@octoguide/mui-ui-toolkit 0.7.4 → 0.7.6

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.d.mts CHANGED
@@ -461,6 +461,37 @@ declare namespace Button {
461
461
  var displayName: string;
462
462
  }
463
463
 
464
+ interface ConfirmDialogProps {
465
+ /** Whether the dialog is open */
466
+ open: boolean;
467
+ /** Dialog heading */
468
+ title: string;
469
+ /** Supporting text below the title */
470
+ description?: React.ReactNode;
471
+ /** Label for the confirm button — defaults to "Confirm" */
472
+ confirmLabel?: string;
473
+ /** Label for the cancel button — defaults to "Cancel" */
474
+ cancelLabel?: string;
475
+ /**
476
+ * Controls the confirm button colour.
477
+ * - `danger` → error (red)
478
+ * - `warning` → warning (amber)
479
+ */
480
+ severity?: 'warning' | 'danger';
481
+ /** Shows a loading spinner on the confirm button and disables both buttons */
482
+ loading?: boolean;
483
+ /** Callback fired when the user confirms */
484
+ onConfirm: () => void;
485
+ /** Callback fired when the user cancels or closes the dialog */
486
+ onClose: () => void;
487
+ /** High-contrast mode for use on dark backgrounds */
488
+ isOnDarkBg?: boolean;
489
+ }
490
+ declare function ConfirmDialog({ open, title, description, confirmLabel, cancelLabel, severity, loading, onConfirm, onClose, isOnDarkBg, }: ConfirmDialogProps): react_jsx_runtime.JSX.Element;
491
+ declare namespace ConfirmDialog {
492
+ var displayName: string;
493
+ }
494
+
464
495
  type ChipProps = ChipProps$1;
465
496
  /**
466
497
  * Chip component extending MUI Chip.
@@ -814,6 +845,45 @@ interface LogoLinkProps extends Omit<React.AnchorHTMLAttributes<HTMLAnchorElemen
814
845
  }
815
846
  declare const LogoLink: React.ForwardRefExoticComponent<LogoLinkProps & React.RefAttributes<HTMLAnchorElement>>;
816
847
 
848
+ interface MultiSelectOption {
849
+ value: string;
850
+ label: string | React.ReactNode;
851
+ }
852
+ interface MultiSelectProps {
853
+ options: MultiSelectOption[];
854
+ onChange?: (selectedOptions: MultiSelectOption[]) => void;
855
+ placeholder: {
856
+ singular: string;
857
+ plural: string;
858
+ };
859
+ preSelectedOptions?: Array<{
860
+ value: string;
861
+ label?: string | React.ReactNode;
862
+ }>;
863
+ renderOption: (option: any, currentOptionIndex: number, handleSelectOption: (event: React.SyntheticEvent, option: any) => void, checked: boolean, inputId: string) => React.ReactNode;
864
+ label?: string;
865
+ inputId: string;
866
+ hasError?: boolean;
867
+ hasDescription?: boolean;
868
+ hasSelectAll?: boolean;
869
+ hasTooltip?: boolean;
870
+ required?: boolean;
871
+ selectButtonRef?: React.Ref<any>;
872
+ onBlur?: (e: React.FocusEvent<any>) => void;
873
+ onFocus?: (e: React.FocusEvent<any>) => void;
874
+ onKeyUp?: (e: React.KeyboardEvent<any>) => void;
875
+ onKeyDown?: (e: React.KeyboardEvent<any>) => void;
876
+ onClick?: (e: React.MouseEvent<any>) => void;
877
+ onTouchStart?: (e: React.TouchEvent<any>) => void;
878
+ onTouchEnd?: (e: React.TouchEvent<any>) => void;
879
+ className?: string;
880
+ id?: string;
881
+ }
882
+ declare const MultiSelect: {
883
+ ({ options: initialOptions, placeholder, preSelectedOptions, renderOption, onChange, label, inputId, hasError, hasDescription, hasSelectAll, hasTooltip, required, selectButtonRef: providedRef, onBlur, onFocus, onClick, onKeyUp, onKeyDown, onTouchStart, onTouchEnd, ...restProps }: MultiSelectProps): react_jsx_runtime.JSX.Element;
884
+ displayName: string;
885
+ };
886
+
817
887
  interface PageSpinnerProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'role'> {
818
888
  /** Loading message shown below the spinner */
819
889
  message?: string;
