navigation

command
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 21, 2026 License: BSD-3-Clause Imports: 16 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Command navigation shows the navigation of Glutter on a WidgetsApp, without Material. The home page has two tabs. The first one navigates with the imperative API: a thumbnail (a Hero) opens a detail page through a custom PageRouteBuilder that slides in, and the "Pick a color" link opens a page that returns a value, which the home page reads from the channel of NavigatorPush. The second tab keeps a stack of pages in a nested Navigator, the Pages API: the "Push page" link adds a page to the list, and the Back link of a page removes it again. Every link takes the keyboard focus: Tab and Shift+Tab move between the links, the focused link has a thick border, Enter or Space follows it, and Escape goes back (every page maps the DismissIntent to a pop). It uses only the public packages.

Run it with: go run ./examples/navigation

Environment: GLUTTER_BACKEND=x11|wayland, GLUTTER_SCREENSHOT=<file.png>, GLUTTER_SCREENSHOT_AFTER=<duration>. In debug builds: GLUTTER_DEV_ROUTE=<"/", "/detail" or "/pick"> opens that page first, and GLUTTER_DEV_TAB=<0 or 1> opens that tab of the home page.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL