@rh-support/components 2.4.10-beta.6 → 2.5.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/README.md +2 -0
- package/lib/esm/AlertMessage/AlertMessage.d.ts +2 -2
- package/lib/esm/AlertMessage/AlertMessage.d.ts.map +1 -1
- package/lib/esm/AlertMessage/AlertMessage.js +1 -1
- package/lib/esm/ConfirmationModal/ConfirmationContext.d.ts +2 -1
- package/lib/esm/ConfirmationModal/ConfirmationContext.d.ts.map +1 -1
- package/lib/esm/ConfirmationModal/ConfirmationDialog.d.ts +2 -1
- package/lib/esm/ConfirmationModal/ConfirmationDialog.d.ts.map +1 -1
- package/lib/esm/CoverSpinner/CoverSpinner.d.ts +2 -1
- package/lib/esm/CoverSpinner/CoverSpinner.d.ts.map +1 -1
- package/lib/esm/CustomContentLoader/CustomContentLoader.d.ts +2 -2
- package/lib/esm/CustomContentLoader/CustomContentLoader.d.ts.map +1 -1
- package/lib/esm/CustomTextInput/CustomTextInput.d.ts +3 -1
- package/lib/esm/CustomTextInput/CustomTextInput.d.ts.map +1 -1
- package/lib/esm/CustomTextInput/CustomTextInput.js +4 -2
- package/lib/esm/DropDownList/AsyncDropDownList.d.ts +1 -1
- package/lib/esm/DropDownList/AsyncDropDownList.d.ts.map +1 -1
- package/lib/esm/DropDownList/DropDownList.d.ts +2 -1
- package/lib/esm/DropDownList/DropDownList.d.ts.map +1 -1
- package/lib/esm/DropDownList/DropDownList.js +10 -10
- package/lib/esm/DropDownList/DropdownWrapper.d.ts +1 -1
- package/lib/esm/DropDownList/DropdownWrapper.d.ts.map +1 -1
- package/lib/esm/DropDownList/DropdownWrapper.js +2 -2
- package/lib/esm/DropDownList/MultiSelectDropdownList.d.ts.map +1 -1
- package/lib/esm/DropDownList/SearchableList.d.ts +1 -1
- package/lib/esm/DropDownList/SearchableList.d.ts.map +1 -1
- package/lib/esm/DropDownList/SearchableList.js +6 -6
- package/lib/esm/DropDownList/SelectList.d.ts +1 -1
- package/lib/esm/DropDownList/SelectList.d.ts.map +1 -1
- package/lib/esm/DropDownList/SelectList.js +6 -6
- package/lib/esm/DropDownList/async.d.ts +1 -1
- package/lib/esm/DropDownList/async.d.ts.map +1 -1
- package/lib/esm/DropDownList/dropdownList.css +10 -5
- package/lib/esm/DropDownList/types.d.ts +6 -7
- package/lib/esm/DropDownList/types.d.ts.map +1 -1
- package/lib/esm/DropDownList/withMulti.d.ts +1 -1
- package/lib/esm/DropDownList/withMulti.d.ts.map +1 -1
- package/lib/esm/DropDownList/withMulti.js +1 -0
- package/lib/esm/ErrorBoundary/ErrorBoundary.d.ts +2 -1
- package/lib/esm/ErrorBoundary/ErrorBoundary.d.ts.map +1 -1
- package/lib/esm/ErrorBoundary/ErrorBoundary.js +1 -1
- package/lib/esm/ErrorBoundary/ErrorBoundaryFallbackComponent.d.ts +2 -1
- package/lib/esm/ErrorBoundary/ErrorBoundaryFallbackComponent.d.ts.map +1 -1
- package/lib/esm/ErrorBoundary/ErrorBoundaryFallbackComponent.js +3 -4
- package/lib/esm/ErrorPages/Generic403.d.ts +2 -1
- package/lib/esm/ErrorPages/Generic403.d.ts.map +1 -1
- package/lib/esm/FeedbackForm/FeedbackForm.d.ts +2 -1
- package/lib/esm/FeedbackForm/FeedbackForm.d.ts.map +1 -1
- package/lib/esm/FeedbackForm/FeedbackForm.js +2 -2
- package/lib/esm/Functional/CaseContactsSelectorExternal.d.ts +5 -4
- package/lib/esm/Functional/CaseContactsSelectorExternal.d.ts.map +1 -1
- package/lib/esm/Functional/CaseContactsSelectorExternal.js +9 -8
- package/lib/esm/InlineEdit/InlineEdit.d.ts +2 -2
- package/lib/esm/InlineEdit/InlineEdit.d.ts.map +1 -1
- package/lib/esm/InlineEdit/InlineEdit.js +1 -1
- package/lib/esm/InlineEdit/NewInlineEdit.d.ts +2 -2
- package/lib/esm/InlineEdit/NewInlineEdit.d.ts.map +1 -1
- package/lib/esm/InlineEdit/NewInlineEdit.js +2 -2
- package/lib/esm/InlineEdit/inlineEdit.css +24 -1
- package/lib/esm/InlineEdit/newInlineEdit.css +5 -4
- package/lib/esm/LanguageSelector/LanguageSelector.d.ts +2 -1
- package/lib/esm/LanguageSelector/LanguageSelector.d.ts.map +1 -1
- package/lib/esm/LanguageSelector/LanguageSelector.js +13 -3
- package/lib/esm/LanguageSelector/languageSelector.css +1 -1
- package/lib/esm/LoadingDots/LoadingDots.d.ts +3 -1
- package/lib/esm/LoadingDots/LoadingDots.d.ts.map +1 -1
- package/lib/esm/LoadingDots/LoadingDots.js +2 -2
- package/lib/esm/LoadingIndicator/LoadingIndicator.d.ts +2 -1
- package/lib/esm/LoadingIndicator/LoadingIndicator.d.ts.map +1 -1
- package/lib/esm/LoginModal/LoginModal.d.ts +2 -1
- package/lib/esm/LoginModal/LoginModal.d.ts.map +1 -1
- package/lib/esm/LoginModal/LoginModal.js +1 -1
- package/lib/esm/MarkdownEditor/MarkdownEditor.d.ts +1 -1
- package/lib/esm/MarkdownEditor/MarkdownEditor.d.ts.map +1 -1
- package/lib/esm/MarkdownEditor/MarkdownEditor.js +168 -80
- package/lib/esm/MarkdownEditor/markdownEditor.css +113 -5
- package/lib/esm/MoreOrLess/MoreOrLess.d.ts +1 -1
- package/lib/esm/MoreOrLess/MoreOrLess.d.ts.map +1 -1
- package/lib/esm/PaginatedList/PaginatedList.d.ts +2 -1
- package/lib/esm/PaginatedList/PaginatedList.d.ts.map +1 -1
- package/lib/esm/PaginatedList/PaginatedList.js +9 -0
- package/lib/esm/PaginationCompact/PaginationCompact.d.ts +2 -1
- package/lib/esm/PaginationCompact/PaginationCompact.d.ts.map +1 -1
- package/lib/esm/PaginationCompact/PaginationCompact.js +4 -4
- package/lib/esm/PaginationCompact/paginationCompact.css +1 -1
- package/lib/esm/PhoneInput/CountryData.d.ts.map +1 -1
- package/lib/esm/PhoneInput/CountryData.js +3 -2
- package/lib/esm/PhoneInput/FlagSvgs.d.ts +3 -0
- package/lib/esm/PhoneInput/FlagSvgs.d.ts.map +1 -0
- package/lib/esm/PhoneInput/FlagSvgs.js +2018 -0
- package/lib/esm/PhoneInput/PhoneInput.d.ts +14 -1
- package/lib/esm/PhoneInput/PhoneInput.d.ts.map +1 -1
- package/lib/esm/PhoneInput/PhoneInput.js +121 -120
- package/lib/esm/PhoneInput/PhoneInput.scss +15 -732
- package/lib/esm/ProgressBar/CircularProgressBar/CircularProgressBar.d.ts +2 -1
- package/lib/esm/ProgressBar/CircularProgressBar/CircularProgressBar.d.ts.map +1 -1
- package/lib/esm/ProgressBar/CircularProgressBar/Path.d.ts +1 -1
- package/lib/esm/ProgressBar/CircularProgressBar/Path.d.ts.map +1 -1
- package/lib/esm/ProgressBar/CircularProgressBar/types.d.ts +3 -4
- package/lib/esm/ProgressBar/CircularProgressBar/types.d.ts.map +1 -1
- package/lib/esm/ProgressBar/ProgressBar.d.ts +1 -1
- package/lib/esm/ProgressBar/ProgressBar.d.ts.map +1 -1
- package/lib/esm/PromisifyModal/PromisifyModal.d.ts +6 -9
- package/lib/esm/PromisifyModal/PromisifyModal.d.ts.map +1 -1
- package/lib/esm/PromisifyModal/PromisifyModal.js +21 -18
- package/lib/esm/SubscriptionAbuse/SubscriptionAbuseModal.d.ts +2 -1
- package/lib/esm/SubscriptionAbuse/SubscriptionAbuseModal.d.ts.map +1 -1
- package/lib/esm/SubscriptionAbuse/const.d.ts +2 -1
- package/lib/esm/SubscriptionAbuse/const.d.ts.map +1 -1
- package/lib/esm/SupportFeedbackForm/SupportFeedbackForm.d.ts +2 -1
- package/lib/esm/SupportFeedbackForm/SupportFeedbackForm.d.ts.map +1 -1
- package/lib/esm/SupportFeedbackForm/SupportFeedbackModal.d.ts +2 -1
- package/lib/esm/SupportFeedbackForm/SupportFeedbackModal.d.ts.map +1 -1
- package/lib/esm/SupportFeedbackForm/SupportFeedbackModal.js +14 -14
- package/lib/esm/Table/PFTable.d.ts +4 -3
- package/lib/esm/Table/PFTable.d.ts.map +1 -1
- package/lib/esm/Table/PFTable.js +6 -6
- package/lib/{cjs/Table/Table.d.ts → esm/Table/TableComponent.d.ts} +2 -2
- package/lib/esm/Table/TableComponent.d.ts.map +1 -0
- package/lib/esm/Table/{Table.js → TableComponent.js} +1 -1
- package/lib/esm/Table/TablePagination.d.ts +2 -1
- package/lib/esm/Table/TablePagination.d.ts.map +1 -1
- package/lib/esm/Table/TablePagination.js +4 -2
- package/lib/esm/Table/index.d.ts +1 -2
- package/lib/esm/Table/index.d.ts.map +1 -1
- package/lib/esm/Table/index.js +1 -2
- package/lib/esm/TagsSelector/TagsSelector.d.ts +14 -0
- package/lib/esm/TagsSelector/TagsSelector.d.ts.map +1 -0
- package/lib/esm/TagsSelector/TagsSelector.js +73 -0
- package/lib/esm/TagsSelector/index.d.ts +2 -0
- package/lib/esm/TagsSelector/index.d.ts.map +1 -0
- package/lib/esm/TagsSelector/index.js +1 -0
- package/lib/esm/TagsSelector/tagSelector.css +11 -0
- package/lib/esm/TermsAndConditions/AcceptTermsModal.d.ts +2 -1
- package/lib/esm/TermsAndConditions/AcceptTermsModal.d.ts.map +1 -1
- package/lib/esm/TermsAndConditions/AcceptTermsModal.js +7 -6
- package/lib/esm/TextAreaAutosize/TextAreaAutosize.d.ts +1 -1
- package/lib/esm/TextAreaAutosize/TextAreaAutosize.d.ts.map +1 -1
- package/lib/esm/TextAreaResizable/TextAreaResizable.d.ts +1 -1
- package/lib/esm/TextAreaResizable/TextAreaResizable.d.ts.map +1 -1
- package/lib/esm/TextAreaResizable/TextAreaResizable.js +1 -1
- package/lib/esm/ToastNotification/ToastNotification.d.ts +1 -1
- package/lib/esm/ToastNotification/ToastNotification.d.ts.map +1 -1
- package/lib/esm/ToastNotification/ToastNotification.js +13 -5
- package/lib/esm/ToastNotification/toastNotification.css +1 -1
- package/lib/esm/TopContentSearch/TopContentSearch.d.ts +5 -1
- package/lib/esm/TopContentSearch/TopContentSearch.d.ts.map +1 -1
- package/lib/esm/TopContentSearch/TopContentSearch.js +20 -23
- package/lib/esm/ValueChangedIcon/ValueChangedIcon.d.ts +1 -1
- package/lib/esm/ValueChangedIcon/ValueChangedIcon.d.ts.map +1 -1
- package/lib/esm/helperFunctions/errorMessage.js +2 -2
- package/lib/esm/helperFunctions/errorMessage.scss +1 -1
- package/lib/esm/hooks/index.d.ts +4 -0
- package/lib/esm/hooks/index.d.ts.map +1 -1
- package/lib/esm/hooks/index.js +4 -0
- package/lib/esm/hooks/useBreakpoint.d.ts +2 -2
- package/lib/esm/hooks/useBreakpoint.d.ts.map +1 -1
- package/lib/esm/hooks/useBreakpoint.js +2 -0
- package/lib/esm/hooks/useCopyToClipboard.d.ts.map +1 -1
- package/lib/esm/hooks/useCopyToClipboard.js +1 -0
- package/lib/esm/hooks/useFetch.js +1 -2
- package/lib/esm/hooks/useLocalStorage.d.ts +2 -2
- package/lib/esm/hooks/useLocalStorage.d.ts.map +1 -1
- package/lib/esm/hooks/useSearchDocument.d.ts +7 -0
- package/lib/esm/hooks/useSearchDocument.d.ts.map +1 -0
- package/lib/esm/hooks/useSearchDocument.js +42 -0
- package/lib/esm/hooks/useSelectKeyboardNavigator.d.ts +13 -0
- package/lib/esm/hooks/useSelectKeyboardNavigator.d.ts.map +1 -0
- package/lib/esm/hooks/useSelectKeyboardNavigator.js +54 -0
- package/lib/esm/hooks/useSessionStorage.d.ts +5 -0
- package/lib/esm/hooks/useSessionStorage.d.ts.map +1 -0
- package/lib/esm/hooks/useSessionStorage.js +30 -0
- package/lib/esm/index.d.ts +1 -0
- package/lib/esm/index.d.ts.map +1 -1
- package/lib/esm/index.js +1 -0
- package/package.json +40 -46
- package/lib/cjs/AlertMessage/AlertMessage.css +0 -9
- package/lib/cjs/AlertMessage/AlertMessage.d.ts +0 -24
- package/lib/cjs/AlertMessage/AlertMessage.d.ts.map +0 -1
- package/lib/cjs/AlertMessage/AlertMessage.js +0 -30
- package/lib/cjs/AlertMessage/index.d.ts +0 -2
- package/lib/cjs/AlertMessage/index.d.ts.map +0 -1
- package/lib/cjs/AlertMessage/index.js +0 -14
- package/lib/cjs/ConfirmationModal/ConfirmationContext.d.ts +0 -6
- package/lib/cjs/ConfirmationModal/ConfirmationContext.d.ts.map +0 -1
- package/lib/cjs/ConfirmationModal/ConfirmationContext.js +0 -53
- package/lib/cjs/ConfirmationModal/ConfirmationDialog.d.ts +0 -29
- package/lib/cjs/ConfirmationModal/ConfirmationDialog.d.ts.map +0 -1
- package/lib/cjs/ConfirmationModal/ConfirmationDialog.js +0 -28
- package/lib/cjs/ConfirmationModal/ConfirmationModal.stories.d.ts +0 -1
- package/lib/cjs/ConfirmationModal/ConfirmationModal.stories.d.ts.map +0 -1
- package/lib/cjs/ConfirmationModal/ConfirmationModal.stories.js +0 -36
- package/lib/cjs/ConfirmationModal/index.d.ts +0 -3
- package/lib/cjs/ConfirmationModal/index.d.ts.map +0 -1
- package/lib/cjs/ConfirmationModal/index.js +0 -14
- package/lib/cjs/CoverSpinner/CoverSpinner.css +0 -16
- package/lib/cjs/CoverSpinner/CoverSpinner.d.ts +0 -3
- package/lib/cjs/CoverSpinner/CoverSpinner.d.ts.map +0 -1
- package/lib/cjs/CoverSpinner/CoverSpinner.js +0 -13
- package/lib/cjs/CoverSpinner/index.d.ts +0 -2
- package/lib/cjs/CoverSpinner/index.d.ts.map +0 -1
- package/lib/cjs/CoverSpinner/index.js +0 -13
- package/lib/cjs/CustomContentLoader/CustomContentLoader.d.ts +0 -15
- package/lib/cjs/CustomContentLoader/CustomContentLoader.d.ts.map +0 -1
- package/lib/cjs/CustomContentLoader/CustomContentLoader.js +0 -62
- package/lib/cjs/CustomContentLoader/index.d.ts +0 -2
- package/lib/cjs/CustomContentLoader/index.d.ts.map +0 -1
- package/lib/cjs/CustomContentLoader/index.js +0 -13
- package/lib/cjs/CustomTextInput/CustomTextInput.d.ts +0 -12
- package/lib/cjs/CustomTextInput/CustomTextInput.d.ts.map +0 -1
- package/lib/cjs/CustomTextInput/CustomTextInput.js +0 -48
- package/lib/cjs/CustomTextInput/index.d.ts +0 -2
- package/lib/cjs/CustomTextInput/index.d.ts.map +0 -1
- package/lib/cjs/CustomTextInput/index.js +0 -13
- package/lib/cjs/DropDownList/AsyncDropDownList.d.ts +0 -6
- package/lib/cjs/DropDownList/AsyncDropDownList.d.ts.map +0 -1
- package/lib/cjs/DropDownList/AsyncDropDownList.js +0 -10
- package/lib/cjs/DropDownList/DropDownList.d.ts +0 -8
- package/lib/cjs/DropDownList/DropDownList.d.ts.map +0 -1
- package/lib/cjs/DropDownList/DropDownList.js +0 -141
- package/lib/cjs/DropDownList/DropdownWrapper.d.ts +0 -16
- package/lib/cjs/DropDownList/DropdownWrapper.d.ts.map +0 -1
- package/lib/cjs/DropDownList/DropdownWrapper.js +0 -25
- package/lib/cjs/DropDownList/MultiSelectDropdownList.d.ts +0 -4
- package/lib/cjs/DropDownList/MultiSelectDropdownList.d.ts.map +0 -1
- package/lib/cjs/DropDownList/MultiSelectDropdownList.js +0 -7
- package/lib/cjs/DropDownList/Readme.md +0 -114
- package/lib/cjs/DropDownList/SearchableList.d.ts +0 -14
- package/lib/cjs/DropDownList/SearchableList.d.ts.map +0 -1
- package/lib/cjs/DropDownList/SearchableList.js +0 -104
- package/lib/cjs/DropDownList/SelectList.d.ts +0 -11
- package/lib/cjs/DropDownList/SelectList.d.ts.map +0 -1
- package/lib/cjs/DropDownList/SelectList.js +0 -41
- package/lib/cjs/DropDownList/async.d.ts +0 -9
- package/lib/cjs/DropDownList/async.d.ts.map +0 -1
- package/lib/cjs/DropDownList/async.js +0 -138
- package/lib/cjs/DropDownList/dropdownList.css +0 -54
- package/lib/cjs/DropDownList/dropdownUtils.d.ts +0 -5
- package/lib/cjs/DropDownList/dropdownUtils.d.ts.map +0 -1
- package/lib/cjs/DropDownList/dropdownUtils.js +0 -29
- package/lib/cjs/DropDownList/index.d.ts +0 -4
- package/lib/cjs/DropDownList/index.d.ts.map +0 -1
- package/lib/cjs/DropDownList/index.js +0 -15
- package/lib/cjs/DropDownList/types.d.ts +0 -54
- package/lib/cjs/DropDownList/types.d.ts.map +0 -1
- package/lib/cjs/DropDownList/types.js +0 -2
- package/lib/cjs/DropDownList/withMulti.d.ts +0 -5
- package/lib/cjs/DropDownList/withMulti.d.ts.map +0 -1
- package/lib/cjs/DropDownList/withMulti.js +0 -69
- package/lib/cjs/ErrorBoundary/ErrorBoundary.d.ts +0 -36
- package/lib/cjs/ErrorBoundary/ErrorBoundary.d.ts.map +0 -1
- package/lib/cjs/ErrorBoundary/ErrorBoundary.js +0 -62
- package/lib/cjs/ErrorBoundary/ErrorBoundaryFallbackComponent.d.ts +0 -14
- package/lib/cjs/ErrorBoundary/ErrorBoundaryFallbackComponent.d.ts.map +0 -1
- package/lib/cjs/ErrorBoundary/ErrorBoundaryFallbackComponent.js +0 -40
- package/lib/cjs/ErrorBoundary/index.d.ts +0 -2
- package/lib/cjs/ErrorBoundary/index.d.ts.map +0 -1
- package/lib/cjs/ErrorBoundary/index.js +0 -13
- package/lib/cjs/ErrorPages/Generic403.d.ts +0 -2
- package/lib/cjs/ErrorPages/Generic403.d.ts.map +0 -1
- package/lib/cjs/ErrorPages/Generic403.js +0 -14
- package/lib/cjs/ErrorPages/index.d.ts +0 -2
- package/lib/cjs/ErrorPages/index.d.ts.map +0 -1
- package/lib/cjs/ErrorPages/index.js +0 -13
- package/lib/cjs/FeedbackForm/FeedbackForm.d.ts +0 -11
- package/lib/cjs/FeedbackForm/FeedbackForm.d.ts.map +0 -1
- package/lib/cjs/FeedbackForm/FeedbackForm.js +0 -140
- package/lib/cjs/FeedbackForm/index.d.ts +0 -2
- package/lib/cjs/FeedbackForm/index.d.ts.map +0 -1
- package/lib/cjs/FeedbackForm/index.js +0 -13
- package/lib/cjs/Functional/CaseContactsSelectorExternal.d.ts +0 -30
- package/lib/cjs/Functional/CaseContactsSelectorExternal.d.ts.map +0 -1
- package/lib/cjs/Functional/CaseContactsSelectorExternal.js +0 -223
- package/lib/cjs/Functional/index.d.ts +0 -2
- package/lib/cjs/Functional/index.d.ts.map +0 -1
- package/lib/cjs/Functional/index.js +0 -13
- package/lib/cjs/InlineEdit/InlineEdit.d.ts +0 -37
- package/lib/cjs/InlineEdit/InlineEdit.d.ts.map +0 -1
- package/lib/cjs/InlineEdit/InlineEdit.js +0 -169
- package/lib/cjs/InlineEdit/NewInlineEdit.d.ts +0 -41
- package/lib/cjs/InlineEdit/NewInlineEdit.d.ts.map +0 -1
- package/lib/cjs/InlineEdit/NewInlineEdit.js +0 -178
- package/lib/cjs/InlineEdit/index.d.ts +0 -3
- package/lib/cjs/InlineEdit/index.d.ts.map +0 -1
- package/lib/cjs/InlineEdit/index.js +0 -14
- package/lib/cjs/InlineEdit/inlineEdit.css +0 -29
- package/lib/cjs/InlineEdit/newInlineEdit.css +0 -44
- package/lib/cjs/LanguageSelector/LanguageSelector.d.ts +0 -25
- package/lib/cjs/LanguageSelector/LanguageSelector.d.ts.map +0 -1
- package/lib/cjs/LanguageSelector/LanguageSelector.js +0 -61
- package/lib/cjs/LanguageSelector/index.d.ts +0 -2
- package/lib/cjs/LanguageSelector/index.d.ts.map +0 -1
- package/lib/cjs/LanguageSelector/index.js +0 -13
- package/lib/cjs/LanguageSelector/languageSelector.css +0 -5
- package/lib/cjs/LoadingDots/LoadingDots.css +0 -33
- package/lib/cjs/LoadingDots/LoadingDots.d.ts +0 -11
- package/lib/cjs/LoadingDots/LoadingDots.d.ts.map +0 -1
- package/lib/cjs/LoadingDots/LoadingDots.js +0 -25
- package/lib/cjs/LoadingDots/index.d.ts +0 -2
- package/lib/cjs/LoadingDots/index.d.ts.map +0 -1
- package/lib/cjs/LoadingDots/index.js +0 -14
- package/lib/cjs/LoadingIndicator/LoadingIndicator.d.ts +0 -14
- package/lib/cjs/LoadingIndicator/LoadingIndicator.d.ts.map +0 -1
- package/lib/cjs/LoadingIndicator/LoadingIndicator.js +0 -25
- package/lib/cjs/LoadingIndicator/index.d.ts +0 -2
- package/lib/cjs/LoadingIndicator/index.d.ts.map +0 -1
- package/lib/cjs/LoadingIndicator/index.js +0 -13
- package/lib/cjs/LoadingIndicator/loadingIndicator.css +0 -79
- package/lib/cjs/LoginModal/LoginModal.d.ts +0 -14
- package/lib/cjs/LoginModal/LoginModal.d.ts.map +0 -1
- package/lib/cjs/LoginModal/LoginModal.js +0 -21
- package/lib/cjs/LoginModal/index.d.ts +0 -2
- package/lib/cjs/LoginModal/index.d.ts.map +0 -1
- package/lib/cjs/LoginModal/index.js +0 -13
- package/lib/cjs/MarkdownEditor/MarkdownEditor.d.ts +0 -45
- package/lib/cjs/MarkdownEditor/MarkdownEditor.d.ts.map +0 -1
- package/lib/cjs/MarkdownEditor/MarkdownEditor.js +0 -437
- package/lib/cjs/MarkdownEditor/index.d.ts +0 -2
- package/lib/cjs/MarkdownEditor/index.d.ts.map +0 -1
- package/lib/cjs/MarkdownEditor/index.js +0 -13
- package/lib/cjs/MarkdownEditor/markdownEditor.css +0 -111
- package/lib/cjs/MoreOrLess/MoreOrLess.d.ts +0 -13
- package/lib/cjs/MoreOrLess/MoreOrLess.d.ts.map +0 -1
- package/lib/cjs/MoreOrLess/MoreOrLess.js +0 -71
- package/lib/cjs/MoreOrLess/index.d.ts +0 -2
- package/lib/cjs/MoreOrLess/index.d.ts.map +0 -1
- package/lib/cjs/MoreOrLess/index.js +0 -13
- package/lib/cjs/PaginatedList/PaginatedList.d.ts +0 -18
- package/lib/cjs/PaginatedList/PaginatedList.d.ts.map +0 -1
- package/lib/cjs/PaginatedList/PaginatedList.js +0 -63
- package/lib/cjs/PaginatedList/index.d.ts +0 -2
- package/lib/cjs/PaginatedList/index.d.ts.map +0 -1
- package/lib/cjs/PaginatedList/index.js +0 -13
- package/lib/cjs/PaginationCompact/PaginationCompact.d.ts +0 -9
- package/lib/cjs/PaginationCompact/PaginationCompact.d.ts.map +0 -1
- package/lib/cjs/PaginationCompact/PaginationCompact.js +0 -63
- package/lib/cjs/PaginationCompact/index.d.ts +0 -2
- package/lib/cjs/PaginationCompact/index.d.ts.map +0 -1
- package/lib/cjs/PaginationCompact/index.js +0 -13
- package/lib/cjs/PaginationCompact/paginationCompact.css +0 -5
- package/lib/cjs/PhoneInput/CountryData.d.ts +0 -3
- package/lib/cjs/PhoneInput/CountryData.d.ts.map +0 -1
- package/lib/cjs/PhoneInput/CountryData.js +0 -583
- package/lib/cjs/PhoneInput/PhoneInput.d.ts +0 -19
- package/lib/cjs/PhoneInput/PhoneInput.d.ts.map +0 -1
- package/lib/cjs/PhoneInput/PhoneInput.js +0 -286
- package/lib/cjs/PhoneInput/PhoneInput.scss +0 -753
- package/lib/cjs/PhoneInput/flags.png +0 -0
- package/lib/cjs/PhoneInput/index.d.ts +0 -2
- package/lib/cjs/PhoneInput/index.d.ts.map +0 -1
- package/lib/cjs/PhoneInput/index.js +0 -13
- package/lib/cjs/ProgressBar/CircularProgressBar/CircularProgressBar.d.ts +0 -8
- package/lib/cjs/ProgressBar/CircularProgressBar/CircularProgressBar.d.ts.map +0 -1
- package/lib/cjs/ProgressBar/CircularProgressBar/CircularProgressBar.js +0 -68
- package/lib/cjs/ProgressBar/CircularProgressBar/Path.d.ts +0 -12
- package/lib/cjs/ProgressBar/CircularProgressBar/Path.d.ts.map +0 -1
- package/lib/cjs/ProgressBar/CircularProgressBar/Path.js +0 -39
- package/lib/cjs/ProgressBar/CircularProgressBar/constants.d.ts +0 -6
- package/lib/cjs/ProgressBar/CircularProgressBar/constants.d.ts.map +0 -1
- package/lib/cjs/ProgressBar/CircularProgressBar/constants.js +0 -8
- package/lib/cjs/ProgressBar/CircularProgressBar/index.d.ts +0 -2
- package/lib/cjs/ProgressBar/CircularProgressBar/index.d.ts.map +0 -1
- package/lib/cjs/ProgressBar/CircularProgressBar/index.js +0 -13
- package/lib/cjs/ProgressBar/CircularProgressBar/styles.css +0 -60
- package/lib/cjs/ProgressBar/CircularProgressBar/types.d.ts +0 -32
- package/lib/cjs/ProgressBar/CircularProgressBar/types.d.ts.map +0 -1
- package/lib/cjs/ProgressBar/CircularProgressBar/types.js +0 -2
- package/lib/cjs/ProgressBar/ProgressBar.d.ts +0 -15
- package/lib/cjs/ProgressBar/ProgressBar.d.ts.map +0 -1
- package/lib/cjs/ProgressBar/ProgressBar.js +0 -36
- package/lib/cjs/ProgressBar/index.d.ts +0 -3
- package/lib/cjs/ProgressBar/index.d.ts.map +0 -1
- package/lib/cjs/ProgressBar/index.js +0 -14
- package/lib/cjs/PromisifyModal/PromisifyModal.d.ts +0 -18
- package/lib/cjs/PromisifyModal/PromisifyModal.d.ts.map +0 -1
- package/lib/cjs/PromisifyModal/PromisifyModal.js +0 -40
- package/lib/cjs/PromisifyModal/index.d.ts +0 -2
- package/lib/cjs/PromisifyModal/index.d.ts.map +0 -1
- package/lib/cjs/PromisifyModal/index.js +0 -13
- package/lib/cjs/SubscriptionAbuse/SubscriptionAbuseModal.d.ts +0 -7
- package/lib/cjs/SubscriptionAbuse/SubscriptionAbuseModal.d.ts.map +0 -1
- package/lib/cjs/SubscriptionAbuse/SubscriptionAbuseModal.js +0 -20
- package/lib/cjs/SubscriptionAbuse/const.d.ts +0 -4
- package/lib/cjs/SubscriptionAbuse/const.d.ts.map +0 -1
- package/lib/cjs/SubscriptionAbuse/const.js +0 -15
- package/lib/cjs/SubscriptionAbuse/index.d.ts +0 -3
- package/lib/cjs/SubscriptionAbuse/index.d.ts.map +0 -1
- package/lib/cjs/SubscriptionAbuse/index.js +0 -14
- package/lib/cjs/SupportFeedbackForm/SupportFeedbackForm.d.ts +0 -11
- package/lib/cjs/SupportFeedbackForm/SupportFeedbackForm.d.ts.map +0 -1
- package/lib/cjs/SupportFeedbackForm/SupportFeedbackForm.js +0 -44
- package/lib/cjs/SupportFeedbackForm/SupportFeedbackModal.d.ts +0 -10
- package/lib/cjs/SupportFeedbackForm/SupportFeedbackModal.d.ts.map +0 -1
- package/lib/cjs/SupportFeedbackForm/SupportFeedbackModal.js +0 -178
- package/lib/cjs/SupportFeedbackForm/index.d.ts +0 -3
- package/lib/cjs/SupportFeedbackForm/index.d.ts.map +0 -1
- package/lib/cjs/SupportFeedbackForm/index.js +0 -14
- package/lib/cjs/Table/PFTable.d.ts +0 -39
- package/lib/cjs/Table/PFTable.d.ts.map +0 -1
- package/lib/cjs/Table/PFTable.js +0 -204
- package/lib/cjs/Table/README.md +0 -65
- package/lib/cjs/Table/Table.d.ts.map +0 -1
- package/lib/cjs/Table/Table.js +0 -38
- package/lib/cjs/Table/TableColumnSelector.d.ts +0 -7
- package/lib/cjs/Table/TableColumnSelector.d.ts.map +0 -1
- package/lib/cjs/Table/TableColumnSelector.js +0 -34
- package/lib/cjs/Table/TablePagination.d.ts +0 -18
- package/lib/cjs/Table/TablePagination.d.ts.map +0 -1
- package/lib/cjs/Table/TablePagination.js +0 -44
- package/lib/cjs/Table/TableProvider.d.ts +0 -15
- package/lib/cjs/Table/TableProvider.d.ts.map +0 -1
- package/lib/cjs/Table/TableProvider.js +0 -25
- package/lib/cjs/Table/columnSelector.css +0 -37
- package/lib/cjs/Table/index.d.ts +0 -5
- package/lib/cjs/Table/index.d.ts.map +0 -1
- package/lib/cjs/Table/index.js +0 -16
- package/lib/cjs/TermsAndConditions/AcceptTermsModal.d.ts +0 -14
- package/lib/cjs/TermsAndConditions/AcceptTermsModal.d.ts.map +0 -1
- package/lib/cjs/TermsAndConditions/AcceptTermsModal.js +0 -116
- package/lib/cjs/TermsAndConditions/index.d.ts +0 -2
- package/lib/cjs/TermsAndConditions/index.d.ts.map +0 -1
- package/lib/cjs/TermsAndConditions/index.js +0 -13
- package/lib/cjs/TextAreaAutosize/TextAreaAutosize.d.ts +0 -8
- package/lib/cjs/TextAreaAutosize/TextAreaAutosize.d.ts.map +0 -1
- package/lib/cjs/TextAreaAutosize/TextAreaAutosize.js +0 -136
- package/lib/cjs/TextAreaAutosize/index.d.ts +0 -2
- package/lib/cjs/TextAreaAutosize/index.d.ts.map +0 -1
- package/lib/cjs/TextAreaAutosize/index.js +0 -13
- package/lib/cjs/TextAreaResizable/TextAreaResizable.d.ts +0 -20
- package/lib/cjs/TextAreaResizable/TextAreaResizable.d.ts.map +0 -1
- package/lib/cjs/TextAreaResizable/TextAreaResizable.js +0 -56
- package/lib/cjs/TextAreaResizable/index.d.ts +0 -2
- package/lib/cjs/TextAreaResizable/index.d.ts.map +0 -1
- package/lib/cjs/TextAreaResizable/index.js +0 -13
- package/lib/cjs/ToastNotification/ToastNotification.d.ts +0 -28
- package/lib/cjs/ToastNotification/ToastNotification.d.ts.map +0 -1
- package/lib/cjs/ToastNotification/ToastNotification.js +0 -63
- package/lib/cjs/ToastNotification/index.d.ts +0 -2
- package/lib/cjs/ToastNotification/index.d.ts.map +0 -1
- package/lib/cjs/ToastNotification/index.js +0 -13
- package/lib/cjs/ToastNotification/toastNotification.css +0 -22
- package/lib/cjs/TopContentSearch/TopContentSearch.d.ts +0 -14
- package/lib/cjs/TopContentSearch/TopContentSearch.d.ts.map +0 -1
- package/lib/cjs/TopContentSearch/TopContentSearch.js +0 -138
- package/lib/cjs/TopContentSearch/index.d.ts +0 -2
- package/lib/cjs/TopContentSearch/index.d.ts.map +0 -1
- package/lib/cjs/TopContentSearch/index.js +0 -13
- package/lib/cjs/TopContentSearch/topContentSearch.scss +0 -22
- package/lib/cjs/ValueChangedIcon/ValueChangedIcon.d.ts +0 -14
- package/lib/cjs/ValueChangedIcon/ValueChangedIcon.d.ts.map +0 -1
- package/lib/cjs/ValueChangedIcon/ValueChangedIcon.js +0 -76
- package/lib/cjs/ValueChangedIcon/index.d.ts +0 -2
- package/lib/cjs/ValueChangedIcon/index.d.ts.map +0 -1
- package/lib/cjs/ValueChangedIcon/index.js +0 -13
- package/lib/cjs/helperFunctions/errorMessage.d.ts +0 -12
- package/lib/cjs/helperFunctions/errorMessage.d.ts.map +0 -1
- package/lib/cjs/helperFunctions/errorMessage.js +0 -95
- package/lib/cjs/helperFunctions/errorMessage.scss +0 -3
- package/lib/cjs/helperFunctions/index.d.ts +0 -2
- package/lib/cjs/helperFunctions/index.d.ts.map +0 -1
- package/lib/cjs/helperFunctions/index.js +0 -13
- package/lib/cjs/hooks/index.d.ts +0 -14
- package/lib/cjs/hooks/index.d.ts.map +0 -1
- package/lib/cjs/hooks/index.js +0 -25
- package/lib/cjs/hooks/useBreakpoint.d.ts +0 -12
- package/lib/cjs/hooks/useBreakpoint.d.ts.map +0 -1
- package/lib/cjs/hooks/useBreakpoint.js +0 -86
- package/lib/cjs/hooks/useCopyToClipboard.d.ts +0 -6
- package/lib/cjs/hooks/useCopyToClipboard.d.ts.map +0 -1
- package/lib/cjs/hooks/useCopyToClipboard.js +0 -39
- package/lib/cjs/hooks/useDebounce.d.ts +0 -9
- package/lib/cjs/hooks/useDebounce.d.ts.map +0 -1
- package/lib/cjs/hooks/useDebounce.js +0 -40
- package/lib/cjs/hooks/useFetch.d.ts +0 -20
- package/lib/cjs/hooks/useFetch.d.ts.map +0 -1
- package/lib/cjs/hooks/useFetch.js +0 -71
- package/lib/cjs/hooks/useForceUpdate.d.ts +0 -18
- package/lib/cjs/hooks/useForceUpdate.d.ts.map +0 -1
- package/lib/cjs/hooks/useForceUpdate.js +0 -28
- package/lib/cjs/hooks/useForkRef.d.ts +0 -2
- package/lib/cjs/hooks/useForkRef.d.ts.map +0 -1
- package/lib/cjs/hooks/useForkRef.js +0 -29
- package/lib/cjs/hooks/useIsMounted.d.ts +0 -3
- package/lib/cjs/hooks/useIsMounted.d.ts.map +0 -1
- package/lib/cjs/hooks/useIsMounted.js +0 -18
- package/lib/cjs/hooks/useLRUCache.d.ts +0 -8
- package/lib/cjs/hooks/useLRUCache.d.ts.map +0 -1
- package/lib/cjs/hooks/useLRUCache.js +0 -28
- package/lib/cjs/hooks/useLocalStorage.d.ts +0 -5
- package/lib/cjs/hooks/useLocalStorage.d.ts.map +0 -1
- package/lib/cjs/hooks/useLocalStorage.js +0 -39
- package/lib/cjs/hooks/useOnScreen.d.ts +0 -2
- package/lib/cjs/hooks/useOnScreen.d.ts.map +0 -1
- package/lib/cjs/hooks/useOnScreen.js +0 -18
- package/lib/cjs/hooks/usePolling.d.ts +0 -2
- package/lib/cjs/hooks/usePolling.d.ts.map +0 -1
- package/lib/cjs/hooks/usePolling.js +0 -19
- package/lib/cjs/hooks/usePrevious.d.ts +0 -2
- package/lib/cjs/hooks/usePrevious.d.ts.map +0 -1
- package/lib/cjs/hooks/usePrevious.js +0 -12
- package/lib/cjs/hooks/useTitle.d.ts +0 -2
- package/lib/cjs/hooks/useTitle.d.ts.map +0 -1
- package/lib/cjs/hooks/useTitle.js +0 -14
- package/lib/cjs/hooks/useUndo.d.ts +0 -22
- package/lib/cjs/hooks/useUndo.d.ts.map +0 -1
- package/lib/cjs/hooks/useUndo.js +0 -76
- package/lib/cjs/index.d.ts +0 -34
- package/lib/cjs/index.d.ts.map +0 -1
- package/lib/cjs/index.js +0 -45
- package/lib/esm/PhoneInput/flags.png +0 -0
- package/lib/esm/Table/Table.d.ts +0 -11
- package/lib/esm/Table/Table.d.ts.map +0 -1
- package/lib/esm/Table/TableColumnSelector.d.ts +0 -7
- package/lib/esm/Table/TableColumnSelector.d.ts.map +0 -1
- package/lib/esm/Table/TableColumnSelector.js +0 -27
- package/lib/esm/Table/columnSelector.css +0 -37
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
-
}) : function(o, v) {
|
|
12
|
-
o["default"] = v;
|
|
13
|
-
});
|
|
14
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
-
if (mod && mod.__esModule) return mod;
|
|
16
|
-
var result = {};
|
|
17
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
-
__setModuleDefault(result, mod);
|
|
19
|
-
return result;
|
|
20
|
-
};
|
|
21
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
|
-
exports.TablePagination = void 0;
|
|
23
|
-
const react_core_1 = require("@patternfly/react-core");
|
|
24
|
-
const react_1 = __importStar(require("react"));
|
|
25
|
-
const TableProvider_1 = require("./TableProvider");
|
|
26
|
-
function TablePagination(props) {
|
|
27
|
-
const { data, setSelectedPage, setPerPage, perPage, currentPage } = TableProvider_1.useTableContext();
|
|
28
|
-
const onSetPage = (event, pageNumber) => {
|
|
29
|
-
setSelectedPage(pageNumber);
|
|
30
|
-
props.onSetPage && props.onSetPage({ pageSize: perPage, currentPage: pageNumber });
|
|
31
|
-
};
|
|
32
|
-
const onPerPageSelect = (event, pageSize) => {
|
|
33
|
-
setSelectedPage(1);
|
|
34
|
-
setPerPage(pageSize);
|
|
35
|
-
props.onPerPageSelect && props.onPerPageSelect({ pageSize, currentPage: 1 });
|
|
36
|
-
};
|
|
37
|
-
react_1.useEffect(() => {
|
|
38
|
-
props.perPage && props.perPage !== perPage && setPerPage(props.perPage);
|
|
39
|
-
props.currentPage && props.currentPage !== currentPage && setSelectedPage(props.currentPage);
|
|
40
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
41
|
-
}, [props.perPage, props.currentPage]);
|
|
42
|
-
return (react_1.default.createElement(react_core_1.Pagination, { itemCount: props.itemCount || (data || []).length, widgetId: "pagination-options-menu-top", perPage: perPage, page: currentPage, variant: props.variant, onSetPage: onSetPage, onPerPageSelect: onPerPageSelect }));
|
|
43
|
-
}
|
|
44
|
-
exports.TablePagination = TablePagination;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { IColumn } from './PFTable';
|
|
3
|
-
interface ITableContext {
|
|
4
|
-
columns: IColumn[];
|
|
5
|
-
data: any;
|
|
6
|
-
currentPage: number;
|
|
7
|
-
perPage: number;
|
|
8
|
-
setSelectedPage: React.Dispatch<React.SetStateAction<number>>;
|
|
9
|
-
setPerPage: React.Dispatch<React.SetStateAction<number>>;
|
|
10
|
-
selectedColumns: string[];
|
|
11
|
-
}
|
|
12
|
-
export declare const TableContext: React.Context<ITableContext>;
|
|
13
|
-
export declare function useTableContext(): ITableContext;
|
|
14
|
-
export {};
|
|
15
|
-
//# sourceMappingURL=TableProvider.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TableProvider.d.ts","sourceRoot":"","sources":["../../../src/Table/TableProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,UAAU,aAAa;IACnB,OAAO,EAAE,OAAO,EAAE,CAAC;IACnB,IAAI,EAAE,GAAG,CAAC;IACV,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;IAChB,eAAe,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,CAAC;IAC9D,UAAU,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,CAAC;IACzD,eAAe,EAAE,MAAM,EAAE,CAAC;CAC7B;AAYD,eAAO,MAAM,YAAY,8BAAyD,CAAC;AAEnF,wBAAgB,eAAe,kBAM9B"}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.useTableContext = exports.TableContext = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
|
-
const intialTableContext = {
|
|
9
|
-
columns: [],
|
|
10
|
-
data: [],
|
|
11
|
-
currentPage: 1,
|
|
12
|
-
perPage: 10,
|
|
13
|
-
setSelectedPage: () => { },
|
|
14
|
-
setPerPage: () => { },
|
|
15
|
-
selectedColumns: [],
|
|
16
|
-
};
|
|
17
|
-
exports.TableContext = react_1.default.createContext(intialTableContext);
|
|
18
|
-
function useTableContext() {
|
|
19
|
-
const context = react_1.default.useContext(exports.TableContext);
|
|
20
|
-
if (context === undefined) {
|
|
21
|
-
throw new Error(`useTableContext must be used within a TableProvider`);
|
|
22
|
-
}
|
|
23
|
-
return context;
|
|
24
|
-
}
|
|
25
|
-
exports.useTableContext = useTableContext;
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
.downshift .column-selector-menu {
|
|
2
|
-
box-shadow: rgba(3, 5, 3, 0.05) 1px 1px 1px 0px, rgba(3, 3, 3, 0.06) 1px 4px 8px 6px;
|
|
3
|
-
max-height: 250px;
|
|
4
|
-
left: unset;
|
|
5
|
-
border-color: #d1d1d1;
|
|
6
|
-
position: absolute;
|
|
7
|
-
top: 100%;
|
|
8
|
-
z-index: 10;
|
|
9
|
-
display: -ms-grid;
|
|
10
|
-
display: grid;
|
|
11
|
-
-ms-grid-columns: 1fr 1fr;
|
|
12
|
-
grid-template-columns: 1fr 1fr;
|
|
13
|
-
grid-gap: 6px;
|
|
14
|
-
margin: 4px 0 0;
|
|
15
|
-
list-style-type: none;
|
|
16
|
-
background-color: #fff;
|
|
17
|
-
min-width: 410px;
|
|
18
|
-
overflow: auto;
|
|
19
|
-
padding: 10px 4px;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
.downshift .column-selector-menu li:hover:not([disabled]) label {
|
|
23
|
-
cursor: pointer;
|
|
24
|
-
color: #06c;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.downshift .column-selector-menu li[disabled] {
|
|
28
|
-
cursor: not-allowed;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
button.pf-c-button.column-selector-btn::after {
|
|
32
|
-
border: none;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.downshift .column-selector-menu li label {
|
|
36
|
-
font-weight: 400;
|
|
37
|
-
}
|
package/lib/cjs/Table/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Table/index.tsx"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC"}
|
package/lib/cjs/Table/index.js
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
__exportStar(require("./Table"), exports);
|
|
14
|
-
__exportStar(require("./PFTable"), exports);
|
|
15
|
-
__exportStar(require("./TableColumnSelector"), exports);
|
|
16
|
-
__exportStar(require("./TablePagination"), exports);
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
interface IProps {
|
|
2
|
-
isModalOpen: boolean;
|
|
3
|
-
onModalClose: () => void;
|
|
4
|
-
onConfirm: (pdfId: string) => Promise<void>;
|
|
5
|
-
isSubmitting?: boolean;
|
|
6
|
-
siteCode: string;
|
|
7
|
-
eventCode: string;
|
|
8
|
-
loggedInUser: string;
|
|
9
|
-
dataTrackingId?: string;
|
|
10
|
-
isDisabled?: boolean;
|
|
11
|
-
}
|
|
12
|
-
export declare function AcceptTermsModal(props: IProps): JSX.Element;
|
|
13
|
-
export {};
|
|
14
|
-
//# sourceMappingURL=AcceptTermsModal.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AcceptTermsModal.d.ts","sourceRoot":"","sources":["../../../src/TermsAndConditions/AcceptTermsModal.tsx"],"names":[],"mappings":"AAmBA,UAAU,MAAM;IACZ,WAAW,EAAE,OAAO,CAAC;IACrB,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,SAAS,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAC5C,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;IACrB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,UAAU,CAAC,EAAE,OAAO,CAAC;CACxB;AAiBD,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,eAyI7C"}
|
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
-
}) : function(o, v) {
|
|
12
|
-
o["default"] = v;
|
|
13
|
-
});
|
|
14
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
-
if (mod && mod.__esModule) return mod;
|
|
16
|
-
var result = {};
|
|
17
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
-
__setModuleDefault(result, mod);
|
|
19
|
-
return result;
|
|
20
|
-
};
|
|
21
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
22
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
23
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
24
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
25
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
26
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
27
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
28
|
-
});
|
|
29
|
-
};
|
|
30
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
31
|
-
exports.AcceptTermsModal = void 0;
|
|
32
|
-
const hydrajs_1 = require("@cee-eng/hydrajs");
|
|
33
|
-
const react_core_1 = require("@patternfly/react-core");
|
|
34
|
-
const react_1 = __importStar(require("react"));
|
|
35
|
-
const react_i18next_1 = require("react-i18next");
|
|
36
|
-
const hooks_1 = require("../hooks");
|
|
37
|
-
const LoadingIndicator_1 = require("../LoadingIndicator");
|
|
38
|
-
const getLocaleNameFromLocalCode = (localeCode) => {
|
|
39
|
-
if ('Intl' in window && 'DisplayNames' in Intl) {
|
|
40
|
-
try {
|
|
41
|
-
const [lang, locale] = localeCode.includes('_') ? localeCode.split('_') : localeCode.split('-');
|
|
42
|
-
// https://github.com/microsoft/TypeScript/issues/41338
|
|
43
|
-
const langName = new Intl.DisplayNames([lang], { type: 'language' });
|
|
44
|
-
const regionNamesInLang = new Intl.DisplayNames([lang], { type: 'region' });
|
|
45
|
-
return `${regionNamesInLang.of(locale)} (${langName.of(lang)})`;
|
|
46
|
-
}
|
|
47
|
-
catch (e) {
|
|
48
|
-
return localeCode;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
return localeCode;
|
|
52
|
-
};
|
|
53
|
-
function AcceptTermsModal(props) {
|
|
54
|
-
const { request, isFetching } = hooks_1.useFetch(hydrajs_1.publicApi.terms.getRequiredTerms);
|
|
55
|
-
const [termsAcked, setTermsAcked] = react_1.useState(false);
|
|
56
|
-
const [allTranslations, setAllTranslations] = react_1.useState({});
|
|
57
|
-
const [isLangSelectorDropdownOpen, setisLangSelectorDropdownOpen] = react_1.useState(false);
|
|
58
|
-
const [selectedTranslation, setSelectedTranslation] = react_1.useState(null);
|
|
59
|
-
const { t } = react_i18next_1.useTranslation();
|
|
60
|
-
react_1.useEffect(() => {
|
|
61
|
-
const fetchTerms = () => __awaiter(this, void 0, void 0, function* () {
|
|
62
|
-
var _a, _b, _c, _d;
|
|
63
|
-
try {
|
|
64
|
-
const { siteCode, eventCode, loggedInUser } = props;
|
|
65
|
-
const response = yield request(siteCode, eventCode, loggedInUser);
|
|
66
|
-
let defaultTranslation = (_b = (_a = response === null || response === void 0 ? void 0 : response[0]) === null || _a === void 0 ? void 0 : _a.translations) === null || _b === void 0 ? void 0 : _b[0];
|
|
67
|
-
const translationLangInfoMap = (_d = (_c = response === null || response === void 0 ? void 0 : response[0]) === null || _c === void 0 ? void 0 : _c.translations) === null || _d === void 0 ? void 0 : _d.reduce((allTranslationsmap, translation) => {
|
|
68
|
-
if (translation.isDefault) {
|
|
69
|
-
defaultTranslation = translation;
|
|
70
|
-
}
|
|
71
|
-
allTranslationsmap[translation['localeCode']] = translation;
|
|
72
|
-
return allTranslationsmap;
|
|
73
|
-
}, {});
|
|
74
|
-
setSelectedTranslation(defaultTranslation);
|
|
75
|
-
setAllTranslations(translationLangInfoMap);
|
|
76
|
-
}
|
|
77
|
-
catch (e) {
|
|
78
|
-
console.log(e);
|
|
79
|
-
}
|
|
80
|
-
});
|
|
81
|
-
fetchTerms();
|
|
82
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
83
|
-
}, []);
|
|
84
|
-
const onLangChange = (event, lang) => {
|
|
85
|
-
setSelectedTranslation(allTranslations[lang]);
|
|
86
|
-
setisLangSelectorDropdownOpen(false);
|
|
87
|
-
};
|
|
88
|
-
const handleModalToggle = () => {
|
|
89
|
-
!props.isDisabled && props.onModalClose();
|
|
90
|
-
};
|
|
91
|
-
const onSubmitClick = () => {
|
|
92
|
-
props.onConfirm(selectedTranslation.termsPdfId);
|
|
93
|
-
};
|
|
94
|
-
const onDropdownToggle = (toggle) => setisLangSelectorDropdownOpen(toggle);
|
|
95
|
-
return (react_1.default.createElement(react_core_1.Modal, { variant: react_core_1.ModalVariant.medium, className: "pf-u-font-size-sm", title: isFetching || !selectedTranslation ? 'Remote Access Rider' : selectedTranslation.translatedTermsName, isOpen: props.isModalOpen, showClose: props.isSubmitting ? false : true, onClose: handleModalToggle, actions: [
|
|
96
|
-
react_1.default.createElement(react_core_1.Button, { key: "confirm", variant: react_core_1.ButtonVariant.primary, isDisabled: !termsAcked || props.isSubmitting || props.isDisabled, isLoading: props.isDisabled || props.isSubmitting, "data-tracking-id": `${props.dataTrackingId || props.eventCode}-terms-accept`, onClick: onSubmitClick },
|
|
97
|
-
react_1.default.createElement(react_i18next_1.Trans, null, "Submit")),
|
|
98
|
-
react_1.default.createElement(react_core_1.Button, { key: "cancel", isDisabled: props.isSubmitting || props.isDisabled, "data-tracking-id": `${props.dataTrackingId || props.eventCode}-terms-cancel`, variant: react_core_1.ButtonVariant.link, onClick: props.onModalClose },
|
|
99
|
-
react_1.default.createElement(react_i18next_1.Trans, null, "Cancel")),
|
|
100
|
-
] }, isFetching || !selectedTranslation ? (react_1.default.createElement("div", { style: { height: '100px' } },
|
|
101
|
-
react_1.default.createElement(LoadingIndicator_1.LoadingIndicator, null))) : (react_1.default.createElement(react_1.default.Fragment, null,
|
|
102
|
-
react_1.default.createElement("p", { className: "pf-u-mb-md" }, selectedTranslation.translatedDescription),
|
|
103
|
-
react_1.default.createElement("strong", null,
|
|
104
|
-
react_1.default.createElement(react_i18next_1.Trans, null, "Download the agreement")),
|
|
105
|
-
react_1.default.createElement("p", { className: "pf-u-mb-md pf-u-mt-sm" }, selectedTranslation.translatedInstructions),
|
|
106
|
-
react_1.default.createElement(react_core_1.Flex, null,
|
|
107
|
-
react_1.default.createElement(react_core_1.FlexItem, null,
|
|
108
|
-
react_1.default.createElement(react_core_1.Select, { "aria-label": t('Select language'), id: "terms-language-selector", className: "pf-u-mb-md", selections: selectedTranslation.localeCode, onSelect: onLangChange, isOpen: isLangSelectorDropdownOpen, isDisabled: props.isSubmitting, menuAppendTo: document.body, placeholderText: t('Select an option that best fits'), onToggle: onDropdownToggle }, Object.keys(allTranslations).map((option, index) => (react_1.default.createElement(react_core_1.SelectOption, { key: index, value: option }, getLocaleNameFromLocalCode(option)))))),
|
|
109
|
-
react_1.default.createElement(react_core_1.FlexItem, null,
|
|
110
|
-
react_1.default.createElement("a", { href: selectedTranslation.pdfDownloadUrl, "data-tracking-id": `${props.eventCode}-terms-download`, target: "_blank", rel: "noopener noreferrer" },
|
|
111
|
-
react_1.default.createElement(react_i18next_1.Trans, null, "Download")))),
|
|
112
|
-
react_1.default.createElement(react_core_1.Checkbox, { label: t('I have read and agree to the terms'), isChecked: termsAcked, onChange: (checked) => {
|
|
113
|
-
setTermsAcked(checked);
|
|
114
|
-
}, "aria-label": t('I have read and agree to the terms'), id: "agree-terms", name: "agree-terms" })))));
|
|
115
|
-
}
|
|
116
|
-
exports.AcceptTermsModal = AcceptTermsModal;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/TermsAndConditions/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
__exportStar(require("./AcceptTermsModal"), exports);
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import React, { HTMLProps } from 'react';
|
|
2
|
-
interface IProps extends Omit<HTMLProps<HTMLTextAreaElement>, 'css'> {
|
|
3
|
-
rowsMax?: number;
|
|
4
|
-
rowsMin?: number;
|
|
5
|
-
}
|
|
6
|
-
declare const TextAreaAutosize: React.ForwardRefExoticComponent<Pick<IProps, "size" | "className" | "cite" | "data" | "form" | "label" | "slot" | "span" | "style" | "summary" | "title" | "pattern" | "children" | "action" | "accept" | "acceptCharset" | "allowFullScreen" | "allowTransparency" | "alt" | "as" | "async" | "autoComplete" | "autoFocus" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "checked" | "classID" | "cols" | "colSpan" | "content" | "controls" | "coords" | "crossOrigin" | "dateTime" | "default" | "defer" | "disabled" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "height" | "high" | "href" | "hrefLang" | "htmlFor" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "list" | "loop" | "low" | "manifest" | "marginHeight" | "marginWidth" | "max" | "maxLength" | "media" | "mediaGroup" | "method" | "min" | "minLength" | "multiple" | "muted" | "name" | "nonce" | "noValidate" | "open" | "optimum" | "placeholder" | "playsInline" | "poster" | "preload" | "readOnly" | "rel" | "required" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "selected" | "shape" | "sizes" | "src" | "srcDoc" | "srcLang" | "srcSet" | "start" | "step" | "target" | "type" | "useMap" | "value" | "width" | "wmode" | "wrap" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "rowsMax" | "rowsMin"> & React.RefAttributes<unknown>>;
|
|
7
|
-
export { TextAreaAutosize };
|
|
8
|
-
//# sourceMappingURL=TextAreaAutosize.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TextAreaAutosize.d.ts","sourceRoot":"","sources":["../../../src/TextAreaAutosize/TextAreaAutosize.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAc,SAAS,EAA6D,MAAM,OAAO,CAAC;AAKhH,UAAU,MAAO,SAAQ,IAAI,CAAC,SAAS,CAAC,mBAAmB,CAAC,EAAE,KAAK,CAAC;IAChE,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AAWD,QAAA,MAAM,gBAAgB,o0LAyHpB,CAAC;AAGH,OAAO,EAAE,gBAAgB,EAAE,CAAC"}
|
|
@@ -1,136 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
-
}) : function(o, v) {
|
|
12
|
-
o["default"] = v;
|
|
13
|
-
});
|
|
14
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
-
if (mod && mod.__esModule) return mod;
|
|
16
|
-
var result = {};
|
|
17
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
-
__setModuleDefault(result, mod);
|
|
19
|
-
return result;
|
|
20
|
-
};
|
|
21
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
22
|
-
var t = {};
|
|
23
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
24
|
-
t[p] = s[p];
|
|
25
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
26
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
27
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
28
|
-
t[p[i]] = s[p[i]];
|
|
29
|
-
}
|
|
30
|
-
return t;
|
|
31
|
-
};
|
|
32
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
33
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
34
|
-
};
|
|
35
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.TextAreaAutosize = void 0;
|
|
37
|
-
const debounce_1 = __importDefault(require("lodash/debounce"));
|
|
38
|
-
const react_1 = __importStar(require("react"));
|
|
39
|
-
const useForkRef_1 = require("../hooks/useForkRef");
|
|
40
|
-
const defaultProps = {
|
|
41
|
-
rowsMax: 20,
|
|
42
|
-
rowsMin: 2,
|
|
43
|
-
};
|
|
44
|
-
function getStyleValue(computedStyle, property) {
|
|
45
|
-
return parseInt(computedStyle[property], 10) || 0;
|
|
46
|
-
}
|
|
47
|
-
const TextAreaAutosize = react_1.forwardRef((props, ref) => {
|
|
48
|
-
const { rowsMax, rowsMin } = props, rest = __rest(props, ["rowsMax", "rowsMin"]);
|
|
49
|
-
const { current: isControlled } = react_1.default.useRef(props.value != null);
|
|
50
|
-
const inputRef = react_1.useRef(null);
|
|
51
|
-
const handleRef = useForkRef_1.useForkRef(ref, inputRef);
|
|
52
|
-
const shadowRef = react_1.default.useRef(null);
|
|
53
|
-
const renders = react_1.default.useRef(0);
|
|
54
|
-
const [state, setState] = react_1.useState({
|
|
55
|
-
overflow: null,
|
|
56
|
-
outerHeightStyle: null,
|
|
57
|
-
});
|
|
58
|
-
const syncHeight = react_1.useCallback(() => {
|
|
59
|
-
const input = inputRef.current;
|
|
60
|
-
const computedStyle = window.getComputedStyle(input);
|
|
61
|
-
const inputShallow = shadowRef.current;
|
|
62
|
-
inputShallow.style.width = computedStyle.width;
|
|
63
|
-
inputShallow.value = input.value || 'x';
|
|
64
|
-
if (inputShallow.value.slice(-1) === '\n') {
|
|
65
|
-
// Certain fonts which overflow the line height will cause the textarea
|
|
66
|
-
// to report a different scrollHeight depending on whether the last line
|
|
67
|
-
// is empty. Make it non-empty to avoid this issue.
|
|
68
|
-
inputShallow.value += ' ';
|
|
69
|
-
}
|
|
70
|
-
const boxSizing = computedStyle['box-sizing'];
|
|
71
|
-
const padding = getStyleValue(computedStyle, 'padding-bottom') + getStyleValue(computedStyle, 'padding-top');
|
|
72
|
-
const border = getStyleValue(computedStyle, 'border-bottom-width') + getStyleValue(computedStyle, 'border-top-width');
|
|
73
|
-
// The height of the inner content
|
|
74
|
-
const innerHeight = inputShallow.scrollHeight - padding;
|
|
75
|
-
// Measure height of a textarea with a single row
|
|
76
|
-
inputShallow.value = 'x';
|
|
77
|
-
const singleRowHeight = inputShallow.scrollHeight - padding;
|
|
78
|
-
// The height of the outer content
|
|
79
|
-
let outerHeight = innerHeight;
|
|
80
|
-
if (props.rowsMin)
|
|
81
|
-
outerHeight = Math.max(Number(props.rowsMin) * singleRowHeight, outerHeight);
|
|
82
|
-
if (props.rowsMax)
|
|
83
|
-
outerHeight = Math.min(Number(props.rowsMax) * singleRowHeight, outerHeight);
|
|
84
|
-
outerHeight = Math.max(outerHeight, singleRowHeight);
|
|
85
|
-
// Take the box sizing into account for applying this value as a style.
|
|
86
|
-
const outerHeightStyle = outerHeight + (boxSizing === 'border-box' ? padding + border : 0);
|
|
87
|
-
const overflow = Math.abs(outerHeight - innerHeight) <= 1;
|
|
88
|
-
setState((prevState) => {
|
|
89
|
-
// Need a large enough difference to update the height.
|
|
90
|
-
// This prevents infinite rendering loop.
|
|
91
|
-
if (renders.current < 20 &&
|
|
92
|
-
((outerHeightStyle > 0 && Math.abs((prevState.outerHeightStyle || 0) - outerHeightStyle) > 1) ||
|
|
93
|
-
prevState.overflow !== overflow)) {
|
|
94
|
-
renders.current += 1;
|
|
95
|
-
return {
|
|
96
|
-
overflow,
|
|
97
|
-
outerHeightStyle,
|
|
98
|
-
};
|
|
99
|
-
}
|
|
100
|
-
return prevState;
|
|
101
|
-
});
|
|
102
|
-
}, [props.rowsMax, props.rowsMin]);
|
|
103
|
-
react_1.useEffect(() => {
|
|
104
|
-
const debouncedHandleResize = debounce_1.default(() => {
|
|
105
|
-
renders.current = 0;
|
|
106
|
-
syncHeight();
|
|
107
|
-
}, 1000);
|
|
108
|
-
window.addEventListener('resize', debouncedHandleResize);
|
|
109
|
-
return () => {
|
|
110
|
-
window.removeEventListener('resize', debouncedHandleResize);
|
|
111
|
-
};
|
|
112
|
-
}, [syncHeight]);
|
|
113
|
-
react_1.useLayoutEffect(() => {
|
|
114
|
-
syncHeight();
|
|
115
|
-
});
|
|
116
|
-
react_1.useEffect(() => {
|
|
117
|
-
renders.current = 0;
|
|
118
|
-
}, [props.value]);
|
|
119
|
-
const handleChange = (event) => {
|
|
120
|
-
renders.current = 0;
|
|
121
|
-
if (!isControlled)
|
|
122
|
-
syncHeight();
|
|
123
|
-
if (props.onChange)
|
|
124
|
-
props.onChange(event);
|
|
125
|
-
};
|
|
126
|
-
return (react_1.default.createElement(react_1.default.Fragment, null,
|
|
127
|
-
react_1.default.createElement("textarea", Object.assign({}, rest, { value: props.value, onChange: handleChange, ref: handleRef, rows: props.rows || props.rowsMin, style: {
|
|
128
|
-
height: state.outerHeightStyle,
|
|
129
|
-
// Need a large enough difference to allow scrolling.
|
|
130
|
-
// This prevents infinite rendering loop.
|
|
131
|
-
overflow: state.overflow ? 'hidden' : null,
|
|
132
|
-
} })),
|
|
133
|
-
react_1.default.createElement("textarea", { "aria-hidden": true, className: props.className, style: { visibility: 'hidden', position: 'absolute' }, readOnly: true, ref: shadowRef, tabIndex: -1, rows: 1 })));
|
|
134
|
-
});
|
|
135
|
-
exports.TextAreaAutosize = TextAreaAutosize;
|
|
136
|
-
TextAreaAutosize.defaultProps = defaultProps;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/TextAreaAutosize/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
__exportStar(require("./TextAreaAutosize"), exports);
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { ValidatedOptions } from '@patternfly/react-core';
|
|
2
|
-
import React, { HTMLProps } from 'react';
|
|
3
|
-
interface IProps extends Omit<HTMLProps<HTMLTextAreaElement>, 'css' | 'onChange' | 'name' | 'validated'> {
|
|
4
|
-
rowsMax?: number;
|
|
5
|
-
rowsMin?: number;
|
|
6
|
-
value?: string;
|
|
7
|
-
autoResize?: boolean;
|
|
8
|
-
isSpaceAllowed?: boolean;
|
|
9
|
-
id?: string;
|
|
10
|
-
className?: string;
|
|
11
|
-
isRequired?: boolean;
|
|
12
|
-
maxLength?: number;
|
|
13
|
-
name?: string;
|
|
14
|
-
isDisabled?: boolean;
|
|
15
|
-
validated?: ValidatedOptions;
|
|
16
|
-
onChange: (value: string, event: React.ChangeEvent<HTMLTextAreaElement>) => void;
|
|
17
|
-
}
|
|
18
|
-
export declare const TextAreaResizable: (props: IProps) => JSX.Element;
|
|
19
|
-
export {};
|
|
20
|
-
//# sourceMappingURL=TextAreaResizable.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TextAreaResizable.d.ts","sourceRoot":"","sources":["../../../src/TextAreaResizable/TextAreaResizable.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAY,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAEpE,OAAO,KAAK,EAAE,EAAE,SAAS,EAAY,MAAM,OAAO,CAAC;AAEnD,UAAU,MAAO,SAAQ,IAAI,CAAC,SAAS,CAAC,mBAAmB,CAAC,EAAE,KAAK,GAAG,UAAU,GAAG,MAAM,GAAG,WAAW,CAAC;IACpG,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,gBAAgB,CAAC;IAC7B,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,CAAC,WAAW,CAAC,mBAAmB,CAAC,KAAK,IAAI,CAAC;CACpF;AACD,eAAO,MAAM,iBAAiB,UAAW,MAAM,gBAoD9C,CAAC"}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
-
}) : function(o, v) {
|
|
12
|
-
o["default"] = v;
|
|
13
|
-
});
|
|
14
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
-
if (mod && mod.__esModule) return mod;
|
|
16
|
-
var result = {};
|
|
17
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
-
__setModuleDefault(result, mod);
|
|
19
|
-
return result;
|
|
20
|
-
};
|
|
21
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
22
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
23
|
-
};
|
|
24
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
-
exports.TextAreaResizable = void 0;
|
|
26
|
-
const react_core_1 = require("@patternfly/react-core");
|
|
27
|
-
const isEmpty_1 = __importDefault(require("lodash/isEmpty"));
|
|
28
|
-
const react_1 = __importStar(require("react"));
|
|
29
|
-
const TextAreaResizable = (props) => {
|
|
30
|
-
// To set defaultProps
|
|
31
|
-
const { rowsMin = 2, autoResize = false, onChange, rows, id, className, isRequired, maxLength, name, value, isDisabled, isSpaceAllowed = true, } = props;
|
|
32
|
-
const [isTextAreaEmpty, setIsTextAreaEmpty] = react_1.useState(false);
|
|
33
|
-
// Function to handle onChange event
|
|
34
|
-
const onTextAreaChange = (value, event) => {
|
|
35
|
-
onChange(value, event);
|
|
36
|
-
setIsTextAreaEmpty(isEmpty_1.default(value === null || value === void 0 ? void 0 : value.trim()));
|
|
37
|
-
event.preventDefault();
|
|
38
|
-
return [];
|
|
39
|
-
};
|
|
40
|
-
// Function to check for validity
|
|
41
|
-
const validatedCheck = () => {
|
|
42
|
-
let isValidated = 'default';
|
|
43
|
-
if (isRequired) {
|
|
44
|
-
if (isSpaceAllowed) {
|
|
45
|
-
return isValidated;
|
|
46
|
-
}
|
|
47
|
-
else {
|
|
48
|
-
return isTextAreaEmpty ? 'error' : 'default';
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
else
|
|
52
|
-
return 'default';
|
|
53
|
-
};
|
|
54
|
-
return (react_1.default.createElement(react_core_1.TextArea, { id: id, rows: rows || rowsMin, className: className, "aria-required": props['aria-required'], isRequired: isRequired, maxLength: maxLength, name: name, value: value, autoResize: autoResize, validated: validatedCheck(), onChange: onTextAreaChange, disabled: isDisabled }));
|
|
55
|
-
};
|
|
56
|
-
exports.TextAreaResizable = TextAreaResizable;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/TextAreaResizable/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
__exportStar(require("./TextAreaResizable"), exports);
|