@mage-ui/components 1.0.31 → 1.0.33

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 (62) hide show
  1. package/dist/components/buttons/button/Button.d.mts +2 -2
  2. package/dist/components/buttons/button-action/ButtonAction.d.mts +2 -2
  3. package/dist/components/buttons/button-action/ButtonLoader.d.mts +2 -2
  4. package/dist/components/buttons/button-icon/ButtonIcon.d.mts +2 -2
  5. package/dist/components/buttons/button-icon-visual/ButtonIconVisual.d.mts +2 -2
  6. package/dist/components/buttons/button-visual/ButtonVisual.d.mts +2 -2
  7. package/dist/components/controls/autocomplete/Autocomplete.d.mts +2 -2
  8. package/dist/components/controls/combobox/Combobox.d.mts +2 -2
  9. package/dist/components/controls/dropzone/Dropzone.d.mts +2 -2
  10. package/dist/components/controls/dropzone-files/DropzoneFiles.d.mts +2 -2
  11. package/dist/components/controls/file-input/FileInput.d.mts +2 -2
  12. package/dist/components/controls/file-input/FileInputMultiple.d.mts +2 -2
  13. package/dist/components/controls/index.d.mts +2 -0
  14. package/dist/components/controls/multi-select/MultiSelect.d.mts +2 -2
  15. package/dist/components/controls/multi-select/MultiSelectTags.d.mts +2 -2
  16. package/dist/components/controls/password-input/PasswordInput.d.mts +2 -2
  17. package/dist/components/controls/password-input/PasswordStrengthInput.d.mts +37 -3
  18. package/dist/components/controls/password-input/PasswordStrengthInput.d.mts.map +1 -1
  19. package/dist/components/controls/password-input/PasswordStrengthInput.mjs +10 -1
  20. package/dist/components/controls/password-input/PasswordStrengthInput.mjs.map +1 -1
  21. package/dist/components/controls/password-input/usePasswordRules.d.mts +3 -2
  22. package/dist/components/controls/password-input/usePasswordRules.d.mts.map +1 -1
  23. package/dist/components/controls/password-input-strength/oldPasswordInputStrength.d.mts +2 -2
  24. package/dist/components/controls/select/Select.d.mts +2 -2
  25. package/dist/components/controls/text-input/TextInput.d.mts +2 -2
  26. package/dist/components/controls/textarea/Textarea.d.mts +2 -2
  27. package/dist/components/controls/utils/chevron/Chevron.d.mts +2 -2
  28. package/dist/components/controls/utils/clear-button/ClearButton.d.mts +2 -2
  29. package/dist/components/data-display/assigned-user/AssignedUser.d.mts +2 -2
  30. package/dist/components/data-display/avatar/Avatar.d.mts +2 -2
  31. package/dist/components/data-display/badge/Badge.d.mts +2 -2
  32. package/dist/components/data-display/calendar/Calendar.d.mts +2 -2
  33. package/dist/components/data-display/loader-dot/LoaderDot.d.mts +2 -2
  34. package/dist/components/data-display/loader-oval/LoaderOval.d.mts +2 -2
  35. package/dist/components/data-display/removable-item/RemovableItem.d.mts +2 -2
  36. package/dist/components/data-display/tag/Tag.d.mts +3 -3
  37. package/dist/components/data-display/tag-group/TagGroup.d.mts +2 -2
  38. package/dist/components/data-display/uploaded-file/UploadedFile.d.mts +2 -2
  39. package/dist/components/data-display/uploaded-file/UploadedFileDetails.d.mts +2 -2
  40. package/dist/components/forms/Form.d.mts +7 -7
  41. package/dist/components/index.d.mts +2 -0
  42. package/dist/components/layouts/top-bar/TopBar.d.mts +2 -2
  43. package/dist/components/misc/horizontal-divider/HorizontalDivider.d.mts +2 -2
  44. package/dist/components/misc/visually-hidden/VisuallyHidden.d.mts +2 -2
  45. package/dist/components/navigations/breadcrumbs/Breadcrumbs.d.mts +2 -2
  46. package/dist/components/navigations/menu/Menu.d.mts +4 -4
  47. package/dist/components/navigations/sidebars/sidebar/Sidebar.d.mts +3 -3
  48. package/dist/components/overlays/modal/Modal.d.mts +10 -10
  49. package/dist/components/overlays/modals/ModalsProvider.d.mts +2 -2
  50. package/dist/components/overlays/tooltip/Tooltip.d.mts +2 -2
  51. package/dist/index.d.mts +3 -1
  52. package/dist/index.mjs +1 -1
  53. package/dist/semedlab/components/data-display/user-group-preview/UserGroupPreview.d.mts +2 -2
  54. package/dist/semedlab/components/navigations/backoffice-top-bar/BackofficeTopBar.d.mts +2 -2
  55. package/dist/semedlab/components/navigations/backoffice-top-bar/BackofficeTopBar.d.mts.map +1 -1
  56. package/dist/semedlab/components/navigations/notification-list/NotificationList.d.mts +2 -2
  57. package/dist/semedlab/components/navigations/notification-list/NotificationList.d.mts.map +1 -1
  58. package/dist/semedlab/components/navigations/notification-menu/NotificationMenu.d.mts +2 -2
  59. package/dist/semedlab/components/navigations/notification-menu/NotificationMenu.d.mts.map +1 -1
  60. package/dist/semedlab/components/navigations/profile-menu/ProfileMenu.d.mts +2 -2
  61. package/dist/semedlab/components/navigations/profile-menu/ProfileMenu.d.mts.map +1 -1
  62. package/package.json +3 -3
@@ -1,5 +1,5 @@
1
1
  import { ButtonVariantProps } from "@mage-ui/styled-system/recipes";
2
- import * as react_jsx_runtime15 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime16 from "react/jsx-runtime";
3
3
  import { ComponentPropsWithoutRef, ReactNode } from "react";
4
4
 
5
5
  //#region src/components/buttons/button/Button.d.ts
@@ -21,7 +21,7 @@ declare const Button: ({
21
21
  startSlot,
22
22
  endSlot,
23
23
  ...props
24
- }: ButtonProps) => react_jsx_runtime15.JSX.Element;
24
+ }: ButtonProps) => react_jsx_runtime16.JSX.Element;
25
25
  //#endregion
26
26
  export { Button, ButtonProps };
27
27
  //# sourceMappingURL=Button.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { ButtonProps } from "../button/Button.mjs";
2
- import * as react_jsx_runtime16 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime17 from "react/jsx-runtime";
3
3
  import { ReactNode } from "react";
4
4
 
5
5
  //#region src/components/buttons/button-action/ButtonAction.d.ts
@@ -26,7 +26,7 @@ declare const ButtonAction: ({
26
26
  successDuration,
27
27
  disabled,
28
28
  ...props
29
- }: ButtonActionProps) => react_jsx_runtime16.JSX.Element;
29
+ }: ButtonActionProps) => react_jsx_runtime17.JSX.Element;
30
30
  //#endregion
31
31
  export { ButtonAction, ButtonActionProps };
32
32
  //# sourceMappingURL=ButtonAction.d.mts.map
@@ -1,11 +1,11 @@
1
- import * as react_jsx_runtime17 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime18 from "react/jsx-runtime";
2
2
  import { ComponentProps } from "react";
3
3
 
4
4
  //#region src/components/buttons/button-action/ButtonLoader.d.ts
5
5
  declare const ButtonLoader: ({
6
6
  className,
7
7
  ...props
8
- }: ComponentProps<"span">) => react_jsx_runtime17.JSX.Element;
8
+ }: ComponentProps<"span">) => react_jsx_runtime18.JSX.Element;
9
9
  //#endregion
10
10
  export { ButtonLoader };
11
11
  //# sourceMappingURL=ButtonLoader.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime18 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime19 from "react/jsx-runtime";
2
2
  import { ComponentProps } from "react";
3
3
 
4
4
  //#region src/components/buttons/button-icon/ButtonIcon.d.ts
@@ -23,7 +23,7 @@ declare const ButtonIcon: ({
23
23
  onClick,
24
24
  disabled,
25
25
  classNames
26
- }: ButtonIconProps) => react_jsx_runtime18.JSX.Element;
26
+ }: ButtonIconProps) => react_jsx_runtime19.JSX.Element;
27
27
  //#endregion
28
28
  export { ButtonIcon, ButtonIconProps };
29
29
  //# sourceMappingURL=ButtonIcon.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime19 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime20 from "react/jsx-runtime";
2
2
  import { ComponentProps } from "react";
3
3
 
4
4
  //#region src/components/buttons/button-icon-visual/ButtonIconVisual.d.ts
@@ -22,7 +22,7 @@ declare const ButtonIconVisual: ({
22
22
  name,
23
23
  path,
24
24
  disabled
25
- }: ButtonIconVisualProps) => react_jsx_runtime19.JSX.Element;
25
+ }: ButtonIconVisualProps) => react_jsx_runtime20.JSX.Element;
26
26
  //#endregion
27
27
  export { ButtonIconVisual, ButtonIconVisualProps };
28
28
  //# sourceMappingURL=ButtonIconVisual.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime20 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime21 from "react/jsx-runtime";
2
2
  import { ReactNode } from "react";
3
3
 
4
4
  //#region src/components/buttons/button-visual/ButtonVisual.d.ts
@@ -21,7 +21,7 @@ declare const ButtonVisual: ({
21
21
  endSlot,
22
22
  children,
23
23
  disabled
24
- }: ButtonVisualProps) => react_jsx_runtime20.JSX.Element;
24
+ }: ButtonVisualProps) => react_jsx_runtime21.JSX.Element;
25
25
  //#endregion
26
26
  export { ButtonVisual, ButtonVisualProps };
27
27
  //# sourceMappingURL=ButtonVisual.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { ComboboxProps } from "../combobox/Combobox.mjs";
2
- import * as react_jsx_runtime24 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime25 from "react/jsx-runtime";
3
3
  import { ReactNode } from "react";
4
4
 
5
5
  //#region src/components/controls/autocomplete/Autocomplete.d.ts
@@ -29,7 +29,7 @@ declare const Autocomplete: ({
29
29
  emptyMessage,
30
30
  minLength,
31
31
  classNames
32
- }: AutocompleteProps) => react_jsx_runtime24.JSX.Element;
32
+ }: AutocompleteProps) => react_jsx_runtime25.JSX.Element;
33
33
  //#endregion
34
34
  export { Autocomplete, AutocompleteProps, OptionProps };
35
35
  //# sourceMappingURL=Autocomplete.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { DropdownProps } from "../dropdown/Dropdown.mjs";
2
- import * as react_jsx_runtime25 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime26 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/controls/combobox/Combobox.d.ts
5
5
  type ComboboxProps = Omit<DropdownProps, 'classNames' | 'onChange' | 'onBlur' | 'onFocus' | 'onClick' | 'setValue' | 'children'> & {
@@ -52,7 +52,7 @@ declare const Combobox: ({
52
52
  btnClearLabel,
53
53
  onChange,
54
54
  classNames
55
- }: ComboboxProps) => react_jsx_runtime25.JSX.Element;
55
+ }: ComboboxProps) => react_jsx_runtime26.JSX.Element;
56
56
  //#endregion
57
57
  export { Combobox, ComboboxProps };
58
58
  //# sourceMappingURL=Combobox.d.mts.map
@@ -1,7 +1,7 @@
1
1
  import { IconProps } from "../../data-display/icons/icon/Icon.mjs";
2
2
  import { LoaderOvalProps } from "../../data-display/loader-oval/LoaderOval.mjs";
3
3
  import "../../data-display/index.mjs";
4
- import * as react_jsx_runtime26 from "react/jsx-runtime";
4
+ import * as react_jsx_runtime27 from "react/jsx-runtime";
5
5
  import { ReactNode } from "react";
6
6
 
7
7
  //#region src/components/controls/dropzone/Dropzone.d.ts
@@ -64,7 +64,7 @@ declare const Dropzone: ({
64
64
  hint,
65
65
  inputId,
66
66
  classNames
67
- }: DropzoneProps) => react_jsx_runtime26.JSX.Element;
67
+ }: DropzoneProps) => react_jsx_runtime27.JSX.Element;
68
68
  //#endregion
69
69
  export { Dropzone, DropzoneProps, FileData };
70
70
  //# sourceMappingURL=Dropzone.d.mts.map
@@ -2,7 +2,7 @@ import { UploadedFileProps } from "../../data-display/uploaded-file/UploadedFile
2
2
  import "../../data-display/index.mjs";
3
3
  import { DropzoneProps, FileData } from "../dropzone/Dropzone.mjs";
4
4
  import "../index.mjs";
5
- import * as react_jsx_runtime27 from "react/jsx-runtime";
5
+ import * as react_jsx_runtime28 from "react/jsx-runtime";
6
6
  import { ReactNode } from "react";
7
7
 
8
8
  //#region src/components/controls/dropzone-files/DropzoneFiles.d.ts
@@ -48,7 +48,7 @@ declare const DropzoneFiles: ({
48
48
  url,
49
49
  inputId,
50
50
  classNames
51
- }: DropzoneFilesProps) => react_jsx_runtime27.JSX.Element;
51
+ }: DropzoneFilesProps) => react_jsx_runtime28.JSX.Element;
52
52
  //#endregion
53
53
  export { DropzoneFiles, DropzoneFilesProps };
54
54
  //# sourceMappingURL=DropzoneFiles.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { BaseFileInputProps } from "./BaseFileInput.mjs";
