import { ViewportScroller } from '@angular/common'; import { ChangeDetectionStrategy, Component } from '@angular/core'; import { ActivatedRoute, RouterOutlet } from '@angular/router'; import { ContentTextService } from '@app/app/components/content-text.component.js'; import { AppTitle } from '@app/app/components/title'; import { Seo } from '@app/app/components/seo.js'; import { Translation } from '@app/app/components/translation.js'; import { DuiApp, DuiStyleComponent } from '@deepkit/desktop-ui'; @Component({ selector: 'app-root', imports: [RouterOutlet, AppTitle, DuiStyleComponent], host: { '[class.content-text-dark]': 'contentTextService.darkMode()', }, template: ` @if (translation.ready()) { } `, changeDetection: ChangeDetectionStrategy.Eager, styleUrls: ['./app.component.css'], }) export class AppComponent { constructor( public activeRoute: ActivatedRoute, private viewportScroller: ViewportScroller, public contentTextService: ContentTextService, public translation: Translation, private duiApp: DuiApp, seo: Seo, ) { // viewportScroller.setOffset([0, 84]); // duiApp.disableThemeDetection(); // duiApp.setDarkMode(false); viewportScroller.setHistoryScrollRestoration('auto'); } }