Giter VIP home page Giter VIP logo

Comments (7)

timdream avatar timdream commented on July 26, 2024 1

I ended up implementing the idea 2. Idea 1 is implemented only until this year but hover/click handler was not bind on DOM elements yet -- pull request welcome.

Ah ok, I get it, the $ is just your shorthand for "this is a jquery element"?

Yes. The code in index.html is independent of the library.

from wordcloud2.js.

timdream avatar timdream commented on July 26, 2024

Ideas:

  1. Expose info on wordclouddrawn so people could reconstruct the cloud with DOM or SVG. Maybe have an option to "draw" the cloud in DOM or SVG in this library.
  2. allow specifying hover or click callbacks on the library options.

from wordcloud2.js.

timdream avatar timdream commented on July 26, 2024

WIP patch done.

from wordcloud2.js.

foobarbecue avatar foobarbecue commented on July 26, 2024

Click does not work on http://timdream.org/wordcloud2.js/#web-tech when it's set to Elements rather than Canvas. In my own project, I can't seem to get click or hover to work in Elements or in Canvas. More examples and / or docs would be very helpful. I don't get what's going on in the window.drawBox function... what is $box?

from wordcloud2.js.

foobarbecue avatar foobarbecue commented on July 26, 2024

Some more useful info. I'm getting hundreds of these on mouseover:

ReferenceError: canvas is not defined
var rect = canvas.getBoundingClientRect();
wordcloud2.js (line 351)

Am using Firefox 25.0 . By the way, thanks for all the amazing work! What a fantastic library.

from wordcloud2.js.

foobarbecue avatar foobarbecue commented on July 26, 2024

Ah ok, I get it, the $ is just your shorthand for "this is a jquery element"?

from wordcloud2.js.

foobarbecue avatar foobarbecue commented on July 26, 2024

Ah ok, thanks... looks like something I might be able to do! If I can find the time I will.

from wordcloud2.js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.