feat: add wellbeing preference hide news (#2026)

This commit is contained in:
Alex 2023-04-28 15:38:44 +08:00 committed by GitHub
parent cbba846c4f
commit 5c3b8be055
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 15 additions and 1 deletions

View file

@ -7,6 +7,7 @@ export interface CommonRouteTabOption {
disabled?: boolean
name?: string
icon?: string
hide?: boolean
}
const { options, command, replace, preventScrollTop = false } = $defineProps<{
options: CommonRouteTabOption[]
@ -31,7 +32,7 @@ useCommands(() => command
<template>
<div flex w-full items-center lg:text-lg of-x-auto scrollbar-hide border="b base">
<template
v-for="(option, index) in options"
v-for="(option, index) in options.filter(item => !item.hide)"
:key="option?.name || index"
>
<NuxtLink