Editor

Turn into menu

The “Turn into” list: convert a block to another type. The current type is checked. Used as a submenu of the block menu and of the text toolbar.

Text
Heading 1
Heading 2
Heading 3
Heading 4
Page
Page in
Bulleted list
Numbered list
To-do list
Toggle list
Code
Quote
Callout
Block equation
Synced block
Toggle heading 1
Toggle heading 2
Toggle heading 3
Toggle heading 4
2 columns
3 columns
4 columns
5 columns

Usage

  • Use the Turn into menu to change a block’s type while keeping its text.
  • It opens from the block menu and the text toolbar; render it yourself only in a custom editor.
  • Don’t use it to insert new blocks; that is the slash menu’s job.

Installation

Install the package (React 19):

terminal
npm install @krackedui/motion

Import the styles once, in your app entry or root layout:

/src/main.tsx
import '@krackedui/motion/styles.css';

Use it anywhere inside your app's <Theme> (see Installation):

/src/TurnintomenuExample.tsx
import { TurnIntoMenu } from '@krackedui/motion';

export function TurnIntoMenuExample() {
  return (
    <TurnIntoMenu block={{ type: 'text' }} highlightedId="text" />
  );
}

Examples

Toggle heading checked

Headings compare toggleable too, so a toggle heading checks “Toggle heading N”.

Text
Heading 1
Heading 2
Heading 3
Heading 4
Page
Page in
Bulleted list
Numbered list
To-do list
Toggle list
Code
Quote
Callout
Block equation
Synced block
Toggle heading 1
Toggle heading 2
Toggle heading 3
Toggle heading 4
2 columns
3 columns
4 columns
5 columns

Bare

bare drops the floating surface, for embedding in another menu.

Text
Heading 1
Heading 2
Heading 3
Heading 4
Page
Page in
Bulleted list
Numbered list
To-do list
Toggle list
Code
Quote
Callout
Block equation
Synced block
Toggle heading 1
Toggle heading 2
Toggle heading 3
Toggle heading 4
2 columns
3 columns
4 columns
5 columns

API Reference

TurnIntoMenu

Based on <div> and supports its props (except onSelect). Adds:

PropTypeDefault
block
Pick<Block, "type" | "props">
onSelect
(item: TurnIntoItem) => void
highlightedId
string
bare
boolean
false
autoFocus
boolean
false

TurnIntoItem

Entries of turnIntoItems; isKind(block, kind) decides the checkmark.

PropTypeDefault
id
string
label
string
icon
IconName
kind
BlockKind | null
submenu
boolean

Accessibility

  • The list is a labelled listbox and a single tab stop: ↑/↓/Home/End move the highlight (aria-activedescendant), Enter/Space pick it. Inside BlockActionMenu the same entries are a Radix submenu.
  • In the text toolbar the list opens from “Normal Text ▸” (aria-expanded); opened from the keyboard it takes focus, and Escape closes it and returns focus to the trigger.
© 2026 Motion. Internal documentation.