hyper-d3 1.0.0.lap23

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 (204) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +1 -0
  3. data/Gemfile +4 -0
  4. data/Gemfile.lock +313 -0
  5. data/README.md +118 -0
  6. data/Rakefile +31 -0
  7. data/hyper-d3.gemspec +27 -0
  8. data/lib/d3.rb +68 -0
  9. data/lib/d3/arc.rb +29 -0
  10. data/lib/d3/area.rb +53 -0
  11. data/lib/d3/axis.rb +79 -0
  12. data/lib/d3/band_scale.rb +30 -0
  13. data/lib/d3/collections.rb +9 -0
  14. data/lib/d3/color.rb +76 -0
  15. data/lib/d3/color_schemes.rb +34 -0
  16. data/lib/d3/continuous_scale.rb +60 -0
  17. data/lib/d3/creator.rb +11 -0
  18. data/lib/d3/curve.rb +74 -0
  19. data/lib/d3/dsv.rb +103 -0
  20. data/lib/d3/ease.rb +319 -0
  21. data/lib/d3/format.rb +95 -0
  22. data/lib/d3/histograms.rb +46 -0
  23. data/lib/d3/interpolate.rb +125 -0
  24. data/lib/d3/line.rb +27 -0
  25. data/lib/d3/map.rb +48 -0
  26. data/lib/d3/misc.rb +15 -0
  27. data/lib/d3/native.rb +112 -0
  28. data/lib/d3/nest.rb +100 -0
  29. data/lib/d3/ordinal_scale.rb +39 -0
  30. data/lib/d3/path.rb +24 -0
  31. data/lib/d3/pie.rb +25 -0
  32. data/lib/d3/point_scale.rb +27 -0
  33. data/lib/d3/polygon.rb +18 -0
  34. data/lib/d3/quadtree.rb +89 -0
  35. data/lib/d3/quantile_scale.rb +19 -0
  36. data/lib/d3/quantize_scale.rb +20 -0
  37. data/lib/d3/radial_area.rb +55 -0
  38. data/lib/d3/radial_line.rb +27 -0
  39. data/lib/d3/random.rb +14 -0
  40. data/lib/d3/search.rb +30 -0
  41. data/lib/d3/selection.rb +151 -0
  42. data/lib/d3/sequential_scale.rb +31 -0
  43. data/lib/d3/set.rb +30 -0
  44. data/lib/d3/source/d3-drag.js +234 -0
  45. data/lib/d3/source/d3-scale-chromatic.js +484 -0
  46. data/lib/d3/source/d3.js +17178 -0
  47. data/lib/d3/stack.rb +13 -0
  48. data/lib/d3/statistics.rb +81 -0
  49. data/lib/d3/symbol.rb +70 -0
  50. data/lib/d3/threshold_scale.rb +22 -0
  51. data/lib/d3/time_format.rb +47 -0
  52. data/lib/d3/time_interval.rb +85 -0
  53. data/lib/d3/transformations.rb +16 -0
  54. data/lib/hyper-d3.rb +17 -0
  55. data/lib/hyperloop/d3/component.rb +12 -0
  56. data/lib/hyperloop/d3/mixin.rb +59 -0
  57. data/lib/hyperloop/d3/version.rb +5 -0
  58. data/spec/arc_spec.rb +80 -0
  59. data/spec/area_spec.rb +98 -0
  60. data/spec/axis_spec.rb +174 -0
  61. data/spec/band_scale_spec.rb +73 -0
  62. data/spec/color_spec.rb +74 -0
  63. data/spec/continuous_scale_spec.rb +217 -0
  64. data/spec/coverage_spec.rb +16 -0
  65. data/spec/creator_spec.rb +15 -0
  66. data/spec/curve_spec.rb +206 -0
  67. data/spec/dsv_spec.rb +194 -0
  68. data/spec/ease_spec.rb +370 -0
  69. data/spec/format_spec.rb +87 -0
  70. data/spec/histograms_spec.rb +61 -0
  71. data/spec/html/index.html.erb +11 -0
  72. data/spec/interpolate_spec.rb +152 -0
  73. data/spec/line_spec.rb +54 -0
  74. data/spec/map_spec.rb +80 -0
  75. data/spec/misc_spec.rb +21 -0
  76. data/spec/nest_spec.rb +89 -0
  77. data/spec/objects_spec.rb +22 -0
  78. data/spec/ordinal_scale_spec.rb +59 -0
  79. data/spec/path_spec.rb +65 -0
  80. data/spec/pie_spec.rb +114 -0
  81. data/spec/point_scale_spec.rb +58 -0
  82. data/spec/polygon_spec.rb +51 -0
  83. data/spec/quadtree_spec.rb +128 -0
  84. data/spec/quantile_scale_spec.rb +24 -0
  85. data/spec/quantize_scale_spec.rb +40 -0
  86. data/spec/radial_area_spec.rb +123 -0
  87. data/spec/radial_line_spec.rb +50 -0
  88. data/spec/random_spec.rb +34 -0
  89. data/spec/search_spec.rb +69 -0
  90. data/spec/selection_data_spec.rb +64 -0
  91. data/spec/selection_manipulation_spec.rb +166 -0
  92. data/spec/selection_spec.rb +187 -0
  93. data/spec/sequential_scale_spec.rb +90 -0
  94. data/spec/set_spec.rb +57 -0
  95. data/spec/spec_helper.rb +1 -0
  96. data/spec/stack_spec.rb +5 -0
  97. data/spec/statistics_spec.rb +65 -0
  98. data/spec/symbol_spec.rb +116 -0
  99. data/spec/test_app/.gitignore +23 -0
  100. data/spec/test_app/Gemfile +7 -0
  101. data/spec/test_app/Gemfile.lock +206 -0
  102. data/spec/test_app/README.md +9 -0
  103. data/spec/test_app/Rakefile +6 -0
  104. data/spec/test_app/app/assets/config/manifest.js +3 -0
  105. data/spec/test_app/app/assets/images/.keep +0 -0
  106. data/spec/test_app/app/assets/javascripts/application.js +13 -0
  107. data/spec/test_app/app/assets/javascripts/cable.js +13 -0
  108. data/spec/test_app/app/assets/javascripts/channels/.keep +0 -0
  109. data/spec/test_app/app/assets/javascripts/data/elections_2016.rb +10 -0
  110. data/spec/test_app/app/assets/javascripts/data/harry_potter.rb +19 -0
  111. data/spec/test_app/app/assets/javascripts/data/iphones.rb +29 -0
  112. data/spec/test_app/app/assets/javascripts/data/london_population.rb +26 -0
  113. data/spec/test_app/app/assets/javascripts/data/man_vs_horse.rb +55 -0
  114. data/spec/test_app/app/assets/javascripts/data/mtg_modern_colors.rb +96 -0
  115. data/spec/test_app/app/assets/javascripts/data/mtg_modern_creatures.rb +116 -0
  116. data/spec/test_app/app/assets/javascripts/data/olympics_2016_medals.rb +100 -0
  117. data/spec/test_app/app/assets/javascripts/data/paradox.rb +60 -0
  118. data/spec/test_app/app/assets/javascripts/data/polish_pms.rb +28 -0
  119. data/spec/test_app/app/assets/javascripts/data/star_trek_voyager.rb +183 -0
  120. data/spec/test_app/app/assets/javascripts/data/weather_in_london.rb +381 -0
  121. data/spec/test_app/app/assets/javascripts/elections_2016.rb +27 -0
  122. data/spec/test_app/app/assets/javascripts/harry_potter.rb +42 -0
  123. data/spec/test_app/app/assets/javascripts/iphones.rb +54 -0
  124. data/spec/test_app/app/assets/javascripts/london_population.rb +53 -0
  125. data/spec/test_app/app/assets/javascripts/london_population_area.rb +49 -0
  126. data/spec/test_app/app/assets/javascripts/man_vs_horse.rb +60 -0
  127. data/spec/test_app/app/assets/javascripts/mtg_modern_colors.rb +56 -0
  128. data/spec/test_app/app/assets/javascripts/mtg_modern_creatures.rb +70 -0
  129. data/spec/test_app/app/assets/javascripts/olympics_2016_medals.rb +62 -0
  130. data/spec/test_app/app/assets/javascripts/paradox.rb +64 -0
  131. data/spec/test_app/app/assets/javascripts/polish_pms.rb +60 -0
  132. data/spec/test_app/app/assets/javascripts/star_trek_voyager.rb +44 -0
  133. data/spec/test_app/app/assets/javascripts/weather_in_london.rb +69 -0
  134. data/spec/test_app/app/assets/stylesheets/application.css +15 -0
  135. data/spec/test_app/app/channels/application_cable/channel.rb +4 -0
  136. data/spec/test_app/app/channels/application_cable/connection.rb +4 -0
  137. data/spec/test_app/app/controllers/application_controller.rb +27 -0
  138. data/spec/test_app/app/controllers/concerns/.keep +0 -0
  139. data/spec/test_app/app/helpers/application_helper.rb +2 -0
  140. data/spec/test_app/app/jobs/application_job.rb +2 -0
  141. data/spec/test_app/app/mailers/application_mailer.rb +4 -0
  142. data/spec/test_app/app/models/application_record.rb +3 -0
  143. data/spec/test_app/app/models/concerns/.keep +0 -0
  144. data/spec/test_app/app/views/application/index.erb +18 -0
  145. data/spec/test_app/app/views/application/visualization.erb +28 -0
  146. data/spec/test_app/app/views/layouts/application.html.erb +13 -0
  147. data/spec/test_app/bin/bundle +3 -0
  148. data/spec/test_app/bin/rails +4 -0
  149. data/spec/test_app/bin/rake +4 -0
  150. data/spec/test_app/bin/setup +38 -0
  151. data/spec/test_app/bin/update +29 -0
  152. data/spec/test_app/bin/yarn +11 -0
  153. data/spec/test_app/config.ru +5 -0
  154. data/spec/test_app/config/application.rb +18 -0
  155. data/spec/test_app/config/boot.rb +3 -0
  156. data/spec/test_app/config/cable.yml +10 -0
  157. data/spec/test_app/config/database.yml +25 -0
  158. data/spec/test_app/config/environment.rb +5 -0
  159. data/spec/test_app/config/environments/development.rb +54 -0
  160. data/spec/test_app/config/environments/production.rb +91 -0
  161. data/spec/test_app/config/environments/test.rb +42 -0
  162. data/spec/test_app/config/initializers/application_controller_renderer.rb +8 -0
  163. data/spec/test_app/config/initializers/assets.rb +14 -0
  164. data/spec/test_app/config/initializers/backtrace_silencers.rb +7 -0
  165. data/spec/test_app/config/initializers/cookies_serializer.rb +5 -0
  166. data/spec/test_app/config/initializers/filter_parameter_logging.rb +4 -0
  167. data/spec/test_app/config/initializers/inflections.rb +16 -0
  168. data/spec/test_app/config/initializers/mime_types.rb +4 -0
  169. data/spec/test_app/config/initializers/wrap_parameters.rb +14 -0
  170. data/spec/test_app/config/locales/en.yml +33 -0
  171. data/spec/test_app/config/puma.rb +56 -0
  172. data/spec/test_app/config/routes.rb +5 -0
  173. data/spec/test_app/config/secrets.yml +32 -0
  174. data/spec/test_app/config/spring.rb +6 -0
  175. data/spec/test_app/db/seeds.rb +7 -0
  176. data/spec/test_app/lib/assets/.keep +0 -0
  177. data/spec/test_app/lib/tasks/.keep +0 -0
  178. data/spec/test_app/log/.keep +0 -0
  179. data/spec/test_app/package.json +5 -0
  180. data/spec/test_app/public/404.html +67 -0
  181. data/spec/test_app/public/422.html +67 -0
  182. data/spec/test_app/public/500.html +66 -0
  183. data/spec/test_app/public/apple-touch-icon-precomposed.png +0 -0
  184. data/spec/test_app/public/apple-touch-icon.png +0 -0
  185. data/spec/test_app/public/favicon.ico +0 -0
  186. data/spec/test_app/public/robots.txt +1 -0
  187. data/spec/test_app/test/application_system_test_case.rb +5 -0
  188. data/spec/test_app/test/controllers/.keep +0 -0
  189. data/spec/test_app/test/fixtures/.keep +0 -0
  190. data/spec/test_app/test/fixtures/files/.keep +0 -0
  191. data/spec/test_app/test/helpers/.keep +0 -0
  192. data/spec/test_app/test/integration/.keep +0 -0
  193. data/spec/test_app/test/mailers/.keep +0 -0
  194. data/spec/test_app/test/models/.keep +0 -0
  195. data/spec/test_app/test/system/.keep +0 -0
  196. data/spec/test_app/test/test_helper.rb +10 -0
  197. data/spec/test_app/tmp/.keep +0 -0
  198. data/spec/test_app/vendor/.keep +0 -0
  199. data/spec/threshold_scale_spec.rb +28 -0
  200. data/spec/time_format_spec.rb +100 -0
  201. data/spec/time_interval_spec.rb +314 -0
  202. data/spec/transformations_spec.rb +51 -0
  203. data/startrekvoyager.png +0 -0
  204. metadata +529 -0
