Inkeep OSS Sync#607
Merged
Merged
Conversation
* [US-001] Add sidebar visibility config leaves and update showAllFiles redirect Add appearance.sidebar.showOnlyMarkdownFiles (default false), showSkillsSection (default true), and showOkFolders (default false) as project-local, non-agent-settable config leaves, registered before .default() per the field-registry declaration-order rule. Point the removed showAllFiles key's redirect at showOnlyMarkdownFiles as the view-preference successor and drop the stale no-way-to-scope claim. Tests: schema defaults and explicit-value parsing, project-local scope pins (field-registry list + patch-scope validation both directions), patchability through a project-local bindConfigDoc binding, the .md/.mdx description contract, and the removed-key successor pointer. * [US-002] Extend shared tree visibility predicate to axis composition filterVisibleEntries now takes an object of orthogonal visibility axes (showHiddenFiles, showOnlyMarkdownFiles, showOkFolders) composed by AND, with all-off defaults reproducing the previous hidden-only behavior exactly. .ok-segment entries are governed solely by showOkFolders: the hidden-files axis never reveals them, and a dot-segment ancestor above the .ok segment still follows hidden-files so revealing .ok cannot drag a hidden parent into view. Only-markdown keeps folders and markdown docs (client kind document is exactly on-disk .md/.mdx) and drops every other leaf. The four FileTree merge points adapt mechanically to the new signature (same hidden-files value from the existing ref mirror; no behavior change). Onboarding counters keep calling with defaults; new negative tests pin that view toggles cannot move the onboarding gate. * [US-003] Quiet tree on hidden-doc open: deselect stale row, guard scroll When the active doc has no visible tree row (view filters hide it), the selection mirror now clears the previously active row's selection instead of leaving a stale highlight, and revealActiveRow only scrolls when the focused row is the active row, so the tree no longer jumps to the stale previous row. Pierre has no unfocus API, so the stale focused path is neutralized by the reveal guard rather than cleared at the mirror. Adds a quiet-tree Playwright e2e (dot-path doc seeded via direct disk write; asserts editor opens, nothing selected, no scroll, visible ancestors of a partially hidden path stay expanded) and appends it to the fixed test:e2e CI subset. Both e2e tests were verified RED against the unfixed code. Unit and DOM tests pin the reveal guard and the absent-row deselect, including ancestor expansion ordering. * [US-004] Wire the only-markdown toggle into the tree filter and flip effect * [US-005] Gate the Skills sidebar section on showSkillsSection * [US-006] Restructure tree-options popover into the two-section Show layout The tree-options popover now renders its command pair (Expand all / Collapse all) followed by a separator and a Show-labeled checkbox group (Hidden files, Only markdown files, Skills), using the labeled-sections Group + aria-label + Label pattern so assistive tech announces the section. The trigger's folders-exist gate is removed: the Show group is state-independent, so the menu always has content; the command items keep their per-item smart-hide, now via gates shared with the empty-space menu and the View-menu IPC push (renamed surface-neutral). All three checkboxes write through a single patchSidebarVisibility helper (also absorbing the empty-space handler and the toggle-show-hidden-files menu action) with the existing disabled-when-binding-null + warn/toast pattern. New labels go through Lingui; en + pseudo catalogs regenerated. The sidebar-search-pill e2e empty-workspace test flips to assert the always-visible trigger; sibling dom-test dropdown mocks gain the new primitives. * [US-007] Add Show toggles to context menu, drop per-row checkbox * [US-008] Mirror the Show toggles into the native View menu * [US-009] Add the passive not-in-sidebar indicator with per-axis flips * [US-010] Add the filtered-to-zero explainer with one-click view-filter reset * [US-012] Add the request-scoped showOk flag to the documents endpoint * [US-013] Add the Show .ok folders toggle with read-only click-routing * chore(open-knowledge): changeset and comment fixes for tree Show filters Adds the minor changeset for the Show visibility menu, corrects the empty-space-menu comment to stop counting checkboxes, and fixes the state-store header to describe what the store actually persists. * fixup! local-review: baseline (pre-review state) * fixup! local-review: address findings (pass 1) * chore: drop ambient cross-harness skill churn from feature branch The review baseline snapshot swept pre-session working-tree state (.agents/skills symlink deletions + auto-generated .cursor/skills mirror) into this branch. These are unrelated to the tree Show-visibility feature; restore .agents/skills to origin/main and drop the generated .cursor mirror so the PR is feature-only. * chore: drop repo-root spec duplicate and restore ambient .agents skill The canonical feature spec lives under public/open-knowledge/specs/; a stray duplicate at the repo-root specs/ and one more ambient .agents/skills change were swept in by the review baseline snapshot. Remove the duplicate and restore .agents/skills to origin/main so the PR carries only the feature. * [US-101] Reject any-depth .ok/.git paths in server mutation handlers isReservedProjectStatePath now matches a .ok or .git segment at any depth, case-insensitively (nested <folder>/.ok is a first-class OK shape; case-insensitive filesystems resolve .OK/x to .ok/x). All six generic mutation sites consume it: create-page (replacing the first-segment check), create-folder, duplicate-path, rename-path (both sides), delete-path (reserved check now runs for folder and file kinds, not just asset), and the trash-cleanup sibling. New guard suite pins root/nested/case-variant rejection with untouched disk per handler, plus a nested-dotfolder non-rejection regression. * [US-102] Gate client mutation affordances on revealed .ok rows Revealed .ok rows are read-only OK-managed state, but four client surfaces still mutated them: the active-folder create target, the native File menu's rename/duplicate/move-to-trash dispatch, the tree's keyboard copy/paste/duplicate/delete shortcuts, and the delete-confirm execution spine that reaches Electron's shell.trashItem before any server check. Gate all four on the shared hasOkPathSegment predicate: the create dir falls back to the workspace root, mutating menu picks quietly no-op, keyboard shortcuts resolve no .ok targets (multi-selections drop them), and handleDeleteTargets filters .ok targets as the last chokepoint so no entry path can trash OK state from the client. Server-side any-depth rejection remains the authoritative boundary. * [US-103] Pin .ok activation read-only at e2e + spike corrigendum * Address review considers: case-insensitive client .ok guard, .git test parity - hasOkPathSegment now compares path segments case-insensitively, matching the server's isReservedProjectStatePath so the two read-only layers agree on .OK variants; dedicated predicate tests added - .git segment guard tests extended from 2 to 6 handlers (create-folder, duplicate source, rename to- and from-side) matching the .ok exhaustiveness - main app bundle size limit 462 -> 466 kB (measured 464.63 kB after three main catch-up merges + the Show menu eager weight; attribution in the package.json size note) GitOrigin-RevId: d130e89b609f3e87251ecb2be6ad03924c23d566
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Copybara-translated commits for Inkeep OSS Sync. Rebase-merge this PR so the prepared commits land directly on public main.