Skip to content

Commit be6bd7c

Browse files
committed
feat(website): 新增赞助商火山引擎(中英文分站链接)
1 parent 6ceb8ff commit be6bd7c

6 files changed

Lines changed: 44 additions & 12 deletions

File tree

8 KB
Loading

website/src/components/home/SponsorStrip.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { ArrowRight, Heart } from "lucide-react";
22
import { Link } from "react-router-dom";
33
import { useLanguage } from "@/i18n/LanguageProvider";
4-
import { sponsors } from "@/content/sponsors";
4+
import { sponsorUrl, sponsors } from "@/content/sponsors";
55

66
export function SponsorStrip() {
77
const { t, lang, prefix } = useLanguage();
@@ -22,7 +22,7 @@ export function SponsorStrip() {
2222
{sponsors.map((s) => (
2323
<a
2424
key={s.id}
25-
href={s.url}
25+
href={sponsorUrl(s, lang)}
2626
target="_blank"
2727
rel="noreferrer"
2828
className="flex w-[260px] items-center gap-3 rounded-2xl border border-border/70 bg-card/60 p-4 transition-colors hover:border-primary/40"

website/src/components/sponsors/SponsorCard.tsx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,19 @@
11
import { ArrowUpRight, Sparkles } from "lucide-react";
22
import { useLanguage } from "@/i18n/LanguageProvider";
3-
import type { Sponsor } from "@/content/sponsors";
3+
import { sponsorUrl, type Sponsor } from "@/content/sponsors";
44
import { PerkText } from "./PerkText";
55
import { cn } from "@/lib/utils";
66

77
export function SponsorCard({ sponsor }: { sponsor: Sponsor }) {
88
const { lang } = useLanguage();
99
const s = sponsor;
10+
const href = sponsorUrl(s, lang);
1011

1112
// 旗舰 + 有 banner:全宽大屏卡片,图片在上、文字在下(参考 CC Switch 旗舰位)
1213
if (s.banner) {
1314
return (
1415
<div className="group relative flex flex-col overflow-hidden rounded-2xl border border-gold/40 bg-card/60 transition-all hover:border-gold/70 md:col-span-2 lg:col-span-3">
15-
<a href={s.url} target="_blank" rel="noreferrer" className="block">
16+
<a href={href} target="_blank" rel="noreferrer" className="block">
1617
<img src={s.banner} alt={s.name} className="aspect-[1269/337] w-full object-cover" />
1718
</a>
1819

@@ -30,7 +31,7 @@ export function SponsorCard({ sponsor }: { sponsor: Sponsor }) {
3031
</span>
3132
)}
3233
<a
33-
href={s.url}
34+
href={href}
3435
target="_blank"
3536
rel="noreferrer"
3637
className="ml-auto inline-flex items-center gap-2 rounded-xl bg-gold px-5 py-2.5 text-sm font-semibold text-gold-foreground transition-opacity hover:opacity-90"
@@ -51,7 +52,7 @@ export function SponsorCard({ sponsor }: { sponsor: Sponsor }) {
5152

5253
return (
5354
<a
54-
href={s.url}
55+
href={href}
5556
target="_blank"
5657
rel="noreferrer"
5758
className="group relative flex min-h-[180px] flex-col rounded-2xl border border-border/70 bg-card/60 p-6 transition-all hover:z-20 hover:-translate-y-0.5 hover:border-primary/40"

website/src/components/sponsors/SponsorPerksTable.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { ExternalLink, Sparkles } from "lucide-react";
22
import { CopyButton } from "@/components/ui/copy-button";
33
import { useLanguage } from "@/i18n/LanguageProvider";
4-
import { sponsors } from "@/content/sponsors";
4+
import { sponsorUrl, sponsors } from "@/content/sponsors";
55

66
export function SponsorPerksTable() {
77
const { t, lang } = useLanguage();
@@ -59,7 +59,7 @@ export function SponsorPerksTable() {
5959
)}
6060
</td>
6161
<td className="px-5 py-3.5 text-right">
62-
<a href={sp.url} target="_blank" rel="noreferrer" className="inline-flex items-center gap-1 font-medium text-primary hover:underline">
62+
<a href={sponsorUrl(sp, lang)} target="_blank" rel="noreferrer" className="inline-flex items-center gap-1 font-medium text-primary hover:underline">
6363
{s.visit}
6464
<ExternalLink className="size-3.5" />
6565
</a>

website/src/components/studio/StudioSponsorSlot.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { ArrowUpRight, Sparkles } from "lucide-react";
22
import { useLanguage } from "@/i18n/LanguageProvider";
3-
import { sponsorsByTier } from "@/content/sponsors";
3+
import { sponsorUrl, sponsorsByTier } from "@/content/sponsors";
44
import { PerkText } from "@/components/sponsors/PerkText";
55
import { cn } from "@/lib/utils";
66

@@ -16,7 +16,7 @@ export function StudioSponsorSlot() {
1616
return (
1717
<div className="container-page pb-8">
1818
<a
19-
href={sponsor.url}
19+
href={sponsorUrl(sponsor, lang)}
2020
target="_blank"
2121
rel="noreferrer"
2222
className="group flex flex-wrap items-center gap-x-4 gap-y-2 rounded-2xl border border-gold/40 bg-gold/[0.04] px-5 py-3.5 transition-colors hover:border-gold/70"

website/src/content/sponsors.ts

Lines changed: 33 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import type { Language } from "@/i18n/translations";
33
/**
44
* 赞助商数据。
55
*
6-
* 当前赞助商:APINEBULA(旗舰,银河录像局旗下 AI 聚合平台)、优云智算(UCloud 旗下 AI 云平台)、RootFlowAI(大模型 API 聚合平台)、Cubence(API 中转服务商)、CCSub(AI API 中转平台)。
6+
* 当前赞助商:APINEBULA(旗舰,银河录像局旗下 AI 聚合平台)、优云智算(UCloud 旗下 AI 云平台)、RootFlowAI(大模型 API 聚合平台)、Cubence(API 中转服务商)、CCSub(AI API 中转平台)、火山引擎(字节跳动云服务,中英文分别对应 volcengine.com / byteplus.com 两个不同站点)
77
* 均为真实付费赞助,非占位样例。新增赞助商时按 Sponsor 结构追加即可。
88
*/
99

@@ -22,7 +22,8 @@ export interface Sponsor {
2222
logo?: string;
2323
/** 大屏 banner 图(public 目录下的路径)。旗舰赞助商用,全宽展示 */
2424
banner?: string;
25-
url: string;
25+
/** 跳转链接。多数赞助商中英文共用同一个链接;少数品牌中国大陆站点和国际站点是不同域名(如火山引擎/BytePlus),此时传 LocalizedText,按当前语言取值 */
26+
url: string | LocalizedText;
2627
tier: SponsorTier;
2728
tagline: LocalizedText;
2829
description: LocalizedText;
@@ -159,8 +160,38 @@ export const sponsors: Sponsor[] = [
159160
en: "$5 free credit on sign-up",
160161
},
161162
},
163+
{
164+
id: "volcengine",
165+
name: "火山引擎",
166+
badge: "🌋",
167+
accent: "from-blue-600 to-cyan-400",
168+
logo: "/sponsors/logo-volcengine-icon.png",
169+
url: {
170+
zh: "https://www.volcengine.com/activity/ai618?utm_campaign=hw&utm_content=hw&utm_medium=devrel_tool_web&utm_source=OWO&utm_term=agency-agents-zh",
171+
en: "https://www.byteplus.com/en/product/modelark?utm_campaign=hw&utm_content=jnMetaCode&utm_medium=devrel_tool_web&utm_source=OWO&utm_term=jnMetaCode",
172+
},
173+
tier: "standard",
174+
since: "2026-07",
175+
featured: false,
176+
tagline: {
177+
zh: "豆包大模型限时 5 折起 · 编程模型套餐 2.5 折订阅",
178+
en: "Dola Seed 2.0 — ByteDance's full-modal general large model, on the ModelArk platform",
179+
},
180+
description: {
181+
zh: "感谢火山引擎赞助了本项目!火山引擎 AI 巅峰盛惠来袭:豆包大模型限时 5 折起,19 元即可入手约 440 万 Tokens 文本模型,新客首单再享 AI 统一节省计划。从文本生成、图像创作到视频合成、语音复刻,全模态 AI 能力一站式配齐;开发者专属编程模型套餐 2.5 折订阅,支持 Kimi-K2.7、GLM-5.2 等主流模型。",
182+
en: "Thanks to Dola Seed for sponsoring this project! Dola Seed 2.0 is a full-modal general large model independently developed by ByteDance for the global market. Built on a unified multimodal architecture, it supports joint understanding and generation of text, images, audio and video. It natively enables agent collaboration, with strong reasoning, long-task execution, tool integration and coding capabilities — widely applicable to smart cockpits, personal assistants, education, customer support, marketing, retail and more. It excels in multimodal perception, end-to-end complex task delivery, stable interaction and data security, and is readily accessible and deployable via the ModelArk platform.",
183+
},
184+
perk: {
185+
zh: "注册即领 2500 万 Tokens,立即访问活动页面抢购",
186+
en: "Register via the link to get 500,000 tokens of free inference quota per model",
187+
},
188+
},
162189
];
163190

164191
export function sponsorsByTier(tier: SponsorTier) {
165192
return sponsors.filter((s) => s.tier === tier);
166193
}
194+
195+
export function sponsorUrl(sponsor: Pick<Sponsor, "url">, lang: Language): string {
196+
return typeof sponsor.url === "string" ? sponsor.url : sponsor.url[lang];
197+
}

0 commit comments

Comments
 (0)