Repository navigation
Releases
Releases · alnpokrovsky/base-toolbar-config
1.1.0
Base Toolbar Config 1.1.0
What's New
- Refactored architecture: split
main.tsinto focused modules —commands.ts,toolbar/,ui/,utils/— keeping the entry point minimal per plugin lifecycle conventions. - MutationObserver for async toolbar rendering: embeds inside
%%cols%%tables and TaskNotes integrations now receive hide-classes correctly after the initial layout pass. - i18n support: English, Russian, and Chinese translations with runtime language switching.
- Settings UI: per-
.basefile toolbar configuration with custom view-switcher buttons, drag-to-reorder, and danger zone for deleting configs. - Test suite: added Vitest with 26 passing tests covering i18n, path resolution, and settings merging.
Changed
- Settings changes no longer trigger a full cache wipe + re-scan of all views; only affected UI is refreshed.
- Improved embed path resolution: handles anchors (
file.base#view), aliases (file.base|text), URL-encoding, andvault:///app://protocols.
1.0.7
1.0.6
1.0.5
1.0.4
Base Toolbar Config v1.0.4
🐛 Fixed
- Localization is now deterministic: replaced
ts-obsidian-i18n(localStorage-based) with a built-int()on top of Obsidian'sgetLanguage(). Interface language always matches the user's Obsidian setting, includingzh-CN/ru-RU. - Views button now actually hides when
hideViewsis enabled orviewsis listed intoolbar.hide. - Removed stray toolbar scrollbar caused by an unconditional
display: var(--btc-hide-*, inline-flex)rule. - Plugin no longer writes to
localStorage— the previouslanguagekey could interfere with Obsidian's own localization. - Removed duplicate
await loadSettings()call inonload().
⚡ Improved
- Embed resolution no longer enumerates the vault:
resolveEmbedPath()usesmetadataCache.getFirstLinkpathDest(). - Toolbar hiding is applied synchronously on
file-openand on.bases-toolbarinsertion (un-debouncedMutationObserver) — no more 2–3 s flash.
🧹 Internal
- Removed dependencies:
ts-obsidian-i18n,js-yaml,yaml. - YAML parsing via Obsidian's built-in
parseYaml. createDiv/createSpaninstead ofdocument.createElement;window.setTimeout/window.requestAnimationFramefor popout compatibility.- No
!importantinstyles.css; specificity raised via.workspace-leaf. eslint: 0 errors, 0 warnings.
1.0.3
Base Toolbar Config v1.0.3
This release focuses on rendering speed, CSS correctness, and a new toolbar button. Upgrading is recommended.
✨ New
- Hide the Views button. A new
hideViewstoggle is available under Interface, and a matchingviewstoken is supported in the.baseYAML:toolbar: hide: - views
⚡ Improved
- Instant toolbar hiding. Hide rules are now applied synchronously on
file-openand on.bases-toolbarinsertion (via an un-debouncedMutationObserver). Buttons no longer flash for 2–3 seconds before disappearing. - Settings are applied before paint. Per-file toggles are set in the same tick the view appears, so the toolbar is rendered already in its final state.
- YAML parsing uses Obsidian's built-in
parseYaml. No external YAML dependency. - Cache invalidation on file modify/rename/delete. Edits to
toolbar.hidein a.basefile take effect immediately — no plugin reload required.
🐛 Fixed
- Views button now actually hides. The CSS selector targets
.bases-toolbar-views-menuexplicitly. - Stray scrollbar in the toolbar. Removed the unconditional
display: var(--btc-hide-*, inline-flex)rule that changed layout even when no button was hidden. Hide rules now only applydisplay: nonewhen the correspondingbth-hide-*class is present. - Duplicate
await loadSettings()inonload()— settings were loaded twice on every startup. - Missing legacy cleanup for
bvs-hide-groupandbvs-hide-viewsinonunload(). - Settings migration. Old
data.jsonfiles without newer toggles (hideGroup,hideViews) are now filled in fromDEFAULT_FILE_CONFIGon load — no manual reset needed.
🧹 Internal
- Replaced
document.createElementwith Obsidian'screateDiv/createSpanhelpers (perobsidianmd/prefer-create-el). - Replaced bare
setTimeout/requestAnimationFramewithwindow.*variants for popout window compatibility. - Removed all
!importantdeclarations fromstyles.css; specificity is raised via.workspace-leafscoping instead. - Replaced direct
element.style.setPropertycalls withsetCssProps(perobsidianmd/no-static-styles-assignment). - Narrowed
loadData()result viaunknown+ type guard to satisfy@typescript-eslint/no-unsafe-assignment. - Migrated settings UI to the declarative
getSettingDefinitions()API (Obsidian 1.13.0+). eslintpasses with 0 errors, 0 warnings.
📦 Installation
Download main.js, manifest.json, and styles.css from this release and place them in <your-vault>/.obsidian/plugins/base-toolbar-config/, then restart Obsidian.
📋 Requirements
- Obsidian 1.13.0 or newer.
v1.0.1
Base Toolbar Config — Initial Release
Configure which toolbar buttons are visible in Obsidian Bases, both in standalone .base files and in embeds inside notes.
Features
- Per-file toolbar control — hide the result count, search, properties, filter, sort, group, or views buttons from the plugin settings or directly from a
.basefile's YAML. - Embed support — the same hiding rules apply to
![[file.base]]embeds. - Custom view-switcher buttons — pin frequently used views as toolbar buttons with an icon or text label.
- Default button — jump to a chosen view in one click.
- Drag-and-drop reordering of custom buttons.
- Multilingual UI — follows Obsidian's language (English, Russian, Chinese).
How to use
-
Open Settings → Base Toolbar Config.
-
Click + Add Base and pick a
.basefile. -
Toggle the buttons you want to hide under Interface.
Or add a
toolbar.hideblock directly to your.basefile:toolbar: hide: - search - filter - sort
Requirements
- Obsidian 1.13.0 or later.
Installation
Download main.js, manifest.json, and styles.css from this release and place them in <your-vault>/.obsidian/plugins/base-toolbar-config/.