-
Notifications
You must be signed in to change notification settings - Fork 184
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(all packages): missing options, package.json and lint fixes (#1849)
* fix(all packages): missing options, package.json fixes * chore(d3): was getting bundled previously therefore not needed as peer * fix(core): jsdoc comment * chore(prettier): add blank line * docs(core/model): JSDoc * test(core): update env * chore(core/vite/type): type should be PluginOption - not Plugin * chore(vite): explicitly set this as default is changing * chore(lint): minor adjustments for lint
- Loading branch information
1 parent
1bdbc11
commit a43f0eb
Showing
29 changed files
with
291 additions
and
610 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,67 @@ | ||
import type { AxisChartOptions } from './charts' | ||
|
||
/** | ||
* Represents tabular data for a chart. | ||
* Each record is an object where keys are strings and values can be of any type. | ||
* @type {Record<string, any>[]} | ||
*/ | ||
export type ChartTabularData = Record<string, any>[] | ||
|
||
/** | ||
* Configuration passed to the chart. | ||
* | ||
* Includes options and data | ||
* Includes options and data. | ||
*/ | ||
export interface ChartConfig<T extends AxisChartOptions> { | ||
/** | ||
* Chart options configuration. | ||
* @type {T} | ||
*/ | ||
options: T | ||
|
||
/** | ||
* Data for the chart. | ||
* @type {ChartTabularData} | ||
*/ | ||
data: ChartTabularData | ||
} | ||
|
||
/** | ||
* Represents a dataset used in a chart. | ||
*/ | ||
export interface DataSet { | ||
/** | ||
* Label for the dataset | ||
* Label for the dataset. | ||
* @type {string} | ||
*/ | ||
label: string | ||
|
||
/** | ||
* Array of hex background colors | ||
* Array of hex background colors. | ||
* @type {string[]} | ||
*/ | ||
fillColors: string[] | ||
|
||
/** | ||
* Array of data values | ||
* Array of data values. | ||
* @type {any[]} | ||
*/ | ||
data: any[] | ||
} | ||
|
||
/** | ||
* Represents the data structure for a chart. | ||
*/ | ||
export interface ChartData { | ||
/** | ||
* Labels for the x (horizontal) axis. Should match the number of items in each dataset data array | ||
* Labels for the x (horizontal) axis. Should match the number of items in each dataset data array. | ||
* @type {string[]} | ||
*/ | ||
labels: string[] | ||
|
||
/** | ||
* Array of datasets to display in the chart | ||
* Array of datasets to display in the chart. | ||
* @type {DataSet[]} | ||
*/ | ||
datasets: DataSet[] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.