Skip to content

Commit

Permalink
feat: ✨ Options to show img thumbnails or not
Browse files Browse the repository at this point in the history
  • Loading branch information
SkepticMystic committed Nov 10, 2021
1 parent 85cbb79 commit e8ae368
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ export const DEFAULT_SETTINGS: GraphAnalysisSettings = {
noInfinity: true,
noZero: true,
allFileExtensions: true,
showImgThumbnails: true,
addUnresolved: true,
coTags: true,
defaultSubtypeType: 'Co-Citations',
Expand Down
1 change: 1 addition & 0 deletions src/Interfaces.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ export interface GraphAnalysisSettings {
noInfinity: boolean
noZero: boolean
allFileExtensions: boolean
showImgThumbnails: boolean
addUnresolved: boolean
coTags: boolean
defaultSubtypeType: Subtype
Expand Down
12 changes: 12 additions & 0 deletions src/Settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,18 @@ export class SampleSettingTab extends PluginSettingTab {
})
)

new Setting(containerEl)
.setName('Show Thumbnails for Images')
.setDesc(
'Whether to show small thumbnails for images (if all file extensions are included).'
)
.addToggle((toggle) =>
toggle.setValue(settings.showImgThumbnails).onChange(async (value) => {
settings.showImgThumbnails = value
await plugin.saveSettings()
})
)

new Setting(containerEl)
.setName('Include tags (Co-Citations)')
.setDesc(
Expand Down

0 comments on commit e8ae368

Please sign in to comment.