ccgather 2.0.36 → 2.0.38

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/dist/index.js +5 -15
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -146,18 +146,7 @@ function _stripAnsi(str) {
146
146
  }
147
147
  function getDisplayWidth(str) {
148
148
  const stripped = _stripAnsi(str);
149
- let width = (0, import_string_width.default)(stripped);
150
- const emojiRegex = /[\u{1F300}-\u{1F9FF}]|[\u{2600}-\u{26FF}]|[\u{2700}-\u{27BF}]|✦/gu;
151
- const emojis = stripped.match(emojiRegex);
152
- if (emojis) {
153
- for (const emoji of emojis) {
154
- const emojiWidth = (0, import_string_width.default)(emoji);
155
- if (emojiWidth === 1) {
156
- width += 1;
157
- }
158
- }
159
- }
160
- return width;
149
+ return (0, import_string_width.default)(stripped);
161
150
  }
162
151
  function header(title, icon = "") {
163
152
  const iconPart = icon ? `${icon} ` : "";
@@ -277,7 +266,7 @@ var init_ui = __esm({
277
266
  "use strict";
278
267
  import_chalk = __toESM(require("chalk"));
279
268
  import_string_width = __toESM(require("string-width"));
280
- VERSION = true ? "2.0.36" : "0.0.0";
269
+ VERSION = true ? "2.0.38" : "0.0.0";
281
270
  colors = {
282
271
  primary: import_chalk.default.hex("#DA7756"),
283
272
  // Claude coral
@@ -1466,7 +1455,8 @@ async function submit(options) {
1466
1455
  console.log();
1467
1456
  const sectionHeader = (icon, title) => {
1468
1457
  const text = `${icon} ${title} `;
1469
- const lineLength = 40 - text.length;
1458
+ const textWidth = getDisplayWidth(text);
1459
+ const lineLength = 48 - textWidth;
1470
1460
  return ` ${colors.white.bold(text)}${colors.dim("\u2500".repeat(Math.max(0, lineLength)))}`;
1471
1461
  };
1472
1462
  const accumulatedTokens = result.previous?.totalTokens || usageData.totalTokens;
@@ -1533,7 +1523,7 @@ async function submit(options) {
1533
1523
  }
1534
1524
  }
1535
1525
  console.log();
1536
- console.log(sectionHeader("\u2B06\uFE0F", "Level Progress"));
1526
+ console.log(sectionHeader("\u2B06\uFE0F ", "Level Progress"));
1537
1527
  console.log();
1538
1528
  console.log(
1539
1529
  ` ${colors.muted("Lv.")}${colors.white(String(currentLevel.level))} ${currentLevel.icon} ${currentLevel.color(currentLevel.name)}`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ccgather",
3
- "version": "2.0.36",
3
+ "version": "2.0.38",
4
4
  "description": "CLI tool for syncing Claude Code usage data to CCgather leaderboard",
5
5
  "bin": {
6
6
  "ccgather": "dist/index.js",