@owp/core 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/QuickPanel-xYOXYOdd.js +103 -0
- package/dist/QuickPanel-xYOXYOdd.js.map +1 -0
- package/dist/index-DGvdCuqz.js +49361 -0
- package/dist/index-DGvdCuqz.js.map +1 -0
- package/dist/index.css +1 -0
- package/dist/index.js +172 -0
- package/dist/index.js.map +1 -0
- package/dist/owp-app.css +1 -0
- package/dist/types/auth/authRoles.d.ts +21 -0
- package/dist/types/colors/owpDark.d.ts +20 -0
- package/dist/types/colors/skyBlue.d.ts +20 -0
- package/dist/types/components/NavLinkAdapter/NavLinkAdapter.d.ts +18 -0
- package/dist/types/components/NavLinkAdapter/index.d.ts +1 -0
- package/dist/types/components/OwpAutoLogoutDialog/OwpAutoLogoutDialog.d.ts +3 -0
- package/dist/types/components/OwpBarcodeInput/OwpBarcodeInputField.d.ts +2 -0
- package/dist/types/components/OwpButtonDelete/index.d.ts +7 -0
- package/dist/types/components/OwpButtonSave/index.d.ts +7 -0
- package/dist/types/components/OwpCommonDialog/index.d.ts +17 -0
- package/dist/types/components/OwpDialog/OwpDialog.d.ts +7 -0
- package/dist/types/components/OwpDialog/index.d.ts +1 -0
- package/dist/types/components/OwpDialog/owpDialogSlice.d.ts +14 -0
- package/dist/types/components/OwpExportExcelButton/OwpExportExcelButton.d.ts +22 -0
- package/dist/types/components/OwpFileUploadButton/OwpFileUploadButton.d.ts +10 -0
- package/dist/types/components/OwpLayout/OwpLayout.d.ts +23 -0
- package/dist/types/components/OwpLayout/index.d.ts +1 -0
- package/dist/types/components/OwpLoading/OwpLoading.d.ts +9 -0
- package/dist/types/components/OwpLoading/index.d.ts +1 -0
- package/dist/types/components/OwpMessage/OwpMessage.d.ts +8 -0
- package/dist/types/components/OwpMessage/index.d.ts +1 -0
- package/dist/types/components/OwpMessage/owpMessageSlice.d.ts +14 -0
- package/dist/types/components/OwpNavigation/OwpNavBadge.d.ts +14 -0
- package/dist/types/components/OwpNavigation/OwpNavItem.d.ts +14 -0
- package/dist/types/components/OwpNavigation/OwpNavigation.d.ts +20 -0
- package/dist/types/components/OwpNavigation/horizontal/OwpNavHorizontalLayout1.d.ts +7 -0
- package/dist/types/components/OwpNavigation/horizontal/types/OwpNavHorizontalCollapse.d.ts +12 -0
- package/dist/types/components/OwpNavigation/horizontal/types/OwpNavHorizontalGroup.d.ts +11 -0
- package/dist/types/components/OwpNavigation/horizontal/types/OwpNavHorizontalItem.d.ts +9 -0
- package/dist/types/components/OwpNavigation/horizontal/types/OwpNavHorizontalLink.d.ts +6 -0
- package/dist/types/components/OwpNavigation/index.d.ts +1 -0
- package/dist/types/components/OwpNavigation/isUrlInChildren.d.ts +7 -0
- package/dist/types/components/OwpNavigation/models/OwpNavItemModel.d.ts +8 -0
- package/dist/types/components/OwpNavigation/types/OwpNavBadgeType.d.ts +9 -0
- package/dist/types/components/OwpNavigation/types/OwpNavItemType.d.ts +30 -0
- package/dist/types/components/OwpNavigation/utils/components.d.ts +4 -0
- package/dist/types/components/OwpNavigation/utils/registerComponent.d.ts +4 -0
- package/dist/types/components/OwpNavigation/vertical/OwpNavVerticalLayout1.d.ts +9 -0
- package/dist/types/components/OwpNavigation/vertical/OwpNavVerticalLayout2.d.ts +7 -0
- package/dist/types/components/OwpNavigation/vertical/types/OwpNavVerticalCollapse.d.ts +7 -0
- package/dist/types/components/OwpNavigation/vertical/types/OwpNavVerticalGroup.d.ts +7 -0
- package/dist/types/components/OwpNavigation/vertical/types/OwpNavVerticalItem.d.ts +7 -0
- package/dist/types/components/OwpNavigation/vertical/types/OwpNavVerticalLink.d.ts +8 -0
- package/dist/types/components/OwpNavigation/vertical/types/OwpNavVerticalTab.d.ts +11 -0
- package/dist/types/components/OwpNumberField/index.d.ts +7 -0
- package/dist/types/components/OwpPageCarded/OwpPageCarded.d.ts +52 -0
- package/dist/types/components/OwpPageCarded/OwpPageCardedHeader.d.ts +7 -0
- package/dist/types/components/OwpPageCarded/OwpPageCardedSidebar.d.ts +19 -0
- package/dist/types/components/OwpPageCarded/OwpPageCardedSidebarContent.d.ts +13 -0
- package/dist/types/components/OwpPageCarded/index.d.ts +1 -0
- package/dist/types/components/OwpPageContent/index.d.ts +9 -0
- package/dist/types/components/OwpPageLockLoading/index.d.ts +6 -0
- package/dist/types/components/OwpPageSimple/OwpPageSimple.d.ts +52 -0
- package/dist/types/components/OwpPageSimple/OwpPageSimpleHeader.d.ts +14 -0
- package/dist/types/components/OwpPageSimple/OwpPageSimpleSidebar.d.ts +19 -0
- package/dist/types/components/OwpPageSimple/OwpPageSimpleSidebarContent.d.ts +13 -0
- package/dist/types/components/OwpPageSimple/index.d.ts +1 -0
- package/dist/types/components/OwpPageTitle/index.d.ts +8 -0
- package/dist/types/components/OwpPicker/CalendarContainer.d.ts +4 -0
- package/dist/types/components/OwpPicker/DatePickerInput.d.ts +8 -0
- package/dist/types/components/OwpPicker/OwpDatePicker.d.ts +18 -0
- package/dist/types/components/OwpPicker/OwpDateRangePicker.d.ts +19 -0
- package/dist/types/components/OwpPicker/OwpWeekDatePicker.d.ts +19 -0
- package/dist/types/components/OwpPicker/OwpYearRangePicker.d.ts +18 -0
- package/dist/types/components/OwpPicker/constants.d.ts +4 -0
- package/dist/types/components/OwpScrollbars/OwpScrollbars.d.ts +16 -0
- package/dist/types/components/OwpScrollbars/index.d.ts +1 -0
- package/dist/types/components/OwpSearch/OwpSearch.d.ts +20 -0
- package/dist/types/components/OwpSearch/index.d.ts +1 -0
- package/dist/types/components/OwpSearchFilter/index.d.ts +9 -0
- package/dist/types/components/OwpSection/index.d.ts +13 -0
- package/dist/types/components/OwpSettings/OwpLayoutConfig.d.ts +12 -0
- package/dist/types/components/OwpSettings/OwpLayoutConfigs.d.ts +10 -0
- package/dist/types/components/OwpSettings/OwpSettings.d.ts +34 -0
- package/dist/types/components/OwpSettings/ThemeFormConfigTypes.d.ts +39 -0
- package/dist/types/components/OwpSettings/index.d.ts +1 -0
- package/dist/types/components/OwpSettings/owpSettingsSlice.d.ts +1866 -0
- package/dist/types/components/OwpSettings/palette-generator/PalettePreview.d.ts +14 -0
- package/dist/types/components/OwpSettings/palette-generator/PaletteSelector.d.ts +15 -0
- package/dist/types/components/OwpSettings/palette-generator/SectionPreview.d.ts +12 -0
- package/dist/types/components/OwpShortcuts/OwpShortcuts.d.ts +16 -0
- package/dist/types/components/OwpShortcuts/index.d.ts +1 -0
- package/dist/types/components/OwpSidePanel/OwpSidePanel.d.ts +15 -0
- package/dist/types/components/OwpSidePanel/index.d.ts +1 -0
- package/dist/types/components/OwpSplashScreen/OwpSplashScreen.d.ts +8 -0
- package/dist/types/components/OwpSplashScreen/index.d.ts +1 -0
- package/dist/types/components/OwpSuspense/OwpSuspense.d.ts +15 -0
- package/dist/types/components/OwpSuspense/index.d.ts +1 -0
- package/dist/types/components/OwpSvgIcon/OwpSvgIcon.d.ts +15 -0
- package/dist/types/components/OwpSvgIcon/index.d.ts +1 -0
- package/dist/types/components/OwpTable/OwpDataTable.d.ts +38 -0
- package/dist/types/components/OwpTable/OwpTable.d.ts +22 -0
- package/dist/types/components/OwpTable/OwpVerticalTable.d.ts +27 -0
- package/dist/types/components/OwpTextField/OwpTextMaskField.d.ts +15 -0
- package/dist/types/components/OwpTheme/OwpTheme.d.ts +15 -0
- package/dist/types/components/OwpTheme/index.d.ts +1 -0
- package/dist/types/components/OwpThemeSelector/OwpThemeSelector.d.ts +13 -0
- package/dist/types/components/OwpThemeSelector/SchemePreview.d.ts +14 -0
- package/dist/types/components/OwpThemeSelector/ThemePreview.d.ts +17 -0
- package/dist/types/components/OwpThemeSelector/index.d.ts +1 -0
- package/dist/types/components/OwpTreeGrid/OwpTreeGrid.d.ts +43 -0
- package/dist/types/components/OwpTreeGrid/OwpTreeGridToolbar.d.ts +13 -0
- package/dist/types/components/OwpTreeGrid/TreeGrid.d.ts +18 -0
- package/dist/types/components/OwpTreeGrid/index.d.ts +2 -0
- package/dist/types/components/OwpTreeGrid/utils.d.ts +8 -0
- package/dist/types/components/OwpTreeView/OwpSlotTreeView.d.ts +11 -0
- package/dist/types/components/OwpZoomImageSlider/OwpZoomImageSlider.d.ts +11 -0
- package/dist/types/components/OwpZoomImageSlider/ZoomImage.d.ts +7 -0
- package/dist/types/components/layouts/index.d.ts +8 -0
- package/dist/types/components/layouts/layout1/Layout1.d.ts +10 -0
- package/dist/types/components/layouts/layout1/Layout1Config.d.ts +114 -0
- package/dist/types/components/layouts/layout1/components/FooterLayout1.d.ts +9 -0
- package/dist/types/components/layouts/layout1/components/LeftSideLayout1.d.ts +6 -0
- package/dist/types/components/layouts/layout1/components/NavbarToggleFabLayout1.d.ts +8 -0
- package/dist/types/components/layouts/layout1/components/NavbarWrapperLayout1.d.ts +5 -0
- package/dist/types/components/layouts/layout1/components/RightSideLayout1.d.ts +6 -0
- package/dist/types/components/layouts/layout1/components/ToolbarLayout1.d.ts +9 -0
- package/dist/types/components/layouts/layout1/components/navbar/style-1/NavbarStyle1.d.ts +5 -0
- package/dist/types/components/layouts/layout1/components/navbar/style-1/NavbarStyle1Content.d.ts +9 -0
- package/dist/types/components/layouts/layout1/components/navbar/style-2/NavbarStyle2.d.ts +5 -0
- package/dist/types/components/layouts/layout1/components/navbar/style-2/NavbarStyle2Content.d.ts +9 -0
- package/dist/types/components/layouts/layout1/components/navbar/style-3/NavbarStyle3.d.ts +9 -0
- package/dist/types/components/layouts/layout1/components/navbar/style-3/NavbarStyle3Content.d.ts +10 -0
- package/dist/types/components/layouts/layout2/Layout2.d.ts +10 -0
- package/dist/types/components/layouts/layout2/Layout2Config.d.ts +109 -0
- package/dist/types/components/layouts/layout2/components/FooterLayout2.d.ts +9 -0
- package/dist/types/components/layouts/layout2/components/LeftSideLayout2.d.ts +6 -0
- package/dist/types/components/layouts/layout2/components/NavbarLayout2.d.ts +9 -0
- package/dist/types/components/layouts/layout2/components/NavbarMobileLayout2.d.ts +9 -0
- package/dist/types/components/layouts/layout2/components/NavbarToggleFabLayout2.d.ts +8 -0
- package/dist/types/components/layouts/layout2/components/NavbarWrapperLayout2.d.ts +5 -0
- package/dist/types/components/layouts/layout2/components/RightSideLayout2.d.ts +6 -0
- package/dist/types/components/layouts/layout2/components/ToolbarLayout2.d.ts +9 -0
- package/dist/types/components/layouts/layout3/Layout3.d.ts +10 -0
- package/dist/types/components/layouts/layout3/Layout3Config.d.ts +110 -0
- package/dist/types/components/layouts/layout3/components/FooterLayout3.d.ts +9 -0
- package/dist/types/components/layouts/layout3/components/LeftSideLayout3.d.ts +6 -0
- package/dist/types/components/layouts/layout3/components/NavbarLayout3.d.ts +9 -0
- package/dist/types/components/layouts/layout3/components/NavbarMobileLayout3.d.ts +9 -0
- package/dist/types/components/layouts/layout3/components/NavbarWrapperLayout3.d.ts +5 -0
- package/dist/types/components/layouts/layout3/components/RightSideLayout3.d.ts +6 -0
- package/dist/types/components/layouts/layout3/components/ToolbarLayout3.d.ts +9 -0
- package/dist/types/components/layouts/shared-components/AdjustFontSize.d.ts +8 -0
- package/dist/types/components/layouts/shared-components/DemoLayoutFooterContent.d.ts +5 -0
- package/dist/types/components/layouts/shared-components/DocumentationButton.d.ts +8 -0
- package/dist/types/components/layouts/shared-components/FullScreenToggle.d.ts +8 -0
- package/dist/types/components/layouts/shared-components/LanguageSwitcher.d.ts +7 -0
- package/dist/types/components/layouts/shared-components/Logo.d.ts +5 -0
- package/dist/types/components/layouts/shared-components/OwpLanguageSwitcherSelect.d.ts +7 -0
- package/dist/types/components/layouts/shared-components/OwpSettingsViewerDialog.d.ts +8 -0
- package/dist/types/components/layouts/shared-components/PoweredByLinks.d.ts +5 -0
- package/dist/types/components/layouts/shared-components/PurchaseButton.d.ts +8 -0
- package/dist/types/components/layouts/shared-components/UserMenu.d.ts +11 -0
- package/dist/types/components/layouts/shared-components/UserNavbarHeader.d.ts +5 -0
- package/dist/types/components/layouts/shared-components/configurator/Configurator.d.ts +6 -0
- package/dist/types/components/layouts/shared-components/configurator/SettingsPanel.d.ts +8 -0
- package/dist/types/components/layouts/shared-components/configurator/ThemesPanel.d.ts +8 -0
- package/dist/types/components/layouts/shared-components/navbar/NavbarPinToggleButton.d.ts +10 -0
- package/dist/types/components/layouts/shared-components/navbar/NavbarToggleButton.d.ts +7 -0
- package/dist/types/components/layouts/shared-components/navbar/NavbarToggleFab.d.ts +10 -0
- package/dist/types/components/layouts/shared-components/navbar/navbarSlice.d.ts +18 -0
- package/dist/types/components/layouts/shared-components/navigation/Navigation.d.ts +3 -0
- package/dist/types/components/layouts/shared-components/navigation/NavigationSearch.d.ts +6 -0
- package/dist/types/components/layouts/shared-components/navigation/NavigationShortcuts.d.ts +6 -0
- package/dist/types/components/layouts/shared-components/navigation/store/navigationSlice.d.ts +86 -0
- package/dist/types/components/layouts/shared-components/quickPanel/QuickPanel.d.ts +5 -0
- package/dist/types/components/layouts/shared-components/quickPanel/QuickPanelToggleButton.d.ts +9 -0
- package/dist/types/components/layouts/shared-components/quickPanel/quickPanelSlice.d.ts +14 -0
- package/dist/types/components/layouts/themeLayoutConfigs.d.ts +27 -0
- package/dist/types/components/layouts/themeLayouts.d.ts +13 -0
- package/dist/types/components/shared-components/LightDarkModeToggle.d.ts +8 -0
- package/dist/types/components/shared-components/PageBreadcrumb.d.ts +6 -0
- package/dist/types/components/shared-components/PageTitle.d.ts +11 -0
- package/dist/types/components/shared-components/data-table/DataTable.d.ts +3 -0
- package/dist/types/components/shared-components/data-table/DataTableTopToolbar.d.ts +6 -0
- package/dist/types/components/shared-components/data-table/utils/parseFromValuesOrFunc.d.ts +7 -0
- package/dist/types/components/shared-components/index.d.ts +7 -0
- package/dist/types/components/shared-components/tabs/OwpTab.d.ts +6 -0
- package/dist/types/components/shared-components/tabs/OwpTabs.d.ts +6 -0
- package/dist/types/components/withRouter/index.d.ts +1 -0
- package/dist/types/components/withRouter/withRouter.d.ts +14 -0
- package/dist/types/components/withRouterAndRef/index.d.ts +1 -0
- package/dist/types/components/withRouterAndRef/withRouterAndRef.d.ts +14 -0
- package/dist/types/context/OwpAppProvider.d.ts +15 -0
- package/dist/types/default-settings/OwpDefaultSettings.d.ts +640 -0
- package/dist/types/hooks/useCommonCodeList.d.ts +11 -0
- package/dist/types/hooks/useConfirm.d.ts +23 -0
- package/dist/types/hooks/useCurrentLanguage.d.ts +13 -0
- package/dist/types/hooks/useCurrentLogoSrc.d.ts +2 -0
- package/dist/types/hooks/useCurrentUserId.d.ts +2 -0
- package/dist/types/hooks/useDebounce.d.ts +7 -0
- package/dist/types/hooks/useDeepCompareEffect.d.ts +17 -0
- package/dist/types/hooks/useNavigation.d.ts +18 -0
- package/dist/types/hooks/usePrevious.d.ts +5 -0
- package/dist/types/hooks/useShortcuts.d.ts +2 -0
- package/dist/types/hooks/useStorage.d.ts +11 -0
- package/dist/types/hooks/useThemeMediaQuery.d.ts +7 -0
- package/dist/types/hooks/useTimeout.d.ts +6 -0
- package/dist/types/index.d.ts +103 -0
- package/dist/types/store/apiService.d.ts +3 -0
- package/dist/types/store/generateReducersFromSlices.d.ts +3 -0
- package/dist/types/store/hooks.d.ts +4 -0
- package/dist/types/store/lazyLoadedSlices.d.ts +6 -0
- package/dist/types/store/middleware.d.ts +14 -0
- package/dist/types/store/store.d.ts +10 -0
- package/dist/types/store/withReducer.d.ts +5 -0
- package/dist/types/store/withSlices.d.ts +11 -0
- package/dist/types/utils/CommonCodeUtils.d.ts +17 -0
- package/dist/types/utils/ErrorBoundary.d.ts +16 -0
- package/dist/types/utils/EventEmitter.d.ts +34 -0
- package/dist/types/utils/OwpNavigationHelper.d.ts +23 -0
- package/dist/types/utils/OwpUtils.d.ts +120 -0
- package/dist/types/utils/excelUtil.d.ts +20 -0
- package/dist/types/utils/treeGridExportExcelUtil.d.ts +6 -0
- package/dist/types/utils/treeGridUtil.d.ts +24 -0
- package/dist/types/utils/zipUtil.d.ts +10 -0
- package/package.json +125 -0
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { IconProps } from '@mui/material';
|
|
2
|
+
interface OwpSectionProps {
|
|
3
|
+
className?: string;
|
|
4
|
+
headerProps?: React.HTMLAttributes<HTMLDivElement>;
|
|
5
|
+
disableTitleIcon?: boolean;
|
|
6
|
+
title?: React.ReactNode;
|
|
7
|
+
actions?: React.ReactNode;
|
|
8
|
+
leftSlot?: React.ReactNode;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
iconSize?: IconProps['fontSize'];
|
|
11
|
+
}
|
|
12
|
+
declare const OwpSection: ({ className, title, disableTitleIcon, headerProps, actions, leftSlot, children, iconSize, }: OwpSectionProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export { OwpSection };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { OwpSettingsConfigType } from '@/components/OwpSettings/OwpSettings';
|
|
2
|
+
import { AnyFormFieldType } from '@/components/OwpSettings/ThemeFormConfigTypes';
|
|
3
|
+
import { Control } from 'react-hook-form';
|
|
4
|
+
type OwpSettingsControllerProps = {
|
|
5
|
+
key?: string;
|
|
6
|
+
name: keyof OwpSettingsConfigType;
|
|
7
|
+
control: Control<OwpSettingsConfigType>;
|
|
8
|
+
title?: string;
|
|
9
|
+
item: AnyFormFieldType;
|
|
10
|
+
};
|
|
11
|
+
declare function OwpLayoutConfig(props: OwpSettingsControllerProps): "" | import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export { OwpLayoutConfig };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Control } from 'react-hook-form';
|
|
2
|
+
import { OwpSettingsConfigType } from './OwpSettings';
|
|
3
|
+
import { ThemeFormConfigTypes } from './ThemeFormConfigTypes';
|
|
4
|
+
type OwpSettingsControllersProps = {
|
|
5
|
+
value: ThemeFormConfigTypes;
|
|
6
|
+
prefix: string;
|
|
7
|
+
control: Control<OwpSettingsConfigType>;
|
|
8
|
+
};
|
|
9
|
+
declare function OwpLayoutConfigs(props: OwpSettingsControllersProps): import("react/jsx-runtime").JSX.Element[];
|
|
10
|
+
export { OwpLayoutConfigs };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { themeLayoutDefaultsProps } from '@/components/layouts/themeLayoutConfigs';
|
|
2
|
+
import { Palette } from '@mui/material/styles/createPalette';
|
|
3
|
+
import { PartialDeep } from 'type-fest';
|
|
4
|
+
export type OwpThemeType = {
|
|
5
|
+
palette: PartialDeep<Palette>;
|
|
6
|
+
};
|
|
7
|
+
export type OwpThemesType = {
|
|
8
|
+
[key: string]: OwpThemeType;
|
|
9
|
+
};
|
|
10
|
+
export type OwpSettingsConfigType = {
|
|
11
|
+
layout: {
|
|
12
|
+
style?: string;
|
|
13
|
+
config?: PartialDeep<themeLayoutDefaultsProps>;
|
|
14
|
+
};
|
|
15
|
+
customScrollbars?: boolean;
|
|
16
|
+
direction: 'rtl' | 'ltr';
|
|
17
|
+
theme: {
|
|
18
|
+
main: OwpThemeType;
|
|
19
|
+
navbar: OwpThemeType;
|
|
20
|
+
toolbar: OwpThemeType;
|
|
21
|
+
footer: OwpThemeType;
|
|
22
|
+
};
|
|
23
|
+
defaultAuth?: string[];
|
|
24
|
+
loginRedirectUrl: string;
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* The OwpSettings component is responsible for rendering the settings form for the Owp React application.
|
|
28
|
+
* It uses the useForm hook from the react-hook-form library to handle form state and validation.
|
|
29
|
+
* It also uses various MUI components to render the form fields and sections.
|
|
30
|
+
* The component is memoized to prevent unnecessary re-renders.
|
|
31
|
+
*/
|
|
32
|
+
declare function OwpSettings(): import("react/jsx-runtime").JSX.Element;
|
|
33
|
+
declare const OwpSettingsMemo: import("react").MemoExoticComponent<typeof OwpSettings>;
|
|
34
|
+
export { OwpSettingsMemo as OwpSettings };
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
type RadioOptionType = {
|
|
2
|
+
name: string;
|
|
3
|
+
value: string;
|
|
4
|
+
};
|
|
5
|
+
type FormFieldBaseType = {
|
|
6
|
+
title: string;
|
|
7
|
+
};
|
|
8
|
+
type RadioFieldType = FormFieldBaseType & {
|
|
9
|
+
type: 'radio';
|
|
10
|
+
options: RadioOptionType[];
|
|
11
|
+
};
|
|
12
|
+
type NumberFieldType = FormFieldBaseType & {
|
|
13
|
+
type: 'number';
|
|
14
|
+
min?: number;
|
|
15
|
+
max?: number;
|
|
16
|
+
};
|
|
17
|
+
type SwitchFieldType = FormFieldBaseType & {
|
|
18
|
+
type: 'switch';
|
|
19
|
+
};
|
|
20
|
+
type GroupFieldChildrenType = {
|
|
21
|
+
[key: string]: RadioFieldType | SwitchFieldType | NumberFieldType | GroupFieldType;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* The GroupFieldType type defines the shape of a group form field.
|
|
25
|
+
* It extends the FormFieldBaseType type and adds a children property which is a GroupFieldChildrenType object.
|
|
26
|
+
*/
|
|
27
|
+
type GroupFieldType = FormFieldBaseType & {
|
|
28
|
+
type: 'group';
|
|
29
|
+
children: GroupFieldChildrenType;
|
|
30
|
+
};
|
|
31
|
+
export type AnyFormFieldType = RadioFieldType | SwitchFieldType | NumberFieldType | GroupFieldType;
|
|
32
|
+
/**
|
|
33
|
+
* The ThemeFormConfigTypes type is an object where the keys are strings and the values are AnyFormFieldType objects.
|
|
34
|
+
* It is used to generate the form fields based on the configuration in the themeLayoutConfigs object.
|
|
35
|
+
*/
|
|
36
|
+
type ThemeFormConfigTypes = {
|
|
37
|
+
[key: string]: AnyFormFieldType;
|
|
38
|
+
};
|
|
39
|
+
export type { ThemeFormConfigTypes };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { OwpSettings } from './OwpSettings';
|