@inceptionstack/roundhouse 0.3.23 → 0.3.24

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": "@inceptionstack/roundhouse",
3
- "version": "0.3.23",
3
+ "version": "0.3.24",
4
4
  "type": "module",
5
5
  "description": "Multi-platform chat gateway that routes messages through a configured AI agent",
6
6
  "license": "MIT",
@@ -133,11 +133,11 @@ function formatTable(tableMd: string): string {
133
133
  if (cp >= 0xFE00 && cp <= 0xFE0F) return 0;
134
134
  // Tags block (used in flag sequences etc)
135
135
  if (cp >= 0xE0001 && cp <= 0xE007F) return 0;
136
- // Emoji (common ranges)
137
- if (cp >= 0x1F100 && cp <= 0x1FAFF) return 2;
138
- if (cp >= 0x231A && cp <= 0x23FF) return 2;
139
- if (cp >= 0x2600 && cp <= 0x27BF) return 2;
140
- if (cp >= 0x2B50 && cp <= 0x2B55) return 2;
136
+ // Emoji Telegram renders these ~3 monospace columns wide in <pre> blocks
137
+ if (cp >= 0x1F100 && cp <= 0x1FAFF) return 3;
138
+ if (cp >= 0x231A && cp <= 0x23FF) return 3;
139
+ if (cp >= 0x2600 && cp <= 0x27BF) return 3;
140
+ if (cp >= 0x2B50 && cp <= 0x2B55) return 3;
141
141
  // CJK Unified Ideographs
142
142
  if (cp >= 0x3400 && cp <= 0x4DBF) return 2;
143
143
  if (cp >= 0x4E00 && cp <= 0x9FFF) return 2;
@@ -155,7 +155,7 @@ function formatTable(tableMd: string): string {
155
155
  const segmenter = new Intl.Segmenter();
156
156
  const graphemeDisplayWidth = (grapheme: string): number => {
157
157
  // ZWJ emoji sequences: multiple code points but render as a single wide emoji
158
- if (grapheme.includes('\u200D')) return 2;
158
+ if (grapheme.includes('\u200D')) return 3;
159
159
  // Single code point: use lookup
160
160
  const cps = Array.from(grapheme);
161
161
  if (cps.length === 1) return codePointWidth(cps[0].codePointAt(0)!);