@workday/canvas-kit-docs 12.0.0-alpha.862-next.0 → 12.0.0-alpha.898-next.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/dist/es6/docgen/docParser.d.ts +1 -1
- package/dist/es6/docgen/docParser.d.ts.map +1 -1
- package/dist/es6/docgen/docParser.js +12 -2
- package/dist/es6/docgen/docTypes.d.ts +1 -1
- package/dist/es6/docgen/docTypes.d.ts.map +1 -1
- package/dist/es6/docgen/plugins/enhancedComponentParser.d.ts +1 -1
- package/dist/es6/docgen/plugins/enhancedComponentParser.d.ts.map +1 -1
- package/dist/es6/docgen/traverse.d.ts +2 -2
- package/dist/es6/docgen/traverse.d.ts.map +1 -1
- package/dist/es6/index.d.ts +1 -0
- package/dist/es6/index.d.ts.map +1 -1
- package/dist/es6/index.js +1 -0
- package/dist/es6/lib/ExampleCodeBlock.d.ts +3 -0
- package/dist/es6/lib/ExampleCodeBlock.d.ts.map +1 -0
- package/dist/es6/lib/ExampleCodeBlock.js +56 -0
- package/dist/es6/lib/InformationHighlight/Base.js +1 -1
- package/dist/es6/lib/InformationHighlight/Body.js +1 -1
- package/dist/es6/lib/InformationHighlight/Heading.js +1 -1
- package/dist/es6/lib/InformationHighlight/Icon.d.ts +1 -1
- package/dist/es6/lib/InformationHighlight/Icon.d.ts.map +1 -1
- package/dist/es6/lib/InformationHighlight/Icon.js +1 -1
- package/dist/es6/lib/InformationHighlight/Link.js +1 -1
- package/dist/es6/lib/InformationHighlight/index.d.ts +1 -1
- package/dist/es6/lib/InformationHighlight/index.d.ts.map +1 -1
- package/dist/es6/lib/InformationHighlight/index.js +1 -1
- package/dist/es6/lib/InformationHighlight/modelHook.d.ts +1 -1
- package/dist/es6/lib/InformationHighlight/modelHook.d.ts.map +1 -1
- package/dist/es6/lib/MDXElements.d.ts +2 -1
- package/dist/es6/lib/MDXElements.d.ts.map +1 -1
- package/dist/es6/lib/MDXElements.js +1 -1
- package/dist/es6/lib/MoreTooltip.d.ts +1 -1
- package/dist/es6/lib/MoreTooltip.d.ts.map +1 -1
- package/dist/es6/lib/MoreTooltip.js +2 -2
- package/dist/es6/lib/Specifications.d.ts +2 -1
- package/dist/es6/lib/Specifications.d.ts.map +1 -1
- package/dist/es6/lib/StylePropsTable.d.ts +3 -2
- package/dist/es6/lib/StylePropsTable.d.ts.map +1 -1
- package/dist/es6/lib/Table.js +6 -6
- package/dist/es6/lib/Value.d.ts +3 -3
- package/dist/es6/lib/Value.d.ts.map +1 -1
- package/dist/es6/lib/Value.js +4 -2
- package/dist/es6/lib/docs.d.ts +3 -3
- package/dist/es6/lib/docs.d.ts.map +1 -1
- package/dist/es6/lib/docs.js +76923 -72365
- package/dist/es6/lib/specs.js +1 -7130
- package/dist/es6/lib/widgetUtils.d.ts +5 -5
- package/dist/es6/lib/widgetUtils.d.ts.map +1 -1
- package/dist/es6/lib/widgetUtils.js +2 -2
- package/dist/es6/mdx/installBlock.d.ts +2 -1
- package/dist/es6/mdx/installBlock.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Background.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Background.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Background.js +6 -4
- package/dist/es6/mdx/style-props/examples/Border.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Border.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Border.js +4 -4
- package/dist/es6/mdx/style-props/examples/Color.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Color.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Color.js +4 -4
- package/dist/es6/mdx/style-props/examples/Depth.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Depth.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Depth.js +4 -4
- package/dist/es6/mdx/style-props/examples/Flex.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Flex.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Flex.js +9 -9
- package/dist/es6/mdx/style-props/examples/FlexItem.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/FlexItem.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/FlexItem.js +9 -9
- package/dist/es6/mdx/style-props/examples/Grid.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Grid.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Grid.js +4 -4
- package/dist/es6/mdx/style-props/examples/GridItem.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/GridItem.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/GridItem.js +5 -5
- package/dist/es6/mdx/style-props/examples/Layout.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Layout.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Layout.js +4 -4
- package/dist/es6/mdx/style-props/examples/Other.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Other.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Other.js +4 -4
- package/dist/es6/mdx/style-props/examples/Position.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Position.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Position.js +4 -4
- package/dist/es6/mdx/style-props/examples/Space.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Space.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Space.js +4 -4
- package/dist/es6/mdx/style-props/examples/Text.d.ts +2 -1
- package/dist/es6/mdx/style-props/examples/Text.d.ts.map +1 -1
- package/dist/es6/mdx/style-props/examples/Text.js +1 -1
- package/dist/es6/mdx/versionsTable.d.ts +2 -1
- package/dist/es6/mdx/versionsTable.d.ts.map +1 -1
- package/dist/es6/mdx/welcomePage.d.ts +2 -1
- package/dist/es6/mdx/welcomePage.d.ts.map +1 -1
- package/dist/es6/mdx/welcomePage.js +5 -3
- package/dist/mdx/11.0-UPGRADE-GUIDE.mdx +8 -8
- package/dist/mdx/12.0-UPGRADE-GUIDE.mdx +350 -39
- package/dist/mdx/4.0-UPGRADE-GUIDE.mdx +1 -11
- package/dist/mdx/5.0-UPGRADE-GUIDE.mdx +0 -10
- package/dist/mdx/6.0-UPGRADE-GUIDE.mdx +0 -10
- package/dist/mdx/7.0-UPGRADE-GUIDE.mdx +0 -10
- package/dist/mdx/8.0-UPGRADE-GUIDE.mdx +0 -10
- package/dist/mdx/API_PATTERN_GUIDELINES.mdx +0 -10
- package/dist/mdx/COMPOUND_COMPONENTS.mdx +0 -10
- package/dist/mdx/CONTRIBUTING.mdx +0 -10
- package/dist/mdx/CREATING_COMPOUND_COMPONENTS.mdx +0 -10
- package/dist/mdx/DOCUMENTATION_GUIDELINES.mdx +20 -22
- package/dist/mdx/GETTING_STARTED.mdx +0 -9
- package/dist/mdx/MAINTAINING.mdx +12 -20
- package/dist/mdx/TESTING.mdx +1 -26
- package/dist/mdx/changelog.mdx +5 -0
- package/dist/mdx/labs-react/combobox/Combobox.mdx +52 -0
- package/dist/mdx/labs-react/combobox/examples/Basic.tsx +87 -0
- package/dist/mdx/labs-react/combobox/examples/DisabledItem.tsx +87 -0
- package/dist/mdx/labs-react/combobox/examples/GroupOfResult.tsx +87 -0
- package/dist/mdx/labs-react/combobox/examples/Grow.tsx +87 -0
- package/dist/mdx/labs-react/combobox/examples/NoClearButton.tsx +87 -0
- package/dist/mdx/labs-react/combobox/examples/RTL.tsx +90 -0
- package/dist/mdx/labs-react/expandable/Expandable.mdx +1 -3
- package/dist/mdx/labs-react/search-form/SearchForm.mdx +1 -4
- package/dist/mdx/preview-react/_examples/mdx/Forms.mdx +9 -0
- package/dist/mdx/preview-react/_examples/mdx/FormsWithFormik.mdx +14 -0
- package/dist/mdx/preview-react/_examples/{examples → mdx/examples}/SelectWithFormik.tsx +1 -5
- package/dist/mdx/preview-react/_examples/{examples → mdx/examples}/TextInputWithReactHookForm.tsx +2 -1
- package/dist/mdx/preview-react/divider/Divider.mdx +36 -0
- package/dist/mdx/preview-react/divider/examples/Basic.tsx +105 -0
- package/dist/mdx/preview-react/divider/examples/CustomSpace.tsx +32 -0
- package/dist/mdx/preview-react/loading-sparkles/LoadingSparkles.mdx +1 -2
- package/dist/mdx/preview-react/menu/Menu.mdx +2 -9
- package/dist/mdx/preview-react/pill/Pill.mdx +1 -3
- package/dist/mdx/preview-react/radio/Radio.mdx +1 -3
- package/dist/mdx/preview-react/radio/examples/Alert.tsx +26 -11
- package/dist/mdx/preview-react/radio/examples/Basic.tsx +29 -19
- package/dist/mdx/preview-react/radio/examples/Custom.tsx +32 -30
- package/dist/mdx/preview-react/radio/examples/Disabled.tsx +25 -12
- package/dist/mdx/preview-react/radio/examples/Error.tsx +26 -11
- package/dist/mdx/preview-react/radio/examples/Inverse.tsx +14 -18
- package/dist/mdx/preview-react/radio/examples/LabelPosition.tsx +25 -10
- package/dist/mdx/preview-react/radio/examples/NoValue.tsx +23 -10
- package/dist/mdx/preview-react/radio/examples/RefForwarding.tsx +17 -11
- package/dist/mdx/preview-react/radio/examples/Required.tsx +19 -11
- package/dist/mdx/preview-react/radio/examples/StandaloneRadio.tsx +6 -6
- package/dist/mdx/preview-react/segmented-control/SegmentedControl.mdx +1 -4
- package/dist/mdx/preview-react/select/Select.mdx +89 -0
- package/dist/mdx/preview-react/select/examples/Left Label/AlertLeft.tsx +18 -0
- package/dist/mdx/preview-react/select/examples/Left Label/DefaultLeft.tsx +17 -0
- package/dist/mdx/preview-react/select/examples/Left Label/DefaultWithCustomOptionsLeft.tsx +25 -0
- package/dist/mdx/preview-react/select/examples/Left Label/DefaultWithSimpleOptionsLeft.tsx +17 -0
- package/dist/mdx/preview-react/select/examples/Left Label/DisabledLeft.tsx +19 -0
- package/dist/mdx/preview-react/select/examples/Left Label/ErrorLeft.tsx +18 -0
- package/dist/mdx/preview-react/select/examples/Left Label/GrowLeft.tsx +17 -0
- package/dist/mdx/preview-react/select/examples/Left Label/ScrollableLeft.tsx +17 -0
- package/dist/mdx/preview-react/select/examples/Left Label/index.ts +8 -0
- package/dist/mdx/preview-react/select/examples/Top Label/Alert.tsx +18 -0
- package/dist/mdx/preview-react/select/examples/Top Label/Default.tsx +17 -0
- package/dist/mdx/preview-react/select/examples/Top Label/DefaultWithCustomOptions.tsx +25 -0
- package/dist/mdx/preview-react/select/examples/Top Label/DefaultWithSimpleOptions.tsx +17 -0
- package/dist/mdx/preview-react/select/examples/Top Label/Disabled.tsx +19 -0
- package/dist/mdx/preview-react/select/examples/Top Label/Error.tsx +18 -0
- package/dist/mdx/preview-react/select/examples/Top Label/Grow.tsx +17 -0
- package/dist/mdx/preview-react/select/examples/Top Label/Scrollable.tsx +15 -0
- package/dist/mdx/preview-react/select/examples/Top Label/index.ts +8 -0
- package/dist/mdx/preview-react/select/examples/storiesData.tsx +93 -0
- package/dist/mdx/preview-react/side-panel/SidePanel.mdx +1 -4
- package/dist/mdx/preview-react/status-indicator/StatusIndicator.mdx +1 -2
- package/dist/mdx/preview-react/text-area/TextArea.mdx +1 -4
- package/dist/mdx/preview-react/text-area/examples/Alert.tsx +1 -1
- package/dist/mdx/preview-react/text-area/examples/LabelPositionHorizontal.tsx +1 -1
- package/dist/mdx/preview-react/text-input/TextInput.mdx +4 -7
- package/dist/mdx/preview-react/text-input/examples/LabelPositionHorizontal.tsx +1 -1
- package/dist/mdx/react/_examples/{AriaLiveRegions.mdx → mdx/AriaLiveRegions.mdx} +1 -0
- package/dist/mdx/react/_examples/{CompoundComponent.mdx → mdx/CompoundComponent.mdx} +2 -0
- package/dist/mdx/react/_examples/mdx/CookieBanner.mdx +9 -0
- package/dist/mdx/react/_examples/mdx/Density.mdx +11 -0
- package/dist/mdx/react/_examples/mdx/Headers.mdx +19 -0
- package/dist/mdx/react/_examples/{Layouts.mdx → mdx/Layouts.mdx} +1 -0
- package/dist/mdx/react/_examples/{MediaModal.mdx → mdx/MediaModal.mdx} +3 -2
- package/dist/mdx/react/_examples/{SearchForm.mdx → mdx/SearchForm.mdx} +1 -0
- package/dist/mdx/react/_examples/{SidePanel.mdx → mdx/SidePanel.mdx} +2 -1
- package/dist/mdx/react/_examples/{TablesAdvanced.mdx → mdx/TablesAdvanced.mdx} +5 -5
- package/dist/mdx/react/_examples/{examples → mdx/examples}/AriaLiveRegions/FilterListWithLiveStatus.tsx +1 -1
- package/dist/mdx/react/_examples/{examples → mdx/examples}/AriaLiveRegions/HiddenLiveRegion.tsx +1 -1
- package/dist/mdx/react/_examples/{examples → mdx/examples}/AriaLiveRegions/TextInputWithLiveError.tsx +1 -1
- package/dist/mdx/react/_examples/{examples → mdx/examples}/AriaLiveRegions/VisibleLiveRegion.tsx +1 -1
- package/dist/mdx/react/_examples/mdx/examples/Density.tsx +370 -0
- package/dist/mdx/react/_examples/{examples → mdx/examples}/SidePanelWithNavigation.tsx +0 -1
- package/dist/mdx/react/_examples/{examples → mdx/examples}/Table/WithExpandableRows.tsx +26 -29
- package/dist/mdx/react/_examples/mdx/examples/common/FilterListWithLiveStatus.tsx +65 -0
- package/dist/mdx/react/_examples/mdx/examples/common/HiddenLiveRegion.tsx +30 -0
- package/dist/mdx/react/_examples/mdx/examples/common/IconButtonsWithLiveBadges.tsx +98 -0
- package/dist/mdx/react/_examples/mdx/examples/common/TextInputWithLiveError.tsx +25 -0
- package/dist/mdx/react/_examples/mdx/examples/common/VisibleLiveRegion.tsx +40 -0
- package/dist/mdx/react/action-bar/ActionBar.mdx +1 -5
- package/dist/mdx/react/action-bar/examples/Basic.tsx +12 -10
- package/dist/mdx/react/action-bar/examples/OverflowActionBar.tsx +13 -10
- package/dist/mdx/react/action-bar/examples/index.ts +5 -0
- package/dist/mdx/react/avatar/avatar/Avatar.mdx +12 -10
- package/dist/mdx/react/avatar/avatar/examples/Button.tsx +1 -1
- package/dist/mdx/react/avatar/avatar/examples/CustomStyles.tsx +2 -2
- package/dist/mdx/react/avatar/avatar/examples/Image.tsx +1 -1
- package/dist/mdx/react/avatar/avatar/examples/LazyLoad.tsx +1 -1
- package/dist/mdx/react/avatar/avatar/examples/test-avatar.png +0 -0
- package/dist/mdx/react/badge/CountBadge.mdx +15 -18
- package/dist/mdx/react/badge/examples/NotificationBadge.tsx +30 -25
- package/dist/mdx/react/banner/Banner.mdx +3 -5
- package/dist/mdx/react/breadcrumbs/Breadcrumbs.mdx +1 -5
- package/dist/mdx/react/button/button/Button.mdx +6 -1
- package/dist/mdx/react/button/button/Hyperlink.mdx +1 -4
- package/dist/mdx/react/button/button/examples/CustomStyles.tsx +21 -7
- package/dist/mdx/react/button/button/examples/Delete.tsx +1 -1
- package/dist/mdx/react/button/button/examples/Primary.tsx +1 -1
- package/dist/mdx/react/card/card.mdx +3 -4
- package/dist/mdx/react/checkbox/Checkbox.mdx +6 -17
- package/dist/mdx/react/checkbox/examples/Alert.tsx +5 -4
- package/dist/mdx/react/checkbox/examples/Basic.tsx +14 -1
- package/dist/mdx/react/checkbox/examples/Disabled.tsx +13 -6
- package/dist/mdx/react/checkbox/examples/Error.tsx +5 -4
- package/dist/mdx/react/checkbox/examples/Inverse.tsx +0 -1
- package/dist/mdx/react/checkbox/examples/LabelPosition.tsx +11 -9
- package/dist/mdx/react/checkbox/examples/RefForwarding.tsx +21 -7
- package/dist/mdx/react/checkbox/examples/Required.tsx +10 -8
- package/dist/mdx/react/collection/{Collection.mdx → mdx/Collection.mdx} +1 -3
- package/dist/mdx/react/color-picker/color-input/ColorInput.mdx +6 -18
- package/dist/mdx/react/color-picker/color-input/examples/Alert.tsx +5 -3
- package/dist/mdx/react/color-picker/color-input/examples/Basic.tsx +4 -2
- package/dist/mdx/react/color-picker/color-input/examples/Checked.tsx +4 -2
- package/dist/mdx/react/color-picker/color-input/examples/Disabled.tsx +4 -2
- package/dist/mdx/react/color-picker/color-input/examples/Error.tsx +5 -3
- package/dist/mdx/react/color-picker/color-input/examples/Grow.tsx +9 -2
- package/dist/mdx/react/color-picker/color-input/examples/LabelPosition.tsx +5 -3
- package/dist/mdx/react/color-picker/color-input/examples/RefForwarding.tsx +4 -2
- package/dist/mdx/react/color-picker/color-input/examples/Required.tsx +4 -2
- package/dist/mdx/react/color-picker/color-input/examples/ValidColorChange.tsx +9 -7
- package/dist/mdx/react/color-picker/color-preview/ColorPreview.mdx +6 -17
- package/dist/mdx/react/color-picker/color-preview/examples/Basic.tsx +9 -1
- package/dist/mdx/react/color-picker/color-preview/examples/LabelPosition.tsx +5 -3
- package/dist/mdx/react/color-picker/color-preview/examples/RefForwarding.tsx +4 -2
- package/dist/mdx/react/combobox/Combobox.mdx +1 -4
- package/dist/mdx/react/combobox/examples/Autocomplete.tsx +32 -30
- package/dist/mdx/react/common/{CompoundComponentUtilities.mdx → mdx/CompoundComponentUtilities.mdx} +2 -1
- package/dist/mdx/react/common/{Responsive.mdx → mdx/Responsive.mdx} +2 -2
- package/dist/mdx/react/common/{examples → mdx/examples}/ResponsiveStyles.tsx +1 -1
- package/dist/mdx/react/dialog/Dialog.mdx +1 -4
- package/dist/mdx/react/dialog/examples/Basic.tsx +1 -1
- package/dist/mdx/react/dialog/examples/DialogWithFallbackPlacements.tsx +110 -0
- package/dist/mdx/react/dialog/examples/Focus.tsx +1 -1
- package/dist/mdx/react/form-field/FormField.mdx +104 -78
- package/dist/mdx/react/form-field/examples/Alert.tsx +11 -9
- package/dist/mdx/{preview-react → react}/form-field/examples/AllFields.tsx +43 -8
- package/dist/mdx/react/form-field/examples/Basic.tsx +9 -4
- package/dist/mdx/{preview-react → react}/form-field/examples/Custom.tsx +2 -2
- package/dist/mdx/{preview-react → react}/form-field/examples/CustomId.tsx +4 -2
- package/dist/mdx/{preview-react → react}/form-field/examples/Disabled.tsx +4 -2
- package/dist/mdx/react/form-field/examples/Error.tsx +12 -9
- package/dist/mdx/react/form-field/examples/GroupedInputs.tsx +207 -0
- package/dist/mdx/react/form-field/examples/Grow.tsx +7 -3
- package/dist/mdx/react/form-field/examples/Hint.tsx +11 -8
- package/dist/mdx/react/form-field/examples/LabelPositionHorizontalEnd.tsx +32 -0
- package/dist/mdx/react/form-field/examples/LabelPositionHorizontalStart.tsx +32 -0
- package/dist/mdx/{preview-react → react}/form-field/examples/RefForwarding.tsx +4 -2
- package/dist/mdx/react/form-field/examples/Required.tsx +11 -3
- package/dist/mdx/{preview-react → react}/form-field/examples/ThemedErrors.tsx +7 -5
- package/dist/mdx/react/icon/Assets.mdx +13 -6
- package/dist/mdx/react/icon/examples/AccentIconList.tsx +1 -1
- package/dist/mdx/react/layout/Box.mdx +1 -3
- package/dist/mdx/react/layout/Flex.mdx +8 -7
- package/dist/mdx/react/layout/Grid.mdx +2 -4
- package/dist/mdx/react/loading-dots/LoadingDots.mdx +1 -3
- package/dist/mdx/react/menu/Menu.mdx +1 -4
- package/dist/mdx/react/menu/examples/MenuWithFallbackPlacements.tsx +66 -0
- package/dist/mdx/react/modal/Modal.mdx +1 -4
- package/dist/mdx/react/modal/examples/CustomFocus.tsx +1 -1
- package/dist/mdx/react/modal/examples/FormModal.tsx +1 -1
- package/dist/mdx/react/modal/examples/IframeTest.tsx +26 -0
- package/dist/mdx/react/modal/examples/ModalWithPopup.tsx +66 -0
- package/dist/mdx/react/modal/examples/ReturnFocus.tsx +1 -1
- package/dist/mdx/react/modal/examples/StackedModals.tsx +56 -0
- package/dist/mdx/react/modal/examples/WithRadioButtons.tsx +30 -0
- package/dist/mdx/react/modal/examples/WithTooltips.tsx +74 -0
- package/dist/mdx/react/pagination/pagination.mdx +1 -5
- package/dist/mdx/react/popup/Popup.mdx +30 -6
- package/dist/mdx/react/popup/examples/CloseOnTargetHiddenTest.tsx +54 -0
- package/dist/mdx/react/popup/examples/ComboboxWithinPopup.tsx +48 -0
- package/dist/mdx/react/popup/examples/MixedPopupTypes.tsx +143 -0
- package/dist/mdx/react/popup/examples/PopupWithFallbackPlacements.tsx +82 -0
- package/dist/mdx/react/popup/examples/PopupWithNonHidablePopup.tsx +42 -0
- package/dist/mdx/react/popup/examples/ReturnFocusTest.tsx +68 -0
- package/dist/mdx/react/popup/examples/TooltipReturnFocus.tsx +36 -0
- package/dist/mdx/react/radio/Radio.mdx +6 -16
- package/dist/mdx/react/radio/examples/Alert.tsx +1 -1
- package/dist/mdx/react/radio/examples/Basic.tsx +1 -1
- package/dist/mdx/react/radio/examples/Disabled.tsx +1 -1
- package/dist/mdx/react/radio/examples/Error.tsx +1 -1
- package/dist/mdx/react/radio/examples/LabelPosition.tsx +2 -2
- package/dist/mdx/react/radio/examples/NoValue.tsx +2 -2
- package/dist/mdx/react/radio/examples/RefForwarding.tsx +1 -1
- package/dist/mdx/react/radio/examples/Required.tsx +1 -1
- package/dist/mdx/react/segmented-control/SegmentedControl.mdx +1 -5
- package/dist/mdx/react/select/Select.mdx +18 -28
- package/dist/mdx/react/select/examples/Alert.tsx +15 -13
- package/dist/mdx/react/select/examples/Basic.tsx +18 -16
- package/dist/mdx/react/select/examples/Complex.tsx +14 -12
- package/dist/mdx/react/select/examples/Disabled.tsx +21 -19
- package/dist/mdx/react/select/examples/DisabledOption.tsx +24 -22
- package/dist/mdx/react/select/examples/Error.tsx +21 -19
- package/dist/mdx/react/select/examples/FetchingDynamicItems.tsx +23 -19
- package/dist/mdx/react/select/examples/Grow.tsx +14 -12
- package/dist/mdx/react/select/examples/HoistedModel.tsx +14 -12
- package/dist/mdx/react/select/examples/InitialSelectedItem.tsx +18 -15
- package/dist/mdx/react/select/examples/LabelPosition.tsx +15 -12
- package/dist/mdx/react/select/examples/MenuHeight.tsx +11 -9
- package/dist/mdx/react/select/examples/Placeholder.tsx +17 -14
- package/dist/mdx/react/select/examples/RefForwarding.tsx +13 -10
- package/dist/mdx/react/select/examples/Required.tsx +12 -10
- package/dist/mdx/react/select/examples/WithIcons.tsx +25 -23
- package/dist/mdx/react/skeleton/Skeleton.mdx +1 -5
- package/dist/mdx/react/skeleton/examples/Simulation.tsx +3 -3
- package/dist/mdx/react/status-indicator/StatusIndicator.mdx +5 -8
- package/dist/mdx/react/switch/Switch.mdx +6 -17
- package/dist/mdx/react/switch/examples/Alert.tsx +5 -3
- package/dist/mdx/react/switch/examples/Basic.tsx +4 -2
- package/dist/mdx/react/switch/examples/Disabled.tsx +4 -2
- package/dist/mdx/react/switch/examples/Error.tsx +5 -3
- package/dist/mdx/react/switch/examples/LabelPosition.tsx +5 -3
- package/dist/mdx/react/switch/examples/RefForwarding.tsx +4 -2
- package/dist/mdx/react/table/Table.mdx +1 -4
- package/dist/mdx/react/tabs/Tabs.mdx +1 -4
- package/dist/mdx/react/testing/Testing.mdx +1 -4
- package/dist/mdx/react/text/BodyText.mdx +1 -3
- package/dist/mdx/react/text/Heading.mdx +1 -3
- package/dist/mdx/react/text/LabelText.mdx +1 -3
- package/dist/mdx/react/text/Subtext.mdx +1 -3
- package/dist/mdx/react/text/Text.mdx +1 -3
- package/dist/mdx/react/text/Title.mdx +1 -3
- package/dist/mdx/react/text-area/TextArea.mdx +6 -17
- package/dist/mdx/react/text-area/examples/Alert.tsx +5 -3
- package/dist/mdx/react/text-area/examples/Basic.tsx +4 -2
- package/dist/mdx/react/text-area/examples/Disabled.tsx +4 -2
- package/dist/mdx/react/text-area/examples/Error.tsx +5 -3
- package/dist/mdx/react/text-area/examples/Grow.tsx +6 -4
- package/dist/mdx/react/text-area/examples/LabelPosition.tsx +6 -3
- package/dist/mdx/react/text-area/examples/Placeholder.tsx +9 -7
- package/dist/mdx/react/text-area/examples/RefForwarding.tsx +4 -2
- package/dist/mdx/react/text-area/examples/Required.tsx +4 -2
- package/dist/mdx/react/text-area/examples/ResizeConstraints.tsx +9 -7
- package/dist/mdx/react/text-input/TextInput.mdx +7 -16
- package/dist/mdx/react/text-input/examples/Alert.tsx +5 -3
- package/dist/mdx/react/text-input/examples/Basic.tsx +5 -3
- package/dist/mdx/react/text-input/examples/Disabled.tsx +4 -2
- package/dist/mdx/react/text-input/examples/Error.tsx +5 -3
- package/dist/mdx/react/text-input/examples/Grow.tsx +5 -3
- package/dist/mdx/react/text-input/examples/Icons.tsx +4 -2
- package/dist/mdx/react/text-input/examples/LabelPosition.tsx +6 -3
- package/dist/mdx/react/text-input/examples/Placeholder.tsx +9 -7
- package/dist/mdx/react/text-input/examples/RefForwarding.tsx +4 -2
- package/dist/mdx/react/text-input/examples/Required.tsx +4 -2
- package/dist/mdx/react/toast/toast.mdx +5 -6
- package/dist/mdx/react/tokens/Tokens.mdx +1 -2
- package/dist/mdx/react/tooltip/Tooltip.mdx +1 -5
- package/dist/mdx/style-props/STYLE_PROPS.mdx +25 -25
- package/dist/mdx/style-props/examples/Background.tsx +15 -22
- package/dist/mdx/style-props/examples/Border.tsx +3 -18
- package/dist/mdx/style-props/examples/Color.tsx +9 -21
- package/dist/mdx/style-props/examples/Flex.tsx +27 -9
- package/dist/mdx/style-props/examples/FlexItem.tsx +24 -8
- package/dist/mdx/style-props/examples/Position.tsx +1 -1
- package/dist/mdx/style-props/examples/Space.tsx +9 -3
- package/dist/mdx/welcome.mdx +48 -0
- package/index.ts +1 -0
- package/lib/ExampleCodeBlock.tsx +83 -0
- package/lib/MDXElements.tsx +2 -1
- package/lib/Value.tsx +5 -3
- package/package.json +9 -8
- package/dist/mdx/changelog.stories.mdx +0 -14
- package/dist/mdx/preview-react/_examples/SelectWithFormik.mdx +0 -8
- package/dist/mdx/preview-react/_examples/TextInputWithFormik.mdx +0 -8
- package/dist/mdx/preview-react/_examples/TextInputWithReactHookForm.mdx +0 -8
- package/dist/mdx/preview-react/form-field/FormField.mdx +0 -149
- package/dist/mdx/preview-react/form-field/examples/Alert.tsx +0 -24
- package/dist/mdx/preview-react/form-field/examples/Basic.tsx +0 -21
- package/dist/mdx/preview-react/form-field/examples/Error.tsx +0 -25
- package/dist/mdx/preview-react/form-field/examples/FieldSet.tsx +0 -29
- package/dist/mdx/preview-react/form-field/examples/Grow.tsx +0 -21
- package/dist/mdx/preview-react/form-field/examples/Hint.tsx +0 -25
- package/dist/mdx/preview-react/form-field/examples/LabelPositionHorizontal.tsx +0 -18
- package/dist/mdx/preview-react/form-field/examples/Required.tsx +0 -23
- package/dist/mdx/react/_examples/CookieBanner.mdx +0 -8
- package/dist/mdx/react/_examples/GlobalHeader.mdx +0 -12
- package/dist/mdx/react/_examples/PageHeader.mdx +0 -8
- package/dist/mdx/react/form-field/examples/AlertLabel.tsx +0 -23
- package/dist/mdx/react/form-field/examples/CustomInputId.tsx +0 -17
- package/dist/mdx/react/form-field/examples/ErrorLabel.tsx +0 -23
- package/dist/mdx/react/form-field/examples/GroupingInputs.tsx +0 -22
- package/dist/mdx/react/form-field/examples/LabelPosition.tsx +0 -17
- package/dist/mdx/welcome.stories.mdx +0 -35
- /package/dist/mdx/preview-react/_examples/{examples → mdx/examples}/TextInputWithFormik.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/AriaLiveRegions/IconButtonsWithLiveBadges.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/CookieBanner.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/GlobalHeader.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/MediaModal.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/PageHeader.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/SearchFormBasic.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/SegmentControlWithText.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/SidePanelWithOverlay.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/Table/WithSelectableRows.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/Table/WithSortableColumnHeaders.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/compoundComponent/CustomCard.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/AreaColumnPositioning.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/CustomColumnPositioning.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/CustomColumnWidth.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/FullWidthWith3Columns.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/FullWidthWith3Columns2Rows.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/Masonry.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/ResponsiveColumns.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/Tiled2and3Columns.tsx +0 -0
- /package/dist/mdx/react/_examples/{examples → mdx/examples}/layout/Tiled4and2Columns.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/Basic.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/BasicGrid.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/BasicVirtual.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/DataLoader.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/DynamicItemsObjects.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/DynamicItemsStrings.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/IdentifiedItems.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/MultiSelection.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/RovingFocus.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/Selection.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/StringChildren.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/Virtualization.tsx +0 -0
- /package/dist/mdx/react/collection/{examples → mdx/examples}/WrappingGrid.tsx +0 -0
- /package/dist/mdx/react/common/{examples → mdx/examples}/CreateComponent.tsx +0 -0
- /package/dist/mdx/react/common/{examples → mdx/examples}/CreateContainer.tsx +0 -0
- /package/dist/mdx/react/common/{examples → mdx/examples}/CreateElemPropsHook.tsx +0 -0
- /package/dist/mdx/react/common/{examples → mdx/examples}/CreateModelHook.tsx +0 -0
- /package/dist/mdx/react/common/{examples → mdx/examples}/CreateSubcomponent.tsx +0 -0
- /package/dist/mdx/react/common/{examples → mdx/examples}/ResponsiveViewport.tsx +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
3
|
import {mailIcon} from '@workday/canvas-system-icons-web';
|
|
4
|
-
import {FormField} from '@workday/canvas-kit-
|
|
4
|
+
import {FormField} from '@workday/canvas-kit-react/form-field';
|
|
5
5
|
import {InputGroup} from '@workday/canvas-kit-react/text-input';
|
|
6
6
|
import {SystemIcon} from '@workday/canvas-kit-react/icon';
|
|
7
7
|
|
|
@@ -9,7 +9,9 @@ export default () => {
|
|
|
9
9
|
return (
|
|
10
10
|
<FormField>
|
|
11
11
|
<FormField.Label>Email</FormField.Label>
|
|
12
|
-
<
|
|
12
|
+
<FormField.Field>
|
|
13
|
+
<InputGroupFormFieldForwarder />
|
|
14
|
+
</FormField.Field>
|
|
13
15
|
</FormField>
|
|
14
16
|
);
|
|
15
17
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {FormField} from '@workday/canvas-kit-
|
|
2
|
+
import {FormField} from '@workday/canvas-kit-react/form-field';
|
|
3
3
|
import {TextInput} from '@workday/canvas-kit-react/text-input';
|
|
4
4
|
|
|
5
5
|
export default () => {
|
|
@@ -10,9 +10,12 @@ export default () => {
|
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
return (
|
|
13
|
-
<FormField orientation="
|
|
13
|
+
<FormField orientation="horizontalStart">
|
|
14
14
|
<FormField.Label>Email</FormField.Label>
|
|
15
|
-
<FormField.
|
|
15
|
+
<FormField.Field>
|
|
16
|
+
<FormField.Input as={TextInput} onChange={handleChange} value={value} />
|
|
17
|
+
<FormField.Hint>Add a valid email</FormField.Hint>
|
|
18
|
+
</FormField.Field>
|
|
16
19
|
</FormField>
|
|
17
20
|
);
|
|
18
21
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {FormField} from '@workday/canvas-kit-
|
|
2
|
+
import {FormField} from '@workday/canvas-kit-react/form-field';
|
|
3
3
|
import {TextInput} from '@workday/canvas-kit-react/text-input';
|
|
4
4
|
|
|
5
5
|
export default () => {
|
|
@@ -12,12 +12,14 @@ export default () => {
|
|
|
12
12
|
return (
|
|
13
13
|
<FormField>
|
|
14
14
|
<FormField.Label>Email</FormField.Label>
|
|
15
|
-
<FormField.
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
15
|
+
<FormField.Field>
|
|
16
|
+
<FormField.Input
|
|
17
|
+
as={TextInput}
|
|
18
|
+
onChange={handleChange}
|
|
19
|
+
placeholder="user@email.com"
|
|
20
|
+
value={value}
|
|
21
|
+
/>
|
|
22
|
+
</FormField.Field>
|
|
21
23
|
</FormField>
|
|
22
24
|
);
|
|
23
25
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import {PrimaryButton} from '@workday/canvas-kit-react/button';
|
|
3
|
-
import {FormField} from '@workday/canvas-kit-
|
|
3
|
+
import {FormField} from '@workday/canvas-kit-react/form-field';
|
|
4
4
|
import {TextInput} from '@workday/canvas-kit-react/text-input';
|
|
5
5
|
|
|
6
6
|
export default () => {
|
|
@@ -19,7 +19,9 @@ export default () => {
|
|
|
19
19
|
<>
|
|
20
20
|
<FormField>
|
|
21
21
|
<FormField.Label>Email</FormField.Label>
|
|
22
|
-
<FormField.
|
|
22
|
+
<FormField.Field>
|
|
23
|
+
<FormField.Input as={TextInput} onChange={handleChange} ref={ref} value={value} />
|
|
24
|
+
</FormField.Field>
|
|
23
25
|
</FormField>
|
|
24
26
|
<PrimaryButton onClick={handleClick}>Focus Text Input</PrimaryButton>
|
|
25
27
|
</>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {FormField} from '@workday/canvas-kit-
|
|
2
|
+
import {FormField} from '@workday/canvas-kit-react/form-field';
|
|
3
3
|
import {TextInput} from '@workday/canvas-kit-react/text-input';
|
|
4
4
|
|
|
5
5
|
export default () => {
|
|
@@ -12,7 +12,9 @@ export default () => {
|
|
|
12
12
|
return (
|
|
13
13
|
<FormField isRequired={true}>
|
|
14
14
|
<FormField.Label>Email</FormField.Label>
|
|
15
|
-
<FormField.
|
|
15
|
+
<FormField.Field>
|
|
16
|
+
<FormField.Input as={TextInput} onChange={handleChange} value={value} />
|
|
17
|
+
</FormField.Field>
|
|
16
18
|
</FormField>
|
|
17
19
|
);
|
|
18
20
|
};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {SymbolDoc} from '@workday/canvas-kit-docs';
|
|
2
|
-
|
|
1
|
+
import {ExampleCodeBlock, SymbolDoc} from '@workday/canvas-kit-docs';
|
|
3
2
|
import {Toast} from '@workday/canvas-kit-react/toast';
|
|
4
3
|
import Basic from './examples/Basic';
|
|
5
4
|
import ToastAlert from './examples/ToastAlert';
|
|
@@ -8,7 +7,6 @@ import WithActionLinkAndCloseIcon from './examples/WithActionLinkAndCloseIcon';
|
|
|
8
7
|
import WithPopper from './examples/WithPopper';
|
|
9
8
|
import RTL from './examples/RTL';
|
|
10
9
|
|
|
11
|
-
|
|
12
10
|
# Canvas Kit Toast
|
|
13
11
|
|
|
14
12
|
`Toast` is a [compound component](/getting-started/for-developers/resources/compound-components/)
|
|
@@ -57,9 +55,10 @@ An `alert` `Toast` will wrap the message within an `assertive` ARIA live region
|
|
|
57
55
|
|
|
58
56
|
Set the `mode` prop to `dialog` to convey the presence of a follow-up action. If you use this
|
|
59
57
|
`mode`, you need to add an `aria-label`. This `aria-label` should be additional information for the
|
|
60
|
-
`Toast` such as `notification`. The `Toast` will also add an `aria-describedby` that links the
|
|
61
|
-
so that it is read out to screen readers. The `aria-label` should be
|
|
62
|
-
the `Toast` so there is no duplication being read out by screen
|
|
58
|
+
`Toast` such as `notification`. The `Toast` will also add an `aria-describedby` that links the
|
|
59
|
+
`Toast` to `Toast.Message` so that it is read out to screen readers. The `aria-label` should be
|
|
60
|
+
different that the contents of the `Toast` so there is no duplication being read out by screen
|
|
61
|
+
readers.
|
|
63
62
|
|
|
64
63
|
<ExampleCodeBlock code={ToastDialog} />
|
|
65
64
|
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {InformationHighlight} from '@workday/canvas-kit-docs';
|
|
2
|
-
import {BorderRadius, Space, Depth, Colors, Type} from './examples/Tokens';
|
|
1
|
+
import {ExampleCodeBlock, InformationHighlight} from '@workday/canvas-kit-docs';import {BorderRadius, Space, Depth, Colors, Type} from './examples/Tokens';
|
|
3
2
|
import Overview from './examples/Overview';
|
|
4
3
|
|
|
5
4
|
|
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
import {SymbolDoc, Specifications} from '@workday/canvas-kit-docs';
|
|
2
|
-
|
|
3
|
-
import {Tooltip} from '@workday/canvas-kit-react/tooltip';
|
|
4
|
-
|
|
5
|
-
import Default from './examples/Default';
|
|
1
|
+
import {ExampleCodeBlock, SymbolDoc, Specifications} from '@workday/canvas-kit-docs';import Default from './examples/Default';
|
|
6
2
|
import CustomContent from './examples/CustomContent';
|
|
7
3
|
import DelayedTooltip from './examples/DelayedTooltip';
|
|
8
4
|
import DescribeType from './examples/DescribeType';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {StylePropsTable} from '@workday/canvas-kit-docs';
|
|
2
|
-
|
|
1
|
+
import {ExampleCodeBlock, StylePropsTable} from '@workday/canvas-kit-docs';
|
|
2
|
+
|
|
3
3
|
import {
|
|
4
4
|
backgroundStyleFnConfigs,
|
|
5
5
|
borderStyleFnConfigs,
|
|
@@ -15,20 +15,20 @@ import {
|
|
|
15
15
|
spaceStyleFnConfigs,
|
|
16
16
|
textStyleFnConfigs,
|
|
17
17
|
} from '@workday/canvas-kit-react/layout';
|
|
18
|
-
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
18
|
+
|
|
19
|
+
import Background from './examples/Background';
|
|
20
|
+
import Border from './examples/Border';
|
|
21
|
+
import Color from './examples/Color';
|
|
22
|
+
import Depth from './examples/Depth';
|
|
23
23
|
import FlexExample from './examples/Flex';
|
|
24
|
-
import
|
|
24
|
+
import FlexItem from './examples/FlexItem';
|
|
25
25
|
import GridExample from './examples/Grid';
|
|
26
|
-
import
|
|
27
|
-
import
|
|
28
|
-
import
|
|
29
|
-
import
|
|
30
|
-
import
|
|
31
|
-
import
|
|
26
|
+
import GridItem from './examples/GridItem';
|
|
27
|
+
import Layout from './examples/Layout';
|
|
28
|
+
import Other from './examples/Other';
|
|
29
|
+
import Position from './examples/Position';
|
|
30
|
+
import Space from './examples/Space';
|
|
31
|
+
import Text from './examples/Text';
|
|
32
32
|
|
|
33
33
|
|
|
34
34
|
# Style Props
|
|
@@ -59,7 +59,7 @@ supported.
|
|
|
59
59
|
|
|
60
60
|
Background style props allow you to adjust the background styles of components.
|
|
61
61
|
|
|
62
|
-
<ExampleCodeBlock code={
|
|
62
|
+
<ExampleCodeBlock code={Background} />
|
|
63
63
|
|
|
64
64
|
<StylePropsTable styleProps={backgroundStyleFnConfigs} />
|
|
65
65
|
|
|
@@ -67,7 +67,7 @@ Background style props allow you to adjust the background styles of components.
|
|
|
67
67
|
|
|
68
68
|
Border style props allow you to adjust the border styles of components.
|
|
69
69
|
|
|
70
|
-
<ExampleCodeBlock code={
|
|
70
|
+
<ExampleCodeBlock code={Border} />
|
|
71
71
|
|
|
72
72
|
<StylePropsTable styleProps={borderStyleFnConfigs} />
|
|
73
73
|
|
|
@@ -75,7 +75,7 @@ Border style props allow you to adjust the border styles of components.
|
|
|
75
75
|
|
|
76
76
|
Color style props allow you to adjust the color styles of components.
|
|
77
77
|
|
|
78
|
-
<ExampleCodeBlock code={
|
|
78
|
+
<ExampleCodeBlock code={Color} />
|
|
79
79
|
|
|
80
80
|
<StylePropsTable styleProps={colorStyleFnConfigs} />
|
|
81
81
|
|
|
@@ -83,7 +83,7 @@ Color style props allow you to adjust the color styles of components.
|
|
|
83
83
|
|
|
84
84
|
Depth style props allow you to adjust the depth styles of components.
|
|
85
85
|
|
|
86
|
-
<ExampleCodeBlock code={
|
|
86
|
+
<ExampleCodeBlock code={Depth} />
|
|
87
87
|
|
|
88
88
|
<StylePropsTable styleProps={depthStyleFnConfigs} />
|
|
89
89
|
|
|
@@ -99,7 +99,7 @@ Flex style props allow you to adjust the flex styles of components.
|
|
|
99
99
|
|
|
100
100
|
Flex item style props allow you to adjust the flex item styles of components.
|
|
101
101
|
|
|
102
|
-
<ExampleCodeBlock code={
|
|
102
|
+
<ExampleCodeBlock code={FlexItem} />
|
|
103
103
|
|
|
104
104
|
<StylePropsTable styleProps={flexItemStyleFnConfigs} />
|
|
105
105
|
|
|
@@ -115,7 +115,7 @@ Grid style props allow you to adjust the grid styles of components.
|
|
|
115
115
|
|
|
116
116
|
Grid item style props allow you to adjust the grid item styles of components.
|
|
117
117
|
|
|
118
|
-
<ExampleCodeBlock code={
|
|
118
|
+
<ExampleCodeBlock code={GridItem} />
|
|
119
119
|
|
|
120
120
|
<StylePropsTable styleProps={gridItemStyleFnConfigs} />
|
|
121
121
|
|
|
@@ -123,7 +123,7 @@ Grid item style props allow you to adjust the grid item styles of components.
|
|
|
123
123
|
|
|
124
124
|
Layout style props allow you to adjust the layout styles of components.
|
|
125
125
|
|
|
126
|
-
<ExampleCodeBlock code={
|
|
126
|
+
<ExampleCodeBlock code={Layout} />
|
|
127
127
|
|
|
128
128
|
<StylePropsTable styleProps={layoutStyleFnConfigs} />
|
|
129
129
|
|
|
@@ -131,7 +131,7 @@ Layout style props allow you to adjust the layout styles of components.
|
|
|
131
131
|
|
|
132
132
|
Other style props allow you to adjust the other, miscellaneous styles of components.
|
|
133
133
|
|
|
134
|
-
<ExampleCodeBlock code={
|
|
134
|
+
<ExampleCodeBlock code={Other} />
|
|
135
135
|
|
|
136
136
|
<StylePropsTable styleProps={otherStyleFnConfigs} />
|
|
137
137
|
|
|
@@ -139,7 +139,7 @@ Other style props allow you to adjust the other, miscellaneous styles of compone
|
|
|
139
139
|
|
|
140
140
|
Position style props allow you to adjust the position styles of components.
|
|
141
141
|
|
|
142
|
-
<ExampleCodeBlock code={
|
|
142
|
+
<ExampleCodeBlock code={Position} />
|
|
143
143
|
|
|
144
144
|
<StylePropsTable styleProps={positionStyleFnConfigs} />
|
|
145
145
|
|
|
@@ -147,7 +147,7 @@ Position style props allow you to adjust the position styles of components.
|
|
|
147
147
|
|
|
148
148
|
Space style props allow you to adjust the space styles of components.
|
|
149
149
|
|
|
150
|
-
<ExampleCodeBlock code={
|
|
150
|
+
<ExampleCodeBlock code={Space} />
|
|
151
151
|
|
|
152
152
|
<StylePropsTable styleProps={spaceStyleFnConfigs} />
|
|
153
153
|
|
|
@@ -155,6 +155,6 @@ Space style props allow you to adjust the space styles of components.
|
|
|
155
155
|
|
|
156
156
|
Text style props allow you to adjust the text styles of components.
|
|
157
157
|
|
|
158
|
-
<ExampleCodeBlock code={
|
|
158
|
+
<ExampleCodeBlock code={Text} />
|
|
159
159
|
|
|
160
160
|
<StylePropsTable styleProps={textStyleFnConfigs} />
|
|
@@ -10,25 +10,18 @@ const baseStyles = {
|
|
|
10
10
|
padding: 'xs',
|
|
11
11
|
};
|
|
12
12
|
|
|
13
|
-
export default () =>
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
backgroundColor="blueberry300"
|
|
29
|
-
{...baseStyles}
|
|
30
|
-
>
|
|
31
|
-
Blueberry 300
|
|
32
|
-
</Box>
|
|
33
|
-
</>
|
|
34
|
-
);
|
|
13
|
+
export default () => {
|
|
14
|
+
return (
|
|
15
|
+
<>
|
|
16
|
+
<Box backgroundColor="cinnamon300" {...baseStyles}>
|
|
17
|
+
Cinnamon 300
|
|
18
|
+
</Box>
|
|
19
|
+
<Box backgroundColor="sourLemon300" {...baseStyles}>
|
|
20
|
+
Sour Lemon 300
|
|
21
|
+
</Box>
|
|
22
|
+
<Box backgroundColor="blueberry300" {...baseStyles}>
|
|
23
|
+
Blueberry 300
|
|
24
|
+
</Box>
|
|
25
|
+
</>
|
|
26
|
+
);
|
|
27
|
+
};
|
|
@@ -12,28 +12,13 @@ const baseStyles = {
|
|
|
12
12
|
|
|
13
13
|
export default () => (
|
|
14
14
|
<>
|
|
15
|
-
<Box
|
|
16
|
-
borderRadius="m"
|
|
17
|
-
border="solid 4px"
|
|
18
|
-
borderColor="cinnamon300"
|
|
19
|
-
{...baseStyles}
|
|
20
|
-
>
|
|
15
|
+
<Box borderRadius="m" border="solid 4px" borderColor="cinnamon300" {...baseStyles}>
|
|
21
16
|
Cinnamon 300
|
|
22
17
|
</Box>
|
|
23
|
-
<Box
|
|
24
|
-
borderRadius="m"
|
|
25
|
-
border="solid 4px"
|
|
26
|
-
borderColor="sourLemon300"
|
|
27
|
-
{...baseStyles}
|
|
28
|
-
>
|
|
18
|
+
<Box borderRadius="m" border="solid 4px" borderColor="sourLemon300" {...baseStyles}>
|
|
29
19
|
Sour Lemon 300
|
|
30
20
|
</Box>
|
|
31
|
-
<Box
|
|
32
|
-
borderRadius="m"
|
|
33
|
-
border="solid 4px"
|
|
34
|
-
borderColor="blueberry300"
|
|
35
|
-
{...baseStyles}
|
|
36
|
-
>
|
|
21
|
+
<Box borderRadius="m" border="solid 4px" borderColor="blueberry300" {...baseStyles}>
|
|
37
22
|
Blueberry 300
|
|
38
23
|
</Box>
|
|
39
24
|
</>
|
|
@@ -11,26 +11,14 @@ const baseStyles = {
|
|
|
11
11
|
|
|
12
12
|
export default () => (
|
|
13
13
|
<>
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
{...baseStyles}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
color="blackPepper500"
|
|
24
|
-
{...baseStyles}
|
|
25
|
-
>
|
|
26
|
-
Sour Lemon 300
|
|
27
|
-
</Box>
|
|
28
|
-
<Box
|
|
29
|
-
backgroundColor="blueberry300"
|
|
30
|
-
color="blackPepper500"
|
|
31
|
-
{...baseStyles}
|
|
32
|
-
>
|
|
33
|
-
Blueberry 300
|
|
34
|
-
</Box>
|
|
14
|
+
<Box backgroundColor="cinnamon300" color="blackPepper500" {...baseStyles}>
|
|
15
|
+
Cinnamon 300
|
|
16
|
+
</Box>
|
|
17
|
+
<Box backgroundColor="sourLemon300" color="blackPepper500" {...baseStyles}>
|
|
18
|
+
Sour Lemon 300
|
|
19
|
+
</Box>
|
|
20
|
+
<Box backgroundColor="blueberry300" color="blackPepper500" {...baseStyles}>
|
|
21
|
+
Blueberry 300
|
|
22
|
+
</Box>
|
|
35
23
|
</>
|
|
36
24
|
);
|
|
@@ -11,19 +11,37 @@ const baseStyles = {
|
|
|
11
11
|
export default () => (
|
|
12
12
|
<Flex columnGap="xs">
|
|
13
13
|
<Flex flexDirection="column" rowGap="xs" flex={1}>
|
|
14
|
-
<Flex.Item backgroundColor="cinnamon300" textAlign="center" {...baseStyles}>
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
<Flex.Item backgroundColor="cinnamon300" textAlign="center" {...baseStyles}>
|
|
15
|
+
1
|
|
16
|
+
</Flex.Item>
|
|
17
|
+
<Flex.Item backgroundColor="sourLemon300" textAlign="center" {...baseStyles}>
|
|
18
|
+
1
|
|
19
|
+
</Flex.Item>
|
|
20
|
+
<Flex.Item backgroundColor="blueberry300" textAlign="center" {...baseStyles}>
|
|
21
|
+
1
|
|
22
|
+
</Flex.Item>
|
|
17
23
|
</Flex>
|
|
18
24
|
<Flex flexDirection="column" rowGap="xs" flex={2}>
|
|
19
|
-
<Flex.Item backgroundColor="cinnamon300" textAlign="center" {...baseStyles}>
|
|
20
|
-
|
|
21
|
-
|
|
25
|
+
<Flex.Item backgroundColor="cinnamon300" textAlign="center" {...baseStyles}>
|
|
26
|
+
2
|
|
27
|
+
</Flex.Item>
|
|
28
|
+
<Flex.Item backgroundColor="sourLemon300" textAlign="center" {...baseStyles}>
|
|
29
|
+
2
|
|
30
|
+
</Flex.Item>
|
|
31
|
+
<Flex.Item backgroundColor="blueberry300" textAlign="center" {...baseStyles}>
|
|
32
|
+
2
|
|
33
|
+
</Flex.Item>
|
|
22
34
|
</Flex>
|
|
23
35
|
<Flex flexDirection="column" rowGap="xs" flex={1}>
|
|
24
|
-
<Flex.Item backgroundColor="cinnamon300" textAlign="center" {...baseStyles}>
|
|
25
|
-
|
|
26
|
-
|
|
36
|
+
<Flex.Item backgroundColor="cinnamon300" textAlign="center" {...baseStyles}>
|
|
37
|
+
1
|
|
38
|
+
</Flex.Item>
|
|
39
|
+
<Flex.Item backgroundColor="sourLemon300" textAlign="center" {...baseStyles}>
|
|
40
|
+
1
|
|
41
|
+
</Flex.Item>
|
|
42
|
+
<Flex.Item backgroundColor="blueberry300" textAlign="center" {...baseStyles}>
|
|
43
|
+
1
|
|
44
|
+
</Flex.Item>
|
|
27
45
|
</Flex>
|
|
28
46
|
</Flex>
|
|
29
47
|
);
|
|
@@ -11,18 +11,34 @@ const baseStyles = {
|
|
|
11
11
|
export default () => (
|
|
12
12
|
<Flex flexDirection="column" rowGap="xs">
|
|
13
13
|
<Flex columnGap="xs">
|
|
14
|
-
<Flex.Item backgroundColor="cinnamon300" flex={1} textAlign="center" {...baseStyles}>
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
<Flex.Item backgroundColor="cinnamon300" flex={1} textAlign="center" {...baseStyles}>
|
|
15
|
+
1
|
|
16
|
+
</Flex.Item>
|
|
17
|
+
<Flex.Item backgroundColor="sourLemon300" flex={2} textAlign="center" {...baseStyles}>
|
|
18
|
+
2
|
|
19
|
+
</Flex.Item>
|
|
20
|
+
<Flex.Item backgroundColor="blueberry300" flex={1} textAlign="center" {...baseStyles}>
|
|
21
|
+
1
|
|
22
|
+
</Flex.Item>
|
|
17
23
|
</Flex>
|
|
18
24
|
<Flex columnGap="xs">
|
|
19
|
-
<Flex.Item backgroundColor="cinnamon300" flex={2} textAlign="center" {...baseStyles}>
|
|
20
|
-
|
|
21
|
-
|
|
25
|
+
<Flex.Item backgroundColor="cinnamon300" flex={2} textAlign="center" {...baseStyles}>
|
|
26
|
+
2
|
|
27
|
+
</Flex.Item>
|
|
28
|
+
<Flex.Item backgroundColor="sourLemon300" flex={1} textAlign="center" {...baseStyles}>
|
|
29
|
+
1
|
|
30
|
+
</Flex.Item>
|
|
31
|
+
<Flex.Item backgroundColor="blueberry300" flex={2} textAlign="center" {...baseStyles}>
|
|
32
|
+
2
|
|
33
|
+
</Flex.Item>
|
|
22
34
|
</Flex>
|
|
23
35
|
<Flex columnGap="xs">
|
|
24
|
-
<Flex.Item backgroundColor="cinnamon300" flex={1} textAlign="center" {...baseStyles}>
|
|
25
|
-
|
|
36
|
+
<Flex.Item backgroundColor="cinnamon300" flex={1} textAlign="center" {...baseStyles}>
|
|
37
|
+
1
|
|
38
|
+
</Flex.Item>
|
|
39
|
+
<Flex.Item backgroundColor="blueberry300" flex={1} textAlign="center" {...baseStyles}>
|
|
40
|
+
1
|
|
41
|
+
</Flex.Item>
|
|
26
42
|
</Flex>
|
|
27
43
|
</Flex>
|
|
28
44
|
);
|
|
@@ -11,13 +11,19 @@ const baseStyles = {
|
|
|
11
11
|
export default () => (
|
|
12
12
|
<>
|
|
13
13
|
<Box backgroundColor="cinnamon300" margin="xxs" padding="s" textAlign="center" {...baseStyles}>
|
|
14
|
-
<Box border="dotted 2px" borderColor="blackPepper500">
|
|
14
|
+
<Box border="dotted 2px" borderColor="blackPepper500">
|
|
15
|
+
Small
|
|
16
|
+
</Box>
|
|
15
17
|
</Box>
|
|
16
18
|
<Box backgroundColor="sourLemon300" margin="xxs" padding="m" textAlign="center" {...baseStyles}>
|
|
17
|
-
<Box border="dotted 2px" borderColor="blackPepper500">
|
|
19
|
+
<Box border="dotted 2px" borderColor="blackPepper500">
|
|
20
|
+
Medium
|
|
21
|
+
</Box>
|
|
18
22
|
</Box>
|
|
19
23
|
<Box backgroundColor="blueberry300" margin="xxs" padding="l" textAlign="center" {...baseStyles}>
|
|
20
|
-
<Box border="dotted 2px" borderColor="blackPepper500">
|
|
24
|
+
<Box border="dotted 2px" borderColor="blackPepper500">
|
|
25
|
+
Large
|
|
26
|
+
</Box>
|
|
21
27
|
</Box>
|
|
22
28
|
</>
|
|
23
29
|
);
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import Readme from '../../../README.md';
|
|
2
|
+
import Markdown from '../../../utils/storybook/Markdown.tsx';
|
|
3
|
+
import {WelcomePage} from './welcomePage';
|
|
4
|
+
import {InstallBlock} from './installBlock';
|
|
5
|
+
import {version} from '../../../lerna.json';
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
<WelcomePage />
|
|
9
|
+
|
|
10
|
+
### Canvas Provider
|
|
11
|
+
|
|
12
|
+
The `<CanvasProvider>` is required for proper branding support. Furthermore, if you use Emotion for
|
|
13
|
+
styling your components, the `<CanvasProvider>` ensures your styles will merge as expected. Note:
|
|
14
|
+
Custom use of `<CacheProvider>` provided by Emotion is not supported. `@workday/canvas-kit-styling`
|
|
15
|
+
owns the creating of the cache reference. This ensures both static styling and Emotion’s dynamic
|
|
16
|
+
styling solutions work together. In most cases you'll want to wrap your application at the root
|
|
17
|
+
level in `<CanvasProvider>`.
|
|
18
|
+
|
|
19
|
+
```tsx
|
|
20
|
+
import * as React from 'react';
|
|
21
|
+
import {
|
|
22
|
+
CanvasProvider,
|
|
23
|
+
ContentDirection,
|
|
24
|
+
PartialEmotionCanvasTheme,
|
|
25
|
+
useTheme,
|
|
26
|
+
} from '@workday/canvas-kit-react/common';
|
|
27
|
+
// Ensure CSS variables are defined. You Can also do this at the root index.css
|
|
28
|
+
import '@workday/canvas-tokens-web/css/base/_variables.css';
|
|
29
|
+
import '@workday/canvas-tokens-web/css/brand/_variables.css';
|
|
30
|
+
import '@workday/canvas-tokens-web/css/system/_variables.css';
|
|
31
|
+
|
|
32
|
+
export const App = () => {
|
|
33
|
+
// useTheme is filling in the Canvas theme object if any keys are missing
|
|
34
|
+
const canvasTheme: PartialEmotionCanvasTheme = useTheme({
|
|
35
|
+
canvas: {
|
|
36
|
+
// Switch to `ContentDirection.RTL` to change direction
|
|
37
|
+
direction: ContentDirection.LTR,
|
|
38
|
+
},
|
|
39
|
+
});
|
|
40
|
+
return (
|
|
41
|
+
<CanvasProvider theme={canvasTheme}>
|
|
42
|
+
<main>
|
|
43
|
+
<p>Get Started With Canvas Kit</p>
|
|
44
|
+
</main>
|
|
45
|
+
</CanvasProvider>
|
|
46
|
+
);
|
|
47
|
+
};
|
|
48
|
+
```
|
package/index.ts
CHANGED