@@ -1016,4 +1086,4 @@ interface TypographyButtonProps extends Omit<TypographyProps, 'variant'> {
1016
1086
  }
1017
1087
  declare const TypographyButton: React.ForwardRefExoticComponent<Omit<TypographyButtonProps, "ref"> & React.RefAttributes<HTMLElement>>;
1018
1088
 
1019
- export { ABNInput, type ABNInputProps, Accordion, AccordionDetails, type AccordionDetailsProps, type AccordionProps, AccordionSummary, type AccordionSummaryProps, Alert, type AlertProps, AlertTitle, type AlertTitleProps, Avatar, type AvatarProps, type AvatarSize, Body1, type Body1Props, Body2, type Body2Props, type BorderRadiusTokens, Button, type ButtonProps, Caption, type CaptionProps, Card, CardActions, CardContent, CardHeader, type CardProps, Chip, type ChipProps, type ColorTokens, type ComponentTokens, DateCalendar, type DateCalendarProps, DateField, type DateFieldProps, DateLocalizationProvider, type DateLocalizationProviderProps, DatePicker, type DatePickerProps, DateRangePickerCalendar, type DateRangePickerCalendarProps, DateRangePickerInput, type DateRangePickerInputProps, type DateRangeValue, DateTimeField, type DateTimeFieldProps, DateTimePicker, type DateTimePickerProps, DesktopDatePicker, type DesktopDatePickerProps, DesktopDateTimePicker, type DesktopDateTimePickerProps, DesktopTimePicker, type DesktopTimePickerProps, Grid, type GridProps, H1, type H1Props, H2, type H2Props, H3, type H3Props, H4, type H4Props, H5, type H5Props, H6, type H6Props, IconText, type IconTextProps, type IconTextSymbol, InternalLinkItem, type InternalLinkItemProps, Link, type LinkProps, LogoLink, type LogoLinkProps, MobileDatePicker, type MobileDatePickerProps, MobileDateTimePicker, type MobileDateTimePickerProps, MobileTimePicker, type MobileTimePickerProps, Overline, type OverlineProps, PageSpinner, type PageSpinnerProps, Pagination, type PaginationColor, type PaginationProps, type PaginationShape, type PaginationVariant, Paragraph, type ParagraphProps, Password, PasswordCriteria, type PasswordCriteriaProps, type PasswordProps, PasswordRule, type PasswordRuleProps, PasswordRules, type ShadowTokens, type SpacingTokens, Spinner, type SpinnerProps, type SpinnerSize, StandaloneAccordion, StaticDatePicker, type StaticDatePickerProps, StaticDateTimePicker, type StaticDateTimePickerProps, StaticTimePicker, type StaticTimePickerProps, Subtitle1, type Subtitle1Props, Subtitle2, type Subtitle2Props, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableContainer, type TableContainerProps, TableHead, TableHeadCell, type TableHeadProps, TablePagination, type TableProps, TableRow, type TableRowProps, TableSortLabel, TextField, type TextFieldProps, type ThemeName, type ThemeTokens, TimeField, type TimeFieldProps, TimePicker, type TimePickerProps, Toggle, ToggleButton, ToggleButtonGroup, type ToggleButtonGroupProps, type ToggleButtonProps, type ToggleProps, ToolkitThemeProvider, type TransitionTokens, TypographyButton, type TypographyButtonProps, type TypographyTokens, Variant, type ZIndexTokens, createMuiTheme, getThemeTokens, passwordValidator, resolveThemeName, themeRegistry };
1089
+ export { ABNInput, type ABNInputProps, Accordion, AccordionDetails, type AccordionDetailsProps, type AccordionProps, AccordionSummary, type AccordionSummaryProps, Alert, type AlertProps, AlertTitle, type AlertTitleProps, Avatar, type AvatarProps, type AvatarSize, Body1, type Body1Props, Body2, type Body2Props, type BorderRadiusTokens, Button, type ButtonProps, Caption, type CaptionProps, Card, CardActions, CardContent, CardHeader, type CardProps, Chip, type ChipProps, type ColorTokens, type ComponentTokens, ConfirmDialog, type ConfirmDialogProps, DateCalendar, type DateCalendarProps, DateField, type DateFieldProps, DateLocalizationProvider, type DateLocalizationProviderProps, DatePicker, type DatePickerProps, DateRangePickerCalendar, type DateRangePickerCalendarProps, DateRangePickerInput, type DateRangePickerInputProps, type DateRangeValue, DateTimeField, type DateTimeFieldProps, DateTimePicker, type DateTimePickerProps, DesktopDatePicker, type DesktopDatePickerProps, DesktopDateTimePicker, type DesktopDateTimePickerProps, DesktopTimePicker, type DesktopTimePickerProps, Grid, type GridProps, H1, type H1Props, H2, type H2Props, H3, type H3Props, H4, type H4Props, H5, type H5Props, H6, type H6Props, IconText, type IconTextProps, type IconTextSymbol, InternalLinkItem, type InternalLinkItemProps, Link, type LinkProps, LogoLink, type LogoLinkProps, MobileDatePicker, type MobileDatePickerProps, MobileDateTimePicker, type MobileDateTimePickerProps, MobileTimePicker, type MobileTimePickerProps, MultiSelect, type MultiSelectOption, type MultiSelectProps, Overline, type OverlineProps, PageSpinner, type PageSpinnerProps, Pagination, type PaginationColor, type PaginationProps, type PaginationShape, type PaginationVariant, Paragraph, type ParagraphProps, Password, PasswordCriteria, type PasswordCriteriaProps, type PasswordProps, PasswordRule, type PasswordRuleProps, PasswordRules, type ShadowTokens, type SpacingTokens, Spinner, type SpinnerProps, type SpinnerSize, StandaloneAccordion, StaticDatePicker, type StaticDatePickerProps, StaticDateTimePicker, type StaticDateTimePickerProps, StaticTimePicker, type StaticTimePickerProps, Subtitle1, type Subtitle1Props, Subtitle2, type Subtitle2Props, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableContainer, type TableContainerProps, TableHead, TableHeadCell, type TableHeadProps, TablePagination, type TableProps, TableRow, type TableRowProps, TableSortLabel, TextField, type TextFieldProps, type ThemeName, type ThemeTokens, TimeField, type TimeFieldProps, TimePicker, type TimePickerProps, Toggle, ToggleButton, ToggleButtonGroup, type ToggleButtonGroupProps, type ToggleButtonProps, type ToggleProps, ToolkitThemeProvider, type TransitionTokens, TypographyButton, type TypographyButtonProps, type TypographyTokens, Variant, type ZIndexTokens, createMuiTheme, getThemeTokens, passwordValidator, resolveThemeName, themeRegistry };
package/dist/index.d.ts CHANGED
@@ -461,6 +461,37 @@ declare namespace Button {
461
461
  var displayName: string;
462
462
  }
