<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Tangled in Design</title>
	
	<link>http://www.tangledindesign.com/blog</link>
	<description>Web Development and Graphic Design</description>
	<lastBuildDate>Fri, 03 Aug 2012 12:01:46 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/tangledindesign" /><feedburner:info uri="tangledindesign" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>An Introduction to CSS3 Animation… with Gary Neville</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/YNxxSES2ugE/</link>
		<comments>http://www.tangledindesign.com/blog/an-introduction-to-css3-animation-with-gary-neville/#comments</comments>
		<pubDate>Fri, 03 Aug 2012 11:52:36 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[CSS3 Animation]]></category>
		<category><![CDATA[CSS3 Transforms]]></category>
		<category><![CDATA[CSS3 Transitions]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1434</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/an-introduction-to-css3-animation-with-gary-neville/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/08/featured.jpg" class="alignleft tfe wp-post-image" alt="featured" title="featured" /></a>We&#8217;re going to look at the basics of creating keyframe based animation using CSS3, including all of the various properties we can use to control the animation&#8217;s behaviour. And to finish, we&#8217;ll look at a real life application of CSS &#8230; <a href="http://www.tangledindesign.com/blog/an-introduction-to-css3-animation-with-gary-neville/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>We&#8217;re going to look at the basics of creating keyframe based animation using CSS3, including all of the various properties we can use to control the animation&#8217;s behaviour. And to finish, we&#8217;ll look at a real life application of CSS animation.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-animation/basic"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/08/6.jpg" alt="View Basic Demo" title="Basic Demo" class="alignleft post-img" /></a></p>
<p><a href="http://garynevillegasm.com/"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/08/5.jpg" alt="View Nev Demo" title="Nev Demo" class="alignleft post-img" /></a></p>
<div class="clearfix"></div>
<h4>Unnecessary Background Reading</h4>
<p>If you&#8217;re not a little intrigued as to how Gary Neville has found himself in a CSS blog post title, then feel free to skip this section and read on. What&#8217;s that&hellip; you&#8217;d love to know? Well okay, if you insist&hellip;</p>
<p>Football fans will recall his moment of &#8216;excitement&#8217; when Fernando Torres rounded Victor Valdes and knocked the ball into the net to seal Chelsea&#8217;s shock victory against Barcelona in this years Champions League semi final.</p>
<p>Well, Nev&#8217;s reaction didn&#8217;t go unnoticed by the internet&#8217;s millions. In fact, 2 guys from my work (big up <a href="https://twitter.com/mitchellbush">Mitch</a> and <a href="https://twitter.com/seanpb">Sean</a>) dropped me an email the following day asking if I wanted to knock something together to go on the new domain they&#8217;d just bought&#8230; <a href="http://garynevillegasm.com/">garynevillegasm.com</a>. And so it began.</p>
<h3>The Basics</h3>
<p>Okay, so Gary Neville&#8217;s only really here to provide a real life example of where CSS3 animation has been used &#8211; we need to get to grips with the basics first.</p>
<h4>Defining the keyframes</h4>
<p>As with most animation, CSS3 animation works on a keyframe basis. This removes the limitations we have with CSS transitions, as they only animate from one state to another; for example from a blue normal state to a red hover state. With keyframe animation we can animate from one state to another to another and so on.</p>
<p>We define when each state change will happen using percentages. Let&#8217;s see how this works with an example of a box moving around four corners of a page, changing colours as it travels to each corner.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-animation/basic"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/08/3.jpg" alt="View Basic Demo" title="Basic Demo" class="alignleft full-width-img" /></a><a href="http://www.tangledindesign.com/blog/demos/css3-animation/basic"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png" alt="View Demo" title="View Demo" class="demo-btn alignleft" /></a><a href="http://www.tangledindesign.com/blog/demos/css3-animation/basic/main.css"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/css-button.png" alt="View CSS" title="View CSS" class="demo-btn alignleft" /></a></p>
<p>There are 4 state changes to define, so here&#8217;s how we do it &hellip;</p>
<pre>
<code>@keyframes square {
	
    0% {
        top:0;
        left:0;
        background:blue;
    }
	
    25% {
        top:300px;
        left:0;
        background:red;
    }
	
    50% {
        top:300px;
        left:600px;
        background:green;
    }
	
    75% {
        top:0;
        left:600px;
        background:yellow;
    }
	
}</code>
</pre>
<p>It&#8217;s important to note that the exact code above will not work in any browser at the time of writing, as the only current support requires vendor pre-fixes. <code>-moz-</code> and <code>-webkit-</code> provide support for Firefox, Chrome and Safari in this case.</p>
<p>In the annotated image below, you can see exactly what each keyframe does.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/08/1.jpg" alt="Annotated CSS3 Animation Code" title="Annotated CSS3 Animation Code" class="alignleft full-width-img" /></p>
<h4>Applying the Animation to an Element</h4>
<p>Now we&#8217;ve created a set of keyframes, we need to apply the animation to an element. We do this by simply using the various <code>animation</code> properties on the element(s) we want to animate, like so&hellip;</p>
<pre>
<code>.box {
    /* Your list of animation properties */
}</code>
</pre>
<p>So what are these animation properties/controls?</p>
<ul>
<li><code>animation-name</code> &#8211; The name of your animation. Must correspond with name given in <code>@keyframes</code> rule; in this case, &#8216;square&#8217;.</li>
<li><code>animation-duration</code> &#8211; How long the animation should last from start to finish. Defined in seconds or milliseconds; e.g. <code>5ms</code> or <code>0.5s</code>.</li>
<li><code>animation-timing-function</code> &#8211; Describes the varied acceleration of the animation; it denotes <em>where</em> the animation speeds up and slows down over the specified duration of the transition. E.g. <code>ease</code> or <code>linear</code>. See my <a href="http://www.tangledindesign.com/blog/css3-transitions-the-transition-timing-function-property-explained/">previous article</a> for more on the timing-function property.</li>
<li><code>animation-iteration-count</code> &#8211; How many times the animation repeats from start to finish. This can be any numerical value or the <code>infinite</code> keyword, which loops the animation forever!</li>
<li><code>animation-direction</code> &#8211; A value of <code>normal</code> (the default value) would play the animation from start to finish. The other value of <code>alternate</code> would play the animation forwards then backwards for animations with an iteration count of 2 or more.</li>
<li><code>animation-delay</code> &#8211; Only plays the animation after a set amount of time. For example, a value of <code>5s</code> would cause the animation to begin 5 seconds after the page has loaded.</li>
<li><code>animation-play-state</code> &#8211; The default value is <code>running</code> which plays the animation normally; the other keyword is <code>paused</code> which &#8211; well, pauses the animation. If you take another look at my <a href="http://tangledindesign.com/blog/demos/css3-animation/basic">demo</a>, I have set the <code>animation-play-state</code> property to paused when the box is hovered.</li>
</ul>
<p>This seems like a lot of bytes to simply apply an animation to an element, right? Well, thankfully, we can use the shorthand version to vastly reduce it. The only required properties are <code>animation-name</code> and <code>animation-duration</code>.</p>
<pre>
<code>.box {
    animation:square 10s infinite;
}

/* To pause the animation when the box is hovered... */
.box:hover {
    animation-play-state:paused;
}</code>
</pre>
<p>An important note &#8211; for simplicity, all of my code examples above are un-prefixed, but in order for animations to work at the moment, they must have the appropriate vendor prefixes. For example <code>@-webkit-keyframes</code> and <code>-webkit-animation</code>.</p>
<h3>Using CSS3 Animation in the real world&hellip; on Gary Neville</h3>
<p>When it came to making Gary Neville as animated as his voice, there was only one thing for it &#8211; CSS3! Not just animation though &#8211; the use of other CSS3 capabilities such as <a href="http://www.tangledindesign.com/blog/get-the-ball-rolling-with-css3-transitions/">transitions</a> and <a href="http://www.tangledindesign.com/blog/enhancing-thumb-galleries-css3-transitions-transforms/">transforms</a> go some way to showing just what can now be achieved with a few lines of CSS.</p>
<p><a href="http://garynevillegasm.com/"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/08/4.jpg" alt="View Nev Demo" title="Nev Demo" class="alignleft full-width-img" /></a></p>
<p>Nev starts out pretty small when the page first loads (the <em>image</em> of Nev of course&hellip; take your dirty mind elsewhere!). Then, when the user inevitably hovers over the image, he springs into life, as we use a transition to animate the image to its full scale.</p>
<p><small>Don&#8217;t forget to click on the image too and make sure you&#8217;re volume&#8217;s turned up!</small></p>
<pre>
<code>img {
    transform:scale(0.6);
    opacity:0.7;
    transition:all 0.6s ease;
}

img:hover {
    transform:scale(1);
    opacity:1;
}</code>
</pre>
<p>Remember, with transitions, we can only animate from one state to another; in this case, from the small image to the full size image. But now he&#8217;s full size, we need to shake him rigorously from side to side in order to really put across his <em>excitement</em>. A transition isn&#8217;t quite powerful enough for this, so now we need to call upon keyframe animation!</p>
<p>In order to shake Nev, we need to move and rotate him slightly from side to side. We can use CSS3 transforms to do the maneuveral work for each keyframe and allow the animation to do the tweening between each frame.</p>
<pre>
<code>@keyframes nev {
    0% { -webkit-transform: translate(5px, 0); }
    25% { -webkit-transform: translate(-5px, 0) rotate(-10deg); } 
    50% { -webkit-transform: translate(5px, 0) rotate(10deg); } 
    75% { -webkit-transform: translate(-5px, 0) rotate(-10deg); } 
    100% { -webkit-transform: translate(5px, 0) rotate(10deg); }   
}

/* Don't forget vendor prefixes!! */</code>
</pre>
<p>Now we have our keyframes, we need to apply them to the image&#8217;s hover state using our various animation properties.</p>
<p>As described earlier, we used a transition lasting 0.6 seconds to scale the image to its full size on hover, so we don&#8217;t really want the animation to begin until the intial transition has finished. Step forward the <code>animation-delay</code> property. All we have to do is set the value to 0.6s and the animation will not begin until the first transition has finished.</p>
<pre>
<code>img:hover {
    transform:scale(1);
    opacity:1;
    animation-name:nev;
    animation-duration:0.5s;
    animation-timing-function:ease;
    animation-delay:0.6s;
    animation-iteration-count:infinite;
}</code>
</pre>
<p>With the above, we&#8217;ve set our animation to apply to the image on hover after 0.6 seconds with a duration of 0.5 seconds which will loop an infinite number of times. But don&#8217;t forget, we don&#8217;t need all that code! We can just as easily shorten all of the animation controls to one line of code: <code>animation:nev 0.5s ease 0.6s infinite</code>.</p>
<p>And with that, Gary Neville becomes <em>almost</em> as animated as the sound he makes when the image is clicked.</p>
<h3>Conclusion</h3>
<p>I seem to conclude every one of my posts on CSS3 the same way&hellip; with a warning.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/08/2.jpg" alt="Animate all the things!" title="Animate all the things!" class="alignleft full-width-img" /></p>
<p>It&#8217;s understandable that people want to play with new toys, but it must be done with caution, for progressive enhancement and not for vital functionality.</p>
<p>Be subtle and use where appropriate.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/an-introduction-to-css3-animation-with-gary-neville/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/an-introduction-to-css3-animation-with-gary-neville/</feedburner:origLink></item>
		<item>
		<title>Using CSS3 Filters to Enhance your Transitions</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/vhH-vMmb298/</link>
		<comments>http://www.tangledindesign.com/blog/using-css3-filters-to-enhance-your-transitions/#comments</comments>
		<pubDate>Wed, 06 Jun 2012 11:53:04 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[CSS3 Filters]]></category>
		<category><![CDATA[CSS3 Transitions]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1382</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/using-css3-filters-to-enhance-your-transitions/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/featured.jpg" class="alignleft tfe wp-post-image" alt="featured" title="featured" /></a>CSS3 Filters are a pretty exciting prospect for us Web Designers as they make effects that we typically associate with Photoshop, possible to apply in the browser with ease. Assuming across-the-board support eventually arrives, we can wave goodbye to countless &#8230; <a href="http://www.tangledindesign.com/blog/using-css3-filters-to-enhance-your-transitions/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/featured.jpg" alt="featured" title="featured" class="alignleft post-img" />CSS3 Filters are a pretty exciting prospect for us Web Designers as they make effects that we typically associate with Photoshop, possible to apply in the browser with ease. Assuming across-the-board support eventually arrives, we can wave goodbye to countless annoying sprites for simple hover effects and instead, replace this tedious process with a single line of simple CSS.</p>
<p>The basic filters as listed in the <a href="https://dvcs.w3.org/hg/FXTF/raw-file/tip/filters/index.html" title="CSS3 Filters Draft">W3C Draft</a> are as follows: <code>grayscale</code>, <code>sepia</code>, <code>saturate</code>, <code>hue-rotate</code>, <code>invert</code>, <code>opacity</code>, <code>brightness</code>, <code>contrast</code>,<code>blur</code>, <code>drop-shadow</code>, <code>custom</code>.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/14.jpg" alt="Basic CSS3 Filters" title="Basic CSS3 Filters" class="alignleft post-img" /></a><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png" alt="View Demo" title="View Demo" class="demo-btn alignleft" /></a><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/main.css"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/css-button.png" alt="View CSS" title="View CSS" class="demo-btn alignleft" /></a></p>
<div class="clearfix"></div>
<p>We can combine these filters together and use them with other CSS3 properties like <code>transform</code> and <code>animate</code> to create even more interesting transitions.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/combining-css3-filters"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/15.jpg" alt="Combining CSS3 Filters" title="Combining CSS3 Filters" class="alignleft post-img" /></a><a href="http://www.tangledindesign.com/blog/demos/css3-filters/combining-css3-filters"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png" alt="View Demo" title="View Demo" class="demo-btn alignleft" /></a><a href="http://www.tangledindesign.com/blog/demos/css3-filters/combining-css3-filters/main.css"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/css-button.png" alt="View CSS" title="View CSS" class="demo-btn alignleft" /></a></p>
<div class="clearfix"></div>
<h3>Support</h3>
<p>Support is very limited at the time of writing, with Chrome currently the only browser with support for CSS3 filters, so anything other than experimental usage should be done with caution.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/13.jpg" alt="CSS3 Filters Browser Support" title="CSS3 Filters Browser Support" class="full-width-img alignleft" /><br />
Having said that, with Chrome recently surpassing IE as the world&#8217;s most used browser, you can be confident that a sizeable chunk of your audience will see the benefits of your CSS3 filters if you do decide to experiment with them.</p>
<p>As with most of the new CSS3 properties, as long as we use them with caution to enhance the user experience and not to compromise the functionality of the site, you can feel free to use them right now.</p>
<h3>Using CSS3 Filters to Enhance your Image Galleries</h3>
<p>We&#8217;re going to take a look at how we can use these new filters to improve the UX for a simple image gallery.</p>
<h4>Grayscale</h4>
<p>Grayscale is a very basic effect that I think we would see a lot more of if we could achieve it with a single line of CSS rather than having to use a sprite image.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/index.html#gal-one"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/1.jpg" alt="Grayscale CSS3 Filter" title="Grayscale CSS3 Filter" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img {
    -webkit-filter:grayscale(1);
}

img:hover {
    -webkit-filter:grayscale(0);
}</code>
</pre>
<p>As simple as that! Just one line needed to apply the filter; in this case, <code>grayscale</code> uses a scale of 0-1 to specify the strength of the filter. The above code applies a full grayscale effect to the image and restores the image&#8217;s full colour on hover. The demo uses a simple CSS3 transition effect to complete the effect.</p>
<h4>Saturate</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/index.html#gal-two"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/2.jpg" alt="Saturate CSS3 Filter" title="Saturate CSS3 Filter" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img {
    -webkit-filter:saturate(4);
}

img:hover {
    -webkit-filter:saturate(1);
}</code>
</pre>
<p>The <code>saturate</code> filter has a starting value of 1, below which it de-saturates, creating a grayscale effect and above which it starts to saturate the colours in the image. The above demo strongly over-saturates the images to make the hover effect stronger.</p>
<h4>Sepia</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/index.html#gal-three"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/3.jpg" alt="Sepia CSS3 Filter" title="Sepia CSS3 Filter" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img {
    -webkit-filter:sepia(1);
}

img:hover {
    -webkit-filter:sepia(0);
}</code>
</pre>
<p>The above code applies the classic sepia filter, which operates on a scale of 0-1 to determine its strength, similarly to the grayscale filter.</p>
<h4>Hue Rotate</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/index.html#gal-four"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/4.jpg" alt="Hue Rotate CSS3 Filter" title="Hue Rotate CSS3 Filter" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img:hover {
    -webkit-filter:hue-rotate(360deg);
}</code>
</pre>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/16.jpg" alt="Colour Wheel" title="Colour Wheel" class="post-img alignleft" />The <code>hue-rotate</code> filter is applied a little differently to the others as it is specified in degrees. This may seem strange at first, but when you picture a colour wheel, it soon becomes easy enough to visualise the hue value in terms of its position in a circle. The above code (when used with a transition) simply sends the hue value all the way round the colour wheel on hover. The best way to understand this effect is to take a look at the demo above.</p>
<h4>Invert</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/index.html#gal-five"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/5.jpg" alt="Invert CSS3 Filter" title="Invert CSS3 Filter" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img {
    -webkit-filter:invert(1);
}

img:hover {
    -webkit-filter:invert(0);
}</code>
</pre>
<p>The <code>invert</code> filter isn&#8217;t the most aesthetically pleasing in its basic usage, but it could be useful when combined with other filters or with black and white images.</p>
<h4>Brightness</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/index.html#gal-six"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/6.jpg" alt="Brightness CSS3 Filter" title="Brightness CSS3 Filter" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img {
    -webkit-filter:brightness(-0.5);
}

img:hover {
    -webkit-filter:brightness(0);
}</code>
</pre>
<p>The <code>brightness</code> filter can be effective at making certain elements on a page stand out amongst their surroundings. A value of 1 is equivalent to 100% brightness (white) whereas -1 is complete darkness. In the example above, we&#8217;ve used a negative value to darken the gallery images, allowing the hovered image to stand out even more.</p>
<h4>Contrast</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/index.html#gal-seven"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/7.jpg" alt="Contrast CSS3 Filter" title="Contrast CSS3 Filter" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img {
    -webkit-filter:contrast(0.3);
}

img:hover {
    -webkit-filter:contrast(1);
}</code>
</pre>
<p>The <code>contrast</code> filter uses the value 1 to specify a neutral contrast, with the effect increasing or decreasing along with this value. In the above example, we&#8217;ve used a low value to ceate a low-contrast effect in order to make the hover effect stronger.</p>
<h4>Blur</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/basic-css3-filters/index.html#gal-eight"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/8.jpg" alt="Blur CSS3 Filter" title="Blur CSS3 Filter" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img {
    -webkit-filter:blur(2px);
}

img:hover {
    -webkit-filter:blur(0);
}</code>
</pre>
<p>The <code>blur</code> filter is defined differently to the other filters as it uses pixel units to determine the strength of the blur, with 0 as its base value.</p>
<h3>Combining CSS3 Filters to Enhance your Image Galleries</h3>
<p>If we use our imaginations we can create any number of impressive techniques by using the various filters together and by combining filters with other CSS3 properties like <code>transform</code> and <code>animate</code>.</p>
<p>Here are just a few examples&hellip;</p>
<h4>Hue-rotate and Animate</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/combining-css3-filters/index.html#gal-one"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/9.jpg" alt="CSS3 Filter CSS3 Animation" title="CSS3 Filter CSS3 Animation" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>@-webkit-keyframes hue { 
    100% { -webkit-filter:hue-rotate(360deg); }  
}

img:hover {
    -webkit-animation:hue 1s linear infinite;
}</code>
</pre>
<p>This example combines the <code>hue-rotate</code> filter with CSS3 animation to send the hovered image on an infinite loop around the colour wheel.</p>
<h4>Blur, Grayscale and Transform (Scale)</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/combining-css3-filters/index.html#gal-two"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/10.jpg" alt="Blur, Grayscale and Transform (Scale)" title="CSS3 Blur, Grayscale and Transform (Scale)" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img { 
    -webkit-filter:grayscale(1) blur(2px); 
}

img:hover {
    -webkit-transform:scale(1.3);
    -webkit-filter:grayscale(0) blur(0);
}</code>
</pre>
<p>In the example above, we&#8217;ve brought in the <code>transform</code> property to give our hovered image a bit more emphasis. The <code>blur</code> filter also helps focus our attention on the un-blurred, hovered image.</p>
<h4>Sepia, Brightness and Opacity</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/combining-css3-filters/index.html#gal-three"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/11.jpg" alt="Sepia, Brightness and Opacity" title="Sepia, Brightness and Opacity" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img { 
    -webkit-filter:sepia(1) brightness(-0.2) opacity(0.6);
}

img:hover {
    -webkit-filter:sepia(0) brightness(0) opacity(1);
}</code>
</pre>
<p>The above combination of filters help to create a nice, subtle and understated gallery.</p>
<h4>Grayscale and Brightness</h4>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-filters/combining-css3-filters/index.html#gal-four"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/06/12.jpg" alt="Grayscale and Brightness" title="Grayscale and Brightness" class="full-width-img alignleft" /></a></p>
<h5>The Code</h5>
<pre>
<code>img { 
    -webkit-filter:grayscale(1) brightness(-0.4);
}

img:hover {
    -webkit-filter:grayscale(0) brightness(0);
}</code>
</pre>
<p>Again, the <code>grayscale</code> and <code>brightness</code> filters really help to bring out the hovered image and focus our full attention on it.</p>
<h3>Conclusion</h3>
<p>So there we have it, another taste of the sheer power of CSS3 and what can be achieved with it.</p>
<p>Just remember what we said earlier; consider how you&#8217;re using these filters. Are they detrimental to the functionality of your site or are they simply enhancing the appearance of existing functions?</p>
<p>Progressive enhancement is the way forward and as long as you&#8217;re applying this technique, I see no reason why you can&#8217;t treat your Chrome users to some CSS3 filters right now. Proceed with caution.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/using-css3-filters-to-enhance-your-transitions/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/using-css3-filters-to-enhance-your-transitions/</feedburner:origLink></item>
		<item>
		<title>From Concept to Live in 8 Days: Messi Vs Ronaldo</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/ri5owO_hWuk/</link>
		<comments>http://www.tangledindesign.com/blog/from-concept-to-live-in-8-days-messi-vs-ronaldo/#comments</comments>
		<pubDate>Thu, 03 May 2012 12:47:41 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[Football]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[SEO]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1345</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/from-concept-to-live-in-8-days-messi-vs-ronaldo/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/featured.jpg" class="alignleft tfe wp-post-image" alt="featured" title="featured" /></a>A couple of weeks ago, I was watching some Spanish football (the Madrid derby to be precise) &#8211; Cristiano Ronaldo banged in yet another hat-trick for his club and soon my train of thought was mulling over the sheer amount &#8230; <a href="http://www.tangledindesign.com/blog/from-concept-to-live-in-8-days-messi-vs-ronaldo/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/featured.jpg" alt="featured" title="featured" class="post-img alignleft" />A couple of weeks ago, I was watching some Spanish football (the Madrid derby to be precise) &#8211; Cristiano Ronaldo banged in yet another hat-trick for his club and soon my train of thought was mulling over the sheer amount of goals that Ronaldo and his Barcelona rival Messi keep on scoring for their respective clubs.</p>
