@hmcts/ccd-case-ui-toolkit 7.1.76-hint-text-1 → 7.1.76

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 (23) hide show
  1. package/esm2022/lib/components/form/date-input/date-input.component.mjs +49 -35
  2. package/esm2022/lib/shared/components/palette/base-field/field-read.component.mjs +3 -3
  3. package/esm2022/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder.component.mjs +6 -6
  4. package/esm2022/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu.component.mjs +28 -22
  5. package/esm2022/lib/shared/components/palette/collection/read-collection-field.component.mjs +8 -8
  6. package/esm2022/lib/shared/components/palette/collection/write-collection-field.component.mjs +23 -22
  7. package/esm2022/lib/shared/components/palette/complex/read-complex-field.component.mjs +4 -1
  8. package/esm2022/lib/shared/components/palette/complex/write-complex-field.component.mjs +2 -1
  9. package/esm2022/lib/shared/components/palette/date/write-date-field.component.mjs +6 -3
  10. package/esm2022/lib/shared/components/palette/query-management/components/query-write/query-write-add-documents/query-write-add-documents.component.mjs +2 -2
  11. package/esm2022/lib/shared/domain/definition/case-field.model.mjs +29 -2
  12. package/fesm2022/hmcts-ccd-case-ui-toolkit.mjs +149 -94
  13. package/fesm2022/hmcts-ccd-case-ui-toolkit.mjs.map +1 -1
  14. package/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu.component.d.ts +1 -1
  15. package/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu.component.d.ts.map +1 -1
  16. package/lib/shared/components/palette/collection/write-collection-field.component.d.ts.map +1 -1
  17. package/lib/shared/components/palette/complex/read-complex-field.component.d.ts.map +1 -1
  18. package/lib/shared/components/palette/complex/write-complex-field.component.d.ts.map +1 -1
  19. package/lib/shared/components/palette/date/write-date-field.component.d.ts +1 -0
  20. package/lib/shared/components/palette/date/write-date-field.component.d.ts.map +1 -1
  21. package/lib/shared/domain/definition/case-field.model.d.ts +2 -0
  22. package/lib/shared/domain/definition/case-field.model.d.ts.map +1 -1
  23. package/package.json +1 -1
@@ -13,7 +13,7 @@ import * as i1$2 from '@angular/common/http';
13
13
  import { HttpErrorResponse, HttpHeaders, HttpParams } from '@angular/common/http';
14
14
  import { distinctUntilChanged, catchError, map, publish, refCount, switchMap, debounceTime, delay, finalize, timeout, mergeMap, retryWhen, tap, delayWhen, publishReplay, take, first, takeUntil, filter } from 'rxjs/operators';
15
15
  import { polling } from 'rx-polling-hmcts';
16
- import { Type, Expose, plainToClassFromExist, plainToClass } from 'class-transformer';
16
+ import { Type, Exclude, Expose, plainToClassFromExist, plainToClass } from 'class-transformer';
17
17
  import moment from 'moment';
18
18
  import { __decorate, __metadata } from 'tslib';
19
19
  import * as _ from 'underscore';
@@ -404,7 +404,7 @@ class BodyComponent {
404
404
  const _c0$12 = a0 => ({ "govuk-input--error": a0 });
405
405
  function DateInputComponent_div_19_Template(rf, ctx) { if (rf & 1) {
406
406
  const _r5 = i0.ɵɵgetCurrentView();
407
- i0.ɵɵelementStart(0, "div", 15)(1, "label", 8);
407
+ i0.ɵɵelementStart(0, "div", 15)(1, "span", 8);
408
408
  i0.ɵɵtext(2);
409
409
  i0.ɵɵpipe(3, "rpxTranslate");
410
410
  i0.ɵɵelementEnd();
@@ -414,15 +414,16 @@ function DateInputComponent_div_19_Template(rf, ctx) { if (rf & 1) {
414
414
  } if (rf & 2) {
415
415
  const ctx_r6 = i0.ɵɵnextContext();
416
416
  i0.ɵɵadvance();
417
- i0.ɵɵproperty("for", ctx_r6.hourId());
417
+ i0.ɵɵattribute("id", "hour-label-" + ctx_r6.hourId());
418
418
  i0.ɵɵadvance();
419
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 6, "Hour"));
419
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 7, "Hour"));
420
420
  i0.ɵɵadvance(2);
421
- i0.ɵɵproperty("id", ctx_r6.hourId())("name", ctx_r6.hourId())("value", ctx_r6.displayHour)("ngClass", i0.ɵɵpureFunction1(8, _c0$12, ctx_r6.isInvalid));
421
+ i0.ɵɵproperty("id", ctx_r6.hourId())("name", ctx_r6.hourId())("value", ctx_r6.displayHour)("ngClass", i0.ɵɵpureFunction1(9, _c0$12, ctx_r6.isInvalid));
422
+ i0.ɵɵattribute("aria-labelledby", "hour-label-" + ctx_r6.hourId());
422
423
  } }
423
424
  function DateInputComponent_div_20_Template(rf, ctx) { if (rf & 1) {
424
425
  const _r8 = i0.ɵɵgetCurrentView();
425
- i0.ɵɵelementStart(0, "div", 17)(1, "label", 8);
426
+ i0.ɵɵelementStart(0, "div", 17)(1, "span", 8);
426
427
  i0.ɵɵtext(2);
427
428
  i0.ɵɵpipe(3, "rpxTranslate");
428
429
  i0.ɵɵelementEnd();
@@ -432,29 +433,39 @@ function DateInputComponent_div_20_Template(rf, ctx) { if (rf & 1) {
432
433
  } if (rf & 2) {
433
434
  const ctx_r6 = i0.ɵɵnextContext();
434
435
  i0.ɵɵadvance();
435
- i0.ɵɵproperty("for", ctx_r6.minuteId());
436
+ i0.ɵɵattribute("id", "minute-label-" + ctx_r6.hourId());
436
437
  i0.ɵɵadvance();
437
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 6, "Minute"));
438
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 7, "Minute"));
438
439
  i0.ɵɵadvance(2);
439
- i0.ɵɵproperty("id", ctx_r6.minuteId())("name", ctx_r6.minuteId())("value", ctx_r6.displayMinute)("ngClass", i0.ɵɵpureFunction1(8, _c0$12, ctx_r6.isInvalid));
440
+ i0.ɵɵproperty("id", ctx_r6.minuteId())("name", ctx_r6.minuteId())("value", ctx_r6.displayMinute)("ngClass", i0.ɵɵpureFunction1(9, _c0$12, ctx_r6.isInvalid));
441
+ i0.ɵɵattribute("aria-labelledby", "minute-label-" + ctx_r6.minuteId());
440
442
  } }
441
443
  function DateInputComponent_div_21_Template(rf, ctx) { if (rf & 1) {
442
444
  const _r10 = i0.ɵɵgetCurrentView();
443
- i0.ɵɵelementStart(0, "div", 18)(1, "label", 8);
445
+ i0.ɵɵelementStart(0, "div", 18)(1, "span", 8);
444
446
  i0.ɵɵtext(2);
445
447
  i0.ɵɵpipe(3, "rpxTranslate");
446
448
  i0.ɵɵelementEnd();
447
- i0.ɵɵelementStart(4, "input", 16, 5);
448
- i0.ɵɵlistener("input", function DateInputComponent_div_21_Template_input_input_4_listener() { i0.ɵɵrestoreView(_r10); const secondInput_r11 = i0.ɵɵreference(5); const ctx_r6 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r6.secondChange(secondInput_r11.value)); })("keyup", function DateInputComponent_div_21_Template_input_keyup_4_listener() { i0.ɵɵrestoreView(_r10); const secondInput_r11 = i0.ɵɵreference(5); const ctx_r6 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r6.secondChange(secondInput_r11.value)); })("focus", function DateInputComponent_div_21_Template_input_focus_4_listener() { i0.ɵɵrestoreView(_r10); const ctx_r6 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r6.inputFocus()); });
449
+ i0.ɵɵelementStart(4, "label", 19);
450
+ i0.ɵɵtext(5);
451
+ i0.ɵɵpipe(6, "rpxTranslate");
452
+ i0.ɵɵelementEnd();
453
+ i0.ɵɵelementStart(7, "input", 16, 5);
454
+ i0.ɵɵlistener("input", function DateInputComponent_div_21_Template_input_input_7_listener() { i0.ɵɵrestoreView(_r10); const secondInput_r11 = i0.ɵɵreference(8); const ctx_r6 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r6.secondChange(secondInput_r11.value)); })("keyup", function DateInputComponent_div_21_Template_input_keyup_7_listener() { i0.ɵɵrestoreView(_r10); const secondInput_r11 = i0.ɵɵreference(8); const ctx_r6 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r6.secondChange(secondInput_r11.value)); })("focus", function DateInputComponent_div_21_Template_input_focus_7_listener() { i0.ɵɵrestoreView(_r10); const ctx_r6 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r6.inputFocus()); });
449
455
  i0.ɵɵelementEnd()();
450
456
  } if (rf & 2) {
451
457
  const ctx_r6 = i0.ɵɵnextContext();
452
458
  i0.ɵɵadvance();
459
+ i0.ɵɵattribute("id", "second-label-" + ctx_r6.secondId());
460
+ i0.ɵɵadvance();
461
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 9, "Second"));
462
+ i0.ɵɵadvance(2);
453
463
  i0.ɵɵproperty("for", ctx_r6.secondId());
454
464
  i0.ɵɵadvance();
455
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(3, 6, "Second"));
465
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(6, 11, "Second"));
456
466
  i0.ɵɵadvance(2);
457
- i0.ɵɵproperty("id", ctx_r6.secondId())("name", ctx_r6.secondId())("value", ctx_r6.displaySecond)("ngClass", i0.ɵɵpureFunction1(8, _c0$12, ctx_r6.isInvalid));
467
+ i0.ɵɵproperty("id", ctx_r6.secondId())("name", ctx_r6.secondId())("value", ctx_r6.displaySecond)("ngClass", i0.ɵɵpureFunction1(13, _c0$12, ctx_r6.isInvalid));
468
+ i0.ɵɵattribute("aria-labelledby", "second-label-" + ctx_r6.secondId());
458
469
  } }
459
470
  class DateInputComponent {
460
471
  id;
@@ -590,22 +601,22 @@ class DateInputComponent {
590
601
  }
591
602
  }
592
603
  dayId() {
593
- return `${this.id}-day`;
604
+ return this.id + '-day';
594
605
  }
595
606
  monthId() {
596
- return `${this.id}-month`;
607
+ return this.id + '-month';
597
608
  }
598
609
  yearId() {
599
- return `${this.id}-year`;
610
+ return this.id + '-year';
600
611
  }
601
612
  hourId() {
602
- return `${this.id}-hour`;
613
+ return this.id + '-hour';
603
614
  }
604
615
  minuteId() {
605
- return `${this.id}-minute`;
616
+ return this.id + '-minute';
606
617
  }
607
618
  secondId() {
608
- return `${this.id}-second`;
619
+ return this.id + '-second';
609
620
  }
610
621
  viewValue() {
611
622
  if (this.day || this.month || this.year || this.hour || this.minute || this.second) {
@@ -658,50 +669,53 @@ class DateInputComponent {
658
669
  useExisting: forwardRef(() => DateInputComponent),
659
670
  multi: true
660
671
  }
661
- ])], decls: 22, vars: 33, consts: [["dayInput", ""], ["monthInput", ""], ["yearInput", ""], ["hourInput", ""], ["minuteInput", ""], ["secondInput", ""], [1, "form-date"], [1, "form-group", "form-group-day"], [1, "form-label", 3, "for"], ["type", "text", "pattern", "[0-9]*", "inputmode", "numeric", 1, "form-control", 3, "change", "keyup", "focus", "id", "name", "value", "ngClass"], [1, "form-group", "form-group-month"], [1, "form-group", "form-group-year"], ["class", "form-group form-group-hour", 4, "ngIf"], ["class", "form-group form-group-minute", 4, "ngIf"], ["class", "form-group form-group-second", 4, "ngIf"], [1, "form-group", "form-group-hour"], ["type", "number", 1, "form-control", 3, "input", "keyup", "focus", "id", "name", "value", "ngClass"], [1, "form-group", "form-group-minute"], [1, "form-group", "form-group-second"]], template: function DateInputComponent_Template(rf, ctx) { if (rf & 1) {
672
+ ])], decls: 22, vars: 36, consts: [["dayInput", ""], ["monthInput", ""], ["yearInput", ""], ["hourInput", ""], ["minuteInput", ""], ["secondInput", ""], [1, "form-date"], [1, "form-group", "form-group-day"], [1, "form-label"], ["type", "text", "pattern", "[0-9]*", "inputmode", "numeric", 1, "form-control", 3, "change", "keyup", "focus", "id", "name", "value", "ngClass"], [1, "form-group", "form-group-month"], [1, "form-group", "form-group-year"], ["class", "form-group form-group-hour", 4, "ngIf"], ["class", "form-group form-group-minute", 4, "ngIf"], ["class", "form-group form-group-second", 4, "ngIf"], [1, "form-group", "form-group-hour"], ["type", "number", 1, "form-control", 3, "input", "keyup", "focus", "id", "name", "value", "ngClass"], [1, "form-group", "form-group-minute"], [1, "form-group", "form-group-second"], [1, "form-label", 3, "for"]], template: function DateInputComponent_Template(rf, ctx) { if (rf & 1) {
662
673
  const _r1 = i0.ɵɵgetCurrentView();
663
- i0.ɵɵelementStart(0, "div", 6)(1, "div", 7)(2, "label", 8);
674
+ i0.ɵɵelementStart(0, "div", 6)(1, "div", 7)(2, "span", 8);
664
675
  i0.ɵɵtext(3);
665
676
  i0.ɵɵpipe(4, "rpxTranslate");
666
677
  i0.ɵɵelementEnd();
667
678
  i0.ɵɵelementStart(5, "input", 9, 0);
668
679
  i0.ɵɵlistener("change", function DateInputComponent_Template_input_change_5_listener() { i0.ɵɵrestoreView(_r1); const dayInput_r2 = i0.ɵɵreference(6); return i0.ɵɵresetView(ctx.dayChange(dayInput_r2.value)); })("keyup", function DateInputComponent_Template_input_keyup_5_listener() { i0.ɵɵrestoreView(_r1); const dayInput_r2 = i0.ɵɵreference(6); return i0.ɵɵresetView(ctx.dayChange(dayInput_r2.value)); })("focus", function DateInputComponent_Template_input_focus_5_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.inputFocus()); });
669
680
  i0.ɵɵelementEnd()();
670
- i0.ɵɵelementStart(7, "div", 10)(8, "label", 8);
681
+ i0.ɵɵelementStart(7, "div", 10)(8, "span", 8);
671
682
  i0.ɵɵtext(9);
672
683
  i0.ɵɵpipe(10, "rpxTranslate");
673
684
  i0.ɵɵelementEnd();
674
685
  i0.ɵɵelementStart(11, "input", 9, 1);
675
686
  i0.ɵɵlistener("change", function DateInputComponent_Template_input_change_11_listener() { i0.ɵɵrestoreView(_r1); const monthInput_r3 = i0.ɵɵreference(12); return i0.ɵɵresetView(ctx.monthChange(monthInput_r3.value)); })("keyup", function DateInputComponent_Template_input_keyup_11_listener() { i0.ɵɵrestoreView(_r1); const monthInput_r3 = i0.ɵɵreference(12); return i0.ɵɵresetView(ctx.monthChange(monthInput_r3.value)); })("focus", function DateInputComponent_Template_input_focus_11_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.inputFocus()); });
676
687
  i0.ɵɵelementEnd()();
677
- i0.ɵɵelementStart(13, "div", 11)(14, "label", 8);
688
+ i0.ɵɵelementStart(13, "div", 11)(14, "span", 8);
678
689
  i0.ɵɵtext(15);
679
690
  i0.ɵɵpipe(16, "rpxTranslate");
680
691
  i0.ɵɵelementEnd();
681
692
  i0.ɵɵelementStart(17, "input", 9, 2);
682
693
  i0.ɵɵlistener("change", function DateInputComponent_Template_input_change_17_listener() { i0.ɵɵrestoreView(_r1); const yearInput_r4 = i0.ɵɵreference(18); return i0.ɵɵresetView(ctx.yearChange(yearInput_r4.value)); })("keyup", function DateInputComponent_Template_input_keyup_17_listener() { i0.ɵɵrestoreView(_r1); const yearInput_r4 = i0.ɵɵreference(18); return i0.ɵɵresetView(ctx.yearChange(yearInput_r4.value)); })("focus", function DateInputComponent_Template_input_focus_17_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.inputFocus()); });
683
694
  i0.ɵɵelementEnd()();
684
- i0.ɵɵtemplate(19, DateInputComponent_div_19_Template, 6, 10, "div", 12)(20, DateInputComponent_div_20_Template, 6, 10, "div", 13)(21, DateInputComponent_div_21_Template, 6, 10, "div", 14);
695
+ i0.ɵɵtemplate(19, DateInputComponent_div_19_Template, 6, 11, "div", 12)(20, DateInputComponent_div_20_Template, 6, 11, "div", 13)(21, DateInputComponent_div_21_Template, 9, 15, "div", 14);
685
696
  i0.ɵɵelementEnd();
686
697
  } if (rf & 2) {
687
698
  i0.ɵɵadvance(2);
688
- i0.ɵɵproperty("for", ctx.dayId());
699
+ i0.ɵɵattribute("id", "day-label-" + ctx.dayId());
689
700
  i0.ɵɵadvance();
690
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(4, 21, "Day"));
701
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(4, 24, "Day"));
691
702
  i0.ɵɵadvance(2);
692
- i0.ɵɵproperty("id", ctx.dayId())("name", ctx.dayId())("value", ctx.displayDay)("ngClass", i0.ɵɵpureFunction1(27, _c0$12, ctx.isInvalid));
703
+ i0.ɵɵproperty("id", ctx.dayId())("name", ctx.dayId())("value", ctx.displayDay)("ngClass", i0.ɵɵpureFunction1(30, _c0$12, ctx.isInvalid));
704
+ i0.ɵɵattribute("aria-labelledby", "day-label-" + ctx.dayId());
693
705
  i0.ɵɵadvance(3);
694
- i0.ɵɵproperty("for", ctx.monthId());
706
+ i0.ɵɵattribute("id", "month-label-" + ctx.monthId());
695
707
  i0.ɵɵadvance();
696
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(10, 23, "Month"));
708
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(10, 26, "Month"));
697
709
  i0.ɵɵadvance(2);
698
- i0.ɵɵproperty("id", ctx.monthId())("name", ctx.monthId())("value", ctx.displayMonth)("ngClass", i0.ɵɵpureFunction1(29, _c0$12, ctx.isInvalid));
710
+ i0.ɵɵproperty("id", ctx.monthId())("name", ctx.monthId())("value", ctx.displayMonth)("ngClass", i0.ɵɵpureFunction1(32, _c0$12, ctx.isInvalid));
711
+ i0.ɵɵattribute("aria-labelledby", "month-label-" + ctx.monthId());
699
712
  i0.ɵɵadvance(3);
700
- i0.ɵɵproperty("for", ctx.yearId());
713
+ i0.ɵɵattribute("id", "year-label-" + ctx.yearId());
701
714
  i0.ɵɵadvance();
702
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(16, 25, "Year"));
715
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(16, 28, "Year"));
703
716
  i0.ɵɵadvance(2);
704
- i0.ɵɵproperty("id", ctx.yearId())("name", ctx.yearId())("value", ctx.displayYear)("ngClass", i0.ɵɵpureFunction1(31, _c0$12, ctx.isInvalid));
717
+ i0.ɵɵproperty("id", ctx.yearId())("name", ctx.yearId())("value", ctx.displayYear)("ngClass", i0.ɵɵpureFunction1(34, _c0$12, ctx.isInvalid));
718
+ i0.ɵɵattribute("aria-labelledby", "year-label-" + ctx.yearId());
705
719
  i0.ɵɵadvance(2);
706
720
  i0.ɵɵproperty("ngIf", ctx.isDateTime);
707
721
  i0.ɵɵadvance();
@@ -723,7 +737,7 @@ class DateInputComponent {
723
737
  useExisting: forwardRef(() => DateInputComponent),
724
738
  multi: true
725
739
  }
