Package Exports
- lm-dialog
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (lm-dialog) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
dialog
- 作者:niuguimin
- 邮箱:15275151030@163.com
- 版本:**
1.0.2**
介绍
组件描述内容
安装
lm-* 组件使用 npm 进行管理,命名空间统一为 lm-,请使用以下命令进行组件安装。
npm i lm-dialog --save- 如果你还没有安装
npm,可通过以下方式进行 安装。 - 安装cnpm
npm install -g cnpm --registry=https://registry.npm.taobao.org
使用
样例文档
- 待开发
使用
最少配置参数为:
- 传入
showState是否显示
<Dialog
showState={false}
title={'提示标题'}
btnOkCbFun={() => {}}
btnCancelCbFun={() => {}}>
提示内容,可以是dom、string等
</Dialog>
配置参数
| Prop | Type | Default | Description |
|---|---|---|---|
header |
boolean |
'' |
顶部是否显示 |
className |
string |
'' |
样式类名 |
showState |
bool |
false |
是否显示 |
opacity |
number |
0.5 |
透明度 |
dialogType |
string |
Confirm |
Alert,Confirm |
title |
node |
undefined |
提示标题 |
content |
node |
undefined |
提示内容 |
btnCancelText |
string |
取消 |
取消按钮 |
btnOkText |
string |
确定 |
确定按钮 |
btnCancelCbFun |
func |
args => args |
取消回调函数 |
btnOkCbFun |
func |
args => args |
确认回调函数 |
onMaskClick |
func |
args => args |
点击遮罩回调 |
注意事项
- 组件注意事项
开发调试
进入项目目录后,使用 node 命令启动服务
npm run start打包发布可通过 node 命令执行
npm run build
npm publish相关资料
Changelog
0.1.0
- init
0.2.1
- 修改dialog默认的样式
0.2.2
- 修改dialog默认的样式,参考cfqm端的样式
0.3.0
- 升级只react16版本
- 遮罩修改为lm-mask
- 根据新的UI规范增加了新的UI样式配置
- 优化了组件内部代码
1.0.0
- 根据新的UI规范更新代码
- 去掉旧版UI
1.0.1
- 遮罩lm-mask版本升级
1.0.2
- 修改dialog的样式