Skip to content

Commit b9f85cd

Browse files
committed
processed integrating svg icons into central MultiIcon
1 parent 38c1d53 commit b9f85cd

File tree

121 files changed

+874
-1155
lines changed

Some content is hidden

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

121 files changed

+874
-1155
lines changed

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

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ import styled from "styled-components";
66
import { TacoButtonType, TacoButton } from "components/button";
77
import Draggable from "react-draggable";
88
import { DarkActiveTextColor, GreyTextColor } from "constants/style";
9-
import { CloseIcon, ErrorIcon, SuccessIcon, WarningIcon, WarningWhiteIcon } from "icons";
109
import { trans } from "i18n/design";
1110
import { modalInstance } from "components/GlobalInstances";
11+
import {MultiIconDisplay} from "lowcoder/src/comps/comps/multiIconDisplay";
1212

1313
type ModalWrapperProps = {
1414
$width?: string | number;
@@ -130,7 +130,7 @@ function ModalHeader(props: {
130130
)}
131131
<ModalHeaderTitle>{props.title}</ModalHeaderTitle>
132132
<ModalCloseIcon onClick={props.onCancel}>
133-
<CloseIcon />
133+
<MultiIconDisplay identifier="/icon:svg/CloseIcon" />
134134
</ModalCloseIcon>
135135
</>
136136
);
@@ -264,10 +264,10 @@ function CustomModal(props: CustomModalProps) {
264264
}
265265

266266
const TitleIcon = {
267-
error: <ErrorIcon />,
268-
warn: <WarningIcon />,
269-
info: <WarningWhiteIcon />,
270-
success: <SuccessIcon />,
267+
error: <MultiIconDisplay identifier="/icon:svg/ErrorIcon" />,
268+
warn: <MultiIconDisplay identifier="/icon:svg/WarningIcon" />,
269+
info: <MultiIconDisplay identifier="/icon:svg/WarningWhiteIcon" />,
270+
success: <MultiIconDisplay identifier="/icon:svg/SuccessIcon" />,
271271
};
272272

273273
CustomModal.confirm = (props: {

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { ActiveTextColor, GreyTextColor } from "constants/style";
2-
import { DocIcon } from "icons";
32
import styled from "styled-components";
3+
import {MultiIcon} from "lowcoder/src/comps/comps/multiIconDisplay";
44

55
export const ExternalLink = styled.a`
66
font-size: 13px;
@@ -14,7 +14,7 @@ export const ExternalLink = styled.a`
1414
}
1515
`;
1616

17-
const StyledDocIcon = styled(DocIcon)`
17+
const StyledDocIcon = styled(MultiIcon("/icon:svg/DocIcon"))`
1818
height: 12px;
1919
width: 12px;
2020
margin-right: 4px;

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

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React from "react";
22
import styled, { css } from "styled-components";
3-
import { PointIcon, DragIcon, PencilIcon } from "icons";
43
import { labelCss } from "./Label";
4+
import {MultiIcon} from "lowcoder/src/comps/comps/multiIconDisplay";
55

66
interface IItem {
77
$width?: number;
@@ -26,7 +26,7 @@ const IconCss = css`
2626
cursor: pointer;
2727
}
2828
`;
29-
const StyledDragIcon = styled(DragIcon)`
29+
const StyledDragIcon = styled(MultiIcon("/icon:svg/DragIcon"))`
3030
${IconCss}
3131
margin-left: 12px;
3232
margin-top: 8px;
@@ -79,12 +79,12 @@ const GrayText = styled.span`
7979
color: #8b8fa3;
8080
margin-left: 8px;
8181
`;
82-
const StyledPencilIcon = styled(PencilIcon)`
82+
const StyledPencilIcon = styled(MultiIcon("/icon:svg/PencilIcon"))`
8383
${IconCss}
8484
margin-top: 8px;
8585
float: right;
8686
`;
87-
const StyledPointIcon = styled(PointIcon)`
87+
const StyledPointIcon = styled(MultiIcon("/icon:svg/PointIcon"))`
8888
${IconCss}
8989
margin-left: 16px;
9090
margin-top: 8px;

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

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
import styled from "styled-components";
2-
import { BluePlusIcon } from "icons";
32
import { EllipsisTextCss, labelCss } from "./Label";
43
import { LinkButton } from "./button";
54
import { ReactNode } from "react";
65
import { trans } from "i18n/design";
6+
import {MultiIcon, MultiIconDisplay} from "lowcoder/src/comps/comps/multiIconDisplay";
77

