Comments (5)
As mentioned above, use the TabItem to do the customization. Here is a sample similar to what you need:
Take care of the internal style, you may need to define your own builder if it's not compact with your situation
StyleProvider(
style: Style(),
child: ConvexAppBar(
style: TabStyle.react,
items: [
TabItem(icon: Icons.link),
TabItem(
icon: Icons.add,
isIconBlend: false,
activeIcon: Container(
decoration: BoxDecoration(
shape: BoxShape.circle,
gradient: LinearGradient(
begin: Alignment.topCenter,
end: Alignment.bottomCenter,
colors: [Colors.pink, Colors.blue],
tileMode: TileMode.repeated,
),
color: Colors.redAccent,
),
child: Icon(Icons.add, color: Colors.white, size: 40),
)),
TabItem(icon: Icons.work),
],
color: Colors.black87,
activeColor: Colors.grey,
backgroundColor: Colors.white,
),
)
class Style extends StyleHook {
@override
double get activeIconSize => 60;
@override
double get activeIconMargin => 0;
@override
double get iconSize => 20;
@override
TextStyle textStyle(Color color) {
return TextStyle(fontSize: 20, color: color);
}
}
from convex_bottom_bar.
Set a different icon for active item. TabItem#activeIcon
from convex_bottom_bar.
i actually need to use gradient background color for active item. I can only found activeColor
option instead of activeBackgroundColor
from convex_bottom_bar.
How about provide some screenshots?
from convex_bottom_bar.
from convex_bottom_bar.
Related Issues (20)
- Unable to remove the DEBUG label HOT 1
- DefaultTabController Error after Flutter 3.7.0 upgrade HOT 4
- Error building after adding import HOT 4
- Error: Member not found: 'DefaultTabController.maybeOf'. HOT 2
- Does anyone have problem with impeller-enabled on iOS HOT 1
- Error: Member not found: 'DefaultTabController.maybeOf'. Issue HOT 4
- WEB can't be built HOT 2
- Unable to run example code HOT 1
- Error: Member not found: 'DefaultTabController.maybeOf'. return widget.controller ?? DefaultTabController.maybeOf(context); HOT 1
- How to change text styte depends on selected tab?
- ConvexAppBar - elevation, does not work HOT 7
- Selected option occludes snack bar messages HOT 3
- Question: How to not change selected index when another item is pressed?
- Cannot change the currentIndex using Global Key HOT 1
- How can I add IconButton to TabItem HOT 1
- How can I refresh a page during page transitions?
- More customization needed (Circle shadow, switch animation) HOT 1
- ConvexAppBar.badge reactive circle resizes itself when badge isn't empty
- StyleHook issue
- Pixel overflow on big label HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from convex_bottom_bar.