Skip to content

Commit 8069be4

Browse files
Merge branch 'main' into fix/confirmation-shield-messages
2 parents a4a7982 + 238a703 commit 8069be4

File tree

15 files changed

+72
-51
lines changed

15 files changed

+72
-51
lines changed

app/_locales/en/messages.json

Lines changed: 2 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/_locales/en_GB/messages.json

Lines changed: 2 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
58.8 KB
Loading

test/e2e/tests/metrics/errors.spec.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,7 @@ describe('Sentry errors', function () {
211211
async function mockSentryMigratorError(mockServer: Mockttp) {
212212
return await mockServer
213213
.forPost(sentryRegEx)
214+
.withBodyIncluding('{"type":"event"')
214215
.withBodyIncluding(migrationError)
215216
.thenCallback(() => {
216217
return {

ui/components/app/shield-entry-modal/index.scss

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@
44
.shield-entry-modal__title {
55
line-height: 1em;
66
font-size: 2.25rem;
7+
8+
@include design-system.screen-sm-max {
9+
font-size: 2rem;
10+
margin-top: 16px;
11+
}
712
}
813

914
.shield-entry-modal__content {
@@ -43,4 +48,13 @@
4348
width: 100%;
4449
}
4550
}
51+
52+
&-sheild-image {
53+
width: 346px;
54+
height: 252px;
55+
56+
@include design-system.screen-sm-max {
57+
width: 322px;
58+
}
59+
}
4660
}

ui/components/app/shield-entry-modal/shield-entry-modal.tsx

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@ import {
4747
} from '../../../../shared/constants/subscriptions';
4848
import {
4949
AlignItems,
50+
BlockSize,
5051
Display,
5152
FlexDirection,
5253
} from '../../../helpers/constants/design-system';
5354
import { TRANSACTION_SHIELD_LINK } from '../../../helpers/constants/common';
5455
import { ThemeType } from '../../../../shared/constants/preferences';
55-
import ShieldIllustrationAnimation from './shield-illustration-animation';
5656

5757
const ShieldEntryModal = ({
5858
skipEventSubmission = false,
@@ -197,6 +197,7 @@ const ShieldEntryModal = ({
197197
flexDirection={FlexDirection.Column}
198198
gap={3}
199199
paddingTop={4}
200+
height={BlockSize.Full}
200201
>
201202
<Text
202203
fontFamily={FontFamily.Hero}
@@ -216,15 +217,11 @@ const ShieldEntryModal = ({
216217
? t('shieldEntryModalSubtitleA', ['$10,000'])
217218
: t('shieldEntryModalSubtitleB', ['$10,000'])}
218219
</Text>
219-
<Box className="grid place-items-center">
220+
<Box className="shield-entry-modal-sheild-image flex-1 flex items-center justify-center">
220221
<img
221-
src="/images/shield-entry-modal-bg.png"
222+
src="/images/transaction-shield-modal.png"
222223
alt="Shield Entry Illustration"
223-
className="col-start-1 row-start-1"
224-
/>
225-
<ShieldIllustrationAnimation
226-
containerClassName="shield-entry-modal-shield-illustration__container col-start-1 row-start-1"
227-
canvasClassName="shield-entry-modal-shield-illustration__canvas"
224+
className="mx-auto h-full w-full object-contain"
228225
/>
229226
</Box>
230227
</ModalBody>

ui/css/utilities/colors.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,5 @@ Before adding a color here make sure that there isn't a design token available.
2424
--color-network-linea-mainnet-default: #121212;
2525
--color-network-linea-mainnet-inverse: #fcfcfc;
2626
--welcome-bg-light: #fff2eb;
27+
--shield-membership-inactive-light: #dadce5;
2728
}

ui/pages/confirmations/components/send/amount/amount.test.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ describe('Amount', () => {
120120
fireEvent.change(getByRole('textbox'), { target: { value: 100 } });
121121
expect(getByText('$ 20.00')).toBeInTheDocument();
122122
fireEvent.click(getByTestId('toggle-fiat-mode'));
123+
expect(getByText('$ 20.00 available')).toBeInTheDocument();
123124
expect(getByRole('textbox')).toHaveValue('20');
124125
expect(getByText('USD')).toBeInTheDocument();
125126
fireEvent.change(getByRole('textbox'), { target: { value: 100 } });

ui/pages/confirmations/components/send/amount/amount.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,12 @@ export const Amount = ({
121121
updateValue,
122122
]);
123123

124+
const balanceDisplayValue = useMemo(() => {
125+
return fiatMode
126+
? `${getFiatDisplayValue(String(balance))} ${t('available')}`
127+
: `${balance} ${asset?.symbol} ${t('available')}`;
128+
}, [fiatMode, getFiatDisplayValue, balance, asset?.symbol, t]);
129+
124130
if (asset?.standard === ERC721) {
125131
return null;
126132
}
@@ -173,7 +179,7 @@ export const Amount = ({
173179
</Text>
174180
<Box display={Display.Flex}>
175181
<Text color={TextColor.textAlternative} variant={TextVariant.bodySm}>
176-
{balance} {asset?.symbol} {t('available')}
182+
{balanceDisplayValue}
177183
</Text>
178184
{!isNonEvmNativeSendType && (
179185
<ButtonLink

ui/pages/settings/index.scss

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -397,7 +397,9 @@
397397

398398
&__modules {
399399
@include design-system.screen-sm-max {
400-
display: block;
400+
display: flex;
401+
flex-flow: column;
402+
overflow-y: auto;
401403
}
402404
}
403405
}
@@ -547,7 +549,8 @@
547549
}
548550

549551
.settings-page__content__modules {
550-
display: block;
552+
display: flex;
553+
flex-flow: column;
551554
}
552555
}
553556
}

0 commit comments

Comments
 (0)