@vkzstudio/muza-ui 1.4.0 → 1.5.0

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 (51) hide show
  1. package/dist/components/DropdownSearchMenu/DropdownSearchMenu.d.ts +73 -0
  2. package/dist/components/DropdownSearchMenu/DropdownSearchMenu.d.ts.map +1 -0
  3. package/dist/components/DropdownSearchMenu/DropdownSearchMenu.js +257 -0
  4. package/dist/components/DropdownSearchMenu/DropdownSearchMenu.stories.d.ts +28 -0
  5. package/dist/components/DropdownSearchMenu/DropdownSearchMenu.stories.d.ts.map +1 -0
  6. package/dist/components/DropdownSearchMenu/index.d.ts +2 -0
  7. package/dist/components/DropdownSearchMenu/index.d.ts.map +1 -0
  8. package/dist/components/PasswordInput/PasswordInput.d.ts +12 -0
  9. package/dist/components/PasswordInput/PasswordInput.d.ts.map +1 -1
  10. package/dist/components/PasswordInput/PasswordInput.js +25 -17
  11. package/dist/components/PasswordInput/PasswordInput.stories.d.ts.map +1 -1
  12. package/dist/components/PhoneInput/CountrySelector.d.ts +34 -0
  13. package/dist/components/PhoneInput/CountrySelector.d.ts.map +1 -0
  14. package/dist/components/PhoneInput/CountrySelector.js +109 -0
  15. package/dist/components/PhoneInput/PhoneInput.d.ts +86 -0
  16. package/dist/components/PhoneInput/PhoneInput.d.ts.map +1 -0
  17. package/dist/components/PhoneInput/PhoneInput.js +144 -0
  18. package/dist/components/PhoneInput/PhoneInput.stories.d.ts +29 -0
  19. package/dist/components/PhoneInput/PhoneInput.stories.d.ts.map +1 -0
  20. package/dist/components/PhoneInput/index.d.ts +2 -0
  21. package/dist/components/PhoneInput/index.d.ts.map +1 -0
  22. package/dist/components/Searchbar/Searchbar.js +4 -4
  23. package/dist/components/Toast/Toast.d.ts +2 -1
  24. package/dist/components/Toast/Toast.d.ts.map +1 -1
  25. package/dist/components/Toast/Toast.js +37 -36
  26. package/dist/components/Toast/Toast.stories.d.ts +1 -0
  27. package/dist/components/Toast/Toast.stories.d.ts.map +1 -1
  28. package/dist/components/Tooltip/Tooltip.d.ts +16 -2
  29. package/dist/components/Tooltip/Tooltip.d.ts.map +1 -1
  30. package/dist/components/Tooltip/Tooltip.js +99 -22
  31. package/dist/components/Tooltip/Tooltip.stories.d.ts +1 -0
  32. package/dist/components/Tooltip/Tooltip.stories.d.ts.map +1 -1
  33. package/dist/components/index.d.ts +2 -0
  34. package/dist/components/index.d.ts.map +1 -1
  35. package/dist/index.js +329 -322
  36. package/dist/muza-ui.css +1 -1
  37. package/dist/styles/token-colors.css +34 -0
  38. package/dist/styles/token-sizes.css +88 -8
  39. package/dist/translations/index.d.ts +1 -1
  40. package/dist/translations/index.d.ts.map +1 -1
  41. package/dist/translations/locales/cs.d.ts.map +1 -1
  42. package/dist/translations/locales/cs.js +12 -0
  43. package/dist/translations/locales/en.d.ts.map +1 -1
  44. package/dist/translations/locales/en.js +12 -0
  45. package/dist/translations/locales/sk.d.ts.map +1 -1
  46. package/dist/translations/locales/sk.js +12 -0
  47. package/dist/translations/types.d.ts +30 -0
  48. package/dist/translations/types.d.ts.map +1 -1
  49. package/dist/utils/cn.d.ts.map +1 -1
  50. package/dist/utils/cn.js +2 -1
  51. package/package.json +2 -1
