@undefine-ui/design-system 3.5.1 → 3.6.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.
package/dist/index.d.cts CHANGED
@@ -16,10 +16,11 @@ import { PopoverProps } from '@mui/material/Popover';
16
16
  import { ButtonBaseProps } from '@mui/material/ButtonBase';
17
17
  import { InputBaseProps } from '@mui/material/InputBase';
18
18
  import { FieldValues, UseFormReturn, SubmitHandler } from 'react-hook-form';
19
+ import { TextFieldProps } from '@mui/material/TextField';
20
+ import { AutocompleteProps } from '@mui/material/Autocomplete';
19
21
  import { DatePickerProps as DatePickerProps$1 } from '@mui/x-date-pickers/DatePicker';
20
22
  import { TimePickerProps as TimePickerProps$1 } from '@mui/x-date-pickers/TimePicker';
21
23
  import { DateTimePickerProps as DateTimePickerProps$1 } from '@mui/x-date-pickers/DateTimePicker';
22
- import { AutocompleteProps } from '@mui/material/Autocomplete';
23
24
  import { CheckboxProps } from '@mui/material/Checkbox';
24
25
  import { FormGroupProps } from '@mui/material/FormGroup';
25
26
  import { FormLabelProps } from '@mui/material/FormLabel';
@@ -28,7 +29,6 @@ import { FormHelperTextProps } from '@mui/material/FormHelperText';
28
29
  import { FormControlLabelProps } from '@mui/material/FormControlLabel';
29
30
  import { RadioProps } from '@mui/material/Radio';
30
31
  import { RadioGroupProps } from '@mui/material/RadioGroup';
31
- import { TextFieldProps } from '@mui/material/TextField';
32
32
  import { SwitchProps } from '@mui/material/Switch';
33
33
  export * from 'sonner';
34
34
 
@@ -1652,6 +1652,158 @@ interface FormProps<T extends FieldValues> extends Omit<BoxProps, 'onSubmit'> {
1652
1652
  }
1653
1653
  declare const Form: <T extends FieldValues>({ children, onSubmit, methods, ...rest }: FormProps<T>) => react_jsx_runtime.JSX.Element;
1654
1654
 
1655
+ interface MainTextMatchedSubstrings {
1656
+ offset: number;
1657
+ length: number;
1658
+ }
1659
+ interface StructuredFormatting {
1660
+ main_text: string;
1661
+ main_text_matched_substrings: readonly MainTextMatchedSubstrings[];
1662
+ secondary_text?: string;
1663
+ }
1664
+ interface PlaceType {
1665
+ description: string;
1666
+ place_id?: string;
1667
+ structured_formatting: StructuredFormatting;
1668
+ }
1669
+ interface GooglePlacesContextValue {
1670
+ apiKey: string;
1671
+ loaded: boolean;
1672
+ error: Error | null;
1673
+ }
1674
+ interface PlaceDetails {
1675
+ placeId: string;
1676
+ description: string;
1677
+ mainText: string;
1678
+ secondaryText?: string;
1679
+ lat?: number;
1680
+ lng?: number;
1681
+ formattedAddress?: string;
1682
+ addressComponents?: any[];
1683
+ }
1684
+
1685
+ interface GooglePlacesProviderProps {
1686
+ apiKey: string;
1687
+ children: React.ReactNode;
1688
+ /**
1689
+ * Additional libraries to load alongside 'places'
1690
+ * @default []
1691
+ */
1692
+ libraries?: string[];
1693
+ }
1694
+ declare const GooglePlacesProvider: ({ apiKey, children, libraries }: GooglePlacesProviderProps) => react_jsx_runtime.JSX.Element;
1695
+ declare const useGooglePlacesContext: () => GooglePlacesContextValue;
1696
+ declare const useGooglePlacesLoaded: () => boolean;
1697
+
1698
+ interface UseGooglePlacesAutocompleteOptions {
1699
+ /**
1700
+ * Debounce delay in milliseconds
1701
+ * @default 300
1702
+ */
1703
+ debounceMs?: number;
1704
+ /**
1705
+ * Types of places to search for
1706
+ * @see https://developers.google.com/maps/documentation/places/web-service/supported_types
1707
+ */
1708
+ types?: string[];
1709
+ /**
1710
+ * Country restrictions (ISO 3166-1 Alpha-2 codes)
1711
+ * @example ['us', 'ca']
1712
+ */
1713
+ componentRestrictions?: {
1714
+ country: string | string[];
1715
+ };
1716
+ /**
1717
+ * Whether to fetch place details when a place is selected
1718
+ * @default false
1719
+ */
1720
+ fetchPlaceDetails?: boolean;
1721
+ /**
1722
+ * Fields to fetch when getting place details
1723
+ * @default ['geometry', 'formatted_address', 'address_components']
1724
+ */
1725
+ placeDetailsFields?: string[];
1726
+ }
1727
+ interface UseGooglePlacesAutocompleteReturn {
1728
+ /** Current input value */
1729
+ inputValue: string;
1730
+ /** Set input value */
1731
+ setInputValue: (value: string) => void;
1732
+ /** Selected place */
1733
+ value: PlaceType | null;
1734
+ /** Set selected place */
1735
+ setValue: (value: PlaceType | null) => void;
1736
+ /** Autocomplete options */
1737
+ options: readonly PlaceType[];
1738
+ /** Whether the API is loaded */
1739
+ loaded: boolean;
1740
+ /** Loading state for fetching suggestions */
1741
+ loading: boolean;
1742
+ /** Error state */
1743
+ error: Error | null;
1744
+ /** Get place details for a selected place */
1745
+ getPlaceDetails: (placeId: string) => Promise<PlaceDetails | null>;
1746
+ /** Clear the selection */
1747
+ clear: () => void;
1748
+ }
1749
+ declare const useGooglePlacesAutocomplete: (options?: UseGooglePlacesAutocompleteOptions) => UseGooglePlacesAutocompleteReturn;
1750
+
1751
+ interface GooglePlacesAutocompleteProps extends UseGooglePlacesAutocompleteOptions, Omit<AutocompleteProps<PlaceType, false, false, false>, 'options' | 'renderInput' | 'value' | 'onChange' | 'onInputChange' | 'loading'> {
1752
+ /** Text field label */
1753
+ label?: string;
1754
+ /** Text field placeholder */
1755
+ placeholder?: string;
1756
+ /** Helper text */
1757
+ helperText?: React.ReactNode;
1758
+ /** Error state */
1759
+ error?: boolean;
1760
+ /** Error message */
1761
+ errorMessage?: string;
1762
+ /** Required field */
1763
+ required?: boolean;
1764
+ /** Callback when value changes */
1765
+ onChange?: (value: PlaceType | null) => void;
1766
+ /** Callback when place details are fetched */
1767
+ onPlaceDetailsChange?: (details: any) => void;
1768
+ /** Additional TextField props */
1769
+ textFieldProps?: Partial<TextFieldProps>;
1770
+ /** Custom location icon component */
1771
+ LocationIcon?: React.ComponentType<{
1772
+ sx?: object;
1773
+ }>;
1774
+ /** No options text */
1775
+ noOptionsText?: string;
1776
+ /** External value (controlled) */
1777
+ value?: PlaceType | null;
1778
+ /** External input value (controlled) */
1779
+ inputValue?: string;
1780
+ }
1781
+ declare const GooglePlacesAutocomplete: ({ debounceMs, types, componentRestrictions, fetchPlaceDetails, placeDetailsFields, label, placeholder, helperText, error, errorMessage, required, onChange, onPlaceDetailsChange, textFieldProps, LocationIcon, noOptionsText, value: externalValue, inputValue: externalInputValue, ...autocompleteProps }: GooglePlacesAutocompleteProps) => react_jsx_runtime.JSX.Element;
1782
+
1783
+ interface RHFGooglePlacesAutocompleteProps extends Omit<GooglePlacesAutocompleteProps, 'value' | 'onChange' | 'error' | 'errorMessage'> {
1784
+ /** Field name */
1785
+ name: string;
1786
+ /** Helper text */
1787
+ helperText?: React.ReactNode;
1788
+ /**
1789
+ * What to store in the form value
1790
+ * - 'full': Store the entire PlaceType object
1791
+ * - 'description': Store only the description string
1792
+ * - 'details': Store the PlaceDetails object (requires fetchPlaceDetails=true)
1793
+ * @default 'full'
1794
+ */
1795
+ valueType?: 'full' | 'description' | 'details';
1796
+ /**
1797
+ * Callback when value changes (receives the raw PlaceType)
1798
+ */
1799
+ onValueChange?: (value: PlaceType | null) => void;
1800
+ /**
1801
+ * Callback when place details are fetched
1802
+ */
1803
+ onPlaceDetailsChange?: (details: PlaceDetails | null) => void;
1804
+ }
1805
+ declare const RHFGooglePlacesAutocomplete: ({ name, helperText, valueType, onValueChange, onPlaceDetailsChange, fetchPlaceDetails, ...other }: RHFGooglePlacesAutocompleteProps) => react_jsx_runtime.JSX.Element;
1806
+
1655
1807
  /**
1656
1808
  * Type definitions for date picker components with clearable option.
1657
1809
  */
@@ -1748,6 +1900,18 @@ interface RHFRadioGroupProps extends Omit<RadioGroupProps, 'name' | 'control'> {
1748
1900
  }
1749
1901
  declare const RHFRadioGroup: ({ name, label, options, helperText, slotProps, ...other }: RHFRadioGroupProps) => react_jsx_runtime.JSX.Element;
1750
1902
 
1903
+ type RHFSelectOption = {
1904
+ value: string | number;
1905
+ label: string;
1906
+ disabled?: boolean;
1907
+ };
1908
+ type RHFSelectProps = Omit<TextFieldProps, 'select' | 'name'> & {
1909
+ name: string;
1910
+ options: RHFSelectOption[];
1911
+ placeholder?: string;
1912
+ };
1913
+ declare const RHFSelect: ({ name, options, helperText, placeholder, slotProps, ...rest }: RHFSelectProps) => react_jsx_runtime.JSX.Element;
1914
+
1751
1915
  interface RHFUploadProps extends Omit<UploadProps, 'value'> {
1752
1916
  name: string;
1753
1917
  multiple?: boolean;
@@ -1823,6 +1987,7 @@ declare const Field: {
1823
1987
  };
1824
1988
  }) => react_jsx_runtime.JSX.Element;
1825
1989
  Upload: ({ name, multiple, helperText, ...rest }: RHFUploadProps) => react_jsx_runtime.JSX.Element;
1990
+ Select: ({ name, options, helperText, placeholder, slotProps, ...rest }: RHFSelectProps) => react_jsx_runtime.JSX.Element;
1826
1991
  Text: ({ name, helperText, type, slotProps, ...rest }: _mui_material.TextFieldProps) => react_jsx_runtime.JSX.Element;
1827
1992
  Radio: ({ name, label, options, helperText, slotProps, ...other }: RHFRadioGroupProps) => react_jsx_runtime.JSX.Element;
