🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
TypeScript agentagent-collaborationagent-harnessloop-engineeringmcppersonal-assistantproactive-agentskillssuper-agenttask-management
🌐 chore: translate non-English comments to English in edge-config (#14453)
LobeHub Bot05a9eae504ef
diff --git a/packages/edge-config/src/types.ts b/packages/edge-config/src/types.tsindex f2e1084a2b0..74b798c2ec4 100644--- a/packages/edge-config/src/types.ts+++ b/packages/edge-config/src/types.ts@@ -1,8 +1,8 @@import type { BusinessEdgeConfigData } from '@lobechat/business-config/server';/**- * Billboard 单条 item 的可本地化字段。- * cover / linkUrl / 顺序 / 时间窗口不翻译。+ * Localizable fields for a single Billboard item.+ * cover / linkUrl / order / time window are not translated.*/export interface BillboardItemLocaleFields {description?: string;@@ -11,14 +11,14 @@ export interface BillboardItemLocaleFields {}/**- * Billboard 轮播项(Home sidebar 左下角运营卡片的单条内容)+ * Billboard carousel item (a single content entry for the operations card in the bottom-left of the Home sidebar)*/export interface BillboardItem {cover?: string | null;description: string;/**- * 每个 locale 的覆盖文案。缺失时回退到默认字段(title / description / linkLabel)。- * key 采用 LobeHub locale code(如 `zh-CN`、`en-US`、`ja-JP`)。+ * Override copy per locale. Falls back to the default fields (title / description / linkLabel) when missing.+ * Keys use LobeHub locale codes (e.g. `zh-CN`, `en-US`, `ja-JP`).*/i18n?: Record<string, BillboardItemLocaleFields>;id: number;@@ -28,36 +28,36 @@ export interface BillboardItem {}/**- * Billboard 级别的可本地化字段(当前仅 title)。+ * Localizable fields at the Billboard level (currently only title).*/export interface BillboardLocaleFields {title?: string;}/**- * Billboard set(一组 items 在前端轮播)。- * 在 Sprint-style 模型下,每个 env 最多 1 个 set;- * 实际展示还受 startAt / endAt 时间窗口约束。+ * Billboard set (a group of items displayed as a carousel on the frontend).+ * In the Sprint-style model, each env has at most 1 set;+ * actual display is also constrained by the startAt / endAt time window.*/export interface BillboardSet {- /** ISO timestamp — 时间窗口结束,到点后 LobeHub 不再展示 */+ /** ISO timestamp — end of the display time window; LobeHub stops showing after this time */endAt: string;/**- * 按 locale 覆盖 billboard 级别的文案(当前仅 title,用于 ? 菜单)。+ * Override billboard-level copy per locale (currently only title, used for the ? menu).*/i18n?: Record<string, BillboardLocaleFields>;id: number;items: BillboardItem[];- /** 唯一标识符 */+ /** Unique identifier */slug: string;- /** ISO timestamp — 时间窗口开始,未到时 LobeHub 不展示 */+ /** ISO timestamp — start of the display time window; LobeHub does not show before this time */startAt: string;- /** 用于 ? 菜单展示 */+ /** Used for display in the ? menu */title: string;}/**- * Edge Config 中存放的 Billboard 纯内容。Sprint-style 每个 env 只有 1 条或 null。+ * Pure Billboard content stored in Edge Config. In Sprint-style, each env has exactly 1 entry or null.*/export type BillboardSnapshot = BillboardSet | null;@@ -75,8 +75,8 @@ export interface EdgeConfigData extends BusinessEdgeConfigData {assistant_whitelist?: string[];/**- * Billboard snapshot. 每个 Vercel 部署读自己 store 里的 `billboards` key——- * dev 部署指向 dev store,prod 部署指向 prod store,LobeHub 侧无感知。+ * Billboard snapshot. Each Vercel deployment reads the `billboards` key from its own store —+ * dev deployments point to the dev store, prod deployments point to the prod store, transparent to the LobeHub side.*/billboards?: BillboardSnapshot;diff --git a/packages/types/src/serverConfig.ts b/packages/types/src/serverConfig.tsindex b603ffd9ed6..403a66760a5 100644--- a/packages/types/src/serverConfig.ts+++ b/packages/types/src/serverConfig.ts@@ -93,7 +93,7 @@ export interface GlobalBillboardItem {cover?: string | null;description: string;/**- * 按 locale 覆盖的文案。缺失 locale 或 locale 内某字段缺失时回退到默认字段。+ * Override copy per locale. Falls back to the default fields when the locale or a field within it is missing.*/i18n?: Record<string, GlobalBillboardItemLocaleFields>;id: number;@@ -109,7 +109,7 @@ export interface GlobalBillboardLocaleFields {export interface GlobalBillboard {endAt: string;/**- * 按 locale 覆盖 billboard 级别字段(当前仅 title)。缺失时回退到默认 title。+ * Override billboard-level fields per locale (currently only title). Falls back to the default title when missing.*/i18n?: Record<string, GlobalBillboardLocaleFields>;id: number;diff --git a/src/features/Billboard/locale.ts b/src/features/Billboard/locale.tsindex 5428f684477..a8e50d316c8 100644--- a/src/features/Billboard/locale.ts+++ b/src/features/Billboard/locale.ts@@ -12,8 +12,8 @@ export interface ResolvedBillboardItem {}/**- * locale 候选优先级:完整 code(zh-CN) → 基础 code(zh) → 其它共享同基础的 code(zh-HK)→ 默认字段。- * 只命中 i18n 中存在的 key,避免把 undefined 当作有效值覆盖默认。+ * Locale candidate priority: full code (zh-CN) → base code (zh) → other codes sharing the same base (zh-HK) → default fields.+ * Only matches keys that exist in i18n to avoid overriding defaults with undefined values.*/const pickLocaleEntry = <T>(i18n: Record<string, T> | undefined, locale: string): T | undefined => {if (!i18n) return undefined;@@ -41,7 +41,7 @@ export const resolveBillboardItem = (};/**- * 解析 billboard 级别字段(目前只有 title,用于 ? 菜单展示)。+ * Resolve billboard-level fields (currently only title, used for the ? menu display).*/export const resolveBillboardTitle = (billboard: GlobalBillboard, locale: string): string => {const entry = pickLocaleEntry<GlobalBillboardLocaleFields>(billboard.i18n, locale);