Skip to content

docs(layer-runtime): toastHost owns the toast context and queue - #10166

Merged
cixzhang merged 1 commit into
meta:mainfrom
vjeux:docs/layer-runtime-toast-host
Nov 5, 2026
Merged

cixzhang merged 1 commit into
meta:mainfrom
vjeux:docs/layer-runtime-toast-host

Conversation

@vjeux

@vjeux vjeux commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

Reader impact

architecture:layer-runtime's owning-code list tells a contributor that LayerProvider, ToastContext, useToast and ToastViewport own notification state. Since #10012, ToastContext lives in Layer/toastHost.tsx, with Toast's viewport registration and the queue that holds a toast until a viewport takes it. A contributor who follows the list misses the file that owns them.

Source of truth

packages/core/src/Layer/toastHost.tsx on main, which exports ToastContext, registerToastHost, createToastQueue, ToastQueueConnector and ToastHostOutlet. The record's own INV10 and its verification row already name toastHost.tsx.

Correction

One bullet under "Owning code" now starts: "Layer/toastHost.tsx owns ToastContext, Toast's viewport registration, and the toast queue that LayerProvider's outlet and useToast's fallback root both use." The rest of the bullet is unchanged, minus ToastContext in its list. No claim, invariant or verification row changes.

Evidence

The bullet names only files and exports that exist on main. pnpm check:knowledge passes.

Writing rubric results

  • R1 narration: none; the bullet states ownership in the present tense.
  • R2 research in the record: none.
  • R3 evidence naming a change: none; the record names no pull request.
  • R4 rejected alternatives over one line or outside a decision: none.
  • R5 pull request or issue references remaining: none in the record.
  • R6 ruled open questions still listing options: none.

Scope

  • This PR changes documentation only, or names every necessary generated artifact.
  • Runtime, API, visual, and policy changes were removed or split.
  • Public text and artifacts contain no internal Meta context.

Testing

pnpm check:knowledge, Prettier on the record and pnpm review:pre pass at this head.

Since meta#10012, `ToastContext` lives in Layer/toastHost.tsx, with Toast's
viewport registration and the queue that holds a toast until a viewport
takes it. The record's owning-code list still named `ToastContext`
beside LayerProvider, useToast and ToastViewport. It now names
toastHost.tsx and what it owns, as INV10 and its verification row
already do.
@vercel

vercel Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Nov 5, 2026 9:44pm UTC

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 5, 2026
@astracat-bot

astracat-bot Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

AI review status for this pull request.

Review status Updated
🟢 Reviewed (for maintainers only) Nov 5, 2026, 9:49 PM UTC

@github-actions github-actions Bot added the needs:spec-owner-review Current knowledge records await owner approval label Nov 5, 2026
@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

PR Analysis Report

🔎 Preview · 4100c70

Storybook · Sandbox · built from this PR's head

Package size: no published package changed; no new dependencies.

API changes: none in this pull request

Committed API report behind this build: cli 19 rows, core 23 rows; run pnpm api:report.

Not run on this PR: add ci:run-visual, ci:run-a11y or ci:run-rtl to run them.


Generated by PR Enrichment workflow | View full report

@cixzhang

cixzhang commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

/approve-spec 4100c70

@github-actions github-actions Bot removed the needs:spec-owner-review Current knowledge records await owner approval label Nov 5, 2026

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI has not run on this head yet.

The new Owning code sentence matches main: Layer/toastHost.tsx defines ToastContext, registerToastHost and createToastQueue, and LayerProvider's outlet and useToast's fallback root both use that queue; no requirement in the record changes.

Next, a maintainer adds the ci:run label so CI runs on this fork branch; until then the required checks report that they are waiting for it.

[Automated review]

@vjeux
vjeux marked this pull request as ready for review November 5, 2026 21:47
@cixzhang cixzhang added the ci:run A maintainer lets this outside contributor's pull request run CI (AST-030 FR17) label Nov 5, 2026
@cixzhang
cixzhang marked this pull request as draft November 5, 2026 21:53
@cixzhang
cixzhang marked this pull request as ready for review November 5, 2026 21:54
@cixzhang
cixzhang merged commit 8d59e5d into meta:main Nov 5, 2026
146 of 151 checks passed
@vjeux
vjeux deleted the docs/layer-runtime-toast-host branch November 5, 2026 23:54

This branch was successfully deployed

1 active deployment
Preview — 4100c704 Deployed Nov 5, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:run A maintainer lets this outside contributor's pull request run CI (AST-030 FR17) CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants