@progress/kendo-angular-inputs 10.1.1-dev.202210121020 → 10.1.1-dev.202210181135

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 (29) hide show
  1. package/bundles/kendo-angular-inputs.umd.js +1 -1
  2. package/colorpicker/color-gradient-numeric-label.directive.d.ts +20 -0
  3. package/colorpicker/color-gradient.component.d.ts +48 -5
  4. package/colorpicker/color-input.component.d.ts +14 -3
  5. package/colorpicker/color-palette.component.d.ts +16 -0
  6. package/colorpicker/colorpicker.component.d.ts +8 -2
  7. package/colorpicker/constants.d.ts +4 -0
  8. package/colorpicker/flatcolorpicker-actions.component.d.ts +4 -1
  9. package/colorpicker/flatcolorpicker-header.component.d.ts +4 -1
  10. package/colorpicker/flatcolorpicker.component.d.ts +40 -3
  11. package/colorpicker/localization/messages.d.ts +17 -1
  12. package/colorpicker/models/gradient-settings.d.ts +12 -0
  13. package/colorpicker.module.d.ts +14 -13
  14. package/esm2015/colorpicker/color-gradient-numeric-label.directive.js +29 -0
  15. package/esm2015/colorpicker/color-gradient.component.js +181 -34
  16. package/esm2015/colorpicker/color-input.component.js +71 -10
  17. package/esm2015/colorpicker/color-palette.component.js +49 -11
  18. package/esm2015/colorpicker/colorpicker.component.js +69 -11
  19. package/esm2015/colorpicker/constants.js +4 -0
  20. package/esm2015/colorpicker/flatcolorpicker-actions.component.js +20 -5
  21. package/esm2015/colorpicker/flatcolorpicker-header.component.js +36 -14
  22. package/esm2015/colorpicker/flatcolorpicker.component.js +206 -49
  23. package/esm2015/colorpicker/localization/messages.js +9 -1
  24. package/esm2015/colorpicker.module.js +4 -1
  25. package/esm2015/main.js +1 -0
  26. package/esm2015/package-metadata.js +1 -1
  27. package/fesm2015/kendo-angular-inputs.js +686 -153
  28. package/main.d.ts +1 -0
  29. package/package.json +1 -1
