<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	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/"
	>

<channel>
	<title>Joshua Mauldin &#187; forms</title>
	<atom:link href="http://joshuamauldin.com/blog/tag/forms/feed/" rel="self" type="application/rss+xml" />
	<link>http://joshuamauldin.com/blog</link>
	<description>A blog where technerdery, design and startup-related articles abound.</description>
	<lastBuildDate>Wed, 05 May 2010 22:27:55 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<cloud domain='joshuamauldin.com' port='80' path='/blog/?rsscloud=notify' registerProcedure='' protocol='http-post' />
		<item>
		<title>Using CSS Transformations: A How-To</title>
		<link>http://joshuamauldin.com/blog/2009/07/using-css-transformations/</link>
		<comments>http://joshuamauldin.com/blog/2009/07/using-css-transformations/#comments</comments>
		<pubDate>Wed, 15 Jul 2009 15:10:03 +0000</pubDate>
		<dc:creator>Josh</dc:creator>
				<category><![CDATA[Design]]></category>
		<category><![CDATA[css3]]></category>
		<category><![CDATA[forms]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[ui]]></category>

		<guid isPermaLink="false">http://joshuamauldin.com/blog/?p=483</guid>
		<description><![CDATA[Lately I&#8217;ve been using more advanced CSS3 transformations in my design—both for Webkit and Mozilla—and I wanted to share some of what I&#8217;ve been doing.
I&#8217;ve launched two sites in the last little bit that take advantage of those: a site for musician Brooks Wood and a site for Houston-based Leyendecker Landscape. In both of these, [...]]]></description>
			<content:encoded><![CDATA[<p>Lately I&#8217;ve been using more advanced CSS3 transformations in my design—both for Webkit and Mozilla—and I wanted to share some of what I&#8217;ve been doing.</p>
<p>I&#8217;ve launched two sites in the last little bit that take advantage of those: a site for musician <a title="Check out Brooks Wood's Site!" href="http://brookswood.net/">Brooks Wood</a> and a site for Houston-based <a title="Visit Leyendecker Landscape's Site!" href="http://leyendeckerlandscape.com/">Leyendecker Landscape</a>. In both of these, I&#8217;ve tried to take advantage of some great CSS features for those browsers that can handle it and just letting those that can&#8217;t ignore it. In this demo, I&#8217;m focusing on the form elements since they&#8217;ve always tended to be boring.</p>
<p>I&#8217;ve attached a link to a <a title="View a working demo of this CSS" href="http://joshuamauldin.com/docs/css-transform.html" target="_blank">working demo</a> of the forms with a brief explanation of how I did what I did. Read on for more.<span id="more-483"></span></p>
<p>One note before we get started: Firefox 3 supports some of this, but Safari 3 and 4 support much more. I&#8217;ve included things which Firefox 3.5 supports, just so those users can have  a little fun, too.</p>
<p><strong>Easing the transition</strong></p>
<p>When a user focuses on any of the fields or the submit button, I&#8217;ve added a transformation that will magnify the input area, similar to a magnifying glass and ease it in/out for Webkit users. Here&#8217;s the code:</p>
<p><code>-webkit-transition: all 0.1s ease-out;</code></p>
<p>This smoothes the transition from the normal state of the form to its active state. As of the Firefox 3.5, the <code>transition</code> property isn&#8217;t supported. You&#8217;ll want to add this onto the main element, in this case we&#8217;ve added it to the <code>input</code> tag.</p>
<p><strong>Scaling the elements</strong></p>
<p>Both of these will scale both the input area and the text within it to be just a little larger than they were before the user clicked into them.</p>
<p><code>-webkit-transform: scale(1.2);</code> <code>-moz-transform: scale(1.2);</code></p>
<p>I&#8217;ve added a few more lines of code for some additional styling, such as <code>border-radius</code> to smooth the edges of the field elements. You can view all that information in the source of this page, but here&#8217;s how to smooth the edges of an element:</p>
<p><code>-webkit-border-radius: 6px;</code> <code>-moz-border-radius: 6px;</code></p>
<p><strong>Styling the submit button</strong></p>
<p>I&#8217;ve also done a little work on the submit button, which is a little more complex.</p>
<p><code> background: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#fff), color-stop(0.5, #ccc)); </code></p>
<p>While I&#8217;ve also added <code>border-radius</code> and a few more goodies to the submit button, the part which creates the gradient is above. It creates a color gradient that starts at the top left of the element and goes to the bottom of the element. The gradient starts with white, goes to silver halfway and then back to white at the bottom. If you wanted to adjust where the gradient goes to silver, you can change the <code>color-stop</code> value to something like .25 for 1/4 of the way down, or .75 for 3/4 of the way down.</p>
]]></content:encoded>
			<wfw:commentRss>http://joshuamauldin.com/blog/2009/07/using-css-transformations/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>
