@gearbox-protocol/ui-kit 4.0.0-next.20 → 4.0.0-next.21

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 (30) hide show
  1. package/dist/cjs/components/base/position-assets/position-assets.cjs +1 -1
  2. package/dist/cjs/components/base/strategy-apy-breakdown-card/constants.cjs +1 -1
  3. package/dist/cjs/components/base/strategy-apy-breakdown-card/strategy-apy-breakdown-card.cjs +1 -1
  4. package/dist/cjs/components/base/values/scalars.cjs +1 -1
  5. package/dist/cjs/components/compound-apy/compound-apy.cjs +1 -1
  6. package/dist/cjs/components/yield-breakdown-tooltip/yield-breakdown-tooltip.cjs +1 -1
  7. package/dist/cjs/index.cjs +1 -1
  8. package/dist/cjs/locale/en.json.cjs +1 -1
  9. package/dist/cjs/utils/index.cjs +1 -1
  10. package/dist/esm/components/base/position-assets/position-assets.js +62 -39
  11. package/dist/esm/components/base/strategy-apy-breakdown-card/constants.js +7 -3
  12. package/dist/esm/components/base/strategy-apy-breakdown-card/strategy-apy-breakdown-card.js +140 -166
  13. package/dist/esm/components/base/values/scalars.js +40 -35
  14. package/dist/esm/components/compound-apy/compound-apy.js +24 -23
  15. package/dist/esm/components/yield-breakdown-tooltip/yield-breakdown-tooltip.js +15 -15
  16. package/dist/esm/index.js +88 -91
  17. package/dist/esm/locale/en.json.js +3 -7
  18. package/dist/esm/utils/index.js +48 -51
  19. package/dist/globals.css +1 -1
  20. package/dist/types/components/base/position-assets/position-assets.d.ts +19 -13
  21. package/dist/types/components/base/strategy-apy-breakdown-card/constants.d.ts +5 -1
  22. package/dist/types/components/base/strategy-apy-breakdown-card/strategy-apy-breakdown-card.d.ts +39 -14
  23. package/dist/types/components/base/values/scalars.d.ts +17 -2
  24. package/dist/types/components/compound-apy/compound-apy.d.ts +11 -1
  25. package/dist/types/locale/en.json.d.ts +1 -6
  26. package/dist/types/utils/index.d.ts +0 -1
  27. package/package.json +1 -1
  28. package/dist/cjs/utils/strategy-apy.cjs +0 -1
  29. package/dist/esm/utils/strategy-apy.js +0 -51
  30. package/dist/types/utils/strategy-apy.d.ts +0 -40
@@ -1,12 +1,12 @@
1
1
  import { generateId as r, useFormFieldIds as t } from "./a11y.js";
2
- import { pointProgramsOf as m, positiveTokenRewardsOf as n, tokenRewardsOf as p, totalApyOf as i } from "./apy-breakdown.js";
3
- import { bnToInputView as s } from "./bn-to-input-view.js";
2
+ import { pointProgramsOf as m, positiveTokenRewardsOf as n, tokenRewardsOf as i, totalApyOf as p } from "./apy-breakdown.js";
3
+ import { bnToInputView as l } from "./bn-to-input-view.js";
4
4
  import { bnToPrettyView as x } from "./bn-to-pretty-view.js";
5
- import { bpsToPercent as g } from "./bps.js";
5
+ import { bpsToPercent as c } from "./bps.js";
6
6
  import { cn as S, cn as d } from "./cn.js";
7
- import { generateColorsFromBase as h, getCSSVariable as A, hexToRgba as v, hslToHex as y, resolveCSSColor as P } from "./colors.js";
7
+ import { generateColorsFromBase as h, getCSSVariable as v, hexToRgba as P, hslToHex as b, resolveCSSColor as A } from "./colors.js";
8
8
  import { copyToClipboard as N } from "./copy.js";
9
- import { convertPercent as I, formatBytecodeSize as k, formatBytecodeVersion as C, formatTimestamp as w, shortenHash as F, significantTrunc as D } from "./format.js";
9
+ import { convertPercent as L, formatBytecodeSize as y, formatBytecodeVersion as C, formatTimestamp as w, shortenHash as F, significantTrunc as D } from "./format.js";
10
10
  import { formatAssetAmount as V } from "./format-asset-amount.js";
