Add documents page to the compliance portal

Build the Trust Center documents page: a unified list of published
documents, uploaded files, and audit reports, grouped into category
sections. An All/Public/Private tab bar filters the list by trust
center visibility.

Expose that filter over the trust v1 API by adding a
TrustCenterVisibility enum and a shared TrustCenterVisibilityFilter
input, wiring it through the documents, audits, and trustCenterFiles
connections down to the existing coredata SQL filters. "All" keeps the
default public+private slice; the other tabs pin a single visibility.

Access controls are display-only for now (auth is handled separately):
authorized or public entries open their exported PDF via the export
mutations, requested entries show a pending state, and everything else
shows an inert Get Access affordance.

Add the v2 Tabs and Toaster kit components (Base UI headless) needed by
the page and mount a toast provider at the app root for mutation
feedback.

Signed-off-by: Émile Ré <emile@probo.com>
This commit is contained in:
Émile Ré
2026-07-15 18:33:46 +02:00
parent 3c3276a90b
commit 158861ccdd
41 changed files with 1589 additions and 43 deletions

View File

@@ -16,6 +16,7 @@ type TrustCenter implements Node {
after: CursorKey
last: Int
before: CursorKey
filter: TrustCenterVisibilityFilter
): DocumentConnection! @goField(forceResolver: true)
audits(
@@ -23,6 +24,7 @@ type TrustCenter implements Node {
after: CursorKey
last: Int
before: CursorKey
filter: TrustCenterVisibilityFilter
): AuditConnection! @goField(forceResolver: true)
subprocessors(
@@ -50,6 +52,7 @@ type TrustCenter implements Node {
after: CursorKey
last: Int
before: CursorKey
filter: TrustCenterVisibilityFilter
): TrustCenterFileConnection! @goField(forceResolver: true)
complianceFrameworks(
@@ -95,6 +98,18 @@ enum DocumentType
)
}
enum TrustCenterVisibility
@goModel(model: "go.probo.inc/probo/pkg/coredata.TrustCenterVisibility") {
PRIVATE
@goEnum(value: "go.probo.inc/probo/pkg/coredata.TrustCenterVisibilityPrivate")
PUBLIC
@goEnum(value: "go.probo.inc/probo/pkg/coredata.TrustCenterVisibilityPublic")
}
input TrustCenterVisibilityFilter {
visibility: TrustCenterVisibility
}
type Document implements Node @nda {
id: ID!
title: String!