@ngutil/aria 0.0.101 → 0.0.104
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/fesm2022/ngutil-aria.mjs +76 -74
- package/fesm2022/ngutil-aria.mjs.map +1 -1
- package/index.d.ts +436 -5
- package/package.json +6 -6
- package/activity/activity.service.d.ts +0 -23
- package/activity/index.d.ts +0 -1
- package/focus/focus-state.directive.d.ts +0 -16
- package/focus/focus-trap.directive.d.ts +0 -8
- package/focus/focus.service.d.ts +0 -22
- package/focus/focusable.directive.d.ts +0 -13
- package/focus/index.d.ts +0 -4
- package/gestures/gesture-drag.d.ts +0 -21
- package/gestures/gesture-event.d.ts +0 -40
- package/gestures/gesture-longtap.d.ts +0 -13
- package/gestures/gesture-tap.d.ts +0 -12
- package/gestures/gesture.d.ts +0 -84
- package/gestures/gesture.service.d.ts +0 -20
- package/gestures/index.d.ts +0 -6
- package/keystroke/index.d.ts +0 -1
- package/keystroke/keystroke.service.d.ts +0 -22
- package/ui-state/abstract.d.ts +0 -19
- package/ui-state/busy.directive.d.ts +0 -9
- package/ui-state/dirty.directive.d.ts +0 -9
- package/ui-state/disabled.directive.d.ts +0 -9
- package/ui-state/index.d.ts +0 -17
- package/ui-state/progress-state.d.ts +0 -71
- package/ui-state/readonly.directive.d.ts +0 -9
- package/ui-state/selector.d.ts +0 -60
- package/ui-state/ui-state.d.ts +0 -36
package/fesm2022/ngutil-aria.mjs
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { DOCUMENT } from '@angular/common';
|
|
2
1
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { inject, NgZone, Injectable, ElementRef, computed, Directive, input, signal, untracked, effect, NgModule } from '@angular/core';
|
|
2
|
+
import { inject, NgZone, DOCUMENT, Injectable, ElementRef, computed, Directive, input, signal, untracked, effect, NgModule } from '@angular/core';
|
|
4
3
|
import { merge, fromEvent, map, share, filter, shareReplay, startWith, throttleTime, switchMap, timer, take, distinctUntilChanged, BehaviorSubject, connect, Subject, tap, finalize, scan, of, combineLatest, Observable, EMPTY, from, debounceTime, takeWhile, animationFrames } from 'rxjs';
|
|
5
4
|
import { isEqualStrict, isEqual, coerceElement, Destructible, isElementInput, __zone_symbol__, isFalsy, isTruthy, deepClone, coerceBoolAttr } from '@ngutil/common';
|
|
6
5
|
import { FocusTrapFactory } from '@angular/cdk/a11y';
|
|
@@ -45,10 +44,10 @@ class ActivityService {
|
|
|
45
44
|
watchInactvity(timeout) {
|
|
46
45
|
return this.events$.pipe(startWith(null), throttleTime(timeout / 2), switchMap(() => timer(0, timeout).pipe(take(2))), map(v => v !== 0), distinctUntilChanged(), shareReplay(1));
|
|
47
46
|
}
|
|
48
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
49
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
47
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: ActivityService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
48
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: ActivityService, providedIn: "root" }); }
|
|
50
49
|
}
|
|
51
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
50
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: ActivityService, decorators: [{
|
|
52
51
|
type: Injectable,
|
|
53
52
|
args: [{ providedIn: "root" }]
|
|
54
53
|
}] });
|
|
@@ -201,10 +200,10 @@ class FocusService {
|
|
|
201
200
|
this.#originOverrides.next(map);
|
|
202
201
|
}
|
|
203
202
|
}
|
|
204
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
205
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
203
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: FocusService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
204
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: FocusService, providedIn: "root" }); }
|
|
206
205
|
}
|
|
207
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
206
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: FocusService, decorators: [{
|
|
208
207
|
type: Injectable,
|
|
209
208
|
args: [{ providedIn: "root" }]
|
|
210
209
|
}] });
|
|
@@ -259,22 +258,22 @@ class FocusState {
|
|
|
259
258
|
this.event$ = combineLatest([this.#self, this.#connEvent]).pipe(
|
|
260
259
|
// debounceTime(100), // TODO: miért volt ez itt?
|
|
261
260
|
map(([self, conn]) => (self.origin !== null ? self : conn.origin !== null ? conn : this.#default)), distinctUntilChanged(isEqual), shareReplay(1));
|
|
262
|
-
this.event = toSignal(this.event$, {
|
|
261
|
+
this.event = toSignal(this.event$, { manualCleanup: true, equal: isEqual });
|
|
263
262
|
this.self = computed(() => {
|
|
264
263
|
const event = this.event();
|
|
265
264
|
if (event == null) {
|
|
266
265
|
return null;
|
|
267
266
|
}
|
|
268
267
|
return event.element === this.#el.nativeElement ? event.origin : null;
|
|
269
|
-
});
|
|
268
|
+
}, ...(ngDevMode ? [{ debugName: "self" }] : []));
|
|
270
269
|
this.within = computed(() => {
|
|
271
270
|
const event = this.event();
|
|
272
271
|
if (event == null) {
|
|
273
272
|
return null;
|
|
274
273
|
}
|
|
275
274
|
return event.element !== this.#el.nativeElement ? event.origin : null;
|
|
276
|
-
});
|
|
277
|
-
this.has = computed(() => this.self() || this.within());
|
|
275
|
+
}, ...(ngDevMode ? [{ debugName: "within" }] : []));
|
|
276
|
+
this.has = computed(() => this.self() || this.within(), ...(ngDevMode ? [{ debugName: "has" }] : []));
|
|
278
277
|
this.#parent?.connect(this).pipe(takeUntilDestroyed()).subscribe();
|
|
279
278
|
// effect(() => {
|
|
280
279
|
// console.log(this.#el.nativeElement, this.has())
|
|
@@ -295,11 +294,11 @@ class FocusState {
|
|
|
295
294
|
};
|
|
296
295
|
});
|
|
297
296
|
}
|
|
298
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
299
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
297
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: FocusState, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
298
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.13", type: FocusState, isStandalone: true, host: { properties: { "attr.focus": "self()", "attr.focus-within": "within()", "attr.focus-present": "has()" } }, ngImport: i0 }); }
|
|
300
299
|
}
|
|
301
300
|
_a$1 = FocusState;
|
|
302
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
301
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: FocusState, decorators: [{
|
|
303
302
|
type: Directive,
|
|
304
303
|
args: [{
|
|
305
304
|
host: {
|
|
@@ -314,8 +313,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
|
|
|
314
313
|
class Focusable {
|
|
315
314
|
constructor() {
|
|
316
315
|
this.state = inject(FocusState);
|
|
317
|
-
this.focusable = input(true, { alias: "nuFocusable" });
|
|
318
|
-
this.tabindex = input(0, { transform: Number });
|
|
316
|
+
this.focusable = input(true, ...(ngDevMode ? [{ debugName: "focusable", alias: "nuFocusable" }] : [{ alias: "nuFocusable" }]));
|
|
317
|
+
this.tabindex = input(0, ...(ngDevMode ? [{ debugName: "tabindex", transform: Number }] : [{ transform: Number }]));
|
|
319
318
|
this._tabindex = computed(() => {
|
|
320
319
|
const focusable = this.focusable();
|
|
321
320
|
const tabindex = this.tabindex();
|
|
@@ -329,7 +328,7 @@ class Focusable {
|
|
|
329
328
|
return tabindex;
|
|
330
329
|
}
|
|
331
330
|
return 0;
|
|
332
|
-
});
|
|
331
|
+
}, ...(ngDevMode ? [{ debugName: "_tabindex" }] : []));
|
|
333
332
|
}
|
|
334
333
|
connect(value) {
|
|
335
334
|
if (value instanceof FocusState || isElementInput(value)) {
|
|
@@ -339,10 +338,10 @@ class Focusable {
|
|
|
339
338
|
return this.state.connect(value.state);
|
|
340
339
|
}
|
|
341
340
|
}
|
|
342
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
343
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
341
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: Focusable, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
342
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.13", type: Focusable, isStandalone: true, selector: "[nuFocusable]", inputs: { focusable: { classPropertyName: "focusable", publicName: "nuFocusable", isSignal: true, isRequired: false, transformFunction: null }, tabindex: { classPropertyName: "tabindex", publicName: "tabindex", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.tabindex": "_tabindex()" } }, exportAs: ["nuFocusable"], hostDirectives: [{ directive: FocusState }], ngImport: i0 }); }
|
|
344
343
|
}
|
|
345
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
344
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: Focusable, decorators: [{
|
|
346
345
|
type: Directive,
|
|
347
346
|
args: [{
|
|
348
347
|
selector: "[nuFocusable]",
|
|
@@ -352,7 +351,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
|
|
|
352
351
|
},
|
|
353
352
|
hostDirectives: [FocusState]
|
|
354
353
|
}]
|
|
355
|
-
}] });
|
|
354
|
+
}], propDecorators: { focusable: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuFocusable", required: false }] }], tabindex: [{ type: i0.Input, args: [{ isSignal: true, alias: "tabindex", required: false }] }] } });
|
|
356
355
|
|
|
357
356
|
class KeystrokeService {
|
|
358
357
|
#document = inject(DOCUMENT);
|
|
@@ -409,10 +408,10 @@ class KeystrokeService {
|
|
|
409
408
|
#focusActivation(element) {
|
|
410
409
|
return this.#focusEvent.pipe(map(focused => focused === element || element.contains(focused)));
|
|
411
410
|
}
|
|
412
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
413
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
411
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: KeystrokeService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
412
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: KeystrokeService, providedIn: "root" }); }
|
|
414
413
|
}
|
|
415
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
414
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: KeystrokeService, decorators: [{
|
|
416
415
|
type: Injectable,
|
|
417
416
|
args: [{ providedIn: "root" }]
|
|
418
417
|
}] });
|
|
@@ -796,7 +795,7 @@ class GestureService {
|
|
|
796
795
|
const state = { events: [], gestures, includeScrollDistance };
|
|
797
796
|
return merge(src.pipe(tap(event => state.events.push(event))), ...Array.from(gestures.keys())
|
|
798
797
|
.sort(sortByPripority)
|
|
799
|
-
.map(gesture => gesture.capture(src.pipe(filter(gesture.shouldCapture.bind(gesture)))).pipe(takeWhile(result => result !== GestureCaptureState.Skip, true), tap(result => gestures.set(gesture, result))))).pipe(map(() => state));
|
|
798
|
+
.map(gesture => gesture.capture(src.pipe(filter(gesture.shouldCapture.bind(gesture)), share())).pipe(takeWhile(result => result !== GestureCaptureState.Skip, true), tap(result => gestures.set(gesture, result))))).pipe(map(() => state));
|
|
800
799
|
})
|
|
801
800
|
// finalize(() => console.log("FINALIZE CAPTURE"))
|
|
802
801
|
);
|
|
@@ -835,7 +834,7 @@ class GestureService {
|
|
|
835
834
|
// finalize(() => console.log("FINALIZE SELECT"))
|
|
836
835
|
);
|
|
837
836
|
return selectGesture.pipe(switchMap(({ events, gesture }) => gesture
|
|
838
|
-
.handle(eventStream.pipe(startWith(...events), tap(({ origin }) => preventDefault(origin)), filter(gesture.isRelevantEvent.bind(gesture))))
|
|
837
|
+
.handle(eventStream.pipe(startWith(...events), tap(({ origin }) => preventDefault(origin)), filter(gesture.isRelevantEvent.bind(gesture)), share()))
|
|
839
838
|
.pipe(takeWhile(v => v.phase !== GesturePhase.End, true), tap(detail => dispatchEvent(new CustomEvent(gesture.type, { detail, bubbles: true, cancelable: true })))
|
|
840
839
|
// finalize(() => console.log("GESTURE FINALIZE"))
|
|
841
840
|
)),
|
|
@@ -933,10 +932,10 @@ class GestureService {
|
|
|
933
932
|
this.#lastTouchAction = undefined;
|
|
934
933
|
}
|
|
935
934
|
};
|
|
936
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
937
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
935
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: GestureService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
936
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: GestureService, providedIn: "root" }); }
|
|
938
937
|
}
|
|
939
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
938
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: GestureService, decorators: [{
|
|
940
939
|
type: Injectable,
|
|
941
940
|
args: [{ providedIn: "root" }]
|
|
942
941
|
}], ctorParameters: () => [] });
|
|
@@ -990,6 +989,9 @@ function preventDefault(event) {
|
|
|
990
989
|
event.preventDefault();
|
|
991
990
|
}
|
|
992
991
|
}
|
|
992
|
+
function reduceCaptureStates(states) {
|
|
993
|
+
return Math.min(...states);
|
|
994
|
+
}
|
|
993
995
|
|
|
994
996
|
const COMPILE_CACHE = {};
|
|
995
997
|
function compile(selector) {
|
|
@@ -1303,7 +1305,7 @@ var _a;
|
|
|
1303
1305
|
class UiState {
|
|
1304
1306
|
constructor() {
|
|
1305
1307
|
this.#parent = inject(_a, { skipSelf: true, optional: true });
|
|
1306
|
-
this.#self = signal({});
|
|
1308
|
+
this.#self = signal({}, ...(ngDevMode ? [{ debugName: "#self" }] : []));
|
|
1307
1309
|
this.merged = computed(() => {
|
|
1308
1310
|
const parent = this.#parent?.merged();
|
|
1309
1311
|
const self = this.#self();
|
|
@@ -1328,7 +1330,7 @@ class UiState {
|
|
|
1328
1330
|
else {
|
|
1329
1331
|
return self;
|
|
1330
1332
|
}
|
|
1331
|
-
});
|
|
1333
|
+
}, ...(ngDevMode ? [{ debugName: "merged" }] : []));
|
|
1332
1334
|
this.value = computed(() => {
|
|
1333
1335
|
const merged = this.merged();
|
|
1334
1336
|
const result = {};
|
|
@@ -1336,8 +1338,8 @@ class UiState {
|
|
|
1336
1338
|
result[k] = Object.values(v).includes(true);
|
|
1337
1339
|
}
|
|
1338
1340
|
return result;
|
|
1339
|
-
});
|
|
1340
|
-
this.inertSelector = signal("busy || disabled");
|
|
1341
|
+
}, ...(ngDevMode ? [{ debugName: "value" }] : []));
|
|
1342
|
+
this.inertSelector = signal("busy || disabled", ...(ngDevMode ? [{ debugName: "inertSelector" }] : []));
|
|
1341
1343
|
}
|
|
1342
1344
|
#parent;
|
|
1343
1345
|
get root() {
|
|
@@ -1376,11 +1378,11 @@ class UiState {
|
|
|
1376
1378
|
isInert() {
|
|
1377
1379
|
return this.is(this.inertSelector());
|
|
1378
1380
|
}
|
|
1379
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1380
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
1381
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: UiState, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1382
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.13", type: UiState, isStandalone: true, ngImport: i0 }); }
|
|
1381
1383
|
}
|
|
1382
1384
|
_a = UiState;
|
|
1383
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1385
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: UiState, decorators: [{
|
|
1384
1386
|
type: Directive,
|
|
1385
1387
|
args: [{}]
|
|
1386
1388
|
}] });
|
|
@@ -1397,8 +1399,8 @@ class AbstractUiState {
|
|
|
1397
1399
|
return this.state.is(`${this.name}.self || (${when})`);
|
|
1398
1400
|
}
|
|
1399
1401
|
return this.state.is(this.name);
|
|
1400
|
-
});
|
|
1401
|
-
this.no = computed(() => !this.yes());
|
|
1402
|
+
}, ...(ngDevMode ? [{ debugName: "yes" }] : []));
|
|
1403
|
+
this.no = computed(() => !this.yes(), ...(ngDevMode ? [{ debugName: "no" }] : []));
|
|
1402
1404
|
effect(() => {
|
|
1403
1405
|
const input = this.input();
|
|
1404
1406
|
if (input !== NOTSET) {
|
|
@@ -1415,23 +1417,23 @@ class AbstractUiState {
|
|
|
1415
1417
|
wrap(observable, source) {
|
|
1416
1418
|
return this.state.wrap(observable, this.name, source);
|
|
1417
1419
|
}
|
|
1418
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1419
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
1420
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: AbstractUiState, deps: "invalid", target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1421
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.13", type: AbstractUiState, isStandalone: true, ngImport: i0 }); }
|
|
1420
1422
|
}
|
|
1421
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1423
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: AbstractUiState, decorators: [{
|
|
1422
1424
|
type: Directive
|
|
1423
1425
|
}], ctorParameters: () => [{ type: undefined }] });
|
|
1424
1426
|
|
|
1425
1427
|
class BusyDirective extends AbstractUiState {
|
|
1426
1428
|
constructor() {
|
|
1427
1429
|
super("busy");
|
|
1428
|
-
this.input = input(NOTSET, { alias: "nuBusy" });
|
|
1429
|
-
this.when = input(NOTSET, { alias: "nuBusyWhen" });
|
|
1430
|
+
this.input = input(NOTSET, ...(ngDevMode ? [{ debugName: "input", alias: "nuBusy" }] : [{ alias: "nuBusy" }]));
|
|
1431
|
+
this.when = input(NOTSET, ...(ngDevMode ? [{ debugName: "when", alias: "nuBusyWhen" }] : [{ alias: "nuBusyWhen" }]));
|
|
1430
1432
|
}
|
|
1431
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1432
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
1433
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: BusyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1434
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.13", type: BusyDirective, isStandalone: true, selector: "[nuBusy], [nuBusyWhen]", inputs: { input: { classPropertyName: "input", publicName: "nuBusy", isSignal: true, isRequired: false, transformFunction: null }, when: { classPropertyName: "when", publicName: "nuBusyWhen", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.aria-busy": "yes() ? 'true' : 'false'", "attr.inert": "state.isInert() ? '' : null" } }, providers: [UiState], exportAs: ["busy"], usesInheritance: true, ngImport: i0 }); }
|
|
1433
1435
|
}
|
|
1434
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1436
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: BusyDirective, decorators: [{
|
|
1435
1437
|
type: Directive,
|
|
1436
1438
|
args: [{
|
|
1437
1439
|
selector: "[nuBusy], [nuBusyWhen]",
|
|
@@ -1442,18 +1444,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
|
|
|
1442
1444
|
},
|
|
1443
1445
|
providers: [UiState]
|
|
1444
1446
|
}]
|
|
1445
|
-
}], ctorParameters: () => [] });
|
|
1447
|
+
}], ctorParameters: () => [], propDecorators: { input: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuBusy", required: false }] }], when: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuBusyWhen", required: false }] }] } });
|
|
1446
1448
|
|
|
1447
1449
|
class DirtyDirective extends AbstractUiState {
|
|
1448
1450
|
constructor() {
|
|
1449
1451
|
super("dirty");
|
|
1450
|
-
this.input = input(NOTSET, { alias: "nuDirty" });
|
|
1451
|
-
this.when = input(NOTSET, { alias: "nuDirtyWhen" });
|
|
1452
|
+
this.input = input(NOTSET, ...(ngDevMode ? [{ debugName: "input", alias: "nuDirty" }] : [{ alias: "nuDirty" }]));
|
|
1453
|
+
this.when = input(NOTSET, ...(ngDevMode ? [{ debugName: "when", alias: "nuDirtyWhen" }] : [{ alias: "nuDirtyWhen" }]));
|
|
1452
1454
|
}
|
|
1453
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1454
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
1455
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: DirtyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1456
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.13", type: DirtyDirective, isStandalone: true, selector: "[nuDirty], [nuDirtyWhen]", inputs: { input: { classPropertyName: "input", publicName: "nuDirty", isSignal: true, isRequired: false, transformFunction: null }, when: { classPropertyName: "when", publicName: "nuDirtyWhen", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.dirty": "yes() ? '' : null" } }, providers: [UiState], exportAs: ["dirty"], usesInheritance: true, ngImport: i0 }); }
|
|
1455
1457
|
}
|
|
1456
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1458
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: DirtyDirective, decorators: [{
|
|
1457
1459
|
type: Directive,
|
|
1458
1460
|
args: [{
|
|
1459
1461
|
selector: "[nuDirty], [nuDirtyWhen]",
|
|
@@ -1463,18 +1465,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
|
|
|
1463
1465
|
},
|
|
1464
1466
|
providers: [UiState]
|
|
1465
1467
|
}]
|
|
1466
|
-
}], ctorParameters: () => [] });
|
|
1468
|
+
}], ctorParameters: () => [], propDecorators: { input: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuDirty", required: false }] }], when: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuDirtyWhen", required: false }] }] } });
|
|
1467
1469
|
|
|
1468
1470
|
class DisabledDirective extends AbstractUiState {
|
|
1469
1471
|
constructor() {
|
|
1470
1472
|
super("disabled");
|
|
1471
|
-
this.input = input(NOTSET, { alias: "nuDisabled" });
|
|
1472
|
-
this.when = input(NOTSET, { alias: "nuDisabledWhen" });
|
|
1473
|
+
this.input = input(NOTSET, ...(ngDevMode ? [{ debugName: "input", alias: "nuDisabled" }] : [{ alias: "nuDisabled" }]));
|
|
1474
|
+
this.when = input(NOTSET, ...(ngDevMode ? [{ debugName: "when", alias: "nuDisabledWhen" }] : [{ alias: "nuDisabledWhen" }]));
|
|
1473
1475
|
}
|
|
1474
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1475
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
1476
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: DisabledDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1477
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.13", type: DisabledDirective, isStandalone: true, selector: "[nuDisabled], [nuDisabledWhen]", inputs: { input: { classPropertyName: "input", publicName: "nuDisabled", isSignal: true, isRequired: false, transformFunction: null }, when: { classPropertyName: "when", publicName: "nuDisabledWhen", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.aria-disabled": "yes() ? 'true' : 'false'", "attr.disabled": "yes() ? '' : null", "attr.inert": "state.isInert() ? '' : null" } }, providers: [UiState], exportAs: ["disabled"], usesInheritance: true, ngImport: i0 }); }
|
|
1476
1478
|
}
|
|
1477
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1479
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: DisabledDirective, decorators: [{
|
|
1478
1480
|
type: Directive,
|
|
1479
1481
|
args: [{
|
|
1480
1482
|
selector: "[nuDisabled], [nuDisabledWhen]",
|
|
@@ -1486,18 +1488,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
|
|
|
1486
1488
|
},
|
|
1487
1489
|
providers: [UiState]
|
|
1488
1490
|
}]
|
|
1489
|
-
}], ctorParameters: () => [] });
|
|
1491
|
+
}], ctorParameters: () => [], propDecorators: { input: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuDisabled", required: false }] }], when: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuDisabledWhen", required: false }] }] } });
|
|
1490
1492
|
|
|
1491
1493
|
class ReadonlyDirective extends AbstractUiState {
|
|
1492
1494
|
constructor() {
|
|
1493
1495
|
super("readonly");
|
|
1494
|
-
this.input = input(NOTSET, { alias: "nuReadonly" });
|
|
1495
|
-
this.when = input(NOTSET, { alias: "nuReadonlyWhen" });
|
|
1496
|
+
this.input = input(NOTSET, ...(ngDevMode ? [{ debugName: "input", alias: "nuReadonly" }] : [{ alias: "nuReadonly" }]));
|
|
1497
|
+
this.when = input(NOTSET, ...(ngDevMode ? [{ debugName: "when", alias: "nuReadonlyWhen" }] : [{ alias: "nuReadonlyWhen" }]));
|
|
1496
1498
|
}
|
|
1497
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1498
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
1499
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: ReadonlyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1500
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.13", type: ReadonlyDirective, isStandalone: true, selector: "[nuReadonly], [nuReadonlyWhen]", inputs: { input: { classPropertyName: "input", publicName: "nuReadonly", isSignal: true, isRequired: false, transformFunction: null }, when: { classPropertyName: "when", publicName: "nuReadonlyWhen", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.aria-readonly": "yes() ? 'true' : 'false'", "attr.readonly": "yes() ? '' : null" } }, providers: [UiState], exportAs: ["readonly"], usesInheritance: true, ngImport: i0 }); }
|
|
1499
1501
|
}
|
|
1500
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1502
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: ReadonlyDirective, decorators: [{
|
|
1501
1503
|
type: Directive,
|
|
1502
1504
|
args: [{
|
|
1503
1505
|
selector: "[nuReadonly], [nuReadonlyWhen]",
|
|
@@ -1508,7 +1510,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
|
|
|
1508
1510
|
},
|
|
1509
1511
|
providers: [UiState]
|
|
1510
1512
|
}]
|
|
1511
|
-
}], ctorParameters: () => [] });
|
|
1513
|
+
}], ctorParameters: () => [], propDecorators: { input: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuReadonly", required: false }] }], when: [{ type: i0.Input, args: [{ isSignal: true, alias: "nuReadonlyWhen", required: false }] }] } });
|
|
1512
1514
|
|
|
1513
1515
|
const SEGMENT_REGISTER = { type: "fix", percent: 0 };
|
|
1514
1516
|
const SEGMENT_COMPLETE = { type: "fix", percent: 1 };
|
|
@@ -1607,10 +1609,10 @@ class ProgressState {
|
|
|
1607
1609
|
return res;
|
|
1608
1610
|
}, {});
|
|
1609
1611
|
}
|
|
1610
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1611
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
1612
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: ProgressState, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1613
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.13", type: ProgressState, isStandalone: true, ngImport: i0 }); }
|
|
1612
1614
|
}
|
|
1613
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1615
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: ProgressState, decorators: [{
|
|
1614
1616
|
type: Directive
|
|
1615
1617
|
}] });
|
|
1616
1618
|
class ProgressSegmentRef {
|
|
@@ -1651,11 +1653,11 @@ class ProgressSegmentRef {
|
|
|
1651
1653
|
|
|
1652
1654
|
const entries = [BusyDirective, DirtyDirective, DisabledDirective, ReadonlyDirective];
|
|
1653
1655
|
class UiStateModule {
|
|
1654
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1655
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
1656
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
1656
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: UiStateModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
1657
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.13", ngImport: i0, type: UiStateModule, imports: [BusyDirective, DirtyDirective, DisabledDirective, ReadonlyDirective], exports: [BusyDirective, DirtyDirective, DisabledDirective, ReadonlyDirective] }); }
|
|
1658
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: UiStateModule }); }
|
|
1657
1659
|
}
|
|
1658
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1660
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.13", ngImport: i0, type: UiStateModule, decorators: [{
|
|
1659
1661
|
type: NgModule,
|
|
1660
1662
|
args: [{
|
|
1661
1663
|
imports: entries,
|
|
@@ -1667,5 +1669,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
|
|
|
1667
1669
|
* Generated bundle index. Do not edit.
|
|
1668
1670
|
*/
|
|
1669
1671
|
|
|
1670
|
-
export { AbstractUiState, ActivityService, BusyDirective, DirtyDirective, DisabledDirective, FocusService, FocusState, FocusTrap, Focusable, Gesture, GestureCaptureState, GestureDrag, GestureDragHorizontal, GestureDragImpl, GestureDragVertical, GestureLongTap, GestureLongTapImpl, GesturePhase, GesturePointerType, GestureService, GestureTap, GestureTapImpl, KeystrokeService, Listeners, NOTSET, ProgressSegmentRef, ProgressState, ReadonlyDirective, UiState, UiStateModule, gestureDrag, gestureLongTap, gestureTap };
|
|
1672
|
+
export { AbstractUiState, ActivityService, BusyDirective, DirtyDirective, DisabledDirective, FocusService, FocusState, FocusTrap, Focusable, Gesture, GestureCaptureState, GestureDrag, GestureDragHorizontal, GestureDragImpl, GestureDragVertical, GestureLongTap, GestureLongTapImpl, GesturePhase, GesturePointerType, GestureService, GestureTap, GestureTapImpl, KeystrokeService, Listeners, NOTSET, ProgressSegmentRef, ProgressState, ReadonlyDirective, UiState, UiStateModule, gestureDrag, gestureLongTap, gestureTap, reduceCaptureStates };
|
|
1671
1673
|
//# sourceMappingURL=ngutil-aria.mjs.map
|