Code Monkey home page Code Monkey logo

d3_water_drop_chart's Introduction

D3 Water Drop Chart

D3 Water Drop Chart is a very simple chart created with a single stacked bar chart inside a Water Drop body.

Sample

D3 Water Drop Chart Sample

Github mascot Chart Sample

Have a look in this github page to see it in action.

Getting Started

Download the package, and include the dist/ng-content-editable.min.js file in your page.

Via bower

bower install d3_water_drop_chart --save

Usage

Include the Water Drop's Javascript and Stylesheet in your HTML

<script src="d3_water_drop_chart.js" type="text/javascript"></script>
<link href="d3_water_drop_chart.css"  rel="stylesheet" type="text/css">

Define HTML div to be the chart container

<div class='water-drop-chart-container'></div>

JavaScript initialize chart

<script language="javascript">
  startWaterDropChart(".water-drop-chart-container", [
    {
      x: 0,
      y: 0.51,
      label: "diesel",
      color: "#83ba43"
    },
    {
      x: 0,
      y: 0.21,
      label: "gasoline",
      color: "#4370ba"
    },
    {
      x: 0,
      y: 0.28,
      label: "ethanol",
      color: "#fbac1c"
    }
  ], {
      width: 133,
      height: 190,
      mouseoverColor: "#6B486B",
      maskSvg: "github-icon.svg"
  })
</script>

Dependencies

  • D3 version 3.5.*

d3_water_drop_chart's People

Contributors

antonioams avatar vitormargis avatar tiagogoncalves89 avatar leandro-cervelin avatar

Watchers

 avatar James Cloos avatar Rodrigo Brito avatar

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.