draft-components 0.48.0 → 0.51.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/checkbox/checkbox.d.ts +2 -1
- package/components/checkbox/checkbox.js +6 -2
- package/components/checkbox/checkbox.js.map +1 -1
- package/components/datetime-field/datetime-field.d.ts +1 -1
- package/components/number-field/number-field.d.ts +1 -1
- package/components/number-field/number-field.js +3 -7
- package/components/number-field/number-field.js.map +1 -1
- package/components/radio-button/radio-button.d.ts +2 -1
- package/components/radio-button/radio-button.js +6 -2
- package/components/radio-button/radio-button.js.map +1 -1
- package/components/search-field/search-field.d.ts +1 -1
- package/components/segmented-control/segmented-control.d.ts +4 -5
- package/components/segmented-control/segmented-control.js +11 -7
- package/components/segmented-control/segmented-control.js.map +1 -1
- package/components/select/select.d.ts +2 -1
- package/components/select/select.js +6 -2
- package/components/select/select.js.map +1 -1
- package/components/switch/switch.d.ts +1 -1
- package/components/switch/switch.js +6 -2
- package/components/switch/switch.js.map +1 -1
- package/components/table/index.d.ts +6 -0
- package/components/table/index.js +6 -0
- package/components/table/index.js.map +1 -1
- package/components/table/table-header-cell.d.ts +2 -2
- package/components/table/table-header-cell.js +2 -2
- package/components/table/table-header-cell.js.map +1 -1
- package/components/text-field/text-field.d.ts +2 -1
- package/components/text-field/text-field.js +4 -1
- package/components/text-field/text-field.js.map +1 -1
- package/components/textarea/textarea.d.ts +2 -1
- package/components/textarea/textarea.js +6 -2
- package/components/textarea/textarea.js.map +1 -1
- package/css/draft-components-utils.css +1 -1
- package/css/draft-components.css +1 -1
- package/package.json +3 -2
- package/scss/components/_radio-group.scss +2 -1
- package/scss/components/_table.scss +0 -5
- package/scss/utils/_borders.scss +21 -21
- package/scss/utils/_box-model.scss +7 -7
- package/scss/utils/_flexbox.scss +38 -38
- package/scss/utils/_margin.scss +11 -11
- package/scss/utils/_padding.scss +9 -9
- package/scss/utils/_typography.scss +35 -32
|
@@ -3,5 +3,6 @@ import { SelectionControlBaseProps } from '../selection-control';
|
|
|
3
3
|
export declare type CheckboxHtmlAttrs = Omit<ComponentPropsWithRef<'input'>, 'accept' | 'alt' | 'capture' | 'dirname' | 'formAction' | 'formEncType' | 'formMethod' | 'formNoValidate' | 'formTarget' | 'height' | 'max' | 'maxLength' | 'min' | 'minLength' | 'multiple' | 'pattern' | 'placeholder' | 'size' | 'src' | 'step' | 'type' | 'width'>;
|
|
4
4
|
export interface CheckboxProps extends SelectionControlBaseProps, CheckboxHtmlAttrs {
|
|
5
5
|
isMixed?: boolean;
|
|
6
|
+
onCheck?(checked: boolean): void;
|
|
6
7
|
}
|
|
7
|
-
export declare const Checkbox: import("react").ForwardRefExoticComponent<Pick<CheckboxProps, "form" | "label" | "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "name" | "role" | "tabIndex" | "crossOrigin" | "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" | "onChange" | "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" | "key" | "list" | "hidden" | "disabled" | "autoFocus" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "description" | "autoComplete" | "checked" | "enterKeyHint" | "readOnly" | "required" | "isMixed"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
8
|
+
export declare const Checkbox: import("react").ForwardRefExoticComponent<Pick<CheckboxProps, "form" | "label" | "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "name" | "role" | "tabIndex" | "crossOrigin" | "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" | "onChange" | "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" | "key" | "list" | "hidden" | "disabled" | "autoFocus" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "description" | "autoComplete" | "checked" | "enterKeyHint" | "readOnly" | "required" | "isMixed" | "onCheck"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -3,12 +3,16 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.Checkbox = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const react_1 = require("react");
|
|
6
|
+
const guards_1 = require("../../lib/guards");
|
|
6
7
|
const react_helpers_1 = require("../../lib/react-helpers");
|
|
7
8
|
const selection_control_1 = require("../selection-control");
|
|
8
9
|
const svg_icon_1 = require("../svg-icon");
|
|
9
10
|
const dash_1 = require("../../icons/dash");
|
|
10
11
|
const check_1 = require("../../icons/check");
|
|
11
|
-
exports.Checkbox = react_1.forwardRef(function Checkbox({ label, description, style, className, disabled, isMixed, ...props }, ref) {
|
|
12
|
-
return (jsx_runtime_1.jsxs(selection_control_1.SelectionControl, Object.assign({ className: react_helpers_1.classNames(className, 'dc-checkbox'), style: style, label: label, description: description, isDisabled: disabled }, { children: [jsx_runtime_1.jsx("input", Object.assign({}, props, { className: "dc-checkbox__input", ref: ref, type: "checkbox", disabled: disabled
|
|
12
|
+
exports.Checkbox = react_1.forwardRef(function Checkbox({ label, description, style, className, disabled, isMixed, onChange, onCheck, ...props }, ref) {
|
|
13
|
+
return (jsx_runtime_1.jsxs(selection_control_1.SelectionControl, Object.assign({ className: react_helpers_1.classNames(className, 'dc-checkbox'), style: style, label: label, description: description, isDisabled: disabled }, { children: [jsx_runtime_1.jsx("input", Object.assign({}, props, { className: "dc-checkbox__input", ref: ref, type: "checkbox", disabled: disabled, onChange: (event) => {
|
|
14
|
+
guards_1.isFunction(onChange) && onChange(event);
|
|
15
|
+
guards_1.isFunction(onCheck) && onCheck(event.target.checked);
|
|
16
|
+
} }), void 0), jsx_runtime_1.jsx("span", Object.assign({ className: "dc-checkbox__check", "aria-hidden": true }, { children: jsx_runtime_1.jsx(svg_icon_1.SvgIcon, { className: "dc-checkbox__check-icon", icon: isMixed ? dash_1.dash : check_1.check, size: "lg" }, void 0) }), void 0)] }), void 0));
|
|
13
17
|
});
|
|
14
18
|
//# sourceMappingURL=checkbox.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkbox.js","sourceRoot":"","sources":["../../src/components/checkbox/checkbox.tsx"],"names":[],"mappings":";;;;AAAA,iCAA0D;AAC1D,2DAAqD;AACrD,4DAG8B;AAC9B,0CAAsC;AACtC,2CAAwC;AACxC,6CAA0C;
|
|
1
|
+
{"version":3,"file":"checkbox.js","sourceRoot":"","sources":["../../src/components/checkbox/checkbox.tsx"],"names":[],"mappings":";;;;AAAA,iCAA0D;AAC1D,6CAA8C;AAC9C,2DAAqD;AACrD,4DAG8B;AAC9B,0CAAsC;AACtC,2CAAwC;AACxC,6CAA0C;AAmC7B,QAAA,QAAQ,GAAG,kBAAU,CAChC,SAAS,QAAQ,CACf,EACE,KAAK,EACL,WAAW,EACX,KAAK,EACL,SAAS,EACT,QAAQ,EACR,OAAO,EACP,QAAQ,EACR,OAAO,EACP,GAAG,KAAK,EACT,EACD,GAAG;IAEH,OAAO,CACL,mBAAC,oCAAgB,kBACf,SAAS,EAAE,0BAAU,CAAC,SAAS,EAAE,aAAa,CAAC,EAC/C,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,KAAK,EACZ,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,QAAQ,iBAEpB,6CACM,KAAK,IACT,SAAS,EAAC,oBAAoB,EAC9B,GAAG,EAAE,GAAG,EACR,IAAI,EAAC,UAAU,EACf,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,CAAC,KAAK,EAAE,EAAE;oBAClB,mBAAU,CAAC,QAAQ,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,CAAC;oBACxC,mBAAU,CAAC,OAAO,CAAC,IAAI,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;gBACvD,CAAC,YACD,EACF,0CAAM,SAAS,EAAC,oBAAoB,iBAAc,IAAI,gBACpD,kBAAC,kBAAO,IACN,SAAS,EAAC,yBAAyB,EACnC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC,WAAI,CAAC,CAAC,CAAC,aAAK,EAC5B,IAAI,EAAC,IAAI,WACT,YACG,aACU,CACpB,CAAC;AACJ,CAAC,CACF,CAAC"}
|
|
@@ -19,4 +19,4 @@ export interface DatetimeFieldProps extends ComponentPropsWithRef<'div'> {
|
|
|
19
19
|
value: DateComponents;
|
|
20
20
|
onChangeValue(value: DateComponents): void;
|
|
21
21
|
}
|
|
22
|
-
export declare const DatetimeField: import("react").ForwardRefExoticComponent<Pick<DatetimeFieldProps, "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "type" | "role" | "tabIndex" | "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" | "onChange" | "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" | "key" | "size" | "hidden" | "disabled" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "readOnly" | "invalid" | "
|
|
22
|
+
export declare const DatetimeField: import("react").ForwardRefExoticComponent<Pick<DatetimeFieldProps, "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "type" | "role" | "tabIndex" | "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" | "onChange" | "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" | "key" | "size" | "hidden" | "disabled" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "readOnly" | "invalid" | "onChangeValue" | "ids" | "ariaLabels" | "placeholders"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -9,4 +9,4 @@ export interface NumberFieldProps extends TextFieldProps {
|
|
|
9
9
|
value: string;
|
|
10
10
|
onChangeValue(value: string): void;
|
|
11
11
|
}
|
|
12
|
-
export declare function NumberField({ style, className, incrementButtonLabel, decrementButtonLabel, min, max, step, disabled, readOnly, fullWidth, size, value,
|
|
12
|
+
export declare function NumberField({ style, className, incrementButtonLabel, decrementButtonLabel, min, max, step, disabled, readOnly, fullWidth, size, value, onKeyDown, onChangeValue, ...props }: NumberFieldProps): JSX.Element;
|
|
@@ -7,7 +7,7 @@ const keyboard_helpers_1 = require("../../lib/keyboard-helpers");
|
|
|
7
7
|
const button_1 = require("../button");
|
|
8
8
|
const text_field_1 = require("../text-field");
|
|
9
9
|
const NUMBER_REGEXP = /^[-+]?([0-9]+(\.[0-9]*)?|\.[0-9]+)([eE][-+]?[0-9]+)?$/;
|
|
10
|
-
function NumberField({ style, className, incrementButtonLabel = '↑', decrementButtonLabel = '↓', min, max, step = 1, disabled, readOnly, fullWidth, size, value,
|
|
10
|
+
function NumberField({ style, className, incrementButtonLabel = '↑', decrementButtonLabel = '↓', min, max, step = 1, disabled, readOnly, fullWidth, size, value, onKeyDown, onChangeValue, ...props }) {
|
|
11
11
|
const numericValue = Number(value) || 0;
|
|
12
12
|
function inRange(value) {
|
|
13
13
|
if (min != null && max != null) {
|
|
@@ -37,17 +37,13 @@ function NumberField({ style, className, incrementButtonLabel = '↑', decrement
|
|
|
37
37
|
onChangeValue(formatFloat(diff, fractionDigits));
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
|
-
function
|
|
41
|
-
const value = event.target.value;
|
|
40
|
+
function handleChangeValue(value) {
|
|
42
41
|
if (value === '') {
|
|
43
42
|
onChangeValue(value);
|
|
44
43
|
}
|
|
45
44
|
else if (value.match(NUMBER_REGEXP) && inRange(Number(value))) {
|
|
46
45
|
onChangeValue(value);
|
|
47
46
|
}
|
|
48
|
-
if (typeof onChange === 'function') {
|
|
49
|
-
onChange(event);
|
|
50
|
-
}
|
|
51
47
|
}
|
|
52
48
|
function handleKeyDown(event) {
|
|
53
49
|
const code = event.code;
|
|
@@ -83,7 +79,7 @@ function NumberField({ style, className, incrementButtonLabel = '↑', decrement
|
|
|
83
79
|
if (!readOnly) {
|
|
84
80
|
decrement(step);
|
|
85
81
|
}
|
|
86
|
-
} }, { children: decrementButtonLabel }), void 0), jsx_runtime_1.jsx(text_field_1.TextField, Object.assign({}, props, { className: "dc-number-field__input", size: size, disabled: disabled, readOnly: readOnly, fullWidth: fullWidth, type: "text", value: value,
|
|
82
|
+
} }, { children: decrementButtonLabel }), void 0), jsx_runtime_1.jsx(text_field_1.TextField, Object.assign({}, props, { className: "dc-number-field__input", size: size, disabled: disabled, readOnly: readOnly, fullWidth: fullWidth, type: "text", value: value, onKeyDown: handleKeyDown, onChangeValue: handleChangeValue }), void 0), jsx_runtime_1.jsx(button_1.Button, Object.assign({ appearance: "secondary", size: size, type: "button", noPadding: true, disabled: disabled, onClick: () => {
|
|
87
83
|
if (!readOnly) {
|
|
88
84
|
increment(step);
|
|
89
85
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"number-field.js","sourceRoot":"","sources":["../../src/components/number-field/number-field.tsx"],"names":[],"mappings":";;;;AACA,2DAAqD;AACrD,iEAAqD;AACrD,sCAAmC;AACnC,8CAA0D;AAY1D,MAAM,aAAa,GAAG,uDAAuD,CAAC;AAE9E,SAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,SAAS,EACT,oBAAoB,GAAG,GAAG,EAC1B,oBAAoB,GAAG,GAAG,EAC1B,GAAG,EACH,GAAG,EACH,IAAI,GAAG,CAAC,EACR,QAAQ,EACR,QAAQ,EACR,SAAS,EACT,IAAI,EACJ,KAAK,EACL,
|
|
1
|
+
{"version":3,"file":"number-field.js","sourceRoot":"","sources":["../../src/components/number-field/number-field.tsx"],"names":[],"mappings":"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"}
|
|
@@ -2,5 +2,6 @@ import { ComponentPropsWithRef } from 'react';
|
|
|
2
2
|
import { SelectionControlBaseProps } from '../selection-control';
|
|
3
3
|
export declare type RadioButtonHtmlAttrs = Omit<ComponentPropsWithRef<'input'>, 'accept' | 'alt' | 'capture' | 'dirname' | 'formAction' | 'formEncType' | 'formMethod' | 'formNoValidate' | 'formTarget' | 'height' | 'max' | 'maxLength' | 'min' | 'minLength' | 'multiple' | 'pattern' | 'placeholder' | 'size' | 'src' | 'step' | 'type' | 'width'>;
|
|
4
4
|
export interface RadioButtonProps extends SelectionControlBaseProps, RadioButtonHtmlAttrs {
|
|
5
|
+
onCheck?(checked: boolean): void;
|
|
5
6
|
}
|
|
6
|
-
export declare const RadioButton: import("react").ForwardRefExoticComponent<Pick<RadioButtonProps, "form" | "label" | "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "name" | "role" | "tabIndex" | "crossOrigin" | "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" | "onChange" | "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" | "key" | "list" | "hidden" | "disabled" | "autoFocus" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "description" | "autoComplete" | "checked" | "enterKeyHint" | "readOnly" | "required"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
7
|
+
export declare const RadioButton: import("react").ForwardRefExoticComponent<Pick<RadioButtonProps, "form" | "label" | "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "name" | "role" | "tabIndex" | "crossOrigin" | "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" | "onChange" | "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" | "key" | "list" | "hidden" | "disabled" | "autoFocus" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "description" | "autoComplete" | "checked" | "enterKeyHint" | "readOnly" | "required" | "onCheck"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -3,9 +3,13 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.RadioButton = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const react_1 = require("react");
|
|
6
|
+
const guards_1 = require("../../lib/guards");
|
|
6
7
|
const react_helpers_1 = require("../../lib/react-helpers");
|
|
7
8
|
const selection_control_1 = require("../selection-control");
|
|
8
|
-
exports.RadioButton = react_1.forwardRef(function RadioButton({ label, description, style, className, disabled, ...props }, ref) {
|
|
9
|
-
return (jsx_runtime_1.jsxs(selection_control_1.SelectionControl, Object.assign({ className: react_helpers_1.classNames(className, 'dc-radio-btn'), style: style, label: label, description: description, isDisabled: disabled }, { children: [jsx_runtime_1.jsx("input", Object.assign({}, props, { className: "dc-radio-btn__input", ref: ref, type: "radio", disabled: disabled
|
|
9
|
+
exports.RadioButton = react_1.forwardRef(function RadioButton({ label, description, style, className, disabled, onChange, onCheck, ...props }, ref) {
|
|
10
|
+
return (jsx_runtime_1.jsxs(selection_control_1.SelectionControl, Object.assign({ className: react_helpers_1.classNames(className, 'dc-radio-btn'), style: style, label: label, description: description, isDisabled: disabled }, { children: [jsx_runtime_1.jsx("input", Object.assign({}, props, { className: "dc-radio-btn__input", ref: ref, type: "radio", disabled: disabled, onChange: (event) => {
|
|
11
|
+
guards_1.isFunction(onChange) && onChange(event);
|
|
12
|
+
guards_1.isFunction(onCheck) && onCheck(event.target.checked);
|
|
13
|
+
} }), void 0), jsx_runtime_1.jsx("span", { className: "dc-radio-btn__radio", "aria-hidden": true }, void 0)] }), void 0));
|
|
10
14
|
});
|
|
11
15
|
//# sourceMappingURL=radio-button.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"radio-button.js","sourceRoot":"","sources":["../../src/components/radio-button/radio-button.tsx"],"names":[],"mappings":";;;;AAAA,iCAA0D;AAC1D,2DAAqD;AACrD,4DAG8B;
|
|
1
|
+
{"version":3,"file":"radio-button.js","sourceRoot":"","sources":["../../src/components/radio-button/radio-button.tsx"],"names":[],"mappings":";;;;AAAA,iCAA0D;AAC1D,6CAA8C;AAC9C,2DAAqD;AACrD,4DAG8B;AAkCjB,QAAA,WAAW,GAAG,kBAAU,CACnC,SAAS,WAAW,CAClB,EACE,KAAK,EACL,WAAW,EACX,KAAK,EACL,SAAS,EACT,QAAQ,EACR,QAAQ,EACR,OAAO,EACP,GAAG,KAAK,EACT,EACD,GAAG;IAEH,OAAO,CACL,mBAAC,oCAAgB,kBACf,SAAS,EAAE,0BAAU,CAAC,SAAS,EAAE,cAAc,CAAC,EAChD,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,KAAK,EACZ,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,QAAQ,iBAEpB,6CACM,KAAK,IACT,SAAS,EAAC,qBAAqB,EAC/B,GAAG,EAAE,GAAG,EACR,IAAI,EAAC,OAAO,EACZ,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,CAAC,KAAK,EAAE,EAAE;oBAClB,mBAAU,CAAC,QAAQ,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,CAAC;oBACxC,mBAAU,CAAC,OAAO,CAAC,IAAI,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;gBACvD,CAAC,YACD,EACF,4BAAM,SAAS,EAAC,qBAAqB,iBAAc,IAAI,WAAI,aAC1C,CACpB,CAAC;AACJ,CAAC,CACF,CAAC"}
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
import { TextFieldProps } from '../text-field';
|
|
3
3
|
export interface SearchFieldProps extends TextFieldProps {
|
|
4
4
|
}
|
|
5
|
-
export declare const SearchField: import("react").ForwardRefExoticComponent<Pick<SearchFieldProps, "form" | "slot" | "style" | "title" | "pattern" | "className" | "color" | "id" | "lang" | "name" | "type" | "role" | "tabIndex" | "crossOrigin" | "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" | "onChange" | "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" | "key" | "size" | "list" | "hidden" | "multiple" | "disabled" | "autoFocus" | "value" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "fullWidth" | "autoComplete" | "enterKeyHint" | "maxLength" | "minLength" | "readOnly" | "required" | "invalid" | "leadingAddOn" | "trailingAddOn"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
5
|
+
export declare const SearchField: import("react").ForwardRefExoticComponent<Pick<SearchFieldProps, "form" | "slot" | "style" | "title" | "pattern" | "className" | "color" | "id" | "lang" | "name" | "type" | "role" | "tabIndex" | "crossOrigin" | "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" | "onChange" | "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" | "key" | "size" | "list" | "hidden" | "multiple" | "disabled" | "autoFocus" | "value" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "fullWidth" | "autoComplete" | "enterKeyHint" | "maxLength" | "minLength" | "readOnly" | "required" | "invalid" | "leadingAddOn" | "trailingAddOn" | "onChangeValue"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
import { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
2
|
declare type SegmentId = string | number;
|
|
3
3
|
export interface Segment<T extends SegmentId> {
|
|
4
|
-
|
|
4
|
+
value: T;
|
|
5
5
|
label: ReactNode;
|
|
6
6
|
icon?: ReactNode;
|
|
7
7
|
}
|
|
8
8
|
export interface SegmentedControlProps<T extends SegmentId> extends ComponentPropsWithoutRef<'ul'> {
|
|
9
9
|
size?: 'sm' | 'md' | 'lg';
|
|
10
|
-
name?: string;
|
|
11
10
|
items: Segment<T>[];
|
|
12
|
-
|
|
13
|
-
|
|
11
|
+
selectedValue: Segment<T>['value'];
|
|
12
|
+
onChangeSelectedValue(value: Segment<T>['value']): void;
|
|
14
13
|
}
|
|
15
|
-
export declare function SegmentedControl<T extends SegmentId>({ size,
|
|
14
|
+
export declare function SegmentedControl<T extends SegmentId>({ size, items, selectedValue, onChangeSelectedValue, className, onKeyDown, ...props }: SegmentedControlProps<T>): JSX.Element;
|
|
16
15
|
export {};
|
|
@@ -2,12 +2,16 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.SegmentedControl = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const util_1 = require("../../lib/util");
|
|
6
5
|
const guards_1 = require("../../lib/guards");
|
|
7
6
|
const react_helpers_1 = require("../../lib/react-helpers");
|
|
8
7
|
const keyboard_helpers_1 = require("../../lib/keyboard-helpers");
|
|
9
8
|
const button_1 = require("../button");
|
|
10
|
-
function SegmentedControl({ size = 'md',
|
|
9
|
+
function SegmentedControl({ size = 'md', items, selectedValue, onChangeSelectedValue, className, onKeyDown, ...props }) {
|
|
10
|
+
function selectSegment(segment) {
|
|
11
|
+
if (segment.value !== selectedValue) {
|
|
12
|
+
onChangeSelectedValue(segment.value);
|
|
13
|
+
}
|
|
14
|
+
}
|
|
11
15
|
function handleKeyDown(event) {
|
|
12
16
|
const code = event.code;
|
|
13
17
|
if (code === keyboard_helpers_1.KeyCode.home ||
|
|
@@ -43,14 +47,14 @@ function SegmentedControl({ size = 'md', name = util_1.uniqueId('segmented-contr
|
|
|
43
47
|
}
|
|
44
48
|
guards_1.isFunction(onKeyDown) && onKeyDown(event);
|
|
45
49
|
}
|
|
46
|
-
return (jsx_runtime_1.jsx("ul", Object.assign({}, props, { className: react_helpers_1.classNames(className, 'dc-segmented-control', `dc-segmented-control_size_${size}`), role: "radiogroup", onKeyDown: handleKeyDown }, { children: items.map((
|
|
47
|
-
const isSelected =
|
|
48
|
-
return (jsx_runtime_1.jsx(button_1.Button, Object.assign({ size: size, className: "dc-segmented-control__radio-btn", appearance: isSelected ? 'default' : 'minimal', leadingIcon:
|
|
50
|
+
return (jsx_runtime_1.jsx("ul", Object.assign({}, props, { className: react_helpers_1.classNames(className, 'dc-segmented-control', `dc-segmented-control_size_${size}`), role: "radiogroup", onKeyDown: handleKeyDown }, { children: items.map((segment) => {
|
|
51
|
+
const isSelected = segment.value === selectedValue;
|
|
52
|
+
return (jsx_runtime_1.jsx(button_1.Button, Object.assign({ size: size, className: "dc-segmented-control__radio-btn", appearance: isSelected ? 'default' : 'minimal', leadingIcon: segment.icon, renderAs: (props) => (jsx_runtime_1.jsx("li", Object.assign({}, props, { role: "radio", "aria-checked": isSelected, tabIndex: isSelected ? 0 : -1, onClick: () => selectSegment(segment), onKeyDown: (event) => {
|
|
49
53
|
if (keyboard_helpers_1.similarToClick(event)) {
|
|
50
54
|
event.preventDefault();
|
|
51
|
-
|
|
55
|
+
selectSegment(segment);
|
|
52
56
|
}
|
|
53
|
-
} }), void 0)) }, { children:
|
|
57
|
+
} }), void 0)) }, { children: segment.label }), segment.value));
|
|
54
58
|
}) }), void 0));
|
|
55
59
|
}
|
|
56
60
|
exports.SegmentedControl = SegmentedControl;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"segmented-control.js","sourceRoot":"","sources":["../../src/components/segmented-control/segmented-control.tsx"],"names":[],"mappings":";;;;AACA,
|
|
1
|
+
{"version":3,"file":"segmented-control.js","sourceRoot":"","sources":["../../src/components/segmented-control/segmented-control.tsx"],"names":[],"mappings":"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"}
|
|
@@ -3,5 +3,6 @@ export interface SelectProps extends Omit<ComponentPropsWithRef<'select'>, 'size
|
|
|
3
3
|
size?: 'sm' | 'md' | 'lg';
|
|
4
4
|
invalid?: boolean;
|
|
5
5
|
fullWidth?: boolean;
|
|
6
|
+
onChangeValue?(value: string): void;
|
|
6
7
|
}
|
|
7
|
-
export declare const Select: import("react").ForwardRefExoticComponent<Pick<SelectProps, "form" | "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "name" | "role" | "tabIndex" | "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" | "onChange" | "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" | "key" | "size" | "hidden" | "multiple" | "disabled" | "autoFocus" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "fullWidth" | "autoComplete" | "required" | "invalid"> & import("react").RefAttributes<HTMLSelectElement>>;
|
|
8
|
+
export declare const Select: import("react").ForwardRefExoticComponent<Pick<SelectProps, "form" | "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "name" | "role" | "tabIndex" | "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" | "onChange" | "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" | "key" | "size" | "hidden" | "multiple" | "disabled" | "autoFocus" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "fullWidth" | "autoComplete" | "required" | "invalid" | "onChangeValue"> & import("react").RefAttributes<HTMLSelectElement>>;
|
|
@@ -3,12 +3,16 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.Select = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const react_1 = require("react");
|
|
6
|
+
const guards_1 = require("../../lib/guards");
|
|
6
7
|
const react_helpers_1 = require("../../lib/react-helpers");
|
|
7
|
-
exports.Select = react_1.forwardRef(function Select({ size = 'md', invalid, fullWidth, className, ...props }, ref) {
|
|
8
|
+
exports.Select = react_1.forwardRef(function Select({ size = 'md', invalid, fullWidth, className, onChange, onChangeValue, ...props }, ref) {
|
|
8
9
|
return (jsx_runtime_1.jsx("select", Object.assign({}, props, { ref: ref, className: react_helpers_1.classNames(className, 'dc-field', 'dc-select', {
|
|
9
10
|
'dc-field_invalid': invalid,
|
|
10
11
|
'dc-field_full_width': fullWidth,
|
|
11
12
|
[`dc-field_size_${size}`]: size,
|
|
12
|
-
})
|
|
13
|
+
}), onChange: (event) => {
|
|
14
|
+
guards_1.isFunction(onChange) && onChange(event);
|
|
15
|
+
guards_1.isFunction(onChangeValue) && onChangeValue(event.target.value);
|
|
16
|
+
} }), void 0));
|
|
13
17
|
});
|
|
14
18
|
//# sourceMappingURL=select.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select.js","sourceRoot":"","sources":["../../src/components/select/select.tsx"],"names":[],"mappings":";;;;AAAA,iCAA0D;AAC1D,2DAAqD;
|
|
1
|
+
{"version":3,"file":"select.js","sourceRoot":"","sources":["../../src/components/select/select.tsx"],"names":[],"mappings":";;;;AAAA,iCAA0D;AAC1D,6CAA8C;AAC9C,2DAAqD;AAUxC,QAAA,MAAM,GAAG,kBAAU,CAC9B,SAAS,MAAM,CACb,EACE,IAAI,GAAG,IAAI,EACX,OAAO,EACP,SAAS,EACT,SAAS,EACT,QAAQ,EACR,aAAa,EACb,GAAG,KAAK,EACT,EACD,GAAG;IAEH,OAAO,CACL,8CACM,KAAK,IACT,GAAG,EAAE,GAAG,EACR,SAAS,EAAE,0BAAU,CAAC,SAAS,EAAE,UAAU,EAAE,WAAW,EAAE;YACxD,kBAAkB,EAAE,OAAO;YAC3B,qBAAqB,EAAE,SAAS;YAChC,CAAC,iBAAiB,IAAI,EAAE,CAAC,EAAE,IAAI;SAChC,CAAC,EACF,QAAQ,EAAE,CAAC,KAAK,EAAE,EAAE;YAClB,mBAAU,CAAC,QAAQ,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,CAAC;YACxC,mBAAU,CAAC,aAAa,CAAC,IAAI,aAAa,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;QACjE,CAAC,YACD,CACH,CAAC;AACJ,CAAC,CACF,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { CheckboxProps } from '../checkbox';
|
|
3
|
-
export declare const Switch: import("react").ForwardRefExoticComponent<Pick<CheckboxProps, "form" | "label" | "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "name" | "role" | "tabIndex" | "crossOrigin" | "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" | "onChange" | "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" | "key" | "list" | "hidden" | "disabled" | "autoFocus" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "description" | "autoComplete" | "checked" | "enterKeyHint" | "readOnly" | "required" | "isMixed"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
3
|
+
export declare const Switch: import("react").ForwardRefExoticComponent<Pick<CheckboxProps, "form" | "label" | "slot" | "style" | "title" | "className" | "color" | "id" | "lang" | "name" | "role" | "tabIndex" | "crossOrigin" | "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" | "onChange" | "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" | "key" | "list" | "hidden" | "disabled" | "autoFocus" | "value" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "description" | "autoComplete" | "checked" | "enterKeyHint" | "readOnly" | "required" | "isMixed" | "onCheck"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -3,9 +3,13 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.Switch = void 0;
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const react_1 = require("react");
|
|
6
|
+
const guards_1 = require("../../lib/guards");
|
|
6
7
|
const react_helpers_1 = require("../../lib/react-helpers");
|
|
7
8
|
const selection_control_1 = require("../selection-control");
|
|
8
|
-
exports.Switch = react_1.forwardRef(function Switch({ label, description, className, style, disabled, ...props }, ref) {
|
|
9
|
-
return (jsx_runtime_1.jsxs(selection_control_1.SelectionControl, Object.assign({ className: react_helpers_1.classNames(className, 'dc-switch'), style: style, label: label, description: description, isDisabled: disabled }, { children: [jsx_runtime_1.jsx("input", Object.assign({}, props, { className: "dc-switch__input", ref: ref, type: "checkbox", disabled: disabled
|
|
9
|
+
exports.Switch = react_1.forwardRef(function Switch({ label, description, className, style, disabled, onChange, onCheck, ...props }, ref) {
|
|
10
|
+
return (jsx_runtime_1.jsxs(selection_control_1.SelectionControl, Object.assign({ className: react_helpers_1.classNames(className, 'dc-switch'), style: style, label: label, description: description, isDisabled: disabled }, { children: [jsx_runtime_1.jsx("input", Object.assign({}, props, { className: "dc-switch__input", ref: ref, type: "checkbox", disabled: disabled, onChange: (event) => {
|
|
11
|
+
guards_1.isFunction(onChange) && onChange(event);
|
|
12
|
+
guards_1.isFunction(onCheck) && onCheck(event.target.checked);
|
|
13
|
+
} }), void 0), jsx_runtime_1.jsx("span", { className: "dc-switch__check", "aria-hidden": true }, void 0)] }), void 0));
|
|
10
14
|
});
|
|
11
15
|
//# sourceMappingURL=switch.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"switch.js","sourceRoot":"","sources":["../../src/components/switch/switch.tsx"],"names":[],"mappings":";;;;AACA,iCAAmC;AACnC,2DAAqD;AACrD,4DAAwD;AAE3C,QAAA,MAAM,GAAG,kBAAU,CAC9B,SAAS,MAAM,CACb,
|
|
1
|
+
{"version":3,"file":"switch.js","sourceRoot":"","sources":["../../src/components/switch/switch.tsx"],"names":[],"mappings":";;;;AACA,iCAAmC;AACnC,6CAA8C;AAC9C,2DAAqD;AACrD,4DAAwD;AAE3C,QAAA,MAAM,GAAG,kBAAU,CAC9B,SAAS,MAAM,CACb,EACE,KAAK,EACL,WAAW,EACX,SAAS,EACT,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,OAAO,EACP,GAAG,KAAK,EACT,EACD,GAAG;IAEH,OAAO,CACL,mBAAC,oCAAgB,kBACf,SAAS,EAAE,0BAAU,CAAC,SAAS,EAAE,WAAW,CAAC,EAC7C,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,KAAK,EACZ,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,QAAQ,iBAEpB,6CACM,KAAK,IACT,SAAS,EAAC,kBAAkB,EAC5B,GAAG,EAAE,GAAG,EACR,IAAI,EAAC,UAAU,EACf,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,CAAC,KAAK,EAAE,EAAE;oBAClB,mBAAU,CAAC,QAAQ,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,CAAC;oBACxC,mBAAU,CAAC,OAAO,CAAC,IAAI,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;gBACvD,CAAC,YACD,EACF,4BAAM,SAAS,EAAC,kBAAkB,iBAAc,IAAI,WAAI,aACvC,CACpB,CAAC;AACJ,CAAC,CACF,CAAC"}
|
|
@@ -11,4 +11,10 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
11
11
|
};
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
13
|
__exportStar(require("./table"), exports);
|
|
14
|
+
__exportStar(require("./table-container"), exports);
|
|
15
|
+
__exportStar(require("./table-head"), exports);
|
|
16
|
+
__exportStar(require("./table-body"), exports);
|
|
17
|
+
__exportStar(require("./table-row"), exports);
|
|
18
|
+
__exportStar(require("./table-header-cell"), exports);
|
|
19
|
+
__exportStar(require("./table-cell"), exports);
|
|
14
20
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/components/table/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,0CAAwB"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/components/table/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,0CAAwB;AACxB,oDAAkC;AAClC,+CAA6B;AAC7B,+CAA6B;AAC7B,8CAA4B;AAC5B,sDAAoC;AACpC,+CAA6B"}
|
|
@@ -3,7 +3,7 @@ import { TableSortButtonProps } from './table-sort-button';
|
|
|
3
3
|
export interface TableHeaderCellProps extends ComponentPropsWithoutRef<'th'> {
|
|
4
4
|
isSortable?: boolean;
|
|
5
5
|
order?: TableSortButtonProps['order'];
|
|
6
|
-
|
|
6
|
+
onChangeOrder?: TableSortButtonProps['onSort'];
|
|
7
7
|
renderSortButtonLabel?: TableSortButtonProps['renderLabel'];
|
|
8
8
|
}
|
|
9
|
-
export declare function TableHeaderCell({ isSortable, order, renderSortButtonLabel,
|
|
9
|
+
export declare function TableHeaderCell({ isSortable, order, renderSortButtonLabel, onChangeOrder, className, role, align, children, ...props }: TableHeaderCellProps): JSX.Element;
|
|
@@ -9,8 +9,8 @@ const ariaSortValues = {
|
|
|
9
9
|
asc: 'ascending',
|
|
10
10
|
desc: 'descending',
|
|
11
11
|
};
|
|
12
|
-
function TableHeaderCell({ isSortable, order = 'none', renderSortButtonLabel,
|
|
13
|
-
return (jsx_runtime_1.jsx("th", Object.assign({ "aria-sort": isSortable ? ariaSortValues[order] : undefined }, props, { className: react_helpers_1.classNames(className, 'dc-table-cell', 'dc-table-cell_header'), role: role, align: align }, { children: jsx_runtime_1.jsxs("div", Object.assign({ className: "dc-table-cell__body" }, { children: [isSortable && (jsx_runtime_1.jsx(table_sort_button_1.TableSortButton, { className: "dc-table-cell__sort-btn", column: children, order: order, onSort:
|
|
12
|
+
function TableHeaderCell({ isSortable, order = 'none', renderSortButtonLabel, onChangeOrder, className, role = 'columnheader', align = 'left', children, ...props }) {
|
|
13
|
+
return (jsx_runtime_1.jsx("th", Object.assign({ "aria-sort": isSortable ? ariaSortValues[order] : undefined }, props, { className: react_helpers_1.classNames(className, 'dc-table-cell', 'dc-table-cell_header'), role: role, align: align }, { children: jsx_runtime_1.jsxs("div", Object.assign({ className: "dc-table-cell__body" }, { children: [isSortable && (jsx_runtime_1.jsx(table_sort_button_1.TableSortButton, { className: "dc-table-cell__sort-btn", column: children, order: order, onSort: onChangeOrder, renderLabel: renderSortButtonLabel }, void 0)), children] }), void 0) }), void 0));
|
|
14
14
|
}
|
|
15
15
|
exports.TableHeaderCell = TableHeaderCell;
|
|
16
16
|
//# sourceMappingURL=table-header-cell.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"table-header-cell.js","sourceRoot":"","sources":["../../src/components/table/table-header-cell.tsx"],"names":[],"mappings":";;;;AACA,2DAAqD;AACrD,2DAI6B;AAS7B,MAAM,cAAc,GAAqD;IACvE,IAAI,EAAE,MAAM;IACZ,GAAG,EAAE,WAAW;IAChB,IAAI,EAAE,YAAY;CACnB,CAAC;AAEF,SAAgB,eAAe,CAAC,EAC9B,UAAU,EACV,KAAK,GAAG,MAAM,EACd,qBAAqB,EACrB,
|
|
1
|
+
{"version":3,"file":"table-header-cell.js","sourceRoot":"","sources":["../../src/components/table/table-header-cell.tsx"],"names":[],"mappings":";;;;AACA,2DAAqD;AACrD,2DAI6B;AAS7B,MAAM,cAAc,GAAqD;IACvE,IAAI,EAAE,MAAM;IACZ,GAAG,EAAE,WAAW;IAChB,IAAI,EAAE,YAAY;CACnB,CAAC;AAEF,SAAgB,eAAe,CAAC,EAC9B,UAAU,EACV,KAAK,GAAG,MAAM,EACd,qBAAqB,EACrB,aAAa,EACb,SAAS,EACT,IAAI,GAAG,cAAc,EACrB,KAAK,GAAG,MAAM,EACd,QAAQ,EACR,GAAG,KAAK,EACa;IACrB,OAAO,CACL,qDACa,UAAU,CAAC,CAAC,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,SAAS,IACrD,KAAK,IACT,SAAS,EAAE,0BAAU,CAAC,SAAS,EAAE,eAAe,EAAE,sBAAsB,CAAC,EACzE,IAAI,EAAE,IAAI,EACV,KAAK,EAAE,KAAK,gBAEZ,0CAAK,SAAS,EAAC,qBAAqB,iBACjC,UAAU,IAAI,CACb,kBAAC,mCAAe,IACd,SAAS,EAAC,yBAAyB,EACnC,MAAM,EAAE,QAAQ,EAChB,KAAK,EAAE,KAAK,EACZ,MAAM,EAAE,aAAa,EACrB,WAAW,EAAE,qBAAqB,WAClC,CACH,EACA,QAAQ,aACL,YACH,CACN,CAAC;AACJ,CAAC;AAjCD,0CAiCC"}
|