mirror of
https://github.com/zadam/trilium.git
synced 2025-11-03 11:56:01 +01:00
hide some "boring" attributes from book listing view
This commit is contained in:
@@ -79,6 +79,15 @@ async function renderAttributes(attributes, renderIsInheritable) {
|
||||
return $container;
|
||||
}
|
||||
|
||||
const HIDDEN_ATTRIBUTES = [
|
||||
'originalFileName',
|
||||
'template',
|
||||
'cssClass',
|
||||
'iconClass',
|
||||
'pageSize',
|
||||
'viewType'
|
||||
];
|
||||
|
||||
async function renderNormalAttributes(note) {
|
||||
const promotedDefinitionAttributes = note.getPromotedDefinitionAttributes();
|
||||
let attrs = note.getAttributes();
|
||||
@@ -90,6 +99,7 @@ async function renderNormalAttributes(note) {
|
||||
attrs = attrs.filter(
|
||||
attr => !attr.isDefinition()
|
||||
&& !attr.isAutoLink
|
||||
&& !HIDDEN_ATTRIBUTES.includes(attr.name)
|
||||
&& attr.noteId === note.noteId
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user