</div>
<!-- Quick back to top -->
- <a href="#welcome" class="bs-top">
+ <a href="#" class="bs-top">
Back to top
</a>
}
.visible-sm {
- display: inherit !important;
+ display: block !important;
}
.visible-md {
}
.hidden-md {
- display: inherit !important;
+ display: block !important;
}
.hidden-lg {
- display: inherit !important;
+ display: block !important;
}
@media (min-width: 768px) and (max-width: 991px) {
display: none !important;
}
.visible-md {
- display: inherit !important;
+ display: block !important;
}
.visible-lg {
display: none !important;
}
.hidden-sm {
- display: inherit !important;
+ display: block !important;
}
.hidden-md {
display: none !important;
}
.hidden-lg {
- display: inherit !important;
+ display: block !important;
}
}
display: none !important;
}
.visible-lg {
- display: inherit !important;
+ display: block !important;
}
.hidden-sm {
- display: inherit !important;
+ display: block !important;
}
.hidden-md {
- display: inherit !important;
+ display: block !important;
}
.hidden-lg {
display: none !important;
@media print {
.visible-print {
- display: inherit !important;
+ display: block !important;
}
.hidden-print {
display: none !important;
position: relative;
float: left;
width: 25%;
- height: 43px;
+ padding: 15px 10px;
font-size: 14px;
font-weight: bold;
- line-height: 43px;
+ line-height: 1.1;
color: #999;
text-align: center;
border: 1px solid #ddd;
- -webkit-border-radius: 4px;
- -moz-border-radius: 4px;
- border-radius: 4px;
+ border-radius: 4px;
}
.responsive-utilities-test li + li {
margin-left: 10px;
left: -1px;
right: -1px;
bottom: -1px;
- -webkit-border-radius: 4px;
- -moz-border-radius: 4px;
- border-radius: 4px;
+ padding: 15px 10px;
+ border-radius: 4px;
}
.responsive-utilities-test span {
color: #468847;
margin-bottom: 5px;
}
+/* Hide the top link initially */
+.bs-top {
+ display: none;
+}
/* Responsive variations
/* Back to top link */
.bs-top {
+ display: block; /* Unhide */
float: left;
padding: 7px 15px;
font-weight: 500;
<thead>
<tr>
<th>Class</th>
- <th>Phones <small>767px and below</small></th>
- <th>Tablets <small>979px to 768px</small></th>
- <th>Desktops <small>Default</small></th>
+ <th>Small devices <small>Up to 768px</small></th>
+ <th>Medium devices <small>768px to 979px</small></th>
+ <th>Large devices <small>980px and up</small></th>
</tr>
</thead>
<tbody>
</table>
<h3>When to use</h3>
- <p>Use on a limited basis and avoid creating entirely different versions of the same site. Instead, use them to complement each device's presentation. Responsive utilities should not be used with tables, and as such are not supported.</p>
+ <p>Use on a limited basis and avoid creating entirely different versions of the same site. Instead, use them to complement each device's presentation. Responsive utilities are currently only available for block-level toggling, meaning <code>display: none;</code> or <code>display: block;</code>. Use with inline and table elements is currently not supported.</p>
<h3>Test case</h3>
- <p>Resize your browser or load on different devices to test the above classes.</p>
+ <p>Resize your browser or load on different devices to test the responsive utility classes.</p>
<h4>Visible on...</h4>
- <p>Green checkmarks indicate that class is visible in your current viewport.</p>
+ <p>Green checkmarks indicate the element <strong>is visible</strong> in your current viewport.</p>
<ul class="responsive-utilities-test">
- <li>Phone<span class="visible-sm">✔ Phone</span></li>
- <li>Tablet<span class="visible-md">✔ Tablet</span></li>
- <li>Desktop<span class="visible-lg">✔ Desktop</span></li>
+ <li>Small<span class="visible-sm">✔ Visible on small</span></li>
+ <li>Medium<span class="visible-md">✔ Visible on medium</span></li>
+ <li>Large<span class="visible-lg">✔ Visible on large</span></li>
</ul>
<h4>Hidden on...</h4>
- <p>Here, green checkmarks indicate that class is hidden in your current viewport.</p>
+ <p>Here, green checkmarks indicate the element <strong>is hidden</strong> in your current viewport.</p>
<ul class="responsive-utilities-test hidden-on">
- <li>Phone<span class="hidden-sm">✔ Phone</span></li>
- <li>Tablet<span class="hidden-md">✔ Tablet</span></li>
- <li>Desktop<span class="hidden-lg">✔ Desktop</span></li>
+ <li>Small<span class="hidden-sm">✔ Hidden on small</span></li>
+ <li>Medium<span class="hidden-md">✔ Hidden on medium</span></li>
+ <li>Large<span class="hidden-lg">✔ Hidden on desktop</span></li>
</ul>
</div>
// Visibility utilities
// For Phones
-.visible-sm { display: inherit !important; }
+.visible-sm { display: block !important; }
.visible-md { display: none !important; }
.visible-lg { display: none !important; }
.hidden-sm { display: none !important; }
-.hidden-md { display: inherit !important; }
-.hidden-lg { display: inherit !important; }
+.hidden-md { display: block !important; }
+.hidden-lg { display: block !important; }
// Tablets & small desktops only
@media (min-width: @screen-tablet) and (max-width: @screen-tablet-max) {
.visible-sm { display: none !important; }
- .visible-md { display: inherit !important; }
+ .visible-md { display: block !important; }
.visible-lg { display: none !important; }
- .hidden-sm { display: inherit !important; }
+ .hidden-sm { display: block !important; }
.hidden-md { display: none !important; }
- .hidden-lg { display: inherit !important; }
+ .hidden-lg { display: block !important; }
}
// For desktops
@media (min-width: @screen-desktop) {
.visible-sm { display: none !important; }
.visible-md { display: none !important; }
- .visible-lg { display: inherit !important; }
+ .visible-lg { display: block !important; }
- .hidden-sm { display: inherit !important; }
- .hidden-md { display: inherit !important; }
+ .hidden-sm { display: block !important; }
+ .hidden-md { display: block !important; }
.hidden-lg { display: none !important; }
}
.hidden-print { }
@media print {
- .visible-print { display: inherit !important; }
+ .visible-print { display: block !important; }
.hidden-print { display: none !important; }
}