Skip to content

Add Control options and styles to remote component. #1393

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 18 commits into from
Dec 31, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
3eafcd5
Fixed background Color and built type structure of gauge chart.
Imiss-U1025 Dec 20, 2024
bb1d2b5
Added Stage Speed Gauge, Grade Gauge, Temperature Gauge chart, Multi …
Imiss-U1025 Dec 20, 2024
4c790a7
Fixed Conditional statements.
Imiss-U1025 Dec 20, 2024
bbdcfe7
Added Stage clock to gauge chart(not editing).
Imiss-U1025 Dec 20, 2024
da4216e
Added dataZoom, grid to candleStick chart.
Imiss-U1025 Dec 20, 2024
a06f57a
Added an editing ability on Stage Gauge chart.
Imiss-U1025 Dec 23, 2024
67c0472
Added an editing ability on Grade Gauge chart.
Imiss-U1025 Dec 24, 2024
7209f93
Added an editing ability on Temperature Gauge chart.
Imiss-U1025 Dec 25, 2024
8c23506
Fixed an editing ability on Temperature Gauge chart.
Imiss-U1025 Dec 26, 2024
5d7020c
Fixed an editing ability on Multi Title and Ring chart.
Imiss-U1025 Dec 26, 2024
ab040d8
Converted repetitive control fields to JSON option, optimize and clea…
Imiss-U1025 Dec 27, 2024
c87b7b3
Fixed an editing ability on Clock chart.
Imiss-U1025 Dec 28, 2024
186aa15
Fixed Clock Pointer Icons on Clock Chart.
Imiss-U1025 Dec 28, 2024
d7e5a2d
Fixed an editing ability on Barometer chart.
Imiss-U1025 Dec 28, 2024
6056207
Fixed some issues and added border and detailSize to Detail Style.
Imiss-U1025 Dec 30, 2024
3d30bad
Fixed a border Radius on styleWrapper.
Imiss-U1025 Dec 30, 2024
0531190
Fixed tooltip and formatters on all gauge chart
Imiss-U1025 Dec 30, 2024
b0078ef
Merge branch 'dev' into feature-funnelChart
raheeliftikhar5 Dec 31, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fixed a border Radius on styleWrapper.
  • Loading branch information
Imiss-U1025 committed Dec 30, 2024
commit 3d30bade948c2cf3ec5b51d8e7daa72b34656c37
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,7 @@ let chartJsonModeChildren: any = {
gradePointerIcon:withDefault(StringControl, trans('gaugeChart.gradeDefaultPointerIcon')),
clockPointerIcon:withDefault(StringControl, trans('gaugeChart.clockDefaultPointerIcon')),
barometerPointerIcon:withDefault(StringControl, trans('gaugeChart.defaultBarometerPointerIcon')),
multiTitlePointerIcon:withDefault(StringControl, trans('gaugeChart.defaultMultiTitlePointerIcon')),
progressBarWidth:withDefault(NumberControl,trans('gaugeChart.defaultProgressBarWidth')),
axisTickWidth: withDefault(NumberControl, trans('gaugeChart.defaultAxisTickWidth')),
axisTickLength: withDefault(NumberControl, trans('gaugeChart.defaultAxisTickLength')),
Expand All @@ -324,6 +325,7 @@ let chartJsonModeChildren: any = {
gradeGaugePointer_Y:withDefault(NumberControl,trans('gaugeChart.defaultGradeGaugePointer_Y')),
stageProgressBarWidth:withDefault(NumberControl,trans('gaugeChart.defaultStageProgressBarWidth')),
temperatureProgressBarWidth:withDefault(NumberControl,trans('gaugeChart.defaultTemperatureProgressBarWidth')),
ringProgressBarWidth:withDefault(NumberControl,trans('gaugeChart.defaultRingProgressBarWidth')),
temperatureAxisLabelDistance:withDefault(NumberControl,trans('gaugeChart.defaultTemperatureAxisLabelDistance')),
stageAxisTickColor: withDefault(ColorControl, trans('gaugeChart.defaultStageAxisTickColor')),
gradeAxisTickColor: withDefault(ColorControl),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ export function gaugeChartPropertyView(
{children.pointerLength.propertyView({ label: trans("gaugeChart.pointerLength"), tooltip: trans("echarts.pointerLengthTooltip") })}
{children.pointerWidth.propertyView({ label: trans("gaugeChart.pointerWidth"), tooltip: trans("echarts.pointerWidthTooltip") })}
{children.pointer_Y.propertyView({ label: trans("gaugeChart.pointer_Y"), tooltip: trans("gaugeChart.pointer_Y_Tooltip") })}
{children.pointerIcon.propertyView({ label: trans("gaugeChart.pointerIcon"), tooltip: trans("gaugeChart.pointerIconTooltip") })}
{children.multiTitlePointerIcon.propertyView({ label: trans("gaugeChart.pointerIcon"), tooltip: trans("gaugeChart.pointerIconTooltip") })}
{children.progressBarWidth.propertyView({ label: trans("gaugeChart.progressBarWidth"), tooltip: trans("echarts.pointerWidthTooltip") })}
{children.tooltip.propertyView({ label: trans("gaugeChart.tooltip"), tooltip: trans("echarts.tooltipVisibilityTooltip") })}
{children.roundCap.propertyView({ label: trans("gaugeChart.roundCap"), tooltip: trans("echarts.roundCapVisibilityTooltip") })}
Expand Down Expand Up @@ -357,7 +357,7 @@ export function gaugeChartPropertyView(
{children.max.propertyView({ label: trans("gaugeChart.max"), tooltip: trans("echarts.maxTooltip") })}
{children.position_x.propertyView({ label: trans("gaugeChart.position_x"), tooltip: trans("echarts.positionChart_x_Tooltip") })}
{children.position_y.propertyView({ label: trans("gaugeChart.position_y"), tooltip: trans("echarts.positionChart_x_Tooltip") })}
{children.progressBarWidth.propertyView({ label: trans("gaugeChart.progressBarWidth"), tooltip: trans("echarts.pointerWidthTooltip") })}
{children.ringProgressBarWidth.propertyView({ label: trans("gaugeChart.progressBarWidth"), tooltip: trans("echarts.pointerWidthTooltip") })}
{children.tooltip.propertyView({ label: trans("gaugeChart.tooltip"), tooltip: trans("echarts.tooltipVisibilityTooltip") })}
{children.roundCap.propertyView({ label: trans("gaugeChart.roundCap"), tooltip: trans("echarts.roundCapVisibilityTooltip") })}
</Section>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ export function getEchartsConfig(
"borderColor": styleContainer?.chartBorderColor || themeContainer?.borderColor || 'inherit',
"borderWidth": styleContainer?.chartBorderWidth || themeContainer?.borderWidth || detailBorderWidth,
"borderType": styleContainer?.chartBorderStyle || themeContainer?.borderType,
"borderRadius": styleContainer?.chartBorderRadius || themeContainer?.borderRadius,
"borderRadius": Number(styleContainer?.chartBorderRadius || themeContainer?.borderRadius),
"backgroundColor": styleContainer?.chartBackgroundColor || themeContainer?.backgroundColor || defaultBackgroundColor,
"width": styleContainer?.detailSize?.split('px')[0] || themeContainer?.detailSize.split('px')[0] || 24,
"height": styleContainer?.detailSize?.split('px')[1] || themeContainer?.detailSize.split('px')[1] || 12,
Expand Down Expand Up @@ -218,7 +218,7 @@ export function getEchartsConfig(
"borderColor": props?.chartStyle?.chartBorderColor || theme?.chartStyle?.borderColor,
"borderWidth": props?.chartStyle?.chartBorderWidth || theme?.chartStyle?.borderWidth,
"borderType": props?.chartStyle?.chartBorderStyle || theme?.chartStyle?.borderType,
"borderRadius": props?.chartStyle?.chartBorderRadius || theme?.chartStyle?.borderRadius,
"borderRadius": Number(props?.chartStyle?.chartBorderRadius || theme?.chartStyle?.borderRadius),
"shadowColor": props?.chartStyle?.chartShadowColor || theme?.chartStyle?.shadowColor,
"shadowBlur": props?.chartStyle?.chartBoxShadow?.split('px')[0] || theme?.chartStyle?.boxShadow?.split('px')[0],
"shadowOffsetX": props?.chartStyle?.chartBoxShadow?.split('px')[1] || theme?.chartStyle?.boxShadow?.split('px')[1],
Expand Down Expand Up @@ -386,7 +386,7 @@ export function getEchartsConfig(
anchor: {
show: true,
showAbove: true,
size: 10,
size: Number(props?.pointerWidth) * 1.5,
itemStyle: {
color: props?.multiTitleGaugeOption?.data[0]["value"].slice(-1)[0]
}
Expand Down Expand Up @@ -419,6 +419,10 @@ export function getEchartsConfig(
title: {
...styleWrapper(props?.labelStyle, theme?.labelStyle, 16),
},
pointer: {
...basicSeries.pointer,
icon: props?.multiTitlePointerIcon,
},
detail: {
...styleWrapper(props?.legendStyle, theme?.legendStyle, 16, '#ffffff', 0, 'inherit'),
formatter: props?.multiTitleGaugeOption?.data?.map(data => data.formatter)[0],
Expand Down Expand Up @@ -535,17 +539,18 @@ export function getEchartsConfig(
show: false
},
progress: {
"roundCap": props.roundCap,
roundCap: props?.roundCap,
show: true,
width: props?.progressBarWidth,
width: props?.ringProgressBarWidth,
overlap: false,
clip: false,
},
// axisLine: {
// lineStyle: {
// width: 20 // Reduced from 40
// }
// },
axisLine: {
roundCap: props?.roundCap,
lineStyle: {
width: props?.ringProgressBarWidth
}
},
splitLine: {
show: false
},
Expand Down
2 changes: 2 additions & 0 deletions client/packages/lowcoder-comps/src/i18n/comps/locales/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ export const en = {
defaultProgressBarWidth: '10',
defaultStageProgressBarWidth: '15',
defaultTemperatureProgressBarWidth: '35',
defaultRingProgressBarWidth: '20',
progressBar: 'Progress Bar',
roundCap: "Round Cap",
chartType: "Chart Type",
Expand All @@ -147,6 +148,7 @@ export const en = {
gradeDefaultPointerIcon: "path://M12.8,0.7l12,40.1H0.7L12.8,0.7z",
clockDefaultPointerIcon: "path://M2.9,0.7L2.9,0.7c1.4,0,2.6,1.2,2.6,2.6v115c0,1.4-1.2,2.6-2.6,2.6l0,0c-1.4,0-2.6-1.2-2.6-2.6V3.3C0.3,1.9,1.4,0.7,2.9,0.7z",
defaultBarometerPointerIcon: 'path://M2090.36389,615.30999 L2090.36389,615.30999 C2091.48372,615.30999 2092.40383,616.194028 2092.44859,617.312956 L2096.90698,728.755929 C2097.05155,732.369577 2094.2393,735.416212 2090.62566,735.56078 C2090.53845,735.564269 2090.45117,735.566014 2090.36389,735.566014 L2090.36389,735.566014 C2086.74736,735.566014 2083.81557,732.63423 2083.81557,729.017692 C2083.81557,728.930412 2083.81732,728.84314 2083.82081,728.755929 L2088.2792,617.312956 C2088.32396,616.194028 2089.24407,615.30999 2090.36389,615.30999 Z',
defaultMultiTitlePointerIcon: 'path://M2.9,0.7L2.9,0.7c1.4,0,2.6,1.2,2.6,2.6v115c0,1.4-1.2,2.6-2.6,2.6l0,0c-1.4,0-2.6-1.2-2.6-2.6V3.3C0.3,1.9,1.4,0.7,2.9,0.7z',
pointer_Y: "Pointer-Y",
pointer_Y_Tooltip: "select vertical of pointer",
pointerIcon: "Pointer Icon",
Expand Down
Loading