Граф коммитов

14 Коммитов

Автор SHA1 Сообщение Дата
Mike Bostock 3081dd45ef Consolidate everything into d3.v2.js.
Rather than producing separate files for each module, the default build now
produces a single file. This should encourage better page-load performance as
the files were relatively small. Also, it's easier to deal with only one file
rather than many, especially if you're not quite sure what the dependencies are.
You may still create minimized builds, if you don't want every feature.

This commit also demotes the chart components to the examples directory, rather
than keeping them as part of the core library. As always, D3 is not a charting
library, and these were ever only intended to serve as examples.
2012-02-18 14:04:01 -08:00
Mike Bostock 7d2ce55914 Fix a bug in SPLOM axes.
Array.reverse does not create a copy of the array, so we must slice first.
2011-12-20 08:39:01 -08:00
Jason Davies 5a87998694 Examples: namespaces are optional as of v2.6.0. 2011-11-23 22:48:13 +00:00
Mike Bostock af5fccdca1 Use inclusive bounds for brush examples. 2011-11-04 19:42:59 -07:00
Mike Bostock 6aad8c7c44 Use a single brush for scatterplot matrix. 2011-11-04 11:28:27 -07:00
Mike Bostock af589a01fc Update SPLOM example to use d3.svg.brush.
This required a couple core changes. First, the brush shouldn't notify listeners
when redrawing, because this commonly causes an infinite loop if one brush
triggers a change in another brush (as in a scatterplot matrix, where only one
brush is active at a given time). I suppose an alternative implementation might
use just a single brush, and assign the axes dynmically; I might try that in a
future commit. Second, I added a clear convenience method to reset a brush.
2011-11-02 11:44:29 -07:00
Mike Bostock 98ef2d185f Prefer style over attr. 2011-05-26 21:15:28 -07:00
Michael Bostock 127ecdea25 Restructure splom example. 2011-02-27 12:21:11 -08:00
Michael Bostock d215acef78 Add d3.behavior module.
Includes, as the first behavior, a pan & zoom behavior. The canvas can be panned
by dragging the mouse, and zoomed using the mousewheel (or by double-click). By
listening to redraw events, users can decide whether to implement geometric
zooming (such as by setting the "transform" attribute on an `svg:g` element) or
semantic zooming (by changing the domain of a scale object and repositioning
elements).

This commit also includes two bug fixes. The `d3.format` class now properly
groups thousands of negative numbers, and supports the sign specifier. The
unicode minus symbol \u2212 is used for negative values. The `d3.scale.pow`
class now properly handles negative numbers, as well.
2011-02-11 13:00:41 -08:00
Michael Bostock e4935b1bb5 Add brushing & linking to splom. 2011-02-07 09:56:05 -08:00
Michael Bostock f8ae20da9d Simplify data join. Add insert & empty.
The data join is now specified as a single function of data, as with all other
properties. This allows the key to be computed on the previously-bound data,
rather than requiring the key to be serialized into the DOM (say, as an
attribute). In the case that there is no previously-bound data, it is still
possible to access the associated node as the `this` context.

The `enter` operator no longer performs an append. For symmetry with the `exit`
operator, you must call `append` after obtaining the entering selection. This
requires a tiny bit more code, but should make the code more clear. Also, it
provides an opportunity to use a different instantiation operator, such as the
new `insert` operator. This takes a second argument, which is a selector for the
insert-before reference element. For example, the selector ":first-child" will
prepend nodes.

The `empty` operator allows you to query whether a selection is empty (i.e.,
contains zero matching nodes).
2011-01-31 11:00:35 -08:00
Michael Bostock c678ecb447 Remove cruft. 2011-01-17 12:34:02 -08:00
Michael Bostock 3727826d7e Add a cheesy enter transition. 2010-11-04 20:04:13 -07:00
Michael Bostock e793ce8800 Scatterplot matrix example. 2010-11-04 19:54:24 -07:00