1828
1993
  Checkbox: ({ name, description, helperText, label, sx, slotProps, ...other }: RHFCheckboxProps) => react_jsx_runtime.JSX.Element;
@@ -1832,6 +1997,7 @@ declare const Field: {
1832
1997
  Time: react.MemoExoticComponent<({ name, slotProps, helperText, clearable, format, ...other }: RHFTimePickerProps) => react_jsx_runtime.JSX.Element>;
1833
1998
  DateTime: react.MemoExoticComponent<({ name, slotProps, helperText, clearable, format, ...other }: RHFDateTimePickerProps) => react_jsx_runtime.JSX.Element>;
1834
1999
  DateRange: typeof RHFDateRangePicker;
2000
+ GooglePlacesAutocomplete: ({ name, helperText, valueType, onValueChange, onPlaceDetailsChange, fetchPlaceDetails, ...other }: RHFGooglePlacesAutocompleteProps) => react_jsx_runtime.JSX.Element;
1835
2001
  };
1836
2002
 
1837
2003
  type RHFSwitchProps = Omit<FormControlLabelProps, 'name' | 'control'> & {
@@ -2453,4 +2619,4 @@ type ThemeProviderProps = {
2453
2619
  };
2454
2620
  declare const ThemeProvider: ({ children }: ThemeProviderProps) => react_jsx_runtime.JSX.Element;
2455
2621
 
2456
- export { AnimatedLogo, Attachment, Bank, BellNotification, Building, Calendar, ChatBubbleQuestionSolid, CheckCircleSolid, CheckboxDefault, CheckboxIndeterminate, CheckboxSelect, Circle, ClipboardCheck, Clock, CloudUpload, type ColorSchema, Copy, CopyButton, CustomDialog, type CustomDialogProps, CustomDrawer, type CustomDrawerProps, type CustomShadowOptions, type CustomSpacingOptions, type DatePickerProps, type DatePreset, type DatePresetOption, type DateRange, DateRangeDropdown, type DateRangeDropdownProps, DateRangePicker, type DateRangePickerProps, type DateTimePickerProps, Download, Edit, EmptyContent, type EmptyContentProps, ErrorToast, Eye, EyeClosed, FeedbackDialog, type FeedbackDialogProps, type FeedbackDialogSlotProps, Field, FilterDropdown, type FilterDropdownProps, FilterList, Form, HelpCircle, Icon, type IconProps, type IconType, Image, type ImageProps, type ImageStatus, InfoCircle, InfoCircleSolid, InfoToast, KeyCommand, Loader, LoadingScreen, LocalStorageAvailable, LocalStorageGetItem, Logo, LongArrowUpLeftSolid, MoreHorizontal, NavArrowDown, NavArrowDownSolid, NavArrowLeft, NavArrowRight, OTPInput, type OTPInputProps, Plus, PlusSquare, RHFAutocomplete, type RHFAutocompleteProps, RHFCheckbox, type RHFCheckboxProps, RHFDatePicker, type RHFDatePickerProps, RHFDateRangePicker, type RHFDateRangePickerProps, RHFDateTimePicker, type RHFDateTimePickerProps, RHFMultiCheckbox, type RHFMultiCheckboxOption, type RHFMultiCheckboxProps, RHFMultiSwitch, RHFOTPInput, type RHFOTPInputProps, RHFRadioGroup, type RHFRadioGroupProps, RHFSwitch, RHFTextField, RHFTimePicker, type RHFTimePickerProps, RHFUpload, type RHFUploadProps, RadioDefault, RadioSelect, type RadiusOptions, STORAGE_KEY, Search, Settings, SettingsConsumer, SettingsContext, type SettingsContextProps, SettingsProvider, type SettingsValueProps, type SortDirection, SortDown, SortDropdown, type SortDropdownProps, type SortOption, SortUp, SplashScreen, StatDown, StatUp, SuccessToast, Table, TablePagination, ThemeProvider, type TimePickerProps, Toast, ToolbarButton, type ToolbarButtonProps, ToolbarDatePickerButton, type ToolbarDatePickerButtonProps, ToolbarFilterButton, type ToolbarFilterButtonProps, ToolbarSearchField, type ToolbarSearchFieldProps, ToolbarSettingsButton, type ToolbarSettingsButtonProps, ToolbarSortButton, type ToolbarSortButtonProps, ToolbarTodayButton, type ToolbarTodayButtonProps, ToolbarViewSwitcher, type ToolbarViewSwitcherProps, Trash, Upload, type UploadProps, type UseBooleanReturnType, type UseSetStateReturnType, User, UserSolid, type ViewOption, WarningToast, XMark, XMarkSolid, action, apexChartsStyles, background, baseAction, basePalette, bgBlur, bgGradient, border, borderGradient, breakpoints, colorSchemes, common, components, createPaletteChannel, createShadowColor, createTheme, customShadows, customSpacing, darkPalette, defaultPresets, defaultSettings, dialogClasses, drawerClasses, error, fCurrency, fData, fNumber, fPercent, fShortenNumber, feedbackDialogClasses, formatFullname, getCurrencySymbol, getDateRangeFromPreset, getDefaultChartOptions, getInitials, getStorage, grey, hexToRgbChannel, hideScrollX, hideScrollY, icon, iconClasses, info, isEqual, lightPalette, maxLine, mediaQueries, menuItem, neutral, orderBy, paper, paramCase, primary, primaryFont, pxToRem, radius, remToPx, removeStorage, responsiveFontSizes, schemeConfig, secondary, secondaryFont, sentenceCase, setFont, setStorage, shadows, snakeCase, splitFullname, stylesMode, success, surface, tertiaryFont, text, textGradient, toolbarClasses, typography, updateComponentsWithSettings, updateCoreWithSettings, useBoolean, useCopyToClipboard, useCountdownDate, useCountdownSeconds, useEventListener, useLocalStorage, usePopover, useResponsive, useScrollOffSetTop, useSetState, useSettings, useWidth, varAlpha, warning };
2622
+ export { AnimatedLogo, Attachment, Bank, BellNotification, Building, Calendar, ChatBubbleQuestionSolid, CheckCircleSolid, CheckboxDefault, CheckboxIndeterminate, CheckboxSelect, Circle, ClipboardCheck, Clock, CloudUpload, type ColorSchema, Copy, CopyButton, CustomDialog, type CustomDialogProps, CustomDrawer, type CustomDrawerProps, type CustomShadowOptions, type CustomSpacingOptions, type DatePickerProps, type DatePreset, type DatePresetOption, type DateRange, DateRangeDropdown, type DateRangeDropdownProps, DateRangePicker, type DateRangePickerProps, type DateTimePickerProps, Download, Edit, EmptyContent, type EmptyContentProps, ErrorToast, Eye, EyeClosed, FeedbackDialog, type FeedbackDialogProps, type FeedbackDialogSlotProps, Field, FilterDropdown, type FilterDropdownProps, FilterList, Form, GooglePlacesAutocomplete, type GooglePlacesAutocompleteProps, type GooglePlacesContextValue, GooglePlacesProvider, type GooglePlacesProviderProps, HelpCircle, Icon, type IconProps, type IconType, Image, type ImageProps, type ImageStatus, InfoCircle, InfoCircleSolid, InfoToast, KeyCommand, Loader, LoadingScreen, LocalStorageAvailable, LocalStorageGetItem, Logo, LongArrowUpLeftSolid, type MainTextMatchedSubstrings, MoreHorizontal, NavArrowDown, NavArrowDownSolid, NavArrowLeft, NavArrowRight, OTPInput, type OTPInputProps, type PlaceDetails, type PlaceType, Plus, PlusSquare, RHFAutocomplete, type RHFAutocompleteProps, RHFCheckbox, type RHFCheckboxProps, RHFDatePicker, type RHFDatePickerProps, RHFDateRangePicker, type RHFDateRangePickerProps, RHFDateTimePicker, type RHFDateTimePickerProps, RHFGooglePlacesAutocomplete, type RHFGooglePlacesAutocompleteProps, RHFMultiCheckbox, type RHFMultiCheckboxOption, type RHFMultiCheckboxProps, RHFMultiSwitch, RHFOTPInput, type RHFOTPInputProps, RHFRadioGroup, type RHFRadioGroupProps, RHFSelect, type RHFSelectOption, type RHFSelectProps, RHFSwitch, RHFTextField, RHFTimePicker, type RHFTimePickerProps, RHFUpload, type RHFUploadProps, RadioDefault, RadioSelect, type RadiusOptions, STORAGE_KEY, Search, Settings, SettingsConsumer, SettingsContext, type SettingsContextProps, SettingsProvider, type SettingsValueProps, type SortDirection, SortDown, SortDropdown, type SortDropdownProps, type SortOption, SortUp, SplashScreen, StatDown, StatUp, type StructuredFormatting, SuccessToast, Table, TablePagination, ThemeProvider, type TimePickerProps, Toast, ToolbarButton, type ToolbarButtonProps, ToolbarDatePickerButton, type ToolbarDatePickerButtonProps, ToolbarFilterButton, type ToolbarFilterButtonProps, ToolbarSearchField, type ToolbarSearchFieldProps, ToolbarSettingsButton, type ToolbarSettingsButtonProps, ToolbarSortButton, type ToolbarSortButtonProps, ToolbarTodayButton, type ToolbarTodayButtonProps, ToolbarViewSwitcher, type ToolbarViewSwitcherProps, Trash, Upload, type UploadProps, type UseBooleanReturnType, type UseGooglePlacesAutocompleteOptions, type UseGooglePlacesAutocompleteReturn, type UseSetStateReturnType, User, UserSolid, type ViewOption, WarningToast, XMark, XMarkSolid, action, apexChartsStyles, background, baseAction, basePalette, bgBlur, bgGradient, border, borderGradient, breakpoints, colorSchemes, common, components, createPaletteChannel, createShadowColor, createTheme, customShadows, customSpacing, darkPalette, defaultPresets, defaultSettings, dialogClasses, drawerClasses, error, fCurrency, fData, fNumber, fPercent, fShortenNumber, feedbackDialogClasses, formatFullname, getCurrencySymbol, getDateRangeFromPreset, getDefaultChartOptions, getInitials, getStorage, grey, hexToRgbChannel, hideScrollX, hideScrollY, icon, iconClasses, info, isEqual, lightPalette, maxLine, mediaQueries, menuItem, neutral, orderBy, paper, paramCase, primary, primaryFont, pxToRem, radius, remToPx, removeStorage, responsiveFontSizes, schemeConfig, secondary, secondaryFont, sentenceCase, setFont, setStorage, shadows, snakeCase, splitFullname, stylesMode, success, surface, tertiaryFont, text, textGradient, toolbarClasses, typography, updateComponentsWithSettings, updateCoreWithSettings, useBoolean, useCopyToClipboard, useCountdownDate, useCountdownSeconds, useEventListener, useGooglePlacesAutocomplete, useGooglePlacesContext, useGooglePlacesLoaded, useLocalStorage, usePopover, useResponsive, useScrollOffSetTop, useSetState, useSettings, useWidth, varAlpha, warning };
package/dist/index.d.ts CHANGED
@@ -16,10 +16,11 @@ import { PopoverProps } from '@mui/material/Popover';
16
16
  import { ButtonBaseProps } from '@mui/material/ButtonBase';
17
17
  import { InputBaseProps } from '@mui/material/InputBase';
18
18
  import { FieldValues, UseFormReturn, SubmitHandler } from 'react-hook-form';
19
+ import { TextFieldProps } from '@mui/material/TextField';
20
+ import { AutocompleteProps } from '@mui/material/Autocomplete';
19
21
  import { DatePickerProps as DatePickerProps$1 } from '@mui/x-date-pickers/DatePicker';
20
22
  import { TimePickerProps as TimePickerProps$1 } from '@mui/x-date-pickers/TimePicker';
21
23
  import { DateTimePickerProps as DateTimePickerProps$1 } from '@mui/x-date-pickers/DateTimePicker';
22
- import { AutocompleteProps } from '@mui/material/Autocomplete';
23
24
  import { CheckboxProps } from '@mui/material/Checkbox';
24
25
  import { FormGroupProps } from '@mui/material/FormGroup';
25
26
  import { FormLabelProps } from '@mui/material/FormLabel';
@@ -28,7 +29,6 @@ import { FormHelperTextProps } from '@mui/material/FormHelperText';
28
29
  import { FormControlLabelProps } from '@mui/material/FormControlLabel';
29
30
  import { RadioProps } from '@mui/material/Radio';
30
31
  import { RadioGroupProps } from '@mui/material/RadioGroup';
31
- import { TextFieldProps } from '@mui/material/TextField';
32
32
  import { SwitchProps } from '@mui/material/Switch';
33
33
  export * from 'sonner';
34
34
 
@@ -1652,6 +1652,158 @@ interface FormProps<T extends FieldValues> extends Omit<BoxProps, 'onSubmit'> {
1652
1652
  }
1653
1653
  declare const Form: <T extends FieldValues>({ children, onSubmit, methods, ...rest }: FormProps<T>) => react_jsx_runtime.JSX.Element;
1654
1654
 
1655
+ interface MainTextMatchedSubstrings {
1656
+ offset: number;
1657
+ length: number;
1658
+ }
1659
+ interface StructuredFormatting {
1660
+ main_text: string;
1661
+ main_text_matched_substrings: readonly MainTextMatchedSubstrings[];
1662
+ secondary_text?: string;
1663
+ }
1664
+ interface PlaceType {
1665
+ description: string;
1666
+ place_id?: string;
1667
+ structured_formatting: StructuredFormatting;
1668
+ }
1669
+ interface GooglePlacesContextValue {
1670
+ apiKey: string;
1671
+ loaded: boolean;
1672
+ error: Error | null;
1673
+ }
1674
+ interface PlaceDetails {
1675
+ placeId: string;
1676
+ description: string;
1677
+ mainText: string;
1678
+ secondaryText?: string;
1679
+ lat?: number;
1680
+ lng?: number;
1681
+ formattedAddress?: string;
1682
+ addressComponents?: any[];
1683
+ }
1684
+
1685
+ interface GooglePlacesProviderProps {
1686
+ apiKey: string;
1687
+ children: React.ReactNode;
1688
+ /**
1689
+ * Additional libraries to load alongside 'places'
1690
+ * @default []
1691
+ */
1692
+ libraries?: string[];
1693
+ }
1694
+ declare const GooglePlacesProvider: ({ apiKey, children, libraries }: GooglePlacesProviderProps) => react_jsx_runtime.JSX.Element;
1695
+ declare const useGooglePlacesContext: () => GooglePlacesContextValue;
1696
+ declare const useGooglePlacesLoaded: () => boolean;
1697
+
1698
+ interface UseGooglePlacesAutocompleteOptions {
1699
+ /**
1700
+ * Debounce delay in milliseconds
1701
+ * @default 300
1702
+ */
1703
+ debounceMs?: number;
1704
+ /**
1705
+ * Types of places to search for
1706
+ * @see https://developers.google.com/maps/documentation/places/web-service/supported_types
1707
+ */
1708
+ types?: string[];
1709
+ /**
1710
+ * Country restrictions (ISO 3166-1 Alpha-2 codes)
1711
+ * @example ['us', 'ca']
1712
+ */
1713
+ componentRestrictions?: {
1714
+ country: string | string[];
1715
+ };
1716
+ /**
1717
+ * Whether to fetch place details when a place is selected
1718
+ * @default false
1719
+ */
1720
+ fetchPlaceDetails?: boolean;
1721
+ /**
1722
+ * Fields to fetch when getting place details
1723
+ * @default ['geometry', 'formatted_address', 'address_components']
1724
+ */
1725
+ placeDetailsFields?: string[];
1726
+ }
1727
+ interface UseGooglePlacesAutocompleteReturn {
1728
+ /** Current input value */
1729
+ inputValue: string;
1730
+ /** Set input value */
1731
+ setInputValue: (value: string) => void;
1732
+ /** Selected place */
1733
+ value: PlaceType | null;
1734
+ /** Set selected place */
1735
+ setValue: (value: PlaceType | null) => void;
1736
+ /** Autocomplete options */
1737
+ options: readonly PlaceType[];
1738
+ /** Whether the API is loaded */
1739
+ loaded: boolean;
1740
+ /** Loading state for fetching suggestions */
1741
+ loading: boolean;
1742
+ /** Error state */
1743
+ error: Error | null;
1744
+ /** Get place details for a selected place */
1745
+ getPlaceDetails: (placeId: string) => Promise<PlaceDetails | null>;
1746
+ /** Clear the selection */
1747
+ clear: () => void;
1748
+ }
1749
+ declare const useGooglePlacesAutocomplete: (options?: UseGooglePlacesAutocompleteOptions) => UseGooglePlacesAutocompleteReturn;
1750
+
1751
+ interface GooglePlacesAutocompleteProps extends UseGooglePlacesAutocompleteOptions, Omit<AutocompleteProps<PlaceType, false, false, false>, 'options' | 'renderInput' | 'value' | 'onChange' | 'onInputChange' | 'loading'> {
1752
+ /** Text field label */
1753
+ label?: string;
1754
+ /** Text field placeholder */
1755
+ placeholder?: string;
1756
+ /** Helper text */
1757
+ helperText?: React.ReactNode;
1758
+ /** Error state */
1759
+ error?: boolean;
1760
+ /** Error message */
1761
+ errorMessage?: string;
1762
+ /** Required field */
1763
+ required?: boolean;
1764
+ /** Callback when value changes */
1765
+ onChange?: (value: PlaceType | null) => void;
1766
+ /** Callback when place details are fetched */
1767
+ onPlaceDetailsChange?: (details: any) => void;
1768
+ /** Additional TextField props */
1769
+ textFieldProps?: Partial<TextFieldProps>;
1770
+ /** Custom location icon component */
1771
+ LocationIcon?: React.ComponentType<{
1772
+ sx?: object;
1773
+ }>;
1774
+ /** No options text */
1775
+ noOptionsText?: string;
1776
+ /** External value (controlled) */
1777
+ value?: PlaceType | null;
1778
+ /** External input value (controlled) */
1779
+ inputValue?: string;
1780
+ }
1781
+ declare const GooglePlacesAutocomplete: ({ debounceMs, types, componentRestrictions, fetchPlaceDetails, placeDetailsFields, label, placeholder, helperText, error, errorMessage, required, onChange, onPlaceDetailsChange, textFieldProps, LocationIcon, noOptionsText, value: externalValue, inputValue: externalInputValue, ...autocompleteProps }: GooglePlacesAutocompleteProps) => react_jsx_runtime.JSX.Element;
1782
+
1783
+ interface RHFGooglePlacesAutocompleteProps extends Omit<GooglePlacesAutocompleteProps, 'value' | 'onChange' | 'error' | 'errorMessage'> {
1784
+ /** Field name */
1785
+ name: string;
1786
+ /** Helper text */
1787
+ helperText?: React.ReactNode;
1788
+ /**
1789
+ * What to store in the form value
1790
+ * - 'full': Store the entire PlaceType object
1791
+ * - 'description': Store only the description string
1792
+ * - 'details': Store the PlaceDetails object (requires fetchPlaceDetails=true)
1793
+ * @default 'full'
1794
+ */
1795
+ valueType?: 'full' | 'description' | 'details';
1796
+ /**
1797
+ * Callback when value changes (receives the raw PlaceType)
1798
+ */
1799
+ onValueChange?: (value: PlaceType | null) => void;
1800
+ /**
1801
+ * Callback when place details are fetched
1802
+ */
1803
+ onPlaceDetailsChange?: (details: PlaceDetails | null) => void;
1804
+ }
1805
+ declare const RHFGooglePlacesAutocomplete: ({ name, helperText, valueType, onValueChange, onPlaceDetailsChange, fetchPlaceDetails, ...other }: RHFGooglePlacesAutocompleteProps) => react_jsx_runtime.JSX.Element;
1806
+
1655
1807
  /**
1656
1808
  * Type definitions for date picker components with clearable option.
1657
1809
  */
@@ -1748,6 +1900,18 @@ interface RHFRadioGroupProps extends Omit<RadioGroupProps, 'name' | 'control'> {
1748
1900
  }
1749
1901
  declare const RHFRadioGroup: ({ name, label, options, helperText, slotProps, ...other }: RHFRadioGroupProps) => react_jsx_runtime.JSX.Element;
1750
1902
 
1903
+ type RHFSelectOption = {
1904
+ value: string | number;
1905
+ label: string;
1906
+ disabled?: boolean;
1907
+ };
1908
+ type RHFSelectProps = Omit<TextFieldProps, 'select' | 'name'> & {
1909
+ name: string;
1910
+ options: RHFSelectOption[];
1911
+ placeholder?: string;
1912
+ };
1913
+ declare const RHFSelect: ({ name, options, helperText, placeholder, slotProps, ...rest }: RHFSelectProps) => react_jsx_runtime.JSX.Element;
1914
+
1751
1915
  interface RHFUploadProps extends Omit<UploadProps, 'value'> {
1752
1916
  name: string;
1753
1917
  multiple?: boolean;
@@ -1823,6 +1987,7 @@ declare const Field: {
1823
1987
  };
1824
1988
  }) => react_jsx_runtime.JSX.Element;
