@gradial/aci 0.1.52-rc.9 → 0.1.52
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +126 -0
- package/README.md +86 -5
- package/dist/astro/error-page.js +1 -0
- package/dist/astro/index.js +4 -0
- package/dist/astro/page.d.ts +5 -2
- package/dist/astro/page.js +35 -23
- package/dist/astro/preview.js +2 -17
- package/dist/audience-data-models.d.ts +308 -197
- package/dist/audience-data-models.js +313 -51
- package/dist/cli/compile-registry.mjs +6 -34
- package/dist/cli/mintlify-render.mjs +8 -0
- package/dist/collect/aci.js +1 -1
- package/dist/collect/aci.js.sha256 +1 -1
- package/dist/collect/api.d.ts +6 -7
- package/dist/collect/api.js +21 -8
- package/dist/collect/assignments.d.ts +7 -9
- package/dist/collect/assignments.js +23 -32
- package/dist/collect/batcher.d.ts +9 -7
- package/dist/collect/batcher.js +6 -5
- package/dist/collect/consent/envelope.d.ts +7 -1
- package/dist/collect/consent/envelope.js +3 -1
- package/dist/collect/consent/mapping.d.ts +2 -0
- package/dist/collect/consent/mapping.js +1 -0
- package/dist/collect/consenthold.d.ts +38 -0
- package/dist/collect/consenthold.js +82 -0
- package/dist/collect/declarative.js +7 -5
- package/dist/collect/gapbuffer.d.ts +13 -4
- package/dist/collect/gapbuffer.js +21 -10
- package/dist/collect/index.js +78 -21
- package/dist/collect/pageviews.d.ts +11 -11
- package/dist/collect/pageviews.js +27 -22
- package/dist/consent-banner/index.d.ts +17 -0
- package/dist/consent-banner/index.js +23 -0
- package/dist/content/index.d.ts +2 -1
- package/dist/content/index.js +4 -1
- package/dist/content/provider.d.ts +16 -2
- package/dist/content/provider.js +5 -1
- package/dist/content/resolve-slots.d.ts +24 -2
- package/dist/content/resolve-slots.js +127 -21
- package/dist/content/types.d.ts +5 -1
- package/dist/edge/expression-capabilities.v1.d.ts +106 -0
- package/dist/edge/expression-capabilities.v1.js +165 -0
- package/dist/index.d.ts +1 -2
- package/dist/index.js +0 -1
- package/dist/internal/domain/edge/identity.d.ts +47 -4
- package/dist/internal/domain/edge/identity.js +130 -26
- package/dist/internal/domain/edge/index.d.ts +1 -1
- package/dist/internal/domain/edge/index.js +1 -1
- package/dist/internal/domain/edge/mimic_token.d.ts +14 -0
- package/dist/internal/domain/edge/mimic_token.js +125 -0
- package/dist/internal/domain/edge/personalization-core.d.ts +61 -22
- package/dist/internal/domain/edge/personalization-core.js +790 -200
- package/dist/internal/domain/edge/personalization_index.d.ts +17 -0
- package/dist/internal/domain/edge/personalization_index.js +55 -0
- package/dist/internal/domain/edge/resolve.js +76 -39
- package/dist/internal/domain/edge/testdata/flat_only_validator_v1.d.ts +10 -0
- package/dist/internal/domain/edge/testdata/flat_only_validator_v1.js +253 -0
- package/dist/internal/domain/edge/types.d.ts +82 -78
- package/dist/internal/domain/edge/types.js +3 -3
- package/dist/internal/domain/edge/variant_key.d.ts +4 -0
- package/dist/internal/domain/edge/variant_key.js +56 -0
- package/dist/internal/platform/collectionstore/errors.d.ts +24 -0
- package/dist/internal/platform/collectionstore/errors.js +48 -0
- package/dist/mintlify/blocks.d.ts +6 -0
- package/dist/mintlify/blocks.js +201 -0
- package/dist/mintlify/config.d.ts +3 -0
- package/dist/mintlify/config.js +77 -0
- package/dist/mintlify/index.d.ts +3 -0
- package/dist/mintlify/index.js +2 -0
- package/dist/mintlify/json.d.ts +8 -0
- package/dist/mintlify/json.js +37 -0
- package/dist/mintlify/materialize.d.ts +14 -0
- package/dist/mintlify/materialize.js +254 -0
- package/dist/mintlify/types.d.ts +74 -0
- package/dist/mintlify/types.js +1 -0
- package/dist/mintlify/validate.d.ts +7 -0
- package/dist/mintlify/validate.js +256 -0
- package/dist/next/assignments-navigation.d.ts +4 -0
- package/dist/next/assignments-navigation.js +18 -0
- package/dist/next/assignments-script.d.ts +3 -2
- package/dist/next/assignments-script.js +5 -5
- package/dist/next/error-pages.d.ts +4 -0
- package/dist/next/error-pages.js +4 -0
- package/dist/next/error-seat-payload.d.ts +2 -1
- package/dist/next/error-seat-payload.js +14 -24
- package/dist/next/error-seat.js +7 -2
- package/dist/next/index.d.ts +1 -1
- package/dist/next/index.js +3 -1
- package/dist/next/page.d.ts +2 -1
- package/dist/next/page.js +15 -4
- package/dist/next/release-context.d.ts +30 -0
- package/dist/next/release-context.js +56 -0
- package/dist/next/render.d.ts +1 -1
- package/dist/next/render.js +15 -5
- package/dist/next/server.d.ts +9 -3
- package/dist/next/server.js +17 -32
- package/dist/preview/core.d.ts +1 -0
- package/dist/preview/core.js +27 -0
- package/dist/react/VideoPlayer.d.ts +3 -3
- package/dist/react/index.d.ts +3 -3
- package/dist/registry.d.ts +4 -2
- package/dist/testing/conformance/checks.d.ts +2 -2
- package/dist/testing/conformance/checks.js +2 -0
- package/dist/testing/conformance/index.d.ts +1 -0
- package/dist/testing/conformance/index.js +1 -0
- package/dist/testing/conformance/next-stubs.d.ts +6 -0
- package/dist/testing/conformance/next-stubs.js +9 -0
- package/dist/testing/conformance/preset.d.ts +3 -2
- package/dist/testing/conformance/preset.js +15 -8
- package/dist/testing/conformance/root-identity.d.ts +31 -0
- package/dist/testing/conformance/root-identity.js +361 -0
- package/dist/testing/conformance/stubs/next-image.d.ts +7 -0
- package/dist/testing/conformance/stubs/next-image.js +5 -0
- package/dist/testing/conformance/stubs/next-link.d.ts +7 -0
- package/dist/testing/conformance/stubs/next-link.js +4 -0
- package/dist/testing/conformance/types.d.ts +5 -2
- package/dist/testing/index.d.ts +1 -1
- package/dist/testing/index.js +4 -3
- package/dist/types/block-ref.js +2 -2
- package/dist/types/component.d.ts +9 -0
- package/dist/types/config.d.ts +0 -1
- package/dist/types/index.d.ts +0 -1
- package/dist/types/index.js +0 -1
- package/dist/types/page.d.ts +0 -1
- package/migrations/conformance-registry.md +22 -0
- package/migrations/experiment-goal-ids.md +43 -0
- package/package.json +21 -7
- package/src/cli/compile-registry.mjs +6 -30
- package/src/cli/mintlify-render.mjs +9 -0
- package/src/types/block-ref.test.ts +16 -1
- package/src/types/block-ref.ts +2 -2
- package/src/types/component.ts +10 -0
- package/src/types/config.ts +0 -1
- package/src/types/index.ts +0 -1
- package/src/types/page.ts +0 -1
- package/templates/astro/starter-content/src/components/chrome/Footer.astro +5 -3
- package/templates/astro/starter-content/src/components/chrome/Header.astro +5 -3
- package/templates/astro/starter-content/src/components/elements/Button.astro +5 -2
- package/templates/astro/starter-content/src/components/elements/ButtonBlock.astro +5 -3
- package/templates/astro/starter-content/src/components/sections/ContainerSection.astro +4 -3
- package/templates/astro/starter-content/src/components/sections/FeatureCard.astro +4 -3
- package/templates/astro/starter-content/src/components/sections/FeatureGrid.astro +4 -3
- package/templates/astro/starter-content/src/components/sections/HomeHero.astro +5 -3
- package/templates/astro/starter-content/src/components/sections/PersonalizationChoice.astro +4 -3
- package/templates/astro/starter-content/src/components/sections/StatsBar.astro +4 -3
- package/templates/astro/starter-content/src/fixtures/sections.ts +1 -1
- package/templates/astro/starter-content/src/stories/CompositionStoryFrame.astro +7 -2
- package/templates/astro/template/.aci.yaml.tmpl +0 -1
- package/templates/astro/template/package.json.tmpl +5 -5
- package/templates/astro/template/src/layouts/SiteLayout.astro +2 -2
- package/templates/common/.agents/skills/aci/SKILL.md +58 -1
- package/templates/common/.agents/skills/authoring/SKILL.md +194 -42
- package/templates/common/.agents/skills/authoring/references/block-registry.md +19 -3
- package/templates/common/.agents/skills/authoring/references/contracts.md +9 -30
- package/templates/common/.agents/skills/authoring/references/repo-structure.md +5 -4
- package/templates/common/.agents/skills/authoring/references/sdk-server-functions.md +3 -3
- package/templates/common/.agents/skills/dam-delivery/SKILL.md +216 -0
- package/templates/common/.agents/skills/dam-delivery/references/permalink-grammar.md +167 -0
- package/templates/common/.agents/skills/migration/references/canon-migration.md +18 -67
- package/templates/common/.agents/skills/migration/references/selector-map.md +1 -1
- package/templates/common/.content/fragments/navbar/_index.json +24 -0
- package/templates/common/.content/fragments/site-footer/_index.json +61 -0
- package/templates/common/.content/pages/404/_index.json +4 -2
- package/templates/common/.content/pages/_index.json +0 -1
- package/templates/common/.content/pages/error/_index.json +4 -2
- package/templates/common/.content/schemas/site.schema.json +11 -1
- package/templates/common/.content/templates/error.json +24 -0
- package/templates/common/.content/templates/home.json +28 -0
- package/templates/common/.content/templates/site.json +8 -0
- package/templates/common/.content/templates/standard.json +24 -0
- package/templates/common/.nvmrc +1 -1
- package/templates/common/starter-content/.content/config/site.json +1 -1
- package/templates/common/starter-content/.content/dam/README.md +74 -0
- package/templates/common/starter-content/.content/dam/folders/seed/{ast_site_about_hero → 000000000000000000000000101}/asset.json +1 -1
- package/templates/common/starter-content/.content/dam/folders/seed/{ast_site_home_hero → 000000000000000000000000102}/asset.json +1 -1
- package/templates/common/starter-content/.content/pages/404/_index.json +1 -2
- package/templates/common/starter-content/.content/pages/{home/_index.json → _index.json} +14 -3
- package/templates/common/starter-content/.content/pages/about/_index.json +2 -2
- package/templates/common/starter-content/.content/pages/error/_index.json +1 -2
- package/templates/common/starter-content/.content/patterns/components/button.json +2 -2
- package/templates/common/starter-content/.content/patterns/components/container.json +8 -3
- package/templates/common/starter-content/.content/patterns/components/feature_card.json +2 -2
- package/templates/common/starter-content/.content/patterns/components/feature_grid.json +5 -3
- package/templates/common/starter-content/.content/patterns/components/home_hero.json +2 -2
- package/templates/common/starter-content/.content/patterns/components/personalization_choice.json +2 -2
- package/templates/common/starter-content/.content/patterns/components/site-footer.json +2 -2
- package/templates/common/starter-content/.content/patterns/components/site-navigation.json +2 -2
- package/templates/common/starter-content/.content/patterns/components/stats_bar.json +2 -2
- package/templates/common/starter-content/.content/schemas/site.schema.json +11 -1
- package/templates/nextjs/starter-content/src/components/chrome/Footer.tsx +4 -3
- package/templates/nextjs/starter-content/src/components/chrome/Header.tsx +4 -3
- package/templates/nextjs/starter-content/src/components/elements/Button.tsx +4 -3
- package/templates/nextjs/starter-content/src/components/elements/ButtonBlock.tsx +4 -3
- package/templates/nextjs/starter-content/src/components/sections/ContainerSection.tsx +4 -2
- package/templates/nextjs/starter-content/src/components/sections/FeatureCard.tsx +4 -3
- package/templates/nextjs/starter-content/src/components/sections/FeatureGrid.tsx +4 -2
- package/templates/nextjs/starter-content/src/components/sections/HomeHero.tsx +4 -3
- package/templates/nextjs/starter-content/src/components/sections/PersonalizationChoice.tsx +4 -2
- package/templates/nextjs/starter-content/src/components/sections/StatsBar.tsx +4 -3
- package/templates/nextjs/template/.aci.yaml +0 -1
- package/templates/nextjs/template/.aci.yaml.tmpl +0 -1
- package/templates/nextjs/template/package.json.tmpl +4 -3
- package/templates/nextjs/template/src/app/_components/c15t-bridge.ts +30 -0
- package/templates/nextjs/template/src/app/_components/c15t-consent-ui.tsx +37 -0
- package/templates/nextjs/template/src/app/_components/consent-manager.css +63 -0
- package/templates/nextjs/template/src/app/_components/consent-manager.tsx +76 -0
- package/templates/nextjs/template/src/app/fonts/inter/OFL.txt +93 -0
- package/templates/nextjs/template/src/app/fonts/inter/inter-latin.woff2 +0 -0
- package/templates/nextjs/template/src/app/fonts/space-grotesk/OFL.txt +93 -0
- package/templates/nextjs/template/src/app/fonts/space-grotesk/space-grotesk-latin.woff2 +0 -0
- package/templates/nextjs/template/src/app/layout.tsx +12 -7
- package/templates/nextjs/template/tests/conformance.test.ts.tmpl +1 -0
- package/dist/define-layout.d.ts +0 -6
- package/dist/define-layout.js +0 -14
- package/dist/edge/personalization-core.d.ts +0 -11
- package/dist/edge/personalization-core.js +0 -269
- package/dist/internal/domain/edge/compose.d.ts +0 -24
- package/dist/internal/domain/edge/compose.js +0 -89
- package/dist/internal/domain/edge/record/codec.d.ts +0 -71
- package/dist/internal/domain/edge/record/codec.js +0 -401
- package/dist/next/collect-route.d.ts +0 -19
- package/dist/next/collect-route.js +0 -459
- package/dist/next/edge-config.d.ts +0 -1
- package/dist/next/edge-config.js +0 -92
- package/dist/next/envelope-digest.d.ts +0 -21
- package/dist/next/envelope-digest.js +0 -58
- package/dist/next/middleware.d.ts +0 -40
- package/dist/next/middleware.js +0 -475
- package/dist/next/personalization-host.d.ts +0 -134
- package/dist/next/personalization-host.js +0 -270
- package/dist/next/root-layout.d.ts +0 -4
- package/dist/next/root-layout.js +0 -5
- package/dist/next/vercel-collect-sdk-route.d.ts +0 -27
- package/dist/next/vercel-collect-sdk-route.js +0 -181
- package/dist/next/vercel-edge-projection-v1.d.ts +0 -24
- package/dist/next/vercel-edge-projection-v1.js +0 -880
- package/dist/next/vercel-personalization.d.ts +0 -4
- package/dist/next/vercel-personalization.js +0 -4
- package/dist/next/vercel-s3-personalization.d.ts +0 -79
- package/dist/next/vercel-s3-personalization.js +0 -570
- package/dist/types/layout.d.ts +0 -24
- package/src/types/layout.ts +0 -29
- package/templates/astro/starter-content/src/render/RenderPage.astro +0 -67
- package/templates/astro/template/src/cms/contracts/layouts/index.ts +0 -18
- package/templates/common/starter-content/.content/patterns/layouts/default.json +0 -14
- package/templates/nextjs/starter-content/src/components/elements/AtomicBlock.tsx +0 -13
- package/templates/nextjs/template/src/cms/contracts/layouts/index.ts +0 -16
- /package/dist/{types/layout.js → cli/mintlify-render.d.mts} +0 -0
- /package/templates/common/starter-content/.content/dam/folders/seed/{ast_site_home_hero → 000000000000000000000000101}/editorial.json +0 -0
- /package/templates/common/starter-content/.content/dam/folders/seed/{ast_site_about_hero → 000000000000000000000000101}/governance.json +0 -0
- /package/templates/common/starter-content/.content/dam/folders/seed/{ast_site_home_hero → 000000000000000000000000101}/versions/v0001.json +0 -0
- /package/templates/common/starter-content/.content/dam/folders/seed/{ast_site_about_hero → 000000000000000000000000102}/editorial.json +0 -0
- /package/templates/common/starter-content/.content/dam/folders/seed/{ast_site_home_hero → 000000000000000000000000102}/governance.json +0 -0
- /package/templates/common/starter-content/.content/dam/folders/seed/{ast_site_about_hero → 000000000000000000000000102}/versions/v0001.json +0 -0
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
import { Button } from '@/components/elements/Button';
|
|
2
2
|
import { Container } from '@/components/elements/Container';
|
|
3
|
-
import { primaryImageSource } from '@gradial/aci';
|
|
3
|
+
import { primaryImageSource, type RootIdentityProps } from '@gradial/aci';
|
|
4
4
|
import type { ContentProps } from '@/cms/contracts/components/homeHero.contract';
|
|
5
5
|
|
|
6
6
|
type HeroImage = NonNullable<ContentProps['image']>;
|
|
7
7
|
|
|
8
|
-
export type HomeHeroProps = Omit<ContentProps, 'image'> & { image?: HeroImage };
|
|
8
|
+
export type HomeHeroProps = Omit<ContentProps, 'image'> & { image?: HeroImage } & RootIdentityProps;
|
|
9
9
|
|
|
10
|
-
export function HomeHero({ eyebrow = '', headline = '', description = '', ctaLabel = '', ctaHref = '#', image }: HomeHeroProps) {
|
|
10
|
+
export function HomeHero({ eyebrow = '', headline = '', description = '', ctaLabel = '', ctaHref = '#', image, ...root }: HomeHeroProps) {
|
|
11
11
|
const imageSrc = heroImageSrc(image);
|
|
12
12
|
const imageAlt = image?.alt || headline;
|
|
13
13
|
|
|
14
14
|
return (
|
|
15
15
|
<section
|
|
16
|
+
{...root}
|
|
16
17
|
className="theme-light relative flex min-h-[var(--height-hero-min)] items-center bg-cover bg-center"
|
|
17
18
|
aria-label={imageAlt}
|
|
18
19
|
style={{
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
3
|
import { useEffect, useState } from 'react';
|
|
4
|
+
import type { RootIdentityProps } from '@gradial/aci';
|
|
4
5
|
import type { ContentProps } from '@/cms/contracts/components/personalizationChoice.contract';
|
|
5
6
|
|
|
6
7
|
type AciWindow = Window & { aci?: (command: string, value: unknown) => void };
|
|
@@ -15,7 +16,8 @@ export function PersonalizationChoice({
|
|
|
15
16
|
redLabel,
|
|
16
17
|
blueLabel,
|
|
17
18
|
refreshLabel,
|
|
18
|
-
|
|
19
|
+
...root
|
|
20
|
+
}: ContentProps & RootIdentityProps) {
|
|
19
21
|
const [consent, setConsent] = useState(false);
|
|
20
22
|
const [marker, setMarker] = useState(false);
|
|
21
23
|
|
|
@@ -30,7 +32,7 @@ export function PersonalizationChoice({
|
|
|
30
32
|
}, []);
|
|
31
33
|
|
|
32
34
|
return (
|
|
33
|
-
<section className="border-y border-[var(--color-border)] bg-[var(--color-surface)] py-[var(--spacing-section-y)]">
|
|
35
|
+
<section className="border-y border-[var(--color-border)] bg-[var(--color-surface)] py-[var(--spacing-section-y)]" {...root}>
|
|
34
36
|
<div className="mx-auto max-w-[var(--layout-content-max)] px-[var(--layout-gutter)] text-center">
|
|
35
37
|
<h2 className="text-[length:var(--text-h2)] font-[var(--font-weight-semibold)] text-[var(--color-fg)]">{title}</h2>
|
|
36
38
|
{description ? <p className="mx-auto mt-3 max-w-2xl text-[var(--color-fg-muted)]">{description}</p> : null}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { Container } from '@/components/elements/Container';
|
|
2
|
+
import type { RootIdentityProps } from '@gradial/aci';
|
|
2
3
|
import type { ContentProps } from '@/cms/contracts/components/statsBar.contract';
|
|
3
4
|
|
|
4
|
-
export type StatsBarProps = ContentProps;
|
|
5
|
+
export type StatsBarProps = ContentProps & RootIdentityProps;
|
|
5
6
|
|
|
6
|
-
export function StatsBar({ stats = [] }: StatsBarProps) {
|
|
7
|
+
export function StatsBar({ stats = [], ...root }: StatsBarProps) {
|
|
7
8
|
return (
|
|
8
|
-
<section className="theme-light relative border-y border-[var(--color-border-default)] bg-[var(--color-surface-100)] py-[var(--spacing-section-y)]">
|
|
9
|
+
<section {...root} className="theme-light relative border-y border-[var(--color-border-default)] bg-[var(--color-surface-100)] py-[var(--spacing-section-y)]">
|
|
9
10
|
<div className="pointer-events-none absolute inset-0 bg-[image:var(--gradient-hero-base)] opacity-40" />
|
|
10
11
|
<Container className="relative">
|
|
11
12
|
<div className="grid gap-10 sm:grid-cols-2 lg:grid-cols-4">
|
|
@@ -15,12 +15,13 @@
|
|
|
15
15
|
"build:storybook": "storybook build"
|
|
16
16
|
},
|
|
17
17
|
"engines": {
|
|
18
|
-
"node": ">=
|
|
18
|
+
"node": ">=24",
|
|
19
19
|
"npm": ">=10"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
+
"@c15t/nextjs": "^2.2.1",
|
|
22
23
|
"@gradial/aci": "{{aciVersion}}",
|
|
23
|
-
"next": "
|
|
24
|
+
"next": "15.5.24",
|
|
24
25
|
"react": "^19.0.0",
|
|
25
26
|
"react-dom": "^19.0.0"
|
|
26
27
|
},
|
|
@@ -31,7 +32,7 @@
|
|
|
31
32
|
"@eslint/compat": "^1.2.0",
|
|
32
33
|
"@eslint/eslintrc": "^3.2.0",
|
|
33
34
|
"eslint": "^9.18.0",
|
|
34
|
-
"eslint-config-next": "
|
|
35
|
+
"eslint-config-next": "15.5.24",
|
|
35
36
|
"eslint-plugin-import": "^2.29.1",
|
|
36
37
|
"tailwindcss": "^4.2.4",
|
|
37
38
|
"@tailwindcss/postcss": "^4.2.4",
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export type Consents = Record<string, boolean>;
|
|
2
|
+
export type ConsentListener = (payload: { consents: Consents }) => void;
|
|
3
|
+
|
|
4
|
+
export interface C15tBridgeTarget {
|
|
5
|
+
c15t?: {
|
|
6
|
+
consents?: Consents;
|
|
7
|
+
onConsentChange?: (listener: ConsentListener) => void;
|
|
8
|
+
};
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
const listenersByTarget = new WeakMap<object, Set<ConsentListener>>();
|
|
12
|
+
|
|
13
|
+
// Install the discovery/subscription surface immediately. Consent values stay
|
|
14
|
+
// absent until publish is called with a real visitor decision, but a collector
|
|
15
|
+
// that subscribes before that decision remains connected indefinitely.
|
|
16
|
+
export function installC15tBridge(target: C15tBridgeTarget): (consents: Consents) => void {
|
|
17
|
+
let listeners = listenersByTarget.get(target);
|
|
18
|
+
if (!listeners) {
|
|
19
|
+
listeners = new Set<ConsentListener>();
|
|
20
|
+
listenersByTarget.set(target, listeners);
|
|
21
|
+
}
|
|
22
|
+
const bridge = (target.c15t ??= {});
|
|
23
|
+
bridge.onConsentChange ??= (listener) => {
|
|
24
|
+
listeners.add(listener);
|
|
25
|
+
};
|
|
26
|
+
return (consents) => {
|
|
27
|
+
bridge.consents = consents;
|
|
28
|
+
for (const listener of [...listeners]) listener({ consents });
|
|
29
|
+
};
|
|
30
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
// Themed c15t UI, loaded lazily via next/dynamic from consent-manager.tsx.
|
|
4
|
+
// Keeping the provider, banner, dialog, and their stylesheet in this separate
|
|
5
|
+
// chunk keeps them out of the self-contained error pages (REQ-14's 150 KiB
|
|
6
|
+
// budget) — error routes share the root layout but never carry the collect
|
|
7
|
+
// tag, so this chunk is never loaded there.
|
|
8
|
+
|
|
9
|
+
import {
|
|
10
|
+
ConsentBanner,
|
|
11
|
+
ConsentDialog,
|
|
12
|
+
ConsentManagerProvider,
|
|
13
|
+
} from '@c15t/nextjs';
|
|
14
|
+
import './consent-manager.css';
|
|
15
|
+
|
|
16
|
+
export default function C15tConsentUI() {
|
|
17
|
+
const backendURL = process.env.NEXT_PUBLIC_C15T_BACKEND_URL;
|
|
18
|
+
return (
|
|
19
|
+
<ConsentManagerProvider
|
|
20
|
+
options={
|
|
21
|
+
backendURL
|
|
22
|
+
? {
|
|
23
|
+
mode: 'hosted',
|
|
24
|
+
backendURL,
|
|
25
|
+
consentCategories: ['necessary', 'measurement', 'marketing'],
|
|
26
|
+
}
|
|
27
|
+
: {
|
|
28
|
+
mode: 'offline',
|
|
29
|
+
consentCategories: ['necessary', 'measurement', 'marketing'],
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
>
|
|
33
|
+
<ConsentBanner />
|
|
34
|
+
<ConsentDialog />
|
|
35
|
+
</ConsentManagerProvider>
|
|
36
|
+
);
|
|
37
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
@import "@c15t/nextjs/styles.css";
|
|
2
|
+
|
|
3
|
+
/* c15t consent surfaces (banner + dialog) mapped onto Meridian tokens.
|
|
4
|
+
* `:root:root` because ConsentManagerProvider injects <style id="c15t-theme">
|
|
5
|
+
* with c15t's defaults on `:root` into <body> at runtime — after the head
|
|
6
|
+
* stylesheet — so a plain `:root` rule here would lose on source order.
|
|
7
|
+
* c15t's `-dark` component variables reference the same base tokens, so both
|
|
8
|
+
* color schemes stay on the Meridian light palette. */
|
|
9
|
+
:root:root {
|
|
10
|
+
/* Typography — Inter everywhere, on the Meridian scale. */
|
|
11
|
+
--c15t-font-family: var(--font-family-base);
|
|
12
|
+
--c15t-font-size-xs: var(--text-size-caption);
|
|
13
|
+
--c15t-font-size-sm: var(--text-size-body-small);
|
|
14
|
+
--c15t-font-size-md: var(--text-size-body);
|
|
15
|
+
--c15t-font-size-base: var(--text-size-body);
|
|
16
|
+
--c15t-font-size-lg: var(--text-size-body-large);
|
|
17
|
+
--c15t-font-weight-normal: var(--font-weight-regular);
|
|
18
|
+
--c15t-font-weight-regular: var(--font-weight-regular);
|
|
19
|
+
--c15t-font-weight-medium: var(--font-weight-medium);
|
|
20
|
+
--c15t-font-weight-semibold: var(--font-weight-semibold);
|
|
21
|
+
--c15t-line-height-tight: var(--leading-snug);
|
|
22
|
+
--c15t-line-height-normal: var(--leading-body);
|
|
23
|
+
--c15t-line-height-relaxed: var(--leading-relaxed);
|
|
24
|
+
|
|
25
|
+
/* Color — Meridian palette. */
|
|
26
|
+
--c15t-primary: var(--color-accent-primary);
|
|
27
|
+
--c15t-primary-hover: var(--color-brand-500);
|
|
28
|
+
--c15t-surface: var(--color-white);
|
|
29
|
+
--c15t-surface-hover: var(--color-surface-100);
|
|
30
|
+
--c15t-border: var(--color-border-default);
|
|
31
|
+
--c15t-text: var(--color-text-primary);
|
|
32
|
+
--c15t-text-muted: var(--color-text-secondary);
|
|
33
|
+
--c15t-text-on-primary: var(--color-white);
|
|
34
|
+
--c15t-overlay: color-mix(in srgb, var(--color-surface-900) 45%, transparent);
|
|
35
|
+
--c15t-switch-track: var(--color-surface-300);
|
|
36
|
+
--c15t-switch-track-active: var(--color-accent-primary);
|
|
37
|
+
--c15t-switch-thumb: var(--color-white);
|
|
38
|
+
|
|
39
|
+
/* Shape + depth — Meridian card treatment. */
|
|
40
|
+
--c15t-radius-md: var(--radius-button);
|
|
41
|
+
--c15t-radius-lg: var(--radius-card);
|
|
42
|
+
--c15t-shadow-md: var(--shadow-card);
|
|
43
|
+
--c15t-shadow-lg: var(--shadow-elevated);
|
|
44
|
+
|
|
45
|
+
/* c15t hardcodes these component values instead of deriving them from the
|
|
46
|
+
* base tokens; re-point the ones the banner + dialog actually render. */
|
|
47
|
+
--legal-links-color: var(--color-accent-primary);
|
|
48
|
+
--legal-links-focus-color: var(--color-accent-primary);
|
|
49
|
+
--legal-links-focus-color-dark: var(--color-accent-primary);
|
|
50
|
+
--consent-dialog-card-shadow: var(--shadow-elevated);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/* Stack the banner/dialog action buttons on narrow viewports. c15t only
|
|
54
|
+
* stacks via its `direction: column` config; the default row layout squeezes
|
|
55
|
+
* 2–3 buttons onto a phone. The attribute selectors match c15t's stable
|
|
56
|
+
* class-name prefixes (the hashed suffixes change between c15t releases). */
|
|
57
|
+
@media (width < 640px) {
|
|
58
|
+
[class*="c15t-ui-footer-"],
|
|
59
|
+
[class*="c15t-ui-footerSubGroup-"] {
|
|
60
|
+
flex-direction: column;
|
|
61
|
+
width: 100%;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
// c15t consent manager (personalization-onboarding ANTI-3: CMP-less sites are
|
|
4
|
+
// pointed at c15t via the starter kits). Offline mode by default; set
|
|
5
|
+
// NEXT_PUBLIC_C15T_BACKEND_URL to use a hosted or self-hosted c15t backend.
|
|
6
|
+
//
|
|
7
|
+
// The component gates itself on the collect tag in the document: the tag is
|
|
8
|
+
// the only per-site configuration surface, emitted by createPage from the
|
|
9
|
+
// site config's personalization block, so the consent surface appears exactly
|
|
10
|
+
// when the tag says data-aci-consent="c15t" — and never on pages without the
|
|
11
|
+
// tag (error pages, custom routes). This keeps the root layout free of
|
|
12
|
+
// server-side config loading.
|
|
13
|
+
//
|
|
14
|
+
// The ACI collect SDK's c15t preset reads window.c15t = { consents,
|
|
15
|
+
// onConsentChange }, but c15t publishes its store as window.c15tStore. The
|
|
16
|
+
// bridge below exposes the subscription shape immediately, while publishing
|
|
17
|
+
// consent values only after a real visitor decision (consentInfo set), so
|
|
18
|
+
// pre-decision defaults never read as a withdrawal.
|
|
19
|
+
|
|
20
|
+
import dynamic from 'next/dynamic';
|
|
21
|
+
import { useEffect, useState } from 'react';
|
|
22
|
+
import { installC15tBridge, type Consents } from './c15t-bridge';
|
|
23
|
+
|
|
24
|
+
// Lazy so the c15t bundle + stylesheet stay out of the self-contained error
|
|
25
|
+
// pages (REQ-14 budget): those routes never carry the collect tag, so this
|
|
26
|
+
// chunk is never requested there.
|
|
27
|
+
const C15tConsentUI = dynamic(() => import('./c15t-consent-ui'), {
|
|
28
|
+
ssr: false,
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
interface ConsentStoreState {
|
|
32
|
+
consents?: Consents;
|
|
33
|
+
consentInfo?: unknown;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
interface ConsentStoreLike {
|
|
37
|
+
getState(): ConsentStoreState;
|
|
38
|
+
subscribe(listener: (state: ConsentStoreState) => void): () => void;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export function ConsentManager() {
|
|
42
|
+
const [enabled, setEnabled] = useState(false);
|
|
43
|
+
|
|
44
|
+
useEffect(() => {
|
|
45
|
+
const tag = document.querySelector('script[data-aci-consent]');
|
|
46
|
+
setEnabled(tag?.getAttribute('data-aci-consent') === 'c15t');
|
|
47
|
+
}, []);
|
|
48
|
+
|
|
49
|
+
useEffect(() => {
|
|
50
|
+
if (!enabled) return;
|
|
51
|
+
const w = window as typeof window & {
|
|
52
|
+
c15t?: { consents?: Consents; onConsentChange?: (cb: (payload: { consents: Consents }) => void) => void };
|
|
53
|
+
c15tStore?: ConsentStoreLike;
|
|
54
|
+
};
|
|
55
|
+
const publish = installC15tBridge(w);
|
|
56
|
+
const onState = (state: ConsentStoreState): void => {
|
|
57
|
+
if (state.consentInfo && state.consents) publish(state.consents);
|
|
58
|
+
};
|
|
59
|
+
let unsubscribe: (() => void) | undefined;
|
|
60
|
+
let remaining = 40; // same bounded poll the collect SDK uses for window.c15t
|
|
61
|
+
const poll = (): void => {
|
|
62
|
+
if (w.c15tStore) {
|
|
63
|
+
onState(w.c15tStore.getState());
|
|
64
|
+
unsubscribe = w.c15tStore.subscribe(onState);
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
remaining -= 1;
|
|
68
|
+
if (remaining > 0) window.setTimeout(poll, 250);
|
|
69
|
+
};
|
|
70
|
+
poll();
|
|
71
|
+
return () => unsubscribe?.();
|
|
72
|
+
}, [enabled]);
|
|
73
|
+
|
|
74
|
+
if (!enabled) return null;
|
|
75
|
+
return <C15tConsentUI />;
|
|
76
|
+
}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
Copyright 2020 The Inter Project Authors (https://github.com/rsms/inter)
|
|
2
|
+
|
|
3
|
+
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
|
4
|
+
This license is copied below, and is also available with a FAQ at:
|
|
5
|
+
https://scripts.sil.org/OFL
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
-----------------------------------------------------------
|
|
9
|
+
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
|
10
|
+
-----------------------------------------------------------
|
|
11
|
+
|
|
12
|
+
PREAMBLE
|
|
13
|
+
The goals of the Open Font License (OFL) are to stimulate worldwide
|
|
14
|
+
development of collaborative font projects, to support the font creation
|
|
15
|
+
efforts of academic and linguistic communities, and to provide a free and
|
|
16
|
+
open framework in which fonts may be shared and improved in partnership
|
|
17
|
+
with others.
|
|
18
|
+
|
|
19
|
+
The OFL allows the licensed fonts to be used, studied, modified and
|
|
20
|
+
redistributed freely as long as they are not sold by themselves. The
|
|
21
|
+
fonts, including any derivative works, can be bundled, embedded,
|
|
22
|
+
redistributed and/or sold with any software provided that any reserved
|
|
23
|
+
names are not used by derivative works. The fonts and derivatives,
|
|
24
|
+
however, cannot be released under any other type of license. The
|
|
25
|
+
requirement for fonts to remain under this license does not apply
|
|
26
|
+
to any document created using the fonts or their derivatives.
|
|
27
|
+
|
|
28
|
+
DEFINITIONS
|
|
29
|
+
"Font Software" refers to the set of files released by the Copyright
|
|
30
|
+
Holder(s) under this license and clearly marked as such. This may
|
|
31
|
+
include source files, build scripts and documentation.
|
|
32
|
+
|
|
33
|
+
"Reserved Font Name" refers to any names specified as such after the
|
|
34
|
+
copyright statement(s).
|
|
35
|
+
|
|
36
|
+
"Original Version" refers to the collection of Font Software components as
|
|
37
|
+
distributed by the Copyright Holder(s).
|
|
38
|
+
|
|
39
|
+
"Modified Version" refers to any derivative made by adding to, deleting,
|
|
40
|
+
or substituting -- in part or in whole -- any of the components of the
|
|
41
|
+
Original Version, by changing formats or by porting the Font Software to a
|
|
42
|
+
new environment.
|
|
43
|
+
|
|
44
|
+
"Author" refers to any designer, engineer, programmer, technical
|
|
45
|
+
writer or other person who contributed to the Font Software.
|
|
46
|
+
|
|
47
|
+
PERMISSION & CONDITIONS
|
|
48
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
49
|
+
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
|
50
|
+
redistribute, and sell modified and unmodified copies of the Font
|
|
51
|
+
Software, subject to the following conditions:
|
|
52
|
+
|
|
53
|
+
1) Neither the Font Software nor any of its individual components,
|
|
54
|
+
in Original or Modified Versions, may be sold by itself.
|
|
55
|
+
|
|
56
|
+
2) Original or Modified Versions of the Font Software may be bundled,
|
|
57
|
+
redistributed and/or sold with any software, provided that each copy
|
|
58
|
+
contains the above copyright notice and this license. These can be
|
|
59
|
+
included either as stand-alone text files, human-readable headers or
|
|
60
|
+
in the appropriate machine-readable metadata fields within text or
|
|
61
|
+
binary files as long as those fields can be easily viewed by the user.
|
|
62
|
+
|
|
63
|
+
3) No Modified Version of the Font Software may use the Reserved Font
|
|
64
|
+
Name(s) unless explicit written permission is granted by the corresponding
|
|
65
|
+
Copyright Holder. This restriction only applies to the primary font name as
|
|
66
|
+
presented to the users.
|
|
67
|
+
|
|
68
|
+
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
|
69
|
+
Software shall not be used to promote, endorse or advertise any
|
|
70
|
+
Modified Version, except to acknowledge the contribution(s) of the
|
|
71
|
+
Copyright Holder(s) and the Author(s) or with their explicit written
|
|
72
|
+
permission.
|
|
73
|
+
|
|
74
|
+
5) The Font Software, modified or unmodified, in part or in whole,
|
|
75
|
+
must be distributed entirely under this license, and must not be
|
|
76
|
+
distributed under any other license. The requirement for fonts to
|
|
77
|
+
remain under this license does not apply to any document created
|
|
78
|
+
using the Font Software.
|
|
79
|
+
|
|
80
|
+
TERMINATION
|
|
81
|
+
This license becomes null and void if any of the above conditions are
|
|
82
|
+
not met.
|
|
83
|
+
|
|
84
|
+
DISCLAIMER
|
|
85
|
+
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
86
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
|
87
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
|
88
|
+
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
|
89
|
+
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
90
|
+
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
|
91
|
+
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
92
|
+
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
|
93
|
+
OTHER DEALINGS IN THE FONT SOFTWARE.
|
|
Binary file
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
Copyright 2020 The Space Grotesk Project Authors (https://github.com/floriankarsten/space-grotesk)
|
|
2
|
+
|
|
3
|
+
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
|
4
|
+
This license is copied below, and is also available with a FAQ at:
|
|
5
|
+
http://scripts.sil.org/OFL
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
-----------------------------------------------------------
|
|
9
|
+
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
|
10
|
+
-----------------------------------------------------------
|
|
11
|
+
|
|
12
|
+
PREAMBLE
|
|
13
|
+
The goals of the Open Font License (OFL) are to stimulate worldwide
|
|
14
|
+
development of collaborative font projects, to support the font creation
|
|
15
|
+
efforts of academic and linguistic communities, and to provide a free and
|
|
16
|
+
open framework in which fonts may be shared and improved in partnership
|
|
17
|
+
with others.
|
|
18
|
+
|
|
19
|
+
The OFL allows the licensed fonts to be used, studied, modified and
|
|
20
|
+
redistributed freely as long as they are not sold by themselves. The
|
|
21
|
+
fonts, including any derivative works, can be bundled, embedded,
|
|
22
|
+
redistributed and/or sold with any software provided that any reserved
|
|
23
|
+
names are not used by derivative works. The fonts and derivatives,
|
|
24
|
+
however, cannot be released under any other type of license. The
|
|
25
|
+
requirement for fonts to remain under this license does not apply
|
|
26
|
+
to any document created using the fonts or their derivatives.
|
|
27
|
+
|
|
28
|
+
DEFINITIONS
|
|
29
|
+
"Font Software" refers to the set of files released by the Copyright
|
|
30
|
+
Holder(s) under this license and clearly marked as such. This may
|
|
31
|
+
include source files, build scripts and documentation.
|
|
32
|
+
|
|
33
|
+
"Reserved Font Name" refers to any names specified as such after the
|
|
34
|
+
copyright statement(s).
|
|
35
|
+
|
|
36
|
+
"Original Version" refers to the collection of Font Software components as
|
|
37
|
+
distributed by the Copyright Holder(s).
|
|
38
|
+
|
|
39
|
+
"Modified Version" refers to any derivative made by adding to, deleting,
|
|
40
|
+
or substituting -- in part or in whole -- any of the components of the
|
|
41
|
+
Original Version, by changing formats or by porting the Font Software to a
|
|
42
|
+
new environment.
|
|
43
|
+
|
|
44
|
+
"Author" refers to any designer, engineer, programmer, technical
|
|
45
|
+
writer or other person who contributed to the Font Software.
|
|
46
|
+
|
|
47
|
+
PERMISSION & CONDITIONS
|
|
48
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
49
|
+
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
|
50
|
+
redistribute, and sell modified and unmodified copies of the Font
|
|
51
|
+
Software, subject to the following conditions:
|
|
52
|
+
|
|
53
|
+
1) Neither the Font Software nor any of its individual components,
|
|
54
|
+
in Original or Modified Versions, may be sold by itself.
|
|
55
|
+
|
|
56
|
+
2) Original or Modified Versions of the Font Software may be bundled,
|
|
57
|
+
redistributed and/or sold with any software, provided that each copy
|
|
58
|
+
contains the above copyright notice and this license. These can be
|
|
59
|
+
included either as stand-alone text files, human-readable headers or
|
|
60
|
+
in the appropriate machine-readable metadata fields within text or
|
|
61
|
+
binary files as long as those fields can be easily viewed by the user.
|
|
62
|
+
|
|
63
|
+
3) No Modified Version of the Font Software may use the Reserved Font
|
|
64
|
+
Name(s) unless explicit written permission is granted by the corresponding
|
|
65
|
+
Copyright Holder. This restriction only applies to the primary font name as
|
|
66
|
+
presented to the users.
|
|
67
|
+
|
|
68
|
+
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
|
69
|
+
Software shall not be used to promote, endorse or advertise any
|
|
70
|
+
Modified Version, except to acknowledge the contribution(s) of the
|
|
71
|
+
Copyright Holder(s) and the Author(s) or with their explicit written
|
|
72
|
+
permission.
|
|
73
|
+
|
|
74
|
+
5) The Font Software, modified or unmodified, in part or in whole,
|
|
75
|
+
must be distributed entirely under this license, and must not be
|
|
76
|
+
distributed under any other license. The requirement for fonts to
|
|
77
|
+
remain under this license does not apply to any document created
|
|
78
|
+
using the Font Software.
|
|
79
|
+
|
|
80
|
+
TERMINATION
|
|
81
|
+
This license becomes null and void if any of the above conditions are
|
|
82
|
+
not met.
|
|
83
|
+
|
|
84
|
+
DISCLAIMER
|
|
85
|
+
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
86
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
|
87
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
|
88
|
+
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
|
89
|
+
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
90
|
+
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
|
91
|
+
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
92
|
+
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
|
93
|
+
OTHER DEALINGS IN THE FONT SOFTWARE.
|
|
Binary file
|
|
@@ -1,20 +1,24 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
|
-
import
|
|
2
|
+
import localFont from 'next/font/local';
|
|
3
3
|
import { DevRefresh } from '@gradial/aci/next';
|
|
4
|
+
import { ConsentManager } from './_components/consent-manager';
|
|
4
5
|
import '@/design-system/styles.css';
|
|
5
6
|
|
|
6
|
-
|
|
7
|
-
|
|
7
|
+
// Fonts ship with the site so `next build` never fetches from Google Fonts.
|
|
8
|
+
// Each file is the Google Fonts latin-subset variable woff2 (one file covers
|
|
9
|
+
// weights 400-700); the SIL OFL 1.1 license sits beside it.
|
|
10
|
+
const inter = localFont({
|
|
11
|
+
src: './fonts/inter/inter-latin.woff2',
|
|
8
12
|
variable: '--font-inter',
|
|
9
13
|
display: 'swap',
|
|
10
|
-
weight:
|
|
14
|
+
weight: '400 700',
|
|
11
15
|
});
|
|
12
16
|
|
|
13
|
-
const spaceGrotesk =
|
|
14
|
-
|
|
17
|
+
const spaceGrotesk = localFont({
|
|
18
|
+
src: './fonts/space-grotesk/space-grotesk-latin.woff2',
|
|
15
19
|
variable: '--font-space-grotesk',
|
|
16
20
|
display: 'swap',
|
|
17
|
-
weight:
|
|
21
|
+
weight: '400 700',
|
|
18
22
|
});
|
|
19
23
|
|
|
20
24
|
export default function Layout({ children }: { children: ReactNode }) {
|
|
@@ -22,6 +26,7 @@ export default function Layout({ children }: { children: ReactNode }) {
|
|
|
22
26
|
<html lang="en" className={`${inter.variable} ${spaceGrotesk.variable}`}>
|
|
23
27
|
<body>
|
|
24
28
|
{children}
|
|
29
|
+
<ConsentManager />
|
|
25
30
|
<DevRefresh />
|
|
26
31
|
</body>
|
|
27
32
|
</html>
|
package/dist/define-layout.d.ts
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { LayoutContract, LayoutDefinition, LayoutSlot } from './types/layout.js';
|
|
2
|
-
import type { FragmentRefNode } from './types/page.js';
|
|
3
|
-
export declare function defineLayout(definition: LayoutDefinition): LayoutContract;
|
|
4
|
-
export declare const defineLayoutContract: typeof defineLayout;
|
|
5
|
-
export declare function slot(name: string, required?: boolean): LayoutSlot;
|
|
6
|
-
export declare function fragmentDefault(fragmentId: string): FragmentRefNode;
|
package/dist/define-layout.js
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
export function defineLayout(definition) {
|
|
2
|
-
return {
|
|
3
|
-
name: definition.name,
|
|
4
|
-
slots: definition.slots,
|
|
5
|
-
defaults: definition.defaults,
|
|
6
|
-
};
|
|
7
|
-
}
|
|
8
|
-
export const defineLayoutContract = defineLayout;
|
|
9
|
-
export function slot(name, required = false) {
|
|
10
|
-
return { name, required };
|
|
11
|
-
}
|
|
12
|
-
export function fragmentDefault(fragmentId) {
|
|
13
|
-
return { kind: 'fragment-ref', fragmentId, inline: true };
|
|
14
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export function selectPersonalizationVariant(request: any, route: any, claims: any, experiments: any, identity: any): any;
|
|
2
|
-
export function resolvePersonalizationDecision(request: any, route: any, claims: any, experiments: any, identity: any): {
|
|
3
|
-
variant: any;
|
|
4
|
-
experiment: {
|
|
5
|
-
experimentId: any;
|
|
6
|
-
armId: any;
|
|
7
|
-
allocationVersion: string;
|
|
8
|
-
variantKey: any;
|
|
9
|
-
bucket: number;
|
|
10
|
-
} | null;
|
|
11
|
-
};
|