wangrong
2026-08-30 761e5c5fa871959f60e15c971c8d83f2b53d0af5
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
declare type EditorProperty =
  | 'background-overall-component'
  | 'border-style'
  | 'basic-style-selector'
  | 'symbolic-style-selector'
  | 'dual-basic-style-selector'
  | 'label-selector'
  | 'tooltip-selector'
  | 'x-axis-selector'
  | 'y-axis-selector'
  | 'dual-y-axis-selector'
  | 'title-selector'
  | 'legend-selector'
  | 'table-header-selector'
  | 'table-cell-selector'
  | 'table-total-selector'
  | 'text-selector'
  | 'misc-selector'
  | 'misc-style-selector'
  | 'function-cfg'
  | 'assist-line'
  | 'scroll-cfg'
  | 'threshold'
  | 'map-mapping'
  | 'jump-set'
  | 'linkage'
  | 'indicator-value-selector'
  | 'indicator-name-selector'
  | 'quadrant-selector'
  | 'map-symbolic-selector'
  | 'flow-map-line-selector'
  | 'flow-map-point-selector'
  | 'bubble-animate'
  | 'summary-selector'
  | 'bullet-graph-selector'
declare type EditorPropertyInner = {
  [key in EditorProperty]?: string[]
}
 
declare type EditorSelectorSpec = {
  [key in EditorProperty]?: {
    title: string
  }
}
/**
 * 轴类型
 */
declare type AxisType =
  | 'xAxis'
  | 'yAxis'
  | 'xAxisExt'
  | 'xAxisExtRight'
  | 'yAxisExt'
  | 'extBubble'
  | 'drill'
  | 'filter'
  | 'extStack'
  | 'extLabel'
  | 'extTooltip'
  | 'area'
  | 'flowMapStartName'
  | 'flowMapEndName'
  | 'extColor'
  | 'drillFields'
/**
 * 轴配置
 */
declare type AxisConfig = {
  [key in AxisType]?: AxisSpec
}
/**
 * 轴类型详细配置
 */
declare type AxisSpec = {
  /**
   * 轴名称
   */
  name: string
  /**
   * 轴类型限制, 没有表示不限制
   */
  type?: 'q' | 'd'
  /**
   * 轴维度/指标数量限制, 0表示不限制
   */
  limit?: number
  /**
   * 轴是否允许重复
   */
  duplicate?: boolean
  /**
   * 轴提示
   */
  tooltip?: string
  /**
   * 允许为空
   */
  allowEmpty?: boolean
}
/**
 * 图表编辑表单
 */
declare interface ChartEditorForm<T> {
  /**
   * 属性表单
   */
  data: T
  /**
   * 是否拉取数据
   */
  requestData: boolean
  /**
   * 是否渲染图表
   */
  render: boolean
  /**
   * 子属性
   */
  prop?: string
}
/**
 * 轴编辑表单
 */
declare interface AxisEditForm {
  /**
   * 轴类型
   */
  axisType: AxisType
  /**
   * 变更内容
   */
  axis: Axis[]
  /**
   * 变更类型
   */
  editType: 'add' | 'remove' | 'update'
}