1825
1989
  Upload: ({ name, multiple, helperText, ...rest }: RHFUploadProps) => react_jsx_runtime.JSX.Element;
1990
+ Select: ({ name, options, helperText, placeholder, slotProps, ...rest }: RHFSelectProps) => react_jsx_runtime.JSX.Element;
1826
1991
  Text: ({ name, helperText, type, slotProps, ...rest }: _mui_material.TextFieldProps) => react_jsx_runtime.JSX.Element;
1827
1992
  Radio: ({ name, label, options, helperText, slotProps, ...other }: RHFRadioGroupProps) => react_jsx_runtime.JSX.Element;
1828
1993
  Checkbox: ({ name, description, helperText, label, sx, slotProps, ...other }: RHFCheckboxProps) => react_jsx_runtime.JSX.Element;
@@ -1832,6 +1997,7 @@ declare const Field: {
1832
1997
  Time: react.MemoExoticComponent<({ name, slotProps, helperText, clearable, format, ...other }: RHFTimePickerProps) => react_jsx_runtime.JSX.Element>;
1833
1998
  DateTime: react.MemoExoticComponent<({ name, slotProps, helperText, clearable, format, ...other }: RHFDateTimePickerProps) => react_jsx_runtime.JSX.Element>;
1834
1999
  DateRange: typeof RHFDateRangePicker;
2000
+ GooglePlacesAutocomplete: ({ name, helperText, valueType, onValueChange, onPlaceDetailsChange, fetchPlaceDetails, ...other }: RHFGooglePlacesAutocompleteProps) => react_jsx_runtime.JSX.Element;
1835
2001
  };
1836
2002
 
1837
2003
  type RHFSwitchProps = Omit<FormControlLabelProps, 'name' | 'control'> & {
@@ -2453,4 +2619,4 @@ type ThemeProviderProps = {
2453
2619
  };
2454
2620
  declare const ThemeProvider: ({ children }: ThemeProviderProps) => react_jsx_runtime.JSX.Element;
2455
2621
 
2456
- export { AnimatedLogo, Attachment, Bank, BellNotification, Building, Calendar, ChatBubbleQuestionSolid, CheckCircleSolid, CheckboxDefault, CheckboxIndeterminate, CheckboxSelect, Circle, ClipboardCheck, Clock, CloudUpload, type ColorSchema, Copy, CopyButton, CustomDialog, type CustomDialogProps, CustomDrawer, type CustomDrawerProps, type CustomShadowOptions, type CustomSpacingOptions, type DatePickerProps, type DatePreset, type DatePresetOption, type DateRange, DateRangeDropdown, type DateRangeDropdownProps, DateRangePicker, type DateRangePickerProps, type DateTimePickerProps, Download, Edit, EmptyContent, type EmptyContentProps, ErrorToast, Eye, EyeClosed, FeedbackDialog, type FeedbackDialogProps, type FeedbackDialogSlotProps, Field, FilterDropdown, type FilterDropdownProps, FilterList, Form, HelpCircle, Icon, type IconProps, type IconType, Image, type ImageProps, type ImageStatus, InfoCircle, InfoCircleSolid, InfoToast, KeyCommand, Loader, LoadingScreen, LocalStorageAvailable, LocalStorageGetItem, Logo, LongArrowUpLeftSolid, MoreHorizontal, NavArrowDown, NavArrowDownSolid, NavArrowLeft, NavArrowRight, OTPInput, type OTPInputProps, Plus, PlusSquare, RHFAutocomplete, type RHFAutocompleteProps, RHFCheckbox, type RHFCheckboxProps, RHFDatePicker, type RHFDatePickerProps, RHFDateRangePicker, type RHFDateRangePickerProps, RHFDateTimePicker, type RHFDateTimePickerProps, RHFMultiCheckbox, type RHFMultiCheckboxOption, type RHFMultiCheckboxProps, RHFMultiSwitch, RHFOTPInput, type RHFOTPInputProps, RHFRadioGroup, type RHFRadioGroupProps, RHFSwitch, RHFTextField, RHFTimePicker, type RHFTimePickerProps, RHFUpload, type RHFUploadProps, RadioDefault, RadioSelect, type RadiusOptions, STORAGE_KEY, Search, Settings, SettingsConsumer, SettingsContext, type SettingsContextProps, SettingsProvider, type SettingsValueProps, type SortDirection, SortDown, SortDropdown, type SortDropdownProps, type SortOption, SortUp, SplashScreen, StatDown, StatUp, SuccessToast, Table, TablePagination, ThemeProvider, type TimePickerProps, Toast, ToolbarButton, type ToolbarButtonProps, ToolbarDatePickerButton, type ToolbarDatePickerButtonProps, ToolbarFilterButton, type ToolbarFilterButtonProps, ToolbarSearchField, type ToolbarSearchFieldProps, ToolbarSettingsButton, type ToolbarSettingsButtonProps, ToolbarSortButton, type ToolbarSortButtonProps, ToolbarTodayButton, type ToolbarTodayButtonProps, ToolbarViewSwitcher, type ToolbarViewSwitcherProps, Trash, Upload, type UploadProps, type UseBooleanReturnType, type UseSetStateReturnType, User, UserSolid, type ViewOption, WarningToast, XMark, XMarkSolid, action, apexChartsStyles, background, baseAction, basePalette, bgBlur, bgGradient, border, borderGradient, breakpoints, colorSchemes, common, components, createPaletteChannel, createShadowColor, createTheme, customShadows, customSpacing, darkPalette, defaultPresets, defaultSettings, dialogClasses, drawerClasses, error, fCurrency, fData, fNumber, fPercent, fShortenNumber, feedbackDialogClasses, formatFullname, getCurrencySymbol, getDateRangeFromPreset, getDefaultChartOptions, getInitials, getStorage, grey, hexToRgbChannel, hideScrollX, hideScrollY, icon, iconClasses, info, isEqual, lightPalette, maxLine, mediaQueries, menuItem, neutral, orderBy, paper, paramCase, primary, primaryFont, pxToRem, radius, remToPx, removeStorage, responsiveFontSizes, schemeConfig, secondary, secondaryFont, sentenceCase, setFont, setStorage, shadows, snakeCase, splitFullname, stylesMode, success, surface, tertiaryFont, text, textGradient, toolbarClasses, typography, updateComponentsWithSettings, updateCoreWithSettings, useBoolean, useCopyToClipboard, useCountdownDate, useCountdownSeconds, useEventListener, useLocalStorage, usePopover, useResponsive, useScrollOffSetTop, useSetState, useSettings, useWidth, varAlpha, warning };
2622
+ export { AnimatedLogo, Attachment, Bank, BellNotification, Building, Calendar, ChatBubbleQuestionSolid, CheckCircleSolid, CheckboxDefault, CheckboxIndeterminate, CheckboxSelect, Circle, ClipboardCheck, Clock, CloudUpload, type ColorSchema, Copy, CopyButton, CustomDialog, type CustomDialogProps, CustomDrawer, type CustomDrawerProps, type CustomShadowOptions, type CustomSpacingOptions, type DatePickerProps, type DatePreset, type DatePresetOption, type DateRange, DateRangeDropdown, type DateRangeDropdownProps, DateRangePicker, type DateRangePickerProps, type DateTimePickerProps, Download, Edit, EmptyContent, type EmptyContentProps, ErrorToast, Eye, EyeClosed, FeedbackDialog, type FeedbackDialogProps, type FeedbackDialogSlotProps, Field, FilterDropdown, type FilterDropdownProps, FilterList, Form, GooglePlacesAutocomplete, type GooglePlacesAutocompleteProps, type GooglePlacesContextValue, GooglePlacesProvider, type GooglePlacesProviderProps, HelpCircle, Icon, type IconProps, type IconType, Image, type ImageProps, type ImageStatus, InfoCircle, InfoCircleSolid, InfoToast, KeyCommand, Loader, LoadingScreen, LocalStorageAvailable, LocalStorageGetItem, Logo, LongArrowUpLeftSolid, type MainTextMatchedSubstrings, MoreHorizontal, NavArrowDown, NavArrowDownSolid, NavArrowLeft, NavArrowRight, OTPInput, type OTPInputProps, type PlaceDetails, type PlaceType, Plus, PlusSquare, RHFAutocomplete, type RHFAutocompleteProps, RHFCheckbox, type RHFCheckboxProps, RHFDatePicker, type RHFDatePickerProps, RHFDateRangePicker, type RHFDateRangePickerProps, RHFDateTimePicker, type RHFDateTimePickerProps, RHFGooglePlacesAutocomplete, type RHFGooglePlacesAutocompleteProps, RHFMultiCheckbox, type RHFMultiCheckboxOption, type RHFMultiCheckboxProps, RHFMultiSwitch, RHFOTPInput, type RHFOTPInputProps, RHFRadioGroup, type RHFRadioGroupProps, RHFSelect, type RHFSelectOption, type RHFSelectProps, RHFSwitch, RHFTextField, RHFTimePicker, type RHFTimePickerProps, RHFUpload, type RHFUploadProps, RadioDefault, RadioSelect, type RadiusOptions, STORAGE_KEY, Search, Settings, SettingsConsumer, SettingsContext, type SettingsContextProps, SettingsProvider, type SettingsValueProps, type SortDirection, SortDown, SortDropdown, type SortDropdownProps, type SortOption, SortUp, SplashScreen, StatDown, StatUp, type StructuredFormatting, SuccessToast, Table, TablePagination, ThemeProvider, type TimePickerProps, Toast, ToolbarButton, type ToolbarButtonProps, ToolbarDatePickerButton, type ToolbarDatePickerButtonProps, ToolbarFilterButton, type ToolbarFilterButtonProps, ToolbarSearchField, type ToolbarSearchFieldProps, ToolbarSettingsButton, type ToolbarSettingsButtonProps, ToolbarSortButton, type ToolbarSortButtonProps, ToolbarTodayButton, type ToolbarTodayButtonProps, ToolbarViewSwitcher, type ToolbarViewSwitcherProps, Trash, Upload, type UploadProps, type UseBooleanReturnType, type UseGooglePlacesAutocompleteOptions, type UseGooglePlacesAutocompleteReturn, type UseSetStateReturnType, User, UserSolid, type ViewOption, WarningToast, XMark, XMarkSolid, action, apexChartsStyles, background, baseAction, basePalette, bgBlur, bgGradient, border, borderGradient, breakpoints, colorSchemes, common, components, createPaletteChannel, createShadowColor, createTheme, customShadows, customSpacing, darkPalette, defaultPresets, defaultSettings, dialogClasses, drawerClasses, error, fCurrency, fData, fNumber, fPercent, fShortenNumber, feedbackDialogClasses, formatFullname, getCurrencySymbol, getDateRangeFromPreset, getDefaultChartOptions, getInitials, getStorage, grey, hexToRgbChannel, hideScrollX, hideScrollY, icon, iconClasses, info, isEqual, lightPalette, maxLine, mediaQueries, menuItem, neutral, orderBy, paper, paramCase, primary, primaryFont, pxToRem, radius, remToPx, removeStorage, responsiveFontSizes, schemeConfig, secondary, secondaryFont, sentenceCase, setFont, setStorage, shadows, snakeCase, splitFullname, stylesMode, success, surface, tertiaryFont, text, textGradient, toolbarClasses, typography, updateComponentsWithSettings, updateCoreWithSettings, useBoolean, useCopyToClipboard, useCountdownDate, useCountdownSeconds, useEventListener, useGooglePlacesAutocomplete, useGooglePlacesContext, useGooglePlacesLoaded, useLocalStorage, usePopover, useResponsive, useScrollOffSetTop, useSetState, useSettings, useWidth, varAlpha, warning };