@gearbox-protocol/ui-kit 3.13.0 → 3.14.0-next.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.
Files changed (25) hide show
  1. package/dist/cjs/components/composites/pool-table/columns.cjs +1 -1
  2. package/dist/cjs/components/composites/pool-table/pool-table.cjs +1 -1
  3. package/dist/cjs/components/composites/strategies-table/columns.cjs +1 -1
  4. package/dist/cjs/components/composites/strategies-table/components/cells/cells.cjs +1 -1
  5. package/dist/cjs/components/composites/strategies-table/components/rewards-tooltip/tooltip-content.cjs +1 -1
  6. package/dist/cjs/components/graph/graph.cjs +1 -1
  7. package/dist/cjs/components/layout/main-aside-layout/main-aside-layout.cjs +1 -1
  8. package/dist/cjs/locale/en.json.cjs +1 -1
  9. package/dist/esm/components/composites/pool-table/columns.js +344 -207
  10. package/dist/esm/components/composites/pool-table/pool-table.js +94 -102
  11. package/dist/esm/components/composites/strategies-table/columns.js +1 -1
  12. package/dist/esm/components/composites/strategies-table/components/cells/cells.js +31 -28
  13. package/dist/esm/components/composites/strategies-table/components/rewards-tooltip/tooltip-content.js +131 -122
  14. package/dist/esm/components/graph/graph.js +339 -293
  15. package/dist/esm/components/layout/main-aside-layout/main-aside-layout.js +70 -22
  16. package/dist/esm/locale/en.json.js +1 -0
  17. package/dist/globals.css +1 -1
  18. package/dist/types/components/composites/pool-table/columns.d.ts +0 -2
  19. package/dist/types/components/composites/strategies-table/components/cells/cells.d.ts +2 -1
  20. package/dist/types/components/graph/graph.d.ts +8 -1
  21. package/dist/types/components/layout/main-aside-layout/main-aside-layout.d.ts +46 -5
  22. package/dist/types/components/trading-view/trading-view.d.ts +7 -0
  23. package/dist/types/locale/en.json.d.ts +1 -0
  24. package/package.json +3 -3
  25. package/src/styles/base.css +4 -2
@@ -1,35 +1,83 @@
1
- import { jsx as s, jsxs as f } from "react/jsx-runtime";
2
- import * as c from "react";
3
- import { cn as a } from "../../../utils/cn.js";
4
- const d = c.forwardRef(
1
+ import { jsx as i, jsxs as c } from "react/jsx-runtime";
2
+ import * as g from "react";
3
+ import { cn as x } from "../../../utils/cn.js";
4
+ const u = g.forwardRef(
5
5
  ({
6
- children: i,
7
- aside: e,
8
- asidePosition: l = "right",
9
- asideClassName: t,
10
- className: m,
11
- ...o
12
- }, n) => {
13
- const r = e == null ? null : /* @__PURE__ */ s("aside", { className: a("min-w-0 shrink-0", t), children: e });
14
- return /* @__PURE__ */ f(
6
+ children: r,
7
+ aside: m,
8
+ asidePosition: e = "right",
9
+ asideClassName: n,
10
+ mainClassName: p,
11
+ mainRef: t,
12
+ variant: o = "default",
13
+ className: s,
14
+ ...w
15
+ }, f) => {
16
+ const l = o === "detail", a = m == null ? null : /* @__PURE__ */ i(
17
+ "aside",
18
+ {
19
+ className: x(
20
+ "min-w-0 shrink-0",
21
+ l && [
22
+ "w-full",
23
+ "z-30 lg:w-[420px] lg:min-w-[420px] lg:max-w-[420px]",
24
+ "xl:w-[460px] xl:min-w-[460px] xl:max-w-[460px]",
25
+ "max-h-full lg:max-h-[100vh] overflow-y-visible lg:overflow-y-auto",
26
+ // sticky below 2450px, fixed at ≥2450px
27
+ "lg:max-[2449px]:sticky lg:max-[2449px]:top-4",
28
+ "min-[2450px]:fixed min-[2450px]:top-28 min-[2450px]:right-32"
29
+ ],
30
+ n
31
+ ),
32
+ children: m
33
+ }
34
+ );
35
+ return /* @__PURE__ */ c(
15
36
  "div",
16
37
  {
17
- ref: n,
18
- className: a(
38
+ ref: f,
39
+ className: x(
40
+ // base: mobile stack (column-reverse), desktop row
19
41
  "flex w-full flex-col-reverse gap-6 lg:flex-row lg:items-start",
20
- m
42
+ l && [
43
+ "relative mx-auto min-w-0",
44
+ // cap width so aside doesn't overflow on medium-wide screens
45
+ "max-w-[calc(80rem+420px+1.5rem)]",
46
+ "xl:max-w-[calc(80rem+460px+1.5rem)]",
47
+ // at ≥2450px aside is fixed → switch wrapper to block so main can
48
+ // centre independently
49
+ "min-[2450px]:block min-[2450px]:max-w-none min-[2450px]:gap-0"
50
+ ],
51
+ s
21
52
  ),
22
- ...o,
53
+ ...w,
23
54
  children: [
24
- l === "left" && r,
25
- /* @__PURE__ */ s("div", { className: "min-w-0 flex-1", children: i }),
26
- l === "right" && r
55
+ e === "left" && a,
56
+ /* @__PURE__ */ i(
57
+ "div",
58
+ {
59
+ ref: t,
60
+ className: x(
61
+ "min-w-0 flex-1",
62
+ l && [
63
+ "relative z-0 w-full",
64
+ // at ≥2450px: stop growing and centre with explicit max-width
65
+ // (leaves room for the fixed 460px aside + 8rem right offset)
66
+ "min-[2450px]:mx-auto min-[2450px]:flex-none",
67
+ "min-[2450px]:max-w-[min(80rem,calc(100vw-460px-8rem))]"
68
+ ],
69
+ p
70
+ ),
71
+ children: r
72
+ }
73
+ ),
74
+ e === "right" && a
27
75
  ]
28
76
  }
29
77
  );
30
78
  }
31
79
  );
32
- d.displayName = "MainAsideLayout";
80
+ u.displayName = "MainAsideLayout";
33
81
  export {
34
- d as MainAsideLayout
82
+ u as MainAsideLayout
35
83
  };
@@ -102,6 +102,7 @@ const e = {
102
102
  "components.poolTable.notFound.description.dashboard": "Choose earn above.",
103
103
  "components.poolTable.notFound.description.list": "Choose another chain or toggle Show All Markets",
104
104
  "components.poolTable.externalApy.tooltipShort": "{value} APY boost when depositing via {name}",
105
+ "components.poolTable.line.rwa.tip": "This is RWA market.",
105
106
  "components.rewardsTooltip.without.title": "Without Leverage",
106
107
  "components.rewardsTooltip.without.extra": "Extra APY",
107
108
  "components.rewardsTooltip.without.extra.tip": "Any deposit through Gearbox",