@ufoui/core 0.0.4 → 0.0.5
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/README.md +9 -3
- package/assets/icons.d.ts +8 -0
- package/assets/index.d.ts +1 -0
- package/components/accordion/accordion.d.ts +24 -0
- package/components/accordion/accordionItem.d.ts +37 -0
- package/components/accordion/accordionItem.guards.d.ts +15 -0
- package/components/accordion/index.d.ts +2 -0
- package/components/avatar/avatar.d.ts +26 -29
- package/components/avatar/avatar.guards.d.ts +15 -0
- package/components/avatar/avatarGroup.d.ts +29 -0
- package/components/avatar/index.d.ts +2 -0
- package/components/badge/badge.d.ts +1 -1
- package/components/base/{boxBase/boxBase.d.ts → boxBase.d.ts} +32 -3
- package/components/base/{buttonBase/buttonBase.d.ts → buttonBase.d.ts} +1 -2
- package/components/base/{checkboxBase/checkboxBase.d.ts → checkboxBase.d.ts} +2 -3
- package/components/base/{dialogBase/dialog.d.ts → dialogBase.d.ts} +5 -8
- package/components/base/{fieldBase/fieldBase.d.ts → fieldBase.d.ts} +2 -2
- package/components/base/index.d.ts +6 -0
- package/components/base/textBase.d.ts +45 -0
- package/components/button/button.d.ts +1 -1
- package/components/checkbox/checkbox.d.ts +1 -1
- package/components/chip/chip.d.ts +1 -1
- package/components/collapse/collapse.d.ts +38 -0
- package/components/dialogs/bottomSheet.d.ts +23 -0
- package/components/dialogs/dialog.d.ts +21 -0
- package/components/{dialog → dialogs}/dialogActions.d.ts +1 -2
- package/components/{dialog → dialogs}/dialogTitle.d.ts +1 -2
- package/components/dialogs/drawer.d.ts +23 -0
- package/components/dialogs/index.d.ts +6 -0
- package/components/divider/divider.d.ts +1 -1
- package/components/divider/divider.guards.d.ts +1 -1
- package/components/fab/fab.d.ts +1 -1
- package/components/fields/dateField.d.ts +24 -0
- package/components/fields/dateTimeField.d.ts +24 -0
- package/components/fields/emailField.d.ts +24 -0
- package/components/fields/index.d.ts +11 -0
- package/components/fields/monthField.d.ts +24 -0
- package/components/fields/numberField.d.ts +24 -0
- package/components/fields/passwordField.d.ts +24 -0
- package/components/fields/phoneField.d.ts +24 -0
- package/components/fields/textField.d.ts +24 -0
- package/components/fields/timeField.d.ts +24 -0
- package/components/fields/urlField.d.ts +24 -0
- package/components/fields/weekField.d.ts +24 -0
- package/components/fieldset/fieldset.d.ts +2 -1
- package/components/iconButton/iconButton.d.ts +1 -1
- package/components/{article → layout}/article.d.ts +1 -1
- package/components/{aside → layout}/aside.d.ts +1 -1
- package/components/{content → layout}/content.d.ts +1 -1
- package/components/{div → layout}/div.d.ts +1 -1
- package/components/{flex → layout}/flex.d.ts +1 -1
- package/components/{footer → layout}/footer.d.ts +1 -1
- package/components/{grid → layout}/grid.d.ts +1 -1
- package/components/{header → layout}/header.d.ts +1 -1
- package/components/layout/index.d.ts +11 -0
- package/components/{main → layout}/main.d.ts +1 -1
- package/components/{nav → layout}/nav.d.ts +1 -1
- package/components/{section → layout}/section.d.ts +1 -1
- package/components/list/list.d.ts +8 -0
- package/components/{listItem → list}/listItem.d.ts +2 -3
- package/components/{listItem → list}/listItem.guards.d.ts +1 -1
- package/components/menu/menu.d.ts +2 -4
- package/components/menu/menu.guards.d.ts +1 -1
- package/components/menuItem/menuItem.d.ts +2 -3
- package/components/menuItem/menuItem.guards.d.ts +1 -1
- package/components/option/option.d.ts +1 -1
- package/components/option/option.guards.d.ts +1 -1
- package/components/progress/progress.d.ts +27 -0
- package/components/radio/radio.d.ts +1 -1
- package/components/radiogroup/radioGroup.d.ts +1 -1
- package/components/select/select.d.ts +1 -1
- package/components/switch/switch.d.ts +1 -2
- package/components/tabs/index.d.ts +2 -0
- package/components/tabs/tab.d.ts +37 -0
- package/components/tabs/tab.guards.d.ts +15 -0
- package/components/tabs/tabs.d.ts +7 -0
- package/components/toast/index.d.ts +2 -0
- package/components/toast/toast.d.ts +38 -0
- package/components/toast/toastViewport.d.ts +6 -0
- package/components/toggleButton/toggleButton.d.ts +1 -1
- package/components/toolbar/toolbar.d.ts +51 -0
- package/components/tooltip/tooltip.d.ts +1 -1
- package/components/typography/h1.d.ts +18 -0
- package/components/typography/h2.d.ts +18 -0
- package/components/typography/h3.d.ts +18 -0
- package/components/typography/h4.d.ts +18 -0
- package/components/typography/h5.d.ts +18 -0
- package/components/typography/h6.d.ts +18 -0
- package/components/typography/index.d.ts +9 -0
- package/components/typography/label.d.ts +18 -0
- package/components/typography/p.d.ts +18 -0
- package/components/typography/span.d.ts +18 -0
- package/context/index.d.ts +4 -0
- package/context/selectionContext.d.ts +31 -0
- package/context/themeContext.d.ts +2 -2
- package/hooks/index.d.ts +8 -0
- package/hooks/useAnimate.d.ts +2 -2
- package/hooks/useResizeObserver.d.ts +26 -0
- package/hooks/useSelection.d.ts +13 -0
- package/index.css +1 -1
- package/index.d.ts +26 -36
- package/index.mjs +3818 -3001
- package/internal/inlineTooltip/inlineTooltipManager.d.ts +1 -1
- package/package.json +1 -1
- package/utils/calculateFloatingPosition.d.ts +1 -1
- package/utils/color.d.ts +2 -92
- package/utils/controlStyle.d.ts +67 -0
- package/utils/generateMaterialColors.d.ts +1 -1
- package/utils/generateSchemes.d.ts +1 -1
- package/utils/index.d.ts +9 -0
- package/utils/{inputhMethod.d.ts → interactionMode.d.ts} +1 -1
- package/utils/toasts/ensureViewport.d.ts +2 -0
- package/utils/toasts/index.d.ts +1 -0
- package/utils/toasts/toast.d.ts +29 -0
- package/utils/toasts/toastStore.d.ts +11 -0
- package/utils/uniqueID.d.ts +14 -0
- package/utils/utils.d.ts +17 -29
- package/components/base/inlineBase/inlineBase.d.ts +0 -62
- package/components/dateInput/dateInput.d.ts +0 -2
- package/components/dateTimeInput/dateTimeInput.d.ts +0 -2
- package/components/emailInput/emailInput.d.ts +0 -2
- package/components/numberInput/numberInput.d.ts +0 -2
- package/components/telInput/telInput.d.ts +0 -2
- package/components/textField/textField.d.ts +0 -9
- package/components/timeInput/timeInput.d.ts +0 -2
- package/components/urlInput/urlInput.d.ts +0 -2
- /package/components/{dialog → dialogs}/dialogContent.d.ts +0 -0
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link DateField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category DateField
|
|
7
|
+
*/
|
|
8
|
+
export type DateFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Date field component used to enter date values.
|
|
11
|
+
*
|
|
12
|
+
* Use for selecting calendar dates in forms.
|
|
13
|
+
*
|
|
14
|
+
* @category DateField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <DateField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <DateField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const DateField: import('react').ForwardRefExoticComponent<DateFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link DateTimeField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category DateTimeField
|
|
7
|
+
*/
|
|
8
|
+
export type DateTimeFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Date and time field component used to enter combined date and time values.
|
|
11
|
+
*
|
|
12
|
+
* Use for scheduling and time-based form input.
|
|
13
|
+
*
|
|
14
|
+
* @category DateTimeField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <DateTimeField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <DateTimeField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const DateTimeField: import('react').ForwardRefExoticComponent<DateTimeFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link EmailField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category EmailField
|
|
7
|
+
*/
|
|
8
|
+
export type EmailFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Email field component used to enter email addresses.
|
|
11
|
+
*
|
|
12
|
+
* Use for collecting email contact information in forms.
|
|
13
|
+
*
|
|
14
|
+
* @category EmailField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <EmailField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <EmailField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const EmailField: import('react').ForwardRefExoticComponent<EmailFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * from './textField';
|
|
2
|
+
export * from './numberField';
|
|
3
|
+
export * from './emailField';
|
|
4
|
+
export * from './phoneField';
|
|
5
|
+
export * from './passwordField';
|
|
6
|
+
export * from './dateField';
|
|
7
|
+
export * from './dateTimeField';
|
|
8
|
+
export * from './timeField';
|
|
9
|
+
export * from './monthField';
|
|
10
|
+
export * from './weekField';
|
|
11
|
+
export * from './urlField';
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link MonthField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category MonthField
|
|
7
|
+
*/
|
|
8
|
+
export type MonthFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Month field component used to enter month and year values.
|
|
11
|
+
*
|
|
12
|
+
* Use for selecting calendar months in forms.
|
|
13
|
+
*
|
|
14
|
+
* @category MonthField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <MonthField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <MonthField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const MonthField: import('react').ForwardRefExoticComponent<MonthFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link NumberField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category NumberField
|
|
7
|
+
*/
|
|
8
|
+
export type NumberFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Number field component used to enter numeric values.
|
|
11
|
+
*
|
|
12
|
+
* Use for quantities, amounts, and other number-based input.
|
|
13
|
+
*
|
|
14
|
+
* @category NumberField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <NumberField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <NumberField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const NumberField: import('react').ForwardRefExoticComponent<NumberFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link PasswordField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category PasswordField
|
|
7
|
+
*/
|
|
8
|
+
export type PasswordFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Password field component used to enter secure text input.
|
|
11
|
+
*
|
|
12
|
+
* Use for authentication and protected form data.
|
|
13
|
+
*
|
|
14
|
+
* @category PasswordField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <PasswordField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <PasswordField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const PasswordField: import('react').ForwardRefExoticComponent<PasswordFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link PhoneField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category PhoneField
|
|
7
|
+
*/
|
|
8
|
+
export type PhoneFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Phone field component used to enter telephone numbers.
|
|
11
|
+
*
|
|
12
|
+
* Use for collecting contact phone information in forms.
|
|
13
|
+
*
|
|
14
|
+
* @category PhoneField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <PhoneField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <PhoneField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const PhoneField: import('react').ForwardRefExoticComponent<PhoneFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link TextField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category TextField
|
|
7
|
+
*/
|
|
8
|
+
export type TextFieldProps = Omit<FieldBaseProps, 'elementClass'>;
|
|
9
|
+
/**
|
|
10
|
+
* Text field component used to collect user input.
|
|
11
|
+
*
|
|
12
|
+
* Use for forms, search, and general data entry.
|
|
13
|
+
*
|
|
14
|
+
* @category TextField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <TextField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <TextField placeholder="Enter value" />
|
|
23
|
+
*/
|
|
24
|
+
export declare const TextField: import('react').ForwardRefExoticComponent<TextFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link TimeField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category TimeField
|
|
7
|
+
*/
|
|
8
|
+
export type TimeFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Time field component used to enter time values.
|
|
11
|
+
*
|
|
12
|
+
* Use for selecting hours and minutes in forms.
|
|
13
|
+
*
|
|
14
|
+
* @category TimeField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <TimeField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <TimeField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const TimeField: import('react').ForwardRefExoticComponent<TimeFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link UrlField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category UrlField
|
|
7
|
+
*/
|
|
8
|
+
export type UrlFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* URL field component used to enter web addresses.
|
|
11
|
+
*
|
|
12
|
+
* Use for collecting links and website references in forms.
|
|
13
|
+
*
|
|
14
|
+
* @category UrlField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <UrlField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <UrlField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const UrlField: import('react').ForwardRefExoticComponent<UrlFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FieldBaseProps } from '../base/fieldBase';
|
|
2
|
+
/**
|
|
3
|
+
* Props for {@link WeekField}.
|
|
4
|
+
* Extends {@link FieldBaseProps}.
|
|
5
|
+
*
|
|
6
|
+
* @category WeekField
|
|
7
|
+
*/
|
|
8
|
+
export type WeekFieldProps = Omit<FieldBaseProps, 'elementClass' | 'type'>;
|
|
9
|
+
/**
|
|
10
|
+
* Week field component used to enter week and year values.
|
|
11
|
+
*
|
|
12
|
+
* Use for selecting calendar weeks in forms.
|
|
13
|
+
*
|
|
14
|
+
* @category WeekField
|
|
15
|
+
* @function
|
|
16
|
+
* @param props - All field props inherited from {@link FieldBase}.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* <WeekField label="Label" />
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* <WeekField required />
|
|
23
|
+
*/
|
|
24
|
+
export declare const WeekField: import('react').ForwardRefExoticComponent<WeekFieldProps & import('react').RefAttributes<HTMLInputElement>>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { ElementFont, SurfaceColor } from '../../utils';
|
|
3
|
+
import { BoxBaseProps } from '../base/boxBase';
|
|
3
4
|
/**
|
|
4
5
|
* Props for {@link Fieldset}.
|
|
5
6
|
* Extends {@link BoxBaseProps} except for `elementClass` and `component`.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * from './article';
|
|
2
|
+
export * from './aside';
|
|
3
|
+
export * from './content';
|
|
4
|
+
export * from './div';
|
|
5
|
+
export * from './flex';
|
|
6
|
+
export * from './footer';
|
|
7
|
+
export * from './grid';
|
|
8
|
+
export * from './header';
|
|
9
|
+
export * from './main';
|
|
10
|
+
export * from './nav';
|
|
11
|
+
export * from './section';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { BoxBaseProps } from '../base/boxBase';
|
|
3
|
+
export interface ListProps extends Omit<BoxBaseProps, 'type'> {
|
|
4
|
+
type?: 'single' | 'multiple';
|
|
5
|
+
defaultValue?: string;
|
|
6
|
+
children: ReactNode;
|
|
7
|
+
}
|
|
8
|
+
export declare const List: ({ type, defaultValue, children, }: ListProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { default as React, HTMLProps, ReactNode } from 'react';
|
|
2
|
-
import { ElementDensity, ElementFocusEffect, ElementFont, ElementSelectedEffect, ElementShape, ElementTouchEffect } from '../../utils
|
|
3
|
-
import {
|
|
4
|
-
import { MenuVariant } from '../../index.ts';
|
|
2
|
+
import { ElementDensity, ElementFocusEffect, ElementFont, ElementSelectedEffect, ElementShape, ElementTouchEffect, SurfaceColor } from '../../utils';
|
|
3
|
+
import { MenuVariant } from '../menu/menu';
|
|
5
4
|
/**
|
|
6
5
|
* Visual variant of a ListItem.
|
|
7
6
|
*
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { default as React, ReactElement } from 'react';
|
|
2
|
-
import { ListItemInternalProps, ListItemProps } from '
|
|
2
|
+
import { ListItemInternalProps, ListItemProps } from './listItem';
|
|
3
3
|
export declare const IS_LIST_ITEM: unique symbol;
|
|
4
4
|
/**
|
|
5
5
|
* Type guard that checks whether a React node is a MenuItem component.
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { default as React, HTMLAttributes, ReactNode, RefObject } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { BorderColor, SurfaceColor } from '../../utils/color';
|
|
5
|
-
import { ElementFloatingMode } from '../../utils/calculateFloatingPosition';
|
|
2
|
+
import { MotionAnimation, MotionStyle } from '../../types';
|
|
3
|
+
import { BorderColor, ElementAlign, ElementBorder, ElementDensity, ElementElevation, ElementFloatingMode, ElementFocusEffect, ElementFont, ElementSelectedEffect, ElementShape, ElementTouchEffect, SurfaceColor } from '../../utils';
|
|
6
4
|
/**
|
|
7
5
|
* Visual style preset for the Menu component.
|
|
8
6
|
*
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { default as React, ReactElement } from 'react';
|
|
2
|
-
import { MenuInternalProps, MenuProps } from '
|
|
2
|
+
import { MenuInternalProps, MenuProps } from './menu';
|
|
3
3
|
export declare const IS_MENU: unique symbol;
|
|
4
4
|
/**
|
|
5
5
|
* Type guard that checks whether a React node is a Menu component.
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { default as React, HTMLProps, ReactNode } from 'react';
|
|
2
|
-
import { ElementDensity, ElementFocusEffect, ElementFont, ElementSelectedEffect, ElementShape, ElementTouchEffect } from '../../utils
|
|
3
|
-
import { MenuVariant } from '
|
|
4
|
-
import { SurfaceColor } from '../../utils/color';
|
|
2
|
+
import { ElementDensity, ElementFocusEffect, ElementFont, ElementSelectedEffect, ElementShape, ElementTouchEffect, SurfaceColor } from '../../utils';
|
|
3
|
+
import { MenuVariant } from '../menu/menu';
|
|
5
4
|
/**
|
|
6
5
|
* Visual variant of a MenuItem.
|
|
7
6
|
*
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { default as React, ReactElement } from 'react';
|
|
2
|
-
import { MenuItemInternalProps, MenuItemProps } from '
|
|
2
|
+
import { MenuItemInternalProps, MenuItemProps } from './menuItem';
|
|
3
3
|
export declare const IS_MENU_ITEM: unique symbol;
|
|
4
4
|
/**
|
|
5
5
|
* Type guard that checks whether a React node is a MenuItem component.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ForwardRefExoticComponent, RefAttributes } from 'react';
|
|
2
|
-
import { MenuItemInternalProps, MenuItemProps } from '
|
|
2
|
+
import { MenuItemInternalProps, MenuItemProps } from '../menuItem/menuItem';
|
|
3
3
|
export interface OptionProps extends Omit<MenuItemProps, 'type' | 'checked'> {
|
|
4
4
|
selected?: boolean;
|
|
5
5
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { default as React, ReactElement } from 'react';
|
|
2
2
|
import { OptionProps } from './option';
|
|
3
|
-
import { MenuItemInternalProps } from '
|
|
3
|
+
import { MenuItemInternalProps } from '../menuItem/menuItem';
|
|
4
4
|
export declare const IS_OPTION: unique symbol;
|
|
5
5
|
/**
|
|
6
6
|
* Type guard that checks whether a React node is an Option component.
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ElementSize, SemanticColor } from '../../utils';
|
|
3
|
+
import { BoxBaseProps } from '../base';
|
|
4
|
+
/**
|
|
5
|
+
* Props for {@link Progress}.
|
|
6
|
+
*
|
|
7
|
+
* @category Progress
|
|
8
|
+
*/
|
|
9
|
+
export interface ProgressProps extends Omit<BoxBaseProps, 'children'> {
|
|
10
|
+
variant?: 'linear' | 'circular';
|
|
11
|
+
value?: number;
|
|
12
|
+
min?: number;
|
|
13
|
+
max?: number;
|
|
14
|
+
color?: SemanticColor;
|
|
15
|
+
size?: ElementSize;
|
|
16
|
+
thickness?: number;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Visual progress indicator.
|
|
20
|
+
*
|
|
21
|
+
* @function
|
|
22
|
+
*
|
|
23
|
+
* @param props - Component props.
|
|
24
|
+
*
|
|
25
|
+
* @category Progress
|
|
26
|
+
*/
|
|
27
|
+
export declare const Progress: React.ForwardRefExoticComponent<ProgressProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { default as React, ReactNode } from 'react';
|
|
2
|
-
import { ElementAlign, ElementDensity, ElementElevation, ElementFocusEffect, ElementFont, ElementHoverEffect, ElementOutline, ElementPressedEffect, ElementSelectedEffect, ElementShape, ElementSize, ElementTextPlacement, ElementTouchEffect } from '../../utils
|
|
3
|
-
import { BorderColor, SemanticColor, SurfaceColor } from '../../utils/color';
|
|
2
|
+
import { BorderColor, ElementAlign, ElementDensity, ElementElevation, ElementFocusEffect, ElementFont, ElementHoverEffect, ElementOutline, ElementPressedEffect, ElementSelectedEffect, ElementShape, ElementSize, ElementTextPlacement, ElementTouchEffect, SemanticColor, SurfaceColor } from '../../utils';
|
|
4
3
|
/**
|
|
5
4
|
* Props for the Switch component.
|
|
6
5
|
*
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { IS_TAB } from './tab.guards';
|
|
3
|
+
/**
|
|
4
|
+
* Props for {@link Tab}.
|
|
5
|
+
*
|
|
6
|
+
* @category Tabs
|
|
7
|
+
*/
|
|
8
|
+
export interface TabProps {
|
|
9
|
+
/** Unique tab value. */
|
|
10
|
+
value: string;
|
|
11
|
+
/** Tab label. */
|
|
12
|
+
label: ReactNode;
|
|
13
|
+
/** Tab panel content. */
|
|
14
|
+
children: ReactNode;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Tab component containing both trigger and panel.
|
|
18
|
+
*
|
|
19
|
+
* Displays its content when selected.
|
|
20
|
+
*
|
|
21
|
+
* @function
|
|
22
|
+
*
|
|
23
|
+
* @category Tabs
|
|
24
|
+
*/
|
|
25
|
+
export declare const Tab: {
|
|
26
|
+
({ value, label, children }: TabProps): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
displayName: string;
|
|
28
|
+
/**
|
|
29
|
+
* Marks this component as a Tab for runtime type guards.
|
|
30
|
+
*
|
|
31
|
+
* Used internally to identify Tab elements via a shared Symbol.
|
|
32
|
+
* Not part of the public API.
|
|
33
|
+
*
|
|
34
|
+
* @internal
|
|
35
|
+
*/
|
|
36
|
+
[IS_TAB]: boolean;
|
|
37
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { default as React, ReactElement } from 'react';
|
|
2
|
+
import { TabProps } from './tab';
|
|
3
|
+
export declare const IS_TAB: unique symbol;
|
|
4
|
+
/**
|
|
5
|
+
* Type guard that checks whether a React node is a Tab component.
|
|
6
|
+
*
|
|
7
|
+
* Identifies Tab elements by the internal {@link IS_TAB} symbol
|
|
8
|
+
* attached to the component type.
|
|
9
|
+
*
|
|
10
|
+
* @param el - React node to test.
|
|
11
|
+
* @returns `true` if the node is a Tab element.
|
|
12
|
+
*
|
|
13
|
+
* @internal
|
|
14
|
+
*/
|
|
15
|
+
export declare function isTab(el: React.ReactNode): el is ReactElement<TabProps>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { BoxBaseProps } from '../base/boxBase';
|
|
3
|
+
export interface TabsProps extends BoxBaseProps {
|
|
4
|
+
defaultValue: string;
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
}
|
|
7
|
+
export declare const Tabs: ({ defaultValue, children, ...rest }: TabsProps) => import("react/jsx-runtime").JSX.Element;
|