November 2026 - Presentation Editing
Presentation gains a formatting toolbar API, snapping, rotation, and composable overlay parts. Includes breaking changes.
Presentation now covers more of a slide editor, built on @diceui/pptx 0.3.
pnpm dlx shadcn@latest add @diceui/presentationEditing
- Selection. A click selects a shape. Click it again, double-click, or type to edit its text. An empty text box is removed once editing moves elsewhere.
- Snapping. Moving and resizing snap to the slide and to other shapes, with guides. Hold Alt to place freely, or set
snappingandsnapThreshold. - Rotation. Drag the handle above a shape to rotate it. Rotated shapes resize along their own axes.
- Shortcuts. Tab moves between shapes, Ctrl / Cmd + D duplicates, copy, cut, and paste work within and between decks, and Ctrl / Cmd + ] and Ctrl / Cmd + [ arrange.
- Thumbnails. The list keeps at most 50 rendered previews, and pending previews no longer pulse.
Formatting toolbar
useSelection reads the selection and its text formatting, and formats, duplicates, deletes, reorders, and inserts text boxes and shapes. startDrawing arms a draw tool that places a text box or shape where the slide is clicked or dragged. Mark toolbars and their menus with data-pptx-keep-selection so pressing them keeps the selection.
The editing example now has a small toolbar built with it.
Overlay parts
The selection overlay is composable from PresentationSelectionBox, PresentationResizeHandle, PresentationRotateHandle, PresentationSnapGuide, and PresentationMarquee. PresentationSelection renders all of them by default.
<PresentationSelection>
<PresentationSelectionBox>
<PresentationResizeHandle />
<PresentationRotateHandle />
</PresentationSelectionBox>
<PresentationSnapGuide />
<PresentationMarquee />
</PresentationSelection>Breaking changes
undo()returns a promise.useHistory().undoandstore.undo()resolve to a boolean, likeredo().movestarts on drag.modeanddata-modestay"selected"on a press and only become"move"once it drags.- Click selects text boxes. A single click no longer starts editing a text box or placeholder.
- New selection color. The default
--presentation-selectionis#1a73e8instead ofvar(--ring). - Resize handle attribute. Resize handles carry
data-resize-handleinstead ofdata-resize-grip. - New modes.
onModeChangeandmodecan report"rotate"and"draw".
Migrating
- Update
@diceui/pptxto 0.3 and reinstall the Presentation component. - Await or
voidcalls toundo(). - Rename
[data-resize-grip]selectors to[data-resize-handle]. - Set
--presentation-selection: var(--ring)to keep the old selection color.