@idux/charts-core 0.8.0 → 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.
- package/CHANGELOG.md +19 -2
- package/dist/components/Chart.d.ts +4 -3
- package/dist/components/index.d.ts +3 -1
- package/dist/composables/index.d.ts +1 -0
- package/dist/composables/useChart.d.ts +4 -4
- package/dist/composables/useReactiveAttrs.d.ts +2 -0
- package/dist/composables/useResizeObserver.d.ts +2 -2
- package/dist/composables/useStripe.d.ts +17 -8
- package/dist/index.js +1108 -957
- package/dist/index.umd.cjs +7 -7
- package/dist/types/index.d.ts +12 -5
- package/dist/utils/index.d.ts +3 -1
- package/dist/utils/withChartProps.d.ts +30 -0
- package/package.json +14 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,10 +1,27 @@
|
|
|
1
1
|
# @idux/charts-core
|
|
2
2
|
|
|
3
|
-
##
|
|
3
|
+
## 1.1.0
|
|
4
4
|
|
|
5
5
|
### Minor Changes
|
|
6
6
|
|
|
7
|
-
-
|
|
7
|
+
- 887b91a: Add Radar, Gauge and LiquidFill components with pure option builders, public prop types and reactive plot theme/typography configuration. Extend core option types for the new series and coordinate systems.
|
|
8
|
+
|
|
9
|
+
Schedule automatic chart resizing on the next animation frame to avoid ResizeObserver delivery loops, and cancel pending resize work when auto-resize is disabled or the chart is disposed.
|
|
10
|
+
|
|
11
|
+
## 1.0.0
|
|
12
|
+
|
|
13
|
+
### Major Changes
|
|
14
|
+
|
|
15
|
+
- 493c9e8: Release the first stable 1.0.0 versions of the chart packages. This release includes reactive chart updates and lifecycle fixes, inferred component declarations compatible with Vue 2.7 and Vue 3, and public prop types for Vue 2.6 adapters.
|
|
16
|
+
|
|
17
|
+
### Minor Changes
|
|
18
|
+
|
|
19
|
+
- 45f7872: Export ChartPublicProps, BarChartPublicProps, LineChartPublicProps, and PieChartPublicProps for component type declarations. These types preserve named props and their optionality without broad index signatures. Existing chart configuration types and runtime behavior remain unchanged.
|
|
20
|
+
|
|
21
|
+
### Patch Changes
|
|
22
|
+
|
|
23
|
+
- 45f7872: Fix reactive chart options and event listeners across Vue 2 and Vue 3. Clean up resize observers and striped area observers when charts update or unmount.
|
|
24
|
+
- 45f7872: Preserve vue-demi imports and emit component declarations compatible with Vue 2.7 and Vue 3, retaining inferred configuration props, events, scoped slots, and instance bindings. Keep ECharts registration reachable when consumers tree-shake the packaged library.
|
|
8
25
|
|
|
9
26
|
## 0.7.2
|
|
10
27
|
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { ChartProps } from '../types';
|
|
2
|
+
declare const _default: import('..').ChartComponent<ChartProps, import("vue-demi").DefineComponent<{}, {
|
|
3
|
+
containerRef: import("vue-demi").ShallowRef<HTMLDivElement | undefined>;
|
|
4
|
+
}, {}, {}, {}, import("vue-demi").ComponentOptionsMixin, import("vue-demi").ComponentOptionsMixin, {}, string>, never>;
|
|
4
5
|
export default _default;
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
declare const IxChart: import(
|
|
1
|
+
declare const IxChart: import('..').ChartComponent<import('..').ChartProps, import("vue-demi").DefineComponent<{}, {
|
|
2
|
+
containerRef: import("vue-demi").ShallowRef<HTMLDivElement | undefined>;
|
|
3
|
+
}, {}, {}, {}, import("vue-demi").ComponentOptionsMixin, import("vue-demi").ComponentOptionsMixin, {}, string>, never>;
|
|
2
4
|
export { IxChart };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { Ref, ShallowRef } from 'vue-demi';
|
|
2
|
+
import { EChartsType } from 'echarts/core';
|
|
3
|
+
import { ChartProps } from '../types';
|
|
4
4
|
export type MaybeRef<T> = T | Ref<T>;
|
|
5
|
-
export declare function useChart<U extends ChartProps>(options: MaybeRef<U>, listeners?: Record<string, Function>): {
|
|
5
|
+
export declare function useChart<U extends ChartProps>(options: MaybeRef<U>, listeners?: Record<string, Function> | (() => Record<string, Function>)): {
|
|
6
6
|
containerRef: ShallowRef<HTMLDivElement | undefined>;
|
|
7
7
|
chartRef: ShallowRef<EChartsType | undefined>;
|
|
8
8
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { ComputedRef, Ref } from 'vue-demi';
|
|
2
|
+
import { EChartsType } from 'echarts/core';
|
|
3
3
|
export declare function useResizeObserver(containerRef: Ref<HTMLElement | undefined>, chartRef: Ref<EChartsType | undefined>, mergedAutoResize: ComputedRef<boolean | undefined>): void;
|
|
4
4
|
export type ResizeListener = (entry: ResizeObserverEntry) => void;
|
|
5
5
|
export declare function onResize(el: Element | null | undefined, listener: ResizeListener | undefined, options?: ResizeObserverOptions): void;
|
|
@@ -1,12 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
* @file 柱状图条纹使用
|
|
3
|
-
*/
|
|
4
|
-
import { type BarSeriesOption } from 'echarts/charts';
|
|
1
|
+
import { BarSeriesOption } from 'echarts/charts';
|
|
5
2
|
export declare function useStripe({ data, color, offset, rotate, size, }: {
|
|
6
3
|
data: number[];
|
|
7
4
|
color: string;
|
|
8
|
-
size?: [
|
|
9
|
-
|
|
5
|
+
size?: [
|
|
6
|
+
number,
|
|
7
|
+
number
|
|
8
|
+
];
|
|
9
|
+
offset?: [
|
|
10
|
+
number,
|
|
11
|
+
number
|
|
12
|
+
];
|
|
10
13
|
rotate?: number;
|
|
11
14
|
}): BarSeriesOption;
|
|
12
15
|
export declare function useStripeBarTooltip(unit: string): {
|
|
@@ -23,8 +26,14 @@ export declare function useStripeBarSeries({ series, color, offset, rotate, size
|
|
|
23
26
|
data: number[];
|
|
24
27
|
};
|
|
25
28
|
color: string;
|
|
26
|
-
offset?: [
|
|
27
|
-
|
|
29
|
+
offset?: [
|
|
30
|
+
number,
|
|
31
|
+
number
|
|
32
|
+
];
|
|
33
|
+
size?: [
|
|
34
|
+
number,
|
|
35
|
+
number
|
|
36
|
+
];
|
|
28
37
|
rotate?: number;
|
|
29
38
|
}): BarSeriesOption[];
|
|
30
39
|
export declare function useStripeArea(): {
|