Skip to content

A fast 2D and 3D game engine — TypeScript SDK, C++/WebAssembly core, visual editor. Ship one project to web, desktop, WeChat MiniGames, playable ads, and native Android / iOS.

fix(samples): keep virtualized UI inside device safe areas

yhh556d47a1d461
diff --git a/CHANGELOG.md b/CHANGELOG.md
index db900365d..954ad2d59 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -22,7 +22,7 @@ published separately; it ships inside the editor.
### Fixed
-- **Native UI follows the device safe area.** iOS view insets and Android content bounds reach `SafeArea` in surface pixels, including delayed layouts and landscape side changes. The localization sample places its text and controls inside an authored safe-area container so the iPhone cutout does not cover the paragraph.
+- **Native UI follows the device safe area.** iOS view insets and Android content bounds reach `SafeArea` in surface pixels, including delayed layouts and landscape side changes. The localization and virtualized-list samples place their text and controls inside authored safe-area containers so the iPhone cutout does not cover paragraphs or list rows.
- **The installed macOS MCP entry launches the bundled editor.** It reads `CFBundleExecutable` from the app's Info.plist instead of assuming the product name matches the executable file.
diff --git a/examples/ui-list/README.md b/examples/ui-list/README.md
index 51a61b917..a89a2dc6d 100644
--- a/examples/ui-list/README.md
+++ b/examples/ui-list/README.md
@@ -40,3 +40,7 @@ source holds.
The scene authors the static frame (panel, headers, empty slots); the startup
system finds the named slots and instantiates the widgets — the same
scene-plus-factories split as the `ui-controls` example.
+
+The panel sits under an absolute `SafeArea` content container. Device cutouts
+move the whole interactive list and its controls together; the panel keeps its
+authored margins inside that container.
diff --git a/examples/ui-list/assets/scenes/main.esscene b/examples/ui-list/assets/scenes/main.esscene
index bc8564b5a..03e414954 100644
--- a/examples/ui-list/assets/scenes/main.esscene
+++ b/examples/ui-list/assets/scenes/main.esscene
@@ -30,7 +30,7 @@
"id": 1,
"name": "Canvas",
"parent": null,
- "children": [2],
+ "children": [13],
"components": [
{ "type": "Transform", "data": {} },
{
@@ -47,7 +47,7 @@
{
"id": 2,
"name": "Panel",
- "parent": 1,
+ "parent": 13,
"children": [3, 4, 11, 12],
"components": [
{ "type": "Transform", "data": {} },
@@ -310,6 +310,18 @@
}
],
"visible": true
+ },
+ {
+ "id": 13,
+ "name": "Safe Content",
+ "parent": 1,
+ "children": [2],
+ "components": [
+ { "type": "Transform", "data": {} },
+ { "type": "UINode", "data": { "position": 1 } },
+ { "type": "SafeArea", "data": {} }
+ ],
+ "visible": true
}
]
}
diff --git a/tools/releaseNotes.mjs b/tools/releaseNotes.mjs
index ca26acbeb..2e9cc73b1 100644
--- a/tools/releaseNotes.mjs
+++ b/tools/releaseNotes.mjs
@@ -28,6 +28,8 @@ export const NOTES_FLOOR = 'v0.65.0';
* the reader recognises anyway.
*/
export const NOTED = {
+ 'fix(samples): keep virtualized UI inside device safe areas':
+ { note: 'Native UI follows the device safe area.' },
'fix(verification): read renderer counters after a completed frame':
{ internal: 'Packaged-game acceptance waits for actual render frames before reading counters and separates Windows Electron app arguments; shipping engine and editor behavior are unchanged.' },
'fix(native): keep authored UI inside live device safe areas':