This page exercises Plan 68c Phase S5 hooks:
URL-change handler (history.pushState / popstate / hashchange) and the
MutationObserver on dynamically rendered phone numbers.
Call our main line: (555) 123-4567
This should already be swapped to the Corporate pool's tracking number on page load.
Click the button to inject new content with a phone number below. The phone number in the injected content should be swapped within 50–100ms (debounced MutationObserver tick).
history.pushStateThese buttons change the URL without a full page reload. The phone module's
URL-change handler should:
1. Reset its swap dedupe state
2. Re-evaluate the 5 gates against the new URL
3. Trigger a fresh swap if the new pool's tracking number is in cache (or a fetch if not).
After clicking, this page's content stays the same (we don't actually swap content; this just mimics a SPA route change). Inspect the DOM — the phone module should re-fire its swap logic because the URL changed. Use the inject buttons above AFTER navigating to verify the observer is still attached.
hashchange eventClick to change the URL hash. The URL-change handler also listens for
hashchange, so this should fire the same re-evaluate path.
Click 5 times rapidly. The injected phone number should be swapped once; subsequent injections of the same wrapped span should not be re-processed.