@masterteam/formula-builder 0.0.20 → 0.0.22
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
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@masterteam/formula-builder",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.22",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"directory": "../../../dist/masterteam/formula-builder",
|
|
6
6
|
"linkDirectory": true,
|
|
@@ -19,8 +19,8 @@
|
|
|
19
19
|
"rxjs": "^7.8.2",
|
|
20
20
|
"tailwindcss": "^4.2.2",
|
|
21
21
|
"tailwindcss-primeui": "^0.6.1",
|
|
22
|
-
"@masterteam/
|
|
23
|
-
"@masterteam/
|
|
22
|
+
"@masterteam/components": "^0.0.207",
|
|
23
|
+
"@masterteam/icons": "^0.0.17"
|
|
24
24
|
},
|
|
25
25
|
"sideEffects": false,
|
|
26
26
|
"exports": {
|
|
@@ -155,17 +155,12 @@ declare class FormulaBuilder implements ControlValueAccessor, OnDestroy {
|
|
|
155
155
|
readonly resolvedContextEntityTypeKey: _angular_core.Signal<string | undefined>;
|
|
156
156
|
readonly isModuleContext: _angular_core.Signal<boolean>;
|
|
157
157
|
readonly autocompleteProvider: (request: AutocompleteRequest) => Observable<AutocompleteResponse | null>;
|
|
158
|
-
/** Track last synced builder JSON to avoid loops */
|
|
159
|
-
private lastBuilderJson;
|
|
160
158
|
/** Editor mode */
|
|
161
159
|
readonly editorMode: _angular_core.WritableSignal<"builder" | "code">;
|
|
162
160
|
readonly isCodeMode: _angular_core.Signal<boolean>;
|
|
163
|
-
readonly isCodeModeLocked: _angular_core.WritableSignal<boolean>;
|
|
164
161
|
readonly showModeToggle: _angular_core.Signal<boolean>;
|
|
165
162
|
readonly formulaApiMode: _angular_core.Signal<"default" | "current-only">;
|
|
166
163
|
readonly resolvedToolbarTabs: _angular_core.Signal<readonly ToolbarTab[]>;
|
|
167
|
-
private codeModeSnapshotTokens;
|
|
168
|
-
private codeModeSnapshotExpression;
|
|
169
164
|
/** ControlValueAccessor callbacks */
|
|
170
165
|
private onChange;
|
|
171
166
|
private onTouched;
|
|
@@ -207,11 +202,23 @@ declare class FormulaBuilder implements ControlValueAccessor, OnDestroy {
|
|
|
207
202
|
private setEditorMode;
|
|
208
203
|
private enterCodeMode;
|
|
209
204
|
private exitCodeMode;
|
|
210
|
-
private clearBuilderTokens;
|
|
211
205
|
/** Clear the formula */
|
|
212
206
|
clear(): void;
|
|
213
207
|
private resolveExpressionValue;
|
|
214
208
|
private applyFormulaValue;
|
|
209
|
+
private rebuildBuilderFromExpression;
|
|
210
|
+
/**
|
|
211
|
+
* Resolve friendly display labels on property tokens from the loaded property
|
|
212
|
+
* map (table path -> [{ key, name }]). This lets the visual builder render
|
|
213
|
+
* "Start Date" instead of the raw "@Current::dema_qa_portfolio_startdate" key
|
|
214
|
+
* after a code->blocks switch or when hydrating an expression-only formula.
|
|
215
|
+
* Pure and loop-safe: returns the SAME array reference when nothing changed,
|
|
216
|
+
* and only touches `display` — never `value` — so the executable expression
|
|
217
|
+
* and validation are unaffected.
|
|
218
|
+
*/
|
|
219
|
+
private enrichTokenDisplays;
|
|
220
|
+
private syncBuilderFromExpression;
|
|
221
|
+
private setBuilderTokens;
|
|
215
222
|
readonly propertyScope: _angular_core.WritableSignal<string>;
|
|
216
223
|
readonly propertyPathSegments: _angular_core.WritableSignal<PathSegment[]>;
|
|
217
224
|
readonly propertyFieldKey: _angular_core.WritableSignal<string>;
|