Skip to content

Commit

Permalink
refactor: wip
Browse files Browse the repository at this point in the history
  • Loading branch information
mydearxym committed Dec 25, 2023
1 parent 65f72b4 commit 955821f
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 59 deletions.
34 changes: 0 additions & 34 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@
"react-portal": "^4.2.2",
"react-scroll-parallax": "^3.4.5",
"react-select": "^5.5.7",
"react-svg": "15.1.10",
"react-swipeable": "^7.0.0",
"react-textarea-autosize": "^8.3.0",
"react-tooltip": "^4.2.21",
Expand Down
35 changes: 34 additions & 1 deletion src/app/Landing/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,39 @@ import {
FAQWrapper,
} from './styles'

const faqs = [
{
title: 'Groupher 是免费的吗',
body: '是的,在一定额度内免费使用,部分高级功能需要收费。',
index: 0,
},
{
title: '可以只使用某些模块吗',
body: '是的,你可以根据需要单独使用讨论区、看板、更新日志等。',
index: 1,
},
{
title: '可以私有部署吗',
body: '是的,本项目完全开源,你可以用于私有部署,但需要遵守特定协议。',
index: 2,
},
{
title: '支持手机端使用吗',
body: '是的,本项目对于手机屏幕做了适配。但目前没有原生的 App',
index: 3,
},
{
title: '支持内容审核吗',
body: '是的,你可以在后台打开先审后发,同时平台 AI 自动会过滤违法信息。',
index: 4,
},
{
title: '支持海外访问吗',
body: '是的,但是目前服务器在国内,国际化相关工作还在开发中,敬请期待。',
index: 5,
},
]

const LandingPage: FC = () => {
const router = useRouter()
const { wallpaper } = useWallpaper()
Expand Down Expand Up @@ -122,7 +155,7 @@ const LandingPage: FC = () => {
<Divider top={50} bottom={50} />
</MobileOnly>
<FAQWrapper>
<FaqList layout={DOC_FAQ_LAYOUT.FLAT} large />
<FaqList layout={DOC_FAQ_LAYOUT.FLAT} large sections={faqs} />
</FAQWrapper>
</Wrapper>
</ParallaxProvider>
Expand Down
2 changes: 1 addition & 1 deletion src/app/Landing/styles/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ export const Divider = styled.div<TSpace>`
`
export const FAQWrapper = styled.div`
width: 100%;
max-width: 1080px;
max-width: 1048px;
margin-bottom: 20px;
`

Expand Down
12 changes: 0 additions & 12 deletions src/widgets/Img/SvgLoader.tsx

This file was deleted.

10 changes: 0 additions & 10 deletions src/widgets/Img/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import { FC, ReactNode, memo } from 'react'
import { buildLog } from '@/logger'

// import SvgLoader from './SvgLoader'
import NormalImg from './NormalImg'
import LazyLoadImg from './LazyLoadImg'

Expand Down Expand Up @@ -38,15 +37,6 @@ const Img: FC<IProps> = ({
// see solution in:
// https://github.com/tanem/react-svg/issues/676#issuecomment-589639104
return <>SVG TODO</>
// return (
// <SvgLoader
// src={src}
// beforeInjection={(svg) =>
// className.split(' ').map((singleClassName) => svg.classList.add(singleClassName))
// }
// onClick={onClick}
// />
// )
}
return (
<>
Expand Down

0 comments on commit 955821f

Please sign in to comment.