d3.layout.cloud
Advanced tools
Comparing version 1.1.0 to 1.1.1
@@ -97,3 +97,3 @@ // Word cloud layout by Jason Davies, http://www.jasondavies.com/word-cloud/ | ||
if (Math.min(dx, dy) > maxDelta) break; | ||
if (Math.min(Math.abs(dx), Math.abs(dy)) >= maxDelta) break; | ||
@@ -100,0 +100,0 @@ tag.x = startX + dx; |
@@ -7,3 +7,3 @@ var globals = {}; | ||
global.d3 = require("d3"); | ||
global.Canvas = require("Canvas"); | ||
global.Canvas = require("canvas"); | ||
@@ -10,0 +10,0 @@ require("./d3.layout.cloud"); |
{ | ||
"name": "d3.layout.cloud", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "Generate word clouds in JavaScript.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -18,2 +18,20 @@ # Word Cloud Layout | ||
<a name="cloud" href="#cloud">#</a> d3.layout.<b>cloud</b>() | ||
Constructs a new cloud layout instance. | ||
<a name="on" href="#on">#</a> <b>on</b>(<i>type</i>, <i>listener</i>) | ||
Registers the specified *listener* to receive events of the specified *type* | ||
from the layout. Currently, only "word" and "end" events are supported. | ||
A "word" event is dispatched every time a word is successfully placed. | ||
Registered listeners are called with a single argument: the word object that | ||
has been placed. | ||
An "end" event is dispatched when the layout has finished attempting to place | ||
all words. Registered listeners are called with two arguments: an array of the | ||
word objects that were successfully placed, and a *bounds* object of the form | ||
`[{x0, y0}, {x1, y1}]` representing the extent of the placed objects. | ||
<a name="start" href="#start">#</a> <b>start</b>() | ||
@@ -33,3 +51,3 @@ | ||
Stops the layout algorithm.V | ||
Stops the layout algorithm. | ||
@@ -123,2 +141,3 @@ <a name="timeInterval" href="#timeInterval">#</a> <b>timeInterval</b>([<i>time</i>]) | ||
} | ||
``` | ||
@@ -125,0 +144,0 @@ If not specified, returns the current spiral generator, which defaults to the |
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
358933
10
158
0
107
1