Loading repository data…
Loading repository data…
kspo / repository
This package offers a collapsible app bar along with an attractive search bar animation, enhancing the visual appeal of your Flutter app with an iOS-inspired design. This package is versatile, allowing complete customization, and it seamlessly works on both iOS and Android platforms.
[][linkedin]
[
][github]
[][pub.dev]
As a developer passionate about Apple UI/UX designs, I felt that Flutter lacked sufficient support for a widget that I wanted to develop. CupertinoSliverNavigationBar does not provide support for a search bar and a bottom app bar. Additionally, even if you were to add them as Slivers, creating a built-in animation and, furthermore, implementing Apple transition animations during page transitions would be challenging. This plugin frees you from this burden.
| Floated Large Title | Pinned Large Title | Only Large Title |
|---|---|---|
| Normal Navbar Floated | Normal Navbar Pinned | Only Navbar |
| Large Title, SearchBar and Bottom | Large Title and Bottom |
|---|---|
Before the table of content, hereby, you can find all of example from here. Enjoy!
It's been necessary from the beginning, and I just did it.
Using SuperScaffold provides several advantages and additional features compared to the standard Scaffold in Flutter. Here are some reasons why you might consider using SuperScaffold:
Configurability: SuperScaffold allows you to easily configure and customize various parts of the app bar, including the title, large title, search bar, and bottom bar. This provides flexibility in adapting the app bar to the specific design requirements of your application.
Search Bar Integration: With SuperScaffold, you can integrate a search bar (SuperSearchBar) directly into the app bar, complete with customizable behavior, animation, and callbacks for handling user input.
Large Title Support: The SuperLargeTitle feature enables the use of large titles in the app bar, which can be particularly useful in applications with a prominent navigation hierarchy.
Bottom Bar Options: The SuperAppBarBottom feature allows you to add a bottom bar below the app bar, providing additional space for interactive elements or navigation controls.
Consistent Theming: SuperScaffold includes theming options to ensure a consistent look and feel throughout your application. You can customize colors, borders, and other visual aspects easily.
Before the table of content, hereby, you can find all of example from here. Enjoy!
dependencies:
super_cupertino_navigation_bar: latest_version
import 'package:super_cupertino_navigation_bar/super_cupertino_navigation_bar.dart';
Scaffold(
backgroundColor: Theme.of(context).scaffoldBackgroundColor,
body: SuperScaffold(
appBar: SuperAppBar(
title: Text("Hello SuperScaffold"),
largeTitle: SuperLargeTitle(
enabled: true,
largeTitle: "Welcome",
),
searchBar: SuperSearchBar(
enabled: true,
onChanged: (query) {
// Search Bar Changes
},
onSubmitted: (query) {
// On Search Bar submitted
},
searchResult: /* ... */,
// Add other search bar properties as needed
),
bottom: SuperAppBarBottom(
enabled: true,
height: 40,
child: YourCustomBottomWidget(), // Any widget of yours
),
),
body: SingleChildScrollView( // You can use CustomScrollView or any Widget desired
child: Column(
children: [
Card(
// Playground card
// Add your onTap logic for Playground card
),
Card(
// List of example cards
// Add your ListView.separated logic for example cards
),
],
),
),
);
SuperScaffold is an extended version of the Flutter Scaffold widget with additional features and customization options.
stretch: If true, the SuperScaffold will stretch to occupy the available space.transitionBetweenRoutes: If true, enables transition animations between routes.appBar: An instance of SuperAppBar for customizing the app bar.onCollapsed: A callback function invoked when the app bar is collapsed.scrollController: A custom scroll controller for the body of the SuperScaffold.body: body attribute can now be any widget you want. SingleChildScrollView, CustomScrollView or etc...Feel free to use this extended SuperScaffold in your Flutter application for enhanced customization and additional features. Adjust the parameters according to your application's requirements.
SuperAppBar is a customizable Flutter widget that extends the functionality of the default AppBar. It provides enhanced features such as a search bar, large title, and additional customization options.
| Parameter | Description | Default Value |
|---|---|---|
title | The main title of the app bar. If a Text widget is provided, it ensures that a default style is set if none is provided. | - |
actions | Additional widgets to display on the app bar, typically icons or buttons. | - |
height | The height of the app bar. | kToolbarHeight |
leadingWidth | The width of the leading widget. | - |
leading | A widget to display before the title. If automaticallyImplyLeading is true, this widget will represent the back button. | - |
automaticallyImplyLeading | Whether to automatically include a leading widget (typically a back button). | true |
titleSpacing |