Skip to content

Open source personal finance application

update 3.2.6

ilkomedf6ed35516f4
diff --git a/assets/stylus/variables/fonts.styl b/assets/stylus/variables/fonts.styl
index ec73d97e..c7458857 100644
--- a/assets/stylus/variables/fonts.styl
+++ b/assets/stylus/variables/fonts.styl
@@ -1,5 +1,5 @@
html
- --font-secondary "Unica One", "Roboto Condensed", sans-serif
+ --font-secondary 'Unica One', 'Roboto Condensed', sans-serif
fs-m()
font-size 16px
@@ -8,13 +8,19 @@ fs-m()
// fonts
font-primary()
- font-family "Roboto", sans-serif
+ font-family 'Roboto', sans-serif
font-secondary()
- font-family "Unica One", "Roboto Condensed", sans-serif
+ font-family 'Unica One', 'Roboto Condensed', sans-serif
fontFamilyNunito()
- font-family "Nunito", "Roboto", sans-serif
+ font-family 'Nunito', 'Roboto', sans-serif
+
+font-pt-sans-narrow()
+ font-family 'PT Sans Narrow', sans-serif
+
+font-roboto()
+ font-family 'Roboto', sans-serif
// sizes
$font-size-nb = 28px
diff --git a/components/about/About.vue b/components/about/About.vue
index 92b1c323..6c52e4be 100644
--- a/components/about/About.vue
+++ b/components/about/About.vue
@@ -18,7 +18,7 @@ export default {
</template>
<style lang="stylus" scoped>
-@import "~assets/stylus/variables"
+@import '~assets/stylus/variables'
.about
&__title
diff --git a/components/amount/Amount.vue b/components/amount/Amount.vue
index 41fe551e..a8dba846 100644
--- a/components/amount/Amount.vue
+++ b/components/amount/Amount.vue
@@ -45,11 +45,19 @@ export default {
computed: {
className () {
return {
- [`_${this.vertical}`]: this.vertical,
_expenses: this.isColorize && this.type === 0,
_incomes: this.isColorize && this.type === 1,
+ [`_${this.vertical}`]: this.vertical,
[`_size_${this.size}`]: this.size
}
+ },
+
+ amountInBaseCurrency () {
+ const baseValue = this.$store.getters['currencies/getAmountInBaseCurrency']({ amount: this.value, currency: this.currency })
+ if (baseValue) {
+ return this.formatAmount(baseValue, '0')
+ }
+ return null
}
},
@@ -75,13 +83,6 @@ export default {
const number = amount
const fixed = fixedNumber || 2
return Number(`${number.toFixed(fixed)}`).toLocaleString('ru-RU')
- },
-
- convertToBaseCurrency () {
- const baseValue = this.$store.getters['currencies/getAmountInBaseCurrency']({ amount: this.value, currency: this.currency })
- if (baseValue) {
- return this.formatAmount(baseValue, '0')
- }
}
}
}
@@ -97,12 +98,12 @@ export default {
template(v-if="showBase && (value !== 0) && (currency !== $store.state.currencies.base)")
.amountItem._base(:class="className")
.amountItem__prefix(v-if="isShowPrefix") {{ type === 0 ? '-' : '+' }}
- .amountItem__value {{ convertToBaseCurrency() }}
+ .amountItem__value {{ amountInBaseCurrency }}
.amountItem__symbol {{ getCurrencySymbol($store.state.currencies.base) }}
</template>
<style lang="stylus" scoped>
-@import "~assets/stylus/variables"
+@import '~assets/stylus/variables'
.amount
color var(--c-font-base)
@@ -113,6 +114,43 @@ export default {
&._expenses
color var(--c-expenses-1)
+ typo-money()
+
+ @media $media-laptop
+ font-size 16px
+
+ &._big
+ font-size 20px
+ font-weight 600
+
+ &._small
+ font-size 14px
+ font-weight 600
+
+ &__wrap
+ display flex
+ flex-flow row nowrap
+ align-items flex-end
+ justify-content flex-end
+
+ ^[0]._center &
+ justify-content center
+
+ &__price
+ &:first-child
+ margin-right $m3
+
+ &:last-child
+ margin-left $m3
+
+ &__symbol
+ font-primary()
+ font-size 14px
+ font-weight normal
+
+ ^[0]._small &
+ font-size 11px
+
.amountItem
display flex
align-items flex-end
@@ -141,7 +179,7 @@ export default {
&__value
font-size 15px
- font-weight bold
+ font-weight 400
font-secondary()
~/._base &
diff --git a/components/amount/amount.styl b/components/amount/amount.styl
deleted file mode 100644
index 1d07d60d..00000000
--- a/components/amount/amount.styl
+++ /dev/null
@@ -1,43 +0,0 @@
-.amount
- typo-money()
-
- @media $media-laptop
- font-size 16px
-
- &._big
- font-size 20px
- font-weight 600
-
- &._small
- font-size 14px
- font-weight 600
-
- &__wrap
- display flex
- flex-flow row nowrap
- align-items flex-end
- justify-content flex-end
-
- ^[0]._center &
- justify-content center
-
- &._expenses
- color var(--c-expenses-1)
-
- &._incomes
- color var(--c-incomes-1)
-
- &__price
- &:first-child
- margin-right $m3
-
- &:last-child
- margin-left $m3
-
- &__symbol
- font-primary()
- font-size 14px
- font-weight normal
-
- ^[0]._small &
- font-size 11px
diff --git a/components/analytics/AnalyticsChart.vue b/components/analytics/AnalyticsChart.vue
index b6afdf2d..633fe532 100644
--- a/components/analytics/AnalyticsChart.vue
+++ b/components/analytics/AnalyticsChart.vue
@@ -25,13 +25,13 @@ export default {
return {
average: 0,
date: dayjs().valueOf(),
- periodName: 'month',
visiblePeriodMenu: false,
dateStart: null,
dateEnd: null,
chartOptions: {
...chartOptions,
- legend: false
+ legend: false,
+ tooltip: false
}
}
},
@@ -51,6 +51,10 @@ export default {
filterDate () {
return this.$store.state.filter.date
+ },
+
+ periodName () {
+ return this.$store.state.filter.period
}
},
@@ -86,6 +90,7 @@ export default {
this.chartOptions = {
...this.chartOptions,
+ tooltip: false,
xAxis: {
categories: data.categories
},
@@ -128,10 +133,17 @@ export default {
const categories = []
const incomesData = []
+ let format = 'MMM'
+ console.log(periodName)
+ if (periodName === 'day') { format = 'D.MM' }
+ if (periodName === 'week') { format = 'D.MM' }
+ if (periodName === 'month') { format = 'MMMM' }
+ if (periodName === 'year') { format = 'YYYY' }
+
for (let index = 0; index < periodsToShow; index++) {
// count total period
const periodDate = dayjs().endOf(periodName).subtract(index, periodName).valueOf()
- const name = dayjs(periodDate).format('MMM')
+ const name = dayjs(periodDate).format(format)
const trnsIds = this.$store.getters['trns/getTrns']({
categoryId: this.categoryId,
date: periodDate,
@@ -182,18 +194,18 @@ export default {
.chart(ref="chart")
.columns
.item
- .item__name Выбранный период
+ .item__name {{ $t('stat.selectedPeriod') }}
.item__price
Amount(
:currency="$store.state.currencies.base"
:type="3"
- :value="statCurrentPeriod.categories[categoryId].total"
+ :value="statCurrentPeriod.total"
size="xl"
vertical="center"
)
.item
- .item__name Среднее
+ .item__name {{ $t('money.average') }}
.item__price
Amount(
:currency="$store.state.currencies.base"
diff --git a/components/layout/Layout.vue b/components/layout/Layout.vue
deleted file mode 100644
index a073fa93..00000000
--- a/components/layout/Layout.vue
+++ /dev/null
@@ -1,15 +0,0 @@
-<script>
-export default {
-}
-</script>
-
-<template lang="pug">
-.layout
- LazyLayoutMobile(v-if="$store.state.ui.mobile")
- LazyLayoutPc(v-if="$store.state.ui.pc")
-</template>
-
-<style lang="stylus" scoped>
-.layout
- height 100%
-</style>
diff --git a/components/layout/LayoutMobile.vue b/components/layout/LayoutMobile.vue
index c0970191..c21c61ca 100644
--- a/components/layout/LayoutMobile.vue
+++ b/components/layout/LayoutMobile.vue
@@ -118,7 +118,7 @@ export default {
.page__summary
//- Summary
//-----------------------------------------------------------
- LazySummaryAverage(v-if="$store.state.ui.stat.averageStatVisibility === 'visible'")
+ //- LazySummaryAverage(v-if="$store.state.ui.stat.averageStatVisibility === 'visible'")
.page__content
.chartBar(v-show="$store.state.ui.statGraphsVisibility === 'visible'")
diff --git a/components/layout/sidebar/Menu.vue b/components/layout/sidebar/Menu.vue
index 58be06c1..6fcabeff 100644
--- a/components/layout/sidebar/Menu.vue
+++ b/components/layout/sidebar/Menu.vue
@@ -119,9 +119,11 @@ item-bg-active()
grid-template-columns 24px 1fr 24px
grid-column-gap 20px
align-items center
+ height 50px
padding 16px 16px
+media-laptop()
+ height auto
padding 16px 20px
&:hover
diff --git a/components/shared/BaseModal.vue b/components/shared/BaseModal.vue
index 3cb15cc8..33eeb847 100644
--- a/components/shared/BaseModal.vue
+++ b/components/shared/BaseModal.vue
@@ -133,16 +133,16 @@ portal(to="modal" v-if="show")
display none
&__wrap
- z-index 2
overflow hidden
+ z-index 2
position absolute
left 0
bottom 0
- width 100%
display flex
+ width 100%
flex-grow 1
flex-flow column nowrap
- background var(--c-bg-4)
+ background var(--c-bg-2)
border-radius $m6
&._anim
diff --git a/components/shared/contextMenu/ContextMenuItem.vue b/components/shared/contextMenu/ContextMenuItem.vue
index 490aa27d..ba21080e 100644
--- a/components/shared/contextMenu/ContextMenuItem.vue
+++ b/components/shared/contextMenu/ContextMenuItem.vue
@@ -55,13 +55,11 @@ export default {
cursor pointer
display flex
align-items center
+ height 50px
padding 0 $m6
font-size 13px
white-space nowrap
- @media $media-phone
- height 56px
-
@media $media-laptop
height 38px
diff --git a/components/stat/StatItem.vue b/components/stat/StatItem.vue
index 274fa4d3..d111570a 100644
--- a/components/stat/StatItem.vue
+++ b/components/stat/StatItem.vue
@@ -109,9 +109,9 @@ export default {
overflow hidden
cursor pointer
position relative
- margin (- 10px) 0
+ // margin (- 10px) 0
margin-bottom 10px
- padding 10px
+ padding 8px 0
border 1px solid transparent
border-radius $m5
@@ -130,8 +130,8 @@ export default {
background var(--c-bg-2)
border 1px solid var(--c-bg-7)
- &:first-child
- margin-top (- 10px)
+ // &:first-child
+ // margin-top (- 10px)
&__content
display grid
diff --git a/components/stat/SummaryRow.vue b/components/stat/SummaryRow.vue
index 6da8616a..cc64d4a3 100644
--- a/components/stat/SummaryRow.vue
+++ b/components/stat/SummaryRow.vue
@@ -69,24 +69,25 @@ export default {
flex 1 0 0
position relative
display flex
+ align-items center
justify-content center
flex-flow column
- // padding-right 32px
+ padding-right 32px
- // &:after
- // position absolute
- // top 50%
- // right 16px
- // content ""
- // width 1px
- // height 32px
- // background var(--c-bg-7)
- // transform translateY(-50%)
+ &:after
+ position absolute
+ top 50%
+ right 16px
+ content ""
+ width 1px
+ height 32px
+ background var(--c-bg-7)
+ transform translateY(-50%)
- // &:last-child
- // padding-right 0
- // &:after
- // display none
+ &:last-child
+ padding-right 0
+ &:after
+ display none
&__title
padding-bottom $m5
diff --git a/components/trns/list/TrnsListDate.vue b/components/trns/list/TrnsListDate.vue
index d10948fb..9eac4528 100644
--- a/components/trns/list/TrnsListDate.vue
+++ b/components/trns/list/TrnsListDate.vue
@@ -40,6 +40,7 @@ export default {
padding-right 10px
align-self center
font-size 32px
+ font-weight 500
&__weekday
padding-top 2px
diff --git a/locales/en-US.js b/locales/en-US.js
index fe206caa..07937265 100644
--- a/locales/en-US.js
+++ b/locales/en-US.js
@@ -205,6 +205,7 @@ export default {
stat: {
title: 'Statistics',
+ selectedPeriod: 'Selected period',
shortTitle: 'Stat',
balanceTitle: 'Balance',
empty: 'No stat for this period',
diff --git a/locales/ru-RU.js b/locales/ru-RU.js
index dd8f8a6b..40e6d3d4 100644
--- a/locales/ru-RU.js
+++ b/locales/ru-RU.js
@@ -207,6 +207,7 @@ export default {
stat: {
title: 'Статистика',
+ selectedPeriod: 'Выбранный период',
shortTitle: 'Статистика',
balanceTitle: 'Баланс',
empty: 'Статистики по выбранным параметрам нет :)',
diff --git a/nuxt.config.js b/nuxt.config.js
index abdff1bf..f94c9806 100644
--- a/nuxt.config.js
+++ b/nuxt.config.js
@@ -48,7 +48,7 @@ export default {
],
link: [{
rel: 'stylesheet',
- href: 'https://fonts.googleapis.com/css?family=Roboto+Condensed:400,700|Unica+One|Nunito:400,700,800&display=swap&subset=cyrillic'
+ href: 'https://fonts.googleapis.com/css?family=Roboto:400,500,600,700|Roboto+Condensed:400,500,600,700|Unica+One|Nunito:400,700,800&display=swap&subset=cyrillic'
}, {
rel: 'stylesheet',
href: 'https://cdn.materialdesignicons.com/5.0.45/css/materialdesignicons.min.css'
@@ -101,6 +101,13 @@ export default {
fallback: 'dark' // fallback value if not system preference found
},
+ /**
+ * Style resources
+ */
+ styleResources: {
+ stylus: ['~/assets/stylus/variables']
+ },
+
/**
* Nuxt.js modules
*/
diff --git a/package-lock.json b/package-lock.json
index d1338f61..e2d48616 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,6 +1,6 @@
{
"name": "finapp",
- "version": "3.2.4",
+ "version": "3.2.5",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@@ -2929,9 +2929,9 @@
"dev": true
},
"import-fresh": {
- "version": "3.2.1",
- "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz",
- "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==",
+ "version": "3.2.2",
+ "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.2.tgz",
+ "integrity": "sha512-cTPNrlvJT6twpYy+YmKUKrTSjWFs3bjYjAhCwm+z4EOCubZxAuO+hHpRN64TqjEaYSHs7tJAE0w1CKMGmsG/lw==",
"dev": true,
"requires": {
"parent-module": "^1.0.0",
@@ -5027,6 +5027,16 @@
}
}
},
+ "@nuxtjs/style-resources": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/@nuxtjs/style-resources/-/style-resources-1.0.0.tgz",
+ "integrity": "sha512-tDRcC/pm8B0Kpxtzb/1/HOBkv3/kPD+2FiCiUBGMB7YriRud9OUPw1pnYCsAH9ftwpMJS4k4XOyUY8FCTk6OxA==",
+ "requires": {
+ "consola": "^2.4.0",
+ "glob-all": "^3.1.0",
+ "sass-resources-loader": "^2.0.0"
+ }
+ },
"@nuxtjs/youch": {
"version": "4.2.3",
"resolved": "https://registry.npmjs.org/@nuxtjs/youch/-/youch-4.2.3.tgz",
@@ -5122,12 +5132,6 @@
"resolved": "https://registry.npmjs.org/@types/anymatch/-/anymatch-1.3.1.tgz",
"integrity": "sha512-/+CRPXpBDpo2RK9C68N3b2cOvO0Cf5B9aPijHsoDQTHivnGSObdOF2BRQOYjojWTDy6nQvMjmqRXIxH55VjxxA=="
},
- "@types/color-name": {
- "version": "1.1.1",
- "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz",
- "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==",
- "dev": true
- },
"@types/html-minifier-terser": {
"version": "5.1.1",
"resolved": "https://registry.npmjs.org/@types/html-minifier-terser/-/html-minifier-terser-5.1.1.tgz",
@@ -6166,6 +6170,11 @@
"integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==",
"dev": true
},
+ "async": {
+ "version": "3.2.0",
+ "resolved": "https://registry.npmjs.org/async/-/async-3.2.0.tgz",
+ "integrity": "sha512-TR2mEZFVOj2pLStYxLht7TyfuRzaydfpxr3k9RpHIzMgw7A64dzsdqCxH1WJyQdoe8T10nDXd9wnEigmiuHIZw=="
+ },
"async-done": {
"version": "1.3.2",
"resolved": "https://registry.npmjs.org/async-done/-/async-done-1.3.2.tgz",
@@ -8014,9 +8023,9 @@
}
},
"dayjs": {
- "version": "1.9.4",
- "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.9.4.tgz",
- "integrity": "sha512-ABSF3alrldf7nM9sQ2U+Ln67NRwmzlLOqG7kK03kck0mw3wlSSEKv/XhKGGxUjQcS57QeiCyNdrFgtj9nWlrng=="
+ "version": "1.9.5",
+ "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.9.5.tgz",
+ "integrity": "sha512-WULIw7UpW/E0y6VywewpbXAMH3d5cZijEhoHLwM+OMVbk/NtchKS/W+57H/0P1rqU7gHrAArjiRLHCUhgMQl6w=="
},
"de-indent": {
"version": "1.0.2",
@@ -8584,9 +8593,9 @@
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
},
"eslint": {
- "version": "7.12.1",
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-7.12.1.tgz",
- "integrity": "sha512-HlMTEdr/LicJfN08LB3nM1rRYliDXOmfoO4vj39xN6BLpFzF00hbwBoqHk8UcJ2M/3nlARZWy/mslvGEuZFvsg==",
+ "version": "7.13.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-7.13.0.tgz",
+ "integrity": "sha512-uCORMuOO8tUzJmsdRtrvcGq5qposf7Rw0LwkTJkoDbOycVQtQjmnhZSuLQnozLE4TmAzlMVV45eCHmQ1OpDKUQ==",
"dev": true,
"requires": {
"@babel/code-frame": "^7.0.0",
@@ -8775,9 +8784,9 @@
"dev": true
},
"import-fresh": {
- "version": "3.2.1",
- "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz",
- "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==",
+ "version": "3.2.2",
+ "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.2.tgz",
+ "integrity": "sha512-cTPNrlvJT6twpYy+YmKUKrTSjWFs3bjYjAhCwm+z4EOCubZxAuO+hHpRN64TqjEaYSHs7tJAE0w1CKMGmsG/lw==",
"dev": true,
"requires": {
"parent-module": "^1.0.0",
@@ -10343,6 +10352,181 @@
"path-is-absolute": "^1.0.0"
}
},
+ "glob-all": {
+ "version": "3.2.1",
+ "resolved": "https://registry.npmjs.org/glob-all/-/glob-all-3.2.1.tgz",
+ "integrity": "sha512-x877rVkzB3ipid577QOp+eQCR6M5ZyiwrtaYgrX/z3EThaSPFtLDwBXFHc3sH1cG0R0vFYI5SRYeWMMSEyXkUw==",
+ "requires": {
+ "glob": "^7.1.2",
+ "yargs": "^15.3.1"
+ },
+ "dependencies": {
+ "ansi-regex": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz",
+ "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg=="
+ },
+ "ansi-styles": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
+ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
+ "requires": {
+ "color-convert": "^2.0.1"
+ }
+ },
+ "camelcase": {
+ "version": "5.3.1",
+ "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz",
+ "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg=="
+ },
+ "cliui": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz",
+ "integrity": "sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ==",
+ "requires": {
+ "string-width": "^4.2.0",
+ "strip-ansi": "^6.0.0",
+ "wrap-ansi": "^6.2.0"
+ }
+ },
+ "color-convert": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
+ "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
+ "requires": {
+ "color-name": "~1.1.4"
+ }
+ },
+ "color-name": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
+ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
+ },
+ "find-up": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz",
+ "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==",
+ "requires": {
+ "locate-path": "^5.0.0",
+ "path-exists": "^4.0.0"
+ }
+ },
+ "get-caller-file": {
+ "version": "2.0.5",
+ "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
+ "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg=="
+ },
+ "is-fullwidth-code-point": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
+ "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg=="
+ },
+ "locate-path": {
+ "version": "5.0.0",
+ "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz",
+ "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==",
+ "requires": {
+ "p-locate": "^4.1.0"
+ }
+ },
+ "p-limit": {
+ "version": "2.3.0",
+ "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz",
+ "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==",
+ "requires": {
+ "p-try": "^2.0.0"
+ }
+ },
+ "p-locate": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz",
+ "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==",
+ "requires": {
+ "p-limit": "^2.2.0"
+ }
+ },
+ "p-try": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz",
+ "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ=="
+ },
+ "path-exists": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz",
+ "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w=="
+ },
+ "require-main-filename": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz",
+ "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg=="
+ },
+ "string-width": {
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.0.tgz",
+ "integrity": "sha512-zUz5JD+tgqtuDjMhwIg5uFVV3dtqZ9yQJlZVfq4I01/K5Paj5UHj7VyrQOJvzawSVlKpObApbfD0Ed6yJc+1eg==",
+ "requires": {
+ "emoji-regex": "^8.0.0",
+ "is-fullwidth-code-point": "^3.0.0",
+ "strip-ansi": "^6.0.0"
+ }
+ },
+ "strip-ansi": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz",
+ "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==",
+ "requires": {
+ "ansi-regex": "^5.0.0"
+ }
+ },
+ "which-module": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz",
+ "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho="
+ },
+ "wrap-ansi": {
+ "version": "6.2.0",
+ "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz",
+ "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==",
+ "requires": {
+ "ansi-styles": "^4.0.0",
+ "string-width": "^4.1.0",
+ "strip-ansi": "^6.0.0"
+ }
+ },
+ "y18n": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz",
+ "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w=="
+ },
+ "yargs": {
+ "version": "15.4.1",
+ "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz",
+ "integrity": "sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A==",
+ "requires": {
+ "cliui": "^6.0.0",
+ "decamelize": "^1.2.0",
+ "find-up": "^4.1.0",
+ "get-caller-file": "^2.0.1",
+ "require-directory": "^2.1.1",
+ "require-main-filename": "^2.0.0",
+ "set-blocking": "^2.0.0",
+ "string-width": "^4.2.0",
+ "which-module": "^2.0.0",
+ "y18n": "^4.0.0",
+ "yargs-parser": "^18.1.2"
+ }
+ },
+ "yargs-parser": {
+ "version": "18.1.3",
+ "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-18.1.3.tgz",
+ "integrity": "sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==",
+ "requires": {
+ "camelcase": "^5.0.0",
+ "decamelize": "^1.2.0"
+ }
+ }
+ }
+ },
"glob-parent": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-3.1.0.tgz",
@@ -12170,12 +12354,11 @@
},
"dependencies": {
"ansi-styles": {
- "version": "4.2.1",
- "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz",
- "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==",
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
+ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
"dev": true,
"requires": {
- "@types/color-name": "^1.1.1",
"color-convert": "^2.0.1"
}
},
@@ -12467,9 +12650,9 @@
}
},
"mathjs": {
- "version": "7.5.1",
- "resolved": "https://registry.npmjs.org/mathjs/-/mathjs-7.5.1.tgz",
- "integrity": "sha512-H2q/Dq0qxBLMw+G84SSXmGqo/znihuxviGgAQwAcyeFLwK2HksvSGNx4f3dllZF51bWOnu2op60VZxH2Sb51Pw==",
+ "version": "7.6.0",
+ "resolved": "https://registry.npmjs.org/mathjs/-/mathjs-7.6.0.tgz",
+ "integrity": "sha512-abywR28hUpKF4at5jE8Ys+Kigk40eKMT5mcBLD0/dtsqjfOLbtzd3WjlRqIopNo7oQ6FME51qph6lb8h/bhpUg==",
"requires": {
"complex.js": "^2.0.11",
"decimal.js": "^10.2.1",
@@ -16045,6 +16228,72 @@
"resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz",
"integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
},
+ "sass-resources-loader": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/sass-resources-loader/-/sass-resources-loader-2.1.1.tgz",
+ "integrity": "sha512-/KrD5mEBTj3ZQ49thKSThhpv1OFhc82JbWA0bmv9yANRuPIlQrydNpZG82jdy4pEWY0QcQTGyd5OmCb3xVeZsw==",
+ "requires": {
+ "async": "^3.2.0",
+ "chalk": "^4.1.0",
+ "glob": "^7.1.6",
+ "loader-utils": "^2.0.0"
+ },
+ "dependencies": {
+ "ansi-styles": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
+ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
+ "requires": {
+ "color-convert": "^2.0.1"
+ }
+ },
+ "chalk": {
+ "version": "4.1.0",
+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz",
+ "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==",
+ "requires": {
+ "ansi-styles": "^4.1.0",
+ "supports-color": "^7.1.0"
+ }
+ },
+ "color-convert": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
+ "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
+ "requires": {
+ "color-name": "~1.1.4"
+ }
+ },
+ "color-name": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
+ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
+ },
+ "has-flag": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
+ "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ=="
+ },
+ "loader-utils": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.0.tgz",
+ "integrity": "sha512-rP4F0h2RaWSvPEkD7BLDFQnvSf+nK+wr3ESUjNTyAGobqrijmW92zc+SO6d4p4B1wh7+B/Jg1mkQe5NYUEHtHQ==",
+ "requires": {
+ "big.js": "^5.2.2",
+ "emojis-list": "^3.0.0",
+ "json5": "^2.1.2"
+ }
+ },
+ "supports-color": {
+ "version": "7.2.0",
+ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
+ "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
+ "requires": {
+ "has-flag": "^4.0.0"
+ }
+ }
+ }
+ },
"sax": {
"version": "1.2.4",
"resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz",
@@ -16775,9 +17024,9 @@
}
},
"stylelint": {
- "version": "13.7.1",
- "resolved": "https://registry.npmjs.org/stylelint/-/stylelint-13.7.1.tgz",
- "integrity": "sha512-qzqazcyRxrSRdmFuO0/SZOJ+LyCxYy0pwcvaOBBnl8/2VfHSMrtNIE+AnyJoyq6uKb+mt+hlgmVrvVi6G6XHfQ==",
+ "version": "13.7.2",
+ "resolved": "https://registry.npmjs.org/stylelint/-/stylelint-13.7.2.tgz",
+ "integrity": "sha512-mmieorkfmO+ZA6CNDu1ic9qpt4tFvH2QUB7vqXgrMVHe5ENU69q7YDq0YUg/UHLuCsZOWhUAvcMcLzLDIERzSg==",
"dev": true,
"requires": {
"@stylelint/postcss-css-in-js": "^0.37.2",
@@ -16840,9 +17089,9 @@
}
},
"ajv": {
- "version": "6.12.5",
- "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.5.tgz",
- "integrity": "sha512-lRF8RORchjpKG50/WFf8xmg7sgCLFiYNNnqdKflk63whMQcWR5ngGjiSXkL9bjxy6B2npOK2HSMN49jEBMSkag==",
+ "version": "6.12.6",
+ "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz",
+ "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==",
"dev": true,
"requires": {
"fast-deep-equal": "^3.1.1",
@@ -16858,12 +17107,11 @@
"dev": true
},
"ansi-styles": {
- "version": "4.2.1",
- "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz",
- "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==",
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
+ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
"dev": true,
"requires": {
- "@types/color-name": "^1.1.1",
"color-convert": "^2.0.1"
}
},
@@ -16971,9 +17219,9 @@
"dev": true
},
"import-fresh": {
- "version": "3.2.1",
- "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz",
- "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==",
+ "version": "3.2.2",
+ "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.2.tgz",
+ "integrity": "sha512-cTPNrlvJT6twpYy+YmKUKrTSjWFs3bjYjAhCwm+z4EOCubZxAuO+hHpRN64TqjEaYSHs7tJAE0w1CKMGmsG/lw==",
"dev": true,
"requires": {
"parent-module": "^1.0.0",
@@ -18100,9 +18348,9 @@
"dev": true
},
"v8-compile-cache": {
- "version": "2.1.1",
- "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.1.1.tgz",
- "integrity": "sha512-8OQ9CL+VWyt3JStj7HX7/ciTL2V3Rl1Wf5OL+SNTm0yK1KvtReVulksyeRnCANHHuUxHlQig+JJDlUhBt1NQDQ==",
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.2.0.tgz",
+ "integrity": "sha512-gTpR5XQNKFwOd4clxfnhaqvfqMpqEwr4tOtCyz4MtYZX2JYhfr1JvBFKdS+7K/9rfpZR3VLX+YWBbKoxCgS43Q==",
"dev": true
},
"v8flags": {
diff --git a/package.json b/package.json
index 77b02576..11e8a8b4 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "finapp",
- "version": "3.2.5",
+ "version": "3.2.6",
"scripts": {
"dev": "cross-env NUXT_HOST=0.0.0.0 nuxt",
"build": "nuxt build",
@@ -12,15 +12,16 @@
"upload-min": "NODE_ENV=production node node_modules/gulp/bin/gulp.js uploadMin"
},
"dependencies": {
+ "@nuxtjs/style-resources": "^1.0.0",
"axios": "^0.21.0",
- "dayjs": "^1.9.4",
+ "dayjs": "^1.9.5",
"fancy-log": "^1.3.3",
"firebase": "^7.24.0",
"highcharts": "^8.2.2",
"highcharts-border-radius": "0.0.2",
"highcharts-vue": "^1.3.5",
"localforage": "^1.9.0",
- "mathjs": "^7.5.1",
+ "mathjs": "^7.6.0",
"nuxt": "^2.14.7",
"nuxt-composition-api": "^0.11.0",
"nuxt-i18n": "^6.15.4",
@@ -38,7 +39,7 @@
"@nuxtjs/pwa": "3.2.2",
"babel-eslint": "^10.1.0",
"cross-env": "^7.0.2",
- "eslint": "^7.12.1",
+ "eslint": "^7.13.0",
"eslint-plugin-nuxt": "^1.0.0",
"gulp": "^4.0.2",
"gulp-notify": "^3.2.0",
@@ -47,7 +48,7 @@
"pug": "^3.0.0",
"pug-plain-loader": "^1.0.0",
"style-loader": "^1.3.0",
- "stylelint": "^13.7.1",
+ "stylelint": "^13.7.2",
"stylelint-order": "^4.1.0",
"stylelint-plugin-stylus": "^0.9.0",
"stylus": "^0.54.8",
diff --git a/pages/composition.vue b/pages/composition.vue
deleted file mode 100644
index aad4594d..00000000
--- a/pages/composition.vue
+++ /dev/null
@@ -1,57 +0,0 @@
-<script>
-import { ref } from 'nuxt-composition-api'
-import useTouchClose from '~/composables/useTouchClose'
-
-export default {
- name: 'CompositionPage',
-
- setup () {
- const scrollContainer = ref(null)
- const scrollContent = ref(null)
- const scrollOverflow = ref(null)
- const scrollWrapper = ref(null)
-
- const { close } = useTouchClose({
- container: scrollContainer,
- content: scrollContent,
- overflow: scrollOverflow,
- wrapper: scrollWrapper
- })
-
- return {
- scrollContainer,
- scrollContent,
- scrollOverflow,
- scrollWrapper,
- closeModal: close
- }
- }
-}
-</script>
-
-<template lang="pug">
-div
- n-link(to="/") CompositionPage
-
- h1(@click="close") close
-
- div.scroll(ref="scrollContainer")
- .scroll__overflow(ref="scrollOverflow") overflow
- .scroll__wrapper(ref="scrollWrapper") wrapper
- .scroll__content(ref="scrollContent") content
-
-</template>
-
-<style lang="stylus" scoped>
-.scroll
- height 400px
- background gray
-
- &__wrapper
- height 100px
- background blue
-
- &__content
- height 50px
- background red
-</style>
diff --git a/pages/index.vue b/pages/index.vue
index 3bb8db3d..a33490f4 100644
--- a/pages/index.vue
+++ b/pages/index.vue
@@ -5,9 +5,12 @@ export default {
</script>
<template lang="pug">
-Layout(v-if="$store.getters['user/userUid']")
+.layout(v-if="$store.getters['user/userUid']")
+ LazyLayoutMobile(v-if="$store.state.ui.mobile")
+ LazyLayoutPc(v-if="$store.state.ui.pc")
</template>
<style lang="stylus" scoped>
-// styles here
+.layout
+ height 100%
</style>
diff --git a/store/trns/getters.js b/store/trns/getters.js
index d341fb31..64500ef3 100644
--- a/store/trns/getters.js
+++ b/store/trns/getters.js
@@ -258,7 +258,7 @@ export default {
getTrnsIds: (state, getters, rootState) => (props) => {
if (!getters.hasTrns) { return [] }
- // const { date, periodName, description } = props
+ const { startDate, endDate, periodName } = props
const categories = rootState.categories.items
const categoriesIds = Object.keys(categories)
const filterCategoryId = props.categoryId
@@ -267,10 +267,16 @@ export default {
const trns = rootState.trns.items
let trnsIds = Object.keys(trns)
- // const filterDate = dayjs(date)
- // const filterPeriod = periodName || rootState.filter.period
- // const startDateValue = filterDate.startOf(filterPeriod).valueOf()
- // const endDateValue = filterDate.endOf(filterPeriod).valueOf()
+ // filter date
+ if (startDate && endDate && periodName) {
+ // const filterDate = dayjs(startDate)
+ // const filterPeriod = periodName || rootState.filter.period
+ const startDateValue = dayjs(startDate).startOf('day').valueOf()
+ const endDateValue = dayjs(endDate).endOf('day').valueOf()
+
+ trnsIds = trnsIds
+ .filter(trnId => (trns[trnId].date >= startDateValue) && (trns[trnId].date <= endDateValue))
+ }
// filter wallet
if (filterWalletId) {
diff --git a/stylelint.config.js b/stylelint.config.js
index ea5a8843..3670ba44 100644
--- a/stylelint.config.js
+++ b/stylelint.config.js
@@ -22,7 +22,7 @@ module.exports = {
'selector-attribute-operator-space-after': 'never',
'selector-attribute-operator-space-before': 'never',
'selector-attribute-quotes': 'always',
- 'string-quotes': 'double',
+ 'string-quotes': 'single',
'stylus/at-rule-empty-line-before': [
'always', {
except: ['blockless-after-same-name-blockless'],