Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit b5bf1b0

Browse files
Add search page design
1 parent 6ec1426 commit b5bf1b0

File tree

1 file changed

+35
-11
lines changed

1 file changed

+35
-11
lines changed

‎lib/pages/search.dart

Lines changed: 35 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,42 @@ class _SearchPageState extends State<SearchPage> {
1414
appBar: AppBar(
1515
backgroundColor: Colors.transparent,
1616
elevation: 0,
17-
title: Text('Search Page', style: TextStyle(color: Colors.black)),
18-
actions: <Widget>[
19-
IconButton(
20-
icon: Icon(Icons.search, color: Colors.black),
21-
onPressed: () {
22-
print('Search pressed');
23-
}),
24-
],
25-
),
26-
body: Center(
27-
child: Text('Search Page'),
17+
title: Container(
18+
height: 45,
19+
child: TextField(
20+
autofocus: true,
21+
cursorColor: Colors.grey,
22+
decoration: InputDecoration(
23+
contentPadding: EdgeInsets.symmetric(horizontal: 20, vertical: 0),
24+
filled: true,
25+
fillColor: Colors.white,
26+
prefixIcon: Icon(Icons.search, color: Colors.black),
27+
border: OutlineInputBorder(
28+
borderRadius: BorderRadius.circular(50),
29+
borderSide: BorderSide.none
30+
),
31+
hintText: "Search e.g Sweatshirt",
32+
hintStyle: TextStyle(fontSize: 14, color: Colors.black),
33+
34+
),
35+
),
36+
),
2837
),
38+
body: Column(
39+
mainAxisAlignment: MainAxisAlignment.center,
40+
children: [
41+
Opacity(
42+
opacity: .7,
43+
child: Container(
44+
width: double.infinity,
45+
height: 250,
46+
child: Image( image: AssetImage("assets/images/search.png")),
47+
)
48+
),
49+
SizedBox(height: 40,),
50+
Text("Type to search ...", style: TextStyle(fontSize: 20),)
51+
],
52+
)
2953
);
3054
}
3155
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /