Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
chore(badges/content): add separator
Elian Doran43ebbfc3217a
diff --git a/apps/client/src/widgets/layout/ActiveContentBadges.tsx b/apps/client/src/widgets/layout/ActiveContentBadges.tsxindex 689854237d..162607b194 100644--- a/apps/client/src/widgets/layout/ActiveContentBadges.tsx+++ b/apps/client/src/widgets/layout/ActiveContentBadges.tsx@@ -73,6 +73,7 @@ const typeMappings: Record<ActiveContentInfo["type"], {dropStart: true,options: [{ label: "Legacy", value: "" },+ { type: "separator" },{ label: "Trilium (Auto)", value: "next" },{ label: "Trilium (Light)", value: "next-light" },{ label: "Trilium (Dark)", value: "next-dark" }diff --git a/apps/client/src/widgets/react/NotePropertyMenu.tsx b/apps/client/src/widgets/react/NotePropertyMenu.tsxindex 15f3723943..0c63f785c3 100644--- a/apps/client/src/widgets/react/NotePropertyMenu.tsx+++ b/apps/client/src/widgets/react/NotePropertyMenu.tsx@@ -55,6 +55,10 @@ interface ComboBoxGroup {items: ComboBoxItem[];}+interface ComboBoxSeparator {+ type: "separator"+}+export interface ComboBoxProperty {type: "combobox",label: string;@@ -64,7 +68,7 @@ export interface ComboBoxProperty {* The default value is used when the label is not set.*/defaultValue?: string;- options: (ComboBoxItem | ComboBoxGroup)[];+ options: (ComboBoxItem | ComboBoxSeparator | ComboBoxGroup)[];dropStart?: boolean;}@@ -176,6 +180,10 @@ function ComboBoxPropertyView({ note, property }: { note: FNote, property: Combo</Fragment>);}+ if ("type" in option) {+ return <FormDropdownDivider key={index} />;+ }+return renderItem(option);})}