Skip to content

[Feature]: Add /export slash command for quick conversation export #1685

@amanharshx

Description

@amanharshx

Feature Description

Currently there is no way to quickly export or copy an entire conversation from within the chat. If you want to grab the full text of a conversation, you have to manually select and copy it in multiple passes — the UI doesn't let you select all the text at once. This is especially painful for long conversations where you need the full transcript (e.g. to paste into another tool or save for reference).

A /export slash command would let users instantly copy the full conversation to clipboard or save it as a .txt file directly from the sendbox.

Proposed Solution

Add a /export builtin slash command with a two-step flow:

  1. Action picker — choose between "Copy to clipboard" or "Save to file"
  2. Filename input (save only) — enter a filename, see path preview, confirm save

The export produces a plain-text transcript with conversation metadata (name, ID, type, timestamp) and all shareable messages labeled by role (User / Assistant / System).

Why This Is Useful

  • Selecting conversation text in the UI requires multiple passes — you can't select everything at once
  • No existing single-conversation export — the GroupedHistory ZIP export is for bulk/multi-conversation use
  • Common workflow: copy a conversation to paste into any coding agent, a doc, or a ticket
  • Saves to the current workspace directory by default, or Desktop if no workspace is open

Implementation

Fixed in #1684

Affected Files

  • sendbox.tsx — register /export command, integrate overlay
  • conversationExport.ts (new) — shared export utilities
  • useConversationExport.tsx (new) — export flow state machine hook
  • exportHelpers.ts — extract shared functions, deduplicate role-label logic
  • useExport.ts — update imports to shared module
  • messages.json × 6 locales — 24 new i18n keys
  • 5 new test files — utility, hook, integration, and existing module tests

Diff

+1850 −96 across 18 files (12 modified, 6 new)

  • Code: +825 −96 across 13 files
  • Tests: +1025 −0 across 5 files

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions