@bloxwap/hig 0.5.2 → 0.6.0

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 (138) hide show
  1. package/README.md +1 -1
  2. package/chart/README.md +1 -1
  3. package/contracts/README.md +1 -1
  4. package/contracts/dist/messages.d.ts +31 -4
  5. package/contracts/dist/messages.js +11 -2
  6. package/feedback/README.md +1 -1
  7. package/native/README.md +1 -1
  8. package/native/dist/account-block.d.ts +46 -0
  9. package/native/dist/account-block.js +28 -0
  10. package/native/dist/asset-balance-row.d.ts +20 -0
  11. package/native/dist/asset-balance-row.js +21 -0
  12. package/native/dist/bar-mark.d.ts +45 -0
  13. package/native/dist/bar-mark.js +34 -0
  14. package/native/dist/bar-pnl.d.ts +50 -0
  15. package/native/dist/bar-pnl.js +59 -0
  16. package/native/dist/blocks.d.ts +44 -0
  17. package/native/dist/{recipes.js → blocks.js} +19 -9
  18. package/native/dist/field.d.ts +0 -1
  19. package/native/dist/field.js +0 -1
  20. package/native/dist/icons.d.ts +8 -0
  21. package/native/dist/icons.js +4 -0
  22. package/native/dist/language-block.d.ts +31 -0
  23. package/native/dist/language-block.js +30 -0
  24. package/native/dist/list-group.d.ts +26 -0
  25. package/native/dist/list-group.js +27 -0
  26. package/native/dist/manage-position-block.d.ts +69 -0
  27. package/native/dist/manage-position-block.js +57 -0
  28. package/native/dist/notifications-block.d.ts +25 -0
  29. package/native/dist/notifications-block.js +14 -0
  30. package/native/dist/pickers.d.ts +12 -4
  31. package/native/dist/pickers.js +6 -2
  32. package/native/dist/position-block.d.ts +51 -0
  33. package/native/dist/position-block.js +21 -0
  34. package/native/dist/profile-block.d.ts +42 -0
  35. package/native/dist/profile-block.js +28 -0
  36. package/native/dist/reward-block.d.ts +83 -0
  37. package/native/dist/reward-block.js +35 -0
  38. package/native/dist/setting-header.d.ts +8 -0
  39. package/native/dist/setting-header.js +11 -0
  40. package/native/dist/setting-switch.d.ts +18 -0
  41. package/native/dist/setting-switch.js +17 -0
  42. package/native/dist/signals-block.d.ts +37 -0
  43. package/native/dist/signals-block.js +16 -0
  44. package/native/dist/sound-haptics-block.d.ts +39 -0
  45. package/native/dist/sound-haptics-block.js +21 -0
  46. package/native/dist/{swap-panel.d.ts → swap-panel-block.d.ts} +6 -2
  47. package/native/dist/{swap-panel.js → swap-panel-block.js} +4 -2
  48. package/native/dist/swap-sheet.d.ts +4 -4
  49. package/native/dist/swap-sheet.js +4 -4
  50. package/native/dist/swap-views.d.ts +1 -1
  51. package/native/dist/swap-views.js +4 -4
  52. package/native/dist/target-block.d.ts +83 -0
  53. package/native/dist/target-block.js +61 -0
  54. package/native/dist/token-action-block.d.ts +39 -0
  55. package/native/dist/token-action-block.js +20 -0
  56. package/native/dist/trade-history-detail-block.d.ts +59 -0
  57. package/native/dist/trade-history-detail-block.js +38 -0
  58. package/native/dist/trade-history-list-block.d.ts +44 -0
  59. package/native/dist/trade-history-list-block.js +29 -0
  60. package/native-fonts/README.md +1 -1
  61. package/og-fonts/README.md +1 -1
  62. package/package.json +246 -41
  63. package/react/README.md +1 -1
  64. package/react/dist/asset-balance-row.d.ts +19 -0
  65. package/react/dist/asset-balance-row.js +10 -0
  66. package/react/dist/bar-mark.d.ts +35 -0
  67. package/react/dist/bar-mark.js +21 -0
  68. package/react/dist/bar-pnl.d.ts +49 -0
  69. package/react/dist/bar-pnl.js +45 -0
  70. package/react/dist/blocks/account-block.d.ts +46 -0
  71. package/react/dist/blocks/account-block.js +27 -0
  72. package/react/dist/blocks/language-block.d.ts +32 -0
  73. package/react/dist/blocks/language-block.js +51 -0
  74. package/react/dist/blocks/manage-position-block.d.ts +67 -0
  75. package/react/dist/blocks/manage-position-block.js +28 -0
  76. package/react/dist/blocks/notifications-block.d.ts +23 -0
  77. package/react/dist/blocks/notifications-block.js +8 -0
  78. package/react/dist/{recipes → blocks}/pickers.d.ts +12 -4
  79. package/react/dist/{recipes → blocks}/pickers.js +6 -2
  80. package/react/dist/blocks/position-block.d.ts +49 -0
  81. package/react/dist/blocks/position-block.js +14 -0
  82. package/react/dist/blocks/profile-block.d.ts +48 -0
  83. package/react/dist/blocks/profile-block.js +15 -0
  84. package/react/dist/blocks/reward-block.d.ts +81 -0
  85. package/react/dist/blocks/reward-block.js +24 -0
  86. package/react/dist/blocks/screen-header.d.ts +9 -0
  87. package/react/dist/blocks/screen-header.js +12 -0
  88. package/react/dist/blocks/setting-switch.d.ts +10 -0
  89. package/react/dist/blocks/setting-switch.js +8 -0
  90. package/react/dist/blocks/signals-block.d.ts +35 -0
  91. package/react/dist/blocks/signals-block.js +15 -0
  92. package/react/dist/blocks/sound-haptics-block.d.ts +37 -0
  93. package/react/dist/blocks/sound-haptics-block.js +18 -0
  94. package/react/dist/{recipes → blocks}/swap/picker.d.ts +1 -1
  95. package/react/dist/{recipes → blocks}/swap/picker.js +4 -4
  96. package/react/dist/{recipes → blocks}/swap/shared.d.ts +1 -0
  97. package/react/dist/{recipes → blocks}/swap/shared.js +1 -0
  98. package/react/dist/{recipes/swap-panel.d.ts → blocks/swap-panel-block.d.ts} +6 -2
  99. package/react/dist/{recipes/swap-panel.js → blocks/swap-panel-block.js} +3 -1
  100. package/react/dist/{recipes → blocks}/swap-sheet.d.ts +4 -4
  101. package/react/dist/{recipes → blocks}/swap-sheet.js +4 -4
  102. package/react/dist/blocks/target-block.d.ts +81 -0
  103. package/react/dist/blocks/target-block.js +65 -0
  104. package/react/dist/blocks/token-action-block.d.ts +37 -0
  105. package/react/dist/blocks/token-action-block.js +18 -0
  106. package/react/dist/{recipes → blocks}/trade-entry.js +2 -2
  107. package/react/dist/blocks/trade-history-detail-block.d.ts +58 -0
  108. package/react/dist/blocks/trade-history-detail-block.js +16 -0
  109. package/react/dist/blocks/trade-history-list-block.d.ts +43 -0
  110. package/react/dist/blocks/trade-history-list-block.js +21 -0
  111. package/react/dist/blocks.d.ts +20 -0
  112. package/react/dist/blocks.js +21 -0
  113. package/react/dist/field.d.ts +0 -2
  114. package/react/dist/field.js +0 -2
  115. package/react/dist/list-group.d.ts +26 -0
  116. package/react/dist/list-group.js +20 -0
  117. package/react/dist/styles.css +270 -5
  118. package/tokens/README.md +1 -1
  119. package/native/dist/recipes.d.ts +0 -46
  120. package/react/dist/recipes/activity-list.d.ts +0 -8
  121. package/react/dist/recipes/activity-list.js +0 -6
  122. package/react/dist/recipes/balance-card.d.ts +0 -6
  123. package/react/dist/recipes/balance-card.js +0 -5
  124. package/react/dist/recipes/code-window.d.ts +0 -4
  125. package/react/dist/recipes/code-window.js +0 -4
  126. package/react/dist/recipes.d.ts +0 -10
  127. package/react/dist/recipes.js +0 -11
  128. /package/react/dist/{recipes → blocks}/install-command.d.ts +0 -0
  129. /package/react/dist/{recipes → blocks}/install-command.js +0 -0
  130. /package/react/dist/{recipes → blocks}/market-row.d.ts +0 -0
  131. /package/react/dist/{recipes → blocks}/market-row.js +0 -0
  132. /package/react/dist/{recipes → blocks}/marketing-hero.d.ts +0 -0
  133. /package/react/dist/{recipes → blocks}/marketing-hero.js +0 -0
  134. /package/react/dist/{recipes → blocks}/swap/amount-card.d.ts +0 -0
  135. /package/react/dist/{recipes → blocks}/swap/amount-card.js +0 -0
  136. /package/react/dist/{recipes → blocks}/swap/settings.d.ts +0 -0
  137. /package/react/dist/{recipes → blocks}/swap/settings.js +0 -0
  138. /package/react/dist/{recipes → blocks}/trade-entry.d.ts +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bloxwap/hig",
3
- "version": "0.5.2",
3
+ "version": "0.6.0",
4
4
  "description": "Bloxwap Human Interface Guidelines: tokens, contracts, React and React Native components, chart adapter, feedback and fonts in one package.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -155,60 +155,90 @@
155
155
  "import": "./react/dist/brand.js",
156
156
  "default": "./react/dist/brand.js"
157
157
  },
158
+ "./react/blocks": {
159
+ "types": "./react/dist/blocks.d.ts",
160
+ "import": "./react/dist/blocks.js",
161
+ "default": "./react/dist/blocks.js"
162
+ },
158
163
  "./react/recipes": {
159
- "types": "./react/dist/recipes.d.ts",
160
- "import": "./react/dist/recipes.js",
161
- "default": "./react/dist/recipes.js"
164
+ "types": "./react/dist/blocks.d.ts",
165
+ "import": "./react/dist/blocks.js",
166
+ "default": "./react/dist/blocks.js"
167
+ },
168
+ "./react/blocks/market-row": {
169
+ "types": "./react/dist/blocks/market-row.d.ts",
170
+ "import": "./react/dist/blocks/market-row.js",
171
+ "default": "./react/dist/blocks/market-row.js"
162
172
  },
163
173
  "./react/recipes/market-row": {
164
- "types": "./react/dist/recipes/market-row.d.ts",
165
- "import": "./react/dist/recipes/market-row.js",
166
- "default": "./react/dist/recipes/market-row.js"
174
+ "types": "./react/dist/blocks/market-row.d.ts",
175
+ "import": "./react/dist/blocks/market-row.js",
176
+ "default": "./react/dist/blocks/market-row.js"
167
177
  },
168
- "./react/recipes/balance-card": {
169
- "types": "./react/dist/recipes/balance-card.d.ts",
170
- "import": "./react/dist/recipes/balance-card.js",
171
- "default": "./react/dist/recipes/balance-card.js"
178
+ "./react/blocks/trade-entry": {
179
+ "types": "./react/dist/blocks/trade-entry.d.ts",
180
+ "import": "./react/dist/blocks/trade-entry.js",
181
+ "default": "./react/dist/blocks/trade-entry.js"
172
182
  },
173
183
  "./react/recipes/trade-entry": {
174
- "types": "./react/dist/recipes/trade-entry.d.ts",
175
- "import": "./react/dist/recipes/trade-entry.js",
176
- "default": "./react/dist/recipes/trade-entry.js"
184
+ "types": "./react/dist/blocks/trade-entry.d.ts",
185
+ "import": "./react/dist/blocks/trade-entry.js",
186
+ "default": "./react/dist/blocks/trade-entry.js"
187
+ },
188
+ "./react/blocks/swap-panel-block": {
189
+ "types": "./react/dist/blocks/swap-panel-block.d.ts",
190
+ "import": "./react/dist/blocks/swap-panel-block.js",
191
+ "default": "./react/dist/blocks/swap-panel-block.js"
192
+ },
193
+ "./react/blocks/swap-panel": {
194
+ "types": "./react/dist/blocks/swap-panel-block.d.ts",
195
+ "import": "./react/dist/blocks/swap-panel-block.js",
196
+ "default": "./react/dist/blocks/swap-panel-block.js"
177
197
  },
178
198
  "./react/recipes/swap-panel": {
179
- "types": "./react/dist/recipes/swap-panel.d.ts",
180
- "import": "./react/dist/recipes/swap-panel.js",
181
- "default": "./react/dist/recipes/swap-panel.js"
199
+ "types": "./react/dist/blocks/swap-panel-block.d.ts",
200
+ "import": "./react/dist/blocks/swap-panel-block.js",
201
+ "default": "./react/dist/blocks/swap-panel-block.js"
202
+ },
203
+ "./react/blocks/pickers": {
204
+ "types": "./react/dist/blocks/pickers.d.ts",
205
+ "import": "./react/dist/blocks/pickers.js",
206
+ "default": "./react/dist/blocks/pickers.js"
182
207
  },
183
208
  "./react/recipes/pickers": {
184
- "types": "./react/dist/recipes/pickers.d.ts",
185
- "import": "./react/dist/recipes/pickers.js",
186
- "default": "./react/dist/recipes/pickers.js"
209
+ "types": "./react/dist/blocks/pickers.d.ts",
210
+ "import": "./react/dist/blocks/pickers.js",
211
+ "default": "./react/dist/blocks/pickers.js"
212
+ },
213
+ "./react/blocks/swap-sheet": {
214
+ "types": "./react/dist/blocks/swap-sheet.d.ts",
215
+ "import": "./react/dist/blocks/swap-sheet.js",
216
+ "default": "./react/dist/blocks/swap-sheet.js"
187
217
  },
188
218
  "./react/recipes/swap-sheet": {
189
- "types": "./react/dist/recipes/swap-sheet.d.ts",
190
- "import": "./react/dist/recipes/swap-sheet.js",
191
- "default": "./react/dist/recipes/swap-sheet.js"
219
+ "types": "./react/dist/blocks/swap-sheet.d.ts",
220
+ "import": "./react/dist/blocks/swap-sheet.js",
221
+ "default": "./react/dist/blocks/swap-sheet.js"
222
+ },
223
+ "./react/blocks/install-command": {
224
+ "types": "./react/dist/blocks/install-command.d.ts",
225
+ "import": "./react/dist/blocks/install-command.js",
226
+ "default": "./react/dist/blocks/install-command.js"
192
227
  },
193
228
  "./react/recipes/install-command": {
194
- "types": "./react/dist/recipes/install-command.d.ts",
195
- "import": "./react/dist/recipes/install-command.js",
196
- "default": "./react/dist/recipes/install-command.js"
229
+ "types": "./react/dist/blocks/install-command.d.ts",
230
+ "import": "./react/dist/blocks/install-command.js",
231
+ "default": "./react/dist/blocks/install-command.js"
197
232
  },
198
- "./react/recipes/code-window": {
199
- "types": "./react/dist/recipes/code-window.d.ts",
200
- "import": "./react/dist/recipes/code-window.js",
201
- "default": "./react/dist/recipes/code-window.js"
233
+ "./react/blocks/marketing-hero": {
234
+ "types": "./react/dist/blocks/marketing-hero.d.ts",
235
+ "import": "./react/dist/blocks/marketing-hero.js",
236
+ "default": "./react/dist/blocks/marketing-hero.js"
202
237
  },
203
238
  "./react/recipes/marketing-hero": {
204
- "types": "./react/dist/recipes/marketing-hero.d.ts",
205
- "import": "./react/dist/recipes/marketing-hero.js",
206
- "default": "./react/dist/recipes/marketing-hero.js"
207
- },
208
- "./react/recipes/activity-list": {
209
- "types": "./react/dist/recipes/activity-list.d.ts",
210
- "import": "./react/dist/recipes/activity-list.js",
211
- "default": "./react/dist/recipes/activity-list.js"
239
+ "types": "./react/dist/blocks/marketing-hero.d.ts",
240
+ "import": "./react/dist/blocks/marketing-hero.js",
241
+ "default": "./react/dist/blocks/marketing-hero.js"
212
242
  },
213
243
  "./react/css": {
214
244
  "types": "./css.d.ts",
@@ -228,6 +258,91 @@
228
258
  "import": "./react/dist/wallet-address.js",
229
259
  "default": "./react/dist/wallet-address.js"
230
260
  },
261
+ "./react/asset-balance-row": {
262
+ "types": "./react/dist/asset-balance-row.d.ts",
263
+ "import": "./react/dist/asset-balance-row.js",
264
+ "default": "./react/dist/asset-balance-row.js"
265
+ },
266
+ "./react/blocks/account-block": {
267
+ "types": "./react/dist/blocks/account-block.d.ts",
268
+ "import": "./react/dist/blocks/account-block.js",
269
+ "default": "./react/dist/blocks/account-block.js"
270
+ },
271
+ "./react/blocks/token-action-block": {
272
+ "types": "./react/dist/blocks/token-action-block.d.ts",
273
+ "import": "./react/dist/blocks/token-action-block.js",
274
+ "default": "./react/dist/blocks/token-action-block.js"
275
+ },
276
+ "./react/blocks/language-block": {
277
+ "types": "./react/dist/blocks/language-block.d.ts",
278
+ "import": "./react/dist/blocks/language-block.js",
279
+ "default": "./react/dist/blocks/language-block.js"
280
+ },
281
+ "./react/blocks/manage-position-block": {
282
+ "types": "./react/dist/blocks/manage-position-block.d.ts",
283
+ "import": "./react/dist/blocks/manage-position-block.js",
284
+ "default": "./react/dist/blocks/manage-position-block.js"
285
+ },
286
+ "./react/blocks/target-block": {
287
+ "types": "./react/dist/blocks/target-block.d.ts",
288
+ "import": "./react/dist/blocks/target-block.js",
289
+ "default": "./react/dist/blocks/target-block.js"
290
+ },
291
+ "./react/blocks/position-block": {
292
+ "types": "./react/dist/blocks/position-block.d.ts",
293
+ "import": "./react/dist/blocks/position-block.js",
294
+ "default": "./react/dist/blocks/position-block.js"
295
+ },
296
+ "./react/blocks/reward-block": {
297
+ "types": "./react/dist/blocks/reward-block.d.ts",
298
+ "import": "./react/dist/blocks/reward-block.js",
299
+ "default": "./react/dist/blocks/reward-block.js"
300
+ },
301
+ "./react/blocks/sound-haptics-block": {
302
+ "types": "./react/dist/blocks/sound-haptics-block.d.ts",
303
+ "import": "./react/dist/blocks/sound-haptics-block.js",
304
+ "default": "./react/dist/blocks/sound-haptics-block.js"
305
+ },
306
+ "./react/blocks/signals-block": {
307
+ "types": "./react/dist/blocks/signals-block.d.ts",
308
+ "import": "./react/dist/blocks/signals-block.js",
309
+ "default": "./react/dist/blocks/signals-block.js"
310
+ },
311
+ "./react/blocks/notifications-block": {
312
+ "types": "./react/dist/blocks/notifications-block.d.ts",
313
+ "import": "./react/dist/blocks/notifications-block.js",
314
+ "default": "./react/dist/blocks/notifications-block.js"
315
+ },
316
+ "./react/blocks/trade-history-list-block": {
317
+ "types": "./react/dist/blocks/trade-history-list-block.d.ts",
318
+ "import": "./react/dist/blocks/trade-history-list-block.js",
319
+ "default": "./react/dist/blocks/trade-history-list-block.js"
320
+ },
321
+ "./react/blocks/trade-history-detail-block": {
322
+ "types": "./react/dist/blocks/trade-history-detail-block.d.ts",
323
+ "import": "./react/dist/blocks/trade-history-detail-block.js",
324
+ "default": "./react/dist/blocks/trade-history-detail-block.js"
325
+ },
326
+ "./react/blocks/profile-block": {
327
+ "types": "./react/dist/blocks/profile-block.d.ts",
328
+ "import": "./react/dist/blocks/profile-block.js",
329
+ "default": "./react/dist/blocks/profile-block.js"
330
+ },
331
+ "./react/bar-mark": {
332
+ "types": "./react/dist/bar-mark.d.ts",
333
+ "import": "./react/dist/bar-mark.js",
334
+ "default": "./react/dist/bar-mark.js"
335
+ },
336
+ "./react/bar-pnl": {
337
+ "types": "./react/dist/bar-pnl.d.ts",
338
+ "import": "./react/dist/bar-pnl.js",
339
+ "default": "./react/dist/bar-pnl.js"
340
+ },
341
+ "./react/list-group": {
342
+ "types": "./react/dist/list-group.d.ts",
343
+ "import": "./react/dist/list-group.js",
344
+ "default": "./react/dist/list-group.js"
345
+ },
231
346
  "./react/gesture-sheet": {
232
347
  "types": "./react/dist/gesture-sheet.d.ts",
233
348
  "import": "./react/dist/gesture-sheet.js",
@@ -243,6 +358,91 @@
243
358
  "import": "./native/dist/wallet-address.js",
244
359
  "default": "./native/dist/wallet-address.js"
245
360
  },
361
+ "./native/asset-balance-row": {
362
+ "types": "./native/dist/asset-balance-row.d.ts",
363
+ "import": "./native/dist/asset-balance-row.js",
364
+ "default": "./native/dist/asset-balance-row.js"
365
+ },
366
+ "./native/account-block": {
367
+ "types": "./native/dist/account-block.d.ts",
368
+ "import": "./native/dist/account-block.js",
369
+ "default": "./native/dist/account-block.js"
370
+ },
371
+ "./native/token-action-block": {
372
+ "types": "./native/dist/token-action-block.d.ts",
373
+ "import": "./native/dist/token-action-block.js",
374
+ "default": "./native/dist/token-action-block.js"
375
+ },
376
+ "./native/language-block": {
377
+ "types": "./native/dist/language-block.d.ts",
378
+ "import": "./native/dist/language-block.js",
379
+ "default": "./native/dist/language-block.js"
380
+ },
381
+ "./native/manage-position-block": {
382
+ "types": "./native/dist/manage-position-block.d.ts",
383
+ "import": "./native/dist/manage-position-block.js",
384
+ "default": "./native/dist/manage-position-block.js"
385
+ },
386
+ "./native/target-block": {
387
+ "types": "./native/dist/target-block.d.ts",
388
+ "import": "./native/dist/target-block.js",
389
+ "default": "./native/dist/target-block.js"
390
+ },
391
+ "./native/position-block": {
392
+ "types": "./native/dist/position-block.d.ts",
393
+ "import": "./native/dist/position-block.js",
394
+ "default": "./native/dist/position-block.js"
395
+ },
396
+ "./native/reward-block": {
397
+ "types": "./native/dist/reward-block.d.ts",
398
+ "import": "./native/dist/reward-block.js",
399
+ "default": "./native/dist/reward-block.js"
400
+ },
401
+ "./native/sound-haptics-block": {
402
+ "types": "./native/dist/sound-haptics-block.d.ts",
403
+ "import": "./native/dist/sound-haptics-block.js",
404
+ "default": "./native/dist/sound-haptics-block.js"
405
+ },
406
+ "./native/signals-block": {
407
+ "types": "./native/dist/signals-block.d.ts",
408
+ "import": "./native/dist/signals-block.js",
409
+ "default": "./native/dist/signals-block.js"
410
+ },
411
+ "./native/notifications-block": {
412
+ "types": "./native/dist/notifications-block.d.ts",
413
+ "import": "./native/dist/notifications-block.js",
414
+ "default": "./native/dist/notifications-block.js"
415
+ },
416
+ "./native/trade-history-list-block": {
417
+ "types": "./native/dist/trade-history-list-block.d.ts",
418
+ "import": "./native/dist/trade-history-list-block.js",
419
+ "default": "./native/dist/trade-history-list-block.js"
420
+ },
421
+ "./native/trade-history-detail-block": {
422
+ "types": "./native/dist/trade-history-detail-block.d.ts",
423
+ "import": "./native/dist/trade-history-detail-block.js",
424
+ "default": "./native/dist/trade-history-detail-block.js"
425
+ },
426
+ "./native/profile-block": {
427
+ "types": "./native/dist/profile-block.d.ts",
428
+ "import": "./native/dist/profile-block.js",
429
+ "default": "./native/dist/profile-block.js"
430
+ },
431
+ "./native/bar-mark": {
432
+ "types": "./native/dist/bar-mark.d.ts",
433
+ "import": "./native/dist/bar-mark.js",
434
+ "default": "./native/dist/bar-mark.js"
435
+ },
436
+ "./native/bar-pnl": {
437
+ "types": "./native/dist/bar-pnl.d.ts",
438
+ "import": "./native/dist/bar-pnl.js",
439
+ "default": "./native/dist/bar-pnl.js"
440
+ },
441
+ "./native/list-group": {
442
+ "types": "./native/dist/list-group.d.ts",
443
+ "import": "./native/dist/list-group.js",
444
+ "default": "./native/dist/list-group.js"
445
+ },
246
446
  "./native/pickers": {
247
447
  "types": "./native/dist/pickers.d.ts",
248
448
  "import": "./native/dist/pickers.js",
@@ -303,10 +503,15 @@
303
503
  "import": "./native/dist/brand.js",
304
504
  "default": "./native/dist/brand.js"
305
505
  },
506
+ "./native/blocks": {
507
+ "types": "./native/dist/blocks.d.ts",
508
+ "import": "./native/dist/blocks.js",
509
+ "default": "./native/dist/blocks.js"
510
+ },
306
511
  "./native/recipes": {
307
- "types": "./native/dist/recipes.d.ts",
308
- "import": "./native/dist/recipes.js",
309
- "default": "./native/dist/recipes.js"
512
+ "types": "./native/dist/blocks.d.ts",
513
+ "import": "./native/dist/blocks.js",
514
+ "default": "./native/dist/blocks.js"
310
515
  },
311
516
  "./native/switch": {
312
517
  "types": "./native/dist/switch.d.ts",
package/react/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @bloxwap/hig/react
2
2
 
3
- Version 0.5.2, an entry of `@bloxwap/hig`. Import individual entries; see docs/components for platform and accessibility contracts.
3
+ Version 0.6.0, an entry of `@bloxwap/hig`. Import individual entries; see docs/components for platform and accessibility contracts.
4
4
 
5
5
  Set a brand accent with `<HIGProvider primaryColor='#ff0000'>` from
6
6
  `@bloxwap/hig/react/provider`. It accepts opaque sRGB hex (`#RGB` or `#RRGGBB`),
@@ -0,0 +1,19 @@
1
+ import React from 'react';
2
+ /** Artwork for an asset: an image URL, or an element the host draws. */
3
+ export type AssetArtwork = string | React.ReactElement;
4
+ export interface AssetBalanceRowProps extends Omit<React.HTMLAttributes<HTMLElement>, 'onSelect'> {
5
+ name: string;
6
+ symbol: string;
7
+ /** A missing icon falls back to the first letters of the symbol. */
8
+ icon?: AssetArtwork;
9
+ /** Dollar value of the holding. `null` reads as unknown. */
10
+ value?: number | null;
11
+ /** The holding in token units, shown under the value. Omit it to show the value alone, as for a dollar stablecoin. */
12
+ balance?: number | null;
13
+ /** Format of the units line. Defaults to at most six fraction digits. */
14
+ balanceOptions?: Intl.NumberFormatOptions;
15
+ /** Makes the whole row a button. */
16
+ onSelect?: () => void;
17
+ }
18
+ /** One holding in a list: round artwork, the asset's name over its symbol, and its dollar value over its units. Both numbers update place by place. */
19
+ export declare function AssetBalanceRow({ name, symbol, icon, value, balance, balanceOptions, onSelect, className, ...rest }: AssetBalanceRowProps): React.JSX.Element;
@@ -0,0 +1,10 @@
1
+ "use client";
2
+ import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import { AnimatedNumberReadout } from './animated-number.js';
4
+ const usd = { style: 'currency', currency: 'USD' }, units = { maximumFractionDigits: 6 };
5
+ /** One holding in a list: round artwork, the asset's name over its symbol, and its dollar value over its units. Both numbers update place by place. */
6
+ export function AssetBalanceRow({ name, symbol, icon, value, balance, balanceOptions = units, onSelect, className, ...rest }) {
7
+ const content = _jsxs(_Fragment, { children: [_jsx("span", { className: 'hig-asset-row-icon', "aria-hidden": 'true', children: typeof icon === 'string' ? _jsx("img", { src: icon, alt: '' }) : icon ?? symbol.slice(0, 3) }), _jsxs("span", { className: 'hig-asset-row-identity', children: [_jsx("strong", { children: name }), _jsx("span", { children: symbol })] }), _jsxs("span", { className: 'hig-asset-row-amounts', children: [_jsx("strong", { children: _jsx(AnimatedNumberReadout, { value: value, options: usd }) }), balance !== undefined && _jsx("span", { children: _jsx(AnimatedNumberReadout, { value: balance, options: balanceOptions }) })] })] });
8
+ const classes = `hig-asset-row${className ? ` ${className}` : ''}`;
9
+ return onSelect ? _jsx("button", { type: 'button', ...rest, className: classes, onClick: onSelect, children: content }) : _jsx("div", { ...rest, className: classes, children: content });
10
+ }
@@ -0,0 +1,35 @@
1
+ import React from 'react';
2
+ /** Colour roles a segment can take. They follow the token palette (and a host's market colours) like any other role. */
3
+ export type BarMarkTone = 'positive' | 'info' | 'warning' | 'negative' | 'muted' | 'faint';
4
+ /** The order segments take tones in when they name neither a `tone` nor a `color`. */
5
+ export declare const barMarkTones: readonly BarMarkTone[];
6
+ /** One part of the bar. `value` is in the host's own unit; only its share of the whole is drawn. `detail` is host-formatted text shown after the label, such as `12.4 GB`. `color` is a host hex for a category outside the tone roles. */
7
+ export interface BarMarkElement {
8
+ id?: string;
9
+ label: string;
10
+ value: number;
11
+ tone?: BarMarkTone;
12
+ color?: string;
13
+ detail?: string;
14
+ }
15
+ export interface BarMarkProps extends Omit<React.HTMLAttributes<HTMLElement>, 'title'> {
16
+ title: string;
17
+ /** A line on the trailing edge of the title row, such as `59.2 GB of 64 GB used`. */
18
+ description?: React.ReactNode;
19
+ elements: readonly BarMarkElement[];
20
+ /** The whole the elements are parts of. When it is larger than their sum the remainder stays empty track. Defaults to the sum. */
21
+ total?: number;
22
+ /** Set false to hide the legend; the labels and shares stay available to assistive technology. */
23
+ legend?: boolean;
24
+ /** `small` draws a 12-unit bar for a secondary breakdown under a main one. */
25
+ size?: 'default' | 'small';
26
+ /** Set false to draw no card: no surface fill, padding or radius. The title row, bar and legend keep their spacing. Default `true`. */
27
+ surface?: boolean;
28
+ }
29
+ /** Shares of the whole for each element, and the empty remainder, as fractions of 1. Negative and non-finite values count as nothing. */
30
+ export declare function barMarkShares(elements: readonly BarMarkElement[], total?: number): {
31
+ shares: number[];
32
+ rest: number;
33
+ };
34
+ /** A one-dimensional stacked bar: a titled card whose single bar is divided among its elements, with a legend naming each part. */
35
+ export declare function BarMark({ title, description, elements, total, legend, size, surface, className, ...rest }: BarMarkProps): React.JSX.Element;
@@ -0,0 +1,21 @@
1
+ "use client";
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import { useId } from 'react';
4
+ import { formatNumber } from '@bloxwap/hig/contracts';
5
+ import { useHIG } from './provider.js';
6
+ /** The order segments take tones in when they name neither a `tone` nor a `color`. */
7
+ export const barMarkTones = ['positive', 'info', 'warning', 'negative', 'muted', 'faint'];
8
+ const amount = (value) => Number.isFinite(value) && value > 0 ? value : 0;
9
+ /** Shares of the whole for each element, and the empty remainder, as fractions of 1. Negative and non-finite values count as nothing. */
10
+ export function barMarkShares(elements, total) {
11
+ const values = elements.map(element => amount(element.value)), sum = values.reduce((a, b) => a + b, 0), whole = Math.max(amount(total ?? 0), sum);
12
+ return whole > 0 ? { shares: values.map(value => value / whole), rest: (whole - sum) / whole } : { shares: values.map(() => 0), rest: 1 };
13
+ }
14
+ /** A one-dimensional stacked bar: a titled card whose single bar is divided among its elements, with a legend naming each part. */
15
+ export function BarMark({ title, description, elements, total, legend = true, size = 'default', surface = true, className, ...rest }) {
16
+ const { locale } = useHIG();
17
+ const id = useId();
18
+ const { shares, rest: remainder } = barMarkShares(elements, total);
19
+ const paint = (element, index) => element.color ? { style: { '--hig-bar-mark-color': element.color } } : { 'data-tone': element.tone ?? barMarkTones[index % barMarkTones.length] };
20
+ return _jsxs("section", { ...rest, className: `${surface ? 'hig-surface ' : ''}hig-bar-mark${className ? ` ${className}` : ''}`, "data-surface": surface ? undefined : 'false', "data-size": size === 'small' ? size : undefined, "aria-labelledby": id, children: [_jsxs("div", { className: 'hig-bar-mark-header', children: [_jsx("strong", { id: id, className: 'hig-bar-mark-title', children: title }), description != null && _jsx("span", { className: 'hig-bar-mark-description', children: description })] }), _jsxs("div", { className: 'hig-bar-mark-bar', "aria-hidden": 'true', children: [elements.map((element, index) => shares[index] > 0 && _jsx("span", { className: 'hig-bar-mark-segment', ...paint(element, index), style: { ...paint(element, index).style, flexGrow: shares[index] } }, element.id ?? index)), remainder > 0 && _jsx("span", { className: 'hig-bar-mark-rest', style: { flexGrow: remainder } })] }), _jsx("ul", { className: legend ? 'hig-bar-mark-legend' : 'hig-sr-only', children: elements.map((element, index) => _jsxs("li", { children: [_jsx("span", { className: 'hig-bar-mark-dot', "aria-hidden": 'true', ...paint(element, index) }), _jsx("span", { children: element.label }), element.detail && _jsx("span", { className: 'hig-bar-mark-detail', children: element.detail }), _jsx("span", { className: 'hig-sr-only', children: formatNumber(shares[index], locale, { style: 'percent', maximumFractionDigits: 1 }) })] }, element.id ?? index)) })] });
21
+ }
@@ -0,0 +1,49 @@
1
+ import React from 'react';
2
+ export type BarPnlSide = 'long' | 'short';
3
+ export type BarPnlResult = 'profit' | 'loss' | 'flat';
4
+ export type BarPnlKind = 'liquidation' | 'mark' | 'entry';
5
+ export interface BarPnlProps extends Omit<React.HTMLAttributes<HTMLElement>, 'title'> {
6
+ /** Price the position was opened at. */
7
+ entry: number;
8
+ /** Current mark price. `null` or omitted reads as unknown and draws no profit or loss. */
9
+ mark?: number | null;
10
+ /** Liquidation price. Omit it, or pass `null`, for a position that cannot be liquidated. */
11
+ liquidation?: number | null;
12
+ /** Direction of the position. Defaults to `long` when the liquidation price is below entry (or unknown) and `short` when it is above. */
13
+ side?: BarPnlSide;
14
+ /** Host text for the three prices, for example `{liquidation:'Liquidation',mark:'Mark',entry:'Entry'}`. HIG ships no trading terms of its own. */
15
+ labels: Record<BarPnlKind, string>;
16
+ /** Heading on the leading edge above the bar, such as `BTC Long 10×`. */
17
+ title?: string;
18
+ /** A line on the trailing edge of the title row, such as the profit or loss in dollars. */
19
+ description?: React.ReactNode;
20
+ /** Format of the three prices. Defaults to US dollars. */
21
+ priceOptions?: Intl.NumberFormatOptions;
22
+ /** Shortens the three prices for narrow screens: `$64,700` for `$64,700.00`, `$142.96`, `$0.4821`. Trailing zeros are dropped. Default `false`. */
23
+ compact?: boolean;
24
+ /** Scales the bar to the prices themselves, so the stretch from entry to mark fills it. For a finished trade, where the move is the whole story. Default `false`. */
25
+ fit?: boolean;
26
+ /** Set false to draw no card: no surface fill, padding or radius. The title row, bar and readouts keep their spacing. Default `true`. */
27
+ surface?: boolean;
28
+ }
29
+ /** Price format for `compact`: no fraction at 1,000 and above, at most two fraction digits from 1, and four significant digits below 1, with trailing zeros dropped. Host `priceOptions` (such as the currency) are kept. */
30
+ export declare function barPnlCompactOptions(value: number | null | undefined, base?: Intl.NumberFormatOptions): Intl.NumberFormatOptions;
31
+ /**
32
+ * Where each price sits on the bar, as a fraction of its width from the low-price edge, the readouts in price order, and
33
+ * whether the position is in profit. With a liquidation price the bar runs from it to the same distance on the other side
34
+ * of entry, so entry sits in the middle; a mark beyond either end stretches the bar. Without one the bar is centred on entry.
35
+ */
36
+ export declare function barPnlLayout({ entry, mark, liquidation, side, fit }: {
37
+ entry: number;
38
+ mark?: number | null;
39
+ liquidation?: number | null;
40
+ side?: BarPnlSide;
41
+ fit?: boolean;
42
+ }): {
43
+ side: BarPnlSide;
44
+ result: BarPnlResult;
45
+ positions: Partial<Record<BarPnlKind, number>>;
46
+ order: BarPnlKind[];
47
+ };
48
+ /** A position's profit or loss as one bar: the stretch between entry and mark is filled solid in the result colour, a tick marks each price, and the liquidation, mark and entry prices read under the bar in price order, so mark and entry trade places as the position moves. */
49
+ export declare function BarPnl({ entry, mark, liquidation, side, labels, title, description, priceOptions, compact, fit, surface, className, ...rest }: BarPnlProps): React.JSX.Element;
@@ -0,0 +1,45 @@
1
+ "use client";
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import { useId } from 'react';
4
+ import { AnimatedNumberReadout } from './animated-number.js';
5
+ const usd = { style: 'currency', currency: 'USD' };
6
+ const finite = (value) => typeof value === 'number' && Number.isFinite(value);
7
+ /** Price format for `compact`: no fraction at 1,000 and above, at most two fraction digits from 1, and four significant digits below 1, with trailing zeros dropped. Host `priceOptions` (such as the currency) are kept. */
8
+ export function barPnlCompactOptions(value, base = usd) {
9
+ const size = finite(value) ? Math.abs(value) : 0;
10
+ return size > 0 && size < 1 ? { ...base, minimumFractionDigits: undefined, maximumFractionDigits: undefined, maximumSignificantDigits: 4 } : { ...base, minimumFractionDigits: 0, maximumFractionDigits: size >= 1000 ? 0 : 2 };
11
+ }
12
+ /**
13
+ * Where each price sits on the bar, as a fraction of its width from the low-price edge, the readouts in price order, and
14
+ * whether the position is in profit. With a liquidation price the bar runs from it to the same distance on the other side
15
+ * of entry, so entry sits in the middle; a mark beyond either end stretches the bar. Without one the bar is centred on entry.
16
+ */
17
+ export function barPnlLayout({ entry, mark, liquidation, side, fit }) {
18
+ const liq = finite(liquidation) ? liquidation : null;
19
+ const direction = side ?? (liq !== null && liq > entry ? 'short' : 'long');
20
+ const result = !finite(entry) || !finite(mark) || mark === entry ? 'flat' : (mark > entry) === (direction === 'long') ? 'profit' : 'loss';
21
+ if (!finite(entry))
22
+ return { side: direction, result, positions: {}, order: [] };
23
+ const price = finite(mark) ? mark : entry;
24
+ const reach = liq !== null ? Math.abs(entry - liq) : Math.max(Math.abs(price - entry) * 2, Math.abs(entry) * 0.01, Number.MIN_VALUE);
25
+ // `fit` scales the bar to the prices themselves, so the stretch from entry to mark fills it.
26
+ const points = liq !== null ? [entry, price, liq] : [entry, price];
27
+ const low = fit ? Math.min(...points) : Math.min(entry - reach, price), high = fit ? Math.max(...points) : Math.max(entry + reach, price), span = high - low;
28
+ const at = (value) => span > 0 ? Math.min(1, Math.max(0, (value - low) / span)) : 0.5;
29
+ const positions = { entry: at(entry), mark: at(price) };
30
+ if (liq !== null)
31
+ positions.liquidation = at(liq);
32
+ // Ties keep liquidation outermost and put mark on the side it would move to next.
33
+ const rank = { liquidation: direction === 'long' ? 0 : 2, entry: 1, mark: direction === 'long' ? (result === 'loss' ? 0.5 : 1.5) : (result === 'loss' ? 1.5 : 0.5) };
34
+ const values = { liquidation: liq ?? 0, entry, mark: price };
35
+ const order = Object.keys(positions).sort((a, b) => values[a] - values[b] || rank[a] - rank[b]);
36
+ return { side: direction, result, positions, order };
37
+ }
38
+ /** A position's profit or loss as one bar: the stretch between entry and mark is filled solid in the result colour, a tick marks each price, and the liquidation, mark and entry prices read under the bar in price order, so mark and entry trade places as the position moves. */
39
+ export function BarPnl({ entry, mark, liquidation, side, labels, title, description, priceOptions = usd, compact = false, fit = false, surface = true, className, ...rest }) {
40
+ const id = useId();
41
+ const { result, positions, order } = barPnlLayout({ entry, mark, liquidation, side, fit });
42
+ const from = Math.min(positions.entry ?? 0.5, positions.mark ?? 0.5), to = Math.max(positions.entry ?? 0.5, positions.mark ?? 0.5);
43
+ const values = { liquidation, mark, entry };
44
+ return _jsxs("section", { ...rest, className: `${surface ? 'hig-surface ' : ''}hig-bar-pnl${className ? ` ${className}` : ''}`, "data-surface": surface ? undefined : 'false', "data-result": result, "aria-labelledby": title ? id : undefined, children: [(title || description != null) && _jsxs("div", { className: 'hig-bar-mark-header', children: [title && _jsx("strong", { id: id, className: 'hig-bar-mark-title', children: title }), description != null && _jsx("span", { className: 'hig-bar-mark-description', children: description })] }), _jsxs("div", { className: 'hig-bar-pnl-bar', "aria-hidden": 'true', children: [_jsx("span", { className: 'hig-bar-pnl-rest', style: { flexGrow: from } }), _jsx("span", { className: 'hig-bar-pnl-move', "data-lead": (positions.mark ?? 0) < (positions.entry ?? 0) ? 'mark' : 'entry', style: { flexGrow: to - from } }), _jsx("span", { className: 'hig-bar-pnl-rest', style: { flexGrow: 1 - to } }), positions.liquidation !== undefined && _jsx("span", { className: 'hig-bar-pnl-liquidation', style: { insetInlineStart: `${positions.liquidation * 100}%` } })] }), _jsx("dl", { className: 'hig-bar-pnl-readouts', children: order.map(kind => _jsxs("div", { "data-kind": kind, children: [_jsx("dt", { children: labels[kind] }), _jsx("dd", { children: _jsx(AnimatedNumberReadout, { value: values[kind], options: compact ? barPnlCompactOptions(values[kind], priceOptions) : priceOptions }) })] }, kind)) })] });
45
+ }
@@ -0,0 +1,46 @@
1
+ import React from 'react';
2
+ import { type AssetArtwork } from '../asset-balance-row.js';
3
+ export { AssetBalanceRow, type AssetArtwork, type AssetBalanceRowProps } from '../asset-balance-row.js';
4
+ /** One holding of the account. The host supplies every figure; HIG sorts, formats and lays it out. */
5
+ export interface AccountAsset {
6
+ id: string;
7
+ name: string;
8
+ symbol: string;
9
+ icon?: AssetArtwork;
10
+ /** Holding in token units. */
11
+ balance?: number | null;
12
+ /** USD per unit, when the host knows it. */
13
+ price?: number | null;
14
+ /** Dollar value of the holding. Defaults to `balance × price`. */
15
+ value?: number | null;
16
+ }
17
+ export interface AccountBlockProps extends Omit<React.HTMLAttributes<HTMLElement>, 'title'> {
18
+ /** Heading. Defaults to the built-in “Account”. */
19
+ title?: string;
20
+ /** Shows Back on the leading edge of the header. */
21
+ onBack?: () => void;
22
+ /** Shows a QR button on the trailing edge of the header, above the deposit action. The host shows the account address, for example with `WalletAddress`. */
23
+ onShowAddress?: () => void;
24
+ /** A control on the trailing edge of the header, usually an `IconButton`. Replaces the QR button. */
25
+ headerAction?: React.ReactNode;
26
+ /** Total in dollars. Defaults to the sum of the asset values; `null` reads as unknown. */
27
+ balance?: number | null;
28
+ assets: readonly AccountAsset[];
29
+ /** Symbol of the asset that is always first. Defaults to `USDC`. */
30
+ pinnedSymbol?: string;
31
+ /** Shows the deposit action beside the total. */
32
+ onDeposit?: () => void;
33
+ /** Text of the deposit action. Defaults to the built-in “Deposit”. */
34
+ depositLabel?: string;
35
+ /** Makes each row a button that reports its asset. */
36
+ onAssetSelect?: (asset: AccountAsset) => void;
37
+ }
38
+ /** Dollar value of a holding: its `value`, or `balance × price` when both are known. */
39
+ export declare const assetValue: (asset: AccountAsset) => number | null;
40
+ /** The account's rows in display order: the pinned asset (a zero placeholder when the account does not hold it), then every other asset by dollar value, largest first, unknown values last and ties by name. */
41
+ export declare function accountRows(assets: readonly AccountAsset[], pinnedSymbol?: string): {
42
+ pinned: AccountAsset;
43
+ rest: AccountAsset[];
44
+ };
45
+ /** An account at a glance: a header, the total with a deposit action, the pinned dollar balance, then every other holding by value. */
46
+ export declare function AccountBlock({ title, onBack, onShowAddress, headerAction, balance, assets, pinnedSymbol, onDeposit, depositLabel, onAssetSelect, className, ...rest }: AccountBlockProps): React.JSX.Element;
@@ -0,0 +1,27 @@
1
+ "use client";
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import * as en from '@bloxwap/hig/contracts/messages';
4
+ import { useHIG } from '../provider.js';
5
+ import { Button } from '../button.js';
6
+ import { AnimatedNumberReadout } from '../animated-number.js';
7
+ import { AssetBalanceRow } from '../asset-balance-row.js';
8
+ import { ScreenHeader, qrIcon } from './screen-header.js';
9
+ export { AssetBalanceRow } from '../asset-balance-row.js';
10
+ const usdCoin = 'USD Coin', usd = { style: 'currency', currency: 'USD' };
11
+ /** Dollar value of a holding: its `value`, or `balance × price` when both are known. */
12
+ export const assetValue = (asset) => asset.value !== undefined ? asset.value : asset.balance != null && asset.price != null ? asset.balance * asset.price : null;
13
+ /** The account's rows in display order: the pinned asset (a zero placeholder when the account does not hold it), then every other asset by dollar value, largest first, unknown values last and ties by name. */
14
+ export function accountRows(assets, pinnedSymbol = 'USDC') {
15
+ const index = assets.findIndex(asset => asset.symbol.toUpperCase() === pinnedSymbol.toUpperCase());
16
+ const pinned = index >= 0 ? assets[index] : { id: pinnedSymbol, name: pinnedSymbol === 'USDC' ? usdCoin : pinnedSymbol, symbol: pinnedSymbol, balance: 0, value: 0 };
17
+ const rest = assets.filter((_, position) => position !== index).sort((a, b) => { const left = assetValue(a), right = assetValue(b); return left === right ? a.name.localeCompare(b.name) : left === null ? 1 : right === null ? -1 : right - left || a.name.localeCompare(b.name); });
18
+ return { pinned, rest };
19
+ }
20
+ /** An account at a glance: a header, the total with a deposit action, the pinned dollar balance, then every other holding by value. */
21
+ export function AccountBlock({ title, onBack, onShowAddress, headerAction, balance, assets, pinnedSymbol = 'USDC', onDeposit, depositLabel, onAssetSelect, className, ...rest }) {
22
+ const { messages } = useHIG();
23
+ const { pinned, rest: others } = accountRows(assets, pinnedSymbol);
24
+ const total = balance !== undefined ? balance : assets.reduce((sum, asset) => sum + (assetValue(asset) ?? 0), 0);
25
+ const row = (asset, pin) => _jsx("li", { "data-pinned": pin || undefined, children: _jsx(AssetBalanceRow, { name: asset.name, symbol: asset.symbol, icon: asset.icon, value: assetValue(asset), balance: pin ? undefined : asset.balance ?? null, onSelect: onAssetSelect && (() => onAssetSelect(asset)) }) }, asset.id);
26
+ return _jsxs("section", { ...rest, className: `hig-account-block${className ? ` ${className}` : ''}`, children: [_jsx(ScreenHeader, { title: title ?? messages.account ?? en.account, onBack: onBack, action: headerAction ?? (onShowAddress && _jsx("button", { type: 'button', className: 'hig-swap-back hig-account-address', "aria-label": messages.showAddress ?? en.showAddress, onClick: onShowAddress, children: qrIcon })) }), _jsxs("div", { className: 'hig-account-summary', children: [_jsx("div", { className: 'hig-account-balance', children: _jsx(AnimatedNumberReadout, { value: total, label: messages.accountBalance ?? en.accountBalance, options: usd }) }), onDeposit && _jsx(Button, { onClick: onDeposit, children: depositLabel ?? messages.deposit ?? en.deposit })] }), _jsxs("ul", { className: 'hig-account-assets', children: [row(pinned, true), others.map(asset => row(asset, false))] })] });
27
+ }