| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105 |
- import 'coupon_uikit.dart';
- import 'package:flutter/material.dart';
- class HorizontalCouponExample1 extends StatelessWidget {
- const HorizontalCouponExample1({Key? key}) : super(key: key);
- @override
- Widget build(BuildContext context) {
- const Color secondaryColor = Color(0xffcbf3f0);
- const Color primaryColor = Color(0xff368f8b);
- return CouponCard(
- height: 150,
- backgroundColor: secondaryColor,
- curveAxis: Axis.vertical,
- firstChild: Container(
- decoration: const BoxDecoration(
- color: primaryColor,
- ),
- child: Column(
- mainAxisAlignment: MainAxisAlignment.center,
- children: [
- Expanded(
- child: Center(
- child: Column(
- mainAxisSize: MainAxisSize.min,
- children: const [
- Text(
- '23%',
- style: TextStyle(
- color: Colors.white,
- fontSize: 24,
- fontWeight: FontWeight.bold,
- ),
- ),
- Text(
- 'OFF',
- style: TextStyle(
- color: Colors.white,
- fontSize: 16,
- fontWeight: FontWeight.bold,
- ),
- ),
- ],
- ),
- ),
- ),
- const Divider(color: Colors.white54, height: 0),
- const Expanded(
- child: Center(
- child: Text(
- 'WINTER IS\nHERE',
- textAlign: TextAlign.center,
- style: TextStyle(
- color: Colors.white,
- fontSize: 12,
- fontWeight: FontWeight.bold,
- ),
- ),
- ),
- ),
- ],
- ),
- ),
- secondChild: Container(
- width: double.maxFinite,
- padding: const EdgeInsets.all(18),
- child: Column(
- mainAxisSize: MainAxisSize.min,
- crossAxisAlignment: CrossAxisAlignment.start,
- children: const [
- Text(
- 'Coupon Code',
- textAlign: TextAlign.center,
- style: TextStyle(
- fontSize: 13,
- fontWeight: FontWeight.bold,
- color: Colors.black54,
- ),
- ),
- SizedBox(height: 4),
- Text(
- 'FREESALES',
- textAlign: TextAlign.center,
- style: TextStyle(
- fontSize: 24,
- color: primaryColor,
- fontWeight: FontWeight.bold,
- ),
- ),
- Spacer(),
- Text(
- 'Valid Till - 30 Jan 2022',
- textAlign: TextAlign.center,
- style: TextStyle(
- color: Colors.black45,
- ),
- ),
- ],
- ),
- ),
- );
- }
- }
|