/neat

Lightweight alternative for jQuery UI

Primary LanguageJavaScriptMIT LicenseMIT

neat

neat is a lightweight UI handler for jQuery.

Why (is it) neat?

jQuery UI is overloaded and bloated. neat is not.

How to use?

First include jQuery, then neat in your site:

<script src="//code.jquery.com/jquery-latest.min.js"></script> <script src="jquery.neat.min.js"></script>

Use the neat methods (you can find more about methods in the wiki):

<script> $(function(){ $('.element').method(); }); </script>

Methods

.accordion()

Create an accordion using a plain definition list:

This is the title of the first pane
This is a description.
This is the title of the second pane
This is a description.

Load and customize it:

$('.accordion').accordion({ 'speed': 200 // Defines the toggle speed of each item });

.tabs()

Create a tabbed navigation using a list and articles:

Inhalt des ersten Tabs. Inhalt des zweiten Tabs.

Load it:

$('.tabs').tabs();

.tooltip()

TODO: Describe what it does and how to use ...

.center()

TODO: Describe what it does and how to use ...

Further information

Minified version

Reduce loading times and use the minified version of the plugin here.

Delays on Mobile Devices

Many mobile browsers add a 300ms-delay to each click-event (to check for double-tapping). To get around this, you just need to implement [fastclick] (http://build.origami.ft.com/bundles/js?modules=fastclick):

$(function() { FastClick.attach(document.body); });