463
463
 
464
+ interface ConfirmDialogProps {
465
+ /** Whether the dialog is open */
466
+ open: boolean;
467
+ /** Dialog heading */
468
+ title: string;
469
+ /** Supporting text below the title */
470
+ description?: React.ReactNode;
471
+ /** Label for the confirm button — defaults to "Confirm" */
472
+ confirmLabel?: string;
473
+ /** Label for the cancel button — defaults to "Cancel" */
474
+ cancelLabel?: string;
475
+ /**
476
+ * Controls the confirm button colour.
477
+ * - `danger` → error (red)
478
+ * - `warning` → warning (amber)
479
+ */
480
+ severity?: 'warning' | 'danger';
481
+ /** Shows a loading spinner on the confirm button and disables both buttons */
482
+ loading?: boolean;
483
+ /** Callback fired when the user confirms */
484
+ onConfirm: () => void;
485
+ /** Callback fired when the user cancels or closes the dialog */
486
+ onClose: () => void;
487
+ /** High-contrast mode for use on dark backgrounds */
488
+ isOnDarkBg?: boolean;
489
+ }
490
+ declare function ConfirmDialog({ open, title, description, confirmLabel, cancelLabel, severity, loading, onConfirm, onClose, isOnDarkBg, }: ConfirmDialogProps): react_jsx_runtime.JSX.Element;
491
+ declare namespace ConfirmDialog {
492
+ var displayName: string;
493
+ }
494
+
464
495
  type ChipProps = ChipProps$1;
