@gravity-ui/querieskit 1.2.0 → 1.3.1
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/build/cjs/components/AttachmentList/AttachmentList.css +22 -0
- package/build/cjs/components/AttachmentList/AttachmentList.css.map +1 -0
- package/build/cjs/components/AttachmentList/AttachmentList.d.ts +17 -0
- package/build/cjs/components/AttachmentList/AttachmentList.js +75 -0
- package/build/cjs/components/AttachmentList/AttachmentList.js.map +1 -0
- package/build/cjs/components/AttachmentList/AttachmentList.stories.d.ts +93 -0
- package/build/cjs/components/AttachmentList/AttachmentList.stories.js +323 -0
- package/build/cjs/components/AttachmentList/AttachmentList.stories.js.map +1 -0
- package/build/cjs/components/AttachmentList/helpers/getIconByAttachmentName.d.ts +2 -0
- package/build/cjs/components/AttachmentList/helpers/getIconByAttachmentName.js +36 -0
- package/build/cjs/components/AttachmentList/helpers/getIconByAttachmentName.js.map +1 -0
- package/build/cjs/components/AttachmentList/helpers/objectLinkValidator.d.ts +11 -0
- package/build/cjs/components/AttachmentList/helpers/objectLinkValidator.js +30 -0
- package/build/cjs/components/AttachmentList/helpers/objectLinkValidator.js.map +1 -0
- package/build/cjs/components/AttachmentList/helpers/stringRequiredValidator.d.ts +2 -0
- package/build/cjs/components/AttachmentList/helpers/stringRequiredValidator.js +26 -0
- package/build/cjs/components/AttachmentList/helpers/stringRequiredValidator.js.map +1 -0
- package/build/cjs/components/AttachmentList/hooks/useKeyDownFormControl.d.ts +4 -0
- package/build/cjs/components/AttachmentList/hooks/useKeyDownFormControl.js +27 -0
- package/build/cjs/components/AttachmentList/hooks/useKeyDownFormControl.js.map +1 -0
- package/build/cjs/components/AttachmentList/hooks/useLabelRef.d.ts +4 -0
- package/build/cjs/components/AttachmentList/hooks/useLabelRef.js +35 -0
- package/build/cjs/components/AttachmentList/hooks/useLabelRef.js.map +1 -0
- package/build/cjs/components/AttachmentList/i18n/dicts.d.ts +23 -0
- package/build/cjs/components/AttachmentList/i18n/dicts.js +14 -0
- package/build/cjs/components/AttachmentList/i18n/dicts.js.map +1 -0
- package/build/cjs/components/AttachmentList/i18n/en.json +10 -0
- package/build/cjs/components/AttachmentList/i18n/index.d.ts +6 -0
- package/build/cjs/components/AttachmentList/i18n/index.js +11 -0
- package/build/cjs/components/AttachmentList/i18n/index.js.map +1 -0
- package/build/cjs/components/AttachmentList/i18n/ru.json +10 -0
- package/build/cjs/components/AttachmentList/index.d.ts +4 -0
- package/build/cjs/components/AttachmentList/index.js +40 -0
- package/build/cjs/components/AttachmentList/index.js.map +1 -0
- package/build/cjs/components/AttachmentList/internal/AttachmentItem/AttachmentItem.css +18 -0
- package/build/cjs/components/AttachmentList/internal/AttachmentItem/AttachmentItem.css.map +1 -0
- package/build/cjs/components/AttachmentList/internal/AttachmentItem/AttachmentItem.d.ts +16 -0
- package/build/cjs/components/AttachmentList/internal/AttachmentItem/AttachmentItem.js +106 -0
- package/build/cjs/components/AttachmentList/internal/AttachmentItem/AttachmentItem.js.map +1 -0
- package/build/cjs/components/AttachmentList/internal/AttachmentItem/index.d.ts +2 -0
- package/build/cjs/components/AttachmentList/internal/AttachmentItem/index.js +13 -0
- package/build/cjs/components/AttachmentList/internal/AttachmentItem/index.js.map +1 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/EditAttachmentItem.d.ts +9 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/EditAttachmentItem.js +22 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/EditAttachmentItem.js.map +1 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.css +17 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.css.map +1 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.d.ts +24 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.js +175 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.js.map +1 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/FileEdit.d.ts +12 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/FileEdit.js +91 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/FileEdit.js.map +1 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/index.d.ts +4 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/index.js +13 -0
- package/build/cjs/components/AttachmentList/internal/EditAttachmentItem/index.js.map +1 -0
- package/build/cjs/components/AttachmentListPlaceholder/AttachmentListPlaceholder.css +4 -0
- package/build/cjs/components/AttachmentListPlaceholder/AttachmentListPlaceholder.css.map +1 -0
- package/build/cjs/components/AttachmentListPlaceholder/AttachmentListPlaceholder.d.ts +13 -0
- package/build/cjs/components/AttachmentListPlaceholder/AttachmentListPlaceholder.js +75 -0
- package/build/cjs/components/AttachmentListPlaceholder/AttachmentListPlaceholder.js.map +1 -0
- package/build/cjs/components/AttachmentListPlaceholder/AttachmentListPlaceholder.stories.d.ts +29 -0
- package/build/cjs/components/AttachmentListPlaceholder/AttachmentListPlaceholder.stories.js +36 -0
- package/build/cjs/components/AttachmentListPlaceholder/AttachmentListPlaceholder.stories.js.map +1 -0
- package/build/cjs/components/AttachmentListPlaceholder/i18n/dicts.d.ts +17 -0
- package/build/cjs/components/AttachmentListPlaceholder/i18n/dicts.js +14 -0
- package/build/cjs/components/AttachmentListPlaceholder/i18n/dicts.js.map +1 -0
- package/build/cjs/components/AttachmentListPlaceholder/i18n/en.json +7 -0
- package/build/cjs/components/AttachmentListPlaceholder/i18n/index.d.ts +6 -0
- package/build/cjs/components/AttachmentListPlaceholder/i18n/index.js +11 -0
- package/build/cjs/components/AttachmentListPlaceholder/i18n/index.js.map +1 -0
- package/build/cjs/components/AttachmentListPlaceholder/i18n/ru.json +7 -0
- package/build/cjs/components/AttachmentListPlaceholder/index.d.ts +2 -0
- package/build/cjs/components/AttachmentListPlaceholder/index.js +13 -0
- package/build/cjs/components/AttachmentListPlaceholder/index.js.map +1 -0
- package/build/cjs/components/DataTable/DataTable.css +0 -7
- package/build/cjs/components/DataTable/DataTable.css.map +1 -1
- package/build/cjs/components/DataTable/DataTable.js +12 -5
- package/build/cjs/components/DataTable/DataTable.js.map +1 -1
- package/build/cjs/components/ErrorTree/ErrorTree.d.ts +3 -0
- package/build/cjs/components/ErrorTree/ErrorTree.js +35 -0
- package/build/cjs/components/ErrorTree/ErrorTree.js.map +1 -0
- package/build/cjs/components/ErrorTree/ErrorTree.stories.d.ts +8 -0
- package/build/cjs/components/ErrorTree/ErrorTree.stories.js +101 -0
- package/build/cjs/components/ErrorTree/ErrorTree.stories.js.map +1 -0
- package/build/cjs/components/ErrorTree/helpers/formatAttributes.d.ts +2 -0
- package/build/cjs/components/ErrorTree/helpers/formatAttributes.js +16 -0
- package/build/cjs/components/ErrorTree/helpers/formatAttributes.js.map +1 -0
- package/build/cjs/components/ErrorTree/helpers/getIntermediateChain.d.ts +6 -0
- package/build/cjs/components/ErrorTree/helpers/getIntermediateChain.js +22 -0
- package/build/cjs/components/ErrorTree/helpers/getIntermediateChain.js.map +1 -0
- package/build/cjs/components/ErrorTree/i18n/dicts.d.ts +27 -0
- package/build/cjs/components/ErrorTree/i18n/dicts.js +14 -0
- package/build/cjs/components/ErrorTree/i18n/dicts.js.map +1 -0
- package/build/cjs/components/ErrorTree/i18n/en.json +11 -0
- package/build/cjs/components/ErrorTree/i18n/index.d.ts +6 -0
- package/build/cjs/components/ErrorTree/i18n/index.js +11 -0
- package/build/cjs/components/ErrorTree/i18n/index.js.map +1 -0
- package/build/cjs/components/ErrorTree/i18n/ru.json +13 -0
- package/build/cjs/components/ErrorTree/index.d.ts +1 -0
- package/build/cjs/components/ErrorTree/index.js +13 -0
- package/build/cjs/components/ErrorTree/index.js.map +1 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeChildren.css +4 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeChildren.css.map +1 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeChildren.d.ts +10 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeChildren.js +32 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeChildren.js.map +1 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeNode.css +80 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeNode.css.map +1 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeNode.d.ts +13 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeNode.js +274 -0
- package/build/cjs/components/ErrorTree/internal/ErrorTreeNode.js.map +1 -0
- package/build/cjs/components/ErrorTree/internal/IntermediateMessages.css +10 -0
- package/build/cjs/components/ErrorTree/internal/IntermediateMessages.css.map +1 -0
- package/build/cjs/components/ErrorTree/internal/IntermediateMessages.d.ts +9 -0
- package/build/cjs/components/ErrorTree/internal/IntermediateMessages.js +118 -0
- package/build/cjs/components/ErrorTree/internal/IntermediateMessages.js.map +1 -0
- package/build/cjs/components/Icons/LogoCPlusPlus.d.ts +2 -0
- package/build/cjs/components/Icons/LogoCPlusPlus.js +35 -0
- package/build/cjs/components/Icons/LogoCPlusPlus.js.map +1 -0
- package/build/cjs/components/Icons/index.d.ts +1 -0
- package/build/cjs/components/Icons/index.js +13 -0
- package/build/cjs/components/Icons/index.js.map +1 -0
- package/build/cjs/components/QueryResultsTable/QueryResultsTable.css +53 -0
- package/build/cjs/components/QueryResultsTable/QueryResultsTable.css.map +1 -0
- package/build/cjs/components/QueryResultsTable/QueryResultsTable.d.ts +24 -0
- package/build/cjs/components/QueryResultsTable/QueryResultsTable.js +104 -0
- package/build/cjs/components/QueryResultsTable/QueryResultsTable.js.map +1 -0
- package/build/cjs/components/QueryResultsTable/helpers/formatQueryResultType.d.ts +3 -0
- package/build/cjs/components/QueryResultsTable/helpers/formatQueryResultType.js +90 -0
- package/build/cjs/components/QueryResultsTable/helpers/formatQueryResultType.js.map +1 -0
- package/build/cjs/components/QueryResultsTable/helpers/formatQueryResultValue.d.ts +11 -0
- package/build/cjs/components/QueryResultsTable/helpers/formatQueryResultValue.js +40 -0
- package/build/cjs/components/QueryResultsTable/helpers/formatQueryResultValue.js.map +1 -0
- package/build/cjs/components/QueryResultsTable/i18n/dicts.d.ts +13 -0
- package/build/cjs/components/QueryResultsTable/i18n/dicts.js +14 -0
- package/build/cjs/components/QueryResultsTable/i18n/dicts.js.map +1 -0
- package/build/cjs/components/QueryResultsTable/i18n/en.json +5 -0
- package/build/cjs/components/QueryResultsTable/i18n/index.d.ts +6 -0
- package/build/cjs/components/QueryResultsTable/i18n/index.js +11 -0
- package/build/cjs/components/QueryResultsTable/i18n/index.js.map +1 -0
- package/build/cjs/components/QueryResultsTable/i18n/ru.json +5 -0
- package/build/cjs/components/QueryResultsTable/index.d.ts +3 -0
- package/build/cjs/components/QueryResultsTable/index.js +20 -0
- package/build/cjs/components/QueryResultsTable/index.js.map +1 -0
- package/build/cjs/components/QueryResultsTable/internal/QueryResultCell.d.ts +11 -0
- package/build/cjs/components/QueryResultsTable/internal/QueryResultCell.js +79 -0
- package/build/cjs/components/QueryResultsTable/internal/QueryResultCell.js.map +1 -0
- package/build/cjs/components/index.d.ts +5 -0
- package/build/cjs/components/index.js +48 -1
- package/build/cjs/components/index.js.map +1 -1
- package/build/cjs/helpers/createUuid.d.ts +1 -0
- package/build/cjs/helpers/createUuid.js +12 -0
- package/build/cjs/helpers/createUuid.js.map +1 -0
- package/build/cjs/helpers/isObjectEqual.d.ts +1 -0
- package/build/cjs/helpers/isObjectEqual.js +30 -0
- package/build/cjs/helpers/isObjectEqual.js.map +1 -0
- package/build/cjs/helpers/useDebouncedValue.d.ts +2 -0
- package/build/cjs/helpers/useDebouncedValue.js +27 -0
- package/build/cjs/helpers/useDebouncedValue.js.map +1 -0
- package/build/cjs/index.d.ts +3 -0
- package/build/cjs/index.js +33 -0
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/modules/Attachments/Attachments.css +8 -0
- package/build/cjs/modules/Attachments/Attachments.css.map +1 -0
- package/build/cjs/modules/Attachments/Attachments.d.ts +22 -0
- package/build/cjs/modules/Attachments/Attachments.js +381 -0
- package/build/cjs/modules/Attachments/Attachments.js.map +1 -0
- package/build/cjs/modules/Attachments/Attachments.stories.d.ts +41 -0
- package/build/cjs/modules/Attachments/Attachments.stories.js +123 -0
- package/build/cjs/modules/Attachments/Attachments.stories.js.map +1 -0
- package/build/cjs/modules/Attachments/i18n/dicts.d.ts +13 -0
- package/build/cjs/modules/Attachments/i18n/dicts.js +14 -0
- package/build/cjs/modules/Attachments/i18n/dicts.js.map +1 -0
- package/build/cjs/modules/Attachments/i18n/en.json +5 -0
- package/build/cjs/modules/Attachments/i18n/index.d.ts +6 -0
- package/build/cjs/modules/Attachments/i18n/index.js +11 -0
- package/build/cjs/modules/Attachments/i18n/index.js.map +1 -0
- package/build/cjs/modules/Attachments/i18n/ru.json +5 -0
- package/build/cjs/modules/Attachments/index.d.ts +2 -0
- package/build/cjs/modules/Attachments/index.js +13 -0
- package/build/cjs/modules/Attachments/index.js.map +1 -0
- package/build/cjs/modules/HistoryLayout/HistoryLayout.d.ts +1 -1
- package/build/cjs/modules/HistoryLayout/HistoryLayout.js +1 -1
- package/build/cjs/modules/HistoryLayout/HistoryLayout.js.map +1 -1
- package/build/cjs/modules/NavigationPreview/NavigationPreview.css +7 -1
- package/build/cjs/modules/NavigationPreview/NavigationPreview.css.map +1 -1
- package/build/cjs/modules/NavigationPreview/NavigationPreview.d.ts +2 -2
- package/build/cjs/modules/NavigationPreview/NavigationPreview.js +37 -7
- package/build/cjs/modules/NavigationPreview/NavigationPreview.js.map +1 -1
- package/build/cjs/modules/NavigationPreview/story/NavigationPreview.stories.d.ts +1 -0
- package/build/cjs/modules/NavigationPreview/story/NavigationPreview.stories.js +25 -1
- package/build/cjs/modules/NavigationPreview/story/NavigationPreview.stories.js.map +1 -1
- package/build/cjs/modules/NavigationPreview/story/mockData.d.ts +2 -2
- package/build/cjs/modules/NavigationPreview/story/mockData.js +16 -4
- package/build/cjs/modules/NavigationPreview/story/mockData.js.map +1 -1
- package/build/cjs/modules/QueryStatistics/QueryStatistics.css +4 -0
- package/build/cjs/modules/QueryStatistics/QueryStatistics.css.map +1 -0
- package/build/cjs/modules/QueryStatistics/QueryStatistics.d.ts +4 -0
- package/build/cjs/modules/QueryStatistics/QueryStatistics.js +151 -0
- package/build/cjs/modules/QueryStatistics/QueryStatistics.js.map +1 -0
- package/build/cjs/modules/QueryStatistics/helpers.d.ts +15 -0
- package/build/cjs/modules/QueryStatistics/helpers.js +118 -0
- package/build/cjs/modules/QueryStatistics/helpers.js.map +1 -0
- package/build/cjs/modules/QueryStatistics/i18n/dicts.d.ts +35 -0
- package/build/cjs/modules/QueryStatistics/i18n/dicts.js +14 -0
- package/build/cjs/modules/QueryStatistics/i18n/dicts.js.map +1 -0
- package/build/cjs/modules/QueryStatistics/i18n/en.json +16 -0
- package/build/cjs/modules/QueryStatistics/i18n/index.d.ts +6 -0
- package/build/cjs/modules/QueryStatistics/i18n/index.js +11 -0
- package/build/cjs/modules/QueryStatistics/i18n/index.js.map +1 -0
- package/build/cjs/modules/QueryStatistics/i18n/ru.json +16 -0
- package/build/cjs/modules/QueryStatistics/index.d.ts +2 -0
- package/build/cjs/modules/QueryStatistics/index.js +13 -0
- package/build/cjs/modules/QueryStatistics/index.js.map +1 -0
- package/build/cjs/modules/QueryStatistics/internal/MetricCell.css +36 -0
- package/build/cjs/modules/QueryStatistics/internal/MetricCell.css.map +1 -0
- package/build/cjs/modules/QueryStatistics/internal/MetricCell.d.ts +9 -0
- package/build/cjs/modules/QueryStatistics/internal/MetricCell.js +121 -0
- package/build/cjs/modules/QueryStatistics/internal/MetricCell.js.map +1 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsTable.css +21 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsTable.css.map +1 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsTable.d.ts +20 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsTable.js +140 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsTable.js.map +1 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsToolbar.css +5 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsToolbar.css.map +1 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsToolbar.d.ts +10 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsToolbar.js +55 -0
- package/build/cjs/modules/QueryStatistics/internal/QueryStatisticsToolbar.js.map +1 -0
- package/build/cjs/modules/QueryStatistics/story/QueryStatistics.stories.d.ts +8 -0
- package/build/cjs/modules/QueryStatistics/story/QueryStatistics.stories.js +112 -0
- package/build/cjs/modules/QueryStatistics/story/QueryStatistics.stories.js.map +1 -0
- package/build/cjs/modules/RowsList/RowsList.css +4 -0
- package/build/cjs/modules/RowsList/RowsList.css.map +1 -1
- package/build/cjs/modules/index.d.ts +3 -0
- package/build/cjs/modules/index.js +20 -0
- package/build/cjs/modules/index.js.map +1 -1
- package/build/cjs/types/declarations.d.ts +10 -0
- package/build/cjs/types/errorTree.d.ts +23 -0
- package/build/cjs/types/errorTree.js +6 -0
- package/build/cjs/types/errorTree.js.map +1 -0
- package/build/cjs/types/navigation.d.ts +8 -1
- package/build/cjs/types/navigation.js.map +1 -1
- package/build/cjs/types/queryList.d.ts +1 -1
- package/build/cjs/types/queryList.js.map +1 -1
- package/build/cjs/types/queryResults.d.ts +34 -0
- package/build/cjs/types/queryResults.js +6 -0
- package/build/cjs/types/queryResults.js.map +1 -0
- package/build/cjs/types/queryStatistics.d.ts +54 -0
- package/build/cjs/types/queryStatistics.js +6 -0
- package/build/cjs/types/queryStatistics.js.map +1 -0
- package/build/cjs/widgets/QueriesHistory/QueriesHistory.js +1 -2
- package/build/cjs/widgets/QueriesHistory/QueriesHistory.js.map +1 -1
- package/build/cjs/widgets/QueriesHistory/QueriesHistory.stories.d.ts +1 -0
- package/build/cjs/widgets/QueriesHistory/QueriesHistory.stories.js +82 -1
- package/build/cjs/widgets/QueriesHistory/QueriesHistory.stories.js.map +1 -1
- package/build/cjs/widgets/QueriesNavigation/QueriesNavigation.stories.js +40 -35
- package/build/cjs/widgets/QueriesNavigation/QueriesNavigation.stories.js.map +1 -1
- package/build/cjs/widgets/QueriesNavigation/i18n/index.d.ts +2 -2
- package/build/cjs/widgets/QueryResults/QueryResults.css +19 -0
- package/build/cjs/widgets/QueryResults/QueryResults.css.map +1 -0
- package/build/cjs/widgets/QueryResults/QueryResults.d.ts +23 -0
- package/build/cjs/widgets/QueryResults/QueryResults.js +119 -0
- package/build/cjs/widgets/QueryResults/QueryResults.js.map +1 -0
- package/build/cjs/widgets/QueryResults/QueryResults.stories.d.ts +19 -0
- package/build/cjs/widgets/QueryResults/QueryResults.stories.js +199 -0
- package/build/cjs/widgets/QueryResults/QueryResults.stories.js.map +1 -0
- package/build/cjs/widgets/QueryResults/i18n/dicts.d.ts +25 -0
- package/build/cjs/widgets/QueryResults/i18n/dicts.js +14 -0
- package/build/cjs/widgets/QueryResults/i18n/dicts.js.map +1 -0
- package/build/cjs/widgets/QueryResults/i18n/en.json +10 -0
- package/build/cjs/widgets/QueryResults/i18n/index.d.ts +6 -0
- package/build/cjs/widgets/QueryResults/i18n/index.js +11 -0
- package/build/cjs/widgets/QueryResults/i18n/index.js.map +1 -0
- package/build/cjs/widgets/QueryResults/i18n/ru.json +12 -0
- package/build/cjs/widgets/QueryResults/index.d.ts +2 -0
- package/build/cjs/widgets/QueryResults/index.js +13 -0
- package/build/cjs/widgets/QueryResults/index.js.map +1 -0
- package/build/cjs/widgets/QueryResults/internal/QueryResultsSchema.d.ts +7 -0
- package/build/cjs/widgets/QueryResults/internal/QueryResultsSchema.js +49 -0
- package/build/cjs/widgets/QueryResults/internal/QueryResultsSchema.js.map +1 -0
- package/build/cjs/widgets/SavedQueries/SavedQueries.stories.js.map +1 -1
- package/build/cjs/widgets/index.d.ts +2 -0
- package/build/cjs/widgets/index.js +7 -0
- package/build/cjs/widgets/index.js.map +1 -1
- package/build/esm/components/AttachmentList/AttachmentList.css +22 -0
- package/build/esm/components/AttachmentList/AttachmentList.css.map +1 -0
- package/build/esm/components/AttachmentList/AttachmentList.d.ts +17 -0
- package/build/esm/components/AttachmentList/AttachmentList.js +67 -0
- package/build/esm/components/AttachmentList/AttachmentList.js.map +1 -0
- package/build/esm/components/AttachmentList/AttachmentList.scss +25 -0
- package/build/esm/components/AttachmentList/AttachmentList.stories.d.ts +93 -0
- package/build/esm/components/AttachmentList/AttachmentList.stories.js +315 -0
- package/build/esm/components/AttachmentList/AttachmentList.stories.js.map +1 -0
- package/build/esm/components/AttachmentList/helpers/getIconByAttachmentName.d.ts +2 -0
- package/build/esm/components/AttachmentList/helpers/getIconByAttachmentName.js +30 -0
- package/build/esm/components/AttachmentList/helpers/getIconByAttachmentName.js.map +1 -0
- package/build/esm/components/AttachmentList/helpers/objectLinkValidator.d.ts +11 -0
- package/build/esm/components/AttachmentList/helpers/objectLinkValidator.js +24 -0
- package/build/esm/components/AttachmentList/helpers/objectLinkValidator.js.map +1 -0
- package/build/esm/components/AttachmentList/helpers/stringRequiredValidator.d.ts +2 -0
- package/build/esm/components/AttachmentList/helpers/stringRequiredValidator.js +19 -0
- package/build/esm/components/AttachmentList/helpers/stringRequiredValidator.js.map +1 -0
- package/build/esm/components/AttachmentList/hooks/useKeyDownFormControl.d.ts +4 -0
- package/build/esm/components/AttachmentList/hooks/useKeyDownFormControl.js +21 -0
- package/build/esm/components/AttachmentList/hooks/useKeyDownFormControl.js.map +1 -0
- package/build/esm/components/AttachmentList/hooks/useLabelRef.d.ts +4 -0
- package/build/esm/components/AttachmentList/hooks/useLabelRef.js +28 -0
- package/build/esm/components/AttachmentList/hooks/useLabelRef.js.map +1 -0
- package/build/esm/components/AttachmentList/i18n/dicts.d.ts +23 -0
- package/build/esm/components/AttachmentList/i18n/dicts.js +7 -0
- package/build/esm/components/AttachmentList/i18n/dicts.js.map +1 -0
- package/build/esm/components/AttachmentList/i18n/en.json +10 -0
- package/build/esm/components/AttachmentList/i18n/index.d.ts +6 -0
- package/build/esm/components/AttachmentList/i18n/index.js +4 -0
- package/build/esm/components/AttachmentList/i18n/index.js.map +1 -0
- package/build/esm/components/AttachmentList/i18n/ru.json +10 -0
- package/build/esm/components/AttachmentList/index.d.ts +4 -0
- package/build/esm/components/AttachmentList/index.js +4 -0
- package/build/esm/components/AttachmentList/index.js.map +1 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/AttachmentItem.css +18 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/AttachmentItem.css.map +1 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/AttachmentItem.d.ts +16 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/AttachmentItem.js +98 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/AttachmentItem.js.map +1 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/AttachmentItem.scss +23 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/index.d.ts +2 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/index.js +2 -0
- package/build/esm/components/AttachmentList/internal/AttachmentItem/index.js.map +1 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditAttachmentItem.d.ts +9 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditAttachmentItem.js +15 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditAttachmentItem.js.map +1 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.css +17 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.css.map +1 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.d.ts +24 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.js +167 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.js.map +1 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditLinkItem.scss +21 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/FileEdit.d.ts +12 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/FileEdit.js +83 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/FileEdit.js.map +1 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/index.d.ts +4 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/index.js +2 -0
- package/build/esm/components/AttachmentList/internal/EditAttachmentItem/index.js.map +1 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.css +4 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.css.map +1 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.d.ts +13 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.js +68 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.js.map +1 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.scss +5 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.stories.d.ts +29 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.stories.js +29 -0
- package/build/esm/components/AttachmentListPlaceholder/AttachmentListPlaceholder.stories.js.map +1 -0
- package/build/esm/components/AttachmentListPlaceholder/i18n/dicts.d.ts +17 -0
- package/build/esm/components/AttachmentListPlaceholder/i18n/dicts.js +7 -0
- package/build/esm/components/AttachmentListPlaceholder/i18n/dicts.js.map +1 -0
- package/build/esm/components/AttachmentListPlaceholder/i18n/en.json +7 -0
- package/build/esm/components/AttachmentListPlaceholder/i18n/index.d.ts +6 -0
- package/build/esm/components/AttachmentListPlaceholder/i18n/index.js +4 -0
- package/build/esm/components/AttachmentListPlaceholder/i18n/index.js.map +1 -0
- package/build/esm/components/AttachmentListPlaceholder/i18n/ru.json +7 -0
- package/build/esm/components/AttachmentListPlaceholder/index.d.ts +2 -0
- package/build/esm/components/AttachmentListPlaceholder/index.js +2 -0
- package/build/esm/components/AttachmentListPlaceholder/index.js.map +1 -0
- package/build/esm/components/DataTable/DataTable.css +0 -7
- package/build/esm/components/DataTable/DataTable.css.map +1 -1
- package/build/esm/components/DataTable/DataTable.js +12 -5
- package/build/esm/components/DataTable/DataTable.js.map +1 -1
- package/build/esm/components/DataTable/DataTable.scss +18 -26
- package/build/esm/components/ErrorTree/ErrorTree.d.ts +3 -0
- package/build/esm/components/ErrorTree/ErrorTree.js +28 -0
- package/build/esm/components/ErrorTree/ErrorTree.js.map +1 -0
- package/build/esm/components/ErrorTree/ErrorTree.stories.d.ts +8 -0
- package/build/esm/components/ErrorTree/ErrorTree.stories.js +94 -0
- package/build/esm/components/ErrorTree/ErrorTree.stories.js.map +1 -0
- package/build/esm/components/ErrorTree/helpers/formatAttributes.d.ts +2 -0
- package/build/esm/components/ErrorTree/helpers/formatAttributes.js +10 -0
- package/build/esm/components/ErrorTree/helpers/formatAttributes.js.map +1 -0
- package/build/esm/components/ErrorTree/helpers/getIntermediateChain.d.ts +6 -0
- package/build/esm/components/ErrorTree/helpers/getIntermediateChain.js +16 -0
- package/build/esm/components/ErrorTree/helpers/getIntermediateChain.js.map +1 -0
- package/build/esm/components/ErrorTree/i18n/dicts.d.ts +27 -0
- package/build/esm/components/ErrorTree/i18n/dicts.js +7 -0
- package/build/esm/components/ErrorTree/i18n/dicts.js.map +1 -0
- package/build/esm/components/ErrorTree/i18n/en.json +11 -0
- package/build/esm/components/ErrorTree/i18n/index.d.ts +6 -0
- package/build/esm/components/ErrorTree/i18n/index.js +4 -0
- package/build/esm/components/ErrorTree/i18n/index.js.map +1 -0
- package/build/esm/components/ErrorTree/i18n/ru.json +13 -0
- package/build/esm/components/ErrorTree/index.d.ts +1 -0
- package/build/esm/components/ErrorTree/index.js +2 -0
- package/build/esm/components/ErrorTree/index.js.map +1 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeChildren.css +4 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeChildren.css.map +1 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeChildren.d.ts +10 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeChildren.js +25 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeChildren.js.map +1 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeChildren.scss +5 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeNode.css +80 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeNode.css.map +1 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeNode.d.ts +13 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeNode.js +266 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeNode.js.map +1 -0
- package/build/esm/components/ErrorTree/internal/ErrorTreeNode.scss +95 -0
- package/build/esm/components/ErrorTree/internal/IntermediateMessages.css +10 -0
- package/build/esm/components/ErrorTree/internal/IntermediateMessages.css.map +1 -0
- package/build/esm/components/ErrorTree/internal/IntermediateMessages.d.ts +9 -0
- package/build/esm/components/ErrorTree/internal/IntermediateMessages.js +110 -0
- package/build/esm/components/ErrorTree/internal/IntermediateMessages.js.map +1 -0
- package/build/esm/components/ErrorTree/internal/IntermediateMessages.scss +13 -0
- package/build/esm/components/Icons/LogoCPlusPlus.d.ts +2 -0
- package/build/esm/components/Icons/LogoCPlusPlus.js +28 -0
- package/build/esm/components/Icons/LogoCPlusPlus.js.map +1 -0
- package/build/esm/components/Icons/index.d.ts +1 -0
- package/build/esm/components/Icons/index.js +2 -0
- package/build/esm/components/Icons/index.js.map +1 -0
- package/build/esm/components/QueryResultsTable/QueryResultsTable.css +53 -0
- package/build/esm/components/QueryResultsTable/QueryResultsTable.css.map +1 -0
- package/build/esm/components/QueryResultsTable/QueryResultsTable.d.ts +24 -0
- package/build/esm/components/QueryResultsTable/QueryResultsTable.js +96 -0
- package/build/esm/components/QueryResultsTable/QueryResultsTable.js.map +1 -0
- package/build/esm/components/QueryResultsTable/QueryResultsTable.scss +65 -0
- package/build/esm/components/QueryResultsTable/helpers/formatQueryResultType.d.ts +3 -0
- package/build/esm/components/QueryResultsTable/helpers/formatQueryResultType.js +82 -0
- package/build/esm/components/QueryResultsTable/helpers/formatQueryResultType.js.map +1 -0
- package/build/esm/components/QueryResultsTable/helpers/formatQueryResultValue.d.ts +11 -0
- package/build/esm/components/QueryResultsTable/helpers/formatQueryResultValue.js +33 -0
- package/build/esm/components/QueryResultsTable/helpers/formatQueryResultValue.js.map +1 -0
- package/build/esm/components/QueryResultsTable/i18n/dicts.d.ts +13 -0
- package/build/esm/components/QueryResultsTable/i18n/dicts.js +7 -0
- package/build/esm/components/QueryResultsTable/i18n/dicts.js.map +1 -0
- package/build/esm/components/QueryResultsTable/i18n/en.json +5 -0
- package/build/esm/components/QueryResultsTable/i18n/index.d.ts +6 -0
- package/build/esm/components/QueryResultsTable/i18n/index.js +4 -0
- package/build/esm/components/QueryResultsTable/i18n/index.js.map +1 -0
- package/build/esm/components/QueryResultsTable/i18n/ru.json +5 -0
- package/build/esm/components/QueryResultsTable/index.d.ts +3 -0
- package/build/esm/components/QueryResultsTable/index.js +3 -0
- package/build/esm/components/QueryResultsTable/index.js.map +1 -0
- package/build/esm/components/QueryResultsTable/internal/QueryResultCell.d.ts +11 -0
- package/build/esm/components/QueryResultsTable/internal/QueryResultCell.js +71 -0
- package/build/esm/components/QueryResultsTable/internal/QueryResultCell.js.map +1 -0
- package/build/esm/components/index.d.ts +5 -0
- package/build/esm/components/index.js +4 -0
- package/build/esm/components/index.js.map +1 -1
- package/build/esm/helpers/createUuid.d.ts +1 -0
- package/build/esm/helpers/createUuid.js +6 -0
- package/build/esm/helpers/createUuid.js.map +1 -0
- package/build/esm/helpers/isObjectEqual.d.ts +1 -0
- package/build/esm/helpers/isObjectEqual.js +23 -0
- package/build/esm/helpers/isObjectEqual.js.map +1 -0
- package/build/esm/helpers/useDebouncedValue.d.ts +2 -0
- package/build/esm/helpers/useDebouncedValue.js +21 -0
- package/build/esm/helpers/useDebouncedValue.js.map +1 -0
- package/build/esm/index.d.ts +3 -0
- package/build/esm/index.js +3 -0
- package/build/esm/index.js.map +1 -1
- package/build/esm/modules/Attachments/Attachments.css +8 -0
- package/build/esm/modules/Attachments/Attachments.css.map +1 -0
- package/build/esm/modules/Attachments/Attachments.d.ts +22 -0
- package/build/esm/modules/Attachments/Attachments.js +373 -0
- package/build/esm/modules/Attachments/Attachments.js.map +1 -0
- package/build/esm/modules/Attachments/Attachments.scss +10 -0
- package/build/esm/modules/Attachments/Attachments.stories.d.ts +41 -0
- package/build/esm/modules/Attachments/Attachments.stories.js +115 -0
- package/build/esm/modules/Attachments/Attachments.stories.js.map +1 -0
- package/build/esm/modules/Attachments/i18n/dicts.d.ts +13 -0
- package/build/esm/modules/Attachments/i18n/dicts.js +7 -0
- package/build/esm/modules/Attachments/i18n/dicts.js.map +1 -0
- package/build/esm/modules/Attachments/i18n/en.json +5 -0
- package/build/esm/modules/Attachments/i18n/index.d.ts +6 -0
- package/build/esm/modules/Attachments/i18n/index.js +4 -0
- package/build/esm/modules/Attachments/i18n/index.js.map +1 -0
- package/build/esm/modules/Attachments/i18n/ru.json +5 -0
- package/build/esm/modules/Attachments/index.d.ts +2 -0
- package/build/esm/modules/Attachments/index.js +2 -0
- package/build/esm/modules/Attachments/index.js.map +1 -0
- package/build/esm/modules/HistoryLayout/HistoryLayout.d.ts +1 -1
- package/build/esm/modules/HistoryLayout/HistoryLayout.js +1 -1
- package/build/esm/modules/HistoryLayout/HistoryLayout.js.map +1 -1
- package/build/esm/modules/NavigationPreview/NavigationPreview.css +7 -1
- package/build/esm/modules/NavigationPreview/NavigationPreview.css.map +1 -1
- package/build/esm/modules/NavigationPreview/NavigationPreview.d.ts +2 -2
- package/build/esm/modules/NavigationPreview/NavigationPreview.js +38 -8
- package/build/esm/modules/NavigationPreview/NavigationPreview.js.map +1 -1
- package/build/esm/modules/NavigationPreview/NavigationPreview.scss +25 -17
- package/build/esm/modules/NavigationPreview/story/NavigationPreview.stories.d.ts +1 -0
- package/build/esm/modules/NavigationPreview/story/NavigationPreview.stories.js +24 -0
- package/build/esm/modules/NavigationPreview/story/NavigationPreview.stories.js.map +1 -1
- package/build/esm/modules/NavigationPreview/story/mockData.d.ts +2 -2
- package/build/esm/modules/NavigationPreview/story/mockData.js +16 -4
- package/build/esm/modules/NavigationPreview/story/mockData.js.map +1 -1
- package/build/esm/modules/QueryStatistics/QueryStatistics.css +4 -0
- package/build/esm/modules/QueryStatistics/QueryStatistics.css.map +1 -0
- package/build/esm/modules/QueryStatistics/QueryStatistics.d.ts +4 -0
- package/build/esm/modules/QueryStatistics/QueryStatistics.js +143 -0
- package/build/esm/modules/QueryStatistics/QueryStatistics.js.map +1 -0
- package/build/esm/modules/QueryStatistics/QueryStatistics.scss +3 -0
- package/build/esm/modules/QueryStatistics/helpers.d.ts +15 -0
- package/build/esm/modules/QueryStatistics/helpers.js +106 -0
- package/build/esm/modules/QueryStatistics/helpers.js.map +1 -0
- package/build/esm/modules/QueryStatistics/i18n/dicts.d.ts +35 -0
- package/build/esm/modules/QueryStatistics/i18n/dicts.js +7 -0
- package/build/esm/modules/QueryStatistics/i18n/dicts.js.map +1 -0
- package/build/esm/modules/QueryStatistics/i18n/en.json +16 -0
- package/build/esm/modules/QueryStatistics/i18n/index.d.ts +6 -0
- package/build/esm/modules/QueryStatistics/i18n/index.js +4 -0
- package/build/esm/modules/QueryStatistics/i18n/index.js.map +1 -0
- package/build/esm/modules/QueryStatistics/i18n/ru.json +16 -0
- package/build/esm/modules/QueryStatistics/index.d.ts +2 -0
- package/build/esm/modules/QueryStatistics/index.js +2 -0
- package/build/esm/modules/QueryStatistics/index.js.map +1 -0
- package/build/esm/modules/QueryStatistics/internal/MetricCell.css +36 -0
- package/build/esm/modules/QueryStatistics/internal/MetricCell.css.map +1 -0
- package/build/esm/modules/QueryStatistics/internal/MetricCell.d.ts +9 -0
- package/build/esm/modules/QueryStatistics/internal/MetricCell.js +114 -0
- package/build/esm/modules/QueryStatistics/internal/MetricCell.js.map +1 -0
- package/build/esm/modules/QueryStatistics/internal/MetricCell.scss +12 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsTable.css +21 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsTable.css.map +1 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsTable.d.ts +20 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsTable.js +132 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsTable.js.map +1 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsTable.scss +8 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsToolbar.css +5 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsToolbar.css.map +1 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsToolbar.d.ts +10 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsToolbar.js +48 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsToolbar.js.map +1 -0
- package/build/esm/modules/QueryStatistics/internal/QueryStatisticsToolbar.scss +1 -0
- package/build/esm/modules/QueryStatistics/story/QueryStatistics.stories.d.ts +8 -0
- package/build/esm/modules/QueryStatistics/story/QueryStatistics.stories.js +105 -0
- package/build/esm/modules/QueryStatistics/story/QueryStatistics.stories.js.map +1 -0
- package/build/esm/modules/RowsList/RowsList.css +4 -0
- package/build/esm/modules/RowsList/RowsList.css.map +1 -1
- package/build/esm/modules/RowsList/RowsList.scss +3 -0
- package/build/esm/modules/index.d.ts +3 -0
- package/build/esm/modules/index.js +2 -0
- package/build/esm/modules/index.js.map +1 -1
- package/build/esm/types/declarations.d.ts +10 -0
- package/build/esm/types/errorTree.d.ts +23 -0
- package/build/esm/types/errorTree.js +2 -0
- package/build/esm/types/errorTree.js.map +1 -0
- package/build/esm/types/navigation.d.ts +8 -1
- package/build/esm/types/navigation.js.map +1 -1
- package/build/esm/types/queryList.d.ts +1 -1
- package/build/esm/types/queryList.js.map +1 -1
- package/build/esm/types/queryResults.d.ts +34 -0
- package/build/esm/types/queryResults.js +2 -0
- package/build/esm/types/queryResults.js.map +1 -0
- package/build/esm/types/queryStatistics.d.ts +54 -0
- package/build/esm/types/queryStatistics.js +2 -0
- package/build/esm/types/queryStatistics.js.map +1 -0
- package/build/esm/widgets/QueriesHistory/QueriesHistory.js +1 -2
- package/build/esm/widgets/QueriesHistory/QueriesHistory.js.map +1 -1
- package/build/esm/widgets/QueriesHistory/QueriesHistory.stories.d.ts +1 -0
- package/build/esm/widgets/QueriesHistory/QueriesHistory.stories.js +81 -0
- package/build/esm/widgets/QueriesHistory/QueriesHistory.stories.js.map +1 -1
- package/build/esm/widgets/QueriesNavigation/QueriesNavigation.stories.js +40 -35
- package/build/esm/widgets/QueriesNavigation/QueriesNavigation.stories.js.map +1 -1
- package/build/esm/widgets/QueriesNavigation/i18n/index.d.ts +2 -2
- package/build/esm/widgets/QueryResults/QueryResults.css +19 -0
- package/build/esm/widgets/QueryResults/QueryResults.css.map +1 -0
- package/build/esm/widgets/QueryResults/QueryResults.d.ts +23 -0
- package/build/esm/widgets/QueryResults/QueryResults.js +111 -0
- package/build/esm/widgets/QueryResults/QueryResults.js.map +1 -0
- package/build/esm/widgets/QueryResults/QueryResults.scss +25 -0
- package/build/esm/widgets/QueryResults/QueryResults.stories.d.ts +19 -0
- package/build/esm/widgets/QueryResults/QueryResults.stories.js +191 -0
- package/build/esm/widgets/QueryResults/QueryResults.stories.js.map +1 -0
- package/build/esm/widgets/QueryResults/i18n/dicts.d.ts +25 -0
- package/build/esm/widgets/QueryResults/i18n/dicts.js +7 -0
- package/build/esm/widgets/QueryResults/i18n/dicts.js.map +1 -0
- package/build/esm/widgets/QueryResults/i18n/en.json +10 -0
- package/build/esm/widgets/QueryResults/i18n/index.d.ts +6 -0
- package/build/esm/widgets/QueryResults/i18n/index.js +4 -0
- package/build/esm/widgets/QueryResults/i18n/index.js.map +1 -0
- package/build/esm/widgets/QueryResults/i18n/ru.json +12 -0
- package/build/esm/widgets/QueryResults/index.d.ts +2 -0
- package/build/esm/widgets/QueryResults/index.js +2 -0
- package/build/esm/widgets/QueryResults/index.js.map +1 -0
- package/build/esm/widgets/QueryResults/internal/QueryResultsSchema.d.ts +7 -0
- package/build/esm/widgets/QueryResults/internal/QueryResultsSchema.js +41 -0
- package/build/esm/widgets/QueryResults/internal/QueryResultsSchema.js.map +1 -0
- package/build/esm/widgets/SavedQueries/SavedQueries.stories.js.map +1 -1
- package/build/esm/widgets/index.d.ts +2 -0
- package/build/esm/widgets/index.js +1 -0
- package/build/esm/widgets/index.js.map +1 -1
- package/package.json +29 -2
- package/.agents/skills/code-review-checklist/SKILL.md +0 -135
- package/.agents/skills/github-pr-review/SKILL.md +0 -24
- package/.agents/skills/gravity-ui/SKILL.md +0 -175
- package/.agents/skills/gravity-ui/references/icons.md +0 -60
- package/.agents/skills/gravity-ui/references/layout.md +0 -366
- package/.agents/skills/gravity-ui/references/package-routing.md +0 -424
- package/.agents/skills/gravity-ui/references/theming.md +0 -309
- package/.agents/skills/gravity-ui/rules/hallucination-traps.md +0 -361
- package/.agents/skills/gravity-ui/scripts/icon-image-search.sh +0 -63
- package/.eslintignore +0 -3
- package/.github/workflows/ci.yml +0 -25
- package/.github/workflows/main-preview.yml +0 -31
- package/.github/workflows/pr-preview-build.yml +0 -13
- package/.github/workflows/pr-preview-deploy.yml +0 -22
- package/.github/workflows/pr-title.yml +0 -27
- package/.github/workflows/release.yml +0 -20
- package/.nvmrc +0 -1
- package/.prettierrc.js +0 -1
- package/.storybook/main.ts +0 -31
- package/.storybook/preview.tsx +0 -43
- package/.storybook/redefinition.css +0 -3
- package/.storybook/tsconfig.json +0 -9
- package/.stylelintrc +0 -9
- package/AGENTS.md +0 -117
- package/CHANGELOG.md +0 -86
- package/CODEOWNERS +0 -1
- package/CONTRIBUTING.md +0 -31
- package/NOTICES.md +0 -8
- package/app-builder.config.ts +0 -9
- package/commitlint.config.cjs +0 -6
- package/eslint.config.mjs +0 -53
- package/plans/i18n-rules.md +0 -116
- package/plans/navigation-architecture.md +0 -262
- package/plans/queries-history-structure.md +0 -143
- package/plans/queries-navigation-architecture-review.md +0 -217
- package/skills-lock.json +0 -11
- package/src/components/AddChartButton/AddChartButton.scss +0 -12
- package/src/components/AddChartButton/AddChartButton.stories.tsx +0 -34
- package/src/components/AddChartButton/AddChartButton.tsx +0 -139
- package/src/components/AddChartButton/index.ts +0 -6
- package/src/components/Breadcrumbs/Breadcrumbs.scss +0 -25
- package/src/components/Breadcrumbs/Breadcrumbs.tsx +0 -114
- package/src/components/Breadcrumbs/helpers/parsePathSegments.ts +0 -16
- package/src/components/Breadcrumbs/i18n/dicts.ts +0 -4
- package/src/components/Breadcrumbs/i18n/en.json +0 -4
- package/src/components/Breadcrumbs/i18n/index.ts +0 -5
- package/src/components/Breadcrumbs/i18n/ru.json +0 -4
- package/src/components/Breadcrumbs/index.ts +0 -2
- package/src/components/Chart/Chart.scss +0 -40
- package/src/components/Chart/Chart.stories.tsx +0 -75
- package/src/components/Chart/Chart.tsx +0 -120
- package/src/components/Chart/i18n/dicts.ts +0 -4
- package/src/components/Chart/i18n/en.json +0 -6
- package/src/components/Chart/i18n/index.ts +0 -5
- package/src/components/Chart/i18n/ru.json +0 -6
- package/src/components/Chart/index.ts +0 -2
- package/src/components/ChartEditorForm/ChartEditorForm.scss +0 -20
- package/src/components/ChartEditorForm/ChartEditorForm.stories.tsx +0 -88
- package/src/components/ChartEditorForm/ChartEditorForm.tsx +0 -120
- package/src/components/ChartEditorForm/helpers/resolveLabels.ts +0 -17
- package/src/components/ChartEditorForm/i18n/dicts.ts +0 -4
- package/src/components/ChartEditorForm/i18n/en.json +0 -12
- package/src/components/ChartEditorForm/i18n/index.ts +0 -5
- package/src/components/ChartEditorForm/i18n/ru.json +0 -12
- package/src/components/ChartEditorForm/index.ts +0 -7
- package/src/components/ChartEditorForm/internal/Field.tsx +0 -11
- package/src/components/ChartEditorForm/types.ts +0 -44
- package/src/components/ClusterRow/ClusterRow.tsx +0 -34
- package/src/components/ClusterRow/index.ts +0 -2
- package/src/components/Dashboard/Dashboard.scss +0 -4
- package/src/components/Dashboard/Dashboard.stories.scss +0 -18
- package/src/components/Dashboard/Dashboard.stories.tsx +0 -248
- package/src/components/Dashboard/Dashboard.tsx +0 -51
- package/src/components/Dashboard/helpers/createDefaultLayout.ts +0 -43
- package/src/components/Dashboard/hooks/useDashboardConfig.ts +0 -63
- package/src/components/Dashboard/index.ts +0 -2
- package/src/components/Dashboard/internal/DashPlate.scss +0 -23
- package/src/components/Dashboard/internal/DashPlate.tsx +0 -35
- package/src/components/Dashboard/internal/DashboardProvider.tsx +0 -37
- package/src/components/Dashboard/types.ts +0 -21
- package/src/components/DataTable/DataTable.scss +0 -35
- package/src/components/DataTable/DataTable.stories.tsx +0 -65
- package/src/components/DataTable/DataTable.tsx +0 -81
- package/src/components/DataTable/index.ts +0 -1
- package/src/components/EditableRowTitle/EditableRowTitle.tsx +0 -67
- package/src/components/EditableRowTitle/index.ts +0 -2
- package/src/components/EmptyContent/EmptyContent.scss +0 -3
- package/src/components/EmptyContent/EmptyContent.tsx +0 -57
- package/src/components/EmptyContent/i18n/dicts.ts +0 -4
- package/src/components/EmptyContent/i18n/en.json +0 -7
- package/src/components/EmptyContent/i18n/index.ts +0 -5
- package/src/components/EmptyContent/i18n/ru.json +0 -7
- package/src/components/EmptyContent/index.ts +0 -1
- package/src/components/FieldsSearchToolbar/FieldsSearchToolbar.tsx +0 -48
- package/src/components/FieldsSearchToolbar/index.ts +0 -2
- package/src/components/FieldsSelector/FieldsSelector.scss +0 -18
- package/src/components/FieldsSelector/FieldsSelector.stories.tsx +0 -48
- package/src/components/FieldsSelector/FieldsSelector.tsx +0 -92
- package/src/components/FieldsSelector/i18n/dicts.ts +0 -4
- package/src/components/FieldsSelector/i18n/en.json +0 -3
- package/src/components/FieldsSelector/i18n/index.ts +0 -5
- package/src/components/FieldsSelector/i18n/ru.json +0 -3
- package/src/components/FieldsSelector/index.ts +0 -2
- package/src/components/HistoryFilter/HistoryFilter.scss +0 -5
- package/src/components/HistoryFilter/HistoryFilter.stories.tsx +0 -69
- package/src/components/HistoryFilter/HistoryFilter.tsx +0 -64
- package/src/components/HistoryFilter/i18n/dicts.ts +0 -4
- package/src/components/HistoryFilter/i18n/en.json +0 -4
- package/src/components/HistoryFilter/i18n/index.ts +0 -5
- package/src/components/HistoryFilter/i18n/ru.json +0 -4
- package/src/components/HistoryFilter/index.ts +0 -1
- package/src/components/HistoryGroupHeader/HistoryGroupHeader.scss +0 -7
- package/src/components/HistoryGroupHeader/HistoryGroupHeader.tsx +0 -18
- package/src/components/HistoryGroupHeader/index.ts +0 -1
- package/src/components/HistoryPrivateIcon/HistoryPrivateIcon.scss +0 -7
- package/src/components/HistoryPrivateIcon/HistoryPrivateIcon.tsx +0 -22
- package/src/components/HistoryPrivateIcon/index.ts +0 -1
- package/src/components/LazyList/LazyList.scss +0 -13
- package/src/components/LazyList/LazyList.tsx +0 -97
- package/src/components/LazyList/index.ts +0 -2
- package/src/components/ListSpinner/ListSpinner.scss +0 -3
- package/src/components/ListSpinner/ListSpinner.tsx +0 -18
- package/src/components/ListSpinner/index.ts +0 -2
- package/src/components/MonacoEditor/MonacoEditor.tsx +0 -112
- package/src/components/MonacoEditor/MonacoEditorThemes.tsx +0 -73
- package/src/components/MonacoEditor/index.ts +0 -11
- package/src/components/MonacoEditor/monaco-yql-languages/_.contribution.ts +0 -193
- package/src/components/MonacoEditor/monaco-yql-languages/clickhouse/clickhouse.contribution.ts +0 -14
- package/src/components/MonacoEditor/monaco-yql-languages/clickhouse/clickhouse.keywords.ts +0 -146
- package/src/components/MonacoEditor/monaco-yql-languages/clickhouse/clickhouse.ts +0 -217
- package/src/components/MonacoEditor/monaco-yql-languages/constants.ts +0 -6
- package/src/components/MonacoEditor/monaco-yql-languages/fillers/monaco-editor-core.ts +0 -3
- package/src/components/MonacoEditor/monaco-yql-languages/index.ts +0 -1
- package/src/components/MonacoEditor/monaco-yql-languages/monaco.contribution.ts +0 -5
- package/src/components/MonacoEditor/monaco-yql-languages/s-expressions/s-expressions.contribution.ts +0 -14
- package/src/components/MonacoEditor/monaco-yql-languages/s-expressions/s-expressions.keywords.ts +0 -97
- package/src/components/MonacoEditor/monaco-yql-languages/s-expressions/s-expressions.ts +0 -170
- package/src/components/MonacoEditor/monaco-yql-languages/themes/themes.contribution.ts +0 -35
- package/src/components/MonacoEditor/monaco-yql-languages/yql/yql.contribution.ts +0 -14
- package/src/components/MonacoEditor/monaco-yql-languages/yql/yql.keywords.ts +0 -13
- package/src/components/MonacoEditor/monaco-yql-languages/yql/yql.ts +0 -178
- package/src/components/MonacoEditor/monaco-yql-languages/yql_ansi/yql_ansi.contribution.ts +0 -14
- package/src/components/MonacoEditor/monaco-yql-languages/yql_ansi/yql_ansi.keywords.ts +0 -45
- package/src/components/MonacoEditor/monaco-yql-languages/yql_ansi/yql_ansi.ts +0 -142
- package/src/components/NavigationActionButtons/NavigationActionButtons.tsx +0 -46
- package/src/components/NavigationActionButtons/index.ts +0 -2
- package/src/components/NavigationItemRow/NavigationItemRow.tsx +0 -28
- package/src/components/NavigationItemRow/index.ts +0 -2
- package/src/components/PathEditor/PathEditor.scss +0 -41
- package/src/components/PathEditor/PathEditor.stories.helpers.ts +0 -118
- package/src/components/PathEditor/PathEditor.stories.tsx +0 -57
- package/src/components/PathEditor/PathEditor.tsx +0 -380
- package/src/components/PathEditor/helpers/suggestions.ts +0 -40
- package/src/components/PathEditor/i18n/dicts.ts +0 -4
- package/src/components/PathEditor/i18n/en.json +0 -4
- package/src/components/PathEditor/i18n/index.ts +0 -5
- package/src/components/PathEditor/i18n/ru.json +0 -4
- package/src/components/PathEditor/index.ts +0 -2
- package/src/components/QueryDuration/QueryDuration.scss +0 -6
- package/src/components/QueryDuration/QueryDuration.stories.tsx +0 -40
- package/src/components/QueryDuration/QueryDuration.tsx +0 -21
- package/src/components/QueryDuration/index.ts +0 -1
- package/src/components/QueryDuration/useQueryDuration.ts +0 -34
- package/src/components/QueryStatusIcon/QueryStatusIcon.scss +0 -17
- package/src/components/QueryStatusIcon/QueryStatusIcon.stories.tsx +0 -50
- package/src/components/QueryStatusIcon/QueryStatusIcon.tsx +0 -37
- package/src/components/QueryStatusIcon/index.ts +0 -1
- package/src/components/RowActionsMenu/RowActionsMenu.tsx +0 -47
- package/src/components/RowActionsMenu/index.ts +0 -2
- package/src/components/RowLink/RowLink.scss +0 -8
- package/src/components/RowLink/RowLink.tsx +0 -23
- package/src/components/RowLink/index.ts +0 -2
- package/src/components/SearchRowLayout/SearchRowLayout.scss +0 -18
- package/src/components/SearchRowLayout/SearchRowLayout.tsx +0 -45
- package/src/components/SearchRowLayout/helpers/fitQueryToVisibleLines.ts +0 -10
- package/src/components/SearchRowLayout/helpers/monacoConfig.ts +0 -25
- package/src/components/SearchRowLayout/index.ts +0 -2
- package/src/components/SearchWithButtons/SearchWithButtons.scss +0 -10
- package/src/components/SearchWithButtons/SearchWithButtons.stories.tsx +0 -107
- package/src/components/SearchWithButtons/SearchWithButtons.tsx +0 -56
- package/src/components/SearchWithButtons/index.ts +0 -2
- package/src/components/SimpleForm/CheckboxGroupField.tsx +0 -53
- package/src/components/SimpleForm/RangeDatePickerField.tsx +0 -50
- package/src/components/SimpleForm/SelectField.tsx +0 -24
- package/src/components/SimpleForm/SimpleForm.stories.tsx +0 -115
- package/src/components/SimpleForm/SimpleForm.tsx +0 -65
- package/src/components/SimpleForm/SwitchField.tsx +0 -23
- package/src/components/SimpleForm/helpers/controlsRegistry.ts +0 -24
- package/src/components/SimpleForm/helpers/getInitialValues.ts +0 -10
- package/src/components/SimpleForm/helpers/index.ts +0 -2
- package/src/components/SimpleForm/index.ts +0 -7
- package/src/components/SkeletonRows/SkeletonRows.tsx +0 -24
- package/src/components/SkeletonRows/index.ts +0 -2
- package/src/components/index.ts +0 -66
- package/src/constants/query.ts +0 -10
- package/src/constants/row.ts +0 -2
- package/src/helpers/buildColumnsFromKeys.ts +0 -17
- package/src/helpers/getDefaultNavigationIcon.ts +0 -33
- package/src/helpers/getListKey.ts +0 -12
- package/src/helpers/getParentPath.ts +0 -10
- package/src/helpers/isEmptyValue.ts +0 -2
- package/src/helpers/isFieldVisible.ts +0 -20
- package/src/helpers/time.ts +0 -29
- package/src/helpers/useLoadMoreSentinel.ts +0 -31
- package/src/helpers/useToggle.ts +0 -11
- package/src/helpers/useVisibleColumns.ts +0 -26
- package/src/i18n/index.ts +0 -26
- package/src/index.ts +0 -9
- package/src/modules/ChartEditor/ChartEditor.scss +0 -12
- package/src/modules/ChartEditor/ChartEditor.tsx +0 -116
- package/src/modules/ChartEditor/i18n/dicts.ts +0 -4
- package/src/modules/ChartEditor/i18n/en.json +0 -3
- package/src/modules/ChartEditor/i18n/index.ts +0 -5
- package/src/modules/ChartEditor/i18n/ru.json +0 -3
- package/src/modules/ChartEditor/index.ts +0 -2
- package/src/modules/ChartEditor/story/ChartEditor.stories.tsx +0 -186
- package/src/modules/ChartEditor/story/mockData.ts +0 -222
- package/src/modules/ChartEditor/types.ts +0 -18
- package/src/modules/ClustersList/ClustersList.scss +0 -11
- package/src/modules/ClustersList/ClustersList.tsx +0 -49
- package/src/modules/ClustersList/index.ts +0 -2
- package/src/modules/HistoryComparisonActions/HistoryComparisonActions.scss +0 -4
- package/src/modules/HistoryComparisonActions/HistoryComparisonActions.tsx +0 -42
- package/src/modules/HistoryComparisonActions/index.ts +0 -2
- package/src/modules/HistoryHeader/HistoryHeader.stories.tsx +0 -47
- package/src/modules/HistoryHeader/HistoryHeader.tsx +0 -58
- package/src/modules/HistoryHeader/index.ts +0 -1
- package/src/modules/HistoryHeader/internal/FullSearchToggleButton.tsx +0 -16
- package/src/modules/HistoryLayout/HistoryLayout.scss +0 -7
- package/src/modules/HistoryLayout/HistoryLayout.tsx +0 -43
- package/src/modules/HistoryLayout/index.ts +0 -2
- package/src/modules/HistoryRow/HistoryRow.scss +0 -32
- package/src/modules/HistoryRow/HistoryRow.stories.tsx +0 -91
- package/src/modules/HistoryRow/HistoryRow.tsx +0 -77
- package/src/modules/HistoryRow/index.ts +0 -1
- package/src/modules/HistorySearchRow/HistorySearchRow.scss +0 -13
- package/src/modules/HistorySearchRow/HistorySearchRow.stories.tsx +0 -52
- package/src/modules/HistorySearchRow/HistorySearchRow.tsx +0 -62
- package/src/modules/HistorySearchRow/helpers/resolveMonacoLanguage.ts +0 -19
- package/src/modules/HistorySearchRow/index.ts +0 -1
- package/src/modules/NavigationDetail/NavigationDetail.scss +0 -13
- package/src/modules/NavigationDetail/NavigationDetail.tsx +0 -121
- package/src/modules/NavigationDetail/helpers/getInitialTab.ts +0 -9
- package/src/modules/NavigationDetail/helpers/getVisibleTabs.ts +0 -5
- package/src/modules/NavigationDetail/index.ts +0 -2
- package/src/modules/NavigationDetail/internal/NavigationDetailTabs.tsx +0 -32
- package/src/modules/NavigationHeader/NavigationHeader.stories.tsx +0 -118
- package/src/modules/NavigationHeader/NavigationHeader.tsx +0 -33
- package/src/modules/NavigationHeader/index.ts +0 -2
- package/src/modules/NavigationItemsList/NavigationItemsList.scss +0 -65
- package/src/modules/NavigationItemsList/NavigationItemsList.tsx +0 -92
- package/src/modules/NavigationItemsList/index.ts +0 -2
- package/src/modules/NavigationItemsList/internal/NavigationItemsListEmptyState.tsx +0 -45
- package/src/modules/NavigationItemsList/internal/NavigationItemsListHeader.scss +0 -6
- package/src/modules/NavigationItemsList/internal/NavigationItemsListHeader.tsx +0 -54
- package/src/modules/NavigationItemsList/internal/useParentRow.ts +0 -23
- package/src/modules/NavigationMeta/NavigationMeta.scss +0 -25
- package/src/modules/NavigationMeta/NavigationMeta.tsx +0 -81
- package/src/modules/NavigationMeta/helpers/buildMetaGroups.tsx +0 -27
- package/src/modules/NavigationMeta/i18n/dicts.ts +0 -4
- package/src/modules/NavigationMeta/i18n/en.json +0 -4
- package/src/modules/NavigationMeta/i18n/index.ts +0 -5
- package/src/modules/NavigationMeta/i18n/ru.json +0 -4
- package/src/modules/NavigationMeta/index.ts +0 -3
- package/src/modules/NavigationMeta/story/NavigationMeta.stories.tsx +0 -80
- package/src/modules/NavigationMeta/story/mockData.ts +0 -22
- package/src/modules/NavigationPreview/NavigationPreview.scss +0 -24
- package/src/modules/NavigationPreview/NavigationPreview.tsx +0 -110
- package/src/modules/NavigationPreview/helpers/buildPreviewColumns.tsx +0 -11
- package/src/modules/NavigationPreview/helpers/filterPreviewRows.ts +0 -29
- package/src/modules/NavigationPreview/i18n/dicts.ts +0 -4
- package/src/modules/NavigationPreview/i18n/en.json +0 -3
- package/src/modules/NavigationPreview/i18n/index.ts +0 -5
- package/src/modules/NavigationPreview/i18n/ru.json +0 -3
- package/src/modules/NavigationPreview/index.ts +0 -4
- package/src/modules/NavigationPreview/story/NavigationPreview.stories.tsx +0 -98
- package/src/modules/NavigationPreview/story/mockData.ts +0 -9
- package/src/modules/NavigationSchema/NavigationSchema.scss +0 -24
- package/src/modules/NavigationSchema/NavigationSchema.tsx +0 -118
- package/src/modules/NavigationSchema/helpers/buildSchemaColumns.tsx +0 -54
- package/src/modules/NavigationSchema/helpers/filterSchema.ts +0 -18
- package/src/modules/NavigationSchema/i18n/dicts.ts +0 -4
- package/src/modules/NavigationSchema/i18n/en.json +0 -9
- package/src/modules/NavigationSchema/i18n/index.ts +0 -5
- package/src/modules/NavigationSchema/i18n/ru.json +0 -9
- package/src/modules/NavigationSchema/index.ts +0 -4
- package/src/modules/NavigationSchema/story/NavigationSchema.stories.tsx +0 -112
- package/src/modules/NavigationSchema/story/mockData.ts +0 -9
- package/src/modules/NavigationView/NavigationView.scss +0 -44
- package/src/modules/NavigationView/NavigationView.tsx +0 -60
- package/src/modules/NavigationView/helpers/buildViewColumns.tsx +0 -11
- package/src/modules/NavigationView/i18n/dicts.ts +0 -4
- package/src/modules/NavigationView/i18n/en.json +0 -3
- package/src/modules/NavigationView/i18n/index.ts +0 -5
- package/src/modules/NavigationView/i18n/ru.json +0 -3
- package/src/modules/NavigationView/index.ts +0 -3
- package/src/modules/NavigationView/internal/NavigationViewSectionItem.tsx +0 -70
- package/src/modules/NavigationView/story/NavigationView.stories.tsx +0 -110
- package/src/modules/NavigationView/story/mockData.ts +0 -35
- package/src/modules/QueriesList/QueriesList.scss +0 -10
- package/src/modules/QueriesList/QueriesList.tsx +0 -98
- package/src/modules/QueriesList/index.ts +0 -2
- package/src/modules/RowsList/RowsList.scss +0 -5
- package/src/modules/RowsList/RowsList.tsx +0 -96
- package/src/modules/RowsList/helpers/prepareRowData.ts +0 -61
- package/src/modules/RowsList/index.ts +0 -2
- package/src/modules/SavedQueryRow/SavedQueryRow.scss +0 -20
- package/src/modules/SavedQueryRow/SavedQueryRow.tsx +0 -60
- package/src/modules/SavedQueryRow/index.ts +0 -2
- package/src/modules/SavedQuerySearchRow/SavedQuerySearchRow.scss +0 -15
- package/src/modules/SavedQuerySearchRow/SavedQuerySearchRow.tsx +0 -58
- package/src/modules/SavedQuerySearchRow/index.ts +0 -2
- package/src/modules/TutorialRow/TutorialRow.scss +0 -9
- package/src/modules/TutorialRow/TutorialRow.stories.tsx +0 -43
- package/src/modules/TutorialRow/TutorialRow.tsx +0 -25
- package/src/modules/TutorialRow/index.ts +0 -2
- package/src/modules/TutorialSearchRow/TutorialSearchRow.scss +0 -5
- package/src/modules/TutorialSearchRow/TutorialSearchRow.stories.tsx +0 -44
- package/src/modules/TutorialSearchRow/TutorialSearchRow.tsx +0 -33
- package/src/modules/TutorialSearchRow/index.ts +0 -2
- package/src/modules/index.ts +0 -36
- package/src/types/declarations.d.ts +0 -15
- package/src/types/forms.ts +0 -33
- package/src/types/history.ts +0 -12
- package/src/types/navigation.ts +0 -199
- package/src/types/pathEditor.ts +0 -29
- package/src/types/queryList.ts +0 -92
- package/src/types/savedQueries.ts +0 -7
- package/src/types/tutorial.ts +0 -3
- package/src/widgets/DashboardCharts/DashboardCharts.scss +0 -25
- package/src/widgets/DashboardCharts/DashboardCharts.tsx +0 -214
- package/src/widgets/DashboardCharts/helpers/chartTypeIcons.ts +0 -33
- package/src/widgets/DashboardCharts/i18n/dicts.ts +0 -4
- package/src/widgets/DashboardCharts/i18n/en.json +0 -7
- package/src/widgets/DashboardCharts/i18n/index.ts +0 -5
- package/src/widgets/DashboardCharts/i18n/ru.json +0 -7
- package/src/widgets/DashboardCharts/index.ts +0 -2
- package/src/widgets/DashboardCharts/internal/EmptyDashboardPlaceholder.tsx +0 -26
- package/src/widgets/DashboardCharts/story/DashboardCharts.stories.scss +0 -6
- package/src/widgets/DashboardCharts/story/DashboardCharts.stories.tsx +0 -77
- package/src/widgets/DashboardCharts/story/mockData.ts +0 -419
- package/src/widgets/DashboardCharts/types.ts +0 -30
- package/src/widgets/QueriesHistory/QueriesHistory.scss +0 -3
- package/src/widgets/QueriesHistory/QueriesHistory.stories.tsx +0 -276
- package/src/widgets/QueriesHistory/QueriesHistory.tsx +0 -71
- package/src/widgets/QueriesHistory/i18n/dicts.ts +0 -4
- package/src/widgets/QueriesHistory/i18n/en.json +0 -3
- package/src/widgets/QueriesHistory/i18n/index.ts +0 -5
- package/src/widgets/QueriesHistory/i18n/ru.json +0 -3
- package/src/widgets/QueriesHistory/index.ts +0 -2
- package/src/widgets/QueriesHistory/internal/HistoryRowContent.tsx +0 -22
- package/src/widgets/QueriesNavigation/QueriesNavigation.scss +0 -9
- package/src/widgets/QueriesNavigation/QueriesNavigation.stories.tsx +0 -400
- package/src/widgets/QueriesNavigation/QueriesNavigation.tsx +0 -195
- package/src/widgets/QueriesNavigation/helpers/createEmptyDetailConfig.tsx +0 -8
- package/src/widgets/QueriesNavigation/helpers/createNavigationDetailResolver.ts +0 -28
- package/src/widgets/QueriesNavigation/helpers/createTableDetailConfig.tsx +0 -127
- package/src/widgets/QueriesNavigation/i18n/dicts.ts +0 -4
- package/src/widgets/QueriesNavigation/i18n/en.json +0 -10
- package/src/widgets/QueriesNavigation/i18n/index.ts +0 -5
- package/src/widgets/QueriesNavigation/i18n/ru.json +0 -10
- package/src/widgets/QueriesNavigation/index.ts +0 -13
- package/src/widgets/SavedQueries/SavedQueries.scss +0 -3
- package/src/widgets/SavedQueries/SavedQueries.stories.tsx +0 -192
- package/src/widgets/SavedQueries/SavedQueries.tsx +0 -77
- package/src/widgets/SavedQueries/SavedQueryRowContent.tsx +0 -26
- package/src/widgets/SavedQueries/i18n/dicts.ts +0 -4
- package/src/widgets/SavedQueries/i18n/en.json +0 -3
- package/src/widgets/SavedQueries/i18n/index.ts +0 -4
- package/src/widgets/SavedQueries/i18n/ru.json +0 -3
- package/src/widgets/SavedQueries/index.ts +0 -2
- package/src/widgets/TutorialsHistory/TutorialRowContent.tsx +0 -16
- package/src/widgets/TutorialsHistory/TutorialsHistory.scss +0 -3
- package/src/widgets/TutorialsHistory/TutorialsHistory.stories.tsx +0 -135
- package/src/widgets/TutorialsHistory/TutorialsHistory.tsx +0 -63
- package/src/widgets/TutorialsHistory/i18n/dicts.ts +0 -4
- package/src/widgets/TutorialsHistory/i18n/en.json +0 -3
- package/src/widgets/TutorialsHistory/i18n/index.ts +0 -5
- package/src/widgets/TutorialsHistory/i18n/ru.json +0 -3
- package/src/widgets/TutorialsHistory/index.ts +0 -2
- package/src/widgets/index.ts +0 -18
- package/tsconfig.json +0 -20
- package/tsconfig.publish.json +0 -11
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import "core-js/modules/es.string.trim.js";
|
|
2
|
+
import i18n from "../i18n";
|
|
3
|
+
var DEFAULT_MAX_LENGTH = 256;
|
|
4
|
+
export var stringRequiredValidator = function stringRequiredValidator(value) {
|
|
5
|
+
var maxLength = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : DEFAULT_MAX_LENGTH;
|
|
6
|
+
if (typeof value !== 'string') {
|
|
7
|
+
return i18n('alert_value-must-be-string');
|
|
8
|
+
}
|
|
9
|
+
if (!value.trim()) {
|
|
10
|
+
return i18n('alert_required-field');
|
|
11
|
+
}
|
|
12
|
+
if (value.length > maxLength) {
|
|
13
|
+
return i18n('alert_max-length', {
|
|
14
|
+
maxLength: maxLength
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
return null;
|
|
18
|
+
};
|
|
19
|
+
// #sourceMappingURL=stringRequiredValidator.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["i18n","DEFAULT_MAX_LENGTH","stringRequiredValidator","value","maxLength","arguments","length","undefined","trim"],"sources":["stringRequiredValidator.ts"],"sourcesContent":["import i18n from '../i18n';\n\nconst DEFAULT_MAX_LENGTH = 256;\n\nexport type Validator = (value: unknown) => string | null;\n\nexport const stringRequiredValidator: Validator = (\n value: unknown,\n maxLength: number = DEFAULT_MAX_LENGTH,\n) => {\n if (typeof value !== 'string') {\n return i18n('alert_value-must-be-string');\n }\n\n if (!value.trim()) {\n return i18n('alert_required-field');\n }\n\n if (value.length > maxLength) {\n return i18n('alert_max-length', {maxLength});\n }\n\n return null;\n};\n"],"mappings":";AAAA,OAAOA,IAAI;AAEX,IAAMC,kBAAkB,GAAG,GAAG;AAI9B,OAAO,IAAMC,uBAAkC,GAAG,SAArCA,uBAAkCA,CAC3CC,KAAc,EAEb;EAAA,IADDC,SAAiB,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAAGJ,kBAAkB;EAEtC,IAAI,OAAOE,KAAK,KAAK,QAAQ,EAAE;IAC3B,OAAOH,IAAI,CAAC,4BAA4B,CAAC;EAC7C;EAEA,IAAI,CAACG,KAAK,CAACK,IAAI,CAAC,CAAC,EAAE;IACf,OAAOR,IAAI,CAAC,sBAAsB,CAAC;EACvC;EAEA,IAAIG,KAAK,CAACG,MAAM,GAAGF,SAAS,EAAE;IAC1B,OAAOJ,IAAI,CAAC,kBAAkB,EAAE;MAACI,SAAS,EAATA;IAAS,CAAC,CAAC;EAChD;EAEA,OAAO,IAAI;AACf,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export var useKeyDownFormControl = function useKeyDownFormControl(onAccept, onCancel) {
|
|
2
|
+
var handleInputKeyDown = function handleInputKeyDown(event) {
|
|
3
|
+
if (event.key === 'Enter' && !event.shiftKey) {
|
|
4
|
+
event.preventDefault();
|
|
5
|
+
onAccept();
|
|
6
|
+
}
|
|
7
|
+
};
|
|
8
|
+
var handleEditorKeyDown = function handleEditorKeyDown(event) {
|
|
9
|
+
if (event.key !== 'Escape' || event.nativeEvent.isComposing) {
|
|
10
|
+
return;
|
|
11
|
+
}
|
|
12
|
+
event.preventDefault();
|
|
13
|
+
event.stopPropagation();
|
|
14
|
+
onCancel === null || onCancel === void 0 || onCancel();
|
|
15
|
+
};
|
|
16
|
+
return {
|
|
17
|
+
handleInputKeyDown: handleInputKeyDown,
|
|
18
|
+
handleEditorKeyDown: handleEditorKeyDown
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
// #sourceMappingURL=useKeyDownFormControl.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["useKeyDownFormControl","onAccept","onCancel","handleInputKeyDown","event","key","shiftKey","preventDefault","handleEditorKeyDown","nativeEvent","isComposing","stopPropagation"],"sources":["useKeyDownFormControl.ts"],"sourcesContent":["export const useKeyDownFormControl = (onAccept: () => void, onCancel: () => void) => {\n const handleInputKeyDown = (\n event: React.KeyboardEvent<HTMLInputElement | HTMLTextAreaElement>,\n ) => {\n if (event.key === 'Enter' && !event.shiftKey) {\n event.preventDefault();\n onAccept();\n }\n };\n\n const handleEditorKeyDown = (event: React.KeyboardEvent<'div'>) => {\n if (event.key !== 'Escape' || event.nativeEvent.isComposing) {\n return;\n }\n\n event.preventDefault();\n event.stopPropagation();\n onCancel?.();\n };\n\n return {handleInputKeyDown, handleEditorKeyDown};\n};\n"],"mappings":"AAAA,OAAO,IAAMA,qBAAqB,GAAG,SAAxBA,qBAAqBA,CAAIC,QAAoB,EAAEC,QAAoB,EAAK;EACjF,IAAMC,kBAAkB,GAAG,SAArBA,kBAAkBA,CACpBC,KAAkE,EACjE;IACD,IAAIA,KAAK,CAACC,GAAG,KAAK,OAAO,IAAI,CAACD,KAAK,CAACE,QAAQ,EAAE;MAC1CF,KAAK,CAACG,cAAc,CAAC,CAAC;MACtBN,QAAQ,CAAC,CAAC;IACd;EACJ,CAAC;EAED,IAAMO,mBAAmB,GAAG,SAAtBA,mBAAmBA,CAAIJ,KAAiC,EAAK;IAC/D,IAAIA,KAAK,CAACC,GAAG,KAAK,QAAQ,IAAID,KAAK,CAACK,WAAW,CAACC,WAAW,EAAE;MACzD;IACJ;IAEAN,KAAK,CAACG,cAAc,CAAC,CAAC;IACtBH,KAAK,CAACO,eAAe,CAAC,CAAC;IACvBT,QAAQ,aAARA,QAAQ,eAARA,QAAQ,CAAG,CAAC;EAChB,CAAC;EAED,OAAO;IAACC,kBAAkB,EAAlBA,kBAAkB;IAAEK,mBAAmB,EAAnBA;EAAmB,CAAC;AACpD,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
2
|
+
import { useLayoutEffect, useRef, useState } from 'react';
|
|
3
|
+
export var useLabelRef = function useLabelRef(labelText) {
|
|
4
|
+
var labelRef = useRef(null);
|
|
5
|
+
var _useState = useState(0),
|
|
6
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
7
|
+
labelWidth = _useState2[0],
|
|
8
|
+
setLabelWidth = _useState2[1];
|
|
9
|
+
useLayoutEffect(function () {
|
|
10
|
+
var label = labelRef.current;
|
|
11
|
+
if (!label) return undefined;
|
|
12
|
+
var updateLabelWidth = function updateLabelWidth() {
|
|
13
|
+
return setLabelWidth(label.offsetWidth);
|
|
14
|
+
};
|
|
15
|
+
updateLabelWidth();
|
|
16
|
+
if (typeof ResizeObserver === 'undefined') return undefined;
|
|
17
|
+
var observer = new ResizeObserver(updateLabelWidth);
|
|
18
|
+
observer.observe(label);
|
|
19
|
+
return function () {
|
|
20
|
+
return observer.disconnect();
|
|
21
|
+
};
|
|
22
|
+
}, [labelText]);
|
|
23
|
+
return {
|
|
24
|
+
labelRef: labelRef,
|
|
25
|
+
labelWidth: labelWidth
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
// #sourceMappingURL=useLabelRef.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["useLayoutEffect","useRef","useState","useLabelRef","labelText","labelRef","_useState","_useState2","_slicedToArray","labelWidth","setLabelWidth","label","current","undefined","updateLabelWidth","offsetWidth","ResizeObserver","observer","observe","disconnect"],"sources":["useLabelRef.ts"],"sourcesContent":["import {useLayoutEffect, useRef, useState} from 'react';\n\nexport const useLabelRef = (labelText: string) => {\n const labelRef = useRef<HTMLLabelElement>(null);\n const [labelWidth, setLabelWidth] = useState(0);\n\n useLayoutEffect(() => {\n const label = labelRef.current;\n\n if (!label) return undefined;\n\n const updateLabelWidth = () => setLabelWidth(label.offsetWidth);\n\n updateLabelWidth();\n\n if (typeof ResizeObserver === 'undefined') return undefined;\n\n const observer = new ResizeObserver(updateLabelWidth);\n observer.observe(label);\n\n return () => observer.disconnect();\n }, [labelText]);\n\n return {labelRef, labelWidth};\n};\n"],"mappings":";AAAA,SAAQA,eAAe,EAAEC,MAAM,EAAEC,QAAQ,QAAO,OAAO;AAEvD,OAAO,IAAMC,WAAW,GAAG,SAAdA,WAAWA,CAAIC,SAAiB,EAAK;EAC9C,IAAMC,QAAQ,GAAGJ,MAAM,CAAmB,IAAI,CAAC;EAC/C,IAAAK,SAAA,GAAoCJ,QAAQ,CAAC,CAAC,CAAC;IAAAK,UAAA,GAAAC,cAAA,CAAAF,SAAA;IAAxCG,UAAU,GAAAF,UAAA;IAAEG,aAAa,GAAAH,UAAA;EAEhCP,eAAe,CAAC,YAAM;IAClB,IAAMW,KAAK,GAAGN,QAAQ,CAACO,OAAO;IAE9B,IAAI,CAACD,KAAK,EAAE,OAAOE,SAAS;IAE5B,IAAMC,gBAAgB,GAAG,SAAnBA,gBAAgBA,CAAA;MAAA,OAASJ,aAAa,CAACC,KAAK,CAACI,WAAW,CAAC;IAAA;IAE/DD,gBAAgB,CAAC,CAAC;IAElB,IAAI,OAAOE,cAAc,KAAK,WAAW,EAAE,OAAOH,SAAS;IAE3D,IAAMI,QAAQ,GAAG,IAAID,cAAc,CAACF,gBAAgB,CAAC;IACrDG,QAAQ,CAACC,OAAO,CAACP,KAAK,CAAC;IAEvB,OAAO;MAAA,OAAMM,QAAQ,CAACE,UAAU,CAAC,CAAC;IAAA;EACtC,CAAC,EAAE,CAACf,SAAS,CAAC,CAAC;EAEf,OAAO;IAACC,QAAQ,EAARA,QAAQ;IAAEI,UAAU,EAAVA;EAAU,CAAC;AACjC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
en: {
|
|
3
|
+
field_link: string;
|
|
4
|
+
field_token: string;
|
|
5
|
+
field_name: string;
|
|
6
|
+
action_save: string;
|
|
7
|
+
action_cancel: string;
|
|
8
|
+
"alert_value-must-be-string": string;
|
|
9
|
+
"alert_required-field": string;
|
|
10
|
+
"alert_max-length": string;
|
|
11
|
+
};
|
|
12
|
+
ru: {
|
|
13
|
+
field_link: string;
|
|
14
|
+
field_token: string;
|
|
15
|
+
field_name: string;
|
|
16
|
+
action_save: string;
|
|
17
|
+
action_cancel: string;
|
|
18
|
+
"alert_value-must-be-string": string;
|
|
19
|
+
"alert_required-field": string;
|
|
20
|
+
"alert_max-length": string;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["en","ru"],"sources":["dicts.ts"],"sourcesContent":["import en from './en.json';\nimport ru from './ru.json';\n\nexport default {en, ru};\n"],"mappings":"AAAA,OAAOA,EAAE;AACT,OAAOC,EAAE;AAET,eAAe;EAACD,EAAE,EAAFA,EAAE;EAAEC,EAAE,EAAFA;AAAE,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"field_link": "Link:",
|
|
3
|
+
"field_token": "Token:",
|
|
4
|
+
"field_name": "Name:",
|
|
5
|
+
"action_save": "Save",
|
|
6
|
+
"action_cancel": "Cancel",
|
|
7
|
+
"alert_value-must-be-string": "Value must be a string",
|
|
8
|
+
"alert_required-field": "Required field",
|
|
9
|
+
"alert_max-length": "Maximum length is {{maxLength}}"
|
|
10
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
declare const _default: ((key: "field_link" | "field_token" | "field_name" | "action_save" | "action_cancel" | "alert_value-must-be-string" | "alert_required-field" | "alert_max-length", params?: import("@gravity-ui/i18n").Params) => string) & {
|
|
2
|
+
keysetData: {
|
|
3
|
+
"qp:attachment-list": Record<"field_link" | "field_token" | "field_name" | "action_save" | "action_cancel" | "alert_value-must-be-string" | "alert_required-field" | "alert_max-length", import("@gravity-ui/i18n").KeyData>;
|
|
4
|
+
};
|
|
5
|
+
};
|
|
6
|
+
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["addI18Keysets","dicts"],"sources":["index.ts"],"sourcesContent":["import {addI18Keysets} from '../../../i18n';\n\nimport dicts from './dicts';\n\nexport default addI18Keysets('qp:attachment-list', dicts);\n"],"mappings":"AAAA,SAAQA,aAAa;AAErB,OAAOC,KAAK;AAEZ,eAAeD,aAAa,CAAC,oBAAoB,EAAEC,KAAK,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"field_link": "Ссылка:",
|
|
3
|
+
"field_token": "Токен:",
|
|
4
|
+
"field_name": "Имя:",
|
|
5
|
+
"action_save": "Сохранить",
|
|
6
|
+
"action_cancel": "Отменить",
|
|
7
|
+
"alert_value-must-be-string": "Значение должно быть строкой",
|
|
8
|
+
"alert_required-field": "Обязательное поле",
|
|
9
|
+
"alert_max-length": "Максимальная длина — {{maxLength}}"
|
|
10
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["AttachmentList"],"sources":["index.ts"],"sourcesContent":["export {AttachmentList} from './AttachmentList';\nexport type {AttachmentListProps} from './AttachmentList';\nexport * from './internal/EditAttachmentItem';\nexport * from './internal/AttachmentItem';\n"],"mappings":"AAAA,SAAQA,cAAc;AAEtB;AACA","ignoreList":[]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
.qp-attachment-item__info {
|
|
2
|
+
flex: 1;
|
|
3
|
+
min-width: 0;
|
|
4
|
+
}
|
|
5
|
+
.qp-attachment-item__actions {
|
|
6
|
+
flex-shrink: 0;
|
|
7
|
+
}
|
|
8
|
+
.qp-attachment-item__attachment-name {
|
|
9
|
+
flex: 1;
|
|
10
|
+
min-width: 0;
|
|
11
|
+
}
|
|
12
|
+
.qp-attachment-item_wasAdded {
|
|
13
|
+
background-color: var(--g-color-base-positive-light);
|
|
14
|
+
}
|
|
15
|
+
.qp-attachment-item_wasEdited {
|
|
16
|
+
background-color: var(--g-color-base-info-light);
|
|
17
|
+
}
|
|
18
|
+
/*# sourceMappingURL=AttachmentItem.css.map */
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["AttachmentItem.scss"],"names":[],"mappings":"AACI;EACI,OAAA;EACA,YAAA;AAAR;AAGI;EACI,cAAA;AADR;AAII;EACI,OAAA;EACA,YAAA;AAFR;AAKI;EACI,oDAAA;AAHR;AAMI;EACI,gDAAA;AAJR","file":"AttachmentItem.css","sourcesContent":[".qp-attachment-item {\n &__info {\n flex: 1;\n min-width: 0;\n }\n\n &__actions {\n flex-shrink: 0;\n }\n\n &__attachment-name {\n flex: 1;\n min-width: 0;\n }\n\n &_wasAdded {\n background-color: var(--g-color-base-positive-light);\n }\n\n &_wasEdited {\n background-color: var(--g-color-base-info-light);\n }\n}\n"],"sourceRoot":""}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './AttachmentItem.scss';
|
|
3
|
+
export type AttachmentItemProps = {
|
|
4
|
+
attachment: {
|
|
5
|
+
id: string;
|
|
6
|
+
name: string;
|
|
7
|
+
link?: string;
|
|
8
|
+
};
|
|
9
|
+
wasEdited?: boolean;
|
|
10
|
+
wasAdded?: boolean;
|
|
11
|
+
onEdit?: (attachment: AttachmentItemProps['attachment']) => void;
|
|
12
|
+
onDelete?: (attachment: AttachmentItemProps['attachment']) => void;
|
|
13
|
+
onRevert?: (attachment: AttachmentItemProps['attachment']) => void;
|
|
14
|
+
isDeleted?: boolean;
|
|
15
|
+
};
|
|
16
|
+
export declare const AttachmentItem: ({ attachment, wasAdded, wasEdited, onEdit, onDelete, onRevert, isDeleted, }: AttachmentItemProps) => React.JSX.Element;
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
2
|
+
import "core-js/modules/es.function.name.js";
|
|
3
|
+
import "core-js/modules/es.string.link.js";
|
|
4
|
+
import React, { useMemo, useState } from 'react';
|
|
5
|
+
import { Button, Flex, Icon, Text } from '@gravity-ui/uikit';
|
|
6
|
+
import { ArrowRotateLeft, Link, Pencil, TrashBin } from '@gravity-ui/icons';
|
|
7
|
+
import { getAttachmentIcon } from "../../helpers/getIconByAttachmentName";
|
|
8
|
+
import cn from 'bem-cn-lite';
|
|
9
|
+
import "./AttachmentItem.css";
|
|
10
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
11
|
+
var block = cn('qp-attachment-item');
|
|
12
|
+
export var AttachmentItem = function AttachmentItem(_ref) {
|
|
13
|
+
var attachment = _ref.attachment,
|
|
14
|
+
wasAdded = _ref.wasAdded,
|
|
15
|
+
wasEdited = _ref.wasEdited,
|
|
16
|
+
onEdit = _ref.onEdit,
|
|
17
|
+
onDelete = _ref.onDelete,
|
|
18
|
+
onRevert = _ref.onRevert,
|
|
19
|
+
isDeleted = _ref.isDeleted;
|
|
20
|
+
var _useState = useState(false),
|
|
21
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
22
|
+
isHovered = _useState2[0],
|
|
23
|
+
setIsHovered = _useState2[1];
|
|
24
|
+
var attachmentIcon = useMemo(function () {
|
|
25
|
+
if (typeof attachment.link === 'string') return Link;
|
|
26
|
+
return getAttachmentIcon(attachment.name);
|
|
27
|
+
}, [attachment.name, attachment.link]);
|
|
28
|
+
return /*#__PURE__*/_jsxs(Flex, {
|
|
29
|
+
width: "100%",
|
|
30
|
+
height: "32px",
|
|
31
|
+
onMouseEnter: function onMouseEnter() {
|
|
32
|
+
return setIsHovered(true);
|
|
33
|
+
},
|
|
34
|
+
onMouseLeave: function onMouseLeave() {
|
|
35
|
+
return setIsHovered(false);
|
|
36
|
+
},
|
|
37
|
+
alignItems: "center",
|
|
38
|
+
justifyContent: "space-between",
|
|
39
|
+
spacing: {
|
|
40
|
+
px: 4
|
|
41
|
+
},
|
|
42
|
+
className: block({
|
|
43
|
+
wasEdited: wasEdited,
|
|
44
|
+
wasAdded: wasAdded
|
|
45
|
+
}),
|
|
46
|
+
children: [/*#__PURE__*/_jsxs(Flex, {
|
|
47
|
+
gap: 2,
|
|
48
|
+
alignItems: "center",
|
|
49
|
+
className: block('info'),
|
|
50
|
+
children: [/*#__PURE__*/_jsx(Icon, {
|
|
51
|
+
width: 16,
|
|
52
|
+
className: block('attachment-icon'),
|
|
53
|
+
data: attachmentIcon
|
|
54
|
+
}), /*#__PURE__*/_jsx(Text, {
|
|
55
|
+
variant: "body-1",
|
|
56
|
+
ellipsis: true,
|
|
57
|
+
className: block('attachment-name'),
|
|
58
|
+
children: attachment.name
|
|
59
|
+
})]
|
|
60
|
+
}), isHovered && !isDeleted && /*#__PURE__*/_jsxs(Flex, {
|
|
61
|
+
gap: 1,
|
|
62
|
+
className: block('actions'),
|
|
63
|
+
children: [/*#__PURE__*/_jsx(Button, {
|
|
64
|
+
size: "s",
|
|
65
|
+
view: "flat",
|
|
66
|
+
onClick: function onClick() {
|
|
67
|
+
return onEdit === null || onEdit === void 0 ? void 0 : onEdit(attachment);
|
|
68
|
+
},
|
|
69
|
+
children: /*#__PURE__*/_jsx(Icon, {
|
|
70
|
+
data: Pencil
|
|
71
|
+
})
|
|
72
|
+
}), /*#__PURE__*/_jsx(Button, {
|
|
73
|
+
size: "s",
|
|
74
|
+
view: "flat",
|
|
75
|
+
onClick: function onClick() {
|
|
76
|
+
return onDelete === null || onDelete === void 0 ? void 0 : onDelete(attachment);
|
|
77
|
+
},
|
|
78
|
+
children: /*#__PURE__*/_jsx(Icon, {
|
|
79
|
+
data: TrashBin
|
|
80
|
+
})
|
|
81
|
+
})]
|
|
82
|
+
}), isHovered && isDeleted && /*#__PURE__*/_jsx(Flex, {
|
|
83
|
+
gap: 1,
|
|
84
|
+
className: block('actions'),
|
|
85
|
+
children: /*#__PURE__*/_jsx(Button, {
|
|
86
|
+
size: "s",
|
|
87
|
+
view: "flat",
|
|
88
|
+
onClick: function onClick() {
|
|
89
|
+
return onRevert === null || onRevert === void 0 ? void 0 : onRevert(attachment);
|
|
90
|
+
},
|
|
91
|
+
children: /*#__PURE__*/_jsx(Icon, {
|
|
92
|
+
data: ArrowRotateLeft
|
|
93
|
+
})
|
|
94
|
+
})
|
|
95
|
+
})]
|
|
96
|
+
});
|
|
97
|
+
};
|
|
98
|
+
// #sourceMappingURL=AttachmentItem.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","useMemo","useState","Button","Flex","Icon","Text","ArrowRotateLeft","Link","Pencil","TrashBin","getAttachmentIcon","cn","jsx","_jsx","jsxs","_jsxs","block","AttachmentItem","_ref","attachment","wasAdded","wasEdited","onEdit","onDelete","onRevert","isDeleted","_useState","_useState2","_slicedToArray","isHovered","setIsHovered","attachmentIcon","link","name","width","height","onMouseEnter","onMouseLeave","alignItems","justifyContent","spacing","px","className","children","gap","data","variant","ellipsis","size","view","onClick"],"sources":["AttachmentItem.tsx"],"sourcesContent":["import React, {useMemo, useState} from 'react';\nimport {Button, Flex, Icon, Text} from '@gravity-ui/uikit';\nimport {ArrowRotateLeft, Link, Pencil, TrashBin} from '@gravity-ui/icons';\nimport {getAttachmentIcon} from '../../helpers/getIconByAttachmentName';\nimport cn from 'bem-cn-lite';\nimport './AttachmentItem.scss';\n\nexport type AttachmentItemProps = {\n attachment: {id: string; name: string; link?: string};\n wasEdited?: boolean;\n wasAdded?: boolean;\n onEdit?: (attachment: AttachmentItemProps['attachment']) => void;\n onDelete?: (attachment: AttachmentItemProps['attachment']) => void;\n onRevert?: (attachment: AttachmentItemProps['attachment']) => void;\n isDeleted?: boolean;\n};\n\nconst block = cn('qp-attachment-item');\n\nexport const AttachmentItem = ({\n attachment,\n wasAdded,\n wasEdited,\n onEdit,\n onDelete,\n onRevert,\n isDeleted,\n}: AttachmentItemProps) => {\n const [isHovered, setIsHovered] = useState(false);\n\n const attachmentIcon = useMemo(() => {\n if (typeof attachment.link === 'string') return Link;\n return getAttachmentIcon(attachment.name);\n }, [attachment.name, attachment.link]);\n\n return (\n <Flex\n width=\"100%\"\n height=\"32px\"\n onMouseEnter={() => setIsHovered(true)}\n onMouseLeave={() => setIsHovered(false)}\n alignItems=\"center\"\n justifyContent=\"space-between\"\n spacing={{px: 4}}\n className={block({wasEdited, wasAdded})}\n >\n <Flex gap={2} alignItems=\"center\" className={block('info')}>\n <Icon width={16} className={block('attachment-icon')} data={attachmentIcon} />\n <Text variant=\"body-1\" ellipsis className={block('attachment-name')}>\n {attachment.name}\n </Text>\n </Flex>\n\n {isHovered && !isDeleted && (\n <Flex gap={1} className={block('actions')}>\n <Button size=\"s\" view=\"flat\" onClick={() => onEdit?.(attachment)}>\n <Icon data={Pencil} />\n </Button>\n\n <Button size=\"s\" view=\"flat\" onClick={() => onDelete?.(attachment)}>\n <Icon data={TrashBin} />\n </Button>\n </Flex>\n )}\n\n {isHovered && isDeleted && (\n <Flex gap={1} className={block('actions')}>\n <Button size=\"s\" view=\"flat\" onClick={() => onRevert?.(attachment)}>\n <Icon data={ArrowRotateLeft} />\n </Button>\n </Flex>\n )}\n </Flex>\n );\n};\n"],"mappings":";;;AAAA,OAAOA,KAAK,IAAGC,OAAO,EAAEC,QAAQ,QAAO,OAAO;AAC9C,SAAQC,MAAM,EAAEC,IAAI,EAAEC,IAAI,EAAEC,IAAI,QAAO,mBAAmB;AAC1D,SAAQC,eAAe,EAAEC,IAAI,EAAEC,MAAM,EAAEC,QAAQ,QAAO,mBAAmB;AACzE,SAAQC,iBAAiB;AACzB,OAAOC,EAAE,MAAM,aAAa;AAC5B;AAA+B,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAY/B,IAAMC,KAAK,GAAGL,EAAE,CAAC,oBAAoB,CAAC;AAEtC,OAAO,IAAMM,cAAc,GAAG,SAAjBA,cAAcA,CAAAC,IAAA,EAQA;EAAA,IAPvBC,UAAU,GAAAD,IAAA,CAAVC,UAAU;IACVC,QAAQ,GAAAF,IAAA,CAARE,QAAQ;IACRC,SAAS,GAAAH,IAAA,CAATG,SAAS;IACTC,MAAM,GAAAJ,IAAA,CAANI,MAAM;IACNC,QAAQ,GAAAL,IAAA,CAARK,QAAQ;IACRC,QAAQ,GAAAN,IAAA,CAARM,QAAQ;IACRC,SAAS,GAAAP,IAAA,CAATO,SAAS;EAET,IAAAC,SAAA,GAAkCzB,QAAQ,CAAC,KAAK,CAAC;IAAA0B,UAAA,GAAAC,cAAA,CAAAF,SAAA;IAA1CG,SAAS,GAAAF,UAAA;IAAEG,YAAY,GAAAH,UAAA;EAE9B,IAAMI,cAAc,GAAG/B,OAAO,CAAC,YAAM;IACjC,IAAI,OAAOmB,UAAU,CAACa,IAAI,KAAK,QAAQ,EAAE,OAAOzB,IAAI;IACpD,OAAOG,iBAAiB,CAACS,UAAU,CAACc,IAAI,CAAC;EAC7C,CAAC,EAAE,CAACd,UAAU,CAACc,IAAI,EAAEd,UAAU,CAACa,IAAI,CAAC,CAAC;EAEtC,oBACIjB,KAAA,CAACZ,IAAI;IACD+B,KAAK,EAAC,MAAM;IACZC,MAAM,EAAC,MAAM;IACbC,YAAY,EAAE,SAAdA,YAAYA,CAAA;MAAA,OAAQN,YAAY,CAAC,IAAI,CAAC;IAAA,CAAC;IACvCO,YAAY,EAAE,SAAdA,YAAYA,CAAA;MAAA,OAAQP,YAAY,CAAC,KAAK,CAAC;IAAA,CAAC;IACxCQ,UAAU,EAAC,QAAQ;IACnBC,cAAc,EAAC,eAAe;IAC9BC,OAAO,EAAE;MAACC,EAAE,EAAE;IAAC,CAAE;IACjBC,SAAS,EAAE1B,KAAK,CAAC;MAACK,SAAS,EAATA,SAAS;MAAED,QAAQ,EAARA;IAAQ,CAAC,CAAE;IAAAuB,QAAA,gBAExC5B,KAAA,CAACZ,IAAI;MAACyC,GAAG,EAAE,CAAE;MAACN,UAAU,EAAC,QAAQ;MAACI,SAAS,EAAE1B,KAAK,CAAC,MAAM,CAAE;MAAA2B,QAAA,gBACvD9B,IAAA,CAACT,IAAI;QAAC8B,KAAK,EAAE,EAAG;QAACQ,SAAS,EAAE1B,KAAK,CAAC,iBAAiB,CAAE;QAAC6B,IAAI,EAAEd;MAAe,CAAE,CAAC,eAC9ElB,IAAA,CAACR,IAAI;QAACyC,OAAO,EAAC,QAAQ;QAACC,QAAQ;QAACL,SAAS,EAAE1B,KAAK,CAAC,iBAAiB,CAAE;QAAA2B,QAAA,EAC/DxB,UAAU,CAACc;MAAI,CACd,CAAC;IAAA,CACL,CAAC,EAENJ,SAAS,IAAI,CAACJ,SAAS,iBACpBV,KAAA,CAACZ,IAAI;MAACyC,GAAG,EAAE,CAAE;MAACF,SAAS,EAAE1B,KAAK,CAAC,SAAS,CAAE;MAAA2B,QAAA,gBACtC9B,IAAA,CAACX,MAAM;QAAC8C,IAAI,EAAC,GAAG;QAACC,IAAI,EAAC,MAAM;QAACC,OAAO,EAAE,SAATA,OAAOA,CAAA;UAAA,OAAQ5B,MAAM,aAANA,MAAM,uBAANA,MAAM,CAAGH,UAAU,CAAC;QAAA,CAAC;QAAAwB,QAAA,eAC7D9B,IAAA,CAACT,IAAI;UAACyC,IAAI,EAAErC;QAAO,CAAE;MAAC,CAClB,CAAC,eAETK,IAAA,CAACX,MAAM;QAAC8C,IAAI,EAAC,GAAG;QAACC,IAAI,EAAC,MAAM;QAACC,OAAO,EAAE,SAATA,OAAOA,CAAA;UAAA,OAAQ3B,QAAQ,aAARA,QAAQ,uBAARA,QAAQ,CAAGJ,UAAU,CAAC;QAAA,CAAC;QAAAwB,QAAA,eAC/D9B,IAAA,CAACT,IAAI;UAACyC,IAAI,EAAEpC;QAAS,CAAE;MAAC,CACpB,CAAC;IAAA,CACP,CACT,EAEAoB,SAAS,IAAIJ,SAAS,iBACnBZ,IAAA,CAACV,IAAI;MAACyC,GAAG,EAAE,CAAE;MAACF,SAAS,EAAE1B,KAAK,CAAC,SAAS,CAAE;MAAA2B,QAAA,eACtC9B,IAAA,CAACX,MAAM;QAAC8C,IAAI,EAAC,GAAG;QAACC,IAAI,EAAC,MAAM;QAACC,OAAO,EAAE,SAATA,OAAOA,CAAA;UAAA,OAAQ1B,QAAQ,aAARA,QAAQ,uBAARA,QAAQ,CAAGL,UAAU,CAAC;QAAA,CAAC;QAAAwB,QAAA,eAC/D9B,IAAA,CAACT,IAAI;UAACyC,IAAI,EAAEvC;QAAgB,CAAE;MAAC,CAC3B;IAAC,CACP,CACT;EAAA,CACC,CAAC;AAEf,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
.qp-attachment-item {
|
|
2
|
+
&__info {
|
|
3
|
+
flex: 1;
|
|
4
|
+
min-width: 0;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
&__actions {
|
|
8
|
+
flex-shrink: 0;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
&__attachment-name {
|
|
12
|
+
flex: 1;
|
|
13
|
+
min-width: 0;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
&_wasAdded {
|
|
17
|
+
background-color: var(--g-color-base-positive-light);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
&_wasEdited {
|
|
21
|
+
background-color: var(--g-color-base-info-light);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["AttachmentItem"],"sources":["index.ts"],"sourcesContent":["export {AttachmentItem} from './AttachmentItem';\nexport type {AttachmentItemProps} from './AttachmentItem';\n"],"mappings":"AAAA,SAAQA,cAAc","ignoreList":[]}
|
package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditAttachmentItem.d.ts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { EditFileItemProps } from './FileEdit';
|
|
3
|
+
import type { EditLinkItemProps } from './EditLinkItem';
|
|
4
|
+
export type EditAttachmentItemProps = (EditFileItemProps & {
|
|
5
|
+
type: 'file';
|
|
6
|
+
}) | (EditLinkItemProps & {
|
|
7
|
+
type: 'link';
|
|
8
|
+
});
|
|
9
|
+
export declare const EditAttachmentItem: ({ ...props }: EditAttachmentItemProps) => React.JSX.Element;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
+
import _objectDestructuringEmpty from "@babel/runtime/helpers/objectDestructuringEmpty";
|
|
3
|
+
import "core-js/modules/es.object.assign.js";
|
|
4
|
+
import React from 'react';
|
|
5
|
+
import { FileEdit } from "./FileEdit";
|
|
6
|
+
import { EditLinkItem } from "./EditLinkItem";
|
|
7
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
8
|
+
export var EditAttachmentItem = function EditAttachmentItem(_ref) {
|
|
9
|
+
var props = Object.assign({}, (_objectDestructuringEmpty(_ref), _ref));
|
|
10
|
+
if (props.type === 'file') {
|
|
11
|
+
return /*#__PURE__*/_jsx(FileEdit, _objectSpread({}, props));
|
|
12
|
+
}
|
|
13
|
+
return /*#__PURE__*/_jsx(EditLinkItem, _objectSpread({}, props));
|
|
14
|
+
};
|
|
15
|
+
// #sourceMappingURL=EditAttachmentItem.js.map
|
package/build/esm/components/AttachmentList/internal/EditAttachmentItem/EditAttachmentItem.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","FileEdit","EditLinkItem","jsx","_jsx","EditAttachmentItem","_ref","props","Object","assign","_objectDestructuringEmpty","type","_objectSpread"],"sources":["EditAttachmentItem.tsx"],"sourcesContent":["import React from 'react';\nimport {FileEdit} from './FileEdit';\nimport {EditLinkItem} from './EditLinkItem';\nimport type {EditFileItemProps} from './FileEdit';\nimport type {EditLinkItemProps} from './EditLinkItem';\n\nexport type EditAttachmentItemProps =\n | (EditFileItemProps & {\n type: 'file';\n })\n | (EditLinkItemProps & {\n type: 'link';\n });\n\nexport const EditAttachmentItem = ({...props}: EditAttachmentItemProps) => {\n if (props.type === 'file') {\n return <FileEdit {...props} />;\n }\n\n return <EditLinkItem {...props} />;\n};\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAQC,QAAQ;AAChB,SAAQC,YAAY;AAAwB,SAAAC,GAAA,IAAAC,IAAA;AAY5C,OAAO,IAAMC,kBAAkB,GAAG,SAArBA,kBAAkBA,CAAAC,IAAA,EAA4C;EAAA,IAApCC,KAAK,GAAAC,MAAA,CAAAC,MAAA,MAAAC,yBAAA,CAAAJ,IAAA,GAAAA,IAAA;EACxC,IAAIC,KAAK,CAACI,IAAI,KAAK,MAAM,EAAE;IACvB,oBAAOP,IAAA,CAACH,QAAQ,EAAAW,aAAA,KAAKL,KAAK,CAAG,CAAC;EAClC;EAEA,oBAAOH,IAAA,CAACF,YAAY,EAAAU,aAAA,KAAKL,KAAK,CAAG,CAAC;AACtC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
.edit-link-item__link-field-container {
|
|
2
|
+
padding: 1px;
|
|
3
|
+
}
|
|
4
|
+
.edit-link-item__link-field-label {
|
|
5
|
+
position: absolute;
|
|
6
|
+
z-index: 1;
|
|
7
|
+
top: calc(var(--g-spacing-1) + 1px);
|
|
8
|
+
left: var(--g-spacing-2);
|
|
9
|
+
font-weight: 600;
|
|
10
|
+
}
|
|
11
|
+
.edit-link-item .g-select {
|
|
12
|
+
padding: 1px;
|
|
13
|
+
}
|
|
14
|
+
.edit-link-item .g-text-input {
|
|
15
|
+
padding: 1px;
|
|
16
|
+
}
|
|
17
|
+
/*# sourceMappingURL=EditLinkItem.css.map */
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["EditLinkItem.scss"],"names":[],"mappings":"AACI;EACI,YAAA;AAAR;AAGI;EACI,kBAAA;EACA,UAAA;EACA,mCAAA;EACA,wBAAA;EACA,gBAAA;AADR;AAII;EACI,YAAA;AAFR;AAKI;EACI,YAAA;AAHR","file":"EditLinkItem.css","sourcesContent":[".edit-link-item {\n &__link-field-container {\n padding: 1px;\n }\n\n &__link-field-label {\n position: absolute;\n z-index: 1;\n inset-block-start: calc(var(--g-spacing-1) + 1px);\n inset-inline-start: var(--g-spacing-2);\n font-weight: 600;\n }\n\n .g-select {\n padding: 1px;\n }\n\n .g-text-input {\n padding: 1px;\n }\n}"],"sourceRoot":""}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ObjectLinkValidator } from '../../helpers/objectLinkValidator';
|
|
3
|
+
import './EditLinkItem.scss';
|
|
4
|
+
export type EditLinkValues = {
|
|
5
|
+
link: string;
|
|
6
|
+
token: string;
|
|
7
|
+
name: string;
|
|
8
|
+
};
|
|
9
|
+
export type EditLinkItemProps = {
|
|
10
|
+
linkLabel?: string;
|
|
11
|
+
tokenLabel?: string;
|
|
12
|
+
nameLabel?: string;
|
|
13
|
+
onAccept?: (values: EditLinkValues) => void;
|
|
14
|
+
onCancel?: () => void;
|
|
15
|
+
onChange?: (pathedValues: EditLinkValues) => void;
|
|
16
|
+
tokens?: {
|
|
17
|
+
value: string;
|
|
18
|
+
title: string;
|
|
19
|
+
}[];
|
|
20
|
+
values?: EditLinkValues;
|
|
21
|
+
defaultValues?: EditLinkValues;
|
|
22
|
+
validator?: ObjectLinkValidator;
|
|
23
|
+
};
|
|
24
|
+
export declare const EditLinkItem: ({ linkLabel: cutomerLinkLabel, tokenLabel: customerTokenLabel, nameLabel: customeNameLabel, onAccept, onCancel, onChange, tokens, values: customerValues, validator, defaultValues, }: EditLinkItemProps) => React.JSX.Element;
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
|
+
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
3
|
+
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
4
|
+
import "core-js/modules/es.array.iterator.js";
|
|
5
|
+
import "core-js/modules/es.array.map.js";
|
|
6
|
+
import "core-js/modules/es.function.name.js";
|
|
7
|
+
import "core-js/modules/es.iterator.constructor.js";
|
|
8
|
+
import "core-js/modules/es.iterator.map.js";
|
|
9
|
+
import "core-js/modules/es.object.to-string.js";
|
|
10
|
+
import "core-js/modules/es.string.link.js";
|
|
11
|
+
import "core-js/modules/web.dom-collections.iterator.js";
|
|
12
|
+
import React, { useId, useRef, useState } from 'react';
|
|
13
|
+
import { Box, Button, Flex, Icon, Select, Text, TextArea, TextInput } from '@gravity-ui/uikit';
|
|
14
|
+
import { Check, Xmark } from '@gravity-ui/icons';
|
|
15
|
+
import { useLabelRef } from "../../hooks/useLabelRef";
|
|
16
|
+
import { useKeyDownFormControl } from "../../hooks/useKeyDownFormControl";
|
|
17
|
+
import { objectLinkValidator } from "../../helpers/objectLinkValidator";
|
|
18
|
+
import cn from 'bem-cn-lite';
|
|
19
|
+
import i18n from "../../i18n";
|
|
20
|
+
import "./EditLinkItem.css";
|
|
21
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
22
|
+
var block = cn('edit-link-item');
|
|
23
|
+
export var EditLinkItem = function EditLinkItem(_ref) {
|
|
24
|
+
var cutomerLinkLabel = _ref.linkLabel,
|
|
25
|
+
customerTokenLabel = _ref.tokenLabel,
|
|
26
|
+
customeNameLabel = _ref.nameLabel,
|
|
27
|
+
onAccept = _ref.onAccept,
|
|
28
|
+
onCancel = _ref.onCancel,
|
|
29
|
+
onChange = _ref.onChange,
|
|
30
|
+
tokens = _ref.tokens,
|
|
31
|
+
customerValues = _ref.values,
|
|
32
|
+
_ref$validator = _ref.validator,
|
|
33
|
+
validator = _ref$validator === void 0 ? objectLinkValidator : _ref$validator,
|
|
34
|
+
defaultValues = _ref.defaultValues;
|
|
35
|
+
var _useState = useState(_objectSpread(_objectSpread({
|
|
36
|
+
link: '',
|
|
37
|
+
token: '',
|
|
38
|
+
name: ''
|
|
39
|
+
}, customerValues), defaultValues !== null && defaultValues !== void 0 ? defaultValues : {})),
|
|
40
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
41
|
+
innerValues = _useState2[0],
|
|
42
|
+
setInnerValues = _useState2[1];
|
|
43
|
+
var _useState3 = useState(null),
|
|
44
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
45
|
+
errors = _useState4[0],
|
|
46
|
+
setErrors = _useState4[1];
|
|
47
|
+
var linkInputId = useId();
|
|
48
|
+
var linkLabel = cutomerLinkLabel !== null && cutomerLinkLabel !== void 0 ? cutomerLinkLabel : i18n('field_link');
|
|
49
|
+
var tokenLabel = customerTokenLabel !== null && customerTokenLabel !== void 0 ? customerTokenLabel : i18n('field_token');
|
|
50
|
+
var nameLabel = customeNameLabel !== null && customeNameLabel !== void 0 ? customeNameLabel : i18n('field_name');
|
|
51
|
+
var values = customerValues !== null && customerValues !== void 0 ? customerValues : innerValues;
|
|
52
|
+
var _useLabelRef = useLabelRef(linkLabel),
|
|
53
|
+
labelRef = _useLabelRef.labelRef,
|
|
54
|
+
labelWidth = _useLabelRef.labelWidth;
|
|
55
|
+
var wasSubmittedRef = useRef(false);
|
|
56
|
+
var isTokenRequired = tokens && (tokens === null || tokens === void 0 ? void 0 : tokens.length) > 0;
|
|
57
|
+
var handleUpdate = function handleUpdate(key, patcValue) {
|
|
58
|
+
var newValues = _objectSpread(_objectSpread({}, values), {}, _defineProperty({}, key, patcValue));
|
|
59
|
+
if (errors || wasSubmittedRef.current) {
|
|
60
|
+
setErrors(validator(newValues, isTokenRequired));
|
|
61
|
+
}
|
|
62
|
+
setInnerValues(newValues);
|
|
63
|
+
onChange === null || onChange === void 0 || onChange(newValues);
|
|
64
|
+
};
|
|
65
|
+
var handleAccept = function handleAccept() {
|
|
66
|
+
var validResult = validator(values, isTokenRequired);
|
|
67
|
+
wasSubmittedRef.current = true;
|
|
68
|
+
if (validResult) {
|
|
69
|
+
setErrors(validResult);
|
|
70
|
+
return;
|
|
71
|
+
}
|
|
72
|
+
onAccept === null || onAccept === void 0 || onAccept(values);
|
|
73
|
+
};
|
|
74
|
+
var handleCancel = function handleCancel() {
|
|
75
|
+
onCancel === null || onCancel === void 0 || onCancel();
|
|
76
|
+
};
|
|
77
|
+
var handleLinkScroll = function handleLinkScroll(event) {
|
|
78
|
+
if (labelRef.current) {
|
|
79
|
+
labelRef.current.style.transform = "translateY(-".concat(event.currentTarget.scrollTop, "px)");
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
var _useKeyDownFormContro = useKeyDownFormControl(handleAccept, handleCancel),
|
|
83
|
+
handleEditorKeyDown = _useKeyDownFormContro.handleEditorKeyDown,
|
|
84
|
+
handleInputKeyDown = _useKeyDownFormContro.handleInputKeyDown;
|
|
85
|
+
return /*#__PURE__*/_jsxs(Flex, {
|
|
86
|
+
onKeyDown: handleEditorKeyDown,
|
|
87
|
+
className: block(),
|
|
88
|
+
width: "100%",
|
|
89
|
+
spacing: {
|
|
90
|
+
px: 4,
|
|
91
|
+
py: 3
|
|
92
|
+
},
|
|
93
|
+
direction: "column",
|
|
94
|
+
gap: 2,
|
|
95
|
+
children: [/*#__PURE__*/_jsxs(Box, {
|
|
96
|
+
overflow: "hidden",
|
|
97
|
+
className: block('link-field-container'),
|
|
98
|
+
position: "relative",
|
|
99
|
+
children: [/*#__PURE__*/_jsx(Text, {
|
|
100
|
+
ref: labelRef,
|
|
101
|
+
as: "label",
|
|
102
|
+
htmlFor: linkInputId,
|
|
103
|
+
className: block('link-field-label'),
|
|
104
|
+
children: linkLabel
|
|
105
|
+
}), /*#__PURE__*/_jsx(TextArea, {
|
|
106
|
+
id: linkInputId,
|
|
107
|
+
value: values.link,
|
|
108
|
+
minRows: 3,
|
|
109
|
+
maxRows: 5,
|
|
110
|
+
hasClear: true,
|
|
111
|
+
autoFocus: true,
|
|
112
|
+
error: errors === null || errors === void 0 ? void 0 : errors.link,
|
|
113
|
+
errorMessage: errors === null || errors === void 0 ? void 0 : errors.link,
|
|
114
|
+
onKeyDown: handleInputKeyDown,
|
|
115
|
+
onUpdate: function onUpdate(v) {
|
|
116
|
+
return handleUpdate('link', v);
|
|
117
|
+
},
|
|
118
|
+
controlProps: {
|
|
119
|
+
onScroll: handleLinkScroll,
|
|
120
|
+
style: {
|
|
121
|
+
textIndent: labelWidth ? labelWidth + 2 : undefined
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
})]
|
|
125
|
+
}), tokens && /*#__PURE__*/_jsx(Select, {
|
|
126
|
+
filterable: true,
|
|
127
|
+
value: [values.token],
|
|
128
|
+
label: tokenLabel,
|
|
129
|
+
errorMessage: errors === null || errors === void 0 ? void 0 : errors.token,
|
|
130
|
+
validationState: errors !== null && errors !== void 0 && errors.token ? 'invalid' : undefined,
|
|
131
|
+
onUpdate: function onUpdate(v) {
|
|
132
|
+
return handleUpdate('token', v[0]);
|
|
133
|
+
},
|
|
134
|
+
children: tokens.map(function (token) {
|
|
135
|
+
return /*#__PURE__*/_jsx(Select.Option, {
|
|
136
|
+
value: token.value,
|
|
137
|
+
content: token.title
|
|
138
|
+
}, token.value);
|
|
139
|
+
})
|
|
140
|
+
}), /*#__PURE__*/_jsx(TextInput, {
|
|
141
|
+
value: values.name,
|
|
142
|
+
label: nameLabel,
|
|
143
|
+
hasClear: true,
|
|
144
|
+
error: errors === null || errors === void 0 ? void 0 : errors.name,
|
|
145
|
+
onKeyDown: handleInputKeyDown,
|
|
146
|
+
onUpdate: function onUpdate(v) {
|
|
147
|
+
return handleUpdate('name', v);
|
|
148
|
+
}
|
|
149
|
+
}), /*#__PURE__*/_jsxs(Flex, {
|
|
150
|
+
gap: 2,
|
|
151
|
+
children: [/*#__PURE__*/_jsxs(Button, {
|
|
152
|
+
view: "flat",
|
|
153
|
+
onClick: handleAccept,
|
|
154
|
+
children: [/*#__PURE__*/_jsx(Icon, {
|
|
155
|
+
data: Check
|
|
156
|
+
}), i18n('action_save')]
|
|
157
|
+
}), /*#__PURE__*/_jsxs(Button, {
|
|
158
|
+
view: "flat",
|
|
159
|
+
onClick: onCancel,
|
|
160
|
+
children: [/*#__PURE__*/_jsx(Icon, {
|
|
161
|
+
data: Xmark
|
|
162
|
+
}), i18n('action_cancel')]
|
|
163
|
+
})]
|
|
164
|
+
})]
|
|
165
|
+
});
|
|
166
|
+
};
|
|
167
|
+
// #sourceMappingURL=EditLinkItem.js.map
|