Skip to content

Commit

Permalink
add button to reload
Browse files Browse the repository at this point in the history
  • Loading branch information
pourmand1376 committed Jul 1, 2024
1 parent b8a869c commit dbbe7c4
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -276,8 +276,19 @@ class FontSettingTab extends PluginSettingTab {
catch (error) {
console.log(error)
}
// Show combo box in UI somehow


new Setting(containerEl)
.setName("Reload fonts from folder")
.setDesc("This button reloades from the folder you specified (it also creates the folder for you)")
.addButton((button) => {
button.setButtonText("Reload")
button.onClick(callback => {
this.plugin.saveSettings();
this.plugin.load_plugin();
this.display();
})
})
this.containerEl.createDiv()

new Setting(containerEl)
.setName("Font")
Expand Down

0 comments on commit dbbe7c4

Please sign in to comment.