@n1xyz/wallet-widget 0.0.1

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 (111) hide show
  1. package/.eslintrc.js +29 -0
  2. package/dist/Common/NIcon.d.ts +1 -0
  3. package/dist/Common/NIcon.js +7 -0
  4. package/dist/Logic/getPseudoName.d.ts +1 -0
  5. package/dist/Logic/getPseudoName.js +5825 -0
  6. package/dist/Logic/utils.d.ts +20 -0
  7. package/dist/Logic/utils.js +199 -0
  8. package/dist/Logic/words.d.ts +9 -0
  9. package/dist/Logic/words.js +93571 -0
  10. package/dist/Modal/BackButton.d.ts +3 -0
  11. package/dist/Modal/BackButton.js +13 -0
  12. package/dist/Modal/ConnectView.d.ts +1 -0
  13. package/dist/Modal/ConnectView.js +71 -0
  14. package/dist/Modal/CreateSessionView.d.ts +1 -0
  15. package/dist/Modal/CreateSessionView.js +236 -0
  16. package/dist/Modal/CreateUserView.d.ts +1 -0
  17. package/dist/Modal/CreateUserView.js +160 -0
  18. package/dist/Modal/ModalHeader.d.ts +1 -0
  19. package/dist/Modal/ModalHeader.js +9 -0
  20. package/dist/Modal/N1WalletModal.d.ts +1 -0
  21. package/dist/Modal/N1WalletModal.js +232 -0
  22. package/dist/Modal/NoWhitelistView.d.ts +1 -0
  23. package/dist/Modal/NoWhitelistView.js +29 -0
  24. package/dist/Modal/Sidebar/N1Sidebar.d.ts +1 -0
  25. package/dist/Modal/Sidebar/N1Sidebar.js +38 -0
  26. package/dist/Modal/SigningView.d.ts +1 -0
  27. package/dist/Modal/SigningView.js +5 -0
  28. package/dist/Modal/SuccessView.d.ts +1 -0
  29. package/dist/Modal/SuccessView.js +10 -0
  30. package/dist/Provider/LazyWalletProvider.d.ts +1 -0
  31. package/dist/Provider/LazyWalletProvider.js +160 -0
  32. package/dist/Provider/N1WalletProvider.d.ts +2 -0
  33. package/dist/Provider/N1WalletProvider.js +219 -0
  34. package/dist/Provider/context.d.ts +5 -0
  35. package/dist/Provider/context.js +4 -0
  36. package/dist/Provider/hooks.d.ts +2 -0
  37. package/dist/Provider/hooks.js +16 -0
  38. package/dist/Provider/icons/CoinbaseWalletIcon.d.ts +1 -0
  39. package/dist/Provider/icons/CoinbaseWalletIcon.js +4 -0
  40. package/dist/Provider/icons/ConnectionDotsSVG.d.ts +1 -0
  41. package/dist/Provider/icons/ConnectionDotsSVG.js +4 -0
  42. package/dist/Provider/icons/MetamaskIcon.d.ts +1 -0
  43. package/dist/Provider/icons/MetamaskIcon.js +4 -0
  44. package/dist/Provider/icons/PhantomIcon.d.ts +1 -0
  45. package/dist/Provider/icons/PhantomIcon.js +4 -0
  46. package/dist/Provider/icons/UserIcon.d.ts +1 -0
  47. package/dist/Provider/icons/UserIcon.js +4 -0
  48. package/dist/Provider/icons/WalletConnectIcon.d.ts +1 -0
  49. package/dist/Provider/icons/WalletConnectIcon.js +4 -0
  50. package/dist/Provider/index.d.ts +3 -0
  51. package/dist/Provider/index.js +3 -0
  52. package/dist/Provider/types.d.ts +68 -0
  53. package/dist/Provider/types.js +14 -0
  54. package/dist/WidgetButton/N1ConnectButton.d.ts +5 -0
  55. package/dist/WidgetButton/N1ConnectButton.js +24 -0
  56. package/dist/components/AnimatedButton.d.ts +9 -0
  57. package/dist/components/AnimatedButton.js +5 -0
  58. package/dist/components/LazyLoadWrapper.d.ts +8 -0
  59. package/dist/components/LazyLoadWrapper.js +17 -0
  60. package/dist/config.d.ts +2 -0
  61. package/dist/config.js +2 -0
  62. package/dist/errors/types.d.ts +21 -0
  63. package/dist/errors/types.js +64 -0
  64. package/dist/index.d.ts +5 -0
  65. package/dist/index.js +5 -0
  66. package/dist/main.css +1 -0
  67. package/dist/utils/lazyLoad.d.ts +3 -0
  68. package/dist/utils/lazyLoad.js +9 -0
  69. package/dist/utils/logger.d.ts +20 -0
  70. package/dist/utils/logger.js +106 -0
  71. package/dist/utils/react-shim.d.ts +2 -0
  72. package/dist/utils/react-shim.js +6 -0
  73. package/package.json +46 -0
  74. package/postcss.config.js +6 -0
  75. package/src/Logic/getPseudoName.ts +5832 -0
  76. package/src/Logic/utils.ts +162 -0
  77. package/src/Logic/words.ts +93571 -0
  78. package/src/Modal/BackButton.tsx +23 -0
  79. package/src/Modal/ConnectView.tsx +88 -0
  80. package/src/Modal/CreateSessionView.tsx +242 -0
  81. package/src/Modal/CreateUserView.tsx +195 -0
  82. package/src/Modal/ModalHeader.tsx +64 -0
  83. package/src/Modal/N1WalletModal.tsx +275 -0
  84. package/src/Modal/NoWhitelistView.tsx +61 -0
  85. package/src/Modal/Sidebar/N1Sidebar.tsx +172 -0
  86. package/src/Modal/SigningView.tsx +18 -0
  87. package/src/Modal/SuccessView.tsx +36 -0
  88. package/src/Provider/LazyWalletProvider.tsx +136 -0
  89. package/src/Provider/N1WalletProvider.tsx +208 -0
  90. package/src/Provider/context.ts +11 -0
  91. package/src/Provider/hooks.ts +22 -0
  92. package/src/Provider/icons/CoinbaseWalletIcon.tsx +27 -0
  93. package/src/Provider/icons/ConnectionDotsSVG.tsx +19 -0
  94. package/src/Provider/icons/MetamaskIcon.tsx +58 -0
  95. package/src/Provider/icons/PhantomIcon.tsx +26 -0
  96. package/src/Provider/icons/UserIcon.tsx +15 -0
  97. package/src/Provider/icons/WalletConnectIcon.tsx +15 -0
  98. package/src/Provider/index.ts +3 -0
  99. package/src/Provider/types.ts +77 -0
  100. package/src/WidgetButton/N1ConnectButton.tsx +72 -0
  101. package/src/components/LazyLoadWrapper.tsx +19 -0
  102. package/src/config.ts +2 -0
  103. package/src/errors/types.ts +49 -0
  104. package/src/index.ts +5 -0
  105. package/src/main.css +3 -0
  106. package/src/styles/main.css +3 -0
  107. package/src/utils/lazyLoad.ts +12 -0
  108. package/src/utils/logger.ts +98 -0
  109. package/src/utils/react-shim.js +8 -0
  110. package/tailwind.config.js +44 -0
  111. package/tsconfig.json +21 -0
