Feat/expired tokens multi account theme - #10
Open
realitix wants to merge 6 commits into
Open
Conversation
Monitor credentials file for changes and refresh automatically. Show cached data with visual feedback (desaturated icon) when the token expires, and add option to hide the indicator entirely.
Automatically detect ~/.claude-*/ directories and monitor multiple OAuth accounts simultaneously. The panel displays the highest utilization across all accounts, and the dropdown menu shows per-account usage sections. Accounts can also be added manually and labeled via the new Accounts preferences group.
Remove explicit color values from section titles, percent labels, and reset labels so they inherit the GNOME Shell theme colors. Replace fixed background-color on progress bar with a more neutral semi-transparent gray. Use opacity instead of hardcoded color for the reset label to better adapt to both light and dark themes.
Author
|
It fixes #3 |
Allow users to choose which account is displayed in the panel when multiple accounts are configured: highest usage, lowest usage, or specific pinned accounts shown side by side.
Create dynamic panel widgets per pinned account so each gets its own label and progress bar, instead of sharing the single default bar.
When icon style is 'color', panel progress bars follow the usage color scheme (green/yellow/orange/red). When 'monochrome', bars stay white.
|
+1 I created this PR which is completely separate from this one, that auto-refreshes the token. I use the Claude Desktop all the time instead of the CLI these days, which results in an expired token. I could raise a PR on top of this one as well to make that happen, but I didn't want to immediately. |
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
This PR adds three features to improve the extension's usability for power users and multi-account setups:
~/.claude-*/directories containing.credentials.jsonand monitors all accounts simultaneously. The panel displays the highest utilization across all accounts, and the dropdown menu shows per-account usage sections. Accounts can also be added manually and labeled via a new "Accounts" preferences group.Details
Expired token handling (
98eef9a)~/.claude/.credentials.jsonfor changes (debounced 500ms) and auto-refreshes on token updatehide-on-expiredsetting to completely hide the indicator when token is expiredMulti-account support (
10f9677)AccountStateclass to manage per-account state (credentials, file monitors, cached data, menu widgets)~/.claude-*/directories in the home folder$CLAUDE_CONFIG_DIRfor the default accountextra-accounts(manually added config dirs) andaccount-labels(custom labels inpath|labelformat)Theme compatibility (
6e7fdf7)colorvalues from.claude-section-title,.claude-percent-label,.claude-reset-labelrgba(128, 128, 128, 0.2)instead of white-based coloropacity: 0.6instead of fixed gray colorScreenshots
It works great ! And thanks for this extension.