@ethlete/cdk 5.0.0-next.30 → 5.0.0-next.32

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.
@@ -0,0 +1,41 @@
1
+ # Work through the cdk migration tasks
2
+
3
+ `nx g @ethlete/cdk:migrate-from-cdk` rewrites every import whose successor in `@ethlete/components` or
4
+ `@ethlete/core` has the same contract. What it cannot rewrite, it writes into
5
+ `migrate-from-cdk-tasks.md` at the repository root. That file is the input for this task.
6
+
7
+ If `migrate-from-cdk-tasks.md` is not there, the generator found nothing that needs a decision, and
8
+ there is nothing to do here.
9
+
10
+ ## How to work the file
11
+
12
+ Take one section at a time. Every entry names a `file:line`, so read the call site before you change
13
+ it. Each section states what the successor API expects.
14
+
15
+ - **`<et-picture>` without `alt`.** `alt` is required on the components picture. `alt=""` is allowed and
16
+ states that the image is decorative. Which one a site needs is a product decision: read the
17
+ surrounding markup, and use `alt=""` only where the image carries no information. Where a real
18
+ description is needed and nothing in the code holds one, leave the site in the report and say so.
19
+ - **Picture class inputs.** `imgClass`, `pictureClass`, `figureClass` and `figcaptionClass` are gone.
20
+ The report groups each site by what its classes express: a definite box in both axes takes `fit` on
21
+ the host, a single constrained axis takes a style on `.et-picture-img`. Follow the group, not a
22
+ uniform rewrite - `fit` on an image that sizes its own box collapses the layout.
23
+ - **Themed spinners.** The cdk spinner defaulted to a themed blue; the components spinner defaults to
24
+ `currentColor`. A spinner inside a button or a link should inherit. A standalone one that carried the
25
+ brand colour needs `color="brand"`, using the theme name that app registers.
26
+ - **Spinner `[mode]` bindings.** `mode` split into the `determinate` boolean. Rewrite the expression by
27
+ what it meant, for example `[mode]="isKnown ? 'determinate' : 'indeterminate'"` becomes
28
+ `[determinate]="isKnown"`.
29
+ - **Symbols whose contract changed.** These imports still point at `@ethlete/cdk` on purpose. Move one
30
+ only when its call site matches the successor API. The entry names the successor and links its guide.
31
+ - **Successors that need a newer package.** Do not touch these. Update `@ethlete/components` or
32
+ `@ethlete/core` first, then run `nx g @ethlete/cdk:migrate-from-cdk` again.
33
+
34
+ ## When you are done
35
+
36
+ 1. Run the type check and the lint task of every project you changed.
37
+ 2. Run the tests that cover the components you touched.
38
+ 3. Delete the entries you finished from `migrate-from-cdk-tasks.md`, and delete the file once it is
39
+ empty. Leave any entry you could not decide, with a line saying what is missing.
40
+
41
+ The cdk migration guide is at <https://ethlete-sdk-docs.web.app/cdk/migration>.
@@ -0,0 +1,28 @@
1
+ {
2
+ "migrations": [
3
+ {
4
+ "name": "to-v5",
5
+ "version": "5.0.0-beta.12",
6
+ "kind": "auto",
7
+ "description": "Rewrite the v4 cdk API into its v5 shape.",
8
+ "generator": "@ethlete/cdk:migrate-to-v5",
9
+ "docs": "/cdk/migration"
10
+ },
11
+ {
12
+ "name": "from-cdk",
13
+ "version": "5.0.0-next.25",
14
+ "kind": "auto",
15
+ "description": "Rewrite the mechanical part of the move off @ethlete/cdk, and write migrate-from-cdk-tasks.md for the rest.",
16
+ "generator": "@ethlete/cdk:migrate-from-cdk",
17
+ "docs": "/cdk/migration"
18
+ },
19
+ {
20
+ "name": "from-cdk-decisions",
21
+ "version": "5.0.0-next.25",
22
+ "kind": "assisted",
23
+ "description": "Work through migrate-from-cdk-tasks.md: the call sites whose successor API behaves differently.",
24
+ "instructions": "./migrations/from-cdk-decisions.md",
25
+ "docs": "/cdk/migration"
26
+ }
27
+ ]
28
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ethlete/cdk",
3
- "version": "5.0.0-next.30",
3
+ "version": "5.0.0-next.32",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "exports": {
@@ -18,12 +18,12 @@
18
18
  },
19
19
  "peerDependencies": {
20
20
  "@analogjs/vite-plugin-angular": "2.6.3",
21
- "@angular/cdk": "22.0.5",
22
- "@angular/common": "22.0.7",
23
- "@angular/core": "22.0.7",
24
- "@angular/forms": "22.0.7",
25
- "@angular/platform-browser": "22.0.7",
26
- "@angular/router": "22.0.7",
21
+ "@angular/cdk": "22.1.6",
22
+ "@angular/common": "22.1.6",
23
+ "@angular/core": "22.1.6",
24
+ "@angular/forms": "22.1.6",
25
+ "@angular/platform-browser": "22.1.6",
26
+ "@angular/router": "22.1.6",
27
27
  "@ethlete/core": "^5.0.0-beta.11",
28
28
  "@ethlete/query": "^6.0.0-beta.8",
29
29
  "@ethlete/types": "^2.0.0-beta.4",
@@ -48,6 +48,9 @@
48
48
  "optional": true
49
49
  }
50
50
  },
