Skip to content

Commit

Permalink
Follow Guidelines for settings tab (#2342)
Browse files Browse the repository at this point in the history
  • Loading branch information
joethei committed May 26, 2024
1 parent 0c54ac0 commit b0c36b7
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,6 @@ class GeneralSettingsTab extends PluginSettingTab {

public display(): void {
this.containerEl.empty();
this.containerEl.createEl("h2", { text: "General settings" });

new Setting(this.containerEl)
.setName("Enable inline queries")
Expand Down Expand Up @@ -366,7 +365,7 @@ class GeneralSettingsTab extends PluginSettingTab {
})
);

this.containerEl.createEl("h2", { text: "Codeblock settings" });
new Setting(this.containerEl).setName("Codeblocks").setHeading();

new Setting(this.containerEl)
.setName("DataviewJS keyword")
Expand Down Expand Up @@ -420,8 +419,7 @@ class GeneralSettingsTab extends PluginSettingTab {
.onChange(async value => await this.plugin.updateSettings({ inlineQueriesInCodeblocks: value }))
);

this.containerEl.createEl("h2", { text: "View settings" });
this.containerEl.createEl("h3", { text: "General" });
new Setting(this.containerEl).setName("View").setHeading();

new Setting(this.containerEl)
.setName("Display result count")
Expand Down Expand Up @@ -530,7 +528,7 @@ class GeneralSettingsTab extends PluginSettingTab {
})
);

this.containerEl.createEl("h3", { text: "Table settings" });
new Setting(this.containerEl).setName("Tables").setHeading();

new Setting(this.containerEl)
.setName("Primary column name")
Expand Down Expand Up @@ -563,7 +561,7 @@ class GeneralSettingsTab extends PluginSettingTab {
})
);

this.containerEl.createEl("h3", { text: "Task settings" });
new Setting(this.containerEl).setName("Tasks").setHeading();

let taskCompletionSubsettingsEnabled = this.plugin.settings.taskCompletionTracking;
let taskCompletionInlineSubsettingsEnabled =
Expand Down

0 comments on commit b0c36b7

Please sign in to comment.