react-restyle-components 0.2.24 → 0.2.26
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/lib/package.json +5 -5
- package/lib/src/App.js +2 -2
- package/lib/src/core-components/atoms/button/Button.stories.d.ts +2 -17
- package/lib/src/core-components/atoms/button/Button.stories.js +2 -39
- package/lib/src/core-components/atoms/button/Button.types.d.ts +1 -12
- package/lib/src/core-components/atoms/button/button.component.d.ts +1 -0
- package/lib/src/core-components/atoms/button/button.component.js +7 -6
- package/lib/src/core-components/atoms/button/buttonGroup/ButtonGroup.stories.d.ts +0 -17
- package/lib/src/core-components/atoms/button/buttonGroup/ButtonGroup.stories.js +4 -232
- package/lib/src/core-components/atoms/button/buttonGroup/buttonGroup.component.d.ts +1 -0
- package/lib/src/core-components/atoms/button/buttonGroup/buttonGroup.component.js +2 -3
- package/lib/src/core-components/atoms/tooltip/Tooltip.stories.d.ts +1 -2
- package/lib/src/core-components/atoms/tooltip/Tooltip.stories.js +5 -5
- package/lib/src/core-components/atoms/tooltip/Tooltip.types.d.ts +0 -2
- package/lib/src/core-components/atoms/tooltip/tooltip.component.d.ts +1 -2
- package/lib/src/core-components/atoms/tooltip/tooltip.component.js +11 -11
- package/lib/src/core-components/index.d.ts +0 -2
- package/lib/src/core-components/index.js +0 -2
- package/lib/tc.css +1 -1
- package/package.json +5 -5
- package/lib/src/core-components/atoms/button/LinkButton.stories.d.ts +0 -302
- package/lib/src/core-components/atoms/button/LinkButton.stories.js +0 -52
- package/lib/src/core-components/atoms/button/ToggleButton.stories.d.ts +0 -337
- package/lib/src/core-components/atoms/button/ToggleButton.stories.js +0 -62
- package/lib/src/core-components/atoms/button/button.module.css +0 -477
- package/lib/src/core-components/atoms/button/linkButton.component.d.ts +0 -9
- package/lib/src/core-components/atoms/button/linkButton.component.js +0 -20
- package/lib/src/core-components/atoms/button/toggleButton.component.d.ts +0 -10
- package/lib/src/core-components/atoms/button/toggleButton.component.js +0 -21
- package/lib/src/core-components/atoms/tooltip/Tooltip.module.css +0 -44
|
@@ -1,337 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import type { StoryObj } from '@storybook/react';
|
|
3
|
-
declare const meta: {
|
|
4
|
-
title: string;
|
|
5
|
-
component: React.ForwardRefExoticComponent<Omit<import("./Button.types").ButtonProps, "variant"> & {
|
|
6
|
-
labelClassName?: string | undefined;
|
|
7
|
-
contentClassName?: string | undefined;
|
|
8
|
-
active?: boolean | undefined;
|
|
9
|
-
variant?: "brand" | "accent" | undefined;
|
|
10
|
-
} & React.InputHTMLAttributes<HTMLInputElement> & React.RefAttributes<HTMLInputElement>>;
|
|
11
|
-
tags: string[];
|
|
12
|
-
decorators: ((Story: import("@storybook/csf").PartialStoryFn<import("@storybook/react/dist/types-a5624094").R, {
|
|
13
|
-
className?: string | undefined;
|
|
14
|
-
focus?: "none" | "visible" | "focus" | undefined;
|
|
15
|
-
loading?: boolean | undefined;
|
|
16
|
-
tooltip?: string | undefined;
|
|
17
|
-
level?: "primary" | "secondary" | undefined;
|
|
18
|
-
scale?: "s" | "xl" | "l" | "m" | "xs" | "xxs" | undefined;
|
|
19
|
-
iconOnly?: boolean | undefined;
|
|
20
|
-
labelClassName?: string | undefined;
|
|
21
|
-
contentClassName?: string | undefined;
|
|
22
|
-
active?: boolean | undefined;
|
|
23
|
-
variant?: "brand" | "accent" | undefined;
|
|
24
|
-
accept?: string | undefined;
|
|
25
|
-
alt?: string | undefined;
|
|
26
|
-
autoComplete?: React.HTMLInputAutoCompleteAttribute | undefined;
|
|
27
|
-
capture?: boolean | "user" | "environment" | undefined;
|
|
28
|
-
checked?: boolean | undefined;
|
|
29
|
-
disabled?: boolean | undefined;
|
|
30
|
-
form?: string | undefined;
|
|
31
|
-
formAction?: string | undefined;
|
|
32
|
-
formEncType?: string | undefined;
|
|
33
|
-
formMethod?: string | undefined;
|
|
34
|
-
formNoValidate?: boolean | undefined;
|
|
35
|
-
formTarget?: string | undefined;
|
|
36
|
-
height?: string | number | undefined;
|
|
37
|
-
list?: string | undefined;
|
|
38
|
-
max?: string | number | undefined;
|
|
39
|
-
maxLength?: number | undefined;
|
|
40
|
-
min?: string | number | undefined;
|
|
41
|
-
minLength?: number | undefined;
|
|
42
|
-
multiple?: boolean | undefined;
|
|
43
|
-
name?: string | undefined;
|
|
44
|
-
pattern?: string | undefined;
|
|
45
|
-
placeholder?: string | undefined;
|
|
46
|
-
readOnly?: boolean | undefined;
|
|
47
|
-
required?: boolean | undefined;
|
|
48
|
-
size?: number | undefined;
|
|
49
|
-
src?: string | undefined;
|
|
50
|
-
step?: string | number | undefined;
|
|
51
|
-
type?: React.HTMLInputTypeAttribute | undefined;
|
|
52
|
-
value?: string | number | readonly string[] | undefined;
|
|
53
|
-
width?: string | number | undefined;
|
|
54
|
-
onChange?: React.ChangeEventHandler<HTMLInputElement> | undefined;
|
|
55
|
-
defaultChecked?: boolean | undefined;
|
|
56
|
-
defaultValue?: string | number | readonly string[] | undefined;
|
|
57
|
-
suppressContentEditableWarning?: boolean | undefined;
|
|
58
|
-
suppressHydrationWarning?: boolean | undefined;
|
|
59
|
-
accessKey?: string | undefined;
|
|
60
|
-
autoCapitalize?: (string & {}) | "off" | "on" | "none" | "sentences" | "words" | "characters" | undefined;
|
|
61
|
-
autoFocus?: boolean | undefined;
|
|
62
|
-
contentEditable?: (boolean | "true" | "false") | "inherit" | "plaintext-only" | undefined;
|
|
63
|
-
contextMenu?: string | undefined;
|
|
64
|
-
dir?: string | undefined;
|
|
65
|
-
draggable?: (boolean | "true" | "false") | undefined;
|
|
66
|
-
enterKeyHint?: "search" | "enter" | "done" | "go" | "next" | "previous" | "send" | undefined;
|
|
67
|
-
hidden?: boolean | undefined;
|
|
68
|
-
id?: string | undefined;
|
|
69
|
-
lang?: string | undefined;
|
|
70
|
-
nonce?: string | undefined;
|
|
71
|
-
slot?: string | undefined;
|
|
72
|
-
spellCheck?: (boolean | "true" | "false") | undefined;
|
|
73
|
-
style?: React.CSSProperties | undefined;
|
|
74
|
-
tabIndex?: number | undefined;
|
|
75
|
-
title?: string | undefined;
|
|
76
|
-
translate?: "yes" | "no" | undefined;
|
|
77
|
-
radioGroup?: string | undefined;
|
|
78
|
-
role?: React.AriaRole | undefined;
|
|
79
|
-
about?: string | undefined;
|
|
80
|
-
content?: string | undefined;
|
|
81
|
-
datatype?: string | undefined;
|
|
82
|
-
inlist?: any;
|
|
83
|
-
prefix?: string | undefined;
|
|
84
|
-
property?: string | undefined;
|
|
85
|
-
rel?: string | undefined;
|
|
86
|
-
resource?: string | undefined;
|
|
87
|
-
rev?: string | undefined;
|
|
88
|
-
typeof?: string | undefined;
|
|
89
|
-
vocab?: string | undefined;
|
|
90
|
-
autoCorrect?: string | undefined;
|
|
91
|
-
autoSave?: string | undefined;
|
|
92
|
-
color?: string | undefined;
|
|
93
|
-
itemProp?: string | undefined;
|
|
94
|
-
itemScope?: boolean | undefined;
|
|
95
|
-
itemType?: string | undefined;
|
|
96
|
-
itemID?: string | undefined;
|
|
97
|
-
itemRef?: string | undefined;
|
|
98
|
-
results?: number | undefined;
|
|
99
|
-
security?: string | undefined;
|
|
100
|
-
unselectable?: "off" | "on" | undefined;
|
|
101
|
-
inputMode?: "search" | "text" | "email" | "tel" | "url" | "none" | "numeric" | "decimal" | undefined;
|
|
102
|
-
is?: string | undefined;
|
|
103
|
-
"aria-activedescendant"?: string | undefined;
|
|
104
|
-
"aria-atomic"?: (boolean | "true" | "false") | undefined;
|
|
105
|
-
"aria-autocomplete"?: "none" | "list" | "inline" | "both" | undefined;
|
|
106
|
-
"aria-braillelabel"?: string | undefined;
|
|
107
|
-
"aria-brailleroledescription"?: string | undefined;
|
|
108
|
-
"aria-busy"?: (boolean | "true" | "false") | undefined;
|
|
109
|
-
"aria-checked"?: boolean | "true" | "false" | "mixed" | undefined;
|
|
110
|
-
"aria-colcount"?: number | undefined;
|
|
111
|
-
"aria-colindex"?: number | undefined;
|
|
112
|
-
"aria-colindextext"?: string | undefined;
|
|
113
|
-
"aria-colspan"?: number | undefined;
|
|
114
|
-
"aria-controls"?: string | undefined;
|
|
115
|
-
"aria-current"?: boolean | "time" | "date" | "true" | "false" | "page" | "step" | "location" | undefined;
|
|
116
|
-
"aria-describedby"?: string | undefined;
|
|
117
|
-
"aria-description"?: string | undefined;
|
|
118
|
-
"aria-details"?: string | undefined;
|
|
119
|
-
"aria-disabled"?: (boolean | "true" | "false") | undefined;
|
|
120
|
-
"aria-dropeffect"?: "link" | "none" | "copy" | "execute" | "move" | "popup" | undefined;
|
|
121
|
-
"aria-errormessage"?: string | undefined;
|
|
122
|
-
"aria-expanded"?: (boolean | "true" | "false") | undefined;
|
|
123
|
-
"aria-flowto"?: string | undefined;
|
|
124
|
-
"aria-grabbed"?: (boolean | "true" | "false") | undefined;
|
|
125
|
-
"aria-haspopup"?: boolean | "dialog" | "menu" | "true" | "false" | "grid" | "listbox" | "tree" | undefined;
|
|
126
|
-
"aria-hidden"?: (boolean | "true" | "false") | undefined;
|
|
127
|
-
"aria-invalid"?: boolean | "true" | "false" | "grammar" | "spelling" | undefined;
|
|
128
|
-
"aria-keyshortcuts"?: string | undefined;
|
|
129
|
-
"aria-label"?: string | undefined;
|
|
130
|
-
"aria-labelledby"?: string | undefined;
|
|
131
|
-
"aria-level"?: number | undefined;
|
|
132
|
-
"aria-live"?: "off" | "assertive" | "polite" | undefined;
|
|
133
|
-
"aria-modal"?: (boolean | "true" | "false") | undefined;
|
|
134
|
-
"aria-multiline"?: (boolean | "true" | "false") | undefined;
|
|
135
|
-
"aria-multiselectable"?: (boolean | "true" | "false") | undefined;
|
|
136
|
-
"aria-orientation"?: "horizontal" | "vertical" | undefined;
|
|
137
|
-
"aria-owns"?: string | undefined;
|
|
138
|
-
"aria-placeholder"?: string | undefined;
|
|
139
|
-
"aria-posinset"?: number | undefined;
|
|
140
|
-
"aria-pressed"?: boolean | "true" | "false" | "mixed" | undefined;
|
|
141
|
-
"aria-readonly"?: (boolean | "true" | "false") | undefined;
|
|
142
|
-
"aria-relevant"?: "text" | "additions" | "additions removals" | "additions text" | "all" | "removals" | "removals additions" | "removals text" | "text additions" | "text removals" | undefined;
|
|
143
|
-
"aria-required"?: (boolean | "true" | "false") | undefined;
|
|
144
|
-
"aria-roledescription"?: string | undefined;
|
|
145
|
-
"aria-rowcount"?: number | undefined;
|
|
146
|
-
"aria-rowindex"?: number | undefined;
|
|
147
|
-
"aria-rowindextext"?: string | undefined;
|
|
148
|
-
"aria-rowspan"?: number | undefined;
|
|
149
|
-
"aria-selected"?: (boolean | "true" | "false") | undefined;
|
|
150
|
-
"aria-setsize"?: number | undefined;
|
|
151
|
-
"aria-sort"?: "none" | "ascending" | "descending" | "other" | undefined;
|
|
152
|
-
"aria-valuemax"?: number | undefined;
|
|
153
|
-
"aria-valuemin"?: number | undefined;
|
|
154
|
-
"aria-valuenow"?: number | undefined;
|
|
155
|
-
"aria-valuetext"?: string | undefined;
|
|
156
|
-
children?: React.ReactNode;
|
|
157
|
-
dangerouslySetInnerHTML?: {
|
|
158
|
-
__html: string | TrustedHTML;
|
|
159
|
-
} | undefined;
|
|
160
|
-
onCopy?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
161
|
-
onCopyCapture?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
162
|
-
onCut?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
163
|
-
onCutCapture?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
164
|
-
onPaste?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
165
|
-
onPasteCapture?: React.ClipboardEventHandler<HTMLInputElement> | undefined;
|
|
166
|
-
onCompositionEnd?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
167
|
-
onCompositionEndCapture?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
168
|
-
onCompositionStart?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
169
|
-
onCompositionStartCapture?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
170
|
-
onCompositionUpdate?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
171
|
-
onCompositionUpdateCapture?: React.CompositionEventHandler<HTMLInputElement> | undefined;
|
|
172
|
-
onFocus?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
173
|
-
onFocusCapture?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
174
|
-
onBlur?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
175
|
-
onBlurCapture?: React.FocusEventHandler<HTMLInputElement> | undefined;
|
|
176
|
-
onChangeCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
177
|
-
onBeforeInput?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
178
|
-
onBeforeInputCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
179
|
-
onInput?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
180
|
-
onInputCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
181
|
-
onReset?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
182
|
-
onResetCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
183
|
-
onSubmit?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
184
|
-
onSubmitCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
185
|
-
onInvalid?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
186
|
-
onInvalidCapture?: React.FormEventHandler<HTMLInputElement> | undefined;
|
|
187
|
-
onLoad?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
188
|
-
onLoadCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
189
|
-
onError?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
190
|
-
onErrorCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
191
|
-
onKeyDown?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
192
|
-
onKeyDownCapture?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
193
|
-
onKeyPress?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
194
|
-
onKeyPressCapture?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
195
|
-
onKeyUp?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
196
|
-
onKeyUpCapture?: React.KeyboardEventHandler<HTMLInputElement> | undefined;
|
|
197
|
-
onAbort?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
198
|
-
onAbortCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
199
|
-
onCanPlay?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
200
|
-
onCanPlayCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
201
|
-
onCanPlayThrough?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
202
|
-
onCanPlayThroughCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
203
|
-
onDurationChange?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
204
|
-
onDurationChangeCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
205
|
-
onEmptied?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
206
|
-
onEmptiedCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
207
|
-
onEncrypted?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
208
|
-
onEncryptedCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
209
|
-
onEnded?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
210
|
-
onEndedCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
211
|
-
onLoadedData?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
212
|
-
onLoadedDataCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
213
|
-
onLoadedMetadata?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
214
|
-
onLoadedMetadataCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
215
|
-
onLoadStart?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
216
|
-
onLoadStartCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
217
|
-
onPause?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
218
|
-
onPauseCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
219
|
-
onPlay?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
220
|
-
onPlayCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
221
|
-
onPlaying?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
222
|
-
onPlayingCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
223
|
-
onProgress?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
224
|
-
onProgressCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
225
|
-
onRateChange?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
226
|
-
onRateChangeCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
227
|
-
onResize?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
228
|
-
onResizeCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
229
|
-
onSeeked?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
230
|
-
onSeekedCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
231
|
-
onSeeking?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
232
|
-
onSeekingCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
233
|
-
onStalled?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
234
|
-
onStalledCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
235
|
-
onSuspend?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
236
|
-
onSuspendCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
237
|
-
onTimeUpdate?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
238
|
-
onTimeUpdateCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
239
|
-
onVolumeChange?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
240
|
-
onVolumeChangeCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
241
|
-
onWaiting?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
242
|
-
onWaitingCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
243
|
-
onAuxClick?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
244
|
-
onAuxClickCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
245
|
-
onClick?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
246
|
-
onClickCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
247
|
-
onContextMenu?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
248
|
-
onContextMenuCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
249
|
-
onDoubleClick?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
250
|
-
onDoubleClickCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
251
|
-
onDrag?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
252
|
-
onDragCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
253
|
-
onDragEnd?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
254
|
-
onDragEndCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
255
|
-
onDragEnter?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
256
|
-
onDragEnterCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
257
|
-
onDragExit?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
258
|
-
onDragExitCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
259
|
-
onDragLeave?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
260
|
-
onDragLeaveCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
261
|
-
onDragOver?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
262
|
-
onDragOverCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
263
|
-
onDragStart?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
264
|
-
onDragStartCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
265
|
-
onDrop?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
266
|
-
onDropCapture?: React.DragEventHandler<HTMLInputElement> | undefined;
|
|
267
|
-
onMouseDown?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
268
|
-
onMouseDownCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
269
|
-
onMouseEnter?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
270
|
-
onMouseLeave?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
271
|
-
onMouseMove?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
272
|
-
onMouseMoveCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
273
|
-
onMouseOut?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
274
|
-
onMouseOutCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
275
|
-
onMouseOver?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
276
|
-
onMouseOverCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
277
|
-
onMouseUp?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
278
|
-
onMouseUpCapture?: React.MouseEventHandler<HTMLInputElement> | undefined;
|
|
279
|
-
onSelect?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
280
|
-
onSelectCapture?: React.ReactEventHandler<HTMLInputElement> | undefined;
|
|
281
|
-
onTouchCancel?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
282
|
-
onTouchCancelCapture?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
283
|
-
onTouchEnd?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
284
|
-
onTouchEndCapture?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
285
|
-
onTouchMove?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
286
|
-
onTouchMoveCapture?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
287
|
-
onTouchStart?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
288
|
-
onTouchStartCapture?: React.TouchEventHandler<HTMLInputElement> | undefined;
|
|
289
|
-
onPointerDown?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
290
|
-
onPointerDownCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
291
|
-
onPointerMove?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
292
|
-
onPointerMoveCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
293
|
-
onPointerUp?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
294
|
-
onPointerUpCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
295
|
-
onPointerCancel?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
296
|
-
onPointerCancelCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
297
|
-
onPointerEnter?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
298
|
-
onPointerLeave?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
299
|
-
onPointerOver?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
300
|
-
onPointerOverCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
301
|
-
onPointerOut?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
302
|
-
onPointerOutCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
303
|
-
onGotPointerCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
304
|
-
onGotPointerCaptureCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
305
|
-
onLostPointerCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
306
|
-
onLostPointerCaptureCapture?: React.PointerEventHandler<HTMLInputElement> | undefined;
|
|
307
|
-
onScroll?: React.UIEventHandler<HTMLInputElement> | undefined;
|
|
308
|
-
onScrollCapture?: React.UIEventHandler<HTMLInputElement> | undefined;
|
|
309
|
-
onWheel?: React.WheelEventHandler<HTMLInputElement> | undefined;
|
|
310
|
-
onWheelCapture?: React.WheelEventHandler<HTMLInputElement> | undefined;
|
|
311
|
-
onAnimationStart?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
312
|
-
onAnimationStartCapture?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
313
|
-
onAnimationEnd?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
314
|
-
onAnimationEndCapture?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
315
|
-
onAnimationIteration?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
316
|
-
onAnimationIterationCapture?: React.AnimationEventHandler<HTMLInputElement> | undefined;
|
|
317
|
-
onTransitionEnd?: React.TransitionEventHandler<HTMLInputElement> | undefined;
|
|
318
|
-
onTransitionEndCapture?: React.TransitionEventHandler<HTMLInputElement> | undefined;
|
|
319
|
-
ref?: React.LegacyRef<HTMLInputElement> | undefined;
|
|
320
|
-
key?: React.Key | null | undefined;
|
|
321
|
-
}>) => React.JSX.Element)[];
|
|
322
|
-
argTypes: {
|
|
323
|
-
disabled: {
|
|
324
|
-
control: "boolean";
|
|
325
|
-
};
|
|
326
|
-
onChange: {
|
|
327
|
-
action: string;
|
|
328
|
-
};
|
|
329
|
-
};
|
|
330
|
-
};
|
|
331
|
-
export default meta;
|
|
332
|
-
type Story = StoryObj<typeof meta>;
|
|
333
|
-
export declare const TextOnly: Story;
|
|
334
|
-
export declare const TextWithIconAtStart: Story;
|
|
335
|
-
export declare const TextWithIconAtEnd: Story;
|
|
336
|
-
export declare const IconOnly: Story;
|
|
337
|
-
export declare const Loading: Story;
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { BrowserRouter } from 'react-router-dom';
|
|
3
|
-
import Attach from '../../../assets/icons/attach.svg';
|
|
4
|
-
import { TooltipProvider } from '../tooltip/tooltip.component';
|
|
5
|
-
import { ToggleButton } from './toggleButton.component';
|
|
6
|
-
import { useState } from 'react';
|
|
7
|
-
// More on how to set up stories at: https://storybook.js.org/docs/react/writing-stories/introduction
|
|
8
|
-
const meta = {
|
|
9
|
-
title: 'Design System/Atoms/ToggleButton',
|
|
10
|
-
component: ToggleButton,
|
|
11
|
-
tags: ['autodocs'],
|
|
12
|
-
decorators: [
|
|
13
|
-
(Story) => (React.createElement(BrowserRouter, null,
|
|
14
|
-
React.createElement(TooltipProvider, null,
|
|
15
|
-
React.createElement(Story, null)))),
|
|
16
|
-
],
|
|
17
|
-
argTypes: {
|
|
18
|
-
disabled: { control: 'boolean' },
|
|
19
|
-
onChange: { action: 'clicked' },
|
|
20
|
-
},
|
|
21
|
-
};
|
|
22
|
-
export default meta;
|
|
23
|
-
// More on writing stories with args: https://storybook.js.org/docs/react/writing-stories/args
|
|
24
|
-
export const TextOnly = {
|
|
25
|
-
args: {
|
|
26
|
-
children: 'Button',
|
|
27
|
-
},
|
|
28
|
-
};
|
|
29
|
-
export const TextWithIconAtStart = {
|
|
30
|
-
render: (args) => (React.createElement(ToggleButton, { ...args },
|
|
31
|
-
React.createElement(Attach, null),
|
|
32
|
-
" Go to attachments")),
|
|
33
|
-
args: {},
|
|
34
|
-
};
|
|
35
|
-
export const TextWithIconAtEnd = {
|
|
36
|
-
render: (args) => (React.createElement(ToggleButton, { ...args },
|
|
37
|
-
"Go to attachments ",
|
|
38
|
-
React.createElement(Attach, null))),
|
|
39
|
-
args: {},
|
|
40
|
-
};
|
|
41
|
-
export const IconOnly = {
|
|
42
|
-
render: (args) => (React.createElement(ToggleButton, { ...args },
|
|
43
|
-
React.createElement(Attach, null))),
|
|
44
|
-
args: {
|
|
45
|
-
iconOnly: true,
|
|
46
|
-
},
|
|
47
|
-
};
|
|
48
|
-
export const Loading = {
|
|
49
|
-
render: function Render(args) {
|
|
50
|
-
const [loading, setLoading] = useState(false);
|
|
51
|
-
const [active, setActive] = useState(false);
|
|
52
|
-
const handleClick = () => {
|
|
53
|
-
setLoading(true);
|
|
54
|
-
setTimeout(() => {
|
|
55
|
-
setLoading(false);
|
|
56
|
-
setActive(!active);
|
|
57
|
-
}, 1000);
|
|
58
|
-
};
|
|
59
|
-
return (React.createElement(ToggleButton, { iconOnly: true, checked: active, onChange: handleClick, ...args, loading: loading, onClick: handleClick },
|
|
60
|
-
React.createElement(Attach, null)));
|
|
61
|
-
},
|
|
62
|
-
};
|