@mechane-ai/elements 0.39.0 → 0.41.0
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/NOTICE +11 -19
- package/README.md +49 -25
- package/dist/accessibility-P89UG9-r.js +25 -0
- package/dist/agent.js +1 -0
- package/dist/ai.js +50 -44
- package/dist/{categorical-values-BECG-J6R.js → categorical-values-DnGR_pQx.js} +3 -3
- package/dist/{chart-frame-CJFnI39T.js → chart-frame-BsyI1Zc8.js} +58 -57
- package/dist/{chart-input-DwAobO8Y.js → chart-input-r4S3-QCT.js} +2 -2
- package/dist/chart-navigation-D7OkLdSx.js +119 -0
- package/dist/charts/cartesian.js +560 -583
- package/dist/charts/distribution.js +218 -218
- package/dist/charts/graph.js +86 -85
- package/dist/charts/hierarchy.js +4 -4
- package/dist/charts/matrix.js +148 -147
- package/dist/charts/timeline.js +77 -76
- package/dist/charts.js +2 -2
- package/dist/code-block-C4K1sM9O.js +255 -0
- package/dist/collections.js +828 -607
- package/dist/constants.stylex-BILvnwUk.js +84 -0
- package/dist/content/code.js +1 -1
- package/dist/content/diff.js +3 -3
- package/dist/content/link.js +1 -1
- package/dist/content/markdown.js +2 -2
- package/dist/content/tree.js +184 -77
- package/dist/{content-link-B3ObdyZY.js → content-link-CBDqSvgP.js} +1 -1
- package/dist/content.js +1 -1
- package/dist/control-styles-D3q_Qyxi.js +179 -0
- package/dist/csp.js +14 -1
- package/dist/feedback.js +1 -1
- package/dist/forms/dates.js +359 -245
- package/dist/forms-I-WMHTkr.js +139 -0
- package/dist/forms.js +3 -3
- package/dist/index.js +1 -1
- package/dist/layout.js +271 -241
- package/dist/navigation/commands.js +87 -76
- package/dist/{navigation-D2_sGy3C.js → navigation-CveMIuXI.js} +1 -1
- package/dist/navigation.js +2 -2
- package/dist/overlays.js +1 -1
- package/dist/packages/ai/src/message-action.d.ts +1 -1
- package/dist/packages/charts/src/chart-navigation.d.ts +18 -2
- package/dist/packages/charts/src/chart-surface.d.ts +23 -0
- package/dist/packages/charts/src/distribution/distribution-plot.d.ts +3 -2
- package/dist/packages/collections/src/data-table.d.ts +7 -2
- package/dist/packages/collections/src/index.d.ts +4 -1
- package/dist/packages/collections/src/query-controls.d.ts +18 -0
- package/dist/packages/collections/src/table-query.d.ts +64 -0
- package/dist/packages/collections/src/use-collection-controls.d.ts +3 -8
- package/dist/packages/content/src/pierre-theme.d.ts +0 -1
- package/dist/packages/core/src/actions.d.ts +15 -13
- package/dist/packages/core/src/copy-value.d.ts +3 -2
- package/dist/packages/core/src/disclosure.d.ts +14 -11
- package/dist/packages/feedback/src/notifications.d.ts +15 -15
- package/dist/packages/feedback/src/toast.d.ts +9 -3
- package/dist/packages/forms/src/combobox.d.ts +31 -41
- package/dist/packages/forms/src/dates/event-month.d.ts +17 -0
- package/dist/packages/forms/src/dates/index.d.ts +2 -0
- package/dist/packages/forms/src/field-styles.d.ts +0 -19
- package/dist/packages/forms/src/form-controls.d.ts +26 -24
- package/dist/packages/forms/src/forms.d.ts +17 -14
- package/dist/packages/forms/src/select-control.d.ts +6 -4
- package/dist/packages/forms/src/select.d.ts +14 -18
- package/dist/packages/forms/src/selection-state.d.ts +11 -0
- package/dist/packages/forms/src/selection-styles.d.ts +3 -0
- package/dist/packages/forms/src/selection.d.ts +21 -19
- package/dist/packages/foundations/src/agent/index.d.ts +2 -0
- package/dist/packages/foundations/src/control-state.d.ts +2 -3
- package/dist/packages/foundations/src/control-styles.d.ts +19 -0
- package/dist/packages/foundations/src/csp/index.d.ts +1 -1
- package/dist/packages/foundations/src/csp/provider.d.ts +3 -0
- package/dist/packages/foundations/src/style-composition.d.ts +4 -1
- package/dist/packages/layout/src/app-shell.d.ts +12 -1
- package/dist/packages/layout/src/index.d.ts +1 -1
- package/dist/packages/layout/src/navigation-rail.d.ts +15 -2
- package/dist/packages/layout/src/resizable.d.ts +2 -2
- package/dist/packages/layout/src/sidebar.d.ts +4 -3
- package/dist/packages/navigation/src/tab-styles.d.ts +1 -1
- package/dist/packages/navigation/src/tabs.d.ts +12 -10
- package/dist/packages/overlays/src/alert-dialog.d.ts +19 -13
- package/dist/packages/overlays/src/dialog.d.ts +39 -24
- package/dist/packages/overlays/src/drawer.d.ts +16 -26
- package/dist/packages/overlays/src/menu.d.ts +37 -44
- package/dist/packages/overlays/src/overlay-root.d.ts +10 -0
- package/dist/packages/overlays/src/popover.d.ts +11 -20
- package/dist/packages/overlays/src/preview.d.ts +6 -13
- package/dist/packages/overlays/src/tooltip.d.ts +12 -15
- package/dist/{pierre-diff-CaPsfQRo.js → pierre-diff-DJ3oOfPX.js} +5 -5
- package/dist/{src-DPRmO-JY.js → src-CNV1ewzb.js} +379 -407
- package/dist/{src-CSWIG_op.js → src-CQQvXi7a.js} +58 -81
- package/dist/{src-DWjAoOyd.js → src-D2OHco8V.js} +42 -41
- package/dist/src-DfOAlAd2.js +750 -0
- package/dist/src-na2DdkKI.js +561 -0
- package/dist/{src-C-Sx37kz.js → src-s3tWwnN4.js} +361 -518
- package/dist/styles.js +3 -0
- package/dist/{elements.css → styles2.css} +195 -97
- package/dist/tokens.js +3 -1
- package/dist/{tokens.stylex-CJbIDPB9.js → tokens.stylex-dF5CACEJ.js} +13 -93
- package/package.json +8 -9
- package/skills/elements-workspace/SKILL.md +12 -0
- package/dist/accessibility-C-aIZ1Yx.js +0 -15
- package/dist/chart-navigation-CBIeNtJq.js +0 -67
- package/dist/code-block-aC0Htt4N.js +0 -184
- package/dist/forms-BQQFas9g.js +0 -118
- package/dist/foundations.css +0 -7
- package/dist/packages/content/src/tree/pierre-tree.d.ts +0 -3
- package/dist/pierre-theme-BpNaWn1x.js +0 -126
- package/dist/pierre-tree-CYCRjdGG.js +0 -106
- package/dist/src-d7EAi61b.js +0 -617
- package/dist/src-nkgFDl-g.js +0 -1171
- package/dist/style-composition-uYlczSsB.js +0 -9
- package/styles.css +0 -2
|
@@ -1,55 +1,48 @@
|
|
|
1
|
-
import
|
|
1
|
+
import * as ComboboxSdk from '@ui-sdk/react/combobox';
|
|
2
2
|
import type { ComponentProps, ReactNode } from 'react';
|
|
3
3
|
import type { ControlDensity } from '../../foundations/src/control-density.ts';
|
|
4
|
-
import type { OpenStateProperties, ReadOnlyValueProperties, ValueStateProperties } from '../../foundations/src/control-state.ts';
|
|
5
4
|
import type { PlacementStyle } from '../../foundations/src/style-composition.ts';
|
|
5
|
+
import type { MultipleSelectionOf, SelectionProperties, SingleSelectionOf } from './selection-state.ts';
|
|
6
6
|
type InputQueryProperties<Change> = {
|
|
7
|
-
readonly
|
|
8
|
-
readonly
|
|
9
|
-
readonly
|
|
7
|
+
readonly query: string;
|
|
8
|
+
readonly defaultQuery?: never;
|
|
9
|
+
readonly onQueryChange: Change;
|
|
10
10
|
} | {
|
|
11
|
-
readonly
|
|
12
|
-
readonly
|
|
13
|
-
readonly
|
|
11
|
+
readonly query?: never;
|
|
12
|
+
readonly defaultQuery?: string;
|
|
13
|
+
readonly onQueryChange?: Change;
|
|
14
14
|
};
|
|
15
|
-
type ComboboxRootProps<Value
|
|
15
|
+
type ComboboxRootProps<Value> = (SelectionProperties<SingleSelectionOf<ComboboxSdk.ComboboxProps<Value>>> | SelectionProperties<MultipleSelectionOf<ComboboxSdk.ComboboxProps<Value, true>>>) & InputQueryProperties<NonNullable<ComboboxSdk.ComboboxProps<Value>['onQueryChange']>> & {
|
|
16
16
|
readonly density?: ControlDensity;
|
|
17
|
+
readonly items?: never;
|
|
17
18
|
};
|
|
18
|
-
type ComboboxInputGroupProps = ComponentProps<
|
|
19
|
+
type ComboboxInputGroupProps = ComponentProps<'div'> & {
|
|
19
20
|
readonly xstyle?: PlacementStyle;
|
|
20
21
|
};
|
|
21
|
-
type ComboboxLabelProps = ComponentProps<typeof
|
|
22
|
-
type
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
type
|
|
26
|
-
type ComboboxTriggerProps = ComponentProps<typeof BaseCombobox.Trigger>;
|
|
27
|
-
type ComboboxClearProps = ComponentProps<typeof BaseCombobox.Clear>;
|
|
28
|
-
type ComboboxPositionerProps = ComponentProps<typeof BaseCombobox.Positioner> & {
|
|
22
|
+
type ComboboxLabelProps = ComponentProps<typeof ComboboxSdk.ComboboxLabel>;
|
|
23
|
+
type ComboboxInputProps = ComponentProps<typeof ComboboxSdk.ComboboxInput>;
|
|
24
|
+
type ComboboxTriggerProps = ComponentProps<typeof ComboboxSdk.ComboboxTrigger>;
|
|
25
|
+
type ComboboxClearProps = ComponentProps<typeof ComboboxSdk.ComboboxClear>;
|
|
26
|
+
type ComboboxContentProps = ComponentProps<typeof ComboboxSdk.ComboboxContent> & {
|
|
29
27
|
readonly xstyle?: PlacementStyle;
|
|
30
28
|
};
|
|
31
|
-
type
|
|
32
|
-
type
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
type
|
|
36
|
-
type
|
|
37
|
-
type
|
|
38
|
-
type
|
|
39
|
-
type
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
type ComboboxChipRemoveProps = ComponentProps<typeof BaseCombobox.ChipRemove>;
|
|
43
|
-
declare function ComboboxRoot<Value, Multiple extends boolean | undefined = false, Item = Value>({ density, ...props }: ComboboxRootProps<Value, Multiple, Item>): ReactNode;
|
|
44
|
-
declare function ComboboxInputGroup({ className, style, xstyle, ...props }: ComboboxInputGroupProps): ReactNode;
|
|
29
|
+
type ComboboxListProps = ComponentProps<typeof ComboboxSdk.ComboboxList>;
|
|
30
|
+
type ComboboxItemProps = ComponentProps<typeof ComboboxSdk.ComboboxItem>;
|
|
31
|
+
type ComboboxIndicatorProps = ComponentProps<typeof ComboboxSdk.ComboboxItemIndicator>;
|
|
32
|
+
type ComboboxEmptyProps = ComponentProps<typeof ComboboxSdk.ComboboxEmpty>;
|
|
33
|
+
type ComboboxStatusProps = ComponentProps<typeof ComboboxSdk.ComboboxStatus>;
|
|
34
|
+
type ComboboxGroupLabelProps = ComponentProps<typeof ComboboxSdk.ComboboxGroupLabel>;
|
|
35
|
+
type ComboboxChipsProps = ComponentProps<typeof ComboboxSdk.ComboboxChips>;
|
|
36
|
+
type ComboboxChipProps = ComponentProps<typeof ComboboxSdk.ComboboxChip>;
|
|
37
|
+
type ComboboxChipRemoveProps = ComponentProps<typeof ComboboxSdk.ComboboxChipRemove>;
|
|
38
|
+
declare function ComboboxRoot<Value>(props: ComboboxRootProps<Value>): ReactNode;
|
|
39
|
+
declare function ComboboxInputGroup({ xstyle, ...props }: ComboboxInputGroupProps): ReactNode;
|
|
45
40
|
declare function ComboboxLabel({ className, style, ...props }: ComboboxLabelProps): ReactNode;
|
|
46
|
-
declare function ComboboxValue<Value>(props: ComboboxValueProps<Value>): ReactNode;
|
|
47
41
|
declare function ComboboxInput({ className, style, ...props }: ComboboxInputProps): ReactNode;
|
|
48
42
|
declare function ComboboxTrigger({ children, 'aria-label': label, className, style, ...props }: ComboboxTriggerProps): ReactNode;
|
|
49
43
|
declare function ComboboxClear({ children, 'aria-label': label, className, style, ...props }: ComboboxClearProps): ReactNode;
|
|
50
|
-
declare function
|
|
51
|
-
declare function
|
|
52
|
-
declare function ComboboxList<Item>({ className, style, ...props }: ComboboxListProps<Item>): ReactNode;
|
|
44
|
+
declare function ComboboxPopup({ className, style, xstyle, sideOffset, ...props }: ComboboxContentProps): ReactNode;
|
|
45
|
+
declare function ComboboxList({ className, style, ...props }: ComboboxListProps): ReactNode;
|
|
53
46
|
declare function ComboboxItem({ className, style, ...props }: ComboboxItemProps): ReactNode;
|
|
54
47
|
declare function ComboboxIndicator({ children, className, style, ...props }: ComboboxIndicatorProps): ReactNode;
|
|
55
48
|
declare function ComboboxEmpty({ className, style, ...props }: ComboboxEmptyProps): ReactNode;
|
|
@@ -65,20 +58,17 @@ export declare const Combobox: {
|
|
|
65
58
|
Input: typeof ComboboxInput;
|
|
66
59
|
Trigger: typeof ComboboxTrigger;
|
|
67
60
|
Clear: typeof ComboboxClear;
|
|
68
|
-
Portal: import("react").ForwardRefExoticComponent<Omit<import("@base-ui/react").ComboboxPortalProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
69
|
-
Positioner: typeof ComboboxPositioner;
|
|
70
61
|
Popup: typeof ComboboxPopup;
|
|
71
62
|
List: typeof ComboboxList;
|
|
72
63
|
Item: typeof ComboboxItem;
|
|
73
64
|
ItemIndicator: typeof ComboboxIndicator;
|
|
74
65
|
Empty: typeof ComboboxEmpty;
|
|
75
66
|
Status: typeof ComboboxStatus;
|
|
76
|
-
Group: import("
|
|
67
|
+
Group: import("@ui-sdk/react/primitive").PartComponent<ComboboxSdk.ComboboxPrimitive, "group", "div">;
|
|
77
68
|
GroupLabel: typeof ComboboxGroupLabel;
|
|
78
69
|
Chips: typeof ComboboxChips;
|
|
79
70
|
Chip: typeof ComboboxChip;
|
|
80
71
|
ChipRemove: typeof ComboboxChipRemove;
|
|
81
|
-
Value: typeof ComboboxValue;
|
|
82
|
-
Collection: typeof BaseCombobox.Collection;
|
|
72
|
+
Value: typeof ComboboxSdk.ComboboxValue;
|
|
83
73
|
};
|
|
84
74
|
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { CalendarDate } from './civil.ts';
|
|
3
|
+
export type EventMonthItem = {
|
|
4
|
+
readonly id: string;
|
|
5
|
+
readonly label: string;
|
|
6
|
+
};
|
|
7
|
+
export type EventMonthProps = {
|
|
8
|
+
readonly label: string;
|
|
9
|
+
readonly locale: string;
|
|
10
|
+
readonly timeZone: string;
|
|
11
|
+
readonly today: CalendarDate;
|
|
12
|
+
readonly selected: CalendarDate;
|
|
13
|
+
readonly weekStartsOn?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
14
|
+
readonly itemsByDate: ReadonlyMap<string, ReadonlyArray<EventMonthItem>>;
|
|
15
|
+
readonly onSelect: (date: CalendarDate) => void;
|
|
16
|
+
};
|
|
17
|
+
export declare function EventMonth({ label, locale, timeZone, today, selected, weekStartsOn, itemsByDate, onSelect, }: EventMonthProps): ReactNode;
|
|
@@ -11,3 +11,5 @@ export type { MonthPickerProps } from './month-picker.tsx';
|
|
|
11
11
|
export { MonthPicker } from './month-picker.tsx';
|
|
12
12
|
export type { MonthRangePickerProps, MonthRangePreset } from './month-range-picker.tsx';
|
|
13
13
|
export { MonthRangePicker } from './month-range-picker.tsx';
|
|
14
|
+
export type { EventMonthItem, EventMonthProps } from './event-month.tsx';
|
|
15
|
+
export { EventMonth } from './event-month.tsx';
|
|
@@ -6,25 +6,6 @@ export declare const fieldStyles: Readonly<{
|
|
|
6
6
|
readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
|
|
7
7
|
readonly overflowWrap: stylex.StyleXClassNameFor<"overflowWrap", "anywhere">;
|
|
8
8
|
}>;
|
|
9
|
-
readonly input: Readonly<{
|
|
10
|
-
readonly ':focus-visible': stylex.StyleXClassNameFor<":focus-visible", {
|
|
11
|
-
readonly outlineWidth: stylex.StyleXVar<string>;
|
|
12
|
-
readonly outlineStyle: "solid";
|
|
13
|
-
readonly outlineColor: stylex.StyleXVar<string>;
|
|
14
|
-
readonly outlineOffset: 1;
|
|
15
|
-
}>;
|
|
16
|
-
readonly ':is([data-invalid], [aria-invalid="true"])': stylex.StyleXClassNameFor<":is([data-invalid], [aria-invalid=\"true\"])", {
|
|
17
|
-
readonly borderColor: stylex.StyleXVar<string>;
|
|
18
|
-
}>;
|
|
19
|
-
readonly ':disabled': stylex.StyleXClassNameFor<":disabled", {
|
|
20
|
-
readonly color: stylex.StyleXVar<string>;
|
|
21
|
-
readonly backgroundColor: stylex.StyleXVar<string>;
|
|
22
|
-
readonly cursor: "not-allowed";
|
|
23
|
-
}>;
|
|
24
|
-
readonly '::placeholder': stylex.StyleXClassNameFor<"::placeholder", {
|
|
25
|
-
readonly color: stylex.StyleXVar<string>;
|
|
26
|
-
}>;
|
|
27
|
-
}>;
|
|
28
9
|
readonly compactTextarea: Readonly<{
|
|
29
10
|
readonly minHeight: stylex.StyleXClassNameFor<"minHeight", 80>;
|
|
30
11
|
readonly maxHeight: stylex.StyleXClassNameFor<"maxHeight", "30dvh">;
|
|
@@ -1,56 +1,58 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { Slider as
|
|
1
|
+
import { FieldControl as SdkFieldControl, FieldLabel as SdkFieldLabel, FieldLegend as SdkFieldLegend, FieldSet as SdkFieldSet } from '@ui-sdk/react/field';
|
|
2
|
+
import { InputGroup as SdkInputGroup } from '@ui-sdk/react/input';
|
|
3
|
+
import { NumberInputControl, NumberInputDecrement, NumberInputGroup, NumberInputIncrement, NumberInput as SdkNumberInput } from '@ui-sdk/react/number-input';
|
|
4
|
+
import { Slider as SdkSlider, SliderControl as SdkSliderControl, SliderIndicator as SdkSliderIndicator, SliderThumb as SdkSliderThumb, SliderTrack as SdkSliderTrack, SliderValue as SdkSliderValue } from '@ui-sdk/react/slider';
|
|
5
5
|
import type { ComponentProps, ReactNode } from 'react';
|
|
6
6
|
import type { ControlDensity } from '../../foundations/src/control-density.ts';
|
|
7
7
|
import type { ReadOnlyValueProperties, ValueStateProperties } from '../../foundations/src/control-state.ts';
|
|
8
8
|
import type { PlacementStyle } from '../../foundations/src/style-composition.ts';
|
|
9
9
|
import type { InputProps } from './forms.tsx';
|
|
10
|
-
type FieldsetRootProps = ComponentProps<typeof
|
|
10
|
+
type FieldsetRootProps = ComponentProps<typeof SdkFieldSet> & {
|
|
11
11
|
readonly xstyle?: PlacementStyle;
|
|
12
12
|
};
|
|
13
|
-
type FieldsetLegendProps = ComponentProps<typeof
|
|
14
|
-
type InputGroupRootProps = ComponentProps<
|
|
13
|
+
type FieldsetLegendProps = ComponentProps<typeof SdkFieldLegend>;
|
|
14
|
+
type InputGroupRootProps = ComponentProps<typeof SdkInputGroup> & {
|
|
15
15
|
readonly density?: ControlDensity;
|
|
16
16
|
readonly xstyle?: PlacementStyle;
|
|
17
17
|
};
|
|
18
18
|
type InputGroupAddonProps = ComponentProps<'span'>;
|
|
19
|
-
type InputGroupInputProps =
|
|
20
|
-
|
|
19
|
+
type InputGroupInputProps = InputProps & {
|
|
20
|
+
readonly density?: never;
|
|
21
|
+
};
|
|
22
|
+
type NumberFieldRootProps = Omit<ComponentProps<typeof SdkNumberInput>, 'value' | 'defaultValue' | 'onValueChange' | 'locale'> & (ValueStateProperties<number | null, NonNullable<ComponentProps<typeof SdkNumberInput>['onValueChange']>, number> | ReadOnlyValueProperties<number | null, NonNullable<ComponentProps<typeof SdkNumberInput>['onValueChange']>>) & {
|
|
21
23
|
readonly locale: string;
|
|
22
24
|
readonly density?: ControlDensity;
|
|
23
25
|
readonly xstyle?: PlacementStyle;
|
|
24
26
|
};
|
|
25
|
-
type NumberFieldGroupProps = ComponentProps<typeof
|
|
26
|
-
type NumberFieldInputProps = ComponentProps<typeof
|
|
27
|
-
type NumberFieldIncrementProps = ComponentProps<typeof
|
|
28
|
-
type NumberFieldDecrementProps = ComponentProps<typeof
|
|
29
|
-
type SliderRootProps<Value extends number |
|
|
27
|
+
type NumberFieldGroupProps = ComponentProps<typeof NumberInputGroup>;
|
|
28
|
+
type NumberFieldInputProps = ComponentProps<typeof NumberInputControl>;
|
|
29
|
+
type NumberFieldIncrementProps = ComponentProps<typeof NumberInputIncrement>;
|
|
30
|
+
type NumberFieldDecrementProps = ComponentProps<typeof NumberInputDecrement>;
|
|
31
|
+
type SliderRootProps<Value extends number | Array<number>> = Omit<ComponentProps<typeof SdkSlider<Value>>, 'value' | 'defaultValue' | 'onValueChange' | 'locale'> & ValueStateProperties<Value, NonNullable<ComponentProps<typeof SdkSlider<Value>>['onValueChange']>> & {
|
|
30
32
|
readonly locale: string;
|
|
31
33
|
readonly xstyle?: PlacementStyle;
|
|
32
34
|
};
|
|
33
|
-
type SliderControlProps = ComponentProps<typeof
|
|
34
|
-
type SliderTrackProps = ComponentProps<typeof
|
|
35
|
-
type SliderIndicatorProps = ComponentProps<typeof
|
|
36
|
-
type SliderThumbProps = ComponentProps<typeof
|
|
37
|
-
type SliderLabelProps = ComponentProps<typeof
|
|
38
|
-
type SliderValueProps = ComponentProps<typeof
|
|
39
|
-
type FilePickerProps = Omit<ComponentProps<typeof
|
|
35
|
+
type SliderControlProps = ComponentProps<typeof SdkSliderControl>;
|
|
36
|
+
type SliderTrackProps = ComponentProps<typeof SdkSliderTrack>;
|
|
37
|
+
type SliderIndicatorProps = ComponentProps<typeof SdkSliderIndicator>;
|
|
38
|
+
type SliderThumbProps = ComponentProps<typeof SdkSliderThumb>;
|
|
39
|
+
type SliderLabelProps = ComponentProps<typeof SdkFieldLabel>;
|
|
40
|
+
type SliderValueProps = ComponentProps<typeof SdkSliderValue>;
|
|
41
|
+
type FilePickerProps = Omit<ComponentProps<typeof SdkFieldControl>, 'type' | 'value' | 'defaultValue' | 'onValueChange'> & {
|
|
40
42
|
readonly density?: ControlDensity;
|
|
41
43
|
readonly xstyle?: PlacementStyle;
|
|
42
44
|
};
|
|
43
45
|
declare function FieldsetRoot({ className, style, xstyle, ...props }: FieldsetRootProps): ReactNode;
|
|
44
46
|
declare function FieldsetLegend({ className, style, ...props }: FieldsetLegendProps): ReactNode;
|
|
45
|
-
declare function InputGroupRoot({ density, xstyle, ...props }: InputGroupRootProps): ReactNode;
|
|
47
|
+
declare function InputGroupRoot({ density, className, style, xstyle, ...props }: InputGroupRootProps): ReactNode;
|
|
46
48
|
declare function InputGroupAddon(props: InputGroupAddonProps): ReactNode;
|
|
47
|
-
declare function InputGroupInput(
|
|
49
|
+
declare function InputGroupInput(props: InputGroupInputProps): ReactNode;
|
|
48
50
|
declare function NumberFieldRoot({ density, className, style, xstyle, ...props }: NumberFieldRootProps): ReactNode;
|
|
49
51
|
declare function NumberFieldGroup({ className, style, ...props }: NumberFieldGroupProps): ReactNode;
|
|
50
52
|
declare function NumberFieldInput({ className, style, ...props }: NumberFieldInputProps): ReactNode;
|
|
51
53
|
declare function NumberFieldIncrement({ children, 'aria-label': label, className, style, ...props }: NumberFieldIncrementProps): ReactNode;
|
|
52
54
|
declare function NumberFieldDecrement({ children, 'aria-label': label, className, style, ...props }: NumberFieldDecrementProps): ReactNode;
|
|
53
|
-
declare function SliderRoot<Value extends number |
|
|
55
|
+
declare function SliderRoot<Value extends number | Array<number>>({ className, style, xstyle, ...props }: SliderRootProps<Value>): ReactNode;
|
|
54
56
|
declare function SliderControl({ className, style, ...props }: SliderControlProps): ReactNode;
|
|
55
57
|
declare function SliderTrack({ className, style, ...props }: SliderTrackProps): ReactNode;
|
|
56
58
|
declare function SliderIndicator({ className, style, ...props }: SliderIndicatorProps): ReactNode;
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { Field as
|
|
2
|
-
import { Input as BaseInput } from '@base-ui/react/input';
|
|
1
|
+
import { Field as SdkField, FieldDescription as SdkFieldDescription, FieldError as SdkFieldError, FieldLabel as SdkFieldLabel } from '@ui-sdk/react/field';
|
|
3
2
|
import type { ComponentProps, ReactNode } from 'react';
|
|
4
3
|
import type { ControlDensity } from '../../foundations/src/control-density.ts';
|
|
5
4
|
import type { TextValueProperties } from '../../foundations/src/control-state.ts';
|
|
6
5
|
import type { PlacementStyle } from '../../foundations/src/style-composition.ts';
|
|
7
6
|
import type { TextareaAppearance } from './field-styles.ts';
|
|
8
|
-
type FieldRootProps = ComponentProps<typeof
|
|
7
|
+
type FieldRootProps = ComponentProps<typeof SdkField> & {
|
|
9
8
|
readonly xstyle?: PlacementStyle;
|
|
10
9
|
};
|
|
11
|
-
type FieldLabelProps = ComponentProps<typeof
|
|
12
|
-
type FieldDescriptionProps = ComponentProps<typeof
|
|
13
|
-
type FieldErrorProps = ComponentProps<typeof
|
|
14
|
-
type
|
|
15
|
-
|
|
16
|
-
readonly
|
|
10
|
+
type FieldLabelProps = ComponentProps<typeof SdkFieldLabel>;
|
|
11
|
+
type FieldDescriptionProps = ComponentProps<typeof SdkFieldDescription>;
|
|
12
|
+
type FieldErrorProps = ComponentProps<typeof SdkFieldError>;
|
|
13
|
+
type TextControlProps<Tag extends 'input' | 'textarea'> = Omit<ComponentProps<Tag>, 'value' | 'defaultValue' | 'onChange' | 'readOnly' | 'size' | 'onSelect' | 'onSubmit'> & TextValueProperties<string | number, NonNullable<ComponentProps<Tag>['onChange']>, (value: string) => void> & {
|
|
14
|
+
/** Keep credentials and other private text out of the UI SDK runtime. Password inputs always use this mode. */
|
|
15
|
+
readonly isSensitive?: boolean;
|
|
17
16
|
readonly xstyle?: PlacementStyle;
|
|
18
17
|
};
|
|
19
|
-
type
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
export type InputProps = TextControlProps<'input'> & {
|
|
19
|
+
readonly density?: ControlDensity;
|
|
20
|
+
};
|
|
21
|
+
type TextareaProps = TextControlProps<'textarea'> & {
|
|
22
22
|
readonly isCompact?: boolean;
|
|
23
23
|
readonly shouldGrow?: boolean;
|
|
24
24
|
readonly appearance?: TextareaAppearance;
|
|
@@ -33,6 +33,9 @@ export declare const Field: {
|
|
|
33
33
|
Description: typeof FieldDescription;
|
|
34
34
|
Error: typeof FieldError;
|
|
35
35
|
};
|
|
36
|
-
export declare function Input(
|
|
37
|
-
export declare function
|
|
36
|
+
export declare function Input(props: InputProps): ReactNode;
|
|
37
|
+
export declare function TextInput({ density, isEmbedded, isSensitive, className, style, xstyle, value, defaultValue, onValueChange, onChange, ...props }: InputProps & {
|
|
38
|
+
readonly isEmbedded?: boolean;
|
|
39
|
+
}): ReactNode;
|
|
40
|
+
export declare function Textarea({ isCompact, shouldGrow, appearance, isSensitive, className, style, xstyle, value, defaultValue, onValueChange, onChange, ...props }: TextareaProps): ReactNode;
|
|
38
41
|
export {};
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
+
import type { SelectProps } from '@ui-sdk/react/select';
|
|
1
2
|
import type { ComponentProps, ReactNode } from 'react';
|
|
2
3
|
import { Select } from './select.tsx';
|
|
4
|
+
import type { SingleSelectionOf } from './selection-state.ts';
|
|
3
5
|
export type SelectOption<Value extends string> = Pick<ComponentProps<typeof Select.Item>, 'disabled'> & {
|
|
4
6
|
readonly value: Value;
|
|
5
7
|
readonly label: string;
|
|
6
8
|
};
|
|
7
|
-
type SelectValueChange<Value extends string> = NonNullable<
|
|
9
|
+
type SelectValueChange<Value extends string> = NonNullable<SingleSelectionOf<SelectProps<Value>>['onValueChange']>;
|
|
8
10
|
type SelectControlValueProps<Value extends string> = {
|
|
9
11
|
readonly value: Value | null;
|
|
10
12
|
} & ({
|
|
@@ -14,13 +16,13 @@ type SelectControlValueProps<Value extends string> = {
|
|
|
14
16
|
readonly readOnly: true;
|
|
15
17
|
readonly onValueChange?: never;
|
|
16
18
|
});
|
|
17
|
-
type SelectFormProps<Value extends string> = Pick<
|
|
18
|
-
type SelectControlTriggerProps = Omit<ComponentProps<typeof Select.Trigger>, 'children' | 'render' | '
|
|
19
|
+
type SelectFormProps<Value extends string> = Pick<SelectProps<Value>, 'name' | 'form' | 'required' | 'autoComplete'>;
|
|
20
|
+
type SelectControlTriggerProps = Omit<ComponentProps<typeof Select.Trigger>, 'children' | 'render' | 'type' | 'value' | 'defaultValue' | 'name' | 'form' | 'autoComplete' | 'required' | 'readOnly' | 'aria-label' | 'className' | 'style'>;
|
|
19
21
|
export type SelectControlProps<Value extends string> = SelectControlValueProps<Value> & SelectFormProps<Value> & SelectControlTriggerProps & {
|
|
20
22
|
readonly label: string;
|
|
21
23
|
readonly items: ReadonlyArray<SelectOption<Value>>;
|
|
22
24
|
readonly placeholder?: string;
|
|
23
25
|
readonly align?: 'start' | 'end';
|
|
24
26
|
};
|
|
25
|
-
export declare function SelectControl<Value extends string>({ label, items, placeholder, align, value, readOnly, onValueChange, name, form, required, autoComplete,
|
|
27
|
+
export declare function SelectControl<Value extends string>({ label, items, placeholder, align, value, readOnly, onValueChange, disabled, id, name, form, required, autoComplete, ...triggerProps }: SelectControlProps<Value>): ReactNode;
|
|
26
28
|
export {};
|
|
@@ -1,32 +1,30 @@
|
|
|
1
|
-
import
|
|
1
|
+
import * as SelectSdk from '@ui-sdk/react/select';
|
|
2
2
|
import type { ComponentProps, ReactNode } from 'react';
|
|
3
3
|
import type { ControlDensity } from '../../foundations/src/control-density.ts';
|
|
4
|
-
import type { OpenStateProperties, ReadOnlyValueProperties, ValueStateProperties } from '../../foundations/src/control-state.ts';
|
|
5
4
|
import type { PlacementStyle } from '../../foundations/src/style-composition.ts';
|
|
5
|
+
import type { MultipleSelectionOf, SelectionProperties, SingleSelectionOf } from './selection-state.ts';
|
|
6
6
|
type SelectVariant = 'outline' | 'ghost';
|
|
7
|
-
type SelectRootProps<Value
|
|
8
|
-
type SelectTriggerProps = ComponentProps<typeof
|
|
7
|
+
type SelectRootProps<Value> = SelectionProperties<SingleSelectionOf<SelectSdk.SelectProps<Value>>> | SelectionProperties<MultipleSelectionOf<SelectSdk.SelectProps<Value, true>>>;
|
|
8
|
+
type SelectTriggerProps = ComponentProps<typeof SelectSdk.SelectTrigger> & {
|
|
9
9
|
readonly variant?: SelectVariant;
|
|
10
10
|
readonly density?: ControlDensity;
|
|
11
11
|
readonly xstyle?: PlacementStyle;
|
|
12
12
|
};
|
|
13
|
-
type SelectValueProps = ComponentProps<typeof
|
|
13
|
+
type SelectValueProps = ComponentProps<typeof SelectSdk.SelectValue> & {
|
|
14
14
|
readonly xstyle?: PlacementStyle;
|
|
15
15
|
};
|
|
16
|
-
type SelectIconProps = ComponentProps<
|
|
17
|
-
type
|
|
16
|
+
type SelectIconProps = ComponentProps<'span'>;
|
|
17
|
+
type SelectContentProps = ComponentProps<typeof SelectSdk.SelectContent> & {
|
|
18
18
|
readonly xstyle?: PlacementStyle;
|
|
19
19
|
};
|
|
20
|
-
type
|
|
21
|
-
type
|
|
22
|
-
type
|
|
23
|
-
|
|
24
|
-
declare function SelectRoot<Value, Multiple extends boolean | undefined = false>(props: SelectRootProps<Value, Multiple>): ReactNode;
|
|
20
|
+
type SelectItemProps = ComponentProps<typeof SelectSdk.SelectItem>;
|
|
21
|
+
type SelectItemTextProps = ComponentProps<typeof SelectSdk.SelectItemText>;
|
|
22
|
+
type SelectItemIndicatorProps = ComponentProps<typeof SelectSdk.SelectItemIndicator>;
|
|
23
|
+
declare function SelectRoot<Value>(props: SelectRootProps<Value>): ReactNode;
|
|
25
24
|
declare function SelectTrigger({ variant, density, className, style, xstyle, ...props }: SelectTriggerProps): ReactNode;
|
|
26
25
|
declare function SelectValue({ className, style, xstyle, ...props }: SelectValueProps): ReactNode;
|
|
27
|
-
declare function SelectIcon(
|
|
28
|
-
declare function
|
|
29
|
-
declare function SelectPopup({ className, style, ...props }: SelectPopupProps): ReactNode;
|
|
26
|
+
declare function SelectIcon(props: SelectIconProps): ReactNode;
|
|
27
|
+
declare function SelectPopup({ xstyle, className, style, sideOffset, ...props }: SelectContentProps): ReactNode;
|
|
30
28
|
declare function SelectItem({ className, style, ...props }: SelectItemProps): ReactNode;
|
|
31
29
|
declare function SelectItemText({ className, style, ...props }: SelectItemTextProps): ReactNode;
|
|
32
30
|
declare function SelectItemIndicator({ className, style, ...props }: SelectItemIndicatorProps): ReactNode;
|
|
@@ -35,10 +33,8 @@ export declare const Select: {
|
|
|
35
33
|
Trigger: typeof SelectTrigger;
|
|
36
34
|
Value: typeof SelectValue;
|
|
37
35
|
Icon: typeof SelectIcon;
|
|
38
|
-
Portal: import("react").ForwardRefExoticComponent<Omit<import("@base-ui/react").SelectPortalProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
39
|
-
Positioner: typeof SelectPositioner;
|
|
40
36
|
Popup: typeof SelectPopup;
|
|
41
|
-
List:
|
|
37
|
+
List: typeof SelectSdk.SelectList;
|
|
42
38
|
Item: typeof SelectItem;
|
|
43
39
|
ItemText: typeof SelectItemText;
|
|
44
40
|
ItemIndicator: typeof SelectItemIndicator;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { OpenStateProperties, ReadOnlyValueProperties, ValueStateProperties } from '../../foundations/src/control-state.ts';
|
|
2
|
+
type Multiple = Readonly<Record<'multiple', true>>;
|
|
3
|
+
export type SingleSelectionOf<Options> = Exclude<Options, Multiple>;
|
|
4
|
+
export type MultipleSelectionOf<Options> = Extract<Options, Multiple>;
|
|
5
|
+
export type SelectionProperties<Options extends {
|
|
6
|
+
readonly open?: unknown;
|
|
7
|
+
readonly onOpenChange?: unknown;
|
|
8
|
+
readonly value?: unknown;
|
|
9
|
+
readonly onValueChange?: unknown;
|
|
10
|
+
}> = Options & OpenStateProperties<NonNullable<Options['onOpenChange']>> & (ValueStateProperties<Exclude<Options['value'], undefined>, NonNullable<Options['onValueChange']>> | ReadOnlyValueProperties<Exclude<Options['value'], undefined>, NonNullable<Options['onValueChange']>>);
|
|
11
|
+
export {};
|
|
@@ -79,6 +79,9 @@ export declare const selectionStyles: Readonly<{
|
|
|
79
79
|
}>;
|
|
80
80
|
readonly option: Readonly<{
|
|
81
81
|
readonly display: stylex.StyleXClassNameFor<"display", "flex">;
|
|
82
|
+
readonly ':is([hidden])': stylex.StyleXClassNameFor<":is([hidden])", {
|
|
83
|
+
readonly display: "none";
|
|
84
|
+
}>;
|
|
82
85
|
readonly boxSizing: stylex.StyleXClassNameFor<"boxSizing", "border-box">;
|
|
83
86
|
readonly alignItems: stylex.StyleXClassNameFor<"alignItems", "center">;
|
|
84
87
|
readonly gap: stylex.StyleXClassNameFor<"gap", string>;
|
|
@@ -1,41 +1,43 @@
|
|
|
1
|
-
import { Checkbox as
|
|
2
|
-
import { Radio as
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { Toggle as BaseToggle } from '@base-ui/react/toggle';
|
|
6
|
-
import { ToggleGroup as BaseToggleGroup } from '@base-ui/react/toggle-group';
|
|
1
|
+
import { Checkbox as SdkCheckbox, CheckboxIndicator as SdkCheckboxIndicator } from '@ui-sdk/react/checkbox';
|
|
2
|
+
import { Radio as SdkRadio, RadioGroup as SdkRadioGroup, RadioIndicator as SdkRadioIndicator } from '@ui-sdk/react/radio';
|
|
3
|
+
import { Switch as SdkSwitch, SwitchThumb as SdkSwitchThumb } from '@ui-sdk/react/switch';
|
|
4
|
+
import { Toggle as SdkToggle, ToggleGroup as SdkToggleGroup } from '@ui-sdk/react/toggle';
|
|
7
5
|
import type { ComponentProps, ReactNode } from 'react';
|
|
8
6
|
import type { CheckedStateProperties, ReadOnlyValueProperties, ValueStateProperties } from '../../foundations/src/control-state.ts';
|
|
9
7
|
import type { PlacementStyle } from '../../foundations/src/style-composition.ts';
|
|
10
|
-
type
|
|
8
|
+
type CheckboxChange = NonNullable<ComponentProps<typeof SdkCheckbox>['onCheckedChange']>;
|
|
9
|
+
type RadioChange<Value extends string> = NonNullable<ComponentProps<typeof SdkRadioGroup<Value>>['onValueChange']>;
|
|
10
|
+
type RadioSelection<Value extends string> = (value: Value, details: Parameters<RadioChange<Value>>[1]) => void;
|
|
11
|
+
type CheckboxRootProps = Omit<ComponentProps<typeof SdkCheckbox>, 'checked' | 'defaultChecked' | 'onCheckedChange' | 'readOnly'> & CheckedStateProperties<(isChecked: boolean, details: Parameters<CheckboxChange>[1]) => void> & {
|
|
12
|
+
readonly indeterminate?: boolean;
|
|
11
13
|
readonly xstyle?: PlacementStyle;
|
|
12
14
|
};
|
|
13
|
-
type CheckboxIndicatorProps = ComponentProps<typeof
|
|
14
|
-
type RadioGroupRootProps<Value> = Omit<
|
|
15
|
+
type CheckboxIndicatorProps = ComponentProps<typeof SdkCheckboxIndicator>;
|
|
16
|
+
type RadioGroupRootProps<Value extends string> = Omit<ComponentProps<typeof SdkRadioGroup<Value>>, 'value' | 'defaultValue' | 'onValueChange'> & (ValueStateProperties<Value, RadioSelection<Value>> | ReadOnlyValueProperties<Value, RadioSelection<Value>>) & {
|
|
15
17
|
readonly xstyle?: PlacementStyle;
|
|
16
18
|
};
|
|
17
|
-
type RadioItemProps
|
|
19
|
+
type RadioItemProps = ComponentProps<typeof SdkRadio> & {
|
|
18
20
|
readonly xstyle?: PlacementStyle;
|
|
19
21
|
};
|
|
20
|
-
type RadioIndicatorProps = ComponentProps<typeof
|
|
21
|
-
type SwitchRootProps = Omit<ComponentProps<typeof
|
|
22
|
+
type RadioIndicatorProps = ComponentProps<typeof SdkRadioIndicator>;
|
|
23
|
+
type SwitchRootProps = Omit<ComponentProps<typeof SdkSwitch>, 'checked' | 'defaultChecked' | 'onCheckedChange' | 'readOnly'> & CheckedStateProperties<NonNullable<ComponentProps<typeof SdkSwitch>['onCheckedChange']>> & {
|
|
22
24
|
readonly xstyle?: PlacementStyle;
|
|
23
25
|
};
|
|
24
|
-
type SwitchThumbProps = ComponentProps<typeof
|
|
25
|
-
type ToggleGroupRootProps<Value extends string> = Omit<
|
|
26
|
+
type SwitchThumbProps = ComponentProps<typeof SdkSwitchThumb>;
|
|
27
|
+
type ToggleGroupRootProps<Value extends string> = Omit<ComponentProps<typeof SdkToggleGroup<Value>>, 'value' | 'defaultValue' | 'onValueChange'> & ValueStateProperties<ReadonlyArray<Value>, NonNullable<ComponentProps<typeof SdkToggleGroup<Value>>['onValueChange']>> & {
|
|
26
28
|
readonly xstyle?: PlacementStyle;
|
|
27
29
|
};
|
|
28
|
-
type ToggleItemProps<Value extends string> = Omit<
|
|
30
|
+
type ToggleItemProps<Value extends string> = Omit<ComponentProps<typeof SdkToggle>, 'value' | 'pressed' | 'defaultPressed' | 'onPressedChange'> & {
|
|
29
31
|
readonly value: Value;
|
|
30
32
|
};
|
|
31
|
-
declare function CheckboxRoot({ className, style, xstyle, ...props }: CheckboxRootProps): ReactNode;
|
|
33
|
+
declare function CheckboxRoot({ className, style, xstyle, indeterminate, checked, defaultChecked, onCheckedChange, ...props }: CheckboxRootProps): ReactNode;
|
|
32
34
|
declare function CheckboxIndicator({ children, className, style, ...props }: CheckboxIndicatorProps): ReactNode;
|
|
33
|
-
declare function RadioGroupRoot<Value>({ className, style, xstyle, ...props }: RadioGroupRootProps<Value>): ReactNode;
|
|
34
|
-
declare function RadioItem
|
|
35
|
+
declare function RadioGroupRoot<Value extends string>({ className, style, xstyle, onValueChange, ...props }: RadioGroupRootProps<Value>): ReactNode;
|
|
36
|
+
declare function RadioItem({ className, style, xstyle, ...props }: RadioItemProps): ReactNode;
|
|
35
37
|
declare function RadioIndicator({ className, style, ...props }: RadioIndicatorProps): ReactNode;
|
|
36
38
|
declare function SwitchRoot({ className, style, xstyle, ...props }: SwitchRootProps): ReactNode;
|
|
37
39
|
declare function SwitchThumb({ className, style, ...props }: SwitchThumbProps): ReactNode;
|
|
38
|
-
declare function ToggleGroupRoot<Value extends string>({ className, style, xstyle, ...props }: ToggleGroupRootProps<Value>): ReactNode;
|
|
40
|
+
declare function ToggleGroupRoot<Value extends string>({ className, style, xstyle, value, defaultValue, ...props }: ToggleGroupRootProps<Value>): ReactNode;
|
|
39
41
|
declare function ToggleItem<Value extends string>({ className, style, ...props }: ToggleItemProps<Value>): ReactNode;
|
|
40
42
|
export declare const Checkbox: {
|
|
41
43
|
Root: typeof CheckboxRoot;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import type { Dialog } from '@base-ui/react/dialog';
|
|
2
1
|
import type { ComponentProps } from 'react';
|
|
3
2
|
export type OpenStateProperties<Change> = {
|
|
4
|
-
readonly open:
|
|
3
|
+
readonly open: boolean;
|
|
5
4
|
readonly defaultOpen?: never;
|
|
6
5
|
readonly onOpenChange: Change;
|
|
7
6
|
} | {
|
|
8
7
|
readonly open?: never;
|
|
9
|
-
readonly defaultOpen?:
|
|
8
|
+
readonly defaultOpen?: boolean;
|
|
10
9
|
readonly onOpenChange?: Change;
|
|
11
10
|
};
|
|
12
11
|
export type ValueStateProperties<Value, Change, DefaultValue = Value> = {
|
|
@@ -36,6 +36,25 @@ export declare const controlStyles: Readonly<{
|
|
|
36
36
|
readonly color: stylex.StyleXClassNameFor<"color", string>;
|
|
37
37
|
readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
|
|
38
38
|
}>;
|
|
39
|
+
readonly textFieldState: Readonly<{
|
|
40
|
+
readonly ':focus-visible': stylex.StyleXClassNameFor<":focus-visible", {
|
|
41
|
+
readonly outlineWidth: stylex.StyleXVar<string>;
|
|
42
|
+
readonly outlineStyle: "solid";
|
|
43
|
+
readonly outlineColor: stylex.StyleXVar<string>;
|
|
44
|
+
readonly outlineOffset: 1;
|
|
45
|
+
}>;
|
|
46
|
+
readonly ':is([data-invalid], [aria-invalid="true"])': stylex.StyleXClassNameFor<":is([data-invalid], [aria-invalid=\"true\"])", {
|
|
47
|
+
readonly borderColor: stylex.StyleXVar<string>;
|
|
48
|
+
}>;
|
|
49
|
+
readonly ':disabled': stylex.StyleXClassNameFor<":disabled", {
|
|
50
|
+
readonly color: stylex.StyleXVar<string>;
|
|
51
|
+
readonly backgroundColor: stylex.StyleXVar<string>;
|
|
52
|
+
readonly cursor: "not-allowed";
|
|
53
|
+
}>;
|
|
54
|
+
readonly '::placeholder': stylex.StyleXClassNameFor<"::placeholder", {
|
|
55
|
+
readonly color: stylex.StyleXVar<string>;
|
|
56
|
+
}>;
|
|
57
|
+
}>;
|
|
39
58
|
readonly singleLineField: Readonly<{
|
|
40
59
|
readonly height: stylex.StyleXClassNameFor<"height", string>;
|
|
41
60
|
}>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { CSPProvider } from '
|
|
1
|
+
export { CSPProvider } from './provider.tsx';
|
|
2
2
|
export type { CSPProviderProps } from '@base-ui/react/csp-provider';
|
|
@@ -16,5 +16,8 @@ type CompiledStyles = {
|
|
|
16
16
|
type MergeStylesInput<State> = StyleProperties<State> & {
|
|
17
17
|
readonly styles: CompiledStyles;
|
|
18
18
|
};
|
|
19
|
-
export declare function mergeStyles<State>({ className, style, styles }: MergeStylesInput<State>):
|
|
19
|
+
export declare function mergeStyles<State>({ className, style, styles }: MergeStylesInput<State>): {
|
|
20
|
+
className: (state: State) => string;
|
|
21
|
+
style: (state: State) => CSSProperties;
|
|
22
|
+
};
|
|
20
23
|
export {};
|
|
@@ -1,7 +1,18 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
|
+
import type { NavigationRailMenuProps } from './navigation-rail-menu.tsx';
|
|
3
|
+
import type { NavigationRailProps } from './navigation-rail.tsx';
|
|
4
|
+
type RailFooter = {
|
|
5
|
+
readonly navigation?: Pick<NavigationRailProps, 'label' | 'links'>;
|
|
6
|
+
readonly menu: NavigationRailMenuProps;
|
|
7
|
+
} | {
|
|
8
|
+
readonly placeholder: {
|
|
9
|
+
readonly linkIcon?: ReactNode;
|
|
10
|
+
readonly menuIcon: ReactNode;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
2
13
|
type AppShellProps = {
|
|
3
14
|
readonly rail?: ReactNode;
|
|
4
|
-
readonly railFooter?:
|
|
15
|
+
readonly railFooter?: RailFooter;
|
|
5
16
|
readonly sidebarHeader?: ReactNode;
|
|
6
17
|
readonly sidebar: ReactNode;
|
|
7
18
|
readonly footer?: ReactNode;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { PageLayout, PageSection } from './page-layout.tsx';
|
|
2
2
|
export { AppShell } from './app-shell.tsx';
|
|
3
|
-
export { NavigationRail } from './navigation-rail.tsx';
|
|
3
|
+
export { NavigationRail, NavigationRailPlaceholder } from './navigation-rail.tsx';
|
|
4
4
|
export type { NavigationRailLink, NavigationRailProps } from './navigation-rail.tsx';
|
|
5
5
|
export { NavigationRailMenu } from './navigation-rail-menu.tsx';
|
|
6
6
|
export type { NavigationRailMenuProps } from './navigation-rail-menu.tsx';
|