선생님 위치 알리기 화면도 호출 화면처럼 가운데 최대 560 폭으로 제한

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-22 00:40:42 +00:00
co-authored by Claude Sonnet 5
parent cb0984ed6f
commit 1140747af2
+12 -1
View File
@@ -74,6 +74,12 @@ class _TeacherLocationScreenState extends State<TeacherLocationScreen> {
);
}
/// 넓은 화면(웹 데스크톱)에서 내용이 양옆으로 늘어지지 않게 가운데 최대 560 폭으로 맞춘다.
double _sidePad(BuildContext context) {
final width = MediaQuery.of(context).size.width;
return ((width - 560) / 2).clamp(16.0, double.infinity);
}
@override
Widget build(BuildContext context) {
return ListenableBuilder(
@@ -91,7 +97,12 @@ class _TeacherLocationScreenState extends State<TeacherLocationScreen> {
: RefreshIndicator(
onRefresh: _controller.fetchReceivedCalls,
child: ListView(
padding: const EdgeInsets.fromLTRB(16, 0, 16, 16),
padding: EdgeInsets.fromLTRB(
_sidePad(context),
0,
_sidePad(context),
16,
),
children: [
const Center(child: TitlePill('내 위치 알리기')),
const SizedBox(height: 16),