From fc699ca874f4f819bc8ea417b1fabb4910bdb6b3 Mon Sep 17 00:00:00 2001 From: Karolis Kundrotas Date: Fri, 10 Sep 2021 01:54:05 +0300 Subject: [PATCH] Refinement and cleanup --- KTUSA PS/ClientApp/.prettierrc.js | 6 + KTUSA PS/ClientApp/package-lock.json | 5 + KTUSA PS/ClientApp/package.json | 1 + KTUSA PS/ClientApp/src/App.vue | 40 ++++- KTUSA PS/ClientApp/src/components/Counter.vue | 26 ---- .../ClientApp/src/components/FetchData.vue | 53 ------- KTUSA PS/ClientApp/src/components/Home.vue | 78 ---------- KTUSA PS/ClientApp/src/components/NavMenu.vue | 96 ++++-------- KTUSA PS/ClientApp/src/main.js | 21 +-- KTUSA PS/ClientApp/src/pages/Home.vue | 84 ++++++----- KTUSA PS/ClientApp/src/pages/OidcEndpoint.vue | 46 ++---- KTUSA PS/ClientApp/src/router/index.js | 32 ++-- KTUSA PS/ClientApp/src/store/modules/auth.js | 142 +++++++++++++----- .../Controllers/AuthMetadataController.cs | 24 +++ KTUSA PS/Controllers/TestController.cs | 4 +- KTUSA PS/Startup.cs | 8 +- KTUSA PS/appsettings.Development.json | 5 +- KTUSA PS/appsettings.json | 5 +- 18 files changed, 301 insertions(+), 375 deletions(-) create mode 100644 KTUSA PS/ClientApp/.prettierrc.js delete mode 100644 KTUSA PS/ClientApp/src/components/Counter.vue delete mode 100644 KTUSA PS/ClientApp/src/components/FetchData.vue delete mode 100644 KTUSA PS/ClientApp/src/components/Home.vue create mode 100644 KTUSA PS/Controllers/AuthMetadataController.cs diff --git a/KTUSA PS/ClientApp/.prettierrc.js b/KTUSA PS/ClientApp/.prettierrc.js new file mode 100644 index 0000000..0614ee7 --- /dev/null +++ b/KTUSA PS/ClientApp/.prettierrc.js @@ -0,0 +1,6 @@ +module.exports = { + trailingComma: 'es5', + tabWidth: 2, + semi: false, + singleQuote: true, +} diff --git a/KTUSA PS/ClientApp/package-lock.json b/KTUSA PS/ClientApp/package-lock.json index afcbec4..db7f3de 100644 --- a/KTUSA PS/ClientApp/package-lock.json +++ b/KTUSA PS/ClientApp/package-lock.json @@ -1113,6 +1113,11 @@ "integrity": "sha512-shAmDyaQC4H92APFoIaVDHCx5bStIocgvbwQyxPRrbUY20V1EYTbSDchWbuwlMG3V17cprZhA6+78JfB+3DTPw==", "dev": true }, + "@popperjs/core": { + "version": "2.10.1", + "resolved": "https://registry.npmjs.org/@popperjs/core/-/core-2.10.1.tgz", + "integrity": "sha512-HnUhk1Sy9IuKrxEMdIRCxpIqPw6BFsbYSEUO9p/hNw5sMld/+3OLMWQP80F8/db9qsv3qUjs7ZR5bS/R+iinXw==" + }, "@soda/friendly-errors-webpack-plugin": { "version": "1.7.1", "resolved": "https://registry.npmjs.org/@soda/friendly-errors-webpack-plugin/-/friendly-errors-webpack-plugin-1.7.1.tgz", diff --git a/KTUSA PS/ClientApp/package.json b/KTUSA PS/ClientApp/package.json index b27cf99..644267b 100644 --- a/KTUSA PS/ClientApp/package.json +++ b/KTUSA PS/ClientApp/package.json @@ -8,6 +8,7 @@ "lint": "vue-cli-service lint" }, "dependencies": { + "@popperjs/core": "^2.10.1", "axios": "^0.20.0-0", "bootstrap": "^5.1.1", "cookies-js": "^1.2.3", diff --git a/KTUSA PS/ClientApp/src/App.vue b/KTUSA PS/ClientApp/src/App.vue index 990a19c..12da81c 100644 --- a/KTUSA PS/ClientApp/src/App.vue +++ b/KTUSA PS/ClientApp/src/App.vue @@ -1,21 +1,49 @@ - + diff --git a/KTUSA PS/ClientApp/src/components/Counter.vue b/KTUSA PS/ClientApp/src/components/Counter.vue deleted file mode 100644 index ad746cb..0000000 --- a/KTUSA PS/ClientApp/src/components/Counter.vue +++ /dev/null @@ -1,26 +0,0 @@ - - - - \ No newline at end of file diff --git a/KTUSA PS/ClientApp/src/components/FetchData.vue b/KTUSA PS/ClientApp/src/components/FetchData.vue deleted file mode 100644 index 785ae2b..0000000 --- a/KTUSA PS/ClientApp/src/components/FetchData.vue +++ /dev/null @@ -1,53 +0,0 @@ - - - - \ No newline at end of file diff --git a/KTUSA PS/ClientApp/src/components/Home.vue b/KTUSA PS/ClientApp/src/components/Home.vue deleted file mode 100644 index 3f34b55..0000000 --- a/KTUSA PS/ClientApp/src/components/Home.vue +++ /dev/null @@ -1,78 +0,0 @@ - - - - - - diff --git a/KTUSA PS/ClientApp/src/components/NavMenu.vue b/KTUSA PS/ClientApp/src/components/NavMenu.vue index 1bc7c0b..bc53f9d 100644 --- a/KTUSA PS/ClientApp/src/components/NavMenu.vue +++ b/KTUSA PS/ClientApp/src/components/NavMenu.vue @@ -1,97 +1,65 @@ - - \ No newline at end of file +} + diff --git a/KTUSA PS/ClientApp/src/main.js b/KTUSA PS/ClientApp/src/main.js index 41d2bbe..5e59846 100644 --- a/KTUSA PS/ClientApp/src/main.js +++ b/KTUSA PS/ClientApp/src/main.js @@ -1,12 +1,15 @@ -import { createApp } from "vue"; -import App from "./App.vue"; -import router from "./router"; -import store from "./store"; -import "./assets/main.scss"; +import { createApp } from 'vue' +import App from './App.vue' +import router from './router' +import store from './store' +import './assets/main.scss' +import 'bootstrap' -const app = createApp(App); +const app = createApp(App) -app.use(router); -app.use(store); +app.use(router) +app.use(store) -app.mount("#app"); +app.mount('#app') + +window.r = router diff --git a/KTUSA PS/ClientApp/src/pages/Home.vue b/KTUSA PS/ClientApp/src/pages/Home.vue index 4835402..d375071 100644 --- a/KTUSA PS/ClientApp/src/pages/Home.vue +++ b/KTUSA PS/ClientApp/src/pages/Home.vue @@ -1,11 +1,14 @@