-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3595 from illacloud/Release/4.1.3
Release/4.1.3
- Loading branch information
Showing
12 changed files
with
248 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ | |
"private": true, | ||
"author": "ILLA Cloud <[email protected]>", | ||
"license": "Apache-2.0", | ||
"version": "4.1.2", | ||
"version": "4.1.3", | ||
"scripts": { | ||
"dev": "vite --strictPort --force", | ||
"build-cloud": "NODE_OPTIONS=--max-old-space-size=12288 vite build --mode cloud", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions
1
apps/cloud/src/page/workspace/components/ChangeLogModal/constants.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export const CHANGE_LOG_NUM = 5 |
94 changes: 94 additions & 0 deletions
94
apps/cloud/src/page/workspace/components/ChangeLogModal/index.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
import { ILLAMarkdown } from "@illa-public/illa-markdown" | ||
import { FC } from "react" | ||
import { useTranslation } from "react-i18next" | ||
import { | ||
Button, | ||
CloseIcon, | ||
Link, | ||
Modal, | ||
Timeline, | ||
TimelineItem, | ||
getColor, | ||
} from "@illa-design/react" | ||
import ChangeLogIcon from "@/assets/page/workspace/change-log-bg.svg?react" | ||
import { CHANGE_LOG_NUM } from "./constants" | ||
import { ChangeLogModalProps } from "./interface" | ||
import { | ||
changeBgStyle, | ||
changeLogContainerStyle, | ||
closeIconStyle, | ||
contentStyle, | ||
headerStyle, | ||
itemContainerStyle, | ||
itemTitleStyle, | ||
lineContainerStyle, | ||
linkStyle, | ||
modalMaskStyle, | ||
modalStyle, | ||
} from "./style" | ||
|
||
const ChangeLogModal: FC<ChangeLogModalProps> = ({ onClose }) => { | ||
const { t } = useTranslation() | ||
|
||
const CHANGE_LOGS = Array.from(new Array(CHANGE_LOG_NUM)).map((_, index) => ({ | ||
content: t(`page.left.menu.changeLogs.${index + 1}.content`), | ||
title: t(`page.left.menu.changeLogs.${index + 1}.title`), | ||
changeLogLink: t(`page.left.menu.changeLogs.${index + 1}.changeLogLink`), | ||
})) | ||
|
||
return ( | ||
<Modal | ||
visible | ||
maskClosable={false} | ||
footer={false} | ||
css={modalStyle} | ||
maskStyle={modalMaskStyle} | ||
withoutPadding | ||
> | ||
<div css={changeLogContainerStyle}> | ||
<div css={headerStyle}> | ||
<span css={closeIconStyle} onClick={onClose}> | ||
<CloseIcon size="12px" /> | ||
</span> | ||
<span css={changeBgStyle}> | ||
<ChangeLogIcon width="100%" height="100%" /> | ||
</span> | ||
</div> | ||
<div css={contentStyle}> | ||
<Timeline> | ||
{Array.isArray(CHANGE_LOGS) && | ||
CHANGE_LOGS?.map(({ content, changeLogLink, title }, i) => ( | ||
<TimelineItem | ||
key={title} | ||
index={i} | ||
css={lineContainerStyle} | ||
dotColor={getColor("techPurple", "01")} | ||
> | ||
<div css={itemContainerStyle}> | ||
<span css={itemTitleStyle}>{title}</span> | ||
<ILLAMarkdown | ||
textString={content} | ||
textColor={getColor("grayBlue", "02")} | ||
urlColor={getColor("grayBlue", "02")} | ||
/> | ||
<Link | ||
href={changeLogLink ?? ""} | ||
css={linkStyle} | ||
colorScheme="white" | ||
target="_blank" | ||
> | ||
<Button colorScheme={getColor("grayBlue", "02")}> | ||
{t("page.left.menu.changeLogs.read_more")} | ||
</Button> | ||
</Link> | ||
</div> | ||
</TimelineItem> | ||
))} | ||
</Timeline> | ||
</div> | ||
</div> | ||
</Modal> | ||
) | ||
} | ||
|
||
export default ChangeLogModal |
9 changes: 9 additions & 0 deletions
9
apps/cloud/src/page/workspace/components/ChangeLogModal/interface.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
export interface ChangeLog { | ||
content: string | ||
title: string | ||
changeLogLink: string | ||
} | ||
|
||
export interface ChangeLogModalProps { | ||
onClose: () => void | ||
} |
83 changes: 83 additions & 0 deletions
83
apps/cloud/src/page/workspace/components/ChangeLogModal/style.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
import { css } from "@emotion/react" | ||
import { applyMobileStyle } from "@illa-public/utils" | ||
import { getColor } from "@illa-design/react" | ||
|
||
export const modalStyle = css` | ||
min-width: auto; | ||
width: auto; | ||
${applyMobileStyle(css` | ||
width: 716rem; | ||
min-width: 716rem; | ||
`)} | ||
` | ||
export const modalMaskStyle = css` | ||
background-color: ${getColor("white", "05")}; | ||
backdrop-filter: blur(5px); | ||
` | ||
|
||
export const changeLogContainerStyle = css` | ||
overflow: hidden; | ||
` | ||
|
||
export const headerStyle = css` | ||
position: relative; | ||
` | ||
|
||
export const closeIconStyle = css` | ||
position: absolute; | ||
width: 24px; | ||
height: 24px; | ||
line-height: 10px; | ||
text-align: center; | ||
top: 16px; | ||
right: 16px; | ||
cursor: pointer; | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
color: ${getColor("grayBlue", "02")}; | ||
` | ||
export const contentStyle = css` | ||
overflow-y: auto; | ||
padding: 32px; | ||
max-height: 480px; | ||
width: 488px; | ||
${applyMobileStyle(css` | ||
width: 100%; | ||
`)} | ||
` | ||
export const lineContainerStyle = css` | ||
padding: 0; | ||
margin-bottom: 32px; | ||
&:last-of-type { | ||
margin-bottom: 0; | ||
} | ||
` | ||
|
||
export const itemContainerStyle = css` | ||
display: flex; | ||
flex-direction: column; | ||
gap: 8px; | ||
ul, | ||
ol { | ||
padding-left: 16px; | ||
} | ||
` | ||
|
||
export const itemTitleStyle = css` | ||
color: ${getColor("grayBlue", "02")}; | ||
font-size: 16px; | ||
font-style: normal; | ||
font-weight: 600; | ||
line-height: 24px; | ||
` | ||
|
||
export const linkStyle = css` | ||
display: flex; | ||
padding: 0; | ||
` | ||
|
||
export const changeBgStyle = css` | ||
display: flex; | ||
width: 100%; | ||
` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,3 @@ | ||
import { ReactNode } from "react" | ||
|
||
export interface WorkspaceLayoutProps { | ||
children: ReactNode | ||
onAddTeam?: () => void | ||
onOpenChangeLogModal: () => void | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.