mirror of
https://github.com/twbs/bootstrap.git
synced 2025-02-19 16:54:24 +01:00
Merge branch 'responsive-embed' of https://github.com/boulox/bootstrap into boulox-responsive-embed
Conflicts: dist/css/bootstrap.css.map dist/css/bootstrap.min.css
This commit is contained in:
commit
f4dd6221d4
24
dist/css/bootstrap.css
vendored
24
dist/css/bootstrap.css
vendored
@ -5625,6 +5625,30 @@ button.close {
|
||||
.affix {
|
||||
position: fixed;
|
||||
}
|
||||
.embed-responsive {
|
||||
position: relative;
|
||||
display: block;
|
||||
height: 0;
|
||||
padding: 0;
|
||||
overflow: hidden;
|
||||
}
|
||||
.embed-responsive .embed-responsive-item,
|
||||
.embed-responsive iframe,
|
||||
.embed-responsive embed,
|
||||
.embed-responsive object {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
.embed-responsive.embed-responsive-16by9 {
|
||||
padding-bottom: 56.25%;
|
||||
}
|
||||
.embed-responsive.embed-responsive-4by3 {
|
||||
padding-bottom: 75%;
|
||||
}
|
||||
@-ms-viewport {
|
||||
width: device-width;
|
||||
}
|
||||
|
2
dist/css/bootstrap.css.map
vendored
2
dist/css/bootstrap.css.map
vendored
File diff suppressed because one or more lines are too long
2
dist/css/bootstrap.min.css
vendored
2
dist/css/bootstrap.min.css
vendored
File diff suppressed because one or more lines are too long
@ -99,6 +99,7 @@
|
||||
<li><a href="#helper-classes-show-hide">Showing and hiding content</a></li>
|
||||
<li><a href="#helper-classes-screen-readers">Screen reader content</a></li>
|
||||
<li><a href="#helper-classes-image-replacement">Image replacement</a></li>
|
||||
<li><a href="#helper-classes-embeds-responsive">Embeds responsive</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
|
35
docs/assets/js/customize.min.js
vendored
35
docs/assets/js/customize.min.js
vendored
File diff suppressed because one or more lines are too long
17
docs/assets/js/docs.min.js
vendored
17
docs/assets/js/docs.min.js
vendored
File diff suppressed because one or more lines are too long
@ -2576,6 +2576,21 @@ For example, <code><section></code> should be wrapped as inline.
|
||||
.heading {
|
||||
.text-hide();
|
||||
}
|
||||
{% endhighlight %}
|
||||
|
||||
<h3 id="helper-classes-embeds-responsive">Embeds responsive</h3>
|
||||
<p>Allows browsers to determine videos or slideshow dimensions based on the width of their containing block to create an intrinsic ratio that will properly scale on any device.</p>
|
||||
<p>Rules are directly apply to <code><iframe></code>, <code><embed></code> and <code><object></code> elements, optionally use of an explicit descendant class <code>.embed-responsive-item</code> when you want to match the styling for other attributes.</p>
|
||||
{% highlight html %}
|
||||
<!-- 16:9 aspect ratio -->
|
||||
<div class="embed-responsive embed-responsive-16by9">
|
||||
<iframe class="embed-responsive-item" src="…"></iframe>
|
||||
</div>
|
||||
|
||||
<!-- 4:3 aspect ratio -->
|
||||
<div class="embed-responsive embed-responsive-4by3">
|
||||
<iframe class="embed-responsive-item" src="…"></iframe>
|
||||
</div>
|
||||
{% endhighlight %}
|
||||
</div>
|
||||
|
||||
|
2
docs/dist/css/bootstrap.css.map
vendored
2
docs/dist/css/bootstrap.css.map
vendored
File diff suppressed because one or more lines are too long
2
docs/dist/css/bootstrap.min.css
vendored
2
docs/dist/css/bootstrap.min.css
vendored
File diff suppressed because one or more lines are too long
@ -54,3 +54,39 @@
|
||||
.affix {
|
||||
position: fixed;
|
||||
}
|
||||
|
||||
|
||||
// Embeds responsive
|
||||
// -------------------------
|
||||
|
||||
// Credit: Nicolas Gallagher
|
||||
|
||||
.embed-responsive {
|
||||
position: relative;
|
||||
display: block;
|
||||
height: 0;
|
||||
padding: 0;
|
||||
overflow: hidden;
|
||||
|
||||
.embed-responsive-item,
|
||||
iframe,
|
||||
embed,
|
||||
object {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
// Modifier class for 16:9 aspect ratio
|
||||
&.embed-responsive-16by9 {
|
||||
padding-bottom: 56.25%;
|
||||
}
|
||||
|
||||
// Modifier class for 4:3 aspect ratio
|
||||
&.embed-responsive-4by3 {
|
||||
padding-bottom: 75%;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user