Skip to content

Commit 139a9b4

Browse files
committed
feat: finish
1 parent 649ad7f commit 139a9b4

File tree

15 files changed

+141
-58
lines changed

15 files changed

+141
-58
lines changed

projects/fastgpt/app/[[...lang]]/page.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import CTA from '@/components/home/CTA';
44
import FAQ from '@/components/home/FAQ';
55
import Feature from '@/components/home/Feature';
66
import Hero from '@/components/home/Hero';
7-
import Pricing from '@/components/home/Pricing';
87
// import SocialProof from '@/components/home/SocialProof';
98
import VideoPlayer from '@/components/home/Video';
109
import { defaultLocale, getDictionary, localeNames } from '@/lib/i18n';
@@ -45,7 +44,7 @@ export default async function LangHome({ params: { lang } }: { params: { lang?:
4544
{/* FAQ (Frequently Asked Questions) */}
4645
<FAQ id="FAQ" locale={dict.FAQ} langName={langName} />
4746

48-
{/* CTA (Call to Action) */}
47+
{/* CTA (Call to Action) Footer */}
4948
<CTA locale={dict.CTA} CTALocale={dict.CTAButton} stars={stars} />
5049
</main>
5150
</>

projects/fastgpt/app/layout.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import BaiDuAnalytics from '@/app/BaiDuAnalytics';
22
import GoogleAnalytics from '@/app/GoogleAnalytics';
33
import { TailwindIndicator } from '@/components/TailwindIndicator';
44
import { ThemeProvider } from '@/components/ThemeProvider';
5-
import Footer from '@/components/footer/Footer';
65
import { siteConfig } from '@/config/site';
76
import { defaultLocale } from '@/lib/i18n';
87
import { cn } from '@/lib/utils';
@@ -51,7 +50,7 @@ export default async function RootLayout({
5150
<body className={cn('min-h-screen bg-background font-sans antialiased', fontSans.variable)}>
5251
<ThemeProvider attribute="class" defaultTheme={siteConfig.nextThemeColor} enableSystem>
5352
{children}
54-
<Footer />
53+
{/* <Footer /> */}
5554
<Analytics />
5655
<TailwindIndicator />
5756
</ThemeProvider>

projects/fastgpt/components/home/Ability.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const Ability = ({
1717
return (
1818
<section
1919
id={id}
20-
className="flex flex-col justify-center lg:max-w-7xl md:max-w-5xl w-[90%] mx-auto gap-6 md:gap-12 py-6"
20+
className="flex flex-col justify-center lg:max-w-7xl md:max-w-5xl w-[88%] mx-auto gap-6 md:gap-12 py-6"
2121
>
2222
<h4 className="text-center text-gradient">
2323
{/* <RoughNotation type="highlight" show={true} color="#2563EB"> */}
@@ -48,7 +48,7 @@ const Ability = ({
4848
}}
4949
>
5050
<div className="flex flex-col w-full lg:w-1/3 h-full text-[12px] md:text-[16px] whitespace-pre-wrap">
51-
<div className="p-4 w-16 h-16 mb-5 dark:text-white rounded-2xl flex items-center justify-center" style={{
51+
<div className="p-3 lg:p-4 w-12 h-12 md:w-14 md:h-14 lg:w-16 lg:h-16 mb-5 dark:text-white rounded-2xl flex items-center justify-center" style={{
5252
...(index === 0 && { background: "var(--ability-icon-0)" }),
5353
...(index === 1 && { background: "var(--ability-icon-1)" }),
5454
...(index === 2 && { background: "var(--ability-icon-2)" }),

projects/fastgpt/components/home/CTA.tsx

Lines changed: 106 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,114 @@
11
/* eslint-disable react/no-unescaped-entities */
22
import CTAButton from '@/components/home/CTAButton';
3+
import { siteConfig } from "@/config/site";
4+
import Image from "next/image";
5+
import Link from "next/link";
6+
import React from 'react';
37

48
const CTA = ({ locale, CTALocale, stars }: { locale: any; CTALocale: any; stars: number }) => {
9+
const d = new Date();
10+
const currentYear = d.getFullYear();
11+
const { authors, footerService, footerProducts, footerLinks } = siteConfig;
12+
13+
14+
const LogoFC = () => (<div className="flex items-center md:gap-x-12">
15+
<Link
16+
href="/"
17+
aria-label="FastGPT"
18+
title="FastGPT"
19+
className="flex items-center space-x-2 font-bold "
20+
>
21+
<Image
22+
alt={siteConfig.name}
23+
src="/logo.svg"
24+
className="w-14 h-14 bg-[#E9E9E9] p-2 rounded-xl dark:bg-opacity-20"
25+
width={32}
26+
height={32}
27+
/>
28+
</Link>
29+
</div>)
30+
531
return (
6-
<section className="flex justify-between items-start py-16 gap-12 w-[88%] border-t-2 border-white/10">
7-
<div className="flex flex-col">
8-
<h4 className="text-start text-gradient">
9-
{locale.title.slice(0, 20)}
10-
<br />
11-
{locale.title.slice(20)}
12-
</h4>
13-
<p className="text-large text-white/50">
14-
<span style={{ color: 'var(--text-primary)' }}>{locale.description1}&nbsp;</span>
15-
{locale.description2}
16-
<span style={{ color: 'var(--text-primary)' }}>&nbsp;{locale.description3}&nbsp;</span>
17-
{locale.description4}
18-
<br />
19-
<span style={{ color: 'var(--text-primary)' }}>{locale.description5}&nbsp;</span>
20-
{locale.description6}
21-
22-
23-
24-
{/* <RoughNotation type="box" color="#b71c1c" show={true}>
25-
{locale.description1}
26-
</RoughNotation>
27-
{locale.description2}
28-
<RoughNotation type="box" color="#b71c1c" show={true}>
29-
{locale.description3}
30-
</RoughNotation>
31-
{locale.description4}
32-
<RoughNotation type="box" color="#b71c1c" show={true}>
33-
{locale.description5}
34-
</RoughNotation>
35-
{locale.description6} */}
36-
</p>
37-
</div>
38-
<CTAButton locale={CTALocale} stars={stars} showGithub={false} />
39-
</section>
32+
<footer className='lg:max-w-6xl w-[80%] mx-auto border-t-2 border-white/10 py-12 text-center'>
33+
<div className='md:hidden flex justify-center mb-5'><LogoFC /></div>
34+
35+
<section className="relative flex flex-wrap w-full justify-center">
36+
<div className="flex flex-col gap-2 mb-6 items-center md:items-start md:flex-1">
37+
<h4 className="md:text-start text-gradient md:text-2xl text-base text-center">
38+
{locale.title.slice(0, 20)}
39+
<br />
40+
{locale.title.slice(20)}
41+
</h4>
42+
<p className="md:text-large text-white/50 text-wrap md:text-start text-xs text-center md:max-w-[70%]" >
43+
<span style={{ color: 'var(--text-primary)' }}>{locale.description1}&nbsp;</span>
44+
{locale.description2}
45+
<span style={{ color: 'var(--text-primary)' }}>&nbsp;{locale.description3}&nbsp;</span>
46+
{locale.description4}
47+
<span style={{ color: 'var(--text-primary)' }}>{locale.description5}&nbsp;</span>
48+
{locale.description6}
49+
</p>
50+
</div>
51+
<div className='md:absolute md:top-0 right-0'>
52+
<CTAButton locale={CTALocale} stars={stars} showGithub={false} />
53+
</div>
54+
</section>
55+
56+
<section className='relative mt-12 text-xs'>
57+
<div className='flex flex-col gap-4 justify-center items-center md:absolute md:top-3 md:right-0 md:gap-8'>
58+
{/* <FooterProducts /> */}
59+
<div className='flex gap-8 text-white'>
60+
{footerProducts.map((product) => {
61+
return (
62+
<Link href={product.url} target="_blank" key={product.url}>
63+
{product.name}
64+
</Link>
65+
);
66+
})}
67+
</div>
68+
{/* <FooterLinks /> */}
69+
<div className="w-full flex justify-center items-center text-white/75 md:justify-end gap-6">
70+
{footerLinks.map((link) => (
71+
<Link
72+
key={link.name}
73+
href={link.href}
74+
target="_blank"
75+
rel="noopener noreferrer nofollow"
76+
className="flex max-w-[24px] flex-col items-center justify-center"
77+
>
78+
{link.icon && React.createElement(link.icon, { className: 'text-2xl' })}
79+
</Link>
80+
))}
81+
</div>
82+
</div>
83+
84+
<div className='hidden md:block mb-8'><LogoFC /></div>
85+
<div className='flex flex-wrap justify-center text-white/65 md:justify-start mt-8 md:mt-0 '>
86+
<div className="flex space-x-2 text-nowrap gap-3">
87+
{footerService.map((product) => {
88+
return (
89+
<Link href={product.url} target="_blank" key={product.url}>
90+
{product.name}
91+
</Link>
92+
);
93+
})}
94+
</div>
95+
<div className='hidden xs:block'>|</div>
96+
<div>
97+
<span>{${currentYear}`}&nbsp;</span>
98+
<Link href={authors[0].twitter || authors[0].url} target="_blank">
99+
{authors[0].name}
100+
</Link>
101+
<span>&nbsp;All rights reserved.</span>
102+
{process.env.NEXT_PUBLIC_FILING_ADDRESS && (
103+
<Link href={'https://beian.miit.gov.cn/'}>
104+
{process.env.NEXT_PUBLIC_FILING_ADDRESS}
105+
</Link>
106+
)}
107+
</div>
108+
</div>
109+
110+
</section>
111+
</footer>
40112
);
41113
};
42114

projects/fastgpt/components/home/FAQ.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const FAQ = ({
2323
return (
2424
<section
2525
id={id}
26-
className="flex flex-col justify-center max-w-[88%] items-center py-16 gap-12"
26+
className="flex flex-col justify-center lg:max-w-6xl w-[80%] mx-auto items-center py-16 gap-12"
2727
>
2828
<div className="flex flex-col text-center">
2929
<h4 className="text-center text-gradient">

projects/fastgpt/components/home/Feature.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const Feature = ({
1717
return (
1818
<section
1919
id={id}
20-
className="flex flex-col justify-center lg:max-w-7xl md:max-w-5xl w-[90%] mx-auto py-6"
20+
className="flex flex-col justify-center lg:max-w-7xl md:max-w-5xl w-[88%] mx-auto py-6"
2121
>
2222
<h4 className="text-center text-gradient">
2323
{/* <RoughNotation type="highlight" show={true} color="#2563EB"> */}
@@ -39,7 +39,7 @@ const Feature = ({
3939
background: "var(--theme-gradient)"
4040
}}
4141
>
42-
<div className="p-3 w-14 h-14 mb-5 text-white rounded-xl flex items-center justify-center"
42+
<div className="p-3 lg:p-4 w-12 h-12 md:w-14 md:h-14 lg:w-16 lg:h-16 mb-5 text-white rounded-xl flex items-center justify-center"
4343
style={{ background: "var(--feature-icon)" }}>
4444
{feature.icon &&
4545
React.createElement(feature.icon, { className: "text-2xl" })}
@@ -52,7 +52,7 @@ const Feature = ({
5252
))}
5353
</div>
5454

55-
<div className="inline-block mx-auto border font-bold rounded-full px-6 py-3 text-xs lg:text-sm mt-10"
55+
<div className="inline-block mx-auto border font-bold rounded-full px-6 py-3 text-xs lg:text-sm mt-10 md:text-nowrap"
5656
style={{
5757
color: '#B5E8FD',
5858
background: 'linear-gradient(90deg, rgba(212, 212, 249, 0.15) 0%, rgba(55, 55, 214, 0.00) 100%)',

projects/fastgpt/components/home/Video.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,7 @@ const VideoPlayer = ({
5757
return (
5858
<div
5959
id="player-container"
60-
className="mx-auto max-w-4xl lg:max-w-6xl mb-12 mt-6 px-4 sm:px-6 lg:px-8 md:mt-20 text-center h-[200px] sm:h-[500px] lg:h-[700px]"
61-
60+
className="mx-auto mb-12 max-w-[88%] 2xl:max-w-7xl mt-6 md:mt-20 text-center h-[200px] md:h-[450px] lg:h-[600px] xl:h-[750px] 2xl:h-[850px]"
6261
>
6362
<div className="rounded-lg overflow-hidden">
6463
<video

projects/fastgpt/config/site.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,9 @@ const baseSiteConfig = {
7272
{ url: 'https://doc.fastgpt.in', name: 'Docs' },
7373
{ url: 'https://doc.fastgpt.in/docs/community/', name: 'Forum' },
7474
{ url: 'https://uuhyahynnudq.hzh.sealos.run/status/in', name: 'Status' },
75-
{ url: 'https://doc.fastgpt.in/docs/agreement/terms', name: 'Terms of Service' },
75+
],
76+
footerService:[
77+
{ url: 'https://doc.fastgpt.in/docs/agreement/terms', name: 'Terms of Service' },
7678
{ url: 'https://doc.fastgpt.in/docs/agreement/privacy', name: 'Privacy Policy' }
7779
]
7880
};

projects/fastgpt/locales/ar.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
},
1111
{
1212
"label": "الأسعار",
13-
"href": "#Pricing"
13+
"href": "https://cloud.tryfastgpt.ai/price"
1414
},
1515
{
1616
"label": "الأسئلة الشائعة",
@@ -33,7 +33,9 @@
3333
},
3434
"Feature": {
3535
"title": "المزايا الرئيسية لـ FastGPT",
36-
"description": "لماذا تختار FastGPT لتلبية احتياجات قاعدة معرفة الذكاء الاصطناعي الخاصة بك؟"
36+
"description": "لماذا تختار FastGPT لتلبية احتياجات قاعدة معرفة الذكاء الاصطناعي الخاصة بك؟",
37+
"doYouLike": "هل تستمتع باستخدام حل قاعدة معرفة الذكاء الاصطناعي مفتوح المصدر هذا؟",
38+
"follow": "أظهر تقديرك بمنحنا نجمة 🌟"
3739
},
3840
"Ability": {
3941
"title": "جاهز للنشر"

projects/fastgpt/locales/en.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
},
1111
{
1212
"label": "Pricing",
13-
"href": "#Pricing"
13+
"href": "https://cloud.tryfastgpt.ai/price"
1414
},
1515
{
1616
"label": "FAQ",

0 commit comments

Comments
 (0)