11
11
  import { formatLeverage as M } from "./format-leverage.js";
12
12
  import { formatCompactPercent as _, formatMoney as E, formatMoneyAmount as H, formatPercentAmount as W, percentTemplate as Z, percentageTemplate as z } from "./format-money.js";
@@ -14,42 +14,41 @@ import { FORMAT_CONSTANTS as X, formatNumberWithSuffix as q, formatPrice as j, g
14
14
  import { slippageTemplate as $ } from "./format-slippage.js";
15
15
  import { formatChipLeverage as oe, leveragePresets as re } from "./leverage-presets.js";
16
16
  import { allLoaded as ae, loadingProgress as me, round5 as ne } from "./loading.js";
17
- import { decimalsToStep as ie, findClosestPoint as fe, formatWithDecimals as se, formatWithoutDecimals as le, splitInterval as xe, validateMinMax as Te } from "./math.js";
18
- import { getNetworkIcon as ce } from "./network-icons.js";
19
- import { bnToLiquidationPriceView as de, isPositiveFloat as ue, parseInputToBN as he, parseSmallNumber as Ae } from "./parse-input-to-bn.js";
20
- import { pluralize as ye, selectPluralString as Pe } from "./plural.js";
17
+ import { decimalsToStep as pe, findClosestPoint as fe, formatWithDecimals as le, formatWithoutDecimals as se, splitInterval as xe, validateMinMax as Te } from "./math.js";
18
+ import { getNetworkIcon as ge } from "./network-icons.js";
19
+ import { bnToLiquidationPriceView as de, isPositiveFloat as ue, parseInputToBN as he, parseSmallNumber as ve } from "./parse-input-to-bn.js";
20
+ import { pluralize as be, selectPluralString as Ae } from "./plural.js";
21
21
  import { getAvailableRanges as Ne } from "./ranges.js";
22
- import { extractTextFromLabel as Ie, serializeValue as ke } from "./react.js";
22
+ import { extractTextFromLabel as Le, serializeValue as ye } from "./react.js";
23
23
  import { searchInString as we } from "./search.js";
24
24
  import { createTokenSearchFilter as De, searchInToken as Oe } from "./search-in-token.js";
25
25
  import { shortSHA as Be } from "./short-sha.js";
26
26
  import { isLongString as Re, shortenString as _e } from "./shorten-string.js";
27
- import { strategyApyPartsAtLeverage as He, strategyNetApyAtLeverage as We } from "./strategy-apy.js";
28
- import { negativeTokenTemplate as ze, tokenTemplate as Ue, tokenTemplateNumber as Xe, tokenTemplateString as qe } from "./templates.js";
29
- import { getTokenIcon as Ge, parseShareTokenUnderlying as Je } from "./token-icon-source.js";
30
- import { TTL_CONSTANTS as Qe, getTTLZones as Ye, ttlFromTimestamp as $e, ttlLeft as eo, ttlLeftHuman as oo } from "./ttl.js";
31
- import { openInNewWindow as to } from "./window.js";
32
- import { Z_INDEX as mo, Z_INDEX_VALUES as no } from "./z-index.js";
27
+ import { negativeTokenTemplate as He, tokenTemplate as We, tokenTemplateNumber as Ze, tokenTemplateString as ze } from "./templates.js";
28
+ import { getTokenIcon as Xe, parseShareTokenUnderlying as qe } from "./token-icon-source.js";
29
+ import { TTL_CONSTANTS as Ge, getTTLZones as Je, ttlFromTimestamp as Ke, ttlLeft as Qe, ttlLeftHuman as Ye } from "./ttl.js";
30
+ import { openInNewWindow as eo } from "./window.js";
31
+ import { Z_INDEX as ro, Z_INDEX_VALUES as to } from "./z-index.js";
33
32
  export {
34
33
  X as FORMAT_CONSTANTS,
35
- Qe as TTL_CONSTANTS,
36
- mo as Z_INDEX,
37
- no as Z_INDEX_VALUES,
34
+ Ge as TTL_CONSTANTS,
35
+ ro as Z_INDEX,
36
+ to as Z_INDEX_VALUES,
38
37
  ae as allLoaded,
39
- s as bnToInputView,
38
+ l as bnToInputView,
40
39
  de as bnToLiquidationPriceView,
41
40
  x as bnToPrettyView,
42
- g as bpsToPercent,
41
+ c as bpsToPercent,
43
42
  S as cn,
44
- I as convertPercent,
43
+ L as convertPercent,
45
44
  N as copyToClipboard,
46
45
  De as createTokenSearchFilter,
47
- ie as decimalsToStep,
46
+ pe as decimalsToStep,
48
47
  d as default,
49
- Ie as extractTextFromLabel,
48
+ Le as extractTextFromLabel,
50
49
  fe as findClosestPoint,
51
50
  V as formatAssetAmount,
52
- k as formatBytecodeSize,
51
+ y as formatBytecodeSize,
53
52
  C as formatBytecodeVersion,
54
53
  oe as formatChipLeverage,
55
54
  _ as formatCompactPercent,
@@ -60,57 +59,55 @@ export {
60
59
  W as formatPercentAmount,
61
60
  j as formatPrice,
62
61
  w as formatTimestamp,
63
- se as formatWithDecimals,
64
- le as formatWithoutDecimals,
62
+ le as formatWithDecimals,
63
+ se as formatWithoutDecimals,
65
64
  h as generateColorsFromBase,
66
65
  r as generateId,
67
66
  G as getAdaptiveDecimals,
68
67
  Ne as getAvailableRanges,
69
- A as getCSSVariable,
70
- ce as getNetworkIcon,
71
- Ye as getTTLZones,
72
- Ge as getTokenIcon,
73
- v as hexToRgba,
74
- y as hslToHex,
68
+ v as getCSSVariable,
69
+ ge as getNetworkIcon,
70
+ Je as getTTLZones,
71
+ Xe as getTokenIcon,
72
+ P as hexToRgba,
73
+ b as hslToHex,
75
74
  J as isBelowDisplayThreshold,
76
75
  K as isEffectivelyZero,
77
76
  Re as isLongString,
78
77
  ue as isPositiveFloat,
79
78
  re as leveragePresets,
80
79
  me as loadingProgress,
81
- ze as negativeTokenTemplate,
82
- to as openInNewWindow,
80
+ He as negativeTokenTemplate,
81
+ eo as openInNewWindow,
83
82
  he as parseInputToBN,
84
- Je as parseShareTokenUnderlying,
85
- Ae as parseSmallNumber,
83
+ qe as parseShareTokenUnderlying,
84
+ ve as parseSmallNumber,
86
85
  Z as percentTemplate,
87
86
  z as percentageTemplate,
88
- ye as pluralize,
87
+ be as pluralize,
89
88
  m as pointProgramsOf,
90
89
  n as positiveTokenRewardsOf,
91
- P as resolveCSSColor,
90
+ A as resolveCSSColor,
92
91
  ne as round5,
93
92
  we as searchInString,
94
93
  Oe as searchInToken,
95
- Pe as selectPluralString,
96
- ke as serializeValue,
94
+ Ae as selectPluralString,
95
+ ye as serializeValue,
97
96
  Be as shortSHA,
98
97
  F as shortenHash,
99
98
  _e as shortenString,
100
99
  D as significantTrunc,
101
100
  $ as slippageTemplate,
102
101
  xe as splitInterval,
103
- He as strategyApyPartsAtLeverage,
104
- We as strategyNetApyAtLeverage,
105
102
  Q as toSignificantDigits,
106
- p as tokenRewardsOf,
107
- Ue as tokenTemplate,
108
- Xe as tokenTemplateNumber,
109
- qe as tokenTemplateString,
110
- i as totalApyOf,
111
- $e as ttlFromTimestamp,
112
- eo as ttlLeft,
113
- oo as ttlLeftHuman,
103
+ i as tokenRewardsOf,
104
+ We as tokenTemplate,
105
+ Ze as tokenTemplateNumber,
106
+ ze as tokenTemplateString,
107
+ p as totalApyOf,
108
+ Ke as ttlFromTimestamp,
109
+ Qe as ttlLeft,
110
+ Ye as ttlLeftHuman,
114
111
  t as useFormFieldIds,
115
112
  Te as validateMinMax
116
113
  };