@easy-editor/materials-dashboard-radar-chart 0.0.2

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.
Files changed (44) hide show
  1. package/.vite/plugins/vite-plugin-external-deps.ts +224 -0
  2. package/.vite/plugins/vite-plugin-material-dev.ts +218 -0
  3. package/CHANGELOG.md +7 -0
  4. package/LICENSE +9 -0
  5. package/dist/component.esm.js +31510 -0
  6. package/dist/component.esm.js.map +1 -0
  7. package/dist/component.js +31517 -0
  8. package/dist/component.js.map +1 -0
  9. package/dist/component.min.js +24 -0
  10. package/dist/component.min.js.map +1 -0
  11. package/dist/index.cjs +31811 -0
  12. package/dist/index.cjs.map +1 -0
  13. package/dist/index.esm.js +31808 -0
  14. package/dist/index.esm.js.map +1 -0
  15. package/dist/index.js +31815 -0
  16. package/dist/index.js.map +1 -0
  17. package/dist/index.min.js +24 -0
  18. package/dist/index.min.js.map +1 -0
  19. package/dist/meta.esm.js +333 -0
  20. package/dist/meta.esm.js.map +1 -0
  21. package/dist/meta.js +343 -0
  22. package/dist/meta.js.map +1 -0
  23. package/dist/meta.min.js +2 -0
  24. package/dist/meta.min.js.map +1 -0
  25. package/dist/src/component.d.ts +21 -0
  26. package/dist/src/configure.d.ts +7 -0
  27. package/dist/src/constants.d.ts +39 -0
  28. package/dist/src/index.d.ts +6 -0
  29. package/dist/src/meta.d.ts +3 -0
  30. package/dist/src/snippets.d.ts +3 -0
  31. package/package.json +68 -0
  32. package/rollup.config.js +212 -0
  33. package/src/component.module.css +16 -0
  34. package/src/component.tsx +199 -0
  35. package/src/configure.ts +247 -0
  36. package/src/constants.ts +51 -0
  37. package/src/index.tsx +7 -0
  38. package/src/meta.ts +23 -0
  39. package/src/snippets.ts +57 -0
  40. package/src/type.d.ts +8 -0
  41. package/tsconfig.build.json +12 -0
  42. package/tsconfig.json +9 -0
  43. package/tsconfig.test.json +7 -0
  44. package/vite.config.ts +54 -0
package/dist/meta.js ADDED
@@ -0,0 +1,343 @@
1
+ /* @easy-editor/materials-dashboard-tech-radar-chart v0.0.1 (meta) */
2
+ (function (global, factory) {
3
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
4
+ typeof define === 'function' && define.amd ? define(['exports'], factory) :
5
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.EasyEditorMaterialsTechRadarChartMeta = {}));
6
+ })(this, (function (exports) { 'use strict';
7
+
8
+ const MaterialGroup = {
9
+ CHART: 'chart'};
10
+
11
+ const COMPONENT_NAME = 'EasyEditorMaterialsTechRadarChart';
12
+ const PACKAGE_NAME = '@easy-editor/materials-dashboard-tech-radar-chart';
13
+ const DEFAULT_DATA = [{
14
+ dimension: 'Attack',
15
+ player1: 85,
16
+ player2: 70
17
+ }, {
18
+ dimension: 'Defense',
19
+ player1: 70,
20
+ player2: 90
21
+ }, {
22
+ dimension: 'Speed',
23
+ player1: 95,
24
+ player2: 60
25
+ }, {
26
+ dimension: 'Magic',
27
+ player1: 60,
28
+ player2: 85
29
+ }, {
30
+ dimension: 'HP',
31
+ player1: 75,
32
+ player2: 80
33
+ }];
34
+ const DEFAULT_SERIES = [{
35
+ name: 'Player 1',
36
+ dataKey: 'player1',
37
+ color: '#00d4ff'
38
+ }, {
39
+ name: 'Player 2',
40
+ dataKey: 'player2',
41
+ color: '#00ff88'
42
+ }];
43
+
44
+ const configure = {
45
+ props: [{
46
+ type: 'group',
47
+ title: '属性',
48
+ setter: 'TabSetter',
49
+ items: [{
50
+ type: 'group',
51
+ key: 'config',
52
+ title: '配置',
53
+ setter: {
54
+ componentName: 'CollapseSetter',
55
+ props: {
56
+ icon: false
57
+ }
58
+ },
59
+ items: [
60
+ {
61
+ name: 'id',
62
+ title: 'ID',
63
+ setter: 'NodeIdSetter',
64
+ extraProps: {
65
+ label: false
66
+ }
67
+ }, {
68
+ name: 'title',
69
+ title: '标题',
70
+ setter: 'StringSetter',
71
+ extraProps: {
72
+ getValue(target) {
73
+ return target.getExtraPropValue('title');
74
+ },
75
+ setValue(target, value) {
76
+ target.setExtraPropValue('title', value);
77
+ }
78
+ }
79
+ }, {
80
+ type: 'group',
81
+ title: '基础属性',
82
+ setter: {
83
+ componentName: 'CollapseSetter',
84
+ props: {
85
+ icon: false
86
+ }
87
+ },
88
+ items: [{
89
+ name: 'rect',
90
+ title: '位置尺寸',
91
+ setter: 'RectSetter',
92
+ extraProps: {
93
+ getValue(target) {
94
+ return target.getExtraPropValue('$dashboard.rect');
95
+ },
96
+ setValue(target, value) {
97
+ target.setExtraPropValue('$dashboard.rect', value);
98
+ }
99
+ }
100
+ }]
101
+ },
102
+ {
103
+ type: 'group',
104
+ title: '数据',
105
+ setter: {
106
+ componentName: 'CollapseSetter',
107
+ props: {
108
+ icon: false
109
+ }
110
+ },
111
+ items: [{
112
+ name: 'data',
113
+ title: '数据',
114
+ setter: 'JsonSetter'
115
+ }, {
116
+ name: 'dimensionKey',
117
+ title: '维度字段',
118
+ setter: 'StringSetter',
119
+ extraProps: {
120
+ defaultValue: 'dimension'
121
+ }
122
+ }, {
123
+ name: 'series',
124
+ title: '系列',
125
+ setter: 'JsonSetter'
126
+ }]
127
+ }, {
128
+ type: 'group',
129
+ title: '数值格式',
130
+ setter: {
131
+ componentName: 'CollapseSetter',
132
+ props: {
133
+ icon: false
134
+ }
135
+ },
136
+ items: [{
137
+ name: 'valuePrefix',
138
+ title: '前缀',
139
+ setter: 'StringSetter'
140
+ }, {
141
+ name: 'valueSuffix',
142
+ title: '后缀',
143
+ setter: 'StringSetter'
144
+ }, {
145
+ name: 'valueDecimals',
146
+ title: '小数位数',
147
+ setter: {
148
+ componentName: 'NumberSetter',
149
+ props: {
150
+ suffix: '位'
151
+ }
152
+ },
153
+ extraProps: {
154
+ defaultValue: 0
155
+ }
156
+ }]
157
+ }, {
158
+ type: 'group',
159
+ title: '样式',
160
+ setter: {
161
+ componentName: 'CollapseSetter',
162
+ props: {
163
+ icon: false
164
+ }
165
+ },
166
+ items: [{
167
+ name: 'showGrid',
168
+ title: '显示网格',
169
+ setter: 'SwitchSetter',
170
+ extraProps: {
171
+ defaultValue: true
172
+ }
173
+ }, {
174
+ name: 'fillOpacity',
175
+ title: '填充透明度',
176
+ setter: {
177
+ componentName: 'SliderSetter',
178
+ props: {
179
+ min: 0,
180
+ max: 1,
181
+ step: 0.1
182
+ }
183
+ },
184
+ extraProps: {
185
+ defaultValue: 0.3
186
+ }
187
+ }, {
188
+ name: 'showLegend',
189
+ title: '显示图例',
190
+ setter: 'SwitchSetter',
191
+ extraProps: {
192
+ defaultValue: true
193
+ }
194
+ }, {
195
+ name: 'legendPosition',
196
+ title: '图例位置',
197
+ setter: {
198
+ componentName: 'SelectSetter',
199
+ props: {
200
+ options: [{
201
+ label: '顶部',
202
+ value: 'top'
203
+ }, {
204
+ label: '底部',
205
+ value: 'bottom'
206
+ }, {
207
+ label: '左侧',
208
+ value: 'left'
209
+ }, {
210
+ label: '右侧',
211
+ value: 'right'
212
+ }]
213
+ }
214
+ },
215
+ extraProps: {
216
+ defaultValue: 'bottom'
217
+ }
218
+ }, {
219
+ name: 'glowEffect',
220
+ title: '发光效果',
221
+ setter: 'SwitchSetter',
222
+ extraProps: {
223
+ defaultValue: true
224
+ }
225
+ }]
226
+ }]
227
+ }, {
228
+ type: 'group',
229
+ key: 'data',
230
+ title: '数据',
231
+ items: [{
232
+ name: 'dataBinding',
233
+ title: '数据绑定',
234
+ setter: 'DataBindingSetter'
235
+ }]
236
+ }, {
237
+ type: 'group',
238
+ key: 'advanced',
239
+ title: '高级',
240
+ items: [{
241
+ name: 'condition',
242
+ title: '显隐控制',
243
+ setter: 'SwitchSetter',
244
+ extraProps: {
245
+ defaultValue: true,
246
+ supportVariable: true
247
+ }
248
+ }]
249
+ }]
250
+ }],
251
+ component: {},
252
+ supports: {},
253
+ advanced: {}
254
+ };
255
+
256
+ const snippets = [{
257
+ title: '雷达图',
258
+ screenshot: '',
259
+ schema: {
260
+ componentName: COMPONENT_NAME,
261
+ props: {
262
+ data: DEFAULT_DATA,
263
+ dimensionKey: 'dimension',
264
+ series: DEFAULT_SERIES,
265
+ showGrid: true,
266
+ fillOpacity: 0.3,
267
+ glowEffect: true,
268
+ showLegend: true
269
+ },
270
+ $dashboard: {
271
+ rect: {
272
+ width: 400,
273
+ height: 300
274
+ }
275
+ }
276
+ }
277
+ }, {
278
+ title: '单系列雷达图',
279
+ screenshot: '',
280
+ schema: {
281
+ componentName: COMPONENT_NAME,
282
+ props: {
283
+ data: [{
284
+ dimension: 'Attack',
285
+ value: 85
286
+ }, {
287
+ dimension: 'Defense',
288
+ value: 70
289
+ }, {
290
+ dimension: 'Speed',
291
+ value: 95
292
+ }, {
293
+ dimension: 'Magic',
294
+ value: 60
295
+ }, {
296
+ dimension: 'HP',
297
+ value: 75
298
+ }],
299
+ dimensionKey: 'dimension',
300
+ series: [{
301
+ name: 'Stats',
302
+ dataKey: 'value',
303
+ color: '#00d4ff'
304
+ }],
305
+ showGrid: true,
306
+ fillOpacity: 0.4,
307
+ glowEffect: true,
308
+ showLegend: false
309
+ },
310
+ $dashboard: {
311
+ rect: {
312
+ width: 400,
313
+ height: 300
314
+ }
315
+ }
316
+ }
317
+ }];
318
+
319
+ var version = "0.0.1";
320
+ var pkg = {
321
+ version: version};
322
+
323
+ const meta = {
324
+ componentName: COMPONENT_NAME,
325
+ title: '雷达图',
326
+ group: MaterialGroup.CHART,
327
+ devMode: 'proCode',
328
+ npm: {
329
+ package: PACKAGE_NAME,
330
+ version: pkg.version,
331
+ globalName: COMPONENT_NAME,
332
+ componentName: COMPONENT_NAME
333
+ },
334
+ snippets,
335
+ configure
336
+ };
337
+
338
+ exports.default = meta;
339
+
340
+ Object.defineProperty(exports, '__esModule', { value: true });
341
+
342
+ }));
343
+ //# sourceMappingURL=meta.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"meta.js","sources":["../../../../shared/src/index.ts","../src/constants.ts","../src/configure.ts","../src/snippets.ts","../src/meta.ts"],"sourcesContent":["/**\n * Shared types, components and utilities for EasyEditor materials\n * @package @easy-editor/materials-shared\n */\n\n// 物料分组常量\nexport const MaterialGroup = {\n /** 内置 */\n INNER: 'inner',\n /** 基础 */\n BASIC: 'basic',\n /** 图表 */\n CHART: 'chart',\n /** 数据展示 */\n DISPLAY: 'display',\n /** 媒体 */\n MEDIA: 'media',\n /** 交互 */\n INTERACTION: 'interaction',\n /** 地图 */\n MAP: 'map',\n} as const\n\nexport type MaterialGroup = (typeof MaterialGroup)[keyof typeof MaterialGroup]\n\n// 工具函数\nexport { cn } from './lib/utils'\n\nexport * from './types'\n","/**\n * 物料常量配置\n * 统一管理全局变量名等配置,确保 meta.ts 和 rollup.config.js 使用相同的值\n */\n\n/**\n * UMD 全局变量基础名称\n */\nexport const COMPONENT_NAME = 'EasyEditorMaterialsTechRadarChart'\n\n/**\n * 包名\n */\nexport const PACKAGE_NAME = '@easy-editor/materials-dashboard-tech-radar-chart'\n\n/**\n * 默认颜色\n */\nexport const DEFAULT_COLORS = ['#00d4ff', '#00ff88', '#ff6b6b', '#ffd93d', '#6bcbff', '#c56bff']\n\n/**\n * 默认维度\n */\nexport const DEFAULT_DIMENSIONS = ['Attack', 'Defense', 'Speed', 'Magic', 'HP']\n\n/**\n * 雷达图数据点类型\n */\nexport interface RadarDataPoint {\n dimension: string\n [key: string]: number | string | undefined\n}\n\n/**\n * 默认数据\n */\nexport const DEFAULT_DATA: RadarDataPoint[] = [\n { dimension: 'Attack', player1: 85, player2: 70 },\n { dimension: 'Defense', player1: 70, player2: 90 },\n { dimension: 'Speed', player1: 95, player2: 60 },\n { dimension: 'Magic', player1: 60, player2: 85 },\n { dimension: 'HP', player1: 75, player2: 80 },\n]\n\n/**\n * 默认系列配置\n */\nexport const DEFAULT_SERIES = [\n { name: 'Player 1', dataKey: 'player1', color: '#00d4ff' },\n { name: 'Player 2', dataKey: 'player2', color: '#00ff88' },\n]\n","/**\n * Radar Chart Configure\n * 雷达图组件配置\n */\n\nimport type { Configure } from '@easy-editor/core'\n\nconst configure: Configure = {\n props: [\n {\n type: 'group',\n title: '属性',\n setter: 'TabSetter',\n items: [\n {\n type: 'group',\n key: 'config',\n title: '配置',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n // 基础配置\n {\n name: 'id',\n title: 'ID',\n setter: 'NodeIdSetter',\n extraProps: {\n // @ts-expect-error label is not a valid extra prop\n label: false,\n },\n },\n {\n name: 'title',\n title: '标题',\n setter: 'StringSetter',\n extraProps: {\n getValue(target) {\n return target.getExtraPropValue('title')\n },\n setValue(target, value) {\n target.setExtraPropValue('title', value)\n },\n },\n },\n {\n type: 'group',\n title: '基础属性',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n {\n name: 'rect',\n title: '位置尺寸',\n setter: 'RectSetter',\n extraProps: {\n getValue(target) {\n return target.getExtraPropValue('$dashboard.rect')\n },\n setValue(target, value) {\n target.setExtraPropValue('$dashboard.rect', value)\n },\n },\n },\n ],\n },\n // 组件配置\n {\n type: 'group',\n title: '数据',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n {\n name: 'data',\n title: '数据',\n setter: 'JsonSetter',\n },\n {\n name: 'dimensionKey',\n title: '维度字段',\n setter: 'StringSetter',\n extraProps: {\n defaultValue: 'dimension',\n },\n },\n {\n name: 'series',\n title: '系列',\n setter: 'JsonSetter',\n },\n ],\n },\n {\n type: 'group',\n title: '数值格式',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n {\n name: 'valuePrefix',\n title: '前缀',\n setter: 'StringSetter',\n },\n {\n name: 'valueSuffix',\n title: '后缀',\n setter: 'StringSetter',\n },\n {\n name: 'valueDecimals',\n title: '小数位数',\n setter: {\n componentName: 'NumberSetter',\n props: {\n suffix: '位',\n },\n },\n extraProps: {\n defaultValue: 0,\n },\n },\n ],\n },\n {\n type: 'group',\n title: '样式',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n {\n name: 'showGrid',\n title: '显示网格',\n setter: 'SwitchSetter',\n extraProps: {\n defaultValue: true,\n },\n },\n {\n name: 'fillOpacity',\n title: '填充透明度',\n setter: {\n componentName: 'SliderSetter',\n props: {\n min: 0,\n max: 1,\n step: 0.1,\n },\n },\n extraProps: {\n defaultValue: 0.3,\n },\n },\n {\n name: 'showLegend',\n title: '显示图例',\n setter: 'SwitchSetter',\n extraProps: {\n defaultValue: true,\n },\n },\n {\n name: 'legendPosition',\n title: '图例位置',\n setter: {\n componentName: 'SelectSetter',\n props: {\n options: [\n { label: '顶部', value: 'top' },\n { label: '底部', value: 'bottom' },\n { label: '左侧', value: 'left' },\n { label: '右侧', value: 'right' },\n ],\n },\n },\n extraProps: {\n defaultValue: 'bottom',\n },\n },\n {\n name: 'glowEffect',\n title: '发光效果',\n setter: 'SwitchSetter',\n extraProps: {\n defaultValue: true,\n },\n },\n ],\n },\n ],\n },\n {\n type: 'group',\n key: 'data',\n title: '数据',\n items: [\n {\n name: 'dataBinding',\n title: '数据绑定',\n setter: 'DataBindingSetter',\n },\n ],\n },\n {\n type: 'group',\n key: 'advanced',\n title: '高级',\n items: [\n {\n name: 'condition',\n title: '显隐控制',\n setter: 'SwitchSetter',\n extraProps: {\n defaultValue: true,\n supportVariable: true,\n },\n },\n ],\n },\n ],\n },\n ],\n component: {},\n supports: {},\n advanced: {},\n}\n\nexport default configure\n","import type { Snippet } from '@easy-editor/core'\nimport { COMPONENT_NAME, DEFAULT_DATA, DEFAULT_SERIES } from './constants'\n\nconst snippets: Snippet[] = [\n {\n title: '雷达图',\n screenshot: '',\n schema: {\n componentName: COMPONENT_NAME,\n props: {\n data: DEFAULT_DATA,\n dimensionKey: 'dimension',\n series: DEFAULT_SERIES,\n showGrid: true,\n fillOpacity: 0.3,\n glowEffect: true,\n showLegend: true,\n },\n $dashboard: {\n rect: {\n width: 400,\n height: 300,\n },\n },\n },\n },\n {\n title: '单系列雷达图',\n screenshot: '',\n schema: {\n componentName: COMPONENT_NAME,\n props: {\n data: [\n { dimension: 'Attack', value: 85 },\n { dimension: 'Defense', value: 70 },\n { dimension: 'Speed', value: 95 },\n { dimension: 'Magic', value: 60 },\n { dimension: 'HP', value: 75 },\n ],\n dimensionKey: 'dimension',\n series: [{ name: 'Stats', dataKey: 'value', color: '#00d4ff' }],\n showGrid: true,\n fillOpacity: 0.4,\n glowEffect: true,\n showLegend: false,\n },\n $dashboard: {\n rect: {\n width: 400,\n height: 300,\n },\n },\n },\n },\n]\n\nexport default snippets\n","import type { ComponentMetadata } from '@easy-editor/core'\nimport { MaterialGroup } from '@easy-editor/materials-shared'\nimport { COMPONENT_NAME, PACKAGE_NAME } from './constants'\nimport configure from './configure'\nimport snippets from './snippets'\nimport pkg from '../package.json'\n\nconst meta: ComponentMetadata = {\n componentName: COMPONENT_NAME,\n title: '雷达图',\n group: MaterialGroup.CHART,\n devMode: 'proCode',\n npm: {\n package: PACKAGE_NAME,\n version: pkg.version,\n globalName: COMPONENT_NAME,\n componentName: COMPONENT_NAME,\n },\n snippets,\n configure,\n}\n\nexport default meta\n"],"names":["MaterialGroup","INNER","CHART","COMPONENT_NAME","PACKAGE_NAME","DEFAULT_DATA","dimension","player1","player2","DEFAULT_SERIES","name","dataKey","color","configure","props","type","title","setter","items","key","componentName","icon","extraProps","label","getValue","target","getExtraPropValue","setValue","value","setExtraPropValue","defaultValue","suffix","min","max","step","options","supportVariable","component","supports","advanced","snippets","screenshot","schema","data","dimensionKey","series","showGrid","fillOpacity","glowEffect","showLegend","$dashboard","rect","width","height","meta","group","devMode","npm","package","version","pkg","globalName"],"mappings":";;;;;;;EAMO,MAAMA,aAAa,GAAG;EAE3BC,EAIAC,KAAK,EAAE,OAST,CAAU;;ECbH,MAAMC,cAAc,GAAG,mCAAmC;EAK1D,MAAMC,YAAY,GAAG,mDAAmD;EAuBxE,MAAMC,YAA8B,GAAG,CAC5C;EAAEC,EAAAA,SAAS,EAAE,QAAQ;EAAEC,E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VC,MAAAA,IAAI,EAAE;EACJC,QAAAA,KAAK,EAAE,GAAG;EACVC,QAAAA,MAAM,EAAE;EACV;EACF;EACF;EACF,CAAC,CACF;;;;;;AC/CD,QAAMC,IAAuB,GAAG;EAC9BlC,EAAAA,aAAa,EAAEjB,cAAc;EAC7Ba,EAAAA,KAAK,EAAE,KAAK;IACZuC,KAAK,EAAEvD,aAAa,CAACE,KAAK;EAC1BsD,EAAAA,OAAO,EAAE,SAAS;EAClBC,EAAAA,GAAG,EAAE;EACHC,IAAAA,OAAO,EAAEtD,YAAY;MACrBuD,OAAO,EAAEC,GAAG,CAACD,OAAO;EACpBE,IAAAA,UAAU,EAAE1D,cAAc;EAC1BiB,IAAAA,aAAa,EAAEjB;KAChB;IACDqC,QAAQ;EACR3B,EAAAA;EACF;;;;;;;;;;"}
@@ -0,0 +1,2 @@
1
+ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).EasyEditorMaterialsTechRadarChartMeta={})}(this,function(e){"use strict";const t="EasyEditorMaterialsTechRadarChart";const a={componentName:t,title:"雷达图",group:"chart",devMode:"proCode",npm:{package:"@easy-editor/materials-dashboard-tech-radar-chart",version:"0.0.1",globalName:t,componentName:t},snippets:[{title:"雷达图",screenshot:"",schema:{componentName:t,props:{data:[{dimension:"Attack",player1:85,player2:70},{dimension:"Defense",player1:70,player2:90},{dimension:"Speed",player1:95,player2:60},{dimension:"Magic",player1:60,player2:85},{dimension:"HP",player1:75,player2:80}],dimensionKey:"dimension",series:[{name:"Player 1",dataKey:"player1",color:"#00d4ff"},{name:"Player 2",dataKey:"player2",color:"#00ff88"}],showGrid:!0,fillOpacity:.3,glowEffect:!0,showLegend:!0},$dashboard:{rect:{width:400,height:300}}}},{title:"单系列雷达图",screenshot:"",schema:{componentName:t,props:{data:[{dimension:"Attack",value:85},{dimension:"Defense",value:70},{dimension:"Speed",value:95},{dimension:"Magic",value:60},{dimension:"HP",value:75}],dimensionKey:"dimension",series:[{name:"Stats",dataKey:"value",color:"#00d4ff"}],showGrid:!0,fillOpacity:.4,glowEffect:!0,showLegend:!1},$dashboard:{rect:{width:400,height:300}}}}],configure:{props:[{type:"group",title:"属性",setter:"TabSetter",items:[{type:"group",key:"config",title:"配置",setter:{componentName:"CollapseSetter",props:{icon:!1}},items:[{name:"id",title:"ID",setter:"NodeIdSetter",extraProps:{label:!1}},{name:"title",title:"标题",setter:"StringSetter",extraProps:{getValue:e=>e.getExtraPropValue("title"),setValue(e,t){e.setExtraPropValue("title",t)}}},{type:"group",title:"基础属性",setter:{componentName:"CollapseSetter",props:{icon:!1}},items:[{name:"rect",title:"位置尺寸",setter:"RectSetter",extraProps:{getValue:e=>e.getExtraPropValue("$dashboard.rect"),setValue(e,t){e.setExtraPropValue("$dashboard.rect",t)}}}]},{type:"group",title:"数据",setter:{componentName:"CollapseSetter",props:{icon:!1}},items:[{name:"data",title:"数据",setter:"JsonSetter"},{name:"dimensionKey",title:"维度字段",setter:"StringSetter",extraProps:{defaultValue:"dimension"}},{name:"series",title:"系列",setter:"JsonSetter"}]},{type:"group",title:"数值格式",setter:{componentName:"CollapseSetter",props:{icon:!1}},items:[{name:"valuePrefix",title:"前缀",setter:"StringSetter"},{name:"valueSuffix",title:"后缀",setter:"StringSetter"},{name:"valueDecimals",title:"小数位数",setter:{componentName:"NumberSetter",props:{suffix:"位"}},extraProps:{defaultValue:0}}]},{type:"group",title:"样式",setter:{componentName:"CollapseSetter",props:{icon:!1}},items:[{name:"showGrid",title:"显示网格",setter:"SwitchSetter",extraProps:{defaultValue:!0}},{name:"fillOpacity",title:"填充透明度",setter:{componentName:"SliderSetter",props:{min:0,max:1,step:.1}},extraProps:{defaultValue:.3}},{name:"showLegend",title:"显示图例",setter:"SwitchSetter",extraProps:{defaultValue:!0}},{name:"legendPosition",title:"图例位置",setter:{componentName:"SelectSetter",props:{options:[{label:"顶部",value:"top"},{label:"底部",value:"bottom"},{label:"左侧",value:"left"},{label:"右侧",value:"right"}]}},extraProps:{defaultValue:"bottom"}},{name:"glowEffect",title:"发光效果",setter:"SwitchSetter",extraProps:{defaultValue:!0}}]}]},{type:"group",key:"data",title:"数据",items:[{name:"dataBinding",title:"数据绑定",setter:"DataBindingSetter"}]},{type:"group",key:"advanced",title:"高级",items:[{name:"condition",title:"显隐控制",setter:"SwitchSetter",extraProps:{defaultValue:!0,supportVariable:!0}}]}]}],component:{},supports:{},advanced:{}}};e.default=a,Object.defineProperty(e,"__esModule",{value:!0})});
2
+ //# sourceMappingURL=meta.min.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"meta.min.js","sources":["../../../../shared/src/index.ts","../src/constants.ts","../src/meta.ts","../src/snippets.ts","../src/configure.ts"],"sourcesContent":["/**\n * Shared types, components and utilities for EasyEditor materials\n * @package @easy-editor/materials-shared\n */\n\n// 物料分组常量\nexport const MaterialGroup = {\n /** 内置 */\n INNER: 'inner',\n /** 基础 */\n BASIC: 'basic',\n /** 图表 */\n CHART: 'chart',\n /** 数据展示 */\n DISPLAY: 'display',\n /** 媒体 */\n MEDIA: 'media',\n /** 交互 */\n INTERACTION: 'interaction',\n /** 地图 */\n MAP: 'map',\n} as const\n\nexport type MaterialGroup = (typeof MaterialGroup)[keyof typeof MaterialGroup]\n\n// 工具函数\nexport { cn } from './lib/utils'\n\nexport * from './types'\n","/**\n * 物料常量配置\n * 统一管理全局变量名等配置,确保 meta.ts 和 rollup.config.js 使用相同的值\n */\n\n/**\n * UMD 全局变量基础名称\n */\nexport const COMPONENT_NAME = 'EasyEditorMaterialsTechRadarChart'\n\n/**\n * 包名\n */\nexport const PACKAGE_NAME = '@easy-editor/materials-dashboard-tech-radar-chart'\n\n/**\n * 默认颜色\n */\nexport const DEFAULT_COLORS = ['#00d4ff', '#00ff88', '#ff6b6b', '#ffd93d', '#6bcbff', '#c56bff']\n\n/**\n * 默认维度\n */\nexport const DEFAULT_DIMENSIONS = ['Attack', 'Defense', 'Speed', 'Magic', 'HP']\n\n/**\n * 雷达图数据点类型\n */\nexport interface RadarDataPoint {\n dimension: string\n [key: string]: number | string | undefined\n}\n\n/**\n * 默认数据\n */\nexport const DEFAULT_DATA: RadarDataPoint[] = [\n { dimension: 'Attack', player1: 85, player2: 70 },\n { dimension: 'Defense', player1: 70, player2: 90 },\n { dimension: 'Speed', player1: 95, player2: 60 },\n { dimension: 'Magic', player1: 60, player2: 85 },\n { dimension: 'HP', player1: 75, player2: 80 },\n]\n\n/**\n * 默认系列配置\n */\nexport const DEFAULT_SERIES = [\n { name: 'Player 1', dataKey: 'player1', color: '#00d4ff' },\n { name: 'Player 2', dataKey: 'player2', color: '#00ff88' },\n]\n","import type { ComponentMetadata } from '@easy-editor/core'\nimport { MaterialGroup } from '@easy-editor/materials-shared'\nimport { COMPONENT_NAME, PACKAGE_NAME } from './constants'\nimport configure from './configure'\nimport snippets from './snippets'\nimport pkg from '../package.json'\n\nconst meta: ComponentMetadata = {\n componentName: COMPONENT_NAME,\n title: '雷达图',\n group: MaterialGroup.CHART,\n devMode: 'proCode',\n npm: {\n package: PACKAGE_NAME,\n version: pkg.version,\n globalName: COMPONENT_NAME,\n componentName: COMPONENT_NAME,\n },\n snippets,\n configure,\n}\n\nexport default meta\n","import type { Snippet } from '@easy-editor/core'\nimport { COMPONENT_NAME, DEFAULT_DATA, DEFAULT_SERIES } from './constants'\n\nconst snippets: Snippet[] = [\n {\n title: '雷达图',\n screenshot: '',\n schema: {\n componentName: COMPONENT_NAME,\n props: {\n data: DEFAULT_DATA,\n dimensionKey: 'dimension',\n series: DEFAULT_SERIES,\n showGrid: true,\n fillOpacity: 0.3,\n glowEffect: true,\n showLegend: true,\n },\n $dashboard: {\n rect: {\n width: 400,\n height: 300,\n },\n },\n },\n },\n {\n title: '单系列雷达图',\n screenshot: '',\n schema: {\n componentName: COMPONENT_NAME,\n props: {\n data: [\n { dimension: 'Attack', value: 85 },\n { dimension: 'Defense', value: 70 },\n { dimension: 'Speed', value: 95 },\n { dimension: 'Magic', value: 60 },\n { dimension: 'HP', value: 75 },\n ],\n dimensionKey: 'dimension',\n series: [{ name: 'Stats', dataKey: 'value', color: '#00d4ff' }],\n showGrid: true,\n fillOpacity: 0.4,\n glowEffect: true,\n showLegend: false,\n },\n $dashboard: {\n rect: {\n width: 400,\n height: 300,\n },\n },\n },\n },\n]\n\nexport default snippets\n","/**\n * Radar Chart Configure\n * 雷达图组件配置\n */\n\nimport type { Configure } from '@easy-editor/core'\n\nconst configure: Configure = {\n props: [\n {\n type: 'group',\n title: '属性',\n setter: 'TabSetter',\n items: [\n {\n type: 'group',\n key: 'config',\n title: '配置',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n // 基础配置\n {\n name: 'id',\n title: 'ID',\n setter: 'NodeIdSetter',\n extraProps: {\n // @ts-expect-error label is not a valid extra prop\n label: false,\n },\n },\n {\n name: 'title',\n title: '标题',\n setter: 'StringSetter',\n extraProps: {\n getValue(target) {\n return target.getExtraPropValue('title')\n },\n setValue(target, value) {\n target.setExtraPropValue('title', value)\n },\n },\n },\n {\n type: 'group',\n title: '基础属性',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n {\n name: 'rect',\n title: '位置尺寸',\n setter: 'RectSetter',\n extraProps: {\n getValue(target) {\n return target.getExtraPropValue('$dashboard.rect')\n },\n setValue(target, value) {\n target.setExtraPropValue('$dashboard.rect', value)\n },\n },\n },\n ],\n },\n // 组件配置\n {\n type: 'group',\n title: '数据',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n {\n name: 'data',\n title: '数据',\n setter: 'JsonSetter',\n },\n {\n name: 'dimensionKey',\n title: '维度字段',\n setter: 'StringSetter',\n extraProps: {\n defaultValue: 'dimension',\n },\n },\n {\n name: 'series',\n title: '系列',\n setter: 'JsonSetter',\n },\n ],\n },\n {\n type: 'group',\n title: '数值格式',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n {\n name: 'valuePrefix',\n title: '前缀',\n setter: 'StringSetter',\n },\n {\n name: 'valueSuffix',\n title: '后缀',\n setter: 'StringSetter',\n },\n {\n name: 'valueDecimals',\n title: '小数位数',\n setter: {\n componentName: 'NumberSetter',\n props: {\n suffix: '位',\n },\n },\n extraProps: {\n defaultValue: 0,\n },\n },\n ],\n },\n {\n type: 'group',\n title: '样式',\n setter: {\n componentName: 'CollapseSetter',\n props: {\n icon: false,\n },\n },\n items: [\n {\n name: 'showGrid',\n title: '显示网格',\n setter: 'SwitchSetter',\n extraProps: {\n defaultValue: true,\n },\n },\n {\n name: 'fillOpacity',\n title: '填充透明度',\n setter: {\n componentName: 'SliderSetter',\n props: {\n min: 0,\n max: 1,\n step: 0.1,\n },\n },\n extraProps: {\n defaultValue: 0.3,\n },\n },\n {\n name: 'showLegend',\n title: '显示图例',\n setter: 'SwitchSetter',\n extraProps: {\n defaultValue: true,\n },\n },\n {\n name: 'legendPosition',\n title: '图例位置',\n setter: {\n componentName: 'SelectSetter',\n props: {\n options: [\n { label: '顶部', value: 'top' },\n { label: '底部', value: 'bottom' },\n { label: '左侧', value: 'left' },\n { label: '右侧', value: 'right' },\n ],\n },\n },\n extraProps: {\n defaultValue: 'bottom',\n },\n },\n {\n name: 'glowEffect',\n title: '发光效果',\n setter: 'SwitchSetter',\n extraProps: {\n defaultValue: true,\n },\n },\n ],\n },\n ],\n },\n {\n type: 'group',\n key: 'data',\n title: '数据',\n items: [\n {\n name: 'dataBinding',\n title: '数据绑定',\n setter: 'DataBindingSetter',\n },\n ],\n },\n {\n type: 'group',\n key: 'advanced',\n title: '高级',\n items: [\n {\n name: 'condition',\n title: '显隐控制',\n setter: 'SwitchSetter',\n extraProps: {\n defaultValue: true,\n supportVariable: true,\n },\n },\n ],\n },\n ],\n },\n ],\n component: {},\n supports: {},\n advanced: {},\n}\n\nexport default configure\n"],"names":["COMPONENT_NAME","meta","componentName","title","group","devMode","npm","package","version","globalName","snippets","screenshot","schema","props","data","dimension","player1","player2","dimensionKey","series","name","dataKey","color","showGrid","fillOpacity","glowEffect","showLegend","$dashboard","rect","width","height","value","configure","type","setter","items","key","icon","extraProps","label","getValue","target","getExtraPropValue","setValue","setExtraPropValue","defaultValue","suffix","min","max","step","options","supportVariable","component","supports","advanced"],"mappings":"4QAMO,MCEMA,EAAiB,oCCD9B,MAAMC,EAA0B,CAC9BC,cAAeF,EACfG,MAAO,MACPC,MFEO,QEDPC,QAAS,UACTC,IAAK,CACHC,QDAwB,oDCCxBC,gBACAC,WAAYT,EACZE,cAAeF,GAEjBU,SCf0B,CAC1B,CACEP,MAAO,MACPQ,WAAY,GACZC,OAAQ,CACNV,cAAeF,EACfa,MAAO,CACLC,KF0BsC,CAC5C,CAAEC,UAAW,SAAUC,QAAS,GAAIC,QAAS,IAC7C,CAAEF,UAAW,UAAWC,QAAS,GAAIC,QAAS,IAC9C,CAAEF,UAAW,QAASC,QAAS,GAAIC,QAAS,IAC5C,CAAEF,UAAW,QAASC,QAAS,GAAIC,QAAS,IAC5C,CAAEF,UAAW,KAAMC,QAAS,GAAIC,QAAS,KE9BnCC,aAAc,YACdC,OFmCsB,CAC5B,CAAEC,KAAM,WAAYC,QAAS,UAAWC,MAAO,WAC/C,CAAEF,KAAM,WAAYC,QAAS,UAAWC,MAAO,YEpCzCC,UAAU,EACVC,YAAa,GACbC,YAAY,EACZC,YAAY,GAEdC,WAAY,CACVC,KAAM,CACJC,MAAO,IACPC,OAAQ,QAKhB,CACE3B,MAAO,SACPQ,WAAY,GACZC,OAAQ,CACNV,cAAeF,EACfa,MAAO,CACLC,KAAM,CACJ,CAAEC,UAAW,SAAUgB,MAAO,IAC9B,CAAEhB,UAAW,UAAWgB,MAAO,IAC/B,CAAEhB,UAAW,QAASgB,MAAO,IAC7B,CAAEhB,UAAW,QAASgB,MAAO,IAC7B,CAAEhB,UAAW,KAAMgB,MAAO,KAE5Bb,aAAc,YACdC,OAAQ,CA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V,CACEd,KAAM,cACNjB,MAAO,KACP+B,OAAQ,gBAEV,CACEd,KAAM,gBACNjB,MAAO,OACP+B,OAAQ,CACNhC,cAAe,eACfW,MAAO,CACLiC,OAAQ,MAGZR,WAAY,CACVO,aAAc,MAKtB,CACEZ,KAAM,QACN9B,MAAO,KACP+B,OAAQ,CACNhC,cAAe,iBACfW,MAAO,CACLwB,MAAM,IAGVF,MAAO,CACL,CACEf,KAAM,WACNjB,MAAO,OACP+B,OAAQ,eACRI,WAAY,CACVO,cAAc,IAGlB,CACEzB,KAAM,cACNjB,MAAO,QACP+B,OAAQ,CACNhC,cAAe,eACfW,MAAO,CACLkC,IAAK,EACLC,IAAK,EACLC,KAAM,KAGVX,WAAY,CACVO,aAAc,KAGlB,CACEzB,KAAM,aACNjB,MAAO,OACP+B,OAAQ,eACRI,WAAY,CACVO,cAAc,IAGlB,CACEzB,KAAM,iBACNjB,MAAO,OACP+B,OAAQ,CACNhC,cAAe,eACfW,MAAO,CACLqC,QAAS,CACP,CAAEX,MAAO,KAAMR,MAAO,OACtB,CAAEQ,MAAO,KAAMR,MAAO,UACtB,CAAEQ,MAAO,KAAMR,MAAO,QACtB,CAAEQ,MAAO,KAAMR,MAAO,YAI5BO,WAAY,CACVO,aAAc,WAGlB,CACEzB,KAAM,aACNjB,MAAO,OACP+B,OAAQ,eACRI,WAAY,CACVO,cAAc,QAO1B,CACEZ,KAAM,QACNG,IAAK,OACLjC,MAAO,KACPgC,MAAO,CACL,CACEf,KAAM,cACNjB,MAAO,OACP+B,OAAQ,uBAId,CACED,KAAM,QACNG,IAAK,WACLjC,MAAO,KACPgC,MAAO,CACL,CACEf,KAAM,YACNjB,MAAO,OACP+B,OAAQ,eACRI,WAAY,CACVO,cAAc,EACdM,iBAAiB,SAQ/BC,UAAW,CAAA,EACXC,SAAU,CAAA,EACVC,SAAU,CAAA"}
@@ -0,0 +1,21 @@
1
+ import { type CSSProperties, type Ref } from 'react';
2
+ import { type RadarDataPoint } from './constants';
3
+ interface RadarSeries {
4
+ name: string;
5
+ dataKey: string;
6
+ color: string;
7
+ }
8
+ interface RadarChartProps {
9
+ ref?: Ref<HTMLDivElement>;
10
+ data?: RadarDataPoint[];
11
+ dimensionKey?: string;
12
+ series?: RadarSeries[];
13
+ showGrid?: boolean;
14
+ fillOpacity?: number;
15
+ glowEffect?: boolean;
16
+ showLegend?: boolean;
17
+ showTooltip?: boolean;
18
+ style?: CSSProperties;
19
+ }
20
+ declare const RadarChartComponent: (props: RadarChartProps) => import("react/jsx-runtime").JSX.Element;
21
+ export default RadarChartComponent;
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Radar Chart Configure
3
+ * 雷达图组件配置
4
+ */
5
+ import type { Configure } from '@easy-editor/core';
6
+ declare const configure: Configure;
7
+ export default configure;
@@ -0,0 +1,39 @@
1
+ /**
2
+ * 物料常量配置
3
+ * 统一管理全局变量名等配置,确保 meta.ts 和 rollup.config.js 使用相同的值
4
+ */
5
+ /**
6
+ * UMD 全局变量基础名称
7
+ */
8
+ export declare const COMPONENT_NAME = "EasyEditorMaterialsTechRadarChart";
9
+ /**
10
+ * 包名
11
+ */
12
+ export declare const PACKAGE_NAME = "@easy-editor/materials-dashboard-tech-radar-chart";
13
+ /**
14
+ * 默认颜色
15
+ */
16
+ export declare const DEFAULT_COLORS: string[];
17
+ /**
18
+ * 默认维度
19
+ */
20
+ export declare const DEFAULT_DIMENSIONS: string[];
21
+ /**
22
+ * 雷达图数据点类型
23
+ */
24
+ export interface RadarDataPoint {
25
+ dimension: string;
26
+ [key: string]: number | string | undefined;
27
+ }
28
+ /**
29
+ * 默认数据
30
+ */
31
+ export declare const DEFAULT_DATA: RadarDataPoint[];
32
+ /**
33
+ * 默认系列配置
34
+ */
35
+ export declare const DEFAULT_SERIES: {
36
+ name: string;
37
+ dataKey: string;
38
+ color: string;
39
+ }[];
@@ -0,0 +1,6 @@
1
+ /**
2
+ * RadarChart Entry
3
+ * 雷达图组件入口
4
+ */
5
+ export { default as component } from './component';
6
+ export { default as meta } from './meta';
@@ -0,0 +1,3 @@
1
+ import type { ComponentMetadata } from '@easy-editor/core';
2
+ declare const meta: ComponentMetadata;
3
+ export default meta;
@@ -0,0 +1,3 @@
1
+ import type { Snippet } from '@easy-editor/core';
2
+ declare const snippets: Snippet[];
3
+ export default snippets;
package/package.json ADDED
@@ -0,0 +1,68 @@
1
+ {
2
+ "name": "@easy-editor/materials-dashboard-radar-chart",
3
+ "version": "0.0.2",
4
+ "description": "Radar Chart component for EasyEditor dashboard",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "types": "dist/index.d.ts",
8
+ "exports": {
9
+ ".": {
10
+ "types": "./dist/index.d.ts",
11
+ "import": "./dist/index.esm.js",
12
+ "require": "./dist/index.cjs"
13
+ }
14
+ },
15
+ "publishConfig": {
16
+ "access": "public",
17
+ "jsdelivr": "dist/index.min.js",
18
+ "registry": "https://registry.npmjs.org/"
19
+ },
20
+ "homepage": "https://github.com/Easy-Editor/EasyMaterials",
21
+ "license": "MIT",
22
+ "author": "JinSo <kimjinso@qq.com>",
23
+ "keywords": [
24
+ "@easy-editor",
25
+ "easyeditor",
26
+ "low-code",
27
+ "dashboard",
28
+ "radar-chart",
29
+ "spider-chart",
30
+ "echarts",
31
+ "component",
32
+ "react"
33
+ ],
34
+ "repository": {
35
+ "type": "git",
36
+ "url": "https://github.com/Easy-Editor/EasyMaterials",
37
+ "directory": "packages/dashboard/chart/radar-chart"
38
+ },
39
+ "bugs": {
40
+ "url": "https://github.com/Easy-Editor/EasyMaterials/issues"
41
+ },
42
+ "peerDependencies": {
43
+ "@easy-editor/core": "*",
44
+ "react": "^18 || ^19",
45
+ "react-dom": "^18 || ^19",
46
+ "@types/react": "^18 || ^19",
47
+ "@types/react-dom": "^18 || ^19"
48
+ },
49
+ "dependencies": {
50
+ "echarts": "^5.6.0",
51
+ "@easy-editor/materials-shared": "0.0.0"
52
+ },
53
+ "scripts": {
54
+ "dev": "vite",
55
+ "dev:debug": "vite --port 5005",
56
+ "format": "biome format --write .",
57
+ "lint": "biome check .",
58
+ "build": "npm-run-all -nl build:*",
59
+ "build:clean": "rimraf dist/",
60
+ "build:js": "rollup -c",
61
+ "build:types": "pnpm types",
62
+ "types": "npm-run-all -nl types:*",
63
+ "types:src": "tsc --project tsconfig.build.json",
64
+ "test-types": "tsc --project tsconfig.test.json"
65
+ },
66
+ "module": "dist/index.esm.js",
67
+ "unpkg": "dist/index.min.js"
68
+ }