465
496
  /**
466
497
  * Chip component extending MUI Chip.
@@ -814,6 +845,45 @@ interface LogoLinkProps extends Omit<React.AnchorHTMLAttributes<HTMLAnchorElemen
814
845
  }
815
846
  declare const LogoLink: React.ForwardRefExoticComponent<LogoLinkProps & React.RefAttributes<HTMLAnchorElement>>;
816
847
 
848
+ interface MultiSelectOption {
849
+ value: string;
850
+ label: string | React.ReactNode;
851
+ }
852
+ interface MultiSelectProps {
853
+ options: MultiSelectOption[];
854
+ onChange?: (selectedOptions: MultiSelectOption[]) => void;
855
+ placeholder: {
856
+ singular: string;
857
+ plural: string;
858
+ };
859
+ preSelectedOptions?: Array<{
860
+ value: string;
861
+ label?: string | React.ReactNode;
862
+ }>;
863
+ renderOption: (option: any, currentOptionIndex: number, handleSelectOption: (event: React.SyntheticEvent, option: any) => void, checked: boolean, inputId: string) => React.ReactNode;
864
+ label?: string;
865
+ inputId: string;
866
+ hasError?: boolean;
867
+ hasDescription?: boolean;
868
+ hasSelectAll?: boolean;
869
+ hasTooltip?: boolean;
870
+ required?: boolean;
871
+ selectButtonRef?: React.Ref<any>;
872
+ onBlur?: (e: React.FocusEvent<any>) => void;
873
+ onFocus?: (e: React.FocusEvent<any>) => void;
874
+ onKeyUp?: (e: React.KeyboardEvent<any>) => void;
875
+ onKeyDown?: (e: React.KeyboardEvent<any>) => void;
876
+ onClick?: (e: React.MouseEvent<any>) => void;
877
+ onTouchStart?: (e: React.TouchEvent<any>) => void;
878
+ onTouchEnd?: (e: React.TouchEvent<any>) => void;
879
+ className?: string;
880
+ id?: string;
881
+ }
882
+ declare const MultiSelect: {
883
+ ({ options: initialOptions, placeholder, preSelectedOptions, renderOption, onChange, label, inputId, hasError, hasDescription, hasSelectAll, hasTooltip, required, selectButtonRef: providedRef, onBlur, onFocus, onClick, onKeyUp, onKeyDown, onTouchStart, onTouchEnd, ...restProps }: MultiSelectProps): react_jsx_runtime.JSX.Element;
884
+ displayName: string;
885
+ };
886
+
817
887
  interface PageSpinnerProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'role'> {
818
888
  /** Loading message shown below the spinner */
819
889
  message?: string;
@@ -1016,4 +1086,4 @@ interface TypographyButtonProps extends Omit<TypographyProps, 'variant'> {
1016
1086
  }
1017
1087
  declare const TypographyButton: React.ForwardRefExoticComponent<Omit<TypographyButtonProps, "ref"> & React.RefAttributes<HTMLElement>>;
1018
1088
 
