Skip to content

Commit b97caf0

Browse files
committed
formating removed-34
1 parent 26fcd2e commit b97caf0

File tree

1 file changed

+27
-30
lines changed

1 file changed

+27
-30
lines changed

client/packages/lowcoder/src/comps/comps/containerComp/pageLayoutComp.tsx

Lines changed: 27 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,17 @@ import { NameGenerator } from "comps/utils/nameGenerator";
66
import { Section, sectionNames } from "lowcoder-design";
77
import { oldContainerParamsToNew } from "../containerBase";
88
import { toSimpleContainerData } from "../containerBase/simpleContainerComp";
9-
import { disabledPropertyView, hiddenPropertyView, } from "comps/utils/propertyUtils";
9+
import { disabledPropertyView, hiddenPropertyView } from "comps/utils/propertyUtils";
1010
import { trans } from "i18n";
1111
import { BoolCodeControl } from "comps/controls/codeControl";
1212
import { DisabledContext } from "comps/generators/uiCompBuilder";
1313
import React, { useContext, useEffect, useState } from "react";
1414
import { EditorContext } from "comps/editorState";
1515

16-
import { ContainerChildren, ContainerCompBuilder } from "../pageLayoutComp/pageLayoutCompBuilder";
16+
import {
17+
ContainerChildren,
18+
ContainerCompBuilder,
19+
} from "../pageLayoutComp/pageLayoutCompBuilder";
1720
import { PageLayout } from "../pageLayoutComp/pageLayout";
1821
import { AnimationStyle, styleControl } from "@lowcoder-ee/index.sdk";
1922

@@ -24,58 +27,52 @@ export const ContainerBaseComp = (function () {
2427
};
2528

2629
return new ContainerCompBuilder(childrenMap, (props, dispatch) => {
30+
2731
const [siderCollapsed, setSiderCollapsed] = useState(false);
2832

2933
return (
3034
<DisabledContext.Provider value={props.disabled}>
31-
<PageLayout
32-
{...props}
33-
siderCollapsed={siderCollapsed}
34-
setSiderCollapsed={setSiderCollapsed}
35-
/>
35+
<PageLayout {...props} siderCollapsed={siderCollapsed} setSiderCollapsed={setSiderCollapsed} />
3636
</DisabledContext.Provider>
3737
);
3838
})
3939
.setPropertyViewFn((children) => {
4040
return (
4141
<>
42-
{(useContext(EditorContext).editorModeStatus === "logic" ||
43-
useContext(EditorContext).editorModeStatus === "both") && (
42+
{(useContext(EditorContext).editorModeStatus === "logic" || useContext(EditorContext).editorModeStatus === "both") && (
4443
<Section name={sectionNames.interaction}>
4544
{disabledPropertyView(children)}
4645
{hiddenPropertyView(children)}
47-
{children.container.appSelectorPropertyView()}
46+
{ children.container.appSelectorPropertyView()}
4847
</Section>
4948
)}
5049

51-
{(useContext(EditorContext).editorModeStatus === "layout" ||
52-
useContext(EditorContext).editorModeStatus === "both") && (
53-
<>
54-
<Section name={sectionNames.layout}>
55-
{children.container.getPropertyView()}
56-
</Section>
57-
<Section name={sectionNames.style}>
58-
{children.container.stylePropertyView()}
50+
{(useContext(EditorContext).editorModeStatus === "layout" || useContext(EditorContext).editorModeStatus === "both") && (
51+
<><Section name={sectionNames.layout}>
52+
{children.container.getPropertyView()}
53+
</Section>
54+
<Section name={sectionNames.style}>
55+
{ children.container.stylePropertyView() }
5956
</Section>
6057
<Section name={sectionNames.animationStyle}>
6158
{children.animationStyle.getPropertyView()}
6259
</Section>
63-
{children.container.children.showHeader.getView() && (
64-
<Section name={"Header Style"}>
65-
{children.container.headerStylePropertyView()}
60+
{children.container.children.showHeader.getView() && (
61+
<Section name={"Header Style"}>
62+
{ children.container.headerStylePropertyView() }
6663
</Section>
6764
)}
68-
{children.container.children.showSider.getView() && (
69-
<Section name={"Sider Style"}>
70-
{children.container.siderStylePropertyView()}
65+
{children.container.children.showSider.getView() && (
66+
<Section name={"Sider Style"}>
67+
{ children.container.siderStylePropertyView() }
7168
</Section>
7269
)}
73-
<Section name={"Body Style"}>
74-
{children.container.bodyStylePropertyView()}
75-
</Section>
76-
{children.container.children.showFooter.getView() && (
77-
<Section name={"Footer Style"}>
78-
{children.container.footerStylePropertyView()}
70+
<Section name={"Body Style"}>
71+
{ children.container.bodyStylePropertyView() }
72+
</Section>
73+
{children.container.children.showFooter.getView() && (
74+
<Section name={"Footer Style"}>
75+
{ children.container.footerStylePropertyView() }
7976
</Section>
8077
)}
8178
</>

0 commit comments

Comments
 (0)