From 9ef93899004b7d9e1f0543babbd79a99d70bb915 Mon Sep 17 00:00:00 2001 From: Parker Lougheed Date: Mon, 31 Jul 2023 12:17:39 -0500 Subject: [PATCH] Add /ui exception for mini-toc generation (#9164) This allows index pages linked to from the breadcrumbs to be generated properly, such as the text index page. They were empty since the generation didn't account for `/ui` having multiple entries in the sidenav. --- src/_layouts/toc.html | 3 ++- src/ui/design/index.md | 2 +- src/ui/index.md | 1 - src/ui/interactivity/gestures/index.md | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/_layouts/toc.html b/src/_layouts/toc.html index 2273b4d9e0..6fb1b4d8c9 100644 --- a/src/_layouts/toc.html +++ b/src/_layouts/toc.html @@ -1,6 +1,7 @@ --- layout: default toc: false +sitemap: false --- {% assign url = page.url | regex_replace: '/index$|/index.html$|/$' -%} @@ -17,7 +18,7 @@ {% else -%} {% assign path = path | append: '/' | append: path_part -%} {% endif -%} - {% if forloop.index0 > 0 -%} + {% if forloop.index0 > 0 and path != '/ui' -%} {% assign topics = topics | where: "permalink", path -%} {% assign topics = topics[0].children | where_exp:"item", "item != 'divider'" -%} {% endif -%} diff --git a/src/ui/design/index.md b/src/ui/design/index.md index d4cc1f6e55..8159a01422 100644 --- a/src/ui/design/index.md +++ b/src/ui/design/index.md @@ -1,6 +1,6 @@ --- layout: toc -title: Design +title: Design & theming description: Content covering designing Flutter apps. sitemap: false --- diff --git a/src/ui/index.md b/src/ui/index.md index edad0601e4..dce8cc6020 100644 --- a/src/ui/index.md +++ b/src/ui/index.md @@ -1,5 +1,4 @@ --- -layout: toc title: Building user interfaces with Flutter short-title: UI description: Introduction to user interface development in Flutter. diff --git a/src/ui/interactivity/gestures/index.md b/src/ui/interactivity/gestures/index.md index 24d5e07120..a0c3540ee3 100644 --- a/src/ui/interactivity/gestures/index.md +++ b/src/ui/interactivity/gestures/index.md @@ -1,5 +1,6 @@ --- title: Taps, drags, and other gestures +short-title: Gestures description: How gestures, such as taps and drags, work in Flutter. ---