@syntrologie/runtime-sdk 2.8.0-canary.71 → 2.8.0-canary.73
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/{chunk-WX32GVSP.js → chunk-P3GRWZXE.js} +81 -21
- package/dist/chunk-P3GRWZXE.js.map +7 -0
- package/dist/fetchers/mergeConfigs.d.ts +7 -7
- package/dist/index.js +1 -1
- package/dist/react.js +1 -1
- package/dist/smart-canvas.esm.js +27 -27
- package/dist/smart-canvas.esm.js.map +3 -3
- package/dist/smart-canvas.js +79 -20
- package/dist/smart-canvas.js.map +2 -2
- package/dist/smart-canvas.min.js +25 -25
- package/dist/smart-canvas.min.js.map +3 -3
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
- package/dist/chunk-WX32GVSP.js.map +0 -7
|
@@ -10,20 +10,20 @@ export type VariantFlagValue = Partial<CanvasConfigResponse> & {
|
|
|
10
10
|
/**
|
|
11
11
|
* Strategy for resolving multiple active variant configs into one.
|
|
12
12
|
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
13
|
+
* - "merge" (default): concatenate tiles/actions from all active variants.
|
|
14
|
+
* Singleton fields (theme, launcher, meta, etc.) take first-defined value.
|
|
15
|
+
* - "first-match": returns the first non-empty variant config (legacy).
|
|
15
16
|
*/
|
|
16
|
-
export type MergeStrategy = 'first-match';
|
|
17
|
+
export type MergeStrategy = 'merge' | 'first-match';
|
|
17
18
|
/**
|
|
18
19
|
* Resolve multiple variant feature flags into a single CanvasConfigResponse.
|
|
19
20
|
*
|
|
20
21
|
* Evaluates each flag key against the experiment client and applies the
|
|
21
|
-
* configured strategy.
|
|
22
|
-
* returns a non-empty config wins.
|
|
22
|
+
* configured strategy.
|
|
23
23
|
*
|
|
24
24
|
* @param client - Experiment client to evaluate feature flags
|
|
25
25
|
* @param keys - Ordered list of variant flag keys to evaluate
|
|
26
|
-
* @param
|
|
26
|
+
* @param strategy - Resolution strategy (default: "merge")
|
|
27
27
|
* @returns Resolved config, or null if no flags are active
|
|
28
28
|
*/
|
|
29
|
-
export declare function resolveVariantConfigs(client: ExperimentClient, keys: string[],
|
|
29
|
+
export declare function resolveVariantConfigs(client: ExperimentClient, keys: string[], strategy?: MergeStrategy): CanvasConfigResponse | null;
|
package/dist/index.js
CHANGED