From 14267a7089732af1fb0fea7a90e56f65971bfeab Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:27:14 +0100 Subject: [PATCH 01/50] chore: delete redundant component --- src/modal/layouts/argent/QRCode.svelte | 469 ------------------------- 1 file changed, 469 deletions(-) delete mode 100644 src/modal/layouts/argent/QRCode.svelte diff --git a/src/modal/layouts/argent/QRCode.svelte b/src/modal/layouts/argent/QRCode.svelte deleted file mode 100644 index e04d3fa..0000000 --- a/src/modal/layouts/argent/QRCode.svelte +++ /dev/null @@ -1,469 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From 44ce0a5a5a02a8a380eea249ed47ef845ee7c5c4 Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:28:00 +0100 Subject: [PATCH 02/50] chore: inherit `color` for svg icons --- src/modal/components/icons/ReloadIcon.svelte | 3 +-- src/modal/components/icons/brands/AppleIcon.svelte | 1 - 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/src/modal/components/icons/ReloadIcon.svelte b/src/modal/components/icons/ReloadIcon.svelte index bb32753..e5b1885 100644 --- a/src/modal/components/icons/ReloadIcon.svelte +++ b/src/modal/components/icons/ReloadIcon.svelte @@ -1,4 +1,3 @@ - - + \ No newline at end of file diff --git a/src/modal/components/icons/brands/AppleIcon.svelte b/src/modal/components/icons/brands/AppleIcon.svelte index 2678b26..8cbb556 100644 --- a/src/modal/components/icons/brands/AppleIcon.svelte +++ b/src/modal/components/icons/brands/AppleIcon.svelte @@ -1,4 +1,3 @@ - From 110bbdf4696c9029c547acea1529edb5d505130d Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:29:21 +0100 Subject: [PATCH 03/50] chore: remove redundant component --- src/modal/ConnectorButton.svelte | 116 ------------------------------- 1 file changed, 116 deletions(-) delete mode 100644 src/modal/ConnectorButton.svelte diff --git a/src/modal/ConnectorButton.svelte b/src/modal/ConnectorButton.svelte deleted file mode 100644 index 46a528b..0000000 --- a/src/modal/ConnectorButton.svelte +++ /dev/null @@ -1,116 +0,0 @@ -
  • { - cb(null) - }} - on:keyup={(e) => { - if (e.key === "Enter") { - cb(null) - } - }} - > - -

    - Install {wallet.name} -

    - {wallet.name} -
  • - -{:else} - -
  • { - console.log("HERE", wallet, getConnector(wallet.connector)) - cb(getConnector(wallet.connector)) - }} - on:keyup={async (e) => { - if (e.key === "Enter") { - cb(getConnector(wallet.connector)) - } - }} - > - {#if wallet.isCompoundConnector} - - compound - {/if} - -
    -

    - {wallet.title ?? wallet.name} -

    -

    - {wallet.subtitle ?? ""} -

    -
    - - {#if loadingItem === wallet?.id} -
    - - Loading... -
    - {:else if isSvg} -
    {@html icon}
    - {:else} - {wallet?.name} - {/if} -
  • -{/if} From 1202fa324ab73b845a460c5cef00849f3238910b Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:29:55 +0100 Subject: [PATCH 04/50] fix: add missing tailwind's color tokens from `x-ui` --- tailwind.config.js | 1 + 1 file changed, 1 insertion(+) diff --git a/tailwind.config.js b/tailwind.config.js index a11718e..4d65d7a 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -12,6 +12,7 @@ export default { colors: { "primary-orange-400": "var(--color-primary-orange-400)", "surface-default": "var(--color-surface-default)", + ...tailwindThemeConfig.colors, }, fontSize: { ...tailwindThemeConfig.fontSize, From f743342c436e6a0a85fe5e6066d71570428aed20 Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:30:46 +0100 Subject: [PATCH 05/50] chore: improve button components --- .../components/buttons/IconButton.svelte | 27 ++++++++++++------- .../components/buttons/LargeButton.svelte | 12 +++++++-- src/modal/components/buttons/Link.svelte | 15 ++++++++++- 3 files changed, 42 insertions(+), 12 deletions(-) diff --git a/src/modal/components/buttons/IconButton.svelte b/src/modal/components/buttons/IconButton.svelte index e38af82..173fad0 100644 --- a/src/modal/components/buttons/IconButton.svelte +++ b/src/modal/components/buttons/IconButton.svelte @@ -1,19 +1,28 @@ - - \ No newline at end of file + \ No newline at end of file diff --git a/src/modal/components/buttons/LargeButton.svelte b/src/modal/components/buttons/LargeButton.svelte index cbfc1ae..2e072e9 100644 --- a/src/modal/components/buttons/LargeButton.svelte +++ b/src/modal/components/buttons/LargeButton.svelte @@ -1,19 +1,27 @@ diff --git a/src/modal/components/buttons/Link.svelte b/src/modal/components/buttons/Link.svelte index 512495b..44dc1ad 100644 --- a/src/modal/components/buttons/Link.svelte +++ b/src/modal/components/buttons/Link.svelte @@ -2,8 +2,21 @@ export let className: string export let href: string | undefined = undefined export let as: "button" | "a" = "a" + + export let handleClick: ((e: MouseEvent) => void) | undefined = undefined + export let handleKeyup: ((e: KeyboardEvent) => void) | undefined = undefined - + \ No newline at end of file From c777e5d136d9d1722e611a11eb5aeed234939331 Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:34:48 +0100 Subject: [PATCH 06/50] chore: rename component to more appropriate name --- src/modal/components/{Line.svelte => HorizontalLine.svelte} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename src/modal/components/{Line.svelte => HorizontalLine.svelte} (100%) diff --git a/src/modal/components/Line.svelte b/src/modal/components/HorizontalLine.svelte similarity index 100% rename from src/modal/components/Line.svelte rename to src/modal/components/HorizontalLine.svelte From 8612c92634722fa86ff8779be20b0212a1024e98 Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:35:33 +0100 Subject: [PATCH 07/50] chore: improve button component --- src/modal/components/buttons/Button.svelte | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/modal/components/buttons/Button.svelte b/src/modal/components/buttons/Button.svelte index 1ce9234..2f27f21 100644 --- a/src/modal/components/buttons/Button.svelte +++ b/src/modal/components/buttons/Button.svelte @@ -6,10 +6,15 @@ export let as: "button" | "a" = "button" export let isLarge: boolean = false - export let height = isLarge ? "min-h-12" : "min-h-8" + const height = isLarge ? "min-h-12" : "min-h-8" + + export let handleClick: (e: MouseEvent) => void = (e: MouseEvent) => console.log("click", e) + export let handleKeyup: (e: KeyboardEvent) => void = (e: KeyboardEvent) => console.log("keyup", e) Date: Tue, 29 Oct 2024 11:35:58 +0100 Subject: [PATCH 08/50] fix: color --- src/modal/components/icons/CloseIcon.svelte | 1 - 1 file changed, 1 deletion(-) diff --git a/src/modal/components/icons/CloseIcon.svelte b/src/modal/components/icons/CloseIcon.svelte index 14b302c..b2e8ab9 100644 --- a/src/modal/components/icons/CloseIcon.svelte +++ b/src/modal/components/icons/CloseIcon.svelte @@ -1,4 +1,3 @@ - \ No newline at end of file From c57a8d8201a3a919031fa867544f8d78e4d873ac Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:36:44 +0100 Subject: [PATCH 09/50] feat: add component for rendering icons --- src/modal/components/DynamicIcon.svelte | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 src/modal/components/DynamicIcon.svelte diff --git a/src/modal/components/DynamicIcon.svelte b/src/modal/components/DynamicIcon.svelte new file mode 100644 index 0000000..8d131d8 --- /dev/null +++ b/src/modal/components/DynamicIcon.svelte @@ -0,0 +1,21 @@ + + +{#if renderIcon.trimStart()?.startsWith(" +
    {@html renderIcon}
    +{:else} + +{/if} From fba46c4e3d237cb8c1c5e837f9efe5ca91da1bab Mon Sep 17 00:00:00 2001 From: Aleksandar Cakalic Date: Tue, 29 Oct 2024 11:38:27 +0100 Subject: [PATCH 10/50] chore: clean up and add missing functionality --- src/modal/components/FallbackMobile.svelte | 19 +++++++++++---- src/modal/components/InstallWallet.svelte | 16 +++++++++---- .../components/buttons/WalletButton.svelte | 23 +++++++++++++------ src/modal/layouts/Connecting.svelte | 9 ++++---- src/modal/layouts/FailedLogin.svelte | 22 ++++++++++++++---- 5 files changed, 64 insertions(+), 25 deletions(-) diff --git a/src/modal/components/FallbackMobile.svelte b/src/modal/components/FallbackMobile.svelte index 8dcb928..af2ed02 100644 --- a/src/modal/components/FallbackMobile.svelte +++ b/src/modal/components/FallbackMobile.svelte @@ -1,14 +1,23 @@ -