Skip to content

[DRAFT] Ai header#13264

Open
lamek wants to merge 4 commits intoflutter:mainfrom
lamek:ai-header
Open

[DRAFT] Ai header#13264
lamek wants to merge 4 commits intoflutter:mainfrom
lamek:ai-header

Conversation

@lamek
Copy link
Copy Markdown
Contributor

@lamek lamek commented Apr 10, 2026

Adds top level AI header and reorganizes our current AI landing page and AI content.

Presubmit checklist

  • If you are unwilling, or unable, to sign the CLA, even for a tiny, one-word PR, please file an issue instead of a PR.
  • If this PR is not meant to land until a future stable release, mark it as draft with an explanation.
  • This PR follows the Google Developer Documentation Style Guidelines—for example, it doesn't use i.e. or e.g., and it avoids I and we (first-person pronouns).
  • This PR uses semantic line breaks
    of 80 characters or fewer.

@lamek lamek requested review from a team and sfshaza2 as code owners April 10, 2026 18:00
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces a new "AI" section to the Flutter documentation, including a rewritten overview page, navigation header updates, and a new sidebar configuration. The review feedback highlights the need to register the new sidebar in the layout components to ensure it appears correctly, fix formatting issues such as line length and trailing spaces in the markdown content, and remove trailing slashes from permalinks in the sidebar configuration to maintain navigation consistency.

Comment on lines +65 to +69
_NavItem(
href: '/ai/create-with-ai',
label: 'AI',
isActive: activeEntry == ActiveNavEntry.ai,
),
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.

high

When adding a new top-level navigation entry like AI, ensure it is also mirrored in the DashSideNav component (site/lib/src/components/layout/sidenav.dart) and registered in the pathSidenavs map in site/lib/src/layouts/dash_layout.dart. Currently, these updates are missing, which will prevent the AI-specific sidebar from appearing and break navigation consistency on mobile views.

This guide covers how you can leverage AI tools to build AI-powered
features for your Flutter apps and streamline your
Flutter and Dart development.
This guide covers how to integrate AI into your development process to write code faster, and how to build generative AI features directly into your Flutter apps.
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.

medium

This line exceeds the 80-character limit for semantic line breaks and contains a trailing space. Please wrap the text to follow the project's documentation style guidelines.

Suggested change
This guide covers how to integrate AI into your development process to write code faster, and how to build generative AI features directly into your Flutter apps.
This guide covers how to integrate AI into your development process to write
code faster, and how to build generative AI features directly into your
Flutter apps.

Comment on lines +23 to +28
- title: GenUI SDK
permalink: /ai/genui/
- title: Flutter AI Toolkit
permalink: /ai/ai-toolkit/
- title: Best Practices
permalink: /ai/best-practices/
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.

medium

Remove the trailing slashes from these permalinks. The site's navigation logic (specifically _urlMatchesPermalink in sidenav.dart) expects consistency with other configuration files like default.yml, which do not use trailing slashes. Keeping them here may break the 'active' state highlighting in the sidebar.

    - title: GenUI SDK
      permalink: /ai/genui
    - title: Flutter AI Toolkit
      permalink: /ai/ai-toolkit
    - title: Best Practices
      permalink: /ai/best-practices

@flutter-website-bot
Copy link
Copy Markdown
Collaborator

flutter-website-bot commented Apr 10, 2026

Visit the preview URL for this PR (updated for commit aa74813):

https://flutter-docs-prod--pr13264-ai-header-nn1a053u.web.app

Copy link
Copy Markdown
Contributor

@sfshaza2 sfshaza2 left a comment

Choose a reason for hiding this comment

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

Overall, this looks good but the bot has a couple of valid complaints and you clearly want to hurt me with your run-on lines. ;) I'll approve, but please don't land this until you make these changes.


Using AI in your Flutter app unlocks new user experiences that allow your app to
support natural language understanding and content generation.
* **[Antigravity](https://antigravity.google/)**: An in-IDE AI agent that can plan tasks, read and write code, run terminal commands, and verify its own changes for you.
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.

This and the next few lines requires semantic line breaks.

[official documentation][firebase-ai-logic-docs].
* [Flutter AI Toolkit][] - A sample app with pre-built widgets to help you build
AI-powered features in Flutter.
Integrating generative AI into your Flutter application unlocks new user experiences, allowing your app to support natural language processing, intelligent orchestration, and dynamic content generation.
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.

Ditto. Semantic line breaks.

started, visit the [AI rules for Flutter and Dart][] guide.

[AI rules for Flutter and Dart]: /ai/ai-rules
* **[Firebase AI Logic client SDKs]({{site.firebase}}/docs/ai-logic)**: The official Firebase SDK to securely access Gemini and Imagen models directly from your Flutter client.
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.

This and the next two lines: semantic line breaks.

from your Flutter client.
---

Firebase AI Logic provides safe, secure access to Google's state-of-the-art base models (including Gemini and Imagen) directly from your app logic.
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.

Why are you hurting me with lack of semantic line breaks?


## Overview

This page serves as a placeholder for future comprehensive documentation on integrating Firebase AI Logic SDKs into your Flutter projects.
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.

ditto

@@ -0,0 +1,12 @@
---
title: Gemini Code Assist
description: >
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.

Interesting. I thought the correct syntax was ">-", not ">". But now I'm not sure.

provides real-time code completion and error explanation.
---

Gemini Code Assist is an AI-powered code assistant that integrates into your IDE to provide contextual suggestions, inline chat, and code generation features.
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.

Ditto.


## Overview

This page serves as a placeholder for future comprehensive documentation on leveraging Gemini Code Assist for your Flutter development workflow.
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.

Ditto

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants