Merge pull request #6146 from tsiegleauq/angular12

Update to Angular12
This commit is contained in:
Sean 2021-07-13 14:36:38 +02:00 committed by GitHub
commit 18f2e3326d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
267 changed files with 29186 additions and 9065 deletions

7
client/.browserslistrc Normal file
View File

@ -0,0 +1,7 @@
last 1 Chrome version
last 1 Firefox version
last 2 Edge major versions
last 2 Safari major versions
last 2 iOS major versions
Firefox ESR
not IE 11

View File

@ -22,7 +22,6 @@
"main": "src/main.ts", "main": "src/main.ts",
"polyfills": "src/polyfills.ts", "polyfills": "src/polyfills.ts",
"tsConfig": "tsconfig.app.json", "tsConfig": "tsconfig.app.json",
"aot": true,
"assets": [ "assets": [
"src/assets", "src/assets",
"src/manifest.json", "src/manifest.json",
@ -43,7 +42,13 @@
"node_modules/video.js/dist/video.min.js", "node_modules/video.js/dist/video.min.js",
"src/assets/jitsi/external_api.js" "src/assets/jitsi/external_api.js"
], ],
"webWorkerTsConfig": "tsconfig.worker.json" "webWorkerTsConfig": "tsconfig.worker.json",
"vendorChunk": true,
"extractLicenses": false,
"buildOptimizer": false,
"sourceMap": true,
"optimization": false,
"namedChunks": true
}, },
"configurations": { "configurations": {
"production": { "production": {
@ -56,9 +61,7 @@
"optimization": true, "optimization": true,
"outputHashing": "all", "outputHashing": "all",
"sourceMap": false, "sourceMap": false,
"extractCss": true,
"namedChunks": false, "namedChunks": false,
"aot": true,
"extractLicenses": true, "extractLicenses": true,
"vendorChunk": false, "vendorChunk": false,
"buildOptimizer": true, "buildOptimizer": true,
@ -83,13 +86,14 @@
} }
], ],
"tsConfig": "./tsconfig-es5.app.json" "tsConfig": "./tsconfig-es5.app.json"
} },
} "development": {}
},
"defaultConfiguration": "production"
}, },
"serve": { "serve": {
"builder": "@angular-devkit/build-angular:dev-server", "builder": "@angular-devkit/build-angular:dev-server",
"options": { "options": {
"browserTarget": "client:build"
}, },
"configurations": { "configurations": {
"production": { "production": {
@ -97,8 +101,12 @@
}, },
"es5": { "es5": {
"browserTarget": "client:build:es5" "browserTarget": "client:build:es5"
},
"development": {
"browserTarget": "client:build:development"
} }
} },
"defaultConfiguration": "development"
}, },
"extract-i18n": { "extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n", "builder": "@angular-devkit/build-angular:extract-i18n",
@ -147,14 +155,17 @@
"e2e": { "e2e": {
"builder": "@angular-devkit/build-angular:protractor", "builder": "@angular-devkit/build-angular:protractor",
"options": { "options": {
"protractorConfig": "e2e/protractor.conf.js", "protractorConfig": "e2e/protractor.conf.js"
"devServerTarget": "client:serve"
}, },
"configurations": { "configurations": {
"production": { "production": {
"devServerTarget": "client:serve:production" "devServerTarget": "client:serve:production"
},
"development": {
"devServerTarget": "client:serve:development"
} }
} },
"defaultConfiguration": "development"
} }
} }
} }

View File

@ -1,9 +0,0 @@
# This file is currently used by autoprefixer to adjust CSS to support the below specified browsers
# For additional information regarding the format and rule options, please see:
# https://github.com/browserslist/browserslist#queries
# For IE 9-11 support, please uncomment the last line of the file and adjust as needed
> 0.5%
last 2 versions
Firefox ESR
not dead
IE 9-11

View File

@ -6,7 +6,7 @@ RUN useradd -m openslides
RUN chown -R openslides /build/app RUN chown -R openslides /build/app
USER root USER root
RUN npm install -g @angular/cli@^10 RUN npm install -g @angular/cli@^12
RUN ng config -g cli.warnings.versionMismatch false RUN ng config -g cli.warnings.versionMismatch false
USER openslides USER openslides

View File

@ -9,19 +9,25 @@ module.exports = function (config) {
require('karma-jasmine'), require('karma-jasmine'),
require('karma-chrome-launcher'), require('karma-chrome-launcher'),
require('karma-jasmine-html-reporter'), require('karma-jasmine-html-reporter'),
require('karma-coverage-istanbul-reporter'), require('karma-coverage'),
require('@angular-devkit/build-angular/plugins/karma') require('@angular-devkit/build-angular/plugins/karma')
], ],
client: { client: {
clearContext: false, // leave Jasmine Spec Runner output visible in browser clearContext: false, // leave Jasmine Spec Runner output visible in browser
jasmine: { jasmine: {
timeoutInterval: 10000 // you can add configuration options for Jasmine here
} // the possible options are listed at https://jasmine.github.io/api/edge/Configuration.html
// for example, you can disable the random execution with `random: false`
// or set a specific seed with `seed: 4321`
},
}, },
coverageIstanbulReporter: { jasmineHtmlReporter: {
dir: require('path').join(__dirname, '../coverage'), suppressAll: true // removes the duplicated traces
reports: ['html', 'lcovonly'], },
fixWebpackSourcePaths: true coverageReporter: {
dir: require('path').join(__dirname, './coverage/Test'),
subdir: '.',
reporters: [{ type: 'html' }, { type: 'text-summary' }]
}, },
reporters: ['progress', 'kjhtml'], reporters: ['progress', 'kjhtml'],
port: 9876, port: 9876,
@ -36,11 +42,6 @@ module.exports = function (config) {
} }
}, },
singleRun: false, singleRun: false,
proxies: { restartOnFileChange: true
'/apps/': 'http://localhost:8000/apps/',
'/media/': 'http://localhost:8000/media/',
'/rest/': 'http://localhost:8000/rest/',
'/ws/': 'ws://localhost:8000/'
}
}); });
}; };

