Skip to content

Commit

Permalink
[Wallet] george / Fix UI inconsistencies in CashierWalletHeader compo…
Browse files Browse the repository at this point in the history
…nent (#11145)

* style: 💄 fix icon xl size, jurisdiction badge, text xl line-height size

* style: 💄 add gap in mobile view

* style: 🎨 replace svg fiat currency icons with proper ones
  • Loading branch information
heorhi-deriv committed Nov 3, 2023
1 parent 2994ffb commit fd6c143
Show file tree
Hide file tree
Showing 12 changed files with 29 additions and 115 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ $desktop-font-size-map: (
),
'xl': (
size: 2.4rem,
line_height: 3.4rem,
line_height: 3.6rem,
),
'2xl': (
size: 3.2rem,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const typeToWidthMapper = {
lg: { desktop: 48, mobile: 32 },
md: { desktop: 24, mobile: 24 },
sm: { desktop: 16, mobile: 16 },
xl: { desktop: 56, mobile: 48 },
xl: { desktop: 64, mobile: 48 },
},
};

Expand Down
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
.wallets-list-card {
&__badge {
display: flex;
padding: 0rem 0.4rem;
padding-inline: 0.4rem;
justify-content: center;
align-items: center;
gap: 0.4rem;
height: 1.4rem;
border-radius: 0.2rem;
border: 0.1rem solid var(--system-light-1-prominent-text, #333);
outline: 0.1rem solid var(--system-light-1-prominent-text, #333);

@include mobile {
height: 1.2rem;
}

&--demo {
display: flex;
padding: 0.1rem 0.6rem;
justify-content: center;
align-items: center;
gap: 0.4rem;
border-radius: 0.2rem;
background: var(--status-light-information, #377cfc);
outline: none;
}
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React from 'react';
import classNames from 'classnames';
import { THooks } from '../../types';
import { WalletText } from '../Base';
import './WalletListCardBadge.scss';
Expand All @@ -9,17 +10,17 @@ type TProps = {
};

const WalletListCardBadge: React.FC<TProps> = ({ isDemo, label }) => {
const className = isDemo ? 'wallets-list-card__badge--demo' : 'wallets-list-card__badge';
const className = classNames('wallets-list-card__badge', {
'wallets-list-card__badge--demo': isDemo,
});

const formattedLabel = label === 'virtual' ? 'Demo' : label?.toUpperCase() || 'SVG';

return (
<div className={className}>
<div className='wallets-list-card__name'>
<WalletText color={isDemo ? 'white' : 'black'} size='2xs' weight='bold'>
{formattedLabel}
</WalletText>
</div>
<WalletText color={isDemo ? 'white' : 'black'} size='2xs' weight='bold'>
{formattedLabel}
</WalletText>
</div>
);
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,19 +30,21 @@
&__top-left-info {
display: flex;
flex-direction: column;
gap: 0.6rem;

@include mobile {
gap: 0.4rem;
}
}

&__details {
display: flex;
gap: 2.4rem;
gap: 0.8rem;
align-items: center;

@include mobile {
opacity: 1;
max-height: 2rem;
transition: opacity 0.25s ease, max-height 0.25s ease;
gap: 0.8rem;

&--hide-details {
max-height: 0;
Expand Down
2 changes: 1 addition & 1 deletion packages/wallets/src/public/images/currencies/aud.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 1 addition & 15 deletions packages/wallets/src/public/images/currencies/eur.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 1 addition & 5 deletions packages/wallets/src/public/images/currencies/gbp.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

1 comment on commit fd6c143

@vercel
Copy link

@vercel vercel bot commented on fd6c143 Nov 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

deriv-app – ./

deriv-app.vercel.app
binary.sx
deriv-app-git-master.binary.sx
deriv-app.binary.sx

Please sign in to comment.