nuxt-echarts 0.0.1 → 0.0.4
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 +37 -15
- package/dist/module.d.mts +31 -1
- package/dist/module.d.ts +31 -1
- package/dist/module.json +5 -2
- package/dist/module.mjs +105 -6
- package/dist/runtime/components/VChart.client.d.ts +310 -0
- package/dist/runtime/components/VChart.client.js +240 -0
- package/dist/runtime/components/VChart.server.vue +5 -0
- package/dist/runtime/components/VChartIsland.server.vue +34 -0
- package/dist/runtime/components/VChartLight.vue +78 -0
- package/dist/runtime/components/VChartLight.vue.d.ts +26 -0
- package/dist/runtime/components/VChartServer.vue +48 -0
- package/dist/runtime/composables/api.d.ts +7 -0
- package/dist/runtime/composables/api.js +35 -0
- package/dist/runtime/composables/autoresize.d.ts +0 -0
- package/dist/runtime/composables/autoresize.js +26 -0
- package/dist/runtime/composables/index.d.ts +3 -0
- package/dist/runtime/composables/index.js +3 -0
- package/dist/runtime/composables/loading.d.ts +8 -0
- package/dist/runtime/composables/loading.js +29 -0
- package/dist/runtime/{plugin.mjs → plugin.js} +0 -1
- package/dist/runtime/style.css +1 -0
- package/dist/runtime/types.d.ts +52 -0
- package/dist/runtime/types.js +0 -0
- package/dist/runtime/utils/injection.d.ts +6 -0
- package/dist/runtime/utils/injection.js +4 -0
- package/dist/runtime/utils/on.d.ts +4 -0
- package/dist/runtime/utils/on.js +11 -0
- package/dist/runtime/utils/wc.d.ts +0 -0
- package/dist/runtime/utils/wc.js +30 -0
- package/dist/types.d.mts +4 -13
- package/dist/types.d.ts +4 -13
- package/package.json +25 -13
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
let registered = null;
|
|
2
|
+
export const TAG_NAME = "x-vue-echarts";
|
|
3
|
+
if (import.meta.server) {
|
|
4
|
+
global.HTMLElement = Object;
|
|
5
|
+
}
|
|
6
|
+
export class EChartsElement extends HTMLElement {
|
|
7
|
+
__dispose = null;
|
|
8
|
+
disconnectedCallback() {
|
|
9
|
+
if (this.__dispose) {
|
|
10
|
+
this.__dispose();
|
|
11
|
+
this.__dispose = null;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
export function register() {
|
|
16
|
+
if (registered != null) {
|
|
17
|
+
return registered;
|
|
18
|
+
}
|
|
19
|
+
if (typeof HTMLElement === "undefined" || typeof customElements === "undefined") {
|
|
20
|
+
return registered = false;
|
|
21
|
+
}
|
|
22
|
+
try {
|
|
23
|
+
if (customElements.get(TAG_NAME) == null) {
|
|
24
|
+
customElements.define(TAG_NAME, EChartsElement);
|
|
25
|
+
}
|
|
26
|
+
} catch (e) {
|
|
27
|
+
return registered = false;
|
|
28
|
+
}
|
|
29
|
+
return registered = true;
|
|
30
|
+
}
|
package/dist/types.d.mts
CHANGED
|
@@ -1,16 +1,7 @@
|
|
|
1
|
+
import type { NuxtModule } from '@nuxt/schema'
|
|
1
2
|
|
|
2
|
-
import type {
|
|
3
|
+
import type { default as Module } from './module.js'
|
|
3
4
|
|
|
5
|
+
export type ModuleOptions = typeof Module extends NuxtModule<infer O> ? Partial<O> : Record<string, any>
|
|
4
6
|
|
|
5
|
-
|
|
6
|
-
interface NuxtConfig { ['echarts']?: Partial<ModuleOptions> }
|
|
7
|
-
interface NuxtOptions { ['echarts']?: ModuleOptions }
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
declare module 'nuxt/schema' {
|
|
11
|
-
interface NuxtConfig { ['echarts']?: Partial<ModuleOptions> }
|
|
12
|
-
interface NuxtOptions { ['echarts']?: ModuleOptions }
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export type { ModuleOptions, default } from './module.js'
|
|
7
|
+
export { default } from './module.js'
|
package/dist/types.d.ts
CHANGED
|
@@ -1,16 +1,7 @@
|
|
|
1
|
+
import type { NuxtModule } from '@nuxt/schema'
|
|
1
2
|
|
|
2
|
-
import type {
|
|
3
|
+
import type { default as Module } from './module'
|
|
3
4
|
|
|
5
|
+
export type ModuleOptions = typeof Module extends NuxtModule<infer O> ? Partial<O> : Record<string, any>
|
|
4
6
|
|
|
5
|
-
|
|
6
|
-
interface NuxtConfig { ['echarts']?: Partial<ModuleOptions> }
|
|
7
|
-
interface NuxtOptions { ['echarts']?: ModuleOptions }
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
declare module 'nuxt/schema' {
|
|
11
|
-
interface NuxtConfig { ['echarts']?: Partial<ModuleOptions> }
|
|
12
|
-
interface NuxtOptions { ['echarts']?: ModuleOptions }
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export type { ModuleOptions, default } from './module'
|
|
7
|
+
export { default } from './module'
|
package/package.json
CHANGED
|
@@ -1,12 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nuxt-echarts",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.4",
|
|
4
4
|
"description": "Nuxt Module for Apache ECharts™",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"vue",
|
|
7
|
+
"nuxt",
|
|
8
|
+
"echarts",
|
|
9
|
+
"data-visualization",
|
|
10
|
+
"charts"
|
|
11
|
+
],
|
|
5
12
|
"author": "Yue JIN <yuejin13@fudan.edu.cn>",
|
|
6
13
|
"repository": "kingyue737/nuxt-echarts",
|
|
7
14
|
"license": "MIT",
|
|
8
15
|
"type": "module",
|
|
9
|
-
"packageManager": "pnpm@9.
|
|
16
|
+
"packageManager": "pnpm@9.4.0",
|
|
10
17
|
"exports": {
|
|
11
18
|
".": {
|
|
12
19
|
"types": "./dist/types.d.ts",
|
|
@@ -32,22 +39,23 @@
|
|
|
32
39
|
"test:types": "vue-tsc --noEmit && cd playground && vue-tsc --noEmit"
|
|
33
40
|
},
|
|
34
41
|
"dependencies": {
|
|
35
|
-
"@nuxt/kit": "^3.
|
|
42
|
+
"@nuxt/kit": "^3.12.2",
|
|
43
|
+
"echarts": "^5.5.0"
|
|
36
44
|
},
|
|
37
45
|
"devDependencies": {
|
|
38
|
-
"@nuxt/devtools": "^1.3.
|
|
46
|
+
"@nuxt/devtools": "^1.3.3",
|
|
39
47
|
"@nuxt/eslint-config": "^0.3.13",
|
|
40
|
-
"@nuxt/module-builder": "^0.
|
|
41
|
-
"@nuxt/schema": "^3.
|
|
48
|
+
"@nuxt/module-builder": "^0.8.0",
|
|
49
|
+
"@nuxt/schema": "^3.12.2",
|
|
42
50
|
"@nuxt/test-utils": "^3.13.1",
|
|
43
|
-
"@types/node": "^20.
|
|
51
|
+
"@types/node": "^20.14.5",
|
|
44
52
|
"changelogen": "^0.5.5",
|
|
45
|
-
"eslint": "^9.
|
|
46
|
-
"nuxt": "^3.
|
|
47
|
-
"prettier": "^3.2
|
|
53
|
+
"eslint": "^9.5.0",
|
|
54
|
+
"nuxt": "^3.12.2",
|
|
55
|
+
"prettier": "^3.3.2",
|
|
48
56
|
"typescript": "latest",
|
|
49
57
|
"vitest": "^1.6.0",
|
|
50
|
-
"vue-tsc": "^2.0.
|
|
58
|
+
"vue-tsc": "^2.0.21"
|
|
51
59
|
},
|
|
52
60
|
"pnpm": {
|
|
53
61
|
"peerDependencyRules": {
|
|
@@ -55,8 +63,12 @@
|
|
|
55
63
|
"@typescript-eslint/eslint-plugin>eslint": "^9.0.0",
|
|
56
64
|
"@typescript-eslint/parser>eslint": "^9.0.0",
|
|
57
65
|
"@typescript-eslint/type-utils>eslint": "^9.0.0",
|
|
58
|
-
"@typescript-eslint/utils>eslint": "^9.0.0"
|
|
59
|
-
|
|
66
|
+
"@typescript-eslint/utils>eslint": "^9.0.0",
|
|
67
|
+
"@opentelemetry/api": "^1.9.0"
|
|
68
|
+
},
|
|
69
|
+
"ignoreMissing": [
|
|
70
|
+
"webpack"
|
|
71
|
+
]
|
|
60
72
|
}
|
|
61
73
|
}
|
|
62
74
|
}
|