@jaw.id/ui 0.0.2 → 0.0.4

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 (67) hide show
  1. package/README.md +18 -28
  2. package/cjs-error.cjs +3 -0
  3. package/dist/{ccip-CQ-gVxMf.js → ccip-yRQNp5zr.js} +1 -1
  4. package/dist/{index-Dy2WdHwt.js → index-BcDVfcdq.js} +20996 -20525
  5. package/dist/index.js +1 -1
  6. package/package.json +9 -2
  7. package/.babelrc +0 -12
  8. package/CHANGELOG.md +0 -9
  9. package/components.json +0 -22
  10. package/postcss.config.cjs +0 -6
  11. package/src/components/ConnectDialog/index.tsx +0 -270
  12. package/src/components/ConnectDialog/types.ts +0 -34
  13. package/src/components/DefaultDialog/index.tsx +0 -99
  14. package/src/components/Eip712Dialog/index.tsx +0 -525
  15. package/src/components/Eip712Dialog/types.ts +0 -27
  16. package/src/components/FeeTokenSelector/index.tsx +0 -308
  17. package/src/components/OnboardingDialog/index.tsx +0 -317
  18. package/src/components/OnboardingDialog/types.ts +0 -43
  19. package/src/components/OrSeparator/index.tsx +0 -13
  20. package/src/components/PermissionDialog/index.tsx +0 -598
  21. package/src/components/PermissionDialog/types.ts +0 -77
  22. package/src/components/SignatureDialog/index.tsx +0 -180
  23. package/src/components/SignatureDialog/types.ts +0 -27
  24. package/src/components/SiweDialog/index.tsx +0 -231
  25. package/src/components/SiweDialog/types.ts +0 -34
  26. package/src/components/TransactionDialog/DecodedCalldata.tsx +0 -79
  27. package/src/components/TransactionDialog/index.tsx +0 -663
  28. package/src/components/TransactionDialog/types.ts +0 -54
  29. package/src/components/ui/accordion.tsx +0 -66
  30. package/src/components/ui/avatar.tsx +0 -53
  31. package/src/components/ui/button.tsx +0 -59
  32. package/src/components/ui/card.tsx +0 -92
  33. package/src/components/ui/checkbox.tsx +0 -32
  34. package/src/components/ui/dialog.tsx +0 -183
  35. package/src/components/ui/dropdown-menu.tsx +0 -258
  36. package/src/components/ui/form.tsx +0 -167
  37. package/src/components/ui/input.tsx +0 -60
  38. package/src/components/ui/label.tsx +0 -24
  39. package/src/components/ui/popover.tsx +0 -48
  40. package/src/components/ui/scroll-area.tsx +0 -58
  41. package/src/components/ui/select.tsx +0 -160
  42. package/src/components/ui/separator.tsx +0 -28
  43. package/src/components/ui/sheet.tsx +0 -169
  44. package/src/components/ui/spinner.tsx +0 -18
  45. package/src/components/ui/tabs.tsx +0 -69
  46. package/src/components/ui/tooltip.tsx +0 -61
  47. package/src/hooks/index.ts +0 -5
  48. package/src/hooks/useChainIconURI.tsx +0 -117
  49. package/src/hooks/useDecodedCalldata.ts +0 -128
  50. package/src/hooks/useFeeTokenPrice.tsx +0 -36
  51. package/src/hooks/useGasEstimation.ts +0 -474
  52. package/src/hooks/useIsMobile.ts +0 -36
  53. package/src/icons/index.tsx +0 -114
  54. package/src/index.ts +0 -19
  55. package/src/lib/utils.ts +0 -6
  56. package/src/react/ReactUIHandler.tsx +0 -3004
  57. package/src/react/index.ts +0 -2
  58. package/src/styles.css +0 -210
  59. package/src/utils/formatAddress.ts +0 -24
  60. package/src/utils/index.ts +0 -4
  61. package/src/utils/justaNameInstance.ts +0 -25
  62. package/src/utils/tokenBalance.ts +0 -41
  63. package/src/utils/tokenPrice.ts +0 -58
  64. package/tailwind.config.js +0 -130
  65. package/tsconfig.json +0 -19
  66. package/tsconfig.lib.json +0 -43
  67. package/vite.config.ts +0 -45
package/README.md CHANGED
@@ -1,54 +1,44 @@
1
1
  # @jaw.id/ui
2
2
 
3
- React UI components for JAW (JustaName Account Wallet) - pre-built dialogs for wallet interactions.
3
+ Pre-built React dialogs for [JAW.id](https://jaw.id) wallet interactions: onboarding, transaction signing, permissions, and more.
4
+
5
+ ## Documentation
6
+
7
+ For documentation and guides, visit [docs.jaw.id](https://docs.jaw.id).
4
8
 
5
9
  ## Installation
6
10
 
7
11
  ```bash
8
12
  npm install @jaw.id/ui
9
- ```
10
-
11
- Import styles in your app entry point:
12
-
13
- ```typescript
14
- import '@jaw.id/ui/style.css';
13
+ # or
14
+ bun add @jaw.id/ui
15
15
  ```
16
16
 
17
17
  ## Quick Start
18
18
 
19
- Use `ReactUIHandler` with app-specific passkey mode:
20
-
21
19
  ```tsx
22
20
  import { JAW } from '@jaw.id/core';
23
21
  import { ReactUIHandler } from '@jaw.id/ui';
24
- import '@jaw.id/ui/style.css';
25
22
 
26
- const uiHandler = new ReactUIHandler({
27
- container: document.getElementById('jaw-ui-root')!,
28
- });
23
+ const uiHandler = new ReactUIHandler();
29
24
 
30
- const jaw = await JAW.create({
25
+ const jaw = JAW.create({
31
26
  apiKey: 'your-api-key',
32
27
  appName: 'My App',
33
- mode: 'appSpecific',
34
- uiHandler,
28
+ preference: {
29
+ mode: 'AppSpecific',
30
+ uiHandler,
31
+ },
35
32
  });
36
33
  ```
37
34
 
38
- ## Exports
35
+ ## AI-Assisted Development
39
36
 
40
- **Dialog Components:** `OnboardingDialog`, `ConnectDialog`, `TransactionDialog`, `SignatureDialog`, `Eip712Dialog`, `SiweDialog`, `PermissionDialog`, `DefaultDialog`
37
+ Add JAW.id skills to your AI coding agent:
41
38
 
42
- **React Integration:** `ReactUIHandler` - Complete UIHandler implementation for app-specific mode
43
-
44
- ## Peer Dependencies
45
-
46
- - `react` >= 18.0.0
47
- - `react-dom` >= 18.0.0
48
-
49
- ## Documentation
50
-
51
- For detailed guides and examples, visit **[docs.jaw.id](https://docs.jaw.id)**.
39
+ ```bash
40
+ npx skills add JustaName-id/jaw-skills
41
+ ```
52
42
 
53
43
  ## License
54
44
 
package/cjs-error.cjs ADDED
@@ -0,0 +1,3 @@
1
+ throw new Error(
2
+ '@jaw.id/ui is ESM-only. Use ESM imports or dynamic import("@jaw.id/ui").'
3
+ );
@@ -1,4 +1,4 @@
1
- import { B as p, g as m, s as w, d as k, i as b, l as L, a as O, c as R, b as E, e as x, H as y, f as M } from "./index-Dy2WdHwt.js";
1
+ import { B as p, g as m, s as w, d as k, i as b, l as L, a as O, c as R, b as E, e as x, H as y, f as M } from "./index-BcDVfcdq.js";
2
2
  class S extends p {
3
3
  constructor({ callbackSelector: s, cause: e, data: o, extraData: n, sender: c, urls: t }) {
4
4
  super(e.shortMessage || "An error occurred while fetching for an offchain result.", {