@nulogy/components 10.2.5 → 11.0.0-beta.2

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/main.js +1296 -197
  2. package/dist/main.module.js +1295 -196
  3. package/dist/src/AsyncSelect/AsyncSelectComponents.d.ts +1 -1
  4. package/dist/src/BrandedNavBar/MobileMenu.d.ts +1 -1
  5. package/dist/src/Branding/BrandingText.d.ts +1 -1
  6. package/dist/src/Branding/LettermarkLogo.d.ts +1 -1
  7. package/dist/src/Branding/WordmarkLogo.d.ts +1 -1
  8. package/dist/src/Button/Button.d.ts +1 -1
  9. package/dist/src/Button/DangerButton.d.ts +1 -1
  10. package/dist/src/Button/PrimaryButton.d.ts +1 -1
  11. package/dist/src/Button/QuietButton.d.ts +1 -1
  12. package/dist/src/ButtonGroup/ButtonGroup.d.ts +1 -1
  13. package/dist/src/Card/Card.d.ts +1 -1
  14. package/dist/src/Checkbox/Checkbox.d.ts +1 -1
  15. package/dist/src/Checkbox/CheckboxGroup.d.ts +1 -1
  16. package/dist/src/DatePicker/DatePickerHeader.d.ts +1 -1
  17. package/dist/src/DateRange/DateRange.d.ts +1 -1
  18. package/dist/src/DateRange/EndTime.d.ts +2 -2
  19. package/dist/src/DateRange/StartTime.d.ts +2 -2
  20. package/dist/src/DropdownMenu/DropdownItem.d.ts +1 -1
  21. package/dist/src/DropdownMenu/DropdownMenu.d.ts +1 -1
  22. package/dist/src/DropdownMenu/DropdownMenuContainer.d.ts +1 -1
  23. package/dist/src/DropdownMenu/DropdownText.d.ts +1 -1
  24. package/dist/src/Form/Fieldset.d.ts +1 -1
  25. package/dist/src/Form/FormSection.d.ts +1 -1
  26. package/dist/src/Icon/LoadingIcon.d.ts +1 -1
  27. package/dist/src/Layout/Header.d.ts +1 -1
  28. package/dist/src/Layout/Page.d.ts +1 -1
  29. package/dist/src/List/List.d.ts +1 -1
  30. package/dist/src/List/ListItem.d.ts +1 -1
  31. package/dist/src/LoadingAnimation/LoadingAnimation.d.ts +1 -1
  32. package/dist/src/Modal/Modal.d.ts +1 -1
  33. package/dist/src/Modal/ModalContent.d.ts +1 -1
  34. package/dist/src/NDSProvider/ComponentSizeContext.d.ts +1 -1
  35. package/dist/src/NDSProvider/NDSProvider.d.ts +1 -1
  36. package/dist/src/Overlay/Overlay.d.ts +1 -1
  37. package/dist/src/Popper/Popper.d.ts +1 -1
  38. package/dist/src/Radio/Radio.d.ts +1 -1
  39. package/dist/src/RangeContainer/RangeContainer.d.ts +1 -1
  40. package/dist/src/Select/MenuList.d.ts +3 -0
  41. package/dist/src/Select/Select.d.ts +20 -53
  42. package/dist/src/Select/Select.story.d.ts +0 -1
  43. package/dist/src/Select/Select.story.fixture.d.ts +19 -0
  44. package/dist/src/Select/SelectComponents.d.ts +9 -7
  45. package/dist/src/Select/SelectOption.d.ts +7 -6
  46. package/dist/src/Select/index.d.ts +1 -1
  47. package/dist/src/Select/lib.d.ts +20 -0
  48. package/dist/src/Summary/Summary.d.ts +1 -1
  49. package/dist/src/Summary/SummaryContext.d.ts +1 -1
  50. package/dist/src/Summary/SummaryItem.d.ts +1 -1
  51. package/dist/src/Switcher/Switcher.d.ts +1 -1
  52. package/dist/src/Table/TableCell.d.ts +1 -1
  53. package/dist/src/Tabs/Tab.d.ts +1 -1
  54. package/dist/src/Tabs/TabScrollIndicator.d.ts +1 -1
  55. package/dist/src/TimePicker/TimePicker.d.ts +1 -1
  56. package/dist/src/Toggle/ToggleButton.d.ts +1 -1
  57. package/dist/src/Tooltip/Tooltip.d.ts +1 -1
  58. package/dist/src/Validation/InlineValidation.d.ts +1 -1
  59. package/dist/src/index.d.ts +1 -1
  60. package/dist/src/utils/PopperArrow.d.ts +1 -1
  61. package/dist/src/utils/ts/FocusManager.d.ts +1 -1
  62. package/package.json +5 -5
@@ -1,7 +1,7 @@
1
1
  import React from "react";
2
2
  import { ClearIndicatorProps, ContainerProps, ControlProps, DropdownIndicatorProps, InputProps, MenuProps, MultiValueProps } from "react-select";
3
3
  import { GroupBase } from "react-select";
4
- import { OptionProps } from "react-windowed-select";
4
+ import { OptionProps } from "react-select";
5
5
  import { ComponentSize } from "../NDSProvider/ComponentSizeContext";
6
6
  export declare const SelectControl: <Option, IsMulti extends boolean, Group extends GroupBase<Option>>(props: ControlProps<Option, IsMulti, Group>) => React.JSX.Element;
7
7
  export declare const SelectMultiValue: <Option, IsMulti extends boolean, Group extends GroupBase<Option>>(props: MultiValueProps<Option, IsMulti, Group>) => React.JSX.Element;
@@ -15,5 +15,5 @@ type BaseMobileMenuProps = {
15
15
  themeColorObject?: ThemeColorObject;
16
16
  showNulogyLogo?: boolean;
17
17
  };
18
- declare const MobileMenu: import("styled-components").StyledComponent<React.FC<React.PropsWithChildren<BaseMobileMenuProps>>, import("styled-components").DefaultTheme, {}, never>;
18
+ declare const MobileMenu: import("styled-components").StyledComponent<React.FC<BaseMobileMenuProps>, import("styled-components").DefaultTheme, {}, never>;
19
19
  export default MobileMenu;
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
- declare const BrandingText: React.FC<React.PropsWithChildren<any>>;
2
+ declare const BrandingText: React.FC<any>;
3
3
  export default BrandingText;
@@ -3,5 +3,5 @@ type LettermarkLogoProps = {
3
3
  letterFill?: string;
4
4
  size?: string;
5
5
  };
6
- declare const LettermarkLogo: React.FC<React.PropsWithChildren<LettermarkLogoProps>>;
6
+ declare const LettermarkLogo: React.FC<LettermarkLogoProps>;
7
7
  export default LettermarkLogo;
@@ -4,5 +4,5 @@ type WordmarkLogoProps = {
4
4
  letterFill?: string;
5
5
  size?: string;
6
6
  };
7
- declare const WordmarkLogo: React.FC<React.PropsWithChildren<WordmarkLogoProps>>;
7
+ declare const WordmarkLogo: React.FC<WordmarkLogoProps>;
8
8
  export default WordmarkLogo;
@@ -13,5 +13,5 @@ export type ButtonProps = SpaceProps & React.ComponentPropsWithRef<"button"> & {
13
13
  theme?: DefaultNDSThemeType;
14
14
  href?: string;
15
15
  };
16
- declare const Button: React.FC<React.PropsWithChildren<ButtonProps>>;
16
+ declare const Button: React.FC<ButtonProps>;
17
17
  export default Button;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import { ButtonProps } from "./Button";
3
- declare const DangerButton: import("styled-components").StyledComponent<import("react").FC<import("react").PropsWithChildren<ButtonProps>>, import("styled-components").DefaultTheme, {}, never>;
3
+ declare const DangerButton: import("styled-components").StyledComponent<import("react").FC<ButtonProps>, import("styled-components").DefaultTheme, {}, never>;
4
4
  export default DangerButton;
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
- declare const PrimaryButton: React.FC<React.PropsWithChildren<any>>;
2
+ declare const PrimaryButton: React.FC<any>;
3
3
  export default PrimaryButton;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import { ButtonProps } from "./Button";
3
- declare const QuietButton: import("styled-components").StyledComponent<import("react").FC<import("react").PropsWithChildren<ButtonProps>>, import("styled-components").DefaultTheme, {}, never>;
3
+ declare const QuietButton: import("styled-components").StyledComponent<import("react").FC<ButtonProps>, import("styled-components").DefaultTheme, {}, never>;
4
4
  export default QuietButton;
@@ -4,5 +4,5 @@ type ButtonGroupProps = FlexProps & {
4
4
  alignment?: "left" | "spaced" | "right";
5
5
  className?: string;
6
6
  };
7
- declare const ButtonGroup: React.FC<React.PropsWithChildren<ButtonGroupProps>>;
7
+ declare const ButtonGroup: React.FC<ButtonGroupProps>;
8
8
  export default ButtonGroup;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import { BoxProps } from "../Box/Box";
3
- declare const Card: React.FC<React.PropsWithChildren<BoxProps>>;
3
+ declare const Card: React.FC<BoxProps>;
4
4
  export default Card;
