https://github.com/flutter-studio/ticket_card
A ticket-style card
https://github.com/flutter-studio/ticket_card
card cardview
Last synced: 8 months ago
JSON representation
A ticket-style card
- Host: GitHub
- URL: https://github.com/flutter-studio/ticket_card
- Owner: flutter-studio
- License: other
- Created: 2019-11-29T08:36:15.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2019-12-02T12:17:28.000Z (almost 6 years ago)
- Last Synced: 2023-08-20T23:00:58.700Z (about 2 years ago)
- Topics: card, cardview
- Language: Dart
- Size: 172 KB
- Stars: 8
- Watchers: 1
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
English | [简体中文](./README_zh-CN.md)
# ticket_card
[](https://pub.dartlang.org/packages/ticket_card)
A ticket-style card
![]()
## Usage
To use this plugin, add `ticket_card` as a [dependency in your pubspec.yaml file](https://flutter.io/platform-plugins/).## Widget
### TicketCard
| Prop | Description |
| -------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| lineFromTop | The distance from the top of the divider |
| lineRadius | The radius of the rounded corners on either side of the divider |
| lineColor | The color of the dividing line |
| decoration | Ticket-style card decorator |
| child | A child component of a ticket card |## Example
``` dart
// Import package
import 'package:ticket_card/ticket_card.dart';
import 'package:flutter/material.dart';TicketCard(
decoration: TicketDecoration(
shadow: [TicketShadow(color: Colors.black, elevation: 6)],
border: TicketBorder(
color: Colors.green,
width: 0.1,
style: TicketBorderStyle.dotted
)
),
lineFromTop: 100,
child: Container(
height: 200,
width: 200,
color: Colors.white,
child: Text(
"sdfsf",
style: TextStyle(color: Colors.black),
),
),
)
```