Skip to content

Commit

Permalink
refactor(setting): remove unused variable
Browse files Browse the repository at this point in the history
  • Loading branch information
Mara-Li committed Aug 19, 2023
1 parent a8ae4d1 commit 4dc7782
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions src/settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export class NoteInFolderSettingsTab extends PluginSettingTab {
containerEl.createEl("h3", {text: i18next.t("title")} as const);

for (const folder of this.plugin.settings.folder) {
const setting = new Setting(containerEl)
new Setting(containerEl)
.setClass("create-note-in-folder")
.setClass("settingsTab")
.addButton(cb =>
Expand All @@ -60,8 +60,7 @@ export class NoteInFolderSettingsTab extends PluginSettingTab {
this.plugin.settings.folder[this.plugin.settings.folder.indexOf(folder)] = result;
this.plugin.saveSettings();
}).open();
}));
const commandNameSetting = setting
}))
.addText(cb => {
cb
.setPlaceholder(i18next.t("commandName"))
Expand All @@ -77,9 +76,7 @@ export class NoteInFolderSettingsTab extends PluginSettingTab {
* When the user focus the cb input, a tooltip must be displayed to say "command name"
*/
this.addTooltip(i18next.t("commandName"), cb.inputEl);
});

const SearchSetting = setting
})
.addSearch((cb) => {
new FolderSuggest(cb.inputEl);
cb.setPlaceholder(i18next.t("example"));
Expand All @@ -93,8 +90,7 @@ export class NoteInFolderSettingsTab extends PluginSettingTab {
await this.plugin.saveSettings();
});
this.addTooltip(i18next.t("path"), cb.inputEl);
});
setting
})
.addButton(cb =>
cb
.setIcon("cross")
Expand Down

0 comments on commit 4dc7782

Please sign in to comment.