@rovula/ui 0.0.7 → 0.0.9
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/dist/cjs/bundle.css +136 -33
- package/dist/cjs/bundle.js +1 -1
- package/dist/cjs/bundle.js.map +1 -1
- package/dist/cjs/types/components/Dropdown/Dropdown.d.ts +26 -0
- package/dist/cjs/types/components/Dropdown/Dropdown.stories.d.ts +367 -0
- package/dist/cjs/types/components/Dropdown/Dropdown.styles.d.ts +11 -0
- package/dist/cjs/types/components/TextInput/TextInput.d.ts +3 -2
- package/dist/cjs/types/components/TextInput/TextInput.stories.d.ts +2 -16
- package/dist/cjs/types/components/TextInput/TextInput.styles.d.ts +0 -1
- package/dist/cjs/types/index.d.ts +1 -0
- package/dist/components/Dropdown/Dropdown.js +58 -0
- package/dist/components/Dropdown/Dropdown.stories.js +43 -0
- package/dist/components/Dropdown/Dropdown.styles.js +47 -0
- package/dist/components/TextInput/TextInput.js +3 -5
- package/dist/components/TextInput/TextInput.stories.js +1 -1
- package/dist/components/TextInput/TextInput.styles.js +13 -21
- package/dist/esm/bundle.css +136 -33
- package/dist/esm/bundle.js +1 -1
- package/dist/esm/bundle.js.map +1 -1
- package/dist/esm/types/components/Dropdown/Dropdown.d.ts +26 -0
- package/dist/esm/types/components/Dropdown/Dropdown.stories.d.ts +367 -0
- package/dist/esm/types/components/Dropdown/Dropdown.styles.d.ts +11 -0
- package/dist/esm/types/components/TextInput/TextInput.d.ts +3 -2
- package/dist/esm/types/components/TextInput/TextInput.stories.d.ts +2 -16
- package/dist/esm/types/components/TextInput/TextInput.styles.d.ts +0 -1
- package/dist/esm/types/index.d.ts +1 -0
- package/dist/index.d.ts +29 -2
- package/dist/index.js +1 -0
- package/dist/src/theme/global.css +170 -38
- package/package.json +1 -1
- package/src/components/Dropdown/Dropdown.stories.tsx +49 -0
- package/src/components/Dropdown/Dropdown.styles.ts +54 -0
- package/src/components/Dropdown/Dropdown.tsx +151 -0
- package/src/components/TextInput/TextInput.stories.tsx +3 -3
- package/src/components/TextInput/TextInput.styles.ts +13 -21
- package/src/components/TextInput/TextInput.tsx +14 -5
- package/src/index.ts +1 -0
|
@@ -0,0 +1,367 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
declare const meta: {
|
|
3
|
+
title: string;
|
|
4
|
+
component: ({ id, options, value, label, size, rounded, variant, helperText, errorMessage, fullwidth, disabled, error, filterMode, required, onChangeText, onSelect, ...props }: {
|
|
5
|
+
id?: string | undefined;
|
|
6
|
+
label?: string | undefined;
|
|
7
|
+
size?: "sm" | "md" | "lg" | undefined;
|
|
8
|
+
rounded?: "none" | "normal" | "full" | undefined;
|
|
9
|
+
variant?: "outline" | "flat" | "underline" | undefined;
|
|
10
|
+
helperText?: string | undefined;
|
|
11
|
+
errorMessage?: string | undefined;
|
|
12
|
+
filterMode?: boolean | undefined;
|
|
13
|
+
fullwidth?: boolean | undefined;
|
|
14
|
+
disabled?: boolean | undefined;
|
|
15
|
+
error?: boolean | undefined;
|
|
16
|
+
required?: boolean | undefined;
|
|
17
|
+
className?: string | undefined;
|
|
18
|
+
options: {
|
|
19
|
+
value: string;
|
|
20
|
+
label: string;
|
|
21
|
+
}[];
|
|
22
|
+
value?: {
|
|
23
|
+
value: string;
|
|
24
|
+
label: string;
|
|
25
|
+
} | undefined;
|
|
26
|
+
onChangeText?: React.ChangeEventHandler<HTMLInputElement> | undefined;
|
|
27
|
+
onSelect?: ((value: {
|
|
28
|
+
value: string;
|
|
29
|
+
label: string;
|
|
30
|
+
}) => void) | undefined;
|
|
31
|
+
} & Omit<import("../TextInput/TextInput").InputProps, "value">) => import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
tags: string[];
|
|
33
|
+
parameters: {
|
|
34
|
+
layout: string;
|
|
35
|
+
};
|
|
36
|
+
decorators: ((Story: import("@storybook/types").PartialStoryFn<import("@storybook/react").ReactRenderer, {
|
|
37
|
+
id?: string | undefined;
|
|
38
|
+
label?: string | undefined;
|
|
39
|
+
size?: "sm" | "md" | "lg" | undefined;
|
|
40
|
+
rounded?: "none" | "normal" | "full" | undefined;
|
|
41
|
+
variant?: "outline" | "flat" | "underline" | undefined;
|
|
42
|
+
helperText?: string | undefined;
|
|
43
|
+
errorMessage?: string | undefined;
|
|
44
|
+
filterMode?: boolean | undefined;
|
|
45
|
+
fullwidth?: boolean | undefined;
|
|
46
|
+
disabled?: boolean | undefined;
|
|
47
|
+
error?: boolean | undefined;
|
|
48
|
+
required?: boolean | undefined;
|
|
49
|
+
className?: string | undefined;
|
|
50
|
+
options: {
|
|
51
|
+
value: string;
|
|
52
|
+
label: string;
|
|
53
|
+
}[];
|
|
54
|
+
value?: {
|
|
55
|
+
value: string;
|
|
56
|
+
label: string;
|
|
57
|
+
} | undefined;
|
|
58
|
+
onChangeText?: React.ChangeEventHandler<HTMLInputElement> | undefined;
|
|
59
|
+
onSelect?: (((value: {
|
|
60
|
+
value: string;
|
|
61
|
+
label: string;
|
|
62
|
+
}) => void) & React.ReactEventHandler<HTMLInputElement>) | undefined;
|
|
63
|
+
color?: string | undefined;
|
|
64
|
+
title?: string | undefined;
|
|
65
|
+
children?: React.ReactNode;
|
|
66
|
+
endIcon?: React.ReactNode;
|
|
67
|
+
form?: string | undefined;
|
|
68
|
+
formAction?: string | undefined;
|
|
69
|
+
formEncType?: string | undefined;
|
|
70
|
+
formMethod?: string | undefined;
|
|
71
|
+
formNoValidate?: boolean | undefined;
|
|
72
|
+
formTarget?: string | undefined;
|
|
73
|
+
name?: string | undefined;
|
|
74
|
+
type?: React.HTMLInputTypeAttribute | undefined;
|
|
75
|
+
defaultChecked?: boolean | undefined;
|
|
76
|
+
defaultValue?: string | number | readonly string[] | undefined;
|
|
77
|
+
suppressContentEditableWarning?: boolean | undefined;
|
|
78
|
+
suppressHydrationWarning?: boolean | undefined;
|
|
79
|
+
accessKey?: string | undefined;
|
|
80
|
+
autoFocus?: boolean | undefined;
|
|
81
|
+
contentEditable?: (boolean | "true" | "false") | "inherit" | "plaintext-only" | undefined;
|
|
82
|
+
contextMenu?: string | undefined;
|
|
83
|
+
dir?: string | undefined;
|
|
84
|
+
draggable?: (boolean | "true" | "false") | undefined;
|
|
85
|
+
hidden?: boolean | undefined;
|
|
86
|
+
lang?: string | undefined;
|
|
87
|
+
nonce?: string | undefined;
|
|
88
|
+
slot?: string | undefined;
|
|
89
|
+
spellCheck?: (boolean | "true" | "false") | undefined;
|
|
90
|
+
style?: React.CSSProperties | undefined;
|
|
91
|
+
tabIndex?: number | undefined;
|
|
92
|
+
translate?: "yes" | "no" | undefined;
|
|
93
|
+
radioGroup?: string | undefined;
|
|
94
|
+
role?: React.AriaRole | undefined;
|
|
95
|
+
about?: string | undefined;
|
|
96
|
+
content?: string | undefined;
|
|
97
|
+
datatype?: string | undefined;
|
|
98
|
+
inlist?: any;
|
|
99
|
+
prefix?: string | undefined;
|
|
100
|
+
property?: string | undefined;
|
|
101
|
+
rel?: string | undefined;
|
|
102
|
+
resource?: string | undefined;
|
|
103
|
+
rev?: string | undefined;
|
|
104
|
+
typeof?: string | undefined;
|
|
105
|
+
vocab?: string | undefined;
|
|
106
|
+
autoCapitalize?: string | undefined;
|
|
107
|
+
autoCorrect?: string | undefined;
|
|
108
|
+
autoSave?: string | undefined;
|
|
109
|
+
itemProp?: string | undefined;
|
|
110
|
+
itemScope?: boolean | undefined;
|
|
111
|
+
itemType?: string | undefined;
|
|
112
|
+
itemID?: string | undefined;
|
|
113
|
+
itemRef?: string | undefined;
|
|
114
|
+
results?: number | undefined;
|
|
115
|
+
security?: string | undefined;
|
|
116
|
+
unselectable?: "on" | "off" | undefined;
|
|
117
|
+
inputMode?: "search" | "none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | undefined;
|
|
118
|
+
is?: string | undefined;
|
|
119
|
+
"aria-activedescendant"?: string | undefined;
|
|
120
|
+
"aria-atomic"?: (boolean | "true" | "false") | undefined;
|
|
121
|
+
"aria-autocomplete"?: "list" | "none" | "inline" | "both" | undefined;
|
|
122
|
+
"aria-braillelabel"?: string | undefined;
|
|
123
|
+
"aria-brailleroledescription"?: string | undefined;
|
|
124
|
+
"aria-busy"?: (boolean | "true" | "false") | undefined;
|
|
125
|
+
"aria-checked"?: boolean | "true" | "false" | "mixed" | undefined;
|
|
126
|
+
"aria-colcount"?: number | undefined;
|
|
127
|
+
"aria-colindex"?: number | undefined;
|
|
128
|
+
"aria-colindextext"?: string | undefined;
|
|
129
|
+
"aria-colspan"?: number | undefined;
|
|
130
|
+
"aria-controls"?: string | undefined;
|
|
131
|
+
"aria-current"?: boolean | "true" | "false" | "date" | "time" | "step" | "page" | "location" | undefined;
|
|
132
|
+
"aria-describedby"?: string | undefined;
|
|
133
|
+
"aria-description"?: string | undefined;
|
|
134
|
+
"aria-details"?: string | undefined;
|
|
135
|
+
"aria-disabled"?: (boolean | "true" | "false") | undefined;
|
|
136
|
+
"aria-dropeffect"?: "link" | "none" | "copy" | "execute" | "move" | "popup" | undefined;
|
|
137
|
+
"aria-errormessage"?: string | undefined;
|
|
138
|
+
"aria-expanded"?: (boolean | "true" | "false") | undefined;
|
|
139
|
+
"aria-flowto"?: string | undefined;
|
|
140
|
+
"aria-grabbed"?: (boolean | "true" | "false") | undefined;
|
|
141
|
+
"aria-haspopup"?: boolean | "true" | "false" | "dialog" | "grid" | "listbox" | "menu" | "tree" | undefined;
|
|
142
|
+
"aria-hidden"?: (boolean | "true" | "false") | undefined;
|
|
143
|
+
"aria-invalid"?: boolean | "true" | "false" | "grammar" | "spelling" | undefined;
|
|
144
|
+
"aria-keyshortcuts"?: string | undefined;
|
|
145
|
+
"aria-label"?: string | undefined;
|
|
146
|
+
"aria-labelledby"?: string | undefined;
|
|
147
|
+
"aria-level"?: number | undefined;
|
|
148
|
+
"aria-live"?: "off" | "assertive" | "polite" | undefined;
|
|
149
|
+
"aria-modal"?: (boolean | "true" | "false") | undefined;
|
|
150
|
+
"aria-multiline"?: (boolean | "true" | "false") | undefined;
|
|
151
|
+
"aria-multiselectable"?: (boolean | "true" | "false") | undefined;
|
|
152
|
+
"aria-orientation"?: "horizontal" | "vertical" | undefined;
|
|
153
|
+
"aria-owns"?: string | undefined;
|
|
154
|
+
"aria-placeholder"?: string | undefined;
|
|
155
|
+
"aria-posinset"?: number | undefined;
|
|
156
|
+
"aria-pressed"?: boolean | "true" | "false" | "mixed" | undefined;
|
|
157
|
+
"aria-readonly"?: (boolean | "true" | "false") | undefined;
|
|
158
|
+
"aria-relevant"?: "text" | "additions" | "additions removals" | "additions text" | "all" | "removals" | "removals additions" | "removals text" | "text additions" | "text removals" | undefined;
|
|
159
|
+
"aria-required"?: (boolean | "true" | "false") | undefined;
|
|
160
|
+
"aria-roledescription"?: string | undefined;
|
|
161
|
+
"aria-rowcount"?: number | undefined;
|
|
162
|
+
"aria-rowindex"?: number | undefined;
|
|
163
|
+
"aria-rowindextext"?: string | undefined;
|
|
164
|
+
"aria-rowspan"?: number | undefined;
|
|
165
|
+
"aria-selected"?: (boolean | "true" | "false") | undefined;
|
|
166
|
+
"aria-setsize"?: number | undefined;
|
|
167
|
+
"aria-sort"?: "none" | "ascending" | "descending" | "other" | undefined;
|
|
168
|
+
"aria-valuemax"?: number | undefined;
|
|
169
|
+
"aria-valuemin"?: number | undefined;
|
|
170
|
+
"aria-valuenow"?: number | undefined;
|
|
171
|
+
"aria-valuetext"?: string | undefined;
|
|
172
|
+
dangerouslySetInnerHTML?: {
|
|
173
|
+
__html: string | TrustedHTML;
|
|
174
|
+
} | undefined;
|
|
175
|
+
onCopy?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
176
|
+
onCopyCapture?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
177
|
+
onCut?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
178
|
+
onCutCapture?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
179
|
+
onPaste?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
180
|
+
onPasteCapture?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
181
|
+
onCompositionEnd?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
182
|
+
onCompositionEndCapture?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
183
|
+
onCompositionStart?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
184
|
+
onCompositionStartCapture?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
185
|
+
onCompositionUpdate?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
186
|
+
onCompositionUpdateCapture?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
187
|
+
onFocus?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
188
|
+
onFocusCapture?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
189
|
+
onBlur?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
190
|
+
onBlurCapture?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
191
|
+
onChange?: React.ChangeEventHandler<HTMLInputElement> | undefined;
|
|
192
|
+
onChangeCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
193
|
+
onBeforeInput?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
194
|
+
onBeforeInputCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
195
|
+
onInput?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
196
|
+
onInputCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
197
|
+
onReset?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
198
|
+
onResetCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
199
|
+
onSubmit?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
200
|
+
onSubmitCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
201
|
+
onInvalid?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
202
|
+
onInvalidCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
203
|
+
onLoad?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
204
|
+
onLoadCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
205
|
+
onError?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
206
|
+
onErrorCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
207
|
+
onKeyDown?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
208
|
+
onKeyDownCapture?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
209
|
+
onKeyPress?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
210
|
+
onKeyPressCapture?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
211
|
+
onKeyUp?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
212
|
+
onKeyUpCapture?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
213
|
+
onAbort?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
214
|
+
onAbortCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
215
|
+
onCanPlay?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
216
|
+
onCanPlayCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
217
|
+
onCanPlayThrough?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
218
|
+
onCanPlayThroughCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
219
|
+
onDurationChange?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
220
|
+
onDurationChangeCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
221
|
+
onEmptied?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
222
|
+
onEmptiedCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
223
|
+
onEncrypted?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
224
|
+
onEncryptedCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
225
|
+
onEnded?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
226
|
+
onEndedCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
227
|
+
onLoadedData?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
228
|
+
onLoadedDataCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
229
|
+
onLoadedMetadata?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
230
|
+
onLoadedMetadataCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
231
|
+
onLoadStart?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
232
|
+
onLoadStartCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
233
|
+
onPause?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
234
|
+
onPauseCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
235
|
+
onPlay?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
236
|
+
onPlayCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
237
|
+
onPlaying?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
238
|
+
onPlayingCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
239
|
+
onProgress?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
240
|
+
onProgressCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
241
|
+
onRateChange?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
242
|
+
onRateChangeCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
243
|
+
onResize?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
244
|
+
onResizeCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
245
|
+
onSeeked?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
246
|
+
onSeekedCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
247
|
+
onSeeking?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
248
|
+
onSeekingCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
249
|
+
onStalled?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
250
|
+
onStalledCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
251
|
+
onSuspend?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
252
|
+
onSuspendCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
253
|
+
onTimeUpdate?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
254
|
+
onTimeUpdateCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
255
|
+
onVolumeChange?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
256
|
+
onVolumeChangeCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
257
|
+
onWaiting?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
258
|
+
onWaitingCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
259
|
+
onAuxClick?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
260
|
+
onAuxClickCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
261
|
+
onClick?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
262
|
+
onClickCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
263
|
+
onContextMenu?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
264
|
+
onContextMenuCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
265
|
+
onDoubleClick?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
266
|
+
onDoubleClickCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
267
|
+
onDrag?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
268
|
+
onDragCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
269
|
+
onDragEnd?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
270
|
+
onDragEndCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
271
|
+
onDragEnter?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
272
|
+
onDragEnterCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
273
|
+
onDragExit?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
274
|
+
onDragExitCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
275
|
+
onDragLeave?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
276
|
+
onDragLeaveCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
277
|
+
onDragOver?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
278
|
+
onDragOverCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
279
|
+
onDragStart?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
280
|
+
onDragStartCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
281
|
+
onDrop?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
282
|
+
onDropCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
283
|
+
onMouseDown?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
284
|
+
onMouseDownCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
285
|
+
onMouseEnter?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
286
|
+
onMouseLeave?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
287
|
+
onMouseMove?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
288
|
+
onMouseMoveCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
289
|
+
onMouseOut?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
290
|
+
onMouseOutCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
291
|
+
onMouseOver?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
292
|
+
onMouseOverCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
293
|
+
onMouseUp?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
294
|
+
onMouseUpCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
295
|
+
onSelectCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
296
|
+
onTouchCancel?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
297
|
+
onTouchCancelCapture?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
298
|
+
onTouchEnd?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
299
|
+
onTouchEndCapture?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
300
|
+
onTouchMove?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
301
|
+
onTouchMoveCapture?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
302
|
+
onTouchStart?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
303
|
+
onTouchStartCapture?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
304
|
+
onPointerDown?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
305
|
+
onPointerDownCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
306
|
+
onPointerMove?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
307
|
+
onPointerMoveCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
308
|
+
onPointerUp?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
309
|
+
onPointerUpCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
310
|
+
onPointerCancel?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
311
|
+
onPointerCancelCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
312
|
+
onPointerEnter?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
313
|
+
onPointerLeave?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
314
|
+
onPointerOver?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
315
|
+
onPointerOverCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
316
|
+
onPointerOut?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
317
|
+
onPointerOutCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
318
|
+
onGotPointerCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
319
|
+
onGotPointerCaptureCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
320
|
+
onLostPointerCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
321
|
+
onLostPointerCaptureCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
322
|
+
onScroll?: React.UIEventHandler<HTMLInputElement> | undefined;
|
|
323
|
+
onScrollCapture?: React.UIEventHandler<HTMLInputElement> | undefined;
|
|
324
|
+
onWheel?: React.WheelEventHandler<HTMLInputElement> | undefined;
|
|
325
|
+
onWheelCapture?: React.WheelEventHandler<HTMLInputElement> | undefined;
|
|
326
|
+
onAnimationStart?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
327
|
+
onAnimationStartCapture?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
328
|
+
onAnimationEnd?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
329
|
+
onAnimationEndCapture?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
330
|
+
onAnimationIteration?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
331
|
+
onAnimationIterationCapture?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
332
|
+
onTransitionEnd?: React.TransitionEventHandler<HTMLInputElement> | undefined;
|
|
333
|
+
onTransitionEndCapture?: React.TransitionEventHandler<HTMLInputElement> | undefined;
|
|
334
|
+
list?: string | undefined;
|
|
335
|
+
hasClearIcon?: boolean | undefined;
|
|
336
|
+
accept?: string | undefined;
|
|
337
|
+
alt?: string | undefined;
|
|
338
|
+
autoComplete?: React.HTMLInputAutoCompleteAttribute | undefined;
|
|
339
|
+
capture?: boolean | "user" | "environment" | undefined;
|
|
340
|
+
checked?: boolean | undefined;
|
|
341
|
+
enterKeyHint?: "search" | "enter" | "done" | "go" | "next" | "previous" | "send" | undefined;
|
|
342
|
+
height?: string | number | undefined;
|
|
343
|
+
max?: string | number | undefined;
|
|
344
|
+
maxLength?: number | undefined;
|
|
345
|
+
min?: string | number | undefined;
|
|
346
|
+
minLength?: number | undefined;
|
|
347
|
+
multiple?: boolean | undefined;
|
|
348
|
+
pattern?: string | undefined;
|
|
349
|
+
placeholder?: string | undefined;
|
|
350
|
+
readOnly?: boolean | undefined;
|
|
351
|
+
src?: string | undefined;
|
|
352
|
+
step?: string | number | undefined;
|
|
353
|
+
width?: string | number | undefined;
|
|
354
|
+
}>) => import("react/jsx-runtime").JSX.Element)[];
|
|
355
|
+
};
|
|
356
|
+
export default meta;
|
|
357
|
+
export declare const Default: {
|
|
358
|
+
args: {
|
|
359
|
+
label: string;
|
|
360
|
+
fullwidth: boolean;
|
|
361
|
+
options: {
|
|
362
|
+
value: string;
|
|
363
|
+
label: string;
|
|
364
|
+
}[];
|
|
365
|
+
};
|
|
366
|
+
render: (args: {}) => import("react/jsx-runtime").JSX.Element;
|
|
367
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const iconWrapperVariant: (props?: ({
|
|
2
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
3
|
+
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
4
|
+
export declare const dropdownIconVariant: (props?: ({
|
|
5
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
6
|
+
disabled?: boolean | null | undefined;
|
|
7
|
+
isFocus?: boolean | null | undefined;
|
|
8
|
+
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
9
|
+
export declare const customInputVariant: (props?: ({
|
|
10
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
11
|
+
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React, { FC } from "react";
|
|
2
|
-
type InputProps = {
|
|
1
|
+
import React, { FC, ReactNode } from "react";
|
|
2
|
+
export type InputProps = {
|
|
3
3
|
id?: string;
|
|
4
4
|
label?: string;
|
|
5
5
|
size?: "sm" | "md" | "lg";
|
|
@@ -13,6 +13,7 @@ type InputProps = {
|
|
|
13
13
|
error?: boolean;
|
|
14
14
|
required?: boolean;
|
|
15
15
|
hasClearIcon?: boolean;
|
|
16
|
+
endIcon?: ReactNode;
|
|
16
17
|
className?: string;
|
|
17
18
|
} & Omit<React.InputHTMLAttributes<HTMLInputElement>, "size">;
|
|
18
19
|
declare const TextInput: FC<InputProps>;
|
|
@@ -1,22 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
declare const meta: {
|
|
3
3
|
title: string;
|
|
4
|
-
component: React.FC<
|
|
5
|
-
id?: string | undefined;
|
|
6
|
-
label?: string | undefined;
|
|
7
|
-
size?: "sm" | "md" | "lg" | undefined;
|
|
8
|
-
rounded?: "none" | "normal" | "full" | undefined;
|
|
9
|
-
variant?: "outline" | "flat" | "underline" | undefined;
|
|
10
|
-
type?: React.HTMLInputTypeAttribute | undefined;
|
|
11
|
-
helperText?: string | undefined;
|
|
12
|
-
errorMessage?: string | undefined;
|
|
13
|
-
fullwidth?: boolean | undefined;
|
|
14
|
-
disabled?: boolean | undefined;
|
|
15
|
-
error?: boolean | undefined;
|
|
16
|
-
required?: boolean | undefined;
|
|
17
|
-
hasClearIcon?: boolean | undefined;
|
|
18
|
-
className?: string | undefined;
|
|
19
|
-
} & Omit<React.InputHTMLAttributes<HTMLInputElement>, "size">>;
|
|
4
|
+
component: React.FC<import("./TextInput").InputProps>;
|
|
20
5
|
tags: string[];
|
|
21
6
|
parameters: {
|
|
22
7
|
layout: string;
|
|
@@ -35,6 +20,7 @@ declare const meta: {
|
|
|
35
20
|
error?: boolean | undefined;
|
|
36
21
|
required?: boolean | undefined;
|
|
37
22
|
hasClearIcon?: boolean | undefined;
|
|
23
|
+
endIcon?: React.ReactNode;
|
|
38
24
|
className?: string | undefined;
|
|
39
25
|
color?: string | undefined;
|
|
40
26
|
title?: string | undefined;
|
|
@@ -11,7 +11,6 @@ export declare const labelVariant: (props?: ({
|
|
|
11
11
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
12
12
|
disabled?: boolean | null | undefined;
|
|
13
13
|
error?: boolean | null | undefined;
|
|
14
|
-
isFloating?: boolean | null | undefined;
|
|
15
14
|
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
16
15
|
export declare const helperTextVariant: (props?: ({
|
|
17
16
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
@@ -4,4 +4,5 @@ export { default as Table } from "./components/Table/Table";
|
|
|
4
4
|
export { default as TextInput } from "./components/TextInput/TextInput";
|
|
5
5
|
export { default as Text } from "./components/Text/Text";
|
|
6
6
|
export { default as Tabs } from "./components/Tabs/Tabs";
|
|
7
|
+
export { default as Dropdown } from "./components/Dropdown/Dropdown";
|
|
7
8
|
export { resloveTimestamp, getStartDateOfDay, getEndDateOfDay, getStartEndTimestampOfDay, getTimestampUTC, } from "./utils/datetime";
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import React, { FC, ReactElement } from 'react';
|
|
1
|
+
import React, { FC, ReactElement, ReactNode } from 'react';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
3
|
|
|
3
4
|
type ButtonProps = {
|
|
4
5
|
title?: string;
|
|
@@ -38,6 +39,7 @@ type InputProps = {
|
|
|
38
39
|
error?: boolean;
|
|
39
40
|
required?: boolean;
|
|
40
41
|
hasClearIcon?: boolean;
|
|
42
|
+
endIcon?: ReactNode;
|
|
41
43
|
className?: string;
|
|
42
44
|
} & Omit<React.InputHTMLAttributes<HTMLInputElement>, "size">;
|
|
43
45
|
declare const TextInput: FC<InputProps>;
|
|
@@ -63,6 +65,31 @@ interface TabsProps {
|
|
|
63
65
|
}
|
|
64
66
|
declare const Tabs: React.FC<TabsProps>;
|
|
65
67
|
|
|
68
|
+
type Options = {
|
|
69
|
+
value: string;
|
|
70
|
+
label: string;
|
|
71
|
+
};
|
|
72
|
+
type DropdownProps = {
|
|
73
|
+
id?: string;
|
|
74
|
+
label?: string;
|
|
75
|
+
size?: "sm" | "md" | "lg";
|
|
76
|
+
rounded?: "none" | "normal" | "full";
|
|
77
|
+
variant?: "flat" | "outline" | "underline";
|
|
78
|
+
helperText?: string;
|
|
79
|
+
errorMessage?: string;
|
|
80
|
+
filterMode?: boolean;
|
|
81
|
+
fullwidth?: boolean;
|
|
82
|
+
disabled?: boolean;
|
|
83
|
+
error?: boolean;
|
|
84
|
+
required?: boolean;
|
|
85
|
+
className?: string;
|
|
86
|
+
options: Options[];
|
|
87
|
+
value?: Options;
|
|
88
|
+
onChangeText?: InputProps["onChange"];
|
|
89
|
+
onSelect?: (value: Options) => void;
|
|
90
|
+
} & Omit<InputProps, "value">;
|
|
91
|
+
declare const Dropdown: ({ id, options, value, label, size, rounded, variant, helperText, errorMessage, fullwidth, disabled, error, filterMode, required, onChangeText, onSelect, ...props }: DropdownProps) => react_jsx_runtime.JSX.Element;
|
|
92
|
+
|
|
66
93
|
declare const resloveTimestamp: (timestamp: number) => number;
|
|
67
94
|
declare const getStartDateOfDay: (date: Date) => Date;
|
|
68
95
|
declare const getEndDateOfDay: (date: Date) => Date;
|
|
@@ -72,4 +99,4 @@ declare const getStartEndTimestampOfDay: () => {
|
|
|
72
99
|
};
|
|
73
100
|
declare const getTimestampUTC: (date: Date) => number;
|
|
74
101
|
|
|
75
|
-
export { Button, Table, Tabs, Text, TextInput, getEndDateOfDay, getStartDateOfDay, getStartEndTimestampOfDay, getTimestampUTC, resloveTimestamp };
|
|
102
|
+
export { Button, Dropdown, Table, Tabs, Text, TextInput, getEndDateOfDay, getStartDateOfDay, getStartEndTimestampOfDay, getTimestampUTC, resloveTimestamp };
|
package/dist/index.js
CHANGED
|
@@ -6,6 +6,7 @@ export { default as Table } from "./components/Table/Table";
|
|
|
6
6
|
export { default as TextInput } from "./components/TextInput/TextInput";
|
|
7
7
|
export { default as Text } from "./components/Text/Text";
|
|
8
8
|
export { default as Tabs } from "./components/Tabs/Tabs";
|
|
9
|
+
export { default as Dropdown } from "./components/Dropdown/Dropdown";
|
|
9
10
|
// UTILS
|
|
10
11
|
export { resloveTimestamp, getStartDateOfDay, getEndDateOfDay, getStartEndTimestampOfDay, getTimestampUTC, } from "./utils/datetime";
|
|
11
12
|
// const mainPreset = require("./theme/main-preset");
|