@theroutingcompany/components 0.0.18 → 0.0.19
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 +32 -4
- package/dist/trc-components.es.js +12134 -8963
- package/dist/trc-components.es.js.map +1 -1
- package/dist/trc-components.umd.js +1009 -856
- package/dist/trc-components.umd.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +25 -20
- package/types/components/AlertDialog/AlertDialog.d.ts +3 -1
- package/types/components/Box/Box.d.ts +133 -0
- package/types/components/Breadcrumbs/Breadcrumbs.d.ts +3 -3
- package/types/components/Button/Button.d.ts +4 -4
- package/types/components/Checkbox/Checkbox.d.ts +3 -1
- package/types/components/Dialog/Dialog.d.ts +7 -3
- package/types/components/DropdownMenu/DropdownMenu.d.ts +19 -0
- package/types/components/Fieldset/Fieldset.d.ts +1 -1
- package/types/components/FileUpload/FileUpload.d.ts +2 -2
- package/types/components/Flex/Flex.d.ts +73 -0
- package/types/components/FormControl/FormControl.d.ts +2 -2
- package/types/components/IconButton/IconButton.d.ts +1 -1
- package/types/components/Input/NumberInput/NumberInput.d.ts +1 -1
- package/types/components/Input/TextArea/TextArea.d.ts +1 -1
- package/types/components/Input/TextInput/TextInput.d.ts +1 -1
- package/types/components/Label/Label.d.ts +1 -1
- package/types/components/MultiSelect/MultiSelect.d.ts +10 -10
- package/types/components/NavigationMenu/NavigationMenu.d.ts +6 -3
- package/types/components/Page/Page.d.ts +15 -1
- package/types/components/Paginator/Paginator.d.ts +1 -1
- package/types/components/Popover/Popover.d.ts +1 -1
- package/types/components/ReactAriaButton/ReactAriaButton.d.ts +1 -1
- package/types/components/index.d.ts +4 -0
- package/types/helpers/interactionStates.d.ts +7 -0
- package/types/helpers/tokenUtils.d.ts +19 -0
- package/types/helpers/typeHelpers.d.ts +4 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theroutingcompany/components",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.19",
|
|
4
4
|
"description": "The Routing Company Components",
|
|
5
5
|
"main": "./dist/trc-components.umd.js",
|
|
6
6
|
"module": "./dist/trc-components.es.js",
|
|
@@ -39,20 +39,21 @@
|
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"@internationalized/date": "3.1.0",
|
|
41
41
|
"@material-ui/icons": "^4.11.3",
|
|
42
|
-
"@radix-ui/react-accessible-icon": "^1.0.
|
|
43
|
-
"@radix-ui/react-alert-dialog": "^1.0.
|
|
44
|
-
"@radix-ui/react-checkbox": "^1.0.
|
|
45
|
-
"@radix-ui/react-collapsible": "^1.0.
|
|
46
|
-
"@radix-ui/react-dialog": "^1.0.
|
|
42
|
+
"@radix-ui/react-accessible-icon": "^1.0.2",
|
|
43
|
+
"@radix-ui/react-alert-dialog": "^1.0.3",
|
|
44
|
+
"@radix-ui/react-checkbox": "^1.0.3",
|
|
45
|
+
"@radix-ui/react-collapsible": "^1.0.2",
|
|
46
|
+
"@radix-ui/react-dialog": "^1.0.3",
|
|
47
|
+
"@radix-ui/react-dropdown-menu": "^2.0.4",
|
|
47
48
|
"@radix-ui/react-polymorphic": "^0.0.14",
|
|
48
|
-
"@radix-ui/react-popover": "^1.0.
|
|
49
|
-
"@radix-ui/react-radio-group": "^1.1.
|
|
50
|
-
"@radix-ui/react-select": "^1.2.
|
|
51
|
-
"@radix-ui/react-separator": "^1.0.
|
|
52
|
-
"@radix-ui/react-switch": "^1.0.
|
|
53
|
-
"@radix-ui/react-tabs": "^1.0.
|
|
54
|
-
"@radix-ui/react-toast": "^1.1.
|
|
55
|
-
"@radix-ui/react-toggle-group": "^1.0.
|
|
49
|
+
"@radix-ui/react-popover": "^1.0.5",
|
|
50
|
+
"@radix-ui/react-radio-group": "^1.1.2",
|
|
51
|
+
"@radix-ui/react-select": "^1.2.1",
|
|
52
|
+
"@radix-ui/react-separator": "^1.0.2",
|
|
53
|
+
"@radix-ui/react-switch": "^1.0.2",
|
|
54
|
+
"@radix-ui/react-tabs": "^1.0.3",
|
|
55
|
+
"@radix-ui/react-toast": "^1.1.3",
|
|
56
|
+
"@radix-ui/react-toggle-group": "^1.0.3",
|
|
56
57
|
"@radix-ui/react-tooltip": "^1.0.4",
|
|
57
58
|
"@react-aria/breadcrumbs": "3.5.0",
|
|
58
59
|
"@react-aria/button": "3.7.0",
|
|
@@ -90,14 +91,17 @@
|
|
|
90
91
|
"@react-types/select": "3.7.0",
|
|
91
92
|
"@tanstack/react-table": "^8.7.9",
|
|
92
93
|
"@theroutingcompany/design-tokens": "^0.0.3",
|
|
93
|
-
"
|
|
94
|
+
"csstype": "^3.1.1"
|
|
94
95
|
},
|
|
95
96
|
"peerDependencies": {
|
|
96
97
|
"@material-ui/icons": "^4.11.3",
|
|
97
|
-
"react": "^18.0.0",
|
|
98
|
-
"react-dom": "
|
|
99
|
-
"
|
|
100
|
-
"
|
|
98
|
+
"@types/react": "^18.0.0",
|
|
99
|
+
"@types/react-dom": "^18.0.0",
|
|
100
|
+
"csstype": "^3.1.1",
|
|
101
|
+
"react": "^18.2.0",
|
|
102
|
+
"react-dom": "^18.2.0",
|
|
103
|
+
"react-is": "^18.2.0",
|
|
104
|
+
"styled-components": "^5.3.9"
|
|
101
105
|
},
|
|
102
106
|
"devDependencies": {
|
|
103
107
|
"@babel/core": "^7.21.0",
|
|
@@ -122,11 +126,11 @@
|
|
|
122
126
|
"@typescript-eslint/parser": "^5.54.0",
|
|
123
127
|
"@vitejs/plugin-react": "^3.1.0",
|
|
124
128
|
"chromatic": "^6.17.1",
|
|
125
|
-
"csstype": "^3.1.1",
|
|
126
129
|
"eslint": "^8.35.0",
|
|
127
130
|
"eslint-config-prettier": "^8.6.0",
|
|
128
131
|
"eslint-plugin-jsx-a11y": "^6.7.1",
|
|
129
132
|
"eslint-plugin-react": "^7.32.2",
|
|
133
|
+
"eslint-plugin-react-hooks": "^4.6.0",
|
|
130
134
|
"eslint-plugin-storybook": "^0.6.11",
|
|
131
135
|
"postcss-styled-syntax": "^0.3.3",
|
|
132
136
|
"prettier": "^2.8.4",
|
|
@@ -135,6 +139,7 @@
|
|
|
135
139
|
"react-is": "^18.2.0",
|
|
136
140
|
"rimraf": "^4.1.2",
|
|
137
141
|
"storybook": "^7.0.0-beta.21",
|
|
142
|
+
"styled-components": "^5.3.9",
|
|
138
143
|
"stylelint": "^15.2.0",
|
|
139
144
|
"stylelint-config-prettier": "^9.0.5",
|
|
140
145
|
"stylelint-config-standard": "^30.0.1",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog';
|
|
3
3
|
import type { ComponentPropsWithRef } from 'react';
|
|
4
|
-
import { dialogWidths } from 'components/Dialog/Dialog';
|
|
4
|
+
import { dialogWidths } from '../../components/Dialog/Dialog';
|
|
5
5
|
type DialogWidth = keyof typeof dialogWidths;
|
|
6
6
|
type StyledContentProps = {
|
|
7
7
|
size?: DialogWidth;
|
|
@@ -15,4 +15,6 @@ export declare const AlertDialog: React.FC<AlertDialogPrimitive.AlertDialogProps
|
|
|
15
15
|
export declare const AlertDialogTrigger: React.ForwardRefExoticComponent<AlertDialogPrimitive.AlertDialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
16
16
|
export declare const AlertDialogAction: React.ForwardRefExoticComponent<AlertDialogPrimitive.AlertDialogActionProps & React.RefAttributes<HTMLButtonElement>>;
|
|
17
17
|
export declare const AlertDialogCancel: React.ForwardRefExoticComponent<AlertDialogPrimitive.AlertDialogCancelProps & React.RefAttributes<HTMLButtonElement>>;
|
|
18
|
+
/** AlertDialog Cancel Button positioned in top right with × */
|
|
19
|
+
export declare const AlertDialogCancelButton: ({ children, ...buttonProps }: AlertDialogPrimitive.AlertDialogCancelProps) => JSX.Element;
|
|
18
20
|
export {};
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import type { Property } from 'csstype';
|
|
2
|
+
import type { PropsWithChildren } from 'react';
|
|
3
|
+
import type { BorderRadiusToken, ElevationToken, RemoveVendorProperties, SizingToken, SpacingToken } from '../../helpers/tokenUtils';
|
|
4
|
+
export type BoxProps = PropsWithChildren<{
|
|
5
|
+
display?: 'block' | 'inline-block' | 'contents' | 'none' | 'inline';
|
|
6
|
+
position?: RemoveVendorProperties<Property.Position>;
|
|
7
|
+
top?: Property.Top<SpacingToken>;
|
|
8
|
+
bottom?: Property.Bottom<SpacingToken>;
|
|
9
|
+
left?: Property.Left<SpacingToken>;
|
|
10
|
+
right?: Property.Right<SpacingToken>;
|
|
11
|
+
zIndex?: Property.ZIndex;
|
|
12
|
+
/** width */
|
|
13
|
+
w?: RemoveVendorProperties<Property.Width<SizingToken>>;
|
|
14
|
+
/** min-width */
|
|
15
|
+
minW?: RemoveVendorProperties<Property.MinWidth<SizingToken>>;
|
|
16
|
+
/** max-width */
|
|
17
|
+
maxW?: RemoveVendorProperties<Property.MaxWidth<SizingToken>>;
|
|
18
|
+
/** height */
|
|
19
|
+
h?: RemoveVendorProperties<Property.Height<SizingToken>>;
|
|
20
|
+
/** min-height */
|
|
21
|
+
minH?: RemoveVendorProperties<Property.MinHeight<SizingToken>>;
|
|
22
|
+
/** max-height */
|
|
23
|
+
maxH?: RemoveVendorProperties<Property.MaxHeight<SizingToken>>;
|
|
24
|
+
/** margin */
|
|
25
|
+
m?: RemoveVendorProperties<Property.Margin<SpacingToken>>;
|
|
26
|
+
/** margin-top */
|
|
27
|
+
mt?: RemoveVendorProperties<Property.MarginTop<SpacingToken>>;
|
|
28
|
+
/** margin-bottom */
|
|
29
|
+
mb?: RemoveVendorProperties<Property.MarginBottom<SpacingToken>>;
|
|
30
|
+
/** margin-left */
|
|
31
|
+
ml?: RemoveVendorProperties<Property.MarginLeft<SpacingToken>>;
|
|
32
|
+
/** margin-right */
|
|
33
|
+
mr?: RemoveVendorProperties<Property.MarginRight<SpacingToken>>;
|
|
34
|
+
/** padding */
|
|
35
|
+
p?: RemoveVendorProperties<Property.Padding<SpacingToken>>;
|
|
36
|
+
/** padding-top */
|
|
37
|
+
pt?: RemoveVendorProperties<Property.PaddingTop<SpacingToken>>;
|
|
38
|
+
/** padding-right */
|
|
39
|
+
pr?: RemoveVendorProperties<Property.PaddingRight<SpacingToken>>;
|
|
40
|
+
/** padding-bottom */
|
|
41
|
+
pb?: RemoveVendorProperties<Property.PaddingBottom<SpacingToken>>;
|
|
42
|
+
/** padding-left */
|
|
43
|
+
pl?: RemoveVendorProperties<Property.PaddingLeft<SpacingToken>>;
|
|
44
|
+
borderRadius?: Property.BorderRadius<BorderRadiusToken>;
|
|
45
|
+
borderTopLeftRadius?: Property.BorderTopLeftRadius<BorderRadiusToken>;
|
|
46
|
+
borderTopRightRadius?: Property.BorderTopRightRadius<BorderRadiusToken>;
|
|
47
|
+
borderBottomLeftRadius?: Property.BorderBottomLeftRadius<BorderRadiusToken>;
|
|
48
|
+
borderBottomRightRadius?: Property.BorderBottomRightRadius<BorderRadiusToken>;
|
|
49
|
+
/** box-shadow */
|
|
50
|
+
elevation?: ElevationToken;
|
|
51
|
+
flexShrink?: RemoveVendorProperties<Property.FlexShrink>;
|
|
52
|
+
flexGrow?: RemoveVendorProperties<Property.FlexGrow>;
|
|
53
|
+
flexBasis?: RemoveVendorProperties<Property.FlexBasis<SizingToken>>;
|
|
54
|
+
flex?: Property.Flex<SizingToken>;
|
|
55
|
+
alignSelf?: Property.AlignSelf;
|
|
56
|
+
order?: Property.Order;
|
|
57
|
+
border?: Property.Border;
|
|
58
|
+
borderColor?: Property.BorderColor;
|
|
59
|
+
borderWidth?: Property.BorderWidth;
|
|
60
|
+
/** background */
|
|
61
|
+
bg?: Property.Background;
|
|
62
|
+
/** background-color */
|
|
63
|
+
bgColor?: Property.BackgroundColor;
|
|
64
|
+
opacity?: Property.Background;
|
|
65
|
+
color?: Property.Color;
|
|
66
|
+
overflow?: RemoveVendorProperties<Property.Overflow>;
|
|
67
|
+
}>;
|
|
68
|
+
export declare const Box: import("styled-components").StyledComponent<"div", any, {
|
|
69
|
+
display?: "none" | "inline" | "block" | "inline-block" | "contents" | undefined;
|
|
70
|
+
position?: "inherit" | "fixed" | "static" | "initial" | "revert" | "revert-layer" | "unset" | "absolute" | "relative" | "sticky" | undefined;
|
|
71
|
+
top?: Property.Top<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
72
|
+
bottom?: Property.Bottom<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
73
|
+
left?: Property.Left<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
74
|
+
right?: Property.Right<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
75
|
+
zIndex?: Property.ZIndex | undefined;
|
|
76
|
+
/** width */
|
|
77
|
+
w?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | "min-intrinsic" | undefined;
|
|
78
|
+
/** min-width */
|
|
79
|
+
minW?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | "min-intrinsic" | undefined;
|
|
80
|
+
/** max-width */
|
|
81
|
+
maxW?: "0" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "none" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | undefined;
|
|
82
|
+
/** height */
|
|
83
|
+
h?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "max-content" | "min-content" | undefined;
|
|
84
|
+
/** min-height */
|
|
85
|
+
minH?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | undefined;
|
|
86
|
+
/** max-height */
|
|
87
|
+
maxH?: "0" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "none" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | undefined;
|
|
88
|
+
/** margin */
|
|
89
|
+
m?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
90
|
+
/** margin-top */
|
|
91
|
+
mt?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
92
|
+
/** margin-bottom */
|
|
93
|
+
mb?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
94
|
+
/** margin-left */
|
|
95
|
+
ml?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
96
|
+
/** margin-right */
|
|
97
|
+
mr?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
98
|
+
/** padding */
|
|
99
|
+
p?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
100
|
+
/** padding-top */
|
|
101
|
+
pt?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
102
|
+
/** padding-right */
|
|
103
|
+
pr?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
104
|
+
/** padding-bottom */
|
|
105
|
+
pb?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
106
|
+
/** padding-left */
|
|
107
|
+
pl?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
108
|
+
borderRadius?: Property.BorderRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
109
|
+
borderTopLeftRadius?: Property.BorderTopLeftRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
110
|
+
borderTopRightRadius?: Property.BorderTopRightRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
111
|
+
borderBottomLeftRadius?: Property.BorderBottomLeftRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
112
|
+
borderBottomRightRadius?: Property.BorderBottomRightRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
113
|
+
/** box-shadow */
|
|
114
|
+
elevation?: ElevationToken | undefined;
|
|
115
|
+
flexShrink?: (string & {}) | "inherit" | "initial" | "revert" | "revert-layer" | "unset" | (number & {}) | undefined;
|
|
116
|
+
flexGrow?: (string & {}) | "inherit" | "initial" | "revert" | "revert-layer" | "unset" | (number & {}) | undefined;
|
|
117
|
+
flexBasis?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "content" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "max-content" | "min-content" | undefined;
|
|
118
|
+
flex?: Property.Flex<"0" | "1000" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500"> | undefined;
|
|
119
|
+
alignSelf?: Property.AlignSelf | undefined;
|
|
120
|
+
order?: Property.Order | undefined;
|
|
121
|
+
border?: Property.Border<0 | (string & {})> | undefined;
|
|
122
|
+
borderColor?: Property.BorderColor | undefined;
|
|
123
|
+
borderWidth?: Property.BorderWidth<0 | (string & {})> | undefined;
|
|
124
|
+
/** background */
|
|
125
|
+
bg?: Property.Background<0 | (string & {})> | undefined;
|
|
126
|
+
/** background-color */
|
|
127
|
+
bgColor?: Property.BackgroundColor | undefined;
|
|
128
|
+
opacity?: Property.Background<0 | (string & {})> | undefined;
|
|
129
|
+
color?: Property.Color | undefined;
|
|
130
|
+
overflow?: "auto" | "hidden" | (string & {}) | "inherit" | "clip" | "initial" | "revert" | "revert-layer" | "unset" | "scroll" | "visible" | undefined;
|
|
131
|
+
} & {
|
|
132
|
+
children?: import("react").ReactNode;
|
|
133
|
+
}, never>;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { type ReactNode } from 'react';
|
|
2
2
|
import { type AriaBreadcrumbItemProps, type AriaBreadcrumbsProps } from '@react-aria/breadcrumbs';
|
|
3
|
-
import type { RenameMisprefixedProps } from 'helpers/typeHelpers';
|
|
3
|
+
import type { RenameMisprefixedProps } from '../../helpers/typeHelpers';
|
|
4
4
|
export declare const BreadcrumbListItem: import("styled-components").StyledComponent<"li", any, {}, never>;
|
|
5
5
|
export declare const BreadcrumbLink: import("styled-components").StyledComponent<"a", any, {}, never>;
|
|
6
6
|
export declare const Breadcrumbs: import("react").ForwardRefExoticComponent<AriaBreadcrumbsProps & {
|
|
7
7
|
children?: ReactNode;
|
|
8
8
|
} & import("react").RefAttributes<HTMLOListElement>>;
|
|
9
9
|
export type BreadcrumbItemProps<ExtraProps = unknown> = RenameMisprefixedProps<AriaBreadcrumbItemProps, 'is', 'isDisabled'> & {
|
|
10
|
-
LinkComponent
|
|
10
|
+
LinkComponent?: JSX.Element | "a";
|
|
11
11
|
href?: string | undefined;
|
|
12
12
|
} & ExtraProps;
|
|
13
13
|
export declare const BreadcrumbItem: import("react").ForwardRefExoticComponent<Omit<AriaBreadcrumbItemProps, "isDisabled"> & {
|
|
14
14
|
disabled?: boolean | undefined;
|
|
15
15
|
} & {
|
|
16
|
-
LinkComponent
|
|
16
|
+
LinkComponent?: "a" | JSX.Element | undefined;
|
|
17
17
|
href?: string | undefined;
|
|
18
18
|
} & import("react").RefAttributes<HTMLAnchorElement>>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { type PropsWithChildren } from 'react';
|
|
1
|
+
import { type ComponentPropsWithoutRef, type PropsWithChildren } from 'react';
|
|
2
2
|
import { type AriaButtonProps } from '@react-aria/button';
|
|
3
|
-
import type { RenameMisprefixedProps } from 'helpers';
|
|
3
|
+
import type { Prettify, RenameMisprefixedProps } from '../../helpers';
|
|
4
4
|
type Variant = 'primary' | 'secondary' | 'danger' | 'inverse';
|
|
5
5
|
type Size = 'small' | 'large';
|
|
6
6
|
type ButtonDesignProps = {
|
|
@@ -20,8 +20,8 @@ export type ButtonBaseProps = {
|
|
|
20
20
|
paddingSize: Size;
|
|
21
21
|
};
|
|
22
22
|
type ReactAriaProps = RenameMisprefixedProps<AriaButtonProps, 'is', 'isDisabled'>;
|
|
23
|
-
export type ButtonProps = PropsWithChildren<ButtonDesignProps
|
|
23
|
+
export type ButtonProps = Prettify<PropsWithChildren<ButtonDesignProps & ReactAriaProps & {
|
|
24
24
|
onClick?: ReactAriaProps['onPress'];
|
|
25
|
-
}
|
|
25
|
+
} & Pick<ComponentPropsWithoutRef<'button'>, 'form'>>>;
|
|
26
26
|
export declare const Button: import("react").ForwardRefExoticComponent<ButtonProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
27
27
|
export {};
|
|
@@ -4,4 +4,6 @@ export type CheckedState = CheckboxPrimitive.CheckedState;
|
|
|
4
4
|
export type CheckboxProps = Omit<CheckboxPrimitive.CheckboxProps, 'defaultChecked'> & {
|
|
5
5
|
invalid?: boolean;
|
|
6
6
|
};
|
|
7
|
-
export declare
|
|
7
|
+
export declare const Checkbox: import("react").ForwardRefExoticComponent<Omit<CheckboxPrimitive.CheckboxProps, "defaultChecked"> & {
|
|
8
|
+
invalid?: boolean | undefined;
|
|
9
|
+
} & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import * as DialogPrimitive from '@radix-ui/react-dialog';
|
|
2
2
|
import type { ComponentPropsWithRef } from 'react';
|
|
3
|
-
export declare const
|
|
4
|
-
export declare const contentShow: import("styled-components").Keyframes;
|
|
3
|
+
export declare const overlayStyles: import("styled-components").FlattenSimpleInterpolation;
|
|
5
4
|
export declare const dialogWidths: {
|
|
6
5
|
readonly small: "360px";
|
|
7
6
|
readonly medium: "540px";
|
|
@@ -11,12 +10,17 @@ type DialogWidth = keyof typeof dialogWidths;
|
|
|
11
10
|
type StyledContentProps = {
|
|
12
11
|
size?: DialogWidth;
|
|
13
12
|
};
|
|
13
|
+
export declare const dialogContentStyles: import("styled-components").FlattenSimpleInterpolation;
|
|
14
14
|
export type DialogContentProps = StyledContentProps & DialogPrimitive.DialogContentProps & ComponentPropsWithRef<'div'>;
|
|
15
15
|
export declare function DialogContent({ children, size, ...props }: DialogContentProps): JSX.Element;
|
|
16
|
+
export declare const dialogTitleStyles: string;
|
|
16
17
|
export declare const DialogTitle: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DialogPrimitive.DialogTitleProps & import("react").RefAttributes<HTMLHeadingElement>>, any, {}, never>;
|
|
18
|
+
export declare const dialogDescriptionStyles: import("styled-components").FlattenSimpleInterpolation;
|
|
17
19
|
export declare const DialogDescription: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DialogPrimitive.DialogDescriptionProps & import("react").RefAttributes<HTMLParagraphElement>>, any, {}, never>;
|
|
18
20
|
export declare const DialogFooter: import("styled-components").StyledComponent<"footer", any, {}, never>;
|
|
19
|
-
export declare const
|
|
21
|
+
export declare const dialogCloseButtonStyles: import("styled-components").FlattenSimpleInterpolation;
|
|
22
|
+
/** Dialog Close Button positioned in top right with × */
|
|
23
|
+
export declare const DialogCloseButton: ({ children, ...buttonProps }: DialogPrimitive.DialogCloseProps) => JSX.Element;
|
|
20
24
|
export declare const Dialog: import("react").FC<DialogPrimitive.DialogProps>;
|
|
21
25
|
export declare const DialogTrigger: import("react").ForwardRefExoticComponent<DialogPrimitive.DialogTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
22
26
|
export declare const DialogClose: import("react").ForwardRefExoticComponent<DialogPrimitive.DialogCloseProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
|
|
3
|
+
export type { DropdownMenuCheckboxItemProps, DropdownMenuContentProps, DropdownMenuItemIndicatorProps, DropdownMenuLabelProps, MenuSubTriggerProps, MenuSubContentProps, MenuSeparatorProps, } from '@radix-ui/react-dropdown-menu';
|
|
4
|
+
export declare function DropdownMenuContent({ children, forceMount, ...props }: DropdownMenuPrimitive.DropdownMenuContentProps): JSX.Element;
|
|
5
|
+
export declare const DropdownMenu: import("react").FC<DropdownMenuPrimitive.DropdownMenuProps>;
|
|
6
|
+
export declare const DropdownMenuPortal: import("react").FC<DropdownMenuPrimitive.DropdownMenuPortalProps>;
|
|
7
|
+
export declare const DropdownMenuGroup: import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuGroupProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
8
|
+
export declare const DropdownMenuTrigger: import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
9
|
+
export declare const DropdownMenuRadioGroup: import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuRadioGroupProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
10
|
+
export declare const DropdownMenuItem: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuItemProps & import("react").RefAttributes<HTMLDivElement>>, any, {}, never>;
|
|
11
|
+
export declare const DropdownMenuRadioItem: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuRadioItemProps & import("react").RefAttributes<HTMLDivElement>>, any, {}, never>;
|
|
12
|
+
export declare const DropdownMenuCheckboxItem: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuCheckboxItemProps & import("react").RefAttributes<HTMLDivElement>>, any, {}, never>;
|
|
13
|
+
export declare const DropdownMenuItemIndicator: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuItemIndicatorProps & import("react").RefAttributes<HTMLSpanElement>>, any, {}, never>;
|
|
14
|
+
export declare const DropdownMenuArrow: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuArrowProps & import("react").RefAttributes<SVGSVGElement>>, any, {}, never>;
|
|
15
|
+
export declare const DropdownMenuLabel: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuLabelProps & import("react").RefAttributes<HTMLDivElement>>, any, {}, never>;
|
|
16
|
+
export declare const DropdownMenuSeparator: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuSeparatorProps & import("react").RefAttributes<HTMLDivElement>>, any, {}, never>;
|
|
17
|
+
export declare const DropdownMenuSub: import("react").FC<DropdownMenuPrimitive.DropdownMenuSubProps>;
|
|
18
|
+
export declare const DropdownMenuSubTrigger: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuSubTriggerProps & import("react").RefAttributes<HTMLDivElement>>, any, {}, never>;
|
|
19
|
+
export declare const DropdownMenuSubContent: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuSubContentProps & import("react").RefAttributes<HTMLDivElement>>, any, {}, never>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import type { ComponentPropsWithoutStyles } from 'helpers/typeHelpers';
|
|
2
|
+
import type { ComponentPropsWithoutStyles } from '../../helpers/typeHelpers';
|
|
3
3
|
export declare const StyledFieldSet: import("styled-components").StyledComponent<"fieldset", any, {}, never>;
|
|
4
4
|
/** Adding disabled to `<fieldset>` will disable all inputs inside it HTML wise,
|
|
5
5
|
* the problem is that React won't know about that they the input components are disabled (prop-wise)
|
|
@@ -4,10 +4,10 @@ export type FileDescription = {
|
|
|
4
4
|
mime: `${string}/${string}`;
|
|
5
5
|
};
|
|
6
6
|
type DropTargetProps = {
|
|
7
|
-
file
|
|
7
|
+
file?: File | null | undefined;
|
|
8
8
|
fileTypes: FileDescription[];
|
|
9
9
|
onAddFile: (f: File) => void;
|
|
10
|
-
onDeleteFile
|
|
10
|
+
onDeleteFile?: (() => void) | undefined;
|
|
11
11
|
};
|
|
12
12
|
export declare const FileUpload: import("react").ForwardRefExoticComponent<DropTargetProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
13
13
|
export {};
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import type { PropsWithChildren } from 'react';
|
|
2
|
+
import type { Property } from 'csstype';
|
|
3
|
+
import { type SpacingToken } from '../../helpers/tokenUtils';
|
|
4
|
+
export type FlexProps = PropsWithChildren<{
|
|
5
|
+
display?: 'flex' | "inline-flex";
|
|
6
|
+
wrap?: Property.FlexWrap;
|
|
7
|
+
direction?: Property.FlexDirection;
|
|
8
|
+
alignItems?: Property.AlignItems;
|
|
9
|
+
alignContent?: Property.AlignContent;
|
|
10
|
+
justifyContent?: Property.JustifyContent;
|
|
11
|
+
flow?: Property.FlexFlow;
|
|
12
|
+
gap?: Property.Gap<SpacingToken>;
|
|
13
|
+
columnGap?: Property.ColumnGap<SpacingToken>;
|
|
14
|
+
rowGap?: Property.RowGap<SpacingToken>;
|
|
15
|
+
}>;
|
|
16
|
+
export declare const Flex: import("styled-components").StyledComponent<"div", any, {
|
|
17
|
+
display?: "none" | "inline" | "block" | "inline-block" | "contents" | undefined;
|
|
18
|
+
position?: "inherit" | "fixed" | "static" | "initial" | "revert" | "revert-layer" | "unset" | "absolute" | "relative" | "sticky" | undefined;
|
|
19
|
+
top?: Property.Top<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
20
|
+
bottom?: Property.Bottom<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
21
|
+
left?: Property.Left<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
22
|
+
right?: Property.Right<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
23
|
+
zIndex?: Property.ZIndex | undefined;
|
|
24
|
+
w?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | "min-intrinsic" | undefined;
|
|
25
|
+
minW?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | "min-intrinsic" | undefined;
|
|
26
|
+
maxW?: "0" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "none" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | undefined;
|
|
27
|
+
h?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "max-content" | "min-content" | undefined;
|
|
28
|
+
minH?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | undefined;
|
|
29
|
+
maxH?: "0" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "none" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "intrinsic" | "max-content" | "min-content" | undefined;
|
|
30
|
+
m?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
31
|
+
mt?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
32
|
+
mb?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
33
|
+
ml?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
34
|
+
mr?: "0" | "auto" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
35
|
+
p?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
36
|
+
pt?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
37
|
+
pr?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
38
|
+
pb?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
39
|
+
pl?: "0" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "initial" | "revert" | "revert-layer" | "unset" | undefined;
|
|
40
|
+
borderRadius?: Property.BorderRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
41
|
+
borderTopLeftRadius?: Property.BorderTopLeftRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
42
|
+
borderTopRightRadius?: Property.BorderTopRightRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
43
|
+
borderBottomLeftRadius?: Property.BorderBottomLeftRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
44
|
+
borderBottomRightRadius?: Property.BorderBottomRightRadius<"0" | "400" | "circle" | "100" | "200" | "800" | "pill"> | undefined;
|
|
45
|
+
elevation?: import("../../helpers/tokenUtils").ElevationToken | undefined;
|
|
46
|
+
flexShrink?: (string & {}) | "inherit" | "initial" | "revert" | "revert-layer" | "unset" | (number & {}) | undefined;
|
|
47
|
+
flexGrow?: (string & {}) | "inherit" | "initial" | "revert" | "revert-layer" | "unset" | (number & {}) | undefined;
|
|
48
|
+
flexBasis?: "0" | "auto" | "1000" | "300" | "400" | "500" | "600" | (string & {}) | "inherit" | "content" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500" | "initial" | "revert" | "revert-layer" | "unset" | "fit-content" | "max-content" | "min-content" | undefined;
|
|
49
|
+
flex?: Property.Flex<"0" | "1000" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900" | "350" | "1100" | "1150" | "1200" | "1300" | "1350" | "1400" | "1500"> | undefined;
|
|
50
|
+
alignSelf?: Property.AlignSelf | undefined;
|
|
51
|
+
order?: Property.Order | undefined;
|
|
52
|
+
border?: Property.Border<0 | (string & {})> | undefined;
|
|
53
|
+
borderColor?: Property.BorderColor | undefined;
|
|
54
|
+
borderWidth?: Property.BorderWidth<0 | (string & {})> | undefined;
|
|
55
|
+
bg?: Property.Background<0 | (string & {})> | undefined;
|
|
56
|
+
bgColor?: Property.BackgroundColor | undefined;
|
|
57
|
+
opacity?: Property.Background<0 | (string & {})> | undefined;
|
|
58
|
+
color?: Property.Color | undefined;
|
|
59
|
+
overflow?: "auto" | "hidden" | (string & {}) | "inherit" | "clip" | "initial" | "revert" | "revert-layer" | "unset" | "scroll" | "visible" | undefined;
|
|
60
|
+
} & {
|
|
61
|
+
children?: import("react").ReactNode;
|
|
62
|
+
} & {
|
|
63
|
+
display?: "flex" | "inline-flex" | undefined;
|
|
64
|
+
wrap?: Property.FlexWrap | undefined;
|
|
65
|
+
direction?: Property.FlexDirection | undefined;
|
|
66
|
+
alignItems?: Property.AlignItems | undefined;
|
|
67
|
+
alignContent?: Property.AlignContent | undefined;
|
|
68
|
+
justifyContent?: Property.JustifyContent | undefined;
|
|
69
|
+
flow?: Property.FlexFlow | undefined;
|
|
70
|
+
gap?: Property.Gap<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
71
|
+
columnGap?: Property.ColumnGap<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
72
|
+
rowGap?: Property.RowGap<"0" | "300" | "400" | "500" | "600" | "100" | "200" | "450" | "550" | "650" | "700" | "750" | "800" | "850" | "900"> | undefined;
|
|
73
|
+
}, never>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type PropsWithChildren, type ReactNode } from 'react';
|
|
2
2
|
import { type AriaFieldProps, type FieldAria } from '@react-aria/label';
|
|
3
3
|
import type { AriaTextFieldProps } from '@react-aria/textfield';
|
|
4
|
-
import type { ComponentPropsWithoutStyles } from 'helpers/typeHelpers';
|
|
4
|
+
import type { ComponentPropsWithoutStyles } from '../../helpers/typeHelpers';
|
|
5
5
|
type FormControlProps<FieldProps = AriaFieldProps> = PropsWithChildren<{
|
|
6
6
|
tooltipContent?: string;
|
|
7
7
|
tooltipIcon?: ReactNode;
|
|
@@ -70,7 +70,7 @@ export declare const NumberFormControl: import("react").ForwardRefExoticComponen
|
|
|
70
70
|
tooltipIcon?: ReactNode;
|
|
71
71
|
} & AriaFieldProps & {
|
|
72
72
|
children?: ReactNode;
|
|
73
|
-
} & Omit<import("helpers/typeHelpers").RenameBooleanProps<import("@react-types/numberfield").AriaNumberFieldProps>, "minValue" | "maxValue"> & {
|
|
73
|
+
} & Omit<import("../../helpers/typeHelpers").RenameBooleanProps<import("@react-types/numberfield").AriaNumberFieldProps>, "minValue" | "maxValue"> & {
|
|
74
74
|
min?: number | undefined;
|
|
75
75
|
max?: number | undefined;
|
|
76
76
|
} & import("components/Input/InputBase").InputBaseProps & {
|
|
@@ -12,7 +12,7 @@ export type StyledIconButtonProps = AriaButtonProps & {
|
|
|
12
12
|
shape?: Shape;
|
|
13
13
|
disabled?: boolean;
|
|
14
14
|
};
|
|
15
|
-
/** Be sure to add add a `label` prop.
|
|
15
|
+
/** Be sure to add add a `label` prop. Note `aria-label` is already taken care of by the `label` prop.
|
|
16
16
|
* ```jsx
|
|
17
17
|
* <IconButton label="Add new item">
|
|
18
18
|
* <AddIcon/>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { type AriaNumberFieldProps } from '@react-aria/numberfield';
|
|
3
3
|
import { type NumberFieldStateOptions } from '@react-stately/numberfield';
|
|
4
|
-
import type { ComponentPropsWithoutStyles, RenameBooleanProps, RenameMissuffixedProps } from 'helpers/typeHelpers';
|
|
4
|
+
import type { ComponentPropsWithoutStyles, RenameBooleanProps, RenameMissuffixedProps } from '../../../helpers/typeHelpers';
|
|
5
5
|
import { type InputBaseProps } from '../InputBase';
|
|
6
6
|
type ReactAriaNumberInputProps = RenameMissuffixedProps<RenameBooleanProps<AriaNumberFieldProps>, 'Value', 'minValue' | 'maxValue'>;
|
|
7
7
|
type ShowStepper = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { type AriaTextFieldOptions } from '@react-aria/textfield';
|
|
3
|
-
import type { RenameBooleanProps } from 'helpers/typeHelpers';
|
|
3
|
+
import type { RenameBooleanProps } from '../../../helpers/typeHelpers';
|
|
4
4
|
import { type InputBaseProps } from '../InputBase';
|
|
5
5
|
type ReactAriaInputProps = Omit<RenameBooleanProps<AriaTextFieldOptions<'textarea'>>, 'inputElementType'>;
|
|
6
6
|
export type TextAreaInputProps = ReactAriaInputProps & InputBaseProps;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { type AriaTextFieldOptions } from '@react-aria/textfield';
|
|
3
|
-
import type { RenameBooleanProps } from 'helpers/typeHelpers';
|
|
3
|
+
import type { RenameBooleanProps } from '../../../helpers/typeHelpers';
|
|
4
4
|
import { type InputBaseProps } from '../InputBase';
|
|
5
5
|
type ReactAriaInputProps = Omit<RenameBooleanProps<AriaTextFieldOptions<'input'>>, 'inputElementType'>;
|
|
6
6
|
export type TextInputProps = ReactAriaInputProps & InputBaseProps;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
|
-
import type { ComponentPropsWithoutStyles } from 'helpers/typeHelpers';
|
|
2
|
+
import type { ComponentPropsWithoutStyles } from '../../helpers/typeHelpers';
|
|
3
3
|
export interface LabelProps extends ComponentPropsWithoutStyles<'label'> {
|
|
4
4
|
size?: 'small' | 'medium' | 'large';
|
|
5
5
|
bold?: boolean;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { CollectionChildren } from
|
|
2
|
-
import React from
|
|
3
|
-
import { useMultiSelectState } from
|
|
4
|
-
export { Item as MultiSelectItem, Section as MultiSelectSection } from
|
|
1
|
+
import type { CollectionChildren } from '@react-types/shared';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { useMultiSelectState } from './useMultiSelectState';
|
|
4
|
+
export { Item as MultiSelectItem, Section as MultiSelectSection, } from '@react-stately/collections';
|
|
5
5
|
export type OptionItem = {
|
|
6
6
|
children?: never;
|
|
7
7
|
id: string;
|
|
@@ -25,9 +25,9 @@ type MultiSelectProps = {
|
|
|
25
25
|
/** Sets the default open state of the field (uncontrolled). */
|
|
26
26
|
defaultOpen?: boolean;
|
|
27
27
|
/** The initial selected keys in the collection (uncontrolled). */
|
|
28
|
-
defaultSelectedKeys?: Parameters<typeof useMultiSelectState>[
|
|
28
|
+
defaultSelectedKeys?: Parameters<typeof useMultiSelectState>['0']['defaultSelectedKeys'];
|
|
29
29
|
/** The item keys that are disabled. These items cannot be selected, focused, or otherwise interacted with. */
|
|
30
|
-
disabledKeys?: Parameters<typeof useMultiSelectState>[
|
|
30
|
+
disabledKeys?: Parameters<typeof useMultiSelectState>['0']['disabledKeys'];
|
|
31
31
|
excludeFromTabOrder?: boolean;
|
|
32
32
|
items: Option[];
|
|
33
33
|
/** Whether the field can be emptied. */
|
|
@@ -43,13 +43,13 @@ type MultiSelectProps = {
|
|
|
43
43
|
/** The content to display as the placeholder. */
|
|
44
44
|
placeholder?: string;
|
|
45
45
|
/** Handler that is called when the select's open state changes. */
|
|
46
|
-
onOpenChange?: Parameters<typeof useMultiSelectState>[
|
|
46
|
+
onOpenChange?: Parameters<typeof useMultiSelectState>['0']['onOpenChange'];
|
|
47
47
|
/** Handler that is called when the selection changes. */
|
|
48
|
-
onSelectionChange?: Parameters<typeof useMultiSelectState>[
|
|
48
|
+
onSelectionChange?: Parameters<typeof useMultiSelectState>['0']['onSelectionChange'];
|
|
49
49
|
/** The currently selected keys in the collection (controlled). */
|
|
50
|
-
selectedKeys?: Parameters<typeof useMultiSelectState>[
|
|
50
|
+
selectedKeys?: Parameters<typeof useMultiSelectState>['0']['selectedKeys'];
|
|
51
51
|
/** The type of selection that is allowed in the collection. */
|
|
52
|
-
selectionMode:
|
|
52
|
+
selectionMode: 'single' | 'multiple';
|
|
53
53
|
tooltipContent?: string;
|
|
54
54
|
tooltipIcon?: string;
|
|
55
55
|
};
|
|
@@ -43,8 +43,11 @@ interface ItemProps<T extends React.ElementType> {
|
|
|
43
43
|
as?: T;
|
|
44
44
|
children?: React.ReactNode;
|
|
45
45
|
}
|
|
46
|
-
export declare function Item<T extends React.ElementType =
|
|
47
|
-
|
|
46
|
+
export declare function Item<T extends React.ElementType = 'div'>({ as, ...props }: ItemProps<T> & Omit<React.ComponentPropsWithoutRef<T>, keyof ItemProps<T>>): JSX.Element;
|
|
47
|
+
/**
|
|
48
|
+
* Separator
|
|
49
|
+
*/
|
|
50
|
+
export declare const Separator: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
48
51
|
declare const NavigationMenu: CompoundedComponent & {
|
|
49
52
|
Trigger: ({ children }: TriggerProps) => JSX.Element;
|
|
50
53
|
List: ({ children, portalIdOverride, }: {
|
|
@@ -52,7 +55,7 @@ declare const NavigationMenu: CompoundedComponent & {
|
|
|
52
55
|
portalIdOverride?: string | undefined;
|
|
53
56
|
}) => React.ReactPortal;
|
|
54
57
|
Item: typeof Item;
|
|
55
|
-
Separator:
|
|
58
|
+
Separator: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
56
59
|
};
|
|
57
60
|
declare const NavigationMenuPortal: () => JSX.Element;
|
|
58
61
|
export { NavigationMenu, NavigationMenuPortal };
|