A semantic narrow page landmark that owns gutters and layout while applications own every visible authentication region.
app/components/nitro_kit/auth_shell.rbNitroKit::AuthShell.new(id:, html:, aria:, data:, desperately_need_a_class:) { ... }The shell supplies one semantic landmark, narrow constraint, gutters, and vertical rhythm. The application supplies every visible region.
A real Rails form and Card remain ordinary direct content.
test/dummy/app/components/gallery/blocks/auth_shell_page.rbrender NitroKit::AuthShell.new(
id: "gallery-auth-shell-credentials",
aria: { label: "Credentials example" }
) do
render_credentials_card
endBrand identity and supporting copy are siblings of the application-owned Card, not shell slots.
Secure workspace access for Research and Production.
test/dummy/app/components/gallery/blocks/auth_shell_page.rbrender NitroKit::AuthShell.new(
id: "gallery-auth-shell-branding",
aria: { labelledby: "gallery-auth-shell-brand-name" }
) do
header(data: { gallery: "auth-branding" }) do
h4(id: "gallery-auth-shell-brand-name") { "Analytical Engines" }
p { "Secure workspace access for Research and Production." }
end
render_access_card
endThe named Turbo Frame surrounds the shell and can replace the complete authentication state.
test/dummy/app/components/gallery/blocks/auth_shell_page.rbturbo_frame_tag("gallery-auth-shell-frame") do
render NitroKit::AuthShell.new(
id: "gallery-auth-shell-turbo",
aria: { label: "Email verification status" }
) do
render_verification_card
end
endValidation, completion, long identity copy, and a deliberately narrow viewport all use the same optionless shell.
Model errors, alert intent, field semantics, and recovery navigation remain caller-owned.
test/dummy/app/components/gallery/blocks/auth_shell_page.rbrender NitroKit::AuthShell.new(
id: "gallery-auth-shell-validation",
aria: { label: "Invalid credentials example" }
) do
render_validation_card
endCompletion content can replace the form without changing the shell contract.
test/dummy/app/components/gallery/blocks/auth_shell_page.rbrender NitroKit::AuthShell.new(
id: "gallery-auth-shell-success",
aria: { label: "Successful sign-in example" }
) do
render_success_card
endUnbroken identity pressure shrinks inside the fixed medium content constraint.
We sent instructions to katherine.johnson+analytical-engines-research-and-production@example.test for the International Research, Production, and Reliability Engineering workspace.
test/dummy/app/components/gallery/blocks/auth_shell_page.rbrender NitroKit::AuthShell.new(
id: "gallery-auth-shell-long-copy",
aria: { label: "Long account identity example" }
) do
render_long_copy_card
endGallery viewport metadata narrows the same shell; Nitro keeps gutters and descendants shrinkable.
test/dummy/app/components/gallery/blocks/auth_shell_page.rbrender NitroKit::AuthShell.new(
id: "gallery-auth-shell-mobile",
aria: { label: "Mobile authentication example" },
data: { gallery: "flow-surface", gallery_mobile: "true" }
) do
render_mobile_card
end