ShadowEditor/ShadowEditor.Web/test/ui/22 ModalTest.html
2018-08-01 21:34:58 +08:00

56 lines
1.4 KiB
HTML

<!DOCTYPE html>
<html lang="zh-cn">
<head>
<meta charset="utf-8">
<title>Modal Test</title>
<meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
<link href="../../assets/css/main.css" rel="stylesheet" />
</head>
<body>
<script src="../../node_modules/three/build/three.js"></script>
<script src="../../dist/ShadowEditor.js"></script>
<script>
var control = Shadow.UI.create({
xtype: 'modal',
width: '300px',
height: '200px',
shadeClose: true,
children: [{
xtype: 'row',
children: [{
xtype: 'text',
text: 'Username'
}, {
xtype: 'input',
value: ''
}]
}, {
xtype: 'row',
children: [{
xtype: 'text',
text: 'Password'
}, {
xtype: 'input',
value: ''
}]
}]
});
control.render();
var button = Shadow.UI.create({
xtype: 'button',
text: 'Push me',
onClick: function () {
control.show();
}
});
button.render();
</script>
</body>
</html>