Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource


Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource


Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.


Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


                <h1>Transición entre dos imágenes arrastrando una barra. (sólo CSS)</h1>

<div id=alfa title="Lucrecia Orloff.">
<div id=bravo title="Anibal Cedrón.">
<textarea readonly class=charly></textarea>

<p>Inspired by <a href="">
Image Swaping</a> and <a href="">
Demo CSS Navigation width Resize</a>.</p>



                #alfa {
background-image: url(; 
width: 640px; height: 480px; 
padding: 0; 
position: relative; 
border-width: 0 20px; 
border-color: black; 
border-style: none groove none ridge; 

#bravo {
background-image: url(; 
height: 480px; 
border-width: 0 20px 0 0; 
border-color: dimgray;
border-style: solid; 
resize: horizontal; 
position: absolute; 
top: 0; left: 0; 
min-width: 0; max-width: 640px; 
-ms-box-sizing: border-box; 
-moz-box-sizing: border-box; 
box-sizing: border-box; 
#bravo:before {
content: '↔'; 
font-size: 20px; 
color: white; 
top: 50%; right: -20px; 
position: absolute; 

resize: horizontal; 
opacity: .01; 
position: relative; 
top: 50%; left: -20px; 
margin-right: -50px; 
border: 2px solid transparent; 
width: 40px; height: 15px; 
max-width: 670px; min-width: 40px; 
outline: 0 solid transparent; 
cursor: ew-resize; 
-webkit-animation-name: delta;
animation-name: delta;
-webkit-animation-duration: 5s;
animation-duration: 5s;
-webkit-animation-iteration-count: 1;
animation-iteration-count: 1; 
-webkit-animation-direction: normal; 
animation-direction: normal; 
-webkit-animation-timing-function: ease-in-out; 
animation-timing-function: ease-in-out; 
-webkit-animation-delay: 3s; 
animation-delay: 3s; 
-webkit-animation: delta 5s 1 normal ease-in-out 3s; 
animation: delta 5s 1 normal ease-in-out 3s; 
@keyframes delta {
  0% {width: 40px; }
  50% {width: 300px; }
  100% {width: 40px; }
@-webkit-keyframes delta {
  0% {width: 40px; }
  50% {width: 300px; }
  100% {width: 40px; }