rebuild docs
This commit is contained in:
@ -605,6 +605,7 @@ var y = e.pageY - btn.offsetTop - btn.offsetParent.offsetTop
|
||||
width: 300px;
|
||||
height: 25px;
|
||||
background: linear-gradient(rgba(255, 255, 255, 0.001), white); /* transparent keyword is broken in Safari */
|
||||
pointer-events: none;
|
||||
}
|
||||
.overflow-scroll-gradient__scroller {
|
||||
overflow-y: scroll;
|
||||
@ -635,6 +636,7 @@ var y = e.pageY - btn.offsetTop - btn.offsetParent.offsetTop
|
||||
width: 300px;
|
||||
height: 25px;
|
||||
bottom: 0;
|
||||
pointer-events: none;
|
||||
}
|
||||
.snippet-demo__overflow-scroll-gradient__scroller {
|
||||
overflow-y: scroll;
|
||||
@ -651,13 +653,14 @@ var y = e.pageY - btn.offsetTop - btn.offsetParent.offsetTop
|
||||
</script>
|
||||
<h4 data-type="Explanation">Explanation</h4>
|
||||
<ol>
|
||||
<li><code>position: relative</code> on the parent establishes a Cartesian positioning context for psuedo elements.</li>
|
||||
<li><code>position: relative</code> on the parent establishes a Cartesian positioning context for psuedo-elements.</li>
|
||||
<li><code>::after</code> defines a pseudo element.</li>
|
||||
<li><code>background-image: linear-gradient(...)</code> adds a linear gradient that fades from transparent to white (top to bottom).</li>
|
||||
<li><code>position: absolute</code> takes the pseudo element out of the flow of the document and positions it in relation to the parent.</li>
|
||||
<li><code>width: 300px</code> matches the size of the scrolling element (which is a child of the parent that has the pseudo element).</li>
|
||||
<li><code>height: 25px</code> is the height of the fading gradient psuedo element, which should be kept relatively small.</li>
|
||||
<li><code>bottom: 0</code> positions the pseudo element at the bottom of the parent.</li>
|
||||
<li><code>height: 25px</code> is the height of the fading gradient psuedo-element, which should be kept relatively small.</li>
|
||||
<li><code>bottom: 0</code> positions the pseudo-element at the bottom of the parent.</li>
|
||||
<li><code>pointer-events: none</code> specifies that the psuedo-element cannot be a target of mouse events, allowing text behind it to still be selectable/interactive.</li>
|
||||
</ol>
|
||||
<h4 data-type="Browser support">Browser support</h4>
|
||||
<div>
|
||||
|
||||
Reference in New Issue
Block a user