<p>Naturally, I wanted to know who was currently on top. Obviously, the Spanish league scoring charts were easy to come across, but then I wanted to know who was ahead in the Champions League &#8211; and then I wondered who was on top in all competitions &#8211; then I wanted to know who has assisted more goals this season.</p>
<h4>What I found</h4>
<p>Surprisingly, I found it was quite an effort to come across this information. For a subject with so much coverage and so much public interest, I was quite astounded that there didn&#8217;t appear to be an up-to-date, statistical comparison of the 2 players, considering that their battle for top scorer is constantly back-and-forth and something that a considerable number of people like to keep their eyes on throughout the season.</p>
<p>I could access all of the data through several different sites and pages showing the various goals and assists charts&hellip; and I could read hundreds of articles comparing the 2 masters. But crucially, these comparisons are out-of-date and are very text heavy.</p>
<p>All I wanted was a snapshot of their head to head statistics at this moment in time and surprisingly, that wasn&#8217;t very attainable. And thus, my idea was born.</p>
<p><a href="http://messivsronaldo.net/"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/visit.jpg" alt="Visit Site" title="Visit Site" class="full-width-img" /></a></p>
<h4>So what next?</h4>
<p>I had a very thorough look through the results returned by Google for &#8216;Messi Vs Ronaldo&#8217;, which only really confirmed what I had first thought. Some really good write-ups of their abilities and their goal-hauls, but all of which contain what is now out-of-date information.</p>
<p>I thought, as it&#8217;s something that is of particular interest to me and with the potential it has to generate some decent traffic, it would be worth chucking something together and seeing how it gets on.</p>
<p>With just over a week until the players&#8217; clubs met in the famous El Classico clash, I set myself a challenge to get something launched in time for this match.</p>
<h3>The Concept: Day 1</h3>
<p>I had been mulling over the idea for a few days by now, so I already had a pretty clear image in my head that I wanted to achieve. I [very] roughly sketched out my concept onto some paper, which you can see below &#8211; bear in mind though that my sketches are very rough (crap) and are just to give me something visual to work from!</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/concept.jpg" alt="Messi Vs Ronaldo Concept" title="Messi Vs Ronaldo Concept" class="post-img" /></p>
<p>The basic concept was to give people a quick reference point for the main stats of the 2 players, such as goals, assists and appearances in each competition in order for people to quickly see who&#8217;s currently on top.</p>
<p>Then I had (and am still having) more and more ideas for additional data avaiable below the fold, should users want to scroll down to see it. These include the achievements of the 2 players in terms of trophies won (both club and personal) and a head-to-head comparison of their abilities.</p>
<h3>The Design: Day 1</h3>
<p>I spent an entire night tackling the design of the project, attempting to transfer my paper concept into Photoshop. The most time consuming aspect was creating a background I was happy with, but I was eventually able to design everything I needed in the few hours I had available.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/MvsR1.jpg" alt="Photoshop Design" title="Photoshop Design" class="full-width-img" /><br />
I designed only the top area to define the look and style of the site, with the sections that followed below simply being created in the browser.</p>
<h3>Coding: Day 2 &#8211; 7</h3>
<p>I sailed through the coding of the site, probably because I had written half of the mark-up in my head as I was designing it. I did my best to stay as semantic as possible despite the unorthodox layout&hellip;</p>
<p><small>Note: It didn&#8217;t <em>actually</em> take all that time to code &#8211; I worked on it on and off when I got chance during that time.</small></p>
<p>An easy method that will go <em>some</em> way to judging the semantic value of your markup is to disable the CSS. Does the content still make sense? Is there still a clear hierarchy of importance?</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/3.jpg" alt="Semantic Markup" title="Semantic Markup" class="full-width-img" /></p>
<p>As you can see, the headers and list elements used ensure that the context of the data is maintained without any styling, going some way to proving the semantic value of the code.</p>
<p>You may notice the sub-headers (&#8216;Lionel Messi Stats&#8217; etc.) that are set to <code>display:none</code> when CSS in enabled. I feel it is important that your markup makes absolute sense when it is completely abstracted from the CSS that styles it; in this case, the styling makes it obvious which stats belong to who, but take that styling away and there are no visual clues whatsoever, so the extra headings are required.</p>
<p>This also ensures that each of the statistic blocks (like the one shown above) makes sense when taken out of the context of the rest of the page; I therefore felt it appropriate and semantic to make use of the HTML5 <code>&lt;article&gt;</code> element rather than <code>&lt;section&gt;</code> or <code>&lt;div&gt;</code>, as the data makes sense on its own and doesn&#8217;t require surrounding content to support it.</p>
<h4>Making My Life Easier</h4>
<p>Manually updating this thing after each match is tasking enough as it is, but having to scroll through all the code and pin-point the correct number to edit each time is just not even worth doing. With the lack of a reliable football stats API I could use (to my knowledge), I simply made use of PHP variables to make maintaining the project a million times easier.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/4.jpg" alt="PHP Variables" title="PHP Variables" class="full-width-img" /><br />
Above, you can see we simply echo the PHP variables that are defined at the top of the page in the appropriate place.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/5.jpg" alt="PHP Variables" title="PHP Variables" class="full-width-img" /><br />
This method allows the appropriate statistic to be easily and instantly accessed, making the project a much more maintainable one. Another slight time saver was to make the All Competitions statistics calculate automatically by simply adding the values from each competition and outputting the result.</p>
<p>If anyone knows of a better way to go about this, then I&#8217;d love to hear about it.</p>
<h3>Research &#8211; Day 7-8</h3>
<p>I spent the last day and a half researching all of the statistics &amp; achievements/honours to input and writing up the abilities comparisons, which proved rather time consuming.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/6.jpg" alt="" title="Honours" class="full-width-img" /><br />
<img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/7.jpg" alt="" title="Abilities" class="full-width-img" /></p>
<h3>Live &#8211; Day 8</h3>
<p>Eight days after putting my concept on paper, the site was live &#8211; just in time for El Clasico (Barcelona Vs. Real Madrid) the following night. I was very pleased with the substantial piece of work I&#8217;d managed to put together in such a short space of time, but the work has continued since putting the site live, with several additions &amp; improvements being added.</p>
<h4>Embedded YouTube Videos</h4>
<p>I wanted to provide visual evidence to back up my opinions on the players&#8217; abilities, so decided to embed YouTube videos into the site, through the help of iframes and fancybox to optimise the user experience.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/8.jpg" alt="YouTube iframe" title="YouTube iframe" class="full-width-img" /></p>
<h4>Facebook Comments</h4>
<p>It <a href="https://twitter.com/#!/IanHumph/status/195264544325636096">had been suggested</a> that adding a &#8216;Have your say&#8217; option could make the site more interactive and encourage discussion, which in turn would increase the site&#8217;s reach on Facebook.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/05/9.jpg" alt="Facebook Comments" title="Facebook Comments" class="full-width-img" /></p>
<h3>Performance</h3>
<p>I made a half-hearted attempt to promote the site, posting it on Facebook and Twitter, submitting it to some CSS galleries and one or two relevant forums.</p>
<p>The response was good, but my main aim was to make the site self-sustainable in terms of generating hits, i.e. generating traffic through searches rather than having to constantly promote it and/or rely on people sharing it.</p>
<p>Last week, it sat somewhere on the 2nd page of Google for &#8216;Messi Vs Ronaldo&#8217; &#8211; as of this writing, it has now moved up to 2nd on page one. Yesterday, I had 68 visitors from that search term and so far today (13:00), I&#8217;ve had 62 from that term, so it does seem to be ever-improving in terms of performance so far.</p>
<h4>Social Performance</h4>
<p>I should probably point out that a big help to the site was a <a href="https://twitter.com/#!/FourFourTom/status/197768188639973376">re-tweet</a> by <a href="https://twitter.com/#!/FourFourTom">@FourFourTom</a>, a football journalist who is very prominent in the Twitterverse; this pushed the site in front of a <em>relevant</em> audience of around 60,000, which seemed to kick-start a lot of interest in the site.</p>
<p>In terms of Facebook, the site has surpassed 200 likes and is growing in reach and significance thanks to the Facebook Comments section.</p>
<h4>Overall Performance</h4>
<p>Overall, the site has had 3467 unique visitors in the 13 days it has been live, with an ever-increasing majority coming through Google. For me, this is extremely promising and it points to the site&#8217;s potential to sustain itself in the long term through Google searches, suggesting it won&#8217;t just die down into nothingness when social sharing dries up.</p>
<p>Anyway, go look, click the Like button, click the Tweet button and have your say by leaving a comment at the bottom &#8211; <a href="http://messivsronaldo.net/">http://messivsronaldo.net/</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/from-concept-to-live-in-8-days-messi-vs-ronaldo/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/from-concept-to-live-in-8-days-messi-vs-ronaldo/</feedburner:origLink></item>
		<item>
		<title>Deciding what Responsive Breakpoints to use</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/xZFye1SopR8/</link>
		<comments>http://www.tangledindesign.com/blog/deciding-what-responsive-breakpoints-to-use/#comments</comments>
		<pubDate>Tue, 20 Mar 2012 14:13:07 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Media Queries]]></category>
		<category><![CDATA[Responsive]]></category>
		<category><![CDATA[RWD]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1326</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/deciding-what-responsive-breakpoints-to-use/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/featured.jpg" class="alignleft tfe wp-post-image" alt="Responsive Breakpoints" title="Responsive Breakpoints" /></a>Let&#8217;s start off by discussing a rather common mindset when it comes to responsive development &#8211; it&#8217;s the wrong mindset to take on (in my opinion of course) but it seems to be the default thought-process for many. It&#8217;s understandable, &#8230; <a href="http://www.tangledindesign.com/blog/deciding-what-responsive-breakpoints-to-use/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/featured.jpg" alt="Responsive Breakpoints" title="Responsive Breakpoints" class="alignleft post-img" /> Let&#8217;s start off by discussing a rather common mindset when it comes to responsive development &#8211; it&#8217;s the wrong mindset to take on (in my opinion of course) but it seems to be the default thought-process for many. It&#8217;s understandable, but we&#8217;ll be explaining why in reality, it&#8217;s pretty daft.</p>
<h3>The Wrong Mindset!</h3>
<p>Okay, so let&#8217;s pretend we&#8217;ve made a nice, fluid layout in CSS, but alas, it starts to break as we drag the edge of our browser window to test. Media Queries to the rescue! But where do we apply these media queries? Right, well there&#8217;s the iPhone (amongst other smartphones), the iPad, the Kindle and then your laptops and desktops. With that selection of popular devices that will access your website, it might seem logical to use breakpoints like 320, 480, 600, 768 and 1024.</p>
<p>Have you done this? Yeah, so have I. It&#8217;s forgivable. But it goes against what responsive development is all about.</p>
<h4>Why?</h4>
<p>When you start to think in terms of device dimensions, you&#8217;re not thinking responsive. Responsive Web Design is fluid and flexible; something that <em>adapts</em> to the surroundings it happens to inhabit.</p>
<h4>Analogy time</h4>
<p>Picture a jug of water. Now imagine you&#8217;ve got 20 odd cups, all completely different sizes, lined up next to the jug. It doesn&#8217;t matter which cup you pour the water into, it will simply adapt to its surroundings and take the shape of the cup.</p>
<p>Wow that was a bad analogy. But you get the jist. Your design needs to adapt and flow into its surroundings and take the shape of the device &#8211; whatever that device may be.</p>
<h3>So how do you achieve a truly device-agnostic design?</h3>
<p>For starters, remove yourself from the device based breakpoints mindset. And get into the <em>design</em> based breakpoints mindset. Make adjustments where the design dictates. Pull your browser window out and see when the design starts to break &#8211; that&#8217;s your first breakpoint. Use a media query, fix it up and repeat the process. Simple!</p>
<p>Don&#8217;t base your breakpoints on devices that are currently popular, base them on your design and where it requires adjustment.</p>
<h4>Some gentle contradiction</h4>
<p>In theory, we should forget everything we ever knew about currently popular devices when it comes to determining breakpoints, but it&#8217;s probably not the wisest move to dismiss them altogether. It&#8217;s always important to test your responsive design in as many devices as you can get your hands on, especially the popular ones that will access your website the most. I&#8217;m not backtracking on what I&#8217;ve already said, I&#8217;m just saying be <em>aware</em> of what&#8217;s around at the moment and make sure your site performs as it should.</p>
<p>There are a number of really nicely made, good looking responsive testing sites doing the rounds at the moment and whilst these can be very useful, just be wary of relying on them too much. They encourage device based breakpoints and lack of testing inbetween the devices they display. Additionally, as <a href="https://twitter.com/#!/dbushell/status/178050745390731264">David Bushell highlighted</a>, most of these testing sites ignore the browser UI on the devices they claim to emulate, pointing out that the iPhone web viewport is not 320&#215;480 when taking this into account.</p>
<h3>What&#8217;s everyone else doing?</h3>
<p>So you know what I think, but what of the big players in the industry? <a href="http://smashingmagazine.com">Smashing Magazine</a> is <em>the</em> web design blog and has recently been the subject of a responsive makeover, spearheaded by curly haired Web person <a href="http://elliotjaystocks.com/">Elliot Jay Stocks</a>.</p>
<p>I sent Elliot an email asking for some insight into the breakpoints used in the new site and I was pleased to learn my beliefs were shared by Elliot and were applied in the Smashing re-design project&hellip;</p>
<blockquote><p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/open-quote1.png" alt="&quot;" class="alignleft" />I strongly agree with you that breakpoints should be defined by &#8216;when it looks appropriate&#8217; rather than conforming to device dimensions, which date very, very quickly. For SM, we certainly applied this logic&hellip;<img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/close-quote.png" alt="&quot;" class="alignright" /></p></blockquote>
<p>There you go; someone significant agrees with me! Anyway, I did some firebugging and went through their CSS to identify exactly what breakpoints they used&hellip;</p>
<h4>Smashing Magazine Breakpoints</h4>
<h5>0 and Up (Screenshot is at 320px)</h5>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/320.jpg" alt="0 and Up" title="0 and Up" class="alignleft full-width-img" /><br />
The fluidity of the layout does all of the work to start with right up until the first breakpoint.</p>
<h5>500px</h5>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/500.jpg" alt="500px" title="500px" class="alignleft full-width-img" /><br />
The first breakpoint is used for the tiniest of fixes; it simply says that when the viewport is below 500px, change the search button text from &#8216;Search&#8217; to &#8216;Go!&#8217; as this text obviously scales down further.</p>
<h5>610px</h5>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/610.jpg" alt="610px" title="610px" class="alignleft full-width-img" /><br />
The first major breakpoint isn&#8217;t until the viewport reaches 610px, so the fluid framework of the site handles everything below that, which is pretty good going. The navigation explodes from it&#8217;s dropdown menu into a rather large set of lists. These changes definitely <em>feel</em> like the transition from mobile to tablet.</p>
<h5>650px</h5>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/650.jpg" alt="650px" title="650px" class="alignleft full-width-img" /><br />
Okay, this is a really insignificant breakpoint in the grand scheme of things, but I&#8217;ve included it to highlight that it&#8217;s okay to use media queries for minor things that just need fixing; they don&#8217;t just have to be for major changes. This particular breakpoint states that when the viewport is wider than 650px, then float the advert to the right (the one visible in the shots above).</p>
<h5>800px</h5>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/800.jpg" alt="800px" title="800px" class="alignleft full-width-img" /><br />
Here we see more big changes with this breakpoint. A second column is brought in to accomodate the secondary navigation that was previously taking up large amounts of space above the content.</p>
<h5>1020px</h5>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/1020.jpg" alt="1020px" title="1020px" class="alignleft full-width-img" /><br />
Another major breakpoint in the design; viewports wider than 1020px are treated to a huge new right hand sidebar (there are still only 2 columns as the secondary nav has moved back to the top) to accomodate all of the adverts and other less important content. This change feels like the transition from tablet to desktop/laptop.</p>
<h5>1220px</h5>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/1220.jpg" alt="1220px" title="1220px" class="alignleft full-width-img" /><br />
Now for the first time, we have a 3 column layout, with the secondary nav returning to the left hand-side, but this time, the right hand sidebar is maintained.</p>
<h5>1450px</h5>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/03/1450.jpg" alt="1450px" title="1450px" class="alignleft full-width-img" /><br />
The final major breakpoint adjusts the design for widescreen monitors. A further fourth column is introduced as the top level navigation shifts to the left hand side of the page next to the secondary nav.</p>
<p>There were two more breakpoints used at 1600px and 1800px, but these were only very minor fixes in areas such as the footer.</p>
<h3>Summing Up</h3>
<p>So there you have it. A set of breakpoints which bare very little relation to any currently popular devices, because they&#8217;ve been added where the design suggests they should be, not where devices suggest they should be.</p>
<p>I&#8217;ve used Smashing Magazine as a case study as it perfectly backs up my point, but I looked at a few more responsive designs and found that they&#8217;d clearly based their breakpoints around device dimensions. These sites included <a href="http://sony.com" title="Sony Responsive Website">sony.com</a> and <a href="http://24ways.org" title="24 Ways Responsive Design">24ways.org</a>; pretty big players in their own rights, so don&#8217;t feel too disheartened if you&#8217;ve fallen into the same trap as it seems the very best of us have.</p>
<p>Disagree with my thoughts? Go leave a comment below and we&#8217;ll have it out!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/deciding-what-responsive-breakpoints-to-use/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/deciding-what-responsive-breakpoints-to-use/</feedburner:origLink></item>
		<item>
		<title>Enhancing your Image Thumb Galleries using CSS3 Transitions and Transforms (Responsive)</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/9DmVlCK1ztM/</link>
		<comments>http://www.tangledindesign.com/blog/enhancing-thumb-galleries-css3-transitions-transforms/#comments</comments>
		<pubDate>Thu, 09 Feb 2012 13:54:39 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[CSS3 Transforms]]></category>
		<category><![CDATA[CSS3 Transitions]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1292</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/enhancing-thumb-galleries-css3-transitions-transforms/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/featured1.jpg" class="alignleft tfe wp-post-image" alt="featured" title="featured" /></a>We&#8217;re going to look at using progressive enhancement techniques to improve our user&#8217;s experience, in this case, with image galleries. These enhancements aren&#8217;t essential to the functionality of our galleries, but they do show that we care about our users, &#8230; <a href="http://www.tangledindesign.com/blog/enhancing-thumb-galleries-css3-transitions-transforms/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/featured1.jpg" alt="" title="featured" class="alignleft post-img" />We&#8217;re going to look at using progressive enhancement techniques to improve our user&#8217;s experience, in this case, with image galleries. These enhancements aren&#8217;t essential to the functionality of our galleries, but they do show that we care about our users, offering them the best experience we can in their browser of choice.</p>
<p>The techniques use only CSS, so are very easy to implement and very lightweight when squared against some JavaScript that achieves the same outcome.</p>
<p>Try not to get carried away with these techniques; remember that they&#8217;re meant to enhance the experience for those with capable browsers, not punish those who perhaps aren&#8217;t as <em>aware</em> of the software they&#8217;re using.</p>
<p>The examples we&#8217;ll be discussing are in no way lightbox alternatives or have anywhere near the same capabilities, but they do provide some middle ground by subtly enhancing our image thumb galleries, much like the way Google Images provides a further taster by slightly enlarging their images when they&#8217;re hovered over.</p>
<p>Go see the demo to see all the techniques in practice and to get an idea of all we&#8217;ll be talking about&hellip;<br />
<a href="http://tangledindesign.com/blog/demos/css3-enhanced-galleries"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/8.jpg" alt="View Demo" title="View Demo" class="alignleft full-width-img" /></a><a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png" alt="" title="View Demo" width="254" height="67" class="demo-btn alignleft size-full wp-image-643" /></a><a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries/main.css"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/css-button.png" alt="" title="View CSS" width="254" height="67" class="demo-btn alignleft size-full wp-image-645" /></a></p>
<h3>Responsive Framework</h3>
<p>This isn&#8217;t the main aspect of our discussion, but we&#8217;re going to quickly run through building an image thumb gallery using percentage values and other responsive techniques to ensure it looks good on all devices.</p>
<p>First of all, we need a containing <code>div</code>. Inside this element, we have our images, which I&#8217;m going to put inside an unordered list (<code>&lt;ul&gt;</code>); the <code>&lt;li&gt;</code>s that will wrap our images will come in handy when making these images responsive.</p>
<p>So here&#8217;s our markup for the gallery&hellip;</p>
<pre>
<code>&lt;div&gt;
    &lt;ul&gt;
        &lt;li&gt;&lt;img src="1.jpg" alt=""&gt;&lt;/li&gt;
        &lt;li&gt;&lt;img src="1.jpg" alt=""&gt;&lt;/li&gt;
        &lt;li&gt;&lt;img src="1.jpg" alt=""&gt;&lt;/li&gt;
        &lt;li&gt;&lt;img src="1.jpg" alt=""&gt;&lt;/li&gt;
        &lt;li&gt;&lt;img src="1.jpg" alt=""&gt;&lt;/li&gt;
        &lt;li&gt;&lt;img src="1.jpg" alt=""&gt;&lt;/li&gt;
    &lt;/ul&gt;
&lt;/div&gt;</code>
</pre>
<p>Easy, simple and clean markup. Now for some simple CSS to match.</p>
<p>Seeing as our gallery is for thumbnail images, we&#8217;ll give our containing <code>&lt;div&gt;</code> 30% of the page width. Now, we have 6 images to accommodate &#8211; let&#8217;s go for 2 rows of 3. We&#8217;re going to give each containing <code>&lt;li&gt;</code> 30% of the containing <code>&lt;div&gt;</code>.</p>
<p>So 30% multiplied by 3 list items (per row) equals 90% (doesn&#8217;t take a genius), leaving us 10% for our margins. A row of 3 images leaves us with 4 gutters to fill between the containing <code>&lt;div&gt;</code> and between each of the images. 10% divided by 4 is 2.5%, so that is the width of our margins. Simple!</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/7.jpg" alt="Responsive Framework" title="Responsive Framework" class="alignleft full-width-img" /></p>
<pre>
<code>div {
    width:30%;
    margin:0 auto; /* Centres page */
}

ul {
    width:100%;
    padding-bottom:2.5%;
    background:#ccc;
    float:left;
}

ul li {
    width:30%;
    margin:2.5% 0 0 2.5%;
    float:left;
    position:relative; /* Needed for z-indexing later */
}</code>
</pre>
<p>Finally, we need to ensure our images fit inside of the <code>&lt;li&gt;</code>s. To do this we simply give our <code>&lt;img&gt;</code> elements a <code>max-width</code> value of 100%, ensuring that our images fill the <code>&lt;li&gt;</code>s and don&#8217;t overflow.</p>
<pre>
<code>ul li img {
    max-width:100%;
    border:2px solid #eee;
    box-sizing:border-box; /* Don't forget vendor prefixes! */
}</code>
</pre>
<p>You can see above that we&#8217;ve also used the <code>border-box</code> technique, which basically alters the laws of the box model and allows us to use pixel based border widths, without adding any more width/height to our images. So instead of the border being in <em>addition</em> to the image&#8217;s width/height, it is applied <em>within</em> the image&#8217;s width/height.</p>
<p>If you were actually going to create a gallery like this in the real world, you would be wise to use media queries to adjust the width of the containing <code>&lt;div&gt;</code> at different viewport sizes, as obviously 30% of a mobile device viewport would result in a tiny, barely usable thumb gallery.</p>
<h3>Basic Hover Effects using Transforms and Transitions</h3>
<p>We&#8217;re going to start with a simple enlarge on hover effect as you can see in <a href="http://tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-one">Gallery One</a> from our <a href="http://tangledindesign.com/blog/demos/css3-enhanced-galleries">demo</a>.</p>
<p>Right, let&#8217;s kick off by giving our thumbs an <code>opacity</code> value of 0.5, so that on hover we can bring it to full colour and emphasise the hover effect. So, we know that on hover we want our thumb to get bigger and strengthen in colour, but we need to add the transition values to our thumb in order for the state change to appear animated.</p>
<p><small>If you need a refresher on CSS3 Transitions and Transforms, you may want to read <a href="http://www.tangledindesign.com/blog/get-the-ball-rolling-with-css3-transitions/">my initial post explaining these techniques</a>.</small></p>
<p>Our <code>&lt;li&gt;</code> now has the following CSS rules (assuming all of the general rules we defined above are still in place as well).</p>
<pre>
<code>.gal-1 li {
    transition:all 0.6s ease; /* Remember vendor prefixes! */
    opacity:0.5;
}</code>
</pre>
<p>The above rules simply say; make the element 50% transparent and transition any state changes for 0.6 seconds. Now we need to determine our CSS rules for the <code>:hover</code> state&hellip;</p>
<pre>
<code>.gal-1 li {
    transition:all 0.6s ease; /* Remember vendor prefixes! */
    opacity:0.5;
}

.gal-1 li:hover {
    transform:scale(1.4); /* Remember vendor prefixes! */
    opacity:1;
    box-shadow:5px 3px 5px rgba(0, 0, 0, 0.3);
    z-index:2;
}</code>
</pre>
<p>As previously discussed, we&#8217;ve made the image fully opaque and we&#8217;ve used the CSS3 <code>transform</code> property to make the thumb 1.4 times bigger. The beauty of the scale transform property is that it ignores everything around it and simply enlarges from its centre without effecting the surrounding layout.</p>
<p>I&#8217;ve also added a subtle shadow to the image to strengthen the illusion that the image is hovering above the others. And finally, I&#8217;ve given the hovered element a <code>z-index</code> value to ensure that the currently hovered image appears above all of the other images.</p>
<p>These extremely simple CSS rules give us a lovely, smooth zoom functionality on our thumb images. As I see it, the idea is still to utilise some kind of lightbox plugin to view the full image and complete the gallery experience, but these techniques go a long way to enhancing our user experience by providing an additional taster for our thumbs.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-one"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/9.jpg" alt="Thumb Enlarge" title="Thumb Enlarge" class="alignleft full-width-img" /></a></p>
<h4>Using Rotate</h4>
<p>There&#8217;s more to the <code>transform</code> property than <code>scale</code>; a particularly good one when combined with transitions is <code>rotate</code>. I&#8217;m going to make a very slight addition to the code we produced above to create a rather <a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-two">different transition</a>.</p>
<pre>
<code>.gal-2 li:hover {
    transform:scale(1.4) rotate(360deg); /* Remember vendor prefixes! */
    opacity:1;
    box-shadow:5px 3px 5px rgba(0, 0, 0, 0.3);
    z-index:2;
}</code>
</pre>
<p>The change has been made to our rules on the <code>:hover</code> state. Spot the difference? All we&#8217;ve done is add another set of values to the <code>transform</code> property &#8211; in this case, we&#8217;ve ordered the thumb to not only scale up on hover, but to rotate 360 degrees as well, creating a more exciting transition.</p>
<p>Here&#8217;s the thumbnail image in mid transition.<br />
<a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-two"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/10.jpg" alt="Rotate Transition" title="Rotate Transition" class="alignleft full-width-img" /></a></p>
<h3>Scattered Thumbs</h3>
<p>The next example is a little more tedious depending on how many thumb images you have.<br />
<a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-three"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/11.jpg" alt="Scattered Thumbs" title="Scattered Thumbs" class="alignleft full-width-img" /></a><br />
I&#8217;ve scattered the thumb images by targeting each of them individually using the <code>nth-of-type</code> selector and then using the <code>transform:rotate()</code> technique to position each of the images at a different angle. Finally, I&#8217;ve introduced yet another variation of the <code>transform</code> property, called <code>translate</code>, which quite simply moves the element from one position to another. I used this to make the thumbs overlap each other slightly.</p>
<pre>
<code>.gal-3 li:nth-of-type(2) { transform:rotate(-10deg) translate(0, 10px); }

.gal-3 li:nth-of-type(3) { transform:rotate(10deg) translate(0, 20px); }

.gal-3 li:nth-of-type(4) { transform:rotate(-40deg) translate(20px, -10px); }

/* etc. */</code>
</pre>
<p>On the <code>:hover</code> state, I simply scaled the thumbnails up again and straightened out any angles.<br />
<a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-three"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/12.jpg" alt="Scattered Thumbs" title="Scattered Thumbs" class="alignleft full-width-img" /></a></p>
<h3>Triggering Transitions on Click</h3>
<p>The last couple of galleries in our demo employ similar effects to the ones above, only these transitions are triggered when the thumb is clicked on rather than hovered over. For a detailed explanation into how you can trigger a CSS transition on click, you may want to read <a href="http://www.tangledindesign.com/blog/how-to-trigger-css3-transitions-on-click-using-target/">this article I wrote on the matter</a>. But Basically, we use the <code>:target</code> pseudo-selector.</p>
<p>To give you a basic understanding, the CSS rules under <code>#one:target</code> will only be applied if #one is at the end of the URL in the addres bar. In short, if a link to #one has been clicked, the CSS rules under <code>#one:target</code> will be applied. Simple.</p>
<p>To make this work properly, we need to modify our gallery markup&hellip;</p>
<pre>
<code>&lt;h2 id="gal-five"&gt;Gallery Five &lt;span&gt;Enlarge on Click&lt;/span&gt;&lt;/h2&gt;
&lt;ul class="gal-5"&gt;
    &lt;li id="one"&gt;
        &lt;a class="close" href="#gal-five"&gt;Close&lt;/a&gt;
        &lt;a href="#one"&gt;&lt;img src="1.jpg" alt=""&gt;&lt;/a&gt;
    &lt;/li&gt;
    &lt;li id="two"&gt;
        &lt;a class="close" href="#gal-five"&gt;Close&lt;/a&gt;
        &lt;a href="#two"&gt;&lt;img src="2.jpg" alt=""&gt;&lt;/a&gt;
    &lt;/li&gt;
    &lt;li id="three"&gt;
        &lt;a class="close" href="#gal-five"&gt;Close&lt;/a&gt;
        &lt;a href="#three"&gt;&lt;img src="3.jpg" alt=""&gt;&lt;/a&gt;
    &lt;/li&gt;
    &lt;li id="four"&gt;
        &lt;a class="close" href="#gal-five"&gt;Close&lt;/a&gt;
        &lt;a href="#four"&gt;&lt;img src="4.jpg" alt=""&gt;&lt;/a&gt;
    &lt;/li&gt;
    &lt;li id="five"&gt;
        &lt;a class="close" href="#gal-five"&gt;Close&lt;/a&gt;
        &lt;a href="#five"&gt;&lt;img src="5.jpg" alt=""&gt;&lt;/a&gt;
    &lt;/li&gt;
    &lt;li id="six"&gt;
        &lt;a class="close" href="#gal-five"&gt;Close&lt;/a&gt;
        &lt;a href="#six"&gt;&lt;img src="6.jpg" alt=""&gt;&lt;/a&gt;
    &lt;/li&gt;
&lt;/ul&gt;</code>
</pre>
<p>What have we done here then? Well, we&#8217;ve added an <code>id</code> to each <code>&lt;li&gt;</code>, we&#8217;ve wrapped our images in <code>&lt;a&gt;</code> tags which link to the corresponding <code>&lt;li&gt; id</code>. Lastly, we&#8217;ve added another link which links to the galleries <code>&lt;h2&gt; id</code>, allowing the user to escape once a thumb has been clicked on.</p>
<p>The markup modification is the most difficult bit about this technique really, so carry on reading&hellip;</p>
<p>Now we simply scale up the thumb when it&#8217;s being targeted (clicked on).</p>
<pre>
<code>.gal-5 li:target {
    transform:scale(2.2);
    z-index:2;
    opacity:1;
}

.gal-5 li:target img {
    box-shadow:5px 3px 5px rgba(0, 0, 0, 0.3);
}

.gal-5 .close {
    display:none;
    /* other presentational styles */
}

.gal-5 li:target .close {
    display:inline;
}</code>
</pre>
<p>After scaling the currently targeted <code>&lt;li&gt;</code>, we add the <code>box-shadow</code> property to the img within the currently targeted <code>&lt;li&gt;</code> and we ensure that all of the <code>&lt;a&gt;</code> tags with a class of <code>.close</code> are hidden unless they are within the currently targeted <code>&lt;li&gt;</code>.</p>
<p>This method is nice when it works, but it has its limitations; namely the page jumping to the top of targeted element. I would imagine you will very rarely find a practical use for this, but if you do, use cautiously.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-five"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/13.jpg" alt="Transition on Click" title="Transition on Click" class="alignleft full-width-img" /></a></p>
<h3>Transitioning 3D Transforms on Click</h3>
<p>Our <a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-six">final gallery</a> also triggers the transitions by clicking on the thumbs rather than hovering over them. We use all of the same techniques as we just used above, but with one small addition; yes, <em>another</em> <code>transform</code> value.</p>
<p>This one is just like the <code>rotate</code> transform value we discussed above, but with one small addition. This value is either <code>rotateX</code>, <code>rotateY</code> or <code>rotateZ</code>, which allow the element to rotate as if in a 3D environment. So rather than simply spinning left or right, this allows us to flip our images forwards or backwards or horizontally.</p>
<p>Now, before you start raging about how it doesn&#8217;t work for you, bear in mind that 3D transforms have limited support at the moment and are best viewed in the latest versions of Chrome and Safari, although Firefox 10 appears to support them now, if not perfectly.</p>
<p>So here&#8217;s the small addition we&#8217;ve made to our CSS&hellip;</p>
<pre>
<code>.gal-6 li:target {
    transform:scale(2.2) rotateY(360deg);
    z-index:2;
    opacity:1;
}</code>
</pre>
<p>We&#8217;ve simply added <code>rotateY</code> to our <code>transform</code> property, telling it to rotate 360 degrees towards us.</p>
<p>Here&#8217;s the bottom right thumb in mid 3D rotation:<br />
<a href="http://www.tangledindesign.com/blog/demos/css3-enhanced-galleries#gal-six"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/02/14.jpg" alt="3D Transform Transition" title="3D Transform Transition" class="alignleft full-width-img" /></a></p>
<h3>Summing Up</h3>
<p>As long as you remember a few key points, you can go ahead and use these techniques right now, without any worry.</p>
<ul>
<li>Remember that you&#8217;re using these techniques to <em>enhance</em> your user&#8217;s experience in capable browsers &#8211; they&#8217;re not to be relied upon for functionality.</li>
<li>Test in all major browsers &#8211; if you&#8217;re doing things properly, your gallery should look perfectly acceptable in IE 7 and friends.</li>
<li>Remember your browser prefixes (<code>-webkit-</code>, <code>-moz-</code>, <code>-o-</code>, <code>-ms-</code>) and throw in the un-prefixed property to make it future proof.</li>
<li>Be subtle &#8211; crazy, gimmicky effects belong in the 90&#8242;s. Be elegant and delicate with the transforms &amp; transitions you&#8217;re applying.</li>
</ul>
<p>If you can think of any more cool transitions for thumb galleries, I&#8217;d love to see them in the comments section. And if you enjoyed this post, please share, tweet etc.!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/enhancing-thumb-galleries-css3-transitions-transforms/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/enhancing-thumb-galleries-css3-transitions-transforms/</feedburner:origLink></item>
		<item>
		<title>Words of Wisdom to Improve your Design Theory</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/gVMkX2rI4qU/</link>
		<comments>http://www.tangledindesign.com/blog/words-of-wisdom-to-improve-your-design-theory/#comments</comments>
		<pubDate>Thu, 26 Jan 2012 13:50:59 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[Design Quotes]]></category>
		<category><![CDATA[Design Theory]]></category>
		<category><![CDATA[Self-improvement]]></category>
		<category><![CDATA[University]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1274</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/words-of-wisdom-to-improve-your-design-theory/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/01/featured1.jpg" class="alignleft tfe wp-post-image" alt="Only dead fish go with the flow" title="Only dead fish go with the flow" /></a>A few weeks ago I was clearing out a load of old stuff and I came across a pretty big folder from my first year of Uni. After having a slightly nostalgic flick through, I deemed it all rather useless. &#8230; <a href="http://www.tangledindesign.com/blog/words-of-wisdom-to-improve-your-design-theory/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/01/featured1.jpg" alt="Only dead fish go with the flow" title="Only dead fish go with the flow" class="alignleft post-img" /> A few weeks ago I was clearing out a load of old stuff and I came across a pretty big folder from my first year of Uni. After having a slightly nostalgic flick through, I deemed it all rather useless. All bar about 6 pages of notes from a couple of my first ever lectures.</p>
<p>Titled <em>‘Methodologies of Design’</em>, they offered clarity to some of the basic principles of design and reminded myself of the theory behind my actions as a designer.</p>
<p>It was somewhat refreshing and I realised that sometimes it’s good to take a step back and go back to basics to remind yourself what you’re doing and why you’re doing it. And I thought these notes might be worth sharing in a ‘back-to-basics’ type offering.</p>
<p>It seems I did take something useful from Uni after all! Who’d have thought it?</p>
<p>Here are just a few words of wisdom from my methodologies of design lecture&hellip; </p>
<blockquote><p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/open-quote1.png" alt="&quot;" class="alignleft" />Only dead fish go with the flow<img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/close-quote.png" alt="&quot;" class="alignright" /></p></blockquote>
<ul>
<li>Create your own style</li>
<li>Do things in your own way</li>
<li>Use tools in your own way</li>
<li>Don’t be like everyone else</li>
</ul>
<blockquote><p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/open-quote1.png" alt="&quot;" class="alignleft" />A good designer is an imaginative problem solver<img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/close-quote.png" alt="&quot;" class="alignright" /></p></blockquote>
<ul>
<li>Able to rethink ideas</li>
<li>Change to improve functionality</li>
<li>Think outside the box</li>
</ul>
<blockquote><p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/open-quote1.png" alt="&quot;" class="alignleft" />Less is more<img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/close-quote.png" alt="&quot;" class="alignright" /></p></blockquote>
<ul>
<li>Simplicity and clarity lead to good design</li>
<li>Well organised content will communicate your message better than trying to cram in as much information as possible</li>
</ul>
<blockquote><p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/open-quote1.png" alt="&quot;" class="alignleft" />Form follows function<img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/close-quote.png" alt="&quot;" class="alignright" /></p></blockquote>
<ul>
<li>Must be formed to suit function</li>
<li>Form must support function</li>
</ul>
<blockquote><p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/open-quote1.png" alt="&quot;" class="alignleft" />Design can directly improve profitability<img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/close-quote.png" alt="&quot;" class="alignright" /></p></blockquote>
<ul>
<li>Packaging</li>
<li>Appearance of product</li>
<li>Looking good is half the battle won</li>
</ul>
<blockquote><p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/open-quote1.png" alt="&quot;" class="alignleft" />Colour effects mood<img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/03/close-quote.png" alt="&quot;" class="alignright" /></p></blockquote>
<ul>
<li>Cool colours (blue, green neutral, white, grey) can be calming, comforting, nurturing, cold and/or impersonal</li>
<li>Warm colours (red, yellow, orange) can show brightness, passion, heat, love and/or urgency</li>
<li>Warm colours appear larger than cool colours and can appear closer whilst cool colours visually recede</li>
</ul>
<p>Simple stuff, but worth clarifying in your mind. This type of theoretical knowledge aids you in making your design decisions and helps to ensure you are making the right ones.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/words-of-wisdom-to-improve-your-design-theory/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/words-of-wisdom-to-improve-your-design-theory/</feedburner:origLink></item>
		<item>
		<title>Using first-line and first-letter to draw users into your copy</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/XvqZ76qGbW4/</link>
		<comments>http://www.tangledindesign.com/blog/using-first-line-and-first-letter-to-draw-people-into-your-copy/#comments</comments>
		<pubDate>Tue, 17 Jan 2012 14:17:13 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[pseudo-elements]]></category>
		<category><![CDATA[pseudo-selectors]]></category>
		<category><![CDATA[Typography]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1251</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/using-first-line-and-first-letter-to-draw-people-into-your-copy/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/01/featured.jpg" class="alignleft tfe wp-post-image" alt="First Line and First Letter" title="First Line and First Letter" /></a>Blocks of copy can often appear intimidating and overwhelming to us humans, being the instinctively lazy species that we are. Subsequently, we’re always striving to make the text on our websites more friendly, more appealing and ultimately to increase its &#8230; <a href="http://www.tangledindesign.com/blog/using-first-line-and-first-letter-to-draw-people-into-your-copy/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/01/featured.jpg" alt="First Line and First Letter" title="First Line and First Letter" class="alignleft post-img" /> Blocks of copy can often appear intimidating and overwhelming to us humans, being the instinctively lazy species that we are. Subsequently, we’re always striving to make the text on our websites more friendly, more appealing and ultimately to increase its readability. It&#8217;s a difficult practise, but there are a number of ways we try to control the readability of our copy.</p>
<p>The way we design a website in terms of layout helps us to control and manage the readability of our copy, as it houses the text and attempts to present it in the best way possible.</p>
<p>There are several other ways we try to control the readability of our text, from size and colour to line height and letter spacing, but the fact is large areas of text are often still uninviting and hard to entice your average user with, despite utilising all of the best usability practises.</p>
<h4>Extra Styling</h4>
<p>Another little trick to break down the barrier between your copy and your users is to add some extra styling to the opening section of the text; namely the first line, first letter and/or first word(s).</p>
<p>This technique may not have your words being consumed by all who come across them, but it could go some way to tying your copy in with the design of the website and therefore considerably breaking down the barrier between the user and them actually starting to read the text.</p>
<p>Having the first few words stand out from the rest of the text will attract attention and draw the user into them, encouraging the user to start reading and making it more likely that they will read on.</p>
<h4>Pseudo-Selectors</h4>
<p>Thanks to CSS, we can utilise this technique quite easily using pseudo-selectors to target these areas, without having to add any ugly tags to our markup.</p>
<ul>
<li>:first-line</li>
<li>:first-letter</li>
</ul>
<p>And the best thing is, they both work across the board, in all major browsers! Yes, even IE6!</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/01/4.jpg" alt="Browser Support" title="Browser Support" class="alignleft full-width-img" /></p>
<p><small>Note: Pseudo-elements should be implemented with a double colon (::first-line) as opposed to pseudo-classes which should use a single colon (:first-child), but older versions of IE fail to recognise the double colon usage, which is why I tend to stick with a single colon.</small></p>
<p>We’re going to be looking at a few examples of how we can use these pseudo-selectors to add that little something extra to our website’s copy.</p>
<p>You may have noticed that there is no pseudo-selector for first-word in CSS, so we’re going to have to use our imagination for this; we’ll be going through our options later on in this article.</p>
<h4>First-line</h4>
<p>The beauty of pseudo-selectors is that they ensure we don’t have to touch our markup to add unnecessary tags and classes. All the work is done in the CSS.</p>
<p>And it couldn’t be simpler&#8230;</p>
<pre>
<code>p:first-line {
    font-weight:bold;
    text-transform:uppercase;
    letter-spacing:0.1em;
}</code>
</pre>
<p>This selector allows us to target part of an element that has no place in the actual document tree, which is why we refer to it as a pseudo-element.</p>
<p>Now we have a first line that stands out from the rest of our text, offering us an introduction into our paragraph.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/01/1.jpg" alt="first-line" title="first-line" class="alignleft full-width-img" /></p>
<p>That’s fine in theory, but what happens when we add a few more paragraphs into our copy?</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/01/2.jpg" alt="first-line" title="first-line" class="alignleft full-width-img" /></p>
<p>Not really what we wanted is it? Ideally, we just want the first line of our first paragraph to stand out, not the first line of every paragraph!</p>
<p>We could use <code>p:first-child:first-line</code>, but for this to work, the <code>&lt;p&gt;</code> would need to be the first child of its container, which is unlikely given that most blocks of text are superseded with a heading of some sort.</p>
<p>In this case, we can use <code>p:first-of-type:first-line</code>. This ensures that only the first line of the very first paragraph is styled, no matter what comes before the first paragraph in the markup.</p>
<h4>First-letter</h4>
<p>No prizes for guessing what’s coming next. Unsurprisingly, it’s exactly the same method as the above. The basic usage is simply <code>p:first-letter</code>, but taking into account multiple paragraphs, we use the below snippet to target only the first paragraph&#8230;</p>
<pre>
<code>p:first-of-type:first-letter {
    font-size:4.5em;
    font-weight:normal;
    letter-spacing:0;
    line-height:1.2em;
    border:1px dashed #999;
    padding:0 17px;
    margin-right:5px;
}</code>
</pre>
<p>Simply styling one letter differently to the rest of the text can really draw attention to the block of text and encourage the user to read it.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/type-pseudo-elements/index.html"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2012/01/3.jpg" alt="first-letter" title="first-letter" class="alignleft full-width-img" /></a><a href="http://www.tangledindesign.com/blog/demos/type-pseudo-elements/index.html"><img class="demo-btn full-width-img alignleft" title="View Demo" alt="" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png"></a></p>
<h4>First Word</h4>
<p>Earlier we touched upon the fact that there is no pseudo-selector to style the first word of a paragraph for whatever reason. So unfortunately, we have to go a bit more old-school with this one.</p>
<p>Basically, there are 2 [front-end] options open to us.</p>
<ul>
<li>Wrap a <code>&lt;span&gt;</code> tag around the first word of our paragraph and target that element to style.</li>
<li>Use JavaScript to automatically wrap a <code>&lt;span&gt;</code> tag around your first word to avoid having to do it manually.</li>
</ul>
<p>If you’re working on a relatively small and maintainable site, then it’s probably easier to just add a <code>&lt;span&gt;</code> tag in where you need it. This method is easier and allows you more control over what you target i.e. if it was more appropriate to style the first few words rather than just the first, you could simply shift the closing tag. Easy peasy.</p>
<p>However, it’s often the case that the content being added isn’t so accessible, or it’s simply impractical to manually add bits of code into the copy. For example, it may be that a client is adding the content to the site through a CMS, in which case it wouldn’t be reasonable to rely on them to add <code>&lt;span&gt;</code> tags where necessary. This is where a JavaScript solution would be the more sensible option.</p>
<p>Whichever method you choose to use should simply be based on the needs of your project and which would be the easiest to implement and the easiest to maintain.</p>
<p>To wrap up, styled well these subtle pseudo elements can be very effective in transforming a boring block of text into something that is inviting and appealing to the eye.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/using-first-line-and-first-letter-to-draw-people-into-your-copy/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/using-first-line-and-first-letter-to-draw-people-into-your-copy/</feedburner:origLink></item>
		<item>
		<title>A Presentation about CSS3, Created with CSS3</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/NJ_kYoSos4o/</link>
		<comments>http://www.tangledindesign.com/blog/a-presentation-about-css3-created-with-css3/#comments</comments>
		<pubDate>Fri, 25 Nov 2011 12:53:45 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[CSS3]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1231</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/a-presentation-about-css3-created-with-css3/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/featured2.jpg" class="alignleft tfe wp-post-image" alt="CSS3 Slides" title="CSS3 Slides" /></a>Earlier on this week I held a training session on CSS3 for my colleagues at Adtrak, focusing on the basics and how we can use it today in our clients&#8217; sites &#8211; sites that receive the majority of their traffic &#8230; <a href="http://www.tangledindesign.com/blog/a-presentation-about-css3-created-with-css3/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/featured2.jpg" alt="CSS3 Slides" title="CSS3 Slides" class="alignleft post-img" />Earlier on this week I held a training session on CSS3 for my colleagues at <a href="http://adtrak.co.uk">Adtrak</a>, focusing on the basics and <strong>how we can use it today</strong> in our clients&#8217; sites &#8211; sites that receive the majority of their traffic from IE browsers (which you probably know don&#8217;t like CSS3 oh so much). I should probably start calling this blog Tangled in CSS3 considering how much I go on about it!</p>
<p>I wanted to make my presentation browser based so I could include working examples of certain features of CSS3 that require interactivity, so I put the slides together and animated them using jQuery.</p>
<p>Then I thought &#8211; wait a minute, surely I can do this with CSS3 and rid myself of any scripts! So that&#8217;s exactly what I did.</p>
<p>I&#8217;m going to provide a quick overview of the presentation and finish with a brief explanation of how I put it together (It&#8217;s pretty much the same method as the <a href="http://tangledindesign.com/blog/responsive-css3-sliding-gallery/">tutorial I posted last week</a> on my <a href="http://tangledindesign.com/blog/demos/responsive-css3-slider/">responsive sliding image gallery</a>).</p>
<p>The slides&hellip;<br />
<a href="http://tangledindesign.com/blog/demos/css3-slides"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/1.jpg" alt="View Slides" title="View Slides" class="alignleft full-width-img" /></a><br />
<a href="http://tangledindesign.com/blog/demos/css3-slides/"><img class="demo-btn full-width-img alignleft" title="View Demo" alt="" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png"></a></p>
<h3>Overview</h3>
<h4>Contents</h4>
<ol>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#one">Intro</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#two">Border Radius</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#three">CSS3 Transitions</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#seven">Opacity and RGBA</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#eight">Text Shadow and Box Shadow</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#ten">Multiple Backgrounds</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#eleven">2D Transforms</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#twelve">Using 2D Transforms with Transitions</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#thirteen">Pseudo Elements</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#fourteen">Linear Gradients</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#fifteen">Radial Gradients</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#sixteen">Selectors</a></li>
<li><a href="http://www.tangledindesign.com/blog/demos/css3-slides/#seventeen">Take Away</a></li>
</ol>
<p>It doesn&#8217;t cover everything (it barely touches the surface) and there are a few bits and bobs that aren&#8217;t strictly CSS3, namely the selectors, but I felt there were certain selectors that fly a bit under the radar in the mainstream and deserve a bit more coverage.</p>
<p>I do plan on expanding these slides considerably and transforming it into a significant resource for all things CSS3.</p>
<h3>How to make a presentation with CSS3</h3>
<p>It&#8217;s really quite simple. CSS3 takes all the glory but the real star here is simply the <code>:target</code> pseudo-selector, which applies styles to the element whos <code>id</code> is targeted at the end of the URL.</p>
<p>All our slides need an id; I&#8217;ve gone for #one, #two, #three etc. And within each slides we need navigation controls to take us to the next or previous slide. I&#8217;ve simply styled the controls to be transparent, with the &#8216;previous&#8217; link taking up the entire left half of the slide and the &#8216;next&#8217; link taking up the entire right half of the slide.</p>
<p>Obviously the navigation controls for the number #three slide (for example) would have a &#8216;previous&#8217; link to #two and a &#8216;next&#8217; link to #four. Like so&hellip;</p>
<pre>
<code>&lt;div class="panel" id="two"&gt;
    &lt;a class="back" href="#one"&gt;&lt;/a&gt;
    &lt;a class="next" href="#three"&gt;&lt;/a&gt;
&lt;/div&gt;
            
&lt;div class="panel" id="three"&gt;
    &lt;a class="back" href="#two"&gt;&lt;/a&gt;
    &lt;a class="next" href="#four"&gt;&lt;/a&gt;
&lt;/div&gt;
            
&lt;div class="panel" id="four"&gt;
    &lt;a class="back" href="#three"&gt;&lt;/a&gt;
    &lt;a class="next" href="#five"&gt;&lt;/a&gt;
&lt;/div&gt;</code>
</pre>
<p>Probably should be a <code>&lt;ul&gt;</code> rather than a list of <code>&lt;div&gt;'s</code> but we won&#8217;t get hung up on that right now.</p>
<h4>The CSS</h4>
<p>Before we get to any CSS3 we could simply say&hellip;</p>
<pre>
<code>.panel {
    display:none;
}

#one:target, #two:target, #three:target /* etc. */ {
    display:block;
}</code>
</pre>
<p>And job&#8217;s a good &#8216;un!</p>
<h4>CSS3</h4>
<p>But we want to be a bit more adventurous than that don&#8217;t we?</p>
<p>Yes. Firstly, lets get rid of the <code>display</code> properties because we can&#8217;t transition them. Let&#8217;s use <code>opacity:0;</code> instead and stick <code>opacity:1;</code> on the targeted elements. Don&#8217;t forget the <code>transition</code> property too!</p>
<pre>
<code>.panel {
    opacity: 0;
    transition: all 1s ease; /* Don't forget vendor pre-fixes! */
}

#one:target, #two:target /* etc. */ {
    opacity:1;
}</code>
</pre>
<p>Things are already looking much better. From here it&#8217;s simply a case of experimenting with various CSS3 properties.</p>
<p>I&#8217;ve used some transforms to make the animation look a little nicer and allow the slides to actually slide in.</p>
<pre>
<code>.panel {
    opacity: 0;
    transform: scale(0.1) translate(960px, 0);
    transition: all 1s ease; /* Don't forget vendor pre-fixes! */
}

#one:target, #two:target /* etc. */ {
    opacity:1;
    transform: scale(1) translate(0);
}</code>
</pre>
<p>So this pushes the panels 960px to the right and pulls it back to centre position when it&#8217;s targeted, allowing for the sliding transition from the right. I&#8217;ve also added a scale so it also appears to expand from small to big.</p>
<p>There&#8217;s a few more details you might need to know if you&#8217;re looking at employing this technique, so I&#8217;d strongly recommend taking a look at the CSS file.</p>
<p><a href="http://tangledindesign.com/blog/demos/css3-slides/"><img class="demo-btn alignleft size-full" title="View Demo" alt="" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png"></a><a href="http://tangledindesign.com/blog/demos/css3-slides/css/main.css"><img class="demo-btn alignleft" title="View CSS" alt="" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/css-button.png"></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/a-presentation-about-css3-created-with-css3/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/a-presentation-about-css3-created-with-css3/</feedburner:origLink></item>
		<item>
		<title>Responsive Sliding Click-through Gallery Using CSS3 Transitions</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/6TLaJmSB-Uw/</link>
		<comments>http://www.tangledindesign.com/blog/responsive-css3-sliding-gallery/#comments</comments>
		<pubDate>Thu, 17 Nov 2011 13:29:29 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[CSS3 Transforms]]></category>
		<category><![CDATA[CSS3 Transitions]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1206</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/responsive-css3-sliding-gallery/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/featured1.jpg" class="alignleft tfe wp-post-image" alt="featured" title="featured" /></a>When asked to hold a training session on CSS3 at my place of work, I thought a great way of demonstrating its capabilities would be to create my actual animated presentation using, wait for it&#8230; CSS3! I&#8217;d already done a &#8230; <a href="http://www.tangledindesign.com/blog/responsive-css3-sliding-gallery/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/featured1.jpg" alt="" title="featured" class="alignleft post-img" /> When asked to hold a training session on CSS3 at my place of work, I thought a great way of demonstrating its capabilities would be to create my actual animated presentation using, wait for it&hellip; CSS3!</p>
<p>I&#8217;d already done a bit of experimenting on <a href="http://www.tangledindesign.com/blog/how-to-trigger-css3-transitions-on-click-using-target/">how we can trigger CSS3 transitions on click</a>, rather than just triggering the effects on hover. The <code>:target</code> pseudo selector took the spotlight here and I knew I could utilise this technique to create a presentation where a click would trigger the piece to advance onto the next slide.</p>
<p>It worked a treat. And you can expect a post on how to put it together in the near future.</p>
<h4>Adapting the technique</h4>
<p>Since creating my CSS3 powered presentation, the ever innovative <a href="https://twitter.com/#!/csswizardry">Harry Roberts</a> of <a href="http://csswizardry.com">CSS Wizardry</a> recently put together a fantastic, <a href="http://csswizardry.com/2011/10/fully-fluid-responsive-css-carousel/">CSS3 powered image carousel</a>. Not only is it light and simple in comparison to JavaScript alternatives, but it&#8217;s also completely responsive.</p>
<p>This inspired me to adapt the techniques I&#8217;d used for my presentation and combine them with Harry&#8217;s techniques to create a responsive, click-through image gallery using no more than CSS3 transitions and transforms.</p>
<p>Here&#8217;s what we&#8217;re going to be working towards:<br />
<strong><em>Best viewed in Firefox!</em></strong><br />
<a href="http://www.tangledindesign.com/blog/demos/responsive-css3-slider"><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/1a.jpg" alt="" title="View Demo" class="alignleft full-width-img" /></a><br />
<a href="http://www.tangledindesign.com/blog/demos/responsive-css3-slider"><img class="demo-btn alignleft size-full wp-image-643" width="254" height="67" title="View Demo" alt="" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png"></a><a href="http://www.tangledindesign.com/blog/demos/responsive-css3-slider/main.css"><img class="demo-btn alignleft size-full wp-image-645" width="254" height="67" title="View CSS" alt="" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/css-button.png"></a></p>
<h3>The Structure</h3>
<p>Again, I refer you to <a href="http://csswizardry.com/2011/10/fully-fluid-responsive-css-carousel/">Harry&#8217;s article</a> as his responsive carousel framework forms the foundations for our click-through image slider.</p>
<pre>
<code>&lt;div id="image-slider"&gt;
    &lt;ul&gt;
        &lt;li&gt;&lt;img src="1.jpg" alt=""&gt;&lt;/li&gt;
        &lt;li&gt;&lt;img src="2.jpg" alt=""&gt;&lt;/li&gt;
        &lt;li&gt;&lt;img src="3.jpg" alt=""&gt;&lt;/li&gt;
    &lt;/ul&gt;
&lt;/div&gt;</code>
</pre>
<p>So we have our images in list items, we have an unordered list to contain these items and we have a viewport that each <code>&lt;li&gt;</code> will occupy, one at a time.</p>
<p>Think of the list as a horizontal row of images and the viewport as a window, with each image sliding by the window to have a peak out.</p>
<h3>The CSS</h3>
<p>Still focusing on Harry&#8217;s framework, here&#8217;s how we style our structural elements&hellip;</p>
<pre>
<code>#image-slider {
    width:100%;
    max-width:500px; /* The actual width of our images */
    overflow:hidden;
    margin:0 auto; /* Just to centre the page */
}

