Skip to content

Design a generic side panel system for right-hand plugins #64

@jedrazb

Description

@jedrazb

Problem

We currently have the template variable panel on the right side of the editor. As we add more features — Track Changes (#49), comments, document outline — they'll all need right-side panel space.

Right now there's no system for this. Each feature would fight for the same space, and we'd end up with ad-hoc solutions that don't compose well.

What we need

A generic panel registration system that plugins can hook into cleanly. Something like:

interface SidePanel {
  id: string;            // 'templates', 'track-changes', 'comments'
  label: string;
  icon: ReactNode;
  component: ReactNode;
  badge?: number;        // e.g. "3 pending changes"
}

Plugins register a panel, the system handles layout and switching.

Open question: what's the best UX pattern?

  • Icon rail (like VS Code's activity bar) — vertical icon strip on the far right, click to open/close, only one panel visible at a time
  • Stacked/collapsible sections — multiple panels visible simultaneously, each independently expandable
  • Contextual — panel switches automatically based on what you're doing (select a tracked change → review panel appears, click a template field → templates panel appears)

Why this matters now

This should be build together with Track Changes (#49) or any other right-side feature, so they plug in cleanly from day one. The existing template panel should be refactored to use this system as the first consumer.

Input and PRs welcome!

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions