postrest 0.0.3 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (234) hide show
  1. checksums.yaml +4 -4
  2. data/lib/app.rb +1 -1
  3. data/public/index.htm +116 -0
  4. data/public/node_modules/pivottable/CONTRIBUTING.md +19 -0
  5. data/public/node_modules/pivottable/LICENSE.md +9 -0
  6. data/public/node_modules/pivottable/ReadMe.md +155 -0
  7. data/public/node_modules/pivottable/bower.json +31 -0
  8. data/public/node_modules/pivottable/c3_renderers.coffee +155 -0
  9. data/public/node_modules/pivottable/d3_renderers.coffee +73 -0
  10. data/public/node_modules/pivottable/dist/c3_renderers.js +256 -0
  11. data/public/node_modules/pivottable/dist/c3_renderers.js.map +1 -0
  12. data/public/node_modules/pivottable/dist/c3_renderers.min.js +2 -0
  13. data/public/node_modules/pivottable/dist/c3_renderers.min.js.map +1 -0
  14. data/public/node_modules/pivottable/dist/d3_renderers.js +105 -0
  15. data/public/node_modules/pivottable/dist/d3_renderers.js.map +1 -0
  16. data/public/node_modules/pivottable/dist/d3_renderers.min.js +2 -0
  17. data/public/node_modules/pivottable/dist/d3_renderers.min.js.map +1 -0
  18. data/public/node_modules/pivottable/dist/export_renderers.js +80 -0
  19. data/public/node_modules/pivottable/dist/export_renderers.js.map +1 -0
  20. data/public/node_modules/pivottable/dist/export_renderers.min.js +2 -0
  21. data/public/node_modules/pivottable/dist/export_renderers.min.js.map +1 -0
  22. data/public/node_modules/pivottable/dist/gchart_renderers.js +183 -0
  23. data/public/node_modules/pivottable/dist/gchart_renderers.js.map +1 -0
  24. data/public/node_modules/pivottable/dist/gchart_renderers.min.js +2 -0
  25. data/public/node_modules/pivottable/dist/gchart_renderers.min.js.map +1 -0
  26. data/public/node_modules/pivottable/dist/pivot.css +97 -0
  27. data/public/node_modules/pivottable/dist/pivot.es.js +78 -0
  28. data/public/node_modules/pivottable/dist/pivot.es.js.map +1 -0
  29. data/public/node_modules/pivottable/dist/pivot.es.min.js +2 -0
  30. data/public/node_modules/pivottable/dist/pivot.es.min.js.map +1 -0
  31. data/public/node_modules/pivottable/dist/pivot.fr.js +78 -0
  32. data/public/node_modules/pivottable/dist/pivot.fr.js.map +1 -0
  33. data/public/node_modules/pivottable/dist/pivot.fr.min.js +2 -0
  34. data/public/node_modules/pivottable/dist/pivot.fr.min.js.map +1 -0
  35. data/public/node_modules/pivottable/dist/pivot.js +1511 -0
  36. data/public/node_modules/pivottable/dist/pivot.js.map +1 -0
  37. data/public/node_modules/pivottable/dist/pivot.min.css +1 -0
  38. data/public/node_modules/pivottable/dist/pivot.min.js +2 -0
  39. data/public/node_modules/pivottable/dist/pivot.min.js.map +1 -0
  40. data/public/node_modules/pivottable/dist/pivot.nl.js +78 -0
  41. data/public/node_modules/pivottable/dist/pivot.nl.js.map +1 -0
  42. data/public/node_modules/pivottable/dist/pivot.nl.min.js +2 -0
  43. data/public/node_modules/pivottable/dist/pivot.nl.min.js.map +1 -0
  44. data/public/node_modules/pivottable/dist/pivot.pt.js +104 -0
  45. data/public/node_modules/pivottable/dist/pivot.pt.js.map +1 -0
  46. data/public/node_modules/pivottable/dist/pivot.pt.min.js +2 -0
  47. data/public/node_modules/pivottable/dist/pivot.pt.min.js.map +1 -0
  48. data/public/node_modules/pivottable/dist/pivot.ru.js +78 -0
  49. data/public/node_modules/pivottable/dist/pivot.ru.js.map +1 -0
  50. data/public/node_modules/pivottable/dist/pivot.ru.min.js +2 -0
  51. data/public/node_modules/pivottable/dist/pivot.ru.min.js.map +1 -0
  52. data/public/node_modules/pivottable/dist/pivot.tr.js +104 -0
  53. data/public/node_modules/pivottable/dist/pivot.tr.js.map +1 -0
  54. data/public/node_modules/pivottable/dist/pivot.tr.min.js +2 -0
  55. data/public/node_modules/pivottable/dist/pivot.tr.min.js.map +1 -0
  56. data/public/node_modules/pivottable/dist/tips_data.min.js +247 -0
  57. data/public/node_modules/pivottable/examples/c3.html +61 -0
  58. data/public/node_modules/pivottable/examples/d3.html +49 -0
  59. data/public/node_modules/pivottable/examples/fully_loaded.html +80 -0
  60. data/public/node_modules/pivottable/examples/gchart.html +53 -0
  61. data/public/node_modules/pivottable/examples/gh-fork-ribbon.css +140 -0
  62. data/public/node_modules/pivottable/examples/gh-fork-ribbon.ie.css +78 -0
  63. data/public/node_modules/pivottable/examples/index.html +85 -0
  64. data/public/node_modules/pivottable/examples/local.html +74 -0
  65. data/public/node_modules/pivottable/examples/montreal_2014.csv +366 -0
  66. data/public/node_modules/pivottable/examples/montreal_2014.html +106 -0
  67. data/public/node_modules/pivottable/examples/mps.csv +309 -0
  68. data/public/node_modules/pivottable/examples/mps.html +45 -0
  69. data/public/node_modules/pivottable/examples/mps.json +1 -0
  70. data/public/node_modules/pivottable/examples/mps_agg.html +44 -0
  71. data/public/node_modules/pivottable/examples/mps_csv.html +42 -0
  72. data/public/node_modules/pivottable/examples/mps_export.html +44 -0
  73. data/public/node_modules/pivottable/examples/mps_fr.html +40 -0
  74. data/public/node_modules/pivottable/examples/mps_prepop.html +42 -0
  75. data/public/node_modules/pivottable/examples/onrefresh.html +52 -0
  76. data/public/node_modules/pivottable/examples/rcsvs.html +87 -0
  77. data/public/node_modules/pivottable/examples/scatter.html +53 -0
  78. data/public/node_modules/pivottable/examples/show_code.js +17 -0
  79. data/public/node_modules/pivottable/examples/simple.html +41 -0
  80. data/public/node_modules/pivottable/examples/simple_agg.html +51 -0
  81. data/public/node_modules/pivottable/examples/simple_function.html +57 -0
  82. data/public/node_modules/pivottable/examples/simple_ui.html +42 -0
  83. data/public/node_modules/pivottable/examples/simple_ui_from_table.html +60 -0
  84. data/public/node_modules/pivottable/export_renderers.coffee +57 -0
  85. data/public/node_modules/pivottable/gchart_renderers.coffee +111 -0
  86. data/public/node_modules/pivottable/gulpFile.js +95 -0
  87. data/public/node_modules/pivottable/images/animation.gif +0 -0
  88. data/public/node_modules/pivottable/images/filters.png +0 -0
  89. data/public/node_modules/pivottable/images/gender_age_bins.png +0 -0
  90. data/public/node_modules/pivottable/images/gender_imbalance.png +0 -0
  91. data/public/node_modules/pivottable/images/gender_imbalance_instructions.png +0 -0
  92. data/public/node_modules/pivottable/images/initial_state.png +0 -0
  93. data/public/node_modules/pivottable/images/province_x_party_heatmap.png +0 -0
  94. data/public/node_modules/pivottable/images/province_x_party_heatmap_instructions.png +0 -0
  95. data/public/node_modules/pivottable/images/simple.png +0 -0
  96. data/public/node_modules/pivottable/images/simple_ui.png +0 -0
  97. data/public/node_modules/pivottable/images/whats_what.png +0 -0
  98. data/public/node_modules/pivottable/index.html +14 -0
  99. data/public/node_modules/pivottable/node_modules/jquery/AUTHORS.txt +278 -0
  100. data/public/node_modules/pivottable/node_modules/jquery/LICENSE.txt +36 -0
  101. data/public/node_modules/pivottable/node_modules/jquery/README.md +65 -0
  102. data/public/node_modules/pivottable/node_modules/jquery/bower.json +14 -0
  103. data/public/node_modules/pivottable/node_modules/jquery/dist/jquery.js +9842 -0
  104. data/public/node_modules/pivottable/node_modules/jquery/dist/jquery.min.js +4 -0
  105. data/public/node_modules/pivottable/node_modules/jquery/dist/jquery.min.map +1 -0
  106. data/public/node_modules/pivottable/node_modules/jquery/dist/jquery.slim.js +7877 -0
  107. data/public/node_modules/pivottable/node_modules/jquery/dist/jquery.slim.min.js +4 -0
  108. data/public/node_modules/pivottable/node_modules/jquery/dist/jquery.slim.min.map +1 -0
  109. data/public/node_modules/pivottable/node_modules/jquery/package.json +122 -0
  110. data/public/node_modules/pivottable/node_modules/jquery/sizzle/LICENSE.txt +36 -0
  111. data/public/node_modules/pivottable/node_modules/jquery/sizzle/dist/sizzle.js +2143 -0
  112. data/public/node_modules/pivottable/node_modules/jquery/sizzle/dist/sizzle.min.js +3 -0
  113. data/public/node_modules/pivottable/node_modules/jquery/sizzle/dist/sizzle.min.map +1 -0
  114. data/public/node_modules/pivottable/node_modules/jquery/src/ajax.js +845 -0
  115. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/jsonp.js +100 -0
  116. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/load.js +83 -0
  117. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/parseJSON.js +13 -0
  118. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/parseXML.js +27 -0
  119. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/script.js +68 -0
  120. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/var/location.js +3 -0
  121. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/var/nonce.js +5 -0
  122. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/var/rquery.js +3 -0
  123. data/public/node_modules/pivottable/node_modules/jquery/src/ajax/xhr.js +167 -0
  124. data/public/node_modules/pivottable/node_modules/jquery/src/attributes.js +11 -0
  125. data/public/node_modules/pivottable/node_modules/jquery/src/attributes/attr.js +142 -0
  126. data/public/node_modules/pivottable/node_modules/jquery/src/attributes/classes.js +177 -0
  127. data/public/node_modules/pivottable/node_modules/jquery/src/attributes/prop.js +125 -0
  128. data/public/node_modules/pivottable/node_modules/jquery/src/attributes/support.js +36 -0
  129. data/public/node_modules/pivottable/node_modules/jquery/src/attributes/val.js +177 -0
  130. data/public/node_modules/pivottable/node_modules/jquery/src/callbacks.js +232 -0
  131. data/public/node_modules/pivottable/node_modules/jquery/src/core.js +494 -0
  132. data/public/node_modules/pivottable/node_modules/jquery/src/core/DOMEval.js +14 -0
  133. data/public/node_modules/pivottable/node_modules/jquery/src/core/access.js +65 -0
  134. data/public/node_modules/pivottable/node_modules/jquery/src/core/init.js +134 -0
  135. data/public/node_modules/pivottable/node_modules/jquery/src/core/parseHTML.js +41 -0
  136. data/public/node_modules/pivottable/node_modules/jquery/src/core/ready.js +103 -0
  137. data/public/node_modules/pivottable/node_modules/jquery/src/core/support.js +18 -0
  138. data/public/node_modules/pivottable/node_modules/jquery/src/core/var/rsingleTag.js +5 -0
  139. data/public/node_modules/pivottable/node_modules/jquery/src/css.js +515 -0
  140. data/public/node_modules/pivottable/node_modules/jquery/src/css/addGetHookIf.js +24 -0
  141. data/public/node_modules/pivottable/node_modules/jquery/src/css/adjustCSS.js +65 -0
  142. data/public/node_modules/pivottable/node_modules/jquery/src/css/curCSS.js +60 -0
  143. data/public/node_modules/pivottable/node_modules/jquery/src/css/defaultDisplay.js +72 -0
  144. data/public/node_modules/pivottable/node_modules/jquery/src/css/hiddenVisibleSelectors.js +18 -0
  145. data/public/node_modules/pivottable/node_modules/jquery/src/css/showHide.js +48 -0
  146. data/public/node_modules/pivottable/node_modules/jquery/src/css/support.js +121 -0
  147. data/public/node_modules/pivottable/node_modules/jquery/src/css/var/cssExpand.js +3 -0
  148. data/public/node_modules/pivottable/node_modules/jquery/src/css/var/getStyles.js +15 -0
  149. data/public/node_modules/pivottable/node_modules/jquery/src/css/var/isHidden.js +16 -0
  150. data/public/node_modules/pivottable/node_modules/jquery/src/css/var/rmargin.js +3 -0
  151. data/public/node_modules/pivottable/node_modules/jquery/src/css/var/rnumnonpx.js +5 -0
  152. data/public/node_modules/pivottable/node_modules/jquery/src/css/var/swap.js +24 -0
  153. data/public/node_modules/pivottable/node_modules/jquery/src/data.js +187 -0
  154. data/public/node_modules/pivottable/node_modules/jquery/src/data/Data.js +200 -0
  155. data/public/node_modules/pivottable/node_modules/jquery/src/data/accepts.js +20 -0
  156. data/public/node_modules/pivottable/node_modules/jquery/src/data/support.js +23 -0
  157. data/public/node_modules/pivottable/node_modules/jquery/src/data/var/acceptData.js +18 -0
  158. data/public/node_modules/pivottable/node_modules/jquery/src/data/var/dataPriv.js +5 -0
  159. data/public/node_modules/pivottable/node_modules/jquery/src/data/var/dataUser.js +5 -0
  160. data/public/node_modules/pivottable/node_modules/jquery/src/deferred.js +158 -0
  161. data/public/node_modules/pivottable/node_modules/jquery/src/deferred/exceptionHook.js +19 -0
  162. data/public/node_modules/pivottable/node_modules/jquery/src/deprecated.js +32 -0
  163. data/public/node_modules/pivottable/node_modules/jquery/src/dimensions.js +54 -0
  164. data/public/node_modules/pivottable/node_modules/jquery/src/effects.js +629 -0
  165. data/public/node_modules/pivottable/node_modules/jquery/src/effects/Tween.js +121 -0
  166. data/public/node_modules/pivottable/node_modules/jquery/src/effects/animatedSelector.js +13 -0
  167. data/public/node_modules/pivottable/node_modules/jquery/src/effects/support.js +58 -0
  168. data/public/node_modules/pivottable/node_modules/jquery/src/event.js +710 -0
  169. data/public/node_modules/pivottable/node_modules/jquery/src/event/ajax.js +20 -0
  170. data/public/node_modules/pivottable/node_modules/jquery/src/event/alias.js +27 -0
  171. data/public/node_modules/pivottable/node_modules/jquery/src/event/focusin.js +53 -0
  172. data/public/node_modules/pivottable/node_modules/jquery/src/event/support.js +9 -0
  173. data/public/node_modules/pivottable/node_modules/jquery/src/event/trigger.js +199 -0
  174. data/public/node_modules/pivottable/node_modules/jquery/src/exports/amd.js +24 -0
  175. data/public/node_modules/pivottable/node_modules/jquery/src/exports/global.js +26 -0
  176. data/public/node_modules/pivottable/node_modules/jquery/src/intro.js +44 -0
  177. data/public/node_modules/pivottable/node_modules/jquery/src/jquery.js +37 -0
  178. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation.js +481 -0
  179. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/_evalUrl.js +20 -0
  180. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/buildFragment.js +102 -0
  181. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/createSafeFragment.js +20 -0
  182. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/getAll.js +21 -0
  183. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/setGlobalEval.js +20 -0
  184. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/support.js +33 -0
  185. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/var/nodeNames.js +5 -0
  186. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/var/rcheckableType.js +3 -0
  187. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/var/rleadingWhitespace.js +3 -0
  188. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/var/rscriptType.js +3 -0
  189. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/var/rtagName.js +3 -0
  190. data/public/node_modules/pivottable/node_modules/jquery/src/manipulation/wrapMap.js +27 -0
  191. data/public/node_modules/pivottable/node_modules/jquery/src/offset.js +218 -0
  192. data/public/node_modules/pivottable/node_modules/jquery/src/outro.js +2 -0
  193. data/public/node_modules/pivottable/node_modules/jquery/src/queue.js +143 -0
  194. data/public/node_modules/pivottable/node_modules/jquery/src/queue/delay.js +22 -0
  195. data/public/node_modules/pivottable/node_modules/jquery/src/selector-native.js +211 -0
  196. data/public/node_modules/pivottable/node_modules/jquery/src/selector-sizzle.js +14 -0
  197. data/public/node_modules/pivottable/node_modules/jquery/src/selector.js +1 -0
  198. data/public/node_modules/pivottable/node_modules/jquery/src/serialize.js +125 -0
  199. data/public/node_modules/pivottable/node_modules/jquery/src/support.js +63 -0
  200. data/public/node_modules/pivottable/node_modules/jquery/src/traversing.js +175 -0
  201. data/public/node_modules/pivottable/node_modules/jquery/src/traversing/findFilter.js +100 -0
  202. data/public/node_modules/pivottable/node_modules/jquery/src/traversing/var/dir.js +20 -0
  203. data/public/node_modules/pivottable/node_modules/jquery/src/traversing/var/rneedsContext.js +6 -0
  204. data/public/node_modules/pivottable/node_modules/jquery/src/traversing/var/siblings.js +15 -0
  205. data/public/node_modules/pivottable/node_modules/jquery/src/var/arr.js +3 -0
  206. data/public/node_modules/pivottable/node_modules/jquery/src/var/class2type.js +5 -0
  207. data/public/node_modules/pivottable/node_modules/jquery/src/var/concat.js +5 -0
  208. data/public/node_modules/pivottable/node_modules/jquery/src/var/deletedIds.js +3 -0
  209. data/public/node_modules/pivottable/node_modules/jquery/src/var/document.js +3 -0
  210. data/public/node_modules/pivottable/node_modules/jquery/src/var/documentElement.js +5 -0
  211. data/public/node_modules/pivottable/node_modules/jquery/src/var/hasOwn.js +5 -0
  212. data/public/node_modules/pivottable/node_modules/jquery/src/var/indexOf.js +5 -0
  213. data/public/node_modules/pivottable/node_modules/jquery/src/var/pnum.js +3 -0
  214. data/public/node_modules/pivottable/node_modules/jquery/src/var/push.js +5 -0
  215. data/public/node_modules/pivottable/node_modules/jquery/src/var/rcssNum.js +7 -0
  216. data/public/node_modules/pivottable/node_modules/jquery/src/var/rnotwhite.js +3 -0
  217. data/public/node_modules/pivottable/node_modules/jquery/src/var/slice.js +5 -0
  218. data/public/node_modules/pivottable/node_modules/jquery/src/var/support.js +5 -0
  219. data/public/node_modules/pivottable/node_modules/jquery/src/var/toString.js +5 -0
  220. data/public/node_modules/pivottable/node_modules/jquery/src/wrap.js +79 -0
  221. data/public/node_modules/pivottable/package.json +70 -0
  222. data/public/node_modules/pivottable/pivot.coffee +957 -0
  223. data/public/node_modules/pivottable/pivot.es.coffee +57 -0
  224. data/public/node_modules/pivottable/pivot.fr.coffee +57 -0
  225. data/public/node_modules/pivottable/pivot.nl.coffee +55 -0
  226. data/public/node_modules/pivottable/pivot.pt.coffee +80 -0
  227. data/public/node_modules/pivottable/pivot.ru.coffee +56 -0
  228. data/public/node_modules/pivottable/pivot.tr.coffee +80 -0
  229. data/public/node_modules/pivottable/pivottable.jquery.json +33 -0
  230. data/public/node_modules/pivottable/tests/boot.js +152 -0
  231. data/public/node_modules/pivottable/tests/index.html +35 -0
  232. data/public/node_modules/pivottable/tests/pivot_spec.coffee +458 -0
  233. data/public/vendor.js +5 -0
  234. metadata +232 -1
@@ -0,0 +1,61 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Pivot Demo</title>
5
+ <!-- external libs from cdnjs -->
6
+ <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/c3/0.4.10/c3.min.css">
7
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script>
8
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/c3/0.4.10/c3.min.js"></script>
9
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
10
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
11
+
12
+ <!-- PivotTable.js libs from ../dist -->
13
+ <link rel="stylesheet" type="text/css" href="../dist/pivot.css">
14
+ <script type="text/javascript" src="../dist/pivot.js"></script>
15
+ <script type="text/javascript" src="../dist/c3_renderers.js"></script>
16
+ <style>
17
+ body {font-family: Verdana;}
18
+
19
+ .c3-line, .c3-focused {stroke-width: 3px !important;}
20
+ .c3-bar {stroke: white !important; stroke-width: 1;}
21
+ .c3 text { font-size: 12px; color: grey;}
22
+ .tick line {stroke: white;}
23
+ .c3-axis path {stroke: grey;}
24
+ .c3-circle { opacity: 1 !important; }
25
+ </style>
26
+
27
+ <!-- for examples only! script to show code to user -->
28
+ <script type="text/javascript" src="show_code.js"></script>
29
+ </head>
30
+ <body>
31
+ <script type="text/javascript">
32
+ // This example adds C3 chart renderers.
33
+
34
+ $(function(){
35
+
36
+ var derivers = $.pivotUtilities.derivers;
37
+ var renderers = $.extend($.pivotUtilities.renderers,
38
+ $.pivotUtilities.c3_renderers);
39
+
40
+ $.getJSON("mps.json", function(mps) {
41
+ $("#output").pivotUI(mps, {
42
+ renderers: renderers,
43
+ derivedAttributes: {
44
+ "Age Bin": derivers.bin("Age", 10),
45
+ "Gender Imbalance": function(mp) {
46
+ return mp["Gender"] == "Male" ? 1 : -1;
47
+ }
48
+ },
49
+ cols: ["Age Bin"], rows: ["Gender"],
50
+ rendererName: "Area Chart"
51
+ });
52
+ });
53
+ });
54
+ </script>
55
+
56
+ <p><a href="index.html">&laquo; back to examples</a></p>
57
+
58
+ <div id="output" style="margin: 30px;"></div>
59
+
60
+ </body>
61
+ </html>
@@ -0,0 +1,49 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Pivot Demo</title>
5
+ <!-- external libs from cdnjs -->
6
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script>
7
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
8
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
9
+
10
+ <!-- PivotTable.js libs from ../dist -->
11
+ <link rel="stylesheet" type="text/css" href="../dist/pivot.css">
12
+ <script type="text/javascript" src="../dist/pivot.js"></script>
13
+ <script type="text/javascript" src="../dist/d3_renderers.js"></script>
14
+ <style>
15
+ body {font-family: Verdana;}
16
+ .node {
17
+ border: solid 1px white;
18
+ font: 10px sans-serif;
19
+ line-height: 12px;
20
+ overflow: hidden;
21
+ position: absolute;
22
+ text-indent: 2px;
23
+ }
24
+ </style>
25
+
26
+ <!-- for examples only! script to show code to user -->
27
+ <script type="text/javascript" src="show_code.js"></script>
28
+ </head>
29
+ <body>
30
+ <script type="text/javascript">
31
+ // This example of a D3 renderer shows a treemap.
32
+
33
+ $(function(){
34
+ $.getJSON("mps.json", function(mps) {
35
+ $("#output").pivotUI(mps, {
36
+ renderers: $.pivotUtilities.d3_renderers,
37
+ cols: [], rows: ["Province", "Party"],
38
+ rendererName: "Treemap"
39
+ });
40
+ });
41
+ });
42
+ </script>
43
+
44
+ <p><a href="index.html">&laquo; back to examples</a></p>
45
+
46
+ <div id="output" style="margin: 30px;"></div>
47
+
48
+ </body>
49
+ </html>
@@ -0,0 +1,80 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Pivot Demo</title>
5
+
6
+ <!-- external libs from cdnjs -->
7
+ <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/c3/0.4.10/c3.min.css">
8
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
9
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
10
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script>
11
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jqueryui-touch-punch/0.2.3/jquery.ui.touch-punch.min.js"></script>
12
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery-csv/0.71/jquery.csv-0.71.min.js"></script>
13
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/c3/0.4.10/c3.min.js"></script>
14
+
15
+ <!-- PivotTable.js libs from ../dist -->
16
+ <link rel="stylesheet" type="text/css" href="../dist/pivot.css">
17
+ <script type="text/javascript" src="../dist/pivot.js"></script>
18
+ <script type="text/javascript" src="../dist/export_renderers.js"></script>
19
+ <script type="text/javascript" src="../dist/d3_renderers.js"></script>
20
+ <script type="text/javascript" src="../dist/c3_renderers.js"></script>
21
+
22
+ <style>
23
+ body {font-family: Verdana;}
24
+ .node {
25
+ border: solid 1px white;
26
+ font: 10px sans-serif;
27
+ line-height: 12px;
28
+ overflow: hidden;
29
+ position: absolute;
30
+ text-indent: 2px;
31
+ }
32
+ .c3-line, .c3-focused {stroke-width: 3px !important;}
33
+ .c3-bar {stroke: white !important; stroke-width: 1;}
34
+ .c3 text { font-size: 12px; color: grey;}
35
+ .tick line {stroke: white;}
36
+ .c3-axis path {stroke: grey;}
37
+ .c3-circle { opacity: 1 !important; }
38
+ </style>
39
+
40
+ <!-- for examples only! script to show code to user -->
41
+ <script type="text/javascript" src="show_code.js"></script>
42
+ </head>
43
+ <body>
44
+ <script type="text/javascript">
45
+ // This example has all the renderers loaded,
46
+ // and should work with touch devices.
47
+
48
+ $(function(){
49
+ var derivers = $.pivotUtilities.derivers;
50
+
51
+ var renderers = $.extend(
52
+ $.pivotUtilities.renderers,
53
+ $.pivotUtilities.c3_renderers,
54
+ $.pivotUtilities.d3_renderers,
55
+ $.pivotUtilities.export_renderers
56
+ );
57
+
58
+ $.getJSON("mps.json", function(mps) {
59
+ $("#output").pivotUI(mps, {
60
+ renderers: renderers,
61
+ derivedAttributes: {
62
+ "Age Bin": derivers.bin("Age", 10),
63
+ "Gender Imbalance": function(mp) {
64
+ return mp["Gender"] == "Male" ? 1 : -1;
65
+ }
66
+ },
67
+ cols: ["Age Bin"], rows: ["Gender"],
68
+ rendererName: "Table Barchart"
69
+ });
70
+ });
71
+ });
72
+ </script>
73
+
74
+ <p><a href="index.html">&laquo; back to examples</a></p>
75
+
76
+
77
+ <div id="output" style="margin: 30px;"></div>
78
+
79
+ </body>
80
+ </html>
@@ -0,0 +1,53 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Pivot Demo</title>
5
+ <script type="text/javascript" src="https://www.google.com/jsapi"></script>
6
+
7
+ <!-- external libs from cdnjs -->
8
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
9
+ <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
10
+
11
+ <!-- PivotTable.js libs from ../dist -->
12
+ <link rel="stylesheet" type="text/css" href="../dist/pivot.css">
13
+ <script type="text/javascript" src="../dist/pivot.js"></script>
14
+ <script type="text/javascript" src="../dist/gchart_renderers.js"></script>
15
+ <style>
16
+ body {font-family: Verdana;}
17
+ </style>
18
+
19
+ <!-- for examples only! script to show code to user -->
20
+ <script type="text/javascript" src="show_code.js"></script>
21
+ </head>
22
+ <body>
23
+ <script type="text/javascript">
24
+ // This example adds Google Chart renderers.
25
+
26
+ google.load("visualization", "1", {packages:["corechart", "charteditor"]});
27
+ $(function(){
28
+ var derivers = $.pivotUtilities.derivers;
29
+ var renderers = $.extend($.pivotUtilities.renderers,
30
+ $.pivotUtilities.gchart_renderers);
31
+
32
+ $.getJSON("mps.json", function(mps) {
33
+ $("#output").pivotUI(mps, {
34
+ renderers: renderers,
35
+ derivedAttributes: {
36
+ "Age Bin": derivers.bin("Age", 10),
37
+ "Gender Imbalance": function(mp) {
38
+ return mp["Gender"] == "Male" ? 1 : -1;
39
+ }
40
+ },
41
+ cols: ["Age Bin"], rows: ["Gender"],
42
+ rendererName: "Area Chart"
43
+ });
44
+ });
45
+ });
46
+ </script>
47
+
48
+ <p><a href="index.html">&laquo; back to examples</a></p>
49
+
50
+ <div id="output" style="margin: 30px;"></div>
51
+
52
+ </body>
53
+ </html>
@@ -0,0 +1,140 @@
1
+ /*!
2
+ * "Fork me on GitHub" CSS ribbon v0.1.1 | MIT License
3
+ * https://github.com/simonwhitaker/github-fork-ribbon-css
4
+ */
5
+
6
+ /* Left will inherit from right (so we don't need to duplicate code) */
7
+ .github-fork-ribbon {
8
+ /* The right and left classes determine the side we attach our banner to */
9
+ position: absolute;
10
+
11
+ /* Add a bit of padding to give some substance outside the "stitching" */
12
+ padding: 2px 0;
13
+
14
+ /* Set the base colour */
15
+ background-color: #a00;
16
+
17
+ /* Set a gradient: transparent black at the top to almost-transparent black at the bottom */
18
+ background-image: -webkit-gradient(linear, left top, left bottom, from(rgba(0, 0, 0, 0)), to(rgba(0, 0, 0, 0.15)));
19
+ background-image: -webkit-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15));
20
+ background-image: -moz-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15));
21
+ background-image: -ms-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15));
22
+ background-image: -o-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15));
23
+ background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15));
24
+
25
+ /* Add a drop shadow */
26
+ -webkit-box-shadow: 0 2px 3px 0 rgba(0, 0, 0, 0.5);
27
+ -moz-box-shadow: 0 2px 3px 0 rgba(0, 0, 0, 0.5);
28
+ box-shadow: 0 2px 3px 0 rgba(0, 0, 0, 0.5);
29
+
30
+ /* Set the font */
31
+ font: 700 13px "Helvetica Neue", Helvetica, Arial, sans-serif;
32
+
33
+ z-index: 9999;
34
+ pointer-events: auto;
35
+ }
36
+
37
+ .github-fork-ribbon a,
38
+ .github-fork-ribbon a:hover {
39
+ /* Set the text properties */
40
+ color: #fff;
41
+ text-decoration: none;
42
+ text-shadow: 0 -1px rgba(0, 0, 0, 0.5);
43
+ text-align: center;
44
+
45
+ /* Set the geometry. If you fiddle with these you'll also need
46
+ to tweak the top and right values in .github-fork-ribbon. */
47
+ width: 200px;
48
+ line-height: 20px;
49
+
50
+ /* Set the layout properties */
51
+ display: inline-block;
52
+ padding: 2px 0;
53
+
54
+ /* Add "stitching" effect */
55
+ border-width: 1px 0;
56
+ border-style: dotted;
57
+ border-color: #fff;
58
+ border-color: rgba(255, 255, 255, 0.7);
59
+ }
60
+
61
+ .github-fork-ribbon-wrapper {
62
+ width: 150px;
63
+ height: 150px;
64
+ position: absolute;
65
+ overflow: hidden;
66
+ top: 0;
67
+ z-index: 9999;
68
+ pointer-events: none;
69
+ }
70
+
71
+ .github-fork-ribbon-wrapper.fixed {
72
+ position: fixed;
73
+ }
74
+
75
+ .github-fork-ribbon-wrapper.left {
76
+ left: 0;
77
+ }
78
+
79
+ .github-fork-ribbon-wrapper.right {
80
+ right: 0;
81
+ }
82
+
83
+ .github-fork-ribbon-wrapper.left-bottom {
84
+ position: fixed;
85
+ top: inherit;
86
+ bottom: 0;
87
+ left: 0;
88
+ }
89
+
90
+ .github-fork-ribbon-wrapper.right-bottom {
91
+ position: fixed;
92
+ top: inherit;
93
+ bottom: 0;
94
+ right: 0;
95
+ }
96
+
97
+ .github-fork-ribbon-wrapper.right .github-fork-ribbon {
98
+ top: 42px;
99
+ right: -43px;
100
+
101
+ -webkit-transform: rotate(45deg);
102
+ -moz-transform: rotate(45deg);
103
+ -ms-transform: rotate(45deg);
104
+ -o-transform: rotate(45deg);
105
+ transform: rotate(45deg);
106
+ }
107
+
108
+ .github-fork-ribbon-wrapper.left .github-fork-ribbon {
109
+ top: 42px;
110
+ left: -43px;
111
+
112
+ -webkit-transform: rotate(-45deg);
113
+ -moz-transform: rotate(-45deg);
114
+ -ms-transform: rotate(-45deg);
115
+ -o-transform: rotate(-45deg);
116
+ transform: rotate(-45deg);
117
+ }
118
+
119
+
120
+ .github-fork-ribbon-wrapper.left-bottom .github-fork-ribbon {
121
+ top: 80px;
122
+ left: -43px;
123
+
124
+ -webkit-transform: rotate(45deg);
125
+ -moz-transform: rotate(45deg);
126
+ -ms-transform: rotate(45deg);
127
+ -o-transform: rotate(45deg);
128
+ transform: rotate(45deg);
129
+ }
130
+
131
+ .github-fork-ribbon-wrapper.right-bottom .github-fork-ribbon {
132
+ top: 80px;
133
+ right: -43px;
134
+
135
+ -webkit-transform: rotate(-45deg);
136
+ -moz-transform: rotate(-45deg);
137
+ -ms-transform: rotate(-45deg);
138
+ -o-transform: rotate(-45deg);
139
+ transform: rotate(-45deg);
140
+ }
@@ -0,0 +1,78 @@
1
+ /*!
2
+ * "Fork me on GitHub" CSS ribbon v0.1.1 | MIT License
3
+ * https://github.com/simonwhitaker/github-fork-ribbon-css
4
+ */
5
+
6
+ /* IE voodoo courtesy of http://stackoverflow.com/a/4617511/263871 and
7
+ * http://www.useragentman.com/IETransformsTranslator */
8
+
9
+ .github-fork-ribbon {
10
+ filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,StartColorStr='#000000', EndColorStr='#000000');
11
+ }
12
+
13
+ .github-fork-ribbon-wrapper.right .github-fork-ribbon {
14
+ /* IE positioning hack (couldn't find a transform-origin alternative for IE) */
15
+ top: -22px;
16
+ right: -62px;
17
+
18
+ /* IE8+ */
19
+ -ms-filter: "progid:DXImageTransform.Microsoft.Matrix(M11=0.7071067811865474, M12=-0.7071067811865477, M21=0.7071067811865477, M22=0.7071067811865474, SizingMethod='auto expand')";
20
+ /* IE6 and 7 */
21
+ filter: progid:DXImageTransform.Microsoft.Matrix(
22
+ M11=0.7071067811865474,
23
+ M12=-0.7071067811865477,
24
+ M21=0.7071067811865477,
25
+ M22=0.7071067811865474,
26
+ SizingMethod='auto expand'
27
+ );
28
+ }
29
+
30
+ .github-fork-ribbon-wrapper.left .github-fork-ribbon {
31
+ top: -22px;
32
+ left: -22px;
33
+
34
+ /* IE8+ */
35
+ -ms-filter: "progid:DXImageTransform.Microsoft.Matrix(M11=0.7071067811865483, M12=0.7071067811865467, M21=-0.7071067811865467, M22=0.7071067811865483, SizingMethod='auto expand')";
36
+ /* IE6 and 7 */
37
+ filter: progid:DXImageTransform.Microsoft.Matrix(
38
+ M11=0.7071067811865483,
39
+ M12=0.7071067811865467,
40
+ M21=-0.7071067811865467,
41
+ M22=0.7071067811865483,
42
+ SizingMethod='auto expand'
43
+ );
44
+ }
45
+
46
+ .github-fork-ribbon-wrapper.left-bottom .github-fork-ribbon {
47
+ /* IE positioning hack (couldn't find a transform-origin alternative for IE) */
48
+ top: 12px;
49
+ left: -22px;
50
+
51
+
52
+ /* IE8+ */
53
+ -ms-filter: "progid:DXImageTransform.Microsoft.Matrix(M11=0.7071067811865474, M12=-0.7071067811865477, M21=0.7071067811865477, M22=0.7071067811865474, SizingMethod='auto expand')";
54
+ /* IE6 and 7 */
55
+ /* filter: progid:DXImageTransform.Microsoft.Matrix(
56
+ M11=0.7071067811865474,
57
+ M12=-0.7071067811865477,
58
+ M21=0.7071067811865477,
59
+ M22=0.7071067811865474,
60
+ SizingMethod='auto expand'
61
+ );
62
+ */}
63
+
64
+ .github-fork-ribbon-wrapper.right-bottom .github-fork-ribbon {
65
+ top: 12px;
66
+ right: -62px;
67
+
68
+ /* IE8+ */
69
+ -ms-filter: "progid:DXImageTransform.Microsoft.Matrix(M11=0.7071067811865483, M12=0.7071067811865467, M21=-0.7071067811865467, M22=0.7071067811865483, SizingMethod='auto expand')";
70
+ /* IE6 and 7 */
71
+ filter: progid:DXImageTransform.Microsoft.Matrix(
72
+ M11=0.7071067811865483,
73
+ M12=0.7071067811865467,
74
+ M21=-0.7071067811865467,
75
+ M22=0.7071067811865483,
76
+ SizingMethod='auto expand'
77
+ );
78
+ }