@pismo/marola 2.1.18 → 2.1.19
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.
|
@@ -22,7 +22,7 @@ declare const meta: {
|
|
|
22
22
|
open?: boolean | undefined;
|
|
23
23
|
onClose?: (() => void) | undefined;
|
|
24
24
|
content: import('react').ReactNode;
|
|
25
|
-
position?: import('@floating-ui/
|
|
25
|
+
position?: import('@floating-ui/react-dom').Placement | undefined;
|
|
26
26
|
disablePortal?: boolean | undefined;
|
|
27
27
|
arialRole?: import('react').AriaRole | undefined;
|
|
28
28
|
disableHoverListener?: boolean | undefined;
|
|
@@ -1,59 +1,285 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import * as
|
|
3
|
-
import { useRef as
|
|
4
|
-
import { T as
|
|
5
|
-
import { c as
|
|
6
|
-
import { _ as
|
|
7
|
-
import { C as
|
|
8
|
-
import '../../assets/Tooltip.css';function
|
|
9
|
-
const
|
|
10
|
-
if (!
|
|
1
|
+
import { jsx as x, jsxs as $, Fragment as et } from "react/jsx-runtime";
|
|
2
|
+
import * as j from "react";
|
|
3
|
+
import { useRef as ot, useState as G, useEffect as J, isValidElement as nt, cloneElement as it } from "react";
|
|
4
|
+
import { T as rt, P as at } from "../../Popup-aWlctE1C.js";
|
|
5
|
+
import { c as X } from "../../clsx-OuTLNxxd.js";
|
|
6
|
+
import { _ as lt, b as st, P as O } from "../../useSlotProps-C7dqSmdM.js";
|
|
7
|
+
import { C as ct } from "../../ClickAwayListener-BjqhGzJh.js";
|
|
8
|
+
import '../../assets/Tooltip.css';function pt() {
|
|
9
|
+
const t = j.useContext(rt);
|
|
10
|
+
if (!t)
|
|
11
11
|
throw new Error("Missing transition context");
|
|
12
12
|
const {
|
|
13
|
-
registerTransition:
|
|
14
|
-
requestedEnter:
|
|
15
|
-
onExited:
|
|
16
|
-
} =
|
|
17
|
-
return
|
|
18
|
-
onExited:
|
|
19
|
-
requestedEnter:
|
|
13
|
+
registerTransition: e,
|
|
14
|
+
requestedEnter: i,
|
|
15
|
+
onExited: n
|
|
16
|
+
} = t;
|
|
17
|
+
return j.useEffect(() => e(), [e]), {
|
|
18
|
+
onExited: n,
|
|
19
|
+
requestedEnter: i
|
|
20
20
|
};
|
|
21
21
|
}
|
|
22
|
-
const
|
|
23
|
-
function
|
|
22
|
+
const ft = ["children", "className", "enterAnimationName", "enterClassName", "exitAnimationName", "exitClassName"];
|
|
23
|
+
function Y(t) {
|
|
24
24
|
const {
|
|
25
|
-
children:
|
|
26
|
-
className:
|
|
27
|
-
enterAnimationName:
|
|
28
|
-
enterClassName:
|
|
29
|
-
exitAnimationName:
|
|
30
|
-
exitClassName:
|
|
31
|
-
} =
|
|
32
|
-
requestedEnter:
|
|
33
|
-
onExited:
|
|
34
|
-
} =
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
}, [
|
|
38
|
-
const
|
|
39
|
-
|
|
40
|
-
}, [
|
|
41
|
-
return /* @__PURE__ */
|
|
42
|
-
onAnimationEnd:
|
|
43
|
-
className:
|
|
44
|
-
},
|
|
45
|
-
children:
|
|
25
|
+
children: e,
|
|
26
|
+
className: i,
|
|
27
|
+
enterAnimationName: n,
|
|
28
|
+
enterClassName: r,
|
|
29
|
+
exitAnimationName: o,
|
|
30
|
+
exitClassName: l
|
|
31
|
+
} = t, s = lt(t, ft), {
|
|
32
|
+
requestedEnter: f,
|
|
33
|
+
onExited: c
|
|
34
|
+
} = pt(), m = j.useRef(!0);
|
|
35
|
+
j.useEffect(() => {
|
|
36
|
+
f && m.current && (m.current = !1);
|
|
37
|
+
}, [f]);
|
|
38
|
+
const g = j.useCallback((a) => {
|
|
39
|
+
a.animationName === o ? (c(), m.current = !0) : a.animationName === n && (m.current = !1);
|
|
40
|
+
}, [c, o, n]);
|
|
41
|
+
return /* @__PURE__ */ x("div", st({
|
|
42
|
+
onAnimationEnd: g,
|
|
43
|
+
className: X(i, f ? r : l)
|
|
44
|
+
}, s, {
|
|
45
|
+
children: e
|
|
46
46
|
}));
|
|
47
47
|
}
|
|
48
|
-
process.env.NODE_ENV !== "production" && (
|
|
49
|
-
children:
|
|
50
|
-
className:
|
|
51
|
-
enterAnimationName:
|
|
52
|
-
enterClassName:
|
|
53
|
-
exitAnimationName:
|
|
54
|
-
exitClassName:
|
|
48
|
+
process.env.NODE_ENV !== "production" && (Y.propTypes = {
|
|
49
|
+
children: O.node,
|
|
50
|
+
className: O.string,
|
|
51
|
+
enterAnimationName: O.string,
|
|
52
|
+
enterClassName: O.string,
|
|
53
|
+
exitAnimationName: O.string,
|
|
54
|
+
exitClassName: O.string
|
|
55
55
|
});
|
|
56
|
-
const
|
|
56
|
+
const mt = {
|
|
57
|
+
left: "right",
|
|
58
|
+
right: "left",
|
|
59
|
+
bottom: "top",
|
|
60
|
+
top: "bottom"
|
|
61
|
+
}, ut = {
|
|
62
|
+
start: "end",
|
|
63
|
+
end: "start"
|
|
64
|
+
};
|
|
65
|
+
function Z(t, e) {
|
|
66
|
+
return typeof t == "function" ? t(e) : t;
|
|
67
|
+
}
|
|
68
|
+
function F(t) {
|
|
69
|
+
return t.split("-")[0];
|
|
70
|
+
}
|
|
71
|
+
function H(t) {
|
|
72
|
+
return t.split("-")[1];
|
|
73
|
+
}
|
|
74
|
+
function _t(t) {
|
|
75
|
+
return t === "x" ? "y" : "x";
|
|
76
|
+
}
|
|
77
|
+
function ht(t) {
|
|
78
|
+
return t === "y" ? "height" : "width";
|
|
79
|
+
}
|
|
80
|
+
const gt = /* @__PURE__ */ new Set(["top", "bottom"]);
|
|
81
|
+
function M(t) {
|
|
82
|
+
return gt.has(F(t)) ? "y" : "x";
|
|
83
|
+
}
|
|
84
|
+
function dt(t) {
|
|
85
|
+
return _t(M(t));
|
|
86
|
+
}
|
|
87
|
+
function yt(t, e, i) {
|
|
88
|
+
i === void 0 && (i = !1);
|
|
89
|
+
const n = H(t), r = dt(t), o = ht(r);
|
|
90
|
+
let l = r === "x" ? n === (i ? "end" : "start") ? "right" : "left" : n === "start" ? "bottom" : "top";
|
|
91
|
+
return e.reference[o] > e.floating[o] && (l = L(l)), [l, L(l)];
|
|
92
|
+
}
|
|
93
|
+
function xt(t) {
|
|
94
|
+
const e = L(t);
|
|
95
|
+
return [q(t), e, q(e)];
|
|
96
|
+
}
|
|
97
|
+
function q(t) {
|
|
98
|
+
return t.replace(/start|end/g, (e) => ut[e]);
|
|
99
|
+
}
|
|
100
|
+
const K = ["left", "right"], Q = ["right", "left"], bt = ["top", "bottom"], vt = ["bottom", "top"];
|
|
101
|
+
function wt(t, e, i) {
|
|
102
|
+
switch (t) {
|
|
103
|
+
case "top":
|
|
104
|
+
case "bottom":
|
|
105
|
+
return i ? e ? Q : K : e ? K : Q;
|
|
106
|
+
case "left":
|
|
107
|
+
case "right":
|
|
108
|
+
return e ? bt : vt;
|
|
109
|
+
default:
|
|
110
|
+
return [];
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
function At(t, e, i, n) {
|
|
114
|
+
const r = H(t);
|
|
115
|
+
let o = wt(F(t), i === "start", n);
|
|
116
|
+
return r && (o = o.map((l) => l + "-" + r), e && (o = o.concat(o.map(q)))), o;
|
|
117
|
+
}
|
|
118
|
+
function L(t) {
|
|
119
|
+
return t.replace(/left|right|bottom|top/g, (e) => mt[e]);
|
|
120
|
+
}
|
|
121
|
+
function Pt(t) {
|
|
122
|
+
return {
|
|
123
|
+
top: 0,
|
|
124
|
+
right: 0,
|
|
125
|
+
bottom: 0,
|
|
126
|
+
left: 0,
|
|
127
|
+
...t
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
function Nt(t) {
|
|
131
|
+
return typeof t != "number" ? Pt(t) : {
|
|
132
|
+
top: t,
|
|
133
|
+
right: t,
|
|
134
|
+
bottom: t,
|
|
135
|
+
left: t
|
|
136
|
+
};
|
|
137
|
+
}
|
|
138
|
+
function U(t) {
|
|
139
|
+
const {
|
|
140
|
+
x: e,
|
|
141
|
+
y: i,
|
|
142
|
+
width: n,
|
|
143
|
+
height: r
|
|
144
|
+
} = t;
|
|
145
|
+
return {
|
|
146
|
+
width: n,
|
|
147
|
+
height: r,
|
|
148
|
+
top: i,
|
|
149
|
+
left: e,
|
|
150
|
+
right: e + n,
|
|
151
|
+
bottom: i + r,
|
|
152
|
+
x: e,
|
|
153
|
+
y: i
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
async function kt(t, e) {
|
|
157
|
+
var i;
|
|
158
|
+
e === void 0 && (e = {});
|
|
159
|
+
const {
|
|
160
|
+
x: n,
|
|
161
|
+
y: r,
|
|
162
|
+
platform: o,
|
|
163
|
+
rects: l,
|
|
164
|
+
elements: s,
|
|
165
|
+
strategy: f
|
|
166
|
+
} = t, {
|
|
167
|
+
boundary: c = "clippingAncestors",
|
|
168
|
+
rootBoundary: m = "viewport",
|
|
169
|
+
elementContext: g = "floating",
|
|
170
|
+
altBoundary: a = !1,
|
|
171
|
+
padding: S = 0
|
|
172
|
+
} = Z(e, t), p = Nt(S), b = s[a ? g === "floating" ? "reference" : "floating" : g], w = U(await o.getClippingRect({
|
|
173
|
+
element: (i = await (o.isElement == null ? void 0 : o.isElement(b))) == null || i ? b : b.contextElement || await (o.getDocumentElement == null ? void 0 : o.getDocumentElement(s.floating)),
|
|
174
|
+
boundary: c,
|
|
175
|
+
rootBoundary: m,
|
|
176
|
+
strategy: f
|
|
177
|
+
})), v = g === "floating" ? {
|
|
178
|
+
x: n,
|
|
179
|
+
y: r,
|
|
180
|
+
width: l.floating.width,
|
|
181
|
+
height: l.floating.height
|
|
182
|
+
} : l.reference, P = await (o.getOffsetParent == null ? void 0 : o.getOffsetParent(s.floating)), d = await (o.isElement == null ? void 0 : o.isElement(P)) ? await (o.getScale == null ? void 0 : o.getScale(P)) || {
|
|
183
|
+
x: 1,
|
|
184
|
+
y: 1
|
|
185
|
+
} : {
|
|
186
|
+
x: 1,
|
|
187
|
+
y: 1
|
|
188
|
+
}, y = U(o.convertOffsetParentRelativeRectToViewportRelativeRect ? await o.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
189
|
+
elements: s,
|
|
190
|
+
rect: v,
|
|
191
|
+
offsetParent: P,
|
|
192
|
+
strategy: f
|
|
193
|
+
}) : v);
|
|
194
|
+
return {
|
|
195
|
+
top: (w.top - y.top + p.top) / d.y,
|
|
196
|
+
bottom: (y.bottom - w.bottom + p.bottom) / d.y,
|
|
197
|
+
left: (w.left - y.left + p.left) / d.x,
|
|
198
|
+
right: (y.right - w.right + p.right) / d.x
|
|
199
|
+
};
|
|
200
|
+
}
|
|
201
|
+
const Ct = function(t) {
|
|
202
|
+
return t === void 0 && (t = {}), {
|
|
203
|
+
name: "flip",
|
|
204
|
+
options: t,
|
|
205
|
+
async fn(e) {
|
|
206
|
+
var i, n;
|
|
207
|
+
const {
|
|
208
|
+
placement: r,
|
|
209
|
+
middlewareData: o,
|
|
210
|
+
rects: l,
|
|
211
|
+
initialPlacement: s,
|
|
212
|
+
platform: f,
|
|
213
|
+
elements: c
|
|
214
|
+
} = e, {
|
|
215
|
+
mainAxis: m = !0,
|
|
216
|
+
crossAxis: g = !0,
|
|
217
|
+
fallbackPlacements: a,
|
|
218
|
+
fallbackStrategy: S = "bestFit",
|
|
219
|
+
fallbackAxisSideDirection: p = "none",
|
|
220
|
+
flipAlignment: C = !0,
|
|
221
|
+
...b
|
|
222
|
+
} = Z(t, e);
|
|
223
|
+
if ((i = o.arrow) != null && i.alignmentOffset)
|
|
224
|
+
return {};
|
|
225
|
+
const w = F(r), v = M(s), P = F(s) === s, d = await (f.isRTL == null ? void 0 : f.isRTL(c.floating)), y = a || (P || !C ? [L(s)] : xt(s)), D = p !== "none";
|
|
226
|
+
!a && D && y.push(...At(s, C, p, d));
|
|
227
|
+
const V = [s, ...y], R = await kt(e, b), E = [];
|
|
228
|
+
let u = ((n = o.flip) == null ? void 0 : n.overflows) || [];
|
|
229
|
+
if (m && E.push(R[w]), g) {
|
|
230
|
+
const N = yt(r, l, d);
|
|
231
|
+
E.push(R[N[0]], R[N[1]]);
|
|
232
|
+
}
|
|
233
|
+
if (u = [...u, {
|
|
234
|
+
placement: r,
|
|
235
|
+
overflows: E
|
|
236
|
+
}], !E.every((N) => N <= 0)) {
|
|
237
|
+
var I, z;
|
|
238
|
+
const N = (((I = o.flip) == null ? void 0 : I.index) || 0) + 1, B = V[N];
|
|
239
|
+
if (B && (!(g === "alignment" ? v !== M(B) : !1) || // We leave the current main axis only if every placement on that axis
|
|
240
|
+
// overflows the main axis.
|
|
241
|
+
u.every((_) => _.overflows[0] > 0 && M(_.placement) === v)))
|
|
242
|
+
return {
|
|
243
|
+
data: {
|
|
244
|
+
index: N,
|
|
245
|
+
overflows: u
|
|
246
|
+
},
|
|
247
|
+
reset: {
|
|
248
|
+
placement: B
|
|
249
|
+
}
|
|
250
|
+
};
|
|
251
|
+
let T = (z = u.filter((k) => k.overflows[0] <= 0).sort((k, _) => k.overflows[1] - _.overflows[1])[0]) == null ? void 0 : z.placement;
|
|
252
|
+
if (!T)
|
|
253
|
+
switch (S) {
|
|
254
|
+
case "bestFit": {
|
|
255
|
+
var W;
|
|
256
|
+
const k = (W = u.filter((_) => {
|
|
257
|
+
if (D) {
|
|
258
|
+
const A = M(_.placement);
|
|
259
|
+
return A === v || // Create a bias to the `y` side axis due to horizontal
|
|
260
|
+
// reading directions favoring greater width.
|
|
261
|
+
A === "y";
|
|
262
|
+
}
|
|
263
|
+
return !0;
|
|
264
|
+
}).map((_) => [_.placement, _.overflows.filter((A) => A > 0).reduce((A, tt) => A + tt, 0)]).sort((_, A) => _[1] - A[1])[0]) == null ? void 0 : W[0];
|
|
265
|
+
k && (T = k);
|
|
266
|
+
break;
|
|
267
|
+
}
|
|
268
|
+
case "initialPlacement":
|
|
269
|
+
T = s;
|
|
270
|
+
break;
|
|
271
|
+
}
|
|
272
|
+
if (r !== T)
|
|
273
|
+
return {
|
|
274
|
+
reset: {
|
|
275
|
+
placement: T
|
|
276
|
+
}
|
|
277
|
+
};
|
|
278
|
+
}
|
|
279
|
+
return {};
|
|
280
|
+
}
|
|
281
|
+
};
|
|
282
|
+
}, Et = Ct, Ot = "_tooltip_f9rcp_79", St = "_tooltip__container_f9rcp_125", Rt = "_tooltip__title_f9rcp_131", Tt = "_tooltip__content_f9rcp_138", Mt = "_tooltip__footer_f9rcp_145", h = {
|
|
57
283
|
"u-typography-h1": "_u-typography-h1_f9rcp_1",
|
|
58
284
|
"u-typography-h2": "_u-typography-h2_f9rcp_8",
|
|
59
285
|
"u-typography-h3": "_u-typography-h3_f9rcp_15",
|
|
@@ -69,15 +295,15 @@ const B = "_tooltip_f9rcp_79", G = "_tooltip__container_f9rcp_125", J = "_toolti
|
|
|
69
295
|
"u-typography-base--strikethrough": "_u-typography-base--strikethrough_f9rcp_68",
|
|
70
296
|
"u-typography-base--underlined": "_u-typography-base--underlined_f9rcp_71",
|
|
71
297
|
"u-typography-base--strikethrough-underlined": "_u-typography-base--strikethrough-underlined_f9rcp_74",
|
|
72
|
-
tooltip:
|
|
298
|
+
tooltip: Ot,
|
|
73
299
|
"tooltip--bottom": "_tooltip--bottom_f9rcp_96",
|
|
74
300
|
"tooltip--top": "_tooltip--top_f9rcp_103",
|
|
75
301
|
"tooltip--right": "_tooltip--right_f9rcp_110",
|
|
76
302
|
"tooltip--left": "_tooltip--left_f9rcp_117",
|
|
77
|
-
tooltip__container:
|
|
78
|
-
tooltip__title:
|
|
79
|
-
tooltip__content:
|
|
80
|
-
tooltip__footer:
|
|
303
|
+
tooltip__container: St,
|
|
304
|
+
tooltip__title: Rt,
|
|
305
|
+
tooltip__content: Tt,
|
|
306
|
+
tooltip__footer: Mt,
|
|
81
307
|
"tooltip__footer-button": "_tooltip__footer-button_f9rcp_149",
|
|
82
308
|
"tooltip__footer-link": "_tooltip__footer-link_f9rcp_169",
|
|
83
309
|
"s--animation": "_s--animation_f9rcp_180",
|
|
@@ -85,85 +311,90 @@ const B = "_tooltip_f9rcp_79", G = "_tooltip__container_f9rcp_125", J = "_toolti
|
|
|
85
311
|
"tooltip--open-animation": "_tooltip--open-animation_f9rcp_1",
|
|
86
312
|
"tooltip--anim-close": "_tooltip--anim-close_f9rcp_183",
|
|
87
313
|
"tooltip--close-animation": "_tooltip--close-animation_f9rcp_1"
|
|
88
|
-
},
|
|
89
|
-
arialRole:
|
|
90
|
-
children:
|
|
91
|
-
className:
|
|
92
|
-
disableHoverListener:
|
|
93
|
-
onClose:
|
|
94
|
-
position:
|
|
95
|
-
open:
|
|
96
|
-
title:
|
|
97
|
-
content:
|
|
98
|
-
footer:
|
|
99
|
-
onTargetCreated:
|
|
100
|
-
...
|
|
314
|
+
}, $t = ({
|
|
315
|
+
arialRole: t,
|
|
316
|
+
children: e,
|
|
317
|
+
className: i,
|
|
318
|
+
disableHoverListener: n,
|
|
319
|
+
onClose: r,
|
|
320
|
+
position: o = "bottom",
|
|
321
|
+
open: l,
|
|
322
|
+
title: s,
|
|
323
|
+
content: f,
|
|
324
|
+
footer: c,
|
|
325
|
+
onTargetCreated: m,
|
|
326
|
+
...g
|
|
101
327
|
}) => {
|
|
102
|
-
const
|
|
103
|
-
let
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
328
|
+
const a = ot(null), [S, p] = G(l || !1);
|
|
329
|
+
let C = S;
|
|
330
|
+
const [b, w] = G(o);
|
|
331
|
+
J(() => {
|
|
332
|
+
p(l || !1);
|
|
333
|
+
}, [l]);
|
|
334
|
+
const v = nt(e) ? e : /* @__PURE__ */ x("span", { children: e });
|
|
335
|
+
!f && f !== 0 && (C = !1);
|
|
336
|
+
const P = () => {
|
|
337
|
+
r == null || r(), !n && p(!1);
|
|
111
338
|
};
|
|
112
|
-
|
|
113
|
-
if (
|
|
114
|
-
const
|
|
115
|
-
|
|
339
|
+
J(() => {
|
|
340
|
+
if (a != null && a.current) {
|
|
341
|
+
const u = a == null ? void 0 : a.current;
|
|
342
|
+
m == null || m(u);
|
|
116
343
|
}
|
|
117
|
-
}, [
|
|
118
|
-
const
|
|
119
|
-
|
|
120
|
-
},
|
|
121
|
-
|
|
122
|
-
},
|
|
123
|
-
padding:
|
|
344
|
+
}, [a, n]);
|
|
345
|
+
const d = () => {
|
|
346
|
+
n || p(!0);
|
|
347
|
+
}, y = () => {
|
|
348
|
+
n || p(!1);
|
|
349
|
+
}, D = {
|
|
350
|
+
padding: b.match(/(bottom|top)/) ? ".25rem 0" : "0 .25rem",
|
|
124
351
|
zIndex: 1
|
|
125
|
-
},
|
|
126
|
-
...
|
|
127
|
-
ref:
|
|
128
|
-
onPointerEnter:
|
|
129
|
-
onPointerLeave:
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
352
|
+
}, V = X(h.tooltip, h[`tooltip--${b}`], i), R = {
|
|
353
|
+
...v.props,
|
|
354
|
+
ref: a,
|
|
355
|
+
onPointerEnter: n ? void 0 : () => p(!0),
|
|
356
|
+
onPointerLeave: n ? void 0 : () => p(!1)
|
|
357
|
+
}, E = () => ({
|
|
358
|
+
name: "currentPlacement",
|
|
359
|
+
fn: (u) => (w(u.placement), u)
|
|
360
|
+
});
|
|
361
|
+
return /* @__PURE__ */ $(et, { children: [
|
|
362
|
+
it(v, R),
|
|
363
|
+
/* @__PURE__ */ x(
|
|
364
|
+
at,
|
|
135
365
|
{
|
|
136
366
|
disablePortal: !0,
|
|
137
|
-
...
|
|
138
|
-
open:
|
|
139
|
-
anchor:
|
|
140
|
-
style:
|
|
141
|
-
role:
|
|
142
|
-
placement:
|
|
143
|
-
onPointerEnter:
|
|
144
|
-
onPointerLeave:
|
|
367
|
+
...g,
|
|
368
|
+
open: C,
|
|
369
|
+
anchor: a == null ? void 0 : a.current,
|
|
370
|
+
style: D,
|
|
371
|
+
role: t,
|
|
372
|
+
placement: b,
|
|
373
|
+
onPointerEnter: d,
|
|
374
|
+
onPointerLeave: y,
|
|
145
375
|
"data-testid": "popup",
|
|
146
|
-
|
|
147
|
-
|
|
376
|
+
middleware: [Et(), E()],
|
|
377
|
+
children: /* @__PURE__ */ x(
|
|
378
|
+
Y,
|
|
148
379
|
{
|
|
149
|
-
className:
|
|
150
|
-
enterClassName:
|
|
151
|
-
exitClassName:
|
|
380
|
+
className: h["tooltip--animation"],
|
|
381
|
+
enterClassName: h["tooltip--anim-open"],
|
|
382
|
+
exitClassName: h["tooltip--anim-close"],
|
|
152
383
|
enterAnimationName: "tooltip--open-animation",
|
|
153
384
|
exitAnimationName: "tooltip--close-animation",
|
|
154
|
-
children: /* @__PURE__ */
|
|
155
|
-
|
|
156
|
-
/* @__PURE__ */
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
385
|
+
children: /* @__PURE__ */ x("div", { className: V, onPointerEnter: d, onPointerLeave: y, children: /* @__PURE__ */ x(ct, { onClickAway: P, children: /* @__PURE__ */ $("div", { className: h.tooltip__container, children: [
|
|
386
|
+
s && /* @__PURE__ */ x("div", { className: h.tooltip__title, children: s }),
|
|
387
|
+
/* @__PURE__ */ x("div", { className: h.tooltip__content, children: f }),
|
|
388
|
+
c && /* @__PURE__ */ $("div", { className: h.tooltip__footer, children: [
|
|
389
|
+
c.type === "button" && c.onClick && /* @__PURE__ */ x("button", { onClick: c.onClick, className: h["tooltip__footer-button"], children: c.label }),
|
|
390
|
+
c.type === "link" && c.href && /* @__PURE__ */ x(
|
|
160
391
|
"a",
|
|
161
392
|
{
|
|
162
|
-
href:
|
|
163
|
-
className:
|
|
393
|
+
href: c.href,
|
|
394
|
+
className: h["tooltip__footer-link"],
|
|
164
395
|
target: "_blank",
|
|
165
396
|
rel: "noopener noreferrer",
|
|
166
|
-
children:
|
|
397
|
+
children: c.label
|
|
167
398
|
}
|
|
168
399
|
)
|
|
169
400
|
] })
|
|
@@ -175,5 +406,5 @@ const B = "_tooltip_f9rcp_79", G = "_tooltip__container_f9rcp_125", J = "_toolti
|
|
|
175
406
|
] });
|
|
176
407
|
};
|
|
177
408
|
export {
|
|
178
|
-
|
|
409
|
+
$t as Tooltip
|
|
179
410
|
};
|
|
@@ -20,7 +20,7 @@ declare const meta: {
|
|
|
20
20
|
open?: boolean | undefined;
|
|
21
21
|
disableHoverListener?: boolean | undefined;
|
|
22
22
|
onClose?: (() => void) | undefined;
|
|
23
|
-
position?: import('@floating-ui/
|
|
23
|
+
position?: import('@floating-ui/react-dom').Placement | undefined;
|
|
24
24
|
arialRole?: import('react').AriaRole | undefined;
|
|
25
25
|
className?: string | undefined;
|
|
26
26
|
style?: import('react').CSSProperties | undefined;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pismo/marola",
|
|
3
3
|
"description": "CDX tribe component library",
|
|
4
|
-
"version": "2.1.
|
|
4
|
+
"version": "2.1.19",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/main.js",
|
|
7
7
|
"types": "dist/main.d.ts",
|
|
@@ -96,6 +96,7 @@
|
|
|
96
96
|
},
|
|
97
97
|
"dependencies": {
|
|
98
98
|
"@base-ui-components/react": "^1.0.0-alpha.6",
|
|
99
|
+
"@floating-ui/dom": "^1.7.2",
|
|
99
100
|
"@mui/base": "^5.0.0-beta.40",
|
|
100
101
|
"@mui/material": "^5.15.15"
|
|
101
102
|
},
|