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

Module loading issues#781

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes fromall commits
Commits
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
17 changes: 13 additions & 4 deletionsclient/packages/lowcoder-design/src/components/ScrollBar.tsx
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -5,7 +5,7 @@ import styled from "styled-components";
import { DebouncedFunc } from 'lodash'; // Assuming you're using lodash's DebouncedFunc type


const ScrollBarWrapper = styled.div<{hidePlaceholder?: boolean }>`
const ScrollBarWrapper = styled.div<{$hideplaceholder?: boolean }>`
min-height: 0;
height: 100%;
width: 100%;
Expand DownExpand Up@@ -37,7 +37,7 @@ const ScrollBarWrapper = styled.div<{ hidePlaceholder?: boolean }>`
bottom: 10px;
}

${props => props.hidePlaceholder && `
${props =>Boolean(props.$hideplaceholder) && `
.simplebar-placeholder {
display: none !important;
}
Expand All@@ -54,11 +54,20 @@ interface IProps {
scrollableNodeProps?: {
onScroll: DebouncedFunc<(e: any) => void>;
};
hidePlaceholder?: boolean;
$hideplaceholder?: boolean;
hideScrollbar?: boolean;
}

export const ScrollBar = ({ height = "100%", className, children, style, scrollableNodeProps, hideScrollbar = false, ...otherProps }: IProps) => {
export const ScrollBar = ({
height = "100%",
className,
children,
style,
scrollableNodeProps,
hideScrollbar = false,
$hideplaceholder = false,
...otherProps
}: IProps) => {
// You can now use the style prop directly or pass it to SimpleBar
const combinedStyle = { ...style, height }; // Example of combining height with passed style

Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -106,7 +106,7 @@ export const BaseSection = (props: ISectionConfig<ReactNode>) => {
const { compName, state, toggle } = useContext(PropertySectionContext);
const open = props.open !== undefined ? props.open : name ? state[compName]?.[name] !== false : true;

console.log("open", open, props.open);
//console.log("open", open, props.open);

const handleToggle = () => {
if (!name) {
Expand Down
33 changes: 19 additions & 14 deletionsclient/packages/lowcoder/src/appView/AppView.tsx
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
import { default as App } from "antd/es/app";
import GlobalInstances from "components/GlobalInstances";
import { RootComp } from "comps/comps/rootComp";
import { GetContainerParams, useCompInstance } from "comps/utils/useCompInstance";
import { createBrowserHistory } from "history";
Expand DownExpand Up@@ -88,19 +90,22 @@ export function AppView(props: AppViewProps) {
}, [moduleInputs]);

return (
<Provider store={reduxStore}>
<ExternalEditorContext.Provider
value={{
applicationId: appId,
appType: 1,
readOnly: true,
hideHeader: true,
}}
>
<Router history={browserHistory}>
<Route path="/" render={() => comp?.getView()} />
</Router>
</ExternalEditorContext.Provider>
</Provider>
<App>
<GlobalInstances />
<Provider store={reduxStore}>
<ExternalEditorContext.Provider
value={{
applicationId: appId,
appType: 1,
readOnly: true,
hideHeader: true,
}}
>
<Router history={browserHistory}>
<Route path="/" render={() => comp?.getView()} />
</Router>
</ExternalEditorContext.Provider>
</Provider>
</App>
);
}
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -116,7 +116,7 @@ export class ModuleLayoutComp extends ModuleLayoutCompBase implements IContainer
const rowCount = this.children.containerRowCount.getView();
return (
<div>
<ScrollBar style={{ height: "100%", margin: "0px", padding: "0px" }}hidePlaceholder={false}>
<ScrollBar style={{ height: "100%", margin: "0px", padding: "0px" }}$hideplaceholder={false}>
<ModuleLayoutView
positionParams={this.children.positionParams.getView()}
containerSize={this.children.containerSize.getView()}
Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -282,7 +282,7 @@ function QueryView(props: QueryViewProps) {
) {
setTimeout(() => {
comp.dispatch(deferAction(executeQueryAction({})));
});
}, 100);
}
}, []);

Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,7 +23,7 @@ const SuccessMessageAction = new MultiCompBuilder(
{
text: StringControl,
},
(props) => (duration: number) => props.text && messageInstance.success(props.text, duration)
(props) => (duration: number) => props.text && messageInstance?.success(props.text, duration)
)
.setPropertyViewFn((children) => (
<>
Expand DownExpand Up@@ -109,14 +109,14 @@ const QueryNotificationTmpControl = new MultiCompBuilder(
props.fail.forEach((item) => {
const props = (item.getView() as any)({ data: result.data });
if (props.condition && props.text) {
messageInstance.error(props.text, duration);
messageInstance?.error(props.text, duration);
hasNoticed = true;
}
});

// Execute system notification if triggered manually without custom notification and query fails
if (!result.success && !hasNoticed) {
hasNoticed = !!messageInstance.error(
hasNoticed = !!messageInstance?.error(
trans("query.failMessageWithName", {
name,
result: JSON.stringify(pick(result, ["code", "message"])),
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp