mirror of
https://github.com/Hopiu/jquery-mobile.git
synced 2026-03-16 22:10:25 +00:00
65 lines
1.8 KiB
HTML
65 lines
1.8 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<title>jQuery Mobile: Grid Layout</title>
|
|
<link rel="stylesheet" href="../../css/themes/default/" />
|
|
<link rel="stylesheet" href="../../docs/_assets/css/jqm-docs.css" />
|
|
<script src="../../js/jquery.js"></script>
|
|
<script data-main="../../js/jquery.mobile" src="../../external/requirejs/require.js"></script>
|
|
|
|
<script>
|
|
$(function(){
|
|
$(".ui-grid-d a").bind("tap click", function(e){
|
|
$(this).hide();
|
|
$("#log")
|
|
.prepend("<li>"+ e.type +" event; target: "+ e.target.nodeName +"; message: grid '"+$(this).text()+"' hidden</li>")
|
|
.listview("refresh");
|
|
return false;
|
|
}).bind("tap click", false);
|
|
$("#showbtn").bind("tap click", function(e){
|
|
$(".ui-grid-d a").show();
|
|
$("#log")
|
|
.prepend("<li>"+ e.type +" event; target: "+ e.target.nodeName +"; message: show all buttons</li>")
|
|
.listview("refresh");
|
|
}).bind("tap click", false);
|
|
});
|
|
</script>
|
|
</head>
|
|
<body>
|
|
<div data-role="page" data-theme="b" id="jqm-home">
|
|
<div data-role="header">
|
|
<h1>Grid Layout</h1>
|
|
</div>
|
|
|
|
<div data-role="content">
|
|
<p>Touch events on this page will log out below, prepending to the top as they arrive.</p>
|
|
|
|
<div class="ui-grid-d">
|
|
<div class="ui-block-a">
|
|
<a data-role="button" id="btn1" data-theme="b">Button 1</a>
|
|
</div>
|
|
<div class="ui-block-b">
|
|
<a data-role="button" id="btn2" data-theme="b">Button 2</a>
|
|
</div>
|
|
<div class="ui-block-c">
|
|
<a data-role="button" id="btn3" data-theme="b">Button 3</a>
|
|
</div>
|
|
<div class="ui-block-d">
|
|
<a data-role="button" id="btn4" data-theme="b">Button 4</a>
|
|
</div>
|
|
<div class="ui-block-e">
|
|
<a data-role="button" id="btn5" data-theme="b">Button 5</a>
|
|
</div>
|
|
</div>
|
|
|
|
<a data-role="button" id="showbtn">Show all button</a>
|
|
|
|
<ul data-role="listview" id="log">
|
|
|
|
</ul>
|
|
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html>
|