@firecms/ui 3.0.0-canary.120 → 3.0.0-canary.121

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.
@@ -1,32 +1,50 @@
1
1
  import * as React from "react";
2
- export type MultiSelectProps = {
2
+ import { ChangeEvent } from "react";
3
+ interface MultiSelectContextProps {
4
+ fieldValue?: string[];
5
+ onItemClick: (v: string) => void;
6
+ }
7
+ export declare const MultiSelectContext: React.Context<MultiSelectContextProps>;
8
+ /**
9
+ * Props for MultiSelect component
10
+ */
11
+ interface MultiSelectProps {
12
+ /**
13
+ * The modality of the popover. When set to true, interaction with outside elements
14
+ * will be disabled and only popover content will be visible to screen readers.
15
+ * Optional, defaults to false.
16
+ */
17
+ modalPopover?: boolean;
18
+ /**
19
+ * Additional class names to apply custom styles to the multi-select component.
20
+ * Optional, can be used to add custom styles.
21
+ */
22
+ className?: string;
3
23
  open?: boolean;
4
24
  name?: string;
5
25
  id?: string;
6
26
  onOpenChange?: (open: boolean) => void;
7
27
  value?: string[];
8
- containerClassName?: string;
9
- className?: string;
10
28
  inputClassName?: string;
11
- onMultiValueChange?: (updatedValue: string[]) => void;
29
+ onChange?: React.EventHandler<ChangeEvent<HTMLSelectElement>>;
30
+ onValueChange?: (updatedValue: string[]) => void;
12
31
  placeholder?: React.ReactNode;
13
- renderValue?: (values: string, index: number) => React.ReactNode;
14
- renderValues?: (values: string[]) => React.ReactNode;
15
32
  size?: "small" | "medium";
16
- label?: React.ReactNode;
33
+ useChips?: boolean;
34
+ label?: React.ReactNode | string;
17
35
  disabled?: boolean;
18
36
  error?: boolean;
19
37
  position?: "item-aligned" | "popper";
38
+ endAdornment?: React.ReactNode;
39
+ multiple?: boolean;
40
+ includeClear?: boolean;
20
41
  inputRef?: React.RefObject<HTMLButtonElement>;
21
- children?: React.ReactNode;
22
- };
23
- interface MultiSelectContextProps {
24
- fieldValue?: string[];
25
- setInputValue: (v: string) => void;
26
- onValueChangeInternal: (v: string) => void;
42
+ padding?: boolean;
43
+ invisible?: boolean;
44
+ children: React.ReactNode;
45
+ renderValues?: (values: string[]) => React.ReactNode;
27
46
  }
28
- export declare const MultiSelectContext: React.Context<MultiSelectContextProps>;
29
- export declare function MultiSelect({ value, open, onMultiValueChange, size, label, disabled, renderValue, renderValues, containerClassName, className, children, error }: MultiSelectProps): import("react/jsx-runtime").JSX.Element;
47
+ export declare const MultiSelect: React.ForwardRefExoticComponent<MultiSelectProps & React.RefAttributes<HTMLButtonElement>>;
30
48
  export interface MultiSelectItemProps {
31
49
  value: string;
32
50
  children?: React.ReactNode;
@@ -4,25 +4,21 @@ export type SelectProps = {
4
4
  name?: string;
5
5
  id?: string;
6
6
  onOpenChange?: (open: boolean) => void;
7
- value?: string | string[];
7
+ value?: string;
8
8
  className?: string;
9
9
  inputClassName?: string;
10
10
  onChange?: React.EventHandler<ChangeEvent<HTMLSelectElement>>;
11
11
  onValueChange?: (updatedValue: string) => void;
12
- onMultiValueChange?: (updatedValue: string[]) => void;
13
12
  placeholder?: React.ReactNode;
14
- renderValue?: (value: string, index: number) => React.ReactNode;
15
- renderValues?: (values: string[]) => React.ReactNode;
13
+ renderValue?: (value: string) => React.ReactNode;
16
14
  size?: "small" | "medium";
17
15
  label?: React.ReactNode | string;
18
16
  disabled?: boolean;
19
17
  error?: boolean;
20
18
  position?: "item-aligned" | "popper";
21
19
  endAdornment?: React.ReactNode;
22
- multiple?: boolean;
23
20
  inputRef?: React.RefObject<HTMLButtonElement>;
24
21
  padding?: boolean;
25
- includeFocusOutline?: boolean;
26
22
  invisible?: boolean;
27
23
  children?: React.ReactNode;
28
24
  };
@@ -1,4 +1,5 @@
1
- export declare function Separator({ orientation, decorative }: {
1
+ export declare function Separator({ orientation, decorative, className }: {
2
2
  orientation: "horizontal" | "vertical";
3
3
  decorative?: boolean;
4
+ className?: string;
4
5
  }): import("react/jsx-runtime").JSX.Element;
File without changes
@@ -26,7 +26,6 @@ export * from "./Markdown";
26
26
  export * from "./Menu";
27
27
  export * from "./Menubar";
28
28
  export * from "./MultiSelect";
29
- export * from "./NewMultiSelect";
30
29
  export * from "./Paper";
31
30
  export * from "./RadioGroup";
32
31
  export * from "./SearchBar";