logster 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (245) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +17 -0
  3. data/Gemfile +4 -0
  4. data/Guardfile +8 -0
  5. data/LICENSE.txt +22 -0
  6. data/README.md +38 -0
  7. data/Rakefile +18 -0
  8. data/assets/javascript/app.js +377 -0
  9. data/assets/javascript/external/ember.js +44267 -0
  10. data/assets/javascript/external/ember.min.js +19 -0
  11. data/assets/javascript/external/handlebars.min.js +28 -0
  12. data/assets/javascript/external/jquery.min.js +5 -0
  13. data/assets/javascript/external/lodash.min.js +56 -0
  14. data/assets/javascript/external/moment.min.js +6 -0
  15. data/assets/javascript/templates/application.handlebars +1 -0
  16. data/assets/javascript/templates/index.handlebars +48 -0
  17. data/assets/javascript/templates/message.handlebars +7 -0
  18. data/assets/stylesheets/app.css +188 -0
  19. data/bower_components/ember/.bower.json +22 -0
  20. data/bower_components/ember/.gitignore +5 -0
  21. data/bower_components/ember/Makefile +9 -0
  22. data/bower_components/ember/README.md +12 -0
  23. data/bower_components/ember/bower.json +11 -0
  24. data/bower_components/ember/component.json +13 -0
  25. data/bower_components/ember/composer.json +27 -0
  26. data/bower_components/ember/ember-template-compiler.js +320 -0
  27. data/bower_components/ember/ember.js +44267 -0
  28. data/bower_components/ember/ember.min.js +19 -0
  29. data/bower_components/ember/ember.prod.js +42649 -0
  30. data/bower_components/ember/package.json +11 -0
  31. data/bower_components/handlebars/.bower.json +16 -0
  32. data/bower_components/handlebars/.gitignore +2 -0
  33. data/bower_components/handlebars/README.md +11 -0
  34. data/bower_components/handlebars/bower.json +6 -0
  35. data/bower_components/handlebars/component.json +9 -0
  36. data/bower_components/handlebars/composer.json +35 -0
  37. data/bower_components/handlebars/handlebars-source.gemspec +21 -0
  38. data/bower_components/handlebars/handlebars.amd.js +2719 -0
  39. data/bower_components/handlebars/handlebars.amd.min.js +28 -0
  40. data/bower_components/handlebars/handlebars.js +2746 -0
  41. data/bower_components/handlebars/handlebars.js.nuspec +17 -0
  42. data/bower_components/handlebars/handlebars.min.js +28 -0
  43. data/bower_components/handlebars/handlebars.runtime.amd.js +515 -0
  44. data/bower_components/handlebars/handlebars.runtime.amd.min.js +27 -0
  45. data/bower_components/handlebars/handlebars.runtime.js +530 -0
  46. data/bower_components/handlebars/handlebars.runtime.min.js +27 -0
  47. data/bower_components/handlebars/lib/handlebars/source.rb +11 -0
  48. data/bower_components/jquery/.bower.json +37 -0
  49. data/bower_components/jquery/MIT-LICENSE.txt +21 -0
  50. data/bower_components/jquery/bower.json +27 -0
  51. data/bower_components/jquery/dist/jquery.js +9111 -0
  52. data/bower_components/jquery/dist/jquery.min.js +5 -0
  53. data/bower_components/jquery/dist/jquery.min.map +1 -0
  54. data/bower_components/jquery/src/ajax.js +806 -0
  55. data/bower_components/jquery/src/ajax/jsonp.js +89 -0
  56. data/bower_components/jquery/src/ajax/load.js +75 -0
  57. data/bower_components/jquery/src/ajax/parseJSON.js +13 -0
  58. data/bower_components/jquery/src/ajax/parseXML.js +28 -0
  59. data/bower_components/jquery/src/ajax/script.js +64 -0
  60. data/bower_components/jquery/src/ajax/var/nonce.js +5 -0
  61. data/bower_components/jquery/src/ajax/var/rquery.js +3 -0
  62. data/bower_components/jquery/src/ajax/xhr.js +130 -0
  63. data/bower_components/jquery/src/attributes.js +11 -0
  64. data/bower_components/jquery/src/attributes/attr.js +143 -0
  65. data/bower_components/jquery/src/attributes/classes.js +158 -0
  66. data/bower_components/jquery/src/attributes/prop.js +96 -0
  67. data/bower_components/jquery/src/attributes/support.js +35 -0
  68. data/bower_components/jquery/src/attributes/val.js +153 -0
  69. data/bower_components/jquery/src/callbacks.js +205 -0
  70. data/bower_components/jquery/src/core.js +500 -0
  71. data/bower_components/jquery/src/core/access.js +60 -0
  72. data/bower_components/jquery/src/core/init.js +123 -0
  73. data/bower_components/jquery/src/core/parseHTML.js +39 -0
  74. data/bower_components/jquery/src/core/ready.js +96 -0
  75. data/bower_components/jquery/src/core/var/rsingleTag.js +4 -0
  76. data/bower_components/jquery/src/css.js +455 -0
  77. data/bower_components/jquery/src/css/addGetHookIf.js +24 -0
  78. data/bower_components/jquery/src/css/curCSS.js +57 -0
  79. data/bower_components/jquery/src/css/defaultDisplay.js +69 -0
  80. data/bower_components/jquery/src/css/hiddenVisibleSelectors.js +15 -0
  81. data/bower_components/jquery/src/css/support.js +83 -0
  82. data/bower_components/jquery/src/css/swap.js +28 -0
  83. data/bower_components/jquery/src/css/var/cssExpand.js +3 -0
  84. data/bower_components/jquery/src/css/var/getStyles.js +5 -0
  85. data/bower_components/jquery/src/css/var/isHidden.js +13 -0
  86. data/bower_components/jquery/src/css/var/rmargin.js +3 -0
  87. data/bower_components/jquery/src/css/var/rnumnonpx.js +5 -0
  88. data/bower_components/jquery/src/data.js +175 -0
  89. data/bower_components/jquery/src/data/Data.js +181 -0
  90. data/bower_components/jquery/src/data/accepts.js +20 -0
  91. data/bower_components/jquery/src/data/var/data_priv.js +5 -0
  92. data/bower_components/jquery/src/data/var/data_user.js +5 -0
  93. data/bower_components/jquery/src/deferred.js +149 -0
  94. data/bower_components/jquery/src/deprecated.js +13 -0
  95. data/bower_components/jquery/src/dimensions.js +50 -0
  96. data/bower_components/jquery/src/effects.js +642 -0
  97. data/bower_components/jquery/src/effects/Tween.js +114 -0
  98. data/bower_components/jquery/src/effects/animatedSelector.js +13 -0
  99. data/bower_components/jquery/src/event.js +859 -0
  100. data/bower_components/jquery/src/event/alias.js +39 -0
  101. data/bower_components/jquery/src/event/support.js +9 -0
  102. data/bower_components/jquery/src/exports/amd.js +18 -0
  103. data/bower_components/jquery/src/exports/global.js +32 -0
  104. data/bower_components/jquery/src/intro.js +44 -0
  105. data/bower_components/jquery/src/jquery.js +36 -0
  106. data/bower_components/jquery/src/manipulation.js +583 -0
  107. data/bower_components/jquery/src/manipulation/_evalUrl.js +18 -0
  108. data/bower_components/jquery/src/manipulation/support.js +24 -0
  109. data/bower_components/jquery/src/manipulation/var/rcheckableType.js +3 -0
  110. data/bower_components/jquery/src/offset.js +204 -0
  111. data/bower_components/jquery/src/outro.js +1 -0
  112. data/bower_components/jquery/src/queue.js +142 -0
  113. data/bower_components/jquery/src/queue/delay.js +22 -0
  114. data/bower_components/jquery/src/selector-native.js +171 -0
  115. data/bower_components/jquery/src/selector-sizzle.js +14 -0
  116. data/bower_components/jquery/src/selector.js +1 -0
  117. data/bower_components/jquery/src/serialize.js +111 -0
  118. data/bower_components/jquery/src/sizzle/dist/sizzle.js +2015 -0
  119. data/bower_components/jquery/src/sizzle/dist/sizzle.min.js +3 -0
  120. data/bower_components/jquery/src/sizzle/dist/sizzle.min.map +1 -0
  121. data/bower_components/jquery/src/traversing.js +200 -0
  122. data/bower_components/jquery/src/traversing/findFilter.js +100 -0
  123. data/bower_components/jquery/src/traversing/var/rneedsContext.js +6 -0
  124. data/bower_components/jquery/src/var/arr.js +3 -0
  125. data/bower_components/jquery/src/var/class2type.js +4 -0
  126. data/bower_components/jquery/src/var/concat.js +5 -0
  127. data/bower_components/jquery/src/var/hasOwn.js +5 -0
  128. data/bower_components/jquery/src/var/indexOf.js +5 -0
  129. data/bower_components/jquery/src/var/pnum.js +3 -0
  130. data/bower_components/jquery/src/var/push.js +5 -0
  131. data/bower_components/jquery/src/var/rnotwhite.js +3 -0
  132. data/bower_components/jquery/src/var/slice.js +5 -0
  133. data/bower_components/jquery/src/var/strundefined.js +3 -0
  134. data/bower_components/jquery/src/var/support.js +4 -0
  135. data/bower_components/jquery/src/var/toString.js +5 -0
  136. data/bower_components/jquery/src/var/trim.js +3 -0
  137. data/bower_components/jquery/src/wrap.js +78 -0
  138. data/bower_components/lodash/.bower.json +34 -0
  139. data/bower_components/lodash/LICENSE.txt +22 -0
  140. data/bower_components/lodash/bower.json +23 -0
  141. data/bower_components/lodash/dist/lodash.compat.js +7157 -0
  142. data/bower_components/lodash/dist/lodash.compat.min.js +61 -0
  143. data/bower_components/lodash/dist/lodash.js +6785 -0
  144. data/bower_components/lodash/dist/lodash.min.js +56 -0
  145. data/bower_components/lodash/dist/lodash.underscore.js +4979 -0
  146. data/bower_components/lodash/dist/lodash.underscore.min.js +39 -0
  147. data/bower_components/moment/.bower.json +31 -0
  148. data/bower_components/moment/LICENSE +22 -0
  149. data/bower_components/moment/bower.json +20 -0
  150. data/bower_components/moment/lang/ar-ma.js +56 -0
  151. data/bower_components/moment/lang/ar.js +56 -0
  152. data/bower_components/moment/lang/bg.js +86 -0
  153. data/bower_components/moment/lang/br.js +107 -0
  154. data/bower_components/moment/lang/bs.js +139 -0
  155. data/bower_components/moment/lang/ca.js +66 -0
  156. data/bower_components/moment/lang/cs.js +155 -0
  157. data/bower_components/moment/lang/cv.js +59 -0
  158. data/bower_components/moment/lang/cy.js +77 -0
  159. data/bower_components/moment/lang/da.js +56 -0
  160. data/bower_components/moment/lang/de.js +71 -0
  161. data/bower_components/moment/lang/el.js +79 -0
  162. data/bower_components/moment/lang/en-au.js +62 -0
  163. data/bower_components/moment/lang/en-ca.js +59 -0
  164. data/bower_components/moment/lang/en-gb.js +63 -0
  165. data/bower_components/moment/lang/eo.js +65 -0
  166. data/bower_components/moment/lang/es.js +75 -0
  167. data/bower_components/moment/lang/et.js +76 -0
  168. data/bower_components/moment/lang/eu.js +60 -0
  169. data/bower_components/moment/lang/fa.js +97 -0
  170. data/bower_components/moment/lang/fi.js +103 -0
  171. data/bower_components/moment/lang/fo.js +56 -0
  172. data/bower_components/moment/lang/fr-ca.js +54 -0
  173. data/bower_components/moment/lang/fr.js +58 -0
  174. data/bower_components/moment/lang/gl.js +71 -0
  175. data/bower_components/moment/lang/he.js +77 -0
  176. data/bower_components/moment/lang/hi.js +105 -0
  177. data/bower_components/moment/lang/hr.js +140 -0
  178. data/bower_components/moment/lang/hu.js +105 -0
  179. data/bower_components/moment/lang/hy-am.js +113 -0
  180. data/bower_components/moment/lang/id.js +67 -0
  181. data/bower_components/moment/lang/is.js +124 -0
  182. data/bower_components/moment/lang/it.js +59 -0
  183. data/bower_components/moment/lang/ja.js +58 -0
  184. data/bower_components/moment/lang/ka.js +108 -0
  185. data/bower_components/moment/lang/km.js +55 -0
  186. data/bower_components/moment/lang/ko.js +63 -0
  187. data/bower_components/moment/lang/lb.js +160 -0
  188. data/bower_components/moment/lang/lt.js +118 -0
  189. data/bower_components/moment/lang/lv.js +77 -0
  190. data/bower_components/moment/lang/mk.js +86 -0
  191. data/bower_components/moment/lang/ml.js +64 -0
  192. data/bower_components/moment/lang/mr.js +104 -0
  193. data/bower_components/moment/lang/ms-my.js +66 -0
  194. data/bower_components/moment/lang/nb.js +57 -0
  195. data/bower_components/moment/lang/ne.js +105 -0
  196. data/bower_components/moment/lang/nl.js +67 -0
  197. data/bower_components/moment/lang/nn.js +56 -0
  198. data/bower_components/moment/lang/pl.js +98 -0
  199. data/bower_components/moment/lang/pt-br.js +56 -0
  200. data/bower_components/moment/lang/pt.js +60 -0
  201. data/bower_components/moment/lang/ro.js +72 -0
  202. data/bower_components/moment/lang/ru.js +163 -0
  203. data/bower_components/moment/lang/sk.js +156 -0
  204. data/bower_components/moment/lang/sl.js +144 -0
  205. data/bower_components/moment/lang/sq.js +61 -0
  206. data/bower_components/moment/lang/sr-cyr.js +106 -0
  207. data/bower_components/moment/lang/sr.js +106 -0
  208. data/bower_components/moment/lang/sv.js +63 -0
  209. data/bower_components/moment/lang/ta.js +112 -0
  210. data/bower_components/moment/lang/th.js +58 -0
  211. data/bower_components/moment/lang/tl-ph.js +58 -0
  212. data/bower_components/moment/lang/tr.js +93 -0
  213. data/bower_components/moment/lang/tzm-la.js +55 -0
  214. data/bower_components/moment/lang/tzm.js +55 -0
  215. data/bower_components/moment/lang/uk.js +157 -0
  216. data/bower_components/moment/lang/uz.js +55 -0
  217. data/bower_components/moment/lang/vi.js +62 -0
  218. data/bower_components/moment/lang/zh-cn.js +108 -0
  219. data/bower_components/moment/lang/zh-tw.js +84 -0
  220. data/bower_components/moment/min/langs.js +5991 -0
  221. data/bower_components/moment/min/langs.min.js +3 -0
  222. data/bower_components/moment/min/moment-with-langs.js +7993 -0
  223. data/bower_components/moment/min/moment-with-langs.min.js +9 -0
  224. data/bower_components/moment/min/moment.min.js +6 -0
  225. data/bower_components/moment/moment.js +2489 -0
  226. data/bower_components/moment/readme.md +368 -0
  227. data/lib/logster.rb +9 -0
  228. data/lib/logster/logger.rb +31 -0
  229. data/lib/logster/message.rb +42 -0
  230. data/lib/logster/middleware/reporter.rb +13 -0
  231. data/lib/logster/middleware/viewer.rb +122 -0
  232. data/lib/logster/rails/railtie.rb +39 -0
  233. data/lib/logster/redis_store.rb +124 -0
  234. data/lib/logster/version.rb +3 -0
  235. data/logster.gemspec +30 -0
  236. data/test/logster/middleware/test_viewer.rb +34 -0
  237. data/test/logster/test_redis_store.rb +112 -0
  238. data/test/test_helper.rb +6 -0
  239. data/website/Gemfile +6 -0
  240. data/website/config.ru +2 -0
  241. data/website/data/data.json +1 -0
  242. data/website/docker_container/logster.yml +95 -0
  243. data/website/sample.rb +85 -0
  244. data/website/scripts/persist_logs.rb +13 -0
  245. metadata +375 -0
