mirror of
https://github.com/ant-design/ant-design.git
synced 2025-01-18 22:36:31 +08:00
tweak code
This commit is contained in:
parent
b16202a329
commit
196566039b
@ -9,21 +9,20 @@
|
||||
````jsx
|
||||
var modal = antd.modal;
|
||||
|
||||
function show(){
|
||||
function show() {
|
||||
modal({
|
||||
width:500,
|
||||
title:'第一个 modal',
|
||||
content: <p>modal content</p>,
|
||||
onCancel:function(){
|
||||
title: '第一个 Modal',
|
||||
content: <p>Modal content</p>,
|
||||
onCancel: function() {
|
||||
alert('cancel');
|
||||
},
|
||||
onOk:function(){
|
||||
alert('ok')
|
||||
onOk: function() {
|
||||
alert('ok');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
React.render(
|
||||
<button onClick={show}>show modal</button>
|
||||
<button onClick={show}>显示对话框</button>
|
||||
, document.getElementById('components-modal-demo-basic'));
|
||||
````
|
||||
|
Loading…
Reference in New Issue
Block a user