@@ -0,0 +1,86 @@
1
+ import { ComponentPropsWithoutRef, ReactNode } from 'react';
2
+ import { VariantProps } from 'class-variance-authority';
3
+ import { CountryData, ParsedCountry } from 'react-international-phone';
4
+ /**
5
+ * Metadata passed alongside the E.164 value to `PhoneInput`'s `onChange`.
6
+ */
7
+ export interface PhoneInputChangeMeta {
8
+ /** The formatted, human-readable value shown in the input (e.g. `"777 123 456"`). */
9
+ inputValue: string;
10
+ /** The resolved country the number currently belongs to. */
11
+ country: ParsedCountry;
12
+ }
13
+ declare const phoneWrapperVariants: (props?: ({
14
+ size?: "xs" | "sm" | "lg" | "base" | null | undefined;
15
+ error?: boolean | null | undefined;
16
+ } & import('class-variance-authority/types').ClassProp) | undefined) => string;
17
+ /**
18
+ * Props for the PhoneInput component.
19
+ *
20
+ * A segmented phone-number field: a searchable country selector (flag + dial
21
+ * code) on the left and a formatted national-number input on the right. The
22
+ * value is composed and emitted as a single E.164 string. Formatting, country
23
+ * detection, and dial-code handling are powered by
24
+ * [react-international-phone](https://react-international-phone.vercel.app/).
25
+ *
26
+ * Extends native input attributes except `size`/`type`/`prefix` (managed
27
+ * internally) and `value`/`defaultValue`/`onChange` (narrowed to the phone
28
+ * string contract below).
29
+ */
30
+ export interface PhoneInputProps extends Omit<ComponentPropsWithoutRef<'input'>, 'size' | 'type' | 'prefix' | 'value' | 'defaultValue' | 'onChange'>, VariantProps<typeof phoneWrapperVariants> {
31
+ /** Label text rendered above the input. */
32
+ label?: string;
33
+ /** Helper or error text rendered below the input. */
34
+ hint?: string;
35
+ /** Controls height and typography. @default 'base' */
36
+ size?: 'xs' | 'sm' | 'base' | 'lg';
37
+ /** Applies error border and hint styling. @default false */
38
+ error?: boolean;
39
+ /**
40
+ * Controlled phone value in E.164 format (e.g. `"+420777123456"`). Pair with
41
+ * `onChange` for controlled usage.
42
+ */
43
+ value?: string;
44
+ /** Initial phone value in E.164 format for uncontrolled usage. */
45
+ defaultValue?: string;
46
+ /**
47
+ * Fires on every change with the composed E.164 phone string and formatting
48
+ * metadata. The phone string is empty (`""`) when no number is entered.
49
+ */
50
+ onChange?: (phone: string, meta: PhoneInputChangeMeta) => void;
51
+ /** ISO2 code of the initial country selection (e.g. `"cz"`). @default 'cz' */
52
+ defaultCountry?: string;
53
+ /**
54
+ * Country dataset used for the selector and number guessing. Rarely needed —
55
+ * override to restrict or reorder the available countries.
56
+ * @default defaultCountries
57
+ */
58
+ countries?: CountryData[];
59
+ /**
60
+ * Hides the required asterisk in the label even when `required` is `true`.
61
+ * @default false
62
+ */
63
+ disableRequiredAsterisk?: boolean;
64
+ /** Custom content rendered inline next to the label. Takes precedence over `infoTooltip`. */
65
+ labelExtra?: ReactNode;
66
+ /** Tooltip content shown in an info icon next to the label. Ignored when `labelExtra` is provided. */
67
+ infoTooltip?: string;
68
+ /**
69
+ * Accessible label for the country selector trigger.
70
+ * @default translations.phoneInput.countrySelectorAriaLabel
71
+ */
72
+ countrySelectorAriaLabel?: string;
73
+ /**
74
+ * Placeholder for the country search field.
75
+ * @default translations.phoneInput.searchPlaceholder
76
+ */
77
+ searchPlaceholder?: string;
78
+ /**
79
+ * Message shown when the country search yields no matches.
80
+ * @default translations.phoneInput.noResults
81
+ */
82
+ noResultsText?: string;
83
+ }
84
+ export declare const PhoneInput: import('react').ForwardRefExoticComponent<PhoneInputProps & import('react').RefAttributes<HTMLInputElement>>;
85
+ export {};
86
+ //# sourceMappingURL=PhoneInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PhoneInput.d.ts","sourceRoot":"","sources":["../../../src/components/PhoneInput/PhoneInput.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wBAAwB,EAC7B,KAAK,SAAS,EAMf,MAAM,OAAO,CAAA;AACd,OAAO,EAAE,KAAK,YAAY,EAAO,MAAM,0BAA0B,CAAA;AACjE,OAAO,EACL,KAAK,WAAW,EAChB,KAAK,aAAa,EAGnB,MAAM,2BAA2B,CAAA;AAOlC;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC,qFAAqF;IACrF,UAAU,EAAE,MAAM,CAAA;IAClB,4DAA4D;IAC5D,OAAO,EAAE,aAAa,CAAA;CACvB;AAKD,QAAA,MAAM,oBAAoB;;;8EAyBzB,CAAA;AAcD;;;;;;;;;;;;GAYG;AACH,MAAM,WAAW,eACf,SAAQ,IAAI,CACR,wBAAwB,CAAC,OAAO,CAAC,EACjC,MAAM,GAAG,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,cAAc,GAAG,UAAU,CACnE,EACD,YAAY,CAAC,OAAO,oBAAoB,CAAC;IAC3C,2CAA2C;IAC3C,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,qDAAqD;IACrD,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,sDAAsD;IACtD,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,MAAM,GAAG,IAAI,CAAA;IAClC,4DAA4D;IAC5D,KAAK,CAAC,EAAE,OAAO,CAAA;IACf;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,kEAAkE;IAClE,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB;;;OAGG;IACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,oBAAoB,KAAK,IAAI,CAAA;IAC9D,8EAA8E;IAC9E,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB;;;;OAIG;IACH,SAAS,CAAC,EAAE,WAAW,EAAE,CAAA;IACzB;;;OAGG;IACH,uBAAuB,CAAC,EAAE,OAAO,CAAA;IACjC,6FAA6F;IAC7F,UAAU,CAAC,EAAE,SAAS,CAAA;IACtB,sGAAsG;IACtG,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB;;;OAGG;IACH,wBAAwB,CAAC,EAAE,MAAM,CAAA;IACjC;;;OAGG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB;AAED,eAAO,MAAM,UAAU,8GA6HtB,CAAA"}
@@ -0,0 +1,144 @@
1
+ import { jsx as u, jsxs as W } from "react/jsx-runtime";
2
+ import { forwardRef as Y, useId as B, useRef as G, useState as H, useEffect as J } from "react";
3
+ import { cva as K } from "class-variance-authority";
4
+ import { usePhoneInput as O, defaultCountries as Q } from "react-international-phone";
5
+ import { CountrySelector as U } from "./CountrySelector.js";
6
+ import { useMuzaTranslations as X } from "../../translations/TranslationContext.js";
7
+ import { FormField as Z } from "../FormField/FormField.js";
8
+ import { cn as v } from "../../utils/cn.js";
9
+ import { typographyVariants as _ } from "../Typography/Typography.js";
10
+ const q = K(
11
+ [
12
+ "group flex items-center",
13
+ "rounded-full border border-comp-input-stroke-def bg-comp-input-fill-def transition-colors",
14
+ "hover:border-comp-input-stroke-hover",
15
+ "focus-within:border-comp-input-icon-brand-focused",
16
+ "has-[:disabled]:cursor-not-allowed has-[:disabled]:border-comp-input-stroke-disabled has-[:disabled]:bg-comp-input-fill-disabled"
17
+ ],
18
+ {
19
+ variants: {
20
+ size: {
21
+ xs: "h-comp-input-h-xsm",
22
+ sm: "h-comp-input-h-small",
23
+ base: "h-comp-input-h-def",
24
+ lg: "h-comp-input-h-large"
25
+ },
26
+ error: {
27
+ true: "border-comp-input-stroke-error-def"
28
+ }
29
+ },
30
+ defaultVariants: {
31
+ size: "base",
32
+ error: !1
33
+ }
34
+ }
35
+ ), ee = (t) => v(
36
+ _({
37
+ size: t === "xs" || t === "sm" ? "input" : "base",
38
+ weight: "medium",
39
+ fixY: !0
40
+ }),
41
+ "h-full min-w-0 flex-1 bg-transparent px-comp-input-p-hor text-comp-input-text-primary outline-0 transition-colors",
42
+ "placeholder:font-regular placeholder:text-comp-input-text-placeholder",
43
+ "disabled:cursor-not-allowed"
44
+ ), te = Y(
45
+ ({
46
+ className: t,
47
+ label: p,
48
+ hint: c,
49
+ size: d,
50
+ error: o,
51
+ value: m,
52
+ defaultValue: C,
53
+ onChange: i,
54
+ defaultCountry: V = "cz",
55
+ countries: h = Q,
56
+ disabled: f,
57
+ required: l,
58
+ disableRequiredAsterisk: w,
59
+ labelExtra: P,
60
+ infoTooltip: R,
61
+ id: k,
62
+ countrySelectorAriaLabel: N,
63
+ searchPlaceholder: z,
64
+ noResultsText: F,
65
+ ...b
66
+ }, e) => {
67
+ const s = X(), S = B(), r = k ?? S, y = c ? `${r}-hint` : void 0, x = p ? `${r}-label` : void 0, n = G(null), I = m !== void 0, [j, A] = H(C ?? ""), L = I ? m : j, { inputValue: M, country: T, setCountry: $, handlePhoneValueChange: D } = O({
68
+ defaultCountry: V,
69
+ value: L,
70
+ countries: h,
71
+ inputRef: n,
72
+ // Keep the dial code out of the number field — it lives in the country
73
+ // selector segment. `phone` in onChange is still full E.164.
74
+ disableDialCodeAndPrefix: !0,
75
+ onChange: ({
76
+ phone: a,
77
+ inputValue: g,
78
+ country: E
79
+ }) => {
80
+ I || A(a), i == null || i(g ? a : "", {
81
+ inputValue: g,
82
+ country: E
83
+ });
84
+ }
85
+ });
86
+ return J(() => {
87
+ e && (typeof e == "function" ? e(n.current) : e.current = n.current);
88
+ }, [e]), /* @__PURE__ */ u(
89
+ Z,
90
+ {
91
+ label: p,
92
+ hint: c,
93
+ error: o,
94
+ required: l,
95
+ disableRequiredAsterisk: w,
96
+ htmlFor: r,
97
+ labelId: x,
98
+ hintId: y,
99
+ labelExtra: P,
100
+ infoTooltip: R,
101
+ children: /* @__PURE__ */ W("div", { className: v(q({ size: d, error: o }), t), children: [
102
+ /* @__PURE__ */ u(
103
+ U,
104
+ {
105
+ selectedCountry: T.iso2,
106
+ onCountryChange: (a) => $(a),
107
+ countries: h,
108
+ disabled: f,
109
+ error: o,
110
+ ariaLabel: N ?? s.phoneInput.countrySelectorAriaLabel,
111
+ searchPlaceholder: z ?? s.phoneInput.searchPlaceholder,
112
+ noResultsText: F ?? s.phoneInput.noResults
113
+ }
114
+ ),
115
+ /* @__PURE__ */ u(
116
+ "input",
117
+ {
118
+ ...b,
119
+ ref: n,
120
+ id: r,
121
+ type: "tel",
122
+ inputMode: "tel",
123
+ autoComplete: b.autoComplete ?? "tel",
124
+ "data-slot": "phone-input",
125
+ value: M,
126
+ onChange: D,
127
+ disabled: f,
128
+ required: l,
129
+ "aria-describedby": y,
130
+ "aria-labelledby": x,
131
+ "aria-invalid": o,
132
+ "aria-required": l,
133
+ className: ee(d)
134
+ }
135
+ )
136
+ ] })
137
+ }
138
+ );
139
+ }
140
+ );
141
+ te.displayName = "PhoneInput";
142
+ export {
143
+ te as PhoneInput
144
+ };
@@ -0,0 +1,29 @@
1
+ import { Meta, StoryObj } from '@storybook/react-vite';
2
+ import { PhoneInput } from './PhoneInput';
3
+ declare const meta: Meta<typeof PhoneInput>;
4
+ export default meta;
5
+ type Story = StoryObj<typeof PhoneInput>;
6
+ export declare const Default: Story;
7
+ export declare const Prefilled: Story;
8
+ export declare const ErrorState: Story;
9
+ export declare const Disabled: Story;
10
+ /**
11
+ * Controlled usage: the parent owns the E.164 value and echoes it back below
12
+ * the field. This is the real integration pattern — keep the wiring inline so
13
+ * the code preview teaches it.
14
+ */
15
+ export declare const Controlled: Story;
16
+ export declare const AllSizes: Story;
17
+ /**
18
+ * Consolidated state matrix for visual regression. Hover and focus are forced
19
+ * with `storybook-addon-pseudo-states` (`pseudo-hover` /
20
+ * `pseudo-focus-within`) rather than duplicating utility classes.
21
+ */
22
+ export declare const AllStates: Story;
23
+ /**
24
+ * Country dropdown rendered open so the visual-regression suite captures the
25
+ * portaled Popover (search field + country list). The closed stories cannot
26
+ * show it.
27
+ */
28
+ export declare const OpenState: Story;
29
+ //# sourceMappingURL=PhoneInput.stories.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PhoneInput.stories.d.ts","sourceRoot":"","sources":["../../../src/components/PhoneInput/PhoneInput.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAE3D,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAEzC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,UAAU,CA8DjC,CAAA;AAED,eAAe,IAAI,CAAA;AACnB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,UAAU,CAAC,CAAA;AAExC,eAAO,MAAM,OAAO,EAAE,KAarB,CAAA;AAED,eAAO,MAAM,SAAS,EAAE,KAevB,CAAA;AAED,eAAO,MAAM,UAAU,EAAE,KAcxB,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,KActB,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,UAAU,EAAE,KA0BxB,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,KAiBtB,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,SAAS,EAAE,KA0CvB,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,SAAS,EAAE,KAsBvB,CAAA"}
@@ -0,0 +1,2 @@
1
+ export { PhoneInput, type PhoneInputProps, type PhoneInputChangeMeta, } from './PhoneInput';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/PhoneInput/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,KAAK,eAAe,EACpB,KAAK,oBAAoB,GAC1B,MAAM,cAAc,CAAA"}
@@ -1,9 +1,9 @@
1
1
  import { jsxs as R, jsx as e } from "react/jsx-runtime";
