mirror of
https://github.com/MetaCubeX/metacubexd.git
synced 2024-11-24 21:55:38 +08:00
21 lines
463 B
TypeScript
21 lines
463 B
TypeScript
import { For } from 'solid-js'
|
|
import { ProxyNodeCard } from '~/components'
|
|
|
|
export const ProxyCardGroups = (props: {
|
|
proxyNames: string[]
|
|
now?: string
|
|
onClick?: (name: string) => void
|
|
}) => {
|
|
return (
|
|
<For each={props.proxyNames}>
|
|
{(proxy) => (
|
|
<ProxyNodeCard
|
|
proxyName={proxy}
|
|
isSelected={props.now === proxy}
|
|
onClick={props.onClick && (() => props.onClick?.(proxy))}
|
|
/>
|
|
)}
|
|
</For>
|
|
)
|
|
}
|