Skip to content

Image resize handles missing in header/footer edit mode #266

@jedrazb

Description

@jedrazb

Reported during manual testing of PR #264 (which fixes save round-trip for header images, issue #251).

Repro

  1. bun run dev, open http://localhost:5173/.
  2. Load any DOCX with a header.
  3. Double-click the header to enter edit mode.
  4. Paste an image (Cmd+V).

Expected: Image has draggable resize handles (same as in body).

Actual: Image renders as plain <img>, no handles. Cannot resize while in header/footer edit mode.

Root cause

The body editor uses a React NodeView (EditableImage) that adds resize handles, but InlineHeaderFooterEditor.tsx:209 builds a fresh ExtensionManager via createStarterKit() that registers the plain ImageExtension.toDOM() without that NodeView.

Suggested fix

Either:

  • Plumb the same EditableImage React NodeView into the InlineHeaderFooterEditor's extension setup, or
  • Move the resize-handle NodeView registration into ImageExtension itself (single source of truth).

Estimated fix

Medium. Need to share the React NodeView across two ProseMirror instances cleanly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions