@rhinestone/deposit-modal 0.19.0 → 0.20.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +154 -61
- package/dist/BankOnrampStep-3SNUX6V2.cjs +435 -0
- package/dist/BankOnrampStep-4D24HVHV.mjs +435 -0
- package/dist/{DepositModalReown-UITYXJ6W.cjs → DepositModalReown-7EHOJTFW.cjs} +21 -20
- package/dist/{DepositModalReown-XBNY6QCI.mjs → DepositModalReown-SYQ2SCHC.mjs} +6 -5
- package/dist/WithdrawModal-LLJLEYXZ.cjs +12 -0
- package/dist/WithdrawModal-LXDIT4UV.mjs +12 -0
- package/dist/{bearer-transport-CVHNBgoV.d.cts → bearer-transport-DZyeDG64.d.cts} +5 -1
- package/dist/{bearer-transport-CVHNBgoV.d.ts → bearer-transport-DZyeDG64.d.ts} +5 -1
- package/dist/{caip-BMi-9t09.d.cts → caip-nwFFL46o.d.cts} +2 -2
- package/dist/{caip-BMi-9t09.d.ts → caip-nwFFL46o.d.ts} +2 -2
- package/dist/{chunk-FTWKAJGN.mjs → chunk-2FOPO4N5.mjs} +1 -1
- package/dist/{chunk-EG4H7OMC.cjs → chunk-CIVFT5KR.cjs} +171 -130
- package/dist/{chunk-PYOC6K24.cjs → chunk-D3R3O4CY.cjs} +1 -1
- package/dist/chunk-E7IMWVMN.mjs +346 -0
- package/dist/chunk-EJDBIWNH.mjs +113 -0
- package/dist/chunk-FKJ6EJHH.cjs +346 -0
- package/dist/{chunk-LVCD6RHF.cjs → chunk-FVJKUTHF.cjs} +2 -2
- package/dist/{chunk-NITKDXHR.mjs → chunk-FW7ZMXQS.mjs} +849 -674
- package/dist/chunk-G264OM23.cjs +224 -0
- package/dist/chunk-IPHKBBUV.cjs +113 -0
- package/dist/{chunk-BIL4ENC3.mjs → chunk-IPKT3FU6.mjs} +73 -32
- package/dist/chunk-JPX4MEHV.mjs +19 -0
- package/dist/{chunk-HMUGY66O.cjs → chunk-KXSU24RU.cjs} +1569 -1019
- package/dist/{chunk-ISLVD5HQ.cjs → chunk-LVMNNMOZ.cjs} +10 -5
- package/dist/chunk-O5OW4S7L.cjs +19 -0
- package/dist/{chunk-5NWLS5BQ.mjs → chunk-OZPMRTW3.mjs} +1511 -961
- package/dist/{chunk-OCWSMLOP.cjs → chunk-PVFEZ3UG.cjs} +1164 -989
- package/dist/{chunk-ZGHVJ2XM.mjs → chunk-YQCRXJIL.mjs} +8 -3
- package/dist/chunk-YY4ZOAH5.mjs +224 -0
- package/dist/{chunk-X6N2XPTO.mjs → chunk-ZOJMB5TZ.mjs} +1 -1
- package/dist/compliance.cjs +4 -7
- package/dist/compliance.d.cts +26 -3
- package/dist/compliance.d.ts +26 -3
- package/dist/compliance.mjs +6 -9
- package/dist/constants-BQDxVNgr.d.cts +29 -0
- package/dist/constants-DjGQW5N5.d.ts +29 -0
- package/dist/constants.cjs +3 -37
- package/dist/constants.d.cts +4 -20
- package/dist/constants.d.ts +4 -20
- package/dist/constants.mjs +4 -38
- package/dist/deposit.cjs +7 -6
- package/dist/deposit.d.cts +5 -3
- package/dist/deposit.d.ts +5 -3
- package/dist/deposit.mjs +6 -5
- package/dist/embed.cjs +21 -20
- package/dist/embed.d.cts +3 -2
- package/dist/embed.d.ts +3 -2
- package/dist/embed.mjs +7 -6
- package/dist/index.cjs +8 -35
- package/dist/index.d.cts +5 -3
- package/dist/index.d.ts +5 -3
- package/dist/index.mjs +9 -36
- package/dist/onramp.cjs +4 -33
- package/dist/onramp.d.cts +51 -33
- package/dist/onramp.d.ts +51 -33
- package/dist/onramp.mjs +5 -34
- package/dist/polymarket.cjs +6 -6
- package/dist/polymarket.mjs +2 -2
- package/dist/ramp-types-HYWd7CW0.d.cts +108 -0
- package/dist/ramp-types-HYWd7CW0.d.ts +108 -0
- package/dist/styles.css +255 -0
- package/dist/{types-BOxa1DE-.d.ts → types-BEEMfNi2.d.cts} +24 -4
- package/dist/{types-BShYNpvO.d.cts → types-DQDUqzsZ.d.ts} +24 -4
- package/dist/withdraw.cjs +6 -5
- package/dist/withdraw.d.cts +4 -3
- package/dist/withdraw.d.ts +4 -3
- package/dist/withdraw.mjs +5 -4
- package/package.json +9 -17
- package/dist/WithdrawModal-DY6A55OA.mjs +0 -11
- package/dist/WithdrawModal-V42OK7L3.cjs +0 -11
- package/dist/chunk-ADEWTBSN.cjs +0 -19
- package/dist/chunk-EAGMY3QE.mjs +0 -962
- package/dist/chunk-OY5N3E6L.cjs +0 -962
- package/dist/chunk-PP4QE32S.mjs +0 -19
- package/dist/constants-BT4ctuHo.d.cts +0 -64
- package/dist/constants-D21ZdNOP.d.ts +0 -64
- package/dist/offramp.cjs +0 -25
- package/dist/offramp.d.cts +0 -28
- package/dist/offramp.d.ts +0 -28
- package/dist/offramp.mjs +0 -25
- package/dist/ramp-types-C6aUz4SZ.d.cts +0 -43
- package/dist/ramp-types-C6aUz4SZ.d.ts +0 -43
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkD3R3O4CYcjs = require('./chunk-D3R3O4CY.cjs');
|
|
4
4
|
|
|
5
5
|
// src/core/bearer-transport.ts
|
|
6
6
|
var ScopedRequestError = class extends Error {
|
|
7
|
-
constructor(status) {
|
|
7
|
+
constructor(status, code) {
|
|
8
8
|
super(
|
|
9
9
|
status === 404 ? "Route unavailable; upgrade the proxy before using this API" : `Scoped request failed (${status})`
|
|
10
10
|
);
|
|
11
11
|
this.status = status;
|
|
12
|
+
this.code = code;
|
|
12
13
|
}
|
|
13
14
|
};
|
|
14
15
|
function createBearerTransport(options) {
|
|
@@ -22,7 +23,7 @@ function createBearerTransport(options) {
|
|
|
22
23
|
const response = await fetch(`${base}${path}`, {
|
|
23
24
|
method: body === void 0 ? "GET" : "POST",
|
|
24
25
|
headers: {
|
|
25
|
-
...
|
|
26
|
+
..._chunkD3R3O4CYcjs.serviceHeaders.call(void 0, ),
|
|
26
27
|
Authorization: `Bearer ${session.token}`
|
|
27
28
|
},
|
|
28
29
|
body: body === void 0 ? void 0 : JSON.stringify(body),
|
|
@@ -30,7 +31,11 @@ function createBearerTransport(options) {
|
|
|
30
31
|
cache: "no-store",
|
|
31
32
|
redirect: "error"
|
|
32
33
|
});
|
|
33
|
-
if (!response.ok)
|
|
34
|
+
if (!response.ok) {
|
|
35
|
+
const body2 = await response.json().catch(() => null);
|
|
36
|
+
const code = typeof _optionalChain([body2, 'optionalAccess', _ => _.code]) === "string" && /^[A-Z_]{1,64}$/.test(body2.code) ? body2.code : void 0;
|
|
37
|
+
throw new ScopedRequestError(response.status, code);
|
|
38
|
+
}
|
|
34
39
|
return response.json();
|
|
35
40
|
};
|
|
36
41
|
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
var _chunkLVMNNMOZcjs = require('./chunk-LVMNNMOZ.cjs');
|
|
4
|
+
|
|
5
|
+
// src/core/compliance-service.ts
|
|
6
|
+
function getComplianceStatus(options) {
|
|
7
|
+
return _chunkLVMNNMOZcjs.createBearerTransport.call(void 0, options)("/compliance/status");
|
|
8
|
+
}
|
|
9
|
+
function startComplianceVerification(options) {
|
|
10
|
+
return _chunkLVMNNMOZcjs.createBearerTransport.call(void 0, options)(
|
|
11
|
+
"/compliance/verification",
|
|
12
|
+
{}
|
|
13
|
+
);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
exports.getComplianceStatus = getComplianceStatus; exports.startComplianceVerification = startComplianceVerification;
|