Skip to content

Commit 496f036

Browse files
author
th37rose
authored
Merge branch 'dev' into fix/jwt
2 parents 29b3d04 + af3a8f4 commit 496f036

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

client/packages/lowcoder/src/layout/compSelectionWrapper.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ function getLineStyle(
8989

9090
return `
9191
border: ${GRID_ITEM_BORDER_WIDTH}px ${borderStyle} ${borderColor};
92-
padding: ${isHidden && !isSelected ? 0 : padding[1] - GRID_ITEM_BORDER_WIDTH}px;
92+
padding: ${isHidden || !isSelected ? 0 : padding[1] - GRID_ITEM_BORDER_WIDTH}px;
9393
padding-left: ${padding[0] - GRID_ITEM_BORDER_WIDTH}px;
9494
padding-right: ${padding[0] - GRID_ITEM_BORDER_WIDTH}px;
9595
`;

client/packages/lowcoder/src/layout/gridItem.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -447,6 +447,7 @@ export function GridItem(props: GridItemProps) {
447447
pos,
448448
props.name,
449449
props.autoHeight,
450+
props.hidden,
450451
Boolean(draggingUtils.isDragging())
451452
),
452453
opacity: layoutHide ? 0 : undefined,

client/packages/lowcoder/src/layout/utils.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,7 @@ export function setTransform(
203203
{top, left, width, height }: Position,
204204
name ?: string,
205205
autoHeight?: boolean,
206+
hidden?: boolean,
206207
isDragging?: boolean,
207208
): Record<string, any> {
208209
// Replace unitless items with px
@@ -211,7 +212,7 @@ export function setTransform(
211212
return /chart/i.test(str);
212213
}
213214
let updatedHeight = 'auto';
214-
if (isDragging || !autoHeight || (name && containsChart(name))) {
215+
if (isDragging || !autoHeight || hidden || (name && containsChart(name))) {
215216
updatedHeight = `${height}px`;
216217
}
217218

client/packages/lowcoder/src/pages/editor/AppEditor.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,17 +95,16 @@ export default function AppEditor() {
9595
dispatch(fetchQueryLibraryDropdown());
9696
}
9797
}, [dispatch, applicationId, paramViewMode]);
98-
99-
useEffect(() => {
100-
if (!currentUser?.id) return;
98+
99+
const fetchJSDataSourceByApp = () => {
101100
DatasourceApi.fetchJsDatasourceByApp(applicationId).then((res) => {
102101
res.data.data.forEach((i) => {
103102
registryDataSourcePlugin(i.type, i.id, i.pluginDefinition);
104103
});
105104
setIsDataSourcePluginRegistered(true);
106105
});
107106
dispatch(setShowAppSnapshot(false));
108-
}, [applicationId, dispatch, currentUser]);
107+
};
109108

110109
useEffect(() => {
111110
if (!fetchOrgGroupsFinished) {
@@ -129,6 +128,7 @@ export default function AppEditor() {
129128
},
130129
});
131130
setAppInfo(info);
131+
fetchJSDataSourceByApp();
132132
},
133133
})
134134
);

0 commit comments

Comments
 (0)