diff --git a/core/core-frontend/src/assets/svg/circle-packing-dark.svg b/core/core-frontend/src/assets/svg/circle-packing-dark.svg new file mode 100644 index 0000000000..0e663153ae --- /dev/null +++ b/core/core-frontend/src/assets/svg/circle-packing-dark.svg @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/core/core-frontend/src/assets/svg/circle-packing-origin.svg b/core/core-frontend/src/assets/svg/circle-packing-origin.svg new file mode 100644 index 0000000000..f71ca3188f --- /dev/null +++ b/core/core-frontend/src/assets/svg/circle-packing-origin.svg @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/core/core-frontend/src/assets/svg/circle-packing.svg b/core/core-frontend/src/assets/svg/circle-packing.svg new file mode 100644 index 0000000000..73380f1ad1 --- /dev/null +++ b/core/core-frontend/src/assets/svg/circle-packing.svg @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/core/core-frontend/src/components/data-visualization/RealTimeGroup.vue b/core/core-frontend/src/components/data-visualization/RealTimeGroup.vue index b95b564845..7e0ad8f61f 100644 --- a/core/core-frontend/src/components/data-visualization/RealTimeGroup.vue +++ b/core/core-frontend/src/components/data-visualization/RealTimeGroup.vue @@ -73,6 +73,7 @@ import { lockStoreWithOut } from '@/store/modules/data-visualization/lock' import ContextMenuAsideDetails from '@/components/data-visualization/canvas/ContextMenuAsideDetails.vue' import ComposeShow from '@/components/data-visualization/canvas/ComposeShow.vue' import { composeStoreWithOut } from '@/store/modules/data-visualization/compose' +import circlePackingOrigin from '@/assets/svg/circle-packing-origin.svg' const dropdownMore = ref(null) const lockStore = lockStoreWithOut() @@ -233,7 +234,8 @@ const iconMap = { 'waterfall-origin': waterfallOrigin, 'word-cloud-origin': wordCloudOrigin, 't-heatmap-origin': tHeatmapOrigin, - group: group + group: group, + 'circle-packing-origin': circlePackingOrigin } const getIconName = item => { if (item.component === 'UserView') { diff --git a/core/core-frontend/src/components/data-visualization/RealTimeListTree.vue b/core/core-frontend/src/components/data-visualization/RealTimeListTree.vue index 80d6ed94c1..3ca41f7241 100644 --- a/core/core-frontend/src/components/data-visualization/RealTimeListTree.vue +++ b/core/core-frontend/src/components/data-visualization/RealTimeListTree.vue @@ -80,6 +80,7 @@ import RealTimeGroup from '@/components/data-visualization/RealTimeGroup.vue' import { contextmenuStoreWithOut } from '@/store/modules/data-visualization/contextmenu' import RealTimeTab from '@/components/data-visualization/RealTimeTab.vue' import { useI18n } from '@/hooks/web/useI18n' +import circlePackingOrigin from '@/assets/svg/circle-packing-origin.svg' const dropdownMore = ref(null) const lockStore = lockStoreWithOut() @@ -329,7 +330,8 @@ const iconMap = { 'word-cloud-origin': wordCloudOrigin, 't-heatmap-origin': tHeatmapOrigin, 'picture-group-origin': pictureGroupOrigin, - group: group + group: group, + 'circle-packing-origin': circlePackingOrigin } const getIconName = item => { if (item.component === 'UserView') { diff --git a/core/core-frontend/src/components/data-visualization/canvas/Shape.vue b/core/core-frontend/src/components/data-visualization/canvas/Shape.vue index cebb5d13e4..9cbb9afa34 100644 --- a/core/core-frontend/src/components/data-visualization/canvas/Shape.vue +++ b/core/core-frontend/src/components/data-visualization/canvas/Shape.vue @@ -344,7 +344,8 @@ const boardMoveActive = computed(() => { 'table-pivot', 'symbolic-map', 'heat-map', - 't-heatmap' + 't-heatmap', + 'circle-packing' ] return element.value.isPlugin || CHARTS.includes(element.value.innerType) }) diff --git a/core/core-frontend/src/components/icon-group/chart-dark-list.ts b/core/core-frontend/src/components/icon-group/chart-dark-list.ts index fafc88eb6f..600db62b32 100644 --- a/core/core-frontend/src/components/icon-group/chart-dark-list.ts +++ b/core/core-frontend/src/components/icon-group/chart-dark-list.ts @@ -42,6 +42,7 @@ import treemapDark from '@/assets/svg/treemap-dark.svg' import waterfallDark from '@/assets/svg/waterfall-dark.svg' import wordCloudDark from '@/assets/svg/word-cloud-dark.svg' import tHeatmapDark from '@/assets/svg/t-heatmap-dark.svg' +import circlePackingDark from '@/assets/svg/circle-packing-dark.svg' const iconChartDarkMap = { 'area-dark': areaDark, @@ -87,7 +88,8 @@ const iconChartDarkMap = { 'treemap-dark': treemapDark, 'waterfall-dark': waterfallDark, 'word-cloud-dark': wordCloudDark, - 't-heatmap-dark': tHeatmapDark + 't-heatmap-dark': tHeatmapDark, + 'circle-packing-dark': circlePackingDark } export { iconChartDarkMap } diff --git a/core/core-frontend/src/components/icon-group/chart-list.ts b/core/core-frontend/src/components/icon-group/chart-list.ts index 62d5e92047..02e6ba93c9 100644 --- a/core/core-frontend/src/components/icon-group/chart-list.ts +++ b/core/core-frontend/src/components/icon-group/chart-list.ts @@ -45,6 +45,7 @@ import tHeatmap from '@/assets/svg/t-heatmap.svg' import pictureGroup from '@/assets/svg/picture-group.svg' import filter from '@/assets/svg/filter.svg' import outerParams from '@/assets/svg/icon_params_setting.svg' +import circlePacking from '@/assets/svg/circle-packing.svg' const iconChartMap = { 'area-stack': areaStack, @@ -93,7 +94,8 @@ const iconChartMap = { 't-heatmap': tHeatmap, 'picture-group': pictureGroup, filter: filter, - outerParams: outerParams + outerParams: outerParams, + 'circle-packing': circlePacking } export { iconChartMap } diff --git a/core/core-frontend/src/locales/en-US.ts b/core/core-frontend/src/locales/en-US.ts index 657fa11c58..78e95398ca 100644 --- a/core/core-frontend/src/locales/en-US.ts +++ b/core/core-frontend/src/locales/en-US.ts @@ -1919,7 +1919,13 @@ export default { 'When Customizing, Supports SVG, JPG, JPEG, and PNG files up to 1MB', size_range: 'Size Range', x_axis_constant_line: 'X-axis Constant Line', - y_axis_constant_line: 'Y-axis Constant Line' + y_axis_constant_line: 'Y-axis Constant Line', + chart_circle_packing: 'Circle Packing Chart', + circle_packing_name: 'Circle Name', + circle_packing_value: 'Circle Size', + circle_packing_border_color: 'Border color', + circle_packing_border_width: 'Border width', + circle_packing_padding: 'Circle padding' }, dataset: { scope_edit: 'Only effective when editing', diff --git a/core/core-frontend/src/locales/en.ts b/core/core-frontend/src/locales/en.ts index c021897ac2..da17c86632 100644 --- a/core/core-frontend/src/locales/en.ts +++ b/core/core-frontend/src/locales/en.ts @@ -1919,7 +1919,13 @@ Scatter chart (bubble) chart: {a} (series name), {b} (data name), {c} (value arr x_axis_constant_line: 'X-axis Constant Line', y_axis_constant_line: 'Y-axis Constant Line', sort_priority: 'Sort Priority Setting', - sort_priority_tip: 'Top-down, sorting priority from highest to lowest' + sort_priority_tip: 'Top-down, sorting priority from highest to lowest', + chart_circle_packing: 'Circle packing chart', + circle_packing_name: 'Circle name', + circle_packing_value: 'Circle size', + circle_packing_border_color: 'Border color', + circle_packing_border_width: 'Border width', + circle_packing_padding: 'Circle padding' }, dataset: { scope_edit: 'Only effective when editing', diff --git a/core/core-frontend/src/locales/tw.ts b/core/core-frontend/src/locales/tw.ts index cc68a55e07..d0b2eaeec4 100644 --- a/core/core-frontend/src/locales/tw.ts +++ b/core/core-frontend/src/locales/tw.ts @@ -1877,7 +1877,13 @@ export default { x_axis_constant_line: 'X 軸恆線', y_axis_constant_line: 'Y 軸恆線', sort_priority: '排序優先級設置', - sort_priority_tip: '自上而下,排序優先級從高到低' + sort_priority_tip: '自上而下,排序優先級從高到低', + chart_circle_packing: '圓形填充圖', + circle_packing_name: '圓形名稱', + circle_packing_value: '圓形大小', + circle_packing_border_color: '邊線顏色', + circle_packing_border_width: '邊線寬度', + circle_packing_padding: 'Circle padding' }, dataset: { scope_edit: '僅編輯時生效', diff --git a/core/core-frontend/src/locales/zh-CN.ts b/core/core-frontend/src/locales/zh-CN.ts index 3c826cc8cb..120790bd3e 100644 --- a/core/core-frontend/src/locales/zh-CN.ts +++ b/core/core-frontend/src/locales/zh-CN.ts @@ -1879,7 +1879,13 @@ export default { x_axis_constant_line: 'X 轴恒线', y_axis_constant_line: 'Y 轴恒线', sort_priority: '排序优先级设置', - sort_priority_tip: '自上而下,排序优先级从高到低' + sort_priority_tip: '自上而下,排序优先级从高到低', + chart_circle_packing: '圆形填充图', + circle_packing_name: '圆形名称', + circle_packing_value: '圆形大小', + circle_packing_border_color: '边线颜色', + circle_packing_border_width: '边线宽度', + circle_packing_padding: '圓形間距' }, dataset: { scope_edit: '仅编辑时生效', diff --git a/core/core-frontend/src/models/chart/chart-attr.d.ts b/core/core-frontend/src/models/chart/chart-attr.d.ts index e225245851..a8dffeb79b 100644 --- a/core/core-frontend/src/models/chart/chart-attr.d.ts +++ b/core/core-frontend/src/models/chart/chart-attr.d.ts @@ -350,6 +350,18 @@ declare interface ChartBasicStyle { * 雷达图面积颜色开关 */ radarAreaColor: boolean + /** + * 圆形填充图边线颜色 + */ + circleBorderColor: string + /** + * 圆形填充图边线宽度 + */ + circleBorderWidth: number + /** + * 圆形填充图间距 + */ + circlePadding: number } /** * 表头属性 diff --git a/core/core-frontend/src/views/chart/components/editor/editor-senior/components/FunctionCfg.vue b/core/core-frontend/src/views/chart/components/editor/editor-senior/components/FunctionCfg.vue index c101282c54..1278e3eced 100644 --- a/core/core-frontend/src/views/chart/components/editor/editor-senior/components/FunctionCfg.vue +++ b/core/core-frontend/src/views/chart/components/editor/editor-senior/components/FunctionCfg.vue @@ -93,6 +93,9 @@ const initFieldCtrl = () => { }) } } +const isCirclePacking = computed(() => { + return equalsAny(props.chart.type, 'circle-packing') +}) onMounted(() => { init() }) @@ -196,7 +199,9 @@ onMounted(() => { 自定义 - {{ t('chart.set_zero') }} + {{ + t('chart.set_zero') + }} {{ t('chart.ignore_data') }} diff --git a/core/core-frontend/src/views/chart/components/editor/editor-style/components/BasicStyleSelector.vue b/core/core-frontend/src/views/chart/components/editor/editor-style/components/BasicStyleSelector.vue index 33f2408113..0fa8084a8d 100644 --- a/core/core-frontend/src/views/chart/components/editor/editor-style/components/BasicStyleSelector.vue +++ b/core/core-frontend/src/views/chart/components/editor/editor-style/components/BasicStyleSelector.vue @@ -13,7 +13,7 @@ import { SERIES_NUMBER_FIELD } from '@antv/s2' import { dvMainStoreWithOut } from '@/store/modules/data-visualization/dvMain' import { storeToRefs } from 'pinia' import { isNumber } from 'mathjs' -import { ElMessage, UploadProps } from 'element-plus-secondary' +import { ElFormItem, ElInputNumber, ElMessage, UploadProps } from 'element-plus-secondary' import { svgStrToUrl } from '../../../js/util' const dvMainStore = dvMainStoreWithOut() @@ -1389,6 +1389,69 @@ onMounted(() => { + + + + + + + + + + + + + + + + + + + + + + + + + +