Skip to content

Commit

Permalink
fix: update nx to 19.1 (#1558)
Browse files Browse the repository at this point in the history
* fix: update nx to 19.1

* fix: migrate angular material

* chore: fix spec files
  • Loading branch information
lacolaco authored Nov 22, 2024
1 parent eaeecfe commit 1b44239
Show file tree
Hide file tree
Showing 12 changed files with 2,333 additions and 1,876 deletions.
10 changes: 8 additions & 2 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,18 @@
"parserOptions": {
"project": "./tsconfig.*?.json"
},
"rules": {}
"rules": {
"@typescript-eslint/no-extra-semi": "error",
"no-extra-semi": "off"
}
},
{
"files": ["*.js", "*.jsx"],
"extends": ["plugin:@nx/javascript"],
"rules": {}
"rules": {
"@typescript-eslint/no-extra-semi": "error",
"no-extra-semi": "off"
}
}
]
}
25 changes: 12 additions & 13 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,20 @@

## [1.0.4](https://github.com/lacolaco/contributors-img/compare/v1.0.3...v1.0.4) (2024-11-17)


### Bug Fixes

* **deps:** update dependency @rx-angular/state to v16.3.0 ([#1537](https://github.com/lacolaco/contributors-img/issues/1537)) ([7b3ab04](https://github.com/lacolaco/contributors-img/commit/7b3ab042af74db455f3b742047b3cd87951dc26d))
* **deps:** update golang.org/x/exp digest to 2d47ceb ([#1513](https://github.com/lacolaco/contributors-img/issues/1513)) ([b5f1467](https://github.com/lacolaco/contributors-img/commit/b5f1467374c6655ea5941d3ef86dd88a835cf4bb))
* **deps:** update module cloud.google.com/go/bigquery to v1.64.0 ([#1522](https://github.com/lacolaco/contributors-img/issues/1522)) ([d7a1e51](https://github.com/lacolaco/contributors-img/commit/d7a1e51af29d64a2bb0b29bc9883634f6b3cc7b8))
* **deps:** update module cloud.google.com/go/storage to v1.47.0 ([#1525](https://github.com/lacolaco/contributors-img/issues/1525)) ([b27f311](https://github.com/lacolaco/contributors-img/commit/b27f31160c3e6765e0fe206e1a131109d2b414f2))
* **deps:** update module github.com/andybalholm/brotli to v1.1.1 ([#1538](https://github.com/lacolaco/contributors-img/issues/1538)) ([482ee2f](https://github.com/lacolaco/contributors-img/commit/482ee2f0e67eb1a854078d0b31d1acc9b118d645))
* **deps:** update module github.com/gin-gonic/gin to v1.10.0 ([#1541](https://github.com/lacolaco/contributors-img/issues/1541)) ([1c59455](https://github.com/lacolaco/contributors-img/commit/1c59455ddd211c5c551ee8079f0f1e6cbc2981fb))
* **deps:** update module github.com/google/go-github/v45 to v66 ([#1543](https://github.com/lacolaco/contributors-img/issues/1543)) ([8e5e57e](https://github.com/lacolaco/contributors-img/commit/8e5e57e44b955c0e2b772ae9b071b5d854f6f8e9))
* **deps:** update module go.ajitem.com/zapdriver to v1.5.3 ([#1540](https://github.com/lacolaco/contributors-img/issues/1540)) ([df4342f](https://github.com/lacolaco/contributors-img/commit/df4342fe5542ffd7349db0d697c954262d0c5024))
* **deps:** update module go.uber.org/zap to v1.27.0 ([#1539](https://github.com/lacolaco/contributors-img/issues/1539)) ([448bd73](https://github.com/lacolaco/contributors-img/commit/448bd7386905e01f34252b88094dc876ed617316))
* **deps:** update module google.golang.org/api to v0.205.0 ([#1528](https://github.com/lacolaco/contributors-img/issues/1528)) ([daf7e0c](https://github.com/lacolaco/contributors-img/commit/daf7e0c142537bcf5d5ef5061a14ae1507897b7f))
* **deps:** update otel packages ([#1530](https://github.com/lacolaco/contributors-img/issues/1530)) ([83eb939](https://github.com/lacolaco/contributors-img/commit/83eb939738f7ee568f24fafdecc6964e44e75141))
* upgrade nx to v17 ([#1508](https://github.com/lacolaco/contributors-img/issues/1508)) ([726ac8c](https://github.com/lacolaco/contributors-img/commit/726ac8c579b2d023539e03e8c5251f61fd63ba2c))
- **deps:** update dependency @rx-angular/state to v16.3.0 ([#1537](https://github.com/lacolaco/contributors-img/issues/1537)) ([7b3ab04](https://github.com/lacolaco/contributors-img/commit/7b3ab042af74db455f3b742047b3cd87951dc26d))
- **deps:** update golang.org/x/exp digest to 2d47ceb ([#1513](https://github.com/lacolaco/contributors-img/issues/1513)) ([b5f1467](https://github.com/lacolaco/contributors-img/commit/b5f1467374c6655ea5941d3ef86dd88a835cf4bb))
- **deps:** update module cloud.google.com/go/bigquery to v1.64.0 ([#1522](https://github.com/lacolaco/contributors-img/issues/1522)) ([d7a1e51](https://github.com/lacolaco/contributors-img/commit/d7a1e51af29d64a2bb0b29bc9883634f6b3cc7b8))
- **deps:** update module cloud.google.com/go/storage to v1.47.0 ([#1525](https://github.com/lacolaco/contributors-img/issues/1525)) ([b27f311](https://github.com/lacolaco/contributors-img/commit/b27f31160c3e6765e0fe206e1a131109d2b414f2))
- **deps:** update module github.com/andybalholm/brotli to v1.1.1 ([#1538](https://github.com/lacolaco/contributors-img/issues/1538)) ([482ee2f](https://github.com/lacolaco/contributors-img/commit/482ee2f0e67eb1a854078d0b31d1acc9b118d645))
- **deps:** update module github.com/gin-gonic/gin to v1.10.0 ([#1541](https://github.com/lacolaco/contributors-img/issues/1541)) ([1c59455](https://github.com/lacolaco/contributors-img/commit/1c59455ddd211c5c551ee8079f0f1e6cbc2981fb))
- **deps:** update module github.com/google/go-github/v45 to v66 ([#1543](https://github.com/lacolaco/contributors-img/issues/1543)) ([8e5e57e](https://github.com/lacolaco/contributors-img/commit/8e5e57e44b955c0e2b772ae9b071b5d854f6f8e9))
- **deps:** update module go.ajitem.com/zapdriver to v1.5.3 ([#1540](https://github.com/lacolaco/contributors-img/issues/1540)) ([df4342f](https://github.com/lacolaco/contributors-img/commit/df4342fe5542ffd7349db0d697c954262d0c5024))
- **deps:** update module go.uber.org/zap to v1.27.0 ([#1539](https://github.com/lacolaco/contributors-img/issues/1539)) ([448bd73](https://github.com/lacolaco/contributors-img/commit/448bd7386905e01f34252b88094dc876ed617316))
- **deps:** update module google.golang.org/api to v0.205.0 ([#1528](https://github.com/lacolaco/contributors-img/issues/1528)) ([daf7e0c](https://github.com/lacolaco/contributors-img/commit/daf7e0c142537bcf5d5ef5061a14ae1507897b7f))
- **deps:** update otel packages ([#1530](https://github.com/lacolaco/contributors-img/issues/1530)) ([83eb939](https://github.com/lacolaco/contributors-img/commit/83eb939738f7ee568f24fafdecc6964e44e75141))
- upgrade nx to v17 ([#1508](https://github.com/lacolaco/contributors-img/issues/1508)) ([726ac8c](https://github.com/lacolaco/contributors-img/commit/726ac8c579b2d023539e03e8c5251f61fd63ba2c))

## [1.0.3](https://github.com/lacolaco/contributors-img/compare/v1.0.2...v1.0.3) (2024-11-16)

Expand Down
4 changes: 2 additions & 2 deletions apps/webapp/src/app/app.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { HttpClientModule } from '@angular/common/http';
import { provideHttpClient } from '@angular/common/http';
import { ApplicationConfig, importProvidersFrom } from '@angular/core';
import { getAnalytics, provideAnalytics } from '@angular/fire/analytics';
import { initializeApp, provideFirebaseApp } from '@angular/fire/app';
Expand All @@ -13,7 +13,7 @@ import { provideFeaturedRepositoryDatasource } from './shared/featured-repositor
export const appConfig: ApplicationConfig = {
providers: [
provideAnimations(),
importProvidersFrom(HttpClientModule),
provideHttpClient(),
provideRouter(routes),
importProvidersFrom(provideFirebaseApp(() => initializeApp(environment.firebaseConfig))),
importProvidersFrom(provideFirestore(() => getFirestore())),
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { ComponentFixture, TestBed } from '@angular/core/testing';

import { HeaderComponent } from './header.component';

describe('HeaderComponent', () => {
let component: HeaderComponent;
let fixture: ComponentFixture<HeaderComponent>;

beforeEach(async(() => {
beforeEach(() => {
TestBed.configureTestingModule({
imports: [HeaderComponent],
}).compileComponents();
}));
});

beforeEach(() => {
fixture = TestBed.createComponent(HeaderComponent);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { ChangeDetectionStrategy, Component } from '@angular/core';
import { MatLegacyButtonModule as MatButtonModule } from '@angular/material/legacy-button';
import { MatButtonModule } from '@angular/material/button';

@Component({
selector: 'app-header',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { ChangeDetectionStrategy, Component, inject, Input } from '@angular/core';
import { FormBuilder, ReactiveFormsModule, Validators } from '@angular/forms';
import { MatLegacyButtonModule as MatButtonModule } from '@angular/material/legacy-button';
import { MatLegacyFormFieldModule as MatFormFieldModule } from '@angular/material/legacy-form-field';
import { MatLegacyInputModule as MatInputModule } from '@angular/material/legacy-input';
import { MatButtonModule } from '@angular/material/button';
import { MatFormFieldModule } from '@angular/material/form-field';
import { MatInputModule } from '@angular/material/input';
import { ImageParams } from '../../../models/image-params';
import { Repository } from '../../../models/repository';
import { PreviewState } from '../state';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { CommonModule } from '@angular/common';
import { ChangeDetectionStrategy, Component, Input, OnChanges } from '@angular/core';
import { MatLegacyButtonModule as MatButtonModule } from '@angular/material/legacy-button';
import { MatButtonModule } from '@angular/material/button';
import { SvgViewComponent } from '../../../components/svg-view/svg-view.component';
import { Repository } from '../../../models';
import { ImageSnippetComponent } from '../image-snippet/image-snippet.component';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
import { Clipboard, ClipboardModule } from '@angular/cdk/clipboard';
import { ChangeDetectionStrategy, Component, inject, Input } from '@angular/core';
import {
MatLegacySnackBar as MatSnackBar,
MatLegacySnackBarModule as MatSnackBarModule,
} from '@angular/material/legacy-snack-bar';
import { MatSnackBar, MatSnackBarModule } from '@angular/material/snack-bar';
import { Repository } from '../../../models/repository';

@Component({
Expand Down
17 changes: 3 additions & 14 deletions apps/webapp/src/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -8,23 +8,12 @@ body {

// Define a custom typography config that overrides the font-family as well as the
// `headlines` and `body-1` levels.
$custom-typography: mat.define-legacy-typography-config(
$custom-typography: mat.m2-define-legacy-typography-config(
$font-family: "'Montserrat', sans-serif",
$headline: mat.define-typography-level(32px, 48px, 700),
$body-1: mat.define-typography-level(16px, 24px, 500),
$headline: mat.m2-define-typography-level(32px, 48px, 700),
$body-1: mat.m2-define-typography-level(16px, 24px, 500),
);

// TODO(v15): As of v15 mat.legacy-core no longer includes default typography styles.
// The following line adds:
// 1. Default typography styles for all components
// 2. Styles for typography hierarchy classes (e.g. .mat-headline-1)
// If you specify typography styles for the components you use elsewhere, you should delete this line.
// If you don't need the default component typographies but still want the hierarchy styles,
// you can delete this line and instead use:
// `@include mat.legacy-typography-hierarchy($custom-typography);`
@include mat.all-legacy-component-typographies($custom-typography);
@include mat.legacy-core();

.mat-form-field.--no-hint {
.mat-form-field-wrapper {
padding-bottom: unset;
Expand Down
42 changes: 32 additions & 10 deletions migrations.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,48 @@
"migrations": [
{
"cli": "nx",
"version": "18.2.0-beta.0",
"requires": { "@angular/core": ">=17.3.0" },
"description": "Update the @angular/cli package version to ~17.3.0.",
"factory": "./src/migrations/update-18-2-0/update-angular-cli",
"version": "19.1.0-beta.6",
"description": "Migrate no-extra-semi rules into user config, out of nx extendable configs",
"implementation": "./src/migrations/update-19-1-0-migrate-no-extra-semi/migrate-no-extra-semi",
"package": "@nx/eslint-plugin",
"name": "update-19-1-0-rename-no-extra-semi"
},
{
"cli": "nx",
"version": "19.1.0-beta.2",
"requires": { "@angular/core": ">=18.0.0" },
"description": "Update the @angular/cli package version to ~18.0.0.",
"factory": "./src/migrations/update-19-1-0/update-angular-cli",
"package": "@nx/angular",
"name": "update-angular-cli-version-17-3-0"
"name": "update-angular-cli-version-18-0-0"
},
{
"version": "17.3.0",
"version": "18.0.0",
"description": "Updates two-way bindings that have an invalid expression to use the longform expression instead.",
"factory": "./migrations/invalid-two-way-bindings/bundle",
"package": "@angular/core",
"name": "invalid-two-way-bindings"
},
{
"version": "17.0.0-0",
"description": "Updates Angular Material to v17",
"factory": "./ng-update/index_bundled#updateToV17",
"version": "18.0.0",
"description": "Replace deprecated HTTP related modules with provider functions",
"factory": "./migrations/http-providers/bundle",
"package": "@angular/core",
"name": "migration-http-providers"
},
{
"version": "18.0.0-0",
"description": "Updates Angular Material to v18",
"factory": "./ng-update/index_bundled#updateToV18",
"package": "@angular/material",
"name": "migration-v17"
"name": "migration-v18"
},
{
"version": "18.0.0-0",
"description": "Updates the Angular CDK to v18",
"factory": "./ng-update/index#updateToV18",
"package": "@angular/cdk",
"name": "migration-v18"
}
]
}
52 changes: 26 additions & 26 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,17 @@
"private": true,
"packageManager": "[email protected]",
"dependencies": {
"@angular/animations": "17.3.12",
"@angular/cdk": "17.3.9",
"@angular/common": "17.3.12",
"@angular/compiler": "17.3.12",
"@angular/core": "17.3.12",
"@angular/animations": "18.0.7",
"@angular/cdk": "18.0.6",
"@angular/common": "18.0.7",
"@angular/compiler": "18.0.7",
"@angular/core": "18.0.7",
"@angular/fire": "17.0.0",
"@angular/forms": "17.3.12",
"@angular/material": "^16.2.0",
"@angular/platform-browser": "17.3.12",
"@angular/platform-browser-dynamic": "17.3.12",
"@angular/router": "17.3.12",
"@angular/forms": "18.0.7",
"@angular/material": "18.0.6",
"@angular/platform-browser": "18.0.7",
"@angular/platform-browser-dynamic": "18.0.7",
"@angular/router": "18.0.7",
"@rx-angular/state": "16.3.0",
"firebase": "9.23.0",
"normalize.css": "8.0.1",
Expand All @@ -50,22 +50,22 @@
"zone.js": "0.14.8"
},
"devDependencies": {
"@angular-devkit/architect": "0.1703.9",
"@angular-devkit/build-angular": "17.3.11",
"@angular-eslint/eslint-plugin": "17.3.0",
"@angular-eslint/eslint-plugin-template": "17.3.0",
"@angular-eslint/template-parser": "17.3.0",
"@angular/cli": "~17.3.0",
"@angular/compiler-cli": "17.3.12",
"@angular/language-service": "17.3.12",
"@angular-devkit/architect": "0.1800.7",
"@angular-devkit/build-angular": "18.0.7",
"@angular-eslint/eslint-plugin": "18.4.1",
"@angular-eslint/eslint-plugin-template": "18.4.1",
"@angular-eslint/template-parser": "18.4.1",
"@angular/cli": "~18.0.0",
"@angular/compiler-cli": "18.0.7",
"@angular/language-service": "18.0.7",
"@faker-js/faker": "9.2.0",
"@nx/angular": "19.0.8",
"@nx/eslint": "19.0.8",
"@nx/eslint-plugin": "19.0.8",
"@nx/jest": "19.0.8",
"@nx/node": "19.0.8",
"@nx/web": "19.0.8",
"@nx/workspace": "19.0.8",
"@nx/angular": "19.1.2",
"@nx/eslint": "19.1.2",
"@nx/eslint-plugin": "19.1.2",
"@nx/jest": "19.1.2",
"@nx/node": "19.1.2",
"@nx/web": "19.1.2",
"@nx/workspace": "19.1.2",
"@types/jest": "29.5.14",
"@types/jsdom": "21.1.7",
"@types/node": "18.19.64",
Expand All @@ -79,7 +79,7 @@
"firebase-tools": "13.24.2",
"jest": "29.7.0",
"jest-environment-jsdom": "29.7.0",
"jest-preset-angular": "14.0.4",
"jest-preset-angular": "14.1.1",
"prettier": "2.8.8",
"ts-node": "10.9.2",
"typescript": "5.4.5"
Expand Down
Loading

0 comments on commit 1b44239

Please sign in to comment.