@coinlist-co/react 0.12.2-rc.eea3be6 → 0.12.2
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.
- package/README.md +79 -43
- package/dist/{chunk-335G7ZM5.js → chunk-2FZAXGVH.js} +162 -431
- package/dist/chunk-2FZAXGVH.js.map +1 -0
- package/dist/{chunk-WBB6P6ZI.js → chunk-EAPBF7T2.js} +11 -42
- package/dist/chunk-EAPBF7T2.js.map +1 -0
- package/dist/{chunk-MJ6YXZWH.js → chunk-IWQ6A52U.js} +4 -2
- package/dist/chunk-IWQ6A52U.js.map +1 -0
- package/dist/{chunk-IUAGXUJY.js → chunk-OQ2ANYUF.js} +328 -21
- package/dist/chunk-OQ2ANYUF.js.map +1 -0
- package/dist/client/index.d.ts +251 -164
- package/dist/client/index.js +930 -570
- package/dist/client/index.js.map +1 -1
- package/dist/client-credentials-BwcmPcn-.d.ts +13 -0
- package/dist/server/index.d.ts +58 -106
- package/dist/server/index.js +208 -170
- package/dist/server/index.js.map +1 -1
- package/dist/{time-qZW4aYYp.d.ts → time-ChSGmKZe.d.ts} +82 -51
- package/dist/{token-registry-snapshot-CMrhSBun.d.ts → token-registry-snapshot-DMubXr2c.d.ts} +1 -1
- package/dist/universal/index.d.ts +45 -44
- package/dist/universal/index.js +4 -4
- package/package.json +1 -1
- package/dist/chunk-335G7ZM5.js.map +0 -1
- package/dist/chunk-IUAGXUJY.js.map +0 -1
- package/dist/chunk-MJ6YXZWH.js.map +0 -1
- package/dist/chunk-WBB6P6ZI.js.map +0 -1
package/dist/client/index.js
CHANGED
|
@@ -1,15 +1,24 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import {
|
|
3
|
+
API_VERSION,
|
|
3
4
|
AuthenticatedApiClient,
|
|
4
|
-
|
|
5
|
+
COINLIST_BASE_URL,
|
|
6
|
+
HEADER_USER_AGENT,
|
|
7
|
+
OAUTH_PAGE_PATH,
|
|
5
8
|
PINO_LEVEL,
|
|
6
9
|
SDK_LOGGER_NAME,
|
|
10
|
+
SUPPORT_NEW_TICKET_URL,
|
|
11
|
+
VERIFY_IDENTITY_ACCREDITATION_PATH,
|
|
12
|
+
VERIFY_IDENTITY_PATH,
|
|
13
|
+
WALLET_PATH,
|
|
14
|
+
baseUrls,
|
|
15
|
+
createNabuApiClient,
|
|
7
16
|
loggerOverPino,
|
|
8
17
|
notifySessionExpired,
|
|
9
18
|
publicClients,
|
|
10
19
|
systemDelay,
|
|
11
20
|
systemTime
|
|
12
|
-
} from "../chunk-
|
|
21
|
+
} from "../chunk-OQ2ANYUF.js";
|
|
13
22
|
import {
|
|
14
23
|
AuthorizationCode,
|
|
15
24
|
CodeVerifier,
|
|
@@ -20,7 +29,6 @@ import {
|
|
|
20
29
|
ONDO_POLL_INTERVAL_MS,
|
|
21
30
|
ONDO_SETTLEMENT_ASSET,
|
|
22
31
|
ONDO_SUPPORTED_INPUT_ASSETS,
|
|
23
|
-
OffersNamespaceImpl,
|
|
24
32
|
RedactedWalletError,
|
|
25
33
|
SLIPPAGE_OPTIONS_BPS,
|
|
26
34
|
SUPERSTATE_ISSUER_NAME,
|
|
@@ -44,15 +52,13 @@ import {
|
|
|
44
52
|
resolveCentrifugeVaults,
|
|
45
53
|
superstateSwapContractAddress,
|
|
46
54
|
swapSpender
|
|
47
|
-
} from "../chunk-
|
|
55
|
+
} from "../chunk-EAPBF7T2.js";
|
|
48
56
|
import {
|
|
49
|
-
API_VERSION,
|
|
50
57
|
AssetDecimals,
|
|
51
58
|
AssetIconUrl,
|
|
52
59
|
AssetSymbol,
|
|
53
60
|
Attributes,
|
|
54
61
|
BlockchainAmount,
|
|
55
|
-
COINLIST_BASE_URL,
|
|
56
62
|
CentrifugeNamespaceImpl,
|
|
57
63
|
CentrifugeVaultLeg,
|
|
58
64
|
CentrifugeVaultLegId,
|
|
@@ -64,26 +70,20 @@ import {
|
|
|
64
70
|
EvmContractAddress,
|
|
65
71
|
FormattedAmountAssetUi,
|
|
66
72
|
FormattedPercentUi,
|
|
67
|
-
HEADER_USER_AGENT,
|
|
68
73
|
MAX_UINT_256,
|
|
69
74
|
Millis,
|
|
70
75
|
NA_AMOUNT_ASSET_UI,
|
|
71
76
|
NotAuthenticatedError,
|
|
72
|
-
OAUTH_PAGE_PATH,
|
|
73
77
|
OfferOptionAddressId,
|
|
78
|
+
OffersNamespaceImpl,
|
|
74
79
|
OndoNamespaceImpl,
|
|
75
|
-
PUBLIC_API_BASE_URL,
|
|
76
80
|
RequirementsNamespaceImpl,
|
|
77
81
|
STABLE_DECIMALS,
|
|
78
82
|
SUPERSTATE_SWAP_ABI,
|
|
79
|
-
SUPPORT_NEW_TICKET_URL,
|
|
80
83
|
Seconds,
|
|
81
84
|
SentWith,
|
|
82
85
|
SuperstateSwapNamespaceImpl,
|
|
83
86
|
TokensNamespaceImpl,
|
|
84
|
-
VERIFY_IDENTITY_ACCREDITATION_PATH,
|
|
85
|
-
VERIFY_IDENTITY_PATH,
|
|
86
|
-
WALLET_PATH,
|
|
87
87
|
WalletsNamespaceImpl,
|
|
88
88
|
apiErrorCode,
|
|
89
89
|
assetAmount,
|
|
@@ -100,10 +100,11 @@ import {
|
|
|
100
100
|
internalLogger,
|
|
101
101
|
isRejectedToken,
|
|
102
102
|
parseBlockchainAmount,
|
|
103
|
+
parseUint256,
|
|
103
104
|
shortenAddress,
|
|
104
105
|
txExplorerUrl,
|
|
105
106
|
usdAmount
|
|
106
|
-
} from "../chunk-
|
|
107
|
+
} from "../chunk-2FZAXGVH.js";
|
|
107
108
|
|
|
108
109
|
// src/client/CoinListProvider.tsx
|
|
109
110
|
import {
|
|
@@ -163,6 +164,94 @@ var ApiClient = class {
|
|
|
163
164
|
}
|
|
164
165
|
};
|
|
165
166
|
|
|
167
|
+
// src/client/core/auth/auth-namespace.ts
|
|
168
|
+
var OAUTH_STATE_KEY = "coinlist.oauth_state";
|
|
169
|
+
var OAUTH_CODE_VERIFIER_KEY = "coinlist.oauth_code_verifier";
|
|
170
|
+
var ClientAuthNamespaceImpl = class {
|
|
171
|
+
constructor(config, session) {
|
|
172
|
+
this.config = config;
|
|
173
|
+
this.session = session;
|
|
174
|
+
this.log = internalLogger(config.logger ?? null, "AUTH");
|
|
175
|
+
}
|
|
176
|
+
getState() {
|
|
177
|
+
return this.session.getState();
|
|
178
|
+
}
|
|
179
|
+
async startOAuth() {
|
|
180
|
+
return this.log.wrap("startOAuth", void 0, () => this.redirectToOAuth());
|
|
181
|
+
}
|
|
182
|
+
async redirectToOAuth() {
|
|
183
|
+
const pkceParams = await generatePKCEParams(this.config);
|
|
184
|
+
sessionStorage.setItem(OAUTH_STATE_KEY, pkceParams.state);
|
|
185
|
+
sessionStorage.setItem(OAUTH_CODE_VERIFIER_KEY, pkceParams.codeVerifier);
|
|
186
|
+
const params = new URLSearchParams({
|
|
187
|
+
client_id: pkceParams.clientId,
|
|
188
|
+
response_type: pkceParams.responseType,
|
|
189
|
+
redirect_uri: pkceParams.redirectUri,
|
|
190
|
+
code_challenge: pkceParams.codeChallenge,
|
|
191
|
+
code_challenge_method: pkceParams.codeChallengeMethod,
|
|
192
|
+
state: pkceParams.state
|
|
193
|
+
});
|
|
194
|
+
const baseUrl = this.config.coinlistBaseUrl ?? COINLIST_BASE_URL;
|
|
195
|
+
this.log.child({ op: "startOAuth" }).info(() => ({ msg: "redirecting to CoinList", fields: { baseUrl } }));
|
|
196
|
+
window.location.href = `${baseUrl}${OAUTH_PAGE_PATH}?${params.toString()}`;
|
|
197
|
+
}
|
|
198
|
+
/**
|
|
199
|
+
* Every failure here is silent from the browser's side - a state mismatch
|
|
200
|
+
* and a missing verifier both just leave the user logged out - so the
|
|
201
|
+
* reason is logged rather than left for the host to infer from a callback.
|
|
202
|
+
*/
|
|
203
|
+
completeOAuth() {
|
|
204
|
+
const result = this.readOauthCallback();
|
|
205
|
+
switch (result.type) {
|
|
206
|
+
case "error":
|
|
207
|
+
this.log.child({ op: "completeOAuth" }).error(() => ({
|
|
208
|
+
msg: "oauth callback rejected",
|
|
209
|
+
fields: { reason: result.reason }
|
|
210
|
+
}));
|
|
211
|
+
return result;
|
|
212
|
+
case "ok":
|
|
213
|
+
this.log.child({ op: "completeOAuth" }).info(() => ({ msg: "authorization code received" }));
|
|
214
|
+
return result;
|
|
215
|
+
default: {
|
|
216
|
+
const _exhaustive = result;
|
|
217
|
+
return result;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
logout() {
|
|
222
|
+
this.log.child({ op: "logout" }).info(() => ({ msg: "access token cleared" }));
|
|
223
|
+
this.session.clearAccessToken();
|
|
224
|
+
}
|
|
225
|
+
readOauthCallback() {
|
|
226
|
+
const params = new URLSearchParams(window.location.search);
|
|
227
|
+
const coinlistError = params.get("error");
|
|
228
|
+
if (coinlistError) {
|
|
229
|
+
return { type: "error", reason: "user_canceled" };
|
|
230
|
+
}
|
|
231
|
+
const stateParam = params.get("state");
|
|
232
|
+
if (!stateParam) {
|
|
233
|
+
return { type: "error", reason: "missing_state" };
|
|
234
|
+
}
|
|
235
|
+
const storedState = sessionStorage.getItem(OAUTH_STATE_KEY);
|
|
236
|
+
if (storedState === null || storedState !== stateParam) {
|
|
237
|
+
return { type: "error", reason: "invalid_state" };
|
|
238
|
+
}
|
|
239
|
+
const codeParam = params.get("code");
|
|
240
|
+
if (!codeParam) {
|
|
241
|
+
return { type: "error", reason: "missing_code" };
|
|
242
|
+
}
|
|
243
|
+
const codeVerifierValue = sessionStorage.getItem(OAUTH_CODE_VERIFIER_KEY);
|
|
244
|
+
if (!codeVerifierValue) {
|
|
245
|
+
return { type: "error", reason: "missing_code_verifier" };
|
|
246
|
+
}
|
|
247
|
+
return {
|
|
248
|
+
type: "ok",
|
|
249
|
+
code: AuthorizationCode(codeParam),
|
|
250
|
+
codeVerifier: CodeVerifier(codeVerifierValue)
|
|
251
|
+
};
|
|
252
|
+
}
|
|
253
|
+
};
|
|
254
|
+
|
|
166
255
|
// src/client/core/auth/client-access-token.ts
|
|
167
256
|
var CONFIRM_DELAY = Millis.of(1e3);
|
|
168
257
|
var Generation = {
|
|
@@ -316,94 +405,6 @@ function isFresh(token, rejected) {
|
|
|
316
405
|
return token !== null && !isRejectedToken(token, rejected);
|
|
317
406
|
}
|
|
318
407
|
|
|
319
|
-
// src/client/core/auth/client-auth-namespace.ts
|
|
320
|
-
var OAUTH_STATE_KEY = "coinlist.oauth_state";
|
|
321
|
-
var OAUTH_CODE_VERIFIER_KEY = "coinlist.oauth_code_verifier";
|
|
322
|
-
var ClientAuthNamespaceImpl = class {
|
|
323
|
-
constructor(config, session) {
|
|
324
|
-
this.config = config;
|
|
325
|
-
this.session = session;
|
|
326
|
-
this.log = internalLogger(config.logger ?? null, "AUTH");
|
|
327
|
-
}
|
|
328
|
-
getState() {
|
|
329
|
-
return this.session.getState();
|
|
330
|
-
}
|
|
331
|
-
async startOAuth() {
|
|
332
|
-
return this.log.wrap("startOAuth", void 0, () => this.redirectToOAuth());
|
|
333
|
-
}
|
|
334
|
-
async redirectToOAuth() {
|
|
335
|
-
const pkceParams = await generatePKCEParams(this.config);
|
|
336
|
-
sessionStorage.setItem(OAUTH_STATE_KEY, pkceParams.state);
|
|
337
|
-
sessionStorage.setItem(OAUTH_CODE_VERIFIER_KEY, pkceParams.codeVerifier);
|
|
338
|
-
const params = new URLSearchParams({
|
|
339
|
-
client_id: pkceParams.clientId,
|
|
340
|
-
response_type: pkceParams.responseType,
|
|
341
|
-
redirect_uri: pkceParams.redirectUri,
|
|
342
|
-
code_challenge: pkceParams.codeChallenge,
|
|
343
|
-
code_challenge_method: pkceParams.codeChallengeMethod,
|
|
344
|
-
state: pkceParams.state
|
|
345
|
-
});
|
|
346
|
-
const baseUrl = this.config.coinlistBaseUrl ?? COINLIST_BASE_URL;
|
|
347
|
-
this.log.child({ op: "startOAuth" }).info(() => ({ msg: "redirecting to CoinList", fields: { baseUrl } }));
|
|
348
|
-
window.location.href = `${baseUrl}${OAUTH_PAGE_PATH}?${params.toString()}`;
|
|
349
|
-
}
|
|
350
|
-
/**
|
|
351
|
-
* Every failure here is silent from the browser's side - a state mismatch
|
|
352
|
-
* and a missing verifier both just leave the user logged out - so the
|
|
353
|
-
* reason is logged rather than left for the host to infer from a callback.
|
|
354
|
-
*/
|
|
355
|
-
completeOAuth() {
|
|
356
|
-
const result = this.readOauthCallback();
|
|
357
|
-
switch (result.type) {
|
|
358
|
-
case "error":
|
|
359
|
-
this.log.child({ op: "completeOAuth" }).error(() => ({
|
|
360
|
-
msg: "oauth callback rejected",
|
|
361
|
-
fields: { reason: result.reason }
|
|
362
|
-
}));
|
|
363
|
-
return result;
|
|
364
|
-
case "ok":
|
|
365
|
-
this.log.child({ op: "completeOAuth" }).info(() => ({ msg: "authorization code received" }));
|
|
366
|
-
return result;
|
|
367
|
-
default: {
|
|
368
|
-
const _exhaustive = result;
|
|
369
|
-
return result;
|
|
370
|
-
}
|
|
371
|
-
}
|
|
372
|
-
}
|
|
373
|
-
logout() {
|
|
374
|
-
this.log.child({ op: "logout" }).info(() => ({ msg: "access token cleared" }));
|
|
375
|
-
this.session.clearAccessToken();
|
|
376
|
-
}
|
|
377
|
-
readOauthCallback() {
|
|
378
|
-
const params = new URLSearchParams(window.location.search);
|
|
379
|
-
const coinlistError = params.get("error");
|
|
380
|
-
if (coinlistError) {
|
|
381
|
-
return { type: "error", reason: "user_canceled" };
|
|
382
|
-
}
|
|
383
|
-
const stateParam = params.get("state");
|
|
384
|
-
if (!stateParam) {
|
|
385
|
-
return { type: "error", reason: "missing_state" };
|
|
386
|
-
}
|
|
387
|
-
const storedState = sessionStorage.getItem(OAUTH_STATE_KEY);
|
|
388
|
-
if (storedState === null || storedState !== stateParam) {
|
|
389
|
-
return { type: "error", reason: "invalid_state" };
|
|
390
|
-
}
|
|
391
|
-
const codeParam = params.get("code");
|
|
392
|
-
if (!codeParam) {
|
|
393
|
-
return { type: "error", reason: "missing_code" };
|
|
394
|
-
}
|
|
395
|
-
const codeVerifierValue = sessionStorage.getItem(OAUTH_CODE_VERIFIER_KEY);
|
|
396
|
-
if (!codeVerifierValue) {
|
|
397
|
-
return { type: "error", reason: "missing_code_verifier" };
|
|
398
|
-
}
|
|
399
|
-
return {
|
|
400
|
-
type: "ok",
|
|
401
|
-
code: AuthorizationCode(codeParam),
|
|
402
|
-
codeVerifier: CodeVerifier(codeVerifierValue)
|
|
403
|
-
};
|
|
404
|
-
}
|
|
405
|
-
};
|
|
406
|
-
|
|
407
408
|
// src/client/core/shared/blockchain/wallet-error.ts
|
|
408
409
|
import {
|
|
409
410
|
BaseError,
|
|
@@ -583,7 +584,7 @@ async function submitErc20Approval({
|
|
|
583
584
|
}
|
|
584
585
|
}
|
|
585
586
|
|
|
586
|
-
// src/client/core/providers/
|
|
587
|
+
// src/client/core/providers/shared/approve-then-build.ts
|
|
587
588
|
async function approveThenBuild({
|
|
588
589
|
erc20,
|
|
589
590
|
wallet,
|
|
@@ -620,7 +621,7 @@ async function approveThenBuild({
|
|
|
620
621
|
}
|
|
621
622
|
var INSUFFICIENT_ALLOWANCE_CODE = "insufficient_allowance";
|
|
622
623
|
|
|
623
|
-
// src/client/core/providers/
|
|
624
|
+
// src/client/core/providers/shared/broadcast-built.ts
|
|
624
625
|
async function broadcastBuilt({
|
|
625
626
|
wallet,
|
|
626
627
|
chain,
|
|
@@ -642,12 +643,12 @@ async function broadcastBuilt({
|
|
|
642
643
|
});
|
|
643
644
|
}
|
|
644
645
|
|
|
645
|
-
// src/universal/core/providers/
|
|
646
|
+
// src/universal/core/providers/centrifuge/vault-contracts.ts
|
|
646
647
|
function vaultProxy(vaultContracts, chain) {
|
|
647
648
|
return contractOn(vaultContracts, chain);
|
|
648
649
|
}
|
|
649
650
|
|
|
650
|
-
// src/client/core/providers/
|
|
651
|
+
// src/client/core/providers/centrifuge/checkout-flows.ts
|
|
651
652
|
async function prepareCentrifugeBuy(params) {
|
|
652
653
|
const {
|
|
653
654
|
centrifuge,
|
|
@@ -724,7 +725,7 @@ async function buyCentrifuge(params) {
|
|
|
724
725
|
});
|
|
725
726
|
}
|
|
726
727
|
|
|
727
|
-
// src/client/core/providers/
|
|
728
|
+
// src/client/core/providers/centrifuge/claim-flows.ts
|
|
728
729
|
async function claimCentrifugeVault(params) {
|
|
729
730
|
const { wallet, chain, direction, onProgress } = params;
|
|
730
731
|
const emit = (phase) => onProgress?.(phase);
|
|
@@ -878,11 +879,11 @@ function isWalletError(value) {
|
|
|
878
879
|
return typeof type === "string" && WALLET_ERROR_TYPES.has(type);
|
|
879
880
|
}
|
|
880
881
|
|
|
881
|
-
// src/client/core/providers/
|
|
882
|
+
// src/client/core/providers/centrifuge/client-centrifuge-namespace.ts
|
|
882
883
|
var ClientCentrifugeNamespaceImpl = class extends CentrifugeNamespaceImpl {
|
|
883
|
-
constructor(ctx,
|
|
884
|
+
constructor(ctx, deps) {
|
|
884
885
|
super(ctx);
|
|
885
|
-
this.
|
|
886
|
+
this.deps = deps;
|
|
886
887
|
}
|
|
887
888
|
buy(params) {
|
|
888
889
|
return withFlowLogging(
|
|
@@ -895,7 +896,7 @@ var ClientCentrifugeNamespaceImpl = class extends CentrifugeNamespaceImpl {
|
|
|
895
896
|
...systemTime,
|
|
896
897
|
onProgress,
|
|
897
898
|
centrifuge: this,
|
|
898
|
-
erc20: this.erc20
|
|
899
|
+
erc20: this.deps.erc20
|
|
899
900
|
})
|
|
900
901
|
);
|
|
901
902
|
}
|
|
@@ -909,7 +910,7 @@ var ClientCentrifugeNamespaceImpl = class extends CentrifugeNamespaceImpl {
|
|
|
909
910
|
...params,
|
|
910
911
|
onProgress,
|
|
911
912
|
centrifuge: this,
|
|
912
|
-
erc20: this.erc20
|
|
913
|
+
erc20: this.deps.erc20
|
|
913
914
|
})
|
|
914
915
|
);
|
|
915
916
|
}
|
|
@@ -933,7 +934,7 @@ var ClientCentrifugeNamespaceImpl = class extends CentrifugeNamespaceImpl {
|
|
|
933
934
|
}
|
|
934
935
|
};
|
|
935
936
|
|
|
936
|
-
// src/universal/core/providers/
|
|
937
|
+
// src/universal/core/providers/coin-list/token-sale-offer.ts
|
|
937
938
|
function tokenSaleTerms({
|
|
938
939
|
offer,
|
|
939
940
|
chain,
|
|
@@ -983,7 +984,7 @@ function tokenSaleQuantity(amount, price) {
|
|
|
983
984
|
return BlockchainAmount.div(amount, price);
|
|
984
985
|
}
|
|
985
986
|
|
|
986
|
-
// src/client/core/providers/
|
|
987
|
+
// src/client/core/providers/coin-list/checkout-flows.ts
|
|
987
988
|
async function executeTokenSale(params) {
|
|
988
989
|
const {
|
|
989
990
|
erc20,
|
|
@@ -1097,11 +1098,11 @@ function approvalError(failure) {
|
|
|
1097
1098
|
}
|
|
1098
1099
|
}
|
|
1099
1100
|
|
|
1100
|
-
// src/client/core/providers/
|
|
1101
|
+
// src/client/core/providers/coin-list/client-token-sale-namespace.ts
|
|
1101
1102
|
var ClientCoinListTokenSaleNamespaceImpl = class extends CoinListTokenSaleNamespaceImpl {
|
|
1102
|
-
constructor(ctx,
|
|
1103
|
+
constructor(ctx, deps) {
|
|
1103
1104
|
super(ctx);
|
|
1104
|
-
this.
|
|
1105
|
+
this.deps = deps;
|
|
1105
1106
|
}
|
|
1106
1107
|
execute(params) {
|
|
1107
1108
|
return withFlowLogging(
|
|
@@ -1112,14 +1113,14 @@ var ClientCoinListTokenSaleNamespaceImpl = class extends CoinListTokenSaleNamesp
|
|
|
1112
1113
|
(onProgress) => executeTokenSale({
|
|
1113
1114
|
...params,
|
|
1114
1115
|
onProgress,
|
|
1115
|
-
erc20: this.erc20,
|
|
1116
|
+
erc20: this.deps.erc20,
|
|
1116
1117
|
tokenSale: this
|
|
1117
1118
|
})
|
|
1118
1119
|
);
|
|
1119
1120
|
}
|
|
1120
1121
|
};
|
|
1121
1122
|
|
|
1122
|
-
// src/client/core/providers/
|
|
1123
|
+
// src/client/core/providers/ondo/checkout-flows.ts
|
|
1123
1124
|
async function prepareOndoBuy(params) {
|
|
1124
1125
|
const { ondo, symbol, chain, wallet, amount } = params;
|
|
1125
1126
|
return prepare(
|
|
@@ -1205,11 +1206,11 @@ async function executeOndoSwap(params) {
|
|
|
1205
1206
|
}
|
|
1206
1207
|
}
|
|
1207
1208
|
|
|
1208
|
-
// src/client/core/providers/
|
|
1209
|
+
// src/client/core/providers/ondo/client-ondo-namespace.ts
|
|
1209
1210
|
var ClientOndoNamespaceImpl = class extends OndoNamespaceImpl {
|
|
1210
|
-
constructor(ctx,
|
|
1211
|
+
constructor(ctx, deps) {
|
|
1211
1212
|
super(ctx);
|
|
1212
|
-
this.
|
|
1213
|
+
this.deps = deps;
|
|
1213
1214
|
}
|
|
1214
1215
|
prepareBuy(params) {
|
|
1215
1216
|
return withFlowLogging(
|
|
@@ -1221,7 +1222,7 @@ var ClientOndoNamespaceImpl = class extends OndoNamespaceImpl {
|
|
|
1221
1222
|
...params,
|
|
1222
1223
|
onProgress,
|
|
1223
1224
|
ondo: this,
|
|
1224
|
-
erc20: this.erc20
|
|
1225
|
+
erc20: this.deps.erc20
|
|
1225
1226
|
})
|
|
1226
1227
|
);
|
|
1227
1228
|
}
|
|
@@ -1235,7 +1236,7 @@ var ClientOndoNamespaceImpl = class extends OndoNamespaceImpl {
|
|
|
1235
1236
|
...params,
|
|
1236
1237
|
onProgress,
|
|
1237
1238
|
ondo: this,
|
|
1238
|
-
erc20: this.erc20
|
|
1239
|
+
erc20: this.deps.erc20
|
|
1239
1240
|
})
|
|
1240
1241
|
);
|
|
1241
1242
|
}
|
|
@@ -1250,7 +1251,7 @@ var ClientOndoNamespaceImpl = class extends OndoNamespaceImpl {
|
|
|
1250
1251
|
}
|
|
1251
1252
|
};
|
|
1252
1253
|
|
|
1253
|
-
// src/universal/core/providers/
|
|
1254
|
+
// src/universal/core/providers/superstate/blockchain/swapped-event.ts
|
|
1254
1255
|
import { parseEventLogs } from "viem";
|
|
1255
1256
|
function decodeSwappedOutputAmount(receipt, outputDecimals) {
|
|
1256
1257
|
try {
|
|
@@ -1268,7 +1269,7 @@ function decodeSwappedOutputAmount(receipt, outputDecimals) {
|
|
|
1268
1269
|
}
|
|
1269
1270
|
}
|
|
1270
1271
|
|
|
1271
|
-
// src/client/core/providers/
|
|
1272
|
+
// src/client/core/providers/superstate/checkout-flows.ts
|
|
1272
1273
|
async function executeSwap(params) {
|
|
1273
1274
|
const {
|
|
1274
1275
|
swap,
|
|
@@ -1467,12 +1468,11 @@ async function authorizeWallet(params) {
|
|
|
1467
1468
|
return { type: "success" };
|
|
1468
1469
|
}
|
|
1469
1470
|
|
|
1470
|
-
// src/client/core/providers/
|
|
1471
|
+
// src/client/core/providers/superstate/client-superstate-namespace.ts
|
|
1471
1472
|
var ClientSuperstateSwapNamespaceImpl = class extends SuperstateSwapNamespaceImpl {
|
|
1472
|
-
constructor(ctx,
|
|
1473
|
+
constructor(ctx, deps) {
|
|
1473
1474
|
super(ctx);
|
|
1474
|
-
this.
|
|
1475
|
-
this.wallets = wallets;
|
|
1475
|
+
this.deps = deps;
|
|
1476
1476
|
}
|
|
1477
1477
|
execute(params) {
|
|
1478
1478
|
return withFlowLogging(
|
|
@@ -1480,7 +1480,12 @@ var ClientSuperstateSwapNamespaceImpl = class extends SuperstateSwapNamespaceImp
|
|
|
1480
1480
|
"execute",
|
|
1481
1481
|
void 0,
|
|
1482
1482
|
params.onProgress,
|
|
1483
|
-
(onProgress) => executeSwap({
|
|
1483
|
+
(onProgress) => executeSwap({
|
|
1484
|
+
...params,
|
|
1485
|
+
onProgress,
|
|
1486
|
+
swap: this,
|
|
1487
|
+
erc20: this.deps.erc20
|
|
1488
|
+
})
|
|
1484
1489
|
);
|
|
1485
1490
|
}
|
|
1486
1491
|
authorizeWallet(params) {
|
|
@@ -1493,7 +1498,7 @@ var ClientSuperstateSwapNamespaceImpl = class extends SuperstateSwapNamespaceImp
|
|
|
1493
1498
|
...params,
|
|
1494
1499
|
onProgress,
|
|
1495
1500
|
swap: this,
|
|
1496
|
-
wallets: this.wallets
|
|
1501
|
+
wallets: this.deps.wallets
|
|
1497
1502
|
})
|
|
1498
1503
|
);
|
|
1499
1504
|
}
|
|
@@ -1506,14 +1511,14 @@ function openInNewTab(url) {
|
|
|
1506
1511
|
|
|
1507
1512
|
// src/client/core/requirements/client-requirements-namespace.ts
|
|
1508
1513
|
var ClientRequirementsNamespaceImpl = class extends RequirementsNamespaceImpl {
|
|
1509
|
-
constructor(ctx,
|
|
1514
|
+
constructor(ctx, deps) {
|
|
1510
1515
|
super(ctx);
|
|
1511
|
-
this.
|
|
1516
|
+
this.deps = deps;
|
|
1512
1517
|
}
|
|
1513
1518
|
handle(requirement) {
|
|
1514
1519
|
const path = requirementPath(requirement);
|
|
1515
1520
|
if (path === null) return;
|
|
1516
|
-
const baseUrl = this.coinlistBaseUrl ?? COINLIST_BASE_URL;
|
|
1521
|
+
const baseUrl = this.deps.coinlistBaseUrl ?? COINLIST_BASE_URL;
|
|
1517
1522
|
openInNewTab(new URL(path, baseUrl).toString());
|
|
1518
1523
|
}
|
|
1519
1524
|
};
|
|
@@ -1543,10 +1548,10 @@ function requirementPath(requirement) {
|
|
|
1543
1548
|
}
|
|
1544
1549
|
}
|
|
1545
1550
|
|
|
1546
|
-
// src/client/core/support/
|
|
1551
|
+
// src/client/core/support/support-namespace.ts
|
|
1547
1552
|
var ClientSupportNamespaceImpl = class {
|
|
1548
|
-
constructor(
|
|
1549
|
-
this.log = internalLogger(logger, "SUPPORT");
|
|
1553
|
+
constructor(ctx) {
|
|
1554
|
+
this.log = internalLogger(ctx.logger, "SUPPORT");
|
|
1550
1555
|
}
|
|
1551
1556
|
contact() {
|
|
1552
1557
|
this.log.child({ op: "contact" }).info(() => ({
|
|
@@ -1684,9 +1689,10 @@ var CoinListClientImpl = class {
|
|
|
1684
1689
|
...systemDelay
|
|
1685
1690
|
});
|
|
1686
1691
|
this.accessToken = accessToken;
|
|
1692
|
+
const urls = baseUrls(config);
|
|
1687
1693
|
this.api = new ApiClient(
|
|
1688
1694
|
{
|
|
1689
|
-
baseUrl:
|
|
1695
|
+
baseUrl: urls.api,
|
|
1690
1696
|
xApiVersion: API_VERSION
|
|
1691
1697
|
},
|
|
1692
1698
|
(trigger) => accessToken.get(trigger),
|
|
@@ -1703,25 +1709,25 @@ var CoinListClientImpl = class {
|
|
|
1703
1709
|
clearAccessToken: () => accessToken.clear()
|
|
1704
1710
|
});
|
|
1705
1711
|
this.offers = new OffersNamespaceImpl(ctx);
|
|
1706
|
-
this.requirements = new ClientRequirementsNamespaceImpl(
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
);
|
|
1710
|
-
|
|
1711
|
-
this.
|
|
1712
|
-
this.
|
|
1713
|
-
this.
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
);
|
|
1718
|
-
this.ondo = new ClientOndoNamespaceImpl(ctx,
|
|
1719
|
-
this.centrifuge = new ClientCentrifugeNamespaceImpl(ctx,
|
|
1720
|
-
this.tokens = new TokensNamespaceImpl(
|
|
1721
|
-
|
|
1712
|
+
this.requirements = new ClientRequirementsNamespaceImpl(ctx, {
|
|
1713
|
+
coinlistBaseUrl: config.coinlistBaseUrl
|
|
1714
|
+
});
|
|
1715
|
+
const wallets = new ClientWalletsNamespaceImpl(ctx);
|
|
1716
|
+
const erc20 = new Erc20NamespaceImpl(ctx);
|
|
1717
|
+
this.wallets = wallets;
|
|
1718
|
+
this.erc20 = erc20;
|
|
1719
|
+
this.tokenSale = new ClientCoinListTokenSaleNamespaceImpl(ctx, { erc20 });
|
|
1720
|
+
this.superstate = new ClientSuperstateSwapNamespaceImpl(ctx, {
|
|
1721
|
+
erc20,
|
|
1722
|
+
wallets
|
|
1723
|
+
});
|
|
1724
|
+
this.ondo = new ClientOndoNamespaceImpl(ctx, { erc20 });
|
|
1725
|
+
this.centrifuge = new ClientCentrifugeNamespaceImpl(ctx, { erc20 });
|
|
1726
|
+
this.tokens = new TokensNamespaceImpl({
|
|
1727
|
+
nabu: createNabuApiClient(urls.tokens, logger),
|
|
1722
1728
|
logger
|
|
1723
|
-
);
|
|
1724
|
-
this.support = new ClientSupportNamespaceImpl(logger);
|
|
1729
|
+
});
|
|
1730
|
+
this.support = new ClientSupportNamespaceImpl({ logger });
|
|
1725
1731
|
}
|
|
1726
1732
|
async init() {
|
|
1727
1733
|
return this.accessToken.load();
|
|
@@ -1793,7 +1799,7 @@ function CoinListProvider({
|
|
|
1793
1799
|
import { createContext as createContext4, useContext as useContext3 } from "react";
|
|
1794
1800
|
|
|
1795
1801
|
// src/client/generated/sdk-styles.gen.ts
|
|
1796
|
-
var sdkStyles = '/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-space-y-reverse:0;--tw-divide-y-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-duration:initial;--tw-ease:initial;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1}}}@layer theme{:root,:host{--clcosdk-font-mono:ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--clcosdk-color-red-400:oklch(70.4% .191 22.216);--clcosdk-color-red-500:oklch(63.7% .237 25.331);--clcosdk-color-amber-500:oklch(76.9% .188 70.08);--clcosdk-color-gray-400:oklch(70.7% .022 261.325);--clcosdk-color-gray-500:oklch(55.1% .027 264.364);--clcosdk-color-black:#000;--clcosdk-spacing:.25rem;--clcosdk-container-sm:24rem;--clcosdk-container-md:28rem;--clcosdk-container-xl:36rem;--clcosdk-text-xs:.75rem;--clcosdk-text-xs--line-height:calc(1 / .75);--clcosdk-text-sm:.875rem;--clcosdk-text-sm--line-height:calc(1.25 / .875);--clcosdk-text-base:1rem;--clcosdk-text-base--line-height:calc(1.5 / 1);--clcosdk-text-lg:1.125rem;--clcosdk-text-lg--line-height:calc(1.75 / 1.125);--clcosdk-font-weight-normal:400;--clcosdk-font-weight-medium:500;--clcosdk-font-weight-semibold:600;--clcosdk-radius-md:.375rem;--clcosdk-radius-lg:.5rem;--clcosdk-radius-xl:.75rem;--clcosdk-radius-2xl:1rem;--clcosdk-ease-out:cubic-bezier(0, 0, .2, 1);--clcosdk-ease-in-out:cubic-bezier(.4, 0, .2, 1);--clcosdk-animate-spin:spin 1s linear infinite;--clcosdk-animate-pulse:pulse 2s cubic-bezier(.4, 0, .6, 1) infinite;--clcosdk-color-brand-primary:var(--color-brand-primary)}}@layer base{.clco-sdk-root{--color-brand-primary:#171717;--color-brand-primary-hover:#000;--color-brand-primary-active:#262626;--color-accent:#2b3a67;--color-accent-hover:#243057;--color-accent-active:#1d2647;--color-accent-focus:#c7d2fe;--color-accent-subtle:#eef1f8;--color-text-primary:#171717;--color-text-secondary:#8c8c8c;--color-text-disabled:#d1d1d1;--color-text-inverse:#fff;--color-background:#fff;--color-surface:#fafafa;--color-section:#f3f3f3;--color-border:#e5e5e5;--color-divider:#ececec;--color-overlay:#00000080;--color-positive:#15803d;--color-positive-subtle:#dcfce7;--color-negative:#dc2626;--color-negative-subtle:#fee2e2;--color-success:#2c8c5e;--color-success-subtle:#e6f4ec;--color-success-border:#cfe9db;--color-warning:#e08a1a;--color-warning-subtle:#fff7ed;--color-warning-border:#fdead7;--color-error:#b42318;--color-error-subtle:#feeceb;--color-error-border:#fbd5d2;--shadow-step-active:0px 0px 10px 0px #0000001a;--shadow-dialog:0px 8px 32px 0px #0000001a;--btn-primary-gradient:linear-gradient(180deg, #262626 0%, #1c1c1c 50%, #0f0f0f 100%);--btn-primary-shadow:inset 0px -1px 3px 0px #00000059, inset 0px 1px 2px 0px #ffffff2e, inset 0px 1px 0px 0px #ffffff1a;--sale-card-surface:linear-gradient(to top, #0a0a0a 0%, #1a1a1a 100%);--color-sale-card-text:#f4f4f5;--color-sale-card-text-muted:#a1a1aa;--color-sale-card-text-strong:#fff;--color-sale-card-border:#ffffff40;--color-sale-card-chrome-border:#ffffff4d;--color-sale-card-chrome-bg:#ffffff26;--color-sale-card-chrome-emphasis-border:#fff6;--color-sale-card-chrome-emphasis-bg:#ffffff40;--color-sale-card-focus-ring:#ffffff80;--display-on-light:block;--display-on-dark:none}@media (prefers-color-scheme:dark){.clco-sdk-root:not(:where(.light,.light *)){--color-brand-primary:#f4f4f5;--color-brand-primary-hover:#fff;--color-brand-primary-active:#e4e4e7;--color-accent:#6f82c9;--color-accent-hover:#8799e4;--color-accent-active:#5b6fcf;--color-accent-focus:#6f82c959;--color-accent-subtle:#6f82c91f;--color-text-primary:#f4f4f5;--color-text-secondary:#a1a1aa;--color-text-disabled:#71717a;--color-text-inverse:#171717;--color-background:#0f1115;--color-surface:#161a20;--color-section:#20242c;--color-border:#2a2e35;--color-divider:#323741;--color-overlay:#000000b3;--color-positive:#22c55e;--color-positive-subtle:#22c55e1f;--color-negative:#ef4444;--color-negative-subtle:#ef44441f;--color-success:#34d399;--color-success-subtle:#34d3991f;--color-success-border:#34d39940;--color-warning:#f59e0b;--color-warning-subtle:#f59e0b1f;--color-warning-border:#f59e0b40;--color-error:#f87171;--color-error-subtle:#f871711f;--color-error-border:#f8717140;--shadow-step-active:0px 0px 10px 0px #00000080;--shadow-dialog:0px 8px 32px 0px #0009;--btn-primary-gradient:linear-gradient(180deg, #fafafa 0%, #f0f0f0 50%, #e4e4e7 100%);--btn-primary-shadow:inset 0px -1px 3px 0px #0000001f, inset 0px 1px 2px 0px #fff9, inset 0px 1px 0px 0px #fff6;--display-on-light:none;--display-on-dark:block}}:where(.dark,.dark *) .clco-sdk-root{--color-brand-primary:#f4f4f5;--color-brand-primary-hover:#fff;--color-brand-primary-active:#e4e4e7;--color-accent:#6f82c9;--color-accent-hover:#8799e4;--color-accent-active:#5b6fcf;--color-accent-focus:#6f82c959;--color-accent-subtle:#6f82c91f;--color-text-primary:#f4f4f5;--color-text-secondary:#a1a1aa;--color-text-disabled:#71717a;--color-text-inverse:#171717;--color-background:#0f1115;--color-surface:#161a20;--color-section:#20242c;--color-border:#2a2e35;--color-divider:#323741;--color-overlay:#000000b3;--color-positive:#22c55e;--color-positive-subtle:#22c55e1f;--color-negative:#ef4444;--color-negative-subtle:#ef44441f;--color-success:#34d399;--color-success-subtle:#34d3991f;--color-success-border:#34d39940;--color-warning:#f59e0b;--color-warning-subtle:#f59e0b1f;--color-warning-border:#f59e0b40;--color-error:#f87171;--color-error-subtle:#f871711f;--color-error-border:#f8717140;--shadow-step-active:0px 0px 10px 0px #00000080;--shadow-dialog:0px 8px 32px 0px #0009;--btn-primary-gradient:linear-gradient(180deg, #fafafa 0%, #f0f0f0 50%, #e4e4e7 100%);--btn-primary-shadow:inset 0px -1px 3px 0px #0000001f, inset 0px 1px 2px 0px #fff9, inset 0px 1px 0px 0px #fff6;--display-on-light:none;--display-on-dark:block}.clco-sdk-root{color:var(--color-text-primary);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:Inter,sans-serif}.clco-sdk-root *,.clco-sdk-root :before,.clco-sdk-root :after{box-sizing:border-box}.clco-sdk-root button{appearance:none;cursor:pointer;font:inherit;color:inherit;background:0 0;border:none;padding:0}.clco-sdk-root input,.clco-sdk-root textarea,.clco-sdk-root select{font:inherit;color:inherit;background:0 0;border:none;border-radius:0;padding:0}.clco-sdk-root a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}.clco-sdk-root ul,.clco-sdk-root ol{margin:0;padding:0;list-style:none}.clco-sdk-root h1,.clco-sdk-root h2,.clco-sdk-root h3,.clco-sdk-root h4,.clco-sdk-root h5,.clco-sdk-root h6,.clco-sdk-root p,.clco-sdk-root figure,.clco-sdk-root blockquote,.clco-sdk-root dl,.clco-sdk-root dd,.clco-sdk-root pre{margin:0}.clco-sdk-root img,.clco-sdk-root svg{max-width:100%;display:block}@keyframes clco-status-ping{0%{opacity:.7;transform:scale(1)}75%,to{opacity:0;transform:scale(3.25)}}.clco-sdk-root .clcosdk-status-dot-ping{animation:1.6s cubic-bezier(0,0,.2,1) infinite clco-status-ping}.clco-sdk-root .clcosdk-on-light{display:var(--display-on-light)}.clco-sdk-root .clcosdk-on-dark{display:var(--display-on-dark)}@media (prefers-reduced-motion:reduce){.clco-sdk-root .clcosdk-status-dot-ping{opacity:0;animation:none}}}@layer components;@layer utilities{.clcosdk\\:pointer-events-none{pointer-events:none}.clcosdk\\:invisible{visibility:hidden}.clcosdk\\:sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.clcosdk\\:absolute{position:absolute}.clcosdk\\:fixed{position:fixed}.clcosdk\\:relative{position:relative}.clcosdk\\:inset-0{inset:0}.clcosdk\\:top-1\\/2{top:50%}.clcosdk\\:top-4{top:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:top-full{top:100%}.clcosdk\\:-right-0\\.5{right:calc(var(--clcosdk-spacing) * -.5)}.clcosdk\\:right-4{right:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:right-\\[-14\\%\\]{right:-14%}.clcosdk\\:-bottom-0\\.5{bottom:calc(var(--clcosdk-spacing) * -.5)}.clcosdk\\:bottom-full{bottom:100%}.clcosdk\\:left-1\\/2{left:50%}.clcosdk\\:z-0{z-index:0}.clcosdk\\:z-10{z-index:10}.clcosdk\\:z-50{z-index:50}.clcosdk\\:order-1{order:1}.clcosdk\\:order-2{order:2}.clcosdk\\:-mx-2{margin-inline:calc(var(--clcosdk-spacing) * -2)}.clcosdk\\:mt-2{margin-top:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:mt-4{margin-top:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:mt-auto{margin-top:auto}.clcosdk\\:mb-2{margin-bottom:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:flex{display:flex}.clcosdk\\:grid{display:grid}.clcosdk\\:inline-flex{display:inline-flex}.clcosdk\\:size-2{width:calc(var(--clcosdk-spacing) * 2);height:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:size-3{width:calc(var(--clcosdk-spacing) * 3);height:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:size-3\\.5{width:calc(var(--clcosdk-spacing) * 3.5);height:calc(var(--clcosdk-spacing) * 3.5)}.clcosdk\\:size-4{width:calc(var(--clcosdk-spacing) * 4);height:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:size-5{width:calc(var(--clcosdk-spacing) * 5);height:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:size-6{width:calc(var(--clcosdk-spacing) * 6);height:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:size-10{width:calc(var(--clcosdk-spacing) * 10);height:calc(var(--clcosdk-spacing) * 10)}.clcosdk\\:size-12{width:calc(var(--clcosdk-spacing) * 12);height:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:size-16{width:calc(var(--clcosdk-spacing) * 16);height:calc(var(--clcosdk-spacing) * 16)}.clcosdk\\:size-24{width:calc(var(--clcosdk-spacing) * 24);height:calc(var(--clcosdk-spacing) * 24)}.clcosdk\\:size-\\[15rem\\]{width:15rem;height:15rem}.clcosdk\\:size-full{width:100%;height:100%}.clcosdk\\:h-1{height:var(--clcosdk-spacing)}.clcosdk\\:h-3{height:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:h-4{height:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:h-5{height:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:h-6{height:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:h-8{height:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:h-9{height:calc(var(--clcosdk-spacing) * 9)}.clcosdk\\:h-10{height:calc(var(--clcosdk-spacing) * 10)}.clcosdk\\:h-11{height:calc(var(--clcosdk-spacing) * 11)}.clcosdk\\:h-12{height:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:h-14{height:calc(var(--clcosdk-spacing) * 14)}.clcosdk\\:h-\\[1em\\]{height:1em}.clcosdk\\:h-\\[18px\\]{height:18px}.clcosdk\\:h-\\[54px\\]{height:54px}.clcosdk\\:h-\\[71px\\]{height:71px}.clcosdk\\:h-auto{height:auto}.clcosdk\\:h-full{height:100%}.clcosdk\\:h-px{height:1px}.clcosdk\\:max-h-\\[92vh\\]{max-height:92vh}.clcosdk\\:max-h-full{max-height:100%}.clcosdk\\:min-h-0{min-height:0}.clcosdk\\:min-h-9{min-height:calc(var(--clcosdk-spacing) * 9)}.clcosdk\\:min-h-40{min-height:calc(var(--clcosdk-spacing) * 40)}.clcosdk\\:min-h-\\[1lh\\]{min-height:1lh}.clcosdk\\:min-h-screen{min-height:100vh}.clcosdk\\:w-1{width:var(--clcosdk-spacing)}.clcosdk\\:w-1\\/2{width:50%}.clcosdk\\:w-2\\/5{width:40%}.clcosdk\\:w-3\\/5{width:60%}.clcosdk\\:w-4{width:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:w-5{width:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:w-6{width:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:w-8{width:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:w-10{width:calc(var(--clcosdk-spacing) * 10)}.clcosdk\\:w-12{width:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:w-16{width:calc(var(--clcosdk-spacing) * 16)}.clcosdk\\:w-20{width:calc(var(--clcosdk-spacing) * 20)}.clcosdk\\:w-24{width:calc(var(--clcosdk-spacing) * 24)}.clcosdk\\:w-28{width:calc(var(--clcosdk-spacing) * 28)}.clcosdk\\:w-32{width:calc(var(--clcosdk-spacing) * 32)}.clcosdk\\:w-40{width:calc(var(--clcosdk-spacing) * 40)}.clcosdk\\:w-48{width:calc(var(--clcosdk-spacing) * 48)}.clcosdk\\:w-56{width:calc(var(--clcosdk-spacing) * 56)}.clcosdk\\:w-80{width:calc(var(--clcosdk-spacing) * 80)}.clcosdk\\:w-96{width:calc(var(--clcosdk-spacing) * 96)}.clcosdk\\:w-\\[16px\\]{width:16px}.clcosdk\\:w-\\[28rem\\]{width:28rem}.clcosdk\\:w-\\[36rem\\]{width:36rem}.clcosdk\\:w-\\[448px\\]{width:448px}.clcosdk\\:w-\\[calc\\(100\\%\\+16px\\)\\]{width:calc(100% + 16px)}.clcosdk\\:w-component{width:448px}.clcosdk\\:w-fit{width:fit-content}.clcosdk\\:w-full{width:100%}.clcosdk\\:w-max{width:max-content}.clcosdk\\:max-w-\\[16rem\\]{max-width:16rem}.clcosdk\\:max-w-\\[28rem\\]{max-width:28rem}.clcosdk\\:max-w-\\[30rem\\]{max-width:30rem}.clcosdk\\:max-w-\\[40rem\\]{max-width:40rem}.clcosdk\\:max-w-\\[50\\%\\]{max-width:50%}.clcosdk\\:max-w-\\[56rem\\]{max-width:56rem}.clcosdk\\:max-w-\\[64rem\\]{max-width:64rem}.clcosdk\\:max-w-\\[400px\\]{max-width:400px}.clcosdk\\:max-w-\\[448px\\]{max-width:448px}.clcosdk\\:max-w-\\[760px\\]{max-width:760px}.clcosdk\\:max-w-full{max-width:100%}.clcosdk\\:max-w-md{max-width:var(--clcosdk-container-md)}.clcosdk\\:max-w-sm{max-width:var(--clcosdk-container-sm)}.clcosdk\\:max-w-xl{max-width:var(--clcosdk-container-xl)}.clcosdk\\:min-w-0{min-width:0}.clcosdk\\:flex-1{flex:1}.clcosdk\\:shrink-0{flex-shrink:0}.clcosdk\\:-translate-x-1\\/2{--tw-translate-x:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.clcosdk\\:-translate-y-1\\/2{--tw-translate-y:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.clcosdk\\:rotate-90{rotate:90deg}.clcosdk\\:rotate-180{rotate:180deg}.clcosdk\\:animate-pulse{animation:var(--clcosdk-animate-pulse)}.clcosdk\\:animate-spin{animation:var(--clcosdk-animate-spin)}.clcosdk\\:cursor-pointer{cursor:pointer}.clcosdk\\:cursor-text{cursor:text}.clcosdk\\:grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.clcosdk\\:grid-rows-\\[0fr\\]{grid-template-rows:0fr}.clcosdk\\:grid-rows-\\[1fr\\]{grid-template-rows:1fr}.clcosdk\\:flex-col{flex-direction:column}.clcosdk\\:flex-row{flex-direction:row}.clcosdk\\:flex-wrap{flex-wrap:wrap}.clcosdk\\:items-center{align-items:center}.clcosdk\\:items-end{align-items:flex-end}.clcosdk\\:items-start{align-items:flex-start}.clcosdk\\:justify-between{justify-content:space-between}.clcosdk\\:justify-center{justify-content:center}.clcosdk\\:justify-end{justify-content:flex-end}.clcosdk\\:justify-start{justify-content:flex-start}.clcosdk\\:gap-1{gap:var(--clcosdk-spacing)}.clcosdk\\:gap-1\\.5{gap:calc(var(--clcosdk-spacing) * 1.5)}.clcosdk\\:gap-2{gap:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:gap-2\\.5{gap:calc(var(--clcosdk-spacing) * 2.5)}.clcosdk\\:gap-3{gap:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:gap-4{gap:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:gap-6{gap:calc(var(--clcosdk-spacing) * 6)}:where(.clcosdk\\:space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--clcosdk-spacing) * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--clcosdk-spacing) * 3) * calc(1 - var(--tw-space-y-reverse)))}:where(.clcosdk\\:space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--clcosdk-spacing) * 4) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--clcosdk-spacing) * 4) * calc(1 - var(--tw-space-y-reverse)))}:where(.clcosdk\\:divide-y>:not(:last-child)){--tw-divide-y-reverse:0;border-bottom-style:var(--tw-border-style);border-top-style:var(--tw-border-style);border-top-width:calc(1px * var(--tw-divide-y-reverse));border-bottom-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)))}:where(.clcosdk\\:divide-divider>:not(:last-child)){border-color:var(--color-divider)}.clcosdk\\:self-start{align-self:flex-start}.clcosdk\\:truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.clcosdk\\:overflow-hidden{overflow:hidden}.clcosdk\\:overflow-y-auto{overflow-y:auto}.clcosdk\\:rounded{border-radius:.25rem}.clcosdk\\:rounded-2xl{border-radius:var(--clcosdk-radius-2xl)}.clcosdk\\:rounded-\\[20px\\]{border-radius:20px}.clcosdk\\:rounded-\\[28px\\]{border-radius:28px}.clcosdk\\:rounded-btn{border-radius:12px}.clcosdk\\:rounded-card{border-radius:24px}.clcosdk\\:rounded-full{border-radius:3.40282e38px}.clcosdk\\:rounded-lg{border-radius:var(--clcosdk-radius-lg)}.clcosdk\\:rounded-md{border-radius:var(--clcosdk-radius-md)}.clcosdk\\:rounded-xl{border-radius:var(--clcosdk-radius-xl)}.clcosdk\\:border{border-style:var(--tw-border-style);border-width:1px}.clcosdk\\:border-2{border-style:var(--tw-border-style);border-width:2px}.clcosdk\\:border-\\[1\\.5px\\]{border-style:var(--tw-border-style);border-width:1.5px}.clcosdk\\:border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.clcosdk\\:border-b-2{border-bottom-style:var(--tw-border-style);border-bottom-width:2px}.clcosdk\\:border-accent\\/60{border-color:var(--color-accent)}@supports (color:color-mix(in lab, red, red)){.clcosdk\\:border-accent\\/60{border-color:color-mix(in oklab, var(--color-accent) 60%, transparent)}}.clcosdk\\:border-amber-500{border-color:var(--clcosdk-color-amber-500)}.clcosdk\\:border-background{border-color:var(--color-background)}.clcosdk\\:border-border{border-color:var(--color-border)}.clcosdk\\:border-brand-primary{border-color:var(--color-brand-primary)}.clcosdk\\:border-current{border-color:currentColor}.clcosdk\\:border-divider{border-color:var(--color-divider)}.clcosdk\\:border-error-border{border-color:var(--color-error-border)}.clcosdk\\:border-sale-card-border{border-color:var(--color-sale-card-border)}.clcosdk\\:border-sale-card-chrome-border{border-color:var(--color-sale-card-chrome-border)}.clcosdk\\:border-success-border{border-color:var(--color-success-border)}.clcosdk\\:border-text-primary{border-color:var(--color-text-primary)}.clcosdk\\:border-transparent{border-color:#0000}.clcosdk\\:border-warning-border{border-color:var(--color-warning-border)}.clcosdk\\:border-t-transparent{border-top-color:#0000}.clcosdk\\:bg-background{background-color:var(--color-background)}.clcosdk\\:bg-black\\/50{background-color:var(--clcosdk-color-black)}@supports (color:color-mix(in lab, red, red)){.clcosdk\\:bg-black\\/50{background-color:color-mix(in oklab, var(--clcosdk-color-black) 50%, transparent)}}.clcosdk\\:bg-brand-primary{background-color:var(--color-brand-primary)}.clcosdk\\:bg-divider{background-color:var(--color-divider)}.clcosdk\\:bg-error-subtle{background-color:var(--color-error-subtle)}.clcosdk\\:bg-overlay{background-color:var(--color-overlay)}.clcosdk\\:bg-positive{background-color:var(--color-positive)}.clcosdk\\:bg-positive-subtle{background-color:var(--color-positive-subtle)}.clcosdk\\:bg-sale-card-chrome-bg{background-color:var(--color-sale-card-chrome-bg)}.clcosdk\\:bg-section{background-color:var(--color-section)}.clcosdk\\:bg-success-subtle{background-color:var(--color-success-subtle)}.clcosdk\\:bg-surface{background-color:var(--color-surface)}.clcosdk\\:bg-text-disabled{background-color:var(--color-text-disabled)}.clcosdk\\:bg-text-primary{background-color:var(--color-text-primary)}.clcosdk\\:bg-transparent{background-color:#0000}.clcosdk\\:bg-warning-subtle{background-color:var(--color-warning-subtle)}.clcosdk\\:bg-\\[image\\:var\\(--btn-primary-gradient\\)\\]{background-image:var(--btn-primary-gradient)}.clcosdk\\:bg-\\[image\\:var\\(--sale-card-surface\\)\\]{background-image:var(--sale-card-surface)}.clcosdk\\:object-contain{object-fit:contain}.clcosdk\\:object-cover{object-fit:cover}.clcosdk\\:p-0{padding:0}.clcosdk\\:p-1\\.5{padding:calc(var(--clcosdk-spacing) * 1.5)}.clcosdk\\:p-3{padding:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:p-3\\.5{padding:calc(var(--clcosdk-spacing) * 3.5)}.clcosdk\\:p-4{padding:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:p-5{padding:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:p-6{padding:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:p-8{padding:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:p-16{padding:calc(var(--clcosdk-spacing) * 16)}.clcosdk\\:px-2{padding-inline:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:px-3{padding-inline:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:px-4{padding-inline:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:px-5{padding-inline:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:px-6{padding-inline:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:py-1\\.5{padding-block:calc(var(--clcosdk-spacing) * 1.5)}.clcosdk\\:py-2{padding-block:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:py-3{padding-block:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:py-8{padding-block:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:py-12{padding-block:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:pt-1{padding-top:var(--clcosdk-spacing)}.clcosdk\\:pt-4{padding-top:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:pt-14{padding-top:calc(var(--clcosdk-spacing) * 14)}.clcosdk\\:pr-1\\.5{padding-right:calc(var(--clcosdk-spacing) * 1.5)}.clcosdk\\:pr-3{padding-right:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:pr-4{padding-right:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:pb-1{padding-bottom:var(--clcosdk-spacing)}.clcosdk\\:pb-4{padding-bottom:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:pl-3{padding-left:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:text-center{text-align:center}.clcosdk\\:text-left{text-align:left}.clcosdk\\:text-right{text-align:right}.clcosdk\\:font-mono{font-family:var(--clcosdk-font-mono)}.clcosdk\\:text-base{font-size:var(--clcosdk-text-base);line-height:var(--tw-leading,var(--clcosdk-text-base--line-height))}.clcosdk\\:text-lg{font-size:var(--clcosdk-text-lg);line-height:var(--tw-leading,var(--clcosdk-text-lg--line-height))}.clcosdk\\:text-sm{font-size:var(--clcosdk-text-sm);line-height:var(--tw-leading,var(--clcosdk-text-sm--line-height))}.clcosdk\\:text-xs{font-size:var(--clcosdk-text-xs);line-height:var(--tw-leading,var(--clcosdk-text-xs--line-height))}.clcosdk\\:text-\\[11px\\]{font-size:11px}.clcosdk\\:text-\\[12px\\]{font-size:12px}.clcosdk\\:text-\\[13px\\]{font-size:13px}.clcosdk\\:text-\\[14px\\]{font-size:14px}.clcosdk\\:text-\\[15px\\]{font-size:15px}.clcosdk\\:text-\\[16px\\]{font-size:16px}.clcosdk\\:text-\\[18px\\]{font-size:18px}.clcosdk\\:text-\\[22px\\]{font-size:22px}.clcosdk\\:text-\\[28px\\]{font-size:28px}.clcosdk\\:text-\\[36px\\]{font-size:36px}.clcosdk\\:text-\\[48px\\]{font-size:48px}.clcosdk\\:text-\\[64px\\]{font-size:64px}.clcosdk\\:leading-\\[105\\%\\]{--tw-leading:105%;line-height:105%}.clcosdk\\:leading-\\[108\\%\\]{--tw-leading:108%;line-height:108%}.clcosdk\\:leading-\\[110\\%\\]{--tw-leading:110%;line-height:110%}.clcosdk\\:leading-\\[120\\%\\]{--tw-leading:120%;line-height:120%}.clcosdk\\:leading-\\[130\\%\\]{--tw-leading:130%;line-height:130%}.clcosdk\\:leading-\\[140\\%\\]{--tw-leading:140%;line-height:140%}.clcosdk\\:leading-\\[150\\%\\]{--tw-leading:150%;line-height:150%}.clcosdk\\:leading-\\[160\\%\\]{--tw-leading:160%;line-height:160%}.clcosdk\\:font-medium{--tw-font-weight:var(--clcosdk-font-weight-medium);font-weight:var(--clcosdk-font-weight-medium)}.clcosdk\\:font-normal{--tw-font-weight:var(--clcosdk-font-weight-normal);font-weight:var(--clcosdk-font-weight-normal)}.clcosdk\\:font-semibold{--tw-font-weight:var(--clcosdk-font-weight-semibold);font-weight:var(--clcosdk-font-weight-semibold)}.clcosdk\\:tracking-\\[0\\.28px\\]{--tw-tracking:.28px;letter-spacing:.28px}.clcosdk\\:break-words{overflow-wrap:break-word}.clcosdk\\:break-all{word-break:break-all}.clcosdk\\:whitespace-nowrap{white-space:nowrap}.clcosdk\\:whitespace-pre{white-space:pre}.clcosdk\\:text-background{color:var(--color-background)}.clcosdk\\:text-brand-primary{color:var(--color-brand-primary)}.clcosdk\\:text-error{color:var(--color-error)}.clcosdk\\:text-positive{color:var(--color-positive)}.clcosdk\\:text-sale-card-text{color:var(--color-sale-card-text)}.clcosdk\\:text-sale-card-text-muted{color:var(--color-sale-card-text-muted)}.clcosdk\\:text-sale-card-text-strong{color:var(--color-sale-card-text-strong)}.clcosdk\\:text-success{color:var(--color-success)}.clcosdk\\:text-text-disabled{color:var(--color-text-disabled)}.clcosdk\\:text-text-inverse{color:var(--color-text-inverse)}.clcosdk\\:text-text-primary{color:var(--color-text-primary)}.clcosdk\\:text-text-secondary{color:var(--color-text-secondary)}.clcosdk\\:text-warning{color:var(--color-warning)}.clcosdk\\:capitalize{text-transform:capitalize}.clcosdk\\:lining-nums{--tw-numeric-figure:lining-nums;font-variant-numeric:var(--tw-ordinal,) var(--tw-slashed-zero,) var(--tw-numeric-figure,) var(--tw-numeric-spacing,) var(--tw-numeric-fraction,)}.clcosdk\\:tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,) var(--tw-slashed-zero,) var(--tw-numeric-figure,) var(--tw-numeric-spacing,) var(--tw-numeric-fraction,)}.clcosdk\\:no-underline{text-decoration-line:none}.clcosdk\\:underline{text-decoration-line:underline}.clcosdk\\:underline-offset-2{text-underline-offset:2px}.clcosdk\\:underline-offset-4{text-underline-offset:4px}.clcosdk\\:opacity-0{opacity:0}.clcosdk\\:opacity-60{opacity:.6}.clcosdk\\:shadow-\\[0_0_0_3px_rgba\\(59\\,130\\,246\\,0\\.2\\)\\]{--tw-shadow:0 0 0 3px var(--tw-shadow-color,#3b82f633);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-\\[0px_1px_1px_0px_rgba\\(10\\,10\\,10\\,0\\.04\\)\\,0px_8px_12px_0px_rgba\\(10\\,10\\,10\\,0\\.08\\)\\]{--tw-shadow:0px 1px 1px 0px var(--tw-shadow-color,#0a0a0a0a), 0px 8px 12px 0px var(--tw-shadow-color,#0a0a0a14);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-\\[0px_4px_12px_0px_rgba\\(0\\,0\\,0\\,0\\.08\\)\\,0px_12px_28px_0px_rgba\\(0\\,0\\,0\\,0\\.13\\)\\]{--tw-shadow:0px 4px 12px 0px var(--tw-shadow-color,#00000014), 0px 12px 28px 0px var(--tw-shadow-color,#00000021);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-\\[var\\(--btn-primary-shadow\\)\\]{--tw-shadow:var(--btn-primary-shadow);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-card{--tw-shadow:0px 4px 6px -2px var(--tw-shadow-color,#0000000d), 0px 12px 24px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-dialog{--tw-shadow:var(--shadow-dialog);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-step-active{--tw-shadow:var(--shadow-step-active);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:transition-\\[background-color\\,border-color\\]{transition-property:background-color,border-color;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:transition-\\[grid-template-rows\\]{transition-property:grid-template-rows;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:duration-200{--tw-duration:.2s;transition-duration:.2s}.clcosdk\\:duration-300{--tw-duration:.3s;transition-duration:.3s}.clcosdk\\:duration-500{--tw-duration:.5s;transition-duration:.5s}.clcosdk\\:ease-in-out{--tw-ease:var(--clcosdk-ease-in-out);transition-timing-function:var(--clcosdk-ease-in-out)}.clcosdk\\:ease-out{--tw-ease:var(--clcosdk-ease-out);transition-timing-function:var(--clcosdk-ease-out)}.clcosdk\\:outline-none{--tw-outline-style:none;outline-style:none}.clcosdk\\:group-focus-within\\:opacity-100:is(:where(.clcosdk\\:group):focus-within *){opacity:1}@media (hover:hover){.clcosdk\\:group-hover\\:border-sale-card-chrome-emphasis-border:is(:where(.clcosdk\\:group):hover *){border-color:var(--color-sale-card-chrome-emphasis-border)}.clcosdk\\:group-hover\\:bg-sale-card-chrome-emphasis-bg:is(:where(.clcosdk\\:group):hover *){background-color:var(--color-sale-card-chrome-emphasis-bg)}.clcosdk\\:group-hover\\:opacity-100:is(:where(.clcosdk\\:group):hover *){opacity:1}}.clcosdk\\:group-focus-visible\\:border-sale-card-chrome-emphasis-border:is(:where(.clcosdk\\:group):focus-visible *){border-color:var(--color-sale-card-chrome-emphasis-border)}.clcosdk\\:group-focus-visible\\:bg-sale-card-chrome-emphasis-bg:is(:where(.clcosdk\\:group):focus-visible *){background-color:var(--color-sale-card-chrome-emphasis-bg)}.clcosdk\\:placeholder\\:text-text-disabled::placeholder{color:var(--color-text-disabled)}@media (hover:hover){.clcosdk\\:hover\\:scale-\\[1\\.02\\]:hover{scale:1.02}.clcosdk\\:hover\\:border-text-disabled:hover{border-color:var(--color-text-disabled)}.clcosdk\\:hover\\:bg-\\[\\#fcdcd8\\]:hover{background-color:#fcdcd8}.clcosdk\\:hover\\:bg-border:hover{background-color:var(--color-border)}.clcosdk\\:hover\\:bg-brand-primary:hover{background-color:var(--color-brand-primary)}.clcosdk\\:hover\\:bg-brand-primary-hover:hover{background-color:var(--color-brand-primary-hover)}.clcosdk\\:hover\\:bg-section:hover{background-color:var(--color-section)}.clcosdk\\:hover\\:bg-surface:hover{background-color:var(--color-surface)}.clcosdk\\:hover\\:text-\\[\\#8b1a13\\]:hover{color:#8b1a13}.clcosdk\\:hover\\:text-text-primary:hover{color:var(--color-text-primary)}.clcosdk\\:hover\\:underline:hover{text-decoration-line:underline}.clcosdk\\:hover\\:opacity-80:hover{opacity:.8}.clcosdk\\:hover\\:opacity-90:hover{opacity:.9}}.clcosdk\\:focus-visible\\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:focus-visible\\:ring-gray-400:focus-visible{--tw-ring-color:var(--clcosdk-color-gray-400)}.clcosdk\\:focus-visible\\:ring-gray-500:focus-visible{--tw-ring-color:var(--clcosdk-color-gray-500)}.clcosdk\\:focus-visible\\:ring-red-400:focus-visible{--tw-ring-color:var(--clcosdk-color-red-400)}.clcosdk\\:focus-visible\\:ring-red-500:focus-visible{--tw-ring-color:var(--clcosdk-color-red-500)}.clcosdk\\:focus-visible\\:ring-sale-card-focus-ring:focus-visible{--tw-ring-color:var(--color-sale-card-focus-ring)}.clcosdk\\:focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)}.clcosdk\\:focus-visible\\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.clcosdk\\:active\\:bg-\\[\\#d9d9d9\\]:active{background-color:#d9d9d9}.clcosdk\\:active\\:bg-\\[\\#f9c9c4\\]:active{background-color:#f9c9c4}.clcosdk\\:active\\:bg-border:active{background-color:var(--color-border)}.clcosdk\\:active\\:bg-brand-primary-active:active{background-color:var(--color-brand-primary-active)}.clcosdk\\:active\\:text-\\[\\#6d1510\\]:active{color:#6d1510}.clcosdk\\:active\\:opacity-80:active{opacity:.8}.clcosdk\\:disabled\\:pointer-events-none:disabled{pointer-events:none}.clcosdk\\:disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.clcosdk\\:disabled\\:opacity-40:disabled{opacity:.4}.clcosdk\\:disabled\\:opacity-50:disabled{opacity:.5}.clcosdk\\:aria-disabled\\:cursor-not-allowed[aria-disabled=true]{cursor:not-allowed}.clcosdk\\:aria-disabled\\:opacity-50[aria-disabled=true]{opacity:.5}@media not all and (min-width:48rem){.clcosdk\\:max-md\\:hidden{display:none}.clcosdk\\:max-md\\:w-full{width:100%}.clcosdk\\:max-md\\:justify-start{justify-content:flex-start}.clcosdk\\:max-md\\:gap-4{gap:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:max-md\\:rounded-none{border-radius:0}.clcosdk\\:max-md\\:border-0{border-style:var(--tw-border-style);border-width:0}.clcosdk\\:max-md\\:bg-transparent{background-color:#0000}.clcosdk\\:max-md\\:p-0{padding:0}@media (hover:hover){.clcosdk\\:max-md\\:hover\\:scale-100:hover{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}}}@media (min-width:40rem){.clcosdk\\:sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (min-width:48rem){.clcosdk\\:md\\:right-\\[-10\\%\\]{right:-10%}.clcosdk\\:md\\:order-1{order:1}.clcosdk\\:md\\:order-2{order:2}.clcosdk\\:md\\:hidden{display:none}.clcosdk\\:md\\:size-\\[20rem\\]{width:20rem;height:20rem}.clcosdk\\:md\\:h-9{height:calc(var(--clcosdk-spacing) * 9)}.clcosdk\\:md\\:h-12{height:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:md\\:h-\\[54px\\]{height:54px}.clcosdk\\:md\\:w-9{width:calc(var(--clcosdk-spacing) * 9)}.clcosdk\\:md\\:w-12{width:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:md\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.clcosdk\\:md\\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.clcosdk\\:md\\:grid-cols-\\[minmax\\(0\\,11fr\\)_minmax\\(0\\,8fr\\)\\]{grid-template-columns:minmax(0,11fr) minmax(0,8fr)}.clcosdk\\:md\\:flex-row{flex-direction:row}.clcosdk\\:md\\:items-center{align-items:center}.clcosdk\\:md\\:items-end{align-items:flex-end}.clcosdk\\:md\\:justify-between{justify-content:space-between}.clcosdk\\:md\\:justify-end{justify-content:flex-end}.clcosdk\\:md\\:gap-3{gap:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:md\\:gap-6{gap:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:md\\:gap-x-12{column-gap:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:md\\:self-end{align-self:flex-end}.clcosdk\\:md\\:rounded-\\[40px\\]{border-radius:40px}.clcosdk\\:md\\:rounded-card{border-radius:24px}.clcosdk\\:md\\:rounded-dialog{border-radius:32px}.clcosdk\\:md\\:p-4{padding:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:md\\:p-6{padding:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:md\\:p-8{padding:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:md\\:px-6{padding-inline:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:md\\:px-8{padding-inline:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:md\\:py-2{padding-block:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:md\\:pr-2{padding-right:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:md\\:pr-4{padding-right:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:md\\:pl-4{padding-left:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:md\\:text-base{font-size:var(--clcosdk-text-base);line-height:var(--tw-leading,var(--clcosdk-text-base--line-height))}.clcosdk\\:md\\:text-\\[14px\\]{font-size:14px}.clcosdk\\:md\\:text-\\[16px\\]{font-size:16px}.clcosdk\\:md\\:text-\\[18px\\]{font-size:18px}.clcosdk\\:md\\:text-\\[28px\\]{font-size:28px}.clcosdk\\:md\\:leading-\\[120\\%\\]{--tw-leading:120%;line-height:120%}.clcosdk\\:md\\:leading-\\[160\\%\\]{--tw-leading:160%;line-height:160%}}@media (prefers-color-scheme:dark){@media (hover:hover){.clcosdk\\:dark\\:hover\\:bg-\\[rgba\\(248\\,113\\,113\\,0\\.20\\)\\]:not(:where(.light,.light *)):hover{background-color:#f8717133}}}@media (hover:hover){.clcosdk\\:dark\\:hover\\:bg-\\[rgba\\(248\\,113\\,113\\,0\\.20\\)\\]:where(.dark,.dark *):hover{background-color:#f8717133}}@media (prefers-color-scheme:dark){@media (hover:hover){.clcosdk\\:dark\\:hover\\:text-\\[\\#fca5a5\\]:not(:where(.light,.light *)):hover{color:#fca5a5}}}@media (hover:hover){.clcosdk\\:dark\\:hover\\:text-\\[\\#fca5a5\\]:where(.dark,.dark *):hover{color:#fca5a5}}@media (prefers-color-scheme:dark){.clcosdk\\:dark\\:active\\:bg-\\[rgba\\(248\\,113\\,113\\,0\\.30\\)\\]:not(:where(.light,.light *)):active{background-color:#f871714d}}.clcosdk\\:dark\\:active\\:bg-\\[rgba\\(248\\,113\\,113\\,0\\.30\\)\\]:where(.dark,.dark *):active{background-color:#f871714d}@media (prefers-color-scheme:dark){.clcosdk\\:dark\\:active\\:bg-divider:not(:where(.light,.light *)):active{background-color:var(--color-divider)}}.clcosdk\\:dark\\:active\\:bg-divider:where(.dark,.dark *):active{background-color:var(--color-divider)}@media (prefers-color-scheme:dark){.clcosdk\\:dark\\:active\\:text-\\[\\#f87171\\]:not(:where(.light,.light *)):active{color:#f87171}}.clcosdk\\:dark\\:active\\:text-\\[\\#f87171\\]:where(.dark,.dark *):active{color:#f87171}.clcosdk\\:\\[\\&_circle\\]\\:fill-error-subtle circle{fill:var(--color-error-subtle)}.clcosdk\\:\\[\\&_circle\\]\\:fill-success-subtle circle{fill:var(--color-success-subtle)}.clcosdk\\:\\[\\&_circle\\]\\:fill-warning-subtle circle{fill:var(--color-warning-subtle)}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-divide-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@keyframes spin{to{transform:rotate(360deg)}}@keyframes pulse{50%{opacity:.5}}';
|
|
1802
|
+
var sdkStyles = '/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-space-y-reverse:0;--tw-divide-y-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-duration:initial;--tw-ease:initial;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1}}}@layer theme{:root,:host{--clcosdk-font-mono:ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--clcosdk-color-red-400:oklch(70.4% .191 22.216);--clcosdk-color-red-500:oklch(63.7% .237 25.331);--clcosdk-color-amber-500:oklch(76.9% .188 70.08);--clcosdk-color-gray-400:oklch(70.7% .022 261.325);--clcosdk-color-gray-500:oklch(55.1% .027 264.364);--clcosdk-color-black:#000;--clcosdk-spacing:.25rem;--clcosdk-container-sm:24rem;--clcosdk-container-md:28rem;--clcosdk-container-xl:36rem;--clcosdk-text-xs:.75rem;--clcosdk-text-xs--line-height:calc(1 / .75);--clcosdk-text-sm:.875rem;--clcosdk-text-sm--line-height:calc(1.25 / .875);--clcosdk-text-base:1rem;--clcosdk-text-base--line-height:calc(1.5 / 1);--clcosdk-text-lg:1.125rem;--clcosdk-text-lg--line-height:calc(1.75 / 1.125);--clcosdk-font-weight-normal:400;--clcosdk-font-weight-medium:500;--clcosdk-font-weight-semibold:600;--clcosdk-radius-md:.375rem;--clcosdk-radius-lg:.5rem;--clcosdk-radius-xl:.75rem;--clcosdk-radius-2xl:1rem;--clcosdk-ease-out:cubic-bezier(0, 0, .2, 1);--clcosdk-ease-in-out:cubic-bezier(.4, 0, .2, 1);--clcosdk-animate-spin:spin 1s linear infinite;--clcosdk-animate-pulse:pulse 2s cubic-bezier(.4, 0, .6, 1) infinite;--clcosdk-color-brand-primary:var(--color-brand-primary)}}@layer base{.clco-sdk-root{--color-brand-primary:#171717;--color-brand-primary-hover:#000;--color-brand-primary-active:#262626;--color-accent:#2b3a67;--color-accent-hover:#243057;--color-accent-active:#1d2647;--color-accent-focus:#c7d2fe;--color-accent-subtle:#eef1f8;--color-text-primary:#171717;--color-text-secondary:#8c8c8c;--color-text-disabled:#d1d1d1;--color-text-inverse:#fff;--color-background:#fff;--color-surface:#fafafa;--color-section:#f3f3f3;--color-border:#e5e5e5;--color-divider:#ececec;--color-overlay:#00000080;--color-positive:#15803d;--color-positive-subtle:#dcfce7;--color-negative:#dc2626;--color-negative-subtle:#fee2e2;--color-success:#2c8c5e;--color-success-subtle:#e6f4ec;--color-success-border:#cfe9db;--color-warning:#e08a1a;--color-warning-subtle:#fff7ed;--color-warning-border:#fdead7;--color-error:#b42318;--color-error-subtle:#feeceb;--color-error-border:#fbd5d2;--shadow-step-active:0px 0px 10px 0px #0000001a;--shadow-dialog:0px 8px 32px 0px #0000001a;--btn-primary-gradient:linear-gradient(180deg, #262626 0%, #1c1c1c 50%, #0f0f0f 100%);--btn-primary-shadow:inset 0px -1px 3px 0px #00000059, inset 0px 1px 2px 0px #ffffff2e, inset 0px 1px 0px 0px #ffffff1a;--sale-card-surface:linear-gradient(to top, #0a0a0a 0%, #1a1a1a 100%);--color-sale-card-text:#f4f4f5;--color-sale-card-text-muted:#a1a1aa;--color-sale-card-text-strong:#fff;--color-sale-card-border:#ffffff40;--color-sale-card-chrome-border:#ffffff4d;--color-sale-card-chrome-bg:#ffffff26;--color-sale-card-chrome-emphasis-border:#fff6;--color-sale-card-chrome-emphasis-bg:#ffffff40;--color-sale-card-focus-ring:#ffffff80;--display-on-light:block;--display-on-dark:none}@media (prefers-color-scheme:dark){.clco-sdk-root:not(:where(.light,.light *)){--color-brand-primary:#f4f4f5;--color-brand-primary-hover:#fff;--color-brand-primary-active:#e4e4e7;--color-accent:#6f82c9;--color-accent-hover:#8799e4;--color-accent-active:#5b6fcf;--color-accent-focus:#6f82c959;--color-accent-subtle:#6f82c91f;--color-text-primary:#f4f4f5;--color-text-secondary:#a1a1aa;--color-text-disabled:#71717a;--color-text-inverse:#171717;--color-background:#0f1115;--color-surface:#161a20;--color-section:#20242c;--color-border:#2a2e35;--color-divider:#323741;--color-overlay:#000000b3;--color-positive:#22c55e;--color-positive-subtle:#22c55e1f;--color-negative:#ef4444;--color-negative-subtle:#ef44441f;--color-success:#34d399;--color-success-subtle:#34d3991f;--color-success-border:#34d39940;--color-warning:#f59e0b;--color-warning-subtle:#f59e0b1f;--color-warning-border:#f59e0b40;--color-error:#f87171;--color-error-subtle:#f871711f;--color-error-border:#f8717140;--shadow-step-active:0px 0px 10px 0px #00000080;--shadow-dialog:0px 8px 32px 0px #0009;--btn-primary-gradient:linear-gradient(180deg, #fafafa 0%, #f0f0f0 50%, #e4e4e7 100%);--btn-primary-shadow:inset 0px -1px 3px 0px #0000001f, inset 0px 1px 2px 0px #fff9, inset 0px 1px 0px 0px #fff6;--display-on-light:none;--display-on-dark:block}}:where(.dark,.dark *) .clco-sdk-root{--color-brand-primary:#f4f4f5;--color-brand-primary-hover:#fff;--color-brand-primary-active:#e4e4e7;--color-accent:#6f82c9;--color-accent-hover:#8799e4;--color-accent-active:#5b6fcf;--color-accent-focus:#6f82c959;--color-accent-subtle:#6f82c91f;--color-text-primary:#f4f4f5;--color-text-secondary:#a1a1aa;--color-text-disabled:#71717a;--color-text-inverse:#171717;--color-background:#0f1115;--color-surface:#161a20;--color-section:#20242c;--color-border:#2a2e35;--color-divider:#323741;--color-overlay:#000000b3;--color-positive:#22c55e;--color-positive-subtle:#22c55e1f;--color-negative:#ef4444;--color-negative-subtle:#ef44441f;--color-success:#34d399;--color-success-subtle:#34d3991f;--color-success-border:#34d39940;--color-warning:#f59e0b;--color-warning-subtle:#f59e0b1f;--color-warning-border:#f59e0b40;--color-error:#f87171;--color-error-subtle:#f871711f;--color-error-border:#f8717140;--shadow-step-active:0px 0px 10px 0px #00000080;--shadow-dialog:0px 8px 32px 0px #0009;--btn-primary-gradient:linear-gradient(180deg, #fafafa 0%, #f0f0f0 50%, #e4e4e7 100%);--btn-primary-shadow:inset 0px -1px 3px 0px #0000001f, inset 0px 1px 2px 0px #fff9, inset 0px 1px 0px 0px #fff6;--display-on-light:none;--display-on-dark:block}.clco-sdk-root{color:var(--color-text-primary);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:Inter,sans-serif}.clco-sdk-root *,.clco-sdk-root :before,.clco-sdk-root :after{box-sizing:border-box}.clco-sdk-root button{appearance:none;cursor:pointer;font:inherit;color:inherit;background:0 0;border:none;padding:0}.clco-sdk-root input,.clco-sdk-root textarea,.clco-sdk-root select{font:inherit;color:inherit;background:0 0;border:none;border-radius:0;padding:0}.clco-sdk-root a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}.clco-sdk-root ul,.clco-sdk-root ol{margin:0;padding:0;list-style:none}.clco-sdk-root h1,.clco-sdk-root h2,.clco-sdk-root h3,.clco-sdk-root h4,.clco-sdk-root h5,.clco-sdk-root h6,.clco-sdk-root p,.clco-sdk-root figure,.clco-sdk-root blockquote,.clco-sdk-root dl,.clco-sdk-root dd,.clco-sdk-root pre{margin:0}.clco-sdk-root img,.clco-sdk-root svg{max-width:100%;display:block}@keyframes clco-status-ping{0%{opacity:.7;transform:scale(1)}75%,to{opacity:0;transform:scale(3.25)}}.clco-sdk-root .clcosdk-status-dot-ping{animation:1.6s cubic-bezier(0,0,.2,1) infinite clco-status-ping}.clco-sdk-root .clcosdk-on-light{display:var(--display-on-light)}.clco-sdk-root .clcosdk-on-dark{display:var(--display-on-dark)}@media (prefers-reduced-motion:reduce){.clco-sdk-root .clcosdk-status-dot-ping{opacity:0;animation:none}}}@layer components;@layer utilities{.clcosdk\\:pointer-events-none{pointer-events:none}.clcosdk\\:invisible{visibility:hidden}.clcosdk\\:sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.clcosdk\\:absolute{position:absolute}.clcosdk\\:fixed{position:fixed}.clcosdk\\:relative{position:relative}.clcosdk\\:inset-0{inset:0}.clcosdk\\:top-1\\/2{top:50%}.clcosdk\\:top-4{top:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:top-full{top:100%}.clcosdk\\:-right-0\\.5{right:calc(var(--clcosdk-spacing) * -.5)}.clcosdk\\:right-4{right:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:right-\\[-14\\%\\]{right:-14%}.clcosdk\\:-bottom-0\\.5{bottom:calc(var(--clcosdk-spacing) * -.5)}.clcosdk\\:bottom-full{bottom:100%}.clcosdk\\:left-1\\/2{left:50%}.clcosdk\\:z-0{z-index:0}.clcosdk\\:z-10{z-index:10}.clcosdk\\:z-50{z-index:50}.clcosdk\\:order-1{order:1}.clcosdk\\:order-2{order:2}.clcosdk\\:-mx-2{margin-inline:calc(var(--clcosdk-spacing) * -2)}.clcosdk\\:mt-2{margin-top:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:mt-4{margin-top:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:mt-auto{margin-top:auto}.clcosdk\\:mb-2{margin-bottom:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:flex{display:flex}.clcosdk\\:grid{display:grid}.clcosdk\\:inline-flex{display:inline-flex}.clcosdk\\:size-2{width:calc(var(--clcosdk-spacing) * 2);height:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:size-3{width:calc(var(--clcosdk-spacing) * 3);height:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:size-3\\.5{width:calc(var(--clcosdk-spacing) * 3.5);height:calc(var(--clcosdk-spacing) * 3.5)}.clcosdk\\:size-4{width:calc(var(--clcosdk-spacing) * 4);height:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:size-5{width:calc(var(--clcosdk-spacing) * 5);height:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:size-6{width:calc(var(--clcosdk-spacing) * 6);height:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:size-10{width:calc(var(--clcosdk-spacing) * 10);height:calc(var(--clcosdk-spacing) * 10)}.clcosdk\\:size-12{width:calc(var(--clcosdk-spacing) * 12);height:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:size-16{width:calc(var(--clcosdk-spacing) * 16);height:calc(var(--clcosdk-spacing) * 16)}.clcosdk\\:size-24{width:calc(var(--clcosdk-spacing) * 24);height:calc(var(--clcosdk-spacing) * 24)}.clcosdk\\:size-\\[15rem\\]{width:15rem;height:15rem}.clcosdk\\:size-full{width:100%;height:100%}.clcosdk\\:h-1{height:var(--clcosdk-spacing)}.clcosdk\\:h-3{height:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:h-3\\.5{height:calc(var(--clcosdk-spacing) * 3.5)}.clcosdk\\:h-4{height:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:h-5{height:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:h-6{height:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:h-8{height:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:h-9{height:calc(var(--clcosdk-spacing) * 9)}.clcosdk\\:h-10{height:calc(var(--clcosdk-spacing) * 10)}.clcosdk\\:h-11{height:calc(var(--clcosdk-spacing) * 11)}.clcosdk\\:h-12{height:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:h-14{height:calc(var(--clcosdk-spacing) * 14)}.clcosdk\\:h-\\[1em\\]{height:1em}.clcosdk\\:h-\\[18px\\]{height:18px}.clcosdk\\:h-\\[54px\\]{height:54px}.clcosdk\\:h-\\[71px\\]{height:71px}.clcosdk\\:h-auto{height:auto}.clcosdk\\:h-full{height:100%}.clcosdk\\:h-px{height:1px}.clcosdk\\:max-h-\\[92vh\\]{max-height:92vh}.clcosdk\\:max-h-full{max-height:100%}.clcosdk\\:min-h-0{min-height:0}.clcosdk\\:min-h-9{min-height:calc(var(--clcosdk-spacing) * 9)}.clcosdk\\:min-h-40{min-height:calc(var(--clcosdk-spacing) * 40)}.clcosdk\\:min-h-\\[1lh\\]{min-height:1lh}.clcosdk\\:min-h-screen{min-height:100vh}.clcosdk\\:w-1{width:var(--clcosdk-spacing)}.clcosdk\\:w-1\\/2{width:50%}.clcosdk\\:w-2\\/5{width:40%}.clcosdk\\:w-3\\.5{width:calc(var(--clcosdk-spacing) * 3.5)}.clcosdk\\:w-3\\/5{width:60%}.clcosdk\\:w-4{width:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:w-5{width:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:w-6{width:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:w-8{width:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:w-10{width:calc(var(--clcosdk-spacing) * 10)}.clcosdk\\:w-12{width:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:w-16{width:calc(var(--clcosdk-spacing) * 16)}.clcosdk\\:w-20{width:calc(var(--clcosdk-spacing) * 20)}.clcosdk\\:w-24{width:calc(var(--clcosdk-spacing) * 24)}.clcosdk\\:w-28{width:calc(var(--clcosdk-spacing) * 28)}.clcosdk\\:w-32{width:calc(var(--clcosdk-spacing) * 32)}.clcosdk\\:w-40{width:calc(var(--clcosdk-spacing) * 40)}.clcosdk\\:w-48{width:calc(var(--clcosdk-spacing) * 48)}.clcosdk\\:w-56{width:calc(var(--clcosdk-spacing) * 56)}.clcosdk\\:w-80{width:calc(var(--clcosdk-spacing) * 80)}.clcosdk\\:w-96{width:calc(var(--clcosdk-spacing) * 96)}.clcosdk\\:w-\\[16px\\]{width:16px}.clcosdk\\:w-\\[28rem\\]{width:28rem}.clcosdk\\:w-\\[36rem\\]{width:36rem}.clcosdk\\:w-\\[240px\\]{width:240px}.clcosdk\\:w-\\[260px\\]{width:260px}.clcosdk\\:w-\\[320px\\]{width:320px}.clcosdk\\:w-\\[448px\\]{width:448px}.clcosdk\\:w-\\[calc\\(100\\%\\+16px\\)\\]{width:calc(100% + 16px)}.clcosdk\\:w-component{width:448px}.clcosdk\\:w-fit{width:fit-content}.clcosdk\\:w-full{width:100%}.clcosdk\\:w-max{width:max-content}.clcosdk\\:max-w-\\[16rem\\]{max-width:16rem}.clcosdk\\:max-w-\\[28rem\\]{max-width:28rem}.clcosdk\\:max-w-\\[30rem\\]{max-width:30rem}.clcosdk\\:max-w-\\[40rem\\]{max-width:40rem}.clcosdk\\:max-w-\\[50\\%\\]{max-width:50%}.clcosdk\\:max-w-\\[56rem\\]{max-width:56rem}.clcosdk\\:max-w-\\[64rem\\]{max-width:64rem}.clcosdk\\:max-w-\\[400px\\]{max-width:400px}.clcosdk\\:max-w-\\[448px\\]{max-width:448px}.clcosdk\\:max-w-\\[760px\\]{max-width:760px}.clcosdk\\:max-w-full{max-width:100%}.clcosdk\\:max-w-md{max-width:var(--clcosdk-container-md)}.clcosdk\\:max-w-sm{max-width:var(--clcosdk-container-sm)}.clcosdk\\:max-w-xl{max-width:var(--clcosdk-container-xl)}.clcosdk\\:min-w-0{min-width:0}.clcosdk\\:flex-1{flex:1}.clcosdk\\:shrink-0{flex-shrink:0}.clcosdk\\:-translate-x-1\\/2{--tw-translate-x:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.clcosdk\\:-translate-y-1\\/2{--tw-translate-y:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.clcosdk\\:rotate-90{rotate:90deg}.clcosdk\\:rotate-180{rotate:180deg}.clcosdk\\:animate-pulse{animation:var(--clcosdk-animate-pulse)}.clcosdk\\:animate-spin{animation:var(--clcosdk-animate-spin)}.clcosdk\\:cursor-pointer{cursor:pointer}.clcosdk\\:cursor-text{cursor:text}.clcosdk\\:grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.clcosdk\\:grid-rows-\\[0fr\\]{grid-template-rows:0fr}.clcosdk\\:grid-rows-\\[1fr\\]{grid-template-rows:1fr}.clcosdk\\:flex-col{flex-direction:column}.clcosdk\\:flex-row{flex-direction:row}.clcosdk\\:flex-wrap{flex-wrap:wrap}.clcosdk\\:items-center{align-items:center}.clcosdk\\:items-end{align-items:flex-end}.clcosdk\\:items-start{align-items:flex-start}.clcosdk\\:justify-between{justify-content:space-between}.clcosdk\\:justify-center{justify-content:center}.clcosdk\\:justify-end{justify-content:flex-end}.clcosdk\\:justify-start{justify-content:flex-start}.clcosdk\\:gap-1{gap:var(--clcosdk-spacing)}.clcosdk\\:gap-1\\.5{gap:calc(var(--clcosdk-spacing) * 1.5)}.clcosdk\\:gap-2{gap:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:gap-2\\.5{gap:calc(var(--clcosdk-spacing) * 2.5)}.clcosdk\\:gap-3{gap:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:gap-4{gap:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:gap-6{gap:calc(var(--clcosdk-spacing) * 6)}:where(.clcosdk\\:space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--clcosdk-spacing) * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--clcosdk-spacing) * 3) * calc(1 - var(--tw-space-y-reverse)))}:where(.clcosdk\\:space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--clcosdk-spacing) * 4) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--clcosdk-spacing) * 4) * calc(1 - var(--tw-space-y-reverse)))}:where(.clcosdk\\:divide-y>:not(:last-child)){--tw-divide-y-reverse:0;border-bottom-style:var(--tw-border-style);border-top-style:var(--tw-border-style);border-top-width:calc(1px * var(--tw-divide-y-reverse));border-bottom-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)))}:where(.clcosdk\\:divide-divider>:not(:last-child)){border-color:var(--color-divider)}.clcosdk\\:self-start{align-self:flex-start}.clcosdk\\:truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.clcosdk\\:overflow-hidden{overflow:hidden}.clcosdk\\:overflow-y-auto{overflow-y:auto}.clcosdk\\:rounded{border-radius:.25rem}.clcosdk\\:rounded-2xl{border-radius:var(--clcosdk-radius-2xl)}.clcosdk\\:rounded-\\[20px\\]{border-radius:20px}.clcosdk\\:rounded-\\[28px\\]{border-radius:28px}.clcosdk\\:rounded-btn{border-radius:12px}.clcosdk\\:rounded-card{border-radius:24px}.clcosdk\\:rounded-full{border-radius:3.40282e38px}.clcosdk\\:rounded-lg{border-radius:var(--clcosdk-radius-lg)}.clcosdk\\:rounded-md{border-radius:var(--clcosdk-radius-md)}.clcosdk\\:rounded-xl{border-radius:var(--clcosdk-radius-xl)}.clcosdk\\:border{border-style:var(--tw-border-style);border-width:1px}.clcosdk\\:border-2{border-style:var(--tw-border-style);border-width:2px}.clcosdk\\:border-\\[1\\.5px\\]{border-style:var(--tw-border-style);border-width:1.5px}.clcosdk\\:border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.clcosdk\\:border-b-2{border-bottom-style:var(--tw-border-style);border-bottom-width:2px}.clcosdk\\:border-accent\\/60{border-color:var(--color-accent)}@supports (color:color-mix(in lab, red, red)){.clcosdk\\:border-accent\\/60{border-color:color-mix(in oklab, var(--color-accent) 60%, transparent)}}.clcosdk\\:border-amber-500{border-color:var(--clcosdk-color-amber-500)}.clcosdk\\:border-background{border-color:var(--color-background)}.clcosdk\\:border-border{border-color:var(--color-border)}.clcosdk\\:border-brand-primary{border-color:var(--color-brand-primary)}.clcosdk\\:border-current{border-color:currentColor}.clcosdk\\:border-divider{border-color:var(--color-divider)}.clcosdk\\:border-error-border{border-color:var(--color-error-border)}.clcosdk\\:border-sale-card-border{border-color:var(--color-sale-card-border)}.clcosdk\\:border-sale-card-chrome-border{border-color:var(--color-sale-card-chrome-border)}.clcosdk\\:border-success-border{border-color:var(--color-success-border)}.clcosdk\\:border-text-primary{border-color:var(--color-text-primary)}.clcosdk\\:border-transparent{border-color:#0000}.clcosdk\\:border-warning-border{border-color:var(--color-warning-border)}.clcosdk\\:border-t-transparent{border-top-color:#0000}.clcosdk\\:bg-background{background-color:var(--color-background)}.clcosdk\\:bg-black\\/50{background-color:var(--clcosdk-color-black)}@supports (color:color-mix(in lab, red, red)){.clcosdk\\:bg-black\\/50{background-color:color-mix(in oklab, var(--clcosdk-color-black) 50%, transparent)}}.clcosdk\\:bg-brand-primary{background-color:var(--color-brand-primary)}.clcosdk\\:bg-divider{background-color:var(--color-divider)}.clcosdk\\:bg-error-subtle{background-color:var(--color-error-subtle)}.clcosdk\\:bg-overlay{background-color:var(--color-overlay)}.clcosdk\\:bg-positive{background-color:var(--color-positive)}.clcosdk\\:bg-positive-subtle{background-color:var(--color-positive-subtle)}.clcosdk\\:bg-sale-card-chrome-bg{background-color:var(--color-sale-card-chrome-bg)}.clcosdk\\:bg-section{background-color:var(--color-section)}.clcosdk\\:bg-success-subtle{background-color:var(--color-success-subtle)}.clcosdk\\:bg-surface{background-color:var(--color-surface)}.clcosdk\\:bg-text-disabled{background-color:var(--color-text-disabled)}.clcosdk\\:bg-text-primary{background-color:var(--color-text-primary)}.clcosdk\\:bg-transparent{background-color:#0000}.clcosdk\\:bg-warning-subtle{background-color:var(--color-warning-subtle)}.clcosdk\\:bg-\\[image\\:var\\(--btn-primary-gradient\\)\\]{background-image:var(--btn-primary-gradient)}.clcosdk\\:bg-\\[image\\:var\\(--sale-card-surface\\)\\]{background-image:var(--sale-card-surface)}.clcosdk\\:object-contain{object-fit:contain}.clcosdk\\:object-cover{object-fit:cover}.clcosdk\\:p-0{padding:0}.clcosdk\\:p-1\\.5{padding:calc(var(--clcosdk-spacing) * 1.5)}.clcosdk\\:p-3{padding:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:p-3\\.5{padding:calc(var(--clcosdk-spacing) * 3.5)}.clcosdk\\:p-4{padding:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:p-5{padding:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:p-6{padding:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:p-8{padding:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:p-16{padding:calc(var(--clcosdk-spacing) * 16)}.clcosdk\\:px-2{padding-inline:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:px-3{padding-inline:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:px-4{padding-inline:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:px-5{padding-inline:calc(var(--clcosdk-spacing) * 5)}.clcosdk\\:px-6{padding-inline:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:py-1\\.5{padding-block:calc(var(--clcosdk-spacing) * 1.5)}.clcosdk\\:py-2{padding-block:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:py-3{padding-block:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:py-8{padding-block:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:py-12{padding-block:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:pt-1{padding-top:var(--clcosdk-spacing)}.clcosdk\\:pt-4{padding-top:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:pt-14{padding-top:calc(var(--clcosdk-spacing) * 14)}.clcosdk\\:pr-1\\.5{padding-right:calc(var(--clcosdk-spacing) * 1.5)}.clcosdk\\:pr-3{padding-right:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:pr-4{padding-right:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:pb-1{padding-bottom:var(--clcosdk-spacing)}.clcosdk\\:pb-4{padding-bottom:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:pl-3{padding-left:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:text-center{text-align:center}.clcosdk\\:text-left{text-align:left}.clcosdk\\:text-right{text-align:right}.clcosdk\\:font-mono{font-family:var(--clcosdk-font-mono)}.clcosdk\\:text-base{font-size:var(--clcosdk-text-base);line-height:var(--tw-leading,var(--clcosdk-text-base--line-height))}.clcosdk\\:text-lg{font-size:var(--clcosdk-text-lg);line-height:var(--tw-leading,var(--clcosdk-text-lg--line-height))}.clcosdk\\:text-sm{font-size:var(--clcosdk-text-sm);line-height:var(--tw-leading,var(--clcosdk-text-sm--line-height))}.clcosdk\\:text-xs{font-size:var(--clcosdk-text-xs);line-height:var(--tw-leading,var(--clcosdk-text-xs--line-height))}.clcosdk\\:text-\\[11px\\]{font-size:11px}.clcosdk\\:text-\\[12px\\]{font-size:12px}.clcosdk\\:text-\\[13px\\]{font-size:13px}.clcosdk\\:text-\\[14px\\]{font-size:14px}.clcosdk\\:text-\\[15px\\]{font-size:15px}.clcosdk\\:text-\\[16px\\]{font-size:16px}.clcosdk\\:text-\\[18px\\]{font-size:18px}.clcosdk\\:text-\\[22px\\]{font-size:22px}.clcosdk\\:text-\\[28px\\]{font-size:28px}.clcosdk\\:text-\\[36px\\]{font-size:36px}.clcosdk\\:text-\\[48px\\]{font-size:48px}.clcosdk\\:text-\\[64px\\]{font-size:64px}.clcosdk\\:leading-\\[105\\%\\]{--tw-leading:105%;line-height:105%}.clcosdk\\:leading-\\[108\\%\\]{--tw-leading:108%;line-height:108%}.clcosdk\\:leading-\\[110\\%\\]{--tw-leading:110%;line-height:110%}.clcosdk\\:leading-\\[120\\%\\]{--tw-leading:120%;line-height:120%}.clcosdk\\:leading-\\[130\\%\\]{--tw-leading:130%;line-height:130%}.clcosdk\\:leading-\\[140\\%\\]{--tw-leading:140%;line-height:140%}.clcosdk\\:leading-\\[150\\%\\]{--tw-leading:150%;line-height:150%}.clcosdk\\:leading-\\[160\\%\\]{--tw-leading:160%;line-height:160%}.clcosdk\\:font-medium{--tw-font-weight:var(--clcosdk-font-weight-medium);font-weight:var(--clcosdk-font-weight-medium)}.clcosdk\\:font-normal{--tw-font-weight:var(--clcosdk-font-weight-normal);font-weight:var(--clcosdk-font-weight-normal)}.clcosdk\\:font-semibold{--tw-font-weight:var(--clcosdk-font-weight-semibold);font-weight:var(--clcosdk-font-weight-semibold)}.clcosdk\\:tracking-\\[0\\.28px\\]{--tw-tracking:.28px;letter-spacing:.28px}.clcosdk\\:break-words{overflow-wrap:break-word}.clcosdk\\:break-all{word-break:break-all}.clcosdk\\:whitespace-nowrap{white-space:nowrap}.clcosdk\\:whitespace-pre{white-space:pre}.clcosdk\\:text-background{color:var(--color-background)}.clcosdk\\:text-brand-primary{color:var(--color-brand-primary)}.clcosdk\\:text-error{color:var(--color-error)}.clcosdk\\:text-positive{color:var(--color-positive)}.clcosdk\\:text-sale-card-text{color:var(--color-sale-card-text)}.clcosdk\\:text-sale-card-text-muted{color:var(--color-sale-card-text-muted)}.clcosdk\\:text-sale-card-text-strong{color:var(--color-sale-card-text-strong)}.clcosdk\\:text-success{color:var(--color-success)}.clcosdk\\:text-text-disabled{color:var(--color-text-disabled)}.clcosdk\\:text-text-inverse{color:var(--color-text-inverse)}.clcosdk\\:text-text-primary{color:var(--color-text-primary)}.clcosdk\\:text-text-secondary{color:var(--color-text-secondary)}.clcosdk\\:text-warning{color:var(--color-warning)}.clcosdk\\:capitalize{text-transform:capitalize}.clcosdk\\:lining-nums{--tw-numeric-figure:lining-nums;font-variant-numeric:var(--tw-ordinal,) var(--tw-slashed-zero,) var(--tw-numeric-figure,) var(--tw-numeric-spacing,) var(--tw-numeric-fraction,)}.clcosdk\\:tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,) var(--tw-slashed-zero,) var(--tw-numeric-figure,) var(--tw-numeric-spacing,) var(--tw-numeric-fraction,)}.clcosdk\\:no-underline{text-decoration-line:none}.clcosdk\\:underline{text-decoration-line:underline}.clcosdk\\:underline-offset-2{text-underline-offset:2px}.clcosdk\\:underline-offset-4{text-underline-offset:4px}.clcosdk\\:opacity-0{opacity:0}.clcosdk\\:opacity-60{opacity:.6}.clcosdk\\:shadow-\\[0_0_0_3px_rgba\\(59\\,130\\,246\\,0\\.2\\)\\]{--tw-shadow:0 0 0 3px var(--tw-shadow-color,#3b82f633);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-\\[0px_1px_1px_0px_rgba\\(10\\,10\\,10\\,0\\.04\\)\\,0px_8px_12px_0px_rgba\\(10\\,10\\,10\\,0\\.08\\)\\]{--tw-shadow:0px 1px 1px 0px var(--tw-shadow-color,#0a0a0a0a), 0px 8px 12px 0px var(--tw-shadow-color,#0a0a0a14);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-\\[0px_4px_12px_0px_rgba\\(0\\,0\\,0\\,0\\.08\\)\\,0px_12px_28px_0px_rgba\\(0\\,0\\,0\\,0\\.13\\)\\]{--tw-shadow:0px 4px 12px 0px var(--tw-shadow-color,#00000014), 0px 12px 28px 0px var(--tw-shadow-color,#00000021);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-\\[var\\(--btn-primary-shadow\\)\\]{--tw-shadow:var(--btn-primary-shadow);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-card{--tw-shadow:0px 4px 6px -2px var(--tw-shadow-color,#0000000d), 0px 12px 24px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-dialog{--tw-shadow:var(--shadow-dialog);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:shadow-step-active{--tw-shadow:var(--shadow-step-active);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:transition-\\[background-color\\,border-color\\]{transition-property:background-color,border-color;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:transition-\\[grid-template-rows\\]{transition-property:grid-template-rows;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.clcosdk\\:duration-200{--tw-duration:.2s;transition-duration:.2s}.clcosdk\\:duration-300{--tw-duration:.3s;transition-duration:.3s}.clcosdk\\:duration-500{--tw-duration:.5s;transition-duration:.5s}.clcosdk\\:ease-in-out{--tw-ease:var(--clcosdk-ease-in-out);transition-timing-function:var(--clcosdk-ease-in-out)}.clcosdk\\:ease-out{--tw-ease:var(--clcosdk-ease-out);transition-timing-function:var(--clcosdk-ease-out)}.clcosdk\\:outline-none{--tw-outline-style:none;outline-style:none}.clcosdk\\:group-focus-within\\:opacity-100:is(:where(.clcosdk\\:group):focus-within *){opacity:1}@media (hover:hover){.clcosdk\\:group-hover\\:border-sale-card-chrome-emphasis-border:is(:where(.clcosdk\\:group):hover *){border-color:var(--color-sale-card-chrome-emphasis-border)}.clcosdk\\:group-hover\\:bg-sale-card-chrome-emphasis-bg:is(:where(.clcosdk\\:group):hover *){background-color:var(--color-sale-card-chrome-emphasis-bg)}.clcosdk\\:group-hover\\:opacity-100:is(:where(.clcosdk\\:group):hover *){opacity:1}}.clcosdk\\:group-focus-visible\\:border-sale-card-chrome-emphasis-border:is(:where(.clcosdk\\:group):focus-visible *){border-color:var(--color-sale-card-chrome-emphasis-border)}.clcosdk\\:group-focus-visible\\:bg-sale-card-chrome-emphasis-bg:is(:where(.clcosdk\\:group):focus-visible *){background-color:var(--color-sale-card-chrome-emphasis-bg)}.clcosdk\\:placeholder\\:text-text-disabled::placeholder{color:var(--color-text-disabled)}@media (hover:hover){.clcosdk\\:hover\\:scale-\\[1\\.02\\]:hover{scale:1.02}.clcosdk\\:hover\\:border-text-disabled:hover{border-color:var(--color-text-disabled)}.clcosdk\\:hover\\:bg-\\[\\#fcdcd8\\]:hover{background-color:#fcdcd8}.clcosdk\\:hover\\:bg-border:hover{background-color:var(--color-border)}.clcosdk\\:hover\\:bg-brand-primary:hover{background-color:var(--color-brand-primary)}.clcosdk\\:hover\\:bg-brand-primary-hover:hover{background-color:var(--color-brand-primary-hover)}.clcosdk\\:hover\\:bg-section:hover{background-color:var(--color-section)}.clcosdk\\:hover\\:bg-surface:hover{background-color:var(--color-surface)}.clcosdk\\:hover\\:text-\\[\\#8b1a13\\]:hover{color:#8b1a13}.clcosdk\\:hover\\:text-text-primary:hover{color:var(--color-text-primary)}.clcosdk\\:hover\\:underline:hover{text-decoration-line:underline}.clcosdk\\:hover\\:opacity-80:hover{opacity:.8}.clcosdk\\:hover\\:opacity-90:hover{opacity:.9}}.clcosdk\\:focus-visible\\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.clcosdk\\:focus-visible\\:ring-gray-400:focus-visible{--tw-ring-color:var(--clcosdk-color-gray-400)}.clcosdk\\:focus-visible\\:ring-gray-500:focus-visible{--tw-ring-color:var(--clcosdk-color-gray-500)}.clcosdk\\:focus-visible\\:ring-red-400:focus-visible{--tw-ring-color:var(--clcosdk-color-red-400)}.clcosdk\\:focus-visible\\:ring-red-500:focus-visible{--tw-ring-color:var(--clcosdk-color-red-500)}.clcosdk\\:focus-visible\\:ring-sale-card-focus-ring:focus-visible{--tw-ring-color:var(--color-sale-card-focus-ring)}.clcosdk\\:focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)}.clcosdk\\:focus-visible\\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.clcosdk\\:active\\:bg-\\[\\#d9d9d9\\]:active{background-color:#d9d9d9}.clcosdk\\:active\\:bg-\\[\\#f9c9c4\\]:active{background-color:#f9c9c4}.clcosdk\\:active\\:bg-border:active{background-color:var(--color-border)}.clcosdk\\:active\\:bg-brand-primary-active:active{background-color:var(--color-brand-primary-active)}.clcosdk\\:active\\:text-\\[\\#6d1510\\]:active{color:#6d1510}.clcosdk\\:active\\:opacity-80:active{opacity:.8}.clcosdk\\:disabled\\:pointer-events-none:disabled{pointer-events:none}.clcosdk\\:disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.clcosdk\\:disabled\\:opacity-40:disabled{opacity:.4}.clcosdk\\:disabled\\:opacity-50:disabled{opacity:.5}.clcosdk\\:aria-disabled\\:cursor-not-allowed[aria-disabled=true]{cursor:not-allowed}.clcosdk\\:aria-disabled\\:opacity-50[aria-disabled=true]{opacity:.5}@media not all and (min-width:48rem){.clcosdk\\:max-md\\:hidden{display:none}.clcosdk\\:max-md\\:w-full{width:100%}.clcosdk\\:max-md\\:justify-start{justify-content:flex-start}.clcosdk\\:max-md\\:gap-4{gap:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:max-md\\:rounded-none{border-radius:0}.clcosdk\\:max-md\\:border-0{border-style:var(--tw-border-style);border-width:0}.clcosdk\\:max-md\\:bg-transparent{background-color:#0000}.clcosdk\\:max-md\\:p-0{padding:0}@media (hover:hover){.clcosdk\\:max-md\\:hover\\:scale-100:hover{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}}}@media (min-width:40rem){.clcosdk\\:sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (min-width:48rem){.clcosdk\\:md\\:right-\\[-10\\%\\]{right:-10%}.clcosdk\\:md\\:order-1{order:1}.clcosdk\\:md\\:order-2{order:2}.clcosdk\\:md\\:hidden{display:none}.clcosdk\\:md\\:size-\\[20rem\\]{width:20rem;height:20rem}.clcosdk\\:md\\:h-9{height:calc(var(--clcosdk-spacing) * 9)}.clcosdk\\:md\\:h-12{height:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:md\\:h-\\[54px\\]{height:54px}.clcosdk\\:md\\:w-9{width:calc(var(--clcosdk-spacing) * 9)}.clcosdk\\:md\\:w-12{width:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:md\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.clcosdk\\:md\\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.clcosdk\\:md\\:grid-cols-\\[minmax\\(0\\,11fr\\)_minmax\\(0\\,8fr\\)\\]{grid-template-columns:minmax(0,11fr) minmax(0,8fr)}.clcosdk\\:md\\:flex-row{flex-direction:row}.clcosdk\\:md\\:items-center{align-items:center}.clcosdk\\:md\\:items-end{align-items:flex-end}.clcosdk\\:md\\:justify-between{justify-content:space-between}.clcosdk\\:md\\:justify-end{justify-content:flex-end}.clcosdk\\:md\\:gap-3{gap:calc(var(--clcosdk-spacing) * 3)}.clcosdk\\:md\\:gap-6{gap:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:md\\:gap-x-12{column-gap:calc(var(--clcosdk-spacing) * 12)}.clcosdk\\:md\\:self-end{align-self:flex-end}.clcosdk\\:md\\:rounded-\\[40px\\]{border-radius:40px}.clcosdk\\:md\\:rounded-card{border-radius:24px}.clcosdk\\:md\\:rounded-dialog{border-radius:32px}.clcosdk\\:md\\:p-4{padding:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:md\\:p-6{padding:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:md\\:p-8{padding:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:md\\:px-6{padding-inline:calc(var(--clcosdk-spacing) * 6)}.clcosdk\\:md\\:px-8{padding-inline:calc(var(--clcosdk-spacing) * 8)}.clcosdk\\:md\\:py-2{padding-block:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:md\\:pr-2{padding-right:calc(var(--clcosdk-spacing) * 2)}.clcosdk\\:md\\:pr-4{padding-right:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:md\\:pl-4{padding-left:calc(var(--clcosdk-spacing) * 4)}.clcosdk\\:md\\:text-base{font-size:var(--clcosdk-text-base);line-height:var(--tw-leading,var(--clcosdk-text-base--line-height))}.clcosdk\\:md\\:text-\\[14px\\]{font-size:14px}.clcosdk\\:md\\:text-\\[16px\\]{font-size:16px}.clcosdk\\:md\\:text-\\[18px\\]{font-size:18px}.clcosdk\\:md\\:text-\\[28px\\]{font-size:28px}.clcosdk\\:md\\:leading-\\[120\\%\\]{--tw-leading:120%;line-height:120%}.clcosdk\\:md\\:leading-\\[160\\%\\]{--tw-leading:160%;line-height:160%}}@media (prefers-color-scheme:dark){@media (hover:hover){.clcosdk\\:dark\\:hover\\:bg-\\[rgba\\(248\\,113\\,113\\,0\\.20\\)\\]:not(:where(.light,.light *)):hover{background-color:#f8717133}}}@media (hover:hover){.clcosdk\\:dark\\:hover\\:bg-\\[rgba\\(248\\,113\\,113\\,0\\.20\\)\\]:where(.dark,.dark *):hover{background-color:#f8717133}}@media (prefers-color-scheme:dark){@media (hover:hover){.clcosdk\\:dark\\:hover\\:text-\\[\\#fca5a5\\]:not(:where(.light,.light *)):hover{color:#fca5a5}}}@media (hover:hover){.clcosdk\\:dark\\:hover\\:text-\\[\\#fca5a5\\]:where(.dark,.dark *):hover{color:#fca5a5}}@media (prefers-color-scheme:dark){.clcosdk\\:dark\\:active\\:bg-\\[rgba\\(248\\,113\\,113\\,0\\.30\\)\\]:not(:where(.light,.light *)):active{background-color:#f871714d}}.clcosdk\\:dark\\:active\\:bg-\\[rgba\\(248\\,113\\,113\\,0\\.30\\)\\]:where(.dark,.dark *):active{background-color:#f871714d}@media (prefers-color-scheme:dark){.clcosdk\\:dark\\:active\\:bg-divider:not(:where(.light,.light *)):active{background-color:var(--color-divider)}}.clcosdk\\:dark\\:active\\:bg-divider:where(.dark,.dark *):active{background-color:var(--color-divider)}@media (prefers-color-scheme:dark){.clcosdk\\:dark\\:active\\:text-\\[\\#f87171\\]:not(:where(.light,.light *)):active{color:#f87171}}.clcosdk\\:dark\\:active\\:text-\\[\\#f87171\\]:where(.dark,.dark *):active{color:#f87171}.clcosdk\\:\\[\\&_circle\\]\\:fill-error-subtle circle{fill:var(--color-error-subtle)}.clcosdk\\:\\[\\&_circle\\]\\:fill-success-subtle circle{fill:var(--color-success-subtle)}.clcosdk\\:\\[\\&_circle\\]\\:fill-warning-subtle circle{fill:var(--color-warning-subtle)}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-divide-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@keyframes spin{to{transform:rotate(360deg)}}@keyframes pulse{50%{opacity:.5}}';
|
|
1797
1803
|
|
|
1798
1804
|
// src/client/CoinListStyleScope.tsx
|
|
1799
1805
|
import { Fragment, jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
@@ -5282,7 +5288,7 @@ function loadErrorReason(error) {
|
|
|
5282
5288
|
}
|
|
5283
5289
|
}
|
|
5284
5290
|
|
|
5285
|
-
// src/universal/core/providers/
|
|
5291
|
+
// src/universal/core/providers/centrifuge/constants.ts
|
|
5286
5292
|
var CENTRIFUGE_POLL_INTERVAL_MS = 15e3;
|
|
5287
5293
|
|
|
5288
5294
|
// src/client/hooks/providers/base/centrifuge/useCentrifugeVaultStatuses.ts
|
|
@@ -6623,7 +6629,7 @@ function useCheckoutWalletSelectViewModel({
|
|
|
6623
6629
|
return { state: uiState(), onEvent };
|
|
6624
6630
|
}
|
|
6625
6631
|
|
|
6626
|
-
// src/universal/core/providers/
|
|
6632
|
+
// src/universal/core/providers/centrifuge/symbol.ts
|
|
6627
6633
|
function centrifugeShareSymbol(offer) {
|
|
6628
6634
|
return AssetSymbol(offer.asset.code);
|
|
6629
6635
|
}
|
|
@@ -6805,7 +6811,7 @@ function CentrifugeBuyCheckoutContainer({
|
|
|
6805
6811
|
// src/client/components/providers/checkout/coin-list/token-sale/placed/TokenSaleOrderPlaced.tsx
|
|
6806
6812
|
import { Fragment as Fragment8, jsx as jsx58, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
6807
6813
|
var TITLE6 = "Order placed";
|
|
6808
|
-
var SUBTITLE2 = "Your
|
|
6814
|
+
var SUBTITLE2 = "Your order is recorded, and the sale will hold your payment until it settles. Then your tokens are allocated, and anything not allocated is refunded.";
|
|
6809
6815
|
var COMMITTED_LABEL = "Amount committed";
|
|
6810
6816
|
var ESTIMATED_TOKENS_LABEL = "Estimated tokens";
|
|
6811
6817
|
var WALLET_LABEL2 = "Wallet";
|
|
@@ -6856,9 +6862,9 @@ var TITLE7 = "Review and confirm";
|
|
|
6856
6862
|
var YOU_RECEIVE_LABEL = "You receive (estimated)";
|
|
6857
6863
|
var PRICE_PER_TOKEN_LABEL = "Price per token";
|
|
6858
6864
|
var RECEIVING_WALLET_LABEL2 = "Receiving wallet";
|
|
6859
|
-
var RECEIVING_WALLET_TOOLTIP = "This wallet
|
|
6865
|
+
var RECEIVING_WALLET_TOOLTIP = "This wallet pays for the order and receives the tokens when the sale settles.";
|
|
6860
6866
|
var SALE_AGREEMENT_LABEL = "the Sale Agreement";
|
|
6861
|
-
var DISCLAIMER_PREAMBLE2 = "
|
|
6867
|
+
var DISCLAIMER_PREAMBLE2 = "The sale holds your payment until it settles, then allocates your tokens and refunds anything not allocated.";
|
|
6862
6868
|
function TokenSaleReviewView(props) {
|
|
6863
6869
|
return /* @__PURE__ */ jsx59(CoinListStyleScope, { children: /* @__PURE__ */ jsx59(TokenSaleReviewViewBody, { ...props }) });
|
|
6864
6870
|
}
|
|
@@ -9080,7 +9086,7 @@ function toMarketUi(state) {
|
|
|
9080
9086
|
}
|
|
9081
9087
|
}
|
|
9082
9088
|
|
|
9083
|
-
// src/universal/core/providers/
|
|
9089
|
+
// src/universal/core/providers/ondo/symbol.ts
|
|
9084
9090
|
function ondoSymbolOf(offer) {
|
|
9085
9091
|
return AssetSymbol(offer.asset.code);
|
|
9086
9092
|
}
|
|
@@ -11808,15 +11814,16 @@ function renderSide(side, branches) {
|
|
|
11808
11814
|
}
|
|
11809
11815
|
}
|
|
11810
11816
|
|
|
11811
|
-
// src/client/components/providers/claim/centrifuge/vault/CentrifugeVaultClaimView.tsx
|
|
11812
|
-
import { LoaderCircle as LoaderCircle2 } from "lucide-react";
|
|
11813
|
-
|
|
11814
11817
|
// src/client/components/providers/claim/centrifuge/vault/CentrifugeVaultClaimDialog.tsx
|
|
11815
11818
|
import { Circle, LoaderCircle } from "lucide-react";
|
|
11816
11819
|
|
|
11817
11820
|
// src/client/components/design-system/StepStatusIcon.tsx
|
|
11818
|
-
import { CircleCheck as CircleCheck2, CircleX, Info as Info3 } from "lucide-react";
|
|
11821
|
+
import { CircleCheck as CircleCheck2, CircleDashed, CircleX, Info as Info3 } from "lucide-react";
|
|
11819
11822
|
import { jsx as jsx87 } from "react/jsx-runtime";
|
|
11823
|
+
var sizeClass = {
|
|
11824
|
+
md: "clcosdk:h-6 clcosdk:w-6",
|
|
11825
|
+
sm: "clcosdk:h-3.5 clcosdk:w-3.5"
|
|
11826
|
+
};
|
|
11820
11827
|
var statusConfig = {
|
|
11821
11828
|
required: {
|
|
11822
11829
|
Icon: Info3,
|
|
@@ -11828,6 +11835,11 @@ var statusConfig = {
|
|
|
11828
11835
|
colorClass: "clcosdk:text-warning",
|
|
11829
11836
|
fillClass: "clcosdk:[&_circle]:fill-warning-subtle"
|
|
11830
11837
|
},
|
|
11838
|
+
"in-progress": {
|
|
11839
|
+
Icon: CircleDashed,
|
|
11840
|
+
colorClass: "clcosdk:text-warning",
|
|
11841
|
+
fillClass: "clcosdk:[&_circle]:fill-warning-subtle"
|
|
11842
|
+
},
|
|
11831
11843
|
completed: {
|
|
11832
11844
|
Icon: CircleCheck2,
|
|
11833
11845
|
colorClass: "clcosdk:text-success",
|
|
@@ -11839,13 +11851,18 @@ var statusConfig = {
|
|
|
11839
11851
|
fillClass: "clcosdk:[&_circle]:fill-error-subtle"
|
|
11840
11852
|
}
|
|
11841
11853
|
};
|
|
11842
|
-
function StepStatusIcon({
|
|
11854
|
+
function StepStatusIcon({
|
|
11855
|
+
status,
|
|
11856
|
+
size = "md",
|
|
11857
|
+
className
|
|
11858
|
+
}) {
|
|
11843
11859
|
const { Icon, colorClass, fillClass } = statusConfig[status];
|
|
11844
11860
|
return /* @__PURE__ */ jsx87(
|
|
11845
11861
|
Icon,
|
|
11846
11862
|
{
|
|
11847
11863
|
className: cn(
|
|
11848
|
-
|
|
11864
|
+
sizeClass[size],
|
|
11865
|
+
"clcosdk:shrink-0",
|
|
11849
11866
|
colorClass,
|
|
11850
11867
|
fillClass,
|
|
11851
11868
|
className
|
|
@@ -12025,8 +12042,50 @@ function SuccessLine() {
|
|
|
12025
12042
|
] });
|
|
12026
12043
|
}
|
|
12027
12044
|
|
|
12028
|
-
// src/client/components/providers/claim/
|
|
12045
|
+
// src/client/components/providers/claim/shared/ClaimRowLayout.tsx
|
|
12029
12046
|
import { jsx as jsx89, jsxs as jsxs58 } from "react/jsx-runtime";
|
|
12047
|
+
function ClaimRowLayout({
|
|
12048
|
+
icon,
|
|
12049
|
+
title,
|
|
12050
|
+
aside,
|
|
12051
|
+
meta,
|
|
12052
|
+
trailing
|
|
12053
|
+
}) {
|
|
12054
|
+
return /* @__PURE__ */ jsx89(CoinListStyleScope, { children: /* @__PURE__ */ jsxs58("div", { className: "clcosdk:flex clcosdk:items-center clcosdk:justify-between clcosdk:gap-3", children: [
|
|
12055
|
+
/* @__PURE__ */ jsxs58("div", { className: "clcosdk:flex clcosdk:min-w-0 clcosdk:flex-1 clcosdk:items-center clcosdk:gap-3", children: [
|
|
12056
|
+
icon,
|
|
12057
|
+
/* @__PURE__ */ jsxs58("div", { className: "clcosdk:flex clcosdk:min-w-0 clcosdk:flex-1 clcosdk:flex-col", children: [
|
|
12058
|
+
/* @__PURE__ */ jsxs58("div", { className: "clcosdk:flex clcosdk:min-w-0 clcosdk:items-center clcosdk:justify-between clcosdk:gap-2", children: [
|
|
12059
|
+
/* @__PURE__ */ jsx89(
|
|
12060
|
+
"span",
|
|
12061
|
+
{
|
|
12062
|
+
className: cn(
|
|
12063
|
+
typeClasses.body,
|
|
12064
|
+
"clcosdk:max-w-full clcosdk:shrink-0 clcosdk:text-text-primary clcosdk:truncate"
|
|
12065
|
+
),
|
|
12066
|
+
children: title
|
|
12067
|
+
}
|
|
12068
|
+
),
|
|
12069
|
+
aside !== void 0 && /* @__PURE__ */ jsx89("div", { className: "clcosdk:flex clcosdk:min-w-0 clcosdk:justify-end", children: aside })
|
|
12070
|
+
] }),
|
|
12071
|
+
/* @__PURE__ */ jsx89(
|
|
12072
|
+
"div",
|
|
12073
|
+
{
|
|
12074
|
+
className: cn(
|
|
12075
|
+
typeClasses.subhead,
|
|
12076
|
+
"clcosdk:min-w-0 clcosdk:text-text-secondary"
|
|
12077
|
+
),
|
|
12078
|
+
children: meta
|
|
12079
|
+
}
|
|
12080
|
+
)
|
|
12081
|
+
] })
|
|
12082
|
+
] }),
|
|
12083
|
+
trailing !== void 0 && /* @__PURE__ */ jsx89("div", { className: "clcosdk:flex clcosdk:min-w-0 clcosdk:shrink-0 clcosdk:max-w-[50%] clcosdk:justify-end", children: trailing })
|
|
12084
|
+
] }) });
|
|
12085
|
+
}
|
|
12086
|
+
|
|
12087
|
+
// src/client/components/providers/claim/centrifuge/vault/CentrifugeVaultClaimRow.tsx
|
|
12088
|
+
import { jsx as jsx90, jsxs as jsxs59 } from "react/jsx-runtime";
|
|
12030
12089
|
var PENDING_LABEL = "Pending";
|
|
12031
12090
|
var CLAIM_LABEL = "Claim";
|
|
12032
12091
|
var BLOCKED_COPY = {
|
|
@@ -12036,20 +12095,20 @@ function CentrifugeVaultClaimRow({
|
|
|
12036
12095
|
row,
|
|
12037
12096
|
onClaim
|
|
12038
12097
|
}) {
|
|
12039
|
-
return /* @__PURE__ */
|
|
12098
|
+
return /* @__PURE__ */ jsx90(CoinListStyleScope, { children: /* @__PURE__ */ jsx90(RowBody, { row, onClaim }) });
|
|
12040
12099
|
}
|
|
12041
12100
|
function RowBody({ row, onClaim }) {
|
|
12042
|
-
const icon = /* @__PURE__ */
|
|
12101
|
+
const icon = /* @__PURE__ */ jsx90(AssetIcon, { asset: { name: row.amount, iconUrl: row.iconUrl }, size: 40 });
|
|
12043
12102
|
switch (row.kind) {
|
|
12044
12103
|
case "pending":
|
|
12045
|
-
return /* @__PURE__ */
|
|
12046
|
-
|
|
12104
|
+
return /* @__PURE__ */ jsx90(
|
|
12105
|
+
ClaimRowLayout,
|
|
12047
12106
|
{
|
|
12048
12107
|
icon,
|
|
12049
12108
|
title: row.title,
|
|
12050
|
-
meta: /* @__PURE__ */
|
|
12051
|
-
trailing: /* @__PURE__ */
|
|
12052
|
-
/* @__PURE__ */
|
|
12109
|
+
meta: /* @__PURE__ */ jsx90(MetaRow, { children: PENDING_LABEL }),
|
|
12110
|
+
trailing: /* @__PURE__ */ jsxs59("div", { className: "clcosdk:flex clcosdk:min-w-0 clcosdk:flex-col clcosdk:items-end", children: [
|
|
12111
|
+
/* @__PURE__ */ jsx90(
|
|
12053
12112
|
"span",
|
|
12054
12113
|
{
|
|
12055
12114
|
className: cn(
|
|
@@ -12059,7 +12118,7 @@ function RowBody({ row, onClaim }) {
|
|
|
12059
12118
|
children: row.amount
|
|
12060
12119
|
}
|
|
12061
12120
|
),
|
|
12062
|
-
/* @__PURE__ */
|
|
12121
|
+
/* @__PURE__ */ jsx90(
|
|
12063
12122
|
"span",
|
|
12064
12123
|
{
|
|
12065
12124
|
className: cn(
|
|
@@ -12073,14 +12132,14 @@ function RowBody({ row, onClaim }) {
|
|
|
12073
12132
|
}
|
|
12074
12133
|
);
|
|
12075
12134
|
case "claimable":
|
|
12076
|
-
return /* @__PURE__ */
|
|
12077
|
-
/* @__PURE__ */
|
|
12078
|
-
|
|
12135
|
+
return /* @__PURE__ */ jsxs59("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-2", children: [
|
|
12136
|
+
/* @__PURE__ */ jsx90(
|
|
12137
|
+
ClaimRowLayout,
|
|
12079
12138
|
{
|
|
12080
12139
|
icon,
|
|
12081
12140
|
title: row.amount,
|
|
12082
|
-
meta: /* @__PURE__ */
|
|
12083
|
-
trailing: /* @__PURE__ */
|
|
12141
|
+
meta: /* @__PURE__ */ jsx90(MetaRow, { children: row.wallet }),
|
|
12142
|
+
trailing: /* @__PURE__ */ jsx90(
|
|
12084
12143
|
ClButton,
|
|
12085
12144
|
{
|
|
12086
12145
|
variant: "primary",
|
|
@@ -12094,7 +12153,7 @@ function RowBody({ row, onClaim }) {
|
|
|
12094
12153
|
)
|
|
12095
12154
|
}
|
|
12096
12155
|
),
|
|
12097
|
-
row.action.type === "blocked" && /* @__PURE__ */
|
|
12156
|
+
row.action.type === "blocked" && /* @__PURE__ */ jsx90(
|
|
12098
12157
|
"p",
|
|
12099
12158
|
{
|
|
12100
12159
|
className: cn(typeClasses.subhead, "clcosdk:text-text-secondary"),
|
|
@@ -12108,49 +12167,73 @@ function RowBody({ row, onClaim }) {
|
|
|
12108
12167
|
}
|
|
12109
12168
|
}
|
|
12110
12169
|
}
|
|
12111
|
-
|
|
12112
|
-
|
|
12113
|
-
|
|
12114
|
-
|
|
12115
|
-
|
|
12170
|
+
|
|
12171
|
+
// src/client/components/providers/claim/shared/ClaimCard.tsx
|
|
12172
|
+
import { Fragment as Fragment13, jsx as jsx91, jsxs as jsxs60 } from "react/jsx-runtime";
|
|
12173
|
+
var TITLE20 = "Your orders";
|
|
12174
|
+
function ClaimCard({
|
|
12175
|
+
body,
|
|
12176
|
+
footer,
|
|
12177
|
+
className,
|
|
12178
|
+
children
|
|
12116
12179
|
}) {
|
|
12117
|
-
return /* @__PURE__ */
|
|
12118
|
-
/* @__PURE__ */
|
|
12119
|
-
|
|
12120
|
-
|
|
12121
|
-
|
|
12122
|
-
|
|
12180
|
+
return /* @__PURE__ */ jsx91(CoinListStyleScope, { children: /* @__PURE__ */ jsxs60(Card, { gap: "md", className, children: [
|
|
12181
|
+
/* @__PURE__ */ jsx91("h3", { className: cn(typeClasses.h4, "clcosdk:text-text-primary"), children: TITLE20 }),
|
|
12182
|
+
/* @__PURE__ */ jsx91(Divider, {}),
|
|
12183
|
+
body,
|
|
12184
|
+
footer !== void 0 && /* @__PURE__ */ jsxs60(Fragment13, { children: [
|
|
12185
|
+
/* @__PURE__ */ jsx91(Divider, {}),
|
|
12186
|
+
footer
|
|
12187
|
+
] }),
|
|
12188
|
+
children
|
|
12189
|
+
] }) });
|
|
12190
|
+
}
|
|
12191
|
+
|
|
12192
|
+
// src/client/components/providers/claim/shared/ClaimLoadError.tsx
|
|
12193
|
+
import { jsx as jsx92, jsxs as jsxs61 } from "react/jsx-runtime";
|
|
12194
|
+
var LOAD_FAILED = "We could not load your orders.";
|
|
12195
|
+
var RETRY_LABEL4 = "Try again";
|
|
12196
|
+
function ClaimLoadError({ onRetry }) {
|
|
12197
|
+
return /* @__PURE__ */ jsx92(CoinListStyleScope, { children: /* @__PURE__ */ jsxs61("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:items-start clcosdk:gap-3", children: [
|
|
12198
|
+
/* @__PURE__ */ jsx92(
|
|
12199
|
+
AlertBanner,
|
|
12200
|
+
{
|
|
12201
|
+
variant: "error",
|
|
12202
|
+
content: LOAD_FAILED,
|
|
12203
|
+
className: "clcosdk:w-full"
|
|
12204
|
+
}
|
|
12205
|
+
),
|
|
12206
|
+
/* @__PURE__ */ jsx92(ClButton, { variant: "secondary", size: "sm", onClick: onRetry, children: RETRY_LABEL4 })
|
|
12207
|
+
] }) });
|
|
12208
|
+
}
|
|
12209
|
+
|
|
12210
|
+
// src/client/components/providers/claim/shared/ClaimLoading.tsx
|
|
12211
|
+
import { LoaderCircle as LoaderCircle2 } from "lucide-react";
|
|
12212
|
+
import { jsx as jsx93, jsxs as jsxs62 } from "react/jsx-runtime";
|
|
12213
|
+
var LOADING_LABEL2 = "Loading orders";
|
|
12214
|
+
function ClaimLoading() {
|
|
12215
|
+
return /* @__PURE__ */ jsx93(CoinListStyleScope, { children: /* @__PURE__ */ jsxs62(
|
|
12216
|
+
"div",
|
|
12217
|
+
{
|
|
12218
|
+
className: "clcosdk:flex clcosdk:items-center clcosdk:gap-2",
|
|
12219
|
+
role: "status",
|
|
12220
|
+
children: [
|
|
12221
|
+
/* @__PURE__ */ jsx93(
|
|
12222
|
+
LoaderCircle2,
|
|
12123
12223
|
{
|
|
12124
|
-
className:
|
|
12125
|
-
|
|
12126
|
-
"clcosdk:text-text-primary clcosdk:truncate"
|
|
12127
|
-
),
|
|
12128
|
-
children: title
|
|
12224
|
+
className: "clcosdk:size-5 clcosdk:shrink-0 clcosdk:animate-spin clcosdk:text-text-secondary",
|
|
12225
|
+
"aria-hidden": "true"
|
|
12129
12226
|
}
|
|
12130
12227
|
),
|
|
12131
|
-
/* @__PURE__ */
|
|
12132
|
-
|
|
12133
|
-
|
|
12134
|
-
|
|
12135
|
-
typeClasses.subhead,
|
|
12136
|
-
"clcosdk:min-w-0 clcosdk:text-text-secondary"
|
|
12137
|
-
),
|
|
12138
|
-
children: meta
|
|
12139
|
-
}
|
|
12140
|
-
)
|
|
12141
|
-
] })
|
|
12142
|
-
] }),
|
|
12143
|
-
/* @__PURE__ */ jsx89("div", { className: "clcosdk:flex clcosdk:min-w-0 clcosdk:shrink-0 clcosdk:max-w-[50%] clcosdk:justify-end", children: trailing })
|
|
12144
|
-
] });
|
|
12228
|
+
/* @__PURE__ */ jsx93("span", { className: cn(typeClasses.bodySm, "clcosdk:text-text-secondary"), children: LOADING_LABEL2 })
|
|
12229
|
+
]
|
|
12230
|
+
}
|
|
12231
|
+
) });
|
|
12145
12232
|
}
|
|
12146
12233
|
|
|
12147
12234
|
// src/client/components/providers/claim/centrifuge/vault/CentrifugeVaultClaimView.tsx
|
|
12148
|
-
import {
|
|
12149
|
-
var TITLE20 = "Your orders";
|
|
12150
|
-
var LOADING_LABEL2 = "Loading orders";
|
|
12235
|
+
import { jsx as jsx94, jsxs as jsxs63 } from "react/jsx-runtime";
|
|
12151
12236
|
var NO_ORDERS = "No orders for this asset in your connected wallets.";
|
|
12152
|
-
var LOAD_FAILED = "We could not load your orders.";
|
|
12153
|
-
var RETRY_LABEL4 = "Try again";
|
|
12154
12237
|
var CONNECT_PROMPT = "Connect the external wallet you used to invest to check your orders.";
|
|
12155
12238
|
var CONNECT_LABEL = "Connect wallet";
|
|
12156
12239
|
var CHANGE_LABEL = "Change wallet";
|
|
@@ -12161,127 +12244,67 @@ function CentrifugeVaultClaimView({
|
|
|
12161
12244
|
onEvent,
|
|
12162
12245
|
className
|
|
12163
12246
|
}) {
|
|
12164
|
-
|
|
12165
|
-
|
|
12166
|
-
|
|
12167
|
-
|
|
12168
|
-
|
|
12169
|
-
|
|
12247
|
+
if (state.type === "HIDDEN") return null;
|
|
12248
|
+
return /* @__PURE__ */ jsx94(CoinListStyleScope, { children: /* @__PURE__ */ jsx94(
|
|
12249
|
+
ClaimCard,
|
|
12250
|
+
{
|
|
12251
|
+
className,
|
|
12252
|
+
body: bodyOf(state, onEvent),
|
|
12253
|
+
footer: footerOf(state.externalWallet, onEvent),
|
|
12254
|
+
children: state.type === "CONTENT" && /* @__PURE__ */ jsx94(
|
|
12255
|
+
CentrifugeVaultClaimDialog,
|
|
12170
12256
|
{
|
|
12171
|
-
|
|
12172
|
-
|
|
12173
|
-
onEvent
|
|
12174
|
-
body: /* @__PURE__ */ jsx90(LoadingSpinner, {})
|
|
12257
|
+
dialog: state.dialog,
|
|
12258
|
+
onRetry: () => onEvent({ type: "ON_RETRY_CLAIM" }),
|
|
12259
|
+
onClose: () => onEvent({ type: "ON_CLOSE_CLAIM_DIALOG" })
|
|
12175
12260
|
}
|
|
12176
|
-
)
|
|
12261
|
+
)
|
|
12262
|
+
}
|
|
12263
|
+
) });
|
|
12264
|
+
}
|
|
12265
|
+
function bodyOf(state, onEvent) {
|
|
12266
|
+
switch (state.type) {
|
|
12267
|
+
case "LOADING":
|
|
12268
|
+
return /* @__PURE__ */ jsx94(ClaimLoading, {});
|
|
12177
12269
|
case "ERROR":
|
|
12178
|
-
return /* @__PURE__ */
|
|
12179
|
-
Shell,
|
|
12180
|
-
{
|
|
12181
|
-
className,
|
|
12182
|
-
externalWallet: state.externalWallet,
|
|
12183
|
-
onEvent,
|
|
12184
|
-
body: /* @__PURE__ */ jsxs59("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:items-start clcosdk:gap-3", children: [
|
|
12185
|
-
/* @__PURE__ */ jsx90(
|
|
12186
|
-
AlertBanner,
|
|
12187
|
-
{
|
|
12188
|
-
variant: "error",
|
|
12189
|
-
content: LOAD_FAILED,
|
|
12190
|
-
className: "clcosdk:w-full"
|
|
12191
|
-
}
|
|
12192
|
-
),
|
|
12193
|
-
/* @__PURE__ */ jsx90(
|
|
12194
|
-
ClButton,
|
|
12195
|
-
{
|
|
12196
|
-
variant: "secondary",
|
|
12197
|
-
size: "sm",
|
|
12198
|
-
onClick: () => onEvent({ type: "ON_RETRY_LOAD" }),
|
|
12199
|
-
children: RETRY_LABEL4
|
|
12200
|
-
}
|
|
12201
|
-
)
|
|
12202
|
-
] })
|
|
12203
|
-
}
|
|
12204
|
-
);
|
|
12270
|
+
return /* @__PURE__ */ jsx94(ClaimLoadError, { onRetry: () => onEvent({ type: "ON_RETRY_LOAD" }) });
|
|
12205
12271
|
case "CONTENT":
|
|
12206
|
-
return /* @__PURE__ */
|
|
12207
|
-
|
|
12272
|
+
return state.rows.length === 0 ? /* @__PURE__ */ jsx94("p", { className: cn(typeClasses.bodySm, "clcosdk:text-text-secondary"), children: NO_ORDERS }) : /* @__PURE__ */ jsx94("ul", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-4", children: state.rows.map((row) => /* @__PURE__ */ jsx94("li", { children: /* @__PURE__ */ jsx94(
|
|
12273
|
+
CentrifugeVaultClaimRow,
|
|
12208
12274
|
{
|
|
12209
|
-
|
|
12210
|
-
|
|
12211
|
-
|
|
12212
|
-
|
|
12213
|
-
"p",
|
|
12214
|
-
{
|
|
12215
|
-
className: cn(
|
|
12216
|
-
typeClasses.bodySm,
|
|
12217
|
-
"clcosdk:text-text-secondary"
|
|
12218
|
-
),
|
|
12219
|
-
children: NO_ORDERS
|
|
12220
|
-
}
|
|
12221
|
-
) : /* @__PURE__ */ jsx90("ul", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-4", children: state.rows.map((row) => /* @__PURE__ */ jsx90("li", { children: /* @__PURE__ */ jsx90(
|
|
12222
|
-
CentrifugeVaultClaimRow,
|
|
12223
|
-
{
|
|
12224
|
-
row,
|
|
12225
|
-
onClaim: () => {
|
|
12226
|
-
if (row.kind === "claimable") {
|
|
12227
|
-
onEvent({ type: "ON_CLAIM", legId: row.legId });
|
|
12228
|
-
}
|
|
12229
|
-
}
|
|
12230
|
-
}
|
|
12231
|
-
) }, row.key)) }),
|
|
12232
|
-
children: /* @__PURE__ */ jsx90(
|
|
12233
|
-
CentrifugeVaultClaimDialog,
|
|
12234
|
-
{
|
|
12235
|
-
dialog: state.dialog,
|
|
12236
|
-
onRetry: () => onEvent({ type: "ON_RETRY_CLAIM" }),
|
|
12237
|
-
onClose: () => onEvent({ type: "ON_CLOSE_CLAIM_DIALOG" })
|
|
12275
|
+
row,
|
|
12276
|
+
onClaim: () => {
|
|
12277
|
+
if (row.kind === "claimable") {
|
|
12278
|
+
onEvent({ type: "ON_CLAIM", legId: row.legId });
|
|
12238
12279
|
}
|
|
12239
|
-
|
|
12280
|
+
}
|
|
12240
12281
|
}
|
|
12241
|
-
);
|
|
12282
|
+
) }, row.key)) });
|
|
12242
12283
|
default: {
|
|
12243
12284
|
const exhaustive = state;
|
|
12244
12285
|
return exhaustive;
|
|
12245
12286
|
}
|
|
12246
12287
|
}
|
|
12247
12288
|
}
|
|
12248
|
-
function
|
|
12249
|
-
|
|
12250
|
-
externalWallet,
|
|
12251
|
-
onEvent,
|
|
12252
|
-
className,
|
|
12253
|
-
children
|
|
12254
|
-
}) {
|
|
12255
|
-
const footer = externalWallet.type === "hidden" ? null : /* @__PURE__ */ jsx90(ExternalWalletFooter, { externalWallet, onEvent });
|
|
12256
|
-
return /* @__PURE__ */ jsx90(CoinListStyleScope, { children: /* @__PURE__ */ jsxs59(Card, { gap: "md", className, children: [
|
|
12257
|
-
/* @__PURE__ */ jsx90("h3", { className: cn(typeClasses.h4, "clcosdk:text-text-primary"), children: TITLE20 }),
|
|
12258
|
-
body !== null && /* @__PURE__ */ jsxs59(Fragment13, { children: [
|
|
12259
|
-
/* @__PURE__ */ jsx90(Divider, {}),
|
|
12260
|
-
body
|
|
12261
|
-
] }),
|
|
12262
|
-
footer !== null && /* @__PURE__ */ jsxs59(Fragment13, { children: [
|
|
12263
|
-
/* @__PURE__ */ jsx90(Divider, {}),
|
|
12264
|
-
footer
|
|
12265
|
-
] }),
|
|
12266
|
-
children
|
|
12267
|
-
] }) });
|
|
12289
|
+
function footerOf(externalWallet, onEvent) {
|
|
12290
|
+
return externalWallet.type === "hidden" ? void 0 : /* @__PURE__ */ jsx94(ExternalWalletFooter, { externalWallet, onEvent });
|
|
12268
12291
|
}
|
|
12269
12292
|
function ExternalWalletFooter({
|
|
12270
12293
|
externalWallet,
|
|
12271
12294
|
onEvent
|
|
12272
12295
|
}) {
|
|
12273
12296
|
const pending = externalWallet.request === "pending";
|
|
12274
|
-
return /* @__PURE__ */
|
|
12275
|
-
externalWallet.type === "disconnected" && /* @__PURE__ */
|
|
12276
|
-
externalWallet.type === "connected" && /* @__PURE__ */
|
|
12297
|
+
return /* @__PURE__ */ jsxs63("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:items-start clcosdk:gap-3", children: [
|
|
12298
|
+
externalWallet.type === "disconnected" && /* @__PURE__ */ jsx94("p", { className: cn(typeClasses.bodySm, "clcosdk:text-text-secondary"), children: CONNECT_PROMPT }),
|
|
12299
|
+
externalWallet.type === "connected" && /* @__PURE__ */ jsx94(
|
|
12277
12300
|
AlertBanner,
|
|
12278
12301
|
{
|
|
12279
12302
|
variant: "info",
|
|
12280
|
-
content: /* @__PURE__ */
|
|
12303
|
+
content: /* @__PURE__ */ jsx94("span", { className: "clcosdk:break-all", children: connectedAs(externalWallet.wallet) }),
|
|
12281
12304
|
className: "clcosdk:w-full"
|
|
12282
12305
|
}
|
|
12283
12306
|
),
|
|
12284
|
-
externalWallet.type === "connected" ? /* @__PURE__ */
|
|
12307
|
+
externalWallet.type === "connected" ? /* @__PURE__ */ jsx94(
|
|
12285
12308
|
ClButton,
|
|
12286
12309
|
{
|
|
12287
12310
|
variant: "secondary",
|
|
@@ -12290,7 +12313,7 @@ function ExternalWalletFooter({
|
|
|
12290
12313
|
onClick: () => onEvent({ type: "ON_CHANGE_WALLET" }),
|
|
12291
12314
|
children: CHANGE_LABEL
|
|
12292
12315
|
}
|
|
12293
|
-
) : /* @__PURE__ */
|
|
12316
|
+
) : /* @__PURE__ */ jsx94(
|
|
12294
12317
|
ClButton,
|
|
12295
12318
|
{
|
|
12296
12319
|
variant: "outline",
|
|
@@ -12300,28 +12323,9 @@ function ExternalWalletFooter({
|
|
|
12300
12323
|
children: CONNECT_LABEL
|
|
12301
12324
|
}
|
|
12302
12325
|
),
|
|
12303
|
-
externalWallet.request === "failed" && /* @__PURE__ */
|
|
12326
|
+
externalWallet.request === "failed" && /* @__PURE__ */ jsx94("p", { className: cn(typeClasses.subhead, "clcosdk:text-error"), children: CONNECT_FAILED2 })
|
|
12304
12327
|
] });
|
|
12305
12328
|
}
|
|
12306
|
-
function LoadingSpinner() {
|
|
12307
|
-
return /* @__PURE__ */ jsxs59(
|
|
12308
|
-
"div",
|
|
12309
|
-
{
|
|
12310
|
-
className: "clcosdk:flex clcosdk:items-center clcosdk:gap-2",
|
|
12311
|
-
role: "status",
|
|
12312
|
-
children: [
|
|
12313
|
-
/* @__PURE__ */ jsx90(
|
|
12314
|
-
LoaderCircle2,
|
|
12315
|
-
{
|
|
12316
|
-
className: "clcosdk:size-5 clcosdk:shrink-0 clcosdk:animate-spin clcosdk:text-text-secondary",
|
|
12317
|
-
"aria-hidden": "true"
|
|
12318
|
-
}
|
|
12319
|
-
),
|
|
12320
|
-
/* @__PURE__ */ jsx90("span", { className: cn(typeClasses.bodySm, "clcosdk:text-text-secondary"), children: LOADING_LABEL2 })
|
|
12321
|
-
]
|
|
12322
|
-
}
|
|
12323
|
-
);
|
|
12324
|
-
}
|
|
12325
12329
|
|
|
12326
12330
|
// src/client/hooks/providers/claim/centrifuge/vault/useCentrifugeVaultClaimViewModel.ts
|
|
12327
12331
|
import { useEffect as useEffect19, useMemo as useMemo11, useState as useState30 } from "react";
|
|
@@ -12980,7 +12984,7 @@ function useCentrifugeVaults(offer, registry) {
|
|
|
12980
12984
|
}
|
|
12981
12985
|
|
|
12982
12986
|
// src/client/components/providers/claim/centrifuge/vault/CentrifugeVaultClaimContainer.tsx
|
|
12983
|
-
import { jsx as
|
|
12987
|
+
import { jsx as jsx95 } from "react/jsx-runtime";
|
|
12984
12988
|
function CentrifugeVaultClaimContainer({
|
|
12985
12989
|
offer,
|
|
12986
12990
|
wallets,
|
|
@@ -12996,7 +13000,7 @@ function CentrifugeVaultClaimContainer({
|
|
|
12996
13000
|
onClaimed,
|
|
12997
13001
|
enabled
|
|
12998
13002
|
});
|
|
12999
|
-
return /* @__PURE__ */
|
|
13003
|
+
return /* @__PURE__ */ jsx95(
|
|
13000
13004
|
CentrifugeVaultClaimView,
|
|
13001
13005
|
{
|
|
13002
13006
|
state,
|
|
@@ -13006,8 +13010,373 @@ function CentrifugeVaultClaimContainer({
|
|
|
13006
13010
|
);
|
|
13007
13011
|
}
|
|
13008
13012
|
|
|
13013
|
+
// src/client/components/providers/claim/coin-list/token-sale/ParticipationRow.tsx
|
|
13014
|
+
import { jsx as jsx96, jsxs as jsxs64 } from "react/jsx-runtime";
|
|
13015
|
+
var STATUS = {
|
|
13016
|
+
processing: { label: "Processing", icon: "in-progress" },
|
|
13017
|
+
committed: { label: "Committed", icon: "completed" },
|
|
13018
|
+
failed: { label: "Failed", icon: "rejected" },
|
|
13019
|
+
refunding: { label: "Refund in progress", icon: "in-progress" },
|
|
13020
|
+
refunded: { label: "Refund sent", icon: "completed" },
|
|
13021
|
+
"refund-failed": { label: "Refund failed", icon: "rejected" }
|
|
13022
|
+
};
|
|
13023
|
+
function ParticipationRow({ row }) {
|
|
13024
|
+
const status = STATUS[row.status];
|
|
13025
|
+
return /* @__PURE__ */ jsx96(CoinListStyleScope, { children: /* @__PURE__ */ jsx96(
|
|
13026
|
+
ClaimRowLayout,
|
|
13027
|
+
{
|
|
13028
|
+
icon: /* @__PURE__ */ jsx96(AssetIcon, { asset: row.asset, size: 32 }),
|
|
13029
|
+
title: /* @__PURE__ */ jsx96("span", { className: "clcosdk:font-medium", children: row.amount }),
|
|
13030
|
+
aside: /* @__PURE__ */ jsxs64("span", { className: "clcosdk:flex clcosdk:min-w-0 clcosdk:items-center clcosdk:gap-1", children: [
|
|
13031
|
+
/* @__PURE__ */ jsx96(StepStatusIcon, { status: status.icon, size: "sm" }),
|
|
13032
|
+
/* @__PURE__ */ jsx96(
|
|
13033
|
+
"span",
|
|
13034
|
+
{
|
|
13035
|
+
className: cn(
|
|
13036
|
+
typeClasses.caption,
|
|
13037
|
+
"clcosdk:text-text-secondary clcosdk:truncate"
|
|
13038
|
+
),
|
|
13039
|
+
children: status.label
|
|
13040
|
+
}
|
|
13041
|
+
)
|
|
13042
|
+
] }),
|
|
13043
|
+
meta: /* @__PURE__ */ jsx96("div", { className: typeClasses.caption, children: /* @__PURE__ */ jsxs64(MetaRow, { children: [
|
|
13044
|
+
row.placedAt !== null && /* @__PURE__ */ jsx96("span", { className: "clcosdk:shrink-0 clcosdk:whitespace-nowrap", children: row.placedAt }),
|
|
13045
|
+
row.wallet !== null && /* @__PURE__ */ jsx96("span", { className: "clcosdk:min-w-0 clcosdk:truncate", children: row.wallet })
|
|
13046
|
+
] }) })
|
|
13047
|
+
}
|
|
13048
|
+
) });
|
|
13049
|
+
}
|
|
13050
|
+
|
|
13051
|
+
// src/client/components/providers/claim/coin-list/token-sale/CoinListTokenSaleClaimView.tsx
|
|
13052
|
+
import { jsx as jsx97 } from "react/jsx-runtime";
|
|
13053
|
+
var NO_ORDERS2 = "Your orders in this sale will appear here.";
|
|
13054
|
+
function CoinListTokenSaleClaimView({
|
|
13055
|
+
state,
|
|
13056
|
+
onEvent,
|
|
13057
|
+
className
|
|
13058
|
+
}) {
|
|
13059
|
+
if (state.type === "HIDDEN") return null;
|
|
13060
|
+
return /* @__PURE__ */ jsx97(CoinListStyleScope, { children: /* @__PURE__ */ jsx97(ClaimCard, { className, body: bodyOf2(state, onEvent) }) });
|
|
13061
|
+
}
|
|
13062
|
+
function bodyOf2(state, onEvent) {
|
|
13063
|
+
switch (state.type) {
|
|
13064
|
+
case "LOADING":
|
|
13065
|
+
return /* @__PURE__ */ jsx97(ClaimLoading, {});
|
|
13066
|
+
case "ERROR":
|
|
13067
|
+
return /* @__PURE__ */ jsx97(ClaimLoadError, { onRetry: () => onEvent({ type: "ON_RETRY_LOAD" }) });
|
|
13068
|
+
case "CONTENT":
|
|
13069
|
+
return state.rows.length === 0 ? /* @__PURE__ */ jsx97("p", { className: cn(typeClasses.bodySm, "clcosdk:text-text-secondary"), children: NO_ORDERS2 }) : /* @__PURE__ */ jsx97("ul", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-4", children: state.rows.map((row) => /* @__PURE__ */ jsx97("li", { children: /* @__PURE__ */ jsx97(ParticipationRow, { row }) }, row.key)) });
|
|
13070
|
+
default: {
|
|
13071
|
+
const exhaustive = state;
|
|
13072
|
+
return exhaustive;
|
|
13073
|
+
}
|
|
13074
|
+
}
|
|
13075
|
+
}
|
|
13076
|
+
|
|
13077
|
+
// src/client/hooks/providers/base/coin-list/useCoinListTokenSaleParticipations.ts
|
|
13078
|
+
import { useCallback as useCallback10, useRef as useRef12, useState as useState31 } from "react";
|
|
13079
|
+
var DEFAULT_POLL_INTERVAL = Seconds.of(15);
|
|
13080
|
+
var LOADING9 = { type: "LOADING" };
|
|
13081
|
+
var DISABLED10 = {
|
|
13082
|
+
type: "DISABLED"
|
|
13083
|
+
};
|
|
13084
|
+
function useCoinListTokenSaleParticipations(offerId, options = {}) {
|
|
13085
|
+
const { coinlist, isReady } = useCoinList();
|
|
13086
|
+
const log = useLogger("useCoinListTokenSaleParticipations");
|
|
13087
|
+
const visible = usePageVisible();
|
|
13088
|
+
const {
|
|
13089
|
+
data,
|
|
13090
|
+
enabled = true,
|
|
13091
|
+
pollInterval = DEFAULT_POLL_INTERVAL
|
|
13092
|
+
} = options;
|
|
13093
|
+
const offerKey = offerId ?? "";
|
|
13094
|
+
const [read, setRead] = useState31(() => ({
|
|
13095
|
+
offerKey,
|
|
13096
|
+
state: data === void 0 ? LOADING9 : { type: "CONTENT", participations: data }
|
|
13097
|
+
}));
|
|
13098
|
+
const heldRef = useRef12(data === void 0 ? null : offerKey);
|
|
13099
|
+
const skipNextRef = useRef12(data !== void 0);
|
|
13100
|
+
const [refetchCount, setRefetchCount] = useState31(0);
|
|
13101
|
+
const refetch = useCallback10(() => {
|
|
13102
|
+
skipNextRef.current = false;
|
|
13103
|
+
setRefetchCount((count) => count + 1);
|
|
13104
|
+
}, []);
|
|
13105
|
+
usePoll({
|
|
13106
|
+
key: `${offerKey}:${refetchCount}`,
|
|
13107
|
+
enabled: isReady && enabled && visible,
|
|
13108
|
+
intervalMs: Seconds.toMillis(pollInterval),
|
|
13109
|
+
tick: async (isCurrent) => {
|
|
13110
|
+
if (skipNextRef.current) {
|
|
13111
|
+
skipNextRef.current = false;
|
|
13112
|
+
return;
|
|
13113
|
+
}
|
|
13114
|
+
try {
|
|
13115
|
+
const participations = await coinlist.tokenSale.list(offerId);
|
|
13116
|
+
if (!isCurrent()) return;
|
|
13117
|
+
log.debug(() => ({
|
|
13118
|
+
msg: "settled",
|
|
13119
|
+
fields: { state: "CONTENT", count: participations.length }
|
|
13120
|
+
}));
|
|
13121
|
+
heldRef.current = offerKey;
|
|
13122
|
+
setRead({ offerKey, state: { type: "CONTENT", participations } });
|
|
13123
|
+
} catch (error) {
|
|
13124
|
+
if (!isCurrent()) return;
|
|
13125
|
+
const reason = loadErrorReason(error);
|
|
13126
|
+
const policy = reason === "not-authenticated" ? "drop" : "keep";
|
|
13127
|
+
if (heldRef.current === offerKey && policy === "keep") {
|
|
13128
|
+
log.warning(
|
|
13129
|
+
() => ({
|
|
13130
|
+
msg: "poll failed; keeping the last list",
|
|
13131
|
+
fields: { reason }
|
|
13132
|
+
}),
|
|
13133
|
+
error
|
|
13134
|
+
);
|
|
13135
|
+
} else {
|
|
13136
|
+
heldRef.current = null;
|
|
13137
|
+
log.failure(
|
|
13138
|
+
() => ({ msg: "settled", fields: { state: "ERROR", reason } }),
|
|
13139
|
+
error
|
|
13140
|
+
);
|
|
13141
|
+
}
|
|
13142
|
+
setRead((previous) => ({
|
|
13143
|
+
offerKey,
|
|
13144
|
+
state: settleStale(
|
|
13145
|
+
previous.offerKey === offerKey ? previous.state : LOADING9,
|
|
13146
|
+
{ type: "ERROR", reason },
|
|
13147
|
+
policy
|
|
13148
|
+
)
|
|
13149
|
+
}));
|
|
13150
|
+
}
|
|
13151
|
+
}
|
|
13152
|
+
});
|
|
13153
|
+
const state = read.offerKey === offerKey ? read.state : LOADING9;
|
|
13154
|
+
return {
|
|
13155
|
+
participationsState: !enabled && state.type === "LOADING" ? DISABLED10 : state,
|
|
13156
|
+
refetch
|
|
13157
|
+
};
|
|
13158
|
+
}
|
|
13159
|
+
|
|
13160
|
+
// src/client/ui/format/date.ts
|
|
13161
|
+
function formatShortDateTime(date, {
|
|
13162
|
+
now,
|
|
13163
|
+
locale,
|
|
13164
|
+
timeZone
|
|
13165
|
+
}) {
|
|
13166
|
+
const sameYear = yearOf(date, locale, timeZone) === yearOf(new Date(now), locale, timeZone);
|
|
13167
|
+
return new Intl.DateTimeFormat(locale, {
|
|
13168
|
+
year: sameYear ? void 0 : "numeric",
|
|
13169
|
+
month: "short",
|
|
13170
|
+
day: "numeric",
|
|
13171
|
+
hour: "numeric",
|
|
13172
|
+
minute: "2-digit",
|
|
13173
|
+
timeZone
|
|
13174
|
+
}).format(date);
|
|
13175
|
+
}
|
|
13176
|
+
function yearOf(date, locale, timeZone) {
|
|
13177
|
+
return new Intl.DateTimeFormat(locale, { year: "numeric", timeZone }).formatToParts(date).filter((part) => part.type === "year").map((part) => part.value).join("");
|
|
13178
|
+
}
|
|
13179
|
+
|
|
13180
|
+
// src/client/hooks/providers/claim/coin-list/token-sale/useCoinListTokenSaleClaimViewModel.types.ts
|
|
13181
|
+
var ParticipationStatusUi = {
|
|
13182
|
+
/**
|
|
13183
|
+
* Folds the backend's eight steps into the six a user can act on. The
|
|
13184
|
+
* three before the payment is held - approval unverified, queued for a
|
|
13185
|
+
* commit batch, commit broadcast - are one wait to the user.
|
|
13186
|
+
*/
|
|
13187
|
+
fromDomain: (status) => {
|
|
13188
|
+
switch (status) {
|
|
13189
|
+
case "prepared":
|
|
13190
|
+
case "pending":
|
|
13191
|
+
case "submitted":
|
|
13192
|
+
return "processing";
|
|
13193
|
+
case "completed":
|
|
13194
|
+
return "committed";
|
|
13195
|
+
case "failed":
|
|
13196
|
+
return "failed";
|
|
13197
|
+
case "remit_submitted":
|
|
13198
|
+
return "refunding";
|
|
13199
|
+
case "remitted":
|
|
13200
|
+
return "refunded";
|
|
13201
|
+
case "remit_failed":
|
|
13202
|
+
return "refund-failed";
|
|
13203
|
+
default: {
|
|
13204
|
+
const exhaustive = status;
|
|
13205
|
+
return exhaustive;
|
|
13206
|
+
}
|
|
13207
|
+
}
|
|
13208
|
+
}
|
|
13209
|
+
};
|
|
13210
|
+
var ParticipationRowUi = {
|
|
13211
|
+
fromDomain: (participation, {
|
|
13212
|
+
walletLabel,
|
|
13213
|
+
locale,
|
|
13214
|
+
clock
|
|
13215
|
+
}) => {
|
|
13216
|
+
const symbol = TOKEN_REGISTRY.stablecoin(participation.asset.code);
|
|
13217
|
+
const address = participation.walletAddress;
|
|
13218
|
+
return {
|
|
13219
|
+
key: participation.id,
|
|
13220
|
+
asset: {
|
|
13221
|
+
name: participation.asset.name,
|
|
13222
|
+
iconUrl: symbol === null ? null : stablecoinIconUrl(symbol)
|
|
13223
|
+
},
|
|
13224
|
+
amount: participationAmount(participation, locale),
|
|
13225
|
+
status: ParticipationStatusUi.fromDomain(participation.status),
|
|
13226
|
+
wallet: address === null ? null : walletLabel?.(address) ?? shortenAddress(address),
|
|
13227
|
+
placedAt: placedAtOf(participation.insertedAt, locale, clock)
|
|
13228
|
+
};
|
|
13229
|
+
}
|
|
13230
|
+
};
|
|
13231
|
+
function participationAmount(participation, locale) {
|
|
13232
|
+
const { amount, displayAmount, asset } = participation;
|
|
13233
|
+
const code = AssetSymbol(asset.code);
|
|
13234
|
+
const parsed = baseUnits(amount, asset.fractionalDigits);
|
|
13235
|
+
return parsed === null ? FormattedAmountAssetUi(`${displayAmount} ${code}`) : assetAmount(formatAmount(parsed, locale), code);
|
|
13236
|
+
}
|
|
13237
|
+
function baseUnits(raw, decimals) {
|
|
13238
|
+
if (!/^\d+$/.test(raw)) return null;
|
|
13239
|
+
try {
|
|
13240
|
+
return BlockchainAmount({
|
|
13241
|
+
raw: parseUint256(BigInt(raw), "participation amount"),
|
|
13242
|
+
decimals: AssetDecimals(decimals)
|
|
13243
|
+
});
|
|
13244
|
+
} catch {
|
|
13245
|
+
return null;
|
|
13246
|
+
}
|
|
13247
|
+
}
|
|
13248
|
+
function placedAtOf(date, locale, clock) {
|
|
13249
|
+
return date === null || Number.isNaN(date.getTime()) ? null : formatShortDateTime(date, { locale, ...clock });
|
|
13250
|
+
}
|
|
13251
|
+
|
|
13252
|
+
// src/client/hooks/providers/claim/coin-list/token-sale/coin-list-token-sale-claim-ui-mapper.ts
|
|
13253
|
+
var CoinListTokenSaleClaimUiMapper = {
|
|
13254
|
+
/**
|
|
13255
|
+
* The card for a participations read.
|
|
13256
|
+
*
|
|
13257
|
+
* A signed-out user and a switched-off card both render nothing; the host
|
|
13258
|
+
* owns asking the user to sign in. Every other failure is offered a retry.
|
|
13259
|
+
*/
|
|
13260
|
+
toUiState: ({
|
|
13261
|
+
participations,
|
|
13262
|
+
walletLabel,
|
|
13263
|
+
locale,
|
|
13264
|
+
clock
|
|
13265
|
+
}) => {
|
|
13266
|
+
switch (participations.type) {
|
|
13267
|
+
case "DISABLED":
|
|
13268
|
+
return { type: "HIDDEN" };
|
|
13269
|
+
case "LOADING":
|
|
13270
|
+
return { type: "LOADING" };
|
|
13271
|
+
case "ERROR":
|
|
13272
|
+
return participations.reason === "not-authenticated" ? { type: "HIDDEN" } : { type: "ERROR" };
|
|
13273
|
+
case "CONTENT":
|
|
13274
|
+
return {
|
|
13275
|
+
type: "CONTENT",
|
|
13276
|
+
rows: newestFirst(participations.participations).map(
|
|
13277
|
+
(participation) => ParticipationRowUi.fromDomain(participation, {
|
|
13278
|
+
walletLabel,
|
|
13279
|
+
locale,
|
|
13280
|
+
clock
|
|
13281
|
+
})
|
|
13282
|
+
)
|
|
13283
|
+
};
|
|
13284
|
+
default: {
|
|
13285
|
+
const exhaustive = participations;
|
|
13286
|
+
return exhaustive;
|
|
13287
|
+
}
|
|
13288
|
+
}
|
|
13289
|
+
}
|
|
13290
|
+
};
|
|
13291
|
+
function newestFirst(participations) {
|
|
13292
|
+
return [...participations].sort(
|
|
13293
|
+
(a, b) => placedAt(b) - placedAt(a) || (a.id < b.id ? -1 : a.id > b.id ? 1 : 0)
|
|
13294
|
+
);
|
|
13295
|
+
}
|
|
13296
|
+
function placedAt(participation) {
|
|
13297
|
+
const time = participation.insertedAt?.getTime() ?? Number.NaN;
|
|
13298
|
+
return Number.isNaN(time) ? Number.NEGATIVE_INFINITY : time;
|
|
13299
|
+
}
|
|
13300
|
+
|
|
13301
|
+
// src/client/ui/hooks/useHydrated.ts
|
|
13302
|
+
import { useSyncExternalStore as useSyncExternalStore2 } from "react";
|
|
13303
|
+
function useHydrated() {
|
|
13304
|
+
return useSyncExternalStore2(
|
|
13305
|
+
subscribe2,
|
|
13306
|
+
() => true,
|
|
13307
|
+
() => false
|
|
13308
|
+
);
|
|
13309
|
+
}
|
|
13310
|
+
function subscribe2() {
|
|
13311
|
+
return () => {
|
|
13312
|
+
};
|
|
13313
|
+
}
|
|
13314
|
+
|
|
13315
|
+
// src/client/hooks/providers/claim/coin-list/token-sale/useCoinListTokenSaleClaimViewModel.ts
|
|
13316
|
+
function useCoinListTokenSaleClaimViewModel({
|
|
13317
|
+
offer,
|
|
13318
|
+
walletLabel,
|
|
13319
|
+
data,
|
|
13320
|
+
pollInterval,
|
|
13321
|
+
enabled = true
|
|
13322
|
+
}) {
|
|
13323
|
+
const locale = useLocale();
|
|
13324
|
+
const hydrated = useHydrated();
|
|
13325
|
+
const { participationsState, refetch } = useCoinListTokenSaleParticipations(
|
|
13326
|
+
offer.id,
|
|
13327
|
+
{ data, pollInterval, enabled }
|
|
13328
|
+
);
|
|
13329
|
+
const state = CoinListTokenSaleClaimUiMapper.toUiState({
|
|
13330
|
+
participations: participationsState,
|
|
13331
|
+
walletLabel,
|
|
13332
|
+
locale,
|
|
13333
|
+
// The user's own clock, except on a server and through hydration, where
|
|
13334
|
+
// the machine's zone would make the markup differ between the two. The
|
|
13335
|
+
// poll re-renders often enough for "this year" to stay current.
|
|
13336
|
+
clock: {
|
|
13337
|
+
now: EpochMillis.now(),
|
|
13338
|
+
timeZone: hydrated ? void 0 : "UTC"
|
|
13339
|
+
}
|
|
13340
|
+
});
|
|
13341
|
+
const onEvent = (event) => {
|
|
13342
|
+
switch (event.type) {
|
|
13343
|
+
case "ON_RETRY_LOAD":
|
|
13344
|
+
refetch();
|
|
13345
|
+
return;
|
|
13346
|
+
default: {
|
|
13347
|
+
const exhaustive = event.type;
|
|
13348
|
+
return exhaustive;
|
|
13349
|
+
}
|
|
13350
|
+
}
|
|
13351
|
+
};
|
|
13352
|
+
return { state, onEvent };
|
|
13353
|
+
}
|
|
13354
|
+
|
|
13355
|
+
// src/client/components/providers/claim/coin-list/token-sale/CoinListTokenSaleClaimContainer.tsx
|
|
13356
|
+
import { jsx as jsx98 } from "react/jsx-runtime";
|
|
13357
|
+
function CoinListTokenSaleClaimContainer({
|
|
13358
|
+
offer,
|
|
13359
|
+
walletLabel,
|
|
13360
|
+
enabled,
|
|
13361
|
+
className
|
|
13362
|
+
}) {
|
|
13363
|
+
const { state, onEvent } = useCoinListTokenSaleClaimViewModel({
|
|
13364
|
+
offer,
|
|
13365
|
+
walletLabel,
|
|
13366
|
+
enabled
|
|
13367
|
+
});
|
|
13368
|
+
return /* @__PURE__ */ jsx98(
|
|
13369
|
+
CoinListTokenSaleClaimView,
|
|
13370
|
+
{
|
|
13371
|
+
state,
|
|
13372
|
+
onEvent,
|
|
13373
|
+
className
|
|
13374
|
+
}
|
|
13375
|
+
);
|
|
13376
|
+
}
|
|
13377
|
+
|
|
13009
13378
|
// src/client/components/providers/claim/ClaimContainer.tsx
|
|
13010
|
-
import { jsx as
|
|
13379
|
+
import { jsx as jsx99 } from "react/jsx-runtime";
|
|
13011
13380
|
function ClaimContainer({
|
|
13012
13381
|
offer,
|
|
13013
13382
|
wallets,
|
|
@@ -13017,7 +13386,7 @@ function ClaimContainer({
|
|
|
13017
13386
|
className
|
|
13018
13387
|
}) {
|
|
13019
13388
|
return renderOffer2(offer, {
|
|
13020
|
-
centrifugeVault: (vaultOffer) => /* @__PURE__ */
|
|
13389
|
+
centrifugeVault: (vaultOffer) => /* @__PURE__ */ jsx99(
|
|
13021
13390
|
CentrifugeVaultClaimContainer,
|
|
13022
13391
|
{
|
|
13023
13392
|
offer: vaultOffer,
|
|
@@ -13027,6 +13396,15 @@ function ClaimContainer({
|
|
|
13027
13396
|
enabled,
|
|
13028
13397
|
className
|
|
13029
13398
|
}
|
|
13399
|
+
),
|
|
13400
|
+
coinListTokenSale: (saleOffer) => /* @__PURE__ */ jsx99(
|
|
13401
|
+
CoinListTokenSaleClaimContainer,
|
|
13402
|
+
{
|
|
13403
|
+
offer: saleOffer,
|
|
13404
|
+
walletLabel,
|
|
13405
|
+
enabled,
|
|
13406
|
+
className
|
|
13407
|
+
}
|
|
13030
13408
|
)
|
|
13031
13409
|
});
|
|
13032
13410
|
}
|
|
@@ -13034,8 +13412,10 @@ function renderOffer2(offer, branches) {
|
|
|
13034
13412
|
switch (offer.type) {
|
|
13035
13413
|
case "centrifuge::vault":
|
|
13036
13414
|
return branches.centrifugeVault(offer);
|
|
13415
|
+
case "coinlist::token_sale":
|
|
13416
|
+
return branches.coinListTokenSale(offer);
|
|
13037
13417
|
default: {
|
|
13038
|
-
const exhaustive = offer
|
|
13418
|
+
const exhaustive = offer;
|
|
13039
13419
|
return exhaustive;
|
|
13040
13420
|
}
|
|
13041
13421
|
}
|
|
@@ -13043,9 +13423,9 @@ function renderOffer2(offer, branches) {
|
|
|
13043
13423
|
|
|
13044
13424
|
// src/client/components/requirements/identity-verification/IdentityVerificationView.tsx
|
|
13045
13425
|
import SumsubWebSdk from "@sumsub/websdk-react";
|
|
13046
|
-
import { jsx as
|
|
13426
|
+
import { jsx as jsx100, jsxs as jsxs65 } from "react/jsx-runtime";
|
|
13047
13427
|
function IdentityVerificationView(props) {
|
|
13048
|
-
return /* @__PURE__ */
|
|
13428
|
+
return /* @__PURE__ */ jsx100(CoinListStyleScope, { children: /* @__PURE__ */ jsx100(IdentityVerificationViewBody, { ...props }) });
|
|
13049
13429
|
}
|
|
13050
13430
|
function IdentityVerificationViewBody({
|
|
13051
13431
|
state,
|
|
@@ -13054,7 +13434,7 @@ function IdentityVerificationViewBody({
|
|
|
13054
13434
|
}) {
|
|
13055
13435
|
switch (state.type) {
|
|
13056
13436
|
case "loading":
|
|
13057
|
-
return /* @__PURE__ */
|
|
13437
|
+
return /* @__PURE__ */ jsx100(
|
|
13058
13438
|
"output",
|
|
13059
13439
|
{
|
|
13060
13440
|
"aria-live": "polite",
|
|
@@ -13062,11 +13442,11 @@ function IdentityVerificationViewBody({
|
|
|
13062
13442
|
"clcosdk:flex clcosdk:min-h-40 clcosdk:items-center clcosdk:justify-center",
|
|
13063
13443
|
className
|
|
13064
13444
|
),
|
|
13065
|
-
children: /* @__PURE__ */
|
|
13445
|
+
children: /* @__PURE__ */ jsx100("p", { className: cn(typeClasses.body, "clcosdk:text-text-secondary"), children: "Loading identity verification..." })
|
|
13066
13446
|
}
|
|
13067
13447
|
);
|
|
13068
13448
|
case "error":
|
|
13069
|
-
return /* @__PURE__ */
|
|
13449
|
+
return /* @__PURE__ */ jsxs65(
|
|
13070
13450
|
"div",
|
|
13071
13451
|
{
|
|
13072
13452
|
className: cn(
|
|
@@ -13074,13 +13454,13 @@ function IdentityVerificationViewBody({
|
|
|
13074
13454
|
className
|
|
13075
13455
|
),
|
|
13076
13456
|
children: [
|
|
13077
|
-
/* @__PURE__ */
|
|
13078
|
-
state.retryable && /* @__PURE__ */
|
|
13457
|
+
/* @__PURE__ */ jsx100(AlertBanner, { variant: "error", icon: true, content: state.message }),
|
|
13458
|
+
state.retryable && /* @__PURE__ */ jsx100(ClButton, { size: "sm", onClick: () => onEvent({ type: "ON_RETRY" }), children: "Try again" })
|
|
13079
13459
|
]
|
|
13080
13460
|
}
|
|
13081
13461
|
);
|
|
13082
13462
|
case "ready":
|
|
13083
|
-
return /* @__PURE__ */
|
|
13463
|
+
return /* @__PURE__ */ jsx100("div", { className: cn("clcosdk:w-full", className), children: /* @__PURE__ */ jsx100(
|
|
13084
13464
|
SumsubWebSdk,
|
|
13085
13465
|
{
|
|
13086
13466
|
accessToken: state.accessToken,
|
|
@@ -13120,24 +13500,24 @@ function toError(error) {
|
|
|
13120
13500
|
}
|
|
13121
13501
|
|
|
13122
13502
|
// src/client/hooks/requirements/identity-verification/useIdentityVerificationViewModel.ts
|
|
13123
|
-
import { useCallback as
|
|
13503
|
+
import { useCallback as useCallback12, useEffect as useEffect21, useMemo as useMemo12, useRef as useRef14 } from "react";
|
|
13124
13504
|
|
|
13125
13505
|
// src/client/hooks/requirements/data/useKycToken.ts
|
|
13126
|
-
import { useCallback as
|
|
13506
|
+
import { useCallback as useCallback11, useEffect as useEffect20, useRef as useRef13, useState as useState32 } from "react";
|
|
13127
13507
|
var IDLE_STATE = { type: "IDLE" };
|
|
13128
13508
|
var LOADING_STATE2 = { type: "LOADING" };
|
|
13129
13509
|
function useKycToken(levelName, reset) {
|
|
13130
13510
|
const { coinlist } = useCoinList();
|
|
13131
13511
|
const log = useLogger("useKycToken");
|
|
13132
|
-
const [kycTokenState, setKycTokenState] =
|
|
13133
|
-
const resetPendingRef =
|
|
13134
|
-
const tokenIssuedRef =
|
|
13512
|
+
const [kycTokenState, setKycTokenState] = useState32(IDLE_STATE);
|
|
13513
|
+
const resetPendingRef = useRef13(reset === true);
|
|
13514
|
+
const tokenIssuedRef = useRef13(false);
|
|
13135
13515
|
useEffect20(() => {
|
|
13136
13516
|
if (!tokenIssuedRef.current) {
|
|
13137
13517
|
resetPendingRef.current = reset === true;
|
|
13138
13518
|
}
|
|
13139
13519
|
}, [reset]);
|
|
13140
|
-
const fetchToken =
|
|
13520
|
+
const fetchToken = useCallback11(async () => {
|
|
13141
13521
|
setKycTokenState(LOADING_STATE2);
|
|
13142
13522
|
try {
|
|
13143
13523
|
const kycToken = await coinlist.requirements.createKycToken({
|
|
@@ -13171,7 +13551,7 @@ var GENERIC_ERROR_MESSAGE2 = "Unable to start identity verification right now. P
|
|
|
13171
13551
|
function useIdentityVerificationViewModel(options = {}) {
|
|
13172
13552
|
const { levelName, reset, locale, onSubmitted, onError } = options;
|
|
13173
13553
|
const { kycTokenState, fetchToken } = useKycToken(levelName, reset);
|
|
13174
|
-
const fetchedRef =
|
|
13554
|
+
const fetchedRef = useRef14(false);
|
|
13175
13555
|
useEffect21(() => {
|
|
13176
13556
|
if (fetchedRef.current) {
|
|
13177
13557
|
return;
|
|
@@ -13206,7 +13586,7 @@ function useIdentityVerificationViewModel(options = {}) {
|
|
|
13206
13586
|
}
|
|
13207
13587
|
}
|
|
13208
13588
|
}, [kycTokenState, locale, fetchToken]);
|
|
13209
|
-
const onEvent =
|
|
13589
|
+
const onEvent = useCallback12(
|
|
13210
13590
|
(event) => {
|
|
13211
13591
|
switch (event.type) {
|
|
13212
13592
|
case "ON_RETRY":
|
|
@@ -13231,7 +13611,7 @@ function useIdentityVerificationViewModel(options = {}) {
|
|
|
13231
13611
|
}
|
|
13232
13612
|
|
|
13233
13613
|
// src/client/components/requirements/identity-verification/IdentityVerificationContainer.tsx
|
|
13234
|
-
import { jsx as
|
|
13614
|
+
import { jsx as jsx101 } from "react/jsx-runtime";
|
|
13235
13615
|
function IdentityVerificationContainer({
|
|
13236
13616
|
levelName,
|
|
13237
13617
|
reset,
|
|
@@ -13247,7 +13627,7 @@ function IdentityVerificationContainer({
|
|
|
13247
13627
|
onSubmitted,
|
|
13248
13628
|
onError
|
|
13249
13629
|
});
|
|
13250
|
-
return /* @__PURE__ */
|
|
13630
|
+
return /* @__PURE__ */ jsx101(
|
|
13251
13631
|
IdentityVerificationView,
|
|
13252
13632
|
{
|
|
13253
13633
|
state,
|
|
@@ -13261,13 +13641,13 @@ function IdentityVerificationContainer({
|
|
|
13261
13641
|
import { ChevronRight } from "lucide-react";
|
|
13262
13642
|
|
|
13263
13643
|
// src/client/components/requirements/ConnectedWalletList.tsx
|
|
13264
|
-
import { useState as
|
|
13265
|
-
import { jsx as
|
|
13644
|
+
import { useState as useState33 } from "react";
|
|
13645
|
+
import { jsx as jsx102, jsxs as jsxs66 } from "react/jsx-runtime";
|
|
13266
13646
|
function ConnectedWalletRow({
|
|
13267
13647
|
wallet,
|
|
13268
13648
|
onRemove
|
|
13269
13649
|
}) {
|
|
13270
|
-
const [state, setState] =
|
|
13650
|
+
const [state, setState] = useState33("idle");
|
|
13271
13651
|
const remove = async () => {
|
|
13272
13652
|
if (!onRemove) return;
|
|
13273
13653
|
setState("removing");
|
|
@@ -13278,8 +13658,8 @@ function ConnectedWalletRow({
|
|
|
13278
13658
|
setState("error");
|
|
13279
13659
|
}
|
|
13280
13660
|
};
|
|
13281
|
-
return /* @__PURE__ */
|
|
13282
|
-
/* @__PURE__ */
|
|
13661
|
+
return /* @__PURE__ */ jsxs66("div", { className: "clcosdk:flex clcosdk:min-h-9 clcosdk:flex-wrap clcosdk:items-center clcosdk:justify-between clcosdk:gap-2", children: [
|
|
13662
|
+
/* @__PURE__ */ jsx102(
|
|
13283
13663
|
"span",
|
|
13284
13664
|
{
|
|
13285
13665
|
title: wallet.address,
|
|
@@ -13290,16 +13670,16 @@ function ConnectedWalletRow({
|
|
|
13290
13670
|
children: wallet.shortAddress
|
|
13291
13671
|
}
|
|
13292
13672
|
),
|
|
13293
|
-
onRemove != null && (state === "confirming" ? /* @__PURE__ */
|
|
13294
|
-
/* @__PURE__ */
|
|
13673
|
+
onRemove != null && (state === "confirming" ? /* @__PURE__ */ jsxs66("div", { className: "clcosdk:flex clcosdk:items-center clcosdk:gap-2", children: [
|
|
13674
|
+
/* @__PURE__ */ jsx102(
|
|
13295
13675
|
"span",
|
|
13296
13676
|
{
|
|
13297
13677
|
className: cn(typeClasses.subhead, "clcosdk:text-text-secondary"),
|
|
13298
13678
|
children: "Remove?"
|
|
13299
13679
|
}
|
|
13300
13680
|
),
|
|
13301
|
-
/* @__PURE__ */
|
|
13302
|
-
/* @__PURE__ */
|
|
13681
|
+
/* @__PURE__ */ jsx102(ClButton, { size: "sm", variant: "destructive", onClick: remove, children: "Remove" }),
|
|
13682
|
+
/* @__PURE__ */ jsx102(
|
|
13303
13683
|
ClButton,
|
|
13304
13684
|
{
|
|
13305
13685
|
size: "sm",
|
|
@@ -13308,9 +13688,9 @@ function ConnectedWalletRow({
|
|
|
13308
13688
|
children: "Cancel"
|
|
13309
13689
|
}
|
|
13310
13690
|
)
|
|
13311
|
-
] }) : state === "error" ? /* @__PURE__ */
|
|
13312
|
-
/* @__PURE__ */
|
|
13313
|
-
/* @__PURE__ */
|
|
13691
|
+
] }) : state === "error" ? /* @__PURE__ */ jsxs66("div", { className: "clcosdk:flex clcosdk:items-center clcosdk:gap-2", children: [
|
|
13692
|
+
/* @__PURE__ */ jsx102("span", { className: cn(typeClasses.subhead, "clcosdk:text-error"), children: "Couldn't remove." }),
|
|
13693
|
+
/* @__PURE__ */ jsx102(
|
|
13314
13694
|
ClButton,
|
|
13315
13695
|
{
|
|
13316
13696
|
size: "sm",
|
|
@@ -13319,7 +13699,7 @@ function ConnectedWalletRow({
|
|
|
13319
13699
|
children: "Try again"
|
|
13320
13700
|
}
|
|
13321
13701
|
)
|
|
13322
|
-
] }) : /* @__PURE__ */
|
|
13702
|
+
] }) : /* @__PURE__ */ jsx102(
|
|
13323
13703
|
ClButton,
|
|
13324
13704
|
{
|
|
13325
13705
|
size: "sm",
|
|
@@ -13332,7 +13712,7 @@ function ConnectedWalletRow({
|
|
|
13332
13712
|
] });
|
|
13333
13713
|
}
|
|
13334
13714
|
function ConnectedWalletList(props) {
|
|
13335
|
-
return /* @__PURE__ */
|
|
13715
|
+
return /* @__PURE__ */ jsx102(CoinListStyleScope, { children: /* @__PURE__ */ jsx102(ConnectedWalletListBody, { ...props }) });
|
|
13336
13716
|
}
|
|
13337
13717
|
function ConnectedWalletListBody({
|
|
13338
13718
|
wallets,
|
|
@@ -13342,18 +13722,18 @@ function ConnectedWalletListBody({
|
|
|
13342
13722
|
status = "ready",
|
|
13343
13723
|
className
|
|
13344
13724
|
}) {
|
|
13345
|
-
return /* @__PURE__ */
|
|
13725
|
+
return /* @__PURE__ */ jsxs66(
|
|
13346
13726
|
"div",
|
|
13347
13727
|
{
|
|
13348
13728
|
className: cn("clcosdk:flex clcosdk:flex-col clcosdk:gap-2", className),
|
|
13349
13729
|
children: [
|
|
13350
|
-
status === "loading" ? /* @__PURE__ */
|
|
13730
|
+
status === "loading" ? /* @__PURE__ */ jsx102(AlertBanner, { variant: "info", content: "Loading your connected wallets\u2026" }) : status === "error" ? /* @__PURE__ */ jsx102(
|
|
13351
13731
|
AlertBanner,
|
|
13352
13732
|
{
|
|
13353
13733
|
variant: "error",
|
|
13354
13734
|
content: "Couldn't load your connected wallets."
|
|
13355
13735
|
}
|
|
13356
|
-
) : wallets.length === 0 ? /* @__PURE__ */
|
|
13736
|
+
) : wallets.length === 0 ? /* @__PURE__ */ jsx102(AlertBanner, { variant: "info", content: "No wallets connected yet." }) : /* @__PURE__ */ jsx102("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:divide-y clcosdk:divide-divider", children: wallets.map((wallet) => /* @__PURE__ */ jsx102(
|
|
13357
13737
|
ConnectedWalletRow,
|
|
13358
13738
|
{
|
|
13359
13739
|
wallet,
|
|
@@ -13361,7 +13741,7 @@ function ConnectedWalletListBody({
|
|
|
13361
13741
|
},
|
|
13362
13742
|
wallet.id
|
|
13363
13743
|
)) }),
|
|
13364
|
-
onAdd != null && status !== "loading" && /* @__PURE__ */
|
|
13744
|
+
onAdd != null && status !== "loading" && /* @__PURE__ */ jsx102(
|
|
13365
13745
|
ClButton,
|
|
13366
13746
|
{
|
|
13367
13747
|
size: "sm",
|
|
@@ -13377,7 +13757,7 @@ function ConnectedWalletListBody({
|
|
|
13377
13757
|
}
|
|
13378
13758
|
|
|
13379
13759
|
// src/client/components/requirements/RequirementItem.tsx
|
|
13380
|
-
import { Fragment as Fragment14, jsx as
|
|
13760
|
+
import { Fragment as Fragment14, jsx as jsx103, jsxs as jsxs67 } from "react/jsx-runtime";
|
|
13381
13761
|
var DEFAULT_PENDING = "Under review. We'll notify you when complete.";
|
|
13382
13762
|
var DEFAULT_REJECTED = "Verification rejected.";
|
|
13383
13763
|
var SUPPORT_LINK = "Contact support";
|
|
@@ -13390,9 +13770,9 @@ function VerificationActionZone({
|
|
|
13390
13770
|
switch (status) {
|
|
13391
13771
|
case "required":
|
|
13392
13772
|
if (onAction === null) return null;
|
|
13393
|
-
return /* @__PURE__ */
|
|
13773
|
+
return /* @__PURE__ */ jsx103(ClButton, { size: "sm", className: "clcosdk:self-start", onClick: onAction, children: "Continue" });
|
|
13394
13774
|
case "pending":
|
|
13395
|
-
return /* @__PURE__ */
|
|
13775
|
+
return /* @__PURE__ */ jsx103(
|
|
13396
13776
|
AlertBanner,
|
|
13397
13777
|
{
|
|
13398
13778
|
variant: "warning",
|
|
@@ -13400,7 +13780,7 @@ function VerificationActionZone({
|
|
|
13400
13780
|
}
|
|
13401
13781
|
);
|
|
13402
13782
|
case "completed":
|
|
13403
|
-
return /* @__PURE__ */
|
|
13783
|
+
return /* @__PURE__ */ jsx103(
|
|
13404
13784
|
AlertBanner,
|
|
13405
13785
|
{
|
|
13406
13786
|
variant: "success",
|
|
@@ -13408,11 +13788,11 @@ function VerificationActionZone({
|
|
|
13408
13788
|
}
|
|
13409
13789
|
);
|
|
13410
13790
|
case "rejected":
|
|
13411
|
-
return /* @__PURE__ */
|
|
13791
|
+
return /* @__PURE__ */ jsx103(
|
|
13412
13792
|
AlertBanner,
|
|
13413
13793
|
{
|
|
13414
13794
|
variant: "error",
|
|
13415
|
-
content: /* @__PURE__ */
|
|
13795
|
+
content: /* @__PURE__ */ jsx103(
|
|
13416
13796
|
RejectedMessage,
|
|
13417
13797
|
{
|
|
13418
13798
|
message: statusMessages?.rejected ?? DEFAULT_REJECTED,
|
|
@@ -13432,10 +13812,10 @@ function RejectedMessage({
|
|
|
13432
13812
|
return message;
|
|
13433
13813
|
}
|
|
13434
13814
|
if (linkAt === -1) {
|
|
13435
|
-
return /* @__PURE__ */
|
|
13815
|
+
return /* @__PURE__ */ jsxs67(Fragment14, { children: [
|
|
13436
13816
|
message,
|
|
13437
13817
|
" ",
|
|
13438
|
-
/* @__PURE__ */
|
|
13818
|
+
/* @__PURE__ */ jsx103(
|
|
13439
13819
|
"button",
|
|
13440
13820
|
{
|
|
13441
13821
|
type: "button",
|
|
@@ -13447,9 +13827,9 @@ function RejectedMessage({
|
|
|
13447
13827
|
"."
|
|
13448
13828
|
] });
|
|
13449
13829
|
}
|
|
13450
|
-
return /* @__PURE__ */
|
|
13830
|
+
return /* @__PURE__ */ jsxs67(Fragment14, { children: [
|
|
13451
13831
|
message.slice(0, linkAt),
|
|
13452
|
-
/* @__PURE__ */
|
|
13832
|
+
/* @__PURE__ */ jsx103(
|
|
13453
13833
|
"button",
|
|
13454
13834
|
{
|
|
13455
13835
|
type: "button",
|
|
@@ -13470,8 +13850,8 @@ function WalletActionZone({
|
|
|
13470
13850
|
onRemoveWallet
|
|
13471
13851
|
}) {
|
|
13472
13852
|
if (multiWallet) {
|
|
13473
|
-
return /* @__PURE__ */
|
|
13474
|
-
/* @__PURE__ */
|
|
13853
|
+
return /* @__PURE__ */ jsxs67(Fragment14, { children: [
|
|
13854
|
+
/* @__PURE__ */ jsx103(
|
|
13475
13855
|
ConnectedWalletList,
|
|
13476
13856
|
{
|
|
13477
13857
|
wallets: connectedWallets,
|
|
@@ -13480,7 +13860,7 @@ function WalletActionZone({
|
|
|
13480
13860
|
status: walletsStatus
|
|
13481
13861
|
}
|
|
13482
13862
|
),
|
|
13483
|
-
status === "rejected" && /* @__PURE__ */
|
|
13863
|
+
status === "rejected" && /* @__PURE__ */ jsx103(
|
|
13484
13864
|
AlertBanner,
|
|
13485
13865
|
{
|
|
13486
13866
|
variant: "error",
|
|
@@ -13491,8 +13871,8 @@ function WalletActionZone({
|
|
|
13491
13871
|
}
|
|
13492
13872
|
if (status === "completed") {
|
|
13493
13873
|
const connected = connectedWallets[0];
|
|
13494
|
-
return /* @__PURE__ */
|
|
13495
|
-
onAction !== null && /* @__PURE__ */
|
|
13874
|
+
return /* @__PURE__ */ jsxs67(Fragment14, { children: [
|
|
13875
|
+
onAction !== null && /* @__PURE__ */ jsx103(
|
|
13496
13876
|
ClButton,
|
|
13497
13877
|
{
|
|
13498
13878
|
size: "sm",
|
|
@@ -13502,19 +13882,19 @@ function WalletActionZone({
|
|
|
13502
13882
|
children: "Change wallet"
|
|
13503
13883
|
}
|
|
13504
13884
|
),
|
|
13505
|
-
walletsStatus === "loading" ? /* @__PURE__ */
|
|
13885
|
+
walletsStatus === "loading" ? /* @__PURE__ */ jsx103(
|
|
13506
13886
|
AlertBanner,
|
|
13507
13887
|
{
|
|
13508
13888
|
variant: "info",
|
|
13509
13889
|
content: "Loading your connected wallet\u2026"
|
|
13510
13890
|
}
|
|
13511
|
-
) : walletsStatus === "error" ? /* @__PURE__ */
|
|
13891
|
+
) : walletsStatus === "error" ? /* @__PURE__ */ jsx103(
|
|
13512
13892
|
AlertBanner,
|
|
13513
13893
|
{
|
|
13514
13894
|
variant: "error",
|
|
13515
13895
|
content: "Couldn't load your connected wallet."
|
|
13516
13896
|
}
|
|
13517
|
-
) : /* @__PURE__ */
|
|
13897
|
+
) : /* @__PURE__ */ jsx103(
|
|
13518
13898
|
AlertBanner,
|
|
13519
13899
|
{
|
|
13520
13900
|
variant: "success",
|
|
@@ -13524,9 +13904,9 @@ function WalletActionZone({
|
|
|
13524
13904
|
] });
|
|
13525
13905
|
}
|
|
13526
13906
|
if (status === "rejected") {
|
|
13527
|
-
return /* @__PURE__ */
|
|
13528
|
-
onAction !== null && /* @__PURE__ */
|
|
13529
|
-
/* @__PURE__ */
|
|
13907
|
+
return /* @__PURE__ */ jsxs67(Fragment14, { children: [
|
|
13908
|
+
onAction !== null && /* @__PURE__ */ jsx103(ClButton, { size: "sm", className: "clcosdk:self-start", onClick: onAction, children: "Connect wallet" }),
|
|
13909
|
+
/* @__PURE__ */ jsx103(
|
|
13530
13910
|
AlertBanner,
|
|
13531
13911
|
{
|
|
13532
13912
|
variant: "error",
|
|
@@ -13536,7 +13916,7 @@ function WalletActionZone({
|
|
|
13536
13916
|
] });
|
|
13537
13917
|
}
|
|
13538
13918
|
if (onAction === null) return null;
|
|
13539
|
-
return /* @__PURE__ */
|
|
13919
|
+
return /* @__PURE__ */ jsx103(ClButton, { size: "sm", className: "clcosdk:self-start", onClick: onAction, children: "Connect wallet" });
|
|
13540
13920
|
}
|
|
13541
13921
|
function RequirementItem({
|
|
13542
13922
|
ui,
|
|
@@ -13549,7 +13929,7 @@ function RequirementItem({
|
|
|
13549
13929
|
onContactSupport,
|
|
13550
13930
|
spaceBeforeNextRow = true
|
|
13551
13931
|
}) {
|
|
13552
|
-
return /* @__PURE__ */
|
|
13932
|
+
return /* @__PURE__ */ jsx103(CoinListStyleScope, { children: /* @__PURE__ */ jsxs67(
|
|
13553
13933
|
"div",
|
|
13554
13934
|
{
|
|
13555
13935
|
className: cn(
|
|
@@ -13557,7 +13937,7 @@ function RequirementItem({
|
|
|
13557
13937
|
className
|
|
13558
13938
|
),
|
|
13559
13939
|
children: [
|
|
13560
|
-
/* @__PURE__ */
|
|
13940
|
+
/* @__PURE__ */ jsxs67(
|
|
13561
13941
|
"button",
|
|
13562
13942
|
{
|
|
13563
13943
|
type: "button",
|
|
@@ -13565,9 +13945,9 @@ function RequirementItem({
|
|
|
13565
13945
|
"aria-expanded": expanded,
|
|
13566
13946
|
className: "clcosdk:-mx-2 clcosdk:flex clcosdk:h-14 clcosdk:w-[calc(100%+16px)] clcosdk:cursor-pointer clcosdk:items-center clcosdk:justify-between clcosdk:rounded-2xl clcosdk:px-2 clcosdk:transition-colors clcosdk:hover:bg-surface",
|
|
13567
13947
|
children: [
|
|
13568
|
-
/* @__PURE__ */
|
|
13569
|
-
/* @__PURE__ */
|
|
13570
|
-
/* @__PURE__ */
|
|
13948
|
+
/* @__PURE__ */ jsxs67("div", { className: "clcosdk:flex clcosdk:items-center clcosdk:gap-3", children: [
|
|
13949
|
+
/* @__PURE__ */ jsx103(StepStatusIcon, { status: ui.status }),
|
|
13950
|
+
/* @__PURE__ */ jsx103(
|
|
13571
13951
|
"span",
|
|
13572
13952
|
{
|
|
13573
13953
|
className: cn(
|
|
@@ -13578,7 +13958,7 @@ function RequirementItem({
|
|
|
13578
13958
|
}
|
|
13579
13959
|
)
|
|
13580
13960
|
] }),
|
|
13581
|
-
/* @__PURE__ */
|
|
13961
|
+
/* @__PURE__ */ jsx103(
|
|
13582
13962
|
ChevronRight,
|
|
13583
13963
|
{
|
|
13584
13964
|
className: cn(
|
|
@@ -13591,14 +13971,14 @@ function RequirementItem({
|
|
|
13591
13971
|
]
|
|
13592
13972
|
}
|
|
13593
13973
|
),
|
|
13594
|
-
/* @__PURE__ */
|
|
13974
|
+
/* @__PURE__ */ jsx103(
|
|
13595
13975
|
"div",
|
|
13596
13976
|
{
|
|
13597
13977
|
className: cn(
|
|
13598
13978
|
"clcosdk:grid clcosdk:transition-[grid-template-rows] clcosdk:duration-300 clcosdk:ease-in-out",
|
|
13599
13979
|
expanded ? "clcosdk:grid-rows-[1fr]" : "clcosdk:grid-rows-[0fr]"
|
|
13600
13980
|
),
|
|
13601
|
-
children: /* @__PURE__ */
|
|
13981
|
+
children: /* @__PURE__ */ jsx103("div", { className: "clcosdk:min-h-0 clcosdk:overflow-hidden", children: /* @__PURE__ */ jsxs67(
|
|
13602
13982
|
"div",
|
|
13603
13983
|
{
|
|
13604
13984
|
className: cn(
|
|
@@ -13606,7 +13986,7 @@ function RequirementItem({
|
|
|
13606
13986
|
spaceBeforeNextRow && "clcosdk:pb-4"
|
|
13607
13987
|
),
|
|
13608
13988
|
children: [
|
|
13609
|
-
/* @__PURE__ */
|
|
13989
|
+
/* @__PURE__ */ jsx103(
|
|
13610
13990
|
"p",
|
|
13611
13991
|
{
|
|
13612
13992
|
className: cn(
|
|
@@ -13616,7 +13996,7 @@ function RequirementItem({
|
|
|
13616
13996
|
children: ui.description
|
|
13617
13997
|
}
|
|
13618
13998
|
),
|
|
13619
|
-
ui.variant === "verification" ? /* @__PURE__ */
|
|
13999
|
+
ui.variant === "verification" ? /* @__PURE__ */ jsx103(
|
|
13620
14000
|
VerificationActionZone,
|
|
13621
14001
|
{
|
|
13622
14002
|
status: ui.status,
|
|
@@ -13624,7 +14004,7 @@ function RequirementItem({
|
|
|
13624
14004
|
onAction,
|
|
13625
14005
|
onContactSupport
|
|
13626
14006
|
}
|
|
13627
|
-
) : /* @__PURE__ */
|
|
14007
|
+
) : /* @__PURE__ */ jsx103(
|
|
13628
14008
|
WalletActionZone,
|
|
13629
14009
|
{
|
|
13630
14010
|
status: ui.status,
|
|
@@ -13646,9 +14026,9 @@ function RequirementItem({
|
|
|
13646
14026
|
}
|
|
13647
14027
|
|
|
13648
14028
|
// src/client/components/requirements/RequirementsChecklistView.tsx
|
|
13649
|
-
import { Fragment as Fragment15, jsx as
|
|
14029
|
+
import { Fragment as Fragment15, jsx as jsx104, jsxs as jsxs68 } from "react/jsx-runtime";
|
|
13650
14030
|
function RequirementsChecklistView(props) {
|
|
13651
|
-
return /* @__PURE__ */
|
|
14031
|
+
return /* @__PURE__ */ jsx104(CoinListStyleScope, { children: /* @__PURE__ */ jsx104(RequirementsChecklistViewBody, { ...props }) });
|
|
13652
14032
|
}
|
|
13653
14033
|
function RequirementsChecklistViewBody({
|
|
13654
14034
|
state,
|
|
@@ -13659,7 +14039,7 @@ function RequirementsChecklistViewBody({
|
|
|
13659
14039
|
}) {
|
|
13660
14040
|
switch (state.type) {
|
|
13661
14041
|
case "loading":
|
|
13662
|
-
return loading ?? /* @__PURE__ */
|
|
14042
|
+
return loading ?? /* @__PURE__ */ jsx104(
|
|
13663
14043
|
LoadingState2,
|
|
13664
14044
|
{
|
|
13665
14045
|
title: state.title,
|
|
@@ -13668,7 +14048,7 @@ function RequirementsChecklistViewBody({
|
|
|
13668
14048
|
}
|
|
13669
14049
|
);
|
|
13670
14050
|
case "error":
|
|
13671
|
-
return /* @__PURE__ */
|
|
14051
|
+
return /* @__PURE__ */ jsxs68(
|
|
13672
14052
|
"div",
|
|
13673
14053
|
{
|
|
13674
14054
|
className: cn(
|
|
@@ -13676,8 +14056,8 @@ function RequirementsChecklistViewBody({
|
|
|
13676
14056
|
className
|
|
13677
14057
|
),
|
|
13678
14058
|
children: [
|
|
13679
|
-
/* @__PURE__ */
|
|
13680
|
-
error ?? /* @__PURE__ */
|
|
14059
|
+
/* @__PURE__ */ jsx104("h3", { className: cn(typeClasses.h3, "clcosdk:text-text-primary"), children: state.title }),
|
|
14060
|
+
error ?? /* @__PURE__ */ jsx104(
|
|
13681
14061
|
AlertBanner,
|
|
13682
14062
|
{
|
|
13683
14063
|
variant: "error",
|
|
@@ -13689,7 +14069,7 @@ function RequirementsChecklistViewBody({
|
|
|
13689
14069
|
}
|
|
13690
14070
|
);
|
|
13691
14071
|
case "content":
|
|
13692
|
-
return /* @__PURE__ */
|
|
14072
|
+
return /* @__PURE__ */ jsxs68(
|
|
13693
14073
|
"div",
|
|
13694
14074
|
{
|
|
13695
14075
|
className: cn(
|
|
@@ -13697,9 +14077,9 @@ function RequirementsChecklistViewBody({
|
|
|
13697
14077
|
className
|
|
13698
14078
|
),
|
|
13699
14079
|
children: [
|
|
13700
|
-
/* @__PURE__ */
|
|
13701
|
-
/* @__PURE__ */
|
|
13702
|
-
state.blockedMessage == null && /* @__PURE__ */
|
|
14080
|
+
/* @__PURE__ */ jsxs68("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-2", children: [
|
|
14081
|
+
/* @__PURE__ */ jsx104("h3", { className: cn(typeClasses.h3, "clcosdk:text-text-primary"), children: state.title }),
|
|
14082
|
+
state.blockedMessage == null && /* @__PURE__ */ jsx104(
|
|
13703
14083
|
"p",
|
|
13704
14084
|
{
|
|
13705
14085
|
className: cn(typeClasses.body, "clcosdk:text-text-secondary"),
|
|
@@ -13707,7 +14087,7 @@ function RequirementsChecklistViewBody({
|
|
|
13707
14087
|
}
|
|
13708
14088
|
)
|
|
13709
14089
|
] }),
|
|
13710
|
-
state.blockedMessage != null ? /* @__PURE__ */
|
|
14090
|
+
state.blockedMessage != null ? /* @__PURE__ */ jsx104(AlertBanner, { variant: "info", icon: true, content: state.blockedMessage }) : state.items.length === 0 ? state.continueAction && /* @__PURE__ */ jsx104(
|
|
13711
14091
|
ClButton,
|
|
13712
14092
|
{
|
|
13713
14093
|
variant: "primary",
|
|
@@ -13716,8 +14096,8 @@ function RequirementsChecklistViewBody({
|
|
|
13716
14096
|
onClick: () => onEvent({ type: "ON_CONTINUE" }),
|
|
13717
14097
|
children: "Continue"
|
|
13718
14098
|
}
|
|
13719
|
-
) : /* @__PURE__ */
|
|
13720
|
-
/* @__PURE__ */
|
|
14099
|
+
) : /* @__PURE__ */ jsxs68(Fragment15, { children: [
|
|
14100
|
+
/* @__PURE__ */ jsx104("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:divide-y clcosdk:divide-divider", children: state.items.map((row, index) => /* @__PURE__ */ jsx104(
|
|
13721
14101
|
RequirementItem,
|
|
13722
14102
|
{
|
|
13723
14103
|
ui: row.item,
|
|
@@ -13737,8 +14117,8 @@ function RequirementsChecklistViewBody({
|
|
|
13737
14117
|
},
|
|
13738
14118
|
row.id
|
|
13739
14119
|
)) }),
|
|
13740
|
-
/* @__PURE__ */
|
|
13741
|
-
/* @__PURE__ */
|
|
14120
|
+
/* @__PURE__ */ jsxs68("div", { className: "clcosdk:flex clcosdk:flex-row clcosdk:items-center clcosdk:justify-between clcosdk:gap-6", children: [
|
|
14121
|
+
/* @__PURE__ */ jsx104(
|
|
13742
14122
|
"span",
|
|
13743
14123
|
{
|
|
13744
14124
|
className: cn(
|
|
@@ -13749,7 +14129,7 @@ function RequirementsChecklistViewBody({
|
|
|
13749
14129
|
children: state.ineligible ? "You are not eligible to invest." : completedLabel(state.items)
|
|
13750
14130
|
}
|
|
13751
14131
|
),
|
|
13752
|
-
state.continueAction && /* @__PURE__ */
|
|
14132
|
+
state.continueAction && /* @__PURE__ */ jsx104(
|
|
13753
14133
|
ClButton,
|
|
13754
14134
|
{
|
|
13755
14135
|
variant: "primary",
|
|
@@ -13786,7 +14166,7 @@ function LoadingState2({
|
|
|
13786
14166
|
description,
|
|
13787
14167
|
className
|
|
13788
14168
|
}) {
|
|
13789
|
-
return /* @__PURE__ */
|
|
14169
|
+
return /* @__PURE__ */ jsxs68(
|
|
13790
14170
|
"div",
|
|
13791
14171
|
{
|
|
13792
14172
|
className: cn(
|
|
@@ -13794,19 +14174,19 @@ function LoadingState2({
|
|
|
13794
14174
|
className
|
|
13795
14175
|
),
|
|
13796
14176
|
children: [
|
|
13797
|
-
/* @__PURE__ */
|
|
13798
|
-
/* @__PURE__ */
|
|
13799
|
-
/* @__PURE__ */
|
|
13800
|
-
/* @__PURE__ */
|
|
14177
|
+
/* @__PURE__ */ jsx104("output", { className: "clcosdk:sr-only", children: "Loading requirements..." }),
|
|
14178
|
+
/* @__PURE__ */ jsxs68("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-2", children: [
|
|
14179
|
+
/* @__PURE__ */ jsx104("h3", { className: cn(typeClasses.h3, "clcosdk:text-text-primary"), children: title }),
|
|
14180
|
+
/* @__PURE__ */ jsx104("p", { className: cn(typeClasses.body, "clcosdk:text-text-secondary"), children: description })
|
|
13801
14181
|
] }),
|
|
13802
|
-
/* @__PURE__ */
|
|
14182
|
+
/* @__PURE__ */ jsx104("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-3", children: LOADING_ROW_WIDTHS.map((width) => /* @__PURE__ */ jsx104(Skeleton, { className: cn("clcosdk:h-8", width) }, width)) })
|
|
13803
14183
|
]
|
|
13804
14184
|
}
|
|
13805
14185
|
);
|
|
13806
14186
|
}
|
|
13807
14187
|
|
|
13808
14188
|
// src/client/components/requirements/tax-document/TaxDocumentModalView.tsx
|
|
13809
|
-
import { jsx as
|
|
14189
|
+
import { jsx as jsx105, jsxs as jsxs69 } from "react/jsx-runtime";
|
|
13810
14190
|
function TaxDocumentModalView({
|
|
13811
14191
|
state,
|
|
13812
14192
|
onEvent,
|
|
@@ -13815,7 +14195,7 @@ function TaxDocumentModalView({
|
|
|
13815
14195
|
if (state.type === "hidden") {
|
|
13816
14196
|
return null;
|
|
13817
14197
|
}
|
|
13818
|
-
return /* @__PURE__ */
|
|
14198
|
+
return /* @__PURE__ */ jsx105(CoinListStyleScope, { children: /* @__PURE__ */ jsx105("div", { className: "clcosdk:fixed clcosdk:inset-0 clcosdk:z-50 clcosdk:flex clcosdk:items-center clcosdk:justify-center clcosdk:bg-black/50 clcosdk:p-4", children: /* @__PURE__ */ jsxs69(
|
|
13819
14199
|
"div",
|
|
13820
14200
|
{
|
|
13821
14201
|
className: cn(
|
|
@@ -13823,11 +14203,11 @@ function TaxDocumentModalView({
|
|
|
13823
14203
|
className
|
|
13824
14204
|
),
|
|
13825
14205
|
children: [
|
|
13826
|
-
/* @__PURE__ */
|
|
13827
|
-
/* @__PURE__ */
|
|
13828
|
-
/* @__PURE__ */
|
|
14206
|
+
/* @__PURE__ */ jsxs69("div", { className: "clcosdk:flex clcosdk:items-start clcosdk:justify-between clcosdk:gap-4", children: [
|
|
14207
|
+
/* @__PURE__ */ jsx105("h3", { className: cn(typeClasses.h3, "clcosdk:text-text-primary"), children: state.title }),
|
|
14208
|
+
/* @__PURE__ */ jsx105(CloseButton, { onClick: () => onEvent({ type: "ON_CLOSE" }) })
|
|
13829
14209
|
] }),
|
|
13830
|
-
/* @__PURE__ */
|
|
14210
|
+
/* @__PURE__ */ jsx105(Screen, { screen: state.screen, onEvent })
|
|
13831
14211
|
]
|
|
13832
14212
|
}
|
|
13833
14213
|
) }) });
|
|
@@ -13838,11 +14218,11 @@ function Screen({
|
|
|
13838
14218
|
}) {
|
|
13839
14219
|
switch (screen.type) {
|
|
13840
14220
|
case "loading":
|
|
13841
|
-
return /* @__PURE__ */
|
|
14221
|
+
return /* @__PURE__ */ jsx105(LoadingScreen, {});
|
|
13842
14222
|
case "error":
|
|
13843
|
-
return /* @__PURE__ */
|
|
14223
|
+
return /* @__PURE__ */ jsx105(AlertBanner, { variant: "error", icon: true, content: screen.message });
|
|
13844
14224
|
case "review":
|
|
13845
|
-
return /* @__PURE__ */
|
|
14225
|
+
return /* @__PURE__ */ jsx105(
|
|
13846
14226
|
ReviewScreen,
|
|
13847
14227
|
{
|
|
13848
14228
|
fields: screen.fields,
|
|
@@ -13853,9 +14233,9 @@ function Screen({
|
|
|
13853
14233
|
}
|
|
13854
14234
|
);
|
|
13855
14235
|
case "editing":
|
|
13856
|
-
return /* @__PURE__ */
|
|
14236
|
+
return /* @__PURE__ */ jsx105(EditScreen, { fields: screen.fields, onEvent });
|
|
13857
14237
|
case "sign-only":
|
|
13858
|
-
return /* @__PURE__ */
|
|
14238
|
+
return /* @__PURE__ */ jsx105(
|
|
13859
14239
|
SignOnlyScreen,
|
|
13860
14240
|
{
|
|
13861
14241
|
signing: screen.signing,
|
|
@@ -13870,14 +14250,14 @@ function Screen({
|
|
|
13870
14250
|
}
|
|
13871
14251
|
}
|
|
13872
14252
|
function LoadingScreen() {
|
|
13873
|
-
return /* @__PURE__ */
|
|
14253
|
+
return /* @__PURE__ */ jsx105(
|
|
13874
14254
|
"output",
|
|
13875
14255
|
{
|
|
13876
14256
|
"aria-live": "polite",
|
|
13877
14257
|
className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-4",
|
|
13878
|
-
children: [0, 1, 2, 3, 4].map((row) => /* @__PURE__ */
|
|
13879
|
-
/* @__PURE__ */
|
|
13880
|
-
/* @__PURE__ */
|
|
14258
|
+
children: [0, 1, 2, 3, 4].map((row) => /* @__PURE__ */ jsxs69("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-1", children: [
|
|
14259
|
+
/* @__PURE__ */ jsx105("div", { className: "clcosdk:h-3 clcosdk:w-28 clcosdk:animate-pulse clcosdk:rounded clcosdk:bg-surface" }),
|
|
14260
|
+
/* @__PURE__ */ jsx105("div", { className: "clcosdk:h-5 clcosdk:w-48 clcosdk:animate-pulse clcosdk:rounded clcosdk:bg-surface" })
|
|
13881
14261
|
] }, row))
|
|
13882
14262
|
}
|
|
13883
14263
|
);
|
|
@@ -13889,9 +14269,9 @@ function ReviewScreen({
|
|
|
13889
14269
|
signError,
|
|
13890
14270
|
onEvent
|
|
13891
14271
|
}) {
|
|
13892
|
-
return /* @__PURE__ */
|
|
13893
|
-
/* @__PURE__ */
|
|
13894
|
-
piiUnavailable && /* @__PURE__ */
|
|
14272
|
+
return /* @__PURE__ */ jsxs69("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-6", children: [
|
|
14273
|
+
/* @__PURE__ */ jsx105("p", { className: cn(typeClasses.body, "clcosdk:text-text-secondary"), children: "Review your information below. If anything looks incorrect, edit before signing." }),
|
|
14274
|
+
piiUnavailable && /* @__PURE__ */ jsx105(
|
|
13895
14275
|
AlertBanner,
|
|
13896
14276
|
{
|
|
13897
14277
|
variant: "info",
|
|
@@ -13899,27 +14279,27 @@ function ReviewScreen({
|
|
|
13899
14279
|
content: "We don't have this information on file yet \u2014 please fill it in below."
|
|
13900
14280
|
}
|
|
13901
14281
|
),
|
|
13902
|
-
/* @__PURE__ */
|
|
14282
|
+
/* @__PURE__ */ jsx105("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-4 clcosdk:border-t clcosdk:border-divider clcosdk:pt-4", children: fields.map(({ field, label, displayValue }) => /* @__PURE__ */ jsxs69(
|
|
13903
14283
|
"div",
|
|
13904
14284
|
{
|
|
13905
14285
|
className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-1",
|
|
13906
14286
|
children: [
|
|
13907
|
-
/* @__PURE__ */
|
|
14287
|
+
/* @__PURE__ */ jsx105(
|
|
13908
14288
|
"span",
|
|
13909
14289
|
{
|
|
13910
14290
|
className: cn(typeClasses.label, "clcosdk:text-text-secondary"),
|
|
13911
14291
|
children: label
|
|
13912
14292
|
}
|
|
13913
14293
|
),
|
|
13914
|
-
/* @__PURE__ */
|
|
14294
|
+
/* @__PURE__ */ jsx105("span", { className: cn(typeClasses.body, "clcosdk:text-text-primary"), children: displayValue })
|
|
13915
14295
|
]
|
|
13916
14296
|
},
|
|
13917
14297
|
field
|
|
13918
14298
|
)) }),
|
|
13919
|
-
/* @__PURE__ */
|
|
13920
|
-
signError && /* @__PURE__ */
|
|
13921
|
-
/* @__PURE__ */
|
|
13922
|
-
/* @__PURE__ */
|
|
14299
|
+
/* @__PURE__ */ jsx105("p", { className: cn(typeClasses.caption, "clcosdk:text-text-secondary"), children: "By signing, you certify that the information above is accurate and that you are the beneficial owner of the income this form relates to. This document cannot be edited once signed." }),
|
|
14300
|
+
signError && /* @__PURE__ */ jsx105(AlertBanner, { variant: "error", icon: true, content: signError }),
|
|
14301
|
+
/* @__PURE__ */ jsxs69("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-2", children: [
|
|
14302
|
+
/* @__PURE__ */ jsx105(
|
|
13923
14303
|
ClButton,
|
|
13924
14304
|
{
|
|
13925
14305
|
fullWidth: true,
|
|
@@ -13929,7 +14309,7 @@ function ReviewScreen({
|
|
|
13929
14309
|
children: "Sign W-8BEN"
|
|
13930
14310
|
}
|
|
13931
14311
|
),
|
|
13932
|
-
/* @__PURE__ */
|
|
14312
|
+
/* @__PURE__ */ jsx105(
|
|
13933
14313
|
ClButton,
|
|
13934
14314
|
{
|
|
13935
14315
|
fullWidth: true,
|
|
@@ -13946,20 +14326,20 @@ function EditScreen({
|
|
|
13946
14326
|
fields,
|
|
13947
14327
|
onEvent
|
|
13948
14328
|
}) {
|
|
13949
|
-
return /* @__PURE__ */
|
|
13950
|
-
/* @__PURE__ */
|
|
14329
|
+
return /* @__PURE__ */ jsxs69("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-6", children: [
|
|
14330
|
+
/* @__PURE__ */ jsx105("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-4 clcosdk:border-t clcosdk:border-divider clcosdk:pt-4", children: fields.map(({ field, label, placeholder, value }) => /* @__PURE__ */ jsxs69(
|
|
13951
14331
|
"label",
|
|
13952
14332
|
{
|
|
13953
14333
|
className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-1",
|
|
13954
14334
|
children: [
|
|
13955
|
-
/* @__PURE__ */
|
|
14335
|
+
/* @__PURE__ */ jsx105(
|
|
13956
14336
|
"span",
|
|
13957
14337
|
{
|
|
13958
14338
|
className: cn(typeClasses.label, "clcosdk:text-text-secondary"),
|
|
13959
14339
|
children: label
|
|
13960
14340
|
}
|
|
13961
14341
|
),
|
|
13962
|
-
/* @__PURE__ */
|
|
14342
|
+
/* @__PURE__ */ jsx105(
|
|
13963
14343
|
"input",
|
|
13964
14344
|
{
|
|
13965
14345
|
type: "text",
|
|
@@ -13980,9 +14360,9 @@ function EditScreen({
|
|
|
13980
14360
|
},
|
|
13981
14361
|
field
|
|
13982
14362
|
)) }),
|
|
13983
|
-
/* @__PURE__ */
|
|
13984
|
-
/* @__PURE__ */
|
|
13985
|
-
/* @__PURE__ */
|
|
14363
|
+
/* @__PURE__ */ jsxs69("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-2", children: [
|
|
14364
|
+
/* @__PURE__ */ jsx105(ClButton, { fullWidth: true, onClick: () => onEvent({ type: "ON_SAVE_EDIT" }), children: "Save & review" }),
|
|
14365
|
+
/* @__PURE__ */ jsx105(
|
|
13986
14366
|
ClButton,
|
|
13987
14367
|
{
|
|
13988
14368
|
fullWidth: true,
|
|
@@ -13999,10 +14379,10 @@ function SignOnlyScreen({
|
|
|
13999
14379
|
signError,
|
|
14000
14380
|
onEvent
|
|
14001
14381
|
}) {
|
|
14002
|
-
return /* @__PURE__ */
|
|
14003
|
-
/* @__PURE__ */
|
|
14004
|
-
signError && /* @__PURE__ */
|
|
14005
|
-
/* @__PURE__ */
|
|
14382
|
+
return /* @__PURE__ */ jsxs69("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-6", children: [
|
|
14383
|
+
/* @__PURE__ */ jsx105("p", { className: cn(typeClasses.body, "clcosdk:text-text-secondary"), children: "As an entity investor, you must complete a W-8BEN-E to confirm your foreign tax status and claim applicable treaty benefits. You'll receive an email to complete the signing." }),
|
|
14384
|
+
signError && /* @__PURE__ */ jsx105(AlertBanner, { variant: "error", icon: true, content: signError }),
|
|
14385
|
+
/* @__PURE__ */ jsx105(
|
|
14006
14386
|
ClButton,
|
|
14007
14387
|
{
|
|
14008
14388
|
fullWidth: true,
|
|
@@ -14016,10 +14396,10 @@ function SignOnlyScreen({
|
|
|
14016
14396
|
}
|
|
14017
14397
|
|
|
14018
14398
|
// src/client/hooks/requirements/tax-document/useTaxDocumentModalViewModel.ts
|
|
14019
|
-
import { useCallback as
|
|
14399
|
+
import { useCallback as useCallback14, useEffect as useEffect23, useMemo as useMemo13 } from "react";
|
|
14020
14400
|
|
|
14021
14401
|
// src/client/hooks/requirements/data/useTaxDocument.ts
|
|
14022
|
-
import { useCallback as
|
|
14402
|
+
import { useCallback as useCallback13, useEffect as useEffect22, useState as useState34 } from "react";
|
|
14023
14403
|
var IDLE_SIGN = { type: "idle", error: null };
|
|
14024
14404
|
var LOADING_STATE3 = { type: "LOADING" };
|
|
14025
14405
|
var SIGN_FAILED_MESSAGE = "Unable to sign document. Please try again.";
|
|
@@ -14094,7 +14474,7 @@ function useTaxDocument({
|
|
|
14094
14474
|
}) {
|
|
14095
14475
|
const { coinlist, isReady } = useCoinList();
|
|
14096
14476
|
const log = useLogger("useTaxDocument");
|
|
14097
|
-
const [state, setState] =
|
|
14477
|
+
const [state, setState] = useState34(LOADING_STATE3);
|
|
14098
14478
|
useEffect22(() => {
|
|
14099
14479
|
let isCancelled = false;
|
|
14100
14480
|
if (!isOpen) {
|
|
@@ -14136,7 +14516,7 @@ function useTaxDocument({
|
|
|
14136
14516
|
isCancelled = true;
|
|
14137
14517
|
};
|
|
14138
14518
|
}, [coinlist, isReady, isOpen, log]);
|
|
14139
|
-
const onEditField =
|
|
14519
|
+
const onEditField = useCallback13(
|
|
14140
14520
|
(field, value) => {
|
|
14141
14521
|
setState(
|
|
14142
14522
|
(prev) => prev.type === "EDITING" ? { ...prev, fields: { ...prev.fields, [field]: value } } : prev
|
|
@@ -14144,7 +14524,7 @@ function useTaxDocument({
|
|
|
14144
14524
|
},
|
|
14145
14525
|
[]
|
|
14146
14526
|
);
|
|
14147
|
-
const onStartEdit =
|
|
14527
|
+
const onStartEdit = useCallback13(() => {
|
|
14148
14528
|
setState(
|
|
14149
14529
|
(prev) => prev.type === "REVIEW" ? {
|
|
14150
14530
|
type: "EDITING",
|
|
@@ -14155,7 +14535,7 @@ function useTaxDocument({
|
|
|
14155
14535
|
} : prev
|
|
14156
14536
|
);
|
|
14157
14537
|
}, []);
|
|
14158
|
-
const onSaveEdit =
|
|
14538
|
+
const onSaveEdit = useCallback13(() => {
|
|
14159
14539
|
setState(
|
|
14160
14540
|
(prev) => prev.type === "EDITING" ? {
|
|
14161
14541
|
type: "REVIEW",
|
|
@@ -14166,7 +14546,7 @@ function useTaxDocument({
|
|
|
14166
14546
|
} : prev
|
|
14167
14547
|
);
|
|
14168
14548
|
}, []);
|
|
14169
|
-
const onCancelEdit =
|
|
14549
|
+
const onCancelEdit = useCallback13(() => {
|
|
14170
14550
|
setState(
|
|
14171
14551
|
(prev) => prev.type === "EDITING" ? {
|
|
14172
14552
|
type: "REVIEW",
|
|
@@ -14177,7 +14557,7 @@ function useTaxDocument({
|
|
|
14177
14557
|
} : prev
|
|
14178
14558
|
);
|
|
14179
14559
|
}, []);
|
|
14180
|
-
const onSign =
|
|
14560
|
+
const onSign = useCallback13(() => {
|
|
14181
14561
|
if (state.type !== "REVIEW" && state.type !== "SIGN_ONLY") return;
|
|
14182
14562
|
if (state.type === "REVIEW" && state.fields.dob.trim() !== "" && !isValidUsDate(state.fields.dob)) {
|
|
14183
14563
|
setState({
|
|
@@ -14231,7 +14611,7 @@ function useTaxDocumentModalViewModel({
|
|
|
14231
14611
|
}
|
|
14232
14612
|
return { type: "content", title: toTitle(state), screen: toScreen(state) };
|
|
14233
14613
|
}, [isOpen, state]);
|
|
14234
|
-
const onEvent =
|
|
14614
|
+
const onEvent = useCallback14(
|
|
14235
14615
|
(event) => {
|
|
14236
14616
|
switch (event.type) {
|
|
14237
14617
|
case "ON_CLOSE":
|
|
@@ -14314,7 +14694,7 @@ function toFieldsUi(fields) {
|
|
|
14314
14694
|
}
|
|
14315
14695
|
|
|
14316
14696
|
// src/client/components/requirements/tax-document/TaxDocumentModalContainer.tsx
|
|
14317
|
-
import { jsx as
|
|
14697
|
+
import { jsx as jsx106 } from "react/jsx-runtime";
|
|
14318
14698
|
function TaxDocumentModalContainer({
|
|
14319
14699
|
isOpen,
|
|
14320
14700
|
onClose,
|
|
@@ -14326,7 +14706,7 @@ function TaxDocumentModalContainer({
|
|
|
14326
14706
|
onClose,
|
|
14327
14707
|
onSubmitted
|
|
14328
14708
|
});
|
|
14329
|
-
return /* @__PURE__ */
|
|
14709
|
+
return /* @__PURE__ */ jsx106(
|
|
14330
14710
|
TaxDocumentModalView,
|
|
14331
14711
|
{
|
|
14332
14712
|
state,
|
|
@@ -14337,26 +14717,26 @@ function TaxDocumentModalContainer({
|
|
|
14337
14717
|
}
|
|
14338
14718
|
|
|
14339
14719
|
// src/client/components/requirements/VerificationOverlay.tsx
|
|
14340
|
-
import { jsx as
|
|
14720
|
+
import { jsx as jsx107, jsxs as jsxs70 } from "react/jsx-runtime";
|
|
14341
14721
|
function VerificationOverlay({
|
|
14342
14722
|
onClose,
|
|
14343
14723
|
children
|
|
14344
14724
|
}) {
|
|
14345
|
-
return /* @__PURE__ */
|
|
14725
|
+
return /* @__PURE__ */ jsx107(CoinListStyleScope, { children: /* @__PURE__ */ jsx107(VerificationOverlayBody, { onClose, children }) });
|
|
14346
14726
|
}
|
|
14347
14727
|
function VerificationOverlayBody({
|
|
14348
14728
|
onClose,
|
|
14349
14729
|
children
|
|
14350
14730
|
}) {
|
|
14351
|
-
return /* @__PURE__ */
|
|
14731
|
+
return /* @__PURE__ */ jsx107(
|
|
14352
14732
|
"div",
|
|
14353
14733
|
{
|
|
14354
14734
|
role: "dialog",
|
|
14355
14735
|
"aria-modal": "true",
|
|
14356
14736
|
"aria-label": "Identity verification",
|
|
14357
14737
|
className: "clcosdk:fixed clcosdk:inset-0 clcosdk:z-50 clcosdk:flex clcosdk:items-center clcosdk:justify-center clcosdk:bg-overlay clcosdk:p-4",
|
|
14358
|
-
children: /* @__PURE__ */
|
|
14359
|
-
/* @__PURE__ */
|
|
14738
|
+
children: /* @__PURE__ */ jsxs70("div", { className: "clcosdk:relative clcosdk:flex clcosdk:max-h-[92vh] clcosdk:w-full clcosdk:max-w-[760px] clcosdk:flex-col clcosdk:overflow-y-auto clcosdk:rounded-2xl clcosdk:bg-background clcosdk:p-6 clcosdk:pt-14", children: [
|
|
14739
|
+
/* @__PURE__ */ jsx107(
|
|
14360
14740
|
CloseButton,
|
|
14361
14741
|
{
|
|
14362
14742
|
onClick: onClose,
|
|
@@ -14371,7 +14751,7 @@ function VerificationOverlayBody({
|
|
|
14371
14751
|
|
|
14372
14752
|
// src/client/components/requirements/wallet/ConnectWalletModalView.tsx
|
|
14373
14753
|
import { useId as useId5 } from "react";
|
|
14374
|
-
import { jsx as
|
|
14754
|
+
import { jsx as jsx108, jsxs as jsxs71 } from "react/jsx-runtime";
|
|
14375
14755
|
function ConnectWalletModalView({
|
|
14376
14756
|
state,
|
|
14377
14757
|
onEvent,
|
|
@@ -14381,7 +14761,7 @@ function ConnectWalletModalView({
|
|
|
14381
14761
|
if (state.type === "hidden") {
|
|
14382
14762
|
return null;
|
|
14383
14763
|
}
|
|
14384
|
-
return /* @__PURE__ */
|
|
14764
|
+
return /* @__PURE__ */ jsx108(CoinListStyleScope, { children: /* @__PURE__ */ jsx108("div", { className: "clcosdk:fixed clcosdk:inset-0 clcosdk:z-50 clcosdk:flex clcosdk:items-center clcosdk:justify-center clcosdk:bg-black/50 clcosdk:p-4", children: /* @__PURE__ */ jsxs71(
|
|
14385
14765
|
"div",
|
|
14386
14766
|
{
|
|
14387
14767
|
role: "dialog",
|
|
@@ -14392,8 +14772,8 @@ function ConnectWalletModalView({
|
|
|
14392
14772
|
className
|
|
14393
14773
|
),
|
|
14394
14774
|
children: [
|
|
14395
|
-
/* @__PURE__ */
|
|
14396
|
-
/* @__PURE__ */
|
|
14775
|
+
/* @__PURE__ */ jsxs71("div", { className: "clcosdk:flex clcosdk:items-start clcosdk:justify-between clcosdk:gap-4", children: [
|
|
14776
|
+
/* @__PURE__ */ jsx108(
|
|
14397
14777
|
"h3",
|
|
14398
14778
|
{
|
|
14399
14779
|
id: titleId,
|
|
@@ -14401,9 +14781,9 @@ function ConnectWalletModalView({
|
|
|
14401
14781
|
children: "Connect your wallet"
|
|
14402
14782
|
}
|
|
14403
14783
|
),
|
|
14404
|
-
/* @__PURE__ */
|
|
14784
|
+
/* @__PURE__ */ jsx108(CloseButton, { onClick: () => onEvent({ type: "ON_CLOSE" }) })
|
|
14405
14785
|
] }),
|
|
14406
|
-
/* @__PURE__ */
|
|
14786
|
+
/* @__PURE__ */ jsx108(
|
|
14407
14787
|
Screen2,
|
|
14408
14788
|
{
|
|
14409
14789
|
screen: state.screen,
|
|
@@ -14422,9 +14802,9 @@ function Screen2({
|
|
|
14422
14802
|
}) {
|
|
14423
14803
|
switch (screen.type) {
|
|
14424
14804
|
case "needs-wallet":
|
|
14425
|
-
return /* @__PURE__ */
|
|
14426
|
-
/* @__PURE__ */
|
|
14427
|
-
canRequestConnect && /* @__PURE__ */
|
|
14805
|
+
return /* @__PURE__ */ jsxs71("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-6", children: [
|
|
14806
|
+
/* @__PURE__ */ jsx108("p", { className: cn(typeClasses.body, "clcosdk:text-text-secondary"), children: "Connect an external wallet to prove ownership and bind it to this offer." }),
|
|
14807
|
+
canRequestConnect && /* @__PURE__ */ jsx108(
|
|
14428
14808
|
ClButton,
|
|
14429
14809
|
{
|
|
14430
14810
|
fullWidth: true,
|
|
@@ -14434,23 +14814,23 @@ function Screen2({
|
|
|
14434
14814
|
)
|
|
14435
14815
|
] });
|
|
14436
14816
|
case "ready":
|
|
14437
|
-
return /* @__PURE__ */
|
|
14438
|
-
/* @__PURE__ */
|
|
14439
|
-
/* @__PURE__ */
|
|
14440
|
-
/* @__PURE__ */
|
|
14817
|
+
return /* @__PURE__ */ jsxs71("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-6", children: [
|
|
14818
|
+
/* @__PURE__ */ jsx108("p", { className: cn(typeClasses.body, "clcosdk:text-text-secondary"), children: "Sign a message with your connected wallet to prove you own it. This does not cost gas or move any funds." }),
|
|
14819
|
+
/* @__PURE__ */ jsxs71("div", { className: "clcosdk:flex clcosdk:flex-col clcosdk:gap-1 clcosdk:border-t clcosdk:border-divider clcosdk:pt-4", children: [
|
|
14820
|
+
/* @__PURE__ */ jsx108(
|
|
14441
14821
|
"span",
|
|
14442
14822
|
{
|
|
14443
14823
|
className: cn(typeClasses.label, "clcosdk:text-text-secondary"),
|
|
14444
14824
|
children: "Wallet address"
|
|
14445
14825
|
}
|
|
14446
14826
|
),
|
|
14447
|
-
/* @__PURE__ */
|
|
14827
|
+
/* @__PURE__ */ jsx108("span", { className: cn(typeClasses.body, "clcosdk:text-text-primary"), children: screen.shortAddress })
|
|
14448
14828
|
] }),
|
|
14449
14829
|
screen.signError && // Live region: the error is inserted async after a failed attempt,
|
|
14450
14830
|
// so screen readers need it announced rather than silently
|
|
14451
14831
|
// rendered.
|
|
14452
|
-
/* @__PURE__ */
|
|
14453
|
-
/* @__PURE__ */
|
|
14832
|
+
/* @__PURE__ */ jsx108("div", { role: "alert", children: /* @__PURE__ */ jsx108(AlertBanner, { variant: "error", icon: true, content: screen.signError }) }),
|
|
14833
|
+
/* @__PURE__ */ jsx108(
|
|
14454
14834
|
ClButton,
|
|
14455
14835
|
{
|
|
14456
14836
|
fullWidth: true,
|
|
@@ -14461,7 +14841,7 @@ function Screen2({
|
|
|
14461
14841
|
children: "Sign & connect"
|
|
14462
14842
|
}
|
|
14463
14843
|
),
|
|
14464
|
-
canRequestConnect && /* @__PURE__ */
|
|
14844
|
+
canRequestConnect && /* @__PURE__ */ jsx108(
|
|
14465
14845
|
ClButton,
|
|
14466
14846
|
{
|
|
14467
14847
|
fullWidth: true,
|
|
@@ -14480,10 +14860,10 @@ function Screen2({
|
|
|
14480
14860
|
}
|
|
14481
14861
|
|
|
14482
14862
|
// src/client/hooks/requirements/wallet/useConnectWalletModalViewModel.ts
|
|
14483
|
-
import { useCallback as
|
|
14863
|
+
import { useCallback as useCallback16, useEffect as useEffect25, useMemo as useMemo14 } from "react";
|
|
14484
14864
|
|
|
14485
14865
|
// src/client/hooks/requirements/data/useConnectWallet.ts
|
|
14486
|
-
import { useCallback as
|
|
14866
|
+
import { useCallback as useCallback15, useEffect as useEffect24, useRef as useRef15, useState as useState35 } from "react";
|
|
14487
14867
|
var IDLE_SIGN2 = { type: "idle", error: null };
|
|
14488
14868
|
var ERROR_COPY2 = {
|
|
14489
14869
|
not_authenticated: "Sign in to connect your wallet.",
|
|
@@ -14508,10 +14888,10 @@ function useConnectWallet({
|
|
|
14508
14888
|
statement
|
|
14509
14889
|
}) {
|
|
14510
14890
|
const { coinlist } = useCoinList();
|
|
14511
|
-
const [state, setState] =
|
|
14891
|
+
const [state, setState] = useState35(
|
|
14512
14892
|
() => wallet ? { type: "READY", address: wallet.address, sign: IDLE_SIGN2 } : { type: "NEEDS_WALLET" }
|
|
14513
14893
|
);
|
|
14514
|
-
const attempt =
|
|
14894
|
+
const attempt = useRef15(0);
|
|
14515
14895
|
useEffect24(() => {
|
|
14516
14896
|
attempt.current += 1;
|
|
14517
14897
|
if (!isOpen) return;
|
|
@@ -14525,7 +14905,7 @@ function useConnectWallet({
|
|
|
14525
14905
|
},
|
|
14526
14906
|
[]
|
|
14527
14907
|
);
|
|
14528
|
-
const onSign =
|
|
14908
|
+
const onSign = useCallback15(() => {
|
|
14529
14909
|
if (!wallet || state.type !== "READY") return;
|
|
14530
14910
|
attempt.current += 1;
|
|
14531
14911
|
const gen = attempt.current;
|
|
@@ -14617,7 +14997,7 @@ function useConnectWalletModalViewModel({
|
|
|
14617
14997
|
canRequestConnect
|
|
14618
14998
|
};
|
|
14619
14999
|
}, [isOpen, state, onRequestConnect]);
|
|
14620
|
-
const onEvent =
|
|
15000
|
+
const onEvent = useCallback16(
|
|
14621
15001
|
(event) => {
|
|
14622
15002
|
switch (event.type) {
|
|
14623
15003
|
case "ON_CLOSE":
|
|
@@ -14641,13 +15021,13 @@ function useConnectWalletModalViewModel({
|
|
|
14641
15021
|
}
|
|
14642
15022
|
|
|
14643
15023
|
// src/client/components/requirements/wallet/ConnectWalletModalContainer.tsx
|
|
14644
|
-
import { jsx as
|
|
15024
|
+
import { jsx as jsx109 } from "react/jsx-runtime";
|
|
14645
15025
|
function ConnectWalletModalContainer({
|
|
14646
15026
|
className,
|
|
14647
15027
|
...options
|
|
14648
15028
|
}) {
|
|
14649
15029
|
const { state, onEvent } = useConnectWalletModalViewModel(options);
|
|
14650
|
-
return /* @__PURE__ */
|
|
15030
|
+
return /* @__PURE__ */ jsx109(
|
|
14651
15031
|
ConnectWalletModalView,
|
|
14652
15032
|
{
|
|
14653
15033
|
state,
|
|
@@ -14658,10 +15038,10 @@ function ConnectWalletModalContainer({
|
|
|
14658
15038
|
}
|
|
14659
15039
|
|
|
14660
15040
|
// src/client/hooks/requirements/useRequirementsChecklistViewModel.ts
|
|
14661
|
-
import { useCallback as
|
|
15041
|
+
import { useCallback as useCallback19, useEffect as useEffect28, useMemo as useMemo15, useRef as useRef16, useState as useState38 } from "react";
|
|
14662
15042
|
|
|
14663
15043
|
// src/client/hooks/requirements/data/useOptionAddresses.ts
|
|
14664
|
-
import { useCallback as
|
|
15044
|
+
import { useCallback as useCallback17, useEffect as useEffect26, useState as useState36 } from "react";
|
|
14665
15045
|
var LOADING_STATE4 = { type: "LOADING" };
|
|
14666
15046
|
var EMPTY_STATE = {
|
|
14667
15047
|
type: "CONTENT",
|
|
@@ -14671,12 +15051,12 @@ function useOptionAddresses(offerId, offerOptionId, options = {}) {
|
|
|
14671
15051
|
const { coinlist, isReady } = useCoinList();
|
|
14672
15052
|
const log = useLogger("useOptionAddresses");
|
|
14673
15053
|
const { data, enabled = true } = options;
|
|
14674
|
-
const [addressesState, setAddressesState] =
|
|
15054
|
+
const [addressesState, setAddressesState] = useState36(
|
|
14675
15055
|
data !== void 0 ? { type: "CONTENT", addresses: data } : LOADING_STATE4
|
|
14676
15056
|
);
|
|
14677
|
-
const [fetchKey, setFetchKey] =
|
|
14678
|
-
const refetch =
|
|
14679
|
-
const disconnect =
|
|
15057
|
+
const [fetchKey, setFetchKey] = useState36(0);
|
|
15058
|
+
const refetch = useCallback17(() => setFetchKey((k) => k + 1), []);
|
|
15059
|
+
const disconnect = useCallback17(
|
|
14680
15060
|
async (addressId) => {
|
|
14681
15061
|
await coinlist.wallets.remove({ offerId, addressId });
|
|
14682
15062
|
refetch();
|
|
@@ -14739,17 +15119,17 @@ function useOptionAddresses(offerId, offerOptionId, options = {}) {
|
|
|
14739
15119
|
}
|
|
14740
15120
|
|
|
14741
15121
|
// src/client/hooks/requirements/data/useRequirements.ts
|
|
14742
|
-
import { useCallback as
|
|
15122
|
+
import { useCallback as useCallback18, useEffect as useEffect27, useState as useState37 } from "react";
|
|
14743
15123
|
var LOADING_STATE5 = { type: "LOADING" };
|
|
14744
15124
|
function useRequirements(offerId, options = {}) {
|
|
14745
15125
|
const { coinlist, isReady } = useCoinList();
|
|
14746
15126
|
const log = useLogger("useRequirements");
|
|
14747
15127
|
const { data, enabled = true } = options;
|
|
14748
|
-
const [requirementsState, setRequirementsState] =
|
|
15128
|
+
const [requirementsState, setRequirementsState] = useState37(
|
|
14749
15129
|
data !== void 0 ? { type: "CONTENT", ...data } : LOADING_STATE5
|
|
14750
15130
|
);
|
|
14751
|
-
const [fetchKey, setFetchKey] =
|
|
14752
|
-
const refetch =
|
|
15131
|
+
const [fetchKey, setFetchKey] = useState37(0);
|
|
15132
|
+
const refetch = useCallback18(() => setFetchKey((k) => k + 1), []);
|
|
14753
15133
|
useEffect27(() => {
|
|
14754
15134
|
let isCancelled = false;
|
|
14755
15135
|
if (!enabled) {
|
|
@@ -14944,18 +15324,18 @@ function useRequirementsChecklistViewModel(options) {
|
|
|
14944
15324
|
data,
|
|
14945
15325
|
enabled
|
|
14946
15326
|
});
|
|
14947
|
-
const [expandedId, setExpandedId] =
|
|
14948
|
-
const [taxDocumentOpen, setTaxDocumentOpen] =
|
|
14949
|
-
const [connectWalletOpen, setConnectWalletOpen] =
|
|
14950
|
-
const [verifyingRequirementId, setVerifyingRequirementId] =
|
|
14951
|
-
const isMountedRef =
|
|
15327
|
+
const [expandedId, setExpandedId] = useState38(null);
|
|
15328
|
+
const [taxDocumentOpen, setTaxDocumentOpen] = useState38(false);
|
|
15329
|
+
const [connectWalletOpen, setConnectWalletOpen] = useState38(false);
|
|
15330
|
+
const [verifyingRequirementId, setVerifyingRequirementId] = useState38(null);
|
|
15331
|
+
const isMountedRef = useRef16(true);
|
|
14952
15332
|
useEffect28(() => {
|
|
14953
15333
|
isMountedRef.current = true;
|
|
14954
15334
|
return () => {
|
|
14955
15335
|
isMountedRef.current = false;
|
|
14956
15336
|
};
|
|
14957
15337
|
}, []);
|
|
14958
|
-
const [hasWalletRequirement, setHasWalletRequirement] =
|
|
15338
|
+
const [hasWalletRequirement, setHasWalletRequirement] = useState38(false);
|
|
14959
15339
|
useEffect28(() => {
|
|
14960
15340
|
if (requirementsState.type === "CONTENT") {
|
|
14961
15341
|
setHasWalletRequirement(
|
|
@@ -14972,14 +15352,14 @@ function useRequirementsChecklistViewModel(options) {
|
|
|
14972
15352
|
} = useOptionAddresses(offerId, optionId, {
|
|
14973
15353
|
enabled: enabled && hasWalletRequirement
|
|
14974
15354
|
});
|
|
14975
|
-
const removeWallet =
|
|
15355
|
+
const removeWallet = useCallback19(
|
|
14976
15356
|
async (addressId) => {
|
|
14977
15357
|
await disconnect(OfferOptionAddressId(addressId));
|
|
14978
15358
|
refetch();
|
|
14979
15359
|
},
|
|
14980
15360
|
[disconnect, refetch]
|
|
14981
15361
|
);
|
|
14982
|
-
const awaitVerificationResult =
|
|
15362
|
+
const awaitVerificationResult = useCallback19(
|
|
14983
15363
|
(requirementId, statusBeforeSubmit) => {
|
|
14984
15364
|
void (async () => {
|
|
14985
15365
|
const deadline = Date.now() + VERIFICATION_POLL_TIMEOUT_MS;
|
|
@@ -15088,7 +15468,7 @@ function useRequirementsChecklistViewModel(options) {
|
|
|
15088
15468
|
identityVerificationOptions,
|
|
15089
15469
|
removeWallet
|
|
15090
15470
|
]);
|
|
15091
|
-
const handleRequirementAction =
|
|
15471
|
+
const handleRequirementAction = useCallback19(
|
|
15092
15472
|
(requirement) => {
|
|
15093
15473
|
const inlineVerification = statusById.get(requirement.id)?.kycLevel !== void 0 && onRequirementActionOverride === void 0;
|
|
15094
15474
|
if (inlineVerification) {
|
|
@@ -15120,7 +15500,7 @@ function useRequirementsChecklistViewModel(options) {
|
|
|
15120
15500
|
coinlist
|
|
15121
15501
|
]
|
|
15122
15502
|
);
|
|
15123
|
-
const onEvent =
|
|
15503
|
+
const onEvent = useCallback19(
|
|
15124
15504
|
(event) => {
|
|
15125
15505
|
switch (event.type) {
|
|
15126
15506
|
case "ON_TOGGLE_ITEM":
|
|
@@ -15218,7 +15598,7 @@ function toVerificationUi(verifyingRequirementId, statusById, identityVerificati
|
|
|
15218
15598
|
}
|
|
15219
15599
|
|
|
15220
15600
|
// src/client/components/requirements/RequirementsChecklistContainer.tsx
|
|
15221
|
-
import { Fragment as Fragment16, jsx as
|
|
15601
|
+
import { Fragment as Fragment16, jsx as jsx110, jsxs as jsxs72 } from "react/jsx-runtime";
|
|
15222
15602
|
function RequirementsChecklistContainer({
|
|
15223
15603
|
loading,
|
|
15224
15604
|
error,
|
|
@@ -15230,8 +15610,8 @@ function RequirementsChecklistContainer({
|
|
|
15230
15610
|
...options,
|
|
15231
15611
|
enabled
|
|
15232
15612
|
});
|
|
15233
|
-
return /* @__PURE__ */
|
|
15234
|
-
/* @__PURE__ */
|
|
15613
|
+
return /* @__PURE__ */ jsxs72(Fragment16, { children: [
|
|
15614
|
+
/* @__PURE__ */ jsx110(
|
|
15235
15615
|
RequirementsChecklistView,
|
|
15236
15616
|
{
|
|
15237
15617
|
state,
|
|
@@ -15241,8 +15621,8 @@ function RequirementsChecklistContainer({
|
|
|
15241
15621
|
className
|
|
15242
15622
|
}
|
|
15243
15623
|
),
|
|
15244
|
-
state.type === "content" && /* @__PURE__ */
|
|
15245
|
-
/* @__PURE__ */
|
|
15624
|
+
state.type === "content" && /* @__PURE__ */ jsxs72(Fragment16, { children: [
|
|
15625
|
+
/* @__PURE__ */ jsx110(
|
|
15246
15626
|
TaxDocumentModalContainer,
|
|
15247
15627
|
{
|
|
15248
15628
|
isOpen: state.taxDocumentOpen,
|
|
@@ -15250,11 +15630,11 @@ function RequirementsChecklistContainer({
|
|
|
15250
15630
|
onSubmitted: () => onEvent({ type: "ON_TAX_DOCUMENT_SUBMITTED" })
|
|
15251
15631
|
}
|
|
15252
15632
|
),
|
|
15253
|
-
state.verification && /* @__PURE__ */
|
|
15633
|
+
state.verification && /* @__PURE__ */ jsx110(
|
|
15254
15634
|
VerificationOverlay,
|
|
15255
15635
|
{
|
|
15256
15636
|
onClose: () => onEvent({ type: "ON_CLOSE_VERIFICATION" }),
|
|
15257
|
-
children: /* @__PURE__ */
|
|
15637
|
+
children: /* @__PURE__ */ jsx110(
|
|
15258
15638
|
IdentityVerificationContainer,
|
|
15259
15639
|
{
|
|
15260
15640
|
levelName: state.verification.levelName,
|
|
@@ -15265,7 +15645,7 @@ function RequirementsChecklistContainer({
|
|
|
15265
15645
|
)
|
|
15266
15646
|
}
|
|
15267
15647
|
),
|
|
15268
|
-
/* @__PURE__ */
|
|
15648
|
+
/* @__PURE__ */ jsx110(
|
|
15269
15649
|
ConnectWalletModalContainer,
|
|
15270
15650
|
{
|
|
15271
15651
|
isOpen: state.connectWalletOpen,
|
|
@@ -15298,17 +15678,17 @@ function pinoClientLogger(options) {
|
|
|
15298
15678
|
}
|
|
15299
15679
|
|
|
15300
15680
|
// src/client/hooks/auth/useCompleteOAuth.ts
|
|
15301
|
-
import { useEffect as useEffect29, useRef as
|
|
15681
|
+
import { useEffect as useEffect29, useRef as useRef17 } from "react";
|
|
15302
15682
|
function useCompleteOAuth(options) {
|
|
15303
15683
|
const { coinlist } = useCoinList();
|
|
15304
15684
|
const log = useLogger("useCompleteOAuth");
|
|
15305
|
-
const postOAuthCompleteRef =
|
|
15306
|
-
const onFailureRef =
|
|
15307
|
-
const onSuccessRef =
|
|
15685
|
+
const postOAuthCompleteRef = useRef17(options.postOAuthComplete);
|
|
15686
|
+
const onFailureRef = useRef17(options.onFailure);
|
|
15687
|
+
const onSuccessRef = useRef17(options.onSuccess);
|
|
15308
15688
|
postOAuthCompleteRef.current = options.postOAuthComplete;
|
|
15309
15689
|
onFailureRef.current = options.onFailure;
|
|
15310
15690
|
onSuccessRef.current = options.onSuccess;
|
|
15311
|
-
const hasStartedExchangeRef =
|
|
15691
|
+
const hasStartedExchangeRef = useRef17(false);
|
|
15312
15692
|
useEffect29(() => {
|
|
15313
15693
|
if (typeof window === "undefined") return;
|
|
15314
15694
|
const params = new URLSearchParams(window.location.search);
|
|
@@ -15373,13 +15753,13 @@ function useCompleteOAuth(options) {
|
|
|
15373
15753
|
}
|
|
15374
15754
|
|
|
15375
15755
|
// src/client/hooks/offers/data/useOfferDetails.ts
|
|
15376
|
-
import { useEffect as useEffect30, useState as
|
|
15756
|
+
import { useEffect as useEffect30, useState as useState39 } from "react";
|
|
15377
15757
|
var LOADING_STATE6 = { type: "LOADING" };
|
|
15378
15758
|
function useOfferDetails(offerId, options = {}) {
|
|
15379
15759
|
const { coinlist, isReady } = useCoinList();
|
|
15380
15760
|
const log = useLogger("useOfferDetails");
|
|
15381
15761
|
const { data, enabled = true } = options;
|
|
15382
|
-
const [offerDetailsState, setOfferDetailsState] =
|
|
15762
|
+
const [offerDetailsState, setOfferDetailsState] = useState39(
|
|
15383
15763
|
data !== void 0 ? { type: "CONTENT", offerDetail: data } : LOADING_STATE6
|
|
15384
15764
|
);
|
|
15385
15765
|
useEffect30(() => {
|
|
@@ -15449,29 +15829,6 @@ var OfferAssetCardUi = {
|
|
|
15449
15829
|
logo: OfferLogoUi.fromOffer(detail, tokenMetadata)
|
|
15450
15830
|
})
|
|
15451
15831
|
};
|
|
15452
|
-
|
|
15453
|
-
// src/client/hooks/providers/checkout/coin-list/token-sale/data/useParticipations.ts
|
|
15454
|
-
import { useMemo as useMemo16 } from "react";
|
|
15455
|
-
function useParticipations(offerId, options = {}) {
|
|
15456
|
-
const { coinlist, isReady } = useCoinList();
|
|
15457
|
-
const log = useLogger("useParticipations");
|
|
15458
|
-
const { data, enabled = true } = options;
|
|
15459
|
-
const { state, refetch } = useLoadOnce({
|
|
15460
|
-
key: offerId ?? "",
|
|
15461
|
-
enabled,
|
|
15462
|
-
ready: isReady,
|
|
15463
|
-
load: () => coinlist.tokenSale.list(offerId),
|
|
15464
|
-
seed: data,
|
|
15465
|
-
classify: loadErrorReason,
|
|
15466
|
-
log,
|
|
15467
|
-
describe: (participations) => ({ count: participations.length })
|
|
15468
|
-
});
|
|
15469
|
-
const participationsState = useMemo16(
|
|
15470
|
-
() => state.type === "CONTENT" ? { type: "CONTENT", participations: state.value } : state,
|
|
15471
|
-
[state]
|
|
15472
|
-
);
|
|
15473
|
-
return { participationsState, refetch };
|
|
15474
|
-
}
|
|
15475
15832
|
export {
|
|
15476
15833
|
ChecklistStatus,
|
|
15477
15834
|
CheckoutAssetUi,
|
|
@@ -15501,6 +15858,8 @@ export {
|
|
|
15501
15858
|
OfferSaleCard,
|
|
15502
15859
|
OfferSaleCardUi,
|
|
15503
15860
|
OffersGridContainer,
|
|
15861
|
+
ParticipationRowUi,
|
|
15862
|
+
ParticipationStatusUi,
|
|
15504
15863
|
RequirementItemUi,
|
|
15505
15864
|
RequirementStatus,
|
|
15506
15865
|
RequirementVariant,
|
|
@@ -15528,6 +15887,8 @@ export {
|
|
|
15528
15887
|
useCoinList,
|
|
15529
15888
|
useCoinListSignInCardViewModel,
|
|
15530
15889
|
useCoinListTokenSaleCheckoutViewModel,
|
|
15890
|
+
useCoinListTokenSaleClaimViewModel,
|
|
15891
|
+
useCoinListTokenSaleParticipations,
|
|
15531
15892
|
useCompleteOAuth,
|
|
15532
15893
|
useConnectWallet,
|
|
15533
15894
|
useErc20Balance,
|
|
@@ -15544,7 +15905,6 @@ export {
|
|
|
15544
15905
|
useOndoSellTransaction,
|
|
15545
15906
|
useOndoTradingStatus,
|
|
15546
15907
|
useOptionAddresses,
|
|
15547
|
-
useParticipations,
|
|
15548
15908
|
useRequirements,
|
|
15549
15909
|
useRequirementsChecklistViewModel,
|
|
15550
15910
|
useSuperstateReviewViewModel,
|