@imtf/dms-core 1.1.0-beta.6 → 7.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +75 -0
- package/core/components/ActionMenu/styles.d.ts +2 -4
- package/core/components/Chip/Chip.d.ts +1 -1
- package/core/components/CloseModalButton/CloseModalButton.d.ts +4 -0
- package/core/components/DatePicker/DatePicker.d.ts +4 -3
- package/core/components/FormattedMessage/index.d.ts +11 -0
- package/core/components/Inline/index.d.ts +8 -0
- package/core/components/ItemIcon/index.d.ts +1 -1
- package/core/components/NotFound/index.d.ts +4 -0
- package/core/components/Select/Select.d.ts +3 -3
- package/core/components/Tooltip/TooltipError.d.ts +4 -0
- package/core/components/dms-ui/Composer.d.ts +57 -0
- package/core/components/dms-ui/NewDatasourceAutocomplete.d.ts +18 -0
- package/core/components/dms-ui/constants.d.ts +1 -0
- package/core/components/dms-ui/default/DatasourceAutocomplete.d.ts +18 -0
- package/core/components/dms-ui/default/DatePicker.d.ts +17 -0
- package/core/components/dms-ui/default/Group.d.ts +19 -0
- package/core/components/dms-ui/default/NestedGroup.d.ts +7 -0
- package/core/components/dms-ui/default/NumberFormattedTexfield.d.ts +17 -0
- package/core/components/dms-ui/default/NumberTextfield.d.ts +3 -0
- package/core/components/dms-ui/default/RadioButton.d.ts +16 -0
- package/core/components/dms-ui/default/Select.d.ts +20 -0
- package/core/components/dms-ui/default/Textfield.d.ts +17 -0
- package/core/components/dms-ui/default/TwoDigitNumberFormattedTextfield.d.ts +3 -0
- package/core/components/dms-ui/{immutableDefault → default}/index.d.ts +2 -2
- package/core/components/dms-ui/facet/DatasourceAutocomplete.d.ts +13 -0
- package/core/components/dms-ui/facet/DateRangeSearcher.d.ts +18 -0
- package/core/components/dms-ui/facet/Facet.d.ts +11 -0
- package/core/components/dms-ui/facet/NumericRangePicker.d.ts +20 -0
- package/core/components/dms-ui/facet/Select.d.ts +13 -0
- package/core/components/dms-ui/facet/Textfield.d.ts +11 -0
- package/core/components/dms-ui/facet/TypePicker.d.ts +12 -0
- package/core/components/dms-ui/facet/styles.d.ts +9 -0
- package/core/components/dms-ui/messages.d.ts +12 -0
- package/core/components/dms-ui/types.d.ts +9 -1
- package/core/components/dms-ui/utils/getComponent.d.ts +20 -0
- package/core/components/dms-ui/utils/type-guards.d.ts +4 -0
- package/core/constants/apps.d.ts +0 -5
- package/core/constants/permissions.d.ts +1 -0
- package/core/containers/DataGrid/constants.d.ts +2 -0
- package/core/containers/DataGrid/types.d.ts +14 -2
- package/core/containers/DataGrid/utils/crossTabSync.d.ts +13 -0
- package/core/containers/EntityDocuments/components/Accordion.d.ts +1 -1
- package/core/containers/EntityDocuments/components/Document.d.ts +4 -4
- package/core/containers/EntityDocuments/components/DocumentLabel.d.ts +8 -6
- package/core/containers/NotificationCenter/slice.d.ts +1 -1
- package/core/containers/PDFTronViewer/components/LightViewer/config.d.ts +0 -4
- package/core/containers/PDFTronViewer/messages.d.ts +8 -0
- package/core/containers/SearchDataGrid/types.d.ts +1 -6
- package/core/providers/App/actions.d.ts +4 -10
- package/core/providers/App/constants.d.ts +1 -1
- package/core/providers/App/hooks/useApplicationSettings.d.ts +15 -1
- package/core/providers/App/hooks/useDownload.d.ts +6 -0
- package/core/providers/App/hooks/useSettings.d.ts +4 -4
- package/core/providers/App/hooks/useTriggerItems.d.ts +2 -0
- package/core/providers/App/messages.d.ts +4 -0
- package/core/providers/App/reducer.d.ts +1 -1
- package/core/providers/App/service.d.ts +48 -17
- package/core/providers/App/types.d.ts +9 -0
- package/core/providers/App/utils/convertOldUserSettings.d.ts +1 -1
- package/core/providers/App/utils/convertTreeviewFields.d.ts +19 -1
- package/core/providers/Authentication/hooks/useAuth.d.ts +1 -1
- package/core/providers/Authentication/service.d.ts +11 -3
- package/core/providers/Authentication/types.d.ts +5 -7
- package/core/providers/Cases/actions.d.ts +6 -0
- package/core/providers/Cases/service.d.ts +70 -33
- package/core/providers/Cases/types.d.ts +3 -0
- package/core/providers/Cases/utils/common.d.ts +2 -0
- package/core/providers/Ccm/constants.d.ts +6 -0
- package/core/providers/Ccm/types.d.ts +1 -1
- package/core/providers/Ccm/utils/isAccount.d.ts +1 -1
- package/core/providers/Ccm/utils/isClient.d.ts +1 -1
- package/core/providers/Ccm/utils/isClientGroup.d.ts +1 -1
- package/core/providers/Ccm/utils/isHouseholdEntity.d.ts +1 -1
- package/core/providers/DataGrid/Context.d.ts +4 -0
- package/core/providers/Definitions/service.d.ts +48 -19
- package/core/providers/Definitions/types.d.ts +24 -1
- package/core/providers/DropZone/Context.d.ts +2 -2
- package/core/providers/Inodes/actions.d.ts +26 -1
- package/core/providers/Inodes/constants.d.ts +9 -2
- package/core/providers/Inodes/hooks/useInodeByOid.d.ts +1 -1
- package/core/providers/Inodes/hooks/useInodesByOids.d.ts +1 -1
- package/core/providers/Inodes/messages.d.ts +37 -1
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/AccordionItem.d.ts +4 -2
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/ModalContent.d.ts +6 -6
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/index.d.ts +1 -1
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/messages.d.ts +4 -0
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/types.d.ts +1 -1
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/utils/addInodeOidToName.d.ts +2 -16
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/utils/convertToUIPropertiesGroup.d.ts +3 -0
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/utils/getDefaultValuesFromProperties.d.ts +7 -0
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/utils/replaceComponentsWithConfig.d.ts +1 -1
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/utils/resolveProperties.d.ts +8 -0
- package/core/providers/Inodes/service.d.ts +141 -65
- package/core/providers/Inodes/type-guards.d.ts +2 -0
- package/core/providers/Inodes/types.d.ts +8 -5
- package/core/providers/Inodes/utils/can.d.ts +1 -0
- package/core/providers/Inodes/utils/getUrl.d.ts +2 -1
- package/core/providers/Inodes/utils/resolveInodeTypes.d.ts +4 -2
- package/core/providers/Inodes/utils/validatePropertiesForm.d.ts +2 -0
- package/core/providers/Inspectors/Context.d.ts +3 -0
- package/core/providers/Inspectors/types.d.ts +5 -5
- package/core/providers/MdmGraph/actions.d.ts +5 -1
- package/core/providers/MdmGraph/constants.d.ts +6 -0
- package/core/providers/MdmGraph/service.d.ts +56 -31
- package/core/providers/MdmGraph/types.d.ts +10 -0
- package/core/providers/Modal/hooks/useModal.d.ts +1 -0
- package/core/providers/Modal/slice.d.ts +3 -0
- package/core/providers/Modal/types.d.ts +1 -0
- package/core/providers/Plugins/hooks/app/useSystemNotification.d.ts +8 -3
- package/core/providers/Plugins/hooks/tasks/useActions.d.ts +2 -2
- package/core/providers/Plugins/hooks/tasks/useTaskProcessing.d.ts +8 -0
- package/core/providers/Plugins/pluginRegistry.d.ts +21 -12
- package/core/providers/Plugins/types/componentPlugins.d.ts +2 -2
- package/core/providers/Plugins/withComponentPlugin.d.ts +2 -2
- package/core/providers/Search/service.d.ts +10 -4
- package/core/providers/Search/types.d.ts +0 -38
- package/core/providers/Tasks/Context.d.ts +8 -5
- package/core/providers/Tasks/constants.d.ts +2 -1
- package/core/providers/Tasks/service.d.ts +43 -23
- package/core/providers/Tasks/types.d.ts +7 -0
- package/core/providers/Tasks/utils/isDocumentTask.d.ts +2 -0
- package/core/providers/Uploader/Context.d.ts +1 -1
- package/core/providers/User/hooks/useAgencies.d.ts +16 -0
- package/core/providers/User/hooks/useIsAgencyEnabled.d.ts +5 -0
- package/core/providers/User/saga.d.ts +1 -2
- package/core/providers/User/service.d.ts +18 -0
- package/core/providers/User/types.d.ts +21 -0
- package/core/services/constants.d.ts +1 -0
- package/core/services/index.d.ts +6 -6
- package/core/services/localStorage.d.ts +1 -0
- package/core/theme/theme.base.d.ts +302 -21
- package/core/theme/theme.lightMode.d.ts +34 -170
- package/core/utils/common.d.ts +15 -0
- package/core/utils/string.d.ts +2 -1
- package/package.json +1 -1
- package/reducers.d.ts +2 -3
- package/store.d.ts +12 -18
- package/vendor/@imtf/react-components/components/ActivityDetail/ActivityDetail.d.ts +2 -30
- package/vendor/@imtf/react-components/components/CounterStackedBar/CounterStackedBar.d.ts +1 -27
- package/vendor/@imtf/react-components/components/Error/Error.d.ts +2 -55
- package/vendor/@imtf/react-components/components/InfiniteScroll/InfiniteScroll.d.ts +0 -4
- package/vendor/@imtf/react-components/components/Line/Line.d.ts +1 -38
- package/vendor/@imtf/react-components/components/Loader/Loader.d.ts +1 -22
- package/vendor/@imtf/react-components/components/Menu/Menu.d.ts +1 -9
- package/vendor/@imtf/react-components/components/NoContent/NoContent.d.ts +1 -10
- package/vendor/@imtf/react-components/components/Notification/Notification.d.ts +2 -55
- package/vendor/@imtf/react-components/components/ProgressCircleBar/ProgressCircleBar.d.ts +2 -43
- package/vendor/@imtf/react-components/components/Scroller/Scroller.d.ts +1 -19
- package/vendor/@imtf/react-components/components/SearchBar/SearchBar.d.ts +2 -57
- package/vendor/@imtf/react-components/components/Timeline/Timeline.d.ts +1 -14
- package/vendor/@imtf/react-components/components/Timeline/TimelineItem.d.ts +2 -46
- package/vendor/@imtf/react-components/components/ViewMore/ViewMore.d.ts +1 -24
- package/vendor/@imtf/react-components/components/ViewMoreCard/ViewMoreCard.d.ts +2 -73
- package/vendor/@imtf/react-components/components/ViewMoreCard/utils.d.ts +2 -2
- package/vendor/@imtf/react-components/components/index.d.ts +0 -14
- package/vendor/@imtf/react-components/index.d.ts +0 -1
- package/vendor/@imtf/react-components/utils/common.d.ts +1 -4
- package/vendor/@imtf/react-components/utils/constants.d.ts +0 -1
- package/core/components/Select/ListboxComponent.d.ts +0 -5
- package/core/components/dms-ui/DatasourceAutocomplete.d.ts +0 -14
- package/core/components/dms-ui/ImmutableComposer.d.ts +0 -15
- package/core/components/dms-ui/immutableDefault/DatasourceAutocomplete.d.ts +0 -19
- package/core/components/dms-ui/immutableDefault/DatePicker.d.ts +0 -15
- package/core/components/dms-ui/immutableDefault/Group.d.ts +0 -16
- package/core/components/dms-ui/immutableDefault/NumberFormattedTexfield.d.ts +0 -14
- package/core/components/dms-ui/immutableDefault/NumberTextfield.d.ts +0 -2
- package/core/components/dms-ui/immutableDefault/RadioButton.d.ts +0 -19
- package/core/components/dms-ui/immutableDefault/Select.d.ts +0 -19
- package/core/components/dms-ui/immutableDefault/Switch.d.ts +0 -19
- package/core/components/dms-ui/immutableDefault/Textfield.d.ts +0 -21
- package/core/components/dms-ui/immutableFacet/DatasourceAutocomplete.d.ts +0 -13
- package/core/components/dms-ui/immutableFacet/DateRangeSearcher.d.ts +0 -14
- package/core/components/dms-ui/immutableFacet/Facet.d.ts +0 -23
- package/core/components/dms-ui/immutableFacet/NumericRangePicker.d.ts +0 -14
- package/core/components/dms-ui/immutableFacet/Select.d.ts +0 -13
- package/core/components/dms-ui/immutableFacet/Textfield.d.ts +0 -13
- package/core/components/dms-ui/immutableFacet/TypePicker.d.ts +0 -13
- package/core/components/dms-ui/immutableFacet/styles.d.ts +0 -5
- package/core/components/dms-ui/utils/getImmutableComponent.d.ts +0 -19
- package/core/containers/EntityDocuments/styles.d.ts +0 -10
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/utils/getInodesRequiredFieldNames.d.ts +0 -10
- package/core/providers/Inodes/modals/AssignTypeAndPropertiesModal/utils/getInvalidInodeOids.d.ts +0 -10
- package/core/providers/SystemNotification/constants.d.ts +0 -3
- package/core/providers/SystemNotification/slice.d.ts +0 -9
- package/core/providers/SystemNotification/useSystemNotification.d.ts +0 -6
- package/core/utils/immutable.d.ts +0 -2
- package/vendor/@imtf/react-components/components/BasicNotification/BasicNotification.d.ts +0 -52
- package/vendor/@imtf/react-components/components/BasicNotification/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/BasicNotification/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Breadcrumb/Breadcrumb.d.ts +0 -36
- package/vendor/@imtf/react-components/components/Breadcrumb/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Breadcrumb/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Chip/Chip.d.ts +0 -41
- package/vendor/@imtf/react-components/components/Chip/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Chip/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Chip/messages.d.ts +0 -7
- package/vendor/@imtf/react-components/components/Chip/utils.d.ts +0 -14
- package/vendor/@imtf/react-components/components/DebounceField/DebounceField.d.ts +0 -35
- package/vendor/@imtf/react-components/components/DebounceField/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/DebounceField/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/DetailList/DetailList.d.ts +0 -24
- package/vendor/@imtf/react-components/components/DetailList/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/DetailList/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/DetailTree/DetailTree.d.ts +0 -30
- package/vendor/@imtf/react-components/components/DetailTree/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/DetailTree/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/ErrorCatcher/ErrorCatcher.d.ts +0 -40
- package/vendor/@imtf/react-components/components/ErrorCatcher/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/ErrorCatcher/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/InfoCard/InfoCard.d.ts +0 -64
- package/vendor/@imtf/react-components/components/InfoCard/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Inline/Inline.d.ts +0 -19
- package/vendor/@imtf/react-components/components/Inline/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Inline/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Internal/FormattedMessage.d.ts +0 -11
- package/vendor/@imtf/react-components/components/MenuSelect/MenuSelect.d.ts +0 -43
- package/vendor/@imtf/react-components/components/MenuSelect/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/MenuSelect/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Navipath/Navipath.d.ts +0 -52
- package/vendor/@imtf/react-components/components/Navipath/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Navipath/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/RippleEffect/RippleEffect.d.ts +0 -33
- package/vendor/@imtf/react-components/components/RippleEffect/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/RippleEffect/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Stats/Stats.d.ts +0 -39
- package/vendor/@imtf/react-components/components/Stats/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/Stats/index.d.ts +0 -1
- package/vendor/@imtf/react-components/components/TitleContent/TitleContent.d.ts +0 -25
- package/vendor/@imtf/react-components/components/TitleContent/ids.d.ts +0 -1
- package/vendor/@imtf/react-components/components/TitleContent/index.d.ts +0 -1
- package/vendor/@imtf/react-components/hooks/index.d.ts +0 -1
- package/vendor/@imtf/react-components/hooks/useResponsiveBreakpoints.d.ts +0 -13
- package/vendor/@imtf/react-components/utils/resizeObserver.d.ts +0 -1
- /package/core/components/dms-ui/{immutableFacet → facet}/index.d.ts +0 -0
package/README.md
ADDED
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
# @imtf/dms-core
|
|
2
|
+
|
|
3
|
+
TypeScript typings for `dms-core` (the ICOS front end) - for typing your own code against its domain model, and for the `IMTFPlugins` plugin system it exposes at runtime.
|
|
4
|
+
|
|
5
|
+
## Prerequisites
|
|
6
|
+
|
|
7
|
+
- TypeScript 5+.
|
|
8
|
+
- `IMTFPlugins` is a global provided at runtime by dms-core itself, inside a plugin bundle it loads - this package only supplies its types. Referencing `IMTFPlugins` outside that runtime (e.g. an isolated unit test) will be `undefined` unless you mock it.
|
|
9
|
+
|
|
10
|
+
## Installation
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
npm install --save-dev @imtf/dms-core
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
This is a types-only package - it ships no runtime code, only `.d.ts` declarations.
|
|
17
|
+
|
|
18
|
+
## Using the domain types
|
|
19
|
+
|
|
20
|
+
Import any of the exported domain types directly to type your own functions, components, or utilities - this works regardless of whether the code is a registered plugin. The package exports the domain types used across dms-core's plugin surface (`Case`, `Task`, `Inode`, `Entity`, and others); rely on your editor's autocomplete on `@imtf/dms-core` for the full, current list rather than a list here that can drift out of date.
|
|
21
|
+
|
|
22
|
+
```typescript
|
|
23
|
+
import type { Case, Task } from "@imtf/dms-core";
|
|
24
|
+
|
|
25
|
+
function getCaseLabel(currentCase: Case): string {
|
|
26
|
+
return currentCase.label;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
function isOpenTask(task: Task): boolean {
|
|
30
|
+
return task.status === "open";
|
|
31
|
+
}
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Using the `IMTFPlugins` global
|
|
35
|
+
|
|
36
|
+
When `dms-core` starts, it registers a global `IMTFPlugins` object - the entry point for building custom plugins that extend Core without modifying it. This package types that global so you get autocomplete and type-checking while authoring plugins.
|
|
37
|
+
|
|
38
|
+
Registering a plugin (available plugin types are exposed at runtime via `IMTFPlugins.TYPES` - use autocomplete there too):
|
|
39
|
+
|
|
40
|
+
```typescript
|
|
41
|
+
import MyPluginComponent from "./MyPlugin";
|
|
42
|
+
|
|
43
|
+
IMTFPlugins.register(
|
|
44
|
+
IMTFPlugins.TYPES.QUESTIONNAIRE_PART,
|
|
45
|
+
"myPlugin",
|
|
46
|
+
MyPluginComponent,
|
|
47
|
+
);
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
Reading data via the hooks API (namespaced under `IMTFPlugins.hooks`, grouped by domain - `app`, `case`, `task`, `mdm`, `inode`):
|
|
51
|
+
|
|
52
|
+
```typescript
|
|
53
|
+
export default function MyComponent({ item }: { item: Case }) {
|
|
54
|
+
const { data: currentCase } = IMTFPlugins.hooks.case.useCase(item);
|
|
55
|
+
// ...
|
|
56
|
+
}
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Calling an action:
|
|
60
|
+
|
|
61
|
+
```typescript
|
|
62
|
+
const { getAction, TYPES } = IMTFPlugins.actions;
|
|
63
|
+
|
|
64
|
+
const action = getAction(TYPES.APP.OPEN_IN_NEW_WINDOW, [item]);
|
|
65
|
+
if (action) {
|
|
66
|
+
action();
|
|
67
|
+
}
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## Versioning
|
|
71
|
+
|
|
72
|
+
This package follows semantic versioning, always aligned with the `dms-core` product release version (e.g. `7.4.X`) — so the version you install tells you exactly which `dms-core` release its types were generated from.
|
|
73
|
+
|
|
74
|
+
- **Stable releases** (`x.y.z`, no suffix) are published under the `latest` npm dist-tag. `npm install @imtf/dms-core` without pinning a version resolves to one of these.
|
|
75
|
+
- **Prereleases and variant lines** (e.g. `x.y.z-beta.n`, `x.y.z-natwest.n`) publish under their own identifier as the npm dist-tag (`beta`, `natwest`, ...) rather than `latest`, so they're never picked up unless explicitly requested - either by pinning the exact version (e.g. `"@imtf/dms-core": "1.1.0-beta.6"`) or installing via that tag (e.g. `npm install @imtf/dms-core@beta`).
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
export const IconButtonStyled: import("@emotion/styled").StyledComponent<import("@mui/material").IconButtonOwnProps & Omit<import("@mui/material").ButtonBaseOwnProps, "classes"> & import("@mui/material/OverridableComponent").CommonProps & Omit<
|
|
2
|
-
|
|
3
|
-
}, "classes" | "children" | "className" | "sx" | "style" | "tabIndex" | "color" | "loading" | "size" | "disabled" | "action" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "loadingIndicator" | "edge"> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
4
|
-
export const MoreIcon: import("@emotion/styled").StyledComponent<Omit<import("react").SVGProps<SVGSVGElement> & import("@imtf/icons").IconProps, "ref"> & import("react").RefAttributes<SVGSVGElement> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
1
|
+
export const IconButtonStyled: import("@emotion/styled").StyledComponent<import("@mui/material").IconButtonOwnProps & Omit<import("@mui/material").ButtonBaseOwnProps, "classes"> & import("@mui/material/OverridableComponent").CommonProps & Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "classes" | "children" | "className" | "sx" | "style" | "tabIndex" | "color" | "action" | "centerRipple" | "disabled" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "loading" | "loadingIndicator" | "size" | "edge"> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
2
|
+
export const MenuIcon: import("@emotion/styled").StyledComponent<Omit<import("react").SVGProps<SVGSVGElement> & import("@imtf/icons").IconProps, "ref"> & import("react").RefAttributes<SVGSVGElement> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
@@ -4,5 +4,5 @@ type ChipProps = {
|
|
|
4
4
|
margin?: boolean;
|
|
5
5
|
customColor?: string | null;
|
|
6
6
|
} & MuiChipProps;
|
|
7
|
-
declare const Chip: ({ title, type, margin, size, customColor, style, ...props }: ChipProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
7
|
+
declare const Chip: ({ title, label, type, margin, size, customColor, style, ...props }: ChipProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
8
8
|
export default Chip;
|
|
@@ -5,6 +5,10 @@ type CloseModalButtonProps = {
|
|
|
5
5
|
/** The content placed before the close button. */
|
|
6
6
|
children: React.ReactNode;
|
|
7
7
|
onClick: IconButtonProps["onClick"];
|
|
8
|
+
/** Additional props to pass to the IconButton component. */
|
|
9
|
+
buttonProps?: IconButtonProps & {
|
|
10
|
+
"data-testid"?: string;
|
|
11
|
+
};
|
|
8
12
|
};
|
|
9
13
|
declare const CloseModalButton: import("react").ForwardRefExoticComponent<CloseModalButtonProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
10
14
|
export default CloseModalButton;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { TextFieldProps } from "@mui/material";
|
|
2
2
|
import { DatePickerProps } from "@mui/x-date-pickers";
|
|
3
|
-
|
|
4
|
-
size
|
|
5
|
-
}
|
|
3
|
+
interface CustomDatePickerProps extends DatePickerProps {
|
|
4
|
+
size?: TextFieldProps["size"];
|
|
5
|
+
}
|
|
6
|
+
declare const DatePicker: (props: CustomDatePickerProps) => import("react/jsx-runtime").JSX.Element;
|
|
6
7
|
export default DatePicker;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
type FormattedMessageProps = {
|
|
2
|
+
message: string | {
|
|
3
|
+
id: string;
|
|
4
|
+
defaultMessage?: string;
|
|
5
|
+
values?: Record<string, any>;
|
|
6
|
+
};
|
|
7
|
+
values?: Record<string, any>;
|
|
8
|
+
};
|
|
9
|
+
export declare const FormattedMessage: ({ message: messageBase, values, }: FormattedMessageProps) => string | null;
|
|
10
|
+
declare const _default: import("react").MemoExoticComponent<({ message: messageBase, values, }: FormattedMessageProps) => string | null>;
|
|
11
|
+
export default _default;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
export declare const Inline: React.ForwardRefExoticComponent<{
|
|
3
|
+
disableBorder?: boolean;
|
|
4
|
+
} & React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
5
|
+
declare const _default: React.NamedExoticComponent<{
|
|
6
|
+
disableBorder?: boolean;
|
|
7
|
+
} & React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
export default _default;
|
|
@@ -6,7 +6,7 @@ declare function ItemIcon({ item: itemProp, margin, size, align, ...props }: {
|
|
|
6
6
|
margin?: number | undefined;
|
|
7
7
|
size?: number | undefined;
|
|
8
8
|
align?: string | undefined;
|
|
9
|
-
}):
|
|
9
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
10
10
|
declare namespace ItemIcon {
|
|
11
11
|
namespace propTypes {
|
|
12
12
|
let item: PropTypes.Requireable<{}>;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { IconProps } from "@imtf/icons";
|
|
2
|
+
import type { SVGProps } from "react";
|
|
3
|
+
declare const ForwardRef: import("react").ForwardRefExoticComponent<Omit<SVGProps<SVGSVGElement> & IconProps, "ref"> & import("react").RefAttributes<SVGSVGElement>>;
|
|
4
|
+
export { ForwardRef as NotFoundIcon };
|
|
@@ -5,16 +5,16 @@ export interface AutocompleteProps<T, Multiple extends boolean | undefined = und
|
|
|
5
5
|
helperText?: TextFieldProps["helperText"];
|
|
6
6
|
placeholder?: TextFieldProps["placeholder"];
|
|
7
7
|
required?: TextFieldProps["required"];
|
|
8
|
-
virtualized?: boolean;
|
|
9
8
|
itemSize?: number;
|
|
10
9
|
autoFocus?: boolean;
|
|
11
10
|
renderInput?: (params: AutocompleteRenderInputParams) => React.ReactNode;
|
|
12
|
-
InputProps?: AutocompleteRenderInputParams["InputProps"]
|
|
11
|
+
InputProps?: Partial<AutocompleteRenderInputParams["InputProps"]>;
|
|
13
12
|
creatable?: boolean;
|
|
14
13
|
onCreate?: (inputValue: string, callback: (newValue: string | false) => void) => void;
|
|
14
|
+
textFieldProps?: TextFieldProps;
|
|
15
15
|
}
|
|
16
16
|
/**
|
|
17
17
|
* Use `Select` to add a select field. Override AutocompleteComponent directly with props
|
|
18
18
|
*/
|
|
19
|
-
export declare const Select: <T, Multiple extends boolean | undefined = undefined, DisableClearable extends boolean | undefined = undefined, FreeSolo extends boolean | undefined = undefined>({ label, error, helperText, placeholder, required,
|
|
19
|
+
export declare const Select: <T, Multiple extends boolean | undefined = undefined, DisableClearable extends boolean | undefined = undefined, FreeSolo extends boolean | undefined = undefined>({ label, error, helperText, placeholder, required, getOptionLabel, renderOption, renderInput, itemSize, loading, InputProps, options, textFieldProps, ...props }: AutocompleteProps<T, Multiple, DisableClearable, FreeSolo>) => import("react/jsx-runtime").JSX.Element;
|
|
20
20
|
export default Select;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
import { Inode, InodeTypeRef } from "../../../core/providers/Inodes/types";
|
|
3
|
+
import { PropertiesComponent, UIPropertiesGroup } from "./types";
|
|
4
|
+
type ComposerProps = {
|
|
5
|
+
components: (PropertiesComponent | UIPropertiesGroup)[];
|
|
6
|
+
display: "default" | "facet";
|
|
7
|
+
control: Control;
|
|
8
|
+
/**
|
|
9
|
+
* No need to use this props, as there's already an onChange from RHF to update the form state
|
|
10
|
+
* But you can use it if you need to know which component changed and its value
|
|
11
|
+
*/
|
|
12
|
+
onChange?: (name: string, value: unknown) => void;
|
|
13
|
+
/**
|
|
14
|
+
* The inode that is being edited. Not really required if you don't use the Group component
|
|
15
|
+
*/
|
|
16
|
+
inode?: Inode;
|
|
17
|
+
/**
|
|
18
|
+
* Hide the current group title if the inode is the same as the current group
|
|
19
|
+
*/
|
|
20
|
+
hideCurrentGroupTitle?: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* Disable all the Composers components
|
|
23
|
+
*/
|
|
24
|
+
disabled?: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* The typeRef of the current group
|
|
27
|
+
*/
|
|
28
|
+
typeRef?: InodeTypeRef;
|
|
29
|
+
/**
|
|
30
|
+
* Whether the nested groups are collapsible or not
|
|
31
|
+
*/
|
|
32
|
+
collapsibleNestedGroups?: boolean;
|
|
33
|
+
/**
|
|
34
|
+
* Whether the first group should have a top left and top right border radius or not
|
|
35
|
+
*/
|
|
36
|
+
removeFirstGroupTopBorderRadius?: boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Context properties that can be used by the components to display or not some values, or to filter some values.
|
|
39
|
+
* For example, it can be the current user's agencies to only display the values of those agencies in a datasource autocomplete.
|
|
40
|
+
* This is especially useful when uploading a file, we can pass the folder's properties in which the file is being uploaded for more context.
|
|
41
|
+
*
|
|
42
|
+
* Here's the structure needed:
|
|
43
|
+
* {
|
|
44
|
+
* "key1": "value1",
|
|
45
|
+
* "key2": "value2",
|
|
46
|
+
* }
|
|
47
|
+
*/
|
|
48
|
+
contextProperties?: Record<string, unknown>;
|
|
49
|
+
/**
|
|
50
|
+
* Whether to show a search icon next to the property in the inspector properties panel.
|
|
51
|
+
* Clicking it navigates to the first search mask with the property technical key and current value appended as query parameters.
|
|
52
|
+
*/
|
|
53
|
+
searchable?: boolean;
|
|
54
|
+
onSearchablePropertyClick?: (propertyName: PropertiesComponent["name"], propertyValue: string, kind: PropertiesComponent["kind"]) => void;
|
|
55
|
+
};
|
|
56
|
+
export default function Composer({ components, display, control, onChange, disabled, hideCurrentGroupTitle, typeRef, collapsibleNestedGroups, removeFirstGroupTopBorderRadius, contextProperties, searchable, onSearchablePropertyClick, ...props }: ComposerProps): import("react/jsx-runtime").JSX.Element;
|
|
57
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { SelectProps, TextFieldProps } from "@mui/material";
|
|
2
|
+
import { ControllerRenderProps } from "react-hook-form";
|
|
3
|
+
type AutocompleteProps = SelectProps & {
|
|
4
|
+
name: string;
|
|
5
|
+
field: ControllerRenderProps;
|
|
6
|
+
required?: TextFieldProps["required"];
|
|
7
|
+
datasourceName: string;
|
|
8
|
+
inputProps?: TextFieldProps["InputProps"];
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
autoSelect?: boolean;
|
|
11
|
+
error: TextFieldProps["error"];
|
|
12
|
+
helperText?: TextFieldProps["helperText"];
|
|
13
|
+
variant: TextFieldProps["variant"];
|
|
14
|
+
freeSolo?: boolean;
|
|
15
|
+
contextProperties?: Record<string, unknown>;
|
|
16
|
+
};
|
|
17
|
+
declare const _default: import("react").MemoExoticComponent<({ name, field, required, datasourceName, inputProps, disabled, autoSelect, error, helperText, variant, freeSolo, contextProperties, ...props }: AutocompleteProps) => import("react/jsx-runtime").JSX.Element>;
|
|
18
|
+
export default _default;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export declare const UI: {
|
|
2
2
|
readonly GROUP: "dms-core.ui.component.Group";
|
|
3
|
+
readonly PROPERTY_GROUP: "dms-core.ui.component.PropertyGroup";
|
|
3
4
|
readonly AUTOCOMPLETE: "dms-core.ui.component.Autocomplete";
|
|
4
5
|
readonly TEXTFIELD: "dms-core.ui.component.TextField";
|
|
5
6
|
readonly NUMBER_TEXTFIELD: "dms-core.ui.component.NumberTextField";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
import { PropertiesComponent } from "../types";
|
|
3
|
+
type AutocompleteFieldProps = {
|
|
4
|
+
control: Control;
|
|
5
|
+
name: string;
|
|
6
|
+
label: string;
|
|
7
|
+
datasourceName?: string;
|
|
8
|
+
required?: boolean;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
allowUnmanagedValue?: boolean;
|
|
11
|
+
onChange?: (name: string, value: unknown) => void;
|
|
12
|
+
contextProperties?: Record<string, unknown>;
|
|
13
|
+
searchable?: boolean;
|
|
14
|
+
onSearchablePropertyClick?: (name: PropertiesComponent["name"], value: unknown, kind: PropertiesComponent["kind"]) => void;
|
|
15
|
+
kind: PropertiesComponent["kind"];
|
|
16
|
+
};
|
|
17
|
+
export default function AutocompleteField({ control, name, label, datasourceName, required, disabled, allowUnmanagedValue, onChange, contextProperties, searchable, onSearchablePropertyClick, kind, ...props }: AutocompleteFieldProps): import("react/jsx-runtime").JSX.Element | null;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { DatePickerProps } from "@mui/x-date-pickers";
|
|
2
|
+
import { Control } from "react-hook-form";
|
|
3
|
+
import { PropertiesComponent } from "../types";
|
|
4
|
+
export type DatePickerComponentProps = DatePickerProps & {
|
|
5
|
+
control: Control;
|
|
6
|
+
name: string;
|
|
7
|
+
label: string;
|
|
8
|
+
required?: boolean;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
onChange?: (name: string, value: unknown) => void;
|
|
11
|
+
minValue?: DatePickerProps["minDate"];
|
|
12
|
+
maxValue?: DatePickerProps["maxDate"];
|
|
13
|
+
searchable?: boolean;
|
|
14
|
+
onSearchablePropertyClick?: (name: PropertiesComponent["name"], value: unknown, kind: PropertiesComponent["kind"]) => void;
|
|
15
|
+
kind: PropertiesComponent["kind"];
|
|
16
|
+
};
|
|
17
|
+
export default function DatePickerComponent({ control, required, disabled, label, name, minValue: minDateProp, maxValue: maxDateProp, onChange, searchable, onSearchablePropertyClick, kind, ...props }: DatePickerComponentProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Inode } from "../../../providers/Inodes/types";
|
|
2
|
+
import { UIPropertiesGroup } from "../types";
|
|
3
|
+
type GroupProps = {
|
|
4
|
+
inodeRef: UIPropertiesGroup["inodeRef"];
|
|
5
|
+
typeRef: UIPropertiesGroup["typeRef"];
|
|
6
|
+
inode?: Inode;
|
|
7
|
+
hideCurrentGroupTitle: boolean;
|
|
8
|
+
children?: React.ReactNode;
|
|
9
|
+
/**
|
|
10
|
+
* Whether the group is the first one or not
|
|
11
|
+
*/
|
|
12
|
+
isFirstGroup: boolean;
|
|
13
|
+
/**
|
|
14
|
+
* Whether the first group should have a top left and top right border radius or not
|
|
15
|
+
*/
|
|
16
|
+
removeFirstGroupTopBorderRadius: boolean;
|
|
17
|
+
};
|
|
18
|
+
export default function Group({ inodeRef, typeRef, inode, hideCurrentGroupTitle, children, isFirstGroup, removeFirstGroupTopBorderRadius, }: GroupProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { InodeTypeRef } from "../../../providers/Inodes/types";
|
|
2
|
+
import { PropertiesComponent } from "../types";
|
|
3
|
+
export default function NestedGroup({ children, label, autoExpanded, typeRef, name, collapsibleNestedGroups, }: PropertiesComponent & {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
collapsibleNestedGroups: boolean;
|
|
6
|
+
typeRef: InodeTypeRef;
|
|
7
|
+
}): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
import { NumericFormatProps } from "react-number-format";
|
|
3
|
+
import { PropertiesComponent } from "../types";
|
|
4
|
+
export type NumberFormattedTextfieldProps = NumericFormatProps & {
|
|
5
|
+
control: Control;
|
|
6
|
+
name: string;
|
|
7
|
+
label: string;
|
|
8
|
+
required?: boolean;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
minValue?: number;
|
|
11
|
+
maxValue?: number;
|
|
12
|
+
onChange?: (name: string, value: unknown) => void;
|
|
13
|
+
searchable?: boolean;
|
|
14
|
+
onSearchablePropertyClick?: (name: PropertiesComponent["name"], value: unknown, kind: PropertiesComponent["kind"]) => void;
|
|
15
|
+
kind: PropertiesComponent["kind"];
|
|
16
|
+
};
|
|
17
|
+
export default function NumberFormattedTextfield({ control, name, label, required, disabled, minValue, maxValue, onChange, searchable, onSearchablePropertyClick, kind, ...props }: NumberFormattedTextfieldProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
type RadioOption = {
|
|
3
|
+
value: string;
|
|
4
|
+
label: string;
|
|
5
|
+
};
|
|
6
|
+
type RadioButtonComponentProps = {
|
|
7
|
+
control: Control;
|
|
8
|
+
options: RadioOption[];
|
|
9
|
+
name: string;
|
|
10
|
+
label: string;
|
|
11
|
+
required?: boolean;
|
|
12
|
+
disabled?: boolean;
|
|
13
|
+
onChange?: (name: string, value: unknown) => void;
|
|
14
|
+
};
|
|
15
|
+
export default function RadioButtonComponent({ control, options, name, label, required, disabled, onChange, ...props }: RadioButtonComponentProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
import { PropertiesComponent } from "../types";
|
|
3
|
+
type SelectOption = {
|
|
4
|
+
value: string;
|
|
5
|
+
label: string;
|
|
6
|
+
};
|
|
7
|
+
type SelectProps = {
|
|
8
|
+
control: Control;
|
|
9
|
+
name: string;
|
|
10
|
+
label: string;
|
|
11
|
+
options: SelectOption[];
|
|
12
|
+
required?: boolean;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
onChange?: (name: string, value: unknown) => void;
|
|
15
|
+
searchable?: boolean;
|
|
16
|
+
onSearchablePropertyClick?: (name: PropertiesComponent["name"], value: unknown, kind: PropertiesComponent["kind"]) => void;
|
|
17
|
+
kind: PropertiesComponent["kind"];
|
|
18
|
+
};
|
|
19
|
+
declare const Select: ({ control, name, label, options, required, disabled, onChange, searchable, onSearchablePropertyClick, kind, ...props }: SelectProps) => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
export default Select;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { TextFieldProps } from "@mui/material";
|
|
2
|
+
import { Control } from "react-hook-form";
|
|
3
|
+
import { PropertiesComponent } from "../types";
|
|
4
|
+
export type TextFieldComponentProps = TextFieldProps & {
|
|
5
|
+
control: Control;
|
|
6
|
+
name: string;
|
|
7
|
+
label: string;
|
|
8
|
+
required?: boolean;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
minValue?: number;
|
|
11
|
+
maxValue?: number;
|
|
12
|
+
onChange?: (name: string, value: unknown) => void;
|
|
13
|
+
searchable?: boolean;
|
|
14
|
+
onSearchablePropertyClick?: (name: PropertiesComponent["name"], value: unknown, kind: PropertiesComponent["kind"]) => void;
|
|
15
|
+
kind: PropertiesComponent["kind"];
|
|
16
|
+
};
|
|
17
|
+
export default function TextFieldComponent({ control, name, label, required, disabled, minValue, maxValue, onChange, searchable, onSearchablePropertyClick, kind, ...props }: TextFieldComponentProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export { default as DatasourceAutocomplete } from "./DatasourceAutocomplete";
|
|
2
2
|
export { default as DatePicker } from "./DatePicker";
|
|
3
3
|
export { default as Group } from "./Group";
|
|
4
|
+
export { default as NestedGroup } from "./NestedGroup";
|
|
4
5
|
export { default as Select } from "./Select";
|
|
5
|
-
export { default as Switch } from "./Switch";
|
|
6
6
|
export { default as Textfield } from "./Textfield";
|
|
7
7
|
export { default as NumberTextfield } from "./NumberTextfield";
|
|
8
8
|
export { default as NumberFormattedTextfield } from "./NumberFormattedTexfield";
|
|
9
9
|
export { default as RadioButton } from "./RadioButton";
|
|
10
|
-
export
|
|
10
|
+
export { default as TwoDigitNumberFormattedTextfield } from "./TwoDigitNumberFormattedTextfield";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
type AutocompleteFieldProps = {
|
|
3
|
+
control: Control;
|
|
4
|
+
name: string;
|
|
5
|
+
label: string;
|
|
6
|
+
datasourceName?: string;
|
|
7
|
+
required?: boolean;
|
|
8
|
+
disabled?: boolean;
|
|
9
|
+
allowUnmanagedValue?: boolean;
|
|
10
|
+
onChange?: (name: string, value: unknown) => void;
|
|
11
|
+
};
|
|
12
|
+
export default function AutocompleteField({ control, name, label, datasourceName, required, disabled, allowUnmanagedValue, onChange, }: AutocompleteFieldProps): import("react/jsx-runtime").JSX.Element | null;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
type DateRangeSearcherProps = {
|
|
3
|
+
control: Control;
|
|
4
|
+
name: string;
|
|
5
|
+
label: string;
|
|
6
|
+
options: {
|
|
7
|
+
label: string;
|
|
8
|
+
value: {
|
|
9
|
+
to: string;
|
|
10
|
+
from: string;
|
|
11
|
+
};
|
|
12
|
+
count?: number | null;
|
|
13
|
+
}[];
|
|
14
|
+
onChange?: (name: string, value: unknown) => void;
|
|
15
|
+
required?: boolean;
|
|
16
|
+
};
|
|
17
|
+
export default function DateRangeSearcher({ control, name, label, options, onChange, required, }: DateRangeSearcherProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { Control } from "react-hook-form";
|
|
3
|
+
type FacetProps = {
|
|
4
|
+
control: Control;
|
|
5
|
+
name: string;
|
|
6
|
+
label: string;
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
required?: boolean;
|
|
9
|
+
};
|
|
10
|
+
export default function Facet({ control, name, label, children, required, }: FacetProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
type NumericRangeValue = {
|
|
3
|
+
from: string | null;
|
|
4
|
+
to: string | null;
|
|
5
|
+
};
|
|
6
|
+
type NumericRangeOption = {
|
|
7
|
+
label: string;
|
|
8
|
+
value: NumericRangeValue;
|
|
9
|
+
count?: number;
|
|
10
|
+
};
|
|
11
|
+
type NumericRangePickerProps = {
|
|
12
|
+
control: Control;
|
|
13
|
+
name: string;
|
|
14
|
+
label: string;
|
|
15
|
+
options: NumericRangeOption[];
|
|
16
|
+
onChange?: (name: string, value: unknown) => void;
|
|
17
|
+
required?: boolean;
|
|
18
|
+
};
|
|
19
|
+
export default function NumericRangePicker({ control, name, label, options: rawOptions, onChange, required, }: NumericRangePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
import { Option } from "../types";
|
|
3
|
+
type SelectProps = {
|
|
4
|
+
control: Control;
|
|
5
|
+
name: string;
|
|
6
|
+
label: string;
|
|
7
|
+
options: Option[];
|
|
8
|
+
multiple?: boolean;
|
|
9
|
+
onChange?: (name: string, value: unknown) => void;
|
|
10
|
+
required?: boolean;
|
|
11
|
+
};
|
|
12
|
+
export default function Select({ control, name, label, options, multiple, onChange, required, }: SelectProps): false | import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
type TextFieldComponentProps = {
|
|
3
|
+
control: Control;
|
|
4
|
+
name: string;
|
|
5
|
+
label: string;
|
|
6
|
+
required?: boolean;
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
onChange?: (name: string, value: unknown) => void;
|
|
9
|
+
};
|
|
10
|
+
export default function TextFieldComponent({ control, name, label, required, disabled, onChange, ...props }: TextFieldComponentProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
2
|
+
import { Option as OptionType } from "../types";
|
|
3
|
+
type TypePickerComponentProps = {
|
|
4
|
+
control: Control;
|
|
5
|
+
name: string;
|
|
6
|
+
label: string;
|
|
7
|
+
options: OptionType[];
|
|
8
|
+
onChange?: (name: string, value: unknown) => void;
|
|
9
|
+
required?: boolean;
|
|
10
|
+
};
|
|
11
|
+
export default function TypePickerComponent({ control, name, label, options, onChange, required, }: TypePickerComponentProps): false | import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const TextEllipsisSpan: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
2
|
+
export declare const OptionSingle: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
|
|
3
|
+
checked: boolean;
|
|
4
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
5
|
+
export declare const OptionMultiple: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
|
|
6
|
+
checked: boolean;
|
|
7
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
8
|
+
export declare const Count: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
9
|
+
export declare const Input: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, {}>;
|
|
@@ -23,5 +23,17 @@ declare const _default: {
|
|
|
23
23
|
id: string;
|
|
24
24
|
defaultMessage: string;
|
|
25
25
|
};
|
|
26
|
+
placeholder: {
|
|
27
|
+
id: string;
|
|
28
|
+
defaultMessage: string;
|
|
29
|
+
};
|
|
30
|
+
minValue: {
|
|
31
|
+
id: string;
|
|
32
|
+
defaultMessage: string;
|
|
33
|
+
};
|
|
34
|
+
maxValue: {
|
|
35
|
+
id: string;
|
|
36
|
+
defaultMessage: string;
|
|
37
|
+
};
|
|
26
38
|
};
|
|
27
39
|
export default _default;
|
|
@@ -1,12 +1,16 @@
|
|
|
1
1
|
import { InodeRef, InodeTypeRef } from "../../providers/Inodes/types";
|
|
2
2
|
import { UI } from "./constants";
|
|
3
|
-
export type
|
|
3
|
+
export type OldDateValue = {
|
|
4
4
|
from: string;
|
|
5
5
|
to?: string;
|
|
6
6
|
} | {
|
|
7
7
|
from?: string;
|
|
8
8
|
to: string;
|
|
9
9
|
};
|
|
10
|
+
export type DateValue = {
|
|
11
|
+
from?: Date | null;
|
|
12
|
+
to?: Date | null;
|
|
13
|
+
};
|
|
10
14
|
export interface OptionValue {
|
|
11
15
|
label: string;
|
|
12
16
|
value: string;
|
|
@@ -45,5 +49,9 @@ export type PropertiesComponent = {
|
|
|
45
49
|
options?: Option[];
|
|
46
50
|
multiple?: boolean;
|
|
47
51
|
valueFormat?: string;
|
|
52
|
+
maxValue?: string;
|
|
53
|
+
minValue?: string;
|
|
54
|
+
components?: PropertiesComponent[];
|
|
55
|
+
autoExpanded?: boolean;
|
|
48
56
|
};
|
|
49
57
|
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as Default from "../default";
|
|
2
|
+
import * as Facet from "../facet";
|
|
3
|
+
import { PropertiesComponent, UIPropertiesGroup } from "../types";
|
|
4
|
+
export default function getComponent(kind: PropertiesComponent["kind"] | UIPropertiesGroup["kind"], display: "default" | "facet"): (({ control, name, label, options, required, disabled, onChange, searchable, onSearchablePropertyClick, kind, ...props }: {
|
|
5
|
+
control: import("react-hook-form").Control;
|
|
6
|
+
name: string;
|
|
7
|
+
label: string;
|
|
8
|
+
options: {
|
|
9
|
+
value: string;
|
|
10
|
+
label: string;
|
|
11
|
+
}[];
|
|
12
|
+
required?: boolean;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
onChange?: (name: string, value: unknown) => void;
|
|
15
|
+
searchable?: boolean;
|
|
16
|
+
onSearchablePropertyClick?: (name: PropertiesComponent["name"], value: unknown, kind: PropertiesComponent["kind"]) => void;
|
|
17
|
+
kind: PropertiesComponent["kind"];
|
|
18
|
+
}) => import("react/jsx-runtime").JSX.Element) | ((props: import("../default/Textfield").TextFieldComponentProps) => import("react/jsx-runtime").JSX.Element) | ((props: import("../default/NumberFormattedTexfield").NumberFormattedTextfieldProps) => import("react/jsx-runtime").JSX.Element) | (({ component, }: {
|
|
19
|
+
component: PropertiesComponent;
|
|
20
|
+
}) => import("react/jsx-runtime").JSX.Element) | typeof Facet.Select | typeof Facet.DateRangeSearcher | typeof Facet.NumericRangePicker | typeof Default.Group | typeof Default.NestedGroup | typeof Default.DatasourceAutocomplete | typeof Default.DatePicker;
|