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

refactor(templates): Bootstrap utilities instead of the upstream rules that redid them

webvirtcloud.css still carried the upstream panel's rules for what
Bootstrap 5.3 has as utilities and components:
- the page's bottom space (body padding) is pb-5 on base.html's body,
  and the console page no longer has to undo it;
- the VM page's action tabs (.action-button, .action-block with a
  fixed 65px width) are text-center with a d-block icon; its tab panes
  (#power ... #undefine, one rule each) mt-3;
- the bordered sub-tab panes (.tab-pane-bordered, a fixed #eee border
  that dark themes could not change) border border-top-0 p-3;
- the search box and header buttons (.search, .btn-header) m-1 and
  mt-1; the SSH key select (.keyselect) a form-select;
- the boot order list (.multipleselect, fixed size, #c0c0c0 border) a
  list-group of form-check-input items; its unused .multipleselect-on
  goes;
- table cells centred by a global rule are align-middle on each table.
Two rules against Bootstrap's behaviour go: menus opened on hover on
wide screens (Bootstrap opens them on a click, and keyboard and touch
users had no hover), and "a { outline: 0 }", which hid the keyboard
focus ring.

The paragraph and page-header margins and the 900px container stay
for a separate change: they set every page's layout.
This commit is contained in:
catborise 2026-10-27 17:09:52 +03:00
parent c1e30aeb7f
commit faa6e4bb14
32 changed files with 95 additions and 195 deletions

View file

@ -6,7 +6,7 @@
{% block content %}
<div class="row">
<div class="col-lg-12">
<a href="{% url 'admin:group_create' %}" class="btn btn-success btn-header float-end" title="{% trans "Create Group" %}">
<a href="{% url 'admin:group_create' %}" class="btn btn-success mt-1 float-end" title="{% trans "Create Group" %}">
{% bs_icon 'plus-circle-fill' %}
</a>
{% include 'search_block.html' %}
@ -23,7 +23,7 @@
{% else %}
<div class="col-lg-12">
<div class="table-responsive">
<table class="table table-striped table-hover">
<table class="table table-striped table-hover align-middle">
<thead>
<tr>
<th scope="col">{% trans "Group Name" %}</th>

View file

@ -32,7 +32,7 @@
</div>
{% else %}
<div class="table-responsive">
<table class="table table-hover">
<table class="table table-hover align-middle">
<thead>
<tr>
<th scope="col">#</th>

View file

@ -21,7 +21,7 @@
{% else %}
<div class="col-lg-12">
<div class="table-responsive">
<table class="table table-striped table-hover">
<table class="table table-striped table-hover align-middle">
<thead>
<tr>
<th scope="col">{% trans "Name" %}</th>

View file

@ -9,7 +9,7 @@
{% block page_heading %}{{ title }}{% endblock page_heading %}
{% block page_heading_extra %}
<a href="{% url 'admin:user_create' %}" class="btn btn-success btn-header float-end" title="{% trans "Create User" %}">
<a href="{% url 'admin:user_create' %}" class="btn btn-success mt-1 float-end" title="{% trans "Create User" %}">
{% bs_icon 'plus-circle-fill' %}
</a>
{% include 'search_block.html' %}
@ -26,7 +26,7 @@
{% else %}
<div class="col-lg-12">
<div class="table-responsive">
<table class="table table-striped table-hover">
<table class="table table-striped table-hover align-middle">
<thead>
<tr>
<th scope="col">{% trans "Username" %}</th>