726
- ], template: "<div class=\"form-date\">\n <div class=\"form-group form-group-day\">\n <label class=\"form-label\" [for]=\"dayId()\">{{'Day' | rpxTranslate}}</label>\n <input #dayInput\n class=\"form-control\"\n [id]=\"dayId()\"\n [name]=\"dayId()\"\n type=\"text\"\n pattern=\"[0-9]*\"\n inputmode=\"numeric\"\n [value]=\"displayDay\"\n (change)=\"dayChange(dayInput.value)\"\n (keyup)=\"dayChange(dayInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-month\">\n <label class=\"form-label\" [for]=\"monthId()\">{{'Month' | rpxTranslate}}</label>\n <input #monthInput\n class=\"form-control\"\n [id]=\"monthId()\"\n [name]=\"monthId()\"\n type=\"text\"\n pattern=\"[0-9]*\"\n inputmode=\"numeric\"\n [value]=\"displayMonth\"\n (change)=\"monthChange(monthInput.value)\"\n (keyup)=\"monthChange(monthInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-year\">\n <label class=\"form-label\" [for]=\"yearId()\">{{'Year' | rpxTranslate}}</label>\n <input #yearInput\n class=\"form-control\"\n [id]=\"yearId()\"\n [name]=\"yearId()\"\n type=\"text\"\n pattern=\"[0-9]*\"\n inputmode=\"numeric\"\n [value]=\"displayYear\"\n (change)=\"yearChange(yearInput.value)\"\n (keyup)=\"yearChange(yearInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-hour\" *ngIf=\"isDateTime\">\n <label class=\"form-label\" [for]=\"hourId()\">{{'Hour' | rpxTranslate}}</label>\n <input #hourInput\n class=\"form-control\"\n [id]=\"hourId()\"\n [name]=\"hourId()\"\n type=\"number\"\n [value]=\"displayHour\"\n (input)=\"hourChange(hourInput.value)\"\n (keyup)=\"hourChange(hourInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-minute\" *ngIf=\"isDateTime\">\n <label class=\"form-label\" [for]=\"minuteId()\">{{'Minute' | rpxTranslate}}</label>\n <input #minuteInput\n class=\"form-control\"\n [id]=\"minuteId()\"\n [name]=\"minuteId()\"\n type=\"number\"\n [value]=\"displayMinute\"\n (input)=\"minuteChange(minuteInput.value)\"\n (keyup)=\"minuteChange(minuteInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-second\" *ngIf=\"isDateTime\">\n <label class=\"form-label\" [for]=\"secondId()\">{{'Second' | rpxTranslate}}</label>\n <input #secondInput\n class=\"form-control\"\n [id]=\"secondId()\"\n [name]=\"secondId()\"\n type=\"number\"\n [value]=\"displaySecond\"\n (input)=\"secondChange(secondInput.value)\"\n (keyup)=\"secondChange(secondInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n</div>\n" }]
740
+ ], template: "<div class=\"form-date\">\n <div class=\"form-group form-group-day\">\n <span class=\"form-label\" [attr.id]=\"'day-label-'+dayId()\">{{'Day' | rpxTranslate}}</span>\n <input #dayInput\n class=\"form-control\"\n [id]=\"dayId()\"\n [name]=\"dayId()\"\n type=\"text\"\n pattern=\"[0-9]*\"\n inputmode=\"numeric\"\n [attr.aria-labelledby]=\"'day-label-'+dayId()\"\n [value]=\"displayDay\"\n (change)=\"dayChange(dayInput.value)\"\n (keyup)=\"dayChange(dayInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-month\">\n <span class=\"form-label\" [attr.id]=\"'month-label-'+ monthId()\">{{'Month' | rpxTranslate}}</span>\n <input #monthInput\n class=\"form-control\"\n [id]=\"monthId()\"\n [name]=\"monthId()\"\n type=\"text\"\n pattern=\"[0-9]*\"\n inputmode=\"numeric\"\n [attr.aria-labelledby]=\"'month-label-'+ monthId()\"\n [value]=\"displayMonth\"\n (change)=\"monthChange(monthInput.value)\"\n (keyup)=\"monthChange(monthInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-year\">\n <span class=\"form-label\" [attr.id]=\"'year-label-'+ yearId()\">{{'Year' | rpxTranslate}}</span>\n <input #yearInput\n class=\"form-control\"\n [id]=\"yearId()\"\n [name]=\"yearId()\"\n type=\"text\"\n pattern=\"[0-9]*\"\n inputmode=\"numeric\"\n [attr.aria-labelledby]=\"'year-label-'+ yearId()\"\n [value]=\"displayYear\"\n (change)=\"yearChange(yearInput.value)\"\n (keyup)=\"yearChange(yearInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-hour\" *ngIf=\"isDateTime\">\n <span class=\"form-label\" [attr.id]=\"'hour-label-'+ hourId()\">{{'Hour' | rpxTranslate}}</span>\n <input #hourInput\n class=\"form-control\"\n [id]=\"hourId()\"\n [name]=\"hourId()\"\n type=\"number\"\n [attr.aria-labelledby]=\"'hour-label-'+ hourId()\"\n [value]=\"displayHour\"\n (input)=\"hourChange(hourInput.value)\"\n (keyup)=\"hourChange(hourInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-minute\" *ngIf=\"isDateTime\">\n <span class=\"form-label\" [attr.id]=\"'minute-label-'+ hourId()\">{{'Minute' | rpxTranslate}}</span>\n <input #minuteInput\n class=\"form-control\"\n [id]=\"minuteId()\"\n [name]=\"minuteId()\"\n type=\"number\"\n [attr.aria-labelledby]=\"'minute-label-'+ minuteId()\"\n [value]=\"displayMinute\"\n (input)=\"minuteChange(minuteInput.value)\"\n (keyup)=\"minuteChange(minuteInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n\n <div class=\"form-group form-group-second\" *ngIf=\"isDateTime\">\n <span class=\"form-label\" [attr.id]=\"'second-label-'+ secondId()\">{{'Second' | rpxTranslate}}</span>\n <label class=\"form-label\" [for]=\"secondId()\">{{'Second' | rpxTranslate}}</label>\n <input #secondInput\n class=\"form-control\"\n [id]=\"secondId()\"\n [name]=\"secondId()\"\n type=\"number\"\n [attr.aria-labelledby]=\"'second-label-'+ secondId()\"\n [value]=\"displaySecond\"\n (input)=\"secondChange(secondInput.value)\"\n (keyup)=\"secondChange(secondInput.value)\"\n (focus)=\"inputFocus()\"\n [ngClass]=\"{'govuk-input--error': isInvalid}\">\n </div>\n</div>\n" }]
727
741
  }], null, { id: [{
728
742
  type: Input
729
743
  }], mandatory: [{
@@ -3272,6 +3286,7 @@ class CaseField {
3272
3286
  hiddenCannotChange;
3273
3287
  label;
3274
3288
  order;
3289
+ parent;
3275
3290
  field_type;
3276
3291
  hint_text;
3277
3292
  security_label;
@@ -3394,6 +3409,22 @@ class CaseField {
3394
3409
  }
3395
3410
  return null;
3396
3411
  }
3412
+ // Ascend the hierarchy to get the full path of the field
3413
+ getHierachicalId(curr) {
3414
+ const prefix = curr ? curr + "_" : "";
3415
+ if (prefix.length < 1024) {
3416
+ if (this.parent) {
3417
+ return this.parent.getHierachicalId(prefix + this.id);
3418
+ }
3419
+ else {
3420
+ return prefix + this.id;
3421
+ }
3422
+ }
3423
+ else {
3424
+ console.log("Path too long, possible circular reference in case field hierarchy");
3425
+ return this.id;
3426
+ }
3427
+ }
3397
3428
  set isTranslated(val) {
3398
3429
  this.isTranslatedFlag = val;
3399
3430
  }
@@ -3401,6 +3432,10 @@ class CaseField {
3401
3432
  return this.isTranslatedFlag;
3402
3433
  }
3403
3434
  }
3435
+ __decorate([
3436
+ Exclude(),
3437
+ __metadata("design:type", CaseField)
3438
+ ], CaseField.prototype, "parent", void 0);
3404
3439
  __decorate([
3405
3440
  Type(() => FieldType),
3406
3441
  __metadata("design:type", FieldType)
@@ -3483,6 +3518,12 @@ __decorate([
3483
3518
  __metadata("design:paramtypes", []),
3484
3519
  __metadata("design:returntype", Boolean)
3485
3520
  ], CaseField.prototype, "isCaseLink", null);
3521
+ __decorate([
3522
+ Expose(),
3523
+ __metadata("design:type", Function),
3524
+ __metadata("design:paramtypes", [String]),
3525
+ __metadata("design:returntype", String)
3526
+ ], CaseField.prototype, "getHierachicalId", null);
3486
3527
 
3487
3528
  // @dynamic
3488
3529
  class WizardPage {
@@ -12254,6 +12295,7 @@ class WriteComplexFieldComponent extends AbstractFieldWriteComponent {
12254
12295
  const fieldsFilterPipe = new FieldsFilterPipe();
12255
12296
  this.complexFields = fieldsFilterPipe.transform(this.caseField, true).map(field => {
12256
12297
  if (field && field.id) {
12298
+ field.parent = this.caseField;
12257
12299
  if (!(field instanceof CaseField)) {
12258
12300
  return this.buildField(plainToClassFromExist(new CaseField(), field));
12259
12301
  }
@@ -14195,8 +14237,8 @@ class WriteCaseLinkFieldComponent extends AbstractFieldWriteComponent {
14195
14237
  }] }); })();
14196
14238
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(WriteCaseLinkFieldComponent, { className: "WriteCaseLinkFieldComponent", filePath: "lib/shared/components/palette/case-link/write-case-link-field.component.ts", lineNumber: 11 }); })();
14197
14239
 
14198
- const _c0$T = (a0, a1, a2, a3, a4, a5) => ({ id: a0, label: a1, field_type: a2, display_context_parameter: a3, value: a4, hidden: a5 });
14199
- const _c1$m = (a0, a1, a2, a3, a4) => ({ id: a0, label: a1, field_type: a2, value: a3, hidden: a4 });
14240
+ const _c0$T = (a0, a1, a2, a3, a4, a5, a6) => ({ id: a0, label: a1, field_type: a2, display_context_parameter: a3, value: a4, hidden: a5, parent: a6 });
14241
+ const _c1$m = (a0, a1, a2, a3, a4, a5) => ({ id: a0, label: a1, field_type: a2, value: a3, hidden: a4, parent: a5 });
14200
14242
  function ReadCollectionFieldComponent_table_0_tbody_2_Template(rf, ctx) { if (rf & 1) {
14201
14243
  i0.ɵɵelementStart(0, "tbody")(1, "tr");
14202
14244
  i0.ɵɵelement(2, "th", 4);
@@ -14206,7 +14248,7 @@ function ReadCollectionFieldComponent_table_0_tbody_2_Template(rf, ctx) { if (rf
14206
14248
  } if (rf & 2) {
14207
14249
  const ctx_r0 = i0.ɵɵnextContext(2);
14208
14250
  i0.ɵɵadvance(4);
14209
- i0.ɵɵproperty("caseField", i0.ɵɵpureFunction6(3, _c0$T, ctx_r0.caseField.label, ctx_r0.caseField.label, ctx_r0.caseField.field_type.collection_field_type, ctx_r0.caseField.display_context_parameter, ctx_r0.caseField.value, ctx_r0.caseField.hidden))("context", ctx_r0.context)("topLevelFormGroup", ctx_r0.topLevelFormGroup);
14251
+ i0.ɵɵproperty("caseField", i0.ɵɵpureFunction7(3, _c0$T, ctx_r0.caseField.label, ctx_r0.caseField.label, ctx_r0.caseField.field_type.collection_field_type, ctx_r0.caseField.display_context_parameter, ctx_r0.caseField.value, ctx_r0.caseField.hidden, ctx_r0.caseField))("context", ctx_r0.context)("topLevelFormGroup", ctx_r0.topLevelFormGroup);
14210
14252
  } }
14211
14253
  function ReadCollectionFieldComponent_table_0_tbody_3_tr_1_Template(rf, ctx) { if (rf & 1) {
14212
14254
  i0.ɵɵelementStart(0, "tr")(1, "td");
@@ -14217,11 +14259,11 @@ function ReadCollectionFieldComponent_table_0_tbody_3_tr_1_Template(rf, ctx) { i
14217
14259
  const i_r3 = ctx.index;
14218
14260
  const ctx_r0 = i0.ɵɵnextContext(3);
14219
14261
  i0.ɵɵadvance(2);
14220
- i0.ɵɵproperty("caseField", i0.ɵɵpureFunction5(4, _c1$m, i_r3, ctx_r0.caseField.label + " " + (i_r3 + 1), ctx_r0.caseField.field_type.collection_field_type, item_r2.value, ctx_r0.caseField.hidden))("context", ctx_r0.context)("topLevelFormGroup", ctx_r0.topLevelFormGroup)("idPrefix", ctx_r0.buildIdPrefix(i_r3));
14262
+ i0.ɵɵproperty("caseField", i0.ɵɵpureFunction6(4, _c1$m, i_r3 + "", ctx_r0.caseField.label + " " + (i_r3 + 1), ctx_r0.caseField.field_type.collection_field_type, item_r2.value, ctx_r0.caseField.hidden, ctx_r0.caseField))("context", ctx_r0.context)("topLevelFormGroup", ctx_r0.topLevelFormGroup)("idPrefix", ctx_r0.buildIdPrefix(i_r3));
14221
14263
  } }
14222
14264
  function ReadCollectionFieldComponent_table_0_tbody_3_Template(rf, ctx) { if (rf & 1) {
14223
14265
  i0.ɵɵelementStart(0, "tbody");
14224
- i0.ɵɵtemplate(1, ReadCollectionFieldComponent_table_0_tbody_3_tr_1_Template, 3, 10, "tr", 6);
14266
+ i0.ɵɵtemplate(1, ReadCollectionFieldComponent_table_0_tbody_3_tr_1_Template, 3, 11, "tr", 6);
14225
14267
  i0.ɵɵelementEnd();
14226
14268
  } if (rf & 2) {
14227
14269
  const ctx_r0 = i0.ɵɵnextContext(2);
@@ -14231,7 +14273,7 @@ function ReadCollectionFieldComponent_table_0_tbody_3_Template(rf, ctx) { if (rf
14231
14273
  function ReadCollectionFieldComponent_table_0_Template(rf, ctx) { if (rf & 1) {
14232
14274
  i0.ɵɵelementStart(0, "table", 1);
14233
14275
  i0.ɵɵelementContainerStart(1, 2);
14234
- i0.ɵɵtemplate(2, ReadCollectionFieldComponent_table_0_tbody_2_Template, 5, 10, "tbody", 3)(3, ReadCollectionFieldComponent_table_0_tbody_3_Template, 2, 1, "tbody", 3);
14276
+ i0.ɵɵtemplate(2, ReadCollectionFieldComponent_table_0_tbody_2_Template, 5, 11, "tbody", 3)(3, ReadCollectionFieldComponent_table_0_tbody_3_Template, 2, 1, "tbody", 3);
14235
14277
  i0.ɵɵelementContainerEnd();
14236
14278
  i0.ɵɵelementEnd();
14237
14279
  } if (rf & 2) {
@@ -14266,7 +14308,7 @@ class ReadCollectionFieldComponent extends AbstractFieldReadComponent {
14266
14308
  }
14267
14309
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ReadCollectionFieldComponent, [{
14268
14310
  type: Component,
14269
- args: [{ selector: 'ccd-read-collection-field', template: "<table *ngIf=\"caseField.value && caseField.value.length \" class=\"collection-field-table\" aria-describedby=\"collection table\">\n <ng-container [ngSwitch]=\"isDisplayContextParameterAvailable\">\n <tbody *ngSwitchCase=\"true\">\n <tr>\n <th id=\"hiddenHeader\" style=\"display: none;\"></th>\n <td>\n <ccd-field-read\n [caseField]=\"{\n id: caseField.label,\n label: caseField.label,\n field_type: caseField.field_type.collection_field_type,\n display_context_parameter: caseField.display_context_parameter,\n value: caseField.value,\n hidden: caseField.hidden\n }\"\n [context]=\"context\"\n [topLevelFormGroup]=\"topLevelFormGroup\">\n </ccd-field-read>\n </td>\n </tr>\n </tbody>\n <tbody *ngSwitchCase=\"false\">\n <tr *ngFor=\"let item of caseField.value; let i = index\">\n <td>\n <ccd-field-read\n [caseField]=\"{\n id: i,\n label: caseField.label + ' ' + (i + 1),\n field_type: caseField.field_type.collection_field_type,\n value: item.value,\n hidden: caseField.hidden\n }\"\n [context]=\"context\"\n [topLevelFormGroup]=\"topLevelFormGroup\"\n [idPrefix]=\"buildIdPrefix(i)\">\n </ccd-field-read>\n </td>\n </tr>\n </tbody>\n </ng-container>\n</table>\n", styles: [".collection-field-table tr:first-child>td{padding-top:0}.collection-field-table tr:last-child>td{border-bottom:none}.collection-field-table td.collection-actions{width:1px;white-space:nowrap}.error-spacing{margin-top:10px}.collection-title{height:51px}.float-left{float:left;padding-top:8px}.float-right{float:right}.complex-panel{margin:13px 0;border:1px solid #bfc1c3}.complex-panel .complex-panel-title{background-color:#dee0e2;padding:5px 5px 2px;border-bottom:1px solid #bfc1c3;display:block;color:#0b0c0c;font-family:nta,Arial,sans-serif;font-weight:700;text-transform:none;font-size:16px;line-height:1.25}@media (min-width: 641px){.complex-panel .complex-panel-title{font-size:19px;line-height:1.3157894737}}.complex-panel .complex-panel-table>tbody>tr>th{vertical-align:top}.complex-panel .complex-panel-table>tbody>tr:last-child>th,.complex-panel .complex-panel-table>tbody>tr:last-child>td{border-bottom:none}.complex-panel .complex-panel-simple-field th{padding-left:5px;width:295px}.complex-panel .complex-panel-compound-field td{padding:5px}.collection-indicator{border-left:solid 5px #b1b4b6}\n"] }]
14311
+ args: [{ selector: 'ccd-read-collection-field', template: "<table *ngIf=\"caseField.value && caseField.value.length \" class=\"collection-field-table\" aria-describedby=\"collection table\">\n <ng-container [ngSwitch]=\"isDisplayContextParameterAvailable\">\n <tbody *ngSwitchCase=\"true\">\n <tr>\n <th id=\"hiddenHeader\" style=\"display: none;\"></th>\n <td>\n <ccd-field-read\n [caseField]=\"{\n id: caseField.label,\n label: caseField.label,\n field_type: caseField.field_type.collection_field_type,\n display_context_parameter: caseField.display_context_parameter,\n value: caseField.value,\n hidden: caseField.hidden,\n parent: caseField\n }\"\n [context]=\"context\"\n [topLevelFormGroup]=\"topLevelFormGroup\">\n </ccd-field-read>\n </td>\n </tr>\n </tbody>\n <tbody *ngSwitchCase=\"false\">\n <tr *ngFor=\"let item of caseField.value; let i = index\">\n <td>\n <ccd-field-read\n [caseField]=\"{\n id: i + '',\n label: caseField.label + ' ' + (i + 1),\n field_type: caseField.field_type.collection_field_type,\n value: item.value,\n hidden: caseField.hidden,\n parent: caseField\n }\"\n [context]=\"context\"\n [topLevelFormGroup]=\"topLevelFormGroup\"\n [idPrefix]=\"buildIdPrefix(i)\">\n </ccd-field-read>\n </td>\n </tr>\n </tbody>\n </ng-container>\n</table>\n", styles: [".collection-field-table tr:first-child>td{padding-top:0}.collection-field-table tr:last-child>td{border-bottom:none}.collection-field-table td.collection-actions{width:1px;white-space:nowrap}.error-spacing{margin-top:10px}.collection-title{height:51px}.float-left{float:left;padding-top:8px}.float-right{float:right}.complex-panel{margin:13px 0;border:1px solid #bfc1c3}.complex-panel .complex-panel-title{background-color:#dee0e2;padding:5px 5px 2px;border-bottom:1px solid #bfc1c3;display:block;color:#0b0c0c;font-family:nta,Arial,sans-serif;font-weight:700;text-transform:none;font-size:16px;line-height:1.25}@media (min-width: 641px){.complex-panel .complex-panel-title{font-size:19px;line-height:1.3157894737}}.complex-panel .complex-panel-table>tbody>tr>th{vertical-align:top}.complex-panel .complex-panel-table>tbody>tr:last-child>th,.complex-panel .complex-panel-table>tbody>tr:last-child>td{border-bottom:none}.complex-panel .complex-panel-simple-field th{padding-left:5px;width:295px}.complex-panel .complex-panel-compound-field td{padding:5px}.collection-indicator{border-left:solid 5px #b1b4b6}\n"] }]
14270
14312
  }], null, null); })();
14271
14313
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ReadCollectionFieldComponent, { className: "ReadCollectionFieldComponent", filePath: "lib/shared/components/palette/collection/read-collection-field.component.ts", lineNumber: 10 }); })();
14272
14314
 
@@ -14357,49 +14399,49 @@ function WriteCollectionFieldComponent_h2_8_Template(rf, ctx) { if (rf & 1) {
14357
14399
  i0.ɵɵadvance();
14358
14400
  i0.ɵɵproperty("ngIf", ctx_r0.formArray.errors);
14359
14401
  } }
14360
- function WriteCollectionFieldComponent_div_9_div_1_Template(rf, ctx) { if (rf & 1) {
14402
+ function WriteCollectionFieldComponent_div_9_div_2_Template(rf, ctx) { if (rf & 1) {
14361
14403
  const _r2 = i0.ɵɵgetCurrentView();
14362
- i0.ɵɵelementStart(0, "div", 1, 0)(2, "div", 14)(3, "div", 15)(4, "label", 16)(5, "h3", 17);
14363
- i0.ɵɵtext(6);
14364
- i0.ɵɵpipe(7, "rpxTranslate");
14365
- i0.ɵɵelementEnd()()();
14366
- i0.ɵɵelementStart(8, "div", 18)(9, "button", 19);
14367
- i0.ɵɵlistener("click", function WriteCollectionFieldComponent_div_9_div_1_Template_button_click_9_listener() { const i_r3 = i0.ɵɵrestoreView(_r2).index; const ctx_r0 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r0.openModal(i_r3)); });
14368
- i0.ɵɵtext(10);
14369
- i0.ɵɵpipe(11, "rpxTranslate");
14404
+ i0.ɵɵelementStart(0, "div", 1, 0)(2, "div", 15)(3, "div", 16)(4, "legend", 17)(5, "label", 18)(6, "h3", 19);
14405
+ i0.ɵɵtext(7);
14406
+ i0.ɵɵpipe(8, "rpxTranslate");
14407
+ i0.ɵɵelementEnd()()()();
14408
+ i0.ɵɵelementStart(9, "div", 20)(10, "button", 21);
14409
+ i0.ɵɵlistener("click", function WriteCollectionFieldComponent_div_9_div_2_Template_button_click_10_listener() { const i_r3 = i0.ɵɵrestoreView(_r2).index; const ctx_r0 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r0.openModal(i_r3)); });
14410
+ i0.ɵɵtext(11);
14411
+ i0.ɵɵpipe(12, "rpxTranslate");
14370
14412
  i0.ɵɵelementEnd()()();
14371
- i0.ɵɵelement(12, "ccd-field-write", 20);
14413
+ i0.ɵɵelement(13, "ccd-field-write", 22);
14372
14414
  i0.ɵɵelementEnd();
14373
14415
  } if (rf & 2) {
14374
14416
  const item_r4 = ctx.$implicit;
14375
14417
  const i_r3 = ctx.index;
14376
14418
  const ctx_r0 = i0.ɵɵnextContext(2);
14377
14419
  i0.ɵɵproperty("id", ctx_r0.buildIdPrefix(i_r3) + i_r3);
14378
- i0.ɵɵadvance(4);
14420
+ i0.ɵɵadvance(5);
14379
14421
  i0.ɵɵproperty("for", item_r4.prefix + i_r3);
14380
14422
  i0.ɵɵadvance(2);
14381
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(7, 15, ctx_r0.itemLabel(i_r3)));
14423
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(8, 15, ctx_r0.itemLabel(i_r3)));
14382
14424
  i0.ɵɵadvance(3);
14383
14425
  i0.ɵɵattributeInterpolate1("aria-label", "Remove ", ctx_r0.itemLabel(i_r3), "");
14384
14426
  i0.ɵɵproperty("disabled", ctx_r0.isNotAuthorisedToDelete(i_r3));
14385
14427
  i0.ɵɵadvance();
14386
- i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(11, 17, "Remove"));
14428
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(12, 17, "Remove"));
14387
14429
  i0.ɵɵadvance(2);
14388
14430
  i0.ɵɵproperty("caseField", item_r4.caseField)("caseFields", ctx_r0.caseFields)("formGroup", ctx_r0.formGroup)("parent", item_r4.container)("idPrefix", item_r4.prefix)("hidden", item_r4.caseField.hidden)("isExpanded", ctx_r0.isExpanded)("isInSearchBlock", ctx_r0.isInSearchBlock);
14389
14431
  } }
14390
14432
  function WriteCollectionFieldComponent_div_9_Template(rf, ctx) { if (rf & 1) {
14391
- i0.ɵɵelementStart(0, "div", 12);
14392
- i0.ɵɵtemplate(1, WriteCollectionFieldComponent_div_9_div_1_Template, 13, 19, "div", 13);
14393
- i0.ɵɵelementEnd();
14433
+ i0.ɵɵelementStart(0, "div", 12)(1, "fieldset", 13);
14434
+ i0.ɵɵtemplate(2, WriteCollectionFieldComponent_div_9_div_2_Template, 14, 19, "div", 14);
14435
+ i0.ɵɵelementEnd()();
14394
14436
  } if (rf & 2) {
14395
14437
  const ctx_r0 = i0.ɵɵnextContext();
14396
14438
  i0.ɵɵproperty("hidden", ctx_r0.caseField.hidden);
14397
- i0.ɵɵadvance();
14439
+ i0.ɵɵadvance(2);
14398
14440
  i0.ɵɵproperty("ngForOf", ctx_r0.collItems);
14399
14441
  } }
14400
14442
  function WriteCollectionFieldComponent_button_10_Template(rf, ctx) { if (rf & 1) {
14401
14443
  const _r5 = i0.ɵɵgetCurrentView();
14402
- i0.ɵɵelementStart(0, "button", 21);
14444
+ i0.ɵɵelementStart(0, "button", 23);
14403
14445
  i0.ɵɵlistener("click", function WriteCollectionFieldComponent_button_10_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r5); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.addItem(false)); });
