Skip to content

Commit

Permalink
Update to Angular 18 (#562)
Browse files Browse the repository at this point in the history
* Fix test setup

* Improve Material 3 support

* Add ThemeService

* Add Zenika logo component

* Fix feedback history filter

* Improve mobile menu

* Add link to usage analytics (hidden for now)

* Increase notification font-size

* Improve documentation

* Display special message when feedbackId or tokenId is invalid
  • Loading branch information
avine authored Jun 18, 2024
1 parent ef955d6 commit e112867
Show file tree
Hide file tree
Showing 123 changed files with 6,139 additions and 4,583 deletions.
54 changes: 0 additions & 54 deletions client/.eslintrc.json

This file was deleted.

2 changes: 1 addition & 1 deletion client/.gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# See http://help.github.com/ignore-files/ for more about ignoring files.
# See https://docs.github.com/get-started/getting-started-with-git/ignoring-files for more about ignoring files.

# Compiled output
/dist
Expand Down
20 changes: 8 additions & 12 deletions client/angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,12 @@
"polyfills": ["zone.js"],
"tsConfig": "tsconfig.app.json",
"inlineStyleLanguage": "scss",
"assets": ["src/favicon.svg", "src/assets"],
"assets": [
{
"glob": "**/*",
"input": "public"
}
],
"styles": ["src/styles.scss"],
"scripts": []
},
Expand Down Expand Up @@ -103,7 +108,7 @@
"fileReplacements": [
{
"replace": "src/environments/environment.ts",
"with": "src/environments/environment.development.ts"
"with": "src/environments/environment.dev-local.ts"
}
]
}
Expand All @@ -126,16 +131,7 @@
"defaultConfiguration": "development"
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"buildTarget": "client:build"
}
},
"test": {
"builder": "@angular-builders/jest:run",
"options": {
"configPath": "jest.config.ts"
}
"builder": "@angular-devkit/build-angular:extract-i18n"
},
"lint": {
"builder": "@angular-eslint/builder:lint",
Expand Down
46 changes: 46 additions & 0 deletions client/eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
// @ts-check
const eslint = require('@eslint/js');
const tseslint = require('typescript-eslint');
const angular = require('angular-eslint');
const eslintConfigPrettier = require('eslint-config-prettier');
const eslintPluginPrettierRecommended = require('eslint-plugin-prettier/recommended');

module.exports = tseslint.config(
{
files: ['**/*.ts'],
extends: [
eslint.configs.recommended,
...tseslint.configs.recommended,
...tseslint.configs.stylistic,
...angular.configs.tsRecommended,
],
processor: angular.processInlineTemplates,
rules: {
'@angular-eslint/directive-selector': [
'error',
{
type: 'attribute',
prefix: 'app',
style: 'camelCase',
},
],
'@angular-eslint/component-selector': [
'error',
{
type: 'element',
prefix: 'app',
style: 'kebab-case',
},
],
// Note: the following rule is an addon (by default, type definitions use `interface`, but we prefer to use `type`)
'@typescript-eslint/consistent-type-definitions': ['error', 'type'],
},
},
{
files: ['**/*.html'],
extends: [...angular.configs.templateRecommended, ...angular.configs.templateAccessibility],
rules: {},
},
eslintConfigPrettier,
eslintPluginPrettierRecommended,
);
4 changes: 3 additions & 1 deletion client/jest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,7 @@ import type { Config } from 'jest';

export default {
passWithNoTests: true,
setupFiles: ['./setup-jest.ts'],
preset: 'jest-preset-angular',
setupFilesAfterEnv: ['<rootDir>/setup-jest.ts'],
//globalSetup: 'jest-preset-angular/global-setup',
} satisfies Config;
Loading

0 comments on commit e112867

Please sign in to comment.