Added PWA manifest with icons and service. #4
@@ -30,13 +30,15 @@
|
||||
"inlineStyleLanguage": "scss",
|
||||
"assets": [
|
||||
"src/favicon.ico",
|
||||
"src/assets"
|
||||
"src/assets",
|
||||
"src/manifest.webmanifest"
|
||||
],
|
||||
"styles": [
|
||||
"./node_modules/@angular/material/prebuilt-themes/indigo-pink.css",
|
||||
"src/styles.scss"
|
||||
],
|
||||
"scripts": []
|
||||
"scripts": [],
|
||||
"serviceWorker": "src/ngsw-config.json"
|
||||
},
|
||||
"configurations": {
|
||||
"production": {
|
||||
@@ -58,7 +60,8 @@
|
||||
"with": "src/environments/environment.prod.ts"
|
||||
}
|
||||
],
|
||||
"outputHashing": "all"
|
||||
"outputHashing": "all",
|
||||
"serviceWorker": "src/ngsw-config.json"
|
||||
},
|
||||
"development": {
|
||||
"optimization": false,
|
||||
|
||||
@@ -17,11 +17,12 @@
|
||||
"@angular/compiler": "^21.0.0",
|
||||
"@angular/core": "^21.0.0",
|
||||
"@angular/forms": "^21.0.0",
|
||||
"@angular/material": "^21.0.0",
|
||||
"@angular/localize": "^21.0.0",
|
||||
"@angular/material": "^21.0.0",
|
||||
"@angular/platform-browser": "^21.0.0",
|
||||
"@angular/platform-browser-dynamic": "^21.0.0",
|
||||
"@angular/router": "^21.0.0",
|
||||
"@angular/service-worker": "^21.1.1",
|
||||
"date-fns": "^4.1.0",
|
||||
"rxjs": "~7.8.0",
|
||||
"tslib": "^2.8.1",
|
||||
|
||||
@@ -13,6 +13,8 @@ import { RegonComponent } from './components/regon/regon.component';
|
||||
import { IbanComponent } from './components/iban/iban.component';
|
||||
import { IdentityCardComponent } from './components/identitycard/identitycard.component';
|
||||
import {NgOptimizedImage} from "@angular/common";
|
||||
import { ServiceWorkerModule } from '@angular/service-worker';
|
||||
import { environment } from '../environments/environment';
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
@@ -33,6 +35,12 @@ import {NgOptimizedImage} from "@angular/common";
|
||||
MatSnackBarModule,
|
||||
ReactiveFormsModule,
|
||||
NgOptimizedImage,
|
||||
ServiceWorkerModule.register('ngsw-worker.js', {
|
||||
enabled: environment.production,
|
||||
// Register the ServiceWorker as soon as the application is stable
|
||||
// or after 30 seconds (whichever comes first).
|
||||
registrationStrategy: 'registerWhenStable:30000'
|
||||
}),
|
||||
],
|
||||
providers: [TranslatePipe],
|
||||
bootstrap: [AppComponent]
|
||||
|
||||
BIN
src/assets/icons/icon-128x128.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
src/assets/icons/icon-144x144.png
Normal file
|
After Width: | Height: | Size: 25 KiB |
BIN
src/assets/icons/icon-152x152.png
Normal file
|
After Width: | Height: | Size: 27 KiB |
BIN
src/assets/icons/icon-192x192.png
Normal file
|
After Width: | Height: | Size: 40 KiB |
BIN
src/assets/icons/icon-384x384.png
Normal file
|
After Width: | Height: | Size: 132 KiB |
BIN
src/assets/icons/icon-512x512.png
Normal file
|
After Width: | Height: | Size: 229 KiB |
BIN
src/assets/icons/icon-72x72.png
Normal file
|
After Width: | Height: | Size: 7.9 KiB |
BIN
src/assets/icons/icon-96x96.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
src/favicon.ico
|
Before Width: | Height: | Size: 948 B After Width: | Height: | Size: 2.1 KiB |
@@ -5,7 +5,9 @@
|
||||
<title>Generator i walidator identyfikatorów</title>
|
||||
<base href="/">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" type="image/x-icon" href="favicon.ico">
|
||||
<link rel="icon" type="image/png" href="favicon.ico">
|
||||
<link rel="manifest" href="./manifest.webmanifest">
|
||||
<meta name="theme-color" content="#3f51b5">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com">
|
||||
<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500&display=swap" rel="stylesheet">
|
||||
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
|
||||
|
||||
59
src/manifest.webmanifest
Normal file
@@ -0,0 +1,59 @@
|
||||
{
|
||||
"name": "Generator i walidator identyfikatorów",
|
||||
"short_name": "Generator",
|
||||
"theme_color": "#3f51b5",
|
||||
"background_color": "#fafafa",
|
||||
"display": "standalone",
|
||||
"scope": "./",
|
||||
"start_url": "./",
|
||||
"icons": [
|
||||
{
|
||||
"src": "./assets/icons/icon-72x72.png",
|
||||
"sizes": "72x72",
|
||||
"type": "image/png",
|
||||
"purpose": "any"
|
||||
},
|
||||
{
|
||||
"src": "./assets/icons/icon-96x96.png",
|
||||
"sizes": "96x96",
|
||||
"type": "image/png",
|
||||
"purpose": "any"
|
||||
},
|
||||
{
|
||||
"src": "./assets/icons/icon-128x128.png",
|
||||
"sizes": "128x128",
|
||||
"type": "image/png",
|
||||
"purpose": "any"
|
||||
},
|
||||
{
|
||||
"src": "./assets/icons/icon-144x144.png",
|
||||
"sizes": "144x144",
|
||||
"type": "image/png",
|
||||
"purpose": "any"
|
||||
},
|
||||
{
|
||||
"src": "./assets/icons/icon-152x152.png",
|
||||
"sizes": "152x152",
|
||||
"type": "image/png",
|
||||
"purpose": "any"
|
||||
},
|
||||
{
|
||||
"src": "./assets/icons/icon-192x192.png",
|
||||
"sizes": "192x192",
|
||||
"type": "image/png",
|
||||
"purpose": "any"
|
||||
},
|
||||
{
|
||||
"src": "./assets/icons/icon-384x384.png",
|
||||
"sizes": "384x384",
|
||||
"type": "image/png",
|
||||
"purpose": "any"
|
||||
},
|
||||
{
|
||||
"src": "./assets/icons/icon-512x512.png",
|
||||
"sizes": "512x512",
|
||||
"type": "image/png",
|
||||
"purpose": "any"
|
||||
}
|
||||
]
|
||||
}
|
||||
29
src/ngsw-config.json
Normal file
@@ -0,0 +1,29 @@
|
||||
{
|
||||
"index": "/index.html",
|
||||
"assetGroups": [
|
||||
{
|
||||
"name": "app",
|
||||
"installMode": "prefetch",
|
||||
"resources": {
|
||||
"files": [
|
||||
"/favicon.ico",
|
||||
"/index.html",
|
||||
"/manifest.webmanifest",
|
||||
"/*.css",
|
||||
"/*.js"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "assets",
|
||||
"installMode": "lazy",
|
||||
"updateMode": "prefetch",
|
||||
"resources": {
|
||||
"files": [
|
||||
"/assets/**",
|
||||
"/*.(svg|cur|jpg|jpeg|png|apng|webp|avif|apple-touch-icon|png|otf|ttf|woff|woff2)"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||