feat(trace-drawer): implement resizable trace drawer and enhance UI interactions

This commit introduces a resizable trace drawer in the `doc-content` component, allowing users to adjust the width for better visibility. Key changes include:

1. Added functionality to save and load the drawer width from local storage.
2. Implemented mouse events for resizing the drawer, enhancing user interaction.
3. Updated the UI to reflect the new drawer width dynamically.
4. Enhanced the trace entry button for improved accessibility and clarity.

These changes aim to improve user experience by providing a more flexible and user-friendly interface for trace inspection.
This commit is contained in:
wizardchen
2026-05-28 13:19:41 +08:00
committed by lyingbug
parent d12273255d
commit a0547729b2
5 changed files with 433 additions and 485 deletions
+10
View File
@@ -406,6 +406,11 @@ export default {
fetchFailed: 'Last {n} refreshes failed — data may be stale, click refresh to retry',
fetchFailedShort: 'fetch failed',
viewTrace: 'View trace',
traceBtn: 'Trace',
expandBranch: 'Expand children',
collapseBranch: 'Collapse children',
rowSelectHint: 'Click to view details; use the arrow to expand or collapse children',
resizeDrawer: 'Drag to resize panel width',
justNow: 'just now',
secondsAgo: '{n}s ago',
minutesAgo: '{n}m ago',
@@ -415,6 +420,8 @@ export default {
head: {
duration: 'Duration',
stages: 'Stages',
stagesDone: 'Stages completed',
stagesProgress: 'Current stage',
stage: 'Stage',
status: 'Status',
attempt: 'Attempt',
@@ -440,6 +447,9 @@ export default {
input: 'Input',
output: 'Output',
metadata: 'Metadata',
traceMetadata: 'Trace metadata',
metadataHint: 'Auxiliary fields for observability (e.g. Langfuse trace ID). Stage/subspan payloads live under Input and Output.',
metadataEmpty: 'This span has no metadata. Use Input/Output for stage payloads; trace-level fields appear in Overview when Langfuse is connected.',
error: 'Error',
empty: 'No data',
inProgress: 'In progress',