#12719: feat(ui): add copy button to logs page
app: web-ui
stale
Cluster:
Web UI Enhancements and Fixes
## Summary
- Add a Copy button to the gateway Control UI logs page that copies filtered log entries to the clipboard
- Button shows brief "Copied!" feedback for 1.5s after clicking, matching the existing chat copy button pattern
## Test plan
- [ ] Open Control UI → Logs tab
- [ ] Click Copy button → verify logs copied to clipboard and button briefly shows "Copied!"
- [ ] Apply filters → verify Copy only includes filtered entries
- [ ] Verify button is disabled when no log entries are visible
🤖 Generated with [Claude Code](https://claude.com/claude-code)
<!-- greptile_comment -->
<h2>Greptile Overview</h2>
<h3>Greptile Summary</h3>
This PR adds a new `onCopy` callback to the Logs view and wires it up in `renderApp` to copy the currently visible (filtered) log lines to the clipboard. The Logs page now renders a Copy button alongside Refresh/Export, and briefly changes its label to “Copied!” after clicking.
Main integration points:
- `ui/src/ui/app-render.ts` passes an `onCopy` implementation to `renderLogs`.
- `ui/src/ui/views/logs.ts` computes `filtered` entries and uses them for both Export and Copy actions.
Key issues to address before merge are around copy feedback/state management and error handling for clipboard writes.
<h3>Confidence Score: 3/5</h3>
- This PR is close to mergeable but has user-visible correctness issues around copy feedback/error handling.
- The feature is small and localized, but the current implementation can show “Copied!” even when clipboard writes fail, and the feedback is not tied to reactive render state (can desync on re-render/multiple clicks). Fixing these should make behavior reliable.
- ui/src/ui/views/logs.ts, ui/src/ui/app-render.ts
<!-- greptile_other_comments_section -->
<sub>(3/5) Reply to the agent's comments like "Can you suggest a fix for this @greptileai?" or ask follow-up questions!</sub>
<!-- /greptile_comment -->
Most Similar PRs
#9716: feat(ui): add GitHub-style floating copy button to code blocks
by BigUncle · 2026-02-05
78.6%
#19259: fix(ui): add legacy fallback for copy-as-markdown on non-secure con...
by assistent-dries-robuxio · 2026-02-17
76.2%
#13548: feat(control-ui): Add quote reply and send message to session features
by Annaxiebot · 2026-02-10
72.7%
#6308: feat(ui): add logsLevelFilters field to store log level filter sett...
by Cassius0924 · 2026-02-01
70.2%
#14719: UI: fix debug event log layout and health history toggle
by detecti1 · 2026-02-12
70.0%
#3721: fix(ui): webchat not displaying chat responses
by maxmaxrouge-rgb · 2026-01-29
69.9%
#7316: fix: /chat dashboard performance
by felipcsousa · 2026-02-02
69.1%
#6408: feat(ui): add job filtering and improve run history display
by Cassius0924 · 2026-02-01
68.3%
#9218: Fix Control UI chat resync on gaps and terminal events
by figitaki · 2026-02-05
68.3%
#14309: fix(ui): resolve chat event session key mismatch
by justonlyforyou · 2026-02-11
68.2%