mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-07-27 18:12:29 +08:00
feat(in-app-help): render folders as book
This commit is contained in:
parent
02708d593f
commit
122c1ad1ec
@ -33,13 +33,13 @@ function parseNoteMetaFile(noteMetaFile: NoteMetaFile): HiddenSubtreeItem[] {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function parseNoteMeta(noteMeta: NoteMeta, docNameRoot: string): HiddenSubtreeItem {
|
function parseNoteMeta(noteMeta: NoteMeta, docNameRoot: string): HiddenSubtreeItem {
|
||||||
|
let iconClass: string = "bx bx-file";
|
||||||
const item: HiddenSubtreeItem = {
|
const item: HiddenSubtreeItem = {
|
||||||
id: `_help_${noteMeta.noteId}`,
|
id: `_help_${noteMeta.noteId}`,
|
||||||
title: noteMeta.title,
|
title: noteMeta.title,
|
||||||
type: "doc",
|
type: "doc", // can change
|
||||||
attributes: []
|
attributes: []
|
||||||
};
|
};
|
||||||
let iconClass: string = "bx bx-file";
|
|
||||||
|
|
||||||
// Handle attributes
|
// Handle attributes
|
||||||
for (const attribute of noteMeta.attributes ?? []) {
|
for (const attribute of noteMeta.attributes ?? []) {
|
||||||
@ -51,6 +51,7 @@ function parseNoteMeta(noteMeta: NoteMeta, docNameRoot: string): HiddenSubtreeIt
|
|||||||
// Handle folder notes
|
// Handle folder notes
|
||||||
if (!noteMeta.dataFileName) {
|
if (!noteMeta.dataFileName) {
|
||||||
iconClass = "bx bx-folder";
|
iconClass = "bx bx-folder";
|
||||||
|
item.type = "book";
|
||||||
}
|
}
|
||||||
|
|
||||||
// Handle text notes
|
// Handle text notes
|
||||||
|
Loading…
x
Reference in New Issue
Block a user