improvements

development-design-2.0
Sikander Saleem 3 years ago
parent d634729615
commit 3c56c4889c

@ -1,5 +1,5 @@
sdk.dir=/Users/sikandersaleem/Library/Android/sdk sdk.dir=/Users/sikandersaleem/Library/Android/sdk
flutter.sdk=/Users/sikandersaleem/sdks/flutter flutter.sdk=/Users/sikandersaleem/sdks/flutter
flutter.buildMode=profile flutter.buildMode=debug
flutter.versionName=1.0.0 flutter.versionName=1.0.0
flutter.versionCode=1 flutter.versionCode=1

@ -3,6 +3,7 @@ import 'package:tangheem/models/authentication_user_model.dart';
import 'package:tangheem/models/content_info_model.dart'; import 'package:tangheem/models/content_info_model.dart';
import 'package:tangheem/models/member_model.dart'; import 'package:tangheem/models/member_model.dart';
import 'package:tangheem/models/navigation_model.dart'; import 'package:tangheem/models/navigation_model.dart';
import 'package:tangheem/models/quick_links_model.dart';
import 'package:tangheem/models/surah_model.dart'; import 'package:tangheem/models/surah_model.dart';
class AppState { class AppState {
@ -73,4 +74,6 @@ class AppState {
List<ContentInfoDataModel> tareefAlMosasa; List<ContentInfoDataModel> tareefAlMosasa;
String tangheemDiscription; String tangheemDiscription;
List<QuickLinksData> quickLinks;
} }

@ -111,8 +111,11 @@ class _CommonHomeParentState extends State<CommonHomeParent> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
bool isPortrait = MediaQuery.of(context).orientation == Orientation.portrait;
return Scaffold( return Scaffold(
backgroundColor: Color(0xffF4F4F4), backgroundColor: Color(0xffF4F4F4),
resizeToAvoidBottomInset: true,
body: SafeArea( body: SafeArea(
bottom: true, bottom: true,
left: false, left: false,
@ -127,7 +130,7 @@ class _CommonHomeParentState extends State<CommonHomeParent> {
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
children: [ children: [
Container( Container(
height: 58, height: isPortrait ? 58 : 42,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(29.0), borderRadius: BorderRadius.circular(29.0),
color: Colors.white, color: Colors.white,
@ -136,12 +139,12 @@ class _CommonHomeParentState extends State<CommonHomeParent> {
padding: EdgeInsets.only(left: 30, right: 30), padding: EdgeInsets.only(left: 30, right: 30),
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [for (int i = 0; i < icons.length; i++) getBottomNavigationItem(i)], children: [for (int i = 0; i < icons.length; i++) getBottomNavigationItem(i, isPortrait ? 0 : 6)],
), ),
), ),
Container( Container(
height: 26, height: 26,
margin: EdgeInsets.only(top: 16), margin: EdgeInsets.only(top: isPortrait ? 16 : 8),
padding: EdgeInsets.only(right: 16, left: 12), padding: EdgeInsets.only(right: 16, left: 12),
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(29.0), borderRadius: BorderRadius.circular(29.0),
@ -178,21 +181,21 @@ class _CommonHomeParentState extends State<CommonHomeParent> {
]; ];
List<double> sizes = [26, 26, 36, 26, 26]; List<double> sizes = [26, 26, 36, 26, 26];
Widget getBottomNavigationItem(int _index) { Widget getBottomNavigationItem(int _index, int minusValue) {
return Column( return Column(
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
children: [ children: [
SvgPicture.asset( SvgPicture.asset(
icons[_index], icons[_index],
width: sizes[_index], width: sizes[_index] - minusValue,
height: sizes[_index], height: sizes[_index] - minusValue,
color: index == _index ? ColorConsts.brownColor : ColorConsts.darkText, color: index == _index ? ColorConsts.brownColor : ColorConsts.darkText,
).expanded, ).expanded,
if (index == _index) if (index == _index)
Container( Container(
height: 3, height: 3,
color: ColorConsts.brownColor, color: ColorConsts.brownColor,
width: sizes[_index], width: sizes[_index] - minusValue,
), ),
], ],
).onPress(() { ).onPress(() {

@ -15,12 +15,14 @@ import 'package:tangheem/extensions/string_extensions.dart';
import 'package:tangheem/extensions/widget_extensions.dart'; import 'package:tangheem/extensions/widget_extensions.dart';
import 'package:tangheem/models/aya_tangheem_type.dart'; import 'package:tangheem/models/aya_tangheem_type.dart';
import 'package:tangheem/models/content_info_model.dart'; import 'package:tangheem/models/content_info_model.dart';
import 'package:tangheem/models/quick_links_model.dart';
import 'package:tangheem/models/surah_model.dart'; import 'package:tangheem/models/surah_model.dart';
import 'package:tangheem/models/tangheem_type_model.dart'; import 'package:tangheem/models/tangheem_type_model.dart';
import 'package:tangheem/ui/dialogs/general_dialog.dart'; import 'package:tangheem/ui/dialogs/general_dialog.dart';
import 'package:tangheem/ui/screens/tangheem_screen.dart'; import 'package:tangheem/ui/screens/tangheem_screen.dart';
import 'package:tangheem/widgets/common_dropdown_button.dart'; import 'package:tangheem/widgets/common_dropdown_button.dart';
import 'package:tangheem/widgets/video_player_widget.dart'; import 'package:tangheem/widgets/video_player_widget.dart';
import 'package:url_launcher/url_launcher.dart';
class HomeScreen extends StatefulWidget { class HomeScreen extends StatefulWidget {
static const String routeName = "/"; static const String routeName = "/";
@ -46,6 +48,7 @@ class _HomeScreenState extends State<HomeScreen> {
SurahModel _surahModel; SurahModel _surahModel;
TangheemType _tangheemType; TangheemType _tangheemType;
String _tangheemDiscription; String _tangheemDiscription;
List<QuickLinksData> quickLinks;
@override @override
void initState() { void initState() {
@ -65,6 +68,15 @@ class _HomeScreenState extends State<HomeScreen> {
_tangheemDiscription = AppState().tangheemDiscription; _tangheemDiscription = AppState().tangheemDiscription;
} }
if (AppState().quickLinks == null) {
quickLinks = (await TangheemUserApiClient().quickLinks())?.data ?? [];
quickLinks = quickLinks.where((element) => element.position == "down").toList();
quickLinks.sort((a, b) => a.orderNo.compareTo(b.orderNo));
AppState().quickLinks = quickLinks;
} else {
quickLinks = AppState().quickLinks;
}
if (AppState().getSurahModel == null) { if (AppState().getSurahModel == null) {
_surahModel = await TangheemUserApiClient().getSurahs(); _surahModel = await TangheemUserApiClient().getSurahs();
AppState().setSurahModel(_surahModel); AppState().setSurahModel(_surahModel);
@ -185,6 +197,8 @@ class _HomeScreenState extends State<HomeScreen> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
bool isPortrait = MediaQuery.of(context).orientation == Orientation.portrait;
return SizedBox( return SizedBox(
width: double.infinity, width: double.infinity,
child: Stack( child: Stack(
@ -193,10 +207,11 @@ class _HomeScreenState extends State<HomeScreen> {
"assets/icons/new/home_light.jpg", "assets/icons/new/home_light.jpg",
fit: BoxFit.cover, fit: BoxFit.cover,
height: double.infinity, height: double.infinity,
width: double.infinity,
opacity: const AlwaysStoppedAnimation(.73), opacity: const AlwaysStoppedAnimation(.73),
), ),
SingleChildScrollView( SingleChildScrollView(
padding: EdgeInsets.fromLTRB(45, 138, 45, 138), padding: EdgeInsets.fromLTRB(45, isPortrait ? 138 : 45, 45, 138),
physics: BouncingScrollPhysics(), physics: BouncingScrollPhysics(),
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.center, crossAxisAlignment: CrossAxisAlignment.center,
@ -282,14 +297,14 @@ class _HomeScreenState extends State<HomeScreen> {
child: TextField( child: TextField(
controller: _searchController, controller: _searchController,
focusNode: _searchFocusNode, focusNode: _searchFocusNode,
style: TextStyle(color: Colors.white, fontSize: 14), style: TextStyle(color: Colors.white, fontSize: 14,fontFamily: "Montserrat"),
textAlign: TextAlign.end, textAlign: TextAlign.end,
decoration: InputDecoration( decoration: InputDecoration(
contentPadding: EdgeInsets.fromLTRB(2, 2, 24, 2), contentPadding: EdgeInsets.fromLTRB(2, 2, 24, 2),
alignLabelWithHint: true, alignLabelWithHint: true,
fillColor: ColorConsts.darkText.withOpacity(.65), fillColor: ColorConsts.darkText.withOpacity(.65),
filled: true, filled: true,
hintStyle: TextStyle(color: Colors.white, fontSize: 14), hintStyle: TextStyle(color: Colors.white, fontSize: 14,fontFamily: "Montserrat"),
hintText: "البحث عن آية", hintText: "البحث عن آية",
prefixIconConstraints: BoxConstraints(maxHeight: 20), prefixIconConstraints: BoxConstraints(maxHeight: 20),
prefixIcon: InkWell( prefixIcon: InkWell(
@ -324,7 +339,21 @@ class _HomeScreenState extends State<HomeScreen> {
), ),
), ),
), ),
) ),
30.height,
"شارك هذه الصفحة".toText(13, color: Color(0xffa2a2a2)),
30.height,
if(quickLinks!=null && quickLinks.isNotEmpty)
Row(
children: [
for (QuickLinksData _quickLink in quickLinks)
commonIconButton(ApiConsts.baseUrl + _quickLink.exposeFilePath, () {
//for live production server
// commonIconButton( _quickLink.exposeFilePath, () {
_launchURL(_quickLink.imageUrl);
}, size: 35, isAsset: false),
],
),
], ],
), ),
), ),
@ -333,6 +362,20 @@ class _HomeScreenState extends State<HomeScreen> {
); );
} }
void _launchURL(String _url) async => await canLaunch(_url) ? await launch(_url) : throw 'Could not launch $_url';
Widget commonIconButton(String icon, VoidCallback onPressed, {double size, bool isAsset = true}) {
return Expanded(
child: IconButton(
padding: EdgeInsets.zero,
icon: isAsset ? SvgPicture.asset(icon, height: size ?? 25, width: size ?? 30) : Image.network(icon, height: size ?? 25, width: size ?? 30),
onPressed: () {
Navigator.pop(context);
Future.delayed(Duration(milliseconds: 200), () => onPressed());
}),
);
}
Widget iconButton(String title, String icon, VoidCallback callback) { Widget iconButton(String title, String icon, VoidCallback callback) {
return InkWell( return InkWell(
splashColor: Colors.transparent, splashColor: Colors.transparent,

@ -21,6 +21,8 @@ class AppMenuDialog extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
bool isPortrait = MediaQuery.of(context).orientation == Orientation.portrait;
return BackdropFilter( return BackdropFilter(
filter: ImageFilter.blur(sigmaX: 4, sigmaY: 4), filter: ImageFilter.blur(sigmaX: 4, sigmaY: 4),
child: Dialog( child: Dialog(
@ -32,61 +34,64 @@ class AppMenuDialog extends StatelessWidget {
backgroundColor: Colors.transparent, backgroundColor: Colors.transparent,
child: Container( child: Container(
width: MediaQuery.of(context).size.width * 245 / 375, width: MediaQuery.of(context).size.width * 245 / 375,
padding: EdgeInsets.all(12),
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.white.withOpacity(.91), color: Colors.white.withOpacity(.91),
borderRadius: BorderRadius.circular(20), borderRadius: BorderRadius.circular(20),
), ),
child: Column( child: SingleChildScrollView(
mainAxisSize: MainAxisSize.min, padding: EdgeInsets.all(12),
children: [ physics: BouncingScrollPhysics(),
58.height, child: Column(
menuItem("الرئيسية", "assets/icons/new/home.svg", 0), mainAxisSize: MainAxisSize.min,
Container(width: 50, height: 1, color: ColorConsts.greyB5Color).paddingOnly(top: 16, bottom: 16), children: [
menuItem("عن الموسوعة", "assets/icons/new/intro.svg", 1), isPortrait ? 58.height : 24.height,
Container(width: 50, height: 1, color: ColorConsts.greyB5Color).paddingOnly(top: 16, bottom: 16), menuItem("الرئيسية", "assets/icons/new/home.svg", 0),
menuItem("اللجنة الإشرافية", "assets/icons/new/members.svg", 4), Container(width: 50, height: 1, color: ColorConsts.greyB5Color).paddingOnly(top: 16, bottom: 16),
Container(width: 50, height: 1, color: ColorConsts.greyB5Color).paddingOnly(top: 16, bottom: 16), menuItem("عن الموسوعة", "assets/icons/new/intro.svg", 1),
menuItem("قراءة القرآن الكريم", "assets/icons/new/quran.svg", 2), Container(width: 50, height: 1, color: ColorConsts.greyB5Color).paddingOnly(top: 16, bottom: 16),
Row( menuItem("اللجنة الإشرافية", "assets/icons/new/members.svg", 4),
mainAxisSize: MainAxisSize.min, Container(width: 50, height: 1, color: ColorConsts.greyB5Color).paddingOnly(top: 16, bottom: 16),
children: [ menuItem("قراءة القرآن الكريم", "assets/icons/new/quran.svg", 2),
menuOptions("assets/icons/new/bookmark.svg").onPress(() { Row(
Navigator.pop(context); mainAxisSize: MainAxisSize.min,
Navigator.pushNamed(context, BookmarkScreen.routeName);
}),
14.width,
menuOptions("assets/icons/new/zoom_in.svg").onPress(onFontIncrease),
14.width,
menuOptions("assets/icons/new/zoom_out.svg").onPress(onFontDecrease),
14.width,
menuOptions("assets/icons/new/user_acount.svg").onPress(() {
Navigator.pop(context);
if (AppState().isUserLogin) {
Navigator.pushNamed(context, UserProfileScreen.routeName);
} else
Navigator.pushNamed(context, LoginScreen.routeName);
}),
],
).paddingOnly(top: 32, bottom: 32),
Container(
height: 26,
padding: EdgeInsets.only(right: 16, left: 12),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(32.0),
color: ColorConsts.brownLightColor,
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [ children: [
Icon(Icons.play_arrow_outlined, size: 20, color: Colors.white), menuOptions("assets/icons/new/bookmark.svg").onPress(() {
"تصفح وتحميل الموسوعة".toText(13), Navigator.pop(context);
Navigator.pushNamed(context, BookmarkScreen.routeName);
}),
14.width,
menuOptions("assets/icons/new/zoom_in.svg").onPress(onFontIncrease),
14.width,
menuOptions("assets/icons/new/zoom_out.svg").onPress(onFontDecrease),
14.width,
menuOptions("assets/icons/new/user_acount.svg").onPress(() {
Navigator.pop(context);
if (AppState().isUserLogin) {
Navigator.pushNamed(context, UserProfileScreen.routeName);
} else
Navigator.pushNamed(context, LoginScreen.routeName);
}),
], ],
), ).paddingOnly(top: 32, bottom: 32),
).onPress(() { Container(
goToIndex(5); height: 26,
}) padding: EdgeInsets.only(right: 16, left: 12),
], decoration: BoxDecoration(
borderRadius: BorderRadius.circular(32.0),
color: ColorConsts.brownLightColor,
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Icon(Icons.play_arrow_outlined, size: 20, color: Colors.white),
"تصفح وتحميل الموسوعة".toText(13),
],
),
).onPress(() {
goToIndex(5);
})
],
),
), ),
), ),
), ),

@ -52,6 +52,8 @@ class _ContactUsScreenState extends State<ContactUsScreen> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
bool isPortrait = MediaQuery.of(context).orientation == Orientation.portrait;
return Scaffold( return Scaffold(
backgroundColor: ColorConsts.greyF4Color, backgroundColor: ColorConsts.greyF4Color,
body: SingleChildScrollView( body: SingleChildScrollView(

@ -84,13 +84,15 @@ class _LoginScreenState extends State<LoginScreen> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
bool isPortrait = MediaQuery.of(context).orientation == Orientation.portrait;
return Scaffold( return Scaffold(
backgroundColor: ColorConsts.darkText, backgroundColor: ColorConsts.darkText,
body: SafeArea( body: SafeArea(
child: Directionality( child: Directionality(
textDirection: TextDirection.rtl, textDirection: TextDirection.rtl,
child: SingleChildScrollView( child: SingleChildScrollView(
padding: EdgeInsets.only(top: 140, bottom: 50, left: 40, right: 40), padding: EdgeInsets.only(top: isPortrait ? 140 : 40, bottom: 50, left: 40, right: 40),
physics: BouncingScrollPhysics(), physics: BouncingScrollPhysics(),
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.center, crossAxisAlignment: CrossAxisAlignment.center,

@ -1,7 +1,11 @@
import 'dart:async';
import 'dart:io';
import 'dart:ui'; import 'dart:ui';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart'; import 'package:flutter_svg/flutter_svg.dart';
import 'package:path_provider/path_provider.dart';
import 'package:syncfusion_flutter_pdfviewer/pdfviewer.dart'; import 'package:syncfusion_flutter_pdfviewer/pdfviewer.dart';
import 'package:tangheem/api/tangheem_user_api_client.dart'; import 'package:tangheem/api/tangheem_user_api_client.dart';
import 'package:tangheem/app_state/app_state.dart'; import 'package:tangheem/app_state/app_state.dart';
@ -85,6 +89,7 @@ class _PdfListScreenState extends State<PdfListScreen> {
height: double.infinity, height: double.infinity,
child: SingleChildScrollView( child: SingleChildScrollView(
physics: const AlwaysScrollableScrollPhysics(), physics: const AlwaysScrollableScrollPhysics(),
padding: EdgeInsets.only(bottom: 140),
child: Column( child: Column(
children: [ children: [
CommonHeader("التصفح والتحميل", "assets/icons/new/pdf_bg.jpg", Color(0xffAE8646)), CommonHeader("التصفح والتحميل", "assets/icons/new/pdf_bg.jpg", Color(0xffAE8646)),
@ -178,21 +183,17 @@ class PdfViewerScreen extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Column( return SfPdfViewer.network(
children: [ ApiConsts.baseUrl + pdfDetail.exposeFilePath,
CommonHeader(pdfDetail.fileName, "assets/icons/new/pdf_bg.jpg", Color(0xffAE8646)), key: _pdfViewerKey,
SfPdfViewer.network( canShowScrollHead: false,
ApiConsts.baseUrl + pdfDetail.exposeFilePath, enableTextSelection: false,
key: _pdfViewerKey, enableDocumentLinkAnnotation: false,
canShowScrollHead: false, canShowPaginationDialog: false,
enableTextSelection: false, canShowScrollStatus: false,
enableDocumentLinkAnnotation: false, pageSpacing: 0,
canShowPaginationDialog: false, // pageLayoutMode:PdfPageLayoutMode.single
canShowScrollStatus: false,
pageSpacing: 0,
// pageLayoutMode:PdfPageLayoutMode.single
).expanded,
],
); );
} }
} }

@ -187,6 +187,8 @@ class _QuranScreenState extends State<QuranScreen> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
bool isPortrait = MediaQuery.of(context).orientation == Orientation.portrait;
var tempList = _ayaModel?.data?.map((e) => e.surahNameAR)?.toList()?.toSet()?.toList() ?? []; var tempList = _ayaModel?.data?.map((e) => e.surahNameAR)?.toList()?.toSet()?.toList() ?? [];
String _surahName = ""; String _surahName = "";
_surahName = tempList.isEmpty ? "" : tempList?.last ?? ""; _surahName = tempList.isEmpty ? "" : tempList?.last ?? "";
@ -413,7 +415,7 @@ class _QuranScreenState extends State<QuranScreen> {
// } // }
multiModeView = SingleChildScrollView( multiModeView = SingleChildScrollView(
padding: EdgeInsets.fromLTRB(24, 96, 24, 140), padding: EdgeInsets.fromLTRB(24, isPortrait ? 96 : 50, 24, 140),
physics: BouncingScrollPhysics(), physics: BouncingScrollPhysics(),
child: Column(children: finalViewList), child: Column(children: finalViewList),
); );
@ -422,9 +424,16 @@ class _QuranScreenState extends State<QuranScreen> {
width: double.infinity, width: double.infinity,
child: Stack( child: Stack(
children: [ children: [
AspectRatio( SizedBox(
aspectRatio: 375 / 345, width: double.infinity,
child: Image.asset("assets/icons/new/quran_bg.jpg", fit: BoxFit.cover, alignment: Alignment(-0.7, 0.5)), child: AspectRatio(
aspectRatio: 375 / 345,
child: Image.asset(
"assets/icons/new/quran_bg.jpg",
fit: BoxFit.cover,
alignment: Alignment(-0.7, 0.5),
),
),
), ),
multiModeView multiModeView
], ],

@ -452,7 +452,7 @@ class _TangheemDetailScreenState extends State<TangheemDetailScreen> {
), ),
), ),
), ),
if (MediaQuery.of(context).orientation == Orientation.portrait) // if (MediaQuery.of(context).orientation == Orientation.portrait)
AyaPlayerWidget( AyaPlayerWidget(
surahName: _ayatTangheemTypeMappedFirstData?.surahNameAr ?? "", surahName: _ayatTangheemTypeMappedFirstData?.surahNameAr ?? "",
ayaTangheemTypeId: _ayatTangheemTypeMappedFirstData?.tangheemTypeId ?? "", ayaTangheemTypeId: _ayatTangheemTypeMappedFirstData?.tangheemTypeId ?? "",
@ -470,7 +470,7 @@ class _TangheemDetailScreenState extends State<TangheemDetailScreen> {
], ],
), ),
), ),
if (MediaQuery.of(context).orientation == Orientation.landscape) if (false)
Column( Column(
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,

@ -112,23 +112,29 @@ class _TangheemScreenState extends State<TangheemScreen> {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return _dataList == null return _dataList == null
? SizedBox() ? SizedBox()
: Stack( : ListView(
controller: _controller,
//physics: BouncingScrollPhysics(),
children: [ children: [
Stack( Stack(
alignment: Alignment.center, alignment: Alignment.center,
children: [ children: [
AspectRatio( SizedBox(
aspectRatio: 375 / 215, // height: double.infinity,
child: Image.asset("assets/icons/new/quran_bg.jpg", fit: BoxFit.cover, alignment: Alignment(-0.3, 0.5)), width: double.infinity,
child: AspectRatio(
aspectRatio: 375 / 215,
child: Image.asset("assets/icons/new/quran_bg.jpg", fit: BoxFit.cover, alignment: Alignment(-0.3, 0.5)),
),
), ),
Column( Column(
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
children: [ children: [
Image.asset('assets/icons/new/Tangeem-logo-W.png', width: 50), Image.asset('assets/icons/new/Tangeem-logo-W.png', width: 50),
26.height, 26.height,
widget.tangheemTypeName.toText(30), (widget.tangheemTypeName ?? "").toText(30),
8.height, 8.height,
"${widget.surah.nameAR}".toText(12, color: ColorConsts.brownB6CColor), "${widget.surah?.nameAR ?? ""}".toText(12, color: ColorConsts.brownB6CColor),
], ],
).paddingOnly(top: 16), ).paddingOnly(top: 16),
], ],
@ -136,9 +142,11 @@ class _TangheemScreenState extends State<TangheemScreen> {
_dataList.isEmpty _dataList.isEmpty
? NoDataUI().paddingOnly(top: 215) ? NoDataUI().paddingOnly(top: 215)
: ListView.separated( : ListView.separated(
controller: _controller, // controller: _controller,
physics: BouncingScrollPhysics(), // physics: BouncingScrollPhysics(),
padding: EdgeInsets.only(left: 24, right: 24, top: 215, bottom: 138), physics: NeverScrollableScrollPhysics(),
shrinkWrap: true,
padding: EdgeInsets.only(left: 24, right: 24, top: 24, bottom: 24),
itemCount: _dataList.length, itemCount: _dataList.length,
separatorBuilder: (context, index) { separatorBuilder: (context, index) {
return SizedBox(height: 12); return SizedBox(height: 12);

@ -102,6 +102,8 @@ class _AyaRecordWidgetState extends State<AyaRecordWidget> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
bool isPortrait = MediaQuery.of(context).orientation == Orientation.portrait;
return Column( return Column(
children: [ children: [
Container( Container(
@ -229,8 +231,8 @@ class _AyaRecordWidgetState extends State<AyaRecordWidget> {
}, },
child: Container( child: Container(
height: 31, height: 31,
width: 125, width: 135,
padding: EdgeInsets.only(left: 24, right: 24), padding: EdgeInsets.only(left: 12, right: 12),
alignment: Alignment.center, alignment: Alignment.center,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(20), borderRadius: BorderRadius.circular(20),

@ -26,7 +26,7 @@ class CommonDropDownButton extends StatelessWidget {
child: Container( child: Container(
height: 48, height: 48,
decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(10), border: Border.all(color: ColorConsts.brownColor, width: .5)), decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(10), border: Border.all(color: ColorConsts.brownColor, width: .5)),
padding: EdgeInsets.fromLTRB(24, 15, 24, 15), padding: EdgeInsets.fromLTRB(24, 12, 24, 12),
child: DropdownButtonHideUnderline( child: DropdownButtonHideUnderline(
child: DropdownButton<int>( child: DropdownButton<int>(
isExpanded: isDropDown, isExpanded: isDropDown,
@ -52,7 +52,7 @@ class CommonDropDownButton extends StatelessWidget {
(list.isEmpty || index < 0) ? hintText : list[index], (list.isEmpty || index < 0) ? hintText : list[index],
maxLines: 1, maxLines: 1,
overflow: TextOverflow.ellipsis, overflow: TextOverflow.ellipsis,
style: TextStyle(fontSize: 14, color: ColorConsts.brownColor), style: TextStyle(fontSize: 14, color: ColorConsts.brownColor, height: 14 / 17),
), ),
], ],
), ),

@ -54,7 +54,6 @@ dependencies:
flutter_html: ^2.2.1 flutter_html: ^2.2.1
flutter_inappwebview: ^5.7.2+3 flutter_inappwebview: ^5.7.2+3
dotted_border: ^2.0.0+1 dotted_border: ^2.0.0+1
dev_dependencies: dev_dependencies:
flutter_test: flutter_test:
sdk: flutter sdk: flutter

Loading…
Cancel
Save