Add interface languages and improve themes and workspace controls for 0.1.36
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { t } from "$lib/i18n";
|
||||
import { tick } from "svelte";
|
||||
import type { OutlineItem } from "$lib/workspace/outline";
|
||||
import Icon from "$lib/ui/Icon.svelte";
|
||||
@@ -47,27 +48,27 @@
|
||||
</script>
|
||||
|
||||
<!-- svelte-ignore a11y_no_noninteractive_tabindex, a11y_no_noninteractive_element_interactions (The outline accepts focus for pane-local search shortcuts.) -->
|
||||
<section class="outline" aria-label="Outline" tabindex="0" bind:this={pane} onkeydown={keydown}>
|
||||
<section class="outline" aria-label={$t("Outline")} tabindex="0" bind:this={pane} onkeydown={keydown}>
|
||||
<div class="pane-label">
|
||||
<span>Outline</span>
|
||||
<IconButton icon="search" label="Find in outline (Ctrl+F)" active={searchOpen} onclick={() => void openSearch()} />
|
||||
<span>{$t("Outline")}</span>
|
||||
<IconButton icon="search" label={$t("Find in outline (Ctrl+F)")} active={searchOpen} onclick={() => void openSearch()} />
|
||||
</div>
|
||||
{#if searchOpen}
|
||||
<div class="rs-find-bar outline-search">
|
||||
<div class="rs-find-row">
|
||||
<div class="rs-find-field">
|
||||
<Icon icon="search" />
|
||||
<input bind:this={searchInput} bind:value={query} aria-label="Find in outline" placeholder="Find in outline" />
|
||||
<input bind:this={searchInput} bind:value={query} aria-label={$t("Find in outline")} placeholder={$t("Find in outline")} />
|
||||
</div>
|
||||
<IconButton icon="close" label="Close outline find (Escape)" onclick={closeSearch} />
|
||||
<IconButton icon="close" label={$t("Close outline find (Escape)")} onclick={closeSearch} />
|
||||
</div>
|
||||
<span class="match-count" role="status">{visibleItems.length} of {items.length} headings or symbols</span>
|
||||
<span class="match-count" role="status">{$t("{visible} of {total} headings or symbols", { visible: visibleItems.length, total: items.length })}</span>
|
||||
</div>
|
||||
{/if}
|
||||
{#if items.length === 0}
|
||||
<p class="placeholder">No headings or symbols in this file.</p>
|
||||
<p class="placeholder">{$t("No headings or symbols in this file.")}</p>
|
||||
{:else if visibleItems.length === 0}
|
||||
<p class="placeholder">No matching headings or symbols.</p>
|
||||
<p class="placeholder">{$t("No matching headings or symbols.")}</p>
|
||||
{:else}
|
||||
<ul>
|
||||
{#each visibleItems as item (item.line + item.text)}
|
||||
|
||||
Reference in New Issue
Block a user