From 1912f4b457744b53e87f526dd493ccb4bf3594c4 Mon Sep 17 00:00:00 2001 From: Jason Davies Date: Thu, 12 Jan 2017 15:37:13 +0000 Subject: [PATCH] Update to d3-dispatch version 1.x. --- index.js | 4 ++-- package.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/index.js b/index.js index ffae380..c06db09 100644 --- a/index.js +++ b/index.js @@ -62,7 +62,7 @@ module.exports = function() { cloudSprite(contextAndRatio, d, data, i); if (d.hasText && place(board, d, bounds)) { tags.push(d); - event.word(d); + event.call("word", cloud, d); if (bounds) cloudBounds(bounds, d); else bounds = [{x: d.x + d.x0, y: d.y + d.y0}, {x: d.x + d.x1, y: d.y + d.y1}]; // Temporary hack @@ -72,7 +72,7 @@ module.exports = function() { } if (i >= n) { cloud.stop(); - event.end(tags, bounds); + event.call("end", cloud, tags, bounds); } } } diff --git a/package.json b/package.json index 5e46ff2..6cc3eed 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "d3-cloud", - "version": "1.2.2", + "version": "1.2.3", "description": "Generate word clouds in JavaScript.", "keywords": [ "word", @@ -24,7 +24,7 @@ "build": "mkdir -p build && browserify --standalone d3.layout.cloud index.js > build/d3.layout.cloud.js" }, "dependencies": { - "d3-dispatch": "0.2.x" + "d3-dispatch": "1" }, "devDependencies": { "browserify": "^11.2.0"