@ledgerhq/ledger-wallet-provider 1.0.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 (232) hide show
  1. package/LICENSE +202 -0
  2. package/README.md +320 -0
  3. package/dist/components/atom/balance/ledger-balance.d.ts +8 -0
  4. package/dist/components/atom/balance/ledger-balance.d.ts.map +1 -0
  5. package/dist/components/atom/button/ledger-button.d.ts +44 -0
  6. package/dist/components/atom/button/ledger-button.d.ts.map +1 -0
  7. package/dist/components/atom/chip/ledger-chip.d.ts +32 -0
  8. package/dist/components/atom/chip/ledger-chip.d.ts.map +1 -0
  9. package/dist/components/atom/crypto-icon/ledger-crypto-icon.d.ts +28 -0
  10. package/dist/components/atom/crypto-icon/ledger-crypto-icon.d.ts.map +1 -0
  11. package/dist/components/atom/crypto-icon/map.json.d.ts +242 -0
  12. package/dist/components/atom/floating-button/ledger-floating-button-controller.d.ts +20 -0
  13. package/dist/components/atom/floating-button/ledger-floating-button-controller.d.ts.map +1 -0
  14. package/dist/components/atom/floating-button/ledger-floating-button.d.ts +22 -0
  15. package/dist/components/atom/floating-button/ledger-floating-button.d.ts.map +1 -0
  16. package/dist/components/atom/icon/backIcon.d.ts +3 -0
  17. package/dist/components/atom/icon/backIcon.d.ts.map +1 -0
  18. package/dist/components/atom/icon/bluetoothIcon.d.ts +3 -0
  19. package/dist/components/atom/icon/bluetoothIcon.d.ts.map +1 -0
  20. package/dist/components/atom/icon/cartIcon.d.ts +3 -0
  21. package/dist/components/atom/icon/cartIcon.d.ts.map +1 -0
  22. package/dist/components/atom/icon/checkIcon.d.ts +3 -0
  23. package/dist/components/atom/icon/checkIcon.d.ts.map +1 -0
  24. package/dist/components/atom/icon/chevronDownIcon.d.ts +3 -0
  25. package/dist/components/atom/icon/chevronDownIcon.d.ts.map +1 -0
  26. package/dist/components/atom/icon/chevronRightIcon.d.ts +3 -0
  27. package/dist/components/atom/icon/chevronRightIcon.d.ts.map +1 -0
  28. package/dist/components/atom/icon/clearSigningIcon.d.ts +3 -0
  29. package/dist/components/atom/icon/clearSigningIcon.d.ts.map +1 -0
  30. package/dist/components/atom/icon/closeIcon.d.ts +3 -0
  31. package/dist/components/atom/icon/closeIcon.d.ts.map +1 -0
  32. package/dist/components/atom/icon/desktopIcon.d.ts +3 -0
  33. package/dist/components/atom/icon/desktopIcon.d.ts.map +1 -0
  34. package/dist/components/atom/icon/device-icon/apexp.d.ts +3 -0
  35. package/dist/components/atom/icon/device-icon/apexp.d.ts.map +1 -0
  36. package/dist/components/atom/icon/device-icon/device-icon.d.ts +9 -0
  37. package/dist/components/atom/icon/device-icon/device-icon.d.ts.map +1 -0
  38. package/dist/components/atom/icon/device-icon/flex.d.ts +3 -0
  39. package/dist/components/atom/icon/device-icon/flex.d.ts.map +1 -0
  40. package/dist/components/atom/icon/device-icon/nano.d.ts +3 -0
  41. package/dist/components/atom/icon/device-icon/nano.d.ts.map +1 -0
  42. package/dist/components/atom/icon/device-icon/stax.d.ts +3 -0
  43. package/dist/components/atom/icon/device-icon/stax.d.ts.map +1 -0
  44. package/dist/components/atom/icon/deviceIcon.d.ts +3 -0
  45. package/dist/components/atom/icon/deviceIcon.d.ts.map +1 -0
  46. package/dist/components/atom/icon/directConnectivityIcon.d.ts +3 -0
  47. package/dist/components/atom/icon/directConnectivityIcon.d.ts.map +1 -0
  48. package/dist/components/atom/icon/errorIcon.d.ts +3 -0
  49. package/dist/components/atom/icon/errorIcon.d.ts.map +1 -0
  50. package/dist/components/atom/icon/externalLinkIcon.d.ts +3 -0
  51. package/dist/components/atom/icon/externalLinkIcon.d.ts.map +1 -0
  52. package/dist/components/atom/icon/index.d.ts +20 -0
  53. package/dist/components/atom/icon/index.d.ts.map +1 -0
  54. package/dist/components/atom/icon/ledger-icon.d.ts +20 -0
  55. package/dist/components/atom/icon/ledger-icon.d.ts.map +1 -0
  56. package/dist/components/atom/icon/ledgerLogoIcon.d.ts +3 -0
  57. package/dist/components/atom/icon/ledgerLogoIcon.d.ts.map +1 -0
  58. package/dist/components/atom/icon/mobileIcon.d.ts +3 -0
  59. package/dist/components/atom/icon/mobileIcon.d.ts.map +1 -0
  60. package/dist/components/atom/icon/questionIcon.d.ts +3 -0
  61. package/dist/components/atom/icon/questionIcon.d.ts.map +1 -0
  62. package/dist/components/atom/icon/settingsIcon.d.ts +3 -0
  63. package/dist/components/atom/icon/settingsIcon.d.ts.map +1 -0
  64. package/dist/components/atom/icon/transactionCheckIcon.d.ts +3 -0
  65. package/dist/components/atom/icon/transactionCheckIcon.d.ts.map +1 -0
  66. package/dist/components/atom/icon/usbIcon.d.ts +3 -0
  67. package/dist/components/atom/icon/usbIcon.d.ts.map +1 -0
  68. package/dist/components/atom/lottie/animations/background-flare.d.ts +429 -0
  69. package/dist/components/atom/lottie/animations/background-flare.d.ts.map +1 -0
  70. package/dist/components/atom/lottie/animations/checkmark.d.ts +201 -0
  71. package/dist/components/atom/lottie/animations/checkmark.d.ts.map +1 -0
  72. package/dist/components/atom/lottie/animations/loading-spinner.d.ts +200 -0
  73. package/dist/components/atom/lottie/animations/loading-spinner.d.ts.map +1 -0
  74. package/dist/components/atom/lottie/ledger-lottie.d.ts +871 -0
  75. package/dist/components/atom/lottie/ledger-lottie.d.ts.map +1 -0
  76. package/dist/components/atom/modal/ledger-modal-story-wrapper.d.ts +8 -0
  77. package/dist/components/atom/modal/ledger-modal-story-wrapper.d.ts.map +1 -0
  78. package/dist/components/atom/modal/ledger-modal.d.ts +27 -0
  79. package/dist/components/atom/modal/ledger-modal.d.ts.map +1 -0
  80. package/dist/components/atom/toggle/ledger-toggle.d.ts +24 -0
  81. package/dist/components/atom/toggle/ledger-toggle.d.ts.map +1 -0
  82. package/dist/components/index.d.ts +23 -0
  83. package/dist/components/index.d.ts.map +1 -0
  84. package/dist/components/molecule/account-item/ledger-account-item.d.ts +48 -0
  85. package/dist/components/molecule/account-item/ledger-account-item.d.ts.map +1 -0
  86. package/dist/components/molecule/account-switch/ledger-account-switch.d.ts +26 -0
  87. package/dist/components/molecule/account-switch/ledger-account-switch.d.ts.map +1 -0
  88. package/dist/components/molecule/ad-item/ledger-ad-item.d.ts +13 -0
  89. package/dist/components/molecule/ad-item/ledger-ad-item.d.ts.map +1 -0
  90. package/dist/components/molecule/chain-item/ledger-chain-item.d.ts +33 -0
  91. package/dist/components/molecule/chain-item/ledger-chain-item.d.ts.map +1 -0
  92. package/dist/components/molecule/connection-item/ledger-connection-item.d.ts +34 -0
  93. package/dist/components/molecule/connection-item/ledger-connection-item.d.ts.map +1 -0
  94. package/dist/components/molecule/device-animation/apex/01_APEX_DARK_PIN.json.d.ts +8245 -0
  95. package/dist/components/molecule/device-animation/apex/02_APEX_DARK_CONTINUE_ON_LEDGER.json.d.ts +3927 -0
  96. package/dist/components/molecule/device-animation/device-animation.d.ts +12 -0
  97. package/dist/components/molecule/device-animation/device-animation.d.ts.map +1 -0
  98. package/dist/components/molecule/device-animation/flex/01_EUROPA_DARK_PIN.json.d.ts +9085 -0
  99. package/dist/components/molecule/device-animation/flex/02_EUROPA_DARK_PAIRING.json.d.ts +3641 -0
  100. package/dist/components/molecule/device-animation/flex/03_EUROPA_DARK_PAIRED_SUCCESS.json.d.ts +2327 -0
  101. package/dist/components/molecule/device-animation/flex/04_EUROPA_DARK_CONTINUE_ON_LEDGER.json.d.ts +2197 -0
  102. package/dist/components/molecule/device-animation/flex/05_EUROPA_DARK_SIGN_TRANSACTION.json.d.ts +2166 -0
  103. package/dist/components/molecule/device-animation/flex/06_STAX_DARK_FRONT_VIEW.json.d.ts +1596 -0
  104. package/dist/components/molecule/device-animation/nanosp/01_NANO_S_DARK_PIN.json.d.ts +9738 -0
  105. package/dist/components/molecule/device-animation/nanosp/02_NANO_S_DARK_CONTINUE_ON_YOUR_LEDGER.json.d.ts +4207 -0
  106. package/dist/components/molecule/device-animation/nanox/01_NANO_X_DARK_PIN.json.d.ts +7171 -0
  107. package/dist/components/molecule/device-animation/nanox/02_NANO_X_DARK_PAIRING.json.d.ts +4618 -0
  108. package/dist/components/molecule/device-animation/nanox/03_NANO_X_DARK_CONTINUE_ON_YOUR_LEDGER.json.d.ts +2551 -0
  109. package/dist/components/molecule/device-animation/stax/01_STAX_DARK_PIN.json.d.ts +6187 -0
  110. package/dist/components/molecule/device-animation/stax/02_STAX_DARK_PAIRING.json.d.ts +2952 -0
  111. package/dist/components/molecule/device-animation/stax/03_STAX_DARK_PAIRED_SUCCESS.json.d.ts +1322 -0
  112. package/dist/components/molecule/device-animation/stax/04_STAX_DARK_CONTINUE_ON_LEDGER.json.d.ts +1184 -0
  113. package/dist/components/molecule/device-animation/stax/05_STAX_DARK_SIGN_TRANSACTION.json.d.ts +1161 -0
  114. package/dist/components/molecule/device-animation/stax/06_STAX_DARK_FRONT_VIEW.json.d.ts +1274 -0
  115. package/dist/components/molecule/device-item/ledger-device-item.d.ts +48 -0
  116. package/dist/components/molecule/device-item/ledger-device-item.d.ts.map +1 -0
  117. package/dist/components/molecule/info-state/flex-device-icon.d.ts +3 -0
  118. package/dist/components/molecule/info-state/flex-device-icon.d.ts.map +1 -0
  119. package/dist/components/molecule/info-state/ledger-info-state.d.ts +21 -0
  120. package/dist/components/molecule/info-state/ledger-info-state.d.ts.map +1 -0
  121. package/dist/components/molecule/info-state/nanox-device-icon.d.ts +3 -0
  122. package/dist/components/molecule/info-state/nanox-device-icon.d.ts.map +1 -0
  123. package/dist/components/molecule/info-state/stax-device-icon.d.ts +3 -0
  124. package/dist/components/molecule/info-state/stax-device-icon.d.ts.map +1 -0
  125. package/dist/components/molecule/platform-item/ledger-platform-item.d.ts +24 -0
  126. package/dist/components/molecule/platform-item/ledger-platform-item.d.ts.map +1 -0
  127. package/dist/components/molecule/toolbar/ledger-toolbar.d.ts +38 -0
  128. package/dist/components/molecule/toolbar/ledger-toolbar.d.ts.map +1 -0
  129. package/dist/components/organism/status/ledger-status.d.ts +37 -0
  130. package/dist/components/organism/status/ledger-status.d.ts.map +1 -0
  131. package/dist/context/core-context.d.ts +13 -0
  132. package/dist/context/core-context.d.ts.map +1 -0
  133. package/dist/context/language-context.d.ts +273 -0
  134. package/dist/context/language-context.d.ts.map +1 -0
  135. package/dist/domain/account-tokens/account-token-controller.d.ts +17 -0
  136. package/dist/domain/account-tokens/account-token-controller.d.ts.map +1 -0
  137. package/dist/domain/account-tokens/account-tokens.d.ts +32 -0
  138. package/dist/domain/account-tokens/account-tokens.d.ts.map +1 -0
  139. package/dist/domain/device-connection-status/device-connection-status-controller.d.ts +14 -0
  140. package/dist/domain/device-connection-status/device-connection-status-controller.d.ts.map +1 -0
  141. package/dist/domain/device-connection-status/device-connection-status.d.ts +24 -0
  142. package/dist/domain/device-connection-status/device-connection-status.d.ts.map +1 -0
  143. package/dist/domain/device-switch/device-switch-controller.d.ts +26 -0
  144. package/dist/domain/device-switch/device-switch-controller.d.ts.map +1 -0
  145. package/dist/domain/device-switch/device-switch.d.ts +30 -0
  146. package/dist/domain/device-switch/device-switch.d.ts.map +1 -0
  147. package/dist/domain/home/ledger-home-controller.d.ts +21 -0
  148. package/dist/domain/home/ledger-home-controller.d.ts.map +1 -0
  149. package/dist/domain/home/ledger-home.d.ts +28 -0
  150. package/dist/domain/home/ledger-home.d.ts.map +1 -0
  151. package/dist/domain/home-flow/home-flow-controller.d.ts +20 -0
  152. package/dist/domain/home-flow/home-flow-controller.d.ts.map +1 -0
  153. package/dist/domain/home-flow/home-flow.d.ts +21 -0
  154. package/dist/domain/home-flow/home-flow.d.ts.map +1 -0
  155. package/dist/domain/onboarding/consent-prompt/consent-analytics-screen.d.ts +20 -0
  156. package/dist/domain/onboarding/consent-prompt/consent-analytics-screen.d.ts.map +1 -0
  157. package/dist/domain/onboarding/ledger-sync/ledger-sync-controller.d.ts +38 -0
  158. package/dist/domain/onboarding/ledger-sync/ledger-sync-controller.d.ts.map +1 -0
  159. package/dist/domain/onboarding/ledger-sync/ledger-sync.d.ts +29 -0
  160. package/dist/domain/onboarding/ledger-sync/ledger-sync.d.ts.map +1 -0
  161. package/dist/domain/onboarding/onboarding-flow/onboarding-flow-controller.d.ts +16 -0
  162. package/dist/domain/onboarding/onboarding-flow/onboarding-flow-controller.d.ts.map +1 -0
  163. package/dist/domain/onboarding/onboarding-flow/onboarding-flow.d.ts +21 -0
  164. package/dist/domain/onboarding/onboarding-flow/onboarding-flow.d.ts.map +1 -0
  165. package/dist/domain/onboarding/retrieving-accounts/retrieving-accounts-controller.d.ts +29 -0
  166. package/dist/domain/onboarding/retrieving-accounts/retrieving-accounts-controller.d.ts.map +1 -0
  167. package/dist/domain/onboarding/retrieving-accounts/retrieving-accounts.d.ts +24 -0
  168. package/dist/domain/onboarding/retrieving-accounts/retrieving-accounts.d.ts.map +1 -0
  169. package/dist/domain/onboarding/select-account/select-account-controller.d.ts +19 -0
  170. package/dist/domain/onboarding/select-account/select-account-controller.d.ts.map +1 -0
  171. package/dist/domain/onboarding/select-account/select-account.d.ts +30 -0
  172. package/dist/domain/onboarding/select-account/select-account.d.ts.map +1 -0
  173. package/dist/domain/onboarding/select-device/select-device-controller.d.ts +30 -0
  174. package/dist/domain/onboarding/select-device/select-device-controller.d.ts.map +1 -0
  175. package/dist/domain/onboarding/select-device/select-device.d.ts +23 -0
  176. package/dist/domain/onboarding/select-device/select-device.d.ts.map +1 -0
  177. package/dist/domain/onboarding/turn-on-sync/turn-on-sync-controller.d.ts +14 -0
  178. package/dist/domain/onboarding/turn-on-sync/turn-on-sync-controller.d.ts.map +1 -0
  179. package/dist/domain/onboarding/turn-on-sync/turn-on-sync.d.ts +24 -0
  180. package/dist/domain/onboarding/turn-on-sync/turn-on-sync.d.ts.map +1 -0
  181. package/dist/domain/onboarding/turn-on-sync-desktop/turn-on-sync-desktop-controller.d.ts +13 -0
  182. package/dist/domain/onboarding/turn-on-sync-desktop/turn-on-sync-desktop-controller.d.ts.map +1 -0
  183. package/dist/domain/onboarding/turn-on-sync-desktop/turn-on-sync-desktop.d.ts +23 -0
  184. package/dist/domain/onboarding/turn-on-sync-desktop/turn-on-sync-desktop.d.ts.map +1 -0
  185. package/dist/domain/onboarding/turn-on-sync-mobile/turn-on-sync-mobile-controller.d.ts +12 -0
  186. package/dist/domain/onboarding/turn-on-sync-mobile/turn-on-sync-mobile-controller.d.ts.map +1 -0
  187. package/dist/domain/onboarding/turn-on-sync-mobile/turn-on-sync-mobile.d.ts +22 -0
  188. package/dist/domain/onboarding/turn-on-sync-mobile/turn-on-sync-mobile.d.ts.map +1 -0
  189. package/dist/domain/onboarding/welcome/welcome-screen.d.ts +26 -0
  190. package/dist/domain/onboarding/welcome/welcome-screen.d.ts.map +1 -0
  191. package/dist/domain/settings/settings-screen.d.ts +21 -0
  192. package/dist/domain/settings/settings-screen.d.ts.map +1 -0
  193. package/dist/domain/sign-transaction/sign-transaction-controller.d.ts +50 -0
  194. package/dist/domain/sign-transaction/sign-transaction-controller.d.ts.map +1 -0
  195. package/dist/domain/sign-transaction/sign-transaction.d.ts +38 -0
  196. package/dist/domain/sign-transaction/sign-transaction.d.ts.map +1 -0
  197. package/dist/domain/signing-flow/signing-flow-controller.d.ts +16 -0
  198. package/dist/domain/signing-flow/signing-flow-controller.d.ts.map +1 -0
  199. package/dist/domain/signing-flow/signing-flow.d.ts +21 -0
  200. package/dist/domain/signing-flow/signing-flow.d.ts.map +1 -0
  201. package/dist/i18n/en.json.d.ts +254 -0
  202. package/dist/index.d.ts +12 -0
  203. package/dist/index.d.ts.map +1 -0
  204. package/dist/index.js +63326 -0
  205. package/dist/ledger-button-app-controller.d.ts +12 -0
  206. package/dist/ledger-button-app-controller.d.ts.map +1 -0
  207. package/dist/ledger-button-app.d.ts +50 -0
  208. package/dist/ledger-button-app.d.ts.map +1 -0
  209. package/dist/ledger-button-playground.d.ts +16 -0
  210. package/dist/ledger-button-playground.d.ts.map +1 -0
  211. package/dist/shared/navigation.d.ts +20 -0
  212. package/dist/shared/navigation.d.ts.map +1 -0
  213. package/dist/shared/root-navigation-controller.d.ts +29 -0
  214. package/dist/shared/root-navigation-controller.d.ts.map +1 -0
  215. package/dist/shared/root-navigation.d.ts +38 -0
  216. package/dist/shared/root-navigation.d.ts.map +1 -0
  217. package/dist/shared/routes.d.ts +182 -0
  218. package/dist/shared/routes.d.ts.map +1 -0
  219. package/dist/styles.css +3202 -0
  220. package/dist/tailwind-element.d.ts +5 -0
  221. package/dist/tailwind-element.d.ts.map +1 -0
  222. package/dist/utils/scope-css.d.ts +6 -0
  223. package/dist/utils/scope-css.d.ts.map +1 -0
  224. package/dist/utils/setup-floating-button.d.ts +8 -0
  225. package/dist/utils/setup-floating-button.d.ts.map +1 -0
  226. package/dist/web3-provider/LedgerEIP1193Provider.d.ts +64 -0
  227. package/dist/web3-provider/LedgerEIP1193Provider.d.ts.map +1 -0
  228. package/dist/web3-provider/supportedChains.d.ts +15 -0
  229. package/dist/web3-provider/supportedChains.d.ts.map +1 -0
  230. package/dist/web3-provider/supportedRpcMethods.d.ts +17 -0
  231. package/dist/web3-provider/supportedRpcMethods.d.ts.map +1 -0
  232. package/package.json +41 -0
package/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright 2024-present Ledger
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
package/README.md ADDED
@@ -0,0 +1,320 @@
1
+ # @ledgerhq/ledger-wallet-provider
2
+
3
+ A comprehensive Web Components-based library that provides a complete Ledger hardware wallet integration solution for web applications. Built with Lit and designed to work with any frontend framework.
4
+
5
+ ## Features
6
+
7
+ - **EIP-1193 Provider**: Complete Ethereum Provider implementation with full JSON-RPC support
8
+ - **EIP-6963 Support**: Multi-wallet discovery and selection
9
+ - **Framework Agnostic**: Works with any frontend framework (React, Vue, Angular, Svelte, etc.)
10
+ - **Hardware Wallet Integration**: Direct connection to Ledger devices via USB and Bluetooth
11
+ - **Modern UI**: Pre-built components with Tailwind CSS styling and dark mode support
12
+ - **Transaction Signing**: Support for Ethereum transactions, typed data, and personal messages
13
+ - **Account Management**: Multi-account support and switching
14
+ - **Ledger Sync Integration**: Seamless integration with Ledger's cloud services
15
+ - **Device Management**: Support for multiple device types and connection methods
16
+
17
+ ## Installation
18
+
19
+ ```bash
20
+ npm install @ledgerhq/ledger-wallet-provider
21
+ ```
22
+
23
+ ## Quick Start
24
+
25
+ ### Basic Setup
26
+
27
+ ```javascript
28
+ import { initializeLedgerProvider } from '@ledgerhq/ledger-wallet-provider';
29
+ import '@ledgerhq/ledger-wallet-provider/styles.css';
30
+
31
+ // Initialize the Ledger provider
32
+ const cleanup = initializeLedgerProvider({
33
+ devConfig: {
34
+ stub: {
35
+ base: false, // Enable base stub mode for development
36
+ account: false, // Enable account stubbing
37
+ device: false, // Enable device stubbing
38
+ web3Provider: false, // Enable Web3 provider stubbing
39
+ dAppConfig: false, // Enable dApp config stubbing
40
+ },
41
+ },
42
+ target: document.body, // Optional: specify where to mount the UI
43
+ dAppIdentifier: 'my-dapp', // Your dApp identifier
44
+ apiKey: 'your-api-key', // Your Ledger API key
45
+ loggerLevel: 'info', // Log level: 'debug', 'info', 'warn', 'error'
46
+ dmkConfig: undefined, // Device Management Kit configuration (optional)
47
+ });
48
+
49
+ // Request provider discovery
50
+ window.dispatchEvent(new Event('eip6963:requestProvider'));
51
+ ```
52
+
53
+ ### React Integration
54
+
55
+ ```tsx
56
+ import { useEffect, useState, useCallback } from 'react';
57
+ import type { EIP6963ProviderDetail } from '@ledgerhq/ledger-wallet-provider';
58
+
59
+ function useProviders() {
60
+ const [providers, setProviders] = useState<EIP6963ProviderDetail[]>([]);
61
+ const [selectedProvider, setSelectedProvider] = useState<EIP6963ProviderDetail | null>(null);
62
+
63
+ const handleAnnounceProvider = useCallback((e: CustomEvent<EIP6963ProviderDetail>) => {
64
+ setProviders(prev => {
65
+ const found = prev.find(p => p.info.uuid === e.detail.info.uuid);
66
+ if (found) return prev;
67
+ return [...prev, e.detail];
68
+ });
69
+ }, []);
70
+
71
+ useEffect(() => {
72
+ // Dynamic import is required because the library uses browser APIs
73
+ // and won't work with Server-Side Rendering (SSR)
74
+ const initializeProvider = async () => {
75
+ const { initializeLedgerProvider } = await import('@ledgerhq/ledger-wallet-provider');
76
+
77
+ const cleanup = initializeLedgerProvider({
78
+ devConfig: {
79
+ stub: {
80
+ base: false, // Set to true for development
81
+ account: false, // Enable account stubbing
82
+ device: false, // Enable device stubbing
83
+ web3Provider: false, // Enable Web3 provider stubbing
84
+ dAppConfig: false, // Enable dApp config stubbing
85
+ },
86
+ },
87
+ dAppIdentifier: 'my-dapp',
88
+ apiKey: 'your-api-key',
89
+ loggerLevel: 'info', // Log level configuration
90
+ dmkConfig: undefined, // Device Management Kit config (optional)
91
+ });
92
+
93
+ window.addEventListener('eip6963:announceProvider', handleAnnounceProvider);
94
+
95
+ return cleanup;
96
+ };
97
+
98
+ let cleanup: (() => void) | undefined;
99
+
100
+ initializeProvider().then(cleanupFn => {
101
+ cleanup = cleanupFn;
102
+ });
103
+
104
+ return () => {
105
+ cleanup?.();
106
+ window.removeEventListener('eip6963:announceProvider', handleAnnounceProvider);
107
+ };
108
+ }, [handleAnnounceProvider]);
109
+
110
+ return { providers, selectedProvider, setSelectedProvider };
111
+ }
112
+
113
+ function App() {
114
+ const { providers, selectedProvider, setSelectedProvider } = useProviders();
115
+ const [account, setAccount] = useState<string | null>(null);
116
+
117
+ const connectWallet = async () => {
118
+ if (!selectedProvider) return;
119
+
120
+ try {
121
+ const accounts = await selectedProvider.provider.request({
122
+ method: 'eth_requestAccounts',
123
+ params: []
124
+ });
125
+ setAccount(accounts[0]);
126
+ } catch (error) {
127
+ console.error('Failed to connect:', error);
128
+ }
129
+ };
130
+
131
+ const signTransaction = async (transaction: any) => {
132
+ if (!selectedProvider) return;
133
+
134
+ try {
135
+ const result = await selectedProvider.provider.request({
136
+ method: 'eth_signTransaction',
137
+ params: [transaction]
138
+ });
139
+ return result;
140
+ } catch (error) {
141
+ console.error('Failed to sign transaction:', error);
142
+ }
143
+ };
144
+
145
+ return (
146
+ <div>
147
+ {providers.map(provider => (
148
+ <button
149
+ key={provider.info.uuid}
150
+ onClick={() => setSelectedProvider(provider)}
151
+ >
152
+ Connect {provider.info.name}
153
+ </button>
154
+ ))}
155
+
156
+ {selectedProvider && (
157
+ <button onClick={connectWallet}>
158
+ Request Accounts
159
+ </button>
160
+ )}
161
+
162
+ {account && <p>Connected: {account}</p>}
163
+ </div>
164
+ );
165
+ }
166
+ ```
167
+
168
+ ## API Reference
169
+
170
+ ### `initializeLedgerProvider(options)`
171
+
172
+ Initializes the Ledger Wallet Provider and injects the UI components into the DOM.
173
+
174
+ #### Parameters
175
+
176
+ ```typescript
177
+ {
178
+ devConfig?: {
179
+ stub?: {
180
+ base?: boolean; // Enable base stub mode for development (default: false)
181
+ account?: boolean; // Enable account stubbing (default: false)
182
+ device?: boolean; // Enable device stubbing (default: false)
183
+ web3Provider?: boolean; // Enable Web3 provider stubbing (default: false)
184
+ dAppConfig?: boolean; // Enable dApp config stubbing (default: false)
185
+ };
186
+ };
187
+ target?: HTMLElement; // Target element to mount UI (default: document.body)
188
+ dAppIdentifier?: string; // Your dApp identifier
189
+ apiKey?: string; // Your Ledger API key
190
+ loggerLevel?: string; // Log level: 'debug', 'info', 'warn', 'error' (default: 'info')
191
+ dmkConfig?: any; // Device Management Kit configuration (optional)
192
+ }
193
+ ```
194
+
195
+ #### Returns
196
+
197
+ A cleanup function to remove the provider and UI components.
198
+
199
+ ### `LedgerEIP1193Provider`
200
+
201
+ The main provider class that implements the EIP-1193 standard.
202
+
203
+ #### Methods
204
+
205
+ - `request({ method, params })` - Make JSON-RPC requests
206
+ - `on(event, listener)` - Listen to provider events
207
+ - `removeListener(event, listener)` - Remove event listeners
208
+ - `isConnected()` - Check connection status
209
+ - `disconnect()` - Disconnect from the provider
210
+
211
+ #### Supported Methods
212
+
213
+ - `eth_requestAccounts` - Request user accounts
214
+ - `eth_accounts` - Get current accounts
215
+ - `eth_chainId` - Get current chain ID
216
+ - `eth_sendTransaction` - Send and sign transactions
217
+ - `eth_signTransaction` - Sign transactions
218
+ - `eth_signRawTransaction` - Sign raw transactions
219
+ - `eth_sign` - Sign messages
220
+ - `personal_sign` - Sign personal messages
221
+ - `eth_sendRawTransaction` - Send raw transactions
222
+ - `eth_signTypedData` - Sign typed data (EIP-712)
223
+ - `eth_signTypedData_v4` - Sign typed data v4 (EIP-712)
224
+ - `eth_getBalance` - Get account balance (delegated to core)
225
+
226
+ #### Events
227
+
228
+ - `accountsChanged` - Fired when accounts change
229
+ - `chainChanged` - Fired when chain changes
230
+ - `connect` - Fired when provider connects
231
+ - `disconnect` - Fired when provider disconnects
232
+
233
+ ## Server-Side Rendering (SSR) Compatibility
234
+
235
+ The library uses browser-specific APIs and requires dynamic imports in SSR environments:
236
+
237
+ ```javascript
238
+ // ❌ Don't do this in SSR environments
239
+ import { initializeLedgerProvider } from '@ledgerhq/ledger-wallet-provider';
240
+
241
+ // ✅ Use dynamic imports instead
242
+ useEffect(() => {
243
+ const initializeProvider = async () => {
244
+ const { initializeLedgerProvider } = await import('@ledgerhq/ledger-wallet-provider');
245
+ return initializeLedgerProvider({ /* options */ });
246
+ };
247
+
248
+ initializeProvider();
249
+ }, []);
250
+ ```
251
+
252
+ **Why dynamic imports are necessary:**
253
+ - The library uses Web APIs (`window`, `document`, `CustomEvent`) that don't exist in Node.js
254
+ - Direct imports will cause build errors in SSR frameworks (Next.js, Nuxt, SvelteKit, etc.)
255
+ - Dynamic imports ensure the code only runs in the browser environment
256
+
257
+ ## Styling
258
+
259
+ Import the CSS file to get the default styling:
260
+
261
+ ```javascript
262
+ import '@ledgerhq/ledger-wallet-provider/styles.css';
263
+ ```
264
+
265
+ ## Development Mode
266
+
267
+ For development and testing, you can enable stub mode:
268
+
269
+ ```javascript
270
+ const cleanup = initializeLedgerProvider({
271
+ devConfig: {
272
+ stub: {
273
+ base: true, // Enable base stub mode
274
+ account: true, // Mock account operations
275
+ device: true, // Mock device interactions
276
+ web3Provider: true, // Mock Web3 provider responses
277
+ dAppConfig: true, // Mock dApp configuration
278
+ },
279
+ },
280
+ dAppIdentifier: 'my-dapp',
281
+ apiKey: 'your-api-key',
282
+ });
283
+ ```
284
+
285
+ ## Requirements
286
+
287
+ - ES2020+ support
288
+ - Modern bundler (Vite, Webpack 5+, etc.)
289
+ - Browser environment (no Node.js server-side execution)
290
+ - Web HID API support (for USB connections)
291
+ - Web Bluetooth API support (for Bluetooth connections)
292
+ - **Note**: Mobile browsers are not supported due to Web HID/BLE API not being implemented
293
+
294
+ ## Browser Support
295
+
296
+ - **Desktop**: Chrome 89+, Firefox 89+, Safari 14.1+, Edge 89+
297
+ - **Mobile**: Not supported (Web HID/BLE APIs not available)
298
+ - **Web Extensions**: Supported in manifest v3 extensions
299
+
300
+ ## Building
301
+
302
+ Run `nx build ledger-wallet-provider` to build the library.
303
+
304
+ ## Testing
305
+
306
+ Run `nx test ledger-wallet-provider` to execute the unit tests via [Vitest](https://vitest.dev/).
307
+
308
+ ## Storybook
309
+
310
+ Run `nx storybook ledger-wallet-provider` to start the Storybook development server for component development and testing.
311
+
312
+ ## Version
313
+
314
+ Current version: **1.0.0-rc.5**
315
+
316
+ This is a release candidate version. The API is stable but may have minor changes before the final 1.0.0 release.
317
+
318
+ ## License
319
+
320
+ This project is licensed under the MIT License.
@@ -0,0 +1,8 @@
1
+ import { LitElement } from 'lit';
2
+ export declare class LedgerBalance extends LitElement {
3
+ label: string;
4
+ balance: number;
5
+ ticker: string;
6
+ render(): import('lit').TemplateResult<1>;
7
+ }
8
+ //# sourceMappingURL=ledger-balance.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ledger-balance.d.ts","sourceRoot":"","sources":["../../../../src/components/atom/balance/ledger-balance.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,UAAU,EAAE,MAAM,KAAK,CAAC;AAKvC,qBAEa,aAAc,SAAQ,UAAU;IAE3C,KAAK,SAAa;IAGlB,OAAO,SAAK;IAGZ,MAAM,SAAM;IAEH,MAAM;CAYhB"}
@@ -0,0 +1,44 @@
1
+ import { LitElement } from 'lit';
2
+ import { LedgerIconAttributes } from '../icon/ledger-icon.js';
3
+ export type ButtonVariant = "primary" | "secondary" | "accent" | "noBackground";
4
+ export type ButtonSize = "small" | "medium" | "large" | "xs" | "full";
5
+ export type IconPosition = "left" | "right";
6
+ export interface LedgerButtonAttributes {
7
+ label?: string;
8
+ variant?: ButtonVariant;
9
+ size?: ButtonSize;
10
+ disabled?: boolean;
11
+ icon?: boolean;
12
+ iconPosition?: IconPosition;
13
+ type?: "button" | "submit" | "reset";
14
+ }
15
+ export declare class LedgerButton extends LitElement {
16
+ label: string;
17
+ variant: ButtonVariant;
18
+ size: ButtonSize;
19
+ disabled: boolean;
20
+ icon: boolean;
21
+ iconType?: LedgerIconAttributes["type"];
22
+ iconPosition: IconPosition;
23
+ type: "button" | "submit" | "reset";
24
+ private get buttonClasses();
25
+ private renderIcon;
26
+ private renderLabel;
27
+ render(): import('lit').TemplateResult<1>;
28
+ private handleClick;
29
+ }
30
+ declare global {
31
+ interface HTMLElementTagNameMap {
32
+ "ledger-button": LedgerButton;
33
+ }
34
+ interface WindowEventMap {
35
+ "ledger-button-click": CustomEvent<{
36
+ timestamp: number;
37
+ variant: ButtonVariant;
38
+ size: ButtonSize;
39
+ label: string;
40
+ }>;
41
+ }
42
+ }
43
+ export default LedgerButton;
44
+ //# sourceMappingURL=ledger-button.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ledger-button.d.ts","sourceRoot":"","sources":["../../../../src/components/atom/button/ledger-button.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,CAAC;AAG7B,OAAO,EAAa,UAAU,EAAW,MAAM,KAAK,CAAC;AAKrD,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAE9D,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,WAAW,GAAG,QAAQ,GAAG,cAAc,CAAC;AAChF,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,GAAG,IAAI,GAAG,MAAM,CAAC;AACtE,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,OAAO,CAAC;AAE5C,MAAM,WAAW,sBAAsB;IACrC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,aAAa,CAAC;IACxB,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAC;CACtC;AAwDD,qBAEa,YAAa,SAAQ,UAAU;IAE1C,KAAK,SAAM;IAGX,OAAO,EAAE,aAAa,CAAa;IAGnC,IAAI,EAAE,UAAU,CAAY;IAG5B,QAAQ,UAAS;IAGjB,IAAI,UAAS;IAGb,QAAQ,CAAC,EAAE,oBAAoB,CAAC,MAAM,CAAC,CAAC;IAGxC,YAAY,EAAE,YAAY,CAAU;IAGpC,IAAI,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAY;IAE/C,OAAO,KAAK,aAAa,GAIxB;IAED,OAAO,CAAC,UAAU;IAmBlB,OAAO,CAAC,WAAW;IAQV,MAAM;IAoBf,OAAO,CAAC,WAAW;CAqBpB;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,eAAe,EAAE,YAAY,CAAC;KAC/B;IAED,UAAU,cAAc;QACtB,qBAAqB,EAAE,WAAW,CAAC;YACjC,SAAS,EAAE,MAAM,CAAC;YAClB,OAAO,EAAE,aAAa,CAAC;YACvB,IAAI,EAAE,UAAU,CAAC;YACjB,KAAK,EAAE,MAAM,CAAC;SACf,CAAC,CAAC;KACJ;CACF;AAED,eAAe,YAAY,CAAC"}
@@ -0,0 +1,32 @@
1
+ import { LitElement } from 'lit';
2
+ import { DeviceModelId } from '../icon/device-icon/device-icon';
3
+ export interface LedgerChipAttributes {
4
+ label?: string;
5
+ icon?: "device";
6
+ }
7
+ export declare class LedgerChip extends LitElement {
8
+ label: string;
9
+ deviceModelId: DeviceModelId;
10
+ private get chipContainerClasses();
11
+ private get chipLabelClasses();
12
+ private get chipChevronClasses();
13
+ private renderIcon;
14
+ private renderChevron;
15
+ render(): import('lit').TemplateResult<1>;
16
+ private handleClick;
17
+ private handleKeydown;
18
+ }
19
+ declare global {
20
+ interface HTMLElementTagNameMap {
21
+ "ledger-chip": LedgerChip;
22
+ }
23
+ interface WindowEventMap {
24
+ "ledger-chip-click": CustomEvent<{
25
+ timestamp: number;
26
+ label: string;
27
+ deviceModelId: DeviceModelId;
28
+ }>;
29
+ }
30
+ }
31
+ export default LedgerChip;
32
+ //# sourceMappingURL=ledger-chip.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ledger-chip.d.ts","sourceRoot":"","sources":["../../../../src/components/atom/chip/ledger-chip.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,CAAC;AAC7B,OAAO,iCAAiC,CAAC;AAGzC,OAAO,EAAQ,UAAU,EAAE,MAAM,KAAK,CAAC;AAKvC,OAAO,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AAEhE,MAAM,WAAW,oBAAoB;IACnC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,QAAQ,CAAC;CACjB;AAWD,qBAEa,UAAW,SAAQ,UAAU;IAExC,KAAK,SAAM;IAGX,aAAa,EAAE,aAAa,CAAU;IAEtC,OAAO,KAAK,oBAAoB,GAI/B;IAED,OAAO,KAAK,gBAAgB,GAI3B;IAED,OAAO,KAAK,kBAAkB,GAI7B;IAED,OAAO,CAAC,UAAU;IAIlB,OAAO,CAAC,aAAa;IAQZ,MAAM;IAef,OAAO,CAAC,WAAW;IAcnB,OAAO,CAAC,aAAa;CAMtB;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,aAAa,EAAE,UAAU,CAAC;KAC3B;IAED,UAAU,cAAc;QACtB,mBAAmB,EAAE,WAAW,CAAC;YAC/B,SAAS,EAAE,MAAM,CAAC;YAClB,KAAK,EAAE,MAAM,CAAC;YACd,aAAa,EAAE,aAAa,CAAC;SAC9B,CAAC,CAAC;KACJ;CACF;AAED,eAAe,UAAU,CAAC"}
@@ -0,0 +1,28 @@
1
+ import { LitElement } from 'lit';
2
+ export type CryptoIconSize = "small" | "medium" | "large";
3
+ export type CryptoIconVariant = "rounded" | "square";
4
+ export interface LedgerCryptoIconAttributes {
5
+ ledgerId: string;
6
+ ticker: string;
7
+ size?: CryptoIconSize;
8
+ variant?: CryptoIconVariant;
9
+ }
10
+ export declare class LedgerCryptoIcon extends LitElement {
11
+ ledgerId: string;
12
+ ticker: string;
13
+ alt: string;
14
+ size: CryptoIconSize;
15
+ variant: CryptoIconVariant;
16
+ private get iconClasses();
17
+ private getCryptoIconUrl;
18
+ private renderFallback;
19
+ private renderCryptoIcon;
20
+ render(): import('lit').TemplateResult<1>;
21
+ }
22
+ declare global {
23
+ interface HTMLElementTagNameMap {
24
+ "ledger-crypto-icon": LedgerCryptoIcon;
25
+ }
26
+ }
27
+ export default LedgerCryptoIcon;
28
+ //# sourceMappingURL=ledger-crypto-icon.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ledger-crypto-icon.d.ts","sourceRoot":"","sources":["../../../../src/components/atom/crypto-icon/ledger-crypto-icon.ts"],"names":[],"mappings":"AACA,OAAO,EAAQ,UAAU,EAAE,MAAM,KAAK,CAAC;AAMvC,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC;AAC1D,MAAM,MAAM,iBAAiB,GAAG,SAAS,GAAG,QAAQ,CAAC;AAErD,MAAM,WAAW,0BAA0B;IACzC,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,OAAO,CAAC,EAAE,iBAAiB,CAAC;CAC7B;AA4CD,qBAEa,gBAAiB,SAAQ,UAAU;IAE9C,QAAQ,SAAM;IAGd,MAAM,SAAM;IAGZ,GAAG,SAAM;IAGT,IAAI,EAAE,cAAc,CAAW;IAG/B,OAAO,EAAE,iBAAiB,CAAa;IAEvC,OAAO,KAAK,WAAW,GAEtB;IAED,OAAO,CAAC,gBAAgB;IAWxB,OAAO,CAAC,cAAc;IAMtB,OAAO,CAAC,gBAAgB;IAYf,MAAM;CAchB;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,oBAAoB,EAAE,gBAAgB,CAAC;KACxC;CACF;AAED,eAAe,gBAAgB,CAAC"}