@@ -0,0 +1,219 @@
1
+ 'use client';
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
17
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
18
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
19
+ return new (P || (P = Promise))(function (resolve, reject) {
20
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
21
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
22
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
23
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
24
+ });
25
+ };
26
+ var __generator = (this && this.__generator) || function (thisArg, body) {
27
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
28
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
29
+ function verb(n) { return function (v) { return step([n, v]); }; }
30
+ function step(op) {
31
+ if (f) throw new TypeError("Generator is already executing.");
32
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
33
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
34
+ if (y = 0, t) op = [op[0] & 2, t.value];
35
+ switch (op[0]) {
36
+ case 0: case 1: t = op; break;
37
+ case 4: _.label++; return { value: op[1], done: false };
38
+ case 5: _.label++; y = op[1]; op = [0]; continue;
39
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
40
+ default:
41
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
42
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
43
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
44
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
45
+ if (t[2]) _.ops.pop();
46
+ _.trys.pop(); continue;
47
+ }
48
+ op = body.call(thisArg, _);
49
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
50
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
51
+ }
52
+ };
53
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
54
+ import React, { Suspense, useCallback, useEffect, useState } from 'react';
55
+ import { N1WalletModal } from '../Modal/N1WalletModal';
56
+ import { WalletError, WalletErrorCode } from '../errors/types';
57
+ import { N1InternalWalletContext, N1WalletContext } from './context';
58
+ import { N1ModalViewMode, N1SessionMode } from './types';
59
+ var LazyWalletProvider = React.lazy(function () {
60
+ return import('./LazyWalletProvider').then(function (mod) { return ({
61
+ default: mod.LazyWalletProvider,
62
+ }); });
63
+ });
64
+ // Error boundary to catch WalletErrors
65
+ var WalletErrorBoundary = /** @class */ (function (_super) {
66
+ __extends(WalletErrorBoundary, _super);
67
+ function WalletErrorBoundary() {
68
+ return _super !== null && _super.apply(this, arguments) || this;
69
+ }
70
+ WalletErrorBoundary.prototype.componentDidCatch = function (error) {
71
+ if (error instanceof WalletError) {
72
+ this.props.onError(error);
73
+ }
74
+ else {
75
+ // Convert unknown errors to WalletError
76
+ this.props.onError(new WalletError(WalletErrorCode.UNKNOWN, error.message || 'An unexpected error occurred', { originalError: error }));
77
+ }
78
+ };
79
+ WalletErrorBoundary.prototype.render = function () {
80
+ return this.props.children;
81
+ };
82
+ return WalletErrorBoundary;
83
+ }(React.Component));
84
+ export function N1WalletProvider(_a) {
85
+ var _this = this;
86
+ var children = _a.children, providedSessionMode = _a.providedSessionMode, appId = _a.appId, _b = _a.darkMode, darkMode = _b === void 0 ? true : _b, onError = _a.onError;
87
+ var _c = useState(false), isConnected = _c[0], setIsConnected = _c[1];
88
+ var _d = useState(null), ntsInterface = _d[0], setNtsInterface = _d[1];
89
+ var _e = useState(false), showLogin = _e[0], setShowLogin = _e[1];
90
+ var _f = useState(null), sessionPubKey = _f[0], setSessionPubKey = _f[1];
91
+ var _g = useState(null), walletPubKey = _g[0], setWalletPubKey = _g[1];
92
+ var _h = useState(null), userChain = _h[0], setUserChain = _h[1];
93
+ var _j = useState(''), username = _j[0], setUsername = _j[1];
94
+ var _k = useState(null), signMessageWithSessionKey = _k[0], setSignMessageWithSessionKey = _k[1];
95
+ var _l = useState(null), signMessageWithWalletKey = _l[0], setSignMessageWithWalletKey = _l[1];
96
+ var _m = useState(false), showSidebar = _m[0], setShowSidebar = _m[1];
97
+ var _o = useState(false), startClosingLogin = _o[0], setStartClosingLogin = _o[1];
98
+ var _p = useState(false), loading = _p[0], setLoading = _p[1];
99
+ var _q = useState(N1ModalViewMode.Connect), viewMode = _q[0], setViewMode = _q[1];
100
+ // Log initialization only once on mount
101
+ useEffect(function () {
102
+ // eslint-disable-next-line no-console
103
+ console.log('N1WalletProvider initializing');
104
+ }, []);
105
+ // dynamic
106
+ var _r = useState(''), address = _r[0], setAddress = _r[1];
107
+ var _s = useState(''), chain = _s[0], setChain = _s[1];
108
+ var _t = useState(null), dynamicSdkHasLoaded = _t[0], setDynamicSdkHasLoaded = _t[1];
109
+ var _u = useState(null), dynamicHandleLogOut = _u[0], setDynamicHandleLogOut = _u[1];
110
+ var _v = useState(null), sessionMode = _v[0], setSessionMode = _v[1];
111
+ var _w = useState(null), dynamicWallet = _w[0], setDynamicWallet = _w[1];
112
+ var _x = useState(null), showDynamicWidget = _x[0], setShowDynamicWidget = _x[1];
113
+ // Combine SDK loading and initialization into a single effect
114
+ useEffect(function () {
115
+ var mounted = true;
116
+ var loadNTSSDK = function () { return __awaiter(_this, void 0, void 0, function () {
117
+ var NTSInterface, error_1;
118
+ return __generator(this, function (_a) {
119
+ switch (_a.label) {
120
+ case 0:
121
+ // eslint-disable-next-line no-console
122
+ console.log('Loading NTS SDK');
123
+ if (providedSessionMode === N1SessionMode.Nord) {
124
+ // eslint-disable-next-line no-console
125
+ console.log('Nord mode, skipping NTS SDK load');
126
+ return [2 /*return*/];
127
+ }
128
+ _a.label = 1;
129
+ case 1:
130
+ _a.trys.push([1, 3, , 4]);
131
+ return [4 /*yield*/, import('@n1xyz/nts-sdk')];
132
+ case 2:
133
+ NTSInterface = (_a.sent()).NTSInterface;
134
+ if (mounted) {
135
+ // eslint-disable-next-line no-console
136
+ console.log('NTS SDK loaded successfully');
137
+ setNtsInterface(new NTSInterface(process.env.NTS_URL));
138
+ }
139
+ return [3 /*break*/, 4];
140
+ case 3:
141
+ error_1 = _a.sent();
142
+ if (mounted) {
143
+ // eslint-disable-next-line no-console
144
+ console.error('Error loading NTS SDK:', error_1);
145
+ }
146
+ return [3 /*break*/, 4];
147
+ case 4: return [2 /*return*/];
148
+ }
149
+ });
150
+ }); };
151
+ loadNTSSDK();
152
+ return function () {
153
+ mounted = false;
154
+ };
155
+ }, [providedSessionMode]);
156
+ // Separate effect to handle loading state based on both SDKs
157
+ useEffect(function () {
158
+ var isDynamicReady = dynamicSdkHasLoaded || providedSessionMode === N1SessionMode.Nord;
159
+ var isNtsReady = ntsInterface || providedSessionMode === N1SessionMode.Nord;
160
+ setLoading(!isDynamicReady || !isNtsReady);
161
+ }, [dynamicSdkHasLoaded, ntsInterface, providedSessionMode]);
162
+ var handleError = useCallback(function (error) {
163
+ onError === null || onError === void 0 ? void 0 : onError(error);
164
+ }, [onError]);
165
+ // Simple function to test error handler
166
+ var throwTestError = function () { return __awaiter(_this, void 0, void 0, function () {
167
+ return __generator(this, function (_a) {
168
+ handleError(new WalletError(WalletErrorCode.WALLET_NOT_FOUND, 'Test error: No compatible wallet was found'));
169
+ return [2 /*return*/];
170
+ });
171
+ }); };
172
+ return (_jsx(WalletErrorBoundary, { onError: handleError, children: _jsx(N1WalletContext.Provider, { value: {
173
+ address: address,
174
+ appId: appId,
175
+ chain: chain,
176
+ isConnected: isConnected,
177
+ ntsInterface: ntsInterface,
178
+ sessionMode: sessionMode,
179
+ sessionPubKey: sessionPubKey,
180
+ setShowLogin: setShowLogin,
181
+ showLogin: showLogin,
182
+ signMessageWithSessionKey: signMessageWithSessionKey,
183
+ signMessageWithWalletKey: signMessageWithWalletKey,
184
+ userChain: userChain,
185
+ username: username,
186
+ viewMode: viewMode,
187
+ walletPubKey: walletPubKey,
188
+ throwTestError: throwTestError,
189
+ }, children: _jsxs(N1InternalWalletContext.Provider, { value: {
190
+ dynamicHandleLogOut: dynamicHandleLogOut,
191
+ dynamicWallet: dynamicWallet,
192
+ loading: loading,
193
+ dynamicSdkHasLoaded: dynamicSdkHasLoaded,
194
+ handleError: handleError,
195
+ setDynamicSdkHasLoaded: setDynamicSdkHasLoaded,
196
+ setAddress: setAddress,
197
+ setChain: setChain,
198
+ setDynamicHandleLogOut: setDynamicHandleLogOut,
199
+ setDynamicWallet: setDynamicWallet,
200
+ setIsConnected: setIsConnected,
201
+ setLoading: setLoading,
202
+ setNtsInterface: setNtsInterface,
203
+ setSessionMode: setSessionMode,
204
+ setSessionPubKey: setSessionPubKey,
205
+ setShowSidebar: setShowSidebar,
206
+ setSignMessageWithSessionKey: setSignMessageWithSessionKey,
207
+ setSignMessageWithWalletKey: setSignMessageWithWalletKey,
208
+ setStartClosingLogin: setStartClosingLogin,
209
+ setUsername: setUsername,
210
+ setUserChain: setUserChain,
211
+ setViewMode: setViewMode,
212
+ setWalletPubKey: setWalletPubKey,
213
+ showSidebar: showSidebar,
214
+ startClosingLogin: startClosingLogin,
215
+ showDynamicWidget: showDynamicWidget,
216
+ setShowDynamicWidget: setShowDynamicWidget,
217
+ darkMode: darkMode,
218
+ }, children: [children, _jsx(N1WalletModal, {}), _jsx(Suspense, { fallback: null, children: _jsx(LazyWalletProvider, {}) })] }) }) }));
219
+ }
@@ -0,0 +1,5 @@
1
+ import { N1WalletState } from './types';
2
+ import { N1InternalWalletState } from './types';
3
+ declare const N1WalletContext: import("react").Context<N1WalletState>;
4
+ declare const N1InternalWalletContext: import("react").Context<N1InternalWalletState>;
5
+ export { N1WalletContext, N1InternalWalletContext };
@@ -0,0 +1,4 @@
1
+ import { createContext } from 'react';
2
+ var N1WalletContext = createContext({});
3
+ var N1InternalWalletContext = createContext({});
4
+ export { N1WalletContext, N1InternalWalletContext };
@@ -0,0 +1,2 @@
1
+ export declare function useN1WalletContext(): import("./types").N1WalletState;
2
+ export declare function useN1WalletInternalContext(): import("./types").N1InternalWalletState;
@@ -0,0 +1,16 @@
1
+ import { useContext } from 'react';
2
+ import { N1WalletContext, N1InternalWalletContext } from './context';
3
+ export function useN1WalletContext() {
4
+ var context = useContext(N1WalletContext);
5
+ if (context === undefined) {
6
+ throw new Error('useN1WalletContext must be used within a N1WalletProvider');
7
+ }
8
+ return context;
9
+ }
10
+ export function useN1WalletInternalContext() {
11
+ var context = useContext(N1InternalWalletContext);
12
+ if (context === undefined) {
13
+ throw new Error('useN1WalletInternalContext must be used within a N1WalletProvider');
14
+ }
15
+ return context;
16
+ }
@@ -0,0 +1 @@
1
+ export declare function CoinbaseWalletIcon(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ export function CoinbaseWalletIcon() {
3
+ return (_jsxs("svg", { width: "1.5em", height: "1.5em", xmlns: "http://www.w3.org/2000/svg", xmlnsXlink: "http://www.w3.org/1999/xlink", version: "1.2", baseProfile: "tiny", id: "Layer_1", x: "0px", y: "0px", viewBox: "0 0 1024 1024", overflow: "visible", xmlSpace: "preserve", children: [_jsx("path", { fill: "#0052FF", d: "M512,0L512,0c282.8,0,512,229.2,512,512l0,0c0,282.8-229.2,512-512,512l0,0C229.2,1024,0,794.8,0,512l0,0 C0,229.2,229.2,0,512,0z" }), _jsx("path", { fill: "#FFFFFF", d: "M512.1,692c-99.4,0-180-80.5-180-180s80.6-180,180-180c89.1,0,163.1,65,177.3,150h181.3 c-15.3-184.8-170-330-358.7-330c-198.8,0-360,161.2-360,360s161.2,360,360,360c188.7,0,343.4-145.2,358.7-330H689.3 C675,627,601.2,692,512.1,692z" })] }));
4
+ }
@@ -0,0 +1 @@
1
+ export declare function ConnectionDotsSVG(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ export function ConnectionDotsSVG() {
3
+ return (_jsxs("svg", { width: "56", height: "12", viewBox: "0 0 56 12", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [_jsx("circle", { cx: "19.5", cy: "2.5", r: "2.5", fill: "#6e6e6e" }), _jsx("circle", { cx: "36.5", cy: "2.5", r: "2.5", fill: "#6e6e6e" }), _jsx("circle", { cx: "2.5", cy: "2.5", r: "2.5", fill: "#6e6e6e" }), _jsx("circle", { cx: "53.5", cy: "2.5", r: "2.5", fill: "#6e6e6e" }), _jsx("circle", { cx: "12.5", cy: "9.5", r: "2.5", fill: "#6e6e6e" }), _jsx("circle", { cx: "29.5", cy: "9.5", r: "2.5", fill: "#6e6e6e" }), _jsx("circle", { cx: "46.5", cy: "9.5", r: "2.5", fill: "#6e6e6e" })] }));
4
+ }
@@ -0,0 +1 @@
1
+ export declare function MetamaskIcon(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
+ export function MetamaskIcon() {
3
+ return (_jsx(_Fragment, { children: _jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "1.5em", height: "1.5em", viewBox: "0 0 256 240", children: [_jsx("path", { fill: "#e17726", d: "M250.066 0L140.219 81.279l20.427-47.9z" }), _jsx("path", { fill: "#e27625", d: "m6.191.096l89.181 33.289l19.396 48.528zM205.86 172.858l48.551.924l-16.968 57.642l-59.243-16.311zm-155.721 0l27.557 42.255l-59.143 16.312l-16.865-57.643z" }), _jsx("path", { fill: "#e27625", d: "m112.131 69.552l1.984 64.083l-59.371-2.701l16.888-25.478l.214-.245zm31.123-.715l40.9 36.376l.212.244l16.888 25.478l-59.358 2.7zM79.435 173.044l32.418 25.259l-37.658 18.181zm97.136-.004l5.131 43.445l-37.553-18.184z" }), _jsx("path", { fill: "#d5bfb2", d: "m144.978 195.922l38.107 18.452l-35.447 16.846l.368-11.134zm-33.967.008l-2.909 23.974l.239 11.303l-35.53-16.833z" }), _jsx("path", { fill: "#233447", d: "m100.007 141.999l9.958 20.928l-33.903-9.932zm55.985.002l24.058 10.994l-34.014 9.929z" }), _jsx("path", { fill: "#cc6228", d: "m82.026 172.83l-5.48 45.04l-29.373-44.055zm91.95.001l34.854.984l-29.483 44.057zm28.136-44.444l-25.365 25.851l-19.557-8.937l-9.363 19.684l-6.138-33.849zm-148.237 0l60.435 2.749l-6.139 33.849l-9.365-19.681l-19.453 8.935z" }), _jsx("path", { fill: "#e27525", d: "m52.166 123.082l28.698 29.121l.994 28.749zm151.697-.052l-29.746 57.973l1.12-28.8zm-90.956 1.826l1.155 7.27l2.854 18.111l-1.835 55.625l-8.675-44.685l-.003-.462zm30.171-.101l6.521 35.96l-.003.462l-8.697 44.797l-.344-11.205l-1.357-44.862z" }), _jsx("path", { fill: "#f5841f", d: "m177.788 151.046l-.971 24.978l-30.274 23.587l-6.12-4.324l6.86-35.335zm-99.471 0l30.399 8.906l6.86 35.335l-6.12 4.324l-30.275-23.589z" }), _jsx("path", { fill: "#c0ac9d", d: "m67.018 208.858l38.732 18.352l-.164-7.837l3.241-2.845h38.334l3.358 2.835l-.248 7.831l38.487-18.29l-18.728 15.476l-22.645 15.553h-38.869l-22.63-15.617z" }), _jsx("path", { fill: "#161616", d: "m142.204 193.479l5.476 3.869l3.209 25.604l-4.644-3.921h-36.476l-4.556 4l3.104-25.681l5.478-3.871z" }), _jsx("path", { fill: "#763e1a", d: "M242.814 2.25L256 41.807l-8.235 39.997l5.864 4.523l-7.935 6.054l5.964 4.606l-7.897 7.191l4.848 3.511l-12.866 15.026l-52.77-15.365l-.457-.245l-38.027-32.078zm-229.628 0l98.326 72.777l-38.028 32.078l-.457.245l-52.77 15.365l-12.866-15.026l4.844-3.508l-7.892-7.194l5.952-4.601l-8.054-6.071l6.085-4.526L0 41.809z" }), _jsx("path", { fill: "#f5841f", d: "m180.392 103.99l55.913 16.279l18.165 55.986h-47.924l-33.02.416l24.014-46.808zm-104.784 0l-17.151 25.873l24.017 46.808l-33.005-.416H1.631l18.063-55.985zm87.776-70.878l-15.639 42.239l-3.319 57.06l-1.27 17.885l-.101 45.688h-30.111l-.098-45.602l-1.274-17.986l-3.32-57.045l-15.637-42.239z" })] }) }));
4
+ }
@@ -0,0 +1 @@
1
+ export declare function PhantomIcon(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ export function PhantomIcon() {
3
+ return (_jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "1.5em", height: "1.5em", viewBox: "0 0 1200 1200", fill: "none", children: [_jsxs("g", { clipPath: "url(#clip0_2800_140397)", children: [_jsx("rect", { width: "1200", height: "1200", fill: "#9886E5" }), _jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M516.641 777.604C466.226 854.856 381.747 952.618 269.335 952.618C216.194 952.618 165.098 930.741 165.098 835.714C165.098 593.704 495.521 219.066 802.1 219.066C976.509 219.066 1046 340.071 1046 477.484C1046 653.865 931.544 855.54 817.77 855.54C781.661 855.54 763.948 835.714 763.948 804.267C763.948 796.063 765.311 787.175 768.036 777.604C729.202 843.918 654.261 905.446 584.089 905.446C532.992 905.446 507.103 873.315 507.103 828.194C507.103 811.787 510.51 794.696 516.641 777.604ZM930.877 472.714C930.877 512.755 907.253 532.776 880.826 532.776C853.998 532.776 830.775 512.755 830.775 472.714C830.775 432.673 853.998 412.653 880.826 412.653C907.253 412.653 930.877 432.673 930.877 472.714ZM780.73 472.714C780.73 512.755 757.105 532.776 730.678 532.776C703.851 532.776 680.627 512.755 680.627 472.714C680.627 432.673 703.851 412.653 730.678 412.653C757.105 412.653 780.73 432.673 780.73 472.714Z", fill: "#FFFDF8" })] }), _jsx("defs", { children: _jsx("clipPath", { id: "clip0_2800_140397", children: _jsx("rect", { width: "1200", height: "1200", fill: "white" }) }) })] }));
4
+ }
@@ -0,0 +1 @@
1
+ export declare function UserIcon(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ export function UserIcon() {
3
+ return (_jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: _jsx("path", { fillRule: "evenodd", d: "M18.685 19.097A9.723 9.723 0 0 0 21.75 12c0-5.385-4.365-9.75-9.75-9.75S2.25 6.615 2.25 12a9.723 9.723 0 0 0 3.065 7.097A9.716 9.716 0 0 0 12 20.25a9.716 9.716 0 0 0 6.685-2.653Zm-12.54-1.285A7.486 7.486 0 0 1 12 15a7.486 7.486 0 0 1 5.855 2.812A8.224 8.224 0 0 1 12 20.25a8.224 8.224 0 0 1-5.855-2.438ZM15.75 9a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0Z", clipRule: "evenodd" }) }));
4
+ }
@@ -0,0 +1 @@
1
+ export declare function WalletConnectIcon(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ export function WalletConnectIcon() {
3
+ return (_jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "1.5em", height: "1.5em", viewBox: "0 0 24 24", children: _jsx("path", { fill: "#388eff", d: "M4.913 7.519c3.915-3.831 10.26-3.831 14.174 0l.471.461a.483.483 0 0 1 0 .694l-1.611 1.577a.252.252 0 0 1-.354 0l-.649-.634c-2.73-2.673-7.157-2.673-9.887 0l-.694.68a.255.255 0 0 1-.355 0L4.397 8.719a.482.482 0 0 1 0-.693l.516-.507Zm17.506 3.263l1.434 1.404a.483.483 0 0 1 0 .694l-6.466 6.331a.508.508 0 0 1-.709 0l-4.588-4.493a.126.126 0 0 0-.178 0l-4.589 4.493a.508.508 0 0 1-.709 0L.147 12.88a.483.483 0 0 1 0-.694l1.434-1.404a.508.508 0 0 1 .709 0l4.589 4.493c.05.048.129.048.178 0l4.589-4.493a.508.508 0 0 1 .709 0l4.589 4.493c.05.048.128.048.178 0l4.589-4.493a.507.507 0 0 1 .708 0Z" }) }));
4
+ }
@@ -0,0 +1,3 @@
1
+ export * from './types';
2
+ export { N1WalletProvider } from './N1WalletProvider';
3
+ export { useN1WalletContext, useN1WalletInternalContext } from './hooks';
@@ -0,0 +1,3 @@
1
+ export * from './types';
2
+ export { N1WalletProvider } from './N1WalletProvider';
3
+ export { useN1WalletContext, useN1WalletInternalContext } from './hooks';
@@ -0,0 +1,68 @@
1
+ import type { WalletError } from '../errors/types';
2
+ export declare enum N1ModalViewMode {
3
+ Connect = 0,
4
+ CreateSession = 1,
5
+ Signing = 2,
6
+ CreatingUser = 3,
7
+ Success = 4,
8
+ NoWhitelist = 5
9
+ }
10
+ export declare enum N1SessionMode {
11
+ Nord = 0,
12
+ NTS = 1
13
+ }
14
+ export interface N1WalletProviderProps {
15
+ children: React.ReactNode;
16
+ providedSessionMode: N1SessionMode;
17
+ appId: string;
18
+ darkMode?: boolean;
19
+ onError?: (error: WalletError) => void;
20
+ }
21
+ export interface N1WalletState {
22
+ address: string;
23
+ appId: string | null;
24
+ chain: string;
25
+ isConnected: boolean;
26
+ ntsInterface: any;
27
+ sessionMode: N1SessionMode | null;
28
+ sessionPubKey: Uint8Array | null;
29
+ setShowLogin: (show: boolean) => void;
30
+ showLogin: boolean;
31
+ signMessageWithSessionKey: ((message: any) => Promise<any>) | null;
32
+ signMessageWithWalletKey: ((message: any) => Promise<any>) | null;
33
+ userChain: string | null;
34
+ username: string;
35
+ viewMode: N1ModalViewMode;
36
+ walletPubKey: Uint8Array | null;
37
+ throwTestError: () => Promise<void>;
38
+ }
39
+ export interface N1InternalWalletState {
40
+ dynamicHandleLogOut: any;
41
+ dynamicWallet: any;
42
+ loading: boolean;
43
+ dynamicSdkHasLoaded: any;
44
+ handleError: (error: WalletError) => void;
45
+ setDynamicSdkHasLoaded: (loaded: any) => void;
46
+ setAddress: (address: string) => void;
47
+ setChain: (chain: string) => void;
48
+ setDynamicHandleLogOut: (handler: any) => void;
49
+ setDynamicWallet: (wallet: any) => void;
50
+ setIsConnected: (connected: boolean) => void;
51
+ setLoading: (loading: boolean) => void;
52
+ setNtsInterface: (nts: any) => void;
53
+ setSessionMode: (mode: N1SessionMode | null) => void;
54
+ setSessionPubKey: (key: Uint8Array) => void;
55
+ setShowSidebar: (show: boolean) => void;
56
+ setSignMessageWithSessionKey: React.Dispatch<React.SetStateAction<((message: any) => Promise<any>) | null>>;
57
+ setSignMessageWithWalletKey: React.Dispatch<React.SetStateAction<((message: any) => Promise<any>) | null>>;
58
+ setStartClosingLogin: (closing: boolean) => void;
59
+ setUsername: (username: string) => void;
60
+ setUserChain: (chain: string) => void;
61
+ setViewMode: (mode: N1ModalViewMode) => void;
62
+ setWalletPubKey: (key: Uint8Array) => void;
63
+ showSidebar: boolean;
64
+ startClosingLogin: boolean;
65
+ showDynamicWidget: any;
66
+ setShowDynamicWidget: (show: any) => void;
67
+ darkMode: boolean;
68
+ }
@@ -0,0 +1,14 @@
1
+ export var N1ModalViewMode;
2
+ (function (N1ModalViewMode) {
3
+ N1ModalViewMode[N1ModalViewMode["Connect"] = 0] = "Connect";
4
+ N1ModalViewMode[N1ModalViewMode["CreateSession"] = 1] = "CreateSession";
5
+ N1ModalViewMode[N1ModalViewMode["Signing"] = 2] = "Signing";
6
+ N1ModalViewMode[N1ModalViewMode["CreatingUser"] = 3] = "CreatingUser";
7
+ N1ModalViewMode[N1ModalViewMode["Success"] = 4] = "Success";
8
+ N1ModalViewMode[N1ModalViewMode["NoWhitelist"] = 5] = "NoWhitelist";
9
+ })(N1ModalViewMode || (N1ModalViewMode = {}));
10
+ export var N1SessionMode;
11
+ (function (N1SessionMode) {
12
+ N1SessionMode[N1SessionMode["Nord"] = 0] = "Nord";
13
+ N1SessionMode[N1SessionMode["NTS"] = 1] = "NTS";
14
+ })(N1SessionMode || (N1SessionMode = {}));
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ export declare function N1ConnectButton(_props: {
3
+ label: string;
4
+ children?: React.ReactNode;
5
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,24 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import BlockiesSvg from 'blockies-react-svg';
3
+ import { useEffect, useState } from 'react';
4
+ import { useN1WalletContext, useN1WalletInternalContext, } from '../Provider/hooks';
5
+ import { logger } from '../utils/logger';
6
+ export function N1ConnectButton(_props) {
7
+ var _a = useN1WalletContext(), isConnected = _a.isConnected, setShowLogin = _a.setShowLogin, address = _a.address;
8
+ var _b = useState(false), toOpen = _b[0], setToOpen = _b[1];
9
+ var _c = useN1WalletInternalContext(), setShowSidebar = _c.setShowSidebar, loading = _c.loading, darkMode = _c.darkMode, showSidebar = _c.showSidebar;
10
+ var addressText = isConnected && address.substring(0, 9) + '...' + address.slice(-3);
11
+ var showLoginFn = function () {
12
+ setShowLogin(true);
13
+ };
14
+ useEffect(function () {
15
+ if (!loading && toOpen) {
16
+ showLoginFn();
17
+ setToOpen(false);
18
+ }
19
+ }, [loading]);
20
+ return (_jsx("div", { className: darkMode ? 'dark' : '', children: _jsxs("div", { className: "flex", children: [!isConnected && !loading && (_jsx("div", { className: "rounded-xl shadow cursor-pointer px-3 py-2 duration-300 hover:bg-stone-100 text-sm flex items-center justify-center h-10 min-w-24 group-hover:opacity-80 bg-white dark:bg-neutral-900 text-neutral-900 dark:text-stone-200 border border-neutral-200 dark:border-neutral-700", onClick: showLoginFn, children: _jsx("span", { className: "font-bold mr-0.5", children: "Connect" }) })), loading && !isConnected && (_jsx("div", { className: "rounded-xl shadow cursor-pointer px-3 py-2 duration-300 hover:opacity-80 text-sm flex items-center justify-center h-10 min-w-24 group-hover:opacity-80 bg-white dark:bg-neutral-900 text-neutral-900 dark:text-stone-200 border border-neutral-200 dark:border-neutral-700", onClick: function () { return setToOpen(true); }, children: _jsx("span", { className: "font-bold mr-0.5", children: "Connect" }) })), isConnected && (_jsx("div", { className: "relative group", children: _jsxs("div", { className: "rounded-xl shadow cursor-pointer px-3 py-2 duration-300 hover:opacity-80 text-sm flex items-center justify-start h-10 min-w-24 group-hover:opacity-80 bg-white dark:bg-neutral-900 text-neutral-900 dark:text-stone-200 border border-neutral-200 dark:border-neutral-700", onClick: function () {
21
+ logger.debug('ShowSidebar');
22
+ setShowSidebar(true);
23
+ }, children: [_jsx("div", { className: "h-6 w-6 rounded-full", children: _jsx(BlockiesSvg, { address: address, className: "drop-shadow w-full h-full rounded-full" }) }), _jsx("div", { className: "ml-2", children: addressText })] }) }))] }) }));
24
+ }
@@ -0,0 +1,9 @@
1
+ interface AnimatedButtonProps {
2
+ onClick: () => void;
3
+ children: any;
4
+ hoverColor?: string;
5
+ baseColor?: string;
6
+ className?: string;
7
+ }
8
+ export default function AnimatedButton({ onClick, children, hoverColor, baseColor, className, }: AnimatedButtonProps): import("react/jsx-runtime").JSX.Element;
9
+ export {};
@@ -0,0 +1,5 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ export default function AnimatedButton(_a) {
3
+ var onClick = _a.onClick, children = _a.children, _b = _a.hoverColor, hoverColor = _b === void 0 ? "#f53f0c" : _b, _c = _a.baseColor, baseColor = _c === void 0 ? "bg-blue-500" : _c, _d = _a.className, className = _d === void 0 ? "" : _d;
4
+ return (_jsxs("button", { onClick: onClick, className: "flex flex-row items-center justify-center gap-1 w-full ".concat(baseColor, " text-white px-6 py-2 rounded-full\n relative overflow-hidden group ").concat(className).trim(), children: [_jsx("div", { className: "absolute inset-0 transform -translate-x-full group-hover:translate-x-0 transition-transform duration-300 ease-in-out", style: { backgroundColor: hoverColor } }), _jsx("div", { className: "relative w-full z-10", children: children })] }));
5
+ }
@@ -0,0 +1,8 @@
1
+ import React, { ComponentType } from 'react';
2
+ interface LazyLoadWrapperProps {
3
+ component: ComponentType<any>;
4
+ fallback?: React.ReactNode;
5
+ props?: Record<string, any>;
6
+ }
7
+ export declare function LazyLoadWrapper({ component: Component, fallback, props, }: LazyLoadWrapperProps): import("react/jsx-runtime").JSX.Element;
8
+ export {};
@@ -0,0 +1,17 @@
1
+ var __assign = (this && this.__assign) || function () {
2
+ __assign = Object.assign || function(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
6
+ t[p] = s[p];
7
+ }
8
+ return t;
9
+ };
10
+ return __assign.apply(this, arguments);
11
+ };
12
+ import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime";
13
+ import { Suspense } from 'react';
14
+ export function LazyLoadWrapper(_a) {
15
+ var Component = _a.component, _b = _a.fallback, fallback = _b === void 0 ? _jsx(_Fragment, {}) : _b, _c = _a.props, props = _c === void 0 ? {} : _c;
16
+ return (_jsx(Suspense, { fallback: fallback, children: _jsx(Component, __assign({}, props)) }));
17
+ }
@@ -0,0 +1,2 @@
1
+ export declare const PUBLIC_DISCORD_CLIENT_ID = "1197692401939136573";
2
+ export declare const PUBLIC_DISCORD_APP_URI = "jSUqXiay1C2PM3hzSY8KdXnX8aEKiISn";
package/dist/config.js ADDED
@@ -0,0 +1,2 @@
1
+ export var PUBLIC_DISCORD_CLIENT_ID = '1197692401939136573';
2
+ export var PUBLIC_DISCORD_APP_URI = 'jSUqXiay1C2PM3hzSY8KdXnX8aEKiISn';
@@ -0,0 +1,21 @@
1
+ export declare enum WalletErrorCode {
2
+ CONNECTION_FAILED = "CONNECTION_FAILED",
3
+ WALLET_NOT_FOUND = "WALLET_NOT_FOUND",
4
+ USER_REJECTED = "USER_REJECTED",
5
+ NETWORK_ERROR = "NETWORK_ERROR",
6
+ INVALID_CHAIN = "INVALID_CHAIN",
7
+ UNKNOWN = "UNKNOWN",
8
+ TRANSACTION_FAILED = "TRANSACTION_FAILED"
9
+ }
10
+ export declare class WalletError extends Error {
11
+ code: WalletErrorCode;
12
+ details?: Record<string, any> | undefined;
13
+ constructor(code: WalletErrorCode, message: string, details?: Record<string, any> | undefined);
14
+ toDisplayFormat(): {
15
+ title: string;
16
+ message: string;
17
+ code: WalletErrorCode;
18
+ details: string | undefined;
19
+ };
20
+ private getErrorTitle;
21
+ }
@@ -0,0 +1,64 @@
1
+ var __extends = (this && this.__extends) || (function () {
2
+ var extendStatics = function (d, b) {
3
+ extendStatics = Object.setPrototypeOf ||
4
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
+ return extendStatics(d, b);
7
+ };
8
+ return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
11
+ extendStatics(d, b);
12
+ function __() { this.constructor = d; }
13
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
14
+ };
15
+ })();
16
+ export var WalletErrorCode;
17
+ (function (WalletErrorCode) {
18
+ WalletErrorCode["CONNECTION_FAILED"] = "CONNECTION_FAILED";
19
+ WalletErrorCode["WALLET_NOT_FOUND"] = "WALLET_NOT_FOUND";
20
+ WalletErrorCode["USER_REJECTED"] = "USER_REJECTED";
21
+ WalletErrorCode["NETWORK_ERROR"] = "NETWORK_ERROR";
22
+ WalletErrorCode["INVALID_CHAIN"] = "INVALID_CHAIN";
23
+ WalletErrorCode["UNKNOWN"] = "UNKNOWN";
24
+ WalletErrorCode["TRANSACTION_FAILED"] = "TRANSACTION_FAILED";
25
+ })(WalletErrorCode || (WalletErrorCode = {}));
26
+ var WalletError = /** @class */ (function (_super) {
27
+ __extends(WalletError, _super);
28
+ function WalletError(code, message, details) {
29
+ var _this = _super.call(this, message) || this;
30
+ _this.code = code;
31
+ _this.details = details;
32
+ _this.name = 'WalletError';
33
+ return _this;
34
+ }
35
+ // Helper method to convert to a format that can be easily displayed
36
+ WalletError.prototype.toDisplayFormat = function () {
37
+ return {
38
+ title: this.getErrorTitle(),
39
+ message: this.message,
40
+ code: this.code,
41
+ details: this.details ? JSON.stringify(this.details, null, 2) : undefined,
42
+ };
43
+ };
44
+ WalletError.prototype.getErrorTitle = function () {
45
+ switch (this.code) {
46
+ case WalletErrorCode.CONNECTION_FAILED:
47
+ return 'Connection Failed';
48
+ case WalletErrorCode.WALLET_NOT_FOUND:
49
+ return 'Wallet Not Found';
50
+ case WalletErrorCode.USER_REJECTED:
51
+ return 'Action Rejected';
52
+ case WalletErrorCode.NETWORK_ERROR:
53
+ return 'Network Error';
54
+ case WalletErrorCode.INVALID_CHAIN:
55
+ return 'Invalid Chain';
56
+ case WalletErrorCode.TRANSACTION_FAILED:
57
+ return 'Transaction Failed';
58
+ default:
59
+ return 'Wallet Error';
60
+ }
61
+ };
62
+ return WalletError;
63
+ }(Error));
64
+ export { WalletError };
@@ -0,0 +1,5 @@
1
+ import './main.css';
2
+ export { N1WalletProvider } from './Provider/N1WalletProvider';
3
+ export { N1ModalViewMode } from './Provider/types';
4
+ export { N1ConnectButton } from './WidgetButton/N1ConnectButton';
5
+ export { useN1WalletContext } from './Provider/hooks';
package/dist/index.js ADDED
@@ -0,0 +1,5 @@
1
+ import './main.css';
2
+ export { N1WalletProvider } from './Provider/N1WalletProvider';
3
+ export { N1ModalViewMode } from './Provider/types';
4
+ export { N1ConnectButton } from './WidgetButton/N1ConnectButton';
5
+ export { useN1WalletContext } from './Provider/hooks';