ul {
    width:1000%; /* No. of images * 100% */
    overflow:hidden;
    position:relative;
    list-style:none;
}

ul li {
    float:left;
    width:10%;
}

ul li img {
    max-width:100%;
}</code>
</pre>
<p>It&#8217;s all pretty basic. Remember we said our <code>&lt;ul&gt;</code> needs to be a container for our list items? Well we&#8217;ve got 10 list items, and they all need a width of 100% to fill the viewport, so the <code>&lt;ul&gt;</code> needs to be big enough to contain 10 list-items, each 100% wide. Logically, that means our <code>&lt;ul&gt;</code> width equals 1000%.</p>
<h4>Responsive Images</h4>
<p>The property that really makes the magic happen here is <code>max-width:100%;</code> on the image element. This ensures that the image is only ever as big as its container, so as the browser window reduces in size, so does the images container and so does the image. Who knew responsive web design was so easy?!</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/2a.jpg" alt="Responsive Image" title="Responsive Image"  class="alignleft full-width-img" /></p>
<h3>Navigation Controls</h3>
<p>Moving away from Harry&#8217;s carousel framework, we need to add a little more to the markup &#8211; a vital ingredient of a click-through gallery; navigation controls!</p>
<pre>
<code>&lt;li id="one"&gt;
    &lt;img src="1.jpg" alt=""&gt;
    &lt;a href="#ten"&gt;Back&lt;/a&gt;
    &lt;a href="#two"&gt;Next&lt;/a&gt;
