친구/그룹 스터디/백품타 랭킹 화면 폭 제한 (양옆으로 길게 늘어지던 것 수정)

백품타 랭킹, 그룹 스터디 목록은 최대 560px로(기존 대비 절반 느낌),
친구 목록은 최대 400px로(더 좁게, 1/3 느낌) 가운데 정렬되게 제한.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-30 06:10:30 +00:00
co-authored by Claude Sonnet 5
parent ae3a3f18ea
commit 153c341efc
3 changed files with 490 additions and 451 deletions
+14 -4
View File
@@ -163,7 +163,10 @@ class _FriendsScreenState extends State<FriendsScreen> {
), ),
body: _controller.isLoading body: _controller.isLoading
? const Center(child: CircularProgressIndicator()) ? const Center(child: CircularProgressIndicator())
: RefreshIndicator( : Center(
child: ConstrainedBox(
constraints: const BoxConstraints(maxWidth: 400),
child: RefreshIndicator(
onRefresh: _controller.refresh, onRefresh: _controller.refresh,
child: ListView( child: ListView(
padding: const EdgeInsets.fromLTRB(16, 0, 16, 90), padding: const EdgeInsets.fromLTRB(16, 0, 16, 90),
@@ -199,8 +202,10 @@ class _FriendsScreenState extends State<FriendsScreen> {
), ),
), ),
TextButton( TextButton(
onPressed: () => onPressed: () => _respond(
_respond(r['requestId'] as int, false), r['requestId'] as int,
false,
),
child: const Text( child: const Text(
'거절', '거절',
style: TextStyle(color: Colors.grey), style: TextStyle(color: Colors.grey),
@@ -220,7 +225,10 @@ class _FriendsScreenState extends State<FriendsScreen> {
), ),
const SizedBox(height: 20), const SizedBox(height: 20),
], ],
_sectionHeader('내 친구', count: _controller.friends.length), _sectionHeader(
'내 친구',
count: _controller.friends.length,
),
const SizedBox(height: 10), const SizedBox(height: 10),
if (_controller.friends.isEmpty) if (_controller.friends.isEmpty)
const Padding( const Padding(
@@ -282,6 +290,8 @@ class _FriendsScreenState extends State<FriendsScreen> {
], ],
), ),
), ),
),
),
); );
}, },
); );
+23 -7
View File
@@ -188,7 +188,10 @@ class _GroupListScreenState extends State<GroupListScreen> {
), ),
body: _controller.isLoading body: _controller.isLoading
? const Center(child: CircularProgressIndicator()) ? const Center(child: CircularProgressIndicator())
: RefreshIndicator( : Center(
child: ConstrainedBox(
constraints: const BoxConstraints(maxWidth: 560),
child: RefreshIndicator(
onRefresh: _controller.refresh, onRefresh: _controller.refresh,
child: ListView( child: ListView(
padding: const EdgeInsets.fromLTRB(16, 0, 16, 90), padding: const EdgeInsets.fromLTRB(16, 0, 16, 90),
@@ -249,7 +252,10 @@ class _GroupListScreenState extends State<GroupListScreen> {
), ),
const SizedBox(height: 20), const SizedBox(height: 20),
], ],
_sectionHeader('내 그룹', count: _controller.groups.length), _sectionHeader(
'내 그룹',
count: _controller.groups.length,
),
const SizedBox(height: 10), const SizedBox(height: 10),
if (_controller.groups.isEmpty) if (_controller.groups.isEmpty)
const Padding( const Padding(
@@ -275,7 +281,9 @@ class _GroupListScreenState extends State<GroupListScreen> {
border: Border.all(color: AppPalette.sage), border: Border.all(color: AppPalette.sage),
boxShadow: [ boxShadow: [
BoxShadow( BoxShadow(
color: Colors.black.withValues(alpha: 0.03), color: Colors.black.withValues(
alpha: 0.03,
),
blurRadius: 12, blurRadius: 12,
offset: const Offset(0, 4), offset: const Offset(0, 4),
), ),
@@ -308,9 +316,11 @@ class _GroupListScreenState extends State<GroupListScreen> {
Flexible( Flexible(
child: Text( child: Text(
'${g['name']}', '${g['name']}',
overflow: TextOverflow.ellipsis, overflow:
TextOverflow.ellipsis,
style: const TextStyle( style: const TextStyle(
fontWeight: FontWeight.bold, fontWeight:
FontWeight.bold,
fontSize: 15, fontSize: 15,
), ),
), ),
@@ -336,7 +346,9 @@ class _GroupListScreenState extends State<GroupListScreen> {
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.red[50], color: Colors.red[50],
borderRadius: borderRadius:
BorderRadius.circular(20), BorderRadius.circular(
20,
),
border: Border.all( border: Border.all(
color: Colors.red, color: Colors.red,
), ),
@@ -422,7 +434,9 @@ class _GroupListScreenState extends State<GroupListScreen> {
if (g['requested'] == true) if (g['requested'] == true)
Text( Text(
'신청됨', '신청됨',
style: TextStyle(color: Colors.grey[500]), style: TextStyle(
color: Colors.grey[500],
),
) )
else else
ElevatedButton( ElevatedButton(
@@ -441,6 +455,8 @@ class _GroupListScreenState extends State<GroupListScreen> {
], ],
), ),
), ),
),
),
); );
}, },
); );
+18 -5
View File
@@ -76,7 +76,10 @@ class _StudyRankingScreenState extends State<StudyRankingScreen> {
: '전체 공부 랭킹', : '전체 공부 랭킹',
), ),
), ),
body: Column( body: Center(
child: ConstrainedBox(
constraints: const BoxConstraints(maxWidth: 560),
child: Column(
children: [ children: [
Padding( Padding(
padding: const EdgeInsets.fromLTRB(16, 8, 16, 0), padding: const EdgeInsets.fromLTRB(16, 8, 16, 0),
@@ -131,10 +134,14 @@ class _StudyRankingScreenState extends State<StudyRankingScreen> {
vertical: 12, vertical: 12,
), ),
decoration: BoxDecoration( decoration: BoxDecoration(
color: isMe ? AppPalette.ink : AppPalette.paper, color: isMe
? AppPalette.ink
: AppPalette.paper,
borderRadius: BorderRadius.circular(14), borderRadius: BorderRadius.circular(14),
border: Border.all( border: Border.all(
color: isMe ? AppPalette.ink : AppPalette.sage, color: isMe
? AppPalette.ink
: AppPalette.sage,
), ),
), ),
child: Row( child: Row(
@@ -172,10 +179,14 @@ class _StudyRankingScreenState extends State<StudyRankingScreen> {
), ),
), ),
Text( Text(
_formatHM((r['totalSeconds'] as num).toInt()), _formatHM(
(r['totalSeconds'] as num).toInt(),
),
style: TextStyle( style: TextStyle(
fontWeight: FontWeight.bold, fontWeight: FontWeight.bold,
color: isMe ? Colors.white : AppPalette.ink, color: isMe
? Colors.white
: AppPalette.ink,
), ),
), ),
], ],
@@ -186,6 +197,8 @@ class _StudyRankingScreenState extends State<StudyRankingScreen> {
), ),
], ],
), ),
),
),
); );
}, },
); );