@@ -13,5 +13,5 @@ type CheckboxProps = NativeInputProps & SpaceProps & {
13
13
  indeterminate?: boolean;
14
14
  theme?: DefaultNDSThemeType;
15
15
  };
16
- declare const Checkbox: React.FC<React.PropsWithChildren<CheckboxProps>>;
16
+ declare const Checkbox: React.FC<CheckboxProps>;
17
17
  export default Checkbox;
@@ -14,5 +14,5 @@ interface CheckboxGroupProps {
14
14
  required?: boolean;
15
15
  disabled?: boolean;
16
16
  }
17
- declare const CheckboxGroup: React.FC<React.PropsWithChildren<CheckboxGroupProps>>;
17
+ declare const CheckboxGroup: React.FC<CheckboxGroupProps>;
18
18
  export default CheckboxGroup;
@@ -7,5 +7,5 @@ type DatePickerHeaderProps = {
7
7
  nextMonthButtonDisabled: boolean;
8
8
  locale?: string;
9
9
  };
10
- declare const DatePickerHeader: React.FC<React.PropsWithChildren<DatePickerHeaderProps>>;
10
+ declare const DatePickerHeader: React.FC<DatePickerHeaderProps>;
11
11
  export default DatePickerHeader;
@@ -32,5 +32,5 @@ type DateRangeProps = FieldProps & {
32
32
  startTimeProps?: any;
33
33
  size?: ComponentSize;
34
34
  };