2
- import * as react_jsx_runtime28 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime29 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/controls/file-input/FileInput.d.ts
5
5
  type FileInputProps = Omit<BaseFileInputProps, 'multiple' | 'valueComponent' | 'onChange'> & {
@@ -18,7 +18,7 @@ declare const FileInput: ({
18
18
  required,
19
19
  disabled,
20
20
  classNames
21
- }: FileInputProps) => react_jsx_runtime28.JSX.Element;
21
+ }: FileInputProps) => react_jsx_runtime29.JSX.Element;
22
22
  //#endregion
23
23
  export { FileInput, FileInputProps };
24
24
  //# sourceMappingURL=FileInput.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { BaseFileInputProps } from "./BaseFileInput.mjs";
2
- import * as react_jsx_runtime29 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime30 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/controls/file-input/FileInputMultiple.d.ts
5
5
  type FileInputMultipleProps = Omit<BaseFileInputProps, 'multiple' | 'onChange' | 'valueComponent'> & {
@@ -25,7 +25,7 @@ declare const FileInputMultiple: ({
25
25
  disabled,
26
26
  classNames,
27
27
  badgeClassNames
28
- }: FileInputMultipleProps) => react_jsx_runtime29.JSX.Element;
28
+ }: FileInputMultipleProps) => react_jsx_runtime30.JSX.Element;
29
29
  //#endregion
30
30
  export { FileInputMultiple, FileInputMultipleProps };
31
31
  //# sourceMappingURL=FileInputMultiple.d.mts.map
@@ -11,6 +11,8 @@ import { MultiSelect, MultiSelectProps } from "./multi-select/MultiSelect.mjs";
11
11
  import { MultiSelectTags, MultiSelectTagsProps } from "./multi-select/MultiSelectTags.mjs";
12
12
  import { TextInput, TextInputProps } from "./text-input/TextInput.mjs";
13
13
  import { PasswordInput, PasswordInputProps } from "./password-input/PasswordInput.mjs";
14
+ import { PasswordRule, PasswordSegment, PasswordStrengthInput, PasswordStrengthInputProps } from "./password-input/PasswordStrengthInput.mjs";
15
+ import { PasswordRuleDefinition, usePasswordRules } from "./password-input/usePasswordRules.mjs";
14
16
  import { PasswordInputStrength, PasswordInputStrengthProps } from "./password-input-strength/oldPasswordInputStrength.mjs";
15
17
  import { Radio, RadioProps } from "./radio/Radio.mjs";
16
18
  import { Select, SelectProps } from "./select/Select.mjs";
@@ -1,5 +1,5 @@
1
1
  import { DropdownProps, DropdownTextInputClassNames } from "../dropdown/Dropdown.mjs";
2
- import * as react_jsx_runtime30 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime31 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/controls/multi-select/MultiSelect.d.ts
5
5
  type MultiSelectProps = Omit<DropdownProps, 'classNames' | 'children' | 'onChange' | 'onFocus' | 'onBlur' | 'onClick' | 'value' | 'search' | 'setValue' | 'store' | 'target'> & {
@@ -39,7 +39,7 @@ declare const MultiSelect: ({
39
39
  keepMounted,
40
40
  textSelected,
41
41
  classNames
42
- }: MultiSelectProps) => react_jsx_runtime30.JSX.Element;
42
+ }: MultiSelectProps) => react_jsx_runtime31.JSX.Element;
43
43
  //#endregion
44
44
  export { MultiSelect, MultiSelectProps };
45
45
  //# sourceMappingURL=MultiSelect.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { DropdownProps, DropdownTextInputClassNames } from "../dropdown/Dropdown.mjs";
2
- import * as react_jsx_runtime31 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime32 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/controls/multi-select/MultiSelectTags.d.ts
5
5
  type MultiSelectTagsProps = Omit<DropdownProps, 'classNames' | 'children' | 'onChange' | 'onFocus' | 'onBlur' | 'onClick' | 'value' | 'search' | 'setValue' | 'store' | 'target'> & {
@@ -57,7 +57,7 @@ declare const MultiSelectTags: ({
57
57
  startSlot,
58
58
  endSlot,
59
59
  classNames
60
- }: MultiSelectTagsProps) => react_jsx_runtime31.JSX.Element;
60
+ }: MultiSelectTagsProps) => react_jsx_runtime32.JSX.Element;
61
61
  //#endregion
62
62
  export { MultiSelectTags, MultiSelectTagsProps };
63
63
  //# sourceMappingURL=MultiSelectTags.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { TextInputProps } from "../text-input/TextInput.mjs";
2
- import * as react_jsx_runtime32 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime33 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/controls/password-input/PasswordInput.d.ts
5
5
  type PasswordInputProps = Omit<NonNullable<TextInputProps>, 'classNames'> & {
@@ -23,7 +23,7 @@ declare const PasswordInput: ({
23
23
  hideText,
24
24
  showText,
25
25
  ...props
26
- }: PasswordInputProps) => react_jsx_runtime32.JSX.Element;
26
+ }: PasswordInputProps) => react_jsx_runtime33.JSX.Element;
27
27
  //#endregion
28
28
  export { PasswordInput, PasswordInputProps };
29
29
  //# sourceMappingURL=PasswordInput.d.mts.map
@@ -1,11 +1,45 @@
1
- import "./PasswordInput.mjs";
2
- import "react/jsx-runtime";
1
+ import { IconProps } from "../../data-display/icons/icon/Icon.mjs";
2
+ import "../../data-display/index.mjs";
3
+ import { PasswordInputProps } from "./PasswordInput.mjs";
4
+ import * as react_jsx_runtime34 from "react/jsx-runtime";
3
5
 
4
6
  //#region src/components/controls/password-input/PasswordStrengthInput.d.ts
7
+ type PasswordRule = {
8
+ text: string;
9
+ isValid: boolean;
10
+ };
5
11
  type PasswordSegment = {
6
12
  minScore: number;
7
13
  label: string;
8
14
  };
15
+ type PasswordStrengthInputProps = PasswordInputProps & {
16
+ segments?: PasswordSegment[];
17
+ rules?: PasswordRule[];
18
+ showRules?: boolean;
19
+ showStrengthLabel?: boolean;
20
+ classNames?: {
21
+ passwordStrengthInput?: string;
22
+ root?: string;
23
+ strengthWrapper?: string;
24
+ barWrapper?: string;
25
+ bar?: string;
26
+ segment?: string;
27
+ strengthLabel?: string;
28
+ rules?: string;
29
+ rule?: string;
30
+ ruleIcon?: IconProps['classNames'];
31
+ ruleText?: string;
32
+ passwordInput?: PasswordInputProps['classNames'];
33
+ };
34
+ };
35
+ declare const PasswordStrengthInput: ({
36
+ segments,
37
+ rules,
38
+ showRules,
39
+ showStrengthLabel,
40
+ classNames,
41
+ ...props
42
+ }: PasswordStrengthInputProps) => react_jsx_runtime34.JSX.Element;
9
43
  //#endregion
