page

Tutorials Overview (Table of Contents)

Route: /tutorials/:id → views/TutorialsOverview.vue (kind "overview")

1. Route and component dispatch

A Tutorials Overview page is what swift-docc emits from the technology-root @Tutorials directive — the "table of contents" page that lists a technology's volumes/chapters and its resources block. On the wire it is a TutorialsPageRenderNode with kind: "overview" (see kinds/node-overview.html for the full data sheet and the routing-vs-string-comparison nuance summarized again below).

routes.js matches the bare technology-root URL shape /tutorials/:id (no further path segments) to the route named tutorials-overview, whose component is views/TutorialsOverview.vue. Any deeper path under the same technology (/tutorials/:id/*, e.g. an individual tutorial or tutorial article) instead routes to Topic.vue, a completely different view chain documented on the Tutorial Project and Tutorial Article hierarchy pages. Dispatch to this page therefore happens entirely at the router/URL-shape level — nothing in the component tree below the route ever compares a kind string against the literal "overview".

The route-level view component fetches the RenderNode JSON for the current route and forwards exactly three of its top-level fields (metadata, references, sections) as props to the real presentational component, components/TutorialsOverview.vue (locally aliased Overview):

<template>
  <Overview v-if="topicData" v-bind="overviewProps" :key="topicKey" />
</template>
...
overviewProps: ({ topicData: { metadata, references, sections } }) => ({
  metadata, references, sections,
}),

components/TutorialsOverview.vue is the actual layout root. It partitions the incoming sections array by section kind into a single hero section and "everything else," then renders a dark-themed Nav, a Hero fed the hero section, and a LearningPath fed every other section (lines 15–34):

<div class="tutorials-overview">
  <Nav v-if="!isTargetIDE" :sections="otherSections" class="theme-dark">{{ title }}</Nav>
  <main id="app-main" tabindex="0" class="main">
    <div class="radial-gradient">
      <Hero v-if="heroSection" :action="heroSection.action" :content="heroSection.content"
            :estimatedTime="metadata.estimatedTime" :image="heroSection.image"
            :title="heroSection.title" />
    </div>
    <LearningPath v-if="otherSections.length > 0" :sections="otherSections" />
  </main>
</div>

TutorialsOverview/LearningPath.vue is the actual per-non-hero-section dispatch site. It splits its sections prop into volumes (kind === 'volume', rendered through a dedicated <Volume v-for> loop) and otherSections (dispatched generically through a componentFor/propsFor lookup table, whose only populated key today is resources → Resources.vue):

const SectionKind = { resources: 'resources', volume: 'volume' };
componentFor: ({ kind }) => ({
  [SectionKind.resources]: Resources,
  [SectionKind.volume]: Volume,
}[kind]),

Volume.vue renders an optional VolumeName header/blurb plus one Chapter per chapters[] entry; Resources.vue renders the same shared VolumeName component (fed a localized "Resources" title instead of an authored one) plus a ResourcesTileGroup grid of ResourcesTile cards. Both of these subtrees, and the intro/hero band above them, are walked in full in section 3's DOM hierarchy tree.

2. Page chrome (non-schema)

Unlike a Documentation Topic page, the Tutorials Overview page has no sidebar navigator and no search field — the same is true of the Tutorial (Project) and Tutorial Article page kinds, since all three share this dark, tutorials-specific chrome rather than the light documentation chrome. The only persistent navigation surface is the top nav bar; there is no <Navigator> tree and no NavigatorLink/filter UI anywhere in this view chain.

TutorialsOverview/Nav.vue wraps the generic NavBase.vue (root element nav.nav, the same base bar every page kind uses), supplying a NavTitleContainer whose visible title is the page's own metadata.category string (via the parent's title computed) and whose subhead is the localized plural "Tutorials" string ($tc('tutorials.title', 2)). Its menu-items slot always includes one NavMenuItemBase.in-page-navigation wrapping a TutorialsNavigation component — the in-nav "jump to volume" menu — fed the same non-hero sections array LearningPath.vue also receives.

The parent, components/TutorialsOverview.vue, always applies class="theme-dark" to this Nav (lines 16–20), so the top bar is dark-themed unconditionally, regardless of the site-wide light/dark/auto color-scheme preference — matching the enclosing page's own forced-dark background (body:has(.tutorials-overview) { --color-text-background: #{dark-color(fill)}; }, a global, non-scoped style rule in that same component). The Nav is only omitted entirely when isTargetIDE is true, i.e. when the page is rendered inside Xcode's built-in documentation viewer rather than a browser.

TutorialsNavigation.vue renders a flat nav.tutorials-navigation > TutorialsNavigationList with one <li> per section: a named volume becomes an expandable TutorialsNavigationMenu (a button.toggle + transition-expand-animated content panel, listing each chapter as a plain link and collapsed by default unless it is the currently "active" volume), an unnamed volume becomes a flat TutorialsNavigationList of its chapters with no enclosing toggle, and a resources section becomes a single plain TutorialsNavigationLink labelled with the same localized "Resources" string Resources.vue uses for its own heading. "Which volume is active" is tracked in the shared TutorialsOverviewStore, written both by clicking a menu toggle (select-menu/deselect-menu events) and by scroll position (each Volume/Chapter/Resources component mixes in onIntersectViewport to call setActiveVolume/ setActiveSidebarLink as it crosses the viewport). This scroll-and-click-driven jump menu is the only client-side interactive chrome specific to this page kind; see kinds/section-volume.html section 5 for the fuller "native <details> could replace part of this" analysis.

3. DOM hierarchy: root → chrome → content → leaves

The tree below is assembled from components/TutorialsOverview.vue (root/hero/learning-path scaffolding), Nav.vue/TutorialsNavigation.vue (chrome), and LearningPath.vue → Volume.vue/Resources.vue and their children (content). It walks one representative volume (with a named header, one chapter, and a resolved tutorial topic link) and one resources block (with a two-tile grid) down to leaf inline content, matching the tier labels used across kinds/*.html.

(tiles[].media, a nullable reference-format string declared on the wire schema, is not walked above because — per kinds/section-resources.html and kinds/section-tile.html — it is not read by ResourcesTileGroup.vue's propsFor or by ResourcesTile.vue's own props, i.e. it is present on the wire but dead data for this page's current rendering.)

4. RenderNode content dispatch (schema-driven)

Kinds actually reachable on a real Tutorials Overview page, in the order the component tree dispatches them (top-level sections partition first, then nested block/inline/reference dispatch inside whichever section matched):

Dispatch siteKindTierNotes
components/TutorialsOverview.vue partitionedSections herosection Exactly one expected per page; everything else falls into otherSections.
LearningPath.vue partitionedSections volumesection Zero or more; rendered via a dedicated <Volume v-for> loop, not the generic lookup table.
LearningPath.vue componentFor/propsFor resourcessection At most one in practice (the map's only other populated key); dispatched generically, unlike volume.
Resources.vue > ResourcesTileGroup.vue per-tile loop tilesection-embedded (untagged on the wire) Not a discriminated kind; one RenderTile object per resources.tiles[] entry.
ContentNode.vue (hero/volume/chapter/tile content arrays) paragraph and any other RenderBlockContent case an author writes block Whatever block kinds appear in authored prose are reachable here; paragraph is shown as the representative case in section 3's tree.
ContentNode.vue inline dispatch (within the above blocks) text and any other RenderInlineContent case inline Same caveat as above — text is the representative leaf case.
Volume.vue lookupTopics() / chapter tutorial links topicreference Each chapters[].tutorials[] identifier resolved against the page's references map.
ResourcesTile.vue action / Hero.vue action topic / linkreference Resolved via DestinationDataProvider; internal doc links resolve as topic, external URLs as link.
Hero.vue/VolumeName.vue/Chapter.vue Asset imagereference Hero/volume/chapter illustration identifiers resolved against references.

5. Kind cross-reference table

Exhaustive list of every kind documented elsewhere in this reference that is reachable from a Tutorials Overview page, for use as backlink source data.

KindTierKind file
overviewnodenode-overview.html
herosectionsection-hero.html
volumesectionsection-volume.html
resourcessectionsection-resources.html
tilesection (embedded/untagged)section-tile.html
paragraphblockblock-paragraph.html
textinlineinline-text.html
topicreferencereference-topic.html
linkreferencereference-link.html
imagereferencereference-image.html

Any other RenderBlockContent/RenderInlineContent case an author writes inside a hero/volume/chapter/tile's content array is also reachable in principle (the ContentNode.vue dispatcher used there is fully generic and not restricted by page kind) — the block/inline rows above list only the representative leaf case actually walked in section 3, not an exhaustive claim that no other block/inline kind can appear on this page.