2
2
  import * as n from "react";
3
3
  import { useMuzaTranslations as j } from "../../translations/TranslationContext.js";
4
- import { MagnifyingGlass as w } from "../Icons/CustomIcons.js";
5
4
  import { cn as s } from "../../utils/cn.js";
6
- import { CloseCircleBold as I } from "@solar-icons/react-perf";
5
+ import { CloseCircleBold as w } from "@solar-icons/react-perf";
6
+ import { MagnifyingGlass as I } from "../Icons/CustomIcons.js";
7
7
  import { Input as M } from "../Input/Input.js";
8
8
  const F = ({
9
9
  className: p,
@@ -49,7 +49,7 @@ const F = ({
49
49
  type: "button",
50
50
  onClick: z,
51
51
  children: /* @__PURE__ */ e(
52
- I,
52
+ w,
53
53
  {
54
54
  className: s("size-icon-small text-icon-dark-secondary-def", {
55
55
  "text-text-dark-tertiary": r
@@ -70,7 +70,7 @@ const F = ({
70
70
  "aria-label": L,
71
71
  type: "submit",
72
72
  children: /* @__PURE__ */ e(
73
- w,
73
+ I,
74
74
  {
75
75
  className: s(
76
76
  "size-icon-small text-icon-dark-primary-def transition-colors",
@@ -4,7 +4,7 @@ export interface ToastProps {
4
4
  /** Unique identifier for the toast instance. Provided automatically by `toast()`. */
5
5
  id: string | number;
6
6
  /** Visual style variant indicating message severity. */
7
- variant: 'warning' | 'success' | 'error';
7
+ variant: 'warning' | 'success' | 'error' | 'info';
8
8
  /** Message text content displayed in the toast. */
9
9
  text?: string;
10
10
  /** Enables close button for manual dismissal. @default true */
@@ -31,6 +31,7 @@ export interface ToastProps {
31
31
  * toast({ variant: 'success', text: 'Saved successfully' })
32
32
  * toast({ variant: 'error', text: 'Failed to save', autoDismiss: 5000 })
33
33
  * toast({ variant: 'warning', text: 'Unsaved changes', closable: false })
34
+ * toast({ variant: 'info', text: 'Sync in progress' })
34
35
  */
35
36
  declare const toast: (toast: Omit<ToastProps, "id">) => string | number;
36
37
  declare const Toast: ({ id, text, variant, icon, dismissAriaLabel, onClose, closable, className, }: ToastProps) => import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../../src/components/Toast/Toast.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAA;AAOzB,wEAAwE;AACxE,MAAM,WAAW,UAAU;IACzB,qFAAqF;IACrF,EAAE,EAAE,MAAM,GAAG,MAAM,CAAA;IACnB,wDAAwD;IACxD,OAAO,EAAE,SAAS,GAAG,SAAS,GAAG,OAAO,CAAA;IACxC,mDAAmD;IACnD,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,+DAA+D;IAC/D,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,+EAA+E;IAC/E,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,gEAAgE;IAChE,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACtB,gEAAgE;IAChE,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,iDAAiD;IACjD,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,qDAAqD;IACrD,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,wFAAwF;IACxF,aAAa,CAAC,EAAE,MAAM,IAAI,CAAA;IAC1B,yFAAyF;IACzF,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED;;;;;;;GAOG;AACH,QAAA,MAAM,KAAK,GAAI,OAAO,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,oBAO3C,CAAA;AAED,QAAA,MAAM,KAAK,GAAI,8EASZ,UAAU,4CA8CZ,CAAA;AAED,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,CAAA"}
1
+ {"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../../src/components/Toast/Toast.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAA;AAOzB,wEAAwE;AACxE,MAAM,WAAW,UAAU;IACzB,qFAAqF;IACrF,EAAE,EAAE,MAAM,GAAG,MAAM,CAAA;IACnB,wDAAwD;IACxD,OAAO,EAAE,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,CAAA;IACjD,mDAAmD;IACnD,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,+DAA+D;IAC/D,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,+EAA+E;IAC/E,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,gEAAgE;IAChE,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACtB,gEAAgE;IAChE,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,iDAAiD;IACjD,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,qDAAqD;IACrD,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,wFAAwF;IACxF,aAAa,CAAC,EAAE,MAAM,IAAI,CAAA;IAC1B,yFAAyF;IACzF,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED;;;;;;;;GAQG;AACH,QAAA,MAAM,KAAK,GAAI,OAAO,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,oBAO3C,CAAA;AAED,QAAA,MAAM,KAAK,GAAI,8EASZ,UAAU,4CAmDZ,CAAA;AAED,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,CAAA"}
@@ -1,44 +1,45 @@
1
- import { jsx as t, jsxs as m } from "react/jsx-runtime";
1
+ import { jsx as e, jsxs as m } from "react/jsx-runtime";
2
2
  import "react";
3
- import { toast as a } from "sonner";
4
- import { XClose as u } from "../Icons/CustomIcons.js";
5
- import { cn as d } from "../../utils/cn.js";
6
- import { DangerTriangleOutline as p, UnreadOutline as g } from "@solar-icons/react-perf";
7
- import { Typography as x } from "../Typography/Typography.js";
8
- const T = (e) => a.custom((s) => /* @__PURE__ */ t(f, { id: s, ...e }), {
9
- dismissible: e.closable,
10
- onAutoClose: e.onAutoDismiss,
11
- duration: e.autoDismiss,
12
- toasterId: e.toasterId
13
- }), f = ({
14
- id: e,
15
- text: s,
16
- variant: r,
17
- icon: i,
18
- dismissAriaLabel: c,
19
- onClose: o,
20
- closable: l = !0,
21
- className: n
3
+ import { toast as c } from "sonner";
4
+ import { XClose as n } from "../Icons/CustomIcons.js";
5
+ import { cn as u } from "../../utils/cn.js";
6
+ import { DangerTriangleOutline as g, UnreadOutline as x } from "@solar-icons/react-perf";
7
+ import { Typography as d } from "../Typography/Typography.js";
8
+ const T = (s) => c.custom((o) => /* @__PURE__ */ e(b, { id: o, ...s }), {
9
+ dismissible: s.closable,
10
+ onAutoClose: s.onAutoDismiss,
11
+ duration: s.autoDismiss,
12
+ toasterId: s.toasterId
13
+ }), b = ({
14
+ id: s,
15
+ text: o,
16
+ variant: t,
17
+ icon: r,
18
+ dismissAriaLabel: a,
19
+ onClose: i,
20
+ closable: p = !0,
21
+ className: l
22
22
  }) => /* @__PURE__ */ m(
23
23
  "div",
24
24
  {
25
- className: d(
25
+ className: u(
26
26
  "flex items-center gap-comp-alert-gap-sm rounded-xl p-xl",
27
27
  {
28
- "bg-orange-200 text-comp-alert-text-warning": r === "warning",
29
- "bg-green-400 text-text-invert-def": r === "success",
30
- "bg-surface-error-def text-text-invert-def": r === "error"
28
+ "bg-comp-toast-bg-warning text-comp-toast-text-warning": t === "warning",
29
+ "bg-comp-toast-bg-success text-comp-toast-text-success": t === "success",
30
+ "bg-comp-toast-bg-error text-comp-toast-text-text-error": t === "error",
31
+ "bg-comp-toast-bg-info text-comp-toast-text-info": t === "info"
31
32
  },
32
- n
33
+ l
33
34
  ),
34
35
  children: [
35
36
  /* @__PURE__ */ m("div", { className: "[&>svg]:size-comp-alert-ico-size", children: [
36
- i,
37
- !i && (r === "error" || r === "warning") && /* @__PURE__ */ t(p, {}),
38
- !i && r === "success" && /* @__PURE__ */ t(g, {})
37
+ r,
38
+ !r && (t === "error" || t === "warning" || t === "info") && /* @__PURE__ */ e(g, {}),
39
+ !r && t === "success" && /* @__PURE__ */ e(x, {})
39
40
  ] }),
40
- /* @__PURE__ */ t(
41
- x,
41
+ /* @__PURE__ */ e(
42
+ d,
42
43
  {
43
44
  component: "p",
44
45
  variant: "body",
@@ -46,24 +47,24 @@ const T = (e) => a.custom((s) => /* @__PURE__ */ t(f, { id: s, ...e }), {
46
47
  size: "base",
47
48
  className: "text-inherit",
48
49
  fixY: !0,
49
- children: s
50
+ children: o
50
51
  }
51
52
  ),
52
- l && /* @__PURE__ */ t(
53
+ p && /* @__PURE__ */ e(
53
54
  "button",
54
55
  {
55
56
  className: "ml-auto focus-visible-auto",
56
- "aria-label": c,
57
+ "aria-label": a,
57
58
  onClick: () => {
58
- a.dismiss(e), o == null || o();
59
+ c.dismiss(s), i == null || i();
59
60
  },
60
- children: /* @__PURE__ */ t(u, { className: "size-comp-alert-ico-size" })
61
+ children: /* @__PURE__ */ e(n, { className: "size-comp-alert-ico-size" })
61
62
  }
62
63
  )
63
64
  ]
64
65
  }
65
66
  );
66
67
  export {
67
- f as Toast,
68
+ b as Toast,
68
69
  T as toast
69
70
  };
@@ -7,5 +7,6 @@ export declare const Warning: Story;
7
7
  export declare const OpenState: Story;
8
8
  export declare const Success: Story;
9
9
  export declare const Error: Story;
10
+ export declare const Info: Story;
10
11
  export declare const AllOptions: Story;
11
12
  //# sourceMappingURL=Toast.stories.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Toast.stories.d.ts","sourceRoot":"","sources":["../../../src/components/Toast/Toast.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAG3D,OAAO,EAAE,KAAK,EAAS,MAAM,SAAS,CAAA;AAGtC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,KAAK,CA4D5B,CAAA;AAED,eAAe,IAAI,CAAA;AACnB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,KAAK,CAAC,CAAA;AAEnC,eAAO,MAAM,OAAO,EAAE,KAiCrB,CAAA;AAED,eAAO,MAAM,SAAS,EAAE,KAkCvB,CAAA;AAED,eAAO,MAAM,OAAO,EAAE,KAkCrB,CAAA;AAED,eAAO,MAAM,KAAK,EAAE,KAkCnB,CAAA;AAED,eAAO,MAAM,UAAU,EAAE,KAgExB,CAAA"}
1
+ {"version":3,"file":"Toast.stories.d.ts","sourceRoot":"","sources":["../../../src/components/Toast/Toast.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAG3D,OAAO,EAAE,KAAK,EAAS,MAAM,SAAS,CAAA;AAGtC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,KAAK,CA4D5B,CAAA;AAED,eAAe,IAAI,CAAA;AACnB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,KAAK,CAAC,CAAA;AAEnC,eAAO,MAAM,OAAO,EAAE,KAiCrB,CAAA;AAED,eAAO,MAAM,SAAS,EAAE,KAkCvB,CAAA;AAED,eAAO,MAAM,OAAO,EAAE,KAkCrB,CAAA;AAED,eAAO,MAAM,KAAK,EAAE,KAkCnB,CAAA;AAED,eAAO,MAAM,IAAI,EAAE,KAkClB,CAAA;AAED,eAAO,MAAM,UAAU,EAAE,KA0ExB,CAAA"}
@@ -22,11 +22,18 @@ export interface TooltipProps extends React.ComponentProps<typeof TooltipPrimiti
22
22
  delayDuration?: number;
23
23
  /** Prevents the tooltip from staying open when hovering over the content. */
24
24
  disableHoverableContent?: boolean;
25
+ /**
26
+ * Opens the tooltip on click/tap instead of hover/focus and renders a close
27
+ * button (on tablet/mobile) so it can be dismissed on touch devices. Use for
28
+ * tap-triggered hints, e.g. a help icon beside an input label.
29
+ * @default false
30
+ */
31
+ openOnClick?: boolean;
25
32
  }
26
- declare const Tooltip: React.FC<TooltipProps>;
33
+ declare const Tooltip: ({ openOnClick, open: openProp, defaultOpen, onOpenChange, children, ...props }: TooltipProps) => import("react/jsx-runtime").JSX.Element;
27
34
  /** Props for the TooltipTrigger. Element that displays tooltip on hover/focus. Use `asChild` for custom elements. */
28
35
  export type TooltipTriggerProps = React.ComponentProps<typeof TooltipPrimitive.Trigger>;
29
- declare const TooltipTrigger: React.ForwardRefExoticComponent<TooltipPrimitive.TooltipTriggerProps & React.RefAttributes<HTMLButtonElement>>;
36
+ declare const TooltipTrigger: React.ForwardRefExoticComponent<Omit<TooltipPrimitive.TooltipTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
30
37
  /** Props for the TooltipContent. Styled floating container with positioning and animations. */
31
38
  export interface TooltipContentProps extends React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content> {
32
39
  /** Preferred side of the trigger to render against. @default 'top' */
@@ -37,6 +44,13 @@ export interface TooltipContentProps extends React.ComponentPropsWithoutRef<type
37
44
  align?: 'start' | 'center' | 'end';
38
45
  /** Offset in pixels from the aligned edge. */
39
46
  alignOffset?: number;
47
+ /**
48
+ * Accessible label for the close button shown in click (`openOnClick`) mode.
49
+ * Defaults to translation `tooltip.closeAriaLabel`.
50
+ */
51
+ closeAriaLabel?: string;
52
+ /** Fires when the close button is clicked (click mode only). */
53
+ onClose?: () => void;
40
54
  }
41
55
  declare const TooltipContent: React.ForwardRefExoticComponent<TooltipContentProps & React.RefAttributes<HTMLDivElement>>;
42
56
  export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };
@@ -1 +1 @@
1
- {"version":3,"file":"Tooltip.d.ts","sourceRoot":"","sources":["../../../src/components/Tooltip/Tooltip.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAA;AAI3D,+FAA+F;AAC/F,MAAM,WAAW,oBACf,SAAQ,KAAK,CAAC,wBAAwB,CAAC,OAAO,gBAAgB,CAAC,QAAQ,CAAC;IACxE,kEAAkE;IAClE,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,yFAAyF;IACzF,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,4FAA4F;IAC5F,uBAAuB,CAAC,EAAE,OAAO,CAAA;CAClC;AAED,QAAA,MAAM,eAAe,GAAI,cAAc,oBAAoB,4CAE1D,CAAA;AAED,uEAAuE;AACvE,MAAM,WAAW,YACf,SAAQ,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,IAAI,CAAC;IAC1D,4CAA4C;IAC5C,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,gEAAgE;IAChE,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,yCAAyC;IACzC,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IACtC,+DAA+D;IAC/D,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,6EAA6E;IAC7E,uBAAuB,CAAC,EAAE,OAAO,CAAA;CAClC;AAED,QAAA,MAAM,OAAO,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CAAyB,CAAA;AAE7D,qHAAqH;AACrH,MAAM,MAAM,mBAAmB,GAAG,KAAK,CAAC,cAAc,CACpD,OAAO,gBAAgB,CAAC,OAAO,CAChC,CAAA;AAED,QAAA,MAAM,cAAc,gHAA2B,CAAA;AAE/C,+FAA+F;AAC/F,MAAM,WAAW,mBACf,SAAQ,KAAK,CAAC,wBAAwB,CAAC,OAAO,gBAAgB,CAAC,OAAO,CAAC;IACvE,sEAAsE;IACtE,IAAI,CAAC,EAAE,KAAK,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAA;IAC1C,sDAAsD;IACtD,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,iEAAiE;IACjE,KAAK,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,CAAA;IAClC,8CAA8C;IAC9C,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB;AAED,QAAA,MAAM,cAAc,4FAiBlB,CAAA;AAGF,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,eAAe,EAAE,CAAA"}
1
+ {"version":3,"file":"Tooltip.d.ts","sourceRoot":"","sources":["../../../src/components/Tooltip/Tooltip.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAA;AAuB3D,+FAA+F;AAC/F,MAAM,WAAW,oBACf,SAAQ,KAAK,CAAC,wBAAwB,CAAC,OAAO,gBAAgB,CAAC,QAAQ,CAAC;IACxE,kEAAkE;IAClE,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,yFAAyF;IACzF,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,4FAA4F;IAC5F,uBAAuB,CAAC,EAAE,OAAO,CAAA;CAClC;AAED,QAAA,MAAM,eAAe,GAAI,cAAc,oBAAoB,4CAE1D,CAAA;AAED,uEAAuE;AACvE,MAAM,WAAW,YACf,SAAQ,KAAK,CAAC,cAAc,CAAC,OAAO,gBAAgB,CAAC,IAAI,CAAC;IAC1D,4CAA4C;IAC5C,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,gEAAgE;IAChE,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,yCAAyC;IACzC,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IACtC,+DAA+D;IAC/D,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,6EAA6E;IAC7E,uBAAuB,CAAC,EAAE,OAAO,CAAA;IACjC;;;;;OAKG;IACH,WAAW,CAAC,EAAE,OAAO,CAAA;CACtB;AAED,QAAA,MAAM,OAAO,GAAI,gFAOd,YAAY,4CAmCd,CAAA;AAED,qHAAqH;AACrH,MAAM,MAAM,mBAAmB,GAAG,KAAK,CAAC,cAAc,CACpD,OAAO,gBAAgB,CAAC,OAAO,CAChC,CAAA;AAED,QAAA,MAAM,cAAc,sKAiBlB,CAAA;AAGF,+FAA+F;AAC/F,MAAM,WAAW,mBACf,SAAQ,KAAK,CAAC,wBAAwB,CAAC,OAAO,gBAAgB,CAAC,OAAO,CAAC;IACvE,sEAAsE;IACtE,IAAI,CAAC,EAAE,KAAK,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAA;IAC1C,sDAAsD;IACtD,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,iEAAiE;IACjE,KAAK,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,CAAA;IAClC,8CAA8C;IAC9C,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,gEAAgE;IAChE,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB;AAED,QAAA,MAAM,cAAc,4FAkDnB,CAAA;AAGD,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,eAAe,EAAE,CAAA"}
@@ -1,25 +1,102 @@
1
- import { jsx as i } from "react/jsx-runtime";
2
- import * as n from "react";
3
- import * as o from "@radix-ui/react-tooltip";
4
- import { cn as s } from "../../utils/cn.js";
5
- import { Typography as m } from "../Typography/Typography.js";
6
- const g = ({ ...t }) => /* @__PURE__ */ i(o.Provider, { delayDuration: 100, ...t }), y = o.Root, T = o.Trigger, l = n.forwardRef(({ className: t, children: e, sideOffset: a = 4, ...r }, d) => /* @__PURE__ */ i(
7
- o.Content,
8
- {
9
- ref: d,
10
- sideOffset: a,
11
- className: s(
12
- "z-50 origin-[--radix-tooltip-content-transform-origin] animate-in overflow-hidden rounded-md bg-surface-brand-brand-tertiary px-lg py-md text-text-brand-def fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
13
- t
14
- ),
15
- ...r,
16
- children: /* @__PURE__ */ i(m, { component: "span", variant: "body", weight: "regular", size: "sm", children: e })
1
+ import { jsx as s, jsxs as v } from "react/jsx-runtime";
2
+ import * as i from "react";
3
+ import * as n from "@radix-ui/react-tooltip";
4
+ import { XClose as y } from "../Icons/CustomIcons.js";
5
+ import { useMuzaTranslationContext as T } from "../../translations/TranslationContext.js";
6
+ import { cn as w } from "../../utils/cn.js";
7
+ import { Typography as z } from "../Typography/Typography.js";
8
+ const b = () => {
9
+ }, u = i.createContext({
10
+ openOnClick: !1,
11
+ open: !1,
12
+ setOpen: b
13
+ }), M = ({ ...t }) => /* @__PURE__ */ s(n.Provider, { delayDuration: 100, ...t }), A = ({
14
+ openOnClick: t = !1,
15
+ open: r,
16
+ defaultOpen: l,
17
+ onOpenChange: o,
18
+ children: e,
19
+ ...d
20
+ }) => {
21
+ const [p, c] = i.useState(
22
+ l ?? !1
23
+ ), a = r !== void 0, m = a ? r : p, f = i.useCallback(
24
+ (x) => {
25
+ a || c(x), o == null || o(x);
26
+ },
27
+ [a, o]
28
+ ), g = i.useMemo(
29
+ () => ({ openOnClick: t, open: m, setOpen: f }),
30
+ [t, m, f]
31
+ );
32
+ return /* @__PURE__ */ s(u.Provider, { value: g, children: /* @__PURE__ */ s(
33
+ n.Root,
34
+ {
35
+ open: t ? m : r,
36
+ defaultOpen: t ? void 0 : l,
37
+ onOpenChange: t ? b : o,
38
+ ...d,
39
+ children: e
40
+ }
41
+ ) });
42
+ }, N = i.forwardRef(({ onClick: t, ...r }, l) => {
43
+ const { openOnClick: o, open: e, setOpen: d } = i.useContext(u);
44
+ return /* @__PURE__ */ s(
45
+ n.Trigger,
46
+ {
47
+ ref: l,
48
+ "aria-expanded": o ? e : void 0,
49
+ onClick: (p) => {
50
+ t == null || t(p), o && d(!e);
51
+ },
52
+ ...r
53
+ }
54
+ );
55
+ });
56
+ N.displayName = n.Trigger.displayName;
57
+ const h = i.forwardRef(
58
+ ({ className: t, children: r, sideOffset: l = 4, closeAriaLabel: o, onClose: e, ...d }, p) => {
59
+ const { openOnClick: c, setOpen: a } = i.useContext(u), { translations: m } = T(), f = o ?? m.tooltip.closeAriaLabel;
60
+ return /* @__PURE__ */ v(
61
+ n.Content,
62
+ {
63
+ ref: p,
64
+ sideOffset: l,
65
+ className: w(
66
+ "relative z-50 origin-[--radix-tooltip-content-transform-origin] animate-in overflow-hidden rounded-comp-tooltip-radius bg-surface-brand-brand-tertiary py-comp-tooltip-p-ver text-text-brand-def fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
67
+ // Desktop uses the left token on both sides; tablet/mobile reserves
68
+ // extra right padding for the close button.
69
+ c ? "pr-comp-tooltip-p-right pl-comp-tooltip-p-left lg:pr-comp-tooltip-p-left" : "px-comp-tooltip-p-left",
70
+ t
71
+ ),
72
+ ...d,
73
+ ...c && {
74
+ onEscapeKeyDown: () => a(!1),
75
+ onPointerDownOutside: () => a(!1)
76
+ },
77
+ children: [
78
+ /* @__PURE__ */ s(z, { component: "span", variant: "body", weight: "regular", size: "sm", children: r }),
79
+ c && /* @__PURE__ */ s(
80
+ "button",
81
+ {
82
+ type: "button",
83
+ onClick: () => {
84
+ a(!1), e == null || e();
85
+ },
86
+ "aria-label": f,
87
+ className: "absolute top-2xs right-2xs flex size-comp-button-w-xs cursor-pointer items-center justify-center rounded-full text-text-brand-def focus-visible-auto lg:hidden",
88
+ children: /* @__PURE__ */ s(y, { className: "size-icon-xsmall" })
89
+ }
90
+ )
91
+ ]
92
+ }
93
+ );
17
94
  }
18
- ));
19
- l.displayName = o.Content.displayName;
95
+ );
96
+ h.displayName = n.Content.displayName;
20
97
  export {
21
- y as Tooltip,
22
- l as TooltipContent,
23
- g as TooltipProvider,
24
- T as TooltipTrigger
98
+ A as Tooltip,
99
+ h as TooltipContent,
100
+ M as TooltipProvider,
101
+ N as TooltipTrigger
25
102
  };
@@ -5,5 +5,6 @@ export default meta;
5
5
  type Story = StoryObj<typeof Tooltip>;
6
6
  export declare const DefaultTooltipComponent: Story;
7
7
  export declare const OpenState: Story;
8
+ export declare const OpenOnClick: Story;
8
9
  export declare const PrefferedSideBottom: Story;
9
10
  //# sourceMappingURL=Tooltip.stories.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Tooltip.stories.d.ts","sourceRoot":"","sources":["../../../src/components/Tooltip/Tooltip.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAE3D,OAAO,EACL,OAAO,EAIR,MAAM,WAAW,CAAA;AAElB,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,OAAO,CA8C9B,CAAA;AAED,eAAe,IAAI,CAAA;AACnB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,OAAO,CAAC,CAAA;AAErC,eAAO,MAAM,uBAAuB,EAAE,KAqBrC,CAAA;AAED,eAAO,MAAM,SAAS,EAAE,KAsBvB,CAAA;AAED,eAAO,MAAM,mBAAmB,EAAE,KAsBjC,CAAA"}
1
+ {"version":3,"file":"Tooltip.stories.d.ts","sourceRoot":"","sources":["../../../src/components/Tooltip/Tooltip.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAK3D,OAAO,EACL,OAAO,EAIR,MAAM,WAAW,CAAA;AAElB,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,OAAO,CAmD9B,CAAA;AAED,eAAe,IAAI,CAAA;AACnB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,OAAO,CAAC,CAAA;AAErC,eAAO,MAAM,uBAAuB,EAAE,KAqBrC,CAAA;AAED,eAAO,MAAM,SAAS,EAAE,KAsBvB,CAAA;AAED,eAAO,MAAM,WAAW,EAAE,KAkCzB,CAAA;AAED,eAAO,MAAM,mBAAmB,EAAE,KAsBjC,CAAA"}