@moku-labs/native 0.3.15 → 0.3.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1078,9 +1078,11 @@ const IOS_MANAGER_IMPORT = ["#[cfg(target_os = \"ios\")]", "use tauri::Manager;"
1078
1078
  * The safe-area setup hook up to the end of the iOS closure, as verified on the iOS 26.3
1079
1079
  * simulator. UIKit shrinks a WKWebView page by the safe area while its scroll view stays on
1080
1080
  * `.automatic`; `.never` gives the page the whole screen, and CSS `env(safe-area-inset-*)`
1081
- * still reports the notch. The `cfg` makes it a no-op off iOS, so `lib.rs` does not differ
1082
- * per target. The window is tauri's default `main` label: the generated `app.windows` entry
1083
- * carries none.
1081
+ * still reports the notch. iOS 26 also draws a scroll edge effect under the status bar, which
1082
+ * Reduce Transparency turns into an opaque band in the page colour (seen on an iPhone 13 mini
1083
+ * and on the iOS 27 simulator), so the hook hides the four edge effects. The `cfg` makes it a
1084
+ * no-op off iOS, so `lib.rs` does not differ per target. The window is tauri's default `main`
1085
+ * label: the generated `app.windows` entry carries none.
1084
1086
  */
1085
1087
  const SAFE_AREA_SETUP = [
1086
1088
  " .setup(|_app| {",
@@ -1089,9 +1091,19 @@ const SAFE_AREA_SETUP = [
1089
1091
  " #[cfg(target_os = \"ios\")]",
1090
1092
  " if let Some(window) = _app.get_webview_window(\"main\") {",
1091
1093
  " window.with_webview(|webview| unsafe {",
1092
- " use objc2::{msg_send, runtime::AnyObject};",
1094
+ " use objc2::{msg_send, runtime::AnyObject, sel};",
1093
1095
  " let wk = &*(webview.inner() as *mut AnyObject);",
1094
1096
  " let scroll: *mut AnyObject = msg_send![wk, scrollView];",
1097
+ " // iOS 26 draws a scroll edge effect under the status bar and the home indicator. With",
1098
+ " // Reduce Transparency it is an opaque band in the page colour over the game, so it is",
1099
+ " // hidden: the page never scrolls. Older iOS has no such selector and is left alone.",
1100
+ " for name in [sel!(topEdgeEffect), sel!(leftEdgeEffect), sel!(bottomEdgeEffect), sel!(rightEdgeEffect)] {",
1101
+ " let has: bool = msg_send![&*scroll, respondsToSelector: name];",
1102
+ " if has {",
1103
+ " let effect: *mut AnyObject = msg_send![&*scroll, performSelector: name];",
1104
+ " let _: () = msg_send![&*effect, setHidden: true];",
1105
+ " }",
1106
+ " }",
1095
1107
  " // UIScrollViewContentInsetAdjustmentNever = 2",
1096
1108
  " let _: () = msg_send![&*scroll, setContentInsetAdjustmentBehavior: 2isize];"
1097
1109
  ];
package/dist/index.mjs CHANGED
@@ -1051,9 +1051,11 @@ const IOS_MANAGER_IMPORT = ["#[cfg(target_os = \"ios\")]", "use tauri::Manager;"
1051
1051
  * The safe-area setup hook up to the end of the iOS closure, as verified on the iOS 26.3
1052
1052
  * simulator. UIKit shrinks a WKWebView page by the safe area while its scroll view stays on
1053
1053
  * `.automatic`; `.never` gives the page the whole screen, and CSS `env(safe-area-inset-*)`
1054
- * still reports the notch. The `cfg` makes it a no-op off iOS, so `lib.rs` does not differ
1055
- * per target. The window is tauri's default `main` label: the generated `app.windows` entry
1056
- * carries none.
1054
+ * still reports the notch. iOS 26 also draws a scroll edge effect under the status bar, which
1055
+ * Reduce Transparency turns into an opaque band in the page colour (seen on an iPhone 13 mini
1056
+ * and on the iOS 27 simulator), so the hook hides the four edge effects. The `cfg` makes it a
1057
+ * no-op off iOS, so `lib.rs` does not differ per target. The window is tauri's default `main`
1058
+ * label: the generated `app.windows` entry carries none.
1057
1059
  */
1058
1060
  const SAFE_AREA_SETUP = [
1059
1061
  " .setup(|_app| {",
@@ -1062,9 +1064,19 @@ const SAFE_AREA_SETUP = [
1062
1064
  " #[cfg(target_os = \"ios\")]",
1063
1065
  " if let Some(window) = _app.get_webview_window(\"main\") {",
1064
1066
  " window.with_webview(|webview| unsafe {",
1065
- " use objc2::{msg_send, runtime::AnyObject};",
1067
+ " use objc2::{msg_send, runtime::AnyObject, sel};",
1066
1068
  " let wk = &*(webview.inner() as *mut AnyObject);",
1067
1069
  " let scroll: *mut AnyObject = msg_send![wk, scrollView];",
1070
+ " // iOS 26 draws a scroll edge effect under the status bar and the home indicator. With",
1071
+ " // Reduce Transparency it is an opaque band in the page colour over the game, so it is",
1072
+ " // hidden: the page never scrolls. Older iOS has no such selector and is left alone.",
1073
+ " for name in [sel!(topEdgeEffect), sel!(leftEdgeEffect), sel!(bottomEdgeEffect), sel!(rightEdgeEffect)] {",
1074
+ " let has: bool = msg_send![&*scroll, respondsToSelector: name];",
1075
+ " if has {",
1076
+ " let effect: *mut AnyObject = msg_send![&*scroll, performSelector: name];",
1077
+ " let _: () = msg_send![&*effect, setHidden: true];",
1078
+ " }",
1079
+ " }",
1068
1080
  " // UIScrollViewContentInsetAdjustmentNever = 2",
1069
1081
  " let _: () = msg_send![&*scroll, setContentInsetAdjustmentBehavior: 2isize];"
1070
1082
  ];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moku-labs/native",
3
- "version": "0.3.15",
3
+ "version": "0.3.16",
4
4
  "description": "Node-only native packager framework for Moku — generates a gitignored Tauri project, codegens capabilities/Info.plist/AndroidManifest from composed system plugins, and runs tauri build.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -66,8 +66,8 @@
66
66
  "@arethetypeswrong/cli": "0.18.3",
67
67
  "@arethetypeswrong/core": "0.18.3",
68
68
  "@biomejs/biome": "2.4.16",
69
- "@moku-labs/ci": "1.5.7",
70
- "@moku-labs/common": "0.3.10",
69
+ "@moku-labs/ci": "1.5.8",
70
+ "@moku-labs/common": "0.3.12",
71
71
  "@moku-labs/core": "1.7.6",
72
72
  "@types/bun": "1.4.2",
73
73
  "@vitest/coverage-istanbul": "4.0.18",