dankgrinder 8.72.0 → 8.73.0

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.
Files changed (2) hide show
  1. package/lib/ui.js +10 -4
  2. package/package.json +1 -1
package/lib/ui.js CHANGED
@@ -127,8 +127,10 @@ function layout() {
127
127
 
128
128
  // ── Column layout ─────────────────────────────────────────────
129
129
  function getCol() {
130
- const col = { st: 9, name: 18, cmd: 16, bal: 8, ls: 3, lv: 3, earned: 8 };
131
- const nameExtra = Math.max(0, _inner - col.st - col.name - col.cmd - col.bal - col.ls - col.lv - col.earned - 14);
130
+ const col = { st: 9, name: 18, cmd: 18, bal: 10, ls: 3, lv: 3, earned: 10 };
131
+ // Account row visual parts: '│ ' + '# ' + status + ' ' + name + ' ' + doing + ' ' + bal + ' ' + ls + ' ' + lv + ' ' + earned + ' │'
132
+ const rowPadding = 1 + 2 + 1 + col.st + 1 + col.name + 1 + col.cmd + 1 + col.bal + 1 + col.ls + 1 + col.lv + 1 + col.earned + 2;
133
+ const nameExtra = Math.max(0, _inner - rowPadding);
132
134
  col.name += nameExtra;
133
135
  return col;
134
136
  }
@@ -187,9 +189,13 @@ function draw() {
187
189
  const line = i === 1 ? BANNER_LINES[1].replace('PLACEHOLDER', _version) : BANNER_LINES[i];
188
190
  if (i < 2) {
189
191
  const gradLine = gradientLine(line, 77, 212, 238, 255, 92, 147);
190
- process.stdout.write(`${B}│\x1b[0m ${gradLine}${' '.repeat(_inner - 2 - stripAnsi(gradLine) - 2)}${B}│`);
192
+ const ansiLen = stripAnsi(gradLine).length;
193
+ const totalContent = 2 + ansiLen; // left spaces + content
194
+ process.stdout.write(`${B}│\x1b[0m ${gradLine}${' '.repeat(Math.max(0, _inner - totalContent - 1))}${B}│`);
191
195
  } else {
192
- process.stdout.write(`${B}│\x1b[0m ${DIM}${line}${c.reset}${' '.repeat(_inner - 2 - stripAnsi(line) - 2)}${B}│`);
196
+ const ansiLen = stripAnsi(line).length;
197
+ const totalContent = 2 + ansiLen;
198
+ process.stdout.write(`${B}│\x1b[0m ${DIM}${line}${c.reset}${' '.repeat(Math.max(0, _inner - totalContent - 1))}${B}│`);
193
199
  }
194
200
  ln();
195
201
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dankgrinder",
3
- "version": "8.72.0",
3
+ "version": "8.73.0",
4
4
  "description": "Dank Memer automation engine — grind coins while you sleep",
5
5
  "bin": {
6
6
  "dankgrinder": "bin/dankgrinder.js"