fix: Fixed issue with UI sometimes getting shifted up on iOS

This commit is contained in:
Antonella Sgarlatta
2025-06-24 03:53:36 -03:00
committed by GitHub
parent 5f61500ee0
commit c050a2cd33
5 changed files with 10 additions and 30 deletions

View File

@@ -361,12 +361,6 @@ export class WebApplication extends SNApplication implements WebApplicationInter
setCustomViewportHeight(100, 'vh', true)
}
handleUpdateSafeAreaInsets(insets: { top: number; bottom: number; left: number; right: number }) {
for (const [key, value] of Object.entries(insets)) {
document.documentElement.style.setProperty(`--safe-area-inset-${key}`, `${value}px`)
}
}
handleOpenFilePreviewEvent({ id }: { id: string }): void {
const file = this.items.findItem<FileItem>(id)
if (!file) {

View File

@@ -81,11 +81,6 @@ export class MobileWebReceiver {
case ReactNativeToWebEvent.KeyboardDidHide:
void this.application.handleMobileKeyboardDidHideEvent()
break
case ReactNativeToWebEvent.UpdateSafeAreaInsets:
void this.application.handleUpdateSafeAreaInsets(
messageData as { top: number; left: number; bottom: number; right: number },
)
break
case ReactNativeToWebEvent.ReceivedFile:
void this.application.handleReceivedFileEvent(
messageData as {