Arkivet
Rethinking the Mobile Web (Yiibu)
An approach to responsive design and mobile web by Yiibu. Slides first and then their proof of concept; their website.
Rethinking the Mobile Web by Yiibu
And a little thing to remember:”move away from device specific break points – connect to content instead”
- Ethan Marcotte
Inspirerende: The Great Discontent
Was intrigued by The Great Discontent website, for their use of responsive images, responsive design and changing images when you scroll down. Deconstructed below!
1. Responsive Images
The main article image is available in several size.
800 x 533 px
1600x1200px
Download the Responsive Images script from github: https://github.com/filamentgroup/Responsive-Images
2. Scrolling changes header image
When you scroll down, the header image changes to an image with different focus. Interesting simple effect achieved by this simple jquery:
(function(){
if( $("html").hasClass("rwd-imgs-lrg") ){ // class set by the responsive images script
var imageUrl = "/-/2012/img/mall/dan-balance.jpg"; // image which that will fade over the original
var threshold = 190; // px scrolled until we fade in
var duration = 500; // fade duration in ms var showing = false;
var heroA = $("article header img");
var heroB = $("<img src='"+imageUrl+"' style='width:100%; position:absolute; display:none;'>");
heroA.wrap("<div style='width:100%; display:inline-block'></div>");
heroA.before( heroB );
$(window).scroll(function(event){
var scroll = parseFloat($(window).scrollTop());
if( !showing && scroll >= threshold ){
heroB.fadeIn( duration );showing = true;
} else if( showing && scroll < threshold ) {
heroB.fadeOut( duration );showing = false;
}
});
}})();
3. Placement of the asides
When viewed on large screens, the layout has three columns. The left and right ones holds the asides.
When viewed on smaller screens, the layout shifts to a one column layout, and the asides is placed inline with captions to the right.
On the smallest screens, the placement of the captions moves below the figure (image/video)
Pixeldotter
På http://www.pixelknete.de/dotter kan man lave lækre prikkede baggrunde.
Sjovt
