igniteui-angular 13.2.11 → 13.2.14
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.
- package/esm2020/lib/date-picker/date-picker.component.mjs +2 -1
- package/esm2020/lib/date-range-picker/date-range-picker.component.mjs +3 -3
- package/esm2020/lib/directives/drag-drop/drag-drop.directive.mjs +9 -5
- package/esm2020/lib/directives/radio/radio-group.directive.mjs +11 -5
- package/esm2020/lib/grids/grid-navigation.service.mjs +8 -3
- package/esm2020/lib/grids/selection/selection.service.mjs +9 -4
- package/esm2020/lib/radio/radio.component.mjs +15 -2
- package/esm2020/lib/simple-combo/simple-combo.component.mjs +7 -2
- package/esm2020/lib/time-picker/time-picker.component.mjs +3 -2
- package/fesm2015/igniteui-angular.mjs +57 -17
- package/fesm2015/igniteui-angular.mjs.map +1 -1
- package/fesm2020/igniteui-angular.mjs +57 -17
- package/fesm2020/igniteui-angular.mjs.map +1 -1
- package/lib/directives/radio/radio-group.directive.d.ts +5 -0
- package/lib/grids/selection/selection.service.d.ts +2 -1
- package/lib/radio/radio.component.d.ts +13 -2
- package/package.json +1 -1
|
@@ -7,7 +7,7 @@ import { NgModel, FormControlName, NG_VALUE_ACCESSOR, NG_VALIDATORS, CheckboxReq
|
|
|
7
7
|
import * as i4 from '@angular/common';
|
|
8
8
|
import { isPlatformBrowser, formatDate as formatDate$1, CurrencyPipe, formatPercent, formatNumber, getLocaleCurrencyCode, DatePipe, DOCUMENT, CommonModule, FormatWidth, getLocaleDateFormat, getLocaleNumberFormat, NumberFormatStyle, getCurrencySymbol } from '@angular/common';
|
|
9
9
|
import { Observable, Subject, fromEvent, interval, animationFrameScheduler, noop, merge, Subscription, timer, pipe } from 'rxjs';
|
|
10
|
-
import { takeUntil, filter, first as first$1, throttleTime, take, throttle, debounce, tap, switchMap, skipLast, map, debounceTime, shareReplay, takeWhile, pluck } from 'rxjs/operators';
|
|
10
|
+
import { takeUntil, filter, first as first$1, throttleTime, take, throttle, startWith, debounce, tap, switchMap, skipLast, map, debounceTime, shareReplay, takeWhile, pluck } from 'rxjs/operators';
|
|
11
11
|
import mergeWith from 'lodash.mergewith';
|
|
12
12
|
import { __awaiter, __decorate, __param } from 'tslib';
|
|
13
13
|
import * as JSZip from 'jszip';
|
|
@@ -14797,7 +14797,9 @@ class IgxDragDirective {
|
|
|
14797
14797
|
}
|
|
14798
14798
|
}
|
|
14799
14799
|
get ghostLeft() {
|
|
14800
|
-
|
|
14800
|
+
if (this.ghostElement) {
|
|
14801
|
+
return parseInt(this.ghostElement.style.left, 10) + this._ghostHostX;
|
|
14802
|
+
}
|
|
14801
14803
|
}
|
|
14802
14804
|
set ghostTop(pageY) {
|
|
14803
14805
|
if (this.ghostElement) {
|
|
@@ -14808,7 +14810,9 @@ class IgxDragDirective {
|
|
|
14808
14810
|
}
|
|
14809
14811
|
}
|
|
14810
14812
|
get ghostTop() {
|
|
14811
|
-
|
|
14813
|
+
if (this.ghostElement) {
|
|
14814
|
+
return parseInt(this.ghostElement.style.top, 10) + this._ghostHostY;
|
|
14815
|
+
}
|
|
14812
14816
|
}
|
|
14813
14817
|
get windowScrollTop() {
|
|
14814
14818
|
return document.documentElement.scrollTop || window.scrollY;
|
|
@@ -15371,7 +15375,7 @@ class IgxDragDirective {
|
|
|
15371
15375
|
const ghostMarginLeft = parseInt(document.defaultView.getComputedStyle(this.ghostElement)['margin-left'], 10);
|
|
15372
15376
|
const ghostMarginTop = parseInt(document.defaultView.getComputedStyle(this.ghostElement)['margin-top'], 10);
|
|
15373
15377
|
this.ghostElement.style.left = (this._ghostStartX - ghostMarginLeft + totalMovedX - this._ghostHostX) + 'px';
|
|
15374
|
-
this.ghostElement.style.top = (this._ghostStartY - ghostMarginTop + totalMovedY - this.
|
|
15378
|
+
this.ghostElement.style.top = (this._ghostStartY - ghostMarginTop + totalMovedY - this._ghostHostY) + 'px';
|
|
15375
15379
|
if (this.pointerEventsEnabled) {
|
|
15376
15380
|
// The ghostElement takes control for moving and dragging after it has been rendered.
|
|
15377
15381
|
if (this._pointerDownId !== null) {
|
|
@@ -15558,7 +15562,7 @@ class IgxDragDirective {
|
|
|
15558
15562
|
const elementHeight = this.ghost && this.ghostElement ? this.ghostElement.offsetHeight : this.element.nativeElement.offsetHeight;
|
|
15559
15563
|
const bottomBorder = (!this.scrollContainer ? window.innerHeight : containerBounds.bottom) +
|
|
15560
15564
|
this.windowScrollTop - this._scrollContainerThreshold - elementHeight;
|
|
15561
|
-
// Same for window scroll left
|
|
15565
|
+
// Same for window scroll left
|
|
15562
15566
|
const leftBorder = (!this.scrollContainer ? 0 : containerBounds.left) + this.windowScrollLeft + this._scrollContainerThreshold;
|
|
15563
15567
|
// Subtract the element width again because we position it from top left corner.
|
|
15564
15568
|
const elementWidth = this.ghost && this.ghostElement ? this.ghostElement.offsetWidth : this.element.nativeElement.offsetWidth;
|
|
@@ -17465,6 +17469,11 @@ let nextId$3 = 0;
|
|
|
17465
17469
|
class IgxRadioComponent {
|
|
17466
17470
|
constructor(cdr) {
|
|
17467
17471
|
this.cdr = cdr;
|
|
17472
|
+
/**
|
|
17473
|
+
* @hidden
|
|
17474
|
+
* @internal
|
|
17475
|
+
*/
|
|
17476
|
+
this.destroy$ = new Subject();
|
|
17468
17477
|
/**
|
|
17469
17478
|
* Sets/gets the `id` of the radio component.
|
|
17470
17479
|
* If not set, the `id` of the first radio component will be `"igx-radio-0"`.
|
|
@@ -17638,6 +17647,14 @@ class IgxRadioComponent {
|
|
|
17638
17647
|
set disabled(value) {
|
|
17639
17648
|
this._disabled = (value === '') || value;
|
|
17640
17649
|
}
|
|
17650
|
+
/**
|
|
17651
|
+
* @hidden
|
|
17652
|
+
* @internal
|
|
17653
|
+
*/
|
|
17654
|
+
ngOnDestroy() {
|
|
17655
|
+
this.destroy$.next(true);
|
|
17656
|
+
this.destroy$.complete();
|
|
17657
|
+
}
|
|
17641
17658
|
/**
|
|
17642
17659
|
* @hidden
|
|
17643
17660
|
* @internal
|
|
@@ -17937,6 +17954,11 @@ class IgxRadioGroupDirective {
|
|
|
17937
17954
|
* @internal
|
|
17938
17955
|
*/
|
|
17939
17956
|
this.destroy$ = new Subject();
|
|
17957
|
+
/**
|
|
17958
|
+
* @hidden
|
|
17959
|
+
* @internal
|
|
17960
|
+
*/
|
|
17961
|
+
this.queryChange$ = new Subject();
|
|
17940
17962
|
}
|
|
17941
17963
|
/**
|
|
17942
17964
|
* Sets/gets the `value` attribute.
|
|
@@ -18082,8 +18104,9 @@ class IgxRadioGroupDirective {
|
|
|
18082
18104
|
// The initial value can possibly be set by NgModel and it is possible that
|
|
18083
18105
|
// the OnInit of the NgModel occurs after the OnInit of this class.
|
|
18084
18106
|
this._isInitialized = true;
|
|
18085
|
-
|
|
18086
|
-
this.
|
|
18107
|
+
this.radioButtons.changes.pipe(startWith(0), takeUntil(this.destroy$)).subscribe(() => {
|
|
18108
|
+
this.queryChange$.next();
|
|
18109
|
+
setTimeout(() => this._initRadioButtons());
|
|
18087
18110
|
});
|
|
18088
18111
|
}
|
|
18089
18112
|
/**
|
|
@@ -18161,7 +18184,7 @@ class IgxRadioGroupDirective {
|
|
|
18161
18184
|
button.checked = true;
|
|
18162
18185
|
this._selected = button;
|
|
18163
18186
|
}
|
|
18164
|
-
button.change.pipe(takeUntil(this.destroy$)).subscribe((ev) => this._selectedRadioButtonChanged(ev));
|
|
18187
|
+
button.change.pipe(takeUntil(button.destroy$), takeUntil(this.destroy$), takeUntil(this.queryChange$)).subscribe((ev) => this._selectedRadioButtonChanged(ev));
|
|
18165
18188
|
});
|
|
18166
18189
|
}
|
|
18167
18190
|
}
|
|
@@ -23771,9 +23794,13 @@ class IgxGridSelectionService {
|
|
|
23771
23794
|
*/
|
|
23772
23795
|
this.pointerEventInGridBody = false;
|
|
23773
23796
|
this._ranges = new Set();
|
|
23774
|
-
this.pointerOriginHandler = () => {
|
|
23797
|
+
this.pointerOriginHandler = (event) => {
|
|
23775
23798
|
this.pointerEventInGridBody = false;
|
|
23776
23799
|
document.body.removeEventListener('pointerup', this.pointerOriginHandler);
|
|
23800
|
+
const targetTagName = event.target.tagName.toLowerCase();
|
|
23801
|
+
if (targetTagName !== 'igx-grid-cell' && targetTagName !== 'igx-tree-grid-cell') {
|
|
23802
|
+
this.pointerUp(this._lastSelectedNode, this.grid.rangeSelected, true);
|
|
23803
|
+
}
|
|
23777
23804
|
};
|
|
23778
23805
|
this.initPointerState();
|
|
23779
23806
|
this.initKeyboardState();
|
|
@@ -23890,6 +23917,7 @@ class IgxGridSelectionService {
|
|
|
23890
23917
|
* and the start node of the `state`.
|
|
23891
23918
|
*/
|
|
23892
23919
|
generateRange(node, state) {
|
|
23920
|
+
this._lastSelectedNode = node;
|
|
23893
23921
|
if (!state) {
|
|
23894
23922
|
return {
|
|
23895
23923
|
rowStart: node.row,
|
|
@@ -24007,8 +24035,8 @@ class IgxGridSelectionService {
|
|
|
24007
24035
|
}
|
|
24008
24036
|
return true;
|
|
24009
24037
|
}
|
|
24010
|
-
pointerUp(node, emitter) {
|
|
24011
|
-
if (this.dragMode) {
|
|
24038
|
+
pointerUp(node, emitter, firedOutsideGrid) {
|
|
24039
|
+
if (this.dragMode || firedOutsideGrid) {
|
|
24012
24040
|
this.restoreTextSelection();
|
|
24013
24041
|
this.addRangeMeta(node, this.pointerState);
|
|
24014
24042
|
this.mergeMap(this.selection, this.temp);
|
|
@@ -37184,7 +37212,12 @@ class IgxSimpleComboComponent extends IgxComboBaseDirective {
|
|
|
37184
37212
|
}
|
|
37185
37213
|
return current === this.selection[0];
|
|
37186
37214
|
});
|
|
37187
|
-
this.
|
|
37215
|
+
if (!this.isRemote) {
|
|
37216
|
+
// navigate to item only if we have local data
|
|
37217
|
+
// as with remote data this will fiddle with igxFor's scroll handler
|
|
37218
|
+
// and will trigger another chunk load which will break the visualization
|
|
37219
|
+
this.dropdown.navigateItem(index);
|
|
37220
|
+
}
|
|
37188
37221
|
}
|
|
37189
37222
|
});
|
|
37190
37223
|
this.dropdown.opening.pipe(takeUntil(this.destroy$)).subscribe(() => {
|
|
@@ -38029,6 +38062,7 @@ class IgxDatePickerComponent extends PickerBaseDirective {
|
|
|
38029
38062
|
this._onTouchedCallback = noop;
|
|
38030
38063
|
this._onValidatorChange = noop;
|
|
38031
38064
|
this.onStatusChanged = () => {
|
|
38065
|
+
this.disabled = this._ngControl.disabled;
|
|
38032
38066
|
this.updateValidity();
|
|
38033
38067
|
this.inputGroup.isRequired = this.required;
|
|
38034
38068
|
};
|
|
@@ -42008,7 +42042,8 @@ class IgxTimePickerComponent extends PickerBaseDirective {
|
|
|
42008
42042
|
}
|
|
42009
42043
|
onStatusChanged() {
|
|
42010
42044
|
if ((this._ngControl.control.touched || this._ngControl.control.dirty) &&
|
|
42011
|
-
(this._ngControl.control.validator || this._ngControl.control.asyncValidator)
|
|
42045
|
+
(this._ngControl.control.validator || this._ngControl.control.asyncValidator) &&
|
|
42046
|
+
!this._ngControl.disabled) {
|
|
42012
42047
|
if (this._inputGroup.isFocused) {
|
|
42013
42048
|
this.inputDirective.valid = this._ngControl.valid ? IgxInputState.VALID : IgxInputState.INVALID;
|
|
42014
42049
|
}
|
|
@@ -58337,8 +58372,13 @@ class IgxGridNavigationService {
|
|
|
58337
58372
|
this.grid.clearCellSelection();
|
|
58338
58373
|
this.grid.navigateTo(this.activeNode.row, this.activeNode.column, (obj) => {
|
|
58339
58374
|
var _a;
|
|
58340
|
-
(
|
|
58341
|
-
|
|
58375
|
+
if (this.activeNode.row === obj.target.row.index) {
|
|
58376
|
+
(_a = obj.target) === null || _a === void 0 ? void 0 : _a.activate(event);
|
|
58377
|
+
this.grid.cdr.detectChanges();
|
|
58378
|
+
}
|
|
58379
|
+
else {
|
|
58380
|
+
this.grid.navigateTo(this.activeNode.row, this.activeNode.column);
|
|
58381
|
+
}
|
|
58342
58382
|
});
|
|
58343
58383
|
}
|
|
58344
58384
|
else {
|
|
@@ -83766,14 +83806,14 @@ class IgxDateRangePickerComponent extends PickerBaseDirective {
|
|
|
83766
83806
|
this.onValidatorChange = noop;
|
|
83767
83807
|
this.onStatusChanged = () => {
|
|
83768
83808
|
if (this.inputGroup) {
|
|
83769
|
-
this.inputDirective.valid = this.isTouchedOrDirty
|
|
83809
|
+
this.inputDirective.valid = this.isTouchedOrDirty && !this._ngControl.disabled
|
|
83770
83810
|
? this.getInputState(this.inputGroup.isFocused)
|
|
83771
83811
|
: IgxInputState.INITIAL;
|
|
83772
83812
|
}
|
|
83773
83813
|
else if (this.hasProjectedInputs) {
|
|
83774
83814
|
this.projectedInputs
|
|
83775
83815
|
.forEach(i => {
|
|
83776
|
-
i.inputDirective.valid = this.isTouchedOrDirty
|
|
83816
|
+
i.inputDirective.valid = this.isTouchedOrDirty && !this._ngControl.disabled
|
|
83777
83817
|
? this.getInputState(i.isFocused)
|
|
83778
83818
|
: IgxInputState.INITIAL;
|
|
83779
83819
|
;
|