v0.1.5
sliverbar_with_card
एक फ्लटर पैकेज जो कार्ड के साथ एक स्लिवर एपीआई बनाने के लिए है, जिसमें क्रिया बटन और वापस बटन होता है, कैटलॉग आइटम दिखाने के लिए उत्तम है।
60लाइक 3330-दिन डाउनलोड40Pub अंक
प्लेटफ़ॉर्म डेटा नहीं
एक फ्लटर पैकेज जो कार्ड के साथ एक SliverAppBar बनाने के लिए है।
{"sdk":"flutter"}{"sdk":"flutter"}—यह अंग्रेज़ी मूल स्नैपशॉट है। नवीनतम सामग्री GitHub पर देखें।
Pub Pull Requests are welcome Pull Requests are welcome Codemagic build status
A Flutter package to create a SliverAppBar with a Card.
Inspired by FaoB's Twitter Post design.
Showcase
Wrap your content with CardSliverAppBar and set your desired options:
MaterialApp(
home: Material(
child: CardSliverAppBar(
height: 300,
background: Image.asset("assets/logo.png"),
title: Text("The Walking Dead"),
body: Container()
)
)
)
MaterialApp(
home: Material(
child: CardSliverAppBar(
height: 300,
background: Image.asset("assets/logo.png", fit: BoxFit.cover),
title: Text("The Walking Dead",
style: TextStyle(color: Colors.black, fontSize: 20, fontWeight: FontWeight.bold)
),
titleDescription: Text("Drama, Action, Adventure, Fantasy, \nScience Fiction, Horror, Thriller",
style: TextStyle(color: Colors.black, fontSize: 11)
),
card: AssetImage("assets/card.jpg"),
backButton: true,
backBottonColors: [Colors.white, Colors.black],
action: IconButton(
icon: Icon(Icons.favorite),
iconSize: 30.0,
color: Colors.red,
onPressed: (){},
),
body: Container()
)
)
)
| Property | Type | Description | Default |
|---|---|---|---|
required height |
Double | The height of background image | - |
required background |
Image | The image of background | - |
required title |
Text | The text of title | - |
required body |
Widget | The body of this widget | - |
| titleDescription | Text | The short description of title | null |
| backButton | Boolean | If has backButton | false |
| backButtonColors | List | The colors of backButton when open and closed | Colors.white |
| action | Widget | The action between appBar and background | null |
| card | ImageProvider | The image of card | null |