Initial commit
This commit is contained in:
54
lib/src/widgets/header.dart
Normal file
54
lib/src/widgets/header.dart
Normal file
@@ -0,0 +1,54 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:furman_now/src/utils/theme.dart';
|
||||
|
||||
class HeaderWidget extends StatelessWidget {
|
||||
const HeaderWidget({
|
||||
required this.title,
|
||||
this.link,
|
||||
Key? key
|
||||
}) : super(key: key);
|
||||
|
||||
final String title;
|
||||
final HeaderLink? link;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(
|
||||
padding: const EdgeInsets.only(left: 40, right: 40, top: 20, bottom: 15),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
Text(
|
||||
title.toUpperCase(),
|
||||
style: furmanTextStyle(TextStyle(
|
||||
color: Colors.grey[800],
|
||||
fontWeight: FontWeight.w900,
|
||||
fontSize: 18,
|
||||
)),
|
||||
),
|
||||
if (link != null)
|
||||
Text(
|
||||
link!.text,
|
||||
style: furmanTextStyle(const TextStyle(
|
||||
color: Color(0xff755898),
|
||||
fontSize: 12,
|
||||
fontWeight: FontWeight.bold,
|
||||
)),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@immutable
|
||||
class HeaderLink {
|
||||
final String text;
|
||||
final String href;
|
||||
|
||||
const HeaderLink({
|
||||
required this.text,
|
||||
required this.href,
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user