@rainlanguage/ui-components 0.0.1-alpha.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (236) hide show
  1. package/README.md +58 -0
  2. package/dist/__fixtures__/orderDetail.d.ts +99 -0
  3. package/dist/__fixtures__/orderDetail.js +204 -0
  4. package/dist/__fixtures__/settings-12-11-24.json +160 -0
  5. package/dist/__mocks__/MockComponent.d.ts +1 -0
  6. package/dist/__mocks__/MockComponent.js +2 -0
  7. package/dist/__mocks__/MockComponent.svelte +3 -0
  8. package/dist/__mocks__/MockComponent.svelte.d.ts +18 -0
  9. package/dist/__mocks__/mockTransactionStore.d.ts +22 -0
  10. package/dist/__mocks__/mockTransactionStore.js +56 -0
  11. package/dist/__mocks__/mockWeb3Config.d.ts +2 -0
  12. package/dist/__mocks__/mockWeb3Config.js +15 -0
  13. package/dist/__mocks__/queries.d.ts +13 -0
  14. package/dist/__mocks__/queries.js +64 -0
  15. package/dist/__mocks__/settings.d.ts +3 -0
  16. package/dist/__mocks__/settings.js +37 -0
  17. package/dist/__mocks__/stores.d.ts +94 -0
  18. package/dist/__mocks__/stores.js +113 -0
  19. package/dist/app.css +3 -0
  20. package/dist/assets/ledger.svg +6 -0
  21. package/dist/assets/logo-dark.svg +15 -0
  22. package/dist/assets/logo-light.svg +15 -0
  23. package/dist/assets/walletconnect.svg +1 -0
  24. package/dist/components/BadgeActive.svelte +9 -0
  25. package/dist/components/BadgeActive.svelte.d.ts +19 -0
  26. package/dist/components/BlockQuote.svelte +1 -0
  27. package/dist/components/BlockQuote.svelte.d.ts +29 -0
  28. package/dist/components/ButtonDarkMode.svelte +14 -0
  29. package/dist/components/ButtonDarkMode.svelte.d.ts +18 -0
  30. package/dist/components/ButtonLoading.svelte +11 -0
  31. package/dist/components/ButtonLoading.svelte.d.ts +24 -0
  32. package/dist/components/ButtonTab.svelte +7 -0
  33. package/dist/components/ButtonTab.svelte.d.ts +23 -0
  34. package/dist/components/ButtonVaultLink.svelte +29 -0
  35. package/dist/components/ButtonVaultLink.svelte.d.ts +22 -0
  36. package/dist/components/CardProperty.svelte +11 -0
  37. package/dist/components/CardProperty.svelte.d.ts +31 -0
  38. package/dist/components/CheckboxMyItemsOnly.svelte +23 -0
  39. package/dist/components/CheckboxMyItemsOnly.svelte.d.ts +21 -0
  40. package/dist/components/CheckboxZeroBalanceVault.svelte +20 -0
  41. package/dist/components/CheckboxZeroBalanceVault.svelte.d.ts +19 -0
  42. package/dist/components/CodeMirrorDotrain.svelte +35 -0
  43. package/dist/components/CodeMirrorDotrain.svelte.d.ts +23 -0
  44. package/dist/components/CodeMirrorRainlang.svelte +34 -0
  45. package/dist/components/CodeMirrorRainlang.svelte.d.ts +23 -0
  46. package/dist/components/DropdownProperty.svelte +12 -0
  47. package/dist/components/DropdownProperty.svelte.d.ts +19 -0
  48. package/dist/components/EditableSpan.svelte +46 -0
  49. package/dist/components/EditableSpan.svelte.d.ts +21 -0
  50. package/dist/components/Hash.svelte +85 -0
  51. package/dist/components/Hash.svelte.d.ts +28 -0
  52. package/dist/components/Heading.svelte +19 -0
  53. package/dist/components/Heading.svelte.d.ts +29 -0
  54. package/dist/components/IconError.svelte +8 -0
  55. package/dist/components/IconError.svelte.d.ts +16 -0
  56. package/dist/components/IconExternalLink.svelte +18 -0
  57. package/dist/components/IconExternalLink.svelte.d.ts +18 -0
  58. package/dist/components/IconInfo.svelte +8 -0
  59. package/dist/components/IconInfo.svelte.d.ts +16 -0
  60. package/dist/components/IconLedger.svelte +13 -0
  61. package/dist/components/IconLedger.svelte.d.ts +16 -0
  62. package/dist/components/IconSuccess.svelte +8 -0
  63. package/dist/components/IconSuccess.svelte.d.ts +16 -0
  64. package/dist/components/IconTelegram.svelte +12 -0
  65. package/dist/components/IconTelegram.svelte.d.ts +25 -0
  66. package/dist/components/IconWalletConnect.svelte +13 -0
  67. package/dist/components/IconWalletConnect.svelte.d.ts +16 -0
  68. package/dist/components/IconWarning.svelte +8 -0
  69. package/dist/components/IconWarning.svelte.d.ts +16 -0
  70. package/dist/components/License.svelte +29 -0
  71. package/dist/components/License.svelte.d.ts +25 -0
  72. package/dist/components/ListViewOrderbookFilters.svelte +58 -0
  73. package/dist/components/ListViewOrderbookFilters.svelte.d.ts +28 -0
  74. package/dist/components/OrderOrVaultHash.svelte +24 -0
  75. package/dist/components/OrderOrVaultHash.svelte.d.ts +22 -0
  76. package/dist/components/PageHeader.svelte +33 -0
  77. package/dist/components/PageHeader.svelte.d.ts +21 -0
  78. package/dist/components/TanstackAppTable.svelte +73 -0
  79. package/dist/components/TanstackAppTable.svelte.d.ts +30 -0
  80. package/dist/components/Text.svelte +12 -0
  81. package/dist/components/Text.svelte.d.ts +31 -0
  82. package/dist/components/charts/APYTimeFilters.svelte +47 -0
  83. package/dist/components/charts/APYTimeFilters.svelte.d.ts +19 -0
  84. package/dist/components/charts/ChartTimeFilters.svelte +35 -0
  85. package/dist/components/charts/ChartTimeFilters.svelte.d.ts +18 -0
  86. package/dist/components/charts/LightweightChart.svelte +110 -0
  87. package/dist/components/charts/LightweightChart.svelte.d.ts +29 -0
  88. package/dist/components/charts/OrderTradesChart.svelte +36 -0
  89. package/dist/components/charts/OrderTradesChart.svelte.d.ts +21 -0
  90. package/dist/components/charts/TableTimeFilters.svelte +48 -0
  91. package/dist/components/charts/TableTimeFilters.svelte.d.ts +19 -0
  92. package/dist/components/charts/TanstackLightweightChartLine.svelte +24 -0
  93. package/dist/components/charts/TanstackLightweightChartLine.svelte.d.ts +23 -0
  94. package/dist/components/charts/VaultBalanceChart.svelte +37 -0
  95. package/dist/components/charts/VaultBalanceChart.svelte.d.ts +22 -0
  96. package/dist/components/checkbox/Checkbox.svelte +17 -0
  97. package/dist/components/checkbox/Checkbox.svelte.d.ts +21 -0
  98. package/dist/components/deployment/ButtonSelectOption.svelte +14 -0
  99. package/dist/components/deployment/ButtonSelectOption.svelte.d.ts +20 -0
  100. package/dist/components/deployment/ComposedRainlangModal.svelte +35 -0
  101. package/dist/components/deployment/ComposedRainlangModal.svelte.d.ts +19 -0
  102. package/dist/components/deployment/DeploymentSectionHeader.svelte +14 -0
  103. package/dist/components/deployment/DeploymentSectionHeader.svelte.d.ts +19 -0
  104. package/dist/components/deployment/DeploymentSteps.svelte +252 -0
  105. package/dist/components/deployment/DeploymentSteps.svelte.d.ts +38 -0
  106. package/dist/components/deployment/DeploymentTile.svelte +19 -0
  107. package/dist/components/deployment/DeploymentTile.svelte.d.ts +21 -0
  108. package/dist/components/deployment/DeploymentsSection.svelte +20 -0
  109. package/dist/components/deployment/DeploymentsSection.svelte.d.ts +19 -0
  110. package/dist/components/deployment/DepositInput.svelte +93 -0
  111. package/dist/components/deployment/DepositInput.svelte.d.ts +20 -0
  112. package/dist/components/deployment/DepositsSection.svelte +8 -0
  113. package/dist/components/deployment/DepositsSection.svelte.d.ts +20 -0
  114. package/dist/components/deployment/DisclaimerModal.svelte +54 -0
  115. package/dist/components/deployment/DisclaimerModal.svelte.d.ts +19 -0
  116. package/dist/components/deployment/FieldDefinitionInput.svelte +66 -0
  117. package/dist/components/deployment/FieldDefinitionInput.svelte.d.ts +20 -0
  118. package/dist/components/deployment/FieldDefinitionsSection.svelte +9 -0
  119. package/dist/components/deployment/FieldDefinitionsSection.svelte.d.ts +20 -0
  120. package/dist/components/deployment/InvalidStrategiesSection.svelte +19 -0
  121. package/dist/components/deployment/InvalidStrategiesSection.svelte.d.ts +19 -0
  122. package/dist/components/deployment/SelectToken.svelte +88 -0
  123. package/dist/components/deployment/SelectToken.svelte.d.ts +21 -0
  124. package/dist/components/deployment/SelectTokensSection.svelte +17 -0
  125. package/dist/components/deployment/SelectTokensSection.svelte.d.ts +21 -0
  126. package/dist/components/deployment/ShareChoicesButton.svelte +26 -0
  127. package/dist/components/deployment/ShareChoicesButton.svelte.d.ts +18 -0
  128. package/dist/components/deployment/StrategyPage.svelte +70 -0
  129. package/dist/components/deployment/StrategyPage.svelte.d.ts +19 -0
  130. package/dist/components/deployment/TokenIOInput.svelte +62 -0
  131. package/dist/components/deployment/TokenIOInput.svelte.d.ts +22 -0
  132. package/dist/components/deployment/TokenIOSection.svelte +17 -0
  133. package/dist/components/deployment/TokenIOSection.svelte.d.ts +21 -0
  134. package/dist/components/deployment/ValidStrategiesSection.svelte +25 -0
  135. package/dist/components/deployment/ValidStrategiesSection.svelte.d.ts +19 -0
  136. package/dist/components/deployment/getDeploymentTransactionArgs.d.ts +17 -0
  137. package/dist/components/deployment/getDeploymentTransactionArgs.js +24 -0
  138. package/dist/components/detail/DepositOrWithdrawButtons.svelte +44 -0
  139. package/dist/components/detail/DepositOrWithdrawButtons.svelte.d.ts +26 -0
  140. package/dist/components/detail/OrderDetail.svelte +195 -0
  141. package/dist/components/detail/OrderDetail.svelte.d.ts +36 -0
  142. package/dist/components/detail/TanstackOrderQuote.svelte +173 -0
  143. package/dist/components/detail/TanstackOrderQuote.svelte.d.ts +22 -0
  144. package/dist/components/detail/TanstackPageContentDetail.svelte +56 -0
  145. package/dist/components/detail/TanstackPageContentDetail.svelte.d.ts +31 -0
  146. package/dist/components/detail/VaultDetail.svelte +178 -0
  147. package/dist/components/detail/VaultDetail.svelte.d.ts +35 -0
  148. package/dist/components/dropdown/DropdownActiveSubgraphs.svelte +38 -0
  149. package/dist/components/dropdown/DropdownActiveSubgraphs.svelte.d.ts +21 -0
  150. package/dist/components/dropdown/DropdownCheckbox.svelte +77 -0
  151. package/dist/components/dropdown/DropdownCheckbox.svelte.d.ts +26 -0
  152. package/dist/components/dropdown/DropdownOrderListAccounts.svelte +15 -0
  153. package/dist/components/dropdown/DropdownOrderListAccounts.svelte.d.ts +20 -0
  154. package/dist/components/dropdown/DropdownOrderStatus.svelte +31 -0
  155. package/dist/components/dropdown/DropdownOrderStatus.svelte.d.ts +19 -0
  156. package/dist/components/dropdown/DropdownRadio.svelte +45 -0
  157. package/dist/components/dropdown/DropdownRadio.svelte.d.ts +30 -0
  158. package/dist/components/icon/RainLogo.svelte +54 -0
  159. package/dist/components/icon/RainLogo.svelte.d.ts +25 -0
  160. package/dist/components/icon/Refresh.svelte +57 -0
  161. package/dist/components/icon/Refresh.svelte.d.ts +40 -0
  162. package/dist/components/input/InputHex.svelte +42 -0
  163. package/dist/components/input/InputHex.svelte.d.ts +19 -0
  164. package/dist/components/input/InputOrderHash.svelte +22 -0
  165. package/dist/components/input/InputOrderHash.svelte.d.ts +20 -0
  166. package/dist/components/input/InputRegistryUrl.svelte +18 -0
  167. package/dist/components/input/InputRegistryUrl.svelte.d.ts +16 -0
  168. package/dist/components/input/InputToken.svelte +53 -0
  169. package/dist/components/input/InputToken.svelte.d.ts +19 -0
  170. package/dist/components/input/InputTokenAmount.svelte +63 -0
  171. package/dist/components/input/InputTokenAmount.svelte.d.ts +21 -0
  172. package/dist/components/tables/OrderAPY.svelte +57 -0
  173. package/dist/components/tables/OrderAPY.svelte.d.ts +19 -0
  174. package/dist/components/tables/OrderTradesListTable.svelte +145 -0
  175. package/dist/components/tables/OrderTradesListTable.svelte.d.ts +21 -0
  176. package/dist/components/tables/OrderVaultsVolTable.svelte +67 -0
  177. package/dist/components/tables/OrderVaultsVolTable.svelte.d.ts +19 -0
  178. package/dist/components/tables/OrdersListTable.svelte +181 -0
  179. package/dist/components/tables/OrdersListTable.svelte.d.ts +35 -0
  180. package/dist/components/tables/VaultBalanceChangesTable.svelte +74 -0
  181. package/dist/components/tables/VaultBalanceChangesTable.svelte.d.ts +17 -0
  182. package/dist/components/tables/VaultsListTable.svelte +229 -0
  183. package/dist/components/tables/VaultsListTable.svelte.d.ts +40 -0
  184. package/dist/components/wallet/WalletConnect.svelte +28 -0
  185. package/dist/components/wallet/WalletConnect.svelte.d.ts +23 -0
  186. package/dist/errors/DeploymentStepsError.d.ts +24 -0
  187. package/dist/errors/DeploymentStepsError.js +45 -0
  188. package/dist/errors/index.d.ts +1 -0
  189. package/dist/errors/index.js +1 -0
  190. package/dist/index.d.ts +89 -0
  191. package/dist/index.js +89 -0
  192. package/dist/queries/constants.d.ts +2 -0
  193. package/dist/queries/constants.js +2 -0
  194. package/dist/queries/keys.d.ts +9 -0
  195. package/dist/queries/keys.js +9 -0
  196. package/dist/queries/queryClient.d.ts +3 -0
  197. package/dist/queries/queryClient.js +16 -0
  198. package/dist/services/getExplorerLink.d.ts +1 -0
  199. package/dist/services/getExplorerLink.js +10 -0
  200. package/dist/services/handleShareChoices.d.ts +2 -0
  201. package/dist/services/handleShareChoices.js +10 -0
  202. package/dist/services/historicalOrderCharts.d.ts +12 -0
  203. package/dist/services/historicalOrderCharts.js +496 -0
  204. package/dist/services/index.d.ts +2 -0
  205. package/dist/services/index.js +1 -0
  206. package/dist/services/registry.d.ts +25 -0
  207. package/dist/services/registry.js +133 -0
  208. package/dist/services/time.d.ts +6 -0
  209. package/dist/services/time.js +17 -0
  210. package/dist/stores/transactionStore.d.ts +98 -0
  211. package/dist/stores/transactionStore.js +303 -0
  212. package/dist/test/matchers.d.ts +6 -0
  213. package/dist/test/matchers.js +4 -0
  214. package/dist/types/appStores.d.ts +19 -0
  215. package/dist/types/appStores.js +1 -0
  216. package/dist/types/modal.d.ts +20 -0
  217. package/dist/types/modal.js +1 -0
  218. package/dist/types/strategy.d.ts +10 -0
  219. package/dist/types/strategy.js +1 -0
  220. package/dist/types/transaction.d.ts +27 -0
  221. package/dist/types/transaction.js +1 -0
  222. package/dist/utils/breadcrumbs.d.ts +5 -0
  223. package/dist/utils/breadcrumbs.js +9 -0
  224. package/dist/utils/codeMirrorThemes.d.ts +2 -0
  225. package/dist/utils/codeMirrorThemes.js +86 -0
  226. package/dist/utils/hex.d.ts +2 -0
  227. package/dist/utils/hex.js +3 -0
  228. package/dist/utils/lightweightChartsThemes.d.ts +52 -0
  229. package/dist/utils/lightweightChartsThemes.js +21 -0
  230. package/dist/utils/number.d.ts +14 -0
  231. package/dist/utils/number.js +43 -0
  232. package/dist/utils/time.d.ts +12 -0
  233. package/dist/utils/time.js +27 -0
  234. package/dist/utils/vault.d.ts +2 -0
  235. package/dist/utils/vault.js +29 -0
  236. package/package.json +86 -0
package/README.md ADDED
@@ -0,0 +1,58 @@
1
+ # create-svelte
2
+
3
+ Everything you need to build a Svelte library, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/main/packages/create-svelte).
4
+
5
+ Read more about creating a library [in the docs](https://svelte.dev/docs/kit/packaging).
6
+
7
+ ## Creating a project
8
+
9
+ If you're seeing this, you've probably already done this step. Congrats!
10
+
11
+ ```bash
12
+ # create a new project in the current directory
13
+ npx sv create
14
+
15
+ # create a new project in my-app
16
+ npx sv create my-app
17
+ ```
18
+
19
+ ## Developing
20
+
21
+ Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
22
+
23
+ ```bash
24
+ npm run dev
25
+
26
+ # or start the server and open the app in a new browser tab
27
+ npm run dev -- --open
28
+ ```
29
+
30
+ Everything inside `src/lib` is part of your library, everything inside `src/routes` can be used as a showcase or preview app.
31
+
32
+ ## Building
33
+
34
+ To build your library:
35
+
36
+ ```bash
37
+ npm run package
38
+ ```
39
+
40
+ To create a production version of your showcase app:
41
+
42
+ ```bash
43
+ npm run build
44
+ ```
45
+
46
+ You can preview the production build with `npm run preview`.
47
+
48
+ > To deploy your app, you may need to install an [adapter](https://svelte.dev/docs/kit/adapters) for your target environment.
49
+
50
+ ## Publishing
51
+
52
+ Go into the `package.json` and give your package the desired name through the `"name"` option. Also consider adding a `"license"` field and point it to a `LICENSE` file which you can create from a template (one popular option is the [MIT license](https://opensource.org/license/mit/)).
53
+
54
+ To publish your library to [npm](https://www.npmjs.com):
55
+
56
+ ```bash
57
+ npm publish
58
+ ```
@@ -0,0 +1,99 @@
1
+ import type { OrderDetailExtended } from '@rainlanguage/orderbook/js_api';
2
+ export declare const mockOrderDetailsExtended: OrderDetailExtended;
3
+ export declare const mockOrder: {
4
+ id: string;
5
+ orderBytes: string;
6
+ orderHash: string;
7
+ owner: string;
8
+ outputs: {
9
+ id: string;
10
+ owner: string;
11
+ vaultId: string;
12
+ balance: string;
13
+ token: {
14
+ id: string;
15
+ address: string;
16
+ name: string;
17
+ symbol: string;
18
+ decimals: string;
19
+ };
20
+ orderbook: {
21
+ id: string;
22
+ };
23
+ ordersAsOutput: {
24
+ id: string;
25
+ orderHash: string;
26
+ active: boolean;
27
+ }[];
28
+ ordersAsInput: never[];
29
+ balanceChanges: {
30
+ __typename: string;
31
+ data: {
32
+ id: string;
33
+ __typename: string;
34
+ amount: string;
35
+ newVaultBalance: string;
36
+ oldVaultBalance: string;
37
+ vault: {
38
+ id: string;
39
+ vault_id: string;
40
+ token: {
41
+ id: string;
42
+ address: string;
43
+ name: string;
44
+ symbol: string;
45
+ decimals: string;
46
+ };
47
+ };
48
+ timestamp: string;
49
+ transaction: {
50
+ id: string;
51
+ from: string;
52
+ blockNumber: string;
53
+ timestamp: string;
54
+ };
55
+ orderbook: {
56
+ id: string;
57
+ };
58
+ };
59
+ }[];
60
+ }[];
61
+ inputs: {
62
+ id: string;
63
+ owner: string;
64
+ vaultId: string;
65
+ balance: string;
66
+ token: {
67
+ id: string;
68
+ address: string;
69
+ name: string;
70
+ symbol: string;
71
+ decimals: string;
72
+ };
73
+ orderbook: {
74
+ id: string;
75
+ };
76
+ ordersAsOutput: never[];
77
+ ordersAsInput: {
78
+ id: string;
79
+ orderHash: string;
80
+ active: boolean;
81
+ }[];
82
+ balanceChanges: never[];
83
+ }[];
84
+ orderbook: {
85
+ id: string;
86
+ };
87
+ active: boolean;
88
+ timestampAdded: string;
89
+ meta: string;
90
+ addEvents: {
91
+ transaction: {
92
+ id: string;
93
+ from: string;
94
+ blockNumber: string;
95
+ timestamp: string;
96
+ };
97
+ }[];
98
+ trades: never[];
99
+ };
@@ -0,0 +1,204 @@
1
+ export const mockOrderDetailsExtended = {
2
+ order: {
3
+ id: 'order1',
4
+ orderBytes: '0x123456',
5
+ orderHash: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdefabcdef',
6
+ owner: '0x1111111111111111111111111111111111111111',
7
+ outputs: [
8
+ {
9
+ id: 'vault1',
10
+ token: {
11
+ id: 'token1',
12
+ address: '0xaaaaaa1111111111111111111111111111111111',
13
+ name: 'Token1',
14
+ symbol: 'TK1',
15
+ decimals: '18'
16
+ },
17
+ balance: '1000',
18
+ vaultId: '0x1111111111111111111111111111111111111111111111111111111111111111',
19
+ orderbook: { id: '0x1111111111111111111111111111111111111111' },
20
+ owner: '0x1111111111111111111111111111111111111111',
21
+ ordersAsOutput: [],
22
+ ordersAsInput: [],
23
+ balanceChanges: []
24
+ }
25
+ ],
26
+ inputs: [
27
+ {
28
+ id: 'vault2',
29
+ token: {
30
+ id: 'token2',
31
+ address: '0xbbbbbb2222222222222222222222222222222222',
32
+ name: 'Token2',
33
+ symbol: 'TK2',
34
+ decimals: '18'
35
+ },
36
+ balance: '500',
37
+ vaultId: '0x2222222222222222222222222222222222222222222222222222222222222222',
38
+ orderbook: { id: '0x1111111111111111111111111111111111111111' },
39
+ owner: '0x1111111111111111111111111111111111111111',
40
+ ordersAsOutput: [],
41
+ ordersAsInput: [],
42
+ balanceChanges: []
43
+ }
44
+ ],
45
+ active: true,
46
+ addEvents: [
47
+ {
48
+ transaction: {
49
+ id: '0x2222222222222222222222222222222222222222222222222222222222222222',
50
+ from: '0x1111111111111111111111111111111111111111',
51
+ blockNumber: '12345',
52
+ timestamp: '1620000000'
53
+ }
54
+ }
55
+ ],
56
+ meta: 'metadata1',
57
+ timestampAdded: '1620000000',
58
+ orderbook: {
59
+ id: '0x00'
60
+ },
61
+ trades: []
62
+ },
63
+ rainlang: 'rainlang1'
64
+ };
65
+ export const mockOrder = {
66
+ id: '0x9229dadc45c673afcbc393231d5ab0e15bb65719daa5d58bd85adfca3fd60d48',
67
+ orderBytes: '0x0000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b7e455bac373194f20d5962bd8ae1c0884d3436a00000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000062000000000000000000000000000000000000000000000000000000000000006a06322e24062c0c4fe1d4d97a4ecd7fe28f3ab9e86f31d5c5e7f2b3b6d1533ba62000000000000000000000000bd8849759749b4d8506bc851acef0e19f34eabee0000000000000000000000008d96ea3ef24d7123882c51ce4325b89bc0d63f9e000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000004e3000000000000000000000000000000000000000000000000000000000000001100000000000000000000000000000000000000000000000000b1a2bc2ec500000000000000000000000000000000000000000000000000000c7d713b49da0000914d696e20747261646520616d6f756e742e00000000000000000000000000008b616d6f756e742d7573656400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000853a0d2313c000000000000000000000000000000000000000000000000124bc0ddd92e560000000000000000000000000000000000000000000000000000c328093e61ee4000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000e043da6172500008f6c6173742d74726164652d74696d65000000000000000000000000000000008d6c6173742d74726164652d696f0000000000000000000000000000000000008c696e697469616c2d74696d650000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f05b59d3b200000000000000000000000000000000000000000000000000008ac7230489e800000000000000000000000000000000000000000000000000d8d726b7177a8000000000000000000000000000000000000000000000000000d551185379fa1c000000000000000000000000000000000000000000000000000000000000000002830b00000024007400e0015801b401e001f40218025c0264080500040b20000200100001001000000b120003001000010b110004001000030b0100051305000201100001011000003d120000011000020010000003100404211200001d02000001100003031000010c1200004911000003100404001000012b12000001100003031000010c1200004a0200001a0b00090b1000060b20000700100000001000011b1200001a10000047120000001000001a1000004712000001100004011000002e12000001100006011000052e120000001000053d12000001100005001000042e1200000010000601100006001000032e120000481200011d0b020a0010000001100004011000072713000001100003031000010c12000049110000001000030010000247120000001000010b110008001000050110000000100001201200001f12000001100000011000084712000000100006001000073d120000011000002b12000000100008001000043b120000160901080b1000070b10000901100009001000013d1200001b12000001100007001000013d1200000b10000a001000033a120000001000040010000248120001001000000b110008001000053d12000000100006001000042b1200000a0401011a1000000110000a031000010c1200004a020000001000000110000b031000010c1200004a020000040200010110000c031000010c12000049110000080300020110000a031000010c120000491100000110000b031000010c12000049110000100c01030110000e001000002e1200000110000d3e120000001000010010000100100001001000010010000100100001001000010010000100100001001000013d1a0000010100010110000f010100010110001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000af88d065e77c8cc2239327c5edb3a432268e58310000000000000000000000000000000000000000000000000000000000000006b798f8557fa0e7787ba14dc96c22d2f7d2314689d209a54104e1c6685ad1e39c000000000000000000000000000000000000000000000000000000000000000100000000000000000000000082af49447d8a07e3bd95bd0d56f35241523fbab10000000000000000000000000000000000000000000000000000000000000012b798f8557fa0e7787ba14dc96c22d2f7d2314689d209a54104e1c6685ad1e39c',
68
+ orderHash: '0x522af734207572d3c1d2cff938dc355578391b62b7b5e6f45185c481141416f7',
69
+ owner: '0xb7e455bac373194f20d5962bd8ae1c0884d3436a',
70
+ outputs: [
71
+ {
72
+ id: '0x81bd468a9c493e7427ec9b3cafd52cc780a5a0d9074043bcbae608c5f39a6118',
73
+ owner: '0xb7e455bac373194f20d5962bd8ae1c0884d3436a',
74
+ vaultId: '83043525982714387441210092990847911536190235553161609246480078437778300461980',
75
+ balance: '0',
76
+ token: {
77
+ id: '0x82af49447d8a07e3bd95bd0d56f35241523fbab1',
78
+ address: '0x82af49447d8a07e3bd95bd0d56f35241523fbab1',
79
+ name: 'Wrapped Ether',
80
+ symbol: 'WETH',
81
+ decimals: '18'
82
+ },
83
+ orderbook: {
84
+ id: '0x550878091b2b1506069f61ae59e3a5484bca9166'
85
+ },
86
+ ordersAsOutput: [
87
+ {
88
+ id: '0x9229dadc45c673afcbc393231d5ab0e15bb65719daa5d58bd85adfca3fd60d48',
89
+ orderHash: '0x522af734207572d3c1d2cff938dc355578391b62b7b5e6f45185c481141416f7',
90
+ active: false
91
+ }
92
+ ],
93
+ ordersAsInput: [],
94
+ balanceChanges: [
95
+ {
96
+ __typename: 'deposit',
97
+ data: {
98
+ id: '0x4085027ab87a1aa27267de3187559dcea51a49bc0dd3789ca65af38c2ba3728e',
99
+ __typename: 'Deposit',
100
+ amount: '504119298720293716',
101
+ newVaultBalance: '504119298720293716',
102
+ oldVaultBalance: '0',
103
+ vault: {
104
+ id: '0x81bd468a9c493e7427ec9b3cafd52cc780a5a0d9074043bcbae608c5f39a6118',
105
+ vault_id: '83043525982714387441210092990847911536190235553161609246480078437778300461980',
106
+ token: {
107
+ id: '0x82af49447d8a07e3bd95bd0d56f35241523fbab1',
108
+ address: '0x82af49447d8a07e3bd95bd0d56f35241523fbab1',
109
+ name: 'Wrapped Ether',
110
+ symbol: 'WETH',
111
+ decimals: '18'
112
+ }
113
+ },
114
+ timestamp: '1733398198',
115
+ transaction: {
116
+ id: '0xa62c5dd249c906d69604dcccf935b490757ba6286eef3744b9b7e991d11c1b0f',
117
+ from: '0xb7e455bac373194f20d5962bd8ae1c0884d3436a',
118
+ blockNumber: '281580844',
119
+ timestamp: '1733398198'
120
+ },
121
+ orderbook: {
122
+ id: '0x550878091b2b1506069f61ae59e3a5484bca9166'
123
+ }
124
+ }
125
+ },
126
+ {
127
+ __typename: 'withdrawal',
128
+ data: {
129
+ id: '0x78cc1de97a4afeedb0b0b11f273b21bedf7642256893073b81b253d1845ac802',
130
+ __typename: 'Withdrawal',
131
+ amount: '-504119298720293716',
132
+ newVaultBalance: '0',
133
+ oldVaultBalance: '504119298720293716',
134
+ vault: {
135
+ id: '0x81bd468a9c493e7427ec9b3cafd52cc780a5a0d9074043bcbae608c5f39a6118',
136
+ vault_id: '83043525982714387441210092990847911536190235553161609246480078437778300461980',
137
+ token: {
138
+ id: '0x82af49447d8a07e3bd95bd0d56f35241523fbab1',
139
+ address: '0x82af49447d8a07e3bd95bd0d56f35241523fbab1',
140
+ name: 'Wrapped Ether',
141
+ symbol: 'WETH',
142
+ decimals: '18'
143
+ }
144
+ },
145
+ timestamp: '1733408176',
146
+ transaction: {
147
+ id: '0xf07aaa0493d64cb42e94ed72c4f47a1e57885dc1d71a1b4586f9cf987fa068ee',
148
+ from: '0xb7e455bac373194f20d5962bd8ae1c0884d3436a',
149
+ blockNumber: '281620727',
150
+ timestamp: '1733408176'
151
+ },
152
+ orderbook: {
153
+ id: '0x550878091b2b1506069f61ae59e3a5484bca9166'
154
+ }
155
+ }
156
+ }
157
+ ]
158
+ }
159
+ ],
160
+ inputs: [
161
+ {
162
+ id: '0x1f97367df62b14b4088b8ea897f1b0adc021001a55397d513f8ff6c39d54b671',
163
+ owner: '0xb7e455bac373194f20d5962bd8ae1c0884d3436a',
164
+ vaultId: '83043525982714387441210092990847911536190235553161609246480078437778300461980',
165
+ balance: '0',
166
+ token: {
167
+ id: '0xaf88d065e77c8cc2239327c5edb3a432268e5831',
168
+ address: '0xaf88d065e77c8cc2239327c5edb3a432268e5831',
169
+ name: 'USD Coin',
170
+ symbol: 'USDC',
171
+ decimals: '6'
172
+ },
173
+ orderbook: {
174
+ id: '0x550878091b2b1506069f61ae59e3a5484bca9166'
175
+ },
176
+ ordersAsOutput: [],
177
+ ordersAsInput: [
178
+ {
179
+ id: '0x9229dadc45c673afcbc393231d5ab0e15bb65719daa5d58bd85adfca3fd60d48',
180
+ orderHash: '0x522af734207572d3c1d2cff938dc355578391b62b7b5e6f45185c481141416f7',
181
+ active: false
182
+ }
183
+ ],
184
+ balanceChanges: []
185
+ }
186
+ ],
187
+ orderbook: {
188
+ id: '0x550878091b2b1506069f61ae59e3a5484bca9166'
189
+ },
190
+ active: false,
191
+ timestampAdded: '1733398040',
192
+ meta: '0xff0a89c674ee7874a300590ac02f2a20302e2063616c63756c6174652d696f202a2f200a7573696e672d776f7264732d66726f6d20307862303632303261413346653764383531373166423761413566313730313164313745363366333832203078623036323032614133466537643835313731664237614135663137303131643137453633663338320a616d6f756e742d65706f6368730a74726164652d65706f6368733a63616c6c3c323e28292c0a6d61782d6f75747075743a2063616c6c3c333e28616d6f756e742d65706f6368732074726164652d65706f636873292c0a696f3a2063616c6c3c343e2874726164652d65706f636873292c0a3a63616c6c3c353e28696f293b0a0a2f2a20312e2068616e646c652d696f202a2f200a6d696e2d616d6f756e743a206d756c28302e303520302e39292c0a3a656e7375726528677265617465722d7468616e2d6f722d657175616c2d746f286f75747075742d7661756c742d64656372656173652829206d696e2d616d6f756e742920224d696e20747261646520616d6f756e742e22292c0a757365643a206765742868617368286f726465722d6861736828292022616d6f756e742d757365642229292c0a3a7365742868617368286f726465722d6861736828292022616d6f756e742d757365642229206164642875736564206f75747075742d7661756c742d6465637265617365282929293b0a0a2f2a20322e206765742d65706f6368202a2f200a696e697469616c2d74696d653a2063616c6c3c363e28292c0a6c6173742d74696d65205f3a2063616c6c3c373e28292c0a6475726174696f6e3a20737562286e6f77282920616e79286c6173742d74696d6520696e697469616c2d74696d6529292c0a746f74616c2d6475726174696f6e3a20737562286e6f77282920696e697469616c2d74696d65292c0a726174696f2d667265657a652d616d6f756e742d65706f6368733a2064697628302e303520302e36292c0a726174696f2d667265657a652d74726164652d65706f6368733a206d756c28726174696f2d667265657a652d616d6f756e742d65706f63687320646976283836343030203336303029292c0a616d6f756e742d65706f6368733a2064697628746f74616c2d6475726174696f6e203836343030292c0a74726164652d65706f6368733a2073617475726174696e672d73756228646976286475726174696f6e20333630302920726174696f2d667265657a652d74726164652d65706f636873293b0a0a2f2a20332e20616d6f756e742d666f722d65706f6368202a2f200a616d6f756e742d65706f6368730a74726164652d65706f6368733a2c0a746f74616c2d617661696c61626c653a206c696e6561722d67726f777468283020302e3620616d6f756e742d65706f636873292c0a757365643a206765742868617368286f726465722d6861736828292022616d6f756e742d757365642229292c0a756e757365643a2073756228746f74616c2d617661696c61626c652075736564292c0a64656361793a2063616c6c3c383e2874726164652d65706f636873292c0a7368792d64656361793a20657665727928677265617465722d7468616e2874726164652d65706f63687320302e303529206465636179292c0a7661726961626c652d636f6d706f6e656e743a2073756228302e3120302e3035292c0a7461726765742d616d6f756e743a2061646428302e3035206d756c287661726961626c652d636f6d706f6e656e74207368792d646563617929292c0a6361707065642d756e757365643a206d696e28756e75736564207461726765742d616d6f756e74293b0a0a2f2a20342e20696f2d666f722d65706f6368202a2f200a65706f63683a2c0a6c6173742d696f3a2063616c6c3c373e28292c0a6d61782d6e6578742d74726164653a20616e79286d756c286c6173742d696f20312e3031292063616c6c3c393e2829292c0a626173656c696e652d6e6578742d74726164653a206d756c286c6173742d696f2030292c0a7265616c2d626173656c696e653a206d617828626173656c696e652d6e6578742d74726164652063616c6c3c31303e2829292c0a7661726961626c652d636f6d706f6e656e743a2073617475726174696e672d737562286d61782d6e6578742d7472616465207265616c2d626173656c696e65292c0a61626f76652d626173656c696e653a206d756c287661726961626c652d636f6d706f6e656e742063616c6c3c383e2865706f636829292c0a5f3a20616464287265616c2d626173656c696e652061626f76652d626173656c696e65293b0a0a2f2a20352e207365742d6c6173742d7472616465202a2f200a6c6173742d696f3a2c0a3a7365742868617368286f726465722d68617368282920226c6173742d74726164652d74696d652229206e6f772829292c0a3a7365742868617368286f726465722d68617368282920226c6173742d74726164652d696f2229206c6173742d696f293b0a0a2f2a20362e206765742d696e697469616c2d74696d65202a2f200a5f3a6765742868617368286f726465722d6861736828292022696e697469616c2d74696d652229293b0a0a2f2a20372e206765742d6c6173742d7472616465202a2f200a6c6173742d74696d653a6765742868617368286f726465722d68617368282920226c6173742d74726164652d74696d652229292c0a6c6173742d696f3a6765742868617368286f726465722d68617368282920226c6173742d74726164652d696f2229293b0a0a2f2a20382e2068616c666c696665202a2f200a65706f63683a2c0a2f2a2a0a202a20536872696e6b696e6720746865206d756c7469706c696572206c696b6520746869730a202a207468656e206170706c79696e672069742031302074696d657320616c6c6f777320666f720a202a2062657474657220707265636973696f6e207768656e206d61782d696f2d726174696f0a202a2069732076657279206c617267652c20652e672e207e31653130206f72207e316532302b0a202a0a202a205468697320776f726b7320626563617573652060706f77657260206c6f7365730a202a20707265636973696f6e206f6e20626173652060302e3560207768656e207468650a202a206578706f6e656e74206973206c6172676520616e642063616e206576656e20676f0a202a20746f20603060207768696c652074686520696f2d726174696f206973207374696c6c0a202a206c617267652e2042657474657220746f206b65657020746865206d756c7469706c6965720a202a2068696768657220707265636973696f6e20616e642064726f702074686520696f2d726174696f0a202a20736d6f6f74686c7920666f72206173206c6f6e672061732077652063616e2e0a202a2f0a6d756c7469706c6965723a0a2020706f77657228302e35206469762865706f636820313029292c0a76616c3a0a20206d756c280a202020206d756c7469706c6965720a202020206d756c7469706c6965720a202020206d756c7469706c6965720a202020206d756c7469706c6965720a202020206d756c7469706c6965720a202020206d756c7469706c6965720a202020206d756c7469706c6965720a202020206d756c7469706c6965720a202020206d756c7469706c6965720a202020206d756c7469706c6965720a2020293b0a0a2f2a20392e20636f6e7374616e742d696e697469616c2d696f202a2f200a5f3a20343030303b0a0a2f2a2031302e20636f6e7374616e742d626173656c696e65202a2f200a5f3a20333933353b011bff13109e41336ff20278186170706c69636174696f6e2f6f637465742d73747265616d',
193
+ addEvents: [
194
+ {
195
+ transaction: {
196
+ id: '0xb47869bda04e3407e41120ae3a031af874fe0b82ba39a99496acffc257180553',
197
+ from: '0xb7e455bac373194f20d5962bd8ae1c0884d3436a',
198
+ blockNumber: '281580211',
199
+ timestamp: '1733398040'
200
+ }
201
+ }
202
+ ],
203
+ trades: []
204
+ };
@@ -0,0 +1,160 @@
1
+ {
2
+ "accounts": {
3
+ "wallet1": "0xf08bCbce72f62c95Dcb7c07dCb5Ed26ACfCfBc11",
4
+ "wallet2": "0x6bc14a99ccf7f9037c98d75eec6c6d807f9d953f"
5
+ },
6
+ "networks": {
7
+ "flare": {
8
+ "rpc": "https://rpc.ankr.com/flare",
9
+ "chain-id": 14,
10
+ "currency": "FLR"
11
+ },
12
+ "base": {
13
+ "rpc": "https://mainnet.base.org",
14
+ "chain-id": 8453,
15
+ "network-id": 8453,
16
+ "currency": "ETH"
17
+ },
18
+ "sepolia": {
19
+ "rpc": "https://1rpc.io/sepolia",
20
+ "chain-id": 11155111,
21
+ "network-id": 11155111,
22
+ "currency": "ETH"
23
+ },
24
+ "polygon": {
25
+ "rpc": "https://rpc.ankr.com/polygon",
26
+ "chain-id": 137,
27
+ "network-id": 137,
28
+ "currency": "POL"
29
+ },
30
+ "arbitrum": {
31
+ "rpc": "https://rpc.ankr.com/arbitrum",
32
+ "chain-id": 42161,
33
+ "network-id": 42161,
34
+ "currency": "ETH"
35
+ },
36
+ "bsc": {
37
+ "rpc": "https://rpc.ankr.com/bsc",
38
+ "chain-id": 56,
39
+ "network-id": 56,
40
+ "currency": "BNB"
41
+ },
42
+ "linea": {
43
+ "rpc": "https://rpc.linea.build",
44
+ "chain-id": 59144,
45
+ "network-id": 59144,
46
+ "currency": "ETH"
47
+ },
48
+ "ethereum": {
49
+ "rpc": "https://rpc.ankr.com/eth",
50
+ "chain-id": 1,
51
+ "network-id": 1,
52
+ "currency": "ETH"
53
+ }
54
+ },
55
+ "subgraphs": {
56
+ "flare": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/ob4-flare/0.8/gn",
57
+ "base": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/ob4-base/0.9/gn",
58
+ "sepolia": "http://replaceme.com",
59
+ "polygon": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/ob4-polygon/0.6/gn",
60
+ "arbitrum": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/ob4-arbitrum/0.2/gn",
61
+ "bsc": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/ob4-bsc/2024-10-14-63f4/gn",
62
+ "linea": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/ob4-linea/2024-10-14-12fc/gn",
63
+ "ethereum": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/ob4-mainnet/2024-10-25-af6a/gn"
64
+ },
65
+ "metaboards": {
66
+ "flare": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/mb-flare-0x893BBFB7/0.1/gn",
67
+ "base": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/mb-base-0x59401C93/0.1/gn",
68
+ "sepolia": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/mb-sepolia-0x77991674/0.1/gn",
69
+ "polygon": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/mb-polygon/0.1/gn",
70
+ "arbitrum": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/mb-arbitrum/0.1/gn",
71
+ "bsc": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/mb-bsc/0.1/gn",
72
+ "linea": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/mb-linea-0xed7d6156/1.0.0/gn",
73
+ "ethereum": "https://api.goldsky.com/api/public/project_clv14x04y9kzi01saerx7bxpg/subgraphs/metadata-mainnet/2024-10-25-2857/gn"
74
+ },
75
+ "orderbooks": {
76
+ "flare": {
77
+ "address": "0xCEe8Cd002F151A536394E564b84076c41bBBcD4d",
78
+ "network": "flare",
79
+ "subgraph": "flare"
80
+ },
81
+ "base": {
82
+ "address": "0xd2938e7c9fe3597f78832ce780feb61945c377d7",
83
+ "network": "base",
84
+ "subgraph": "base"
85
+ },
86
+ "sepolia": {
87
+ "address": "0x0bB72B4C7c0d47b2CaED07c804D9243C1B8a0728",
88
+ "network": "sepolia",
89
+ "subgraph": "sepolia"
90
+ },
91
+ "polygon": {
92
+ "address": "0x7D2f700b1f6FD75734824EA4578960747bdF269A",
93
+ "network": "polygon",
94
+ "subgraph": "polygon"
95
+ },
96
+ "arbitrum": {
97
+ "address": "0x550878091b2B1506069F61ae59e3A5484Bca9166",
98
+ "network": "arbitrum",
99
+ "subgraph": "arbitrum"
100
+ },
101
+ "matchain": {
102
+ "address": "0x40312edab8fe65091354172ad79e9459f21094e2",
103
+ "network": "matchain",
104
+ "subgraph": "matchain"
105
+ },
106
+ "bsc": {
107
+ "address": "0xd2938E7c9fe3597F78832CE780Feb61945c377d7",
108
+ "network": "bsc",
109
+ "subgraph": "bsc"
110
+ },
111
+ "linea": {
112
+ "address": "0x22410e2a46261a1B1e3899a072f303022801C764",
113
+ "network": "linea",
114
+ "subgraph": "linea"
115
+ },
116
+ "ethereum": {
117
+ "address": "0x0eA6d458488d1cf51695e1D6e4744e6FB715d37C",
118
+ "network": "ethereum",
119
+ "subgraph": "ethereum"
120
+ }
121
+ },
122
+ "deployers": {
123
+ "flare": {
124
+ "address": "0xE3989Ea7486c0F418C764e6c511e86f6E8830FAb",
125
+ "network": "flare"
126
+ },
127
+ "base": {
128
+ "address": "0xC1A14cE2fd58A3A2f99deCb8eDd866204eE07f8D",
129
+ "network": "base"
130
+ },
131
+ "sepolia": {
132
+ "address": "0x7692BA8446Bb8B3140A2c02df073080BeD0a7F8E",
133
+ "network": "sepolia"
134
+ },
135
+ "polygon": {
136
+ "address": "0xE7116BC05C8afe25e5B54b813A74F916B5D42aB1",
137
+ "network": "polygon"
138
+ },
139
+ "arbitrum": {
140
+ "address": "0x9B0D254bd858208074De3d2DaF5af11b3D2F377F",
141
+ "network": "arbitrum"
142
+ },
143
+ "matchain": {
144
+ "address": "0x582d9e838FE6cD9F8147C66A8f56A3FBE513a6A2",
145
+ "network": "polygon"
146
+ },
147
+ "bsc": {
148
+ "address": "0xA2f56F8F74B7d04d61f281BE6576b6155581dcBA",
149
+ "network": "bsc"
150
+ },
151
+ "linea": {
152
+ "address": "0xA2f56F8F74B7d04d61f281BE6576b6155581dcBA",
153
+ "network": "linea"
154
+ },
155
+ "ethereum": {
156
+ "address": "0xd19581a021f4704ad4eBfF68258e7A0a9DB1CD77",
157
+ "network": "ethereum"
158
+ }
159
+ }
160
+ }
@@ -0,0 +1 @@
1
+ export declare const props: import("svelte/store").Writable<unknown>;
@@ -0,0 +1,2 @@
1
+ import { writable } from 'svelte/store';
2
+ export const props = writable();
@@ -0,0 +1,3 @@
1
+ <script>import { props } from "./MockComponent";
2
+ $: $props = $$props;
3
+ </script>
@@ -0,0 +1,18 @@
1
+ import { SvelteComponent } from "svelte";
2
+ declare const __propDef: {
3
+ props: {
4
+ [x: string]: any;
5
+ };
6
+ events: {
7
+ [evt: string]: CustomEvent<any>;
8
+ };
9
+ slots: {};
10
+ exports?: undefined;
11
+ bindings?: undefined;
12
+ };
13
+ export type MockComponentProps = typeof __propDef.props;
14
+ export type MockComponentEvents = typeof __propDef.events;
15
+ export type MockComponentSlots = typeof __propDef.slots;
16
+ export default class MockComponent extends SvelteComponent<MockComponentProps, MockComponentEvents, MockComponentSlots> {
17
+ }
18
+ export {};
@@ -0,0 +1,22 @@
1
+ import { TransactionStatus, TransactionErrorMessage } from '../stores/transactionStore';
2
+ type MockTransactionStoreState = {
3
+ status: TransactionStatus;
4
+ error: string;
5
+ hash: string;
6
+ data: null;
7
+ functionName: string;
8
+ message: string;
9
+ };
10
+ export declare const mockTransactionStore: {
11
+ subscribe: (this: void, run: import("svelte/store").Subscriber<MockTransactionStoreState>, invalidate?: import("svelte/store").Invalidator<MockTransactionStoreState> | undefined) => import("svelte/store").Unsubscriber;
12
+ set: (this: void, value: MockTransactionStoreState) => void;
13
+ reset: () => void;
14
+ handleDeploymentTransaction: () => Promise<void>;
15
+ checkingWalletAllowance: (message?: string) => void;
16
+ awaitWalletConfirmation: (message?: string) => void;
17
+ awaitApprovalTx: (hash: string) => void;
18
+ transactionSuccess: (hash: string, message?: string) => void;
19
+ transactionError: (error: TransactionErrorMessage, hash?: string) => void;
20
+ mockSetSubscribeValue: (value: Partial<MockTransactionStoreState>) => void;
21
+ };
22
+ export {};
@@ -0,0 +1,56 @@
1
+ import { writable } from 'svelte/store';
2
+ import { TransactionStatus, TransactionErrorMessage } from '../stores/transactionStore';
3
+ const initialState = {
4
+ status: TransactionStatus.IDLE,
5
+ error: '',
6
+ hash: '',
7
+ data: null,
8
+ functionName: '',
9
+ message: ''
10
+ };
11
+ const mockTransactionWritable = writable(initialState);
12
+ export const mockTransactionStore = {
13
+ subscribe: mockTransactionWritable.subscribe,
14
+ set: mockTransactionWritable.set,
15
+ reset: () => mockTransactionWritable.set(initialState),
16
+ handleDeploymentTransaction: async () => {
17
+ mockTransactionWritable.update((state) => ({
18
+ ...state,
19
+ status: TransactionStatus.SUCCESS,
20
+ message: 'Strategy deployed successfully!',
21
+ hash: '0x123'
22
+ }));
23
+ },
24
+ checkingWalletAllowance: (message = '') => mockTransactionWritable.update((state) => ({
25
+ ...state,
26
+ status: TransactionStatus.CHECKING_ALLOWANCE,
27
+ message
28
+ })),
29
+ awaitWalletConfirmation: (message = '') => mockTransactionWritable.update((state) => ({
30
+ ...state,
31
+ status: TransactionStatus.PENDING_WALLET,
32
+ message
33
+ })),
34
+ awaitApprovalTx: (hash) => mockTransactionWritable.update((state) => ({
35
+ ...state,
36
+ hash,
37
+ status: TransactionStatus.PENDING_APPROVAL,
38
+ message: ''
39
+ })),
40
+ transactionSuccess: (hash, message = '') => mockTransactionWritable.update((state) => ({
41
+ ...state,
42
+ status: TransactionStatus.SUCCESS,
43
+ hash,
44
+ message
45
+ })),
46
+ transactionError: (error, hash = '') => mockTransactionWritable.update((state) => ({
47
+ ...state,
48
+ status: TransactionStatus.ERROR,
49
+ error,
50
+ hash
51
+ })),
52
+ mockSetSubscribeValue: (value) => mockTransactionWritable.update((state) => ({
53
+ ...state,
54
+ ...value
55
+ }))
56
+ };
@@ -0,0 +1,2 @@
1
+ import { type Config } from '@wagmi/core';
2
+ export declare const mockWeb3Config: Config;
@@ -0,0 +1,15 @@
1
+ import { createConfig, http, fallback } from '@wagmi/core';
2
+ import { mock } from '@wagmi/connectors';
3
+ import { polygonAmoy } from '@wagmi/core/chains';
4
+ export const mockWeb3Config = createConfig({
5
+ multiInjectedProviderDiscovery: true,
6
+ chains: [polygonAmoy],
7
+ connectors: [
8
+ mock({
9
+ accounts: ['0xf08bcbce72f62c95dcb7c07dcb5ed26acfcfbc11']
10
+ })
11
+ ],
12
+ transports: {
13
+ [polygonAmoy.id]: fallback([http(), http('https://rpc-amoy.polygon.technology')])
14
+ }
15
+ });