35
- declare const DateRange: React.FC<React.PropsWithChildren<DateRangeProps>>;
35
+ declare const DateRange: React.FC<DateRangeProps>;
36
36
  export default DateRange;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- declare const EndTime: import("styled-components").StyledComponent<import("react").FC<import("react").PropsWithChildren<import("styled-system").SpaceProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>, string | number | symbol> & {
2
+ declare const EndTime: import("styled-components").StyledComponent<import("react").FC<import("styled-system").SpaceProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>, string | number | symbol> & {
3
3
  size?: import("../NDSProvider/ComponentSizeContext").ComponentSize;
4
4
  disabled?: boolean;
5
5
  value?: string;
@@ -20,5 +20,5 @@ declare const EndTime: import("styled-components").StyledComponent<import("react
20
20
  onBlur?: (...args: any[]) => any;
21
21
  onFocus?: (...args: any[]) => any;
22
22
  onClick?: (...args: any[]) => any;
23
- }>>, import("styled-components").DefaultTheme, {}, never>;
23
+ }>, import("styled-components").DefaultTheme, {}, never>;
24
24
  export default EndTime;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- declare const StartTime: import("styled-components").StyledComponent<import("react").FC<import("react").PropsWithChildren<import("styled-system").SpaceProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>, string | number | symbol> & {
2
+ declare const StartTime: import("styled-components").StyledComponent<import("react").FC<import("styled-system").SpaceProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>, string | number | symbol> & {
3
3
  size?: import("../NDSProvider/ComponentSizeContext").ComponentSize;
4
4
  disabled?: boolean;
5
5
  value?: string;
@@ -20,5 +20,5 @@ declare const StartTime: import("styled-components").StyledComponent<import("rea
20
20
  onBlur?: (...args: any[]) => any;
21
21
  onFocus?: (...args: any[]) => any;
22
22
  onClick?: (...args: any[]) => any;
23
- }>>, import("styled-components").DefaultTheme, {}, never>;
23
+ }>, import("styled-components").DefaultTheme, {}, never>;
24
24
  export default StartTime;
@@ -6,5 +6,5 @@ type DropdownItemProps = {
6
6
  hoverColor?: string;
7
7
  bgHoverColor?: string;
8
8
  };
9
- declare const DropdownItem: React.FC<React.PropsWithChildren<DropdownItemProps>>;
9
+ declare const DropdownItem: React.FC<DropdownItemProps>;
10
10
  export default DropdownItem;
@@ -18,5 +18,5 @@ type DropdownMenuProps = {
18
18
  closeAriaLabel?: string;
19
19
  openOnHover?: boolean;
20
20
  } & StyledProps;
21
- declare const DropdownMenu: React.FC<React.PropsWithChildren<DropdownMenuProps>>;
21
+ declare const DropdownMenu: React.FC<DropdownMenuProps>;
22
22
  export default DropdownMenu;
@@ -8,5 +8,5 @@ type DropdownMenuContainerProps = {
8
8
  dataPlacement?: any;
9
9
  theme?: DefaultNDSThemeType;
10
10
  };
11
- declare const DropdownMenuContainer: React.FC<React.PropsWithChildren<DropdownMenuContainerProps>>;
11
+ declare const DropdownMenuContainer: React.FC<DropdownMenuContainerProps>;
12
12
  export default DropdownMenuContainer;
@@ -1,4 +1,4 @@
1
1
  import React from "react";
2
2
  import { TextProps } from "../Type/Text";
3
- declare const DropdownText: React.FC<React.PropsWithChildren<TextProps>>;
3
+ declare const DropdownText: React.FC<TextProps>;
4
4
  export default DropdownText;
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
- declare const Fieldset: React.FC<React.PropsWithChildren<any>>;
2
+ declare const Fieldset: React.FC<any>;
3
3
  export default Fieldset;
@@ -2,5 +2,5 @@ import React from "react";
2
2
  type BaseFormSectionProps = React.ComponentPropsWithRef<"fieldset"> & {
3
3
  title?: string;
4
4
  };
5
- declare const FormSection: import("styled-components").StyledComponent<React.FC<React.PropsWithChildren<BaseFormSectionProps>>, import("styled-components").DefaultTheme, {}, never>;
5
+ declare const FormSection: import("styled-components").StyledComponent<React.FC<BaseFormSectionProps>, import("styled-components").DefaultTheme, {}, never>;
6
6
  export default FormSection;
@@ -1,4 +1,4 @@
1
1
  import React from "react";
2
2
  type LoadingIconProps = React.ComponentPropsWithoutRef<"svg">;
3
- declare const LoadingIcon: React.FC<React.PropsWithChildren<LoadingIconProps>>;
3
+ declare const LoadingIcon: React.FC<LoadingIconProps>;
4
4
  export default LoadingIcon;
@@ -13,5 +13,5 @@ type HeaderProps = BoxProps & {
13
13
  medium?: Breakpoint;
14
14
  };
15
15
  };
16
- declare const Header: React.FC<React.PropsWithChildren<HeaderProps>>;
16
+ declare const Header: React.FC<HeaderProps>;
17
17
  export default Header;
@@ -8,5 +8,5 @@ type PageProps = FlexProps & {
8
8
  fullHeight?: boolean;
9
9
  renderHeader?: () => JSX.Element;
10
10
  };
11
- export declare const Page: React.FC<React.PropsWithChildren<PageProps>>;
11
+ export declare const Page: React.FC<PageProps>;
12
12
  export default Page;
@@ -8,5 +8,5 @@ type ListProps = React.ComponentPropsWithRef<"ul"> & StyledProps & {
8
8
  leftAlign?: boolean;
9
9
  listStyle?: string;
10
10
  };
11
- declare const List: React.FC<React.PropsWithChildren<ListProps>>;
11
+ declare const List: React.FC<ListProps>;
12
12
  export default List;
@@ -3,5 +3,5 @@ import { SpaceProps, ColorProps, TypographyProps } from "styled-system";
3
3
  type ListItemProps = React.ComponentPropsWithRef<"li"> & SpaceProps & ColorProps & TypographyProps & {
4
4
  className?: string;
5
5
  };
6
- declare const ListItem: React.FC<React.PropsWithChildren<ListItemProps>>;
6
+ declare const ListItem: React.FC<ListItemProps>;
7
7
  export default ListItem;
@@ -2,5 +2,5 @@ import React from "react";
2
2
  type LoadingAnimationProps = React.ComponentPropsWithRef<"svg"> & {
3
3
  inactive?: boolean;
4
4
  };
5
- declare const LoadingAnimation: React.FC<React.PropsWithChildren<LoadingAnimationProps>>;
5
+ declare const LoadingAnimation: React.FC<LoadingAnimationProps>;
6
6
  export default LoadingAnimation;
@@ -19,7 +19,7 @@ type ModalProps = {
19
19
  footerContent?: React.ReactNode;
20
20
  parentSelector?: (...args: any) => HTMLElement;
21
21
  };
22
- declare const Modal: React.FC<React.PropsWithChildren<ModalProps>> & {
22
+ declare const Modal: React.FC<ModalProps> & {
23
23
  setAppElement: (element: string | HTMLElement) => void;
24
24
  };
25
25
  export default Modal;
@@ -4,5 +4,5 @@ type ModalContentProps = React.ComponentPropsWithRef<"div"> & {
4
4
  hasFooter?: any;
5
5
  theme?: DefaultNDSThemeType;
6
6
  };
7
- declare const ModalContent: React.FC<React.PropsWithChildren<ModalContentProps>>;
7
+ declare const ModalContent: React.FC<ModalContentProps>;
8
8
  export default ModalContent;
@@ -5,5 +5,5 @@ type ComponentSizeContextValue = {
5
5
  };
6
6
  export declare const ComponentSizeContext: React.Context<ComponentSizeContextValue>;
7
7
  export declare function useComponentSize(selectedSize?: ComponentSize): ComponentSize;
8
- declare const ComponentSizeContextProvider: React.FC<React.PropsWithChildren<ComponentSizeContextValue>>;
8
+ declare const ComponentSizeContextProvider: React.FC<ComponentSizeContextValue>;
9
9
  export default ComponentSizeContextProvider;
@@ -16,5 +16,5 @@ type NDSProviderProps = {
16
16
  children?: any;
17
17
  size?: ComponentSize;
18
18
  };
19
- declare const NDSProvider: React.FC<React.PropsWithChildren<NDSProviderProps>>;
19
+ declare const NDSProvider: React.FC<NDSProviderProps>;
20
20
  export default NDSProvider;
@@ -5,5 +5,5 @@ type OverlayProps = FlexProps & {
5
5
  dark?: boolean;
6
6
  theme?: DefaultNDSThemeType;
7
7
  };
8
- declare const Overlay: React.FC<React.PropsWithChildren<OverlayProps>>;
8
+ declare const Overlay: React.FC<OverlayProps>;
9
9
  export default Overlay;
@@ -16,5 +16,5 @@ type PopperProps = {
16
16
  openAriaLabel?: string;
17
17
  closeAriaLabel?: string;
18
18
  };
19
- declare const Popper: React.FC<React.PropsWithChildren<PopperProps>>;
19
+ declare const Popper: React.FC<PopperProps>;
20
20
  export default Popper;
@@ -10,5 +10,5 @@ type RadioProps = NativeInputProps & SpaceProps & {
10
10
  defaultChecked?: boolean;
11
11
  error?: boolean;
12
12
  };
13
- declare const Radio: React.FC<React.PropsWithChildren<RadioProps>>;
13
+ declare const Radio: React.FC<RadioProps>;
14
14
  export default Radio;
@@ -7,5 +7,5 @@ type RangeContainerProps = {
7
7
  size?: ComponentSize;
8
8
  errorMessages?: (string | undefined)[];
9
9
  };
10
- declare const RangeContainer: React.FC<React.PropsWithChildren<RangeContainerProps>>;
10
+ declare const RangeContainer: React.FC<RangeContainerProps>;
11
11
  export default RangeContainer;
@@ -0,0 +1,3 @@
1
+ import * as React from "react";
2
+ declare function MenuList(props: any): React.JSX.Element;
3
+ export default MenuList;
@@ -1,64 +1,31 @@
1
1
  import React, { ReactNode } from "react";
2
- import { GroupBase } from "react-windowed-select";
3
- import type { MenuPlacement, MenuPosition, Props as SelectProps } from "react-select";
2
+ import Select from "react-select/base";
3
+ import { PropsValue } from "react-select";
4
+ import type { GroupBase, Props } from "react-select";
4
5
  import { ComponentSize } from "../NDSProvider/ComponentSizeContext";
5
- interface WindowedSelectProps extends SelectProps {
6
- windowThreshold?: number;
7
- }
8
- interface NDSOptionType {
6
+ export type NDSOptionValue = string | number | boolean | null;
7
+ export interface NDSOption {
9
8
  label: string;
10
- value: unknown;
9
+ value: NDSOptionValue;
11
10
  }
12
- interface CustomProps<Option, IsMulti extends boolean, Group extends GroupBase<Option>> {
13
- autocomplete?: SelectProps<Option, IsMulti, Group>["isSearchable"];
11
+ type CustomProps<IsMulti extends boolean, Group extends GroupBase<NDSOption>> = {
12
+ autocomplete?: Props<NDSOption, IsMulti, Group>["isSearchable"];
14
13
  labelText?: string;
14
+ size?: ComponentSize;
15
15
  requirementText?: string;
16
16
  helpText?: ReactNode;
17
- disabled?: SelectProps<Option, IsMulti, Group>["isDisabled"];
17
+ disabled?: Props<NDSOption, IsMulti, Group>["isDisabled"];
18
18
  errorMessage?: string;
19
19
  errorList?: string[];
20
- initialIsOpen?: SelectProps<Option, IsMulti, Group>["defaultMenuIsOpen"];
21
- multiselect?: SelectProps<Option, IsMulti, Group>["isMulti"];
20
+ initialIsOpen?: Props<NDSOption, IsMulti, Group>["defaultMenuIsOpen"];
21
+ multiselect?: Props<NDSOption, IsMulti, Group>["isMulti"];
22
22
  maxHeight?: string;
23
- size?: ComponentSize;
24
- error?: boolean;
25
- options: NDSOptionType[];
26
- onChange?: (newValue: unknown) => void;
27
- [key: string]: any;
28
- }
29
- export type NDSSelectProps<Option, IsMulti extends boolean, Group extends GroupBase<Option>> = Omit<WindowedSelectProps, "isSearchable" | "isDisabled" | "isMulti" | "defaultMenuIsOpen" | "defaultInputValue" | "options" | "onChange"> & CustomProps<Option, IsMulti, Group>;
30
- export declare const SelectDefaultProps: {
31
- autocomplete: boolean;
32
- disabled: any;
33
- defaultValue: any;
34
- error: any;
35
- errorMessage: any;
36
- errorList: any;
37
- labelText: any;
38
- helpText: any;
39
- noOptionsMessage: any;
40
- requirementText: any;
41
- id: any;
42
- initialIsOpen: any;
43
- maxHeight: string;
44
- menuPosition: MenuPosition;
45
- menuPlacement: MenuPlacement;
46
- multiselect: boolean;
47
- name: any;
48
- onBlur: any;
49
- onChange: any;
50
- placeholder: any;
51
- required: boolean;
52
- value: any;
53
- className: any;
54
- classNamePrefix: string;
55
- menuIsOpen: any;
56
- onMenuOpen: any;
57
- onMenuClose: any;
58
- onInputChange: any;
59
- components: any;
60
- closeMenuOnSelect: boolean;
23
+ defaultValue?: PropsValue<NDSOptionValue>;
24
+ value?: PropsValue<NDSOptionValue>;
25
+ options: NDSOption[];
26
+ onChange?: (newValue: PropsValue<NDSOptionValue>) => void;
27
+ windowThreshold?: number;
61
28
  };
62
- declare const ReactSelect: React.ForwardRefExoticComponent<Omit<Omit<WindowedSelectProps, "isDisabled" | "isMulti" | "isSearchable" | "onChange" | "options" | "defaultMenuIsOpen" | "defaultInputValue"> & CustomProps<unknown, boolean, GroupBase<unknown>>, "ref"> & React.RefAttributes<unknown>>;
63
- export declare const getOption: (options: NDSOptionType[], value: unknown) => unknown;
64
- export default ReactSelect;
29
+ export type NDSSelectProps<IsMulti extends boolean = boolean, Group extends GroupBase<NDSOption> = GroupBase<NDSOption>> = Omit<Props<NDSOption, IsMulti, Group>, keyof CustomProps<IsMulti, Group> | "isSearchable" | "isDisabled" | "defaultMenuIsOpen" | "isMulti"> & CustomProps<IsMulti, Group>;
30
+ declare const NDSSelect: React.ForwardRefExoticComponent<Omit<Props<NDSOption, boolean, GroupBase<NDSOption>>, "isDisabled" | "isMulti" | "isSearchable" | "defaultMenuIsOpen" | keyof CustomProps<IsMulti, Group>> & CustomProps<boolean, GroupBase<NDSOption>> & React.RefAttributes<Select<NDSOption, boolean, GroupBase<NDSOption>>>>;
31
+ export default NDSSelect;
@@ -110,4 +110,3 @@ export declare const UsingRefToControlFocus: {
110
110
  };
111
111
  };
112
112
  export declare const WithTopMenuPlacement: () => React.JSX.Element;
113
- export declare const WithCustomProps: () => React.JSX.Element;
@@ -0,0 +1,19 @@
1
+ import React from "react";
2
+ import { SelectOptionProps } from "./SelectOption";
3
+ import { NDSOption } from "./Select";
4
+ export declare const errorList: string[];
5
+ export declare const options: NDSOption[];
6
+ export declare const partnerCompanyName: {
7
+ value: string;
8
+ label: string;
9
+ }[];
10
+ export declare const wrappingOptions: {
11
+ value: string;
12
+ label: string;
13
+ }[];
14
+ export declare const PCNList: {
15
+ value: string;
16
+ label: string;
17
+ }[];
18
+ export declare const getPhotos: () => Promise<any>;
19
+ export declare const CustomOption: ({ children, ...props }: SelectOptionProps) => React.JSX.Element;
@@ -1,8 +1,10 @@
1
1
  import React from "react";
2
- export declare const SelectControl: (props: any) => React.JSX.Element;
3
- export declare const SelectMultiValue: (props: any) => React.JSX.Element;
4
- export declare const SelectClearIndicator: (props: any) => React.JSX.Element;
5
- export declare const SelectDropdownIndicator: (props: any) => React.JSX.Element;
6
- export declare const SelectMenu: (props: any) => React.JSX.Element;
7
- export declare const SelectContainer: (props: any) => React.JSX.Element;
8
- export declare const SelectInput: (props: any) => React.JSX.Element;
2
+ import { ClearIndicatorProps, ContainerProps, ControlProps, DropdownIndicatorProps, InputProps, MenuProps, MultiValueProps, GroupBase } from "react-select";
3
+ import { NDSOption } from "./Select";
4
+ export declare function SelectControl<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>>(props: ControlProps<Option, IsMulti, Group>): React.JSX.Element;
5
+ export declare function SelectMultiValue<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>>(props: MultiValueProps<Option, IsMulti, Group>): React.JSX.Element;
6
+ export declare function SelectClearIndicator<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>>(props: ClearIndicatorProps<Option, IsMulti, Group>): React.JSX.Element;
7
+ export declare function SelectDropdownIndicator<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>>(props: DropdownIndicatorProps<Option, IsMulti, Group>): React.JSX.Element;
8
+ export declare function SelectMenu<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>>(props: MenuProps<Option, IsMulti, Group>): React.JSX.Element;
9
+ export declare function SelectContainer<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>>(props: ContainerProps<Option, IsMulti, Group>): React.JSX.Element;
10
+ export declare function SelectInput<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>>(props: InputProps<Option, IsMulti, Group>): React.JSX.Element;
@@ -1,14 +1,15 @@
1
1
  import React from "react";
2
- import { OptionProps } from "react-windowed-select";
2
+ import { GroupBase, OptionProps } from "react-select";
3
3
  import { ComponentSize } from "../NDSProvider/ComponentSizeContext";
4
- type SelectOptionProps = {
4
+ import { NDSOption } from "./Select";
5
+ type StyledOptionProps = {
5
6
  isSelected: boolean;
6
7
  isFocused: boolean;
7
8
  size: ComponentSize;
8
9
  };
9
- export declare const StyledOption: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, SelectOptionProps, never>;
10
- interface CustomOptionProps extends OptionProps {
10
+ export declare const StyledOption: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, StyledOptionProps, never>;
11
+ export type SelectOptionProps<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>> = OptionProps<Option, IsMulti, Group> & {
11
12
  size?: ComponentSize;
12
- }
13
- export declare function SelectOption(props: CustomOptionProps): React.JSX.Element;
13
+ };
14
+ export declare function SelectOption<Option = NDSOption, IsMulti extends boolean = boolean, Group extends GroupBase<Option> = GroupBase<Option>>(props: SelectOptionProps<Option, IsMulti, Group>): React.JSX.Element;
14
15
  export {};
@@ -1,3 +1,3 @@
1
1
  export { SelectOption } from "./SelectOption";
2
- export { default as Select } from "./Select";
2
+ export { default as Select, type NDSOption, type NDSOptionValue } from "./Select";
3
3
  export * from "./SelectComponents";
@@ -0,0 +1,20 @@
1
+ import { Options, PropsValue } from "react-select";
2
+ import { NDSOption, NDSOptionValue } from "./Select";
3
+ export declare function calcOptionsLength(options: any): any;
4
+ export declare function flattenGroupedChildren(children: any): any;
5
+ export declare function isFocused({ props: { isFocused } }: {
6
+ props: {
7
+ isFocused: any;
8
+ };
9
+ }): boolean;
10
+ export declare function getCurrentIndex(children: any): number;
11
+ export declare function createGetHeight({ groupHeadingStyles, noOptionsMsgStyles, optionStyles, loadingMsgStyles }: {
12
+ groupHeadingStyles: any;
13
+ noOptionsMsgStyles: any;
14
+ optionStyles: any;
15
+ loadingMsgStyles: any;
16
+ }): (child: any) => any;
17
+ export declare function checkOptionsAreValid(options: Options<NDSOption>): void;
18
+ export declare function getOption(options: Options<NDSOption>, value: PropsValue<NDSOptionValue>): any;
19
+ export declare function getReactSelectValue(options: Options<NDSOption>, input: PropsValue<NDSOptionValue>): any;
20
+ export declare function extractValue(options: Options<NDSOption> | NDSOption, isMulti: boolean): NDSOptionValue[] | NDSOptionValue;
@@ -3,5 +3,5 @@ import { BoxProps } from "../Box/Box";
3
3
  type SummaryProps = Omit<BoxProps, "as"> & {
4
4
  breakpoint?: number | string;
5
5
  };
6
- declare const Summary: React.FC<React.PropsWithChildren<SummaryProps>>;
6
+ declare const Summary: React.FC<SummaryProps>;
7
7
  export default Summary;
@@ -3,5 +3,5 @@ type SummaryContextValue = {
3
3
  breakpoint: number;
4
4
  };
5
5
  export declare function useSummaryContext(): SummaryContextValue;
6
- export declare const SummaryContextProvider: React.FC<React.PropsWithChildren<SummaryContextValue>>;
6
+ export declare const SummaryContextProvider: React.FC<SummaryContextValue>;
7
7
  export {};
@@ -4,5 +4,5 @@ type SummaryItemProps = Omit<FlexProps, "as"> & {
4
4
  value: number | string;
5
5
  status: React.ReactNode;
6
6
  };
7
- declare const SummaryItem: React.FC<React.PropsWithChildren<SummaryItemProps>>;
7
+ declare const SummaryItem: React.FC<SummaryItemProps>;
8
8
  export default SummaryItem;
@@ -7,5 +7,5 @@ type SwitcherProps = {
7
7
  selected?: string;
8
8
  onChange?: (value: string) => void;
9
9
  };
10
- declare const Switcher: React.FC<React.PropsWithChildren<SwitcherProps>>;
10
+ declare const Switcher: React.FC<SwitcherProps>;
11
11
  export default Switcher;
@@ -6,5 +6,5 @@ type TableCellProps = {
6
6
  cellData?: object | React.ReactNode | boolean;
7
7
  compact?: boolean;
8
8
  };
9
- declare const TableCell: React.FC<React.PropsWithChildren<TableCellProps>>;
9
+ declare const TableCell: React.FC<TableCellProps>;
10
10
  export default TableCell;
@@ -8,5 +8,5 @@ type TabButtonProps = React.ComponentPropsWithRef<"button"> & {
8
8
  type TabProps = TabButtonProps & {
9
9
  label?: React.ReactNode;
10
10
  };
11
- declare const Tab: React.FC<React.PropsWithChildren<TabProps>>;
11
+ declare const Tab: React.FC<TabProps>;
12
12
  export default Tab;
@@ -6,5 +6,5 @@ type TabScrollIndicatorProps = {
6
6
  ariaLabelLeft?: string;
7
7
  ariaLabelRight?: string;
8
8
  };
9
- declare const TabScrollIndicator: React.FC<React.PropsWithChildren<TabScrollIndicatorProps>>;
9
+ declare const TabScrollIndicator: React.FC<TabScrollIndicatorProps>;
10
10
  export default TabScrollIndicator;
@@ -38,5 +38,5 @@ export declare const getTimeOptions: (interval: any, timeFormat: any, minTime: a
38
38
  value: string;
39
39
  label: string;
40
40
  }[];
41
- declare const TimePicker: React.FC<React.PropsWithChildren<TimePickerProps>>;
41
+ declare const TimePicker: React.FC<TimePickerProps>;
42
42
  export default TimePicker;
@@ -7,5 +7,5 @@ type ToggleButtonProps = React.ComponentPropsWithRef<"input"> & {
7
7
  name?: string;
8
8
  theme?: DefaultNDSThemeType;
9
9
  };
10
- declare const ToggleButton: React.FC<React.PropsWithChildren<ToggleButtonProps>>;
10
+ declare const ToggleButton: React.FC<ToggleButtonProps>;
11
11
  export default ToggleButton;
@@ -9,5 +9,5 @@ export type TooltipProps = {
9
9
  maxWidth?: string;
10
10
  children?: React.ReactNode;
11
11
  };
12
- declare const Tooltip: React.FC<React.PropsWithChildren<TooltipProps>>;
12
+ declare const Tooltip: React.FC<TooltipProps>;
13
13
  export default Tooltip;
@@ -6,5 +6,5 @@ type InlineValidationProps = SpaceProps & {
6
6
  errorList?: string[];
7
7
  children?: React.ReactNode;
8
8
  };
9
- declare const InlineValidation: React.FC<React.PropsWithChildren<InlineValidationProps>>;
9
+ declare const InlineValidation: React.FC<InlineValidationProps>;
10
10
  export default InlineValidation;
@@ -32,7 +32,7 @@ export { Overlay } from "./Overlay";
32
32
  export { Pagination } from "./Pagination";
33
33
  export { Radio, RadioGroup } from "./Radio";
34
34
  export { RangeContainer } from "./RangeContainer";
35
- export { Select, SelectClearIndicator, SelectContainer, SelectControl, SelectDropdownIndicator, SelectInput, SelectMenu, SelectMultiValue, SelectOption, } from "./Select";
35
+ export { Select, SelectClearIndicator, SelectContainer, SelectControl, SelectDropdownIndicator, SelectInput, SelectMenu, SelectMultiValue, SelectOption, type NDSOption, type NDSOptionValue, } from "./Select";
36
36
  export { SortingTable } from "./SortingTable";
37
37
  export { StatusIndicator, StatusIndicatorValues } from "./StatusIndicator";
38
38
  export type { StatusIndicatorType } from "./StatusIndicator";