@cqa-lib/cqa-ui 1.1.249 → 1.1.250

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.
Files changed (21) hide show
  1. package/esm2020/lib/execution-screen/ai-action-step/ai-action-step.component.mjs +2 -2
  2. package/esm2020/lib/execution-screen/ai-agent-step/ai-agent-step.component.mjs +2 -2
  3. package/esm2020/lib/execution-screen/api-step/api-step.component.mjs +2 -2
  4. package/esm2020/lib/execution-screen/basic-step/basic-step.component.mjs +2 -2
  5. package/esm2020/lib/execution-screen/condition-step/condition-step.component.mjs +2 -2
  6. package/esm2020/lib/execution-screen/db-verification-step/db-verification-step.component.mjs +2 -2
  7. package/esm2020/lib/execution-screen/document-verification-step/document-verification-step.component.mjs +2 -2
  8. package/esm2020/lib/execution-screen/execution-step.models.mjs +1 -1
  9. package/esm2020/lib/execution-screen/failed-step/failed-step.component.mjs +2 -2
  10. package/esm2020/lib/execution-screen/file-download-step/file-download-step.component.mjs +2 -2
  11. package/esm2020/lib/execution-screen/live-execution-step/live-execution-step.component.mjs +2 -2
  12. package/esm2020/lib/execution-screen/loop-step/loop-step.component.mjs +6 -6
  13. package/esm2020/lib/execution-screen/step-group/step-group.component.mjs +7 -7
  14. package/esm2020/lib/execution-screen/step-renderer/step-renderer.component.mjs +23 -23
  15. package/esm2020/lib/execution-screen/updated-failed-step/updated-failed-step.component.mjs +2 -2
  16. package/fesm2015/cqa-lib-cqa-ui.mjs +44 -44
  17. package/fesm2015/cqa-lib-cqa-ui.mjs.map +1 -1
  18. package/fesm2020/cqa-lib-cqa-ui.mjs +44 -44
  19. package/fesm2020/cqa-lib-cqa-ui.mjs.map +1 -1
  20. package/lib/execution-screen/execution-step.models.d.ts +12 -12
  21. package/package.json +1 -1
@@ -6715,7 +6715,7 @@ class StepRendererComponent {
6715
6715
  if (!step)
6716
6716
  return '';
6717
6717
  const t = step.testStepType;
6718
- const type = step.type || t || '';
6718
+ const type = step.displayType || t || '';
6719
6719
  if (t === 'generateDocument')
6720
6720
  return 'file-download';
6721
6721
  if (type === 'FOR_LOOP' || type === 'WHILE_LOOP')
@@ -6726,7 +6726,7 @@ class StepRendererComponent {
6726
6726
  isLoopStep(step) {
6727
6727
  if (!step)
6728
6728
  return false;
6729
- const type = step.type || step.testStepType || '';
6729
+ const type = step.displayType || step.testStepType || '';
6730
6730
  return type === 'loop' || type === 'FOR_LOOP' || type === 'WHILE_LOOP';
6731
6731
  }
6732
6732
  /** Resolve effective debugPointSet so it propagates when toggled (e.g. Storybook Controls). */
@@ -6744,7 +6744,7 @@ class StepRendererComponent {
6744
6744
  const previousStep = changes['step']?.previousValue;
6745
6745
  // Check if selectedIterationId input changed (for loop steps)
6746
6746
  // &&
6747
- // currentStep.type === 'loop' &&
6747
+ // currentstep.displayType === 'loop' &&
6748
6748
  // this.container.length > 0;
6749
6749
  // If selectedIterationId changed for a loop step, update it directly
6750
6750
  if (changes['selectedIterationId'] && changes['selectedIterationId'].currentValue !== changes['selectedIterationId'].previousValue) {
@@ -6928,11 +6928,11 @@ class StepRendererComponent {
6928
6928
  }
6929
6929
  // Get step identifiers (use effective type: generateDocument -> file-download)
6930
6930
  const currentStepId = currentStep.testStepResultId || currentStep.id;
6931
- const currentStepType = this.getEffectiveStepType(currentStep) || currentStep.type;
6931
+ const currentStepType = this.getEffectiveStepType(currentStep) || currentStep.displayType;
6932
6932
  // Use stored lastStepId and lastStepType to properly detect changes
6933
6933
  // This handles the case when step object reference doesn't change but properties do
6934
6934
  // Only check for actual ID/type changes, not just reference changes
6935
- // const stepTypeChanged = !previousStep || currentStepType !== (previousStep.type || this.lastStepType);
6935
+ // const stepTypeChanged = !previousStep || currentStepType !== (previousStep.displayType || this.lastStepType);
6936
6936
  // const stepIdChanged = !previousStep || currentStepId !== (previousStep.testStepResultId || previousStep.id || this.lastStepId);
6937
6937
  const stepTypeChanged = currentStepType !== this.lastStepType;
6938
6938
  const stepIdChanged = currentStepId !== this.lastStepId;
@@ -6987,7 +6987,7 @@ class StepRendererComponent {
6987
6987
  const instance = StepRendererComponent.componentInstances.get(this.container);
6988
6988
  const componentRef = StepRendererComponent.componentRefs.get(this.container);
6989
6989
  if (instance && previousStep && currentStep &&
6990
- previousStep.type === currentStep.type &&
6990
+ previousStep.displayType === currentStep.displayType &&
6991
6991
  (previousStep.testStepResultId || previousStep.id) === (currentStep.testStepResultId || currentStep.id)) {
6992
6992
  // Update existing component instance with new step properties
6993
6993
  this.updateComponentInstance(currentStep, previousStep);
@@ -7072,7 +7072,7 @@ class StepRendererComponent {
7072
7072
  hasChanges = true;
7073
7073
  }
7074
7074
  }
7075
- else if (key === 'action' && currentStep.type === 'ai-agent') {
7075
+ else if (key === 'action' && currentStep.displayType === 'ai-agent') {
7076
7076
  // For ai-agent steps, ensure title and prompt are set from action
7077
7077
  const currentValue = currentStep[key];
7078
7078
  const previousValue = previousStep[key];
@@ -7140,7 +7140,7 @@ class StepRendererComponent {
7140
7140
  hasChanges = true;
7141
7141
  }
7142
7142
  }
7143
- if (currentStep.type === 'step-group' && currentStep.children && !currentStep.steps) {
7143
+ if (currentStep.displayType === 'step-group' && currentStep.children && !currentStep.steps) {
7144
7144
  if (instance.steps !== currentStep.children) {
7145
7145
  instance.steps = currentStep.children;
7146
7146
  if (instance.config) {
@@ -7151,7 +7151,7 @@ class StepRendererComponent {
7151
7151
  }
7152
7152
  // Special handling for condition-step: ensure branches is properly updated
7153
7153
  // Use deep comparison to detect changes in nested subSteps
7154
- if (currentStep.type === 'condition' && currentStep.branches !== undefined) {
7154
+ if (currentStep.displayType === 'condition' && currentStep.branches !== undefined) {
7155
7155
  const currentBranches = currentStep.branches || [];
7156
7156
  const previousBranches = previousStep.branches || [];
7157
7157
  // Use deep comparison to detect nested subSteps changes
@@ -7169,7 +7169,7 @@ class StepRendererComponent {
7169
7169
  }
7170
7170
  // Special handling for condition-step: ensure nestedSteps is properly updated
7171
7171
  // This is important when children are loaded from the API or when switching branches
7172
- if (currentStep.type === 'condition' && currentStep.nestedSteps !== undefined) {
7172
+ if (currentStep.displayType === 'condition' && currentStep.nestedSteps !== undefined) {
7173
7173
  const currentNestedSteps = currentStep.nestedSteps || [];
7174
7174
  const previousNestedSteps = previousStep.nestedSteps || [];
7175
7175
  console.log('🔄 step-renderer: currentNestedSteps', currentNestedSteps);
@@ -7287,7 +7287,7 @@ class StepRendererComponent {
7287
7287
  instance.config = { ...instance.config, ...currentStep };
7288
7288
  // Explicitly ensure branches is updated for condition-step (in case it was nested)
7289
7289
  // Use the already updated branches from instance to maintain reference consistency
7290
- if (currentStep.type === 'condition' && instance.branches !== undefined) {
7290
+ if (currentStep.displayType === 'condition' && instance.branches !== undefined) {
7291
7291
  instance.config.branches = instance.branches;
7292
7292
  }
7293
7293
  }
@@ -7446,7 +7446,7 @@ class StepRendererComponent {
7446
7446
  return true;
7447
7447
  }
7448
7448
  // Also check if the step type changed (important for branch switching)
7449
- if (currentStep.type !== previousStep.type) {
7449
+ if (currentStep.displayType !== previousStep.displayType) {
7450
7450
  return true;
7451
7451
  }
7452
7452
  // Check if testStepType changed (IF vs ELSE_IF vs ELSE)
@@ -7480,7 +7480,7 @@ class StepRendererComponent {
7480
7480
  if (!this.container || !this.step)
7481
7481
  return;
7482
7482
  const currentStepId = this.step.testStepResultId || this.step.id;
7483
- const currentStepType = this.getEffectiveStepType(this.step) || this.step.type;
7483
+ const currentStepType = this.getEffectiveStepType(this.step) || this.step.displayType;
7484
7484
  // Only clear and recreate if step ID or type actually changed
7485
7485
  const needsRecreation = this.lastStepId !== currentStepId || this.lastStepType !== currentStepType;
7486
7486
  if (needsRecreation) {
@@ -7530,7 +7530,7 @@ class StepRendererComponent {
7530
7530
  instance.config = { ...instance.config, ...this.step };
7531
7531
  }
7532
7532
  // Sync file-download (generateDocument) props from generateDocumentResult
7533
- const effectiveTypeForUpdate = this.getEffectiveStepType(this.step) || this.step.type;
7533
+ const effectiveTypeForUpdate = this.getEffectiveStepType(this.step) || this.step.displayType;
7534
7534
  if (effectiveTypeForUpdate === 'file-download') {
7535
7535
  const gd = this.step.executedResult?.generateDocumentResult;
7536
7536
  instance.fileName = gd?.fileName ?? instance.fileName ?? '';
@@ -7653,7 +7653,7 @@ class StepRendererComponent {
7653
7653
  return;
7654
7654
  }
7655
7655
  }
7656
- const effectiveType = this.getEffectiveStepType(this.step) || this.step.type;
7656
+ const effectiveType = this.getEffectiveStepType(this.step) || this.step.displayType;
7657
7657
  const componentType = this.componentMap.get(effectiveType);
7658
7658
  if (componentType) {
7659
7659
  const componentRef = this.container.createComponent(componentType);
@@ -7752,7 +7752,7 @@ class StepRendererComponent {
7752
7752
  }
7753
7753
  }
7754
7754
  // Special handling for step-group: map children to steps if steps is not present
7755
- if (this.step.type === 'step-group' && this.step.children && !this.step.steps) {
7755
+ if (this.step.displayType === 'step-group' && this.step.children && !this.step.steps) {
7756
7756
  instance.steps = this.step.children;
7757
7757
  instance.groupName = this.step.action;
7758
7758
  }
@@ -7787,7 +7787,7 @@ class StepRendererComponent {
7787
7787
  }
7788
7788
  }
7789
7789
  // Special handling for condition-step: set branches and conditionText
7790
- if (this.step.type === 'condition') {
7790
+ if (this.step.displayType === 'condition') {
7791
7791
  // Set branches - prioritize step.branches if available, otherwise use handler
7792
7792
  if (this.step.branches && Array.isArray(this.step.branches)) {
7793
7793
  // Create deep copy to ensure proper change detection
@@ -7818,7 +7818,7 @@ class StepRendererComponent {
7818
7818
  }
7819
7819
  }
7820
7820
  // Special handling for ai-agent-step: ensure title and prompt are set from action
7821
- if (this.step.type === 'ai-agent') {
7821
+ if (this.step.displayType === 'ai-agent') {
7822
7822
  // Set title from action if title is not present or empty
7823
7823
  if ((!instance.title || !instance.title.trim()) && this.step.action) {
7824
7824
  instance.title = this.step.action;
@@ -7842,7 +7842,7 @@ class StepRendererComponent {
7842
7842
  }
7843
7843
  }
7844
7844
  // Wire up common event emitters for api, ai-agent, loop, condition, and basic steps
7845
- if (this.step.type === 'api' || this.step.type === 'ai-agent' || this.isLoopStep(this.step) || this.step.type === 'condition' || this.step.type === 'basic') {
7845
+ if (this.step.displayType === 'api' || this.step.displayType === 'ai-agent' || this.isLoopStep(this.step) || this.step.displayType === 'condition' || this.step.displayType === 'basic') {
7846
7846
  // Subscribe to common output events and call handlers
7847
7847
  // EventEmitters are Subjects, so we can subscribe to them
7848
7848
  if (instance.makeCurrentBaseline && this.onMakeCurrentBaselineHandler) {
@@ -7949,7 +7949,7 @@ class StepRendererComponent {
7949
7949
  }
7950
7950
  }
7951
7951
  // Special handling for condition-step: wire up onExpand event
7952
- if (this.step.type === 'condition') {
7952
+ if (this.step.displayType === 'condition') {
7953
7953
  if (instance.onExpand && this.onExpandHandler) {
7954
7954
  instance.onExpand.subscribe(() => {
7955
7955
  // Call onExpandHandler with the step config
@@ -8067,7 +8067,7 @@ class StepRendererComponent {
8067
8067
  if (this.step)
8068
8068
  instance.step = this.step;
8069
8069
  // Update condition-step specific properties for change detection
8070
- if (this.step.type === 'condition') {
8070
+ if (this.step.displayType === 'condition') {
8071
8071
  // Update activeBranchStepId if it changed
8072
8072
  if (this.step.activeBranchStepId !== undefined) {
8073
8073
  instance.activeBranchStepId = this.step.activeBranchStepId;
@@ -8290,7 +8290,7 @@ class StepRendererComponent {
8290
8290
  // Create a minimal previous step from the instance's current state
8291
8291
  const previousStep = {
8292
8292
  id: instance.id,
8293
- type: instance.type,
8293
+ displayType: instance.displayType,
8294
8294
  status: instance.status,
8295
8295
  duration: instance.duration,
8296
8296
  expanded: instance.expanded,
@@ -8773,7 +8773,7 @@ class UpdatedFailedStepComponent extends BaseStepComponent {
8773
8773
  ngOnInit() {
8774
8774
  // Build config from individual inputs
8775
8775
  this.config = {
8776
- type: 'failed',
8776
+ displayType: 'failed',
8777
8777
  testStepResultId: this.testStepResultId,
8778
8778
  subSteps: this.subSteps,
8779
8779
  failureDetails: this.failureDetails,
@@ -8903,7 +8903,7 @@ class BasicStepComponent extends BaseStepComponent {
8903
8903
  title: this.title,
8904
8904
  status: this.status,
8905
8905
  duration: this.duration,
8906
- type: 'basic',
8906
+ displayType: 'basic',
8907
8907
  subSteps: this.subSteps || [],
8908
8908
  stepDeleted: this.stepDeleted,
8909
8909
  selfHealAnalysis: this.selfHealAnalysis,
@@ -9597,7 +9597,7 @@ class StepGroupComponent extends BaseStepComponent {
9597
9597
  title: this.title,
9598
9598
  status: this.status,
9599
9599
  duration: this.duration,
9600
- type: 'step-group',
9600
+ displayType: 'step-group',
9601
9601
  groupName: this.groupName,
9602
9602
  steps: this.steps || [],
9603
9603
  stepDeleted: this.stepDeleted,
@@ -9646,7 +9646,7 @@ class StepGroupComponent extends BaseStepComponent {
9646
9646
  ...this.config,
9647
9647
  hasChild: true,
9648
9648
  expanded: true,
9649
- testStepType: this.config.testStepType || 'STEP_GROUP',
9649
+ displayType: this.config.displayType || 'STEP_GROUP',
9650
9650
  children: this.config.steps || [],
9651
9651
  testStepResultId: this.testStepResultId,
9652
9652
  id: this.id
@@ -9688,7 +9688,7 @@ class StepGroupComponent extends BaseStepComponent {
9688
9688
  }
9689
9689
  // Helper method to check if a step is a step-group with hasChild
9690
9690
  isNestedStepGroupWithChildren(step) {
9691
- return step.type === 'step-group' && !!step.hasChild;
9691
+ return step.displayType === 'step-group' && !!step.hasChild;
9692
9692
  }
9693
9693
  // Helper method to get groupName from step config
9694
9694
  getGroupName(step) {
@@ -9702,12 +9702,12 @@ class StepGroupComponent extends BaseStepComponent {
9702
9702
  }
9703
9703
  // Helper method to check if a step is a loop step
9704
9704
  isNestedLoopStep(step) {
9705
- const stepType = step.testStepType || step.type;
9705
+ const stepType = step.testStepType || step.displayType;
9706
9706
  return stepType === 'FOR_LOOP' || stepType === 'WHILE_LOOP' || stepType === 'loop';
9707
9707
  }
9708
9708
  // Helper method to check if a step is a condition step
9709
9709
  isNestedConditionStep(step) {
9710
- const stepType = step.testStepType || step.type;
9710
+ const stepType = step.testStepType || step.displayType;
9711
9711
  return stepType === 'CONDITION_IF' || stepType === 'CONDITION_ELSE' ||
9712
9712
  stepType === 'CONDITION_ELSE_IF' || stepType === 'CONDITION_ELSEIF' ||
9713
9713
  stepType === 'condition';
@@ -9742,7 +9742,7 @@ class StepGroupComponent extends BaseStepComponent {
9742
9742
  }
9743
9743
  // Helper methods for loop step properties
9744
9744
  getLoopType(step) {
9745
- const stepType = step.testStepType || step.type;
9745
+ const stepType = step.testStepType || step.displayType;
9746
9746
  if (stepType === 'FOR_LOOP' || step.loopType === 'for') {
9747
9747
  return 'for';
9748
9748
  }
@@ -10037,7 +10037,7 @@ class LoopStepComponent extends BaseStepComponent {
10037
10037
  title: stepTitle,
10038
10038
  status: this.status,
10039
10039
  duration: this.duration,
10040
- type: 'loop',
10040
+ displayType: 'loop',
10041
10041
  loopType: this.loopType,
10042
10042
  iterations: this.iterations,
10043
10043
  selectedIterationId: this.selectedIterationId,
@@ -10566,7 +10566,7 @@ class LoopStepComponent extends BaseStepComponent {
10566
10566
  }
10567
10567
  // Helper method to check if a step is a step-group with hasChild
10568
10568
  isNestedStepGroupWithChildren(step) {
10569
- return step.type === 'step-group' && !!step.hasChild;
10569
+ return step.displayType === 'step-group' && !!step.hasChild;
10570
10570
  }
10571
10571
  // Helper method to get groupName from step config
10572
10572
  getGroupName(step) {
@@ -10579,19 +10579,19 @@ class LoopStepComponent extends BaseStepComponent {
10579
10579
  }
10580
10580
  // Helper method to check if a step is a condition step
10581
10581
  isNestedConditionStep(step) {
10582
- const stepType = step.testStepType || step.type;
10582
+ const stepType = step.testStepType || step.displayType;
10583
10583
  return stepType === 'CONDITION_IF' || stepType === 'CONDITION_ELSE' ||
10584
10584
  stepType === 'CONDITION_ELSE_IF' || stepType === 'CONDITION_ELSEIF' ||
10585
10585
  stepType === 'condition';
10586
10586
  }
10587
10587
  // Helper method to check if a step is a loop step
10588
10588
  isNestedLoopStep(step) {
10589
- const stepType = step.testStepType || step.type;
10589
+ const stepType = step.testStepType || step.displayType;
10590
10590
  return stepType === 'FOR_LOOP' || stepType === 'WHILE_LOOP' || stepType === 'loop';
10591
10591
  }
10592
10592
  // Helper method to get loop type from step config
10593
10593
  getLoopType(step) {
10594
- const stepType = step.testStepType || step.type;
10594
+ const stepType = step.testStepType || step.displayType;
10595
10595
  if (stepType === 'FOR_LOOP' || step.loopType === 'for') {
10596
10596
  return 'for';
10597
10597
  }
@@ -11215,7 +11215,7 @@ class ConditionStepComponent extends BaseStepComponent {
11215
11215
  title: this.title,
11216
11216
  status: this.status,
11217
11217
  duration: this.duration,
11218
- type: 'condition',
11218
+ displayType: 'condition',
11219
11219
  conditionText: this.conditionText,
11220
11220
  branches: this.branches,
11221
11221
  stepDeleted: this.stepDeleted,
@@ -11734,7 +11734,7 @@ class FailedStepComponent extends BaseStepComponent {
11734
11734
  title: this.title,
11735
11735
  status: this.status,
11736
11736
  duration: this.duration,
11737
- type: 'failed',
11737
+ displayType: 'failed',
11738
11738
  subSteps: this.subSteps,
11739
11739
  failureDetails: this.failureDetails,
11740
11740
  timingBreakdown: this.timingBreakdown,
@@ -11866,7 +11866,7 @@ class AIAgentStepComponent extends BaseStepComponent {
11866
11866
  title: titleValue,
11867
11867
  status: this.status,
11868
11868
  duration: this.duration,
11869
- type: 'ai-agent',
11869
+ displayType: 'ai-agent',
11870
11870
  prompt: promptValue.replace('AI Agent', '').trim(),
11871
11871
  optimizedRun: this.optimizedRun,
11872
11872
  actionCount: this.actionCount,
@@ -12179,7 +12179,7 @@ class AIActionStepComponent extends BaseStepComponent {
12179
12179
  title: titleValue,
12180
12180
  status: this.status,
12181
12181
  duration: this.duration,
12182
- type: 'ai-action',
12182
+ displayType: 'ai-action',
12183
12183
  actionCount: this.actionCount,
12184
12184
  actions: this.actions || [],
12185
12185
  stepDeleted: this.stepDeleted,
@@ -12905,7 +12905,7 @@ class ApiStepComponent extends BaseStepComponent {
12905
12905
  title: this.title,
12906
12906
  status: this.status,
12907
12907
  duration: this.duration,
12908
- type: 'api',
12908
+ displayType: 'api',
12909
12909
  method: this.method,
12910
12910
  endpoint: this.endpoint,
12911
12911
  statusCode: this.statusCode,
@@ -13331,7 +13331,7 @@ class FileDownloadStepComponent extends BaseStepComponent {
13331
13331
  title: this.title,
13332
13332
  status: this.status,
13333
13333
  duration: this.duration,
13334
- type: 'file-download',
13334
+ displayType: 'file-download',
13335
13335
  fileName: this.fileName,
13336
13336
  fileType: this.fileType,
13337
13337
  fileSize: this.fileSize,
@@ -13513,7 +13513,7 @@ class DocumentVerificationStepComponent extends BaseStepComponent {
13513
13513
  title: this.title,
13514
13514
  status: this.status,
13515
13515
  duration: this.duration,
13516
- type: 'document-verification',
13516
+ displayType: 'document-verification',
13517
13517
  documentScreenshot: this.documentScreenshot,
13518
13518
  extractedFields: this.extractedFields,
13519
13519
  verificationChecks: this.verificationChecks,
@@ -13647,7 +13647,7 @@ class LiveExecutionStepComponent extends BaseStepComponent {
13647
13647
  title: this.title,
13648
13648
  status: this.status,
13649
13649
  duration: this.duration,
13650
- type: 'live-execution',
13650
+ displayType: 'live-execution',
13651
13651
  subSteps: this.subSteps || [],
13652
13652
  stepDeleted: this.stepDeleted,
13653
13653
  expanded: this.expanded,
@@ -18322,7 +18322,7 @@ class DbVerificationStepComponent extends BaseStepComponent {
18322
18322
  title: this.title,
18323
18323
  status: this.status,
18324
18324
  duration: this.duration,
18325
- type: 'db-verification',
18325
+ displayType: 'db-verification',
18326
18326
  dbTestResult: this.dbTestResult,
18327
18327
  dbConfig: this.dbConfig,
18328
18328
  subSteps: this.subSteps || [],