Skip to content

v0.28.5-nightly.86

@coadler coadler tagged this 09 Sep 06:50
## Summary

Add **Copy Markdown** to the chat context menu for selected text. Copy
Markdown and sanitized rich HTML together for formatted paste.

## Background

Plain-text copying loses formatting when users paste chat text into
Slack. The new action preserves selected formatting without copying the
entire message.

## Implementation

- Preserve emphasis, links, lists, tables, and code blocks within one
message body.
- Exclude code line numbers, controls, visually hidden text, and unsafe
HTML attributes.
- Preserve subscript and superscript semantics. Encode link destinations
for valid Markdown.
- Keep partial list numbering and table column positions.
- Retain relative links, task states, disclosure blocks, and fenced-code
languages.
- Copy selected math as a complete TeX formula to avoid duplicated
renderer text.
- Reconstruct selected Mermaid diagrams from renderer-owned source
metadata.
- Preserve definition-list structure and complete footnote
relationships. Partial selections omit broken footnote links.
- Preserve explicit list numbering and block content inside table cells.
- Strip arbitrary classes and inline styles from raw HTML. Preserve
renderer-generated math styling.
- Display unsupported raw MathML as literal text. Preserve literal HTML
when copied Markdown renders again.
- Keep table spans as sanitized HTML and preserve empty structure for
partial selections.
- Support **M** while the menu is open. Hide the shortcut label on phone
layouts.
- Use Markdown-only copying when rich clipboard APIs are unavailable or
reject the write.

## Risks

Selection conversion depends on the rendered chat structure. Raw HTML no
longer supports arbitrary CSS classes or inline styles. Semantic
Markdown formatting remains supported. Spanning-table selections can
include empty structural cells. Slack paste behavior still needs direct
confirmation.

---

_Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `medium`
• Cost: `$182.77`_

<!-- mux-attribution: model=openai:gpt-6-astra thinking=medium
costs=182.77 -->

---------

Co-authored-by: Mux <noreply@coder.com>
Assets 2
Loading