Extensible optionsSource registry for configuration UI #328
Labels
No labels
abandoned
active
audit
blocked
data-safety
difficulty:easy
difficulty:hard
difficulty:high
difficulty:medium
docs
done
duplicate
notebook-v0
open
priority:high
ready
release-critical
safe-mode
spec
spec-backlog
subsystem:api
subsystem:backlog
subsystem:bases
subsystem:ci
subsystem:command
subsystem:configuration
subsystem:consolidate
subsystem:dependencies
subsystem:desktop-electron
subsystem:diffmerge
subsystem:docker
subsystem:docs
subsystem:fuzzy
subsystem:graph
subsystem:hotkeys
subsystem:lapis
subsystem:maint
subsystem:maintenance
subsystem:markdown
subsystem:markdown-lint
subsystem:md018
subsystem:notebook
subsystem:notifications
subsystem:opfs
subsystem:package
subsystem:plugin-markdown
subsystem:plugin-tasks
subsystem:plugins
subsystem:registry
subsystem:release
subsystem:renovate
subsystem:restore
subsystem:scripts
subsystem:search
subsystem:settings
subsystem:spec
subsystem:tasks
subsystem:testing
subsystem:ui
subsystem:web
subsystem:workspace
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
lapis-notes/lapis#328
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Make configuration-schema
optionsSourcedynamically extensible so the settings UI resolves option lists without hardcoded switches such asworkspace.editorViews.Problem
The workspace settings renderer hardcodes
optionsSource === "workspace.editorViews"inconfiguration.ts. Plugins cannot register their own option sources for declarative settings.Goal
workspace.editorViews).onloadviaPlugin.registerConfigurationOptionSource.App.configurationOptionSources.Scope
ConfigurationOptionSourceRegistryin API packageworkspace.editorViewssourceNon-goals
optionsSourceParamsschema fieldAcceptance Criteria
workspace.editorViewsregistered onAppat boot; invalidates onEditorViewRegistrychangesoptionsSourceswitch in workspace configuration rendereroptionsSourceresolve via registryregisterConfigurationOptionSource("ruleIds", …)→plugin-id.ruleIds; unload removes itallowUnknownOptions: trueImplementation Notes
See attached implementation plan. Phases: registry module → App wiring → plugin API → workspace renderer → component polish → spec.
Suggested Files or Specs To Inspect
packages/api/src/lib/configuration-option-source-registry.ts(new)packages/api/src/lib/context.svelte.tspackages/api/src/lib/plugin.tspackages/workspace/src/lib/components/configuration/configuration.tsspec/src/30-cross-package-contracts/configuration-and-settings.mdValidation Commands
Related Issues
Follow-up Tasks
optionsSourceParamsfor parameterized sourcesImplementation Summary
Added ConfigurationOptionSourceRegistry on App with built-in workspace.editorViews source, Plugin.registerConfigurationOptionSource lifecycle API, registry-backed resolve/bind helpers for object-map and object-array settings, and (custom) unknown-value labels. Validated with api/workspace unit tests and pnpm test:smoke.