fix: fix event types and bump to 7.0.0

This commit is contained in:
Justineo
2024-08-03 16:17:46 +08:00
parent e967bfc1fe
commit 4f3a6ac0a3
5 changed files with 17 additions and 10 deletions

View File

@ -1,3 +1,10 @@
## 7.0.0
> Other prerelease changes:
> * [7.0.0-beta.0](#700-beta0)
* Fixed types for events.
## 7.0.0-beta.0
* Upgraded to ESM.

View File

@ -214,7 +214,7 @@ Drop `<script>` inside your HTML file and access the component via `window.VueEC
```html
<script src="https://cdn.jsdelivr.net/npm/vue@3.4.33"></script>
<script src="https://cdn.jsdelivr.net/npm/echarts@5.5.1"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-echarts@7.0.0-beta.0"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-echarts@7.0.0"></script>
```
<!-- vue3Scripts:end -->
@ -234,7 +234,7 @@ app.component('v-chart', VueECharts)
```html
<script src="https://cdn.jsdelivr.net/npm/vue@2.7.16"></script>
<script src="https://cdn.jsdelivr.net/npm/echarts@5.5.1"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-echarts@7.0.0-beta.0"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-echarts@7.0.0"></script>
```
<!-- vue2Scripts:end -->

View File

@ -214,7 +214,7 @@ import "echarts";
```html
<script src="https://cdn.jsdelivr.net/npm/vue@3.4.33"></script>
<script src="https://cdn.jsdelivr.net/npm/echarts@5.5.1"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-echarts@7.0.0-beta.0"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-echarts@7.0.0"></script>
```
<!-- vue3Scripts:end -->
@ -234,7 +234,7 @@ app.component('v-chart', VueECharts)
```html
<script src="https://cdn.jsdelivr.net/npm/vue@2.7.16"></script>
<script src="https://cdn.jsdelivr.net/npm/echarts@5.5.1"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-echarts@7.0.0-beta.0"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-echarts@7.0.0"></script>
```
<!-- vue2Scripts:end -->

View File

@ -1,6 +1,6 @@
{
"name": "vue-echarts",
"version": "7.0.0-beta.0",
"version": "7.0.0",
"description": "Vue.js component for Apache ECharts™.",
"license": "MIT",
"repository": "https://github.com/ecomfe/vue-echarts.git",

View File

@ -93,19 +93,19 @@ type OtherEventName =
| "globalcursortaken";
type MouseEmits = {
[key in MouseEventName]: (params: ECElementEvent) => boolean;
[key in MouseEventName]: (params: ECElementEvent) => void;
};
type ZRenderEmits = {
[key in ZRenderEventName]: (params: ElementEvent) => boolean;
[key in ZRenderEventName]: (params: ElementEvent) => void;
};
type OtherEmits = {
[key in OtherEventName]: null;
[key in OtherEventName]: (params: any) => void;
};
export type Emits = MouseEmits &
OtherEmits & {
rendered: (params: { elapsedTime: number }) => boolean;
finished: () => boolean;
rendered: (params: { elapsedTime: number }) => void;
finished: () => void;
} & ZRenderEmits;