@praxisui/visual-builder 3.0.0-beta.7 → 3.0.0-beta.8

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/index.d.ts CHANGED
@@ -4,10 +4,10 @@ import { ContextProvider, FunctionRegistry, ExportOptions as ExportOptions$1, Co
4
4
  import { SpecificationMetadata, Specification } from '@praxisui/specification-core';
5
5
  export { SpecificationMetadata } from '@praxisui/specification-core';
6
6
  import { Observable } from 'rxjs';
7
- import { FormLayoutRule, RulePropertySchema } from '@praxisui/core';
7
+ import { FormLayoutRule, RulePropertySchema, PraxisI18nService } from '@praxisui/core';
8
8
  import { DslParsingConfig, DslParsingResult, DslParsingService, AiResponseValidatorService, AiRuleResponse } from '@praxisui/ai';
9
- import { MatSnackBar } from '@angular/material/snack-bar';
10
9
  import { MatDialog, MatDialogRef } from '@angular/material/dialog';
10
+ import { MatSnackBar } from '@angular/material/snack-bar';
11
11
  import { FormBuilder, FormGroup, FormControl, FormArray } from '@angular/forms';
12
12
  import { MatSelectChange } from '@angular/material/select';
13
13
  import { CdkDragDrop } from '@angular/cdk/drag-drop';
@@ -1735,6 +1735,7 @@ declare class RuleBuilderService {
1735
1735
  updateFromParsedDsl(nodes: Record<string, RuleNode>, rootNodes: string[], description?: string): void;
1736
1736
  private saveSnapshot;
1737
1737
  private generateNodeLabel;
1738
+ private withRuleTimestamps;
1738
1739
  private isPropertyRuleNode;
1739
1740
  private containsPropertyRule;
1740
1741
  /**
@@ -2729,12 +2730,13 @@ type RuleNodeConfigExtended = RuleNodeConfig & {
2729
2730
  condition?: RuleNode | string | null;
2730
2731
  };
2731
2732
  declare class RuleEditorComponent implements OnInit, OnDestroy, OnChanges, AfterViewInit {
2732
- private ruleBuilderService;
2733
- private fieldSchemaService;
2734
- private aiResponseValidator;
2735
- private snackBar;
2736
- private dialog;
2737
- private cdr;
2733
+ private readonly ruleBuilderService;
2734
+ private readonly fieldSchemaService;
2735
+ private readonly aiResponseValidator;
2736
+ private readonly snackBar;
2737
+ private readonly dialog;
2738
+ private readonly cdr;
2739
+ private readonly i18n?;
2738
2740
  embedded: boolean;
2739
2741
  config: RuleBuilderConfig | null;
2740
2742
  initialRules: any;
@@ -2756,33 +2758,36 @@ declare class RuleEditorComponent implements OnInit, OnDestroy, OnChanges, After
2756
2758
  private lastErrorCount;
2757
2759
  get canUndo(): boolean;
2758
2760
  get canRedo(): boolean;
2759
- constructor(ruleBuilderService: RuleBuilderService, fieldSchemaService: FieldSchemaService, aiResponseValidator: AiResponseValidatorService, snackBar: MatSnackBar, dialog: MatDialog, cdr: ChangeDetectorRef);
2761
+ constructor(ruleBuilderService: RuleBuilderService, fieldSchemaService: FieldSchemaService, aiResponseValidator: AiResponseValidatorService, snackBar: MatSnackBar, dialog: MatDialog, cdr: ChangeDetectorRef, i18n?: PraxisI18nService | undefined);
2760
2762
  ngOnInit(): void;
2761
2763
  ngOnChanges(changes: SimpleChanges): void;
2762
2764
  ngAfterViewInit(): void;
2763
2765
  ngOnDestroy(): void;
2764
- private setupSubscriptions;
2765
2766
  undo(): void;
2766
2767
  redo(): void;
2767
2768
  clearRules(): void;
2768
2769
  toggleListPanel(): void;
2770
+ shouldShowShellChrome(): boolean;
2771
+ shouldShowStatusBar(): boolean;
2769
2772
  openAiWizard(): void;
2770
2773
  createRuleFromAI(aiResponse: AiRuleResponse): Promise<void>;
2771
- private validateAiResponse;
2772
2774
  addPropertyRule(): void;
2773
2775
  selectNode(nodeId: string): void;
2776
+ duplicateNode(nodeId: string): void;
2774
2777
  onRuleUpdated(config: RuleNodeConfigExtended): void;
2775
2778
  removeNode(nodeId: string): void;
2776
2779
  isPropertyRule(node: RuleNode | null): boolean;
2777
- private buildPropertyRuleLabel;
2778
- private stripTargetPrefix;
2779
- private normalizeRuleConfig;
2780
2780
  openExportDialog(): void;
2781
2781
  importRules(): void;
2782
2782
  onFileSelected(event: Event): void;
2783
2783
  getRuleCount(): number;
2784
- trackByNodeId(index: number, nodeId: string): string;
2785
- static ɵfac: i0.ɵɵFactoryDeclaration<RuleEditorComponent, never>;
2784
+ t(key: string, fallback: string): string;
2785
+ private setupSubscriptions;
2786
+ private validateAiResponse;
2787
+ private buildPropertyRuleLabel;
2788
+ private stripTargetPrefix;
2789
+ private normalizeRuleConfig;
2790
+ static ɵfac: i0.ɵɵFactoryDeclaration<RuleEditorComponent, [null, null, null, null, null, null, { optional: true; }]>;
2786
2791
  static ɵcmp: i0.ɵɵComponentDeclaration<RuleEditorComponent, "praxis-rule-editor", never, { "embedded": { "alias": "embedded"; "required": false; }; "config": { "alias": "config"; "required": false; }; "initialRules": { "alias": "initialRules"; "required": false; }; }, { "stateChanged": "stateChanged"; "save": "save"; "rulesChanged": "rulesChanged"; "exportRequested": "exportRequested"; "importRequested": "importRequested"; }, never, never, true, never>;
2787
2792
  }
2788
2793
 
@@ -3602,27 +3607,54 @@ declare class TemplatePreviewDialogComponent {
3602
3607
  }
3603
3608
 
3604
3609
  type RuleListItem = string | RuleNode;
3610
+ type RuleCardStatus = 'draft' | 'incomplete' | 'error' | 'valid';
3611
+ type StatusFilter = 'all' | RuleCardStatus;
3605
3612
  declare class RuleListComponent {
3613
+ private readonly i18n?;
3606
3614
  rules: RuleListItem[];
3607
3615
  selectedRuleId: string;
3608
3616
  nodeMap: Record<string, RuleNode>;
3617
+ validationErrors: ValidationError$1[];
3609
3618
  ruleSelected: EventEmitter<string>;
3610
3619
  ruleDeleted: EventEmitter<string>;
3620
+ ruleDuplicated: EventEmitter<string>;
3611
3621
  ruleAdded: EventEmitter<void>;
3622
+ aiRequested: EventEmitter<void>;
3612
3623
  searchTerm: string;
3624
+ statusFilter: StatusFilter;
3625
+ constructor(i18n?: PraxisI18nService | undefined);
3613
3626
  get filteredRules(): RuleListItem[];
3614
3627
  trackById: (_index: number, item: RuleListItem) => string;
3615
3628
  isSelected(item: RuleListItem): boolean;
3616
3629
  getLabel(item: RuleListItem): string;
3617
- getDescription(item: RuleListItem): string | undefined;
3618
3630
  getTooltip(item: RuleListItem): string;
3619
- private getItemId;
3631
+ getStatus(item: RuleListItem): RuleCardStatus;
3632
+ getStatusLabel(item: RuleListItem): string;
3633
+ countRulesByStatus(status: RuleCardStatus): number;
3634
+ getConditionPill(item: RuleListItem): string;
3635
+ getConditionDetail(item: RuleListItem): string;
3636
+ getPrimaryTargetLabel(item: RuleListItem): string;
3637
+ getMainTargetName(item: RuleListItem): string;
3638
+ getPrimaryEffectLabel(item: RuleListItem): string;
3639
+ getEffectDetail(item: RuleListItem): string;
3640
+ getSummary(item: RuleListItem): string;
3641
+ getRelativeTime(item: RuleListItem): string | null;
3642
+ getTargetPreview(item: RuleListItem): string[];
3643
+ t(key: string, fallback: string): string;
3620
3644
  onSelect(item: RuleListItem): void;
3621
3645
  onDelete(item: RuleListItem, event: MouseEvent): void;
3646
+ onDuplicate(item: RuleListItem, event: MouseEvent): void;
3622
3647
  onKeySelect(item: RuleListItem, event: Event): void;
3623
3648
  onAddRule(): void;
3624
- static ɵfac: i0.ɵɵFactoryDeclaration<RuleListComponent, never>;
3625
- static ɵcmp: i0.ɵɵComponentDeclaration<RuleListComponent, "praxis-rule-list", never, { "rules": { "alias": "rules"; "required": false; }; "selectedRuleId": { "alias": "selectedRuleId"; "required": false; }; "nodeMap": { "alias": "nodeMap"; "required": false; }; }, { "ruleSelected": "ruleSelected"; "ruleDeleted": "ruleDeleted"; "ruleAdded": "ruleAdded"; }, never, never, true, never>;
3649
+ onAiRequest(): void;
3650
+ private getNode;
3651
+ private getItemId;
3652
+ private getTargetTypeLabel;
3653
+ private describeProperty;
3654
+ private stripTargetPrefix;
3655
+ private parseTimestamp;
3656
+ static ɵfac: i0.ɵɵFactoryDeclaration<RuleListComponent, [{ optional: true; }]>;
3657
+ static ɵcmp: i0.ɵɵComponentDeclaration<RuleListComponent, "praxis-rule-list", never, { "rules": { "alias": "rules"; "required": false; }; "selectedRuleId": { "alias": "selectedRuleId"; "required": false; }; "nodeMap": { "alias": "nodeMap"; "required": false; }; "validationErrors": { "alias": "validationErrors"; "required": false; }; }, { "ruleSelected": "ruleSelected"; "ruleDeleted": "ruleDeleted"; "ruleDuplicated": "ruleDuplicated"; "ruleAdded": "ruleAdded"; "aiRequested": "aiRequested"; }, never, never, true, never>;
3626
3658
  }
3627
3659
 
3628
3660
  export { ArrayFieldAnalyzer, CollectionValidatorEditorComponent, ConditionalValidatorEditorComponent, ConditionalValidatorType, ConfigurationError, ContextError, ContextManagementService, ConversionError, ConverterFactoryService, DslError, DslLinterComponent, DslViewerComponent, ErrorCategory, ErrorHandler, ErrorSeverity, ExportDialogComponent, ExportIntegrationService, FIELD_TYPE_OPERATORS, FieldConditionEditorComponent, FieldSchemaService, FieldType, InternalError, JsonViewerComponent, MetadataEditorComponent, OPERATOR_LABELS, PraxisVisualBuilder, RegistryError, RoundTripTesterComponent, RoundTripValidatorService, RuleBuilderService, RuleCanvasComponent, RuleConversionService, RuleEditorComponent, RuleListComponent, RuleNodeComponent, RuleNodeRegistryService, RuleNodeType, RuleTemplateService, RuleValidationService, SpecificationBridgeService, TemplateEditorDialogComponent, TemplateGalleryComponent, TemplatePreviewDialogComponent, ValidationError as VBValidationError, ValidationCategory, ValidationSeverity, VisualBuilderError, VisualRuleBuilderComponent, WebhookIntegrationService, createError, getArrayItemFieldPaths, globalErrorHandler, isArrayFieldSchema };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@praxisui/visual-builder",
3
- "version": "3.0.0-beta.7",
3
+ "version": "3.0.0-beta.8",
4
4
  "description": "Visual rule and expression builder for Praxis UI with mini-DSL support, validation and context variables.",
5
5
  "peerDependencies": {
6
6
  "@angular/common": "^20.0.0",
@@ -8,9 +8,9 @@
8
8
  "@angular/cdk": "^20.0.0",
9
9
  "@angular/material": "^20.0.0",
10
10
  "@angular/forms": "^20.0.0",
11
- "@praxisui/specification-core": "^3.0.0-beta.7",
12
- "@praxisui/specification": "^3.0.0-beta.7",
13
- "@praxisui/settings-panel": "^3.0.0-beta.7"
11
+ "@praxisui/specification-core": "^3.0.0-beta.8",
12
+ "@praxisui/specification": "^3.0.0-beta.8",
13
+ "@praxisui/settings-panel": "^3.0.0-beta.8"
14
14
  },
15
15
  "dependencies": {
16
16
  "tslib": "^2.3.0",