From 44dfe145ed0a1b96e8cbf90bb04af1a1550588c3 Mon Sep 17 00:00:00 2001 From: Michel Roux Date: Sat, 2 Nov 2024 19:41:13 +0100 Subject: [PATCH] refactor: :wastebasket: cleaning scafolding code --- eslint.config.js | 8 +- frontend/App.vue | 84 ++---------------- frontend/assets/base.css | 86 ------------------ frontend/assets/logo.svg | 1 - frontend/assets/main.css | 35 -------- frontend/components/HelloWorld.vue | 41 --------- frontend/components/TheWelcome.vue | 88 ------------------- frontend/components/WelcomeItem.vue | 87 ------------------ frontend/components/icons/IconCommunity.vue | 7 -- .../components/icons/IconDocumentation.vue | 7 -- frontend/components/icons/IconEcosystem.vue | 7 -- frontend/components/icons/IconSupport.vue | 7 -- frontend/components/icons/IconTooling.vue | 19 ---- frontend/main.ts | 4 - frontend/router/index.ts | 12 +-- frontend/views/AboutView.vue | 15 ---- frontend/views/Containers.vue | 9 ++ frontend/views/HomeView.vue | 9 -- index.html | 2 +- package-lock.json | 17 ++++ package.json | 2 + 21 files changed, 44 insertions(+), 503 deletions(-) delete mode 100644 frontend/assets/base.css delete mode 100644 frontend/assets/logo.svg delete mode 100644 frontend/assets/main.css delete mode 100644 frontend/components/HelloWorld.vue delete mode 100644 frontend/components/TheWelcome.vue delete mode 100644 frontend/components/WelcomeItem.vue delete mode 100644 frontend/components/icons/IconCommunity.vue delete mode 100644 frontend/components/icons/IconDocumentation.vue delete mode 100644 frontend/components/icons/IconEcosystem.vue delete mode 100644 frontend/components/icons/IconSupport.vue delete mode 100644 frontend/components/icons/IconTooling.vue delete mode 100644 frontend/views/AboutView.vue create mode 100644 frontend/views/Containers.vue delete mode 100644 frontend/views/HomeView.vue diff --git a/eslint.config.js b/eslint.config.js index 3009bb4..a7f3858 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -13,7 +13,13 @@ export default [ ignores: ['**/dist/**', '**/dist-ssr/**', '**/coverage/**'], }, - ...pluginVue.configs['flat/essential'], + ...pluginVue.configs['flat/recommended'], ...vueTsEslintConfig(), skipFormatting, + + { + rules: { + 'vue/multi-word-component-names': 'off', + } + } ] diff --git a/frontend/App.vue b/frontend/App.vue index 7905b05..511f6f5 100644 --- a/frontend/App.vue +++ b/frontend/App.vue @@ -1,85 +1,13 @@ - - - + diff --git a/frontend/assets/base.css b/frontend/assets/base.css deleted file mode 100644 index 8816868..0000000 --- a/frontend/assets/base.css +++ /dev/null @@ -1,86 +0,0 @@ -/* color palette from */ -:root { - --vt-c-white: #ffffff; - --vt-c-white-soft: #f8f8f8; - --vt-c-white-mute: #f2f2f2; - - --vt-c-black: #181818; - --vt-c-black-soft: #222222; - --vt-c-black-mute: #282828; - - --vt-c-indigo: #2c3e50; - - --vt-c-divider-light-1: rgba(60, 60, 60, 0.29); - --vt-c-divider-light-2: rgba(60, 60, 60, 0.12); - --vt-c-divider-dark-1: rgba(84, 84, 84, 0.65); - --vt-c-divider-dark-2: rgba(84, 84, 84, 0.48); - - --vt-c-text-light-1: var(--vt-c-indigo); - --vt-c-text-light-2: rgba(60, 60, 60, 0.66); - --vt-c-text-dark-1: var(--vt-c-white); - --vt-c-text-dark-2: rgba(235, 235, 235, 0.64); -} - -/* semantic color variables for this project */ -:root { - --color-background: var(--vt-c-white); - --color-background-soft: var(--vt-c-white-soft); - --color-background-mute: var(--vt-c-white-mute); - - --color-border: var(--vt-c-divider-light-2); - --color-border-hover: var(--vt-c-divider-light-1); - - --color-heading: var(--vt-c-text-light-1); - --color-text: var(--vt-c-text-light-1); - - --section-gap: 160px; -} - -@media (prefers-color-scheme: dark) { - :root { - --color-background: var(--vt-c-black); - --color-background-soft: var(--vt-c-black-soft); - --color-background-mute: var(--vt-c-black-mute); - - --color-border: var(--vt-c-divider-dark-2); - --color-border-hover: var(--vt-c-divider-dark-1); - - --color-heading: var(--vt-c-text-dark-1); - --color-text: var(--vt-c-text-dark-2); - } -} - -*, -*::before, -*::after { - box-sizing: border-box; - margin: 0; - font-weight: normal; -} - -body { - min-height: 100vh; - color: var(--color-text); - background: var(--color-background); - transition: - color 0.5s, - background-color 0.5s; - line-height: 1.6; - font-family: - Inter, - -apple-system, - BlinkMacSystemFont, - 'Segoe UI', - Roboto, - Oxygen, - Ubuntu, - Cantarell, - 'Fira Sans', - 'Droid Sans', - 'Helvetica Neue', - sans-serif; - font-size: 15px; - text-rendering: optimizeLegibility; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; -} diff --git a/frontend/assets/logo.svg b/frontend/assets/logo.svg deleted file mode 100644 index 7565660..0000000 --- a/frontend/assets/logo.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/frontend/assets/main.css b/frontend/assets/main.css deleted file mode 100644 index 36fb845..0000000 --- a/frontend/assets/main.css +++ /dev/null @@ -1,35 +0,0 @@ -@import './base.css'; - -#app { - max-width: 1280px; - margin: 0 auto; - padding: 2rem; - font-weight: normal; -} - -a, -.green { - text-decoration: none; - color: hsla(160, 100%, 37%, 1); - transition: 0.4s; - padding: 3px; -} - -@media (hover: hover) { - a:hover { - background-color: hsla(160, 100%, 37%, 0.2); - } -} - -@media (min-width: 1024px) { - body { - display: flex; - place-items: center; - } - - #app { - display: grid; - grid-template-columns: 1fr 1fr; - padding: 0 2rem; - } -} diff --git a/frontend/components/HelloWorld.vue b/frontend/components/HelloWorld.vue deleted file mode 100644 index d174cf8..0000000 --- a/frontend/components/HelloWorld.vue +++ /dev/null @@ -1,41 +0,0 @@ - - - - - diff --git a/frontend/components/TheWelcome.vue b/frontend/components/TheWelcome.vue deleted file mode 100644 index e65a66b..0000000 --- a/frontend/components/TheWelcome.vue +++ /dev/null @@ -1,88 +0,0 @@ - - - diff --git a/frontend/components/WelcomeItem.vue b/frontend/components/WelcomeItem.vue deleted file mode 100644 index 6d7086a..0000000 --- a/frontend/components/WelcomeItem.vue +++ /dev/null @@ -1,87 +0,0 @@ - - - diff --git a/frontend/components/icons/IconCommunity.vue b/frontend/components/icons/IconCommunity.vue deleted file mode 100644 index 2dc8b05..0000000 --- a/frontend/components/icons/IconCommunity.vue +++ /dev/null @@ -1,7 +0,0 @@ - diff --git a/frontend/components/icons/IconDocumentation.vue b/frontend/components/icons/IconDocumentation.vue deleted file mode 100644 index 6d4791c..0000000 --- a/frontend/components/icons/IconDocumentation.vue +++ /dev/null @@ -1,7 +0,0 @@ - diff --git a/frontend/components/icons/IconEcosystem.vue b/frontend/components/icons/IconEcosystem.vue deleted file mode 100644 index c3a4f07..0000000 --- a/frontend/components/icons/IconEcosystem.vue +++ /dev/null @@ -1,7 +0,0 @@ - diff --git a/frontend/components/icons/IconSupport.vue b/frontend/components/icons/IconSupport.vue deleted file mode 100644 index 7452834..0000000 --- a/frontend/components/icons/IconSupport.vue +++ /dev/null @@ -1,7 +0,0 @@ - diff --git a/frontend/components/icons/IconTooling.vue b/frontend/components/icons/IconTooling.vue deleted file mode 100644 index 660598d..0000000 --- a/frontend/components/icons/IconTooling.vue +++ /dev/null @@ -1,19 +0,0 @@ - - diff --git a/frontend/main.ts b/frontend/main.ts index 5a5dbdb..efe493a 100644 --- a/frontend/main.ts +++ b/frontend/main.ts @@ -1,11 +1,7 @@ -import './assets/main.css' - import { createApp } from 'vue' import App from './App.vue' import router from './router' const app = createApp(App) - app.use(router) - app.mount('#app') diff --git a/frontend/router/index.ts b/frontend/router/index.ts index a49ae50..8f6c25a 100644 --- a/frontend/router/index.ts +++ b/frontend/router/index.ts @@ -1,5 +1,5 @@ import { createRouter, createWebHistory } from 'vue-router' -import HomeView from '../views/HomeView.vue' +import Containers from '../views/Containers.vue' const router = createRouter({ history: createWebHistory(import.meta.env.BASE_URL), @@ -7,16 +7,8 @@ const router = createRouter({ { path: '/', name: 'home', - component: HomeView + component: Containers }, - { - path: '/about', - name: 'about', - // route level code-splitting - // this generates a separate chunk (About.[hash].js) for this route - // which is lazy-loaded when the route is visited. - component: () => import('../views/AboutView.vue') - } ] }) diff --git a/frontend/views/AboutView.vue b/frontend/views/AboutView.vue deleted file mode 100644 index 756ad2a..0000000 --- a/frontend/views/AboutView.vue +++ /dev/null @@ -1,15 +0,0 @@ - - - diff --git a/frontend/views/Containers.vue b/frontend/views/Containers.vue new file mode 100644 index 0000000..bf4e689 --- /dev/null +++ b/frontend/views/Containers.vue @@ -0,0 +1,9 @@ + + + diff --git a/frontend/views/HomeView.vue b/frontend/views/HomeView.vue deleted file mode 100644 index d5c0217..0000000 --- a/frontend/views/HomeView.vue +++ /dev/null @@ -1,9 +0,0 @@ - - - diff --git a/index.html b/index.html index f8736aa..59e287d 100644 --- a/index.html +++ b/index.html @@ -4,7 +4,7 @@ - Vite App + Pilotwings
diff --git a/package-lock.json b/package-lock.json index 9959095..0b66db6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8,6 +8,8 @@ "name": "frontend", "version": "0.0.0", "dependencies": { + "bulma": "^1.0.2", + "font-awesome": "^4.7.0", "vue": "^3.5.12", "vue-router": "^4.4.5" }, @@ -1550,6 +1552,12 @@ "node": ">=8" } }, + "node_modules/bulma": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/bulma/-/bulma-1.0.2.tgz", + "integrity": "sha512-D7GnDuF6seb6HkcnRMM9E739QpEY9chDzzeFrHMyEns/EXyDJuQ0XA0KxbBl/B2NTsKSoDomW61jFGFaAxhK5A==", + "license": "MIT" + }, "node_modules/callsites": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", @@ -2160,6 +2168,15 @@ "dev": true, "license": "ISC" }, + "node_modules/font-awesome": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/font-awesome/-/font-awesome-4.7.0.tgz", + "integrity": "sha512-U6kGnykA/6bFmg1M/oT9EkFeIYv7JlX3bozwQJWiiLz6L0w3F5vBVPxHlwyX/vtNq1ckcpRKOB9f2Qal/VtFpg==", + "license": "(OFL-1.1 AND MIT)", + "engines": { + "node": ">=0.10.3" + } + }, "node_modules/fsevents": { "version": "2.3.3", "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", diff --git a/package.json b/package.json index 35b7e7f..8ef2e4f 100644 --- a/package.json +++ b/package.json @@ -12,6 +12,8 @@ "format": "prettier --write frontend/" }, "dependencies": { + "bulma": "^1.0.2", + "font-awesome": "^4.7.0", "vue": "^3.5.12", "vue-router": "^4.4.5" },