From bc2fec302a9be6d358be32d1dbae3dc60e8a7106 Mon Sep 17 00:00:00 2001 From: Maxime GRANDCOLAS Date: Wed, 15 Jan 2025 13:06:50 +0100 Subject: [PATCH] [MS] Renamed favorites to pinned --- client/src/locales/en-US.json | 6 ++-- client/src/locales/fr-FR.json | 6 ++-- .../views/sidebar-menu/SidebarMenuPage.vue | 32 +++++++++++++++---- 3 files changed, 32 insertions(+), 12 deletions(-) diff --git a/client/src/locales/en-US.json b/client/src/locales/en-US.json index f704c7144da..a7f994398b7 100644 --- a/client/src/locales/en-US.json +++ b/client/src/locales/en-US.json @@ -417,8 +417,8 @@ "actionShare": "Sharing and roles", "actionDetails": "Details", "actionCopyLink": "Copy link", - "actionAddFavorite": "Add to favorites", - "actionRemoveFavorite": "Remove from favorites" + "actionAddFavorite": "Pin", + "actionRemoveFavorite": "Unpin" }, "CreateWorkspaceModal": { "pageTitle": "Create a new workspace", @@ -699,7 +699,7 @@ "SideMenu": { "workspaces": "Workspaces", "recentWorkspaces": "Recent workspaces", - "favorites": "Favorites", + "favorites": "Pinned", "noWorkspace": "No workspaces", "users": "Users", "storage": "Storage", diff --git a/client/src/locales/fr-FR.json b/client/src/locales/fr-FR.json index d5956ce56d3..1b35c4623de 100644 --- a/client/src/locales/fr-FR.json +++ b/client/src/locales/fr-FR.json @@ -417,8 +417,8 @@ "actionShare": "Partage et rôles", "actionDetails": "Détails", "actionCopyLink": "Copier le lien", - "actionAddFavorite": "Ajouter aux favoris", - "actionRemoveFavorite": "Retirer des favoris" + "actionAddFavorite": "Épingler", + "actionRemoveFavorite": "Désépingler" }, "CreateWorkspaceModal": { "pageTitle": "Créer un nouvel espace de travail", @@ -699,7 +699,7 @@ "SideMenu": { "workspaces": "Espaces de travail", "recentWorkspaces": "Espaces récents", - "favorites": "Favoris", + "favorites": "Épinglés", "noWorkspace": "Aucun espace de travail", "users": "Utilisateurs", "storage": "Stockage", diff --git a/client/src/views/sidebar-menu/SidebarMenuPage.vue b/client/src/views/sidebar-menu/SidebarMenuPage.vue index 85a64eebf5f..8fdfd236074 100644 --- a/client/src/views/sidebar-menu/SidebarMenuPage.vue +++ b/client/src/views/sidebar-menu/SidebarMenuPage.vue @@ -194,12 +194,6 @@ v-model:is-content-visible="workspacesMenuVisible" @update:is-content-visible="onWorkspacesMenuVisibilityChanged" > - - {{ $msTranslate('SideMenu.noWorkspace') }} - +
+ +
{ const isManagement = currentRouteIsOrganizationManagementRoute; +const currentWorkspace = computed(() => { + for (const wk of recentDocumentManager.getWorkspaces()) { + if (currentRouteIsWorkspaceRoute(wk.handle)) { + return wk; + } + } + return undefined; +}); + async function goToWorkspace(workspace: WorkspaceInfo): Promise { recentDocumentManager.addWorkspace(workspace); await recentDocumentManager.saveToStorage(storageManager); @@ -811,6 +827,10 @@ async function onRecentFilesMenuVisibilityChanged(visible: boolean): Promise