Skip to content

Commit

Permalink
chore: small improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
martines3000 committed Dec 23, 2024
1 parent 61546a5 commit 6520b5b
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ const CollateralTableRow = ({
</TooltipProvider>
</TableCell>
<TableCell>
<div className=" h-full flex items-center gap-x-2">
<div className="h-full flex items-center gap-x-2">
<span className="text-lavender font-medium">
{getFormattedPrice(
formatUnits(protocolBalance, decimals).times(price)
Expand All @@ -279,7 +279,7 @@ const CollateralTableRow = ({
</div>
</TableCell>
<TableCell>
<div className=" h-full flex items-center gap-x-2">
<div className="h-full flex items-center gap-x-2">
<PointIcons
points={[
...(symbol === 'USDT' || symbol === 'ETH'
Expand Down
26 changes: 17 additions & 9 deletions apps/frontend/src/components/LeaderboardView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export const LeaderboardView = () => {

return (
<>
<div className="hidden lg:flex pt-[33px] sm:pt-[55px] pb-[55px] w-full items-center justify-center">
<div className="flex pt-[33px] sm:pt-[55px] pb-[55px] w-full items-center justify-center">
<div className="flex flex-col items-center justify-center max-w-[750px] lg:w-[750px]">
<div className="text-xl font-semibold text-white">
Swaylend Leaderboard
Expand All @@ -26,27 +26,27 @@ export const LeaderboardView = () => {
<div className="w-full mt-[30px] flex justify-between bg-card p-4 rounded-xl">
<div>
<div className="text-moon font-semibold">Your Rank</div>
<div className="text-primary text-2xl font-semibold">
<div className="text-primary font-semibold text-xl md:text-2xl">
{user?.rank === 0 ? (
<span className="text-xl">Unranked</span>
<span className="text-lg md:text-xl">Unranked</span>
) : (
user?.rank
)}
</div>
</div>
<div className="flex flex-col items-end">
<div className="text-moon font-semibold">Your Points</div>
<div className="text-white text-2xl font-semibold text-right">
<div className="text-white font-semibold text-right text-xl md:text-2xl">
{user ? user.points : '0'}
</div>
</div>
</div>
))}
<div className="w-full mt-[55px] flex justify-between">
<div className="max-sm:flex max-sm:flex-col max-sm:text-center w-full mt-[55px] flex justify-between">
<div className="text-lg text-white font-semibold">
Top Contributors
</div>
<div className="text-sm text-yellow-100 flex items-center px-2">
<div className="text-sm text-yellow-100 flex items-center sm:px-2 max-sm:justify-center">
<TriangleAlert className="w-4 h-4 mr-1" /> Points are updated
every 24 hours
</div>
Expand Down Expand Up @@ -75,7 +75,15 @@ export const LeaderboardView = () => {
{user.rank}
</td>
<td className="px-4 py-2 text-left text-lavender font-semibold">
{user.address}
<span className="md:hidden">{`${user.address.slice(
0,
6
)}...${user.address.slice(-4)}`}</span>
<span className="max-md:hidden lg:hidden">{`${user.address.slice(
0,
14
)}...${user.address.slice(-14)}`}</span>
<span className="max-lg:hidden">{user.address}</span>
</td>
<td className="px-4 py-2 text-right text-lavender font-semibold">
{user.points}
Expand All @@ -89,9 +97,9 @@ export const LeaderboardView = () => {
</table>
</div>
</div>
<div className="lg:hidden w-full h-[60dvh] flex items-center justify-center">
{/* <div className="lg:hidden w-full h-[60dvh] flex items-center justify-center">
This page is not supported on this screen size.
</div>
</div> */}
</>
);
};
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,6 @@ const customDefaultConnectors = (): Array<FuelConnector> => {
const provider = Provider.create(appConfig.client.fuelNodeUrl);
const connectors: Array<FuelConnector> = [
new FueletWalletConnector(),
...(!isMobile(navigator.userAgent)
? [new FuelWalletConnector(), new BakoSafeConnector()]
: []),
new WalletConnectConnector({
projectId: appConfig.client.walletConnectProjectId,
wagmiConfig: wagmiConfig,
Expand All @@ -100,6 +97,10 @@ const customDefaultConnectors = (): Array<FuelConnector> => {
: CHAIN_IDS.fuel.mainnet,
fuelProvider: provider,
}),
// Add desktop only connectors
...(!isMobile(navigator.userAgent)
? [new FuelWalletConnector(), new BakoSafeConnector()]
: []),
];

if (appConfig.env === 'testnet') {
Expand Down

0 comments on commit 6520b5b

Please sign in to comment.