@jackcrane/ui 0.1.14 → 0.1.16

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.
@@ -0,0 +1,34 @@
1
+ /**
2
+ * SegmentedControl component.
3
+ *
4
+ * @param {Object} props
5
+ * @param {Array<{ value: string, label: React.ReactNode, disabled?: boolean }>} props.options
6
+ * @param {string} props.value
7
+ * @param {string} props.defaultValue
8
+ * @param {(value: string) => void} props.onValueChange
9
+ * @param {boolean} props.allowEmpty
10
+ * @param {string} props.variant
11
+ * @param {string} props.size
12
+ * @param {boolean} props.disabled
13
+ * @param {boolean} props.chamfer
14
+ * @param {string} props.className
15
+ * @param {string} props.itemClassName
16
+ * @returns {JSX.Element}
17
+ */
18
+ export default function SegmentedControl({ options, value, defaultValue, onValueChange, allowEmpty, variant, size, disabled, chamfer, className, itemClassName, ...props }: {
19
+ options: Array<{
20
+ value: string;
21
+ label: React.ReactNode;
22
+ disabled?: boolean;
23
+ }>;
24
+ value: string;
25
+ defaultValue: string;
26
+ onValueChange: (value: string) => void;
27
+ allowEmpty: boolean;
28
+ variant: string;
29
+ size: string;
30
+ disabled: boolean;
31
+ chamfer: boolean;
32
+ className: string;
33
+ itemClassName: string;
34
+ }): JSX.Element;
package/dist/index.d.ts CHANGED
@@ -7,6 +7,7 @@ export { default as FileUpload } from "./components/FileUpload/file-upload";
7
7
  export { Loader } from "./components/Loader/loader";
8
8
  export { Radio, RadioGroup } from "./components/Radio/radio";
9
9
  export { default as Select } from "./components/Select/select";
10
+ export { default as SegmentedControl } from "./components/SegmentedControl/segmented-control";
10
11
  export { default as Dropdown } from "./components/Dropdown/dropdown";
11
12
  export { default as Hatch } from "./components/Hatch/hatch";
12
13
  export { toast } from "./components/Toast/toast";