diff --git a/components.html b/components.html index 885e4fe..a932023 100644 --- a/components.html +++ b/components.html @@ -251,6 +251,40 @@ base_url: "../"

Note: Use push.js to actually change content.

+
+

Tab bar (labels only)

+ +
+ +
+ +{% highlight html %} + +{% endhighlight %} + +

Note: Use push.js to actually change content.

+
+

Standard bars

Standard bars are basic fixed elements that can be positioned in 3 places. These can be used to house buttons or segmented controls (see following examples).

diff --git a/dist/android-theme.css b/dist/android-theme.css index 82b580e..4637e75 100644 --- a/dist/android-theme.css +++ b/dist/android-theme.css @@ -176,7 +176,7 @@ a:active { border-top: 0; } .bar-tab .tab-item .icon { - margin-top: 0; + margin-top: 5px; } .bar-tab .tab-item.active .tab-label, .bar-tab .tab-item.active .icon, .bar-tab .tab-item:active .tab-label, diff --git a/dist/ratchet.css b/dist/ratchet.css index 866bebc..edc21ed 100644 --- a/dist/ratchet.css +++ b/dist/ratchet.css @@ -524,22 +524,22 @@ input[type="button"] { display: table-cell; height: 100%; width: 1%; - vertical-align: bottom; + vertical-align: middle; text-align: center; } .bar-tab .tab-item .tab-label, .bar-tab .tab-item .icon { color: #929292; } -.bar-tab .tab-item .tab-label { - margin-top: -2px; - font-size: 11px; - font-weight: 400; -} .bar-tab .tab-item .icon { width: 24px; height: 24px; - margin-top: 0; + margin-top: 5px; +} +.bar-tab .tab-item .icon ~ .tab-label { + margin-top: -2px; + font-size: 11px; + font-weight: 400; } .bar-tab .tab-item.active .tab-label, .bar-tab .tab-item.active .icon, .bar-tab .tab-item:active .tab-label, diff --git a/docs-assets/css/docs.css b/docs-assets/css/docs.css index 5023d6a..37dca61 100644 --- a/docs-assets/css/docs.css +++ b/docs-assets/css/docs.css @@ -1348,7 +1348,7 @@ hr { border-top: 0; } .platform-android .bar-tab .tab-item .icon { - margin-top: 0; + margin-top: 5px; } .platform-android .bar-tab .tab-item.active .tab-label, .platform-android .bar-tab .tab-item.active .icon, .platform-android .bar-tab .tab-item:active .tab-label, diff --git a/lib/sass/bars.scss b/lib/sass/bars.scss index 104753d..2290448 100644 --- a/lib/sass/bars.scss +++ b/lib/sass/bars.scss @@ -90,7 +90,7 @@ display: table-cell; height: 100%; width: 1%; - vertical-align: bottom; + vertical-align: middle; text-align: center; .tab-label, @@ -98,18 +98,18 @@ color: #929292; } - // Label for tab - .tab-label { - margin-top: -2px; - font-size: 11px; - font-weight: 400; - } - // Tab icon .icon { width: 24px; height: 24px; - margin-top: 0; + margin-top: 5px; + + // Make the label smaller if it's used with an icon + ~ .tab-label { + margin-top: -2px; + font-size: 11px; + font-weight: 400; + } } // Active states for the tab bar diff --git a/lib/sass/theme-android.scss b/lib/sass/theme-android.scss index e60d411..f48973c 100644 --- a/lib/sass/theme-android.scss +++ b/lib/sass/theme-android.scss @@ -259,7 +259,7 @@ a { .tab-item { .icon { - margin-top: 0; + margin-top: 5px; } // Active states for the tab bar