From 55d138f01ac75c3dcd3c2b59d38c78edd68d8085 Mon Sep 17 00:00:00 2001 From: kevin olson Date: Sun, 8 Oct 2023 00:51:26 -0500 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20awesome=20progress=20moving=20to=20?= =?UTF-8?q?nuxt=20ui?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .eslintrc | 4 + .eslintrc.js | 5 - .vscode/settings.json | 6 + app/Http/Controllers/SessionController.php | 2 +- client/app.config.ts | 26 + client/app.vue | 27 + client/assets/css/main.css | 23 - client/components/contact/ContactCard.vue | 8 +- .../contact/ContactCardSkeleton.vue | 24 +- client/components/header/HeaderBar.vue | 4 +- client/components/header/HeaderLoginModal.vue | 71 +- client/components/header/HeaderProfile.vue | 10 +- .../components/layout/LayoutBreadCrumbs.vue | 6 +- client/components/session/SessionDevice.vue | 69 +- .../session/SessionDeviceSkeleton.vue | 70 +- client/components/session/SessionList.vue | 10 +- client/composables/api.ts | 3 +- client/composables/confirm.ts | 24 + client/composables/modal.ts | 17 + client/layouts/README.md | 7 - client/layouts/default.vue | 8 - client/lib/api.ts | 117 +- client/lib/menu.ts | 11 +- client/middleware/auth.global.ts | 20 +- client/middleware/guest.ts | 3 - client/pages/home.vue | 11 +- client/pages/index.vue | 27 +- client/pages/sessions.vue | 6 +- composer.json | 2 +- composer.lock | 1109 ++- nuxt.config.ts | 28 +- package.json | 46 +- pnpm-lock.yaml | 8266 +++++++++++++++++ readme.md | 2 +- tsconfig.json | 8 +- windi.config.ts | 12 - yarn.lock | 7305 --------------- 37 files changed, 9177 insertions(+), 8220 deletions(-) create mode 100644 .eslintrc delete mode 100644 .eslintrc.js create mode 100644 client/app.config.ts create mode 100644 client/app.vue create mode 100644 client/composables/confirm.ts create mode 100644 client/composables/modal.ts delete mode 100644 client/layouts/README.md delete mode 100644 client/layouts/default.vue delete mode 100644 client/middleware/guest.ts create mode 100644 pnpm-lock.yaml delete mode 100644 windi.config.ts delete mode 100644 yarn.lock diff --git a/.eslintrc b/.eslintrc new file mode 100644 index 00000000..c6cfc5b1 --- /dev/null +++ b/.eslintrc @@ -0,0 +1,4 @@ +{ + "root": true, + "extends": ["@antfu"] +} diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index 7b6ac704..00000000 --- a/.eslintrc.js +++ /dev/null @@ -1,5 +0,0 @@ -process.env.ESLINT_TSCONFIG = 'tsconfig.json' - -module.exports = { - extends: '@antfu', -} diff --git a/.vscode/settings.json b/.vscode/settings.json index 2dacf5a6..cecae4e9 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,4 +1,10 @@ { + "files.associations": { + "*.css": "tailwindcss" + }, + "editor.quickSuggestions": { + "strings": true + }, "prettier.enable": false, "editor.formatOnSave": false, "editor.codeActionsOnSave": { diff --git a/app/Http/Controllers/SessionController.php b/app/Http/Controllers/SessionController.php index c3a3b616..a92013b0 100644 --- a/app/Http/Controllers/SessionController.php +++ b/app/Http/Controllers/SessionController.php @@ -14,7 +14,7 @@ class SessionController extends Controller */ public function index(): JsonResponse|Response { - sleep(1); + // sleep(2); return $this->render(Session::whereUserId(auth()->user()?->id)->get()); } diff --git a/client/app.config.ts b/client/app.config.ts new file mode 100644 index 00000000..18d98c24 --- /dev/null +++ b/client/app.config.ts @@ -0,0 +1,26 @@ +export default defineAppConfig({ + ui: { + primary: 'emerald', + gray: 'slate', + notifications: { + // Show toasts at the top right of the screen for desktop + // position: 'lg:top-0 lg:right-0 lg:justify-start', + + }, + button: { + default: { + loadingIcon: 'i-mdi-loading', + }, + }, + input: { + default: { + loadingIcon: 'i-mdi-loading', + }, + }, + selectMenu: { + default: { + selectedIcon: 'i-mdi-check-bold', + }, + }, + } +}) diff --git a/client/app.vue b/client/app.vue new file mode 100644 index 00000000..45a983db --- /dev/null +++ b/client/app.vue @@ -0,0 +1,27 @@ + + + diff --git a/client/assets/css/main.css b/client/assets/css/main.css index cc97de2d..02bd3def 100644 --- a/client/assets/css/main.css +++ b/client/assets/css/main.css @@ -13,26 +13,3 @@ p, h1, h2, h3 { button { @apply bg-transparent; } - -.skeleton { - --text-opacity: 0; - background-image: linear-gradient(100deg, #edf2f7 0%, #f4f7fa 20%, #edf2f7 40%); - background-position: 50%; - background-size: 200%; - animation: skeleton 1.25s infinite linear; - @apply rounded-md; -} - -.dark .skeleton { - background-image: linear-gradient(100deg, #4B5563 0%, #6B7280 20%, #4B5563 40%); -} - - -@keyframes skeleton { - 0% { - background-position: 50%; - } - 50%, 100% { - background-position: -100% - } -} diff --git a/client/components/contact/ContactCard.vue b/client/components/contact/ContactCard.vue index 4c1b3935..15709202 100644 --- a/client/components/contact/ContactCard.vue +++ b/client/components/contact/ContactCard.vue @@ -12,7 +12,7 @@ const is_admin = computed(() => Math.random() >= 0.5)