Skip to content

Commit de26bd1

Browse files
ilmartyrkbelka09DiverVMBeccaMelhuish
authored
Update angular20 (#2346)
* add no result hint * New translations en.json (French) * New translations en.json (Spanish) * New translations en.json (Bulgarian) * New translations en.json (Czech) * New translations en.json (German) * New translations en.json (Dutch) * New translations en.json (Russian) * New translations en.json (Slovak) * New translations en.json (Albanian) * New translations en.json (Ukrainian) * New translations en.json (Indonesian) * New translations en.json (Estonian) * New translations en.json (Swahili) * New translations en.json (Somali) * update overflow design * add filters * update filter * text change * replace mobile button * update no image design * Revert "update no image design" This reverts commit a2109cc. * update no image design * Revert "text change" This reverts commit 9b8958f. * text update * update check * add empty question for draft * Revert "update check" This reverts commit acabab7. * fix check * add save draft on close * update data * wip autosave * wip autosave * increase timing, refactor * Update en.json * wip autosave * wip autosave * add autosave loaders and styles * add no result hint * update icon * remove possibility to edit and remove anonymous ideas * add expand/collapse functionality * apply changes * add filters * update filter * fix * wip autosave * wip autosave * increase timing, refactor * wip autosave * wip autosave * add autosave loaders and styles * update icon * wip autosave * fix: Default overlay when topic had image * feature: Add docker files * Update Angular to v19 and update peer dependencies * WIP update standalone components * Update to angular 19 * chore: WIP angular update * chore: update all dependencies to latest, refactor marked integration for v15+ * chore: exclude .env file from git * chore: add .env to .gitignore to prevent secrets from being committed --------- Co-authored-by: Dzmitry Zimnitski <[email protected]> Co-authored-by: Viktar Maslouski <[email protected]> Co-authored-by: BeccaMelhuish <[email protected]>
1 parent a4b48d2 commit de26bd1

File tree

192 files changed

+9289
-6561
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

192 files changed

+9289
-6561
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,4 @@ testem.log
4343
# System files
4444
.DS_Store
4545
Thumbs.db
46+
.env.env

.npmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@web-eid:registry=https://gitlab.com/api/v4/packages/npm

.scannerwork/.sonar_lock

Whitespace-only changes.

.scannerwork/report-task.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
projectKey=citizenos_citizenos-fe_AZNQVASxf83PVb-FYTLU
2+
serverUrl=http://localhost:9000
3+
serverVersion=9.9.2.77730
4+
dashboardUrl=http://localhost:9000/dashboard?id=citizenos_citizenos-fe_AZNQVASxf83PVb-FYTLU
5+
ceTaskId=AZNQVb_Df83PVb-FYTLh
6+
ceTaskUrl=http://localhost:9000/api/ce/task?id=AZNQVb_Df83PVb-FYTLh

angular.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,5 +145,31 @@
145145
},
146146
"cli": {
147147
"analytics": false
148+
},
149+
"schematics": {
150+
"@schematics/angular:component": {
151+
"type": "component"
152+
},
153+
"@schematics/angular:directive": {
154+
"type": "directive"
155+
},
156+
"@schematics/angular:service": {
157+
"type": "service"
158+
},
159+
"@schematics/angular:guard": {
160+
"typeSeparator": "."
161+
},
162+
"@schematics/angular:interceptor": {
163+
"typeSeparator": "."
164+
},
165+
"@schematics/angular:module": {
166+
"typeSeparator": "."
167+
},
168+
"@schematics/angular:pipe": {
169+
"typeSeparator": "."
170+
},
171+
"@schematics/angular:resolver": {
172+
"typeSeparator": "."
173+
}
148174
}
149175
}

gulpfile.js

Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
const gulp = require('gulp');
2+
const { exec } = require('child_process');
3+
const { promisify } = require('util');
4+
const fs = require('fs');
5+
const path = require('path');
6+
7+
const execAsync = promisify(exec);
8+
9+
// Check current Angular version
10+
gulp.task('check:angular-version', async () => {
11+
try {
12+
const packageJson = JSON.parse(fs.readFileSync(path.join(process.cwd(), 'package.json'), 'utf8'));
13+
const currentVersion = packageJson.dependencies['@angular/core'];
14+
console.log(`Current Angular version: ${currentVersion}`);
15+
return currentVersion;
16+
} catch (error) {
17+
console.error('Error checking Angular version:', error);
18+
throw error;
19+
}
20+
});
21+
22+
// Update to Angular 19
23+
gulp.task('update:to-19', async () => {
24+
try {
25+
console.log('Updating to Angular 19...');
26+
27+
// Update Angular CLI globally
28+
console.log('Updating Angular CLI globally...');
29+
await execAsync('npm install -g @angular/cli@19');
30+
31+
// Update core packages
32+
console.log('Updating Angular core packages...');
33+
await execAsync('npm install @angular/core@19 @angular/common@19 @angular/compiler@19 @angular/platform-browser@19 @angular/platform-browser-dynamic@19 @angular/forms@19 @angular/router@19 @angular/animations@19');
34+
35+
// Update CDK
36+
console.log('Updating Angular CDK...');
37+
await execAsync('npm install @angular/cdk@19');
38+
39+
// Update dev dependencies
40+
console.log('Updating Angular dev dependencies...');
41+
await execAsync('npm install --save-dev @angular-devkit/build-angular@19 @angular/cli@19 @angular/compiler-cli@19');
42+
43+
// Update peer dependencies
44+
console.log('Updating peer dependencies...');
45+
await execAsync('npm install rxjs@~7.8.0 zone.js@~0.14.2 tslib@^2.6.0');
46+
47+
// Run ng update to handle breaking changes
48+
console.log('Running ng update to handle breaking changes...');
49+
await execAsync('ng update @angular/core@19 @angular/cli@19 --allow-dirty');
50+
51+
console.log('Update to Angular 19 completed successfully!');
52+
} catch (error) {
53+
console.error('Error updating to Angular 19:', error);
54+
throw error;
55+
}
56+
});
57+
58+
// Update to Angular 20
59+
gulp.task('update:to-20', async () => {
60+
try {
61+
console.log('Updating to Angular 20...');
62+
63+
// Update Angular CLI globally
64+
console.log('Updating Angular CLI globally...');
65+
await execAsync('npm install -g @angular/cli@20');
66+
67+
// Update core packages
68+
console.log('Updating Angular core packages...');
69+
await execAsync('npm install @angular/core@20 @angular/common@20 @angular/compiler@20 @angular/platform-browser@20 @angular/platform-browser-dynamic@20 @angular/forms@20 @angular/router@20 @angular/animations@20');
70+
71+
// Update CDK
72+
console.log('Updating Angular CDK...');
73+
await execAsync('npm install @angular/cdk@20');
74+
75+
// Update dev dependencies
76+
console.log('Updating Angular dev dependencies...');
77+
await execAsync('npm install --save-dev @angular-devkit/build-angular@20 @angular/cli@20 @angular/compiler-cli@20');
78+
79+
// Update peer dependencies
80+
console.log('Updating peer dependencies...');
81+
await execAsync('npm install rxjs@~7.8.0 zone.js@~0.14.3 tslib@^2.6.0');
82+
83+
// Run ng update to handle breaking changes
84+
console.log('Running ng update to handle breaking changes...');
85+
await execAsync('ng update @angular/core@20 @angular/cli@20 --allow-dirty');
86+
87+
console.log('Update to Angular 20 completed successfully!');
88+
} catch (error) {
89+
console.error('Error updating to Angular 20:', error);
90+
throw error;
91+
}
92+
});
93+
94+
// Update all remaining dependencies
95+
gulp.task('update:remaining', async () => {
96+
try {
97+
console.log('Updating remaining dependencies...');
98+
await execAsync('npm update');
99+
console.log('All remaining dependencies updated successfully!');
100+
} catch (error) {
101+
console.error('Error updating remaining dependencies:', error);
102+
throw error;
103+
}
104+
});
105+
106+
// Default task that runs the complete update process
107+
gulp.task('update', gulp.series('check:angular-version', 'update:to-19', 'update:to-20', 'update:remaining'));

0 commit comments

Comments
 (0)