10
- export { PasswordSegment };
44
+ export { PasswordRule, PasswordSegment, PasswordStrengthInput, PasswordStrengthInputProps };
11
45
  //# sourceMappingURL=PasswordStrengthInput.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PasswordStrengthInput.d.mts","names":[],"sources":["../../../../src/components/controls/password-input/PasswordStrengthInput.tsx"],"mappings":";;;;KAOY,eAAA;EACV,QAAA;EACA,KAAA;AAAA"}
1
+ {"version":3,"file":"PasswordStrengthInput.d.mts","names":[],"sources":["../../../../src/components/controls/password-input/PasswordStrengthInput.tsx"],"mappings":";;;;;;KAmCY,YAAA;EACV,IAAA;EACA,OAAA;AAAA;AAAA,KAGU,eAAA;EACV,QAAA;EACA,KAAA;AAAA;AAAA,KAGU,0BAAA,GAA6B,kBAAA;EACvC,QAAA,GAAW,eAAA;EACX,KAAA,GAAQ,YAAA;EACR,SAAA;EACA,iBAAA;EACA,UAAA;IACE,qBAAA;IACA,IAAA;IACA,eAAA;IACA,UAAA;IACA,GAAA;IACA,OAAA;IACA,aAAA;IACA,KAAA;IACA,IAAA;IACA,QAAA,GAAW,SAAA;IACX,QAAA;IACA,aAAA,GAAgB,kBAAA;EAAA;AAAA;AAAA,cAIP,qBAAA;EAAyB,QAAA;EAAA,KAAA;EAAA,SAAA;EAAA,iBAAA;EAAA,UAAA;EAAA,GAAA;AAAA,GAOnC,0BAAA,KAA0B,mBAAA,CAAA,GAAA,CAAA,OAAA"}
@@ -1,2 +1,11 @@
1
- import{PasswordInput as e}from"./PasswordInput.mjs";import{jsx as t,jsxs as n}from"react/jsx-runtime";const r=({segments:r=[],rules:i=[],showRules:a=!0,showStrengthLabel:o=!0,...s})=>{let c=[...r].sort((e,t)=>e.minScore-t.minScore),l=c.length,u=i.filter(e=>e.isValid).length,d=i.length>0?u/i.length*100:0,f=s.value&&String(s.value).length>0,p=[...c].reverse().find(e=>d>=e.minScore),m=f?p?.label??``:``,h=e=>f&&d>=c[e].minScore?`hsl(${e/(l-1)*120}, 70%, 45%)`:`#e5e7eb`;return n(`div`,{children:[t(e,{...s}),n(`div`,{style:{display:`flex`,alignItems:`center`,gap:`8px`,marginTop:`8px`},children:[t(`div`,{style:{display:`flex`,gap:`4px`,flex:1},children:c.map((e,n)=>t(`div`,{style:{flex:1,height:`4px`,backgroundColor:h(n),borderRadius:`2px`}},n))}),o&&m&&t(`span`,{style:{fontSize:`12px`,color:`#6b7280`,whiteSpace:`nowrap`},children:m})]}),a&&i.length>0&&t(`ul`,{style:{listStyle:`none`,padding:0,margin:`8px 0 0 0`,fontSize:`14px`},children:i.map((e,r)=>n(`li`,{style:{display:`flex`,alignItems:`center`,gap:`6px`,color:e.isValid?`#22c55e`:`#9ca3af`},children:[t(`span`,{children:e.isValid?`✓`:`✗`}),t(`span`,{children:e.text})]},r))})]})};export{r as PasswordStrengthInput};
1
+ import{Icon as e}from"../../data-display/icons/icon/Icon.mjs";import{PasswordInput as t}from"./PasswordInput.mjs";import{cx as n}from"@mage-ui/styled-system/css";import{passwordStrengthInput as r,passwordStrengthInputBar as i,passwordStrengthInputBarWrapper as a,passwordStrengthInputInput as o,passwordStrengthInputInputButtonIcon as s,passwordStrengthInputInputButtonIconIcon as c,passwordStrengthInputInputButtonIconIconRaw as l,passwordStrengthInputInputButtonIconIconRawRoot as u,passwordStrengthInputInputButtonIconRoot as d,passwordStrengthInputInputDescription as f,passwordStrengthInputInputError as p,passwordStrengthInputInputInput as m,passwordStrengthInputInputLabel as h,passwordStrengthInputInputRequired as g,passwordStrengthInputInputRoot as _,passwordStrengthInputInputSection as v,passwordStrengthInputInputWrapper as y,passwordStrengthInputRoot as b,passwordStrengthInputRule as x,passwordStrengthInputRuleIcon as S,passwordStrengthInputRuleIconIconRaw as C,passwordStrengthInputRuleIconIconRawRoot as w,passwordStrengthInputRuleIconRoot as T,passwordStrengthInputRuleText as E,passwordStrengthInputRules as D,passwordStrengthInputSegment as O,passwordStrengthInputStrengthLabel as k,passwordStrengthInputStrengthWrapper as A}from"@mage-ui/styled-system/recipes";import{jsx as j,jsxs as M}from"react/jsx-runtime";const N=({segments:N=[],rules:P=[],showRules:F=!0,showStrengthLabel:I=!0,classNames:L,...R})=>{let z=[...N].sort((e,t)=>e.minScore-t.minScore),B=z.length,V=P.filter(e=>e.isValid).length,H=P.length>0?V/P.length*100:0,U=F&&P.length>0,W=R.value&&String(R.value).length>0,G=[...z].reverse().find(e=>H>=e.minScore),K=W?G?.label??``:``,q=e=>W&&H>=z[e].minScore?`hsl(
2
+ calc(
3
+ var(--password-strength-input-segment-hue-start) +
4
+ ${B>1?e/(B-1):1} *
5
+ (var(--password-strength-input-segment-hue-end) -
6
+ var(--password-strength-input-segment-hue-start))
7
+ ),
8
+ var(--password-strength-input-segment-saturation),
9
+ var(--password-strength-input-segment-lightness)
10
+ )`:`var(--password-strength-input-segment-background)`;return M(`div`,{className:n(L?.passwordStrengthInput??r(),L?.root??b()),"data-scope":`passwordStrengthInput`,"data-rules":U,children:[j(t,{classNames:{passwordInput:L?.passwordInput??o(),root:L?.passwordInput?.root??_(),label:L?.passwordInput?.label??h(),description:L?.passwordInput?.description??f(),error:L?.passwordInput?.error??p(),wrapper:L?.passwordInput?.wrapper??y(),required:L?.passwordInput?.required??g(),input:L?.passwordInput?.input??m(),section:L?.passwordInput?.section??v(),buttonIcon:{buttonIcon:L?.passwordInput?.buttonIcon?.buttonIcon??s(),root:L?.passwordInput?.buttonIcon?.root??d(),icon:L?.passwordInput?.buttonIcon?.icon??c(),iconRaw:{iconRaw:L?.passwordInput?.buttonIcon?.iconRaw?.iconRaw??l(),root:L?.passwordInput?.buttonIcon?.iconRaw?.root??u()}}},...R}),M(`div`,{className:n(L?.strengthWrapper??A()),children:[M(`div`,{className:n(L?.barWrapper??a()),children:[j(`div`,{className:n(L?.bar??i()),children:z.map((e,t)=>j(`div`,{style:{backgroundColor:q(t)},className:n(L?.segment??O())},t))}),I&&K&&j(`span`,{className:n(L?.strengthLabel??k()),children:K})]}),U&&j(`ul`,{className:n(L?.rules??D()),children:P.map((t,r)=>M(`li`,{className:n(L?.rule??x()),"data-valid":t.isValid||void 0,children:[j(e,{path:`/icons/sprite-mage.svg`,name:t.isValid?`mage-password-input-strength-rule-check`:`mage-password-input-strength-rule-x`,classNames:{icon:L?.ruleIcon?.icon??S(),root:L?.ruleIcon?.root??T(),iconRaw:{iconRaw:L?.ruleIcon?.iconRaw?.iconRaw??C(),root:L?.ruleIcon?.iconRaw?.root??w()}}}),j(`span`,{className:n(L?.ruleText??E()),children:t.text})]},r))})]})]})};export{N as PasswordStrengthInput};
2
11
  //# sourceMappingURL=PasswordStrengthInput.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"PasswordStrengthInput.mjs","names":[],"sources":["../../../../src/components/controls/password-input/PasswordStrengthInput.tsx"],"sourcesContent":["import { PasswordInput, type PasswordInputProps } from './PasswordInput';\n\nexport type PasswordRule = {\n text: string;\n isValid: boolean;\n};\n\nexport type PasswordSegment = {\n minScore: number;\n label: string;\n};\n\nexport type PasswordStrengthInputProps = PasswordInputProps & {\n segments?: PasswordSegment[];\n rules?: PasswordRule[];\n showRules?: boolean;\n showStrengthLabel?: boolean;\n};\n\nexport const PasswordStrengthInput = ({\n segments = [],\n rules = [],\n showRules = true,\n showStrengthLabel = true,\n ...props\n}: PasswordStrengthInputProps) => {\n const sortedSegments = [...segments].sort((a, b) => a.minScore - b.minScore);\n const segmentCount = sortedSegments.length;\n\n const validCount = rules.filter((rule) => rule.isValid).length;\n const scorePercent = rules.length > 0 ? (validCount / rules.length) * 100 : 0;\n\n const hasValue = props.value && String(props.value).length > 0;\n\n const currentSegment = [...sortedSegments]\n .reverse()\n .find((segment) => scorePercent >= segment.minScore);\n const currentLabel = hasValue ? (currentSegment?.label ?? '') : '';\n\n const getSegmentColor = (index: number) => {\n if (!hasValue) return '#e5e7eb';\n const segment = sortedSegments[index];\n if (scorePercent >= segment.minScore) {\n const hue = (index / (segmentCount - 1)) * 120;\n return `hsl(${hue}, 70%, 45%)`;\n }\n return '#e5e7eb';\n };\n\n return (\n <div>\n <PasswordInput {...props} />\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: '8px',\n marginTop: '8px',\n }}\n >\n <div style={{ display: 'flex', gap: '4px', flex: 1 }}>\n {sortedSegments.map((_, index) => (\n <div\n key={index}\n style={{\n flex: 1,\n height: '4px',\n backgroundColor: getSegmentColor(index),\n borderRadius: '2px',\n }}\n />\n ))}\n </div>\n {showStrengthLabel && currentLabel && (\n <span\n style={{ fontSize: '12px', color: '#6b7280', whiteSpace: 'nowrap' }}\n >\n {currentLabel}\n </span>\n )}\n </div>\n {showRules && rules.length > 0 && (\n <ul\n style={{\n listStyle: 'none',\n padding: 0,\n margin: '8px 0 0 0',\n fontSize: '14px',\n }}\n >\n {rules.map((rule, index) => (\n <li\n key={index}\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: '6px',\n color: rule.isValid ? '#22c55e' : '#9ca3af',\n }}\n >\n <span>{rule.isValid ? '✓' : '✗'}</span>\n <span>{rule.text}</span>\n </li>\n ))}\n </ul>\n )}\n </div>\n );\n};\n"],"mappings":"sGAmBA,MAAa,GAAyB,CACpC,WAAW,EAAE,CACb,QAAQ,EAAE,CACV,YAAY,GACZ,oBAAoB,GACpB,GAAG,KAC6B,CAChC,IAAM,EAAiB,CAAC,GAAG,EAAS,CAAC,MAAM,EAAG,IAAM,EAAE,SAAW,EAAE,SAAS,CACtE,EAAe,EAAe,OAE9B,EAAa,EAAM,OAAQ,GAAS,EAAK,QAAQ,CAAC,OAClD,EAAe,EAAM,OAAS,EAAK,EAAa,EAAM,OAAU,IAAM,EAEtE,EAAW,EAAM,OAAS,OAAO,EAAM,MAAM,CAAC,OAAS,EAEvD,EAAiB,CAAC,GAAG,EAAe,CACvC,SAAS,CACT,KAAM,GAAY,GAAgB,EAAQ,SAAS,CAChD,EAAe,EAAY,GAAgB,OAAS,GAAM,GAE1D,EAAmB,GAClB,GAED,GADY,EAAe,GACH,SAEnB,OADM,GAAS,EAAe,GAAM,IACzB,aAEb,UAGT,OACE,EAAC,MAAA,CAAA,SAAA,CACC,EAAC,EAAA,CAAc,GAAI,EAAA,CAAS,CAC5B,EAAC,MAAA,CACC,MAAO,CACL,QAAS,OACT,WAAY,SACZ,IAAK,MACL,UAAW,MACZ,WAED,EAAC,MAAA,CAAI,MAAO,CAAE,QAAS,OAAQ,IAAK,MAAO,KAAM,EAAG,UACjD,EAAe,KAAK,EAAG,IACtB,EAAC,MAAA,CAEC,MAAO,CACL,KAAM,EACN,OAAQ,MACR,gBAAiB,EAAgB,EAAM,CACvC,aAAc,MACf,CAAA,CANI,EAOL,CACF,EACE,CACL,GAAqB,GACpB,EAAC,OAAA,CACC,MAAO,CAAE,SAAU,OAAQ,MAAO,UAAW,WAAY,SAAU,UAElE,GACI,CAAA,EAEL,CACL,GAAa,EAAM,OAAS,GAC3B,EAAC,KAAA,CACC,MAAO,CACL,UAAW,OACX,QAAS,EACT,OAAQ,YACR,SAAU,OACX,UAEA,EAAM,KAAK,EAAM,IAChB,EAAC,KAAA,CAEC,MAAO,CACL,QAAS,OACT,WAAY,SACZ,IAAK,MACL,MAAO,EAAK,QAAU,UAAY,UACnC,WAED,EAAC,OAAA,CAAA,SAAM,EAAK,QAAU,IAAM,IAAA,CAAW,CACvC,EAAC,OAAA,CAAA,SAAM,EAAK,KAAA,CAAY,CAAA,EATnB,EAUF,CACL,EACC,GAEH"}
1
+ {"version":3,"file":"PasswordStrengthInput.mjs","names":[],"sources":["../../../../src/components/controls/password-input/PasswordStrengthInput.tsx"],"sourcesContent":["import { cx } from '@mage-ui/styled-system/css';\nimport {\n passwordStrengthInput,\n passwordStrengthInputBar,\n passwordStrengthInputBarWrapper,\n passwordStrengthInputInput,\n passwordStrengthInputInputButtonIcon,\n passwordStrengthInputInputButtonIconIcon,\n passwordStrengthInputInputButtonIconIconRaw,\n passwordStrengthInputInputButtonIconIconRawRoot,\n passwordStrengthInputInputButtonIconRoot,\n passwordStrengthInputInputDescription,\n passwordStrengthInputInputError,\n passwordStrengthInputInputInput,\n passwordStrengthInputInputLabel,\n passwordStrengthInputInputRequired,\n passwordStrengthInputInputRoot,\n passwordStrengthInputInputSection,\n passwordStrengthInputInputWrapper,\n passwordStrengthInputRoot,\n passwordStrengthInputRule,\n passwordStrengthInputRuleIcon,\n passwordStrengthInputRuleIconIconRaw,\n passwordStrengthInputRuleIconIconRawRoot,\n passwordStrengthInputRuleIconRoot,\n passwordStrengthInputRules,\n passwordStrengthInputRuleText,\n passwordStrengthInputSegment,\n passwordStrengthInputStrengthLabel,\n passwordStrengthInputStrengthWrapper,\n} from '@mage-ui/styled-system/recipes';\nimport { Icon, type IconProps } from '@/components/data-display';\n\nimport { PasswordInput, type PasswordInputProps } from './PasswordInput';\n\nexport type PasswordRule = {\n text: string;\n isValid: boolean;\n};\n\nexport type PasswordSegment = {\n minScore: number;\n label: string;\n};\n\nexport type PasswordStrengthInputProps = PasswordInputProps & {\n segments?: PasswordSegment[];\n rules?: PasswordRule[];\n showRules?: boolean;\n showStrengthLabel?: boolean;\n classNames?: {\n passwordStrengthInput?: string;\n root?: string;\n strengthWrapper?: string;\n barWrapper?: string;\n bar?: string;\n segment?: string;\n strengthLabel?: string;\n rules?: string;\n rule?: string;\n ruleIcon?: IconProps['classNames'];\n ruleText?: string;\n passwordInput?: PasswordInputProps['classNames'];\n };\n};\n\nexport const PasswordStrengthInput = ({\n segments = [],\n rules = [],\n showRules = true,\n showStrengthLabel = true,\n classNames,\n ...props\n}: PasswordStrengthInputProps) => {\n const sortedSegments = [...segments].sort((a, b) => a.minScore - b.minScore);\n const segmentCount = sortedSegments.length;\n\n const validCount = rules.filter((rule) => rule.isValid).length;\n const scorePercent = rules.length > 0 ? (validCount / rules.length) * 100 : 0;\n\n const hasRulesDisplay = showRules && rules.length > 0;\n\n const hasValue = props.value && String(props.value).length > 0;\n\n const currentSegment = [...sortedSegments]\n .reverse()\n .find((segment) => scorePercent >= segment.minScore);\n const currentLabel = hasValue ? (currentSegment?.label ?? '') : '';\n\n const getSegmentColor = (index: number) => {\n if (!hasValue) {\n return 'var(--password-strength-input-segment-background)';\n }\n\n const segment = sortedSegments[index];\n\n if (scorePercent >= segment.minScore) {\n const ratio = segmentCount > 1 ? index / (segmentCount - 1) : 1;\n\n return `hsl(\n calc(\n var(--password-strength-input-segment-hue-start) +\n ${ratio} *\n (var(--password-strength-input-segment-hue-end) -\n var(--password-strength-input-segment-hue-start))\n ),\n var(--password-strength-input-segment-saturation),\n var(--password-strength-input-segment-lightness)\n )`;\n }\n\n return 'var(--password-strength-input-segment-background)';\n };\n\n // const getSegmentColor = (index: number) => {\n // if (!hasValue) {\n // return 'var(--password-strength-input-segment-background)';\n // }\n\n // const segment = sortedSegments[index];\n\n // if (scorePercent >= segment.minScore) {\n // const ratio =\n // segmentCount > 1 ? index / (segmentCount - 1) : 1;\n\n // const percentage = Math.round(ratio * 100);\n\n // return `color-mix(\n // in oklch,\n // var(--password-strength-input-segment-color-start) ${100 - percentage}%,\n // var(--password-strength-input-segment-color-end) ${percentage}%\n // )`;\n // }\n\n // return 'var(--password-strength-input-segment-background)';\n // };\n\n return (\n <div\n className={cx(\n classNames?.passwordStrengthInput ?? passwordStrengthInput(),\n classNames?.root ?? passwordStrengthInputRoot(),\n )}\n data-scope='passwordStrengthInput'\n data-rules={hasRulesDisplay}\n >\n <PasswordInput\n classNames={{\n passwordInput:\n classNames?.passwordInput ?? passwordStrengthInputInput(),\n root:\n classNames?.passwordInput?.root ?? passwordStrengthInputInputRoot(),\n label:\n classNames?.passwordInput?.label ??\n passwordStrengthInputInputLabel(),\n description:\n classNames?.passwordInput?.description ??\n passwordStrengthInputInputDescription(),\n error:\n classNames?.passwordInput?.error ??\n passwordStrengthInputInputError(),\n wrapper:\n classNames?.passwordInput?.wrapper ??\n passwordStrengthInputInputWrapper(),\n required:\n classNames?.passwordInput?.required ??\n passwordStrengthInputInputRequired(),\n input:\n classNames?.passwordInput?.input ??\n passwordStrengthInputInputInput(),\n section:\n classNames?.passwordInput?.section ??\n passwordStrengthInputInputSection(),\n buttonIcon: {\n buttonIcon:\n classNames?.passwordInput?.buttonIcon?.buttonIcon ??\n passwordStrengthInputInputButtonIcon(),\n root:\n classNames?.passwordInput?.buttonIcon?.root ??\n passwordStrengthInputInputButtonIconRoot(),\n icon:\n classNames?.passwordInput?.buttonIcon?.icon ??\n passwordStrengthInputInputButtonIconIcon(),\n iconRaw: {\n iconRaw:\n classNames?.passwordInput?.buttonIcon?.iconRaw?.iconRaw ??\n passwordStrengthInputInputButtonIconIconRaw(),\n root:\n classNames?.passwordInput?.buttonIcon?.iconRaw?.root ??\n passwordStrengthInputInputButtonIconIconRawRoot(),\n },\n },\n }}\n {...props}\n />\n <div\n className={cx(\n classNames?.strengthWrapper ?? passwordStrengthInputStrengthWrapper(),\n )}\n >\n <div\n className={cx(\n classNames?.barWrapper ?? passwordStrengthInputBarWrapper(),\n )}\n >\n <div className={cx(classNames?.bar ?? passwordStrengthInputBar())}>\n {sortedSegments.map((_, index) => (\n <div\n key={index}\n style={{\n backgroundColor: getSegmentColor(index),\n }}\n className={cx(\n classNames?.segment ?? passwordStrengthInputSegment(),\n )}\n />\n ))}\n </div>\n {showStrengthLabel && currentLabel && (\n <span\n className={cx(\n classNames?.strengthLabel ??\n passwordStrengthInputStrengthLabel(),\n )}\n >\n {currentLabel}\n </span>\n )}\n </div>\n {hasRulesDisplay && (\n <ul className={cx(classNames?.rules ?? passwordStrengthInputRules())}>\n {rules.map((rule, index) => (\n <li\n key={index}\n className={cx(classNames?.rule ?? passwordStrengthInputRule())}\n data-valid={rule.isValid || undefined}\n >\n <Icon\n path='/icons/sprite-mage.svg'\n name={\n rule.isValid\n ? 'mage-password-input-strength-rule-check'\n : 'mage-password-input-strength-rule-x'\n }\n classNames={{\n icon:\n classNames?.ruleIcon?.icon ??\n passwordStrengthInputRuleIcon(),\n root:\n classNames?.ruleIcon?.root ??\n passwordStrengthInputRuleIconRoot(),\n iconRaw: {\n iconRaw:\n classNames?.ruleIcon?.iconRaw?.iconRaw ??\n passwordStrengthInputRuleIconIconRaw(),\n root:\n classNames?.ruleIcon?.iconRaw?.root ??\n passwordStrengthInputRuleIconIconRawRoot(),\n },\n }}\n />\n <span\n className={cx(\n classNames?.ruleText ?? passwordStrengthInputRuleText(),\n )}\n >\n {rule.text}\n </span>\n </li>\n ))}\n </ul>\n )}\n </div>\n </div>\n );\n};\n"],"mappings":"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"}
@@ -1,4 +1,4 @@
1
- import "./PasswordStrengthInput.mjs";
1
+ import { PasswordRule } from "./PasswordStrengthInput.mjs";
2
2
 
3
3
  //#region src/components/controls/password-input/usePasswordRules.d.ts
4
4
  type PasswordRuleDefinition = {
@@ -6,6 +6,7 @@ type PasswordRuleDefinition = {
6
6
  text: string;
7
7
  validate: (value: string) => boolean;
8
8
  };
9
+ declare const usePasswordRules: (value: string, definitions: PasswordRuleDefinition[], t?: (key: string, bindings?: Record<string, string>, fallback?: string) => string) => PasswordRule[];
9
10
  //#endregion
10
- export { PasswordRuleDefinition };
11
+ export { PasswordRuleDefinition, usePasswordRules };
11
12
  //# sourceMappingURL=usePasswordRules.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"usePasswordRules.d.mts","names":[],"sources":["../../../../src/components/controls/password-input/usePasswordRules.ts"],"mappings":";;;KAIY,sBAAA;EACV,GAAA;EACA,IAAA;EACA,QAAA,GAAW,KAAA;AAAA"}
1
+ {"version":3,"file":"usePasswordRules.d.mts","names":[],"sources":["../../../../src/components/controls/password-input/usePasswordRules.ts"],"mappings":";;;KAIY,sBAAA;EACV,GAAA;EACA,IAAA;EACA,QAAA,GAAW,KAAA;AAAA;AAAA,cAGA,gBAAA,GACX,KAAA,UACA,WAAA,EAAa,sBAAA,IACb,CAAA,IACE,GAAA,UACA,QAAA,GAAW,MAAA,kBACX,QAAA,yBAED,YAAA"}
@@ -1,5 +1,5 @@
1
1
  import { PasswordInputProps } from "../password-input/PasswordInput.mjs";
2
- import * as react_jsx_runtime33 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime35 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/controls/password-input-strength/oldPasswordInputStrength.d.ts
5
5
  type PasswordInputStrengthProps = Omit<PasswordInputProps, 'classNames'> & {
@@ -37,7 +37,7 @@ declare const PasswordInputStrength: ({
37
37
  weakPasswordText,
38
38
  mediumPasswordText,
39
39
  strongPasswordText
40
- }: PasswordInputStrengthProps) => react_jsx_runtime33.JSX.Element;
40
+ }: PasswordInputStrengthProps) => react_jsx_runtime35.JSX.Element;
41
41
  //#endregion
42
42
  export { PasswordInputStrength, PasswordInputStrengthProps };
43
43
  //# sourceMappingURL=oldPasswordInputStrength.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { DropdownProps } from "../dropdown/Dropdown.mjs";
2
- import * as react_jsx_runtime34 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime36 from "react/jsx-runtime";
3
3
  import { ReactNode } from "react";
4
4
 
5
5
  //#region src/components/controls/select/Select.d.ts
@@ -32,7 +32,7 @@ declare const Select: ({
32
32
  emptyMessage,
33
33
  btnClearLabel,
34
34
  classNames
35
- }: SelectProps) => react_jsx_runtime34.JSX.Element;
35
+ }: SelectProps) => react_jsx_runtime36.JSX.Element;
36
36
  //#endregion
37
37
  export { Select, SelectProps };
38
38
  //# sourceMappingURL=Select.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime35 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime37 from "react/jsx-runtime";
2
2
  import { ComponentProps, ReactNode } from "react";
3
3
 
4
4
  //#region src/components/controls/text-input/TextInput.d.ts
@@ -26,7 +26,7 @@ declare const TextInput: ({
26
26
  startSlot,
27
27
  endSlot,
28
28
  ...props
29
- }: TextInputProps) => react_jsx_runtime35.JSX.Element;
29
+ }: TextInputProps) => react_jsx_runtime37.JSX.Element;
30
30
  //#endregion
31
31
  export { TextInput, TextInputProps };
32
32
  //# sourceMappingURL=TextInput.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime36 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime38 from "react/jsx-runtime";
2
2
  import { ComponentProps, ReactNode } from "react";
3
3
 
4
4
  //#region src/components/controls/textarea/Textarea.d.ts
@@ -41,7 +41,7 @@ declare const Textarea: ({
41
41
  autosize,
42
42
  minRows,
43
43
  maxRows
44
- }: TextareaProps) => react_jsx_runtime36.JSX.Element;
44
+ }: TextareaProps) => react_jsx_runtime38.JSX.Element;
45
45
  //#endregion
46
46
  export { Textarea, TextareaProps };
47
47
  //# sourceMappingURL=Textarea.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime64 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime67 from "react/jsx-runtime";
2
2
 
3
3
  //#region src/components/controls/utils/chevron/Chevron.d.ts
4
4
  type ChevronProps = {
@@ -21,7 +21,7 @@ declare const Chevron: ({
21
21
  chevronOpen,
22
22
  chevronClose,
23
23
  classNames
24
- }: ChevronProps) => react_jsx_runtime64.JSX.Element;
24
+ }: ChevronProps) => react_jsx_runtime67.JSX.Element;
25
25
  //#endregion
26
26
  export { Chevron, ChevronProps };
27
27
  //# sourceMappingURL=Chevron.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime63 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime66 from "react/jsx-runtime";
2
2
 
3
3
  //#region src/components/controls/utils/clear-button/ClearButton.d.ts
4
4
  type ClearButtonProps = {
@@ -20,7 +20,7 @@ declare const ClearButton: ({
20
20
  onClick,
21
21
  name,
22
22
  classNames
23
- }: ClearButtonProps) => react_jsx_runtime63.JSX.Element;
23
+ }: ClearButtonProps) => react_jsx_runtime66.JSX.Element;
24
24
  //#endregion
25
25
  export { ClearButton, ClearButtonProps };
26
26
  //# sourceMappingURL=ClearButton.d.mts.map
@@ -1,7 +1,7 @@
1
1
  import { AvatarProps } from "../avatar/Avatar.mjs";
2
2
  import { RemovableItemProps } from "../removable-item/RemovableItem.mjs";
3
3
  import "../index.mjs";
4
- import * as react_jsx_runtime37 from "react/jsx-runtime";
4
+ import * as react_jsx_runtime45 from "react/jsx-runtime";
5
5
  import { ReactNode } from "react";
6
6
 
7
7
  //#region src/components/data-display/assigned-user/AssignedUser.d.ts
@@ -31,7 +31,7 @@ declare const AssignedUser: ({
31
31
  removeButtonLabel,
32
32
  children,
33
33
  classNames
34
- }: AssignedUserProps) => react_jsx_runtime37.JSX.Element;
34
+ }: AssignedUserProps) => react_jsx_runtime45.JSX.Element;
35
35
  //#endregion
36
36
  export { AssignedUser, AssignedUserProps };
37
37
  //# sourceMappingURL=AssignedUser.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { AvatarVariantProps } from "@mage-ui/styled-system/recipes";
2
- import * as react_jsx_runtime38 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime46 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/components/data-display/avatar/Avatar.d.ts
5
5
  type AvatarProps = {
@@ -18,7 +18,7 @@ declare const Avatar: ({
18
18
  name,
19
19
  src,
20
20
  alt
21
- }: AvatarProps) => react_jsx_runtime38.JSX.Element;
21
+ }: AvatarProps) => react_jsx_runtime46.JSX.Element;
22
22
  //#endregion
23
23
  export { Avatar, AvatarProps };
24
24
  //# sourceMappingURL=Avatar.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime39 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime47 from "react/jsx-runtime";
2
2
  import React from "react";
3
3
 
4
4
  //#region src/components/data-display/badge/Badge.d.ts
@@ -18,7 +18,7 @@ declare const Badge: ({
18
18
  endSlot,
19
19
  startSlot,
20
20
  classNames
21
- }: BadgeProps) => react_jsx_runtime39.JSX.Element;
21
+ }: BadgeProps) => react_jsx_runtime47.JSX.Element;
22
22
  //#endregion
23
23
  export { Badge, BadgeProps };
24
24
  //# sourceMappingURL=Badge.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime40 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime48 from "react/jsx-runtime";
2
2
  import { CSSProperties } from "react";
3
3
  import { DateLocalizer, DateLocalizer as DateLocalizer$1, Event, Event as CalendarEvent, momentLocalizer } from "react-big-calendar";
4
4
 
@@ -60,7 +60,7 @@ declare const Calendar$1: ({
60
60
  messages,
61
61
  popup,
62
62
  components
63
- }: CalendarProps) => react_jsx_runtime40.JSX.Element;
63
+ }: CalendarProps) => react_jsx_runtime48.JSX.Element;
64
64
  //#endregion
65
65
  export { Calendar$1 as Calendar, type CalendarEvent, CalendarProps, type DateLocalizer$1 as DateLocalizer, momentLocalizer };
66
66
  //# sourceMappingURL=Calendar.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime41 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime49 from "react/jsx-runtime";
2
2
 
3
3
  //#region src/components/data-display/loader-dot/LoaderDot.d.ts
4
4
  type LoaderDotProps = {
@@ -9,7 +9,7 @@ type LoaderDotProps = {
9
9
  };
10
10
  declare const LoaderDot: ({
11
11
  classNames
12
- }: LoaderDotProps) => react_jsx_runtime41.JSX.Element;
12
+ }: LoaderDotProps) => react_jsx_runtime49.JSX.Element;
13
13
  //#endregion
14
14
  export { LoaderDot, LoaderDotProps };
15
15
  //# sourceMappingURL=LoaderDot.d.mts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime42 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime50 from "react/jsx-runtime";
2
2
 
3
3
  //#region src/components/data-display/loader-oval/LoaderOval.d.ts
4
4
  type LoaderOvalProps = {
@@ -9,7 +9,7 @@ type LoaderOvalProps = {
9
9
  };
10
10
  declare const LoaderOval: ({
11
11
  classNames
12
- }: LoaderOvalProps) => react_jsx_runtime42.JSX.Element;
12
+ }: LoaderOvalProps) => react_jsx_runtime50.JSX.Element;
13
13
  //#endregion
14
14
  export { LoaderOval, LoaderOvalProps };
15
15
  //# sourceMappingURL=LoaderOval.d.mts.map
@@ -1,6 +1,6 @@
1
1
  import { ButtonIconProps } from "../../buttons/button-icon/ButtonIcon.mjs";
2
2
  import "../../buttons/index.mjs";
3
- import * as react_jsx_runtime43 from "react/jsx-runtime";
3
+ import * as react_jsx_runtime51 from "react/jsx-runtime";
4
4
  import { ReactNode } from "react";
5
5
 
6
6
  //#region src/components/data-display/removable-item/RemovableItem.d.ts
@@ -23,7 +23,7 @@ declare const RemovableItem: ({
23
23
  onRemove,
24
24
  removeButtonLabel,
25
25
  classNames
26
- }: RemovableItemProps) => react_jsx_runtime43.JSX.Element;
26
+ }: RemovableItemProps) => react_jsx_runtime51.JSX.Element;
27
27
  //#endregion
28
28
  export { RemovableItem, RemovableItemProps };
29
29
  //# sourceMappingURL=RemovableItem.d.mts.map