Skip to content

Commit 638fd29

Browse files
committed
Hide balance when no target defined
+ style adjustments
1 parent 8fbdb7c commit 638fd29

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/assets/css/app.css

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
.f-row { @apply flex flex-row; }
66

77
hr {
8-
@apply border w-full my-6;
8+
@apply border w-full my-5;
99
}
1010

1111
/* Buttons */

src/views/Calc.vue

+4-4
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<label class="col-start">Target</label>
66
<div class="col-end">
77
<input type="number" min="0" step="0.01" autofocus
8-
v-model.number="target" @change="targetChanged()"/>
8+
v-model.number.lazy="target" @change="targetChanged()"/>
99
</div>
1010
</div>
1111

@@ -46,7 +46,7 @@
4646
<span class="input-value result-value">{{ ticketTotal | fixed2 }}</span>
4747
</div>
4848
</div>
49-
<div class="f-row my-2">
49+
<div class="f-row my-2" :class="{invisible: !target}">
5050
<span class="col-start">
5151
{{ balanceLabel }}
5252
</span>
@@ -58,9 +58,9 @@
5858
</div>
5959
</div>
6060

61-
<div class="flex justify-end my-8">
61+
<div class="flex justify-end mt-4">
6262
<div class="col-end">
63-
<button class="btn btn-primary mr-2" type="button"
63+
<button class="btn btn-primary" type="button"
6464
@click="reset()"
6565
:disabled="this.target === null && this.ticketTotal === 0">
6666
Clear

0 commit comments

Comments
 (0)