Skip to content

Commit 526e23c

Browse files
committed
chore: housekeeping: clean up code and remove unused files
1 parent 1d53a34 commit 526e23c

53 files changed

Lines changed: 1385 additions & 2343 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.vscode/settings.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"i18n-ally.localesPaths": ["i18n/locales"]
3+
}

app/app.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import NProgress from '~/components/NProgress.vue'
2323
import SiteHeader from '~/components/SiteHeader.vue'
2424
import SiteFooter from '~/components/SiteFooter.vue'
2525
import { existsSessionId, initUser } from '~/composables/userData'
26-
import { useUserStore } from '~/stores/session'
26+
import { useUserStore } from '~/composables/session'
2727
2828
const SideNav = defineAsyncComponent(
2929
() => import('~/components/SideNav/SideNav.vue')

app/auto-imports.d.ts

Lines changed: 0 additions & 13 deletions
This file was deleted.

app/components.d.ts

Lines changed: 0 additions & 34 deletions
This file was deleted.

app/components/Artwork/ArtworkCard.vue

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@
5959
<script lang="ts" setup>
6060
import DeferLoad from '../DeferLoad.vue'
6161
import { NSkeleton } from 'naive-ui'
62-
import { IllustType } from '~/utils/constants'
6362
import IFasEye from '~icons/fa-solid/eye'
6463
import IFasHeart from '~icons/fa-solid/heart'
6564
import IFasImages from '~icons/fa-solid/images'

app/components/Artwork/ArtworkLargeCard.vue

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,19 @@
77
:alt='illust.title',
88
:src='illust.url.replace("p0_master", "p0_square")'
99
)
10-
.restrict.x-restrict(aria-label='R-18' role='img' title='R-18' v-if='illust.xRestrict === 2')
10+
.restrict.x-restrict(
11+
aria-label='R-18'
12+
role='img'
13+
title='R-18'
14+
v-if='illust.xRestrict === 2'
15+
)
1116
IFasEye(aria-hidden='true')
12-
.restrict.ai-restrict(aria-label='AI生成' role='img' title='AI生成' v-if='illust.aiType === 2')
17+
.restrict.ai-restrict(
18+
aria-label='AI生成'
19+
role='img'
20+
title='AI生成'
21+
v-if='illust.aiType === 2'
22+
)
1323
IFasRobot(aria-hidden='true')
1424
.page-count(
1525
:title='"共 " + illust.pageCount + " 张"'
@@ -27,15 +37,18 @@
2737
RouterLink(:to='"/artworks/" + illust.id') {{ illust.title }}
2838
.author(:title='illust.userName')
2939
RouterLink(:to='"/users/" + illust.userId')
30-
img.avatar(:alt='illust.userName' :src='illust.profileImageUrl' lazyload)
40+
img.avatar(
41+
:alt='illust.userName',
42+
:src='illust.profileImageUrl'
43+
lazyload
44+
)
3145
| {{ illust.userName }}
3246
.tags
3347
ArtTag(:key='_', :tag='item' v-for='(item, _) in illust.tags')
3448
</template>
3549

3650
<script lang="ts" setup>
3751
import type { ArtworkInfo } from '~/types'
38-
import { IllustType } from '~/utils/constants'
3952
import DeferLoad from '../DeferLoad.vue'
4053
import ArtTag from '../ArtTag.vue'
4154
import IFasEye from '~icons/fa-solid/eye'

app/components/Artwork/ArtworkListByUser.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<script setup lang="ts">
2222
import type { ArtworkInfo } from '~/types'
2323
import { NPagination } from 'naive-ui'
24-
import { useUserArtworksStore } from '~/stores/user-artworks'
24+
import { useUserArtworksStore } from '~/composables/user-artworks'
2525
2626
const props = withDefaults(
2727
defineProps<{

app/components/AuthorCard.vue

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,11 @@
33
.author-inner(v-if='user')
44
.flex-center
55
.left
6-
RouterLink(:to='"/users/" + user.userId' :aria-label='"查看作者: " + user.name')
7-
img(:alt='user.name + " 的头像"' :src='user.imageBig')
6+
RouterLink(
7+
:aria-label='"查看作者: " + user.name',
8+
:to='"/users/" + user.userId'
9+
)
10+
img(:alt='user.name + " 的头像"', :src='user.imageBig')
811
.right
912
.flex
1013
h4.plain
@@ -40,7 +43,7 @@ import type { User } from '~/types'
4043
import { NButton, NEllipsis, NSkeleton } from 'naive-ui'
4144
import IFasCheck from '~icons/fa-solid/check'
4245
import IFasPlus from '~icons/fa-solid/plus'
43-
import { useUserStore } from '~/stores/session'
46+
import { useUserStore } from '~/composables/session'
4447
4548
const userStore = useUserStore()
4649

app/components/Comment/Comment.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ li.comment-block
2525
<script lang="ts" setup>
2626
import stampList from './stampList.json'
2727
import type { Comments } from '~/types'
28-
import { useUserStore } from '~/stores/session'
28+
import { useUserStore } from '~/composables/session'
2929
3030
defineProps<{ comment: Comments }>()
3131
const store = useUserStore()

app/components/Comment/CommentSubmit.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
<script lang="ts" setup>
2020
import Cookies from 'js-cookie'
21-
import { useUserStore } from '~/stores/session'
21+
import { useUserStore } from '~/composables/session'
2222
2323
const store = useUserStore()
2424

0 commit comments

Comments
 (0)