@@ -0,0 +1,60 @@
1
+ module D3
2
+ class ContinuousScale
3
+ include D3::Native
4
+ def call(t)
5
+ @native.call(t)
6
+ end
7
+
8
+ aliases_native %i[invert ticks tickFormat]
9
+ attributes_d3 %i[domain range rangeRound clamp]
10
+ alias_native_chainable :nice
11
+ alias_native_new :copy
12
+
13
+ def interpolate(&block)
14
+ if block
15
+ @native.JS.interpolate(block)
16
+ self
17
+ else
18
+ @native.JS.interpolate
19
+ end
20
+ end
21
+ end
22
+
23
+ class PowScale < ContinuousScale
24
+ attribute_d3 :exponent
25
+ end
26
+
27
+ class LogScale < ContinuousScale
28
+ attribute_d3 :base
29
+ end
30
+
31
+ class << self
32
+ def scale_pow
33
+ D3::PowScale.new @d3.JS.scalePow
34
+ end
35
+
36
+ def scale_sqrt
37
+ D3::PowScale.new @d3.JS.scaleSqrt
38
+ end
39
+
40
+ def scale_linear
41
+ D3::ContinuousScale.new @d3.JS.scaleLinear
42
+ end
43
+
44
+ def scale_log
45
+ D3::LogScale.new @d3.JS.scaleLog
46
+ end
47
+
48
+ def scale_identity
49
+ D3::ContinuousScale.new @d3.JS.scaleIdentity
50
+ end
51
+
52
+ def scale_time
53
+ D3::ContinuousScale.new @d3.JS.scaleTime
54
+ end
55
+
56
+ def scale_utc
57
+ D3::ContinuousScale.new @d3.JS.scaleUtc
58
+ end
59
+ end
60
+ end
data/lib/d3/creator.rb ADDED
@@ -0,0 +1,11 @@
1
+ module D3
2
+ class Creator
3
+ include D3::Native
4
+ end
5
+
6
+ class << self
7
+ def creator(name)
8
+ D3::Creator.new @d3.JS.creator(name)
9
+ end
10
+ end
11
+ end
data/lib/d3/curve.rb ADDED
@@ -0,0 +1,74 @@
1
+ module D3
2
+ class Curve
3
+ include D3::Native
4
+ end
5
+
6
+ class CurveBundle < Curve
7
+ alias_native_new :beta
8
+ end
9
+
10
+ class CurveCardinal < Curve
11
+ alias_native_new :tension
12
+ end
13
+
14
+ class CurveCatmullRom < Curve
15
+ alias_native_new :alpha
16
+ end
17
+
18
+ class << self
19
+ def curve_basis
20
+ D3::Curve.new `window.d3.curveBasis`
21
+ end
22
+ def curve_basis_closed
23
+ D3::Curve.new `window.d3.curveBasisClosed`
24
+ end
25
+ def curve_basis_open
26
+ D3::Curve.new `window.d3.curveBasisOpen`
27
+ end
28
+ def curve_bundle
29
+ D3::CurveBundle.new `window.d3.curveBundle`
30
+ end
31
+ def curve_cardinal
32
+ D3::CurveCardinal.new `window.d3.curveCardinal`
33
+ end
34
+ def curve_cardinal_closed
35
+ D3::CurveCardinal.new `window.d3.curveCardinalClosed`
36
+ end
37
+ def curve_cardinal_open
38
+ D3::CurveCardinal.new `window.d3.curveCardinalOpen`
39
+ end
40
+ def curve_catmull_rom
41
+ D3::CurveCatmullRom.new `window.d3.curveCatmullRom`
42
+ end
43
+ def curve_catmull_rom_closed
44
+ D3::CurveCatmullRom.new `window.d3.curveCatmullRomClosed`
45
+ end
46
+ def curve_catmull_rom_open
47
+ D3::CurveCatmullRom.new `window.d3.curveCatmullRomOpen`
48
+ end
49
+ def curve_linear
50
+ D3::Curve.new `window.d3.curveLinear`
51
+ end
52
+ def curve_linear_closed
53
+ D3::Curve.new `window.d3.curveLinearClosed`
54
+ end
55
+ def curve_monotone_x
56
+ D3::Curve.new `window.d3.curveMonotoneX`
57
+ end
58
+ def curve_monotone_y
59
+ D3::Curve.new `window.d3.curveMonotoneY`
60
+ end
61
+ def curve_natural
62
+ D3::Curve.new `window.d3.curveNatural`
63
+ end
64
+ def curve_step
65
+ D3::Curve.new `window.d3.curveStep`
66
+ end
67
+ def curve_step_after
68
+ D3::Curve.new `window.d3.curveStepAfter`
69
+ end
70
+ def curve_step_before
71
+ D3::Curve.new `window.d3.curveStepBefore`
72
+ end
73
+ end
74
+ end
data/lib/d3/dsv.rb ADDED
@@ -0,0 +1,103 @@
1
+ module D3
2
+ class DsvFormat
3
+ include D3::Native
4
+
5
+ def parse_rows(string, row=`undefined`, &block)
6
+ row = block if block_given?
7
+ if `row !== undefined`
8
+ @native.JS.parseRows(string, proc{|d|
9
+ result = row.call(d)
10
+ result == nil ? `null` : result
11
+ })
12
+ else
13
+ @native.JS.parseRows(string)
14
+ end
15
+ end
16
+
17
+ def parse(string, row=`undefined`, &block)
18
+ row = block if block_given?
19
+ if `row !== undefined`
20
+ @native.JS.parse(string, proc{|e|
21
+ result = row.call(`Opal.hash(e)`)
22
+ result == nil ? `null` : result
23
+ })
24
+ else
25
+ @native.JS.parse(string).map{|e| `Opal.hash(e)` }
26
+ end
27
+ end
28
+
29
+ alias_native_new :format_rows, :formatRows
30
+
31
+ alias_native_new :format
32
+ end
33
+
34
+ class << self
35
+ def dsv_format(separator)
36
+ D3::DsvFormat.new @d3.JS.dsvFormat(separator)
37
+ end
38
+
39
+ def csv_parse_rows(string, row=`undefined`, &block)
40
+ row = block if block_given?
41
+ if `row !== undefined`
42
+ @d3.JS.csvParseRows(string, proc{|d|
43
+ result = row.call(d)
44
+ result == nil ? `null` : result
45
+ })
46
+ else
47
+ @d3.JS.csvParseRows(string)
48
+ end
49
+ end
50
+
51
+ def tsv_parse_rows(string, row=`undefined`, &block)
52
+ row = block if block_given?
53
+ if `row !== undefined`
54
+ @d3.JS.tsvParseRows(string, proc{|d|
55
+ result = row.call(d)
56
+ result == nil ? `null` : result
57
+ })
58
+ else
59
+ @d3.JS.tsvParseRows(string)
60
+ end
61
+ end
62
+
63
+ def csv_format_rows(rows)
64
+ @d3.JS.csvFormatRows(rows)
65
+ end
66
+
67
+ def tsv_format_rows(rows)
68
+ @d3.JS.tsvFormatRows(rows)
69
+ end
70
+
71
+ def csv_parse(string, row=`undefined`, &block)
72
+ row = block if block_given?
73
+ if `row !== undefined`
74
+ @d3.JS.csvParse(string, proc{|e|
75
+ result = row.call(`Opal.hash(e)`)
76
+ result == nil ? `null` : result
77
+ })
78
+ else
79
+ @d3.JS.csvParse(string).map{|e| `Opal.hash(e)` }
80
+ end
81
+ end
82
+
83
+ def tsv_parse(string, row=`undefined`, &block)
84
+ row = block if block_given?
85
+ if `row !== undefined`
86
+ @d3.JS.tsvParse(string, proc{|e|
87
+ result = row.call(`Opal.hash(e)`)
88
+ result == nil ? `null` : result
89
+ })
90
+ else
91
+ @d3.JS.tsvParse(string).map{|e| `Opal.hash(e)` }
92
+ end
93
+ end
94
+
95
+ def csv_format(rows, columns=`undefined`)
96
+ @d3.JS.csvFormat(rows.to_n, columns)
97
+ end
98
+
99
+ def tsv_format(rows, columns=`undefined`)
100
+ @d3.JS.tsvFormat(rows.to_n, columns)
101
+ end
102
+ end
103
+ end
data/lib/d3/ease.rb ADDED
@@ -0,0 +1,319 @@
1
+ module D3
2
+ class EasePoly
3
+ include D3::Native
4
+ alias_native_new :exponent
5
+
6
+ def call(t)
7
+ @native.call(t)
8
+ end
9
+ end
10
+
11
+ class EaseBack
12
+ include D3::Native
13
+ alias_native_new :overshoot
14
+
15
+ def call(t)
16
+ @native.call(t)
17
+ end
18
+ end
19
+
20
+ class EaseElastic
21
+ include D3::Native
22
+ alias_native_new :amplitude
23
+ alias_native_new :period
24
+
25
+ def call(t)
26
+ @native.call(t)
27
+ end
28
+ end
29
+
30
+ class <<self
31
+ def ease_linear(t=nil)
32
+ if t
33
+ @d3.JS.easeLinear(t)
34
+ else
35
+ `#@d3.easeLinear`
36
+ end
37
+ end
38
+
39
+ def ease_quad(t=nil)
40
+ if t
41
+ @d3.JS.easeQuad(t)
42
+ else
43
+ `#@d3.easeQuad`
44
+ end
45
+ end
46
+
47
+ def ease_quad_in(t=nil)
48
+ if t
49
+ @d3.JS.easeQuadIn(t)
50
+ else
51
+ `#@d3.easeQuadIn`
52
+ end
53
+ end
54
+
55
+ def ease_quad_out(t=nil)
56
+ if t
57
+ @d3.JS.easeQuadOut(t)
58
+ else
59
+ `#@d3.easeQuadOut`
60
+ end
61
+ end
62
+
63
+ def ease_quad_in_out(t=nil)
64
+ if t
65
+ @d3.JS.easeQuadInOut(t)
66
+ else
67
+ `#@d3.easeQuadInOut`
68
+ end
69
+ end
70
+
71
+ def ease_cubic(t=nil)
72
+ if t
73
+ @d3.JS.easeCubic(t)
74
+ else
75
+ `#@d3.easeCubic`
76
+ end
77
+ end
78
+
79
+ def ease_cubic_in(t=nil)
80
+ if t
81
+ @d3.JS.easeCubicIn(t)
82
+ else
83
+ `#@d3.easeCubicIn`
84
+ end
85
+ end
86
+
87
+ def ease_cubic_out(t=nil)
88
+ if t
89
+ @d3.JS.easeCubicOut(t)
90
+ else
91
+ `#@d3.easeCubicOut`
92
+ end
93
+ end
94
+
95
+ def ease_cubic_in_out(t=nil)
96
+ if t
97
+ @d3.JS.easeCubicInOut(t)
98
+ else
99
+ `#@d3.easeCubicInOut`
100
+ end
101
+ end
102
+
103
+ def ease_sin(t=nil)
104
+ if t
105
+ @d3.JS.easeSin(t)
106
+ else
107
+ `#@d3.easeSin`
108
+ end
109
+ end
110
+
111
+ def ease_sin_in(t=nil)
112
+ if t
113
+ @d3.JS.easeSinIn(t)
114
+ else
115
+ `#@d3.easeSinIn`
116
+ end
117
+ end
118
+
119
+ def ease_sin_out(t=nil)
120
+ if t
121
+ @d3.JS.easeSinOut(t)
122
+ else
123
+ `#@d3.easeSinOut`
124
+ end
125
+ end
126
+
127
+ def ease_sin_in_out(t=nil)
128
+ if t
129
+ @d3.JS.easeSinInOut(t)
130
+ else
131
+ `#@d3.easeSinInOut`
132
+ end
133
+ end
134
+
135
+ def ease_exp(t=nil)
136
+ if t
137
+ @d3.JS.easeExp(t)
138
+ else
139
+ `#@d3.easeExp`
140
+ end
141
+ end
142
+
143
+ def ease_exp_in(t=nil)
144
+ if t
145
+ @d3.JS.easeExpIn(t)
146
+ else
147
+ `#@d3.easeExpIn`
148
+ end
149
+ end
150
+
151
+ def ease_exp_out(t=nil)
152
+ if t
153
+ @d3.JS.easeExpOut(t)
154
+ else
155
+ `#@d3.easeExpOut`
156
+ end
157
+ end
158
+
159
+ def ease_exp_in_out(t=nil)
160
+ if t
161
+ @d3.JS.easeExpInOut(t)
162
+ else
163
+ `#@d3.easeExpInOut`
164
+ end
165
+ end
166
+
167
+ def ease_circle(t=nil)
168
+ if t
169
+ @d3.JS.easeCircle(t)
170
+ else
171
+ `#@d3.easeCircle`
172
+ end
173
+ end
174
+
175
+ def ease_circle_in(t=nil)
176
+ if t
177
+ @d3.JS.easeCircleIn(t)
178
+ else
179
+ `#@d3.easeCircleIn`
180
+ end
181
+ end
182
+
183
+ def ease_circle_out(t=nil)
184
+ if t
185
+ @d3.JS.easeCircleOut(t)
186
+ else
187
+ `#@d3.easeCircleOut`
188
+ end
189
+ end
190
+
191
+ def ease_circle_in_out(t=nil)
192
+ if t
193
+ @d3.JS.easeCircleInOut(t)
194
+ else
195
+ `#@d3.easeCircleInOut`
196
+ end
197
+ end
198
+
199
+ def ease_bounce(t=nil)
200
+ if t
201
+ @d3.JS.easeBounce(t)
202
+ else
203
+ `#@d3.easeBounce`
204
+ end
205
+ end
206
+
207
+ def ease_bounce_in(t=nil)
208
+ if t
209
+ @d3.JS.easeBounceIn(t)
210
+ else
211
+ `#@d3.easeBounceIn`
212
+ end
213
+ end
214
+
215
+ def ease_bounce_out(t=nil)
216
+ if t
217
+ @d3.JS.easeBounceOut(t)
218
+ else
219
+ `#@d3.easeBounceOut`
220
+ end
221
+ end
222
+
223
+ def ease_bounce_in_out(t=nil)
224
+ if t
225
+ @d3.JS.easeBounceInOut(t)
226
+ else
227
+ `#@d3.easeBounceInOut`
228
+ end
229
+ end
230
+
231
+ def ease_poly_in(t=nil)
232
+ if t
233
+ @d3.JS.easePolyIn(t)
234
+ else
235
+ D3::EasePoly.new `#@d3.easePolyIn`
236
+ end
237
+ end
238
+
239
+ def ease_poly_out(t=nil)
240
+ if t
241
+ @d3.JS.easePolyOut(t)
242
+ else
243
+ D3::EasePoly.new `#@d3.easePolyOut`
244
+ end
245
+ end
246
+
247
+ def ease_poly_in_out(t=nil)
248
+ if t
249
+ @d3.JS.easePolyInOut(t)
250
+ else
251
+ D3::EasePoly.new `#@d3.easePolyInOut`
252
+ end
253
+ end
254
+
255
+ def ease_back(t=nil)
256
+ if t
257
+ @d3.JS.easeBack(t)
258
+ else
259
+ D3::EaseBack.new `#@d3.easeBack`
260
+ end
261
+ end
262
+
263
+ def ease_back_in(t=nil)
264
+ if t
265
+ @d3.JS.easeBackIn(t)
266
+ else
267
+ D3::EaseBack.new `#@d3.easeBackIn`
268
+ end
269
+ end
270
+
271
+ def ease_back_out(t=nil)
272
+ if t
273
+ @d3.JS.easeBackOut(t)
274
+ else
275
+ D3::EaseBack.new `#@d3.easeBackOut`
276
+ end
277
+ end
278
+
279
+ def ease_back_in_out(t=nil)
280
+ if t
281
+ @d3.JS.easeBackInOut(t)
282
+ else
283
+ D3::EaseBack.new `#@d3.easeBackInOut`
284
+ end
285
+ end
286
+
287
+ def ease_elastic(t=nil)
288
+ if t
289
+ @d3.JS.easeElastic(t)
290
+ else
291
+ D3::EaseElastic.new `#@d3.easeElastic`
292
+ end
293
+ end
294
+
295
+ def ease_elastic_in(t=nil)
296
+ if t
297
+ @d3.JS.easeElasticIn(t)
298
+ else
299
+ D3::EaseElastic.new `#@d3.easeElasticIn`
300
+ end
301
+ end
302
+
303
+ def ease_elastic_out(t=nil)
304
+ if t
305
+ @d3.JS.easeElasticOut(t)
306
+ else
307
+ D3::EaseElastic.new `#@d3.easeElasticOut`
308
+ end
309
+ end
310
+
311
+ def ease_elastic_in_out(t=nil)
312
+ if t
313
+ @d3.JS.easeElasticInOut(t)
314
+ else
315
+ D3::EaseElastic.new `#@d3.easeElasticInOut`
316
+ end
317
+ end
318
+ end
319
+ end