mirror of
https://github.com/Nystik-gh/ignis.git
synced 2026-06-17 04:35:53 +00:00
refactor plugin, split into modules
This commit is contained in:
17
plugin/src/settings/general-tab.js
Normal file
17
plugin/src/settings/general-tab.js
Normal file
@@ -0,0 +1,17 @@
|
||||
const { Setting } = require("obsidian");
|
||||
|
||||
function display(containerEl) {
|
||||
containerEl.createEl("h2", { text: "Ignis General Settings" });
|
||||
|
||||
new Setting(containerEl)
|
||||
.setName("Example toggle")
|
||||
.setDesc("This is a test toggle to prove the Setting API works.")
|
||||
.addToggle((toggle) => {
|
||||
toggle.setValue(false);
|
||||
toggle.onChange((value) => {
|
||||
console.log("[ignis] Toggle:", value);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
module.exports = { display };
|
||||
Reference in New Issue
Block a user