alibaba / ChatUI

The UI design language and React library for Conversational UI
https://chatui.io
MIT License
2.61k stars 277 forks source link

如何禁用 Input Box #127

Closed songbohu closed 2 days ago

songbohu commented 10 months ago

What problem does this feature solve? (这个功能解决了什么问题)

我希望可以选择性的去禁用对话容器中的input box。

Describe the solution you'd like (描述您想要的解决方案)

支持html中的disabled attribute。

What does the proposed API look like? (你期望的 API 是怎样的)

<Chat
  disabled={true}
/>

谢谢

akai commented 2 days ago

传 inputOptions:

  return (
    <Chat
      inputOptions={{ disabled: true }}
    />
  );