Skip to content

Commit

Permalink
Merge pull request #46 from cesmii/feature/pwa
Browse files Browse the repository at this point in the history
Feature/pwa
  • Loading branch information
scott181182 authored Jun 7, 2024
2 parents ca4c2fc + a148e38 commit 214c57e
Show file tree
Hide file tree
Showing 14 changed files with 42 additions and 0 deletions.
2 changes: 2 additions & 0 deletions frontend/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,5 @@ logs

# Generated files
generated/
# Generated Service Workers
sw.*
1 change: 1 addition & 0 deletions frontend/app.vue
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<template>
<NuxtPwaManifest/>
<NuxtLayout>
<NuxtPage />
</NuxtLayout>
Expand Down
Binary file modified frontend/bun.lockb
Binary file not shown.
35 changes: 35 additions & 0 deletions frontend/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ import { GRAPHL_TOKEN_KEY } from "./lib/consts";



const DESCRIPTION = "CESMII's OEE app provides a glanceable view of a KPI used in many manufacturing environments, and works where ever the OEE Profile is implemented";
const THEME_COLOR = "#212121";
const BACKGROUND_COLOR = "#000000";

// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
devtools: { enabled: true },
Expand All @@ -13,7 +17,16 @@ export default defineNuxtConfig({
app: {
head: {
charset: "utf-8",
viewport: "width=device-width, initial-scale=1",
title: "CESMII OEE Dashboard",
meta: [
{ name: "description", content: DESCRIPTION },
{ name: "theme-color", content: THEME_COLOR },
],
link: [
{ rel: "icon", href: "/favicon.ico", sizes: "48x48" },
{ rel: "apple-touch-icon", href: "/icon-180-bg-black.png" },
],
},
},
modules: [
Expand All @@ -24,7 +37,29 @@ export default defineNuxtConfig({
},
"@nuxt/eslint",
"@nuxtjs/apollo",
"@vite-pwa/nuxt",
],
pwa: {
registerType: "autoUpdate",
devOptions: {
enabled: true,
},
manifest: {
name: "CESMII OEE Dashboard",
short_name: "OEEApp",
description: DESCRIPTION,
theme_color: THEME_COLOR,
background_color: BACKGROUND_COLOR,

icons: [
{ src: "/icon-512.png", sizes: "512x512", type: "image/png" },
{ src: "/icon-512.png", sizes: "512x512", type: "image/png", purpose: "any" },
{ src: "/icon-512-bg-black.png", sizes: "512x512", type: "image/png", purpose: "maskable" },
{ src: "/icon-192.png", sizes: "192x192", type: "image/png" },
{ src: "/icon-64.png", sizes: "64x64", type: "image/png" },
],
},
},
apollo: {
autoImports: true,
clients: {
Expand Down
2 changes: 2 additions & 0 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,11 @@
"@nuxt/eslint": "^0.3.10",
"@nuxtjs/apollo": "^5.0.0-alpha.14",
"@nuxtjs/eslint-config-typescript": "^12.1.0",
"@vite-pwa/nuxt": "^0.8.0",
"eslint": "^8.57.0",
"sass": "^1.77.0",
"typescript": "^5.4.5",
"vite-plugin-pwa": "^0.20.0",
"vite-plugin-vuetify": "^2.0.3",
"vuetify": "^3.6.6"
}
Expand Down
Binary file modified frontend/public/favicon.ico
Binary file not shown.
Binary file added frontend/public/icon-180-bg-black.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/icon-180-bg-white.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/icon-192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/icon-512-bg-black.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/icon-512-bg-white.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/icon-512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/icon-64.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions frontend/public/robots.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
User-agent: *
Allow: /

0 comments on commit 214c57e

Please sign in to comment.