返回 CodeWhale
page.tsx
根目录 / web / app / [locale] / docs / trust / page.tsx
1 import { DocArticle } from "../_components/doc-article";
2 import { getDocsTrust } from "@/lib/i18n/dictionaries";
3 import { buildPageMetadata, SITE_SECURITY_EMAIL } from "@/lib/page-meta";
4
5 export async function generateMetadata({ params }: { params: Promise<{ locale: string }> }) {
6 const { locale } = await params;
7 const t = getDocsTrust(locale);
8 return buildPageMetadata({
9 path: "/docs/trust",
10 locale,
11 title: t.metaTitle,
12 description: t.metaDescription,
13 });
14 }
15
16 export default async function TrustPage({ params }: { params: Promise<{ locale: string }> }) {
17 const { locale } = await params;
18 return (
19 <DocArticle
20 t={getDocsTrust(locale)}
21 locale={locale}
22 extra={{
23 // The contact is code-owned so every locale reports to the same inbox.
24 report: (
25 <div className="portal-actions">
26 <a className="portal-button portal-button-primary" href={`mailto:${SITE_SECURITY_EMAIL}`}>
27 {SITE_SECURITY_EMAIL}
28 </a>
29 </div>
30 ),
31 }}
32 />
33 );
34 }
35
35 lines Plain Text