fix(ui): finish-audit fixes — blank search glyph, quadratic truncation, scope-rail refusal leak
CI / ci (push) Canceled after 0s
CI / ci (pull_request) Canceled after 0s
CI / ci (push) Canceled after 0s
CI / ci (pull_request) Canceled after 0s
Three-reviewer audit of the polish overhaul: - magnifyinglass -> magnifyingglass (blank SF Symbol, all 3 seats) - WordBoundaryTruncation.fit measures each word once (O(n^2) -> O(n) on pathological imported titles; live-title pins unchanged) - scopeHostedSession defers behind an in-flight replay instead of refusing (automatic actions never leak a 'Resume refused' row); replay completion re-fires the pending scope — pinned over the real client path with loadReplayHold, flip-verified - transcript ForEach on stable row ids, not indices - delete dead softBorder param; fold caretPastLeadingBlanks onto firstContentLocation; native TextField prompt for the search field - ElidedPathText.candidates/elide nonisolated (off-actor first(where:) trapped the host); new pins: degenerate truncation shapes, firstContentLocation, elide ladder
This commit is contained in:
1 parent
3a7d495b4b
commit
efad422e03
13 files changed
+163
-65
No files matched your search
@@ -486,20 +486,9 @@ nonisolated extension ProsePresenter {
|
||||
var lineStart = 0
|
||||
while lineStart < nsText.length {
|
||||
let line = nsText.lineRange(for: NSRange(location: lineStart, length: 0))
|
||||
var len = line.length
|
||||
while len > 0 {
|
||||
let char = nsText.character(at: line.location + len - 1)
|
||||
if char == 0x0A || char == 0x0D {
|
||||
len -= 1
|
||||
} else {
|
||||
break
|
||||
}
|
||||
}
|
||||
if len > 0 {
|
||||
let text = nsText.substring(with: NSRange(location: line.location, length: len))
|
||||
if !text.trimmingCharacters(in: .whitespaces).isEmpty {
|
||||
return line.location
|
||||
}
|
||||
let lineText = nsText.substring(with: line)
|
||||
if !lineText.trimmingCharacters(in: .whitespacesAndNewlines).isEmpty {
|
||||
return line.location
|
||||
}
|
||||
lineStart = NSMaxRange(line)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user