subjects rename

This commit is contained in:
ezyyeah
2022-12-31 00:45:10 +01:00
parent 35e5c9cdc6
commit 8bc695b70f
6 changed files with 47 additions and 17 deletions

View File

@@ -133,14 +133,18 @@ class LessonTile extends StatelessWidget {
contentPadding: const EdgeInsets.symmetric(horizontal: 4.0),
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(12.0)),
title: Text(
!lesson.isEmpty ? lesson.subject.name.capital() : "empty".i18n,
!lesson.isEmpty
? lesson.subject.renamedTo != null
? lesson.subject.renamedTo!
: lesson.subject.name.capital()
: "empty".i18n,
maxLines: 2,
overflow: TextOverflow.ellipsis,
style: TextStyle(
fontWeight: FontWeight.w600,
fontSize: 15.5,
color: AppColors.of(context).text.withOpacity(!lesson.isEmpty ? 1.0 : 0.5),
),
fontWeight: FontWeight.w600,
fontSize: 15.5,
color: AppColors.of(context).text.withOpacity(!lesson.isEmpty ? 1.0 : 0.5),
fontStyle: lesson.subject.renamedTo != null ? FontStyle.italic : null),
),
subtitle: description != ""
? Text(