claude-scope 0.8.1 → 0.8.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1185,13 +1185,13 @@ var init_constants = __esm({
1185
1185
  /** Demo total output tokens */
1186
1186
  TOTAL_OUTPUT_TOKENS: 5e4,
1187
1187
  /** Demo current input tokens */
1188
- CURRENT_INPUT_TOKENS: 15e4,
1188
+ CURRENT_INPUT_TOKENS: 8e4,
1189
1189
  /** Demo current output tokens */
1190
- CURRENT_OUTPUT_TOKENS: 5e4,
1190
+ CURRENT_OUTPUT_TOKENS: 3e4,
1191
1191
  /** Demo cache creation tokens */
1192
- CACHE_CREATION_TOKENS: 5e3,
1192
+ CACHE_CREATION_TOKENS: 1e3,
1193
1193
  /** Demo cache read tokens */
1194
- CACHE_READ_TOKENS: 35e3
1194
+ CACHE_READ_TOKENS: 15e3
1195
1195
  };
1196
1196
  DEFAULT_PROGRESS_BAR_WIDTH = DEFAULTS.PROGRESS_BAR_WIDTH;
1197
1197
  }
@@ -6486,12 +6486,32 @@ __export(select_with_preview_exports, {
6486
6486
  });
6487
6487
  async function generatePreviews(choices, style, themeName) {
6488
6488
  const previews = [];
6489
+ const isStyleSelection = choices.length >= 3 && choices.every((c) => isQuickConfigStyle(c.value));
6490
+ const availableThemes = [
6491
+ "monokai",
6492
+ "nord",
6493
+ "dracula",
6494
+ "catppuccin-mocha",
6495
+ "tokyo-night",
6496
+ "vscode-dark-plus",
6497
+ "github-dark-dimmed",
6498
+ "dusty-sage"
6499
+ ];
6500
+ const isThemeSelection = choices.some((c) => isThemeName(c.value, availableThemes));
6489
6501
  for (const choice of choices) {
6490
6502
  try {
6503
+ let previewStyle = style;
6504
+ if (isStyleSelection) {
6505
+ previewStyle = choice.value;
6506
+ }
6507
+ let previewTheme = themeName;
6508
+ if (isThemeSelection && isThemeName(choice.value, availableThemes)) {
6509
+ previewTheme = choice.value;
6510
+ }
6491
6511
  const preview = await renderPreviewFromConfig(
6492
- choice.getConfig(style, themeName),
6493
- style,
6494
- themeName
6512
+ choice.getConfig(previewStyle, previewTheme),
6513
+ previewStyle,
6514
+ previewTheme
6495
6515
  );
6496
6516
  previews.push(preview);
6497
6517
  } catch (error) {
@@ -6501,6 +6521,12 @@ async function generatePreviews(choices, style, themeName) {
6501
6521
  }
6502
6522
  return previews;
6503
6523
  }
6524
+ function isQuickConfigStyle(value) {
6525
+ return typeof value === "string" && ["balanced", "playful", "compact"].includes(value);
6526
+ }
6527
+ function isThemeName(value, availableThemes) {
6528
+ return typeof value === "string" && availableThemes.includes(value);
6529
+ }
6504
6530
  function selectWithPreviewImpl(config, done) {
6505
6531
  const [active, setActive] = useState(0);
6506
6532
  const [status, setStatus] = useState("idle");
@@ -6539,9 +6565,13 @@ function selectWithPreviewImpl(config, done) {
6539
6565
  if (status === "done") {
6540
6566
  return [`${config.message} ${activeChoice.name}`, ""];
6541
6567
  }
6542
- const previewBox = `\x1B[1;37m\u250C\u2500 Live Preview \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510\x1B[0m
6568
+ const line = "\x1B[1;37m" + "\u2500".repeat(60) + "\x1B[0m";
6569
+ const previewBox = `${line}
6570
+ \x1B[1;37mLive Preview\x1B[0m
6571
+
6543
6572
  ${preview}
6544
- \x1B[1;37m\u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518\x1B[0m`;
6573
+
6574
+ ${line}`;
6545
6575
  return [config.message, `${page}
6546
6576
 
6547
6577
  ${previewBox}`];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-scope",
3
- "version": "0.8.1",
3
+ "version": "0.8.3",
4
4
  "description": "Claude Code plugin for session status and analytics",
5
5
  "license": "MIT",
6
6
  "type": "module",