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

angular-gage

v0.1.0

Published

angular-gage [![Build Status](https://travis-ci.org/frapontillo/angular-gage.png)](https://travis-ci.org/frapontillo/angular-gage) ===============

Downloads

431

Readme

angular-gage Build Status

AngularJS directive for the JustGage gauge.

Installation

$ bower install angular-gage

Usage

The directive tag is justgage, but you can also use it as an attribute or as a class name. angular-gage implements all of the original JustGage parameters via AngularJS binding:

  • title, gauge title text
  • titleFontColor, color of the title text
  • titleFontFamily, font-family of the title text
  • titlePosition, "above" or "below" the gauge
  • value, value to show
  • valueFontColor, color of the value text
  • valueFontFamily, font-family of the value text
  • width, gauge width
  • height, gauge height
  • relativeGaugeSize, true if the gauge has to grow with the container
  • min, minimum value
  • max, maximum value
  • valueMinFontSize, absolute minimum font size for the value
  • titleMinFontSize, absolute minimum font size for the title
  • labelMinFontSize, absolute minimum font size for the label
  • minLabelMinFontSize, absolute minimum font size for the minimum label
  • maxLabelMinFontSize, absolute minimum font size for the maximum label
  • hideValue, hide value text
  • hideMinMax, hide min and max values
  • hideInnerShadow, hide inner shadow
  • gaugeWidthScale, width of the gauge element
  • gaugeColor, background color of gauge element
  • showInnerShadow, true to display inner shadow
  • shadowOpacity, shadow opacity, values 0 ~ 1
  • shadowSize, inner shadow size
  • shadowVerticalOffset, how much is shadow offset from top
  • levelColors, array of strings, colors of indicator, from lower to upper, in hex format
  • customSectors, array of objects with color, hi, lo attributes
  • noGradient, true to use sector-based color change, false to use gradual color change
  • label, text to show below value
  • labelFontColor, color of label under the value
  • startAnimationTime, length of initial load animation
  • startAnimationType, type of initial animation (linear, >, <, <>, bounce)
  • refreshAnimationTime, length of refresh animation
  • refreshAnimationType type of refresh animation (linear, >, <, <>, bounce)
  • donut, turn the gauge into a full circle donut
  • donutStartAngle, angle to start from when in donut mode
  • reverse, if true, max and min are swapped (with max appearing on the left, min on the right)
  • counter, increase numbers one by one
  • decimals, quantity of decimal numbers to show
  • symbol, unit of measure that will be appended to value
  • formatNumber, whether to format numbers
  • humanFriendly, true to show shorthand big numbers (300K instead of 300XXX)
  • humanFriendlyDecimal, number of decimal places for our human friendly number to contain
  • textRenderer, function applied before rendering text

When parameters are not set or they are undefined, the behavior of JustGage is to assume they are not set; therefore, the default values will be loaded.

You can check out the demo at demo/index.html.

Development

To build your own version, use grunt:

$ npm install -g grunt-cli bower karma
$ npm install
$ bower install
$ grunt

Contribute

To contribute, please follow the generic AngularJS Contributing Guidelines, with the only exception to send the PR to the develop branch instead of master.

Before committing and requesting a PR, please make sure that your build succeeds.

##Author

Francesco Pontillo (mailto:[email protected])

##License

   Copyright 2014 Francesco Pontillo

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

     http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.