use-plus-modal-ns
v1.7.0
Published
高级对话框
Downloads
1
Readme
use use-plus-modal
install
cnpm i use-plus-modal --save
use
type DetailItemProps = {
count?:number
}
const DetailItem = ({count})=>{
return <>{count}</> //1
}
const App = ()=>{
const detailModalRef = usePlusModal<DetailItemProps>(<DetailItem />, {
title: '详情',
footer: false,
});
const onClick = ()=>{
detailModalRef.current.setChldrenProps({count:1})
detailModalRef.current.setVisible(true)
}
return <Button onClick={onClick}>点击弹框</Button>
}
export default App;
更新记录
1.2.0 自定义footer能接收setOkParams的值
1.0.2(2022.11.01) 1.modalRef查看传入childrenProps
1.0.1 (2022.10.26) 1.修改默认宽度为640px 2.modal样式修改
1.0.0 (2022.10.25) 1.初始化