diff --git a/archivebox/templates/core/snapshot.html b/archivebox/templates/core/snapshot.html index a982a792..2632fc16 100644 --- a/archivebox/templates/core/snapshot.html +++ b/archivebox/templates/core/snapshot.html @@ -833,11 +833,12 @@ } #main-frame-wrapper { width: 100%; - height: calc(100vh - 210px); + height: auto; border-top: 3px solid #aa1e55; overflow: hidden; order: 2; - flex: 0 0 auto; + flex: 1 1 auto; + min-height: 0; display: flex; flex-direction: column; } @@ -857,7 +858,7 @@ } .full-page-wrapper { width: 100%; - height: calc(100vh - 210px); + min-height: 0; } .snapshot-empty-state { display: flex; @@ -1027,9 +1028,6 @@ height: 32px; max-height: 32px; } - #main-frame-wrapper.iframe-large { - height: calc(100vh - 70px); - } .preview-hidden { display: none !important; } @@ -2094,7 +2092,6 @@ console.log('Collapsing Snapshot header...') jQuery('.header-toggle').text('▸') jQuery('.header-bottom').hide() - jQuery('#main-frame-wrapper').addClass('iframe-large') try { localStorage.setItem("archivebox-snapshot-header-visible", "false") } catch (e) { @@ -2105,7 +2102,6 @@ console.log('Expanding Snapshot header...') jQuery('.header-toggle').text('▾') jQuery('.header-bottom').show() - jQuery('#main-frame-wrapper').removeClass('iframe-large') try { localStorage.setItem("archivebox-snapshot-header-visible", "true") } catch (e) { diff --git a/archivebox/tests/test_ui_admin_snapshot.py b/archivebox/tests/test_ui_admin_snapshot.py index 3d0dcde2..442afbea 100644 --- a/archivebox/tests/test_ui_admin_snapshot.py +++ b/archivebox/tests/test_ui_admin_snapshot.py @@ -694,9 +694,8 @@ class TestSnapshotProgressStats: assert "full-page-iframe" in rendered assert "index.jsonl?preview=1" in rendered - assert "#main-frame-wrapper.iframe-large" in rendered - assert "jQuery('#main-frame-wrapper').addClass('iframe-large')" in rendered - assert "jQuery('#main-frame-wrapper').removeClass('iframe-large')" in rendered + assert "height: calc(100vh - 210px)" not in rendered + assert "iframe-large" not in rendered class TestAdminSnapshotListView: