@getjack/jack 0.1.9 → 0.1.10

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getjack/jack",
3
- "version": "0.1.9",
3
+ "version": "0.1.10",
4
4
  "description": "Ship before you forget why you started. The vibecoder's deployment CLI.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
package/src/lib/output.ts CHANGED
@@ -148,16 +148,19 @@ export function celebrate(title: string, lines: string[]): void {
148
148
  const gradient = "░".repeat(innerWidth);
149
149
  const space = " ".repeat(innerWidth);
150
150
 
151
- const center = (text: string) => {
151
+ // Center text based on visual length, then apply colors
152
+ const center = (text: string, applyBold = false) => {
152
153
  const left = Math.floor((innerWidth - text.length) / 2);
153
- return " ".repeat(left) + text + " ".repeat(innerWidth - text.length - left);
154
+ const right = innerWidth - text.length - left;
155
+ const centered = " ".repeat(left) + text + " ".repeat(right);
156
+ return applyBold ? centered.replace(text, bold + text + reset + purple) : centered;
154
157
  };
155
158
 
156
159
  console.error("");
157
160
  console.error(` ${purple}╔${bar}╗${reset}`);
158
161
  console.error(` ${purple}║${fill}║${reset}`);
159
162
  console.error(` ${purple}║${space}║${reset}`);
160
- console.error(` ${purple}║${center(bold + title + reset + purple)}║${reset}`);
163
+ console.error(` ${purple}║${center(title, true)}║${reset}`);
161
164
  console.error(` ${purple}║${space}║${reset}`);
162
165
  for (const line of lines) {
163
166
  console.error(` ${purple}║${center(line)}║${reset}`);