mirror of
https://github.com/openclaw/openclaw.git
synced 2026-03-23 16:01:17 +00:00
fix(terminal): stabilize skills table width across Terminal.app and iTerm (#42849)
* Terminal: measure grapheme display width * Tests: cover grapheme terminal width * Terminal: wrap table cells by grapheme width * Tests: cover emoji table alignment * Terminal: refine table wrapping and width handling * Terminal: stop shrinking CLI tables by one column * Skills: use Terminal-safe emoji in list output * Changelog: note terminal skills table fixes * Skills: normalize emoji presentation across outputs * Terminal: consume unsupported escape bytes in tables
This commit is contained in:
@@ -148,6 +148,18 @@ describe("skills-cli", () => {
|
||||
expect(output).toContain("Any binaries");
|
||||
expect(output).toContain("API_KEY");
|
||||
});
|
||||
|
||||
it("normalizes text-presentation emoji selectors in info output", () => {
|
||||
const report = createMockReport([
|
||||
createMockSkill({
|
||||
name: "info-emoji",
|
||||
emoji: "🎛\uFE0E",
|
||||
}),
|
||||
]);
|
||||
|
||||
const output = formatSkillInfo(report, "info-emoji", {});
|
||||
expect(output).toContain("🎛️");
|
||||
});
|
||||
});
|
||||
|
||||
describe("formatSkillsCheck", () => {
|
||||
@@ -170,6 +182,22 @@ describe("skills-cli", () => {
|
||||
expect(output).toContain("go"); // missing binary
|
||||
expect(output).toContain("npx clawhub");
|
||||
});
|
||||
|
||||
it("normalizes text-presentation emoji selectors in check output", () => {
|
||||
const report = createMockReport([
|
||||
createMockSkill({ name: "ready-emoji", emoji: "🎛\uFE0E", eligible: true }),
|
||||
createMockSkill({
|
||||
name: "missing-emoji",
|
||||
emoji: "🎙\uFE0E",
|
||||
eligible: false,
|
||||
missing: { bins: ["ffmpeg"], anyBins: [], env: [], config: [], os: [] },
|
||||
}),
|
||||
]);
|
||||
|
||||
const output = formatSkillsCheck(report, {});
|
||||
expect(output).toContain("🎛️ ready-emoji");
|
||||
expect(output).toContain("🎙️ missing-emoji");
|
||||
});
|
||||
});
|
||||
|
||||
describe("JSON output", () => {
|
||||
|
||||
Reference in New Issue
Block a user