Skip to content

Commit 6173081

Browse files
authored
Merge pull request lowcoder-org#1094 from lowcoder-org/dev
Dev -> Main v2.4.5
2 parents 90e4e81 + c000da1 commit 6173081

File tree

348 files changed

+195934
-41871
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

348 files changed

+195934
-41871
lines changed

client/VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.4.4
1+
2.4.5

client/packages/lowcoder-comps/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "lowcoder-comps",
3-
"version": "2.4.9",
3+
"version": "2.4.11",
44
"type": "module",
55
"license": "MIT",
66
"dependencies": {

client/packages/lowcoder-comps/src/comps/calendarComp/calendarComp.tsx

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ import {
3232
hiddenPropertyView,
3333
ChangeEventHandlerControl,
3434
DragEventHandlerControl,
35+
CalendarEventHandlerControl,
3536
Section,
3637
sectionNames,
3738
dropdownControl,
@@ -45,7 +46,9 @@ import {
4546
CalendarDeleteIcon,
4647
Tooltip,
4748
useMergeCompStyles,
48-
} from "lowcoder-sdk";
49+
EditorContext,
50+
CompNameContext,
51+
} from 'lowcoder-sdk';
4952

5053
import {
5154
DefaultWithFreeViewOptions,
@@ -76,7 +79,7 @@ let childrenMap: any = {
7679
resourcesEvents: jsonValueExposingStateControl("resourcesEvents", resourcesEventsDefaultData),
7780
resources: jsonValueExposingStateControl("resources", resourcesDefaultData),
7881
resourceName: withDefault(StringControl, trans("calendar.resourcesDefault")),
79-
onEvent: ChangeEventHandlerControl,
82+
onEvent: CalendarEventHandlerControl,
8083
// onDropEvent: safeDragEventHandlerControl,
8184
editable: withDefault(BoolControl, true),
8285
showEventTime: withDefault(BoolControl, true),
@@ -120,6 +123,12 @@ let CalendarBasicComp = (function () {
120123
currentFreeView?: string;
121124
currentPremiumView?: string;
122125
}, dispatch: any) => {
126+
127+
const comp = useContext(EditorContext).getUICompByName(
128+
useContext(CompNameContext)
129+
);
130+
const onEventVal = comp?.toJsonValue().comp.onEvent;
131+
123132

124133
const theme = useContext(ThemeContext);
125134
const ref = createRef<HTMLDivElement>();
@@ -303,7 +312,12 @@ let CalendarBasicComp = (function () {
303312
};
304313
showModal(eventInfo, true);
305314
} else {
306-
showModal(editEvent.current, false);
315+
if (onEventVal && onEventVal.some((e: any) => e.name === 'doubleClick')) {
316+
// Check if 'doubleClick' is included in the array
317+
props.onEvent('doubleClick');
318+
} else {
319+
showModal(editEvent.current as EventType, false);
320+
}
307321
}
308322
};
309323

@@ -433,7 +447,6 @@ let CalendarBasicComp = (function () {
433447
props.onDropEvent("dropEvent");
434448
}
435449
};
436-
437450
return (
438451
<Wrapper
439452
ref={ref}

client/packages/lowcoder-core/lib/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1777,7 +1777,7 @@ var CodeNode = /** @class */ (function (_super) {
17771777
return;
17781778
}
17791779
// wait for lazy loaded comps to load before executing query on page load
1780-
if (!Object.keys(value).length) {
1780+
if (!Object.keys(value).length && paths.size) {
17811781
isFetching_1 = true;
17821782
ready_1 = false;
17831783
}

client/packages/lowcoder-core/src/eval/codeNode.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ export class CodeNode extends AbstractNode<ValueAndMsg<unknown>> {
173173
return;
174174
}
175175
// wait for lazy loaded comps to load before executing query on page load
176-
if (!Object.keys(value).length) {
176+
if (!Object.keys(value).length && paths.size) {
177177
isFetching = true;
178178
ready = false;
179179
}

client/packages/lowcoder-design/src/components/Collapase.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { default as AntdCollapse, CollapseProps } from "antd/es/collapse";
2-
import { ReactComponent as UnFold } from "icons/icon-unfold.svg";
3-
import { ReactComponent as Folded } from "icons/icon-folded.svg";
4-
import { ReactComponent as Omit } from "icons/icon-omit.svg";
2+
import { ReactComponent as UnFold } from "icons/v1/icon-unfold.svg";
3+
import { ReactComponent as Folded } from "icons/v1/icon-folded.svg";
4+
import { ReactComponent as Omit } from "icons/v1/icon-omit.svg";
55
import styled, { css } from "styled-components";
66
import React, { ReactNode } from "react";
77

client/packages/lowcoder-design/src/components/CustomModal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { ButtonProps } from "antd/es/button";
22
import { default as AntdModal, ModalFuncProps, ModalProps as AntdModalProps } from "antd/es/modal";
3-
import { ReactComponent as PackUpIcon } from "icons/icon-Pack-up.svg";
3+
import { ReactComponent as PackUpIcon } from "icons/v1/icon-Pack-up.svg";
44
import React, { ReactNode, useState } from "react";
55
import styled from "styled-components";
66
import { TacoButtonType, TacoButton } from "components/button";

client/packages/lowcoder-design/src/components/Menu.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { default as AntdMenu, MenuProps, SubMenuProps } from "antd/es/menu";
22
import { NormalMenuIconColor, TabActiveColor } from "constants/style";
3-
import { ReactComponent as AddIcon } from "icons/icon-add.svg";
4-
import { ReactComponent as RecycleBinIcon } from "icons/icon-recycle-bin.svg";
3+
import { ReactComponent as AddIcon } from "icons/v1/icon-add.svg";
4+
import { ReactComponent as RecycleBinIcon } from "icons/v1/icon-recycle-bin.svg";
55
import styled from "styled-components";
66

77
const MenuItemWrapper = styled.div`

client/packages/lowcoder-design/src/components/ScrollBar.tsx

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,8 @@ interface IProps {
5656
};
5757
$hideplaceholder?: boolean;
5858
hideScrollbar?: boolean;
59+
prefixNode?: React.ReactNode;
60+
suffixNode?: React.ReactNode;
5961
}
6062

6163
export const ScrollBar = ({
@@ -65,6 +67,8 @@ export const ScrollBar = ({
6567
scrollableNodeProps,
6668
hideScrollbar = false,
6769
$hideplaceholder = false,
70+
prefixNode,
71+
suffixNode,
6872
...otherProps
6973
}: IProps) => {
7074
const height = style?.height ?? '100%';
@@ -73,12 +77,24 @@ export const ScrollBar = ({
7377

7478
return hideScrollbar ? (
7579
<ScrollBarWrapper className={className}>
80+
{prefixNode}
7681
{children}
82+
{suffixNode}
7783
</ScrollBarWrapper>
7884
) : (
7985
<ScrollBarWrapper className={className}>
8086
<SimpleBar style={combinedStyle} scrollableNodeProps={scrollableNodeProps} {...otherProps}>
81-
{children}
87+
{({ scrollableNodeProps, contentNodeProps }) => {
88+
return (
89+
<div {...scrollableNodeProps as any}>
90+
{prefixNode}
91+
<div {...contentNodeProps as any}>
92+
{children}
93+
</div>
94+
{suffixNode}
95+
</div>
96+
);
97+
}}
8298
</SimpleBar>
8399
</ScrollBarWrapper>
84100
);

client/packages/lowcoder-design/src/components/Search.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import styled from "styled-components";
22
import { default as Input, InputProps } from "antd/es/input";
3-
import { ReactComponent as Icon } from "icons/icon-Search.svg";
3+
import { ReactComponent as Icon } from "icons/v1/icon-Search.svg";
44
import React, { CSSProperties } from "react";
55

66
const SearchInput = styled(Input)`

client/packages/lowcoder-design/src/components/Section.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { trans } from "i18n/design";
22
import React, { ReactNode, useContext } from "react";
33
import styled from "styled-components";
4-
import { ReactComponent as Packup } from "icons/icon-Pack-up.svg";
4+
import { ReactComponent as Packup } from "icons/v1/icon-Pack-up.svg";
55
import { labelCss } from "./Label";
66
import { controlItem, ControlNode } from "./control";
77
import { Tooltip } from "./toolTip";

client/packages/lowcoder-design/src/components/SuspensionBox.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import styled from "styled-components";
2-
import { ReactComponent as close } from "icons/icon-flokclose.svg";
2+
import { ReactComponent as close } from "icons/v1/icon-flokclose.svg";
33
import { ScrollBar } from "../components/ScrollBar";
44

55
const Container = styled.div<{ $width: number }>`

client/packages/lowcoder-design/src/components/Switch.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import * as React from "react";
22
import { ReactNode } from "react";
33
import styled, { css } from "styled-components";
4-
import { ReactComponent as jsIcon } from "icons/icon-Js-colors.svg";
5-
import { ReactComponent as jsIconGray } from "icons/icon-Js-Gray.svg";
4+
import { ReactComponent as jsIcon } from "icons/v1/icon-Js-colors.svg";
5+
import { ReactComponent as jsIconGray } from "icons/v1/icon-Js-Gray.svg";
66
import { ToolTipLabel } from "components/toolTip";
77

88
type ControlPlacement = "bottom" | "right" | "modal";

client/packages/lowcoder-design/src/components/Trees.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import styled, { css } from "styled-components";
2-
import { ReactComponent as Folded } from "icons/icon-folded.svg";
2+
import { ReactComponent as Folded } from "icons/v1/icon-folded.svg";
33
import { DataNode, TreeProps } from "antd/es/tree";
44
import DirectoryTree from "antd/es/tree/DirectoryTree";
55

client/packages/lowcoder-design/src/components/container.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { trans } from "i18n/design";
22
import { ReactNode } from "react";
33
import styled from "styled-components";
4-
import { ReactComponent as ContainerDrag } from "icons/icon-container-drag.svg";
4+
import { ReactComponent as ContainerDrag } from "icons/v1/icon-container-drag.svg";
55

66
type ContainerPlaceholderProps = {
77
children?: ReactNode;

client/packages/lowcoder-design/src/components/copyTextButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import copy from "copy-to-clipboard";
22
import styled from "styled-components";
3-
import { ReactComponent as Dcopy } from "icons/icon-copy.svg";
3+
import { ReactComponent as Dcopy } from "icons/v1/icon-copy.svg";
44
import { trans } from "i18n/design";
55
import { CSSProperties } from "react";
66
import { messageInstance } from "./GlobalInstances";

client/packages/lowcoder-design/src/components/customSelect.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { default as AntdSelect, SelectProps as AntdSelectProps } from "antd/es/select";
2-
import { ReactComponent as PackUpIcon } from "icons/icon-Pack-up.svg";
2+
import { ReactComponent as PackUpIcon } from "icons/v1/icon-Pack-up.svg";
33
import styled from "styled-components";
44
import React from "react";
55

client/packages/lowcoder-design/src/components/edit.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import styled from "styled-components";
2-
import { ReactComponent as Edit } from "icons/icon-text-edit.svg";
2+
import { ReactComponent as Edit } from "icons/v1/icon-text-edit.svg";
33
import { CSSProperties, ReactNode, useEffect, useRef, useState } from "react";
44
import { Input } from "../components/Input";
55
import { InputProps, InputRef } from "antd/es/input";

client/packages/lowcoder-design/src/components/form.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import { CustomSelect } from "./customSelect";
1111
import { EllipsisTextCss, labelCss } from "./Label";
1212
import { ToolTipLabel } from "./toolTip";
1313
import styled from "styled-components";
14-
import { ReactComponent as Star } from "icons/icon-star.svg";
14+
import { ReactComponent as Star } from "icons/v1/icon-star.svg";
1515
import _ from "lodash";
1616
import { KeyValueList } from "./keyValueList";
1717
import { OptionsType, ValueFromOption } from "./Dropdown";

client/packages/lowcoder-design/src/components/keyValueList.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import styled from "styled-components";
2-
import { ReactComponent as Bin } from "icons/icon-recycle-bin.svg";
2+
import { ReactComponent as Bin } from "icons/v1/icon-recycle-bin.svg";
33
import { TacoButton } from "./button";
44
import { ReactNode } from "react";
55
import { BluePlusIcon } from "icons";

client/packages/lowcoder-design/src/components/option.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import React, { useState } from "react";
88
import { CSS } from "@dnd-kit/utilities";
99
import { SortableContext, useSortable, verticalListSortingStrategy } from "@dnd-kit/sortable";
1010
import { ConstructorToComp, MultiCompConstructor } from "lowcoder-core";
11-
import { ReactComponent as WarnIcon } from "icons/icon-warning-white.svg";
11+
import { ReactComponent as WarnIcon } from "icons/v1/icon-warning-white.svg";
1212
import { DndContext } from "@dnd-kit/core";
1313
import { restrictToVerticalAxis } from "@dnd-kit/modifiers";
1414
import { ActiveTextColor, GreyTextColor } from "constants/style";

client/packages/lowcoder-design/src/components/tacoInput.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { default as AntdInput, InputRef } from "antd/es/input";
2-
import { ReactComponent as MustFillStar } from "icons/icon-must-fill-star.svg";
2+
import { ReactComponent as MustFillStar } from "icons/v1/icon-must-fill-star.svg";
33
import { trans } from "i18n/design";
44
import { CSSProperties, Ref, useEffect, useRef, useState } from "react";
55
import styled, { css } from "styled-components";

client/packages/lowcoder-design/src/components/tacoPagination.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { default as Pagination, PaginationProps } from "antd/es/pagination";
22
import styled, { css } from "styled-components";
3-
import { ReactComponent as PackUpIcon } from "icons/icon-Pack-up.svg";
3+
import { ReactComponent as PackUpIcon } from "icons/v1/icon-Pack-up.svg";
44

55
const packUpIconCss = css`
66
height: 24px;

client/packages/lowcoder-design/src/components/toolTip.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { default as AntdTooltip, TooltipProps } from "antd/es/tooltip";
33
import { CSSProperties, ReactNode } from "react";
44
import styled, { css } from "styled-components";
55
import { labelCss } from "components/Label";
6-
import { ReactComponent as CloseIcon } from "icons/icon-close.svg";
6+
import { ReactComponent as CloseIcon } from "icons/v1/icon-close.svg";
77
import { TooltipRenderProps } from "react-joyride";
88
import { trans } from "i18n/design";
99

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy