Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
L
library-app-flutter
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ilham Maulana
library-app-flutter
Commits
511976a0
Commit
511976a0
authored
Jul 30, 2024
by
Ilham Maulana
💻
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: book detail layout
parent
d2603bdf
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
33 additions
and
3 deletions
+33
-3
book_detail.dart
lib/src/widgets/books/book_detail.dart
+33
-3
No files found.
lib/src/widgets/books/book_detail.dart
View file @
511976a0
...
...
@@ -2,7 +2,6 @@ import 'package:flutter/material.dart';
import
'package:library_app/src/models/book.dart'
;
import
'package:library_app/src/screens/detail_screen.dart'
;
import
'package:library_app/src/widgets/books/book_item.dart'
;
class
BookDetail
extends
StatefulWidget
{
final
Book
book
;
...
...
@@ -17,6 +16,8 @@ class _BookDetail extends State<BookDetail> {
@override
Widget
build
(
BuildContext
context
)
{
final
screenSize
=
MediaQuery
.
of
(
context
).
size
;
return
DetailScreen
(
title:
book
.
title
,
confirmMessage:
"Loans for how many days?"
,
...
...
@@ -24,8 +25,37 @@ class _BookDetail extends State<BookDetail> {
body:
Column
(
crossAxisAlignment:
CrossAxisAlignment
.
center
,
children:
[
BookItem
(
book
),
Text
(
book
.
description
),
ClipRRect
(
borderRadius:
BorderRadius
.
circular
(
13
),
child:
Image
.
network
(
book
.
coverUrl
??
""
,
height:
screenSize
.
height
*
0.4
,
),
),
Padding
(
padding:
const
EdgeInsets
.
only
(
top:
20.0
),
child:
Text
(
book
.
title
,
style:
Theme
.
of
(
context
).
textTheme
.
titleMedium
,
textAlign:
TextAlign
.
center
,
),
),
Text
(
'By
${book.author}
'
,
style:
Theme
.
of
(
context
).
textTheme
.
labelMedium
,
textAlign:
TextAlign
.
center
,
),
Text
(
book
.
category
??
""
,
style:
Theme
.
of
(
context
).
textTheme
.
labelSmall
,
),
Padding
(
padding:
const
EdgeInsets
.
symmetric
(
vertical:
10.0
),
child:
Text
(
book
.
description
,
style:
Theme
.
of
(
context
).
textTheme
.
labelLarge
,
),
)
],
),
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment