mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-09 08:37:41 +00:00
fix(tui): preserve credential-like tokens in render sanitization
This commit is contained in:
@@ -249,6 +249,20 @@ describe("sanitizeRenderableText", () => {
|
||||
expect(sanitized).toBe(input);
|
||||
});
|
||||
|
||||
it("preserves long credential-like mixed alnum tokens for copy safety", () => {
|
||||
const input = "e3b19c3b87bcf364b23eebb2c276e96ec478956ba1d84c93";
|
||||
const sanitized = sanitizeRenderableText(input);
|
||||
|
||||
expect(sanitized).toBe(input);
|
||||
});
|
||||
|
||||
it("preserves quoted credential-like mixed alnum tokens for copy safety", () => {
|
||||
const input = "'e3b19c3b87bcf364b23eebb2c276e96ec478956ba1d84c93'";
|
||||
const sanitized = sanitizeRenderableText(input);
|
||||
|
||||
expect(sanitized).toBe(input);
|
||||
});
|
||||
|
||||
it("wraps rtl lines with directional isolation marks", () => {
|
||||
const input = "مرحبا بالعالم";
|
||||
const sanitized = sanitizeRenderableText(input);
|
||||
|
||||
Reference in New Issue
Block a user