From a446cd6c5b5ddafaa1c6a2263c2fe7ca5de0e763 Mon Sep 17 00:00:00 2001 From: arcbtc Date: Thu, 19 Dec 2024 22:47:37 +0000 Subject: [PATCH] different way to do wallet cards --- lnbits/core/templates/core/wallet.html | 67 +---------------------- lnbits/static/js/base.js | 12 ++++ lnbits/static/js/wallet.js | 1 - lnbits/templates/base.html | 76 +++++++++++++++++++++++++- lnbits/templates/components.vue | 4 +- 5 files changed, 92 insertions(+), 68 deletions(-) diff --git a/lnbits/core/templates/core/wallet.html b/lnbits/core/templates/core/wallet.html index 47f373dcd..807f86ffc 100644 --- a/lnbits/core/templates/core/wallet.html +++ b/lnbits/core/templates/core/wallet.html @@ -25,68 +25,7 @@ } : ''" > {% endif %} - -
- - -
- - - -
-
-
-
- - {{LNBITS_DENOMINATION}} -
-
-
-
-
-
+ {% else %}
diff --git a/lnbits/static/js/base.js b/lnbits/static/js/base.js index c2cb11c5f..a2e6a927f 100644 --- a/lnbits/static/js/base.js +++ b/lnbits/static/js/base.js @@ -453,6 +453,8 @@ window.windowMixin = { data() { return { toggleSubs: true, + walletFlip: true, + mobileSimple: false, reactionChoice: 'confettiBothSides', borderChoice: '', gradientChoice: @@ -472,6 +474,14 @@ window.windowMixin = { }, methods: { + flipWallets() { + this.walletFlip = !this.walletFlip + this.$q.localStorage.set('lnbits.walletFlip', this.walletFlip) + }, + simpleMobile() { + this.mobileSimple = !this.mobileSimple + this.$q.localStorage.set('lnbits.mobileSimple', this.mobileSimple) + }, changeColor(newValue) { document.body.setAttribute('data-theme', newValue) this.$q.localStorage.set('lnbits.theme', newValue) @@ -700,6 +710,8 @@ window.windowMixin = { } await this.checkUsrInUrl() this.themeParams() + this.walletFlip = this.$q.localStorage.getItem('lnbits.walletFlip') + this.mobileSimple = this.$q.localStorage.getItem('lnbits.mobileSimple') } } diff --git a/lnbits/static/js/wallet.js b/lnbits/static/js/wallet.js index a9fd62932..5e159d06b 100644 --- a/lnbits/static/js/wallet.js +++ b/lnbits/static/js/wallet.js @@ -50,7 +50,6 @@ window.app = Vue.createApp({ }, balance: parseInt(wallet.balance_msat / 1000), fiatBalance: 0, - mobileSimple: false, update: { name: null, currency: null diff --git a/lnbits/templates/base.html b/lnbits/templates/base.html index ae56f6d44..b61db5f7c 100644 --- a/lnbits/templates/base.html +++ b/lnbits/templates/base.html @@ -158,7 +158,14 @@ show-if-above :elevated="$q.screen.lt.md" > - + + + + + + +
+ + +
+ + + +
+
+
+
+ + {{LNBITS_DENOMINATION}} +
+
+
+
+
+
+ + {% block page %}{% endblock %}
diff --git a/lnbits/templates/components.vue b/lnbits/templates/components.vue index 955670aed..88b0fad78 100644 --- a/lnbits/templates/components.vue +++ b/lnbits/templates/components.vue @@ -1,10 +1,11 @@