# @domoinc/ca-cloud-number

> CACloudNumber - Domo Widget

Latest version **2.0.2** (published 2016-03-07) · SEE LICENSE IN LICENSE license · 0 weekly downloads

## Install

```sh
npm install @domoinc/ca-cloud-number
pnpm add @domoinc/ca-cloud-number
yarn add @domoinc/ca-cloud-number
bun add @domoinc/ca-cloud-number
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.2 |
| Published | 2016-03-07 |
| First published | 2016-02-03 |
| Weekly downloads | 0 |
| License | SEE LICENSE IN LICENSE |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 5 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Domo Inc. |
| Maintainers | aharris88, andrewjensen, bkingery, bmbarker-domo, clm, dallasnorton, excrispy, jaxry, jgalb, jmstewart, jonathan-law, k4paul, morganjohn12, nicksrandall, scott.davidson.domo |
| Keywords | domo, app |

## Links

- npm: https://www.npmjs.com/package/@domoinc/ca-cloud-number
- npm.io page: https://npm.io/package/@domoinc/ca-cloud-number

## Dependencies (5)

- [d3](https://npm.io/package/d3.md) ^3.5.14
- [d3.chart](https://npm.io/package/d3.chart.md) ^0.3.0
- [@domoinc/da-theme2](https://npm.io/package/@domoinc/da-theme2.md) ^2.3.0
- [@domoinc/base-widget](https://npm.io/package/@domoinc/base-widget.md) ^1.4.1
- [@domoinc/arrow-single-value-indicator](https://npm.io/package/@domoinc/arrow-single-value-indicator.md) ^5.0.5

## Recent versions

- 2.0.2 (latest) — 2016-03-07
- 2.0.1 — 2016-02-09
- 2.0.0 — 2016-02-03

## README

# CACloudNumber



<img src=media/widget.png height=500 width=500> 

## Configuration Options


#### chartName
Type: `string`  
Default: `CACloudNumber`  

Name of chart for reporting

#### fontSize
Type: `number`  
Default: `48`  
Units: `px`

Font size of the text

#### height
Type: `number`  
Default: `250`  

Height of the chart

#### indicatorColor
Type: `color`  
Default: `#73B0D7`  

Text color of the number

#### postfixString
Type: `string`  
Default: `%`  

Suffix to be appended to the end of the number

#### prefixString
Type: `string`  
Default: ``  

Prefix to be appended to the front of the number

#### shouldValidate
Type: `boolean`  
Default: `true`  

Flag for turning off data validation.

#### textFontFamily
Type: `string`  
Default: `Open Sans`  

Font family for any text.

#### updateSizeableConfigs
Type: `boolean`  
Default: `true`  

Flag for turning off the mimic of illustrator's scale functionality.

#### width
Type: `number`  
Default: `250`  

Width of the chart

## Data Definition


#### Date
Type: `date`

Default validate:  
```js
function (d) { return new Date(this.accessor(d)) !== 'Invalid Date'; }
```

Default accessor:  
```js
function (line) { return line[2]; }
```

#### Label
Type: `string`

Default validate:  
```js
function (d) { return this.accessor(d) !== undefined; }
```

Default accessor:  
```js
function (line) { return line[0] === undefined ? undefined : String(line[0]); }
```

#### Value
Type: `number`

Default validate:  
```js
function (d) { return !isNaN(this.accessor(d)) && this.accessor(d) >= 0; }
```

Default accessor:  
```js
function (line) { return Number(line[1]); }
```

## Events


#### Dispatch Events

#### External Events


## Example

```js  
//Setup some fake data
var data = [
  ['Name', 45]
];

//Initialze the widget
var chart = d3.select("#vis")
  .select('svg')
  .append("g")
  .attr('transform', 'translate(250,264)')
  .chart("CACloudNumber")
  .c({
    width: 183,
    height: 104
  });

//Render the chart with data
chart._notifier.showMessage(true);
chart.draw(data);
```

---
_Source: https://npm.io/package/@domoinc/ca-cloud-number · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
