oficina / docs Public

saving-webkit.swift watches the toast by its placement

Fable's delta on #179 (F4): the WKWebView drive observed the first
[estilo-save-status] in the page, which is now the phone's subtitle. It
observes [estilo-save-status~="floating"], the toast the editor mounts,
as the Playwright drives already do. No assertion could fail on the old
selector, since the editor gives the subtitle the same trouble states;
the drive now watches the element it means to.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Paul Campbell pushed by claude agent, operated by paul@keymail.dev efcf21238f992750c11d3b824b44dab0fbd72511 parent 95f3c20
1 file changed, +1 −1
  • fixtures/engines/saving-webkit.swift +1 −1
diff --git a/fixtures/engines/saving-webkit.swift b/fixtures/engines/saving-webkit.swift
index 3d70089..52f0786 100644
--- a/fixtures/engines/saving-webkit.swift
+++ b/fixtures/engines/saving-webkit.swift
@@ -189,7 +189,7 @@ struct Config: Decodable {
web.load(URLRequest(url: URL(string: config.origin + "/d/" + config.doc)!))
guard await until(editor, seconds: 30) else { throw NSError(domain: "the editor never opened", code: 1) }
try await Task.sleep(for: .milliseconds(500))
- _ = try await js("window.__saveStates = []; new MutationObserver(() => window.__saveStates.push(document.querySelector('[estilo-save-status]').getAttribute('data-state'))).observe(document.querySelector('[estilo-save-status]'), { attributes: true, attributeFilter: ['data-state'] }); addEventListener('pageshow', (e) => { window.__persisted = e.persisted }); true")
+ _ = try await js("window.__saveStates = []; new MutationObserver(() => window.__saveStates.push(document.querySelector('[estilo-save-status~=\"floating\"]').getAttribute('data-state'))).observe(document.querySelector('[estilo-save-status~=\"floating\"]'), { attributes: true, attributeFilter: ['data-state'] }); addEventListener('pageshow', (e) => { window.__persisted = e.persisted }); true")
let beforeText = config.before ?? "Before leaving"
let before = String(data: try JSONEncoder().encode([beforeText]), encoding: .utf8)!
var since = Date()