@hmcts/rpx-xui-common-lib 1.7.0 → 1.7.3-unassigned-cases-pagination

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 (37) hide show
  1. package/bundles/hmcts-rpx-xui-common-lib.umd.js +132 -35
  2. package/bundles/hmcts-rpx-xui-common-lib.umd.js.map +1 -1
  3. package/bundles/hmcts-rpx-xui-common-lib.umd.min.js +1 -1
  4. package/bundles/hmcts-rpx-xui-common-lib.umd.min.js.map +1 -1
  5. package/esm2015/hmcts-rpx-xui-common-lib.js +22 -21
  6. package/esm2015/lib/components/find-location/find-location.component.js +18 -4
  7. package/esm2015/lib/components/find-person/find-person.component.js +14 -4
  8. package/esm2015/lib/components/generic-filter/generic-filter.component.js +21 -4
  9. package/esm2015/lib/components/search-location/search-location.component.js +12 -2
  10. package/esm2015/lib/exui-common-lib.module.js +8 -3
  11. package/esm2015/lib/gov-ui/components/hmcts-pagination/hmcts-pagination.component.js +49 -0
  12. package/esm2015/lib/gov-ui/components/hmcts-sub-navigation/hmcts-sub-navigation.component.js +3 -1
  13. package/esm2015/lib/models/filter.model.js +5 -1
  14. package/esm5/hmcts-rpx-xui-common-lib.js +22 -21
  15. package/esm5/lib/components/find-location/find-location.component.js +21 -4
  16. package/esm5/lib/components/find-person/find-person.component.js +17 -4
  17. package/esm5/lib/components/generic-filter/generic-filter.component.js +28 -4
  18. package/esm5/lib/components/search-location/search-location.component.js +15 -2
  19. package/esm5/lib/exui-common-lib.module.js +9 -3
  20. package/esm5/lib/gov-ui/components/hmcts-pagination/hmcts-pagination.component.js +51 -0
  21. package/esm5/lib/gov-ui/components/hmcts-sub-navigation/hmcts-sub-navigation.component.js +3 -1
  22. package/esm5/lib/models/filter.model.js +5 -1
  23. package/fesm2015/hmcts-rpx-xui-common-lib.js +91 -12
  24. package/fesm2015/hmcts-rpx-xui-common-lib.js.map +1 -1
  25. package/fesm5/hmcts-rpx-xui-common-lib.js +110 -13
  26. package/fesm5/hmcts-rpx-xui-common-lib.js.map +1 -1
  27. package/hmcts-rpx-xui-common-lib.d.ts +21 -20
  28. package/hmcts-rpx-xui-common-lib.metadata.json +1 -1
  29. package/lib/components/find-location/find-location.component.d.ts +4 -0
  30. package/lib/components/find-person/find-person.component.d.ts +2 -0
  31. package/lib/components/generic-filter/generic-filter.component.d.ts +1 -0
  32. package/lib/components/search-location/search-location.component.d.ts +2 -0
  33. package/lib/exui-common-lib.module.d.ts +3 -1
  34. package/lib/gov-ui/components/hmcts-pagination/hmcts-pagination.component.d.ts +10 -0
  35. package/lib/gov-ui/components/hmcts-sub-navigation/hmcts-sub-navigation.component.d.ts +1 -0
  36. package/lib/models/filter.model.d.ts +2 -0
  37. package/package.json +3 -2
@@ -1,8 +1,8 @@
1
1
  (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/material'), require('@angular/material/autocomplete'), require('@angular/common/http'), require('@angular/forms'), require('launchdarkly-js-client-sdk'), require('@angular/common'), require('@angular/platform-browser'), require('@ng-idle/core'), require('@ng-idle/keepalive'), require('@angular/router'), require('@angular/core'), require('rxjs'), require('rxjs/operators')) :
3
- typeof define === 'function' && define.amd ? define('@hmcts/rpx-xui-common-lib', ['exports', '@angular/material', '@angular/material/autocomplete', '@angular/common/http', '@angular/forms', 'launchdarkly-js-client-sdk', '@angular/common', '@angular/platform-browser', '@ng-idle/core', '@ng-idle/keepalive', '@angular/router', '@angular/core', 'rxjs', 'rxjs/operators'], factory) :
4
- (factory((global.hmcts = global.hmcts || {}, global.hmcts['rpx-xui-common-lib'] = {}),global.ng.material,global.ng.material.autocomplete,global.ng.common.http,global.ng.forms,global.LDClient,global.ng.common,global.ng.platformBrowser,global.i1$1,global.i2$1,global.ng.router,global.ng.core,global.rxjs,global.rxjs.operators));
5
- }(this, (function (exports,material,autocomplete,i1,forms,LDClient,i4,i2,i1$1,i2$1,i2$2,i0,rxjs,operators) { 'use strict';
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/material'), require('@angular/material/autocomplete'), require('ngx-pagination'), require('@angular/common/http'), require('@angular/forms'), require('launchdarkly-js-client-sdk'), require('@angular/common'), require('@angular/platform-browser'), require('@ng-idle/core'), require('@ng-idle/keepalive'), require('@angular/router'), require('@angular/core'), require('rxjs'), require('rxjs/operators')) :
3
+ typeof define === 'function' && define.amd ? define('@hmcts/rpx-xui-common-lib', ['exports', '@angular/material', '@angular/material/autocomplete', 'ngx-pagination', '@angular/common/http', '@angular/forms', 'launchdarkly-js-client-sdk', '@angular/common', '@angular/platform-browser', '@ng-idle/core', '@ng-idle/keepalive', '@angular/router', '@angular/core', 'rxjs', 'rxjs/operators'], factory) :
4
+ (factory((global.hmcts = global.hmcts || {}, global.hmcts['rpx-xui-common-lib'] = {}),global.ng.material,global.ng.material.autocomplete,global.ngxPagination,global.ng.common.http,global.ng.forms,global.LDClient,global.ng.common,global.ng.platformBrowser,global.i1$1,global.i2$1,global.ng.router,global.ng.core,global.rxjs,global.rxjs.operators));
5
+ }(this, (function (exports,material,autocomplete,ngxPagination,i1,forms,LDClient,i4,i2,i1$1,i2$1,i2$2,i0,rxjs,operators) { 'use strict';
6
6
 
7
7
  /**
8
8
  * @fileoverview added by tsickle
@@ -1035,7 +1035,13 @@
1035
1035
  }
1036
1036
  }
1037
1037
  }
1038
- return true;
1038
+ // find-location is special case where need to reset textbox (by existing disabling functionality)
1039
+ // field.disable referred to component itself
1040
+ if (field.type === 'find-location') {
1041
+ return true;
1042
+ }
1043
+ // Note: field.disable decides whether to actually disable or not
1044
+ return field.disable ? field.disable : null;
1039
1045
  };
1040
1046
  /**
1041
1047
  * @param {?} form
@@ -1101,6 +1107,24 @@
1101
1107
  }
1102
1108
  }
1103
1109
  };
1110
+ // when user enters input change radio button
1111
+ // when user enters input change radio button
1112
+ /**
1113
+ * @param {?} field
1114
+ * @return {?}
1115
+ */
1116
+ GenericFilterComponent.prototype.inputChanged =
1117
+ // when user enters input change radio button
1118
+ /**
1119
+ * @param {?} field
1120
+ * @return {?}
1121
+ */
1122
+ function (field) {
1123
+ if (field.radioSelectionChange && typeof field.radioSelectionChange === 'string') {
1124
+ var _a = __read(field.enableCondition.split('='), 2), name_3 = _a[0], value = _a[1];
1125
+ this.form.get(name_3).patchValue(value);
1126
+ }
1127
+ };
1104
1128
  /**
1105
1129
  * @return {?}
1106
1130
  */
@@ -1513,7 +1537,7 @@
1513
1537
  * @param {?} f
1514
1538
  * @return {?}
1515
1539
  */function (f) { return f.name === field.name; }));
1516
- if (defaultValues) {
1540
+ if (defaultValues && defaultValues.value && defaultValues.value.length > 0) {
1517
1541
  try {
1518
1542
  for (var _b = __values(defaultValues.value), _c = _b.next(); !_c.done; _c = _b.next()) {
1519
1543
  var defaultValue = _c.value;
@@ -1621,7 +1645,7 @@
1621
1645
  GenericFilterComponent.decorators = [
1622
1646
  { type: i0.Component, args: [{
1623
1647
  selector: 'xuilib-generic-filter',
1624
- template: "<form [formGroup]=\"form\" (ngSubmit)=\"applyFilter(form)\">\n <div class=\"contain-classes\" *ngFor=\"let field of config.fields\">\n <hr *ngIf=\"field.lineBreakBefore\" class=\"govuk-section-break govuk-section-break--visible elevated-break\">\n <div class=\"govuk-form-group xui-generic-filter\"\n [hidden]=\"hidden(field, form)\"\n [id]=\"field.name\"\n [ngClass]=\"{'form-group-error': submitted && (form.get(field.name).errors?.minLength || form.get(field.name).errors?.maxLength)}\">\n <h3 *ngIf=\"field.title\" class=\"govuk-heading-s\">{{field.title}}</h3>\n <p class=\"govuk-body\" *ngIf=\"field.subTitle\">{{field.subTitle}}</p>\n <span [id]=\"field.name + '-error'\" class=\"govuk-error-message\" *ngIf=\"field.displayMinSelectedError && submitted && form.get(field.name).errors?.minLength\">\n <span class=\"govuk-visually-hidden\">Error:</span> {{field.minSelectedError}}\n </span>\n <span [id]=\"field.name + '-error'\" class=\"govuk-error-message\" *ngIf=\"field.displayMaxSelectedError && submitted && form.get(field.name).errors?.maxLength\">\n <span class=\"govuk-visually-hidden\">Error:</span> {{field.maxSelectedError}}\n </span>\n <div class=\"govuk-body\" [ngSwitch]=\"field.type\">\n <ng-container *ngSwitchCase=\"'select'\">\n <select class=\"govuk-select\" (change)=\"fieldChanged(field, form)\" [attr.disabled]=\"disabled(field, form)\" [name]=\"'select_' + field.name\" [id]=\"'select_' + field.name\" [formControlName]=\"field.name\">\n <option disabled selected hidden value=\"\">{{field.disabledText}}</option>\n <option class=\"govuk-radios__item\" *ngFor=\"let item of field.options\" [value]=\"item.key\">{{item.label}}</option>\n </select>\n </ng-container>\n <ng-container *ngSwitchCase=\"'checkbox'\">\n <div class=\"govuk-checkboxes govuk-checkboxes--small\" [formGroupName]=\"field.name\" [attr.field]=\"field.name\" [id]=\"'checkbox_' + field.name\">\n <div *ngFor=\"let item of field.options; let i = index\" class=\"govuk-checkboxes__item\">\n <input type=\"checkbox\" class=\"govuk-checkboxes__input\"\n [attr.disabled]=\"disabled(field, form)\"\n [formControlName]=\"i\"\n (change)=\"toggleSelectAll($event, form, item, field)\"\n [value]=\"item.key\" [id]=\"'checkbox_' + item.key\"\n [name]=\"'checkbox_' + item.key\"\n />\n <label\n [for]=\"'checkbox_' + item.key\"\n class=\"govuk-label govuk-checkboxes__label\"\n [ngClass]=\"{'govuk-!-font-weight-bold': item.selectAll}\"\n >{{item.label}}</label>\n </div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'checkbox-large'\">\n <div class=\"govuk-checkboxes\" [formGroupName]=\"field.name\" [attr.field]=\"field.name\" [id]=\"'checkbox_' + field.name\">\n <div *ngFor=\"let item of field.options; let i = index\" class=\"govuk-checkboxes__item\">\n <input type=\"checkbox\" class=\"govuk-checkboxes__input\"\n [attr.disabled]=\"disabled(field, form)\"\n [formControlName]=\"i\"\n (change)=\"toggleSelectAll($event, form, item, field)\"\n [value]=\"item.key\" [id]=\"'checkbox_' + item.key\"\n [name]=\"'checkbox_' + item.key\"\n />\n <label\n [for]=\"'checkbox_' + item.key\"\n class=\"govuk-label govuk-checkboxes__label\"\n [ngClass]=\"{'govuk-!-font-weight-bold': item.selectAll}\"\n >{{item.label}}</label>\n </div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'radio'\">\n <div class=\"govuk-radios\">\n <div *ngFor=\"let item of field.options\" class=\"govuk-radios__item\">\n <input type=\"radio\"\n [formControlName]=\"field.name\"\n [id]=\"'radio_' + item.key\"\n [attr.disabled]=\"disabled(field, form)\"\n [checked]=\"item.key === form.get(field.name).value\"\n class=\"govuk-radios__input\"\n [value]=\"item.key\"\n (change)=\"fieldChanged(field, form)\"\n />\n <label [for]=\"'radio_' + item.key\" class=\"govuk-label govuk-radios__label\">{{item.label}}</label>\n </div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'find-person'\">\n <xuilib-find-person subTitle=\"\" (personSelected)=\"updatePersonControls($event, field)\"\n [submitted]=\"submitted\"\n [disabled]=\"disabled(field, form)\"\n [domain]=\"form.get(field.domainField)?.value\"\n [findPersonGroup]=\"form\"\n [selectedPerson]=\"form.get(field.name)?.value?.email\"\n [userIncluded]=\"false\"\n ></xuilib-find-person>\n </ng-container>\n <ng-container *ngSwitchCase=\"'find-location'\">\n <xuilib-find-location [form]=\"form\"\n [fields]=\"config.fields\"\n [locationTitle]=\"field.locationTitle\"\n [enableAddLocationButton]=\"field.enableAddLocationButton\"\n [disabled]=\"disabled(field, form)\"\n [selectedLocations]=\"form.get(field.name)?.value\"\n [submitted]=\"submitted\"\n [services]=\"form.get(field.findLocationField)?.value\"\n [field]=\"field\"\n ></xuilib-find-location>\n </ng-container>\n </div>\n </div>\n </div>\n <hr class=\"govuk-section-break govuk-section-break--m govuk-section-break--visible\"/>\n <div class=\"govuk-grid-row\">\n <div class=\"govuk-grid-column-full\">\n <button\n class=\"govuk-button govuk-!-margin-right-1 govuk-!-margin-bottom-0\"\n type=\"submit\"\n id=\"applyFilter\"\n [disabled]=\"config.enableDisabledButton && form.invalid\"\n >{{config.applyButtonText || 'Apply'}}</button>\n <button *ngIf=\"config.showCancelFilterButton\"\n class=\"govuk-button govuk-button--secondary govuk-!-margin-bottom-0\"\n type=\"button\"\n id=\"cancelFilter\"\n (click)=\"cancelFilter()\">{{ config.cancelButtonText || 'Cancel'}}</button>\n </div>\n </div>\n</form>\n",
1648
+ template: "<form [formGroup]=\"form\" (ngSubmit)=\"applyFilter(form)\">\n <div class=\"contain-classes\" *ngFor=\"let field of config.fields\">\n <hr *ngIf=\"field.lineBreakBefore\" class=\"govuk-section-break govuk-section-break--visible elevated-break\">\n <div class=\"govuk-form-group xui-generic-filter\"\n [hidden]=\"hidden(field, form)\"\n [id]=\"field.name\"\n [ngClass]=\"{'form-group-error': submitted && (form.get(field.name).errors?.minLength || form.get(field.name).errors?.maxLength)}\">\n <h3 *ngIf=\"field.title\" class=\"govuk-heading-s\">{{field.title}}</h3>\n <p class=\"govuk-body\" *ngIf=\"field.subTitle\">{{field.subTitle}}</p>\n <span [id]=\"field.name + '-error'\" class=\"govuk-error-message\" *ngIf=\"field.displayMinSelectedError && submitted && form.get(field.name).errors?.minLength\">\n <span class=\"govuk-visually-hidden\">Error:</span> {{field.minSelectedError}}\n </span>\n <span [id]=\"field.name + '-error'\" class=\"govuk-error-message\" *ngIf=\"field.displayMaxSelectedError && submitted && form.get(field.name).errors?.maxLength\">\n <span class=\"govuk-visually-hidden\">Error:</span> {{field.maxSelectedError}}\n </span>\n <div class=\"govuk-body\" [ngSwitch]=\"field.type\">\n <ng-container *ngSwitchCase=\"'select'\">\n <select class=\"govuk-select\" (change)=\"fieldChanged(field, form)\" [attr.disabled]=\"disabled(field, form)\" [name]=\"'select_' + field.name\" [id]=\"'select_' + field.name\" [formControlName]=\"field.name\">\n <option disabled selected hidden value=\"\">{{field.disabledText}}</option>\n <option class=\"govuk-radios__item\" *ngFor=\"let item of field.options\" [value]=\"item.key\">{{item.label}}</option>\n </select>\n </ng-container>\n <ng-container *ngSwitchCase=\"'checkbox'\">\n <div class=\"govuk-checkboxes govuk-checkboxes--small\" [formGroupName]=\"field.name\" [attr.field]=\"field.name\" [id]=\"'checkbox_' + field.name\">\n <div *ngFor=\"let item of field.options; let i = index\" class=\"govuk-checkboxes__item\">\n <input type=\"checkbox\" class=\"govuk-checkboxes__input\"\n [attr.disabled]=\"disabled(field, form)\"\n [formControlName]=\"i\"\n (change)=\"toggleSelectAll($event, form, item, field)\"\n [value]=\"item.key\" [id]=\"'checkbox_' + item.key\"\n [name]=\"'checkbox_' + item.key\"\n />\n <label\n [for]=\"'checkbox_' + item.key\"\n class=\"govuk-label govuk-checkboxes__label\"\n [ngClass]=\"{'govuk-!-font-weight-bold': item.selectAll}\"\n >{{item.label}}</label>\n </div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'checkbox-large'\">\n <div class=\"govuk-checkboxes\" [formGroupName]=\"field.name\" [attr.field]=\"field.name\" [id]=\"'checkbox_' + field.name\">\n <div *ngFor=\"let item of field.options; let i = index\" class=\"govuk-checkboxes__item\">\n <input type=\"checkbox\" class=\"govuk-checkboxes__input\"\n [attr.disabled]=\"disabled(field, form)\"\n [formControlName]=\"i\"\n (change)=\"toggleSelectAll($event, form, item, field)\"\n [value]=\"item.key\" [id]=\"'checkbox_' + item.key\"\n [name]=\"'checkbox_' + item.key\"\n />\n <label\n [for]=\"'checkbox_' + item.key\"\n class=\"govuk-label govuk-checkboxes__label\"\n [ngClass]=\"{'govuk-!-font-weight-bold': item.selectAll}\"\n >{{item.label}}</label>\n </div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'radio'\">\n <div class=\"govuk-radios\">\n <div *ngFor=\"let item of field.options\" class=\"govuk-radios__item\">\n <input type=\"radio\"\n [formControlName]=\"field.name\"\n [id]=\"'radio_' + item.key\"\n [attr.disabled]=\"disabled(field, form)\"\n [checked]=\"item.key === form.get(field.name).value\"\n class=\"govuk-radios__input\"\n [value]=\"item.key\"\n (change)=\"fieldChanged(field, form)\"\n />\n <label [for]=\"'radio_' + item.key\" class=\"govuk-label govuk-radios__label\">{{item.label}}</label>\n </div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'find-person'\">\n <xuilib-find-person subTitle=\"\" (personSelected)=\"updatePersonControls($event, field)\"\n (personFieldChanged)=\"inputChanged(field)\"\n [submitted]=\"submitted\"\n [disabled]=\"disabled(field, form)\"\n [domain]=\"form.get(field.domainField)?.value\"\n [findPersonGroup]=\"form\"\n [selectedPerson]=\"form.get(field.name)?.value?.email\"\n [userIncluded]=\"false\"\n ></xuilib-find-person>\n </ng-container>\n <ng-container *ngSwitchCase=\"'find-location'\">\n <xuilib-find-location (locationFieldChanged)=\"inputChanged(field)\"\n [form]=\"form\"\n [fields]=\"config.fields\"\n [locationTitle]=\"field.locationTitle\"\n [enableAddLocationButton]=\"field.enableAddLocationButton\"\n [disabled]=\"disabled(field, form)\"\n [disableInputField]=\"field.disable\"\n [selectedLocations]=\"form.get(field.name)?.value\"\n [submitted]=\"submitted\"\n [services]=\"form.get(field.findLocationField)?.value\"\n [field]=\"field\"\n ></xuilib-find-location>\n </ng-container>\n </div>\n </div>\n </div>\n <hr class=\"govuk-section-break govuk-section-break--m govuk-section-break--visible\"/>\n <div class=\"govuk-grid-row\">\n <div class=\"govuk-grid-column-full\">\n <button\n class=\"govuk-button govuk-!-margin-right-1 govuk-!-margin-bottom-0\"\n type=\"submit\"\n id=\"applyFilter\"\n [disabled]=\"config.enableDisabledButton && form.invalid\"\n >{{config.applyButtonText || 'Apply'}}</button>\n <button *ngIf=\"config.showCancelFilterButton\"\n class=\"govuk-button govuk-button--secondary govuk-!-margin-bottom-0\"\n type=\"button\"\n id=\"cancelFilter\"\n (click)=\"cancelFilter()\">{{ config.cancelButtonText || 'Cancel'}}</button>\n </div>\n </div>\n</form>\n",
1625
1649
  changeDetection: i0.ChangeDetectionStrategy.OnPush,
1626
1650
  encapsulation: i0.ViewEncapsulation.None,
1627
1651
  styles: [".contain-classes .elevated-break{position:relative;top:-10px}.contain-classes .xui-generic-filter .select-all{margin-bottom:10px}.contain-classes .xui-generic-filter .govuk-checkboxes{display:flex;flex-wrap:wrap}.contain-classes .xui-generic-filter .govuk-checkboxes>div{flex-grow:1;flex-shrink:0}"]
@@ -3803,6 +3827,7 @@
3803
3827
  this.locations = [];
3804
3828
  this.locationSelected = new i0.EventEmitter();
3805
3829
  this.locationInputChanged = new i0.EventEmitter();
3830
+ this.searchLocationChanged = new i0.EventEmitter();
3806
3831
  this.minSearchCharacters = 3;
3807
3832
  this.term = '';
3808
3833
  this.pSelectedLocations = [];
@@ -3923,6 +3948,15 @@
3923
3948
  _this.showAutocomplete = true;
3924
3949
  }));
3925
3950
  };
3951
+ /**
3952
+ * @return {?}
3953
+ */
3954
+ SearchLocationComponent.prototype.onInput = /**
3955
+ * @return {?}
3956
+ */
3957
+ function () {
3958
+ this.searchLocationChanged.emit();
3959
+ };
3926
3960
  /**
3927
3961
  * @param {?} term
3928
3962
  * @return {?}
@@ -3971,7 +4005,7 @@
3971
4005
  SearchLocationComponent.decorators = [
3972
4006
  { type: i0.Component, args: [{
3973
4007
  selector: 'exui-search-location',
3974
- template: "<div class=\"auto-complete-container\">\n <input\n id=\"inputLocationSearch\"\n [formControl]=\"form.controls.searchTerm\"\n [matAutocomplete]=\"autoSearchLocation\"\n class=\"govuk-input\"\n [attr.disabled]=\"disabled\">\n <mat-autocomplete class=\"mat-autocomplete-panel-extend\" autoActiveFirstOption #autoSearchLocation=\"matAutocomplete\">\n <mat-option *ngFor=\"let location of locations\"\n (onSelectionChange)=\"onSelectionChange(location)\">\n {{ location.site_name }}\n </mat-option>\n <mat-option *ngIf=\"!locations.length && showAutocomplete && term && term.length >= this.minSearchCharacters\">No results found</mat-option>\n </mat-autocomplete>\n</div>\n",
4008
+ template: "<div class=\"auto-complete-container\">\n <input\n id=\"inputLocationSearch\"\n (input)=\"onInput()\"\n [formControl]=\"form.controls.searchTerm\"\n [matAutocomplete]=\"autoSearchLocation\"\n class=\"govuk-input\"\n [attr.disabled]=\"disabled\">\n <mat-autocomplete class=\"mat-autocomplete-panel-extend\" autoActiveFirstOption #autoSearchLocation=\"matAutocomplete\">\n <mat-option *ngFor=\"let location of locations\"\n (onSelectionChange)=\"onSelectionChange(location)\">\n {{ location.site_name }}\n </mat-option>\n <mat-option *ngIf=\"!locations.length && showAutocomplete && term && term.length >= this.minSearchCharacters\">No results found</mat-option>\n </mat-autocomplete>\n</div>\n",
3975
4009
  styles: [".autocomplete__input--show-all-values{padding:5px 34px 5px 5px;cursor:pointer}.autocomplete__dropdown-arrow-down{z-index:-1;display:inline-block;position:absolute;right:8px;width:24px;height:24px;top:10px}.autocomplete__menu{background-color:#fff;border:2px solid #0b0c0c;border-top:0;color:#0b0c0c;margin:0;max-height:342px;overflow-x:hidden;padding:0;width:100%;width:calc(100% - 4px)}.autocomplete__menu--visible{display:block}.autocomplete__menu--hidden{display:none}.autocomplete__menu--overlay{box-shadow:rgba(0,0,0,.256863) 0 2px 6px;left:0;position:absolute;top:100%;z-index:100}.autocomplete__menu--inline{position:relative}.autocomplete__option{border-bottom:solid #b1b4b6;border-width:1px 0;cursor:pointer;display:block;position:relative}.autocomplete__option>*{pointer-events:none}.autocomplete__option:first-of-type{border-top-width:0}.autocomplete__option:last-of-type{border-bottom-width:0}.autocomplete__option--odd{background-color:#fafafa}.autocomplete__option--focused,.autocomplete__option:hover{background-color:#1d70b8;border-color:#1d70b8;color:#fff;outline:0}.autocomplete__option--no-results{background-color:#fafafa;color:#646b6f;cursor:not-allowed}.autocomplete__hint,.autocomplete__input,.autocomplete__option{font-size:13px;line-height:1.25}.autocomplete__hint,.autocomplete__option{padding:5px}@media (min-width:641px){.autocomplete__hint,.autocomplete__input,.autocomplete__option{font-size:13px;line-height:1.31579}}.div-action{display:inline-block}.add-location{display:inline}.remove-location-button{margin:5px}.hide-autocomplete{display:none}.auto-complete-container{min-width:550px;display:inline-block;margin-right:4px}.autocomplete__input{line-height:24px;font-size:19px}"]
3976
4010
  }] }
3977
4011
  ];
@@ -3996,6 +4030,7 @@
3996
4030
  locations: [{ type: i0.Input }],
3997
4031
  locationSelected: [{ type: i0.Output }],
3998
4032
  locationInputChanged: [{ type: i0.Output }],
4033
+ searchLocationChanged: [{ type: i0.Output }],
3999
4034
  reset: [{ type: i0.Input }],
4000
4035
  selectedLocations: [{ type: i0.Input }]
4001
4036
  };
@@ -4009,10 +4044,12 @@
4009
4044
  */
4010
4045
  var FindLocationComponent = /** @class */ (function () {
4011
4046
  function FindLocationComponent() {
4047
+ this.locationFieldChanged = new i0.EventEmitter();
4012
4048
  this.selectedLocations = [];
4013
4049
  this.submitted = true;
4014
4050
  this.enableAddLocationButton = true;
4015
4051
  this.locationTitle = 'Search for a location by name';
4052
+ this.disableInputField = false;
4016
4053
  this.locations = [];
4017
4054
  this.tempSelectedLocation = null;
4018
4055
  this.serviceIds = 'SSCS,IA';
@@ -4033,7 +4070,7 @@
4033
4070
  this.searchLocationComponent.resetSearchTerm();
4034
4071
  this.removeSelectedValues();
4035
4072
  }
4036
- this.pDisabled = value;
4073
+ this.pDisabled = this.disableInputField === true ? true : null;
4037
4074
  },
4038
4075
  enumerable: true,
4039
4076
  configurable: true
@@ -4125,6 +4162,15 @@
4125
4162
  this.removeSelectedValues();
4126
4163
  }
4127
4164
  };
4165
+ /**
4166
+ * @return {?}
4167
+ */
4168
+ FindLocationComponent.prototype.onSearchInputChanged = /**
4169
+ * @return {?}
4170
+ */
4171
+ function () {
4172
+ this.locationFieldChanged.emit();
4173
+ };
4128
4174
  /**
4129
4175
  * @param {?} location
4130
4176
  * @return {?}
@@ -4202,11 +4248,12 @@
4202
4248
  FindLocationComponent.decorators = [
4203
4249
  { type: i0.Component, args: [{
4204
4250
  selector: 'xuilib-find-location',
4205
- template: "<div class=\"location-picker-custom\">\n <div class=\"search-location\">\n <div>\n <label id=\"input-selected-location-label\" *ngIf=\"locationTitle\">{{locationTitle}}</label>\n </div>\n <exui-search-location class=\"search-location\"\n [locations]=\"locations\"\n [selectedLocations]=\"selectedLocations\"\n [singleMode]=\"field.maxSelected === 1\"\n [delay]=\"300\"\n [disabled]=\"disabled\"\n [serviceIds]=\"serviceIds\"\n (locationInputChanged)=\"onInputChanged($event)\"\n (locationSelected)=\"onLocationSelected($event)\"\n [locationType]=\"'case-management'\"></exui-search-location>\n <a href=\"javascript:void(0)\" (click)=\"addLocation()\" class=\"govuk-button\" data-module=\"govuk-button\" *ngIf=\"enableAddLocationButton\">\n Add location\n </a>\n </div>\n <ul class=\"hmcts-filter-tags selection-container\" *ngIf=\"field.maxSelected != 1\">\n <li class=\"location-selection\" *ngFor=\"let selection of selectedLocations\">\n <a class=\"hmcts-filter__tag\" (click)=\"removeLocation(selection)\" href=\"javascript:void(0)\">\n {{ selection.site_name }}\n </a>\n </li>\n </ul>\n</div>\n",
4251
+ template: "<div class=\"location-picker-custom\">\n <div class=\"search-location\">\n <div>\n <label id=\"input-selected-location-label\" *ngIf=\"locationTitle\">{{locationTitle}}</label>\n </div>\n <exui-search-location class=\"search-location\"\n [locations]=\"locations\"\n [selectedLocations]=\"selectedLocations\"\n [singleMode]=\"field.maxSelected === 1\"\n [delay]=\"300\"\n [disabled]=\"disabled\"\n [serviceIds]=\"serviceIds\"\n (locationInputChanged)=\"onInputChanged($event)\"\n (locationSelected)=\"onLocationSelected($event)\"\n (searchLocationChanged)=\"onSearchInputChanged()\"\n [locationType]=\"'case-management'\"></exui-search-location>\n <a href=\"javascript:void(0)\" (click)=\"addLocation()\" class=\"govuk-button\" data-module=\"govuk-button\" *ngIf=\"enableAddLocationButton\">\n Add location\n </a>\n </div>\n <ul class=\"hmcts-filter-tags selection-container\" *ngIf=\"field.maxSelected != 1\">\n <li class=\"location-selection\" *ngFor=\"let selection of selectedLocations\">\n <a class=\"hmcts-filter__tag\" (click)=\"removeLocation(selection)\" href=\"javascript:void(0)\">\n {{ selection.site_name }}\n </a>\n </li>\n </ul>\n</div>\n",
4206
4252
  styles: [""]
4207
4253
  }] }
4208
4254
  ];
4209
4255
  FindLocationComponent.propDecorators = {
4256
+ locationFieldChanged: [{ type: i0.Output }],
4210
4257
  selectedLocations: [{ type: i0.Input }],
4211
4258
  submitted: [{ type: i0.Input }],
4212
4259
  enableAddLocationButton: [{ type: i0.Input }],
@@ -4214,6 +4261,7 @@
4214
4261
  field: [{ type: i0.Input }],
4215
4262
  fields: [{ type: i0.Input }],
4216
4263
  locationTitle: [{ type: i0.Input }],
4264
+ disableInputField: [{ type: i0.Input }],
4217
4265
  searchLocationComponent: [{ type: i0.ViewChild, args: [SearchLocationComponent,] }],
4218
4266
  disabled: [{ type: i0.Input }],
4219
4267
  services: [{ type: i0.Input }]
@@ -4860,6 +4908,7 @@
4860
4908
  this.findPersonService = findPersonService;
4861
4909
  this.cd = cd;
4862
4910
  this.personSelected = new i0.EventEmitter();
4911
+ this.personFieldChanged = new i0.EventEmitter();
4863
4912
  this.boldTitle = 'Find the person';
4864
4913
  this.subTitle = 'Type the name of the person and select them.';
4865
4914
  this.domain = PersonRole.ALL;
@@ -5006,14 +5055,23 @@
5006
5055
  return '';
5007
5056
  }
5008
5057
  if (selectedPerson.domain === PersonRole.JUDICIAL && selectedPerson.knownAs) {
5009
- return selectedPerson.knownAs + "(" + selectedPerson.email + ")";
5058
+ return selectedPerson.knownAs + " (" + selectedPerson.email + ")";
5010
5059
  }
5011
- return selectedPerson.email ? selectedPerson.name + "(" + selectedPerson.email + ")" : selectedPerson.name;
5060
+ return selectedPerson.email ? selectedPerson.name + " (" + selectedPerson.email + ")" : selectedPerson.name;
5061
+ };
5062
+ /**
5063
+ * @return {?}
5064
+ */
5065
+ FindPersonComponent.prototype.onInput = /**
5066
+ * @return {?}
5067
+ */
5068
+ function () {
5069
+ this.personFieldChanged.emit();
5012
5070
  };
5013
5071
  FindPersonComponent.decorators = [
5014
5072
  { type: i0.Component, args: [{
5015
5073
  selector: 'xuilib-find-person',
5016
- template: "<h1 class=\"govuk-heading-l\" *ngIf=\"title && title.length\">\n <span class=\"govuk-caption-l\">{{title}}</span>\n {{boldTitle}}\n</h1>\n<div class=\"govuk-form-group\" [formGroup]=\"findPersonGroup\"\n [ngClass]=\"{'form-group-error': findPersonGroup.get('findPersonControl').invalid && submitted}\">\n <fieldset class=\"govuk-fieldset\" aria-describedby=\"sub-title-hint\">\n <div id=\"sub-title-hint\" class=\"govuk-hint\" *ngIf=\"subTitle && subTitle.length\">\n {{subTitle}}\n </div>\n <span id=\"validation-error\" class=\"govuk-error-message\" *ngIf=\"findPersonGroup && findPersonGroup.errors\">\n <span class=\"govuk-visually-hidden\">Error:</span>{{findPersonGroup.errors.error ? findPersonGroup.errors.error : errorMessage}}\n </span>\n <input id=\"inputSelectPerson{{idValue}}\" type=\"text\" aria-label=\"select a person\"\n formControlName=\"findPersonControl\"\n [matAutocomplete]=\"auto\"\n class=\"govuk-input govuk-!-width-one-third\"\n [placeholder]=\"placeholderContent\"\n [attr.disabled]=\"disabled\">\n <mat-autocomplete autoActiveFirstOption #auto=\"matAutocomplete\" (optionSelected)=\"onSelectionChange($event.option.value)\">\n <mat-option *ngFor=\"let option of filteredOptions\"\n [value]=\"option\"\n [ngClass]=\"{'hide-autocomplete': !showAutocomplete, 'select-option': showUpdatedColor}\">\n {{getDisplayName(option)}}\n </mat-option>\n <mat-option [ngClass]=\"{'select-option': showUpdatedColor}\" *ngIf=\"isNoResultsShown && !filteredOptions.length && showAutocomplete\">No results found</mat-option>\n </mat-autocomplete>\n </fieldset>\n</div>\n",
5074
+ template: "<h1 class=\"govuk-heading-l\" *ngIf=\"title && title.length\">\n <span class=\"govuk-caption-l\">{{title}}</span>\n {{boldTitle}}\n</h1>\n<div class=\"govuk-form-group\" [formGroup]=\"findPersonGroup\"\n [ngClass]=\"{'form-group-error': findPersonGroup.get('findPersonControl').invalid && submitted}\">\n <fieldset class=\"govuk-fieldset\" aria-describedby=\"sub-title-hint\">\n <div id=\"sub-title-hint\" class=\"govuk-hint\" *ngIf=\"subTitle && subTitle.length\">\n {{subTitle}}\n </div>\n <span id=\"validation-error\" class=\"govuk-error-message\" *ngIf=\"findPersonGroup && findPersonGroup.errors\">\n <span class=\"govuk-visually-hidden\">Error:</span>{{findPersonGroup.errors.error ? findPersonGroup.errors.error : errorMessage}}\n </span>\n <input id=\"inputSelectPerson{{idValue}}\" type=\"text\" aria-label=\"select a person\"\n formControlName=\"findPersonControl\"\n [matAutocomplete]=\"auto\"\n class=\"govuk-input govuk-!-width-one-third\"\n [placeholder]=\"placeholderContent\"\n [attr.disabled]=\"disabled\"\n (input)=\"onInput()\">\n <mat-autocomplete autoActiveFirstOption #auto=\"matAutocomplete\" (optionSelected)=\"onSelectionChange($event.option.value)\">\n <mat-option *ngFor=\"let option of filteredOptions\"\n [value]=\"option\"\n [ngClass]=\"{'hide-autocomplete': !showAutocomplete, 'select-option': showUpdatedColor}\">\n {{getDisplayName(option)}}\n </mat-option>\n <mat-option [ngClass]=\"{'select-option': showUpdatedColor}\" *ngIf=\"isNoResultsShown && !filteredOptions.length && showAutocomplete\">No results found</mat-option>\n </mat-autocomplete>\n </fieldset>\n</div>\n",
5017
5075
  styles: [".mat-option:hover{background:#2596be}.mat-option.select-option:hover{background:#1d70b8;color:#fff}.hide-autocomplete{display:none}"]
5018
5076
  }] }
5019
5077
  ];
@@ -5026,6 +5084,7 @@
5026
5084
  };
5027
5085
  FindPersonComponent.propDecorators = {
5028
5086
  personSelected: [{ type: i0.Output }],
5087
+ personFieldChanged: [{ type: i0.Output }],
5029
5088
  title: [{ type: i0.Input }],
5030
5089
  boldTitle: [{ type: i0.Input }],
5031
5090
  subTitle: [{ type: i0.Input }],
@@ -6423,6 +6482,39 @@
6423
6482
  return HmctsMainWrapperComponent;
6424
6483
  }());
6425
6484
 
6485
+ /**
6486
+ * @fileoverview added by tsickle
6487
+ * Generated from: lib/gov-ui/components/hmcts-pagination/hmcts-pagination.component.ts
6488
+ * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
6489
+ */
6490
+ var HmctsPaginationComponent = /** @class */ (function () {
6491
+ function HmctsPaginationComponent() {
6492
+ this.maxSize = 7;
6493
+ this.pageSize = 10;
6494
+ this.showPageNumbers = true;
6495
+ this.showResultCount = true;
6496
+ this.pageChange = new i0.EventEmitter();
6497
+ this.pageBoundsCorrection = new i0.EventEmitter();
6498
+ }
6499
+ HmctsPaginationComponent.decorators = [
6500
+ { type: i0.Component, args: [{
6501
+ selector: 'xuilib-hmcts-pagination',
6502
+ template: "<pagination-template #p=\"paginationApi\" [id]=\"id\" [maxSize]=\"maxSize\" (pageChange)=\"pageChange.emit($event)\"\n (pageBoundsCorrection)=\"pageBoundsCorrection.emit($event)\">\n\n <nav class=\"hmcts-pagination\" id=\"pagination-label\">\n <p class=\"govuk-visually-hidden\" aria-labelledby=\"pagination-label\">Pagination navigation</p>\n <ul class=\"hmcts-pagination__list\" *ngIf=\"!(p.pages.length <= 1)\">\n\n <li class=\"hmcts-pagination__item hmcts-pagination__item--prev\" [class.disabled]=\"p.isFirstPage()\">\n <a [routerLink]=\"\" class=\"hmcts-pagination__link\" *ngIf=\"1 < p.getCurrent()\" (keyup.enter)=\"p.previous()\"\n (click)=\"p.previous()\">Previous <span class=\"govuk-visually-hidden\">set of pages</span></a>\n </li>\n\n <ng-container *ngIf=\"showPageNumbers\">\n <li class=\"hmcts-pagination__item\" [class.hmcts-pagination__item--active]=\"p.getCurrent() === page.value\"\n [class.hmcts-pagination__item--dots]=\"page.label === '...'\" *ngFor=\"let page of p.pages\">\n <a class=\"hmcts-pagination__link\" [routerLink]=\"\" (keyup.enter)=\"p.setCurrent(page.value)\"\n (click)=\"p.setCurrent(page.value)\" *ngIf=\"p.getCurrent() !== page.value\">\n <span class=\"govuk-visually-hidden\">page </span>\n <span>{{ (page.label === '...') ? page.label : (page.label | number:'') }}</span>\n </a>\n <ng-container *ngIf=\"p.getCurrent() === page.value\">\n <span>{{ (page.label === '...') ? page.label : (page.label | number:'') }}</span>\n </ng-container>\n </li>\n </ng-container>\n\n <li class=\"hmcts-pagination__item hmcts-pagination__item--next\" [class.disabled]=\"p.isLastPage()\">\n <a [routerLink]=\"\" class=\"hmcts-pagination__link\" *ngIf=\"!p.isLastPage()\" (keyup.enter)=\"p.next()\"\n (click)=\"p.next()\">Next<span class=\"govuk-visually-hidden\"> page</span></a>\n </li>\n\n </ul>\n <p class=\"hmcts-pagination__results\" *ngIf=\"showResultCount\">Showing <b>{{(p.getCurrent() * pageSize) - pageSize + 1}}</b>\n to <b>{{ p.getCurrent() * pageSize > p.getTotalItems() ? p.getTotalItems() : p.getCurrent() *\n pageSize}}</b> of <b>{{p.getTotalItems()}}</b> results</p>\n </nav>\n\n</pagination-template>",
6503
+ styles: [".hmcts-pagination__results{float:right}"]
6504
+ }] }
6505
+ ];
6506
+ HmctsPaginationComponent.propDecorators = {
6507
+ id: [{ type: i0.Input }],
6508
+ maxSize: [{ type: i0.Input }],
6509
+ pageSize: [{ type: i0.Input }],
6510
+ showPageNumbers: [{ type: i0.Input }],
6511
+ showResultCount: [{ type: i0.Input }],
6512
+ pageChange: [{ type: i0.Output }],
6513
+ pageBoundsCorrection: [{ type: i0.Output }]
6514
+ };
6515
+ return HmctsPaginationComponent;
6516
+ }());
6517
+
6426
6518
  /**
6427
6519
  * @fileoverview added by tsickle
6428
6520
  * Generated from: lib/gov-ui/components/hmcts-primary-navigation/hmcts-primary-navigation.component.ts
@@ -6570,6 +6662,7 @@
6570
6662
  /** @type {?} */
6571
6663
  var GOV_UI_COMPONENTS = [
6572
6664
  HmctsIdentityBarComponent,
6665
+ HmctsPaginationComponent,
6573
6666
  HmctsSubNavigationComponent,
6574
6667
  HmctsPrimaryNavigationComponent,
6575
6668
  HmctsErrorSummaryComponent,
@@ -6605,12 +6698,15 @@
6605
6698
  i2$2.RouterModule.forChild([]),
6606
6699
  autocomplete.MatAutocompleteModule,
6607
6700
  material.MatTabsModule,
6608
- material.MatInputModule
6701
+ material.MatInputModule,
6702
+ ngxPagination.NgxPaginationModule
6609
6703
  ],
6610
6704
  providers: [
6611
6705
  { provide: windowToken, useFactory: ɵ0 }
6612
6706
  ],
6613
- exports: __spread(COMMON_COMPONENTS, GOV_UI_COMPONENTS)
6707
+ exports: __spread(COMMON_COMPONENTS, GOV_UI_COMPONENTS, [
6708
+ ngxPagination.PaginatePipe
6709
+ ])
6614
6710
  },] }
6615
6711
  ];
6616
6712
  return ExuiCommonLibModule;
@@ -7711,27 +7807,28 @@
7711
7807
  exports.ɵg = FeatureToggleDirective;
7712
7808
  exports.ɵi = LetContext;
7713
7809
  exports.ɵj = LetDirective;
7714
- exports.ɵby = GovUkCheckboxComponent;
7715
- exports.ɵce = GovUkCheckboxesComponent;
7716
- exports.ɵcd = GovUkDateComponent;
7717
- exports.ɵcb = GovUkErrorMessageComponent;
7718
- exports.ɵcc = GovUkFieldsetComponent;
7719
- exports.ɵcj = GovUkFileUploadComponent;
7720
- exports.ɵbz = GovUkFormGroupWrapperComponent;
7721
- exports.ɵbx = GovUkInputComponent;
7722
- exports.ɵca = GovUkLabelComponent;
7723
- exports.ɵcf = GovUkRadioComponent;
7724
- exports.ɵcg = GovUkRadiosComponent;
7725
- exports.ɵch = GovUkSelectComponent;
7726
- exports.ɵbw = GovukTableComponent;
7727
- exports.ɵci = GovUkTextareaComponent;
7728
- exports.ɵbv = HmctsBannerComponent;
7729
- exports.ɵbt = HmctsErrorSummaryComponent;
7810
+ exports.ɵbz = GovUkCheckboxComponent;
7811
+ exports.ɵcf = GovUkCheckboxesComponent;
7812
+ exports.ɵce = GovUkDateComponent;
7813
+ exports.ɵcc = GovUkErrorMessageComponent;
7814
+ exports.ɵcd = GovUkFieldsetComponent;
7815
+ exports.ɵck = GovUkFileUploadComponent;
7816
+ exports.ɵca = GovUkFormGroupWrapperComponent;
7817
+ exports.ɵby = GovUkInputComponent;
7818
+ exports.ɵcb = GovUkLabelComponent;
7819
+ exports.ɵcg = GovUkRadioComponent;
7820
+ exports.ɵch = GovUkRadiosComponent;
7821
+ exports.ɵci = GovUkSelectComponent;
7822
+ exports.ɵbx = GovukTableComponent;
7823
+ exports.ɵcj = GovUkTextareaComponent;
7824
+ exports.ɵbw = HmctsBannerComponent;
7825
+ exports.ɵbu = HmctsErrorSummaryComponent;
7730
7826
  exports.ɵbq = HmctsIdentityBarComponent;
7731
- exports.ɵbu = HmctsMainWrapperComponent;
7732
- exports.ɵbs = HmctsPrimaryNavigationComponent;
7733
- exports.ɵbr = HmctsSubNavigationComponent;
7734
- exports.ɵck = RemoveHostDirective;
7827
+ exports.ɵbv = HmctsMainWrapperComponent;
7828
+ exports.ɵbr = HmctsPaginationComponent;
7829
+ exports.ɵbt = HmctsPrimaryNavigationComponent;
7830
+ exports.ɵbs = HmctsSubNavigationComponent;
7831
+ exports.ɵcl = RemoveHostDirective;
7735
7832
  exports.ɵr = CaseSharingStateService;
7736
7833
  exports.ɵbg = CookieService;
7737
7834
  exports.ɵh = FeatureToggleService;