@innovaccer/design-system 2.5.0 → 2.7.0-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/.eslintrc.json +54 -0
- package/.github/workflows/chromatic.yml +5 -0
- package/.github/workflows/main.yml +2 -2
- package/.github/workflows/pull_request.yml +2 -2
- package/.github/workflows/test.yml +1 -1
- package/.husky/commit-msg +4 -0
- package/.prettierrc +2 -2
- package/.storybook/main.js +4 -0
- package/.vscode/settings.json +11 -0
- package/CHANGELOG.md +78 -0
- package/CONTRIBUTING.md +180 -98
- package/commitlint.config.js +1 -0
- package/core/accessibility/utils/index.ts +5 -0
- package/core/accessibility/utils/isEnterKey.ts +5 -0
- package/core/accessibility/utils/isSpaceKey.ts +5 -0
- package/core/accessibility/utils/useAccessibilityProps.ts +33 -0
- package/core/common.type.tsx +22 -0
- package/core/components/atoms/_chip/__tests__/__snapshots__/_chip.test.tsx.snap +17 -9
- package/core/components/atoms/_chip/index.tsx +19 -3
- package/core/components/atoms/avatar/Avatar.tsx +4 -14
- package/core/components/atoms/avatar/__stories__/variants/Appearance.story.tsx +3 -2
- package/core/components/atoms/avatar/__tests__/Avatar.test.tsx +14 -9
- package/core/components/atoms/avatarGroup/AvatarGroup.tsx +3 -5
- package/core/components/atoms/badge/Badge.tsx +2 -12
- package/core/components/atoms/badge/__tests__/Badge.test.tsx +22 -7
- package/core/components/atoms/badge/_stories_/variants/Appearance.story.tsx +3 -2
- package/core/components/atoms/badge/_stories_/variants/Subtle.story.tsx +3 -2
- package/core/components/atoms/button/Button.tsx +10 -7
- package/core/components/atoms/button/__stories__/Alert.story.tsx +8 -1
- package/core/components/atoms/button/__stories__/Cancel.story.tsx +4 -1
- package/core/components/atoms/button/__stories__/IconButtonGroup.story.tsx +12 -3
- package/core/components/atoms/button/__stories__/IconButtonSecondary.story.tsx +6 -1
- package/core/components/atoms/button/__stories__/IconLeftSecondary.story.tsx +4 -1
- package/core/components/atoms/button/__stories__/IconRightSecondary.story.tsx +4 -1
- package/core/components/atoms/button/__stories__/IconTransparent.story.tsx +4 -1
- package/core/components/atoms/button/__stories__/LabelButtonGroup.story.tsx +14 -3
- package/core/components/atoms/button/__stories__/LargeIconExpanded.story.tsx +4 -1
- package/core/components/atoms/button/__stories__/LoadingPrimary.story.tsx +4 -1
- package/core/components/atoms/button/__stories__/Primary.story.tsx +5 -2
- package/core/components/atoms/button/__stories__/SplitButton.story.tsx +6 -1
- package/core/components/atoms/button/__stories__/Transparent.story.tsx +8 -1
- package/core/components/atoms/button/__stories__/index.story.tsx +12 -2
- package/core/components/atoms/button/__stories__/variants/Appearance.story.tsx +6 -2
- package/core/components/atoms/button/__stories__/variants/Expanded.story.tsx +6 -2
- package/core/components/atoms/button/__stories__/variants/Size.story.tsx +4 -0
- package/core/components/atoms/button/__stories__/variants/icon/Icon.story.tsx +15 -0
- package/core/components/atoms/button/__stories__/variants/icon/IconLeft.story.tsx +6 -2
- package/core/components/atoms/button/__stories__/variants/icon/IconRight.story.tsx +6 -2
- package/core/components/atoms/button/__stories__/variants/state/Alert.story.tsx +7 -17
- package/core/components/atoms/button/__stories__/variants/state/Basic.story.tsx +9 -17
- package/core/components/atoms/button/__stories__/variants/state/Primary.story.tsx +7 -17
- package/core/components/atoms/button/__stories__/variants/state/Transparent.story.tsx +13 -17
- package/core/components/atoms/button/__tests__/Button.test.tsx +1 -1
- package/core/components/atoms/button/__tests__/__snapshots__/Button.test.tsx.snap +0 -137
- package/core/components/atoms/card/__stories__/empty.story.tsx +1 -1
- package/core/components/atoms/card/__stories__/nested.story.tsx +1 -1
- package/core/components/atoms/card/__stories__/scroll.story.tsx +1 -1
- package/core/components/atoms/checkbox/Checkbox.tsx +8 -9
- package/core/components/atoms/checkbox/__stories__/variants/Size.story.tsx +2 -2
- package/core/components/atoms/chip/Chip.tsx +3 -2
- package/core/components/atoms/chip/__stories__/variants/Selection.story.tsx +17 -0
- package/core/components/atoms/chip/__stories__/variants/Type.story.tsx +2 -2
- package/core/components/atoms/chip/__tests__/Chip.test.tsx +7 -0
- package/core/components/atoms/chipGroup/__tests__/__snapshots__/chipGroup.test.tsx.snap +11 -5
- package/core/components/atoms/chipGroup/__tests__/chipGroup.test.tsx +2 -2
- package/core/components/atoms/chipGroup/_stories_/index.story.tsx +2 -2
- package/core/components/atoms/collapsible/__tests__/__snapshots__/Collapsible.test.tsx.snap +8 -0
- package/core/components/atoms/divider/Divider.tsx +44 -0
- package/core/components/atoms/divider/__stories__/BasicDividerInCard.story.tsx +74 -0
- package/core/components/atoms/divider/__stories__/HeaderDividerInCard.story.tsx +35 -0
- package/core/components/atoms/divider/__stories__/IndentedDivider.story.tsx +49 -0
- package/core/components/atoms/divider/__stories__/Vertical.story.tsx +51 -0
- package/core/components/atoms/divider/__stories__/index.story.tsx +91 -0
- package/core/components/atoms/divider/__stories__/variants/HorizontalDivider.story.tsx +27 -0
- package/core/components/atoms/divider/__tests__/Divider.test.tsx +50 -0
- package/core/components/atoms/divider/__tests__/__snapshots__/Divider.test.tsx.snap +53 -0
- package/core/components/atoms/divider/index.tsx +2 -0
- package/core/components/atoms/dropdown/Dropdown.tsx +18 -17
- package/core/components/atoms/dropdown/DropdownButton.tsx +2 -2
- package/core/components/atoms/dropdown/DropdownList.tsx +18 -7
- package/core/components/atoms/dropdown/Loading.tsx +1 -1
- package/core/components/atoms/dropdown/__stories__/CustomSearchPlaceholder.story.tsx +45 -0
- package/core/components/atoms/dropdown/__stories__/_common_/types.tsx +3 -0
- package/core/components/atoms/dropdown/__stories__/variants/Size.story.tsx +2 -2
- package/core/components/atoms/dropdown/__stories__/variants/controlledDropdown/MultiSelect.story.tsx +28 -18
- package/core/components/atoms/dropdown/__tests__/Dropdown.test.tsx +12 -1
- package/core/components/atoms/dropdown/__tests__/Loading.test.tsx +0 -1
- package/core/components/atoms/dropdown/option/DefaultOption.tsx +3 -0
- package/core/components/atoms/dropdown/option/IconOption.tsx +3 -0
- package/core/components/atoms/dropdown/option/IconWithMetaOption.tsx +3 -0
- package/core/components/atoms/dropdown/option/MetaOption.tsx +3 -0
- package/core/components/atoms/dropdown/option/index.tsx +1 -1
- package/core/components/atoms/editable/Editable.tsx +3 -0
- package/core/components/atoms/heading/Heading.tsx +4 -4
- package/core/components/atoms/heading/__stories__/variants/Appearance.story.tsx +3 -2
- package/core/components/atoms/heading/__tests__/Heading.test.tsx +4 -3
- package/core/components/atoms/icon/Icon.tsx +16 -5
- package/core/components/atoms/icon/__stories__/variants/Image.story.tsx +6 -1
- package/core/components/atoms/icon/__tests__/__snapshots__/Icon.test.tsx.snap +74 -0
- package/core/components/atoms/input/Input.tsx +17 -7
- package/core/components/atoms/input/__stories__/BasicInput.story.tsx +2 -1
- package/core/components/atoms/input/__stories__/InputWithCaption.story.tsx +91 -9
- package/core/components/atoms/input/__stories__/InputWithLabel.story.tsx +11 -3
- package/core/components/atoms/input/__stories__/LabelPosition.story.tsx +46 -4
- package/core/components/atoms/input/__stories__/RequiredVsOptional.story.tsx +12 -8
- package/core/components/atoms/input/__stories__/variants/controlledInput.story.tsx +46 -0
- package/core/components/atoms/input/__stories__/variants/types/BasicInput.story.tsx +2 -2
- package/core/components/atoms/input/__stories__/variants/types/IconLeft.story.tsx +2 -10
- package/core/components/atoms/input/__stories__/variants/types/WithLabel.story.tsx +1 -9
- package/core/components/atoms/input/__tests__/__snapshots__/Input.test.tsx.snap +19 -0
- package/core/components/atoms/label/Label.tsx +1 -1
- package/core/components/atoms/legend/Legend.tsx +5 -2
- package/core/components/atoms/legend/__stories__/variants/labelAppearance.story.tsx +2 -2
- package/core/components/atoms/link/Link.tsx +4 -4
- package/core/components/atoms/message/Message.tsx +12 -12
- package/core/components/atoms/message/__stories__/index.story.tsx +1 -1
- package/core/components/atoms/message/__stories__/variants/Appearance.story.tsx +1 -1
- package/core/components/atoms/message/__stories__/variants/AppearanceTitle.story.tsx +1 -1
- package/core/components/atoms/message/__tests__/Message.test.tsx +1 -6
- package/core/components/atoms/message/__tests__/__snapshots__/Message.test.tsx.snap +0 -45
- package/core/components/atoms/metaList/__tests__/MetaList.test.tsx +2 -2
- package/core/components/atoms/metricInput/MetricInput.tsx +17 -7
- package/core/components/atoms/metricInput/__stories__/DefaultMetric.story.tsx +8 -2
- package/core/components/atoms/metricInput/__stories__/WithPrefix.story.tsx +6 -2
- package/core/components/atoms/metricInput/__stories__/index.story.tsx +1 -0
- package/core/components/atoms/metricInput/__stories__/variants/Controlled.story.tsx +2 -0
- package/core/components/atoms/metricInput/__stories__/variants/Size.story.tsx +2 -2
- package/core/components/atoms/metricInput/__stories__/withSuffix.story.tsx +6 -2
- package/core/components/atoms/metricInput/__tests__/__snapshots__/MetricInput.test.tsx.snap +20 -4
- package/core/components/atoms/multiSlider/Handle.tsx +3 -0
- package/core/components/atoms/multiSlider/SliderUtils.tsx +1 -4
- package/core/components/atoms/multiSlider/index.tsx +9 -4
- package/core/components/atoms/outsideClick/OutsideClick.tsx +1 -2
- package/core/components/atoms/paragraph/Paragraph.tsx +2 -2
- package/core/components/atoms/paragraph/__stories__/variants/Appearance.story.tsx +2 -2
- package/core/components/atoms/paragraph/__tests__/Paragraph.test.tsx +2 -2
- package/core/components/atoms/pills/Pills.tsx +2 -12
- package/core/components/atoms/pills/__stories__/variants/Appearance.story.tsx +3 -2
- package/core/components/atoms/pills/__stories__/variants/Subtle.story.tsx +3 -2
- package/core/components/atoms/pills/__tests__/Pills.test.tsx +3 -2
- package/core/components/atoms/placeholderImage/PlaceholderImage.tsx +2 -2
- package/core/components/atoms/placeholderImage/__stories__/variants/Size.story.tsx +2 -2
- package/core/components/atoms/placeholderParagraph/PlaceholderParagraph.tsx +2 -2
- package/core/components/atoms/placeholderParagraph/__stories__/variants/Size.story.tsx +2 -2
- package/core/components/atoms/popperWrapper/PopperWrapper.tsx +2 -6
- package/core/components/atoms/progressRing/ProgressRing.tsx +2 -2
- package/core/components/atoms/progressRing/__stories__/variants/Size.story.tsx +1 -1
- package/core/components/atoms/radio/Radio.tsx +4 -5
- package/core/components/atoms/rangeSlider/RangeSlider.tsx +1 -2
- package/core/components/atoms/rangeSlider/__stories__/index.story.tsx +1 -2
- package/core/components/atoms/rangeSlider/__stories__/variants/Controlled.story.tsx +1 -2
- package/core/components/atoms/rangeSlider/__stories__/variants/CustomLabels.story.tsx +1 -2
- package/core/components/atoms/spinner/Spinner.tsx +4 -4
- package/core/components/atoms/spinner/__stories__/variants/Appearance.story.tsx +2 -2
- package/core/components/atoms/spinner/__stories__/variants/Size.story.tsx +1 -1
- package/core/components/atoms/statusHint/StatusHint.tsx +5 -3
- package/core/components/atoms/statusHint/__stories__/variants/Appearance.story.tsx +3 -2
- package/core/components/atoms/statusHint/__tests__/StatusHint.test.tsx +3 -2
- package/core/components/atoms/subheading/Subheading.tsx +2 -2
- package/core/components/atoms/subheading/__stories__/variants/Appearance.story.tsx +3 -2
- package/core/components/atoms/subheading/__tests__/Subheading.test.tsx +3 -2
- package/core/components/atoms/switchInput/Switch.tsx +14 -9
- package/core/components/atoms/switchInput/__stories__/DefaultSwitch.story.tsx +4 -1
- package/core/components/atoms/switchInput/__stories__/OffState.story.tsx +4 -1
- package/core/components/atoms/switchInput/__stories__/index.story.tsx +26 -3
- package/core/components/atoms/switchInput/__stories__/variants/Size.story.tsx +10 -1
- package/core/components/atoms/switchInput/__stories__/variants/State.story.tsx +9 -2
- package/core/components/atoms/text/Text.tsx +4 -4
- package/core/components/atoms/text/__stories__/variants/Appearance.story.tsx +2 -2
- package/core/components/atoms/text/__tests__/Text.test.tsx +2 -3
- package/core/components/atoms/textarea/__stories__/TextareaWithCaption.story.tsx +9 -3
- package/core/components/atoms/textarea/__stories__/defaultTextarea.story.tsx +10 -2
- package/core/components/atoms/textarea/__stories__/index.story.tsx +1 -0
- package/core/components/atoms/textarea/__stories__/variants/Disable.story.tsx +1 -0
- package/core/components/atoms/toast/ActionButton.tsx +2 -2
- package/core/components/atoms/toast/Toast.tsx +11 -6
- package/core/components/atoms/toast/__stories__/index.story.tsx +2 -6
- package/core/components/atoms/toast/__stories__/variants/Appearance.story.tsx +3 -2
- package/core/components/atoms/toast/__stories__/variants/ToastMessage.story.tsx +3 -2
- package/core/components/atoms/toast/__stories__/variants/ToastWithAction.story.tsx +3 -2
- package/core/components/atoms/toast/__tests__/Toast.test.tsx +1 -1
- package/core/components/atoms/toast/__tests__/__snapshots__/Toast.test.tsx.snap +24 -125
- package/core/components/css-utilities/Schema.tsx +1 -1
- package/core/components/css-utilities/Spacing/Schema.tsx +1 -1
- package/core/components/molecules/chatMessage/Box.tsx +3 -0
- package/core/components/molecules/chipInput/ChipInput.tsx +3 -0
- package/core/components/molecules/chipInput/__tests__/__snapshots__/ChipInput.test.tsx.snap +14 -2
- package/core/components/molecules/dropzone/Dropzone.tsx +6 -3
- package/core/components/molecules/dropzone/DropzoneBase.tsx +22 -38
- package/core/components/molecules/dropzone/FileSelectorUtils.tsx +1 -1
- package/core/components/molecules/dropzone/__stories__/index.story.tsx +151 -41
- package/core/components/molecules/dropzone/__tests__/Dropzone.test.tsx +2 -2
- package/core/components/molecules/dropzone/utils.tsx +6 -4
- package/core/components/molecules/editableChipInput/EditableChipInput.tsx +9 -5
- package/core/components/molecules/editableChipInput/__stories__/Uncontrolled.story.tsx +1 -1
- package/core/components/molecules/editableChipInput/__tests__/__snapshots__/EditableChipInput.test.tsx.snap +12 -4
- package/core/components/molecules/editableDropdown/EditableDropdown.tsx +2 -2
- package/core/components/molecules/editableInput/EditableInput.tsx +13 -4
- package/core/components/molecules/emptyState/EmptyState.tsx +9 -5
- package/core/components/molecules/emptyState/__stories__/pageNotLoadedWithSVG.story.tsx +26 -26
- package/core/components/molecules/fileList/FileListItem.tsx +3 -2
- package/core/components/molecules/fileUploader/FileUploaderItem.tsx +3 -2
- package/core/components/molecules/fileUploader/FileUploaderStatus.tsx +1 -1
- package/core/components/molecules/fileUploader/__stories__/_common_/types.tsx +3 -0
- package/core/components/molecules/fileUploader/__stories__/index.story.tsx +3 -222
- package/core/components/molecules/fullscreenModal/FullscreenModal.tsx +5 -7
- package/core/components/molecules/inputMask/InputMask.tsx +212 -146
- package/core/components/molecules/inputMask/__stories__/index.story.tsx +24 -0
- package/core/components/molecules/inputMask/__tests__/__snapshots__/InputMask.test.tsx.snap +1 -0
- package/core/components/molecules/modal/Modal.tsx +4 -6
- package/core/components/molecules/modal/__stories__/Confirmation.story.tsx +1 -1
- package/core/components/molecules/pagination/__tests__/__snapshots__/Pagination.test.tsx.snap +5 -1
- package/core/components/molecules/placeholder/Placeholder.tsx +2 -2
- package/core/components/molecules/popover/Popover.tsx +2 -9
- package/core/components/molecules/sidesheet/Sidesheet.tsx +5 -7
- package/core/components/molecules/sidesheet/__stories__/variants/CustomHeader.story.tsx +172 -0
- package/core/components/molecules/stepper/Step.tsx +2 -0
- package/core/components/molecules/tabs/Tabs.tsx +2 -0
- package/core/components/molecules/tabs/TabsWrapper.tsx +2 -0
- package/core/components/molecules/tabs/__stories__/CustomLabels.story.tsx +1 -1
- package/core/components/molecules/tooltip/Tooltip.tsx +4 -4
- package/core/components/molecules/verificationCodeInput/VerificationCodeInput.tsx +8 -4
- package/core/components/molecules/verificationCodeInput/__stories__/index.story.tsx +3 -1
- package/core/components/molecules/verificationCodeInput/__tests__/__snapshots__/VerificationCodeInput.test.tsx.snap +1 -0
- package/core/components/organisms/calendar/Calendar.tsx +130 -8
- package/core/components/organisms/calendar/__stories__/variants/firstDayOfWeek.story.tsx +2 -2
- package/core/components/organisms/calendar/__tests__/Calendar.test.tsx +27 -0
- package/core/components/organisms/calendar/utility.ts +3 -3
- package/core/components/organisms/choiceList/ChoiceList.tsx +12 -12
- package/core/components/organisms/datePicker/DatePicker.tsx +31 -16
- package/core/components/organisms/datePicker/Trigger.tsx +1 -5
- package/core/components/organisms/datePicker/__tests__/__snapshots__/DatePicker.test.tsx.snap +4518 -4479
- package/core/components/organisms/dateRangePicker/DateRangePicker.tsx +9 -10
- package/core/components/organisms/dateRangePicker/SingleInputTrigger.tsx +0 -1
- package/core/components/organisms/dateRangePicker/Trigger.tsx +2 -2
- package/core/components/organisms/dateRangePicker/__stories__/variants/monthsInView.story.tsx +2 -2
- package/core/components/organisms/dateRangePicker/__tests__/__snapshots__/DateRangePicker.test.tsx.snap +112 -40
- package/core/components/organisms/grid/Cell.tsx +23 -19
- package/core/components/organisms/grid/Grid.tsx +3 -4
- package/core/components/organisms/grid/GridBody.tsx +0 -1
- package/core/components/organisms/grid/GridContext.ts +1 -1
- package/core/components/organisms/grid/GridRow.tsx +4 -0
- package/core/components/organisms/grid/__stories__/_common_/editableSchema.tsx +1 -3
- package/core/components/organisms/grid/__stories__/_common_/fetchData.ts +3 -3
- package/core/components/organisms/grid/__stories__/_common_/loaderSchema.ts +0 -2
- package/core/components/organisms/grid/__stories__/_common_/schema.tsx +1 -3
- package/core/components/organisms/grid/__stories__/_common_/simpleLoaderSchema.ts +0 -2
- package/core/components/organisms/grid/__stories__/_common_/statusSchema.ts +0 -2
- package/core/components/organisms/horizontalNav/HorizontalNav.tsx +2 -0
- package/core/components/organisms/inlineMessage/InlineMessage.tsx +5 -7
- package/core/components/organisms/inlineMessage/__tests__/InlineMessage.test.tsx +3 -2
- package/core/components/organisms/inlineMessage/__tests__/__snapshots__/InlineMessage.test.tsx.snap +30 -40
- package/core/components/organisms/list/__stories__/_common_/types.tsx +3 -0
- package/core/components/organisms/list/__stories__/index.story.tsx +0 -16
- package/core/components/organisms/navigation/VerticalNavigation.tsx +4 -0
- package/core/components/organisms/table/Table.tsx +3 -2
- package/core/components/organisms/table/__stories__/CompressedTable.story.tsx +1 -1
- package/core/components/organisms/table/__stories__/DataTable.story.tsx +1 -1
- package/core/components/organisms/table/__stories__/NestedTableWithNestedCard.story.tsx +1 -1
- package/core/components/organisms/table/__stories__/PinnedColumn.story.tsx +1 -1
- package/core/components/organisms/table/__stories__/ResourceTable.story.tsx +4 -3
- package/core/components/organisms/table/__stories__/Selection.story.tsx +2 -2
- package/core/components/organisms/table/__stories__/StandardTable.story.tsx +1 -1
- package/core/components/organisms/table/__stories__/TableAsDescriptionList.story.tsx +2 -2
- package/core/components/organisms/table/__stories__/TableAsOptionList.story.tsx +2 -2
- package/core/components/organisms/table/__stories__/TightStory.story.tsx +1 -1
- package/core/components/organisms/table/__stories__/_common_/types.tsx +3 -0
- package/core/components/organisms/table/__stories__/syncTable.story.tsx +14 -6
- package/core/components/organisms/table/__stories__/variants/showHead.story.tsx +2 -2
- package/core/components/organisms/table/__stories__/variants/showMenu.story.tsx +2 -2
- package/core/components/organisms/table/__stories__/variants/size.story.tsx +2 -2
- package/core/components/organisms/table/__stories__/variants/type.story.tsx +2 -2
- package/core/components/organisms/table/__stories__/variants/withCheckbox.story.tsx +2 -2
- package/core/components/organisms/table/__stories__/variants/withHeader.story.tsx +0 -2
- package/core/components/organisms/table/__stories__/variants/withPagination.story.tsx +2 -2
- package/core/components/organisms/timePicker/TimePicker.tsx +4 -8
- package/core/components/organisms/timePicker/__tests__/__snapshots__/TimePicker.test.tsx.snap +14 -2
- package/core/components/organisms/verticalNav/MenuItem.tsx +2 -0
- package/core/components/organisms/verticalNav/__stories__/schema.tsx +0 -2
- package/core/components/organisms/verticalNav/__tests__/VerticalNav.test.tsx +1 -2
- package/core/components/patterns/datePicker/datePickerWithPresets.story.tsx +126 -0
- package/core/components/patterns/dateRangePicker/withCustomPopover.story.tsx +8 -8
- package/core/components/patterns/forms/CreatePassword.story.tsx +1 -1
- package/core/components/patterns/forms/VerificationCodeInput.story.tsx +2 -2
- package/core/components/patterns/table/Table with Header/tableWithHeader.story.jsx +7 -7
- package/core/global.d.ts +9 -0
- package/core/index.tsx +2 -1
- package/core/index.type.tsx +1 -0
- package/core/utils/Keys.ts +4 -0
- package/core/utils/__tests__/__snapshots__/TS.test.tsx.snap +562 -541
- package/core/utils/docPage/generateImports.tsx +2 -3
- package/core/utils/docPage/index.tsx +52 -37
- package/core/utils/docPage/sandbox.tsx +14 -7
- package/core/utils/overlayHelper.ts +7 -3
- package/core/utils/testHelper.ts +2 -2
- package/core/utils/types.tsx +1 -1
- package/core/utils/validators.ts +37 -34
- package/css/dist/index.css +1550 -1415
- package/css/dist/index.css.map +1 -1
- package/css/src/components/Legend.css +7 -7
- package/css/src/components/ProgressBar.css +1 -1
- package/css/src/components/avatarGroup.css +1 -1
- package/css/src/components/backdrop.css +12 -6
- package/css/src/components/badge.css +52 -52
- package/css/src/components/button.css +95 -94
- package/css/src/components/calendar.css +137 -126
- package/css/src/components/card.css +0 -1
- package/css/src/components/cardSubdued.css +3 -5
- package/css/src/components/chat.css +1 -1
- package/css/src/components/checkbox.css +71 -70
- package/css/src/components/chip.css +20 -17
- package/css/src/components/chipGroup.css +5 -5
- package/css/src/components/chipInput.css +1 -1
- package/css/src/components/choiceList.css +4 -4
- package/css/src/components/dateRangePicker.css +13 -13
- package/css/src/components/divider.css +20 -0
- package/css/src/components/dropdown.css +61 -61
- package/css/src/components/dropdownButton.css +36 -36
- package/css/src/components/dropzone.css +16 -20
- package/css/src/components/editableChipInput.css +10 -9
- package/css/src/components/editableDropdown.css +1 -1
- package/css/src/components/editableInput.css +1 -1
- package/css/src/components/emptyState.css +15 -15
- package/css/src/components/fileList.css +44 -45
- package/css/src/components/fullscreenModal.css +4 -3
- package/css/src/components/grid.css +217 -199
- package/css/src/components/horizontalNav.css +0 -1
- package/css/src/components/icon.css +1 -7
- package/css/src/components/inlineMessage.css +2 -1
- package/css/src/components/input.css +62 -62
- package/css/src/components/link.css +1 -1
- package/css/src/components/list.css +10 -10
- package/css/src/components/message.css +64 -70
- package/css/src/components/metaList.css +26 -26
- package/css/src/components/metricInput.css +3 -4
- package/css/src/components/modal.css +1 -1
- package/css/src/components/navigation.css +3 -3
- package/css/src/components/pageHeader.css +1 -2
- package/css/src/components/pagination.css +36 -36
- package/css/src/components/pills.css +19 -19
- package/css/src/components/placeholder.css +10 -5
- package/css/src/components/popover.css +2 -2
- package/css/src/components/progressRing.css +1 -1
- package/css/src/components/radio.css +74 -74
- package/css/src/components/slider.css +5 -5
- package/css/src/components/statusHints.css +15 -15
- package/css/src/components/switch.css +66 -41
- package/css/src/components/table.css +15 -15
- package/css/src/components/tabs.css +53 -53
- package/css/src/components/textarea.css +1 -1
- package/css/src/components/toast.css +51 -56
- package/css/src/components/verificationCodeInput.css +5 -6
- package/css/src/components/verticalNav.css +1 -2
- package/css/src/core/base.css +3 -0
- package/css/src/core/typography.css +1 -1
- package/css/src/core/utilities.css +1 -1
- package/css/src/tokens/index.css +63 -63
- package/css/src/utils/align.css +1 -1
- package/css/src/utils/background.css +1 -1
- package/css/src/utils/cursor.css +1 -1
- package/css/src/utils/display.css +1 -1
- package/css/src/utils/flex.css +1 -1
- package/css/src/utils/grid.css +1 -1
- package/css/src/utils/overflow.css +1 -1
- package/css/src/utils/position.css +1 -1
- package/css/src/utils/spacing.css +1 -1
- package/css/src/utils/utility.css +13 -13
- package/css/src/variables/index.css +6 -3
- package/dist/core/accessibility/utils/index.d.ts +4 -0
- package/dist/core/accessibility/utils/isEnterKey.d.ts +3 -0
- package/dist/core/accessibility/utils/isSpaceKey.d.ts +3 -0
- package/dist/core/accessibility/utils/useAccessibilityProps.d.ts +18 -0
- package/dist/core/common.type.d.ts +12 -0
- package/dist/core/components/atoms/avatar/Avatar.d.ts +4 -4
- package/dist/core/components/atoms/avatarGroup/AvatarGroup.d.ts +2 -3
- package/dist/core/components/atoms/badge/Badge.d.ts +2 -2
- package/dist/core/components/atoms/button/Button.d.ts +6 -6
- package/dist/core/components/atoms/checkbox/Checkbox.d.ts +3 -3
- package/dist/core/components/atoms/chip/Chip.d.ts +2 -2
- package/dist/core/components/atoms/divider/Divider.d.ts +15 -0
- package/dist/core/components/atoms/divider/index.d.ts +2 -0
- package/dist/core/components/atoms/dropdown/Dropdown.d.ts +18 -17
- package/dist/core/components/atoms/dropdown/DropdownButton.d.ts +2 -2
- package/dist/core/components/atoms/dropdown/DropdownList.d.ts +4 -3
- package/dist/core/components/atoms/dropdown/option/index.d.ts +1 -1
- package/dist/core/components/atoms/heading/Heading.d.ts +4 -4
- package/dist/core/components/atoms/icon/Icon.d.ts +5 -3
- package/dist/core/components/atoms/input/Input.d.ts +4 -4
- package/dist/core/components/atoms/legend/Legend.d.ts +2 -2
- package/dist/core/components/atoms/link/Link.d.ts +4 -4
- package/dist/core/components/atoms/message/Message.d.ts +2 -2
- package/dist/core/components/atoms/metricInput/MetricInput.d.ts +3 -3
- package/dist/core/components/atoms/multiSlider/SliderUtils.d.ts +1 -1
- package/dist/core/components/atoms/multiSlider/index.d.ts +3 -3
- package/dist/core/components/atoms/paragraph/Paragraph.d.ts +2 -2
- package/dist/core/components/atoms/pills/Pills.d.ts +2 -2
- package/dist/core/components/atoms/placeholderImage/PlaceholderImage.d.ts +2 -2
- package/dist/core/components/atoms/placeholderParagraph/PlaceholderParagraph.d.ts +2 -2
- package/dist/core/components/atoms/popperWrapper/PopperWrapper.d.ts +51 -51
- package/dist/core/components/atoms/progressRing/ProgressRing.d.ts +2 -2
- package/dist/core/components/atoms/radio/Radio.d.ts +4 -4
- package/dist/core/components/atoms/rangeSlider/RangeSlider.d.ts +1 -1
- package/dist/core/components/atoms/spinner/Spinner.d.ts +4 -4
- package/dist/core/components/atoms/statusHint/StatusHint.d.ts +2 -2
- package/dist/core/components/atoms/subheading/Subheading.d.ts +2 -2
- package/dist/core/components/atoms/switchInput/Switch.d.ts +7 -6
- package/dist/core/components/atoms/text/Text.d.ts +4 -4
- package/dist/core/components/atoms/toast/ActionButton.d.ts +2 -2
- package/dist/core/components/atoms/toast/Toast.d.ts +2 -2
- package/dist/core/components/molecules/dropzone/Dropzone.d.ts +3 -3
- package/dist/core/components/molecules/dropzone/DropzoneBase.d.ts +1 -1
- package/dist/core/components/molecules/dropzone/utils.d.ts +5 -3
- package/dist/core/components/molecules/emptyState/EmptyState.d.ts +4 -4
- package/dist/core/components/molecules/fileList/FileListItem.d.ts +1 -1
- package/dist/core/components/molecules/fileUploader/FileUploaderItem.d.ts +1 -1
- package/dist/core/components/molecules/fileUploader/FileUploaderStatus.d.ts +1 -1
- package/dist/core/components/molecules/fullscreenModal/FullscreenModal.d.ts +4 -7
- package/dist/core/components/molecules/inputMask/InputMask.d.ts +10 -2
- package/dist/core/components/molecules/modal/Modal.d.ts +3 -6
- package/dist/core/components/molecules/placeholder/Placeholder.d.ts +2 -2
- package/dist/core/components/molecules/popover/Popover.d.ts +0 -1
- package/dist/core/components/molecules/sidesheet/Sidesheet.d.ts +3 -6
- package/dist/core/components/molecules/tooltip/Tooltip.d.ts +3 -3
- package/dist/core/components/organisms/calendar/Calendar.d.ts +31 -0
- package/dist/core/components/organisms/choiceList/ChoiceList.d.ts +5 -6
- package/dist/core/components/organisms/datePicker/DatePicker.d.ts +2 -0
- package/dist/core/components/organisms/dateRangePicker/DateRangePicker.d.ts +24 -0
- package/dist/core/components/organisms/grid/Cell.d.ts +1 -1
- package/dist/core/components/organisms/grid/Grid.d.ts +3 -3
- package/dist/core/components/organisms/grid/GridContext.d.ts +1 -1
- package/dist/core/components/organisms/inlineMessage/InlineMessage.d.ts +2 -2
- package/dist/core/components/organisms/table/Table.d.ts +2 -2
- package/dist/core/components/patterns/datePicker/datePickerWithPresets.story.d.ts +15 -0
- package/dist/core/components/patterns/dateRangePicker/withCustomPopover.story.d.ts +5 -1
- package/dist/core/index.d.ts +1 -0
- package/dist/core/index.type.d.ts +1 -0
- package/dist/core/utils/docPage/generateImports.d.ts +1 -1
- package/dist/core/utils/overlayHelper.d.ts +1 -1
- package/dist/core/utils/types.d.ts +1 -1
- package/dist/index.esm.js +1039 -729
- package/dist/index.js +532 -371
- package/dist/index.js.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.br +0 -0
- package/dist/index.umd.js.gz +0 -0
- package/dts.config.js +11 -2
- package/package.json +32 -27
- package/tsconfig.json +3 -16
- package/tsconfig.type.json +2 -1
- package/types/index.d.ts +2217 -0
- package/types/{innovaccer-design-system/tsconfig.json → tsconfig.json} +1 -1
- package/types/{innovaccer-design-system/tslint.json → tslint.json} +0 -0
- package/types/types-tests.tsx +936 -0
- package/.husky/prepare-commit-msg +0 -6
- package/core/components/atoms/button/__stories__/variants/state/Success.story.tsx +0 -99
- package/core/components/atoms/message/__stories__/default.story.tsx +0 -16
- package/core/components/atoms/toast/__stories__/DefaultToast.story.tsx +0 -16
- package/core/components/molecules/dropzone/__stories__/variants/DropzoneWithFileList.story.tsx +0 -176
- package/core/components/molecules/fileUploader/__stories__/variants/FileUploaderList.story.tsx +0 -80
- package/tslint.json +0 -30
- package/types/innovaccer-design-system/index.d.ts +0 -39
- package/types/innovaccer-design-system/innovaccer-design-system-tests.ts +0 -0
|
@@ -0,0 +1,936 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import {
|
|
3
|
+
Avatar,
|
|
4
|
+
AvatarGroup,
|
|
5
|
+
Backdrop,
|
|
6
|
+
Badge,
|
|
7
|
+
Breadcrumbs,
|
|
8
|
+
Button,
|
|
9
|
+
Calendar,
|
|
10
|
+
Caption,
|
|
11
|
+
Card,
|
|
12
|
+
CardSubdued,
|
|
13
|
+
CardHeader,
|
|
14
|
+
CardBody,
|
|
15
|
+
CardFooter,
|
|
16
|
+
Chip,
|
|
17
|
+
Checkbox,
|
|
18
|
+
Column,
|
|
19
|
+
DatePicker,
|
|
20
|
+
Dropdown,
|
|
21
|
+
EditableDropdown,
|
|
22
|
+
TimePicker,
|
|
23
|
+
MultiSlider,
|
|
24
|
+
Heading,
|
|
25
|
+
Icon,
|
|
26
|
+
Input,
|
|
27
|
+
InputMask,
|
|
28
|
+
Label,
|
|
29
|
+
Link,
|
|
30
|
+
Legend,
|
|
31
|
+
MetaList,
|
|
32
|
+
MetricInput,
|
|
33
|
+
Message,
|
|
34
|
+
Paragraph,
|
|
35
|
+
Radio,
|
|
36
|
+
Row,
|
|
37
|
+
Text,
|
|
38
|
+
OutsideClick,
|
|
39
|
+
ProgressBar,
|
|
40
|
+
StatusHint,
|
|
41
|
+
Pills,
|
|
42
|
+
Spinner,
|
|
43
|
+
Slider,
|
|
44
|
+
RangeSlider,
|
|
45
|
+
Subheading,
|
|
46
|
+
Switch,
|
|
47
|
+
Textarea,
|
|
48
|
+
Toast,
|
|
49
|
+
Popover,
|
|
50
|
+
ChipInput,
|
|
51
|
+
VerticalNav,
|
|
52
|
+
HorizontalNav,
|
|
53
|
+
Tooltip,
|
|
54
|
+
Dialog,
|
|
55
|
+
Modal,
|
|
56
|
+
ModalHeader,
|
|
57
|
+
ModalFooter,
|
|
58
|
+
ModalBody,
|
|
59
|
+
ModalDescription,
|
|
60
|
+
FullscreenModal,
|
|
61
|
+
Sidesheet,
|
|
62
|
+
Collapsible,
|
|
63
|
+
ChatMessage,
|
|
64
|
+
EmptyState,
|
|
65
|
+
Pagination,
|
|
66
|
+
PlaceholderParagraph,
|
|
67
|
+
Placeholder,
|
|
68
|
+
EditableInput,
|
|
69
|
+
ProgressRing,
|
|
70
|
+
Stepper,
|
|
71
|
+
DateRangePicker,
|
|
72
|
+
TabsWrapper,
|
|
73
|
+
Tab,
|
|
74
|
+
Dropzone,
|
|
75
|
+
FileUploader,
|
|
76
|
+
FileUploaderList,
|
|
77
|
+
Grid,
|
|
78
|
+
GridCell,
|
|
79
|
+
Table,
|
|
80
|
+
List,
|
|
81
|
+
InlineMessage,
|
|
82
|
+
ChoiceList,
|
|
83
|
+
} from './index';
|
|
84
|
+
|
|
85
|
+
// $ExpectType Element
|
|
86
|
+
<Avatar className="mr-5" firstName="firstName" lastName="lastName" />;
|
|
87
|
+
|
|
88
|
+
// $ExpectError Property 'age' does not exist on type
|
|
89
|
+
<Avatar className="mr-5" firstName="firstName" lastName="lastName" age="d" />;
|
|
90
|
+
|
|
91
|
+
// $ExpectType Element
|
|
92
|
+
<AvatarGroup
|
|
93
|
+
list={[
|
|
94
|
+
{
|
|
95
|
+
firstName: 'John',
|
|
96
|
+
lastName: 'Doe',
|
|
97
|
+
},
|
|
98
|
+
]}
|
|
99
|
+
max={1}
|
|
100
|
+
popoverOptions={{ on: 'click', dark: false }}
|
|
101
|
+
/>;
|
|
102
|
+
|
|
103
|
+
// $ExpectType Element
|
|
104
|
+
<Backdrop className="BackdropClass" open={false} zIndex={1000} />;
|
|
105
|
+
|
|
106
|
+
// $ExpectType Element
|
|
107
|
+
<Badge appearance="alert" subtle={false}>
|
|
108
|
+
{'Failed'}
|
|
109
|
+
</Badge>;
|
|
110
|
+
|
|
111
|
+
// $ExpectError Type 'string' is not assignable to type 'boolean | undefined'.
|
|
112
|
+
<Badge appearance="alert" subtle={''}>
|
|
113
|
+
{'Failed'}
|
|
114
|
+
</Badge>;
|
|
115
|
+
|
|
116
|
+
// $ExpectType Element
|
|
117
|
+
<Breadcrumbs list={[]} onClick={() => console.log('')} className="My-custom-style" />;
|
|
118
|
+
|
|
119
|
+
// $ExpectError Type '{}' is missing the following properties from type 'Breadcrumb': label, link
|
|
120
|
+
<Breadcrumbs list={[{}]} className="My-custom-style" />;
|
|
121
|
+
|
|
122
|
+
// $ExpectType Element
|
|
123
|
+
<Button appearance="primary" icon="get_app" iconAlign="left" size="regular" className="mr-2">
|
|
124
|
+
Download
|
|
125
|
+
</Button>;
|
|
126
|
+
|
|
127
|
+
// $ExpectError Type '"small"' is not assignable to type '"regular" | "tiny" | "large" | undefined'.
|
|
128
|
+
<Button appearance="primary" icon="get_app" iconAlign="left" size="small" className="mr-2">
|
|
129
|
+
Download
|
|
130
|
+
</Button>;
|
|
131
|
+
|
|
132
|
+
// $ExpectType Element
|
|
133
|
+
<Calendar
|
|
134
|
+
date={new Date(2020, 2, 15)}
|
|
135
|
+
disabledBefore={new Date(2020, 2, 10)}
|
|
136
|
+
disabledAfter={new Date(2021, 2, 20)}
|
|
137
|
+
size={'large'}
|
|
138
|
+
view="year"
|
|
139
|
+
events={{ '09/12/2021': true }}
|
|
140
|
+
onDateChange={() => {}}
|
|
141
|
+
rangePicker={true}
|
|
142
|
+
jumpView={true}
|
|
143
|
+
/>;
|
|
144
|
+
|
|
145
|
+
<Calendar
|
|
146
|
+
// $ExpectError Type 'string' is not assignable to type 'Date | undefined'.
|
|
147
|
+
date={''}
|
|
148
|
+
disabledBefore={new Date(2020, 2, 10)}
|
|
149
|
+
size={'large'}
|
|
150
|
+
view="year"
|
|
151
|
+
events={{ '09/12/2021': true }}
|
|
152
|
+
onDateChange={() => {}}
|
|
153
|
+
/>;
|
|
154
|
+
|
|
155
|
+
// $ExpectType Element
|
|
156
|
+
<Card shadow="none" className="w-50" style={{ height: '250px' }}>
|
|
157
|
+
<CardHeader className="CardHeaderClass">
|
|
158
|
+
<Heading size="s" appearance={'disabled'} className="mb-7">
|
|
159
|
+
Daily progress
|
|
160
|
+
</Heading>
|
|
161
|
+
</CardHeader>
|
|
162
|
+
<CardBody className="CardBodyClass">
|
|
163
|
+
<Paragraph>campaign starts</Paragraph>
|
|
164
|
+
<Row>
|
|
165
|
+
<Column size="12" className="pt-4">
|
|
166
|
+
<Radio label="Send now" name="gender" value="Checkbox" defaultChecked={true} />
|
|
167
|
+
<Text weight="strong" small={true} appearance="disabled" className="ml-7">
|
|
168
|
+
Campaign will start immediately
|
|
169
|
+
</Text>
|
|
170
|
+
</Column>
|
|
171
|
+
<Column size="12" className="py-4" sizeXS={'12'} sizeXL="4" sizeM="4">
|
|
172
|
+
<Radio label="Schedule for later" name="gender" value="Checkbox" />
|
|
173
|
+
<Text small={true} appearance="disabled" className="ml-7">
|
|
174
|
+
Campaign will not start immediately
|
|
175
|
+
</Text>
|
|
176
|
+
</Column>
|
|
177
|
+
</Row>
|
|
178
|
+
</CardBody>
|
|
179
|
+
<CardSubdued border="top" className="ml-7">
|
|
180
|
+
Subdued section.
|
|
181
|
+
</CardSubdued>
|
|
182
|
+
<CardFooter withSeperator={false} className="justify-content-end">
|
|
183
|
+
<Button appearance="primary" className="ml-4">
|
|
184
|
+
Submit
|
|
185
|
+
</Button>
|
|
186
|
+
</CardFooter>
|
|
187
|
+
</Card>;
|
|
188
|
+
|
|
189
|
+
// $ExpectError Type '"red"' is not assignable to type '"dark" | "default" | "none" | "light" | "medium" | undefined'.
|
|
190
|
+
<Card shadow="red" className="w-50" style={{ height: '250px' }}>
|
|
191
|
+
<div className="p-8" />
|
|
192
|
+
</Card>;
|
|
193
|
+
|
|
194
|
+
// $ExpectError Type 'string' is not assignable to type 'boolean | undefined'.
|
|
195
|
+
<CardFooter withSeperator={''} className="justify-content-end">
|
|
196
|
+
Card footer
|
|
197
|
+
</CardFooter>;
|
|
198
|
+
|
|
199
|
+
// $ExpectType Element
|
|
200
|
+
<Chip
|
|
201
|
+
icon="icon"
|
|
202
|
+
label="First Name"
|
|
203
|
+
clearButton={false}
|
|
204
|
+
disabled={false}
|
|
205
|
+
type="action"
|
|
206
|
+
name={'chip'}
|
|
207
|
+
onClick={() => {}}
|
|
208
|
+
onClose={() => {}}
|
|
209
|
+
selected={false}
|
|
210
|
+
/>;
|
|
211
|
+
|
|
212
|
+
<Chip
|
|
213
|
+
icon="icon"
|
|
214
|
+
label="First Name"
|
|
215
|
+
clearButton={false}
|
|
216
|
+
disabled={false}
|
|
217
|
+
type="action"
|
|
218
|
+
// $ExpectError Type 'null' is not assignable to type 'ReactText'.
|
|
219
|
+
name={null}
|
|
220
|
+
onClick={() => {}}
|
|
221
|
+
onClose={() => {}}
|
|
222
|
+
selected={false}
|
|
223
|
+
/>;
|
|
224
|
+
|
|
225
|
+
// $ExpectType Element
|
|
226
|
+
<Checkbox
|
|
227
|
+
defaultChecked={true}
|
|
228
|
+
helpText={'help text'}
|
|
229
|
+
indeterminate={true}
|
|
230
|
+
label="Innovaccer"
|
|
231
|
+
value="Innovaccer"
|
|
232
|
+
className="mt-5"
|
|
233
|
+
onChange={() => {}}
|
|
234
|
+
/>;
|
|
235
|
+
|
|
236
|
+
// $ExpectError Type 'number' is not assignable to type 'string | undefined'.
|
|
237
|
+
<Checkbox helpText={1} indeterminate={true} label="Innovaccer" value="Innovaccer" onChange={() => {}} />;
|
|
238
|
+
|
|
239
|
+
// $ExpectError Type '"20"' is not assignable to type '1 | 8 | 2 | 10 | "auto" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12" | 3 | 4 | 5 | 6 | 7 | 9 | 11 | 12 | undefined'.
|
|
240
|
+
<Column size="20" className="py-4" sizeXS={'12'} sizeXL="4" sizeM="4"></Column>;
|
|
241
|
+
|
|
242
|
+
// $ExpectType Element
|
|
243
|
+
<DatePicker
|
|
244
|
+
date={new Date(2020, 2, 1)}
|
|
245
|
+
view="date"
|
|
246
|
+
withInput={true}
|
|
247
|
+
closeOnSelect={true}
|
|
248
|
+
inputFormat="dd/mm/yyyy"
|
|
249
|
+
outputFormat="dd/mm/yyyy"
|
|
250
|
+
jumpView={true}
|
|
251
|
+
onDateChange={() => console.log('date')}
|
|
252
|
+
firstDayOfWeek="monday"
|
|
253
|
+
inputOptions={{
|
|
254
|
+
required: true,
|
|
255
|
+
}}
|
|
256
|
+
/>;
|
|
257
|
+
|
|
258
|
+
// $ExpectError Type '""' is not assignable to type '"dd/mm/yyyy" | "mm/dd/yyyy" | "yyyy/mm/dd" | "mm-dd-yyyy" | "dd-mm-yyyy" | "yyyy-mm-dd" | undefined'.
|
|
259
|
+
<DatePicker date={new Date(2020, 2, 1)} outputFormat="" />;
|
|
260
|
+
|
|
261
|
+
// $ExpectType Element
|
|
262
|
+
<TimePicker
|
|
263
|
+
inputFormat="hh:mm AM"
|
|
264
|
+
outputFormat="hh:mm AM"
|
|
265
|
+
onTimeChange={() => {}}
|
|
266
|
+
time="3:30 AM"
|
|
267
|
+
inputOptions={{
|
|
268
|
+
placeholderChar: '*',
|
|
269
|
+
}}
|
|
270
|
+
/>;
|
|
271
|
+
|
|
272
|
+
// $ExpectType Element
|
|
273
|
+
<Dropdown
|
|
274
|
+
menu={true}
|
|
275
|
+
icon="expand_more"
|
|
276
|
+
options={[
|
|
277
|
+
{
|
|
278
|
+
label: 'Download All',
|
|
279
|
+
value: 'Download All',
|
|
280
|
+
},
|
|
281
|
+
]}
|
|
282
|
+
withCheckbox={true}
|
|
283
|
+
className="w-25"
|
|
284
|
+
placeholder="Select"
|
|
285
|
+
optionType="WITH_ICON"
|
|
286
|
+
staticLimit={100}
|
|
287
|
+
inlineLabel="Status"
|
|
288
|
+
maxWidth={130}
|
|
289
|
+
align="right"
|
|
290
|
+
withSearch={true}
|
|
291
|
+
onChange={() => {}}
|
|
292
|
+
onClose={() => {}}
|
|
293
|
+
loading={true}
|
|
294
|
+
/>;
|
|
295
|
+
|
|
296
|
+
// $ExpectError JSX attributes must only be assigned a non-empty 'expression'.
|
|
297
|
+
<Dropdown menu={} icon="expand_more" loading={true} />;
|
|
298
|
+
|
|
299
|
+
// $ExpectType Element
|
|
300
|
+
<Icon className="mr-5" name="events" appearance="subtle" onClick={() => {}} size={24} />;
|
|
301
|
+
|
|
302
|
+
// $ExpectType Element
|
|
303
|
+
<Input
|
|
304
|
+
name="input"
|
|
305
|
+
className="mb-4"
|
|
306
|
+
placeholder="Enter password"
|
|
307
|
+
type={'password'}
|
|
308
|
+
value={'value'}
|
|
309
|
+
onChange={() => {}}
|
|
310
|
+
onClear={() => {}}
|
|
311
|
+
disabled={true}
|
|
312
|
+
/>;
|
|
313
|
+
|
|
314
|
+
// $ExpectError Type '"submit"' is not assignable to type '"number" | "text" | "password" | "email" | "tel" | "url" | undefined'.
|
|
315
|
+
<Input name="input" className="mb-4" placeholder="Enter password" type={'submit'} />;
|
|
316
|
+
|
|
317
|
+
// $ExpectType Element
|
|
318
|
+
<MetricInput
|
|
319
|
+
size="regular"
|
|
320
|
+
value="val"
|
|
321
|
+
onChange={() => {}}
|
|
322
|
+
name="input"
|
|
323
|
+
disabled={false}
|
|
324
|
+
readOnly={false}
|
|
325
|
+
onClick={() => {}}
|
|
326
|
+
placeholder="placeholder"
|
|
327
|
+
prefix="#"
|
|
328
|
+
suffix="$"
|
|
329
|
+
icon="icon"
|
|
330
|
+
error={false}
|
|
331
|
+
/>;
|
|
332
|
+
|
|
333
|
+
// $ExpectError Type 'null' is not assignable to type 'string | undefined'.
|
|
334
|
+
<MetricInput name="input" className="mb-4" placeholder="Enter password" type={'submit'} prefix={null} />;
|
|
335
|
+
|
|
336
|
+
// $ExpectType Element
|
|
337
|
+
<InputMask
|
|
338
|
+
name="input"
|
|
339
|
+
type="text"
|
|
340
|
+
value="value"
|
|
341
|
+
defaultValue="defaultValue"
|
|
342
|
+
disabled={false}
|
|
343
|
+
onChange={() => {}}
|
|
344
|
+
placeholder="placeholder"
|
|
345
|
+
inlineLabel="inlineLabel"
|
|
346
|
+
size="tiny"
|
|
347
|
+
icon="icon"
|
|
348
|
+
required={true}
|
|
349
|
+
error={false}
|
|
350
|
+
caption="caption"
|
|
351
|
+
info="info"
|
|
352
|
+
mask={[/\d/, /\d/, /\d/, /\d/, ' ', /\d/, /\d/, /\d/, /\d/, ' ', /\d/, /\d/, /\d/, /\d/, ' ', /\d/, /\d/, /\d/, /\d/]}
|
|
353
|
+
/>;
|
|
354
|
+
|
|
355
|
+
// $ExpectError Type 'string' is not assignable to type 'Mask'.
|
|
356
|
+
<InputMask name="input" className="mb-4" placeholder="Enter password" mask="" />;
|
|
357
|
+
|
|
358
|
+
// $ExpectType Element
|
|
359
|
+
<Label required={true} className="mt-6" withInput={true}>
|
|
360
|
+
Gender
|
|
361
|
+
</Label>;
|
|
362
|
+
|
|
363
|
+
// $ExpectType Element
|
|
364
|
+
<Caption error={false} withInput={true} className={'FileItem-error'}>
|
|
365
|
+
With Error
|
|
366
|
+
</Caption>;
|
|
367
|
+
|
|
368
|
+
// $ExpectType Element
|
|
369
|
+
<Legend iconAppearance="secondary" labelAppearance="destructive">
|
|
370
|
+
Legend
|
|
371
|
+
</Legend>;
|
|
372
|
+
|
|
373
|
+
// $ExpectError Type '"none"' is not assignable to type '"link" | "subtle" | "success" | "default" | "disabled" | "destructive" | "white" | undefined'.
|
|
374
|
+
<Legend iconAppearance="secondary" labelAppearance="none">
|
|
375
|
+
Legend
|
|
376
|
+
</Legend>;
|
|
377
|
+
|
|
378
|
+
// $ExpectType Element
|
|
379
|
+
<EditableDropdown
|
|
380
|
+
placeholder="placeholder"
|
|
381
|
+
dropdownOptions={{
|
|
382
|
+
onChange: () => {},
|
|
383
|
+
options: [{ label: 'label1', value: 'value1' }],
|
|
384
|
+
}}
|
|
385
|
+
/>;
|
|
386
|
+
|
|
387
|
+
// $ExpectType Element
|
|
388
|
+
<Link href="http://innovaccer.com" onClick={() => {}} appearance="subtle" size="tiny">
|
|
389
|
+
Link
|
|
390
|
+
</Link>;
|
|
391
|
+
|
|
392
|
+
// $ExpectType Element
|
|
393
|
+
<Message
|
|
394
|
+
title="title"
|
|
395
|
+
actions={<div>action</div>}
|
|
396
|
+
appearance="alert"
|
|
397
|
+
description="Could not start verification. Please try again later."
|
|
398
|
+
/>;
|
|
399
|
+
|
|
400
|
+
// $ExpectType Element
|
|
401
|
+
<Message
|
|
402
|
+
title="title"
|
|
403
|
+
actions={<div>action</div>}
|
|
404
|
+
appearance="alert"
|
|
405
|
+
description="Could not start verification. Please try again later."
|
|
406
|
+
/>;
|
|
407
|
+
|
|
408
|
+
// $ExpectType Element
|
|
409
|
+
<MetaList seperator={true} list={[{ icon: 'assessment', label: 'Meta data' }]} />;
|
|
410
|
+
|
|
411
|
+
// $ExpectType Element
|
|
412
|
+
<MultiSlider onRangeChange={() => {}}>
|
|
413
|
+
<MultiSlider.Handle value={0} fillAfter={true} />
|
|
414
|
+
<MultiSlider.Handle value={1} />
|
|
415
|
+
</MultiSlider>;
|
|
416
|
+
|
|
417
|
+
// $ExpectType Element
|
|
418
|
+
<OutsideClick className="d-inline-block" onOutsideClick={() => {}}>
|
|
419
|
+
<Card className="d-flex align-items-center justify-content-center" style={{ height: 200, width: 200 }}>
|
|
420
|
+
<Heading>Card</Heading>
|
|
421
|
+
</Card>
|
|
422
|
+
</OutsideClick>;
|
|
423
|
+
|
|
424
|
+
// $ExpectType Element
|
|
425
|
+
<ProgressBar value={50} max={100} />;
|
|
426
|
+
|
|
427
|
+
// $ExpectType Element
|
|
428
|
+
<StatusHint appearance="success">437 wil receive the message.</StatusHint>;
|
|
429
|
+
|
|
430
|
+
// $ExpectType Element
|
|
431
|
+
<Pills appearance="alert" subtle={false}>
|
|
432
|
+
{'Pills'}
|
|
433
|
+
</Pills>;
|
|
434
|
+
|
|
435
|
+
// $ExpectType Element
|
|
436
|
+
<Spinner size="small" appearance={'secondary'} data-test="DesignSystem-Button--Spinner" className="Button-spinner" />;
|
|
437
|
+
|
|
438
|
+
// $ExpectType Element
|
|
439
|
+
<Slider
|
|
440
|
+
min={1}
|
|
441
|
+
max={10}
|
|
442
|
+
label="Controlled Slider"
|
|
443
|
+
stepSize={0.1}
|
|
444
|
+
labelStepSize={1}
|
|
445
|
+
value={10}
|
|
446
|
+
onChange={() => {}}
|
|
447
|
+
className="mt-2"
|
|
448
|
+
/>;
|
|
449
|
+
|
|
450
|
+
// $ExpectType Element
|
|
451
|
+
<RangeSlider
|
|
452
|
+
min={1}
|
|
453
|
+
max={10}
|
|
454
|
+
label="Controlled Slider"
|
|
455
|
+
stepSize={0.1}
|
|
456
|
+
labelStepSize={1}
|
|
457
|
+
value={[2, 4]}
|
|
458
|
+
onChange={() => {}}
|
|
459
|
+
className="mt-2"
|
|
460
|
+
/>;
|
|
461
|
+
|
|
462
|
+
// $ExpectType Element
|
|
463
|
+
<Subheading appearance="subtle">Subheading</Subheading>;
|
|
464
|
+
|
|
465
|
+
// $ExpectType Element
|
|
466
|
+
<Switch defaultChecked={true} size="regular" disabled={false} checked={true} onChange={() => {}} />;
|
|
467
|
+
|
|
468
|
+
// $ExpectType Element
|
|
469
|
+
<Textarea
|
|
470
|
+
name="comments"
|
|
471
|
+
id="comments"
|
|
472
|
+
className="w-25"
|
|
473
|
+
placeholder="Enter your comments here"
|
|
474
|
+
value="value"
|
|
475
|
+
onChange={(e) => {
|
|
476
|
+
console.log(e);
|
|
477
|
+
}}
|
|
478
|
+
rows={3}
|
|
479
|
+
/>;
|
|
480
|
+
|
|
481
|
+
// $ExpectType Element
|
|
482
|
+
<Toast
|
|
483
|
+
appearance="alert"
|
|
484
|
+
title="Campaign failed to run"
|
|
485
|
+
message="Try to run again. If it continues to fail, please raise a ticket."
|
|
486
|
+
actions={[
|
|
487
|
+
{
|
|
488
|
+
label: 'Need Prior Auth',
|
|
489
|
+
onClick: () => {},
|
|
490
|
+
},
|
|
491
|
+
]}
|
|
492
|
+
/>;
|
|
493
|
+
|
|
494
|
+
// $ExpectType Element
|
|
495
|
+
<Popover position="bottom" on="click" trigger={<Button appearance="basic">Open Popup</Button>} dark={true} open={true}>
|
|
496
|
+
<div style={{ width: 'var(--spacing-7)', height: 'var(--spacing-7)' }} />
|
|
497
|
+
</Popover>;
|
|
498
|
+
|
|
499
|
+
// $ExpectType Element
|
|
500
|
+
<ChipInput
|
|
501
|
+
allowDuplicates={false}
|
|
502
|
+
placeholder="placeholder"
|
|
503
|
+
disabled={false}
|
|
504
|
+
chipOptions={{ clearButton: true }}
|
|
505
|
+
value={['1024', '80']}
|
|
506
|
+
className="w-50"
|
|
507
|
+
onChange={() => {}}
|
|
508
|
+
/>;
|
|
509
|
+
|
|
510
|
+
// $ExpectType Element
|
|
511
|
+
<VerticalNav
|
|
512
|
+
menus={[
|
|
513
|
+
{
|
|
514
|
+
name: 'received',
|
|
515
|
+
label: 'Received',
|
|
516
|
+
icon: 'call_received',
|
|
517
|
+
subMenu: [
|
|
518
|
+
{
|
|
519
|
+
name: 'to_dos.due',
|
|
520
|
+
label: 'Due',
|
|
521
|
+
count: 10,
|
|
522
|
+
},
|
|
523
|
+
],
|
|
524
|
+
},
|
|
525
|
+
]}
|
|
526
|
+
expanded={true}
|
|
527
|
+
active={{
|
|
528
|
+
name: 'data_exchange.reports',
|
|
529
|
+
}}
|
|
530
|
+
onClick={() => {}}
|
|
531
|
+
autoCollapse={true}
|
|
532
|
+
/>;
|
|
533
|
+
|
|
534
|
+
// $ExpectType Element
|
|
535
|
+
<HorizontalNav
|
|
536
|
+
className="w-100 justify-content-center"
|
|
537
|
+
menus={[
|
|
538
|
+
{
|
|
539
|
+
name: 'received',
|
|
540
|
+
label: 'Received',
|
|
541
|
+
icon: 'call_received',
|
|
542
|
+
subMenu: [
|
|
543
|
+
{
|
|
544
|
+
name: 'to_dos.due',
|
|
545
|
+
label: 'Due',
|
|
546
|
+
count: 10,
|
|
547
|
+
},
|
|
548
|
+
],
|
|
549
|
+
},
|
|
550
|
+
]}
|
|
551
|
+
active={{
|
|
552
|
+
name: 'data_exchange.reports',
|
|
553
|
+
}}
|
|
554
|
+
onClick={() => {}}
|
|
555
|
+
/>;
|
|
556
|
+
|
|
557
|
+
// $ExpectType Element
|
|
558
|
+
<Tooltip tooltip="tooltip" position="top" appendToBody={true} triggerClass="w-100 overflow-hidden">
|
|
559
|
+
<Button>Button</Button>
|
|
560
|
+
</Tooltip>;
|
|
561
|
+
|
|
562
|
+
// $ExpectType Element
|
|
563
|
+
<Dialog
|
|
564
|
+
open={true}
|
|
565
|
+
onClose={() => {}}
|
|
566
|
+
dimension="small"
|
|
567
|
+
primaryButtonAppearance="primary"
|
|
568
|
+
secondaryButtonAppearance="success"
|
|
569
|
+
heading="Heading"
|
|
570
|
+
title="Description Title"
|
|
571
|
+
description="Adding a subheading clearly indicates the hierarchy of the information."
|
|
572
|
+
primaryButtonLabel="Primary"
|
|
573
|
+
secondaryButtonLabel="Basic"
|
|
574
|
+
/>;
|
|
575
|
+
|
|
576
|
+
// $ExpectType Element
|
|
577
|
+
<Modal open={true} dimension="small" backdropClose={true}>
|
|
578
|
+
<ModalHeader onClose={() => {}} heading="Heading" subHeading="Subheading" />
|
|
579
|
+
<ModalBody>
|
|
580
|
+
<Text>Modal Body</Text>
|
|
581
|
+
<ModalDescription
|
|
582
|
+
title="Description Title"
|
|
583
|
+
description="Adding a subheading clearly indicates the hierarchy of the information."
|
|
584
|
+
/>
|
|
585
|
+
<ModalDescription description="Card Sections include supporting text like an article summary or a restaurant description." />
|
|
586
|
+
</ModalBody>
|
|
587
|
+
<ModalFooter open={true}>
|
|
588
|
+
<Button appearance="basic" onClick={() => {}}>
|
|
589
|
+
Basic
|
|
590
|
+
</Button>
|
|
591
|
+
<Button appearance="primary" className="ml-4" onClick={() => {}}>
|
|
592
|
+
Primary
|
|
593
|
+
</Button>
|
|
594
|
+
</ModalFooter>
|
|
595
|
+
</Modal>;
|
|
596
|
+
|
|
597
|
+
// $ExpectType Element
|
|
598
|
+
<Modal open={true} dimension="small" backdropClose={true}>
|
|
599
|
+
<ModalHeader onClose={() => {}} heading="Heading" subHeading="Subheading" />
|
|
600
|
+
<ModalBody>
|
|
601
|
+
<Text>Modal Body</Text>
|
|
602
|
+
<ModalDescription
|
|
603
|
+
title="Description Title"
|
|
604
|
+
description="Adding a subheading clearly indicates the hierarchy of the information."
|
|
605
|
+
/>
|
|
606
|
+
<ModalDescription description="Card Sections include supporting text like an article summary or a restaurant description." />
|
|
607
|
+
</ModalBody>
|
|
608
|
+
<ModalFooter open={true}>
|
|
609
|
+
<Button appearance="basic" onClick={() => {}}>
|
|
610
|
+
Basic
|
|
611
|
+
</Button>
|
|
612
|
+
<Button appearance="primary" className="ml-4" onClick={() => {}}>
|
|
613
|
+
Primary
|
|
614
|
+
</Button>
|
|
615
|
+
</ModalFooter>
|
|
616
|
+
</Modal>;
|
|
617
|
+
|
|
618
|
+
// $ExpectType Element
|
|
619
|
+
<FullscreenModal
|
|
620
|
+
open={true}
|
|
621
|
+
dimension="large"
|
|
622
|
+
onClose={() => {}}
|
|
623
|
+
headerOptions={{
|
|
624
|
+
heading: 'This is modal Heading',
|
|
625
|
+
subHeading: 'This is modal subheading',
|
|
626
|
+
}}
|
|
627
|
+
footerOptions={{
|
|
628
|
+
actions: [
|
|
629
|
+
{
|
|
630
|
+
children: 'Primary',
|
|
631
|
+
appearance: 'primary',
|
|
632
|
+
className: 'ml-4',
|
|
633
|
+
onClick: () => {},
|
|
634
|
+
},
|
|
635
|
+
],
|
|
636
|
+
}}
|
|
637
|
+
>
|
|
638
|
+
<Text>Fullscreen Modal Body</Text>
|
|
639
|
+
</FullscreenModal>;
|
|
640
|
+
|
|
641
|
+
// $ExpectType Element
|
|
642
|
+
<Sidesheet
|
|
643
|
+
dimension="large"
|
|
644
|
+
headerOptions={{
|
|
645
|
+
backIcon: false,
|
|
646
|
+
heading: 'Heading',
|
|
647
|
+
subHeading: 'Subheading',
|
|
648
|
+
}}
|
|
649
|
+
open={true}
|
|
650
|
+
footerOptions={{ actions: [] }}
|
|
651
|
+
/>;
|
|
652
|
+
|
|
653
|
+
// $ExpectType Element
|
|
654
|
+
<Collapsible height="500px" expandedWidth={240} onToggle={() => {}} hoverable={false} expanded={true}>
|
|
655
|
+
<div className="d-flex pt-4">
|
|
656
|
+
<Icon name="events" data-test="DesignSystem-Collapsible--Icon" />
|
|
657
|
+
</div>
|
|
658
|
+
</Collapsible>;
|
|
659
|
+
|
|
660
|
+
// $ExpectType Element
|
|
661
|
+
<ChatMessage
|
|
662
|
+
text="Message Text"
|
|
663
|
+
type="incoming"
|
|
664
|
+
typingText="Typing Text"
|
|
665
|
+
statusOptions={{
|
|
666
|
+
type: 'sending',
|
|
667
|
+
sendingText: 'Sending Text',
|
|
668
|
+
}}
|
|
669
|
+
/>;
|
|
670
|
+
|
|
671
|
+
// $ExpectType Element
|
|
672
|
+
<EmptyState
|
|
673
|
+
title="Unable to fetch data"
|
|
674
|
+
description="Sorry there was a technical issue while getting this data. Please try again."
|
|
675
|
+
imageSrc="/image"
|
|
676
|
+
size="small"
|
|
677
|
+
className="pb-6"
|
|
678
|
+
>
|
|
679
|
+
<Button icon="refresh" iconAlign="left" className="mt-3">
|
|
680
|
+
Reload
|
|
681
|
+
</Button>
|
|
682
|
+
</EmptyState>;
|
|
683
|
+
|
|
684
|
+
// $ExpectType Element
|
|
685
|
+
<Pagination type="basic" page={1} totalPages={50} onPageChange={(pageNo) => console.log(pageNo)} />;
|
|
686
|
+
|
|
687
|
+
// $ExpectType Element
|
|
688
|
+
<Placeholder withImage={false} round={true}>
|
|
689
|
+
<PlaceholderParagraph className="ml-3" length="large" size="m" />
|
|
690
|
+
</Placeholder>;
|
|
691
|
+
|
|
692
|
+
// $ExpectType Element
|
|
693
|
+
<EditableInput
|
|
694
|
+
placeholder="First Name"
|
|
695
|
+
value="value"
|
|
696
|
+
onChange={() => {}}
|
|
697
|
+
error={true}
|
|
698
|
+
errorMessage={'Error Message'}
|
|
699
|
+
/>;
|
|
700
|
+
|
|
701
|
+
// $ExpectType Element
|
|
702
|
+
<ProgressRing value={30} size="regular" max={100} />;
|
|
703
|
+
|
|
704
|
+
// $ExpectType Element
|
|
705
|
+
<Stepper
|
|
706
|
+
steps={[
|
|
707
|
+
{
|
|
708
|
+
label: 'Step',
|
|
709
|
+
value: 'Step1',
|
|
710
|
+
},
|
|
711
|
+
{
|
|
712
|
+
label: 'Step',
|
|
713
|
+
value: 'Step2',
|
|
714
|
+
},
|
|
715
|
+
]}
|
|
716
|
+
active={1}
|
|
717
|
+
completed={2}
|
|
718
|
+
onChange={() => {}}
|
|
719
|
+
/>;
|
|
720
|
+
|
|
721
|
+
// $ExpectType Element
|
|
722
|
+
<DateRangePicker
|
|
723
|
+
monthsInView={3}
|
|
724
|
+
startDate={new Date(2019, 11, 3)}
|
|
725
|
+
endDate={new Date(2020, 1, 11)}
|
|
726
|
+
startInputOptions={{ caption: 'caption', error: true, required: true }}
|
|
727
|
+
yearNav={2019}
|
|
728
|
+
monthNav={11}
|
|
729
|
+
withInput={true}
|
|
730
|
+
onRangeChange={() => {}}
|
|
731
|
+
inputOptions={{ placeholderChar: '#' }}
|
|
732
|
+
/>;
|
|
733
|
+
|
|
734
|
+
// $ExpectType Element
|
|
735
|
+
<TabsWrapper active={0} onTabChange={() => {}}>
|
|
736
|
+
<Tab label="label" count={10} icon="icon" disabled={true}>
|
|
737
|
+
Tab 1
|
|
738
|
+
</Tab>
|
|
739
|
+
</TabsWrapper>;
|
|
740
|
+
|
|
741
|
+
// $ExpectType Element
|
|
742
|
+
<Dropzone
|
|
743
|
+
formatLabel="Accepted formats: PDF, jpg"
|
|
744
|
+
sizeLabel="Maximum size: 25 MB"
|
|
745
|
+
onDrop={() => {}}
|
|
746
|
+
disabled={false}
|
|
747
|
+
className="mb-3"
|
|
748
|
+
type="tight"
|
|
749
|
+
sampleFileLink={
|
|
750
|
+
<Link
|
|
751
|
+
href="http://www.adobe.com/content/dam/Adobe/en/accessibility/pdfs/accessing-pdf-sr.pdf"
|
|
752
|
+
download="Test.pdf"
|
|
753
|
+
target="_blank"
|
|
754
|
+
>
|
|
755
|
+
Download sample file
|
|
756
|
+
</Link>
|
|
757
|
+
}
|
|
758
|
+
/>;
|
|
759
|
+
|
|
760
|
+
// $ExpectType Element
|
|
761
|
+
<Dropzone
|
|
762
|
+
formatLabel="Accepted formats: PDF, jpg"
|
|
763
|
+
sizeLabel="Maximum size: 25 MB"
|
|
764
|
+
onDrop={() => {}}
|
|
765
|
+
disabled={false}
|
|
766
|
+
className="mb-3"
|
|
767
|
+
type="tight"
|
|
768
|
+
sampleFileLink={
|
|
769
|
+
<Link
|
|
770
|
+
href="http://www.adobe.com/content/dam/Adobe/en/accessibility/pdfs/accessing-pdf-sr.pdf"
|
|
771
|
+
download="Test.pdf"
|
|
772
|
+
target="_blank"
|
|
773
|
+
>
|
|
774
|
+
Download sample file
|
|
775
|
+
</Link>
|
|
776
|
+
}
|
|
777
|
+
/>;
|
|
778
|
+
|
|
779
|
+
// $ExpectType Element
|
|
780
|
+
<FileUploader
|
|
781
|
+
sizeLabel="Maximum size: 25 MB"
|
|
782
|
+
disabled={false}
|
|
783
|
+
className="mb-3"
|
|
784
|
+
multiple={true}
|
|
785
|
+
title="title"
|
|
786
|
+
sampleFileLink={
|
|
787
|
+
<Link
|
|
788
|
+
href="http://www.adobe.com/content/dam/Adobe/en/accessibility/pdfs/accessing-pdf-sr.pdf"
|
|
789
|
+
download="Test.pdf"
|
|
790
|
+
target="_blank"
|
|
791
|
+
>
|
|
792
|
+
Download sample file
|
|
793
|
+
</Link>
|
|
794
|
+
}
|
|
795
|
+
formatLabel="Accepted formats: PDF, jpg, png"
|
|
796
|
+
/>;
|
|
797
|
+
|
|
798
|
+
// $ExpectType Element
|
|
799
|
+
<FileUploaderList
|
|
800
|
+
onDelete={() => {}}
|
|
801
|
+
onRetry={() => {}}
|
|
802
|
+
fileList={[
|
|
803
|
+
{
|
|
804
|
+
file: (File = {
|
|
805
|
+
name: 'Audio File.mp3',
|
|
806
|
+
size: '3 MB',
|
|
807
|
+
type: 'audio',
|
|
808
|
+
} as any),
|
|
809
|
+
status: 'uploading',
|
|
810
|
+
progress: 45,
|
|
811
|
+
id: 1,
|
|
812
|
+
},
|
|
813
|
+
]}
|
|
814
|
+
className="mt-4"
|
|
815
|
+
/>;
|
|
816
|
+
|
|
817
|
+
// $ExpectType Element
|
|
818
|
+
<Grid
|
|
819
|
+
schema={[
|
|
820
|
+
{
|
|
821
|
+
name: 'name',
|
|
822
|
+
displayName: 'Name',
|
|
823
|
+
width: '50%',
|
|
824
|
+
},
|
|
825
|
+
]}
|
|
826
|
+
data={[
|
|
827
|
+
{
|
|
828
|
+
name: 'Zara',
|
|
829
|
+
gender: 'f',
|
|
830
|
+
},
|
|
831
|
+
]}
|
|
832
|
+
withCheckbox={true}
|
|
833
|
+
withPagination={true}
|
|
834
|
+
updateSortingList={() => {}}
|
|
835
|
+
sortingList={[{ name: 'name', type: 'desc' }]}
|
|
836
|
+
/>;
|
|
837
|
+
|
|
838
|
+
// $ExpectType Element
|
|
839
|
+
<GridCell
|
|
840
|
+
schema={{
|
|
841
|
+
displayName: 'Name',
|
|
842
|
+
name: 'name',
|
|
843
|
+
cellType: 'WITH_META_LIST',
|
|
844
|
+
}}
|
|
845
|
+
data={{ name: 'Zara' }}
|
|
846
|
+
loading={true}
|
|
847
|
+
size="comfortable"
|
|
848
|
+
rowIndex={1}
|
|
849
|
+
colIndex={1}
|
|
850
|
+
/>;
|
|
851
|
+
|
|
852
|
+
// $ExpectType Element
|
|
853
|
+
<Table
|
|
854
|
+
data={[
|
|
855
|
+
{
|
|
856
|
+
className: 'align-baseline',
|
|
857
|
+
properties: 'vertical-align: baseline ;',
|
|
858
|
+
},
|
|
859
|
+
]}
|
|
860
|
+
schema={[
|
|
861
|
+
{
|
|
862
|
+
name: 'className',
|
|
863
|
+
displayName: 'ClassName',
|
|
864
|
+
width: '50%',
|
|
865
|
+
resizable: true,
|
|
866
|
+
align: 'left',
|
|
867
|
+
cellRenderer: (props: any) => {
|
|
868
|
+
return (
|
|
869
|
+
<>
|
|
870
|
+
<GridCell {...props} />
|
|
871
|
+
<Button
|
|
872
|
+
title="Copy className to clipboard"
|
|
873
|
+
appearance="transparent"
|
|
874
|
+
icon="content_copy"
|
|
875
|
+
onClick={() => {}}
|
|
876
|
+
/>
|
|
877
|
+
</>
|
|
878
|
+
);
|
|
879
|
+
},
|
|
880
|
+
},
|
|
881
|
+
]}
|
|
882
|
+
size={'standard'}
|
|
883
|
+
headerOptions={{
|
|
884
|
+
withSearch: true,
|
|
885
|
+
}}
|
|
886
|
+
showMenu={false}
|
|
887
|
+
/>;
|
|
888
|
+
|
|
889
|
+
// $ExpectType Element
|
|
890
|
+
<List
|
|
891
|
+
data={[
|
|
892
|
+
{
|
|
893
|
+
data: {
|
|
894
|
+
title: 'Reminder for due lab tests',
|
|
895
|
+
subTitle: 'ENG. +1 Hi [recipient.name]! Your (test) is overdue. Please get in touch with [recipient.PCPI...',
|
|
896
|
+
},
|
|
897
|
+
},
|
|
898
|
+
]}
|
|
899
|
+
schema={[
|
|
900
|
+
{
|
|
901
|
+
width: '100%',
|
|
902
|
+
name: 'data',
|
|
903
|
+
displayName: '',
|
|
904
|
+
cellRenderer: () => {
|
|
905
|
+
return (
|
|
906
|
+
<>
|
|
907
|
+
<Paragraph>
|
|
908
|
+
<Text weight="strong">title</Text>
|
|
909
|
+
</Paragraph>
|
|
910
|
+
</>
|
|
911
|
+
);
|
|
912
|
+
},
|
|
913
|
+
},
|
|
914
|
+
]}
|
|
915
|
+
withHeader={true}
|
|
916
|
+
headerOptions={{
|
|
917
|
+
withSearch: true,
|
|
918
|
+
dynamicColumn: false,
|
|
919
|
+
}}
|
|
920
|
+
withPagination={true}
|
|
921
|
+
pageSize={5}
|
|
922
|
+
/>;
|
|
923
|
+
|
|
924
|
+
// $ExpectType Element
|
|
925
|
+
<ChoiceList
|
|
926
|
+
choices={[
|
|
927
|
+
{ label: 'Male', name: 'gender', value: 'Male' },
|
|
928
|
+
{ label: 'Female', name: 'gender', value: 'Female' },
|
|
929
|
+
{ label: 'Other', name: 'gender', value: 'Other' },
|
|
930
|
+
]}
|
|
931
|
+
title="title"
|
|
932
|
+
onChange={() => {}}
|
|
933
|
+
/>;
|
|
934
|
+
|
|
935
|
+
// $ExpectType Element
|
|
936
|
+
<InlineMessage appearance="info" description="Patient profile updated." />;
|