Permalink
Browse files

cleaned up documentation

  • Loading branch information...
1 parent e56bd43 commit 19520e499807acff42c48d8560c9d097c1d09ca8 @andrewwatts committed Jan 18, 2010
Showing with 13 additions and 13 deletions.
  1. +3 −6 README.md
  2. +1 −6 ui.tabs.closable.js
  3. +9 −1 ui.tabs.closable.min.js
View
@@ -19,12 +19,9 @@ How To Use
overview at the [jQuery UI Tabs][jQuery UI Tabs] site to get an idea of
what is possible.
1. Include the javascript file in your html file or js loader. eg:
-
- `<script type="text/javascript" src="ui.tabs.closable.min.js"></script>`
-
-2. add a closable option when instatiating the tabs:
-
- `$('#tabs').tabs({closable: true})`
+ <script type="text/javascript" src="ui.tabs.closable.min.js"></script>
+2. add a `closable` option when instatiating the tabs:
+ $('#tabs').tabs({closable: true})
That's it, about as unobtrusive as I could make it.
View
@@ -1,15 +1,10 @@
/*!
- *
* Copyright (c) 2010 Andrew Watts
*
* Dual licensed under the MIT (MIT_LICENSE.txt)
* and GPL (GPL_LICENSE.txt) licenses
*
- * http://github.com/andrewwatts/
- *
- * Depends:
- * jquery-ui
- *
+ * http://github.com/andrewwatts/ui.tabs.closable
*/
(function() {
View
@@ -1,2 +1,10 @@
+/*!
+ * Copyright (c) 2010 Andrew Watts
+ *
+ * Dual licensed under the MIT (MIT_LICENSE.txt)
+ * and GPL (GPL_LICENSE.txt) licenses
+ *
+ * http://github.com/andrewwatts/ui.tabs.closable
+ */
(function(){var c=$.ui.tabs.prototype._tabify;$.extend($.ui.tabs.prototype,{_tabify:function(){var a=this;c.apply(this,arguments);a.options.closable===true&&this.lis.filter(function(){return $("span.ui-icon-circle-close",this).length===0}).each(function(){$(this).append('<a href="#"><span class="ui-icon ui-icon-circle-close"></span></a>').find("a:last").hover(function(){$(this).css("cursor","pointer")},function(){$(this).css("cursor","default")}).click(function(){var b=a.lis.index($(this).parent());
-b>-1&&a.remove(b);return false}).end()})}})})(jQuery);
+b>-1&&a.remove(b);return false}).end()})}})})(jQuery);

0 comments on commit 19520e4

Please sign in to comment.