feat(dashboard): add NAME column with CJK-aware padding#15
Open
MuLinForest wants to merge 3 commits into
Open
Conversation
- Add session NAME column showing the conversation slug (e.g. atomic-leaping-moth)
- Add pad_wide() helper for CJK/wide character column alignment:
calculates display width from byte/char count difference so CJK
characters (each 2 display columns) align correctly
- NAME lookup priority:
1. session_title field from session JSON (written by statusline when
it reads customTitle from the JSONL; no extra I/O per render)
2. Epoch-mtime JSONL match: find the JSONL whose mtime is closest
to the session epoch to correctly identify the session even when
multiple sessions share the same project directory
- Adjust column widths to accommodate NAME (22 chars): trim PROJECT
from 18→14, MODEL from 14→12, STATUS from 9→8, bar from 24→22,
OUTPUT from 8→7; fix CTX% format from %-5s to %-6s to match header
Co-Authored-By: Claude Code <claude-core@mulin.date>
session_title from JSON is often null since statusline-command.sh does not write it. When falling back to JSONL lookup, check for a custom-title entry first (written by /rename) before using the auto-generated slug, so user-set names are shown when available. Co-authored-by: Claude Sonnet 4.6 <claude-code@mulin.date>
The separator string used N-2 dashes + 2 spaces per column instead of N dashes + 1 space, causing a 1-char misalignment per column vs the %-Ns format specifiers in the header printf. Co-authored-by: Claude Sonnet 4.6 <claude-code@mulin.date>
MuLinForest
added a commit
to MuLinForest/claude-code-toolkit
that referenced
this pull request
Mar 26, 2026
…session_title in single jq call Resolve dashboard.sh conflict: add session_title to PR kayhaowu#17's consolidated jq read, removing the redundant individual jq calls from PR kayhaowu#15. Co-Authored-By: Claude Sonnet 4.6 <claude-code@mulin.date>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add a NAME column to the dashboard showing the session slug (e.g.
atomic-leaping-moth), with correct handling of CJK wide characters.Changes
pad_wide()helper — CJK-aware column padding using byte/char count difference; each CJK character occupies 2 display columns, sowc -c(bytes) vswc -m(chars) detects multi-byte characters and calculates the correct paddingsession_titlefield from session JSON (written by statusline when it readscustomTitlefrom the JSONL — no extra I/O per render cycle)Test plan
/rename), verify NAME updates on next dashboard refreshsession_titleis absent from JSON (epoch-mtime JSONL match)🤖 Generated with Claude Code