Skip to content

📚 The open-source, offline-first Notion, Obsidian & Confluence alternative. Advanced Markdown, multi-tenant teams, OIDC/SSO, and local S3 backups. Deploy in one command.

feat: migrate to localForage & add handling pages (#551)

Smaugf6d41832ca6f
diff --git a/frontend/app/App.vue b/frontend/app/App.vue
index c5f5a338..62b0a871 100644
--- a/frontend/app/App.vue
+++ b/frontend/app/App.vue
@@ -1,5 +1,5 @@
<template>
- <div id="app">
+ <div v-show="!isLoading" id="app">
<ModalManager />
<ContextMenuManager />
<NuxtLayout>
@@ -7,6 +7,7 @@
</NuxtLayout>
<Notification />
</div>
+ <SplashScreen v-show="isLoading" />
</template>
<script setup lang="ts">
@@ -16,6 +17,8 @@ useFavicon();
const preferences = usePreferencesStore();
const { setAppColor } = useAppColors();
const { setLocale } = useI18n();
+const { isLoading } = useAppState();
+const router = useRouter();
const primaryColor = preferences.get('primaryColor');
const interfaceStyle = preferences.get('style');
@@ -45,6 +48,13 @@ watch(
},
{ immediate: true },
);
+
+router.beforeEach((to, from, next) => {
+ if (to.path.startsWith('/dashboard') && from.path === '/login') {
+ isLoading.value = true;
+ }
+ next();
+});
</script>
<style lang="scss">
diff --git a/frontend/app/components/Node/Card/Recent.vue b/frontend/app/components/Node/Card/Recent.vue
index 0cf7bb0f..099705d9 100644
--- a/frontend/app/components/Node/Card/Recent.vue
+++ b/frontend/app/components/Node/Card/Recent.vue
@@ -1,17 +1,33 @@
<template>
<div class="card">
<div class="header">
- <Icon :name="icon" display="xl" :class="['node-icon', getAppAccent(node.color || (category?.color as number), true)]" />
+ <!-- Icone enveloppée pour un contrÎle précis des dimensions -->
+ <div class="icon-wrapper">
+ <Icon :name="icon" display="xl" :class="['node-icon', getAppAccent(node.color || (category?.color as number), true)]" />
+ </div>
<span class="time">{{ relativeTime(node.updated_timestamp) }}</span>
</div>
- <h3 class="title">{{ node.name }}</h3>
- <p v-if="node.description" class="desc">{{ node.description }}</p>
- <div class="meta">
- <span v-if="category" class="category">
+
+ <!-- Le corps de la carte est enveloppé pour isoler le push du margin-top: auto du footer -->
+ <div class="card-body">
+ <h3 class="title" :title="node.name">{{ node.name }}</h3>
+ <p v-if="node.description" class="desc">{{ node.description }}</p>
+ </div>
+
+ <!-- Footer de métadonnées propre et scannable -->
+ <div v-if="category || node.tags" class="meta">
+ <span v-if="category" class="category" :title="category.name">
{{ category.name }}
</span>
+
+ <!-- Petit séparateur visuel si on a ET une catégorie ET des tags -->
+ <span v-if="category && node.tags" class="meta-separator">·</span>
+
<div v-if="node.tags" class="tags">
- <tag v-for="tag in node.tags.split(',').slice(0, 2)" :key="tag" class="primary">{{ tag.trim() }}</tag>
+ <!-- Remplacement du tag custom par un traitement de badge standardisé -->
+ <span v-for="tag in computedTags" :key="tag" class="tag-badge">
+ {{ tag }}
+ </span>
</div>
</div>
</div>
@@ -30,25 +46,40 @@ const { getAppAccent } = useAppColors();
const category = nodesStore.getById(props.node.parent_id || '');
const icon = resolveIcon(props.node);
+
+// Nettoyage et découpage des tags sécurisé
+const computedTags = computed(() => {
+ if (!props.node.tags) return [];
+ return props.node.tags
+ .split(',')
+ .map(t => t.trim())
+ .filter(t => t.length > 0)
+ .slice(0, 2);
+});
</script>
<style scoped lang="scss">
.card {
display: flex;
+ flex-direction: column;
height: 100%;
- padding: 1rem;
+ padding: 1.25rem; /* Augmenté légÚrement pour un rendu plus aéré / premium */
border: 1px solid var(--border);
border-radius: var(--radius-lg);
+ background: var(--surface-base);
color: var(--text-body);
- transition:
- border-color $transition-base ease,
- box-shadow $transition-base ease,
- transform $transition-base ease;
- flex-direction: column;
text-decoration: none;
+ // Utilisation des variables de transition de ton projet
+ transition:
+ border-color $transition-fast ease,
+ background-color $transition-fast ease,
+ box-shadow $transition-fast ease,
+ transform $transition-fast ease;
+
&:hover {
border-color: var(--primary);
+ background: var(--surface-raised); /* Donne un effet de profondeur au survol */
box-shadow: var(--shadow-md);
transform: translateY(-2px);
}
@@ -58,18 +89,40 @@ const icon = resolveIcon(props.node);
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 0.5rem;
+ margin-bottom: 1rem;
+}
+
+.icon-wrapper {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+}
+
+.node-icon {
+ padding: 0.4rem;
+ border-radius: var(--radius-sm);
}
.time {
font-size: 0.75rem;
+ font-weight: 500;
color: var(--text-secondary);
}
+.card-body {
+ display: flex;
+ flex-direction: column;
+ flex: 1;
+}
+
.title {
font-size: 1rem;
font-weight: 600;
- margin-bottom: 0.25rem;
+ line-height: 1.4;
+ margin: 0 0 0.35rem 0;
+ color: var(--text-body);
+
+ // Sécurité anti-débordement
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
@@ -78,11 +131,12 @@ const icon = resolveIcon(props.node);
.desc {
display: -webkit-box;
font-size: 0.85rem;
+ line-height: 1.5;
color: var(--text-secondary);
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
line-clamp: 2;
- margin-bottom: 0.5rem;
+ margin: 0 0 1rem 0;
overflow: hidden;
}
@@ -90,20 +144,48 @@ const icon = resolveIcon(props.node);
display: flex;
align-items: center;
gap: 0.5rem;
- margin-top: auto;
+ margin-top: auto; /* Pousse le footer vers le bas de la carte, peu importe la taille du texte */
+ padding-top: 0.5rem;
+ min-width: 0; /* Important pour que le flex-truncate fonctionne dedans */
}
.category {
font-size: 0.75rem;
+ font-weight: 600;
color: var(--text-secondary);
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ max-width: 110px;
+}
+
+.meta-separator {
+ font-size: 0.8rem;
+ color: var(--border);
+ user-select: none;
}
.tags {
display: flex;
+ gap: 0.35rem;
+ flex-wrap: wrap;
}
-.node-icon {
- padding: 0.4rem;
- border-radius: var(--radius-sm);
+.tag-badge {
+ display: inline-flex;
+ align-items: center;
+ padding: 0.15rem 0.45rem;
+ font-size: 0.72rem;
+ font-weight: 600;
+ border-radius: var(--radius-xs);
+ // Un fond neutre et discret qui s'adapte au mode sombre
+ background: var(--surface-raised);
+ border: 1px solid var(--border);
+ color: var(--text-secondary);
+
+ // Au survol de la carte globale, on peut accentuer subtilement les badges
+ .card:hover & {
+ background: var(--surface-base);
+ }
}
</style>
diff --git a/frontend/app/components/Node/Card/Workspace.vue b/frontend/app/components/Node/Card/Workspace.vue
index 4fbcb184..897e06e8 100644
--- a/frontend/app/components/Node/Card/Workspace.vue
+++ b/frontend/app/components/Node/Card/Workspace.vue
@@ -1,5 +1,6 @@
<template>
<div class="workspace-tile" :class="accentColorClass">
+ <!-- La lueur utilise désormais une variable CSS `--accent-color` injectée proprement par getAppAccent -->
<div class="glow-ambiance" />
<div class="tile-content">
@@ -16,7 +17,7 @@
</div>
<div class="meta-zone">
- <h3 class="ws-title">{{ workspace.name }}</h3>
+ <h3 class="ws-title" :title="workspace.name">{{ workspace.name }}</h3>
<p v-if="workspace.description" class="ws-description">
{{ workspace.description }}
</p>
@@ -27,7 +28,7 @@
<span v-for="child in categories.slice(0, 2)" :key="child.id" class="pill">
{{ child.name }}
</span>
- <span v-if="categories.length > 2" class="pill-more"> +{{ categories.length - 2 }} autres </span>
+ <span v-if="categories.length > 2" class="pill-more"> +{{ categories.length - 2 }} </span>
</div>
</div>
</div>
@@ -43,6 +44,7 @@ const props = defineProps<{ workspace: Node }>();
const nodesStore = useNodesStore();
const { getAppAccent } = useAppColors();
+// Nettoyage de la logique de couleur pour utiliser les mĂȘmes standards de l'app
const accentColorClass = computed(() => {
const colors = ['blue', 'red', 'green', 'yellow', 'purple', 'pink', 'teal', 'primary'];
const colorIndex = props.workspace.color as number;
@@ -64,44 +66,40 @@ const docCount = computed(() => {
<style scoped lang="scss">
.workspace-tile {
- --tile-radius: 14px;
- --bg-speed: 0.3s;
-
position: relative;
display: flex;
height: 100%;
- padding: 1rem;
+ padding: 1.25rem;
border: 1px solid var(--border);
- border-radius: var(--tile-radius);
+ border-radius: var(--radius-lg);
background: var(--surface-base);
- transition:
- border-color var(--bg-speed) ease,
- transform 0.4s cubic-bezier(0.25, 1, 0.5, 1),
- box-shadow 0.4s ease;
- cursor: pointer;
flex-direction: column;
overflow: hidden;
+ cursor: pointer;
+
+ transition:
+ border-color $transition-fast ease,
+ background-color $transition-fast ease,
+ box-shadow $transition-fast ease,
+ transform $transition-fast cubic-bezier(0.25, 1, 0.5, 1);
&:hover {
- border-color: rgb(var(--primary), 0.35);
- box-shadow:
- 0 20px 30px -10px rgb(0 0 0 / 30%),
- 0 0 0 1px rgb(var(--primary), 0.1);
- transform: translateY(-6px) scale(1.01);
+ border-color: var(--primary);
+ background: var(--surface-raised);
+ box-shadow: var(--shadow-md);
+ transform: translateY(-2px);
.glow-ambiance {
- opacity: 0.12;
- transform: scale(1.2);
+ opacity: 0.08;
+ transform: scale(1.1);
}
.icon-box {
.ws-icon {
- transform: scale(1.1);
+ transform: scale(1.05);
}
-
.status-dot {
- box-shadow: 0 0 12px var(--primary);
- transform: scale(1.3);
+ box-shadow: 0 0 8px var(--primary);
}
}
}
@@ -112,90 +110,95 @@ const docCount = computed(() => {
top: -20%;
right: -20%;
z-index: 0;
- width: 70%;
- height: 70%;
- background: radial-gradient(circle, var(--accent-color) 0%, transparent 70%);
+ width: 60%;
+ height: 60%;
+ background: radial-gradient(circle, color-mix(in srgb, var(--primary) 25%, transparent) 0%, transparent 75%);
opacity: 0;
- transition:
- opacity 0.6s ease,
- transform 0.6s ease;
- filter: blur(40px);
pointer-events: none;
+ filter: blur(30px);
+ transition:
+ opacity $transition-base ease,
+ transform $transition-base ease;
}
.tile-content {
position: relative;
z-index: 1;
display: flex;
- height: 100%;
flex-direction: column;
+ height: 100%;
}
.top-row {
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 1.5rem;
+ margin-bottom: 1.25rem;
}
.icon-box {
position: relative;
display: flex;
- width: 2.8rem;
- height: 2.8rem;
- border-radius: 10px;
+ width: 2.5rem;
+ height: 2.5rem;
+ border-radius: var(--radius-md);
align-items: center;
justify-content: center;
.ws-icon {
- font-size: 1.4rem;
- transition: transform 0.3s ease;
+ font-size: 1.25rem;
+ transition: transform $transition-fast ease;
}
.status-dot {
position: absolute;
- top: -2px;
- right: -2px;
- width: 7px;
- height: 7px;
- border: 1.5px solid var(--surface-base);
+ top: -1px;
+ right: -1px;
+ width: 8px;
+ height: 8px;
+ border: 2px solid var(--surface-base);
border-radius: 50%;
- background: var(--primary-border);
- transition:
- transform 0.3s ease,
- box-shadow 0.3s ease;
+ background: var(--primary);
+ transition: box-shadow $transition-fast ease;
+
+ .workspace-tile:hover & {
+ border-color: var(--surface-raised);
+ }
}
}
.doc-badge {
display: flex;
- font-family: monospace;
align-items: baseline;
- gap: 0.2rem;
+ gap: 0.25rem;
+ color: var(--text-body);
.count-number {
- font-size: 1.3rem;
+ font-size: 1.2rem;
font-weight: 700;
+ letter-spacing: -0.02em;
}
.count-label {
font-size: 0.75rem;
- color: var(--text-muted);
- letter-spacing: 0.05em;
- text-transform: uppercase;
+ font-weight: 600;
+ color: var(--text-secondary);
}
}
.meta-zone {
- margin-bottom: 1.5rem;
+ margin-bottom: 1.25rem;
+ flex: 1;
.ws-title {
- margin: 0 0 0.4rem;
- font-size: 1.25rem;
+ margin: 0 0 0.35rem 0;
+ font-size: 1.05rem;
font-weight: 600;
color: var(--text-body);
- transition: color 0.2s ease;
- letter-spacing: -0.02em;
+ letter-spacing: -0.01em;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
}
.ws-description {
@@ -214,21 +217,26 @@ const docCount = computed(() => {
.tile-footer {
border-top: 1px solid var(--border);
margin-top: auto;
- padding-top: 1rem;
+ padding-top: 0.75rem;
}
.category-pills {
display: flex;
align-items: center;
+ gap: 0.5rem;
flex-wrap: wrap;
- gap: 0.75rem;
+ min-width: 0;
.pill {
position: relative;
font-size: 0.75rem;
- font-weight: 500;
+ font-weight: 600;
color: var(--text-secondary);
- padding-left: 0.6rem;
+ padding-left: 0.5rem;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ max-width: 100px;
&::before {
position: absolute;
@@ -237,19 +245,26 @@ const docCount = computed(() => {
width: 4px;
height: 4px;
border-radius: 50%;
- background: var(--border-strong);
+ background: var(--border);
content: '';
transform: translateY(-50%);
}
}
.pill-more {
- padding: 0.1rem 0.4rem;
- border-radius: 4px;
- font-size: 0.72rem;
- font-weight: 500;
- color: var(--text-muted);
+ display: inline-flex;
+ align-items: center;
+ padding: 0.15rem 0.35rem;
+ border-radius: var(--radius-xs);
+ font-size: 0.7rem;
+ font-weight: 600;
+ color: var(--text-secondary);
background: var(--surface-raised);
+ border: 1px solid var(--border);
+
+ .workspace-tile:hover & {
+ background: var(--surface-base);
+ }
}
}
</style>
diff --git a/frontend/app/components/Node/Document/Footer.vue b/frontend/app/components/Node/Document/Footer.vue
index 3ec38e92..57fcf664 100644
--- a/frontend/app/components/Node/Document/Footer.vue
+++ b/frontend/app/components/Node/Document/Footer.vue
@@ -6,7 +6,7 @@
</div>
</div>
<div class="footer-top-row">
- <NuxtLink :to="`/dashboard/docs/edit/${document.id}`" :prefetch="false" class="edit-link">
+ <NuxtLink :to="`/dashboard/docs/edit/${document.id}`" class="edit-link">
<Icon name="edit_page" display="sm" />
<span>{{ t('nodes.document.editPage') }}</span>
</NuxtLink>
diff --git a/frontend/app/components/Node/Filter.vue b/frontend/app/components/Node/Filter.vue
index c421a8a4..5b6f7c83 100644
--- a/frontend/app/components/Node/Filter.vue
+++ b/frontend/app/components/Node/Filter.vue
@@ -119,17 +119,6 @@ onBeforeUnmount(() => {
display: inline-block;
}
-.bubble {
- position: absolute;
- top: 2px;
- right: 2px;
- width: 10px;
- height: 10px;
- border: 3px solid var(--primary);
- border-radius: 50%;
- background: var(--primary-bg);
-}
-
.filter-panel {
position: absolute;
top: 48px;
diff --git a/frontend/app/components/Node/Modals/Permissions.vue b/frontend/app/components/Node/Modals/Permissions.vue
index e7b777b2..b4b279cd 100644
--- a/frontend/app/components/Node/Modals/Permissions.vue
+++ b/frontend/app/components/Node/Modals/Permissions.vue
@@ -219,7 +219,7 @@ const updatePermission = async (perm: Permission) => {
const removePermission = async (perm: Permission) => {
if (!node.value) return;
- await nodesStore.removePermission(node.value.id, perm.user_id);
+ await nodesStore.removePermission(perm);
node.value.permissions = node.value.permissions.filter(p => p.id !== perm.id);
};
</script>
diff --git a/frontend/app/components/Node/Modals/RemoveShared.vue b/frontend/app/components/Node/Modals/RemoveShared.vue
index 37f89f27..152f3990 100644
--- a/frontend/app/components/Node/Modals/RemoveShared.vue
+++ b/frontend/app/components/Node/Modals/RemoveShared.vue
@@ -15,20 +15,27 @@
const props = defineProps<{ nodeId: string }>();
const emit = defineEmits(['close']);
+const nodesStore = useNodesStore();
+const userStore = useUserStore();
+
const { t } = useI18nT();
const nodesTree = useNodesTree();
+const notifications = useNotifications();
const allChildren = nodesTree.getSubtreeAsArray(props.nodeId);
const removeDoc = () => {
- useNodesStore()
- .removePermission(props.nodeId, useUserStore().user!.id)
+ const node = nodesStore.getById(props.nodeId);
+ const perm = node?.permissions.find(p => p.user_id === userStore.user?.id);
+ if (!perm) return notifications.add({ type: 'error', title: t('common.errors.generic') });
+ nodesStore
+ .removePermission(perm)
.then(() => {
- useNotifications().add({ type: 'success', title: t('nodes.modals.removeShared.success') });
+ notifications.add({ type: 'success', title: t('nodes.modals.removeShared.success') });
emit('close');
useRouter().push('/dashboard');
})
- .catch(e => useNotifications().add({ type: 'error', title: t('common.errors.generic'), message: e }));
+ .catch(e => notifications.add({ type: 'error', title: t('common.errors.generic'), message: e }));
};
</script>
diff --git a/frontend/app/components/Sidebar/Dock.vue b/frontend/app/components/Sidebar/Dock.vue
index 539e9d17..4e991542 100644
--- a/frontend/app/components/Sidebar/Dock.vue
+++ b/frontend/app/components/Sidebar/Dock.vue
@@ -1,27 +1,9 @@
<template>
<div class="dock">
- <NuxtLink to="/dashboard/home">
- <Icon name="dashboard" display="lg" />
- </NuxtLink>
- <NuxtLink to="/dashboard/categories">
- <Icon name="categories" display="lg" />
- </NuxtLink>
- <NuxtLink to="/dashboard/docs">
- <Icon name="files" display="lg" />
- </NuxtLink>
- <NuxtLink to="/dashboard/cdn">
- <Icon name="cdn" display="lg" />
+ <NuxtLink v-for="item in items" :key="item.label" :to="item.to" :class="{ admin: isAdmin && item.adminOnly, show: isAdmin && item.adminOnly }">
+ <Icon :name="item.icon" display="lg" /><span v-if="mark.hasMark(item.mark as MarkId)" class="bubble" />
</NuxtLink>
- <NuxtLink to="/dashboard/import">
- <Icon name="import" display="lg" />
- </NuxtLink>
- <NuxtLink to="/dashboard/cdn/diagram">
- <Icon name="format/diagrams" display="lg" />
- </NuxtLink>
- <NuxtLink v-if="userStore.user?.role === 2" to="/dashboard/admin">
- <Icon name="users" display="lg" />
- </NuxtLink>
<div style="margin-top: auto">
<NuxtLink @click="openSettings">
<Icon name="settings" display="lg" />
@@ -40,6 +22,19 @@ const userStore = useUserStore();
const preferences = usePreferencesStore();
const modals = useModal();
+const mark = useMark();
+
+const items = [
+ { label: 'Dashboard', icon: 'dashboard', to: '/dashboard/home' },
+ { label: 'Categories', icon: 'categories', to: '/dashboard/categories' },
+ { label: 'Documents', icon: 'files', to: '/dashboard/docs' },
+ { label: 'CDN', icon: 'cdn', to: '/dashboard/cdn' },
+ { label: 'Import', icon: 'import', to: '/dashboard/import', mark: 'new-imports' },
+ { label: 'Diagrams', icon: 'format/diagrams', to: '/dashboard/cdn/diagram' },
+ { label: 'Admin', icon: 'users', to: '/dashboard/admin', adminOnly: true },
+];
+
+const isAdmin = computed(() => userStore.user?.role === 2);
const openSettings = () => {
modals.add(new Modal(shallowRef(SettingsModal), { props: { isModal: true }, size: 'medium', noPadding: true }));
@@ -61,6 +56,7 @@ function closeDock() {
a {
display: flex;
+ position: relative;
width: 40px;
height: 40px;
border-radius: var(--radius-md);
@@ -75,6 +71,14 @@ a {
}
}
+.admin {
+ display: none;
+}
+
+.show {
+ display: flex;
+}
+
a.router-link-active {
svg {
color: var(--primary) !important;
diff --git a/frontend/app/components/Sidebar/Sidebar.vue b/frontend/app/components/Sidebar/Sidebar.vue
index b2022241..d32b9d96 100644
--- a/frontend/app/components/Sidebar/Sidebar.vue
+++ b/frontend/app/components/Sidebar/Sidebar.vue
@@ -20,7 +20,7 @@
<div class="email">{{ userStore.user.email }}</div>
</NuxtLink>
<div class="icons">
- <NuxtLink to="/dashboard/docs/new" class="nav-item" :prefetch="false" @click="onClick">
+ <NuxtLink to="/dashboard/docs/new" class="nav-item" @click="onClick">
<Icon name="add_file" />
<p class="hint-tooltip">{{ t('components.sidebar.newDoc') }}</p>
</NuxtLink>
diff --git a/frontend/app/components/Sidebar/SidebarItem.vue b/frontend/app/components/Sidebar/SidebarItem.vue
index 1fa28dcd..54567a9f 100644
--- a/frontend/app/components/Sidebar/SidebarItem.vue
+++ b/frontend/app/components/Sidebar/SidebarItem.vue
@@ -15,14 +15,16 @@
<!-- Label -->
<NuxtLink v-if="item.onClick" class="close content" @click="item.onClick">{{ item.data.role == -1 ? t(item.label) : item.label }}</NuxtLink>
- <NuxtLink v-else :to="item.route" class="close content">{{ item.data.role == -1 ? t(item.label) : item.label }}</NuxtLink>
+ <NuxtLink v-else :to="item.route" class="close content"
+ >{{ item.data.role == -1 ? t(item.label) : item.label }} <span v-if="'mark' in item && item.mark && mark.hasMark(item.mark as MarkId)" class="bubble"
+ /></NuxtLink>
<!-- Right icons / actions -->
<Icon v-if="item.data.shared && level === 0" name="shared" fill="var(--text-secondary)" />
<NuxtLink v-if="item.data.role === 2 && canEdit" :to="`/dashboard/categories/${item.id}/edit`" class="nav close">
<Icon name="settings" />
</NuxtLink>
- <NuxtLink v-if="item.data.role === 2" :to="`/dashboard/docs/new?parent_id=${item.id}`" :prefetch="false" class="nav close">
+ <NuxtLink v-if="item.data.role === 2" :to="`/dashboard/docs/new?parent_id=${item.id}`" class="nav close">
<Icon name="plus" />
</NuxtLink>
<Icon v-if="item.data.order === -1" name="pin" fill="var(--text-secondary)" />
@@ -48,6 +50,7 @@ const { isOpened, workspaceId } = useSidebar();
const { getAppAccent } = useAppColors();
const { isMobile } = useDevice();
const contextMenu = useContextMenu();
+const mark = useMark();
const props = defineProps<{ item: SidebarItem; level: number }>();
const isDragOver = ref<boolean>(false);
@@ -167,6 +170,7 @@ const drop = async (event: DragEvent) => {
.content {
flex: 1;
+ position: relative;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
diff --git a/frontend/app/components/Sidebar/SidebarWorkspaces.vue b/frontend/app/components/Sidebar/SidebarWorkspaces.vue
index 8ab37ef8..68ae600b 100644
--- a/frontend/app/components/Sidebar/SidebarWorkspaces.vue
+++ b/frontend/app/components/Sidebar/SidebarWorkspaces.vue
@@ -43,6 +43,7 @@
import SidebarWorkspace from './SidebarWorkspace.vue';
import NewCategoryModal from '~/components/Node/Modals/CreateCategory.vue';
import JoinModal from '~/components/Node/Modals/Join.vue';
+import localForage from 'localforage';
import type { Workspace } from './helpers';
const props = defineProps<{ workspaces: Workspace[]; teams: Workspace[] }>();
@@ -66,8 +67,8 @@ const flattenWorkspaces = (workspaces: Workspace[], depth = 0): Workspace[] => {
const flattenedWorkspaces = computed(() => flattenWorkspaces(props.teams));
watch(
() => props.workspaces,
- opts => {
- const storage_item = localStorage.getItem('filterWorkspace');
+ async opts => {
+ const storage_item = await localForage.getItem<string>('filterWorkspace');
if (storage_item && [...opts, ...flattenedWorkspaces.value, sharedWorkspaces.value].find(option => option.value == storage_item)) {
workspaceId.value = storage_item;
}
@@ -87,8 +88,8 @@ const closeDropdown = () => (isOpen.value = false);
const selectOption = (option: Workspace) => {
workspaceId.value = option.value;
if (option.meta?.role === 0) router.push('/dashboard/teams/' + option.value);
- if (option.value) localStorage.setItem('filterWorkspace', option.value);
- else localStorage.removeItem('filterWorkspace');
+ if (option.value) localForage.setItem('filterWorkspace', option.value);
+ else localForage.removeItem('filterWorkspace');
};
const handleClickOutside = (event: MouseEvent) => {
if (!(event.target as HTMLElement)!.closest('.dropdown-container')) closeDropdown();
diff --git a/frontend/app/components/Sidebar/helpers.ts b/frontend/app/components/Sidebar/helpers.ts
index a2dae5a8..f9a54996 100644
--- a/frontend/app/components/Sidebar/helpers.ts
+++ b/frontend/app/components/Sidebar/helpers.ts
@@ -20,6 +20,7 @@ export interface NavigationItem {
parent_id?: string;
route: string;
show: Ref<boolean>;
+ mark?: string;
}
export type DefaultItem = NavigationItem;
@@ -95,6 +96,7 @@ export const navigationItems = (sidebarItemsPrefs?: Preferences['sidebarItems'])
parent_id: '',
route: '/dashboard/teams',
show: computed(() => sidebarItemsPrefs?.teams ?? true),
+ mark: 'teams',
},
{
data: {
diff --git a/frontend/app/components/SplashScreen.vue b/frontend/app/components/SplashScreen.vue
new file mode 100644
index 00000000..5d07e506
--- /dev/null
+++ b/frontend/app/components/SplashScreen.vue
@@ -0,0 +1,198 @@
+<template>
+ <div id="splash-screen">
+ <div class="background-glow"></div>
+
+ <div class="splash-content">
+ <div class="logo-card">
+ <img src="/Logo/Alexandrie-logo-light.png" alt="Alexandrie" class="splash-logo" width="128" height="128" />
+ </div>
+
+ <h1 class="splash-title">Alexandrie</h1>
+ <p class="splash-subtitle">Your Notes, Beautifully Organized</p>
+
+ <div class="loading-line">
+ <div class="loading-highlight"></div>
+ </div>
+ </div>
+ </div>
+</template>
+
+<style scoped lang="scss">
+#splash-screen {
+ position: fixed;
+ inset: 0;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ overflow: hidden;
+
+ background: radial-gradient(circle at top, #f8f9ff 0%, #ffffff 55%), #fff;
+
+ font-family:
+ Inter,
+ -apple-system,
+ BlinkMacSystemFont,
+ 'Segoe UI',
+ sans-serif;
+
+ user-select: none;
+ z-index: 9999;
+
+ transition:
+ opacity 0.45s ease,
+ visibility 0.45s ease;
+}
+
+#splash-screen.fade-out {
+ opacity: 0;
+ visibility: hidden;
+}
+
+.background-glow {
+ position: absolute;
+ width: 420px;
+ height: 420px;
+
+ background: radial-gradient(circle, rgba(57, 86, 231, 0.12), transparent 70%);
+
+ filter: blur(25px);
+
+ animation: glow 5s ease-in-out infinite alternate;
+}
+
+.splash-content {
+ position: relative;
+ z-index: 2;
+
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+
+ animation: appear 0.8s cubic-bezier(0.22, 0.8, 0.25, 1);
+}
+
+.logo-card {
+ width: 170px;
+ height: 170px;
+
+ display: flex;
+ align-items: center;
+ justify-content: center;
+
+ border-radius: 36px;
+
+ background: rgba(255, 255, 255, 0.75);
+
+ backdrop-filter: blur(18px);
+
+ border: 1px solid rgba(255, 255, 255, 0.75);
+
+ box-shadow:
+ 0 20px 60px rgba(20, 20, 30, 0.08),
+ inset 0 1px 1px rgba(255, 255, 255, 0.9);
+
+ animation: floating 4s ease-in-out infinite;
+}
+
+.splash-logo {
+ width: 128px;
+ height: 128px;
+}
+
+.splash-title {
+ margin-top: 34px;
+ margin-bottom: 8px;
+
+ font-size: 2rem;
+ font-weight: 700;
+
+ letter-spacing: -0.04em;
+
+ color: #111827;
+}
+
+.splash-subtitle {
+ margin: 0;
+
+ color: #8d93a6;
+
+ font-size: 0.95rem;
+
+ letter-spacing: 0.02em;
+}
+
+#splash-screen.fade-out {
+ opacity: 0;
+ visibility: hidden;
+}
+
+/* Animations */
+
+@keyframes appear {
+ from {
+ opacity: 0;
+ transform: translateY(12px) scale(0.97);
+ }
+
+ to {
+ opacity: 1;
+ transform: none;
+ }
+}
+
+@keyframes floating {
+ 0%,
+ 100% {
+ transform: translateY(0);
+ }
+
+ 50% {
+ transform: translateY(-6px);
+ }
+}
+
+@keyframes glow {
+ from {
+ transform: scale(0.95);
+ opacity: 0.7;
+ }
+
+ to {
+ transform: scale(1.08);
+ opacity: 1;
+ }
+}
+
+.loading-line {
+ margin-top: 28px;
+
+ width: 48px;
+ height: 2px;
+
+ border-radius: 999px;
+ overflow: hidden;
+
+ background: rgba(17, 24, 39, 0.08);
+}
+
+.loading-highlight {
+ width: 45%;
+ height: 100%;
+
+ border-radius: inherit;
+
+ background: linear-gradient(90deg, transparent, #3956e7, transparent);
+
+ animation: loadingLine 1.4s ease-in-out infinite;
+}
+
+@keyframes loadingLine {
+ from {
+ transform: translateX(-170%);
+ }
+
+ to {
+ transform: translateX(170%);
+ }
+}
+</style>
diff --git a/frontend/app/components/ViewSelection.vue b/frontend/app/components/ViewSelection.vue
index 356e1ca8..8c974711 100644
--- a/frontend/app/components/ViewSelection.vue
+++ b/frontend/app/components/ViewSelection.vue
@@ -8,6 +8,7 @@
</template>
<script setup lang="ts">
+import localForage from 'localforage';
export type ViewMode = 'kanban' | 'list' | 'table';
const props = withDefaults(
@@ -34,11 +35,11 @@ const viewOptions = computed(() => {
});
watch(view, newView => {
- if (newView) localStorage.setItem('viewSelection', newView);
+ if (newView) localForage.setItem('viewSelection', newView);
});
-onMounted(() => {
- const storedView = localStorage.getItem('viewSelection');
+onMounted(async () => {
+ const storedView = await localForage.getItem<ViewMode>('viewSelection');
const list = ['table', 'list'];
if (props.showKanban) list.push('kanban');
if (storedView && list.includes(storedView)) view.value = storedView as ViewMode;
diff --git a/frontend/app/components/Welcome.vue b/frontend/app/components/Welcome.vue
new file mode 100644
index 00000000..f2bca03b
--- /dev/null
+++ b/frontend/app/components/Welcome.vue
@@ -0,0 +1,227 @@
+<script setup lang="ts">
+const markStore = useMark();
+
+// L'ID de la marque globale de cette release (Ă  ajouter dans ton ACTIVE_MARK_IDS)
+const RELEASE_MARK_ID: MarkId = 'v8.10.0';
+
+const isVisible = ref(false);
+
+onMounted(() => {
+ if (markStore.hasMark(RELEASE_MARK_ID)) {
+ isVisible.value = true;
+ }
+});
+
+function handleClose() {
+ isVisible.value = false;
+ setTimeout(() => {
+ markStore.dismissMark(RELEASE_MARK_ID);
+ }, 400);
+}
+</script>
+
+<template>
+ <Transition name="welcome-collapse">
+ <div v-if="isVisible" class="welcome-banner">
+ <div class="banner-glow"></div>
+
+ <div class="banner-main">
+ <div class="banner-header">
+ <div class="header-title">
+ <div class="primary icon-badge">
+ <Icon name="sparkle" display="md" />
+ </div>
+ <div>
+ <h2>What's new in Alexandrie?</h2>
+ <p class="version-tag">Version 8.10.0</p>
+ </div>
+ </div>
+
+ <AppBtnIcon icon="close" size="sm" @click="handleClose" />
+ </div>
+
+ <div class="grid">
+ <div class="item">
+ <div class="indicator"></div>
+ <div class="text">
+ <h3>Teams</h3>
+ <p>Organize your activities with others. Manage permissions, access rights and collaborate</p>
+ </div>
+ </div>
+
+ <div class="item">
+ <div class="indicator"></div>
+ <div class="text">
+ <h3>Account 2FA</h3>
+ <p>Ensure the security of your account with two-factor authentication.</p>
+ </div>
+ </div>
+
+ <div class="item">
+ <div class="indicator"></div>
+ <div class="text">
+ <h3>Import full folders from your device</h3>
+ <p>Import entire folders including subfolders & images from your device with the advanced import feature.</p>
+ </div>
+ </div>
+ </div>
+
+ <p class="description">
+ And many more improvements, fixes and features!
+ <NuxtLink to="https://github.com/Smaug6739/Alexandrie/discussions" target="_blank">Give feedback</NuxtLink>
+ </p>
+ <div class="banner-actions">
+ <AppButton type="primary" size="sm" @click="handleClose">I understand, thank you!</AppButton>
+ </div>
+ </div>
+ </div>
+ </Transition>
+</template>
+
+<style scoped lang="scss">
+.welcome-banner {
+ position: relative;
+ overflow: hidden;
+ margin-bottom: 1.5rem;
+ border: 2px solid var(--border);
+ border-radius: var(--radius-xl);
+ background: linear-gradient(135deg, var(--surface-base), var(--surface-raised));
+ margin-top: 1.5rem;
+ transition:
+ opacity $transition-fast ease,
+ transform $transition-fast ease,
+ max-height 0.4s ease,
+ margin 0.4s ease,
+ padding 0.4s ease;
+}
+
+.banner-glow {
+ position: absolute;
+ top: -80px;
+ right: -80px;
+ width: 260px;
+ height: 260px;
+ background: radial-gradient(circle, color-mix(in srgb, var(--primary) 12%, transparent), transparent 70%);
+ pointer-events: none;
+}
+
+.banner-main {
+ padding: 1.5rem;
+}
+
+.banner-header {
+ display: flex;
+ justify-content: space-between;
+ align-items: flex-start;
+ margin-bottom: 1.5rem;
+}
+
+.header-title {
+ display: flex;
+ gap: 0.75rem;
+ align-items: center;
+
+ h2 {
+ font-size: 1.25rem;
+ font-weight: 700;
+ margin: 0;
+ color: var(--text-body);
+ }
+}
+
+.icon-badge {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ width: 36px;
+ height: 36px;
+ border-radius: var(--radius-md);
+}
+
+.version-tag {
+ margin: 2px 0 0 0;
+ font-size: 0.8rem;
+ font-weight: 600;
+ color: var(--text-secondary);
+}
+
+// Organisation en grille responsive
+.grid {
+ display: grid;
+ gap: 1.5rem;
+ grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
+ margin-bottom: 1.5rem;
+}
+
+.item {
+ display: flex;
+ gap: 0.75rem;
+ align-items: flex-start;
+}
+
+.indicator {
+ margin-top: 6px;
+ width: 8px;
+ height: 8px;
+ background-color: var(--primary);
+ border-radius: 50%;
+ flex-shrink: 0;
+ box-shadow: 0 0 8px var(--primary-bg);
+}
+
+.text {
+ h3 {
+ font-size: 0.95rem;
+ font-weight: 600;
+ margin: 0 0 4px 0;
+ color: var(--text-body);
+ }
+
+ p {
+ font-size: 0.85rem;
+ color: var(--text-secondary);
+ line-height: 1.4;
+ margin: 0;
+ }
+}
+
+.description {
+ font-size: 0.85rem;
+ color: var(--text-secondary);
+ line-height: 1.4;
+ margin: 0 0 1.5rem 0;
+ a {
+ color: var(--primary);
+ text-decoration: underline;
+ }
+}
+
+.banner-actions {
+ display: flex;
+ justify-content: flex-start;
+}
+
+// Transition d'écrasement fluide à la fermeture
+.welcome-collapse-enter-active {
+ transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
+}
+
+.welcome-collapse-leave-active {
+ transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
+}
+
+.welcome-collapse-enter-from,
+.welcome-collapse-leave-to {
+ opacity: 0;
+ transform: translateY(-8px) scale(0.99);
+ max-height: 0 !important;
+ margin-bottom: 0 !important;
+ padding-top: 0 !important;
+ padding-bottom: 0 !important;
+}
+
+.welcome-collapse-enter-to,
+.welcome-collapse-leave-from {
+ max-height: 400px; /* Doit ĂȘtre supĂ©rieur Ă  la taille max de ta box */
+}
+</style>
diff --git a/frontend/app/composables/useAppState.ts b/frontend/app/composables/useAppState.ts
new file mode 100644
index 00000000..20eb5c73
--- /dev/null
+++ b/frontend/app/composables/useAppState.ts
@@ -0,0 +1,7 @@
+const isLoading = ref(false);
+
+export const useAppState = () => {
+ return {
+ isLoading,
+ };
+};
diff --git a/frontend/app/composables/useCollapseStore.ts b/frontend/app/composables/useCollapseStore.ts
new file mode 100644
index 00000000..d45dd019
--- /dev/null
+++ b/frontend/app/composables/useCollapseStore.ts
@@ -0,0 +1,94 @@
+import { toRaw } from 'vue';
+import localForage from 'localforage';
+
+const COLLAPSE_STORAGE_KEY = 'collapse-states';
+
+// ─── LE SINGLETON VIT ICI DE MANIÈRE UNIQUE ───
+let isInitializing = false;
+let resolveReady: () => void;
+
+const untilReady = new Promise<void>(resolve => {
+ resolveReady = resolve;
+});
+
+// Instance réactive partagée unique pour Nuxt
+// (on utilise une fonction d'initialisation tardive pour éviter les soucis de SSR)
+let states: Ref<Record<string, boolean>> | null = null;
+
+function getStatesRef() {
+ if (!states) {
+ states = useState<Record<string, boolean>>(COLLAPSE_STORAGE_KEY, () => ({}));
+ }
+ return states;
+}
+
+async function init() {
+ if (isInitializing) return;
+ isInitializing = true;
+
+ console.log('🌳 [CollapseStore] Initializing store...');
+
+ if (import.meta.server) {
+ resolveReady();
+ return;
+ }
+
+ try {
+ const savedStates = await localForage.getItem<Record<string, boolean>>(COLLAPSE_STORAGE_KEY);
+ if (savedStates) {
+ getStatesRef().value = savedStates;
+ }
+ } catch (e) {
+ console.warn('[CollapseStore] Failed to load collapse states', e);
+ } finally {
+ resolveReady();
+ console.log('🌳 [CollapseStore] Store is ready !');
+ }
+}
+
+if (import.meta.client) {
+ init();
+} else {
+ if (typeof resolveReady! === 'function') resolveReady();
+}
+
+export function useCollapseStore() {
+ const sharedStates = getStatesRef();
+
+ function save() {
+ if (import.meta.server) return;
+ localForage.setItem(COLLAPSE_STORAGE_KEY, toRaw(sharedStates.value)).catch(e => {
+ console.error('[CollapseStore] Failed to save states', e);
+ });
+ }
+
+ return {
+ untilReady, // Partagé par tous les appels
+ isExpanded: (id: string) => {
+ const state = sharedStates.value[id];
+ if (state === undefined) {
+ sharedStates.value[id] = true;
+ return true;
+ }
+ return state;
+ },
+ setExpanded: (id: string, value: boolean) => {
+ sharedStates.value[id] = value;
+ save();
+ },
+ toggle: (id: string) => {
+ const currentState = sharedStates.value[id] ?? true;
+ sharedStates.value[id] = !currentState;
+ save();
+ },
+ setAll: (expanded: boolean) => {
+ Object.keys(sharedStates.value).forEach(key => {
+ sharedStates.value[key] = expanded;
+ });
+ save();
+ },
+ isAllCollapsed: () => {
+ return Object.values(sharedStates.value).every(v => v === false);
+ },
+ };
+}
diff --git a/frontend/app/composables/useMark.ts b/frontend/app/composables/useMark.ts
new file mode 100644
index 00000000..16e24ef3
--- /dev/null
+++ b/frontend/app/composables/useMark.ts
@@ -0,0 +1,51 @@
+const ACTIVE_MARK_IDS = ['security-2fa', 'new-imports', 'teams', 'v8.10.0', 'workspace-sharing'] as const;
+
+export type MarkId = (typeof ACTIVE_MARK_IDS)[number];
+
+let isGcExecuted = false;
+async function runGarbageCollector(preferencesStore: ReturnType<typeof usePreferencesStore>) {
+ if (isGcExecuted) return;
+ isGcExecuted = true;
+
+ await preferencesStore.untilReady;
+
+ const currentSaved = preferencesStore.preferences.readAnnouncements || [];
+
+ const cleaned = currentSaved.filter(id => ACTIVE_MARK_IDS.includes(id as MarkId));
+
+ if (cleaned.length !== currentSaved.length) {
+ preferencesStore.set('readAnnouncements', cleaned);
+ }
+}
+
+export function useMark() {
+ const preferencesStore = usePreferencesStore();
+
+ // Lancement du GC uniquement cÎté client au montage
+ if (import.meta.client) {
+ onMounted(() => {
+ runGarbageCollector(preferencesStore);
+ });
+ }
+
+ return {
+ hasMark: (id?: MarkId): boolean => {
+ if (!id || !ACTIVE_MARK_IDS.includes(id)) return false;
+
+ const list = preferencesStore.preferences.readAnnouncements || [];
+ return !list.includes(id);
+ },
+
+ dismissMark: (id: MarkId) => {
+ if (!ACTIVE_MARK_IDS.includes(id)) return;
+
+ const currentList = preferencesStore.preferences.readAnnouncements || [];
+
+ if (currentList.includes(id)) return;
+
+ // Ajout et sauvegarde via le store de préférences
+ const newList = [...currentList, id];
+ preferencesStore.set('readAnnouncements', newList);
+ },
+ };
+}
diff --git a/frontend/app/composables/useNodesTree.ts b/frontend/app/composables/useNodesTree.ts
index bd477af9..12c45eba 100644
--- a/frontend/app/composables/useNodesTree.ts
+++ b/frontend/app/composables/useNodesTree.ts
@@ -6,70 +6,6 @@ import { TreeBuilder, flattenTree, type TreeItem } from '~/helpers/TreeBuilder';
import { resolveIcon, resolveNodeLink } from '~/helpers/node';
import type { Node } from '~/stores';
-// ============================================================================
-// Collapse States (localStorage persistence)
-// ============================================================================
-const COLLAPSE_STORAGE_KEY = 'collapse-states';
-
-function createCollapseStore() {
- const states = ref<Record<string, boolean>>({});
- let initialized = false;
-
- function init() {
- if (initialized || import.meta.server) return;
- try {
- const raw = localStorage.getItem(COLLAPSE_STORAGE_KEY);
- states.value = raw ? JSON.parse(raw) : {};
- } catch {
- states.value = {};
- }
- initialized = true;
- }
-
- function save() {
- if (import.meta.server) return;
- localStorage.setItem(COLLAPSE_STORAGE_KEY, JSON.stringify(states.value));
- }
-
- return {
- isExpanded: (id: string) => {
- init();
- const state = states.value[id];
- if (state === undefined) {
- states.value[id] = true;
- return true;
- }
- return state ?? true;
- },
- setExpanded: (id: string, value: boolean) => {
- init();
- states.value[id] = value;
- save();
- },
- toggle: (id: string) => {
- init();
- states.value[id] = !(states.value[id] ?? true);
- save();
- },
- setAll: (expanded: boolean) => {
- init();
- Object.keys(states.value).forEach(key => (states.value[key] = expanded));
- save();
- },
- isAllCollapsed: () => {
- init();
- return Object.values(states.value).every(v => v === false);
- },
- };
-}
-
-// Singleton collapse store
-const collapseStore = createCollapseStore();
-
-// ============================================================================
-// Main Composable
-// ============================================================================
-
let globalBuilder: ComputedRef<TreeBuilder<Node>> | null = null;
let globalTree: ComputedRef<TreeItem<Node>[]> | null = null;
@@ -113,6 +49,7 @@ function transformNode(node: Node): Omit<TreeItem<Node>, 'children'> {
}
export function useNodesTree() {
const nodesStore = useNodesStore();
+ const collapseStore = useCollapseStore();
initGlobalTree();
diff --git a/frontend/app/composables/useOIDC.ts b/frontend/app/composables/useOIDC.ts
index ead20ed4..0dae9072 100644
--- a/frontend/app/composables/useOIDC.ts
+++ b/frontend/app/composables/useOIDC.ts
@@ -2,6 +2,7 @@
* OIDC Authentication Composable
* Handles OpenID Connect authentication flows with frontend callback
*/
+import localForage from 'localforage';
export interface OIDCProvider {
name: string;
@@ -166,7 +167,7 @@ export function useOIDC() {
if (response.status === 'success' && response.result) {
// Only store login state for login flow (not link flow)
if (!response.result.linked) {
- localStorage.setItem('isLoggedIn', 'true');
+ localForage.setItem('isLoggedIn', true);
}
return response.result;
}
diff --git a/frontend/app/middleware/authentication.global.ts b/frontend/app/middleware/authentication.global.ts
index cfe88273..320b2811 100644
--- a/frontend/app/middleware/authentication.global.ts
+++ b/frontend/app/middleware/authentication.global.ts
@@ -1,6 +1,8 @@
+import localForage from 'localforage';
+
export default defineNuxtRouteMiddleware(async (to, _) => {
if (!import.meta.client) return;
- const user_auth = localStorage.getItem('isLoggedIn');
+ const user_auth = await localForage.getItem('isLoggedIn');
if (to.fullPath.startsWith('/dashboard') && !user_auth) {
return navigateTo({
diff --git a/frontend/app/middleware/init.global.ts b/frontend/app/middleware/init.global.ts
new file mode 100644
index 00000000..70359913
--- /dev/null
+++ b/frontend/app/middleware/init.global.ts
@@ -0,0 +1,14 @@
+export default defineNuxtRouteMiddleware(async (to, _) => {
+ if (!to.path.startsWith('/dashboard')) return;
+
+ if (import.meta.client) {
+ const preferencesStore = usePreferencesStore();
+ const collapseStore = useCollapseStore();
+
+ // console.log('🚩 [Middleware] Blocking route until stores are ready...');
+
+ await Promise.all([collapseStore.untilReady, preferencesStore.untilReady]);
+
+ // console.log('🟱 [Middleware] Stores are ready, allowing route:', to.path);
+ }
+});
diff --git a/frontend/app/pages/dashboard.vue b/frontend/app/pages/dashboard.vue
index 52b9fe59..c820a26a 100644
--- a/frontend/app/pages/dashboard.vue
+++ b/frontend/app/pages/dashboard.vue
@@ -13,16 +13,19 @@
<script setup lang="ts">
const nodesStore = useNodesStore();
const userStore = useUserStore();
+const preferencesStore = usePreferencesStore();
-nodesStore.init();
-userStore.fetch();
-usePreferencesStore().fetchFromBackend();
-
+const { isLoading } = useAppState();
useStyleInjection(); // Custom styles for the app and documents
const { initGlobalListeners, destroyGlobalListeners } = useCommandCenter();
+nodesStore.init();
+userStore.fetch();
+preferencesStore.fetchFromBackend();
+
onMounted(() => {
initGlobalListeners();
+ isLoading.value = false;
});
onBeforeUnmount(() => {
destroyGlobalListeners();
diff --git a/frontend/app/pages/dashboard/home.vue b/frontend/app/pages/dashboard/home.vue
index d0833443..44b9094f 100644
--- a/frontend/app/pages/dashboard/home.vue
+++ b/frontend/app/pages/dashboard/home.vue
@@ -1,7 +1,6 @@
<template>
<div class="home-container">
<Teleport to="#navbar-title"> {{ t('dashboard.dashboard') }}</Teleport>
-
<section class="home-top">
<header class="home-header">
<div class="greeting">
@@ -47,6 +46,8 @@
</div>
</section>
+ <Welcome />
+
<div class="sections">
<!-- Section "Continue Working" -->
<section v-if="recentlyEdited.length" class="section">
diff --git a/frontend/app/pages/dashboard/import/index.vue b/frontend/app/pages/dashboard/import/index.vue
index a3269e79..e3364d31 100644
--- a/frontend/app/pages/dashboard/import/index.vue
+++ b/frontend/app/pages/dashboard/import/index.vue
@@ -28,9 +28,9 @@
<span class="cta">{{ t('common.actions.open') }}</span>
</NuxtLink>
- <NuxtLink class="import-card" to="/dashboard/import/advanced">
- <div class="top">
- <h3>{{ t('import.categories.advanced.title') }}</h3>
+ <NuxtLink class="import-card" to="/dashboard/import/advanced" @click="mark.dismissMark('new-imports')">
+ <div class="top" style="position: relative">
+ <h3>{{ t('import.categories.advanced.title') }}<span v-if="mark.hasMark('new-imports')" class="bubble" /></h3>
<tag class="orange">{{ t('common.labels.advanced') }}</tag>
</div>
<Icon name="advanced" display="xxl" />
@@ -45,6 +45,7 @@
definePageMeta({ breadcrumb: { i18n: 'import.meta.breadcrumb' } });
const { t } = useI18nT();
+const mark = useMark();
</script>
<style scoped lang="scss">
diff --git a/frontend/app/pages/dashboard/settings/_views/advanced.vue b/frontend/app/pages/dashboard/settings/_views/advanced.vue
index 64b40832..72a3e22d 100644
--- a/frontend/app/pages/dashboard/settings/_views/advanced.vue
+++ b/frontend/app/pages/dashboard/settings/_views/advanced.vue
@@ -17,11 +17,15 @@
</template>
<script setup lang="ts">
+import localForage from 'localforage';
+
const preferences = usePreferencesStore();
+
const { t } = useI18nT();
const deleteLocalStorage = () => {
localStorage.clear();
+ localForage.clear();
location.reload();
};
</script>
diff --git a/frontend/app/pages/dashboard/settings/index.vue b/frontend/app/pages/dashboard/settings/index.vue
index 94f39745..1550f899 100644
--- a/frontend/app/pages/dashboard/settings/index.vue
+++ b/frontend/app/pages/dashboard/settings/index.vue
@@ -18,14 +18,8 @@
>{{ section.title }} <tag v-if="section.tag" blue>{{ section.tag }}</tag></span
>
<template v-for="item in section.items" :key="item.label">
- <NuxtLink v-if="item.type === 'link'" :to="item.to" @click="close">
- <Icon :name="item.icon" /><span v-if="item.bubble" class="bubble" />{{ item.label }}
- </NuxtLink>
- <NuxtLink v-else-if="item.type === 'action'" @click="item.action?.()">
- <Icon :name="item.icon" /><span v-if="item.bubble" class="bubble" />{{ item.label }}
- </NuxtLink>
- <NuxtLink v-else :class="{ active: currentPage === item.key }" @click="setPage(item.key!)">
- <span v-if="item.bubble" class="bubble" /> <Icon :name="item.icon" />{{ item.label }}
+ <NuxtLink :class="{ active: currentPage === item.key }" @click="handleItemClick(item)">
+ <span v-if="mark.hasMark(item.newId)" class="bubble" /> <Icon :name="item.icon" />{{ item.label }}
</NuxtLink>
</template>
</template>
@@ -61,7 +55,7 @@ interface NavItem {
icon: string;
to?: string;
action?: () => void;
- bubble?: boolean;
+ newId?: MarkId;
}
interface NavSection {
@@ -95,6 +89,7 @@ const router = useRouter();
const store = useUserStore();
const { avatarURL } = useApi();
const { t } = useI18nT();
+const mark = useMark();
const currentPage = ref<PageKey>((route.query.p as PageKey) || 'profile');
const currentComponent = computed(() => pages[currentPage.value]);
@@ -112,7 +107,7 @@ const navSections = computed<NavSection[]>(() => [
items: [
{ key: 'profile', label: t('settings.pages.profile'), icon: 'profil' },
{ key: 'apparence', label: t('settings.pages.appearance'), icon: 'brush' },
- { key: 'security', label: t('settings.pages.security'), icon: 'security', bubble: true },
+ { key: 'security', label: t('settings.pages.security'), icon: 'security', newId: 'security-2fa' },
],
},
{
@@ -131,7 +126,7 @@ const navSections = computed<NavSection[]>(() => [
{ key: 'snippets', label: t('settings.pages.snippets'), icon: 'snippets' },
{ key: 'backup', label: t('settings.pages.backup'), icon: 'backup' },
{ key: 'advanced', label: t('settings.pages.advanced'), icon: 'build' },
- { key: 'teams', label: t('settings.pages.teams'), icon: 'users' },
+ { key: 'teams', label: t('settings.pages.teams'), icon: 'users', newId: 'teams' },
],
},
{
@@ -150,7 +145,20 @@ const navSections = computed<NavSection[]>(() => [
},
]);
-const setPage = (p: PageKey) => {
+const handleItemClick = (item: NavItem) => {
+ if (item.type === 'action') {
+ item.action?.();
+ return;
+ }
+ if (item.type === 'link' && item.to) {
+ router.push(item.to);
+ menuOpen.value = false;
+ return;
+ }
+ if (mark.hasMark(item.newId)) {
+ mark.dismissMark(item.newId!);
+ }
+ const p = item.key!;
router.push({ query: { ...route.query, p } });
currentPage.value = p;
menuOpen.value = false;
@@ -243,17 +251,6 @@ watchEffect(() => {
}
}
-.bubble {
- position: absolute;
- top: 4px;
- right: 4px;
- width: 10px;
- height: 10px;
- border: 3px solid var(--primary);
- border-radius: 50%;
- background: var(--primary-bg);
-}
-
@media screen and (width <= 920px) {
.component {
position: relative;
diff --git a/frontend/app/pages/dashboard/teams/index.vue b/frontend/app/pages/dashboard/teams/index.vue
index 7c5ad265..c51d3b3c 100644
--- a/frontend/app/pages/dashboard/teams/index.vue
+++ b/frontend/app/pages/dashboard/teams/index.vue
@@ -1,7 +1,6 @@
<template>
<div class="page-card teams-index">
<Teleport to="#navbar-title">{{ t('teams.title') }}</Teleport>
-
<header class="hero">
<div>
<p class="eyebrow">{{ t('teams.eyebrown') }}</p>
@@ -39,8 +38,10 @@ import CreateCategoryModal from '~/components/Node/Modals/CreateCategory.vue';
const nodesStore = useNodesStore();
const modals = useModal();
const { t } = useI18nT();
+const mark = useMark();
const query = ref('');
+mark.dismissMark('teams');
const teams = computed(() => nodesStore.teams.toSorted((a, b) => a.name.localeCompare(b.name)));
const filteredTeams = computed(() => {
diff --git a/frontend/app/splash-screen.html b/frontend/app/splash-screen.html
new file mode 100644
index 00000000..519ae06e
--- /dev/null
+++ b/frontend/app/splash-screen.html
@@ -0,0 +1,191 @@
+<div id="splash-screen">
+ <div class="background-glow"></div>
+
+ <div class="splash-content">
+ <div class="logo-card">
+ <img src="/Logo/Alexandrie-logo-light.png" alt="Alexandrie" class="splash-logo" width="128" height="128" />
+ </div>
+
+ <h1 class="splash-title">Alexandrie</h1>
+ <p class="splash-subtitle">
+ Your Notes, Beautifully Organized
+ </p>
+
+ <div class="loading-line">
+ <div class="loading-highlight"></div>
+ </div>
+ </div>
+</div>
+
+<style>
+ #splash-screen {
+ position: fixed;
+ inset: 0;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ overflow: hidden;
+
+ background: radial-gradient(circle at top, #f8f9ff 0%, #ffffff 55%), #fff;
+
+ font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
+
+ user-select: none;
+ z-index: 9999;
+
+ transition: opacity 0.45s ease, visibility 0.45s ease;
+ }
+
+ #splash-screen.fade-out {
+ opacity: 0;
+ visibility: hidden;
+ }
+
+ .background-glow {
+ position: absolute;
+ width: 420px;
+ height: 420px;
+
+ background: radial-gradient(circle, rgba(57, 86, 231, 0.12), transparent 70%);
+
+ filter: blur(25px);
+
+ animation: glow 5s ease-in-out infinite alternate;
+ }
+
+ .splash-content {
+ position: relative;
+ z-index: 2;
+
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+
+ animation: appear 0.8s cubic-bezier(0.22, 0.8, 0.25, 1);
+ }
+
+ .logo-card {
+ width: 170px;
+ height: 170px;
+
+ display: flex;
+ align-items: center;
+ justify-content: center;
+
+ border-radius: 36px;
+
+ background: rgba(255, 255, 255, 0.75);
+
+ backdrop-filter: blur(18px);
+
+ border: 1px solid rgba(255, 255, 255, 0.75);
+
+ box-shadow: 0 20px 60px rgba(20, 20, 30, 0.08),
+ inset 0 1px 1px rgba(255, 255, 255, 0.9);
+
+ animation: floating 4s ease-in-out infinite;
+ }
+
+ .splash-logo {
+ width: 128px;
+ height: 128px;
+ }
+
+ .splash-title {
+ margin-top: 34px;
+ margin-bottom: 8px;
+
+ font-size: 2rem;
+ font-weight: 700;
+
+ letter-spacing: -0.04em;
+
+ color: #111827;
+ }
+
+ .splash-subtitle {
+ margin: 0;
+
+ color: #8d93a6;
+
+ font-size: 0.95rem;
+
+ letter-spacing: 0.02em;
+ }
+
+ #splash-screen.fade-out {
+ opacity: 0;
+ visibility: hidden;
+ }
+
+ /* Animations */
+
+ @keyframes appear {
+ from {
+ opacity: 0;
+ transform: translateY(12px) scale(0.97);
+ }
+
+ to {
+ opacity: 1;
+ transform: none;
+ }
+ }
+
+ @keyframes floating {
+
+ 0%,
+ 100% {
+ transform: translateY(0);
+ }
+
+ 50% {
+ transform: translateY(-6px);
+ }
+ }
+
+ @keyframes glow {
+ from {
+ transform: scale(0.95);
+ opacity: 0.7;
+ }
+
+ to {
+ transform: scale(1.08);
+ opacity: 1;
+ }
+ }
+
+ .loading-line {
+ margin-top: 28px;
+
+ width: 48px;
+ height: 2px;
+
+ border-radius: 999px;
+ overflow: hidden;
+
+ background: rgba(17, 24, 39, 0.08);
+ }
+
+ .loading-highlight {
+ width: 45%;
+ height: 100%;
+
+ border-radius: inherit;
+
+ background: linear-gradient(90deg, transparent, #3956e7, transparent);
+
+ animation: loadingLine 1.4s ease-in-out infinite;
+ }
+
+ @keyframes loadingLine {
+ from {
+ transform: translateX(-170%);
+ }
+
+ to {
+ transform: translateX(170%);
+ }
+ }
+</style>
\ No newline at end of file
diff --git a/frontend/app/stores/preferences/constants.ts b/frontend/app/stores/preferences/constants.ts
index 0676c532..fe71fc6d 100644
--- a/frontend/app/stores/preferences/constants.ts
+++ b/frontend/app/stores/preferences/constants.ts
@@ -4,6 +4,7 @@ export type ANode<ID = number | string> = Omit<TreeItem<unknown, ID>, 'data' | '
export const DEFAULT_PREFERENCES = {
locale: 'en' as 'en' | 'fr',
+ readAnnouncements: [] as string[],
printMode: false as boolean,
darkMode: false as boolean,
hideTOC: false as boolean,
@@ -82,6 +83,7 @@ export type PreferenceKey = keyof Preferences;
// ─── Key mapping: which preference keys go to which backend JSON column ───
export const GENERAL_KEYS: PreferenceKey[] = [
'locale',
+ 'readAnnouncements',
'printMode',
'darkMode',
'hideTOC',
diff --git a/frontend/app/stores/preferences/preferences.ts b/frontend/app/stores/preferences/preferences.ts
index 45e643d7..7d3a38c4 100644
--- a/frontend/app/stores/preferences/preferences.ts
+++ b/frontend/app/stores/preferences/preferences.ts
@@ -1,3 +1,4 @@
+import localForage from 'localforage';
import { DEFAULT_PREFERENCES, ADVANCED_KEYS, EDITOR_KEYS, GENERAL_KEYS, type Preferences } from './constants';
interface BackendSettings {
@@ -7,27 +8,49 @@ interface BackendSettings {
advanced: Record<string, unknown>;
}
-function loadLocalPreferences(): Preferences {
- if (!import.meta.client) return { ...DEFAULT_PREFERENCES };
- try {
- const raw = JSON.parse(localStorage.getItem('preferences') || '{}') as Partial<Preferences>;
- return {
- ...DEFAULT_PREFERENCES,
- ...raw,
- };
- } catch {
- return { ...DEFAULT_PREFERENCES };
- }
-}
+const isReady = ref(false);
+let resolveReady: () => void;
+
+const untilReady = new Promise<void>(resolve => {
+ resolveReady = resolve;
+});
export const usePreferencesStore = defineStore('preferences', () => {
- const preferences = reactive<Preferences>(loadLocalPreferences());
+ const preferences = reactive<Preferences>({ ...DEFAULT_PREFERENCES });
const debouncedSync = useDebounceFn(syncToBackend, 1500);
+ async function initStore() {
+ console.log('🏬 [Preferences] Initializing store...');
+ if (!import.meta.client) return;
+ try {
+ const raw = await localForage.getItem<Partial<Preferences>>('preferences');
+ if (raw) {
+ Object.assign(preferences, {
+ ...DEFAULT_PREFERENCES,
+ ...raw,
+ });
+ }
+ } catch (e) {
+ console.warn('[Preferences] Failed to load local preferences', e);
+ } finally {
+ resolveReady();
+ isReady.value = true;
+ }
+ }
+
+ initStore();
+
function savePreferences() {
+ if (!isReady.value) return;
if (!import.meta.client) return;
- localStorage.setItem('preferences', JSON.stringify(preferences));
+
+ const rawPreferences = toRaw(preferences);
+
+ localForage.setItem('preferences', rawPreferences).catch(e => {
+ console.error('[Preferences] Failed to save to localForage', e);
+ });
+
debouncedSync();
}
@@ -39,7 +62,7 @@ export const usePreferencesStore = defineStore('preferences', () => {
return result;
}
- function splitForBackend(): { general: Record<string, unknown>; editor: Record<string, unknown>; advanced: Record<string, unknown> } {
+ function splitForBackend() {
return {
general: pickKeys(GENERAL_KEYS),
editor: pickKeys(EDITOR_KEYS),
@@ -62,7 +85,7 @@ export const usePreferencesStore = defineStore('preferences', () => {
...settings.editor,
...settings.advanced,
} as Partial<Preferences>;
- // Merge: default ← remote ← (keep any local keys not in remote, to handle new defaults)
+
const merged: Preferences = { ...DEFAULT_PREFERENCES };
for (const key of Object.keys(merged) as PreferenceKey[]) {
if (key in remote && remote[key] !== undefined && remote[key] !== null) {
@@ -70,12 +93,15 @@ export const usePreferencesStore = defineStore('preferences', () => {
}
}
Object.assign(preferences, merged);
- if (import.meta.client) localStorage.setItem('preferences', JSON.stringify(preferences));
+ if (import.meta.client) {
+ localForage.setItem('preferences', toRaw(preferences));
+ }
}
async function syncToBackend() {
if (!import.meta.client) return;
- if (localStorage.getItem('isLoggedIn') !== 'true') return;
+ const isLoggedIn = await localForage.getItem('isLoggedIn');
+ if (!isLoggedIn) return;
try {
await makeRequest('user/settings', 'PUT', splitForBackend());
@@ -86,7 +112,8 @@ export const usePreferencesStore = defineStore('preferences', () => {
async function fetchFromBackend() {
if (!import.meta.client) return;
- if (localStorage.getItem('isLoggedIn') !== 'true') return;
+ const isLoggedIn = await localForage.getItem('isLoggedIn');
+ if (!isLoggedIn) return;
try {
const response = await makeRequest<BackendSettings>('user/settings', 'GET');
if (response.status === 'success' && response.result) {
@@ -96,9 +123,11 @@ export const usePreferencesStore = defineStore('preferences', () => {
console.warn('[Preferences] Failed to fetch from backend', e);
}
}
+
const computedCache = new Map<PreferenceKey, WritableComputedRef<Preferences[PreferenceKey]>>();
+
function get<K extends PreferenceKey>(key: K): WritableComputedRef<Preferences[K]> {
- let existing = computedCache.get(key) as WritableComputedRef<Preferences[K]> | undefined;
+ let existing = computedCache.get(key);
if (!existing) {
existing = computed<Preferences[K]>({
@@ -108,9 +137,9 @@ export const usePreferencesStore = defineStore('preferences', () => {
savePreferences();
},
});
-
computedCache.set(key, existing);
}
+ // @ts-expect-error Correctly typed, but TypeScript doesn't infer it well here
return existing;
}
@@ -129,12 +158,12 @@ export const usePreferencesStore = defineStore('preferences', () => {
savePreferences();
}
- /** Force a full push to backend (e.g. after import) */
function syncNow() {
debouncedSync();
}
return {
+ untilReady,
get,
set,
reset,
diff --git a/frontend/app/stores/user.store.ts b/frontend/app/stores/user.store.ts
index 1af16a94..3e7025ce 100644
--- a/frontend/app/stores/user.store.ts
+++ b/frontend/app/stores/user.store.ts
@@ -1,3 +1,4 @@
+import localForage from 'localforage';
import type { User, PublicUser, Session } from './db_structures';
export const useUserStore = defineStore('user', {
@@ -22,7 +23,7 @@ export const useUserStore = defineStore('user', {
if (response.status === 'success') {
if (response.result?.message === '2FA_REQUIRED') return { success: true, require2FA: true, preAuthToken: response.result?.pre_auth_token };
- if (import.meta.client) localStorage.setItem('isLoggedIn', 'true');
+ if (import.meta.client) localForage.setItem('isLoggedIn', true);
return { success: true, require2FA: false };
} else {
throw response.message;
@@ -53,7 +54,7 @@ export const useUserStore = defineStore('user', {
try {
const response = await makeRequest<{ success: boolean }>('auth/2fa/verify', 'POST', { pre_auth_token: preAuthToken, code });
if (response.status === 'success') {
- if (import.meta.client) localStorage.setItem('isLoggedIn', 'true');
+ if (import.meta.client) localForage.setItem('isLoggedIn', 'true');
return { success: true };
}
throw response.message;
@@ -196,7 +197,7 @@ export const useUserStore = defineStore('user', {
this.user = undefined;
useNodesStore().clear();
useUserStore().clear();
- if (import.meta.client) localStorage.removeItem('isLoggedIn');
+ if (import.meta.client) localForage.removeItem('isLoggedIn');
},
clear() {
diff --git a/frontend/app/styles/components/common.scss b/frontend/app/styles/components/common.scss
index f9b6c076..86851362 100644
--- a/frontend/app/styles/components/common.scss
+++ b/frontend/app/styles/components/common.scss
@@ -33,4 +33,16 @@
padding: 6px;
border-radius: var(--radius-sm);
margin-right: 10px;
+}
+
+// Mark
+.bubble {
+ position: absolute;
+ top: 4px;
+ right: 4px;
+ width: 10px;
+ height: 10px;
+ border: 3px solid var(--primary);
+ border-radius: 50%;
+ background: var(--primary-bg);
}
\ No newline at end of file
diff --git a/frontend/app/sw.ts b/frontend/app/sw.ts
index c0b1fc82..9e8760e6 100644
--- a/frontend/app/sw.ts
+++ b/frontend/app/sw.ts
@@ -27,7 +27,7 @@ registerRoute(
statuses: [0, 200],
}),
new ExpirationPlugin({
- maxEntries: 500,
+ maxEntries: 5000,
maxAgeSeconds: 30 * 24 * 60 * 60, // 30 days
}),
],
diff --git a/frontend/bun.lock b/frontend/bun.lock
index 8e838254..b2502245 100644
--- a/frontend/bun.lock
+++ b/frontend/bun.lock
@@ -32,6 +32,7 @@
"fast-glob": "^3.3.3",
"fs-extra": "^11.3.5",
"katex": "^0.17.0",
+ "localforage": "^1.10.0",
"markdown-it": "^14.2.0",
"markdown-it-anchor": "^9.2.0",
"markdown-it-container": "^4.0.0",
@@ -4244,7 +4245,7 @@
"sha512-aTvMFUWkBmjzKtEQMDGGDNF8bkfpD5N1b/FCwt7A3wrU4t1o/e/85Wzkluh6JlODCjqVESYCkQCdTXqZ9G7VFg==",
],
- "bare-os": ["[email protected]", "", {}, "sha512-h530JsrkYi8518ZfR57GHaLoI5YzXkGGEV0Y+mf4KYPBn4OnNajiznwkDq7FgE+Vnmyss9Utnzi44y7sowiAXA=="],
+ "bare-os": ["[email protected]", "", {}, "sha512-fF4Q7QsyKVF5Rj0qvI8BgUNjqzC2JvQlpTaPLjVJVxYVUX5Zr9un+y3w1HmA4nNKdFmRBT8z/WmrjvXzXVerKQ=="],
"bare-path": [
@@ -4313,10 +4314,10 @@
"boolbase": ["[email protected]", "", {}, "sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww=="],
"brace-expansion": [
"",
{ "dependencies": { "balanced-match": "^4.0.2" } },
- "sha512-kLpxurY4Z4r9sgMsyG0Z9uzsBlgiU/EFKhj/h91/8yHu0edo7XuixOIH3VcJ8kkxs6/jPzoI6U9Vj3WqbMQ94g==",
+ "sha512-7oFy703dxfY3/NLxC1fh2SUCQ0H9rmAY+5EpDVfXjUTTs+HEwR2nYaqLv+GWcTsumwxPfiz6CzCNkwXwBUwqCA==",
],
"braces": [
@@ -4884,10 +4885,10 @@
],
"electron-to-chromium": [
"",
{},
- "sha512-W6d5AbuEoRayO447cqrg6lKJIlscgRnnxOZl/08kfV71BQDoEBC7Wwis68z87LjyK6f4kWyTaubuDbhHKrZkbA==",
+ "sha512-n9Wa6yB+vDsGuA8AKbl/0z7HbvWqt5jxIdvr1IUicd0ryPrk7/xzwqLv8D9AbbvZ6avVNtXYLTfmgFHkwkyelg==",
],
"emoji-regex": ["[email protected]", "", {}, "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A=="],
@@ -4996,7 +4997,7 @@
"es-errors": ["[email protected]", "", {}, "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw=="],
- "es-module-lexer": ["[email protected]", "", {}, "sha512-n27zTYMjYu1aj4MjCWzSP7G9r75utsaoc8m61weK+W8JMBGGQybd43GstCXZ3WNmSFtGT9wi59qQTW6mhTR5LQ=="],
+ "es-module-lexer": ["[email protected]", "", {}, "sha512-3lGxdTXCLfe1MYfTz1y2ksAAUM4NAOP6rPEjxGJVKO7TZ5+tvHCaQWGpC4Y3IXvW3ece0Cz1cIP4FWBxOnGCTQ=="],
"es-object-atoms": [
@@ -5485,7 +5486,7 @@
"sha512-gX8LrtNEI5hq8DVUfRQMbr5lpaS4nMIWV+7XEbXk2b8kiQIizgnlr12B4dA3ZEx3308ze0O4Q1R+cHts8kyUJg==",
],
- "fast-uri": ["[email protected]", "", {}, "sha512-rVjf7ArG3LTk+FS6Yw81V1DLuZl1bRbNrev6Tmd/9RaroeeRRJhAt7jg/6YFxbvAQXUCavSoZhPPj6oOx+5KjQ=="],
+ "fast-uri": ["[email protected]", "", {}, "sha512-i70LwGWUduXqzicKXWshooq+sWL1K3WUU5rKZNG/0i3a1OSoX3HqhH5WbWwTmqWfor4urUakGPiRQcleRZTwOg=="],
"fast-wrap-ansi": [
@@ -5921,6 +5922,8 @@
"sha512-6TDAlDPZxUFCv+fuOkIoXT/V/f3Qbq8e37p+YOiYrUv3v9cc3/6x78VdfPgFVaB9dZYeLUfKgHRebpkm/oP2VQ==",
],
+ "immediate": ["[email protected]", "", {}, "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ=="],
+
"immutable": ["[email protected]", "", {}, "sha512-TM5YqrGeTsVIPPpILzeqZ8D2Zc2TvNgSDi88zPF2a4cyqQdWV/wVWBDRDbNzzrLeRWScrFcOX9lW2iX6GOtUDw=="],
"import-fresh": [
@@ -6399,6 +6402,13 @@
"sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==",
],
+ "lie": [
+ "",
+ { "dependencies": { "immediate": "~3.0.5" } },
+ "sha512-RiNhHysUjhrDQntfYSfY4MU24coXXdEOgw9WGcKHNeEwffDYbF//u87M1EWaMGzuFoSbqW0C9C6lEEhDOAswfw==",
+ ],
+
"lilconfig": ["[email protected]", "", {}, "sha512-/vlFKAoH5Cgt3Ie+JLhRbwOsCQePABiU3tJ1egGvyQ+33R/vcwM2Zl2QR/LzjsBeItPt3oSVXapn+m4nQDvpzw=="],
"lines-and-columns": ["[email protected]", "", {}, "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg=="],
@@ -6453,6 +6463,13 @@
"sha512-++gUqRDEvcnN6Zhqrr+y/CkVEHhlrR96vZn3nZZPYzMcBUyBtTKzB9NadClFIsIVSsu+3i9tfk/erqy9kAmt7Q==",
],
+ "localforage": [
+ "",
+ { "dependencies": { "lie": "3.1.1" } },
+ "sha512-14/H1aX7hzBBmmh7sGPd+AOMkkIrHM3Z1PAyGgZigA1H1p5O5ANnMyWzvpAETtG68/dC4pC0ncy3+PPGzXZHPg==",
+ ],
+
"locate-path": [
"",
@@ -8783,7 +8800,7 @@
"universalify": ["[email protected]", "", {}, "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw=="],
"unplugin": [
"",
{
"dependencies": { "@jridgewell/remapping": "^2.3.5", "picomatch": "^4.0.4", "webpack-virtual-modules": "^0.6.2" },
@@ -8800,7 +8817,7 @@
},
"optionalPeers": ["@farmfe/core", "@rspack/core", "bun-types-no-globals", "esbuild", "rolldown", "rollup", "unloader", "vite", "webpack"],
},
- "sha512-6nGlT7EHsS+tTcTdAkYFqXIUwDrMJyJvHFNYGSr4x2/2ySIcV4f5e1RAJUeDyfOJPR8TF0auE8l+82PLhKjqsA==",
+ "sha512-qa66K+crbfyE6JK10GjvbJeRrOsuC/JpbnHctfyp/i4oBTxWOzJfRZyDiOk1PtErMFRu8JhsU/wPvOdBNWe5Rg==",
],
"unplugin-utils": [
diff --git a/frontend/nuxt.config.ts b/frontend/nuxt.config.ts
index 1ab35b33..b60e05b8 100644
--- a/frontend/nuxt.config.ts
+++ b/frontend/nuxt.config.ts
@@ -93,7 +93,7 @@ export default defineNuxtConfig({
ssr: false,
compatibilityDate: '2024-07-19',
devtools: { enabled: process.env.NODE_ENV !== 'production' },
-
+ spaLoadingTemplate: './splash-screen.html',
/**
************************ Imports & modules ************************
*/
diff --git a/frontend/package.json b/frontend/package.json
index 69af4ea0..0c6d8300 100644
--- a/frontend/package.json
+++ b/frontend/package.json
@@ -29,6 +29,7 @@
"fast-glob": "^3.3.3",
"fs-extra": "^11.3.5",
"katex": "^0.17.0",
+ "localforage": "^1.10.0",
"markdown-it": "^14.2.0",
"markdown-it-anchor": "^9.2.0",
"markdown-it-container": "^4.0.0",
diff --git a/frontend/public/app-icons/sparkle.svg b/frontend/public/app-icons/sparkle.svg
new file mode 100644
index 00000000..ed2a1ef9
--- /dev/null
+++ b/frontend/public/app-icons/sparkle.svg
@@ -0,0 +1 @@
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 -960 960 960"><path d="M720-440v-80h160v80H720Zm48 280-128-96 48-64 128 96-48 64Zm-80-480-48-64 128-96 48 64-128 96ZM200-200v-160h-40q-33 0-56.5-23.5T80-440v-80q0-33 23.5-56.5T160-600h160l200-120v480L320-360h-40v160h-80Zm240-182v-196l-98 58H160v80h182l98 58Zm120 36v-268q27 24 43.5 58.5T620-480q0 41-16.5 75.5T560-346ZM300-480Z"/></svg>
\ No newline at end of file