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

3858 Коммитов

Автор SHA1 Сообщение Дата
Michael Bostock 3cfeb7c664 Checkpoint immediate-mode implementation. 2010-10-23 20:32:16 -07:00
Michael Bostock 4ff256dd76 Staged transitions. (d3.alt)
At first I thought we'd need to implement a deferred mode again, but it turns
out the deferred mode really doesn't buy you that much (beyond syntax). You
can do the same thing with event listeners and it'll probably be easier to
understand.
2010-10-23 18:39:26 -07:00
Michael Bostock a63f8c10a8 Actually, do store data on the dom. (d3.alt)
This way, the data is available when we want to run an exit transition. It
would be nice if there were a way to clear the data in the future, though.
2010-10-23 17:46:43 -07:00
Michael Bostock b28a1dbfe0 Don't store data on the dom. Remove getters. (d3.alt)
I removed the internal flat storage of the nodes; now there is only the
two-dimensional groups array, which can be inspected from the outside. For
ease of implementation, I removed the old getters that allowed you to query
attributes (etc.) since it doesn't make as much sense to do that when the
selection is grouped. And anyway, that was primarily intended for debugging
purposes. You can still use `each` for iteration.
2010-10-23 17:00:04 -07:00
Michael Bostock 1d15c3f6ef Remove deselect. Better remove. (d3.alt) 2010-10-23 16:08:54 -07:00
Michael Bostock 3220c0b717 Fix a bug in select implementation (d3.alt).
The `select` operator should inherit data from the parent. Still working on
enter and exit.
2010-10-23 15:34:30 -07:00
Michael Bostock 3a898d7eb4 Fix bug in append implementation (d3.alt).
Still working on enter & exit for data binding.
2010-10-23 15:14:47 -07:00
Michael Bostock f5517ea02d First pass at data binding (d3.alt). 2010-10-23 13:06:12 -07:00
Michael Bostock 4494b02790 Allow data to be set to null (d3.alt). 2010-10-23 12:32:46 -07:00
Michael Bostock 3ee56574b8 Only provide a single index to `each` callback (d3.alt).
Hopefully, this should avoid confusion as to what the various indexes mean.
Note that since the callback is guaranteed to be invoked in-order, it's
possible with a little work to infer the group index and the global index. But
this at least gets people in the habit of only depending on the local index.
2010-10-23 12:28:31 -07:00
Michael Bostock d8e79be35c Transition subselect (d3.alt). 2010-10-23 11:52:26 -07:00
Michael Bostock 85e45f5f5d Use `nodes.each` to visit nodes (d3.alt). 2010-10-23 11:47:18 -07:00
Michael Bostock b26f509dd4 Use index rather than full data stack (d3.alt).
Rather than keeping the full data stack and passing it as multiple arguments
to each value function, we now pass the datum followed by the index. If you
want to define values in terms of parent data, bake it into the child data!
2010-10-23 10:29:32 -07:00
Michael Bostock 04a6dce44c Checkpoint transitions (d3.alt). 2010-10-23 10:19:37 -07:00
Michael Bostock a1608d1e3a All selection of node references (d3.alt).
For example, you can now say:

	d3.select(document.body)
	d3.selectAll(document.links)

