Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions packages/ui/src/assets/svg/swapHorizontal.ts

This file was deleted.

10 changes: 0 additions & 10 deletions packages/ui/src/assets/svg/swapHorizontalBold.ts

This file was deleted.

10 changes: 0 additions & 10 deletions packages/ui/src/assets/svg/swapHorizontalRoundedBold.ts

This file was deleted.

10 changes: 0 additions & 10 deletions packages/ui/src/assets/svg/swapVertical.ts

This file was deleted.

6 changes: 6 additions & 0 deletions packages/ui/src/assets/svg/walletconnect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@ export const walletConnectSvg = svg`
<path d="M58.0927 52.9146L44.415 39.2369L30.7373 52.9146L17.0596 39.2369L11.2017 45.0949L30.7373 64.6374L44.415 50.9597L58.0927 64.6374L77.6284 45.0949L71.7704 39.2369L58.0927 52.9146Z" fill="var(--apkt-tokens-theme-textPrimary)"/>
</svg>`

export const walletConnectInvertSvg = svg`
<svg xmlns="http://www.w3.org/2000/svg" width="89" height="89" viewBox="0 0 89 89" fill="none">
<path d="M60.0468 39.2502L65.9116 33.3854C52.6562 20.13 36.1858 20.13 22.9304 33.3854L28.7952 39.2502C38.8764 29.169 49.9725 29.169 60.0536 39.2502H60.0468Z" fill="var(--apkt-tokens-theme-textInvert)"/>
<path d="M58.0927 52.9146L44.415 39.2369L30.7373 52.9146L17.0596 39.2369L11.2017 45.0949L30.7373 64.6374L44.415 50.9597L58.0927 64.6374L77.6284 45.0949L71.7704 39.2369L58.0927 52.9146Z" fill="var(--apkt-tokens-theme-textInvert)"/>
</svg>`

export const walletConnectLightBrownSvg = svg`
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_22274_4692)">
Expand Down
2 changes: 2 additions & 0 deletions packages/ui/src/components/wui-icon/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import { twitchSvg } from '../../assets/svg/twitch.js'
import { twitterIconSvg } from '../../assets/svg/twitterIcon.js'
import {
walletConnectBrownSvg,
walletConnectInvertSvg,
walletConnectLightBrownSvg,
walletConnectSvg
} from '../../assets/svg/walletconnect.js'
Expand Down Expand Up @@ -204,6 +205,7 @@ const svgOptions: Partial<Record<IconType, TemplateResult<2>>> = {
twitter: xSvg,
twitterIcon: twitterIconSvg,
walletConnect: walletConnectSvg,
walletConnectInvert: walletConnectInvertSvg,
walletConnectBrown: walletConnectBrownSvg,
walletConnectLightBrown: walletConnectLightBrownSvg,
x: xSvg
Expand Down
1 change: 1 addition & 0 deletions packages/ui/src/composites/wui-link/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ export class WuiLink extends LitElement {
public override render() {
return html`
<button ?disabled=${this.disabled} data-variant=${this.variant}>
<slot name="iconLeft"></slot>
<wui-text
color=${TEXT_COLOR_BY_VARIANT[this.variant]}
variant=${TEXT_VARIANT_BY_SIZE[this.size]}
Expand Down
1 change: 1 addition & 0 deletions packages/ui/src/composites/wui-snackbar/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export default css`
box-shadow:
0px 0px 8px 0px rgba(0, 0, 0, 0.1),
inset 0 0 0 1px ${({ tokens }) => tokens.theme.borderPrimary};
max-width: 320px;
}

wui-icon-box {
Expand Down
2 changes: 1 addition & 1 deletion packages/ui/src/composites/wui-transaction-visual/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export class WuiTransactionVisual extends LitElement {
}

if (this.type === 'trade') {
return 'swapHorizontalBold'
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

do you know if we're using swapHorizontalBold option somewhere?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Nope, removed the obsolete svgs

return 'swapHorizontal'
} else if (this.type === 'approve') {
return 'checkmark'
} else if (this.type === 'cancel') {
Expand Down
3 changes: 2 additions & 1 deletion packages/ui/src/utils/TypeUtil.ts
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ export type IconType =
| 'verifyFilled'
| 'wallet'
| 'walletConnect'
| 'walletConnectInvert'
| 'walletConnectLightBrown'
| 'walletConnectBrown'
| 'warning'
Expand Down Expand Up @@ -325,7 +326,7 @@ export type TransactionIconType =
| 'arrowBottom'
| 'arrowTop'
| 'swapVertical'
| 'swapHorizontalBold'
| 'swapHorizontal'
| 'checkmark'
| 'close'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ export class AppKitWalletButton extends LitElement {
})
.finally(() => (this.loading = false))
}}
.icon=${ifDefined(this.wallet === 'walletConnect' ? 'walletConnect' : undefined)}
.icon=${ifDefined(this.wallet === 'walletConnect' ? 'walletConnectInvert' : undefined)}
.imageSrc=${ifDefined(walletImage)}
?disabled=${Boolean(this.caipAddress) || loading || this.modalLoading}
?loading=${loading || this.modalLoading}
Expand Down