Skip to content

Commit a7db908

Browse files
authored
feat: Support Angular v19 and stabilize linkedQueryParam utility
BREAKING CHANGE: Updated dependencies and configurations for compatibility with Angular v19 and higher. This PR introduces official compatibility with Angular v19 across the platform. A primary focus was stabilizing the 'linkedQueryParam' utility, which has been promoted from experimental to stable, and significantly enhancing its functionality and documentation. ### Features & Enhancements * **Angular v19 Support:** * **`linkedQueryParam` Stabilization:** The utility is now considered **stable**, with robust support for both static and **dynamic query parameter keys**. * **Dynamic Key Handling:** Improved internal logic to ensure correct behavior when the query parameter key changes dynamically, including enhanced synchronization via `automaticallySynchronizeOnKeyChange`. * **Expanded Documentation:** Added comprehensive documentation, including Quick Start guides, detailed examples for built-in parsers (e.g., `paramToNumber`), and usage with **input, writable, and model signals**. ### Fixes & Refactors * Prevented invalid query parameter keys (null, undefined, empty string) from incorrectly updating the route. * Streamlined internal effect registration and cleaned up redundant test cases for better maintainability.
2 parents f082b82 + ffaae9d commit a7db908

38 files changed

+6142
-1629
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@ All utilities are tree-shakable and designed for Angular 16+.
7474

7575
| ngxtension Version | Release Date | Angular Version Support |
7676
|-------------------|--------------|------------------------|
77+
| **7.x** | 2025-09-12 | >=19.0.0 |
78+
| **6.x** | 2025-09-12 | >=16.0.0 |
7779
| **5.x** | 2025-03-14 | >=16.0.0 |
7880
| **4.x** | 2024-07-15 | >=16.0.0 |
7981
| **3.x** | 2024-04-24 | >=16.0.0 |

apps/test-app/src/app/active-element/active-element.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { Component } from '@angular/core';
33
import { injectActiveElement } from 'ngxtension/active-element';
44

55
@Component({
6-
standalone: true,
76
host: {
87
style: 'display: block; margin: 12px',
98
},

apps/test-app/src/app/app.component.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import { Component } from '@angular/core';
22
import { RouterLink, RouterLinkActive, RouterOutlet } from '@angular/router';
33

44
@Component({
5-
standalone: true,
65
imports: [RouterLink, RouterOutlet, RouterLinkActive],
76
selector: 'ngxtension-platform-root',
87
template: `
@@ -81,7 +80,6 @@ import { RouterLink, RouterLinkActive, RouterOutlet } from '@angular/router';
8180
</div>
8281
</div>
8382
`,
84-
8583
styles: `
8684
ul {
8785
display: flex;

apps/test-app/src/app/control-error/control-error.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import { NgxControlError } from 'ngxtension/control-error';
99

1010
@Component({
1111
selector: 'ngxtension-platform-control-error',
12-
standalone: true,
1312
imports: [NgxControlError, FormsModule, ReactiveFormsModule],
1413
template: `
1514
<form [formGroup]="form">

apps/test-app/src/app/control-value-accessor/control-value-accessor.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,6 @@ export class UserSelect {
109109

110110
@Component({
111111
selector: 'ngxtension-platform-control-value-accessor',
112-
standalone: true,
113112
imports: [
114113
CommonModule,
115114
FormsModule,

apps/test-app/src/app/drag/drag.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@ export class Box {
7171
}
7272

7373
@Component({
74-
standalone: true,
7574
imports: [Box, BoxWithHost, NgxDrag],
7675
template: `
7776
<app-box />

apps/test-app/src/app/form-events/form-events.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import { allEventsObservable, allEventsSignal } from 'ngxtension/form-events';
99

1010
@Component({
1111
selector: 'ngxtension-platform-intl',
12-
standalone: true,
1312
imports: [ReactiveFormsModule, JsonPipe, AsyncPipe],
1413
template: `
1514
<label for="control">Control</label>

apps/test-app/src/app/if-validator/if-validator.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import { FormControl, ReactiveFormsModule, Validators } from '@angular/forms';
44
import { ifValidator } from 'ngxtension/if-validator';
55

66
@Component({
7-
standalone: true,
87
imports: [CommonModule, ReactiveFormsModule],
98
host: {
109
style: 'display: block; margin: 12px',

apps/test-app/src/app/intl/intl.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import {
88

99
@Component({
1010
selector: 'ngxtension-platform-intl',
11-
standalone: true,
1211
imports: [
1312
CommonModule,
1413
DisplayNamesPipe,

apps/test-app/src/app/linked-query-param/linked-query-param-array.component.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
1-
import { JsonPipe } from '@angular/common';
21
import { Component, effect } from '@angular/core';
32
import { FormsModule } from '@angular/forms';
43
import { linkedQueryParam } from 'ngxtension/linked-query-param';
54

65
@Component({
7-
standalone: true,
86
template: `
97
<div>
108
@for (id of IDs; track $index) {
@@ -19,7 +17,7 @@ import { linkedQueryParam } from 'ngxtension/linked-query-param';
1917
}
2018
</div>
2119
`,
22-
imports: [FormsModule, JsonPipe],
20+
imports: [FormsModule],
2321
styles: `
2422
div {
2523
padding: 20px;

0 commit comments

Comments
 (0)