51
+ "ethlete": {
52
+ "migrations": "./migrations.json"
53
+ },
51
54
  "generators": "./generators/generators.json",
52
55
  "module": "fesm2022/ethlete-cdk.mjs",
53
56
  "typings": "types/ethlete-cdk.d.ts",
@@ -5179,7 +5179,7 @@ declare const provideValidatorErrorsService: (service?: new () => ValidationErro
5179
5179
  declare class DefaultValidatorErrorsService implements ValidationErrorsServiceType {
5180
5180
  parse(errors: ValidatorErrors): string | Observable<string>;
5181
5181
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<DefaultValidatorErrorsService, never>;
5182
- static ɵprov: _angular_core.ɵɵInjectableDeclaration<DefaultValidatorErrorsService>;
5182
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<any>;
5183
5183
  }
5184
5184
 
5185
5185
  /**
@@ -5201,7 +5201,7 @@ declare class FormFieldStateService {
5201
5201
  readonly describedBy$: rxjs.Observable<string | null>;
5202
5202
  readonly describedBy: _angular_core.Signal<string | null>;
5203
5203
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<FormFieldStateService, never>;
5204
- static ɵprov: _angular_core.ɵɵInjectableDeclaration<FormFieldStateService>;
5204
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<any>;
5205
5205
  }
5206
5206
 
5207
5207
  /**
@@ -5213,7 +5213,7 @@ declare class FormGroupStateService {
5213
5213
  readonly errorId$: BehaviorSubject<string | null>;
5214
5214
  readonly describedBy$: rxjs.Observable<string | null>;
5215
5215
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<FormGroupStateService, never>;
5216
- static ɵprov: _angular_core.ɵɵInjectableDeclaration<FormGroupStateService>;
5216
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<any>;
5217
5217
  }
5218
5218
 
5219
5219
  /**
@@ -5276,7 +5276,7 @@ declare class InputStateService<T = unknown, J extends HTMLElement = HTMLElement
5276
5276
  _valueChange: InputValueChangeFn<T>;
5277
5277
  _touched: InputTouchedFn;
5278
5278
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<InputStateService<any, any>, never>;
5279
- static ɵprov: _angular_core.ɵɵInjectableDeclaration<InputStateService<any, any>>;
5279
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<any>;
5280
5280
  }
5281
5281
 
5282
5282
  /**
@@ -8965,7 +8965,7 @@ declare class FilterOverlayService<F extends FormGroup, C extends ComponentType<
8965
8965
  reset(): void;
8966
8966
  close(data?: FilterOverlayResult): void;
8967
8967
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<FilterOverlayService<any, any>, never>;
8968
- static ɵprov: _angular_core.ɵɵInjectableDeclaration<FilterOverlayService<any, any>>;
8968
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<any>;
8969
8969
  }
8970
8970
  /**
8971
8971
  * @deprecated `@ethlete/cdk` is in maintenance mode. Use the `@ethlete/components` equivalent instead - see https://ethlete-sdk-docs.web.app/cdk/migration, and run `nx g @ethlete/cdk:migrate-from-cdk` to rewrite the mechanical parts. Intent to remove in v6.
@@ -9907,7 +9907,7 @@ declare class PaginationHeadService implements OnDestroy {
9907
9907
  private _getCanonicalElement;
9908
9908
  private _removeCanonicalElement;
9909
9909
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<PaginationHeadService, never>;
9910
- static ɵprov: _angular_core.ɵɵInjectableDeclaration<PaginationHeadService>;
9910
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<any>;
9911
9911
  }
9912
9912
 
9913
9913
  /**
@@ -10560,7 +10560,7 @@ declare class SortHeaderComponent implements Sortable, OnDestroy, OnInit, AfterV
10560
10560
  declare class SortHeaderIntl {
10561
10561
  readonly changes: Subject<void>;
10562
10562
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<SortHeaderIntl, never>;
10563
- static ɵprov: _angular_core.ɵɵInjectableDeclaration<SortHeaderIntl>;
10563
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<any>;
10564
10564
  }
10565
10565
  /**
10566
10566
  * @deprecated `@ethlete/cdk` is in maintenance mode. Use the `@ethlete/components` equivalent instead - see https://ethlete-sdk-docs.web.app/cdk/migration, and run `nx g @ethlete/cdk:migrate-from-cdk` to rewrite the mechanical parts. Intent to remove in v6.