jQuery Mobile教程: 网格

2024-10-15 02:08:51

1、两列布局<div data-role="content"> <p>两列布局:</p> <div class="ui-grid-a"> <div class="ui-block-a"><a href="#" data-role="button">第一列按钮</a><br> <span>第一列:This is some text. This is some text. This is some text. This is some text. This is some text.</span> </div> <div class="ui-block-b"> <a href="#" data-role="button">第二列按钮</a><br> <span>第二列:This is some text. This is some text. This is some text. This is some text.</span> </div> </div> </div>

jQuery Mobile教程: 网格

3、四列布局<div data-role="content"> <p>四列布局:</p> <div class="ui-grid-c"> <div class="ui-block-a"><a href="#" data-role="button">第一列</a><br> <span>第一列:This is some text. This is some text. This is some text. This is some text. This is some text.</span> </div> <div class="ui-block-b"> <a href="#" data-role="button">第二列</a><br> <span>第二列:This is some text. This is some text. This is some text. This is some text.</span> </div> <div class="ui-block-c"> <a href="#" data-role="button">第三列</a><br> <span>第三列:This is some text. This is some text. This is some text. This is some text.</span> </div> <div class="ui-block-d"> <a href="#" data-role="button">第四列</a><br> <span>第四列:This is some text. This is some text. This is some text. This is some text.</span> </div> </div> </div>

jQuery Mobile教程: 网格

5、自定义网格<div data-role="content"> <p>三列样式布局:</p> <div class="ui-grid-b"> <div class="ui-block-a"><span>第一个列</span></div> <div class="ui-block-b"><span>第二个列</span></div> <div class="ui-block-c"><span>第三个列</span></div> </div> </div>

jQuery Mobile教程: 网格
猜你喜欢