Skip to content

Commit

Permalink
chore(web): adjust homepage logo and name (#2030)
Browse files Browse the repository at this point in the history
  • Loading branch information
HUAHUAI23 authored Oct 16, 2024
1 parent 4665f0d commit af5705d
Show file tree
Hide file tree
Showing 10 changed files with 77 additions and 52 deletions.
5 changes: 3 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -141,8 +141,9 @@
"i18next",
"general"
],
"i18n-ally.sourceLanguage": "zh-CN",
"i18n-ally.displayLanguage": "en,zh",
"i18n-ally.sourceLanguage": "zh",
// "i18n-ally.displayLanguage": "en,zh",
"i18n-ally.displayLanguage": "zh",
"i18n-ally.namespace": false,
"i18n-ally.pathMatcher": "{locale}/translation.json",
"i18n-ally.keystyle": "nested",
Expand Down
26 changes: 12 additions & 14 deletions web/index.html
Original file line number Diff line number Diff line change
@@ -1,17 +1,15 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>云开发</title>
</head>

<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>laf</title>
</head>

<body>
<div id="root"></div>
<script defer src="/js/aws-sdk-2.1275.0.min.js"></script>
<script type="module" src="/src/main.tsx"></script>
</body>

</html>
<body>
<div id="root"></div>
<script defer src="/js/aws-sdk-2.1275.0.min.js"></script>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>
Binary file modified web/public/favicon.ico
Binary file not shown.
16 changes: 10 additions & 6 deletions web/public/locales/en/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@
"description": "Laf provides cloud functions, cloud databases, object storage and other capabilities, writing code like a blog! Launch the ChatGPT app in 3 minutes!"
},
"NavBar": {
"title": "Laf is an open-source project, we need your Star",
"title": "sealaf is an open-source project, we need your Star",
"home": "Home",
"dashboard": "Dashboard",
"price": "Price",
Expand All @@ -468,7 +468,7 @@
"HomePage": {
"slogan": "Write Code as effortlessly as Blogging",
"start": "Free Start →",
"content1": "Laf is a cloud development platform integrating functions, databases and storage",
"content1": "Sealaf is a cloud development platform integrating functions, databases and storage",
"content2": "Publish online anytime, anywhere"
},
"Ability": {
Expand Down Expand Up @@ -497,16 +497,16 @@
"serviceSub": "Learn more"
},
"Join": {
"title": "Join the laf developer community",
"title": "Join the sealaf developer community",
"subtitle": "Grow up with us",
"content": "Here you can experience the latest version of Laf at the first time and keep communicating with developers and users in Discord or WeChat groups.",
"WeChat": "WeChat",
"forum": "Forum"
},
"Footer": {
"laf": "Laf provides ready-to-use features such as cloud functions, cloud databases, and object storage. empowers you to write code with the ease of blogging! Get your ChatGPT application up and running in a mere 3 minutes!",
"laf": "sealaf provides ready-to-use features such as cloud functions, cloud databases, and object storage. empowers you to write code with the ease of blogging! Get your ChatGPT application up and running in a mere 3 minutes!",
"product": "Product",
"item1_1": "Laf Cloud",
"item1_1": "sealaf Cloud",
"item1_2": "Sealos Cloud",
"item1_3": "ChangeLog",
"item1_4": "Vscode Plugin",
Expand Down Expand Up @@ -758,5 +758,9 @@
"UpgradeVersionTip": {
"Title": "Laf is ready to update!",
"Description": "Click to update"
},
"app": {
"title": "sealaf",
"logo": "Sealaf"
}
}
}
20 changes: 12 additions & 8 deletions web/public/locales/zh-CN/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@
"description": "Laf 是一个集函数、数据库、存储为一体的云开发平台,随时随地,发布上线"
},
"NavBar": {
"title": "如果你喜欢 Laf 的话,请在 Github 上给我们一个 Star 吧!",
"title": "如果你喜欢 Sealos 云开发的话,请在 Github 上给我们一个 Star 吧!",
"home": "主页",
"dashboard": "控制台",
"price": "价格",
Expand All @@ -468,11 +468,11 @@
"HomePage": {
"slogan": "像写博客一样写代码",
"start": "立即开发",
"content1": "Laf 是一个集函数、数据库、存储为一体的云开发平台",
"content1": "Sealos 云开发是一个集函数、数据库、存储为一体的云开发平台",
"content2": "随时随地,发布上线"
},
"Ability": {
"title": "Laf 的能力",
"title": "Sealos 云开发的能力",
"learn": "了解详情",
"function": "云函数",
"functionSub": ", 5秒发布你的第一个函数。",
Expand All @@ -482,7 +482,7 @@
"storageSub": ",创建属于你的云存储,管理文件更简单。"
},
"Choice": {
"title": "为什么选择 Laf",
"title": "为什么选择 Sealos 云开发",
"open": "更开放",
"openSub": "Laf 遵循 Apache License 2.0 开源协议",
"fast": "请求更快",
Expand All @@ -497,16 +497,16 @@
"serviceSub": "了解详情"
},
"Join": {
"title": "加入 Laf 开发者社区",
"title": "加入 Sealos 云开发开发者社区",
"subtitle": "和我们一起成长",
"content": "在这里你可以在第一时间体验 Laf 的最新版本,以及在 Discord 或微信群与开发者和用户保持沟通",
"WeChat": "微信",
"forum": "开发者社区"
},
"Footer": {
"laf": "Laf 是一个 Serverless 框架,提供开箱即用的云函数,云数据库,对象存储等能力,是一个干净清爽的开发平台,像写博客一样写代码!三分钟上线 ChatGPT 应用!",
"laf": "Sealos 云开发是一个 Serverless 框架,提供开箱即用的云函数,云数据库,对象存储等能力,是一个干净清爽的开发平台,像写博客一样写代码!三分钟上线 ChatGPT 应用!",
"product": "产品",
"item1_1": "Laf 公有云",
"item1_1": "Sealos 云开发",
"item1_2": "Sealos",
"item1_3": "更新日志",
"item1_4": "Vscode 插件",
Expand Down Expand Up @@ -758,5 +758,9 @@
"UpgradeVersionTip": {
"Title": "Laf 新版本已经准备好了!",
"Description": "点击立即更新"
},
"app": {
"title": "云开发",
"logo": "Sealos 云开发"
}
}
}
24 changes: 14 additions & 10 deletions web/public/locales/zh/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@
},
"TriggerPanel": {
"AddTrigger": "新建触发器",
"CornTip": "例 * * * * * \n表示每 1 分钟执行任务",
"CornTip": ": * * * * * \n表示每 1 分钟执行任务",
"DeleteConfirm": "确定删除该触发器吗",
"Express": "表达式",
"Function": "关联函数",
Expand Down Expand Up @@ -449,7 +449,7 @@
"description": "Laf 是一个集函数、数据库、存储为一体的云开发平台,随时随地,发布上线"
},
"NavBar": {
"title": "如果你喜欢 Laf 的话,请在 Github 上给我们一个 Star 吧!",
"title": "如果你喜欢 Sealos 云开发的话,请在 Github 上给我们一个 Star 吧!",
"home": "主页",
"dashboard": "控制台",
"price": "价格",
Expand All @@ -468,11 +468,11 @@
"HomePage": {
"slogan": "像写博客一样写代码",
"start": "立即开发",
"content1": "Laf 是一个集函数、数据库、存储为一体的云开发平台",
"content1": "Sealos 云开发是一个集函数、数据库、存储为一体的云开发平台",
"content2": "随时随地,发布上线"
},
"Ability": {
"title": "Laf 的能力",
"title": "Sealos 云开发的能力",
"learn": "了解详情",
"function": "云函数",
"functionSub": ", 5秒发布你的第一个函数。",
Expand All @@ -482,7 +482,7 @@
"storageSub": ",创建属于你的云存储,管理文件更简单。"
},
"Choice": {
"title": "为什么选择 Laf",
"title": "为什么选择 Sealos 云开发",
"open": "更开放",
"openSub": "Laf 遵循 Apache License 2.0 开源协议",
"fast": "请求更快",
Expand All @@ -497,16 +497,16 @@
"serviceSub": "了解详情"
},
"Join": {
"title": "加入 Laf 开发者社区",
"title": "加入 Sealos 云开发开发者社区",
"subtitle": "和我们一起成长",
"content": "在这里你可以在第一时间体验 Laf 的最新版本,以及在 Discord 或微信群与开发者和用户保持沟通",
"WeChat": "微信",
"forum": "开发者社区"
},
"Footer": {
"laf": "Laf 是一个 Serverless 框架,提供开箱即用的云函数,云数据库,对象存储等能力,是一个干净清爽的开发平台,像写博客一样写代码!三分钟上线 ChatGPT 应用!",
"laf": "Sealos 云开发是一个 Serverless 框架,提供开箱即用的云函数,云数据库,对象存储等能力,是一个干净清爽的开发平台,像写博客一样写代码!三分钟上线 ChatGPT 应用!",
"product": "产品",
"item1_1": "Laf 公有云",
"item1_1": "Sealos 云开发",
"item1_2": "Sealos",
"item1_3": "更新日志",
"item1_4": "Vscode 插件",
Expand Down Expand Up @@ -647,7 +647,6 @@
"FunctionDesc_Name": "函数描述 - 函数名",
"FunctionName_Desc": "函数名 - 函数描述"
},
"MyIncomeAndExpenses": "我的收支",
"Expenses": "支出",
"OrderNumber": "订单号",
"Bonus amount": "赠送金额",
Expand All @@ -659,6 +658,7 @@
"Hour": "小时",
"Core": "",
"No History": "暂无记录",
"MyIncomeAndExpenses": "我的收支",
"RecycleBin": "回收站",
"Restore": "还原",
"CheckAll": "全选",
Expand Down Expand Up @@ -758,5 +758,9 @@
"UpgradeVersionTip": {
"Title": "Laf 新版本已经准备好了!",
"Description": "点击立即更新"
},
"app": {
"title": "云开发",
"logo": "Sealos 云开发"
}
}
}
1 change: 1 addition & 0 deletions web/public/sealos-logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions web/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,19 @@ loader.config({
paths: { vs: "/js/monaco-editor.0.43.0" },
});

