<?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>Made of Everything You&#039;re Not &#187; user interface</title>
	<atom:link href="http://blog.ericlamb.net/tag/user-interface/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.ericlamb.net</link>
	<description>Thoughts on programming, people and life</description>
	<lastBuildDate>Thu, 29 Jul 2010 07:00:32 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Introduction to jQuery UI</title>
		<link>http://blog.ericlamb.net/2009/11/introduction-to-jquery-ui/</link>
		<comments>http://blog.ericlamb.net/2009/11/introduction-to-jquery-ui/#comments</comments>
		<pubDate>Fri, 06 Nov 2009 13:00:49 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[user interface]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=1931</guid>
		<description><![CDATA[Building the fancy, web 2.0 / Ajaxy, user interfaces for a web application we&#8217;ve all come to expect is, frankly, a pain in the ass. Depending on the JavaScript library you&#8217;re using there&#8217;s usually some addon library to extend the functionality for UI which helps make it easier and ease the pain. If you&#8217;re using [...]]]></description>
			<content:encoded><![CDATA[<p>Building the fancy, web 2.0 / Ajaxy, user interfaces for a web application we&#8217;ve all come to expect is, frankly, a pain in the ass. Depending on the JavaScript library you&#8217;re using there&#8217;s usually some addon library to extend the functionality for UI which helps make it easier and ease the pain. If you&#8217;re using <a title="jQuery" href="http://jquery.com/" onclick="return TrackClick('http%3A%2F%2Fjquery.com%2F','jQuery')" target="_blank">jQuery</a> (and to be honest I&#8217;m more of a Prototype guy) a good library is <a title="jQuery Ui" href="http://jqueryui.com/home" onclick="return TrackClick('http%3A%2F%2Fjqueryui.com%2Fhome','jQuery+Ui')" target="_blank">jQuery Ui</a>.</p>
<div id="attachment_2609" class="wp-caption aligncenter" style="width: 268px"><a href="http://blog.ericlamb.net/wp-content/uploads/2009/11/JQuery_UI_Logo.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2009%2F11%2FJQuery_UI_Logo.png','JQuery+UI')"><img class="size-full wp-image-2609" title="JQuery UI" src="http://blog.ericlamb.net/wp-content/uploads/2009/11/JQuery_UI_Logo.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2009%2F11%2FJQuery_UI_Logo.png','JQuery+UI')" alt="JQuery UI" width="258" height="93" /></a><p class="wp-caption-text">JQuery UI</p></div>
<p>According to the official site:</p>
<blockquote><p>jQuery UI is an open source library of interface components — <a href="http://jqueryui.com/demos" onclick="return TrackClick('http%3A%2F%2Fjqueryui.com%2Fdemos','interactions%2C+full-featured+widgets%2C+and+animation+effects')" target="_blank">interactions, full-featured widgets, and animation effects</a> — based on the stellar <a href="http://jquery.com" onclick="return TrackClick('http%3A%2F%2Fjquery.com','jQuery+javascript+library')" target="_blank">jQuery javascript library</a>.  Each component is built according to <a href="http://docs.jquery.com/How_jQuery_Works" onclick="return TrackClick('http%3A%2F%2Fdocs.jquery.com%2FHow_jQuery_Works','jQuery%22s+event-driven+architecture')" target="_blank">jQuery&#8217;s event-driven architecture</a> (find something, manipulate it) and is <a href="http://jqueryui.com/docs/Theming" onclick="return TrackClick('http%3A%2F%2Fjqueryui.com%2Fdocs%2FTheming','themeable')" target="_blank">themeable</a>, making it easy for developers of any skill level to integrate and extend into their own code.</p></blockquote>
<p>I only ran into it because of an update to WP-Click-Track and WordPress uses jQuery so I kinda had to. Not that it&#8217;s a bad thing; I like jQuery a little bit more because of jQuery UI.</p>
<p>One of the really cool things about jQuery UI is that there&#8217;s an online tool to generate a custom download specific to the project. Having worked with JavaScript libraries for a while I appreciate the customization and convenience of having the smallest footprint as possible. Kudos to them on that.</p>
<p>There&#8217;s also a <a title="jQuery UI Theme Builder" href="http://jqueryui.com/themeroller/" onclick="return TrackClick('http%3A%2F%2Fjqueryui.com%2Fthemeroller%2F','jQuery+UI+Theme+Builder')" target="_blank">Theme Builder</a> that gives a good overview of what&#8217;s available by default along with some preset themes to test; there&#8217;s a good deal of widgets there to work with. Almost, <em>almost</em>, makes me want to start a project with it.</p>
<div id="attachment_2617" class="wp-caption aligncenter" style="width: 215px"><a href="http://blog.ericlamb.net/wp-content/uploads/2009/11/jQuery-UI-ThemeRoller_1257127607785.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2009%2F11%2FjQuery-UI-ThemeRoller_1257127607785.png','jQuery+UI+-+ThemeRoller')"><img class="size-medium wp-image-2617" title="jQuery UI - ThemeRoller" src="http://blog.ericlamb.net/wp-content/uploads/2009/11/jQuery-UI-ThemeRoller_1257127607785-205x300.png" alt="jQuery UI - ThemeRoller" width="205" height="300" /></a><p class="wp-caption-text">jQuery UI - ThemeRoller</p></div>
<p>Implementation is really elegant too; if you know how jQuery works it&#8217;ll be pretty obvious. Otherwise take a look at the below for creating tabs:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">&lt;div id=&quot;tab-jquery-id&quot;&gt;
	&lt;ul&gt;
		&lt;li&gt;&lt;a href=&quot;#tab1&quot;&gt;Tab 1&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;&lt;a href=&quot;#tab2&quot;&gt;Tab 2&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;&lt;a href=&quot;#tab3&quot;&gt;Tab 3&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;&lt;a href=&quot;#tab4&quot;&gt;Tab 4&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;&lt;a href=&quot;#tab5&quot;&gt;Tab 5&lt;/a&gt;&lt;/li&gt;
	&lt;/ul&gt;
	&lt;div id=&quot;tab1&quot;&gt;
&nbsp;
	&lt;/div&gt;
	&lt;div id=&quot;tab2&quot;&gt;
&nbsp;
	&lt;/div&gt;
	&lt;div id=&quot;tab3&quot;&gt;
&nbsp;
	&lt;/div&gt;
	&lt;div id=&quot;tab4&quot;&gt;
&nbsp;
	&lt;/div&gt;
	&lt;div id=&quot;tab5&quot;&gt;
&nbsp;
	&lt;/div&gt;
&lt;/div&gt;
&nbsp;
<span style="color: #339933;">&lt;</span>script type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;</span>
<span style="color: #006600; font-style: italic;">//&lt;![CDATA[</span>
jQuery<span style="color: #000;">&#40;</span>document<span style="color: #000;">&#41;</span>.<span style="color: #660066;">ready</span><span style="color: #000;">&#40;</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #000;">&#40;</span>$<span style="color: #000;">&#41;</span> <span style="color: #000;">&#123;</span>
	<span style="color: #006600; font-style: italic;">//jQuery UI 1.5.2 doesn't expect tab ID's at DIV, so we have to apply a hotfix instead</span>
	<span style="color: #003366; font-weight: bold;">var</span> needs_jquery_hotfix <span style="color: #339933;">=</span> <span style="color: #000;">&#40;</span><span style="color: #000;">&#40;</span>$.<span style="color: #660066;">ui</span>.<span style="color: #660066;">version</span> <span style="color: #339933;">===</span> undefined<span style="color: #000;">&#41;</span> <span style="color: #339933;">||</span> <span style="color: #339933;">!</span>$.<span style="color: #660066;">ui</span>.<span style="color: #660066;">version</span>.<span style="color: #660066;">match</span><span style="color: #000;">&#40;</span><span style="color: #009966; font-style: italic;">/^(1\.[7-9]|[2-9]\.)/</span><span style="color: #000;">&#41;</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
	$<span style="color: #000;">&#40;</span><span style="color: #3366CC;">&quot;#tab-jquery-id&quot;</span><span style="color: #339933;">+</span><span style="color: #000;">&#40;</span>needs_jquery_hotfix <span style="color: #339933;">?</span> <span style="color: #3366CC;">&quot;&gt;ul&quot;</span> <span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;&quot;</span><span style="color: #000;">&#41;</span><span style="color: #000;">&#41;</span>.<span style="color: #660066;">tabs</span><span style="color: #000;">&#40;</span><span style="color: #000;">&#123;</span>
		selected<span style="color: #339933;">:</span> <span style="color: #CC0000;">0</span>
	<span style="color: #000;">&#125;</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span> 
	$<span style="color: #000;">&#40;</span><span style="color: #3366CC;">'.tab5:last'</span><span style="color: #000;">&#41;</span>.<span style="color: #660066;">show</span><span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span>.<span style="color: #660066;">removeClass</span><span style="color: #000;">&#40;</span><span style="color: #3366CC;">'tab5'</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000;">&#125;</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #006600; font-style: italic;">//]]&gt;</span>
<span style="color: #339933;">&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></div></div>

<p>As you can see there&#8217;s not much there in so far as design or class decorators go; most of that&#8217;s handled by jQuery itself as well as the generated css. The only thing to really worry about is adding the wrapper div id in the bottom JavaScript. Still, not a bad thing.</p>
<p>This, of course, barely scratched the surface of jQuery UI but it doesn&#8217;t get much more difficult. If you&#8217;re using jQuery for a library and you need to make something cool it&#8217;s definitely worth checking out.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2009/11/introduction-to-jquery-ui/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
