@cqa-lib/cqa-ui 1.1.550 → 1.1.551

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.
@@ -7813,12 +7813,16 @@ const DEFAULT_MODULAR_LABELS = {
7813
7813
  folderMenuDuplicate: 'Duplicate folder',
7814
7814
  folderMenuDelete: 'Delete folder',
7815
7815
  deleteFolderDialogTitle: 'Delete folder',
7816
- deleteFolderDialogBodySingular: 'This folder contains 1 test case. What should happen to them?',
7817
- deleteFolderDialogBodyPlural: 'This folder contains {n} test cases. What should happen to them?',
7818
- deleteFolderDialogMoveToParentTitle: 'Move test cases to parent folder',
7819
- deleteFolderDialogMoveToParentDescription: 'Test cases move one level up — nothing is lost',
7820
- deleteFolderDialogMoveToUnorganizedTitle: 'Move test cases to Unorganized',
7821
- deleteFolderDialogMoveToUnorganizedDescription: 'Test cases return to the Unorganized section',
7816
+ deleteFolderDialogBodyTemplate: 'This folder contains {items}. What should happen to them?',
7817
+ deleteFolderDialogBodyTestCaseSingular: '1 test case',
7818
+ deleteFolderDialogBodyTestCasePlural: '{n} test cases',
7819
+ deleteFolderDialogBodyStepGroupSingular: '1 step group',
7820
+ deleteFolderDialogBodyStepGroupPlural: '{n} step groups',
7821
+ deleteFolderDialogBodyJoin: 'and',
7822
+ deleteFolderDialogMoveToParentTitle: 'Move to parent folder',
7823
+ deleteFolderDialogMoveToParentDescription: 'Move them one level up — nothing is lost',
7824
+ deleteFolderDialogMoveToUnorganizedTitle: 'Move to Unorganized',
7825
+ deleteFolderDialogMoveToUnorganizedDescription: 'Move them to the Unorganized section',
7822
7826
  deleteFolderDialogCancel: 'Cancel',
7823
7827
  deleteFolderDialogConfirm: 'Delete folder',
7824
7828
  emptyNoTestsInFolderTitle: 'No Test Case Found',
@@ -8490,6 +8494,7 @@ class DeleteFolderDialogComponent {
8490
8494
  this.cdr = cdr;
8491
8495
  this.folderName = '';
8492
8496
  this.testCount = 0;
8497
+ this.stepGroupCount = 0;
8493
8498
  this.hasParent = false;
8494
8499
  this.labels = { ...DEFAULT_MODULAR_LABELS };
8495
8500
  this.strategy = 'MOVE_TO_PARENT';
@@ -8509,10 +8514,21 @@ class DeleteFolderDialogComponent {
8509
8514
  }
8510
8515
  }
8511
8516
  get bodyText() {
8512
- const template = this.testCount === 1
8513
- ? this.labels.deleteFolderDialogBodySingular
8514
- : this.labels.deleteFolderDialogBodyPlural;
8515
- return template.replace('{n}', '' + this.testCount);
8517
+ const parts = [];
8518
+ if (this.testCount > 0) {
8519
+ const tpl = this.testCount === 1
8520
+ ? this.labels.deleteFolderDialogBodyTestCaseSingular
8521
+ : this.labels.deleteFolderDialogBodyTestCasePlural;
8522
+ parts.push(tpl.replace('{n}', '' + this.testCount));
8523
+ }
8524
+ if (this.stepGroupCount > 0) {
8525
+ const tpl = this.stepGroupCount === 1
8526
+ ? this.labels.deleteFolderDialogBodyStepGroupSingular
8527
+ : this.labels.deleteFolderDialogBodyStepGroupPlural;
8528
+ parts.push(tpl.replace('{n}', '' + this.stepGroupCount));
8529
+ }
8530
+ const items = parts.join(` ${this.labels.deleteFolderDialogBodyJoin} `);
8531
+ return this.labels.deleteFolderDialogBodyTemplate.replace('{items}', items);
8516
8532
  }
8517
8533
  setStrategy(value) {
8518
8534
  if (this.strategy === value)
@@ -8523,7 +8539,7 @@ class DeleteFolderDialogComponent {
8523
8539
  }
8524
8540
  }
8525
8541
  DeleteFolderDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: DeleteFolderDialogComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
8526
- DeleteFolderDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: DeleteFolderDialogComponent, selector: "cqa-delete-folder-dialog", inputs: { folderName: "folderName", testCount: "testCount", hasParent: "hasParent", labels: "labels", strategy: "strategy" }, outputs: { strategyChange: "strategyChange" }, host: { classAttribute: "cqa-ui-root" }, usesOnChanges: true, ngImport: i0, template: `
8542
+ DeleteFolderDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: DeleteFolderDialogComponent, selector: "cqa-delete-folder-dialog", inputs: { folderName: "folderName", testCount: "testCount", stepGroupCount: "stepGroupCount", hasParent: "hasParent", labels: "labels", strategy: "strategy" }, outputs: { strategyChange: "strategyChange" }, host: { classAttribute: "cqa-ui-root" }, usesOnChanges: true, ngImport: i0, template: `
8527
8543
  <div class="cqa-flex cqa-flex-col cqa-gap-4 cqa-w-full">
8528
8544
  <p class="cqa-text-sm cqa-text-neutral-800 cqa-m-0">{{ bodyText }}</p>
8529
8545
 
@@ -8639,6 +8655,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
8639
8655
  type: Input
8640
8656
  }], testCount: [{
8641
8657
  type: Input
8658
+ }], stepGroupCount: [{
8659
+ type: Input
8642
8660
  }], hasParent: [{
8643
8661
  type: Input
8644
8662
  }], labels: [{