From 1956a7627851e911601921a82e2e1e62fee5bcc5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A5=9E=E6=A5=BD=E5=9D=82=20=E7=99=BD?= Date: Tue, 14 Nov 2023 01:23:57 +0000 Subject: [PATCH] mail view height --- resources/views/welcome.blade.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/resources/views/welcome.blade.php b/resources/views/welcome.blade.php index e317b48..7707e99 100644 --- a/resources/views/welcome.blade.php +++ b/resources/views/welcome.blade.php @@ -395,6 +395,15 @@ function fetchMail() { $('#exampleModalLabel').text(text); // 显示模态框 $('#myModal').modal('show'); + var iframeHeight = $('#modalIframe').contents().find("html").height(); + console.log("Iframe的实际高度是: " + iframeHeight + "px"); + if (iframeHeight >= 600){ + $('#modalIframe').css('height',600); + } else { + $('#modalIframe').css('height',iframeHeight); + } + + } catch (e) { console.error('Error parsing API response or decoding base64:', e); }