Skip to content

Dev > Main for Release v2.4.2 #1016

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 201 commits into from
Jul 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
201 commits
Select commit Hold shift + click to select a range
28bc24c
Write test case for findAllAuthConfigs and passed!
May 13, 2024
ddcf07f
Remove bundleposition from application api
Jun 3, 2024
9cc00a9
Merge remote-tracking branch 'origin/feature/bundle' into feature/bundle
Jun 3, 2024
08d6054
Merge branch 'refs/heads/dev' into feature/bundle
Jun 3, 2024
c83e0e7
change bundle elements api url format
Jun 3, 2024
cae93bb
Merge branch 'dev' of https://github.com/th37rose/lowcoder_dev1 into …
Jun 3, 2024
4b5a56a
Merge branch 'lowcoder-org:main' into feature/generic-oauth
th37rose Jun 3, 2024
19eea87
Add generic oauth login integration test case
Jun 4, 2024
b9ab638
Merge remote-tracking branch 'origin/feature/generic-oauth' into feat…
Jun 4, 2024
bb5360b
enable test redis server
Jun 4, 2024
0213003
test case with no refresh endpoint
Jun 4, 2024
1713475
remove isTest
Jun 6, 2024
24f47d7
Add exception handler to event publisher
Jun 7, 2024
706ace3
Add Bundle DSP
Jun 11, 2024
a9b10c7
Fix issues add/move app
Jun 11, 2024
5fc238d
Merge branch 'dev' into feature/bundle
th37rose Jun 11, 2024
ad91755
publish API & test case.
Jun 11, 2024
1122e9b
Merge remote-tracking branch 'origin/feature/bundle' into feature/bundle
Jun 11, 2024
92c2845
Remove session mock and add WithMockUser annotation.
Jun 11, 2024
0c4ac50
Bundle Test Case Finished
Jun 11, 2024
a59dd49
Merge branch 'dev' into feature/bundle
th37rose Jun 11, 2024
0d59fe0
Merge conflict resolved
Jun 11, 2024
c827ae3
Create a GID and change ApplicationRepository to use GID.
Jun 14, 2024
065b657
Add GID to ApplicationInfoView
Jun 14, 2024
cde6f53
Add GID to bundle
Jun 14, 2024
d57585a
Refactor code
Jun 14, 2024
3f88b5b
Merge dev to gid
Jun 15, 2024
5221870
use UUIDv7
Jun 17, 2024
3d00ac1
Add GID to folder
Jun 17, 2024
e2ebc84
Fix error
Jun 18, 2024
4aac42e
move initialization of gid to create endpoint
Jun 18, 2024
1493cf9
Merge pull request #971 from lowcoder-org/fix-kanban-draggable-bug
FalkWolsky Jun 19, 2024
4a6f4c5
Merge branch 'dev' into feature/bundle
ludomikula Jun 19, 2024
8b8eeac
Merge pull request #953 from th37rose/feature/bundle
ludomikula Jun 19, 2024
210c63c
fix app view mode not working issue
raheeliftikhar5 Jun 19, 2024
af3a8f4
fix setting hide for comp doesn't hide it
raheeliftikhar5 Jun 20, 2024
a4edf45
add jwt
Jun 20, 2024
29b3d04
add JWT decoder
Jun 20, 2024
496f036
Merge branch 'dev' into fix/jwt
th37rose Jun 20, 2024
8c7ea98
add jwt
Jun 20, 2024
4a4564f
add JWT decoder
Jun 20, 2024
27fa719
Merge branch 'dev' of https://github.com/th37rose/lowcoder_dev1 into …
Jun 21, 2024
492e1a2
check false key and ignore the field
Jun 21, 2024
421c830
Merge remote-tracking branch 'origin/fix/jwt' into fix/jwt
Jun 21, 2024
b6d9047
fix table expanded view keeps loading issue
raheeliftikhar5 Jun 21, 2024
a1f6fc5
Navigation: Added horizontal mode and collapse menu option in vertica…
raheeliftikhar5 Jun 21, 2024
bf32090
Navigation: adjust width based on mode
raheeliftikhar5 Jun 21, 2024
6ecec74
Merge branch 'dev' of https://github.com/th37rose/lowcoder_dev1 into …
Jun 21, 2024
7e628ad
fixed divider styling
Jun 22, 2024
059233b
Updating Gitignore
Jun 23, 2024
85caed6
Updating Gitignore
Jun 23, 2024
7395bfd
Fixing Filter Bug in Home Nav
Jun 23, 2024
f591abe
Update application-debug.yaml
FalkWolsky Jun 23, 2024
6e7e4d6
Revert "Updating Gitignore"
Jun 23, 2024
14ec690
Enable Tests except
Jun 24, 2024
db1a528
Merge pull request #979 from MenamAfzal/fix/divider
raheeliftikhar5 Jun 24, 2024
b3308a3
Merge branch 'dev' into feature/gid
ludomikula Jun 24, 2024
a8e8b9a
Merge pull request #960 from th37rose/feature/gid
ludomikula Jun 24, 2024
48658b6
refactor code : merge two condition
Jun 24, 2024
200fdb6
Merge branch 'dev' into fix/jwt
ludomikula Jun 24, 2024
e57b10f
Merge pull request #975 from th37rose/fix/jwt
ludomikula Jun 24, 2024
eb244e1
event handler added
MenamAfzal Jun 25, 2024
33cf34b
Postman Echo as Data Source
Jun 26, 2024
3ca594c
event handler added
MenamAfzal Jun 26, 2024
65b651f
option hidden
MenamAfzal Jun 26, 2024
c6e4cad
resolve conflict
Jun 27, 2024
936b42d
add switch variable for selecting account on genericoauth
Jun 27, 2024
c13f08b
change default value of userCanSelectAccounts
Jun 27, 2024
d2ab966
fallback for jwt mapping
Jun 27, 2024
e5211e2
Merge pull request #994 from goldants/feature/generic-oauth
ludomikula Jun 28, 2024
2016029
add check for published/marketplace app to anonymous user
Jun 25, 2024
bbfc443
fixed imports
raheeliftikhar5 Jul 1, 2024
6d528d5
event handler for pc navigation
MenamAfzal Jul 2, 2024
b685897
event handler for mobile navigation
MenamAfzal Jul 2, 2024
4e55a59
tabbed container styles updated
MenamAfzal Jul 2, 2024
a31d420
option default black color
MenamAfzal Jul 2, 2024
2b3bcfc
WIP - Changing the Theme Detail View 3
MenamAfzal Jul 2, 2024
d23fc09
event handler section position changed
MenamAfzal Jul 3, 2024
baf96c9
Merge pull request #1002 from MenamAfzal/fix/children-text-color
raheeliftikhar5 Jul 3, 2024
ace9e1e
Merge pull request #1001 from MenamAfzal/fix/remove-duplicate-styles
raheeliftikhar5 Jul 3, 2024
23767c4
Merge branch 'dev' into feature/add-event-handler
raheeliftikhar5 Jul 3, 2024
d9a49a7
Merge pull request #988 from MenamAfzal/feature/add-event-handler
raheeliftikhar5 Jul 3, 2024
1e2d2bf
WIP - Changing the Theme Detail View
May 21, 2024
c29cdbb
WIP - Changing the Theme Detail View 2
May 23, 2024
3a94509
WIP - Changing the Theme Detail View 3
May 23, 2024
b19b824
Theme Settings extended and Components Display set up.
May 25, 2024
e747613
Deleting an Space in tsconfig
May 27, 2024
2ee0cf1
Small Update
May 27, 2024
117a277
Small Update
May 27, 2024
b2d5862
theme: components styling
raheeliftikhar5 Jun 3, 2024
8529fec
theme: fix lc-comps loading in comp styling
raheeliftikhar5 Jun 6, 2024
61e3963
Theme: added debounce for style changes and update theme
raheeliftikhar5 Jun 7, 2024
bbb7f7a
Theme: use theme style in candleChartComp
raheeliftikhar5 Jun 7, 2024
e819e35
Theme: use theme styles for comps
raheeliftikhar5 Jun 7, 2024
8c17c04
Theme: apply theme styles in textComp
raheeliftikhar5 Jun 7, 2024
29bff58
Theme: apply theme styles in triContainerComp
raheeliftikhar5 Jun 7, 2024
2e12374
Theme: moved defaultTheme to separate constant file
raheeliftikhar5 Jun 16, 2024
ee603b0
Theme: applied theme styles in input comp
raheeliftikhar5 Jun 16, 2024
e4b5ddc
Theme: update styleControls to handle comp theme styles
raheeliftikhar5 Jun 16, 2024
04848ba
Theme: apply theme styles on table comp
raheeliftikhar5 Jun 16, 2024
b8d44e5
Theme: apply theme styles in list/grid view
raheeliftikhar5 Jun 16, 2024
5c413c0
Theme: apply theme styles on link comp
raheeliftikhar5 Jun 16, 2024
e659877
Theme: apply theme styles in rating comp
raheeliftikhar5 Jun 16, 2024
5bf8a7b
fixed imported dependencies path
raheeliftikhar5 Jun 16, 2024
106e8ed
Theme: apply theme styles in timeline comp
raheeliftikhar5 Jun 16, 2024
ea58eae
Update for Mobile Navigation Items Display
Jun 15, 2024
7fc9182
remove duplicate dependecies
raheeliftikhar5 Jun 16, 2024
5d20a89
Theme: config updates
raheeliftikhar5 Jun 16, 2024
660fa27
Theme: apply theme on data collection comps
raheeliftikhar5 Jun 17, 2024
736ad03
Theme: apply theme styles on time comp
raheeliftikhar5 Jun 17, 2024
727630a
responsiveLayout component
Jun 17, 2024
9cc5c45
card component
Jun 17, 2024
9ee311e
column layout component
Jun 17, 2024
a5ec696
tabbed container component
Jun 17, 2024
22ae427
step control
Jun 17, 2024
11abdfa
cascader
Jun 17, 2024
1587f0b
float component
Jun 17, 2024
3ed4344
treeSelect Component
Jun 17, 2024
98e48ec
pageLayout component
Jun 17, 2024
df63d5f
themeConstants
Jun 17, 2024
400c25f
Fixes in Style Properties Display in Theme Settings
Jun 17, 2024
33ec791
Integration & Extension component
Jun 17, 2024
7c01f10
Multimedia & Animation
Jun 17, 2024
9cb0240
Item & Signature
Jun 17, 2024
ad6d03a
Theme: allow overwrite theme styles
raheeliftikhar5 Jun 17, 2024
391bb05
Fixes in Style Properties Display in Theme Settings 2
Jun 17, 2024
d05691a
Doc & File
Jun 22, 2024
0d883a6
Meeting & Colaboration
Jun 22, 2024
b4cd202
Theme: created a hook to merge styles initially
raheeliftikhar5 Jun 26, 2024
3cc6189
Theme: replacing code with custom hook
raheeliftikhar5 Jun 26, 2024
de35ab7
Theme: added preventStyleOverwriting switches in app and component se…
raheeliftikhar5 Jun 26, 2024
d58be23
Theme: remove overwriteStyles switch
raheeliftikhar5 Jun 26, 2024
be6c861
Theme: added comp theme styling in candleStickChart
raheeliftikhar5 Jun 26, 2024
13fbb07
custom hook used
MenamAfzal Jun 28, 2024
05f89e1
theme for chart components
MenamAfzal Jul 1, 2024
b466297
Theme: fixed chart themes
raheeliftikhar5 Jul 2, 2024
65f6ec6
Theme: removed unused dependencies + apply themes in charts
raheeliftikhar5 Jul 2, 2024
086334c
fixed imports
raheeliftikhar5 Jul 3, 2024
f107746
small fix
raheeliftikhar5 Jul 3, 2024
411dd7a
Merge pull request #907 from lowcoder-org/feature-themes-for-components
FalkWolsky Jul 3, 2024
6191255
Fix unauthenticated redirection
goldants Jul 3, 2024
4d3f6ce
Revert "Fix kanban draggable bug"
FalkWolsky Jun 19, 2024
00385c0
feat: support external redis auth
linonetwo Jun 29, 2024
41c385d
feat: allow using external mongodb
linonetwo Jun 29, 2024
f9bcac6
Update React JSON Schema Forms to 5.18.6
Jul 3, 2024
9ab8b51
add gid to Datasource
Jun 25, 2024
dc97ba5
add gid to LibraryQuery
Jun 26, 2024
62c3d3c
add gid to ApplicationQuery
Jun 26, 2024
f74b4ce
remove unused imports
Jun 26, 2024
7e9e062
add gid to test data
Jun 26, 2024
e437522
add gid to Datasource and initialize with uuid
Jun 26, 2024
c7db3e0
init uuid for libraryQuery
Jun 26, 2024
e6cb951
fix compile issue
Jun 26, 2024
2d8ced2
add gid test
Jun 27, 2024
f8ac771
gid test
goldants Jun 27, 2024
8bbc9db
folder gid test issue fix
goldants Jun 28, 2024
ea49245
folder gid test
goldants Jun 28, 2024
40c8046
add db migration
goldants Jun 28, 2024
7948960
fix: fix hanging mongo connections
ludomikula Jul 3, 2024
452d3cb
fix font size not working on text comp
raheeliftikhar5 Jul 3, 2024
5d20a9b
fix styles not working on textComp
raheeliftikhar5 Jul 3, 2024
9a72dd5
apply branding styles by default
raheeliftikhar5 Jul 4, 2024
4cccfe8
apply theme styles on container comps
raheeliftikhar5 Jul 4, 2024
69b117f
error boundary part 1
MenamAfzal Jul 4, 2024
d56e6d1
added option to add global css
raheeliftikhar5 Jul 5, 2024
6981d58
fixing nodeServiceApiProxyTarget in vite config
Jul 5, 2024
2d525d2
Enabling Posthog on localhost and app.lowcoder.cloud
Jul 5, 2024
81d072c
latest changes
MenamAfzal Jul 5, 2024
53c267b
fallback ui for error boundary
MenamAfzal Jul 5, 2024
c5ffe4b
fix table column styling for status and markdown types
raheeliftikhar5 Jul 5, 2024
87a1c18
yarn.lock changes
MenamAfzal Jul 5, 2024
efed6da
Fixing iconselector z-index and homescreen icon position
Jul 5, 2024
7071777
Fixing Tag Display in Table
Jul 5, 2024
dcf4fa0
Fixing word wrap in Table
Jul 5, 2024
400b932
Fixing word wrap in Table
Jul 5, 2024
7969dc3
removed unused code
MenamAfzal Jul 6, 2024
45cf141
removed unused code
MenamAfzal Jul 6, 2024
3997d33
Merge branch 'dev' into feature/error-boundary
raheeliftikhar5 Jul 6, 2024
0b69057
Merge pull request #1011 from MenamAfzal/feature/error-boundary
raheeliftikhar5 Jul 6, 2024
15d1ed0
Adapting Theme Comp Panel for better usability
Jul 6, 2024
a37cb9a
fixed app crash on missing styles
raheeliftikhar5 Jul 6, 2024
d0eceb5
Removing console log
Jul 6, 2024
247106e
Small layout fixes at Theme Comp Display
Jul 6, 2024
ad27f9b
Enterprise Edition notice
Jul 6, 2024
4f07bbd
Small fix about InviteButton - And WIP app Redirect
Jul 6, 2024
56396f4
Adding Posthog to localhost and public cloud
Jul 6, 2024
b85f013
handle routes based on orgDev
raheeliftikhar5 Jul 7, 2024
ed44c5c
Fixes in styles and Translations
Jul 7, 2024
bbf21e9
Fixes in translations for OAuth Provider
Jul 7, 2024
b510ebb
FIX GITHUB OAUTH ISSUE
goldants Jul 5, 2024
bf7b1fb
null name issue fixed
goldants Jul 6, 2024
537848a
Adding super_admin to ADMIN_ROLE
Jul 7, 2024
ef772cb
Adding super_admin to ADMIN_ROLE
Jul 7, 2024
70b307b
Extending Postman Echo Data Source
Jul 7, 2024
5c94e81
Fixing App Redirection
Jul 7, 2024
33b0530
Increase Query Timeout Defaults in Frontend
Jul 7, 2024
2acb8a0
fix routing for public apps
raheeliftikhar5 Jul 7, 2024
419cf5a
small fix
raheeliftikhar5 Jul 7, 2024
a0fdcc9
fix: increase connection leak detection threshold
ludomikula Jul 7, 2024
df2042b
Increase Version Number for the Release
Jul 7, 2024
7c772b8
add switch variable : postForUserEndpoint
goldants Jul 7, 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
8 changes: 4 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ client/packages/lowcoder-plugin-demo/.yarn/install-state.gz
client/packages/lowcoder-plugin-demo/yarn.lock
client/packages/lowcoder-plugin-demo/.yarn/cache/@types-node-npm-16.18.68-56f72825c0-094ae9ed80.zip
application-dev.yml
server/api-service/lowcoder-server/src/main/resources/application-lowcoder.yml
server/api-service/lowcoder-server/src/main/resources/application-debug.yaml
application-lowcoder.yml
application-debug.yaml
application-dev-localhost.yaml
.vscode/settings.json
.vscode/launch.json
server/api-service/lowcoder-server/src/main/resources/application-dev-localhost.yaml
.vscode/launch.json
2 changes: 1 addition & 1 deletion client/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.4.1
2.4.2
1 change: 1 addition & 0 deletions client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@
"chalk": "4",
"flag-icons": "^7.2.1",
"number-precision": "^1.6.0",
"posthog-js": "^1.144.2",
"react-countup": "^6.5.3",
"react-player": "^2.11.0",
"resize-observer-polyfill": "^1.5.1",
Expand Down
48 changes: 24 additions & 24 deletions client/packages/lowcoder-comps/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,30 +34,6 @@
"lowcoder": {
"description": "",
"comps": {
"meetingController": {
"name": "Agora Meeting Controller",
"icon": "./icons/icon-comp-calendar.svg",
"layoutInfo": {
"w": 1,
"h": 1
}
},
"meetingSharing": {
"name": "Agora Meeting Sharing",
"icon": "./icons/icon-comp-calendar.svg",
"layoutInfo": {
"w": 6,
"h": 40
}
},
"meetingStream": {
"name": "Video Stream",
"icon": "./icons/icon-comp-calendar.svg",
"layoutInfo": {
"w": 6,
"h": 40
}
},
"calendar": {
"name": "Calendar",
"icon": "./icons/icon-comp-calendar.svg",
Expand Down Expand Up @@ -193,6 +169,30 @@
"w": 19,
"h": 60
}
},
"meetingController": {
"name": "Agora Meeting Controller",
"icon": "./icons/icon-comp-calendar.svg",
"layoutInfo": {
"w": 1,
"h": 1
}
},
"meetingSharing": {
"name": "Agora Meeting Sharing",
"icon": "./icons/icon-comp-calendar.svg",
"layoutInfo": {
"w": 6,
"h": 40
}
},
"meetingStream": {
"name": "Video Stream",
"icon": "./icons/icon-comp-calendar.svg",
"layoutInfo": {
"w": 6,
"h": 40
}
}
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ import {
ThemeContext,
chartColorPalette,
getPromiseAfterDispatch,
dropdownControl
dropdownControl,
useMergeCompStyles,
} from "lowcoder-sdk";
import { getEchartsLocale, trans } from "i18n/comps";
import { ItemColorComp } from "comps/chartComp/chartConfigs/lineChartConfig";
Expand Down Expand Up @@ -73,6 +74,8 @@ BasicChartTmpComp = withViewFn(BasicChartTmpComp, (comp) => {
log.error('theme chart error: ', error);
}

useMergeCompStyles(childrenToProps(comp.children), comp.dispatch);

const triggerClickEvent = async (dispatch: any, action: CompAction<JSONValue>) => {
await getPromiseAfterDispatch(
dispatch,
Expand Down Expand Up @@ -123,7 +126,8 @@ BasicChartTmpComp = withViewFn(BasicChartTmpComp, (comp) => {
const option = useMemo(() => {
return getEchartsConfig(
childrenToProps(echartsConfigChildren) as ToViewReturn<typeof echartsConfigChildren>,
chartSize
chartSize,
theme?.theme?.components?.candleStickChart || {},
);
}, [chartSize, ...Object.values(echartsConfigChildren)]);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -251,11 +251,11 @@ export const chartUiModeChildren = {

const chartJsonModeChildren = {
echartsOption: jsonControl(toObject, i18nObjs.defaultEchartsJsonOption),
echartsTitle: withDefault(StringControl, trans("echarts.defaultTitle")),
echartsTitle: withDefault(StringControl, trans("echarts.defaultTitle")),
echartsLegendConfig: EchartsLegendConfig,
echartsLabelConfig: EchartsLabelConfig,
echartsConfig: EchartsOptionComp,
style: styleControl(EchartsStyle),
style: styleControl(EchartsStyle, 'style'),
tooltip: withDefault(BoolControl, true),
legendVisibility: withDefault(BoolControl, true),
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,17 +128,21 @@ export function getSeriesConfig(props: EchartsConfigProps) {
}

// https://echarts.apache.org/en/option.html
export function getEchartsConfig(props: EchartsConfigProps, chartSize?: ChartSize): EChartsOptionWithMap {
export function getEchartsConfig(
props: EchartsConfigProps,
chartSize?: ChartSize,
theme?: any,
): EChartsOptionWithMap {
if (props.mode === "json") {
let opt={
"title": {
"text": props.echartsTitle,
'top': props.echartsLegendConfig.top === 'bottom' ?'top':'bottom',
"left":"center"
},
"backgroundColor": props?.style?.background,
"color": props.echartsOption.data?.map(data => data.color),
"tooltip": props.tooltip&&{
"backgroundColor": props?.style?.background || theme?.style?.background,
"color": props.echartsOption.data?.map(data => data.color),
"tooltip": props.tooltip && {
"trigger": "item",
"formatter": "{a} <br/>{b} : {c}%"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ import {
CustomModal,
jsonValueExposingStateControl,
CalendarDeleteIcon,
Tooltip
Tooltip,
useMergeCompStyles,
} from "lowcoder-sdk";

import {
Expand Down Expand Up @@ -87,7 +88,7 @@ const childrenMap = {
firstDay: dropdownControl(FirstDayOptions, "1"),
dayMaxEvents: withDefault(NumberControl, 2),
eventMaxStack: withDefault(NumberControl, 0),
style: styleControl(CalendarStyle),
style: styleControl(CalendarStyle, 'style'),
licenseKey: withDefault( StringControl, "" ),
currentFreeView: dropdownControl(DefaultWithFreeViewOptions, "timeGridWeek"),
currentPremiumView: dropdownControl(DefaultWithPremiumViewOptions, "resourceTimelineDay"),
Expand All @@ -114,7 +115,7 @@ let CalendarBasicComp = (function () {
licensed?: boolean;
currentFreeView?: string;
currentPremiumView?: string;
}) => {
}, dispatch: any) => {

const theme = useContext(ThemeContext);
const ref = createRef<HTMLDivElement>();
Expand All @@ -123,15 +124,15 @@ let CalendarBasicComp = (function () {
const [left, setLeft] = useState<number | undefined>(undefined);
const [licensed, setLicensed] = useState<boolean>(props.licenseKey !== "");

useMergeCompStyles(props, dispatch);

useEffect(() => {
setLicensed(props.licenseKey !== "");
}, [props.licenseKey]);

let currentView = licensed ? props.currentPremiumView : props.currentFreeView;
let currentEvents = currentView == "resourceTimelineDay" || currentView == "resourceTimeGridDay" ? props.resourcesEvents : props.events;

console.log("currentEvents", currentEvents);

// we use one central stack of events for all views
let events = Array.isArray(currentEvents.value) ? currentEvents.value.map((item: EventType) => {
return {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ import {
ThemeContext,
chartColorPalette,
getPromiseAfterDispatch,
dropdownControl
dropdownControl,
useMergeCompStyles,
} from "lowcoder-sdk";
import { getEchartsLocale, trans } from "i18n/comps";
import { ItemColorComp } from "comps/chartComp/chartConfigs/lineChartConfig";
Expand Down Expand Up @@ -63,14 +64,15 @@ CandleStickChartTmpComp = withViewFn(CandleStickChartTmpComp, (comp) => {
color: chartColorPalette,
backgroundColor: "#fff",
};

let themeConfig = defaultChartTheme;
try {
themeConfig = theme?.theme.chart ? JSON.parse(theme?.theme.chart) : defaultChartTheme;
} catch (error) {
log.error('theme chart error: ', error);
}

useMergeCompStyles(childrenToProps(comp.children), comp.dispatch);

const triggerClickEvent = async (dispatch: any, action: CompAction<JSONValue>) => {
await getPromiseAfterDispatch(
dispatch,
Expand Down Expand Up @@ -144,7 +146,8 @@ CandleStickChartTmpComp = withViewFn(CandleStickChartTmpComp, (comp) => {
const option = useMemo(() => {
return getEchartsConfig(
childrenToProps(echartsConfigChildren) as ToViewReturn<typeof echartsConfigChildren>,
chartSize
chartSize,
theme?.theme?.components?.candleStickChart || {},
);
}, [chartSize, ...Object.values(echartsConfigChildren)]);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ const chartJsonModeChildren = {
echartsLegendConfig: EchartsLegendConfig,
echartsLabelConfig: EchartsLabelConfig,
echartsConfig: EchartsOptionComp,
style: styleControl(EchartsStyle),
style: styleControl(EchartsStyle, 'style'),
tooltip: withDefault(BoolControl, true),
legendVisibility: withDefault(BoolControl, true),
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { chartColorPalette, isNumeric, JSONObject, loadScript } from "lowcoder-s
import { calcXYConfig } from "comps/chartComp/chartConfigs/cartesianAxisConfig";
import Big from "big.js";
import { googleMapsApiUrl } from "../chartComp/chartConfigs/chartUrls";
import { useContext } from "react";

export function transformData(
originData: JSONObject[],
Expand Down Expand Up @@ -128,15 +129,19 @@ export function getSeriesConfig(props: EchartsConfigProps) {
}

// https://echarts.apache.org/en/option.html
export function getEchartsConfig(props: EchartsConfigProps, chartSize?: ChartSize): EChartsOptionWithMap {
export function getEchartsConfig(
props: EchartsConfigProps,
chartSize?: ChartSize,
theme?: any,
): EChartsOptionWithMap {
if (props.mode === "json") {
let opt={
"title": {
"text": props.echartsTitle,
'top': props.echartsLegendConfig.top === 'bottom' ?'top':'bottom',
"left":"center"
},
"backgroundColor": props?.style?.background,
"backgroundColor": props?.style?.background || theme?.style?.background,
"color": props.echartsOption.data?.map(data => data.color),
"tooltip": props.tooltip&&{
"trigger": "axis",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,11 @@ export function getSeriesConfig(props: EchartsConfigProps) {
}

// https://echarts.apache.org/en/option.html
export function getEchartsConfig(props: EchartsConfigProps, chartSize?: ChartSize): EChartsOptionWithMap {
export function getEchartsConfig(
props: EchartsConfigProps,
chartSize?: ChartSize,
theme?: any,
): EChartsOptionWithMap {
if (props.mode === "json") {
return props.echartsOption ? props.echartsOption : {};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ import {
ThemeContext,
chartColorPalette,
getPromiseAfterDispatch,
dropdownControl
dropdownControl,
useMergeCompStyles,
} from "lowcoder-sdk";
import { getEchartsLocale, trans } from "i18n/comps";
import { ItemColorComp } from "comps/basicChartComp/chartConfigs/lineChartConfig";
Expand Down Expand Up @@ -82,6 +83,8 @@ MapTmpComp = withViewFn(MapTmpComp, (comp) => {
log.error('theme chart error: ', error);
}

useMergeCompStyles(childrenToProps(comp.children), comp.dispatch);

const triggerClickEvent = async (dispatch: any, action: CompAction<JSONValue>) => {
await getPromiseAfterDispatch(
dispatch,
Expand Down Expand Up @@ -119,7 +122,8 @@ MapTmpComp = withViewFn(MapTmpComp, (comp) => {
const option = useMemo(() => {
return getEchartsConfig(
childrenToProps(echartsConfigChildren) as ToViewReturn<typeof echartsConfigChildren>,
chartSize
chartSize,
theme?.theme?.components?.candleStickChart || {},
);
}, [chartSize, ...Object.values(echartsConfigChildren)]);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ import {
ThemeContext,
chartColorPalette,
getPromiseAfterDispatch,
dropdownControl
dropdownControl,
useMergeCompStyles,
} from "lowcoder-sdk";
import { getEchartsLocale, trans } from "i18n/comps";
import { ItemColorComp } from "comps/chartComp/chartConfigs/lineChartConfig";
Expand Down Expand Up @@ -71,6 +72,8 @@ FunnelChartTmpComp = withViewFn(FunnelChartTmpComp, (comp) => {
log.error('theme chart error: ', error);
}

useMergeCompStyles(childrenToProps(comp.children), comp.dispatch);

const triggerClickEvent = async (dispatch: any, action: CompAction<JSONValue>) => {
await getPromiseAfterDispatch(
dispatch,
Expand Down Expand Up @@ -144,7 +147,8 @@ FunnelChartTmpComp = withViewFn(FunnelChartTmpComp, (comp) => {
const option = useMemo(() => {
return getEchartsConfig(
childrenToProps(echartsConfigChildren) as ToViewReturn<typeof echartsConfigChildren>,
chartSize
chartSize,
theme?.theme?.components?.candleStickChart || {},
);
}, [chartSize, ...Object.values(echartsConfigChildren)]);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ const chartJsonModeChildren = {
echartsLabelConfig: EchartsLabelConfig,
echartsConfig: EchartsOptionComp,
echartsTitleConfig:EchartsTitleConfig,
style: styleControl(EchartsStyle),
style: styleControl(EchartsStyle, 'style'),
tooltip: withDefault(BoolControl, true),
label: withDefault(BoolControl, true),
legendVisibility: withDefault(BoolControl, true),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,15 +128,19 @@ export function getSeriesConfig(props: EchartsConfigProps) {
}

// https://echarts.apache.org/en/option.html
export function getEchartsConfig(props: EchartsConfigProps, chartSize?: ChartSize): EChartsOptionWithMap {
export function getEchartsConfig(
props: EchartsConfigProps,
chartSize?: ChartSize,
theme?: any,
): EChartsOptionWithMap {
if (props.mode === "json") {
let opt={
"title": {
"text": props.echartsTitle,
'top': props.echartsLegendConfig.top === 'bottom' ?'top':'bottom',
"left":props.echartsTitleConfig.top
},
"backgroundColor": props?.style?.background,
"backgroundColor": props?.style?.background || theme?.style?.background,
"color": props.echartsOption.data?.map(data => data.color),
"tooltip": props.tooltip&&{
"trigger": "item",
Expand Down
Loading
Loading