mirror of
https://github.com/bulwarkmail/webmail.git
synced 2026-10-31 16:13:15 +00:00
feat: hide the contacts directory when the server refuses it, and let users or admins turn it off #1457
This commit is contained in:
@@ -0,0 +1,90 @@
|
||||
import { act, fireEvent, render, screen } from '@testing-library/react';
|
||||
import { afterEach, describe, expect, it, vi } from 'vitest';
|
||||
import type { IJMAPClient } from '@/lib/jmap/client-interface';
|
||||
import type { DirectoryStatus } from '@/stores/contact-store';
|
||||
|
||||
// The Directory entry in the Contacts sidebar (#1457): it follows the user's
|
||||
// setting, and goes away when the server refuses to list its directory.
|
||||
|
||||
vi.mock('next/navigation', () => ({
|
||||
useRouter: () => ({ push: vi.fn(), back: vi.fn() }),
|
||||
useParams: () => ({ locale: 'en' }),
|
||||
usePathname: () => '/en/contacts',
|
||||
useSearchParams: () => new URLSearchParams(),
|
||||
}));
|
||||
vi.mock('@/components/contacts/contact-activity', () => ({ ContactActivity: () => null }));
|
||||
vi.mock('@/components/layout/navigation-rail', () => ({ NavigationRail: () => <nav data-testid="rail" /> }));
|
||||
vi.mock('@/components/layout/sidebar-apps-modal', () => ({ SidebarAppsModal: () => null }));
|
||||
vi.mock('@/components/layout/inline-app-view', () => ({ InlineAppView: () => null }));
|
||||
vi.mock('@/components/layout/mv-top-bar', () => ({ MvTopBar: () => null }));
|
||||
vi.mock('@/components/plugins/app-top-banner-slot', () => ({ AppTopBannerSlot: () => null }));
|
||||
vi.mock('@/hooks/use-sidebar-apps', () => ({
|
||||
useSidebarApps: () => ({
|
||||
showAppsModal: false, inlineApp: null, loadedApps: [], handleManageApps: vi.fn(),
|
||||
handleInlineApp: vi.fn(), closeInlineApp: vi.fn(), closeAppsModal: vi.fn(),
|
||||
}),
|
||||
}));
|
||||
|
||||
import { ContactsApp } from '../contacts-app';
|
||||
import { useAuthStore } from '@/stores/auth-store';
|
||||
import { useContactStore } from '@/stores/contact-store';
|
||||
import { useSettingsStore } from '@/stores/settings-store';
|
||||
import { presettableSetting } from '@/lib/admin/policy-settings';
|
||||
|
||||
const CLIENT = { supportsPrincipals: () => true } as unknown as IJMAPClient;
|
||||
|
||||
function renderContacts(directoryStatus: DirectoryStatus) {
|
||||
act(() => {
|
||||
useAuthStore.setState({ isAuthenticated: true, client: CLIENT, isLoading: false });
|
||||
useContactStore.setState({
|
||||
contacts: [],
|
||||
addressBooks: [],
|
||||
selectedContactId: null,
|
||||
selectedContactIds: new Set(),
|
||||
searchQuery: '',
|
||||
supportsSync: false,
|
||||
contactsLoaded: true,
|
||||
directoryPrincipals: [],
|
||||
directoryLoaded: true,
|
||||
directoryStatus,
|
||||
});
|
||||
});
|
||||
return render(<ContactsApp />);
|
||||
}
|
||||
|
||||
const entry = () => screen.queryByTestId('contacts-directory-entry');
|
||||
|
||||
afterEach(() => {
|
||||
useSettingsStore.setState({ showContactsDirectory: true });
|
||||
});
|
||||
|
||||
describe('Directory entry in Contacts', () => {
|
||||
it('shows when the server lists its directory', () => {
|
||||
renderContacts('ready');
|
||||
expect(entry()).not.toBeNull();
|
||||
});
|
||||
|
||||
it('is hidden when the server refuses to list the directory', () => {
|
||||
renderContacts('forbidden');
|
||||
expect(entry()).toBeNull();
|
||||
});
|
||||
|
||||
it('is hidden when the user turned it off', () => {
|
||||
useSettingsStore.setState({ showContactsDirectory: false });
|
||||
renderContacts('ready');
|
||||
expect(entry()).toBeNull();
|
||||
});
|
||||
|
||||
it('leaves the directory view when the entry goes away', () => {
|
||||
renderContacts('ready');
|
||||
fireEvent.click(entry()!);
|
||||
expect(screen.getByRole('button', { name: 'select_page' })).toBeInTheDocument();
|
||||
act(() => { useContactStore.setState({ directoryStatus: 'forbidden' }); });
|
||||
expect(entry()).toBeNull();
|
||||
expect(screen.queryByRole('button', { name: 'select_page' })).toBeNull();
|
||||
});
|
||||
|
||||
it('can be preset and locked by the admin policy', () => {
|
||||
expect(presettableSetting('showContactsDirectory')).toMatchObject({ type: 'boolean', defaultValue: true });
|
||||
});
|
||||
});
|
||||
@@ -24,6 +24,7 @@ import { PromptDialog } from "@/components/ui/prompt-dialog";
|
||||
import { exportContacts } from "@/components/contacts/contact-export";
|
||||
import { AppTopBannerSlot } from "@/components/plugins/app-top-banner-slot";
|
||||
import { useContactStore, getContactDisplayName, getContactPrimaryEmail, type DirectoryEntry } from "@/stores/contact-store";
|
||||
import { useSettingsStore } from "@/stores/settings-store";
|
||||
import { inlineContactMedia, type ContactSaveOptions } from "@/lib/contact-media";
|
||||
import { getContactPhotoClient } from "@/hooks/use-contact-photo";
|
||||
import { savePendingMailto } from "@/lib/protocol-handlers/session";
|
||||
@@ -155,7 +156,11 @@ function ContactsAppContent({ linkSegments: routeSegments }: ContactsAppProps =
|
||||
const [directorySelection, setDirectorySelection] = useState<Set<string>>(() => new Set());
|
||||
const [openDirectoryKey, setOpenDirectoryKey] = useState<string | null>(null);
|
||||
const directoryPrincipals = useContactStore((s) => s.directoryPrincipals);
|
||||
const showDirectory = !!client?.supportsPrincipals();
|
||||
const directoryStatus = useContactStore((s) => s.directoryStatus);
|
||||
const showContactsDirectory = useSettingsStore((s) => s.showContactsDirectory);
|
||||
// Hidden when the user turned it off, and when the server refuses to list
|
||||
// its directory (Stalwart 1.0 for normal users): there's nothing to browse.
|
||||
const showDirectory = !!client?.supportsPrincipals() && showContactsDirectory && directoryStatus !== "forbidden";
|
||||
const hasFetched = useRef(false);
|
||||
const { dialogProps: confirmDialogProps, confirm: confirmDialog } = useConfirmDialog();
|
||||
const isMobile = useIsMobile();
|
||||
@@ -460,6 +465,17 @@ function ContactsAppContent({ linkSegments: routeSegments }: ContactsAppProps =
|
||||
return books.size === 1 ? [...books][0] : null;
|
||||
}, [movingContactIds, contacts]);
|
||||
|
||||
// The directory went away while open (turned off, or the server refused
|
||||
// to list it): back to all contacts.
|
||||
useEffect(() => {
|
||||
if (!showDirectory && activeCategory === "directory") {
|
||||
setActiveCategory("all");
|
||||
setDirectorySelection(new Set());
|
||||
setOpenDirectoryKey(null);
|
||||
setView("list");
|
||||
}
|
||||
}, [showDirectory, activeCategory]);
|
||||
|
||||
// Deleting a category only takes a label off contacts: no question, an Undo (R3).
|
||||
const deleteCategory = useDeleteCategory();
|
||||
const handleDeleteKeyword = useCallback(async (keyword: string) => {
|
||||
|
||||
@@ -61,7 +61,7 @@ const pages = {
|
||||
const OVERRIDES: Record<string, () => unknown> = {
|
||||
getAccountId: () => 'acc', getSieveAccountId: () => 'acc', getUsername: () => 'user@example.com',
|
||||
getSharedAccounts: () => [], getSieveAccounts: () => [], getSieveCapabilities: () => null,
|
||||
hasAccountCapability: () => false, supportsCalendars: () => true, supportsFiles: () => true, hasDelayedSend: () => true,
|
||||
hasAccountCapability: () => false, supportsCalendars: () => true, supportsPrincipals: () => true, supportsFiles: () => true, hasDelayedSend: () => true,
|
||||
// Sharing and Recover deleted items read these on open.
|
||||
getShareTargets: async () => ({ targets: [], failed: [] }), listPrincipals: async () => ({ principals: [], status: 'ok' }),
|
||||
getPrincipals: async () => [], listArchivedEmails: async () => ({ items: [], nextPosition: null }),
|
||||
|
||||
@@ -10,6 +10,7 @@ import { exportContacts, useContactExportBusy } from "@/components/contacts/cont
|
||||
import { useContactStore } from "@/stores/contact-store";
|
||||
import { useAuthStore } from "@/stores/auth-store";
|
||||
import { useSettingsStore } from "@/stores/settings-store";
|
||||
import { usePolicyStore } from "@/stores/policy-store";
|
||||
import { toast } from "@/stores/toast-store";
|
||||
|
||||
export function ContactsSettings() {
|
||||
@@ -23,6 +24,9 @@ export function ContactsSettings() {
|
||||
} = useContactStore();
|
||||
const groupContactsByLetter = useSettingsStore((s) => s.groupContactsByLetter);
|
||||
const sortContactsByLastName = useSettingsStore((s) => s.sortContactsByLastName);
|
||||
const showContactsDirectory = useSettingsStore((s) => s.showContactsDirectory);
|
||||
const directoryLocked = usePolicyStore((s) => s.isSettingLocked("showContactsDirectory"));
|
||||
const directoryHidden = usePolicyStore((s) => s.isSettingHidden("showContactsDirectory"));
|
||||
const updateSetting = useSettingsStore((s) => s.updateSetting);
|
||||
const [showImport, setShowImport] = useState(false);
|
||||
const exporting = useContactExportBusy();
|
||||
@@ -80,6 +84,19 @@ export function ContactsSettings() {
|
||||
/>
|
||||
</SettingItem>
|
||||
|
||||
{!!client?.supportsPrincipals() && !directoryHidden && (
|
||||
<SettingItem
|
||||
label={tSettings("show_directory_label")}
|
||||
description={tSettings("show_directory_description")}
|
||||
locked={directoryLocked}
|
||||
>
|
||||
<ToggleSwitch
|
||||
checked={showContactsDirectory}
|
||||
onChange={(checked) => updateSetting("showContactsDirectory", checked)}
|
||||
/>
|
||||
</SettingItem>
|
||||
)}
|
||||
|
||||
<SettingItem
|
||||
label={tSettings("import_label")}
|
||||
description={tSettings("import_description")}
|
||||
|
||||
@@ -77,6 +77,15 @@ export const RESTRICTION_KEYS: readonly RestrictionKeyDef[] = [
|
||||
{ key: 'emailNotificationsEnabled', label: 'Email Notifications', category: 'Notifications', type: 'boolean', page: 'policy', defaultValue: true },
|
||||
{ key: 'calendarNotificationsEnabled', label: 'Calendar Notifications', category: 'Notifications', type: 'boolean', page: 'policy', defaultValue: true },
|
||||
{ key: 'pushNotifyInboxOnly', label: 'Inbox-only Push Notifications', category: 'Notifications', type: 'boolean', page: 'policy', defaultValue: false },
|
||||
{
|
||||
key: 'showContactsDirectory',
|
||||
label: 'Directory in Contacts',
|
||||
description: 'Off hides the Directory entry that lists the accounts and groups on the mail server. Recipient suggestions, sharing and free/busy still use the directory.',
|
||||
category: 'Contacts',
|
||||
type: 'boolean',
|
||||
page: 'policy',
|
||||
defaultValue: true,
|
||||
},
|
||||
{ key: 'debugMode', label: 'Debug Mode', category: 'Advanced', type: 'boolean', page: 'policy', defaultValue: false },
|
||||
{
|
||||
key: 'signature',
|
||||
|
||||
@@ -326,6 +326,7 @@ export const tabSearchEntries: Record<Tab, SettingsSearchEntry[]> = {
|
||||
contacts: [
|
||||
{ label: 'settings.contacts.group_by_letter_label' },
|
||||
{ label: 'settings.contacts.sort_by_last_name_label' },
|
||||
{ label: 'settings.contacts.show_directory_label' },
|
||||
{ label: 'settings.contacts.import_label' },
|
||||
{ label: 'settings.contacts.export_label' },
|
||||
{ label: 'settings.contacts.manage_title' },
|
||||
|
||||
@@ -2579,6 +2579,8 @@
|
||||
"group_by_letter_label": "التجميع حسب الحرف الأول",
|
||||
"sort_by_last_name_label": "الترتيب حسب اسم العائلة",
|
||||
"sort_by_last_name_description": "ترتيب قائمة جهات الاتصال حسب اسم العائلة بحيث يظهر أفراد العائلة معًا",
|
||||
"show_directory_label": "إظهار الدليل",
|
||||
"show_directory_description": "عرض الحسابات والمجموعات الموجودة على خادم البريد تحت \"الدليل\" في جهات الاتصال",
|
||||
"group_by_letter_description": "إظهار عناوين أقسام أبجدية في قائمة جهات الاتصال",
|
||||
"import_label": "استيراد جهات الاتصال",
|
||||
"import_description": "استيراد جهات الاتصال من ملف vCard (.vcf)",
|
||||
|
||||
@@ -2579,6 +2579,8 @@
|
||||
"group_by_letter_label": "Agrupa per lletra inicial",
|
||||
"sort_by_last_name_label": "Ordena per cognom",
|
||||
"sort_by_last_name_description": "Ordena la llista de contactes per cognom perquè els membres d'una família apareguin junts",
|
||||
"show_directory_label": "Mostra el directori",
|
||||
"show_directory_description": "Llista els comptes i grups del servidor de correu a \"Directori\" dins de Contactes",
|
||||
"group_by_letter_description": "Mostra capçaleres de secció alfabètiques a la llista de contactes",
|
||||
"import_label": "Importa contactes",
|
||||
"import_description": "Importeu contactes des d'un fitxer vCard (.vcf)",
|
||||
|
||||
@@ -2572,6 +2572,8 @@
|
||||
"group_by_letter_label": "Seskupit podle prvního písmena",
|
||||
"sort_by_last_name_label": "Řadit podle příjmení",
|
||||
"sort_by_last_name_description": "Seřadit seznam kontaktů podle příjmení, aby členové rodiny byli pohromadě",
|
||||
"show_directory_label": "Zobrazit adresář organizace",
|
||||
"show_directory_description": "Zobrazit účty a skupiny na poštovním serveru v Kontaktech pod položkou „Adresář organizace“",
|
||||
"group_by_letter_description": "Zobrazit záhlaví sekcí podle abecedy v seznamu kontaktů",
|
||||
"import_label": "Importovat kontakty",
|
||||
"import_description": "Importovat kontakty ze souboru vCard (.vcf)",
|
||||
|
||||
@@ -2575,6 +2575,8 @@
|
||||
"group_by_letter_label": "Gruppér efter første bogstav",
|
||||
"sort_by_last_name_label": "Sortér efter efternavn",
|
||||
"sort_by_last_name_description": "Sortér kontaktlisten efter efternavn, så familiemedlemmer står samlet",
|
||||
"show_directory_label": "Vis adressefortegnelsen",
|
||||
"show_directory_description": "Vis kontiene og grupperne på mailserveren under \"Adressefortegnelse\" i Kontakter",
|
||||
"group_by_letter_description": "Vis alfabetiske sektionsoverskrifter i kontaktlisten",
|
||||
"import_label": "Importér kontakter",
|
||||
"import_description": "Importér kontakter fra en vCard-fil (.vcf)",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Alphabetische Abschnittsüberschriften in der Kontaktliste anzeigen",
|
||||
"group_by_letter_label": "Nach Anfangsbuchstaben gruppieren",
|
||||
"sort_by_last_name_label": "Nach Nachname sortieren",
|
||||
"sort_by_last_name_description": "Kontaktliste nach Nachnamen ordnen, damit Familienmitglieder zusammenstehen"
|
||||
"sort_by_last_name_description": "Kontaktliste nach Nachnamen ordnen, damit Familienmitglieder zusammenstehen",
|
||||
"show_directory_label": "Verzeichnis anzeigen",
|
||||
"show_directory_description": "Zeigt die Konten und Gruppen auf dem Mailserver unter „Verzeichnis“ in den Kontakten"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Kalender löschen?",
|
||||
|
||||
@@ -2580,6 +2580,8 @@
|
||||
"group_by_letter_description": "Show alphabetical section headers in the contact list",
|
||||
"sort_by_last_name_label": "Sort by last name",
|
||||
"sort_by_last_name_description": "Order the contact list by surname so family members appear together",
|
||||
"show_directory_label": "Show the directory",
|
||||
"show_directory_description": "List the accounts and groups on your mail server under Directory in Contacts",
|
||||
"import_label": "Import contacts",
|
||||
"import_description": "Import contacts from a vCard (.vcf) file",
|
||||
"export_label": "Export contacts",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Mostrar encabezados alfabéticos en la lista de contactos",
|
||||
"group_by_letter_label": "Agrupar por primera letra",
|
||||
"sort_by_last_name_label": "Ordenar por apellido",
|
||||
"sort_by_last_name_description": "Ordenar la lista de contactos por apellido para que los miembros de una familia aparezcan juntos"
|
||||
"sort_by_last_name_description": "Ordenar la lista de contactos por apellido para que los miembros de una familia aparezcan juntos",
|
||||
"show_directory_label": "Mostrar el directorio",
|
||||
"show_directory_description": "Muestra las cuentas y los grupos del servidor de correo en \"Directorio\" dentro de Contactos"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "¿Eliminar el calendario?",
|
||||
|
||||
@@ -2580,6 +2580,8 @@
|
||||
"group_by_letter_description": "Näita kontaktide loendis tähestikulisi jaotisepealkirju",
|
||||
"sort_by_last_name_label": "Sordi perekonnanime järgi",
|
||||
"sort_by_last_name_description": "Järjesta kontaktide loend perekonnanime järgi, et pereliikmed oleksid koos",
|
||||
"show_directory_label": "Näita kataloogi",
|
||||
"show_directory_description": "Näita meiliserveri kontosid ja rühmi Kontaktide all jaotises „Kataloog“",
|
||||
"import_label": "Impordi kontaktid",
|
||||
"import_description": "Impordi kontaktid vCard (.vcf) failist",
|
||||
"export_label": "Ekspordi kontaktid",
|
||||
|
||||
@@ -2579,6 +2579,8 @@
|
||||
"group_by_letter_label": "گروهبندی بر اساس حرف اول",
|
||||
"sort_by_last_name_label": "مرتبسازی بر اساس نام خانوادگی",
|
||||
"sort_by_last_name_description": "لیست مخاطبین را بر اساس نام خانوادگی مرتب کنید تا اعضای خانواده کنار هم نمایش داده شوند",
|
||||
"show_directory_label": "نمایش فهرست سازمانی",
|
||||
"show_directory_description": "حسابها و گروههای سرور ایمیل را زیر «فهرست سازمانی» در مخاطبین نشان میدهد",
|
||||
"group_by_letter_description": "نمایش هدرهای الفبایی در لیست مخاطبین",
|
||||
"import_label": "وارد کردن مخاطبین",
|
||||
"import_description": "وارد کردن مخاطبین از فایل vCard (.vcf)",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Afficher des en-têtes alphabétiques dans la liste de contacts",
|
||||
"group_by_letter_label": "Grouper par première lettre",
|
||||
"sort_by_last_name_label": "Trier par nom de famille",
|
||||
"sort_by_last_name_description": "Classer la liste des contacts par nom de famille pour regrouper les membres d'une même famille"
|
||||
"sort_by_last_name_description": "Classer la liste des contacts par nom de famille pour regrouper les membres d'une même famille",
|
||||
"show_directory_label": "Afficher l’annuaire",
|
||||
"show_directory_description": "Affiche les comptes et groupes du serveur de messagerie sous « Annuaire » dans Contacts"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Supprimer le calendrier ?",
|
||||
|
||||
@@ -2548,6 +2548,8 @@
|
||||
"group_by_letter_label": "קבוצה לפי אות ראשונה",
|
||||
"sort_by_last_name_label": "מיון לפי שם משפחה",
|
||||
"sort_by_last_name_description": "סידור רשימת אנשי הקשר לפי שם משפחה כך שבני אותה משפחה יופיעו יחד",
|
||||
"show_directory_label": "הצג את הספרייה",
|
||||
"show_directory_description": "הצגת החשבונות והקבוצות בשרת הדואר תחת \"ספרייה\" באנשי הקשר",
|
||||
"group_by_letter_description": "הצג כותרות חלקים אלפביתיים ברשימת אנשי הקשר"
|
||||
},
|
||||
"calendar_management": {
|
||||
|
||||
@@ -2575,6 +2575,8 @@
|
||||
"group_by_letter_label": "Csoportosítás kezdőbetű szerint",
|
||||
"sort_by_last_name_label": "Rendezés vezetéknév szerint",
|
||||
"sort_by_last_name_description": "A névjegylista vezetéknév szerinti rendezése, hogy a családtagok egymás mellett legyenek",
|
||||
"show_directory_label": "Címtár megjelenítése",
|
||||
"show_directory_description": "A levelezőszerver fiókjainak és csoportjainak megjelenítése a Névjegyek „Címtár” részében",
|
||||
"group_by_letter_description": "ABC sorrendű fejléc mutatása a névjegy listában",
|
||||
"import_label": "Névjegyek importálása",
|
||||
"import_description": "Névjegyek importálása vCard (.vcf) fájlból",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Mostra intestazioni alfabetiche nell'elenco dei contatti",
|
||||
"group_by_letter_label": "Raggruppa per prima lettera",
|
||||
"sort_by_last_name_label": "Ordina per cognome",
|
||||
"sort_by_last_name_description": "Ordina l'elenco dei contatti per cognome così i familiari compaiono insieme"
|
||||
"sort_by_last_name_description": "Ordina l'elenco dei contatti per cognome così i familiari compaiono insieme",
|
||||
"show_directory_label": "Mostra la rubrica aziendale",
|
||||
"show_directory_description": "Elenca gli account e i gruppi del server di posta sotto \"Rubrica aziendale\" in Contatti"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Eliminare il calendario?",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "連絡先リストにアルファベット順のセクション見出しを表示",
|
||||
"group_by_letter_label": "頭文字でグループ化",
|
||||
"sort_by_last_name_label": "姓で並べ替え",
|
||||
"sort_by_last_name_description": "家族が並んで表示されるように、連絡先一覧を姓の順に並べ替えます"
|
||||
"sort_by_last_name_description": "家族が並んで表示されるように、連絡先一覧を姓の順に並べ替えます",
|
||||
"show_directory_label": "ディレクトリを表示",
|
||||
"show_directory_description": "連絡先の「ディレクトリ」にメールサーバーのアカウントとグループを表示します"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "カレンダーを削除しますか?",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "연락처 목록에 알파벳순 섹션 헤더 표시",
|
||||
"group_by_letter_label": "첫 글자로 그룹화",
|
||||
"sort_by_last_name_label": "성으로 정렬",
|
||||
"sort_by_last_name_description": "가족 구성원이 함께 표시되도록 연락처 목록을 성 기준으로 정렬합니다"
|
||||
"sort_by_last_name_description": "가족 구성원이 함께 표시되도록 연락처 목록을 성 기준으로 정렬합니다",
|
||||
"show_directory_label": "디렉터리 표시",
|
||||
"show_directory_description": "연락처의 \"디렉터리\"에 메일 서버의 계정과 그룹을 표시합니다"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "캘린더를 삭제할까요?",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Rādīt alfabētiskos sadaļu virsrakstus kontaktu sarakstā",
|
||||
"group_by_letter_label": "Grupēt pēc pirmā burta",
|
||||
"sort_by_last_name_label": "Kārtot pēc uzvārda",
|
||||
"sort_by_last_name_description": "Kārtot kontaktu sarakstu pēc uzvārda, lai ģimenes locekļi būtu kopā"
|
||||
"sort_by_last_name_description": "Kārtot kontaktu sarakstu pēc uzvārda, lai ģimenes locekļi būtu kopā",
|
||||
"show_directory_label": "Rādīt katalogu",
|
||||
"show_directory_description": "Rādīt pasta servera kontus un grupas sadaļā “Katalogs” kontaktos"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Dzēst kalendāru?",
|
||||
|
||||
@@ -2579,6 +2579,8 @@
|
||||
"group_by_letter_label": "Эхний үсгээр бүлэглэх",
|
||||
"sort_by_last_name_label": "Овгоор эрэмбэлэх",
|
||||
"sort_by_last_name_description": "Гэр бүлийн гишүүд хамт харагдахаар харилцах хүмүүсийн жагсаалтыг овгоор эрэмбэлэх",
|
||||
"show_directory_label": "Лавлахыг харуулах",
|
||||
"show_directory_description": "Харилцагчид хэсгийн \"Лавлах\" дор шуудангийн серверийн бүртгэл, бүлгүүдийг харуулна",
|
||||
"group_by_letter_description": "Харилцах хүмүүсийн жагсаалтад цагаан толгойн үсгийн дарааллаар хэсгийн толгойг харуулах",
|
||||
"import_label": "Харилцагчдыг импортлох",
|
||||
"import_description": "vCard (.vcf) файлаас харилцагчдыг импортлох",
|
||||
|
||||
@@ -2579,6 +2579,8 @@
|
||||
"group_by_letter_label": "Grupper etter første bokstav",
|
||||
"sort_by_last_name_label": "Sorter etter etternavn",
|
||||
"sort_by_last_name_description": "Sorter kontaktlisten etter etternavn slik at familiemedlemmer står samlet",
|
||||
"show_directory_label": "Vis katalogen",
|
||||
"show_directory_description": "Vis kontoene og gruppene på e-postserveren under «Katalog» i Kontakter",
|
||||
"group_by_letter_description": "Vis alfabetiske overskrifter i kontaktlisten",
|
||||
"import_label": "Importer kontakter",
|
||||
"import_description": "Importer kontakter fra en vCard-fil (.vcf).",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Toon alfabetische sectiekoppen in de contactenlijst",
|
||||
"group_by_letter_label": "Groeperen op eerste letter",
|
||||
"sort_by_last_name_label": "Sorteren op achternaam",
|
||||
"sort_by_last_name_description": "Sorteer de contactenlijst op achternaam zodat gezinsleden bij elkaar staan"
|
||||
"sort_by_last_name_description": "Sorteer de contactenlijst op achternaam zodat gezinsleden bij elkaar staan",
|
||||
"show_directory_label": "Adresboek van de organisatie tonen",
|
||||
"show_directory_description": "Toon de accounts en groepen op de mailserver onder \"Adresboek van de organisatie\" in Contacten"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Agenda verwijderen?",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Pokaż alfabetyczne nagłówki sekcji na liście kontaktów",
|
||||
"group_by_letter_label": "Grupuj według pierwszej litery",
|
||||
"sort_by_last_name_label": "Sortuj według nazwiska",
|
||||
"sort_by_last_name_description": "Uporządkuj listę kontaktów według nazwiska, aby członkowie rodziny byli obok siebie"
|
||||
"sort_by_last_name_description": "Uporządkuj listę kontaktów według nazwiska, aby członkowie rodziny byli obok siebie",
|
||||
"show_directory_label": "Pokaż katalog",
|
||||
"show_directory_description": "Wyświetla konta i grupy z serwera poczty w sekcji „Katalog” w Kontaktach"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Usunąć kalendarz?",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Mostrar cabeçalhos de seção alfabéticos na lista de contatos",
|
||||
"group_by_letter_label": "Agrupar pela primeira letra",
|
||||
"sort_by_last_name_label": "Ordenar por sobrenome",
|
||||
"sort_by_last_name_description": "Ordenar a lista de contatos por sobrenome para que os membros da família apareçam juntos"
|
||||
"sort_by_last_name_description": "Ordenar a lista de contatos por sobrenome para que os membros da família apareçam juntos",
|
||||
"show_directory_label": "Mostrar o diretório",
|
||||
"show_directory_description": "Lista as contas e os grupos do servidor de e-mail em \"Diretório\" nos Contatos"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Eliminar o calendário?",
|
||||
|
||||
@@ -2579,6 +2579,8 @@
|
||||
"group_by_letter_label": "Grupați după prima literă",
|
||||
"sort_by_last_name_label": "Sortare după nume de familie",
|
||||
"sort_by_last_name_description": "Ordonați lista de contacte după numele de familie, astfel încât membrii familiei să apară împreună",
|
||||
"show_directory_label": "Afișează directorul",
|
||||
"show_directory_description": "Afișează conturile și grupurile de pe serverul de e-mail la „Director” în Contacte",
|
||||
"group_by_letter_description": "Afișați titlurile secțiunilor în ordine alfabetică în lista de contacte",
|
||||
"import_label": "Importați contactele",
|
||||
"import_description": "Importați contactele dintr-un fișier „vCard” (.vcf)",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Показывать алфавитные заголовки разделов в списке контактов",
|
||||
"group_by_letter_label": "Группировать по первой букве",
|
||||
"sort_by_last_name_label": "Сортировать по фамилии",
|
||||
"sort_by_last_name_description": "Упорядочить список контактов по фамилии, чтобы члены семьи шли подряд"
|
||||
"sort_by_last_name_description": "Упорядочить список контактов по фамилии, чтобы члены семьи шли подряд",
|
||||
"show_directory_label": "Показывать справочник",
|
||||
"show_directory_description": "Показывать учётные записи и группы почтового сервера в разделе «Справочник» в Контактах"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Удалить календарь?",
|
||||
|
||||
@@ -2579,6 +2579,8 @@
|
||||
"group_by_letter_label": "Zoskupiť podľa prvého písmena",
|
||||
"sort_by_last_name_label": "Zoradiť podľa priezviska",
|
||||
"sort_by_last_name_description": "Zoradiť zoznam kontaktov podľa priezviska, aby členovia rodiny boli pri sebe",
|
||||
"show_directory_label": "Zobraziť adresár organizácie",
|
||||
"show_directory_description": "Zobraziť účty a skupiny na poštovom serveri v Kontaktoch pod položkou „Adresár organizácie“",
|
||||
"group_by_letter_description": "Zobraziť abecedné záhlavia sekcií v zozname kontaktov",
|
||||
"import_label": "Importovať kontakty",
|
||||
"import_description": "Importovať kontakty zo súboru vCard (.vcf)",
|
||||
|
||||
@@ -5016,6 +5016,8 @@
|
||||
"group_by_letter_description": "แสดงส่วนหัวตามตัวอักษรในรายการผู้ติดต่อ",
|
||||
"sort_by_last_name_label": "เรียงลำดับตามนามสกุล",
|
||||
"sort_by_last_name_description": "เรียงลำดับรายชื่อผู้ติดต่อตามนามสกุลเพื่อให้บุคคลในครอบครัวเดียวกันอยู่ด้วยกัน",
|
||||
"show_directory_label": "แสดงไดเรกทอรีกลาง",
|
||||
"show_directory_description": "แสดงบัญชีและกลุ่มบนเซิร์ฟเวอร์อีเมลใต้ \"ไดเรกทอรีกลาง\" ในรายชื่อติดต่อ",
|
||||
"import_label": "นำเข้าผู้ติดต่อ",
|
||||
"import_description": "นำเข้าผู้ติดต่อจากไฟล์ vCard (.vcf)",
|
||||
"export_label": "ส่งออกผู้ติดต่อ",
|
||||
|
||||
@@ -2572,6 +2572,8 @@
|
||||
"group_by_letter_label": "İlk harfe göre grupla",
|
||||
"sort_by_last_name_label": "Soyada göre sırala",
|
||||
"sort_by_last_name_description": "Aile üyeleri bir arada görünsün diye kişi listesini soyada göre sıralar",
|
||||
"show_directory_label": "Dizini göster",
|
||||
"show_directory_description": "Posta sunucusundaki hesapları ve grupları Kişiler altında \"Dizin\" bölümünde listeler",
|
||||
"group_by_letter_description": "Kişi listesinde alfabetik bölüm başlıkları göster",
|
||||
"import_label": "Kişileri İçe Aktar",
|
||||
"import_description": "Kişileri bir vCard (.vcf) dosyasından içe aktarın",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "Показувати алфавітні заголовки розділів у списку контактів",
|
||||
"group_by_letter_label": "Групувати за першою літерою",
|
||||
"sort_by_last_name_label": "Сортувати за прізвищем",
|
||||
"sort_by_last_name_description": "Упорядкувати список контактів за прізвищем, щоб члени родини були поруч"
|
||||
"sort_by_last_name_description": "Упорядкувати список контактів за прізвищем, щоб члени родини були поруч",
|
||||
"show_directory_label": "Показувати довідник",
|
||||
"show_directory_description": "Показувати облікові записи та групи поштового сервера в розділі «Довідник» у Контактах"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "Видалити календар?",
|
||||
|
||||
@@ -2579,6 +2579,8 @@
|
||||
"group_by_letter_label": "依首字分組",
|
||||
"sort_by_last_name_label": "依姓氏排序",
|
||||
"sort_by_last_name_description": "依姓氏排列聯絡人清單,讓家庭成員顯示在一起",
|
||||
"show_directory_label": "顯示通訊錄目錄",
|
||||
"show_directory_description": "在聯絡人的「通訊錄目錄」中列出郵件伺服器上的帳號與群組",
|
||||
"group_by_letter_description": "在聯絡人清單中顯示依字母排列的分節標題",
|
||||
"import_label": "匯入聯絡人",
|
||||
"import_description": "從 vCard(.vcf)檔案匯入聯絡人",
|
||||
|
||||
@@ -2582,7 +2582,9 @@
|
||||
"group_by_letter_description": "在联系人列表中显示按字母顺序排列的分节标题",
|
||||
"group_by_letter_label": "按首字母分组",
|
||||
"sort_by_last_name_label": "按姓氏排序",
|
||||
"sort_by_last_name_description": "按姓氏排列联系人列表,使家庭成员显示在一起"
|
||||
"sort_by_last_name_description": "按姓氏排列联系人列表,使家庭成员显示在一起",
|
||||
"show_directory_label": "显示通讯录目录",
|
||||
"show_directory_description": "在联系人的“通讯录目录”中列出邮件服务器上的账户和群组"
|
||||
},
|
||||
"calendar_management": {
|
||||
"delete_title": "删除日历?",
|
||||
|
||||
@@ -633,6 +633,9 @@ interface SettingsState extends AccessibilitySettings {
|
||||
// Sort (and group) the contact list by surname instead of given name so
|
||||
// family members sit together (#963).
|
||||
sortContactsByLastName: boolean;
|
||||
// The Directory entry in the Contacts sidebar (#1457). Autocomplete, the
|
||||
// share dialog and free/busy use the directory either way.
|
||||
showContactsDirectory: boolean;
|
||||
|
||||
// Files: view, sort and icons (Settings > Files)
|
||||
filesSettings: FilesSettings;
|
||||
@@ -939,6 +942,7 @@ const DEFAULT_SETTINGS = {
|
||||
// Contacts Display
|
||||
groupContactsByLetter: true,
|
||||
sortContactsByLastName: false,
|
||||
showContactsDirectory: true,
|
||||
|
||||
// Files
|
||||
filesSettings: DEFAULT_FILES_SETTINGS,
|
||||
@@ -1349,6 +1353,7 @@ export const useSettingsStore = create<SettingsState>()(
|
||||
sharedCalendarColors: state.sharedCalendarColors,
|
||||
groupContactsByLetter: state.groupContactsByLetter,
|
||||
sortContactsByLastName: state.sortContactsByLastName,
|
||||
showContactsDirectory: state.showContactsDirectory,
|
||||
filesSettings: state.filesSettings,
|
||||
expandedFilterView: state.expandedFilterView,
|
||||
showTimeInMonthView: state.showTimeInMonthView,
|
||||
|
||||
Reference in New Issue
Block a user