@pancakeswap/pools 4.0.21 → 4.0.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/dist/constants/boostedPools/arb.d.ts +3 -0
  2. package/dist/constants/boostedPools/arb.d.ts.map +1 -0
  3. package/dist/constants/boostedPools/index.d.ts +9 -0
  4. package/dist/constants/boostedPools/index.d.ts.map +1 -0
  5. package/dist/constants/contracts.d.ts +1 -1
  6. package/dist/constants/index.d.ts +1 -0
  7. package/dist/constants/index.d.ts.map +1 -1
  8. package/dist/constants/pools/324.d.ts.map +1 -1
  9. package/dist/constants/pools/56.d.ts.map +1 -1
  10. package/dist/constants/supportedChains.d.ts +2 -0
  11. package/dist/constants/supportedChains.d.ts.map +1 -1
  12. package/dist/index.d.ts +0 -1
  13. package/dist/index.d.ts.map +1 -1
  14. package/dist/index.js +136 -127
  15. package/dist/index.js.map +1 -1
  16. package/dist/index.mjs +130 -124
  17. package/dist/index.mjs.map +1 -1
  18. package/dist/queries/index.d.ts +0 -1
  19. package/dist/queries/index.d.ts.map +1 -1
  20. package/dist/utils/boosted/apr/fetchAlpBoostedPoolApr.d.ts +3 -0
  21. package/dist/utils/boosted/apr/fetchAlpBoostedPoolApr.d.ts.map +1 -0
  22. package/dist/utils/boosted/apr/getBoostedPoolApr.d.ts +9 -0
  23. package/dist/utils/boosted/apr/getBoostedPoolApr.d.ts.map +1 -0
  24. package/dist/utils/boosted/checkIsBoostedPool.d.ts +3 -0
  25. package/dist/utils/boosted/checkIsBoostedPool.d.ts.map +1 -0
  26. package/dist/utils/boosted/types.d.ts +10 -0
  27. package/dist/utils/boosted/types.d.ts.map +1 -0
  28. package/dist/utils/index.d.ts +2 -0
  29. package/dist/utils/index.d.ts.map +1 -1
  30. package/dist/utils/isPoolsSupported.d.ts +3 -1
  31. package/dist/utils/isPoolsSupported.d.ts.map +1 -1
  32. package/package.json +6 -6
  33. package/dist/abis/ICake.d.ts +0 -92
  34. package/dist/abis/ICake.d.ts.map +0 -1
  35. package/dist/queries/fetchUserIfo.d.ts +0 -16
  36. package/dist/queries/fetchUserIfo.d.ts.map +0 -1
@@ -1,6 +1,5 @@
1
1
  export * from './fetchPools';
2
2
  export * from './fetchUserPoolsData';
3
- export * from './fetchUserIfo';
4
3
  export * from './fetchVaultPublic';
5
4
  export * from './getAddresses';
6
5
  export * from './fetchVaultUser';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/queries/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAA;AAC5B,cAAc,sBAAsB,CAAA;AACpC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,oBAAoB,CAAA;AAClC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,kBAAkB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/queries/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAA;AAC5B,cAAc,sBAAsB,CAAA;AACpC,cAAc,oBAAoB,CAAA;AAClC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,kBAAkB,CAAA"}
@@ -0,0 +1,3 @@
1
+ import { PublicClient } from 'viem';
2
+ export declare const fetchAlpBoostedPoolApr: (client: PublicClient) => Promise<number>;
3
+ //# sourceMappingURL=fetchAlpBoostedPoolApr.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fetchAlpBoostedPoolApr.d.ts","sourceRoot":"","sources":["../../../../src/utils/boosted/apr/fetchAlpBoostedPoolApr.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,MAAM,CAAA;AAOnC,eAAO,MAAM,sBAAsB,WAAkB,YAAY,oBAsDhE,CAAA"}
@@ -0,0 +1,9 @@
1
+ import { Address, PublicClient } from 'viem';
2
+ interface GetBoostedPoolApr {
3
+ client: PublicClient;
4
+ contractAddress: Address;
5
+ chainId: number | undefined;
6
+ }
7
+ export declare const getBoostedPoolApr: ({ client, contractAddress, chainId }: GetBoostedPoolApr) => Promise<number>;
8
+ export {};
9
+ //# sourceMappingURL=getBoostedPoolApr.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getBoostedPoolApr.d.ts","sourceRoot":"","sources":["../../../../src/utils/boosted/apr/getBoostedPoolApr.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,MAAM,CAAA;AAK5C,UAAU,iBAAiB;IACzB,MAAM,EAAE,YAAY,CAAA;IACpB,eAAe,EAAE,OAAO,CAAA;IACxB,OAAO,EAAE,MAAM,GAAG,SAAS,CAAA;CAC5B;AAED,eAAO,MAAM,iBAAiB,yCAAgD,iBAAiB,KAAG,QAAQ,MAAM,CAc/G,CAAA"}
@@ -0,0 +1,3 @@
1
+ import { ChainId } from '@pancakeswap/chains';
2
+ export declare const checkIsBoostedPool: (contract: string, chainId: ChainId) => boolean;
3
+ //# sourceMappingURL=checkIsBoostedPool.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"checkIsBoostedPool.d.ts","sourceRoot":"","sources":["../../../src/utils/boosted/checkIsBoostedPool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAA;AAG7C,eAAO,MAAM,kBAAkB,aAAc,MAAM,WAAW,OAAO,KAAG,OAKvE,CAAA"}
@@ -0,0 +1,10 @@
1
+ import { Address } from 'viem';
2
+ export declare enum BoosterType {
3
+ ALP = 0
4
+ }
5
+ export type BoosterConfig = {
6
+ boosterType: BoosterType;
7
+ contractAddress: Address;
8
+ tooltipsText?: string;
9
+ };
10
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/utils/boosted/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAA;AAE9B,oBAAY,WAAW;IACrB,GAAG,IAAA;CACJ;AAED,MAAM,MAAM,aAAa,GAAG;IAC1B,WAAW,EAAE,WAAW,CAAA;IACxB,eAAe,EAAE,OAAO,CAAA;IACxB,YAAY,CAAC,EAAE,MAAM,CAAA;CACtB,CAAA"}
@@ -3,4 +3,6 @@ export * from './isPoolsSupported';
3
3
  export * from './isLegacyPool';
4
4
  export * from './apr';
5
5
  export * from './getPoolContractBySousId';
6
+ export * from './boosted/checkIsBoostedPool';
7
+ export * from './boosted/apr/getBoostedPoolApr';
6
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAA;AACpC,cAAc,oBAAoB,CAAA;AAClC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,OAAO,CAAA;AACrB,cAAc,2BAA2B,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAA;AACpC,cAAc,oBAAoB,CAAA;AAClC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,OAAO,CAAA;AACrB,cAAc,2BAA2B,CAAA;AACzC,cAAc,8BAA8B,CAAA;AAC5C,cAAc,iCAAiC,CAAA"}
@@ -1,3 +1,5 @@
1
- import { SupportedChainId } from '../constants/supportedChains';
1
+ import { ChainId } from '@pancakeswap/chains';
2
+ import { SupportedChainId, CakeVaultSupportedChainId } from '../constants/supportedChains';
2
3
  export declare function isPoolsSupported(chainId: number): chainId is SupportedChainId;
4
+ export declare function isCakeVaultSupported(chainId?: ChainId): chainId is CakeVaultSupportedChainId;
3
5
  //# sourceMappingURL=isPoolsSupported.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"isPoolsSupported.d.ts","sourceRoot":"","sources":["../../src/utils/isPoolsSupported.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAuB,MAAM,8BAA8B,CAAA;AAEpF,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,IAAI,gBAAgB,CAE7E"}
1
+ {"version":3,"file":"isPoolsSupported.d.ts","sourceRoot":"","sources":["../../src/utils/isPoolsSupported.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAA;AAE7C,OAAO,EACL,gBAAgB,EAEhB,yBAAyB,EAE1B,MAAM,8BAA8B,CAAA;AAErC,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,IAAI,gBAAgB,CAE7E;AAED,wBAAgB,oBAAoB,CAAC,OAAO,CAAC,EAAE,OAAO,GAAG,OAAO,IAAI,yBAAyB,CAE5F"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pancakeswap/pools",
3
- "version": "4.0.21",
3
+ "version": "4.0.22",
4
4
  "sideEffects": false,
5
5
  "files": [
6
6
  "dist"
@@ -11,17 +11,17 @@
11
11
  "dependencies": {
12
12
  "bignumber.js": "^9.0.0",
13
13
  "lodash": "^4.17.21",
14
- "viem": "^1.15.1",
15
- "wagmi": "^1.4.3",
14
+ "viem": "1.15.1",
15
+ "wagmi": "1.4.3",
16
16
  "@pancakeswap/token-lists": "0.0.9",
17
- "@pancakeswap/tokens": "0.5.4",
18
- "@pancakeswap/chains": "0.3.0"
17
+ "@pancakeswap/chains": "0.3.0",
18
+ "@pancakeswap/tokens": "0.5.4"
19
19
  },
20
20
  "devDependencies": {
21
21
  "@types/lodash": "^4.14.168",
22
22
  "tsup": "^6.7.0",
23
23
  "@pancakeswap/tsconfig": "0.0.0",
24
- "@pancakeswap/utils": "5.0.6"
24
+ "@pancakeswap/utils": "5.0.7"
25
25
  },
26
26
  "exports": {
27
27
  "./package.json": "./package.json",
@@ -1,92 +0,0 @@
1
- export declare const iCakeABI: readonly [{
2
- readonly inputs: readonly [];
3
- readonly name: "MIN_CEILING_DURATION";
4
- readonly outputs: readonly [{
5
- readonly internalType: "uint256";
6
- readonly name: "";
7
- readonly type: "uint256";
8
- }];
9
- readonly stateMutability: "view";
10
- readonly type: "function";
11
- }, {
12
- readonly inputs: readonly [];
13
- readonly name: "admin";
14
- readonly outputs: readonly [{
15
- readonly internalType: "address";
16
- readonly name: "";
17
- readonly type: "address";
18
- }];
19
- readonly stateMutability: "view";
20
- readonly type: "function";
21
- }, {
22
- readonly inputs: readonly [];
23
- readonly name: "cakePool";
24
- readonly outputs: readonly [{
25
- readonly internalType: "contract ICaKePool";
26
- readonly name: "";
27
- readonly type: "address";
28
- }];
29
- readonly stateMutability: "view";
30
- readonly type: "function";
31
- }, {
32
- readonly inputs: readonly [];
33
- readonly name: "ceiling";
34
- readonly outputs: readonly [{
35
- readonly internalType: "uint256";
36
- readonly name: "";
37
- readonly type: "uint256";
38
- }];
39
- readonly stateMutability: "view";
40
- readonly type: "function";
41
- }, {
42
- readonly inputs: readonly [{
43
- readonly internalType: "address";
44
- readonly name: "_user";
45
- readonly type: "address";
46
- }];
47
- readonly name: "getUserCredit";
48
- readonly outputs: readonly [{
49
- readonly internalType: "uint256";
50
- readonly name: "";
51
- readonly type: "uint256";
52
- }];
53
- readonly stateMutability: "view";
54
- readonly type: "function";
55
- }, {
56
- readonly inputs: readonly [];
57
- readonly name: "owner";
58
- readonly outputs: readonly [{
59
- readonly internalType: "address";
60
- readonly name: "";
61
- readonly type: "address";
62
- }];
63
- readonly stateMutability: "view";
64
- readonly type: "function";
65
- }, {
66
- readonly inputs: readonly [];
67
- readonly name: "renounceOwnership";
68
- readonly outputs: readonly [];
69
- readonly stateMutability: "nonpayable";
70
- readonly type: "function";
71
- }, {
72
- readonly inputs: readonly [{
73
- readonly internalType: "address";
74
- readonly name: "newOwner";
75
- readonly type: "address";
76
- }];
77
- readonly name: "transferOwnership";
78
- readonly outputs: readonly [];
79
- readonly stateMutability: "nonpayable";
80
- readonly type: "function";
81
- }, {
82
- readonly inputs: readonly [{
83
- readonly internalType: "uint256";
84
- readonly name: "_newCeiling";
85
- readonly type: "uint256";
86
- }];
87
- readonly name: "updateCeiling";
88
- readonly outputs: readonly [];
89
- readonly stateMutability: "nonpayable";
90
- readonly type: "function";
91
- }];
92
- //# sourceMappingURL=ICake.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ICake.d.ts","sourceRoot":"","sources":["../../src/abis/ICake.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA0DX,CAAA"}
@@ -1,16 +0,0 @@
1
- import { ChainId } from '@pancakeswap/chains';
2
- import { Address, WalletClient, GetContractReturnType, PublicClient } from 'viem';
3
- import { iCakeABI } from '../abis/ICake';
4
- import { OnChainProvider } from '../types';
5
- export declare const getIfoCreditAddressContract: (chainId: ChainId, provider: OnChainProvider, walletClient?: WalletClient) => GetContractReturnType<typeof iCakeABI, PublicClient, WalletClient>;
6
- export declare const fetchPublicIfoData: (chainId: ChainId, provider: OnChainProvider) => Promise<{
7
- ceiling: string;
8
- }>;
9
- interface Params {
10
- account: Address;
11
- chainId: ChainId;
12
- provider: OnChainProvider;
13
- }
14
- export declare const fetchUserIfoCredit: ({ account, chainId, provider }: Params) => Promise<string>;
15
- export {};
16
- //# sourceMappingURL=fetchUserIfo.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"fetchUserIfo.d.ts","sourceRoot":"","sources":["../../src/queries/fetchUserIfo.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAA;AAC7C,OAAO,EAAE,OAAO,EAAe,YAAY,EAAE,qBAAqB,EAAE,YAAY,EAAE,MAAM,MAAM,CAAA;AAE9F,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AAExC,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAG1C,eAAO,MAAM,2BAA2B,YAC7B,OAAO,YACN,eAAe,iBACV,YAAY,KAC1B,sBAAsB,eAAe,EAAE,YAAY,EAAE,YAAY,CAOnE,CAAA;AAED,eAAO,MAAM,kBAAkB,YAAmB,OAAO,YAAY,eAAe;;EAYnF,CAAA;AAED,UAAU,MAAM;IACd,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,EAAE,OAAO,CAAA;IAChB,QAAQ,EAAE,eAAe,CAAA;CAC1B;AAED,eAAO,MAAM,kBAAkB,mCAA0C,MAAM,oBAS9E,CAAA"}