v0.3.0container_tab_indicator
익숙한 Container 유사 속성을 사용하여 사용자 정의 탭 인디케이터를 만드세요.
44좋아요 6천30일 다운로드160Pub 점수
AndroidiOSWebmacOSWindowsLinux
자신만의 Container와 유사한 탭 인디케이터 만들기
{"sdk":"flutter"}{"sdk":"flutter"}아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.
Add customized ContainerTabIndicator as an indicator for your TabBar. You can manipulate width, height, color, radius, border and positioning within Tab.
class ContainerTabIndicator extends Decoration {
final double width;
final double widthFraction;
final double height;
final double heightFraction;
final EdgeInsetsGeometry padding;
final Color color;
final BorderRadius radius;
final double borderWidth;
final Color borderColor;
...
}
The full example code can be found here.
import 'package:container_tab_indicator/container_tab_indicator.dart';
...
TabBar(
tabs: [
Text('First', style: TextStyle(color: Colors.black)),
Text('Second', style: TextStyle(color: Colors.black)),
],
indicator: ContainerTabIndicator(
width: 16,
height: 16,
radius: BorderRadius.circular(8.0),
padding: const EdgeInsets.only(left: 36),
borderWidth: 2.0,
borderColor: Colors.black,
),
),
example
This package is still in early stages. To see the upcoming features, check the Issue board. If you notice any bugs not present in issues, please file a new issue. If you are willing to fix or enhance things yourself, you are very welcome to make a pull request.