瀏覽代碼

fix: change `Switch.props.ref` to optional prop to align with `OriginalSwitch` (#17443)

tags/1.2.0
yusheng chen 7 月之前
父節點
當前提交
dc9194ca00
沒有連結到貢獻者的電子郵件帳戶。
共有 1 個檔案被更改,包括 1 行新增1 行删除
  1. 1
    1
      web/app/components/base/switch/index.tsx

+ 1
- 1
web/app/components/base/switch/index.tsx 查看文件

@@ -20,7 +20,7 @@ const Switch = (
disabled = false,
className,
}: SwitchProps & {
ref: React.RefObject<HTMLButtonElement>;
ref?: React.RefObject<HTMLButtonElement>;
},
) => {
const [enabled, setEnabled] = useState(defaultValue)

Loading…
取消
儲存