stripchart 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE +21 -0
- data/README.md +21 -0
- data/exe/stripchart +5 -0
- data/lib/stripchart/app.rb +71 -0
- data/lib/stripchart/public/app.css +37 -0
- data/lib/stripchart/public/app.js +167 -0
- data/lib/stripchart/public/components/d3/LICENSE +26 -0
- data/lib/stripchart/public/components/d3/Makefile +45 -0
- data/lib/stripchart/public/components/d3/README.md +7 -0
- data/lib/stripchart/public/components/d3/bower.json +25 -0
- data/lib/stripchart/public/components/d3/component.json +30 -0
- data/lib/stripchart/public/components/d3/d3.js +8798 -0
- data/lib/stripchart/public/components/d3/d3.min.js +5 -0
- data/lib/stripchart/public/components/d3/index-browserify.js +3 -0
- data/lib/stripchart/public/components/d3/index.js +15 -0
- data/lib/stripchart/public/components/d3/lib/colorbrewer/LICENSE +38 -0
- data/lib/stripchart/public/components/d3/lib/colorbrewer/colorbrewer.css +1690 -0
- data/lib/stripchart/public/components/d3/lib/colorbrewer/colorbrewer.js +302 -0
- data/lib/stripchart/public/components/d3/lib/geographiclib/LICENSE +23 -0
- data/lib/stripchart/public/components/d3/lib/jit/LICENSE +27 -0
- data/lib/stripchart/public/components/d3/lib/penner/LICENSE +31 -0
- data/lib/stripchart/public/components/d3/lib/polymaps/LICENSE +28 -0
- data/lib/stripchart/public/components/d3/lib/protovis/LICENSE +27 -0
- data/lib/stripchart/public/components/d3/lib/science/LICENSE +26 -0
- data/lib/stripchart/public/components/d3/lib/science/science.js +225 -0
- data/lib/stripchart/public/components/d3/lib/science/science.lin.js +27 -0
- data/lib/stripchart/public/components/d3/lib/science/science.lin.min.js +1 -0
- data/lib/stripchart/public/components/d3/lib/science/science.min.js +1 -0
- data/lib/stripchart/public/components/d3/lib/science/science.stats.js +720 -0
- data/lib/stripchart/public/components/d3/lib/science/science.stats.min.js +1 -0
- data/lib/stripchart/public/components/d3/package.json +53 -0
- data/lib/stripchart/public/components/d3/src/arrays/ascending.js +3 -0
- data/lib/stripchart/public/components/d3/src/arrays/bisect.js +28 -0
- data/lib/stripchart/public/components/d3/src/arrays/descending.js +3 -0
- data/lib/stripchart/public/components/d3/src/arrays/entries.js +5 -0
- data/lib/stripchart/public/components/d3/src/arrays/extent.js +21 -0
- data/lib/stripchart/public/components/d3/src/arrays/index.js +22 -0
- data/lib/stripchart/public/components/d3/src/arrays/keys.js +5 -0
- data/lib/stripchart/public/components/d3/src/arrays/map.js +50 -0
- data/lib/stripchart/public/components/d3/src/arrays/max.js +14 -0
- data/lib/stripchart/public/components/d3/src/arrays/mean.js +15 -0
- data/lib/stripchart/public/components/d3/src/arrays/median.js +9 -0
- data/lib/stripchart/public/components/d3/src/arrays/merge.js +3 -0
- data/lib/stripchart/public/components/d3/src/arrays/min.js +14 -0
- data/lib/stripchart/public/components/d3/src/arrays/nest.js +97 -0
- data/lib/stripchart/public/components/d3/src/arrays/permute.js +7 -0
- data/lib/stripchart/public/components/d3/src/arrays/quantile.js +8 -0
- data/lib/stripchart/public/components/d3/src/arrays/range.js +24 -0
- data/lib/stripchart/public/components/d3/src/arrays/set.js +38 -0
- data/lib/stripchart/public/components/d3/src/arrays/shuffle.js +8 -0
- data/lib/stripchart/public/components/d3/src/arrays/sum.js +14 -0
- data/lib/stripchart/public/components/d3/src/arrays/transpose.js +5 -0
- data/lib/stripchart/public/components/d3/src/arrays/values.js +5 -0
- data/lib/stripchart/public/components/d3/src/arrays/zip.js +15 -0
- data/lib/stripchart/public/components/d3/src/behavior/behavior.js +1 -0
- data/lib/stripchart/public/components/d3/src/behavior/drag.js +79 -0
- data/lib/stripchart/public/components/d3/src/behavior/index.js +3 -0
- data/lib/stripchart/public/components/d3/src/behavior/zoom.js +209 -0
- data/lib/stripchart/public/components/d3/src/color/color.js +5 -0
- data/lib/stripchart/public/components/d3/src/color/hcl.js +42 -0
- data/lib/stripchart/public/components/d3/src/color/hsl.js +64 -0
- data/lib/stripchart/public/components/d3/src/color/index.js +6 -0
- data/lib/stripchart/public/components/d3/src/color/lab.js +68 -0
- data/lib/stripchart/public/components/d3/src/color/rgb.js +307 -0
- data/lib/stripchart/public/components/d3/src/color/xyz.js +7 -0
- data/lib/stripchart/public/components/d3/src/compat/date.js +3 -0
- data/lib/stripchart/public/components/d3/src/compat/index.js +2 -0
- data/lib/stripchart/public/components/d3/src/compat/style.js +20 -0
- data/lib/stripchart/public/components/d3/src/core/array.js +19 -0
- data/lib/stripchart/public/components/d3/src/core/class.js +12 -0
- data/lib/stripchart/public/components/d3/src/core/document.js +3 -0
- data/lib/stripchart/public/components/d3/src/core/functor.js +5 -0
- data/lib/stripchart/public/components/d3/src/core/identity.js +3 -0
- data/lib/stripchart/public/components/d3/src/core/index.js +3 -0
- data/lib/stripchart/public/components/d3/src/core/noop.js +1 -0
- data/lib/stripchart/public/components/d3/src/core/ns.js +22 -0
- data/lib/stripchart/public/components/d3/src/core/rebind.js +16 -0
- data/lib/stripchart/public/components/d3/src/core/source.js +3 -0
- data/lib/stripchart/public/components/d3/src/core/subclass.js +11 -0
- data/lib/stripchart/public/components/d3/src/core/target.js +3 -0
- data/lib/stripchart/public/components/d3/src/core/true.js +3 -0
- data/lib/stripchart/public/components/d3/src/core/vendor.js +12 -0
- data/lib/stripchart/public/components/d3/src/d3.js +23 -0
- data/lib/stripchart/public/components/d3/src/dsv/csv.js +3 -0
- data/lib/stripchart/public/components/d3/src/dsv/dsv.js +136 -0
- data/lib/stripchart/public/components/d3/src/dsv/index.js +3 -0
- data/lib/stripchart/public/components/d3/src/dsv/tsv.js +3 -0
- data/lib/stripchart/public/components/d3/src/end.js +2 -0
- data/lib/stripchart/public/components/d3/src/event/dispatch.js +69 -0
- data/lib/stripchart/public/components/d3/src/event/drag.js +27 -0
- data/lib/stripchart/public/components/d3/src/event/event.js +50 -0
- data/lib/stripchart/public/components/d3/src/event/index.js +5 -0
- data/lib/stripchart/public/components/d3/src/event/mouse.js +39 -0
- data/lib/stripchart/public/components/d3/src/event/timer.js +82 -0
- data/lib/stripchart/public/components/d3/src/event/touches.js +12 -0
- data/lib/stripchart/public/components/d3/src/format/collapse.js +3 -0
- data/lib/stripchart/public/components/d3/src/format/format-locale.js +4 -0
- data/lib/stripchart/public/components/d3/src/format/format-localized.js +5 -0
- data/lib/stripchart/public/components/d3/src/format/format.js +144 -0
- data/lib/stripchart/public/components/d3/src/format/formatPrefix.js +22 -0
- data/lib/stripchart/public/components/d3/src/format/index.js +4 -0
- data/lib/stripchart/public/components/d3/src/format/requote.js +5 -0
- data/lib/stripchart/public/components/d3/src/format/round.js +5 -0
- data/lib/stripchart/public/components/d3/src/geo/albers-usa.js +129 -0
- data/lib/stripchart/public/components/d3/src/geo/albers.js +11 -0
- data/lib/stripchart/public/components/d3/src/geo/area.js +67 -0
- data/lib/stripchart/public/components/d3/src/geo/azimuthal-equal-area.js +12 -0
- data/lib/stripchart/public/components/d3/src/geo/azimuthal-equidistant.js +13 -0
- data/lib/stripchart/public/components/d3/src/geo/azimuthal.js +25 -0
- data/lib/stripchart/public/components/d3/src/geo/bounds.js +169 -0
- data/lib/stripchart/public/components/d3/src/geo/cartesian.js +47 -0
- data/lib/stripchart/public/components/d3/src/geo/centroid.js +149 -0
- data/lib/stripchart/public/components/d3/src/geo/circle.js +81 -0
- data/lib/stripchart/public/components/d3/src/geo/clip-antimeridian.js +101 -0
- data/lib/stripchart/public/components/d3/src/geo/clip-circle.js +182 -0
- data/lib/stripchart/public/components/d3/src/geo/clip-polygon.js +94 -0
- data/lib/stripchart/public/components/d3/src/geo/clip-view.js +212 -0
- data/lib/stripchart/public/components/d3/src/geo/clip.js +135 -0
- data/lib/stripchart/public/components/d3/src/geo/compose.js +12 -0
- data/lib/stripchart/public/components/d3/src/geo/conic-conformal.js +36 -0
- data/lib/stripchart/public/components/d3/src/geo/conic-equal-area.js +33 -0
- data/lib/stripchart/public/components/d3/src/geo/conic-equidistant.js +35 -0
- data/lib/stripchart/public/components/d3/src/geo/conic.js +16 -0
- data/lib/stripchart/public/components/d3/src/geo/distance.js +13 -0
- data/lib/stripchart/public/components/d3/src/geo/equirectangular.js +10 -0
- data/lib/stripchart/public/components/d3/src/geo/geo.js +1 -0
- data/lib/stripchart/public/components/d3/src/geo/gnomonic.js +12 -0
- data/lib/stripchart/public/components/d3/src/geo/graticule.js +102 -0
- data/lib/stripchart/public/components/d3/src/geo/greatArc.js +42 -0
- data/lib/stripchart/public/components/d3/src/geo/index.js +32 -0
- data/lib/stripchart/public/components/d3/src/geo/interpolate.js +38 -0
- data/lib/stripchart/public/components/d3/src/geo/length.js +43 -0
- data/lib/stripchart/public/components/d3/src/geo/mercator.js +48 -0
- data/lib/stripchart/public/components/d3/src/geo/orthographic.js +12 -0
- data/lib/stripchart/public/components/d3/src/geo/path-area.js +40 -0
- data/lib/stripchart/public/components/d3/src/geo/path-bounds.js +21 -0
- data/lib/stripchart/public/components/d3/src/geo/path-buffer.js +59 -0
- data/lib/stripchart/public/components/d3/src/geo/path-centroid.js +78 -0
- data/lib/stripchart/public/components/d3/src/geo/path-context.js +49 -0
- data/lib/stripchart/public/components/d3/src/geo/path.js +97 -0
- data/lib/stripchart/public/components/d3/src/geo/point-in-polygon.js +71 -0
- data/lib/stripchart/public/components/d3/src/geo/projection.js +132 -0
- data/lib/stripchart/public/components/d3/src/geo/resample.js +98 -0
- data/lib/stripchart/public/components/d3/src/geo/rotation.js +72 -0
- data/lib/stripchart/public/components/d3/src/geo/spherical.js +12 -0
- data/lib/stripchart/public/components/d3/src/geo/stereographic.js +12 -0
- data/lib/stripchart/public/components/d3/src/geo/stream.js +71 -0
- data/lib/stripchart/public/components/d3/src/geo/transverse-mercator.js +23 -0
- data/lib/stripchart/public/components/d3/src/geom/delaunay.js +31 -0
- data/lib/stripchart/public/components/d3/src/geom/geom.js +1 -0
- data/lib/stripchart/public/components/d3/src/geom/hull.js +120 -0
- data/lib/stripchart/public/components/d3/src/geom/index.js +6 -0
- data/lib/stripchart/public/components/d3/src/geom/polygon.js +105 -0
- data/lib/stripchart/public/components/d3/src/geom/quadtree.js +190 -0
- data/lib/stripchart/public/components/d3/src/geom/voronoi.js +545 -0
- data/lib/stripchart/public/components/d3/src/interpolate/array.js +19 -0
- data/lib/stripchart/public/components/d3/src/interpolate/ease.js +110 -0
- data/lib/stripchart/public/components/d3/src/interpolate/hcl.js +23 -0
- data/lib/stripchart/public/components/d3/src/interpolate/hsl.js +23 -0
- data/lib/stripchart/public/components/d3/src/interpolate/index.js +13 -0
- data/lib/stripchart/public/components/d3/src/interpolate/interpolate.js +25 -0
- data/lib/stripchart/public/components/d3/src/interpolate/lab.js +20 -0
- data/lib/stripchart/public/components/d3/src/interpolate/number.js +6 -0
- data/lib/stripchart/public/components/d3/src/interpolate/object.js +25 -0
- data/lib/stripchart/public/components/d3/src/interpolate/rgb.js +20 -0
- data/lib/stripchart/public/components/d3/src/interpolate/round.js +6 -0
- data/lib/stripchart/public/components/d3/src/interpolate/string.js +88 -0
- data/lib/stripchart/public/components/d3/src/interpolate/transform.js +56 -0
- data/lib/stripchart/public/components/d3/src/interpolate/uninterpolate.js +9 -0
- data/lib/stripchart/public/components/d3/src/layout/bundle.js +59 -0
- data/lib/stripchart/public/components/d3/src/layout/chord.js +157 -0
- data/lib/stripchart/public/components/d3/src/layout/cluster.js +92 -0
- data/lib/stripchart/public/components/d3/src/layout/force.js +359 -0
- data/lib/stripchart/public/components/d3/src/layout/hierarchy.js +116 -0
- data/lib/stripchart/public/components/d3/src/layout/histogram.js +110 -0
- data/lib/stripchart/public/components/d3/src/layout/index.js +13 -0
- data/lib/stripchart/public/components/d3/src/layout/layout.js +1 -0
- data/lib/stripchart/public/components/d3/src/layout/pack.js +212 -0
- data/lib/stripchart/public/components/d3/src/layout/partition.js +51 -0
- data/lib/stripchart/public/components/d3/src/layout/pie.js +99 -0
- data/lib/stripchart/public/components/d3/src/layout/stack.js +245 -0
- data/lib/stripchart/public/components/d3/src/layout/tree.js +251 -0
- data/lib/stripchart/public/components/d3/src/layout/treemap.js +230 -0
- data/lib/stripchart/public/components/d3/src/math/adder.js +34 -0
- data/lib/stripchart/public/components/d3/src/math/index.js +2 -0
- data/lib/stripchart/public/components/d3/src/math/number.js +3 -0
- data/lib/stripchart/public/components/d3/src/math/random.js +28 -0
- data/lib/stripchart/public/components/d3/src/math/transform.js +64 -0
- data/lib/stripchart/public/components/d3/src/math/trigonometry.js +29 -0
- data/lib/stripchart/public/components/d3/src/scale/bilinear.js +7 -0
- data/lib/stripchart/public/components/d3/src/scale/category.js +57 -0
- data/lib/stripchart/public/components/d3/src/scale/identity.js +33 -0
- data/lib/stripchart/public/components/d3/src/scale/index.js +11 -0
- data/lib/stripchart/public/components/d3/src/scale/linear.js +128 -0
- data/lib/stripchart/public/components/d3/src/scale/log.js +92 -0
- data/lib/stripchart/public/components/d3/src/scale/nice.js +28 -0
- data/lib/stripchart/public/components/d3/src/scale/ordinal.js +92 -0
- data/lib/stripchart/public/components/d3/src/scale/polylinear.js +24 -0
- data/lib/stripchart/public/components/d3/src/scale/pow.js +58 -0
- data/lib/stripchart/public/components/d3/src/scale/quantile.js +54 -0
- data/lib/stripchart/public/components/d3/src/scale/quantize.js +44 -0
- data/lib/stripchart/public/components/d3/src/scale/scale.js +10 -0
- data/lib/stripchart/public/components/d3/src/scale/sqrt.js +6 -0
- data/lib/stripchart/public/components/d3/src/scale/threshold.js +36 -0
- data/lib/stripchart/public/components/d3/src/selection/append.js +16 -0
- data/lib/stripchart/public/components/d3/src/selection/attr.js +62 -0
- data/lib/stripchart/public/components/d3/src/selection/call.js +8 -0
- data/lib/stripchart/public/components/d3/src/selection/classed.js +72 -0
- data/lib/stripchart/public/components/d3/src/selection/data.js +118 -0
- data/lib/stripchart/public/components/d3/src/selection/datum.js +7 -0
- data/lib/stripchart/public/components/d3/src/selection/each.js +16 -0
- data/lib/stripchart/public/components/d3/src/selection/empty.js +5 -0
- data/lib/stripchart/public/components/d3/src/selection/enter-insert.js +20 -0
- data/lib/stripchart/public/components/d3/src/selection/enter-select.js +27 -0
- data/lib/stripchart/public/components/d3/src/selection/enter.js +21 -0
- data/lib/stripchart/public/components/d3/src/selection/filter.js +28 -0
- data/lib/stripchart/public/components/d3/src/selection/html.js +10 -0
- data/lib/stripchart/public/components/d3/src/selection/index.js +1 -0
- data/lib/stripchart/public/components/d3/src/selection/insert.js +9 -0
- data/lib/stripchart/public/components/d3/src/selection/node.js +11 -0
- data/lib/stripchart/public/components/d3/src/selection/on.js +104 -0
- data/lib/stripchart/public/components/d3/src/selection/order.js +13 -0
- data/lib/stripchart/public/components/d3/src/selection/property.js +43 -0
- data/lib/stripchart/public/components/d3/src/selection/remove.js +11 -0
- data/lib/stripchart/public/components/d3/src/selection/select.js +32 -0
- data/lib/stripchart/public/components/d3/src/selection/selectAll.js +27 -0
- data/lib/stripchart/public/components/d3/src/selection/selection.js +67 -0
- data/lib/stripchart/public/components/d3/src/selection/size.js +7 -0
- data/lib/stripchart/public/components/d3/src/selection/sort.js +15 -0
- data/lib/stripchart/public/components/d3/src/selection/style.js +56 -0
- data/lib/stripchart/public/components/d3/src/selection/text.js +10 -0
- data/lib/stripchart/public/components/d3/src/selection/transition.js +19 -0
- data/lib/stripchart/public/components/d3/src/start.js +2 -0
- data/lib/stripchart/public/components/d3/src/svg/arc.js +99 -0
- data/lib/stripchart/public/components/d3/src/svg/area-radial.js +14 -0
- data/lib/stripchart/public/components/d3/src/svg/area.js +120 -0
- data/lib/stripchart/public/components/d3/src/svg/axis.js +222 -0
- data/lib/stripchart/public/components/d3/src/svg/brush.js +379 -0
- data/lib/stripchart/public/components/d3/src/svg/chord.js +90 -0
- data/lib/stripchart/public/components/d3/src/svg/diagonal-radial.js +26 -0
- data/lib/stripchart/public/components/d3/src/svg/diagonal.js +43 -0
- data/lib/stripchart/public/components/d3/src/svg/index.js +12 -0
- data/lib/stripchart/public/components/d3/src/svg/line-radial.js +26 -0
- data/lib/stripchart/public/components/d3/src/svg/line.js +439 -0
- data/lib/stripchart/public/components/d3/src/svg/svg.js +1 -0
- data/lib/stripchart/public/components/d3/src/svg/symbol.js +105 -0
- data/lib/stripchart/public/components/d3/src/time/day.js +21 -0
- data/lib/stripchart/public/components/d3/src/time/format-iso.js +20 -0
- data/lib/stripchart/public/components/d3/src/time/format-locale.js +10 -0
- data/lib/stripchart/public/components/d3/src/time/format-localized.js +11 -0
- data/lib/stripchart/public/components/d3/src/time/format-utc.js +31 -0
- data/lib/stripchart/public/components/d3/src/time/format.js +303 -0
- data/lib/stripchart/public/components/d3/src/time/hour.js +14 -0
- data/lib/stripchart/public/components/d3/src/time/index.js +15 -0
- data/lib/stripchart/public/components/d3/src/time/interval.js +71 -0
- data/lib/stripchart/public/components/d3/src/time/minute.js +13 -0
- data/lib/stripchart/public/components/d3/src/time/month.js +16 -0
- data/lib/stripchart/public/components/d3/src/time/scale-utc.js +43 -0
- data/lib/stripchart/public/components/d3/src/time/scale.js +150 -0
- data/lib/stripchart/public/components/d3/src/time/second.js +13 -0
- data/lib/stripchart/public/components/d3/src/time/time.js +35 -0
- data/lib/stripchart/public/components/d3/src/time/week.js +32 -0
- data/lib/stripchart/public/components/d3/src/time/year.js +16 -0
- data/lib/stripchart/public/components/d3/src/transition/attr.js +58 -0
- data/lib/stripchart/public/components/d3/src/transition/delay.js +9 -0
- data/lib/stripchart/public/components/d3/src/transition/duration.js +9 -0
- data/lib/stripchart/public/components/d3/src/transition/each.js +23 -0
- data/lib/stripchart/public/components/d3/src/transition/ease.js +10 -0
- data/lib/stripchart/public/components/d3/src/transition/filter.js +22 -0
- data/lib/stripchart/public/components/d3/src/transition/index.js +1 -0
- data/lib/stripchart/public/components/d3/src/transition/remove.js +8 -0
- data/lib/stripchart/public/components/d3/src/transition/select.js +27 -0
- data/lib/stripchart/public/components/d3/src/transition/selectAll.js +30 -0
- data/lib/stripchart/public/components/d3/src/transition/style.js +53 -0
- data/lib/stripchart/public/components/d3/src/transition/subtransition.js +25 -0
- data/lib/stripchart/public/components/d3/src/transition/text.js +11 -0
- data/lib/stripchart/public/components/d3/src/transition/transition.js +118 -0
- data/lib/stripchart/public/components/d3/src/transition/tween.js +17 -0
- data/lib/stripchart/public/components/d3/src/xhr/html.js +12 -0
- data/lib/stripchart/public/components/d3/src/xhr/index.js +5 -0
- data/lib/stripchart/public/components/d3/src/xhr/json.js +9 -0
- data/lib/stripchart/public/components/d3/src/xhr/text.js +5 -0
- data/lib/stripchart/public/components/d3/src/xhr/xhr.js +118 -0
- data/lib/stripchart/public/components/d3/src/xhr/xml.js +5 -0
- data/lib/stripchart/public/components/d3/test/XMLHttpRequest.js +55 -0
- data/lib/stripchart/public/components/d3/test/arrays/ascending-test.js +45 -0
- data/lib/stripchart/public/components/d3/test/arrays/bisect-test.js +257 -0
- data/lib/stripchart/public/components/d3/test/arrays/descending-test.js +45 -0
- data/lib/stripchart/public/components/d3/test/arrays/entries-test.js +39 -0
- data/lib/stripchart/public/components/d3/test/arrays/extent-test.js +50 -0
- data/lib/stripchart/public/components/d3/test/arrays/keys-test.js +27 -0
- data/lib/stripchart/public/components/d3/test/arrays/map-test.js +214 -0
- data/lib/stripchart/public/components/d3/test/arrays/max-test.js +51 -0
- data/lib/stripchart/public/components/d3/test/arrays/mean-test.js +39 -0
- data/lib/stripchart/public/components/d3/test/arrays/median-test.js +39 -0
- data/lib/stripchart/public/components/d3/test/arrays/merge-test.js +26 -0
- data/lib/stripchart/public/components/d3/test/arrays/min-test.js +51 -0
- data/lib/stripchart/public/components/d3/test/arrays/nest-test.js +256 -0
- data/lib/stripchart/public/components/d3/test/arrays/permute-test.js +49 -0
- data/lib/stripchart/public/components/d3/test/arrays/quantile-test.js +56 -0
- data/lib/stripchart/public/components/d3/test/arrays/range-test.js +99 -0
- data/lib/stripchart/public/components/d3/test/arrays/set-test.js +136 -0
- data/lib/stripchart/public/components/d3/test/arrays/sum-test.js +43 -0
- data/lib/stripchart/public/components/d3/test/arrays/transpose-test.js +28 -0
- data/lib/stripchart/public/components/d3/test/arrays/values-test.js +31 -0
- data/lib/stripchart/public/components/d3/test/arrays/zip-test.js +28 -0
- data/lib/stripchart/public/components/d3/test/assert.js +153 -0
- data/lib/stripchart/public/components/d3/test/color/hcl-test.js +112 -0
- data/lib/stripchart/public/components/d3/test/color/hsl-test.js +118 -0
- data/lib/stripchart/public/components/d3/test/color/lab-test.js +81 -0
- data/lib/stripchart/public/components/d3/test/color/rgb-test.js +91 -0
- data/lib/stripchart/public/components/d3/test/core/functor-test.js +25 -0
- data/lib/stripchart/public/components/d3/test/core/ns-test.js +57 -0
- data/lib/stripchart/public/components/d3/test/core/rebind-test.js +50 -0
- data/lib/stripchart/public/components/d3/test/core/version-test.js +16 -0
- data/lib/stripchart/public/components/d3/test/data/sample.csv +2 -0
- data/lib/stripchart/public/components/d3/test/data/sample.html +5 -0
- data/lib/stripchart/public/components/d3/test/data/sample.json +1 -0
- data/lib/stripchart/public/components/d3/test/data/sample.tsv +2 -0
- data/lib/stripchart/public/components/d3/test/data/sample.txt +1 -0
- data/lib/stripchart/public/components/d3/test/data/sample.xml +4 -0
- data/lib/stripchart/public/components/d3/test/data/us-counties.json +3186 -0
- data/lib/stripchart/public/components/d3/test/dsv/csv-test.js +214 -0
- data/lib/stripchart/public/components/d3/test/dsv/tsv-test.js +185 -0
- data/lib/stripchart/public/components/d3/test/event/dispatch-test.js +163 -0
- data/lib/stripchart/public/components/d3/test/event/mouse-test.html +22 -0
- data/lib/stripchart/public/components/d3/test/event/timer-test.js +74 -0
- data/lib/stripchart/public/components/d3/test/event/touch-test.html +61 -0
- data/lib/stripchart/public/components/d3/test/format/format-test.js +360 -0
- data/lib/stripchart/public/components/d3/test/format/formatPrefix-test.js +112 -0
- data/lib/stripchart/public/components/d3/test/format/requote-test.js +49 -0
- data/lib/stripchart/public/components/d3/test/format/round-test.js +66 -0
- data/lib/stripchart/public/components/d3/test/geo/albers-test.js +40 -0
- data/lib/stripchart/public/components/d3/test/geo/albers-usa-test.js +33 -0
- data/lib/stripchart/public/components/d3/test/geo/area-benchmark.js +12 -0
- data/lib/stripchart/public/components/d3/test/geo/area-test.js +185 -0
- data/lib/stripchart/public/components/d3/test/geo/azimuthal-equal-area-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/azimuthal-equidistant-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/benchmark.js +83 -0
- data/lib/stripchart/public/components/d3/test/geo/bounds-test.js +265 -0
- data/lib/stripchart/public/components/d3/test/geo/centroid-test.js +187 -0
- data/lib/stripchart/public/components/d3/test/geo/circle-test.js +29 -0
- data/lib/stripchart/public/components/d3/test/geo/clip-view-mock.js +4 -0
- data/lib/stripchart/public/components/d3/test/geo/clip-view-test.js +44 -0
- data/lib/stripchart/public/components/d3/test/geo/conic-conformal-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/conic-equal-area-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/conic-equidistant-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/distance-test.js +20 -0
- data/lib/stripchart/public/components/d3/test/geo/equirectangular-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/gnomonic-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/graticule-test.js +188 -0
- data/lib/stripchart/public/components/d3/test/geo/greatArc-test.js +35 -0
- data/lib/stripchart/public/components/d3/test/geo/interpolate-test.js +22 -0
- data/lib/stripchart/public/components/d3/test/geo/length-test.js +44 -0
- data/lib/stripchart/public/components/d3/test/geo/mercator-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/orthographic-test.js +34 -0
- data/lib/stripchart/public/components/d3/test/geo/path-test.js +832 -0
- data/lib/stripchart/public/components/d3/test/geo/point-in-polygon-mock.js +18 -0
- data/lib/stripchart/public/components/d3/test/geo/point-in-polygon-test.js +352 -0
- data/lib/stripchart/public/components/d3/test/geo/projection-test-suite.js +29 -0
- data/lib/stripchart/public/components/d3/test/geo/projection-test.js +58 -0
- data/lib/stripchart/public/components/d3/test/geo/rotation-test.js +35 -0
- data/lib/stripchart/public/components/d3/test/geo/stereographic-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geo/stream-test.js +264 -0
- data/lib/stripchart/public/components/d3/test/geo/transverse-mercator-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/geom/hull-test.js +68 -0
- data/lib/stripchart/public/components/d3/test/geom/polygon-test.js +151 -0
- data/lib/stripchart/public/components/d3/test/geom/quadtree-test.js +139 -0
- data/lib/stripchart/public/components/d3/test/geom/voronoi-test.js +230 -0
- data/lib/stripchart/public/components/d3/test/interpolate/array-test.js +24 -0
- data/lib/stripchart/public/components/d3/test/interpolate/ease-test.js +135 -0
- data/lib/stripchart/public/components/d3/test/interpolate/hcl-test.js +47 -0
- data/lib/stripchart/public/components/d3/test/interpolate/hsl-test.js +47 -0
- data/lib/stripchart/public/components/d3/test/interpolate/interpolate-test.js +157 -0
- data/lib/stripchart/public/components/d3/test/interpolate/interpolate-transform-test.js +60 -0
- data/lib/stripchart/public/components/d3/test/interpolate/lab-test.js +31 -0
- data/lib/stripchart/public/components/d3/test/interpolate/number-test.js +20 -0
- data/lib/stripchart/public/components/d3/test/interpolate/object-test.js +35 -0
- data/lib/stripchart/public/components/d3/test/interpolate/rgb-test.js +31 -0
- data/lib/stripchart/public/components/d3/test/interpolate/round-test.js +17 -0
- data/lib/stripchart/public/components/d3/test/interpolate/string-test.js +43 -0
- data/lib/stripchart/public/components/d3/test/layout/chord-test.js +164 -0
- data/lib/stripchart/public/components/d3/test/layout/cluster-test.js +44 -0
- data/lib/stripchart/public/components/d3/test/layout/force-test.js +119 -0
- data/lib/stripchart/public/components/d3/test/layout/hierarchy-test.js +27 -0
- data/lib/stripchart/public/components/d3/test/layout/histogram-test.js +92 -0
- data/lib/stripchart/public/components/d3/test/layout/pack-test.js +129 -0
- data/lib/stripchart/public/components/d3/test/layout/partition-test.js +45 -0
- data/lib/stripchart/public/components/d3/test/layout/pie-test.js +24 -0
- data/lib/stripchart/public/components/d3/test/layout/tree-test.js +45 -0
- data/lib/stripchart/public/components/d3/test/layout/treemap-test.js +181 -0
- data/lib/stripchart/public/components/d3/test/load.js +58 -0
- data/lib/stripchart/public/components/d3/test/math/random-test.js +37 -0
- data/lib/stripchart/public/components/d3/test/math/transform-null-matrix-test.html +26 -0
- data/lib/stripchart/public/components/d3/test/math/transform-null-test.html +26 -0
- data/lib/stripchart/public/components/d3/test/math/transform-rotate-origin-test.html +40 -0
- data/lib/stripchart/public/components/d3/test/math/transform-rotate-test.html +138 -0
- data/lib/stripchart/public/components/d3/test/math/transform-test.html +88 -0
- data/lib/stripchart/public/components/d3/test/scale/category-test.js +76 -0
- data/lib/stripchart/public/components/d3/test/scale/identity-test.js +163 -0
- data/lib/stripchart/public/components/d3/test/scale/linear-test.js +281 -0
- data/lib/stripchart/public/components/d3/test/scale/log-test.js +378 -0
- data/lib/stripchart/public/components/d3/test/scale/ordinal-test.js +272 -0
- data/lib/stripchart/public/components/d3/test/scale/pow-test.js +267 -0
- data/lib/stripchart/public/components/d3/test/scale/quantile-test.js +91 -0
- data/lib/stripchart/public/components/d3/test/scale/quantize-test.js +92 -0
- data/lib/stripchart/public/components/d3/test/scale/sqrt-test.js +260 -0
- data/lib/stripchart/public/components/d3/test/scale/threshold-test.js +64 -0
- data/lib/stripchart/public/components/d3/test/selection/append-test.js +153 -0
- data/lib/stripchart/public/components/d3/test/selection/attr-test.js +182 -0
- data/lib/stripchart/public/components/d3/test/selection/call-test.js +75 -0
- data/lib/stripchart/public/components/d3/test/selection/classed-test.js +269 -0
- data/lib/stripchart/public/components/d3/test/selection/data-test.js +270 -0
- data/lib/stripchart/public/components/d3/test/selection/datum-test.js +87 -0
- data/lib/stripchart/public/components/d3/test/selection/each-test.js +87 -0
- data/lib/stripchart/public/components/d3/test/selection/empty-test.js +53 -0
- data/lib/stripchart/public/components/d3/test/selection/enter-test.js +24 -0
- data/lib/stripchart/public/components/d3/test/selection/filter-test.js +72 -0
- data/lib/stripchart/public/components/d3/test/selection/html-test.js +134 -0
- data/lib/stripchart/public/components/d3/test/selection/insert-test.js +169 -0
- data/lib/stripchart/public/components/d3/test/selection/node-test.js +55 -0
- data/lib/stripchart/public/components/d3/test/selection/on-test.js +135 -0
- data/lib/stripchart/public/components/d3/test/selection/order-test.js +32 -0
- data/lib/stripchart/public/components/d3/test/selection/property-test.js +118 -0
- data/lib/stripchart/public/components/d3/test/selection/remove-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/selection/select-test.js +69 -0
- data/lib/stripchart/public/components/d3/test/selection/selectAll-test.js +52 -0
- data/lib/stripchart/public/components/d3/test/selection/selection-select-test.js +128 -0
- data/lib/stripchart/public/components/d3/test/selection/selection-selectAll-test.js +131 -0
- data/lib/stripchart/public/components/d3/test/selection/selection-test.js +38 -0
- data/lib/stripchart/public/components/d3/test/selection/size-test.js +52 -0
- data/lib/stripchart/public/components/d3/test/selection/sort-test.js +81 -0
- data/lib/stripchart/public/components/d3/test/selection/style-test.js +129 -0
- data/lib/stripchart/public/components/d3/test/selection/text-test.js +115 -0
- data/lib/stripchart/public/components/d3/test/svg/arc-test.js +143 -0
- data/lib/stripchart/public/components/d3/test/svg/area-radial-test.js +199 -0
- data/lib/stripchart/public/components/d3/test/svg/area-test.js +192 -0
- data/lib/stripchart/public/components/d3/test/svg/axis-test.js +447 -0
- data/lib/stripchart/public/components/d3/test/svg/brush-test.js +96 -0
- data/lib/stripchart/public/components/d3/test/svg/diagonal-test.js +62 -0
- data/lib/stripchart/public/components/d3/test/svg/line-radial-test.js +120 -0
- data/lib/stripchart/public/components/d3/test/svg/line-test.js +207 -0
- data/lib/stripchart/public/components/d3/test/svg/symbol-test.js +91 -0
- data/lib/stripchart/public/components/d3/test/time/day-test.js +178 -0
- data/lib/stripchart/public/components/d3/test/time/dayOfYear-test.js +16 -0
- data/lib/stripchart/public/components/d3/test/time/days-test.js +95 -0
- data/lib/stripchart/public/components/d3/test/time/format-iso-test.js +33 -0
- data/lib/stripchart/public/components/d3/test/time/format-test.js +300 -0
- data/lib/stripchart/public/components/d3/test/time/format-utc-test.js +219 -0
- data/lib/stripchart/public/components/d3/test/time/hour-test.js +215 -0
- data/lib/stripchart/public/components/d3/test/time/hours-test.js +109 -0
- data/lib/stripchart/public/components/d3/test/time/minute-test.js +127 -0
- data/lib/stripchart/public/components/d3/test/time/minutes-test.js +91 -0
- data/lib/stripchart/public/components/d3/test/time/month-test.js +150 -0
- data/lib/stripchart/public/components/d3/test/time/months-test.js +95 -0
- data/lib/stripchart/public/components/d3/test/time/scale-test.js +585 -0
- data/lib/stripchart/public/components/d3/test/time/second-test.js +143 -0
- data/lib/stripchart/public/components/d3/test/time/seconds-test.js +91 -0
- data/lib/stripchart/public/components/d3/test/time/time.js +30 -0
- data/lib/stripchart/public/components/d3/test/time/week-test.js +162 -0
- data/lib/stripchart/public/components/d3/test/time/weeks-test.js +95 -0
- data/lib/stripchart/public/components/d3/test/time/year-test.js +137 -0
- data/lib/stripchart/public/components/d3/test/time/years-test.js +74 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-attr.js +56 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-attrTween.js +59 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-call.js +30 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-delay.js +56 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-duration.js +60 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-each.js +163 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-filter.js +84 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-id.js +22 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-node.js +39 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-remove.js +45 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-select.js +60 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-selectAll.js +56 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-size.js +37 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-style.js +51 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-styleTween.js +65 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-text.js +27 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-time.js +38 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-transition.js +59 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test-tween.js +62 -0
- data/lib/stripchart/public/components/d3/test/transition/transition-test.js +89 -0
- data/lib/stripchart/public/components/d3/test/xhr/html-test.js +37 -0
- data/lib/stripchart/public/components/d3/test/xhr/json-test.js +51 -0
- data/lib/stripchart/public/components/d3/test/xhr/text-test.js +46 -0
- data/lib/stripchart/public/components/d3/test/xhr/xhr-test.js +54 -0
- data/lib/stripchart/public/components/d3/test/xhr/xml-test.js +46 -0
- data/lib/stripchart/public/components/jquery/README.md +11 -0
- data/lib/stripchart/public/components/jquery/bower.json +11 -0
- data/lib/stripchart/public/components/jquery/component.json +23 -0
- data/lib/stripchart/public/components/jquery/composer.json +35 -0
- data/lib/stripchart/public/components/jquery/jquery-migrate.js +511 -0
- data/lib/stripchart/public/components/jquery/jquery-migrate.min.js +3 -0
- data/lib/stripchart/public/components/jquery/jquery.js +8829 -0
- data/lib/stripchart/public/components/jquery/jquery.min.js +6 -0
- data/lib/stripchart/public/components/jquery/jquery.min.map +1 -0
- data/lib/stripchart/public/components/jquery/package.json +7 -0
- data/lib/stripchart/version.rb +3 -0
- data/lib/stripchart/views/index.erb +19 -0
- data/lib/stripchart/web.rb +22 -0
- data/lib/stripchart/websocket.rb +22 -0
- metadata +602 -0
@@ -0,0 +1,68 @@
|
|
1
|
+
import "../math/trigonometry";
|
2
|
+
import "color";
|
3
|
+
import "hcl";
|
4
|
+
import "rgb";
|
5
|
+
|
6
|
+
d3.lab = function(l, a, b) {
|
7
|
+
return arguments.length === 1
|
8
|
+
? (l instanceof d3_Lab ? d3_lab(l.l, l.a, l.b)
|
9
|
+
: (l instanceof d3_Hcl ? d3_hcl_lab(l.l, l.c, l.h)
|
10
|
+
: d3_rgb_lab((l = d3.rgb(l)).r, l.g, l.b)))
|
11
|
+
: d3_lab(+l, +a, +b);
|
12
|
+
};
|
13
|
+
|
14
|
+
function d3_lab(l, a, b) {
|
15
|
+
return new d3_Lab(l, a, b);
|
16
|
+
}
|
17
|
+
|
18
|
+
function d3_Lab(l, a, b) {
|
19
|
+
this.l = l;
|
20
|
+
this.a = a;
|
21
|
+
this.b = b;
|
22
|
+
}
|
23
|
+
|
24
|
+
// Corresponds roughly to RGB brighter/darker
|
25
|
+
var d3_lab_K = 18;
|
26
|
+
|
27
|
+
// D65 standard referent
|
28
|
+
var d3_lab_X = 0.950470,
|
29
|
+
d3_lab_Y = 1,
|
30
|
+
d3_lab_Z = 1.088830;
|
31
|
+
|
32
|
+
var d3_labPrototype = d3_Lab.prototype = new d3_Color;
|
33
|
+
|
34
|
+
d3_labPrototype.brighter = function(k) {
|
35
|
+
return d3_lab(Math.min(100, this.l + d3_lab_K * (arguments.length ? k : 1)), this.a, this.b);
|
36
|
+
};
|
37
|
+
|
38
|
+
d3_labPrototype.darker = function(k) {
|
39
|
+
return d3_lab(Math.max(0, this.l - d3_lab_K * (arguments.length ? k : 1)), this.a, this.b);
|
40
|
+
};
|
41
|
+
|
42
|
+
d3_labPrototype.rgb = function() {
|
43
|
+
return d3_lab_rgb(this.l, this.a, this.b);
|
44
|
+
};
|
45
|
+
|
46
|
+
function d3_lab_rgb(l, a, b) {
|
47
|
+
var y = (l + 16) / 116,
|
48
|
+
x = y + a / 500,
|
49
|
+
z = y - b / 200;
|
50
|
+
x = d3_lab_xyz(x) * d3_lab_X;
|
51
|
+
y = d3_lab_xyz(y) * d3_lab_Y;
|
52
|
+
z = d3_lab_xyz(z) * d3_lab_Z;
|
53
|
+
return d3_rgb(
|
54
|
+
d3_xyz_rgb( 3.2404542 * x - 1.5371385 * y - 0.4985314 * z),
|
55
|
+
d3_xyz_rgb(-0.9692660 * x + 1.8760108 * y + 0.0415560 * z),
|
56
|
+
d3_xyz_rgb( 0.0556434 * x - 0.2040259 * y + 1.0572252 * z)
|
57
|
+
);
|
58
|
+
}
|
59
|
+
|
60
|
+
function d3_lab_hcl(l, a, b) {
|
61
|
+
return l > 0
|
62
|
+
? d3_hcl(Math.atan2(b, a) * d3_degrees, Math.sqrt(a * a + b * b), l)
|
63
|
+
: d3_hcl(NaN, NaN, l);
|
64
|
+
}
|
65
|
+
|
66
|
+
function d3_lab_xyz(x) {
|
67
|
+
return x > 0.206893034 ? x * x * x : (x - 4 / 29) / 7.787037;
|
68
|
+
}
|
@@ -0,0 +1,307 @@
|
|
1
|
+
import "../arrays/map";
|
2
|
+
import "color";
|
3
|
+
import "hsl";
|
4
|
+
import "lab";
|
5
|
+
import "xyz";
|
6
|
+
|
7
|
+
d3.rgb = function(r, g, b) {
|
8
|
+
return arguments.length === 1
|
9
|
+
? (r instanceof d3_Rgb ? d3_rgb(r.r, r.g, r.b)
|
10
|
+
: d3_rgb_parse("" + r, d3_rgb, d3_hsl_rgb))
|
11
|
+
: d3_rgb(~~r, ~~g, ~~b);
|
12
|
+
};
|
13
|
+
|
14
|
+
function d3_rgb(r, g, b) {
|
15
|
+
return new d3_Rgb(r, g, b);
|
16
|
+
}
|
17
|
+
|
18
|
+
function d3_Rgb(r, g, b) {
|
19
|
+
this.r = r;
|
20
|
+
this.g = g;
|
21
|
+
this.b = b;
|
22
|
+
}
|
23
|
+
|
24
|
+
var d3_rgbPrototype = d3_Rgb.prototype = new d3_Color;
|
25
|
+
|
26
|
+
d3_rgbPrototype.brighter = function(k) {
|
27
|
+
k = Math.pow(0.7, arguments.length ? k : 1);
|
28
|
+
var r = this.r,
|
29
|
+
g = this.g,
|
30
|
+
b = this.b,
|
31
|
+
i = 30;
|
32
|
+
if (!r && !g && !b) return d3_rgb(i, i, i);
|
33
|
+
if (r && r < i) r = i;
|
34
|
+
if (g && g < i) g = i;
|
35
|
+
if (b && b < i) b = i;
|
36
|
+
return d3_rgb(
|
37
|
+
Math.min(255, Math.floor(r / k)),
|
38
|
+
Math.min(255, Math.floor(g / k)),
|
39
|
+
Math.min(255, Math.floor(b / k)));
|
40
|
+
};
|
41
|
+
|
42
|
+
d3_rgbPrototype.darker = function(k) {
|
43
|
+
k = Math.pow(0.7, arguments.length ? k : 1);
|
44
|
+
return d3_rgb(
|
45
|
+
Math.floor(k * this.r),
|
46
|
+
Math.floor(k * this.g),
|
47
|
+
Math.floor(k * this.b));
|
48
|
+
};
|
49
|
+
|
50
|
+
d3_rgbPrototype.hsl = function() {
|
51
|
+
return d3_rgb_hsl(this.r, this.g, this.b);
|
52
|
+
};
|
53
|
+
|
54
|
+
d3_rgbPrototype.toString = function() {
|
55
|
+
return "#" + d3_rgb_hex(this.r) + d3_rgb_hex(this.g) + d3_rgb_hex(this.b);
|
56
|
+
};
|
57
|
+
|
58
|
+
function d3_rgb_hex(v) {
|
59
|
+
return v < 0x10
|
60
|
+
? "0" + Math.max(0, v).toString(16)
|
61
|
+
: Math.min(255, v).toString(16);
|
62
|
+
}
|
63
|
+
|
64
|
+
function d3_rgb_parse(format, rgb, hsl) {
|
65
|
+
var r = 0, // red channel; int in [0, 255]
|
66
|
+
g = 0, // green channel; int in [0, 255]
|
67
|
+
b = 0, // blue channel; int in [0, 255]
|
68
|
+
m1, // CSS color specification match
|
69
|
+
m2, // CSS color specification type (e.g., rgb)
|
70
|
+
name;
|
71
|
+
|
72
|
+
/* Handle hsl, rgb. */
|
73
|
+
m1 = /([a-z]+)\((.*)\)/i.exec(format);
|
74
|
+
if (m1) {
|
75
|
+
m2 = m1[2].split(",");
|
76
|
+
switch (m1[1]) {
|
77
|
+
case "hsl": {
|
78
|
+
return hsl(
|
79
|
+
parseFloat(m2[0]), // degrees
|
80
|
+
parseFloat(m2[1]) / 100, // percentage
|
81
|
+
parseFloat(m2[2]) / 100 // percentage
|
82
|
+
);
|
83
|
+
}
|
84
|
+
case "rgb": {
|
85
|
+
return rgb(
|
86
|
+
d3_rgb_parseNumber(m2[0]),
|
87
|
+
d3_rgb_parseNumber(m2[1]),
|
88
|
+
d3_rgb_parseNumber(m2[2])
|
89
|
+
);
|
90
|
+
}
|
91
|
+
}
|
92
|
+
}
|
93
|
+
|
94
|
+
/* Named colors. */
|
95
|
+
if (name = d3_rgb_names.get(format)) return rgb(name.r, name.g, name.b);
|
96
|
+
|
97
|
+
/* Hexadecimal colors: #rgb and #rrggbb. */
|
98
|
+
if (format != null && format.charAt(0) === "#") {
|
99
|
+
if (format.length === 4) {
|
100
|
+
r = format.charAt(1); r += r;
|
101
|
+
g = format.charAt(2); g += g;
|
102
|
+
b = format.charAt(3); b += b;
|
103
|
+
} else if (format.length === 7) {
|
104
|
+
r = format.substring(1, 3);
|
105
|
+
g = format.substring(3, 5);
|
106
|
+
b = format.substring(5, 7);
|
107
|
+
}
|
108
|
+
r = parseInt(r, 16);
|
109
|
+
g = parseInt(g, 16);
|
110
|
+
b = parseInt(b, 16);
|
111
|
+
}
|
112
|
+
|
113
|
+
return rgb(r, g, b);
|
114
|
+
}
|
115
|
+
|
116
|
+
function d3_rgb_hsl(r, g, b) {
|
117
|
+
var min = Math.min(r /= 255, g /= 255, b /= 255),
|
118
|
+
max = Math.max(r, g, b),
|
119
|
+
d = max - min,
|
120
|
+
h,
|
121
|
+
s,
|
122
|
+
l = (max + min) / 2;
|
123
|
+
if (d) {
|
124
|
+
s = l < .5 ? d / (max + min) : d / (2 - max - min);
|
125
|
+
if (r == max) h = (g - b) / d + (g < b ? 6 : 0);
|
126
|
+
else if (g == max) h = (b - r) / d + 2;
|
127
|
+
else h = (r - g) / d + 4;
|
128
|
+
h *= 60;
|
129
|
+
} else {
|
130
|
+
h = NaN;
|
131
|
+
s = l > 0 && l < 1 ? 0 : h;
|
132
|
+
}
|
133
|
+
return d3_hsl(h, s, l);
|
134
|
+
}
|
135
|
+
|
136
|
+
function d3_rgb_lab(r, g, b) {
|
137
|
+
r = d3_rgb_xyz(r);
|
138
|
+
g = d3_rgb_xyz(g);
|
139
|
+
b = d3_rgb_xyz(b);
|
140
|
+
var x = d3_xyz_lab((0.4124564 * r + 0.3575761 * g + 0.1804375 * b) / d3_lab_X),
|
141
|
+
y = d3_xyz_lab((0.2126729 * r + 0.7151522 * g + 0.0721750 * b) / d3_lab_Y),
|
142
|
+
z = d3_xyz_lab((0.0193339 * r + 0.1191920 * g + 0.9503041 * b) / d3_lab_Z);
|
143
|
+
return d3_lab(116 * y - 16, 500 * (x - y), 200 * (y - z));
|
144
|
+
}
|
145
|
+
|
146
|
+
function d3_rgb_xyz(r) {
|
147
|
+
return (r /= 255) <= 0.04045 ? r / 12.92 : Math.pow((r + 0.055) / 1.055, 2.4);
|
148
|
+
}
|
149
|
+
|
150
|
+
function d3_rgb_parseNumber(c) { // either integer or percentage
|
151
|
+
var f = parseFloat(c);
|
152
|
+
return c.charAt(c.length - 1) === "%" ? Math.round(f * 2.55) : f;
|
153
|
+
}
|
154
|
+
|
155
|
+
var d3_rgb_names = d3.map({
|
156
|
+
aliceblue: "#f0f8ff",
|
157
|
+
antiquewhite: "#faebd7",
|
158
|
+
aqua: "#00ffff",
|
159
|
+
aquamarine: "#7fffd4",
|
160
|
+
azure: "#f0ffff",
|
161
|
+
beige: "#f5f5dc",
|
162
|
+
bisque: "#ffe4c4",
|
163
|
+
black: "#000000",
|
164
|
+
blanchedalmond: "#ffebcd",
|
165
|
+
blue: "#0000ff",
|
166
|
+
blueviolet: "#8a2be2",
|
167
|
+
brown: "#a52a2a",
|
168
|
+
burlywood: "#deb887",
|
169
|
+
cadetblue: "#5f9ea0",
|
170
|
+
chartreuse: "#7fff00",
|
171
|
+
chocolate: "#d2691e",
|
172
|
+
coral: "#ff7f50",
|
173
|
+
cornflowerblue: "#6495ed",
|
174
|
+
cornsilk: "#fff8dc",
|
175
|
+
crimson: "#dc143c",
|
176
|
+
cyan: "#00ffff",
|
177
|
+
darkblue: "#00008b",
|
178
|
+
darkcyan: "#008b8b",
|
179
|
+
darkgoldenrod: "#b8860b",
|
180
|
+
darkgray: "#a9a9a9",
|
181
|
+
darkgreen: "#006400",
|
182
|
+
darkgrey: "#a9a9a9",
|
183
|
+
darkkhaki: "#bdb76b",
|
184
|
+
darkmagenta: "#8b008b",
|
185
|
+
darkolivegreen: "#556b2f",
|
186
|
+
darkorange: "#ff8c00",
|
187
|
+
darkorchid: "#9932cc",
|
188
|
+
darkred: "#8b0000",
|
189
|
+
darksalmon: "#e9967a",
|
190
|
+
darkseagreen: "#8fbc8f",
|
191
|
+
darkslateblue: "#483d8b",
|
192
|
+
darkslategray: "#2f4f4f",
|
193
|
+
darkslategrey: "#2f4f4f",
|
194
|
+
darkturquoise: "#00ced1",
|
195
|
+
darkviolet: "#9400d3",
|
196
|
+
deeppink: "#ff1493",
|
197
|
+
deepskyblue: "#00bfff",
|
198
|
+
dimgray: "#696969",
|
199
|
+
dimgrey: "#696969",
|
200
|
+
dodgerblue: "#1e90ff",
|
201
|
+
firebrick: "#b22222",
|
202
|
+
floralwhite: "#fffaf0",
|
203
|
+
forestgreen: "#228b22",
|
204
|
+
fuchsia: "#ff00ff",
|
205
|
+
gainsboro: "#dcdcdc",
|
206
|
+
ghostwhite: "#f8f8ff",
|
207
|
+
gold: "#ffd700",
|
208
|
+
goldenrod: "#daa520",
|
209
|
+
gray: "#808080",
|
210
|
+
green: "#008000",
|
211
|
+
greenyellow: "#adff2f",
|
212
|
+
grey: "#808080",
|
213
|
+
honeydew: "#f0fff0",
|
214
|
+
hotpink: "#ff69b4",
|
215
|
+
indianred: "#cd5c5c",
|
216
|
+
indigo: "#4b0082",
|
217
|
+
ivory: "#fffff0",
|
218
|
+
khaki: "#f0e68c",
|
219
|
+
lavender: "#e6e6fa",
|
220
|
+
lavenderblush: "#fff0f5",
|
221
|
+
lawngreen: "#7cfc00",
|
222
|
+
lemonchiffon: "#fffacd",
|
223
|
+
lightblue: "#add8e6",
|
224
|
+
lightcoral: "#f08080",
|
225
|
+
lightcyan: "#e0ffff",
|
226
|
+
lightgoldenrodyellow: "#fafad2",
|
227
|
+
lightgray: "#d3d3d3",
|
228
|
+
lightgreen: "#90ee90",
|
229
|
+
lightgrey: "#d3d3d3",
|
230
|
+
lightpink: "#ffb6c1",
|
231
|
+
lightsalmon: "#ffa07a",
|
232
|
+
lightseagreen: "#20b2aa",
|
233
|
+
lightskyblue: "#87cefa",
|
234
|
+
lightslategray: "#778899",
|
235
|
+
lightslategrey: "#778899",
|
236
|
+
lightsteelblue: "#b0c4de",
|
237
|
+
lightyellow: "#ffffe0",
|
238
|
+
lime: "#00ff00",
|
239
|
+
limegreen: "#32cd32",
|
240
|
+
linen: "#faf0e6",
|
241
|
+
magenta: "#ff00ff",
|
242
|
+
maroon: "#800000",
|
243
|
+
mediumaquamarine: "#66cdaa",
|
244
|
+
mediumblue: "#0000cd",
|
245
|
+
mediumorchid: "#ba55d3",
|
246
|
+
mediumpurple: "#9370db",
|
247
|
+
mediumseagreen: "#3cb371",
|
248
|
+
mediumslateblue: "#7b68ee",
|
249
|
+
mediumspringgreen: "#00fa9a",
|
250
|
+
mediumturquoise: "#48d1cc",
|
251
|
+
mediumvioletred: "#c71585",
|
252
|
+
midnightblue: "#191970",
|
253
|
+
mintcream: "#f5fffa",
|
254
|
+
mistyrose: "#ffe4e1",
|
255
|
+
moccasin: "#ffe4b5",
|
256
|
+
navajowhite: "#ffdead",
|
257
|
+
navy: "#000080",
|
258
|
+
oldlace: "#fdf5e6",
|
259
|
+
olive: "#808000",
|
260
|
+
olivedrab: "#6b8e23",
|
261
|
+
orange: "#ffa500",
|
262
|
+
orangered: "#ff4500",
|
263
|
+
orchid: "#da70d6",
|
264
|
+
palegoldenrod: "#eee8aa",
|
265
|
+
palegreen: "#98fb98",
|
266
|
+
paleturquoise: "#afeeee",
|
267
|
+
palevioletred: "#db7093",
|
268
|
+
papayawhip: "#ffefd5",
|
269
|
+
peachpuff: "#ffdab9",
|
270
|
+
peru: "#cd853f",
|
271
|
+
pink: "#ffc0cb",
|
272
|
+
plum: "#dda0dd",
|
273
|
+
powderblue: "#b0e0e6",
|
274
|
+
purple: "#800080",
|
275
|
+
red: "#ff0000",
|
276
|
+
rosybrown: "#bc8f8f",
|
277
|
+
royalblue: "#4169e1",
|
278
|
+
saddlebrown: "#8b4513",
|
279
|
+
salmon: "#fa8072",
|
280
|
+
sandybrown: "#f4a460",
|
281
|
+
seagreen: "#2e8b57",
|
282
|
+
seashell: "#fff5ee",
|
283
|
+
sienna: "#a0522d",
|
284
|
+
silver: "#c0c0c0",
|
285
|
+
skyblue: "#87ceeb",
|
286
|
+
slateblue: "#6a5acd",
|
287
|
+
slategray: "#708090",
|
288
|
+
slategrey: "#708090",
|
289
|
+
snow: "#fffafa",
|
290
|
+
springgreen: "#00ff7f",
|
291
|
+
steelblue: "#4682b4",
|
292
|
+
tan: "#d2b48c",
|
293
|
+
teal: "#008080",
|
294
|
+
thistle: "#d8bfd8",
|
295
|
+
tomato: "#ff6347",
|
296
|
+
turquoise: "#40e0d0",
|
297
|
+
violet: "#ee82ee",
|
298
|
+
wheat: "#f5deb3",
|
299
|
+
white: "#ffffff",
|
300
|
+
whitesmoke: "#f5f5f5",
|
301
|
+
yellow: "#ffff00",
|
302
|
+
yellowgreen: "#9acd32"
|
303
|
+
});
|
304
|
+
|
305
|
+
d3_rgb_names.forEach(function(key, value) {
|
306
|
+
d3_rgb_names.set(key, d3_rgb_parse(value, d3_rgb, d3_hsl_rgb));
|
307
|
+
});
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import "../core/document";
|
2
|
+
|
3
|
+
try {
|
4
|
+
d3_document.createElement("div").style.setProperty("opacity", 0, "");
|
5
|
+
} catch (error) {
|
6
|
+
var d3_element_prototype = d3_window.Element.prototype,
|
7
|
+
d3_element_setAttribute = d3_element_prototype.setAttribute,
|
8
|
+
d3_element_setAttributeNS = d3_element_prototype.setAttributeNS,
|
9
|
+
d3_style_prototype = d3_window.CSSStyleDeclaration.prototype,
|
10
|
+
d3_style_setProperty = d3_style_prototype.setProperty;
|
11
|
+
d3_element_prototype.setAttribute = function(name, value) {
|
12
|
+
d3_element_setAttribute.call(this, name, value + "");
|
13
|
+
};
|
14
|
+
d3_element_prototype.setAttributeNS = function(space, local, value) {
|
15
|
+
d3_element_setAttributeNS.call(this, space, local, value + "");
|
16
|
+
};
|
17
|
+
d3_style_prototype.setProperty = function(name, value, priority) {
|
18
|
+
d3_style_setProperty.call(this, name, value + "", priority);
|
19
|
+
};
|
20
|
+
}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
import "document";
|
2
|
+
|
3
|
+
var d3_array = d3_arraySlice; // conversion for NodeLists
|
4
|
+
|
5
|
+
function d3_arrayCopy(pseudoarray) {
|
6
|
+
var i = -1, n = pseudoarray.length, array = [];
|
7
|
+
while (++i < n) array.push(pseudoarray[i]);
|
8
|
+
return array;
|
9
|
+
}
|
10
|
+
|
11
|
+
function d3_arraySlice(pseudoarray) {
|
12
|
+
return Array.prototype.slice.call(pseudoarray);
|
13
|
+
}
|
14
|
+
|
15
|
+
try {
|
16
|
+
d3_array(d3_documentElement.childNodes)[0].nodeType;
|
17
|
+
} catch(e) {
|
18
|
+
d3_array = d3_arrayCopy;
|
19
|
+
}
|