34493
client/package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
{ {
"name": "OpenSlides3-Client", "name": "OpenSlides3-Client",
"version": "3.3.0", "version": "3.4.0",
"repository": { "repository": {
"type": "git", "type": "git",
"url": "git://github.com/OpenSlides/OpenSlides.git" "url": "git://github.com/OpenSlides/OpenSlides.git"
@ -10,14 +10,15 @@
"README": "https://github.com/OpenSlides/OpenSlides/blob/master/client/README.md", "README": "https://github.com/OpenSlides/OpenSlides/blob/master/client/README.md",
"scripts": { "scripts": {
"ng": "ng", "ng": "ng",
"start": "ng serve --proxy-config proxy.conf.json --host=0.0.0.0", "ng-high-memory": "node --max_old_space_size=4096 ./node_modules/@angular/cli/bin/ng",
"start-https": "ng serve --ssl --ssl-cert localhost.pem --ssl-key localhost-key.pem --proxy-config proxy.conf.json --host=0.0.0.0", "start": "npm run ng-high-memory -- serve --proxy-config proxy.conf.json --host=0.0.0.0",
"start-es5": "ng serve --proxy-config proxy.conf.json --host=0.0.0.0 --configuration es5", "start-https": "npm run ng-high-memory -- serve --ssl --ssl-cert localhost.pem --ssl-key localhost-key.pem --proxy-config proxy.conf.json --host=0.0.0.0",
"build": "ng build --prod", "start-es5": "npm run ng-high-memory -- serve --proxy-config proxy.conf.json --host=0.0.0.0 --configuration es5",
"build": "npm run ng-high-memory -- build --configuration production",
"build-to-dir": "npm run build -- --output-path", "build-to-dir": "npm run build -- --output-path",
"postinstall": "ngcc", "postinstall": "ngcc",
"build-debug": "ng build", "build-debug": "npm run ng-high-memory -- build",
"test": "ng test", "test": "npm run ng-high-memory -- test",
"test-silently": "npm run test -- --watch=false --no-progress --browsers=ChromeHeadlessNoSandbox", "test-silently": "npm run test -- --watch=false --no-progress --browsers=ChromeHeadlessNoSandbox",
"test-live": "npm run test -- --watch=true --browsers=ChromeHeadlessNoSandbox", "test-live": "npm run test -- --watch=true --browsers=ChromeHeadlessNoSandbox",
"lint-check": "ng lint", "lint-check": "ng lint",
@ -35,27 +36,27 @@
"cleanup-win": "npm run prettify-write & npm run lint-write" "cleanup-win": "npm run prettify-write & npm run lint-write"
}, },
"dependencies": { "dependencies": {
"@angular/animations": "~10.0.14", "@angular/animations": "~12.1.1",
"@angular/cdk": "~10.0.0", "@angular/cdk": "~12.1.1",
"@angular/cdk-experimental": "~10.0.0", "@angular/cdk-experimental": "~12.1.1",
"@angular/common": "~10.0.14", "@angular/common": "~12.1.1",
"@angular/compiler": "~10.0.14", "@angular/compiler": "~12.1.1",
"@angular/core": "~10.0.14", "@angular/core": "~12.1.1",
"@angular/forms": "~10.0.14", "@angular/forms": "~12.1.1",
"@angular/material": "~10.0.0", "@angular/material": "~12.1.1",
"@angular/material-moment-adapter": "~10.1.3", "@angular/material-moment-adapter": "~12.1.1",
"@angular/platform-browser": "~10.0.14", "@angular/platform-browser": "~12.1.1",
"@angular/platform-browser-dynamic": "~10.0.14", "@angular/platform-browser-dynamic": "~12.1.1",
"@angular/router": "~10.0.14", "@angular/router": "~12.1.1",
"@angular/service-worker": "~10.0.14", "@angular/service-worker": "~12.1.1",
"@ngx-pwa/local-storage": "~10.0.1", "@ngx-pwa/local-storage": "~12.0.0",
"@ngx-translate/core": "~13.0.0", "@ngx-translate/core": "~13.0.0",
"@ngx-translate/http-loader": "^6.0.0", "@ngx-translate/http-loader": "^6.0.0",
"@pebula/ngrid": "2.0.0", "@pebula/ngrid": "4.0.0-alpha.3",
"@pebula/ngrid-material": "2.0.0", "@pebula/ngrid-material": "4.0.0-alpha.3",
"@pebula/utils": "1.0.2", "@pebula/utils": "1.0.2",
"@tinymce/tinymce-angular": "^4.1.0", "@tinymce/tinymce-angular": "^4.2.4",
"@videojs/http-streaming": "^1.13.3", "@videojs/http-streaming": "^2.9.1",
"acorn": "^8.0.1", "acorn": "^8.0.1",
"chart.js": "^2.9.3", "chart.js": "^2.9.3",
"core-js": "^3.6.5", "core-js": "^3.6.5",
@ -64,14 +65,14 @@
"file-saver": "^2.0.2", "file-saver": "^2.0.2",
"jszip": "^3.5.0", "jszip": "^3.5.0",
"lz4js": "^0.2.0", "lz4js": "^0.2.0",
"material-icon-font": "git+https://github.com/petergng/materialIconFont.git", "material-design-icons-iconfont": "6.1.0",
"moment": "^2.27.0", "moment": "^2.27.0",
"ng-particles": "^2.6.0", "ng-particles": "^2.6.0",
"ng2-charts": "^2.4.0", "ng2-charts": "^2.4.0",
"ng2-pdf-viewer": "^6.4.1", "ng2-pdf-viewer": "^6.4.1",
"ngx-device-detector": "^2.0.0", "ngx-device-detector": "^2.0.0",
"ngx-file-drop": "^9.0.1", "ngx-file-drop": "^11.1.0",
"ngx-mat-select-search": "^3.0.3", "ngx-mat-select-search": "^3.3.0",
"ngx-material-timepicker": "^5.5.3", "ngx-material-timepicker": "^5.5.3",
"ngx-papaparse": "^4.0.4", "ngx-papaparse": "^4.0.4",
"pdfjs-dist": "2.5.207", "pdfjs-dist": "2.5.207",
@ -79,41 +80,38 @@
"po2json": "^1.0.0-beta-2", "po2json": "^1.0.0-beta-2",
"rxjs": "^6.6.2", "rxjs": "^6.6.2",
"tinymce": "5.7.1", "tinymce": "5.7.1",
"tslib": "^1.10.0", "tslib": "^2.0.0",
"tsparticles": "^1.23.0", "tsparticles": "^1.23.0",
"video.js": "^7.8.4", "video.js": "^7.8.4",
"zone.js": "~0.10.2" "zone.js": "~0.11.4"
}, },
"devDependencies": { "devDependencies": {
"@angular-devkit/build-angular": "~0.1000.8", "@angular-devkit/build-angular": "~12.1.1",
"@angular-devkit/schematics": "^10.0.8", "@angular-devkit/schematics": "^12.1.1",
"@angular/cli": "~10.0.8", "@angular/cli": "~12.1.1",
"@angular/compiler-cli": "~10.0.14", "@angular/compiler-cli": "~12.1.1",
"@angular/language-service": "~10.0.14", "@angular/language-service": "~12.1.1",
"@biesbjerg/ngx-translate-extract": "^7.0.2", "@biesbjerg/ngx-translate-extract": "^7.0.4",
"@biesbjerg/ngx-translate-extract-marker": "^1.0.0", "@biesbjerg/ngx-translate-extract-marker": "^1.0.0",
"@compodoc/compodoc": "^1.1.11", "@compodoc/compodoc": "^1.0.9",
"@schematics/angular": "^10.0.8", "@schematics/angular": "^10.0.8",
"@types/jasmine": "^3.5.14", "@types/jasmine": "~3.6.0",
"@types/jasminewd2": "^2.0.6",
"@types/node": "^14.6.2", "@types/node": "^14.6.2",
"@types/yargs": "^15.0.4", "@types/yargs": "^15.0.4",
"codelyzer": "^6.0.0", "codelyzer": "^6.0.0",
"husky": "^4.2.3", "husky": "^4.2.3",
"jasmine-core": "~3.6.0", "jasmine-core": "~3.8.0",
"jasmine-spec-reporter": "~5.0.1", "karma": "^6.3.4",
"karma": "^5.1.1",
"karma-chrome-launcher": "~3.1.0", "karma-chrome-launcher": "~3.1.0",
"karma-coverage-istanbul-reporter": "^3.0.3", "karma-coverage": "~2.0.3",
"karma-jasmine": "~4.0.1", "karma-jasmine": "~4.0.0",
"karma-jasmine-html-reporter": "^1.4.0", "karma-jasmine-html-reporter": "^1.5.0",
"npm-license-crawler": "^0.2.1", "prettier": "2.3.2",
"prettier": "~2.1.1",
"protractor": "^7.0.0", "protractor": "^7.0.0",
"resize-observer-polyfill": "^1.5.1", "resize-observer-polyfill": "^1.5.1",
"ts-node": "~9.0.0", "ts-node": "~9.0.0",
"tslint": "~6.1.3", "tslint": "~6.1.3",
"tsutils": "3.17.1", "tsutils": "3.17.1",
"typescript": "~3.9.7" "typescript": "~4.3.5"
} }
} }

View File

@ -36,7 +36,7 @@ const routes: Route[] = [
]; ];
@NgModule({ @NgModule({
imports: [RouterModule.forRoot(routes, { onSameUrlNavigation: 'reload' })], imports: [RouterModule.forRoot(routes, { onSameUrlNavigation: 'reload', relativeLinkResolution: 'legacy' })],
exports: [RouterModule] exports: [RouterModule]
}) })
export class AppRoutingModule {} export class AppRoutingModule {}

View File

@ -442,7 +442,7 @@ export class PdfDocumentService {
const isIE = /msie\s|trident\//i.test(window.navigator.userAgent); const isIE = /msie\s|trident\//i.test(window.navigator.userAgent);
if (typeof Worker !== 'undefined' && !isIE) { if (typeof Worker !== 'undefined' && !isIE) {
this.pdfWorker = new Worker('./pdf-worker.worker', { this.pdfWorker = new Worker(new URL('./pdf-worker.worker', import.meta.url), {
type: 'module' type: 'module'
}); });

View File

@ -36,9 +36,8 @@ export abstract class BaseIsAgendaItemAndListOfSpeakersContentObjectRepository<
T extends TitleInformationWithAgendaItem T extends TitleInformationWithAgendaItem
> >
extends BaseRepository<V, M, T> extends BaseRepository<V, M, T>
implements implements IBaseIsAgendaItemContentObjectRepository<V, M, T>, IBaseIsListOfSpeakersContentObjectRepository<V, M, T>
IBaseIsAgendaItemContentObjectRepository<V, M, T>, {
IBaseIsListOfSpeakersContentObjectRepository<V, M, T> {
protected extendRelations(): void { protected extendRelations(): void {
this.relationDefinitions.push({ this.relationDefinitions.push({
type: 'M2O', type: 'M2O',

View File

@ -43,7 +43,8 @@ export abstract class BaseIsAgendaItemContentObjectRepository<
T extends TitleInformationWithAgendaItem T extends TitleInformationWithAgendaItem
> >
extends BaseRepository<V, M, T> extends BaseRepository<V, M, T>
implements IBaseIsAgendaItemContentObjectRepository<V, M, T> { implements IBaseIsAgendaItemContentObjectRepository<V, M, T>
{
public constructor( public constructor(
DS: DataStoreService, DS: DataStoreService,
dataSend: DataSendService, dataSend: DataSendService,

View File

@ -40,7 +40,8 @@ export abstract class BaseIsListOfSpeakersContentObjectRepository<
T extends TitleInformation T extends TitleInformation
> >
extends BaseRepository<V, M, T> extends BaseRepository<V, M, T>
implements IBaseIsListOfSpeakersContentObjectRepository<V, M, T> { implements IBaseIsListOfSpeakersContentObjectRepository<V, M, T>
{
public constructor( public constructor(
DS: DataStoreService, DS: DataStoreService,
dataSend: DataSendService, dataSend: DataSendService,

View File

@ -31,7 +31,8 @@ export interface NestedModelDescriptors {
} }
export abstract class BaseRepository<V extends BaseViewModel & T, M extends BaseModel, T extends TitleInformation> export abstract class BaseRepository<V extends BaseViewModel & T, M extends BaseModel, T extends TitleInformation>
implements OnAfterAppsLoaded, Collection, HasViewModelListObservable<V> { implements OnAfterAppsLoaded, Collection, HasViewModelListObservable<V>
{
/** /**
* Stores all the viewModel in an object * Stores all the viewModel in an object
*/ */

View File

@ -890,28 +890,19 @@ export class MotionRepositoryService extends BaseIsAgendaItemAndListOfSpeakersCo
} }
return amendmentParagraphs return amendmentParagraphs
?.map( ?.map((newText: string, paraNo: number): DiffLinesInParagraph => {
(newText: string, paraNo: number): DiffLinesInParagraph => { if (baseParagraphs[paraNo] === undefined) {
if (baseParagraphs[paraNo] === undefined) { throw new Error(
throw new Error( this.translate.instant('Inconsistent data.') +
this.translate.instant('Inconsistent data.') + ' ' +
' ' + this.translate.instant('An amendment is probably referring to a non-existant line number.')
this.translate.instant( );
'An amendment is probably referring to a non-existant line number.' } else if (newText !== null) {
) return this.diff.getAmendmentParagraphsLines(paraNo, baseParagraphs[paraNo], newText, lineLength);
); } else {
} else if (newText !== null) { return null; // Nothing has changed in this paragraph
return this.diff.getAmendmentParagraphsLines(
paraNo,
baseParagraphs[paraNo],
newText,
lineLength
);
} else {
return null; // Nothing has changed in this paragraph
}
} }
) })
.map((diffLines: DiffLinesInParagraph, paraNo: number) => { .map((diffLines: DiffLinesInParagraph, paraNo: number) => {
// If nothing has changed and we want to keep unchanged paragraphs for the context, // If nothing has changed and we want to keep unchanged paragraphs for the context,
// return the original text in "textPre" // return the original text in "textPre"
@ -969,37 +960,33 @@ export class MotionRepositoryService extends BaseIsAgendaItemAndListOfSpeakersCo
const changedAmendmentParagraphs = this.applyChangesToAmendment(amendment, lineLength, changeRecos, false); const changedAmendmentParagraphs = this.applyChangesToAmendment(amendment, lineLength, changeRecos, false);
return changedAmendmentParagraphs return changedAmendmentParagraphs
?.map( ?.map((newText: string, paraNo: number): ViewMotionAmendedParagraph => {
(newText: string, paraNo: number): ViewMotionAmendedParagraph => { if (newText === null) {
if (newText === null) { return null;
return null;
}
if (baseParagraphs[paraNo] === undefined) {
console.error(
this.translate.instant('Inconsistent data.') +
' ' +
this.translate.instant(
'An amendment is probably referring to a non-existant line number.'
)
);
return null;
}
const origText = baseParagraphs[paraNo],
diff = this.diff.diff(origText, newText),
affectedLines = this.diff.detectAffectedLineRange(diff);
if (affectedLines === null) {
return null;
}
const affectedDiff = this.diff.formatDiff(
this.diff.extractRangeByLineNumbers(diff, affectedLines.from, affectedLines.to)
);
const affectedConsolidated = this.diff.diffHtmlToFinalText(affectedDiff);
return new ViewMotionAmendedParagraph(amendment, paraNo, affectedConsolidated, affectedLines);
} }
) if (baseParagraphs[paraNo] === undefined) {
console.error(
this.translate.instant('Inconsistent data.') +
' ' +
this.translate.instant('An amendment is probably referring to a non-existant line number.')
);
return null;
}
const origText = baseParagraphs[paraNo],
diff = this.diff.diff(origText, newText),
affectedLines = this.diff.detectAffectedLineRange(diff);
if (affectedLines === null) {
return null;
}
const affectedDiff = this.diff.formatDiff(
this.diff.extractRangeByLineNumbers(diff, affectedLines.from, affectedLines.to)
);
const affectedConsolidated = this.diff.diffHtmlToFinalText(affectedDiff);
return new ViewMotionAmendedParagraph(amendment, paraNo, affectedConsolidated, affectedLines);
})
.filter((para: ViewMotionAmendedParagraph) => para !== null); .filter((para: ViewMotionAmendedParagraph) => para !== null);
} }

View File

@ -233,7 +233,7 @@ export abstract class BaseImportService<M extends BaseModel> {
/** /**
* Trigger for executing the import. * Trigger for executing the import.
*/ */
public abstract async doImport(): Promise<void>; public abstract doImport(): Promise<void>;
/** /**
* counts the amount of duplicates that have no decision on the action to * counts the amount of duplicates that have no decision on the action to

View File

@ -121,7 +121,7 @@ export abstract class BaseSortListService<V extends BaseViewModel> extends BaseS
/** /**
* Enforce children to implement a method that returns the fault sorting * Enforce children to implement a method that returns the fault sorting
*/ */
protected abstract async getDefaultDefinition(): Promise<OsSortingDefinition<V>>; protected abstract getDefaultDefinition(): Promise<OsSortingDefinition<V>>;
/** /**
* Defines the sorting properties, and returns an observable with sorted data * Defines the sorting properties, and returns an observable with sorted data

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -9,11 +9,13 @@ describe('FullscreenProjectorComponent', () => {
let component: FullscreenProjectorComponent; let component: FullscreenProjectorComponent;
let fixture: ComponentFixture<FullscreenProjectorComponent>; let fixture: ComponentFixture<FullscreenProjectorComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule, FullscreenProjectorModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule, FullscreenProjectorModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(FullscreenProjectorComponent); fixture = TestBed.createComponent(FullscreenProjectorComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { FormBuilder } from '@angular/forms'; import { FormBuilder } from '@angular/forms';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -9,11 +9,13 @@ describe('AgendaContentObjectFormComponent', () => {
let component: AgendaContentObjectFormComponent; let component: AgendaContentObjectFormComponent;
let fixture: ComponentFixture<AgendaContentObjectFormComponent>; let fixture: ComponentFixture<AgendaContentObjectFormComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AgendaContentObjectFormComponent); fixture = TestBed.createComponent(AgendaContentObjectFormComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('AssignmentPollDetailContentComponent', () => {
let component: AssignmentPollDetailContentComponent; let component: AssignmentPollDetailContentComponent;
let fixture: ComponentFixture<AssignmentPollDetailContentComponent>; let fixture: ComponentFixture<AssignmentPollDetailContentComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AssignmentPollDetailContentComponent); fixture = TestBed.createComponent(AssignmentPollDetailContentComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('AttachmentControlComponent', () => {
let component: AttachmentControlComponent; let component: AttachmentControlComponent;
let fixture: ComponentFixture<AttachmentControlComponent>; let fixture: ComponentFixture<AttachmentControlComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AttachmentControlComponent); fixture = TestBed.createComponent(AttachmentControlComponent);

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
/** Custom component theme. Only lives in a specific scope */ /** Custom component theme. Only lives in a specific scope */
@mixin os-banner-style($theme) { @mixin os-banner-style($theme) {
@ -6,6 +6,6 @@
/** style for the offline-banner */ /** style for the offline-banner */
.banner { .banner {
background: mat-color($accent, 500); background: mat.get-color-from-palette($accent, 500);
} }
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('BannerComponent', () => {
let component: BannerComponent; let component: BannerComponent;
let fixture: ComponentFixture<BannerComponent>; let fixture: ComponentFixture<BannerComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(BannerComponent); fixture = TestBed.createComponent(BannerComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,12 +8,14 @@ describe('BlockTileComponent', () => {
let component: BlockTileComponent; let component: BlockTileComponent;
let fixture: ComponentFixture<BlockTileComponent>; let fixture: ComponentFixture<BlockTileComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
// declarations: [BlockTileComponent] imports: [E2EImportsModule]
}).compileComponents(); // declarations: [BlockTileComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(BlockTileComponent); fixture = TestBed.createComponent(BlockTileComponent);

View File

@ -1,4 +1,4 @@
import { async, TestBed } from '@angular/core/testing'; import { TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -6,11 +6,13 @@ describe('ChartsComponent', () => {
// let component: ChartsComponent; // let component: ChartsComponent;
// let fixture: ComponentFixture<ChartsComponent>; // let fixture: ComponentFixture<ChartsComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
// fixture = TestBed.createComponent(ChartsComponent); // fixture = TestBed.createComponent(ChartsComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('CheckInputComponent', () => {
let component: CheckInputComponent; let component: CheckInputComponent;
let fixture: ComponentFixture<CheckInputComponent>; let fixture: ComponentFixture<CheckInputComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(CheckInputComponent); fixture = TestBed.createComponent(CheckInputComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog'; import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -9,18 +9,20 @@ describe('ChoiceDialogComponent', () => {
let component: ChoiceDialogComponent; let component: ChoiceDialogComponent;
let fixture: ComponentFixture<ChoiceDialogComponent>; let fixture: ComponentFixture<ChoiceDialogComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
providers: [ imports: [E2EImportsModule],
{ provide: MatDialogRef, useValue: {} }, providers: [
{ { provide: MatDialogRef, useValue: {} },
provide: MAT_DIALOG_DATA, {
useValue: null provide: MAT_DIALOG_DATA,
} useValue: null
] }
}).compileComponents(); ]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ChoiceDialogComponent); fixture = TestBed.createComponent(ChoiceDialogComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { CountdownTimeComponent } from './countdown-time.component'; import { CountdownTimeComponent } from './countdown-time.component';
import { E2EImportsModule } from '../../../../e2e-imports.module'; import { E2EImportsModule } from '../../../../e2e-imports.module';
@ -7,11 +7,13 @@ describe('CountdownTimeComponent', () => {
let component: CountdownTimeComponent; let component: CountdownTimeComponent;
let fixture: ComponentFixture<CountdownTimeComponent>; let fixture: ComponentFixture<CountdownTimeComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(CountdownTimeComponent); fixture = TestBed.createComponent(CountdownTimeComponent);

View File

@ -0,0 +1,29 @@
<h2 mat-dialog-title>{{ caption | translate }}</h2>
<mat-dialog-content>
<ng-container *ngIf="partnerName">
<div class="space">
<div class="coin info-coin thisPlayer"></div>
<span>{{ getPlayerName() }}</span>
</div>
<div>
<div class="coin info-coin partner"></div>
<span>{{ partnerName }}</span>
</div>
</ng-container>
<table [class]="disableBoard ? 'disabled' : ''" id="c4">
<tr *ngFor="let row of [5, 4, 3, 2, 1, 0]">
<td *ngFor="let col of [0, 1, 2, 3, 4, 5, 6]">
<div [class]="getCoinClass(row, col)" (click)="clickField(row, col)"></div>
</td>
</tr>
</table>
<div class="center">
<button (click)="handleEvent('searchClicked')" *ngIf="state === 'start'" mat-raised-button color="accent">
{{ 'Search player' | translate }}
</button>
</div>
</mat-dialog-content>
<mat-dialog-actions>
<button mat-button mat-dialog-close>{{ 'Close' | translate }}</button>
</mat-dialog-actions>

View File

@ -0,0 +1,51 @@
span {
font-size: 20px;
padding-left: 10px;
}
.center {
text-align: center;
}
.space {
margin-bottom: 5px;
}
#c4 {
background-color: yellow;
padding: 10px;
margin: 15px auto;
}
#c4.disabled {
background-color: grey;
}
#c4 td {
width: 50px;
height: 50px;
}
#c4 .notSelected {
cursor: pointer;
background-color: white;
}
#c4.disabled .notSelected {
cursor: auto;
}
.thisPlayer {
background-color: blue;
}
#c4.disabled .thisPlayer {
background-color: #8888ff;
}
.partner {
background-color: red;
}
#c4.disabled .partner {
background-color: #ff8888;
}
.coin {
border-radius: 50%;
width: 100%;
height: 100%;
}
.coin.info-coin {
display: inline-block;
width: 20px;
height: 20px;
}

View File

@ -62,97 +62,8 @@ type StateMachine = { [state in State]?: { [event in StateEvent]?: SMAction } };
@Component({ @Component({
selector: 'os-c4dialog', selector: 'os-c4dialog',
template: ` templateUrl: './copyright-sign.component.html',
<h2 mat-dialog-title>{{ caption | translate }}</h2> styleUrls: ['./copyright-sign.component.scss']
<mat-dialog-content>
<ng-container *ngIf="partnerName">
<div class="space">
<div class="coin info-coin thisPlayer"></div>
<span>{{ getPlayerName() }}</span>
</div>
<div>
<div class="coin info-coin partner"></div>
<span>{{ partnerName }}</span>
</div>
</ng-container>
<table [class]="disableBoard ? 'disabled' : ''" id="c4">
<tr *ngFor="let row of [5, 4, 3, 2, 1, 0]">
<td *ngFor="let col of [0, 1, 2, 3, 4, 5, 6]">
<div [class]="getCoinClass(row, col)" (click)="clickField(row, col)"></div>
</td>
</tr>
</table>
<div class="center">
<button
(click)="handleEvent('searchClicked')"
*ngIf="state === 'start'"
mat-raised-button
color="accent"
>
{{ 'Search player' | translate }}
</button>
</div>
</mat-dialog-content>
<mat-dialog-actions>
<button mat-button mat-dialog-close>{{ 'Close' | translate }}</button>
</mat-dialog-actions>
`,
styles: [
`
span {
font-size: 20px;
padding-left: 10px;
}
.center {
text-align: center;
}
.space {
margin-bottom: 5px;
}
#c4 {
background-color: yellow;
padding: 10px;
margin: 15px auto;
}
#c4.disabled {
background-color: grey;
}
#c4 td {
width: 50px;
height: 50px;
}
#c4 .notSelected {
cursor: pointer;
background-color: white;
}
#c4.disabled .notSelected {
cursor: auto;
}
.thisPlayer {
background-color: blue;
}
#c4.disabled .thisPlayer {
background-color: #8888ff;
}
.partner {
background-color: red;
}
#c4.disabled .partner {
background-color: #ff8888;
}
.coin {
border-radius: 50%;
width: 100%;
height: 100%;
}
.coin.info-coin {
display: inline-block;
width: 20px;
height: 20px;
}
`
]
}) })
export class C4DialogComponent implements OnInit, OnDestroy { export class C4DialogComponent implements OnInit, OnDestroy {
/** /**
@ -577,8 +488,7 @@ export class C4DialogComponent implements OnInit, OnDestroy {
@Component({ @Component({
selector: 'os-copyright-sign', selector: 'os-copyright-sign',
template: ` <span (click)="launchC4($event)">©</span> `, template: ` <span (click)="launchC4($event)">©</span> `
styles: [``]
}) })
export class CopyrightSignComponent { export class CopyrightSignComponent {
private clickTimeout: number | null; private clickTimeout: number | null;

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('ExtensionFieldComponent', () => {
let component: ExtensionFieldComponent; let component: ExtensionFieldComponent;
let fixture: ComponentFixture<ExtensionFieldComponent>; let fixture: ComponentFixture<ExtensionFieldComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ExtensionFieldComponent); fixture = TestBed.createComponent(ExtensionFieldComponent);

View File

@ -1,5 +1,3 @@
@import '~@angular/material/theming';
@mixin os-global-spinner-theme($theme) { @mixin os-global-spinner-theme($theme) {
.spinner-container { .spinner-container {
display: flex; display: flex;

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('GlobalSpinnerComponent', () => {
let component: GlobalSpinnerComponent; let component: GlobalSpinnerComponent;
let fixture: ComponentFixture<GlobalSpinnerComponent>; let fixture: ComponentFixture<GlobalSpinnerComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(GlobalSpinnerComponent); fixture = TestBed.createComponent(GlobalSpinnerComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,12 +8,14 @@ describe('GridLayoutComponent', () => {
let component: GridLayoutComponent; let component: GridLayoutComponent;
let fixture: ComponentFixture<GridLayoutComponent>; let fixture: ComponentFixture<GridLayoutComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
// declarations: [GridLayoutComponent] imports: [E2EImportsModule]
}).compileComponents(); // declarations: [GridLayoutComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(GridLayoutComponent); fixture = TestBed.createComponent(GridLayoutComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from '../../../../e2e-imports.module'; import { E2EImportsModule } from '../../../../e2e-imports.module';
import { HeadBarComponent } from './head-bar.component'; import { HeadBarComponent } from './head-bar.component';
@ -7,11 +7,13 @@ describe('HeadBarComponent', () => {
let component: HeadBarComponent; let component: HeadBarComponent;
let fixture: ComponentFixture<HeadBarComponent>; let fixture: ComponentFixture<HeadBarComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(HeadBarComponent); fixture = TestBed.createComponent(HeadBarComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('IconContainerComponent', () => {
let component: IconContainerComponent; let component: IconContainerComponent;
let fixture: ComponentFixture<IconContainerComponent>; let fixture: ComponentFixture<IconContainerComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(IconContainerComponent); fixture = TestBed.createComponent(IconContainerComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from '../../../../e2e-imports.module'; import { E2EImportsModule } from '../../../../e2e-imports.module';
import { LegalNoticeContentComponent } from './legal-notice-content.component'; import { LegalNoticeContentComponent } from './legal-notice-content.component';
@ -7,11 +7,13 @@ describe('LegalNoticeComponent', () => {
let component: LegalNoticeContentComponent; let component: LegalNoticeContentComponent;
let fixture: ComponentFixture<LegalNoticeContentComponent>; let fixture: ComponentFixture<LegalNoticeContentComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(LegalNoticeContentComponent); fixture = TestBed.createComponent(LegalNoticeContentComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('ListOfSpeakersContentComponent', () => {
let component: ListOfSpeakersContentComponent; let component: ListOfSpeakersContentComponent;
let fixture: ComponentFixture<ListOfSpeakersContentComponent>; let fixture: ComponentFixture<ListOfSpeakersContentComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ListOfSpeakersContentComponent); fixture = TestBed.createComponent(ListOfSpeakersContentComponent);

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
@mixin os-list-view-table-theme($theme) { @mixin os-list-view-table-theme($theme) {
$primary: map-get($theme, primary); $primary: map-get($theme, primary);
@ -8,6 +8,6 @@
$background: map-get($theme, background); $background: map-get($theme, background);
.projected { .projected {
background-color: mat-color($background, hover) !important; background-color: mat.get-color-from-palette($background, hover) !important;
} }
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('ListViewTableComponent', () => {
let component: ListViewTableComponent<any>; let component: ListViewTableComponent<any>;
let fixture: ComponentFixture<ListViewTableComponent<any>>; let fixture: ComponentFixture<ListViewTableComponent<any>>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ListViewTableComponent); fixture = TestBed.createComponent(ListViewTableComponent);

View File

@ -12,8 +12,15 @@ import {
} from '@angular/core'; } from '@angular/core';
import { NavigationStart, Router } from '@angular/router'; import { NavigationStart, Router } from '@angular/router';
import { columnFactory, createDS, DataSourcePredicate, PblDataSource, PblNgridComponent } from '@pebula/ngrid'; import {
import { PblColumnDefinition, PblColumnFactory, PblNgridColumnSet, PblNgridRowContext } from '@pebula/ngrid/lib/grid'; columnFactory,
createDS,
DataSourcePredicate,
PblColumnDefinition,
PblDataSource,
PblNgridComponent
} from '@pebula/ngrid';
import { PblColumnFactory, PblNgridColumnSet, PblNgridRowContext } from '@pebula/ngrid/lib/grid';
import { PblNgridDataMatrixRow } from '@pebula/ngrid/target-events'; import { PblNgridDataMatrixRow } from '@pebula/ngrid/target-events';
import { Observable, Subscription } from 'rxjs'; import { Observable, Subscription } from 'rxjs';
import { distinctUntilChanged, filter } from 'rxjs/operators'; import { distinctUntilChanged, filter } from 'rxjs/operators';
@ -91,7 +98,8 @@ export interface ColumnRestriction {
encapsulation: ViewEncapsulation.None encapsulation: ViewEncapsulation.None
}) })
export class ListViewTableComponent<V extends BaseViewModel | BaseViewModelWithContentObject> export class ListViewTableComponent<V extends BaseViewModel | BaseViewModelWithContentObject>
implements OnInit, OnDestroy { implements OnInit, OnDestroy
{
/** /**
* Declare the table * Declare the table
*/ */

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('LogoComponent', () => {
let component: LogoComponent; let component: LogoComponent;
let fixture: ComponentFixture<LogoComponent>; let fixture: ComponentFixture<LogoComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(LogoComponent); fixture = TestBed.createComponent(LogoComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('MediaUploadContentComponent', () => {
let component: MediaUploadContentComponent; let component: MediaUploadContentComponent;
let fixture: ComponentFixture<MediaUploadContentComponent>; let fixture: ComponentFixture<MediaUploadContentComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(MediaUploadContentComponent); fixture = TestBed.createComponent(MediaUploadContentComponent);

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
@mixin os-meta-text-block-style($theme) { @mixin os-meta-text-block-style($theme) {
$foreground: map-get($theme, foreground); $foreground: map-get($theme, foreground);
@ -9,7 +9,7 @@
min-width: 200px; min-width: 200px;
.mat-icon-button mat-icon { .mat-icon-button mat-icon {
color: mat-color($foreground, icon); color: mat.get-color-from-palette($foreground, icon);
font-size: 18px; font-size: 18px;
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('MetaTextBlockComponent', () => {
let component: MetaTextBlockComponent; let component: MetaTextBlockComponent;
let fixture: ComponentFixture<MetaTextBlockComponent>; let fixture: ComponentFixture<MetaTextBlockComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(MetaTextBlockComponent); fixture = TestBed.createComponent(MetaTextBlockComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('MotionPollDetailContentComponent', () => {
let component: MotionPollDetailContentComponent; let component: MotionPollDetailContentComponent;
let fixture: ComponentFixture<MotionPollDetailContentComponent>; let fixture: ComponentFixture<MotionPollDetailContentComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(MotionPollDetailContentComponent); fixture = TestBed.createComponent(MotionPollDetailContentComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('PreviewComponent', () => {
let component: PreviewComponent; let component: PreviewComponent;
let fixture: ComponentFixture<PreviewComponent>; let fixture: ComponentFixture<PreviewComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(PreviewComponent); fixture = TestBed.createComponent(PreviewComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from '../../../../e2e-imports.module'; import { E2EImportsModule } from '../../../../e2e-imports.module';
import { PrivacyPolicyContentComponent } from './privacy-policy-content.component'; import { PrivacyPolicyContentComponent } from './privacy-policy-content.component';
@ -7,11 +7,13 @@ describe('PrivacyPolicyComponent', () => {
let component: PrivacyPolicyContentComponent; let component: PrivacyPolicyContentComponent;
let fixture: ComponentFixture<PrivacyPolicyContentComponent>; let fixture: ComponentFixture<PrivacyPolicyContentComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(PrivacyPolicyContentComponent); fixture = TestBed.createComponent(PrivacyPolicyContentComponent);

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
/** Custom component theme. Only lives in a specific scope */ /** Custom component theme. Only lives in a specific scope */
@mixin os-progress-snack-bar-style($theme) { @mixin os-progress-snack-bar-style($theme) {
@ -6,7 +6,7 @@
.progress-snack-bar { .progress-snack-bar {
.mat-progress-bar-buffer { .mat-progress-bar-buffer {
background-color: mat-color($background, card) !important; background-color: mat.get-color-from-palette($background, card) !important;
} }
} }
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { MatSnackBarRef } from '@angular/material/snack-bar'; import { MatSnackBarRef } from '@angular/material/snack-bar';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -9,12 +9,14 @@ describe('ProgressSnackBarComponent', () => {
let component: ProgressSnackBarComponent; let component: ProgressSnackBarComponent;
let fixture: ComponentFixture<ProgressSnackBarComponent>; let fixture: ComponentFixture<ProgressSnackBarComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
providers: [{ provide: MatSnackBarRef, useValue: {} }] imports: [E2EImportsModule],
}).compileComponents(); providers: [{ provide: MatSnackBarRef, useValue: {} }]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ProgressSnackBarComponent); fixture = TestBed.createComponent(ProgressSnackBarComponent);

View File

@ -1,26 +1,26 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
@mixin os-progress-theme($theme) { @mixin os-progress-theme($theme) {
$primary: map-get($theme, primary); $primary: map-get($theme, primary);
$accent: map-get($theme, accent); $accent: map-get($theme, accent);
.progress-wrapper { .progress-wrapper {
background-color: mat-color($primary); background-color: mat.get-color-from-palette($primary);
} }
.end-icon { .end-icon {
color: mat-color($primary, default-contrast); color: mat.get-color-from-palette($primary, default-contrast);
} }
.slot { .slot {
color: mat-color($primary, default-contrast); color: mat.get-color-from-palette($primary, default-contrast);
} }
.buffer { .buffer {
background-color: mat-color($primary, darker); background-color: mat.get-color-from-palette($primary, darker);
} }
.progress { .progress {
background-color: mat-color($accent); background-color: mat.get-color-from-palette($accent);
} }
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { ProgressComponent } from './progress.component'; import { ProgressComponent } from './progress.component';
@ -6,11 +6,13 @@ describe('ProgressComponent', () => {
let component: ProgressComponent; let component: ProgressComponent;
let fixture: ComponentFixture<ProgressComponent>; let fixture: ComponentFixture<ProgressComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
declarations: [ProgressComponent] TestBed.configureTestingModule({
}).compileComponents(); declarations: [ProgressComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ProgressComponent); fixture = TestBed.createComponent(ProgressComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog'; import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -9,18 +9,20 @@ describe('ProjectionDialogComponent', () => {
let component: ProjectionDialogComponent; let component: ProjectionDialogComponent;
let fixture: ComponentFixture<ProjectionDialogComponent>; let fixture: ComponentFixture<ProjectionDialogComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
providers: [ imports: [E2EImportsModule],
{ provide: MatDialogRef, useValue: {} }, providers: [
{ { provide: MatDialogRef, useValue: {} },
provide: MAT_DIALOG_DATA, {
useValue: null provide: MAT_DIALOG_DATA,
} useValue: null
] }
}).compileComponents(); ]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ProjectionDialogComponent); fixture = TestBed.createComponent(ProjectionDialogComponent);

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
@mixin os-projector-button-style($theme) { @mixin os-projector-button-style($theme) {
$primary: map-get($theme, primary); $primary: map-get($theme, primary);
@ -7,7 +7,7 @@
$contrast: map-get($primary, contrast); $contrast: map-get($primary, contrast);
.mat-mini-fab.projector-inactive { .mat-mini-fab.projector-inactive {
color: mat-color($contrast, A200) !important; color: mat.get-color-from-palette($contrast, A200) !important;
background-color: mat-color($contrast, 500) !important; background-color: mat.get-color-from-palette($contrast, 500) !important;
} }
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('ProjectorButtonComponent', () => {
let component: ProjectorButtonComponent; let component: ProjectorButtonComponent;
let fixture: ComponentFixture<ProjectorButtonComponent>; let fixture: ComponentFixture<ProjectorButtonComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ProjectorButtonComponent); fixture = TestBed.createComponent(ProjectorButtonComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('ProjectorComponent', () => {
let component: ProjectorComponent; let component: ProjectorComponent;
let fixture: ComponentFixture<ProjectorComponent>; let fixture: ComponentFixture<ProjectorComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ProjectorComponent); fixture = TestBed.createComponent(ProjectorComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog'; import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -9,18 +9,20 @@ describe('PromptDialogComponent', () => {
let component: PromptDialogComponent; let component: PromptDialogComponent;
let fixture: ComponentFixture<PromptDialogComponent>; let fixture: ComponentFixture<PromptDialogComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
providers: [ imports: [E2EImportsModule],
{ provide: MatDialogRef, useValue: {} }, providers: [
{ { provide: MatDialogRef, useValue: {} },
provide: MAT_DIALOG_DATA, {
useValue: null provide: MAT_DIALOG_DATA,
} useValue: null
] }
}).compileComponents(); ]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(PromptDialogComponent); fixture = TestBed.createComponent(PromptDialogComponent);

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
:host.full-width { :host.full-width {
width: 100%; width: 100%;
@ -8,7 +8,7 @@
$background: map-get($theme, background); $background: map-get($theme, background);
$foreground: map-get($theme, foreground); $foreground: map-get($theme, foreground);
$foreground-color: mat-color($foreground, icon); $foreground-color: mat.get-color-from-palette($foreground, icon);
.input-container { .input-container {
position: relative; position: relative;
@ -39,7 +39,7 @@
border-radius: 32px; border-radius: 32px;
font-size: 16px; font-size: 16px;
border: 1px solid #ccc; border: 1px solid #ccc;
background: mat-color($background, background); background: mat.get-color-from-palette($background, background);
color: $foreground-color; color: $foreground-color;
transition: all 0.25s ease; transition: all 0.25s ease;

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('RoundedInputComponent', () => {
let component: RoundedInputComponent; let component: RoundedInputComponent;
let fixture: ComponentFixture<RoundedInputComponent>; let fixture: ComponentFixture<RoundedInputComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(RoundedInputComponent); fixture = TestBed.createComponent(RoundedInputComponent);

View File

@ -1,5 +1,5 @@
import { Component, ViewChild } from '@angular/core'; import { Component, ViewChild } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { FormBuilder } from '@angular/forms'; import { FormBuilder } from '@angular/forms';
import { BehaviorSubject } from 'rxjs'; import { BehaviorSubject } from 'rxjs';
@ -22,12 +22,14 @@ describe('SearchValueSelectorComponent', () => {
let hostComponent: TestHostComponent; let hostComponent: TestHostComponent;
let hostFixture: ComponentFixture<TestHostComponent>; let hostFixture: ComponentFixture<TestHostComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [TestHostComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [TestHostComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
hostFixture = TestBed.createComponent(TestHostComponent); hostFixture = TestBed.createComponent(TestHostComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('SlideContainerComponent', () => {
let component: SlideContainerComponent; let component: SlideContainerComponent;
let fixture: ComponentFixture<SlideContainerComponent>; let fixture: ComponentFixture<SlideContainerComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(SlideContainerComponent); fixture = TestBed.createComponent(SlideContainerComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -7,11 +7,13 @@ import { SortBottomSheetComponent } from './sort-bottom-sheet.component';
describe('SortBottomSheetComponent', () => { describe('SortBottomSheetComponent', () => {
let fixture: ComponentFixture<SortBottomSheetComponent<any>>; let fixture: ComponentFixture<SortBottomSheetComponent<any>>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(SortBottomSheetComponent); fixture = TestBed.createComponent(SortBottomSheetComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('OsSortFilterBarComponent', () => {
let component: SortFilterBarComponent<any>; let component: SortFilterBarComponent<any>;
let fixture: ComponentFixture<any>; let fixture: ComponentFixture<any>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(SortFilterBarComponent); fixture = TestBed.createComponent(SortFilterBarComponent);

View File

@ -1,5 +1,5 @@
import { Component, ViewChild } from '@angular/core'; import { Component, ViewChild } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from '../../../../e2e-imports.module'; import { E2EImportsModule } from '../../../../e2e-imports.module';
import { EmptySelectable } from '../empty-selectable'; import { EmptySelectable } from '../empty-selectable';
@ -19,12 +19,14 @@ describe('SortingListComponent', () => {
let hostComponent: TestHostComponent; let hostComponent: TestHostComponent;
let hostFixture: ComponentFixture<TestHostComponent>; let hostFixture: ComponentFixture<TestHostComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [TestHostComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [TestHostComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
hostFixture = TestBed.createComponent(TestHostComponent); hostFixture = TestBed.createComponent(TestHostComponent);

View File

@ -1,5 +1,5 @@
@use '~@angular/material' as mat;
@import '../../../../assets/styles/drag.scss'; @import '../../../../assets/styles/drag.scss';
@import '~@angular/material/theming';
@mixin os-sorting-tree-style($theme) { @mixin os-sorting-tree-style($theme) {
$background: map-get($theme, background); $background: map-get($theme, background);
@ -37,7 +37,7 @@
div.backgroundColorLight { div.backgroundColorLight {
box-sizing: border-box; box-sizing: border-box;
background-color: mat-color($background, background); background-color: mat.get-color-from-palette($background, background);
border-radius: 4px; border-radius: 4px;
box-shadow: 0 5px 5px -3px rgba(0, 0, 0, 0.2), 0 8px 10px 1px rgba(0, 0, 0, 0.14), box-shadow: 0 5px 5px -3px rgba(0, 0, 0, 0.2), 0 8px 10px 1px rgba(0, 0, 0, 0.14),
0 3px 14px 2px rgba(0, 0, 0, 0.12); 0 3px 14px 2px rgba(0, 0, 0, 0.12);

View File

@ -1,5 +1,5 @@
import { Component, ViewChild } from '@angular/core'; import { Component, ViewChild } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
import { BehaviorSubject } from 'rxjs'; import { BehaviorSubject } from 'rxjs';
@ -37,12 +37,14 @@ describe('SortingTreeComponent', () => {
let hostComponent: TestHostComponent; let hostComponent: TestHostComponent;
let hostFixture: ComponentFixture<TestHostComponent>; let hostFixture: ComponentFixture<TestHostComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [TestHostComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [TestHostComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
hostFixture = TestBed.createComponent(TestHostComponent); hostFixture = TestBed.createComponent(TestHostComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('SpeakerButtonComponent', () => {
let component: SpeakerButtonComponent; let component: SpeakerButtonComponent;
let fixture: ComponentFixture<SpeakerButtonComponent>; let fixture: ComponentFixture<SpeakerButtonComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(SpeakerButtonComponent); fixture = TestBed.createComponent(SpeakerButtonComponent);

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use 'sass:math';
@import '../../../../assets/styles/media-queries.scss'; @import '../../../../assets/styles/media-queries.scss';
@mixin os-tile-style($theme) { @mixin os-tile-style($theme) {
@ -64,7 +64,7 @@
@if $space == true { @if $space == true {
@return calc(#{$size} / 4 * 100% - 16px); @return calc(#{$size} / 4 * 100% - 16px);
} @else { } @else {
@return $size / 4 * 100%; @return math.div($size, 4) * 100%;
} }
} }
@ -72,7 +72,7 @@
@if $space == true { @if $space == true {
@return calc(#{$size} / 8 * 100% - 16px); @return calc(#{$size} / 8 * 100% - 16px);
} @else { } @else {
@return $size / 8 * 100%; @return math.div($size, 8) * 100%;
} }
} }
@ -80,7 +80,7 @@
@if $space == true { @if $space == true {
@return calc(#{$size} / 12 * 100% - 16px); @return calc(#{$size} / 12 * 100% - 16px);
} @else { } @else {
@return $size / 12 * 100%; @return math.div($size, 12) * 100%;
} }
} }
@ -88,7 +88,7 @@
@if $space == true { @if $space == true {
@return calc(#{$size} / 16 * 100% - 16px); @return calc(#{$size} / 16 * 100% - 16px);
} @else { } @else {
@return $size / 16 * 100%; @return math.div($size, 16) * 100%;
} }
} }
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { TileComponent } from './tile.component'; import { TileComponent } from './tile.component';
@ -6,11 +6,13 @@ describe('TileComponent', () => {
let component: TileComponent; let component: TileComponent;
let fixture: ComponentFixture<TileComponent>; let fixture: ComponentFixture<TileComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
declarations: [TileComponent] TestBed.configureTestingModule({
}).compileComponents(); declarations: [TileComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(TileComponent); fixture = TestBed.createComponent(TileComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('UserMenuComponent', () => {
let component: UserMenuComponent; let component: UserMenuComponent;
let fixture: ComponentFixture<UserMenuComponent>; let fixture: ComponentFixture<UserMenuComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(UserMenuComponent); fixture = TestBed.createComponent(UserMenuComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('VjsPlayerComponent', () => {
let component: VideoPlayerComponent; let component: VideoPlayerComponent;
let fixture: ComponentFixture<VideoPlayerComponent>; let fixture: ComponentFixture<VideoPlayerComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(VideoPlayerComponent); fixture = TestBed.createComponent(VideoPlayerComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,11 +8,13 @@ describe('VotingPrivacyWarningComponent', () => {
let component: VotingPrivacyWarningComponent; let component: VotingPrivacyWarningComponent;
let fixture: ComponentFixture<VotingPrivacyWarningComponent>; let fixture: ComponentFixture<VotingPrivacyWarningComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule] TestBed.configureTestingModule({
}).compileComponents(); imports: [E2EImportsModule]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(VotingPrivacyWarningComponent); fixture = TestBed.createComponent(VotingPrivacyWarningComponent);

View File

@ -23,8 +23,8 @@ import { Subject, Subscription } from 'rxjs';
*/ */
@Directive() @Directive()
export abstract class BaseFormControlComponentDirective<T> export abstract class BaseFormControlComponentDirective<T>
extends MatFormFieldControl<T> implements MatFormFieldControl<T>, OnDestroy, ControlValueAccessor
implements OnDestroy, ControlValueAccessor { {
public static nextId = 0; public static nextId = 0;
@HostBinding() public id = `base-form-control-${BaseFormControlComponentDirective.nextId++}`; @HostBinding() public id = `base-form-control-${BaseFormControlComponentDirective.nextId++}`;
@ -102,8 +102,6 @@ export abstract class BaseFormControlComponentDirective<T>
protected element: ElementRef<HTMLElement>, protected element: ElementRef<HTMLElement>,
@Optional() @Self() public ngControl: NgControl @Optional() @Self() public ngControl: NgControl
) { ) {
super();
this.initializeForm(); this.initializeForm();
if (this.ngControl !== null) { if (this.ngControl !== null) {

View File

@ -11,7 +11,8 @@ export function isBaseModelWithAgendaItemAndListOfSpeakers(obj: any): obj is Bas
*/ */
export abstract class BaseModelWithAgendaItemAndListOfSpeakers<T = object> export abstract class BaseModelWithAgendaItemAndListOfSpeakers<T = object>
extends BaseModel<T> extends BaseModel<T>
implements BaseModelWithAgendaItem<T>, BaseModelWithListOfSpeakers<T> { implements BaseModelWithAgendaItem<T>, BaseModelWithListOfSpeakers<T>
{
public agenda_item_id: number; public agenda_item_id: number;
public list_of_speakers_id: number; public list_of_speakers_id: number;
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { AgendaListComponent } from './agenda-list.component'; import { AgendaListComponent } from './agenda-list.component';
import { E2EImportsModule } from '../../../../../e2e-imports.module'; import { E2EImportsModule } from '../../../../../e2e-imports.module';
@ -7,12 +7,14 @@ describe('AgendaListComponent', () => {
let component: AgendaListComponent; let component: AgendaListComponent;
let fixture: ComponentFixture<AgendaListComponent>; let fixture: ComponentFixture<AgendaListComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [AgendaListComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [AgendaListComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AgendaListComponent); fixture = TestBed.createComponent(AgendaListComponent);

View File

@ -81,11 +81,11 @@ export class AgendaListComponent extends BaseListViewComponent<ViewItem> impleme
public tableColumnDefinition: PblColumnDefinition[] = [ public tableColumnDefinition: PblColumnDefinition[] = [
{ {
prop: 'title', prop: 'title',
width: 'auto' width: '100%'
}, },
{ {
prop: 'info', prop: 'info',
width: '15%' width: '100px'
} }
]; ];

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,12 +8,14 @@ describe('AgendaSortComponent', () => {
let component: AgendaSortComponent; let component: AgendaSortComponent;
let fixture: ComponentFixture<AgendaSortComponent>; let fixture: ComponentFixture<AgendaSortComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [AgendaSortComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [AgendaSortComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AgendaSortComponent); fixture = TestBed.createComponent(AgendaSortComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog'; import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -9,19 +9,21 @@ describe('ItemInfoDialogComponent', () => {
let component: ItemInfoDialogComponent; let component: ItemInfoDialogComponent;
let fixture: ComponentFixture<ItemInfoDialogComponent>; let fixture: ComponentFixture<ItemInfoDialogComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [ItemInfoDialogComponent], imports: [E2EImportsModule],
providers: [ declarations: [ItemInfoDialogComponent],
{ provide: MatDialogRef, useValue: {} }, providers: [
{ { provide: MatDialogRef, useValue: {} },
provide: MAT_DIALOG_DATA, {
useValue: null provide: MAT_DIALOG_DATA,
} useValue: null
] }
}).compileComponents(); ]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ItemInfoDialogComponent); fixture = TestBed.createComponent(ItemInfoDialogComponent);

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
@mixin os-list-of-speakers-style($theme) { @mixin os-list-of-speakers-style($theme) {
$primary: map-get($theme, primary); $primary: map-get($theme, primary);
@ -8,20 +8,20 @@
$foreground: map-get($theme, foreground); $foreground: map-get($theme, foreground);
.current-speaker { .current-speaker {
background-color: mat-color($accent) !important; background-color: mat.get-color-from-palette($accent) !important;
> span { > span {
color: mat-color($accent, default-contrast); color: mat.get-color-from-palette($accent, default-contrast);
} }
} }
.finished-speaker-grid { .finished-speaker-grid {
> .number .name .controls { > .number .name .controls {
color: mat-color($foreground, text); color: mat.get-color-from-palette($foreground, text);
} }
> .time { > .time {
color: mat-color($foreground, secondary-text); color: mat.get-color-from-palette($foreground, secondary-text);
} }
} }
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from '../../../../../e2e-imports.module'; import { E2EImportsModule } from '../../../../../e2e-imports.module';
import { ListOfSpeakersComponent } from './list-of-speakers.component'; import { ListOfSpeakersComponent } from './list-of-speakers.component';
@ -7,12 +7,14 @@ describe('ListOfSpeakersComponent', () => {
let component: ListOfSpeakersComponent; let component: ListOfSpeakersComponent;
let fixture: ComponentFixture<ListOfSpeakersComponent>; let fixture: ComponentFixture<ListOfSpeakersComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [ListOfSpeakersComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [ListOfSpeakersComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ListOfSpeakersComponent); fixture = TestBed.createComponent(ListOfSpeakersComponent);

View File

@ -12,7 +12,8 @@ export interface ItemTitleInformation {
export class ViewItem export class ViewItem
extends BaseViewModelWithContentObject<Item, BaseViewModelWithAgendaItem> extends BaseViewModelWithContentObject<Item, BaseViewModelWithAgendaItem>
implements ItemTitleInformation { implements ItemTitleInformation
{
public static COLLECTIONSTRING = Item.COLLECTIONSTRING; public static COLLECTIONSTRING = Item.COLLECTIONSTRING;
protected _collectionString = Item.COLLECTIONSTRING; protected _collectionString = Item.COLLECTIONSTRING;

View File

@ -23,7 +23,8 @@ export enum UserListIndexType {
*/ */
export class ViewListOfSpeakers export class ViewListOfSpeakers
extends BaseViewModelWithContentObject<ListOfSpeakers, BaseViewModelWithListOfSpeakers> extends BaseViewModelWithContentObject<ListOfSpeakers, BaseViewModelWithListOfSpeakers>
implements ListOfSpeakersTitleInformation, Projectable { implements ListOfSpeakersTitleInformation, Projectable
{
public static COLLECTIONSTRING = ListOfSpeakers.COLLECTIONSTRING; public static COLLECTIONSTRING = ListOfSpeakers.COLLECTIONSTRING;
protected _collectionString = ListOfSpeakers.COLLECTIONSTRING; protected _collectionString = ListOfSpeakers.COLLECTIONSTRING;

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -11,17 +11,19 @@ describe('AssignmentDetailComponent', () => {
let component: AssignmentDetailComponent; let component: AssignmentDetailComponent;
let fixture: ComponentFixture<AssignmentDetailComponent>; let fixture: ComponentFixture<AssignmentDetailComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [ imports: [E2EImportsModule],
AssignmentDetailComponent, declarations: [
AssignmentPollComponent, AssignmentDetailComponent,
AssignmentPollVoteComponent, AssignmentPollComponent,
PollProgressComponent AssignmentPollVoteComponent,
] PollProgressComponent
}).compileComponents(); ]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AssignmentDetailComponent); fixture = TestBed.createComponent(AssignmentDetailComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,12 +8,14 @@ describe('AssignmentListComponent', () => {
let component: AssignmentListComponent; let component: AssignmentListComponent;
let fixture: ComponentFixture<AssignmentListComponent>; let fixture: ComponentFixture<AssignmentListComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [AssignmentListComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [AssignmentListComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AssignmentListComponent); fixture = TestBed.createComponent(AssignmentListComponent);

View File

@ -38,11 +38,10 @@ export class AssignmentListComponent extends BaseListViewComponent<ViewAssignmen
public tableColumnDefinition: PblColumnDefinition[] = [ public tableColumnDefinition: PblColumnDefinition[] = [
{ {
prop: 'title', prop: 'title',
width: 'auto' width: '100%'
}, },
{ {
prop: 'phase', prop: 'phase',
width: '20%',
minWidth: 180 minWidth: 180
}, },
{ {

View File

@ -36,7 +36,8 @@ export const AssignmentPollPercentBaseVerbose = {
export class ViewAssignmentPoll export class ViewAssignmentPoll
extends ViewBasePoll<AssignmentPoll, AssignmentPollMethod, AssignmentPollPercentBase> extends ViewBasePoll<AssignmentPoll, AssignmentPollMethod, AssignmentPollPercentBase>
implements AssignmentPollTitleInformation { implements AssignmentPollTitleInformation
{
public static COLLECTIONSTRING = AssignmentPoll.COLLECTIONSTRING; public static COLLECTIONSTRING = AssignmentPoll.COLLECTIONSTRING;
protected _collectionString = AssignmentPoll.COLLECTIONSTRING; protected _collectionString = AssignmentPoll.COLLECTIONSTRING;

View File

@ -39,7 +39,8 @@ export const AssignmentPhases: { name: string; value: number; display_name: stri
export class ViewAssignment export class ViewAssignment
extends BaseViewModelWithAgendaItemAndListOfSpeakers<Assignment> extends BaseViewModelWithAgendaItemAndListOfSpeakers<Assignment>
implements AssignmentTitleInformation { implements AssignmentTitleInformation
{
public static COLLECTIONSTRING = Assignment.COLLECTIONSTRING; public static COLLECTIONSTRING = Assignment.COLLECTIONSTRING;
protected _collectionString = Assignment.COLLECTIONSTRING; protected _collectionString = Assignment.COLLECTIONSTRING;

View File

@ -1,4 +1,4 @@
@import '~@angular/material/theming'; @use '~@angular/material' as mat;
@mixin os-assignment-poll-detail-style($theme) { @mixin os-assignment-poll-detail-style($theme) {
$background: map-get($theme, background); $background: map-get($theme, background);
@ -6,24 +6,24 @@
.assignment-result-table { .assignment-result-table {
border-collapse: collapse; border-collapse: collapse;
tr { tr {
border-bottom: 1px solid mat-color($background, focused-button); border-bottom: 1px solid mat.get-color-from-palette($background, focused-button);
} }
} }
.openslides-theme .pbl-ngrid-row:hover { .openslides-theme .pbl-ngrid-row:hover {
background-color: mat-color($background, card); background-color: mat.get-color-from-palette($background, card);
} }
.openslides-theme os-list-view-table os-sort-filter-bar .custom-table-header { .openslides-theme os-list-view-table os-sort-filter-bar .custom-table-header {
&, &,
.action-buttons .input-container input { .action-buttons .input-container input {
background: mat-color($background, card); background: mat.get-color-from-palette($background, card);
} }
} }
.openslides-theme .pbl-ngrid-header-cell:first-child { .openslides-theme .pbl-ngrid-header-cell:first-child {
&::after { &::after {
border-right: 1px solid mat-color($background, focused-button); border-right: 1px solid mat.get-color-from-palette($background, focused-button);
} }
} }
} }

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,12 +8,14 @@ describe('AssignmentPollDetailComponent', () => {
let component: AssignmentPollDetailComponent; let component: AssignmentPollDetailComponent;
let fixture: ComponentFixture<AssignmentPollDetailComponent>; let fixture: ComponentFixture<AssignmentPollDetailComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [AssignmentPollDetailComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [AssignmentPollDetailComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AssignmentPollDetailComponent); fixture = TestBed.createComponent(AssignmentPollDetailComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog'; import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -9,18 +9,20 @@ describe('AssignmentPollDialogComponent', () => {
let component: AssignmentPollDialogComponent; let component: AssignmentPollDialogComponent;
let fixture: ComponentFixture<AssignmentPollDialogComponent>; let fixture: ComponentFixture<AssignmentPollDialogComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
providers: [ imports: [E2EImportsModule],
{ provide: MatDialogRef, useValue: null }, providers: [
{ { provide: MatDialogRef, useValue: null },
provide: MAT_DIALOG_DATA, {
useValue: null provide: MAT_DIALOG_DATA,
} useValue: null
] }
}).compileComponents(); ]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AssignmentPollDialogComponent); fixture = TestBed.createComponent(AssignmentPollDialogComponent);

View File

@ -33,7 +33,8 @@ type OptionsObject = { user_id: number; user: ViewUser }[];
}) })
export class AssignmentPollDialogComponent export class AssignmentPollDialogComponent
extends BasePollDialogComponent<ViewAssignmentPoll, AssignmentPollService> extends BasePollDialogComponent<ViewAssignmentPoll, AssignmentPollService>
implements OnInit { implements OnInit
{
public unknownUserLabel = UnknownUserLabel; public unknownUserLabel = UnknownUserLabel;
/** /**
* The summary values that will have fields in the dialog * The summary values that will have fields in the dialog

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,12 +8,14 @@ describe('AssignmentPollMetaInfoComponent', () => {
let component: AssignmentPollMetaInfoComponent; let component: AssignmentPollMetaInfoComponent;
let fixture: ComponentFixture<AssignmentPollMetaInfoComponent>; let fixture: ComponentFixture<AssignmentPollMetaInfoComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [AssignmentPollMetaInfoComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [AssignmentPollMetaInfoComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AssignmentPollMetaInfoComponent); fixture = TestBed.createComponent(AssignmentPollMetaInfoComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,12 +8,14 @@ describe('AssignmentPollVoteComponent', () => {
let component: AssignmentPollVoteComponent; let component: AssignmentPollVoteComponent;
let fixture: ComponentFixture<AssignmentPollVoteComponent>; let fixture: ComponentFixture<AssignmentPollVoteComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [AssignmentPollVoteComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [AssignmentPollVoteComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AssignmentPollVoteComponent); fixture = TestBed.createComponent(AssignmentPollVoteComponent);

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -10,12 +10,14 @@ describe('AssignmentPollComponent', () => {
let component: AssignmentPollComponent; let component: AssignmentPollComponent;
let fixture: ComponentFixture<AssignmentPollComponent>; let fixture: ComponentFixture<AssignmentPollComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [AssignmentPollComponent, AssignmentPollVoteComponent, PollProgressComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [AssignmentPollComponent, AssignmentPollVoteComponent, PollProgressComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(AssignmentPollComponent); fixture = TestBed.createComponent(AssignmentPollComponent);

View File

@ -29,7 +29,8 @@ import { AssignmentPollService } from '../../services/assignment-poll.service';
}) })
export class AssignmentPollComponent export class AssignmentPollComponent
extends BasePollComponent<ViewAssignmentPoll, AssignmentPollService> extends BasePollComponent<ViewAssignmentPoll, AssignmentPollService>
implements OnInit { implements OnInit
{
@Input() @Input()
public set poll(value: ViewAssignmentPoll) { public set poll(value: ViewAssignmentPoll) {
this.initPoll(value); this.initPoll(value);

View File

@ -16,7 +16,8 @@ import { BaseViewComponentDirective } from './base-view';
@Directive() @Directive()
export abstract class BaseImportListComponentDirective<M extends BaseModel> export abstract class BaseImportListComponentDirective<M extends BaseModel>
extends BaseViewComponentDirective extends BaseViewComponentDirective
implements OnInit { implements OnInit
{
/** /**
* The data source for a table. Requires to be initialised with a BaseViewModel * The data source for a table. Requires to be initialised with a BaseViewModel
*/ */

View File

@ -11,7 +11,8 @@ import { BaseViewModel } from './base-view-model';
export abstract class BaseListViewComponent<V extends BaseViewModel> export abstract class BaseListViewComponent<V extends BaseViewModel>
extends BaseViewComponentDirective extends BaseViewComponentDirective
implements OnDestroy { implements OnDestroy
{
/** /**
* The source of the table data, will be filled by an event emitter * The source of the table data, will be filled by an event emitter
*/ */

View File

@ -9,7 +9,8 @@ import { Projectable, ProjectorElementBuildDeskriptor } from './projectable';
*/ */
export abstract class BaseProjectableViewModel<M extends BaseModel = any> export abstract class BaseProjectableViewModel<M extends BaseModel = any>
extends BaseViewModel<M> extends BaseViewModel<M>
implements Projectable { implements Projectable
{
public abstract getSlide(configService?: ConfigService): ProjectorElementBuildDeskriptor; public abstract getSlide(configService?: ConfigService): ProjectorElementBuildDeskriptor;
/** /**

View File

@ -24,7 +24,8 @@ export interface SortTreeFilterOption extends Identifiable {
@Directive() @Directive()
export abstract class SortTreeViewComponentDirective<V extends BaseViewModel> export abstract class SortTreeViewComponentDirective<V extends BaseViewModel>
extends BaseViewComponentDirective extends BaseViewComponentDirective
implements CanComponentDeactivate { implements CanComponentDeactivate
{
/** /**
* Reference to the view child * Reference to the view child
*/ */

View File

@ -1,4 +1,4 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { E2EImportsModule } from 'e2e-imports.module'; import { E2EImportsModule } from 'e2e-imports.module';
@ -8,12 +8,14 @@ describe('ChatMessageComponent', () => {
let component: ChatMessageComponent; let component: ChatMessageComponent;
let fixture: ComponentFixture<ChatMessageComponent>; let fixture: ComponentFixture<ChatMessageComponent>;
beforeEach(async(() => { beforeEach(
TestBed.configureTestingModule({ waitForAsync(() => {
imports: [E2EImportsModule], TestBed.configureTestingModule({
declarations: [ChatMessageComponent] imports: [E2EImportsModule],
}).compileComponents(); declarations: [ChatMessageComponent]
})); }).compileComponents();
})
);
beforeEach(() => { beforeEach(() => {
fixture = TestBed.createComponent(ChatMessageComponent); fixture = TestBed.createComponent(ChatMessageComponent);

Some files were not shown because too many files have changed in this diff Show More