&lt;/li&gt;
&lt;li id="two"&gt;
    &lt;img src="2.jpg" alt=""&gt;
    &lt;a href="#one"&gt;Back&lt;/a&gt;
    &lt;a href="#three"&gt;Next&lt;/a&gt;
&lt;/li&gt;
&lt;li id="three"&gt;
    &lt;img src="3.jpg" alt=""&gt;
    &lt;a href="#two"&gt;Back&lt;/a&gt;
    &lt;a href="#four"&gt;Next&lt;/a&gt;
&lt;/li&gt;</code>
</pre>
<p>So what have we done here? First of all, we&#8217;ve given the list items unique id&#8217;s as we&#8217;ll need them in order to navigate through the image slider. Now, we&#8217;ve given each list item a couple of navigation controls; one to go back to the previous image and one to go forward to the next image.</p>
<p>We&#8217;re slowly getting somewhere now&hellip;</p>
<h3>More CSS to bring things to life</h3>
<p>We&#8217;ve actually done the bulk of the work &#8211; without any CSS3. But we&#8217;re going to call on it now to animate our click-through gallery and actually make it slide.</p>
<pre>
<code>ul li {
    transform:translate(100%, 0);
    transition:all 1s ease;
    /* Don't forget the vendor prefixes! I'm not using them for the sake of simplicity */
}</code>
</pre>
<p>We&#8217;ve used the transform property to translate (move) our list items to the right by 100%. We&#8217;ve also added the transition property, which ensures that when the list item returns to its original position, this shift from right to left will be gradual, creating an animated effect.</p>
<p>So how do we get it back to its original position?</p>
<pre>
<code>#one:target {
    transform:translate(0);
}</code>
</pre>
<p>Easy, no? All we&#8217;ve done here is state that when the list item with an id of #one is targeted (when the link to #one is clicked on), move the list item back to its original position.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/4a.jpg" alt="Transition Effect" title="Transition Effect" class="alignleft full-width-img" /></p>
<p>You will of course need to specify this for each unique list item like so: <code>#one:target, #two:target, #three:target</code> etc..</p>
<p>Feel free to experiment with different transition effects on your targeted element. This is what I&#8217;ve gone for in <a href="http://www.tangledindesign.com/blog/demos/responsive-css3-slider/">my demo</a>:</p>
<pre>
<code>ul li {
    transform:translate(100%, 0) scale(0.1);
    transition:all 1s ease;
    opacity:0;
}

