Open source personal finance application
ui: update
ilkome65fccf3d5ff0
diff --git a/assets/stylus/colors-light.styl b/assets/stylus/colors-light.stylindex d9fec68a..c4732bae 100644--- a/assets/stylus/colors-light.styl+++ b/assets/stylus/colors-light.styl@@ -50,6 +50,6 @@ html--c-item-stat-bg #ebebeb--c-item-stat-icon rgba(250, 250, 250, 1)- --c-item-bg-main #f5f6f8d1+ --c-item-bg-main #f5f6f8--c-chart-lables-text-color rgba(50, 50, 50, 1)--c-chart-lables-text-shaddow #6e6e6e7adiff --git a/components/categories/item/CategoryItem.vue b/components/categories/item/CategoryItem.vueindex 8537c980..a726d309 100644--- a/components/categories/item/CategoryItem.vue+++ b/components/categories/item/CategoryItem.vue@@ -45,13 +45,13 @@ export default defineComponent({</script><template lang="pug">-.categoryItem.bg-main.p-2.gap-x-3.items-center.flex.rounded-md(+.categoryItem.bg-main.py-2.px-3.gap-x-3.flex.items-center.rounded-md.bg-gray-50.dark_bg-dark5.hocus_bg-gray-100.dark_hocus_bg-neutral-800(v-if="category":class="{ [ui]: ui, _active: activeItemId === id }"@click="onClickItem").categoryItem__active(v-if="activeItemId === id")- .text-neutral-50.text-xl.leading-none.w-8.h-8.rounded-full.justify-center.items-center.flex(+ .w-8.h-8.flex.items-center.justify-center.rounded-full.text-xl.leading-none.text-neutral-50(:style="{ background: category.color }"@click.stop="onClickIcon"): div(:class="category.icon")@@ -62,9 +62,11 @@ export default defineComponent({class="dark_text-neutral-400") {{ parentCategory.name }}- .leading-none.text-sm.text-neutral-700(class="dark_text-neutral-300") {{ category.name }}+ .leading-none.text-sm.text-neutral-700.dark_text-neutral-300+ | {{ category.name }}+ template(v-if="childCategoriesIds.length > 0") ...- .text-md.text-neutral-500(+ .font-unica.text-md.text-neutral-500(v-if="childCategoriesIds.length > 0"class="dark_text-neutral-400") {{ childCategoriesIds.length }}@@ -72,9 +74,6 @@ export default defineComponent({<style lang="stylus" scoped>.bg-main- background var(--c-item-bg-main)- +media-hover()- background var(--c-item-bg-hover)&._activebackground var(--c-item-bg-hover)diff --git a/components/categories/page/List.vue b/components/categories/page/List.vueindex 61d1571a..a3a8e0e7 100644--- a/components/categories/page/List.vue+++ b/components/categories/page/List.vue@@ -19,19 +19,33 @@ export default defineComponent({</script><template lang="pug">-.h-full.overflow.overflow-x-auto.grid.max-w-3xl.h-full(- class="pb-[44px] md_pb-[52px] lg_pb-0 lg_grid-rows-[1fr_auto]"+.overflow.overflow-x-auto.h-full.grid.max-w-3xl(+ class="md_pb-[52px] pb-[44px] lg_pb-0 grid-rows-[1fr_auto]")div- .py-6.px-3.font-nunito.text-neutral-800.dark_text-white.text-2xl.leading-none.font-semibold- | {{ $t('categories.name') }}-- .pb-4- CategoriesListSlot(- :ids="catsIds"- v-slot="{ categories }"- )- .shame1.px-3+ //- Header+ //---------------------------------+ .flex+ //- Title+ .grow.py-6.px-3.font-nunito.text-neutral-800.dark_text-white.text-2xl.leading-none.font-semibold+ | {{ $t('categories.name') }}++ //- Actions+ .flex-center.gap-3.pr-3+ //- Add+ .cursor-pointer.group.w-10.h-10.flex-center.rounded-full.bg-gray-50.dark_bg-dark5.hocus-text-white.hocus_bg-blue2(+ @click="$store.dispatch('ui/setActiveTab', 'createCategory')"+ )+ svg.group-hover_text-white.w-6.h-6(xmlns="http://www.w3.org/2000/svg" viewBox="0 0 12 12")+ path(fill="currentColor" d="M6 1.5a.5.5 0 0 0-1 0V5H1.5a.5.5 0 0 0 0 1H5v3.5a.5.5 0 0 0 1 0V6h3.5a.5.5 0 0 0 0-1H6V1.5Z")++ //- List+ //---------------------------------+ CategoriesListSlot(+ :ids="catsIds"+ v-slot="{ categories }"+ )+ .pb-12.px-3.grid.gap-y-1.gap-x-6.md_grid-cols-2CategoriesItemCategoryItem(v-for="category in categories":category="category"@@ -41,7 +55,7 @@ export default defineComponent({@onClick="id => $router.push(`/categories/${category.id}`)")- .pb-4.px-3.flex.gap-4.pt-4+ .pb-4.px-3.flex.gap-4.button(@click="$store.dispatch('ui/setActiveTab', 'createCategory')") {{ $t('categories.new') }}</template>diff --git a/components/categories/page/id/Edit.vue b/components/categories/page/id/Edit.vueindex 70265a81..f5890b67 100644--- a/components/categories/page/id/Edit.vue+++ b/components/categories/page/id/Edit.vue@@ -232,7 +232,7 @@ export default defineComponent({:href='href'@click='navigate')- .pb-2.text-xs.font-medium(class="text-white/50") {{ $t('categories.editTitle') }}+ .pb-2.text-xs.font-medium(class="dark_text-white/50") {{ $t('categories.editTitle') }}.flex.items-center.gap-3.text-neutral-800.dark_text-white.text-2xl.leading-none.font-semibold {{ category.name }}diff --git a/components/categories/page/id/Index.vue b/components/categories/page/id/Index.vueindex 77af2b55..335ae38c 100644--- a/components/categories/page/id/Index.vue+++ b/components/categories/page/id/Index.vue@@ -57,7 +57,7 @@ function handleEditClick() {:href='href'@click='navigate')- .pb-2.text-xs.font-medium(class="text-white/50")+ .pb-2.text-xs.font-medium(class="dark_text-white/50")| {{ $t('categories.title') }}template(v-if="category.parentId")|@@ -74,6 +74,7 @@ function handleEditClick() {@click="handleEditClick")+ //- Open stat.pb-12.px-3.flex.cursor-pointer.p-1.px-3.flex.items-center.gap-3.bg-gray-50.dark_bg-dark4.rounded-md.hocus_bg-gray-100.dark_hocus_bg-neutral-800.shadow.hocus_shadow-lg(diff --git a/components/wallets/page/List.vue b/components/wallets/page/List.vueindex dc86e139..8f208a10 100644--- a/components/wallets/page/List.vue+++ b/components/wallets/page/List.vue@@ -15,50 +15,45 @@ export default defineComponent({</script><template lang="pug">-.h-full.overflow.overflow-x-auto.grid.max-w-3xl.h-full(- class="pb-[44px] md_pb-[52px] lg_pb-0 lg_grid-rows-[1fr_auto]"+.overflow.overflow-x-auto.h-full.grid.max-w-3xl(+ class="md_pb-[52px] pb-[44px] lg_pb-0 grid-rows-[1fr_auto]")div+ //- Header+ //---------------------------------.flex+ //- Title.grow.py-6.px-3.font-nunito.text-neutral-800.dark_text-white.text-2xl.leading-none.font-semibold| {{ $t('wallets.name') }}+ //- Actions.flex-center.gap-3.pr-3//- Sort- .cursor-pointer.group.bg.rounded-full.w-10.h-10.flex-center.hocus-text-white.hocus_bg-blue2(+ .cursor-pointer.group.w-10.h-10.flex-center.rounded-full.bg-gray-50.dark_bg-dark5.hocus-text-white.hocus_bg-blue2(@click="$store.dispatch('ui/setActiveTab', 'walletsSort')")svg.group-hover_text-white.w-6.h-6(xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24")path(fill="currentColor" d="M7 20h2V8h3L8 4L4 8h3zm13-4h-3V4h-2v12h-3l4 4z")//- Add- .cursor-pointer.group.bg.rounded-full.w-10.h-10.flex-center.hocus-text-white.hocus_bg-blue2(+ .cursor-pointer.group.w-10.h-10.flex-center.rounded-full.bg-gray-50.dark_bg-dark5.hocus-text-white.hocus_bg-blue2(@click="$store.dispatch('ui/setActiveTab', 'createWallet')")svg.group-hover_text-white.w-6.h-6(xmlns="http://www.w3.org/2000/svg" viewBox="0 0 12 12")path(fill="currentColor" d="M6 1.5a.5.5 0 0 0-1 0V5H1.5a.5.5 0 0 0 0 1H5v3.5a.5.5 0 0 0 1 0V6h3.5a.5.5 0 0 0 0-1H6V1.5Z")- .pb-6.px-3+ .pb-12.px-3+ //- TotalWalletsTotalAlt(isShowCreditsisShowSavings)- .pb-6.px-3(v-if="$store.getters['user/isTester']")- .flex- .cursor-pointer.p-1.px-3.flex.items-center.gap-3.bg-gray-50.dark_bg-dark4.rounded-md.hocus_bg-gray-100.dark_hocus_bg-neutral-800.shadow.hocus_shadow-lg(- class="dark_text-white/60"- @click="$router.push('/wallets/total')"- )- .mdi.mdi-poll.text-xl- .text-xs.leading-none Total- .mdi.mdi-chevron-right.opacity-70.text-lg.leading-none-//- List//---------------------------------.pb-12.px-3.grid.gap-y-1.gap-x-6.md_grid-cols-2//- Item- .bg.cursor-pointer.py-2.px-3.rounded-md.hocus_bg-gray-100.dark_hocus_bg-neutral-800(+ .cursor-pointer.py-2.px-3.rounded-md.bg-gray-50.dark_bg-dark5.hocus_bg-gray-100.dark_hocus_bg-neutral-800(v-for="(walletItem, walletId) in walletsItemsSorted":key="walletId"@click="$router.push(`/wallets/${walletId}`)"@@ -85,8 +80,3 @@ export default defineComponent({//- Sort.button(@click="$store.dispatch('ui/setActiveTab', 'walletsSort')") {{ $t('base.sort') }}</template>--<style lang="stylus" scoped>-.bg- background var(--c-item-bg-main)-</style>diff --git a/components/wallets/page/id/Edit.vue b/components/wallets/page/id/Edit.vueindex d581a733..1dd57ad2 100644--- a/components/wallets/page/id/Edit.vue+++ b/components/wallets/page/id/Edit.vue@@ -175,7 +175,7 @@ export default defineComponent({:href='href'@click='navigate')- .pb-1.text-xs.font-medium(class="text-white/50") {{ $t('wallets.editTitle') }}+ .pb-1.text-xs.font-medium(class="dark_text-white/50") {{ $t('wallets.editTitle') }}.flex.items-center.gap-3.text-neutral-800.dark_text-white.text-2xl.font-semibold {{ wallet.name }}diff --git a/components/wallets/page/id/Index.vue b/components/wallets/page/id/Index.vueindex 2833b10d..607296a8 100644--- a/components/wallets/page/id/Index.vue+++ b/components/wallets/page/id/Index.vue@@ -89,7 +89,7 @@ export default defineComponent({:href='href'@click='navigate')- .pb-2.text-xs.font-medium(class="text-white/50") {{ $t('wallets.title') }}+ .pb-2.text-xs.font-medium(class="dark_text-white/50") {{ $t('wallets.title') }}.flex.items-center.gap-3.pb-3.text-neutral-800.dark_text-white.text-2xl.leading-none.font-semibold {{ wallet.name }}@@ -121,8 +121,8 @@ export default defineComponent({.mdi.mdi-chevron-right.opacity-70.text-lg.leading-none//- Stat- .overflow-hidden.relative.bg-white.dark_bg-custom4.mx-3.mb-12.p-3.rounded-md- SharedDate.text-xs.font-medium(class="-mb-1 text-white/50")+ .overflow-hidden.relative.bg-gray-50.dark_bg-custom4.mx-3.mb-12.p-3.rounded-md+ SharedDate.text-xs.font-medium(class="-mb-1 dark_text-white/50")div(class="-mb-3")StatGroupSum2(:trnsIds="filteredTrnsIds"diff --git a/components/wallets/sort/WalletsSort.vue b/components/wallets/sort/WalletsSort.vueindex 745dc8e9..bf5133d8 100644--- a/components/wallets/sort/WalletsSort.vue+++ b/components/wallets/sort/WalletsSort.vue@@ -39,16 +39,13 @@ export default {<template lang="pug">.h-full.overflow.overflow-x-auto- .pb-8.flex.justify-between- .text-neutral-800.dark_text-white.text-2xl.font-semibold.font-nunito- | {{ $t('wallets.sortTitle') }}-- .cursor-pointer.text-white.bg-blue2.rounded-full.w-10.h-10.flex-center.hocus-text-white.hocus_bg-blue1(- @click="saveWalletsOrder"- )- svg.w-6.h-6(xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16")- path(fill="currentColor" d="M12.736 3.97a.733.733 0 0 1 1.047 0c.286.289.29.756.01 1.05L7.88 12.01a.733.733 0 0 1-1.065.02L3.217 8.384a.757.757 0 0 1 0-1.06a.733.733 0 0 1 1.047 0l3.052 3.093l5.4-6.425a.247.247 0 0 1 .02-.022Z")+ //- Header+ //-----------------------------------+ .pb-6.text-neutral-800.dark_text-white.text-2xl.font-semibold.font-nunito+ | {{ $t('wallets.sortTitle') }}+ //- Items+ //-----------------------------------Draggable.grid.gap-1(v-model="sortedWalletsIds"handle=".handle"diff --git a/components/wallets/total/WalletsTotalAlt.vue b/components/wallets/total/WalletsTotalAlt.vueindex 98736db3..6055fae7 100644--- a/components/wallets/total/WalletsTotalAlt.vue+++ b/components/wallets/total/WalletsTotalAlt.vue@@ -53,7 +53,7 @@ export default {v-if="$store.getters['wallets/hasWallets']")//- Credits- .flex.items-center.bg.py-2.px-3.rounded-md(v-if="isShowCredits && totalInWallets.credits !== 0")+ .flex.items-center.bg-gray-50.dark_bg-dark5.py-2.px-3.rounded-md(v-if="isShowCredits && totalInWallets.credits !== 0").grow.text-sm.leading-none {{ $t('credits') }}Amount(:currency="$store.state.currencies.base"@@ -62,7 +62,7 @@ export default {)//- Savings- .flex.items-center.bg.py-2.px-3.rounded-md(v-if="totalInWallets.savings !== 0 && isShowSavings")+ .flex.items-center.bg-gray-50.dark_bg-dark5.py-2.px-3.rounded-md(v-if="totalInWallets.savings !== 0 && isShowSavings").grow.text-sm.leading-none {{ $t('savings') }}Amount(:currency="$store.state.currencies.base"@@ -71,7 +71,7 @@ export default {)//- Total- .flex.items-center.bg.py-2.px-3.rounded-md+ .flex.items-center.bg-gray-50.dark_bg-dark5.py-2.px-3.rounded-md.grow.text-sm.leading-none {{ $t('total') }}Amount(:currency="$store.state.currencies.base"@@ -80,7 +80,7 @@ export default {)//- Avaliable- .flex.items-center.bg.py-2.px-3.rounded-md(v-if="totalInWallets.counted !== totalInWallets.counted + totalInWallets.savings - Math.abs(totalInWallets.credits)")+ .flex.items-center.bg-gray-50.dark_bg-dark5.py-2.px-3.rounded-md(v-if="totalInWallets.counted !== totalInWallets.counted + totalInWallets.savings - Math.abs(totalInWallets.credits)").grow.text-sm.leading-none {{ $t('avaliable') }}Amount(:currency="$store.state.currencies.base"@@ -89,11 +89,6 @@ export default {)</template>-<style lang="stylus" scoped>-.bg- background var(--c-item-bg-main)-</style>-<i18n lang="json5">{"en": {diff --git a/tailwind.config.js b/tailwind.config.jsindex 98467597..8752a67c 100644--- a/tailwind.config.js+++ b/tailwind.config.js@@ -24,10 +24,11 @@ module.exports = {custom5: '#1b1b1c',dark3: '#171717',dark4: '#1c1c1c',+ dark5: '#1e1e1e',+ expense: '#f92134',+ income: '#2cad22',white1: '#fdfdfd',white2: '#fcfcfd',- income: '#2cad22',- expense: '#f92134',},fontSize: {'2xs': '10px',