@cqa-lib/cqa-ui 1.1.367 → 1.1.369

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.
@@ -1,4 +1,4 @@
1
- import { EventEmitter, OnChanges, SimpleChanges } from '@angular/core';
1
+ import { EventEmitter, OnChanges, SimpleChanges, ChangeDetectorRef } from '@angular/core';
2
2
  import * as i0 from "@angular/core";
3
3
  export declare type StepItemStatus = 'passed' | 'current' | 'pending' | 'failed' | 'running' | 'skipped';
4
4
  export interface JumpToStepItem {
@@ -6,15 +6,40 @@ export interface JumpToStepItem {
6
6
  stepNumber: string | number;
7
7
  description: string;
8
8
  status: StepItemStatus;
9
+ /** Step id for selection. When missing, derived from id. */
10
+ stepId?: number;
11
+ /** Optional flag to indicate this item represents a prerequisite step. */
12
+ isPrerequisite?: boolean;
13
+ /** Optional group name (e.g. prerequisite test case name) for visual grouping. */
14
+ groupName?: string;
9
15
  [key: string]: any;
10
16
  }
17
+ export interface JumpToStepStepMeta {
18
+ stepId: number;
19
+ label: string;
20
+ stepNumber: string;
21
+ status: StepItemStatus;
22
+ isPrerequisite?: boolean;
23
+ groupName?: string;
24
+ }
25
+ export interface CombinedTestCaseGroup {
26
+ name?: string;
27
+ isPrerequisite?: boolean;
28
+ steps?: any[];
29
+ }
11
30
  export declare class JumpToStepModalComponent implements OnChanges {
31
+ private readonly cdr;
32
+ constructor(cdr: ChangeDetectorRef);
12
33
  /** Whether the modal is open */
13
34
  isOpen: boolean;
14
35
  /** Modal title */
15
36
  title: string;
16
- /** List of step items to display */
37
+ /** List of step items to display (legacy; used when combinedTestCases not provided) */
17
38
  items: JumpToStepItem[];
39
+ /** Combined test cases for accordion layout. When provided with stepsMeta, used instead of items. */
40
+ combinedTestCases: CombinedTestCaseGroup[];
41
+ /** Pre-computed step metadata (stepNumber, status, etc.) for each step. Required when using combinedTestCases. */
42
+ stepsMeta: JumpToStepStepMeta[];
18
43
  /** Search placeholder text */
19
44
  searchPlaceholder: string;
20
45
  /** Search Empty State text */
@@ -23,8 +48,19 @@ export declare class JumpToStepModalComponent implements OnChanges {
23
48
  searchValue: string;
24
49
  /** Whether search is enabled */
25
50
  enableSearch: boolean;
51
+ /** Whether to show prerequisite steps section. Default true. */
52
+ showPrerequisites: boolean;
26
53
  /** Filtered items based on search */
27
54
  filteredItems: JumpToStepItem[];
55
+ /** Prerequisite groups for accordion: each prerequisite test case by name. */
56
+ prerequisiteGroups: {
57
+ name: string;
58
+ items: JumpToStepItem[];
59
+ }[];
60
+ /** Filtered non-prerequisite step items. */
61
+ filteredStepItems: JumpToStepItem[];
62
+ /** Expanded prerequisite group names. When empty, all groups are collapsed by default. */
63
+ private readonly expandedGroupNames;
28
64
  /** Emitted when modal should be closed */
29
65
  onClose: EventEmitter<void>;
30
66
  /** Emitted when search value changes */
@@ -33,6 +69,11 @@ export declare class JumpToStepModalComponent implements OnChanges {
33
69
  onSelect: EventEmitter<JumpToStepItem>;
34
70
  ngOnChanges(changes: SimpleChanges): void;
35
71
  private updateFilteredItems;
72
+ private buildFromCombinedTestCases;
73
+ private buildFromItems;
74
+ private stripHtml;
75
+ isGroupExpanded(name: string): boolean;
76
+ toggleGroup(name: string): void;
36
77
  onSearchValueChange(value: string): void;
37
78
  onItemClick(item: JumpToStepItem): void;
38
79
  onBackdropClick(event: MouseEvent): void;
@@ -44,5 +85,5 @@ export declare class JumpToStepModalComponent implements OnChanges {
44
85
  toLabel(value: string | number): string;
45
86
  trackByItemId(index: number, item: JumpToStepItem): string;
46
87
  static ɵfac: i0.ɵɵFactoryDeclaration<JumpToStepModalComponent, never>;
47
- static ɵcmp: i0.ɵɵComponentDeclaration<JumpToStepModalComponent, "cqa-jump-to-step-modal", never, { "isOpen": "isOpen"; "title": "title"; "items": "items"; "searchPlaceholder": "searchPlaceholder"; "searchEmptyStateLabel": "searchEmptyStateLabel"; "searchValue": "searchValue"; "enableSearch": "enableSearch"; }, { "onClose": "onClose"; "onSearch": "onSearch"; "onSelect": "onSelect"; }, never, never>;
88
+ static ɵcmp: i0.ɵɵComponentDeclaration<JumpToStepModalComponent, "cqa-jump-to-step-modal", never, { "isOpen": "isOpen"; "title": "title"; "items": "items"; "combinedTestCases": "combinedTestCases"; "stepsMeta": "stepsMeta"; "searchPlaceholder": "searchPlaceholder"; "searchEmptyStateLabel": "searchEmptyStateLabel"; "searchValue": "searchValue"; "enableSearch": "enableSearch"; "showPrerequisites": "showPrerequisites"; }, { "onClose": "onClose"; "onSearch": "onSearch"; "onSelect": "onSelect"; }, never, never>;
48
89
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cqa-lib/cqa-ui",
3
- "version": "1.1.367",
3
+ "version": "1.1.369",
4
4
  "description": "UI Kit library for Angular 13.4",
5
5
  "keywords": [
6
6
  "angular",