@phi-code-admin/phi-code 0.75.0 → 0.75.2

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.
@@ -391,55 +391,57 @@ export class InteractiveMode {
391
391
  this.fdPath = fdPath;
392
392
  // Add header container as first child
393
393
  this.ui.addChild(this.headerContainer);
394
- // Add header with keybindings from config (unless silenced)
394
+ // Phi Code gradient ASCII logo (yellow -> orange -> pink -> magenta).
395
+ // ALWAYS displayed at startup, independent of quietStartup setting.
396
+ // quietStartup only gates the keyboard shortcuts panel below.
397
+ const gradientColors = [
398
+ [255, 220, 50],
399
+ [255, 165, 50],
400
+ [255, 100, 100],
401
+ [230, 80, 150],
402
+ [200, 50, 180],
403
+ [180, 50, 220],
404
+ ];
405
+ const applyGradient = (line) => {
406
+ const chars = [...line];
407
+ const visibleChars = chars.filter((c) => c !== " ");
408
+ const totalVisible = visibleChars.length;
409
+ let visibleIdx = 0;
410
+ return chars
411
+ .map((c) => {
412
+ if (c === " ")
413
+ return c;
414
+ const t = totalVisible > 1 ? visibleIdx / (totalVisible - 1) : 0;
415
+ visibleIdx++;
416
+ const segLen = gradientColors.length - 1;
417
+ const seg = Math.min(Math.floor(t * segLen), segLen - 1);
418
+ const local = t * segLen - seg;
419
+ const [r1, g1, b1] = gradientColors[seg];
420
+ const [r2, g2, b2] = gradientColors[seg + 1];
421
+ const r = Math.round(r1 + (r2 - r1) * local);
422
+ const g = Math.round(g1 + (g2 - g1) * local);
423
+ const b = Math.round(b1 + (b2 - b1) * local);
424
+ return `\x1b[38;2;${r};${g};${b}m${c}\x1b[0m`;
425
+ })
426
+ .join("");
427
+ };
428
+ const asciiLines = [
429
+ " ██████╗ ██╗ ██╗██╗",
430
+ " ██╔══██╗██║ ██║██║",
431
+ " ██████╔╝███████║██║",
432
+ " ██╔═══╝ ██╔══██║██║",
433
+ " ██║ ██║ ██║██║",
434
+ " ╚═╝ ╚═╝ ╚═╝╚═╝",
435
+ ];
436
+ const asciiLogo = asciiLines.map((line) => applyGradient(line)).join("\n");
437
+ const phiLabel = applyGradient(`φ ${APP_NAME.toUpperCase()}`);
438
+ const logo = asciiLogo +
439
+ "\n " +
440
+ phiLabel +
441
+ theme.fg("dim", ` v${this.version}`) +
442
+ theme.fg("dim", " — The Ultimate Coding Agent");
443
+ // Show keyboard hints panel only when not silenced (quietStartup)
395
444
  if (this.options.verbose || !this.settingsManager.getQuietStartup()) {
396
- // Phi Code gradient ASCII logo (yellow -> orange -> pink -> magenta)
397
- const gradientColors = [
398
- [255, 220, 50],
399
- [255, 165, 50],
400
- [255, 100, 100],
401
- [230, 80, 150],
402
- [200, 50, 180],
403
- [180, 50, 220],
404
- ];
405
- const applyGradient = (line) => {
406
- const chars = [...line];
407
- const visibleChars = chars.filter((c) => c !== " ");
408
- const totalVisible = visibleChars.length;
409
- let visibleIdx = 0;
410
- return chars
411
- .map((c) => {
412
- if (c === " ")
413
- return c;
414
- const t = totalVisible > 1 ? visibleIdx / (totalVisible - 1) : 0;
415
- visibleIdx++;
416
- const segLen = gradientColors.length - 1;
417
- const seg = Math.min(Math.floor(t * segLen), segLen - 1);
418
- const local = t * segLen - seg;
419
- const [r1, g1, b1] = gradientColors[seg];
420
- const [r2, g2, b2] = gradientColors[seg + 1];
421
- const r = Math.round(r1 + (r2 - r1) * local);
422
- const g = Math.round(g1 + (g2 - g1) * local);
423
- const b = Math.round(b1 + (b2 - b1) * local);
424
- return `\x1b[38;2;${r};${g};${b}m${c}\x1b[0m`;
425
- })
426
- .join("");
427
- };
428
- const asciiLines = [
429
- " ██████╗ ██╗ ██╗██╗",
430
- " ██╔══██╗██║ ██║██║",
431
- " ██████╔╝███████║██║",
432
- " ██╔═══╝ ██╔══██║██║",
433
- " ██║ ██║ ██║██║",
434
- " ╚═╝ ╚═╝ ╚═╝╚═╝",
435
- ];
436
- const asciiLogo = asciiLines.map((line) => applyGradient(line)).join("\n");
437
- const phiLabel = applyGradient(`φ ${APP_NAME.toUpperCase()}`);
438
- const logo = asciiLogo +
439
- "\n " +
440
- phiLabel +
441
- theme.fg("dim", ` v${this.version}`) +
442
- theme.fg("dim", " — The Ultimate Coding Agent");
443
445
  // Build startup instructions using keybinding hint helpers
444
446
  const hint = (keybinding, description) => keyHint(keybinding, description);
445
447
  const expandedInstructions = [
@@ -473,16 +475,15 @@ export class InteractiveMode {
473
475
  const compactOnboarding = theme.fg("dim", `Press ${keyText("app.tools.expand")} to show full startup help and loaded resources.`);
474
476
  const onboarding = theme.fg("dim", `Pi can explain its own features and look up its docs. Ask it how to use or extend Pi.`);
475
477
  this.builtInHeader = new ExpandableText(() => `${logo}\n${compactInstructions}\n${compactOnboarding}\n\n${onboarding}`, () => `${logo}\n${expandedInstructions}\n\n${onboarding}`, this.getStartupExpansionState(), 1, 0);
476
- // Setup UI layout
477
- this.headerContainer.addChild(new Spacer(1));
478
- this.headerContainer.addChild(this.builtInHeader);
479
- this.headerContainer.addChild(new Spacer(1));
480
478
  }
481
479
  else {
482
- // Minimal header when silenced
483
- this.builtInHeader = new Text("", 0, 0);
484
- this.headerContainer.addChild(this.builtInHeader);
480
+ // quietStartup: show only the logo, no keyboard hints panel
481
+ this.builtInHeader = new Text(logo, 1, 0);
485
482
  }
483
+ // Setup UI layout (always show the header with logo)
484
+ this.headerContainer.addChild(new Spacer(1));
485
+ this.headerContainer.addChild(this.builtInHeader);
486
+ this.headerContainer.addChild(new Spacer(1));
486
487
  this.ui.addChild(this.chatContainer);
487
488
  this.ui.addChild(this.pendingMessagesContainer);
488
489
  this.ui.addChild(this.statusContainer);
@@ -984,7 +985,11 @@ export class InteractiveMode {
984
985
  return lines.join("\n");
985
986
  }
986
987
  showLoadedResources(options) {
987
- const showListing = options?.force || this.options.verbose || !this.settingsManager.getQuietStartup();
988
+ // Phi Code: by default we keep the startup terminal clean.
989
+ // The Context/Skills/Extensions panel only appears with --verbose or
990
+ // an explicit force (eg /reload). Use `phi --verbose` to see resources
991
+ // loaded at startup, or run `/agents`, `/skills`, `/keys list` etc.
992
+ const showListing = options?.force === true || this.options.verbose === true;
988
993
  const showDiagnostics = showListing || options?.showDiagnosticsWhenQuiet === true;
989
994
  if (!showListing && !showDiagnostics) {
990
995
  return;