fix: ng update core
This commit is contained in:
@@ -8,7 +8,7 @@ FROM httpd:alpine AS runtime
|
||||
RUN apk add --no-cache certbot certbot-apache
|
||||
COPY httpd.conf /usr/local/apache2/conf/httpd.conf
|
||||
COPY cli.ini /etc/letsencrypt/cli.ini
|
||||
COPY --from=build /build/dist /usr/local/apache2/htdocs/
|
||||
COPY --from=build /build/dist/ipwa/browser /usr/local/apache2/htdocs/ipwa
|
||||
COPY <<EOF /usr/local/apache2/htdocs/ipwa/.htaccess
|
||||
RewriteEngine on
|
||||
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} -f [OR]
|
||||
|
||||
17
angular.json
17
angular.json
@@ -16,11 +16,12 @@
|
||||
"prefix": "app",
|
||||
"architect": {
|
||||
"build": {
|
||||
"builder": "@angular-devkit/build-angular:browser",
|
||||
"builder": "@angular-devkit/build-angular:application",
|
||||
"options": {
|
||||
"outputPath": "dist/ipwa",
|
||||
"outputPath": {
|
||||
"base": "dist/ipwa"
|
||||
},
|
||||
"index": "src/index.html",
|
||||
"main": "src/main.ts",
|
||||
"polyfills": [
|
||||
"zone.js"
|
||||
],
|
||||
@@ -35,11 +36,11 @@
|
||||
"src/styles.scss"
|
||||
],
|
||||
"scripts": [],
|
||||
"serviceWorker": true,
|
||||
"ngswConfigPath": "ngsw-config.json",
|
||||
"serviceWorker": "ngsw-config.json",
|
||||
"allowedCommonJsDependencies": [
|
||||
"moment"
|
||||
]
|
||||
],
|
||||
"browser": "src/main.ts"
|
||||
},
|
||||
"configurations": {
|
||||
"production": {
|
||||
@@ -58,9 +59,7 @@
|
||||
"outputHashing": "all"
|
||||
},
|
||||
"development": {
|
||||
"buildOptimizer": false,
|
||||
"optimization": false,
|
||||
"vendorChunk": true,
|
||||
"extractLicenses": false,
|
||||
"sourceMap": true,
|
||||
"namedChunks": true,
|
||||
@@ -72,9 +71,7 @@
|
||||
]
|
||||
},
|
||||
"swDevelopment": {
|
||||
"buildOptimizer": false,
|
||||
"optimization": false,
|
||||
"vendorChunk": true,
|
||||
"extractLicenses": false,
|
||||
"sourceMap": true,
|
||||
"namedChunks": true,
|
||||
|
||||
6091
package-lock.json
generated
6091
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
26
package.json
26
package.json
@@ -12,28 +12,28 @@
|
||||
},
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"@angular/animations": "^17.3.2",
|
||||
"@angular/animations": "^18.2.13",
|
||||
"@angular/cdk": "^17.3.2",
|
||||
"@angular/cli": "^17.3.2",
|
||||
"@angular/common": "^17.3.2",
|
||||
"@angular/compiler": "^17.3.2",
|
||||
"@angular/core": "^17.3.2",
|
||||
"@angular/forms": "^17.3.2",
|
||||
"@angular/cli": "^18.2.19",
|
||||
"@angular/common": "^18.2.13",
|
||||
"@angular/compiler": "^18.2.13",
|
||||
"@angular/core": "^18.2.13",
|
||||
"@angular/forms": "^18.2.13",
|
||||
"@angular/material": "^17.3.2",
|
||||
"@angular/material-moment-adapter": "^17.3.2",
|
||||
"@angular/platform-browser": "^17.3.2",
|
||||
"@angular/platform-browser-dynamic": "^17.3.2",
|
||||
"@angular/router": "^17.3.2",
|
||||
"@angular/service-worker": "^17.3.2",
|
||||
"@angular/platform-browser": "^18.2.13",
|
||||
"@angular/platform-browser-dynamic": "^18.2.13",
|
||||
"@angular/router": "^18.2.13",
|
||||
"@angular/service-worker": "^18.2.13",
|
||||
"marked": "^12.0.1",
|
||||
"moment": "^2.29.4",
|
||||
"rxjs": "~7.5.0",
|
||||
"tslib": "^2.3.0",
|
||||
"zone.js": "~0.14.4"
|
||||
"zone.js": "~0.14.10"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@angular-devkit/build-angular": "^17.3.2",
|
||||
"@angular/compiler-cli": "^17.3.2",
|
||||
"@angular-devkit/build-angular": "^18.2.19",
|
||||
"@angular/compiler-cli": "^18.2.13",
|
||||
"@types/jasmine": "~4.3.0",
|
||||
"jasmine-core": "~4.5.0",
|
||||
"karma": "~6.4.0",
|
||||
|
||||
@@ -9,7 +9,7 @@ import { MatSnackBar } from '@angular/material/snack-bar';
|
||||
import { UserResetComponent } from '../user-reset/user-reset.component';
|
||||
import { catchError, throwError } from 'rxjs';
|
||||
import { Moment } from 'moment';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
|
||||
export namespace UserEditComponent {
|
||||
export type InputData = {type: "new" | "edit", id?: string, groups: Group[]}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
|
||||
import { AdminCommService } from './admin-comm.service';
|
||||
import { HttpClient } from '@angular/common/http';
|
||||
import { HttpClientTestingModule, HttpTestingController } from '@angular/common/http/testing';
|
||||
import { HttpClient, provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';
|
||||
import { HttpTestingController, provideHttpClientTesting } from '@angular/common/http/testing';
|
||||
|
||||
describe('AdminCommService', () => {
|
||||
let service: AdminCommService;
|
||||
@@ -11,8 +11,9 @@ describe('AdminCommService', () => {
|
||||
|
||||
beforeEach(() => {
|
||||
TestBed.configureTestingModule({
|
||||
imports: [ HttpClientTestingModule ]
|
||||
});
|
||||
imports: [],
|
||||
providers: [provideHttpClient(withInterceptorsFromDi()), provideHttpClientTesting()]
|
||||
});
|
||||
service = TestBed.inject(AdminCommService);
|
||||
httpClient = TestBed.inject(HttpClient);
|
||||
httpTestingController = TestBed.inject(HttpTestingController);
|
||||
|
||||
@@ -9,7 +9,7 @@ import { map, of } from 'rxjs';
|
||||
import { Notification } from '../types/notification';
|
||||
import { News } from '../types/news';
|
||||
import { AKey } from '../types/key';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
import { IUSettings } from './settings/settings.component';
|
||||
import User from '../types/user';
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { Component, Input } from '@angular/core';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
|
||||
@Component({
|
||||
selector: 'app-hour-display',
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Component, OnDestroy, OnInit } from '@angular/core';
|
||||
import { AdminCommService } from '../admin-comm.service';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
import { FormArray, FormBuilder } from '@angular/forms';
|
||||
import { weekendFilter } from 'src/app/fd.da';
|
||||
import { MatSnackBar } from '@angular/material/snack-bar';
|
||||
|
||||
@@ -2,7 +2,7 @@ import { Component, OnInit } from '@angular/core';
|
||||
import { AdminCommService } from '../../admin-comm.service';
|
||||
import { Router, ActivatedRoute } from '@angular/router';
|
||||
import { ToolbarService } from '../../toolbar/toolbar.service';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
|
||||
@Component({
|
||||
selector: 'app-outbox',
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Component, Inject } from '@angular/core';
|
||||
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
import { UpdatesService } from 'src/app/services/updates.service';
|
||||
|
||||
@Component({
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
import { weekendFilter } from 'src/app/fd.da';
|
||||
import { UpdatesService } from 'src/app/services/updates.service';
|
||||
import { CleanNote } from 'src/app/types/clean-note';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { NgModule, isDevMode } from '@angular/core';
|
||||
import { BrowserModule } from '@angular/platform-browser';
|
||||
|
||||
import { HttpClientModule } from '@angular/common/http';
|
||||
import { provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';
|
||||
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
||||
import { MAT_MOMENT_DATE_ADAPTER_OPTIONS, MAT_MOMENT_DATE_FORMATS, MomentDateAdapter } from '@angular/material-moment-adapter';
|
||||
import { MatButtonModule } from "@angular/material/button";
|
||||
@@ -88,108 +88,102 @@ import { NotifDialogComponent } from './app-view/notif-dialog/notif-dialog.compo
|
||||
import { UserSearchComponent } from './commonComponents/user-search/user-search.component';
|
||||
import { StartAdminComponent } from './admin-view/start/start.component';
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
AppComponent,
|
||||
NewsComponent,
|
||||
MenuComponent,
|
||||
LoginComponent,
|
||||
AppViewComponent,
|
||||
PersonalComponent,
|
||||
ChangePasswordDialogComponent,
|
||||
LogoutConfirmationComponent,
|
||||
DateSelectorComponent,
|
||||
AdminViewComponent,
|
||||
MenuUploadComponent,
|
||||
NewsEditComponent,
|
||||
NewPostComponent,
|
||||
AccountMgmtComponent,
|
||||
UserEditComponent,
|
||||
UserDeleteComponent,
|
||||
MenuNewComponent,
|
||||
CeDirective,
|
||||
LabelDirective,
|
||||
AllergensComponent,
|
||||
UserResetComponent,
|
||||
NotificationsComponent,
|
||||
GroupsComponent,
|
||||
ListEditorComponent,
|
||||
RemoveConfirmComponent,
|
||||
StartComponent,
|
||||
KeyComponent,
|
||||
AdminKeyComponent,
|
||||
NewKeyComponent,
|
||||
GradesComponent,
|
||||
RoomChooserComponent,
|
||||
CleanComponent,
|
||||
SummaryComponent,
|
||||
SettingsComponent,
|
||||
MenuAddComponent,
|
||||
FieldEditorComponent,
|
||||
AttendenceComponent,
|
||||
AttendenceSummaryComponent,
|
||||
HourDisplayComponent,
|
||||
AboutComponent,
|
||||
ExtraComponent,
|
||||
RedirectComponent,
|
||||
OutboxComponent,
|
||||
ToolbarComponent,
|
||||
MessageComponent,
|
||||
NotifDialogComponent,
|
||||
UserSearchComponent,
|
||||
StartAdminComponent,
|
||||
],
|
||||
imports: [
|
||||
BrowserModule,
|
||||
AppRoutingModule,
|
||||
BrowserAnimationsModule,
|
||||
MatTabsModule,
|
||||
HttpClientModule,
|
||||
MatCardModule,
|
||||
MatButtonModule,
|
||||
MatIconModule,
|
||||
MatDatepickerModule,
|
||||
MatNativeDateModule,
|
||||
MatInputModule,
|
||||
ReactiveFormsModule,
|
||||
FormsModule,
|
||||
MatDialogModule,
|
||||
MatListModule,
|
||||
MatToolbarModule,
|
||||
MatSidenavModule,
|
||||
MatSnackBarModule,
|
||||
MatTableModule,
|
||||
MatPaginatorModule,
|
||||
MatSelectModule,
|
||||
MatBottomSheetModule,
|
||||
MatSlideToggleModule,
|
||||
MatProgressSpinnerModule,
|
||||
MatRadioModule,
|
||||
MatChipsModule,
|
||||
MatCheckboxModule,
|
||||
MatMenuModule,
|
||||
MatSortModule,
|
||||
MatButtonToggleModule,
|
||||
MatExpansionModule,
|
||||
DragDropModule,
|
||||
MatBadgeModule,
|
||||
PortalModule,
|
||||
A11yModule,
|
||||
MatAutocompleteModule,
|
||||
ServiceWorkerModule.register('ngsw-worker.js', {
|
||||
enabled: environment.production,
|
||||
// Register the ServiceWorker as soon as the application is stable
|
||||
// or after 30 seconds (whichever comes first).
|
||||
registrationStrategy: 'registerWhenStable:30000'
|
||||
}),
|
||||
],
|
||||
providers: [
|
||||
{ provide: DateAdapter, useClass: MomentDateAdapter, deps: [MAT_DATE_LOCALE, MAT_DATE_FORMATS, MAT_MOMENT_DATE_ADAPTER_OPTIONS] },
|
||||
{ provide: MAT_DATE_LOCALE, useValue: "pl-PL" },
|
||||
{ provide: MAT_DATE_FORMATS, useValue: MAT_MOMENT_DATE_FORMATS },
|
||||
{ provide: MAT_MOMENT_DATE_ADAPTER_OPTIONS, useValue: { useUtc: true } },
|
||||
FDSelection,
|
||||
],
|
||||
bootstrap: [AppComponent],
|
||||
})
|
||||
@NgModule({ declarations: [
|
||||
AppComponent,
|
||||
NewsComponent,
|
||||
MenuComponent,
|
||||
LoginComponent,
|
||||
AppViewComponent,
|
||||
PersonalComponent,
|
||||
ChangePasswordDialogComponent,
|
||||
LogoutConfirmationComponent,
|
||||
DateSelectorComponent,
|
||||
AdminViewComponent,
|
||||
MenuUploadComponent,
|
||||
NewsEditComponent,
|
||||
NewPostComponent,
|
||||
AccountMgmtComponent,
|
||||
UserEditComponent,
|
||||
UserDeleteComponent,
|
||||
MenuNewComponent,
|
||||
CeDirective,
|
||||
LabelDirective,
|
||||
AllergensComponent,
|
||||
UserResetComponent,
|
||||
NotificationsComponent,
|
||||
GroupsComponent,
|
||||
ListEditorComponent,
|
||||
RemoveConfirmComponent,
|
||||
StartComponent,
|
||||
KeyComponent,
|
||||
AdminKeyComponent,
|
||||
NewKeyComponent,
|
||||
GradesComponent,
|
||||
RoomChooserComponent,
|
||||
CleanComponent,
|
||||
SummaryComponent,
|
||||
SettingsComponent,
|
||||
MenuAddComponent,
|
||||
FieldEditorComponent,
|
||||
AttendenceComponent,
|
||||
AttendenceSummaryComponent,
|
||||
HourDisplayComponent,
|
||||
AboutComponent,
|
||||
ExtraComponent,
|
||||
RedirectComponent,
|
||||
OutboxComponent,
|
||||
ToolbarComponent,
|
||||
MessageComponent,
|
||||
NotifDialogComponent,
|
||||
UserSearchComponent,
|
||||
StartAdminComponent,
|
||||
],
|
||||
bootstrap: [AppComponent], imports: [BrowserModule,
|
||||
AppRoutingModule,
|
||||
BrowserAnimationsModule,
|
||||
MatTabsModule,
|
||||
MatCardModule,
|
||||
MatButtonModule,
|
||||
MatIconModule,
|
||||
MatDatepickerModule,
|
||||
MatNativeDateModule,
|
||||
MatInputModule,
|
||||
ReactiveFormsModule,
|
||||
FormsModule,
|
||||
MatDialogModule,
|
||||
MatListModule,
|
||||
MatToolbarModule,
|
||||
MatSidenavModule,
|
||||
MatSnackBarModule,
|
||||
MatTableModule,
|
||||
MatPaginatorModule,
|
||||
MatSelectModule,
|
||||
MatBottomSheetModule,
|
||||
MatSlideToggleModule,
|
||||
MatProgressSpinnerModule,
|
||||
MatRadioModule,
|
||||
MatChipsModule,
|
||||
MatCheckboxModule,
|
||||
MatMenuModule,
|
||||
MatSortModule,
|
||||
MatButtonToggleModule,
|
||||
MatExpansionModule,
|
||||
DragDropModule,
|
||||
MatBadgeModule,
|
||||
PortalModule,
|
||||
A11yModule,
|
||||
MatAutocompleteModule,
|
||||
ServiceWorkerModule.register('ngsw-worker.js', {
|
||||
enabled: environment.production,
|
||||
// Register the ServiceWorker as soon as the application is stable
|
||||
// or after 30 seconds (whichever comes first).
|
||||
registrationStrategy: 'registerWhenStable:30000'
|
||||
})], providers: [
|
||||
{ provide: DateAdapter, useClass: MomentDateAdapter, deps: [MAT_DATE_LOCALE, MAT_DATE_FORMATS, MAT_MOMENT_DATE_ADAPTER_OPTIONS] },
|
||||
{ provide: MAT_DATE_LOCALE, useValue: "pl-PL" },
|
||||
{ provide: MAT_DATE_FORMATS, useValue: MAT_MOMENT_DATE_FORMATS },
|
||||
{ provide: MAT_MOMENT_DATE_ADAPTER_OPTIONS, useValue: { useUtc: true } },
|
||||
FDSelection,
|
||||
provideHttpClient(withInterceptorsFromDi()),
|
||||
] })
|
||||
export class AppModule { }
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core';
|
||||
import { FormControl } from '@angular/forms';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
|
||||
@Component({
|
||||
selector: 'app-date-selector',
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Injectable } from "@angular/core";
|
||||
import { DateRange, MatDateRangeSelectionStrategy } from "@angular/material/datepicker";
|
||||
import * as moment from "moment";
|
||||
import moment from "moment";
|
||||
|
||||
@Injectable()
|
||||
export class FDSelection implements MatDateRangeSelectionStrategy<moment.Moment> {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
|
||||
import { AuthClient } from './auth.client';
|
||||
import { HttpClient } from '@angular/common/http';
|
||||
import { HttpClientTestingModule, HttpTestingController } from '@angular/common/http/testing'
|
||||
import { HttpClient, provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';
|
||||
import { HttpTestingController, provideHttpClientTesting } from '@angular/common/http/testing'
|
||||
|
||||
describe('AuthService', () => {
|
||||
let service: AuthClient;
|
||||
@@ -11,8 +11,9 @@ describe('AuthService', () => {
|
||||
|
||||
beforeEach(() => {
|
||||
TestBed.configureTestingModule({
|
||||
imports: [ HttpClientTestingModule ]
|
||||
});
|
||||
imports: [],
|
||||
providers: [provideHttpClient(withInterceptorsFromDi()), provideHttpClientTesting()]
|
||||
});
|
||||
service = TestBed.inject(AuthClient);
|
||||
httpClient = TestBed.inject(HttpClient);
|
||||
httpTestingController = TestBed.inject(HttpTestingController);
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
|
||||
import { UpdatesService } from './updates.service';
|
||||
import { HttpClientTestingModule, HttpTestingController } from '@angular/common/http/testing';
|
||||
import { HttpClient } from '@angular/common/http';
|
||||
import { HttpTestingController, provideHttpClientTesting } from '@angular/common/http/testing';
|
||||
import { HttpClient, provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';
|
||||
|
||||
describe('UpdatesService', () => {
|
||||
let service: UpdatesService;
|
||||
@@ -11,8 +11,9 @@ describe('UpdatesService', () => {
|
||||
|
||||
beforeEach(() => {
|
||||
TestBed.configureTestingModule({
|
||||
imports: [ HttpClientTestingModule]
|
||||
});
|
||||
imports: [],
|
||||
providers: [provideHttpClient(withInterceptorsFromDi()), provideHttpClientTesting()]
|
||||
});
|
||||
service = TestBed.inject(UpdatesService);
|
||||
httpClient = TestBed.inject(HttpClient);
|
||||
httpTestingController = TestBed.inject(HttpTestingController);
|
||||
|
||||
@@ -3,7 +3,7 @@ import { HttpClient } from '@angular/common/http'
|
||||
import { Menu } from '../types/menu';
|
||||
import { environment } from 'src/environments/environment';
|
||||
import { News } from '../types/news';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment';
|
||||
import { map } from 'rxjs';
|
||||
import { UKey } from '../types/key';
|
||||
import { CleanNote } from '../types/clean-note';
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
"baseUrl": "./",
|
||||
"outDir": "./dist/out-tsc",
|
||||
"forceConsistentCasingInFileNames": true,
|
||||
"esModuleInterop": true,
|
||||
"strict": true,
|
||||
"noImplicitOverride": true,
|
||||
"noPropertyAccessFromIndexSignature": true,
|
||||
@@ -12,7 +13,6 @@
|
||||
"noFallthroughCasesInSwitch": true,
|
||||
"sourceMap": true,
|
||||
"declaration": false,
|
||||
"downlevelIteration": true,
|
||||
"experimentalDecorators": true,
|
||||
"moduleResolution": "node",
|
||||
"importHelpers": true,
|
||||
|
||||
Reference in New Issue
Block a user