학생 계정 관리 화면 박스 크기 재조정

계정 추가/엑셀 등록 정사각형 칸은 기존 크기의 25%로 축소하고,
학생 목록 타일은 기존보다 50% 더 큰 정사각형으로 확대. 목록 폭은
더 이상 위 두 칸 폭에 종속되지 않고 전체 폭을 사용하도록 변경.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-01 00:42:05 +09:00
co-authored by Claude Sonnet 5
parent 517aa791b5
commit e9d31ce41e
+17 -12
View File
@@ -657,12 +657,12 @@ class _TeacherStudentManagementPageState
padding: const EdgeInsets.all(24.0),
child: LayoutBuilder(
builder: (context, constraints) {
// 🖥️ 웹(넓은 화면)은 계정 추가/엑셀 등록을 정사각형 2칸으로 나란히, 폰은 기존처럼 세로로 쌓는다.
// 🖥️ 웹(넓은 화면)은 계정 추가/엑셀 등록을 작은 정사각형 2칸으로 나란히, 폰은 기존처럼 세로로 쌓는다.
final bool isWide = constraints.maxWidth >= 800;
final double squareSize = (constraints.maxWidth - 20) / 2;
final double listWidth = isWide
? squareSize * 2 + 20
: constraints.maxWidth;
// 📉 계정 추가 / 엑셀 등록 칸: 기존 정사각형 크기의 25%로 축소.
final double formSquareSize =
((constraints.maxWidth - 20) / 2) * 0.25;
final double listWidth = constraints.maxWidth;
final Widget addBoxColumn = Column(
crossAxisAlignment: CrossAxisAlignment.start,
@@ -670,8 +670,8 @@ class _TeacherStudentManagementPageState
_sectionTitle('신규 학생 계정 추가'),
const SizedBox(height: 16),
SizedBox(
width: isWide ? squareSize : double.infinity,
height: isWide ? squareSize : null,
width: isWide ? formSquareSize : double.infinity,
height: isWide ? formSquareSize : null,
child: _buildAddAccountBox(),
),
],
@@ -683,8 +683,8 @@ class _TeacherStudentManagementPageState
_sectionTitle('엑셀로 한번에 추가 (신입생 등)'),
const SizedBox(height: 16),
SizedBox(
width: isWide ? squareSize : double.infinity,
height: isWide ? squareSize : 240,
width: isWide ? formSquareSize : double.infinity,
height: isWide ? formSquareSize : 240,
child: _buildExcelBox(),
),
],
@@ -760,12 +760,17 @@ class _TeacherStudentManagementPageState
: GridView.builder(
shrinkWrap: true,
physics: const NeverScrollableScrollPhysics(),
// 📈 학생 타일: 기존(8/4열 기준) 한 칸 폭보다 50% 더 큰 정사각형으로.
gridDelegate:
SliverGridDelegateWithFixedCrossAxisCount(
crossAxisCount: isWide ? 8 : 4,
SliverGridDelegateWithMaxCrossAxisExtent(
maxCrossAxisExtent:
((listWidth -
(isWide ? 7 : 3) * 10) /
(isWide ? 8 : 4)) *
1.5,
crossAxisSpacing: 10,
mainAxisSpacing: 10,
childAspectRatio: isWide ? 1.4 : 0.9,
childAspectRatio: 1,
),
itemCount: _controller.students.length,
itemBuilder: (context, index) =>