# ChartOptions Interface

> ChartOptions interface in the browser TypeScript API: Validated chart type, data, appearance and worksheet placement used for insertion or updates.

- **Product:** TX Sheet Control
- **Section:** Documentation
- **Kind:** Interface
- **Path:** TX Sheet Control > API Reference > TypeScript API > Browser Editor > ChartOptions Interface
- **1000 words**
- **Web URL:** https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/
- **LLMs URL:** https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/llms-full.txt

---

Validated chart type, data, appearance and worksheet placement used for insertion or updates.

Package: `@txtextcontrol/tx-sheet-control`. Version: **2.0.0**.

Type-only declaration; it is not a JavaScript runtime constructor.

### Members

#### Properties

| Property | Description |
|---|---|
| [axisTitles](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/axistitles-property/llms-full.txt) | The axisTitles value of ChartOptions. |
| [colors](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/colors-property/llms-full.txt) | The colors value of ChartOptions. |
| [dataRange](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/datarange-property/llms-full.txt) | The dataRange value of ChartOptions. |
| [elements](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/elements-property/llms-full.txt) | The elements value of ChartOptions. |
| [filters](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/filters-property/llms-full.txt) | The filters value of ChartOptions. |
| [id](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/id-property/llms-full.txt) | The id value of ChartOptions. |
| [legend](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/legend-property/llms-full.txt) | The legend value of ChartOptions. |
| [origin](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/origin-property/llms-full.txt) | The origin value of ChartOptions. |
| [position](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/position-property/llms-full.txt) | The position value of ChartOptions. |
| [series](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/series-property/llms-full.txt) | The series value of ChartOptions. |
| [seriesOrientation](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/seriesorientation-property/llms-full.txt) | The seriesOrientation value of ChartOptions. |
| [style](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/style-property/llms-full.txt) | The style value of ChartOptions. |
| [title](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/title-property/llms-full.txt) | The title value of ChartOptions. |
| [type](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/type-property/llms-full.txt) | The type value of ChartOptions. |
| [presentation](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/presentation-property/llms-full.txt) | Configure chart layout, independent axes and native labels. |

### Examples

Use a fresh workbook. Create and format the sample data, apply this API and retain the returned document or result in your application. In the browser pass editor.workbook; in Node.js pass the server control.

```typescript
import type { Workbook } from '@txtextcontrol/tx-sheet-control';
import type { ChartOptions } from '@txtextcontrol/tx-sheet-control';

function createChartOptionsReport(book: Workbook) {
    const sheet = book.sheets.at(0);
    sheet.range('A1:B5').setValues([
        ['Region', 'Revenue'],
        ['North', 42000],
        ['South', 38500],
        ['East', 31200],
        ['West', 44900],
    ]);

    const chart = sheet.charts.add({
        type: 'column',
        title: 'Revenue by region',
        dataRange: 'A1:B5',
        anchor: { cell: 'D2' },
        size: { width: 480, height: 240 },
    });

    const chartSettings: ChartOptions = { id: chart.id };
    chart.update(chartSettings);
    return sheet;
}
```

### See Also

- [TypeScript Browser Editor API](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/llms-full.txt)
- [Charts and Sparklines](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/charts/llms-full.txt)

---

## In This Section

- [ChartOptions.axisTitles Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/axistitles-property/llms-full.txt): ChartOptions.axisTitles property in the browser TypeScript API, with its type { horizontal: string; vertical: string; } | undefined and a TypeScript example.
- [ChartOptions.colors Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/colors-property/llms-full.txt): ChartOptions.colors property in the TX Sheet Control TypeScript API for the browser, with its type string[] | undefined and a TypeScript example.
- [ChartOptions.dataRange Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/datarange-property/llms-full.txt): ChartOptions.dataRange property in the TX Sheet Control TypeScript API for the browser, with its type string | undefined and a TypeScript example.
- [ChartOptions.elements Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/elements-property/llms-full.txt): ChartOptions.elements property in the TX Sheet Control TypeScript API for the browser, with its type ChartElements | undefined and a TypeScript example.
- [ChartOptions.filters Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/filters-property/llms-full.txt): ChartOptions.filters property in the TX Sheet Control TypeScript API for the browser, with its syntax and a TypeScript example.
- [ChartOptions.id Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/id-property/llms-full.txt): ChartOptions.id property in the TX Sheet Control TypeScript API for the browser, with its type string | undefined and a TypeScript example.
- [ChartOptions.legend Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/legend-property/llms-full.txt): ChartOptions.legend property in the browser TypeScript API, with its type "left" | "right" | "top" | "bottom" | "none" | undefined and a TypeScript example.
- [ChartOptions.origin Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/origin-property/llms-full.txt): ChartOptions.origin property in the browser TypeScript API, with its type { sheetId: string; chartId: string; } | undefined and a TypeScript example.
- [ChartOptions.position Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/position-property/llms-full.txt): ChartOptions.position property in the browser TypeScript API, with its type Partial<ChartPosition> | undefined and a TypeScript example.
- [ChartOptions.presentation Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/presentation-property/llms-full.txt): ChartOptions.presentation property in the browser TypeScript API, with its type ChartAppearance['presentation'] and a TypeScript example.
- [ChartOptions.series Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/series-property/llms-full.txt): ChartOptions.series property in the TX Sheet Control TypeScript API for the browser, with its type ChartSeries[] | undefined and a TypeScript example.
- [ChartOptions.seriesOrientation Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/seriesorientation-property/llms-full.txt): ChartOptions.seriesOrientation property in the browser TypeScript API, with its type "columns" | "rows" | undefined and a TypeScript example.
- [ChartOptions.style Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/style-property/llms-full.txt): ChartOptions.style property in the TX Sheet Control TypeScript API for the browser, with its syntax and a TypeScript example.
- [ChartOptions.title Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/title-property/llms-full.txt): ChartOptions.title property in the TX Sheet Control TypeScript API for the browser, with its type string | undefined and a TypeScript example.
- [ChartOptions.type Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/type-property/llms-full.txt): ChartOptions.type property in the TX Sheet Control TypeScript API for the browser, with its type string | undefined and a TypeScript example.

---

## Nearby

- **Previous:** [ChartObjectOptions.presentation Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartobjectoptions/presentation-property/llms-full.txt)
- **Next:** [ChartOptions.axisTitles Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/chartoptions/axistitles-property/llms-full.txt)
