Shrink & center form section titles

This commit is contained in:
jeremystretch 2021-07-22 12:31:50 -04:00
parent 7bfc66e218
commit 84479925bf
13 changed files with 40 additions and 40 deletions

View File

@ -12,7 +12,7 @@
<div class="row">
<div class="col col-md-8 offset-md-2 col-lg-6 offset-lg-3">
<div class="field-group">
<h4>{{ component_type|title }}</h4>
<h5 class="text-center">{{ component_type|title }}</h5>
{% for field in form.hidden_fields %}
{{ field }}
{% endfor %}
@ -23,7 +23,7 @@
{% endfor %}
{% if form.custom_fields %}
<div class="field-group">
<h4>Custom Fields</h4>
<h5 class="text-center">Custom Fields</h5>
{% render_custom_fields form %}
</div>
{% endif %}

View File

@ -5,14 +5,14 @@
{% render_errors form %}
<div class="field-group">
<h4>Device</h4>
<h5 class="text-center">Device</h5>
{% render_field form.name %}
{% render_field form.device_role %}
{% render_field form.tags %}
</div>
<div class="field-group">
<h4>Hardware</h4>
<h5 class="text-center">Hardware</h5>
{% render_field form.manufacturer %}
{% render_field form.device_type %}
{% render_field form.serial %}
@ -20,7 +20,7 @@
</div>
<div class="field-group">
<h4>Location</h4>
<h5 class="text-center">Location</h5>
{% render_field form.region %}
{% render_field form.site_group %}
{% render_field form.site %}
@ -52,7 +52,7 @@
</div>
<div class="field-group">
<h4>Management</h4>
<h5 class="text-center">Management</h5>
{% render_field form.status %}
{% render_field form.platform %}
{% if obj.pk %}
@ -62,31 +62,31 @@
</div>
<div class="field-group">
<h4>Virtualization</h4>
<h5 class="text-center">Virtualization</h5>
{% render_field form.cluster_group %}
{% render_field form.cluster %}
</div>
<div class="field-group">
<h4>Tenancy</h4>
<h5 class="text-center">Tenancy</h5>
{% render_field form.tenant_group %}
{% render_field form.tenant %}
</div>
{% if form.custom_fields %}
<div class="field-group">
<h4>Custom Fields</h4>
<h5 class="text-center">Custom Fields</h5>
{% render_custom_fields form %}
</div>
{% endif %}
<div class="field-group">
<h4>Local Config Context Data</h4>
<h5 class="text-center">Local Config Context Data</h5>
{% render_field form.local_context_data %}
</div>
<div class="field-group">
<h4>Comments</h4>
<h5 class="text-center">Comments</h5>
{% render_field form.comments %}
</div>

View File

@ -11,7 +11,7 @@
<div class="row">
<div class="col col-md-6">
<div class="field-group mb-3">
<h4>New {{ component_type }}</h4>
<h5 class="text-center">New {{ component_type }}</h5>
<div class="row mb-3">
<label class="col-sm-3 col-form-label">Device Type</label>
<div class="col">

View File

@ -3,7 +3,7 @@
{% block form %}
<div class="field-group">
<h4>Rack</h4>
<h5 class="text-center">Rack</h5>
{% render_field form.region %}
{% render_field form.site_group %}
{% render_field form.site %}
@ -14,18 +14,18 @@
{% render_field form.tags %}
</div>
<div class="field-group">
<h4>Inventory Control</h4>
<h5 class="text-center">Inventory Control</h5>
{% render_field form.facility_id %}
{% render_field form.serial %}
{% render_field form.asset_tag %}
</div>
<div class="field-group">
<h4>Tenancy</h4>
<h5 class="text-center">Tenancy</h5>
{% render_field form.tenant_group %}
{% render_field form.tenant %}
</div>
<div class="field-group">
<h4>Dimensions</h4>
<h5 class="text-center">Dimensions</h5>
{% render_field form.type %}
{% render_field form.width %}
{% render_field form.u_height %}
@ -48,12 +48,12 @@
</div>
{% if form.custom_fields %}
<div class="field-group">
<h4>Custom Fields</h4>
<h5 class="text-center">Custom Fields</h5>
{% render_custom_fields form %}
</div>
{% endif %}
<div class="field-group">
<h4>Comments</h4>
<h5 class="text-center">Comments</h5>
{% render_field form.comments %}
</div>
{% endblock %}

View File

@ -30,7 +30,7 @@
{# Render grouped fields according to Form #}
{% for group, fields in form.Meta.fieldsets %}
<div class="field-group">
<h4>{{ group }}</h4>
<h5 class="text-center">{{ group }}</h5>
{% for name in fields %}
{% render_field form|getfield:name %}
{% endfor %}
@ -39,14 +39,14 @@
{% if form.custom_fields %}
<div class="field-group">
<h4>Custom Fields</h4>
<h5 class="text-center">Custom Fields</h5>
{% render_custom_fields form %}
</div>
{% endif %}
{% if form.comments %}
<div class="field-group">
<h4>Comments</h4>
<h5 class="text-center">Comments</h5>
{% render_field form.comments %}
</div>
{% endif %}
@ -54,7 +54,7 @@
{% else %}
{# Render all fields in a single group #}
<div class="field-group">
<h4>{{ obj_type|capfirst }}</h4>
<h5 class="text-center">{{ obj_type|capfirst }}</h5>
{% block form_fields %}{% render_form form %}{% endblock %}
</div>
{% endif %}

View File

@ -7,7 +7,7 @@
{% block form %}
{% include 'ipam/inc/ipadress_edit_header.html' with active_tab='bulk_add' %}
<div class="field-group">
<h4>IP Addresses</h4>
<h5 class="text-center">IP Addresses</h5>
{% render_field form.pattern %}
{% render_field model_form.status %}
{% render_field model_form.role %}
@ -16,13 +16,13 @@
{% render_field model_form.tags %}
</div>
<div class="field-group">
<h4>Tenancy</h4>
<h5 class="text-center">Tenancy</h5>
{% render_field model_form.tenant_group %}
{% render_field model_form.tenant %}
</div>
{% if model_form.custom_fields %}
<div class="field-group">
<h4>Custom Fields</h4>
<h5 class="text-center">Custom Fields</h5>
{% render_custom_fields model_form %}
</div>
{% endif %}

View File

@ -3,7 +3,7 @@
{% block form %}
<div class="field-group">
<h4>Service</h4>
<h5 class="text-center">Service</h5>
{% if obj.device %}
<div class="row mb-3">
<label class="col-sm-3 col-form-label text-end">Device</label>

View File

@ -5,7 +5,7 @@
{% block form %}
<div class="field-group mb-3">
<h4>VLAN</h4>
<h5 class="text-center">VLAN</h5>
{% render_field form.vid %}
{% render_field form.name %}
{% render_field form.status %}
@ -14,12 +14,12 @@
{% render_field form.tags %}
</div>
<div class="field-group mb-3">
<h4>Tenancy</h4>
<h5 class="text-center">Tenancy</h5>
{% render_field form.tenant_group %}
{% render_field form.tenant %}
</div>
<div class="field-group mb-3">
<h4>Assignment</h4>
<h5 class="text-center">Assignment</h5>
{% with site_tab_active=form.initial.site %}
<ul class="nav nav-tabs" role="tablist">
<li class="nav-item" role="presentation">
@ -44,7 +44,7 @@
</div>
{% if form.custom_fields %}
<div class="field-group">
<h4>Custom Fields</h4>
<h5 class="text-center">Custom Fields</h5>
{% render_custom_fields form %}
</div>
{% endif %}

View File

@ -4,13 +4,13 @@
{% block form %}
<div class="field-group">
<h4>VLAN Group</h4>
<h5 class="text-center">VLAN Group</h5>
{% render_field form.name %}
{% render_field form.slug %}
{% render_field form.description %}
</div>
<div class="field-group">
<h4>Scope</h4>
<h5 class="text-center">Scope</h5>
{% render_field form.scope_type %}
{% render_field form.region %}
{% render_field form.sitegroup %}
@ -22,7 +22,7 @@
</div>
{% if form.custom_fields %}
<div class="field-group">
<h4>Custom Fields</h4>
<h5 class="text-center">Custom Fields</h5>
{% render_custom_fields form %}
</div>
{% endif %}

View File

@ -9,7 +9,7 @@
<form action="." method="post" class="form form-horizontal col-md-10 col-md-offset-1">
{% csrf_token %}
<div class="field-group">
<h4>Password</h4>
<h5 class="text-center">Password</h5>
{% render_field form.old_password %}
{% render_field form.new_password1 %}
{% render_field form.new_password2 %}

View File

@ -7,7 +7,7 @@
<form method="post" action="" id="preferences-update">
{% csrf_token %}
<div class="field-group mb-3">
<h4>Color Mode</h4>
<h5 class="text-center">Color Mode</h5>
<p class="lead text-muted">Set preferred UI color mode</p>
{% with color_mode=preferences|get_key:'ui.colormode'%}
<div class="form-check form-check-inline">
@ -29,7 +29,7 @@
</div>
{% if preferences %}
<div class="field-group mb-3">
<h4>Other Preferences</h4>
<h5 class="text-center">Other Preferences</h5>
<table class="table table-striped">
<thead>
<tr>

View File

@ -15,7 +15,7 @@
<div class="row">
<div class="col col-md-6 offset-md-3">
<div class="field-group">
<h4>Device Selection</h4>
<h5 class="text-center">Device Selection</h5>
{% render_form form %}
</div>
</div>

View File

@ -3,7 +3,7 @@
{% block form %}
<div class="field-group">
<h4>Interface</h4>
<h5 class="text-center">Interface</h5>
{% if form.instance.virtual_machine %}
<div class="row mb-3">
<label class="col-sm-3 col-form-label required" for="id_device">Virtual Machine</label>
@ -22,14 +22,14 @@
</div>
<div class="field-group">
<h4>802.1Q Switching</h4>
<h5 class="text-center">802.1Q Switching</h5>
{% render_field form.mode %}
{% render_field form.untagged_vlan %}
{% render_field form.tagged_vlans %}
</div>
{% if form.custom_fields %}
<div class="field-group">
<h4>Custom Fields</h4>
<h5 class="text-center">Custom Fields</h5>
{% render_custom_fields form %}
</div>
{% endif %}