Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>You can use JQuery UI slide() functions.</p> <p><a href="http://api.jqueryui.com/slide-effect/" rel="nofollow">JQuery UI Slide demo</a></p> <p>Have the wings with a lower z-index in css underneath the base image and hidden.</p> <p>Toggle and slide out the wings with the slide function. The API will let you slide left or right with time delays.</p> <p>A jsFiddle of what you've got would be nice.</p> <p>Update: Here is the <a href="http://jsfiddle.net/uWYzg/2/" rel="nofollow">jsFiddle</a>. I didn't use tables like you did but divs. It looks a bit cleaner I think. Basically the wings start off hidden and the toggle() will show it. I used the UI slider. </p> <p>Html:</p> <pre><code>&lt;div class="angelBox"&gt; &lt;div class="angelBody"&gt; &lt;div class="leftWing wing"&gt;&lt;/div&gt; &lt;div class="rightWing wing"&gt;&lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;br/&gt;&lt;br/&gt; Click on the Blue Box </code></pre> <p>CSS:</p> <pre><code>.angelBox{ margin-left:100px; } .angelBody{ position:relative; width:150px; height:150px; background-color:blue; } .wing{ width:70px; height:50px; background-color:grey; display:none; } .leftWing{ position:absolute; left:-70px; top:50px; } .rightWing{ position:absolute; right:-70px; top:50px; } </code></pre> <p>Javascript:</p> <pre><code>$('.angelBody').click(function(){ $('.leftWing').toggle("slide", { direction: "right" }, 500); $('.rightWing').toggle("slide", { direction: "left" }, 500); }); </code></pre> <p>The elements are absolutely position but they're in a relatively positioned container so you can move the entire 'widget' to wherever you like.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload