You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/toolbars/docs-navbar.html
+8-8Lines changed: 8 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -24,7 +24,7 @@ <h1>Navbar</h1>
24
24
<divclass="content-primary">
25
25
<h2>Simple navbar</h2>
26
26
27
-
<p>jQuery Mobile has a very basic navbar widget that is useful for providing up to 5 buttons with optional icons in a bar, typically within a header or footer. There is also a <ahref="footer-persist-a.html">persistent nav bar</a> variation that works more like a tab bar that stays fixed as you navigate across pages.</p>
27
+
<p>jQuery Mobile has a very basic navbar widget that is useful for providing up to 5 buttons with optional icons in a bar, typically within a header or footer. There is also a <ahref="footer-persist-a.html">persistent navbar</a> variation that works more like a tab bar that stays fixed as you navigate across pages.</p>
28
28
<p>A navbar is coded as an unordered list of links wrapped in a container element that has the <code> data-role="navbar"</code> attribute. To set one of links to the active (selected) state, add <code>class="ui-btn-active"</code> to the anchor. In this example, we have a two-button navbar in the footer with the "One" item set to active:</p>
29
29
30
30
<pre><code>
@@ -154,7 +154,7 @@ <h2>Navbars in footers</h2>
154
154
155
155
<h2>Icons in navbars</h2>
156
156
157
-
<p>Icons can be added to navbar items by adding the <code> data-icon</code> attribute specifying a <ahref="../buttons/buttons-icons.html">standard mobile icon</a> to each anchor. By default icons are added above the text (<code>data-iconpos="top"</code>). The following examples add icons to a navbar in a footer.</p>
157
+
<p>Icons can be added to navbar items by adding the <code> data-icon</code> attribute specifying a <ahref="../buttons/buttons-icons.html">standard mobile icon</a> to each anchor. By default, icons are added above the text (<code>data-iconpos="top"</code>). The following examples add icons to a navbar in a footer.</p>
158
158
159
159
<divdata-role="footer">
160
160
<divdata-role="navbar">
@@ -166,7 +166,7 @@ <h2>Icons in navbars</h2>
166
166
</div><!-- /navbar -->
167
167
</div><!-- /footer -->
168
168
169
-
<p>The icon position is set <em>on the navbar container</em> instead of for individual links within for visual consistency. For example, to place the icons below the labels, add the <code> data-iconpos="bottom"</code> attribute to navbar container.</p>
169
+
<p>The icon position is set <em>on the navbar container</em> instead of for individual links within for visual consistency. For example, to place the icons below the labels, add the <code> data-iconpos="bottom"</code> attribute to the navbar container.</p>
<p>You can add any of the popular icon libraries like <ahref="http://glyphish.com/">Glyphish</a> to achieve the iOS style tab tab that has large icons stacked on top of text labels. All that is required is a bit of custom styles to link to the icons and position them in the navbar. Here is an example using Glyphish icons and custom styles (view page source for styles) in our navbar:</p>
210
+
<p>You can add any of the popular icon libraries like <ahref="http://glyphish.com/">Glyphish</a> to achieve the iOS style tab that has large icons stacked on top of text labels. All that is required is a bit of custom styles to link to the icons and position them in the navbar. Here is an example using Glyphish icons and custom styles (view page source for styles) in our navbar:</p>
211
211
212
212
213
213
<style>
@@ -238,8 +238,8 @@ <h2>Using 3rd party icon sets</h2>
238
238
239
239
<h2>Theming navbars</h2>
240
240
241
-
<p>Navbars inherit the theme swatch from their parent container, just like buttons. If a navbar is placed in header or footer toolbar, it will inherit the default toolbar swatch (A) for bars unless you set this in the markup. </p>
242
-
<p>Here are a few examples of navbars in various container swatches automatically inheriting their parent's swatch letter. Note that in these examples, instead of using a <code>data-theme</code> attribute, we're manually adding the swatch classes to apply the body swatch (<code>ui-body-a</code>) and the class to add the standard body padding (ui-body), but the inheritance works the same way:</p>
241
+
<p>Navbars inherit the theme swatch from their parent container, just like buttons. If a navbar is placed in the header or footer toolbar, it will inherit the default toolbar swatch (A) for bars unless you set this in the markup. </p>
242
+
<p>Here are a few examples of navbars in various container swatches that automatically inheriting their parent's swatch letter. Note that in these examples, instead of using a <code>data-theme</code> attribute, we're manually adding the swatch classes to apply the body swatch (<code>ui-body-a</code>) and the class to add the standard body padding (ui-body), but the inheritance works the same way:</p>
243
243
244
244
<divclass="ui-body-a ui-body">
245
245
<h3>Swatch A</h3>
@@ -267,7 +267,7 @@ <h3>Swatch B</h3>
267
267
</div><!-- /navbar -->
268
268
</div><!-- /container -->
269
269
270
-
<p>To set to the theme color for a navbar item, add the <code>data-theme</code> attribute to the individual links and specify a theme swatch. Note that applying a theme swatch at the navbar container is <em>not</em> supported.</p>
270
+
<p>To set to the theme color for a navbar item, add the <code>data-theme</code> attribute to the individual links and specify a theme swatch. Note that applying a theme swatch to the navbar container is <em>not</em> supported.</p>
0 commit comments