BlockNote icon indicating copy to clipboard operation
BlockNote copied to clipboard

Ability to change the custom block type to another

Open expiante opened this issue 10 months ago • 3 comments

It would be very helpful if BlockNote provided a native way to change a custom block type to another block type.

Currently, when selecting text inside BlockNote’s built-in blocks, the formatting toolbar appears with a Block Type dropdown that allows changing the block type. However, this dropdown is not available for custom blocks, which makes it impossible to convert them using the same UX.

Current Limitation

  • Built-in blocks expose the Block Type dropdown in the formatting toolbar
  • Custom blocks do not expose this control
  • As a result, users cannot convert a custom block into another block type using the native UI

Existing Workaround

BlockNote allows developers to manually construct the content of the formatting toolbar. However, this approach has several drawbacks:

  • The formatting toolbar dynamically adapts based on context (e.g. links, images, tables, etc.)
  • Manually reconstructing the toolbar risks:
    • Breaking built-in toolbar logic in certain states
    • Missing context-specific behaviors
    • Losing compatibility with future toolbar features or components

Why Native Support Matters

  • Ensures consistent UX between built-in and custom blocks
  • Avoids fragile workarounds and duplicated logic
  • Preserves automatic toolbar behavior and future extensibility
  • Makes custom blocks feel like first-class citizens in the editor

Ideally, custom blocks should be able to opt into the same Block Type dropdown behavior as built-in blocks without requiring manual toolbar reconstruction.

expiante avatar Feb 02 '26 12:02 expiante

Seems like the dropdown was wrongly being filtered out, we can fix this easily I think

nperez0111 avatar Feb 03 '26 10:02 nperez0111

@nperez0111 would this be similar to https://github.com/TypeCellOS/BlockNote/issues/2347?

woutervroege avatar Feb 05 '26 22:02 woutervroege

@woutervroege one is about when the dropdown should show, the other is about what it's contents are, so slightly different

nperez0111 avatar Feb 06 '26 12:02 nperez0111