@@ -10,7 +10,7 @@ import { take, filter, concatMap, startWith, takeUntil, skip, debounceTime, thro
10
10
  import * as i1 from '@progress/kendo-angular-l10n';
11
11
  import { ComponentMessages, LocalizationService, L10N_PREFIX, RTL } from '@progress/kendo-angular-l10n';
12
12
  import * as i3 from '@progress/kendo-angular-common';
13
- import { Keys, guid, hasObservers, anyChanged, isDocumentAvailable, KendoInput, isChanged, DraggableModule, EventsModule, ResizeSensorModule, PreventableEvent, closest as closest$1 } from '@progress/kendo-angular-common';
13
+ import { Keys, guid, hasObservers, anyChanged, isDocumentAvailable, KendoInput, isChanged, DraggableModule, EventsModule, ResizeSensorModule, PreventableEvent, findFocusableChild, closest as closest$1 } from '@progress/kendo-angular-common';
14
14
  import { validatePackage } from '@progress/kendo-licensing';
15
15
  import * as i1$1 from '@angular/common';
16
16
  import { CommonModule } from '@angular/common';
@@ -535,7 +535,7 @@ const packageMetadata = {
535
535
  name: '@progress/kendo-angular-inputs',
536
536
  productName: 'Kendo UI for Angular',
537
537
  productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
538
- publishDate: 1665569942,
538
+ publishDate: 1666092870,
539
539
  version: '',
540
540
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
541
541
  };
@@ -8268,6 +8268,10 @@ const DEFAULT_GRADIENT_BACKGROUND_COLOR = 'rgba(255, 0, 0, 1)';
8268
8268
  * @hidden
8269
8269
  */
8270
8270
  const DRAGHANDLE_MOVE_SPEED = 5;
8271
+ /**
8272
+ * @hidden
8273
+ */
8274
+ const DRAGHANDLE_MOVE_SPEED_SMALL_STEP = 2;
8271
8275
  /**
8272
8276
  * @hidden
8273
8277
  */
@@ -8364,9 +8368,11 @@ class FlatColorPickerHeaderComponent {
8364
8368
  constructor(localizationService) {
8365
8369
  this.localizationService = localizationService;
8366
8370
  this.hostClasses = true;
8371
+ this.innerTabIndex = -1;
8367
8372
  this.viewChange = new EventEmitter();
8368
8373
  this.valuePaneClick = new EventEmitter();
8369
8374
  this.clearButtonClick = new EventEmitter();
8375
+ this.tabOut = new EventEmitter();
8370
8376
  }
8371
8377
  onViewButtonClick(view) {
8372
8378
  this.activeView = view;
@@ -8381,21 +8387,30 @@ class FlatColorPickerHeaderComponent {
8381
8387
  getText(text) {
8382
8388
  return this.localizationService.get(text);
8383
8389
  }
8390
+ onHeaderTabOut(ev, index) {
8391
+ if (index === 0) {
8392
+ ev.preventDefault();
8393
+ this.tabOut.emit();
8394
+ }
8395
+ }
8384
8396
  }
8385
8397
  FlatColorPickerHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FlatColorPickerHeaderComponent, deps: [{ token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
8386
- FlatColorPickerHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FlatColorPickerHeaderComponent, selector: "[kendoFlatColorPickerHeader]", inputs: { clearButton: "clearButton", activeView: "activeView", views: "views", preview: "preview", value: "value", selection: "selection" }, outputs: { viewChange: "viewChange", valuePaneClick: "valuePaneClick", clearButtonClick: "clearButtonClick" }, host: { properties: { "class.k-coloreditor-header": "this.hostClasses", "class.k-hstack": "this.hostClasses" } }, viewQueries: [{ propertyName: "clearButtonElement", first: true, predicate: ["clearButton"], descendants: true, read: ElementRef }, { propertyName: "viewButtonsCollection", predicate: ["viewButtons"], descendants: true, read: ElementRef }], ngImport: i0, template: `
8398
+ FlatColorPickerHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FlatColorPickerHeaderComponent, selector: "[kendoFlatColorPickerHeader]", inputs: { clearButton: "clearButton", activeView: "activeView", views: "views", preview: "preview", innerTabIndex: "innerTabIndex", value: "value", selection: "selection" }, outputs: { viewChange: "viewChange", valuePaneClick: "valuePaneClick", clearButtonClick: "clearButtonClick", tabOut: "tabOut" }, host: { properties: { "class.k-coloreditor-header": "this.hostClasses", "class.k-hstack": "this.hostClasses" } }, viewQueries: [{ propertyName: "clearButtonElement", first: true, predicate: ["clearButton"], descendants: true, read: ElementRef }, { propertyName: "viewButtonsCollection", predicate: ["viewButtons"], descendants: true, read: ElementRef }], ngImport: i0, template: `
8387
8399
  <div class="k-coloreditor-header-actions k-hstack">
8388
- <div *ngIf="viewButtons" class="k-button-group k-button-group-flat">
8389
- <button *ngFor="let view of views"
8400
+ <div
8401
+ *ngIf="viewButtons"
8402
+ class="k-button-group k-button-group-flat">
8403
+ <button *ngFor="let view of views; let i = index;"
8390
8404
  #viewButtons
8391
8405
  type="button"
8406
+ [tabindex]="innerTabIndex.toString()"
8392
8407
  (click)="onViewButtonClick(view)"
8408
+ (keydown.shift.tab)="onHeaderTabOut($event, i)"
8393
8409
  class="k-button k-button-md k-button-flat k-button-flat-base k-icon-button"
8394
8410
  [attr.title]="getText(view === 'gradient' ? 'gradientView' : 'paletteView')"
8395
8411
  [attr.aria-label]="getText(view === 'gradient' ? 'gradientView' : 'paletteView')"
8396
8412
  [attr.aria-pressed]="activeView === view"
8397
- [ngClass]="activeView === view ? 'k-selected' : ''"
8398
- >
8413
+ [ngClass]="activeView === view ? 'k-selected' : ''">
8399
8414
  <span
8400
8415
  class="k-button-icon k-icon"
8401
8416
  [ngClass]="getViewButtonIcon(view)">
@@ -8405,7 +8420,9 @@ FlatColorPickerHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
8405
8420
  </div>
8406
8421
  <div class="k-spacer"></div>
8407
8422
  <div class="k-coloreditor-header-actions k-hstack">
8408
- <button *ngIf="clearButton"
8423
+ <button
8424
+ [tabindex]="innerTabIndex.toString()"
8425
+ *ngIf="clearButton"
8409
8426
  #clearButton
8410
8427
  type="button"
8411
8428
  class="k-button k-button-md k-button-flat k-button-flat-base k-icon-button k-coloreditor-reset"
@@ -8414,7 +8431,7 @@ FlatColorPickerHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
8414
8431
  (click)="clearButtonClick.emit()">
8415
8432
  <span class="k-button-icon k-icon k-i-droplet-slash"></span>
8416
8433
  </button>
8417
- <div class="k-coloreditor-preview k-vstack" *ngIf="preview">
8434
+ <div class="k-coloreditor-preview k-vstack" *ngIf="preview" aria-hidden="true">
8418
8435
  <span
8419
8436
  class="k-coloreditor-preview-color k-color-preview"
8420
8437
  [attr.title]="getText('previewColor')"
@@ -8435,17 +8452,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8435
8452
  selector: '[kendoFlatColorPickerHeader]',
8436
8453
  template: `
8437
8454
  <div class="k-coloreditor-header-actions k-hstack">
8438
- <div *ngIf="viewButtons" class="k-button-group k-button-group-flat">
8439
- <button *ngFor="let view of views"
8455
+ <div
8456
+ *ngIf="viewButtons"
8457
+ class="k-button-group k-button-group-flat">
8458
+ <button *ngFor="let view of views; let i = index;"
8440
8459
  #viewButtons
8441
8460
  type="button"
8461
+ [tabindex]="innerTabIndex.toString()"
8442
8462
  (click)="onViewButtonClick(view)"
8463
+ (keydown.shift.tab)="onHeaderTabOut($event, i)"
8443
8464
  class="k-button k-button-md k-button-flat k-button-flat-base k-icon-button"
8444
8465
  [attr.title]="getText(view === 'gradient' ? 'gradientView' : 'paletteView')"
8445
8466
  [attr.aria-label]="getText(view === 'gradient' ? 'gradientView' : 'paletteView')"
8446
8467
  [attr.aria-pressed]="activeView === view"
8447
- [ngClass]="activeView === view ? 'k-selected' : ''"
8448
- >
8468
+ [ngClass]="activeView === view ? 'k-selected' : ''">
8449
8469
  <span
8450
8470
  class="k-button-icon k-icon"
8451
8471
  [ngClass]="getViewButtonIcon(view)">
@@ -8455,7 +8475,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8455
8475
  </div>
8456
8476
  <div class="k-spacer"></div>
8457
8477
  <div class="k-coloreditor-header-actions k-hstack">
8458
- <button *ngIf="clearButton"
8478
+ <button
8479
+ [tabindex]="innerTabIndex.toString()"
8480
+ *ngIf="clearButton"
8459
8481
  #clearButton
8460
8482
  type="button"
8461
8483
  class="k-button k-button-md k-button-flat k-button-flat-base k-icon-button k-coloreditor-reset"
@@ -8464,7 +8486,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8464
8486
  (click)="clearButtonClick.emit()">
8465
8487
  <span class="k-button-icon k-icon k-i-droplet-slash"></span>
8466
8488
  </button>
8467
- <div class="k-coloreditor-preview k-vstack" *ngIf="preview">
8489
+ <div class="k-coloreditor-preview k-vstack" *ngIf="preview" aria-hidden="true">
8468
8490
  <span
8469
8491
  class="k-coloreditor-preview-color k-color-preview"
8470
8492
  [attr.title]="getText('previewColor')"
@@ -8493,6 +8515,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8493
8515
  type: Input
8494
8516
  }], preview: [{
8495
8517
  type: Input
8518
+ }], innerTabIndex: [{
8519
+ type: Input
8496
8520
  }], value: [{
8497
8521
  type: Input
8498
8522
  }], selection: [{
@@ -8503,12 +8527,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8503
8527
  type: Output
8504
8528
  }], clearButtonClick: [{
8505
8529
  type: Output
8530
+ }], tabOut: [{
8531
+ type: Output
8506
8532
  }], viewButtonsCollection: [{
8507
8533
  type: ViewChildren,
8508
8534
  args: ['viewButtons', { read: ElementRef }]
8509
8535
  }], clearButtonElement: [{
8510
8536
  type: ViewChild,
8511
- args: ['clearButton', { read: ElementRef, static: false }]
8537
+ args: ['clearButton', { read: ElementRef }]
8512
8538
  }] } });
8513
8539
 
8514
8540
  /**
@@ -8630,6 +8656,29 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8630
8656
  type: Input
8631
8657
  }] } });
8632
8658
 
8659
+ /**
8660
+ * @hidden
8661
+ */
8662
+ class NumericLabelDirective {
8663
+ constructor(host) {
8664
+ this.host = host;
8665
+ }
8666
+ ngOnInit() {
8667
+ const localizationToken = `${this.kendoAdditionalNumericLabel}ChannelLabel`;
8668
+ this.host.numericInput.nativeElement.setAttribute('aria-label', this.localizationService.get(localizationToken));
8669
+ }
8670
+ }
8671
+ NumericLabelDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: NumericLabelDirective, deps: [{ token: NumericTextBoxComponent }], target: i0.ɵɵFactoryTarget.Directive });
8672
+ NumericLabelDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: NumericLabelDirective, selector: "[kendoAdditionalNumericLabel]", inputs: { kendoAdditionalNumericLabel: "kendoAdditionalNumericLabel", localizationService: "localizationService" }, ngImport: i0 });
8673
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: NumericLabelDirective, decorators: [{
8674
+ type: Directive,
8675
+ args: [{ selector: '[kendoAdditionalNumericLabel]' }]
8676
+ }], ctorParameters: function () { return [{ type: NumericTextBoxComponent }]; }, propDecorators: { kendoAdditionalNumericLabel: [{
8677
+ type: Input
8678
+ }], localizationService: [{
8679
+ type: Input
8680
+ }] } });
8681
+
8633
8682
  /**
8634
8683
  * @hidden
8635
8684
  */
@@ -8642,6 +8691,10 @@ class ColorInputComponent {
8642
8691
  * The id of the hex input.
8643
8692
  */
8644
8693
  this.focusableId = `k-${guid()}`;
8694
+ /**
8695
+ * The inputs tabindex.
8696
+ */
8697
+ this.tabindex = -1;
8645
8698
  /**
8646
8699
  * Sets whether the alpha slider will be shown.
8647
8700
  */
@@ -8658,6 +8711,10 @@ class ColorInputComponent {
8658
8711
  * Emits a parsed rgba string color.
8659
8712
  */
8660
8713
  this.valueChange = new EventEmitter();
8714
+ /**
8715
+ * Emits when the user tabs out of the last focusable input.
8716
+ */
8717
+ this.tabOut = new EventEmitter();
8661
8718
  this.colorInputClass = true;
8662
8719
  /**
8663
8720
  * The rgba inputs values.
@@ -8727,6 +8784,14 @@ class ColorInputComponent {
8727
8784
  handleHexInputBlur() {
8728
8785
  this.hex = parseColor(this.value, 'hex', this.opacity);
8729
8786
  }
8787
+ focusLast() {
8788
+ this.lastInput().focus();
8789
+ }
8790
+ onTab() {
8791
+ if (this.opacity) {
8792
+ return;
8793
+ }
8794
+ }
8730
8795
  toggleFormatView() {
8731
8796
  this.formatView = this.formatView === 'hex' ? 'rgba' : 'hex';
8732
8797
  }
@@ -8736,14 +8801,20 @@ class ColorInputComponent {
8736
8801
  }
8737
8802
  this.subscriptions.add(this.renderer.listen(this.toggleFormatButton.nativeElement, 'click', () => this.toggleFormatView()));
8738
8803
  }
8804
+ lastInput() {
8805
+ var _a;
8806
+ return ((_a = this.hexInput) === null || _a === void 0 ? void 0 : _a.nativeElement) || this.opacityInput || this.blueInput;
8807
+ }
8739
8808
  }
8740
8809
  ColorInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorInputComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
8741
- ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorInputComponent, selector: "kendo-colorinput", inputs: { focusableId: "focusableId", formatView: "formatView", value: "value", opacity: "opacity", disabled: "disabled", readonly: "readonly" }, outputs: { valueChange: "valueChange" }, host: { properties: { "class.k-colorgradient-inputs": "this.colorInputClass", "class.k-hstack": "this.colorInputClass" } }, viewQueries: [{ propertyName: "opacityInput", first: true, predicate: ["opacityInput"], descendants: true }, { propertyName: "hexInput", first: true, predicate: ["hexInput"], descendants: true, read: ElementRef }, { propertyName: "blueInput", first: true, predicate: ["blueInput"], descendants: true, read: ElementRef }, { propertyName: "toggleFormatButton", first: true, predicate: ["toggleFormatButton"], descendants: true }], usesOnChanges: true, ngImport: i0, template: `
8810
+ ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorInputComponent, selector: "kendo-colorinput", inputs: { focusableId: "focusableId", formatView: "formatView", tabindex: "tabindex", value: "value", opacity: "opacity", disabled: "disabled", readonly: "readonly" }, outputs: { valueChange: "valueChange", tabOut: "tabOut" }, host: { properties: { "class.k-colorgradient-inputs": "this.colorInputClass", "class.k-hstack": "this.colorInputClass" } }, viewQueries: [{ propertyName: "opacityInput", first: true, predicate: ["opacityInput"], descendants: true }, { propertyName: "hexInput", first: true, predicate: ["hexInput"], descendants: true }, { propertyName: "blueInput", first: true, predicate: ["blueInput"], descendants: true }, { propertyName: "toggleFormatButton", first: true, predicate: ["toggleFormatButton"], descendants: true }], usesOnChanges: true, ngImport: i0, template: `
8742
8811
  <div class="k-vstack">
8743
8812
  <button #toggleFormatButton
8744
8813
  class="k-colorgradient-toggle-mode k-button k-button-md k-button-flat k-button-flat-base k-icon-button"
8745
8814
  [attr.aria-label]="formatButtonTitle"
8746
8815
  [attr.title]="formatButtonTitle"
8816
+ [disabled]="disabled"
8817
+ [tabindex]="tabindex.toString()"
8747
8818
  type="button"
8748
8819
  >
8749
8820
  <span class="k-button-icon k-icon k-i-caret-alt-expand"></span>
@@ -8759,6 +8830,8 @@ ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
8759
8830
  [value]="hex || ''"
8760
8831
  (blur)="handleHexInputBlur()"
8761
8832
  (input)="handleHexValueChange(hexInput.value)"
8833
+ [tabindex]="tabindex.toString()"
8834
+ (keydown.tab)="$event.preventDefault(); tabOut.emit();"
8762
8835
  />
8763
8836
  <label [for]="focusableId" class="k-colorgradient-input-label">HEX</label>
8764
8837
  </div>
@@ -8766,8 +8839,11 @@ ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
8766
8839
  <div class="k-vstack">
8767
8840
  <kendo-numerictextbox
8768
8841
  #red
8842
+ kendoAdditionalNumericLabel="red"
8843
+ [localizationService]="localizationService"
8769
8844
  [disabled]="disabled"
8770
8845
  [readonly]="readonly"
8846
+ [tabindex]="tabindex"
8771
8847
  [min]="0"
8772
8848
  [max]="255"
8773
8849
  [(value)]="rgba.r"
@@ -8783,8 +8859,11 @@ ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
8783
8859
  <div class="k-vstack">
8784
8860
  <kendo-numerictextbox
8785
8861
  #green
8862
+ kendoAdditionalNumericLabel="green"
8863
+ [localizationService]="localizationService"
8786
8864
  [disabled]="disabled"
8787
8865
  [readonly]="readonly"
8866
+ [tabindex]="tabindex"
8788
8867
  [min]="0"
8789
8868
  [max]="255"
8790
8869
  [(value)]="rgba.g"
@@ -8800,8 +8879,11 @@ ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
8800
8879
  <div class="k-vstack">
8801
8880
  <kendo-numerictextbox
8802
8881
  #blue
8882
+ kendoAdditionalNumericLabel="blue"
8883
+ [localizationService]="localizationService"
8803
8884
  [disabled]="disabled"
8804
8885
  [readonly]="readonly"
8886
+ [tabindex]="tabindex"
8805
8887
  [min]="0"
8806
8888
  [max]="255"
8807
8889
  [(value)]="rgba.b"
@@ -8810,15 +8892,19 @@ ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
8810
8892
  [format]="'n'"
8811
8893
  [decimals]="0"
8812
8894
  (blur)="handleRgbaInputBlur()"
8813
- (valueChange)="handleRgbaValueChange()">
8895
+ (valueChange)="handleRgbaValueChange()"
8896
+ (keydown.tab)="onTab()">
8814
8897
  </kendo-numerictextbox>
8815
8898
  <label [for]="blue.focusableId" class="k-colorgradient-input-label">B</label>
8816
8899
  </div>
8817
8900
  <div class="k-vstack" *ngIf="opacity">
8818
8901
  <kendo-numerictextbox #opacityInput
8819
8902
  #alpha
8903
+ kendoAdditionalNumericLabel="alpha"
8904
+ [localizationService]="localizationService"
8820
8905
  [disabled]="disabled"
8821
8906
  [readonly]="readonly"
8907
+ [tabindex]="tabindex"
8822
8908
  [min]="0"
8823
8909
  [max]="1"
8824
8910
  [(value)]="rgba.a"
@@ -8828,12 +8914,13 @@ ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
8828
8914
  [format]="'n2'"
8829
8915
  [decimals]="2"
8830
8916
  (blur)="handleRgbaInputBlur()"
8831
- (valueChange)="handleRgbaValueChange()">
8917
+ (valueChange)="handleRgbaValueChange()"
8918
+ (keydown.tab)="$event.preventDefault(); tabOut.emit();">
8832
8919
  </kendo-numerictextbox>
8833
8920
  <label [for]="alpha.focusableId" class="k-colorgradient-input-label">A</label>
8834
8921
  </div>
8835
8922
  </ng-container>
8836
- `, isInline: true, components: [{ type: NumericTextBoxComponent, selector: "kendo-numerictextbox", inputs: ["focusableId", "disabled", "readonly", "title", "autoCorrect", "format", "max", "min", "decimals", "placeholder", "step", "spinners", "rangeValidation", "tabindex", "tabIndex", "changeValueOnScroll", "selectOnFocus", "value", "maxlength", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur"], exportAs: ["kendoNumericTextBox"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
8923
+ `, isInline: true, components: [{ type: NumericTextBoxComponent, selector: "kendo-numerictextbox", inputs: ["focusableId", "disabled", "readonly", "title", "autoCorrect", "format", "max", "min", "decimals", "placeholder", "step", "spinners", "rangeValidation", "tabindex", "tabIndex", "changeValueOnScroll", "selectOnFocus", "value", "maxlength", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur"], exportAs: ["kendoNumericTextBox"] }], directives: [{ type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: NumericLabelDirective, selector: "[kendoAdditionalNumericLabel]", inputs: ["kendoAdditionalNumericLabel", "localizationService"] }] });
8837
8924
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorInputComponent, decorators: [{
8838
8925
  type: Component,
8839
8926
  args: [{
@@ -8844,6 +8931,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8844
8931
  class="k-colorgradient-toggle-mode k-button k-button-md k-button-flat k-button-flat-base k-icon-button"
8845
8932
  [attr.aria-label]="formatButtonTitle"
8846
8933
  [attr.title]="formatButtonTitle"
8934
+ [disabled]="disabled"
8935
+ [tabindex]="tabindex.toString()"
8847
8936
  type="button"
8848
8937
  >
8849
8938
  <span class="k-button-icon k-icon k-i-caret-alt-expand"></span>
@@ -8859,6 +8948,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8859
8948
  [value]="hex || ''"
8860
8949
  (blur)="handleHexInputBlur()"
8861
8950
  (input)="handleHexValueChange(hexInput.value)"
8951
+ [tabindex]="tabindex.toString()"
8952
+ (keydown.tab)="$event.preventDefault(); tabOut.emit();"
8862
8953
  />
8863
8954
  <label [for]="focusableId" class="k-colorgradient-input-label">HEX</label>
8864
8955
  </div>
@@ -8866,8 +8957,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8866
8957
  <div class="k-vstack">
8867
8958
  <kendo-numerictextbox
8868
8959
  #red
8960
+ kendoAdditionalNumericLabel="red"
8961
+ [localizationService]="localizationService"
8869
8962
  [disabled]="disabled"
8870
8963
  [readonly]="readonly"
8964
+ [tabindex]="tabindex"
8871
8965
  [min]="0"
8872
8966
  [max]="255"
8873
8967
  [(value)]="rgba.r"
@@ -8883,8 +8977,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8883
8977
  <div class="k-vstack">
8884
8978
  <kendo-numerictextbox
8885
8979
  #green
8980
+ kendoAdditionalNumericLabel="green"
8981
+ [localizationService]="localizationService"
8886
8982
  [disabled]="disabled"
8887
8983
  [readonly]="readonly"
8984
+ [tabindex]="tabindex"
8888
8985
  [min]="0"
8889
8986
  [max]="255"
8890
8987
  [(value)]="rgba.g"
@@ -8900,8 +8997,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8900
8997
  <div class="k-vstack">
8901
8998
  <kendo-numerictextbox
8902
8999
  #blue
9000
+ kendoAdditionalNumericLabel="blue"
9001
+ [localizationService]="localizationService"
8903
9002
  [disabled]="disabled"
8904
9003
  [readonly]="readonly"
9004
+ [tabindex]="tabindex"
8905
9005
  [min]="0"
8906
9006
  [max]="255"
8907
9007
  [(value)]="rgba.b"
@@ -8910,15 +9010,19 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8910
9010
  [format]="'n'"
8911
9011
  [decimals]="0"
8912
9012
  (blur)="handleRgbaInputBlur()"
8913
- (valueChange)="handleRgbaValueChange()">
9013
+ (valueChange)="handleRgbaValueChange()"
9014
+ (keydown.tab)="onTab()">
8914
9015
  </kendo-numerictextbox>
8915
9016
  <label [for]="blue.focusableId" class="k-colorgradient-input-label">B</label>
8916
9017
  </div>
8917
9018
  <div class="k-vstack" *ngIf="opacity">
8918
9019
  <kendo-numerictextbox #opacityInput
8919
9020
  #alpha
9021
+ kendoAdditionalNumericLabel="alpha"
9022
+ [localizationService]="localizationService"
8920
9023
  [disabled]="disabled"
8921
9024
  [readonly]="readonly"
9025
+ [tabindex]="tabindex"
8922
9026
  [min]="0"
8923
9027
  [max]="1"
8924
9028
  [(value)]="rgba.a"
@@ -8928,7 +9032,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8928
9032
  [format]="'n2'"
8929
9033
  [decimals]="2"
8930
9034
  (blur)="handleRgbaInputBlur()"
8931
- (valueChange)="handleRgbaValueChange()">
9035
+ (valueChange)="handleRgbaValueChange()"
9036
+ (keydown.tab)="$event.preventDefault(); tabOut.emit();">
8932
9037
  </kendo-numerictextbox>
8933
9038
  <label [for]="alpha.focusableId" class="k-colorgradient-input-label">A</label>
8934
9039
  </div>
@@ -8939,6 +9044,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8939
9044
  type: Input
8940
9045
  }], formatView: [{
8941
9046
  type: Input
9047
+ }], tabindex: [{
9048
+ type: Input
8942
9049
  }], value: [{
8943
9050
  type: Input
8944
9051
  }], opacity: [{
@@ -8949,6 +9056,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8949
9056
  type: Input
8950
9057
  }], valueChange: [{
8951
9058
  type: Output
9059
+ }], tabOut: [{
9060
+ type: Output
8952
9061
  }], colorInputClass: [{
8953
9062
  type: HostBinding,
8954
9063
  args: ['class.k-colorgradient-inputs']
@@ -8957,13 +9066,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
8957
9066
  args: ['class.k-hstack']
8958
9067
  }], opacityInput: [{
8959
9068
  type: ViewChild,
8960
- args: ['opacityInput', { static: false }]
9069
+ args: ['opacityInput']
8961
9070
  }], hexInput: [{
8962
9071
  type: ViewChild,
8963
- args: ['hexInput', { read: ElementRef, static: false }]
9072
+ args: ['hexInput']
8964
9073
  }], blueInput: [{
8965
9074
  type: ViewChild,
8966
- args: ['blueInput', { read: ElementRef, static: false }]
9075
+ args: ['blueInput']
8967
9076
  }], toggleFormatButton: [{
8968
9077
  type: ViewChild,
8969
9078
  args: ['toggleFormatButton', { static: false }]
@@ -9119,7 +9228,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9119
9228
  class ColorPickerMessages extends ComponentMessages {
9120
9229
  }
9121
9230
  ColorPickerMessages.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorPickerMessages, deps: null, target: i0.ɵɵFactoryTarget.Directive });
9122
- ColorPickerMessages.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: ColorPickerMessages, selector: "kendo-colorpicker-messages-base", inputs: { colorPaletteNoColor: "colorPaletteNoColor", colorGradientNoColor: "colorGradientNoColor", flatColorPickerNoColor: "flatColorPickerNoColor", colorPickerNoColor: "colorPickerNoColor", colorGradientHandle: "colorGradientHandle", clearButton: "clearButton", hueSliderHandle: "hueSliderHandle", opacitySliderHandle: "opacitySliderHandle", hexInputPlaceholder: "hexInputPlaceholder", redInputPlaceholder: "redInputPlaceholder", greenInputPlaceholder: "greenInputPlaceholder", blueInputPlaceholder: "blueInputPlaceholder", alphaInputPlaceholder: "alphaInputPlaceholder", passContrast: "passContrast", failContrast: "failContrast", contrastRatio: "contrastRatio", previewColor: "previewColor", revertSelection: "revertSelection", gradientView: "gradientView", paletteView: "paletteView", formatButton: "formatButton", applyButton: "applyButton", cancelButton: "cancelButton" }, usesInheritance: true, ngImport: i0 });
9231
+ ColorPickerMessages.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: ColorPickerMessages, selector: "kendo-colorpicker-messages-base", inputs: { colorPaletteNoColor: "colorPaletteNoColor", colorGradientNoColor: "colorGradientNoColor", flatColorPickerNoColor: "flatColorPickerNoColor", colorPickerNoColor: "colorPickerNoColor", colorGradientHandle: "colorGradientHandle", clearButton: "clearButton", hueSliderHandle: "hueSliderHandle", opacitySliderHandle: "opacitySliderHandle", hexInputPlaceholder: "hexInputPlaceholder", redInputPlaceholder: "redInputPlaceholder", greenInputPlaceholder: "greenInputPlaceholder", blueInputPlaceholder: "blueInputPlaceholder", alphaInputPlaceholder: "alphaInputPlaceholder", redChannelLabel: "redChannelLabel", greenChannelLabel: "greenChannelLabel", blueChannelLabel: "blueChannelLabel", alphaChannelLabel: "alphaChannelLabel", passContrast: "passContrast", failContrast: "failContrast", contrastRatio: "contrastRatio", previewColor: "previewColor", revertSelection: "revertSelection", gradientView: "gradientView", paletteView: "paletteView", formatButton: "formatButton", applyButton: "applyButton", cancelButton: "cancelButton" }, usesInheritance: true, ngImport: i0 });
9123
9232
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorPickerMessages, decorators: [{
9124
9233
  type: Directive,
9125
9234
  args: [{
@@ -9152,6 +9261,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9152
9261
  type: Input
9153
9262
  }], alphaInputPlaceholder: [{
9154
9263
  type: Input
9264
+ }], redChannelLabel: [{
9265
+ type: Input
9266
+ }], greenChannelLabel: [{
9267
+ type: Input
9268
+ }], blueChannelLabel: [{
9269
+ type: Input
9270
+ }], alphaChannelLabel: [{
9271
+ type: Input
9155
9272
  }], passContrast: [{
9156
9273
  type: Input
9157
9274
  }], failContrast: [{
@@ -9209,13 +9326,15 @@ let serial$3 = 0;
9209
9326
  * The ColorGradient is independently used by `kendo-colorpicker` and can be directly added to the page.
9210
9327
  */
9211
9328
  class ColorGradientComponent {
9212
- constructor(host, ngZone, renderer, cdr, localizationService) {
9329
+ constructor(host, ngZone, renderer, cdr, localizationService, injector) {
9213
9330
  this.host = host;
9214
9331
  this.ngZone = ngZone;
9215
9332
  this.renderer = renderer;
9216
9333
  this.cdr = cdr;
9217
9334
  this.localizationService = localizationService;
9335
+ this.injector = injector;
9218
9336
  this.hostClasses = true;
9337
+ this.ariaRole = 'textbox';
9219
9338
  /**
9220
9339
  * @hidden
9221
9340
  */
@@ -9276,11 +9395,28 @@ class ColorGradientComponent {
9276
9395
  * updated on moving the drag handle or the sliders.
9277
9396
  */
9278
9397
  this.hsva = new BehaviorSubject({});
9398
+ /**
9399
+ * Determines the step (in pixels) when moving the gradient drag handle using the keyboard arrow keys.
9400
+ *
9401
+ * @default 5
9402
+ */
9403
+ this.gradientSliderStep = DRAGHANDLE_MOVE_SPEED;
9404
+ /**
9405
+ * Determines the step (in pixels) when moving the gradient drag handle using the keyboard arrow keys while holding the shift key.
9406
+ *
9407
+ * @default 2
9408
+ */
9409
+ this.gradientSliderSmallStep = DRAGHANDLE_MOVE_SPEED_SMALL_STEP;
9410
+ /**
9411
+ * @hidden
9412
+ */
9413
+ this.internalNavigation = false;
9279
9414
  this._tabindex = 0;
9280
9415
  this.listeners = [];
9281
9416
  this.hueSliderTouched = false;
9282
9417
  this.alphaSliderTouched = false;
9283
9418
  this.updateValues = new Subject();
9419
+ this.hsvHandleCoordinates = { x: 0, y: 0 };
9284
9420
  this.notifyNgChanged = () => { };
9285
9421
  this.notifyNgTouched = () => { };
9286
9422
  validatePackage(packageMetadata);
@@ -9298,7 +9434,42 @@ class ColorGradientComponent {
9298
9434
  return this.id;
9299
9435
  }
9300
9436
  get hostTabindex() {
9301
- return this.tabindex;
9437
+ var _a;
9438
+ return ((_a = this.tabindex) === null || _a === void 0 ? void 0 : _a.toString()) || '0';
9439
+ }
9440
+ get isControlInvalid() {
9441
+ var _a, _b;
9442
+ return (_b = ((_a = this.control) === null || _a === void 0 ? void 0 : _a.invalid)) === null || _b === void 0 ? void 0 : _b.toString();
9443
+ }
9444
+ get isDisabled() {
9445
+ var _a;
9446
+ return ((_a = this.disabled) === null || _a === void 0 ? void 0 : _a.toString()) || undefined;
9447
+ }
9448
+ /**
9449
+ * @hidden
9450
+ */
9451
+ enterHandler(event) {
9452
+ if (event.target !== this.host.nativeElement) {
9453
+ return;
9454
+ }
9455
+ this.internalNavigation = true;
9456
+ this.gradientDragHandle.nativeElement.focus();
9457
+ }
9458
+ /**
9459
+ * @hidden
9460
+ */
9461
+ escapeHandler(event) {
9462
+ if (!this.host.nativeElement.matches(':focus')) {
9463
+ event.stopImmediatePropagation();
9464
+ }
9465
+ this.internalNavigation = false;
9466
+ this.host.nativeElement.focus();
9467
+ }
9468
+ /**
9469
+ * @hidden
9470
+ */
9471
+ focusHandler(ev) {
9472
+ this.internalNavigation = ev.target !== this.host.nativeElement;
9302
9473
  }
9303
9474
  /**
9304
9475
  * Specifies the value of the initially selected color.
@@ -9359,12 +9530,27 @@ class ColorGradientComponent {
9359
9530
  get gradientRect() {
9360
9531
  return this.gradientWrapper.nativeElement.getBoundingClientRect();
9361
9532
  }
9533
+ /**
9534
+ * @hidden
9535
+ */
9536
+ get hsvSliderValueText() {
9537
+ return `X: ${this.hsvHandleCoordinates.x} Y: ${this.hsvHandleCoordinates.y}`;
9538
+ }
9362
9539
  /**
9363
9540
  * @hidden
9364
9541
  */
9365
9542
  get contrastToolVisible() {
9366
9543
  return this.contrastTool && this.contrastTool.length > 0;
9367
9544
  }
9545
+ /**
9546
+ * @hidden
9547
+ */
9548
+ get innerTabIndex() {
9549
+ return this.internalNavigation ? 0 : -1;
9550
+ }
9551
+ ngOnInit() {
9552
+ this.control = this.injector.get(NgControl, null);
9553
+ }
9368
9554
  ngAfterViewInit() {
9369
9555
  this.updateUI();
9370
9556
  this.cdr.detectChanges();
@@ -9447,18 +9633,19 @@ class ColorGradientComponent {
9447
9633
  this.renderer.addClass(this.gradientWrapper.nativeElement, 'k-dragging');
9448
9634
  let keyboardMoveX = 0;
9449
9635
  let keyboardMoveY = 0;
9636
+ const shiftKey = args.shiftKey;
9450
9637
  switch (args.key) {
9451
9638
  case 'ArrowRight':
9452
- keyboardMoveX = DRAGHANDLE_MOVE_SPEED;
9639
+ keyboardMoveX = shiftKey ? this.gradientSliderSmallStep : this.gradientSliderStep;
9453
9640
  break;
9454
9641
  case 'ArrowLeft':
9455
- keyboardMoveX = -DRAGHANDLE_MOVE_SPEED;
9642
+ keyboardMoveX = shiftKey ? -this.gradientSliderSmallStep : -this.gradientSliderStep;
9456
9643
  break;
9457
9644
  case 'ArrowUp':
9458
- keyboardMoveY = -DRAGHANDLE_MOVE_SPEED;
9645
+ keyboardMoveY = shiftKey ? -this.gradientSliderSmallStep : -this.gradientSliderStep;
9459
9646
  break;
9460
9647
  case 'ArrowDown':
9461
- keyboardMoveY = DRAGHANDLE_MOVE_SPEED;
9648
+ keyboardMoveY = shiftKey ? this.gradientSliderSmallStep : this.gradientSliderStep;
9462
9649
  break;
9463
9650
  default: break;
9464
9651
  }
@@ -9554,7 +9741,7 @@ class ColorGradientComponent {
9554
9741
  */
9555
9742
  get colorGradientHandleAriaLabel() {
9556
9743
  const parsed = parseColor(this.value, this.format, this.opacity);
9557
- return `${this.value ? parsed : this.localizationService.get('colorGradientHandle')}`;
9744
+ return `${this.value ? parsed : this.localizationService.get('colorGradientNoColor')}`;
9558
9745
  }
9559
9746
  /**
9560
9747
  * @hidden
@@ -9606,6 +9793,7 @@ class ColorGradientComponent {
9606
9793
  }
9607
9794
  setDragHandleElementPosition(top, left) {
9608
9795
  const dragHandle = this.gradientDragHandle.nativeElement;
9796
+ this.hsvHandleCoordinates = { x: left, y: top };
9609
9797
  this.renderer.setStyle(dragHandle, 'top', `${top}px`);
9610
9798
  this.renderer.setStyle(dragHandle, 'left', `${left}px`);
9611
9799
  }
@@ -9678,8 +9866,8 @@ class ColorGradientComponent {
9678
9866
  }
9679
9867
  }
9680
9868
  }
9681
- ColorGradientComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorGradientComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
9682
- ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorGradientComponent, selector: "kendo-colorgradient", inputs: { id: "id", opacity: "opacity", disabled: "disabled", readonly: "readonly", clearButton: "clearButton", delay: "delay", value: "value", contrastTool: "contrastTool", tabindex: "tabindex", format: "format" }, outputs: { valueChange: "valueChange" }, host: { properties: { "class.k-colorgradient": "this.hostClasses", "attr.aria-readonly": "this.readonlyAttribute", "class.k-disabled": "this.disabledClass", "attr.id": "this.gradientId", "attr.dir": "this.direction", "attr.tabindex": "this.hostTabindex" } }, providers: [
9869
+ ColorGradientComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorGradientComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i1.LocalizationService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
9870
+ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorGradientComponent, selector: "kendo-colorgradient", inputs: { id: "id", opacity: "opacity", disabled: "disabled", readonly: "readonly", clearButton: "clearButton", delay: "delay", value: "value", contrastTool: "contrastTool", tabindex: "tabindex", format: "format", gradientSliderStep: "gradientSliderStep", gradientSliderSmallStep: "gradientSliderSmallStep" }, outputs: { valueChange: "valueChange" }, host: { listeners: { "keydown.enter": "enterHandler($event)", "keydown.escape": "escapeHandler($event)", "focusin": "focusHandler($event)" }, properties: { "class.k-colorgradient": "this.hostClasses", "attr.aria-readonly": "this.readonlyAttribute", "class.k-disabled": "this.disabledClass", "attr.id": "this.gradientId", "attr.dir": "this.direction", "attr.tabindex": "this.hostTabindex", "attr.role": "this.ariaRole", "attr.aria-invalid": "this.isControlInvalid", "attr.aria-disabled": "this.isDisabled" } }, providers: [
9683
9871
  {
9684
9872
  multi: true,
9685
9873
  provide: NG_VALUE_ACCESSOR,
@@ -9698,7 +9886,7 @@ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
9698
9886
  provide: L10N_PREFIX,
9699
9887
  useValue: 'kendo.colorgradient'
9700
9888
  }
9701
- ], viewQueries: [{ propertyName: "gradientDragHandle", first: true, predicate: ["gradientDragHandle"], descendants: true, read: ElementRef }, { propertyName: "inputs", first: true, predicate: ["inputs"], descendants: true }, { propertyName: "alphaSlider", first: true, predicate: ["alphaSlider"], descendants: true }, { propertyName: "gradientWrapper", first: true, predicate: ["gradientWrapper"], descendants: true }, { propertyName: "hsvRectangle", first: true, predicate: ["hsvRectangle"], descendants: true }], exportAs: ["kendoColorGradient"], usesOnChanges: true, ngImport: i0, template: `
9889
+ ], viewQueries: [{ propertyName: "gradientDragHandle", first: true, predicate: ["gradientDragHandle"], descendants: true }, { propertyName: "inputs", first: true, predicate: ["inputs"], descendants: true }, { propertyName: "alphaSlider", first: true, predicate: ["alphaSlider"], descendants: true }, { propertyName: "gradientWrapper", first: true, predicate: ["gradientWrapper"], descendants: true }, { propertyName: "hsvRectangle", first: true, predicate: ["hsvRectangle"], descendants: true }], exportAs: ["kendoColorGradient"], usesOnChanges: true, ngImport: i0, template: `
9702
9890
  <ng-container kendoColorGradientLocalizedMessages
9703
9891
  i18n-colorGradientNoColor="kendo.colorgradient.colorGradientNoColor|The aria-label applied to the ColorGradient component when the value is empty."
9704
9892
  colorGradientNoColor="Colorgradient no color chosen"
@@ -9717,7 +9905,23 @@ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
9717
9905
  i18n-contrastRatio="kendo.colorgradient.contrastRatio|The contrast ratio message for the contrast tool."
9718
9906
  contrastRatio="Contrast ratio"
9719
9907
  i18n-formatButton="kendo.colorgradient.formatButton|The message for the input format toggle button."
9720
- formatButton="Change color format">
9908
+ formatButton="Change color format"
9909
+ i18n-redChannelLabel="kendo.colorgradient.redChannelLabel|The label of the NumericTextBox representing the red color channel."
9910
+ redChannelLabel="Red channel"
9911
+ i18n-greenChannelLabel="kendo.colorgradient.greenChannelLabel|The label of the NumericTextBox representing the green color channel."
9912
+ greenChannelLabel="Green channel"
9913
+ i18n-blueChannelLabel="kendo.colorgradient.blueChannelLabel|The label of the NumericTextBox representing the blue color channel."
9914
+ blueChannelLabel="Blue channel"
9915
+ i18n-alphaChannelLabel="kendo.colorgradient.alphaChannelLabel|The label of the NumericTextBox representing the alpha color channel."
9916
+ alphaChannelLabel="Alpha channel"
9917
+ i18n-redInputPlaceholder="kendo.colorgradient.redInputPlaceholder|The placeholder for the red color input."
9918
+ redChannelLabel="R"
9919
+ i18n-greenInputPlaceholder="kendo.colorgradient.greenInputPlaceholder|The placeholder for the green color input."
9920
+ greenInputPlaceholder="G"
9921
+ i18n-blueInputPlaceholder="kendo.colorgradient.blueInputPlaceholder|The placeholder for the blue color input."
9922
+ blueInputPlaceholder="B"
9923
+ i18n-hexInputPlaceholder="kendo.colorgradient.hexInputPlaceholder|The placeholder for the HEX color input."
9924
+ hexInputPlaceholder="HEX">
9721
9925
  </ng-container>
9722
9926
  <div class="k-colorgradient-canvas k-hstack">
9723
9927
  <div class="k-hsv-rectangle" #hsvRectangle>
@@ -9732,10 +9936,16 @@ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
9732
9936
  <div
9733
9937
  #gradientDragHandle
9734
9938
  class="k-hsv-draghandle k-draghandle"
9735
- tabindex="0"
9939
+ [tabindex]="innerTabIndex.toString()"
9736
9940
  [attr.title]="colorGradientHandleTitle"
9737
- [attr.aria-label]="colorGradientHandleAriaLabel"
9738
- >
9941
+ [attr.aria-label]="colorGradientHandleTitle + ' ' + colorGradientHandleAriaLabel"
9942
+ role="slider"
9943
+ [attr.aria-valuetext]="hsvSliderValueText"
9944
+ [attr.aria-readonly]="readonly ? readonly : undefined"
9945
+ [attr.aria-disabled]="disabled ? disabled : undefined"
9946
+ [attr.aria-orientation]="'undefined'"
9947
+ [attr.aria-valuenow]="'0'"
9948
+ (keydown.shift.tab)="$event.preventDefault(); inputs.focusLast();">
9739
9949
  </div>
9740
9950
  </div>
9741
9951
  <svg kendoColorContrastSvg
@@ -9750,22 +9960,24 @@ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
9750
9960
  <div class="k-hsv-controls k-hstack {{ clearButton ? 'k-sliders-wrap-clearable' : '' }}">
9751
9961
  <span class="k-clear-color k-button k-button-md k-button-flat k-button-flat-base k-button-icon"
9752
9962
  *ngIf="clearButton"
9963
+ role="button"
9753
9964
  (click)="reset()"
9754
9965
  (keydown.enter)="reset()"
9755
9966
  (keydown.space)="reset()"
9756
9967
  [attr.aria-label]="clearButtonTitle"
9757
9968
  [attr.title]="clearButtonTitle"
9758
- tabindex="0">
9969
+ [tabindex]="innerTabIndex.toString()">
9759
9970
  <span class="k-icon k-i-droplet-slash"></span>
9760
9971
  </span>
9761
9972
  <kendo-slider
9762
9973
  [ngClass]="{'k-align-self-end': clearButton}"
9763
9974
  class="k-hue-slider k-colorgradient-slider"
9764
9975
  [dragHandleTitle]="hueSliderTitle"
9976
+ [tabindex]="innerTabIndex"
9765
9977
  [disabled]="disabled"
9766
9978
  [readonly]="readonly"
9767
9979
  [showButtons]="false"
9768
- [tickPlacement]="'none'"
9980
+ tickPlacement="none"
9769
9981
  [vertical]="true"
9770
9982
  [min]="0"
9771
9983
  [max]="360"
@@ -9778,13 +9990,14 @@ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
9778
9990
  <kendo-slider
9779
9991
  *ngIf="opacity"
9780
9992
  #alphaSlider
9993
+ [tabindex]="innerTabIndex"
9781
9994
  [ngClass]="{'k-align-self-end': clearButton}"
9782
9995
  class="k-alpha-slider k-colorgradient-slider"
9783
9996
  [dragHandleTitle]="opacitySliderTitle"
9784
9997
  [disabled]="disabled"
9785
9998
  [readonly]="readonly"
9786
9999
  [showButtons]="false"
9787
- [tickPlacement]="'none'"
10000
+ tickPlacement="none"
9788
10001
  [vertical]="true"
9789
10002
  [min]="0"
9790
10003
  [max]="100"
@@ -9797,12 +10010,14 @@ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
9797
10010
  </div>
9798
10011
  </div>
9799
10012
  <kendo-colorinput #inputs
10013
+ [tabindex]="innerTabIndex"
9800
10014
  [opacity]="opacity"
9801
10015
  [formatView]="format"
9802
10016
  [value]="value"
9803
10017
  [disabled]="disabled"
9804
10018
  [readonly]="readonly"
9805
10019
  (valueChange)="handleInputsValueChange($event)"
10020
+ (tabOut)="gradientDragHandle.focus()"
9806
10021
  >
9807
10022
  </kendo-colorinput>
9808
10023
  <div class="k-colorgradient-color-contrast k-vbox"
@@ -9811,7 +10026,7 @@ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
9811
10026
  [value]="value"
9812
10027
  [ratio]="contrastTool">
9813
10028
  </div>
9814
- `, isInline: true, styles: ["\n .k-clear-color {\n position: absolute;\n top: 0;\n left: 50%;\n transform: translateX(-50%);\n }\n .k-colorgradient-slider.k-align-self-end {\n height: 140px;\n }\n\n .k-color-contrast-svg {\n position: absolute;\n overflow: visible;\n pointer-events: none;\n left: 0px;\n top: 0px;\n }\n "], components: [{ type: ColorContrastSvgComponent, selector: "[kendoColorContrastSvg]", inputs: ["wrapper", "hsva", "backgroundColor"] }, { type: SliderComponent, selector: "kendo-slider", inputs: ["focusableId", "dragHandleTitle", "incrementTitle", "animate", "decrementTitle", "showButtons", "value", "tabIndex"], exportAs: ["kendoSlider"] }, { type: ColorInputComponent, selector: "kendo-colorinput", inputs: ["focusableId", "formatView", "value", "opacity", "disabled", "readonly"], outputs: ["valueChange"] }, { type: ContrastComponent, selector: "[kendoContrastTool]", inputs: ["value", "ratio"] }], directives: [{ type: LocalizedColorPickerMessagesDirective, selector: "[kendoColorPickerLocalizedMessages], [kendoFlatColorPickerLocalizedMessages], [kendoColorGradientLocalizedMessages], [kendoColorPaletteLocalizedMessages]" }, { type: i3.DraggableDirective, selector: "[kendoDraggable]", inputs: ["enableDrag"], outputs: ["kendoPress", "kendoDrag", "kendoRelease"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
10029
+ `, isInline: true, styles: ["\n .k-clear-color {\n position: absolute;\n top: 0;\n left: 50%;\n transform: translateX(-50%);\n }\n .k-colorgradient-slider.k-align-self-end {\n height: 140px;\n }\n\n .k-color-contrast-svg {\n position: absolute;\n overflow: visible;\n pointer-events: none;\n left: 0px;\n top: 0px;\n }\n "], components: [{ type: ColorContrastSvgComponent, selector: "[kendoColorContrastSvg]", inputs: ["wrapper", "hsva", "backgroundColor"] }, { type: SliderComponent, selector: "kendo-slider", inputs: ["focusableId", "dragHandleTitle", "incrementTitle", "animate", "decrementTitle", "showButtons", "value", "tabIndex"], exportAs: ["kendoSlider"] }, { type: ColorInputComponent, selector: "kendo-colorinput", inputs: ["focusableId", "formatView", "tabindex", "value", "opacity", "disabled", "readonly"], outputs: ["valueChange", "tabOut"] }, { type: ContrastComponent, selector: "[kendoContrastTool]", inputs: ["value", "ratio"] }], directives: [{ type: LocalizedColorPickerMessagesDirective, selector: "[kendoColorPickerLocalizedMessages], [kendoFlatColorPickerLocalizedMessages], [kendoColorGradientLocalizedMessages], [kendoColorPaletteLocalizedMessages]" }, { type: i3.DraggableDirective, selector: "[kendoDraggable]", inputs: ["enableDrag"], outputs: ["kendoPress", "kendoDrag", "kendoRelease"] }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
9815
10030
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorGradientComponent, decorators: [{
9816
10031
  type: Component,
9817
10032
  args: [{
@@ -9856,7 +10071,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9856
10071
  i18n-contrastRatio="kendo.colorgradient.contrastRatio|The contrast ratio message for the contrast tool."
9857
10072
  contrastRatio="Contrast ratio"
9858
10073
  i18n-formatButton="kendo.colorgradient.formatButton|The message for the input format toggle button."
9859
- formatButton="Change color format">
10074
+ formatButton="Change color format"
10075
+ i18n-redChannelLabel="kendo.colorgradient.redChannelLabel|The label of the NumericTextBox representing the red color channel."
10076
+ redChannelLabel="Red channel"
10077
+ i18n-greenChannelLabel="kendo.colorgradient.greenChannelLabel|The label of the NumericTextBox representing the green color channel."
10078
+ greenChannelLabel="Green channel"
10079
+ i18n-blueChannelLabel="kendo.colorgradient.blueChannelLabel|The label of the NumericTextBox representing the blue color channel."
10080
+ blueChannelLabel="Blue channel"
10081
+ i18n-alphaChannelLabel="kendo.colorgradient.alphaChannelLabel|The label of the NumericTextBox representing the alpha color channel."
10082
+ alphaChannelLabel="Alpha channel"
10083
+ i18n-redInputPlaceholder="kendo.colorgradient.redInputPlaceholder|The placeholder for the red color input."
10084
+ redChannelLabel="R"
10085
+ i18n-greenInputPlaceholder="kendo.colorgradient.greenInputPlaceholder|The placeholder for the green color input."
10086
+ greenInputPlaceholder="G"
10087
+ i18n-blueInputPlaceholder="kendo.colorgradient.blueInputPlaceholder|The placeholder for the blue color input."
10088
+ blueInputPlaceholder="B"
10089
+ i18n-hexInputPlaceholder="kendo.colorgradient.hexInputPlaceholder|The placeholder for the HEX color input."
10090
+ hexInputPlaceholder="HEX">
9860
10091
  </ng-container>
9861
10092
  <div class="k-colorgradient-canvas k-hstack">
9862
10093
  <div class="k-hsv-rectangle" #hsvRectangle>
@@ -9871,10 +10102,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9871
10102
  <div
9872
10103
  #gradientDragHandle
9873
10104
  class="k-hsv-draghandle k-draghandle"
9874
- tabindex="0"
10105
+ [tabindex]="innerTabIndex.toString()"
9875
10106
  [attr.title]="colorGradientHandleTitle"
9876
- [attr.aria-label]="colorGradientHandleAriaLabel"
9877
- >
10107
+ [attr.aria-label]="colorGradientHandleTitle + ' ' + colorGradientHandleAriaLabel"
10108
+ role="slider"
10109
+ [attr.aria-valuetext]="hsvSliderValueText"
10110
+ [attr.aria-readonly]="readonly ? readonly : undefined"
10111
+ [attr.aria-disabled]="disabled ? disabled : undefined"
10112
+ [attr.aria-orientation]="'undefined'"
10113
+ [attr.aria-valuenow]="'0'"
10114
+ (keydown.shift.tab)="$event.preventDefault(); inputs.focusLast();">
9878
10115
  </div>
9879
10116
  </div>
9880
10117
  <svg kendoColorContrastSvg
@@ -9889,22 +10126,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9889
10126
  <div class="k-hsv-controls k-hstack {{ clearButton ? 'k-sliders-wrap-clearable' : '' }}">
9890
10127
  <span class="k-clear-color k-button k-button-md k-button-flat k-button-flat-base k-button-icon"
9891
10128
  *ngIf="clearButton"
10129
+ role="button"
9892
10130
  (click)="reset()"
9893
10131
  (keydown.enter)="reset()"
9894
10132
  (keydown.space)="reset()"
9895
10133
  [attr.aria-label]="clearButtonTitle"
9896
10134
  [attr.title]="clearButtonTitle"
9897
- tabindex="0">
10135
+ [tabindex]="innerTabIndex.toString()">
9898
10136
  <span class="k-icon k-i-droplet-slash"></span>
9899
10137
  </span>
9900
10138
  <kendo-slider
9901
10139
  [ngClass]="{'k-align-self-end': clearButton}"
9902
10140
  class="k-hue-slider k-colorgradient-slider"
9903
10141
  [dragHandleTitle]="hueSliderTitle"
10142
+ [tabindex]="innerTabIndex"
9904
10143
  [disabled]="disabled"
9905
10144
  [readonly]="readonly"
9906
10145
  [showButtons]="false"
9907
- [tickPlacement]="'none'"
10146
+ tickPlacement="none"
9908
10147
  [vertical]="true"
9909
10148
  [min]="0"
9910
10149
  [max]="360"
@@ -9917,13 +10156,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9917
10156
  <kendo-slider
9918
10157
  *ngIf="opacity"
9919
10158
  #alphaSlider
10159
+ [tabindex]="innerTabIndex"
9920
10160
  [ngClass]="{'k-align-self-end': clearButton}"
9921
10161
  class="k-alpha-slider k-colorgradient-slider"
9922
10162
  [dragHandleTitle]="opacitySliderTitle"
9923
10163
  [disabled]="disabled"
9924
10164
  [readonly]="readonly"
9925
10165
  [showButtons]="false"
9926
- [tickPlacement]="'none'"
10166
+ tickPlacement="none"
9927
10167
  [vertical]="true"
9928
10168
  [min]="0"
9929
10169
  [max]="100"
@@ -9936,12 +10176,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9936
10176
  </div>
9937
10177
  </div>
9938
10178
  <kendo-colorinput #inputs
10179
+ [tabindex]="innerTabIndex"
9939
10180
  [opacity]="opacity"
9940
10181
  [formatView]="format"
9941
10182
  [value]="value"
9942
10183
  [disabled]="disabled"
9943
10184
  [readonly]="readonly"
9944
10185
  (valueChange)="handleInputsValueChange($event)"
10186
+ (tabOut)="gradientDragHandle.focus()"
9945
10187
  >
9946
10188
  </kendo-colorinput>
9947
10189
  <div class="k-colorgradient-color-contrast k-vbox"
@@ -9971,7 +10213,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9971
10213
  }
9972
10214
  `]
9973
10215
  }]
9974
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }, { type: i0.Renderer2 }, { type: i0.ChangeDetectorRef }, { type: i1.LocalizationService }]; }, propDecorators: { hostClasses: [{
10216
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }, { type: i0.Renderer2 }, { type: i0.ChangeDetectorRef }, { type: i1.LocalizationService }, { type: i0.Injector }]; }, propDecorators: { hostClasses: [{
9975
10217
  type: HostBinding,
9976
10218
  args: ['class.k-colorgradient']
9977
10219
  }], readonlyAttribute: [{
@@ -9989,6 +10231,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
9989
10231
  }], hostTabindex: [{
9990
10232
  type: HostBinding,
9991
10233
  args: ['attr.tabindex']
10234
+ }], ariaRole: [{
10235
+ type: HostBinding,
10236
+ args: ['attr.role']
10237
+ }], isControlInvalid: [{
10238
+ type: HostBinding,
10239
+ args: ['attr.aria-invalid']
10240
+ }], isDisabled: [{
10241
+ type: HostBinding,
10242
+ args: ['attr.aria-disabled']
10243
+ }], enterHandler: [{
10244
+ type: HostListener,
10245
+ args: ['keydown.enter', ['$event']]
10246
+ }], escapeHandler: [{
10247
+ type: HostListener,
10248
+ args: ['keydown.escape', ['$event']]
10249
+ }], focusHandler: [{
10250
+ type: HostListener,
10251
+ args: ['focusin', ['$event']]
9992
10252
  }], id: [{
9993
10253
  type: Input
9994
10254
  }], opacity: [{
@@ -10011,21 +10271,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
10011
10271
  type: Input
10012
10272
  }], valueChange: [{
10013
10273
  type: Output
10274
+ }], gradientSliderStep: [{
10275
+ type: Input
10276
+ }], gradientSliderSmallStep: [{
10277
+ type: Input
10014
10278
  }], gradientDragHandle: [{
10015
10279
  type: ViewChild,
10016
- args: ['gradientDragHandle', { read: ElementRef, static: false }]
10280
+ args: ['gradientDragHandle']
10017
10281
  }], inputs: [{
10018
10282
  type: ViewChild,
10019
- args: ['inputs', { static: false }]
10283
+ args: ['inputs']
10020
10284
  }], alphaSlider: [{
10021
10285
  type: ViewChild,
10022
- args: ['alphaSlider', { static: false }]
10286
+ args: ['alphaSlider']
10023
10287
  }], gradientWrapper: [{
10024
10288
  type: ViewChild,
10025
- args: ['gradientWrapper', { static: false }]
10289
+ args: ['gradientWrapper']
10026
10290
  }], hsvRectangle: [{
10027
10291
  type: ViewChild,
10028
- args: ['hsvRectangle', { static: false }]
10292
+ args: ['hsvRectangle']
10029
10293
  }] } });
10030
10294
 
10031
10295
  /**
@@ -10142,6 +10406,10 @@ class ColorPaletteComponent {
10142
10406
  this.renderer = renderer;
10143
10407
  this.localizationService = localizationService;
10144
10408
  this.ngZone = ngZone;
10409
+ /**
10410
+ * @hidden
10411
+ */
10412
+ this.role = 'grid';
10145
10413
  /**
10146
10414
  * @hidden
10147
10415
  */
@@ -10203,6 +10471,13 @@ class ColorPaletteComponent {
10203
10471
  this.direction = rtl ? 'rtl' : 'ltr';
10204
10472
  });
10205
10473
  }
10474
+ /**
10475
+ * @hidden
10476
+ */
10477
+ get activeDescendant() {
10478
+ return this.activeCellId;
10479
+ }
10480
+ ;
10206
10481
  /**
10207
10482
  * @hidden
10208
10483
  */
@@ -10343,6 +10618,14 @@ class ColorPaletteComponent {
10343
10618
  }
10344
10619
  event.preventDefault();
10345
10620
  }
10621
+ /**
10622
+ * @hidden
10623
+ */
10624
+ handleFocus() {
10625
+ if (!this.focusInComponent) {
10626
+ this.focus();
10627
+ }
10628
+ }
10346
10629
  /**
10347
10630
  * @hidden
10348
10631
  */
@@ -10397,6 +10680,18 @@ class ColorPaletteComponent {
10397
10680
  this.cdr.markForCheck();
10398
10681
  this.disabled = isDisabled;
10399
10682
  }
10683
+ /**
10684
+ * @hidden
10685
+ */
10686
+ focus() {
10687
+ this.host.nativeElement.focus();
10688
+ if (!this.focusedCell && !this.readonly && !this.disabled) {
10689
+ this.focusedCell = {
10690
+ row: 0,
10691
+ col: 0
10692
+ };
10693
+ }
10694
+ }
10400
10695
  /**
10401
10696
  * @hidden
10402
10697
  * Used by the FloatingLabel to determine if the component is empty.
@@ -10458,7 +10753,7 @@ class ColorPaletteComponent {
10458
10753
  }
10459
10754
  }
10460
10755
  ColorPaletteComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorPaletteComponent, deps: [{ token: i0.ElementRef }, { token: ColorPaletteService }, { token: i0.ChangeDetectorRef }, { token: i0.Renderer2 }, { token: i1.LocalizationService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
10461
- ColorPaletteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorPaletteComponent, selector: "kendo-colorpalette", inputs: { id: "id", format: "format", value: "value", columns: "columns", palette: "palette", tabindex: "tabindex", disabled: "disabled", readonly: "readonly", tileSize: "tileSize" }, outputs: { selectionChange: "selectionChange", valueChange: "valueChange", cellSelection: "cellSelection" }, host: { listeners: { "keydown": "handleKeydown($event)", "blur": "handleHostBlur()" }, properties: { "attr.dir": "this.direction", "attr.id": "this.paletteId", "attr.tabindex": "this.hostTabindex", "class.k-colorpalette": "this.hostClasses", "attr.aria-disabled": "this.disabledClass", "class.k-disabled": "this.disabledClass", "attr.aria-readonly": "this.readonlyAttribute" } }, providers: [
10756
+ ColorPaletteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorPaletteComponent, selector: "kendo-colorpalette", inputs: { id: "id", format: "format", value: "value", columns: "columns", palette: "palette", tabindex: "tabindex", disabled: "disabled", readonly: "readonly", tileSize: "tileSize" }, outputs: { selectionChange: "selectionChange", valueChange: "valueChange", cellSelection: "cellSelection" }, host: { listeners: { "keydown": "handleKeydown($event)", "focus": "handleFocus($event)", "blur": "handleHostBlur()" }, properties: { "attr.dir": "this.direction", "attr.role": "this.role", "attr.aria-activedescendant": "this.activeDescendant", "attr.id": "this.paletteId", "attr.tabindex": "this.hostTabindex", "class.k-colorpalette": "this.hostClasses", "attr.aria-disabled": "this.disabledClass", "class.k-disabled": "this.disabledClass", "attr.aria-readonly": "this.readonlyAttribute" } }, providers: [
10462
10757
  {
10463
10758
  multi: true,
10464
10759
  provide: NG_VALUE_ACCESSOR,
@@ -10482,13 +10777,12 @@ ColorPaletteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
10482
10777
  i18n-colorPaletteNoColor="kendo.colorpalette.colorPaletteNoColor|The aria-label applied to the ColorPalette component when the value is empty."
10483
10778
  colorPaletteNoColor="Colorpalette no color chosen">
10484
10779
  </ng-container>
10485
- <div role="listbox" class="k-colorpalette-table-wrap"
10486
- [attr.aria-activedescendant]="activeCellId">
10487
- <table class="k-colorpalette-table k-palette">
10780
+ <div class="k-colorpalette-table-wrap">
10781
+ <table role="presentation" class="k-colorpalette-table k-palette">
10488
10782
  <tbody>
10489
- <tr *ngFor="let row of colorRows; let rowIndex = index">
10783
+ <tr *ngFor="let row of colorRows; let rowIndex = index" role="row">
10490
10784
  <td *ngFor="let color of row; let colIndex = index"
10491
- role="option"
10785
+ role="gridcell"
10492
10786
  [class.k-selected]="selectedCell?.row === rowIndex && selectedCell?.col === colIndex"
10493
10787
  [class.k-focus]="focusInComponent && focusedCell?.row === rowIndex && focusedCell?.col === colIndex"
10494
10788
  [attr.aria-selected]="selectedCell?.row === rowIndex && selectedCell?.col === colIndex"
@@ -10539,13 +10833,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
10539
10833
  i18n-colorPaletteNoColor="kendo.colorpalette.colorPaletteNoColor|The aria-label applied to the ColorPalette component when the value is empty."
10540
10834
  colorPaletteNoColor="Colorpalette no color chosen">
10541
10835
  </ng-container>
10542
- <div role="listbox" class="k-colorpalette-table-wrap"
10543
- [attr.aria-activedescendant]="activeCellId">
10544
- <table class="k-colorpalette-table k-palette">
10836
+ <div class="k-colorpalette-table-wrap">
10837
+ <table role="presentation" class="k-colorpalette-table k-palette">
10545
10838
  <tbody>
10546
- <tr *ngFor="let row of colorRows; let rowIndex = index">
10839
+ <tr *ngFor="let row of colorRows; let rowIndex = index" role="row">
10547
10840
  <td *ngFor="let color of row; let colIndex = index"
10548
- role="option"
10841
+ role="gridcell"
10549
10842
  [class.k-selected]="selectedCell?.row === rowIndex && selectedCell?.col === colIndex"
10550
10843
  [class.k-focus]="focusInComponent && focusedCell?.row === rowIndex && focusedCell?.col === colIndex"
10551
10844
  [attr.aria-selected]="selectedCell?.row === rowIndex && selectedCell?.col === colIndex"
@@ -10570,6 +10863,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
10570
10863
  }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: ColorPaletteService }, { type: i0.ChangeDetectorRef }, { type: i0.Renderer2 }, { type: i1.LocalizationService }, { type: i0.NgZone }]; }, propDecorators: { direction: [{
10571
10864
  type: HostBinding,
10572
10865
  args: ['attr.dir']
10866
+ }], role: [{
10867
+ type: HostBinding,
10868
+ args: ['attr.role']
10869
+ }], activeDescendant: [{
10870
+ type: HostBinding,
10871
+ args: ['attr.aria-activedescendant']
10573
10872
  }], paletteId: [{
10574
10873
  type: HostBinding,
10575
10874
  args: ['attr.id']
@@ -10615,6 +10914,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
10615
10914
  }], handleKeydown: [{
10616
10915
  type: HostListener,
10617
10916
  args: ['keydown', ['$event']]
10917
+ }], handleFocus: [{
10918
+ type: HostListener,
10919
+ args: ['focus', ['$event']]
10618
10920
  }], handleHostBlur: [{
10619
10921
  type: HostListener,
10620
10922
  args: ['blur']
@@ -10627,7 +10929,9 @@ class FlatColorPickerActionButtonsComponent {
10627
10929
  constructor(localizationService) {
10628
10930
  this.localizationService = localizationService;
10629
10931
  this.hostClasses = true;
10932
+ this.innerTabIndex = -1;
10630
10933
  this.actionButtonClick = new EventEmitter();
10934
+ this.tabOut = new EventEmitter();
10631
10935
  }
10632
10936
  getText(text) {
10633
10937
  return this.localizationService.get(text);
@@ -10641,18 +10945,21 @@ class FlatColorPickerActionButtonsComponent {
10641
10945
  }
10642
10946
  }
10643
10947
  FlatColorPickerActionButtonsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FlatColorPickerActionButtonsComponent, deps: [{ token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
10644
- FlatColorPickerActionButtonsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FlatColorPickerActionButtonsComponent, selector: "[kendoFlatColorPickerActionButtons]", outputs: { actionButtonClick: "actionButtonClick" }, host: { properties: { "class.k-coloreditor-footer": "this.hostClasses", "class.k-actions": "this.hostClasses", "class.k-hstack": "this.hostClasses" } }, viewQueries: [{ propertyName: "lastButton", first: true, predicate: ["last"], descendants: true, read: ElementRef }], ngImport: i0, template: `
10645
- <button
10948
+ FlatColorPickerActionButtonsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FlatColorPickerActionButtonsComponent, selector: "[kendoFlatColorPickerActionButtons]", inputs: { innerTabIndex: "innerTabIndex" }, outputs: { actionButtonClick: "actionButtonClick", tabOut: "tabOut" }, host: { properties: { "class.k-coloreditor-footer": "this.hostClasses", "class.k-actions": "this.hostClasses", "class.k-hstack": "this.hostClasses" } }, viewQueries: [{ propertyName: "firstButton", first: true, predicate: ["first"], descendants: true, read: ElementRef }, { propertyName: "lastButton", first: true, predicate: ["last"], descendants: true, read: ElementRef }], ngImport: i0, template: `
10949
+ <button #first
10646
10950
  class="k-coloreditor-cancel k-button k-button-md k-button-solid k-button-solid-base"
10647
10951
  [attr.title]="getText('cancelButton')"
10648
10952
  (click)="onActionButtonClick('cancel', $event)"
10649
10953
  type="button"
10954
+ [tabindex]="innerTabIndex.toString()"
10650
10955
  >{{getText('cancelButton')}}</button>
10651
10956
  <button #last
10652
10957
  class="k-coloreditor-apply k-button k-button-md k-button-solid k-button-solid-primary"
10653
10958
  [attr.title]="getText('applyButton')"
10654
10959
  (click)="onActionButtonClick('apply', $event)"
10655
10960
  type="button"
10961
+ [tabindex]="innerTabIndex.toString()"
10962
+ (keydown.tab)="$event.preventDefault(); tabOut.emit();"
10656
10963
  >{{getText('applyButton')}}</button>
10657
10964
  `, isInline: true });
10658
10965
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FlatColorPickerActionButtonsComponent, decorators: [{
@@ -10661,17 +10968,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
10661
10968
  // eslint-disable-next-line @angular-eslint/component-selector
10662
10969
  selector: '[kendoFlatColorPickerActionButtons]',
10663
10970
  template: `
10664
- <button
10971
+ <button #first
10665
10972
  class="k-coloreditor-cancel k-button k-button-md k-button-solid k-button-solid-base"
10666
10973
  [attr.title]="getText('cancelButton')"
10667
10974
  (click)="onActionButtonClick('cancel', $event)"
10668
10975
  type="button"
10976
+ [tabindex]="innerTabIndex.toString()"
10669
10977
  >{{getText('cancelButton')}}</button>
10670
10978
  <button #last
10671
10979
  class="k-coloreditor-apply k-button k-button-md k-button-solid k-button-solid-primary"
10672
10980
  [attr.title]="getText('applyButton')"
10673
10981
  (click)="onActionButtonClick('apply', $event)"
10674
10982
  type="button"
10983
+ [tabindex]="innerTabIndex.toString()"
10984
+ (keydown.tab)="$event.preventDefault(); tabOut.emit();"
10675
10985
  >{{getText('applyButton')}}</button>
10676
10986
  `
10677
10987
  }]
@@ -10684,37 +10994,21 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
10684
10994
  }, {
10685
10995
  type: HostBinding,
10686
10996
  args: ['class.k-hstack']
10997
+ }], innerTabIndex: [{
10998
+ type: Input
10687
10999
  }], actionButtonClick: [{
10688
11000
  type: Output
11001
+ }], tabOut: [{
11002
+ type: Output
11003
+ }], firstButton: [{
11004
+ type: ViewChild,
11005
+ args: ['first', { read: ElementRef }]
10689
11006
  }], lastButton: [{
10690
11007
  type: ViewChild,
10691
- args: ['last', { read: ElementRef, static: false }]
11008
+ args: ['last', { read: ElementRef }]
10692
11009
  }] } });
10693
11010
 
10694
- /**
10695
- * @hidden
10696
- */
10697
- class FocusOnDomReadyDirective {
10698
- constructor(host, ngZone) {
10699
- this.host = host;
10700
- this.ngZone = ngZone;
10701
- }
10702
- ngAfterContentInit() {
10703
- this.focusOnNextTick();
10704
- }
10705
- focusOnNextTick() {
10706
- this.ngZone.runOutsideAngular(() => setTimeout(() => this.host.nativeElement.focus()));
10707
- }
10708
- }
10709
- FocusOnDomReadyDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FocusOnDomReadyDirective, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
10710
- FocusOnDomReadyDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: FocusOnDomReadyDirective, selector: "[kendoFocusOnDomReady]", ngImport: i0 });
10711
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FocusOnDomReadyDirective, decorators: [{
10712
- type: Directive,
10713
- args: [{
10714
- selector: '[kendoFocusOnDomReady]'
10715
- }]
10716
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }]; } });
10717
-
11011
+ /* eslint-disable no-unused-expressions */
10718
11012
  /**
10719
11013
  * Represents the [Kendo UI FlatColorPicker component for Angular]({% slug overview_flatcolorpicker %}).
10720
11014
  *
@@ -10722,14 +11016,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
10722
11016
  * through a gradient that renders an hsv canvas. It supports previewing the selected color, reverting it to its previous state or clearing it completely.
10723
11017
  */
10724
11018
  class FlatColorPickerComponent {
10725
- constructor(host, service, localizationService, cdr, renderer, ngZone) {
11019
+ constructor(host, service, localizationService, cdr, renderer, ngZone, injector) {
10726
11020
  this.host = host;
10727
11021
  this.service = service;
10728
11022
  this.localizationService = localizationService;
10729
11023
  this.cdr = cdr;
10730
11024
  this.renderer = renderer;
10731
11025
  this.ngZone = ngZone;
11026
+ this.injector = injector;
10732
11027
  this.hostClasses = true;
11028
+ this.ariaRole = 'textbox';
10733
11029
  /**
10734
11030
  * Sets the read-only state of the FlatColorPicker.
10735
11031
  *
@@ -10802,9 +11098,15 @@ class FlatColorPickerComponent {
10802
11098
  */
10803
11099
  this.actionButtonClick = new EventEmitter();
10804
11100
  this._tabindex = 0;
10805
- this._gradientSettings = { opacity: true, delay: 0 };
11101
+ this._gradientSettings = {
11102
+ opacity: true,
11103
+ delay: 0,
11104
+ gradientSliderStep: DRAGHANDLE_MOVE_SPEED,
11105
+ gradientSliderSmallStep: DRAGHANDLE_MOVE_SPEED_SMALL_STEP
11106
+ };
10806
11107
  this._paletteSettings = {};
10807
11108
  this.subscriptions = new Subscription();
11109
+ this.internalNavigation = false;
10808
11110
  this.notifyNgChanged = () => { };
10809
11111
  this.notifyNgTouched = () => { };
10810
11112
  validatePackage(packageMetadata);
@@ -10819,7 +11121,40 @@ class FlatColorPickerComponent {
10819
11121
  return this.readonly;
10820
11122
  }
10821
11123
  get hostTabindex() {
10822
- return this.tabindex;
11124
+ var _a;
11125
+ return ((_a = this.tabindex) === null || _a === void 0 ? void 0 : _a.toString()) || '0';
11126
+ }
11127
+ get isControlInvalid() {
11128
+ var _a, _b;
11129
+ return (_b = ((_a = this.control) === null || _a === void 0 ? void 0 : _a.invalid)) === null || _b === void 0 ? void 0 : _b.toString();
11130
+ }
11131
+ get isDisabled() {
11132
+ var _a;
11133
+ return ((_a = this.disabled) === null || _a === void 0 ? void 0 : _a.toString()) || undefined;
11134
+ }
11135
+ /**
11136
+ * @hidden
11137
+ */
11138
+ enterHandler(event) {
11139
+ if (event.target !== this.host.nativeElement) {
11140
+ return;
11141
+ }
11142
+ event.preventDefault();
11143
+ this.internalNavigation = true;
11144
+ this.ngZone.onStable.pipe(take(1)).subscribe(() => { var _a; return (_a = this.firstFocusable) === null || _a === void 0 ? void 0 : _a.focus(); });
11145
+ }
11146
+ /**
11147
+ * @hidden
11148
+ */
11149
+ escapeHandler() {
11150
+ this.internalNavigation = false;
11151
+ this.host.nativeElement.focus();
11152
+ }
11153
+ /**
11154
+ * @hidden
11155
+ */
11156
+ focusHandler(ev) {
11157
+ this.internalNavigation = ev.target !== this.host.nativeElement;
10823
11158
  }
10824
11159
  /**
10825
11160
  * Specifies the initially selected color.
@@ -10836,9 +11171,14 @@ class FlatColorPickerComponent {
10836
11171
  * @default 0
10837
11172
  */
10838
11173
  set tabindex(value) {
10839
- const tabindex = Number(value);
10840
- const defaultValue = 0;
10841
- this._tabindex = !isNaN(tabindex) ? tabindex : defaultValue;
11174
+ if (isPresent(value)) {
11175
+ const tabindex = Number(value);
11176
+ this._tabindex = !isNaN(tabindex) ? tabindex : 0;
11177
+ }
11178
+ else {
11179
+ // Allows removal of the tabindex attribute
11180
+ this._tabindex = value;
11181
+ }
10842
11182
  }
10843
11183
  get tabindex() {
10844
11184
  return !this.disabled ? this._tabindex : undefined;
@@ -10861,8 +11201,33 @@ class FlatColorPickerComponent {
10861
11201
  get paletteSettings() {
10862
11202
  return this._paletteSettings;
10863
11203
  }
11204
+ /**
11205
+ * @hidden
11206
+ */
11207
+ get innerTabIndex() {
11208
+ return this.internalNavigation ? 0 : -1;
11209
+ }
11210
+ /**
11211
+ * @hidden
11212
+ */
11213
+ get firstFocusable() {
11214
+ if (this.headerHasContent) {
11215
+ return this.headerElement.nativeElement.querySelector('.k-button');
11216
+ }
11217
+ return this.activeView === 'gradient' ? this.gradient : this.palette;
11218
+ }
11219
+ /**
11220
+ * @hidden
11221
+ */
11222
+ get lastFocusable() {
11223
+ if (this.preview) {
11224
+ return this.footer.lastButton.nativeElement;
11225
+ }
11226
+ return this.activeView === 'gradient' ? this.gradient : this.palette;
11227
+ }
10864
11228
  ngOnInit() {
10865
11229
  this.selection = this.value;
11230
+ this.control = this.injector.get(NgControl, null);
10866
11231
  this._paletteSettings = this.service.getPaletteSettings(this._paletteSettings, this.format);
10867
11232
  this.setActiveView();
10868
11233
  }
@@ -10870,6 +11235,7 @@ class FlatColorPickerComponent {
10870
11235
  this.setHostElementAriaLabel();
10871
11236
  this.initDomEvents();
10872
11237
  this.setSizingVariables();
11238
+ this.removeGradientAttributes();
10873
11239
  }
10874
11240
  ngOnChanges(changes) {
10875
11241
  if (isChanged('value', changes)) {
@@ -10886,6 +11252,20 @@ class FlatColorPickerComponent {
10886
11252
  }
10887
11253
  this.subscriptions.unsubscribe();
10888
11254
  }
11255
+ /**
11256
+ * @hidden
11257
+ */
11258
+ onTab(ev) {
11259
+ const { shiftKey } = ev;
11260
+ const nextTabStop = this.preview ? this.footer.firstButton.nativeElement : this.headerHasContent ? findFocusableChild(this.headerElement.nativeElement) : null;
11261
+ const previousTabStop = this.headerHasContent ? findFocusableChild(this.headerElement.nativeElement) : this.preview ? this.footer.lastButton.nativeElement : null;
11262
+ if (!nextTabStop && !previousTabStop) {
11263
+ return;
11264
+ }
11265
+ ev.preventDefault();
11266
+ // eslint-disable-next-line no-unused-expressions
11267
+ shiftKey ? previousTabStop === null || previousTabStop === void 0 ? void 0 : previousTabStop.focus() : nextTabStop === null || nextTabStop === void 0 ? void 0 : nextTabStop.focus();
11268
+ }
10889
11269
  /**
10890
11270
  * @hidden
10891
11271
  */
@@ -10903,7 +11283,7 @@ class FlatColorPickerComponent {
10903
11283
  * Focuses the wrapper of the FlatColorPicker.
10904
11284
  */
10905
11285
  focus() {
10906
- if (this.disabled && this.focused) {
11286
+ if (this.disabled || this.focused) {
10907
11287
  return;
10908
11288
  }
10909
11289
  this.host.nativeElement.focus();
@@ -10940,12 +11320,14 @@ class FlatColorPickerComponent {
10940
11320
  }
10941
11321
  this.activeView = view;
10942
11322
  this.activeViewChange.emit(view);
10943
- if (this.activeView === 'gradient') {
10944
- this.ngZone.runOutsideAngular(() => {
10945
- setTimeout(() => {
10946
- this.gradient.gradientDragHandle.nativeElement.focus();
10947
- });
11323
+ this.ngZone.runOutsideAngular(() => {
11324
+ setTimeout(() => {
11325
+ var _a;
11326
+ (_a = this[this.activeView]) === null || _a === void 0 ? void 0 : _a.focus();
10948
11327
  });
11328
+ });
11329
+ if (this.activeView === 'gradient') {
11330
+ this.removeGradientAttributes();
10949
11331
  }
10950
11332
  }
10951
11333
  /**
@@ -10953,6 +11335,7 @@ class FlatColorPickerComponent {
10953
11335
  */
10954
11336
  onClearButtonClick() {
10955
11337
  this.resetInnerComponentValue();
11338
+ this.internalNavigation = false;
10956
11339
  this.host.nativeElement.focus();
10957
11340
  }
10958
11341
  /**
@@ -11063,9 +11446,13 @@ class FlatColorPickerComponent {
11063
11446
  }));
11064
11447
  });
11065
11448
  }
11449
+ removeGradientAttributes() {
11450
+ this.gradientElement && this.renderer.removeAttribute(this.gradientElement.nativeElement, 'role');
11451
+ this.gradientElement && this.renderer.removeAttribute(this.gradientElement.nativeElement, 'aria-label');
11452
+ }
11066
11453
  }
11067
- FlatColorPickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FlatColorPickerComponent, deps: [{ token: i0.ElementRef }, { token: FlatColorPickerService }, { token: i1.LocalizationService }, { token: i0.ChangeDetectorRef }, { token: i0.Renderer2 }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
11068
- FlatColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FlatColorPickerComponent, selector: "kendo-flatcolorpicker", inputs: { readonly: "readonly", disabled: "disabled", format: "format", value: "value", tabindex: "tabindex", clearButton: "clearButton", preview: "preview", actionsLayout: "actionsLayout", activeView: "activeView", views: "views", gradientSettings: "gradientSettings", paletteSettings: "paletteSettings" }, outputs: { valueChange: "valueChange", cancel: "cancel", activeViewChange: "activeViewChange", actionButtonClick: "actionButtonClick" }, host: { properties: { "class.k-flatcolorpicker": "this.hostClasses", "class.k-coloreditor": "this.hostClasses", "class.k-disabled": "this.disabledClass", "attr.aria-disabled": "this.disabledClass", "attr.aria-readonly": "this.ariaReadonly", "attr.dir": "this.direction", "attr.tabindex": "this.hostTabindex" } }, providers: [
11454
+ FlatColorPickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FlatColorPickerComponent, deps: [{ token: i0.ElementRef }, { token: FlatColorPickerService }, { token: i1.LocalizationService }, { token: i0.ChangeDetectorRef }, { token: i0.Renderer2 }, { token: i0.NgZone }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
11455
+ FlatColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: FlatColorPickerComponent, selector: "kendo-flatcolorpicker", inputs: { readonly: "readonly", disabled: "disabled", format: "format", value: "value", tabindex: "tabindex", clearButton: "clearButton", preview: "preview", actionsLayout: "actionsLayout", activeView: "activeView", views: "views", gradientSettings: "gradientSettings", paletteSettings: "paletteSettings" }, outputs: { valueChange: "valueChange", cancel: "cancel", activeViewChange: "activeViewChange", actionButtonClick: "actionButtonClick" }, host: { listeners: { "keydown.enter": "enterHandler($event)", "keydown.escape": "escapeHandler()", "focusin": "focusHandler($event)" }, properties: { "class.k-flatcolorpicker": "this.hostClasses", "class.k-coloreditor": "this.hostClasses", "class.k-disabled": "this.disabledClass", "attr.aria-disabled": "this.isDisabled", "attr.aria-readonly": "this.ariaReadonly", "attr.dir": "this.direction", "attr.tabindex": "this.hostTabindex", "attr.role": "this.ariaRole", "attr.aria-invalid": "this.isControlInvalid" } }, providers: [
11069
11456
  {
11070
11457
  multi: true,
11071
11458
  provide: NG_VALUE_ACCESSOR,
@@ -11085,7 +11472,7 @@ FlatColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0
11085
11472
  provide: L10N_PREFIX,
11086
11473
  useValue: 'kendo.flatcolorpicker'
11087
11474
  }
11088
- ], viewQueries: [{ propertyName: "header", first: true, predicate: ["header"], descendants: true }, { propertyName: "gradient", first: true, predicate: ["gradient"], descendants: true }, { propertyName: "palette", first: true, predicate: ["palette"], descendants: true }, { propertyName: "footer", first: true, predicate: ["footer"], descendants: true }], exportAs: ["kendoFlatColorPicker"], usesOnChanges: true, ngImport: i0, template: `
11475
+ ], viewQueries: [{ propertyName: "header", first: true, predicate: ["header"], descendants: true }, { propertyName: "headerElement", first: true, predicate: ["header"], descendants: true, read: ElementRef }, { propertyName: "gradient", first: true, predicate: ["gradient"], descendants: true }, { propertyName: "gradientElement", first: true, predicate: ["gradient"], descendants: true, read: ElementRef }, { propertyName: "palette", first: true, predicate: ["palette"], descendants: true }, { propertyName: "footer", first: true, predicate: ["footer"], descendants: true }], exportAs: ["kendoFlatColorPicker"], usesOnChanges: true, ngImport: i0, template: `
11089
11476
  <ng-container kendoFlatColorPickerLocalizedMessages
11090
11477
  i18n-flatColorPickerNoColor="kendo.flatcolorpicker.flatColorPickerNoColor|The aria-label applied to the FlatColorPicker component when the value is empty."
11091
11478
  flatColorPickerNoColor="Flatcolorpicker no color chosen"
@@ -11116,9 +11503,26 @@ FlatColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0
11116
11503
  i18n-applyButton="kendo.flatcolorpicker.applyButton|The message for the Apply action button."
11117
11504
  applyButton="Apply"
11118
11505
  i18n-cancelButton="kendo.flatcolorpicker.cancelButton|The message for the Cancel action button."
11119
- cancelButton="Cancel">
11506
+ cancelButton="Cancel"
11507
+ i18n-redChannelLabel="kendo.flatcolorpicker.redChannelLabel|The label of the NumericTextBox representing the red color channel."
11508
+ redChannelLabel="Red channel"
11509
+ i18n-greenChannelLabel="kendo.flatcolorpicker.greenChannelLabel|The label of the NumericTextBox representing the green color channel."
11510
+ greenChannelLabel="Green channel"
11511
+ i18n-blueChannelLabel="kendo.flatcolorpicker.blueChannelLabel|The label of the NumericTextBox representing the blue color channel."
11512
+ blueChannelLabel="Blue channel"
11513
+ i18n-alphaChannelLabel="kendo.flatcolorpicker.alphaChannelLabel|The label of the NumericTextBox representing the alpha color channel."
11514
+ alphaChannelLabel="Alpha channel"
11515
+ i18n-redInputPlaceholder="kendo.flatcolorpicker.redInputPlaceholder|The placeholder for the red color input."
11516
+ redChannelLabel="R"
11517
+ i18n-greenInputPlaceholder="kendo.flatcolorpicker.greenInputPlaceholder|The placeholder for the green color input."
11518
+ greenInputPlaceholder="G"
11519
+ i18n-blueInputPlaceholder="kendo.flatcolorpicker.blueInputPlaceholder|The placeholder for the blue color input."
11520
+ blueInputPlaceholder="B"
11521
+ i18n-hexInputPlaceholder="kendo.flatcolorpicker.hexInputPlaceholder|The placeholder for the HEX color input."
11522
+ hexInputPlaceholder="HEX">
11120
11523
  </ng-container>
11121
11524
  <div kendoFlatColorPickerHeader
11525
+ [innerTabIndex]="this.innerTabIndex"
11122
11526
  *ngIf="headerHasContent"
11123
11527
  #header
11124
11528
  [clearButton]="clearButton"
@@ -11129,24 +11533,25 @@ FlatColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0
11129
11533
  [preview]="preview"
11130
11534
  (clearButtonClick)="onClearButtonClick()"
11131
11535
  (viewChange)="onViewChange($event)"
11132
- (valuePaneClick)="resetSelection($event)">
11133
- </div>
11536
+ (valuePaneClick)="resetSelection($event)"
11537
+ (tabOut)="lastFocusable.focus()"></div>
11134
11538
  <div class="k-coloreditor-views k-vstack">
11135
11539
  <kendo-colorgradient #gradient
11540
+ [tabindex]="innerTabIndex"
11136
11541
  *ngIf="activeView === 'gradient'"
11137
- [tabindex]="null"
11138
11542
  [value]="selection"
11139
11543
  [format]="format"
11140
11544
  [opacity]="gradientSettings.opacity"
11141
11545
  [delay]="gradientSettings.delay"
11142
11546
  [contrastTool]="gradientSettings.contrastTool"
11547
+ [gradientSliderSmallStep]="gradientSettings.gradientSliderSmallStep"
11548
+ [gradientSliderStep]="gradientSettings.gradientSliderStep"
11143
11549
  [readonly]="readonly"
11144
11550
  (valueChange)="handleValueChange($event)"
11145
- >
11146
- </kendo-colorgradient>
11551
+ ></kendo-colorgradient>
11147
11552
  <kendo-colorpalette #palette
11553
+ [tabindex]="innerTabIndex"
11148
11554
  *ngIf="activeView === 'palette'"
11149
- kendoFocusOnDomReady
11150
11555
  [palette]="paletteSettings.palette"
11151
11556
  [columns]="paletteSettings.columns"
11152
11557
  [tileSize]="paletteSettings.tileSize"
@@ -11154,15 +11559,16 @@ FlatColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0
11154
11559
  [value]="selection"
11155
11560
  [readonly]="readonly"
11156
11561
  (valueChange)="handleValueChange($event)"
11157
- >
11158
- </kendo-colorpalette>
11562
+ ></kendo-colorpalette>
11159
11563
  </div>
11160
- <div kendoFlatColorPickerActionButtons *ngIf="preview"
11564
+ <div kendoFlatColorPickerActionButtons
11565
+ [innerTabIndex]="innerTabIndex"
11566
+ *ngIf="preview"
11161
11567
  #footer
11162
11568
  [ngClass]="'k-justify-content-' + actionsLayout"
11163
- (actionButtonClick)="onAction($event)">
11164
- </div>
11165
- `, isInline: true, components: [{ type: FlatColorPickerHeaderComponent, selector: "[kendoFlatColorPickerHeader]", inputs: ["clearButton", "activeView", "views", "preview", "value", "selection"], outputs: ["viewChange", "valuePaneClick", "clearButtonClick"] }, { type: ColorGradientComponent, selector: "kendo-colorgradient", inputs: ["id", "opacity", "disabled", "readonly", "clearButton", "delay", "value", "contrastTool", "tabindex", "format"], outputs: ["valueChange"], exportAs: ["kendoColorGradient"] }, { type: ColorPaletteComponent, selector: "kendo-colorpalette", inputs: ["id", "format", "value", "columns", "palette", "tabindex", "disabled", "readonly", "tileSize"], outputs: ["selectionChange", "valueChange", "cellSelection"], exportAs: ["kendoColorPalette"] }, { type: FlatColorPickerActionButtonsComponent, selector: "[kendoFlatColorPickerActionButtons]", outputs: ["actionButtonClick"] }], directives: [{ type: LocalizedColorPickerMessagesDirective, selector: "[kendoColorPickerLocalizedMessages], [kendoFlatColorPickerLocalizedMessages], [kendoColorGradientLocalizedMessages], [kendoColorPaletteLocalizedMessages]" }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: FocusOnDomReadyDirective, selector: "[kendoFocusOnDomReady]" }, { type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
11569
+ (actionButtonClick)="onAction($event)"
11570
+ (tabOut)="firstFocusable.focus()"></div>
11571
+ `, isInline: true, components: [{ type: FlatColorPickerHeaderComponent, selector: "[kendoFlatColorPickerHeader]", inputs: ["clearButton", "activeView", "views", "preview", "innerTabIndex", "value", "selection"], outputs: ["viewChange", "valuePaneClick", "clearButtonClick", "tabOut"] }, { type: ColorGradientComponent, selector: "kendo-colorgradient", inputs: ["id", "opacity", "disabled", "readonly", "clearButton", "delay", "value", "contrastTool", "tabindex", "format", "gradientSliderStep", "gradientSliderSmallStep"], outputs: ["valueChange"], exportAs: ["kendoColorGradient"] }, { type: ColorPaletteComponent, selector: "kendo-colorpalette", inputs: ["id", "format", "value", "columns", "palette", "tabindex", "disabled", "readonly", "tileSize"], outputs: ["selectionChange", "valueChange", "cellSelection"], exportAs: ["kendoColorPalette"] }, { type: FlatColorPickerActionButtonsComponent, selector: "[kendoFlatColorPickerActionButtons]", inputs: ["innerTabIndex"], outputs: ["actionButtonClick", "tabOut"] }], directives: [{ type: LocalizedColorPickerMessagesDirective, selector: "[kendoColorPickerLocalizedMessages], [kendoFlatColorPickerLocalizedMessages], [kendoColorGradientLocalizedMessages], [kendoColorPaletteLocalizedMessages]" }, { type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
11166
11572
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FlatColorPickerComponent, decorators: [{
11167
11573
  type: Component,
11168
11574
  args: [{
@@ -11220,9 +11626,26 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
11220
11626
  i18n-applyButton="kendo.flatcolorpicker.applyButton|The message for the Apply action button."
11221
11627
  applyButton="Apply"
11222
11628
  i18n-cancelButton="kendo.flatcolorpicker.cancelButton|The message for the Cancel action button."
11223
- cancelButton="Cancel">
11629
+ cancelButton="Cancel"
11630
+ i18n-redChannelLabel="kendo.flatcolorpicker.redChannelLabel|The label of the NumericTextBox representing the red color channel."
11631
+ redChannelLabel="Red channel"
11632
+ i18n-greenChannelLabel="kendo.flatcolorpicker.greenChannelLabel|The label of the NumericTextBox representing the green color channel."
11633
+ greenChannelLabel="Green channel"
11634
+ i18n-blueChannelLabel="kendo.flatcolorpicker.blueChannelLabel|The label of the NumericTextBox representing the blue color channel."
11635
+ blueChannelLabel="Blue channel"
11636
+ i18n-alphaChannelLabel="kendo.flatcolorpicker.alphaChannelLabel|The label of the NumericTextBox representing the alpha color channel."
11637
+ alphaChannelLabel="Alpha channel"
11638
+ i18n-redInputPlaceholder="kendo.flatcolorpicker.redInputPlaceholder|The placeholder for the red color input."
11639
+ redChannelLabel="R"
11640
+ i18n-greenInputPlaceholder="kendo.flatcolorpicker.greenInputPlaceholder|The placeholder for the green color input."
11641
+ greenInputPlaceholder="G"
11642
+ i18n-blueInputPlaceholder="kendo.flatcolorpicker.blueInputPlaceholder|The placeholder for the blue color input."
11643
+ blueInputPlaceholder="B"
11644
+ i18n-hexInputPlaceholder="kendo.flatcolorpicker.hexInputPlaceholder|The placeholder for the HEX color input."
11645
+ hexInputPlaceholder="HEX">
11224
11646
  </ng-container>
11225
11647
  <div kendoFlatColorPickerHeader
11648
+ [innerTabIndex]="this.innerTabIndex"
11226
11649
  *ngIf="headerHasContent"
11227
11650
  #header
11228
11651
  [clearButton]="clearButton"
@@ -11233,24 +11656,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
11233
11656
  [preview]="preview"
11234
11657
  (clearButtonClick)="onClearButtonClick()"
11235
11658
  (viewChange)="onViewChange($event)"
11236
- (valuePaneClick)="resetSelection($event)">
11237
- </div>
11659
+ (valuePaneClick)="resetSelection($event)"
11660
+ (tabOut)="lastFocusable.focus()"></div>
11238
11661
  <div class="k-coloreditor-views k-vstack">
11239
11662
  <kendo-colorgradient #gradient
11663
+ [tabindex]="innerTabIndex"
11240
11664
  *ngIf="activeView === 'gradient'"
11241
- [tabindex]="null"
11242
11665
  [value]="selection"
11243
11666
  [format]="format"
11244
11667
  [opacity]="gradientSettings.opacity"
11245
11668
  [delay]="gradientSettings.delay"
11246
11669
  [contrastTool]="gradientSettings.contrastTool"
11670
+ [gradientSliderSmallStep]="gradientSettings.gradientSliderSmallStep"
11671
+ [gradientSliderStep]="gradientSettings.gradientSliderStep"
11247
11672
  [readonly]="readonly"
11248
11673
  (valueChange)="handleValueChange($event)"
11249
- >
11250
- </kendo-colorgradient>
11674
+ ></kendo-colorgradient>
11251
11675
  <kendo-colorpalette #palette
11676
+ [tabindex]="innerTabIndex"
11252
11677
  *ngIf="activeView === 'palette'"
11253
- kendoFocusOnDomReady
11254
11678
  [palette]="paletteSettings.palette"
11255
11679
  [columns]="paletteSettings.columns"
11256
11680
  [tileSize]="paletteSettings.tileSize"
@@ -11258,17 +11682,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
11258
11682
  [value]="selection"
11259
11683
  [readonly]="readonly"
11260
11684
  (valueChange)="handleValueChange($event)"
11261
- >
11262
- </kendo-colorpalette>
11685
+ ></kendo-colorpalette>
11263
11686
  </div>
11264
- <div kendoFlatColorPickerActionButtons *ngIf="preview"
11687
+ <div kendoFlatColorPickerActionButtons
11688
+ [innerTabIndex]="innerTabIndex"
11689
+ *ngIf="preview"
11265
11690
  #footer
11266
11691
  [ngClass]="'k-justify-content-' + actionsLayout"
11267
- (actionButtonClick)="onAction($event)">
11268
- </div>
11692
+ (actionButtonClick)="onAction($event)"
11693
+ (tabOut)="firstFocusable.focus()"></div>
11269
11694
  `
11270
11695
  }]
11271
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: FlatColorPickerService }, { type: i1.LocalizationService }, { type: i0.ChangeDetectorRef }, { type: i0.Renderer2 }, { type: i0.NgZone }]; }, propDecorators: { hostClasses: [{
11696
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: FlatColorPickerService }, { type: i1.LocalizationService }, { type: i0.ChangeDetectorRef }, { type: i0.Renderer2 }, { type: i0.NgZone }, { type: i0.Injector }]; }, propDecorators: { hostClasses: [{
11272
11697
  type: HostBinding,
11273
11698
  args: ['class.k-flatcolorpicker']
11274
11699
  }, {
@@ -11289,6 +11714,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
11289
11714
  }], hostTabindex: [{
11290
11715
  type: HostBinding,
11291
11716
  args: ['attr.tabindex']
11717
+ }], ariaRole: [{
11718
+ type: HostBinding,
11719
+ args: ['attr.role']
11720
+ }], isControlInvalid: [{
11721
+ type: HostBinding,
11722
+ args: ['attr.aria-invalid']
11723
+ }], isDisabled: [{
11724
+ type: HostBinding,
11725
+ args: ['attr.aria-disabled']
11726
+ }], enterHandler: [{
11727
+ type: HostListener,
11728
+ args: ['keydown.enter', ['$event']]
11729
+ }], escapeHandler: [{
11730
+ type: HostListener,
11731
+ args: ['keydown.escape']
11732
+ }], focusHandler: [{
11733
+ type: HostListener,
11734
+ args: ['focusin', ['$event']]
11292
11735
  }], readonly: [{
11293
11736
  type: Input
11294
11737
  }], disabled: [{
@@ -11323,22 +11766,32 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
11323
11766
  type: Output
11324
11767
  }], header: [{
11325
11768
  type: ViewChild,
11326
- args: ['header', { static: false }]
11769
+ args: ['header']
11770
+ }], headerElement: [{
11771
+ type: ViewChild,
11772
+ args: ['header', { read: ElementRef }]
11327
11773
  }], gradient: [{
11328
11774
  type: ViewChild,
11329
- args: ['gradient', { static: false }]
11775
+ args: ['gradient']
11776
+ }], gradientElement: [{
11777
+ type: ViewChild,
11778
+ args: ['gradient', { read: ElementRef }]
11330
11779
  }], palette: [{
11331
11780
  type: ViewChild,
11332
- args: ['palette', { static: false }]
11781
+ args: ['palette']
11333
11782
  }], footer: [{
11334
11783
  type: ViewChild,
11335
- args: ['footer', { static: false }]
11784
+ args: ['footer']
11336
11785
  }] } });
11337
11786
 
11338
11787
  const DOM_FOCUS_EVENTS = ['focus', 'blur'];
11339
11788
  const DEFAULT_SIZE$3 = 'medium';
11340
11789
  const DEFAULT_ROUNDED$2 = 'medium';
11341
11790
  const DEFAULT_FILL_MODE$1 = 'solid';
11791
+ /**
11792
+ * @hidden
11793
+ */
11794
+ let nextColorPickerId = 0;
11342
11795
  /**
11343
11796
  * Represents the [Kendo UI ColorPicker component for Angular]({% slug overview_colorpicker %}).
11344
11797
  *
@@ -11346,15 +11799,17 @@ const DEFAULT_FILL_MODE$1 = 'solid';
11346
11799
  * which are rendered in its popup. It supports previewing the selected color, reverting it to its previous state or clearing it completely.
11347
11800
  */
11348
11801
  class ColorPickerComponent {
11349
- constructor(host, popupService, cdr, localizationService, ngZone, renderer) {
11802
+ constructor(host, popupService, cdr, localizationService, ngZone, renderer, injector) {
11350
11803
  this.host = host;
11351
11804
  this.popupService = popupService;
11352
11805
  this.cdr = cdr;
11353
11806
  this.localizationService = localizationService;
11354
11807
  this.ngZone = ngZone;
11355
11808
  this.renderer = renderer;
11809
+ this.injector = injector;
11356
11810
  this.hostClasses = true;
11357
- this.role = 'listbox';
11811
+ this.role = 'combobox';
11812
+ this.hasPopup = 'dialog';
11358
11813
  /**
11359
11814
  * Specifies the views that will be rendered in the popup.
11360
11815
  * By default both the gradient and palette views will be rendered.
@@ -11462,6 +11917,7 @@ class ColorPickerComponent {
11462
11917
  this._rounded = 'medium';
11463
11918
  this._fillMode = 'solid';
11464
11919
  this.subscriptions = new Subscription();
11920
+ this.popupSubs = new Subscription();
11465
11921
  this.notifyNgTouched = () => { };
11466
11922
  this.notifyNgChanged = () => { };
11467
11923
  this.domFocusListener = (event) => event.stopImmediatePropagation();
@@ -11469,6 +11925,7 @@ class ColorPickerComponent {
11469
11925
  this.dynamicRTLSubscription = this.localizationService.changes.subscribe(({ rtl }) => {
11470
11926
  this.direction = rtl ? 'rtl' : 'ltr';
11471
11927
  });
11928
+ this.colorPickerId = nextColorPickerId++;
11472
11929
  }
11473
11930
  get focusedClass() {
11474
11931
  return this.isFocused;
@@ -11485,6 +11942,10 @@ class ColorPickerComponent {
11485
11942
  get hostTabindex() {
11486
11943
  return this.tabindex;
11487
11944
  }
11945
+ get isControlInvalid() {
11946
+ var _a, _b;
11947
+ return (_b = ((_a = this.control) === null || _a === void 0 ? void 0 : _a.invalid)) === null || _b === void 0 ? void 0 : _b.toString();
11948
+ }
11488
11949
  /**
11489
11950
  * @hidden
11490
11951
  */
@@ -11627,6 +12088,8 @@ class ColorPickerComponent {
11627
12088
  columns: this._paletteSettings.columns || presetColumns || 10
11628
12089
  };
11629
12090
  this.handleHostId();
12091
+ this.renderer.setAttribute(this.host.nativeElement, 'aria-controls', `k-colorpicker-popup-${this.colorPickerId}`);
12092
+ this.control = this.injector.get(NgControl, null);
11630
12093
  }
11631
12094
  ngAfterViewInit() {
11632
12095
  const stylingInputs = ['size', 'rounded', 'fillMode'];
@@ -11903,19 +12366,21 @@ class ColorPickerComponent {
11903
12366
  content: this.popupTemplate,
11904
12367
  positionMode: 'absolute'
11905
12368
  });
11906
- this.popupRef.popupAnchorViewportLeave.subscribe(() => {
12369
+ this.renderer.setAttribute(this.popupRef.popupElement.querySelector('.k-colorpicker-popup'), 'id', `k-colorpicker-popup-${this.colorPickerId}`);
12370
+ this.popupSubs.add(this.popupRef.popupAnchorViewportLeave.subscribe(() => {
11907
12371
  this.toggleWithEvents(false);
11908
12372
  if (!this.isOpen) {
11909
12373
  this.host.nativeElement.focus({
11910
12374
  preventScroll: true
11911
12375
  });
11912
12376
  }
11913
- });
12377
+ }));
11914
12378
  }
11915
12379
  closePopup() {
11916
12380
  if (!this.isOpen) {
11917
12381
  return;
11918
12382
  }
12383
+ this.popupSubs.unsubscribe();
11919
12384
  this.popupRef.close();
11920
12385
  this.popupRef = null;
11921
12386
  }
@@ -11938,7 +12403,7 @@ class ColorPickerComponent {
11938
12403
  if (gradient && inputs && inputs.formatView === 'hex') {
11939
12404
  return inputs.hexInput;
11940
12405
  }
11941
- return this.gradientSettings.opacity ? inputs.opacityInput.numericInput : inputs.blueInput;
12406
+ return this.gradientSettings.opacity ? inputs.opacityInput.numericInput : inputs.blueInput.numericInput;
11942
12407
  }
11943
12408
  handleDomEvents(action, events) {
11944
12409
  const hostElement = this.host.nativeElement;
@@ -11986,8 +12451,8 @@ class ColorPickerComponent {
11986
12451
  }
11987
12452
  }
11988
12453
  }
11989
- ColorPickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorPickerComponent, deps: [{ token: i0.ElementRef }, { token: i1$3.PopupService }, { token: i0.ChangeDetectorRef }, { token: i1.LocalizationService }, { token: i0.NgZone }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component });
11990
- ColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorPickerComponent, selector: "kendo-colorpicker", inputs: { views: "views", view: "view", activeView: "activeView", readonly: "readonly", disabled: "disabled", format: "format", value: "value", popupSettings: "popupSettings", paletteSettings: "paletteSettings", gradientSettings: "gradientSettings", icon: "icon", iconClass: "iconClass", clearButton: "clearButton", tabindex: "tabindex", preview: "preview", actionsLayout: "actionsLayout", size: "size", rounded: "rounded", fillMode: "fillMode" }, outputs: { valueChange: "valueChange", open: "open", close: "close", onFocus: "focus", onBlur: "blur", cancel: "cancel", activeColorClick: "activeColorClick", activeViewChange: "activeViewChange" }, host: { properties: { "class.k-colorpicker": "this.hostClasses", "class.k-icon-picker": "this.hostClasses", "class.k-picker": "this.hostClasses", "class.k-focus": "this.focusedClass", "attr.aria-disabled": "this.disabledClass", "class.k-disabled": "this.disabledClass", "attr.aria-readonly": "this.ariaReadonly", "attr.aria-expanded": "this.ariaExpanded", "attr.tabindex": "this.hostTabindex", "attr.dir": "this.direction", "attr.role": "this.role" } }, providers: [{
12454
+ ColorPickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ColorPickerComponent, deps: [{ token: i0.ElementRef }, { token: i1$3.PopupService }, { token: i0.ChangeDetectorRef }, { token: i1.LocalizationService }, { token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
12455
+ ColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ColorPickerComponent, selector: "kendo-colorpicker", inputs: { views: "views", view: "view", activeView: "activeView", readonly: "readonly", disabled: "disabled", format: "format", value: "value", popupSettings: "popupSettings", paletteSettings: "paletteSettings", gradientSettings: "gradientSettings", icon: "icon", iconClass: "iconClass", clearButton: "clearButton", tabindex: "tabindex", preview: "preview", actionsLayout: "actionsLayout", size: "size", rounded: "rounded", fillMode: "fillMode" }, outputs: { valueChange: "valueChange", open: "open", close: "close", onFocus: "focus", onBlur: "blur", cancel: "cancel", activeColorClick: "activeColorClick", activeViewChange: "activeViewChange" }, host: { properties: { "class.k-colorpicker": "this.hostClasses", "class.k-icon-picker": "this.hostClasses", "class.k-picker": "this.hostClasses", "class.k-focus": "this.focusedClass", "attr.aria-disabled": "this.disabledClass", "class.k-disabled": "this.disabledClass", "attr.aria-readonly": "this.ariaReadonly", "attr.aria-expanded": "this.ariaExpanded", "attr.tabindex": "this.hostTabindex", "attr.dir": "this.direction", "attr.role": "this.role", "attr.aria-haspopup": "this.hasPopup", "attr.aria-invalid": "this.isControlInvalid" } }, providers: [{
11991
12456
  multi: true,
11992
12457
  provide: NG_VALUE_ACCESSOR,
11993
12458
  useExisting: forwardRef(() => ColorPickerComponent)
@@ -12037,7 +12502,23 @@ ColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
12037
12502
  i18n-applyButton="kendo.colorpicker.applyButton|The message for the Apply action button."
12038
12503
  applyButton="Apply"
12039
12504
  i18n-cancelButton="kendo.colorpicker.cancelButton|The message for the Cancel action button."
12040
- cancelButton="Cancel">
12505
+ cancelButton="Cancel"
12506
+ i18n-redChannelLabel="kendo.colorpicker.redChannelLabel|The label of the NumericTextBox representing the red color channel."
12507
+ redChannelLabel="Red channel"
12508
+ i18n-greenChannelLabel="kendo.colorpicker.greenChannelLabel|The label of the NumericTextBox representing the green color channel."
12509
+ greenChannelLabel="Green channel"
12510
+ i18n-blueChannelLabel="kendo.colorpicker.blueChannelLabel|The label of the NumericTextBox representing the blue color channel."
12511
+ blueChannelLabel="Blue channel"
12512
+ i18n-alphaChannelLabel="kendo.colorpicker.alphaChannelLabel|The label of the NumericTextBox representing the alpha color channel."
12513
+ alphaChannelLabel="Alpha channel"
12514
+ i18n-redInputPlaceholder="kendo.colorpicker.redInputPlaceholder|The placeholder for the red color input."
12515
+ redChannelLabel="R"
12516
+ i18n-greenInputPlaceholder="kendo.colorpicker.greenInputPlaceholder|The placeholder for the green color input."
12517
+ greenInputPlaceholder="G"
12518
+ i18n-blueInputPlaceholder="kendo.colorpicker.blueInputPlaceholder|The placeholder for the blue color input."
12519
+ blueInputPlaceholder="B"
12520
+ i18n-hexInputPlaceholder="kendo.colorpicker.hexInputPlaceholder|The placeholder for the HEX color input."
12521
+ hexInputPlaceholder="HEX">
12041
12522
  </ng-container>
12042
12523
  <span #activeColor class="k-input-inner">
12043
12524
  <span
@@ -12050,6 +12531,8 @@ ColorPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
12050
12531
  <button
12051
12532
  tabindex="-1"
12052
12533
  type="button"
12534
+ role="none"
12535
+ aria-hidden="true"
12053
12536
  class="k-input-button k-button k-button-md k-button-solid k-button-solid-base k-icon-button">
12054
12537
  <span class="k-button-icon k-icon k-i-caret-alt-down"></span>
12055
12538
  </button>
@@ -12130,7 +12613,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
12130
12613
  i18n-applyButton="kendo.colorpicker.applyButton|The message for the Apply action button."
12131
12614
  applyButton="Apply"
12132
12615
  i18n-cancelButton="kendo.colorpicker.cancelButton|The message for the Cancel action button."
12133
- cancelButton="Cancel">
12616
+ cancelButton="Cancel"
12617
+ i18n-redChannelLabel="kendo.colorpicker.redChannelLabel|The label of the NumericTextBox representing the red color channel."
12618
+ redChannelLabel="Red channel"
12619
+ i18n-greenChannelLabel="kendo.colorpicker.greenChannelLabel|The label of the NumericTextBox representing the green color channel."
12620
+ greenChannelLabel="Green channel"
12621
+ i18n-blueChannelLabel="kendo.colorpicker.blueChannelLabel|The label of the NumericTextBox representing the blue color channel."
12622
+ blueChannelLabel="Blue channel"
12623
+ i18n-alphaChannelLabel="kendo.colorpicker.alphaChannelLabel|The label of the NumericTextBox representing the alpha color channel."
12624
+ alphaChannelLabel="Alpha channel"
12625
+ i18n-redInputPlaceholder="kendo.colorpicker.redInputPlaceholder|The placeholder for the red color input."
12626
+ redChannelLabel="R"
12627
+ i18n-greenInputPlaceholder="kendo.colorpicker.greenInputPlaceholder|The placeholder for the green color input."
12628
+ greenInputPlaceholder="G"
12629
+ i18n-blueInputPlaceholder="kendo.colorpicker.blueInputPlaceholder|The placeholder for the blue color input."
12630
+ blueInputPlaceholder="B"
12631
+ i18n-hexInputPlaceholder="kendo.colorpicker.hexInputPlaceholder|The placeholder for the HEX color input."
12632
+ hexInputPlaceholder="HEX">
12134
12633
  </ng-container>
12135
12634
  <span #activeColor class="k-input-inner">
12136
12635
  <span
@@ -12143,6 +12642,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
12143
12642
  <button
12144
12643
  tabindex="-1"
12145
12644
  type="button"
12645
+ role="none"
12646
+ aria-hidden="true"
12146
12647
  class="k-input-button k-button k-button-md k-button-solid k-button-solid-base k-icon-button">
12147
12648
  <span class="k-button-icon k-icon k-i-caret-alt-down"></span>
12148
12649
  </button>
@@ -12169,7 +12670,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
12169
12670
  <ng-container #container></ng-container>
12170
12671
  `
12171
12672
  }]
12172
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$3.PopupService }, { type: i0.ChangeDetectorRef }, { type: i1.LocalizationService }, { type: i0.NgZone }, { type: i0.Renderer2 }]; }, propDecorators: { hostClasses: [{
12673
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$3.PopupService }, { type: i0.ChangeDetectorRef }, { type: i1.LocalizationService }, { type: i0.NgZone }, { type: i0.Renderer2 }, { type: i0.Injector }]; }, propDecorators: { hostClasses: [{
12173
12674
  type: HostBinding,
12174
12675
  args: ['class.k-colorpicker']
12175
12676
  }, {
@@ -12202,6 +12703,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
12202
12703
  }], role: [{
12203
12704
  type: HostBinding,
12204
12705
  args: ['attr.role']
12706
+ }], hasPopup: [{
12707
+ type: HostBinding,
12708
+ args: ['attr.aria-haspopup']
12709
+ }], isControlInvalid: [{
12710
+ type: HostBinding,
12711
+ args: ['attr.aria-invalid']
12205
12712
  }], views: [{
12206
12713
  type: Input
12207
12714
  }], view: [{
@@ -12305,6 +12812,30 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
12305
12812
  }]
12306
12813
  }], ctorParameters: function () { return [{ type: i1.LocalizationService }]; } });
12307
12814
 
12815
+ /**
12816
+ * @hidden
12817
+ */
12818
+ class FocusOnDomReadyDirective {
12819
+ constructor(host, ngZone) {
12820
+ this.host = host;
12821
+ this.ngZone = ngZone;
12822
+ }
12823
+ ngAfterContentInit() {
12824
+ this.focusOnNextTick();
12825
+ }
12826
+ focusOnNextTick() {
12827
+ this.ngZone.runOutsideAngular(() => setTimeout(() => this.host.nativeElement.focus()));
12828
+ }
12829
+ }
12830
+ FocusOnDomReadyDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FocusOnDomReadyDirective, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
12831
+ FocusOnDomReadyDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: FocusOnDomReadyDirective, selector: "[kendoFocusOnDomReady]", ngImport: i0 });
12832
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: FocusOnDomReadyDirective, decorators: [{
12833
+ type: Directive,
12834
+ args: [{
12835
+ selector: '[kendoFocusOnDomReady]'
12836
+ }]
12837
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }]; } });
12838
+
12308
12839
  const PUBLIC_DIRECTIVES = [
12309
12840
  ColorPickerComponent,
12310
12841
  ColorPaletteComponent,
@@ -12314,6 +12845,7 @@ const PUBLIC_DIRECTIVES = [
12314
12845
  ColorPickerCustomMessagesComponent
12315
12846
  ];
12316
12847
  const INTERNAL_DIRECTIVES = [
12848
+ NumericLabelDirective,
12317
12849
  ColorInputComponent,
12318
12850
  FocusOnDomReadyDirective,
12319
12851
  ContrastComponent,
@@ -12334,7 +12866,8 @@ ColorPickerModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", versi
12334
12866
  ColorGradientComponent,
12335
12867
  FlatColorPickerComponent,
12336
12868
  LocalizedColorPickerMessagesDirective,
12337
- ColorPickerCustomMessagesComponent, ColorInputComponent,
12869
+ ColorPickerCustomMessagesComponent, NumericLabelDirective,
12870
+ ColorInputComponent,
12338
12871
  FocusOnDomReadyDirective,
12339
12872
  ContrastComponent,
12340
12873
  ContrastValidationComponent,
@@ -14100,5 +14633,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
14100
14633
  * Generated bundle index. Do not edit.
14101
14634
  */
14102
14635
 
14103
- export { ActiveColorClickEvent, CheckBoxDirective, CheckBoxModule, ColorGradientComponent, ColorPaletteComponent, ColorPickerCancelEvent, ColorPickerCloseEvent, ColorPickerComponent, ColorPickerCustomMessagesComponent, ColorPickerModule, ColorPickerOpenEvent, ErrorComponent, FlatColorPickerComponent, FormFieldComponent, FormFieldModule, HintComponent, InputSeparatorComponent, InputsModule, LabelTemplateDirective, LocalizedColorPickerMessagesDirective, LocalizedNumericTextBoxMessagesDirective, LocalizedRangeSliderMessagesDirective, LocalizedSignatureMessagesDirective, LocalizedSliderMessagesDirective, LocalizedSwitchMessagesDirective, LocalizedTextBoxMessagesDirective, MaskedTextBoxComponent, MaskedTextBoxModule, NumericTextBoxComponent, NumericTextBoxCustomMessagesComponent, NumericTextBoxModule, RadioButtonDirective, RadioButtonModule, RangeSliderComponent, RangeSliderCustomMessagesComponent, RangeSliderModule, SharedModule, SignatureCloseEvent, SignatureComponent, SignatureCustomMessagesComponent, SignatureMessages, SignatureModule, SignatureOpenEvent, SliderComponent, SliderCustomMessagesComponent, SliderModule, SliderTicksComponent, SwitchComponent, SwitchCustomMessagesComponent, SwitchModule, TextAreaComponent, TextAreaDirective, TextAreaModule, TextAreaSuffixComponent, TextBoxComponent, TextBoxCustomMessagesComponent, TextBoxDirective, TextBoxModule, TextBoxPrefixTemplateDirective, TextBoxSuffixTemplateDirective };
14636
+ export { ActiveColorClickEvent, CheckBoxDirective, CheckBoxModule, ColorGradientComponent, ColorPaletteComponent, ColorPickerCancelEvent, ColorPickerCloseEvent, ColorPickerComponent, ColorPickerCustomMessagesComponent, ColorPickerModule, ColorPickerOpenEvent, ErrorComponent, FlatColorPickerComponent, FormFieldComponent, FormFieldModule, HintComponent, InputSeparatorComponent, InputsModule, LabelTemplateDirective, LocalizedColorPickerMessagesDirective, LocalizedNumericTextBoxMessagesDirective, LocalizedRangeSliderMessagesDirective, LocalizedSignatureMessagesDirective, LocalizedSliderMessagesDirective, LocalizedSwitchMessagesDirective, LocalizedTextBoxMessagesDirective, MaskedTextBoxComponent, MaskedTextBoxModule, NumericLabelDirective, NumericTextBoxComponent, NumericTextBoxCustomMessagesComponent, NumericTextBoxModule, RadioButtonDirective, RadioButtonModule, RangeSliderComponent, RangeSliderCustomMessagesComponent, RangeSliderModule, SharedModule, SignatureCloseEvent, SignatureComponent, SignatureCustomMessagesComponent, SignatureMessages, SignatureModule, SignatureOpenEvent, SliderComponent, SliderCustomMessagesComponent, SliderModule, SliderTicksComponent, SwitchComponent, SwitchCustomMessagesComponent, SwitchModule, TextAreaComponent, TextAreaDirective, TextAreaModule, TextAreaSuffixComponent, TextBoxComponent, TextBoxCustomMessagesComponent, TextBoxDirective, TextBoxModule, TextBoxPrefixTemplateDirective, TextBoxSuffixTemplateDirective };
14104
14637