Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitcd948af

Browse files
fixed table not loading inside kanban card
1 parentbf383d2 commitcd948af

File tree

2 files changed

+14
-7
lines changed

2 files changed

+14
-7
lines changed

‎client/packages/lowcoder/src/comps/controls/slotControl.tsx‎

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ import { createContext, useContext } from "react";
1616
importstyledfrom"styled-components";
1717
import{NameGenerator}from"comps/utils";
1818
import{JSONValue}from"util/jsonTypes";
19+
importReactfrom"react";
20+
import{isEqual}from"lodash";
1921

2022
constModalStyled=styled.div<{$background?:string}>`
2123
.ant-modal-content {
@@ -42,23 +44,23 @@ export const SlotConfigContext = createContext<{
4244
modalWidth:520,
4345
});
4446

45-
constContainerView=(props:ContainerBaseProps)=>{
47+
constContainerView=React.memo((props:ContainerBaseProps)=>{
4648
return<InnerGrid{...props}emptyRows={15}autoHeight/>;
47-
};
49+
});
4850

49-
functionModalConfigView(props:{
51+
constModalConfigView=React.memo((props:{
5052
visible:boolean;
5153
containerProps:ConstructorToView<typeofSimpleContainerComp>;
5254
onCancel:()=>void;
53-
}){
55+
})=>{
5456
const{ visible, containerProps, onCancel}=props;
5557
constbackground=useContext(BackgroundColorContext);
5658
const{ modalWidth=520}=useContext(SlotConfigContext);
5759
if(!visible){
5860
returnnull;
5961
}
6062
return(
61-
(<ModalWrapper>
63+
<ModalWrapper>
6264
<Modal
6365
width={modalWidth}
6466
open={visible}
@@ -67,6 +69,7 @@ function ModalConfigView(props: {
6769
footer={null}
6870
styles={{body:{padding:"0"}}}
6971
zIndex={Layers.modal}
72+
maskClosable={false}
7073
modalRender={(node)=>(
7174
<ModalStyled$background={background}onClick={()=>{}}>
7275
{node}
@@ -81,9 +84,9 @@ function ModalConfigView(props: {
8184
items={gridItemCompToGridItems(containerProps.items)}
8285
/>
8386
</Modal>
84-
</ModalWrapper>)
87+
</ModalWrapper>
8588
);
86-
}
89+
},(prevProps,nextProps)=>isEqual(prevProps,nextProps));
8790

8891
constchildrenMap={
8992
container:SimpleContainerComp,

‎client/packages/lowcoder/src/comps/generators/withSelectedMultiContext.tsx‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,10 @@ export function withSelectedMultiContext<TCtor extends MultiCompConstructor>(
8787
||isCustomAction<LazyCompReadyAction>(action,"LazyCompReady")
8888
||isCustomAction<ModuleReadyAction>(action,"moduleReady")
8989
)&&action.path[1]===SELECTED_KEY){
90+
if(action.path[0]===MAP_KEY&&action.path[1]===SELECTED_KEY){
91+
action.path[1]=this.selection;
92+
comp=super.reduce(action);
93+
}
9094
// broadcast
9195
constnewAction={
9296
...action,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp