@steerprotocol/sdk 3.2.6 → 3.2.8
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/index.browser.mjs +35 -7
- package/dist/index.browser.mjs.map +1 -1
- package/dist/index.cjs +44 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +12 -2
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +35 -7
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -270,11 +270,18 @@ const AlgebgraHookBeacons = [
|
|
|
270
270
|
MultiPositionManagers.TestCypherAlgebraIntegralHook,
|
|
271
271
|
MultiPositionManagers.TestQuickswapAlgebraIntegralHook
|
|
272
272
|
];
|
|
273
|
-
const
|
|
274
|
-
MultiPositionManagers.
|
|
273
|
+
const UniswapV4Beacons = [
|
|
274
|
+
MultiPositionManagers.MultiPositionUniswapV4ALM,
|
|
275
275
|
MultiPositionManagers.MultiPositionUniswapV4HookOld,
|
|
276
|
+
MultiPositionManagers.TestUniswapJITHook,
|
|
277
|
+
MultiPositionManagers.MultiPositionUniswapV4Hook,
|
|
276
278
|
MultiPositionManagers.MultiPositionReserveV4,
|
|
277
|
-
MultiPositionManagers.
|
|
279
|
+
MultiPositionManagers.MultiPositionUniswapV4NoOracle
|
|
280
|
+
];
|
|
281
|
+
const UniswapHookBeacons = [
|
|
282
|
+
MultiPositionManagers.MultiPositionUniswapV4Hook,
|
|
283
|
+
MultiPositionManagers.TestUniswapJITHook,
|
|
284
|
+
MultiPositionManagers.MultiPositionUniswapV4HookOld
|
|
278
285
|
];
|
|
279
286
|
//#endregion
|
|
280
287
|
//#region src/const/deployments/abis.ts
|
|
@@ -14443,7 +14450,7 @@ const novaswapConfig = () => ({
|
|
|
14443
14450
|
const pancakeSwapConfig = (theGraphApiKey) => ({
|
|
14444
14451
|
beaconContract: MultiPositionManagers.MultiPositionPancake,
|
|
14445
14452
|
subgraph: {
|
|
14446
|
-
[Chain.BSC]: getTheGraphResolverUrl("
|
|
14453
|
+
[Chain.BSC]: getTheGraphResolverUrl("ChmxqA9bX71cB2cQTRRULbWUBKoMRk7oh3JnpZShDQ2V", false, theGraphApiKey),
|
|
14447
14454
|
[Chain.Arbitrum]: getTheGraphResolverUrl("251MHFNN1rwjErXD2efWMpNS73SANZN8Ua192zw6iXve", false, theGraphApiKey)
|
|
14448
14455
|
},
|
|
14449
14456
|
factoryAddress: {
|
|
@@ -14939,7 +14946,7 @@ const kodiakConfig = () => ({
|
|
|
14939
14946
|
beaconContract: MultiPositionManagers.MultiPositionKodiak,
|
|
14940
14947
|
subgraph: {
|
|
14941
14948
|
[Chain.BeraChainBartio]: "https://api.goldsky.com/api/public/project_clpx84oel0al201r78jsl0r3i/subgraphs/kodiak-v3-berachain-bartio/latest/gn",
|
|
14942
|
-
[Chain.Bera]: "https://api.
|
|
14949
|
+
[Chain.Bera]: "https://api.subgraph.ormilabs.com/api/public/d7eed6cc-ad4a-4862-8017-89893c4095d3/subgraphs/kodiak-v3/latest/gn"
|
|
14943
14950
|
},
|
|
14944
14951
|
factoryAddress: {
|
|
14945
14952
|
[Chain.BeraChainBartio]: "0x217Cd80795EfCa5025d47023da5c03a24fA95356",
|
|
@@ -15086,7 +15093,7 @@ const sparkIntegralConfig = () => ({
|
|
|
15086
15093
|
//#region src/const/amm/configs/protocols/uniswapv4.ts
|
|
15087
15094
|
const uniswapV4Config = (theGraphApiKey) => ({
|
|
15088
15095
|
beaconContract: MultiPositionManagers.MultiPositionUniswapV4ALM,
|
|
15089
|
-
additionalBeaconContracts:
|
|
15096
|
+
additionalBeaconContracts: UniswapV4Beacons.slice(1),
|
|
15090
15097
|
subgraph: {
|
|
15091
15098
|
[Chain.Unichain]: getTheGraphResolverUrl(`EoCvJ5tyMLMJcTnLQwWpjAtPdn74PcrZgzfcT5bYxNBH`, false, theGraphApiKey),
|
|
15092
15099
|
[Chain.BSC]: getTheGraphResolverUrl(`EAq1nJKgjnuKH6Gj4RFjCW7LcL7E2uipbncdwV7TTWkX`, false, theGraphApiKey),
|
|
@@ -15245,6 +15252,27 @@ const getAmmConfig = (theGraphApiKey) => {
|
|
|
15245
15252
|
};
|
|
15246
15253
|
//#endregion
|
|
15247
15254
|
//#region src/const/amm/utils/beacon.ts
|
|
15255
|
+
const TEST_UNISWAP_JIT_HOOK_BEACON = MultiPositionManagers.TestUniswapJITHook;
|
|
15256
|
+
const UNISWAP_V4_NO_ORACLE_BEACON = MultiPositionManagers.MultiPositionUniswapV4NoOracle;
|
|
15257
|
+
const UNISWAP_V4_HOOK_BEACON_NAMES = UniswapHookBeacons;
|
|
15258
|
+
const UNISWAP_V4_BEACON_NAMES = UniswapV4Beacons;
|
|
15259
|
+
const includesBeacon = (beaconNames, beaconName) => {
|
|
15260
|
+
if (!beaconName) return false;
|
|
15261
|
+
const normalizedBeaconName = beaconName.toLowerCase();
|
|
15262
|
+
return beaconNames.some((knownBeaconName) => knownBeaconName.toLowerCase() === normalizedBeaconName);
|
|
15263
|
+
};
|
|
15264
|
+
const isUniswapV4Beacon = (beaconName) => includesBeacon(UNISWAP_V4_BEACON_NAMES, beaconName);
|
|
15265
|
+
const isUniswapV4HookBeacon = (beaconName) => includesBeacon(UNISWAP_V4_HOOK_BEACON_NAMES, beaconName);
|
|
15266
|
+
const shouldValidateUniswapV4VaultHook = (beaconName) => beaconName?.toLowerCase() !== UNISWAP_V4_NO_ORACLE_BEACON.toLowerCase();
|
|
15267
|
+
const UNISWAP_V4_BEACON_SUPPORTED_CHAINS = {
|
|
15268
|
+
[TEST_UNISWAP_JIT_HOOK_BEACON.toLowerCase()]: [Chain.BSC],
|
|
15269
|
+
[UNISWAP_V4_NO_ORACLE_BEACON.toLowerCase()]: [Chain.Robinhood]
|
|
15270
|
+
};
|
|
15271
|
+
const getUniswapV4BeaconSupportedChains = (beaconName) => beaconName ? UNISWAP_V4_BEACON_SUPPORTED_CHAINS[beaconName.toLowerCase()] : void 0;
|
|
15272
|
+
const isUniswapV4BeaconAvailableOnChain = (beaconName, chain) => {
|
|
15273
|
+
const supportedChains = getUniswapV4BeaconSupportedChains(beaconName);
|
|
15274
|
+
return !supportedChains || supportedChains.includes(chain);
|
|
15275
|
+
};
|
|
15248
15276
|
const BEACON_TO_SUPPORTED_PROTOCOL_MAP = {
|
|
15249
15277
|
retro: "Retro",
|
|
15250
15278
|
forge: "Forge",
|
|
@@ -23747,9 +23775,14 @@ exports.SteerClient = SteerClient;
|
|
|
23747
23775
|
exports.StrykePositionManagers = StrykePositionManagers;
|
|
23748
23776
|
exports.SubgraphClient = SubgraphClient;
|
|
23749
23777
|
exports.SubgraphVaultClient = SubgraphVaultClient;
|
|
23778
|
+
exports.TEST_UNISWAP_JIT_HOOK_BEACON = TEST_UNISWAP_JIT_HOOK_BEACON;
|
|
23779
|
+
exports.UNISWAP_V4_BEACON_NAMES = UNISWAP_V4_BEACON_NAMES;
|
|
23780
|
+
exports.UNISWAP_V4_HOOK_BEACON_NAMES = UNISWAP_V4_HOOK_BEACON_NAMES;
|
|
23781
|
+
exports.UNISWAP_V4_NO_ORACLE_BEACON = UNISWAP_V4_NO_ORACLE_BEACON;
|
|
23750
23782
|
exports.UniswapHookBeacons = UniswapHookBeacons;
|
|
23751
23783
|
exports.UniswapV3PoolABI = UniswapV3PoolABI;
|
|
23752
23784
|
exports.UniswapV3QuoterABI = UniswapV3QuoterABI;
|
|
23785
|
+
exports.UniswapV4Beacons = UniswapV4Beacons;
|
|
23753
23786
|
exports.VAULT_FEES_ABI = VAULT_FEES_ABI;
|
|
23754
23787
|
exports.VaultClient = VaultClient;
|
|
23755
23788
|
exports.abis = abis;
|
|
@@ -23822,6 +23855,7 @@ exports.getSupportedChains = getSupportedChains;
|
|
|
23822
23855
|
exports.getSwapRouterAddress = getSwapRouterAddress;
|
|
23823
23856
|
exports.getTheGraphResolverUrl = getTheGraphResolverUrl;
|
|
23824
23857
|
exports.getTickLensAddress = getTickLensAddress;
|
|
23858
|
+
exports.getUniswapV4BeaconSupportedChains = getUniswapV4BeaconSupportedChains;
|
|
23825
23859
|
exports.getVaultReserves = getVaultReserves;
|
|
23826
23860
|
exports.glyphConfig = glyphConfig;
|
|
23827
23861
|
exports.goerliAddresses = goerliAddresses;
|
|
@@ -23844,6 +23878,9 @@ exports.isSingleAssetDepositSupported = isSingleAssetDepositSupported;
|
|
|
23844
23878
|
exports.isThickQuoteParams = isThickQuoteParams;
|
|
23845
23879
|
exports.isThickV2Protocol = isThickV2Protocol;
|
|
23846
23880
|
exports.isUniswapQuoteParams = isUniswapQuoteParams;
|
|
23881
|
+
exports.isUniswapV4Beacon = isUniswapV4Beacon;
|
|
23882
|
+
exports.isUniswapV4BeaconAvailableOnChain = isUniswapV4BeaconAvailableOnChain;
|
|
23883
|
+
exports.isUniswapV4HookBeacon = isUniswapV4HookBeacon;
|
|
23847
23884
|
exports.isValidStakingProtocol = isValidStakingProtocol;
|
|
23848
23885
|
exports.katanaAddresses = katanaAddresses;
|
|
23849
23886
|
exports.katanaConfig = katanaConfig;
|
|
@@ -23884,6 +23921,7 @@ exports.sagaAddresses = sagaAddresses;
|
|
|
23884
23921
|
exports.scrollAddresses = scrollAddresses;
|
|
23885
23922
|
exports.seiAddresses = seiAddresses;
|
|
23886
23923
|
exports.shadowConfig = shadowConfig;
|
|
23924
|
+
exports.shouldValidateUniswapV4VaultHook = shouldValidateUniswapV4VaultHook;
|
|
23887
23925
|
exports.simulateSwap = simulateSwap;
|
|
23888
23926
|
exports.singleTokenDepositAbi = singleTokenDepositAbi;
|
|
23889
23927
|
exports.soneiumAddresses = soneiumAddresses;
|