|
1 | 1 | <script lang="ts"> |
2 | 2 | import { base } from '$app/paths' |
| 3 | + import BitcoinImage from '$lib/assets/images/support/bitcoin.svelte' |
| 4 | + import BuyMeACoffeeImage from '$lib/assets/images/support/buycoffee.png' |
| 5 | + import EthereumImage from '$lib/assets/images/support/ethereum.svelte' |
| 6 | + import PatreonImage from '$lib/assets/images/support/patreon.png' |
| 7 | + import SupportImage from '$lib/assets/images/support/support.svelte' |
3 | 8 | import Modal from '$lib/components/elements/Modal.svelte' |
4 | 9 | import { BTC_ADDRESS, ETH_ADDRESS } from '$utils/constants' |
5 | 10 | import Icon from '@iconify/svelte' |
6 | 11 | import QR from '@svelte-put/qr/img/QR.svelte' |
7 | | - import SupportImage from '$lib/assets/images/support/support.svelte' |
8 | | - import BitcoinImage from '$lib/assets/images/support/bitcoin.svelte' |
9 | | - import EthereumImage from '$lib/assets/images/support/ethereum.svelte' |
10 | | - import BuyMeACoffeeImage from '$lib/assets/images/support/buycoffee.png' |
11 | | - import PatreonImage from '$lib/assets/images/support/patreon.png' |
12 | 12 | import type { SvelteComponent } from 'svelte' |
13 | 13 |
|
14 | 14 | const supportImages: Record<string, string> = { |
15 | 15 | buycoffee: BuyMeACoffeeImage, |
16 | | - patreon: PatreonImage |
| 16 | + patreon: PatreonImage, |
17 | 17 | } |
18 | 18 |
|
19 | 19 | const supportImagesCrypto: Record<string, typeof SvelteComponent> = { |
20 | 20 | bitcoin: BitcoinImage, |
21 | | - ethereum: EthereumImage |
| 21 | + ethereum: EthereumImage, |
22 | 22 | } |
23 | 23 |
|
24 | 24 | let modalData = { |
25 | 25 | show: false, |
26 | 26 | type: '', |
27 | | - address: '' |
| 27 | + address: '', |
28 | 28 | } |
29 | 29 | let copied = false |
30 | 30 | let timeout: ReturnType<typeof setTimeout> | null = null |
|
36 | 36 | modalData.show = true |
37 | 37 | modalData.type = 'bitcoin' |
38 | 38 | modalData.address = BTC_ADDRESS |
39 | | - } |
| 39 | + }, |
40 | 40 | }, |
41 | 41 | { |
42 | 42 | name: 'ethereum', |
43 | 43 | onClick: () => { |
44 | 44 | modalData.show = true |
45 | 45 | modalData.type = 'etheruem' |
46 | 46 | modalData.address = ETH_ADDRESS |
47 | | - } |
48 | | - } |
| 47 | + }, |
| 48 | + }, |
49 | 49 | ] |
50 | 50 |
|
51 | 51 | const supportLogos = [ |
52 | 52 | { name: 'buycoffee', url: 'https://buymeacoffee.com/arkbuilders' }, |
53 | | - { name: 'patreon', url: 'https://www.patreon.com/ARKBuilders' } |
| 53 | + { name: 'patreon', url: 'https://www.patreon.com/ARKBuilders' }, |
54 | 54 | ] |
55 | 55 |
|
56 | 56 | const copyAddress = (value: string) => { |
|
83 | 83 | <div class="my-5 grid grid-cols-2 gap-2 md:flex md:h-[40px] md:flex-row"> |
84 | 84 | {#each supportLogosCrypto as logo} |
85 | 85 | <button |
| 86 | + aria-label={logo.name} |
86 | 87 | class="h-11 w-[150px] overflow-hidden rounded-md" |
87 | 88 | on:click={(e) => { |
88 | 89 | if (['bitcoin', 'ethereum'].includes(logo.name)) e.preventDefault() |
|
0 commit comments