compass-jquery-plugin 0.3.2.3 → 0.3.2.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (235) hide show
  1. data/README.md +54 -37
  2. data/VERSION.yml +1 -1
  3. data/lib/handle_attributes.rb +4 -4
  4. data/lib/handle_js_files.rb +5 -5
  5. data/lib/jqtouch_theme.rb +2 -2
  6. data/lib/jquery/dynatree.rb +2 -2
  7. data/lib/jquery/emulators.rb +1 -1
  8. data/lib/jquery/flash_messages.rb +6 -6
  9. data/lib/jquery/graphics.rb +5 -0
  10. data/lib/jquery/gridify/assertions.rb +1 -1
  11. data/lib/jquery/gridify/grid.rb +76 -59
  12. data/lib/jquery/gridify/grid_column.rb +73 -67
  13. data/lib/jquery/gridify/grid_finder.rb +79 -79
  14. data/lib/jquery/gridify/grid_options.rb +154 -149
  15. data/lib/jquery/gridify/grid_view.rb +143 -143
  16. data/lib/jquery/gridify.rb +25 -25
  17. data/lib/jquery/ical/calendar.rb +2 -2
  18. data/lib/jquery/ical/event.rb +48 -44
  19. data/lib/jquery/ical/helpers/ui_event_helper.rb +3 -3
  20. data/lib/jquery/jqgrid/jqgrid.rb +58 -58
  21. data/lib/jquery/jqgrid.rb +1 -1
  22. data/lib/jquery/jqtouch.rb +1 -1
  23. data/lib/jquery/jquery.rb +117 -117
  24. data/lib/jquery/jquery_auto_complete.rb +9 -9
  25. data/lib/jquery/jquery_json_response.rb +12 -12
  26. data/lib/jquery/jquery_selector_assertions.rb +55 -53
  27. data/lib/jquery/jstree.rb +2 -2
  28. data/lib/jquery/mobile.rb +1 -1
  29. data/lib/jquery/ribbon.rb +2 -2
  30. data/lib/jquery/secret_sauce/controller/ui_dialog_controls.rb +5 -5
  31. data/lib/jquery/secret_sauce/controller/ui_grid_controls.rb +5 -5
  32. data/lib/jquery/secret_sauce/helpers/ui_dialog_helper.rb +1 -1
  33. data/lib/jquery/secret_sauce/helpers/ui_form_helper.rb +39 -39
  34. data/lib/jquery/secret_sauce/helpers/ui_grid_helper.rb +74 -74
  35. data/lib/jquery/secret_sauce/model/find_for_grid.rb +21 -21
  36. data/lib/jquery/secret_sauce.rb +1 -1
  37. data/lib/jquery/tools.rb +1 -1
  38. data/lib/jquery_mobile_theme.rb +2 -2
  39. data/lib/jquery_ui_theme.rb +12 -12
  40. data/templates/dynatree/config/initializers/dynatree.rb +3 -3
  41. data/templates/dynatree/jquery/dynatree/aero.scss +16 -16
  42. data/templates/dynatree/jquery/dynatree/aqua.scss +16 -16
  43. data/templates/dynatree/jquery/dynatree/crystal.scss +16 -16
  44. data/templates/dynatree/jquery/dynatree/xp.scss +17 -17
  45. data/templates/dynatree/jquery.dynatree.js +2926 -2912
  46. data/templates/emulators/config/initializers/emulators.rb +6 -6
  47. data/templates/graphics/config/initializers/graphics.rb +5 -0
  48. data/templates/graphics/jquery/ganttView.scss +89 -0
  49. data/templates/graphics/jquery.ganttView.js +1669 -0
  50. data/templates/graphics/jquery.ganttView.min.js +70 -0
  51. data/templates/{jquery → graphics}/jquery.sparkline.js +466 -438
  52. data/templates/{jquery → graphics}/jquery.sparkline.min.js +0 -0
  53. data/templates/graphics/manifest.rb +9 -0
  54. data/templates/jqgrid/config/initializers/jqgrid.rb +1 -1
  55. data/templates/jqgrid/i18n/jqgrid/locale-ar.js +131 -125
  56. data/templates/jqgrid/i18n/jqgrid/locale-bg.js +135 -131
  57. data/templates/jqgrid/i18n/jqgrid/locale-bg1251.js +135 -131
  58. data/templates/jqgrid/i18n/jqgrid/locale-cat.js +132 -126
  59. data/templates/jqgrid/i18n/jqgrid/locale-cn.js +137 -131
  60. data/templates/jqgrid/i18n/jqgrid/locale-cs.js +133 -127
  61. data/templates/jqgrid/i18n/jqgrid/locale-da.js +132 -126
  62. data/templates/jqgrid/i18n/jqgrid/locale-de.js +138 -132
  63. data/templates/jqgrid/i18n/jqgrid/locale-el.js +131 -125
  64. data/templates/jqgrid/i18n/jqgrid/locale-en.js +133 -127
  65. data/templates/jqgrid/i18n/jqgrid/locale-es.js +133 -127
  66. data/templates/jqgrid/i18n/jqgrid/locale-fa.js +19 -16
  67. data/templates/jqgrid/i18n/jqgrid/locale-fi.js +132 -126
  68. data/templates/jqgrid/i18n/jqgrid/locale-fr.js +131 -125
  69. data/templates/jqgrid/i18n/jqgrid/locale-gl.js +131 -125
  70. data/templates/jqgrid/i18n/jqgrid/locale-he.js +132 -126
  71. data/templates/jqgrid/i18n/jqgrid/locale-hu.js +133 -127
  72. data/templates/jqgrid/i18n/jqgrid/locale-is.js +131 -125
  73. data/templates/jqgrid/i18n/jqgrid/locale-it.js +8 -1
  74. data/templates/jqgrid/i18n/jqgrid/locale-ja.js +139 -136
  75. data/templates/jqgrid/i18n/jqgrid/locale-nl.js +4 -1
  76. data/templates/jqgrid/i18n/jqgrid/locale-no.js +14 -1
  77. data/templates/jqgrid/i18n/jqgrid/locale-pl.js +132 -126
  78. data/templates/jqgrid/i18n/jqgrid/locale-pt-br.js +132 -126
  79. data/templates/jqgrid/i18n/jqgrid/locale-pt.js +130 -124
  80. data/templates/jqgrid/i18n/jqgrid/locale-ro.js +144 -138
  81. data/templates/jqgrid/i18n/jqgrid/locale-ru.js +132 -126
  82. data/templates/jqgrid/i18n/jqgrid/locale-sk.js +132 -126
  83. data/templates/jqgrid/i18n/jqgrid/locale-sr.js +133 -127
  84. data/templates/jqgrid/i18n/jqgrid/locale-sv.js +132 -126
  85. data/templates/jqgrid/i18n/jqgrid/locale-tr.js +131 -125
  86. data/templates/jqgrid/i18n/jqgrid/locale-ua.js +132 -126
  87. data/templates/jqgrid/jquery.jqGrid.js +12735 -10444
  88. data/templates/jqgrid/jquery.jqGrid.min.js +477 -469
  89. data/templates/jqgrid/public/stylesheets/ellipsis-xbl.xml +12 -10
  90. data/templates/jqtouch/config/initializers/jqtouch.rb +3 -3
  91. data/templates/jqtouch/jquery/touch/jqtouch.scss +1 -1
  92. data/templates/jqtouch/jquery.jqtouch.js +10025 -10043
  93. data/templates/jquery/config/initializers/jquery.rb +2 -4
  94. data/templates/jquery/history.adapter.jquery.js +71 -0
  95. data/templates/jquery/history.adapter.jquery.min.js +4 -0
  96. data/templates/jquery/history.html4.js +690 -0
  97. data/templates/jquery/history.html4.min.js +21 -0
  98. data/templates/jquery/history.js +1297 -0
  99. data/templates/jquery/history.min.js +29 -0
  100. data/templates/jquery/i18n/jquery.ui/datepicker-af.js +20 -20
  101. data/templates/jquery/i18n/jquery.ui/datepicker-ar-DZ.js +19 -19
  102. data/templates/jquery/i18n/jquery.ui/datepicker-ar.js +19 -19
  103. data/templates/jquery/i18n/jquery.ui/datepicker-az.js +19 -19
  104. data/templates/jquery/i18n/jquery.ui/datepicker-bg.js +8 -8
  105. data/templates/jquery/i18n/jquery.ui/datepicker-bs.js +20 -20
  106. data/templates/jquery/i18n/jquery.ui/datepicker-ca.js +20 -20
  107. data/templates/jquery/i18n/jquery.ui/datepicker-cs.js +20 -20
  108. data/templates/jquery/i18n/jquery.ui/datepicker-da.js +14 -14
  109. data/templates/jquery/i18n/jquery.ui/datepicker-de.js +20 -20
  110. data/templates/jquery/i18n/jquery.ui/datepicker-el.js +20 -20
  111. data/templates/jquery/i18n/jquery.ui/datepicker-en-AU.js +20 -20
  112. data/templates/jquery/i18n/jquery.ui/datepicker-en-GB.js +20 -20
  113. data/templates/jquery/i18n/jquery.ui/datepicker-en-NZ.js +20 -20
  114. data/templates/jquery/i18n/jquery.ui/datepicker-eo.js +20 -20
  115. data/templates/jquery/i18n/jquery.ui/datepicker-es.js +20 -20
  116. data/templates/jquery/i18n/jquery.ui/datepicker-et.js +20 -20
  117. data/templates/jquery/i18n/jquery.ui/datepicker-eu.js +20 -20
  118. data/templates/jquery/i18n/jquery.ui/datepicker-fa.js +18 -18
  119. data/templates/jquery/i18n/jquery.ui/datepicker-fi.js +15 -15
  120. data/templates/jquery/i18n/jquery.ui/datepicker-fo.js +20 -20
  121. data/templates/jquery/i18n/jquery.ui/datepicker-fr-CH.js +20 -20
  122. data/templates/jquery/i18n/jquery.ui/datepicker-fr.js +22 -22
  123. data/templates/jquery/i18n/jquery.ui/datepicker-gl.js +20 -20
  124. data/templates/jquery/i18n/jquery.ui/datepicker-he.js +20 -20
  125. data/templates/jquery/i18n/jquery.ui/datepicker-hr.js +20 -20
  126. data/templates/jquery/i18n/jquery.ui/datepicker-hu.js +20 -20
  127. data/templates/jquery/i18n/jquery.ui/datepicker-hu.min.js +1 -1
  128. data/templates/jquery/i18n/jquery.ui/datepicker-hy.js +20 -20
  129. data/templates/jquery/i18n/jquery.ui/datepicker-id.js +20 -20
  130. data/templates/jquery/i18n/jquery.ui/datepicker-is.js +20 -20
  131. data/templates/jquery/i18n/jquery.ui/datepicker-it.js +20 -20
  132. data/templates/jquery/i18n/jquery.ui/datepicker-ja.js +20 -20
  133. data/templates/jquery/i18n/jquery.ui/datepicker-ko.js +20 -20
  134. data/templates/jquery/i18n/jquery.ui/datepicker-kz.js +20 -20
  135. data/templates/jquery/i18n/jquery.ui/datepicker-lt.js +20 -20
  136. data/templates/jquery/i18n/jquery.ui/datepicker-lv.js +20 -20
  137. data/templates/jquery/i18n/jquery.ui/datepicker-ml.js +20 -20
  138. data/templates/jquery/i18n/jquery.ui/datepicker-ms.js +20 -20
  139. data/templates/jquery/i18n/jquery.ui/datepicker-nl.js +20 -20
  140. data/templates/jquery/i18n/jquery.ui/datepicker-no.js +16 -16
  141. data/templates/jquery/i18n/jquery.ui/datepicker-no.min.js +2 -2
  142. data/templates/jquery/i18n/jquery.ui/datepicker-pl.js +20 -20
  143. data/templates/jquery/i18n/jquery.ui/datepicker-pt-BR.js +20 -20
  144. data/templates/jquery/i18n/jquery.ui/datepicker-pt.js +20 -20
  145. data/templates/jquery/i18n/jquery.ui/datepicker-rm.js +18 -18
  146. data/templates/jquery/i18n/jquery.ui/datepicker-ro.js +20 -20
  147. data/templates/jquery/i18n/jquery.ui/datepicker-ru.js +20 -20
  148. data/templates/jquery/i18n/jquery.ui/datepicker-sk.js +20 -20
  149. data/templates/jquery/i18n/jquery.ui/datepicker-sl.js +20 -20
  150. data/templates/jquery/i18n/jquery.ui/datepicker-sq.js +20 -20
  151. data/templates/jquery/i18n/jquery.ui/datepicker-sr-SR.js +20 -20
  152. data/templates/jquery/i18n/jquery.ui/datepicker-sr.js +20 -20
  153. data/templates/jquery/i18n/jquery.ui/datepicker-sv.js +14 -14
  154. data/templates/jquery/i18n/jquery.ui/datepicker-ta.js +20 -20
  155. data/templates/jquery/i18n/jquery.ui/datepicker-th.js +20 -20
  156. data/templates/jquery/i18n/jquery.ui/datepicker-tr.js +20 -20
  157. data/templates/jquery/i18n/jquery.ui/datepicker-uk.js +20 -20
  158. data/templates/jquery/i18n/jquery.ui/datepicker-vi.js +20 -20
  159. data/templates/jquery/i18n/jquery.ui/datepicker-zh-CN.js +20 -20
  160. data/templates/jquery/i18n/jquery.ui/datepicker-zh-HK.js +20 -20
  161. data/templates/jquery/i18n/jquery.ui/datepicker-zh-TW.js +20 -20
  162. data/templates/jquery/{partials → jquery/ui}/_flash_messages.scss +0 -0
  163. data/templates/jquery/jquery/ui/_theme.scss +14 -13
  164. data/templates/jquery/jquery/ui/contextMenu/configure.png +0 -0
  165. data/templates/jquery/jquery/ui/contextMenu/copy.png +0 -0
  166. data/templates/jquery/jquery/ui/contextMenu/cut.png +0 -0
  167. data/templates/jquery/jquery/ui/contextMenu/delete.png +0 -0
  168. data/templates/jquery/jquery/ui/contextMenu/edit.png +0 -0
  169. data/templates/jquery/jquery/ui/contextMenu/exit.png +0 -0
  170. data/templates/jquery/jquery/ui/contextMenu/new.png +0 -0
  171. data/templates/jquery/jquery/ui/contextMenu/paste.png +0 -0
  172. data/templates/jquery/jquery/ui/contextMenu/rename.png +0 -0
  173. data/templates/jquery/jquery/ui/contextMenu/show.png +0 -0
  174. data/templates/jquery/jquery/ui/contextMenu/trash.png +0 -0
  175. data/templates/jquery/jquery/ui/contextMenu.scss +16 -10
  176. data/templates/jquery/jquery-ui.js +11839 -23066
  177. data/templates/jquery/jquery-ui.min.js +401 -795
  178. data/templates/jquery/jquery.bgiframe.js +27 -25
  179. data/templates/jquery/jquery.contextMenu.js +209 -196
  180. data/templates/jquery/jquery.cookie.js +3 -1
  181. data/templates/jquery/jquery.dotimeout.js +236 -228
  182. data/templates/jquery/jquery.dst.js +154 -151
  183. data/templates/jquery/jquery.farbtastic.js +293 -293
  184. data/templates/jquery/jquery.flashMessages.js +26 -0
  185. data/templates/jquery/jquery.flashMessages.min.js +1 -0
  186. data/templates/jquery/jquery.form.js +803 -786
  187. data/templates/jquery/jquery.haml.js +248 -247
  188. data/templates/jquery/jquery.hotkeys.js +89 -89
  189. data/templates/jquery/jquery.js +8141 -8106
  190. data/templates/jquery/jquery.layout.js +2451 -2415
  191. data/templates/jquery/jquery.min.js +167 -166
  192. data/templates/jquery/jquery.mousewheel.js +62 -54
  193. data/templates/jquery/jquery.offline.js +171 -171
  194. data/templates/jquery/jquery.pngFix.js +76 -76
  195. data/templates/jquery/jquery.replacetext.js +83 -83
  196. data/templates/jquery/jquery.themeswitchertool.js +202 -177
  197. data/templates/jquery/jquery.tmpl.js +478 -473
  198. data/templates/jquery/jquery.tmplPlus.js +82 -81
  199. data/templates/jquery/jrails.js +178 -175
  200. data/templates/jquery/json.js +77 -7
  201. data/templates/jquery/json2.js +480 -0
  202. data/templates/jquery/json2.min.js +7 -0
  203. data/templates/jquery/lib/tasks/haml.rake +2 -2
  204. data/templates/jquery/manifest.rb +21 -17
  205. data/templates/jstree/jquery.jstree.js +5967 -4536
  206. data/templates/mobile/config/initializers/mobile.rb +1 -1
  207. data/templates/mobile/jquery/mobile/_base.scss +944 -927
  208. data/templates/mobile/jquery/mobile/default.scss +61 -48
  209. data/templates/mobile/jquery/mobile/valencia.scss +56 -42
  210. data/templates/mobile/jquery.mobile.js +4461 -4347
  211. data/templates/mobile/jquery.mobile.min.js +11 -2
  212. data/templates/mobile/lib/tasks/jquery.mobile.rake +12 -12
  213. data/templates/ribbon/config/initializers/ribbon.rb +2 -2
  214. data/templates/ribbon/jquery.ribbon.js +50 -29
  215. data/templates/secret_sauce/secret_sauce.js +8 -8
  216. data/templates/tools/flowplayer.js +945 -1
  217. data/templates/tools/jquery.tools.js +4645 -4335
  218. data/templates/tools/jquery.tools.min.js +37 -37
  219. data/templates/tools/lib/tasks/jquery.tools.rake +4 -4
  220. data/templates/tools/swfobject.js +813 -773
  221. metadata +33 -21
  222. data/templates/jquery/haml.js +0 -506
  223. data/templates/jquery/haml.min.js +0 -5
  224. data/templates/jquery/jquery/ui/contextMenu/door.png +0 -0
  225. data/templates/jquery/jquery/ui/contextMenu/page_white_copy.png +0 -0
  226. data/templates/jquery/jquery/ui/contextMenu/page_white_delete.png +0 -0
  227. data/templates/jquery/jquery/ui/contextMenu/page_white_edit.png +0 -0
  228. data/templates/jquery/jquery/ui/contextMenu/page_white_new.png +0 -0
  229. data/templates/jquery/jquery/ui/contextMenu/page_white_paste.png +0 -0
  230. data/templates/jquery/jquery.compat-1.3.js +0 -291
  231. data/templates/jquery/jquery.compat-1.3.min.js +0 -6
  232. data/templates/jquery/jquery.flash_messages.js +0 -5
  233. data/templates/jquery/jquery.flash_messages.min.js +0 -1
  234. data/templates/jquery/jquery.history.js +0 -194
  235. data/templates/jquery/jquery.history.min.js +0 -5
@@ -42,88 +42,88 @@
42
42
  // 1.1 - (11/21/2009) Simplified the code and API substantially.
43
43
  // 1.0 - (11/21/2009) Initial release
44
44
 
45
- (function($){
46
- '$:nomunge'; // Used by YUI compressor.
47
-
48
- // Method: jQuery.fn.replaceText
49
- //
50
- // Replace text in specified elements. Note that only text content will be
51
- // modified, leaving all tags and attributes untouched. The new text can be
52
- // either text or HTML.
53
- //
54
- // Uses the String prototype replace method, full documentation on that method
55
- // can be found here:
56
- //
57
- // https://developer.mozilla.org/En/Core_JavaScript_1.5_Reference/Objects/String/Replace
58
- //
59
- // Usage:
60
- //
61
- // > jQuery('selector').replaceText( search, replace [, text_only ] );
62
- //
63
- // Arguments:
64
- //
65
- // search - (RegExp|String) A RegExp object or substring to be replaced.
66
- // Because the String prototype replace method is used internally, this
67
- // argument should be specified accordingly.
68
- // replace - (String|Function) The String that replaces the substring received
69
- // from the search argument, or a function to be invoked to create the new
70
- // substring. Because the String prototype replace method is used internally,
71
- // this argument should be specified accordingly.
72
- // text_only - (Boolean) If true, any HTML will be rendered as text. Defaults
73
- // to false.
74
- //
75
- // Returns:
76
- //
77
- // (jQuery) The initial jQuery collection of elements.
78
-
79
- $.fn.replaceText = function( search, replace, text_only ) {
80
- return this.each(function(){
81
- var node = this.firstChild,
82
- val,
83
- new_val,
84
-
85
- // Elements to be removed at the end.
86
- remove = [];
87
-
88
- // Only continue if firstChild exists.
89
- if ( node ) {
90
-
91
- // Loop over all childNodes.
92
- do {
93
-
94
- // Only process text nodes.
95
- if ( node.nodeType === 3 ) {
96
-
97
- // The original node value.
98
- val = node.nodeValue;
99
-
100
- // The new value.
101
- new_val = val.replace( search, replace );
102
-
103
- // Only replace text if the new value is actually different!
104
- if ( new_val !== val ) {
105
-
106
- if ( !text_only && /</.test( new_val ) ) {
107
- // The new value contains HTML, set it in a slower but far more
108
- // robust way.
109
- $(node).before( new_val );
110
-
111
- // Don't remove the node yet, or the loop will lose its place.
112
- remove.push( node );
113
- } else {
114
- // The new value contains no HTML, so it can be set in this
115
- // very fast, simple way.
116
- node.nodeValue = new_val;
117
- }
45
+ (function($) {
46
+ '$:nomunge'; // Used by YUI compressor.
47
+
48
+ // Method: jQuery.fn.replaceText
49
+ //
50
+ // Replace text in specified elements. Note that only text content will be
51
+ // modified, leaving all tags and attributes untouched. The new text can be
52
+ // either text or HTML.
53
+ //
54
+ // Uses the String prototype replace method, full documentation on that method
55
+ // can be found here:
56
+ //
57
+ // https://developer.mozilla.org/En/Core_JavaScript_1.5_Reference/Objects/String/Replace
58
+ //
59
+ // Usage:
60
+ //
61
+ // > jQuery('selector').replaceText( search, replace [, text_only ] );
62
+ //
63
+ // Arguments:
64
+ //
65
+ // search - (RegExp|String) A RegExp object or substring to be replaced.
66
+ // Because the String prototype replace method is used internally, this
67
+ // argument should be specified accordingly.
68
+ // replace - (String|Function) The String that replaces the substring received
69
+ // from the search argument, or a function to be invoked to create the new
70
+ // substring. Because the String prototype replace method is used internally,
71
+ // this argument should be specified accordingly.
72
+ // text_only - (Boolean) If true, any HTML will be rendered as text. Defaults
73
+ // to false.
74
+ //
75
+ // Returns:
76
+ //
77
+ // (jQuery) The initial jQuery collection of elements.
78
+
79
+ $.fn.replaceText = function(search, replace, text_only) {
80
+ return this.each(function() {
81
+ var node = this.firstChild,
82
+ val,
83
+ new_val,
84
+
85
+ // Elements to be removed at the end.
86
+ remove = [];
87
+
88
+ // Only continue if firstChild exists.
89
+ if (node) {
90
+
91
+ // Loop over all childNodes.
92
+ do {
93
+
94
+ // Only process text nodes.
95
+ if (node.nodeType === 3) {
96
+
97
+ // The original node value.
98
+ val = node.nodeValue;
99
+
100
+ // The new value.
101
+ new_val = val.replace(search, replace);
102
+
103
+ // Only replace text if the new value is actually different!
104
+ if (new_val !== val) {
105
+
106
+ if (!text_only && /</.test(new_val)) {
107
+ // The new value contains HTML, set it in a slower but far more
108
+ // robust way.
109
+ $(node).before(new_val);
110
+
111
+ // Don't remove the node yet, or the loop will lose its place.
112
+ remove.push(node);
113
+ } else {
114
+ // The new value contains no HTML, so it can be set in this
115
+ // very fast, simple way.
116
+ node.nodeValue = new_val;
117
+ }
118
+ }
119
+ }
120
+
121
+ } while (node = node.nextSibling);
118
122
  }
119
- }
120
-
121
- } while ( node = node.nextSibling );
122
- }
123
-
124
- // Time to remove those elements!
125
- remove.length && $(remove).remove();
126
- });
127
- };
128
-
123
+
124
+ // Time to remove those elements!
125
+ remove.length && $(remove).remove();
126
+ });
127
+ };
128
+
129
129
  })(jQuery);
@@ -1,190 +1,215 @@
1
1
  /* jQuery plugin themeswitcher
2
- ---------------------------------------------------------------------*/
3
- $.fn.themeswitcher = function(settings){
4
- var options = jQuery.extend({
5
- loadTheme: null,
6
- initialText: 'Switch Theme',
7
- width: 150,
8
- height: 400,
9
- buttonPreText: 'Theme: ',
10
- closeOnSelect: true,
11
- buttonHeight: 14,
12
- cookieName: 'jquery-ui-theme',
13
- onOpen: function(){},
14
- onClose: function(){},
15
- onSelect: function(){}
16
- }, settings);
2
+ ---------------------------------------------------------------------*/
3
+ $.fn.themeswitcher = function(settings) {
4
+ var options = jQuery.extend({
5
+ loadTheme: null,
6
+ initialText: 'Switch Theme',
7
+ width: 150,
8
+ height: 400,
9
+ buttonPreText: 'Theme: ',
10
+ closeOnSelect: true,
11
+ buttonHeight: 14,
12
+ cookieName: 'jquery-ui-theme',
13
+ onOpen: function() {
14
+ },
15
+ onClose: function() {
16
+ },
17
+ onSelect: function() {
18
+ }
19
+ }, settings);
17
20
 
18
- //markup
19
- var button = $('<a href="#" class="jquery-ui-themeswitcher-trigger"><span class="jquery-ui-themeswitcher-icon"></span><span class="jquery-ui-themeswitcher-title">'+ options.initialText +'</span></a>');
20
- var switcherpane = $('<div class="jquery-ui-themeswitcher"><div id="themeGallery"> <ul> <li><a href="compiled/jquery/ui/ui-lightness.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_ui_light.png" alt="UI Lightness" title="UI Lightness" /> <span class="themeName">UI lightness</span></a></li> <li><a href="compiled/jquery/ui/ui-darkness.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_ui_dark.png" alt="UI Darkness" title="UI Darkness" /> <span class="themeName">UI darkness</span> </a></li> <li><a href="compiled/jquery/ui/smoothness.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_smoothness.png" alt="Smoothness" title="Smoothness" /> <span class="themeName">Smoothness</span> </a></li> <li><a href="compiled/jquery/ui/start.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_start_menu.png" alt="Start" title="Start" /> <span class="themeName">Start</span></a></li></li> <li><a href="compiled/jquery/ui/redmond.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_windoze.png" alt="Redmond" title="Redmond" /> <span class="themeName">Redmond</span></a></li></li> <li><a href="compiled/jquery/ui/sunny.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_sunny.png" alt="Sunny" title="Sunny" /> <span class="themeName">Sunny</span></a></li></li> <li><a href="compiled/jquery/ui/overcast.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_overcast.png" alt="Overcast" title="Overcast" /> <span class="themeName">Overcast</span></a></li> <li><a href="compiled/jquery/ui/le-frog.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_le_frog.png" alt="Le Frog" title="Le Frog" /> <span class="themeName">Le Frog</span></a></li></li> <li><a href="compiled/jquery/ui/flick.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_flick.png" alt="Flick" title="Flick" /> <span class="themeName">Flick</span></a></li> <li><a href="compiled/jquery/ui/pepper-grinder.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_pepper_grinder.png" alt="Pepper Grinder" title="Pepper Grinder" /> <span class="themeName">Pepper Grinder</span></a></li> <li><a href="compiled/jquery/ui/eggplant.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_eggplant.png" alt="Eggplant" title="Eggplant" /> <span class="themeName">Eggplant</span></a></li> <li><a href="compiled/jquery/ui/dark-hive.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_dark_hive.png" alt="Dark Hive" title="Dark Hive" /> <span class="themeName">Dark Hive</span></a></li></li> <li><a href="compiled/jquery/ui/cupertino.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_cupertino.png" alt="Cupertino" title="Cupertino" /> <span class="themeName">Cupertino</span></a></li> <li><a href="compiled/jquery/ui/south-street.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_south_street.png" alt="South St" title="South St" /> <span class="themeName">South Street</span></a></li> <li><a href="compiled/jquery/ui/blitzer.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_blitzer.png" alt="Blitzer" title="Blitzer" /> <span class="themeName">Blitzer</span></a></li></li> <li><a href="compiled/jquery/ui/humanity.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_humanity.png" alt="Humanity" title="Humanity" /> <span class="themeName">Humanity</span></a></li></li> <li><a href="compiled/jquery/ui/hot-sneaks.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_hot_sneaks.png" alt="Hot Sneaks" title="Hot Sneaks" /> <span class="themeName">Hot sneaks</span></a></li></li> <li><a href="compiled/jquery/ui/excite-bike.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_excite_bike.png" alt="Excite Bike" title="Excite Bike" /> <span class="themeName">Excite Bike</span></a></li> <li><a href="compiled/jquery/ui/vader.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_black_matte.png" alt="Vader" title="Vader" /> <span class="themeName">Vader</span></a></li> <li><a href="compiled/jquery/ui/dot-luv.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_dot_luv.png" alt="Dot Luv" title="Dot Luv" /> <span class="themeName">Dot Luv</span></a></li> <li><a href="compiled/jquery/ui/mint-choc.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_mint_choco.png" alt="Mint Choc" title="Mint Choc" /> <span class="themeName">Mint Choc</span></a></li></li> <li><a href="compiled/jquery/ui/black-tie.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_black_tie.png" alt="Black Tie" title="Black Tie" /> <span class="themeName">Black Tie</span></a></li></li> <li><a href="compiled/jquery/ui/trontastic.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_trontastic.png" alt="Trontastic" title="Trontastic" /><span class="themeName">Trontastic</span></a></li> <li><a href="compiled/jquery/ui/swanky-purse.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_swanky_purse.png" alt="Swanky Purse" title="Swanky Purse" /> <span class="themeName">Swanky Purse</span></a></li></ul></div></div>').find('div').removeAttr('id');
21
- //button events
22
- button.click(
23
- function(){
24
- if(switcherpane.is(':visible')){ switcherpane.spHide(); }
25
- else{ switcherpane.spShow(); }
26
- return false;
27
- }
28
- );
21
+ //markup
22
+ var button = $('<a href="#" class="jquery-ui-themeswitcher-trigger"><span class="jquery-ui-themeswitcher-icon"></span><span class="jquery-ui-themeswitcher-title">' + options.initialText + '</span></a>');
23
+ var switcherpane = $('<div class="jquery-ui-themeswitcher"><div id="themeGallery"> <ul> <li><a href="compiled/jquery/ui/ui-lightness.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_ui_light.png" alt="UI Lightness" title="UI Lightness" /> <span class="themeName">UI lightness</span></a></li> <li><a href="compiled/jquery/ui/ui-darkness.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_ui_dark.png" alt="UI Darkness" title="UI Darkness" /> <span class="themeName">UI darkness</span> </a></li> <li><a href="compiled/jquery/ui/smoothness.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_smoothness.png" alt="Smoothness" title="Smoothness" /> <span class="themeName">Smoothness</span> </a></li> <li><a href="compiled/jquery/ui/start.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_start_menu.png" alt="Start" title="Start" /> <span class="themeName">Start</span></a></li></li> <li><a href="compiled/jquery/ui/redmond.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_windoze.png" alt="Redmond" title="Redmond" /> <span class="themeName">Redmond</span></a></li></li> <li><a href="compiled/jquery/ui/sunny.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_sunny.png" alt="Sunny" title="Sunny" /> <span class="themeName">Sunny</span></a></li></li> <li><a href="compiled/jquery/ui/overcast.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_overcast.png" alt="Overcast" title="Overcast" /> <span class="themeName">Overcast</span></a></li> <li><a href="compiled/jquery/ui/le-frog.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_le_frog.png" alt="Le Frog" title="Le Frog" /> <span class="themeName">Le Frog</span></a></li></li> <li><a href="compiled/jquery/ui/flick.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_flick.png" alt="Flick" title="Flick" /> <span class="themeName">Flick</span></a></li> <li><a href="compiled/jquery/ui/pepper-grinder.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_pepper_grinder.png" alt="Pepper Grinder" title="Pepper Grinder" /> <span class="themeName">Pepper Grinder</span></a></li> <li><a href="compiled/jquery/ui/eggplant.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_eggplant.png" alt="Eggplant" title="Eggplant" /> <span class="themeName">Eggplant</span></a></li> <li><a href="compiled/jquery/ui/dark-hive.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_dark_hive.png" alt="Dark Hive" title="Dark Hive" /> <span class="themeName">Dark Hive</span></a></li></li> <li><a href="compiled/jquery/ui/cupertino.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_cupertino.png" alt="Cupertino" title="Cupertino" /> <span class="themeName">Cupertino</span></a></li> <li><a href="compiled/jquery/ui/south-street.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_south_street.png" alt="South St" title="South St" /> <span class="themeName">South Street</span></a></li> <li><a href="compiled/jquery/ui/blitzer.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_blitzer.png" alt="Blitzer" title="Blitzer" /> <span class="themeName">Blitzer</span></a></li></li> <li><a href="compiled/jquery/ui/humanity.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_humanity.png" alt="Humanity" title="Humanity" /> <span class="themeName">Humanity</span></a></li></li> <li><a href="compiled/jquery/ui/hot-sneaks.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_hot_sneaks.png" alt="Hot Sneaks" title="Hot Sneaks" /> <span class="themeName">Hot sneaks</span></a></li></li> <li><a href="compiled/jquery/ui/excite-bike.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_excite_bike.png" alt="Excite Bike" title="Excite Bike" /> <span class="themeName">Excite Bike</span></a></li> <li><a href="compiled/jquery/ui/vader.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_black_matte.png" alt="Vader" title="Vader" /> <span class="themeName">Vader</span></a></li> <li><a href="compiled/jquery/ui/dot-luv.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_dot_luv.png" alt="Dot Luv" title="Dot Luv" /> <span class="themeName">Dot Luv</span></a></li> <li><a href="compiled/jquery/ui/mint-choc.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_mint_choco.png" alt="Mint Choc" title="Mint Choc" /> <span class="themeName">Mint Choc</span></a></li></li> <li><a href="compiled/jquery/ui/black-tie.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_black_tie.png" alt="Black Tie" title="Black Tie" /> <span class="themeName">Black Tie</span></a></li></li> <li><a href="compiled/jquery/ui/trontastic.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_trontastic.png" alt="Trontastic" title="Trontastic" /><span class="themeName">Trontastic</span></a></li> <li><a href="compiled/jquery/ui/swanky-purse.css"> <img src="/images/jquery/ui/themeSwitcher/theme_90_swanky_purse.png" alt="Swanky Purse" title="Swanky Purse" /> <span class="themeName">Swanky Purse</span></a></li></ul></div></div>').find('div').removeAttr('id');
24
+ //button events
25
+ button.click(
26
+ function() {
27
+ if (switcherpane.is(':visible')) {
28
+ switcherpane.spHide();
29
+ }
30
+ else {
31
+ switcherpane.spShow();
32
+ }
33
+ return false;
34
+ }
35
+ );
29
36
 
30
- //menu events (mouseout didn't work...)
31
- switcherpane.hover(
32
- function(){},
33
- function(){if(switcherpane.is(':visible')){$(this).spHide();}}
34
- );
37
+ //menu events (mouseout didn't work...)
38
+ switcherpane.hover(
39
+ function() {
40
+ },
41
+ function() {
42
+ if (switcherpane.is(':visible')) {
43
+ $(this).spHide();
44
+ }
45
+ }
46
+ );
35
47
 
36
- //show/hide panel functions
37
- $.fn.spShow = function(){ $(this).css({top: button.offset().top + options.buttonHeight + 6, left: button.offset().left}).slideDown(50); button.css(button_active); options.onOpen(); }
38
- $.fn.spHide = function(){ $(this).slideUp(50, function(){options.onClose();}); button.css(button_default); }
48
+ //show/hide panel functions
49
+ $.fn.spShow = function() {
50
+ $(this).css({top: button.offset().top + options.buttonHeight + 6, left: button.offset().left}).slideDown(50);
51
+ button.css(button_active);
52
+ options.onOpen();
53
+ }
54
+ $.fn.spHide = function() {
55
+ $(this).slideUp(50, function() {
56
+ options.onClose();
57
+ });
58
+ button.css(button_default);
59
+ }
39
60
 
40
61
 
41
- /* Theme Loading
42
- ---------------------------------------------------------------------*/
43
- switcherpane.find('a').click(function(){
44
- updateCSS( $(this).attr('href') );
45
- var themeName = $(this).find('span').text();
46
- button.find('.jquery-ui-themeswitcher-title').text( options.buttonPreText + themeName );
47
- $.cookie(options.cookieName, themeName);
48
- options.onSelect();
49
- if(options.closeOnSelect && switcherpane.is(':visible')){ switcherpane.spHide(); }
50
- return false;
51
- });
62
+ /* Theme Loading
63
+ ---------------------------------------------------------------------*/
64
+ switcherpane.find('a').click(function() {
65
+ updateCSS($(this).attr('href'));
66
+ var themeName = $(this).find('span').text();
67
+ button.find('.jquery-ui-themeswitcher-title').text(options.buttonPreText + themeName);
68
+ $.cookie(options.cookieName, themeName);
69
+ options.onSelect();
70
+ if (options.closeOnSelect && switcherpane.is(':visible')) {
71
+ switcherpane.spHide();
72
+ }
73
+ return false;
74
+ });
52
75
 
53
- //function to append a new theme stylesheet with the new style changes
54
- function updateCSS(locStr){
55
- var cssLink = $('<link href="/stylesheets/'+locStr+'" type="text/css" rel="Stylesheet" class="ui-theme" />');
56
- $("head").append(cssLink);
76
+ //function to append a new theme stylesheet with the new style changes
77
+ function updateCSS(locStr) {
78
+ var cssLink = $('<link href="/stylesheets/' + locStr + '" type="text/css" rel="Stylesheet" class="ui-theme" />');
79
+ $("head").append(cssLink);
57
80
 
58
81
 
59
- if( $("link.ui-theme").size() > 3){
60
- $("link.ui-theme:first").remove();
61
- }
62
- }
82
+ if ($("link.ui-theme").size() > 3) {
83
+ $("link.ui-theme:first").remove();
84
+ }
85
+ }
63
86
 
64
- /* Inline CSS
65
- ---------------------------------------------------------------------*/
66
- var button_default = {
67
- fontFamily: 'Trebuchet MS, Verdana, sans-serif',
68
- fontSize: '11px',
69
- color: '#666',
70
- background: '#eee image_url("jquery/ui/themeSwitcher/buttonbg.png") 50% 50% repeat-x',
71
- border: '1px solid #ccc',
72
- '-moz-border-radius': '6px',
73
- '-webkit-border-radius': '6px',
74
- textDecoration: 'none',
75
- padding: '3px 3px 3px 8px',
76
- width: options.width - 11,//minus must match left and right padding
77
- display: 'block',
78
- height: options.buttonHeight,
79
- outline: '0'
80
- };
81
- var button_hover = {
82
- 'borderColor':'#bbb',
83
- 'background': '#f0f0f0',
84
- cursor: 'pointer',
85
- color: '#444'
86
- };
87
- var button_active = {
88
- color: '#aaa',
89
- background: '#000',
90
- border: '1px solid #ccc',
91
- borderBottom: 0,
92
- '-moz-border-radius-bottomleft': 0,
93
- '-webkit-border-bottom-left-radius': 0,
94
- '-moz-border-radius-bottomright': 0,
95
- '-webkit-border-bottom-right-radius': 0,
96
- outline: '0'
97
- };
87
+ /* Inline CSS
88
+ ---------------------------------------------------------------------*/
89
+ var button_default = {
90
+ fontFamily: 'Trebuchet MS, Verdana, sans-serif',
91
+ fontSize: '11px',
92
+ color: '#666',
93
+ background: '#eee image_url("jquery/ui/themeSwitcher/buttonbg.png") 50% 50% repeat-x',
94
+ border: '1px solid #ccc',
95
+ '-moz-border-radius': '6px',
96
+ '-webkit-border-radius': '6px',
97
+ textDecoration: 'none',
98
+ padding: '3px 3px 3px 8px',
99
+ width: options.width - 11,//minus must match left and right padding
100
+ display: 'block',
101
+ height: options.buttonHeight,
102
+ outline: '0'
103
+ };
104
+ var button_hover = {
105
+ 'borderColor':'#bbb',
106
+ 'background': '#f0f0f0',
107
+ cursor: 'pointer',
108
+ color: '#444'
109
+ };
110
+ var button_active = {
111
+ color: '#aaa',
112
+ background: '#000',
113
+ border: '1px solid #ccc',
114
+ borderBottom: 0,
115
+ '-moz-border-radius-bottomleft': 0,
116
+ '-webkit-border-bottom-left-radius': 0,
117
+ '-moz-border-radius-bottomright': 0,
118
+ '-webkit-border-bottom-right-radius': 0,
119
+ outline: '0'
120
+ };
98
121
 
99
- //button css
100
- button.css(button_default)
101
- .hover(
102
- function(){
103
- $(this).css(button_hover);
104
- },
105
- function(){
106
- if( !switcherpane.is(':animated') && switcherpane.is(':hidden') ){ $(this).css(button_default); }
107
- }
108
- )
109
- .find('.jquery-ui-themeswitcher-icon').css({
110
- 'float': 'right',
111
- width: '16px',
112
- height: '16px',
113
- background: 'image_url("jquery/ui/themeSwitcher/icon_color_arrow.gif") 50% 50% no-repeat'
114
- });
115
- //pane css
116
- switcherpane.css({
117
- position: 'absolute',
118
- 'float': 'left',
119
- fontFamily: 'Trebuchet MS, Verdana, sans-serif',
120
- fontSize: '12px',
121
- background: '#000',
122
- color: '#fff',
123
- padding: '8px 3px 3px',
124
- border: '1px solid #ccc',
125
- '-moz-border-radius-bottomleft': '6px',
126
- '-webkit-border-bottom-left-radius': '6px',
127
- '-moz-border-radius-bottomright': '6px',
128
- '-webkit-border-bottom-right-radius': '6px',
129
- borderTop: 0,
130
- zIndex: 999999,
131
- width: options.width-6//minus must match left and right padding
132
- })
133
- .find('ul').css({
134
- listStyle: 'none',
135
- margin: '0',
136
- padding: '0',
137
- overflow: 'auto',
138
- height: options.height
139
- }).end()
140
- .find('li').hover(
141
- function(){
142
- $(this).css({
143
- 'borderColor':'#555',
144
- 'background': 'image_url("jquery/ui/themeSwitcher/menuhoverbg.png") 50% 50% repeat-x',
145
- cursor: 'pointer'
146
- });
147
- },
148
- function(){
149
- $(this).css({
150
- 'borderColor':'#111',
151
- 'background': '#000',
152
- cursor: 'auto'
153
- });
154
- }
155
- ).css({
156
- width: options.width-30,
157
- height: '',
158
- padding: '2px',
159
- margin: '1px',
160
- border: '1px solid #111',
161
- '-moz-border-radius': '4px',
162
- clear: 'left',
163
- 'float': 'left'
164
- }).end()
165
- .find('a').css({
166
- color: '#aaa',
167
- textDecoration: 'none',
168
- 'float': 'left',
169
- width: '100%',
170
- outline: '0'
171
- }).end()
172
- .find('img').css({
173
- 'float': 'left',
174
- border: '1px solid #333',
175
- margin: '0 2px'
176
- }).end()
177
- .find('.themeName').css({
178
- 'float': 'left',
179
- margin: '3px 0'
180
- }).end();
122
+ //button css
123
+ button.css(button_default)
124
+ .hover(
125
+ function() {
126
+ $(this).css(button_hover);
127
+ },
128
+ function() {
129
+ if (!switcherpane.is(':animated') && switcherpane.is(':hidden')) {
130
+ $(this).css(button_default);
131
+ }
132
+ }
133
+ )
134
+ .find('.jquery-ui-themeswitcher-icon').css({
135
+ 'float': 'right',
136
+ width: '16px',
137
+ height: '16px',
138
+ background: 'image_url("jquery/ui/themeSwitcher/icon_color_arrow.gif") 50% 50% no-repeat'
139
+ });
140
+ //pane css
141
+ switcherpane.css({
142
+ position: 'absolute',
143
+ 'float': 'left',
144
+ fontFamily: 'Trebuchet MS, Verdana, sans-serif',
145
+ fontSize: '12px',
146
+ background: '#000',
147
+ color: '#fff',
148
+ padding: '8px 3px 3px',
149
+ border: '1px solid #ccc',
150
+ '-moz-border-radius-bottomleft': '6px',
151
+ '-webkit-border-bottom-left-radius': '6px',
152
+ '-moz-border-radius-bottomright': '6px',
153
+ '-webkit-border-bottom-right-radius': '6px',
154
+ borderTop: 0,
155
+ zIndex: 999999,
156
+ width: options.width - 6//minus must match left and right padding
157
+ })
158
+ .find('ul').css({
159
+ listStyle: 'none',
160
+ margin: '0',
161
+ padding: '0',
162
+ overflow: 'auto',
163
+ height: options.height
164
+ }).end()
165
+ .find('li').hover(
166
+ function() {
167
+ $(this).css({
168
+ 'borderColor':'#555',
169
+ 'background': 'image_url("jquery/ui/themeSwitcher/menuhoverbg.png") 50% 50% repeat-x',
170
+ cursor: 'pointer'
171
+ });
172
+ },
173
+ function() {
174
+ $(this).css({
175
+ 'borderColor':'#111',
176
+ 'background': '#000',
177
+ cursor: 'auto'
178
+ });
179
+ }
180
+ ).css({
181
+ width: options.width - 30,
182
+ height: '',
183
+ padding: '2px',
184
+ margin: '1px',
185
+ border: '1px solid #111',
186
+ '-moz-border-radius': '4px',
187
+ clear: 'left',
188
+ 'float': 'left'
189
+ }).end()
190
+ .find('a').css({
191
+ color: '#aaa',
192
+ textDecoration: 'none',
193
+ 'float': 'left',
194
+ width: '100%',
195
+ outline: '0'
196
+ }).end()
197
+ .find('img').css({
198
+ 'float': 'left',
199
+ border: '1px solid #333',
200
+ margin: '0 2px'
201
+ }).end()
202
+ .find('.themeName').css({
203
+ 'float': 'left',
204
+ margin: '3px 0'
205
+ }).end();
181
206
 
182
- $(this).append(button);
183
- $('body').append(switcherpane);
184
- switcherpane.hide();
185
- if( $.cookie(options.cookieName) || options.loadTheme ){
186
- var themeName = $.cookie(options.cookieName) || options.loadTheme;
187
- switcherpane.find('a:contains('+ themeName +')').trigger('click');
188
- }
189
- return this;
207
+ $(this).append(button);
208
+ $('body').append(switcherpane);
209
+ switcherpane.hide();
210
+ if ($.cookie(options.cookieName) || options.loadTheme) {
211
+ var themeName = $.cookie(options.cookieName) || options.loadTheme;
212
+ switcherpane.find('a:contains(' + themeName + ')').trigger('click');
213
+ }
214
+ return this;
190
215
  };