-
Notifications
You must be signed in to change notification settings - Fork 29.8k
Description
Use case
Currently, providing largeTitle and omitting middle to CupertinoSliverNavigationBar results in the same widget being used for
large title in expanded state and "middle title" in collapsed state, thus preventing a use of a different widget for collapsed state title (or just changing text style of the title for example). If we provide middle property as well (to be used as a title in collapsed state), both largeTitle and middle are visible when the nav bar is expanded (which is according to docs an expected behaviour). But, if we do not want such behaviour, it would be nice to have alwaysShowMiddle exposed with default value being widget.middle != null.
Proposal
Add alwaysShowMiddle as a field to CupertinoSliverNavigationBar and pass it to _LargeTitleNavigationBarSliverDelegate with default value of widget.middle != null.