Compare commits
2 Commits
10aad47124
...
a1a995777b
| Author | SHA1 | Date | |
|---|---|---|---|
| a1a995777b | |||
| 3d12f0c160 |
@@ -49,36 +49,35 @@ class _ChooseGameViewState extends State<ChooseGameView> {
|
|||||||
),
|
),
|
||||||
centerTitle: true,
|
centerTitle: true,
|
||||||
),
|
),
|
||||||
body: Container(
|
body: Column(
|
||||||
decoration: CustomTheme.standardBoxDecoration,
|
children: [
|
||||||
padding: const EdgeInsets.all(10),
|
Padding(
|
||||||
child: Column(
|
padding: const EdgeInsets.symmetric(horizontal: 10),
|
||||||
children: [
|
child: CustomSearchBar(
|
||||||
CustomSearchBar(
|
|
||||||
controller: searchBarController,
|
controller: searchBarController,
|
||||||
hintText: 'Game Name',
|
hintText: 'Game Name',
|
||||||
),
|
),
|
||||||
const SizedBox(height: 5),
|
),
|
||||||
Expanded(
|
const SizedBox(height: 5),
|
||||||
child: ListView.builder(
|
Expanded(
|
||||||
itemCount: widget.games.length,
|
child: ListView.builder(
|
||||||
itemBuilder: (BuildContext context, int index) {
|
itemCount: widget.games.length,
|
||||||
return TitleDescriptionListTile(
|
itemBuilder: (BuildContext context, int index) {
|
||||||
title: widget.games[index].$1,
|
return TitleDescriptionListTile(
|
||||||
description: widget.games[index].$2,
|
title: widget.games[index].$1,
|
||||||
badgeText: translateRulesetToString(widget.games[index].$3),
|
description: widget.games[index].$2,
|
||||||
isHighlighted: selectedGameIndex == index,
|
badgeText: translateRulesetToString(widget.games[index].$3),
|
||||||
onPressed: () async {
|
isHighlighted: selectedGameIndex == index,
|
||||||
setState(() {
|
onPressed: () async {
|
||||||
selectedGameIndex = index;
|
setState(() {
|
||||||
});
|
selectedGameIndex = index;
|
||||||
},
|
});
|
||||||
);
|
},
|
||||||
},
|
);
|
||||||
),
|
},
|
||||||
),
|
),
|
||||||
],
|
),
|
||||||
),
|
],
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -123,7 +123,7 @@ class _CreateGameViewState extends State<CreateGameView> {
|
|||||||
mainAxisAlignment: MainAxisAlignment.start,
|
mainAxisAlignment: MainAxisAlignment.start,
|
||||||
children: [
|
children: [
|
||||||
Container(
|
Container(
|
||||||
margin: const EdgeInsets.symmetric(horizontal: 12, vertical: 10),
|
margin: const EdgeInsets.symmetric(horizontal: 12, vertical: 5),
|
||||||
child: TextInputField(
|
child: TextInputField(
|
||||||
controller: _gameNameController,
|
controller: _gameNameController,
|
||||||
hintText: 'Game name',
|
hintText: 'Game name',
|
||||||
@@ -213,7 +213,6 @@ class _CreateGameViewState extends State<CreateGameView> {
|
|||||||
},
|
},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
||||||
CustomWidthButton(
|
CustomWidthButton(
|
||||||
text: 'Create game',
|
text: 'Create game',
|
||||||
sizeRelativeToWidth: 0.95,
|
sizeRelativeToWidth: 0.95,
|
||||||
@@ -232,7 +231,6 @@ class _CreateGameViewState extends State<CreateGameView> {
|
|||||||
}
|
}
|
||||||
: null,
|
: null,
|
||||||
),
|
),
|
||||||
const SizedBox(height: 20),
|
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ class TitleDescriptionListTile extends StatelessWidget {
|
|||||||
return GestureDetector(
|
return GestureDetector(
|
||||||
onTap: onPressed,
|
onTap: onPressed,
|
||||||
child: AnimatedContainer(
|
child: AnimatedContainer(
|
||||||
margin: const EdgeInsets.symmetric(horizontal: 12, vertical: 10),
|
margin: const EdgeInsets.symmetric(vertical: 10, horizontal: 10),
|
||||||
padding: const EdgeInsets.symmetric(vertical: 6, horizontal: 12),
|
padding: const EdgeInsets.symmetric(vertical: 6, horizontal: 12),
|
||||||
decoration: isHighlighted
|
decoration: isHighlighted
|
||||||
? CustomTheme.highlightedBoxDecoration
|
? CustomTheme.highlightedBoxDecoration
|
||||||
|
|||||||
Reference in New Issue
Block a user