Move trust center profile onto the page

Store website, email, and headquarters on the trust center so
public and admin surfaces read branding from one place. Drop the
trust API organization type and wire console, MCP, CLI, and apps
through the updated schema.

Signed-off-by: Bryan Frimin <bryan@probo.com>
This commit is contained in:
Bryan Frimin
2026-07-13 14:17:22 +02:00
parent ec80798243
commit ba53c94bdc
36 changed files with 167 additions and 155 deletions

View File

@@ -233,7 +233,7 @@ export function OrganizationSidebar({
: (
<div className="size-24 rounded-2xl border border-border-mid shadow-mid bg-level-1" />
)}
<h1 className="text-2xl mt-6">{trustCenter.organization.name}</h1>
<h1 className="text-2xl mt-6">{trustCenter.title}</h1>
<p className="text-sm text-txt-secondary mt-1">
{trustCenter.description}
</p>

View File

@@ -24,7 +24,7 @@ import { TrustCenterContext } from "#/providers/TrustCenterProvider";
export function useTrustCenter(): {
id: string;
organization: { name: string };
title: string;
} {
const context = useContext(TrustCenterContext);
if (!context) {

View File

@@ -47,9 +47,7 @@ export const ndaPageQuery = graphql`
id
}
currentTrustCenter @required(action: THROW) {
organization {
name
}
title
nonDisclosureAgreement {
fileName
fileUrl
@@ -246,7 +244,7 @@ export function NDAPage(props: {
__(
"%s requires you to sign an NDA before accessing compliance documents.",
),
trustCenter.organization.name,
trustCenter.title,
)}
</p>
{isMobile && nda?.fileUrl && (

View File

@@ -107,7 +107,7 @@ export function OverviewPage() {
url={getTrustCenterUrl("documents")}
/>
<Subprocessors
organizationName={trustCenter.organization.name}
title={trustCenter.title}
subprocessors={fragment.subprocessors.edges}
url={getTrustCenterUrl("subprocessors")}
/>
@@ -187,11 +187,11 @@ function Documents({
function Subprocessors({
subprocessors,
url,
organizationName,
title,
}: {
subprocessors: OverviewPageFragment$data["subprocessors"]["edges"];
url: string;
organizationName: string;
title: string;
}) {
const { __ } = useTranslate();
if (subprocessors.length === 0) {
@@ -209,7 +209,7 @@ function Subprocessors({
<p className="text-sm text-txt-secondary mb-4">
{sprintf(
__("Third-party subprocessors %s work with:"),
organizationName,
title,
)}
</p>
<Rows className="mb-8 *:py-5">

View File

@@ -45,7 +45,7 @@ export function SubprocessorsPage({ queryRef }: Props) {
<p className="text-sm text-txt-secondary mb-4">
{sprintf(
__("Third-party subprocessors %s work with:"),
data.currentTrustCenter?.organization.name ?? "",
data.currentTrustCenter?.title ?? "",
)}
</p>
<Rows>

View File

@@ -38,9 +38,7 @@ import { OIDCButton } from "./_components/OIDCButton";
export const connectPageQuery = graphql`
query ConnectPageQuery {
currentTrustCenter @required(action: THROW) {
organization @required(action: THROW) {
name
}
title
}
oidcProviders {
...OIDCButtonFragment
@@ -77,7 +75,7 @@ export function ConnectPage(props: {
const safeContinueUrl = useSafeContinueUrl();
const {
currentTrustCenter: { organization },
currentTrustCenter: { title },
oidcProviders,
} = usePreloadedQuery<ConnectPageQuery>(connectPageQuery, queryRef);
@@ -98,7 +96,7 @@ export function ConnectPage(props: {
};
}, [magicLinkSent]);
usePageTitle(__(`Connect to ${organization.name}'s Compliance Page`));
usePageTitle(__(`Connect to ${title}'s Compliance Page`));
const {
handleSubmit: handleSubmitWrapper,
@@ -164,7 +162,7 @@ export function ConnectPage(props: {
<div className="space-y-6 w-full max-w-md mx-auto pt-8">
<div className="space-y-2 text-center">
<h1 className="text-3xl font-bold">
{__(`Connect to ${organization.name}'s Compliance Page`)}
{__(`Connect to ${title}'s Compliance Page`)}
</h1>
<p className="text-txt-tertiary">
{__(

View File

@@ -31,6 +31,7 @@ export const currentTrustGraphQuery = graphql`
currentTrustCenter @required(action: THROW) {
id
slug
title
description
websiteUrl
email
@@ -54,9 +55,6 @@ export const currentTrustGraphQuery = graphql`
status
}
}
organization {
name
}
customLinks(first: 20) {
edges {
node {
@@ -96,9 +94,7 @@ export const currentTrustDocumentsQuery = graphql`
query TrustGraphCurrentDocumentsQuery {
currentTrustCenter {
id
organization {
name
}
title
documents(first: 50) {
edges {
node {
@@ -125,9 +121,7 @@ export const currentTrustSubprocessorsQuery = graphql`
query TrustGraphCurrentSubprocessorsQuery {
currentTrustCenter {
id
organization {
name
}
title
subprocessors(first: 50) {
edges {
node {