Skip to content

Commit

Permalink
clean up shared functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
soerenbf committed Oct 24, 2024
1 parent 4a79c63 commit 72062cb
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 182 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ import { CCD_METADATA } from '@shared/constants/token-metadata';
import { ensureDefined } from '@shared/utils/basic-helpers';
import SideArrow from '@assets/svgX/side-arrow.svg';
import ConcordiumLogo from '@assets/svgX/concordium-logo.svg';
import { validateAccountAddress, validateTransferAmount } from '@popup/shared/utils/transaction-helpers';
import Img, { DEFAULT_FAILED } from '@popup/shared/Img';
import { displayAsCcd } from 'wallet-common-helpers';
import { RequiredUncontrolledFieldProps } from '../common/types';
import { makeUncontrolled } from '../common/utils';
import Button from '../../Button';
import { formatTokenAmount, parseTokenAmount, removeNumberGrouping } from '../../utils/helpers';
import { validateAccountAddress, validateTransferAmount } from '../../utils/transaction-helpers';
import ErrorMessage from '../ErrorMessage';
import Img, { DEFAULT_FAILED } from '../../Img';
import { TokenInfo } from './util';

type AmountInputProps = Pick<
Expand Down
55 changes: 0 additions & 55 deletions packages/browser-wallet/src/popup/popupX/shared/Img.tsx

This file was deleted.

5 changes: 0 additions & 5 deletions packages/browser-wallet/src/popup/popupX/shared/i18n/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,10 @@ const t = {
utils: {
address: {
required: 'Please enter an address',
invalid: 'Invalid address',
},
amount: {
required: 'Please enter an amount',
invalid: 'Invalid amount',
insufficient: 'Insufficient funds',
zero: 'Amount may not be zero',
belowBakerThreshold: 'Minimum stake: {{ threshold }}',
exceedingDelegationCap: "Amount may not exceed the target pool's cap of {{ max }}.",
},
},
};
Expand Down

This file was deleted.

2 changes: 1 addition & 1 deletion packages/browser-wallet/src/popup/shared/Img.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import React, { useState } from 'react';
import { ClassName } from 'wallet-common-helpers';

const DEFAULT_LOADING = '/assets/svg/loading_icon.svg';
const DEFAULT_FAILED = '/assets/svg/no_icon.svg';
export const DEFAULT_FAILED = '/assets/svg/no_icon.svg';

type BaseProps = ClassName & {
src?: string;
Expand Down

0 comments on commit 72062cb

Please sign in to comment.