Improve action buttons for part display

This commit is contained in:
Oliver Walters 2020-09-13 20:42:59 +10:00
parent eaf87294ce
commit 04c702e1b8
2 changed files with 13 additions and 5 deletions

View File

@ -413,6 +413,10 @@
font-size: 125%; font-size: 125%;
} }
.btn-group {
padding-bottom: 5px;
}
.action-buttons .btn { .action-buttons .btn {
font-size: 175%; font-size: 175%;
align-content: center; align-content: center;
@ -474,6 +478,7 @@
.media { .media {
padding-top: 15px; padding-top: 15px;
overflow: visible;
} }
.media-body { .media-body {

View File

@ -35,16 +35,18 @@
{% endif %} {% endif %}
</h3> </h3>
<p><i>{{ part.description }}</i></p> <p><i>{{ part.description }}</i></p>
<div class='btn-group action-buttons' role='group'> <div class='btn-group action-buttons' role='group'>
<button type='button' class='btn btn-default' id='toggle-starred' title='{% trans "Star this part" %}'> <button type='button' class='btn btn-default' id='toggle-starred' title='{% trans "Star this part" %}'>
<span id='part-star-icon' class='fas fa-star {% if starred %}icon-yellow{% endif %}'/> <span id='part-star-icon' class='fas fa-star {% if starred %}icon-yellow{% endif %}'/>
</button> </button>
<!-- Barcode actions menu --> <!-- Barcode actions menu -->
<div class='dropdown dropdown-buttons'> <div class='btn-group'>
<button id='barcode-options' title='{% trans "Barcode actions" %}' class='btn btn-default dropdown-toggle' type='button' data-toggle='dropdown'><span class='fas fa-qrcode'></span> <span class='caret'></span></button> <button id='barcode-options' title='{% trans "Barcode actions" %}' class='btn btn-default dropdown-toggle' type='button' data-toggle='dropdown'><span class='fas fa-qrcode'></span> <span class='caret'></span></button>
<ul class='dropdown-menu' role='menu'> <ul class='dropdown-menu'>
<li><a href='#' id='show-qr-code'><span class='fas fa-qrcode'></span> {% trans "Show QR Code" %}</a></li> <li><a href='#' id='show-qr-code'><span class='fas fa-qrcode'></span> {% trans "Show QR Code" %}</a></li>
<li class='disabled'><a href='#' id='print-label'><span class='fas fa-tag'></span> {% trans "Print Label" %}</a></li> <li><a href='#' id='print-label'><span class='fas fa-tag'></span> {% trans "Print Label" %}</a></li>
</ul> </ul>
</div> </div>
{% if part.active %} {% if part.active %}
@ -60,9 +62,10 @@
</button> </button>
{% endif %} {% endif %}
{% endif %} {% endif %}
<div class='dropdown dropdown-buttons'> <!-- Part actions -->
<div class='btn-group'>
<button id='part-actions' title='{% trans "Part actions" %}' class='btn btn-default dropdown-toggle' type='button' data-toggle='dropdown'> <span class='fas fa-shapes'></span> <span class='caret'></span></button> <button id='part-actions' title='{% trans "Part actions" %}' class='btn btn-default dropdown-toggle' type='button' data-toggle='dropdown'> <span class='fas fa-shapes'></span> <span class='caret'></span></button>
<ul class='dropdown-menu' role='menu'> <ul class='dropdown-menu'>
<li><a href='#' id='part-duplicate'><span class='fas fa-copy'></span> {% trans "Duplicate part" %}</a></li> <li><a href='#' id='part-duplicate'><span class='fas fa-copy'></span> {% trans "Duplicate part" %}</a></li>
<li><a href='#' id='part-edit'><span class='fas fa-edit icon-blue'></span> {% trans "Edit part" %}</a></li> <li><a href='#' id='part-edit'><span class='fas fa-edit icon-blue'></span> {% trans "Edit part" %}</a></li>
{% if not part.active %} {% if not part.active %}