Safe areas: research how iOS 27 Safari tints the status bar and toolbar, then a lab page #476
Closed
opened 2026-10-16 06:50:48 +00:00 by kayg
·
5 comments
No Branch/Tag specified
main
port/tasks-float-2
fix/train-1116-2
fix/train-1116-3
fix/train-1116-1
fix/flake-1134
fix/server-1182
dev
port/notes-float-3c
docs/auto-update-ig
feat/dav-transport
port/tasks-float-1
wip/mail1011-sv-order-1116
fix/flake-1179
fix/flake-1178
fix/guards-1153-fsio-split
fix/guards-1153-notes-split-we
fix/guards-1153-notes-lib
fix/guards-1153-notes-home
fix/guards-1153-ui-primitives
fix/guards-1153-primitives-e2e
fix/guards-1153-visibility-doc
feat/paper-grey-1116
fix/flake-1165
fix/flake-1119
docs/imap-766-plan-v2
fix/e2e-unique-ports
t3/paged-search-reconcile-final
wip/mail1011-final-1115
docs/tasks-float-port
perf/editor-first-paint-1c
feat/imap-notes-fetch
feat/imap-notes-projection
feat/imap-notes-readonly
feat/imap-notes-auth
feat/imap-notes-server-foundation
wip/mail1011-txn-ownvocab-1115
wip/mail1011-txn-novocab-1115
perf/p1117-final-harness
perf/single-shot-repeats
port/tasks-matrix
wip/mail1011-txn-1115
fix/static-gates-1155
feat/files-s1-identity-r7
fix/files-r7-idle-loop
fix/daily-train-1152
port/notes-float
fix/editor-tables-test-types
port/notes-float-listscript
feat/tasks-actions
port/notes-float-phone-preload
perf/sound-comparator
port/notes-float-listscroll
port/notes-float-budgets
port/notes-float-suite-fix-b
port/notes-float-sidebar-fix
port/notes-float-trim
port/notes-float-3-lists
fix/attachments-meta-capability
docs/carddav-writes-v2-plan
feat/contacts-companion-pure
issue/carddav-read-perf-fix-r2
issue/carddav-read-r2
port/notes-float-devsync2
review/calendar-2
review/switcher-a-pills
port/notes-float-switcher-a
port/port-tables-2
review/switcher-ends
wip/whiteboard-s1-1114
port/port-tables
wip/mail1011-perfneutral
review/photo-tint
port/notes-float-shell
wip/local/collections-db
wip/local/mail-p1
wip/local/cold-growth-on-tiering
wip/local/tiering-v3-s1
wip/local/wal1051-cap
wip/local/tiering-v3-s1-resume
wip/local/index-position-startup-scan
port/notes-float-flat
port/notes-float-promote
wip/handover/mail1011-candidate
wip/handover/files-s1-candidate
port/notes-float-shell-only
port/notes-float-perf
feat/whiteboard-s1
feat/tiering-v5
fix/app-switch-hitch
wip/local/files-s1-dev-v4-final
feat/files-s1-dev-v4
fix/c2-glass-shared
feat/flat-lists
wip/handover/whiteboard-s1-resume
wip/att-lazy-861
feat/switcher-browse
wip/att-lazy-860
feat/tasks-float
recovered/flat-backup-candidate
perf/stalls-1054-kc
land/ai-toolbar
feat/collections-db
feat/collections-db-fixes
codex/mail-1011-redesign-20261111
fix/ai-toolbar
backup/macos-vm/st3-head
perf/trim-candidate-phonestack
feat/switcher-three
fix/1051-index-idle-checkpoint
perf/stalls-1054-kb
perf/stalls-1054-k
perf/stalls-1054-r3
fix/c2-contrast-tail
perf/stalls-1054-r3-preview
feat/collections-before
feat/tiering-v4
fix/timelog-caret
wip/local/tasks-actions
docs/tasks-writes-v2-plan
st3-r3
feat/pass8
review/calendar-2-before-1111
wip/tiering-v3-cold4
perf/stalls-1054-r2
fix/suite-A4
fix/suite-A5-probe
fix/suite-A6
fix/suite-A3
fix/suite-A2
fix/suite-A5
fix/suite-A1
wip/local/attachments-861-fix
feat/contrast
wip/local/ports-861
storage/wal-checkpoint-off-save-1051
wip/local/mail-1011-reconcile-20261110
feat/style-sheet-fixes
feat/money-round
perf/stalls-1054
wip/tiering-v3-cold5
t3/mail-1011-liveness
feat/iphone-fixes
feat/notes-approve
wip/local/shrow-work
feat/files-s1-identity
feat/quickfix
wip/tiering-v3-cold
wip/local/shared-row-swipes
backup/macos-vm/pfx-B
backup/macos-vm/pfx-C
backup/macos-vm/pfx-D
feat/contrast-r1
feat/tiering-v3-s2-tags
feat/folder-drop
t3/photos-s1
feat/tiering-v3-s1-namespace
wip/local/photos-s1
t3/photos-plan-slice-one
recovered/backup/p1b-61505
t3/paged-search-reconcile
t3/smooth-pane-transitions
t3/index-position-startup-scan
fix/private-staging-759b-r2
backup/macos-vm/hk/hk1009/pr877
backup/macos-vm/hk/hk1009/pr878
docs/undo-block-ids-plan
fix/undo-768
backup/macos-vm/hk/hk1009/pr875
backup/macos-vm/hk/hk1009/pr904
proto/block-identity-v7d
backup/macos-vm/hk/hk1009/pr846
backup/macos-vm/hk/hk1009/pr860
backup/macos-vm/hk/hk1009/pr861
backup/macos-vm/hk/hk1009/pr849
backup/macos-vm/hk/hk1009/pr848
backup/macos-vm/hk/hk1009/pr853
backup/macos-vm/hk/hk1009/pr957
backup/macos-vm/hk/hk1009/pr893
backup/macos-vm/hk/hk1009/pr889
backup/macos-vm/hk/hk1009/pr902
docs/imap-notes-plan
docs/quota-plan-2
fix/parallel-test-flakes
docs/calendar-backend-v2-plan
feat/calendar-ical-converter
backup/macos-vm/hk/hk1009/pr808
docs/contacts-import-v2-plan
issue/610-pm-midnight
feat/calendar-v2-s1-containment
backup/macos-vm/hk/hk1009/pr854
backup/macos-vm/hk/hk1009/pr845
backup/macos-vm/hk/hk1009/pr917
docs/dav-recorder-v2-plan
plan/previews-865
plan/save-log-durable-entry
backup/macos-vm/hk/hk1009/pr934
fix/e2e-data-on-ram
backup/macos-vm/hk/hk1009/pr888
feat/appwindow3
feat/appwindow2
feat/appwindow
feat/money-p1
feat/keys-sheet
review/calendar-2-themes
feat/smooth-cursor
fix/float-style
review/calendar-2-float
release/2026-11-06-hotfix
archive/port/rows-drop-code
archive/port/rows-actions
archive/port/rows
scratch/tasks-894-ui-gates
review/calendar-2-night-wip
recovered/flaky/toast-reduced
release/2026-11-05
archive/flaky/rows-drop-fixed
archive/flaky/rows-actions
archive/flaky/rows
sim/bm15-final
sim/bm15-bis-932
sim/bm15-bis-909
sim/bm15
sim/bm15-bis-887
perf/tiering-option-b
fix/sw-lazy-precache
archive/plan/save-log-durable-entry
mock/money-fix2
archive/fix/e2e-data-on-ram
mock/appearance-all
mock/pill-press
mock/pill-press-mac
backup/macos-vm/appearance-after
mock/auto-swipes
mock/mail-actions
backup/macos-vm/mock/mail-actions
mock/money-static
archive/review/standards-917
perf/tiering-761-fix
mock/type-audit
mock/third-pane
feat/contacts-import-v2-s1
perf/executor-hot-path
archive/port/hidden-blocks
archive/port/devices
scratch/executor-on-894
scratch/executor-spans2
scratch/executor-spans
archive/port/rows-drop
feat/tiering-761-d-scale
feat/tiering-761-c-index
feat/tiering-761-b-reader
archive/review/sharing-pr3-review-9fec3d1f
perf/ports-lazy-budgets
feat/tiering-761-a-migration
archive/review/sharing-pr3-review
archive/review/sharing-pr3-review-code
archive/plan/previews-865
archive/port/port-attachments-3
archive/port/contacts-merge
fix/motion-audit-859
fix/motion-audit-859-mac
archive/port/port-pickers
archive/port/port-tables-2
archive/port/port-tables
recovered/local/sharing-s1-pr2-room-snapshot-candidate
archive/fix/parallel-test-flakes-code-minipc01
docs/imap-766-readonly-slice
feat/dav-recorder-v3
research/788-diagnosis
archive/fix/parallel-test-flakes
archive/perf/pr792-cold-index-edit
docs/sharing-slice-1
recovered/feat/dav-recorder-v2
recovered/feat/dav-recorder-v2-edd7bbb
spike/imap-766-s0-cases
archive/fix/undo-768
recovered/feat/dav-recorder
recovered/feat/dav-recorder-901acd4
feat/contacts-import
perf/cold-growth-on-764
perf/cold-growth-on-tiering
recovered/feat/tasks-set-status
feat/tasks-move-reorder
feat/tasks-delete-promote-duplicate
feat/carddav-writes
perf/quota-on-tiering
perf/quota-simple
perf/cold-growth-on-quota-stack
recovered/perf/cold-growth-on-tiering
feat/calendar-identity
feat/calendar-event-parser
feat/calendar-props-maps
port/glass-when-ring
recovered/feat/tiering-761-s1-wip-8132a84
recovered/feat/tiering-761-s1-wip-9da4094
recovered/feat/tiering-761-s1-wip-724512c
recovered/feat/tiering-761-s1-wip-66e667e
recovered/feat/tiering-761-s1
wip/6by32-01-tier-761-s1-pause-20261030
spike/imap-766-s0
wip/6by32-02-calternal-pause-20261030
wip/8by64-01-review-688-pause-20261030
wip/6by32-01-verify-744-pause-20261030
wip/6by32-01-verify-742-pause-20261030
fix/private-staging-759b
wip/6by32-01-review-748-pause-20261030
wip/6by32-01-review-733c-pause-20261030
wip/6by32-01-review-733b-pause-20261030
review/calendar-month
wip/local/bm15-trash
plan/759b-staging
review/767b-tests
review/preview-2026-10-29
docs/tiering-731-plan
wip/c6b02-review-733d
wip/c6b02-bm1-full-a
docs/deploy-plan
fix/storage-owner-liveness-642
fix/storage-fix-7
feat/tiering-731
wip/tiering-731-first-attempt
perf/idle-honest-2
fix/storage-private-tmp-642-dev
fix/storage-exact-file-quarantine-642
perf/one-flush-save
review/calendar-static
review/indexing-ring
review/when-field-2
proto/block-identity-2-review
proto/block-identity-review
review/when-field
issue/tasks-create-ids
issue/tasks-create
review/combined
review/task-polish
review/top-buttons
review/q1-q5
archive/integ325-293
archive/integ325-ci
issue/calendar-adr
archive/old/train/2026-10-23bk2
archive/old/train/2026-10-23bk
issue/469-mockup-9a
issue/smart-tasks-mockup
issue/469-menus
issue/652-signout-flake
issue/652-history-fix7
issue/652-history-fix6
archive/old/issue/spring-check-perf
issue/spring-check-perf
issue/659-rename-fast
archive/old/train/2026-10-21ar
issue/search-hardening-3
issue/652-history-fix5
issue/660-port-sheets-glass
issue/652-history-fix4
issue/652-history-fix3
issue/652-history-fix2
issue/652-history-flake
train/2026-10-21an
issue/settings-admin-port
issue/search-port
train/2026-10-20am
issue/storage-split-fix2
issue/storage-split
archive/old/issue/folder-ids-fix
train/2026-10-20al
archive/old/issue/folder-ids
train/2026-10-20ak
issue/tables-mockup
train/2026-10-19aj
train/2026-10-19ai
issue/469-merge-fixes
issue/sidebar-band
archive/old/issue/608-settings-spec
train/2026-10-19ah
issue/swipe-offscreen
train/2026-10-19ag
archive/old/issue/590-nlp-adr
archive/old/issue/587-event-after-write-2
train/2026-10-19af
archive/old/issue/587-event-after-write
issue/469-pill-room-c
issue/469-pill-room
train/2026-10-19ae
issue/469-narrow-handle
issue/397-ios-swipe-2
issue/469-desk-fixes
archive/old/issue/auto-update-adr
issue/469-filter-gap
issue/469-port-1b
issue/442-opacity-flake
issue/327-web-fast-3
archive/old/issue/469-port-1
issue/469-port-1
issue/327-web-fast-2
archive/old/issue/327-web-fast
archive/old/issue/425-stt-bench-vq1
archive/old/issue/445-no-bleed
archive/old/issue/400-swipe-mockup-2
issue/426-client-review
issue/426-client-2
issue/426-client
archive/old/issue/476-safe-area-lab
archive/old/issue/445-top-light
issue/471-blocks-mockup
archive/old/issue/448-links-app-2
archive/old/issue/448-links-app
archive/old/issue/398-cold-links
issue/434-442-small-2
issue/434-442-small
archive/old/issue/398-unload
archive/old/issue/445-bottom-band
issue/445-bottom-band
issue/351-rem-3
issue/351-rem-2
issue/351-rem
archive/old/issue/327-first-note
issue/395-width-phone
archive/old/issue/327-typing
issue/396-ios-edges
issue/397-ios-swipe
archive/old/issue/327-notes-index
issue/345-347-contrast-empty-2
archive/old/issue/44-arenas
issue/44-arenas
archive/integ325
archive/old/issue/327-perf-harness
archive/old/issue/44-thp
issue/44-thp
archive/old/issue/285-sticky-pills
archive/old/issue/44-trim-3
issue/44-trim-3
archive/old/issue/165-cards
archive/old/issue/165-picker-2
archive/old/issue/212-multi-select
No results found.
Labels
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".
No due date set.
Dependencies
No dependencies set
Reference
kayg/calternal#476
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
kayg (2026-10-16), on a real iPhone (iOS 27, Safari tab, light), with chrome.html: still a flat grey band behind Safari's bottom toolbar and a lighter strip under the status bar. The simulator showed the same page with no bottom band, so the simulator does not match the device for this.
kayg: "you really gotta research bottom and top safe areas".
Plan:
Research: what decides the colour behind the status bar and the floating toolbar (iOS 26/27 Safari)
Written before any code change. Every claim has a link. "Unconfirmed" is said where it is. Short version first.
Short version
<body>colour. In your screenshot the band is a flat#d0d5d9(measured), right below the blue sky (#a7c7f0). That is the root colour our app sets (background-color: var(--edge-shown)onbody). Safari paints the bar's area from the page, and when it finds nothing to sample it falls back to the page background colour. So we are in the "nothing qualifies" branch.position: fixed/stickyelements at the edge. Our fixed backdrop is a viewport-sized box with a transparentbackground-color(the sky is painted by children), and our bottom search bar floats 18 pt above the edge. A fixed viewport-sized layer is also treated as a "dimming layer" or "viewport-sized" candidate that is blended over the page background, not read as pixels. And ourbodyisoverflow: hidden, so the document never scrolls and Safari never composites page content under the bar either (the other way the bar can show the page).UIColor.systemBackgroundColor(near-white in light mode) in the top inset at scroll origin when no fixed element supplies a top colour. Unconfirmed that it is in the build on your phone.1. How Safari 26/27 picks the colour behind the status bar and the bottom toolbar
theme-coloris ignored in Safari 26+. The safari-color-tinting README: Safari 26 "still parses the meta tag but no longer uses this color". Same in 1ar.io and jahir.dev. Joe Bell's apple-web-app notes list "theme-color → ignored" in simulator runs on 26.5 and 27.0. (Keep it for Chrome/Android.) A Nasedkin write-up advises "do not assume it forces Safari 26-27 toolbar tinting" (nasedk.in). Not tested by anyone on a device on iOS 27 that I could find; lab variants 6 and 7 test it.The rule comes from WebKit's source,
LocalFrameView::fixedContainerEdges(LocalFrameView.cpp, main; I readmain, which may be newer than iOS 27.0). What it does, per edge:sampleRectMargin = 4). Onlyposition: fixedorstickyelements count (NotFixedOrStickyis skipped). Anabsolutechild of a fixed element is not a candidate.minimumRatio = 0.9). Elements with a border box of 10 px or less in either direction give no colour from their own background (thinBorderWidth = 10; a smaller one is sampled from a 2 px strip of real pixels). Hidden or nearly transparent elements are skipped.background-coloris read, notbackground-image. If the element's colour is not visible, WebKit asksPageColorSampler::predominantColorto sample the rendered pixels at the edge instead. Colour with alpha under 0.75 is blended over the page background colour (minimumOpacityThresholdToClampToSolidColor = 0.75).backdrop-filter: a fixed element withbackdrop-filteris reported asPredominantColorType::Multiple(foundBackdropFilter), not a solid colour. So a blurred bottom bar does not give a clean tint.isProbablyDimmingContainer,IsDimmingLayer). A viewport-sized fixed element also "prefers the existing colour" when one is already set (preferExistingColor).pageExtendedBackgroundColor).A WebKit engineer says the same in words: the solid extension happens when a fixed or sticky element sits at an edge next to an obscured inset, and a non-fixed header does not do it (bug 301756, comment 2, Wenson Hsieh). The thread never states that the
html/bodybackground is the source; that is the reporter's reading.html/bodybackground. The fallback chain, from testing:<body>'sbackground-color, else<html>'s, else white (light) or black (dark) (safari-color-tinting; Joe Bell, item 6). A rootbackground-imageis "not reliable as toolbar tint input" (1ar.io); at scroll 0 Safari used the CSSbackground-color, not a fixed background-image layer (Huxpro/hux.pro #92, emulation only, closed).Gradients and images at the edge. Joe Bell: "A full-screen fixed gradient turns both bars solid": a
position: fixed; inset: 0layer painted withbackground-imagehas a transparentbackground-color, is hit, and is blended over the page background, so the bars become the page colour and the gradient never reaches them. The fix there is full-width fixed edge strips with an opaquebackground-colorabove the gradient. Simulator only for that exact claim (notes from 2026-10-15), though the fixed/absolute split, widths and depths were also checked on an iPhone 17 Pro, iOS 27.0 (same page).Thresholds from testing (disagree slightly with the source). Community: within 4 px of the top / 3 px of the bottom, at least 80% wide, at least 3 px high (andesco, jahir.dev). Joe Bell says those do not match the source or his runs: 90% used, 80% not; 6 px deep used, 4 px ignored; a narrow pill at the centre of an edge takes the bar over (device-checked on an iPhone 17 Pro, iOS 27.0). I follow the source and Bell. The lab strips are full width and 28 px + inset deep, so both readings are met.
iOS 27 top edge (the "lighter strip" candidate). WebKit commit 8b5cfad, "[iOS] Don't extend page colors under sidebar or top inset" (bug 317336, landed 2026-07-29): "starting in iOS 27, page colors or content should not appear in the leading or trailing obscured inset areas ... when the page is at its scroll origin." For the top, "if there's no visible sampled top color extension and the top inset is greater than zero, a non-interactive top system background extension is created", coloured
UIColor.systemBackgroundColor; "if a sampled extension is visible, the top system extension fades out instead." Later, on 2026-10-10, PR #76538 (bug 327043) was merged: "Remove the top system background color extensions for iOS". Safari 27.0 shipped on September 14 (nasedk.in). Unconfirmed: whether 8b5cfad is in the iOS 27 build on your phone, and whether the strip you see is that extension. It would explain a near-white band at scroll 0 with a coloured sky below it. If it is that, a qualifying fixed top strip should switch it off (variants 10, 11).2. "Content under the toolbar": when it shows through, when Safari paints its own bar
body { overflow: hidden }, inner scroller). Two sources warn about it:overflow: hiddenon body starved Safari's chrome compositor (Huxpro #92), and at scroll 0 Safari "often shows the sampled or fallback root background-color, not visible media"; with non-zero scroll it can composite real pixels behind the top area (1ar.io). Their fix is a document that is always taller than the viewport (variant 8). Both are blog-level evidence, not Apple statements.viewport-fit=cover: disputed. andesco and 1ar.io say the bottom tint needs it (andesco, 1ar.io); jahir.dev says cover plus an explicit html colour did not fix their case (jahir.dev); Joe Bell says it makes no difference to either bar. In a Safari tab WebKit itself says it will not give top and bottom insets for cover in portrait: bug 306465, Tim Horton, 2026-08-19: "for web compatibility's sake, we can't provide top and bottom insets like you're hoping for here". The simulator agrees:env(safe-area-inset-top/bottom)is 0 in a Safari tab (lab output). So in a tab, env insets can never size a bar strip; use fixed minimums (lab strips usemax(28px, inset)style sizes).bottom: -8px,min-height: 12px,width: 100%, with abackground-color(jahir.dev). Pitfalls recorded by Bell: a narrow fixed pill at an edge's centre takes the bar over; an empty full-screen fixed layer above a dim hides it; a strip faded in by opacity or translated in "sticks" once sampled (keep strips in place and change their colour);<html>and<body>in different colours leave a 1 px hairline (same page).3. Home Screen apps (standalone)
apple-mobile-web-app-status-bar-style:defaultis an opaque system/white bar and the page does not draw under it;blackis opaque black;black-translucentis transparent and the page draws under it, with a realenv(safe-area-inset-top). It only applies whenapple-mobile-web-app-capableisyesand the app was added to the Home Screen (Joe Bell; his device checks were iOS 27.0, "No iOS 26 device was checked"). In his table the top inset is0pxfordefaultandblackand a real inset forblack-translucent. Manifesttheme_coloris not applied to Home Screen apps as of 26.1 (same page). Nothing I found documents a change to these three values for iOS 26/27 beyond the bug below.screen.height874;innerHeight,100dvh,clientHeightandvisualViewport.heightall 812 (offsetTop 0): "a 62px system-drawn gap" above the web layer; tabs are fine; "the bottom bar color is cached from the page background and updates only after relaunch" (one commenter's claim, unconfirmed). Another commenter arguesvh/lvhmatch the full screen whilesvh/dvhmatch the area above the bar. No engineer has explained it (rdar://184081721). Related: 301108 (viewport-fit=coverdoes not fill the screen).4. Units and values (what the evidence supports)
position: fixed; inset: 0(no unit needed).100svhfor the shell;100lvhonly for something that must reach under a collapsed toolbar.env(safe-area-inset-*)is 0 in a tab.innerHeight714,lvh754 (lab, simulator); bug 306465; Safari 26.1 fixed a100dvhbottom gap (Joe Bell notes)screen.height,innerHeightand afixed; top: 0; bottom: 0box at runtime and size the backdrop to the largest; realenv()insets only withblack-translucent.html { background }background-coloronbody(it wins overhtml) and keephtmlthe same colour. Not a gradient.viewport-fit=coverin Safari tabs: neutral to harmful per the sources above; the lab compares 2 and 3.5. Recipes people report working
background-color, more than 10 px deep, followed by fades into the scene; only the strips are sampled. Reported on an iPhone 17 / iOS 27.0.1 for scroll-changing colours, with a known flicker on fast flings (ios-26-notes). This is variants 10 and 11.background-colorandbackdrop-filteron the fixed element itself.theme-colorin sync for Chrome only (nasedk.in).Not found / unconfirmed
main's sampling rules equal what shipped in iOS 27.0, and whether commit 8b5cfad is in it.backdrop-filterresult is "Multiple colours" in the source; how Safari draws that (probably its own blur material) is not documented.overflow: hiddenpage on iOS 27; that is our case and the lab covers it (variants 9, 11).Addendum to the research:
backdrop-filterat the screen edge (the top 20-40 px of glass darkening)Hypothesis from the harness work on #445 (the evidence is in the #445 comment): WebKit blurs nothing above the top of the screen, so a glass element's blur mixes in the root background there, and the top 20-40 px of glass come out flatter/darker. A red root turned exactly that strip red in the simulator. What I could find for and against:
What is documented
blur()in the list usesedgeMode="mirror", with the edge being "the clipped, transformed border box of the element" (Filter Effects 2, editor's draft). So by the spec, pixels beyond the element's box should not bleed in; edges are mirrored. The same draft says the root element is always a Backdrop Root because "there is nothing above the root element". It does not say what a blur reads past the viewport. The draft has no working-group consensus on Backdrop Root.inputNormalizeEdgesTransparentbecause "the check for whether the backdrop is opaque doesn't work". That shows WebKit has two edge behaviours (opaque-backdrop and transparent-edges normalisation) and picks by whether it thinks the backdrop is opaque. I found no iOS Safari equivalent write-up. Unconfirmed that iOS takes the same path or what it does at the viewport edge.mask-image, so outside colours can contribute (DEV: "Your backdrop-filter is working. Your background is hiding it"; a blog-level source, not a WebKit statement, and it does not mention the screen edge).What I could not find: no WebKit bug, release note or write-up about "blur edge bleeding at the viewport edge" or the status-bar area on iOS 26/27. The hypothesis is consistent with the spec's "nothing above the root" and with the red-root observation, but nothing public confirms the mechanism. The lab tests it directly:
inset: -80px), so a live blur at the screen edge has sky pixels to read beyond the edge. Caveat: if WebKit clips the backdrop input at the viewport (as the 2019 thread suggests), oversizing will change nothing; that would itself be a finding.filter: blur) and the glass has nobackdrop-filter. If the top darkening disappears here, live blur at the edge is the cause.&root=redon any variant paints the root and body red, so a bleed shows as red at the edge (variants 3, 13 and 14 were run with it).Safe-area lab is live: https://preview.calternal.cloud/safe-area-lab.html?v=1
Mockup, not the product. PR: "mockup, do not merge" (
issue/476-safe-area-lab, fileapps/mockup/safe-area-lab.html; one file, no build, no assets). Servedno-cache; the live bytes match the build (sha256 of the live file equals the file in the PR). Research is in the two comments above.Each page is a sky backdrop, a long Journal list, the two top pills and the bottom search bar, plus a card at the top with big number buttons, one line saying what the variant does, and live numbers:
innerHeight(and the min/max it has been),visualViewportheight/offsetTop/scale, screen size, the realenv(safe-area-inset-*),dvh/svh/lvh/vhin px, afixed; top: 0; bottom: 0box height, display-mode, scroll positions, theme-color. The two pills at the top have ◀ ▶ to flip variants; every flip is a full reload on purpose (Safari keeps what it sampled for the bars until reload). "Copy numbers" copies the block so you can paste it into a reply. Variant picked with?v=N.Extra switches:
&root=redpaints the root red (shows what an edge shows through),&sb=default|black|black-translucent(Home Screen status bar style; default is what the app uses).The 15 variants (one strategy each)
htmlbackground-image: top colour to bottom colour. No fixed layer.inset: 0), noviewport-fitviewport-fit=cover+ env insets (2 vs 3 isolatesviewport-fit)backdrop-filter: blur(20px)theme-colortheme-colorrewritten on scrollbodyoverflow hidden, flat root colour#d0d5d9, inner scroller, fixed backdrop with children, app'stheme-colorscreen.height, no strips (for the Home Screen app's short viewport)inset: -80px), live blur on the glass, no stripsbackdrop-filter, no stripsChecklist for kayg (light mode, Safari tab with the floating toolbar; about 2 minutes)
For each number, load it (
?v=N), look at the top and the very bottom at scroll 0, then scroll to the end and look again. Reply with the number and one of: seamless, grey/flat band at the bottom, lighter strip at the top, both, plus "Copy numbers" for the ones that look different.?v=15first (my prediction)?v=10?v=11?v=9(today's app: you should see the grey band; if not, the lab is not showing your case and we need to know)?v=3,?v=2(doesviewport-fitmatter?)?v=4,?v=5(bottom strip only; solid vs blurred)?v=14,?v=13(top strip: does the lighter band go away with no live blur / oversized sky?)?v=8,?v=1,?v=12?v=6,?v=7(doestheme-colordo anything at all?)&root=redon?v=3,?v=13,?v=14,?v=15: is there red at the top or bottom edge of the glass??v=15(then?v=9), Share, Add to Home Screen, open the icon, check top and bottom, and "Copy numbers" (we wantinnerHeightvsscreenthere).Prediction
Variant 15 wins; 10 is the fallback; 9 shows the band.
#d0d5d9, the band's measured colour): a viewport-sized fixed backdrop with a transparentbackground-color, a floating bottom bar that is not at the edge, and a body that never scrolls (WebKit source, Bell, item 6 and the gradient pitfall).backdrop-filterelement as a mix of colours, per the source).visualViewportand thefixed top/bottom 0box height), or if 14 fixes the top but 15 does not (then the ramp blur is hurting).Simulator (iPhone 18 Pro, iOS 27.0, Safari tab, light)
Honest limits: the simulator is shared, and another session kept bringing its own app to the front, so I only got clean, verified-visible screenshots of 15 (top and end) and 10 (top) within a reasonable time. 15 and 10 came out seamless at both edges: the left-gutter colour is
#a8c8f1from 8 pt down to the clock and#a7c7f0at the bottom, no step above 3 (a 16-level step in 10 at 719 pt is the card's own edge, not a bar). Numbers it printed: screen 402x874,innerHeight714,dvh/svh714,lvh/vh754,fixed top/bottom 0box 714,visualViewport714 with offsetTop 0, allenv(safe-area-inset-*)0 in a Safari tab (matches WebKit bug 306465: no top/bottom insets forviewport-fit=coverin portrait). The other variants were not captured; the phone numbers are what we need anyway.Where the simulator may differ from your phone: (1) kayg's own report is the proof that it does: the same page showed no bottom band there and a flat grey band on the phone; (2) the status-bar and toolbar compositing and the floating toolbar's material are drawn by the system UI, which the simulator may not reproduce; (3) the simulator's
innerHeightheld at 714 for the whole run, while on a Home Screen app a phone can report it short after launch (WebKit 301994); the lab's "seen min..max" would show that; (4) Joe Bell recorded a page that looked seamless in the simulator and was worse on an iPhone 17 / iOS 27.0.1 (ios-26-notes). Screenshots: not attached (kept in the harness scratch folder).Root cause, as I would write it (the app, not Safari)
Per the harness work: the phone list and sidebar screens are full-bleed live-blur sheets touching both screen edges, with a second blur layer under the status bar. With a live
backdrop-filterat the screen edge, WebKit has nothing above the edge to blur, so it mixes in the root colour, and the top of the glass goes flat; and the fixed elements at the edges are the ones Safari samples, so abackdrop-filterthere is reported as a mix of colours instead of the sky colour. I did not verify this myself: the web research found the spec's "nothing above the root" and the source'sbackdrop-filterrule, but no WebKit write-up of the edge bleed; variants 13/14/15 with&root=redtest it on the phone.Next (after your numbers)
Apply the winning rule to the app and all mockups, with an e2e guard (per the plan in the description). Nothing in the app changes until you say.
kayg tested the lab on a real iPhone (iOS 27 Safari):
Apply this combination to the app (#445) and to all mockups (chrome.html).
Closing during the 26 Oct handover cleanup: The safe-area research and lab are done. Kayg's chosen variants landed in dev (PRs #521, #528).