#one:target {
    transform:translate(0) scale(1);
    opacity:1;</code>
</pre>
<p>The above CSS simply adds a couple more effects to make the transition that little bit more pleasing to the eye.</p>
<h3>Fixing things</h3>
<p>You might think we&#8217;ve done it all now. However, a quick resize of the browser suggests otherwise as our responsive framework is now broken. Thankfully, it&#8217;s a simple fix. All we need to do is add <code>position:absolute</code> to our targeted elements.</p>
<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/3a.jpg" alt="Broken Responsive Image" title="Broken Responsive Image"  class="alignleft full-width-img" /></p>
<p>There&#8217;s also the issue of getting the first image to appear when the page loads, i.e. when #one is not targeted. Sure, we could just give #one all of the targeted rule sets, but then this messes up the gallery, as the first image is always visible in every image transition.</p>
<p>So, as a (far from ideal) solution, I&#8217;ve simply added a start button that links to the list item with an id of #one.</p>
<p>This is probably the biggest limitation in terms of using this method in the real world.</p>
<h3>Webkit Issues</h3>
<p>Why is this demo best viewed in Firefox? Well for whatever reason, <code>transform:translate(100%, 0);</code> (together with its corresponding targeted value <code>transform:translate(0);</code>) behaves differently in Chrome and Safari than in Firefox, i.e. it doesn&#8217;t work.</p>
<p>So in my demo, Chrome and Safari don&#8217;t have the sliding effect, they simply make do with scaling and opacity transitions.</p>
<p>I&#8217;ve not yet managed to wrap my tired brain around the problem. <strong>Any help would be brilliant.</strong></p>
<h3>Wrapping Up</h3>
<p>Our outcome is far from ideal.</p>
<ul>
<li>The images slide from the right whether you are going forwards or backwards, which is not natural.</li>
<li>It requires the user to click a link in order to begin viewing the gallery.</li>
<li>Webkit browsers don&#8217;t like the sliding transition, so have to make do with a simple fade in and out.</li>
<li>This method <em>requires</em> the id values (#one, #two etc.) at the end of the URL, which sometimes, you just don&#8217;t want.</li>
</ul>
<p>However, all in all, we have another demonstration of how CSS3 can be used to create effects only previously possible with the help of JavaScript.</p>
<p>And I&#8217;m sure someone with a bit more brain power than me could knock together something similar without the issues my final outcome suffers from.</p>
<p>I&#8217;ve done a few extra bits to make my demo the way it is, specifically in terms of styling the navigation controls, so you may want to take a look at the CSS file to see what&#8217;s going on in detail.</p>
<p><a href="http://www.tangledindesign.com/blog/demos/responsive-css3-slider"><img class="demo-btn alignleft size-full wp-image-643" width="254" height="67" title="View Demo" alt="" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/demo-button1.png"></a><a href="http://www.tangledindesign.com/blog/demos/responsive-css3-slider/main.css"><img class="demo-btn alignleft size-full wp-image-645" width="254" height="67" title="View CSS" alt="" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/05/css-button.png"></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/responsive-css3-sliding-gallery/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/responsive-css3-sliding-gallery/</feedburner:origLink></item>
		<item>
		<title>5 Reasons for Web Designers to Start a Blog, Even if it Doesn’t Bring World Fame</title>
		<link>http://feedproxy.google.com/~r/tangledindesign/~3/PVKucqtENKk/</link>
		<comments>http://www.tangledindesign.com/blog/reasons-for-web-designers-to-start-a-blog/#comments</comments>
		<pubDate>Wed, 02 Nov 2011 21:52:39 +0000</pubDate>
		<dc:creator>Stephen Greig</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[Blogging]]></category>
		<category><![CDATA[Employability]]></category>
		<category><![CDATA[Self-improvement]]></category>

		<guid isPermaLink="false">http://www.tangledindesign.com/blog/?p=1192</guid>
		<description><![CDATA[<a href="http://www.tangledindesign.com/blog/reasons-for-web-designers-to-start-a-blog/"><img align="left" hspace="5" width="269" height="168" src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/featured.jpg" class="alignleft tfe wp-post-image" alt="featured" title="featured" /></a>When you see blogs like Web Designer Wall and Line25 and you realise the recognition and status they achieve, it&#8217;s easy to think &#8216;I wouldn&#8217;t mind a piece of that!&#8217; And that&#8217;s why we now have an extremely dense market &#8230; <a href="http://www.tangledindesign.com/blog/reasons-for-web-designers-to-start-a-blog/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.tangledindesign.com/blog/wp-content/uploads/2011/11/featured.jpg" alt="Featured" title="featured" class="alignleft post-img" />When you see blogs like <a href="http://www.webdesignerwall.com/">Web Designer Wall</a> and <a href="http://line25.com/">Line25</a> and you realise the recognition and status they achieve, it&#8217;s easy to think &#8216;I wouldn&#8217;t mind a piece of that!&#8217; And that&#8217;s why we now have an <em>extremely</em> dense market in terms of Web Design blogs.</p>
<p>Some have made it and have risen to similar levels to the aforementioned sites; others have fizzled into obscurity or are plagued by poor quality content. The few that have made it however make up a tiny percentage of the overall market and represent the elite of the industry (there are inevitably one or two exceptions who have just got lucky).</p>
<p>But the point is, it&#8217;s so easy to set up a Web Design blog and it&#8217;s even easier to think it&#8217;s going to be an instant success, but that is <em>very</em> rarely the case.</p>
<h4>Don&#8217;t be Naive</h4>
<p>So, haven&#8217;t I just described the reasons why you <em>shouldn&#8217;t</em> start blogging?</p>
<p>No.</p>
<p>I&#8217;ve simply expressed a word of caution. Don&#8217;t be naive and don&#8217;t start a blog with the expectation of recognition; that is completely the wrong reason to set up a Web Design blog in the first place. If fame and/or recognition is your sole motive then your chance of failure soars to the dizziest of heights.</p>
<p>Okay then, why <em>should</em> you start a Web Design blog?</p>
<h3>1. Self Improvement</h3>
<p>For me, the biggest benefit of starting a Web Design blog has been educational. There&#8217;s little I don&#8217;t know about <a href="http://www.tangledindesign.com/blog/tag/css3/">CSS3</a> now, but if I&#8217;d never started this blog, my interest in it would never have been sparked and I&#8217;d probably know half as much as I do now.</p>
<p>Seriously, pushing yourself to learn something and having the desire to blog about it will do absolute wonders for you as a practitioner. We can read about stuff &#8217;til our eyes sting, but until we actually put something into practice, it&#8217;s very difficult to get a full understanding of the matter.</p>
<p>After reading about various CSS3 techniques and experimenting with them via this blog, I&#8217;m now constantly thinking of practical ways it could be implemented right now in day to day projects.</p>
<h3>2. It shows you&#8217;re keen</h3>
<p>Near enough everyone who works in the industry claims to be passionate about what they do, but few really demonstrate that claim. Running a blog shows that you want to experiment and refine best practices, you want to push the boundaries, you want to share&hellip; you <em>want</em> to talk about Web Design.</p>
<p>Don&#8217;t think about your peers, don&#8217;t think about recognition; think about potential employers weighing up your suitability for their position. Running a Web Design blog displays the passion that so many claim to have for their work; it shows that you&#8217;re serious about what you do and that you genuinely love doing it.</p>
<p>It looks like your keen and potential employers will eat that up!</p>
<h3>3. It&#8217;s like a portfolio, but with context</h3>
<p>A blog doesn&#8217;t just show your keen, it shows what you can do and what you&#8217;ve been doing to better yourself. Consider a standard application for a Web Design position&hellip; what might you send off? A CV and your portfolio, right?</p>
<p>Your blog would be like your portfolio, but of far more value to those who are sizing you up. A portfolio pretty much shows what you can do, whereas a blog shows what you can do, with <em>context</em>.</p>
<p>It&#8217;s your portfolio, but with explanation, with discussion and a representation of your thought processes. This is 10x more valuable to a potential employer than simply looking at your CV and some work examples!</p>
<h3>4. Exposure</h3>
<p>I know I stated earlier I don&#8217;t believe you should start a Web Design blog if your main concern is receiving recognition and exposure. But exposure you will get, and it is to your benefit, how ever limited this exposure may be.</p>
<p>It puts yourself out there, it makes you available to those who want to look and you never know who may stumble across your scribbles.</p>
<p>Exposure shouldn&#8217;t be your goal, but it should be the result of your passion to create quality content.</p>
<h3>5. It&#8217;s your platform</h3>
<p>A blog is your playground. Think of it like a sketcher&#8217;s doodle pad. If they don&#8217;t have their pad to scribble down their ideas and let their pencil wander, a lot of their ideas would simply fade away into non-existence. Sometimes you need to get your thoughts out of your head and into something visual, with structure.</p>
<p>If you&#8217;ve got something you want to say or express, I&#8217;d say it&#8217;s pretty advisable to have a space where you can do this. You might write things down or post things on Twitter, but they have their limitations. Your blog is whatever you want it to be; it&#8217;s your platform and on your platform, you can say and do whatever you want.</p>
<p>Build your platform, climb up onto it and have your say.</p>
<h3>So what are you waiting for?</h3>
<p>Seriously, if you start blogging about Web Design and ensure it&#8217;s fairly regular, it will soon become infinitely more valuable than anything else in your portfolio.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.tangledindesign.com/blog/reasons-for-web-designers-to-start-a-blog/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		<feedburner:origLink>http://www.tangledindesign.com/blog/reasons-for-web-designers-to-start-a-blog/</feedburner:origLink></item>
	</channel>
</rss>