88
const InlineEventFormWrapper = styled.div`
99
display: flex;
@@ -112,12 +112,13 @@ const AddLine = (props: { title: ReactNode; add: () => void }) => {
112112
return (
113113
<TitleDiv>
114114
<TitleSpan>{props.title}</TitleSpan>
115-
<LinkButton icon={<BluePlusIcon />} text={trans("addItem")} onClick={props.add} />
115+
<LinkButton icon={<MultiIconDisplay identifier="/icon:svg/BluePlusIcon" />} text={trans("addItem")} onClick={props.add} />
116116
</TitleDiv>
117117
);
118118
};
119+
const Blueplus = MultiIcon("/icon:svg/BluePlusIcon")
119120
export {
120-
BluePlusIcon as AddEventIcon,
121+
Blueplus as AddEventIcon,
121122
EventDiv,
122123
EventContent,
123124
EventTitle,

client/packages/lowcoder-design/src/components/iconSelect/index.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ import {
1919
import Draggable from "react-draggable";
2020
import { default as List, type ListRowProps } from "react-virtualized/dist/es/List";
2121
import styled from "styled-components";
22-
import { CloseIcon, SearchIcon } from "icons";
2322
import { ANTDICON } from "icons/antIcon";
23+
import {MultiIcon} from "lowcoder/src/comps/comps/multiIconDisplay";
2424

2525
const PopupContainer = styled.div`
2626
width: 580px;
@@ -42,7 +42,7 @@ const TitleText = styled.span`
4242
color: #222222;
4343
line-height: 16px;
4444
`;
45-
const StyledCloseIcon = styled(CloseIcon)`
45+
const StyledCloseIcon = styled(MultiIcon("/icon:svg/CloseIcon"))`
4646
width: 16px;
4747
height: 16px;
4848
cursor: pointer;
@@ -60,7 +60,7 @@ const SearchDiv = styled.div`
6060
display: flex;
6161
justify-content: space-between;
6262
`;
63-
const StyledSearchIcon = styled(SearchIcon)`
63+
const StyledSearchIcon = styled(MultiIcon("/icon:svg/SearchIcon"))`
6464
position: absolute;
6565
top: 6px;
6666
left: 12px;

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ import styled from "styled-components";
22
import { ReactComponent as Bin } from "icons/v1/icon-recycle-bin.svg";
33
import { TacoButton } from "./button";
44
import { ReactNode } from "react";
5-
import { BluePlusIcon } from "icons";
65
import { trans } from "i18n/design";
6+
import {MultiIcon} from "lowcoder/src/comps/comps/multiIconDisplay";
77

88
const KeyValueListItem = styled.div`
99
display: flex;
@@ -33,7 +33,7 @@ const DelIcon = styled(Bin)<{
3333
}
3434
`;
3535

36-
const AddIcon = styled(BluePlusIcon)`
36+
const AddIcon = styled(MultiIcon("/icon:svg/BluePlusIcon"))`
3737
height: 8px;
3838
width: 8px;
3939
margin-right: 4px;

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

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import styled, { css } from "styled-components";
2-
import { DragIcon, PointIcon } from "icons";
32
import { EllipsisTextCss, labelCss } from "./Label";
43
import { EditPopover, SimplePopover } from "./popover";
54
import { ToolTipLabel } from "./toolTip";
@@ -13,6 +12,7 @@ import { DndContext } from "@dnd-kit/core";
1312
import { restrictToVerticalAxis } from "@dnd-kit/modifiers";
1413
import { ActiveTextColor, GreyTextColor } from "constants/style";
1514
import { trans } from "i18n/design";
15+
import {MultiIcon} from "lowcoder/src/comps/comps/multiIconDisplay";
1616

1717
const OptionDiv = styled.div`
1818
width: 100%;
@@ -103,7 +103,7 @@ const EmptyOptionSpan = styled.span`
103103
}
104104
`;
105105

106-
const StyledDragIcon = styled(DragIcon)`
106+
const StyledDragIcon = styled(MultiIcon("/icon:svg/DragIcon"))`
107107
${IconCss};
108108
margin-top: 8px;
109109
margin-left: 8px;
@@ -120,7 +120,7 @@ const StyledDragIcon = styled(DragIcon)`
120120
}
121121
`;
122122

123-
const StyledPointIcon = styled(PointIcon)`
123+
const StyledPointIcon = styled(MultiIcon("/icon:svg/PointIcon"))`
124124
${IconCss};
125125
color: ${GreyTextColor};
126126

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { Children, cloneElement, MouseEvent, ReactNode, useState } from "react";
44
import styled from "styled-components";
55
import { ActiveTextColor, GreyTextColor } from "constants/style";
66
import { trans } from "i18n/design";
7-
import { PointIcon } from "icons";
7+
import {MultiIcon} from "lowcoder/src/comps/comps/multiIconDisplay";
88

99
const Wedge = styled.div`
1010
height: 8px;
@@ -36,7 +36,7 @@ const Handle = styled.div`
3636
}
3737
`;
3838

