@gobob/bob-sdk 3.1.7 → 3.2.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/dist/esplora.d.ts +1 -0
- package/dist/esplora.js +5 -1
- package/dist/esplora.js.map +1 -1
- package/dist/gateway/abi.d.ts +128 -15
- package/dist/gateway/abi.js +93 -19
- package/dist/gateway/abi.js.map +1 -1
- package/dist/gateway/client.d.ts +22137 -4
- package/dist/gateway/client.js +254 -55
- package/dist/gateway/client.js.map +1 -1
- package/dist/gateway/strategy.d.ts +11 -0
- package/dist/gateway/strategy.js +139 -0
- package/dist/gateway/strategy.js.map +1 -0
- package/dist/gateway/tokens.d.ts +3 -0
- package/dist/gateway/tokens.js +52 -16
- package/dist/gateway/tokens.js.map +1 -1
- package/dist/gateway/types.d.ts +85 -24
- package/dist/helpers.js +17 -7
- package/dist/helpers.js.map +1 -1
- package/dist/inscription.d.ts +3 -3
- package/dist/inscription.js +17 -7
- package/dist/inscription.js.map +1 -1
- package/dist/mempool.d.ts +3 -2
- package/dist/mempool.js +5 -1
- package/dist/mempool.js.map +1 -1
- package/dist/ordinal-api/index.d.ts +1 -0
- package/dist/ordinal-api/index.js +5 -1
- package/dist/ordinal-api/index.js.map +1 -1
- package/dist/ordinals/commit.js +17 -7
- package/dist/ordinals/commit.js.map +1 -1
- package/dist/ordinals/index.js +17 -7
- package/dist/ordinals/index.js.map +1 -1
- package/dist/ordinals/reveal.d.ts +1 -1
- package/dist/ordinals/reveal.js +17 -7
- package/dist/ordinals/reveal.js.map +1 -1
- package/dist/runes.js +17 -7
- package/dist/runes.js.map +1 -1
- package/dist/utils.d.ts +4 -3
- package/dist/utils.js +7 -0
- package/dist/utils.js.map +1 -1
- package/dist/wallet/utxo.d.ts +5 -4
- package/dist/wallet/utxo.js +33 -18
- package/dist/wallet/utxo.js.map +1 -1
- package/package.json +51 -51
package/dist/esplora.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export declare const MAINNET_ESPLORA_BASE_PATH = "https://btc-mainnet.gobob.xyz";
|
|
2
2
|
export declare const TESTNET_ESPLORA_BASE_PATH = "https://btc-testnet.gobob.xyz";
|
|
3
3
|
export declare const REGTEST_ESPLORA_BASE_PATH = "http://localhost:3003";
|
|
4
|
+
export declare const SIGNET_ESPLORA_BASE_PATH = "https://btc-signet.gobob.xyz";
|
|
4
5
|
export interface MerkleProof {
|
|
5
6
|
blockHeight: number;
|
|
6
7
|
merkle: string;
|
package/dist/esplora.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.EsploraClient = exports.REGTEST_ESPLORA_BASE_PATH = exports.TESTNET_ESPLORA_BASE_PATH = exports.MAINNET_ESPLORA_BASE_PATH = void 0;
|
|
3
|
+
exports.EsploraClient = exports.SIGNET_ESPLORA_BASE_PATH = exports.REGTEST_ESPLORA_BASE_PATH = exports.TESTNET_ESPLORA_BASE_PATH = exports.MAINNET_ESPLORA_BASE_PATH = void 0;
|
|
4
4
|
exports.MAINNET_ESPLORA_BASE_PATH = 'https://btc-mainnet.gobob.xyz';
|
|
5
5
|
exports.TESTNET_ESPLORA_BASE_PATH = 'https://btc-testnet.gobob.xyz';
|
|
6
6
|
exports.REGTEST_ESPLORA_BASE_PATH = 'http://localhost:3003';
|
|
7
|
+
exports.SIGNET_ESPLORA_BASE_PATH = 'https://btc-signet.gobob.xyz';
|
|
7
8
|
function encodeEsploraMerkleProof(merkle) {
|
|
8
9
|
return merkle.map((item) => Buffer.from(item, 'hex').reverse().toString('hex')).join('');
|
|
9
10
|
}
|
|
@@ -13,6 +14,9 @@ class EsploraClient {
|
|
|
13
14
|
case 'mainnet':
|
|
14
15
|
this.basePath = exports.MAINNET_ESPLORA_BASE_PATH;
|
|
15
16
|
break;
|
|
17
|
+
case 'signet':
|
|
18
|
+
this.basePath = exports.SIGNET_ESPLORA_BASE_PATH;
|
|
19
|
+
break;
|
|
16
20
|
case 'testnet':
|
|
17
21
|
this.basePath = exports.TESTNET_ESPLORA_BASE_PATH;
|
|
18
22
|
break;
|
package/dist/esplora.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"esplora.js","sourceRoot":"","sources":["../src/esplora.ts"],"names":[],"mappings":";;;AAIa,QAAA,yBAAyB,GAAG,+BAA+B,CAAC;AAK5D,QAAA,yBAAyB,GAAG,+BAA+B,CAAC;AAK5D,QAAA,yBAAyB,GAAG,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"esplora.js","sourceRoot":"","sources":["../src/esplora.ts"],"names":[],"mappings":";;;AAIa,QAAA,yBAAyB,GAAG,+BAA+B,CAAC;AAK5D,QAAA,yBAAyB,GAAG,+BAA+B,CAAC;AAK5D,QAAA,yBAAyB,GAAG,uBAAuB,CAAC;AAKpD,QAAA,wBAAwB,GAAG,8BAA8B,CAAC;AA4HvE,SAAS,wBAAwB,CAAC,MAAgB;IAE9C,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AAC7F,CAAC;AAOD,MAAa,aAAa;IAmBtB,YAAY,eAAuB,SAAS;QACxC,QAAQ,YAAY,EAAE,CAAC;YACnB,KAAK,SAAS;gBACV,IAAI,CAAC,QAAQ,GAAG,iCAAyB,CAAC;gBAC1C,MAAM;YACV,KAAK,QAAQ;gBACT,IAAI,CAAC,QAAQ,GAAG,gCAAwB,CAAC;gBACzC,MAAM;YACV,KAAK,SAAS;gBACV,IAAI,CAAC,QAAQ,GAAG,iCAAyB,CAAC;gBAC1C,MAAM;YACV,KAAK,SAAS;gBACV,IAAI,CAAC,QAAQ,GAAG,iCAAyB,CAAC;gBAC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;QAClC,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;YACf,MAAM,IAAI,KAAK,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;QACzC,CAAC;QACD,OAAO,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAC;IACjC,CAAC;CACJ;AAzWD,sCAyWC"}
|
package/dist/gateway/abi.d.ts
CHANGED
|
@@ -26,39 +26,152 @@ export declare const strategyCaller: readonly [{
|
|
|
26
26
|
readonly outputs: readonly [];
|
|
27
27
|
readonly stateMutability: "nonpayable";
|
|
28
28
|
}];
|
|
29
|
-
export declare const
|
|
29
|
+
export declare const offrampCreateOrderCaller: readonly [{
|
|
30
30
|
readonly type: "function";
|
|
31
|
-
readonly name: "
|
|
31
|
+
readonly name: "createOrder";
|
|
32
32
|
readonly inputs: readonly [{
|
|
33
|
-
readonly name: "
|
|
33
|
+
readonly name: "offrampOrderArgs";
|
|
34
34
|
readonly type: "tuple";
|
|
35
|
-
readonly internalType: "struct
|
|
35
|
+
readonly internalType: "struct OfframpOrderArgs";
|
|
36
36
|
readonly components: readonly [{
|
|
37
|
-
readonly name: "
|
|
38
|
-
readonly type: "
|
|
39
|
-
readonly internalType: "
|
|
37
|
+
readonly name: "satAmountToLock";
|
|
38
|
+
readonly type: "uint256";
|
|
39
|
+
readonly internalType: "uint256";
|
|
40
40
|
}, {
|
|
41
|
-
readonly name: "
|
|
41
|
+
readonly name: "satFeesMax";
|
|
42
42
|
readonly type: "uint256";
|
|
43
43
|
readonly internalType: "uint256";
|
|
44
44
|
}, {
|
|
45
|
-
readonly name: "
|
|
45
|
+
readonly name: "orderCreationDeadline";
|
|
46
46
|
readonly type: "uint256";
|
|
47
47
|
readonly internalType: "uint256";
|
|
48
48
|
}, {
|
|
49
|
-
readonly name: "
|
|
49
|
+
readonly name: "outputScript";
|
|
50
|
+
readonly type: "bytes";
|
|
51
|
+
readonly internalType: "bytes";
|
|
52
|
+
}, {
|
|
53
|
+
readonly name: "token";
|
|
50
54
|
readonly type: "address";
|
|
51
55
|
readonly internalType: "address";
|
|
56
|
+
}];
|
|
57
|
+
}];
|
|
58
|
+
readonly outputs: readonly [];
|
|
59
|
+
readonly stateMutability: "nonpayable";
|
|
60
|
+
}];
|
|
61
|
+
export declare const offrampBumpFeeCaller: readonly [{
|
|
62
|
+
readonly type: "function";
|
|
63
|
+
readonly name: "bumpFeeOfExistingOrder";
|
|
64
|
+
readonly inputs: readonly [{
|
|
65
|
+
readonly name: "orderId";
|
|
66
|
+
readonly type: "uint256";
|
|
67
|
+
readonly internalType: "uint256";
|
|
68
|
+
}, {
|
|
69
|
+
readonly name: "newFeeSat";
|
|
70
|
+
readonly type: "uint256";
|
|
71
|
+
readonly internalType: "uint256";
|
|
72
|
+
}];
|
|
73
|
+
readonly outputs: readonly [];
|
|
74
|
+
readonly stateMutability: "nonpayable";
|
|
75
|
+
}];
|
|
76
|
+
export declare const offrampUnlockFundsCaller: readonly [{
|
|
77
|
+
readonly type: "function";
|
|
78
|
+
readonly name: "unlockFunds";
|
|
79
|
+
readonly inputs: readonly [{
|
|
80
|
+
readonly name: "orderId";
|
|
81
|
+
readonly type: "uint256";
|
|
82
|
+
readonly internalType: "uint256";
|
|
83
|
+
}, {
|
|
84
|
+
readonly name: "receiver";
|
|
85
|
+
readonly type: "address";
|
|
86
|
+
readonly internalType: "address";
|
|
87
|
+
}];
|
|
88
|
+
readonly outputs: readonly [];
|
|
89
|
+
readonly stateMutability: "nonpayable";
|
|
90
|
+
}];
|
|
91
|
+
export declare const compoundV2CTokenAbi: readonly [{
|
|
92
|
+
readonly name: "exchangeRateCurrent";
|
|
93
|
+
readonly type: "function";
|
|
94
|
+
readonly stateMutability: "nonpayable";
|
|
95
|
+
readonly inputs: readonly [];
|
|
96
|
+
readonly outputs: readonly [{
|
|
97
|
+
readonly type: "uint256";
|
|
98
|
+
}];
|
|
99
|
+
}, {
|
|
100
|
+
readonly name: "underlying";
|
|
101
|
+
readonly type: "function";
|
|
102
|
+
readonly stateMutability: "view";
|
|
103
|
+
readonly inputs: readonly [];
|
|
104
|
+
readonly outputs: readonly [{
|
|
105
|
+
readonly type: "address";
|
|
106
|
+
}];
|
|
107
|
+
}];
|
|
108
|
+
export declare const aaveV2AtokenAbi: readonly [{
|
|
109
|
+
readonly name: "UNDERLYING_ASSET_ADDRESS";
|
|
110
|
+
readonly type: "function";
|
|
111
|
+
readonly stateMutability: "view";
|
|
112
|
+
readonly inputs: readonly [];
|
|
113
|
+
readonly outputs: readonly [{
|
|
114
|
+
readonly type: "address";
|
|
115
|
+
}];
|
|
116
|
+
}];
|
|
117
|
+
export declare const offrampGetOrderCaller: readonly [{
|
|
118
|
+
readonly type: "function";
|
|
119
|
+
readonly name: "getOfframpOrder";
|
|
120
|
+
readonly inputs: readonly [{
|
|
121
|
+
readonly name: "orderId";
|
|
122
|
+
readonly type: "uint256";
|
|
123
|
+
readonly internalType: "uint256";
|
|
124
|
+
}];
|
|
125
|
+
readonly outputs: readonly [{
|
|
126
|
+
readonly name: "";
|
|
127
|
+
readonly type: "tuple";
|
|
128
|
+
readonly internalType: "struct OfframpOrderDetails";
|
|
129
|
+
readonly components: readonly [{
|
|
130
|
+
readonly name: "satAmountLocked";
|
|
131
|
+
readonly type: "uint256";
|
|
132
|
+
readonly internalType: "uint256";
|
|
52
133
|
}, {
|
|
53
|
-
readonly name: "
|
|
134
|
+
readonly name: "satFeesMax";
|
|
135
|
+
readonly type: "uint256";
|
|
136
|
+
readonly internalType: "uint256";
|
|
137
|
+
}, {
|
|
138
|
+
readonly name: "sender";
|
|
54
139
|
readonly type: "address";
|
|
55
|
-
readonly internalType: "
|
|
140
|
+
readonly internalType: "address";
|
|
56
141
|
}, {
|
|
57
|
-
readonly name: "
|
|
142
|
+
readonly name: "receiver";
|
|
143
|
+
readonly type: "address";
|
|
144
|
+
readonly internalType: "address";
|
|
145
|
+
}, {
|
|
146
|
+
readonly name: "outputScript";
|
|
58
147
|
readonly type: "bytes";
|
|
59
148
|
readonly internalType: "bytes";
|
|
149
|
+
}, {
|
|
150
|
+
readonly name: "status";
|
|
151
|
+
readonly type: "uint8";
|
|
152
|
+
readonly internalType: "enum OfframpOrderStatus";
|
|
153
|
+
}, {
|
|
154
|
+
readonly name: "timestamp";
|
|
155
|
+
readonly type: "uint256";
|
|
156
|
+
readonly internalType: "uint256";
|
|
157
|
+
}, {
|
|
158
|
+
readonly name: "token";
|
|
159
|
+
readonly type: "address";
|
|
160
|
+
readonly internalType: "address";
|
|
161
|
+
}, {
|
|
162
|
+
readonly name: "owner";
|
|
163
|
+
readonly type: "address";
|
|
164
|
+
readonly internalType: "address";
|
|
60
165
|
}];
|
|
61
166
|
}];
|
|
62
|
-
readonly
|
|
63
|
-
|
|
167
|
+
readonly stateMutability: "view";
|
|
168
|
+
}];
|
|
169
|
+
export declare const claimDelayAbi: readonly [{
|
|
170
|
+
readonly name: "CLAIM_DELAY";
|
|
171
|
+
readonly type: "function";
|
|
172
|
+
readonly stateMutability: "view";
|
|
173
|
+
readonly inputs: readonly [];
|
|
174
|
+
readonly outputs: readonly [{
|
|
175
|
+
readonly type: "uint64";
|
|
176
|
+
}];
|
|
64
177
|
}];
|
package/dist/gateway/abi.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.claimDelayAbi = exports.offrampGetOrderCaller = exports.aaveV2AtokenAbi = exports.compoundV2CTokenAbi = exports.offrampUnlockFundsCaller = exports.offrampBumpFeeCaller = exports.offrampCreateOrderCaller = exports.strategyCaller = void 0;
|
|
4
|
+
const viem_1 = require("viem");
|
|
4
5
|
exports.strategyCaller = [
|
|
5
6
|
{
|
|
6
7
|
type: 'function',
|
|
@@ -38,45 +39,40 @@ exports.strategyCaller = [
|
|
|
38
39
|
stateMutability: 'nonpayable',
|
|
39
40
|
},
|
|
40
41
|
];
|
|
41
|
-
exports.
|
|
42
|
+
exports.offrampCreateOrderCaller = [
|
|
42
43
|
{
|
|
43
44
|
type: 'function',
|
|
44
|
-
name: '
|
|
45
|
+
name: 'createOrder',
|
|
45
46
|
inputs: [
|
|
46
47
|
{
|
|
47
|
-
name: '
|
|
48
|
+
name: 'offrampOrderArgs',
|
|
48
49
|
type: 'tuple',
|
|
49
|
-
internalType: 'struct
|
|
50
|
+
internalType: 'struct OfframpOrderArgs',
|
|
50
51
|
components: [
|
|
51
52
|
{
|
|
52
|
-
name: '
|
|
53
|
-
type: '
|
|
54
|
-
internalType: '
|
|
53
|
+
name: 'satAmountToLock',
|
|
54
|
+
type: 'uint256',
|
|
55
|
+
internalType: 'uint256',
|
|
55
56
|
},
|
|
56
57
|
{
|
|
57
|
-
name: '
|
|
58
|
+
name: 'satFeesMax',
|
|
58
59
|
type: 'uint256',
|
|
59
60
|
internalType: 'uint256',
|
|
60
61
|
},
|
|
61
62
|
{
|
|
62
|
-
name: '
|
|
63
|
+
name: 'orderCreationDeadline',
|
|
63
64
|
type: 'uint256',
|
|
64
65
|
internalType: 'uint256',
|
|
65
66
|
},
|
|
66
67
|
{
|
|
67
|
-
name: '
|
|
68
|
-
type: '
|
|
69
|
-
internalType: '
|
|
68
|
+
name: 'outputScript',
|
|
69
|
+
type: 'bytes',
|
|
70
|
+
internalType: 'bytes',
|
|
70
71
|
},
|
|
71
72
|
{
|
|
72
73
|
name: 'token',
|
|
73
74
|
type: 'address',
|
|
74
|
-
internalType: '
|
|
75
|
-
},
|
|
76
|
-
{
|
|
77
|
-
name: 'userBtcAddress',
|
|
78
|
-
type: 'bytes',
|
|
79
|
-
internalType: 'bytes',
|
|
75
|
+
internalType: 'address',
|
|
80
76
|
},
|
|
81
77
|
],
|
|
82
78
|
},
|
|
@@ -85,4 +81,82 @@ exports.offRampCaller = [
|
|
|
85
81
|
stateMutability: 'nonpayable',
|
|
86
82
|
},
|
|
87
83
|
];
|
|
84
|
+
exports.offrampBumpFeeCaller = [
|
|
85
|
+
{
|
|
86
|
+
type: 'function',
|
|
87
|
+
name: 'bumpFeeOfExistingOrder',
|
|
88
|
+
inputs: [
|
|
89
|
+
{
|
|
90
|
+
name: 'orderId',
|
|
91
|
+
type: 'uint256',
|
|
92
|
+
internalType: 'uint256',
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
name: 'newFeeSat',
|
|
96
|
+
type: 'uint256',
|
|
97
|
+
internalType: 'uint256',
|
|
98
|
+
},
|
|
99
|
+
],
|
|
100
|
+
outputs: [],
|
|
101
|
+
stateMutability: 'nonpayable',
|
|
102
|
+
},
|
|
103
|
+
];
|
|
104
|
+
exports.offrampUnlockFundsCaller = [
|
|
105
|
+
{
|
|
106
|
+
type: 'function',
|
|
107
|
+
name: 'unlockFunds',
|
|
108
|
+
inputs: [
|
|
109
|
+
{
|
|
110
|
+
name: 'orderId',
|
|
111
|
+
type: 'uint256',
|
|
112
|
+
internalType: 'uint256',
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
name: 'receiver',
|
|
116
|
+
type: 'address',
|
|
117
|
+
internalType: 'address',
|
|
118
|
+
},
|
|
119
|
+
],
|
|
120
|
+
outputs: [],
|
|
121
|
+
stateMutability: 'nonpayable',
|
|
122
|
+
},
|
|
123
|
+
];
|
|
124
|
+
exports.compoundV2CTokenAbi = (0, viem_1.parseAbi)([
|
|
125
|
+
'function exchangeRateCurrent() external returns (uint256)',
|
|
126
|
+
'function underlying() external view returns (address)',
|
|
127
|
+
]);
|
|
128
|
+
exports.aaveV2AtokenAbi = (0, viem_1.parseAbi)(['function UNDERLYING_ASSET_ADDRESS() external view returns (address)']);
|
|
129
|
+
exports.offrampGetOrderCaller = [
|
|
130
|
+
{
|
|
131
|
+
type: 'function',
|
|
132
|
+
name: 'getOfframpOrder',
|
|
133
|
+
inputs: [
|
|
134
|
+
{
|
|
135
|
+
name: 'orderId',
|
|
136
|
+
type: 'uint256',
|
|
137
|
+
internalType: 'uint256',
|
|
138
|
+
},
|
|
139
|
+
],
|
|
140
|
+
outputs: [
|
|
141
|
+
{
|
|
142
|
+
name: '',
|
|
143
|
+
type: 'tuple',
|
|
144
|
+
internalType: 'struct OfframpOrderDetails',
|
|
145
|
+
components: [
|
|
146
|
+
{ name: 'satAmountLocked', type: 'uint256', internalType: 'uint256' },
|
|
147
|
+
{ name: 'satFeesMax', type: 'uint256', internalType: 'uint256' },
|
|
148
|
+
{ name: 'sender', type: 'address', internalType: 'address' },
|
|
149
|
+
{ name: 'receiver', type: 'address', internalType: 'address' },
|
|
150
|
+
{ name: 'outputScript', type: 'bytes', internalType: 'bytes' },
|
|
151
|
+
{ name: 'status', type: 'uint8', internalType: 'enum OfframpOrderStatus' },
|
|
152
|
+
{ name: 'timestamp', type: 'uint256', internalType: 'uint256' },
|
|
153
|
+
{ name: 'token', type: 'address', internalType: 'address' },
|
|
154
|
+
{ name: 'owner', type: 'address', internalType: 'address' },
|
|
155
|
+
],
|
|
156
|
+
},
|
|
157
|
+
],
|
|
158
|
+
stateMutability: 'view',
|
|
159
|
+
},
|
|
160
|
+
];
|
|
161
|
+
exports.claimDelayAbi = (0, viem_1.parseAbi)(['function CLAIM_DELAY() view returns (uint64)']);
|
|
88
162
|
//# sourceMappingURL=abi.js.map
|
package/dist/gateway/abi.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"abi.js","sourceRoot":"","sources":["../../src/gateway/abi.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"abi.js","sourceRoot":"","sources":["../../src/gateway/abi.ts"],"names":[],"mappings":";;;AAAA,+BAAgC;AAEnB,QAAA,cAAc,GAAG;IAC1B;QACI,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,sCAAsC;QAC5C,MAAM,EAAE;YACJ;gBACI,IAAI,EAAE,WAAW;gBACjB,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,iBAAiB;aAClC;YACD;gBACI,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,SAAS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