@gisce/react-ooui 1.5.2-alpha.1 → 1.5.2-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ConnectionProvider.d.ts +7 -0
- package/dist/ConnectionProvider.d.ts.map +1 -0
- package/dist/actionbar/ActionButton.d.ts +13 -0
- package/dist/actionbar/ActionButton.d.ts.map +1 -0
- package/dist/actionbar/AttachmentsButton.d.ts +12 -0
- package/dist/actionbar/AttachmentsButton.d.ts.map +1 -0
- package/dist/actionbar/AttachmentsButtonWrapper.d.ts +19 -0
- package/dist/actionbar/AttachmentsButtonWrapper.d.ts.map +1 -0
- package/dist/actionbar/ButtonWithBadge.d.ts +8 -0
- package/dist/actionbar/ButtonWithBadge.d.ts.map +1 -0
- package/dist/actionbar/ChangeViewButton.d.ts +13 -0
- package/dist/actionbar/ChangeViewButton.d.ts.map +1 -0
- package/dist/actionbar/DashboardActionBar.d.ts +4 -0
- package/dist/actionbar/DashboardActionBar.d.ts.map +1 -0
- package/dist/actionbar/DropdownButton.d.ts +12 -0
- package/dist/actionbar/DropdownButton.d.ts.map +1 -0
- package/dist/actionbar/FormActionBar.d.ts +6 -0
- package/dist/actionbar/FormActionBar.d.ts.map +1 -0
- package/dist/actionbar/GraphActionBar.d.ts +6 -0
- package/dist/actionbar/GraphActionBar.d.ts.map +1 -0
- package/dist/actionbar/NewButton.d.ts +7 -0
- package/dist/actionbar/NewButton.d.ts.map +1 -0
- package/dist/actionbar/SearchBar.d.ts +9 -0
- package/dist/actionbar/SearchBar.d.ts.map +1 -0
- package/dist/actionbar/TreeActionBar.d.ts +9 -0
- package/dist/actionbar/TreeActionBar.d.ts.map +1 -0
- package/dist/common/ButtonWithTooltip.d.ts +8 -0
- package/dist/common/ButtonWithTooltip.d.ts.map +1 -0
- package/dist/common/DatePicker.d.ts +20 -0
- package/dist/common/DatePicker.d.ts.map +1 -0
- package/dist/common/Field.d.ts +14 -0
- package/dist/common/Field.d.ts.map +1 -0
- package/dist/common/SelectAllRecordsRow.d.ts +10 -0
- package/dist/common/SelectAllRecordsRow.d.ts.map +1 -0
- package/dist/context/ActionViewContext.d.ts +65 -0
- package/dist/context/ActionViewContext.d.ts.map +1 -0
- package/dist/context/ConfigContext.d.ts +7 -0
- package/dist/context/ConfigContext.d.ts.map +1 -0
- package/dist/context/ContentRootContext.d.ts +19 -0
- package/dist/context/ContentRootContext.d.ts.map +1 -0
- package/dist/context/DashboardActionContext.d.ts +19 -0
- package/dist/context/DashboardActionContext.d.ts.map +1 -0
- package/dist/context/FormContext.d.ts +35 -0
- package/dist/context/FormContext.d.ts.map +1 -0
- package/dist/context/FormModalContext.d.ts +11 -0
- package/dist/context/FormModalContext.d.ts.map +1 -0
- package/dist/context/LocaleContext.d.ts +14 -0
- package/dist/context/LocaleContext.d.ts.map +1 -0
- package/dist/context/One2manyContext.d.ts +17 -0
- package/dist/context/One2manyContext.d.ts.map +1 -0
- package/dist/context/TabManagerContext.d.ts +50 -0
- package/dist/context/TabManagerContext.d.ts.map +1 -0
- package/dist/helpers/containerHelper.d.ts +22 -0
- package/dist/helpers/containerHelper.d.ts.map +1 -0
- package/dist/helpers/dynamicColumnsHelper.d.ts +8 -0
- package/dist/helpers/dynamicColumnsHelper.d.ts.map +1 -0
- package/dist/helpers/errorHelper.d.ts +6 -0
- package/dist/helpers/errorHelper.d.ts.map +1 -0
- package/dist/helpers/filesHelper.d.ts +8 -0
- package/dist/helpers/filesHelper.d.ts.map +1 -0
- package/dist/helpers/formHelper.d.ts +36 -0
- package/dist/helpers/formHelper.d.ts.map +1 -0
- package/dist/helpers/iconMapper.d.ts +13 -0
- package/dist/helpers/iconMapper.d.ts.map +1 -0
- package/dist/helpers/logInfoHelper.d.ts +3 -0
- package/dist/helpers/logInfoHelper.d.ts.map +1 -0
- package/dist/helpers/one2manyHelper.d.ts +37 -0
- package/dist/helpers/one2manyHelper.d.ts.map +1 -0
- package/dist/helpers/searchHelper.d.ts +6 -0
- package/dist/helpers/searchHelper.d.ts.map +1 -0
- package/dist/helpers/timeHelper.d.ts +4 -0
- package/dist/helpers/timeHelper.d.ts.map +1 -0
- package/dist/helpers/treeHelper.d.ts +23 -0
- package/dist/helpers/treeHelper.d.ts.map +1 -0
- package/dist/helpers/viewHelper.d.ts +10 -0
- package/dist/helpers/viewHelper.d.ts.map +1 -0
- package/dist/hooks/useExport.d.ts +44 -0
- package/dist/hooks/useExport.d.ts.map +1 -0
- package/dist/hooks/useSearch.d.ts +56 -0
- package/dist/hooks/useSearch.d.ts.map +1 -0
- package/dist/hooks/useWindowDimensions.d.ts +7 -0
- package/dist/hooks/useWindowDimensions.d.ts.map +1 -0
- package/dist/index.d.ts +57 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/locales/ca_ES.d.ts +93 -0
- package/dist/locales/ca_ES.d.ts.map +1 -0
- package/dist/locales/en_US.d.ts +93 -0
- package/dist/locales/en_US.d.ts.map +1 -0
- package/dist/locales/es_ES.d.ts +93 -0
- package/dist/locales/es_ES.d.ts.map +1 -0
- package/dist/react-ooui.es.js +11763 -0
- package/dist/react-ooui.es.js.map +1 -0
- package/dist/react-ooui.umd.js +42 -0
- package/dist/react-ooui.umd.js.map +1 -0
- package/dist/style.css +1 -0
- package/dist/types/index.d.ts +256 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/ui/ActionErrorDialog.d.ts +3 -0
- package/dist/ui/ActionErrorDialog.d.ts.map +1 -0
- package/dist/ui/ConfirmDialog.d.ts +7 -0
- package/dist/ui/ConfirmDialog.d.ts.map +1 -0
- package/dist/ui/ErrorAlert.d.ts +6 -0
- package/dist/ui/ErrorAlert.d.ts.map +1 -0
- package/dist/ui/FavouriteButton.d.ts +26 -0
- package/dist/ui/FavouriteButton.d.ts.map +1 -0
- package/dist/ui/FormErrorsDialog.d.ts +3 -0
- package/dist/ui/FormErrorsDialog.d.ts.map +1 -0
- package/dist/ui/GenericErrorDialog.d.ts +3 -0
- package/dist/ui/GenericErrorDialog.d.ts.map +1 -0
- package/dist/ui/GoToResourceModal.d.ts +10 -0
- package/dist/ui/GoToResourceModal.d.ts.map +1 -0
- package/dist/ui/InfoDialog.d.ts +3 -0
- package/dist/ui/InfoDialog.d.ts.map +1 -0
- package/dist/ui/RefreshItemDialog.d.ts +7 -0
- package/dist/ui/RefreshItemDialog.d.ts.map +1 -0
- package/dist/ui/RemoveItemDialog.d.ts +6 -0
- package/dist/ui/RemoveItemDialog.d.ts.map +1 -0
- package/dist/ui/TitleHeader.d.ts +8 -0
- package/dist/ui/TitleHeader.d.ts.map +1 -0
- package/dist/ui/UnlinkItemDialog.d.ts +6 -0
- package/dist/ui/UnlinkItemDialog.d.ts.map +1 -0
- package/dist/ui/UnsavedChangesDialog.d.ts +7 -0
- package/dist/ui/UnsavedChangesDialog.d.ts.map +1 -0
- package/dist/ui/WarningDialog.d.ts +3 -0
- package/dist/ui/WarningDialog.d.ts.map +1 -0
- package/dist/views/ActionView.d.ts +22 -0
- package/dist/views/ActionView.d.ts.map +1 -0
- package/dist/views/CurrentTabContent.d.ts +4 -0
- package/dist/views/CurrentTabContent.d.ts.map +1 -0
- package/dist/views/RootView.d.ts +14 -0
- package/dist/views/RootView.d.ts.map +1 -0
- package/dist/views/TabContent.d.ts +8 -0
- package/dist/views/TabContent.d.ts.map +1 -0
- package/dist/views/TabSelector.d.ts +4 -0
- package/dist/views/TabSelector.d.ts.map +1 -0
- package/dist/views/Welcome.d.ts +4 -0
- package/dist/views/Welcome.d.ts.map +1 -0
- package/dist/views/actionViews/DashboardActionView.d.ts +7 -0
- package/dist/views/actionViews/DashboardActionView.d.ts.map +1 -0
- package/dist/views/actionViews/FormActionView.d.ts +18 -0
- package/dist/views/actionViews/FormActionView.d.ts.map +1 -0
- package/dist/views/actionViews/GraphActionView.d.ts +13 -0
- package/dist/views/actionViews/GraphActionView.d.ts.map +1 -0
- package/dist/views/actionViews/TreeActionView.d.ts +20 -0
- package/dist/views/actionViews/TreeActionView.d.ts.map +1 -0
- package/dist/views/tabs/Tab.d.ts +11 -0
- package/dist/views/tabs/Tab.d.ts.map +1 -0
- package/dist/widgets/WidgetFactory.d.ts +4 -0
- package/dist/widgets/WidgetFactory.d.ts.map +1 -0
- package/dist/widgets/base/Binary.d.ts +14 -0
- package/dist/widgets/base/Binary.d.ts.map +1 -0
- package/dist/widgets/base/Boolean.d.ts +4 -0
- package/dist/widgets/base/Boolean.d.ts.map +1 -0
- package/dist/widgets/base/Button.d.ts +8 -0
- package/dist/widgets/base/Button.d.ts.map +1 -0
- package/dist/widgets/base/Char.d.ts +8 -0
- package/dist/widgets/base/Char.d.ts.map +1 -0
- package/dist/widgets/base/Date.d.ts +5 -0
- package/dist/widgets/base/Date.d.ts.map +1 -0
- package/dist/widgets/base/DateTime.d.ts +5 -0
- package/dist/widgets/base/DateTime.d.ts.map +1 -0
- package/dist/widgets/base/Email.d.ts +4 -0
- package/dist/widgets/base/Email.d.ts.map +1 -0
- package/dist/widgets/base/Float.d.ts +4 -0
- package/dist/widgets/base/Float.d.ts.map +1 -0
- package/dist/widgets/base/FloatTime.d.ts +12 -0
- package/dist/widgets/base/FloatTime.d.ts.map +1 -0
- package/dist/widgets/base/Image.d.ts +14 -0
- package/dist/widgets/base/Image.d.ts.map +1 -0
- package/dist/widgets/base/Integer.d.ts +8 -0
- package/dist/widgets/base/Integer.d.ts.map +1 -0
- package/dist/widgets/base/Label.d.ts +9 -0
- package/dist/widgets/base/Label.d.ts.map +1 -0
- package/dist/widgets/base/LinkInput.d.ts +12 -0
- package/dist/widgets/base/LinkInput.d.ts.map +1 -0
- package/dist/widgets/base/MultiSelection.d.ts +10 -0
- package/dist/widgets/base/MultiSelection.d.ts.map +1 -0
- package/dist/widgets/base/ProgressBar.d.ts +7 -0
- package/dist/widgets/base/ProgressBar.d.ts.map +1 -0
- package/dist/widgets/base/Reference.d.ts +16 -0
- package/dist/widgets/base/Reference.d.ts.map +1 -0
- package/dist/widgets/base/ReferenceTree.d.ts +8 -0
- package/dist/widgets/base/ReferenceTree.d.ts.map +1 -0
- package/dist/widgets/base/Selection.d.ts +10 -0
- package/dist/widgets/base/Selection.d.ts.map +1 -0
- package/dist/widgets/base/Separator.d.ts +8 -0
- package/dist/widgets/base/Separator.d.ts.map +1 -0
- package/dist/widgets/base/Text.d.ts +8 -0
- package/dist/widgets/base/Text.d.ts.map +1 -0
- package/dist/widgets/base/Time.d.ts +12 -0
- package/dist/widgets/base/Time.d.ts.map +1 -0
- package/dist/widgets/base/Url.d.ts +4 -0
- package/dist/widgets/base/Url.d.ts.map +1 -0
- package/dist/widgets/base/many2one/Many2one.d.ts +16 -0
- package/dist/widgets/base/many2one/Many2one.d.ts.map +1 -0
- package/dist/widgets/base/many2one/Many2oneSuffix.d.ts +9 -0
- package/dist/widgets/base/many2one/Many2oneSuffix.d.ts.map +1 -0
- package/dist/widgets/base/many2one/Many2oneSuffixModal.d.ts +10 -0
- package/dist/widgets/base/many2one/Many2oneSuffixModal.d.ts.map +1 -0
- package/dist/widgets/base/many2one/Many2oneTree.d.ts +6 -0
- package/dist/widgets/base/many2one/Many2oneTree.d.ts.map +1 -0
- package/dist/widgets/base/one2many/One2many.d.ts +8 -0
- package/dist/widgets/base/one2many/One2many.d.ts.map +1 -0
- package/dist/widgets/base/one2many/One2manyInput.d.ts +23 -0
- package/dist/widgets/base/one2many/One2manyInput.d.ts.map +1 -0
- package/dist/widgets/base/one2many/One2manyTopBar.d.ts +23 -0
- package/dist/widgets/base/one2many/One2manyTopBar.d.ts.map +1 -0
- package/dist/widgets/containers/Container.d.ts +9 -0
- package/dist/widgets/containers/Container.d.ts.map +1 -0
- package/dist/widgets/containers/Group.d.ts +10 -0
- package/dist/widgets/containers/Group.d.ts.map +1 -0
- package/dist/widgets/containers/Notebook.d.ts +9 -0
- package/dist/widgets/containers/Notebook.d.ts.map +1 -0
- package/dist/widgets/custom/Avatar.d.ts +10 -0
- package/dist/widgets/custom/Avatar.d.ts.map +1 -0
- package/dist/widgets/custom/ButtonGroup.d.ts +8 -0
- package/dist/widgets/custom/ButtonGroup.d.ts.map +1 -0
- package/dist/widgets/custom/CodeEditor.d.ts +9 -0
- package/dist/widgets/custom/CodeEditor.d.ts.map +1 -0
- package/dist/widgets/custom/Comments.d.ts +35 -0
- package/dist/widgets/custom/Comments.d.ts.map +1 -0
- package/dist/widgets/custom/FiberGrid.d.ts +10 -0
- package/dist/widgets/custom/FiberGrid.d.ts.map +1 -0
- package/dist/widgets/custom/Indicator.d.ts +10 -0
- package/dist/widgets/custom/Indicator.d.ts.map +1 -0
- package/dist/widgets/custom/Markdown.d.ts +5 -0
- package/dist/widgets/custom/Markdown.d.ts.map +1 -0
- package/dist/widgets/custom/MultiCheckbox.d.ts +14 -0
- package/dist/widgets/custom/MultiCheckbox.d.ts.map +1 -0
- package/dist/widgets/custom/Radio.d.ts +10 -0
- package/dist/widgets/custom/Radio.d.ts.map +1 -0
- package/dist/widgets/custom/Steps.d.ts +13 -0
- package/dist/widgets/custom/Steps.d.ts.map +1 -0
- package/dist/widgets/custom/Switch.d.ts +4 -0
- package/dist/widgets/custom/Switch.d.ts.map +1 -0
- package/dist/widgets/custom/Tag.d.ts +7 -0
- package/dist/widgets/custom/Tag.d.ts.map +1 -0
- package/dist/widgets/custom/Tags.d.ts +15 -0
- package/dist/widgets/custom/Tags.d.ts.map +1 -0
- package/dist/widgets/custom/Timeline.d.ts +16 -0
- package/dist/widgets/custom/Timeline.d.ts.map +1 -0
- package/dist/widgets/modals/ExportModal.d.ts +15 -0
- package/dist/widgets/modals/ExportModal.d.ts.map +1 -0
- package/dist/widgets/modals/FormModal.d.ts +12 -0
- package/dist/widgets/modals/FormModal.d.ts.map +1 -0
- package/dist/widgets/modals/SearchModal.d.ts +13 -0
- package/dist/widgets/modals/SearchModal.d.ts.map +1 -0
- package/dist/widgets/modals/TranslationModal.d.ts +12 -0
- package/dist/widgets/modals/TranslationModal.d.ts.map +1 -0
- package/dist/widgets/views/Dashboard/Dashboard.d.ts +5 -0
- package/dist/widgets/views/Dashboard/Dashboard.d.ts.map +1 -0
- package/dist/widgets/views/Dashboard/DashboardForm.d.ts +4 -0
- package/dist/widgets/views/Dashboard/DashboardForm.d.ts.map +1 -0
- package/dist/widgets/views/Dashboard/DashboardTree.d.ts +19 -0
- package/dist/widgets/views/Dashboard/DashboardTree.d.ts.map +1 -0
- package/dist/widgets/views/Dashboard/dashboardHelper.d.ts +6 -0
- package/dist/widgets/views/Dashboard/dashboardHelper.d.ts.map +1 -0
- package/dist/widgets/views/DashboardGrid/DashboardGrid.d.ts +4 -0
- package/dist/widgets/views/DashboardGrid/DashboardGrid.d.ts.map +1 -0
- package/dist/widgets/views/DashboardGrid/DashboardGrid.types.d.ts +6 -0
- package/dist/widgets/views/DashboardGrid/DashboardGrid.types.d.ts.map +1 -0
- package/dist/widgets/views/DashboardGrid/DashboardGridItem.d.ts +4 -0
- package/dist/widgets/views/DashboardGrid/DashboardGridItem.d.ts.map +1 -0
- package/dist/widgets/views/DashboardGrid/DashboardGridItem.types.d.ts +11 -0
- package/dist/widgets/views/DashboardGrid/DashboardGridItem.types.d.ts.map +1 -0
- package/dist/widgets/views/DashboardGrid/index.d.ts +5 -0
- package/dist/widgets/views/DashboardGrid/index.d.ts.map +1 -0
- package/dist/widgets/views/Form.d.ts +29 -0
- package/dist/widgets/views/Form.d.ts.map +1 -0
- package/dist/widgets/views/Graph/Graph.d.ts +11 -0
- package/dist/widgets/views/Graph/Graph.d.ts.map +1 -0
- package/dist/widgets/views/Graph/GraphChart.d.ts +11 -0
- package/dist/widgets/views/Graph/GraphChart.d.ts.map +1 -0
- package/dist/widgets/views/Graph/GraphDefaults.d.ts +83 -0
- package/dist/widgets/views/Graph/GraphDefaults.d.ts.map +1 -0
- package/dist/widgets/views/Graph/GraphIndicator.d.ts +17 -0
- package/dist/widgets/views/Graph/GraphIndicator.d.ts.map +1 -0
- package/dist/widgets/views/Graph/useGraphData.d.ts +20 -0
- package/dist/widgets/views/Graph/useGraphData.d.ts.map +1 -0
- package/dist/widgets/views/SearchTree.d.ts +24 -0
- package/dist/widgets/views/SearchTree.d.ts.map +1 -0
- package/dist/widgets/views/Tree.d.ts +32 -0
- package/dist/widgets/views/Tree.d.ts.map +1 -0
- package/dist/widgets/views/searchFilter/DateRangePicker.d.ts +4 -0
- package/dist/widgets/views/searchFilter/DateRangePicker.d.ts.map +1 -0
- package/dist/widgets/views/searchFilter/DateTimeRangePicker.d.ts +4 -0
- package/dist/widgets/views/searchFilter/DateTimeRangePicker.d.ts.map +1 -0
- package/dist/widgets/views/searchFilter/PairFields.d.ts +4 -0
- package/dist/widgets/views/searchFilter/PairFields.d.ts.map +1 -0
- package/dist/widgets/views/searchFilter/SearchBottomBar.d.ts +10 -0
- package/dist/widgets/views/searchFilter/SearchBottomBar.d.ts.map +1 -0
- package/dist/widgets/views/searchFilter/SearchField.d.ts +8 -0
- package/dist/widgets/views/searchFilter/SearchField.d.ts.map +1 -0
- package/dist/widgets/views/searchFilter/SearchFilter.d.ts +20 -0
- package/dist/widgets/views/searchFilter/SearchFilter.d.ts.map +1 -0
- package/dist/widgets/views/searchFilter/SearchParams.d.ts +7 -0
- package/dist/widgets/views/searchFilter/SearchParams.d.ts.map +1 -0
- package/package.json +43 -74
- package/src/actionbar/FormActionBar.tsx +1 -1
- package/src/actionbar/TreeActionBar.tsx +1 -1
- package/src/common/DatePicker.tsx +2 -2
- package/src/common/SelectAllRecordsRow.tsx +5 -4
- package/src/context/ContentRootContext.tsx +54 -61
- package/src/context/TabManagerContext.tsx +4 -3
- package/src/helpers/dynamicColumnsHelper.ts +1 -1
- package/src/helpers/filesHelper.ts +7 -7
- package/src/helpers/formHelper.ts +24 -23
- package/src/helpers/one2manyHelper.ts +6 -6
- package/src/helpers/searchHelper.ts +5 -8
- package/src/helpers/treeHelper.ts +7 -7
- package/src/helpers/viewHelper.ts +2 -2
- package/src/hooks/useExport.ts +3 -2
- package/src/hooks/useSearch.ts +8 -8
- package/src/index.ts +0 -4
- package/src/stories/Binary.stories.tsx +3 -0
- package/src/stories/Boolean.stories.tsx +3 -0
- package/src/stories/Button.stories.tsx +14 -8
- package/src/stories/Char.stories.tsx +3 -0
- package/src/stories/FiberGrid.stories.tsx +3 -0
- package/src/stories/Float.stories.tsx +3 -0
- package/src/stories/FloatTime.stories.tsx +3 -0
- package/src/stories/Image.stories.tsx +3 -0
- package/src/stories/Integer.stories.tsx +3 -0
- package/src/stories/Label.stories.tsx +3 -0
- package/src/stories/Many2one.stories.tsx +3 -0
- package/src/stories/One2many.stories.tsx +11 -4
- package/src/stories/ProgressBar.stories.tsx +3 -0
- package/src/stories/Reference.stories.tsx +3 -0
- package/src/stories/Selection.stories.tsx +3 -0
- package/src/stories/Separator.stories.tsx +7 -3
- package/src/stories/Text.stories.tsx +3 -0
- package/src/stories/containers/Group.stories.tsx +5 -0
- package/src/stories/containers/NewLine.stories.tsx +4 -0
- package/src/stories/containers/Notebook.stories.tsx +5 -0
- package/src/stories/custom/Avatar.stories.tsx +1 -0
- package/src/stories/custom/ButtonGroup.stories.tsx +23 -36
- package/src/stories/custom/CodeEditor.stories.tsx +4 -1
- package/src/stories/custom/Indicator.stories.tsx +11 -3
- package/src/stories/custom/Markdown.stories.tsx +6 -2
- package/src/stories/custom/MultiCheckbox.stories.tsx +15 -20
- package/src/stories/custom/Radio.stories.tsx +16 -13
- package/src/stories/custom/Steps.stories.tsx +5 -7
- package/src/stories/custom/Switch.stories.tsx +3 -0
- package/src/stories/custom/Tag.stories.tsx +11 -17
- package/src/stories/custom/Tags.stories.tsx +16 -20
- package/src/stories/forms/PreferencesForm.stories.tsx +4 -0
- package/src/stories/ui/ActionBar.stories.tsx +3 -0
- package/src/stories/ui/FavouriteButton.stories.tsx +3 -0
- package/src/stories/ui/GoToResourceModal.stories.tsx +3 -0
- package/src/stories/views/SearchTree.stories.tsx +89 -43
- package/src/stories/views/Tab.stories.tsx +3 -0
- package/src/stories/views/TabsAndContent.stories.tsx +3 -0
- package/src/stories/views/Tree.stories.jsx +4 -0
- package/src/stories/views/searchFilter/DateRangePicker.stories.tsx +3 -0
- package/src/stories/views/searchFilter/DateTimeRangePicker.stories.tsx +3 -0
- package/src/stories/views/searchFilter/PairFields.stories.tsx +3 -0
- package/src/stories/views/searchFilter/SearchFilter.stories.tsx +4 -0
- package/src/stories/views/searchFilter/examples/PartnersSearchFilter.stories.tsx +4 -0
- package/src/tailwind.css +8 -0
- package/src/tailwind.generated.css +168533 -0
- package/src/types/index.ts +43 -94
- package/src/ui/FavouriteButton.tsx +3 -2
- package/src/views/ActionView.tsx +11 -12
- package/src/views/RootView.tsx +6 -5
- package/src/widgets/base/Binary.tsx +2 -2
- package/src/widgets/base/Boolean.tsx +2 -1
- package/src/widgets/base/Float.tsx +1 -1
- package/src/widgets/base/Integer.tsx +2 -2
- package/src/widgets/base/Label.tsx +9 -9
- package/src/widgets/base/LinkInput.tsx +1 -6
- package/src/widgets/base/MultiSelection.tsx +2 -1
- package/src/widgets/base/Selection.tsx +5 -11
- package/src/widgets/base/Time.tsx +12 -13
- package/src/widgets/base/many2one/Many2one.tsx +8 -7
- package/src/widgets/base/many2one/Many2oneSuffix.tsx +12 -23
- package/src/widgets/base/one2many/One2manyInput.tsx +15 -14
- package/src/widgets/containers/Notebook.tsx +2 -9
- package/src/widgets/custom/ButtonGroup.tsx +10 -13
- package/src/widgets/custom/CodeEditor.tsx +3 -7
- package/src/widgets/custom/Comments.tsx +70 -76
- package/src/widgets/custom/Indicator.tsx +2 -1
- package/src/widgets/custom/MultiCheckbox.tsx +2 -2
- package/src/widgets/custom/Tag.tsx +16 -20
- package/src/widgets/custom/Tags.tsx +3 -3
- package/src/widgets/custom/Timeline.tsx +6 -6
- package/src/widgets/views/Dashboard/DashboardTree.tsx +2 -2
- package/src/widgets/views/DashboardGrid/DashboardGrid.types.ts +1 -1
- package/src/widgets/views/Form.tsx +11 -10
- package/src/widgets/views/Graph/GraphIndicator.tsx +7 -7
- package/src/widgets/views/SearchTree.tsx +2 -2
- package/src/widgets/views/Tree.tsx +16 -15
- package/src/widgets/views/searchFilter/DateTimeRangePicker.tsx +3 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DateTimeRangePicker.d.ts","sourceRoot":"","sources":["DateTimeRangePicker.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAKtC,eAAO,MAAM,mBAAmB,UAAW,WAAW,sBAoDrD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PairFields.d.ts","sourceRoot":"","sources":["PairFields.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAMtC,wBAAgB,UAAU,CAAC,KAAK,EAAE,WAAW,GAAG,KAAK,CAAC,YAAY,CA2CjE"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
declare type Props = {
|
|
3
|
+
advancedFilter: boolean;
|
|
4
|
+
isSearching: boolean;
|
|
5
|
+
onAdvancedFilterToggle: () => void;
|
|
6
|
+
onClear: () => void;
|
|
7
|
+
};
|
|
8
|
+
export declare function SearchBottomBar(props: Props): React.ReactElement;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=SearchBottomBar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchBottomBar.d.ts","sourceRoot":"","sources":["SearchBottomBar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAY1C,aAAK,KAAK,GAAG;IACX,cAAc,EAAE,OAAO,CAAC;IACxB,WAAW,EAAE,OAAO,CAAC;IACrB,sBAAsB,EAAE,MAAM,IAAI,CAAC;IACnC,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC;AAEF,wBAAgB,eAAe,CAAC,KAAK,EAAE,KAAK,GAAG,KAAK,CAAC,YAAY,CAsChE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchField.d.ts","sourceRoot":"","sources":["SearchField.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAU1C,OAAO,EAAE,KAAK,EAAgD,MAAM,aAAa,CAAC;AAGlF,aAAK,KAAK,GAAG;IACX,KAAK,EAAE,KAAK,CAAC;CACd,CAAC;AAEF,wBAAgB,WAAW,CAAC,KAAK,EAAE,KAAK,qBAyCvC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { SearchFields } from '../../../types';
|
|
3
|
+
declare type Props = {
|
|
4
|
+
fields: any;
|
|
5
|
+
searchFields: SearchFields;
|
|
6
|
+
onClear: () => void;
|
|
7
|
+
onSubmit: (values: any) => void;
|
|
8
|
+
isSearching: boolean;
|
|
9
|
+
limit: number;
|
|
10
|
+
offset: number;
|
|
11
|
+
onLimitChange?: (limit: number) => void;
|
|
12
|
+
searchVisible?: boolean;
|
|
13
|
+
setSearchFilterHeight?: (height: number) => void;
|
|
14
|
+
searchError?: string;
|
|
15
|
+
searchValues?: any;
|
|
16
|
+
showLimitOptions?: boolean;
|
|
17
|
+
};
|
|
18
|
+
declare function SearchFilter(props: Props): React.JSX.Element;
|
|
19
|
+
export default SearchFilter;
|
|
20
|
+
//# sourceMappingURL=SearchFilter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchFilter.d.ts","sourceRoot":"","sources":["SearchFilter.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAY3D,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAOvC,aAAK,KAAK,GAAG;IACX,MAAM,EAAE,GAAG,CAAC;IACZ,YAAY,EAAE,YAAY,CAAC;IAC3B,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,CAAC,MAAM,EAAE,GAAG,KAAK,IAAI,CAAC;IAChC,WAAW,EAAE,OAAO,CAAC;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,qBAAqB,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IACjD,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,GAAG,CAAC;IACnB,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B,CAAC;AAEF,iBAAS,YAAY,CAAC,KAAK,EAAE,KAAK,qBAyHjC;AAED,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchParams.d.ts","sourceRoot":"","sources":["SearchParams.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAQ1C,aAAK,iBAAiB,GAAG;IACvB,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACzC,CAAA;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,iBAAiB,GAAG,KAAK,CAAC,YAAY,CAmBzE"}
|
package/package.json
CHANGED
|
@@ -1,38 +1,39 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gisce/react-ooui",
|
|
3
|
-
"version": "1.5.2-
|
|
4
|
-
"engines": {
|
|
5
|
-
"node": "20.5.0"
|
|
6
|
-
},
|
|
7
|
-
"publishConfig": {
|
|
8
|
-
"access": "public"
|
|
9
|
-
},
|
|
3
|
+
"version": "1.5.2-rc.0",
|
|
10
4
|
"files": [
|
|
11
5
|
"dist",
|
|
12
6
|
"src",
|
|
13
7
|
"README.md"
|
|
14
8
|
],
|
|
9
|
+
"main": "./dist/react-ooui.umd.js",
|
|
15
10
|
"module": "./dist/react-ooui.es.js",
|
|
16
11
|
"types": "./dist/index.d.ts",
|
|
17
12
|
"exports": {
|
|
18
13
|
".": {
|
|
19
|
-
"import": "./dist/react-ooui.es.js"
|
|
14
|
+
"import": "./dist/react-ooui.es.js",
|
|
15
|
+
"require": "./dist/react-ooui.umd.js"
|
|
20
16
|
}
|
|
21
17
|
},
|
|
18
|
+
"publishConfig": {
|
|
19
|
+
"access": "public"
|
|
20
|
+
},
|
|
22
21
|
"scripts": {
|
|
23
|
-
"
|
|
24
|
-
"
|
|
25
|
-
"
|
|
26
|
-
"
|
|
27
|
-
"
|
|
28
|
-
"
|
|
29
|
-
"
|
|
30
|
-
"
|
|
22
|
+
"preminor": "npm version preminor --preid rc",
|
|
23
|
+
"prerelease": "npm version prerelease --preid rc",
|
|
24
|
+
"prepatch": "npm version prepatch --preid rc",
|
|
25
|
+
"premajor": "npm version premajor --preid rc",
|
|
26
|
+
"start": "while :; do tsc && vite build --watch --force; done",
|
|
27
|
+
"build:tailwind": "postcss src/tailwind.css -o src/tailwind.generated.css",
|
|
28
|
+
"build": "tsc && vite build",
|
|
29
|
+
"test": "jest",
|
|
30
|
+
"storybook": "start-storybook -p 6006",
|
|
31
|
+
"build-storybook": "build-storybook"
|
|
31
32
|
},
|
|
32
33
|
"dependencies": {
|
|
33
34
|
"@ant-design/plots": "^1.0.9",
|
|
34
35
|
"@gisce/fiber-diagram": "^1.1.0-rc.3",
|
|
35
|
-
"@gisce/ooui": "^0.22.
|
|
36
|
+
"@gisce/ooui": "^0.22.4-rc.0",
|
|
36
37
|
"@gisce/react-formiga-components": "^1.0.9-rc.21",
|
|
37
38
|
"@gisce/react-formiga-table": "^0.8.6",
|
|
38
39
|
"@monaco-editor/react": "^4.4.5",
|
|
@@ -48,83 +49,51 @@
|
|
|
48
49
|
"react-hotkeys-hook": "^3.4.4",
|
|
49
50
|
"react-markdown": "^8.0.7",
|
|
50
51
|
"react-measure": "^2.5.2",
|
|
51
|
-
"styled-components": "5.3.5",
|
|
52
52
|
"use-deep-compare-effect": "^1.8.1",
|
|
53
53
|
"uuid": "^3.4.0",
|
|
54
54
|
"validator": "^13.6.0"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
|
57
|
-
"@
|
|
58
|
-
"@
|
|
59
|
-
"@
|
|
57
|
+
"@babel/core": "^7.19.1",
|
|
58
|
+
"@storybook/addon-actions": "^6.5.12",
|
|
59
|
+
"@storybook/addon-essentials": "^6.5.12",
|
|
60
|
+
"@storybook/addon-interactions": "^6.5.12",
|
|
61
|
+
"@storybook/addon-knobs": "^6.4.0",
|
|
62
|
+
"@storybook/addon-links": "^6.5.12",
|
|
63
|
+
"@storybook/builder-vite": "^0.2.2",
|
|
64
|
+
"@storybook/react": "^6.5.12",
|
|
65
|
+
"@storybook/testing-library": "^0.0.13",
|
|
66
|
+
"@tailwindcss/postcss7-compat": "^2.0.2",
|
|
67
|
+
"@types/jest": "^26.0.15",
|
|
60
68
|
"@types/lodash": "^4.14.170",
|
|
61
69
|
"@types/md5": "^2.3.2",
|
|
70
|
+
"@types/node": "^12.0.0",
|
|
62
71
|
"@types/react": "^17.0.1",
|
|
63
72
|
"@types/react-dom": "^17.0.1",
|
|
64
73
|
"@types/react-grid-layout": "^1.3.2",
|
|
65
74
|
"@types/react-measure": "^2.0.7",
|
|
66
75
|
"@types/react-responsive": "^8.0.2",
|
|
67
|
-
"@types/rollup-plugin-peer-deps-external": "^2.2.2",
|
|
68
76
|
"@types/scroll-into-view": "^1.16.0",
|
|
69
77
|
"@types/styled-components": "^5.1.7",
|
|
70
78
|
"@types/uuid": "^8.3.1",
|
|
71
79
|
"@types/validator": "^13.6.3",
|
|
72
|
-
"@
|
|
73
|
-
"
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"
|
|
77
|
-
"
|
|
78
|
-
"
|
|
79
|
-
"eslint-plugin-import": "2.28.0",
|
|
80
|
-
"eslint-plugin-n": "15.6.0",
|
|
81
|
-
"eslint-plugin-promise": "6.1.1",
|
|
82
|
-
"eslint-plugin-react": "7.33.1",
|
|
83
|
-
"eslint-plugin-react-hooks": "4.6.0",
|
|
84
|
-
"husky": "8.0.3",
|
|
85
|
-
"lint-staged": "13.2.3",
|
|
86
|
-
"only-allow": "1.1.1",
|
|
87
|
-
"prettier": "3.0.1",
|
|
80
|
+
"@vitejs/plugin-react": "^2.1.0",
|
|
81
|
+
"autoprefixer": "^9.8.6",
|
|
82
|
+
"babel-loader": "^8.2.5",
|
|
83
|
+
"jest": "^26.6.3",
|
|
84
|
+
"jest-enzyme": "^7.1.2",
|
|
85
|
+
"postcss": "^7.0.35",
|
|
86
|
+
"postcss-cli": "^7.1.0",
|
|
88
87
|
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
89
|
-
"
|
|
90
|
-
"
|
|
91
|
-
"
|
|
92
|
-
"vite
|
|
93
|
-
"vite-plugin-
|
|
94
|
-
"vite-tsconfig-paths": "3.5.0"
|
|
88
|
+
"tailwindcss": "npm:@tailwindcss/postcss7-compat@^2.0.2",
|
|
89
|
+
"ts-jest": "^26.4.4",
|
|
90
|
+
"typescript": "^4.0.3",
|
|
91
|
+
"vite": "^3.1.0",
|
|
92
|
+
"vite-plugin-dts": "^1.0.3"
|
|
95
93
|
},
|
|
96
94
|
"peerDependencies": {
|
|
97
95
|
"react": "^17.0.1",
|
|
98
96
|
"react-dom": "^17.0.1",
|
|
99
|
-
"styled-components": "5.
|
|
100
|
-
},
|
|
101
|
-
"lint-staged": {
|
|
102
|
-
"src/**/*.{js,jsx,ts,tsx}": "eslint --fix",
|
|
103
|
-
"src/**/*.{js,jsx,ts,tsx,json,css,md}": "prettier --write"
|
|
104
|
-
},
|
|
105
|
-
"release": {
|
|
106
|
-
"branches": [
|
|
107
|
-
"master",
|
|
108
|
-
{
|
|
109
|
-
"name": "develop",
|
|
110
|
-
"prerelease": "rc"
|
|
111
|
-
},
|
|
112
|
-
{
|
|
113
|
-
"name": "alpha",
|
|
114
|
-
"prerelease": true
|
|
115
|
-
}
|
|
116
|
-
],
|
|
117
|
-
"plugins": [
|
|
118
|
-
"@semantic-release/commit-analyzer",
|
|
119
|
-
"@semantic-release/release-notes-generator",
|
|
120
|
-
[
|
|
121
|
-
"@semantic-release/npm",
|
|
122
|
-
{
|
|
123
|
-
"npmPublish": true
|
|
124
|
-
}
|
|
125
|
-
],
|
|
126
|
-
"@semantic-release/github",
|
|
127
|
-
"@semantic-release/git"
|
|
128
|
-
]
|
|
97
|
+
"styled-components": "^5.2.1"
|
|
129
98
|
}
|
|
130
99
|
}
|
|
@@ -141,7 +141,7 @@ function FormActionBar({ toolbar }: { toolbar: any }) {
|
|
|
141
141
|
try {
|
|
142
142
|
setRemovingItem?.(true);
|
|
143
143
|
|
|
144
|
-
await ConnectionProvider.getHandler().
|
|
144
|
+
await ConnectionProvider.getHandler().delete({
|
|
145
145
|
model: currentModel!,
|
|
146
146
|
ids: [currentId!],
|
|
147
147
|
});
|
|
@@ -92,7 +92,7 @@ function TreeActionBar(props: Props) {
|
|
|
92
92
|
try {
|
|
93
93
|
setRemovingItem?.(true);
|
|
94
94
|
|
|
95
|
-
await ConnectionProvider.getHandler().
|
|
95
|
+
await ConnectionProvider.getHandler().delete({
|
|
96
96
|
model: currentModel!,
|
|
97
97
|
ids: selectedRowItems!.map((item) => item.id),
|
|
98
98
|
});
|
|
@@ -5,9 +5,9 @@ import Field from "@/common/Field";
|
|
|
5
5
|
import { WidgetProps } from "@/types";
|
|
6
6
|
import { Date as DateOoui } from "@gisce/ooui";
|
|
7
7
|
import dayjs from "dayjs";
|
|
8
|
+
const { useToken } = theme;
|
|
8
9
|
import weekday from "dayjs/plugin/weekday";
|
|
9
10
|
import localeData from "dayjs/plugin/localeData";
|
|
10
|
-
const { useToken } = theme;
|
|
11
11
|
dayjs.extend(weekday);
|
|
12
12
|
dayjs.extend(localeData);
|
|
13
13
|
|
|
@@ -47,7 +47,7 @@ interface DatePickerInputProps {
|
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
const DatePickerInput: React.FC<DatePickerInputProps> = (
|
|
50
|
-
props: DatePickerInputProps
|
|
50
|
+
props: DatePickerInputProps
|
|
51
51
|
) => {
|
|
52
52
|
const { value, onChange, ooui, showTime } = props;
|
|
53
53
|
const { id, readOnly, required } = ooui as DateOoui;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import styled from "styled-components";
|
|
2
|
-
import
|
|
2
|
+
import { useContext, useState } from "react";
|
|
3
|
+
import React from "react";
|
|
3
4
|
import { Spin } from "antd";
|
|
4
5
|
import { LocaleContext, LocaleContextType } from "@/context/LocaleContext";
|
|
5
6
|
import Link from "antd/es/typography/Link";
|
|
@@ -59,7 +60,7 @@ export const SelectAllRecordsRow = ({
|
|
|
59
60
|
<span>
|
|
60
61
|
{translations.recordsSelected.replace(
|
|
61
62
|
"{numberOfSelectedRows}",
|
|
62
|
-
numberOfVisibleSelectedRows.toString()
|
|
63
|
+
numberOfVisibleSelectedRows.toString()
|
|
63
64
|
) + " "}
|
|
64
65
|
|
|
65
66
|
{loading ? (
|
|
@@ -68,7 +69,7 @@ export const SelectAllRecordsRow = ({
|
|
|
68
69
|
<Link onClick={handleClick} style={{ fontWeight: 600 }}>
|
|
69
70
|
{translations.selectAllRecords.replace(
|
|
70
71
|
"{totalRecords}",
|
|
71
|
-
totalRecords.toString()
|
|
72
|
+
totalRecords.toString()
|
|
72
73
|
)}
|
|
73
74
|
</Link>
|
|
74
75
|
)}
|
|
@@ -79,7 +80,7 @@ export const SelectAllRecordsRow = ({
|
|
|
79
80
|
<span style={{ fontWeight: 600 }}>
|
|
80
81
|
{translations.allRecordsSelected.replace(
|
|
81
82
|
"{totalRecords}",
|
|
82
|
-
numberOfRealSelectedRows.toString()
|
|
83
|
+
numberOfRealSelectedRows.toString()
|
|
83
84
|
) + " "}
|
|
84
85
|
</span>
|
|
85
86
|
);
|
|
@@ -59,14 +59,14 @@ const callRefreshValues = async (fns: any[]) => {
|
|
|
59
59
|
|
|
60
60
|
const ContentRootProvider = (
|
|
61
61
|
props: ContentRootProviderProps,
|
|
62
|
-
ref: any
|
|
62
|
+
ref: any
|
|
63
63
|
): any => {
|
|
64
64
|
const { children, globalValues = {} } = props;
|
|
65
65
|
const reportInProgressInterval = useRef<any>();
|
|
66
66
|
const waitingForReport = useRef<boolean>();
|
|
67
67
|
const [reportGenerating, setReportGenerating] = useState<boolean>(false);
|
|
68
68
|
const tabManagerContext = useContext(
|
|
69
|
-
TabManagerContext
|
|
69
|
+
TabManagerContext
|
|
70
70
|
) as TabManagerContextType;
|
|
71
71
|
const { openAction } = tabManagerContext || {};
|
|
72
72
|
const onRefreshParentValues = useRef<any>([]);
|
|
@@ -82,7 +82,7 @@ const ContentRootProvider = (
|
|
|
82
82
|
const [actionModalOptions, setActionModalOptions] = useState<ActionModalOpts>(
|
|
83
83
|
{
|
|
84
84
|
context: {},
|
|
85
|
-
}
|
|
85
|
+
}
|
|
86
86
|
);
|
|
87
87
|
|
|
88
88
|
async function generateReport(options: GenerateReportOptions) {
|
|
@@ -103,7 +103,7 @@ const ContentRootProvider = (
|
|
|
103
103
|
|
|
104
104
|
const { ids } = datas || {};
|
|
105
105
|
|
|
106
|
-
|
|
106
|
+
let idsToExecute = ids || [];
|
|
107
107
|
|
|
108
108
|
const reportContextParsed =
|
|
109
109
|
typeof reportContext === "string"
|
|
@@ -182,12 +182,9 @@ const ContentRootProvider = (
|
|
|
182
182
|
context,
|
|
183
183
|
});
|
|
184
184
|
} else if (type === "ir.actions.act_window") {
|
|
185
|
-
return await runAction({
|
|
185
|
+
return await runAction({actionData, fields, values, context});
|
|
186
186
|
} else if (type === "ir.actions.act_url") {
|
|
187
|
-
window.open(
|
|
188
|
-
stringFormat(actionData.url, { ...values, context }),
|
|
189
|
-
"_blank",
|
|
190
|
-
);
|
|
187
|
+
window.open(stringFormat(actionData.url, {...values, context}), "_blank");
|
|
191
188
|
} else {
|
|
192
189
|
showErrorDialog(`${type} action not supported`);
|
|
193
190
|
return {};
|
|
@@ -278,7 +275,7 @@ const ContentRootProvider = (
|
|
|
278
275
|
context: mergedContext,
|
|
279
276
|
domain: parsedDomain,
|
|
280
277
|
model: actionData.res_model,
|
|
281
|
-
views,
|
|
278
|
+
views: views,
|
|
282
279
|
title: actionData.name,
|
|
283
280
|
initialView,
|
|
284
281
|
action_id: actionData.id,
|
|
@@ -349,54 +346,52 @@ const ContentRootProvider = (
|
|
|
349
346
|
});
|
|
350
347
|
}
|
|
351
348
|
|
|
352
|
-
return (
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
</>
|
|
399
|
-
);
|
|
349
|
+
return (<>
|
|
350
|
+
<ContentRootContext.Provider
|
|
351
|
+
value={{
|
|
352
|
+
processAction,
|
|
353
|
+
globalValues,
|
|
354
|
+
}}
|
|
355
|
+
>
|
|
356
|
+
<>
|
|
357
|
+
{children}
|
|
358
|
+
<Modal
|
|
359
|
+
title={t("generatingReport")}
|
|
360
|
+
open={reportGenerating}
|
|
361
|
+
footer={null}
|
|
362
|
+
closable={false}
|
|
363
|
+
centered
|
|
364
|
+
maskClosable={false}
|
|
365
|
+
>
|
|
366
|
+
<Spin />
|
|
367
|
+
</Modal>
|
|
368
|
+
<FormModal
|
|
369
|
+
buttonModal
|
|
370
|
+
parentContext={actionModalOptions.context}
|
|
371
|
+
model={actionModalOptions.model!}
|
|
372
|
+
formView={actionModalOptions.formView}
|
|
373
|
+
visible={actionModalVisible}
|
|
374
|
+
onSubmitSucceed={onFormModalSucceed}
|
|
375
|
+
onCancel={() => {
|
|
376
|
+
callRefreshValues(onRefreshParentValues.current);
|
|
377
|
+
onRefreshParentValues.current = [];
|
|
378
|
+
setActionModalVisible(false);
|
|
379
|
+
setActionModalOptions({
|
|
380
|
+
domain: undefined,
|
|
381
|
+
model: undefined,
|
|
382
|
+
context: {},
|
|
383
|
+
formView: undefined,
|
|
384
|
+
actionData: undefined,
|
|
385
|
+
});
|
|
386
|
+
}}
|
|
387
|
+
showFooter={false}
|
|
388
|
+
actionDomain={actionModalOptions.domain}
|
|
389
|
+
isMenuAction={actionModalOptions?.actionData !== undefined}
|
|
390
|
+
actionData={actionModalOptions?.actionData}
|
|
391
|
+
/>
|
|
392
|
+
</>
|
|
393
|
+
</ContentRootContext.Provider>
|
|
394
|
+
</>);
|
|
400
395
|
};
|
|
401
396
|
|
|
402
397
|
async function getViewsAndInitialView({
|
|
@@ -444,9 +439,7 @@ async function getViewsAndInitialView({
|
|
|
444
439
|
};
|
|
445
440
|
} else if (!view_id) {
|
|
446
441
|
const type = view_mode.split(",")[0];
|
|
447
|
-
const [retrievedViewId] = retriedViewData.find(
|
|
448
|
-
([_, viewType]) => viewType === type,
|
|
449
|
-
)!;
|
|
442
|
+
const [retrievedViewId] = retriedViewData.find(([_, viewType]) => viewType === type)!;
|
|
450
443
|
initialView = { id: retrievedViewId, type };
|
|
451
444
|
} else {
|
|
452
445
|
initialView = {
|
|
@@ -20,7 +20,7 @@ export type TabManagerContextType = {
|
|
|
20
20
|
domain: any;
|
|
21
21
|
context: any;
|
|
22
22
|
model: string;
|
|
23
|
-
views: any
|
|
23
|
+
views: Array<any>;
|
|
24
24
|
title: string;
|
|
25
25
|
target: string;
|
|
26
26
|
initialView: InitialViewData;
|
|
@@ -69,8 +69,9 @@ export type TabManagerContextType = {
|
|
|
69
69
|
setCurrentId?: (id?: number) => void;
|
|
70
70
|
};
|
|
71
71
|
|
|
72
|
-
export const TabManagerContext =
|
|
73
|
-
|
|
72
|
+
export const TabManagerContext = React.createContext<TabManagerContextType | null>(
|
|
73
|
+
null
|
|
74
|
+
);
|
|
74
75
|
|
|
75
76
|
type TabManagerProviderProps = TabManagerContextType & {
|
|
76
77
|
children: React.ReactNode;
|
|
@@ -8,7 +8,7 @@ export function getFilesize(base64string: string) {
|
|
|
8
8
|
|
|
9
9
|
export async function getMimeType(base64string: string) {
|
|
10
10
|
const mimeInfo = await fileTypeFromBuffer(
|
|
11
|
-
Buffer.from(base64string, "base64")
|
|
11
|
+
Buffer.from(base64string, "base64")
|
|
12
12
|
);
|
|
13
13
|
if (!mimeInfo) {
|
|
14
14
|
return {
|
|
@@ -29,13 +29,13 @@ export const toBase64 = (file: File): Promise<string> =>
|
|
|
29
29
|
});
|
|
30
30
|
|
|
31
31
|
export function openBase64InNewTab(data: string, mimeType: string) {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
for (
|
|
32
|
+
var byteCharacters = atob(data);
|
|
33
|
+
var byteNumbers = new Array(byteCharacters.length);
|
|
34
|
+
for (var i = 0; i < byteCharacters.length; i++) {
|
|
35
35
|
byteNumbers[i] = byteCharacters.charCodeAt(i);
|
|
36
36
|
}
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
37
|
+
var byteArray = new Uint8Array(byteNumbers);
|
|
38
|
+
var file = new Blob([byteArray], { type: mimeType + ";base64" });
|
|
39
|
+
var fileURL = URL.createObjectURL(file);
|
|
40
40
|
window.open(fileURL);
|
|
41
41
|
}
|