Standalone app is working
This commit is contained in:
@@ -4,16 +4,17 @@ import jwt_decode from "jwt-decode";
|
||||
import { AuthService } from 'src/app/auth/auth.service';
|
||||
import { User } from 'src/app/models/user.model';
|
||||
import { NotificationsService } from 'src/app/services/notifications.service';
|
||||
import { environment } from 'src/environments/environment';
|
||||
import { MatCardModule } from '@angular/material/card';
|
||||
import { environment } from 'src/environments/environment';
|
||||
import { MatCardModule } from '@angular/material/card';
|
||||
import { NgIf } from '@angular/common';
|
||||
import { MatBottomSheetModule } from '@angular/material/bottom-sheet';
|
||||
|
||||
@Component({
|
||||
selector: 'app-login-page',
|
||||
templateUrl: './login-page.component.html',
|
||||
styleUrls: ['./login-page.component.scss'],
|
||||
standalone: true,
|
||||
imports: [NgIf, MatCardModule]
|
||||
@Component({
|
||||
selector: 'app-login-page',
|
||||
templateUrl: './login-page.component.html',
|
||||
styleUrls: ['./login-page.component.scss'],
|
||||
standalone: true,
|
||||
imports: [NgIf, MatCardModule, MatBottomSheetModule]
|
||||
})
|
||||
|
||||
export class LoginPageComponent implements OnInit {
|
||||
|
||||
@@ -9,6 +9,7 @@ import { MatFormFieldModule } from '@angular/material/form-field';
|
||||
import { RouterLink } from '@angular/router';
|
||||
import { MatButtonModule } from '@angular/material/button';
|
||||
import { MatGridListModule } from '@angular/material/grid-list';
|
||||
import { NotificationsService } from 'src/app/services/notifications.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-layers-list',
|
||||
@@ -25,7 +26,8 @@ export class LayersListComponent implements OnInit {
|
||||
@ViewChild(MatSort) sort!: MatSort;
|
||||
|
||||
constructor(
|
||||
private _http: HttpClient
|
||||
private _http: HttpClient,
|
||||
private notifications$: NotificationsService
|
||||
) { }
|
||||
|
||||
async ngOnInit() {
|
||||
|
||||
@@ -5,7 +5,7 @@ import { v4 as uuidv4 } from 'uuid';
|
||||
import moment, { Moment } from 'moment';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
providedIn: 'root',
|
||||
})
|
||||
export class NotificationsService {
|
||||
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
import { enableProdMode, LOCALE_ID, isDevMode, importProvidersFrom } from '@angular/core';
|
||||
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
|
||||
|
||||
|
||||
import { environment } from './environments/environment';
|
||||
import { AppComponent } from './app/app.component';
|
||||
import { ServiceWorkerModule } from '@angular/service-worker';
|
||||
@@ -13,6 +10,10 @@ import { LoaderInterceptor } from './app/interceptors/loader.interceptor';
|
||||
import { HTTP_INTERCEPTORS, withInterceptorsFromDi, provideHttpClient } from '@angular/common/http';
|
||||
import { MomentDateAdapter, MAT_MOMENT_DATE_ADAPTER_OPTIONS } from '@angular/material-moment-adapter';
|
||||
import { DateAdapter, MAT_DATE_LOCALE } from '@angular/material/core';
|
||||
import { MatBottomSheetModule } from '@angular/material/bottom-sheet';
|
||||
import localePl from '@angular/common/locales/pl';
|
||||
import { registerLocaleData } from '@angular/common';
|
||||
registerLocaleData(localePl);
|
||||
|
||||
if (environment.production) {
|
||||
enableProdMode();
|
||||
@@ -25,10 +26,11 @@ bootstrapApplication(AppComponent, {
|
||||
// Register the ServiceWorker as soon as the application is stable
|
||||
// or after 30 seconds (whichever comes first).
|
||||
registrationStrategy: 'registerWhenStable:30000'
|
||||
})),
|
||||
}),
|
||||
MatBottomSheetModule),
|
||||
{ provide: DateAdapter, useClass: MomentDateAdapter, deps: [MAT_DATE_LOCALE, MAT_MOMENT_DATE_ADAPTER_OPTIONS] },
|
||||
{ provide: MAT_MOMENT_DATE_ADAPTER_OPTIONS, useValue: { useUtc: true } },
|
||||
{ provide: LOCALE_ID, useValue: 'pl-PL' },
|
||||
{ provide: LOCALE_ID, useValue: 'pl' },
|
||||
{
|
||||
provide: HTTP_INTERCEPTORS,
|
||||
useClass: LoaderInterceptor,
|
||||
|
||||
Reference in New Issue
Block a user