39-
const StyledPointIcon = styled(PointIcon)`
39+
const StyledPointIcon = styled(MultiIcon("/icon:svg/PointIcon"))`
4040
cursor: pointer;
4141
color: ${GreyTextColor};
4242

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { default as Card } from "antd/es/card";
33
import { CopyTextButton } from "./copyTextButton";
44
import { CSSProperties, ReactNode, useState } from "react";
55
import styled from "styled-components";
6-
import { ErrorIcon, SuccessIcon } from "icons";
6+
import {MultiIconDisplay} from "lowcoder/src/comps/comps/multiIconDisplay";
77

88
const StyledCard = styled(Card)<{ $backcolor: string }>`
99
z-index: 3;
@@ -126,7 +126,7 @@ export function PopupCard(props: PopupCardProps) {
126126
message={props.title}
127127
type={props.hasError ? "error" : "success"}
128128
showIcon
129-
icon={props.hasError ? <ErrorIcon /> : <SuccessIcon />}
129+
icon={props.hasError ? <MultiIconDisplay identifier="/icon:svg/ErrorIcon" /> : <MultiIconDisplay identifier="/icon:svg/SuccessIcon" />}
130130
/>
131131
}
132132
extra={<CopyTextButton text={props.content ?? ""} />}

client/packages/lowcoder-design/src/components/shapeSelect/index.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ import {
2424
type ListRowProps,
2525
} from "react-virtualized/dist/es/List";
2626
import styled from "styled-components";
27-
import { CloseIcon, SearchIcon } from "icons";
2827
import { ANTDICON } from "icons/antIcon";
2928
import { JSX } from "react/jsx-runtime";
29+
import {MultiIcon} from "lowcoder/src/comps/comps/multiIconDisplay";
3030

3131
const PopupContainer = styled.div`
3232
width: 580px;
@@ -48,7 +48,7 @@ const TitleText = styled.span`
4848
color: #222222;
4949
line-height: 16px;
5050
`;
51-
const StyledCloseIcon = styled(CloseIcon)`
51+
const StyledCloseIcon = styled(MultiIcon("/icon:svg/CloseIcon"))`
5252
width: 16px;
5353
height: 16px;
5454
cursor: pointer;
@@ -66,7 +66,7 @@ const SearchDiv = styled.div`
6666
display: flex;
6767
justify-content: space-between;
6868
`;
69-
const StyledSearchIcon = styled(SearchIcon)`
69+
const StyledSearchIcon = styled(MultiIcon("/icon:svg/SearchIcon"))`
7070
position: absolute;
7171
top: 6px;
7272
left: 12px;

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { default as Pagination, PaginationProps } from "antd/es/pagination";
22
import styled, { css } from "styled-components";
33
import { ReactComponent as PackUpIcon } from "icons/v1/icon-Pack-up.svg";
4+
import {MultiIconDisplay} from "lowcoder/src/comps/comps/multiIconDisplay";
45

56
const packUpIconCss = css`
67
height: 24px;
@@ -89,10 +90,10 @@ const StyledPagination = styled(Pagination)`
8990

9091
export const pageItemRender: PaginationProps["itemRender"] = (_, type, originalElement) => {
9192
if (type === "prev") {
92-
return <PrevIcon />;
93+
return <MultiIconDisplay identifier="/icon:svg/PrevIcon" />;
9394
}
9495
if (type === "next") {
95-
return <NextIcon />;
96+
return <MultiIconDisplay identifier="/icon:svg/NextIcon" />;
9697
}
9798
return originalElement;
9899
};

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// import ReactPlayer from "react-player";
22
import { lazy } from 'react';
33
import styled from "styled-components";
4-
import { VideoCompIcon } from "icons";
4+
import {MultiIcon} from "lowcoder/src/comps/comps/multiIconDisplay";
55

66
const ReactPlayer = lazy(() => import("react-player"));
77

@@ -28,7 +28,7 @@ export const Container = styled.div`
2828
}
2929
}
3030
`;
31-
const PlayTriangle = styled(VideoCompIcon)`
31+
const PlayTriangle = styled(MultiIcon("/icon:svg/VideoCompIcon"))`
3232
position: absolute;
3333
left: 0;
3434
top: 0;

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