@chameleon-ds/chart

2.0.1 • Public • Published

Chameleon Chart

import { html } from "@open-wc/demoing-storybook";
import { withKnobs, text, number } from "@open-wc/demoing-storybook";
import "./chameleon-chart.js";

export default {
  title: "Components|Data and Visualizations/Chart",
  component: "chameleon-chart",
  decorators: [withKnobs],
  options: { selectedPanel: "storybookjs/docs/panel" },
};

Properties

Property Name Type(s) Default Value Description
type String "" The type of chart
color String "#00870a" The hex value of the chart color
percentage Number 0 The percentage to be displayed in the chart
label String "0" The value to show in the label
subLabel String "" The value to show in the sublabel

Examples

Default

export const Default = () => {
  const color = text("Color", "#00870a");
  const label = text("Label", "1,000");
  const subLabel = text("SubLabel", "Funds Remaining");
  const percentage = number("Percentage", 90);

  return html`
    <chameleon-chart
      color="${color}"
      percentage="${percentage}"
      label="${label}"
      subLabel="${subLabel}"
      type="arc"
    ></chameleon-chart>
  `;
};

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 2.0.1
    1
    • latest

Version History

Package Sidebar

Install

npm i @chameleon-ds/chart

Weekly Downloads

1

Version

2.0.1

License

MIT

Unpacked Size

20.3 kB

Total Files

7

Last publish

Collaborators

  • chuckhousley
  • zemptime
  • mandymichel
  • olerk16
  • tfreiner
  • kewalter
  • ryuhhnn