Commit 8f9555c1 authored by Dasun Madushanka's avatar Dasun Madushanka

Update search_box.dart

parent 79c7dd45
......@@ -3,6 +3,7 @@ import 'package:flutter_svg/flutter_svg.dart';
import '../constants.dart';
//search box class
class SearchBox extends StatelessWidget {
const SearchBox({
Key key,
......@@ -20,8 +21,8 @@ class SearchBox extends StatelessWidget {
vertical: kDefaultPadding / 4, // 5 top and bottom
),
decoration: BoxDecoration(
color: Colors.white.withOpacity(0.4),
borderRadius: BorderRadius.circular(12),
color: Colors.white.withOpacity(0.4),//box opacity: 0.4
borderRadius: BorderRadius.circular(12),// add circular border
),
child: TextField(
onChanged: onChanged,
......@@ -29,9 +30,9 @@ class SearchBox extends StatelessWidget {
decoration: InputDecoration(
enabledBorder: InputBorder.none,
focusedBorder: InputBorder.none,
icon: SvgPicture.asset("assets/icons/search.svg"),
hintText: 'Search',
hintStyle: TextStyle(color: Colors.white),
icon: SvgPicture.asset("assets/icons/search.svg"),//add the search icon from assesst folder
hintText: 'Search',//hint text
hintStyle: TextStyle(color: Colors.white),//hint style
),
),
);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment