Decisions

  • Decided: CSS-based approach (inject styles to hide folders)
  • Pending: Does CSS data-path selector work on Obsidian Mobile?

User Tasks

  • Test plugin on Obsidian Mobile after pull
  • Report what the file explorer DOM looks like on mobile

Summary

Custom Obsidian plugin that hides all top-level folders except vault/ in the file explorer, so the user only sees vault content.

Problem / Motivation

When the Opus git repo is opened as an Obsidian vault, the file explorer shows all top-level folders (src/, .claude/, .github/, tests/, etc.). Obsidian’s built-in “Excluded folders” feature doesn’t work reliably. A custom plugin is needed to filter the explorer view.

Proposed Solution

A minimal Obsidian plugin (“Vault Focus”) that injects CSS to hide all top-level items in the file explorer except the configured root folder (default: vault).

Current implementation: .obsidian/plugins/vault-focus/

  • manifest.json — Plugin metadata
  • main.js — CSS injection logic + settings tab
  • styles.css — Placeholder

Approach: Uses CSS selectors targeting .nav-folder.mod-root > .nav-folder-children > .tree-item[data-path] to hide/show folders.


Phase Overview

PhaseDescriptionStatus
Phase 1Basic CSS-based folder hidingWIP
Phase 2Polish and edge cases

Phase 1: Basic Folder Hiding — WIP

Goal: Hide all top-level folders except vault/ in the file explorer.

File / FeatureDetailsOwnerStatus
Plugin scaffoldmanifest.json, main.js, styles.cssopusdone
CSS injectionHide folders via data-path selectorsopusdone
Settings tabConfigurable root folderopusdone
Test on desktopVerify it works on Obsidian desktopmv
Test on mobileVerify it works on Obsidian Mobile (Android)mvWIP
Debug mobileFix if CSS selectors differ on mobileopus

Phase 2: Polish — —

Goal: Handle edge cases and improve UX.

File / FeatureDetailsOwnerStatus
Multiple foldersSupport showing multiple foldersopus
Auto-detectAuto-detect vault/ if it existsopus
Collapse rootAuto-expand vault/ on startupopus

Test

Manual tests

TestExpectedOwnerActualLast
Plugin loads on desktopNo errors, folders hiddenmvpending-
Plugin loads on mobileNo errors, folders hiddenmvpending-
Settings changeChanging root folder updates explorermvpending-
Plugin disableAll folders visible againmvpending-

History

DateEventDetails
2026-03-22CreatedInitial plugin with CSS-based folder hiding

References

  • FR-021 (Obsidian Setup) — plugin is part of Obsidian configuration
  • FR-020 (Vault Sync) — plugin needed for clean mobile experience