@moderneinc/react-charts 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Default color palette for parlament charts.
3
+ * These colors can be overridden by providing a custom theme to the ParliamentChart component.
4
+ */
5
+ export declare const DEFAULT_CHART_COLORS: {
6
+ /** Grey color palette for neutral states */
7
+ readonly neoGrey: {
8
+ readonly 200: "#EDEFEF";
9
+ readonly 400: "#ADB5BD";
10
+ };
11
+ /** Green color palette for success/completion states */
12
+ readonly neoDigitalGreen: {
13
+ readonly 600: "#40c048";
14
+ };
15
+ };
16
+ /**
17
+ * Color configuration type for parliament chart theming
18
+ */
19
+ export type ParliamentChartColors = typeof DEFAULT_CHART_COLORS;
20
+ /**
21
+ * Theme configuration interface for parliament charts.
22
+ * Allows consumers to override default colors while maintaining type safety.
23
+ */
24
+ export interface ParliamentChartTheme {
25
+ colors?: Partial<ParliamentChartColors>;
26
+ }
27
+ /**
28
+ * Merges custom theme colors with default colors
29
+ */
30
+ export declare function mergeThemeColors(customColors?: Partial<ParliamentChartColors>): ParliamentChartColors;
package/package.json ADDED
@@ -0,0 +1,112 @@
1
+ {
2
+ "name": "@moderneinc/react-charts",
3
+ "version": "1.1.0",
4
+ "description": "Parliament chart visualization library for React",
5
+ "type": "module",
6
+ "devEngines": {
7
+ "runtime": {
8
+ "name": "node",
9
+ "version": "22.16.0",
10
+ "onFail": "warn"
11
+ }
12
+ },
13
+ "main": "./dist/index.cjs",
14
+ "module": "./dist/index.js",
15
+ "types": "./dist/index.d.ts",
16
+ "files": [
17
+ "dist"
18
+ ],
19
+ "exports": {
20
+ ".": {
21
+ "types": "./dist/index.d.ts",
22
+ "import": "./dist/index.js",
23
+ "require": "./dist/index.cjs"
24
+ }
25
+ },
26
+ "scripts": {
27
+ "dev": "vite",
28
+ "build": "tsc --noEmit && vite build",
29
+ "test": "vitest",
30
+ "test:ui": "vitest --ui",
31
+ "storybook": "storybook dev -p 6006",
32
+ "build-storybook": "storybook build",
33
+ "check:all": "npm run format && npm run check:lint:fix && npm run check:lint && npm run check:types && npm run test",
34
+ "check:lint:fix": "npm run check:biome:fix",
35
+ "check:lint": "npm run check:biome",
36
+ "check:biome:fix": "biome check --write",
37
+ "check:biome": "biome check",
38
+ "check:types": "tsc --noEmit",
39
+ "format:check": "biome format .",
40
+ "format": "biome format --write .",
41
+ "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
42
+ "preview": "vite preview",
43
+ "release": "semantic-release"
44
+ },
45
+ "peerDependencies": {
46
+ "@emotion/react": ">=11.0.0",
47
+ "@emotion/styled": ">=11.0.0",
48
+ "@mui/icons-material": ">=7.0.0",
49
+ "@mui/material": ">=7.0.0",
50
+ "react": "^18.0.0 || ^19.0.0",
51
+ "react-dom": "^18.0.0 || ^19.0.0"
52
+ },
53
+ "dependencies": {
54
+ "hast-util-to-html": "^9.0.5",
55
+ "hastscript": "^9.0.1",
56
+ "sainte-lague": "^3.0.0"
57
+ },
58
+ "devDependencies": {
59
+ "@biomejs/biome": "^2.2.0",
60
+ "@emotion/react": "^11.14.0",
61
+ "@emotion/styled": "^11.14.0",
62
+ "@mui/icons-material": "^7.3.2",
63
+ "@mui/material": "^7.3.2",
64
+ "@semantic-release/changelog": "^6.0.3",
65
+ "@semantic-release/git": "^10.0.1",
66
+ "@storybook/addon-a11y": "^8.4.7",
67
+ "@storybook/addon-essentials": "^8.4.7",
68
+ "@storybook/addon-interactions": "^8.4.7",
69
+ "@storybook/addon-links": "^8.4.7",
70
+ "@storybook/addon-themes": "^8.4.7",
71
+ "@storybook/blocks": "^8.4.7",
72
+ "@storybook/react": "^8.4.7",
73
+ "@storybook/react-vite": "^8.4.7",
74
+ "@storybook/test": "^8.4.7",
75
+ "@types/react": "^18.3.0",
76
+ "@types/react-dom": "^18.3.0",
77
+ "@typescript-eslint/eslint-plugin": "^8.44.0",
78
+ "@typescript-eslint/parser": "^8.44.0",
79
+ "@vitejs/plugin-react": "^4.3.4",
80
+ "@vitest/ui": "^2.1.8",
81
+ "eslint": "^9.36.0",
82
+ "eslint-plugin-react-hooks": "^5.1.0",
83
+ "eslint-plugin-react-refresh": "^0.4.16",
84
+ "eslint-plugin-storybook": "^0.11.1",
85
+ "jsdom": "^27.0.0",
86
+ "react": "^19.1.1",
87
+ "react-dom": "^19.1.1",
88
+ "semantic-release": "^24.2.0",
89
+ "storybook": "^8.4.7",
90
+ "typescript": "^5.9.2",
91
+ "vite": "^6.0.11",
92
+ "vite-plugin-dts": "^4.4.3",
93
+ "vitest": "^2.1.8"
94
+ },
95
+ "publishConfig": {
96
+ "access": "public",
97
+ "registry": "https://registry.npmjs.org"
98
+ },
99
+ "repository": {
100
+ "type": "git",
101
+ "url": "https://github.com/moderneinc/moderne-react-charts.git"
102
+ },
103
+ "keywords": [
104
+ "react",
105
+ "charts",
106
+ "parliament",
107
+ "visualization",
108
+ "mui"
109
+ ],
110
+ "author": "Moderne",
111
+ "license": "MIT"
112
+ }