@workday/canvas-kit-react 12.0.0 → 12.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commonjs/avatar/lib/Avatar.js +21 -21
- package/dist/commonjs/badge/lib/CountBadge.js +3 -3
- package/dist/commonjs/button/lib/BaseButton.js +21 -21
- package/dist/commonjs/button/lib/DeleteButton.js +1 -1
- package/dist/commonjs/button/lib/PrimaryButton.js +2 -2
- package/dist/commonjs/button/lib/SecondaryButton.js +2 -2
- package/dist/commonjs/button/lib/TertiaryButton.js +18 -18
- package/dist/commonjs/card/lib/Card.js +1 -1
- package/dist/commonjs/card/lib/CardBody.js +1 -1
- package/dist/commonjs/card/lib/CardHeading.js +1 -1
- package/dist/commonjs/checkbox/lib/CheckBackground.js +3 -3
- package/dist/commonjs/checkbox/lib/CheckboxCheck.js +5 -5
- package/dist/commonjs/checkbox/lib/CheckboxContainer.js +1 -1
- package/dist/commonjs/checkbox/lib/CheckboxInput.js +5 -5
- package/dist/commonjs/checkbox/lib/CheckboxRipple.js +1 -1
- package/dist/commonjs/collection/lib/ListBox.js +3 -3
- package/dist/commonjs/combobox/lib/ComboboxMenuList.js +1 -1
- package/dist/commonjs/common/lib/AccessibleHide.js +1 -1
- package/dist/commonjs/common/lib/CanvasProvider.js +1 -1
- package/dist/commonjs/form-field/lib/FormFieldContainer.js +1 -1
- package/dist/commonjs/form-field/lib/FormFieldField.js +1 -1
- package/dist/commonjs/form-field/lib/FormFieldGroupLabel.js +5 -5
- package/dist/commonjs/form-field/lib/FormFieldGroupList.js +3 -3
- package/dist/commonjs/form-field/lib/FormFieldHint.js +3 -3
- package/dist/commonjs/form-field/lib/FormFieldLabel.js +6 -6
- package/dist/commonjs/form-field/lib/formFieldStencil.js +8 -8
- package/dist/commonjs/icon/lib/AccentIcon.js +2 -2
- package/dist/commonjs/icon/lib/AppletIcon.js +1 -1
- package/dist/commonjs/icon/lib/Graphic.js +2 -2
- package/dist/commonjs/icon/lib/Svg.js +2 -2
- package/dist/commonjs/icon/lib/SystemIcon.js +1 -1
- package/dist/commonjs/icon/lib/SystemIconCircle.js +1 -1
- package/dist/commonjs/loading-dots/lib/LoadingDots.js +3 -3
- package/dist/commonjs/menu/lib/MenuCard.js +1 -1
- package/dist/commonjs/menu/lib/MenuItem.js +1 -1
- package/dist/commonjs/menu/lib/MenuList.js +3 -3
- package/dist/commonjs/menu/lib/MenuOption.js +1 -1
- package/dist/commonjs/modal/lib/ModalBody.js +1 -1
- package/dist/commonjs/modal/lib/ModalCard.js +1 -1
- package/dist/commonjs/modal/lib/ModalHeading.js +1 -1
- package/dist/commonjs/modal/lib/ModalOverflowOverlay.js +1 -1
- package/dist/commonjs/modal/lib/ModalOverlay.js +2 -2
- package/dist/commonjs/popup/lib/PopupBody.js +1 -1
- package/dist/commonjs/popup/lib/PopupCard.js +2 -2
- package/dist/commonjs/popup/lib/PopupCloseIcon.js +1 -1
- package/dist/commonjs/popup/lib/PopupHeading.js +1 -1
- package/dist/commonjs/select/lib/Select.d.ts +3 -405
- package/dist/commonjs/select/lib/Select.d.ts.map +1 -1
- package/dist/commonjs/select/lib/Select.js +7 -48
- package/dist/commonjs/select/lib/SelectCard.d.ts +159 -0
- package/dist/commonjs/select/lib/SelectCard.d.ts.map +1 -0
- package/dist/commonjs/select/lib/SelectCard.js +20 -0
- package/dist/commonjs/select/lib/SelectInput.d.ts +95 -0
- package/dist/commonjs/select/lib/SelectInput.d.ts.map +1 -0
- package/dist/commonjs/select/lib/SelectInput.js +37 -0
- package/dist/commonjs/select/lib/SelectItem.d.ts +155 -0
- package/dist/commonjs/select/lib/SelectItem.d.ts.map +1 -0
- package/dist/commonjs/select/lib/SelectItem.js +18 -0
- package/dist/commonjs/switch/lib/Switch.js +7 -7
- package/dist/commonjs/table/lib/Table.js +1 -1
- package/dist/commonjs/table/lib/TableBody.js +1 -1
- package/dist/commonjs/table/lib/TableCaption.js +1 -1
- package/dist/commonjs/table/lib/TableCell.js +1 -1
- package/dist/commonjs/table/lib/TableFooter.js +1 -1
- package/dist/commonjs/table/lib/TableHead.js +1 -1
- package/dist/commonjs/table/lib/TableHeader.js +1 -1
- package/dist/commonjs/table/lib/TableRow.js +1 -1
- package/dist/commonjs/text/lib/LabelText.js +6 -6
- package/dist/commonjs/text/lib/Text.js +16 -16
- package/dist/commonjs/text/lib/TypeLevelComponents.js +4 -4
- package/dist/commonjs/text-area/lib/TextArea.js +5 -5
- package/dist/commonjs/text-input/lib/InputGroup.js +6 -6
- package/dist/commonjs/text-input/lib/TextInput.js +5 -5
- package/dist/commonjs/toast/lib/Toast.js +1 -1
- package/dist/commonjs/toast/lib/ToastBody.js +1 -1
- package/dist/commonjs/toast/lib/ToastCloseIcon.js +1 -1
- package/dist/commonjs/toast/lib/ToastIcon.js +1 -1
- package/dist/commonjs/toast/lib/ToastMessage.js +1 -1
- package/dist/es6/avatar/lib/Avatar.js +21 -21
- package/dist/es6/badge/lib/CountBadge.js +3 -3
- package/dist/es6/button/lib/BaseButton.js +21 -21
- package/dist/es6/button/lib/DeleteButton.js +1 -1
- package/dist/es6/button/lib/PrimaryButton.js +2 -2
- package/dist/es6/button/lib/SecondaryButton.js +2 -2
- package/dist/es6/button/lib/TertiaryButton.js +18 -18
- package/dist/es6/card/lib/Card.js +1 -1
- package/dist/es6/card/lib/CardBody.js +1 -1
- package/dist/es6/card/lib/CardHeading.js +1 -1
- package/dist/es6/checkbox/lib/CheckBackground.js +3 -3
- package/dist/es6/checkbox/lib/CheckboxCheck.js +5 -5
- package/dist/es6/checkbox/lib/CheckboxContainer.js +1 -1
- package/dist/es6/checkbox/lib/CheckboxInput.js +5 -5
- package/dist/es6/checkbox/lib/CheckboxRipple.js +1 -1
- package/dist/es6/collection/lib/ListBox.js +3 -3
- package/dist/es6/combobox/lib/ComboboxMenuList.js +1 -1
- package/dist/es6/common/lib/AccessibleHide.js +1 -1
- package/dist/es6/common/lib/CanvasProvider.js +1 -1
- package/dist/es6/form-field/lib/FormFieldContainer.js +1 -1
- package/dist/es6/form-field/lib/FormFieldField.js +1 -1
- package/dist/es6/form-field/lib/FormFieldGroupLabel.js +5 -5
- package/dist/es6/form-field/lib/FormFieldGroupList.js +3 -3
- package/dist/es6/form-field/lib/FormFieldHint.js +3 -3
- package/dist/es6/form-field/lib/FormFieldLabel.js +6 -6
- package/dist/es6/form-field/lib/formFieldStencil.js +8 -8
- package/dist/es6/icon/lib/AccentIcon.js +2 -2
- package/dist/es6/icon/lib/AppletIcon.js +1 -1
- package/dist/es6/icon/lib/Graphic.js +2 -2
- package/dist/es6/icon/lib/Svg.js +2 -2
- package/dist/es6/icon/lib/SystemIcon.js +1 -1
- package/dist/es6/icon/lib/SystemIconCircle.js +1 -1
- package/dist/es6/loading-dots/lib/LoadingDots.js +3 -3
- package/dist/es6/menu/lib/MenuCard.js +1 -1
- package/dist/es6/menu/lib/MenuItem.js +1 -1
- package/dist/es6/menu/lib/MenuList.js +3 -3
- package/dist/es6/menu/lib/MenuOption.js +1 -1
- package/dist/es6/modal/lib/ModalBody.js +1 -1
- package/dist/es6/modal/lib/ModalCard.js +1 -1
- package/dist/es6/modal/lib/ModalHeading.js +1 -1
- package/dist/es6/modal/lib/ModalOverflowOverlay.js +1 -1
- package/dist/es6/modal/lib/ModalOverlay.js +2 -2
- package/dist/es6/popup/lib/PopupBody.js +1 -1
- package/dist/es6/popup/lib/PopupCard.js +2 -2
- package/dist/es6/popup/lib/PopupCloseIcon.js +1 -1
- package/dist/es6/popup/lib/PopupHeading.js +1 -1
- package/dist/es6/select/lib/Select.d.ts +3 -405
- package/dist/es6/select/lib/Select.d.ts.map +1 -1
- package/dist/es6/select/lib/Select.js +4 -45
- package/dist/es6/select/lib/SelectCard.d.ts +159 -0
- package/dist/es6/select/lib/SelectCard.d.ts.map +1 -0
- package/dist/es6/select/lib/SelectCard.js +14 -0
- package/dist/es6/select/lib/SelectInput.d.ts +95 -0
- package/dist/es6/select/lib/SelectInput.d.ts.map +1 -0
- package/dist/es6/select/lib/SelectInput.js +31 -0
- package/dist/es6/select/lib/SelectItem.d.ts +155 -0
- package/dist/es6/select/lib/SelectItem.d.ts.map +1 -0
- package/dist/es6/select/lib/SelectItem.js +12 -0
- package/dist/es6/switch/lib/Switch.js +7 -7
- package/dist/es6/table/lib/Table.js +1 -1
- package/dist/es6/table/lib/TableBody.js +1 -1
- package/dist/es6/table/lib/TableCaption.js +1 -1
- package/dist/es6/table/lib/TableCell.js +1 -1
- package/dist/es6/table/lib/TableFooter.js +1 -1
- package/dist/es6/table/lib/TableHead.js +1 -1
- package/dist/es6/table/lib/TableHeader.js +1 -1
- package/dist/es6/table/lib/TableRow.js +1 -1
- package/dist/es6/text/lib/LabelText.js +6 -6
- package/dist/es6/text/lib/Text.js +16 -16
- package/dist/es6/text/lib/TypeLevelComponents.js +4 -4
- package/dist/es6/text-area/lib/TextArea.js +5 -5
- package/dist/es6/text-input/lib/InputGroup.js +6 -6
- package/dist/es6/text-input/lib/TextInput.js +5 -5
- package/dist/es6/toast/lib/Toast.js +1 -1
- package/dist/es6/toast/lib/ToastBody.js +1 -1
- package/dist/es6/toast/lib/ToastCloseIcon.js +1 -1
- package/dist/es6/toast/lib/ToastIcon.js +1 -1
- package/dist/es6/toast/lib/ToastMessage.js +1 -1
- package/package.json +4 -4
- package/select/lib/Select.tsx +5 -115
- package/select/lib/SelectCard.tsx +23 -0
- package/select/lib/SelectInput.tsx +89 -0
- package/select/lib/SelectItem.tsx +18 -0
|
@@ -12,11 +12,11 @@ export const useMenuList = composeHooks(createElemPropsHook(useMenuModel)(model
|
|
|
12
12
|
};
|
|
13
13
|
}), useReturnFocus, useFocusRedirect);
|
|
14
14
|
export const menuListStencil = createStencil({
|
|
15
|
-
base: { name: "
|
|
15
|
+
base: { name: "fmb82o", styles: "box-sizing:border-box;background:var(--cnvs-base-palette-french-vanilla-100);border-radius:var(--cnvs-sys-shape-zero);padding:var(--cnvs-sys-space-zero);gap:var(--cnvs-sys-space-zero);" },
|
|
16
16
|
modifiers: {
|
|
17
17
|
orientation: {
|
|
18
|
-
vertical: { name: "
|
|
19
|
-
horizontal: { name: "
|
|
18
|
+
vertical: { name: "fmb82p", styles: "flex-direction:column;" },
|
|
19
|
+
horizontal: { name: "fmb82q", styles: "flex-direction:row;" }
|
|
20
20
|
}
|
|
21
21
|
}
|
|
22
22
|
}, "menu-list-b9b420");
|
|
@@ -11,7 +11,7 @@ import { useMenuModel } from './useMenuModel';
|
|
|
11
11
|
import { menuItemStencil } from './MenuItem';
|
|
12
12
|
export const menuOptionStencil = createStencil({
|
|
13
13
|
extends: menuItemStencil,
|
|
14
|
-
base: { name: "
|
|
14
|
+
base: { name: "fmb82r", styles: "box-sizing:border-box;&:where([aria-selected=true]){& :where([data-part=\"menu-item-selected\"]){opacity:var(--cnvs-sys-opacity-full);}&:where(.focus, :focus){--color-system-icon-583fae:var(--cnvs-brand-primary-accent);outline:none;background-color:var(--cnvs-brand-primary-base);color:var(--color-system-icon-583fae);}}" }
|
|
15
15
|
}, "menu-option-af4ba2");
|
|
16
16
|
const MenuOptionIcon = (elemProps) => {
|
|
17
17
|
return React.createElement(SystemIcon, { "data-part": "menu-item-icon", ...elemProps });
|
|
@@ -6,7 +6,7 @@ import { createStencil } from '@workday/canvas-kit-styling';
|
|
|
6
6
|
import { system } from '@workday/canvas-tokens-web';
|
|
7
7
|
import { mergeStyles } from '@workday/canvas-kit-react/layout';
|
|
8
8
|
export const modalBodyStencil = createStencil({
|
|
9
|
-
base: { name: "
|
|
9
|
+
base: { name: "fmb856", styles: "box-sizing:border-box;@media screen and (max-width: 768px){margin-block-end:var(--cnvs-sys-space-zero);padding:var(--cnvs-sys-space-x1) var(--cnvs-sys-space-x2) var(--cnvs-sys-space-x2);}" }
|
|
10
10
|
}, "modal-body-d624fe");
|
|
11
11
|
export const ModalBody = createSubcomponent('div')({
|
|
12
12
|
displayName: 'Modal.Body',
|
|
@@ -6,7 +6,7 @@ import { calc, createStencil } from '@workday/canvas-kit-styling';
|
|
|
6
6
|
import { system } from '@workday/canvas-tokens-web';
|
|
7
7
|
import { mergeStyles } from '@workday/canvas-kit-react/layout';
|
|
8
8
|
export const modalCardStencil = createStencil({
|
|
9
|
-
base: { name: "
|
|
9
|
+
base: { name: "fmb853", styles: "box-sizing:border-box;margin:var(--cnvs-sys-space-x10);width:calc(calc(var(--cnvs-sys-space-x20) * 5) + var(--cnvs-sys-space-x10));border-width:var(--cnvs-sys-space-zero);box-shadow:var(--cnvs-sys-depth-6);@media screen and (max-width: 768px){margin:var(--cnvs-sys-space-x4);padding:var(--cnvs-sys-space-x4);border-radius:var(--cnvs-sys-space-x6);}" }
|
|
10
10
|
}, "modal-card-9eebe8");
|
|
11
11
|
export const ModalCard = createSubcomponent('div')({
|
|
12
12
|
displayName: 'Modal.Card',
|
|
@@ -6,7 +6,7 @@ import { createStencil } from '@workday/canvas-kit-styling';
|
|
|
6
6
|
import { system } from '@workday/canvas-tokens-web';
|
|
7
7
|
import { mergeStyles } from '@workday/canvas-kit-react/layout';
|
|
8
8
|
export const modalHeadingStencil = createStencil({
|
|
9
|
-
base: { name: "
|
|
9
|
+
base: { name: "fmb854", styles: "box-sizing:border-box;@media screen and (max-width: 768px){margin-block-end:var(--cnvs-sys-space-zero);padding:var(--cnvs-sys-space-x2) var(--cnvs-sys-space-x2) var(--cnvs-sys-space-x1);}" }
|
|
10
10
|
}, "modal-heading-52f13d");
|
|
11
11
|
export const ModalHeading = createSubcomponent('h2')({
|
|
12
12
|
displayName: 'Modal.Heading',
|
|
@@ -5,7 +5,7 @@ import { useModalModel } from './hooks';
|
|
|
5
5
|
import { createStencil } from '@workday/canvas-kit-styling';
|
|
6
6
|
import { mergeStyles } from '@workday/canvas-kit-react/layout';
|
|
7
7
|
export const modalOverflowOverlayStencil = createStencil({
|
|
8
|
-
base: { name: "
|
|
8
|
+
base: { name: "fmb855", styles: "box-sizing:border-box;& > div{max-height:inherit;}overflow:hidden auto;" }
|
|
9
9
|
}, "modal-overflow-overlay-2ac342");
|
|
10
10
|
export const ModalOverflowOverlay = createSubcomponent('div')({
|
|
11
11
|
displayName: 'Modal.OverflowOverlay',
|
|
@@ -6,12 +6,12 @@ import { Box, mergeStyles } from '@workday/canvas-kit-react/layout';
|
|
|
6
6
|
import { useModalModel } from './hooks';
|
|
7
7
|
import { createStencil, cssVar, keyframes } from '@workday/canvas-kit-styling';
|
|
8
8
|
import { system } from '@workday/canvas-tokens-web';
|
|
9
|
-
const fadeIn = keyframes({ name: "
|
|
9
|
+
const fadeIn = keyframes({ name: "fmb851", styles: "0%{background:none;}100%{background:var(--cnvs-sys-color-bg-overlay);}" });
|
|
10
10
|
export const modalOverlayContainerStencil = createStencil({
|
|
11
11
|
vars: {
|
|
12
12
|
containerCenter: '',
|
|
13
13
|
},
|
|
14
|
-
base: { name: "
|
|
14
|
+
base: { name: "fmb852", styles: "box-sizing:border-box;position:fixed;top:var(--cnvs-sys-space-zero);left:var(--cnvs-sys-space-zero);width:100vw;height:100vh;background:var(--cnvs-sys-color-bg-overlay);animation-duration:0.3s;animation-name:animation-fmb851;.wd-no-animation &{animation:none;}& > div{max-height:100%;display:flex;position:absolute;left:var(--cnvs-sys-space-zero);top:var(--cnvs-sys-space-zero);justify-content:center;align-items:center;height:100%;width:var(--containerCenter-modal-overlay-container-8b6518);}@media screen and (max-width: 768px){height:100%;& > div{align-items:end;}}" }
|
|
15
15
|
}, "modal-overlay-container-8b6518");
|
|
16
16
|
export const useModalOverlay = createElemPropsHook(usePopupModel)(({ state }, ref) => {
|
|
17
17
|
const elementRef = useForkRef(ref, state.stackRef);
|
|
@@ -6,7 +6,7 @@ import { createStencil } from '@workday/canvas-kit-styling';
|
|
|
6
6
|
import { mergeStyles } from '../../layout';
|
|
7
7
|
import { system } from '@workday/canvas-tokens-web';
|
|
8
8
|
export const popupBodyStencil = createStencil({
|
|
9
|
-
base: { name: "
|
|
9
|
+
base: { name: "fmb82i", styles: "box-sizing:border-box;overflow-y:auto;padding:var(--cnvs-sys-space-x2);" }
|
|
10
10
|
}, "popup-body-1fee86");
|
|
11
11
|
export const PopupBody = createSubcomponent('div')({
|
|
12
12
|
displayName: 'Popup.Body',
|
|
@@ -11,7 +11,7 @@ const translateVars = createVars({ id: "696a04", args: ["positionX", "positionY"
|
|
|
11
11
|
/**
|
|
12
12
|
* Keyframe for the dots loading animation.
|
|
13
13
|
*/
|
|
14
|
-
const fadeIn = keyframes({ name: "
|
|
14
|
+
const fadeIn = keyframes({ name: "fmb8x", styles: "0%{opacity:1;transform:translate(var(--positionX-696a04), var(--positionY-696a04));}100%{opacity:1;transform:translate(0);}" });
|
|
15
15
|
function getSpace(value) {
|
|
16
16
|
if (value && value in space) {
|
|
17
17
|
return space[value];
|
|
@@ -45,7 +45,7 @@ export const popupCardStencil = createStencil({
|
|
|
45
45
|
transformOriginHorizontal: '',
|
|
46
46
|
transformOriginVertical: '',
|
|
47
47
|
},
|
|
48
|
-
base: { name: "
|
|
48
|
+
base: { name: "fmb8y", styles: "box-sizing:border-box;font-family:var(--cnvs-base-font-family-50);font-weight:var(--cnvs-base-font-weight-400);line-height:var(--cnvs-base-line-height-100);font-size:var(--cnvs-base-font-size-75);letter-spacing:var(--cnvs-base-letter-spacing-150);display:flex;position:relative;max-width:calc(100vw - var(--cnvs-sys-space-x8));flex-direction:column;box-shadow:var(--cnvs-sys-depth-5);min-height:var(--cnvs-sys-space-zero);padding:var(--cnvs-sys-space-x6);max-height:var(--maxHeight-popup-card-36628b);overflow-y:auto;animation-name:animation-fmb8x;animation-duration:150ms;animation-timing-function:ease-out;transform-origin:var(--transformOriginVertical-popup-card-36628b) var(--transformOriginHorizontal-popup-card-36628b);.wd-no-animation &{animation:none;}@media screen and (max-width: 768px){transform-origin:bottom center;}" }
|
|
49
49
|
}, "popup-card-36628b");
|
|
50
50
|
export const PopupCard = createSubcomponent('div')({
|
|
51
51
|
displayName: 'Popup.Card',
|
|
@@ -7,7 +7,7 @@ import { createStencil } from '@workday/canvas-kit-styling';
|
|
|
7
7
|
import { system } from '@workday/canvas-tokens-web';
|
|
8
8
|
import { mergeStyles } from '../../layout';
|
|
9
9
|
export const popupCloseIconStencil = createStencil({
|
|
10
|
-
base: { name: "
|
|
10
|
+
base: { name: "fmb82h", styles: "box-sizing:border-box;position:absolute;inset-inline-end:var(--cnvs-sys-space-x1);top:var(--cnvs-sys-space-x1);" }
|
|
11
11
|
}, "popup-close-icon-111273");
|
|
12
12
|
export const PopupCloseIcon = createSubcomponent('button')({
|
|
13
13
|
displayName: 'Popup.CloseIcon',
|
|
@@ -6,7 +6,7 @@ import { createStencil } from '@workday/canvas-kit-styling';
|
|
|
6
6
|
import { system } from '@workday/canvas-tokens-web';
|
|
7
7
|
import { mergeStyles } from '../../layout';
|
|
8
8
|
export const popupHeadingStencil = createStencil({
|
|
9
|
-
base: { name: "
|
|
9
|
+
base: { name: "fmb82g", styles: "box-sizing:border-box;margin-block-end:var(--cnvs-sys-space-x2);padding:var(--cnvs-sys-space-x2);" }
|
|
10
10
|
}, "popup-heading-3e49bb");
|
|
11
11
|
export const PopupHeading = createSubcomponent('h2')({
|
|
12
12
|
displayName: 'Popup.Heading',
|
|
@@ -1,408 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CanvasSystemIcon } from '@workday/design-assets-types';
|
|
3
2
|
import { Combobox } from '@workday/canvas-kit-react/combobox';
|
|
4
|
-
import { CSProps } from '@workday/canvas-kit-styling';
|
|
5
|
-
import { TextInput } from '@workday/canvas-kit-react/text-input';
|
|
6
3
|
import { ExtractProps } from '@workday/canvas-kit-react/common';
|
|
7
|
-
export interface SelectInputProps extends ExtractProps<typeof TextInput>, CSProps {
|
|
8
|
-
/**
|
|
9
|
-
* The Icon to render at the start of the `input`. Use this prop if your options
|
|
10
|
-
* include icons that you would like to render in the `input` when selected.
|
|
11
|
-
* ** Note:An option must be selected in order to render and icon.**
|
|
12
|
-
*/
|
|
13
|
-
inputStartIcon?: CanvasSystemIcon;
|
|
14
|
-
}
|
|
15
|
-
export declare const SelectInput: import("@workday/canvas-kit-react/common").ElementComponentM<import("@workday/canvas-kit-react/common").ElementComponent<"input", import("@workday/canvas-kit-react/text-input").TextInputProps> & {
|
|
16
|
-
ErrorType: typeof import("@workday/canvas-kit-react/common").ErrorType;
|
|
17
|
-
}, SelectInputProps, {
|
|
18
|
-
state: {
|
|
19
|
-
stackRef: React.RefObject<HTMLDivElement>;
|
|
20
|
-
targetRef: React.RefObject<HTMLButtonElement>;
|
|
21
|
-
initialFocusRef: React.RefObject<any> | undefined;
|
|
22
|
-
returnFocusRef: React.RefObject<any> | undefined;
|
|
23
|
-
placement: import("@popperjs/core").Placement;
|
|
24
|
-
id: string;
|
|
25
|
-
visibility: "hidden" | "visible";
|
|
26
|
-
selectedIds: string[] | "all";
|
|
27
|
-
unselectedIds: string[];
|
|
28
|
-
cursorId: string;
|
|
29
|
-
columnCount: number;
|
|
30
|
-
pageSizeRef: React.MutableRefObject<number>;
|
|
31
|
-
cursorIndexRef: {
|
|
32
|
-
readonly current: number;
|
|
33
|
-
};
|
|
34
|
-
UNSTABLE_virtual: {
|
|
35
|
-
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
36
|
-
totalSize: number;
|
|
37
|
-
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
38
|
-
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
39
|
-
measure: () => void;
|
|
40
|
-
};
|
|
41
|
-
UNSTABLE_defaultItemHeight: number;
|
|
42
|
-
containerRef: React.RefObject<HTMLDivElement>;
|
|
43
|
-
orientation: "horizontal" | "vertical";
|
|
44
|
-
indexRef: React.MutableRefObject<number>;
|
|
45
|
-
nonInteractiveIds: string[];
|
|
46
|
-
isVirtualized: boolean;
|
|
47
|
-
items: import("../..").Item<any>[];
|
|
48
|
-
mode: "multiple" | "single";
|
|
49
|
-
value: string | undefined;
|
|
50
|
-
inputRef: React.RefObject<HTMLInputElement>;
|
|
51
|
-
width: number;
|
|
52
|
-
};
|
|
53
|
-
events: {
|
|
54
|
-
setWidth(width: number): void;
|
|
55
|
-
updatePlacement(data: {
|
|
56
|
-
placement: import("@popperjs/core").Placement;
|
|
57
|
-
}): void;
|
|
58
|
-
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
59
|
-
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
60
|
-
select(data: {
|
|
61
|
-
id: string;
|
|
62
|
-
}): void;
|
|
63
|
-
selectAll(): void;
|
|
64
|
-
unselectAll(): void;
|
|
65
|
-
setSelectedIds(ids: string[] | "all"): void;
|
|
66
|
-
goTo(data: {
|
|
67
|
-
id: string;
|
|
68
|
-
}): void;
|
|
69
|
-
goToNext(): void;
|
|
70
|
-
goToPrevious(): void;
|
|
71
|
-
goToPreviousRow(): void;
|
|
72
|
-
goToNextRow(): void;
|
|
73
|
-
goToFirst(): void;
|
|
74
|
-
goToLast(): void;
|
|
75
|
-
goToFirstOfRow(): void;
|
|
76
|
-
goToLastOfRow(): void;
|
|
77
|
-
goToNextPage(): void;
|
|
78
|
-
goToPreviousPage(): void;
|
|
79
|
-
registerItem(data: {
|
|
80
|
-
item: any;
|
|
81
|
-
textValue: string;
|
|
82
|
-
}): void;
|
|
83
|
-
unregisterItem(data: {
|
|
84
|
-
id: string;
|
|
85
|
-
}): void;
|
|
86
|
-
updateItemHeight(data: {
|
|
87
|
-
value: number;
|
|
88
|
-
}): void;
|
|
89
|
-
};
|
|
90
|
-
onFilterChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
91
|
-
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
92
|
-
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
93
|
-
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
94
|
-
getId: (item: any) => string;
|
|
95
|
-
}>;
|
|
96
|
-
export declare const SelectItem: import("@workday/canvas-kit-react/common").ElementComponentM<"li", import("../../menu/lib/MenuOption").MenuOptionProps & React.LiHTMLAttributes<HTMLLIElement> & import("@workday/canvas-kit-react/common").PropsWithModel<{
|
|
97
|
-
state: {
|
|
98
|
-
stackRef: React.RefObject<HTMLDivElement>;
|
|
99
|
-
targetRef: React.RefObject<HTMLButtonElement>;
|
|
100
|
-
initialFocusRef: React.RefObject<any> | undefined;
|
|
101
|
-
returnFocusRef: React.RefObject<any> | undefined;
|
|
102
|
-
placement: import("@popperjs/core").Placement;
|
|
103
|
-
id: string;
|
|
104
|
-
visibility: "hidden" | "visible";
|
|
105
|
-
selectedIds: string[] | "all";
|
|
106
|
-
unselectedIds: string[];
|
|
107
|
-
cursorId: string;
|
|
108
|
-
columnCount: number;
|
|
109
|
-
pageSizeRef: React.MutableRefObject<number>;
|
|
110
|
-
cursorIndexRef: {
|
|
111
|
-
readonly current: number;
|
|
112
|
-
};
|
|
113
|
-
UNSTABLE_virtual: {
|
|
114
|
-
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
115
|
-
totalSize: number;
|
|
116
|
-
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
117
|
-
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
118
|
-
measure: () => void;
|
|
119
|
-
};
|
|
120
|
-
UNSTABLE_defaultItemHeight: number;
|
|
121
|
-
containerRef: React.RefObject<HTMLDivElement>;
|
|
122
|
-
orientation: "horizontal" | "vertical";
|
|
123
|
-
indexRef: React.MutableRefObject<number>;
|
|
124
|
-
nonInteractiveIds: string[];
|
|
125
|
-
isVirtualized: boolean;
|
|
126
|
-
items: import("../..").Item<any>[];
|
|
127
|
-
mode: "multiple" | "single";
|
|
128
|
-
};
|
|
129
|
-
events: {
|
|
130
|
-
updatePlacement(data: {
|
|
131
|
-
placement: import("@popperjs/core").Placement;
|
|
132
|
-
}): void;
|
|
133
|
-
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
134
|
-
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
135
|
-
select(data: {
|
|
136
|
-
id: string;
|
|
137
|
-
}): void;
|
|
138
|
-
selectAll(): void;
|
|
139
|
-
unselectAll(): void;
|
|
140
|
-
setSelectedIds(ids: string[] | "all"): void;
|
|
141
|
-
goTo(data: {
|
|
142
|
-
id: string;
|
|
143
|
-
}): void;
|
|
144
|
-
goToNext(): void;
|
|
145
|
-
goToPrevious(): void;
|
|
146
|
-
goToPreviousRow(): void;
|
|
147
|
-
goToNextRow(): void;
|
|
148
|
-
goToFirst(): void;
|
|
149
|
-
goToLast(): void;
|
|
150
|
-
goToFirstOfRow(): void;
|
|
151
|
-
goToLastOfRow(): void;
|
|
152
|
-
goToNextPage(): void;
|
|
153
|
-
goToPreviousPage(): void;
|
|
154
|
-
registerItem(data: {
|
|
155
|
-
item: any;
|
|
156
|
-
textValue: string;
|
|
157
|
-
}): void;
|
|
158
|
-
unregisterItem(data: {
|
|
159
|
-
id: string;
|
|
160
|
-
}): void;
|
|
161
|
-
updateItemHeight(data: {
|
|
162
|
-
value: number;
|
|
163
|
-
}): void;
|
|
164
|
-
};
|
|
165
|
-
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
166
|
-
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
167
|
-
getId: (item: any) => string;
|
|
168
|
-
}, {}>, {
|
|
169
|
-
state: {
|
|
170
|
-
stackRef: React.RefObject<HTMLDivElement>;
|
|
171
|
-
targetRef: React.RefObject<HTMLButtonElement>;
|
|
172
|
-
initialFocusRef: React.RefObject<any> | undefined;
|
|
173
|
-
returnFocusRef: React.RefObject<any> | undefined;
|
|
174
|
-
placement: import("@popperjs/core").Placement;
|
|
175
|
-
id: string;
|
|
176
|
-
visibility: "hidden" | "visible";
|
|
177
|
-
selectedIds: string[] | "all";
|
|
178
|
-
unselectedIds: string[];
|
|
179
|
-
cursorId: string;
|
|
180
|
-
columnCount: number;
|
|
181
|
-
pageSizeRef: React.MutableRefObject<number>;
|
|
182
|
-
cursorIndexRef: {
|
|
183
|
-
readonly current: number;
|
|
184
|
-
};
|
|
185
|
-
UNSTABLE_virtual: {
|
|
186
|
-
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
187
|
-
totalSize: number;
|
|
188
|
-
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
189
|
-
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
190
|
-
measure: () => void;
|
|
191
|
-
};
|
|
192
|
-
UNSTABLE_defaultItemHeight: number;
|
|
193
|
-
containerRef: React.RefObject<HTMLDivElement>;
|
|
194
|
-
orientation: "horizontal" | "vertical";
|
|
195
|
-
indexRef: React.MutableRefObject<number>;
|
|
196
|
-
nonInteractiveIds: string[];
|
|
197
|
-
isVirtualized: boolean;
|
|
198
|
-
items: import("../..").Item<any>[];
|
|
199
|
-
mode: "multiple" | "single";
|
|
200
|
-
value: string | undefined;
|
|
201
|
-
inputRef: React.RefObject<HTMLInputElement>;
|
|
202
|
-
width: number;
|
|
203
|
-
};
|
|
204
|
-
events: {
|
|
205
|
-
setWidth(width: number): void;
|
|
206
|
-
updatePlacement(data: {
|
|
207
|
-
placement: import("@popperjs/core").Placement;
|
|
208
|
-
}): void;
|
|
209
|
-
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
210
|
-
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
211
|
-
select(data: {
|
|
212
|
-
id: string;
|
|
213
|
-
}): void;
|
|
214
|
-
selectAll(): void;
|
|
215
|
-
unselectAll(): void;
|
|
216
|
-
setSelectedIds(ids: string[] | "all"): void;
|
|
217
|
-
goTo(data: {
|
|
218
|
-
id: string;
|
|
219
|
-
}): void;
|
|
220
|
-
goToNext(): void;
|
|
221
|
-
goToPrevious(): void;
|
|
222
|
-
goToPreviousRow(): void;
|
|
223
|
-
goToNextRow(): void;
|
|
224
|
-
goToFirst(): void;
|
|
225
|
-
goToLast(): void;
|
|
226
|
-
goToFirstOfRow(): void;
|
|
227
|
-
goToLastOfRow(): void;
|
|
228
|
-
goToNextPage(): void;
|
|
229
|
-
goToPreviousPage(): void;
|
|
230
|
-
registerItem(data: {
|
|
231
|
-
item: any;
|
|
232
|
-
textValue: string;
|
|
233
|
-
}): void;
|
|
234
|
-
unregisterItem(data: {
|
|
235
|
-
id: string;
|
|
236
|
-
}): void;
|
|
237
|
-
updateItemHeight(data: {
|
|
238
|
-
value: number;
|
|
239
|
-
}): void;
|
|
240
|
-
};
|
|
241
|
-
onFilterChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
242
|
-
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
243
|
-
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
244
|
-
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
245
|
-
getId: (item: any) => string;
|
|
246
|
-
}> & {
|
|
247
|
-
Icon: (elemProps: import("@workday/canvas-kit-react/icon").SystemIconProps) => React.JSX.Element;
|
|
248
|
-
};
|
|
249
|
-
export declare const SelectCard: import("@workday/canvas-kit-react/common").ElementComponentM<"div", import("../../combobox/lib/ComboboxCard").ComboboxCardProps & React.HTMLAttributes<HTMLDivElement> & import("@workday/canvas-kit-react/common").PropsWithModel<{
|
|
250
|
-
state: {
|
|
251
|
-
stackRef: React.RefObject<HTMLDivElement>;
|
|
252
|
-
targetRef: React.RefObject<HTMLButtonElement>;
|
|
253
|
-
initialFocusRef: React.RefObject<any> | undefined;
|
|
254
|
-
returnFocusRef: React.RefObject<any> | undefined;
|
|
255
|
-
placement: import("@popperjs/core").Placement;
|
|
256
|
-
id: string;
|
|
257
|
-
visibility: "hidden" | "visible";
|
|
258
|
-
selectedIds: string[] | "all";
|
|
259
|
-
unselectedIds: string[];
|
|
260
|
-
cursorId: string;
|
|
261
|
-
columnCount: number;
|
|
262
|
-
pageSizeRef: React.MutableRefObject<number>;
|
|
263
|
-
cursorIndexRef: {
|
|
264
|
-
readonly current: number;
|
|
265
|
-
};
|
|
266
|
-
UNSTABLE_virtual: {
|
|
267
|
-
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
268
|
-
totalSize: number;
|
|
269
|
-
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
270
|
-
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
271
|
-
measure: () => void;
|
|
272
|
-
};
|
|
273
|
-
UNSTABLE_defaultItemHeight: number;
|
|
274
|
-
containerRef: React.RefObject<HTMLDivElement>;
|
|
275
|
-
orientation: "horizontal" | "vertical";
|
|
276
|
-
indexRef: React.MutableRefObject<number>;
|
|
277
|
-
nonInteractiveIds: string[];
|
|
278
|
-
isVirtualized: boolean;
|
|
279
|
-
items: import("../..").Item<any>[];
|
|
280
|
-
mode: "multiple" | "single";
|
|
281
|
-
value: string | undefined;
|
|
282
|
-
inputRef: React.RefObject<HTMLInputElement>;
|
|
283
|
-
width: number;
|
|
284
|
-
};
|
|
285
|
-
events: {
|
|
286
|
-
setWidth(width: number): void;
|
|
287
|
-
updatePlacement(data: {
|
|
288
|
-
placement: import("@popperjs/core").Placement;
|
|
289
|
-
}): void;
|
|
290
|
-
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
291
|
-
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
292
|
-
select(data: {
|
|
293
|
-
id: string;
|
|
294
|
-
}): void;
|
|
295
|
-
selectAll(): void;
|
|
296
|
-
unselectAll(): void;
|
|
297
|
-
setSelectedIds(ids: string[] | "all"): void;
|
|
298
|
-
goTo(data: {
|
|
299
|
-
id: string;
|
|
300
|
-
}): void;
|
|
301
|
-
goToNext(): void;
|
|
302
|
-
goToPrevious(): void;
|
|
303
|
-
goToPreviousRow(): void;
|
|
304
|
-
goToNextRow(): void;
|
|
305
|
-
goToFirst(): void;
|
|
306
|
-
goToLast(): void;
|
|
307
|
-
goToFirstOfRow(): void;
|
|
308
|
-
goToLastOfRow(): void;
|
|
309
|
-
goToNextPage(): void;
|
|
310
|
-
goToPreviousPage(): void;
|
|
311
|
-
registerItem(data: {
|
|
312
|
-
item: any;
|
|
313
|
-
textValue: string;
|
|
314
|
-
}): void;
|
|
315
|
-
unregisterItem(data: {
|
|
316
|
-
id: string;
|
|
317
|
-
}): void;
|
|
318
|
-
updateItemHeight(data: {
|
|
319
|
-
value: number;
|
|
320
|
-
}): void;
|
|
321
|
-
};
|
|
322
|
-
onFilterChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
323
|
-
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
324
|
-
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
325
|
-
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
326
|
-
getId: (item: any) => string;
|
|
327
|
-
}, {}>, {
|
|
328
|
-
state: {
|
|
329
|
-
stackRef: React.RefObject<HTMLDivElement>;
|
|
330
|
-
targetRef: React.RefObject<HTMLButtonElement>;
|
|
331
|
-
initialFocusRef: React.RefObject<any> | undefined;
|
|
332
|
-
returnFocusRef: React.RefObject<any> | undefined;
|
|
333
|
-
placement: import("@popperjs/core").Placement;
|
|
334
|
-
id: string;
|
|
335
|
-
visibility: "hidden" | "visible";
|
|
336
|
-
selectedIds: string[] | "all";
|
|
337
|
-
unselectedIds: string[];
|
|
338
|
-
cursorId: string;
|
|
339
|
-
columnCount: number;
|
|
340
|
-
pageSizeRef: React.MutableRefObject<number>;
|
|
341
|
-
cursorIndexRef: {
|
|
342
|
-
readonly current: number;
|
|
343
|
-
};
|
|
344
|
-
UNSTABLE_virtual: {
|
|
345
|
-
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
346
|
-
totalSize: number;
|
|
347
|
-
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
348
|
-
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
349
|
-
measure: () => void;
|
|
350
|
-
};
|
|
351
|
-
UNSTABLE_defaultItemHeight: number;
|
|
352
|
-
containerRef: React.RefObject<HTMLDivElement>;
|
|
353
|
-
orientation: "horizontal" | "vertical";
|
|
354
|
-
indexRef: React.MutableRefObject<number>;
|
|
355
|
-
nonInteractiveIds: string[];
|
|
356
|
-
isVirtualized: boolean;
|
|
357
|
-
items: import("../..").Item<any>[];
|
|
358
|
-
mode: "multiple" | "single";
|
|
359
|
-
value: string | undefined;
|
|
360
|
-
inputRef: React.RefObject<HTMLInputElement>;
|
|
361
|
-
width: number;
|
|
362
|
-
};
|
|
363
|
-
events: {
|
|
364
|
-
setWidth(width: number): void;
|
|
365
|
-
updatePlacement(data: {
|
|
366
|
-
placement: import("@popperjs/core").Placement;
|
|
367
|
-
}): void;
|
|
368
|
-
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
369
|
-
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
370
|
-
select(data: {
|
|
371
|
-
id: string;
|
|
372
|
-
}): void;
|
|
373
|
-
selectAll(): void;
|
|
374
|
-
unselectAll(): void;
|
|
375
|
-
setSelectedIds(ids: string[] | "all"): void;
|
|
376
|
-
goTo(data: {
|
|
377
|
-
id: string;
|
|
378
|
-
}): void;
|
|
379
|
-
goToNext(): void;
|
|
380
|
-
goToPrevious(): void;
|
|
381
|
-
goToPreviousRow(): void;
|
|
382
|
-
goToNextRow(): void;
|
|
383
|
-
goToFirst(): void;
|
|
384
|
-
goToLast(): void;
|
|
385
|
-
goToFirstOfRow(): void;
|
|
386
|
-
goToLastOfRow(): void;
|
|
387
|
-
goToNextPage(): void;
|
|
388
|
-
goToPreviousPage(): void;
|
|
389
|
-
registerItem(data: {
|
|
390
|
-
item: any;
|
|
391
|
-
textValue: string;
|
|
392
|
-
}): void;
|
|
393
|
-
unregisterItem(data: {
|
|
394
|
-
id: string;
|
|
395
|
-
}): void;
|
|
396
|
-
updateItemHeight(data: {
|
|
397
|
-
value: number;
|
|
398
|
-
}): void;
|
|
399
|
-
};
|
|
400
|
-
onFilterChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
401
|
-
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
402
|
-
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
403
|
-
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
404
|
-
getId: (item: any) => string;
|
|
405
|
-
}>;
|
|
406
4
|
export interface SelectProps extends ExtractProps<typeof Combobox> {
|
|
407
5
|
}
|
|
408
6
|
/**
|
|
@@ -2108,9 +1706,9 @@ export declare const Select: import("@workday/canvas-kit-react/common").Componen
|
|
|
2108
1706
|
* </Select>
|
|
2109
1707
|
* ```
|
|
2110
1708
|
*/
|
|
2111
|
-
Input: import("@workday/canvas-kit-react/common").ElementComponentM<import("@workday/canvas-kit-react/common").ElementComponent<"input", import("
|
|
1709
|
+
Input: import("@workday/canvas-kit-react/common").ElementComponentM<import("@workday/canvas-kit-react/common").ElementComponent<"input", import("../..").TextInputProps> & {
|
|
2112
1710
|
ErrorType: typeof import("@workday/canvas-kit-react/common").ErrorType;
|
|
2113
|
-
}, SelectInputProps, {
|
|
1711
|
+
}, import("./SelectInput").SelectInputProps, {
|
|
2114
1712
|
state: {
|
|
2115
1713
|
stackRef: React.RefObject<HTMLDivElement>;
|
|
2116
1714
|
targetRef: React.RefObject<HTMLButtonElement>;
|
|
@@ -2717,7 +2315,7 @@ export declare const Select: import("@workday/canvas-kit-react/common").Componen
|
|
|
2717
2315
|
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
2718
2316
|
getId: (item: any) => string;
|
|
2719
2317
|
}> & {
|
|
2720
|
-
Icon: (elemProps: import("
|
|
2318
|
+
Icon: (elemProps: import("../..").SystemIconProps) => React.JSX.Element;
|
|
2721
2319
|
};
|
|
2722
2320
|
};
|
|
2723
2321
|
//# sourceMappingURL=Select.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../../../../select/lib/Select.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../../../../select/lib/Select.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAC,QAAQ,EAAC,MAAM,oCAAoC,CAAC;AAE5D,OAAO,EAAC,YAAY,EAAkB,MAAM,kCAAkC,CAAC;AAK/E,MAAM,WAAW,WAAY,SAAQ,YAAY,CAAC,OAAO,QAAQ,CAAC;CAAG;AACrE;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAIf;;;;;;;;;;;;OAYG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAEH;;;;;;;;;;;;;OAaG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAEH;;;;;;;;;;;;;;;;;OAiBG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAEH;;;;;;;;;;;;;;;;;OAiBG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAEH;;;;;;;;;;;;;;;;;OAiBG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CASL,CAAC"}
|
|
@@ -1,51 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { caretDownSmallIcon } from '@workday/canvas-system-icons-web';
|
|
3
2
|
import { Combobox } from '@workday/canvas-kit-react/combobox';
|
|
4
|
-
import { createStencil, createStyles, px2rem } from '@workday/canvas-kit-styling';
|
|
5
|
-
import { InputGroup, TextInput } from '@workday/canvas-kit-react/text-input';
|
|
6
|
-
import { mergeStyles } from '@workday/canvas-kit-react/layout';
|
|
7
|
-
import { SystemIcon } from '@workday/canvas-kit-react/icon';
|
|
8
|
-
import { useSelectCard } from './hooks/useSelectCard';
|
|
9
|
-
import { useSelectInput } from './hooks/useSelectInput';
|
|
10
3
|
import { useSelectModel } from './hooks/useSelectModel';
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}, "select-input-0c2dc2");
|
|
16
|
-
const selectIconsStencil = createStencil({
|
|
17
|
-
base: { name: "zx5j58", styles: "box-sizing:border-box;position:absolute;pointer-events:none;" }
|
|
18
|
-
}, "select-icons-c2731a");
|
|
19
|
-
const hiddenSelectInputStencil = createStencil({
|
|
20
|
-
base: { name: "zx5j59", styles: "box-sizing:border-box;position:absolute;top:var(--cnvs-sys-space-zero);bottom:var(--cnvs-sys-space-zero);left:var(--cnvs-sys-space-zero);right:var(--cnvs-sys-space-zero);opacity:var(--cnvs-sys-opacity-zero);cursor:default;pointer-events:none;" }
|
|
21
|
-
}, "hidden-select-input-231156");
|
|
22
|
-
export const SelectInput = createSubcomponent(TextInput)({
|
|
23
|
-
modelHook: useSelectModel,
|
|
24
|
-
elemPropsHook: useSelectInput,
|
|
25
|
-
})(({ placeholder = 'Choose an option', inputStartIcon, formInputProps, width, ...elemProps }, Element, model) => {
|
|
26
|
-
return (React.createElement(InputGroup, { "data-width": "ck-formfield-width" },
|
|
27
|
-
inputStartIcon && model.state.selectedIds.length > 0 && (React.createElement(InputGroup.InnerStart, { "data-part": "select-start-icon-container", ...selectIconsStencil() },
|
|
28
|
-
React.createElement(SystemIcon, { "data-part": "select-start-icon", icon: inputStartIcon }))),
|
|
29
|
-
React.createElement(InputGroup.Input, { "data-part": "select-hidden-input", ...formInputProps, ...hiddenSelectInputStencil() }),
|
|
30
|
-
React.createElement(InputGroup.Input, { as: Element, placeholder: placeholder, "data-part": "select-visual-input", ...elemProps, ...mergeStyles(elemProps, selectInputStencil()) }),
|
|
31
|
-
React.createElement(InputGroup.InnerEnd, { "data-part": "select-caret-container" },
|
|
32
|
-
React.createElement(SystemIcon, { "data-part": "select-caret-icon", icon: caretDownSmallIcon }))));
|
|
33
|
-
});
|
|
34
|
-
export const SelectItem = createSubcomponent('li')({
|
|
35
|
-
modelHook: useSelectModel,
|
|
36
|
-
subComponents: {
|
|
37
|
-
Icon: Combobox.Menu.Item.Icon,
|
|
38
|
-
},
|
|
39
|
-
})(({ children, ...elemProps }, Element, _model) => {
|
|
40
|
-
return (React.createElement(Combobox.Menu.Item, { as: Element, ...elemProps }, children));
|
|
41
|
-
});
|
|
42
|
-
const selectCardStyles = createStyles({ name: "zx5j5a", styles: "max-height:18.75rem;" });
|
|
43
|
-
export const SelectCard = createSubcomponent('div')({
|
|
44
|
-
modelHook: useSelectModel,
|
|
45
|
-
elemPropsHook: useSelectCard,
|
|
46
|
-
})(({ children, ...elemProps }, Element) => {
|
|
47
|
-
return (React.createElement(Combobox.Menu.Card, { as: Element, ...mergeStyles(elemProps, selectCardStyles) }, children));
|
|
48
|
-
});
|
|
4
|
+
import { createContainer } from '@workday/canvas-kit-react/common';
|
|
5
|
+
import { SelectInput } from './SelectInput';
|
|
6
|
+
import { SelectCard } from './SelectCard';
|
|
7
|
+
import { SelectItem } from './SelectItem';
|
|
49
8
|
/**
|
|
50
9
|
* Use `Select` to allow users to choose an option from a list or type characters to select a matching option.
|
|
51
10
|
*
|