bubble-chart-js 1.0.19 → 2.0.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.
- package/README.md +1 -1
- package/demo/glassmorphism.html +323 -0
- package/demo/index.html +739 -0
- package/dist/bubbleChart.cjs.js +1 -1
- package/dist/bubbleChart.esm.js +1 -1
- package/dist/bubbleChart.umd.js +1 -1
- package/docs/documentation.html +438 -0
- package/docs/examples.html +689 -0
- package/docs/index.html +432 -0
- package/docs/landing_test.html +337 -0
- package/docs/playground.html +345 -0
- package/docs/process_html.js +105 -0
- package/docs/temp/5a86d.html +248 -0
- package/docs/temp/b0cbe.html +276 -0
- package/docs/temp/docs_desktop.html +341 -0
- package/docs/temp/docs_mobile.html +291 -0
- package/docs/temp/examples_desktop.html +372 -0
- package/docs/temp/examples_mobile.html +317 -0
- package/docs/temp/landing_desktop.html +337 -0
- package/docs/temp/landing_mobile.html +270 -0
- package/docs/temp/playground_desktop.html +283 -0
- package/docs/temp/playground_mobile.html +236 -0
- package/examples/test.html +194 -0
- package/examples/test2.html +103 -0
- package/package.json +7 -3
- package/scripts/generate-fixtures.ts +45 -0
- package/spec/config-defaults.json +16 -0
- package/spec/fixtures/3-bubbles.expected.json +27 -0
- package/spec/fixtures/3-bubbles.input.json +10 -0
- package/spec/fixtures/equal-values.expected.json +34 -0
- package/spec/fixtures/equal-values.input.json +11 -0
- package/spec/fixtures/many-bubbles.expected.json +76 -0
- package/spec/fixtures/many-bubbles.input.json +17 -0
- package/spec/fixtures/single-bubble.expected.json +13 -0
- package/spec/fixtures/single-bubble.input.json +8 -0
- package/spec/physics.json +11 -0
- package/tsconfig.scripts.json +8 -0
- package/dist/canvas.d.ts +0 -5
- package/dist/constants/app-constants.d.ts +0 -3
- package/dist/constants/physics.d.ts +0 -10
- package/dist/core/renderer.d.ts +0 -2
- package/dist/features/text-wrapper.d.ts +0 -2
- package/dist/features/tooltip.d.ts +0 -6
- package/dist/index.d.ts +0 -8
- package/dist/models/internal/data-item-info.d.ts +0 -7
- package/dist/models/public/bubble-chart.d.ts +0 -6
- package/dist/models/public/config/bubble-appearance.d.ts +0 -26
- package/dist/models/public/config/font-options.d.ts +0 -46
- package/dist/models/public/config/interaction-options.d.ts +0 -6
- package/dist/models/public/config/tooltip-config.d.ts +0 -4
- package/dist/models/public/config/tooltip-options.d.ts +0 -170
- package/dist/models/public/configuration.d.ts +0 -30
- package/dist/models/public/data-item.d.ts +0 -8
- package/dist/services/chart-service.d.ts +0 -5
- package/dist/services/render-service.d.ts +0 -3
- package/dist/utils/config.d.ts +0 -12
- package/dist/utils/helper.d.ts +0 -2
- package/dist/utils/validation.d.ts +0 -5
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Defines the appearance properties for a bubble.
|
|
3
|
-
*/
|
|
4
|
-
export interface BubbleAppearance {
|
|
5
|
-
/**
|
|
6
|
-
* Bubble background color
|
|
7
|
-
* @default "#3498DB"
|
|
8
|
-
*/
|
|
9
|
-
bubbleColor?: string;
|
|
10
|
-
/**
|
|
11
|
-
* Border thickness (in pixels)
|
|
12
|
-
* @default 0.25
|
|
13
|
-
*/
|
|
14
|
-
borderThickness?: number;
|
|
15
|
-
/**
|
|
16
|
-
* Border color
|
|
17
|
-
* @default "black"
|
|
18
|
-
*/
|
|
19
|
-
borderColor?: string;
|
|
20
|
-
/**
|
|
21
|
-
* Opacity level (0: transparent, 1: fully visible)
|
|
22
|
-
* @validValues 0 - 1
|
|
23
|
-
* @default 1
|
|
24
|
-
*/
|
|
25
|
-
opacity?: number;
|
|
26
|
-
}
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Defines the font-related styling options.
|
|
3
|
-
*/
|
|
4
|
-
export interface FontOptions {
|
|
5
|
-
/**
|
|
6
|
-
* Custom font family
|
|
7
|
-
* @example "Arial", "Verdana"
|
|
8
|
-
* @default "Arial"
|
|
9
|
-
*/
|
|
10
|
-
fontFamily?: string;
|
|
11
|
-
/**
|
|
12
|
-
* Font style
|
|
13
|
-
* @validValues "normal" | "italic" | "oblique"
|
|
14
|
-
* @default "normal"
|
|
15
|
-
*/
|
|
16
|
-
fontStyle?: "normal" | "italic" | "oblique";
|
|
17
|
-
/**
|
|
18
|
-
* Font weight (numeric scale)
|
|
19
|
-
* @validValues 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900
|
|
20
|
-
* @default 400
|
|
21
|
-
*/
|
|
22
|
-
fontWeight?: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900;
|
|
23
|
-
/**
|
|
24
|
-
* Text alignment
|
|
25
|
-
* @validValues "center" | "end" | "left" | "right" | "start"
|
|
26
|
-
* @default "center"
|
|
27
|
-
*/
|
|
28
|
-
textAlign?: "center" | "end" | "left" | "right" | "start";
|
|
29
|
-
/**
|
|
30
|
-
* Text transformation style
|
|
31
|
-
* @validValues "none" | "uppercase" | "lowercase" | "capitalize"
|
|
32
|
-
* @default "none"
|
|
33
|
-
*/
|
|
34
|
-
textTransform?: "none" | "uppercase" | "lowercase" | "capitalize";
|
|
35
|
-
/**
|
|
36
|
-
* Font color
|
|
37
|
-
* @default "#000000"
|
|
38
|
-
*/
|
|
39
|
-
fontColor?: string;
|
|
40
|
-
/**
|
|
41
|
-
* Text baseline position
|
|
42
|
-
* @validValues "alphabetic" | "bottom" | "hanging" | "ideographic" | "middle" | "top"
|
|
43
|
-
* @default "middle"
|
|
44
|
-
*/
|
|
45
|
-
textBaseline?: "alphabetic" | "bottom" | "hanging" | "ideographic" | "middle" | "top";
|
|
46
|
-
}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export interface InteractionOptions {
|
|
2
|
-
showToolTip?: boolean;
|
|
3
|
-
isResizeCanvasOnWindowSizeChange?: boolean;
|
|
4
|
-
cursorType?: "default" | "pointer" | "grab" | "crosshair" | "move" | "not-allowed" | "help";
|
|
5
|
-
onBubbleClick?: (bubbleData: any, event: MouseEvent) => void;
|
|
6
|
-
}
|
|
@@ -1,170 +0,0 @@
|
|
|
1
|
-
export interface TooltipOptions {
|
|
2
|
-
/**
|
|
3
|
-
* CSS font-family property
|
|
4
|
-
* @default "Arial, sans-serif"
|
|
5
|
-
*/
|
|
6
|
-
fontFamily?: string;
|
|
7
|
-
/**
|
|
8
|
-
* Font style for tooltip text
|
|
9
|
-
* @validValues "normal", "italic", "oblique"
|
|
10
|
-
* @default "normal"
|
|
11
|
-
*/
|
|
12
|
-
fontStyle?: "normal" | "italic" | "oblique";
|
|
13
|
-
/**
|
|
14
|
-
* Font weight (numeric scale)
|
|
15
|
-
* @validValues 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900
|
|
16
|
-
* @default 400
|
|
17
|
-
*/
|
|
18
|
-
fontWeight?: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900;
|
|
19
|
-
/**
|
|
20
|
-
* Font size in pixels
|
|
21
|
-
* @default 14
|
|
22
|
-
*/
|
|
23
|
-
fontSize?: number;
|
|
24
|
-
/**
|
|
25
|
-
* Text alignment within tooltip
|
|
26
|
-
* @validValues "left", "center", "right"
|
|
27
|
-
* @default "left"
|
|
28
|
-
*/
|
|
29
|
-
textAlign?: "left" | "center" | "right";
|
|
30
|
-
/**
|
|
31
|
-
* Text decoration style
|
|
32
|
-
* @validValues "none", "underline", "line-through", "overline"
|
|
33
|
-
* @default "none"
|
|
34
|
-
*/
|
|
35
|
-
textDecoration?: "none" | "underline" | "line-through" | "overline";
|
|
36
|
-
/**
|
|
37
|
-
* Text transformation style
|
|
38
|
-
* @validValues "none", "uppercase", "lowercase", "capitalize"
|
|
39
|
-
* @default "none"
|
|
40
|
-
*/
|
|
41
|
-
textTransform?: "none" | "uppercase" | "lowercase" | "capitalize";
|
|
42
|
-
/**
|
|
43
|
-
* Letter spacing in pixels (0 = normal)
|
|
44
|
-
* @default undefined (normal spacing)
|
|
45
|
-
*/
|
|
46
|
-
letterSpacing?: number;
|
|
47
|
-
/**
|
|
48
|
-
* Text color in CSS format
|
|
49
|
-
* @default "white"
|
|
50
|
-
*/
|
|
51
|
-
fontColor?: string;
|
|
52
|
-
/**
|
|
53
|
-
* Background color in CSS format
|
|
54
|
-
* @default "rgba(0, 0, 0, 0.85)"
|
|
55
|
-
*/
|
|
56
|
-
backgroundColor?: string;
|
|
57
|
-
/**
|
|
58
|
-
* Border color in CSS format
|
|
59
|
-
* @default "transparent"
|
|
60
|
-
*/
|
|
61
|
-
borderColor?: string;
|
|
62
|
-
/**
|
|
63
|
-
* Border style (requires borderWidth to be set)
|
|
64
|
-
* @validValues "solid", "dashed", "dotted", "double", "none"
|
|
65
|
-
* @default "none"
|
|
66
|
-
*/
|
|
67
|
-
borderStyle?: "solid" | "dashed" | "dotted" | "double" | "none";
|
|
68
|
-
/**
|
|
69
|
-
* Border width (CSS value or number in pixels)
|
|
70
|
-
* @example "2px", "0.5rem", 3
|
|
71
|
-
*/
|
|
72
|
-
borderWidth?: string | number;
|
|
73
|
-
/**
|
|
74
|
-
* CSS padding value
|
|
75
|
-
* @example "10px", "1em 2rem", "5% 10px"
|
|
76
|
-
* @default "8px"
|
|
77
|
-
*/
|
|
78
|
-
padding?: string | number;
|
|
79
|
-
/**
|
|
80
|
-
* CSS margin value
|
|
81
|
-
* @example "10px auto", "2rem 1rem"
|
|
82
|
-
* @default "0"
|
|
83
|
-
*/
|
|
84
|
-
margin?: string | number;
|
|
85
|
-
/**
|
|
86
|
-
* CSS box-shadow property
|
|
87
|
-
* @example "3px 3px 5px rgba(0,0,0,0.3)"
|
|
88
|
-
* @default "none"
|
|
89
|
-
*/
|
|
90
|
-
boxShadow?: string;
|
|
91
|
-
/**
|
|
92
|
-
* Opacity value (0 = fully transparent, 1 = fully opaque)
|
|
93
|
-
* @minimum 0
|
|
94
|
-
* @maximum 1
|
|
95
|
-
* @default 1
|
|
96
|
-
*/
|
|
97
|
-
opacity?: number;
|
|
98
|
-
/**
|
|
99
|
-
* Maximum width in pixels
|
|
100
|
-
* @default 200
|
|
101
|
-
*/
|
|
102
|
-
maxWidth?: number;
|
|
103
|
-
/**
|
|
104
|
-
* Minimum width in pixels
|
|
105
|
-
* @default undefined (auto)
|
|
106
|
-
*/
|
|
107
|
-
minWidth?: number;
|
|
108
|
-
/**
|
|
109
|
-
* Maximum height in pixels
|
|
110
|
-
* @default undefined (none)
|
|
111
|
-
*/
|
|
112
|
-
maxHeight?: number;
|
|
113
|
-
/**
|
|
114
|
-
* Minimum height in pixels
|
|
115
|
-
* @default undefined (auto)
|
|
116
|
-
*/
|
|
117
|
-
minHeight?: number;
|
|
118
|
-
/**
|
|
119
|
-
* Preferred position relative to target element
|
|
120
|
-
* @validValues "top", "bottom", "left", "right"
|
|
121
|
-
*/
|
|
122
|
-
position?: "top" | "bottom" | "left" | "right";
|
|
123
|
-
/**
|
|
124
|
-
* Horizontal offset in pixels
|
|
125
|
-
* @default 0
|
|
126
|
-
*/
|
|
127
|
-
offsetX?: number;
|
|
128
|
-
/**
|
|
129
|
-
* Vertical offset in pixels
|
|
130
|
-
* @default 0
|
|
131
|
-
*/
|
|
132
|
-
offsetY?: number;
|
|
133
|
-
/**
|
|
134
|
-
* CSS z-index property
|
|
135
|
-
* @default 1000
|
|
136
|
-
*/
|
|
137
|
-
zIndex?: number;
|
|
138
|
-
/**
|
|
139
|
-
* CSS pointer-events property
|
|
140
|
-
* @validValues "auto", "none"
|
|
141
|
-
* @default "none"
|
|
142
|
-
*/
|
|
143
|
-
pointerEvents?: "auto" | "none";
|
|
144
|
-
/**
|
|
145
|
-
* Enable/disable animations
|
|
146
|
-
* @default true
|
|
147
|
-
*/
|
|
148
|
-
animation?: boolean;
|
|
149
|
-
/**
|
|
150
|
-
* Animation duration in milliseconds
|
|
151
|
-
* @default 300
|
|
152
|
-
*/
|
|
153
|
-
animationDuration?: number;
|
|
154
|
-
/**
|
|
155
|
-
* CSS backdrop-filter property
|
|
156
|
-
* @example "blur(5px)"
|
|
157
|
-
* @default "none"
|
|
158
|
-
*/
|
|
159
|
-
backdropFilter?: string;
|
|
160
|
-
/**
|
|
161
|
-
* CSS transition property
|
|
162
|
-
* @default "opacity 0.2s"
|
|
163
|
-
*/
|
|
164
|
-
transition?: string;
|
|
165
|
-
/**
|
|
166
|
-
* CSS transform property
|
|
167
|
-
* @default "none"
|
|
168
|
-
*/
|
|
169
|
-
transform?: string;
|
|
170
|
-
}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { InteractionOptions } from "./config/interaction-options";
|
|
2
|
-
import { TooltipOptions } from "./config/tooltip-options";
|
|
3
|
-
import { DataItem } from "./data-item";
|
|
4
|
-
export interface Configuration extends InteractionOptions {
|
|
5
|
-
data: DataItem[];
|
|
6
|
-
canvasContainerId: string;
|
|
7
|
-
/**
|
|
8
|
-
* Background color of the canvas.
|
|
9
|
-
*
|
|
10
|
-
* @description Supports only HEX values (without `#`).
|
|
11
|
-
* @default "transparent"
|
|
12
|
-
*/
|
|
13
|
-
canvasBackgroundColor?: string;
|
|
14
|
-
/**
|
|
15
|
-
* Border color of the canvas.
|
|
16
|
-
*
|
|
17
|
-
* @description Supports only HEX values (without `#`).
|
|
18
|
-
* @default "transparent"
|
|
19
|
-
*/
|
|
20
|
-
canvasBorderColor?: string;
|
|
21
|
-
minRadius: number;
|
|
22
|
-
maxLines: number | "auto";
|
|
23
|
-
textWrap: boolean;
|
|
24
|
-
defaultBubbleColor: string;
|
|
25
|
-
fontSize: number;
|
|
26
|
-
defaultFontColor: string;
|
|
27
|
-
defaultFontFamily: string;
|
|
28
|
-
isResizeCanvasOnWindowSizeChange: boolean;
|
|
29
|
-
tooltipOptions?: TooltipOptions;
|
|
30
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { BubbleAppearance } from "./config/bubble-appearance";
|
|
2
|
-
import { FontOptions } from "./config/font-options";
|
|
3
|
-
import { ToolTipConfig } from "./config/tooltip-config";
|
|
4
|
-
export interface DataItem extends BubbleAppearance, FontOptions {
|
|
5
|
-
label: string;
|
|
6
|
-
value: number;
|
|
7
|
-
toolTipConfig?: ToolTipConfig;
|
|
8
|
-
}
|
package/dist/utils/config.d.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { Configuration } from "../models/public/configuration";
|
|
2
|
-
/**
|
|
3
|
-
* Default configuration object.
|
|
4
|
-
*/
|
|
5
|
-
export declare const DEFAULT_CONFIG: Omit<Configuration, "canvasContainerId" | "data">;
|
|
6
|
-
/**
|
|
7
|
-
* Merges user config with defaults, ensuring `canvasContainerId` and `data` are required.
|
|
8
|
-
*/
|
|
9
|
-
export declare function mergeConfig(customConfig: {
|
|
10
|
-
canvasContainerId: string;
|
|
11
|
-
data: Configuration["data"];
|
|
12
|
-
} & Partial<Configuration>): Configuration;
|
package/dist/utils/helper.d.ts
DELETED