Skip to content

ClassDetailPanel: isSuggestionMode prop is declared but unused #225

Description

@damienriehl

Problem

ClassDetailPanelProps declares isSuggestionMode?: boolean (components/editor/ClassDetailPanel.tsx:74), and both editor layouts pass it (Standard line 455, Developer line 559). The component does not destructure or read it anywhere — it is dead code at the type-system level only.

This was introduced when the per-panel "Edit Item" button was removed in PR #104. The companion panels (PropertyDetailPanel, IndividualDetailPanel) don't have the prop at all.

Why it matters

  • Misleading: callers think they are toggling something they aren't.
  • Drift risk: a future reader may try to wire it up and accidentally re-introduce read-only behavior in the editor.

Proposed fix

One of:

  1. Remove isSuggestionMode from ClassDetailPanelProps. Callers should drop the prop too.
  2. If a real semantic difference is intended in suggestion mode (e.g., warning banner, tinted save bar), wire it through.

Option 1 is the lower-risk change.

Refs

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions