Skip to content

Commit

Permalink
fix: power icon align
Browse files Browse the repository at this point in the history
Signed-off-by: Innei <[email protected]>
  • Loading branch information
Innei committed Oct 29, 2024
1 parent b97096d commit 11059f6
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export const MyWalletSection = ({ className }: { className?: string }) => {
return (
<div className={cn(className)}>
<div className="text-sm">
<i className="i-mgc-power mr-0.5 size-3.5 translate-y-px text-accent" />
<i className="i-mgc-power mr-0.5 size-3.5 translate-y-px align-text-top text-accent" />
<Trans
i18nKey="wallet.power.description2"
ns="settings"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,13 @@ export const useRewardDescriptionModal = () => {
<TableBody>
{serverConfigs?.DAILY_POWER_PERCENTAGES.map((percentage, index) => {
const level = serverConfigs?.DAILY_POWER_PERCENTAGES.length - index - 1
const rankPercentage = serverConfigs?.LEVEL_PERCENTAGES[index]
return (
<TableRow key={percentage} className="[&>td]:py-2">
<TableCell>
<Level level={level} />
</TableCell>
<TableCell>{serverConfigs?.LEVEL_PERCENTAGES[index] * 100}%</TableCell>
<TableCell>{rankPercentage ? `${rankPercentage * 100}%` : "-"}</TableCell>
<TableCell>{getLevelMultiplier(level)}</TableCell>
<TableCell>
<Balance withSuffix>
Expand Down
4 changes: 1 addition & 3 deletions apps/renderer/src/modules/wallet/balance.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,7 @@ export const Balance = ({

const Content = (
<span className={cn("tabular-nums", className)}>
{withSuffix && (
<i className="i-mgc-power mr-1 translate-y-[-3px] align-text-bottom text-accent" />
)}
{withSuffix && <i className="i-mgc-power mr-1 -translate-y-px align-middle text-accent" />}
<span>{formatted}</span>
</span>
)
Expand Down
2 changes: 1 addition & 1 deletion apps/renderer/src/modules/wallet/level.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const Level = ({
<span className="h-3 w-8 animate-pulse rounded-xl bg-theme-inactive" />
) : (
<>
<span>Lv.{level}</span>
<span className="tabular-nums">Lv.{level}</span>
<sub className="-translate-y-px text-[0.6rem] font-normal">
{getLevelMultiplier(level)}x
</sub>
Expand Down

0 comments on commit 11059f6

Please sign in to comment.