Add sparkline history and reset time toggle#9
Merged
Conversation
xicv
pushed a commit
to xicv/claude-limitline
that referenced
this pull request
Feb 19, 2026
Add two new block segment features: - timeDisplay option: show "remaining" (3h20m) or "absolute" (2:30pm) reset time - Sparkline history: visual usage trend (▁▂▃▄▅▆▇█) stored in ~/.claude/limitline-history.json Based on tylergraydev#9 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
New features:
- Reset time toggle: Show either time remaining ("3h20m") or absolute reset time ("2:30pm")
- Config: `block.timeDisplay: "remaining" | "absolute"`
- Config: `block.timeFormat: "12h" | "24h"`
- Sparkline history: Visual usage trend using block characters (▁▂▃▄▅▆▇█)
- Config: `block.showSparkline: boolean` (default false)
- Config: `block.sparklineWidth: number` (default 8)
- Stores usage history in ~/.claude/limitline-history.json
- Shows last 24 hours of usage data
Example output with sparkline:
◫ 29% ▁▂▃▄▅▆▇█ (3h)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
tylergraydev
force-pushed
the
feature/sparkline-and-time-toggle
branch
from
February 22, 2026 23:08
e3f0920 to
2ef0614
Compare
3 tasks
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
Two new features for the block segment:
1. Reset Time Toggle
Show either time remaining or absolute reset time:
timeDisplay: "remaining"(default) - Shows "3h20m"timeDisplay: "absolute"- Shows "2:30pm" or "14:30"timeFormat: "12h" | "24h"- Configure 12/24 hour format2. Sparkline History
Visual usage trend using block characters:
showSparkline: boolean(default false)sparklineWidth: number(default 8)~/.claude/limitline-history.jsonExample Output
With sparkline enabled:
With absolute time (12h):
With absolute time (24h):
Configuration Example
{ "block": { "enabled": true, "timeDisplay": "absolute", "timeFormat": "12h", "showSparkline": true, "sparklineWidth": 8 } }Test plan
npm test- 178 tests passnpm run build- builds successfully🤖 Generated with Claude Code