Multiplayer agent harness for work.
web-ui: keep the device safe-area under the composer on mid-width surfaces (#491)
Regan Belldf35bbd9348b
diff --git a/plugins/web-ui/src/shell.css b/plugins/web-ui/src/shell.cssindex 6f0eb82a2..08820165b 100644--- a/plugins/web-ui/src/shell.css+++ b/plugins/web-ui/src/shell.css@@ -2288,7 +2288,7 @@ a.chat-row-open {.composer-wrap {position: relative;width: min(var(--content-w), calc(100% - 32px));- margin: 0 auto 18px;+ margin: 0 auto max(18px, calc(10px + env(safe-area-inset-bottom)));padding: 12px;border: 1px solid var(--border);border-radius: 24px;@@ -6946,6 +6946,15 @@ h3.ambient-field-label {.custom-chat-shell {--content-w: 100%;}+ /* Mid-width surfaces: the floating composer/dock hug the full-width column with 16px+ side margins, but must still clear the device safe areas — the 10px variant below+ only kicks in at <=470px, so the insets need a floor here too. */+ .composer-wrap,+ .live-work-dock {+ width: auto;+ margin-right: max(16px, calc(10px + env(safe-area-inset-right)));+ margin-left: max(16px, calc(10px + env(safe-area-inset-left)));+ }}@container chat (max-width: 470px) {.custom-chat-shell {@@ -6954,14 +6963,12 @@ h3.ambient-field-label {/* The floating composer/dock margins pair with the full-bleed 14px chat pad and mustfollow the surface's width too, or a window resize misaligns them with the column. */.composer-wrap {- width: auto;margin-right: calc(10px + env(safe-area-inset-right));margin-bottom: calc(10px + env(safe-area-inset-bottom));margin-left: calc(10px + env(safe-area-inset-left));border-radius: 18px;}.live-work-dock {- width: auto;margin-right: calc(10px + env(safe-area-inset-right));margin-left: calc(10px + env(safe-area-inset-left));}diff --git a/plugins/web-ui/test/responsive-source.test.ts b/plugins/web-ui/test/responsive-source.test.tsindex 837318df3..57528bb01 100644--- a/plugins/web-ui/test/responsive-source.test.ts+++ b/plugins/web-ui/test/responsive-source.test.ts@@ -110,12 +110,17 @@ test("touch layouts expose row actions and preserve readable composer choices",compactCss,/padding: calc\(20px \+ var\(--surface-safe-top\)\) max\(14px, env\(safe-area-inset-right\)\) calc\(32px \+ env\(safe-area-inset-bottom\)\) max\(14px, env\(safe-area-inset-left\)\)/,);+ assert.match(compactCss, /margin: 0 auto max\(18px, calc\(10px \+ env\(safe-area-inset-bottom\)\)\)/);assert.match(compactCss,- /\.composer-wrap \{\s*width: auto;\s*margin-right: calc\(10px \+ env\(safe-area-inset-right\)\);[\s\S]*margin-left: calc\(10px \+ env\(safe-area-inset-left\)\)/,+ /\.composer-wrap,\s*\.live-work-dock \{\s*width: auto;\s*margin-right: max\(16px, calc\(10px \+ env\(safe-area-inset-right\)\)\);\s*margin-left: max\(16px, calc\(10px \+ env\(safe-area-inset-left\)\)\)/,);assert.match(compactCss,- /\.live-work-dock \{\s*width: auto;\s*margin-right: calc\(10px \+ env\(safe-area-inset-right\)\);\s*margin-left: calc\(10px \+ env\(safe-area-inset-left\)\)/,+ /\.composer-wrap \{\s*margin-right: calc\(10px \+ env\(safe-area-inset-right\)\);\s*margin-bottom: calc\(10px \+ env\(safe-area-inset-bottom\)\);\s*margin-left: calc\(10px \+ env\(safe-area-inset-left\)\)/,+ );+ assert.match(+ compactCss,+ /\.live-work-dock \{\s*margin-right: calc\(10px \+ env\(safe-area-inset-right\)\);\s*margin-left: calc\(10px \+ env\(safe-area-inset-left\)\)/,);});