Skip to content

gpuicn v0.9.8

Choose a tag to compare

@github-actions github-actions released this 07 Nov 11:45
· 16 commits to main since this release
9b280e1

gpuicn v0.9.8

Paper-cuts from Matty's jank review (matty#670): overlays close on Escape
even inside an app's own Escape shortcut, the lightbox closes on a click
around the image and stops blowing small images up, sidebar rows get a
label suffix for status emoji, and Markdown code blocks get a copy button.
Long content can collapse behind Show more. The runtime pins are
unchanged: GPUI Kit 0.9.0 on gpui-pre 0.3.11 and gpui-icons 0.6.0.

Added

  • SidebarItem::label_suffix puts content right after the label, such
    as a person's status emoji, where a hover-revealed options button never
    covers it. A long label truncates before it.
    label_suffix_tooltip shows the text behind it and is read after the
    label.
  • Code block copy button: every markdown() code block shows its
    language and a copy button that copies the raw code (no fences) and
    confirms with a check.
  • collapsible::ShowMore clips content taller than 600 px
    (max_height) behind a fade with Show more / Show less. It is
    uncontrolled, or controlled with expanded and on_toggle;
    fade_color matches the surface behind it.
  • LightboxImage::dimensions(width, height): with a known size, the
    lightbox fits large images down and shows small ones at their natural
    size.
  • primitives::dismiss::on_escape for your own overlays, the Dismiss
    action and the DISMISS_CONTEXT key context.
  • Strings: UiText::CopyCode, UiText::Copied.

Fixed

  • Escape closes dialogs, popovers, hover cards, menus and the lightbox
    when the app binds Escape in a context around them. GPUI runs key
    bindings before key listeners, so an app shortcut such as "mark read"
    used to take the key first. Escape is now the Dismiss action, bound
    in the overlay's own, deeper key context.
  • The lightbox closes on a click on the dark area around a fitted image.

Upgrading

LightboxImage has a new public field, size; code that builds it with
a struct literal adds size: None. Copied components pick these changes
up with gpuicn diff.