Skip to content

Commit

Permalink
Merge branch 'main' into hotfix/replace-domains-7.4.2-base
Browse files Browse the repository at this point in the history
  • Loading branch information
mwmerz authored Aug 21, 2023
2 parents bd6ab78 + d9dc20b commit 343b647
Show file tree
Hide file tree
Showing 9 changed files with 55 additions and 22,506 deletions.
22,525 changes: 33 additions & 22,492 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"@terra-money/ledger-station-js": "^1.3.7",
"@terra-money/log-finder-ruleset": "^3.0.3",
"@terra-money/msg-reader": "^3.0.1",
"@terra-money/station-connector": "^1.0.5",
"@terra-money/station-connector": "^1.0.8",
"@terra-money/terra-utils": "^1.0.9",
"@terra-money/terra.js": "^3.1.9",
"@terra-money/terra.proto": "^2.0.0",
Expand Down
4 changes: 2 additions & 2 deletions public/firefox.manifest.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"manifest_version": 2,
"name": "Station Wallet",
"version": "7.4.2",
"version_name": "7.4.2-rc.2",
"version": "7.4.3",
"version_name": "7.4.3-rc-1",
"background": {
"scripts": ["background.js"],
"persistent": true
Expand Down
3 changes: 3 additions & 0 deletions src/components/feedback/Modal.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@
width: fit-content !important;
padding: 0 !important;
}
&.scrollable {
overflow-y: scroll !important;
}
}

.close {
Expand Down
7 changes: 5 additions & 2 deletions src/components/feedback/Modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,18 +23,20 @@ interface ModalProps {
/* style */
confirm?: boolean
maxHeight?: boolean | number
scrollable?: boolean
}

export interface Props extends ModalProps, ReactModal.Props {}

const Modal = (props: PropsWithChildren<Props>) => {
const { title, children, footer } = props
const { icon, closeIcon, onRequestClose, confirm, maxHeight } = props
const { icon, closeIcon, onRequestClose, confirm, maxHeight, scrollable } =
props

return (
<ReactModal
{...props}
className={styles.modal}
className={cx(styles.modal, { scrollable })}
overlayClassName={styles.overlay}
>
{onRequestClose && (
Expand Down Expand Up @@ -74,6 +76,7 @@ export const [useModal, ModalProvider] = createContext<() => void>("useModal")
interface ModalButtonProps extends ModalProps {
renderButton: RenderButton
modalKey?: string
scrollable?: boolean
}

export const ModalButton = (props: PropsWithChildren<ModalButtonProps>) => {
Expand Down
1 change: 1 addition & 0 deletions src/extension/auth/SelectWallets.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ export default function ManageWallets() {
setPath(Path.select)
}}
className={styles.manage__wallets}
data-testid="manage-wallets-button"
>
{isLedger ? (
wallet.bluetooth ? (
Expand Down
2 changes: 1 addition & 1 deletion src/pages/wallet/IbcSendBack.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const IbcSendBack = ({
chainID,
}: Props) => {
return (
<ModalButton title={title} renderButton={renderButton}>
<ModalButton title={title} scrollable renderButton={renderButton}>
<IbcSendBackTx token={token} chainID={chainID} />
</ModalButton>
)
Expand Down
15 changes: 8 additions & 7 deletions src/pages/wallet/SendPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,13 @@ const SendPage = () => {
),
[balances, readNativeDenom, networkName, prices]
)
const defaultAsset = route?.denom || availableAssets[0].denom

const filteredAssets = useMemo(
() => availableAssets.filter(({ symbol }) => !symbol.endsWith("...")),
[availableAssets]
)

const defaultAsset = route?.denom || filteredAssets[0].denom

/* form */
const form = useForm<TxValues>({ mode: "onChange" })
Expand Down Expand Up @@ -341,11 +347,6 @@ const SendPage = () => {
}
}, [chain, trigger, recipient])

const filteredAssets = useMemo(
() => availableAssets.filter(({ symbol }) => !symbol.endsWith("...")),
[availableAssets]
)

const assetsByDenom = filteredAssets.reduce(
(acc: Record<string, AssetType>, item: AssetType) => {
acc[item.denom] = item
Expand All @@ -369,7 +370,7 @@ const SendPage = () => {
error={errors.asset?.message ?? errors.address?.message}
>
<AssetSelector
value={asset ?? ""}
value={asset ?? defaultAsset}
onChange={(asset) => setValue("asset", asset)}
assetList={filteredAssets}
assetsByDenom={assetsByDenom}
Expand Down
2 changes: 1 addition & 1 deletion src/pages/wallet/Wallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ const Wallet = () => {
className={styles.back}
onClick={() => setRoute(route.previousPage)}
>
<BackIcon width={18} height={18} />
<BackIcon width={18} height={18} data-testid="BackIcon" />
</button>
)
}
Expand Down

0 comments on commit 343b647

Please sign in to comment.