Compact product row of quotes and invoices

Not by much, but it looks a bit more like “invoice rows” rather than
a bunch of scattered forms.

Part of #57.
This commit is contained in:
jordi fita mas 2024-09-10 12:41:35 +02:00
parent ce4d29b83b
commit 4ae9fc5cfa
2 changed files with 25 additions and 12 deletions

View File

@ -594,30 +594,43 @@ main > nav {
/* Invoice */ /* Invoice */
.new-quote-product:not(.radio),
.new-invoice-product:not(.radio) {
display: grid;
grid-template-columns: 1fr 16ch 16ch 16ch 25ch;
position: relative;
margin-bottom: 2rem;
padding-top: 3rem;
}
.new-quote-product input, .new-quote-product input,
.new-invoice-product input { .new-invoice-product input {
width: 100%; width: 100%;
} }
.new-quote-product, .new-quote-product .input,
.new-invoice-product { .new-invoice-product .input {
display: grid; margin: 0;
grid-template-columns: repeat(4, 1fr); }
position: relative;
.new-quote-product + .new-quote-product,
.new-invoice-product + .new-invoice-product {
margin-top: 0;
} }
.new-quote-product .delete-product, .new-quote-product .delete-product,
.new-invoice-product .delete-product { .new-invoice-product .delete-product {
position: absolute; position: absolute;
right: 0; right: 0;
top: .75rem; top: 0;
padding: .5rem;
} }
.new-quote-product .input:nth-of-type(5), .new-quote-product .input:nth-of-type(6),
.new-invoice-product .input:nth-of-type(5) { .new-invoice-product .input:nth-of-type(6) {
grid-column-start: 1; grid-column-start: 1;
grid-column-end: 4; grid-column-end: 6;
margin-top: -.5em;
} }
.new-quote-product textarea, .new-quote-product textarea,

View File

@ -168,8 +168,8 @@
{{ template "input-field" .Price }} {{ template "input-field" .Price }}
{{ template "input-field" .Quantity }} {{ template "input-field" .Quantity }}
{{ template "input-field" .Discount }} {{ template "input-field" .Discount }}
{{ template "input-field" .Description | addInputAttr `rows="1"`}}
{{ template "select-field" .Tax }} {{ template "select-field" .Tax }}
{{ template "input-field" .Description | addInputAttr `rows="2"`}}
</fieldset> </fieldset>
{{- end }} {{- end }}
@ -191,8 +191,8 @@
{{ template "input-field" .Price }} {{ template "input-field" .Price }}
{{ template "input-field" .Quantity }} {{ template "input-field" .Quantity }}
{{ template "input-field" .Discount }} {{ template "input-field" .Discount }}
{{ template "input-field" .Description | addInputAttr `rows="1"`}}
{{ template "select-field" .Tax }} {{ template "select-field" .Tax }}
{{ template "input-field" .Description | addInputAttr `rows="2"`}}
</fieldset> </fieldset>
{{- end }} {{- end }}