1019
- export { ABNInput, type ABNInputProps, Accordion, AccordionDetails, type AccordionDetailsProps, type AccordionProps, AccordionSummary, type AccordionSummaryProps, Alert, type AlertProps, AlertTitle, type AlertTitleProps, Avatar, type AvatarProps, type AvatarSize, Body1, type Body1Props, Body2, type Body2Props, type BorderRadiusTokens, Button, type ButtonProps, Caption, type CaptionProps, Card, CardActions, CardContent, CardHeader, type CardProps, Chip, type ChipProps, type ColorTokens, type ComponentTokens, DateCalendar, type DateCalendarProps, DateField, type DateFieldProps, DateLocalizationProvider, type DateLocalizationProviderProps, DatePicker, type DatePickerProps, DateRangePickerCalendar, type DateRangePickerCalendarProps, DateRangePickerInput, type DateRangePickerInputProps, type DateRangeValue, DateTimeField, type DateTimeFieldProps, DateTimePicker, type DateTimePickerProps, DesktopDatePicker, type DesktopDatePickerProps, DesktopDateTimePicker, type DesktopDateTimePickerProps, DesktopTimePicker, type DesktopTimePickerProps, Grid, type GridProps, H1, type H1Props, H2, type H2Props, H3, type H3Props, H4, type H4Props, H5, type H5Props, H6, type H6Props, IconText, type IconTextProps, type IconTextSymbol, InternalLinkItem, type InternalLinkItemProps, Link, type LinkProps, LogoLink, type LogoLinkProps, MobileDatePicker, type MobileDatePickerProps, MobileDateTimePicker, type MobileDateTimePickerProps, MobileTimePicker, type MobileTimePickerProps, Overline, type OverlineProps, PageSpinner, type PageSpinnerProps, Pagination, type PaginationColor, type PaginationProps, type PaginationShape, type PaginationVariant, Paragraph, type ParagraphProps, Password, PasswordCriteria, type PasswordCriteriaProps, type PasswordProps, PasswordRule, type PasswordRuleProps, PasswordRules, type ShadowTokens, type SpacingTokens, Spinner, type SpinnerProps, type SpinnerSize, StandaloneAccordion, StaticDatePicker, type StaticDatePickerProps, StaticDateTimePicker, type StaticDateTimePickerProps, StaticTimePicker, type StaticTimePickerProps, Subtitle1, type Subtitle1Props, Subtitle2, type Subtitle2Props, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableContainer, type TableContainerProps, TableHead, TableHeadCell, type TableHeadProps, TablePagination, type TableProps, TableRow, type TableRowProps, TableSortLabel, TextField, type TextFieldProps, type ThemeName, type ThemeTokens, TimeField, type TimeFieldProps, TimePicker, type TimePickerProps, Toggle, ToggleButton, ToggleButtonGroup, type ToggleButtonGroupProps, type ToggleButtonProps, type ToggleProps, ToolkitThemeProvider, type TransitionTokens, TypographyButton, type TypographyButtonProps, type TypographyTokens, Variant, type ZIndexTokens, createMuiTheme, getThemeTokens, passwordValidator, resolveThemeName, themeRegistry };
1089
+ export { ABNInput, type ABNInputProps, Accordion, AccordionDetails, type AccordionDetailsProps, type AccordionProps, AccordionSummary, type AccordionSummaryProps, Alert, type AlertProps, AlertTitle, type AlertTitleProps, Avatar, type AvatarProps, type AvatarSize, Body1, type Body1Props, Body2, type Body2Props, type BorderRadiusTokens, Button, type ButtonProps, Caption, type CaptionProps, Card, CardActions, CardContent, CardHeader, type CardProps, Chip, type ChipProps, type ColorTokens, type ComponentTokens, ConfirmDialog, type ConfirmDialogProps, DateCalendar, type DateCalendarProps, DateField, type DateFieldProps, DateLocalizationProvider, type DateLocalizationProviderProps, DatePicker, type DatePickerProps, DateRangePickerCalendar, type DateRangePickerCalendarProps, DateRangePickerInput, type DateRangePickerInputProps, type DateRangeValue, DateTimeField, type DateTimeFieldProps, DateTimePicker, type DateTimePickerProps, DesktopDatePicker, type DesktopDatePickerProps, DesktopDateTimePicker, type DesktopDateTimePickerProps, DesktopTimePicker, type DesktopTimePickerProps, Grid, type GridProps, H1, type H1Props, H2, type H2Props, H3, type H3Props, H4, type H4Props, H5, type H5Props, H6, type H6Props, IconText, type IconTextProps, type IconTextSymbol, InternalLinkItem, type InternalLinkItemProps, Link, type LinkProps, LogoLink, type LogoLinkProps, MobileDatePicker, type MobileDatePickerProps, MobileDateTimePicker, type MobileDateTimePickerProps, MobileTimePicker, type MobileTimePickerProps, MultiSelect, type MultiSelectOption, type MultiSelectProps, Overline, type OverlineProps, PageSpinner, type PageSpinnerProps, Pagination, type PaginationColor, type PaginationProps, type PaginationShape, type PaginationVariant, Paragraph, type ParagraphProps, Password, PasswordCriteria, type PasswordCriteriaProps, type PasswordProps, PasswordRule, type PasswordRuleProps, PasswordRules, type ShadowTokens, type SpacingTokens, Spinner, type SpinnerProps, type SpinnerSize, StandaloneAccordion, StaticDatePicker, type StaticDatePickerProps, StaticDateTimePicker, type StaticDateTimePickerProps, StaticTimePicker, type StaticTimePickerProps, Subtitle1, type Subtitle1Props, Subtitle2, type Subtitle2Props, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableContainer, type TableContainerProps, TableHead, TableHeadCell, type TableHeadProps, TablePagination, type TableProps, TableRow, type TableRowProps, TableSortLabel, TextField, type TextFieldProps, type ThemeName, type ThemeTokens, TimeField, type TimeFieldProps, TimePicker, type TimePickerProps, Toggle, ToggleButton, ToggleButtonGroup, type ToggleButtonGroupProps, type ToggleButtonProps, type ToggleProps, ToolkitThemeProvider, type TransitionTokens, TypographyButton, type TypographyButtonProps, type TypographyTokens, Variant, type ZIndexTokens, createMuiTheme, getThemeTokens, passwordValidator, resolveThemeName, themeRegistry };