@gearbox-protocol/permissionless-ui 1.22.0-next.43 → 1.22.0-next.44
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),u=require("@gearbox-protocol/static"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),u=require("@gearbox-protocol/static"),b=require("class-variance-authority"),j=require("react");require("@gearbox-protocol/sdk");const p=require("../../utils/cn.cjs");require("sonner");const q=require("../tooltip/simple-tooltip.cjs");function H(r){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const t in r)if(t!=="default"){const o=Object.getOwnPropertyDescriptor(r,t);Object.defineProperty(e,t,o.get?o:{enumerable:!0,get:()=>r[t]})}}return e.default=r,Object.freeze(e)}const s=H(j),I=b.cva("transition-colors",{variants:{iconColor:{"gray-10":"text-gray-10","gray-20":"text-gray-20","gray-30":"text-gray-30","gray-40":"text-gray-40","gray-50":"text-gray-50","gray-60":"text-gray-60","gray-70":"text-gray-70","gray-80":"text-gray-80","gray-90":"text-gray-90","gray-100":"text-gray-100","gray-110":"text-gray-110",muted:"text-secondary-foreground",foreground:"text-foreground"},iconHoverColor:{"gray-10":"hover:text-gray-10","gray-20":"hover:text-gray-20","gray-30":"hover:text-gray-30","gray-40":"hover:text-gray-40","gray-50":"hover:text-gray-50","gray-60":"hover:text-gray-60","gray-70":"hover:text-gray-70","gray-80":"hover:text-gray-80","gray-90":"hover:text-gray-90","gray-100":"hover:text-gray-100","gray-110":"hover:text-gray-110",muted:"hover:text-secondary-foreground",foreground:"hover:text-foreground"}},defaultVariants:{iconColor:"gray-90",iconHoverColor:"gray-110"}}),x=s.forwardRef(({className:r,children:e,maxWidth:t,minWidth:o,delayShow:n=200,placement:g="bottom",iconSize:i=14,iconColor:y="gray-90",iconHoverColor:c="gray-110",iconVariant:f="question",onPointerEnter:h,...m},v)=>{const T=a.jsx(l,{ref:v,iconSize:i,iconColor:y,iconHoverColor:c,iconVariant:f,onPointerEnter:h,className:r,...m});return a.jsx(q.SimpleTooltip,{title:T,placement:g,delayShow:n,maxWidth:t,minWidth:o,children:e})});x.displayName="HelpTip";const l=s.forwardRef(({className:r,iconSize:e=14,iconColor:t="gray-90",iconHoverColor:o="gray-110",iconVariant:n="question",onPointerEnter:g,...i},y)=>{const c=n==="question"?u.IconQuestionCircle:u.IconInfo;return a.jsx("span",{ref:y,role:"img","aria-hidden":!0,className:p.cn("inline-block cursor-help",I({iconColor:t,iconHoverColor:o}),r),style:{width:e,height:e},onPointerEnter:g,...i,children:a.jsx(c,{size:e})})});l.displayName="HelpTipIcon";const d=s.forwardRef(({className:r,...e},t)=>a.jsx("span",{ref:t,className:p.cn("ml-1.5 inline-block leading-none",r),...e}));d.displayName="TipWrap";exports.HelpTip=x;exports.HelpTipIcon=l;exports.TipWrap=d;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { IconQuestionCircle as u, IconInfo as v } from "@gearbox-protocol/static";
|
|
3
3
|
import { cva as T } from "class-variance-authority";
|
|
4
4
|
import * as l from "react";
|
|
5
5
|
import "@gearbox-protocol/sdk";
|
|
6
|
-
import { cn as
|
|
6
|
+
import { cn as p } from "../../utils/cn.js";
|
|
7
7
|
import "sonner";
|
|
8
8
|
import { SimpleTooltip as C } from "../tooltip/simple-tooltip.js";
|
|
9
9
|
const H = T("transition-colors", {
|
|
@@ -44,7 +44,7 @@ const H = T("transition-colors", {
|
|
|
44
44
|
({
|
|
45
45
|
className: t,
|
|
46
46
|
children: r,
|
|
47
|
-
maxWidth:
|
|
47
|
+
maxWidth: o,
|
|
48
48
|
minWidth: a,
|
|
49
49
|
delayShow: g = 200,
|
|
50
50
|
placement: y = "bottom",
|
|
@@ -55,8 +55,8 @@ const H = T("transition-colors", {
|
|
|
55
55
|
onPointerEnter: m,
|
|
56
56
|
...d
|
|
57
57
|
}, f) => {
|
|
58
|
-
const h = /* @__PURE__ */
|
|
59
|
-
|
|
58
|
+
const h = /* @__PURE__ */ e(
|
|
59
|
+
c,
|
|
60
60
|
{
|
|
61
61
|
ref: f,
|
|
62
62
|
iconSize: n,
|
|
@@ -68,13 +68,13 @@ const H = T("transition-colors", {
|
|
|
68
68
|
...d
|
|
69
69
|
}
|
|
70
70
|
);
|
|
71
|
-
return /* @__PURE__ */
|
|
71
|
+
return /* @__PURE__ */ e(
|
|
72
72
|
C,
|
|
73
73
|
{
|
|
74
74
|
title: h,
|
|
75
75
|
placement: y,
|
|
76
76
|
delayShow: g,
|
|
77
|
-
maxWidth:
|
|
77
|
+
maxWidth: o,
|
|
78
78
|
minWidth: a,
|
|
79
79
|
children: r
|
|
80
80
|
}
|
|
@@ -82,48 +82,48 @@ const H = T("transition-colors", {
|
|
|
82
82
|
}
|
|
83
83
|
);
|
|
84
84
|
I.displayName = "HelpTip";
|
|
85
|
-
const
|
|
85
|
+
const c = l.forwardRef(
|
|
86
86
|
({
|
|
87
87
|
className: t,
|
|
88
88
|
iconSize: r = 14,
|
|
89
|
-
iconColor:
|
|
89
|
+
iconColor: o = "gray-90",
|
|
90
90
|
iconHoverColor: a = "gray-110",
|
|
91
91
|
iconVariant: g = "question",
|
|
92
92
|
onPointerEnter: y,
|
|
93
93
|
...n
|
|
94
94
|
}, i) => {
|
|
95
95
|
const s = g === "question" ? u : v;
|
|
96
|
-
return /* @__PURE__ */
|
|
96
|
+
return /* @__PURE__ */ e(
|
|
97
97
|
"span",
|
|
98
98
|
{
|
|
99
99
|
ref: i,
|
|
100
100
|
role: "img",
|
|
101
101
|
"aria-hidden": !0,
|
|
102
|
-
className:
|
|
103
|
-
"inline-
|
|
104
|
-
H({ iconColor:
|
|
102
|
+
className: p(
|
|
103
|
+
"inline-block cursor-help",
|
|
104
|
+
H({ iconColor: o, iconHoverColor: a }),
|
|
105
105
|
t
|
|
106
106
|
),
|
|
107
107
|
style: { width: r, height: r },
|
|
108
108
|
onPointerEnter: y,
|
|
109
109
|
...n,
|
|
110
|
-
children: /* @__PURE__ */
|
|
110
|
+
children: /* @__PURE__ */ e(s, { size: r })
|
|
111
111
|
}
|
|
112
112
|
);
|
|
113
113
|
}
|
|
114
114
|
);
|
|
115
|
-
|
|
116
|
-
const N = l.forwardRef(({ className: t, ...r },
|
|
115
|
+
c.displayName = "HelpTipIcon";
|
|
116
|
+
const N = l.forwardRef(({ className: t, ...r }, o) => /* @__PURE__ */ e(
|
|
117
117
|
"span",
|
|
118
118
|
{
|
|
119
|
-
ref:
|
|
120
|
-
className:
|
|
119
|
+
ref: o,
|
|
120
|
+
className: p("ml-1.5 inline-block leading-none", t),
|
|
121
121
|
...r
|
|
122
122
|
}
|
|
123
123
|
));
|
|
124
124
|
N.displayName = "TipWrap";
|
|
125
125
|
export {
|
|
126
126
|
I as HelpTip,
|
|
127
|
-
|
|
127
|
+
c as HelpTipIcon,
|
|
128
128
|
N as TipWrap
|
|
129
129
|
};
|