@vectoriox/iox-builder 3.0.0 → 3.1.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/package.json
CHANGED
|
@@ -83,11 +83,16 @@ declare enum DataSourceType {
|
|
|
83
83
|
/** A ROUTE-CONTEXT value derived from the current route item — `$route`/`$current`/`$siblings`/
|
|
84
84
|
* `$related`. Not fetched: computed by the shared `computeRelative` from other resolved sources.
|
|
85
85
|
* See relative-data-sources-plan.md. */
|
|
86
|
-
Relative = "relative"
|
|
86
|
+
Relative = "relative",
|
|
87
|
+
/** A page-local VARIABLE: a named resource whose value is WRITTEN at runtime by an interaction
|
|
88
|
+
* (`setContext`), never fetched. Starts empty; elements bind to it like any other alias.
|
|
89
|
+
* `request.variable.itemsFrom` names the source whose items it holds, for field suggestions.
|
|
90
|
+
* See element-context-state-plan.md. */
|
|
91
|
+
Variable = "variable"
|
|
87
92
|
}
|
|
88
93
|
interface IoxDataSource {
|
|
89
94
|
id: string;
|
|
90
|
-
type: 'cms' | 'shop' | 'internal-api' | 'external-api' | 'static' | 'derived' | 'relative';
|
|
95
|
+
type: 'cms' | 'shop' | 'internal-api' | 'external-api' | 'static' | 'derived' | 'relative' | 'variable';
|
|
91
96
|
mode: 'single' | 'query';
|
|
92
97
|
alias: string;
|
|
93
98
|
request: {
|
|
@@ -101,6 +106,11 @@ interface IoxDataSource {
|
|
|
101
106
|
/** `relative` alias: a route-context computation (kind + from/subjectFrom/sortBy/matchFields…),
|
|
102
107
|
* resolved by the shared `computeRelative`. */
|
|
103
108
|
relative?: RelativeSourceSpec;
|
|
109
|
+
/** `variable` alias: written at runtime by an interaction. `itemsFrom` names the source whose
|
|
110
|
+
* items it holds — optional, and used only to suggest fields in the bind picker. */
|
|
111
|
+
variable?: {
|
|
112
|
+
itemsFrom?: string;
|
|
113
|
+
};
|
|
104
114
|
cms?: {
|
|
105
115
|
contentType: string;
|
|
106
116
|
filter?: any;
|