Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .obsidian/app.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
"readableLineLength": false,
"newFileLocation": "root",
"newFileFolderPath": "DiscourseGraph",
"promptDelete": true
"promptDelete": false
}
10 changes: 10 additions & 0 deletions .obsidian/plugins/discourse-graphs/data.json
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,16 @@
"modified": 1777371361833,
"description": "An untested claim posed for discussion",
"keyImage": true
},
{
"id": "node_kAWsJzpPKx62Ys03qh289",
"name": "test",
"format": "TEST - {content}",
"template": "Test template",
"tag": "",
"color": "#808080",
"created": 1781800050362,
"modified": 1781800071284
}
],
"relationTypes": [
Expand Down
13 changes: 13 additions & 0 deletions .obsidian/plugins/discourse-graphs/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -66528,6 +66528,19 @@ var convertPageToDiscourseNode = (_0) => __async(void 0, [_0], function* ({
fm.nodeTypeId = nodeType.id;
}
);
if (nodeType.template && nodeType.template.trim() !== "") {
const templateApplied = yield applyTemplate({
app: plugin.app,
targetFile: file,
templateName: nodeType.template
});
if (!templateApplied) {
new import_obsidian16.Notice(
`Warning: Could not apply template "${nodeType.template}"`,
3e3
);
}
}
new import_obsidian16.Notice("Converted page to discourse node", 1e4);
} catch (error) {
console.error("Error converting to discourse node:", error);
Expand Down
Loading