const useDocumentTitle = (titleKey: string, defaultTitle: string) => {
const { t } = useTranslation();

useEffect(() => {
document.title = t(titleKey, defaultTitle);
}, [t, titleKey, defaultTitle]);
};

function APP() {
const { i18n } = useTranslation();

useDocumentTitle("app.title", "云开发");

const getSiteSettings = useSiteSettingStore((state) => state.getSiteSettings);
const { initProviders } = useAuthStore();

Expand Down
18 changes: 10 additions & 8 deletions web/src/pages/homepage/footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,15 @@ const Footer = (props: Props) => {
<div className="py-[60px]">
<div className="flex justify-between">
<div className="w-1/2">
<img
src={darkMode ? "logo_light.png" : "/homepage/logo_text.png"}
alt="logo"
width={64}
height={30}
className="mt-4"
/>
<div className="flex items-center space-x-2">
<img
src={darkMode ? "sealos-logo.svg" : "sealos-logo.svg"}
className="h-8 w-auto"
alt="logo"
/>
<span className="text-lg"> {t("app.logo")}</span>
</div>

<p
className={
darkMode
Expand Down Expand Up @@ -174,7 +176,7 @@ const Footer = (props: Props) => {
darkMode ? "w-1/2 text-lg text-lafWhite-700" : "w-1/2 text-lg text-[#3C455D]"
}
>
laf. all rights reserved. © {new Date().getFullYear()}
sealos. all rights reserved. © {new Date().getFullYear()}
<div
dangerouslySetInnerHTML={{
__html: siteSettings.site_footer?.value || "",
Expand Down
9 changes: 5 additions & 4 deletions web/src/pages/homepage/navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,12 +106,13 @@ const Navbar = () => {
>
<div className="flex w-full max-w-[1200px] justify-between">
<div className="flex items-center">
<div>
<div className="flex items-center space-x-2">
<img
src={darkMode ? "logo_light.png" : "logo_text.png"}
className="h-auto w-20"
alt={"logo"}
src={darkMode ? "sealos-logo.svg" : "sealos-logo.svg"}
className="h-8 w-auto"
alt="logo"
/>
<span className="text-lg"> {t("app.logo")}</span>
</div>

{navList.map((item, index) => {
Expand Down

0 comments on commit af5705d

Please sign in to comment.