@@ -0,0 +1,39 @@
1
+ define([
2
+ "../core",
3
+ "../event"
4
+ ], function( jQuery ) {
5
+
6
+ jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " +
7
+ "mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " +
8
+ "change select submit keydown keypress keyup error contextmenu").split(" "), function( i, name ) {
9
+
10
+ // Handle event binding
11
+ jQuery.fn[ name ] = function( data, fn ) {
12
+ return arguments.length > 0 ?
13
+ this.on( name, null, data, fn ) :
14
+ this.trigger( name );
15
+ };
16
+ });
17
+
18
+ jQuery.fn.extend({
19
+ hover: function( fnOver, fnOut ) {
20
+ return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );
21
+ },
22
+
23
+ bind: function( types, data, fn ) {
24
+ return this.on( types, null, data, fn );
25
+ },
26
+ unbind: function( types, fn ) {
27
+ return this.off( types, null, fn );
28
+ },
29
+
30
+ delegate: function( selector, types, data, fn ) {
31
+ return this.on( types, selector, data, fn );
32
+ },
33
+ undelegate: function( selector, types, fn ) {
34
+ // ( namespace ) or ( selector, types [, fn] )
35
+ return arguments.length === 1 ? this.off( selector, "**" ) : this.off( types, selector || "**", fn );
36
+ }
37
+ });
38
+
39
+ });
@@ -0,0 +1,9 @@
1
+ define([
2
+ "../var/support"
3
+ ], function( support ) {
4
+
5
+ support.focusinBubbles = "onfocusin" in window;
6
+
7
+ return support;
8
+
9
+ });
@@ -0,0 +1,18 @@
1
+ define([
2
+ "../core"
3
+ ], function( jQuery ) {
4
+
5
+ // Register as a named AMD module, since jQuery can be concatenated with other
6
+ // files that may use define, but not via a proper concatenation script that
7
+ // understands anonymous AMD modules. A named AMD is safest and most robust
8
+ // way to register. Lowercase jquery is used because AMD module names are
9
+ // derived from file names, and jQuery is normally delivered in a lowercase
10
+ // file name. Do this after creating the global so that if an AMD module wants
11
+ // to call noConflict to hide this version of jQuery, it will work.
12
+ if ( typeof define === "function" && define.amd ) {
13
+ define( "jquery", [], function() {
14
+ return jQuery;
15
+ });
16
+ }
17
+
18
+ });
@@ -0,0 +1,32 @@
1
+ define([
2
+ "../core",
3
+ "../var/strundefined"
4
+ ], function( jQuery, strundefined ) {
5
+
6
+ var
7
+ // Map over jQuery in case of overwrite
8
+ _jQuery = window.jQuery,
9
+
10
+ // Map over the $ in case of overwrite
11
+ _$ = window.$;
12
+
13
+ jQuery.noConflict = function( deep ) {
14
+ if ( window.$ === jQuery ) {
15
+ window.$ = _$;
16
+ }
17
+
18
+ if ( deep && window.jQuery === jQuery ) {
19
+ window.jQuery = _jQuery;
20
+ }
21
+
22
+ return jQuery;
23
+ };
24
+
25
+ // Expose jQuery and $ identifiers, even in
26
+ // AMD (#7102#comment:10, https://github.com/jquery/jquery/pull/557)
27
+ // and CommonJS for browser emulators (#13566)
28
+ if ( typeof noGlobal === strundefined ) {
29
+ window.jQuery = window.$ = jQuery;
30
+ }
31
+
32
+ });
@@ -0,0 +1,44 @@
1
+ /*!
2
+ * jQuery JavaScript Library v@VERSION
3
+ * http://jquery.com/
4
+ *
5
+ * Includes Sizzle.js
6
+ * http://sizzlejs.com/
7
+ *
8
+ * Copyright 2005, 2014 jQuery Foundation, Inc. and other contributors
9
+ * Released under the MIT license
10
+ * http://jquery.org/license
11
+ *
12
+ * Date: @DATE
13
+ */
14
+
15
+ (function( global, factory ) {
16
+
17
+ if ( typeof module === "object" && typeof module.exports === "object" ) {
18
+ // For CommonJS and CommonJS-like environments where a proper window is present,
19
+ // execute the factory and get jQuery
20
+ // For environments that do not inherently posses a window with a document
21
+ // (such as Node.js), expose a jQuery-making factory as module.exports
22
+ // This accentuates the need for the creation of a real window
23
+ // e.g. var jQuery = require("jquery")(window);
24
+ // See ticket #14549 for more info
25
+ module.exports = global.document ?
26
+ factory( global, true ) :
27
+ function( w ) {
28
+ if ( !w.document ) {
29
+ throw new Error( "jQuery requires a window with a document" );
30
+ }
31
+ return factory( w );
32
+ };
33
+ } else {
34
+ factory( global );
35
+ }
36
+
37
+ // Pass this if window is not defined yet
38
+ }(typeof window !== "undefined" ? window : this, function( window, noGlobal ) {
39
+
40
+ // Can't do this because several apps including ASP.NET trace
41
+ // the stack via arguments.caller.callee and Firefox dies if
42
+ // you try to trace through "use strict" call chains. (#13335)
43
+ // Support: Firefox 18+
44
+ //"use strict";
@@ -0,0 +1,36 @@
1
+ define([
2
+ "./core",
3
+ "./selector",
4
+ "./traversing",
5
+ "./callbacks",
6
+ "./deferred",
7
+ "./core/ready",
8
+ "./data",
9
+ "./queue",
10
+ "./queue/delay",
11
+ "./attributes",
12
+ "./event",
13
+ "./event/alias",
14
+ "./manipulation",
15
+ "./manipulation/_evalUrl",
16
+ "./wrap",
17
+ "./css",
18
+ "./css/hiddenVisibleSelectors",
19
+ "./serialize",
20
+ "./ajax",
21
+ "./ajax/xhr",
22
+ "./ajax/script",
23
+ "./ajax/jsonp",
24
+ "./ajax/load",
25
+ "./effects",
26
+ "./effects/animatedSelector",
27
+ "./offset",
28
+ "./dimensions",
29
+ "./deprecated",
30
+ "./exports/amd",
31
+ "./exports/global"
32
+ ], function( jQuery ) {
33
+
34
+ return jQuery;
35
+
36
+ });
@@ -0,0 +1,583 @@
1
+ define([
2
+ "./core",
3
+ "./var/concat",
4
+ "./var/push",
5
+ "./core/access",
6
+ "./manipulation/var/rcheckableType",
7
+ "./manipulation/support",
8
+ "./data/var/data_priv",
9
+ "./data/var/data_user",
10
+
11
+ "./core/init",
12
+ "./data/accepts",
13
+ "./traversing",
14
+ "./selector",
15
+ "./event"
16
+ ], function( jQuery, concat, push, access, rcheckableType, support, data_priv, data_user ) {
17
+
18
+ var
19
+ rxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,
20
+ rtagName = /<([\w:]+)/,
21
+ rhtml = /<|&#?\w+;/,
22
+ rnoInnerhtml = /<(?:script|style|link)/i,
23
+ // checked="checked" or checked
24
+ rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i,
25
+ rscriptType = /^$|\/(?:java|ecma)script/i,
26
+ rscriptTypeMasked = /^true\/(.*)/,
27
+ rcleanScript = /^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,
28
+
29
+ // We have to close these tags to support XHTML (#13200)
30
+ wrapMap = {
31
+
32
+ // Support: IE 9
33
+ option: [ 1, "<select multiple='multiple'>", "</select>" ],
34
+
35
+ thead: [ 1, "<table>", "</table>" ],
36
+ col: [ 2, "<table><colgroup>", "</colgroup></table>" ],
37
+ tr: [ 2, "<table><tbody>", "</tbody></table>" ],
38
+ td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ],
39
+
40
+ _default: [ 0, "", "" ]
41
+ };
42
+
43
+ // Support: IE 9
44
+ wrapMap.optgroup = wrapMap.option;
45
+
46
+ wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;
47
+ wrapMap.th = wrapMap.td;
48
+
49
+ // Support: 1.x compatibility
50
+ // Manipulating tables requires a tbody
51
+ function manipulationTarget( elem, content ) {
52
+ return jQuery.nodeName( elem, "table" ) &&
53
+ jQuery.nodeName( content.nodeType !== 11 ? content : content.firstChild, "tr" ) ?
54
+
55
+ elem.getElementsByTagName("tbody")[0] ||
56
+ elem.appendChild( elem.ownerDocument.createElement("tbody") ) :
57
+ elem;
58
+ }
59
+
60
+ // Replace/restore the type attribute of script elements for safe DOM manipulation
61
+ function disableScript( elem ) {
62
+ elem.type = (elem.getAttribute("type") !== null) + "/" + elem.type;
63
+ return elem;
64
+ }
65
+ function restoreScript( elem ) {
66
+ var match = rscriptTypeMasked.exec( elem.type );
67
+
68
+ if ( match ) {
69
+ elem.type = match[ 1 ];
70
+ } else {
71
+ elem.removeAttribute("type");
72
+ }
73
+
74
+ return elem;
75
+ }
76
+
77
+ // Mark scripts as having already been evaluated
78
+ function setGlobalEval( elems, refElements ) {
79
+ var i = 0,
80
+ l = elems.length;
81
+
82
+ for ( ; i < l; i++ ) {
83
+ data_priv.set(
84
+ elems[ i ], "globalEval", !refElements || data_priv.get( refElements[ i ], "globalEval" )
85
+ );
86
+ }
87
+ }
88
+
89
+ function cloneCopyEvent( src, dest ) {
90
+ var i, l, type, pdataOld, pdataCur, udataOld, udataCur, events;
91
+
92
+ if ( dest.nodeType !== 1 ) {
93
+ return;
94
+ }
95
+
96
+ // 1. Copy private data: events, handlers, etc.
97
+ if ( data_priv.hasData( src ) ) {
98
+ pdataOld = data_priv.access( src );
99
+ pdataCur = data_priv.set( dest, pdataOld );
100
+ events = pdataOld.events;
101
+
102
+ if ( events ) {
103
+ delete pdataCur.handle;
104
+ pdataCur.events = {};
105
+
106
+ for ( type in events ) {
107
+ for ( i = 0, l = events[ type ].length; i < l; i++ ) {
108
+ jQuery.event.add( dest, type, events[ type ][ i ] );
109
+ }
110
+ }
111
+ }
112
+ }
113
+
114
+ // 2. Copy user data
115
+ if ( data_user.hasData( src ) ) {
116
+ udataOld = data_user.access( src );
117
+ udataCur = jQuery.extend( {}, udataOld );
118
+
119
+ data_user.set( dest, udataCur );
120
+ }
121
+ }
122
+
123
+ function getAll( context, tag ) {
124
+ var ret = context.getElementsByTagName ? context.getElementsByTagName( tag || "*" ) :
125
+ context.querySelectorAll ? context.querySelectorAll( tag || "*" ) :
126
+ [];
127
+
128
+ return tag === undefined || tag && jQuery.nodeName( context, tag ) ?
129
+ jQuery.merge( [ context ], ret ) :
130
+ ret;
131
+ }
132
+
133
+ // Support: IE >= 9
134
+ function fixInput( src, dest ) {
135
+ var nodeName = dest.nodeName.toLowerCase();
136
+
137
+ // Fails to persist the checked state of a cloned checkbox or radio button.
138
+ if ( nodeName === "input" && rcheckableType.test( src.type ) ) {
139
+ dest.checked = src.checked;
140
+
141
+ // Fails to return the selected option to the default selected state when cloning options
142
+ } else if ( nodeName === "input" || nodeName === "textarea" ) {
143
+ dest.defaultValue = src.defaultValue;
144
+ }
145
+ }
146
+
147
+ jQuery.extend({
148
+ clone: function( elem, dataAndEvents, deepDataAndEvents ) {
149
+ var i, l, srcElements, destElements,
150
+ clone = elem.cloneNode( true ),
151
+ inPage = jQuery.contains( elem.ownerDocument, elem );
152
+
153
+ // Support: IE >= 9
154
+ // Fix Cloning issues
155
+ if ( !support.noCloneChecked && ( elem.nodeType === 1 || elem.nodeType === 11 ) &&
156
+ !jQuery.isXMLDoc( elem ) ) {
157
+
158
+ // We eschew Sizzle here for performance reasons: http://jsperf.com/getall-vs-sizzle/2
159
+ destElements = getAll( clone );
160
+ srcElements = getAll( elem );
161
+
162
+ for ( i = 0, l = srcElements.length; i < l; i++ ) {
163
+ fixInput( srcElements[ i ], destElements[ i ] );
164
+ }
165
+ }
166
+
167
+ // Copy the events from the original to the clone
168
+ if ( dataAndEvents ) {
169
+ if ( deepDataAndEvents ) {
170
+ srcElements = srcElements || getAll( elem );
171
+ destElements = destElements || getAll( clone );
172
+
173
+ for ( i = 0, l = srcElements.length; i < l; i++ ) {
174
+ cloneCopyEvent( srcElements[ i ], destElements[ i ] );
175
+ }
176
+ } else {
177
+ cloneCopyEvent( elem, clone );
178
+ }
179
+ }
180
+
181
+ // Preserve script evaluation history
182
+ destElements = getAll( clone, "script" );
183
+ if ( destElements.length > 0 ) {
184
+ setGlobalEval( destElements, !inPage && getAll( elem, "script" ) );
185
+ }
186
+
187
+ // Return the cloned set
188
+ return clone;
189
+ },
190
+
191
+ buildFragment: function( elems, context, scripts, selection ) {
192
+ var elem, tmp, tag, wrap, contains, j,
193
+ fragment = context.createDocumentFragment(),
194
+ nodes = [],
195
+ i = 0,
196
+ l = elems.length;
197
+
198
+ for ( ; i < l; i++ ) {
199
+ elem = elems[ i ];
200
+
201
+ if ( elem || elem === 0 ) {
202
+
203
+ // Add nodes directly
204
+ if ( jQuery.type( elem ) === "object" ) {
205
+ // Support: QtWebKit
206
+ // jQuery.merge because push.apply(_, arraylike) throws
207
+ jQuery.merge( nodes, elem.nodeType ? [ elem ] : elem );
208
+
209
+ // Convert non-html into a text node
210
+ } else if ( !rhtml.test( elem ) ) {
211
+ nodes.push( context.createTextNode( elem ) );
212
+
213
+ // Convert html into DOM nodes
214
+ } else {
215
+ tmp = tmp || fragment.appendChild( context.createElement("div") );
216
+
217
+ // Deserialize a standard representation
218
+ tag = ( rtagName.exec( elem ) || [ "", "" ] )[ 1 ].toLowerCase();
219
+ wrap = wrapMap[ tag ] || wrapMap._default;
220
+ tmp.innerHTML = wrap[ 1 ] + elem.replace( rxhtmlTag, "<$1></$2>" ) + wrap[ 2 ];
221
+
222
+ // Descend through wrappers to the right content
223
+ j = wrap[ 0 ];
224
+ while ( j-- ) {
225
+ tmp = tmp.lastChild;
226
+ }
227
+
228
+ // Support: QtWebKit
229
+ // jQuery.merge because push.apply(_, arraylike) throws
230
+ jQuery.merge( nodes, tmp.childNodes );
231
+
232
+ // Remember the top-level container
233
+ tmp = fragment.firstChild;
234
+
235
+ // Fixes #12346
236
+ // Support: Webkit, IE
237
+ tmp.textContent = "";
238
+ }
239
+ }
240
+ }
241
+
242
+ // Remove wrapper from fragment
243
+ fragment.textContent = "";
244
+
245
+ i = 0;
246
+ while ( (elem = nodes[ i++ ]) ) {
247
+
248
+ // #4087 - If origin and destination elements are the same, and this is
249
+ // that element, do not do anything
250
+ if ( selection && jQuery.inArray( elem, selection ) !== -1 ) {
251
+ continue;
252
+ }
253
+
254
+ contains = jQuery.contains( elem.ownerDocument, elem );
255
+
256
+ // Append to fragment
257
+ tmp = getAll( fragment.appendChild( elem ), "script" );
258
+
259
+ // Preserve script evaluation history
260
+ if ( contains ) {
261
+ setGlobalEval( tmp );
262
+ }
263
+
264
+ // Capture executables
265
+ if ( scripts ) {
266
+ j = 0;
267
+ while ( (elem = tmp[ j++ ]) ) {
268
+ if ( rscriptType.test( elem.type || "" ) ) {
269
+ scripts.push( elem );
270
+ }
271
+ }
272
+ }
273
+ }
274
+
275
+ return fragment;
276
+ },
277
+
278
+ cleanData: function( elems ) {
279
+ var data, elem, events, type, key, j,
280
+ special = jQuery.event.special,
281
+ i = 0;
282
+
283
+ for ( ; (elem = elems[ i ]) !== undefined; i++ ) {
284
+ if ( jQuery.acceptData( elem ) ) {
285
+ key = elem[ data_priv.expando ];
286
+
287
+ if ( key && (data = data_priv.cache[ key ]) ) {
288
+ events = Object.keys( data.events || {} );
289
+ if ( events.length ) {
290
+ for ( j = 0; (type = events[j]) !== undefined; j++ ) {
291
+ if ( special[ type ] ) {
292
+ jQuery.event.remove( elem, type );
293
+
294
+ // This is a shortcut to avoid jQuery.event.remove's overhead
295
+ } else {
296
+ jQuery.removeEvent( elem, type, data.handle );
297
+ }
298
+ }
299
+ }
300
+ if ( data_priv.cache[ key ] ) {
301
+ // Discard any remaining `private` data
302
+ delete data_priv.cache[ key ];
303
+ }
304
+ }
305
+ }
306
+ // Discard any remaining `user` data
307
+ delete data_user.cache[ elem[ data_user.expando ] ];
308
+ }
309
+ }
310
+ });
311
+
312
+ jQuery.fn.extend({
313
+ text: function( value ) {
314
+ return access( this, function( value ) {
315
+ return value === undefined ?
316
+ jQuery.text( this ) :
317
+ this.empty().each(function() {
318
+ if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
319
+ this.textContent = value;
320
+ }
321
+ });
322
+ }, null, value, arguments.length );
323
+ },
324
+
325
+ append: function() {
326
+ return this.domManip( arguments, function( elem ) {
327
+ if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
328
+ var target = manipulationTarget( this, elem );
329
+ target.appendChild( elem );
330
+ }
331
+ });
332
+ },
333
+
334
+ prepend: function() {
335
+ return this.domManip( arguments, function( elem ) {
336
+ if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {
337
+ var target = manipulationTarget( this, elem );
338
+ target.insertBefore( elem, target.firstChild );
339
+ }
340
+ });
341
+ },
342
+
343
+ before: function() {
344
+ return this.domManip( arguments, function( elem ) {
345
+ if ( this.parentNode ) {
346
+ this.parentNode.insertBefore( elem, this );
347
+ }
348
+ });
349
+ },
350
+
351
+ after: function() {
352
+ return this.domManip( arguments, function( elem ) {
353
+ if ( this.parentNode ) {
354
+ this.parentNode.insertBefore( elem, this.nextSibling );
355
+ }
356
+ });
357
+ },
358
+
359
+ remove: function( selector, keepData /* Internal Use Only */ ) {
360
+ var elem,
361
+ elems = selector ? jQuery.filter( selector, this ) : this,
362
+ i = 0;
363
+
364
+ for ( ; (elem = elems[i]) != null; i++ ) {
365
+ if ( !keepData && elem.nodeType === 1 ) {
366
+ jQuery.cleanData( getAll( elem ) );
367
+ }
368
+
369
+ if ( elem.parentNode ) {
370
+ if ( keepData && jQuery.contains( elem.ownerDocument, elem ) ) {
371
+ setGlobalEval( getAll( elem, "script" ) );
372
+ }
373
+ elem.parentNode.removeChild( elem );
374
+ }
375
+ }
376
+
377
+ return this;
378
+ },
379
+
380
+ empty: function() {
381
+ var elem,
382
+ i = 0;
383
+
384
+ for ( ; (elem = this[i]) != null; i++ ) {
385
+ if ( elem.nodeType === 1 ) {
386
+
387
+ // Prevent memory leaks
388
+ jQuery.cleanData( getAll( elem, false ) );
389
+
390
+ // Remove any remaining nodes
391
+ elem.textContent = "";
392
+ }
393
+ }
394
+
395
+ return this;
396
+ },
397
+
398
+ clone: function( dataAndEvents, deepDataAndEvents ) {
399
+ dataAndEvents = dataAndEvents == null ? false : dataAndEvents;
400
+ deepDataAndEvents = deepDataAndEvents == null ? dataAndEvents : deepDataAndEvents;
401
+
402
+ return this.map(function() {
403
+ return jQuery.clone( this, dataAndEvents, deepDataAndEvents );
404
+ });
405
+ },
406
+
407
+ html: function( value ) {
408
+ return access( this, function( value ) {
409
+ var elem = this[ 0 ] || {},
410
+ i = 0,
411
+ l = this.length;
412
+
413
+ if ( value === undefined && elem.nodeType === 1 ) {
414
+ return elem.innerHTML;
415
+ }
416
+
417
+ // See if we can take a shortcut and just use innerHTML
418
+ if ( typeof value === "string" && !rnoInnerhtml.test( value ) &&
419
+ !wrapMap[ ( rtagName.exec( value ) || [ "", "" ] )[ 1 ].toLowerCase() ] ) {
420
+
421
+ value = value.replace( rxhtmlTag, "<$1></$2>" );
422
+
423
+ try {
424
+ for ( ; i < l; i++ ) {
425
+ elem = this[ i ] || {};
426
+
427
+ // Remove element nodes and prevent memory leaks
428
+ if ( elem.nodeType === 1 ) {
429
+ jQuery.cleanData( getAll( elem, false ) );
430
+ elem.innerHTML = value;
431
+ }
432
+ }
433
+
434
+ elem = 0;
435
+
436
+ // If using innerHTML throws an exception, use the fallback method
437
+ } catch( e ) {}
438
+ }
439
+
440
+ if ( elem ) {
441
+ this.empty().append( value );
442
+ }
443
+ }, null, value, arguments.length );
444
+ },
445
+
446
+ replaceWith: function() {
447
+ var arg = arguments[ 0 ];
448
+
449
+ // Make the changes, replacing each context element with the new content
450
+ this.domManip( arguments, function( elem ) {
451
+ arg = this.parentNode;
452
+
453
+ jQuery.cleanData( getAll( this ) );
454
+
455
+ if ( arg ) {
456
+ arg.replaceChild( elem, this );
457
+ }
458
+ });
459
+
460
+ // Force removal if there was no new content (e.g., from empty arguments)
461
+ return arg && (arg.length || arg.nodeType) ? this : this.remove();
462
+ },
463
+
464
+ detach: function( selector ) {
465
+ return this.remove( selector, true );
466
+ },
467
+
468
+ domManip: function( args, callback ) {
469
+
470
+ // Flatten any nested arrays
471
+ args = concat.apply( [], args );
472
+
473
+ var fragment, first, scripts, hasScripts, node, doc,
474
+ i = 0,
475
+ l = this.length,
476
+ set = this,
477
+ iNoClone = l - 1,
478
+ value = args[ 0 ],
479
+ isFunction = jQuery.isFunction( value );
480
+
481
+ // We can't cloneNode fragments that contain checked, in WebKit
482
+ if ( isFunction ||
483
+ ( l > 1 && typeof value === "string" &&
484
+ !support.checkClone && rchecked.test( value ) ) ) {
485
+ return this.each(function( index ) {
486
+ var self = set.eq( index );
487
+ if ( isFunction ) {
488
+ args[ 0 ] = value.call( this, index, self.html() );
489
+ }
490
+ self.domManip( args, callback );
491
+ });
492
+ }
493
+
494
+ if ( l ) {
495
+ fragment = jQuery.buildFragment( args, this[ 0 ].ownerDocument, false, this );
496
+ first = fragment.firstChild;
497
+
498
+ if ( fragment.childNodes.length === 1 ) {
499
+ fragment = first;
500
+ }
501
+
502
+ if ( first ) {
503
+ scripts = jQuery.map( getAll( fragment, "script" ), disableScript );
504
+ hasScripts = scripts.length;
505
+
506
+ // Use the original fragment for the last item instead of the first because it can end up
507
+ // being emptied incorrectly in certain situations (#8070).
508
+ for ( ; i < l; i++ ) {
509
+ node = fragment;
510
+
511
+ if ( i !== iNoClone ) {
512
+ node = jQuery.clone( node, true, true );
513
+
514
+ // Keep references to cloned scripts for later restoration
515
+ if ( hasScripts ) {
516
+ // Support: QtWebKit
517
+ // jQuery.merge because push.apply(_, arraylike) throws
518
+ jQuery.merge( scripts, getAll( node, "script" ) );
519
+ }
520
+ }
521
+
522
+ callback.call( this[ i ], node, i );
523
+ }
524
+
525
+ if ( hasScripts ) {
526
+ doc = scripts[ scripts.length - 1 ].ownerDocument;
527
+
528
+ // Reenable scripts
529
+ jQuery.map( scripts, restoreScript );
530
+
531
+ // Evaluate executable scripts on first document insertion
532
+ for ( i = 0; i < hasScripts; i++ ) {
533
+ node = scripts[ i ];
534
+ if ( rscriptType.test( node.type || "" ) &&
535
+ !data_priv.access( node, "globalEval" ) && jQuery.contains( doc, node ) ) {
536
+
537
+ if ( node.src ) {
538
+ // Optional AJAX dependency, but won't run scripts if not present
539
+ if ( jQuery._evalUrl ) {
540
+ jQuery._evalUrl( node.src );
541
+ }
542
+ } else {
543
+ jQuery.globalEval( node.textContent.replace( rcleanScript, "" ) );
544
+ }
545
+ }
546
+ }
547
+ }
548
+ }
549
+ }
550
+
551
+ return this;
552
+ }
553
+ });
554
+
555
+ jQuery.each({
556
+ appendTo: "append",
557
+ prependTo: "prepend",
558
+ insertBefore: "before",
559
+ insertAfter: "after",
560
+ replaceAll: "replaceWith"
561
+ }, function( name, original ) {
562
+ jQuery.fn[ name ] = function( selector ) {
563
+ var elems,
564
+ ret = [],
565
+ insert = jQuery( selector ),
566
+ last = insert.length - 1,
567
+ i = 0;
568
+
569
+ for ( ; i <= last; i++ ) {
570
+ elems = i === last ? this : this.clone( true );
571
+ jQuery( insert[ i ] )[ original ]( elems );
572
+
573
+ // Support: QtWebKit
574
+ // .get() because push.apply(_, arraylike) throws
575
+ push.apply( ret, elems.get() );
576
+ }
577
+
578
+ return this.pushStack( ret );
579
+ };
580
+ });
581
+
582
+ return jQuery;
583
+ });