@funnycode/myclaude 0.1.18 → 0.1.21

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.
package/dist/myclaude.js CHANGED
@@ -4,8 +4,8 @@
4
4
  // MACRO - build-time constants (injected by build.ts)
5
5
  // MACRO injected by build script
6
6
  globalThis.MACRO = {
7
- VERSION: "0.1.8",
8
- BUILD_TIME: "2026-06-12T13:23:10.387Z",
7
+ VERSION: "0.1.21",
8
+ BUILD_TIME: "2026-06-15T13:49:09.465Z",
9
9
  PACKAGE_URL: "@funnycode/myclaude",
10
10
  NATIVE_PACKAGE_URL: "@funnycode/myclaude",
11
11
  VERSION_CHANGELOG: '',
@@ -9952,9 +9952,9 @@ var init_startupProfiler = __esm(() => {
9952
9952
  }
9953
9953
  });
9954
9954
 
9955
- // node_modules/@ant/claude-for-chrome-mcp/index.ts
9956
- var exports_claude_for_chrome_mcp = {};
9957
- __export(exports_claude_for_chrome_mcp, {
9955
+ // shims/ant-claude-for-chrome-mcp/index.ts
9956
+ var exports_ant_claude_for_chrome_mcp = {};
9957
+ __export(exports_ant_claude_for_chrome_mcp, {
9958
9958
  createClaudeForChromeMcpServer: () => createClaudeForChromeMcpServer,
9959
9959
  BROWSER_TOOLS: () => BROWSER_TOOLS
9960
9960
  });
@@ -9966,7 +9966,7 @@ function createClaudeForChromeMcpServer(_context) {
9966
9966
  };
9967
9967
  }
9968
9968
  var BROWSER_TOOLS;
9969
- var init_claude_for_chrome_mcp = __esm(() => {
9969
+ var init_ant_claude_for_chrome_mcp = __esm(() => {
9970
9970
  BROWSER_TOOLS = [];
9971
9971
  });
9972
9972
 
@@ -145580,7 +145580,7 @@ var init_metadata = __esm(() => {
145580
145580
  });
145581
145581
 
145582
145582
  // src/buddy/types.ts
145583
- var RARITIES, c5, duck, goose, blob, cat, dragon, octopus, owl, penguin, turtle, snail, ghost, axolotl, capybara, cactus, robot, rabbit, mushroom, chonk, SPECIES, EYES, HATS, STAT_NAMES, RARITY_WEIGHTS;
145583
+ var RARITIES, c5, duck, goose, blob, cat, dragon, octopus, owl, penguin, turtle, snail, ghost, axolotl, capybara, cactus, robot, rabbit, mushroom, chonk, SPECIES, EYES, HATS, STAT_NAMES, RARITY_WEIGHTS, RARITY_STARS, RARITY_COLORS;
145584
145584
  var init_types4 = __esm(() => {
145585
145585
  RARITIES = [
145586
145586
  "common",
@@ -145653,6 +145653,20 @@ var init_types4 = __esm(() => {
145653
145653
  epic: 4,
145654
145654
  legendary: 1
145655
145655
  };
145656
+ RARITY_STARS = {
145657
+ common: "★",
145658
+ uncommon: "★★",
145659
+ rare: "★★★",
145660
+ epic: "★★★★",
145661
+ legendary: "★★★★★"
145662
+ };
145663
+ RARITY_COLORS = {
145664
+ common: "inactive",
145665
+ uncommon: "success",
145666
+ rare: "permission",
145667
+ epic: "autoAccept",
145668
+ legendary: "warning"
145669
+ };
145656
145670
  });
145657
145671
 
145658
145672
  // src/buddy/companion.ts
@@ -145760,6 +145774,28 @@ A small ${species} named ${name} sits beside the user's input box and occasional
145760
145774
 
145761
145775
  When the user addresses ${name} directly (by name), its bubble will answer. Your job in that moment is to stay out of the way: respond in ONE line or less, or just answer any part of the message meant for you. Don't explain that you're not ${name} — they know. Don't narrate what ${name} might say — the bubble handles that.`;
145762
145776
  }
145777
+ function getCompanionIntroAttachment(messages) {
145778
+ if (false)
145779
+ ;
145780
+ const companion = getCompanion();
145781
+ if (!companion || getGlobalConfig().companionMuted)
145782
+ return [];
145783
+ for (const msg of messages ?? []) {
145784
+ if (msg.type !== "attachment")
145785
+ continue;
145786
+ if (msg.attachment.type !== "companion_intro")
145787
+ continue;
145788
+ if (msg.attachment.name === companion.name)
145789
+ return [];
145790
+ }
145791
+ return [
145792
+ {
145793
+ type: "companion_intro",
145794
+ name: companion.name,
145795
+ species: companion.species
145796
+ }
145797
+ ];
145798
+ }
145763
145799
  var init_prompt4 = __esm(() => {
145764
145800
  init_config();
145765
145801
  init_companion();
@@ -290707,7 +290743,7 @@ var init_client6 = __esm(() => {
290707
290743
  logMCPDebug(name, `claude.ai proxy transport created successfully`);
290708
290744
  } else if ((serverRef.type === "stdio" || !serverRef.type) && isClaudeInChromeMCPServer(name)) {
290709
290745
  const { createChromeContext } = await Promise.resolve().then(() => (init_mcpServer(), exports_mcpServer));
290710
- const { createClaudeForChromeMcpServer: createClaudeForChromeMcpServer2 } = await Promise.resolve().then(() => (init_claude_for_chrome_mcp(), exports_claude_for_chrome_mcp));
290746
+ const { createClaudeForChromeMcpServer: createClaudeForChromeMcpServer2 } = await Promise.resolve().then(() => (init_ant_claude_for_chrome_mcp(), exports_ant_claude_for_chrome_mcp));
290711
290747
  const { createLinkedTransportPair: createLinkedTransportPair2 } = await Promise.resolve().then(() => exports_InProcessTransport);
290712
290748
  const context = createChromeContext(serverRef.env);
290713
290749
  inProcessServer = createClaudeForChromeMcpServer2(context);
@@ -347416,6 +347452,27 @@ import { access as access4 } from "fs/promises";
347416
347452
  import { tmpdir as osTmpdir } from "os";
347417
347453
  import { join as nativeJoin } from "path";
347418
347454
  import { join as posixJoin } from "path/posix";
347455
+ function createSpawnSemaphore(maxConcurrent) {
347456
+ let active = 0;
347457
+ const queue2 = [];
347458
+ return {
347459
+ async acquire() {
347460
+ if (active >= maxConcurrent) {
347461
+ await new Promise((resolve29) => queue2.push(resolve29));
347462
+ }
347463
+ active++;
347464
+ },
347465
+ release() {
347466
+ active--;
347467
+ const next = queue2.shift();
347468
+ if (next)
347469
+ next();
347470
+ }
347471
+ };
347472
+ }
347473
+ function getBashSpawnSemaphore() {
347474
+ return BASH_SPAWN_SEMAPHORE;
347475
+ }
347419
347476
  function getDisableExtglobCommand(shellPath) {
347420
347477
  if (process.env.CLAUDE_CODE_SHELL_PREFIX) {
347421
347478
  return "{ shopt -u extglob || setopt NO_EXTENDED_GLOB; } >/dev/null 2>&1 || true";
@@ -347509,6 +347566,15 @@ async function createBashShellProvider(shellPath, options) {
347509
347566
  env5.CLAUDE_CODE_TMPDIR = posixTmpDir;
347510
347567
  env5.TMPPREFIX = posixJoin(posixTmpDir, "zsh");
347511
347568
  }
347569
+ if (getPlatform() === "windows") {
347570
+ if (!env5.MSYS2_ARG_CONV_EXCL)
347571
+ env5.MSYS2_ARG_CONV_EXCL = "*";
347572
+ if (!env5.CHERE_INVOKING)
347573
+ env5.CHERE_INVOKING = "1";
347574
+ if (!env5.MSYSTEM && process.env.MSYSTEM) {
347575
+ env5.MSYSTEM = process.env.MSYSTEM;
347576
+ }
347577
+ }
347512
347578
  for (const [key2, value] of getSessionEnvVars()) {
347513
347579
  env5[key2] = value;
347514
347580
  }
@@ -347516,6 +347582,7 @@ async function createBashShellProvider(shellPath, options) {
347516
347582
  }
347517
347583
  };
347518
347584
  }
347585
+ var BASH_SPAWN_SEMAPHORE;
347519
347586
  var init_bashProvider = __esm(() => {
347520
347587
  init_bashPipeCommand();
347521
347588
  init_ShellSnapshot();
@@ -347528,6 +347595,7 @@ var init_bashProvider = __esm(() => {
347528
347595
  init_sessionEnvVars();
347529
347596
  init_tmuxSocket();
347530
347597
  init_windowsPaths();
347598
+ BASH_SPAWN_SEMAPHORE = createSpawnSemaphore(getPlatform() === "windows" ? 24 : Infinity);
347531
347599
  });
347532
347600
 
347533
347601
  // src/utils/shell/powershellDetection.ts
@@ -347754,6 +347822,10 @@ async function exec3(command, abortSignal, shellType, options) {
347754
347822
  const spawnBinary = isSandboxedPowerShell ? "/bin/sh" : binShell;
347755
347823
  const shellArgs = isSandboxedPowerShell ? ["-c", commandString] : provider.getSpawnArgs(commandString);
347756
347824
  const envOverrides = await provider.getEnvironmentOverrides(command);
347825
+ const isGitBash = shellType === "bash" && getPlatform() === "windows" && !isSandboxedPowerShell;
347826
+ if (isGitBash) {
347827
+ await getBashSpawnSemaphore().acquire();
347828
+ }
347757
347829
  const usePipeMode = !!onStdout;
347758
347830
  const taskId = generateTaskId("local_bash");
347759
347831
  const taskOutput = new TaskOutput(taskId, onProgress ?? null, !usePipeMode);
@@ -347780,6 +347852,9 @@ async function exec3(command, abortSignal, shellType, options) {
347780
347852
  detached: provider.detached,
347781
347853
  windowsHide: true
347782
347854
  });
347855
+ if (isGitBash) {
347856
+ childProcess.once("close", () => getBashSpawnSemaphore().release());
347857
+ }
347783
347858
  const shellCommand = wrapSpawn(childProcess, abortSignal, commandTimeout, taskOutput, shouldAutoBackground);
347784
347859
  if (outputHandle !== undefined) {
347785
347860
  try {
@@ -347819,6 +347894,9 @@ async function exec3(command, abortSignal, shellType, options) {
347819
347894
  });
347820
347895
  return shellCommand;
347821
347896
  } catch (error49) {
347897
+ if (isGitBash) {
347898
+ getBashSpawnSemaphore().release();
347899
+ }
347822
347900
  if (outputHandle !== undefined) {
347823
347901
  try {
347824
347902
  await outputHandle.close();
@@ -357194,7 +357272,7 @@ var init_color_diff = __esm(() => {
357194
357272
  };
357195
357273
  });
357196
357274
 
357197
- // node_modules/color-diff-napi/index.ts
357275
+ // shims/color-diff-napi/index.ts
357198
357276
  var init_color_diff_napi = __esm(() => {
357199
357277
  init_color_diff();
357200
357278
  });
@@ -387971,7 +388049,9 @@ async function getAttachments(input, toolUseContext, ideSelection, queuedCommand
387971
388049
  }))),
387972
388050
  maybe("agent_listing_delta", () => Promise.resolve(getAgentListingDeltaAttachment(toolUseContext, messages))),
387973
388051
  maybe("mcp_instructions_delta", () => Promise.resolve(getMcpInstructionsDeltaAttachment(toolUseContext.options.mcpClients, toolUseContext.options.tools, toolUseContext.options.mainLoopModel, messages))),
387974
- ...[],
388052
+ ...[
388053
+ maybe("companion_intro", () => Promise.resolve(getCompanionIntroAttachment(messages)))
388054
+ ],
387975
388055
  maybe("changed_files", () => getChangedFiles2(context)),
387976
388056
  maybe("nested_memory", () => getNestedMemoryAttachments(context)),
387977
388057
  maybe("dynamic_skill", () => getDynamicSkillAttachments(context)),
@@ -403040,7 +403120,7 @@ function prewarm() {
403040
403120
  var cachedModule = null;
403041
403121
  var init_modifiers_napi_src = () => {};
403042
403122
 
403043
- // node_modules/modifiers-napi/index.ts
403123
+ // shims/modifiers-napi/index.ts
403044
403124
  var exports_modifiers_napi = {};
403045
403125
  __export(exports_modifiers_napi, {
403046
403126
  prewarm: () => prewarm,
@@ -475596,6 +475676,732 @@ var init_summary = __esm(() => {
475596
475676
  summary_default = { isEnabled: () => false, isHidden: true, name: "stub" };
475597
475677
  });
475598
475678
 
475679
+ // src/achievements/storage.ts
475680
+ function getUnlockedAchievements() {
475681
+ const config5 = getGlobalConfig();
475682
+ return new Set(config5.unlockedAchievements ?? []);
475683
+ }
475684
+ function hasAchievement(id) {
475685
+ return getUnlockedAchievements().has(id);
475686
+ }
475687
+ function unlockAchievement(id) {
475688
+ const unlocked = getUnlockedAchievements();
475689
+ if (unlocked.has(id))
475690
+ return false;
475691
+ unlocked.add(id);
475692
+ saveGlobalConfig((current) => ({
475693
+ ...current,
475694
+ unlockedAchievements: [...unlocked]
475695
+ }));
475696
+ return true;
475697
+ }
475698
+ function incrementCounter(key2) {
475699
+ const config5 = getGlobalConfig();
475700
+ const counters = config5.achievementCounters ?? {};
475701
+ const current = (counters[key2] ?? 0) + 1;
475702
+ saveGlobalConfig((cfg) => ({
475703
+ ...cfg,
475704
+ achievementCounters: { ...counters, [key2]: current }
475705
+ }));
475706
+ return current;
475707
+ }
475708
+ var init_storage = __esm(() => {
475709
+ init_config();
475710
+ });
475711
+
475712
+ // src/achievements/types.ts
475713
+ function getAchievementsByCategory() {
475714
+ return CATEGORIES.map((cat2) => ({
475715
+ category: cat2,
475716
+ achievements: Object.values(ACHIEVEMENTS).filter((a2) => a2.category === cat2.key)
475717
+ }));
475718
+ }
475719
+ var ACHIEVEMENTS, CATEGORIES;
475720
+ var init_types14 = __esm(() => {
475721
+ ACHIEVEMENTS = {
475722
+ first_hatch: {
475723
+ id: "first_hatch",
475724
+ name: "New Friend",
475725
+ description: "Hatch your first companion",
475726
+ icon: "\uD83E\uDD5A",
475727
+ category: "onboarding"
475728
+ },
475729
+ first_commit: {
475730
+ id: "first_commit",
475731
+ name: "First Commit",
475732
+ description: "Generate your first git commit message",
475733
+ icon: "\uD83D\uDCDD",
475734
+ category: "onboarding"
475735
+ },
475736
+ first_review: {
475737
+ id: "first_review",
475738
+ name: "Code Reviewer",
475739
+ description: "Run your first code review",
475740
+ icon: "\uD83D\uDD0D",
475741
+ category: "onboarding"
475742
+ },
475743
+ first_plugin: {
475744
+ id: "first_plugin",
475745
+ name: "Extensible",
475746
+ description: "Install your first plugin",
475747
+ icon: "\uD83D\uDD0C",
475748
+ category: "onboarding"
475749
+ },
475750
+ first_skill: {
475751
+ id: "first_skill",
475752
+ name: "Skillful",
475753
+ description: "Use your first skill command",
475754
+ icon: "\uD83C\uDFAF",
475755
+ category: "onboarding"
475756
+ },
475757
+ streak_3: {
475758
+ id: "streak_3",
475759
+ name: "Getting Started",
475760
+ description: "Use myclaude for 3 consecutive days",
475761
+ icon: "\uD83D\uDD25",
475762
+ category: "streak"
475763
+ },
475764
+ streak_7: {
475765
+ id: "streak_7",
475766
+ name: "Week Warrior",
475767
+ description: "Use myclaude for 7 consecutive days",
475768
+ icon: "\uD83D\uDD25",
475769
+ category: "streak"
475770
+ },
475771
+ streak_30: {
475772
+ id: "streak_30",
475773
+ name: "Dedicated",
475774
+ description: "Use myclaude for 30 consecutive days",
475775
+ icon: "\uD83D\uDD25",
475776
+ category: "streak"
475777
+ },
475778
+ commits_10: {
475779
+ id: "commits_10",
475780
+ name: "Regular Committer",
475781
+ description: "Generate 10 commit messages",
475782
+ icon: "\uD83D\uDCDD",
475783
+ category: "usage"
475784
+ },
475785
+ commits_100: {
475786
+ id: "commits_100",
475787
+ name: "Commit Machine",
475788
+ description: "Generate 100 commit messages",
475789
+ icon: "\uD83D\uDE80",
475790
+ category: "usage"
475791
+ },
475792
+ chat_100: {
475793
+ id: "chat_100",
475794
+ name: "Conversationalist",
475795
+ description: "Send 100 messages in chat",
475796
+ icon: "\uD83D\uDCAC",
475797
+ category: "usage"
475798
+ },
475799
+ chat_1000: {
475800
+ id: "chat_1000",
475801
+ name: "Power User",
475802
+ description: "Send 1000 messages in chat",
475803
+ icon: "\uD83D\uDCAC",
475804
+ category: "usage"
475805
+ },
475806
+ model_switched: {
475807
+ id: "model_switched",
475808
+ name: "Model Hopper",
475809
+ description: "Switch AI model at least once",
475810
+ icon: "\uD83D\uDD04",
475811
+ category: "usage"
475812
+ },
475813
+ config_changed: {
475814
+ id: "config_changed",
475815
+ name: "Tinkerer",
475816
+ description: "Change a configuration setting",
475817
+ icon: "⚙️",
475818
+ category: "usage"
475819
+ },
475820
+ buddy_hatched: {
475821
+ id: "buddy_hatched",
475822
+ name: "Buddy Up",
475823
+ description: "Hatch a companion",
475824
+ icon: "\uD83D\uDC23",
475825
+ category: "buddy"
475826
+ },
475827
+ buddy_pet_10: {
475828
+ id: "buddy_pet_10",
475829
+ name: "Pet Lover",
475830
+ description: "Pet your companion 10 times",
475831
+ icon: "\uD83D\uDD90️",
475832
+ category: "buddy"
475833
+ },
475834
+ buddy_pet_100: {
475835
+ id: "buddy_pet_100",
475836
+ name: "Best Friend",
475837
+ description: "Pet your companion 100 times",
475838
+ icon: "\uD83D\uDC96",
475839
+ category: "buddy"
475840
+ },
475841
+ buddy_legendary: {
475842
+ id: "buddy_legendary",
475843
+ name: "Legendary Bond",
475844
+ description: "Hatch a legendary companion (1% chance)",
475845
+ icon: "⭐",
475846
+ category: "buddy"
475847
+ },
475848
+ buddy_shiny: {
475849
+ id: "buddy_shiny",
475850
+ name: "Shiny Hunter",
475851
+ description: "Hatch a shiny companion (1% chance)",
475852
+ icon: "✨",
475853
+ category: "buddy"
475854
+ },
475855
+ mcp_added: {
475856
+ id: "mcp_added",
475857
+ name: "Plugin Architect",
475858
+ description: "Add an MCP server",
475859
+ icon: "\uD83D\uDD17",
475860
+ category: "power"
475861
+ }
475862
+ };
475863
+ CATEGORIES = [
475864
+ { key: "onboarding", label: "Getting Started", icon: "\uD83C\uDF1F" },
475865
+ { key: "usage", label: "Usage", icon: "\uD83D\uDCCA" },
475866
+ { key: "streak", label: "Streaks", icon: "\uD83D\uDD25" },
475867
+ { key: "buddy", label: "Buddy", icon: "\uD83D\uDC3E" },
475868
+ { key: "power", label: "Power", icon: "⚡" }
475869
+ ];
475870
+ });
475871
+
475872
+ // src/commands/achievements/achievements.ts
475873
+ var exports_achievements = {};
475874
+ __export(exports_achievements, {
475875
+ call: () => call57
475876
+ });
475877
+ function handleSummary() {
475878
+ const unlocked = getUnlockedAchievements();
475879
+ const total = Object.keys(ACHIEVEMENTS).length;
475880
+ const unlockedCount = unlocked.size;
475881
+ const pct = Math.round(unlockedCount / total * 100);
475882
+ const lines2 = [
475883
+ "╔══════════════════════════════╗",
475884
+ "║ Achievements ║",
475885
+ `║ ${String(unlockedCount).padStart(2)} / ${total} (${pct}%) ║`,
475886
+ "╚══════════════════════════════╝",
475887
+ ""
475888
+ ];
475889
+ for (const group of getAchievementsByCategory()) {
475890
+ const unlockedInGroup = group.achievements.filter((a2) => unlocked.has(a2.id));
475891
+ if (unlockedInGroup.length === 0)
475892
+ continue;
475893
+ lines2.push(`${group.category.icon} ${group.category.label}:`);
475894
+ for (const a2 of unlockedInGroup) {
475895
+ lines2.push(` ${a2.icon} ${a2.name} — ${a2.description}`);
475896
+ }
475897
+ lines2.push("");
475898
+ }
475899
+ if (unlockedCount === 0) {
475900
+ lines2.push(" No achievements yet! Try using myclaude to unlock some.");
475901
+ lines2.push("");
475902
+ }
475903
+ lines2.push(`Use /achievements list to see all ${total} achievements.`);
475904
+ return { type: "text", value: lines2.join(`
475905
+ `) };
475906
+ }
475907
+ function handleListAll() {
475908
+ const unlocked = getUnlockedAchievements();
475909
+ const total = Object.keys(ACHIEVEMENTS).length;
475910
+ const unlockedCount = unlocked.size;
475911
+ const lines2 = [
475912
+ `All Achievements (${unlockedCount}/${total}):`,
475913
+ ""
475914
+ ];
475915
+ for (const group of getAchievementsByCategory()) {
475916
+ lines2.push(`${group.category.icon} ${group.category.label}:`);
475917
+ for (const a2 of group.achievements) {
475918
+ const done = unlocked.has(a2.id);
475919
+ lines2.push(` ${done ? "✅" : "⬜"} ${a2.icon} ${a2.name}`);
475920
+ lines2.push(` ${a2.description}`);
475921
+ }
475922
+ lines2.push("");
475923
+ }
475924
+ return { type: "text", value: lines2.join(`
475925
+ `) };
475926
+ }
475927
+ var call57 = async (args) => {
475928
+ const sub = args.trim().toLowerCase();
475929
+ if (sub === "list" || sub === "all") {
475930
+ return handleListAll();
475931
+ }
475932
+ return handleSummary();
475933
+ };
475934
+ var init_achievements = __esm(() => {
475935
+ init_storage();
475936
+ init_types14();
475937
+ });
475938
+
475939
+ // src/commands/achievements/index.ts
475940
+ var achievementsCmd, achievements_default;
475941
+ var init_achievements2 = __esm(() => {
475942
+ achievementsCmd = {
475943
+ name: "achievements",
475944
+ description: "View your unlocked achievements and progress",
475945
+ aliases: ["achieve", "ach"],
475946
+ supportsNonInteractive: false,
475947
+ type: "local",
475948
+ load: () => Promise.resolve().then(() => (init_achievements(), exports_achievements))
475949
+ };
475950
+ achievements_default = achievementsCmd;
475951
+ });
475952
+
475953
+ // src/stats/usageStats.ts
475954
+ function getUsageStats() {
475955
+ return getGlobalConfig().usageStats ?? DEFAULT_STATS;
475956
+ }
475957
+ function saveStats(update) {
475958
+ const current = getUsageStats();
475959
+ const next = { ...current, ...update };
475960
+ saveGlobalConfig((cfg) => ({ ...cfg, usageStats: next }));
475961
+ return next;
475962
+ }
475963
+ function trackBuddyInteraction() {
475964
+ const stats = getUsageStats();
475965
+ saveStats({ totalBuddyInteractions: stats.totalBuddyInteractions + 1 });
475966
+ }
475967
+ var DEFAULT_STATS;
475968
+ var init_usageStats = __esm(() => {
475969
+ init_config();
475970
+ DEFAULT_STATS = {
475971
+ firstUsedAt: Date.now(),
475972
+ totalSessions: 0,
475973
+ totalCommands: 0,
475974
+ totalCommits: 0,
475975
+ totalReviews: 0,
475976
+ totalChatMessages: 0,
475977
+ totalPluginsInstalled: 0,
475978
+ totalSkillsUsed: 0,
475979
+ totalBuddyInteractions: 0,
475980
+ lastActiveDate: new Date().toISOString().slice(0, 10),
475981
+ consecutiveDays: 1,
475982
+ languagesUsed: []
475983
+ };
475984
+ });
475985
+
475986
+ // src/buddy/milestones.ts
475987
+ function getMilestones() {
475988
+ return getGlobalConfig().buddyMilestones ?? [];
475989
+ }
475990
+ function addMilestone(type) {
475991
+ const milestones = getMilestones();
475992
+ if (milestones.some((m2) => m2.type === type))
475993
+ return false;
475994
+ const def = MILESTONE_DEFS[type];
475995
+ const milestone = { type, ...def, achievedAt: Date.now() };
475996
+ saveGlobalConfig((cfg) => ({
475997
+ ...cfg,
475998
+ buddyMilestones: [...milestones, milestone].sort((a2, b3) => a2.achievedAt - b3.achievedAt)
475999
+ }));
476000
+ return true;
476001
+ }
476002
+ function formatMilestones() {
476003
+ const milestones = getMilestones();
476004
+ if (milestones.length === 0)
476005
+ return "No milestones yet.";
476006
+ return milestones.map((m2) => {
476007
+ const date6 = new Date(m2.achievedAt);
476008
+ const dateStr = `${date6.getFullYear()}-${String(date6.getMonth() + 1).padStart(2, "0")}-${String(date6.getDate()).padStart(2, "0")}`;
476009
+ return ` ${m2.icon} ${m2.label} (${dateStr})`;
476010
+ }).join(`
476011
+ `);
476012
+ }
476013
+ var MILESTONE_DEFS;
476014
+ var init_milestones = __esm(() => {
476015
+ init_config();
476016
+ MILESTONE_DEFS = {
476017
+ first_hatch: { label: "First companion hatched", icon: "\uD83E\uDD5A" },
476018
+ first_commit: { label: "First AI commit", icon: "\uD83D\uDCDD" },
476019
+ first_review: { label: "First code review", icon: "\uD83D\uDD0D" },
476020
+ first_plugin: { label: "First plugin installed", icon: "\uD83D\uDD0C" },
476021
+ first_skill: { label: "First skill used", icon: "\uD83C\uDFAF" },
476022
+ level_5: { label: "Buddy reached level 5", icon: "⭐" },
476023
+ level_10: { label: "Buddy reached level 10", icon: "\uD83C\uDF1F" },
476024
+ level_25: { label: "Buddy reached level 25", icon: "\uD83D\uDCAB" },
476025
+ level_50: { label: "Buddy reached max level 50", icon: "\uD83D\uDC51" },
476026
+ streak_7: { label: "7-day streak achieved", icon: "\uD83D\uDD25" },
476027
+ streak_30: { label: "30-day streak achieved", icon: "\uD83D\uDD25" },
476028
+ achievement_5: { label: "5 achievements unlocked", icon: "\uD83C\uDFC6" },
476029
+ achievement_10: { label: "10 achievements unlocked", icon: "\uD83C\uDFC6" },
476030
+ achievement_20: { label: "All achievements unlocked", icon: "\uD83C\uDFC6" },
476031
+ commits_10: { label: "10 commits generated", icon: "\uD83D\uDCDD" },
476032
+ commits_100: { label: "100 commits generated", icon: "\uD83D\uDE80" },
476033
+ pet_50: { label: "50 times pet your buddy", icon: "\uD83D\uDD90️" },
476034
+ pet_100: { label: "100 times pet your buddy", icon: "\uD83D\uDC96" }
476035
+ };
476036
+ });
476037
+
476038
+ // src/buddy/evolution/index.ts
476039
+ function getBuddyState() {
476040
+ return getGlobalConfig().buddyState ?? DEFAULT_STATE;
476041
+ }
476042
+ function saveBuddyState(update) {
476043
+ const current = getBuddyState();
476044
+ const next = { ...current, ...update };
476045
+ saveGlobalConfig((cfg) => ({ ...cfg, buddyState: next }));
476046
+ return next;
476047
+ }
476048
+ function getLevel() {
476049
+ return getBuddyState().level;
476050
+ }
476051
+ function getXp() {
476052
+ return getBuddyState().xp;
476053
+ }
476054
+ function getXpForNextLevel() {
476055
+ const state = getBuddyState();
476056
+ return state.level * XP_PER_LEVEL;
476057
+ }
476058
+ function getEvolutionStage() {
476059
+ return getBuddyState().evolutionStage;
476060
+ }
476061
+ function addXp(amount) {
476062
+ const events2 = [];
476063
+ let state = getBuddyState();
476064
+ let newXp = state.xp + amount;
476065
+ while (newXp >= state.level * XP_PER_LEVEL && state.level < MAX_LEVEL) {
476066
+ newXp -= state.level * XP_PER_LEVEL;
476067
+ state.level++;
476068
+ events2.push({ type: "level_up", level: state.level });
476069
+ const newStage = getEvolutionForLevel(state.level, state.evolutionStage);
476070
+ if (newStage > state.evolutionStage) {
476071
+ state.evolutionStage = newStage;
476072
+ events2.push({ type: "evolution", stage: newStage });
476073
+ }
476074
+ if (state.level === 5)
476075
+ addMilestone("level_5");
476076
+ if (state.level === 10)
476077
+ addMilestone("level_10");
476078
+ if (state.level === 25)
476079
+ addMilestone("level_25");
476080
+ if (state.level === 50)
476081
+ addMilestone("level_50");
476082
+ }
476083
+ state.xp = Math.min(newXp, MAX_LEVEL * XP_PER_LEVEL);
476084
+ state = saveBuddyState(state);
476085
+ return events2;
476086
+ }
476087
+ function getEvolutionForLevel(level, currentStage) {
476088
+ const companion = getCompanion();
476089
+ if (!companion)
476090
+ return 0;
476091
+ const rule = EVOLUTIONS.find((e) => e.base === companion.species);
476092
+ if (!rule)
476093
+ return 0;
476094
+ if (currentStage < 1 && level >= rule.level)
476095
+ return 1;
476096
+ if (currentStage < 2 && level >= rule.maxLevel)
476097
+ return 2;
476098
+ return currentStage;
476099
+ }
476100
+ function getEvolvedSpecies(species, stage) {
476101
+ if (stage === 0)
476102
+ return species;
476103
+ const rule = EVOLUTIONS.find((e) => e.base === species);
476104
+ if (!rule)
476105
+ return species;
476106
+ return stage >= 2 ? rule.maxEvolved : rule.evolved;
476107
+ }
476108
+ function incrementFeed() {
476109
+ const state = getBuddyState();
476110
+ const count4 = state.feedCount + 1;
476111
+ saveBuddyState({ feedCount: count4 });
476112
+ return count4;
476113
+ }
476114
+ function incrementPlay() {
476115
+ const state = getBuddyState();
476116
+ const count4 = state.playCount + 1;
476117
+ saveBuddyState({ playCount: count4 });
476118
+ return count4;
476119
+ }
476120
+ function getInteractionCounts() {
476121
+ const state = getBuddyState();
476122
+ return { feed: state.feedCount, play: state.playCount };
476123
+ }
476124
+ var XP_PER_LEVEL = 100, MAX_LEVEL = 50, DEFAULT_STATE, EVOLUTIONS, XP_REWARDS;
476125
+ var init_evolution = __esm(() => {
476126
+ init_config();
476127
+ init_companion();
476128
+ init_milestones();
476129
+ DEFAULT_STATE = {
476130
+ xp: 0,
476131
+ level: 1,
476132
+ evolutionStage: 0,
476133
+ feedCount: 0,
476134
+ playCount: 0
476135
+ };
476136
+ EVOLUTIONS = [
476137
+ { base: "duck", evolved: "goose", maxEvolved: "goose", level: 10, maxLevel: 25 },
476138
+ { base: "blob", evolved: "ghost", maxEvolved: "ghost", level: 10, maxLevel: 25 },
476139
+ { base: "cat", evolved: "chonk", maxEvolved: "chonk", level: 12, maxLevel: 28 },
476140
+ { base: "turtle", evolved: "snail", maxEvolved: "snail", level: 15, maxLevel: 30 }
476141
+ ];
476142
+ XP_REWARDS = {
476143
+ BUDDY_HATCH: 50,
476144
+ BUDDY_PET: 5,
476145
+ BUDDY_FEED: 15,
476146
+ BUDDY_PLAY: 20,
476147
+ COMMIT: 10,
476148
+ REVIEW: 25,
476149
+ PLUGIN_INSTALL: 30,
476150
+ SKILL_USE: 5,
476151
+ DAILY_LOGIN: 20,
476152
+ ACHIEVEMENT_UNLOCK: 100
476153
+ };
476154
+ });
476155
+
476156
+ // src/skills/suggestions.ts
476157
+ function getSuggestions(maxCount = 5) {
476158
+ const stats = getUsageStats();
476159
+ const level = getLevel();
476160
+ const unlocked = getUnlockedAchievements();
476161
+ const usedCommands = new Set([
476162
+ ...stats.languagesUsed
476163
+ ]);
476164
+ const scored = ALL_SKILLS.map((skill) => {
476165
+ let score = skill.priority;
476166
+ if (stats.totalSessions > 20)
476167
+ score += 10;
476168
+ if (stats.totalSessions > 50)
476169
+ score += 10;
476170
+ if (level > 5)
476171
+ score += 15;
476172
+ if (unlocked.size > 5)
476173
+ score += 10;
476174
+ if (unlocked.size > 10)
476175
+ score += 10;
476176
+ return { ...skill, score };
476177
+ });
476178
+ return scored.sort((a2, b3) => b3.score - a2.score).slice(0, maxCount).map(({ score, ...skill }) => skill);
476179
+ }
476180
+ var ALL_SKILLS;
476181
+ var init_suggestions = __esm(() => {
476182
+ init_usageStats();
476183
+ init_storage();
476184
+ init_evolution();
476185
+ ALL_SKILLS = [
476186
+ { command: "/commit", description: "Generate git commit messages with AI", reason: "You use git — let AI write your commit messages", priority: 90 },
476187
+ { command: "/review", description: "Review code changes with AI analysis", reason: "Improve code quality with automated reviews", priority: 85 },
476188
+ { command: "/plan", description: "Create step-by-step implementation plans", reason: "Plan before you code — reduce rework", priority: 80 },
476189
+ { command: "/test", description: "Generate and run tests", reason: "Keep your code reliable with automated tests", priority: 75 },
476190
+ { command: "/doc", description: "Generate documentation from code", reason: "Good docs make great projects", priority: 70 },
476191
+ { command: "/diff", description: "Review git diff with explanations", reason: "Understand every change before committing", priority: 65 },
476192
+ { command: "/branch", description: "Manage git branches", reason: "Organize your work with branching", priority: 60 },
476193
+ { command: "/config", description: "Configure myclaude settings", reason: "Tailor myclaude to your workflow", priority: 55 },
476194
+ { command: "/mcp add", description: "Add MCP servers for external tools", reason: "Connect myclaude to databases, APIs, and more", priority: 50 },
476195
+ { command: "/plugin", description: "Install community plugins", reason: "Extend myclaude with community tools", priority: 45 },
476196
+ { command: "/buddy pet", description: "Pet your companion for XP", reason: "Earn XP and bond with your buddy!", priority: 40 },
476197
+ { command: "/buddy feed", description: "Feed your companion for XP", reason: "Your buddy is hungry! +15 XP", priority: 35 },
476198
+ { command: "/buddy play", description: "Play with your companion for XP", reason: "Playtime! +20 XP for you and your buddy", priority: 30 },
476199
+ { command: "/achievements", description: "View unlocked achievements", reason: "See what you've accomplished", priority: 25 },
476200
+ { command: "/mystats", description: "View usage dashboard", reason: "Track your myclaude journey", priority: 20 },
476201
+ { command: "/memory", description: "Manage AI memory", reason: "Help myclaude remember important context", priority: 15 },
476202
+ { command: "/sandbox", description: "Toggle sandbox mode for safe execution", reason: "Execute commands in a safe environment", priority: 10 },
476203
+ { command: "/theme", description: "Change terminal theme", reason: "Make myclaude look the way you like", priority: 5 },
476204
+ { command: "/effort", description: "Adjust AI effort level", reason: "Control how thorough the AI should be", priority: 3 },
476205
+ { command: "/summary", description: "Summarize current session", reason: "Quick recap of what you've done", priority: 1 }
476206
+ ];
476207
+ });
476208
+
476209
+ // src/stats/tips.ts
476210
+ function getRandomTip() {
476211
+ const config5 = getGlobalConfig();
476212
+ const shown = new Set(config5.shownTips ?? []);
476213
+ const available = TIPS.filter((t) => !shown.has(t.id) && t.condition()).sort((a2, b3) => b3.priority - a2.priority);
476214
+ if (available.length === 0)
476215
+ return null;
476216
+ const tip = available[0];
476217
+ saveGlobalConfig((cfg) => ({
476218
+ ...cfg,
476219
+ shownTips: [...cfg.shownTips ?? [], tip.id]
476220
+ }));
476221
+ return tip.message;
476222
+ }
476223
+ var TIPS;
476224
+ var init_tips = __esm(() => {
476225
+ init_config();
476226
+ init_evolution();
476227
+ init_companion();
476228
+ init_storage();
476229
+ init_usageStats();
476230
+ TIPS = [
476231
+ {
476232
+ id: "welcome_buddy",
476233
+ message: "\uD83D\uDC3E Tip: You have a companion! Try /buddy pet, /buddy feed, or /buddy play to earn XP.",
476234
+ condition: () => !!getCompanion(),
476235
+ priority: 100
476236
+ },
476237
+ {
476238
+ id: "try_achievements",
476239
+ message: "\uD83C\uDFC6 Tip: Check your achievements with /achievements to see what you can unlock!",
476240
+ condition: () => getUnlockedAchievements().size < 3,
476241
+ priority: 90
476242
+ },
476243
+ {
476244
+ id: "try_mystats",
476245
+ message: "\uD83D\uDCCA Tip: View your usage dashboard with /mystats to track your progress.",
476246
+ condition: () => getUsageStats().totalSessions >= 3,
476247
+ priority: 80
476248
+ },
476249
+ {
476250
+ id: "buddy_feed",
476251
+ message: "\uD83C\uDF7D️ Tip: Your buddy looks hungry! Try /buddy feed for +15 XP.",
476252
+ condition: () => {
476253
+ const c6 = getCompanion();
476254
+ return !!c6 && getLevel() < 5;
476255
+ },
476256
+ priority: 70
476257
+ },
476258
+ {
476259
+ id: "buddy_play",
476260
+ message: "\uD83C\uDFBE Tip: Your buddy wants to play! Try /buddy play for +20 XP.",
476261
+ condition: () => {
476262
+ const c6 = getCompanion();
476263
+ return !!c6 && getLevel() >= 3 && getLevel() < 10;
476264
+ },
476265
+ priority: 60
476266
+ },
476267
+ {
476268
+ id: "buddy_evolution",
476269
+ message: "✨ Tip: Keep leveling up your buddy! It may evolve at higher levels.",
476270
+ condition: () => {
476271
+ const c6 = getCompanion();
476272
+ return !!c6 && getLevel() >= 8 && getLevel() < 12;
476273
+ },
476274
+ priority: 50
476275
+ },
476276
+ {
476277
+ id: "streak_reminder",
476278
+ message: "\uD83D\uDD25 Tip: You're on a streak! Come back tomorrow to keep it going.",
476279
+ condition: () => {
476280
+ const s = getUsageStats();
476281
+ return s.consecutiveDays >= 3 && s.consecutiveDays < 7;
476282
+ },
476283
+ priority: 40
476284
+ },
476285
+ {
476286
+ id: "plugin_tip",
476287
+ message: "\uD83D\uDD0C Tip: Extend myclaude with plugins! Try /plugin search to find new tools.",
476288
+ condition: () => getUsageStats().totalPluginsInstalled === 0 && getUsageStats().totalSessions >= 5,
476289
+ priority: 30
476290
+ },
476291
+ {
476292
+ id: "skill_tip",
476293
+ message: "\uD83C\uDFAF Tip: Use /skills to see available skill commands that can automate tasks.",
476294
+ condition: () => getUsageStats().totalSkillsUsed === 0 && getUsageStats().totalSessions >= 3,
476295
+ priority: 20
476296
+ },
476297
+ {
476298
+ id: "mcp_tip",
476299
+ message: "\uD83D\uDD17 Tip: Add MCP servers with /mcp add to integrate external tools and APIs.",
476300
+ condition: () => getUsageStats().totalSessions >= 10 && getUsageStats().totalPluginsInstalled > 0,
476301
+ priority: 10
476302
+ }
476303
+ ];
476304
+ });
476305
+
476306
+ // src/commands/mystats/mystats.ts
476307
+ var exports_mystats = {};
476308
+ __export(exports_mystats, {
476309
+ call: () => call58
476310
+ });
476311
+ var call58 = async () => {
476312
+ const stats = getUsageStats();
476313
+ const companion = getCompanion();
476314
+ const unlocked = getUnlockedAchievements();
476315
+ const daysActive = Math.max(1, Math.floor((Date.now() - stats.firstUsedAt) / 86400000));
476316
+ const hoursSince = Math.floor((Date.now() - stats.firstUsedAt) / 3600000);
476317
+ const lines2 = [
476318
+ "╔══════════════════════════════╗",
476319
+ "║ myclaude Dashboard ║",
476320
+ "╚══════════════════════════════╝",
476321
+ ""
476322
+ ];
476323
+ lines2.push("\uD83D\uDCCA Usage:");
476324
+ lines2.push(` Active days: ${daysActive}d (${hoursSince}h since first use)`);
476325
+ lines2.push(` Sessions: ${stats.totalSessions}`);
476326
+ lines2.push(` Commands run: ${stats.totalCommands}`);
476327
+ lines2.push(` Chat messages: ${stats.totalChatMessages}`);
476328
+ lines2.push(` Commits: ${stats.totalCommits}`);
476329
+ lines2.push(` Reviews: ${stats.totalReviews}`);
476330
+ lines2.push(` Plugins: ${stats.totalPluginsInstalled}`);
476331
+ lines2.push(` Skills used: ${stats.totalSkillsUsed}`);
476332
+ lines2.push(` Streak: \uD83D\uDD25 ${stats.consecutiveDays} days`);
476333
+ if (stats.languagesUsed.length > 0) {
476334
+ lines2.push(` Languages: ${stats.languagesUsed.join(", ")}`);
476335
+ }
476336
+ lines2.push("");
476337
+ lines2.push(`\uD83C\uDFC6 Achievements: ${unlocked.size}/${Object.keys(ACHIEVEMENTS).length} unlocked`);
476338
+ lines2.push("");
476339
+ if (companion) {
476340
+ const level = getLevel();
476341
+ const xp = getXp();
476342
+ const xpNext = getXpForNextLevel();
476343
+ const stage = getEvolutionStage();
476344
+ const { feed, play } = getInteractionCounts();
476345
+ const pct = Math.round(xp / xpNext * 100);
476346
+ lines2.push(`\uD83D\uDC3E Buddy: ${companion.name} (${companion.species})`);
476347
+ lines2.push(` Level: ${level} (${xp}/${xpNext} XP, ${pct}%)`);
476348
+ if (stage > 0)
476349
+ lines2.push(` Evolution: Stage ${stage} ✨`);
476350
+ lines2.push(` Interactions: ${stats.totalBuddyInteractions} total`);
476351
+ lines2.push(` Feed: ${feed}x | Play: ${play}x`);
476352
+ lines2.push("");
476353
+ }
476354
+ lines2.push("\uD83D\uDCA1 Tips:");
476355
+ if (stats.consecutiveDays >= 7) {
476356
+ lines2.push(" \uD83D\uDD25 You're on a hot streak! Keep it up!");
476357
+ }
476358
+ if (companion && getLevel() < 10) {
476359
+ lines2.push(" \uD83D\uDC3E Pet, feed and play with your buddy to earn XP!");
476360
+ }
476361
+ if (unlocked.size < 5) {
476362
+ lines2.push(" \uD83C\uDFC6 Try /achievements to see what you can unlock!");
476363
+ }
476364
+ const tip = getRandomTip();
476365
+ if (tip) {
476366
+ lines2.push("");
476367
+ lines2.push(` ${tip}`);
476368
+ }
476369
+ const suggestions = getSuggestions(4);
476370
+ if (suggestions.length > 0) {
476371
+ lines2.push("");
476372
+ lines2.push("\uD83C\uDFAF Suggested for you:");
476373
+ for (const s of suggestions) {
476374
+ lines2.push(` ${s.command.padEnd(18)} ${s.description}`);
476375
+ }
476376
+ }
476377
+ lines2.push("");
476378
+ return { type: "text", value: lines2.join(`
476379
+ `) };
476380
+ };
476381
+ var init_mystats = __esm(() => {
476382
+ init_usageStats();
476383
+ init_evolution();
476384
+ init_companion();
476385
+ init_storage();
476386
+ init_types14();
476387
+ init_suggestions();
476388
+ init_tips();
476389
+ });
476390
+
476391
+ // src/commands/mystats/index.ts
476392
+ var mystatsCmd, mystats_default;
476393
+ var init_mystats2 = __esm(() => {
476394
+ mystatsCmd = {
476395
+ name: "mystats",
476396
+ description: "View your coding statistics and usage dashboard",
476397
+ aliases: ["stats", "dashboard"],
476398
+ supportsNonInteractive: false,
476399
+ type: "local",
476400
+ load: () => Promise.resolve().then(() => (init_mystats(), exports_mystats))
476401
+ };
476402
+ mystats_default = mystatsCmd;
476403
+ });
476404
+
475599
476405
  // src/commands/reset-limits/index.js
475600
476406
  var stub, resetLimits, resetLimitsNonInteractive;
475601
476407
  var init_reset_limits = __esm(() => {
@@ -476745,10 +477551,10 @@ var init_SandboxSettings = __esm(() => {
476745
477551
  // src/commands/sandbox-toggle/sandbox-toggle.tsx
476746
477552
  var exports_sandbox_toggle = {};
476747
477553
  __export(exports_sandbox_toggle, {
476748
- call: () => call57
477554
+ call: () => call59
476749
477555
  });
476750
477556
  import { relative as relative28 } from "path";
476751
- async function call57(onDone, _context, args) {
477557
+ async function call59(onDone, _context, args) {
476752
477558
  const settings = getSettings_DEPRECATED();
476753
477559
  const themeName = settings.theme || "light";
476754
477560
  const platform5 = getPlatform();
@@ -477113,7 +477919,7 @@ async function isChromeExtensionInstalled() {
477113
477919
  }
477114
477920
  var CHROME_EXTENSION_RECONNECT_URL = "https://clau.de/chrome/reconnect", NATIVE_HOST_IDENTIFIER = "com.anthropic.claude_code_browser_extension", NATIVE_HOST_MANIFEST_NAME, shouldAutoEnable = undefined;
477115
477921
  var init_setup2 = __esm(() => {
477116
- init_claude_for_chrome_mcp();
477922
+ init_ant_claude_for_chrome_mcp();
477117
477923
  init_state();
477118
477924
  init_growthbook();
477119
477925
  init_config();
@@ -477130,7 +477936,7 @@ var init_setup2 = __esm(() => {
477130
477936
  // src/commands/chrome/chrome.tsx
477131
477937
  var exports_chrome = {};
477132
477938
  __export(exports_chrome, {
477133
- call: () => call58
477939
+ call: () => call60
477134
477940
  });
477135
477941
  function ClaudeInChromeMenu(t0) {
477136
477942
  const $3 = import_compiler_runtime267.c(41);
@@ -477497,7 +478303,7 @@ function _temp271(c6) {
477497
478303
  function _temp159(s) {
477498
478304
  return s.mcp.clients;
477499
478305
  }
477500
- var import_compiler_runtime267, import_react187, jsx_dev_runtime340, CHROME_EXTENSION_URL = "https://claude.ai/chrome", CHROME_PERMISSIONS_URL = "https://clau.de/chrome/permissions", CHROME_RECONNECT_URL = "https://clau.de/chrome/reconnect", call58 = async function(onDone) {
478306
+ var import_compiler_runtime267, import_react187, jsx_dev_runtime340, CHROME_EXTENSION_URL = "https://claude.ai/chrome", CHROME_PERMISSIONS_URL = "https://clau.de/chrome/permissions", CHROME_RECONNECT_URL = "https://clau.de/chrome/reconnect", call60 = async function(onDone) {
477501
478307
  const isExtensionInstalled = await isChromeExtensionInstalled();
477502
478308
  const config5 = getGlobalConfig();
477503
478309
  const isSubscriber = isClaudeAISubscriber();
@@ -477545,9 +478351,9 @@ var init_chrome2 = __esm(() => {
477545
478351
  // src/commands/stickers/stickers.ts
477546
478352
  var exports_stickers = {};
477547
478353
  __export(exports_stickers, {
477548
- call: () => call59
478354
+ call: () => call61
477549
478355
  });
477550
- async function call59() {
478356
+ async function call61() {
477551
478357
  const url3 = "https://www.stickermule.com/claudecode";
477552
478358
  const success2 = await openBrowser(url3);
477553
478359
  if (success2) {
@@ -477577,7 +478383,7 @@ var init_stickers2 = __esm(() => {
477577
478383
  });
477578
478384
 
477579
478385
  // src/commands/advisor.ts
477580
- var call60 = async (args, context2) => {
478386
+ var call62 = async (args, context2) => {
477581
478387
  const arg = args.trim().toLowerCase();
477582
478388
  const baseModel = parseUserSpecifiedModel(context2.getAppState().mainLoopModel ?? getDefaultMainLoopModelSetting());
477583
478389
  if (!arg) {
@@ -477663,7 +478469,7 @@ var init_advisor2 = __esm(() => {
477663
478469
  return !canUserConfigureAdvisor();
477664
478470
  },
477665
478471
  supportsNonInteractive: true,
477666
- load: () => Promise.resolve({ call: call60 })
478472
+ load: () => Promise.resolve({ call: call62 })
477667
478473
  };
477668
478474
  advisor_default = advisor;
477669
478475
  });
@@ -478077,12 +478883,12 @@ var init_ExitFlow = __esm(() => {
478077
478883
  // src/commands/exit/exit.tsx
478078
478884
  var exports_exit = {};
478079
478885
  __export(exports_exit, {
478080
- call: () => call61
478886
+ call: () => call63
478081
478887
  });
478082
478888
  function getRandomGoodbyeMessage2() {
478083
478889
  return sample_default(GOODBYE_MESSAGES2) ?? "Goodbye!";
478084
478890
  }
478085
- async function call61(onDone) {
478891
+ async function call63(onDone) {
478086
478892
  if (false) {}
478087
478893
  const showWorktree = getCurrentWorktreeSession() !== null;
478088
478894
  if (showWorktree) {
@@ -478376,7 +479182,7 @@ var exports_export = {};
478376
479182
  __export(exports_export, {
478377
479183
  sanitizeFilename: () => sanitizeFilename,
478378
479184
  extractFirstPrompt: () => extractFirstPrompt,
478379
- call: () => call62
479185
+ call: () => call64
478380
479186
  });
478381
479187
  import { join as join131 } from "path";
478382
479188
  function formatTimestamp(date6) {
@@ -478417,7 +479223,7 @@ async function exportWithReactRenderer(context2) {
478417
479223
  const tools = context2.options.tools || [];
478418
479224
  return renderMessagesToPlainText(context2.messages, tools);
478419
479225
  }
478420
- async function call62(onDone, context2, args) {
479226
+ async function call64(onDone, context2, args) {
478421
479227
  const content = await exportWithReactRenderer(context2);
478422
479228
  const filename = args.trim();
478423
479229
  if (filename) {
@@ -478477,7 +479283,7 @@ var init_export2 = __esm(() => {
478477
479283
  // src/commands/model/model.tsx
478478
479284
  var exports_model2 = {};
478479
479285
  __export(exports_model2, {
478480
- call: () => call63
479286
+ call: () => call65
478481
479287
  });
478482
479288
  function ModelPickerWrapper(t0) {
478483
479289
  const $3 = import_compiler_runtime269.c(17);
@@ -478725,7 +479531,7 @@ function renderModelLabel(model) {
478725
479531
  const rendered = renderDefaultModelSetting(model ?? getDefaultMainLoopModelSetting());
478726
479532
  return model === null ? `${rendered} (default)` : rendered;
478727
479533
  }
478728
- var import_compiler_runtime269, React107, jsx_dev_runtime347, call63 = async (onDone, _context, args) => {
479534
+ var import_compiler_runtime269, React107, jsx_dev_runtime347, call65 = async (onDone, _context, args) => {
478729
479535
  args = args?.trim() || "";
478730
479536
  if (COMMON_INFO_ARGS.includes(args)) {
478731
479537
  logEvent("tengu_model_command_inline_help", {
@@ -478794,7 +479600,7 @@ var init_model3 = __esm(() => {
478794
479600
  // src/commands/tag/tag.tsx
478795
479601
  var exports_tag = {};
478796
479602
  __export(exports_tag, {
478797
- call: () => call64
479603
+ call: () => call66
478798
479604
  });
478799
479605
  function ConfirmRemoveTag(t0) {
478800
479606
  const $3 = import_compiler_runtime270.c(11);
@@ -479018,7 +479824,7 @@ Examples:
479018
479824
  React108.useEffect(t1, t2);
479019
479825
  return null;
479020
479826
  }
479021
- async function call64(onDone, _context, args) {
479827
+ async function call66(onDone, _context, args) {
479022
479828
  args = args?.trim() || "";
479023
479829
  if (COMMON_INFO_ARGS.includes(args) || COMMON_HELP_ARGS.includes(args)) {
479024
479830
  return /* @__PURE__ */ jsx_dev_runtime348.jsxDEV(ShowHelp, {
@@ -479067,9 +479873,9 @@ var init_tag2 = __esm(() => {
479067
479873
  // src/commands/output-style/output-style.tsx
479068
479874
  var exports_output_style = {};
479069
479875
  __export(exports_output_style, {
479070
- call: () => call65
479876
+ call: () => call67
479071
479877
  });
479072
- async function call65(onDone) {
479878
+ async function call67(onDone) {
479073
479879
  onDone("/output-style has been deprecated. Use /config to change your output style, or set it in your settings file. Changes take effect on the next session.", {
479074
479880
  display: "system"
479075
479881
  });
@@ -479588,9 +480394,9 @@ var init_RemoteEnvironmentDialog = __esm(() => {
479588
480394
  // src/commands/remote-env/remote-env.tsx
479589
480395
  var exports_remote_env = {};
479590
480396
  __export(exports_remote_env, {
479591
- call: () => call66
480397
+ call: () => call68
479592
480398
  });
479593
- async function call66(onDone) {
480399
+ async function call68(onDone) {
479594
480400
  return /* @__PURE__ */ jsx_dev_runtime350.jsxDEV(RemoteEnvironmentDialog, {
479595
480401
  onDone
479596
480402
  }, undefined, false, undefined, this);
@@ -479620,9 +480426,9 @@ var init_remote_env2 = __esm(() => {
479620
480426
  // src/commands/upgrade/upgrade.tsx
479621
480427
  var exports_upgrade = {};
479622
480428
  __export(exports_upgrade, {
479623
- call: () => call67
480429
+ call: () => call69
479624
480430
  });
479625
- async function call67(onDone, context2) {
480431
+ async function call69(onDone, context2) {
479626
480432
  try {
479627
480433
  if (isClaudeAISubscriber()) {
479628
480434
  const tokens = getClaudeAIOAuthTokens();
@@ -479682,7 +480488,7 @@ var init_upgrade2 = __esm(() => {
479682
480488
  // src/commands/rate-limit-options/rate-limit-options.tsx
479683
480489
  var exports_rate_limit_options = {};
479684
480490
  __export(exports_rate_limit_options, {
479685
- call: () => call68
480491
+ call: () => call70
479686
480492
  });
479687
480493
  function RateLimitOptionsMenu(t0) {
479688
480494
  const $3 = import_compiler_runtime272.c(25);
@@ -479816,7 +480622,7 @@ function RateLimitOptionsMenu(t0) {
479816
480622
  t5 = function handleSelect2(value) {
479817
480623
  if (value === "upgrade") {
479818
480624
  logEvent("tengu_rate_limit_options_menu_select_upgrade", {});
479819
- call67(onDone, context2).then((jsx) => {
480625
+ call69(onDone, context2).then((jsx) => {
479820
480626
  if (jsx) {
479821
480627
  setSubCommandJSX(jsx);
479822
480628
  }
@@ -479876,7 +480682,7 @@ function RateLimitOptionsMenu(t0) {
479876
480682
  }
479877
480683
  return t7;
479878
480684
  }
479879
- async function call68(onDone, context2) {
480685
+ async function call70(onDone, context2) {
479880
480686
  return /* @__PURE__ */ jsx_dev_runtime352.jsxDEV(RateLimitOptionsMenu, {
479881
480687
  onDone,
479882
480688
  context: context2
@@ -479950,7 +480756,7 @@ var exports_effort = {};
479950
480756
  __export(exports_effort, {
479951
480757
  showCurrentEffort: () => showCurrentEffort,
479952
480758
  executeEffort: () => executeEffort,
479953
- call: () => call69
480759
+ call: () => call71
479954
480760
  });
479955
480761
  function setEffortValue(effortValue) {
479956
480762
  const persistable = toPersistableEffort(effortValue);
@@ -480101,7 +480907,7 @@ function ApplyEffortAndClose(t0) {
480101
480907
  React110.useEffect(t1, t2);
480102
480908
  return null;
480103
480909
  }
480104
- async function call69(onDone, _context, args) {
480910
+ async function call71(onDone, _context, args) {
480105
480911
  args = args?.trim() || "";
480106
480912
  if (COMMON_HELP_ARGS2.includes(args)) {
480107
480913
  onDone(`Usage: /effort [low|medium|high|max|auto]
@@ -483010,9 +483816,9 @@ var init_Stats = __esm(() => {
483010
483816
  // src/commands/stats/stats.tsx
483011
483817
  var exports_stats = {};
483012
483818
  __export(exports_stats, {
483013
- call: () => call70
483819
+ call: () => call72
483014
483820
  });
483015
- var jsx_dev_runtime355, call70 = async (onDone) => {
483821
+ var jsx_dev_runtime355, call72 = async (onDone) => {
483016
483822
  return /* @__PURE__ */ jsx_dev_runtime355.jsxDEV(Stats2, {
483017
483823
  onClose: onDone
483018
483824
  }, undefined, false, undefined, this);
@@ -483075,6 +483881,870 @@ var init_agents_platform = __esm(() => {
483075
483881
  agents_platform_default = agentsPlatform;
483076
483882
  });
483077
483883
 
483884
+ // src/buddy/sprites.ts
483885
+ function renderSprite(bones, frame = 0) {
483886
+ const frames = BODIES[bones.species];
483887
+ const body = frames[frame % frames.length].map((line) => line.replaceAll("{E}", bones.eye));
483888
+ const lines2 = [...body];
483889
+ if (bones.hat !== "none" && !lines2[0].trim()) {
483890
+ lines2[0] = HAT_LINES[bones.hat];
483891
+ }
483892
+ if (!lines2[0].trim() && frames.every((f) => !f[0].trim()))
483893
+ lines2.shift();
483894
+ return lines2;
483895
+ }
483896
+ function spriteFrameCount(species) {
483897
+ return BODIES[species].length;
483898
+ }
483899
+ function renderFace(bones) {
483900
+ const eye = bones.eye;
483901
+ switch (bones.species) {
483902
+ case duck:
483903
+ case goose:
483904
+ return `(${eye}>`;
483905
+ case blob:
483906
+ return `(${eye}${eye})`;
483907
+ case cat:
483908
+ return `=${eye}ω${eye}=`;
483909
+ case dragon:
483910
+ return `<${eye}~${eye}>`;
483911
+ case octopus:
483912
+ return `~(${eye}${eye})~`;
483913
+ case owl:
483914
+ return `(${eye})(${eye})`;
483915
+ case penguin:
483916
+ return `(${eye}>)`;
483917
+ case turtle:
483918
+ return `[${eye}_${eye}]`;
483919
+ case snail:
483920
+ return `${eye}(@)`;
483921
+ case ghost:
483922
+ return `/${eye}${eye}\\`;
483923
+ case axolotl:
483924
+ return `}${eye}.${eye}{`;
483925
+ case capybara:
483926
+ return `(${eye}oo${eye})`;
483927
+ case cactus:
483928
+ return `|${eye} ${eye}|`;
483929
+ case robot:
483930
+ return `[${eye}${eye}]`;
483931
+ case rabbit:
483932
+ return `(${eye}..${eye})`;
483933
+ case mushroom:
483934
+ return `|${eye} ${eye}|`;
483935
+ case chonk:
483936
+ return `(${eye}.${eye})`;
483937
+ }
483938
+ }
483939
+ var BODIES, HAT_LINES;
483940
+ var init_sprites = __esm(() => {
483941
+ init_types4();
483942
+ BODIES = {
483943
+ [duck]: [
483944
+ [
483945
+ " ",
483946
+ " __ ",
483947
+ " <({E} )___ ",
483948
+ " ( ._> ",
483949
+ " `--´ "
483950
+ ],
483951
+ [
483952
+ " ",
483953
+ " __ ",
483954
+ " <({E} )___ ",
483955
+ " ( ._> ",
483956
+ " `--´~ "
483957
+ ],
483958
+ [
483959
+ " ",
483960
+ " __ ",
483961
+ " <({E} )___ ",
483962
+ " ( .__> ",
483963
+ " `--´ "
483964
+ ]
483965
+ ],
483966
+ [goose]: [
483967
+ [
483968
+ " ",
483969
+ " ({E}> ",
483970
+ " || ",
483971
+ " _(__)_ ",
483972
+ " ^^^^ "
483973
+ ],
483974
+ [
483975
+ " ",
483976
+ " ({E}> ",
483977
+ " || ",
483978
+ " _(__)_ ",
483979
+ " ^^^^ "
483980
+ ],
483981
+ [
483982
+ " ",
483983
+ " ({E}>> ",
483984
+ " || ",
483985
+ " _(__)_ ",
483986
+ " ^^^^ "
483987
+ ]
483988
+ ],
483989
+ [blob]: [
483990
+ [
483991
+ " ",
483992
+ " .----. ",
483993
+ " ( {E} {E} ) ",
483994
+ " ( ) ",
483995
+ " `----´ "
483996
+ ],
483997
+ [
483998
+ " ",
483999
+ " .------. ",
484000
+ " ( {E} {E} ) ",
484001
+ " ( ) ",
484002
+ " `------´ "
484003
+ ],
484004
+ [
484005
+ " ",
484006
+ " .--. ",
484007
+ " ({E} {E}) ",
484008
+ " ( ) ",
484009
+ " `--´ "
484010
+ ]
484011
+ ],
484012
+ [cat]: [
484013
+ [
484014
+ " ",
484015
+ " /\\_/\\ ",
484016
+ " ( {E} {E}) ",
484017
+ " ( ω ) ",
484018
+ ' (")_(") '
484019
+ ],
484020
+ [
484021
+ " ",
484022
+ " /\\_/\\ ",
484023
+ " ( {E} {E}) ",
484024
+ " ( ω ) ",
484025
+ ' (")_(")~ '
484026
+ ],
484027
+ [
484028
+ " ",
484029
+ " /\\-/\\ ",
484030
+ " ( {E} {E}) ",
484031
+ " ( ω ) ",
484032
+ ' (")_(") '
484033
+ ]
484034
+ ],
484035
+ [dragon]: [
484036
+ [
484037
+ " ",
484038
+ " /^\\ /^\\ ",
484039
+ " < {E} {E} > ",
484040
+ " ( ~~ ) ",
484041
+ " `-vvvv-´ "
484042
+ ],
484043
+ [
484044
+ " ",
484045
+ " /^\\ /^\\ ",
484046
+ " < {E} {E} > ",
484047
+ " ( ) ",
484048
+ " `-vvvv-´ "
484049
+ ],
484050
+ [
484051
+ " ~ ~ ",
484052
+ " /^\\ /^\\ ",
484053
+ " < {E} {E} > ",
484054
+ " ( ~~ ) ",
484055
+ " `-vvvv-´ "
484056
+ ]
484057
+ ],
484058
+ [octopus]: [
484059
+ [
484060
+ " ",
484061
+ " .----. ",
484062
+ " ( {E} {E} ) ",
484063
+ " (______) ",
484064
+ " /\\/\\/\\/\\ "
484065
+ ],
484066
+ [
484067
+ " ",
484068
+ " .----. ",
484069
+ " ( {E} {E} ) ",
484070
+ " (______) ",
484071
+ " \\/\\/\\/\\/ "
484072
+ ],
484073
+ [
484074
+ " o ",
484075
+ " .----. ",
484076
+ " ( {E} {E} ) ",
484077
+ " (______) ",
484078
+ " /\\/\\/\\/\\ "
484079
+ ]
484080
+ ],
484081
+ [owl]: [
484082
+ [
484083
+ " ",
484084
+ " /\\ /\\ ",
484085
+ " (({E})({E})) ",
484086
+ " ( >< ) ",
484087
+ " `----´ "
484088
+ ],
484089
+ [
484090
+ " ",
484091
+ " /\\ /\\ ",
484092
+ " (({E})({E})) ",
484093
+ " ( >< ) ",
484094
+ " .----. "
484095
+ ],
484096
+ [
484097
+ " ",
484098
+ " /\\ /\\ ",
484099
+ " (({E})(-)) ",
484100
+ " ( >< ) ",
484101
+ " `----´ "
484102
+ ]
484103
+ ],
484104
+ [penguin]: [
484105
+ [
484106
+ " ",
484107
+ " .---. ",
484108
+ " ({E}>{E}) ",
484109
+ " /( )\\ ",
484110
+ " `---´ "
484111
+ ],
484112
+ [
484113
+ " ",
484114
+ " .---. ",
484115
+ " ({E}>{E}) ",
484116
+ " |( )| ",
484117
+ " `---´ "
484118
+ ],
484119
+ [
484120
+ " .---. ",
484121
+ " ({E}>{E}) ",
484122
+ " /( )\\ ",
484123
+ " `---´ ",
484124
+ " ~ ~ "
484125
+ ]
484126
+ ],
484127
+ [turtle]: [
484128
+ [
484129
+ " ",
484130
+ " _,--._ ",
484131
+ " ( {E} {E} ) ",
484132
+ " /[______]\\ ",
484133
+ " `` `` "
484134
+ ],
484135
+ [
484136
+ " ",
484137
+ " _,--._ ",
484138
+ " ( {E} {E} ) ",
484139
+ " /[______]\\ ",
484140
+ " `` `` "
484141
+ ],
484142
+ [
484143
+ " ",
484144
+ " _,--._ ",
484145
+ " ( {E} {E} ) ",
484146
+ " /[======]\\ ",
484147
+ " `` `` "
484148
+ ]
484149
+ ],
484150
+ [snail]: [
484151
+ [
484152
+ " ",
484153
+ " {E} .--. ",
484154
+ " \\ ( @ ) ",
484155
+ " \\_`--´ ",
484156
+ " ~~~~~~~ "
484157
+ ],
484158
+ [
484159
+ " ",
484160
+ " {E} .--. ",
484161
+ " | ( @ ) ",
484162
+ " \\_`--´ ",
484163
+ " ~~~~~~~ "
484164
+ ],
484165
+ [
484166
+ " ",
484167
+ " {E} .--. ",
484168
+ " \\ ( @ ) ",
484169
+ " \\_`--´ ",
484170
+ " ~~~~~~ "
484171
+ ]
484172
+ ],
484173
+ [ghost]: [
484174
+ [
484175
+ " ",
484176
+ " .----. ",
484177
+ " / {E} {E} \\ ",
484178
+ " | | ",
484179
+ " ~`~``~`~ "
484180
+ ],
484181
+ [
484182
+ " ",
484183
+ " .----. ",
484184
+ " / {E} {E} \\ ",
484185
+ " | | ",
484186
+ " `~`~~`~` "
484187
+ ],
484188
+ [
484189
+ " ~ ~ ",
484190
+ " .----. ",
484191
+ " / {E} {E} \\ ",
484192
+ " | | ",
484193
+ " ~~`~~`~~ "
484194
+ ]
484195
+ ],
484196
+ [axolotl]: [
484197
+ [
484198
+ " ",
484199
+ "}~(______)~{",
484200
+ "}~({E} .. {E})~{",
484201
+ " ( .--. ) ",
484202
+ " (_/ \\_) "
484203
+ ],
484204
+ [
484205
+ " ",
484206
+ "~}(______){~",
484207
+ "~}({E} .. {E}){~",
484208
+ " ( .--. ) ",
484209
+ " (_/ \\_) "
484210
+ ],
484211
+ [
484212
+ " ",
484213
+ "}~(______)~{",
484214
+ "}~({E} .. {E})~{",
484215
+ " ( -- ) ",
484216
+ " ~_/ \\_~ "
484217
+ ]
484218
+ ],
484219
+ [capybara]: [
484220
+ [
484221
+ " ",
484222
+ " n______n ",
484223
+ " ( {E} {E} ) ",
484224
+ " ( oo ) ",
484225
+ " `------´ "
484226
+ ],
484227
+ [
484228
+ " ",
484229
+ " n______n ",
484230
+ " ( {E} {E} ) ",
484231
+ " ( Oo ) ",
484232
+ " `------´ "
484233
+ ],
484234
+ [
484235
+ " ~ ~ ",
484236
+ " u______n ",
484237
+ " ( {E} {E} ) ",
484238
+ " ( oo ) ",
484239
+ " `------´ "
484240
+ ]
484241
+ ],
484242
+ [cactus]: [
484243
+ [
484244
+ " ",
484245
+ " n ____ n ",
484246
+ " | |{E} {E}| | ",
484247
+ " |_| |_| ",
484248
+ " | | "
484249
+ ],
484250
+ [
484251
+ " ",
484252
+ " ____ ",
484253
+ " n |{E} {E}| n ",
484254
+ " |_| |_| ",
484255
+ " | | "
484256
+ ],
484257
+ [
484258
+ " n n ",
484259
+ " | ____ | ",
484260
+ " | |{E} {E}| | ",
484261
+ " |_| |_| ",
484262
+ " | | "
484263
+ ]
484264
+ ],
484265
+ [robot]: [
484266
+ [
484267
+ " ",
484268
+ " .[||]. ",
484269
+ " [ {E} {E} ] ",
484270
+ " [ ==== ] ",
484271
+ " `------´ "
484272
+ ],
484273
+ [
484274
+ " ",
484275
+ " .[||]. ",
484276
+ " [ {E} {E} ] ",
484277
+ " [ -==- ] ",
484278
+ " `------´ "
484279
+ ],
484280
+ [
484281
+ " * ",
484282
+ " .[||]. ",
484283
+ " [ {E} {E} ] ",
484284
+ " [ ==== ] ",
484285
+ " `------´ "
484286
+ ]
484287
+ ],
484288
+ [rabbit]: [
484289
+ [
484290
+ " ",
484291
+ " (\\__/) ",
484292
+ " ( {E} {E} ) ",
484293
+ " =( .. )= ",
484294
+ ' (")__(") '
484295
+ ],
484296
+ [
484297
+ " ",
484298
+ " (|__/) ",
484299
+ " ( {E} {E} ) ",
484300
+ " =( .. )= ",
484301
+ ' (")__(") '
484302
+ ],
484303
+ [
484304
+ " ",
484305
+ " (\\__/) ",
484306
+ " ( {E} {E} ) ",
484307
+ " =( . . )= ",
484308
+ ' (")__(") '
484309
+ ]
484310
+ ],
484311
+ [mushroom]: [
484312
+ [
484313
+ " ",
484314
+ " .-o-OO-o-. ",
484315
+ "(__________)",
484316
+ " |{E} {E}| ",
484317
+ " |____| "
484318
+ ],
484319
+ [
484320
+ " ",
484321
+ " .-O-oo-O-. ",
484322
+ "(__________)",
484323
+ " |{E} {E}| ",
484324
+ " |____| "
484325
+ ],
484326
+ [
484327
+ " . o . ",
484328
+ " .-o-OO-o-. ",
484329
+ "(__________)",
484330
+ " |{E} {E}| ",
484331
+ " |____| "
484332
+ ]
484333
+ ],
484334
+ [chonk]: [
484335
+ [
484336
+ " ",
484337
+ " /\\ /\\ ",
484338
+ " ( {E} {E} ) ",
484339
+ " ( .. ) ",
484340
+ " `------´ "
484341
+ ],
484342
+ [
484343
+ " ",
484344
+ " /\\ /| ",
484345
+ " ( {E} {E} ) ",
484346
+ " ( .. ) ",
484347
+ " `------´ "
484348
+ ],
484349
+ [
484350
+ " ",
484351
+ " /\\ /\\ ",
484352
+ " ( {E} {E} ) ",
484353
+ " ( .. ) ",
484354
+ " `------´~ "
484355
+ ]
484356
+ ]
484357
+ };
484358
+ HAT_LINES = {
484359
+ none: "",
484360
+ crown: " \\^^^/ ",
484361
+ tophat: " [___] ",
484362
+ propeller: " -+- ",
484363
+ halo: " ( ) ",
484364
+ wizard: " /^\\ ",
484365
+ beanie: " (___) ",
484366
+ tinyduck: " ,> "
484367
+ };
484368
+ });
484369
+
484370
+ // src/achievements/checker.ts
484371
+ function notify2(id) {
484372
+ if (typeof process !== "undefined") {
484373
+ try {
484374
+ const pending = JSON.parse(process.env.__ACHIEVEMENT_PENDING__ || "[]");
484375
+ pending.push(id);
484376
+ process.env.__ACHIEVEMENT_PENDING__ = JSON.stringify(pending);
484377
+ } catch {
484378
+ process.env.__ACHIEVEMENT_PENDING__ = JSON.stringify([id]);
484379
+ }
484380
+ }
484381
+ }
484382
+ function checkOnBuddyHatch() {
484383
+ tryUnlock("buddy_hatched");
484384
+ const companion = getCompanion();
484385
+ if (companion?.rarity === "legendary") {
484386
+ tryUnlock("buddy_legendary");
484387
+ }
484388
+ if (companion?.shiny) {
484389
+ tryUnlock("buddy_shiny");
484390
+ }
484391
+ }
484392
+ function checkOnBuddyPet() {
484393
+ const count4 = incrementCounter("buddy_pet");
484394
+ tryUnlock("buddy_pet_10", count4 >= 10);
484395
+ tryUnlock("buddy_pet_100", count4 >= 100);
484396
+ }
484397
+ function tryUnlock(id, condition = true) {
484398
+ if (!condition)
484399
+ return;
484400
+ if (hasAchievement(id))
484401
+ return;
484402
+ if (unlockAchievement(id)) {
484403
+ addXp(XP_REWARDS.ACHIEVEMENT_UNLOCK);
484404
+ const unlocked = getUnlockedAchievements();
484405
+ if (unlocked.size === 5)
484406
+ addMilestone("achievement_5");
484407
+ if (unlocked.size === 10)
484408
+ addMilestone("achievement_10");
484409
+ if (unlocked.size === 20)
484410
+ addMilestone("achievement_20");
484411
+ const achievement = ACHIEVEMENTS[id];
484412
+ console.error(`
484413
+ \uD83C\uDFC6 ${achievement.icon} Achievement Unlocked: ${achievement.name}`);
484414
+ console.error(` ${achievement.description}
484415
+ `);
484416
+ notify2(id);
484417
+ }
484418
+ }
484419
+ var init_checker = __esm(() => {
484420
+ init_storage();
484421
+ init_types14();
484422
+ init_companion();
484423
+ init_evolution();
484424
+ init_milestones();
484425
+ init_usageStats();
484426
+ });
484427
+
484428
+ // src/events/calendar.ts
484429
+ function getTodayEvent() {
484430
+ const now2 = new Date;
484431
+ const month = now2.getMonth() + 1;
484432
+ const day = now2.getDate();
484433
+ for (const event of EVENTS2) {
484434
+ if (event.month === month && event.day === day) {
484435
+ if (event.yearStart && now2.getFullYear() < event.yearStart)
484436
+ continue;
484437
+ if (event.yearEnd && now2.getFullYear() > event.yearEnd)
484438
+ continue;
484439
+ return event;
484440
+ }
484441
+ }
484442
+ return null;
484443
+ }
484444
+ function getEventReaction() {
484445
+ const event = getTodayEvent();
484446
+ if (!event)
484447
+ return null;
484448
+ return `${event.emoji} ${event.message}`;
484449
+ }
484450
+ var EVENTS2;
484451
+ var init_calendar = __esm(() => {
484452
+ init_config();
484453
+ EVENTS2 = [
484454
+ { id: "new_year", name: "New Year", emoji: "\uD83C\uDF86", message: "Happy New Year! \uD83C\uDF86 May your code compile on the first try!", month: 1, day: 1 },
484455
+ { id: "valentine", name: "Valentine's Day", emoji: "\uD83D\uDC9D", message: "Happy Valentine's Day! \uD83D\uDC9D Your companion sends you love!", month: 2, day: 14 },
484456
+ { id: "pi_day", name: "Pi Day", emoji: "\uD83E\uDD67", message: "Happy Pi Day! 3.14159... π is infinitely delicious!", month: 3, day: 14 },
484457
+ { id: "april_fools", name: "April Fools", emoji: "\uD83C\uDFAD", message: "April Fools! Your code looks perfect today... just kidding! \uD83C\uDFAD", month: 4, day: 1 },
484458
+ { id: "earth_day", name: "Earth Day", emoji: "\uD83C\uDF0D", message: "Happy Earth Day! \uD83C\uDF0D Plant a tree, write green code.", month: 4, day: 22 },
484459
+ { id: "star_wars", name: "May the 4th", emoji: "\uD83D\uDE80", message: "May the 4th be with you! Use the Source, Luke! \uD83D\uDE80", month: 5, day: 4 },
484460
+ { id: "summer_start", name: "Summer Solstice", emoji: "☀️", message: "Longest day of the year! ☀️ Time for some summer coding.", month: 6, day: 21 },
484461
+ { id: "halloween", name: "Halloween", emoji: "\uD83C\uDF83", message: "Trick or treat! \uD83C\uDF83 Your companion is wearing a tiny costume!", month: 10, day: 31 },
484462
+ { id: "programmers_day", name: "Programmer's Day", emoji: "\uD83D\uDCBB", message: "Happy Programmer's Day! (Day 256 of the year) \uD83D\uDCBB", month: 9, day: 13 },
484463
+ { id: "thanksgiving", name: "Thanksgiving", emoji: "\uD83E\uDD83", message: "Happy Thanksgiving! \uD83E\uDD83 Thankful for clean code and good compilers.", month: 11, day: 28 },
484464
+ { id: "christmas", name: "Christmas", emoji: "\uD83C\uDF84", message: "Merry Christmas! \uD83C\uDF84 Your buddy is waiting under the terminal tree!", month: 12, day: 25 },
484465
+ { id: "new_year_eve", name: "New Year's Eve", emoji: "\uD83C\uDF89", message: "Almost there! \uD83C\uDF89 One last commit before the new year!", month: 12, day: 31 },
484466
+ { id: "bun_day", name: "Bun Birthday", emoji: "\uD83E\uDD5F", message: "Happy Bun Birthday! The fastest runtime deserves celebration!", month: 7, day: 13 },
484467
+ { id: "retro_days", name: "Retro Computing Day", emoji: "\uD83D\uDDA5️", message: "Retro Computing Day! Remember when 64KB was plenty? \uD83D\uDDA5️", month: 12, day: 3 }
484468
+ ];
484469
+ });
484470
+
484471
+ // src/commands/buddy/buddy.ts
484472
+ var exports_buddy = {};
484473
+ __export(exports_buddy, {
484474
+ call: () => call73
484475
+ });
484476
+ function getXpBar(current, needed) {
484477
+ const filled = Math.floor(current / needed * 10);
484478
+ return "█".repeat(filled) + "░".repeat(10 - filled);
484479
+ }
484480
+ function formatXpEvents(events2) {
484481
+ const msgs = [];
484482
+ for (const e of events2) {
484483
+ if (e.type === "level_up") {
484484
+ msgs.push(`
484485
+ ⬆️ Level up! You are now level ${e.level}!`);
484486
+ }
484487
+ if (e.type === "evolution") {
484488
+ msgs.push(`
484489
+ ✨ Your companion evolved to stage ${e.stage}!`);
484490
+ }
484491
+ }
484492
+ return msgs;
484493
+ }
484494
+ function handleHatch() {
484495
+ const existing = getGlobalConfig().companion;
484496
+ if (existing && getCompanion()) {
484497
+ return { type: "text", value: "You already have a companion! Use /buddy card to see details." };
484498
+ }
484499
+ const userId = companionUserId();
484500
+ const { bones, inspirationSeed } = roll(userId);
484501
+ const face = renderFace(bones);
484502
+ const rarityStars = RARITY_STARS[bones.rarity];
484503
+ const shiny = bones.shiny ? " ✨ SHINY" : "";
484504
+ const speciesName = SPECIES_NAMES[bones.species] || bones.species;
484505
+ saveGlobalConfig((current) => ({
484506
+ ...current,
484507
+ companion: { name: speciesName, personality: "curious", hatchedAt: Date.now() }
484508
+ }));
484509
+ const events2 = addXp(XP_REWARDS.BUDDY_HATCH);
484510
+ trackBuddyInteraction();
484511
+ const xpMsgs = formatXpEvents(events2);
484512
+ checkOnBuddyHatch();
484513
+ const result = [
484514
+ `\uD83C\uDF89 A new companion has appeared!`,
484515
+ ``,
484516
+ `${face}`,
484517
+ ``,
484518
+ `Rarity: ${rarityStars} (${bones.rarity})${shiny}`,
484519
+ `Species: ${speciesName}`,
484520
+ `Eye: ${bones.eye} Hat: ${bones.hat}`,
484521
+ `+${XP_REWARDS.BUDDY_HATCH} XP for hatching!`,
484522
+ ...xpMsgs,
484523
+ ``
484524
+ ];
484525
+ const eventMsg = getEventReaction();
484526
+ if (eventMsg) {
484527
+ result.push(`${eventMsg}`);
484528
+ result.push("");
484529
+ }
484530
+ result.push(`You can interact with it using:`, ` /buddy pet — pet (+5 XP)`, ` /buddy feed — feed (+15 XP)`, ` /buddy play — play (+20 XP)`, ` /buddy card — view stats & level`, ` /buddy mute — hide companion`);
484531
+ return { type: "text", value: result.join(`
484532
+ `) };
484533
+ }
484534
+ function handlePet() {
484535
+ const companion = getCompanion();
484536
+ if (!companion)
484537
+ return { type: "text", value: `You don't have a companion yet! Use /buddy hatch to get one.` };
484538
+ const events2 = addXp(XP_REWARDS.BUDDY_PET);
484539
+ trackBuddyInteraction();
484540
+ checkOnBuddyPet();
484541
+ const xpMsgs = formatXpEvents(events2);
484542
+ const reaction = getPetReaction(companion.species);
484543
+ return {
484544
+ type: "text",
484545
+ value: [
484546
+ `You pet ${companion.name}! ${companion.name} seems happy. ${reaction}`,
484547
+ `+${XP_REWARDS.BUDDY_PET} XP`,
484548
+ ...xpMsgs
484549
+ ].join(`
484550
+ `)
484551
+ };
484552
+ }
484553
+ function handleFeed() {
484554
+ const companion = getCompanion();
484555
+ if (!companion)
484556
+ return { type: "text", value: `You don't have a companion yet! Use /buddy hatch to get one.` };
484557
+ const count4 = incrementFeed();
484558
+ const events2 = addXp(XP_REWARDS.BUDDY_FEED);
484559
+ trackBuddyInteraction();
484560
+ const xpMsgs = formatXpEvents(events2);
484561
+ const foods = ["a juicy berry \uD83E\uDED0", "a tiny cookie \uD83C\uDF6A", "some fresh grass \uD83C\uDF3F", "a glowing snack ✨", "a warm bowl of soup \uD83E\uDD63"];
484562
+ const food = foods[count4 % foods.length];
484563
+ return {
484564
+ type: "text",
484565
+ value: [
484566
+ `You feed ${companion.name} ${food}. Yum!`,
484567
+ `+${XP_REWARDS.BUDDY_FEED} XP`,
484568
+ ...xpMsgs
484569
+ ].join(`
484570
+ `)
484571
+ };
484572
+ }
484573
+ function handlePlay() {
484574
+ const companion = getCompanion();
484575
+ if (!companion)
484576
+ return { type: "text", value: `You don't have a companion yet! Use /buddy hatch to get one.` };
484577
+ const count4 = incrementPlay();
484578
+ const events2 = addXp(XP_REWARDS.BUDDY_PLAY);
484579
+ trackBuddyInteraction();
484580
+ const xpMsgs = formatXpEvents(events2);
484581
+ const games = ["hide and seek \uD83D\uDE48", "tag \uD83C\uDFC3", "puzzle \uD83E\uDDE9", "fetch \uD83C\uDFBE", "a dance-off \uD83D\uDC83"];
484582
+ const game = games[count4 % games.length];
484583
+ return {
484584
+ type: "text",
484585
+ value: [
484586
+ `You play ${game} with ${companion.name}! So much fun!`,
484587
+ `+${XP_REWARDS.BUDDY_PLAY} XP`,
484588
+ ...xpMsgs
484589
+ ].join(`
484590
+ `)
484591
+ };
484592
+ }
484593
+ function handleCard() {
484594
+ const companion = getCompanion();
484595
+ if (!companion)
484596
+ return { type: "text", value: `You don't have a companion yet! Use /buddy hatch to get one.` };
484597
+ const face = renderFace(companion);
484598
+ const rarityStars = RARITY_STARS[companion.rarity];
484599
+ const shiny = companion.shiny ? " ✨" : "";
484600
+ const speciesName = SPECIES_NAMES[companion.species] || companion.species;
484601
+ const level = getLevel();
484602
+ const xp = getXp();
484603
+ const xpNext = getXpForNextLevel();
484604
+ const stage = getEvolutionStage();
484605
+ const evolvedSpecies = stage > 0 ? getEvolvedSpecies(companion.species, stage) : null;
484606
+ const xpBar = getXpBar(xp, xpNext);
484607
+ const stats2 = Object.entries(companion.stats).map(([name, value]) => ` ${name.padEnd(12)} ${"█".repeat(Math.floor(value / 10))}${"░".repeat(10 - Math.floor(value / 10))} ${value}`).join(`
484608
+ `);
484609
+ const result = [
484610
+ `╔══════════════════════════╗`,
484611
+ `║ Companion Card ║`,
484612
+ `╚══════════════════════════╝`,
484613
+ ``,
484614
+ `${face}`,
484615
+ ``,
484616
+ `${companion.name}`,
484617
+ `${rarityStars} ${companion.rarity}${shiny}`,
484618
+ evolvedSpecies ? `Evolved: ${speciesName} → ${evolvedSpecies}` : speciesName,
484619
+ `Eye: ${companion.eye} Hat: ${companion.hat}`,
484620
+ ``,
484621
+ `Level ${level} ${xpBar} ${xp}/${xpNext} XP`,
484622
+ ``,
484623
+ `Stats:`,
484624
+ stats2,
484625
+ ``,
484626
+ `Personality: ${companion.personality}`,
484627
+ ``,
484628
+ `\uD83D\uDCD6 History:`,
484629
+ formatMilestones(),
484630
+ ``
484631
+ ];
484632
+ const eventMsg = getEventReaction();
484633
+ if (eventMsg) {
484634
+ result.push(`${eventMsg}`);
484635
+ result.push("");
484636
+ }
484637
+ return { type: "text", value: result.join(`
484638
+ `) };
484639
+ }
484640
+ function handleMute() {
484641
+ saveGlobalConfig((current) => ({ ...current, companionMuted: true }));
484642
+ return { type: "text", value: "Companion muted. Use /buddy unmute to show again." };
484643
+ }
484644
+ function handleUnmute() {
484645
+ saveGlobalConfig((current) => ({ ...current, companionMuted: false }));
484646
+ return { type: "text", value: "Companion unmuted! Your buddy is back." };
484647
+ }
484648
+ function getPetReaction(species) {
484649
+ const reactions = {
484650
+ duck: ["Quack! \uD83E\uDD86", "Happy waddling!"],
484651
+ cat: ["Purr... \uD83D\uDC31", "Content meowing."],
484652
+ dragon: ["A tiny puff of smoke! \uD83D\uDC09"],
484653
+ octopus: ["Tentacles wiggle happily! \uD83D\uDC19"],
484654
+ robot: ["Beep boop! \uD83E\uDD16"],
484655
+ ghost: ["A warm flicker... \uD83D\uDC7B"],
484656
+ goose: ["Honk! \uD83E\uDEBF", "Proud hiss."],
484657
+ penguin: ["Happy waddle! \uD83D\uDC27"],
484658
+ axolotl: ["Gills flutter! \uD83E\uDD8E"],
484659
+ capybara: ["Chill nod. \uD83E\uDDAB"],
484660
+ rabbit: ["Nose twitches! \uD83D\uDC30"],
484661
+ turtle: ["Slow blink. \uD83D\uDC22"]
484662
+ };
484663
+ const pool = reactions[species] || ["Seems happy!"];
484664
+ return pool[Math.floor(Math.random() * pool.length)];
484665
+ }
484666
+ var SPECIES_NAMES, HELP_TEXT = `Usage: /buddy <subcommand>
484667
+
484668
+ Subcommands:
484669
+ hatch Hatch a new companion
484670
+ pet Pet your companion (+5 XP)
484671
+ feed Feed your companion (+15 XP)
484672
+ play Play with your companion (+20 XP)
484673
+ card Show companion card with stats and level
484674
+ mute Mute companion
484675
+ unmute Unmute companion
484676
+
484677
+ XP is earned through interactions. Level up to evolve your companion!`, call73 = async (args) => {
484678
+ const [subcommand] = args.trim().toLowerCase().split(/\s+/);
484679
+ switch (subcommand) {
484680
+ case "hatch":
484681
+ return handleHatch();
484682
+ case "pet":
484683
+ return handlePet();
484684
+ case "feed":
484685
+ return handleFeed();
484686
+ case "play":
484687
+ return handlePlay();
484688
+ case "card":
484689
+ return handleCard();
484690
+ case "mute":
484691
+ return handleMute();
484692
+ case "unmute":
484693
+ return handleUnmute();
484694
+ default:
484695
+ return { type: "text", value: HELP_TEXT };
484696
+ }
484697
+ };
484698
+ var init_buddy = __esm(() => {
484699
+ init_companion();
484700
+ init_types4();
484701
+ init_sprites();
484702
+ init_config();
484703
+ init_checker();
484704
+ init_evolution();
484705
+ init_usageStats();
484706
+ init_milestones();
484707
+ init_calendar();
484708
+ SPECIES_NAMES = {
484709
+ duck: "\uD83E\uDD86 Duck",
484710
+ goose: "\uD83E\uDEBF Goose",
484711
+ blob: "\uD83E\uDEE7 Blob",
484712
+ cat: "\uD83D\uDC31 Cat",
484713
+ dragon: "\uD83D\uDC09 Dragon",
484714
+ octopus: "\uD83D\uDC19 Octopus",
484715
+ owl: "\uD83E\uDD89 Owl",
484716
+ penguin: "\uD83D\uDC27 Penguin",
484717
+ turtle: "\uD83D\uDC22 Turtle",
484718
+ snail: "\uD83D\uDC0C Snail",
484719
+ ghost: "\uD83D\uDC7B Ghost",
484720
+ axolotl: "\uD83E\uDD8E Axolotl",
484721
+ capybara: "\uD83E\uDDAB Capybara",
484722
+ cactus: "\uD83C\uDF35 Cactus",
484723
+ robot: "\uD83E\uDD16 Robot",
484724
+ rabbit: "\uD83D\uDC30 Rabbit",
484725
+ mushroom: "\uD83C\uDF44 Mushroom",
484726
+ chonk: "\uD83D\uDC08 Chonk"
484727
+ };
484728
+ });
484729
+
484730
+ // src/commands/buddy/index.ts
484731
+ var exports_buddy2 = {};
484732
+ __export(exports_buddy2, {
484733
+ default: () => buddy_default
484734
+ });
484735
+ var buddyCmd, buddy_default;
484736
+ var init_buddy2 = __esm(() => {
484737
+ buddyCmd = {
484738
+ name: "buddy",
484739
+ description: "Manage your terminal companion — hatch, pet, card, mute, unmute",
484740
+ argumentHint: "<hatch|pet|card|mute|unmute>",
484741
+ supportsNonInteractive: false,
484742
+ type: "local",
484743
+ load: () => Promise.resolve().then(() => (init_buddy(), exports_buddy))
484744
+ };
484745
+ buddy_default = buddyCmd;
484746
+ });
484747
+
483078
484748
  // src/commands/insights.ts
483079
484749
  var exports_insights = {};
483080
484750
  __export(exports_insights, {
@@ -485431,7 +487101,7 @@ function formatDescriptionWithSource(cmd) {
485431
487101
  }
485432
487102
  return `${cmd.description} (${getSettingSourceName(cmd.source)})`;
485433
487103
  }
485434
- var agentsPlatform2, proactive = null, briefCommand = null, assistantCommand = null, bridge = null, remoteControlServerCommand = null, voiceCommand = null, forceSnip = null, workflowsCmd = null, webCmd = null, clearSkillIndexCache2 = null, subscribePr = null, ultraplan = null, torch = null, peersCmd = null, forkCmd = null, buddy = null, usageReport2, INTERNAL_ONLY_COMMANDS2, COMMANDS, builtInCommandNames, getWorkflowCommands = null, loadAllCommands, getSkillToolCommands, getSlashCommandToolSkills, REMOTE_SAFE_COMMANDS, BRIDGE_SAFE_COMMANDS;
487104
+ var agentsPlatform2, proactive = null, briefCommand = null, assistantCommand = null, bridge = null, remoteControlServerCommand = null, voiceCommand = null, forceSnip = null, workflowsCmd = null, webCmd = null, clearSkillIndexCache2 = null, subscribePr = null, ultraplan = null, torch = null, peersCmd = null, forkCmd = null, buddy, usageReport2, INTERNAL_ONLY_COMMANDS2, COMMANDS, builtInCommandNames, getWorkflowCommands = null, loadAllCommands, getSkillToolCommands, getSlashCommandToolSkills, REMOTE_SAFE_COMMANDS, BRIDGE_SAFE_COMMANDS;
485435
487105
  var init_commands2 = __esm(() => {
485436
487106
  init_add_dir2();
485437
487107
  init_autofix_pr();
@@ -485503,6 +487173,8 @@ var init_commands2 = __esm(() => {
485503
487173
  init_bridge_kick();
485504
487174
  init_version();
485505
487175
  init_summary();
487176
+ init_achievements2();
487177
+ init_mystats2();
485506
487178
  init_reset_limits();
485507
487179
  init_ant_trace();
485508
487180
  init_perf_issue();
@@ -485537,6 +487209,7 @@ var init_commands2 = __esm(() => {
485537
487209
  init_debug_tool_call();
485538
487210
  init_constants2();
485539
487211
  agentsPlatform2 = process.env.USER_TYPE === "ant" ? (init_agents_platform(), __toCommonJS(exports_agents_platform)).default : null;
487212
+ buddy = (init_buddy2(), __toCommonJS(exports_buddy2)).default;
485540
487213
  usageReport2 = {
485541
487214
  type: "prompt",
485542
487215
  name: "insights",
@@ -485584,6 +487257,7 @@ var init_commands2 = __esm(() => {
485584
487257
  COMMANDS = memoize_default(() => [
485585
487258
  add_dir_default,
485586
487259
  advisor_default,
487260
+ achievements_default,
485587
487261
  agents_default,
485588
487262
  branch_default,
485589
487263
  btw_default,
@@ -485614,6 +487288,7 @@ var init_commands2 = __esm(() => {
485614
487288
  memory_default,
485615
487289
  mobile_default,
485616
487290
  model_default,
487291
+ mystats_default,
485617
487292
  output_style_default,
485618
487293
  remote_env_default,
485619
487294
  plugin_default,
@@ -497968,7 +499643,7 @@ class DebugLogger {
497968
499643
  }
497969
499644
  var EXTENSION_DOWNLOAD_URL = "https://claude.ai/chrome", BUG_REPORT_URL = "https://github.com/anthropics/claude-code/issues/new?labels=bug,claude-in-chrome", SAFE_BRIDGE_STRING_KEYS, PERMISSION_MODES4;
497970
499645
  var init_mcpServer = __esm(() => {
497971
- init_claude_for_chrome_mcp();
499646
+ init_ant_claude_for_chrome_mcp();
497972
499647
  init_stdio2();
497973
499648
  init_datadog();
497974
499649
  init_firstPartyEventLogger();
@@ -498410,7 +500085,7 @@ var require_argument = __commonJS((exports) => {
498410
500085
  this._name = name;
498411
500086
  break;
498412
500087
  }
498413
- if (this._name.length > 3 && this._name.slice(-3) === "...") {
500088
+ if (this._name.endsWith("...")) {
498414
500089
  this.variadic = true;
498415
500090
  this._name = this._name.slice(0, -3);
498416
500091
  }
@@ -498418,11 +500093,12 @@ var require_argument = __commonJS((exports) => {
498418
500093
  name() {
498419
500094
  return this._name;
498420
500095
  }
498421
- _concatValue(value, previous) {
500096
+ _collectValue(value, previous) {
498422
500097
  if (previous === this.defaultValue || !Array.isArray(previous)) {
498423
500098
  return [value];
498424
500099
  }
498425
- return previous.concat(value);
500100
+ previous.push(value);
500101
+ return previous;
498426
500102
  }
498427
500103
  default(value, description) {
498428
500104
  this.defaultValue = value;
@@ -498440,7 +500116,7 @@ var require_argument = __commonJS((exports) => {
498440
500116
  throw new InvalidArgumentError(`Allowed choices are ${this.argChoices.join(", ")}.`);
498441
500117
  }
498442
500118
  if (this.variadic) {
498443
- return this._concatValue(arg, previous);
500119
+ return this._collectValue(arg, previous);
498444
500120
  }
498445
500121
  return arg;
498446
500122
  };
@@ -498605,7 +500281,11 @@ var require_help = __commonJS((exports) => {
498605
500281
  extraInfo.push(`env: ${option.envVar}`);
498606
500282
  }
498607
500283
  if (extraInfo.length > 0) {
498608
- return `${option.description} (${extraInfo.join(", ")})`;
500284
+ const extraDescription = `(${extraInfo.join(", ")})`;
500285
+ if (option.description) {
500286
+ return `${option.description} ${extraDescription}`;
500287
+ }
500288
+ return extraDescription;
498609
500289
  }
498610
500290
  return option.description;
498611
500291
  }
@@ -498626,6 +500306,27 @@ var require_help = __commonJS((exports) => {
498626
500306
  }
498627
500307
  return argument.description;
498628
500308
  }
500309
+ formatItemList(heading, items, helper) {
500310
+ if (items.length === 0)
500311
+ return [];
500312
+ return [helper.styleTitle(heading), ...items, ""];
500313
+ }
500314
+ groupItems(unsortedItems, visibleItems, getGroup) {
500315
+ const result = new Map;
500316
+ unsortedItems.forEach((item) => {
500317
+ const group = getGroup(item);
500318
+ if (!result.has(group))
500319
+ result.set(group, []);
500320
+ });
500321
+ visibleItems.forEach((item) => {
500322
+ const group = getGroup(item);
500323
+ if (!result.has(group)) {
500324
+ result.set(group, []);
500325
+ }
500326
+ result.get(group).push(item);
500327
+ });
500328
+ return result;
500329
+ }
498629
500330
  formatHelp(cmd, helper) {
498630
500331
  const termWidth = helper.padWidth(cmd, helper);
498631
500332
  const helpWidth = helper.helpWidth ?? 80;
@@ -498646,45 +500347,27 @@ var require_help = __commonJS((exports) => {
498646
500347
  const argumentList = helper.visibleArguments(cmd).map((argument) => {
498647
500348
  return callFormatItem(helper.styleArgumentTerm(helper.argumentTerm(argument)), helper.styleArgumentDescription(helper.argumentDescription(argument)));
498648
500349
  });
498649
- if (argumentList.length > 0) {
498650
- output = output.concat([
498651
- helper.styleTitle("Arguments:"),
498652
- ...argumentList,
498653
- ""
498654
- ]);
498655
- }
498656
- const optionList = helper.visibleOptions(cmd).map((option) => {
498657
- return callFormatItem(helper.styleOptionTerm(helper.optionTerm(option)), helper.styleOptionDescription(helper.optionDescription(option)));
500350
+ output = output.concat(this.formatItemList("Arguments:", argumentList, helper));
500351
+ const optionGroups = this.groupItems(cmd.options, helper.visibleOptions(cmd), (option) => option.helpGroupHeading ?? "Options:");
500352
+ optionGroups.forEach((options, group) => {
500353
+ const optionList = options.map((option) => {
500354
+ return callFormatItem(helper.styleOptionTerm(helper.optionTerm(option)), helper.styleOptionDescription(helper.optionDescription(option)));
500355
+ });
500356
+ output = output.concat(this.formatItemList(group, optionList, helper));
498658
500357
  });
498659
- if (optionList.length > 0) {
498660
- output = output.concat([
498661
- helper.styleTitle("Options:"),
498662
- ...optionList,
498663
- ""
498664
- ]);
498665
- }
498666
500358
  if (helper.showGlobalOptions) {
498667
500359
  const globalOptionList = helper.visibleGlobalOptions(cmd).map((option) => {
498668
500360
  return callFormatItem(helper.styleOptionTerm(helper.optionTerm(option)), helper.styleOptionDescription(helper.optionDescription(option)));
498669
500361
  });
498670
- if (globalOptionList.length > 0) {
498671
- output = output.concat([
498672
- helper.styleTitle("Global Options:"),
498673
- ...globalOptionList,
498674
- ""
498675
- ]);
498676
- }
500362
+ output = output.concat(this.formatItemList("Global Options:", globalOptionList, helper));
498677
500363
  }
498678
- const commandList = helper.visibleCommands(cmd).map((cmd2) => {
498679
- return callFormatItem(helper.styleSubcommandTerm(helper.subcommandTerm(cmd2)), helper.styleSubcommandDescription(helper.subcommandDescription(cmd2)));
500364
+ const commandGroups = this.groupItems(cmd.commands, helper.visibleCommands(cmd), (sub) => sub.helpGroup() || "Commands:");
500365
+ commandGroups.forEach((commands, group) => {
500366
+ const commandList = commands.map((sub) => {
500367
+ return callFormatItem(helper.styleSubcommandTerm(helper.subcommandTerm(sub)), helper.styleSubcommandDescription(helper.subcommandDescription(sub)));
500368
+ });
500369
+ output = output.concat(this.formatItemList(group, commandList, helper));
498680
500370
  });
498681
- if (commandList.length > 0) {
498682
- output = output.concat([
498683
- helper.styleTitle("Commands:"),
498684
- ...commandList,
498685
- ""
498686
- ]);
498687
- }
498688
500371
  return output.join(`
498689
500372
  `);
498690
500373
  }
@@ -498841,6 +500524,7 @@ var require_option = __commonJS((exports) => {
498841
500524
  this.argChoices = undefined;
498842
500525
  this.conflictsWith = [];
498843
500526
  this.implied = undefined;
500527
+ this.helpGroupHeading = undefined;
498844
500528
  }
498845
500529
  default(value, description) {
498846
500530
  this.defaultValue = value;
@@ -498879,11 +500563,12 @@ var require_option = __commonJS((exports) => {
498879
500563
  this.hidden = !!hide;
498880
500564
  return this;
498881
500565
  }
498882
- _concatValue(value, previous) {
500566
+ _collectValue(value, previous) {
498883
500567
  if (previous === this.defaultValue || !Array.isArray(previous)) {
498884
500568
  return [value];
498885
500569
  }
498886
- return previous.concat(value);
500570
+ previous.push(value);
500571
+ return previous;
498887
500572
  }
498888
500573
  choices(values2) {
498889
500574
  this.argChoices = values2.slice();
@@ -498892,7 +500577,7 @@ var require_option = __commonJS((exports) => {
498892
500577
  throw new InvalidArgumentError(`Allowed choices are ${this.argChoices.join(", ")}.`);
498893
500578
  }
498894
500579
  if (this.variadic) {
498895
- return this._concatValue(arg, previous);
500580
+ return this._collectValue(arg, previous);
498896
500581
  }
498897
500582
  return arg;
498898
500583
  };
@@ -498910,6 +500595,10 @@ var require_option = __commonJS((exports) => {
498910
500595
  }
498911
500596
  return camelcase(this.name());
498912
500597
  }
500598
+ helpGroup(heading) {
500599
+ this.helpGroupHeading = heading;
500600
+ return this;
500601
+ }
498913
500602
  is(arg) {
498914
500603
  return this.short === arg || this.long === arg;
498915
500604
  }
@@ -499127,6 +500816,9 @@ var require_command = __commonJS((exports) => {
499127
500816
  this._addImplicitHelpCommand = undefined;
499128
500817
  this._helpCommand = undefined;
499129
500818
  this._helpConfiguration = {};
500819
+ this._helpGroupHeading = undefined;
500820
+ this._defaultCommandGroup = undefined;
500821
+ this._defaultOptionGroup = undefined;
499130
500822
  }
499131
500823
  copyInheritedSettings(sourceCommand) {
499132
500824
  this._outputConfiguration = sourceCommand._outputConfiguration;
@@ -499191,7 +500883,10 @@ var require_command = __commonJS((exports) => {
499191
500883
  configureOutput(configuration) {
499192
500884
  if (configuration === undefined)
499193
500885
  return this._outputConfiguration;
499194
- Object.assign(this._outputConfiguration, configuration);
500886
+ this._outputConfiguration = {
500887
+ ...this._outputConfiguration,
500888
+ ...configuration
500889
+ };
499195
500890
  return this;
499196
500891
  }
499197
500892
  showHelpAfterError(displayHelp = true) {
@@ -499222,12 +500917,12 @@ var require_command = __commonJS((exports) => {
499222
500917
  createArgument(name, description) {
499223
500918
  return new Argument(name, description);
499224
500919
  }
499225
- argument(name, description, fn, defaultValue) {
500920
+ argument(name, description, parseArg, defaultValue) {
499226
500921
  const argument = this.createArgument(name, description);
499227
- if (typeof fn === "function") {
499228
- argument.default(defaultValue).argParser(fn);
500922
+ if (typeof parseArg === "function") {
500923
+ argument.default(defaultValue).argParser(parseArg);
499229
500924
  } else {
499230
- argument.default(fn);
500925
+ argument.default(parseArg);
499231
500926
  }
499232
500927
  this.addArgument(argument);
499233
500928
  return this;
@@ -499240,7 +500935,7 @@ var require_command = __commonJS((exports) => {
499240
500935
  }
499241
500936
  addArgument(argument) {
499242
500937
  const previousArgument = this.registeredArguments.slice(-1)[0];
499243
- if (previousArgument && previousArgument.variadic) {
500938
+ if (previousArgument?.variadic) {
499244
500939
  throw new Error(`only the last argument can be variadic '${previousArgument.name()}'`);
499245
500940
  }
499246
500941
  if (argument.required && argument.defaultValue !== undefined && argument.parseArg === undefined) {
@@ -499252,10 +500947,13 @@ var require_command = __commonJS((exports) => {
499252
500947
  helpCommand(enableOrNameAndArgs, description) {
499253
500948
  if (typeof enableOrNameAndArgs === "boolean") {
499254
500949
  this._addImplicitHelpCommand = enableOrNameAndArgs;
500950
+ if (enableOrNameAndArgs && this._defaultCommandGroup) {
500951
+ this._initCommandGroup(this._getHelpCommand());
500952
+ }
499255
500953
  return this;
499256
500954
  }
499257
- enableOrNameAndArgs = enableOrNameAndArgs ?? "help [command]";
499258
- const [, helpName, helpArgs] = enableOrNameAndArgs.match(/([^ ]+) *(.*)/);
500955
+ const nameAndArgs = enableOrNameAndArgs ?? "help [command]";
500956
+ const [, helpName, helpArgs] = nameAndArgs.match(/([^ ]+) *(.*)/);
499259
500957
  const helpDescription = description ?? "display help for command";
499260
500958
  const helpCommand = this.createCommand(helpName);
499261
500959
  helpCommand.helpOption(false);
@@ -499265,6 +500963,8 @@ var require_command = __commonJS((exports) => {
499265
500963
  helpCommand.description(helpDescription);
499266
500964
  this._addImplicitHelpCommand = true;
499267
500965
  this._helpCommand = helpCommand;
500966
+ if (enableOrNameAndArgs || description)
500967
+ this._initCommandGroup(helpCommand);
499268
500968
  return this;
499269
500969
  }
499270
500970
  addHelpCommand(helpCommand, deprecatedDescription) {
@@ -499274,6 +500974,7 @@ var require_command = __commonJS((exports) => {
499274
500974
  }
499275
500975
  this._addImplicitHelpCommand = true;
499276
500976
  this._helpCommand = helpCommand;
500977
+ this._initCommandGroup(helpCommand);
499277
500978
  return this;
499278
500979
  }
499279
500980
  _getHelpCommand() {
@@ -499353,6 +501054,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
499353
501054
  throw new Error(`Cannot add option '${option.flags}'${this._name && ` to command '${this._name}'`} due to conflicting flag '${matchingFlag}'
499354
501055
  - already used by option '${matchingOption.flags}'`);
499355
501056
  }
501057
+ this._initOptionGroup(option);
499356
501058
  this.options.push(option);
499357
501059
  }
499358
501060
  _registerCommand(command8) {
@@ -499365,6 +501067,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
499365
501067
  const newCmd = knownBy(command8).join("|");
499366
501068
  throw new Error(`cannot add command '${newCmd}' as already have command '${existingCmd}'`);
499367
501069
  }
501070
+ this._initCommandGroup(command8);
499368
501071
  this.commands.push(command8);
499369
501072
  }
499370
501073
  addOption(option) {
@@ -499387,7 +501090,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
499387
501090
  if (val !== null && option.parseArg) {
499388
501091
  val = this._callParseArg(option, val, oldValue, invalidValueMessage);
499389
501092
  } else if (val !== null && option.variadic) {
499390
- val = option._concatValue(val, oldValue);
501093
+ val = option._collectValue(val, oldValue);
499391
501094
  }
499392
501095
  if (val == null) {
499393
501096
  if (option.negate) {
@@ -499762,7 +501465,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
499762
501465
  this.processedArgs = processedArgs;
499763
501466
  }
499764
501467
  _chainOrCall(promise3, fn) {
499765
- if (promise3 && promise3.then && typeof promise3.then === "function") {
501468
+ if (promise3?.then && typeof promise3.then === "function") {
499766
501469
  return promise3.then(() => fn());
499767
501470
  }
499768
501471
  return fn();
@@ -499839,7 +501542,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
499839
501542
  promiseChain = this._chainOrCallHooks(promiseChain, "postAction");
499840
501543
  return promiseChain;
499841
501544
  }
499842
- if (this.parent && this.parent.listenerCount(commandEvent)) {
501545
+ if (this.parent?.listenerCount(commandEvent)) {
499843
501546
  checkForUnknownOptions();
499844
501547
  this._processArguments();
499845
501548
  this.parent.emit(commandEvent, operands, unknown3);
@@ -499901,24 +501604,31 @@ Expecting one of '${allowedValues.join("', '")}'`);
499901
501604
  cmd._checkForConflictingLocalOptions();
499902
501605
  });
499903
501606
  }
499904
- parseOptions(argv) {
501607
+ parseOptions(args) {
499905
501608
  const operands = [];
499906
501609
  const unknown3 = [];
499907
501610
  let dest = operands;
499908
- const args = argv.slice();
499909
501611
  function maybeOption(arg) {
499910
501612
  return arg.length > 1 && arg[0] === "-";
499911
501613
  }
501614
+ const negativeNumberArg = (arg) => {
501615
+ if (!/^-(\d+|\d*\.\d+)(e[+-]?\d+)?$/.test(arg))
501616
+ return false;
501617
+ return !this._getCommandAndAncestors().some((cmd) => cmd.options.map((opt) => opt.short).some((short) => /^-\d$/.test(short)));
501618
+ };
499912
501619
  let activeVariadicOption = null;
499913
- while (args.length) {
499914
- const arg = args.shift();
501620
+ let activeGroup = null;
501621
+ let i3 = 0;
501622
+ while (i3 < args.length || activeGroup) {
501623
+ const arg = activeGroup ?? args[i3++];
501624
+ activeGroup = null;
499915
501625
  if (arg === "--") {
499916
501626
  if (dest === unknown3)
499917
501627
  dest.push(arg);
499918
- dest.push(...args);
501628
+ dest.push(...args.slice(i3));
499919
501629
  break;
499920
501630
  }
499921
- if (activeVariadicOption && !maybeOption(arg)) {
501631
+ if (activeVariadicOption && (!maybeOption(arg) || negativeNumberArg(arg))) {
499922
501632
  this.emit(`option:${activeVariadicOption.name()}`, arg);
499923
501633
  continue;
499924
501634
  }
@@ -499927,14 +501637,14 @@ Expecting one of '${allowedValues.join("', '")}'`);
499927
501637
  const option = this._findOption(arg);
499928
501638
  if (option) {
499929
501639
  if (option.required) {
499930
- const value = args.shift();
501640
+ const value = args[i3++];
499931
501641
  if (value === undefined)
499932
501642
  this.optionMissingArgument(option);
499933
501643
  this.emit(`option:${option.name()}`, value);
499934
501644
  } else if (option.optional) {
499935
501645
  let value = null;
499936
- if (args.length > 0 && !maybeOption(args[0])) {
499937
- value = args.shift();
501646
+ if (i3 < args.length && (!maybeOption(args[i3]) || negativeNumberArg(args[i3]))) {
501647
+ value = args[i3++];
499938
501648
  }
499939
501649
  this.emit(`option:${option.name()}`, value);
499940
501650
  } else {
@@ -499951,7 +501661,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
499951
501661
  this.emit(`option:${option.name()}`, arg.slice(2));
499952
501662
  } else {
499953
501663
  this.emit(`option:${option.name()}`);
499954
- args.unshift(`-${arg.slice(2)}`);
501664
+ activeGroup = `-${arg.slice(2)}`;
499955
501665
  }
499956
501666
  continue;
499957
501667
  }
@@ -499964,31 +501674,24 @@ Expecting one of '${allowedValues.join("', '")}'`);
499964
501674
  continue;
499965
501675
  }
499966
501676
  }
499967
- if (maybeOption(arg)) {
501677
+ if (dest === operands && maybeOption(arg) && !(this.commands.length === 0 && negativeNumberArg(arg))) {
499968
501678
  dest = unknown3;
499969
501679
  }
499970
501680
  if ((this._enablePositionalOptions || this._passThroughOptions) && operands.length === 0 && unknown3.length === 0) {
499971
501681
  if (this._findCommand(arg)) {
499972
501682
  operands.push(arg);
499973
- if (args.length > 0)
499974
- unknown3.push(...args);
501683
+ unknown3.push(...args.slice(i3));
499975
501684
  break;
499976
501685
  } else if (this._getHelpCommand() && arg === this._getHelpCommand().name()) {
499977
- operands.push(arg);
499978
- if (args.length > 0)
499979
- operands.push(...args);
501686
+ operands.push(arg, ...args.slice(i3));
499980
501687
  break;
499981
501688
  } else if (this._defaultCommandName) {
499982
- unknown3.push(arg);
499983
- if (args.length > 0)
499984
- unknown3.push(...args);
501689
+ unknown3.push(arg, ...args.slice(i3));
499985
501690
  break;
499986
501691
  }
499987
501692
  }
499988
501693
  if (this._passThroughOptions) {
499989
- dest.push(arg);
499990
- if (args.length > 0)
499991
- dest.push(...args);
501694
+ dest.push(arg, ...args.slice(i3));
499992
501695
  break;
499993
501696
  }
499994
501697
  dest.push(arg);
@@ -500199,6 +501902,32 @@ Expecting one of '${allowedValues.join("', '")}'`);
500199
501902
  this._name = str2;
500200
501903
  return this;
500201
501904
  }
501905
+ helpGroup(heading) {
501906
+ if (heading === undefined)
501907
+ return this._helpGroupHeading ?? "";
501908
+ this._helpGroupHeading = heading;
501909
+ return this;
501910
+ }
501911
+ commandsGroup(heading) {
501912
+ if (heading === undefined)
501913
+ return this._defaultCommandGroup ?? "";
501914
+ this._defaultCommandGroup = heading;
501915
+ return this;
501916
+ }
501917
+ optionsGroup(heading) {
501918
+ if (heading === undefined)
501919
+ return this._defaultOptionGroup ?? "";
501920
+ this._defaultOptionGroup = heading;
501921
+ return this;
501922
+ }
501923
+ _initOptionGroup(option) {
501924
+ if (this._defaultOptionGroup && !option.helpGroupHeading)
501925
+ option.helpGroup(this._defaultOptionGroup);
501926
+ }
501927
+ _initCommandGroup(cmd) {
501928
+ if (this._defaultCommandGroup && !cmd.helpGroup())
501929
+ cmd.helpGroup(this._defaultCommandGroup);
501930
+ }
500202
501931
  nameFromFilename(filename) {
500203
501932
  this._name = path22.basename(filename, path22.extname(filename));
500204
501933
  return this;
@@ -500275,15 +502004,19 @@ Expecting one of '${allowedValues.join("', '")}'`);
500275
502004
  helpOption(flags, description) {
500276
502005
  if (typeof flags === "boolean") {
500277
502006
  if (flags) {
500278
- this._helpOption = this._helpOption ?? undefined;
502007
+ if (this._helpOption === null)
502008
+ this._helpOption = undefined;
502009
+ if (this._defaultOptionGroup) {
502010
+ this._initOptionGroup(this._getHelpOption());
502011
+ }
500279
502012
  } else {
500280
502013
  this._helpOption = null;
500281
502014
  }
500282
502015
  return this;
500283
502016
  }
500284
- flags = flags ?? "-h, --help";
500285
- description = description ?? "display help for command";
500286
- this._helpOption = this.createOption(flags, description);
502017
+ this._helpOption = this.createOption(flags ?? "-h, --help", description ?? "display help for command");
502018
+ if (flags || description)
502019
+ this._initOptionGroup(this._helpOption);
500287
502020
  return this;
500288
502021
  }
500289
502022
  _getHelpOption() {
@@ -500294,6 +502027,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
500294
502027
  }
500295
502028
  addHelpOption(option) {
500296
502029
  this._helpOption = option;
502030
+ this._initOptionGroup(option);
500297
502031
  return this;
500298
502032
  }
500299
502033
  help(contextOptions) {
@@ -516981,435 +518715,182 @@ var init_useIdeAtMentioned = __esm(() => {
516981
518715
  }));
516982
518716
  });
516983
518717
 
516984
- // src/buddy/sprites.ts
516985
- var BODIES;
516986
- var init_sprites = __esm(() => {
516987
- init_types4();
516988
- BODIES = {
516989
- [duck]: [
516990
- [
516991
- " ",
516992
- " __ ",
516993
- " <({E} )___ ",
516994
- " ( ._> ",
516995
- " `--´ "
516996
- ],
516997
- [
516998
- " ",
516999
- " __ ",
517000
- " <({E} )___ ",
517001
- " ( ._> ",
517002
- " `--´~ "
517003
- ],
517004
- [
517005
- " ",
517006
- " __ ",
517007
- " <({E} )___ ",
517008
- " ( .__> ",
517009
- " `--´ "
517010
- ]
517011
- ],
517012
- [goose]: [
517013
- [
517014
- " ",
517015
- " ({E}> ",
517016
- " || ",
517017
- " _(__)_ ",
517018
- " ^^^^ "
517019
- ],
517020
- [
517021
- " ",
517022
- " ({E}> ",
517023
- " || ",
517024
- " _(__)_ ",
517025
- " ^^^^ "
517026
- ],
517027
- [
517028
- " ",
517029
- " ({E}>> ",
517030
- " || ",
517031
- " _(__)_ ",
517032
- " ^^^^ "
517033
- ]
517034
- ],
517035
- [blob]: [
517036
- [
517037
- " ",
517038
- " .----. ",
517039
- " ( {E} {E} ) ",
517040
- " ( ) ",
517041
- " `----´ "
517042
- ],
517043
- [
517044
- " ",
517045
- " .------. ",
517046
- " ( {E} {E} ) ",
517047
- " ( ) ",
517048
- " `------´ "
517049
- ],
517050
- [
517051
- " ",
517052
- " .--. ",
517053
- " ({E} {E}) ",
517054
- " ( ) ",
517055
- " `--´ "
517056
- ]
517057
- ],
517058
- [cat]: [
517059
- [
517060
- " ",
517061
- " /\\_/\\ ",
517062
- " ( {E} {E}) ",
517063
- " ( ω ) ",
517064
- ' (")_(") '
517065
- ],
517066
- [
517067
- " ",
517068
- " /\\_/\\ ",
517069
- " ( {E} {E}) ",
517070
- " ( ω ) ",
517071
- ' (")_(")~ '
517072
- ],
517073
- [
517074
- " ",
517075
- " /\\-/\\ ",
517076
- " ( {E} {E}) ",
517077
- " ( ω ) ",
517078
- ' (")_(") '
517079
- ]
517080
- ],
517081
- [dragon]: [
517082
- [
517083
- " ",
517084
- " /^\\ /^\\ ",
517085
- " < {E} {E} > ",
517086
- " ( ~~ ) ",
517087
- " `-vvvv-´ "
517088
- ],
517089
- [
517090
- " ",
517091
- " /^\\ /^\\ ",
517092
- " < {E} {E} > ",
517093
- " ( ) ",
517094
- " `-vvvv-´ "
517095
- ],
517096
- [
517097
- " ~ ~ ",
517098
- " /^\\ /^\\ ",
517099
- " < {E} {E} > ",
517100
- " ( ~~ ) ",
517101
- " `-vvvv-´ "
517102
- ]
517103
- ],
517104
- [octopus]: [
517105
- [
517106
- " ",
517107
- " .----. ",
517108
- " ( {E} {E} ) ",
517109
- " (______) ",
517110
- " /\\/\\/\\/\\ "
517111
- ],
517112
- [
517113
- " ",
517114
- " .----. ",
517115
- " ( {E} {E} ) ",
517116
- " (______) ",
517117
- " \\/\\/\\/\\/ "
517118
- ],
517119
- [
517120
- " o ",
517121
- " .----. ",
517122
- " ( {E} {E} ) ",
517123
- " (______) ",
517124
- " /\\/\\/\\/\\ "
517125
- ]
517126
- ],
517127
- [owl]: [
517128
- [
517129
- " ",
517130
- " /\\ /\\ ",
517131
- " (({E})({E})) ",
517132
- " ( >< ) ",
517133
- " `----´ "
517134
- ],
517135
- [
517136
- " ",
517137
- " /\\ /\\ ",
517138
- " (({E})({E})) ",
517139
- " ( >< ) ",
517140
- " .----. "
517141
- ],
517142
- [
517143
- " ",
517144
- " /\\ /\\ ",
517145
- " (({E})(-)) ",
517146
- " ( >< ) ",
517147
- " `----´ "
517148
- ]
517149
- ],
517150
- [penguin]: [
517151
- [
517152
- " ",
517153
- " .---. ",
517154
- " ({E}>{E}) ",
517155
- " /( )\\ ",
517156
- " `---´ "
517157
- ],
517158
- [
517159
- " ",
517160
- " .---. ",
517161
- " ({E}>{E}) ",
517162
- " |( )| ",
517163
- " `---´ "
517164
- ],
517165
- [
517166
- " .---. ",
517167
- " ({E}>{E}) ",
517168
- " /( )\\ ",
517169
- " `---´ ",
517170
- " ~ ~ "
517171
- ]
517172
- ],
517173
- [turtle]: [
517174
- [
517175
- " ",
517176
- " _,--._ ",
517177
- " ( {E} {E} ) ",
517178
- " /[______]\\ ",
517179
- " `` `` "
517180
- ],
517181
- [
517182
- " ",
517183
- " _,--._ ",
517184
- " ( {E} {E} ) ",
517185
- " /[______]\\ ",
517186
- " `` `` "
517187
- ],
517188
- [
517189
- " ",
517190
- " _,--._ ",
517191
- " ( {E} {E} ) ",
517192
- " /[======]\\ ",
517193
- " `` `` "
517194
- ]
517195
- ],
517196
- [snail]: [
517197
- [
517198
- " ",
517199
- " {E} .--. ",
517200
- " \\ ( @ ) ",
517201
- " \\_`--´ ",
517202
- " ~~~~~~~ "
517203
- ],
517204
- [
517205
- " ",
517206
- " {E} .--. ",
517207
- " | ( @ ) ",
517208
- " \\_`--´ ",
517209
- " ~~~~~~~ "
517210
- ],
517211
- [
517212
- " ",
517213
- " {E} .--. ",
517214
- " \\ ( @ ) ",
517215
- " \\_`--´ ",
517216
- " ~~~~~~ "
517217
- ]
517218
- ],
517219
- [ghost]: [
517220
- [
517221
- " ",
517222
- " .----. ",
517223
- " / {E} {E} \\ ",
517224
- " | | ",
517225
- " ~`~``~`~ "
517226
- ],
517227
- [
517228
- " ",
517229
- " .----. ",
517230
- " / {E} {E} \\ ",
517231
- " | | ",
517232
- " `~`~~`~` "
517233
- ],
517234
- [
517235
- " ~ ~ ",
517236
- " .----. ",
517237
- " / {E} {E} \\ ",
517238
- " | | ",
517239
- " ~~`~~`~~ "
517240
- ]
517241
- ],
517242
- [axolotl]: [
517243
- [
517244
- " ",
517245
- "}~(______)~{",
517246
- "}~({E} .. {E})~{",
517247
- " ( .--. ) ",
517248
- " (_/ \\_) "
517249
- ],
517250
- [
517251
- " ",
517252
- "~}(______){~",
517253
- "~}({E} .. {E}){~",
517254
- " ( .--. ) ",
517255
- " (_/ \\_) "
517256
- ],
517257
- [
517258
- " ",
517259
- "}~(______)~{",
517260
- "}~({E} .. {E})~{",
517261
- " ( -- ) ",
517262
- " ~_/ \\_~ "
517263
- ]
517264
- ],
517265
- [capybara]: [
517266
- [
517267
- " ",
517268
- " n______n ",
517269
- " ( {E} {E} ) ",
517270
- " ( oo ) ",
517271
- " `------´ "
517272
- ],
517273
- [
517274
- " ",
517275
- " n______n ",
517276
- " ( {E} {E} ) ",
517277
- " ( Oo ) ",
517278
- " `------´ "
517279
- ],
517280
- [
517281
- " ~ ~ ",
517282
- " u______n ",
517283
- " ( {E} {E} ) ",
517284
- " ( oo ) ",
517285
- " `------´ "
517286
- ]
517287
- ],
517288
- [cactus]: [
517289
- [
517290
- " ",
517291
- " n ____ n ",
517292
- " | |{E} {E}| | ",
517293
- " |_| |_| ",
517294
- " | | "
517295
- ],
517296
- [
517297
- " ",
517298
- " ____ ",
517299
- " n |{E} {E}| n ",
517300
- " |_| |_| ",
517301
- " | | "
517302
- ],
517303
- [
517304
- " n n ",
517305
- " | ____ | ",
517306
- " | |{E} {E}| | ",
517307
- " |_| |_| ",
517308
- " | | "
517309
- ]
517310
- ],
517311
- [robot]: [
517312
- [
517313
- " ",
517314
- " .[||]. ",
517315
- " [ {E} {E} ] ",
517316
- " [ ==== ] ",
517317
- " `------´ "
517318
- ],
517319
- [
517320
- " ",
517321
- " .[||]. ",
517322
- " [ {E} {E} ] ",
517323
- " [ -==- ] ",
517324
- " `------´ "
517325
- ],
517326
- [
517327
- " * ",
517328
- " .[||]. ",
517329
- " [ {E} {E} ] ",
517330
- " [ ==== ] ",
517331
- " `------´ "
517332
- ]
517333
- ],
517334
- [rabbit]: [
517335
- [
517336
- " ",
517337
- " (\\__/) ",
517338
- " ( {E} {E} ) ",
517339
- " =( .. )= ",
517340
- ' (")__(") '
517341
- ],
517342
- [
517343
- " ",
517344
- " (|__/) ",
517345
- " ( {E} {E} ) ",
517346
- " =( .. )= ",
517347
- ' (")__(") '
517348
- ],
517349
- [
517350
- " ",
517351
- " (\\__/) ",
517352
- " ( {E} {E} ) ",
517353
- " =( . . )= ",
517354
- ' (")__(") '
517355
- ]
517356
- ],
517357
- [mushroom]: [
517358
- [
517359
- " ",
517360
- " .-o-OO-o-. ",
517361
- "(__________)",
517362
- " |{E} {E}| ",
517363
- " |____| "
517364
- ],
517365
- [
517366
- " ",
517367
- " .-O-oo-O-. ",
517368
- "(__________)",
517369
- " |{E} {E}| ",
517370
- " |____| "
517371
- ],
517372
- [
517373
- " . o . ",
517374
- " .-o-OO-o-. ",
517375
- "(__________)",
517376
- " |{E} {E}| ",
517377
- " |____| "
518718
+ // src/buddy/CompanionSprite.tsx
518719
+ function wrap(text2, width) {
518720
+ const words = text2.split(" ");
518721
+ const lines2 = [];
518722
+ let cur = "";
518723
+ for (const w2 of words) {
518724
+ if (cur.length + w2.length + 1 > width && cur) {
518725
+ lines2.push(cur);
518726
+ cur = w2;
518727
+ } else {
518728
+ cur = cur ? `${cur} ${w2}` : w2;
518729
+ }
518730
+ }
518731
+ if (cur)
518732
+ lines2.push(cur);
518733
+ return lines2;
518734
+ }
518735
+ function SpeechBubble(t0) {
518736
+ const $3 = import_compiler_runtime312.c(31);
518737
+ const {
518738
+ text: text2,
518739
+ color: color3,
518740
+ fading,
518741
+ tail
518742
+ } = t0;
518743
+ let T0;
518744
+ let borderColor;
518745
+ let t1;
518746
+ let t2;
518747
+ let t3;
518748
+ let t4;
518749
+ let t5;
518750
+ let t6;
518751
+ if ($3[0] !== color3 || $3[1] !== fading || $3[2] !== text2) {
518752
+ const lines2 = wrap(text2, 30);
518753
+ borderColor = fading ? "inactive" : color3;
518754
+ T0 = ThemedBox_default;
518755
+ t1 = "column";
518756
+ t2 = "round";
518757
+ t3 = borderColor;
518758
+ t4 = 1;
518759
+ t5 = 34;
518760
+ let t72;
518761
+ if ($3[11] !== fading) {
518762
+ t72 = (l, i3) => /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
518763
+ italic: true,
518764
+ dimColor: !fading,
518765
+ color: fading ? "inactive" : undefined,
518766
+ children: l
518767
+ }, i3, false, undefined, this);
518768
+ $3[11] = fading;
518769
+ $3[12] = t72;
518770
+ } else {
518771
+ t72 = $3[12];
518772
+ }
518773
+ t6 = lines2.map(t72);
518774
+ $3[0] = color3;
518775
+ $3[1] = fading;
518776
+ $3[2] = text2;
518777
+ $3[3] = T0;
518778
+ $3[4] = borderColor;
518779
+ $3[5] = t1;
518780
+ $3[6] = t2;
518781
+ $3[7] = t3;
518782
+ $3[8] = t4;
518783
+ $3[9] = t5;
518784
+ $3[10] = t6;
518785
+ } else {
518786
+ T0 = $3[3];
518787
+ borderColor = $3[4];
518788
+ t1 = $3[5];
518789
+ t2 = $3[6];
518790
+ t3 = $3[7];
518791
+ t4 = $3[8];
518792
+ t5 = $3[9];
518793
+ t6 = $3[10];
518794
+ }
518795
+ let t7;
518796
+ if ($3[13] !== T0 || $3[14] !== t1 || $3[15] !== t2 || $3[16] !== t3 || $3[17] !== t4 || $3[18] !== t5 || $3[19] !== t6) {
518797
+ t7 = /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(T0, {
518798
+ flexDirection: t1,
518799
+ borderStyle: t2,
518800
+ borderColor: t3,
518801
+ paddingX: t4,
518802
+ width: t5,
518803
+ children: t6
518804
+ }, undefined, false, undefined, this);
518805
+ $3[13] = T0;
518806
+ $3[14] = t1;
518807
+ $3[15] = t2;
518808
+ $3[16] = t3;
518809
+ $3[17] = t4;
518810
+ $3[18] = t5;
518811
+ $3[19] = t6;
518812
+ $3[20] = t7;
518813
+ } else {
518814
+ t7 = $3[20];
518815
+ }
518816
+ const bubble = t7;
518817
+ if (tail === "right") {
518818
+ let t82;
518819
+ if ($3[21] !== borderColor) {
518820
+ t82 = /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
518821
+ color: borderColor,
518822
+ children: "─"
518823
+ }, undefined, false, undefined, this);
518824
+ $3[21] = borderColor;
518825
+ $3[22] = t82;
518826
+ } else {
518827
+ t82 = $3[22];
518828
+ }
518829
+ let t92;
518830
+ if ($3[23] !== bubble || $3[24] !== t82) {
518831
+ t92 = /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedBox_default, {
518832
+ flexDirection: "row",
518833
+ alignItems: "center",
518834
+ children: [
518835
+ bubble,
518836
+ t82
518837
+ ]
518838
+ }, undefined, true, undefined, this);
518839
+ $3[23] = bubble;
518840
+ $3[24] = t82;
518841
+ $3[25] = t92;
518842
+ } else {
518843
+ t92 = $3[25];
518844
+ }
518845
+ return t92;
518846
+ }
518847
+ let t8;
518848
+ if ($3[26] !== borderColor) {
518849
+ t8 = /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedBox_default, {
518850
+ flexDirection: "column",
518851
+ alignItems: "flex-end",
518852
+ paddingRight: 6,
518853
+ children: [
518854
+ /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
518855
+ color: borderColor,
518856
+ children: " "
518857
+ }, undefined, false, undefined, this),
518858
+ /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
518859
+ color: borderColor,
518860
+ children: "╲"
518861
+ }, undefined, false, undefined, this)
517378
518862
  ]
517379
- ],
517380
- [chonk]: [
517381
- [
517382
- " ",
517383
- " /\\ /\\ ",
517384
- " ( {E} {E} ) ",
517385
- " ( .. ) ",
517386
- " `------´ "
517387
- ],
517388
- [
517389
- " ",
517390
- " /\\ /| ",
517391
- " ( {E} {E} ) ",
517392
- " ( .. ) ",
517393
- " `------´ "
517394
- ],
517395
- [
517396
- " ",
517397
- " /\\ /\\ ",
517398
- " ( {E} {E} ) ",
517399
- " ( .. ) ",
517400
- " `------´~ "
518863
+ }, undefined, true, undefined, this);
518864
+ $3[26] = borderColor;
518865
+ $3[27] = t8;
518866
+ } else {
518867
+ t8 = $3[27];
518868
+ }
518869
+ let t9;
518870
+ if ($3[28] !== bubble || $3[29] !== t8) {
518871
+ t9 = /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedBox_default, {
518872
+ flexDirection: "column",
518873
+ alignItems: "flex-end",
518874
+ marginRight: 1,
518875
+ children: [
518876
+ bubble,
518877
+ t8
517401
518878
  ]
517402
- ]
517403
- };
517404
- });
517405
-
517406
- // src/buddy/CompanionSprite.tsx
518879
+ }, undefined, true, undefined, this);
518880
+ $3[28] = bubble;
518881
+ $3[29] = t8;
518882
+ $3[30] = t9;
518883
+ } else {
518884
+ t9 = $3[30];
518885
+ }
518886
+ return t9;
518887
+ }
517407
518888
  function spriteColWidth(nameWidth) {
517408
518889
  return Math.max(SPRITE_BODY_WIDTH, nameWidth + NAME_ROW_PAD);
517409
518890
  }
517410
518891
  function companionReservedColumns(terminalColumns, speaking) {
517411
- if (true)
517412
- return 0;
518892
+ if (false)
518893
+ ;
517413
518894
  const companion = getCompanion();
517414
518895
  if (!companion || getGlobalConfig().companionMuted)
517415
518896
  return 0;
@@ -517419,7 +518900,233 @@ function companionReservedColumns(terminalColumns, speaking) {
517419
518900
  const bubble = speaking && !isFullscreenActive() ? BUBBLE_WIDTH : 0;
517420
518901
  return spriteColWidth(nameWidth) + SPRITE_PADDING_X + bubble;
517421
518902
  }
517422
- var import_compiler_runtime312, import_react224, jsx_dev_runtime400, H3, PET_HEARTS, MIN_COLS_FOR_FULL_SPRITE = 100, SPRITE_BODY_WIDTH = 12, NAME_ROW_PAD = 2, SPRITE_PADDING_X = 2, BUBBLE_WIDTH = 36;
518903
+ function CompanionSprite() {
518904
+ const reaction = useAppState((s) => s.companionReaction);
518905
+ const petAt = useAppState((s) => s.companionPetAt);
518906
+ const focused = useAppState((s) => s.footerSelection === "companion");
518907
+ const setAppState = useSetAppState();
518908
+ const {
518909
+ columns
518910
+ } = useTerminalSize();
518911
+ const [tick, setTick] = import_react224.useState(0);
518912
+ const lastSpokeTick = import_react224.useRef(0);
518913
+ const [{
518914
+ petStartTick,
518915
+ forPetAt
518916
+ }, setPetStart] = import_react224.useState({
518917
+ petStartTick: 0,
518918
+ forPetAt: petAt
518919
+ });
518920
+ if (petAt !== forPetAt) {
518921
+ setPetStart({
518922
+ petStartTick: tick,
518923
+ forPetAt: petAt
518924
+ });
518925
+ }
518926
+ import_react224.useEffect(() => {
518927
+ const timer = setInterval((setT) => setT((t) => t + 1), TICK_MS2, setTick);
518928
+ return () => clearInterval(timer);
518929
+ }, []);
518930
+ import_react224.useEffect(() => {
518931
+ if (!reaction)
518932
+ return;
518933
+ lastSpokeTick.current = tick;
518934
+ const timer = setTimeout((setA) => setA((prev) => prev.companionReaction === undefined ? prev : {
518935
+ ...prev,
518936
+ companionReaction: undefined
518937
+ }), BUBBLE_SHOW * TICK_MS2, setAppState);
518938
+ return () => clearTimeout(timer);
518939
+ }, [reaction, setAppState]);
518940
+ if (false)
518941
+ ;
518942
+ const companion = getCompanion();
518943
+ if (!companion || getGlobalConfig().companionMuted)
518944
+ return null;
518945
+ const color3 = RARITY_COLORS[companion.rarity];
518946
+ const colWidth = spriteColWidth(stringWidth(companion.name));
518947
+ const bubbleAge = reaction ? tick - lastSpokeTick.current : 0;
518948
+ const fading = reaction !== undefined && bubbleAge >= BUBBLE_SHOW - FADE_WINDOW;
518949
+ const petAge = petAt ? tick - petStartTick : Infinity;
518950
+ const petting = petAge * TICK_MS2 < PET_BURST_MS;
518951
+ if (columns < MIN_COLS_FOR_FULL_SPRITE) {
518952
+ const quip = reaction && reaction.length > NARROW_QUIP_CAP ? reaction.slice(0, NARROW_QUIP_CAP - 1) + "…" : reaction;
518953
+ const label = quip ? `"${quip}"` : focused ? ` ${companion.name} ` : companion.name;
518954
+ return /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedBox_default, {
518955
+ paddingX: 1,
518956
+ alignSelf: "flex-end",
518957
+ children: /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
518958
+ children: [
518959
+ petting && /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
518960
+ color: "autoAccept",
518961
+ children: [
518962
+ figures_default.heart,
518963
+ " "
518964
+ ]
518965
+ }, undefined, true, undefined, this),
518966
+ /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
518967
+ bold: true,
518968
+ color: color3,
518969
+ children: renderFace(companion)
518970
+ }, undefined, false, undefined, this),
518971
+ " ",
518972
+ /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
518973
+ italic: true,
518974
+ dimColor: !focused && !reaction,
518975
+ bold: focused,
518976
+ inverse: focused && !reaction,
518977
+ color: reaction ? fading ? "inactive" : color3 : focused ? color3 : undefined,
518978
+ children: label
518979
+ }, undefined, false, undefined, this)
518980
+ ]
518981
+ }, undefined, true, undefined, this)
518982
+ }, undefined, false, undefined, this);
518983
+ }
518984
+ const frameCount = spriteFrameCount(companion.species);
518985
+ const heartFrame = petting ? PET_HEARTS[petAge % PET_HEARTS.length] : null;
518986
+ let spriteFrame;
518987
+ let blink = false;
518988
+ if (reaction || petting) {
518989
+ spriteFrame = tick % frameCount;
518990
+ } else {
518991
+ const step = IDLE_SEQUENCE[tick % IDLE_SEQUENCE.length];
518992
+ if (step === -1) {
518993
+ spriteFrame = 0;
518994
+ blink = true;
518995
+ } else {
518996
+ spriteFrame = step % frameCount;
518997
+ }
518998
+ }
518999
+ const body = renderSprite(companion, spriteFrame).map((line) => blink ? line.replaceAll(companion.eye, "-") : line);
519000
+ const sprite = heartFrame ? [heartFrame, ...body] : body;
519001
+ const spriteColumn = /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedBox_default, {
519002
+ flexDirection: "column",
519003
+ flexShrink: 0,
519004
+ alignItems: "center",
519005
+ width: colWidth,
519006
+ children: [
519007
+ sprite.map((line, i3) => /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
519008
+ color: i3 === 0 && heartFrame ? "autoAccept" : color3,
519009
+ children: line
519010
+ }, i3, false, undefined, this)),
519011
+ /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedText, {
519012
+ italic: true,
519013
+ bold: focused,
519014
+ dimColor: !focused,
519015
+ color: focused ? color3 : undefined,
519016
+ inverse: focused,
519017
+ children: focused ? ` ${companion.name} ` : companion.name
519018
+ }, undefined, false, undefined, this)
519019
+ ]
519020
+ }, undefined, true, undefined, this);
519021
+ if (!reaction) {
519022
+ return /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedBox_default, {
519023
+ paddingX: 1,
519024
+ children: spriteColumn
519025
+ }, undefined, false, undefined, this);
519026
+ }
519027
+ if (isFullscreenActive()) {
519028
+ return /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedBox_default, {
519029
+ paddingX: 1,
519030
+ children: spriteColumn
519031
+ }, undefined, false, undefined, this);
519032
+ }
519033
+ return /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(ThemedBox_default, {
519034
+ flexDirection: "row",
519035
+ alignItems: "flex-end",
519036
+ paddingX: 1,
519037
+ flexShrink: 0,
519038
+ children: [
519039
+ /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(SpeechBubble, {
519040
+ text: reaction,
519041
+ color: color3,
519042
+ fading,
519043
+ tail: "right"
519044
+ }, undefined, false, undefined, this),
519045
+ spriteColumn
519046
+ ]
519047
+ }, undefined, true, undefined, this);
519048
+ }
519049
+ function CompanionFloatingBubble() {
519050
+ const $3 = import_compiler_runtime312.c(8);
519051
+ const reaction = useAppState(_temp188);
519052
+ let t0;
519053
+ if ($3[0] !== reaction) {
519054
+ t0 = {
519055
+ tick: 0,
519056
+ forReaction: reaction
519057
+ };
519058
+ $3[0] = reaction;
519059
+ $3[1] = t0;
519060
+ } else {
519061
+ t0 = $3[1];
519062
+ }
519063
+ const [t1, setTick] = import_react224.useState(t0);
519064
+ const {
519065
+ tick,
519066
+ forReaction
519067
+ } = t1;
519068
+ if (reaction !== forReaction) {
519069
+ setTick({
519070
+ tick: 0,
519071
+ forReaction: reaction
519072
+ });
519073
+ }
519074
+ let t2;
519075
+ let t3;
519076
+ if ($3[2] !== reaction) {
519077
+ t2 = () => {
519078
+ if (!reaction) {
519079
+ return;
519080
+ }
519081
+ const timer = setInterval(_temp352, TICK_MS2, setTick);
519082
+ return () => clearInterval(timer);
519083
+ };
519084
+ t3 = [reaction];
519085
+ $3[2] = reaction;
519086
+ $3[3] = t2;
519087
+ $3[4] = t3;
519088
+ } else {
519089
+ t2 = $3[3];
519090
+ t3 = $3[4];
519091
+ }
519092
+ import_react224.useEffect(t2, t3);
519093
+ if (!reaction) {
519094
+ return null;
519095
+ }
519096
+ const companion = getCompanion();
519097
+ if (!companion || getGlobalConfig().companionMuted) {
519098
+ return null;
519099
+ }
519100
+ const t4 = tick >= BUBBLE_SHOW - FADE_WINDOW;
519101
+ let t5;
519102
+ if ($3[5] !== reaction || $3[6] !== t4) {
519103
+ t5 = /* @__PURE__ */ jsx_dev_runtime400.jsxDEV(SpeechBubble, {
519104
+ text: reaction,
519105
+ color: RARITY_COLORS[companion.rarity],
519106
+ fading: t4,
519107
+ tail: "down"
519108
+ }, undefined, false, undefined, this);
519109
+ $3[5] = reaction;
519110
+ $3[6] = t4;
519111
+ $3[7] = t5;
519112
+ } else {
519113
+ t5 = $3[7];
519114
+ }
519115
+ return t5;
519116
+ }
519117
+ function _temp352(set3) {
519118
+ return set3(_temp278);
519119
+ }
519120
+ function _temp278(s_0) {
519121
+ return {
519122
+ ...s_0,
519123
+ tick: s_0.tick + 1
519124
+ };
519125
+ }
519126
+ function _temp188(s) {
519127
+ return s.companionReaction;
519128
+ }
519129
+ var import_compiler_runtime312, import_react224, jsx_dev_runtime400, TICK_MS2 = 500, BUBBLE_SHOW = 20, FADE_WINDOW = 6, PET_BURST_MS = 2500, IDLE_SEQUENCE, H3, PET_HEARTS, MIN_COLS_FOR_FULL_SPRITE = 100, SPRITE_BODY_WIDTH = 12, NAME_ROW_PAD = 2, SPRITE_PADDING_X = 2, BUBBLE_WIDTH = 36, NARROW_QUIP_CAP = 24;
517423
519130
  var init_CompanionSprite = __esm(() => {
517424
519131
  init_figures();
517425
519132
  init_useTerminalSize();
@@ -517434,6 +519141,7 @@ var init_CompanionSprite = __esm(() => {
517434
519141
  import_compiler_runtime312 = __toESM(require_compiler_runtime(), 1);
517435
519142
  import_react224 = __toESM(require_react(), 1);
517436
519143
  jsx_dev_runtime400 = __toESM(require_jsx_dev_runtime(), 1);
519144
+ IDLE_SEQUENCE = [0, 0, 0, 0, 1, 0, 0, 0, -1, 0, 0, 2, 0, 0, 0];
517437
519145
  H3 = figures_default.heart;
517438
519146
  PET_HEARTS = [` ${H3} ${H3} `, ` ${H3} ${H3} ${H3} `, ` ${H3} ${H3} ${H3} `, `${H3} ${H3} ${H3} `, "· · · "];
517439
519147
  });
@@ -517453,7 +519161,7 @@ function RainbowText2(t0) {
517453
519161
  let t1;
517454
519162
  if ($3[0] !== text2) {
517455
519163
  t1 = /* @__PURE__ */ jsx_dev_runtime401.jsxDEV(jsx_dev_runtime401.Fragment, {
517456
- children: [...text2].map(_temp188)
519164
+ children: [...text2].map(_temp189)
517457
519165
  }, undefined, false, undefined, this);
517458
519166
  $3[0] = text2;
517459
519167
  $3[1] = t1;
@@ -517462,7 +519170,7 @@ function RainbowText2(t0) {
517462
519170
  }
517463
519171
  return t1;
517464
519172
  }
517465
- function _temp188(ch2, i3) {
519173
+ function _temp189(ch2, i3) {
517466
519174
  return /* @__PURE__ */ jsx_dev_runtime401.jsxDEV(ThemedText, {
517467
519175
  color: getRainbowColor(i3),
517468
519176
  children: ch2
@@ -517478,9 +519186,7 @@ function useBuddyNotification() {
517478
519186
  let t1;
517479
519187
  if ($3[0] !== addNotification || $3[1] !== removeNotification) {
517480
519188
  t0 = () => {
517481
- if (true) {
517482
- return;
517483
- }
519189
+ if (false) {}
517484
519190
  const config5 = getGlobalConfig();
517485
519191
  if (config5.companion || !isBuddyTeaserWindow()) {
517486
519192
  return;
@@ -517507,8 +519213,8 @@ function useBuddyNotification() {
517507
519213
  import_react225.useEffect(t0, t1);
517508
519214
  }
517509
519215
  function findBuddyTriggerPositions(text2) {
517510
- if (true)
517511
- return [];
519216
+ if (false)
519217
+ ;
517512
519218
  const triggers = [];
517513
519219
  const re2 = /\/buddy\b/g;
517514
519220
  let m2;
@@ -518526,7 +520232,7 @@ function Notifications(t0) {
518526
520232
  const {
518527
520233
  status: ideStatus
518528
520234
  } = useIdeConnectionStatus(mcpClients);
518529
- const notifications = useAppState(_temp189);
520235
+ const notifications = useAppState(_temp190);
518530
520236
  const {
518531
520237
  addNotification,
518532
520238
  removeNotification
@@ -518545,7 +520251,7 @@ function Notifications(t0) {
518545
520251
  timeoutMs: isError ? 8000 : 5000
518546
520252
  });
518547
520253
  });
518548
- return _temp278;
520254
+ return _temp279;
518549
520255
  };
518550
520256
  t6 = [addNotification];
518551
520257
  $3[5] = addNotification;
@@ -518672,10 +520378,10 @@ function Notifications(t0) {
518672
520378
  }
518673
520379
  return t14;
518674
520380
  }
518675
- function _temp278() {
520381
+ function _temp279() {
518676
520382
  return setEnvHookNotifier(null);
518677
520383
  }
518678
- function _temp189(s) {
520384
+ function _temp190(s) {
518679
520385
  return s.notifications;
518680
520386
  }
518681
520387
  function NotificationContent({
@@ -522621,9 +524327,9 @@ function BridgeDialog(t0) {
522621
524327
  onDone
522622
524328
  } = t0;
522623
524329
  useRegisterOverlay("bridge-dialog");
522624
- const connected = useAppState(_temp190);
522625
- const sessionActive = useAppState(_temp279);
522626
- const reconnecting = useAppState(_temp352);
524330
+ const connected = useAppState(_temp191);
524331
+ const sessionActive = useAppState(_temp280);
524332
+ const reconnecting = useAppState(_temp353);
522627
524333
  const connectUrl = useAppState(_temp439);
522628
524334
  const sessionUrl = useAppState(_temp528);
522629
524335
  const error49 = useAppState(_temp622);
@@ -523051,13 +524757,13 @@ function _temp528(s_3) {
523051
524757
  function _temp439(s_2) {
523052
524758
  return s_2.replBridgeConnectUrl;
523053
524759
  }
523054
- function _temp352(s_1) {
524760
+ function _temp353(s_1) {
523055
524761
  return s_1.replBridgeReconnecting;
523056
524762
  }
523057
- function _temp279(s_0) {
524763
+ function _temp280(s_0) {
523058
524764
  return s_0.replBridgeSessionActive;
523059
524765
  }
523060
- function _temp190(s) {
524766
+ function _temp191(s) {
523061
524767
  return s.replBridgeConnected;
523062
524768
  }
523063
524769
  var import_compiler_runtime321, import_react243, jsx_dev_runtime414;
@@ -523083,12 +524789,12 @@ function getVisibleAgentTasks(tasks2) {
523083
524789
  return Object.values(tasks2).filter((t) => isPanelAgentTask(t) && t.evictAfter !== 0).sort((a2, b3) => a2.startTime - b3.startTime);
523084
524790
  }
523085
524791
  function useCoordinatorTaskCount() {
523086
- const tasks2 = useAppState(_temp191);
524792
+ const tasks2 = useAppState(_temp192);
523087
524793
  let t0;
523088
524794
  t0 = 0;
523089
524795
  return t0;
523090
524796
  }
523091
- function _temp191(s) {
524797
+ function _temp192(s) {
523092
524798
  return s.tasks;
523093
524799
  }
523094
524800
  var import_compiler_runtime322, React136, jsx_dev_runtime415;
@@ -523334,7 +525040,7 @@ function ThinkingToggle(t0) {
523334
525040
  defaultFocusValue: currentValue ? "true" : "false",
523335
525041
  options,
523336
525042
  onChange: handleSelectChange,
523337
- onCancel: onCancel ?? _temp192,
525043
+ onCancel: onCancel ?? _temp193,
523338
525044
  visibleOptionCount: 2
523339
525045
  }, undefined, false, undefined, this)
523340
525046
  }, undefined, false, undefined, this)
@@ -523411,7 +525117,7 @@ function ThinkingToggle(t0) {
523411
525117
  }
523412
525118
  return t11;
523413
525119
  }
523414
- function _temp192() {}
525120
+ function _temp193() {}
523415
525121
  var import_compiler_runtime326, import_react248, jsx_dev_runtime421;
523416
525122
  var init_ThinkingToggle = __esm(() => {
523417
525123
  init_useExitOnCtrlCDWithKeybindings();
@@ -523859,7 +525565,7 @@ function TeammateDetailView(t0) {
523859
525565
  if ($3[6] === Symbol.for("react.memo_cache_sentinel")) {
523860
525566
  t4 = (input) => {
523861
525567
  if (input === "p") {
523862
- setPromptExpanded(_temp193);
525568
+ setPromptExpanded(_temp194);
523863
525569
  }
523864
525570
  };
523865
525571
  $3[6] = t4;
@@ -523950,7 +525656,7 @@ function TeammateDetailView(t0) {
523950
525656
  bold: true,
523951
525657
  children: "Tasks"
523952
525658
  }, undefined, false, undefined, this),
523953
- teammateTasks.map(_temp280)
525659
+ teammateTasks.map(_temp281)
523954
525660
  ]
523955
525661
  }, undefined, true, undefined, this);
523956
525662
  $3[23] = teammateTasks;
@@ -524043,7 +525749,7 @@ function TeammateDetailView(t0) {
524043
525749
  }
524044
525750
  return t13;
524045
525751
  }
524046
- function _temp280(task_0) {
525752
+ function _temp281(task_0) {
524047
525753
  return /* @__PURE__ */ jsx_dev_runtime422.jsxDEV(ThemedText, {
524048
525754
  color: task_0.status === "completed" ? "success" : undefined,
524049
525755
  children: [
@@ -524053,7 +525759,7 @@ function _temp280(task_0) {
524053
525759
  ]
524054
525760
  }, task_0.id, true, undefined, this);
524055
525761
  }
524056
- function _temp193(prev) {
525762
+ function _temp194(prev) {
524057
525763
  return !prev;
524058
525764
  }
524059
525765
  async function killTeammate(paneId, backendType, teamName, teammateId, teammateName, setAppState) {
@@ -524742,7 +526448,7 @@ function createInitialPersistentState() {
524742
526448
  };
524743
526449
  }
524744
526450
  var OPERATORS, SIMPLE_MOTIONS, FIND_KEYS, TEXT_OBJ_SCOPES, TEXT_OBJ_TYPES, MAX_VIM_COUNT = 1e4;
524745
- var init_types14 = __esm(() => {
526451
+ var init_types15 = __esm(() => {
524746
526452
  OPERATORS = {
524747
526453
  d: "delete",
524748
526454
  c: "change",
@@ -525088,7 +526794,7 @@ function executeRepeatFind(reverse, count4, ctx) {
525088
526794
  }
525089
526795
  var init_transitions = __esm(() => {
525090
526796
  init_operators();
525091
- init_types14();
526797
+ init_types15();
525092
526798
  });
525093
526799
 
525094
526800
  // src/hooks/useVimInput.ts
@@ -525288,7 +526994,7 @@ var init_useVimInput = __esm(() => {
525288
526994
  init_intl();
525289
526995
  init_operators();
525290
526996
  init_transitions();
525291
- init_types14();
526997
+ init_types15();
525292
526998
  init_useTextInput();
525293
526999
  import_react250 = __toESM(require_react(), 1);
525294
527000
  });
@@ -525313,7 +527019,7 @@ function VimTextInput(props) {
525313
527019
  const t11 = props.multiline;
525314
527020
  const t12 = props.showCursor ? " " : "";
525315
527021
  const t13 = props.highlightPastedText;
525316
- const t14 = isTerminalFocused ? source_default.inverse : _temp194;
527022
+ const t14 = isTerminalFocused ? source_default.inverse : _temp195;
525317
527023
  let t15;
525318
527024
  if ($3[0] !== theme2) {
525319
527025
  t15 = color("text", theme2);
@@ -525426,7 +527132,7 @@ function VimTextInput(props) {
525426
527132
  }
525427
527133
  return t19;
525428
527134
  }
525429
- function _temp194(text2) {
527135
+ function _temp195(text2) {
525430
527136
  return text2;
525431
527137
  }
525432
527138
  var import_compiler_runtime328, import_react251, jsx_dev_runtime423;
@@ -525800,11 +527506,11 @@ function BackgroundTaskStatus(t0) {
525800
527506
  const {
525801
527507
  columns
525802
527508
  } = useTerminalSize();
525803
- const tasks2 = useAppState(_temp195);
525804
- const viewingAgentTaskId = useAppState(_temp281);
527509
+ const tasks2 = useAppState(_temp196);
527510
+ const viewingAgentTaskId = useAppState(_temp282);
525805
527511
  let t3;
525806
527512
  if ($3[0] !== tasks2) {
525807
- t3 = Object.values(tasks2 ?? {}).filter(_temp353);
527513
+ t3 = Object.values(tasks2 ?? {}).filter(_temp354);
525808
527514
  $3[0] = tasks2;
525809
527515
  $3[1] = t3;
525810
527516
  } else {
@@ -526089,13 +527795,13 @@ function _temp529(t_0) {
526089
527795
  function _temp440(s_1) {
526090
527796
  return s_1.expandedView;
526091
527797
  }
526092
- function _temp353(t) {
527798
+ function _temp354(t) {
526093
527799
  return isBackgroundTask(t) && true;
526094
527800
  }
526095
- function _temp281(s_0) {
527801
+ function _temp282(s_0) {
526096
527802
  return s_0.viewingAgentTaskId;
526097
527803
  }
526098
- function _temp195(s) {
527804
+ function _temp196(s) {
526099
527805
  return s.tasks;
526100
527806
  }
526101
527807
  function AgentPill(t0) {
@@ -526317,10 +528023,10 @@ function TeamStatus(t0) {
526317
528023
  teamsSelected,
526318
528024
  showHint
526319
528025
  } = t0;
526320
- const teamContext = useAppState(_temp196);
528026
+ const teamContext = useAppState(_temp197);
526321
528027
  let t1;
526322
528028
  if ($3[0] !== teamContext) {
526323
- t1 = teamContext ? Object.values(teamContext.teammates).filter(_temp282).length : 0;
528029
+ t1 = teamContext ? Object.values(teamContext.teammates).filter(_temp283).length : 0;
526324
528030
  $3[0] = teamContext;
526325
528031
  $3[1] = t1;
526326
528032
  } else {
@@ -526396,10 +528102,10 @@ function TeamStatus(t0) {
526396
528102
  }
526397
528103
  return t6;
526398
528104
  }
526399
- function _temp282(t) {
528105
+ function _temp283(t) {
526400
528106
  return t.name !== "team-lead";
526401
528107
  }
526402
- function _temp196(s) {
528108
+ function _temp197(s) {
526403
528109
  return s.teamContext;
526404
528110
  }
526405
528111
  var import_compiler_runtime330, jsx_dev_runtime426;
@@ -526437,7 +528143,7 @@ function HistorySearchInput(t0) {
526437
528143
  value,
526438
528144
  onChange,
526439
528145
  cursorOffset: value.length,
526440
- onChangeCursorOffset: _temp197,
528146
+ onChangeCursorOffset: _temp198,
526441
528147
  columns: t3,
526442
528148
  focus: true,
526443
528149
  showCursor: true,
@@ -526468,7 +528174,7 @@ function HistorySearchInput(t0) {
526468
528174
  }
526469
528175
  return t5;
526470
528176
  }
526471
- function _temp197() {}
528177
+ function _temp198() {}
526472
528178
  var import_compiler_runtime331, jsx_dev_runtime427, HistorySearchInput_default;
526473
528179
  var init_HistorySearchInput = __esm(() => {
526474
528180
  init_stringWidth();
@@ -527973,10 +529679,7 @@ function PromptInput({
527973
529679
  const {
527974
529680
  companion: _companion,
527975
529681
  companionMuted
527976
- } = {
527977
- companion: undefined,
527978
- companionMuted: undefined
527979
- };
529682
+ } = getGlobalConfig();
527980
529683
  const companionFooterVisible = !!_companion && !companionMuted;
527981
529684
  const briefOwnsGap = false;
527982
529685
  const mainLoopModel_ = useAppState((s) => s.mainLoopModel);
@@ -529009,7 +530712,10 @@ function PromptInput({
529009
530712
  }
529010
530713
  switch (footerItemSelected) {
529011
530714
  case "companion":
529012
- if (false) {}
530715
+ if (true) {
530716
+ selectFooterItem(null);
530717
+ onSubmit("/buddy");
530718
+ }
529013
530719
  break;
529014
530720
  case "tasks":
529015
530721
  if (isTeammateMode) {
@@ -529168,7 +530874,7 @@ function PromptInput({
529168
530874
  });
529169
530875
  }, [effortNotificationText, addNotification, removeNotification]);
529170
530876
  useBuddyNotification();
529171
- const companionSpeaking = false;
530877
+ const companionSpeaking = useAppState((s) => s.companionReaction !== undefined);
529172
530878
  const {
529173
530879
  columns,
529174
530880
  rows
@@ -535121,7 +536827,7 @@ var init_useManagePlugins = __esm(() => {
535121
536827
  // src/components/TeammateViewHeader.tsx
535122
536828
  function TeammateViewHeader() {
535123
536829
  const $3 = import_compiler_runtime341.c(14);
535124
- const viewedTeammate = useAppState(_temp198);
536830
+ const viewedTeammate = useAppState(_temp199);
535125
536831
  if (!viewedTeammate) {
535126
536832
  return null;
535127
536833
  }
@@ -535220,7 +536926,7 @@ function TeammateViewHeader() {
535220
536926
  }
535221
536927
  return t6;
535222
536928
  }
535223
- function _temp198(s) {
536929
+ function _temp199(s) {
535224
536930
  return getViewedTeammateTask(s);
535225
536931
  }
535226
536932
  var import_compiler_runtime341, jsx_dev_runtime440;
@@ -536333,7 +538039,7 @@ function SessionBackgroundHint(t0) {
536333
538039
  const setAppState = useSetAppState();
536334
538040
  const appStateStore = useAppStateStore();
536335
538041
  const [showSessionHint, setShowSessionHint] = import_react288.useState(false);
536336
- const handleDoublePress = useDoublePress(setShowSessionHint, onBackgroundSession, _temp199);
538042
+ const handleDoublePress = useDoublePress(setShowSessionHint, onBackgroundSession, _temp200);
536337
538043
  let t1;
536338
538044
  if ($3[0] !== appStateStore || $3[1] !== handleDoublePress || $3[2] !== isLoading || $3[3] !== setAppState) {
536339
538045
  t1 = () => {
@@ -536344,7 +538050,7 @@ function SessionBackgroundHint(t0) {
536344
538050
  if (hasForegroundTasks(state2)) {
536345
538051
  backgroundAll(() => appStateStore.getState(), setAppState);
536346
538052
  if (!getGlobalConfig().hasUsedBackgroundTask) {
536347
- saveGlobalConfig(_temp283);
538053
+ saveGlobalConfig(_temp284);
536348
538054
  }
536349
538055
  } else {
536350
538056
  if (isEnvTruthy("false") && isLoading) {
@@ -536407,13 +538113,13 @@ function SessionBackgroundHint(t0) {
536407
538113
  }
536408
538114
  return t5;
536409
538115
  }
536410
- function _temp283(c6) {
538116
+ function _temp284(c6) {
536411
538117
  return c6.hasUsedBackgroundTask ? c6 : {
536412
538118
  ...c6,
536413
538119
  hasUsedBackgroundTask: true
536414
538120
  };
536415
538121
  }
536416
- function _temp199() {}
538122
+ function _temp200() {}
536417
538123
  var import_compiler_runtime343, import_react288, jsx_dev_runtime441;
536418
538124
  var init_SessionBackgroundHint = __esm(() => {
536419
538125
  init_useDoublePress();
@@ -536600,7 +538306,7 @@ function EffortCallout(t0) {
536600
538306
  } else {
536601
538307
  t4 = $3[4];
536602
538308
  }
536603
- import_react290.useEffect(_temp200, t4);
538309
+ import_react290.useEffect(_temp201, t4);
536604
538310
  let t5;
536605
538311
  let t6;
536606
538312
  if ($3[5] === Symbol.for("react.memo_cache_sentinel")) {
@@ -536750,7 +538456,7 @@ function EffortCallout(t0) {
536750
538456
  }
536751
538457
  return t14;
536752
538458
  }
536753
- function _temp200() {
538459
+ function _temp201() {
536754
538460
  markV2Dismissed();
536755
538461
  }
536756
538462
  function EffortIndicatorSymbol(t0) {
@@ -537581,8 +539287,8 @@ function usePostCompactSurvey(messages, isLoading, t0, t1) {
537581
539287
  }
537582
539288
  const seenCompactBoundaries = import_react296.useRef(t4);
537583
539289
  const pendingCompactBoundaryUuid = import_react296.useRef(null);
537584
- const onOpen = _temp201;
537585
- const onSelect = _temp284;
539290
+ const onOpen = _temp202;
539291
+ const onSelect = _temp285;
537586
539292
  let t5;
537587
539293
  if ($3[3] === Symbol.for("react.memo_cache_sentinel")) {
537588
539294
  t5 = {
@@ -537620,7 +539326,7 @@ function usePostCompactSurvey(messages, isLoading, t0, t1) {
537620
539326
  import_react296.useEffect(t6, t7);
537621
539327
  let t8;
537622
539328
  if ($3[7] !== messages) {
537623
- t8 = new Set(messages.filter(_temp354).map(_temp441));
539329
+ t8 = new Set(messages.filter(_temp355).map(_temp441));
537624
539330
  $3[7] = messages;
537625
539331
  $3[8] = t8;
537626
539332
  } else {
@@ -537699,10 +539405,10 @@ function usePostCompactSurvey(messages, isLoading, t0, t1) {
537699
539405
  function _temp441(msg_0) {
537700
539406
  return msg_0.uuid;
537701
539407
  }
537702
- function _temp354(msg) {
539408
+ function _temp355(msg) {
537703
539409
  return isCompactBoundaryMessage(msg);
537704
539410
  }
537705
- function _temp284(appearanceId_0, selected) {
539411
+ function _temp285(appearanceId_0, selected) {
537706
539412
  const smCompactionEnabled_0 = shouldUseSessionMemoryCompaction();
537707
539413
  logEvent("tengu_post_compact_survey_event", {
537708
539414
  event_type: "responded",
@@ -537717,7 +539423,7 @@ function _temp284(appearanceId_0, selected) {
537717
539423
  survey_type: "post_compact"
537718
539424
  });
537719
539425
  }
537720
- function _temp201(appearanceId) {
539426
+ function _temp202(appearanceId) {
537721
539427
  const smCompactionEnabled = shouldUseSessionMemoryCompaction();
537722
539428
  logEvent("tengu_post_compact_survey_event", {
537723
539429
  event_type: "appeared",
@@ -538147,13 +539853,13 @@ var init_useStartupNotification = __esm(() => {
538147
539853
 
538148
539854
  // src/hooks/notifs/useInstallMessages.tsx
538149
539855
  function useInstallMessages() {
538150
- useStartupNotification(_temp285);
539856
+ useStartupNotification(_temp286);
538151
539857
  }
538152
- async function _temp285() {
539858
+ async function _temp286() {
538153
539859
  const messages = await checkInstall();
538154
- return messages.map(_temp202);
539860
+ return messages.map(_temp203);
538155
539861
  }
538156
- function _temp202(message, index) {
539862
+ function _temp203(message, index) {
538157
539863
  let priority = "low";
538158
539864
  if (message.type === "error" || message.userActionRequired) {
538159
539865
  priority = "high";
@@ -538207,9 +539913,9 @@ function getChromeFlag() {
538207
539913
  return;
538208
539914
  }
538209
539915
  function useChromeExtensionNotification() {
538210
- useStartupNotification(_temp203);
539916
+ useStartupNotification(_temp204);
538211
539917
  }
538212
- async function _temp203() {
539918
+ async function _temp204() {
538213
539919
  const chromeFlag = getChromeFlag();
538214
539920
  if (!shouldEnableClaudeInChrome(chromeFlag)) {
538215
539921
  return null;
@@ -538522,9 +540228,9 @@ var init_officialMarketplaceStartupCheck = __esm(() => {
538522
540228
 
538523
540229
  // src/hooks/useOfficialMarketplaceNotification.tsx
538524
540230
  function useOfficialMarketplaceNotification() {
538525
- useStartupNotification(_temp204);
540231
+ useStartupNotification(_temp205);
538526
540232
  }
538527
- async function _temp204() {
540233
+ async function _temp205() {
538528
540234
  const result = await checkAndInstallOfficialMarketplace();
538529
540235
  const notifs = [];
538530
540236
  if (result.configSaveFailed) {
@@ -538587,7 +540293,7 @@ function usePromptsFromClaudeInChrome(mcpClients, toolPermissionMode) {
538587
540293
  } else {
538588
540294
  t0 = $3[1];
538589
540295
  }
538590
- import_react299.useEffect(_temp205, t0);
540296
+ import_react299.useEffect(_temp206, t0);
538591
540297
  let t1;
538592
540298
  let t2;
538593
540299
  if ($3[2] !== mcpClients || $3[3] !== toolPermissionMode) {
@@ -538612,7 +540318,7 @@ function usePromptsFromClaudeInChrome(mcpClients, toolPermissionMode) {
538612
540318
  }
538613
540319
  import_react299.useEffect(t1, t2);
538614
540320
  }
538615
- function _temp205() {}
540321
+ function _temp206() {}
538616
540322
  function findChromeClient(clients) {
538617
540323
  return clients.find((client) => client.type === "connected" && client.name === CLAUDE_IN_CHROME_MCP_SERVER_NAME);
538618
540324
  }
@@ -538690,7 +540396,7 @@ function DesktopUpsellStartup(t0) {
538690
540396
  } else {
538691
540397
  t1 = $3[0];
538692
540398
  }
538693
- import_react300.useEffect(_temp206, t1);
540399
+ import_react300.useEffect(_temp207, t1);
538694
540400
  if (showHandoff) {
538695
540401
  let t22;
538696
540402
  if ($3[1] !== onDone) {
@@ -538713,7 +540419,7 @@ function DesktopUpsellStartup(t0) {
538713
540419
  return;
538714
540420
  }
538715
540421
  case "never": {
538716
- saveGlobalConfig(_temp286);
540422
+ saveGlobalConfig(_temp287);
538717
540423
  onDone();
538718
540424
  return;
538719
540425
  }
@@ -538806,7 +540512,7 @@ function DesktopUpsellStartup(t0) {
538806
540512
  }
538807
540513
  return t8;
538808
540514
  }
538809
- function _temp286(prev_0) {
540515
+ function _temp287(prev_0) {
538810
540516
  if (prev_0.desktopUpsellDismissed) {
538811
540517
  return prev_0;
538812
540518
  }
@@ -538815,7 +540521,7 @@ function _temp286(prev_0) {
538815
540521
  desktopUpsellDismissed: true
538816
540522
  };
538817
540523
  }
538818
- function _temp206() {
540524
+ function _temp207() {
538819
540525
  const newCount = (getGlobalConfig().desktopUpsellSeenCount ?? 0) + 1;
538820
540526
  saveGlobalConfig((prev) => {
538821
540527
  if ((prev.desktopUpsellSeenCount ?? 0) >= newCount) {
@@ -540627,7 +542333,7 @@ function SandboxViolationExpandedView() {
540627
542333
  }
540628
542334
  let t5;
540629
542335
  if ($3[6] !== violations) {
540630
- t5 = violations.map(_temp207);
542336
+ t5 = violations.map(_temp208);
540631
542337
  $3[6] = violations;
540632
542338
  $3[7] = t5;
540633
542339
  } else {
@@ -540674,7 +542380,7 @@ function SandboxViolationExpandedView() {
540674
542380
  }
540675
542381
  return t8;
540676
542382
  }
540677
- function _temp207(v2, i3) {
542383
+ function _temp208(v2, i3) {
540678
542384
  return /* @__PURE__ */ jsx_dev_runtime450.jsxDEV(ThemedBox_default, {
540679
542385
  paddingLeft: 2,
540680
542386
  children: /* @__PURE__ */ jsx_dev_runtime450.jsxDEV(ThemedText, {
@@ -540715,9 +542421,9 @@ function useMcpConnectivityStatus(t0) {
540715
542421
  if (getIsRemoteMode()) {
540716
542422
  return;
540717
542423
  }
540718
- const failedLocalClients = mcpClients.filter(_temp208);
540719
- const failedClaudeAiClients = mcpClients.filter(_temp287);
540720
- const needsAuthLocalServers = mcpClients.filter(_temp355);
542424
+ const failedLocalClients = mcpClients.filter(_temp209);
542425
+ const failedClaudeAiClients = mcpClients.filter(_temp288);
542426
+ const needsAuthLocalServers = mcpClients.filter(_temp356);
540721
542427
  const needsAuthClaudeAiServers = mcpClients.filter(_temp442);
540722
542428
  if (failedLocalClients.length === 0 && failedClaudeAiClients.length === 0 && needsAuthLocalServers.length === 0 && needsAuthClaudeAiServers.length === 0) {
540723
542429
  return;
@@ -540836,13 +542542,13 @@ function useMcpConnectivityStatus(t0) {
540836
542542
  function _temp442(client_2) {
540837
542543
  return client_2.type === "needs-auth" && client_2.config.type === "claudeai-proxy" && hasClaudeAiMcpEverConnected(client_2.name);
540838
542544
  }
540839
- function _temp355(client_1) {
542545
+ function _temp356(client_1) {
540840
542546
  return client_1.type === "needs-auth" && client_1.config.type !== "claudeai-proxy";
540841
542547
  }
540842
- function _temp287(client_0) {
542548
+ function _temp288(client_0) {
540843
542549
  return client_0.type === "failed" && client_0.config.type === "claudeai-proxy" && hasClaudeAiMcpEverConnected(client_0.name);
540844
542550
  }
540845
- function _temp208(client) {
542551
+ function _temp209(client) {
540846
542552
  return client.type === "failed" && client.config.type !== "sse-ide" && client.config.type !== "ws-ide" && client.config.type !== "claudeai-proxy";
540847
542553
  }
540848
542554
  var import_compiler_runtime352, import_react303, jsx_dev_runtime451, EMPTY_MCP_CLIENTS;
@@ -540905,7 +542611,7 @@ function useLspInitializationNotification() {
540905
542611
  addNotification
540906
542612
  } = useNotifications();
540907
542613
  const setAppState = useSetAppState();
540908
- const [shouldPoll, setShouldPoll] = React147.useState(_temp209);
542614
+ const [shouldPoll, setShouldPoll] = React147.useState(_temp224);
540909
542615
  let t0;
540910
542616
  if ($3[0] === Symbol.for("react.memo_cache_sentinel")) {
540911
542617
  t0 = new Set;
@@ -540924,7 +542630,7 @@ function useLspInitializationNotification() {
540924
542630
  notifiedErrorsRef.current.add(errorKey2);
540925
542631
  logForDebugging(`LSP error: ${source} - ${errorMessage4}`);
540926
542632
  setAppState((prev) => {
540927
- const existingKeys = new Set(prev.plugins.errors.map(_temp288));
542633
+ const existingKeys = new Set(prev.plugins.errors.map(_temp289));
540928
542634
  const stateErrorKey = `generic-error:${source}:${errorMessage4}`;
540929
542635
  if (existingKeys.has(stateErrorKey)) {
540930
542636
  return prev;
@@ -541026,13 +542732,13 @@ function useLspInitializationNotification() {
541026
542732
  }
541027
542733
  React147.useEffect(t3, t4);
541028
542734
  }
541029
- function _temp288(e) {
542735
+ function _temp289(e) {
541030
542736
  if (e.type === "generic-error") {
541031
542737
  return `generic-error:${e.source}:${e.error}`;
541032
542738
  }
541033
542739
  return `${e.type}:${e.source}`;
541034
542740
  }
541035
- function _temp209() {
542741
+ function _temp224() {
541036
542742
  return isEnvTruthy("true");
541037
542743
  }
541038
542744
  var import_compiler_runtime353, React147, jsx_dev_runtime452, LSP_POLL_INTERVAL_MS = 5000;
@@ -541364,7 +543070,7 @@ var init_usePluginRecommendationBase = __esm(() => {
541364
543070
  import { extname as extname16, join as join148 } from "path";
541365
543071
  function useLspPluginRecommendation() {
541366
543072
  const $3 = import_compiler_runtime355.c(12);
541367
- const trackedFiles = useAppState(_temp224);
543073
+ const trackedFiles = useAppState(_temp234);
541368
543074
  const {
541369
543075
  addNotification
541370
543076
  } = useNotifications();
@@ -541472,7 +543178,7 @@ function useLspPluginRecommendation() {
541472
543178
  break bb60;
541473
543179
  }
541474
543180
  case "disable": {
541475
- saveGlobalConfig(_temp289);
543181
+ saveGlobalConfig(_temp290);
541476
543182
  }
541477
543183
  }
541478
543184
  clearRecommendation();
@@ -541499,7 +543205,7 @@ function useLspPluginRecommendation() {
541499
543205
  }
541500
543206
  return t4;
541501
543207
  }
541502
- function _temp289(current) {
543208
+ function _temp290(current) {
541503
543209
  if (current.lspRecommendationDisabled) {
541504
543210
  return current;
541505
543211
  }
@@ -541508,7 +543214,7 @@ function _temp289(current) {
541508
543214
  lspRecommendationDisabled: true
541509
543215
  };
541510
543216
  }
541511
- function _temp224(s) {
543217
+ function _temp234(s) {
541512
543218
  return s.fileHistory.trackedFiles;
541513
543219
  }
541514
543220
  var import_compiler_runtime355, React149, TIMEOUT_THRESHOLD_MS = 28000;
@@ -541909,7 +543615,7 @@ function usePluginInstallationStatus() {
541909
543615
  const {
541910
543616
  addNotification
541911
543617
  } = useNotifications();
541912
- const installationStatus = useAppState(_temp234);
543618
+ const installationStatus = useAppState(_temp244);
541913
543619
  let t0;
541914
543620
  bb0: {
541915
543621
  if (!installationStatus) {
@@ -541929,7 +543635,7 @@ function usePluginInstallationStatus() {
541929
543635
  }
541930
543636
  let t12;
541931
543637
  if ($3[1] !== installationStatus.marketplaces) {
541932
- t12 = installationStatus.marketplaces.filter(_temp290);
543638
+ t12 = installationStatus.marketplaces.filter(_temp291);
541933
543639
  $3[1] = installationStatus.marketplaces;
541934
543640
  $3[2] = t12;
541935
543641
  } else {
@@ -541938,7 +543644,7 @@ function usePluginInstallationStatus() {
541938
543644
  const failedMarketplaces = t12;
541939
543645
  let t22;
541940
543646
  if ($3[3] !== installationStatus.plugins) {
541941
- t22 = installationStatus.plugins.filter(_temp356);
543647
+ t22 = installationStatus.plugins.filter(_temp357);
541942
543648
  $3[3] = installationStatus.plugins;
541943
543649
  $3[4] = t22;
541944
543650
  } else {
@@ -542029,13 +543735,13 @@ function usePluginInstallationStatus() {
542029
543735
  }
542030
543736
  import_react305.useEffect(t1, t2);
542031
543737
  }
542032
- function _temp356(p) {
543738
+ function _temp357(p) {
542033
543739
  return p.status === "failed";
542034
543740
  }
542035
- function _temp290(m2) {
543741
+ function _temp291(m2) {
542036
543742
  return m2.status === "failed";
542037
543743
  }
542038
- function _temp234(s) {
543744
+ function _temp244(s) {
542039
543745
  return s.plugins.installationStatus;
542040
543746
  }
542041
543747
  var import_compiler_runtime357, import_react305, jsx_dev_runtime456;
@@ -542096,7 +543802,7 @@ function usePluginAutoupdateNotification() {
542096
543802
  if (updatedPlugins.length === 0) {
542097
543803
  return;
542098
543804
  }
542099
- const pluginNames = updatedPlugins.map(_temp244);
543805
+ const pluginNames = updatedPlugins.map(_temp254);
542100
543806
  const displayNames = pluginNames.length <= 2 ? pluginNames.join(" and ") : `${pluginNames.length} plugins`;
542101
543807
  addNotification({
542102
543808
  key: "plugin-autoupdate-restart",
@@ -542133,7 +543839,7 @@ function usePluginAutoupdateNotification() {
542133
543839
  }
542134
543840
  import_react306.useEffect(t3, t4);
542135
543841
  }
542136
- function _temp244(id) {
543842
+ function _temp254(id) {
542137
543843
  const atIndex = id.indexOf("@");
542138
543844
  return atIndex > 0 ? id.substring(0, atIndex) : id;
542139
543845
  }
@@ -542474,7 +544180,7 @@ function AwsAuthStatusBox() {
542474
544180
  t4 = status2.output.length > 0 && /* @__PURE__ */ jsx_dev_runtime458.jsxDEV(ThemedBox_default, {
542475
544181
  flexDirection: "column",
542476
544182
  marginTop: 1,
542477
- children: status2.output.slice(-5).map(_temp254)
544183
+ children: status2.output.slice(-5).map(_temp292)
542478
544184
  }, undefined, false, undefined, this);
542479
544185
  $3[4] = status2.output;
542480
544186
  $3[5] = t4;
@@ -542517,7 +544223,7 @@ function AwsAuthStatusBox() {
542517
544223
  }
542518
544224
  return t6;
542519
544225
  }
542520
- function _temp254(line, index) {
544226
+ function _temp292(line, index) {
542521
544227
  const m2 = line.match(URL_RE);
542522
544228
  if (!m2) {
542523
544229
  return /* @__PURE__ */ jsx_dev_runtime458.jsxDEV(ThemedText, {
@@ -542831,7 +544537,7 @@ function useIDEStatusIndicator(t0) {
542831
544537
  if (hasShownHintRef.current || (getGlobalConfig().ideHintShownCount ?? 0) >= MAX_IDE_HINT_SHOW_COUNT) {
542832
544538
  return;
542833
544539
  }
542834
- const timeoutId = setTimeout(_temp291, 3000, hasShownHintRef, addNotification);
544540
+ const timeoutId = setTimeout(_temp293, 3000, hasShownHintRef, addNotification);
542835
544541
  return () => clearTimeout(timeoutId);
542836
544542
  };
542837
544543
  t3 = [addNotification, removeNotification, ideStatus, showJetBrainsInfo];
@@ -542936,12 +544642,12 @@ function useIDEStatusIndicator(t0) {
542936
544642
  }
542937
544643
  import_react310.useEffect(t8, t9);
542938
544644
  }
542939
- function _temp291(hasShownHintRef_0, addNotification_0) {
544645
+ function _temp293(hasShownHintRef_0, addNotification_0) {
542940
544646
  detectIDEs(true).then((infos) => {
542941
544647
  const ideName_0 = infos[0]?.name;
542942
544648
  if (ideName_0 && !hasShownHintRef_0.current) {
542943
544649
  hasShownHintRef_0.current = true;
542944
- saveGlobalConfig(_temp292);
544650
+ saveGlobalConfig(_temp294);
542945
544651
  addNotification_0({
542946
544652
  key: "ide-status-hint",
542947
544653
  jsx: /* @__PURE__ */ jsx_dev_runtime460.jsxDEV(ThemedText, {
@@ -542959,7 +544665,7 @@ function _temp291(hasShownHintRef_0, addNotification_0) {
542959
544665
  }
542960
544666
  });
542961
544667
  }
542962
- function _temp292(current) {
544668
+ function _temp294(current) {
542963
544669
  return {
542964
544670
  ...current,
542965
544671
  ideHintShownCount: (current.ideHintShownCount ?? 0) + 1
@@ -542980,9 +544686,9 @@ var init_useIDEStatusIndicator = __esm(() => {
542980
544686
 
542981
544687
  // src/hooks/notifs/useModelMigrationNotifications.tsx
542982
544688
  function useModelMigrationNotifications() {
542983
- useStartupNotification(_temp294);
544689
+ useStartupNotification(_temp295);
542984
544690
  }
542985
- function _temp294() {
544691
+ function _temp295() {
542986
544692
  const config5 = getGlobalConfig();
542987
544693
  const notifs = [];
542988
544694
  for (const migration of MIGRATIONS) {
@@ -543030,9 +544736,9 @@ var init_useModelMigrationNotifications = __esm(() => {
543030
544736
 
543031
544737
  // src/hooks/notifs/useCanSwitchToExistingSubscription.tsx
543032
544738
  function useCanSwitchToExistingSubscription() {
543033
- useStartupNotification(_temp293);
544739
+ useStartupNotification(_temp296);
543034
544740
  }
543035
- async function _temp293() {
544741
+ async function _temp296() {
543036
544742
  if ((getGlobalConfig().subscriptionNoticeCount ?? 0) >= MAX_SHOW_COUNT2) {
543037
544743
  return null;
543038
544744
  }
@@ -543040,7 +544746,7 @@ async function _temp293() {
543040
544746
  if (subscriptionType === null) {
543041
544747
  return null;
543042
544748
  }
543043
- saveGlobalConfig(_temp295);
544749
+ saveGlobalConfig(_temp297);
543044
544750
  logEvent("tengu_switch_to_subscription_notice_shown", {});
543045
544751
  return {
543046
544752
  key: "switch-to-subscription",
@@ -543063,7 +544769,7 @@ async function _temp293() {
543063
544769
  priority: "low"
543064
544770
  };
543065
544771
  }
543066
- function _temp295(current) {
544772
+ function _temp297(current) {
543067
544773
  return {
543068
544774
  ...current,
543069
544775
  subscriptionNoticeCount: (current.subscriptionNoticeCount ?? 0) + 1
@@ -543165,7 +544871,7 @@ function useFastModeNotification() {
543165
544871
  const {
543166
544872
  addNotification
543167
544873
  } = useNotifications();
543168
- const isFastMode = useAppState(_temp297);
544874
+ const isFastMode = useAppState(_temp299);
543169
544875
  const setAppState = useSetAppState();
543170
544876
  let t0;
543171
544877
  let t1;
@@ -543187,7 +544893,7 @@ function useFastModeNotification() {
543187
544893
  });
543188
544894
  } else {
543189
544895
  if (isFastMode) {
543190
- setAppState(_temp296);
544896
+ setAppState(_temp298);
543191
544897
  addNotification({
543192
544898
  key: ORG_CHANGED_KEY,
543193
544899
  color: "warning",
@@ -543220,7 +544926,7 @@ function useFastModeNotification() {
543220
544926
  return;
543221
544927
  }
543222
544928
  return onFastModeOverageRejection((message) => {
543223
- setAppState(_temp357);
544929
+ setAppState(_temp358);
543224
544930
  addNotification({
543225
544931
  key: OVERAGE_REJECTED_KEY,
543226
544932
  color: "warning",
@@ -543287,19 +544993,19 @@ function useFastModeNotification() {
543287
544993
  }
543288
544994
  import_react312.useEffect(t4, t5);
543289
544995
  }
543290
- function _temp357(prev_0) {
544996
+ function _temp358(prev_0) {
543291
544997
  return {
543292
544998
  ...prev_0,
543293
544999
  fastMode: false
543294
545000
  };
543295
545001
  }
543296
- function _temp296(prev) {
545002
+ function _temp298(prev) {
543297
545003
  return {
543298
545004
  ...prev,
543299
545005
  fastMode: false
543300
545006
  };
543301
545007
  }
543302
- function _temp297(s) {
545008
+ function _temp299(s) {
543303
545009
  return s.fastMode;
543304
545010
  }
543305
545011
  function getCooldownMessage(reason, resetIn) {
@@ -544484,7 +546190,7 @@ function AnimatedTerminalTitle(t0) {
544484
546190
  if (disabled || noPrefix || !isAnimating || !terminalFocused) {
544485
546191
  return;
544486
546192
  }
544487
- const interval = setInterval(_temp298, TITLE_ANIMATION_INTERVAL_MS, setFrame);
546193
+ const interval = setInterval(_temp2100, TITLE_ANIMATION_INTERVAL_MS, setFrame);
544488
546194
  return () => clearInterval(interval);
544489
546195
  };
544490
546196
  t2 = [disabled, noPrefix, isAnimating, terminalFocused];
@@ -544503,10 +546209,10 @@ function AnimatedTerminalTitle(t0) {
544503
546209
  useTerminalTitle(disabled ? null : noPrefix ? title : `${prefix} ${title}`);
544504
546210
  return null;
544505
546211
  }
544506
- function _temp298(setFrame_0) {
544507
- return setFrame_0(_temp299);
546212
+ function _temp2100(setFrame_0) {
546213
+ return setFrame_0(_temp300);
544508
546214
  }
544509
- function _temp299(f) {
546215
+ function _temp300(f) {
544510
546216
  return (f + 1) % TITLE_ANIMATION_FRAMES.length;
544511
546217
  }
544512
546218
  function REPL({
@@ -544911,7 +546617,12 @@ function REPL({
544911
546617
  onScrollAway(handle);
544912
546618
  if (false)
544913
546619
  ;
544914
- if (false) {}
546620
+ if (true) {
546621
+ setAppState((prev) => prev.companionReaction === undefined ? prev : {
546622
+ ...prev,
546623
+ companionReaction: undefined
546624
+ });
546625
+ }
544915
546626
  }
544916
546627
  }, [onRepin, onScrollAway, maybeLoadOlder, setAppState]);
544917
546628
  const awaitPendingHooks = useDeferredHookMessages(pendingHookMessages, setMessages);
@@ -545841,7 +547552,12 @@ Error: sandbox required but unavailable: ${reason}
545841
547552
  })) {
545842
547553
  onQueryEvent(event);
545843
547554
  }
545844
- if (false) {}
547555
+ if (true) {
547556
+ fireCompanionObserver(messagesRef.current, (reaction) => setAppState((prev) => prev.companionReaction === reaction ? prev : {
547557
+ ...prev,
547558
+ companionReaction: reaction
547559
+ }));
547560
+ }
545845
547561
  queryCheckpoint("query_end");
545846
547562
  if (false) {}
545847
547563
  resetLoadingState();
@@ -547088,7 +548804,7 @@ Note: ctrl + z now suspends myclaude, ctrl + _ undoes input.
547088
548804
  children: /* @__PURE__ */ jsx_dev_runtime465.jsxDEV(FullscreenLayout, {
547089
548805
  scrollRef,
547090
548806
  overlay: toolPermissionOverlay,
547091
- bottomFloat: undefined,
548807
+ bottomFloat: companionVisible && !companionNarrow ? /* @__PURE__ */ jsx_dev_runtime465.jsxDEV(CompanionFloatingBubble, {}, undefined, false, undefined, this) : undefined,
547092
548808
  modal: centeredModal,
547093
548809
  modalScrollRef,
547094
548810
  dividerYRef,
@@ -547167,11 +548883,11 @@ Note: ctrl + z now suspends myclaude, ctrl + _ undoes input.
547167
548883
  ]
547168
548884
  }, undefined, true, undefined, this),
547169
548885
  bottom: /* @__PURE__ */ jsx_dev_runtime465.jsxDEV(ThemedBox_default, {
547170
- flexDirection: "row",
548886
+ flexDirection: companionNarrow ? "column" : "row",
547171
548887
  width: "100%",
547172
- alignItems: "flex-end",
548888
+ alignItems: companionNarrow ? undefined : "flex-end",
547173
548889
  children: [
547174
- null,
548890
+ companionNarrow && isFullscreenEnvEnabled() && companionVisible ? /* @__PURE__ */ jsx_dev_runtime465.jsxDEV(CompanionSprite, {}, undefined, false, undefined, this) : null,
547175
548891
  /* @__PURE__ */ jsx_dev_runtime465.jsxDEV(ThemedBox_default, {
547176
548892
  flexDirection: "column",
547177
548893
  flexGrow: 1,
@@ -547620,7 +549336,7 @@ Note: ctrl + z now suspends myclaude, ctrl + _ undoes input.
547620
549336
  false
547621
549337
  ]
547622
549338
  }, undefined, true, undefined, this),
547623
- null
549339
+ !(companionNarrow && isFullscreenEnvEnabled()) && companionVisible ? /* @__PURE__ */ jsx_dev_runtime465.jsxDEV(CompanionSprite, {}, undefined, false, undefined, this) : null
547624
549340
  ]
547625
549341
  }, undefined, true, undefined, this)
547626
549342
  }, undefined, false, undefined, this)
@@ -548289,7 +550005,7 @@ function MCPServerMultiselectDialog(t0) {
548289
550005
  }
548290
550006
  let t5;
548291
550007
  if ($3[7] !== serverNames) {
548292
- t5 = serverNames.map(_temp300);
550008
+ t5 = serverNames.map(_temp301);
548293
550009
  $3[7] = serverNames;
548294
550010
  $3[8] = t5;
548295
550011
  } else {
@@ -548378,7 +550094,7 @@ function MCPServerMultiselectDialog(t0) {
548378
550094
  }
548379
550095
  return t9;
548380
550096
  }
548381
- function _temp300(server_0) {
550097
+ function _temp301(server_0) {
548382
550098
  return {
548383
550099
  label: server_0,
548384
550100
  value: server_0
@@ -548683,7 +550399,7 @@ function PreflightStep(t0) {
548683
550399
  onSuccess();
548684
550400
  } else {
548685
550401
  if (result && !result.success) {
548686
- const timer = setTimeout(_temp301, 100);
550402
+ const timer = setTimeout(_temp302, 100);
548687
550403
  return () => clearTimeout(timer);
548688
550404
  }
548689
550405
  }
@@ -548775,7 +550491,7 @@ function PreflightStep(t0) {
548775
550491
  }
548776
550492
  return t6;
548777
550493
  }
548778
- function _temp301() {
550494
+ function _temp302() {
548779
550495
  return process.exit(1);
548780
550496
  }
548781
550497
  var import_compiler_runtime371, import_react321, jsx_dev_runtime471;
@@ -550622,7 +552338,7 @@ function TrustDialog(t0) {
550622
552338
  const hasDangerousEnvVars2 = dangerousEnvVarsSources.length > 0;
550623
552339
  let t10;
550624
552340
  if ($3[9] !== commands) {
550625
- t10 = commands?.some(_temp2100) ?? false;
552341
+ t10 = commands?.some(_temp2102) ?? false;
550626
552342
  $3[9] = commands;
550627
552343
  $3[10] = t10;
550628
552344
  } else {
@@ -550843,15 +552559,15 @@ function _temp530(current) {
550843
552559
  };
550844
552560
  }
550845
552561
  function _temp443(command_0) {
550846
- return command_0.type === "prompt" && (command_0.loadedFrom === "skills" || command_0.loadedFrom === "plugin") && (command_0.source === "projectSettings" || command_0.source === "localSettings" || command_0.source === "plugin") && command_0.allowedTools?.some(_temp358);
552562
+ return command_0.type === "prompt" && (command_0.loadedFrom === "skills" || command_0.loadedFrom === "plugin") && (command_0.source === "projectSettings" || command_0.source === "localSettings" || command_0.source === "plugin") && command_0.allowedTools?.some(_temp359);
550847
552563
  }
550848
- function _temp358(tool_0) {
552564
+ function _temp359(tool_0) {
550849
552565
  return tool_0 === BASH_TOOL_NAME || tool_0.startsWith(BASH_TOOL_NAME + "(");
550850
552566
  }
550851
- function _temp2100(command8) {
550852
- return command8.type === "prompt" && command8.loadedFrom === "commands_DEPRECATED" && (command8.source === "projectSettings" || command8.source === "localSettings") && command8.allowedTools?.some(_temp302);
552567
+ function _temp2102(command8) {
552568
+ return command8.type === "prompt" && command8.loadedFrom === "commands_DEPRECATED" && (command8.source === "projectSettings" || command8.source === "localSettings") && command8.allowedTools?.some(_temp303);
550853
552569
  }
550854
- function _temp302(tool) {
552570
+ function _temp303(tool) {
550855
552571
  return tool === BASH_TOOL_NAME || tool.startsWith(BASH_TOOL_NAME + "(");
550856
552572
  }
550857
552573
  var import_compiler_runtime377, import_react325, jsx_dev_runtime477;
@@ -550891,7 +552607,7 @@ function BypassPermissionsModeDialog(t0) {
550891
552607
  } else {
550892
552608
  t1 = $3[0];
550893
552609
  }
550894
- import_react326.default.useEffect(_temp303, t1);
552610
+ import_react326.default.useEffect(_temp304, t1);
550895
552611
  let t2;
550896
552612
  if ($3[1] !== onAccept) {
550897
552613
  t2 = function onChange2(value) {
@@ -550916,7 +552632,7 @@ function BypassPermissionsModeDialog(t0) {
550916
552632
  t2 = $3[2];
550917
552633
  }
550918
552634
  const onChange = t2;
550919
- const handleEscape = _temp2102;
552635
+ const handleEscape = _temp2103;
550920
552636
  let t3;
550921
552637
  if ($3[3] === Symbol.for("react.memo_cache_sentinel")) {
550922
552638
  t3 = /* @__PURE__ */ jsx_dev_runtime478.jsxDEV(ThemedBox_default, {
@@ -550976,10 +552692,10 @@ function BypassPermissionsModeDialog(t0) {
550976
552692
  }
550977
552693
  return t5;
550978
552694
  }
550979
- function _temp2102() {
552695
+ function _temp2103() {
550980
552696
  gracefulShutdownSync(0);
550981
552697
  }
550982
- function _temp303() {
552698
+ function _temp304() {
550983
552699
  logEvent("tengu_bypass_permissions_mode_dialog_shown", {});
550984
552700
  }
550985
552701
  var import_compiler_runtime378, import_react326, jsx_dev_runtime478;
@@ -551012,7 +552728,7 @@ function ClaudeInChromeOnboarding(t0) {
551012
552728
  t1 = () => {
551013
552729
  logEvent("tengu_claude_in_chrome_onboarding_shown", {});
551014
552730
  isChromeExtensionInstalled().then(setIsExtensionInstalled);
551015
- saveGlobalConfig(_temp304);
552731
+ saveGlobalConfig(_temp305);
551016
552732
  };
551017
552733
  t2 = [];
551018
552734
  $3[0] = t1;
@@ -551161,7 +552877,7 @@ function ClaudeInChromeOnboarding(t0) {
551161
552877
  }
551162
552878
  return t11;
551163
552879
  }
551164
- function _temp304(current) {
552880
+ function _temp305(current) {
551165
552881
  return {
551166
552882
  ...current,
551167
552883
  hasCompletedClaudeInChromeOnboarding: true
@@ -552236,7 +553952,7 @@ function TeleportRepoMismatchDialog(t0) {
552236
553952
  } else {
552237
553953
  t32 = $3[7];
552238
553954
  }
552239
- t2 = [...availablePaths.map(_temp305), t32];
553955
+ t2 = [...availablePaths.map(_temp306), t32];
552240
553956
  $3[5] = availablePaths;
552241
553957
  $3[6] = t2;
552242
553958
  } else {
@@ -552322,7 +554038,7 @@ function TeleportRepoMismatchDialog(t0) {
552322
554038
  }
552323
554039
  return t4;
552324
554040
  }
552325
- function _temp305(path24) {
554041
+ function _temp306(path24) {
552326
554042
  return {
552327
554043
  label: /* @__PURE__ */ jsx_dev_runtime484.jsxDEV(ThemedText, {
552328
554044
  children: [
@@ -552618,7 +554334,7 @@ function NoConversationsMessage() {
552618
554334
  } else {
552619
554335
  t0 = $3[0];
552620
554336
  }
552621
- useKeybinding("app:interrupt", _temp306, t0);
554337
+ useKeybinding("app:interrupt", _temp307, t0);
552622
554338
  let t1;
552623
554339
  if ($3[1] === Symbol.for("react.memo_cache_sentinel")) {
552624
554340
  t1 = /* @__PURE__ */ jsx_dev_runtime485.jsxDEV(ThemedBox_default, {
@@ -552639,7 +554355,7 @@ function NoConversationsMessage() {
552639
554355
  }
552640
554356
  return t1;
552641
554357
  }
552642
- function _temp306() {
554358
+ function _temp307() {
552643
554359
  process.exit(1);
552644
554360
  }
552645
554361
  function CrossProjectMessage(t0) {
@@ -552654,7 +554370,7 @@ function CrossProjectMessage(t0) {
552654
554370
  } else {
552655
554371
  t1 = $3[0];
552656
554372
  }
552657
- import_react332.default.useEffect(_temp359, t1);
554373
+ import_react332.default.useEffect(_temp360, t1);
552658
554374
  let t2;
552659
554375
  if ($3[1] === Symbol.for("react.memo_cache_sentinel")) {
552660
554376
  t2 = /* @__PURE__ */ jsx_dev_runtime485.jsxDEV(ThemedText, {
@@ -552720,11 +554436,11 @@ function CrossProjectMessage(t0) {
552720
554436
  }
552721
554437
  return t6;
552722
554438
  }
552723
- function _temp359() {
552724
- const timeout2 = setTimeout(_temp2103, 100);
554439
+ function _temp360() {
554440
+ const timeout2 = setTimeout(_temp2104, 100);
552725
554441
  return () => clearTimeout(timeout2);
552726
554442
  }
552727
- function _temp2103() {
554443
+ function _temp2104() {
552728
554444
  process.exit(0);
552729
554445
  }
552730
554446
  var import_compiler_runtime384, import_react332, jsx_dev_runtime485;
@@ -553115,7 +554831,7 @@ Now that this skill is invoked, you have access to Chrome browser automation too
553115
554831
  IMPORTANT: Start by calling mcp__claude-in-chrome__tabs_context_mcp to get information about the user's current browser tabs.
553116
554832
  `;
553117
554833
  var init_claudeInChrome = __esm(() => {
553118
- init_claude_for_chrome_mcp();
554834
+ init_ant_claude_for_chrome_mcp();
553119
554835
  init_setup2();
553120
554836
  init_bundledSkills();
553121
554837
  CLAUDE_IN_CHROME_MCP_TOOLS = BROWSER_TOOLS.map((tool) => `mcp__claude-in-chrome__${tool.name}`);
@@ -555603,7 +557319,7 @@ var init_resetProToOpusDefault = __esm(() => {
555603
557319
 
555604
557320
  // src/server/types.ts
555605
557321
  var connectResponseSchema;
555606
- var init_types15 = __esm(() => {
557322
+ var init_types16 = __esm(() => {
555607
557323
  init_v4();
555608
557324
  connectResponseSchema = lazySchema(() => exports_external.object({
555609
557325
  session_id: exports_external.string(),
@@ -555616,7 +557332,7 @@ var init_types15 = __esm(() => {
555616
557332
  var init_createDirectConnectSession = __esm(() => {
555617
557333
  init_errors();
555618
557334
  init_slowOperations();
555619
- init_types15();
557335
+ init_types16();
555620
557336
  });
555621
557337
 
555622
557338
  // src/utils/errorLogSink.ts
@@ -566895,7 +568611,7 @@ function SetupNotes(t0) {
566895
568611
  }
566896
568612
  let t2;
566897
568613
  if ($3[1] !== messages) {
566898
- t2 = messages.map(_temp307);
568614
+ t2 = messages.map(_temp308);
566899
568615
  $3[1] = messages;
566900
568616
  $3[2] = t2;
566901
568617
  } else {
@@ -566919,7 +568635,7 @@ function SetupNotes(t0) {
566919
568635
  }
566920
568636
  return t3;
566921
568637
  }
566922
- function _temp307(message, index) {
568638
+ function _temp308(message, index) {
566923
568639
  return /* @__PURE__ */ jsx_dev_runtime490.jsxDEV(ThemedBox_default, {
566924
568640
  marginLeft: 2,
566925
568641
  children: /* @__PURE__ */ jsx_dev_runtime490.jsxDEV(ThemedText, {