etudes 14.3.0 → 14.4.1
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/build/components/Accordion.d.ts +9 -4
- package/build/components/Collection.d.ts +1 -1
- package/build/components/Dropdown.d.ts +18 -11
- package/build/etudes.js +2616 -2515
- package/build/etudes.umd.cjs +9 -9
- package/build/operators/Styled.d.ts +9 -0
- package/build/operators/Switch.d.ts +2 -2
- package/package.json +1 -1
|
@@ -12,7 +12,7 @@ export type AccordionSelection = Record<number, number[]>;
|
|
|
12
12
|
/**
|
|
13
13
|
* Type describing the data of each section in {@link Accordion}.
|
|
14
14
|
*/
|
|
15
|
-
export type
|
|
15
|
+
export type AccordionSectionProps<T> = Pick<CollectionProps<T>, 'isSelectionTogglable' | 'itemLength' | 'itemPadding' | 'items' | 'layout' | 'numSegments'> & {
|
|
16
16
|
/**
|
|
17
17
|
* Padding (in pixels) between the section header and the internal collection.
|
|
18
18
|
*/
|
|
@@ -37,7 +37,7 @@ export type AccordionItemProps<T> = CollectionItemProps<T>;
|
|
|
37
37
|
* Type describing the props of each `HeaderComponent` provided to
|
|
38
38
|
* {@link Accordion}.
|
|
39
39
|
*/
|
|
40
|
-
export type AccordionHeaderProps<I, S extends
|
|
40
|
+
export type AccordionHeaderProps<I, S extends AccordionSectionProps<I> = AccordionSectionProps<I>> = HTMLAttributes<HTMLElement> & {
|
|
41
41
|
/**
|
|
42
42
|
* The index of the corresponding section.
|
|
43
43
|
*/
|
|
@@ -61,7 +61,7 @@ export type AccordionHeaderProps<I, S extends AccordionSection<I> = AccordionSec
|
|
|
61
61
|
/**
|
|
62
62
|
* Type describing the props of {@link Accordion}.
|
|
63
63
|
*/
|
|
64
|
-
export type AccordionProps<I, S extends
|
|
64
|
+
export type AccordionProps<I, S extends AccordionSectionProps<I> = AccordionSectionProps<I>> = HTMLAttributes<HTMLDivElement> & {
|
|
65
65
|
/**
|
|
66
66
|
* Specifies if expanded sections should automatically collapse upon expanding
|
|
67
67
|
* another section.
|
|
@@ -204,9 +204,10 @@ export type AccordionProps<I, S extends AccordionSection<I> = AccordionSection<I
|
|
|
204
204
|
* @exports AccordionHeader Component for each section header.
|
|
205
205
|
* @exports AccordionExpandIcon Component for the expand icon of each section.
|
|
206
206
|
* @exports AccordionCollapseIcon Component for the collapse icon of each
|
|
207
|
+
* @exports AccordionSection Component for each section.
|
|
207
208
|
* @exports AccordionItem Component for each item in each section.
|
|
208
209
|
*/
|
|
209
|
-
export declare const Accordion: <I, S extends
|
|
210
|
+
export declare const Accordion: <I, S extends AccordionSectionProps<I> = AccordionSectionProps<I>>(props: Readonly<AccordionProps<I, S> & {
|
|
210
211
|
ref?: Ref<HTMLDivElement>;
|
|
211
212
|
}>) => ReactElement;
|
|
212
213
|
/**
|
|
@@ -230,6 +231,10 @@ export declare const AccordionCollapseIcon: {
|
|
|
230
231
|
({ children, ...props }: HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
231
232
|
displayName: string;
|
|
232
233
|
};
|
|
234
|
+
/**
|
|
235
|
+
* Component for each section in an {@link Accordion}.
|
|
236
|
+
*/
|
|
237
|
+
export declare const AccordionSection: ({ children, ...props }: HTMLAttributes<HTMLDivElement>) => import("react/jsx-runtime").JSX.Element;
|
|
233
238
|
/**
|
|
234
239
|
* Component for each item of each section of an {@link Accordion}.
|
|
235
240
|
*/
|
|
@@ -87,26 +87,33 @@ export type DropdownProps<T> = HTMLAttributes<HTMLDivElement> & CollectionProps<
|
|
|
87
87
|
* supports both horizontal and vertical orientations. Provide `items` and
|
|
88
88
|
* `ItemComponent` props to populate.
|
|
89
89
|
*
|
|
90
|
+
* @exports DropdownCollection Component containing the items.
|
|
91
|
+
* @exports DropdownItem Component for each item.
|
|
90
92
|
* @exports DropdownToggle Component for the toggle button.
|
|
91
|
-
* @exports DropdownExpandIcon Component for the expand icon.
|
|
92
93
|
* @exports DropdownCollapseIcon Component for the collapse icon.
|
|
93
|
-
* @exports
|
|
94
|
+
* @exports DropdownExpandIcon Component for the expand icon.
|
|
94
95
|
*/
|
|
95
96
|
export declare const Dropdown: <T>(props: Readonly<DropdownProps<T> & {
|
|
96
97
|
ref?: Ref<HTMLDivElement>;
|
|
97
98
|
}>) => ReactElement;
|
|
98
99
|
/**
|
|
99
|
-
* Component
|
|
100
|
+
* Component containing the items in a {@link Dropdown}.
|
|
100
101
|
*/
|
|
101
|
-
export declare const
|
|
102
|
-
|
|
102
|
+
export declare const DropdownCollection: <T>(props: Readonly<CollectionProps<T> & {
|
|
103
|
+
ref?: Ref<HTMLDivElement>;
|
|
104
|
+
}>) => ReactElement;
|
|
105
|
+
/**
|
|
106
|
+
* Component for each item in a {@link Dropdown}.
|
|
107
|
+
*/
|
|
108
|
+
export declare const DropdownItem: {
|
|
109
|
+
({ children, selectionMode, onActivateAt, ...props }: HTMLAttributes<HTMLDivElement | HTMLButtonElement> & Pick<CollectionProps<any>, "selectionMode" | "onActivateAt">): import("react/jsx-runtime").JSX.Element;
|
|
103
110
|
displayName: string;
|
|
104
111
|
};
|
|
105
112
|
/**
|
|
106
|
-
* Component for the
|
|
113
|
+
* Component for the toggle button of a {@link Dropdown}.
|
|
107
114
|
*/
|
|
108
|
-
export declare const
|
|
109
|
-
({ children,
|
|
115
|
+
export declare const DropdownToggle: {
|
|
116
|
+
({ children, ...props }: HTMLAttributes<HTMLButtonElement> & DropdownToggleProps): import("react/jsx-runtime").JSX.Element;
|
|
110
117
|
displayName: string;
|
|
111
118
|
};
|
|
112
119
|
/**
|
|
@@ -117,9 +124,9 @@ export declare const DropdownCollapseIcon: {
|
|
|
117
124
|
displayName: string;
|
|
118
125
|
};
|
|
119
126
|
/**
|
|
120
|
-
* Component for
|
|
127
|
+
* Component for the expand icon of a {@link Dropdown}.
|
|
121
128
|
*/
|
|
122
|
-
export declare const
|
|
123
|
-
({ children,
|
|
129
|
+
export declare const DropdownExpandIcon: {
|
|
130
|
+
({ children, style, ...props }: HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
124
131
|
displayName: string;
|
|
125
132
|
};
|