@elliemae/ds-global-header 3.55.0-next.9 → 3.56.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/DSGlobalHeader.js +1 -1
- package/dist/cjs/DSGlobalHeader.js.map +2 -2
- package/dist/cjs/DSGlobalHeaderContext.js.map +2 -2
- package/dist/cjs/config/useGlobalHeader.js +2 -2
- package/dist/cjs/config/useGlobalHeader.js.map +2 -2
- package/dist/cjs/config/useValidateProps.js.map +2 -2
- package/dist/cjs/exported-related/index.js +3 -13
- package/dist/cjs/exported-related/index.js.map +2 -2
- package/dist/cjs/index.js +3 -10
- package/dist/cjs/index.js.map +3 -3
- package/dist/cjs/parts/Breadcrumb/GlobalHeaderBreadcrumb.js +1 -1
- package/dist/cjs/parts/Breadcrumb/GlobalHeaderBreadcrumb.js.map +2 -2
- package/dist/cjs/parts/Breadcrumb/PureBreadcrumb.js +14 -3
- package/dist/cjs/parts/Breadcrumb/PureBreadcrumb.js.map +2 -2
- package/dist/cjs/parts/Breadcrumb/useGlobalHeaderBreadcrumb.js +2 -2
- package/dist/cjs/parts/Breadcrumb/useGlobalHeaderBreadcrumb.js.map +2 -2
- package/dist/cjs/parts/Toolbar/GlobalHeaderToolbar.js +115 -89
- package/dist/cjs/parts/Toolbar/GlobalHeaderToolbar.js.map +3 -3
- package/dist/cjs/parts/Toolbar/outOfTheBox/AppPicker/AppPicker.js +12 -5
- package/dist/cjs/parts/Toolbar/outOfTheBox/AppPicker/AppPicker.js.map +2 -2
- package/dist/cjs/parts/Toolbar/outOfTheBox/PopupMenu/PopupMenu.js +6 -4
- package/dist/cjs/parts/Toolbar/outOfTheBox/PopupMenu/PopupMenu.js.map +2 -2
- package/dist/cjs/parts/Toolbar/outOfTheBox/PopupMenu/menuContent/PopupMenuContent.js +5 -3
- package/dist/cjs/parts/Toolbar/outOfTheBox/PopupMenu/menuContent/PopupMenuContent.js.map +2 -2
- package/dist/cjs/parts/Toolbar/outOfTheBox/SearchToggle/SearchToggle.js +10 -8
- package/dist/cjs/parts/Toolbar/outOfTheBox/SearchToggle/SearchToggle.js.map +2 -2
- package/dist/cjs/react-desc-prop-types.js +23 -28
- package/dist/cjs/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/sharedTypes.js.map +1 -1
- package/dist/cjs/typescript-testing/typescript-global-header-valid.js +11 -21
- package/dist/cjs/typescript-testing/typescript-global-header-valid.js.map +2 -2
- package/dist/esm/DSGlobalHeader.js +2 -2
- package/dist/esm/DSGlobalHeader.js.map +2 -2
- package/dist/esm/DSGlobalHeaderContext.js.map +2 -2
- package/dist/esm/config/useGlobalHeader.js +2 -2
- package/dist/esm/config/useGlobalHeader.js.map +2 -2
- package/dist/esm/config/useValidateProps.js +5 -5
- package/dist/esm/config/useValidateProps.js.map +2 -2
- package/dist/esm/exported-related/index.js +2 -9
- package/dist/esm/exported-related/index.js.map +2 -2
- package/dist/esm/index.js +2 -16
- package/dist/esm/index.js.map +3 -3
- package/dist/esm/parts/Breadcrumb/GlobalHeaderBreadcrumb.js +1 -1
- package/dist/esm/parts/Breadcrumb/GlobalHeaderBreadcrumb.js.map +2 -2
- package/dist/esm/parts/Breadcrumb/PureBreadcrumb.js +14 -3
- package/dist/esm/parts/Breadcrumb/PureBreadcrumb.js.map +2 -2
- package/dist/esm/parts/Breadcrumb/useGlobalHeaderBreadcrumb.js +3 -3
- package/dist/esm/parts/Breadcrumb/useGlobalHeaderBreadcrumb.js.map +2 -2
- package/dist/esm/parts/Toolbar/GlobalHeaderToolbar.js +113 -87
- package/dist/esm/parts/Toolbar/GlobalHeaderToolbar.js.map +3 -3
- package/dist/esm/parts/Toolbar/outOfTheBox/AppPicker/AppPicker.js +12 -5
- package/dist/esm/parts/Toolbar/outOfTheBox/AppPicker/AppPicker.js.map +2 -2
- package/dist/esm/parts/Toolbar/outOfTheBox/PopupMenu/PopupMenu.js +6 -4
- package/dist/esm/parts/Toolbar/outOfTheBox/PopupMenu/PopupMenu.js.map +2 -2
- package/dist/esm/parts/Toolbar/outOfTheBox/PopupMenu/menuContent/PopupMenuContent.js +5 -3
- package/dist/esm/parts/Toolbar/outOfTheBox/PopupMenu/menuContent/PopupMenuContent.js.map +2 -2
- package/dist/esm/parts/Toolbar/outOfTheBox/SearchToggle/SearchToggle.js +8 -6
- package/dist/esm/parts/Toolbar/outOfTheBox/SearchToggle/SearchToggle.js.map +2 -2
- package/dist/esm/react-desc-prop-types.js +23 -28
- package/dist/esm/react-desc-prop-types.js.map +2 -2
- package/dist/esm/typescript-testing/typescript-global-header-valid.js +11 -21
- package/dist/esm/typescript-testing/typescript-global-header-valid.js.map +2 -2
- package/dist/types/DSGlobalHeader.d.ts +1 -1
- package/dist/types/DSGlobalHeaderContext.d.ts +2 -2
- package/dist/types/config/useGlobalHeader.d.ts +3 -2
- package/dist/types/exported-related/index.d.ts +2 -2
- package/dist/types/index.d.ts +4 -4
- package/dist/types/parts/Breadcrumb/PureBreadcrumb.d.ts +2 -6
- package/dist/types/parts/Breadcrumb/useGlobalHeaderBreadcrumb.d.ts +4 -4
- package/dist/types/parts/Toolbar/outOfTheBox/AppPicker/AppPicker.d.ts +2 -6
- package/dist/types/parts/Toolbar/outOfTheBox/PopupMenu/PopupMenu.d.ts +2 -2
- package/dist/types/parts/Toolbar/outOfTheBox/PopupMenu/menuContent/PopupMenuContent.d.ts +2 -2
- package/dist/types/parts/Toolbar/outOfTheBox/SearchToggle/SearchToggle.d.ts +2 -2
- package/dist/types/react-desc-prop-types.d.ts +6 -151
- package/dist/types/sharedTypes.d.ts +133 -47
- package/package.json +11 -11
- package/dist/cjs/typescript-testing/typescript-global-header-breadcrumb-types.js +0 -67
- package/dist/cjs/typescript-testing/typescript-global-header-breadcrumb-types.js.map +0 -7
- package/dist/cjs/typescript-testing/typescript-global-header-deprecated.js +0 -73
- package/dist/cjs/typescript-testing/typescript-global-header-deprecated.js.map +0 -7
- package/dist/cjs/typescript-testing/typescript-global-header-toolbar-types.js +0 -285
- package/dist/cjs/typescript-testing/typescript-global-header-toolbar-types.js.map +0 -7
- package/dist/esm/typescript-testing/typescript-global-header-breadcrumb-types.js +0 -37
- package/dist/esm/typescript-testing/typescript-global-header-breadcrumb-types.js.map +0 -7
- package/dist/esm/typescript-testing/typescript-global-header-deprecated.js +0 -50
- package/dist/esm/typescript-testing/typescript-global-header-deprecated.js.map +0 -7
- package/dist/esm/typescript-testing/typescript-global-header-toolbar-types.js +0 -255
- package/dist/esm/typescript-testing/typescript-global-header-toolbar-types.js.map +0 -7
- package/dist/types/typescript-testing/typescript-global-header-breadcrumb-types.d.ts +0 -3
- package/dist/types/typescript-testing/typescript-global-header-deprecated.d.ts +0 -1
- package/dist/types/typescript-testing/typescript-global-header-toolbar-types.d.ts +0 -3
package/dist/types/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DSGlobalHeader } from './DSGlobalHeader.js';
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export { DSGlobalHeaderDatatestid, DSGlobalHeaderDatatestidFlattened, DSGlobalHeaderName, DSGlobalHeaderSlots, DSGlobalHeaderSlotsFlattened, } from './exported-related/index.js';
|
|
5
|
-
export type { DSGlobalHeaderT } from './react-desc-prop-types.js';
|
|
2
|
+
export * from './DSGlobalHeader.js';
|
|
3
|
+
export * from './exported-related/index.js';
|
|
6
4
|
export type { DSGlobalHeaderInternalsT } from './sharedTypes.js';
|
|
5
|
+
export type { DSGlobalHeaderT } from './react-desc-prop-types.js';
|
|
6
|
+
export default DSGlobalHeader;
|
|
@@ -1,7 +1,3 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
fullBreadcrumbListLength: number;
|
|
5
|
-
};
|
|
6
|
-
export declare const PureBreadcrumb: React.MemoExoticComponent<({ onClick, isSelected, fullBreadcrumbListLength, label, hasNext, ...rest }: PureBreadcrumbProps) => import("react/jsx-runtime.js").JSX.Element>;
|
|
7
|
-
export {};
|
|
2
|
+
import type { DSGlobalHeaderInternalsT } from '../../sharedTypes.js';
|
|
3
|
+
export declare const PureBreadcrumb: React.MemoExoticComponent<({ onClick, onKeyDown, isSelected, length, label, hasNext, id, ...rest }: DSGlobalHeaderInternalsT.BreadcrumbItem) => import("react/jsx-runtime.js").JSX.Element>;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
|
-
import type {
|
|
2
|
+
import type { DSGlobalHeaderInternalsT } from '../../sharedTypes.js';
|
|
3
3
|
interface UseGlobalHeaderBreadcrumbReturnT {
|
|
4
|
-
breadcrumb:
|
|
4
|
+
breadcrumb: DSGlobalHeaderInternalsT.BreadcrumbItem[];
|
|
5
5
|
CustomNavigation: React.ComponentType;
|
|
6
6
|
showIconOnly: boolean;
|
|
7
7
|
flexRegionRef: React.MutableRefObject<HTMLDivElement | null>;
|
|
8
|
-
handleOnKeyDown: (onClick: (event
|
|
8
|
+
handleOnKeyDown: (onClick: (event?: React.MouseEvent) => void) => (event: React.KeyboardEvent) => void;
|
|
9
9
|
instanceUID: string;
|
|
10
10
|
ownerProps: {
|
|
11
|
-
getOwnerProps: () => Partial<
|
|
11
|
+
getOwnerProps: () => Partial<DSGlobalHeaderInternalsT.DefaultProps>;
|
|
12
12
|
getOwnerPropsArguments: () => object;
|
|
13
13
|
};
|
|
14
14
|
}
|
|
@@ -1,6 +1,2 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
setRef: (ref: HTMLElement) => void;
|
|
4
|
-
};
|
|
5
|
-
export declare const AppPicker: ({ label, setRef, componentProps, ...otherProps }: AppPickerOutOfTheBoxProps) => JSX.Element;
|
|
6
|
-
export {};
|
|
1
|
+
import type { DSGlobalHeaderInternalsT } from '../../../../sharedTypes.js';
|
|
2
|
+
export declare const AppPicker: ({ label, id, setRef, componentProps, ...otherProps }: DSGlobalHeaderInternalsT.AppPickerProps) => JSX.Element;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
export declare const PopupMenu: ({ Icon, onClick, setRef, componentProps, ...otherProps }:
|
|
1
|
+
import type { DSGlobalHeaderInternalsT } from '../../../../sharedTypes.js';
|
|
2
|
+
export declare const PopupMenu: ({ Icon, onClick, id, setRef, componentProps, ...otherProps }: DSGlobalHeaderInternalsT.PopupProps) => JSX.Element;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type {
|
|
3
|
-
export declare const PopupMenuContent: React.MemoExoticComponent<({ options, onItemClick, onClose, popupOnKeyPress, setIsOpen, }:
|
|
2
|
+
import type { DSGlobalHeaderInternalsT } from '../../../../../sharedTypes.js';
|
|
3
|
+
export declare const PopupMenuContent: React.MemoExoticComponent<({ options, onItemClick, onClose, popupOnKeyPress, setIsOpen, }: DSGlobalHeaderInternalsT.PopupMenuContentProps) => JSX.Element>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
export declare const SearchToggle: ({ setRef, componentProps, ...otherProps }:
|
|
1
|
+
import type { DSGlobalHeaderInternalsT } from '../../../../sharedTypes.js';
|
|
2
|
+
export declare const SearchToggle: ({ id, setRef, componentProps, ...otherProps }: DSGlobalHeaderInternalsT.SearchToggleProps) => JSX.Element;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
import type React from 'react';
|
|
1
|
+
import type { WeakValidationMap } from 'react';
|
|
2
|
+
import type { DSGlobalHeaderInternalsT } from './sharedTypes.js';
|
|
4
3
|
export declare const defaultProps: {
|
|
5
4
|
breadcrumb: never[];
|
|
6
5
|
toolbar: never[];
|
|
@@ -8,152 +7,8 @@ export declare const defaultProps: {
|
|
|
8
7
|
Logo: () => null;
|
|
9
8
|
};
|
|
10
9
|
export declare namespace DSGlobalHeaderT {
|
|
11
|
-
|
|
12
|
-
hasNext?: boolean;
|
|
13
|
-
isSelected?: boolean;
|
|
14
|
-
onClick?: (event: React.MouseEvent | React.KeyboardEvent) => void;
|
|
15
|
-
}
|
|
16
|
-
interface BreadcrumbItemRequired {
|
|
17
|
-
label: string;
|
|
18
|
-
}
|
|
19
|
-
interface BreadcrumbItemOptionalsGlobals extends Omit<GlobalAttributesT, keyof BreadcrumbItemOptionals | keyof BreadcrumbItemRequired> {
|
|
20
|
-
}
|
|
21
|
-
interface BreadcrumbItem extends BreadcrumbItemRequired, BreadcrumbItemOptionals, BreadcrumbItemOptionalsGlobals {
|
|
22
|
-
}
|
|
23
|
-
interface ToolbarCustomComponentProps {
|
|
24
|
-
item: Record<string, unknown> & {
|
|
25
|
-
type: 'custom';
|
|
26
|
-
CustomComponent: React.ComponentType<ToolbarCustomComponentProps>;
|
|
27
|
-
};
|
|
28
|
-
setRef: (ref: HTMLElement | null) => void;
|
|
29
|
-
}
|
|
30
|
-
interface ToolbarCustomItem extends Record<string, unknown> {
|
|
31
|
-
type: 'custom';
|
|
32
|
-
label: string;
|
|
33
|
-
CustomComponent: React.ComponentType<ToolbarCustomComponentProps>;
|
|
34
|
-
}
|
|
35
|
-
interface ToggleSearchComponentProps {
|
|
36
|
-
onNext: () => void;
|
|
37
|
-
onPrevious: () => void;
|
|
38
|
-
currentResultIndex: number;
|
|
39
|
-
totalResults: number;
|
|
40
|
-
placeholder: string;
|
|
41
|
-
value: string;
|
|
42
|
-
onChange: () => void;
|
|
43
|
-
onBlur: () => void;
|
|
44
|
-
onClear: () => void;
|
|
45
|
-
isOpen: boolean;
|
|
46
|
-
onKeyDown: (event: React.KeyboardEvent) => void;
|
|
47
|
-
onClick: (event: React.MouseEvent) => void;
|
|
48
|
-
triggerRef: React.MutableRefObject<HTMLButtonElement>;
|
|
49
|
-
searchContainerRef: React.MutableRefObject<HTMLDivElement>;
|
|
50
|
-
}
|
|
51
|
-
interface SearchToggleProps extends GlobalAttributesT {
|
|
52
|
-
setRef: (ref: HTMLElement) => void;
|
|
53
|
-
componentProps: ToggleSearchComponentProps;
|
|
54
|
-
}
|
|
55
|
-
interface ToolbarSearchToggleItem {
|
|
56
|
-
type: 'ds-search-toggle';
|
|
57
|
-
label: string;
|
|
58
|
-
componentProps: ToggleSearchComponentProps;
|
|
59
|
-
}
|
|
60
|
-
interface PopupMenuContentItem extends Omit<GlobalAttributesT, 'type' | 'label' | 'onClick'> {
|
|
61
|
-
type?: 'separator' | 'custom';
|
|
62
|
-
Icon?: React.ComponentType<{
|
|
63
|
-
fill?: string;
|
|
64
|
-
size?: string;
|
|
65
|
-
}>;
|
|
66
|
-
label?: string;
|
|
67
|
-
onClick?: (event: React.MouseEvent) => void;
|
|
68
|
-
closeOnClick?: boolean;
|
|
69
|
-
Content?: React.ComponentType;
|
|
70
|
-
}
|
|
71
|
-
interface PopupMenuComponentProps {
|
|
72
|
-
onClickOutside?: (e: MouseEvent | TouchEvent) => void;
|
|
73
|
-
onKeyPress: (event: React.KeyboardEvent) => void;
|
|
74
|
-
popupOnKeyPress: (event: React.KeyboardEvent) => void;
|
|
75
|
-
isOpen: boolean;
|
|
76
|
-
options: PopupMenuContentItem[];
|
|
77
|
-
closeOnClick: boolean;
|
|
78
|
-
}
|
|
79
|
-
interface PopupMenuItem extends Omit<GlobalAttributesT, 'type' | 'label' | 'onClick'> {
|
|
80
|
-
type: 'ds-popup-menu';
|
|
81
|
-
Icon?: React.ComponentType<{
|
|
82
|
-
fill?: string;
|
|
83
|
-
size?: string;
|
|
84
|
-
}>;
|
|
85
|
-
label?: string;
|
|
86
|
-
onClick?: (event: React.MouseEvent) => void;
|
|
87
|
-
Content?: React.ComponentType;
|
|
88
|
-
componentProps: PopupMenuComponentProps;
|
|
89
|
-
}
|
|
90
|
-
interface PopupMenuContentProps {
|
|
91
|
-
options: PopupMenuContentItem[];
|
|
92
|
-
onItemClick: () => void;
|
|
93
|
-
onClose: () => void;
|
|
94
|
-
popupOnKeyPress: (event: React.KeyboardEvent) => void;
|
|
95
|
-
setIsOpen: React.Dispatch<React.SetStateAction<boolean>>;
|
|
96
|
-
}
|
|
97
|
-
interface PopupProps extends Omit<GlobalAttributesT, 'title' | 'label' | 'onClick'> {
|
|
98
|
-
Icon?: React.ComponentType<{
|
|
99
|
-
fill?: string;
|
|
100
|
-
size?: string;
|
|
101
|
-
}>;
|
|
102
|
-
onClick?: (event: React.MouseEvent) => void;
|
|
103
|
-
setRef: (ref: HTMLElement) => void;
|
|
104
|
-
componentProps: PopupMenuComponentProps;
|
|
105
|
-
title?: string;
|
|
106
|
-
}
|
|
107
|
-
type AppPickerComponentProps = React.ComponentProps<typeof DSAppPicker> & {
|
|
108
|
-
triggerOnClick?: React.MouseEventHandler<HTMLButtonElement>;
|
|
109
|
-
};
|
|
110
|
-
interface AppPickerProps extends Omit<GlobalAttributesT, 'label'> {
|
|
111
|
-
label: string;
|
|
112
|
-
componentProps: AppPickerComponentProps;
|
|
113
|
-
}
|
|
114
|
-
interface ToolbarAppPickerItem extends Omit<GlobalAttributesT, 'type' | 'label'> {
|
|
115
|
-
type: 'ds-app-picker';
|
|
116
|
-
label: string;
|
|
117
|
-
componentProps: AppPickerComponentProps;
|
|
118
|
-
}
|
|
119
|
-
interface ToolbarItemTypelessDefault extends Omit<GlobalAttributesT, 'label'> {
|
|
120
|
-
type?: undefined;
|
|
121
|
-
label: string;
|
|
122
|
-
Icon: React.ComponentType<{
|
|
123
|
-
fill?: string;
|
|
124
|
-
size?: string;
|
|
125
|
-
}>;
|
|
126
|
-
}
|
|
127
|
-
type ToolbarItem = ToolbarCustomItem | ToolbarSearchToggleItem | ToolbarAppPickerItem | PopupMenuItem | ToolbarItemTypelessDefault;
|
|
128
|
-
interface DefaultProps {
|
|
129
|
-
Logo: React.ComponentType;
|
|
130
|
-
LogoWithBrand: React.ComponentType;
|
|
131
|
-
breadcrumb: DSGlobalHeaderT.BreadcrumbItem[];
|
|
132
|
-
toolbar: DSGlobalHeaderT.ToolbarItem[];
|
|
133
|
-
CustomNavigation: React.ComponentType;
|
|
134
|
-
}
|
|
135
|
-
interface InternalProps extends DefaultProps, Omit<GlobalAttributesT, keyof DefaultProps>, XstyledProps {
|
|
136
|
-
}
|
|
137
|
-
type Props = Partial<DSGlobalHeaderT.DefaultProps>;
|
|
138
|
-
interface Context {
|
|
139
|
-
showIconOnly: boolean;
|
|
140
|
-
fontDetector: number;
|
|
141
|
-
setShowIconOnly: React.Dispatch<React.SetStateAction<boolean>>;
|
|
142
|
-
instanceUID: string;
|
|
143
|
-
globalHeaderToolbarGrid: string[];
|
|
144
|
-
props: InternalProps;
|
|
145
|
-
ownerProps: {
|
|
146
|
-
getOwnerProps: () => Partial<DSGlobalHeaderT.DefaultProps>;
|
|
147
|
-
getOwnerPropsArguments: () => object;
|
|
148
|
-
};
|
|
149
|
-
}
|
|
10
|
+
type Props = Partial<DSGlobalHeaderInternalsT.DefaultProps>;
|
|
150
11
|
}
|
|
151
|
-
export declare const
|
|
152
|
-
export declare const
|
|
153
|
-
|
|
154
|
-
LogoWithBrand?: import("@elliemae/ds-props-helpers/dist/types/propTypes/types").ReactDescT | undefined;
|
|
155
|
-
breadcrumb?: import("@elliemae/ds-props-helpers/dist/types/propTypes/types").ReactDescT | undefined;
|
|
156
|
-
toolbar?: import("@elliemae/ds-props-helpers/dist/types/propTypes/types").ReactDescT | undefined;
|
|
157
|
-
CustomNavigation?: import("@elliemae/ds-props-helpers/dist/types/propTypes/types").ReactDescT | undefined;
|
|
158
|
-
}>;
|
|
159
|
-
export declare const DSGlobalHeaderPropTypesSchema: ValidationMap<DSGlobalHeaderT.Props>;
|
|
12
|
+
export declare const breadcrumbItem: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").ReactDescT;
|
|
13
|
+
export declare const toolbarItem: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").ReactDescT;
|
|
14
|
+
export declare const propTypes: WeakValidationMap<DSGlobalHeaderInternalsT.InternalProps>;
|
|
@@ -1,50 +1,136 @@
|
|
|
1
|
-
import type
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
*/
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import type { DSAppPicker } from '@elliemae/ds-app-picker';
|
|
3
|
+
import type { XstyledProps, GlobalAttributesT } from '@elliemae/ds-props-helpers';
|
|
5
4
|
export declare namespace DSGlobalHeaderInternalsT {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
5
|
+
interface DefaultProps {
|
|
6
|
+
Logo: React.ComponentType;
|
|
7
|
+
LogoWithBrand: React.ComponentType;
|
|
8
|
+
breadcrumb: DSGlobalHeaderInternalsT.BreadcrumbItem[];
|
|
9
|
+
toolbar: DSGlobalHeaderInternalsT.ToolbarItem[];
|
|
10
|
+
CustomNavigation: React.ComponentType;
|
|
11
|
+
}
|
|
12
|
+
interface InternalProps extends DefaultProps, Omit<GlobalAttributesT, keyof DefaultProps>, XstyledProps {
|
|
13
|
+
}
|
|
14
|
+
interface BreadcrumbItem {
|
|
15
|
+
label: string;
|
|
16
|
+
id?: string;
|
|
17
|
+
hasNext?: boolean;
|
|
18
|
+
isSelected?: boolean;
|
|
19
|
+
onClick?: (event?: React.MouseEvent) => void;
|
|
20
|
+
onKeyDown?: (event: React.KeyboardEvent) => void;
|
|
21
|
+
length: number;
|
|
22
|
+
role?: string;
|
|
23
|
+
}
|
|
24
|
+
interface ToolbarCustomComponentProps {
|
|
25
|
+
item: ToolbarItem;
|
|
26
|
+
role?: string;
|
|
27
|
+
setRef: (ref: HTMLElement | null) => void;
|
|
28
|
+
}
|
|
29
|
+
interface ToolbarItem {
|
|
30
|
+
type?: 'ds-app-picker' | 'ds-popup-menu' | 'ds-search-toggle' | 'custom';
|
|
31
|
+
onKeyPress?: (event: React.KeyboardEvent) => void;
|
|
32
|
+
onClick?: (event: React.MouseEvent) => void;
|
|
33
|
+
id?: string;
|
|
34
|
+
label: string;
|
|
35
|
+
Icon?: React.ComponentType<{
|
|
36
|
+
fill?: string;
|
|
37
|
+
size?: string;
|
|
38
|
+
}>;
|
|
39
|
+
componentProps?: PopupMenuComponentProps | ToggleSearchComponentProps | AppPickerComponentProps;
|
|
40
|
+
CustomComponent?: React.ComponentType<ToolbarCustomComponentProps>;
|
|
41
|
+
[key: string]: unknown;
|
|
42
|
+
}
|
|
43
|
+
interface PopupMenuItem {
|
|
44
|
+
type?: string;
|
|
45
|
+
Icon?: React.ComponentType<{
|
|
46
|
+
fill?: string;
|
|
47
|
+
size?: string;
|
|
48
|
+
}>;
|
|
49
|
+
label?: string;
|
|
50
|
+
onClick?: (event: React.MouseEvent) => void;
|
|
51
|
+
Content?: React.ComponentType;
|
|
52
|
+
id?: string;
|
|
53
|
+
}
|
|
54
|
+
interface ToggleSearchComponentProps {
|
|
55
|
+
onNext: () => void;
|
|
56
|
+
onPrevious: () => void;
|
|
57
|
+
currentResultIndex: number;
|
|
58
|
+
totalResults: number;
|
|
59
|
+
placeholder: string;
|
|
60
|
+
value: string;
|
|
61
|
+
onChange: () => void;
|
|
62
|
+
onBlur: () => void;
|
|
63
|
+
onClear: () => void;
|
|
64
|
+
isOpen: boolean;
|
|
65
|
+
onKeyDown: (event: React.KeyboardEvent) => void;
|
|
66
|
+
onClick: (event: React.MouseEvent) => void;
|
|
67
|
+
triggerRef: React.MutableRefObject<HTMLButtonElement>;
|
|
68
|
+
searchContainerRef: React.MutableRefObject<HTMLDivElement>;
|
|
69
|
+
}
|
|
70
|
+
type AppPickerComponentProps = React.ComponentProps<typeof DSAppPicker> & {
|
|
71
|
+
triggerOnClick?: React.MouseEventHandler<HTMLButtonElement>;
|
|
72
|
+
};
|
|
73
|
+
interface PopupMenuComponentProps {
|
|
74
|
+
onClickOutside?: (e: MouseEvent | TouchEvent) => void;
|
|
75
|
+
onKeyPress: (event: React.KeyboardEvent) => void;
|
|
76
|
+
popupOnKeyPress: (event: React.KeyboardEvent) => void;
|
|
77
|
+
isOpen: boolean;
|
|
78
|
+
options: PopupMenuContentItem[];
|
|
79
|
+
closeOnClick: boolean;
|
|
80
|
+
}
|
|
81
|
+
interface SearchToggleProps {
|
|
82
|
+
id: string;
|
|
83
|
+
setRef: (ref: HTMLElement) => void;
|
|
84
|
+
componentProps: ToggleSearchComponentProps;
|
|
85
|
+
}
|
|
86
|
+
interface AppPickerProps {
|
|
87
|
+
label: string;
|
|
88
|
+
id: string;
|
|
89
|
+
setRef: (ref: HTMLElement) => void;
|
|
90
|
+
componentProps: AppPickerComponentProps;
|
|
91
|
+
}
|
|
92
|
+
interface PopupMenuContentItem extends Record<string, unknown> {
|
|
93
|
+
type?: string;
|
|
94
|
+
Icon?: React.ComponentType<{
|
|
95
|
+
fill?: string;
|
|
96
|
+
size?: string;
|
|
97
|
+
}>;
|
|
98
|
+
label?: string;
|
|
99
|
+
onClick?: (event: React.MouseEvent) => void;
|
|
100
|
+
closeOnClick?: boolean;
|
|
101
|
+
Content?: React.ComponentType;
|
|
102
|
+
}
|
|
103
|
+
interface PopupMenuContentProps {
|
|
104
|
+
options: PopupMenuItem[];
|
|
105
|
+
onItemClick: () => void;
|
|
106
|
+
onClose: () => void;
|
|
107
|
+
popupOnKeyPress: (event: React.KeyboardEvent) => void;
|
|
108
|
+
setIsOpen: React.Dispatch<React.SetStateAction<boolean>>;
|
|
109
|
+
}
|
|
110
|
+
interface PopupProps {
|
|
111
|
+
Icon?: React.ComponentType<{
|
|
112
|
+
fill?: string;
|
|
113
|
+
size?: string;
|
|
114
|
+
}>;
|
|
115
|
+
id?: string;
|
|
116
|
+
closeOnClick?: boolean;
|
|
117
|
+
onKeyPress?: (event: React.KeyboardEvent) => void;
|
|
118
|
+
title?: string;
|
|
119
|
+
options?: PopupMenuContentItem[];
|
|
120
|
+
onClick?: (event: React.MouseEvent) => void;
|
|
121
|
+
componentProps: PopupMenuComponentProps;
|
|
122
|
+
setRef: (ref: HTMLElement) => void;
|
|
123
|
+
}
|
|
124
|
+
interface Context {
|
|
125
|
+
showIconOnly: boolean;
|
|
126
|
+
fontDetector: number;
|
|
127
|
+
setShowIconOnly: React.Dispatch<React.SetStateAction<boolean>>;
|
|
128
|
+
instanceUID: string;
|
|
129
|
+
globalHeaderToolbarGrid: string[];
|
|
130
|
+
props: InternalProps;
|
|
131
|
+
ownerProps: {
|
|
132
|
+
getOwnerProps: () => Partial<DSGlobalHeaderInternalsT.DefaultProps>;
|
|
133
|
+
getOwnerPropsArguments: () => object;
|
|
134
|
+
};
|
|
49
135
|
}
|
|
50
136
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-global-header",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.56.0-rc.1",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Global Header",
|
|
6
6
|
"files": [
|
|
@@ -37,21 +37,21 @@
|
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"uid": "~2.0.1",
|
|
40
|
-
"@elliemae/ds-app-picker": "3.
|
|
41
|
-
"@elliemae/ds-
|
|
42
|
-
"@elliemae/ds-
|
|
43
|
-
"@elliemae/ds-
|
|
44
|
-
"@elliemae/ds-
|
|
45
|
-
"@elliemae/ds-
|
|
46
|
-
"@elliemae/ds-props-helpers": "3.
|
|
47
|
-
"@elliemae/ds-
|
|
40
|
+
"@elliemae/ds-app-picker": "3.56.0-rc.1",
|
|
41
|
+
"@elliemae/ds-form": "3.56.0-rc.1",
|
|
42
|
+
"@elliemae/ds-hooks-fontsize-media": "3.56.0-rc.1",
|
|
43
|
+
"@elliemae/ds-grid": "3.56.0-rc.1",
|
|
44
|
+
"@elliemae/ds-popperjs": "3.56.0-rc.1",
|
|
45
|
+
"@elliemae/ds-icons": "3.56.0-rc.1",
|
|
46
|
+
"@elliemae/ds-props-helpers": "3.56.0-rc.1",
|
|
47
|
+
"@elliemae/ds-system": "3.56.0-rc.1"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"@elliemae/pui-cli": "9.0.0-next.65",
|
|
51
51
|
"jest": "~29.7.0",
|
|
52
52
|
"styled-components": "~5.3.9",
|
|
53
|
-
"@elliemae/ds-
|
|
54
|
-
"@elliemae/ds-
|
|
53
|
+
"@elliemae/ds-test-utils": "3.56.0-rc.1",
|
|
54
|
+
"@elliemae/ds-monorepo-devops": "3.56.0-rc.1"
|
|
55
55
|
},
|
|
56
56
|
"peerDependencies": {
|
|
57
57
|
"lodash-es": "^4.17.21",
|
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var typescript_global_header_breadcrumb_types_exports = {};
|
|
30
|
-
__export(typescript_global_header_breadcrumb_types_exports, {
|
|
31
|
-
breadcrumbItems: () => breadcrumbItems,
|
|
32
|
-
breadcrumbItemsAsSyntax: () => breadcrumbItemsAsSyntax
|
|
33
|
-
});
|
|
34
|
-
module.exports = __toCommonJS(typescript_global_header_breadcrumb_types_exports);
|
|
35
|
-
var React = __toESM(require("react"));
|
|
36
|
-
const breadcrumbItemOptionals = {
|
|
37
|
-
hasNext: false,
|
|
38
|
-
isSelected: false,
|
|
39
|
-
onClick: () => {
|
|
40
|
-
}
|
|
41
|
-
};
|
|
42
|
-
const breadcrumbItemRequired = {
|
|
43
|
-
label: "an example label"
|
|
44
|
-
};
|
|
45
|
-
const breadcrumbItemFull = {
|
|
46
|
-
...breadcrumbItemRequired,
|
|
47
|
-
...breadcrumbItemOptionals
|
|
48
|
-
};
|
|
49
|
-
const breadcrumbItems = [
|
|
50
|
-
breadcrumbItemFull,
|
|
51
|
-
breadcrumbItemFull,
|
|
52
|
-
breadcrumbItemFull
|
|
53
|
-
];
|
|
54
|
-
const breadcrumbItemsAsSyntax = [
|
|
55
|
-
{
|
|
56
|
-
label: "pipeline",
|
|
57
|
-
hasNext: true
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
label: "loan",
|
|
61
|
-
hasNext: true
|
|
62
|
-
},
|
|
63
|
-
{
|
|
64
|
-
label: "task"
|
|
65
|
-
}
|
|
66
|
-
];
|
|
67
|
-
//# sourceMappingURL=typescript-global-header-breadcrumb-types.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/typescript-testing/typescript-global-header-breadcrumb-types.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["/* eslint-disable @typescript-eslint/no-unused-vars, no-unused-vars */\nimport type { DSGlobalHeaderT } from '../index.js';\n\n/* *************************************************************************************\n TESTING INTERFACE FOR THE OUT OF THE BOX BREADCRUMB WIDGET\n************************************************************************************** */\nconst breadcrumbItemOptionals: Required<DSGlobalHeaderT.BreadcrumbItemOptionals> = {\n hasNext: false,\n isSelected: false,\n onClick: () => {},\n};\nconst breadcrumbItemRequired: Required<DSGlobalHeaderT.BreadcrumbItemRequired> = {\n label: 'an example label',\n};\nconst breadcrumbItemFull: DSGlobalHeaderT.BreadcrumbItem = {\n ...breadcrumbItemRequired,\n ...breadcrumbItemOptionals,\n};\n\nexport const breadcrumbItems: DSGlobalHeaderT.BreadcrumbItem[] = [\n breadcrumbItemFull,\n breadcrumbItemFull,\n breadcrumbItemFull,\n];\nexport const breadcrumbItemsAsSyntax = [\n {\n label: 'pipeline',\n hasNext: true,\n },\n {\n label: 'loan',\n hasNext: true,\n },\n {\n label: 'task',\n },\n] as DSGlobalHeaderT.BreadcrumbItem[];\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADMvB,MAAM,0BAA6E;AAAA,EACjF,SAAS;AAAA,EACT,YAAY;AAAA,EACZ,SAAS,MAAM;AAAA,EAAC;AAClB;AACA,MAAM,yBAA2E;AAAA,EAC/E,OAAO;AACT;AACA,MAAM,qBAAqD;AAAA,EACzD,GAAG;AAAA,EACH,GAAG;AACL;AAEO,MAAM,kBAAoD;AAAA,EAC/D;AAAA,EACA;AAAA,EACA;AACF;AACO,MAAM,0BAA0B;AAAA,EACrC;AAAA,IACE,OAAO;AAAA,IACP,SAAS;AAAA,EACX;AAAA,EACA;AAAA,IACE,OAAO;AAAA,IACP,SAAS;AAAA,EACX;AAAA,EACA;AAAA,IACE,OAAO;AAAA,EACT;AACF;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __copyProps = (to, from, except, desc) => {
|
|
9
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
10
|
-
for (let key of __getOwnPropNames(from))
|
|
11
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
12
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
13
|
-
}
|
|
14
|
-
return to;
|
|
15
|
-
};
|
|
16
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
17
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
18
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
19
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
20
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
21
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
-
mod
|
|
23
|
-
));
|
|
24
|
-
var React = __toESM(require("react"));
|
|
25
|
-
var import_jsx_runtime = require("react/jsx-runtime");
|
|
26
|
-
var import__ = require("../index.js");
|
|
27
|
-
const testPartialDefaults = {
|
|
28
|
-
breadcrumb: [],
|
|
29
|
-
toolbar: [],
|
|
30
|
-
LogoWithBrand: () => null,
|
|
31
|
-
Logo: () => null
|
|
32
|
-
};
|
|
33
|
-
const testPropsAsSyntax = {
|
|
34
|
-
...testPartialDefaults
|
|
35
|
-
};
|
|
36
|
-
const testCompleteDefaults = {
|
|
37
|
-
breadcrumb: [],
|
|
38
|
-
toolbar: [],
|
|
39
|
-
LogoWithBrand: () => null,
|
|
40
|
-
Logo: () => null,
|
|
41
|
-
CustomNavigation: () => null
|
|
42
|
-
};
|
|
43
|
-
const testInternalProps = {
|
|
44
|
-
...testCompleteDefaults
|
|
45
|
-
};
|
|
46
|
-
const testInternalPropsAsSyntax = {
|
|
47
|
-
...testCompleteDefaults
|
|
48
|
-
};
|
|
49
|
-
const testExplicitDefinition = {
|
|
50
|
-
breadcrumb: [],
|
|
51
|
-
toolbar: [],
|
|
52
|
-
LogoWithBrand: () => null,
|
|
53
|
-
Logo: () => null
|
|
54
|
-
};
|
|
55
|
-
const testInferedTypeCompatibility = {
|
|
56
|
-
breadcrumb: [],
|
|
57
|
-
toolbar: [],
|
|
58
|
-
LogoWithBrand: () => null,
|
|
59
|
-
Logo: () => null
|
|
60
|
-
};
|
|
61
|
-
const testDefinitionAsConst = {
|
|
62
|
-
breadcrumb: [],
|
|
63
|
-
toolbar: [],
|
|
64
|
-
LogoWithBrand: () => null,
|
|
65
|
-
Logo: () => null
|
|
66
|
-
};
|
|
67
|
-
const ExampleUsageComponent = () => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
|
|
68
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import__.DSGlobalHeader, { ...testExplicitDefinition }),
|
|
69
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import__.DSGlobalHeader, { ...testInferedTypeCompatibility }),
|
|
70
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import__.DSGlobalHeader, { ...testDefinitionAsConst }),
|
|
71
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import__.DSGlobalHeader, { breadcrumb: [], toolbar: [], LogoWithBrand: () => null, Logo: () => null })
|
|
72
|
-
] });
|
|
73
|
-
//# sourceMappingURL=typescript-global-header-deprecated.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/typescript-testing/typescript-global-header-deprecated.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-unused-vars, no-unused-vars */\nimport type { DSGlobalHeaderInternalsT, DSGlobalHeaderT } from '../index.js';\nimport { DSGlobalHeader } from '../index.js';\n\n/* ******************************************************************************\n KEPT AROUND FOR BACKWARD COMPATIBILITY, THIS IS LEGACY!\n*********************************************************************************\nthis should be code-modded away in code-bases in favour of the actual namespace.\n******************************************************************************* */\ntype ComponentPropsForApp = DSGlobalHeaderT.Props;\ntype ComponentPropsInternals = DSGlobalHeaderInternalsT.InternalProps;\ntype ComponentPropsDefaultProps = DSGlobalHeaderInternalsT.DefaultProps;\nconst testPartialDefaults: Partial<ComponentPropsDefaultProps> = {\n breadcrumb: [],\n toolbar: [],\n LogoWithBrand: () => null,\n Logo: () => null,\n};\nconst testPropsAsSyntax = {\n ...testPartialDefaults,\n} as ComponentPropsForApp;\nconst testCompleteDefaults: Required<ComponentPropsDefaultProps> = {\n breadcrumb: [],\n toolbar: [],\n LogoWithBrand: () => null,\n Logo: () => null,\n CustomNavigation: () => null,\n};\nconst testInternalProps: ComponentPropsInternals = {\n ...testCompleteDefaults,\n};\nconst testInternalPropsAsSyntax = {\n ...testCompleteDefaults,\n} as ComponentPropsInternals;\nconst testExplicitDefinition: ComponentPropsForApp = {\n breadcrumb: [],\n toolbar: [],\n LogoWithBrand: () => null,\n Logo: () => null,\n};\nconst testInferedTypeCompatibility = {\n breadcrumb: [],\n toolbar: [],\n LogoWithBrand: () => null,\n Logo: () => null,\n} as ComponentPropsForApp;\nconst testDefinitionAsConst = {\n breadcrumb: [] as DSGlobalHeaderInternalsT.BreadcrumbItem[],\n toolbar: [] as DSGlobalHeaderInternalsT.ToolbarItem[],\n LogoWithBrand: () => null,\n Logo: () => null,\n} as const;\nconst ExampleUsageComponent = () => (\n <>\n {/* works with explicitly casted props, all syntaxes */}\n <DSGlobalHeader {...testExplicitDefinition} />\n <DSGlobalHeader {...testInferedTypeCompatibility} />\n <DSGlobalHeader {...testDefinitionAsConst} />\n {/* works with inline values */}\n <DSGlobalHeader breadcrumb={[]} toolbar={[]} LogoWithBrand={() => null} Logo={() => null} />\n </>\n);\n/* ******************************************************************************\n KEPT AROUND FOR BACKWARD COMPATIBILITY, THIS IS LEGACY!\n*********************************************************************************\nthis should be code-modded away in code-bases in favour of the actual namespace.\n******************************************************************************* */\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;AAAA,YAAuB;ACqDrB;AAnDF,eAA+B;AAU/B,MAAM,sBAA2D;AAAA,EAC/D,YAAY,CAAC;AAAA,EACb,SAAS,CAAC;AAAA,EACV,eAAe,MAAM;AAAA,EACrB,MAAM,MAAM;AACd;AACA,MAAM,oBAAoB;AAAA,EACxB,GAAG;AACL;AACA,MAAM,uBAA6D;AAAA,EACjE,YAAY,CAAC;AAAA,EACb,SAAS,CAAC;AAAA,EACV,eAAe,MAAM;AAAA,EACrB,MAAM,MAAM;AAAA,EACZ,kBAAkB,MAAM;AAC1B;AACA,MAAM,oBAA6C;AAAA,EACjD,GAAG;AACL;AACA,MAAM,4BAA4B;AAAA,EAChC,GAAG;AACL;AACA,MAAM,yBAA+C;AAAA,EACnD,YAAY,CAAC;AAAA,EACb,SAAS,CAAC;AAAA,EACV,eAAe,MAAM;AAAA,EACrB,MAAM,MAAM;AACd;AACA,MAAM,+BAA+B;AAAA,EACnC,YAAY,CAAC;AAAA,EACb,SAAS,CAAC;AAAA,EACV,eAAe,MAAM;AAAA,EACrB,MAAM,MAAM;AACd;AACA,MAAM,wBAAwB;AAAA,EAC5B,YAAY,CAAC;AAAA,EACb,SAAS,CAAC;AAAA,EACV,eAAe,MAAM;AAAA,EACrB,MAAM,MAAM;AACd;AACA,MAAM,wBAAwB,MAC5B,4EAEE;AAAA,8CAAC,2BAAgB,GAAG,wBAAwB;AAAA,EAC5C,4CAAC,2BAAgB,GAAG,8BAA8B;AAAA,EAClD,4CAAC,2BAAgB,GAAG,uBAAuB;AAAA,EAE3C,4CAAC,2BAAe,YAAY,CAAC,GAAG,SAAS,CAAC,GAAG,eAAe,MAAM,MAAM,MAAM,MAAM,MAAM;AAAA,GAC5F;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|