14404
14446
  i0.ɵɵtext(1);
14405
14447
  i0.ɵɵpipe(2, "rpxTranslate");
@@ -14438,6 +14480,7 @@ class WriteCollectionFieldComponent extends AbstractFieldWriteComponent {
14438
14480
  this.caseField.value.forEach((item, index) => {
14439
14481
  const prefix = this.buildIdPrefix(index);
14440
14482
  const caseField = this.buildCaseField(item, index);
14483
+ caseField.parent = this.caseField;
14441
14484
  const container = this.getContainer(index);
14442
14485
  if (this.collItems.length <= index) {
14443
14486
  this.collItems.length = index + 1;
@@ -14716,7 +14759,7 @@ class WriteCollectionFieldComponent extends AbstractFieldWriteComponent {
14716
14759
  } if (rf & 2) {
14717
14760
  let _t;
14718
14761
  i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.items = _t);
14719
- } }, inputs: { caseFields: "caseFields" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 11, vars: 11, consts: [["collectionItem", ""], [1, "form-group", 3, "id"], [1, "panel", "collection-indicator"], [1, "heading-h2", "error-spacing"], ["type", "button", 1, "button", "write-collection-add-item__top", 3, "click", "disabled"], ["class", "heading-h2 error-spacing", 4, "ngIf"], ["class", "form-group", 3, "hidden", 4, "ngIf"], ["class", "button write-collection-add-item__bottom", "type", "button", 3, "disabled", "click", 4, "ngIf"], ["class", "form-hint", 4, "ngIf"], ["class", "error-message", 4, "ngIf"], [1, "form-hint"], [1, "error-message"], [1, "form-group", 3, "hidden"], ["class", "form-group", 3, "id", 4, "ngFor", "ngForOf"], [1, "collection-title"], [1, "float-left"], [3, "for"], [1, "heading-h3"], [1, "float-right"], ["type", "button", 1, "button", "button-secondary", 3, "click", "disabled"], [3, "caseField", "caseFields", "formGroup", "parent", "idPrefix", "hidden", "isExpanded", "isInSearchBlock"], ["type", "button", 1, "button", "write-collection-add-item__bottom", 3, "click", "disabled"]], template: function WriteCollectionFieldComponent_Template(rf, ctx) { if (rf & 1) {
14762
+ } }, inputs: { caseFields: "caseFields" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 11, vars: 11, consts: [["collectionItem", ""], [1, "form-group", 3, "id"], [1, "panel", "collection-indicator"], [1, "heading-h2", "error-spacing"], ["type", "button", 1, "button", "write-collection-add-item__top", 3, "click", "disabled"], ["class", "heading-h2 error-spacing", 4, "ngIf"], ["class", "form-group", 3, "hidden", 4, "ngIf"], ["class", "button write-collection-add-item__bottom", "type", "button", 3, "disabled", "click", 4, "ngIf"], ["class", "form-hint", 4, "ngIf"], ["class", "error-message", 4, "ngIf"], [1, "form-hint"], [1, "error-message"], [1, "form-group", 3, "hidden"], [1, "govuk-fieldset"], ["class", "form-group", 3, "id", 4, "ngFor", "ngForOf"], [1, "collection-title"], [1, "float-left"], [1, "govuk-fieldset__legend"], [3, "for"], [1, "heading-h3"], [1, "float-right"], ["type", "button", 1, "button", "button-secondary", 3, "click", "disabled"], [3, "caseField", "caseFields", "formGroup", "parent", "idPrefix", "hidden", "isExpanded", "isInSearchBlock"], ["type", "button", 1, "button", "write-collection-add-item__bottom", 3, "click", "disabled"]], template: function WriteCollectionFieldComponent_Template(rf, ctx) { if (rf & 1) {
14720
14763
  i0.ɵɵelementStart(0, "div", 1)(1, "div", 2)(2, "h2", 3);
14721
14764
  i0.ɵɵtext(3);
14722
14765
  i0.ɵɵpipe(4, "ccdFieldLabel");
@@ -14726,7 +14769,7 @@ class WriteCollectionFieldComponent extends AbstractFieldWriteComponent {
14726
14769
  i0.ɵɵtext(6);
14727
14770
  i0.ɵɵpipe(7, "rpxTranslate");
14728
14771
  i0.ɵɵelementEnd();
14729
- i0.ɵɵtemplate(8, WriteCollectionFieldComponent_h2_8_Template, 3, 2, "h2", 5)(9, WriteCollectionFieldComponent_div_9_Template, 2, 2, "div", 6)(10, WriteCollectionFieldComponent_button_10_Template, 3, 4, "button", 7);
14772
+ i0.ɵɵtemplate(8, WriteCollectionFieldComponent_h2_8_Template, 3, 2, "h2", 5)(9, WriteCollectionFieldComponent_div_9_Template, 3, 2, "div", 6)(10, WriteCollectionFieldComponent_button_10_Template, 3, 4, "button", 7);
14730
14773
  i0.ɵɵelementEnd()();
14731
14774
  } if (rf & 2) {
14732
14775
  i0.ɵɵproperty("id", ctx.id());
@@ -14746,7 +14789,7 @@ class WriteCollectionFieldComponent extends AbstractFieldWriteComponent {
14746
14789
  }
14747
14790
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(WriteCollectionFieldComponent, [{
14748
14791
  type: Component,
14749
- args: [{ selector: 'ccd-write-collection-field', template: "<div class=\"form-group\" [id]=\"id()\">\n\n <div class=\"panel collection-indicator\">\n\n <h2 class=\"heading-h2 error-spacing\">\n {{(caseField | ccdFieldLabel)}}\n </h2>\n <button class=\"button write-collection-add-item__top\" type=\"button\" (click)=\"addItem(true)\" [disabled]=\"isNotAuthorisedToCreate() || isSearchFilter()\">{{'Add new' | rpxTranslate}}</button>\n <h2 class=\"heading-h2 error-spacing\" *ngIf=\"caseField.hint_text || formArray.errors\">\n <span *ngIf=\"caseField.hint_text\" class=\"form-hint\">\n <markdown>{{caseField.hint_text | rpxTranslate }}</markdown>\n </span>\n <span *ngIf=\"formArray.errors\" class=\"error-message\">\n {{(formArray.errors | ccdFirstError:caseField.label)}}\n </span>\n </h2>\n\n <div class=\"form-group\" [hidden]=\"caseField.hidden\" *ngIf=\"caseField.value && caseField.value.length\">\n <div *ngFor=\"let item of collItems; let i = index\" #collectionItem\n [id]=\"this.buildIdPrefix(i) + i\" class=\"form-group\">\n <div class=\"collection-title\">\n <div class=\"float-left\">\n <label [for]=\"item.prefix + i\"><h3 class=\"heading-h3\">{{itemLabel(i) | rpxTranslate}}</h3></label>\n </div>\n <div class=\"float-right\">\n <button class=\"button button-secondary\" type=\"button\" (click)=\"openModal(i)\"\n [disabled]=\"isNotAuthorisedToDelete(i)\"\n attr.aria-label=\"Remove {{ itemLabel(i) }}\">{{'Remove' | rpxTranslate}}</button>\n </div>\n </div>\n <ccd-field-write [caseField]=\"item.caseField\"\n [caseFields]=\"caseFields\"\n [formGroup]=\"formGroup\"\n [parent]=\"item.container\"\n [idPrefix]=\"item.prefix\"\n [hidden]=\"item.caseField.hidden\"\n [isExpanded]=\"isExpanded\"\n [isInSearchBlock]=\"isInSearchBlock\">\n </ccd-field-write>\n </div>\n\n </div>\n\n <button class=\"button write-collection-add-item__bottom\" type=\"button\" (click)=\"addItem(false)\" [disabled]=\"isNotAuthorisedToCreate() || isSearchFilter()\" *ngIf=\"caseField.value && caseField.value.length\">{{'Add new' | rpxTranslate }}</button>\n\n </div>\n\n</div>\n", styles: [".collection-field-table tr:first-child>td{padding-top:0}.collection-field-table tr:last-child>td{border-bottom:none}.collection-field-table td.collection-actions{width:1px;white-space:nowrap}.error-spacing{margin-top:10px}.collection-title{height:51px}.float-left{float:left;padding-top:8px}.float-right{float:right}.complex-panel{margin:13px 0;border:1px solid #bfc1c3}.complex-panel .complex-panel-title{background-color:#dee0e2;padding:5px 5px 2px;border-bottom:1px solid #bfc1c3;display:block;color:#0b0c0c;font-family:nta,Arial,sans-serif;font-weight:700;text-transform:none;font-size:16px;line-height:1.25}@media (min-width: 641px){.complex-panel .complex-panel-title{font-size:19px;line-height:1.3157894737}}.complex-panel .complex-panel-table>tbody>tr>th{vertical-align:top}.complex-panel .complex-panel-table>tbody>tr:last-child>th,.complex-panel .complex-panel-table>tbody>tr:last-child>td{border-bottom:none}.complex-panel .complex-panel-simple-field th{padding-left:5px;width:295px}.complex-panel .complex-panel-compound-field td{padding:5px}.collection-indicator{border-left:solid 5px #b1b4b6}\n"] }]
14792
+ args: [{ selector: 'ccd-write-collection-field', template: "<div class=\"form-group\" [id]=\"id()\">\n\n <div class=\"panel collection-indicator\">\n\n <h2 class=\"heading-h2 error-spacing\">\n {{(caseField | ccdFieldLabel)}}\n </h2>\n <button class=\"button write-collection-add-item__top\" type=\"button\" (click)=\"addItem(true)\" [disabled]=\"isNotAuthorisedToCreate() || isSearchFilter()\">{{'Add new' | rpxTranslate}}</button>\n <h2 class=\"heading-h2 error-spacing\" *ngIf=\"caseField.hint_text || formArray.errors\">\n <span *ngIf=\"caseField.hint_text\" class=\"form-hint\">\n <markdown>{{caseField.hint_text | rpxTranslate }}</markdown>\n </span>\n <span *ngIf=\"formArray.errors\" class=\"error-message\">\n {{(formArray.errors | ccdFirstError:caseField.label)}}\n </span>\n </h2>\n\n <div class=\"form-group\" [hidden]=\"caseField.hidden\" *ngIf=\"caseField.value && caseField.value.length\">\n <fieldset class=\"govuk-fieldset\">\n <div *ngFor=\"let item of collItems; let i = index\" #collectionItem\n [id]=\"this.buildIdPrefix(i) + i\" class=\"form-group\">\n <div class=\"collection-title\">\n <div class=\"float-left\">\n <legend class=\"govuk-fieldset__legend\">\n <label [for]=\"item.prefix + i\"><h3 class=\"heading-h3\">{{itemLabel(i) | rpxTranslate}}</h3></label>\n </legend>\n </div>\n <div class=\"float-right\">\n <button class=\"button button-secondary\" type=\"button\" (click)=\"openModal(i)\"\n [disabled]=\"isNotAuthorisedToDelete(i)\"\n attr.aria-label=\"Remove {{ itemLabel(i) }}\">{{'Remove' | rpxTranslate}}</button>\n </div>\n </div>\n <ccd-field-write [caseField]=\"item.caseField\"\n [caseFields]=\"caseFields\"\n [formGroup]=\"formGroup\"\n [parent]=\"item.container\"\n [idPrefix]=\"item.prefix\"\n [hidden]=\"item.caseField.hidden\"\n [isExpanded]=\"isExpanded\"\n [isInSearchBlock]=\"isInSearchBlock\">\n </ccd-field-write>\n </div>\n </fieldset>\n </div>\n\n <button class=\"button write-collection-add-item__bottom\" type=\"button\" (click)=\"addItem(false)\" [disabled]=\"isNotAuthorisedToCreate() || isSearchFilter()\" *ngIf=\"caseField.value && caseField.value.length\">{{'Add new' | rpxTranslate }}</button>\n\n </div>\n\n</div>\n", styles: [".collection-field-table tr:first-child>td{padding-top:0}.collection-field-table tr:last-child>td{border-bottom:none}.collection-field-table td.collection-actions{width:1px;white-space:nowrap}.error-spacing{margin-top:10px}.collection-title{height:51px}.float-left{float:left;padding-top:8px}.float-right{float:right}.complex-panel{margin:13px 0;border:1px solid #bfc1c3}.complex-panel .complex-panel-title{background-color:#dee0e2;padding:5px 5px 2px;border-bottom:1px solid #bfc1c3;display:block;color:#0b0c0c;font-family:nta,Arial,sans-serif;font-weight:700;text-transform:none;font-size:16px;line-height:1.25}@media (min-width: 641px){.complex-panel .complex-panel-title{font-size:19px;line-height:1.3157894737}}.complex-panel .complex-panel-table>tbody>tr>th{vertical-align:top}.complex-panel .complex-panel-table>tbody>tr:last-child>th,.complex-panel .complex-panel-table>tbody>tr:last-child>td{border-bottom:none}.complex-panel .complex-panel-simple-field th{padding-left:5px;width:295px}.complex-panel .complex-panel-compound-field td{padding:5px}.collection-indicator{border-left:solid 5px #b1b4b6}\n"] }]
14750
14793
  }], () => [{ type: i1$3.MatLegacyDialog }, { type: i2.ScrollToService }, { type: ProfileNotifier }, { type: i0.ChangeDetectorRef }], { caseFields: [{
14751
14794
  type: Input
14752
14795
  }], items: [{
@@ -14789,6 +14832,9 @@ class ReadComplexFieldComponent extends AbstractFieldReadComponent {
14789
14832
  }
14790
14833
  if (this.caseField?.field_type && this.caseField.field_type.complex_fields) {
14791
14834
  this.caseField?.field_type?.complex_fields?.forEach((field) => {
14835
+ if (field && this.caseField) {
14836
+ field.parent = this.caseField;
14837
+ }
14792
14838
  if (field?.isDynamic()) {
14793
14839
  field.list_items = this.caseField.value[field.id]?.list_items;
14794
14840
  field.value = {
@@ -22115,7 +22161,7 @@ class QueryWriteAddDocumentsComponent {
22115
22161
  this.mockDocumentCaseField = Object.assign(new CaseField(), {
22116
22162
  id: QueryWriteAddDocumentsComponent.DOCUMENTS_FORM_CONTROL_NAME,
22117
22163
  label: this.label ? this.label : 'Attach a document',
22118
- hint_text: this.hintText,
22164
+ hint_text: this.hintText ? this.hintText : 'Only attach documents related to your query. For all other documents use your case management document upload function.',
22119
22165
  display_context: 'OPTIONAL',
22120
22166
  display_context_parameter: '#COLLECTION(allowInsert,allowUpdate)',
22121
22167
  field_type: Object.assign(new FieldType(), {
@@ -23502,7 +23548,7 @@ class FieldReadComponent extends AbstractFieldReadComponent {
23502
23548
  const componentClass = this.paletteService.getFieldComponentClass(this.caseField, false);
23503
23549
  const injector = Injector.create({
23504
23550
  providers: [],
23505
- parent: this.fieldContainer.injector
23551
+ parent: this.fieldContainer?.injector
23506
23552
  });
23507
23553
  const component = this.resolver.resolveComponentFactory(componentClass).create(injector);
23508
23554
  // Provide component @Inputs
@@ -23523,7 +23569,7 @@ class FieldReadComponent extends AbstractFieldReadComponent {
23523
23569
  component.instance['caseReference'] = this.caseReference;
23524
23570
  component.instance['context'] = this.context;
23525
23571
  component.instance['labelCanBeTranslated'] = this.labelCanBeTranslated(this.caseField);
23526
- this.fieldContainer.insert(component.hostView);
23572
+ this.fieldContainer?.insert(component.hostView);
23527
23573
  });
23528
23574
  }
23529
23575
  labelCanBeTranslated(caseField) {
@@ -23871,7 +23917,7 @@ function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_1_Template(
23871
23917
  i0.ɵɵadvance(2);
23872
23918
  i0.ɵɵtextInterpolate(ctx_r1.title);
23873
23919
  } }
23874
- function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_2_img_2_Template(rf, ctx) { if (rf & 1) {
23920
+ function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_3_img_2_Template(rf, ctx) { if (rf & 1) {
23875
23921
  i0.ɵɵelement(0, "img", 10);
23876
23922
  } if (rf & 2) {
23877
23923
  const item_r4 = i0.ɵɵnextContext().$implicit;
@@ -23879,35 +23925,34 @@ function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_2_img_2_Tem
23879
23925
  i0.ɵɵpropertyInterpolate1("alt", "", ctx_r1.title, " icon'");
23880
23926
  i0.ɵɵproperty("src", item_r4.iconSrc, i0.ɵɵsanitizeUrl);
23881
23927
  } }
23882
- function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_2_Template(rf, ctx) { if (rf & 1) {
23928
+ function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_3_Template(rf, ctx) { if (rf & 1) {
23883
23929
  const _r3 = i0.ɵɵgetCurrentView();
23884
23930
  i0.ɵɵelementContainerStart(0);
23885
- i0.ɵɵelementStart(1, "div", 7);
23886
- i0.ɵɵlistener("click", function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_2_Template_div_click_1_listener() { const item_r4 = i0.ɵɵrestoreView(_r3).$implicit; const ctx_r1 = i0.ɵɵnextContext(2); item_r4.actionFn(); return i0.ɵɵresetView(ctx_r1.closeOverlay()); })("keyup", function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_2_Template_div_keyup_1_listener($event) { const item_r4 = i0.ɵɵrestoreView(_r3).$implicit; const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView($event.key === "Enter" ? ctx_r1.actionAndClose(item_r4.actionFn()) : null); });
23887
- i0.ɵɵtemplate(2, CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_2_img_2_Template, 1, 3, "img", 8);
23931
+ i0.ɵɵelementStart(1, "li", 7);
23932
+ i0.ɵɵlistener("click", function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_3_Template_li_click_1_listener() { const item_r4 = i0.ɵɵrestoreView(_r3).$implicit; const ctx_r1 = i0.ɵɵnextContext(2); item_r4.actionFn(); return i0.ɵɵresetView(ctx_r1.closeOverlay()); })("keydown.enter", function CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_3_Template_li_keydown_enter_1_listener() { const item_r4 = i0.ɵɵrestoreView(_r3).$implicit; const ctx_r1 = i0.ɵɵnextContext(2); item_r4.actionFn(); return i0.ɵɵresetView(ctx_r1.closeOverlay()); });
23933
+ i0.ɵɵtemplate(2, CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_3_img_2_Template, 1, 3, "img", 8);
23888
23934
  i0.ɵɵelementStart(3, "span", 9);
23889
23935
  i0.ɵɵtext(4);
23890
23936
  i0.ɵɵelementEnd()();
23891
23937
  i0.ɵɵelementContainerEnd();
23892
23938
  } if (rf & 2) {
23893
23939
  const item_r4 = ctx.$implicit;
23894
- const i_r5 = ctx.index;
23895
- i0.ɵɵadvance();
23896
- i0.ɵɵproperty("id", "overlay-menu__item" + i_r5);
23897
- i0.ɵɵadvance();
23940
+ i0.ɵɵadvance(2);
23898
23941
  i0.ɵɵproperty("ngIf", item_r4.iconSrc);
23899
23942
  i0.ɵɵadvance(2);
23900
23943
  i0.ɵɵtextInterpolate(item_r4.actionText);
23901
23944
  } }
23902
23945
  function CaseFileViewOverlayMenuComponent_ng_template_4_Template(rf, ctx) { if (rf & 1) {
23903
23946
  i0.ɵɵelementStart(0, "div", 3);
23904
- i0.ɵɵtemplate(1, CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_1_Template, 3, 1, "ng-container", 4)(2, CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_2_Template, 5, 3, "ng-container", 5);
23905
- i0.ɵɵelementEnd();
23947
+ i0.ɵɵtemplate(1, CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_1_Template, 3, 1, "ng-container", 4);
23948
+ i0.ɵɵelementStart(2, "ul");
23949
+ i0.ɵɵtemplate(3, CaseFileViewOverlayMenuComponent_ng_template_4_ng_container_3_Template, 5, 2, "ng-container", 5);
23950
+ i0.ɵɵelementEnd()();
23906
23951
  } if (rf & 2) {
23907
23952
  const ctx_r1 = i0.ɵɵnextContext();
23908
23953
  i0.ɵɵadvance();
23909
23954
  i0.ɵɵproperty("ngIf", ctx_r1.title);
23910
- i0.ɵɵadvance();
23955
+ i0.ɵɵadvance(2);
23911
23956
  i0.ɵɵproperty("ngForOf", ctx_r1.menuItems);
23912
23957
  } }
23913
23958
  class CaseFileViewOverlayMenuComponent {
@@ -23920,30 +23965,37 @@ class CaseFileViewOverlayMenuComponent {
23920
23965
  this.isOpen = isOpen;
23921
23966
  this.isOpenChange.emit(isOpen);
23922
23967
  }
23923
- actionAndClose(func) {
23924
- func();
23925
- this.closeOverlay();
23968
+ setOpen() {
23969
+ this.isOpen = !this.isOpen;
23970
+ if (this.isOpen) {
23971
+ setTimeout(() => {
23972
+ const el = document.querySelector('.overlay-menu__item:first-of-type');
23973
+ if (el) {
23974
+ el.focus();
23975
+ }
23976
+ }, 0);
23977
+ }
23926
23978
  }
23927
23979
  static ɵfac = function CaseFileViewOverlayMenuComponent_Factory(t) { return new (t || CaseFileViewOverlayMenuComponent)(); };
23928
- static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CaseFileViewOverlayMenuComponent, selectors: [["ccd-case-file-view-overlay-menu"]], inputs: { title: "title", menuItems: "menuItems", isOpen: "isOpen" }, outputs: { isOpenChange: "isOpenChange" }, ngContentSelectors: _c1$9, decls: 5, vars: 4, consts: [["trigger", "cdkOverlayOrigin"], ["type", "button", "cdkOverlayOrigin", "", 1, "overlay-toggle", 3, "click"], ["cdkConnectedOverlay", "", 3, "backdropClick", "cdkConnectedOverlayOrigin", "cdkConnectedOverlayOpen", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayBackdropClass"], [1, "overlay-menu"], [4, "ngIf"], [4, "ngFor", "ngForOf"], [1, "overlay-menu__title"], ["tabindex", "0", 1, "overlay-menu__item", 3, "click", "keyup", "id"], ["class", "overlay-menu__itemIcon", 3, "src", "alt", 4, "ngIf"], [1, "overlay-menu__actionText"], [1, "overlay-menu__itemIcon", 3, "src", "alt"]], template: function CaseFileViewOverlayMenuComponent_Template(rf, ctx) { if (rf & 1) {
23980
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CaseFileViewOverlayMenuComponent, selectors: [["ccd-case-file-view-overlay-menu"]], inputs: { title: "title", menuItems: "menuItems", isOpen: "isOpen" }, outputs: { isOpenChange: "isOpenChange" }, ngContentSelectors: _c1$9, decls: 5, vars: 4, consts: [["trigger", "cdkOverlayOrigin"], ["type", "button", "cdkOverlayOrigin", "", 1, "overlay-toggle", 3, "click"], ["cdkConnectedOverlay", "", 3, "backdropClick", "cdkConnectedOverlayOrigin", "cdkConnectedOverlayOpen", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayBackdropClass"], [1, "overlay-menu"], [4, "ngIf"], [4, "ngFor", "ngForOf"], [1, "overlay-menu__title"], ["tabindex", "0", 1, "overlay-menu__item", 3, "click", "keydown.enter"], ["class", "overlay-menu__itemIcon", 3, "src", "alt", 4, "ngIf"], [1, "overlay-menu__actionText"], [1, "overlay-menu__itemIcon", 3, "src", "alt"]], template: function CaseFileViewOverlayMenuComponent_Template(rf, ctx) { if (rf & 1) {
23929
23981
  const _r1 = i0.ɵɵgetCurrentView();
23930
23982
  i0.ɵɵprojectionDef(_c0$t);
23931
23983
  i0.ɵɵelementStart(0, "div")(1, "button", 1, 0);
23932
- i0.ɵɵlistener("click", function CaseFileViewOverlayMenuComponent_Template_button_click_1_listener($event) { i0.ɵɵrestoreView(_r1); $event.stopPropagation(); return i0.ɵɵresetView(ctx.isOpen = !ctx.isOpen); });
23984
+ i0.ɵɵlistener("click", function CaseFileViewOverlayMenuComponent_Template_button_click_1_listener($event) { i0.ɵɵrestoreView(_r1); $event.stopPropagation(); return i0.ɵɵresetView(ctx.setOpen()); });
23933
23985
  i0.ɵɵprojection(3);
23934
23986
  i0.ɵɵelementEnd();
23935
- i0.ɵɵtemplate(4, CaseFileViewOverlayMenuComponent_ng_template_4_Template, 3, 2, "ng-template", 2);
23987
+ i0.ɵɵtemplate(4, CaseFileViewOverlayMenuComponent_ng_template_4_Template, 4, 2, "ng-template", 2);
23936
23988
  i0.ɵɵlistener("backdropClick", function CaseFileViewOverlayMenuComponent_Template_ng_template_backdropClick_4_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.closeOverlay()); });
23937
23989
  i0.ɵɵelementEnd();
23938
23990
  } if (rf & 2) {
23939
- const trigger_r6 = i0.ɵɵreference(2);
23991
+ const trigger_r5 = i0.ɵɵreference(2);
23940
23992
  i0.ɵɵadvance(4);
23941
- i0.ɵɵproperty("cdkConnectedOverlayOrigin", trigger_r6)("cdkConnectedOverlayOpen", ctx.isOpen)("cdkConnectedOverlayHasBackdrop", true)("cdkConnectedOverlayBackdropClass", "cdk-overlay-transparent-backdrop");
23993
+ i0.ɵɵproperty("cdkConnectedOverlayOrigin", trigger_r5)("cdkConnectedOverlayOpen", ctx.isOpen)("cdkConnectedOverlayHasBackdrop", true)("cdkConnectedOverlayBackdropClass", "cdk-overlay-transparent-backdrop");
23942
23994
  } }, dependencies: [i5.NgForOf, i5.NgIf, i2$1.CdkConnectedOverlay, i2$1.CdkOverlayOrigin], styles: [".overlay-toggle[_ngcontent-%COMP%]{display:block;background:none;border:0;padding:0 6px;margin-right:-4px;cursor:pointer}.overlay-menu[_ngcontent-%COMP%]{background-color:#fafafa;border:1px solid grey;margin-top:8px;font-size:1rem}.overlay-menu__title[_ngcontent-%COMP%], .overlay-menu__item[_ngcontent-%COMP%]{padding:10px;border-bottom:1px solid grey}.overlay-menu__title[_ngcontent-%COMP%]:last-child, .overlay-menu__item[_ngcontent-%COMP%]:last-child{border:none}.overlay-menu__title[_ngcontent-%COMP%]{padding-left:6px;padding-right:6px}.overlay-menu__item[_ngcontent-%COMP%]{display:flex;align-items:center;cursor:pointer;font-size:.875em}.overlay-menu__item[_ngcontent-%COMP%]:hover{background-color:#fff2cc}.overlay-menu__item[_ngcontent-%COMP%]:focus{border:2px solid #ffbf47}.overlay-menu__itemIcon[_ngcontent-%COMP%]{height:1.25em;width:1.25em;margin-right:6px}"] });
23943
23995
  }
23944
23996
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CaseFileViewOverlayMenuComponent, [{
23945
23997
  type: Component,
23946
- args: [{ selector: 'ccd-case-file-view-overlay-menu', template: "<div>\n <button type=\"button\" class=\"overlay-toggle\"\n (click)=\"$event.stopPropagation(); isOpen = !isOpen\"\n cdkOverlayOrigin #trigger=\"cdkOverlayOrigin\">\n <ng-content select=\"[trigger]\"></ng-content>\n </button>\n\n <ng-template\n cdkConnectedOverlay\n [cdkConnectedOverlayOrigin]=\"trigger\"\n [cdkConnectedOverlayOpen]=\"isOpen\"\n [cdkConnectedOverlayHasBackdrop]=\"true\"\n [cdkConnectedOverlayBackdropClass]=\"'cdk-overlay-transparent-backdrop'\"\n (backdropClick)=\"closeOverlay()\"\n >\n <div class=\"overlay-menu\">\n <ng-container *ngIf=\"title\">\n <div class=\"overlay-menu__title\">{{title}}</div>\n </ng-container>\n\n <ng-container *ngFor=\"let item of menuItems; index as i\">\n <div class=\"overlay-menu__item\" tabindex=\"0\" [id]=\"'overlay-menu__item' + i\" (click)=\"item.actionFn(); closeOverlay();\" (keyup)=\"$event.key === 'Enter' ? actionAndClose(item.actionFn()) : null\">\n <img *ngIf=\"item.iconSrc\" [src]=\"item.iconSrc\" class=\"overlay-menu__itemIcon\" alt=\"{{title}} icon'\" />\n <span class=\"overlay-menu__actionText\">{{item.actionText}}</span>\n </div>\n </ng-container>\n </div>\n </ng-template>\n</div>\n", styles: [".overlay-toggle{display:block;background:none;border:0;padding:0 6px;margin-right:-4px;cursor:pointer}.overlay-menu{background-color:#fafafa;border:1px solid grey;margin-top:8px;font-size:1rem}.overlay-menu__title,.overlay-menu__item{padding:10px;border-bottom:1px solid grey}.overlay-menu__title:last-child,.overlay-menu__item:last-child{border:none}.overlay-menu__title{padding-left:6px;padding-right:6px}.overlay-menu__item{display:flex;align-items:center;cursor:pointer;font-size:.875em}.overlay-menu__item:hover{background-color:#fff2cc}.overlay-menu__item:focus{border:2px solid #ffbf47}.overlay-menu__itemIcon{height:1.25em;width:1.25em;margin-right:6px}\n"] }]
23998
+ args: [{ selector: 'ccd-case-file-view-overlay-menu', template: "<div>\n <button type=\"button\" class=\"overlay-toggle\"\n (click)=\"$event.stopPropagation(); setOpen()\"\n cdkOverlayOrigin #trigger=\"cdkOverlayOrigin\">\n <ng-content select=\"[trigger]\"></ng-content>\n </button>\n\n <ng-template\n cdkConnectedOverlay\n [cdkConnectedOverlayOrigin]=\"trigger\"\n [cdkConnectedOverlayOpen]=\"isOpen\"\n [cdkConnectedOverlayHasBackdrop]=\"true\"\n [cdkConnectedOverlayBackdropClass]=\"'cdk-overlay-transparent-backdrop'\"\n (backdropClick)=\"closeOverlay()\"\n >\n <div class=\"overlay-menu\">\n <ng-container *ngIf=\"title\">\n <div class=\"overlay-menu__title\">{{title}}</div>\n </ng-container>\n\n <ul>\n <ng-container *ngFor=\"let item of menuItems;\">\n <li class=\"overlay-menu__item\" tabindex=\"0\" (click)=\"item.actionFn(); closeOverlay();\" (keydown.enter)=\"item.actionFn(); closeOverlay();\">\n <img *ngIf=\"item.iconSrc\" [src]=\"item.iconSrc\" class=\"overlay-menu__itemIcon\" alt=\"{{title}} icon'\" />\n <span class=\"overlay-menu__actionText\">{{item.actionText}}</span>\n </li>\n </ng-container>\n </ul>\n </div>\n </ng-template>\n</div>\n", styles: [".overlay-toggle{display:block;background:none;border:0;padding:0 6px;margin-right:-4px;cursor:pointer}.overlay-menu{background-color:#fafafa;border:1px solid grey;margin-top:8px;font-size:1rem}.overlay-menu__title,.overlay-menu__item{padding:10px;border-bottom:1px solid grey}.overlay-menu__title:last-child,.overlay-menu__item:last-child{border:none}.overlay-menu__title{padding-left:6px;padding-right:6px}.overlay-menu__item{display:flex;align-items:center;cursor:pointer;font-size:.875em}.overlay-menu__item:hover{background-color:#fff2cc}.overlay-menu__item:focus{border:2px solid #ffbf47}.overlay-menu__itemIcon{height:1.25em;width:1.25em;margin-right:6px}\n"] }]
23947
23999
  }], null, { title: [{
23948
24000
  type: Input
23949
24001
  }], menuItems: [{
@@ -24224,10 +24276,10 @@ function CaseFileViewFolderComponent_div_8_cdk_nested_tree_node_4_Template(rf, c
24224
24276
  i0.ɵɵelementStart(7, "span", 17);
24225
24277
  i0.ɵɵtext(8);
24226
24278
  i0.ɵɵpipe(9, "ccdDate");
24227
- i0.ɵɵelementEnd()();
24279
+ i0.ɵɵelementEnd()()();
24228
24280
  i0.ɵɵelementStart(10, "div", 18)(11, "ccd-case-file-view-folder-document-actions", 19);
24229
24281
  i0.ɵɵlistener("changeFolderAction", function CaseFileViewFolderComponent_div_8_cdk_nested_tree_node_4_Template_ccd_case_file_view_folder_document_actions_changeFolderAction_11_listener() { const node_r2 = i0.ɵɵrestoreView(_r1).$implicit; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.triggerDocumentAction("changeFolder", node_r2)); })("openInANewTabAction", function CaseFileViewFolderComponent_div_8_cdk_nested_tree_node_4_Template_ccd_case_file_view_folder_document_actions_openInANewTabAction_11_listener() { const node_r2 = i0.ɵɵrestoreView(_r1).$implicit; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.triggerDocumentAction("openInANewTab", node_r2)); })("downloadAction", function CaseFileViewFolderComponent_div_8_cdk_nested_tree_node_4_Template_ccd_case_file_view_folder_document_actions_downloadAction_11_listener() { const node_r2 = i0.ɵɵrestoreView(_r1).$implicit; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.triggerDocumentAction("download", node_r2)); })("printAction", function CaseFileViewFolderComponent_div_8_cdk_nested_tree_node_4_Template_ccd_case_file_view_folder_document_actions_printAction_11_listener() { const node_r2 = i0.ɵɵrestoreView(_r1).$implicit; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.triggerDocumentAction("print", node_r2)); });
24230
- i0.ɵɵelementEnd()()()();
24282
+ i0.ɵɵelementEnd()()();
24231
24283
  } if (rf & 2) {
24232
24284
  const node_r2 = ctx.$implicit;
24233
24285
  const ctx_r2 = i0.ɵɵnextContext(2);
@@ -24508,7 +24560,7 @@ class CaseFileViewFolderComponent {
24508
24560
  a.remove();
24509
24561
  }
24510
24562
  static ɵfac = function CaseFileViewFolderComponent_Factory(t) { return new (t || CaseFileViewFolderComponent)(i0.ɵɵdirectiveInject(WindowService), i0.ɵɵdirectiveInject(i1$1.Router), i0.ɵɵdirectiveInject(DocumentManagementService), i0.ɵɵdirectiveInject(i1$3.MatLegacyDialog), i0.ɵɵdirectiveInject(AbstractAppConfig)); };
24511
- static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CaseFileViewFolderComponent, selectors: [["ccd-case-file-view-folder"]], inputs: { categoriesAndDocuments: "categoriesAndDocuments", allowMoving: "allowMoving" }, outputs: { clickedDocument: "clickedDocument", moveDocument: "moveDocument" }, decls: 9, vars: 3, consts: [[1, "document-filter-container"], [1, "form-group", "document-filter", 3, "formGroup"], ["type", "search", "id", "document-search", "name", "documentSearchFormControl", "formControlName", "documentSearchFormControl", "placeholder", "Search by document name", "aria-label", "Search by document name", 1, "form-control", "document-search"], [1, "document-folders-header"], [1, "document-folders-header__title"], [3, "sortAscending", "sortDescending"], ["class", "document-tree-container", 4, "ngIf"], [1, "document-tree-container"], [4, "ngIf"], [3, "dataSource", "treeControl"], ["class", "document-tree-container__node document-tree-container__node--document", 4, "cdkTreeNodeDef"], ["class", "document-tree-container__node document-tree-container__folder", 4, "cdkTreeNodeDef", "cdkTreeNodeDefWhen"], [1, "document-tree-container__node", "document-tree-container__node--document"], [1, "node", 3, "click"], ["disabled", "", 1, "node__icon"], ["src", "/assets/img/case-file-view/case-file-view-document.svg", "alt", "Document icon", 1, "node__iconImg"], [1, "node__name", "node-name-document"], [1, "node__document-upload-timestamp"], [1, "node__document-options"], [3, "changeFolderAction", "openInANewTabAction", "downloadAction", "printAction", "allowMoving"], [1, "document-tree-container__node", "document-tree-container__folder"], ["cdkTreeNodeToggle", "", 1, "node"], [1, "node__icon"], ["alt", "Folder icon", 1, "node__iconImg", 3, "src"], [1, "node__count"], [1, "node__name", "node__name--folder"], ["cdkTreeNodeOutlet", ""]], template: function CaseFileViewFolderComponent_Template(rf, ctx) { if (rf & 1) {
24563
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CaseFileViewFolderComponent, selectors: [["ccd-case-file-view-folder"]], inputs: { categoriesAndDocuments: "categoriesAndDocuments", allowMoving: "allowMoving" }, outputs: { clickedDocument: "clickedDocument", moveDocument: "moveDocument" }, decls: 9, vars: 3, consts: [[1, "document-filter-container"], [1, "form-group", "document-filter", 3, "formGroup"], ["type", "search", "id", "document-search", "name", "documentSearchFormControl", "formControlName", "documentSearchFormControl", "placeholder", "Search by document name", "aria-label", "Search by document name", 1, "form-control", "document-search"], [1, "document-folders-header"], [1, "document-folders-header__title"], [3, "sortAscending", "sortDescending"], ["class", "document-tree-container", 4, "ngIf"], [1, "document-tree-container"], [4, "ngIf"], [3, "dataSource", "treeControl"], ["class", "document-tree-container__node document-tree-container__node--document", 4, "cdkTreeNodeDef"], ["class", "document-tree-container__node document-tree-container__folder", 4, "cdkTreeNodeDef", "cdkTreeNodeDefWhen"], [1, "document-tree-container__node", "document-tree-container__node--document"], [1, "node", "case-file__node", 3, "click"], ["disabled", "", 1, "node__icon"], ["src", "/assets/img/case-file-view/case-file-view-document.svg", "alt", "Document icon", 1, "node__iconImg"], [1, "node__name", "node-name-document"], [1, "node__document-upload-timestamp"], [1, "node__document-options", "case-file__action"], [3, "changeFolderAction", "openInANewTabAction", "downloadAction", "printAction", "allowMoving"], [1, "document-tree-container__node", "document-tree-container__folder"], ["cdkTreeNodeToggle", "", 1, "node"], [1, "node__icon"], ["alt", "Folder icon", 1, "node__iconImg", 3, "src"], [1, "node__count"], [1, "node__name", "node__name--folder"], ["cdkTreeNodeOutlet", ""]], template: function CaseFileViewFolderComponent_Template(rf, ctx) { if (rf & 1) {
24512
24564
  i0.ɵɵelementStart(0, "div", 0)(1, "div", 1);
24513
24565
  i0.ɵɵelement(2, "input", 2);
24514
24566
  i0.ɵɵelementEnd()();
@@ -24526,11 +24578,11 @@ class CaseFileViewFolderComponent {
24526
24578
  i0.ɵɵtextInterpolate1("Documents (", ctx.documentCount, ")");
24527
24579
  i0.ɵɵadvance(3);
24528
24580
  i0.ɵɵproperty("ngIf", ctx.documentTreeData);
24529
- } }, dependencies: [i5.NgIf, i4.DefaultValueAccessor, i4.NgControlStatus, i4.NgControlStatusGroup, i4.FormGroupDirective, i4.FormControlName, i7$1.CdkNestedTreeNode, i7$1.CdkTreeNodeDef, i7$1.CdkTreeNodeToggle, i7$1.CdkTree, i7$1.CdkTreeNodeOutlet, CaseFileViewFolderSortComponent, CaseFileViewFolderDocumentActionsComponent, DatePipe], styles: ["[_nghost-%COMP%]{display:flex;height:100%;flex-direction:column}[_nghost-%COMP%] .document-tree-container[_ngcontent-%COMP%]{flex:1 0}.document-filter-container[_ngcontent-%COMP%]{border-bottom:2px solid #C9C9C9}.document-filter-container[_ngcontent-%COMP%] .document-filter[_ngcontent-%COMP%]{padding:10px}.document-filter-container[_ngcontent-%COMP%] .document-filter[_ngcontent-%COMP%] .document-search[_ngcontent-%COMP%]{background:url(/assets/images/icon-search-black.svg) no-repeat right #fff;background-position-x:calc(100% - 4px);padding-right:30px;width:100%}.document-filter-container[_ngcontent-%COMP%] .documents-title[_ngcontent-%COMP%]{height:30%;margin-left:8px;font-weight:700}.document-tree-container[_ngcontent-%COMP%]{padding:4px;overflow-x:hidden;overflow-y:scroll}.document-tree-container__node[_ngcontent-%COMP%]{display:block}.document-tree-container__node[_ngcontent-%COMP%] .document-tree-container__node[_ngcontent-%COMP%]{padding-left:40px}.document-tree-container[_ngcontent-%COMP%] .document-tree-invisible[_ngcontent-%COMP%]{display:none}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar{width:7px}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{border:4px solid rgba(0,0,0,0);background-clip:padding-box;border-radius:9999px;background-color:#aaa}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar-button{display:none}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar-track-piece{background:#eee}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:#ccc}.document-folders-header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;border-bottom:2px solid #C9C9C9;padding:10px}.document-folders-header__title[_ngcontent-%COMP%]{font-weight:700}.node[_ngcontent-%COMP%]{display:flex;align-items:center;width:100%;padding:10px;background:none;border:0;cursor:pointer;white-space:nowrap}.node--selected[_ngcontent-%COMP%]{background:#fff2cc}.node__icon[_ngcontent-%COMP%]{position:relative;display:inline-block}.node__count[_ngcontent-%COMP%]{color:#fff;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);font-size:.875rem;padding-top:4px}.node__iconImg[_ngcontent-%COMP%]{display:block;height:30px;width:30px}.node__name[_ngcontent-%COMP%]{margin-left:6px;font-size:1rem;overflow:hidden;text-overflow:ellipsis}.node__document-options[_ngcontent-%COMP%]{margin-left:auto;margin-right:0}.node__document-upload-timestamp[_ngcontent-%COMP%]{font-size:.8rem;float:left;padding-left:10px}"] });
24581
+ } }, dependencies: [i5.NgIf, i4.DefaultValueAccessor, i4.NgControlStatus, i4.NgControlStatusGroup, i4.FormGroupDirective, i4.FormControlName, i7$1.CdkNestedTreeNode, i7$1.CdkTreeNodeDef, i7$1.CdkTreeNodeToggle, i7$1.CdkTree, i7$1.CdkTreeNodeOutlet, CaseFileViewFolderSortComponent, CaseFileViewFolderDocumentActionsComponent, DatePipe], styles: ["[_nghost-%COMP%]{display:flex;height:100%;flex-direction:column}[_nghost-%COMP%] .document-tree-container[_ngcontent-%COMP%]{flex:1 0}.document-filter-container[_ngcontent-%COMP%]{border-bottom:2px solid #C9C9C9}.document-filter-container[_ngcontent-%COMP%] .document-filter[_ngcontent-%COMP%]{padding:10px}.document-filter-container[_ngcontent-%COMP%] .document-filter[_ngcontent-%COMP%] .document-search[_ngcontent-%COMP%]{background:url(/assets/images/icon-search-black.svg) no-repeat right #fff;background-position-x:calc(100% - 4px);padding-right:30px;width:100%}.document-filter-container[_ngcontent-%COMP%] .documents-title[_ngcontent-%COMP%]{height:30%;margin-left:8px;font-weight:700}.document-tree-container[_ngcontent-%COMP%]{padding:4px;overflow-x:hidden;overflow-y:scroll}.document-tree-container__node[_ngcontent-%COMP%]{display:block}.document-tree-container__node[_ngcontent-%COMP%] .document-tree-container__node[_ngcontent-%COMP%]{padding-left:40px}.document-tree-container[_ngcontent-%COMP%] .document-tree-invisible[_ngcontent-%COMP%]{display:none}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar{width:7px}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{border:4px solid rgba(0,0,0,0);background-clip:padding-box;border-radius:9999px;background-color:#aaa}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar-button{display:none}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar-track-piece{background:#eee}.document-tree-container[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:#ccc}.document-folders-header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;border-bottom:2px solid #C9C9C9;padding:10px}.document-folders-header__title[_ngcontent-%COMP%]{font-weight:700}.node[_ngcontent-%COMP%]{display:flex;align-items:center;width:100%;padding:10px;background:none;border:0;cursor:pointer;white-space:nowrap}.node--selected[_ngcontent-%COMP%]{background:#fff2cc}.node__icon[_ngcontent-%COMP%]{position:relative;display:inline-block}.node__count[_ngcontent-%COMP%]{color:#fff;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);font-size:.875rem;padding-top:4px}.node__iconImg[_ngcontent-%COMP%]{display:block;height:30px;width:30px}.node__name[_ngcontent-%COMP%]{margin-left:6px;font-size:1rem;overflow:hidden;text-overflow:ellipsis}.node__document-options[_ngcontent-%COMP%]{margin-left:auto;margin-right:0}.node__document-upload-timestamp[_ngcontent-%COMP%]{font-size:.8rem;float:left;padding-left:10px}.node.case-file__node[_ngcontent-%COMP%]{width:80%;float:left}.node__document-options.case-file__action[_ngcontent-%COMP%]{width:15%;float:left;box-sizing:border-box;padding:12px}"] });
24530
24582
  }
24531
24583
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CaseFileViewFolderComponent, [{
24532
24584
  type: Component,
24533
- args: [{ selector: 'ccd-case-file-view-folder', template: "<div class=\"document-filter-container\">\n <div class=\"form-group document-filter\" [formGroup]=\"documentFilterFormGroup\">\n <input class=\"form-control document-search\"\n type=\"search\"\n id=\"document-search\"\n name=\"documentSearchFormControl\"\n formControlName=\"documentSearchFormControl\"\n placeholder=\"Search by document name\"\n aria-label=\"Search by document name\">\n </div>\n</div>\n\n<div class=\"document-folders-header\">\n <span class=\"document-folders-header__title\">Documents ({{ documentCount }})</span>\n <div>\n <ccd-case-file-view-folder-sort\n (sortAscending)=\"sortDataSourceAscending($event)\"\n (sortDescending)=\"sortDataSourceDescending($event)\"\n ></ccd-case-file-view-folder-sort>\n </div>\n</div>\n\n<div class=\"document-tree-container\" *ngIf=\"documentTreeData\">\n <div *ngIf=\"!nestedDataSource || nestedDataSource.length === 0\">\n No results found\n </div>\n <div>\n <cdk-tree [dataSource]=\"nestedDataSource\" [treeControl]=\"nestedTreeControl\">\n <!-- document -->\n <cdk-nested-tree-node class=\"document-tree-container__node document-tree-container__node--document\" *cdkTreeNodeDef=\"let node\">\n <button class=\"node\" (click)=\"selectedNodeItem = node; clickedDocument.emit(node)\"\n [class.node--selected]=\"selectedNodeItem?.name === node.name\">\n <div class=\"node__icon\" disabled>\n <img src=\"/assets/img/case-file-view/case-file-view-document.svg\" class=\"node__iconImg\" alt=\"Document icon\">\n </div>\n <span class=\"node__name node-name-document\">\n {{node.name}}\n <br>\n <span class=\"node__document-upload-timestamp\">{{node.upload_timestamp | ccdDate : 'local' :'dd MMM YYYY HH:mm'}}</span>\n </span>\n <div class=\"node__document-options\">\n <ccd-case-file-view-folder-document-actions\n (changeFolderAction)=\"triggerDocumentAction('changeFolder', node)\"\n (openInANewTabAction)=\"triggerDocumentAction('openInANewTab', node)\"\n (downloadAction)=\"triggerDocumentAction('download', node)\"\n (printAction)=\"triggerDocumentAction('print', node)\"\n [allowMoving]=\"allowMoving\"\n >\n </ccd-case-file-view-folder-document-actions>\n </div>\n </button>\n </cdk-nested-tree-node>\n <!-- folder-->\n <cdk-nested-tree-node class=\"document-tree-container__node document-tree-container__folder\" *cdkTreeNodeDef=\"let node; when: nestedChildren\">\n <button class=\"node\" cdkTreeNodeToggle>\n <div class=\"node__icon\" [attr.aria-label]=\"'toggle ' + node.name\" >\n <img class=\"node__iconImg\"\n [src]=\"nestedTreeControl.isExpanded(node) ? '/assets/images/folder-open.png' : '/assets/images/folder.png'\" alt=\"Folder icon\">\n <span class=\"node__count\">{{node.childDocumentCount}}</span>\n </div>\n <span class=\"node__name node__name--folder\">{{node.name}}</span>\n </button>\n\n <div [class.document-tree-invisible]=\"!nestedTreeControl.isExpanded(node)\">\n <ng-container cdkTreeNodeOutlet></ng-container>\n </div>\n </cdk-nested-tree-node>\n </cdk-tree>\n </div>\n</div>\n", styles: [":host{display:flex;height:100%;flex-direction:column}:host .document-tree-container{flex:1 0}.document-filter-container{border-bottom:2px solid #C9C9C9}.document-filter-container .document-filter{padding:10px}.document-filter-container .document-filter .document-search{background:url(/assets/images/icon-search-black.svg) no-repeat right #fff;background-position-x:calc(100% - 4px);padding-right:30px;width:100%}.document-filter-container .documents-title{height:30%;margin-left:8px;font-weight:700}.document-tree-container{padding:4px;overflow-x:hidden;overflow-y:scroll}.document-tree-container__node{display:block}.document-tree-container__node .document-tree-container__node{padding-left:40px}.document-tree-container .document-tree-invisible{display:none}.document-tree-container::-webkit-scrollbar{width:7px}.document-tree-container::-webkit-scrollbar-thumb{border:4px solid rgba(0,0,0,0);background-clip:padding-box;border-radius:9999px;background-color:#aaa}.document-tree-container::-webkit-scrollbar-button{display:none}.document-tree-container::-webkit-scrollbar-track-piece{background:#eee}.document-tree-container::-webkit-scrollbar-thumb{background:#ccc}.document-folders-header{display:flex;align-items:center;justify-content:space-between;border-bottom:2px solid #C9C9C9;padding:10px}.document-folders-header__title{font-weight:700}.node{display:flex;align-items:center;width:100%;padding:10px;background:none;border:0;cursor:pointer;white-space:nowrap}.node--selected{background:#fff2cc}.node__icon{position:relative;display:inline-block}.node__count{color:#fff;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);font-size:.875rem;padding-top:4px}.node__iconImg{display:block;height:30px;width:30px}.node__name{margin-left:6px;font-size:1rem;overflow:hidden;text-overflow:ellipsis}.node__document-options{margin-left:auto;margin-right:0}.node__document-upload-timestamp{font-size:.8rem;float:left;padding-left:10px}\n"] }]
24585
+ args: [{ selector: 'ccd-case-file-view-folder', template: "<div class=\"document-filter-container\">\n <div class=\"form-group document-filter\" [formGroup]=\"documentFilterFormGroup\">\n <input class=\"form-control document-search\"\n type=\"search\"\n id=\"document-search\"\n name=\"documentSearchFormControl\"\n formControlName=\"documentSearchFormControl\"\n placeholder=\"Search by document name\"\n aria-label=\"Search by document name\">\n </div>\n</div>\n\n<div class=\"document-folders-header\">\n <span class=\"document-folders-header__title\">Documents ({{ documentCount }})</span>\n <div>\n <ccd-case-file-view-folder-sort\n (sortAscending)=\"sortDataSourceAscending($event)\"\n (sortDescending)=\"sortDataSourceDescending($event)\"\n ></ccd-case-file-view-folder-sort>\n </div>\n</div>\n\n<div class=\"document-tree-container\" *ngIf=\"documentTreeData\">\n <div *ngIf=\"!nestedDataSource || nestedDataSource.length === 0\">\n No results found\n </div>\n <div>\n <cdk-tree [dataSource]=\"nestedDataSource\" [treeControl]=\"nestedTreeControl\">\n <!-- document -->\n <cdk-nested-tree-node class=\"document-tree-container__node document-tree-container__node--document\" *cdkTreeNodeDef=\"let node\">\n <button class=\"node case-file__node\" (click)=\"selectedNodeItem = node; clickedDocument.emit(node)\"\n [class.node--selected]=\"selectedNodeItem?.name === node.name\">\n <div class=\"node__icon\" disabled>\n <img src=\"/assets/img/case-file-view/case-file-view-document.svg\" class=\"node__iconImg\" alt=\"Document icon\">\n </div>\n <span class=\"node__name node-name-document\">\n {{node.name}}\n <br>\n <span class=\"node__document-upload-timestamp\">{{node.upload_timestamp | ccdDate : 'local' :'dd MMM YYYY HH:mm'}}</span>\n </span>\n </button>\n <div class=\"node__document-options case-file__action\">\n <ccd-case-file-view-folder-document-actions\n (changeFolderAction)=\"triggerDocumentAction('changeFolder', node)\"\n (openInANewTabAction)=\"triggerDocumentAction('openInANewTab', node)\"\n (downloadAction)=\"triggerDocumentAction('download', node)\"\n (printAction)=\"triggerDocumentAction('print', node)\"\n [allowMoving]=\"allowMoving\"\n >\n </ccd-case-file-view-folder-document-actions>\n </div>\n </cdk-nested-tree-node>\n <!-- folder-->\n <cdk-nested-tree-node class=\"document-tree-container__node document-tree-container__folder\" *cdkTreeNodeDef=\"let node; when: nestedChildren\">\n <button class=\"node\" cdkTreeNodeToggle>\n <div class=\"node__icon\" [attr.aria-label]=\"'toggle ' + node.name\" >\n <img class=\"node__iconImg\"\n [src]=\"nestedTreeControl.isExpanded(node) ? '/assets/images/folder-open.png' : '/assets/images/folder.png'\" alt=\"Folder icon\">\n <span class=\"node__count\">{{node.childDocumentCount}}</span>\n </div>\n <span class=\"node__name node__name--folder\">{{node.name}}</span>\n </button>\n\n <div [class.document-tree-invisible]=\"!nestedTreeControl.isExpanded(node)\">\n <ng-container cdkTreeNodeOutlet></ng-container>\n </div>\n </cdk-nested-tree-node>\n </cdk-tree>\n </div>\n</div>\n", styles: [":host{display:flex;height:100%;flex-direction:column}:host .document-tree-container{flex:1 0}.document-filter-container{border-bottom:2px solid #C9C9C9}.document-filter-container .document-filter{padding:10px}.document-filter-container .document-filter .document-search{background:url(/assets/images/icon-search-black.svg) no-repeat right #fff;background-position-x:calc(100% - 4px);padding-right:30px;width:100%}.document-filter-container .documents-title{height:30%;margin-left:8px;font-weight:700}.document-tree-container{padding:4px;overflow-x:hidden;overflow-y:scroll}.document-tree-container__node{display:block}.document-tree-container__node .document-tree-container__node{padding-left:40px}.document-tree-container .document-tree-invisible{display:none}.document-tree-container::-webkit-scrollbar{width:7px}.document-tree-container::-webkit-scrollbar-thumb{border:4px solid rgba(0,0,0,0);background-clip:padding-box;border-radius:9999px;background-color:#aaa}.document-tree-container::-webkit-scrollbar-button{display:none}.document-tree-container::-webkit-scrollbar-track-piece{background:#eee}.document-tree-container::-webkit-scrollbar-thumb{background:#ccc}.document-folders-header{display:flex;align-items:center;justify-content:space-between;border-bottom:2px solid #C9C9C9;padding:10px}.document-folders-header__title{font-weight:700}.node{display:flex;align-items:center;width:100%;padding:10px;background:none;border:0;cursor:pointer;white-space:nowrap}.node--selected{background:#fff2cc}.node__icon{position:relative;display:inline-block}.node__count{color:#fff;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);font-size:.875rem;padding-top:4px}.node__iconImg{display:block;height:30px;width:30px}.node__name{margin-left:6px;font-size:1rem;overflow:hidden;text-overflow:ellipsis}.node__document-options{margin-left:auto;margin-right:0}.node__document-upload-timestamp{font-size:.8rem;float:left;padding-left:10px}.node.case-file__node{width:80%;float:left}.node__document-options.case-file__action{width:15%;float:left;box-sizing:border-box;padding:12px}\n"] }]
24534
24586
  }], () => [{ type: WindowService }, { type: i1$1.Router }, { type: DocumentManagementService }, { type: i1$3.MatLegacyDialog }, { type: AbstractAppConfig }], { categoriesAndDocuments: [{
24535
24587
  type: Input
24536
24588
  }], allowMoving: [{
@@ -28326,6 +28378,9 @@ class WriteDateFieldComponent extends AbstractFieldWriteComponent {
28326
28378
  isDateTime() {
28327
28379
  return this.caseField.field_type.id === 'DateTime';
28328
28380
  }
28381
+ getId() {
28382
+ return this.caseField.getHierachicalId();
28383
+ }
28329
28384
  static ɵfac = /*@__PURE__*/ (() => { let ɵWriteDateFieldComponent_BaseFactory; return function WriteDateFieldComponent_Factory(t) { return (ɵWriteDateFieldComponent_BaseFactory || (ɵWriteDateFieldComponent_BaseFactory = i0.ɵɵgetInheritedFactory(WriteDateFieldComponent)))(t || WriteDateFieldComponent); }; })();
28330
28385
  static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: WriteDateFieldComponent, selectors: [["ccd-write-date-field"]], features: [i0.ɵɵInheritDefinitionFeature], decls: 8, vars: 14, consts: [[1, "form-group", "bottom-30", 3, "id", "ngClass"], ["class", "form-label", 4, "ngIf"], ["class", "form-hint", 4, "ngIf"], ["class", "error-message", 4, "ngIf"], [3, "id", "isDateTime", "mandatory", "isInvalid", "formControl"], [1, "form-label"], [1, "form-hint"], [1, "error-message"]], template: function WriteDateFieldComponent_Template(rf, ctx) { if (rf & 1) {
28331
28386
  i0.ɵɵelementStart(0, "div", 0)(1, "fieldset")(2, "legend");
@@ -28344,12 +28399,12 @@ class WriteDateFieldComponent extends AbstractFieldWriteComponent {
28344
28399
  i0.ɵɵadvance();
28345
28400
  i0.ɵɵproperty("ngIf", ctx.dateControl && ctx.dateControl.errors && (ctx.dateControl.dirty || ctx.dateControl.touched));
28346
28401
  i0.ɵɵadvance();
28347
- i0.ɵɵproperty("id", ctx.id())("isDateTime", ctx.isDateTime())("mandatory", i0.ɵɵpipeBind1(7, 10, ctx.caseField))("isInvalid", ctx.dateControl.errors && (ctx.dateControl.dirty || ctx.dateControl.touched))("formControl", ctx.dateControl);
28402
+ i0.ɵɵproperty("id", ctx.getId())("isDateTime", ctx.isDateTime())("mandatory", i0.ɵɵpipeBind1(7, 10, ctx.caseField))("isInvalid", ctx.dateControl.errors && (ctx.dateControl.dirty || ctx.dateControl.touched))("formControl", ctx.dateControl);
28348
28403
  } }, dependencies: [i5.NgClass, i5.NgIf, i4.NgControlStatus, i4.FormControlDirective, DateInputComponent, FieldLabelPipe, FirstErrorPipe, IsMandatoryPipe, i1.RpxTranslatePipe], encapsulation: 2 });
28349
28404
  }
28350
28405
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(WriteDateFieldComponent, [{
28351
28406
  type: Component,
28352
- args: [{ selector: 'ccd-write-date-field', template: "<div class=\"form-group bottom-30\" [id]=\"id()\" [ngClass]=\"{'form-group-error': dateControl && !dateControl.valid && (dateControl.dirty || dateControl.touched)}\">\n\n <fieldset>\n <legend>\n <span class=\"form-label\" *ngIf=\"caseField.label\">{{(caseField | ccdFieldLabel)}}</span>\n </legend>\n <span class=\"form-hint\" *ngIf=\"caseField.hint_text\">{{caseField.hint_text | rpxTranslate}}</span>\n <span class=\"error-message\" *ngIf=\"dateControl && dateControl.errors && (dateControl.dirty || dateControl.touched)\">\n {{(dateControl.errors | ccdFirstError:caseField.label)}}\n </span>\n <cut-date-input [id]=\"id()\"\n [isDateTime]=\"isDateTime()\"\n [mandatory]=\"caseField | ccdIsMandatory\"\n [isInvalid]=\"dateControl.errors && (dateControl.dirty || dateControl.touched)\"\n [formControl]=\"dateControl\"></cut-date-input>\n\n </fieldset>\n</div>\n" }]
28407
+ args: [{ selector: 'ccd-write-date-field', template: "<div class=\"form-group bottom-30\" [id]=\"id()\" [ngClass]=\"{'form-group-error': dateControl && !dateControl.valid && (dateControl.dirty || dateControl.touched)}\">\n\n <fieldset>\n <legend>\n <span class=\"form-label\" *ngIf=\"caseField.label\">{{(caseField | ccdFieldLabel)}}</span>\n </legend>\n <span class=\"form-hint\" *ngIf=\"caseField.hint_text\">{{caseField.hint_text | rpxTranslate}}</span>\n <span class=\"error-message\" *ngIf=\"dateControl && dateControl.errors && (dateControl.dirty || dateControl.touched)\">\n {{(dateControl.errors | ccdFirstError:caseField.label)}}\n </span>\n <cut-date-input [id]=\"getId()\"\n [isDateTime]=\"isDateTime()\"\n [mandatory]=\"caseField | ccdIsMandatory\"\n [isInvalid]=\"dateControl.errors && (dateControl.dirty || dateControl.touched)\"\n [formControl]=\"dateControl\"></cut-date-input>\n\n </fieldset>\n</div>\n" }]
28353
28408
  }], null, null); })();
28354
28409
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(WriteDateFieldComponent, { className: "WriteDateFieldComponent", filePath: "lib/shared/components/palette/date/write-date-field.component.ts", lineNumber: 9 }); })();
28355
28410