Skip to content

Commit

Permalink
fix: use quasar screen api
Browse files Browse the repository at this point in the history
  • Loading branch information
talvasconcelos committed Nov 26, 2024
1 parent b5f7637 commit c2465a4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions static/js/tpos.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ window.app = Vue.createApp({
},
monochrome: this.$q.localStorage.getItem('lnbits.tpos.color') || false,
showPoS: true,
cartDrawer: this.$q.screen.width > 1200,
cartDrawer: this.$q.screen.gt.md,
searchTerm: '',
categoryFilter: '',
cart: new Map(),
Expand Down Expand Up @@ -180,7 +180,7 @@ window.app = Vue.createApp({
return items
},
drawerWidth() {
return this.$q.screen.width < 500 ? 375 : 450
return this.$q.screen.lt.sm ? 375 : 450
},
formattedCartTax() {
return this.formatAmount(this.cartTax, this.currency)
Expand Down Expand Up @@ -695,7 +695,7 @@ window.app = Vue.createApp({
},
showComplete() {
this.complete.show = true
if (this.$q.screen.width < 1200 && this.cartDrawer) {
if (this.$q.screen.lt.lg && this.cartDrawer) {
this.cartDrawer = false
}
}
Expand Down
2 changes: 1 addition & 1 deletion templates/tpos/tpos.html
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ <h5>
show-if-above
bordered
:width="drawerWidth"
:breakpoint="1200"
:breakpoint="1024"
>
<div class="row full-width q-pa-md">
<div class="absolute-top-right q-pa-md">
Expand Down

0 comments on commit c2465a4

Please sign in to comment.