使用React在antDesign中水平折叠边栏
我尝试了以下链接中给出的ant设计崩溃示例。它是垂直工作的。单击箭头时,它应该折叠并水平扩展。
https://ant.design/components/collapse/
从“ antd”导入{崩溃};
const Panel = Collapse.Panel;
const text =
A dog is a type of domesticated animal.
Known for its loyalty and faithfulness,
it can be found as a welcome guest in many households across the world.
;
ReactDOM.render(
<Panel header="This is panel header 1" key="1">
<p>{text}</p>
</Panel>
,
mountNode
);