1 | import * as React from 'react';
|
2 | import { PolymorphicProps, SlotComponentProps } from '../utils';
|
3 | export interface OptionGroupRootSlotPropsOverrides {
|
4 | }
|
5 | export interface OptionGroupLabelSlotPropsOverrides {
|
6 | }
|
7 | export interface OptionGroupListSlotPropsOverrides {
|
8 | }
|
9 | export interface OptionGroupOwnProps {
|
10 | |
11 |
|
12 |
|
13 | label?: React.ReactNode;
|
14 | className?: string;
|
15 | children?: React.ReactNode;
|
16 | |
17 |
|
18 |
|
19 |
|
20 | disabled?: boolean;
|
21 | |
22 |
|
23 |
|
24 |
|
25 |
|
26 | slots?: OptionGroupSlots;
|
27 | |
28 |
|
29 |
|
30 |
|
31 | slotProps?: {
|
32 | root?: SlotComponentProps<'li', OptionGroupRootSlotPropsOverrides, OptionGroupOwnerState>;
|
33 | label?: SlotComponentProps<'span', OptionGroupLabelSlotPropsOverrides, OptionGroupOwnerState>;
|
34 | list?: SlotComponentProps<'ul', OptionGroupListSlotPropsOverrides, OptionGroupOwnerState>;
|
35 | };
|
36 | }
|
37 | export interface OptionGroupSlots {
|
38 | |
39 |
|
40 |
|
41 |
|
42 | root?: React.ElementType;
|
43 | |
44 |
|
45 |
|
46 |
|
47 | label?: React.ElementType;
|
48 | |
49 |
|
50 |
|
51 |
|
52 | list?: React.ElementType;
|
53 | }
|
54 | export interface OptionGroupTypeMap<AdditionalProps = {}, RootComponentType extends React.ElementType = 'li'> {
|
55 | props: OptionGroupOwnProps & AdditionalProps;
|
56 | defaultComponent: RootComponentType;
|
57 | }
|
58 | export type OptionGroupProps<RootComponentType extends React.ElementType = OptionGroupTypeMap['defaultComponent']> = PolymorphicProps<OptionGroupTypeMap<{}, RootComponentType>, RootComponentType>;
|
59 | export type OptionGroupOwnerState = OptionGroupOwnProps;
|
60 | export type OptionGroupRootSlotProps = {
|
61 | children?: React.ReactNode;
|
62 | className?: string;
|
63 | ownerState: OptionGroupOwnerState;
|
64 | ref: React.Ref<HTMLLIElement>;
|
65 | };
|
66 | export type OptionGroupLabelSlotProps = {
|
67 | children?: React.ReactNode;
|
68 | className?: string;
|
69 | ownerState: OptionGroupOwnerState;
|
70 | };
|
71 | export type OptionGroupListSlotProps = {
|
72 | children?: React.ReactNode;
|
73 | className?: string;
|
74 | ownerState: OptionGroupOwnerState;
|
75 | };
|