From 010d0738918a91ea96c3e3cc79cde7b05b29b0cd Mon Sep 17 00:00:00 2001 From: na-trium-144 <100704180+na-trium-144@users.noreply.github.com> Date: Thu, 19 Mar 2026 00:20:32 +0900 Subject: [PATCH] =?UTF-8?q?iOS=E3=81=A7=E3=81=AFworker=E5=AE=9F=E8=A1=8C?= =?UTF-8?q?=E7=92=B0=E5=A2=83=E8=AA=AD=E3=81=BF=E8=BE=BC=E3=81=BF=E6=99=82?= =?UTF-8?q?=E3=81=ABalert=E3=82=92=E5=87=BA=E3=81=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/runtime/src/worker/runtime.tsx | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/packages/runtime/src/worker/runtime.tsx b/packages/runtime/src/worker/runtime.tsx index 1943ade..386ba54 100644 --- a/packages/runtime/src/worker/runtime.tsx +++ b/packages/runtime/src/worker/runtime.tsx @@ -129,6 +129,11 @@ export function WorkerProvider({ await initializeWorker(); setReady(true); }); + if (isIOS()) { + alert( + "iPhone/iPadでは実行環境が正しく動作しない場合があります。PCで利用してください。" + ); + } return () => { void mutex.runExclusive(async () => { // Reject all pending promises @@ -306,3 +311,13 @@ export function WorkerProvider({ ); } + +function isIOS(): boolean { + // Source - https://stackoverflow.com/a/58065241 + // Posted by kikiwora, modified by community. See post 'Timeline' for change history + // Retrieved 2026-03-19, License - CC BY-SA 4.0 + return ( + /iPad|iPhone|iPod/.test(navigator.platform) || + (navigator.platform === "MacIntel" && navigator.maxTouchPoints > 1) + ); +}