add vue-router and empty upload viewer delete views.

This commit is contained in:
2026-09-28 14:55:21 +02:00
parent 0d1b9c0d40
commit a7dac01168
9 changed files with 79 additions and 7 deletions
+1 -4
View File
@@ -1,6 +1,3 @@
<template>
<main class="flex min-h-screen flex-col p-8">
<h1 class="text-2xl font-semibold tracking-tight">Private Image</h1>
<p class="mt-2 text-muted-foreground">Privacy-first image hosting — upload UI coming soon.</p>
</main>
<router-view />
</template>
+5
View File
@@ -0,0 +1,5 @@
export const ROUTE_NAMES = {
Upload: 'Upload',
Viewer: 'Viewer',
Delete: 'Delete'
} as const;
+2 -1
View File
@@ -1,5 +1,6 @@
import { createApp } from 'vue';
import '@/assets/css/main.css';
import App from './App.vue';
import router from './router';
createApp(App).mount('#app');
createApp(App).use(router).mount('#app');
+28
View File
@@ -0,0 +1,28 @@
import { createRouter, createWebHistory } from 'vue-router';
import { ROUTE_NAMES } from '@/consts/routeNames';
const router = createRouter({
history: createWebHistory(import.meta.env.BASE_URL),
routes: [
{
path: '/',
name: ROUTE_NAMES.Upload,
component: () => import('@/views/UploadView.vue'),
meta: { title: 'Private Image — Upload' }
},
{
path: '/v/:id',
name: ROUTE_NAMES.Viewer,
component: () => import('@/views/ViewerView.vue'),
meta: { title: 'Private Image — Viewer' }
},
{
path: '/d/:id',
name: ROUTE_NAMES.Delete,
component: () => import('@/views/DeleteView.vue'),
meta: { title: 'Private Image — Delete' }
}
]
});
export default router;
+6
View File
@@ -0,0 +1,6 @@
<template>
<main class="flex min-h-screen flex-col p-8">
<h1 class="text-2xl font-semibold tracking-tight">Delete</h1>
<p class="mt-2 text-muted-foreground">Delete upload — coming soon.</p>
</main>
</template>
+6
View File
@@ -0,0 +1,6 @@
<template>
<main class="flex min-h-screen flex-col p-8">
<h1 class="text-2xl font-semibold tracking-tight">Upload</h1>
<p class="mt-2 text-muted-foreground">Upload UI coming soon.</p>
</main>
</template>
+6
View File
@@ -0,0 +1,6 @@
<template>
<main class="flex min-h-screen flex-col p-8">
<h1 class="text-2xl font-semibold tracking-tight">Viewer</h1>
<p class="mt-2 text-muted-foreground">Zero-knowledge viewer — coming soon.</p>
</main>
</template>