/** * Copyright 2025 Beijing Volcano Engine Technology Co., Ltd. All Rights Reserved. * SPDX-license-identifier: BSD-3-Clause */ import { useMemo } from 'react'; import { Button } from '@arco-design/web-react'; import styles from './index.module.less'; interface IProps { value?: string; onChange: (key: string) => void; options: { label: string; key: string; }[]; } function ButtonRadio(props: IProps) { const { value, onChange, options } = props; const selected = useMemo(() => options.find((item) => item.key === value), [value]) || options?.[0]; const handleClick = (key: string) => { onChange?.(key); }; return (