mirror of
https://github.com/zadam/trilium.git
synced 2025-11-28 19:44:24 +01:00
chore(collections/list): use translations for expand depth
This commit is contained in:
parent
45d2e1f5e2
commit
c65b03db41
@ -767,6 +767,9 @@
|
||||
"expand_all_children": "Expand all children",
|
||||
"collapse": "Collapse",
|
||||
"expand": "Expand",
|
||||
"expand_first_level": "Expand direct children",
|
||||
"expand_nth_level": "Expand {{depth}} levels",
|
||||
"expand_all_levels": "Expand all levels",
|
||||
"book_properties": "Collection Properties",
|
||||
"invalid_view_type": "Invalid view type '{{type}}'",
|
||||
"calendar": "Calendar",
|
||||
|
||||
@ -194,13 +194,13 @@ function ListExpandDepth(context: { note: FNote, parentComponent: Component }) {
|
||||
|
||||
return (
|
||||
<>
|
||||
<ListExpandDepthButton label="Expand 1 level" depth={1} {...context} checked={currentDepth === ""} />
|
||||
<ListExpandDepthButton label={t("book_properties.expand_first_level")} depth={1} {...context} checked={currentDepth === ""} />
|
||||
<FormDropdownDivider />
|
||||
{Array.from({ length: 4 }, (_, i) => i + 2).map(depth => [
|
||||
<ListExpandDepthButton label={`Expand ${depth} levels`} depth={depth} {...context} checked={!!currentDepth && parseInt(currentDepth, 10) === depth} />
|
||||
<ListExpandDepthButton label={t("book_properties.expand_nth_level", { depth })} depth={depth} {...context} checked={!!currentDepth && parseInt(currentDepth, 10) === depth} />
|
||||
])}
|
||||
<FormDropdownDivider />
|
||||
<ListExpandDepthButton label="Expand all levels" depth="all" checked={currentDepth === "all"} {...context} />
|
||||
<ListExpandDepthButton label={t("book_properties.expand_all_levels")} depth="all" checked={currentDepth === "all"} {...context} />
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user