@versini/ui-bubble 3.1.7 → 3.1.8
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.
- package/dist/index.js +117 -109
- package/package.json +5 -5
package/dist/index.js
CHANGED
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as s, jsxs as p, Fragment as U } from "react/jsx-runtime";
|
|
2
2
|
import i from "clsx";
|
|
3
|
-
import
|
|
3
|
+
import C, { useState as V, useEffect as O } from "react";
|
|
4
4
|
/*!
|
|
5
|
-
@versini/ui-bubble v3.1.
|
|
5
|
+
@versini/ui-bubble v3.1.8
|
|
6
6
|
© 2025 gizmette.com
|
|
7
7
|
*/
|
|
8
8
|
try {
|
|
9
9
|
window.__VERSINI_UI_BUBBLE__ || (window.__VERSINI_UI_BUBBLE__ = {
|
|
10
|
-
version: "3.1.
|
|
11
|
-
buildTime: "01/
|
|
10
|
+
version: "3.1.8",
|
|
11
|
+
buildTime: "01/16/2025 07:57 PM EST",
|
|
12
12
|
homepage: "https://github.com/aversini/ui-components",
|
|
13
13
|
license: "MIT"
|
|
14
14
|
});
|
|
15
15
|
} catch {
|
|
16
16
|
}
|
|
17
|
-
const j = "av-bubble",
|
|
17
|
+
const j = "av-bubble", E = "av-button", y = "icon", L = "button", z = "link", P = ({
|
|
18
18
|
type: e,
|
|
19
19
|
size: r,
|
|
20
20
|
labelRight: t,
|
|
21
21
|
labelLeft: a,
|
|
22
22
|
align: l
|
|
23
23
|
}) => {
|
|
24
|
-
const o = "max-h-8 py-0 px-2", d = "max-h-9 h-8 px-3",
|
|
24
|
+
const o = "max-h-8 py-0 px-2", d = "max-h-9 h-8 px-3", c = "max-h-12 py-2 px-4";
|
|
25
25
|
switch (e) {
|
|
26
|
-
case
|
|
27
|
-
case
|
|
26
|
+
case L:
|
|
27
|
+
case z:
|
|
28
28
|
return i({
|
|
29
29
|
[o]: r === "small",
|
|
30
30
|
[d]: r === "medium",
|
|
31
|
-
[
|
|
31
|
+
[c]: r === "large"
|
|
32
32
|
});
|
|
33
33
|
case y:
|
|
34
34
|
return i("inline-flex items-center", {
|
|
@@ -51,10 +51,10 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
51
51
|
}) => {
|
|
52
52
|
const l = "text-sm font-medium", o = "text-base font-medium", d = "text-lg font-medium";
|
|
53
53
|
switch (e) {
|
|
54
|
-
case
|
|
55
|
-
case
|
|
54
|
+
case L:
|
|
55
|
+
case z:
|
|
56
56
|
return i({
|
|
57
|
-
"text-center": e ===
|
|
57
|
+
"text-center": e === z,
|
|
58
58
|
[l]: r === "small",
|
|
59
59
|
[o]: r === "medium",
|
|
60
60
|
[d]: r === "large"
|
|
@@ -66,7 +66,7 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
66
66
|
[d]: r === "large" && (t || a)
|
|
67
67
|
});
|
|
68
68
|
}
|
|
69
|
-
},
|
|
69
|
+
}, A = ({
|
|
70
70
|
mode: e,
|
|
71
71
|
noBackground: r,
|
|
72
72
|
noTruncate: t,
|
|
@@ -102,7 +102,7 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
102
102
|
return i("not-prose text-copy-lighter", {
|
|
103
103
|
truncate: !t
|
|
104
104
|
});
|
|
105
|
-
},
|
|
105
|
+
}, G = ({
|
|
106
106
|
mode: e,
|
|
107
107
|
noBackground: r,
|
|
108
108
|
variant: t
|
|
@@ -132,13 +132,13 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
132
132
|
if (t === "selected")
|
|
133
133
|
return "bg-action-selected-dark";
|
|
134
134
|
}
|
|
135
|
-
},
|
|
135
|
+
}, q = ({
|
|
136
136
|
radius: e
|
|
137
137
|
}) => i({
|
|
138
138
|
"rounded-full": e === "large",
|
|
139
139
|
"rounded-md": e === "medium",
|
|
140
140
|
"rounded-sm": e === "small"
|
|
141
|
-
}),
|
|
141
|
+
}), Y = ({
|
|
142
142
|
mode: e,
|
|
143
143
|
disabled: r,
|
|
144
144
|
variant: t
|
|
@@ -168,7 +168,7 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
168
168
|
});
|
|
169
169
|
if (t === "selected")
|
|
170
170
|
return "hover:text-copy-light-hover hover:bg-action-selected-dark-hover";
|
|
171
|
-
},
|
|
171
|
+
}, $ = ({
|
|
172
172
|
mode: e,
|
|
173
173
|
disabled: r,
|
|
174
174
|
variant: t
|
|
@@ -198,7 +198,7 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
198
198
|
});
|
|
199
199
|
if (t === "selected")
|
|
200
200
|
return "active:text-copy-lighter-active active:bg-action-selected-dark-active";
|
|
201
|
-
},
|
|
201
|
+
}, D = ({
|
|
202
202
|
mode: e,
|
|
203
203
|
noBorder: r,
|
|
204
204
|
variant: t
|
|
@@ -228,14 +228,26 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
228
228
|
});
|
|
229
229
|
if (t === "selected")
|
|
230
230
|
return "border border-border-selected-dark";
|
|
231
|
-
},
|
|
231
|
+
}, F = ({
|
|
232
232
|
focusMode: e
|
|
233
233
|
}) => i("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
|
|
234
234
|
"focus:outline-focus-dark": e === "dark",
|
|
235
235
|
"focus:outline-focus-light": e === "light",
|
|
236
236
|
"focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
|
|
237
237
|
"focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
|
|
238
|
-
}),
|
|
238
|
+
}), H = ({
|
|
239
|
+
mode: e,
|
|
240
|
+
raw: r,
|
|
241
|
+
iconClassName: t
|
|
242
|
+
}) => r ? "" : i(
|
|
243
|
+
{
|
|
244
|
+
"text-copy-accent-dark": e === "light" || e === "alt-system",
|
|
245
|
+
"text-copy-light": e === "dark" || e === "system",
|
|
246
|
+
"dark:text-copy-light": e === "alt-system",
|
|
247
|
+
"dark:text-copy-accent-dark": e === "system"
|
|
248
|
+
},
|
|
249
|
+
t
|
|
250
|
+
), M = ({
|
|
239
251
|
type: e,
|
|
240
252
|
className: r,
|
|
241
253
|
raw: t,
|
|
@@ -243,7 +255,7 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
243
255
|
focusMode: l,
|
|
244
256
|
disabled: o,
|
|
245
257
|
fullWidth: d,
|
|
246
|
-
size:
|
|
258
|
+
size: c,
|
|
247
259
|
noBorder: u,
|
|
248
260
|
labelRight: g,
|
|
249
261
|
labelLeft: f,
|
|
@@ -252,51 +264,51 @@ const j = "av-bubble", C = "av-button", y = "icon", E = "button", I = "link", A
|
|
|
252
264
|
noTruncate: b,
|
|
253
265
|
align: m,
|
|
254
266
|
radius: v
|
|
255
|
-
}) => (n || (n = "primary"), t ? i(
|
|
256
|
-
|
|
257
|
-
|
|
267
|
+
}) => (n || (n = "primary"), t ? i(E, r) : i(
|
|
268
|
+
E,
|
|
269
|
+
A({
|
|
258
270
|
mode: a,
|
|
259
271
|
variant: n,
|
|
260
272
|
noBackground: h,
|
|
261
273
|
noTruncate: b
|
|
262
274
|
}),
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
275
|
+
G({ mode: a, noBackground: h, variant: n }),
|
|
276
|
+
q({ radius: v }),
|
|
277
|
+
P({
|
|
266
278
|
type: e,
|
|
267
|
-
size:
|
|
279
|
+
size: c,
|
|
268
280
|
labelRight: g,
|
|
269
281
|
labelLeft: f,
|
|
270
282
|
align: m
|
|
271
283
|
}),
|
|
272
|
-
W({ type: e, size:
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
284
|
+
W({ type: e, size: c, labelRight: g, labelLeft: f }),
|
|
285
|
+
D({ mode: a, variant: n, noBorder: u }),
|
|
286
|
+
F({ focusMode: l }),
|
|
287
|
+
Y({ mode: a, variant: n, disabled: o }),
|
|
288
|
+
$({ mode: a, variant: n, disabled: o }),
|
|
277
289
|
{
|
|
278
290
|
"w-full": d,
|
|
279
291
|
"disabled:cursor-not-allowed disabled:opacity-50": o
|
|
280
292
|
},
|
|
281
293
|
r
|
|
282
|
-
)),
|
|
294
|
+
)), J = (e, r, t) => {
|
|
283
295
|
var a;
|
|
284
296
|
!r && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((a = e == null ? void 0 : e.currentTarget) == null ? void 0 : a.focus) == "function" && e.currentTarget.focus(), typeof t == "function" && t(e);
|
|
285
|
-
}, T =
|
|
297
|
+
}, T = C.forwardRef((e, r) => {
|
|
286
298
|
const { onClick: t, noInternalClick: a = !1, ...l } = e;
|
|
287
|
-
return /* @__PURE__ */
|
|
299
|
+
return /* @__PURE__ */ s(
|
|
288
300
|
"button",
|
|
289
301
|
{
|
|
290
302
|
ref: r,
|
|
291
303
|
onClick: (o) => {
|
|
292
|
-
|
|
304
|
+
J(o, a, t);
|
|
293
305
|
},
|
|
294
306
|
...l
|
|
295
307
|
}
|
|
296
308
|
);
|
|
297
309
|
});
|
|
298
310
|
T.displayName = "BaseButton";
|
|
299
|
-
const
|
|
311
|
+
const S = C.forwardRef(
|
|
300
312
|
({
|
|
301
313
|
children: e,
|
|
302
314
|
disabled: r = !1,
|
|
@@ -305,7 +317,7 @@ const M = z.forwardRef(
|
|
|
305
317
|
fullWidth: l = !1,
|
|
306
318
|
className: o,
|
|
307
319
|
type: d = "button",
|
|
308
|
-
raw:
|
|
320
|
+
raw: c = !1,
|
|
309
321
|
noBorder: u = !1,
|
|
310
322
|
"aria-label": g,
|
|
311
323
|
label: f,
|
|
@@ -316,15 +328,16 @@ const M = z.forwardRef(
|
|
|
316
328
|
align: v = "center",
|
|
317
329
|
radius: k = "large",
|
|
318
330
|
variant: x = "primary",
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
331
|
+
iconClassName: w,
|
|
332
|
+
...B
|
|
333
|
+
}, _) => {
|
|
334
|
+
const N = M({
|
|
322
335
|
type: y,
|
|
323
336
|
mode: t,
|
|
324
337
|
focusMode: a,
|
|
325
338
|
fullWidth: l,
|
|
326
339
|
disabled: r,
|
|
327
|
-
raw:
|
|
340
|
+
raw: c,
|
|
328
341
|
className: o,
|
|
329
342
|
noBorder: u,
|
|
330
343
|
size: h,
|
|
@@ -334,45 +347,40 @@ const M = z.forwardRef(
|
|
|
334
347
|
align: v,
|
|
335
348
|
radius: k,
|
|
336
349
|
variant: x
|
|
337
|
-
}),
|
|
338
|
-
"text-copy-accent-dark": (t === "light" || t === "alt-system") && !s,
|
|
339
|
-
"text-copy-light": (t === "dark" || t === "system") && !s,
|
|
340
|
-
"dark:text-copy-light": t === "alt-system" && !s,
|
|
341
|
-
"dark:text-copy-accent-dark": t === "system" && !s
|
|
342
|
-
});
|
|
350
|
+
}), I = H({ mode: t, raw: c, iconClassName: w });
|
|
343
351
|
return /* @__PURE__ */ p(
|
|
344
352
|
T,
|
|
345
353
|
{
|
|
346
|
-
ref:
|
|
347
|
-
className:
|
|
354
|
+
ref: _,
|
|
355
|
+
className: N,
|
|
348
356
|
disabled: r,
|
|
349
357
|
type: d,
|
|
350
358
|
"aria-label": g || f,
|
|
351
|
-
...
|
|
359
|
+
...B,
|
|
352
360
|
children: [
|
|
353
|
-
b && /* @__PURE__ */
|
|
354
|
-
/* @__PURE__ */
|
|
355
|
-
n && /* @__PURE__ */
|
|
361
|
+
b && /* @__PURE__ */ s("span", { className: "pr-2", children: b }),
|
|
362
|
+
/* @__PURE__ */ s("div", { className: I, children: e }),
|
|
363
|
+
n && /* @__PURE__ */ s("span", { className: "pl-2", children: n })
|
|
356
364
|
]
|
|
357
365
|
}
|
|
358
366
|
);
|
|
359
367
|
}
|
|
360
368
|
);
|
|
361
|
-
|
|
369
|
+
S.displayName = "ButtonIcon";
|
|
362
370
|
/*!
|
|
363
|
-
@versini/ui-button v4.0
|
|
371
|
+
@versini/ui-button v4.1.0
|
|
364
372
|
© 2025 gizmette.com
|
|
365
373
|
*/
|
|
366
374
|
try {
|
|
367
375
|
window.__VERSINI_UI_BUTTON__ || (window.__VERSINI_UI_BUTTON__ = {
|
|
368
|
-
version: "4.0
|
|
369
|
-
buildTime: "01/
|
|
376
|
+
version: "4.1.0",
|
|
377
|
+
buildTime: "01/16/2025 07:57 PM EST",
|
|
370
378
|
homepage: "https://github.com/aversini/ui-components",
|
|
371
379
|
license: "MIT"
|
|
372
380
|
});
|
|
373
381
|
} catch {
|
|
374
382
|
}
|
|
375
|
-
const
|
|
383
|
+
const K = C.forwardRef(
|
|
376
384
|
({
|
|
377
385
|
children: e,
|
|
378
386
|
disabled: r = !1,
|
|
@@ -381,7 +389,7 @@ const Q = z.forwardRef(
|
|
|
381
389
|
fullWidth: l = !1,
|
|
382
390
|
className: o,
|
|
383
391
|
type: d = "button",
|
|
384
|
-
raw:
|
|
392
|
+
raw: c = !1,
|
|
385
393
|
noBorder: u = !1,
|
|
386
394
|
"aria-label": g,
|
|
387
395
|
label: f,
|
|
@@ -394,13 +402,13 @@ const Q = z.forwardRef(
|
|
|
394
402
|
radius: x = "large",
|
|
395
403
|
...w
|
|
396
404
|
}, B) => {
|
|
397
|
-
const _ =
|
|
405
|
+
const _ = M({
|
|
398
406
|
type: y,
|
|
399
407
|
mode: t,
|
|
400
408
|
focusMode: a,
|
|
401
409
|
fullWidth: l,
|
|
402
410
|
disabled: r,
|
|
403
|
-
raw:
|
|
411
|
+
raw: c,
|
|
404
412
|
className: o,
|
|
405
413
|
noBorder: u,
|
|
406
414
|
size: h,
|
|
@@ -410,11 +418,11 @@ const Q = z.forwardRef(
|
|
|
410
418
|
align: v,
|
|
411
419
|
radius: x
|
|
412
420
|
}), N = i({
|
|
413
|
-
"text-copy-accent-dark": t === "light" && !
|
|
414
|
-
"text-copy-light": t === "dark" && !
|
|
415
|
-
"text-copy-accent-dark dark:text-copy-light": t === "alt-system" && !
|
|
416
|
-
"text-copy-light dark:text-copy-accent-dark": t === "system" && !
|
|
417
|
-
}),
|
|
421
|
+
"text-copy-accent-dark": t === "light" && !c,
|
|
422
|
+
"text-copy-light": t === "dark" && !c,
|
|
423
|
+
"text-copy-accent-dark dark:text-copy-light": t === "alt-system" && !c,
|
|
424
|
+
"text-copy-light dark:text-copy-accent-dark": t === "system" && !c
|
|
425
|
+
}), I = k ? i(
|
|
418
426
|
"relative",
|
|
419
427
|
"focus-within:static",
|
|
420
428
|
"focus-within:after:border-transparent",
|
|
@@ -431,7 +439,7 @@ const Q = z.forwardRef(
|
|
|
431
439
|
"after:border-table-light dark:after:border-table-dark": t === "alt-system"
|
|
432
440
|
}
|
|
433
441
|
) : "";
|
|
434
|
-
return /* @__PURE__ */
|
|
442
|
+
return /* @__PURE__ */ s("div", { className: I, children: /* @__PURE__ */ p(
|
|
435
443
|
T,
|
|
436
444
|
{
|
|
437
445
|
ref: B,
|
|
@@ -441,16 +449,16 @@ const Q = z.forwardRef(
|
|
|
441
449
|
"aria-label": g || f,
|
|
442
450
|
...w,
|
|
443
451
|
children: [
|
|
444
|
-
b && /* @__PURE__ */
|
|
445
|
-
/* @__PURE__ */
|
|
446
|
-
n && /* @__PURE__ */
|
|
452
|
+
b && /* @__PURE__ */ s("span", { className: "pr-2", children: b }),
|
|
453
|
+
/* @__PURE__ */ s("div", { className: N, children: e }),
|
|
454
|
+
n && /* @__PURE__ */ s("span", { className: "pl-2", children: n })
|
|
447
455
|
]
|
|
448
456
|
}
|
|
449
457
|
) });
|
|
450
458
|
}
|
|
451
459
|
);
|
|
452
|
-
|
|
453
|
-
const
|
|
460
|
+
K.displayName = "ButtonSort";
|
|
461
|
+
const R = ({
|
|
454
462
|
children: e,
|
|
455
463
|
fill: r,
|
|
456
464
|
viewBox: t,
|
|
@@ -458,12 +466,12 @@ const S = ({
|
|
|
458
466
|
defaultViewBox: l,
|
|
459
467
|
size: o,
|
|
460
468
|
title: d,
|
|
461
|
-
semantic:
|
|
469
|
+
semantic: c = !1,
|
|
462
470
|
...u
|
|
463
471
|
}) => {
|
|
464
472
|
const g = i(o, a);
|
|
465
473
|
return /* @__PURE__ */ p(U, { children: [
|
|
466
|
-
/* @__PURE__ */
|
|
474
|
+
/* @__PURE__ */ s(
|
|
467
475
|
"svg",
|
|
468
476
|
{
|
|
469
477
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -471,36 +479,36 @@ const S = ({
|
|
|
471
479
|
viewBox: t || l,
|
|
472
480
|
fill: r || "currentColor",
|
|
473
481
|
role: "img",
|
|
474
|
-
"aria-hidden": !
|
|
482
|
+
"aria-hidden": !c,
|
|
475
483
|
focusable: !1,
|
|
476
484
|
...u,
|
|
477
485
|
children: e
|
|
478
486
|
}
|
|
479
487
|
),
|
|
480
|
-
d &&
|
|
488
|
+
d && c && /* @__PURE__ */ s("span", { className: "sr-only", children: d })
|
|
481
489
|
] });
|
|
482
490
|
};
|
|
483
491
|
/*!
|
|
484
|
-
@versini/ui-svgicon v4.0.
|
|
492
|
+
@versini/ui-svgicon v4.0.4
|
|
485
493
|
© 2025 gizmette.com
|
|
486
494
|
*/
|
|
487
495
|
try {
|
|
488
496
|
window.__VERSINI_UI_SVGICON__ || (window.__VERSINI_UI_SVGICON__ = {
|
|
489
|
-
version: "4.0.
|
|
490
|
-
buildTime: "01/
|
|
497
|
+
version: "4.0.4",
|
|
498
|
+
buildTime: "01/16/2025 07:57 PM EST",
|
|
491
499
|
homepage: "https://github.com/aversini/ui-components",
|
|
492
500
|
license: "MIT"
|
|
493
501
|
});
|
|
494
502
|
} catch {
|
|
495
503
|
}
|
|
496
|
-
const
|
|
504
|
+
const Q = ({
|
|
497
505
|
className: e,
|
|
498
506
|
viewBox: r,
|
|
499
507
|
title: t,
|
|
500
508
|
monotone: a,
|
|
501
509
|
...l
|
|
502
510
|
}) => /* @__PURE__ */ p(
|
|
503
|
-
|
|
511
|
+
R,
|
|
504
512
|
{
|
|
505
513
|
defaultViewBox: "0 0 448 512",
|
|
506
514
|
size: "size-5",
|
|
@@ -509,7 +517,7 @@ const X = ({
|
|
|
509
517
|
title: t || "Copied",
|
|
510
518
|
...l,
|
|
511
519
|
children: [
|
|
512
|
-
/* @__PURE__ */
|
|
520
|
+
/* @__PURE__ */ s(
|
|
513
521
|
"path",
|
|
514
522
|
{
|
|
515
523
|
className: "fa-secondary",
|
|
@@ -517,7 +525,7 @@ const X = ({
|
|
|
517
525
|
d: "M0 96L0 416c0 35.3 28.7 64 64 64l320 0c35.3 0 64-28.7 64-64l0-320c0-35.3-28.7-64-64-64L64 32C28.7 32 0 60.7 0 96zM104 256c0-6.1 2.3-12.3 7-17c9.4-9.4 24.6-9.4 33.9 0l47 47c37-37 74-74 111-111c4.7-4.7 10.8-7 17-7s12.3 2.3 17 7c2.3 2.3 4.1 5 5.3 7.9c.6 1.5 1 2.9 1.3 4.4c.2 1.1 .3 2.2 .3 2.2c.1 1.2 .1 1.2 .1 2.5c-.1 1.5-.1 1.9-.1 2.3c-.1 .7-.2 1.5-.3 2.2c-.3 1.5-.7 3-1.3 4.4c-1.2 2.9-2.9 5.6-5.3 7.9c-42.7 42.7-85.3 85.3-128 128c-4.7 4.7-10.8 7-17 7s-12.3-2.3-17-7c-21.3-21.3-42.7-42.7-64-64c-4.7-4.7-7-10.8-7-17z"
|
|
518
526
|
}
|
|
519
527
|
),
|
|
520
|
-
/* @__PURE__ */
|
|
528
|
+
/* @__PURE__ */ s(
|
|
521
529
|
"path",
|
|
522
530
|
{
|
|
523
531
|
className: "fa-primary",
|
|
@@ -526,14 +534,14 @@ const X = ({
|
|
|
526
534
|
)
|
|
527
535
|
]
|
|
528
536
|
}
|
|
529
|
-
),
|
|
537
|
+
), X = ({
|
|
530
538
|
className: e,
|
|
531
539
|
viewBox: r,
|
|
532
540
|
title: t,
|
|
533
541
|
monotone: a,
|
|
534
542
|
...l
|
|
535
|
-
}) => /* @__PURE__ */
|
|
536
|
-
|
|
543
|
+
}) => /* @__PURE__ */ s(
|
|
544
|
+
R,
|
|
537
545
|
{
|
|
538
546
|
defaultViewBox: "0 0 512 512",
|
|
539
547
|
size: "size-5",
|
|
@@ -541,17 +549,17 @@ const X = ({
|
|
|
541
549
|
className: e,
|
|
542
550
|
title: t || "Copy",
|
|
543
551
|
...l,
|
|
544
|
-
children: /* @__PURE__ */
|
|
552
|
+
children: /* @__PURE__ */ s("path", { d: "M64 464l224 0c8.8 0 16-7.2 16-16l0-64 48 0 0 64c0 35.3-28.7 64-64 64L64 512c-35.3 0-64-28.7-64-64L0 224c0-35.3 28.7-64 64-64l64 0 0 48-64 0c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16zM224 304l224 0c8.8 0 16-7.2 16-16l0-224c0-8.8-7.2-16-16-16L224 48c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16zm-64-16l0-224c0-35.3 28.7-64 64-64L448 0c35.3 0 64 28.7 64 64l0 224c0 35.3-28.7 64-64 64l-224 0c-35.3 0-64-28.7-64-64z" })
|
|
545
553
|
}
|
|
546
554
|
);
|
|
547
555
|
/*!
|
|
548
|
-
@versini/ui-icons v4.4.
|
|
556
|
+
@versini/ui-icons v4.4.3
|
|
549
557
|
© 2025 gizmette.com
|
|
550
558
|
*/
|
|
551
559
|
try {
|
|
552
560
|
window.__VERSINI_UI_ICONS__ || (window.__VERSINI_UI_ICONS__ = {
|
|
553
|
-
version: "4.4.
|
|
554
|
-
buildTime: "01/
|
|
561
|
+
version: "4.4.3",
|
|
562
|
+
buildTime: "01/16/2025 07:57 PM EST",
|
|
555
563
|
homepage: "https://github.com/aversini/ui-components",
|
|
556
564
|
license: "MIT"
|
|
557
565
|
});
|
|
@@ -563,18 +571,18 @@ const Z = ({
|
|
|
563
571
|
}) => i("p-4", {
|
|
564
572
|
"max-w-xs sm:max-w-md md:max-w-2xl": !r,
|
|
565
573
|
"lg:max-w-3xl": e === "left" && !r
|
|
566
|
-
}),
|
|
574
|
+
}), ee = ({ kind: e }) => i({
|
|
567
575
|
"bg-surface-lighter dark:bg-surface-dark": e === "left",
|
|
568
576
|
"bg-surface-accent": e === "right"
|
|
569
|
-
}),
|
|
577
|
+
}), te = ({ kind: e }) => i(
|
|
570
578
|
"prose prose-dark dark:prose-lighter prose-p:my-3 prose-blockquote:my-3 prose-ol:my-3 prose-ul:my-3 prose-ul:prose-li:marker:text-black",
|
|
571
579
|
{
|
|
572
580
|
"text-copy-lighter": e === "right"
|
|
573
581
|
}
|
|
574
|
-
),
|
|
582
|
+
), re = ({ kind: e }) => i("rounded-b-xl", {
|
|
575
583
|
"rounded-tr-xl": e === "left",
|
|
576
584
|
"rounded-tl-xl": e === "right"
|
|
577
|
-
}),
|
|
585
|
+
}), ae = ({
|
|
578
586
|
kind: e,
|
|
579
587
|
className: r,
|
|
580
588
|
noMaxWidth: t
|
|
@@ -589,9 +597,9 @@ const Z = ({
|
|
|
589
597
|
), l = i(
|
|
590
598
|
"flex flex-col empty:hidden",
|
|
591
599
|
Z({ kind: e, noMaxWidth: t }),
|
|
600
|
+
te({ kind: e }),
|
|
592
601
|
ee({ kind: e }),
|
|
593
|
-
|
|
594
|
-
te({ kind: e })
|
|
602
|
+
re({ kind: e })
|
|
595
603
|
), o = "pr-2 pt-1 text-end text-xs text-copy-light", d = i("flex flex-col-reverse gap-2 sm:flex-row", {
|
|
596
604
|
"ml-2": e === "left",
|
|
597
605
|
"mr-2": e === "right"
|
|
@@ -602,7 +610,7 @@ const Z = ({
|
|
|
602
610
|
footer: o,
|
|
603
611
|
copyButton: d
|
|
604
612
|
};
|
|
605
|
-
},
|
|
613
|
+
}, se = ({
|
|
606
614
|
children: e,
|
|
607
615
|
kind: r = "left",
|
|
608
616
|
className: t,
|
|
@@ -610,10 +618,10 @@ const Z = ({
|
|
|
610
618
|
rawFooter: l,
|
|
611
619
|
copyToClipboard: o,
|
|
612
620
|
copyToClipboardFocusMode: d = "system",
|
|
613
|
-
copyToClipboardMode:
|
|
621
|
+
copyToClipboardMode: c = "system",
|
|
614
622
|
noMaxWidth: u = !1
|
|
615
623
|
}) => {
|
|
616
|
-
const [g, f] = V(!1), h =
|
|
624
|
+
const [g, f] = V(!1), h = ae({ kind: r, className: t, noMaxWidth: u }), n = !!o && (typeof o == "function" || typeof o == "string" || typeof e == "string"), b = () => {
|
|
617
625
|
f(!0), typeof o == "function" ? o(e) : typeof o == "string" ? navigator.clipboard.writeText(o) : typeof e == "string" && navigator.clipboard.writeText(e);
|
|
618
626
|
};
|
|
619
627
|
return O(() => {
|
|
@@ -625,31 +633,31 @@ const Z = ({
|
|
|
625
633
|
};
|
|
626
634
|
}, [g]), /* @__PURE__ */ p("div", { className: h.wrapper, children: [
|
|
627
635
|
/* @__PURE__ */ p("div", { children: [
|
|
628
|
-
/* @__PURE__ */
|
|
629
|
-
a && Object.keys(a).map((m) => a[m] ? /* @__PURE__ */
|
|
636
|
+
/* @__PURE__ */ s("div", { className: h.main, children: e }),
|
|
637
|
+
a && Object.keys(a).map((m) => a[m] ? /* @__PURE__ */ s("div", { className: "prose-p:m-0", children: /* @__PURE__ */ p("p", { className: h.footer, children: [
|
|
630
638
|
m,
|
|
631
639
|
": ",
|
|
632
640
|
a[m]
|
|
633
641
|
] }) }, `-${m}`) : null),
|
|
634
642
|
l && l
|
|
635
643
|
] }),
|
|
636
|
-
n && /* @__PURE__ */
|
|
637
|
-
|
|
644
|
+
n && /* @__PURE__ */ s("div", { className: h.copyButton, children: /* @__PURE__ */ s(
|
|
645
|
+
S,
|
|
638
646
|
{
|
|
639
647
|
noBorder: !0,
|
|
640
648
|
noBackground: !0,
|
|
641
649
|
size: "small",
|
|
642
|
-
mode:
|
|
650
|
+
mode: c,
|
|
643
651
|
focusMode: d,
|
|
644
652
|
label: g ? "Copied to clipboard" : "Copy to clipboard",
|
|
645
653
|
onClick: b,
|
|
646
654
|
disabled: g,
|
|
647
|
-
children: g ? /* @__PURE__ */
|
|
655
|
+
children: g ? /* @__PURE__ */ s(Q, { size: "size-3" }) : /* @__PURE__ */ s(X, { size: "size-3" })
|
|
648
656
|
}
|
|
649
657
|
) })
|
|
650
658
|
] });
|
|
651
659
|
};
|
|
652
660
|
export {
|
|
653
661
|
j as BUBBLE_CLASSNAME,
|
|
654
|
-
|
|
662
|
+
se as Bubble
|
|
655
663
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@versini/ui-bubble",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.8",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "Arno Versini",
|
|
6
6
|
"publishConfig": {
|
|
@@ -38,17 +38,17 @@
|
|
|
38
38
|
"react-dom": "^18.3.1 || ^19.0.0"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@versini/ui-types": "4.
|
|
41
|
+
"@versini/ui-types": "4.2.0"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@tailwindcss/typography": "0.5.16",
|
|
45
|
-
"@versini/ui-button": "4.0
|
|
46
|
-
"@versini/ui-icons": "4.4.
|
|
45
|
+
"@versini/ui-button": "4.1.0",
|
|
46
|
+
"@versini/ui-icons": "4.4.3",
|
|
47
47
|
"clsx": "2.1.1",
|
|
48
48
|
"tailwindcss": "3.4.17"
|
|
49
49
|
},
|
|
50
50
|
"sideEffects": [
|
|
51
51
|
"**/*.css"
|
|
52
52
|
],
|
|
53
|
-
"gitHead": "
|
|
53
|
+
"gitHead": "2be4fd5fe7dd74804533efdedcc6cfa4023a739a"
|
|
54
54
|
}
|