代码格式化: prettier --write 统一代码风格
39 个文件按 .prettierrc.json (printWidth 100 / no semi / singleQuote) 统一格式, 纯空白与换行调整, 无逻辑变更。为接入代码门禁做准备, 让 npm run check (format:check + lint:strict + typecheck) 干净通过。
This commit is contained in:
@@ -30,8 +30,12 @@ const {
|
||||
} = useListingCollections()
|
||||
const activeTab = ref(route.query.tab === 'favorites' ? 'favorites' : 'history')
|
||||
const isMobilePage = computed(() => route.path.startsWith('/m/'))
|
||||
const activeItems = computed(() => (activeTab.value === 'favorites' ? favorites.value : history.value))
|
||||
const emptyText = computed(() => (activeTab.value === 'favorites' ? '暂无收藏账号' : '暂无浏览记录'))
|
||||
const activeItems = computed(() =>
|
||||
activeTab.value === 'favorites' ? favorites.value : history.value
|
||||
)
|
||||
const emptyText = computed(() =>
|
||||
activeTab.value === 'favorites' ? '暂无收藏账号' : '暂无浏览记录'
|
||||
)
|
||||
|
||||
async function handleClearHistory() {
|
||||
try {
|
||||
@@ -81,13 +85,21 @@ function timeText(item: ListingCollectionItem) {
|
||||
<h1>我的足迹</h1>
|
||||
<p>找回看过和收藏过的账号。</p>
|
||||
</div>
|
||||
<button v-if="activeTab === 'history' && history.length" type="button" @click="handleClearHistory">
|
||||
<button
|
||||
v-if="activeTab === 'history' && history.length"
|
||||
type="button"
|
||||
@click="handleClearHistory"
|
||||
>
|
||||
清空记录
|
||||
</button>
|
||||
</header>
|
||||
|
||||
<nav class="collection-tabs">
|
||||
<button :class="{ active: activeTab === 'history' }" type="button" @click="activeTab = 'history'">
|
||||
<button
|
||||
:class="{ active: activeTab === 'history' }"
|
||||
type="button"
|
||||
@click="activeTab = 'history'"
|
||||
>
|
||||
浏览记录 <span>{{ history.length }}</span>
|
||||
</button>
|
||||
<button
|
||||
|
||||
Reference in New Issue
Block a user