perf(native): avoid sanitizing snapshot values twice (#20271)

This commit is contained in:
Neil
2026-09-12 18:06:33 -07:00
committed by GitHub
parent a5dac280e4
commit 8713f6ee72
@@ -238,11 +238,10 @@ public enum SnapshotRenderHeuristics {
if roleText == "heading", Int(value) != nil {
return nil
}
let clean = sanitize(value)
if roleText == "text" || roleText == "text entry area" || roleText == "scroll bar" || roleText == "value indicator" {
return " \(clean)"
return " \(value)"
}
return ", Value: \(clean)"
return ", Value: \(value)"
}
private static func markdownEscaped(_ value: String) -> String {