@masterteam/formula-builder 0.0.27 → 0.0.28

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,26 +1,26 @@
1
1
  {
2
2
  "name": "@masterteam/formula-builder",
3
- "version": "0.0.27",
3
+ "version": "0.0.28",
4
4
  "publishConfig": {
5
5
  "directory": "../../../dist/masterteam/formula-builder",
6
6
  "linkDirectory": true,
7
7
  "access": "public"
8
8
  },
9
9
  "peerDependencies": {
10
- "@angular/common": "^21.2.8",
11
- "@angular/core": "^21.2.8",
12
- "@angular/forms": "^21.2.8",
13
- "@angular/cdk": "^21.2.6",
14
- "@primeuix/themes": "^2.0.3",
15
- "@tailwindcss/postcss": "^4.2.2",
16
- "@jsverse/transloco": "^8.3.0",
17
- "postcss": "^8.5.9",
18
- "primeng": "21.1.5",
19
- "rxjs": "^7.8.2",
20
- "tailwindcss": "^4.2.2",
21
- "tailwindcss-primeui": "^0.6.1",
22
- "@masterteam/icons": "^0.0.17",
23
- "@masterteam/components": "^0.0.227"
10
+ "@angular/common": "catalog:angular21",
11
+ "@angular/core": "catalog:angular21",
12
+ "@angular/forms": "catalog:angular21",
13
+ "@angular/cdk": "catalog:angular21",
14
+ "@primeuix/themes": "catalog:",
15
+ "@tailwindcss/postcss": "catalog:",
16
+ "@jsverse/transloco": "catalog:i18n",
17
+ "postcss": "catalog:",
18
+ "primeng": "catalog:",
19
+ "rxjs": "catalog:angular21",
20
+ "tailwindcss": "catalog:",
21
+ "tailwindcss-primeui": "catalog:",
22
+ "@masterteam/components": "workspace:^",
23
+ "@masterteam/icons": "workspace:^"
24
24
  },
25
25
  "sideEffects": false,
26
26
  "exports": {
@@ -36,6 +36,6 @@
36
36
  "typings": "types/masterteam-formula-builder.d.ts",
37
37
  "type": "module",
38
38
  "dependencies": {
39
- "tslib": "^2.8.1"
39
+ "tslib": "catalog:angular21"
40
40
  }
41
41
  }
@@ -4,7 +4,7 @@ import { OnDestroy } from '@angular/core';
4
4
  import { ControlValueAccessor } from '@angular/forms';
5
5
  import { RadioItem } from '@masterteam/components/radio-cards';
6
6
  import { Observable } from 'rxjs';
7
- import { FunctionCategoryGroup, AutocompleteRequest as AutocompleteRequest$1, AutocompleteResponse as AutocompleteResponse$1, ValidationResult as ValidationResult$1, FormulaToken, ToolbarTab, SmartBlock } from '@masterteam/components/formula';
7
+ import { FunctionCategoryGroup, AutocompleteRequest as AutocompleteRequest$1, AutocompleteResponse as AutocompleteResponse$1, ValidationResult as ValidationResult$1, FormulaToken, ToolbarTab, OperatorDefinition, SmartBlock } from '@masterteam/components/formula';
8
8
  export { ArgumentSlot, BlockType, DragBehavior, FormulaToken, FunctionCategoryGroup, FunctionDefinition, OperatorDefinition, SmartBlock, TokenType, ValidationError, ValidationResult, createFunctionBlock, createLiteralBlock, createOperatorBlock, createPropertyBlock } from '@masterteam/components/formula';
9
9
 
10
10
  type ValidationResult = ValidationResult$1;
@@ -185,6 +185,10 @@ declare class FormulaBuilder implements ControlValueAccessor, OnDestroy {
185
185
  readonly hideStatusBar: _angular_core.InputSignal<boolean>;
186
186
  /** Visible toolbar tabs */
187
187
  readonly toolbarTabs: _angular_core.InputSignal<readonly ToolbarTab[]>;
188
+ /** Optional host-owned function catalog. Takes precedence over API context. */
189
+ readonly functionCategories: _angular_core.InputSignal<FunctionCategoryGroup[]>;
190
+ /** Operators shown in the formula toolbar. */
191
+ readonly operators: _angular_core.InputSignal<OperatorDefinition[]>;
188
192
  /** Force code editor mode and hide the mode toggle */
189
193
  readonly codeOnly: _angular_core.InputSignal<boolean>;
190
194
  /** Keep the block builder active and hide the code-mode toggle. */
@@ -247,8 +251,8 @@ declare class FormulaBuilder implements ControlValueAccessor, OnDestroy {
247
251
  readonly isValidating: _angular_core.Signal<boolean>;
248
252
  /** Builder context from API */
249
253
  readonly builderContext: _angular_core.WritableSignal<FormulaBuilderContextResponse | null>;
250
- /** Function categories from context */
251
- readonly functionCategories: _angular_core.Signal<_masterteam_formula_builder.FunctionCategoryGroup[]>;
254
+ /** Function categories from the host, context API, or validation fallback. */
255
+ readonly resolvedFunctionCategories: _angular_core.Signal<FunctionCategoryGroup[]>;
252
256
  /** Is builder context loading */
253
257
  readonly isContextLoading: _angular_core.WritableSignal<boolean>;
254
258
  private contextRequestId;
@@ -390,7 +394,7 @@ declare class FormulaBuilder implements ControlValueAccessor, OnDestroy {
390
394
  private buildLookupValueResponse;
391
395
  getOperatorDisplayName(token: string): string;
392
396
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<FormulaBuilder, never>;
393
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<FormulaBuilder, "mt-formula-builder", never, { "propertiesByPath": { "alias": "propertiesByPath"; "required": false; "isSignal": true; }; "levelSchemaId": { "alias": "levelSchemaId"; "required": false; "isSignal": true; }; "moduleId": { "alias": "moduleId"; "required": false; "isSignal": true; }; "contextKey": { "alias": "contextKey"; "required": false; "isSignal": true; }; "contextEntityTypeKey": { "alias": "contextEntityTypeKey"; "required": false; "isSignal": true; }; "templateId": { "alias": "templateId"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "hideToolbar": { "alias": "hideToolbar"; "required": false; "isSignal": true; }; "hideStatusBar": { "alias": "hideStatusBar"; "required": false; "isSignal": true; }; "toolbarTabs": { "alias": "toolbarTabs"; "required": false; "isSignal": true; }; "codeOnly": { "alias": "codeOnly"; "required": false; "isSignal": true; }; "builderOnly": { "alias": "builderOnly"; "required": false; "isSignal": true; }; "valueMode": { "alias": "valueMode"; "required": false; "isSignal": true; }; "isProcessBuilder": { "alias": "isProcessBuilder"; "required": false; "isSignal": true; }; }, { "validationChange": "validationChange"; "tokensChange": "tokensChange"; }, never, never, true, never>;
397
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<FormulaBuilder, "mt-formula-builder", never, { "propertiesByPath": { "alias": "propertiesByPath"; "required": false; "isSignal": true; }; "levelSchemaId": { "alias": "levelSchemaId"; "required": false; "isSignal": true; }; "moduleId": { "alias": "moduleId"; "required": false; "isSignal": true; }; "contextKey": { "alias": "contextKey"; "required": false; "isSignal": true; }; "contextEntityTypeKey": { "alias": "contextEntityTypeKey"; "required": false; "isSignal": true; }; "templateId": { "alias": "templateId"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "hideToolbar": { "alias": "hideToolbar"; "required": false; "isSignal": true; }; "hideStatusBar": { "alias": "hideStatusBar"; "required": false; "isSignal": true; }; "toolbarTabs": { "alias": "toolbarTabs"; "required": false; "isSignal": true; }; "functionCategories": { "alias": "functionCategories"; "required": false; "isSignal": true; }; "operators": { "alias": "operators"; "required": false; "isSignal": true; }; "codeOnly": { "alias": "codeOnly"; "required": false; "isSignal": true; }; "builderOnly": { "alias": "builderOnly"; "required": false; "isSignal": true; }; "valueMode": { "alias": "valueMode"; "required": false; "isSignal": true; }; "isProcessBuilder": { "alias": "isProcessBuilder"; "required": false; "isSignal": true; }; }, { "validationChange": "validationChange"; "tokensChange": "tokensChange"; }, never, never, true, never>;
394
398
  }
395
399
 
396
400
  type FormulaApiMode$1 = 'default' | 'current-only';