mirror of
https://github.com/perfect-panel/ppanel-web.git
synced 2026-02-06 11:40:28 -05:00
♻️ refactor: Simplify node display in subscribe form and remove unused Badge import
This commit is contained in:
parent
ee98e7e513
commit
551135de77
@ -10,7 +10,6 @@ import {
|
||||
AccordionItem,
|
||||
AccordionTrigger,
|
||||
} from '@workspace/ui/components/accordion';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Checkbox } from '@workspace/ui/components/checkbox';
|
||||
import {
|
||||
@ -829,20 +828,11 @@ export default function SubscribeForm<T extends Record<string, any>>({
|
||||
key={node.id}
|
||||
className='flex items-center justify-between gap-3'
|
||||
>
|
||||
<span className='font-medium'>{node.name}</span>
|
||||
<span className='text-muted-foreground'>
|
||||
{node.address}:{node.port ?? '—'}
|
||||
</span>
|
||||
<span className='font-mono text-xs uppercase'>
|
||||
{node.protocol || '—'}
|
||||
</span>
|
||||
<span className='flex flex-wrap justify-end gap-1'>
|
||||
{(node.tags || []).map((tg) => (
|
||||
<Badge key={tg} variant='outline'>
|
||||
{tg}
|
||||
</Badge>
|
||||
))}
|
||||
<span>{node.name}</span>
|
||||
<span>
|
||||
{node.address}:{node.port}
|
||||
</span>
|
||||
<span>{node.protocol}</span>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
|
||||
@ -325,7 +325,6 @@ export default function Content() {
|
||||
<div className='grid grid-cols-2 gap-4 md:grid-cols-3 lg:grid-cols-4 xl:grid-cols-6'>
|
||||
{applications
|
||||
?.filter((application) => {
|
||||
// 检查当前平台是否有下载链接或者有 scheme
|
||||
if (!application.download_link && !application.scheme) return false;
|
||||
return (
|
||||
!!application.download_link?.[platform] || !!application.scheme
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user