SPB Git

Repository Public

LegalPages.tsx 4.4 KB 123 lines tsx

1/**2 * =============================================================================3 *                  SP BOUCHER | SOFTWARE & RESEARCH4 *             ARTIFICIAL INTELLIGENCE • FINANCE • ENGINEERING5 * =============================================================================6 *7 * Project          : agentilab-web8 * File             : components/pages/LegalPages.tsx9 * Module           : User Interface10 * Repository       : https://git.spboucher.ai/agentilab-web11 * Project Website  : Not specified12 * Created          : 2026-12-0513 * Last Modified    : 2026-12-0514 *15 * Author           : Simon-Pierre Boucher16 * Position         : Professor of Finance17 * Institution      : Université du Québec en Outaouais (UQO)18 * Organization     : SP Boucher19 * Website          : https://spboucher.ai20 * Git              : https://git.spboucher.ai21 *22 * Preferred Contact: contact@spboucher.ai23 * Development      : dev@spboucher.ai24 * Support          : support@spboucher.ai25 * Security/Admin   : admin@spboucher.ai26 *27 * Copyright (c) 202628 * Simon-Pierre Boucher29 * All rights reserved where applicable. This file is governed by the30 * applicable project license, copyright notices and relevant law.31 * Existing third-party rights and notices remain unaffected.32 *33 * License          : Proprietary34 *35 * Do not embed credentials, private keys, access tokens,36 * certificates or confidential personal information.37 *38 * =============================================================================39 * END OF SP BOUCHER SOURCE HEADER40 * =============================================================================41 */4243import Link from 'next/link';44import type { Locale } from '@/lib/i18n/config';45import { formatDate } from '@/lib/i18n/config';46import { getCopy } from '@/lib/i18n/copy';47import { href } from '@/lib/i18n/routes';48import { launchGates } from '@/content/public/legal';49import { Notice, Section } from '@/components/ui/primitives';50import { PageHead } from '@/components/marketing/blocks';51import { Shell } from './Shell';5253function Updated({ label, locale }: { label: string; locale: Locale }) {54  return (55    <p className="muted small">56      {label} : <time dateTime={launchGates.legalTextsUpdatedOn}>{formatDate(launchGates.legalTextsUpdatedOn, locale)}</time>57    </p>58  );59}6061function Sections({ sections }: { sections: { heading: string; paragraphs: string[] }[] }) {62  return (63    <>64      {sections.map((section) => (65        <section key={section.heading}>66          <h2>{section.heading}</h2>67          {section.paragraphs.map((paragraph) => (68            <p key={paragraph} style={{ marginTop: 'var(--s4)' }}>69              {paragraph}70            </p>71          ))}72        </section>73      ))}74    </>75  );76}7778export function PrivacyPage({ locale }: { locale: Locale }) {79  const copy = getCopy(locale);80  const t = copy.privacy;81  const officer = launchGates.privacyOfficer;82  return (83    <Shell locale={locale} current="privacy">84      <PageHead id="privacy" locale={locale} eyebrow={t.eyebrow} title={t.title} lead={t.intro} />85      <Section className="section--ruled">86        <div className="prose">87          {launchGates.legalTextsReviewed ? null : <Notice>{copy.labels.preliminary}</Notice>}88          <Updated label={t.updated} locale={locale} />89          <Sections sections={t.sections} />90          <section>91            <h2>{t.officerHeading}</h2>92            <p style={{ marginTop: 'var(--s4)' }}>{officer ? t.officerText(officer.name) : t.officerPending}</p>93            <p style={{ marginTop: 'var(--s4)' }}>94              <Link href={href('contact', locale)}>{copy.nav.contact}</Link>95            </p>96          </section>97          <p className="muted small">{t.disclaimer}</p>98        </div>99      </Section>100    </Shell>101  );102}103104export function LegalPage({ locale }: { locale: Locale }) {105  const copy = getCopy(locale);106  const t = copy.legal;107  return (108    <Shell locale={locale} current="legal">109      <PageHead id="legal" locale={locale} eyebrow={t.eyebrow} title={t.title} />110      <Section className="section--ruled">111        <div className="prose">112          {launchGates.legalTextsReviewed ? null : <Notice>{copy.labels.preliminary}</Notice>}113          <Updated label={t.updated} locale={locale} />114          <Sections sections={t.sections} />115          <p>116            <Link href={href('privacy', locale)}>{copy.privacy.title}</Link>117          </p>118        </div>119      </Section>120    </Shell>121  );122}123
Files main
Menu

Theme