npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

flot-pie

v1.0.0

Published

rehosting of the flot piechart plugin with adjustments for NPM

Downloads

111

Readme

flot-pie

Created by Brian Medendorp Updated with contributions from btburnett3, Anthony Aragues and Xavi Ivars

Note: I am not the developer or maintainer, I am setting it up for use on NPM.

Flot plugin for rendering pie charts.

Copyright (c) 2007-2014 IOLA and Ole Laursen. Licensed under the MIT license.

The plugin assumes that each series has a single data value, and that each value is a positive integer or zero. Negative numbers don't make sense for a pie chart, and have unpredictable results. The values do NOT need to be passed in as percentages; the plugin will calculate the total and per-slice percentages internally.

The plugin supports these options:

series: {
    pie: {
        show: true/false
        radius: 0-1 for percentage of fullsize, or a specified pixel length, or 'auto'
        innerRadius: 0-1 for percentage of fullsize or a specified pixel length, for creating a donut effect
        startAngle: 0-2 factor of PI used for starting angle (in radians) i.e 3/2 starts at the top, 0 and 2 have the same result
        tilt: 0-1 for percentage to tilt the pie, where 1 is no tilt, and 0 is completely flat (nothing will show)
        offset: {
            top: integer value to move the pie up or down
            left: integer value to move the pie left or right, or 'auto'
        },
        stroke: {
            color: any hexidecimal color value (other formats may or may not work, so best to stick with something like '#FFF')
            width: integer pixel width of the stroke
        },
        label: {
            show: true/false, or 'auto'
            formatter:  a user-defined function that modifies the text/style of the label text
            radius: 0-1 for percentage of fullsize, or a specified pixel length
            background: {
                color: any hexidecimal color value (other formats may or may not work, so best to stick with something like '#000')
                opacity: 0-1
            },
            threshold: 0-1 for the percentage value at which to hide labels (if they're too small)
        },
        combine: {
            threshold: 0-1 for the percentage value at which to combine slices (if they're too small)
            color: any hexidecimal color value (other formats may or may not work, so best to stick with something like '#CCC'), if null, the plugin will automatically use the color of the first slice to be combined
            label: any text value of what the combined slice should be labeled
        }
        highlight: {
            opacity: 0-1
        }
    }
}