ngx-devextreme-zoneless 2.0.0 → 2.1.0
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/README.md +106 -35
- package/fesm2022/ngx-devextreme-zoneless-core.mjs +201 -2
- package/fesm2022/ngx-devextreme-zoneless-core.mjs.map +1 -1
- package/fesm2022/ngx-devextreme-zoneless-data.mjs +13 -7
- package/fesm2022/ngx-devextreme-zoneless-data.mjs.map +1 -1
- package/package.json +1 -1
- package/types/ngx-devextreme-zoneless-core.d.ts +127 -2
- package/types/ngx-devextreme-zoneless-core.d.ts.map +1 -1
- package/types/ngx-devextreme-zoneless-data.d.ts.map +1 -1
package/README.md
CHANGED
|
@@ -28,12 +28,14 @@ Angular signal ◀──set──── widget event (optionChanged, selection
|
|
|
28
28
|
- **DevExtreme / devextreme-angular** ≥ 25.1 (built and verified against 26.1)
|
|
29
29
|
- **TypeScript** 6.0, `strict`, zero `any` in the public surface
|
|
30
30
|
|
|
31
|
-
> **Why this library exists:** DevExpress officially still requires zone.js
|
|
32
|
-
>
|
|
33
|
-
> ETA
|
|
34
|
-
>
|
|
35
|
-
>
|
|
36
|
-
>
|
|
31
|
+
> **Why this library exists:** DevExpress officially still requires zone.js.
|
|
32
|
+
> As of 2026-08-10 DevExpress is *"considering zoneless Angular support for a
|
|
33
|
+
> future release"* (ticket T1328486) — no ETA, and that thread is where an
|
|
34
|
+
> invite to test will be announced if a release is set. Running DevExtreme
|
|
35
|
+
> zoneless is therefore outside the vendor-supported configuration, and this
|
|
36
|
+
> library is the bridge. Its CI (a Playwright suite driving every binding
|
|
37
|
+
> through a real zoneless app on every push) is the compatibility net the
|
|
38
|
+
> vendor does not provide.
|
|
37
39
|
|
|
38
40
|
Everything is *derived from DevExtreme's own `Properties` declarations* via
|
|
39
41
|
template-literal and conditional types — option names, option value types and
|
|
@@ -305,41 +307,110 @@ constructor() {
|
|
|
305
307
|
The target can also be a callback (`dxReloadOn(() => this.grid()?.refresh(), [deps])`)
|
|
306
308
|
for anything that is not a `DataSource`.
|
|
307
309
|
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
`
|
|
310
|
+
## Remote data (`dxRemoteStore`) <sup>developer preview in 2.1</sup>
|
|
311
|
+
|
|
312
|
+
For server-side loading, `dxRemoteStore` wraps a load function in a
|
|
313
|
+
`DataSource` and exposes the loading state the widget cannot show for you,
|
|
314
|
+
using Angular `resource()` vocabulary — no third dialect. This section is
|
|
315
|
+
written from the reference screens in `smoke/src/remote.component.ts`, which
|
|
316
|
+
run in CI against a DevExtreme.AspNet.Data protocol stub
|
|
317
|
+
(`e2e/stub-server.mjs`) including slow- and failing-endpoint cases.
|
|
311
318
|
|
|
312
319
|
```ts
|
|
313
320
|
readonly search = signal('');
|
|
314
|
-
readonly
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
throw error;
|
|
329
|
-
} finally {
|
|
330
|
-
this.isLoading.set(false);
|
|
331
|
-
}
|
|
332
|
-
},
|
|
333
|
-
}),
|
|
321
|
+
readonly status = signal<string | null>(null);
|
|
322
|
+
|
|
323
|
+
readonly orders = dxRemoteStore<Order, number>({
|
|
324
|
+
key: 'id',
|
|
325
|
+
deps: [this.search, this.status], // query state living outside the widget
|
|
326
|
+
debounce: 300, // for keystroke-fed dependency signals
|
|
327
|
+
load: async (options, signal) => {
|
|
328
|
+
// options: DevExtreme LoadOptions (filter/sort/skip/take/…) from the widget;
|
|
329
|
+
// merge your external filter signals and go to the server:
|
|
330
|
+
const filter = combineFilters(options.filter, myExternalFilter());
|
|
331
|
+
const response = await fetch(`/api/orders?${dxLoadOptionsParams({ ...options, filter })}`, { signal });
|
|
332
|
+
if (!response.ok) throw new Error(`orders failed: ${response.status}`);
|
|
333
|
+
return response.json(); // { data, totalCount } — or a plain array
|
|
334
|
+
},
|
|
334
335
|
});
|
|
336
|
+
```
|
|
335
337
|
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
}
|
|
338
|
+
```html
|
|
339
|
+
<dx-data-grid [dataSource]="orders.dataSource" [remoteOperations]="true">…</dx-data-grid>
|
|
340
|
+
@if (orders.isLoading()) { <app-spinner /> }
|
|
341
|
+
@if (orders.error(); as error) { <button (click)="orders.reload()">retry</button> }
|
|
342
|
+
```
|
|
343
|
+
|
|
344
|
+
`dxLoadOptionsParams` serializes `LoadOptions` into the exact query-string
|
|
345
|
+
format DevExtreme.AspNet.Data server libraries parse (JSON-encoded
|
|
346
|
+
`filter`/`sort`/`group`/`select`/summaries, plain `skip`/`take`/
|
|
347
|
+
`requireTotalCount`/`requireGroupCount`) — the same wire format the vendor's
|
|
348
|
+
`createStore({ loadUrl })` produces, but through your own `fetch`, so auth
|
|
349
|
+
headers, interceptors and `AbortSignal` stay in your hands.
|
|
350
|
+
|
|
351
|
+
**The contract**, aligned with `resource()` and verified by e2e:
|
|
352
|
+
|
|
353
|
+
- **Cancellation, last write wins.** Every load receives an `AbortSignal`. A
|
|
354
|
+
reload — dependency-driven or manual — aborts whatever is in flight;
|
|
355
|
+
superseded loads never overwrite newer results, never surface stale errors,
|
|
356
|
+
and never trigger the widget's load-error UI.
|
|
357
|
+
- **`error` + retry.** `error` holds the rejection of the most recent settled
|
|
358
|
+
load and is cleared by the next successful one; `reload()` is the retry.
|
|
359
|
+
The widget additionally shows its own load-error row — `error` is for UI
|
|
360
|
+
outside the widget.
|
|
361
|
+
- **Page ownership.** A dependency change is a new query, so the store resets
|
|
362
|
+
to page 0 (mirroring `DataSource.filter()` semantics). Manual `reload()`
|
|
363
|
+
refetches the same query and keeps the page. You never manage `pageIndex`
|
|
364
|
+
yourself — and a bound `[(dxPageIndex)]` signal follows both cases.
|
|
365
|
+
- **Debounce ownership.** The `debounce` option applies to dependency-driven
|
|
366
|
+
reloads only (type-ahead filter signals). Widget-driven search (a lookup's
|
|
367
|
+
`searchTimeout`) is already debounced by the widget — don't stack a second
|
|
368
|
+
debounce on the same keystrokes.
|
|
369
|
+
- **Search folds into `filter`.** Widget search options are merged into
|
|
370
|
+
`LoadOptions.filter` before `load` runs (vendor-parity `useDefaultSearch`),
|
|
371
|
+
so your load function only ever deals in filter expressions.
|
|
372
|
+
|
|
373
|
+
**Dependent queries** — a master grid's selection signal drives the detail
|
|
374
|
+
store; return an empty result to skip the request entirely:
|
|
375
|
+
|
|
376
|
+
```ts
|
|
377
|
+
readonly detailOrders = dxRemoteStore<Order, number>({
|
|
378
|
+
key: 'id',
|
|
379
|
+
deps: [this.selectedCustomerId],
|
|
380
|
+
load: async (options, signal) => {
|
|
381
|
+
const customerId = untracked(this.selectedCustomerId);
|
|
382
|
+
if (customerId === undefined) return { data: [], totalCount: 0 };
|
|
383
|
+
const filter = combineFilters(options.filter, ['customerId', '=', customerId]);
|
|
384
|
+
return fetchJson(`/api/orders?${dxLoadOptionsParams({ ...options, filter })}`, signal);
|
|
385
|
+
},
|
|
386
|
+
});
|
|
387
|
+
```
|
|
388
|
+
|
|
389
|
+
**Lookup editors need `byKey`** — a select box showing a programmatically set
|
|
390
|
+
value must resolve the item behind the key before any page is loaded. Against
|
|
391
|
+
a loadOptions endpoint, `byKey` is a filtered load:
|
|
392
|
+
|
|
393
|
+
```ts
|
|
394
|
+
readonly customerLookup = dxRemoteStore<Customer, number>({
|
|
395
|
+
key: 'id',
|
|
396
|
+
load: (options, signal) =>
|
|
397
|
+
fetchJson(`/api/customers?${dxLoadOptionsParams(options)}`, signal),
|
|
398
|
+
byKey: async (key, signal) => {
|
|
399
|
+
const params = dxLoadOptionsParams({ filter: ['id', '=', key], take: 1 });
|
|
400
|
+
const result = await fetchJson<{ data: Customer[] }>(`/api/customers?${params}`, signal);
|
|
401
|
+
if (result.data[0] === undefined) throw new Error(`customer ${key} not found`);
|
|
402
|
+
return result.data[0];
|
|
403
|
+
},
|
|
404
|
+
});
|
|
339
405
|
```
|
|
340
406
|
|
|
341
|
-
|
|
342
|
-
|
|
407
|
+
**Scope: load-only, by design.** Create/update/delete deliberately stay out
|
|
408
|
+
of this first cut — editing flows couple to validation, conflict handling and
|
|
409
|
+
optimistic-update policy that this package should not decide for you. For
|
|
410
|
+
editable grids, hand the widget a full `CustomStore` (or the vendor's
|
|
411
|
+
`createStore` with `insertUrl`/`updateUrl`/`deleteUrl`) and keep
|
|
412
|
+
`dxRemoteStore` for the read paths. If real consumer screens produce a shape
|
|
413
|
+
worth hardening, CRUD can graduate the same way this API did.
|
|
343
414
|
|
|
344
415
|
## Semantics
|
|
345
416
|
|
|
@@ -381,7 +452,7 @@ The package ships per-family secondary entry points:
|
|
|
381
452
|
|
|
382
453
|
```
|
|
383
454
|
ngx-devextreme-zoneless → everything (re-exports the below)
|
|
384
|
-
ngx-devextreme-zoneless/core → engine, types, bases, data-source helpers
|
|
455
|
+
ngx-devextreme-zoneless/core → engine, types, bases, data-source/remote helpers
|
|
385
456
|
ngx-devextreme-zoneless/editors → [(dxValue)] directives
|
|
386
457
|
ngx-devextreme-zoneless/navigation → [(dxSelectedIndex)], [(dxOpened)], …
|
|
387
458
|
ngx-devextreme-zoneless/overlays → [(dxVisible)] directives
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { assertInInjectionContext, inject, Injector, DestroyRef, afterNextRender, effect, untracked, signal, Directive, model, input } from '@angular/core';
|
|
2
|
+
import { assertInInjectionContext, inject, Injector, DestroyRef, afterNextRender, effect, untracked, signal, computed, Directive, model, input } from '@angular/core';
|
|
3
3
|
import CustomStore from 'devextreme/data/custom_store';
|
|
4
4
|
import DataSource from 'devextreme/data/data_source';
|
|
5
5
|
|
|
@@ -478,6 +478,205 @@ function dxReloadOn(target, dependencies, injector) {
|
|
|
478
478
|
}, { injector: resolvedInjector });
|
|
479
479
|
}
|
|
480
480
|
|
|
481
|
+
/**
|
|
482
|
+
* Wraps a remote load function in a DevExtreme `DataSource` with signal-based
|
|
483
|
+
* loading state:
|
|
484
|
+
*
|
|
485
|
+
* ```ts
|
|
486
|
+
* readonly search = signal('');
|
|
487
|
+
* readonly orders = dxRemoteStore<Order, number>({
|
|
488
|
+
* key: 'id',
|
|
489
|
+
* deps: [this.search],
|
|
490
|
+
* debounce: 300,
|
|
491
|
+
* load: async (options, signal) => {
|
|
492
|
+
* const params = dxLoadOptionsParams(options);
|
|
493
|
+
* params.set('search', untracked(this.search));
|
|
494
|
+
* const response = await fetch(`/api/orders?${params}`, { signal });
|
|
495
|
+
* if (!response.ok) throw new Error(`orders load failed: ${response.status}`);
|
|
496
|
+
* return response.json();
|
|
497
|
+
* },
|
|
498
|
+
* });
|
|
499
|
+
* // <dx-data-grid [dataSource]="orders.dataSource" [remoteOperations]="true" />
|
|
500
|
+
* // @if (orders.error()) { <button (click)="orders.reload()">retry</button> }
|
|
501
|
+
* ```
|
|
502
|
+
*
|
|
503
|
+
* Semantics, aligned with Angular's `resource()`:
|
|
504
|
+
* - every load gets an `AbortSignal`; a reload (dependency-driven or manual)
|
|
505
|
+
* aborts whatever is still in flight — last write wins, stale responses
|
|
506
|
+
* never overwrite newer ones and never surface stale errors;
|
|
507
|
+
* - `error` reflects the most recent settled load and is cleared by the next
|
|
508
|
+
* successful one; `reload()` is the retry;
|
|
509
|
+
* - dependency changes reset to page 0 (a new query is a new result set);
|
|
510
|
+
* manual `reload()` keeps the page (same query, fresh data);
|
|
511
|
+
* - widget search options are folded into `LoadOptions.filter` before `load`
|
|
512
|
+
* runs (`useDefaultSearch`, matching the vendor's own remote client), so
|
|
513
|
+
* the load function only ever deals in filter expressions.
|
|
514
|
+
*
|
|
515
|
+
* The store is load-only by design: create/update/delete intentionally stay
|
|
516
|
+
* out of this API — pass a full `CustomStore` to the widget where you need
|
|
517
|
+
* editing.
|
|
518
|
+
*/
|
|
519
|
+
function dxRemoteStore(options) {
|
|
520
|
+
if (options.injector === undefined) {
|
|
521
|
+
assertInInjectionContext(dxRemoteStore);
|
|
522
|
+
}
|
|
523
|
+
const injector = options.injector ?? inject(Injector);
|
|
524
|
+
const pendingCount = signal(0, /* @ts-ignore */
|
|
525
|
+
...(ngDevMode ? [{ debugName: "pendingCount" }] : /* istanbul ignore next */ []));
|
|
526
|
+
const lastError = signal(undefined, /* @ts-ignore */
|
|
527
|
+
...(ngDevMode ? [{ debugName: "lastError" }] : /* istanbul ignore next */ []));
|
|
528
|
+
let loadSequence = 0;
|
|
529
|
+
const inFlight = new Set();
|
|
530
|
+
const trackedLoad = (loadOptions) => {
|
|
531
|
+
const sequence = ++loadSequence;
|
|
532
|
+
const controller = new AbortController();
|
|
533
|
+
inFlight.add(controller);
|
|
534
|
+
pendingCount.update((count) => count + 1);
|
|
535
|
+
const settle = () => {
|
|
536
|
+
inFlight.delete(controller);
|
|
537
|
+
pendingCount.update((count) => count - 1);
|
|
538
|
+
};
|
|
539
|
+
return Promise.resolve(options.load(loadOptions, controller.signal)).then((result) => {
|
|
540
|
+
settle();
|
|
541
|
+
if (sequence === loadSequence) {
|
|
542
|
+
lastError.set(undefined);
|
|
543
|
+
}
|
|
544
|
+
return result;
|
|
545
|
+
}, (reason) => {
|
|
546
|
+
settle();
|
|
547
|
+
if (controller.signal.aborted) {
|
|
548
|
+
// Superseded load: reject with DevExtreme's own
|
|
549
|
+
// cancellation token (the literal `'canceled'`), which the
|
|
550
|
+
// DataSource recognizes and drops without firing
|
|
551
|
+
// `loadError` — the widget never flashes its error UI for
|
|
552
|
+
// a load this store aborted on purpose.
|
|
553
|
+
throw 'canceled';
|
|
554
|
+
}
|
|
555
|
+
if (sequence === loadSequence) {
|
|
556
|
+
lastError.set(reason);
|
|
557
|
+
}
|
|
558
|
+
throw reason;
|
|
559
|
+
});
|
|
560
|
+
};
|
|
561
|
+
const userByKey = options.byKey;
|
|
562
|
+
const trackedByKey = userByKey === undefined
|
|
563
|
+
? undefined
|
|
564
|
+
: (key) => {
|
|
565
|
+
const controller = new AbortController();
|
|
566
|
+
inFlight.add(controller);
|
|
567
|
+
return Promise.resolve(userByKey(key, controller.signal)).finally(() => inFlight.delete(controller));
|
|
568
|
+
};
|
|
569
|
+
const dataSource = new DataSource({
|
|
570
|
+
store: new CustomStore({
|
|
571
|
+
key: options.key,
|
|
572
|
+
loadMode: 'processed',
|
|
573
|
+
useDefaultSearch: true,
|
|
574
|
+
load: trackedLoad,
|
|
575
|
+
byKey: trackedByKey,
|
|
576
|
+
}),
|
|
577
|
+
});
|
|
578
|
+
const abortInFlight = () => {
|
|
579
|
+
for (const controller of inFlight) {
|
|
580
|
+
controller.abort();
|
|
581
|
+
}
|
|
582
|
+
};
|
|
583
|
+
const reload = () => {
|
|
584
|
+
// Abort in-flight transport before starting over — the aborted loads
|
|
585
|
+
// reject as `'canceled'` (see trackedLoad), which DevExtreme drops
|
|
586
|
+
// silently. Deliberately NOT `dataSource.cancelAll()`: that method
|
|
587
|
+
// resets the internal operation-id counter, and the id reuse makes
|
|
588
|
+
// grid adapters discard the results of every subsequent load.
|
|
589
|
+
abortInFlight();
|
|
590
|
+
return Promise.resolve(dataSource.reload()).then(() => undefined, () => undefined);
|
|
591
|
+
};
|
|
592
|
+
const deps = options.deps ?? [];
|
|
593
|
+
let debounceTimer;
|
|
594
|
+
if (deps.length > 0) {
|
|
595
|
+
const debounceMs = options.debounce ?? 0;
|
|
596
|
+
const run = () => {
|
|
597
|
+
debounceTimer = undefined;
|
|
598
|
+
dataSource.pageIndex(0);
|
|
599
|
+
void reload();
|
|
600
|
+
};
|
|
601
|
+
let first = true;
|
|
602
|
+
effect(() => {
|
|
603
|
+
for (const dependency of deps) {
|
|
604
|
+
dependency();
|
|
605
|
+
}
|
|
606
|
+
if (first) {
|
|
607
|
+
first = false;
|
|
608
|
+
return;
|
|
609
|
+
}
|
|
610
|
+
if (debounceTimer !== undefined) {
|
|
611
|
+
clearTimeout(debounceTimer);
|
|
612
|
+
}
|
|
613
|
+
if (debounceMs > 0) {
|
|
614
|
+
debounceTimer = setTimeout(run, debounceMs);
|
|
615
|
+
}
|
|
616
|
+
else {
|
|
617
|
+
untracked(run);
|
|
618
|
+
}
|
|
619
|
+
}, { injector });
|
|
620
|
+
}
|
|
621
|
+
injector.get(DestroyRef).onDestroy(() => {
|
|
622
|
+
if (debounceTimer !== undefined) {
|
|
623
|
+
clearTimeout(debounceTimer);
|
|
624
|
+
}
|
|
625
|
+
abortInFlight();
|
|
626
|
+
dataSource.dispose();
|
|
627
|
+
});
|
|
628
|
+
return {
|
|
629
|
+
dataSource,
|
|
630
|
+
isLoading: computed(() => pendingCount() > 0),
|
|
631
|
+
error: lastError.asReadonly(),
|
|
632
|
+
reload,
|
|
633
|
+
};
|
|
634
|
+
}
|
|
635
|
+
function normalizeSorting(value) {
|
|
636
|
+
const list = Array.isArray(value) ? value : [value];
|
|
637
|
+
return list.map((entry) => {
|
|
638
|
+
if (typeof entry === 'object' && entry !== null && 'selector' in entry) {
|
|
639
|
+
return entry;
|
|
640
|
+
}
|
|
641
|
+
return { selector: entry, desc: false };
|
|
642
|
+
});
|
|
643
|
+
}
|
|
644
|
+
/**
|
|
645
|
+
* Serializes `LoadOptions` into the query parameters understood by the
|
|
646
|
+
* DevExtreme.AspNet.Data server libraries — the same wire format the
|
|
647
|
+
* vendor's own `createStore({ loadUrl })` client produces: structured
|
|
648
|
+
* options JSON-encoded (`filter`, `sort`, `group`, `select`, `totalSummary`,
|
|
649
|
+
* `groupSummary`, with string `sort`/`group` entries normalized to
|
|
650
|
+
* `{ selector }` objects), scalars plain (`skip`, `take`,
|
|
651
|
+
* `requireTotalCount`, `requireGroupCount`).
|
|
652
|
+
*
|
|
653
|
+
* ```ts
|
|
654
|
+
* const response = await fetch(`/api/orders?${dxLoadOptionsParams(options)}`, { signal });
|
|
655
|
+
* ```
|
|
656
|
+
*/
|
|
657
|
+
function dxLoadOptionsParams(loadOptions) {
|
|
658
|
+
const params = new URLSearchParams();
|
|
659
|
+
for (const key of ['skip', 'take', 'requireTotalCount', 'requireGroupCount']) {
|
|
660
|
+
const value = loadOptions[key];
|
|
661
|
+
if (value !== undefined && value !== null) {
|
|
662
|
+
params.set(key, String(value));
|
|
663
|
+
}
|
|
664
|
+
}
|
|
665
|
+
for (const key of ['filter', 'select', 'totalSummary', 'groupSummary']) {
|
|
666
|
+
const value = loadOptions[key];
|
|
667
|
+
if (value !== undefined && value !== null) {
|
|
668
|
+
params.set(key, JSON.stringify(value));
|
|
669
|
+
}
|
|
670
|
+
}
|
|
671
|
+
for (const key of ['sort', 'group']) {
|
|
672
|
+
const value = loadOptions[key];
|
|
673
|
+
if (value !== undefined && value !== null) {
|
|
674
|
+
params.set(key, JSON.stringify(normalizeSorting(value)));
|
|
675
|
+
}
|
|
676
|
+
}
|
|
677
|
+
return params;
|
|
678
|
+
}
|
|
679
|
+
|
|
481
680
|
/**
|
|
482
681
|
* Abstract base directives for the concrete per-component adapter directives.
|
|
483
682
|
*
|
|
@@ -593,5 +792,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.1", ngImpor
|
|
|
593
792
|
* Generated bundle index. Do not edit.
|
|
594
793
|
*/
|
|
595
794
|
|
|
596
|
-
export { DxBindingDirectiveBase, DxSelectedIndexDirectiveBase, DxSelectedItemKeysDirectiveBase, DxSelectedRowKeysDirectiveBase, DxValueDirectiveBase, DxVisibleDirectiveBase, bindDxOption, bindDxState, dxArrayStoreSource, dxEventSignal, dxInstanceSignal, dxOptionAdapter, dxOptionSignal, dxReloadOn, dxShallowObjectEquals, dxStructuralEquals, injectDxInstance, onDxWidgetReady };
|
|
795
|
+
export { DxBindingDirectiveBase, DxSelectedIndexDirectiveBase, DxSelectedItemKeysDirectiveBase, DxSelectedRowKeysDirectiveBase, DxValueDirectiveBase, DxVisibleDirectiveBase, bindDxOption, bindDxState, dxArrayStoreSource, dxEventSignal, dxInstanceSignal, dxLoadOptionsParams, dxOptionAdapter, dxOptionSignal, dxReloadOn, dxRemoteStore, dxShallowObjectEquals, dxStructuralEquals, injectDxInstance, onDxWidgetReady };
|
|
597
796
|
//# sourceMappingURL=ngx-devextreme-zoneless-core.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-devextreme-zoneless-core.mjs","sources":["../../core/src/lib/equality.ts","../../core/src/lib/ready.ts","../../core/src/lib/binding.ts","../../core/src/lib/signals.ts","../../core/src/lib/data-source.ts","../../core/src/lib/bases.ts","../../core/src/public-api.ts","../../core/src/ngx-devextreme-zoneless-core.ts"],"sourcesContent":["/**\n * Structural equality used to break the two-way binding echo cycle\n * (signal → widget → `optionChanged` → signal → ...).\n *\n * DevExtreme frequently emits *new* array/object references for unchanged\n * data (e.g. `selectedRowKeys`), so reference equality alone would loop.\n */\n\n/** Custom equality comparer for a bound value. */\nexport type DxEqualityFn<in T> = (a: T, b: T) => boolean;\n\n/**\n * Deep structural equality with special handling for `Date` and arrays.\n * Plain objects are compared by their own enumerable keys; class instances\n * (anything with a custom prototype) fall back to reference equality.\n */\nexport function dxStructuralEquals(a: unknown, b: unknown): boolean {\n if (Object.is(a, b)) {\n return true;\n }\n if (a instanceof Date || b instanceof Date) {\n return (\n a instanceof Date && b instanceof Date && a.getTime() === b.getTime()\n );\n }\n if (Array.isArray(a) || Array.isArray(b)) {\n return (\n Array.isArray(a) &&\n Array.isArray(b) &&\n a.length === b.length &&\n a.every((item, index) => dxStructuralEquals(item, b[index]))\n );\n }\n if (isPlainObject(a) && isPlainObject(b)) {\n const aKeys = Object.keys(a);\n const bKeys = Object.keys(b);\n return (\n aKeys.length === bKeys.length &&\n aKeys.every(\n (key) =>\n Object.prototype.hasOwnProperty.call(b, key) &&\n dxStructuralEquals(a[key], b[key]),\n )\n );\n }\n return false;\n}\n\n/** Shallow equality over the own enumerable keys of two plain objects. */\nexport function dxShallowObjectEquals(a: unknown, b: unknown): boolean {\n if (Object.is(a, b)) {\n return true;\n }\n if (!isPlainObject(a) || !isPlainObject(b)) {\n return false;\n }\n const aKeys = Object.keys(a);\n const bKeys = Object.keys(b);\n return (\n aKeys.length === bKeys.length &&\n aKeys.every(\n (key) =>\n Object.prototype.hasOwnProperty.call(b, key) &&\n Object.is(a[key], b[key]),\n )\n );\n}\n\nfunction isPlainObject(value: unknown): value is Record<string, unknown> {\n if (typeof value !== 'object' || value === null) {\n return false;\n }\n const proto: unknown = Object.getPrototypeOf(value);\n return proto === Object.prototype || proto === null;\n}\n","import {\n afterNextRender,\n assertInInjectionContext,\n DestroyRef,\n effect,\n inject,\n Injector,\n untracked,\n} from '@angular/core';\nimport type {\n DxHostComponent,\n DxHostRef,\n DxInitializedArgs,\n DxInstanceOf,\n DxWidget,\n} from './types';\n\n/** Cleanup returned by an {@link onDxWidgetReady} callback; runs when the widget goes away. */\nexport type DxWidgetReadyCleanup = () => void;\n\n/**\n * Invokes `callback` as soon as the DevExtreme widget behind a\n * devextreme-angular host component exists — once *per widget instance*:\n *\n * - For a direct host reference the callback fires exactly once (the widget\n * dies with the host component and its element).\n * - For a lazily-provided host (a `viewChild(...)` signal or any getter) the\n * getter is watched for the whole injector lifetime: when the host is\n * destroyed and a new one appears (`@if`, tab panels, re-created popup\n * content, ...), the previous attach is disposed and the callback fires\n * again for the new widget.\n *\n * The callback may return a cleanup function; it runs when the widget goes\n * away — on host re-creation as well as on injector destruction. Errors\n * thrown by cleanups are swallowed, since the widget is routinely already\n * disposed when they run.\n *\n * Handles all timing subtleties:\n * - devextreme-angular creates the widget in `ngAfterViewInit`, long after\n * directives on the same element are constructed;\n * - the `onInitialized` event fires *during* widget construction, before the\n * wrapper's `instance` property is assigned — the widget is therefore taken\n * from the event payload;\n * - `afterNextRender` covers hosts whose widget already exists (late-resolved\n * view children).\n *\n * Must be called in an injection context unless an `injector` is provided.\n * All pending work is disposed automatically when the injector is destroyed.\n */\nexport function onDxWidgetReady<THost extends DxHostComponent>(\n hostRef: DxHostRef<THost>,\n callback: (\n instance: DxInstanceOf<THost> & DxWidget,\n host: THost,\n ) => void | DxWidgetReadyCleanup,\n injector?: Injector,\n): void {\n if (injector === undefined) {\n assertInInjectionContext(onDxWidgetReady);\n }\n const resolvedInjector = injector ?? inject(Injector);\n\n type TInstance = DxInstanceOf<THost> & DxWidget;\n\n /** Disposal scope of the current attach; replaced on host re-creation. */\n let scope: DxWidgetReadyCleanup[] | undefined;\n let destroyed = false;\n\n const detach = (): void => {\n const cleanups = scope;\n scope = undefined;\n if (cleanups === undefined) {\n return;\n }\n for (let i = cleanups.length - 1; i >= 0; i--) {\n try {\n cleanups[i]?.();\n } catch {\n // The widget is routinely already disposed at this point.\n }\n }\n };\n resolvedInjector.get(DestroyRef).onDestroy(() => {\n destroyed = true;\n detach();\n });\n\n const attach = (host: THost): void => {\n const cleanups: DxWidgetReadyCleanup[] = [];\n scope = cleanups;\n let done = false;\n\n const complete = (instance: TInstance | undefined | null): void => {\n // The scope check drops stale completions (afterNextRender or a\n // late `onInitialized`) that race a detach.\n if (done || destroyed || scope !== cleanups || instance === undefined || instance === null) {\n return;\n }\n done = true;\n const cleanup = callback(instance, host);\n if (typeof cleanup === 'function') {\n cleanups.push(cleanup);\n }\n };\n\n const subscription = host.onInitialized.subscribe((event) => {\n // `host.instance` is not assigned yet at this point — use the\n // widget carried by the event payload.\n const args = event as DxInitializedArgs<DxWidget>;\n complete((args.component ?? host.instance) as TInstance);\n });\n cleanups.push(() => subscription.unsubscribe());\n // Fallback for hosts whose widget already exists (e.g. late-resolved\n // view children) or whose `initialized` event was missed.\n afterNextRender(\n { read: () => complete(host.instance as TInstance) },\n { injector: resolvedInjector },\n );\n };\n\n if (typeof hostRef !== 'function') {\n attach(hostRef);\n return;\n }\n\n // Lazy host (viewChild signal or arbitrary getter): watch for the whole\n // injector lifetime. A change of host identity means the widget was\n // destroyed and re-created — dispose the previous attach and re-attach.\n let currentHost: THost | undefined;\n effect(\n () => {\n const host = hostRef() ?? undefined;\n if (host === currentHost) {\n return;\n }\n currentHost = host;\n untracked(() => {\n detach();\n if (host !== undefined) {\n attach(host);\n }\n });\n },\n { injector: resolvedInjector },\n );\n}\n","import {\n assertInInjectionContext,\n effect,\n inject,\n Injector,\n untracked,\n type WritableSignal,\n} from '@angular/core';\nimport { dxStructuralEquals, type DxEqualityFn } from './equality';\nimport { onDxWidgetReady } from './ready';\nimport type {\n DxEventName,\n DxHostComponent,\n DxHostOptionName,\n DxHostOptionValue,\n DxHostRef,\n DxInstanceOf,\n DxOptionChangedArgs,\n DxPropertiesOf,\n DxWidget,\n} from './types';\n\n/** The event names of a widget *instance*, derived from its `Properties` bag. */\nexport type DxAdapterEventName<TInstance> = DxEventName<DxPropertiesOf<TInstance>>;\n\n/**\n * Describes how a bound value is read from / written to a widget and which\n * widget events indicate that it may have changed outside Angular.\n *\n * `bindDxOption` provides the standard option-based adapter; custom adapters\n * cover method-based state such as chart point selection or tree-view\n * selection.\n */\nexport interface DxBindingAdapter<TInstance extends DxWidget, TValue> {\n /**\n * Widget events (`'optionChanged'`, `'selectionChanged'`, ...) that may\n * affect the bound value. Names are checked against the widget's\n * `Properties` declaration — a typo or an event a DevExtreme upgrade\n * renamed is a compile error.\n */\n readonly events: readonly DxAdapterEventName<TInstance>[];\n /** Reads the current value from the widget. */\n read(instance: TInstance): TValue;\n /** Writes a new value to the widget. */\n write(instance: TInstance, value: TValue): void;\n /** Optional filter deciding whether a received event affects this binding. */\n accept?(eventName: DxAdapterEventName<TInstance>, eventArgs: unknown): boolean;\n}\n\n/** Which side wins the initial synchronization when the binding attaches. */\nexport type DxInitialSync =\n /** Push the signal's current value into the widget (unless it is `undefined`). */\n | 'signal'\n /** Pull the widget's current value into the signal. */\n | 'widget'\n /** Push if the signal holds a value other than `undefined`, otherwise pull. */\n | 'auto';\n\n/** Tuning options for a two-way binding. */\nexport interface DxBindingOptions<TValue> {\n /** Equality used to suppress echo updates. Defaults to {@link dxStructuralEquals}. */\n readonly equal?: DxEqualityFn<NoInfer<TValue>>;\n /**\n * Debounce (milliseconds) applied to the widget → signal direction, e.g.\n * to tame per-keystroke `valueChanged` events. May be reactive.\n * A read still pending when the binding is torn down is dropped — the\n * signal keeps the last applied value.\n */\n readonly debounceMs?: number | (() => number);\n /** Initial synchronization strategy. Defaults to `'auto'`. */\n readonly initialSync?: DxInitialSync;\n /** Explicit injector when called outside an injection context. */\n readonly injector?: Injector;\n}\n\n/**\n * Wires a writable signal to widget state described by an adapter, in both\n * directions, with echo suppression and automatic teardown on destroy.\n *\n * - widget → signal: adapter events trigger a (optionally debounced) read;\n * the signal is only written when the value structurally changed. Because\n * the write is a plain signal write, zoneless change detection is scheduled\n * without any `NgZone` involvement.\n * - signal → widget: an `effect` pushes changes into the widget, again only\n * when the value actually differs.\n *\n * When `hostRef` is a getter (e.g. a `viewChild(...)` signal) the binding\n * survives widget re-creation: if the host component is destroyed and a new\n * one appears, the binding re-attaches and the initial synchronization runs\n * again — a signal holding state therefore restores it into the new widget.\n */\nexport function bindDxState<THost extends DxHostComponent, TValue>(\n hostRef: DxHostRef<THost>,\n source: WritableSignal<TValue>,\n adapter: DxBindingAdapter<DxInstanceOf<THost>, TValue>,\n options: DxBindingOptions<TValue> = {},\n): void {\n if (options.injector === undefined) {\n assertInInjectionContext(bindDxState);\n }\n const injector = options.injector ?? inject(Injector);\n const equal = options.equal ?? (dxStructuralEquals as DxEqualityFn<TValue>);\n const debounceMs =\n typeof options.debounceMs === 'function'\n ? options.debounceMs\n : (): number => (options.debounceMs as number | undefined) ?? 0;\n const initialSync = options.initialSync ?? 'auto';\n\n /**\n * Re-entrancy latch. Both directions run synchronous DevExtreme code that\n * may fire events inline; the latch prevents those from re-entering the\n * binding while structural equality handles the asynchronous echo path.\n */\n let syncing = false;\n let debounceTimer: ReturnType<typeof setTimeout> | undefined;\n\n const guarded = (work: () => void): void => {\n syncing = true;\n try {\n work();\n } finally {\n syncing = false;\n }\n };\n\n onDxWidgetReady(\n hostRef,\n (instance) => {\n // --- initial synchronization -------------------------------------\n const initial = untracked(source);\n const pushInitial =\n initialSync === 'signal' ||\n (initialSync === 'auto' && initial !== undefined);\n if (pushInitial) {\n if (initial !== undefined && !equal(adapter.read(instance), initial)) {\n guarded(() => adapter.write(instance, initial));\n }\n } else {\n const widgetValue = adapter.read(instance);\n if (!equal(initial, widgetValue)) {\n guarded(() => source.set(widgetValue));\n }\n }\n\n // --- widget → signal ----------------------------------------------\n const applyFromWidget = (): void => {\n const value = adapter.read(instance);\n if (!equal(untracked(source), value)) {\n guarded(() => source.set(value));\n }\n };\n const detachers: (() => void)[] = [];\n for (const eventName of adapter.events) {\n const handler = (eventArgs: unknown): void => {\n if (syncing) {\n return;\n }\n if (adapter.accept !== undefined && !adapter.accept(eventName, eventArgs)) {\n return;\n }\n const wait = debounceMs();\n if (wait > 0) {\n if (debounceTimer !== undefined) {\n clearTimeout(debounceTimer);\n }\n debounceTimer = setTimeout(applyFromWidget, wait);\n } else {\n applyFromWidget();\n }\n };\n instance.on(eventName, handler);\n detachers.push(() => instance.off(eventName, handler));\n }\n\n // --- signal → widget ----------------------------------------------\n const pusher = effect(\n () => {\n const value = source();\n if (syncing || value === undefined) {\n return;\n }\n untracked(() => {\n if (!equal(adapter.read(instance), value)) {\n guarded(() => adapter.write(instance, value));\n }\n });\n },\n { injector },\n );\n detachers.push(() => pusher.destroy());\n\n return () => {\n // A pending debounced read must not fire into a dead widget.\n // Its trailing value is deliberately dropped — the signal\n // still holds the last applied state.\n if (debounceTimer !== undefined) {\n clearTimeout(debounceTimer);\n debounceTimer = undefined;\n }\n for (let i = detachers.length - 1; i >= 0; i--) {\n detachers[i]?.();\n }\n };\n },\n injector,\n );\n}\n\n/**\n * The standard adapter: binds a signal to a single widget *option*, listening\n * to `optionChanged` filtered by option name. Nested changes\n * (`fullName: 'formData.firstName'`) are matched via their root name.\n */\nexport function dxOptionAdapter<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n TValue,\n>(optionName: TName): DxBindingAdapter<DxInstanceOf<THost>, TValue> {\n return {\n // Every DevExtreme widget declares `onOptionChanged`; the cast is\n // only needed because `THost` is an unresolved type parameter here.\n events: ['optionChanged'] as unknown as readonly DxAdapterEventName<\n DxInstanceOf<THost>\n >[],\n read: (instance) => instance.option(optionName) as TValue,\n write: (instance, value) => {\n (instance.option as (name: string, value: unknown) => void)(optionName, value);\n },\n accept: (_eventName, eventArgs) => {\n const args = eventArgs as DxOptionChangedArgs;\n return args.name === optionName || args.fullName === optionName;\n },\n };\n}\n\n/**\n * Two-way binds a writable signal to a widget option — the strongly-typed\n * workhorse behind all option-based directives of this library, and directly\n * usable for any option of any DevExtreme component:\n *\n * ```ts\n * const grid = viewChild(DxDataGridComponent<Order, number>);\n * readonly keys = signal<number[]>([]);\n * constructor() {\n * bindDxOption(this.grid, 'selectedRowKeys', this.keys);\n * }\n * ```\n */\nexport function bindDxOption<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n TValue extends DxHostOptionValue<THost, TName> | undefined,\n>(\n hostRef: DxHostRef<THost>,\n optionName: TName,\n source: WritableSignal<TValue>,\n options?: DxBindingOptions<TValue>,\n): void {\n bindDxState(hostRef, source, dxOptionAdapter<THost, TName, TValue>(optionName), options);\n}\n","import {\n assertInInjectionContext,\n inject,\n Injector,\n signal,\n type ProviderToken,\n type Signal,\n type WritableSignal,\n} from '@angular/core';\nimport { bindDxOption, type DxBindingOptions } from './binding';\nimport { onDxWidgetReady } from './ready';\nimport type {\n DxHostComponent,\n DxHostEventArg,\n DxHostEventName,\n DxHostOptionName,\n DxHostOptionValue,\n DxHostRef,\n DxInstanceOf,\n} from './types';\n\n/** Options for {@link dxOptionSignal}. */\nexport interface DxOptionSignalOptions<TValue> extends DxBindingOptions<TValue> {\n /**\n * Value the signal holds until the widget is ready. When provided, the\n * signal is also pushed into the widget on attach; without it, the\n * widget's current option value is pulled into the signal instead.\n */\n readonly initialValue?: TValue;\n}\n\n/**\n * Creates a writable signal that is two-way bound to a widget option — the\n * universal escape hatch that works with *every* option of *every*\n * devextreme-angular component, fully typed from DevExtreme's `Properties`:\n *\n * ```ts\n * private readonly textBox = inject(DxTextBoxComponent, { self: true });\n * readonly placeholder = dxOptionSignal(this.textBox, 'placeholder');\n * readonly mode = dxOptionSignal(this.textBox, 'mode', { initialValue: 'search' });\n * ```\n */\nexport function dxOptionSignal<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n>(\n hostRef: DxHostRef<THost>,\n optionName: TName,\n options: DxOptionSignalOptions<DxHostOptionValue<THost, TName>> & {\n initialValue: DxHostOptionValue<THost, TName>;\n },\n): WritableSignal<DxHostOptionValue<THost, TName>>;\nexport function dxOptionSignal<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n>(\n hostRef: DxHostRef<THost>,\n optionName: TName,\n options?: DxOptionSignalOptions<DxHostOptionValue<THost, TName>>,\n): WritableSignal<DxHostOptionValue<THost, TName> | undefined>;\nexport function dxOptionSignal<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n>(\n hostRef: DxHostRef<THost>,\n optionName: TName,\n options: DxOptionSignalOptions<DxHostOptionValue<THost, TName>> = {},\n): WritableSignal<DxHostOptionValue<THost, TName> | undefined> {\n type TValue = DxHostOptionValue<THost, TName>;\n const source = signal<TValue | undefined>(options.initialValue);\n const equal = options.equal;\n bindDxOption<THost, TName, TValue | undefined>(hostRef, optionName, source, {\n ...options,\n // Widen the caller's comparer to the `undefined`-including signal type.\n equal:\n equal === undefined\n ? undefined\n : (a, b) => (a === undefined || b === undefined ? Object.is(a, b) : equal(a, b)),\n // `undefined` initial value ⇒ pull from the widget once it is ready.\n initialSync: options.initialSync ?? 'auto',\n });\n return source;\n}\n\n/**\n * Creates a read-only signal holding the latest payload of a widget event\n * (`undefined` until the event fires for the first time). Event names and\n * payload types are derived from DevExtreme's `onXxx` handler options:\n *\n * ```ts\n * readonly focusOut = dxEventSignal(this.textBox, 'focusOut');\n * readonly rowClick = dxEventSignal(this.grid, 'rowClick');\n * ```\n *\n * Every fire notifies consumers, even when DevExtreme reuses or mutates the\n * event-args object — an event stream never dedupes. With a getter `hostRef`\n * the subscription follows widget re-creation; the last payload is kept\n * across the gap.\n */\nexport function dxEventSignal<\n THost extends DxHostComponent,\n TEvent extends DxHostEventName<THost>,\n>(\n hostRef: DxHostRef<THost>,\n eventName: TEvent,\n injector?: Injector,\n): Signal<DxHostEventArg<THost, TEvent> | undefined> {\n type TArg = DxHostEventArg<THost, TEvent>;\n if (injector === undefined) {\n assertInInjectionContext(dxEventSignal);\n }\n const resolvedInjector = injector ?? inject(Injector);\n const latest = signal<TArg | undefined>(undefined, { equal: () => false });\n\n onDxWidgetReady(\n hostRef,\n (instance) => {\n const handler = (eventArgs: TArg): void => latest.set(eventArgs);\n instance.on(eventName, handler);\n return () => instance.off(eventName, handler);\n },\n resolvedInjector,\n );\n return latest.asReadonly();\n}\n\n/**\n * Exposes the DevExtreme widget instance behind a host reference as a signal\n * that is `undefined` until the widget exists. With a getter `hostRef` (e.g.\n * a `viewChild(...)` signal) it follows widget re-creation: the signal resets\n * to `undefined` when the widget goes away and yields the new instance once\n * it is ready.\n *\n * ```ts\n * private readonly gridRef = viewChild(DxDataGridComponent);\n * readonly grid = dxInstanceSignal(this.gridRef);\n * ```\n */\nexport function dxInstanceSignal<THost extends DxHostComponent>(\n hostRef: DxHostRef<THost>,\n injector?: Injector,\n): Signal<DxInstanceOf<THost> | undefined> {\n if (injector === undefined) {\n assertInInjectionContext(dxInstanceSignal);\n }\n const resolvedInjector = injector ?? inject(Injector);\n const instance = signal<DxInstanceOf<THost> | undefined>(undefined);\n onDxWidgetReady(\n hostRef,\n (widget) => {\n instance.set(widget);\n return () => instance.set(undefined);\n },\n resolvedInjector,\n );\n return instance.asReadonly();\n}\n\n/**\n * Injects a devextreme-angular component from the *current element* and\n * exposes its widget instance as a signal that becomes non-`undefined` once\n * the widget has been created:\n *\n * ```ts\n * readonly grid = injectDxInstance(DxDataGridComponent);\n * ```\n *\n * The injection is strictly `{ self: true }` — it throws when the current\n * element does not carry the component. (Versions before 2.0 silently fell\n * back to ancestor injection, which could grab a *parent* widget of the same\n * type; use `dxInstanceSignal(viewChild(...))` or an explicit `inject()` to\n * reach a widget elsewhere in the template.)\n */\nexport function injectDxInstance<THost extends DxHostComponent>(\n token: ProviderToken<THost>,\n): Signal<DxInstanceOf<THost> | undefined> {\n return dxInstanceSignal(inject(token, { self: true }));\n}\n","import {\n assertInInjectionContext,\n DestroyRef,\n effect,\n inject,\n Injector,\n untracked,\n type Signal,\n} from '@angular/core';\nimport CustomStore from 'devextreme/data/custom_store';\nimport DataSource from 'devextreme/data/data_source';\n\n/**\n * The data-in half of the zoneless story: DevExtreme components load their\n * data through `DataSource` / stores, which know nothing about signals. These\n * helpers connect the two — a signal-produced array as a live data source,\n * and signal-driven reload triggers for any remote source.\n */\n\n/** Options for {@link dxArrayStoreSource}. */\nexport interface DxArrayStoreSourceOptions {\n /** Key expression handed to the underlying store (replaces `keyExpr` on the widget). */\n readonly key?: string | string[];\n /** Explicit injector when called outside an injection context. */\n readonly injector?: Injector;\n}\n\n/**\n * Wraps a `Signal<readonly T[]>` in a DevExtreme `DataSource` that reloads\n * whenever the signal changes — bind it to any `[dataSource]` input and the\n * widget follows the signal:\n *\n * ```ts\n * readonly orders = signal<readonly Order[]>([]);\n * readonly ordersSource = dxArrayStoreSource(this.orders, { key: 'id' });\n * // <dx-data-grid [dataSource]=\"ordersSource\" />\n * ```\n *\n * The store loads in `'raw'` mode, so DevExtreme applies filtering, sorting\n * and paging client-side exactly as for a plain array. The source is disposed\n * when the injector is destroyed.\n */\nexport function dxArrayStoreSource<TItem, TKey = unknown>(\n source: Signal<readonly TItem[]>,\n options: DxArrayStoreSourceOptions = {},\n): DataSource<TItem, TKey> {\n if (options.injector === undefined) {\n assertInInjectionContext(dxArrayStoreSource);\n }\n const injector = options.injector ?? inject(Injector);\n\n const dataSource = new DataSource<TItem, TKey>({\n store: new CustomStore<TItem, TKey>({\n key: options.key,\n loadMode: 'raw',\n // `untracked` — loads must not create reactive subscriptions;\n // reloading is driven by the effect below.\n load: () => untracked(source) as TItem[],\n }),\n });\n dxReloadOn(dataSource, [source], injector);\n injector.get(DestroyRef).onDestroy(() => dataSource.dispose());\n return dataSource;\n}\n\n/** A reload target: anything reloadable/refreshable, or a plain callback. */\nexport type DxReloadTarget =\n | { reload(): unknown }\n | { refresh(): unknown }\n | (() => unknown);\n\n/**\n * Triggers a reload whenever one of the dependency signals changes — the\n * missing link between external filter state held in signals and a\n * remote-loading `DataSource` (or grid), without hand-written `refresh()`\n * plumbing in every component:\n *\n * ```ts\n * readonly search = signal('');\n * readonly source = new DataSource({ store: createStore({ loadUrl: '/api/orders' }) });\n * constructor() {\n * dxReloadOn(this.source, [this.search]);\n * }\n * ```\n *\n * The first run only collects dependencies; reloads happen on changes. For a\n * target that is not a `DataSource` (e.g. a grid instance living in a\n * signal), pass a callback: `dxReloadOn(() => this.grid()?.refresh(), [deps])`.\n */\nexport function dxReloadOn(\n target: DxReloadTarget,\n dependencies: readonly Signal<unknown>[],\n injector?: Injector,\n): void {\n if (injector === undefined) {\n assertInInjectionContext(dxReloadOn);\n }\n const resolvedInjector = injector ?? inject(Injector);\n const trigger =\n typeof target === 'function'\n ? target\n : 'reload' in target\n ? (): unknown => target.reload()\n : (): unknown => target.refresh();\n\n let first = true;\n effect(\n () => {\n for (const dependency of dependencies) {\n dependency();\n }\n if (first) {\n first = false;\n return;\n }\n untracked(() => void trigger());\n },\n { injector: resolvedInjector },\n );\n}\n","import { Directive, input, model, untracked, type WritableSignal } from '@angular/core';\nimport {\n bindDxState,\n dxOptionAdapter,\n type DxBindingAdapter,\n type DxBindingOptions,\n} from './binding';\nimport { dxStructuralEquals, type DxEqualityFn } from './equality';\nimport type {\n DxHostComponent,\n DxHostOptionName,\n DxInstanceOf,\n} from './types';\n\n/**\n * Abstract base directives for the concrete per-component adapter directives.\n *\n * Each family declares one `model()` whose field name doubles as the binding\n * name (`[(dxValue)]`, `[(dxSelectedRowKeys)]`, ...). Concrete directives only\n * inject their host component and name the widget option — the option name is\n * type-checked against the widget's `Properties`, so a typo or an option that\n * does not exist on that widget fails to compile.\n */\n\n/** Shared plumbing: attaches the family model to a widget option or custom adapter. */\n@Directive()\nexport abstract class DxBindingDirectiveBase {\n protected bindOption<THost extends DxHostComponent, TValue>(\n host: THost,\n optionName: DxHostOptionName<THost>,\n source: WritableSignal<TValue>,\n options?: DxBindingOptions<TValue>,\n ): void {\n bindDxState(\n host,\n source,\n dxOptionAdapter<THost, DxHostOptionName<THost>, TValue>(optionName),\n options,\n );\n }\n\n protected bindAdapter<THost extends DxHostComponent, TValue>(\n host: THost,\n source: WritableSignal<TValue>,\n adapter: DxBindingAdapter<DxInstanceOf<THost>, TValue>,\n options?: DxBindingOptions<TValue>,\n ): void {\n bindDxState(host, source, adapter, options);\n }\n}\n\n/**\n * `[(dxValue)]` — two-way binds an editor's `value` option to a signal.\n * Also exposes:\n * - `dxValueDebounce`: debounce (ms) for the widget → signal direction,\n * - `dxValueEqual`: custom equality to suppress echo updates.\n */\n@Directive()\nexport abstract class DxValueDirectiveBase<\n THost extends DxHostComponent,\n TValue,\n> extends DxBindingDirectiveBase {\n readonly dxValue = model.required<TValue>();\n readonly dxValueDebounce = input(0);\n readonly dxValueEqual = input<DxEqualityFn<TValue> | undefined>(undefined);\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, TValue>(host, optionName, this.dxValue, {\n debounceMs: () => this.dxValueDebounce(),\n equal: (a, b) => (untracked(this.dxValueEqual) ?? dxStructuralEquals)(a, b),\n });\n }\n}\n\n/** `[(dxSelectedRowKeys)]` / `[(dxSelectedItemKeys)]`-style multi-selection bases. */\n@Directive()\nexport abstract class DxSelectedRowKeysDirectiveBase<\n THost extends DxHostComponent,\n TKey,\n> extends DxBindingDirectiveBase {\n readonly dxSelectedRowKeys = model.required<readonly TKey[]>();\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, readonly TKey[]>(host, optionName, this.dxSelectedRowKeys);\n }\n}\n\n@Directive()\nexport abstract class DxSelectedItemKeysDirectiveBase<\n THost extends DxHostComponent,\n TKey,\n> extends DxBindingDirectiveBase {\n readonly dxSelectedItemKeys = model.required<readonly TKey[]>();\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, readonly TKey[]>(host, optionName, this.dxSelectedItemKeys);\n }\n}\n\n/** `[(dxSelectedIndex)]` — for index-based navigation widgets (Tabs, TabPanel, ...). */\n@Directive()\nexport abstract class DxSelectedIndexDirectiveBase<\n THost extends DxHostComponent,\n> extends DxBindingDirectiveBase {\n readonly dxSelectedIndex = model.required<number>();\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, number>(host, optionName, this.dxSelectedIndex);\n }\n}\n\n/** `[(dxVisible)]` — for overlay widgets (Popup, Popover, Toast, ...). */\n@Directive()\nexport abstract class DxVisibleDirectiveBase<\n THost extends DxHostComponent,\n> extends DxBindingDirectiveBase {\n readonly dxVisible = model.required<boolean>();\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, boolean>(host, optionName, this.dxVisible);\n }\n}\n","/*\n * Public API surface of ngx-devextreme-zoneless/core — the binding engine,\n * type system and directive bases, without any per-widget directives.\n */\n\n// Core type system\nexport type {\n DxWidget,\n DxPropertiesOf,\n DxOptionName,\n DxOptionValue,\n DxEventName,\n DxEventArg,\n DxSubscribable,\n DxHostComponent,\n DxInstanceOf,\n DxHostProperties,\n DxHostOptionName,\n DxHostOptionValue,\n DxHostEventName,\n DxHostEventArg,\n DxHostValue,\n DxHostRef,\n DxOptionChangedArgs,\n DxInitializedArgs,\n} from './lib/types';\n\n// Shared editor value types\nexport type {\n DxDateValue,\n DxDateRange,\n DxNumberRange,\n DxFilterExpression,\n} from './lib/value-types';\n\n// Equality helpers\nexport { dxStructuralEquals, dxShallowObjectEquals } from './lib/equality';\nexport type { DxEqualityFn } from './lib/equality';\n\n// Readiness\nexport { onDxWidgetReady } from './lib/ready';\nexport type { DxWidgetReadyCleanup } from './lib/ready';\n\n// Binding engine (composition API)\nexport { bindDxState, bindDxOption, dxOptionAdapter } from './lib/binding';\nexport type {\n DxAdapterEventName,\n DxBindingAdapter,\n DxBindingOptions,\n DxInitialSync,\n} from './lib/binding';\n\n// Signal factories (composition API)\nexport {\n dxOptionSignal,\n dxEventSignal,\n dxInstanceSignal,\n injectDxInstance,\n} from './lib/signals';\nexport type { DxOptionSignalOptions } from './lib/signals';\n\n// Data loading (signals → DataSource)\nexport { dxArrayStoreSource, dxReloadOn } from './lib/data-source';\nexport type { DxArrayStoreSourceOptions, DxReloadTarget } from './lib/data-source';\n\n// Directive bases (for building adapters for components not covered out of the box)\nexport {\n DxBindingDirectiveBase,\n DxValueDirectiveBase,\n DxSelectedRowKeysDirectiveBase,\n DxSelectedItemKeysDirectiveBase,\n DxSelectedIndexDirectiveBase,\n DxVisibleDirectiveBase,\n} from './lib/bases';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAAA;;;;;;AAMG;AAKH;;;;AAIG;AACG,SAAU,kBAAkB,CAAC,CAAU,EAAE,CAAU,EAAA;IACrD,IAAI,MAAM,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE;AACjB,QAAA,OAAO,IAAI;IACf;IACA,IAAI,CAAC,YAAY,IAAI,IAAI,CAAC,YAAY,IAAI,EAAE;AACxC,QAAA,QACI,CAAC,YAAY,IAAI,IAAI,CAAC,YAAY,IAAI,IAAI,CAAC,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE;IAE7E;AACA,IAAA,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;AACtC,QAAA,QACI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC;AAChB,YAAA,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC;AAChB,YAAA,CAAC,CAAC,MAAM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,IAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,OAAA,EAAA,EAAA,SAAA,EAAA,iBAAA,EAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAAtB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAD3C;;;ACpHD;;;AAGG;AAgCH;;ACnCA;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"ngx-devextreme-zoneless-core.mjs","sources":["../../core/src/lib/equality.ts","../../core/src/lib/ready.ts","../../core/src/lib/binding.ts","../../core/src/lib/signals.ts","../../core/src/lib/data-source.ts","../../core/src/lib/remote.ts","../../core/src/lib/bases.ts","../../core/src/public-api.ts","../../core/src/ngx-devextreme-zoneless-core.ts"],"sourcesContent":["/**\n * Structural equality used to break the two-way binding echo cycle\n * (signal → widget → `optionChanged` → signal → ...).\n *\n * DevExtreme frequently emits *new* array/object references for unchanged\n * data (e.g. `selectedRowKeys`), so reference equality alone would loop.\n */\n\n/** Custom equality comparer for a bound value. */\nexport type DxEqualityFn<in T> = (a: T, b: T) => boolean;\n\n/**\n * Deep structural equality with special handling for `Date` and arrays.\n * Plain objects are compared by their own enumerable keys; class instances\n * (anything with a custom prototype) fall back to reference equality.\n */\nexport function dxStructuralEquals(a: unknown, b: unknown): boolean {\n if (Object.is(a, b)) {\n return true;\n }\n if (a instanceof Date || b instanceof Date) {\n return (\n a instanceof Date && b instanceof Date && a.getTime() === b.getTime()\n );\n }\n if (Array.isArray(a) || Array.isArray(b)) {\n return (\n Array.isArray(a) &&\n Array.isArray(b) &&\n a.length === b.length &&\n a.every((item, index) => dxStructuralEquals(item, b[index]))\n );\n }\n if (isPlainObject(a) && isPlainObject(b)) {\n const aKeys = Object.keys(a);\n const bKeys = Object.keys(b);\n return (\n aKeys.length === bKeys.length &&\n aKeys.every(\n (key) =>\n Object.prototype.hasOwnProperty.call(b, key) &&\n dxStructuralEquals(a[key], b[key]),\n )\n );\n }\n return false;\n}\n\n/** Shallow equality over the own enumerable keys of two plain objects. */\nexport function dxShallowObjectEquals(a: unknown, b: unknown): boolean {\n if (Object.is(a, b)) {\n return true;\n }\n if (!isPlainObject(a) || !isPlainObject(b)) {\n return false;\n }\n const aKeys = Object.keys(a);\n const bKeys = Object.keys(b);\n return (\n aKeys.length === bKeys.length &&\n aKeys.every(\n (key) =>\n Object.prototype.hasOwnProperty.call(b, key) &&\n Object.is(a[key], b[key]),\n )\n );\n}\n\nfunction isPlainObject(value: unknown): value is Record<string, unknown> {\n if (typeof value !== 'object' || value === null) {\n return false;\n }\n const proto: unknown = Object.getPrototypeOf(value);\n return proto === Object.prototype || proto === null;\n}\n","import {\n afterNextRender,\n assertInInjectionContext,\n DestroyRef,\n effect,\n inject,\n Injector,\n untracked,\n} from '@angular/core';\nimport type {\n DxHostComponent,\n DxHostRef,\n DxInitializedArgs,\n DxInstanceOf,\n DxWidget,\n} from './types';\n\n/** Cleanup returned by an {@link onDxWidgetReady} callback; runs when the widget goes away. */\nexport type DxWidgetReadyCleanup = () => void;\n\n/**\n * Invokes `callback` as soon as the DevExtreme widget behind a\n * devextreme-angular host component exists — once *per widget instance*:\n *\n * - For a direct host reference the callback fires exactly once (the widget\n * dies with the host component and its element).\n * - For a lazily-provided host (a `viewChild(...)` signal or any getter) the\n * getter is watched for the whole injector lifetime: when the host is\n * destroyed and a new one appears (`@if`, tab panels, re-created popup\n * content, ...), the previous attach is disposed and the callback fires\n * again for the new widget.\n *\n * The callback may return a cleanup function; it runs when the widget goes\n * away — on host re-creation as well as on injector destruction. Errors\n * thrown by cleanups are swallowed, since the widget is routinely already\n * disposed when they run.\n *\n * Handles all timing subtleties:\n * - devextreme-angular creates the widget in `ngAfterViewInit`, long after\n * directives on the same element are constructed;\n * - the `onInitialized` event fires *during* widget construction, before the\n * wrapper's `instance` property is assigned — the widget is therefore taken\n * from the event payload;\n * - `afterNextRender` covers hosts whose widget already exists (late-resolved\n * view children).\n *\n * Must be called in an injection context unless an `injector` is provided.\n * All pending work is disposed automatically when the injector is destroyed.\n */\nexport function onDxWidgetReady<THost extends DxHostComponent>(\n hostRef: DxHostRef<THost>,\n callback: (\n instance: DxInstanceOf<THost> & DxWidget,\n host: THost,\n ) => void | DxWidgetReadyCleanup,\n injector?: Injector,\n): void {\n if (injector === undefined) {\n assertInInjectionContext(onDxWidgetReady);\n }\n const resolvedInjector = injector ?? inject(Injector);\n\n type TInstance = DxInstanceOf<THost> & DxWidget;\n\n /** Disposal scope of the current attach; replaced on host re-creation. */\n let scope: DxWidgetReadyCleanup[] | undefined;\n let destroyed = false;\n\n const detach = (): void => {\n const cleanups = scope;\n scope = undefined;\n if (cleanups === undefined) {\n return;\n }\n for (let i = cleanups.length - 1; i >= 0; i--) {\n try {\n cleanups[i]?.();\n } catch {\n // The widget is routinely already disposed at this point.\n }\n }\n };\n resolvedInjector.get(DestroyRef).onDestroy(() => {\n destroyed = true;\n detach();\n });\n\n const attach = (host: THost): void => {\n const cleanups: DxWidgetReadyCleanup[] = [];\n scope = cleanups;\n let done = false;\n\n const complete = (instance: TInstance | undefined | null): void => {\n // The scope check drops stale completions (afterNextRender or a\n // late `onInitialized`) that race a detach.\n if (done || destroyed || scope !== cleanups || instance === undefined || instance === null) {\n return;\n }\n done = true;\n const cleanup = callback(instance, host);\n if (typeof cleanup === 'function') {\n cleanups.push(cleanup);\n }\n };\n\n const subscription = host.onInitialized.subscribe((event) => {\n // `host.instance` is not assigned yet at this point — use the\n // widget carried by the event payload.\n const args = event as DxInitializedArgs<DxWidget>;\n complete((args.component ?? host.instance) as TInstance);\n });\n cleanups.push(() => subscription.unsubscribe());\n // Fallback for hosts whose widget already exists (e.g. late-resolved\n // view children) or whose `initialized` event was missed.\n afterNextRender(\n { read: () => complete(host.instance as TInstance) },\n { injector: resolvedInjector },\n );\n };\n\n if (typeof hostRef !== 'function') {\n attach(hostRef);\n return;\n }\n\n // Lazy host (viewChild signal or arbitrary getter): watch for the whole\n // injector lifetime. A change of host identity means the widget was\n // destroyed and re-created — dispose the previous attach and re-attach.\n let currentHost: THost | undefined;\n effect(\n () => {\n const host = hostRef() ?? undefined;\n if (host === currentHost) {\n return;\n }\n currentHost = host;\n untracked(() => {\n detach();\n if (host !== undefined) {\n attach(host);\n }\n });\n },\n { injector: resolvedInjector },\n );\n}\n","import {\n assertInInjectionContext,\n effect,\n inject,\n Injector,\n untracked,\n type WritableSignal,\n} from '@angular/core';\nimport { dxStructuralEquals, type DxEqualityFn } from './equality';\nimport { onDxWidgetReady } from './ready';\nimport type {\n DxEventName,\n DxHostComponent,\n DxHostOptionName,\n DxHostOptionValue,\n DxHostRef,\n DxInstanceOf,\n DxOptionChangedArgs,\n DxPropertiesOf,\n DxWidget,\n} from './types';\n\n/** The event names of a widget *instance*, derived from its `Properties` bag. */\nexport type DxAdapterEventName<TInstance> = DxEventName<DxPropertiesOf<TInstance>>;\n\n/**\n * Describes how a bound value is read from / written to a widget and which\n * widget events indicate that it may have changed outside Angular.\n *\n * `bindDxOption` provides the standard option-based adapter; custom adapters\n * cover method-based state such as chart point selection or tree-view\n * selection.\n */\nexport interface DxBindingAdapter<TInstance extends DxWidget, TValue> {\n /**\n * Widget events (`'optionChanged'`, `'selectionChanged'`, ...) that may\n * affect the bound value. Names are checked against the widget's\n * `Properties` declaration — a typo or an event a DevExtreme upgrade\n * renamed is a compile error.\n */\n readonly events: readonly DxAdapterEventName<TInstance>[];\n /** Reads the current value from the widget. */\n read(instance: TInstance): TValue;\n /** Writes a new value to the widget. */\n write(instance: TInstance, value: TValue): void;\n /** Optional filter deciding whether a received event affects this binding. */\n accept?(eventName: DxAdapterEventName<TInstance>, eventArgs: unknown): boolean;\n}\n\n/** Which side wins the initial synchronization when the binding attaches. */\nexport type DxInitialSync =\n /** Push the signal's current value into the widget (unless it is `undefined`). */\n | 'signal'\n /** Pull the widget's current value into the signal. */\n | 'widget'\n /** Push if the signal holds a value other than `undefined`, otherwise pull. */\n | 'auto';\n\n/** Tuning options for a two-way binding. */\nexport interface DxBindingOptions<TValue> {\n /** Equality used to suppress echo updates. Defaults to {@link dxStructuralEquals}. */\n readonly equal?: DxEqualityFn<NoInfer<TValue>>;\n /**\n * Debounce (milliseconds) applied to the widget → signal direction, e.g.\n * to tame per-keystroke `valueChanged` events. May be reactive.\n * A read still pending when the binding is torn down is dropped — the\n * signal keeps the last applied value.\n */\n readonly debounceMs?: number | (() => number);\n /** Initial synchronization strategy. Defaults to `'auto'`. */\n readonly initialSync?: DxInitialSync;\n /** Explicit injector when called outside an injection context. */\n readonly injector?: Injector;\n}\n\n/**\n * Wires a writable signal to widget state described by an adapter, in both\n * directions, with echo suppression and automatic teardown on destroy.\n *\n * - widget → signal: adapter events trigger a (optionally debounced) read;\n * the signal is only written when the value structurally changed. Because\n * the write is a plain signal write, zoneless change detection is scheduled\n * without any `NgZone` involvement.\n * - signal → widget: an `effect` pushes changes into the widget, again only\n * when the value actually differs.\n *\n * When `hostRef` is a getter (e.g. a `viewChild(...)` signal) the binding\n * survives widget re-creation: if the host component is destroyed and a new\n * one appears, the binding re-attaches and the initial synchronization runs\n * again — a signal holding state therefore restores it into the new widget.\n */\nexport function bindDxState<THost extends DxHostComponent, TValue>(\n hostRef: DxHostRef<THost>,\n source: WritableSignal<TValue>,\n adapter: DxBindingAdapter<DxInstanceOf<THost>, TValue>,\n options: DxBindingOptions<TValue> = {},\n): void {\n if (options.injector === undefined) {\n assertInInjectionContext(bindDxState);\n }\n const injector = options.injector ?? inject(Injector);\n const equal = options.equal ?? (dxStructuralEquals as DxEqualityFn<TValue>);\n const debounceMs =\n typeof options.debounceMs === 'function'\n ? options.debounceMs\n : (): number => (options.debounceMs as number | undefined) ?? 0;\n const initialSync = options.initialSync ?? 'auto';\n\n /**\n * Re-entrancy latch. Both directions run synchronous DevExtreme code that\n * may fire events inline; the latch prevents those from re-entering the\n * binding while structural equality handles the asynchronous echo path.\n */\n let syncing = false;\n let debounceTimer: ReturnType<typeof setTimeout> | undefined;\n\n const guarded = (work: () => void): void => {\n syncing = true;\n try {\n work();\n } finally {\n syncing = false;\n }\n };\n\n onDxWidgetReady(\n hostRef,\n (instance) => {\n // --- initial synchronization -------------------------------------\n const initial = untracked(source);\n const pushInitial =\n initialSync === 'signal' ||\n (initialSync === 'auto' && initial !== undefined);\n if (pushInitial) {\n if (initial !== undefined && !equal(adapter.read(instance), initial)) {\n guarded(() => adapter.write(instance, initial));\n }\n } else {\n const widgetValue = adapter.read(instance);\n if (!equal(initial, widgetValue)) {\n guarded(() => source.set(widgetValue));\n }\n }\n\n // --- widget → signal ----------------------------------------------\n const applyFromWidget = (): void => {\n const value = adapter.read(instance);\n if (!equal(untracked(source), value)) {\n guarded(() => source.set(value));\n }\n };\n const detachers: (() => void)[] = [];\n for (const eventName of adapter.events) {\n const handler = (eventArgs: unknown): void => {\n if (syncing) {\n return;\n }\n if (adapter.accept !== undefined && !adapter.accept(eventName, eventArgs)) {\n return;\n }\n const wait = debounceMs();\n if (wait > 0) {\n if (debounceTimer !== undefined) {\n clearTimeout(debounceTimer);\n }\n debounceTimer = setTimeout(applyFromWidget, wait);\n } else {\n applyFromWidget();\n }\n };\n instance.on(eventName, handler);\n detachers.push(() => instance.off(eventName, handler));\n }\n\n // --- signal → widget ----------------------------------------------\n const pusher = effect(\n () => {\n const value = source();\n if (syncing || value === undefined) {\n return;\n }\n untracked(() => {\n if (!equal(adapter.read(instance), value)) {\n guarded(() => adapter.write(instance, value));\n }\n });\n },\n { injector },\n );\n detachers.push(() => pusher.destroy());\n\n return () => {\n // A pending debounced read must not fire into a dead widget.\n // Its trailing value is deliberately dropped — the signal\n // still holds the last applied state.\n if (debounceTimer !== undefined) {\n clearTimeout(debounceTimer);\n debounceTimer = undefined;\n }\n for (let i = detachers.length - 1; i >= 0; i--) {\n detachers[i]?.();\n }\n };\n },\n injector,\n );\n}\n\n/**\n * The standard adapter: binds a signal to a single widget *option*, listening\n * to `optionChanged` filtered by option name. Nested changes\n * (`fullName: 'formData.firstName'`) are matched via their root name.\n */\nexport function dxOptionAdapter<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n TValue,\n>(optionName: TName): DxBindingAdapter<DxInstanceOf<THost>, TValue> {\n return {\n // Every DevExtreme widget declares `onOptionChanged`; the cast is\n // only needed because `THost` is an unresolved type parameter here.\n events: ['optionChanged'] as unknown as readonly DxAdapterEventName<\n DxInstanceOf<THost>\n >[],\n read: (instance) => instance.option(optionName) as TValue,\n write: (instance, value) => {\n (instance.option as (name: string, value: unknown) => void)(optionName, value);\n },\n accept: (_eventName, eventArgs) => {\n const args = eventArgs as DxOptionChangedArgs;\n return args.name === optionName || args.fullName === optionName;\n },\n };\n}\n\n/**\n * Two-way binds a writable signal to a widget option — the strongly-typed\n * workhorse behind all option-based directives of this library, and directly\n * usable for any option of any DevExtreme component:\n *\n * ```ts\n * const grid = viewChild(DxDataGridComponent<Order, number>);\n * readonly keys = signal<number[]>([]);\n * constructor() {\n * bindDxOption(this.grid, 'selectedRowKeys', this.keys);\n * }\n * ```\n */\nexport function bindDxOption<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n TValue extends DxHostOptionValue<THost, TName> | undefined,\n>(\n hostRef: DxHostRef<THost>,\n optionName: TName,\n source: WritableSignal<TValue>,\n options?: DxBindingOptions<TValue>,\n): void {\n bindDxState(hostRef, source, dxOptionAdapter<THost, TName, TValue>(optionName), options);\n}\n","import {\n assertInInjectionContext,\n inject,\n Injector,\n signal,\n type ProviderToken,\n type Signal,\n type WritableSignal,\n} from '@angular/core';\nimport { bindDxOption, type DxBindingOptions } from './binding';\nimport { onDxWidgetReady } from './ready';\nimport type {\n DxHostComponent,\n DxHostEventArg,\n DxHostEventName,\n DxHostOptionName,\n DxHostOptionValue,\n DxHostRef,\n DxInstanceOf,\n} from './types';\n\n/** Options for {@link dxOptionSignal}. */\nexport interface DxOptionSignalOptions<TValue> extends DxBindingOptions<TValue> {\n /**\n * Value the signal holds until the widget is ready. When provided, the\n * signal is also pushed into the widget on attach; without it, the\n * widget's current option value is pulled into the signal instead.\n */\n readonly initialValue?: TValue;\n}\n\n/**\n * Creates a writable signal that is two-way bound to a widget option — the\n * universal escape hatch that works with *every* option of *every*\n * devextreme-angular component, fully typed from DevExtreme's `Properties`:\n *\n * ```ts\n * private readonly textBox = inject(DxTextBoxComponent, { self: true });\n * readonly placeholder = dxOptionSignal(this.textBox, 'placeholder');\n * readonly mode = dxOptionSignal(this.textBox, 'mode', { initialValue: 'search' });\n * ```\n */\nexport function dxOptionSignal<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n>(\n hostRef: DxHostRef<THost>,\n optionName: TName,\n options: DxOptionSignalOptions<DxHostOptionValue<THost, TName>> & {\n initialValue: DxHostOptionValue<THost, TName>;\n },\n): WritableSignal<DxHostOptionValue<THost, TName>>;\nexport function dxOptionSignal<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n>(\n hostRef: DxHostRef<THost>,\n optionName: TName,\n options?: DxOptionSignalOptions<DxHostOptionValue<THost, TName>>,\n): WritableSignal<DxHostOptionValue<THost, TName> | undefined>;\nexport function dxOptionSignal<\n THost extends DxHostComponent,\n TName extends DxHostOptionName<THost>,\n>(\n hostRef: DxHostRef<THost>,\n optionName: TName,\n options: DxOptionSignalOptions<DxHostOptionValue<THost, TName>> = {},\n): WritableSignal<DxHostOptionValue<THost, TName> | undefined> {\n type TValue = DxHostOptionValue<THost, TName>;\n const source = signal<TValue | undefined>(options.initialValue);\n const equal = options.equal;\n bindDxOption<THost, TName, TValue | undefined>(hostRef, optionName, source, {\n ...options,\n // Widen the caller's comparer to the `undefined`-including signal type.\n equal:\n equal === undefined\n ? undefined\n : (a, b) => (a === undefined || b === undefined ? Object.is(a, b) : equal(a, b)),\n // `undefined` initial value ⇒ pull from the widget once it is ready.\n initialSync: options.initialSync ?? 'auto',\n });\n return source;\n}\n\n/**\n * Creates a read-only signal holding the latest payload of a widget event\n * (`undefined` until the event fires for the first time). Event names and\n * payload types are derived from DevExtreme's `onXxx` handler options:\n *\n * ```ts\n * readonly focusOut = dxEventSignal(this.textBox, 'focusOut');\n * readonly rowClick = dxEventSignal(this.grid, 'rowClick');\n * ```\n *\n * Every fire notifies consumers, even when DevExtreme reuses or mutates the\n * event-args object — an event stream never dedupes. With a getter `hostRef`\n * the subscription follows widget re-creation; the last payload is kept\n * across the gap.\n */\nexport function dxEventSignal<\n THost extends DxHostComponent,\n TEvent extends DxHostEventName<THost>,\n>(\n hostRef: DxHostRef<THost>,\n eventName: TEvent,\n injector?: Injector,\n): Signal<DxHostEventArg<THost, TEvent> | undefined> {\n type TArg = DxHostEventArg<THost, TEvent>;\n if (injector === undefined) {\n assertInInjectionContext(dxEventSignal);\n }\n const resolvedInjector = injector ?? inject(Injector);\n const latest = signal<TArg | undefined>(undefined, { equal: () => false });\n\n onDxWidgetReady(\n hostRef,\n (instance) => {\n const handler = (eventArgs: TArg): void => latest.set(eventArgs);\n instance.on(eventName, handler);\n return () => instance.off(eventName, handler);\n },\n resolvedInjector,\n );\n return latest.asReadonly();\n}\n\n/**\n * Exposes the DevExtreme widget instance behind a host reference as a signal\n * that is `undefined` until the widget exists. With a getter `hostRef` (e.g.\n * a `viewChild(...)` signal) it follows widget re-creation: the signal resets\n * to `undefined` when the widget goes away and yields the new instance once\n * it is ready.\n *\n * ```ts\n * private readonly gridRef = viewChild(DxDataGridComponent);\n * readonly grid = dxInstanceSignal(this.gridRef);\n * ```\n */\nexport function dxInstanceSignal<THost extends DxHostComponent>(\n hostRef: DxHostRef<THost>,\n injector?: Injector,\n): Signal<DxInstanceOf<THost> | undefined> {\n if (injector === undefined) {\n assertInInjectionContext(dxInstanceSignal);\n }\n const resolvedInjector = injector ?? inject(Injector);\n const instance = signal<DxInstanceOf<THost> | undefined>(undefined);\n onDxWidgetReady(\n hostRef,\n (widget) => {\n instance.set(widget);\n return () => instance.set(undefined);\n },\n resolvedInjector,\n );\n return instance.asReadonly();\n}\n\n/**\n * Injects a devextreme-angular component from the *current element* and\n * exposes its widget instance as a signal that becomes non-`undefined` once\n * the widget has been created:\n *\n * ```ts\n * readonly grid = injectDxInstance(DxDataGridComponent);\n * ```\n *\n * The injection is strictly `{ self: true }` — it throws when the current\n * element does not carry the component. (Versions before 2.0 silently fell\n * back to ancestor injection, which could grab a *parent* widget of the same\n * type; use `dxInstanceSignal(viewChild(...))` or an explicit `inject()` to\n * reach a widget elsewhere in the template.)\n */\nexport function injectDxInstance<THost extends DxHostComponent>(\n token: ProviderToken<THost>,\n): Signal<DxInstanceOf<THost> | undefined> {\n return dxInstanceSignal(inject(token, { self: true }));\n}\n","import {\n assertInInjectionContext,\n DestroyRef,\n effect,\n inject,\n Injector,\n untracked,\n type Signal,\n} from '@angular/core';\nimport CustomStore from 'devextreme/data/custom_store';\nimport DataSource from 'devextreme/data/data_source';\n\n/**\n * The data-in half of the zoneless story: DevExtreme components load their\n * data through `DataSource` / stores, which know nothing about signals. These\n * helpers connect the two — a signal-produced array as a live data source,\n * and signal-driven reload triggers for any remote source.\n */\n\n/** Options for {@link dxArrayStoreSource}. */\nexport interface DxArrayStoreSourceOptions {\n /** Key expression handed to the underlying store (replaces `keyExpr` on the widget). */\n readonly key?: string | string[];\n /** Explicit injector when called outside an injection context. */\n readonly injector?: Injector;\n}\n\n/**\n * Wraps a `Signal<readonly T[]>` in a DevExtreme `DataSource` that reloads\n * whenever the signal changes — bind it to any `[dataSource]` input and the\n * widget follows the signal:\n *\n * ```ts\n * readonly orders = signal<readonly Order[]>([]);\n * readonly ordersSource = dxArrayStoreSource(this.orders, { key: 'id' });\n * // <dx-data-grid [dataSource]=\"ordersSource\" />\n * ```\n *\n * The store loads in `'raw'` mode, so DevExtreme applies filtering, sorting\n * and paging client-side exactly as for a plain array. The source is disposed\n * when the injector is destroyed.\n */\nexport function dxArrayStoreSource<TItem, TKey = unknown>(\n source: Signal<readonly TItem[]>,\n options: DxArrayStoreSourceOptions = {},\n): DataSource<TItem, TKey> {\n if (options.injector === undefined) {\n assertInInjectionContext(dxArrayStoreSource);\n }\n const injector = options.injector ?? inject(Injector);\n\n const dataSource = new DataSource<TItem, TKey>({\n store: new CustomStore<TItem, TKey>({\n key: options.key,\n loadMode: 'raw',\n // `untracked` — loads must not create reactive subscriptions;\n // reloading is driven by the effect below.\n load: () => untracked(source) as TItem[],\n }),\n });\n dxReloadOn(dataSource, [source], injector);\n injector.get(DestroyRef).onDestroy(() => dataSource.dispose());\n return dataSource;\n}\n\n/** A reload target: anything reloadable/refreshable, or a plain callback. */\nexport type DxReloadTarget =\n | { reload(): unknown }\n | { refresh(): unknown }\n | (() => unknown);\n\n/**\n * Triggers a reload whenever one of the dependency signals changes — the\n * missing link between external filter state held in signals and a\n * remote-loading `DataSource` (or grid), without hand-written `refresh()`\n * plumbing in every component:\n *\n * ```ts\n * readonly search = signal('');\n * readonly source = new DataSource({ store: createStore({ loadUrl: '/api/orders' }) });\n * constructor() {\n * dxReloadOn(this.source, [this.search]);\n * }\n * ```\n *\n * The first run only collects dependencies; reloads happen on changes. For a\n * target that is not a `DataSource` (e.g. a grid instance living in a\n * signal), pass a callback: `dxReloadOn(() => this.grid()?.refresh(), [deps])`.\n */\nexport function dxReloadOn(\n target: DxReloadTarget,\n dependencies: readonly Signal<unknown>[],\n injector?: Injector,\n): void {\n if (injector === undefined) {\n assertInInjectionContext(dxReloadOn);\n }\n const resolvedInjector = injector ?? inject(Injector);\n const trigger =\n typeof target === 'function'\n ? target\n : 'reload' in target\n ? (): unknown => target.reload()\n : (): unknown => target.refresh();\n\n let first = true;\n effect(\n () => {\n for (const dependency of dependencies) {\n dependency();\n }\n if (first) {\n first = false;\n return;\n }\n untracked(() => void trigger());\n },\n { injector: resolvedInjector },\n );\n}\n","import {\n assertInInjectionContext,\n computed,\n DestroyRef,\n effect,\n inject,\n Injector,\n signal,\n untracked,\n type Signal,\n} from '@angular/core';\nimport type { LoadOptions, LoadResult } from 'devextreme/common/data';\nimport CustomStore from 'devextreme/data/custom_store';\nimport DataSource from 'devextreme/data/data_source';\n\n/**\n * Remote data with `resource()` vocabulary: {@link dxRemoteStore} wraps a\n * consumer-supplied load function in a DevExtreme `DataSource` and exposes\n * the loading state the widget cannot show for you — `isLoading` and `error`\n * as signals for outside-the-widget UI, `reload()` for retries, dependency\n * signals for query state that lives outside the widget (search boxes,\n * master selections), and an `AbortSignal` per load so superseded requests\n * are actually cancelled instead of racing the newest one.\n */\n\n/**\n * A remote load function: receives the widget-produced `LoadOptions`\n * (filter/sort/group/skip/take/…) and an `AbortSignal` that fires when the\n * load is superseded or the owning injector is destroyed. Resolve to\n * DevExtreme's `LoadResult` — either a plain array or\n * `{ data, totalCount, summary, groupCount }`.\n */\nexport type DxRemoteLoader<TItem> = (\n loadOptions: LoadOptions<TItem>,\n abortSignal: AbortSignal,\n) => PromiseLike<LoadResult<TItem>>;\n\n/** Options for {@link dxRemoteStore}. */\nexport interface DxRemoteStoreOptions<TItem, TKey> {\n /** Loads one page of data. See {@link DxRemoteLoader}. */\n readonly load: DxRemoteLoader<TItem>;\n /**\n * Resolves a single item by key — required for lookup editors\n * (`dx-select-box`, `dx-lookup`, …) that must display a value set\n * programmatically before/without loading the containing page. Against a\n * DevExtreme.AspNet.Data endpoint this is a filtered load:\n * `load({ filter: ['id', '=', key], take: 1 })`, taking the first item.\n * `byKey` activity does not drive `isLoading`/`error` — its failures\n * surface through the requesting widget.\n */\n readonly byKey?: (key: TKey, abortSignal: AbortSignal) => PromiseLike<TItem>;\n /** Key expression handed to the underlying store (replaces `keyExpr` on the widget). */\n readonly key?: string | string[];\n /**\n * Query dependencies: when any of these signals changes, the store\n * resets to the first page and reloads (the dependencies describe the\n * query, so a change starts a new result set — mirroring `DataSource`'s\n * own `filter()` semantics). The load function reads the current values\n * itself, via `untracked`.\n */\n readonly deps?: readonly Signal<unknown>[];\n /**\n * Debounce for dependency-driven reloads in milliseconds (e.g. a search\n * signal fed from keystrokes). Manual `reload()` is never debounced.\n */\n readonly debounce?: number;\n /** Explicit injector when called outside an injection context. */\n readonly injector?: Injector;\n}\n\n/** The handle returned by {@link dxRemoteStore}. */\nexport interface DxRemoteStore<TItem, TKey = unknown> {\n /** Bind this to any `[dataSource]` input. Disposed on injector destroy. */\n readonly dataSource: DataSource<TItem, TKey>;\n /** `true` while at least one load is in flight — for UI outside the widget. */\n readonly isLoading: Signal<boolean>;\n /**\n * The rejection reason of the most recent settled load, or `undefined`\n * after a successful load. Superseded (aborted) loads never write here.\n * The widget additionally shows its own load-error UI; this signal is for\n * error/retry UI outside the widget.\n */\n readonly error: Signal<unknown>;\n /**\n * Refetches the current query: cancels in-flight loads (DataSource\n * operation + transport `AbortSignal`), keeps the current page, and\n * resolves when the reload settles. Failures land in `error`, so the\n * returned promise never rejects.\n */\n reload(): Promise<void>;\n}\n\n/**\n * Wraps a remote load function in a DevExtreme `DataSource` with signal-based\n * loading state:\n *\n * ```ts\n * readonly search = signal('');\n * readonly orders = dxRemoteStore<Order, number>({\n * key: 'id',\n * deps: [this.search],\n * debounce: 300,\n * load: async (options, signal) => {\n * const params = dxLoadOptionsParams(options);\n * params.set('search', untracked(this.search));\n * const response = await fetch(`/api/orders?${params}`, { signal });\n * if (!response.ok) throw new Error(`orders load failed: ${response.status}`);\n * return response.json();\n * },\n * });\n * // <dx-data-grid [dataSource]=\"orders.dataSource\" [remoteOperations]=\"true\" />\n * // @if (orders.error()) { <button (click)=\"orders.reload()\">retry</button> }\n * ```\n *\n * Semantics, aligned with Angular's `resource()`:\n * - every load gets an `AbortSignal`; a reload (dependency-driven or manual)\n * aborts whatever is still in flight — last write wins, stale responses\n * never overwrite newer ones and never surface stale errors;\n * - `error` reflects the most recent settled load and is cleared by the next\n * successful one; `reload()` is the retry;\n * - dependency changes reset to page 0 (a new query is a new result set);\n * manual `reload()` keeps the page (same query, fresh data);\n * - widget search options are folded into `LoadOptions.filter` before `load`\n * runs (`useDefaultSearch`, matching the vendor's own remote client), so\n * the load function only ever deals in filter expressions.\n *\n * The store is load-only by design: create/update/delete intentionally stay\n * out of this API — pass a full `CustomStore` to the widget where you need\n * editing.\n */\nexport function dxRemoteStore<TItem, TKey = unknown>(\n options: DxRemoteStoreOptions<TItem, TKey>,\n): DxRemoteStore<TItem, TKey> {\n if (options.injector === undefined) {\n assertInInjectionContext(dxRemoteStore);\n }\n const injector = options.injector ?? inject(Injector);\n\n const pendingCount = signal(0);\n const lastError = signal<unknown>(undefined);\n let loadSequence = 0;\n const inFlight = new Set<AbortController>();\n\n const trackedLoad = (loadOptions: LoadOptions<TItem>): Promise<LoadResult<TItem>> => {\n const sequence = ++loadSequence;\n const controller = new AbortController();\n inFlight.add(controller);\n pendingCount.update((count) => count + 1);\n const settle = (): void => {\n inFlight.delete(controller);\n pendingCount.update((count) => count - 1);\n };\n return Promise.resolve(options.load(loadOptions, controller.signal)).then(\n (result) => {\n settle();\n if (sequence === loadSequence) {\n lastError.set(undefined);\n }\n return result;\n },\n (reason: unknown) => {\n settle();\n if (controller.signal.aborted) {\n // Superseded load: reject with DevExtreme's own\n // cancellation token (the literal `'canceled'`), which the\n // DataSource recognizes and drops without firing\n // `loadError` — the widget never flashes its error UI for\n // a load this store aborted on purpose.\n throw 'canceled';\n }\n if (sequence === loadSequence) {\n lastError.set(reason);\n }\n throw reason;\n },\n );\n };\n\n const userByKey = options.byKey;\n const trackedByKey =\n userByKey === undefined\n ? undefined\n : (key: TKey): PromiseLike<TItem> => {\n const controller = new AbortController();\n inFlight.add(controller);\n return Promise.resolve(userByKey(key, controller.signal)).finally(() =>\n inFlight.delete(controller),\n );\n };\n\n const dataSource = new DataSource<TItem, TKey>({\n store: new CustomStore<TItem, TKey>({\n key: options.key,\n loadMode: 'processed',\n useDefaultSearch: true,\n load: trackedLoad,\n byKey: trackedByKey,\n }),\n });\n\n const abortInFlight = (): void => {\n for (const controller of inFlight) {\n controller.abort();\n }\n };\n\n const reload = (): Promise<void> => {\n // Abort in-flight transport before starting over — the aborted loads\n // reject as `'canceled'` (see trackedLoad), which DevExtreme drops\n // silently. Deliberately NOT `dataSource.cancelAll()`: that method\n // resets the internal operation-id counter, and the id reuse makes\n // grid adapters discard the results of every subsequent load.\n abortInFlight();\n return Promise.resolve(dataSource.reload()).then(\n () => undefined,\n () => undefined,\n );\n };\n\n const deps = options.deps ?? [];\n let debounceTimer: ReturnType<typeof setTimeout> | undefined;\n if (deps.length > 0) {\n const debounceMs = options.debounce ?? 0;\n const run = (): void => {\n debounceTimer = undefined;\n dataSource.pageIndex(0);\n void reload();\n };\n let first = true;\n effect(\n () => {\n for (const dependency of deps) {\n dependency();\n }\n if (first) {\n first = false;\n return;\n }\n if (debounceTimer !== undefined) {\n clearTimeout(debounceTimer);\n }\n if (debounceMs > 0) {\n debounceTimer = setTimeout(run, debounceMs);\n } else {\n untracked(run);\n }\n },\n { injector },\n );\n }\n\n injector.get(DestroyRef).onDestroy(() => {\n if (debounceTimer !== undefined) {\n clearTimeout(debounceTimer);\n }\n abortInFlight();\n dataSource.dispose();\n });\n\n return {\n dataSource,\n isLoading: computed(() => pendingCount() > 0),\n error: lastError.asReadonly(),\n reload,\n };\n}\n\n/** `sort`/`group` entries normalized to the object form remote servers expect. */\ninterface DxSortingInfo {\n readonly selector: unknown;\n readonly desc?: boolean;\n}\n\nfunction normalizeSorting(value: unknown): readonly DxSortingInfo[] {\n const list = Array.isArray(value) ? value : [value];\n return list.map((entry: unknown): DxSortingInfo => {\n if (typeof entry === 'object' && entry !== null && 'selector' in entry) {\n return entry as DxSortingInfo;\n }\n return { selector: entry, desc: false };\n });\n}\n\n/**\n * Serializes `LoadOptions` into the query parameters understood by the\n * DevExtreme.AspNet.Data server libraries — the same wire format the\n * vendor's own `createStore({ loadUrl })` client produces: structured\n * options JSON-encoded (`filter`, `sort`, `group`, `select`, `totalSummary`,\n * `groupSummary`, with string `sort`/`group` entries normalized to\n * `{ selector }` objects), scalars plain (`skip`, `take`,\n * `requireTotalCount`, `requireGroupCount`).\n *\n * ```ts\n * const response = await fetch(`/api/orders?${dxLoadOptionsParams(options)}`, { signal });\n * ```\n */\nexport function dxLoadOptionsParams(loadOptions: LoadOptions): URLSearchParams {\n const params = new URLSearchParams();\n for (const key of ['skip', 'take', 'requireTotalCount', 'requireGroupCount'] as const) {\n const value = loadOptions[key];\n if (value !== undefined && value !== null) {\n params.set(key, String(value));\n }\n }\n for (const key of ['filter', 'select', 'totalSummary', 'groupSummary'] as const) {\n const value = loadOptions[key];\n if (value !== undefined && value !== null) {\n params.set(key, JSON.stringify(value));\n }\n }\n for (const key of ['sort', 'group'] as const) {\n const value = loadOptions[key];\n if (value !== undefined && value !== null) {\n params.set(key, JSON.stringify(normalizeSorting(value)));\n }\n }\n return params;\n}\n","import { Directive, input, model, untracked, type WritableSignal } from '@angular/core';\nimport {\n bindDxState,\n dxOptionAdapter,\n type DxBindingAdapter,\n type DxBindingOptions,\n} from './binding';\nimport { dxStructuralEquals, type DxEqualityFn } from './equality';\nimport type {\n DxHostComponent,\n DxHostOptionName,\n DxInstanceOf,\n} from './types';\n\n/**\n * Abstract base directives for the concrete per-component adapter directives.\n *\n * Each family declares one `model()` whose field name doubles as the binding\n * name (`[(dxValue)]`, `[(dxSelectedRowKeys)]`, ...). Concrete directives only\n * inject their host component and name the widget option — the option name is\n * type-checked against the widget's `Properties`, so a typo or an option that\n * does not exist on that widget fails to compile.\n */\n\n/** Shared plumbing: attaches the family model to a widget option or custom adapter. */\n@Directive()\nexport abstract class DxBindingDirectiveBase {\n protected bindOption<THost extends DxHostComponent, TValue>(\n host: THost,\n optionName: DxHostOptionName<THost>,\n source: WritableSignal<TValue>,\n options?: DxBindingOptions<TValue>,\n ): void {\n bindDxState(\n host,\n source,\n dxOptionAdapter<THost, DxHostOptionName<THost>, TValue>(optionName),\n options,\n );\n }\n\n protected bindAdapter<THost extends DxHostComponent, TValue>(\n host: THost,\n source: WritableSignal<TValue>,\n adapter: DxBindingAdapter<DxInstanceOf<THost>, TValue>,\n options?: DxBindingOptions<TValue>,\n ): void {\n bindDxState(host, source, adapter, options);\n }\n}\n\n/**\n * `[(dxValue)]` — two-way binds an editor's `value` option to a signal.\n * Also exposes:\n * - `dxValueDebounce`: debounce (ms) for the widget → signal direction,\n * - `dxValueEqual`: custom equality to suppress echo updates.\n */\n@Directive()\nexport abstract class DxValueDirectiveBase<\n THost extends DxHostComponent,\n TValue,\n> extends DxBindingDirectiveBase {\n readonly dxValue = model.required<TValue>();\n readonly dxValueDebounce = input(0);\n readonly dxValueEqual = input<DxEqualityFn<TValue> | undefined>(undefined);\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, TValue>(host, optionName, this.dxValue, {\n debounceMs: () => this.dxValueDebounce(),\n equal: (a, b) => (untracked(this.dxValueEqual) ?? dxStructuralEquals)(a, b),\n });\n }\n}\n\n/** `[(dxSelectedRowKeys)]` / `[(dxSelectedItemKeys)]`-style multi-selection bases. */\n@Directive()\nexport abstract class DxSelectedRowKeysDirectiveBase<\n THost extends DxHostComponent,\n TKey,\n> extends DxBindingDirectiveBase {\n readonly dxSelectedRowKeys = model.required<readonly TKey[]>();\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, readonly TKey[]>(host, optionName, this.dxSelectedRowKeys);\n }\n}\n\n@Directive()\nexport abstract class DxSelectedItemKeysDirectiveBase<\n THost extends DxHostComponent,\n TKey,\n> extends DxBindingDirectiveBase {\n readonly dxSelectedItemKeys = model.required<readonly TKey[]>();\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, readonly TKey[]>(host, optionName, this.dxSelectedItemKeys);\n }\n}\n\n/** `[(dxSelectedIndex)]` — for index-based navigation widgets (Tabs, TabPanel, ...). */\n@Directive()\nexport abstract class DxSelectedIndexDirectiveBase<\n THost extends DxHostComponent,\n> extends DxBindingDirectiveBase {\n readonly dxSelectedIndex = model.required<number>();\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, number>(host, optionName, this.dxSelectedIndex);\n }\n}\n\n/** `[(dxVisible)]` — for overlay widgets (Popup, Popover, Toast, ...). */\n@Directive()\nexport abstract class DxVisibleDirectiveBase<\n THost extends DxHostComponent,\n> extends DxBindingDirectiveBase {\n readonly dxVisible = model.required<boolean>();\n\n protected constructor(host: THost, optionName: DxHostOptionName<THost>) {\n super();\n this.bindOption<THost, boolean>(host, optionName, this.dxVisible);\n }\n}\n","/*\n * Public API surface of ngx-devextreme-zoneless/core — the binding engine,\n * type system and directive bases, without any per-widget directives.\n */\n\n// Core type system\nexport type {\n DxWidget,\n DxPropertiesOf,\n DxOptionName,\n DxOptionValue,\n DxEventName,\n DxEventArg,\n DxSubscribable,\n DxHostComponent,\n DxInstanceOf,\n DxHostProperties,\n DxHostOptionName,\n DxHostOptionValue,\n DxHostEventName,\n DxHostEventArg,\n DxHostValue,\n DxHostRef,\n DxOptionChangedArgs,\n DxInitializedArgs,\n} from './lib/types';\n\n// Shared editor value types\nexport type {\n DxDateValue,\n DxDateRange,\n DxNumberRange,\n DxFilterExpression,\n} from './lib/value-types';\n\n// Equality helpers\nexport { dxStructuralEquals, dxShallowObjectEquals } from './lib/equality';\nexport type { DxEqualityFn } from './lib/equality';\n\n// Readiness\nexport { onDxWidgetReady } from './lib/ready';\nexport type { DxWidgetReadyCleanup } from './lib/ready';\n\n// Binding engine (composition API)\nexport { bindDxState, bindDxOption, dxOptionAdapter } from './lib/binding';\nexport type {\n DxAdapterEventName,\n DxBindingAdapter,\n DxBindingOptions,\n DxInitialSync,\n} from './lib/binding';\n\n// Signal factories (composition API)\nexport {\n dxOptionSignal,\n dxEventSignal,\n dxInstanceSignal,\n injectDxInstance,\n} from './lib/signals';\nexport type { DxOptionSignalOptions } from './lib/signals';\n\n// Data loading (signals → DataSource)\nexport { dxArrayStoreSource, dxReloadOn } from './lib/data-source';\nexport type { DxArrayStoreSourceOptions, DxReloadTarget } from './lib/data-source';\n\n// Remote data (resource()-style loading state over a DataSource)\nexport { dxRemoteStore, dxLoadOptionsParams } from './lib/remote';\nexport type { DxRemoteLoader, DxRemoteStore, DxRemoteStoreOptions } from './lib/remote';\n\n// Directive bases (for building adapters for components not covered out of the box)\nexport {\n DxBindingDirectiveBase,\n DxValueDirectiveBase,\n DxSelectedRowKeysDirectiveBase,\n DxSelectedItemKeysDirectiveBase,\n DxSelectedIndexDirectiveBase,\n DxVisibleDirectiveBase,\n} from './lib/bases';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAAA;;;;;;AAMG;AAKH;;;;AAIG;AACG,SAAU,kBAAkB,CAAC,CAAU,EAAE,CAAU,EAAA;IACrD,IAAI,MAAM,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE;AACjB,QAAA,OAAO,IAAI;IACf;IACA,IAAI,CAAC,YAAY,IAAI,IAAI,CAAC,YAAY,IAAI,EAAE;AACxC,QAAA,QACI,CAAC,YAAY,IAAI,IAAI,CAAC,YAAY,IAAI,IAAI,CAAC,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE;IAE7E;AACA,IAAA,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;AACtC,QAAA,QACI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC;AAChB,YAAA,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC;AAChB,YAAA,CAAC,CAAC,MAAM,KAAK,CAAC,CAAC,MAAM;YACrB,CAAC,CAAC,KAAK,CAAC,CAAC,IAAI,EAAE,KAAK,KAAK,kBAAkB,CAAC,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;IAEpE;IACA,IAAI,aAAa,CAAC,CAAC,CAAC,IAAI,aAAa,CAAC,CAAC,CAAC,EAAE;QACtC,MAAM,KAAK,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC;QAC5B,MAAM,KAAK,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC;AAC5B,QAAA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AAA,SAAA,EAAA,iBAAA,EAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAAtB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAD3C;;;ACpHD;;;AAGG;AAgCH;;ACnCA;;AAEG;;;;"}
|
|
@@ -213,24 +213,30 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.1", ngImpor
|
|
|
213
213
|
* Paging lives under the nested `paging` option (`paging.pageIndex`), which
|
|
214
214
|
* option-name typing deliberately does not cover — these adapters go through
|
|
215
215
|
* the `pageIndex()` / `pageSize()` methods instead and listen for the nested
|
|
216
|
-
* option change.
|
|
216
|
+
* option change. They additionally re-read on `contentReady`: paging can
|
|
217
|
+
* change beneath the `paging` option, without any `optionChanged`, when the
|
|
218
|
+
* bound `DataSource` is manipulated directly (`dataSource.pageIndex(0)` +
|
|
219
|
+
* reload — e.g. a `dxRemoteStore` dependency-driven page reset), and
|
|
220
|
+
* `contentReady` is the event the grid fires after rendering any such change.
|
|
217
221
|
*/
|
|
218
222
|
function pageIndexAdapter() {
|
|
219
223
|
return {
|
|
220
|
-
// `optionChanged`
|
|
221
|
-
// because `TInstance` is an unresolved type parameter here.
|
|
222
|
-
events: ['optionChanged'],
|
|
224
|
+
// `optionChanged`/`contentReady` exist on every widget; the cast is
|
|
225
|
+
// only needed because `TInstance` is an unresolved type parameter here.
|
|
226
|
+
events: ['optionChanged', 'contentReady'],
|
|
223
227
|
read: (instance) => instance.pageIndex(),
|
|
224
228
|
write: (instance, value) => void instance.pageIndex(value),
|
|
225
|
-
accept: (
|
|
229
|
+
accept: (eventName, eventArgs) => eventName === 'contentReady' ||
|
|
230
|
+
eventArgs.name === 'paging',
|
|
226
231
|
};
|
|
227
232
|
}
|
|
228
233
|
function pageSizeAdapter() {
|
|
229
234
|
return {
|
|
230
|
-
events: ['optionChanged'],
|
|
235
|
+
events: ['optionChanged', 'contentReady'],
|
|
231
236
|
read: (instance) => instance.pageSize(),
|
|
232
237
|
write: (instance, value) => void instance.pageSize(value),
|
|
233
|
-
accept: (
|
|
238
|
+
accept: (eventName, eventArgs) => eventName === 'contentReady' ||
|
|
239
|
+
eventArgs.name === 'paging',
|
|
234
240
|
};
|
|
235
241
|
}
|
|
236
242
|
/** `[(dxPageIndex)]` for `dx-data-grid` (zero-based). */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-devextreme-zoneless-data.mjs","sources":["../../data/src/lib/data.ts","../../data/src/public-api.ts","../../data/src/ngx-devextreme-zoneless-data.ts"],"sourcesContent":["import { Directive, inject, input, model } from '@angular/core';\nimport { DxDataGridComponent } from 'devextreme-angular/ui/data-grid';\nimport { DxFormComponent } from 'devextreme-angular/ui/form';\nimport { DxGanttComponent } from 'devextreme-angular/ui/gantt';\nimport { DxSchedulerComponent } from 'devextreme-angular/ui/scheduler';\nimport { DxTreeListComponent } from 'devextreme-angular/ui/tree-list';\nimport { DxTreeViewComponent } from 'devextreme-angular/ui/tree-view';\nimport {\n DxBindingDirectiveBase,\n DxSelectedRowKeysDirectiveBase,\n type DxAdapterEventName,\n type DxBindingAdapter,\n type DxDateValue,\n type DxFilterExpression,\n type DxHostOptionValue,\n type DxInstanceOf,\n type DxOptionChangedArgs,\n type DxWidget,\n} from 'ngx-devextreme-zoneless/core';\n\n/** `[(dxSelectedRowKeys)]` for `dx-data-grid`; `TKey` is inferred from your signal. */\n@Directive({ selector: 'dx-data-grid[dxSelectedRowKeys]', exportAs: 'dxSelectedRowKeys' })\nexport class DxDataGridSelectedRowKeysDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxSelectedRowKeysDirectiveBase<DxDataGridComponent<TRowData, TKey>, TKey> {\n constructor() {\n super(inject(DxDataGridComponent, { self: true }), 'selectedRowKeys');\n }\n}\n\n/** `[(dxSelectedRowKeys)]` for `dx-tree-list`. */\n@Directive({ selector: 'dx-tree-list[dxSelectedRowKeys]', exportAs: 'dxSelectedRowKeys' })\nexport class DxTreeListSelectedRowKeysDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxSelectedRowKeysDirectiveBase<DxTreeListComponent<TRowData, TKey>, TKey> {\n constructor() {\n super(inject(DxTreeListComponent, { self: true }), 'selectedRowKeys');\n }\n}\n\n/** `[(dxSelectedRowKey)]` for `dx-gantt` (single selection; `null` clears it). */\n@Directive({ selector: 'dx-gantt[dxSelectedRowKey]', exportAs: 'dxSelectedRowKey' })\nexport class DxGanttSelectedRowKeyDirective<TKey = unknown> extends DxBindingDirectiveBase {\n readonly dxSelectedRowKey = model.required<TKey | null>();\n\n constructor() {\n super();\n this.bindOption<DxGanttComponent, TKey | null>(\n inject(DxGanttComponent, { self: true }),\n 'selectedRowKey',\n this.dxSelectedRowKey,\n );\n }\n}\n\n/** `[(dxCurrentDate)]` for `dx-scheduler`. */\n@Directive({ selector: 'dx-scheduler[dxCurrentDate]', exportAs: 'dxCurrentDate' })\nexport class DxSchedulerCurrentDateDirective extends DxBindingDirectiveBase {\n readonly dxCurrentDate = model.required<DxDateValue>();\n\n constructor() {\n super();\n this.bindOption<DxSchedulerComponent, DxDateValue>(\n inject(DxSchedulerComponent, { self: true }),\n 'currentDate',\n this.dxCurrentDate,\n );\n }\n}\n\n/** The view identifier type of `dx-scheduler` (`'day' | 'week' | ... | string`). */\nexport type DxSchedulerView = Exclude<\n DxHostOptionValue<DxSchedulerComponent, 'currentView'>,\n undefined\n>;\n\n/** `[(dxCurrentView)]` for `dx-scheduler`. */\n@Directive({ selector: 'dx-scheduler[dxCurrentView]', exportAs: 'dxCurrentView' })\nexport class DxSchedulerCurrentViewDirective extends DxBindingDirectiveBase {\n readonly dxCurrentView = model.required<DxSchedulerView>();\n\n constructor() {\n super();\n this.bindOption<DxSchedulerComponent, DxSchedulerView>(\n inject(DxSchedulerComponent, { self: true }),\n 'currentView',\n this.dxCurrentView,\n );\n }\n}\n\n/**\n * `[(dxFormData)]` for `dx-form`.\n *\n * DevExtreme mutates the bound `formData` object in place while the user\n * edits, so the adapter listens to `fieldDataChanged` and emits a *shallow\n * copy* on every change — the signal therefore always yields a fresh\n * reference, which keeps `computed()` consumers and `OnPush`/zoneless views\n * reliably up to date.\n */\n@Directive({ selector: 'dx-form[dxFormData]', exportAs: 'dxFormData' })\nexport class DxFormDataDirective<\n TFormData extends object = Record<string, unknown>,\n> extends DxBindingDirectiveBase {\n readonly dxFormData = model.required<TFormData>();\n\n constructor() {\n super();\n const adapter: DxBindingAdapter<DxInstanceOf<DxFormComponent>, TFormData> = {\n events: ['fieldDataChanged', 'optionChanged'],\n read: (instance) => ({ ...(instance.option('formData') as TFormData) }),\n write: (instance, value) => {\n (instance.option as (name: string, value: unknown) => void)('formData', value);\n },\n accept: (eventName, eventArgs) =>\n eventName !== 'optionChanged' ||\n (eventArgs as DxOptionChangedArgs).name === 'formData',\n };\n this.bindAdapter(inject(DxFormComponent, { self: true }), this.dxFormData, adapter);\n }\n}\n\n/**\n * `[(dxSelectedNodeKeys)]` for `dx-tree-view`.\n *\n * TreeView has no `selectedItemKeys` option, so this adapter is method-based:\n * it reads `getSelectedNodeKeys()` and writes via `unselectAll()` +\n * `selectItem(key)` inside a `beginUpdate()`/`endUpdate()` batch.\n */\n@Directive({ selector: 'dx-tree-view[dxSelectedNodeKeys]', exportAs: 'dxSelectedNodeKeys' })\nexport class DxTreeViewSelectedNodeKeysDirective<\n TItem = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxSelectedNodeKeys = model.required<readonly TKey[]>();\n\n constructor() {\n super();\n type TInstance = DxInstanceOf<DxTreeViewComponent<TItem, TKey>>;\n const adapter: DxBindingAdapter<TInstance, readonly TKey[]> = {\n events: ['selectionChanged'],\n read: (instance) => instance.getSelectedNodeKeys(),\n write: (instance, keys) => {\n instance.beginUpdate();\n try {\n instance.unselectAll();\n for (const key of keys) {\n instance.selectItem(key);\n }\n } finally {\n instance.endUpdate();\n }\n },\n };\n this.bindAdapter<DxTreeViewComponent<TItem, TKey>, readonly TKey[]>(\n inject(DxTreeViewComponent, { self: true }),\n this.dxSelectedNodeKeys,\n adapter,\n );\n }\n}\n\n/* ------------------------------------------------------------------------ *\n * Grid state beyond selection: focused row, filter, paging, layout state\n * ------------------------------------------------------------------------ */\n\n/** `[(dxFocusedRowKey)]` for `dx-data-grid` (requires `focusedRowEnabled`); `null` clears the focus. */\n@Directive({ selector: 'dx-data-grid[dxFocusedRowKey]', exportAs: 'dxFocusedRowKey' })\nexport class DxDataGridFocusedRowKeyDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxFocusedRowKey = model.required<TKey | null>();\n\n constructor() {\n super();\n this.bindOption<DxDataGridComponent<TRowData, TKey>, TKey | null>(\n inject(DxDataGridComponent, { self: true }),\n 'focusedRowKey',\n this.dxFocusedRowKey,\n );\n }\n}\n\n/** `[(dxFocusedRowKey)]` for `dx-tree-list` (requires `focusedRowEnabled`); `null` clears the focus. */\n@Directive({ selector: 'dx-tree-list[dxFocusedRowKey]', exportAs: 'dxFocusedRowKey' })\nexport class DxTreeListFocusedRowKeyDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxFocusedRowKey = model.required<TKey | null>();\n\n constructor() {\n super();\n this.bindOption<DxTreeListComponent<TRowData, TKey>, TKey | null>(\n inject(DxTreeListComponent, { self: true }),\n 'focusedRowKey',\n this.dxFocusedRowKey,\n );\n }\n}\n\n/** `[(dxFilterValue)]` for `dx-data-grid`; `null` clears the filter. */\n@Directive({ selector: 'dx-data-grid[dxFilterValue]', exportAs: 'dxFilterValue' })\nexport class DxDataGridFilterValueDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxFilterValue = model.required<DxFilterExpression | null>();\n\n constructor() {\n super();\n this.bindOption<DxDataGridComponent<TRowData, TKey>, DxFilterExpression | null>(\n inject(DxDataGridComponent, { self: true }),\n 'filterValue',\n this.dxFilterValue,\n );\n }\n}\n\n/** `[(dxFilterValue)]` for `dx-tree-list`; `null` clears the filter. */\n@Directive({ selector: 'dx-tree-list[dxFilterValue]', exportAs: 'dxFilterValue' })\nexport class DxTreeListFilterValueDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxFilterValue = model.required<DxFilterExpression | null>();\n\n constructor() {\n super();\n this.bindOption<DxTreeListComponent<TRowData, TKey>, DxFilterExpression | null>(\n inject(DxTreeListComponent, { self: true }),\n 'filterValue',\n this.dxFilterValue,\n );\n }\n}\n\n/* Structural view of the paging/state APIs shared by dxDataGrid and dxTreeList. */\ninterface GridPagingLike {\n pageIndex(): number;\n pageIndex(newIndex: number): unknown;\n pageSize(): number;\n pageSize(value: number): unknown;\n}\ninterface GridStateLike {\n state(): unknown;\n state(state: unknown): void;\n}\n\n/**\n * Paging lives under the nested `paging` option (`paging.pageIndex`), which\n * option-name typing deliberately does not cover — these adapters go through\n * the `pageIndex()` / `pageSize()` methods instead and listen for the nested\n * option change.\n */\nfunction pageIndexAdapter<TInstance extends DxWidget & GridPagingLike>(): DxBindingAdapter<\n TInstance,\n number\n> {\n return {\n // `optionChanged` exists on every widget; the cast is only needed\n // because `TInstance` is an unresolved type parameter here.\n events: ['optionChanged'] as unknown as readonly DxAdapterEventName<TInstance>[],\n read: (instance) => instance.pageIndex(),\n write: (instance, value) => void instance.pageIndex(value),\n accept: (_eventName, eventArgs) =>\n (eventArgs as DxOptionChangedArgs).name === 'paging',\n };\n}\n\nfunction pageSizeAdapter<TInstance extends DxWidget & GridPagingLike>(): DxBindingAdapter<\n TInstance,\n number\n> {\n return {\n events: ['optionChanged'] as unknown as readonly DxAdapterEventName<TInstance>[],\n read: (instance) => instance.pageSize(),\n write: (instance, value) => void instance.pageSize(value),\n accept: (_eventName, eventArgs) =>\n (eventArgs as DxOptionChangedArgs).name === 'paging',\n };\n}\n\n/** `[(dxPageIndex)]` for `dx-data-grid` (zero-based). */\n@Directive({ selector: 'dx-data-grid[dxPageIndex]', exportAs: 'dxPageIndex' })\nexport class DxDataGridPageIndexDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxPageIndex = model.required<number>();\n\n constructor() {\n super();\n this.bindAdapter<DxDataGridComponent<TRowData, TKey>, number>(\n inject(DxDataGridComponent, { self: true }),\n this.dxPageIndex,\n pageIndexAdapter<DxInstanceOf<DxDataGridComponent<TRowData, TKey>>>(),\n );\n }\n}\n\n/** `[(dxPageIndex)]` for `dx-tree-list` (zero-based). */\n@Directive({ selector: 'dx-tree-list[dxPageIndex]', exportAs: 'dxPageIndex' })\nexport class DxTreeListPageIndexDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxPageIndex = model.required<number>();\n\n constructor() {\n super();\n this.bindAdapter<DxTreeListComponent<TRowData, TKey>, number>(\n inject(DxTreeListComponent, { self: true }),\n this.dxPageIndex,\n pageIndexAdapter<DxInstanceOf<DxTreeListComponent<TRowData, TKey>>>(),\n );\n }\n}\n\n/** `[(dxPageSize)]` for `dx-data-grid`. */\n@Directive({ selector: 'dx-data-grid[dxPageSize]', exportAs: 'dxPageSize' })\nexport class DxDataGridPageSizeDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxPageSize = model.required<number>();\n\n constructor() {\n super();\n this.bindAdapter<DxDataGridComponent<TRowData, TKey>, number>(\n inject(DxDataGridComponent, { self: true }),\n this.dxPageSize,\n pageSizeAdapter<DxInstanceOf<DxDataGridComponent<TRowData, TKey>>>(),\n );\n }\n}\n\n/** `[(dxPageSize)]` for `dx-tree-list`. */\n@Directive({ selector: 'dx-tree-list[dxPageSize]', exportAs: 'dxPageSize' })\nexport class DxTreeListPageSizeDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxPageSize = model.required<number>();\n\n constructor() {\n super();\n this.bindAdapter<DxTreeListComponent<TRowData, TKey>, number>(\n inject(DxTreeListComponent, { self: true }),\n this.dxPageSize,\n pageSizeAdapter<DxInstanceOf<DxTreeListComponent<TRowData, TKey>>>(),\n );\n }\n}\n\n/**\n * A serialized grid layout state as produced by the `state()` method —\n * column order/width/sort, paging, selection, search text, ... The shape is\n * DevExtreme-internal but JSON-serializable by design (it is what\n * `stateStoring` persists).\n */\nexport type DxGridState = Record<string, unknown>;\n\nfunction gridStateAdapter<TInstance extends DxWidget & GridStateLike>(): DxBindingAdapter<\n TInstance,\n DxGridState | null | undefined\n> {\n return {\n // Any option change may affect the persisted state; structural\n // equality drops the reads that turn out not to.\n events: ['optionChanged'] as unknown as readonly DxAdapterEventName<TInstance>[],\n read: (instance) => instance.state() as DxGridState,\n write: (instance, value) => instance.state(value ?? null),\n };\n}\n\n/**\n * `[(dxGridState)]` — two-way binds the full layout state (`state()` /\n * `stateStoring`) of `dx-data-grid` to a signal, e.g. for persisting layouts:\n *\n * - signal `undefined` ⇒ nothing is pushed; the widget's current state is\n * pulled once ready (first run without a saved layout);\n * - signal holding a saved {@link DxGridState} ⇒ the layout is restored;\n * - signal set to `null` ⇒ the grid resets to its default layout.\n *\n * Widget → signal reads are debounced via `dxGridStateDebounce` (default\n * 100 ms) because user interactions can burst option changes.\n */\n@Directive({ selector: 'dx-data-grid[dxGridState]', exportAs: 'dxGridState' })\nexport class DxDataGridStateDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxGridState = model.required<DxGridState | null | undefined>();\n readonly dxGridStateDebounce = input(100);\n\n constructor() {\n super();\n this.bindAdapter<DxDataGridComponent<TRowData, TKey>, DxGridState | null | undefined>(\n inject(DxDataGridComponent, { self: true }),\n this.dxGridState,\n gridStateAdapter<DxInstanceOf<DxDataGridComponent<TRowData, TKey>>>(),\n { debounceMs: () => this.dxGridStateDebounce() },\n );\n }\n}\n\n/** `[(dxGridState)]` for `dx-tree-list` — see {@link DxDataGridStateDirective}. */\n@Directive({ selector: 'dx-tree-list[dxGridState]', exportAs: 'dxGridState' })\nexport class DxTreeListStateDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxGridState = model.required<DxGridState | null | undefined>();\n readonly dxGridStateDebounce = input(100);\n\n constructor() {\n super();\n this.bindAdapter<DxTreeListComponent<TRowData, TKey>, DxGridState | null | undefined>(\n inject(DxTreeListComponent, { self: true }),\n this.dxGridState,\n gridStateAdapter<DxInstanceOf<DxTreeListComponent<TRowData, TKey>>>(),\n { debounceMs: () => this.dxGridStateDebounce() },\n );\n }\n}\n\n/** All data-component adapter directives, for convenient bulk import. */\nexport const DX_DATA_DIRECTIVES = [\n DxDataGridFilterValueDirective,\n DxDataGridFocusedRowKeyDirective,\n DxDataGridPageIndexDirective,\n DxDataGridPageSizeDirective,\n DxDataGridSelectedRowKeysDirective,\n DxDataGridStateDirective,\n DxFormDataDirective,\n DxGanttSelectedRowKeyDirective,\n DxSchedulerCurrentDateDirective,\n DxSchedulerCurrentViewDirective,\n DxTreeListFilterValueDirective,\n DxTreeListFocusedRowKeyDirective,\n DxTreeListPageIndexDirective,\n DxTreeListPageSizeDirective,\n DxTreeListSelectedRowKeysDirective,\n DxTreeListStateDirective,\n DxTreeViewSelectedNodeKeysDirective,\n] as const;\n","/*\n * Public API surface of ngx-devextreme-zoneless/data.\n */\n\nexport * from './lib/data';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;AAoBA;AAEM,MAAO,kCAGX,SAAQ,8BAAyE,CAAA;AAC/E,IAAA,WAAA,GAAA;AACI,QAAA,KAAK,CAAC,MAAM,CAAC,mBAAmB,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,EAAE,iBAAiB,CAAC;IACzE;uGANS,kCAAkC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAlC,kCAAkC,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAA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AA4B;IAC5B,2BAA2B;IAC3B,kCAAkC;IAClC,wBAAwB;IACxB,mCAAmC;;;AChcvC;;AAEG;;ACFH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"ngx-devextreme-zoneless-data.mjs","sources":["../../data/src/lib/data.ts","../../data/src/public-api.ts","../../data/src/ngx-devextreme-zoneless-data.ts"],"sourcesContent":["import { Directive, inject, input, model } from '@angular/core';\nimport { DxDataGridComponent } from 'devextreme-angular/ui/data-grid';\nimport { DxFormComponent } from 'devextreme-angular/ui/form';\nimport { DxGanttComponent } from 'devextreme-angular/ui/gantt';\nimport { DxSchedulerComponent } from 'devextreme-angular/ui/scheduler';\nimport { DxTreeListComponent } from 'devextreme-angular/ui/tree-list';\nimport { DxTreeViewComponent } from 'devextreme-angular/ui/tree-view';\nimport {\n DxBindingDirectiveBase,\n DxSelectedRowKeysDirectiveBase,\n type DxAdapterEventName,\n type DxBindingAdapter,\n type DxDateValue,\n type DxFilterExpression,\n type DxHostOptionValue,\n type DxInstanceOf,\n type DxOptionChangedArgs,\n type DxWidget,\n} from 'ngx-devextreme-zoneless/core';\n\n/** `[(dxSelectedRowKeys)]` for `dx-data-grid`; `TKey` is inferred from your signal. */\n@Directive({ selector: 'dx-data-grid[dxSelectedRowKeys]', exportAs: 'dxSelectedRowKeys' })\nexport class DxDataGridSelectedRowKeysDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxSelectedRowKeysDirectiveBase<DxDataGridComponent<TRowData, TKey>, TKey> {\n constructor() {\n super(inject(DxDataGridComponent, { self: true }), 'selectedRowKeys');\n }\n}\n\n/** `[(dxSelectedRowKeys)]` for `dx-tree-list`. */\n@Directive({ selector: 'dx-tree-list[dxSelectedRowKeys]', exportAs: 'dxSelectedRowKeys' })\nexport class DxTreeListSelectedRowKeysDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxSelectedRowKeysDirectiveBase<DxTreeListComponent<TRowData, TKey>, TKey> {\n constructor() {\n super(inject(DxTreeListComponent, { self: true }), 'selectedRowKeys');\n }\n}\n\n/** `[(dxSelectedRowKey)]` for `dx-gantt` (single selection; `null` clears it). */\n@Directive({ selector: 'dx-gantt[dxSelectedRowKey]', exportAs: 'dxSelectedRowKey' })\nexport class DxGanttSelectedRowKeyDirective<TKey = unknown> extends DxBindingDirectiveBase {\n readonly dxSelectedRowKey = model.required<TKey | null>();\n\n constructor() {\n super();\n this.bindOption<DxGanttComponent, TKey | null>(\n inject(DxGanttComponent, { self: true }),\n 'selectedRowKey',\n this.dxSelectedRowKey,\n );\n }\n}\n\n/** `[(dxCurrentDate)]` for `dx-scheduler`. */\n@Directive({ selector: 'dx-scheduler[dxCurrentDate]', exportAs: 'dxCurrentDate' })\nexport class DxSchedulerCurrentDateDirective extends DxBindingDirectiveBase {\n readonly dxCurrentDate = model.required<DxDateValue>();\n\n constructor() {\n super();\n this.bindOption<DxSchedulerComponent, DxDateValue>(\n inject(DxSchedulerComponent, { self: true }),\n 'currentDate',\n this.dxCurrentDate,\n );\n }\n}\n\n/** The view identifier type of `dx-scheduler` (`'day' | 'week' | ... | string`). */\nexport type DxSchedulerView = Exclude<\n DxHostOptionValue<DxSchedulerComponent, 'currentView'>,\n undefined\n>;\n\n/** `[(dxCurrentView)]` for `dx-scheduler`. */\n@Directive({ selector: 'dx-scheduler[dxCurrentView]', exportAs: 'dxCurrentView' })\nexport class DxSchedulerCurrentViewDirective extends DxBindingDirectiveBase {\n readonly dxCurrentView = model.required<DxSchedulerView>();\n\n constructor() {\n super();\n this.bindOption<DxSchedulerComponent, DxSchedulerView>(\n inject(DxSchedulerComponent, { self: true }),\n 'currentView',\n this.dxCurrentView,\n );\n }\n}\n\n/**\n * `[(dxFormData)]` for `dx-form`.\n *\n * DevExtreme mutates the bound `formData` object in place while the user\n * edits, so the adapter listens to `fieldDataChanged` and emits a *shallow\n * copy* on every change — the signal therefore always yields a fresh\n * reference, which keeps `computed()` consumers and `OnPush`/zoneless views\n * reliably up to date.\n */\n@Directive({ selector: 'dx-form[dxFormData]', exportAs: 'dxFormData' })\nexport class DxFormDataDirective<\n TFormData extends object = Record<string, unknown>,\n> extends DxBindingDirectiveBase {\n readonly dxFormData = model.required<TFormData>();\n\n constructor() {\n super();\n const adapter: DxBindingAdapter<DxInstanceOf<DxFormComponent>, TFormData> = {\n events: ['fieldDataChanged', 'optionChanged'],\n read: (instance) => ({ ...(instance.option('formData') as TFormData) }),\n write: (instance, value) => {\n (instance.option as (name: string, value: unknown) => void)('formData', value);\n },\n accept: (eventName, eventArgs) =>\n eventName !== 'optionChanged' ||\n (eventArgs as DxOptionChangedArgs).name === 'formData',\n };\n this.bindAdapter(inject(DxFormComponent, { self: true }), this.dxFormData, adapter);\n }\n}\n\n/**\n * `[(dxSelectedNodeKeys)]` for `dx-tree-view`.\n *\n * TreeView has no `selectedItemKeys` option, so this adapter is method-based:\n * it reads `getSelectedNodeKeys()` and writes via `unselectAll()` +\n * `selectItem(key)` inside a `beginUpdate()`/`endUpdate()` batch.\n */\n@Directive({ selector: 'dx-tree-view[dxSelectedNodeKeys]', exportAs: 'dxSelectedNodeKeys' })\nexport class DxTreeViewSelectedNodeKeysDirective<\n TItem = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxSelectedNodeKeys = model.required<readonly TKey[]>();\n\n constructor() {\n super();\n type TInstance = DxInstanceOf<DxTreeViewComponent<TItem, TKey>>;\n const adapter: DxBindingAdapter<TInstance, readonly TKey[]> = {\n events: ['selectionChanged'],\n read: (instance) => instance.getSelectedNodeKeys(),\n write: (instance, keys) => {\n instance.beginUpdate();\n try {\n instance.unselectAll();\n for (const key of keys) {\n instance.selectItem(key);\n }\n } finally {\n instance.endUpdate();\n }\n },\n };\n this.bindAdapter<DxTreeViewComponent<TItem, TKey>, readonly TKey[]>(\n inject(DxTreeViewComponent, { self: true }),\n this.dxSelectedNodeKeys,\n adapter,\n );\n }\n}\n\n/* ------------------------------------------------------------------------ *\n * Grid state beyond selection: focused row, filter, paging, layout state\n * ------------------------------------------------------------------------ */\n\n/** `[(dxFocusedRowKey)]` for `dx-data-grid` (requires `focusedRowEnabled`); `null` clears the focus. */\n@Directive({ selector: 'dx-data-grid[dxFocusedRowKey]', exportAs: 'dxFocusedRowKey' })\nexport class DxDataGridFocusedRowKeyDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxFocusedRowKey = model.required<TKey | null>();\n\n constructor() {\n super();\n this.bindOption<DxDataGridComponent<TRowData, TKey>, TKey | null>(\n inject(DxDataGridComponent, { self: true }),\n 'focusedRowKey',\n this.dxFocusedRowKey,\n );\n }\n}\n\n/** `[(dxFocusedRowKey)]` for `dx-tree-list` (requires `focusedRowEnabled`); `null` clears the focus. */\n@Directive({ selector: 'dx-tree-list[dxFocusedRowKey]', exportAs: 'dxFocusedRowKey' })\nexport class DxTreeListFocusedRowKeyDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxFocusedRowKey = model.required<TKey | null>();\n\n constructor() {\n super();\n this.bindOption<DxTreeListComponent<TRowData, TKey>, TKey | null>(\n inject(DxTreeListComponent, { self: true }),\n 'focusedRowKey',\n this.dxFocusedRowKey,\n );\n }\n}\n\n/** `[(dxFilterValue)]` for `dx-data-grid`; `null` clears the filter. */\n@Directive({ selector: 'dx-data-grid[dxFilterValue]', exportAs: 'dxFilterValue' })\nexport class DxDataGridFilterValueDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxFilterValue = model.required<DxFilterExpression | null>();\n\n constructor() {\n super();\n this.bindOption<DxDataGridComponent<TRowData, TKey>, DxFilterExpression | null>(\n inject(DxDataGridComponent, { self: true }),\n 'filterValue',\n this.dxFilterValue,\n );\n }\n}\n\n/** `[(dxFilterValue)]` for `dx-tree-list`; `null` clears the filter. */\n@Directive({ selector: 'dx-tree-list[dxFilterValue]', exportAs: 'dxFilterValue' })\nexport class DxTreeListFilterValueDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxFilterValue = model.required<DxFilterExpression | null>();\n\n constructor() {\n super();\n this.bindOption<DxTreeListComponent<TRowData, TKey>, DxFilterExpression | null>(\n inject(DxTreeListComponent, { self: true }),\n 'filterValue',\n this.dxFilterValue,\n );\n }\n}\n\n/* Structural view of the paging/state APIs shared by dxDataGrid and dxTreeList. */\ninterface GridPagingLike {\n pageIndex(): number;\n pageIndex(newIndex: number): unknown;\n pageSize(): number;\n pageSize(value: number): unknown;\n}\ninterface GridStateLike {\n state(): unknown;\n state(state: unknown): void;\n}\n\n/**\n * Paging lives under the nested `paging` option (`paging.pageIndex`), which\n * option-name typing deliberately does not cover — these adapters go through\n * the `pageIndex()` / `pageSize()` methods instead and listen for the nested\n * option change. They additionally re-read on `contentReady`: paging can\n * change beneath the `paging` option, without any `optionChanged`, when the\n * bound `DataSource` is manipulated directly (`dataSource.pageIndex(0)` +\n * reload — e.g. a `dxRemoteStore` dependency-driven page reset), and\n * `contentReady` is the event the grid fires after rendering any such change.\n */\nfunction pageIndexAdapter<TInstance extends DxWidget & GridPagingLike>(): DxBindingAdapter<\n TInstance,\n number\n> {\n return {\n // `optionChanged`/`contentReady` exist on every widget; the cast is\n // only needed because `TInstance` is an unresolved type parameter here.\n events: ['optionChanged', 'contentReady'] as unknown as readonly DxAdapterEventName<TInstance>[],\n read: (instance) => instance.pageIndex(),\n write: (instance, value) => void instance.pageIndex(value),\n accept: (eventName, eventArgs) =>\n (eventName as string) === 'contentReady' ||\n (eventArgs as DxOptionChangedArgs).name === 'paging',\n };\n}\n\nfunction pageSizeAdapter<TInstance extends DxWidget & GridPagingLike>(): DxBindingAdapter<\n TInstance,\n number\n> {\n return {\n events: ['optionChanged', 'contentReady'] as unknown as readonly DxAdapterEventName<TInstance>[],\n read: (instance) => instance.pageSize(),\n write: (instance, value) => void instance.pageSize(value),\n accept: (eventName, eventArgs) =>\n (eventName as string) === 'contentReady' ||\n (eventArgs as DxOptionChangedArgs).name === 'paging',\n };\n}\n\n/** `[(dxPageIndex)]` for `dx-data-grid` (zero-based). */\n@Directive({ selector: 'dx-data-grid[dxPageIndex]', exportAs: 'dxPageIndex' })\nexport class DxDataGridPageIndexDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxPageIndex = model.required<number>();\n\n constructor() {\n super();\n this.bindAdapter<DxDataGridComponent<TRowData, TKey>, number>(\n inject(DxDataGridComponent, { self: true }),\n this.dxPageIndex,\n pageIndexAdapter<DxInstanceOf<DxDataGridComponent<TRowData, TKey>>>(),\n );\n }\n}\n\n/** `[(dxPageIndex)]` for `dx-tree-list` (zero-based). */\n@Directive({ selector: 'dx-tree-list[dxPageIndex]', exportAs: 'dxPageIndex' })\nexport class DxTreeListPageIndexDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxPageIndex = model.required<number>();\n\n constructor() {\n super();\n this.bindAdapter<DxTreeListComponent<TRowData, TKey>, number>(\n inject(DxTreeListComponent, { self: true }),\n this.dxPageIndex,\n pageIndexAdapter<DxInstanceOf<DxTreeListComponent<TRowData, TKey>>>(),\n );\n }\n}\n\n/** `[(dxPageSize)]` for `dx-data-grid`. */\n@Directive({ selector: 'dx-data-grid[dxPageSize]', exportAs: 'dxPageSize' })\nexport class DxDataGridPageSizeDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxPageSize = model.required<number>();\n\n constructor() {\n super();\n this.bindAdapter<DxDataGridComponent<TRowData, TKey>, number>(\n inject(DxDataGridComponent, { self: true }),\n this.dxPageSize,\n pageSizeAdapter<DxInstanceOf<DxDataGridComponent<TRowData, TKey>>>(),\n );\n }\n}\n\n/** `[(dxPageSize)]` for `dx-tree-list`. */\n@Directive({ selector: 'dx-tree-list[dxPageSize]', exportAs: 'dxPageSize' })\nexport class DxTreeListPageSizeDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxPageSize = model.required<number>();\n\n constructor() {\n super();\n this.bindAdapter<DxTreeListComponent<TRowData, TKey>, number>(\n inject(DxTreeListComponent, { self: true }),\n this.dxPageSize,\n pageSizeAdapter<DxInstanceOf<DxTreeListComponent<TRowData, TKey>>>(),\n );\n }\n}\n\n/**\n * A serialized grid layout state as produced by the `state()` method —\n * column order/width/sort, paging, selection, search text, ... The shape is\n * DevExtreme-internal but JSON-serializable by design (it is what\n * `stateStoring` persists).\n */\nexport type DxGridState = Record<string, unknown>;\n\nfunction gridStateAdapter<TInstance extends DxWidget & GridStateLike>(): DxBindingAdapter<\n TInstance,\n DxGridState | null | undefined\n> {\n return {\n // Any option change may affect the persisted state; structural\n // equality drops the reads that turn out not to.\n events: ['optionChanged'] as unknown as readonly DxAdapterEventName<TInstance>[],\n read: (instance) => instance.state() as DxGridState,\n write: (instance, value) => instance.state(value ?? null),\n };\n}\n\n/**\n * `[(dxGridState)]` — two-way binds the full layout state (`state()` /\n * `stateStoring`) of `dx-data-grid` to a signal, e.g. for persisting layouts:\n *\n * - signal `undefined` ⇒ nothing is pushed; the widget's current state is\n * pulled once ready (first run without a saved layout);\n * - signal holding a saved {@link DxGridState} ⇒ the layout is restored;\n * - signal set to `null` ⇒ the grid resets to its default layout.\n *\n * Widget → signal reads are debounced via `dxGridStateDebounce` (default\n * 100 ms) because user interactions can burst option changes.\n */\n@Directive({ selector: 'dx-data-grid[dxGridState]', exportAs: 'dxGridState' })\nexport class DxDataGridStateDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxGridState = model.required<DxGridState | null | undefined>();\n readonly dxGridStateDebounce = input(100);\n\n constructor() {\n super();\n this.bindAdapter<DxDataGridComponent<TRowData, TKey>, DxGridState | null | undefined>(\n inject(DxDataGridComponent, { self: true }),\n this.dxGridState,\n gridStateAdapter<DxInstanceOf<DxDataGridComponent<TRowData, TKey>>>(),\n { debounceMs: () => this.dxGridStateDebounce() },\n );\n }\n}\n\n/** `[(dxGridState)]` for `dx-tree-list` — see {@link DxDataGridStateDirective}. */\n@Directive({ selector: 'dx-tree-list[dxGridState]', exportAs: 'dxGridState' })\nexport class DxTreeListStateDirective<\n TRowData = unknown,\n TKey = unknown,\n> extends DxBindingDirectiveBase {\n readonly dxGridState = model.required<DxGridState | null | undefined>();\n readonly dxGridStateDebounce = input(100);\n\n constructor() {\n super();\n this.bindAdapter<DxTreeListComponent<TRowData, TKey>, DxGridState | null | undefined>(\n inject(DxTreeListComponent, { self: true }),\n this.dxGridState,\n gridStateAdapter<DxInstanceOf<DxTreeListComponent<TRowData, TKey>>>(),\n { debounceMs: () => this.dxGridStateDebounce() },\n );\n }\n}\n\n/** All data-component adapter directives, for convenient bulk import. */\nexport const DX_DATA_DIRECTIVES = [\n DxDataGridFilterValueDirective,\n DxDataGridFocusedRowKeyDirective,\n DxDataGridPageIndexDirective,\n DxDataGridPageSizeDirective,\n DxDataGridSelectedRowKeysDirective,\n DxDataGridStateDirective,\n DxFormDataDirective,\n DxGanttSelectedRowKeyDirective,\n DxSchedulerCurrentDateDirective,\n DxSchedulerCurrentViewDirective,\n DxTreeListFilterValueDirective,\n DxTreeListFocusedRowKeyDirective,\n DxTreeListPageIndexDirective,\n DxTreeListPageSizeDirective,\n DxTreeListSelectedRowKeysDirective,\n DxTreeListStateDirective,\n DxTreeViewSelectedNodeKeysDirective,\n] as const;\n","/*\n * Public API surface of ngx-devextreme-zoneless/data.\n */\n\nexport * from './lib/data';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;AAoBA;AAEM,MAAO,kCAGX,SAAQ,8BAAyE,CAAA;AAC/E,IAAA,WAAA,GAAA;AACI,QAAA,KAAK,CAAC,MAAM,CAAC,mBAAmB,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,EAAE,iBAAiB,CAAC;IACzE;uGANS,kCAAkC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA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AAgC;IAChC,4BAA4B;IAC5B,2BAA2B;IAC3B,kCAAkC;IAClC,wBAAwB;IACxB,mBAAmB;IACnB,8BAA8B;IAC9B,+BAA+B;IAC/B,+BAA+B;IAC/B,8BAA8B;IAC9B,gCAAgC;IAChC,4BAA4B;IAC5B,2BAA2B;IAC3B,kCAAkC;IAClC,wBAAwB;IACxB,mCAAmC;;;ACtcvC;;AAEG;;ACFH;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -2,6 +2,7 @@ import { Component } from 'devextreme/core/component';
|
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
import { Injector, WritableSignal, Signal, ProviderToken } from '@angular/core';
|
|
4
4
|
import DataSource from 'devextreme/data/data_source';
|
|
5
|
+
import { LoadOptions, LoadResult } from 'devextreme/common/data';
|
|
5
6
|
|
|
6
7
|
/**
|
|
7
8
|
* Core structural typings that connect the three worlds involved in a binding:
|
|
@@ -386,6 +387,130 @@ type DxReloadTarget = {
|
|
|
386
387
|
*/
|
|
387
388
|
declare function dxReloadOn(target: DxReloadTarget, dependencies: readonly Signal<unknown>[], injector?: Injector): void;
|
|
388
389
|
|
|
390
|
+
/**
|
|
391
|
+
* Remote data with `resource()` vocabulary: {@link dxRemoteStore} wraps a
|
|
392
|
+
* consumer-supplied load function in a DevExtreme `DataSource` and exposes
|
|
393
|
+
* the loading state the widget cannot show for you — `isLoading` and `error`
|
|
394
|
+
* as signals for outside-the-widget UI, `reload()` for retries, dependency
|
|
395
|
+
* signals for query state that lives outside the widget (search boxes,
|
|
396
|
+
* master selections), and an `AbortSignal` per load so superseded requests
|
|
397
|
+
* are actually cancelled instead of racing the newest one.
|
|
398
|
+
*/
|
|
399
|
+
/**
|
|
400
|
+
* A remote load function: receives the widget-produced `LoadOptions`
|
|
401
|
+
* (filter/sort/group/skip/take/…) and an `AbortSignal` that fires when the
|
|
402
|
+
* load is superseded or the owning injector is destroyed. Resolve to
|
|
403
|
+
* DevExtreme's `LoadResult` — either a plain array or
|
|
404
|
+
* `{ data, totalCount, summary, groupCount }`.
|
|
405
|
+
*/
|
|
406
|
+
type DxRemoteLoader<TItem> = (loadOptions: LoadOptions<TItem>, abortSignal: AbortSignal) => PromiseLike<LoadResult<TItem>>;
|
|
407
|
+
/** Options for {@link dxRemoteStore}. */
|
|
408
|
+
interface DxRemoteStoreOptions<TItem, TKey> {
|
|
409
|
+
/** Loads one page of data. See {@link DxRemoteLoader}. */
|
|
410
|
+
readonly load: DxRemoteLoader<TItem>;
|
|
411
|
+
/**
|
|
412
|
+
* Resolves a single item by key — required for lookup editors
|
|
413
|
+
* (`dx-select-box`, `dx-lookup`, …) that must display a value set
|
|
414
|
+
* programmatically before/without loading the containing page. Against a
|
|
415
|
+
* DevExtreme.AspNet.Data endpoint this is a filtered load:
|
|
416
|
+
* `load({ filter: ['id', '=', key], take: 1 })`, taking the first item.
|
|
417
|
+
* `byKey` activity does not drive `isLoading`/`error` — its failures
|
|
418
|
+
* surface through the requesting widget.
|
|
419
|
+
*/
|
|
420
|
+
readonly byKey?: (key: TKey, abortSignal: AbortSignal) => PromiseLike<TItem>;
|
|
421
|
+
/** Key expression handed to the underlying store (replaces `keyExpr` on the widget). */
|
|
422
|
+
readonly key?: string | string[];
|
|
423
|
+
/**
|
|
424
|
+
* Query dependencies: when any of these signals changes, the store
|
|
425
|
+
* resets to the first page and reloads (the dependencies describe the
|
|
426
|
+
* query, so a change starts a new result set — mirroring `DataSource`'s
|
|
427
|
+
* own `filter()` semantics). The load function reads the current values
|
|
428
|
+
* itself, via `untracked`.
|
|
429
|
+
*/
|
|
430
|
+
readonly deps?: readonly Signal<unknown>[];
|
|
431
|
+
/**
|
|
432
|
+
* Debounce for dependency-driven reloads in milliseconds (e.g. a search
|
|
433
|
+
* signal fed from keystrokes). Manual `reload()` is never debounced.
|
|
434
|
+
*/
|
|
435
|
+
readonly debounce?: number;
|
|
436
|
+
/** Explicit injector when called outside an injection context. */
|
|
437
|
+
readonly injector?: Injector;
|
|
438
|
+
}
|
|
439
|
+
/** The handle returned by {@link dxRemoteStore}. */
|
|
440
|
+
interface DxRemoteStore<TItem, TKey = unknown> {
|
|
441
|
+
/** Bind this to any `[dataSource]` input. Disposed on injector destroy. */
|
|
442
|
+
readonly dataSource: DataSource<TItem, TKey>;
|
|
443
|
+
/** `true` while at least one load is in flight — for UI outside the widget. */
|
|
444
|
+
readonly isLoading: Signal<boolean>;
|
|
445
|
+
/**
|
|
446
|
+
* The rejection reason of the most recent settled load, or `undefined`
|
|
447
|
+
* after a successful load. Superseded (aborted) loads never write here.
|
|
448
|
+
* The widget additionally shows its own load-error UI; this signal is for
|
|
449
|
+
* error/retry UI outside the widget.
|
|
450
|
+
*/
|
|
451
|
+
readonly error: Signal<unknown>;
|
|
452
|
+
/**
|
|
453
|
+
* Refetches the current query: cancels in-flight loads (DataSource
|
|
454
|
+
* operation + transport `AbortSignal`), keeps the current page, and
|
|
455
|
+
* resolves when the reload settles. Failures land in `error`, so the
|
|
456
|
+
* returned promise never rejects.
|
|
457
|
+
*/
|
|
458
|
+
reload(): Promise<void>;
|
|
459
|
+
}
|
|
460
|
+
/**
|
|
461
|
+
* Wraps a remote load function in a DevExtreme `DataSource` with signal-based
|
|
462
|
+
* loading state:
|
|
463
|
+
*
|
|
464
|
+
* ```ts
|
|
465
|
+
* readonly search = signal('');
|
|
466
|
+
* readonly orders = dxRemoteStore<Order, number>({
|
|
467
|
+
* key: 'id',
|
|
468
|
+
* deps: [this.search],
|
|
469
|
+
* debounce: 300,
|
|
470
|
+
* load: async (options, signal) => {
|
|
471
|
+
* const params = dxLoadOptionsParams(options);
|
|
472
|
+
* params.set('search', untracked(this.search));
|
|
473
|
+
* const response = await fetch(`/api/orders?${params}`, { signal });
|
|
474
|
+
* if (!response.ok) throw new Error(`orders load failed: ${response.status}`);
|
|
475
|
+
* return response.json();
|
|
476
|
+
* },
|
|
477
|
+
* });
|
|
478
|
+
* // <dx-data-grid [dataSource]="orders.dataSource" [remoteOperations]="true" />
|
|
479
|
+
* // @if (orders.error()) { <button (click)="orders.reload()">retry</button> }
|
|
480
|
+
* ```
|
|
481
|
+
*
|
|
482
|
+
* Semantics, aligned with Angular's `resource()`:
|
|
483
|
+
* - every load gets an `AbortSignal`; a reload (dependency-driven or manual)
|
|
484
|
+
* aborts whatever is still in flight — last write wins, stale responses
|
|
485
|
+
* never overwrite newer ones and never surface stale errors;
|
|
486
|
+
* - `error` reflects the most recent settled load and is cleared by the next
|
|
487
|
+
* successful one; `reload()` is the retry;
|
|
488
|
+
* - dependency changes reset to page 0 (a new query is a new result set);
|
|
489
|
+
* manual `reload()` keeps the page (same query, fresh data);
|
|
490
|
+
* - widget search options are folded into `LoadOptions.filter` before `load`
|
|
491
|
+
* runs (`useDefaultSearch`, matching the vendor's own remote client), so
|
|
492
|
+
* the load function only ever deals in filter expressions.
|
|
493
|
+
*
|
|
494
|
+
* The store is load-only by design: create/update/delete intentionally stay
|
|
495
|
+
* out of this API — pass a full `CustomStore` to the widget where you need
|
|
496
|
+
* editing.
|
|
497
|
+
*/
|
|
498
|
+
declare function dxRemoteStore<TItem, TKey = unknown>(options: DxRemoteStoreOptions<TItem, TKey>): DxRemoteStore<TItem, TKey>;
|
|
499
|
+
/**
|
|
500
|
+
* Serializes `LoadOptions` into the query parameters understood by the
|
|
501
|
+
* DevExtreme.AspNet.Data server libraries — the same wire format the
|
|
502
|
+
* vendor's own `createStore({ loadUrl })` client produces: structured
|
|
503
|
+
* options JSON-encoded (`filter`, `sort`, `group`, `select`, `totalSummary`,
|
|
504
|
+
* `groupSummary`, with string `sort`/`group` entries normalized to
|
|
505
|
+
* `{ selector }` objects), scalars plain (`skip`, `take`,
|
|
506
|
+
* `requireTotalCount`, `requireGroupCount`).
|
|
507
|
+
*
|
|
508
|
+
* ```ts
|
|
509
|
+
* const response = await fetch(`/api/orders?${dxLoadOptionsParams(options)}`, { signal });
|
|
510
|
+
* ```
|
|
511
|
+
*/
|
|
512
|
+
declare function dxLoadOptionsParams(loadOptions: LoadOptions): URLSearchParams;
|
|
513
|
+
|
|
389
514
|
/**
|
|
390
515
|
* Abstract base directives for the concrete per-component adapter directives.
|
|
391
516
|
*
|
|
@@ -444,6 +569,6 @@ declare abstract class DxVisibleDirectiveBase<THost extends DxHostComponent> ext
|
|
|
444
569
|
static ɵdir: i0.ɵɵDirectiveDeclaration<DxVisibleDirectiveBase<any>, never, never, { "dxVisible": { "alias": "dxVisible"; "required": true; "isSignal": true; }; }, { "dxVisible": "dxVisibleChange"; }, never, never, true, never>;
|
|
445
570
|
}
|
|
446
571
|
|
|
447
|
-
export { DxBindingDirectiveBase, DxSelectedIndexDirectiveBase, DxSelectedItemKeysDirectiveBase, DxSelectedRowKeysDirectiveBase, DxValueDirectiveBase, DxVisibleDirectiveBase, bindDxOption, bindDxState, dxArrayStoreSource, dxEventSignal, dxInstanceSignal, dxOptionAdapter, dxOptionSignal, dxReloadOn, dxShallowObjectEquals, dxStructuralEquals, injectDxInstance, onDxWidgetReady };
|
|
448
|
-
export type { DxAdapterEventName, DxArrayStoreSourceOptions, DxBindingAdapter, DxBindingOptions, DxDateRange, DxDateValue, DxEqualityFn, DxEventArg, DxEventName, DxFilterExpression, DxHostComponent, DxHostEventArg, DxHostEventName, DxHostOptionName, DxHostOptionValue, DxHostProperties, DxHostRef, DxHostValue, DxInitialSync, DxInitializedArgs, DxInstanceOf, DxNumberRange, DxOptionChangedArgs, DxOptionName, DxOptionSignalOptions, DxOptionValue, DxPropertiesOf, DxReloadTarget, DxSubscribable, DxWidget, DxWidgetReadyCleanup };
|
|
572
|
+
export { DxBindingDirectiveBase, DxSelectedIndexDirectiveBase, DxSelectedItemKeysDirectiveBase, DxSelectedRowKeysDirectiveBase, DxValueDirectiveBase, DxVisibleDirectiveBase, bindDxOption, bindDxState, dxArrayStoreSource, dxEventSignal, dxInstanceSignal, dxLoadOptionsParams, dxOptionAdapter, dxOptionSignal, dxReloadOn, dxRemoteStore, dxShallowObjectEquals, dxStructuralEquals, injectDxInstance, onDxWidgetReady };
|
|
573
|
+
export type { DxAdapterEventName, DxArrayStoreSourceOptions, DxBindingAdapter, DxBindingOptions, DxDateRange, DxDateValue, DxEqualityFn, DxEventArg, DxEventName, DxFilterExpression, DxHostComponent, DxHostEventArg, DxHostEventName, DxHostOptionName, DxHostOptionValue, DxHostProperties, DxHostRef, DxHostValue, DxInitialSync, DxInitializedArgs, DxInstanceOf, DxNumberRange, DxOptionChangedArgs, DxOptionName, DxOptionSignalOptions, DxOptionValue, DxPropertiesOf, DxReloadTarget, DxRemoteLoader, DxRemoteStore, DxRemoteStoreOptions, DxSubscribable, DxWidget, DxWidgetReadyCleanup };
|
|
449
574
|
//# sourceMappingURL=ngx-devextreme-zoneless-core.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-devextreme-zoneless-core.d.ts","sources":["../../core/src/lib/types.ts","../../core/src/lib/value-types.ts","../../core/src/lib/equality.ts","../../core/src/lib/ready.ts","../../core/src/lib/binding.ts","../../core/src/lib/signals.ts","../../core/src/lib/data-source.ts","../../core/src/lib/bases.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"ngx-devextreme-zoneless-core.d.ts","sources":["../../core/src/lib/types.ts","../../core/src/lib/value-types.ts","../../core/src/lib/equality.ts","../../core/src/lib/ready.ts","../../core/src/lib/binding.ts","../../core/src/lib/signals.ts","../../core/src/lib/data-source.ts","../../core/src/lib/remote.ts","../../core/src/lib/bases.ts"],"mappings":";;;;;;AAAA;;;;;;;;;;;AAWG;;AAOH;;;;AAIG;AACG,KAAM,QAAQ,yBAAyBA,SAAe;AAE5D;KACY,cAAc,gCACJA,SAAe;AAErC;;;;;;AAMG;KACS,YAAY,gBAAgB,OAAO;AAE/C;KACY,aAAa,4BAEP,YAAY;AAG9B;;;;AAIG;AACG,KAAM,WAAW;wEAEb,YAAY;AAErB;AAGD;AACM,KAAM,UAAU,6BAEH,WAAW,sBACrB,UAAU,8DACb,WAAW;AASjB;AACM,UAAW,cAAc;;;;AAE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AAA;2BACHA,EAAA,CAAA,WAAA,CAAA,YAAA;mDAE0B,gBAAgB;yCAR7C,oBAAoB;2CAApB,oBAAoB;AAezC;AAED;AACA,uBACsB,8BAA8B,eAClC,eAAe,gBAEvB,sBAAsB;gCACFA,EAAA,CAAA,WAAA;mDAEqB,gBAAgB;yCAN7C,8BAA8B;2CAA9B,8BAA8B;AAUnD;AAED,uBACsB,+BAA+B,eACnC,eAAe,gBAEvB,sBAAsB;iCACDA,EAAA,CAAA,WAAA;mDAEoB,gBAAgB;yCAN7C,+BAA+B;2CAA/B,+BAA+B;AAUpD;AAED;AACA,uBACsB,4BAA4B,eAChC,eAAe,UACvB,sBAAsB;8BACJA,EAAA,CAAA,WAAA;mDAEuB,gBAAgB;yCAL7C,4BAA4B;2CAA5B,4BAA4B;AASjD;AAED;AACA,uBACsB,sBAAsB,eAC1B,eAAe,UACvB,sBAAsB;wBACVA,EAAA,CAAA,WAAA;mDAE6B,gBAAgB;yCAL7C,sBAAsB;2CAAtB,sBAAsB;AAS3C;;;;","names":["DxCoreComponent","_angular_core"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-devextreme-zoneless-data.d.ts","sources":["../../data/src/lib/data.ts"],"mappings":";;;;;;AAoBA;AACA,cACa,kCAAkC,6CAGrC,8BAA8B,CAAC,mBAAmB;;yCAH/C,kCAAkC;2CAAlC,kCAAkC;AAO9C;AAED;AACA,cACa,kCAAkC,6CAGrC,8BAA8B,CAAC,mBAAmB;;yCAH/C,kCAAkC;2CAAlC,kCAAkC;AAO9C;AAED;AACA,cACa,8BAA8B,yBAAyB,sBAAsB;+BAC7DA,EAAA,CAAA,WAAA;;yCADhB,8BAA8B;2CAA9B,8BAA8B;AAW1C;AAED;AACA,cACa,+BAAgC,SAAQ,sBAAsB;4BACjDA,EAAA,CAAA,WAAA,CAAA,WAAA;;yCADb,+BAA+B;2CAA/B,+BAA+B;AAW3C;AAED;AACM,KAAM,eAAe,GAAG,OAAO,CACjC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