etc.
2010-10-23 08:22:03 -07:00
Michael Bostock 607ed11267 Cleanup alternate implementation. 2010-10-22 22:52:54 -07:00
Michael Bostock a4f5945eea Data for alternate implementation. 2010-10-22 22:32:14 -07:00
Michael Bostock 0c3e453601 Prototyping an alternate implementation. 2010-10-22 20:02:34 -07:00
Michael Bostock 55e13c778d Minor cleanup to ticks & tickFormat. 2010-10-22 16:06:59 -07:00
Michael Bostock 5e381ba73e Export a tickFormat function.
The tick format function doesn't have to be used with ticks, though. It's also
for convenient for determining an appropriate precision for any value label.
2010-10-22 13:51:36 -07:00
Michael Bostock d7bc33eafd First pass at ticks for linear scale. 2010-10-22 12:55:50 -07:00
Michael Bostock 936963e357 Initialize tweens immediately.
Previously, the tweens would not be initialized until the first tick, after a
minimum delay. It's more predictable if we initialize them during the initial
apply, especially if the tweens depend on external state (such as scales) that
may change after the transition has started.
2010-10-22 12:16:43 -07:00
Michael Bostock aab852b19a Temporary fix for select(404).selectAll().
If the select doesn't find any results, `o.node` is null, so we shouldn't run
any normal actions on it. But we still want to run the data action on it (to
generate the enter selection), so the fix is a bit more complicated than this.
2010-10-21 13:09:39 -07:00
Michael Bostock a5089b8918 Add `bind` action. 2010-10-21 12:53:56 -07:00
Michael Bostock 291a732042 Use scales for area chart example. 2010-10-20 15:42:15 -07:00
Michael Bostock 78bca67502 Add ordinal scale, range. 2010-10-20 15:22:22 -07:00
Michael Bostock 92d15a4472 First pass at scale functions.
This includes only the quantitative scale functions, which is primarily the
linear scale. Also included are `log` and `pow` scales, which are simple
transforms of linear scales. All the scale functions use the existing
interpolator logic, so you can specify an output range of numbers, colors,
fonts, paths... pretty much anything.
2010-10-20 11:07:42 -07:00
Michael Bostock c117dbe527 Move `max` and `range` to separate files. 2010-10-14 10:29:17 -07:00
Michael Bostock c8799da069 Rewrap colorbrewer/LICENSE. 2010-10-14 10:25:56 -07:00
Michael Bostock 5a99324d0b Rename README.mkd -> README.md. 2010-10-14 10:25:12 -07:00
Michael Bostock 6464020abb Update google-compiler to 20100917. 2010-10-14 10:23:15 -07:00
Michael Bostock 7e0e19106e Remove values/entries/keys.
These data-processing methods are useful, but they should live in a separate library.
2010-10-14 10:21:07 -07:00
Michael Bostock 2659546f48 Fix typo in LICENSE. 2010-10-10 10:37:07 -07:00
Michael Bostock 917442a1a2 Add HSL conversion utility. 2010-10-06 15:20:38 -07:00
Michael Bostock a16adb1a39 Add d3.{entries,keys,values}.
Also rename calendar/dow example to calendar/dji.
2010-10-05 11:57:27 -07:00
Michael Bostock bacf6762fa Add VIX calendar example. 2010-10-05 11:37:14 -07:00
Michael Bostock af68d6b2ef Quantile color scale. 2010-10-04 20:57:56 -07:00
Michael Bostock 5348d91193 Add lib/colorbrewer. 2010-10-04 20:41:18 -07:00
Michael Bostock 97a9c4466b Add _site to .gitignore. 2010-10-04 20:36:36 -07:00
Mike Bostock 5f47187f7d Update calendar example to use DOW data. 2010-10-04 17:28:01 -07:00
Mike Bostock 544e88d0b8 Add calendar layout example. 2010-10-04 13:01:56 -07:00
Mike Bostock 5d7536385d Rename select_all -> selectAll. 2010-10-02 11:38:50 -07:00
Mike Bostock 018b79577a Rename add -> append. 2010-10-02 11:00:31 -07:00
Mike Bostock ff98c89c9d Rescale when grouped. 2010-09-29 12:58:50 -07:00
Mike Bostock 661ff7fe82 Redesign of tweens. 2010-09-28 23:18:51 -07:00
Mike Bostock 373ae84c83 Tweak button margin in stacked bar chart example. 2010-09-28 18:34:45 -07:00
Mike Bostock bca36356ec Add group <-> stack bidrectional animation. 2010-09-28 18:04:58 -07:00
Mike Bostock b667421e51 Update README. 2010-09-28 17:38:31 -07:00
Mike Bostock 91debece60 Update README. 2010-09-28 17:37:59 -07:00
Mike Bostock 6e7b06f60f Update README. 2010-09-28 17:36:53 -07:00