Skip to content

Commit 9e0421c

Browse files
committed
add animated popup example
1 parent 22b8f53 commit 9e0421c

File tree

1 file changed

+23
-4
lines changed

1 file changed

+23
-4
lines changed

source

+23-4
Original file line numberDiff line numberDiff line change
@@ -81197,6 +81197,25 @@ dictionary <dfn dictionary>DragEventInit</dfn> : <span>MouseEventInit</span> {
8119781197
display:none and other display values is not possible.</p>
8119881198
</div>
8119981199

81200+
<div class="example">
81201+
<p>The following is an example of an animated pop-up:</p>
81202+
81203+
<pre><code class="html">&lt;div popup="auto" id="foo">
81204+
A fancy pop-up with no Javascript
81205+
&lt;/div>
81206+
&lt;style>
81207+
[popup] {
81208+
opacity: 0;
81209+
transform: translate(-100px,100px);
81210+
transition: all 1.5s;
81211+
}
81212+
[popup]:open {
81213+
transform: translate(0,0);
81214+
opacity: 1;
81215+
}
81216+
&lt;/style></code></pre>
81217+
</div>
81218+
8120081219
<p>Every element which is not in the <span data-x="attr-popup-none-state">no pop-up state</span>
8120181220
has the following members:</p>
8120281221
<ul>
@@ -81916,22 +81935,22 @@ dictionary <dfn dictionary>DragEventInit</dfn> : <span>MouseEventInit</span> {
8191681935

8191781936
<pre><code class="html">&lt;div popup=auto id="foo">
8191881937
This is a pop-up!
81919-
&lt;div>
81938+
&lt;/div>
8192081939

8192181940
&lt;button popupshowtarget="foo">
8192281941
Show a pop-up
81923-
&lt;button></code></pre>
81942+
&lt;/button></code></pre>
8192481943

8192581944
<p>The following shows how <code data-x="attr-popup-toggle-target">popuptoggletarget</code> can
8192681945
open and close a manual pop-up, which can't be closed with light dismiss:</p>
8192781946

8192881947
<pre><code class="html">&lt;div popup=manual id="foo">
8192981948
This is a pop-up!
81930-
&lt;div>
81949+
&lt;/div>
8193181950

8193281951
&lt;button popuptoggletarget="foo">
8193381952
Show or hide a pop-up
81934-
&lt;button></code></pre>
81953+
&lt;/button></code></pre>
8193581954
</div>
8193681955

8193781956
<p>The <span>pop-up target attributes</span> allow certain types of buttons to show and hide

0 commit comments

Comments
 (0)