@zealicsolutions/web-ui 1.0.141-beta.3 → 1.0.141-beta.5
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/containers/hooks/useStateModifierHandler.d.ts +8 -4
- package/dist/cjs/helpers/useDataResolution.d.ts +10 -20
- package/dist/cjs/index.js +87 -87
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/molecules/Button/types.d.ts +7 -0
- package/dist/esm/containers/hooks/useStateModifierHandler.d.ts +8 -4
- package/dist/esm/containers/hooks/useStateModifierHandler.js +1 -1
- package/dist/esm/containers/hooks/useStateModifierHandler.js.map +1 -1
- package/dist/esm/helpers/useDataResolution.d.ts +10 -20
- package/dist/esm/helpers/useDataResolution.js +1 -1
- package/dist/esm/helpers/useDataResolution.js.map +1 -1
- package/dist/esm/molecules/Button/Button.js +1 -1
- package/dist/esm/molecules/Button/Button.js.map +1 -1
- package/dist/esm/molecules/Button/hooks/useButtonAction.js +1 -1
- package/dist/esm/molecules/Button/hooks/useButtonAction.js.map +1 -1
- package/dist/esm/molecules/Button/types.d.ts +7 -0
- package/dist/esm/molecules/Consent/ConsentMolecule.js +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import { ActionType } from 'containers';
|
|
2
|
+
type StateChangePayload = {
|
|
3
|
+
id?: string;
|
|
4
|
+
type?: ActionType;
|
|
5
|
+
statePatch?: Record<string, unknown>;
|
|
6
|
+
globalPatch?: Record<string, unknown>;
|
|
7
|
+
};
|
|
2
8
|
export declare const useStateModifierHandler: () => {
|
|
3
|
-
onStateChange: ({ id, type }:
|
|
4
|
-
id?: string | undefined;
|
|
5
|
-
type: ActionType;
|
|
6
|
-
}) => void;
|
|
9
|
+
onStateChange: ({ id, type, statePatch, globalPatch }: StateChangePayload) => void;
|
|
7
10
|
};
|
|
11
|
+
export {};
|
|
@@ -1,23 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Data Resolution Priority Order
|
|
3
|
-
* 1. Container scope (current row data for replicators)
|
|
4
|
-
* 2. Webpage query chains (pre-fetched data from Brand App)
|
|
5
|
-
* 3. State Object (persistent webpage context)
|
|
6
|
-
* 4. Form values (current form state)
|
|
7
|
-
*/
|
|
8
|
-
/**
|
|
9
|
-
* Hook to resolve a data value using prioritized data sources
|
|
10
|
-
*
|
|
11
|
-
* Resolves values in this priority order:
|
|
12
|
-
* 1. Container scope (current row data for replicators)
|
|
13
|
-
* 2. Webpage query chains (pre-fetched data from Brand App)
|
|
14
|
-
* 3. State Object (persistent webpage context)
|
|
15
|
-
* 4. Form values (current form state)
|
|
16
|
-
*
|
|
17
|
-
* @param reference - The reference to resolve (e.g., "fieldId" or "{source:fieldId}")
|
|
18
|
-
* @param containerContext - Optional container context for row data
|
|
19
|
-
* @returns The resolved value or undefined
|
|
20
|
-
*/
|
|
21
1
|
export declare function useResolveValue(reference: string, containerContext?: {
|
|
22
2
|
rowData?: Record<string, unknown>;
|
|
23
3
|
rowIndex?: number;
|
|
@@ -32,6 +12,16 @@ export declare function useResolveValue(reference: string, containerContext?: {
|
|
|
32
12
|
* @returns The resolved value
|
|
33
13
|
*/
|
|
34
14
|
export declare function useResolveData(fieldId: string): unknown;
|
|
15
|
+
/**
|
|
16
|
+
* Hook that returns a resolver function for multiple field IDs.
|
|
17
|
+
* Uses the same data-resolution priority as useResolveData.
|
|
18
|
+
*/
|
|
19
|
+
export declare function useResolveDataResolver(): (reference: string) => unknown;
|
|
20
|
+
/**
|
|
21
|
+
* Hook that returns a resolver function for multiple field IDs without unwrapping.
|
|
22
|
+
* Uses raw container data when available to preserve full data layer structures.
|
|
23
|
+
*/
|
|
24
|
+
export declare function useResolveDataResolverRaw(): (reference: string) => unknown;
|
|
35
25
|
/**
|
|
36
26
|
* Hook for resolving data values using prioritized sources
|
|
37
27
|
*
|