Next release

So far this release lets shapes decide whether they can flip, gates action execution on action predicates across menus and shortcuts, improves crop mode, and runs agent starter kit actions through tool calls. It also includes bug fixes across media asset handling, frame hit testing, text shape bounds, cursor chat, and the comment composer.

API changes

  • 💥 Add ShapeUtil.canFlip(shape), which decides whether the flip menu items and shift+H / shift+V act on a single selected shape. It defaults to false, so a lone custom shape no longer gets the flip menu items or shortcuts. If your shape changes when flipped (for example it handles negative scale in onResize), add override canFlip() { return true } to its util. Multi-shape flips are unchanged. (#11041)
  • 💥 Move the Cmd+G and Cmd+Alt+G shortcuts from the group and frame-selection actions to new toggle-group and toggle-frame actions, which pick group or ungroup, and frame-selection or remove-frame, from the selection. group and frame-selection no longer have a kbd, so menus no longer show a shortcut next to them. To rebind or disable these shortcuts, override actions['toggle-group'] or actions['toggle-frame'] instead, for example actions['toggle-group'].kbd = 'cmd+k,ctrl+k' or delete actions['toggle-group']; setting kbd on group or frame-selection now registers a separate shortcut that only groups or frames. (#11043)
  • 💥 Remove unused help-menu.discord, help-menu.github, and help-menu.twitter keys from TLUiTranslationKey. (#11258)
  • Actions don't run when isAvailable or isEnabled returns false, or when the editor is readonly and the action isn't readonlyOk, whether they're triggered from a menu, a keyboard shortcut or an onSelect call on an action from useActions(). The copy, cut and paste shortcuts still come from native clipboard events and aren't gated. If your app calls a custom action directly in readonly mode, set readonlyOk: true on it. An override that replaces a built-in's onSelect, in place or by spreading it, keeps the built-in's isEnabled, so the action no longer runs from a shortcut or useActions() when that returns false; override isEnabled too if your onSelect handles that case. (#11043)

Improvements

  • Keyboard shortcuts no longer do things the menus don't allow: Shift+H and Shift+V no longer flip a lone text, Shift+F no longer flattens a lone image, Cmd+A and Cmd+P do nothing on an empty page, and Cmd+G no longer groups an arrow away from a shape it's bound to. (#11043)
  • Add Cmd+Alt+Shift+G as an explicit Remove frame shortcut. Cmd+G and Cmd+Alt+G continue to toggle grouping and framing when the selection allows the corresponding action. (#11043)
  • Cursor chat opens with / in any tool, and its menu item shows in any tool. (#11043)
  • Exit crop mode when clicking any shape other than the one being cropped, instead of moving the crop to the clicked image. (#10832)
  • Run agent starter kit actions through tool calls rather than plain JSON text output, with streaming partial updates and follow-up turns, and let actions provide their own results via AgentActionUtil.getResult. (#11147)
  • Add OpenRouter support to the agent and branching-chat starter kits via OPENROUTER_API_KEY. (#11103)

Bug fixes

  • Fix a crash when dropping an audio-only video file (for example .webm) or a file with no size on the canvas. (#11220)
  • Fix replacing an image or video when the upload fails: the shape now keeps its previous media and an error toast shows. (#11220)
  • Fix clicks in the empty space above a frame selecting the frame when zoomed out. (#11253)
  • Fix cursor chat closing immediately when opened from the context menu. (#11054)
  • Fix the comment composer's text jumping up when a comment wraps onto a second line. (#11255)
  • Fix the selection box of a text shape shrinking when an empty heading is created. (#11219)
Next
v5.6.0