@alfalab/core-components-switch 2.3.2 → 2.4.1
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/CHANGELOG.md +30 -0
- package/dist/Component.d.ts +103 -0
- package/{Component.js → dist/Component.js} +1 -1
- package/dist/cssm/Component.d.ts +103 -0
- package/{cssm → dist/cssm}/Component.js +0 -0
- package/{cssm → dist/cssm}/index.d.ts +0 -0
- package/{cssm → dist/cssm}/index.js +0 -0
- package/{cssm → dist/cssm}/index.module.css +0 -0
- package/dist/esm/Component.d.ts +103 -0
- package/{esm → dist/esm}/Component.js +1 -1
- package/{modern → dist/esm}/index.css +26 -26
- package/{esm → dist/esm}/index.d.ts +0 -0
- package/{esm → dist/esm}/index.js +0 -0
- package/{index.css → dist/index.css} +26 -26
- package/{index.d.ts → dist/index.d.ts} +0 -0
- package/{index.js → dist/index.js} +0 -0
- package/dist/modern/Component.d.ts +103 -0
- package/{modern → dist/modern}/Component.js +1 -1
- package/{esm → dist/modern}/index.css +26 -26
- package/{modern → dist/modern}/index.d.ts +0 -0
- package/{modern → dist/modern}/index.js +0 -0
- package/{send-stats.js → dist/send-stats.js} +0 -0
- package/package.json +11 -9
- package/Component.d.ts +0 -103
- package/cssm/Component.d.ts +0 -103
- package/esm/Component.d.ts +0 -103
- package/modern/Component.d.ts +0 -103
package/cssm/Component.d.ts
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { InputHTMLAttributes, ChangeEvent, ReactNode } from "react";
|
|
4
|
-
type Align = 'start' | 'center';
|
|
5
|
-
type SwitchProps = Omit<InputHTMLAttributes<HTMLInputElement>, 'type' | 'hint' | 'onChange' | 'disabled'> & {
|
|
6
|
-
/**
|
|
7
|
-
* Управление состоянием вкл/выкл компонента
|
|
8
|
-
*/
|
|
9
|
-
checked?: boolean;
|
|
10
|
-
/**
|
|
11
|
-
* Текст подписи к переключателю
|
|
12
|
-
*/
|
|
13
|
-
label?: ReactNode;
|
|
14
|
-
/**
|
|
15
|
-
* Текст подсказки снизу
|
|
16
|
-
*/
|
|
17
|
-
hint?: ReactNode;
|
|
18
|
-
/**
|
|
19
|
-
* Переключатель будет отрисован справа от контента
|
|
20
|
-
*/
|
|
21
|
-
reversed?: boolean;
|
|
22
|
-
/**
|
|
23
|
-
* Выравнивание
|
|
24
|
-
*/
|
|
25
|
-
align?: Align;
|
|
26
|
-
/**
|
|
27
|
-
* Дополнительный слот
|
|
28
|
-
*/
|
|
29
|
-
addons?: React.ReactNode;
|
|
30
|
-
/**
|
|
31
|
-
* Растягивать ли компонент на всю ширину
|
|
32
|
-
*/
|
|
33
|
-
block?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Управление состоянием включен / выключен
|
|
36
|
-
*/
|
|
37
|
-
disabled?: boolean;
|
|
38
|
-
/**
|
|
39
|
-
* Управление состоянием активен / неактивен
|
|
40
|
-
*/
|
|
41
|
-
inactive?: boolean;
|
|
42
|
-
/**
|
|
43
|
-
* Обработчик переключения компонента
|
|
44
|
-
*/
|
|
45
|
-
onChange?: (event?: ChangeEvent<HTMLInputElement>, payload?: {
|
|
46
|
-
checked: boolean;
|
|
47
|
-
name: InputHTMLAttributes<HTMLInputElement>['name'];
|
|
48
|
-
}) => void;
|
|
49
|
-
/**
|
|
50
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
51
|
-
*/
|
|
52
|
-
dataTestId?: string;
|
|
53
|
-
};
|
|
54
|
-
declare const Switch: React.ForwardRefExoticComponent<Pick<React.InputHTMLAttributes<HTMLInputElement>, "accept" | "alt" | "autoComplete" | "autoFocus" | "capture" | "checked" | "crossOrigin" | "form" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "height" | "list" | "max" | "maxLength" | "min" | "minLength" | "multiple" | "name" | "pattern" | "placeholder" | "readOnly" | "required" | "size" | "src" | "step" | "value" | "width" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & {
|
|
55
|
-
/**
|
|
56
|
-
* Управление состоянием вкл/выкл компонента
|
|
57
|
-
*/
|
|
58
|
-
checked?: boolean | undefined;
|
|
59
|
-
/**
|
|
60
|
-
* Текст подписи к переключателю
|
|
61
|
-
*/
|
|
62
|
-
label?: React.ReactNode;
|
|
63
|
-
/**
|
|
64
|
-
* Текст подсказки снизу
|
|
65
|
-
*/
|
|
66
|
-
hint?: React.ReactNode;
|
|
67
|
-
/**
|
|
68
|
-
* Переключатель будет отрисован справа от контента
|
|
69
|
-
*/
|
|
70
|
-
reversed?: boolean | undefined;
|
|
71
|
-
/**
|
|
72
|
-
* Выравнивание
|
|
73
|
-
*/
|
|
74
|
-
align?: "start" | "center" | undefined;
|
|
75
|
-
/**
|
|
76
|
-
* Дополнительный слот
|
|
77
|
-
*/
|
|
78
|
-
addons?: React.ReactNode;
|
|
79
|
-
/**
|
|
80
|
-
* Растягивать ли компонент на всю ширину
|
|
81
|
-
*/
|
|
82
|
-
block?: boolean | undefined;
|
|
83
|
-
/**
|
|
84
|
-
* Управление состоянием включен / выключен
|
|
85
|
-
*/
|
|
86
|
-
disabled?: boolean | undefined;
|
|
87
|
-
/**
|
|
88
|
-
* Управление состоянием активен / неактивен
|
|
89
|
-
*/
|
|
90
|
-
inactive?: boolean | undefined;
|
|
91
|
-
/**
|
|
92
|
-
* Обработчик переключения компонента
|
|
93
|
-
*/
|
|
94
|
-
onChange?: ((event?: React.ChangeEvent<HTMLInputElement> | undefined, payload?: {
|
|
95
|
-
checked: boolean;
|
|
96
|
-
name: string | undefined;
|
|
97
|
-
} | undefined) => void) | undefined;
|
|
98
|
-
/**
|
|
99
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
100
|
-
*/
|
|
101
|
-
dataTestId?: string | undefined;
|
|
102
|
-
} & React.RefAttributes<HTMLLabelElement>>;
|
|
103
|
-
export { SwitchProps, Switch };
|
package/esm/Component.d.ts
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { InputHTMLAttributes, ChangeEvent, ReactNode } from "react";
|
|
4
|
-
type Align = 'start' | 'center';
|
|
5
|
-
type SwitchProps = Omit<InputHTMLAttributes<HTMLInputElement>, 'type' | 'hint' | 'onChange' | 'disabled'> & {
|
|
6
|
-
/**
|
|
7
|
-
* Управление состоянием вкл/выкл компонента
|
|
8
|
-
*/
|
|
9
|
-
checked?: boolean;
|
|
10
|
-
/**
|
|
11
|
-
* Текст подписи к переключателю
|
|
12
|
-
*/
|
|
13
|
-
label?: ReactNode;
|
|
14
|
-
/**
|
|
15
|
-
* Текст подсказки снизу
|
|
16
|
-
*/
|
|
17
|
-
hint?: ReactNode;
|
|
18
|
-
/**
|
|
19
|
-
* Переключатель будет отрисован справа от контента
|
|
20
|
-
*/
|
|
21
|
-
reversed?: boolean;
|
|
22
|
-
/**
|
|
23
|
-
* Выравнивание
|
|
24
|
-
*/
|
|
25
|
-
align?: Align;
|
|
26
|
-
/**
|
|
27
|
-
* Дополнительный слот
|
|
28
|
-
*/
|
|
29
|
-
addons?: React.ReactNode;
|
|
30
|
-
/**
|
|
31
|
-
* Растягивать ли компонент на всю ширину
|
|
32
|
-
*/
|
|
33
|
-
block?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Управление состоянием включен / выключен
|
|
36
|
-
*/
|
|
37
|
-
disabled?: boolean;
|
|
38
|
-
/**
|
|
39
|
-
* Управление состоянием активен / неактивен
|
|
40
|
-
*/
|
|
41
|
-
inactive?: boolean;
|
|
42
|
-
/**
|
|
43
|
-
* Обработчик переключения компонента
|
|
44
|
-
*/
|
|
45
|
-
onChange?: (event?: ChangeEvent<HTMLInputElement>, payload?: {
|
|
46
|
-
checked: boolean;
|
|
47
|
-
name: InputHTMLAttributes<HTMLInputElement>['name'];
|
|
48
|
-
}) => void;
|
|
49
|
-
/**
|
|
50
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
51
|
-
*/
|
|
52
|
-
dataTestId?: string;
|
|
53
|
-
};
|
|
54
|
-
declare const Switch: React.ForwardRefExoticComponent<Pick<React.InputHTMLAttributes<HTMLInputElement>, "accept" | "alt" | "autoComplete" | "autoFocus" | "capture" | "checked" | "crossOrigin" | "form" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "height" | "list" | "max" | "maxLength" | "min" | "minLength" | "multiple" | "name" | "pattern" | "placeholder" | "readOnly" | "required" | "size" | "src" | "step" | "value" | "width" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & {
|
|
55
|
-
/**
|
|
56
|
-
* Управление состоянием вкл/выкл компонента
|
|
57
|
-
*/
|
|
58
|
-
checked?: boolean | undefined;
|
|
59
|
-
/**
|
|
60
|
-
* Текст подписи к переключателю
|
|
61
|
-
*/
|
|
62
|
-
label?: React.ReactNode;
|
|
63
|
-
/**
|
|
64
|
-
* Текст подсказки снизу
|
|
65
|
-
*/
|
|
66
|
-
hint?: React.ReactNode;
|
|
67
|
-
/**
|
|
68
|
-
* Переключатель будет отрисован справа от контента
|
|
69
|
-
*/
|
|
70
|
-
reversed?: boolean | undefined;
|
|
71
|
-
/**
|
|
72
|
-
* Выравнивание
|
|
73
|
-
*/
|
|
74
|
-
align?: "start" | "center" | undefined;
|
|
75
|
-
/**
|
|
76
|
-
* Дополнительный слот
|
|
77
|
-
*/
|
|
78
|
-
addons?: React.ReactNode;
|
|
79
|
-
/**
|
|
80
|
-
* Растягивать ли компонент на всю ширину
|
|
81
|
-
*/
|
|
82
|
-
block?: boolean | undefined;
|
|
83
|
-
/**
|
|
84
|
-
* Управление состоянием включен / выключен
|
|
85
|
-
*/
|
|
86
|
-
disabled?: boolean | undefined;
|
|
87
|
-
/**
|
|
88
|
-
* Управление состоянием активен / неактивен
|
|
89
|
-
*/
|
|
90
|
-
inactive?: boolean | undefined;
|
|
91
|
-
/**
|
|
92
|
-
* Обработчик переключения компонента
|
|
93
|
-
*/
|
|
94
|
-
onChange?: ((event?: React.ChangeEvent<HTMLInputElement> | undefined, payload?: {
|
|
95
|
-
checked: boolean;
|
|
96
|
-
name: string | undefined;
|
|
97
|
-
} | undefined) => void) | undefined;
|
|
98
|
-
/**
|
|
99
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
100
|
-
*/
|
|
101
|
-
dataTestId?: string | undefined;
|
|
102
|
-
} & React.RefAttributes<HTMLLabelElement>>;
|
|
103
|
-
export { SwitchProps, Switch };
|
package/modern/Component.d.ts
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { InputHTMLAttributes, ChangeEvent, ReactNode } from "react";
|
|
4
|
-
type Align = 'start' | 'center';
|
|
5
|
-
type SwitchProps = Omit<InputHTMLAttributes<HTMLInputElement>, 'type' | 'hint' | 'onChange' | 'disabled'> & {
|
|
6
|
-
/**
|
|
7
|
-
* Управление состоянием вкл/выкл компонента
|
|
8
|
-
*/
|
|
9
|
-
checked?: boolean;
|
|
10
|
-
/**
|
|
11
|
-
* Текст подписи к переключателю
|
|
12
|
-
*/
|
|
13
|
-
label?: ReactNode;
|
|
14
|
-
/**
|
|
15
|
-
* Текст подсказки снизу
|
|
16
|
-
*/
|
|
17
|
-
hint?: ReactNode;
|
|
18
|
-
/**
|
|
19
|
-
* Переключатель будет отрисован справа от контента
|
|
20
|
-
*/
|
|
21
|
-
reversed?: boolean;
|
|
22
|
-
/**
|
|
23
|
-
* Выравнивание
|
|
24
|
-
*/
|
|
25
|
-
align?: Align;
|
|
26
|
-
/**
|
|
27
|
-
* Дополнительный слот
|
|
28
|
-
*/
|
|
29
|
-
addons?: React.ReactNode;
|
|
30
|
-
/**
|
|
31
|
-
* Растягивать ли компонент на всю ширину
|
|
32
|
-
*/
|
|
33
|
-
block?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Управление состоянием включен / выключен
|
|
36
|
-
*/
|
|
37
|
-
disabled?: boolean;
|
|
38
|
-
/**
|
|
39
|
-
* Управление состоянием активен / неактивен
|
|
40
|
-
*/
|
|
41
|
-
inactive?: boolean;
|
|
42
|
-
/**
|
|
43
|
-
* Обработчик переключения компонента
|
|
44
|
-
*/
|
|
45
|
-
onChange?: (event?: ChangeEvent<HTMLInputElement>, payload?: {
|
|
46
|
-
checked: boolean;
|
|
47
|
-
name: InputHTMLAttributes<HTMLInputElement>['name'];
|
|
48
|
-
}) => void;
|
|
49
|
-
/**
|
|
50
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
51
|
-
*/
|
|
52
|
-
dataTestId?: string;
|
|
53
|
-
};
|
|
54
|
-
declare const Switch: React.ForwardRefExoticComponent<Pick<React.InputHTMLAttributes<HTMLInputElement>, "accept" | "alt" | "autoComplete" | "autoFocus" | "capture" | "checked" | "crossOrigin" | "form" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "height" | "list" | "max" | "maxLength" | "min" | "minLength" | "multiple" | "name" | "pattern" | "placeholder" | "readOnly" | "required" | "size" | "src" | "step" | "value" | "width" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & {
|
|
55
|
-
/**
|
|
56
|
-
* Управление состоянием вкл/выкл компонента
|
|
57
|
-
*/
|
|
58
|
-
checked?: boolean | undefined;
|
|
59
|
-
/**
|
|
60
|
-
* Текст подписи к переключателю
|
|
61
|
-
*/
|
|
62
|
-
label?: React.ReactNode;
|
|
63
|
-
/**
|
|
64
|
-
* Текст подсказки снизу
|
|
65
|
-
*/
|
|
66
|
-
hint?: React.ReactNode;
|
|
67
|
-
/**
|
|
68
|
-
* Переключатель будет отрисован справа от контента
|
|
69
|
-
*/
|
|
70
|
-
reversed?: boolean | undefined;
|
|
71
|
-
/**
|
|
72
|
-
* Выравнивание
|
|
73
|
-
*/
|
|
74
|
-
align?: "start" | "center" | undefined;
|
|
75
|
-
/**
|
|
76
|
-
* Дополнительный слот
|
|
77
|
-
*/
|
|
78
|
-
addons?: React.ReactNode;
|
|
79
|
-
/**
|
|
80
|
-
* Растягивать ли компонент на всю ширину
|
|
81
|
-
*/
|
|
82
|
-
block?: boolean | undefined;
|
|
83
|
-
/**
|
|
84
|
-
* Управление состоянием включен / выключен
|
|
85
|
-
*/
|
|
86
|
-
disabled?: boolean | undefined;
|
|
87
|
-
/**
|
|
88
|
-
* Управление состоянием активен / неактивен
|
|
89
|
-
*/
|
|
90
|
-
inactive?: boolean | undefined;
|
|
91
|
-
/**
|
|
92
|
-
* Обработчик переключения компонента
|
|
93
|
-
*/
|
|
94
|
-
onChange?: ((event?: React.ChangeEvent<HTMLInputElement> | undefined, payload?: {
|
|
95
|
-
checked: boolean;
|
|
96
|
-
name: string | undefined;
|
|
97
|
-
} | undefined) => void) | undefined;
|
|
98
|
-
/**
|
|
99
|
-
* Идентификатор для систем автоматизированного тестирования
|
|
100
|
-
*/
|
|
101
|
-
dataTestId?: string | undefined;
|
|
102
|
-
} & React.RefAttributes<HTMLLabelElement>>;
|
|
103
|
-
export { SwitchProps, Switch };
|