mirror of
https://github.com/lostpaul/obsidian-folder-notes.git
synced 2026-07-22 07:40:24 +00:00
Front matter title bug fix
This commit is contained in:
parent
b40b81bf98
commit
8f91a53fed
2 changed files with 9 additions and 5 deletions
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"id": "folder-notes",
|
||||
"name": "Folder notes",
|
||||
"version": "1.4.4",
|
||||
"version": "1.4.5",
|
||||
"minAppVersion": "0.15.0",
|
||||
"description": "Create notes within folders that can be accessed without collapsing the folder, similar to the functionality offered in Notion.",
|
||||
"author": "Lost Paul",
|
||||
|
|
|
|||
12
src/main.ts
12
src/main.ts
|
|
@ -33,9 +33,11 @@ export default class FolderNotesPlugin extends Plugin {
|
|||
|
||||
new Commands(this.app, this).registerCommands();
|
||||
|
||||
if (this.settings.frontMatterTitle.enabled) {
|
||||
this.fmtpHandler = new FrontMatterTitlePluginHandler(this);
|
||||
}
|
||||
this.app.workspace.onLayoutReady(() => {
|
||||
if (this.settings.frontMatterTitle.enabled) {
|
||||
this.fmtpHandler = new FrontMatterTitlePluginHandler(this);
|
||||
}
|
||||
});
|
||||
|
||||
this.observer = new MutationObserver((mutations: MutationRecord[]) => {
|
||||
mutations.forEach((rec) => {
|
||||
|
|
@ -85,7 +87,9 @@ export default class FolderNotesPlugin extends Plugin {
|
|||
childList: true,
|
||||
subtree: true,
|
||||
});
|
||||
this.registerEvent(this.app.workspace.on('layout-change', () => { this.loadFileClasses(); }));
|
||||
this.registerEvent(this.app.workspace.on('layout-change', () => {
|
||||
this.loadFileClasses();
|
||||
}));
|
||||
this.registerEvent(this.app.vault.on('delete', (file: TAbstractFile) => {
|
||||
if (!(file instanceof TFile)) { return; }
|
||||
// parent is null here even if the parent exists
|
||||
|
|
|
|||
Loading…
Reference in a new issue