Skip to content

Commit 9f8eadd

Browse files
committed
export banner
1 parent 77fba22 commit 9f8eadd

File tree

4 files changed

+75
-1
lines changed

4 files changed

+75
-1
lines changed

src/cloud/components/FolderPage/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ import { ViewsManager } from '../Views'
3333
import ApplicationPageLoader from '../ApplicationPageLoader'
3434
import LoaderFolderPage from '../../../design/components/atoms/loaders/LoaderFolderPage'
3535
import ViewerDisclaimer from '../ViewerDisclaimer'
36+
import FolderPageExportSection from '../Onboarding/FolderPageExportSection'
3637

3738
const FolderPage = () => {
3839
const { pageFolder, team, currentUserIsCoreMember } = usePage()
@@ -236,6 +237,7 @@ const FolderPage = () => {
236237
</ApplicationTopbar>
237238
<ApplicationContent>
238239
<FolderPageInviteSection />
240+
<FolderPageExportSection />
239241
<ViewerDisclaimer resource='folder' />
240242
<ViewsManager
241243
parent={{ type: 'folder', target: currentFolder }}

src/cloud/components/Modal/contents/ExportModal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ const ExportModal = () => {
4040
return (
4141
<Container className='export__modal'>
4242
<header className='export__modal__header'>
43-
<div className='export__modal__title'>Export your workspace data</div>
43+
<div className='export__modal__title'>Export your space data</div>
4444
</header>
4545
<p className='export__modal__description'>
4646
The service for boostnote is planned to be retired at the end of
Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
import React from 'react'
2+
import ColoredBlock from '../../../design/components/atoms/ColoredBlock'
3+
import Flexbox from '../../../design/components/atoms/Flexbox'
4+
import styled from '../../../design/lib/styled'
5+
import Button from '../../../design/components/atoms/Button'
6+
import { mdiExport } from '@mdi/js'
7+
import ExportModal from '../Modal/contents/ExportModal'
8+
import { useModal } from '../../../design/lib/stores/modal'
9+
10+
const FolderPageExportSection = () => {
11+
const { openModal } = useModal()
12+
13+
return (
14+
<FolderPageExportSectionContainer>
15+
<ColoredBlock variant='danger' className='export__section__block'>
16+
<Flexbox alignItems='flex-start' justifyContent='space-between'>
17+
<h5>BoostNote is getting discontinued</h5>
18+
19+
<Button
20+
variant='icon'
21+
iconPath={mdiExport}
22+
onClick={() => {
23+
return openModal(<ExportModal />, {
24+
showCloseIcon: true,
25+
width: 'large',
26+
})
27+
}}
28+
iconSize={16}
29+
>
30+
Learn more
31+
</Button>
32+
</Flexbox>
33+
<p>
34+
We thank you for your continued support. We regret to inform you that
35+
the service will end at the end of September. As such we recommend for
36+
users to export their data to make sure nothing is being lost.
37+
</p>
38+
</ColoredBlock>
39+
</FolderPageExportSectionContainer>
40+
)
41+
}
42+
43+
const FolderPageExportSectionContainer = styled.div`
44+
margin: ${({ theme }) => theme.sizes.spaces.df}px
45+
${({ theme }) => theme.sizes.spaces.sm}px;
46+
47+
.export__section__block {
48+
input {
49+
color: ${({ theme }) => theme.colors.text.subtle};
50+
}
51+
h5 {
52+
color: ${({ theme }) => theme.colors.text.primary};
53+
margin: ${({ theme }) => theme.sizes.spaces.sm}px 0;
54+
font-size: ${({ theme }) => theme.sizes.fonts.l}px;
55+
}
56+
p {
57+
color: ${({ theme }) => theme.colors.text.primary};
58+
font-size: ${({ theme }) => theme.sizes.fonts.df}px;
59+
margin-bottom: ${({ theme }) => theme.sizes.spaces.sm}px;
60+
}
61+
.form__row__items {
62+
> * {
63+
margin-bottom: ${({ theme }) => theme.sizes.spaces.sm}px;
64+
}
65+
flex-wrap: wrap;
66+
}
67+
}
68+
`
69+
70+
export default FolderPageExportSection

src/cloud/components/WorkspacePage/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import { ViewsManager } from '../Views'
1818
import ApplicationPageLoader from '../ApplicationPageLoader'
1919
import LoaderFolderPage from '../../../design/components/atoms/loaders/LoaderFolderPage'
2020
import ViewerDisclaimer from '../ViewerDisclaimer'
21+
import FolderPageExportSection from '../Onboarding/FolderPageExportSection'
2122

2223
const WorkspacePage = ({
2324
workspace: pageWorkspace,
@@ -133,6 +134,7 @@ const WorkspacePage = ({
133134
<ApplicationTopbar controls={topbarControls} />
134135
<ApplicationContent>
135136
<FolderPageInviteSection />
137+
<FolderPageExportSection />
136138
<ViewerDisclaimer resource='folder' />
137139
<ViewsManager
138140
parent={{ type: 'workspace', target: workspace }}

0 commit comments

Comments
 (0)