text
stringlengths
1
372
preliminary guides addressing case 2
are being added to the UI components section.
you can request additional guides by commenting on issue #8427.
<topic_end>
<topic_start>
page navigation
flutter provides the navigation patterns seen on android
and iOS and also automatically adapts the navigation animation
to the current platform.
<topic_end>
<topic_start>
navigation transitions
on android, the default navigator.push() transition
is modeled after startActivity(),
which generally has one bottom-up animation variant.
on iOS:
<topic_end>
<topic_start>
platform-specific transition details
on android, flutter uses the ZoomPageTransitionsBuilder animation.
when the user taps on an item, the UI zooms in to a screen that features that item.
when the user taps to go back, the UI zooms out to the previous screen.
on iOS when the push style transition is used,
flutter’s bundled CupertinoNavigationBar
and CupertinoSliverNavigationBar nav bars
automatically animate each subcomponent to its corresponding
subcomponent on the next or previous page’s
CupertinoNavigationBar or CupertinoSliverNavigationBar.
<topic_end>
<topic_start>
back navigation
on android,
the OS back button, by default, is sent to flutter
and pops the top route of the WidgetsApp’s navigator.
on iOS,
an edge swipe gesture can be used to pop the top route.
<topic_end>
<topic_start>
scrolling
scrolling is an important part of the platform’s
look and feel, and flutter automatically adjusts
the scrolling behavior to match the current platform.
<topic_end>
<topic_start>
physics simulation
android and iOS both have complex scrolling physics
simulations that are difficult to describe verbally.
generally, iOS’s scrollable has more weight and
dynamic friction but android has more static friction.
therefore iOS gains high speed more gradually but stops
less abruptly and is more slippery at slow speeds.
<topic_end>
<topic_start>
overscroll behavior
on android,
scrolling past the edge of a scrollable shows an
overscroll glow indicator (based on the color
of the current material theme).
on iOS, scrolling past the edge of a scrollable
overscrolls with increasing resistance and snaps back.
<topic_end>
<topic_start>
momentum
on iOS,
repeated flings in the same direction stacks momentum
and builds more speed with each successive fling.
there is no equivalent behavior on android.
<topic_end>
<topic_start>
return to top
on iOS,
tapping the OS status bar scrolls the primary
scroll controller to the top position.
there is no equivalent behavior on android.
<topic_end>
<topic_start>
typography
when using the material package,
the typography automatically defaults to the
font family appropriate for the platform.
android uses the roboto font.
iOS uses the san francisco font.
when using the cupertino package, the default theme
uses the san francisco font.
the san francisco font license limits its usage to
software running on iOS, macOS, or tvOS only.
therefore a fallback font is used when running on android
if the platform is debug-overridden to iOS or the
default cupertino theme is used.
you might choose to adapt the text styling of material
widgets to match the default text styling on iOS.
you can see widget-specific examples in the
UI component section.
<topic_end>
<topic_start>
iconography
when using the material package,
certain icons automatically show different
graphics depending on the platform.
for instance, the overflow button’s three dots