1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-11-11 12:46:49 +00:00

refactor(console): the console pages on Bootstrap classes instead of their own style blocks

The console pages carried style blocks for what Bootstrap 5.3 has:
- the page's column (flex, no padding, a #494949 background) is
  d-flex flex-column p-0 bg-dark; its height stays 100dvh inline, as
  vh-100 would run under a phone browser's bar;
- the VNC screen and the serial terminal fill the rest with
  flex-grow-1, the screen overflow-hidden, the terminal bg-black; their
  min-height: 0 stays inline (Bootstrap has no class for it);
- the rule centring the VNC canvas goes: noVNC centres its own canvas
  and draws its own background.
The unused main_container id goes with its style block.
This commit is contained in:
catborise 2026-10-27 19:45:47 +03:00
parent e59870a660
commit 1cb1f8ac6a
3 changed files with 4 additions and 28 deletions

View file

@ -12,32 +12,14 @@
{% with theme=app_settings.BOOTSTRAP_THEME|default:"zephyr" %}<link rel="stylesheet" href="{% static "css/themes/"|add:theme|add:".min.css" %}" id="wvc_css">{% endwith %}
<link href="{% static "css/webvirtcloud.css" %}" rel="stylesheet">
<style>
#main_container {
padding: 0;
width: 100%;
max-width: none;
height: 100dvh;
display: flex;
flex-direction: column;
background-color: #494949;
}
#main_container canvas {
padding-left: 0;
padding-right: 0;
margin-left: auto;
margin-right: auto;
display: block;
}
</style>
{% block head %}{% endblock %}
</head>
<body>
<div id="main_container">
{# the whole window, 100dvh: vh-100 would run under a phone browser's bar #}
<div class="d-flex flex-column p-0 bg-dark" style="height: 100dvh;">
<nav class="navbar navbar-expand-md navbar-dark bg-primary py-1" aria-label="{% trans "Console" %}">
<div class="container-fluid">
<span class="navbar-brand py-0">{{ instance.name }}</span>