Dark / light Mode added

This commit is contained in:
Surendiran 2025-06-24 11:06:42 +05:30
parent 60d9a4f161
commit a109e65c11
50 changed files with 2110 additions and 1254 deletions

View File

@ -2,27 +2,27 @@ C/C++ Structured Log}
{ {
y/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/additional_project_files.txtC y/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/additional_project_files.txtC
A A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ÕÞ„„ñ2  ˜÷îƒñ2z ?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  <EFBFBD>ùÓÁ÷2  ¡¹ñÀ÷2z
x x
v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/android_gradle_build.json  ÕÞ„„ñ2 œ÷îƒñ2 v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/android_gradle_build.json  ƒùÓÁ÷2 £¹ñÀ÷2
} }
{/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/android_gradle_build_mini.json  ÕÞ„„ñ2ƒ  ÷îƒñ2l {/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/android_gradle_build_mini.json  ƒùÓÁ÷2ƒ ¥¹ñÀ÷2l
j j
h/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/build.ninja  ÕÞ„„ñ2êÌ ÷öîƒñ2p h/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/build.ninja  ƒùÓÁ÷2êÌ ޹ñÀ÷2p
n n
l/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/build.ninja.txt  ÕÞ„„ñ2u l/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/build.ninja.txt  ƒùÓÁ÷2u
s s
q/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/build_file_index.txt  ÕÞ„„ñ2 _ ¡÷îƒñ2v q/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/build_file_index.txt  ƒùÓÁ÷2 _ ¦¹ñÀ÷2v
t t
r/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/compile_commands.json  ÕÞ„„ñ2z r/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/compile_commands.json  ƒùÓÁ÷2z
x x
v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/compile_commands.json.bin  ÕÞ„„ñ2 v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/compile_commands.json.bin  ƒùÓÁ÷2
~ ~
|/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/metadata_generation_command.txt  ÕÞ„„ñ2 |/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/metadata_generation_command.txt  ƒùÓÁ÷2
ö ¡÷îƒñ2s ö ¦¹ñÀ÷2s
q q
o/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/prefab_config.json  ÕÞ„„ñ2  ( ¡÷îƒñ2x o/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/prefab_config.json  ƒùÓÁ÷2  ( ¦¹ñÀ÷2x
v v
t/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/symbol_folder_index.txt  ÕÞ„„ñ2  k ¡÷îƒñ2c t/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/arm64-v8a/symbol_folder_index.txt  ƒùÓÁ÷2  k ¦¹ñÀ÷2c
a a
_/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  ÕÞ„„ñ2 ¤ òÑÞ€á2 _/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  ƒùÓÁ÷2 ¤ òÑÞ€á2

View File

@ -2,27 +2,27 @@ C/C++ Structured Log
} }
{/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/additional_project_files.txtC {/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/additional_project_files.txtC
A A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  àÞ„„ñ2  ÎÜðƒñ2| ?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  <EFBFBD>ùÓÁ÷2  ¸ïòÀ÷2|
z z
x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/android_gradle_build.json  àÞ„„ñ2 ÑÜðƒñ2<EFBFBD> x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/android_gradle_build.json  <EFBFBD>ùÓÁ÷2 ºïòÀ÷2<EFBFBD>
 
}/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/android_gradle_build_mini.json  àÞ„„ñ2 ÒÜðƒñ2n }/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/android_gradle_build_mini.json  <EFBFBD>ùÓÁ÷2 »ïòÀ÷2n
l l
j/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/build.ninja  àÞ„„ñ2öÌ »Üðƒñ2r j/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/build.ninja  <EFBFBD>ùÓÁ÷2öÌ ªïòÀ÷2r
p p
n/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/build.ninja.txt  àÞ„„ñ2w n/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/build.ninja.txt  <EFBFBD>ùÓÁ÷2w
u u
s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/build_file_index.txt  àÞ„„ñ2 _ ÓÜðƒñ2x s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/build_file_index.txt  <EFBFBD>ùÓÁ÷2 _ »ïòÀ÷2x
v v
t/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/compile_commands.json  àÞ„„ñ2| t/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/compile_commands.json  <EFBFBD>ùÓÁ÷2|
z z
x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/compile_commands.json.bin  àÞ„„ñ2 ƒ x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/compile_commands.json.bin  <EFBFBD>ùÓÁ÷2 ƒ
 
~/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/metadata_generation_command.txt  àÞ„„ñ2 ~/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/metadata_generation_command.txt  <EFBFBD>ùÓÁ÷2
ÓÜðƒñ2u »ïòÀ÷2u
s s
q/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/prefab_config.json  àÞ„„ñ2  ( ÓÜðƒñ2z q/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/prefab_config.json  <EFBFBD>ùÓÁ÷2  ( »ïòÀ÷2z
x x
v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/symbol_folder_index.txt  àÞ„„ñ2  m ÓÜðƒñ2c v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/armeabi-v7a/symbol_folder_index.txt  <EFBFBD>ùÓÁ÷2  m »ïòÀ÷2c
a a
_/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  àÞ„„ñ2 ¤ òÑÞ€á2 _/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  <EFBFBD>ùÓÁ÷2 ¤ òÑÞ€á2

View File

@ -2,27 +2,27 @@ C/C++ Structured Logw
u u
s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/additional_project_files.txtC s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/additional_project_files.txtC
A A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  æÞ„„ñ2  Ñßðƒñ2t ?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ˜ùÓÁ÷2  „òòÀ÷2t
r r
p/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/android_gradle_build.json  æÞ„„ñ2ô Òßðƒñ2y p/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/android_gradle_build.json  ˜ùÓÁ÷2ô „òòÀ÷2y
w w
u/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/android_gradle_build_mini.json  æÞ„„ñ2÷ Óßðƒñ2f u/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/android_gradle_build_mini.json  ˜ùÓÁ÷2÷ …òòÀ÷2f
d d
b/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/build.ninja  æÞ„„ñ2ÆÌ Äßðƒñ2j b/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/build.ninja  ˜ùÓÁ÷2ÆÌ ûñòÀ÷2j
h h
f/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/build.ninja.txt  æÞ„„ñ2o f/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/build.ninja.txt  ˜ùÓÁ÷2o
m m
k/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/build_file_index.txt  æÞ„„ñ2 _ Óßðƒñ2p k/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/build_file_index.txt  ˜ùÓÁ÷2 _ …òòÀ÷2p
n n
l/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/compile_commands.json  æÞ„„ñ2t l/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/compile_commands.json  ˜ùÓÁ÷2t
r r
p/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/compile_commands.json.bin  æÞ„„ñ2 z p/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/compile_commands.json.bin  ˜ùÓÁ÷2 z
x x
v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/metadata_generation_command.txt  æÞ„„ñ2 v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/metadata_generation_command.txt  ˜ùÓÁ÷2
Ø Óßðƒñ2m Ø …òòÀ÷2m
k k
i/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/prefab_config.json  æÞ„„ñ2  ( Óßðƒñ2r i/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/prefab_config.json  ˜ùÓÁ÷2  ( …òòÀ÷2r
p p
n/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/symbol_folder_index.txt  æÞ„„ñ2  e Óßðƒñ2c n/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86/symbol_folder_index.txt  ˜ùÓÁ÷2  e …òòÀ÷2c
a a
_/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  æÞ„„ñ2 ¤ òÑÞ€á2 _/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  ˜ùÓÁ÷2 ¤ òÑÞ€á2

View File

@ -2,27 +2,27 @@ C/C++ Structured Logz
x x
v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/additional_project_files.txtC v/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/additional_project_files.txtC
A A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  êÞ„„ñ2  ýáðƒñ2w ?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  žùÓÁ÷2  •ôòÀ÷2w
u u
s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/android_gradle_build.json  êÞ„„ñ2ú ÿáðƒñ2| s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/android_gradle_build.json  žùÓÁ÷2ú •ôòÀ÷2|
z z
x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/android_gradle_build_mini.json  êÞ„„ñ2ý €âðƒñ2i x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/android_gradle_build_mini.json  žùÓÁ÷2ý –ôòÀ÷2i
g g
e/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/build.ninja  êÞ„„ñ2ØÌ òáðƒñ2m e/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/build.ninja  žùÓÁ÷2ØÌ <20>ôòÀ÷2m
k k
i/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/build.ninja.txt  êÞ„„ñ2r i/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/build.ninja.txt  žùÓÁ÷2r
p p
n/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/build_file_index.txt  êÞ„„ñ2 _ €âðƒñ2s n/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/build_file_index.txt  žùÓÁ÷2 _ –ôòÀ÷2s
q q
o/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/compile_commands.json  êÞ„„ñ2w o/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/compile_commands.json  žùÓÁ÷2w
u u
s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/compile_commands.json.bin  êÞ„„ñ2 } s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/compile_commands.json.bin  žùÓÁ÷2 }
{ {
y/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/metadata_generation_command.txt  êÞ„„ñ2 y/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/metadata_generation_command.txt  žùÓÁ÷2
ç €âðƒñ2p ç –ôòÀ÷2p
n n
l/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/prefab_config.json  êÞ„„ñ2  ( €âðƒñ2u l/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/prefab_config.json  žùÓÁ÷2  ( –ôòÀ÷2u
s s
q/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/symbol_folder_index.txt  êÞ„„ñ2  h €âðƒñ2c q/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/Debug/4y161to1/x86_64/symbol_folder_index.txt  žùÓÁ÷2  h –ôòÀ÷2c
a a
_/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  êÞ„„ñ2 ¤ òÑÞ€á2 _/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  žùÓÁ÷2 ¤ òÑÞ€á2

View File

@ -2,27 +2,27 @@ C/C++ Structured Log
 
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/additional_project_files.txtC /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/additional_project_files.txtC
A A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  öÃæšö2  ™ªÇŸô2„ ?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  µ§Ä‚ú2  ™ªÇŸô2„
<EFBFBD> <EFBFBD>
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/android_gradle_build.json  öÃæšö2 œªÇŸô2Š /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/android_gradle_build.json  µ§Ä‚ú2 œªÇŸô2Š
 
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/android_gradle_build_mini.json  öÃæšö2 ¤ªÇŸô2u /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/android_gradle_build_mini.json  µ§Ä‚ú2 ¤ªÇŸô2u
s s
q/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/build.ninja  öÃæšö2²Í ù©ÇŸô2y q/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/build.ninja  µ§Ä‚ú2²Í ù©ÇŸô2y
w w
u/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/build.ninja.txt  öÃæšö2~ u/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/build.ninja.txt  µ§Ä‚ú2~
| |
z/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/build_file_index.txt  öÃæšö2 _ ¥ªÇŸô2 z/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/build_file_index.txt  µ§Ä‚ú2 _ ¥ªÇŸô2
} }
{/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/compile_commands.json  öÃæšö2 {/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/compile_commands.json  µ§Ä‚ú2
<EFBFBD> <EFBFBD>
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/compile_commands.json.bin  öÃæšö2  /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/compile_commands.json.bin  µ§Ä‚ú2 
ˆ ˆ
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/metadata_generation_command.txt  öÃæšö2 /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/metadata_generation_command.txt  µ§Ä‚ú2
š ¥ªÇŸô2| š ¥ªÇŸô2|
z z
x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/prefab_config.json  öÃæšö2  ( ¥ªÇŸô2<C3B4> x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/prefab_config.json  µ§Ä‚ú2  ( ¥ªÇŸô2<C3B4>
 
}/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/symbol_folder_index.txt  öÃæšö2  t ¥ªÇŸô2c }/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/arm64-v8a/symbol_folder_index.txt  µ§Ä‚ú2  t ¥ªÇŸô2c
a a
_/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  öÃæšö2 ¤ òÑÞ€á2 _/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  µ§Ä‚ú2 ¤ òÑÞ€á2

View File

@ -2,27 +2,27 @@ C/C++ Structured Log
 
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/additional_project_files.txtC /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/additional_project_files.txtC
A A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  <EFBFBD>Äæšö2  £¼ÇŸô2‡ ?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  Õ§Ä‚ú2  £¼ÇŸô2‡
 
<EFBFBD>/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/android_gradle_build.json  <EFBFBD>Äæšö2 ¤¼ÇŸô2Œ <EFBFBD>/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/android_gradle_build.json  Õ§Ä‚ú2 ¤¼ÇŸô2Œ
 
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/android_gradle_build_mini.json  <EFBFBD>Äæšö2 ¥¼ÇŸô2w /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/android_gradle_build_mini.json  Õ§Ä‚ú2 ¥¼ÇŸô2w
u u
s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/build.ninja  <EFBFBD>Äæšö2¾Í ¼ÇŸô2{ s/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/build.ninja  Õ§Ä‚ú2¾Í ¼ÇŸô2{
y y
w/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/build.ninja.txt  <EFBFBD>Äæšö2 w/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/build.ninja.txt  Õ§Ä‚ú2
~ ~
|/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/build_file_index.txt  <EFBFBD>Äæšö2 _ ¦¼ÇŸô2<C3B4> |/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/build_file_index.txt  Õ§Ä‚ú2 _ ¦¼ÇŸô2<C3B4>
 
}/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/compile_commands.json  <EFBFBD>Äæšö2 }/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/compile_commands.json  Õ§Ä‚ú2
 
<EFBFBD>/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/compile_commands.json.bin  <EFBFBD>Äæšö2 <09> <EFBFBD>/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/compile_commands.json.bin  Õ§Ä‚ú2 <09>
Š Š
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/metadata_generation_command.txt  <EFBFBD>Äæšö2 /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/metadata_generation_command.txt  Õ§Ä‚ú2
¤ ¥¼ÇŸô2~ ¤ ¥¼ÇŸô2~
| |
z/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/prefab_config.json  <EFBFBD>Äæšö2  ( ¦¼ÇŸô2„ z/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/prefab_config.json  Õ§Ä‚ú2  ( ¦¼ÇŸô2„
<EFBFBD> <EFBFBD>
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/symbol_folder_index.txt  <EFBFBD>Äæšö2  v ¦¼ÇŸô2c /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/armeabi-v7a/symbol_folder_index.txt  Õ§Ä‚ú2  v ¦¼ÇŸô2c
a a
_/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  <EFBFBD>Äæšö2 ¤ òÑÞ€á2 _/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  Õ§Ä‚ú2 ¤ òÑÞ€á2

View File

@ -2,27 +2,27 @@ C/C++ Structured Log
~ ~
|/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/additional_project_files.txtC |/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/additional_project_files.txtC
A A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ˆÄæšö2  µÂÇŸô2} ?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  Þ§Ä‚ú2  µÂÇŸô2}
{ {
y/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/android_gradle_build.json  ˆÄæšö2 ·ÂÇŸô2ƒ y/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/android_gradle_build.json  Þ§Ä‚ú2 ·ÂÇŸô2ƒ
 
~/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/android_gradle_build_mini.json  ˆÄæšö2 ¸ÂÇŸô2o ~/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/android_gradle_build_mini.json  Þ§Ä‚ú2 ¸ÂÇŸô2o
m m
k/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/build.ninja  ˆÄæšö2ŽÍ ¨ÂÇŸô2s k/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/build.ninja  Þ§Ä‚ú2ŽÍ ¨ÂÇŸô2s
q q
o/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/build.ninja.txt  ˆÄæšö2x o/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/build.ninja.txt  Þ§Ä‚ú2x
v v
t/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/build_file_index.txt  ˆÄæšö2 _ ¹ÂÇŸô2y t/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/build_file_index.txt  Þ§Ä‚ú2 _ ¹ÂÇŸô2y
w w
u/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/compile_commands.json  ˆÄæšö2} u/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/compile_commands.json  Þ§Ä‚ú2}
{ {
y/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/compile_commands.json.bin  ˆÄæšö2 y/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/compile_commands.json.bin  Þ§Ä‚ú2
<EFBFBD> <EFBFBD>
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/metadata_generation_command.txt  ˆÄæšö2 /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/metadata_generation_command.txt  Þ§Ä‚ú2
ü ¹ÂÇŸô2v ü ¹ÂÇŸô2v
t t
r/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/prefab_config.json  ˆÄæšö2  ( ¹ÂÇŸô2{ r/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/prefab_config.json  Þ§Ä‚ú2  ( ¹ÂÇŸô2{
y y
w/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/symbol_folder_index.txt  ˆÄæšö2  n ¹ÂÇŸô2c w/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86/symbol_folder_index.txt  Þ§Ä‚ú2  n ¹ÂÇŸô2c
a a
_/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  ˆÄæšö2 ¤ òÑÞ€á2 _/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  Þ§Ä‚ú2 ¤ òÑÞ€á2

View File

@ -2,27 +2,27 @@ C/C++ Structured Log
<EFBFBD> <EFBFBD>
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/additional_project_files.txtC /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/additional_project_files.txtC
A A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ŽÄæšö2  ·ÆÇŸô2€ ?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  Œ¨Ä‚ú2  ·ÆÇŸô2€
~ ~
|/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/android_gradle_build.json  ŽÄæšö2Œ ¸ÆÇŸô2‡ |/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/android_gradle_build.json  Œ¨Ä‚ú2Œ ¸ÆÇŸô2‡
 
<EFBFBD>/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/android_gradle_build_mini.json  ŽÄæšö2<18> ¹ÆÇŸô2r <EFBFBD>/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/android_gradle_build_mini.json  Œ¨Ä‚ú2<18> ¹ÆÇŸô2r
p p
n/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/build.ninja  ŽÄæšö2 Í §ÆÇŸô2v n/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/build.ninja  Œ¨Ä‚ú2 Í §ÆÇŸô2v
t t
r/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/build.ninja.txt  ŽÄæšö2{ r/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/build.ninja.txt  Œ¨Ä‚ú2{
y y
w/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/build_file_index.txt  ŽÄæšö2 _ ¹ÆÇŸô2| w/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/build_file_index.txt  Œ¨Ä‚ú2 _ ¹ÆÇŸô2|
z z
x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/compile_commands.json  ŽÄæšö2 x/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/compile_commands.json  Œ¨Ä‚ú2
~ ~
|/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/compile_commands.json.bin  ŽÄæšö2 ˆ |/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/compile_commands.json.bin  Œ¨Ä‚ú2 ˆ
 
/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/metadata_generation_command.txt  ŽÄæšö2 /Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/metadata_generation_command.txt  Œ¨Ä‚ú2
 ¹ÆÇŸô2y  ¹ÆÇŸô2y
w w
u/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/prefab_config.json  ŽÄæšö2  ( ¹ÆÇŸô2~ u/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/prefab_config.json  Œ¨Ä‚ú2  ( ¹ÆÇŸô2~
| |
z/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/symbol_folder_index.txt  ŽÄæšö2  q ¹ÆÇŸô2c z/Users/venbateam/Documents/UAE_Stats/FCSC/frontend/android/app/.cxx/RelWithDebInfo/574gs2w4/x86_64/symbol_folder_index.txt  Œ¨Ä‚ú2  q ¹ÆÇŸô2c
a a
_/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  ŽÄæšö2 ¤ òÑÞ€á2 _/Users/venbateam/Documents/flutter/packages/flutter_tools/gradle/src/main/groovy/CMakeLists.txt  Œ¨Ä‚ú2 ¤ òÑÞ€á2

View File

@ -20,12 +20,12 @@ if (project.hasProperty('google-services.json')) {
def flutterVersionCode = localProperties.getProperty("flutter.versionCode") def flutterVersionCode = localProperties.getProperty("flutter.versionCode")
if (flutterVersionCode == null) { if (flutterVersionCode == null) {
flutterVersionCode = "60" flutterVersionCode = "61"
} }
def flutterVersionName = localProperties.getProperty("flutter.versionName") def flutterVersionName = localProperties.getProperty("flutter.versionName")
if (flutterVersionName == null) { if (flutterVersionName == null) {
flutterVersionName = "1.0.59" flutterVersionName = "1.0.60"
} }
def keystorePropertiesFile = rootProject.file("key.properties") def keystorePropertiesFile = rootProject.file("key.properties")

View File

@ -36,7 +36,7 @@
<action android:name="android.intent.action.VIEW" /> <action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" /> <category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https" android:host="fcscapp.onelink.me" /> <data android:scheme="https" android:host="fcscapp.onelink.me" android:pathPrefix="/forgot-password"/>
</intent-filter> </intent-filter>
<!-- <intent-filter>--> <!-- <intent-filter>-->
<!-- <action android:name="android.intent.action.VIEW" />--> <!-- <action android:name="android.intent.action.VIEW" />-->

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 19 KiB

BIN
assets/dark_bg.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 135 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 497 B

View File

Before

Width:  |  Height:  |  Size: 761 B

After

Width:  |  Height:  |  Size: 761 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 727 B

View File

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

View File

@ -3,6 +3,12 @@ PODS:
- Flutter - Flutter
- app_settings (5.1.1): - app_settings (5.1.1):
- Flutter - Flutter
- appsflyer_sdk (6.16.2):
- AppsFlyerFramework (= 6.16.2)
- Flutter
- AppsFlyerFramework (6.16.2):
- AppsFlyerFramework/Main (= 6.16.2)
- AppsFlyerFramework/Main (6.16.2)
- connectivity_plus (0.0.1): - connectivity_plus (0.0.1):
- Flutter - Flutter
- device_info_plus (0.0.1): - device_info_plus (0.0.1):
@ -104,6 +110,7 @@ PODS:
DEPENDENCIES: DEPENDENCIES:
- app_links (from `.symlinks/plugins/app_links/ios`) - app_links (from `.symlinks/plugins/app_links/ios`)
- app_settings (from `.symlinks/plugins/app_settings/ios`) - app_settings (from `.symlinks/plugins/app_settings/ios`)
- appsflyer_sdk (from `.symlinks/plugins/appsflyer_sdk/ios`)
- connectivity_plus (from `.symlinks/plugins/connectivity_plus/ios`) - connectivity_plus (from `.symlinks/plugins/connectivity_plus/ios`)
- device_info_plus (from `.symlinks/plugins/device_info_plus/ios`) - device_info_plus (from `.symlinks/plugins/device_info_plus/ios`)
- firebase_core (from `.symlinks/plugins/firebase_core/ios`) - firebase_core (from `.symlinks/plugins/firebase_core/ios`)
@ -123,6 +130,7 @@ DEPENDENCIES:
SPEC REPOS: SPEC REPOS:
trunk: trunk:
- AppsFlyerFramework
- Firebase - Firebase
- FirebaseCore - FirebaseCore
- FirebaseCoreInternal - FirebaseCoreInternal
@ -138,6 +146,8 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/app_links/ios" :path: ".symlinks/plugins/app_links/ios"
app_settings: app_settings:
:path: ".symlinks/plugins/app_settings/ios" :path: ".symlinks/plugins/app_settings/ios"
appsflyer_sdk:
:path: ".symlinks/plugins/appsflyer_sdk/ios"
connectivity_plus: connectivity_plus:
:path: ".symlinks/plugins/connectivity_plus/ios" :path: ".symlinks/plugins/connectivity_plus/ios"
device_info_plus: device_info_plus:
@ -174,6 +184,8 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS: SPEC CHECKSUMS:
app_links: 76b66b60cc809390ca1ad69bfd66b998d2387ac7 app_links: 76b66b60cc809390ca1ad69bfd66b998d2387ac7
app_settings: 5127ae0678de1dcc19f2293271c51d37c89428b2 app_settings: 5127ae0678de1dcc19f2293271c51d37c89428b2
appsflyer_sdk: ebe94dc3f00b07bdd001251dbc87879bda3c494a
AppsFlyerFramework: fe5303bffcdfd941d5f570c2d21eaaea982e7bdc
connectivity_plus: cb623214f4e1f6ef8fe7403d580fdad517d2f7dd connectivity_plus: cb623214f4e1f6ef8fe7403d580fdad517d2f7dd
device_info_plus: 21fcca2080fbcd348be798aa36c3e5ed849eefbe device_info_plus: 21fcca2080fbcd348be798aa36c3e5ed849eefbe
Firebase: 1fe1c0a7d9aaea32efe01fbea5f0ebd8d70e53a2 Firebase: 1fe1c0a7d9aaea32efe01fbea5f0ebd8d70e53a2

View File

@ -506,7 +506,7 @@
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements; CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 6; CURRENT_PROJECT_VERSION = 7;
DEVELOPMENT_ASSET_PATHS = Runner/Assets.xcassets; DEVELOPMENT_ASSET_PATHS = Runner/Assets.xcassets;
DEVELOPMENT_TEAM = 9N5SRFUGK2; DEVELOPMENT_TEAM = 9N5SRFUGK2;
ENABLE_BITCODE = NO; ENABLE_BITCODE = NO;
@ -517,7 +517,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 1.0.5; MARKETING_VERSION = 1.0.6;
PRODUCT_BUNDLE_IDENTIFIER = ae.gov.fcsc.frontend.ios; PRODUCT_BUNDLE_IDENTIFIER = ae.gov.fcsc.frontend.ios;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = ""; PROVISIONING_PROFILE_SPECIFIER = "";
@ -705,7 +705,7 @@
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements; CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 6; CURRENT_PROJECT_VERSION = 7;
DEVELOPMENT_ASSET_PATHS = Runner/Assets.xcassets; DEVELOPMENT_ASSET_PATHS = Runner/Assets.xcassets;
DEVELOPMENT_TEAM = 9N5SRFUGK2; DEVELOPMENT_TEAM = 9N5SRFUGK2;
ENABLE_BITCODE = NO; ENABLE_BITCODE = NO;
@ -716,7 +716,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 1.0.5; MARKETING_VERSION = 1.0.6;
PRODUCT_BUNDLE_IDENTIFIER = ae.gov.fcsc.frontend.ios; PRODUCT_BUNDLE_IDENTIFIER = ae.gov.fcsc.frontend.ios;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = ""; PROVISIONING_PROFILE_SPECIFIER = "";
@ -742,7 +742,7 @@
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements; CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 6; CURRENT_PROJECT_VERSION = 7;
DEVELOPMENT_ASSET_PATHS = Runner/Assets.xcassets; DEVELOPMENT_ASSET_PATHS = Runner/Assets.xcassets;
DEVELOPMENT_TEAM = 9N5SRFUGK2; DEVELOPMENT_TEAM = 9N5SRFUGK2;
ENABLE_BITCODE = NO; ENABLE_BITCODE = NO;
@ -753,7 +753,7 @@
"$(inherited)", "$(inherited)",
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
MARKETING_VERSION = 1.0.5; MARKETING_VERSION = 1.0.6;
PRODUCT_BUNDLE_IDENTIFIER = ae.gov.fcsc.frontend.ios; PRODUCT_BUNDLE_IDENTIFIER = ae.gov.fcsc.frontend.ios;
PRODUCT_NAME = "$(TARGET_NAME)"; PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = ""; PROVISIONING_PROFILE_SPECIFIER = "";

View File

@ -1,4 +1,4 @@
// api_config.dart // api_config.dart
// const String apiUrl = 'http://192.168.1.26:8090'; // const String apiUrl = 'http://127.0.0.1:8090';
// const String apiUrl = 'https://pbdev.venbait.in/'; // const String apiUrl = 'https://pbdev.venbait.in/';
const String apiUrl = 'https://pb.venbait.in/'; const String apiUrl = 'https://pb.venbait.in/';

View File

@ -0,0 +1,12 @@
enum AppTheme { light, dark, system }
extension AppThemeExtension on AppTheme {
String get name => toString().split('.').last;
static AppTheme fromString(String value) {
return AppTheme.values.firstWhere(
(e) => e.name == value,
orElse: () => AppTheme.system,
);
}
}

View File

@ -0,0 +1,94 @@
import 'dart:convert';
import 'package:http/http.dart' as http;
import 'package:pocketbase/pocketbase.dart';
import 'package:uae_stat/config/api_config.dart';
class ThemeBaseService {
final pb = PocketBase(apiUrl);
dynamic themeData;
// Future getUserTheme(String userId) async {
// final prefs = await SharedPreferences.getInstance();
// final userId = prefs.getString('userId') ?? '';
//
// // Authenticate admin d
// final adminAuth = await pb.admins.authWithPassword(
// 'pb@venbainfotech.com',
// 'pb@venbainfotech.com',
// );
// final String adminToken = adminAuth.token;
// print('adminToken: $adminToken');
//
// // Fetch user details
// final userDetailsResponse = await pb.collection('users').getOne(
// userId,
// headers: {
// 'Authorization': 'Bearer $adminToken',
// },
// );
//
// print('userDetailsLogin: $userDetailsResponse');
//
//
// // if (response.statusCode == 200) {
// return userDetailsResponse.data['theme'] ?? 'system';
// // } else {
// // return 'system';
// // }
// }
Future<dynamic> getUserTheme(String userId) async {
final url = "${pb.baseUrl}/api/collections/users/records/$userId";
final adminAuth = await pb.admins.authWithPassword(
'pb@venbainfotech.com',
'pb@venbainfotech.com',
);
final String adminToken = adminAuth.token;
print('adminToken: $adminToken');
final response = await http.get(
Uri.parse(url),
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer $adminToken'
},
);
if (response.statusCode == 200) {
return jsonDecode(response.body)['theme'] ?? 'system';
} else {
return 'system';
}
}
Future<void> updateUserTheme(String userId, String theme) async {
// Authenticate admin d
final url = "${pb.baseUrl}/api/collections/users/records/$userId";
final adminAuth = await pb.admins.authWithPassword(
'pb@venbainfotech.com',
'pb@venbainfotech.com',
);
final String adminToken = adminAuth.token;
print('adminToken: $adminToken');
final response = await http.patch(
Uri.parse(url),
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer $adminToken',
},
body: jsonEncode({
'theme': theme, // light, dark, or system
}),
);
if (response.statusCode == 200) {
print("Theme updated successfully");
} else {
print("Failed to update theme: ${response.body}");
throw Exception('Failed to update theme');
}
}
}

View File

@ -0,0 +1,49 @@
import 'package:flutter/material.dart';
import 'package:uae_stat/config/theme/app_theme.dart';
class ThemeSelectorDialog extends StatefulWidget {
final AppTheme initialTheme;
const ThemeSelectorDialog({super.key, required this.initialTheme});
@override
State<ThemeSelectorDialog> createState() => _ThemeSelectorDialogState();
}
class _ThemeSelectorDialogState extends State<ThemeSelectorDialog> {
late AppTheme _selectedTheme;
@override
void initState() {
super.initState();
_selectedTheme = widget.initialTheme;
}
@override
Widget build(BuildContext context) {
return AlertDialog(
title: const Text("Choose Theme"),
content: Column(
mainAxisSize: MainAxisSize.min,
children: AppTheme.values.map((theme) {
return RadioListTile<AppTheme>(
title: Text(theme.name[0].toUpperCase() + theme.name.substring(1)),
value: theme,
groupValue: _selectedTheme,
onChanged: (value) => setState(() => _selectedTheme = value!),
);
}).toList(),
),
actions: [
TextButton(
onPressed: () => Navigator.of(context).pop(null),
child: const Text("Cancel"),
),
ElevatedButton(
onPressed: () => Navigator.of(context).pop(_selectedTheme),
child: const Text("OK"),
),
],
);
}
}

View File

@ -0,0 +1,31 @@
// lib/config/theme/theme_provider.dart
import 'package:flutter/material.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:uae_stat/config/theme/app_theme.dart';
final themeProvider = StateNotifierProvider<ThemeNotifier, ThemeMode>((ref) {
return ThemeNotifier();
});
class ThemeNotifier extends StateNotifier<ThemeMode> {
ThemeNotifier() : super(ThemeMode.system);
void updateTheme(AppTheme theme,Brightness platformBrightness) {
switch (theme) {
case AppTheme.light:
state = ThemeMode.light;
break;
case AppTheme.dark:
state = ThemeMode.dark;
break;
case AppTheme.system:
// Set based on actual system brightness
final systemTheme = platformBrightness == Brightness.dark
? ThemeMode.dark
: ThemeMode.light;
state = systemTheme;
break;
}
}
}

View File

@ -1,4 +1,5 @@
abstract class BannerAssetPath { abstract class BannerAssetPath {
static const _basePath = 'assets/banners'; static const _basePath = 'assets/banners';
static const fcsc = '$_basePath/fcsc.png'; static const fcscLogoDark = '$_basePath/FCSCLogo_dark.png';
static const fcscLogoLight = '$_basePath/FCSCLogo_light.png';
} }

View File

@ -2,9 +2,11 @@ abstract class MiscIconAssetPath {
static const _basePath = 'assets/icons/misc'; static const _basePath = 'assets/icons/misc';
static const rightChevronInSemiCircle = static const rightChevronInSemiCircle =
'$_basePath/right_chevron_in_semicircle.png'; '$_basePath/right_chevron_in_semicircle.png';
static const lock = '$_basePath/lock.png'; static const lockDark = '$_basePath/lockDark.png';
static const lockLight = '$_basePath/lockLight.png';
static const menu = '$_basePath/menu.png'; static const menu = '$_basePath/menu.png';
static const person = '$_basePath/person.png'; static const personDark = '$_basePath/personDark.png';
static const personLight = '$_basePath/personLight.png';
static const back = '$_basePath/back.png'; static const back = '$_basePath/back.png';
static const vector = '$_basePath/vector.png'; static const vector = '$_basePath/vector.png';
static const visibleOn = '$_basePath/visible_on.png'; static const visibleOn = '$_basePath/visible_on.png';

View File

@ -10,6 +10,7 @@ import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:go_router/go_router.dart'; import 'package:go_router/go_router.dart';
import 'package:uae_stat/config/injector.dart'; import 'package:uae_stat/config/injector.dart';
import 'package:uae_stat/config/my_router.dart'; import 'package:uae_stat/config/my_router.dart';
import 'package:uae_stat/config/theme/theme_provider.dart';
import 'package:uae_stat/presentation/components/indicators/locale_provider.dart'; import 'package:uae_stat/presentation/components/indicators/locale_provider.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart'; import 'package:flutter_gen/gen_l10n/app_localizations.dart';
@ -140,6 +141,10 @@ void main() async {
print('User tapped on notification'); print('User tapped on notification');
}); });
// final themeProvider = ThemeProvider();
// themeProvider.setUserId("USER_ID_FROM_LOGIN"); // set this properly
// await themeProvider.loadThemeFromPocketBase();
// //
// Request permission for notifications // Request permission for notifications
@ -224,11 +229,14 @@ class _MainAppState extends ConsumerState<MainApp> {
handleConnectivityChange(context, hasInternet); handleConnectivityChange(context, hasInternet);
} }
}); });
final themeMode = ref.watch(themeProvider);
return MaterialApp.router( return MaterialApp.router(
debugShowCheckedModeBanner: false, debugShowCheckedModeBanner: false,
routerConfig: router, routerConfig: router,
locale: locale, locale: locale,
theme: ThemeData.light(),
darkTheme: ThemeData.dark(),
themeMode: themeMode,
localizationsDelegates: AppLocalizations.localizationsDelegates, localizationsDelegates: AppLocalizations.localizationsDelegates,
supportedLocales: AppLocalizations.supportedLocales, supportedLocales: AppLocalizations.supportedLocales,
); );

View File

@ -7,6 +7,7 @@ import 'package:go_router/go_router.dart';
import 'package:pocketbase/pocketbase.dart'; import 'package:pocketbase/pocketbase.dart';
import 'package:shared_preferences/shared_preferences.dart'; import 'package:shared_preferences/shared_preferences.dart';
import 'package:uae_stat/config/connectivity_provider.dart'; import 'package:uae_stat/config/connectivity_provider.dart';
import 'package:uae_stat/config/theme/theme_provider.dart';
import 'package:uae_stat/config/toggle_lang_service.dart'; import 'package:uae_stat/config/toggle_lang_service.dart';
import 'package:uae_stat/domain/use_cases/language.dart'; import 'package:uae_stat/domain/use_cases/language.dart';
import 'package:uae_stat/infrastructure/services/img_asset_paths/icons/misc_icon_asset_path.dart'; import 'package:uae_stat/infrastructure/services/img_asset_paths/icons/misc_icon_asset_path.dart';
@ -18,7 +19,7 @@ import 'package:http/http.dart' as http;
import 'package:uae_stat/config/api_config.dart'; import 'package:uae_stat/config/api_config.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart'; import 'package:flutter_gen/gen_l10n/app_localizations.dart';
class UaeNumbers extends StatelessWidget { class UaeNumbers extends ConsumerWidget {
const UaeNumbers({super.key}); const UaeNumbers({super.key});
@override @override
@ -34,7 +35,11 @@ class UaeNumbers extends StatelessWidget {
// } // }
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context,WidgetRef ref) {
final isDarkTheme = ref.watch(themeProvider) == ThemeMode.dark ||
(ref.watch(themeProvider) == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
double myheight = MediaQuery.of(context).size.height; double myheight = MediaQuery.of(context).size.height;
double mywidth = MediaQuery.of(context).size.width; double mywidth = MediaQuery.of(context).size.width;
@ -45,6 +50,7 @@ class UaeNumbers extends StatelessWidget {
context.go('/myhomepage'); // Show exit confirmation dialog context.go('/myhomepage'); // Show exit confirmation dialog
}, },
child: BaseScaffold( child: BaseScaffold(
backgroundColor: isDarkTheme ? Color(0xFF333333) : Color(0xFF414042),
title: Text( title: Text(
context.translate( context.translate(
'UAE Numbers', 'UAE Numbers',
@ -54,7 +60,8 @@ class UaeNumbers extends StatelessWidget {
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
) ),
color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF414042),
), ),
), ),
body: uaenumberWidget(), body: uaenumberWidget(),
@ -78,13 +85,22 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
int? expandedIndex = 0; int? expandedIndex = 0;
final _pb = PocketBase(apiUrl); final _pb = PocketBase(apiUrl);
late UserService _userService; late UserService _userService;
late ThemeMode currentTheme;
@override @override
void initState() { void initState() {
super.initState(); super.initState();
_userService = UserService(); _userService = UserService();
final locale = ref.read(localeProvider); final locale = ref.read(localeProvider);
fetchData(locale?.languageCode ?? 'en'); currentTheme = ref.read(themeProvider);
print('123456789');
print(currentTheme);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeMode = (isDark ? 'dark' : 'light');
fetchData(locale?.languageCode ?? 'en',themeMode);
_searchController.addListener(() { _searchController.addListener(() {
setState(() { setState(() {
filterData(_searchController.text); filterData(_searchController.text);
@ -98,10 +114,10 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
super.dispose(); super.dispose();
} }
Future<void> fetchData(locale) async { Future<void> fetchData(locale,themeMode) async {
const baseUrl = '$apiUrl/api/getUAENumbersData'; const baseUrl = '$apiUrl/api/getUAENumbersData';
try { try {
final response = await http.get(Uri.parse(baseUrl + '?language=$locale')); final response = await http.get(Uri.parse(baseUrl + '?language=$locale&color_mode=$themeMode'));
if (response.statusCode == 200) { if (response.statusCode == 200) {
setState(() { setState(() {
homePageData = (json.decode(response.body) as List) homePageData = (json.decode(response.body) as List)
@ -193,9 +209,39 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
isLoading = true; isLoading = true;
}); });
await _userService.updateLanguage(localeCode); await _userService.updateLanguage(localeCode);
fetchData(localeCode); final currentTheme = ref.read(themeProvider);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeString = isDark ? 'dark' : 'light';
fetchData(localeCode,themeString);
}); });
ref.listen<ThemeMode>(themeProvider, (previous, next) async {
final localeCode = ref.watch(localeProvider)?.languageCode ?? 'en';
print(localeCode);
// Default to 'en' if null
setState(() {
isLoading = true;
print('isLoadingref $isLoading');
});
final currentTheme = ref.read(themeProvider);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeString = isDark ? 'dark' : 'light';
fetchData(localeCode,themeString);
});
final themeMode = ref.watch(themeProvider);
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
double myheight = MediaQuery.of(context).size.height; double myheight = MediaQuery.of(context).size.height;
double mywidth = MediaQuery.of(context).size.width; double mywidth = MediaQuery.of(context).size.width;
@ -218,14 +264,16 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
); );
} }
return Padding( return Container(
color: isDarkTheme ? Color(0xFF333333) : Color(0xFFFFFFFF), // Set background here
child: Padding(
padding: const EdgeInsets.only(left: 16.0, right: 16.0, top: 5.0, bottom: 5.0), padding: const EdgeInsets.only(left: 16.0, right: 16.0, top: 5.0, bottom: 5.0),
child: Column( child: Column(
children: [ children: [
Container( Container(
height: 40, height: 40,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.white, color: isDarkTheme ? Color(0xFF000000) : Colors.white,
borderRadius: BorderRadius.circular(30.0), borderRadius: BorderRadius.circular(30.0),
border: Border.all(width: 1, color: Color(0xFFAA8E83)), border: Border.all(width: 1, color: Color(0xFFAA8E83)),
), ),
@ -239,7 +287,7 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
decoration: InputDecoration( decoration: InputDecoration(
hintText: AppLocalizations.of(context)!.search, hintText: AppLocalizations.of(context)!.search,
hintStyle: TextStyle( hintStyle: TextStyle(
color: Color(0xFFAA8E83), color: isDarkTheme ? Color(0xFFBBBBBB) : Color(0xFFAA8E83),
fontFamily: context.translate('Roboto', 'NotoKufi'), fontFamily: context.translate('Roboto', 'NotoKufi'),
fontSize: 14, fontSize: 14,
// height: 1.8, // height: 1.8,
@ -272,7 +320,7 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
}, },
) )
: null, : null,
contentPadding: EdgeInsets.symmetric(vertical: 12, horizontal: 18.0), contentPadding: EdgeInsets.symmetric(vertical: 15, horizontal: 18.0),
border: InputBorder.none, border: InputBorder.none,
// contentPadding: // contentPadding:
// EdgeInsets.symmetric(vertical: 9, horizontal: 18.0), // EdgeInsets.symmetric(vertical: 9, horizontal: 18.0),
@ -303,6 +351,7 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
}, },
title: mainTopic['main_topic'], title: mainTopic['main_topic'],
titleBackgroundColor: backgroundColor, titleBackgroundColor: backgroundColor,
// currentTheme: currentTheme,
children: _buildSubTopics( children: _buildSubTopics(
mainTopic['sub_topics'] ?? [], mainTopic['sub_topics'] ?? [],
mywidth, mywidth,
@ -317,6 +366,7 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
), ),
], ],
), ),
)
); );
} }
@ -431,6 +481,11 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
: 0.0; : 0.0;
bool isPositive = parsedValue >= 0; bool isPositive = parsedValue >= 0;
final themeMode = ref.watch(themeProvider);
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
return GestureDetector( return GestureDetector(
onTap: () { onTap: () {
final encodedMainTopic = Uri.encodeComponent(mainTopic); final encodedMainTopic = Uri.encodeComponent(mainTopic);
@ -444,7 +499,7 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
child: Container( child: Container(
width: mywidth, width: mywidth,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.white, color: isDarkTheme ? Color(0xFF111111) : Colors.white,
border: Border.all( border: Border.all(
color: bordercolor, color: bordercolor,
width: 1, width: 1,
@ -459,7 +514,7 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
Text( Text(
title, title,
textAlign: TextAlign.center, textAlign: TextAlign.center,
style: robotoRegular11(context), style: robotoRegular11(context,isDarkTheme),
), ),
SizedBox(height: 0.1), SizedBox(height: 0.1),
Text(subtitle, textAlign: TextAlign.center, style: subtitleStyle(context)), Text(subtitle, textAlign: TextAlign.center, style: subtitleStyle(context)),
@ -499,7 +554,7 @@ class _UaenumberWidgetState extends ConsumerState<uaenumberWidget> {
} }
} }
class CustomExpandableTile extends StatefulWidget { class CustomExpandableTile extends ConsumerStatefulWidget {
final String title; final String title;
final Color titleBackgroundColor; final Color titleBackgroundColor;
final List<Widget> children; final List<Widget> children;
@ -517,21 +572,31 @@ class CustomExpandableTile extends StatefulWidget {
}); });
@override @override
_CustomExpandableTileState createState() => _CustomExpandableTileState(); ConsumerState<CustomExpandableTile> createState() => _CustomExpandableTileState();
} }
class _CustomExpandableTileState extends State<CustomExpandableTile> { class _CustomExpandableTileState extends ConsumerState<CustomExpandableTile> {
bool isExpanded = false; bool isExpanded = false;
// late bool isExpanded; // late bool isExpanded;
@override @override
void initState() { void initState() {
super.initState(); // Initialize isExpanded based on widget's property super.initState(); // Initialize isExpanded based on widget's property
print('123456789');
} }
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
double myheight = MediaQuery.of(context).size.height; double myheight = MediaQuery.of(context).size.height;
final themeMode = ref.watch(themeProvider);
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
print('123456789000');
print(isDarkTheme);
return Card( return Card(
elevation: 0, elevation: 0,
child: Column( child: Column(
@ -540,8 +605,7 @@ class _CustomExpandableTileState extends State<CustomExpandableTile> {
onTap: () => widget.onTap(widget.index), onTap: () => widget.onTap(widget.index),
child: Container( child: Container(
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors color: isDarkTheme ? Color(0xFF333333) : Colors.white,
.white, // Ensuring the background outside the rounded container is white
), ),
child: Container( child: Container(
decoration: BoxDecoration( decoration: BoxDecoration(
@ -581,13 +645,13 @@ class _CustomExpandableTileState extends State<CustomExpandableTile> {
duration: Duration(milliseconds: 300), duration: Duration(milliseconds: 300),
curve: Curves.easeInOut, curve: Curves.easeInOut,
width: double.infinity, width: double.infinity,
color: Colors.white, color: isDarkTheme ? Color(0xFF333333) : Colors.white,
height: widget.isExpanded ? myheight * 0.52 : 0, height: widget.isExpanded ? myheight * 0.52 : 0,
child: widget.isExpanded child: widget.isExpanded
? SingleChildScrollView( ? SingleChildScrollView(
child: Container( child: Container(
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.white, color: isDarkTheme ? Color(0xFF333333) : Colors.white,
// borderRadius: BorderRadius.all(Radius.circular(20)) // borderRadius: BorderRadius.all(Radius.circular(20))
), ),
padding: const EdgeInsets.all(1), padding: const EdgeInsets.all(1),

View File

@ -12,7 +12,7 @@ class Welcomepage extends StatelessWidget {
double myheight = MediaQuery.of(context).size.height; double myheight = MediaQuery.of(context).size.height;
double mywidth = MediaQuery.of(context).size.width; double mywidth = MediaQuery.of(context).size.width;
final fcscBanner = Image.asset( final fcscBanner = Image.asset(
BannerAssetPath.fcsc, BannerAssetPath.fcscLogoLight,
height: 40, height: 40,
); );
final uaestat = Image.asset( final uaestat = Image.asset(

View File

@ -48,7 +48,7 @@ class _CreateNewPwState extends ConsumerState<CreateNewPw> {
String? _confirmPassword; String? _confirmPassword;
final fcscBanner = Image.asset( final fcscBanner = Image.asset(
BannerAssetPath.fcsc, BannerAssetPath.fcscLogoLight,
height: 40, height: 40,
); );
@ -426,7 +426,7 @@ class _CreateNewPwState extends ConsumerState<CreateNewPw> {
end: 10, end: 10,
), ),
child: Image.asset( child: Image.asset(
MiscIconAssetPath.lock, MiscIconAssetPath.lockLight,
fit: BoxFit.fitHeight, fit: BoxFit.fitHeight,
height: 25, height: 25,
width: 25, width: 25,
@ -510,7 +510,7 @@ class _CreateNewPwState extends ConsumerState<CreateNewPw> {
end: 10, end: 10,
), ),
child: Image.asset( child: Image.asset(
MiscIconAssetPath.lock, MiscIconAssetPath.lockLight,
fit: BoxFit.fitHeight, fit: BoxFit.fitHeight,
height: 25, height: 25,
width: 25, width: 25,
@ -592,7 +592,7 @@ class _CreateNewPwState extends ConsumerState<CreateNewPw> {
end: 10, end: 10,
), ),
child: Image.asset( child: Image.asset(
MiscIconAssetPath.lock, MiscIconAssetPath.lockLight,
fit: BoxFit.fitHeight, fit: BoxFit.fitHeight,
height: 25, height: 25,
width: 25, width: 25,

View File

@ -41,7 +41,7 @@ class _ForgotPasswordState extends ConsumerState<ForgotPassword> {
String? _confirmPassword; String? _confirmPassword;
final fcscBanner = Image.asset( final fcscBanner = Image.asset(
BannerAssetPath.fcsc, BannerAssetPath.fcscLogoLight,
height: 40, height: 40,
); );
@ -445,7 +445,7 @@ class _ForgotPasswordState extends ConsumerState<ForgotPassword> {
end: 10, end: 10,
), ),
child: Image.asset( child: Image.asset(
MiscIconAssetPath.lock, MiscIconAssetPath.lockLight,
fit: BoxFit.fitHeight, fit: BoxFit.fitHeight,
height: 25, height: 25,
width: 25, width: 25,
@ -528,7 +528,7 @@ class _ForgotPasswordState extends ConsumerState<ForgotPassword> {
end: 10, end: 10,
), ),
child: Image.asset( child: Image.asset(
MiscIconAssetPath.lock, MiscIconAssetPath.lockLight,
fit: BoxFit.fitHeight, fit: BoxFit.fitHeight,
height: 25, height: 25,
width: 25, width: 25,

View File

@ -7,7 +7,7 @@ import 'package:uae_stat/presentation/routes/drawer_routes/custom_drawer_routes.
class PrivacyPolicy extends StatelessWidget { class PrivacyPolicy extends StatelessWidget {
PrivacyPolicy({super.key}); PrivacyPolicy({super.key});
final fcscBanner = Image.asset( final fcscBanner = Image.asset(
BannerAssetPath.fcsc, BannerAssetPath.fcscLogoLight,
height: 40, height: 40,
alignment: Alignment.center, alignment: Alignment.center,
); );

View File

@ -8,6 +8,7 @@ import 'package:pocketbase/pocketbase.dart';
import 'package:uae_stat/config/api_config.dart'; import 'package:uae_stat/config/api_config.dart';
import 'package:uae_stat/config/connectivity_provider.dart'; import 'package:uae_stat/config/connectivity_provider.dart';
import 'package:uae_stat/config/my_theme.dart'; import 'package:uae_stat/config/my_theme.dart';
import 'package:uae_stat/config/theme/theme_provider.dart';
import 'package:uae_stat/domain/use_cases/language.dart'; import 'package:uae_stat/domain/use_cases/language.dart';
import 'package:uae_stat/infrastructure/services/img_asset_paths/banner_asset_path.dart'; import 'package:uae_stat/infrastructure/services/img_asset_paths/banner_asset_path.dart';
import 'package:uae_stat/infrastructure/services/img_asset_paths/icons/misc_icon_asset_path.dart'; import 'package:uae_stat/infrastructure/services/img_asset_paths/icons/misc_icon_asset_path.dart';
@ -359,10 +360,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
} }
} }
final fcscBanner = Image.asset(
BannerAssetPath.fcsc,
height: 40,
);
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
@ -376,6 +374,18 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
} }
}); });
final themeMode = ref.read(themeProvider);
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final fcscBanner = Image.asset(
isDarkTheme
? BannerAssetPath.fcscLogoDark
: BannerAssetPath.fcscLogoLight,
height: 40,
);
Widget buildIconContainer(IconData icon, Color iconColor) { Widget buildIconContainer(IconData icon, Color iconColor) {
return Container( return Container(
width: 60, width: 60,
@ -406,7 +416,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
context.go('/login'); // Show exit confirmation dialog context.go('/login'); // Show exit confirmation dialog
}, },
child:Scaffold( child:Scaffold(
backgroundColor: Colors.white, backgroundColor: isDarkTheme ? Color(0xFF111111) : Colors.white,
body: SafeArea( body: SafeArea(
child: Stack(children: [ child: Stack(children: [
SingleChildScrollView( SingleChildScrollView(
@ -452,7 +462,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
children: [ children: [
SizedBox(height: screenheight / 4), SizedBox(height: screenheight / 4),
buildIconContainer( buildIconContainer(
Icons.report, Color(0xFF7DAFBC)), Icons.check_circle_rounded, Color(0xFF7DAFBC)),
SizedBox(height: 20), SizedBox(height: 20),
Text( Text(
context.translate( context.translate(
@ -466,7 +476,8 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
), ),
fontSize: 16, fontSize: 16,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
color: Color(0xFF414042)), color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF414042)
),
), ),
SizedBox(height: 10), SizedBox(height: 10),
Text( Text(
@ -480,15 +491,14 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'NotoKufi', 'NotoKufi',
), ),
fontSize: 14, fontSize: 14,
color: Color(0xFF898C81), color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF898C81),
), ),
), ),
SizedBox(height: 10), SizedBox(height: 10),
ElevatedButton( ElevatedButton(
onPressed: () => {context.go('/login')}, onPressed: () => {context.go('/login')},
style: ElevatedButton.styleFrom( style: ElevatedButton.styleFrom(
backgroundColor: backgroundColor: isDarkTheme ? Color(0xFF24B4FB) : Color(0xFFAA8E83), // Background color
Color(0xFFAA8E83), // Background color
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular( borderRadius: BorderRadius.circular(
12), // Border radius 12), // Border radius
@ -514,7 +524,9 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
decoration: BoxDecoration( decoration: BoxDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
"assets/splash_screen/logo.png"), // Background image asset isDarkTheme
? BannerAssetPath.fcscLogoDark
: BannerAssetPath.fcscLogoLight), // Background image asset
fit: BoxFit.fill, fit: BoxFit.fill,
), ),
), ),
@ -544,7 +556,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
), ),
fontSize: 16, fontSize: 16,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
color: Color(0xFF414042)), color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF414042)),
), ),
SizedBox(height: 10), SizedBox(height: 10),
Text( Text(
@ -558,7 +570,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'NotoKufi', 'NotoKufi',
), ),
fontSize: 14, fontSize: 14,
color: Color(0xFF898C81), color: isDarkTheme ? Color(0xFFEEEEEE) : Color(0xFF898C81),
), ),
), ),
SizedBox(height: 10), SizedBox(height: 10),
@ -581,7 +593,8 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
) ),
color: isDarkTheme ? Color(0xFF24B4FB) : Color(0xFFAA8E83),
), ),
), ),
), ),
@ -593,7 +606,9 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
decoration: BoxDecoration( decoration: BoxDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
"assets/splash_screen/logo.png"), // Background image asset isDarkTheme
? BannerAssetPath.fcscLogoDark
: BannerAssetPath.fcscLogoLight), // Background image asset
fit: BoxFit.fill, fit: BoxFit.fill,
), ),
), ),
@ -619,7 +634,9 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'NotoKufi', 'NotoKufi',
), ),
fontSize: 32, fontSize: 32,
fontWeight: FontWeight.w400), fontWeight: FontWeight.w400,
color: isDarkTheme ? Color(0xFFFFFFFF) : null,
),
), ),
SizedBox(height: 10), SizedBox(height: 10),
Text( Text(
@ -632,7 +649,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
), ),
fontSize: fontSize:
context.translate(18.0, 14.0), context.translate(18.0, 14.0),
color: const Color(0xff898C81), color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xff898C81),
fontWeight: FontWeight.w600, fontWeight: FontWeight.w600,
), ),
), ),
@ -649,7 +666,10 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
controller: _usernameController, controller: _usernameController,
// focusNode: _focusNodes[0], // focusNode: _focusNodes[0],
decoration: InputDecoration( decoration: InputDecoration(
filled: true,
fillColor: isDarkTheme ? const Color(0xFF000000) : Colors.white,
errorStyle: TextStyle( errorStyle: TextStyle(
color: isDarkTheme ? Color(0xFFFFA200) : Color(0xFFb22222),
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -674,7 +694,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
end: 10, end: 10,
), ),
child: Image.asset( child: Image.asset(
MiscIconAssetPath.person, MiscIconAssetPath.personLight,
fit: BoxFit.fitHeight, fit: BoxFit.fitHeight,
height: 25, height: 25,
width: 25, width: 25,
@ -695,10 +715,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: MyTheme.topicColor( color: isDarkTheme ? Colors.white : MyTheme.topicColor(IndicatorTopic.economy).shade400, // border
IndicatorTopic
.economy)
.shade400,
width: 1), // Enabled border width: 1), // Enabled border
), ),
focusedBorder: OutlineInputBorder( focusedBorder: OutlineInputBorder(
@ -712,7 +729,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA100) : Color(0xFFb22222),
width: 1), // Error border width: 1), // Error border
), ),
focusedErrorBorder: focusedErrorBorder:
@ -720,7 +737,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA100) : Color(0xFFb22222),
width: width:
1), // Match the error color 1), // Match the error color
), ),
@ -730,7 +747,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Color(0xFFC3C6CB), color: isDarkTheme ? const Color(0xFFEEEEEE) : const Color(0xFFC3C6CB),
fontSize: registerLocale fontSize: registerLocale
?.languageCode == ?.languageCode ==
'ar' 'ar'
@ -756,7 +773,10 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
controller: _emailController, controller: _emailController,
// focusNode: _focusNodes[1], // focusNode: _focusNodes[1],
decoration: InputDecoration( decoration: InputDecoration(
filled: true,
fillColor: isDarkTheme ? const Color(0xFF000000) : Colors.white,
errorStyle: TextStyle( errorStyle: TextStyle(
color: isDarkTheme ? Color(0xFFFFA200) : Color(0xFFb22222),
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -798,10 +818,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: MyTheme.topicColor( color: isDarkTheme ? Colors.white : MyTheme.topicColor(IndicatorTopic.economy).shade400,
IndicatorTopic
.economy)
.shade400,
width: 1), width: 1),
), ),
focusedBorder: OutlineInputBorder( focusedBorder: OutlineInputBorder(
@ -815,7 +832,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA100) : Color(0xFFb22222),
width: 1), // Error border width: 1), // Error border
), ),
focusedErrorBorder: focusedErrorBorder:
@ -823,7 +840,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA100) : Color(0xFFb22222),
width: width:
1), // Match the error color 1), // Match the error color
), ),
@ -833,7 +850,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Color(0xFFC3C6CB), color: isDarkTheme ? const Color(0xFFEEEEEE) : const Color(0xFFC3C6CB),
fontSize: registerLocale fontSize: registerLocale
?.languageCode == ?.languageCode ==
'ar' 'ar'
@ -863,7 +880,10 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
// focusNode: _focusNodes[2], // focusNode: _focusNodes[2],
obscureText: _obscurePassword, obscureText: _obscurePassword,
decoration: InputDecoration( decoration: InputDecoration(
filled: true,
fillColor: isDarkTheme ? const Color(0xFF000000) : Colors.white,
errorStyle: TextStyle( errorStyle: TextStyle(
color: isDarkTheme ? Color(0xFFFFA200) : Color(0xFFb22222),
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -888,7 +908,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
end: 10, end: 10,
), ),
child: Image.asset( child: Image.asset(
MiscIconAssetPath.lock, MiscIconAssetPath.lockLight,
fit: BoxFit.fitHeight, fit: BoxFit.fitHeight,
height: 25, height: 25,
width: 25, width: 25,
@ -936,10 +956,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: MyTheme.topicColor( color: isDarkTheme ? Colors.white : MyTheme.topicColor(IndicatorTopic.economy).shade400,
IndicatorTopic
.economy)
.shade400,
width: 1), width: 1),
), ),
focusedBorder: OutlineInputBorder( focusedBorder: OutlineInputBorder(
@ -953,7 +970,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA100) : Color(0xFFb22222),
width: 1), // Error border width: 1), // Error border
), ),
focusedErrorBorder: focusedErrorBorder:
@ -961,7 +978,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA100) : Color(0xFFb22222),
width: width:
1), // Match the error color 1), // Match the error color
), ),
@ -972,7 +989,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Color(0xFFC3C6CB), color: isDarkTheme ? const Color(0xFFEEEEEE) : const Color(0xFFC3C6CB),
fontSize: registerLocale fontSize: registerLocale
?.languageCode == ?.languageCode ==
'ar' 'ar'
@ -1000,7 +1017,10 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
obscureText: obscureText:
_obscureConfirmPassword, _obscureConfirmPassword,
decoration: InputDecoration( decoration: InputDecoration(
filled: true,
fillColor: isDarkTheme ? const Color(0xFF000000) : Colors.white,
errorStyle: TextStyle( errorStyle: TextStyle(
color: isDarkTheme ? Color(0xFFFFA200) : Color(0xFFb22222),
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1025,7 +1045,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
end: 10, end: 10,
), ),
child: Image.asset( child: Image.asset(
MiscIconAssetPath.lock, MiscIconAssetPath.lockLight,
fit: BoxFit.fitHeight, fit: BoxFit.fitHeight,
height: 25, height: 25,
width: 25, width: 25,
@ -1063,10 +1083,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: MyTheme.topicColor( color: isDarkTheme ? Colors.white : MyTheme.topicColor(IndicatorTopic.economy).shade400,
IndicatorTopic
.economy)
.shade400,
width: 1), width: 1),
), ),
focusedBorder: OutlineInputBorder( focusedBorder: OutlineInputBorder(
@ -1080,7 +1097,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA100) : Color(0xFFb22222),
width: 1), // Error border width: 1), // Error border
), ),
focusedErrorBorder: focusedErrorBorder:
@ -1088,7 +1105,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA100) : Color(0xFFb22222),
width: width:
1), // Match the error color 1), // Match the error color
), ),
@ -1098,7 +1115,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Color(0xFFC3C6CB), color: isDarkTheme ? const Color(0xFFEEEEEE) : const Color(0xFFC3C6CB),
fontSize: registerLocale fontSize: registerLocale
?.languageCode == ?.languageCode ==
'ar' 'ar'
@ -1139,11 +1156,8 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
}, },
side: BorderSide( side: BorderSide(
color: showError color: showError
? Color(0xFFb22222) ? isDarkTheme ? Color(0xFFFFA200) : Color(0xFFb22222)
: MyTheme.topicColor( : isDarkTheme ? Colors.white : MyTheme.topicColor(IndicatorTopic.economy).shade400,
IndicatorTopic
.economy)
.shade400,
width: 1, width: 1,
), ),
), ),
@ -1172,9 +1186,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'ar' 'ar'
? 12 ? 12
: 14, : 14,
color: Color( color: isDarkTheme ? Color(0xFFEEEEEE) : Color(0xFF898C81), // Change to your desired color
0xFF898C81,
), // Change to your desired color
), ),
children: [ children: [
TextSpan( TextSpan(
@ -1201,8 +1213,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
fontWeight: fontWeight:
FontWeight FontWeight
.bold, .bold,
color: Color( color:isDarkTheme ? Color(0xFF9EB3E4) : Color(0xFF985400),
0xFF985400),
// Makes the text bold // Makes the text bold
// decoration: // decoration:
// TextDecoration.underline, // TextDecoration.underline,
@ -1221,8 +1232,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Color( color: isDarkTheme ? Color(0xFFEEEEEE) : Color(0xFF898C81),
0xFF898C81), // Change to your desired color
), ),
), ),
TextSpan( TextSpan(
@ -1248,8 +1258,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'ar' 'ar'
? 12 ? 12
: 14, : 14,
color: Color( color: isDarkTheme ? Color(0xFF9EB3E4) : Color(0xFF985400),
0xFF985400),
// decoration: // decoration:
// TextDecoration.underline, // TextDecoration.underline,
decorationColor: decorationColor:
@ -1274,8 +1283,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'ar' 'ar'
? 12 ? 12
: 14, : 14,
color: Color( color: isDarkTheme ? Color(0xFFEEEEEE) : Color( 0xFF898C81), // Change to your desired color
0xFF898C81), // Change to your desired color
), ),
), ),
], ],
@ -1312,7 +1320,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Color(0xFFb22222), color: isDarkTheme ? Color(0xFFFFA200) : Color(0xFFb22222),
fontSize: registerLocale fontSize: registerLocale
?.languageCode == ?.languageCode ==
'ar' 'ar'
@ -1337,8 +1345,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
? null ? null
: _registerUser, : _registerUser,
style: ElevatedButton.styleFrom( style: ElevatedButton.styleFrom(
backgroundColor: Color( backgroundColor: isDarkTheme ? Color(0xFF9EB3E4) : Color(0xFFA7887A), // Brownish color for Register
0xFFA7887A), // Brownish color for Register
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
@ -1362,14 +1369,14 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'ar' 'ar'
? 14 ? 14
: 16, : 16,
color: Colors.white), color: isDarkTheme ? Color(0xFF000000) : Colors.white
),
), ),
SizedBox(width: 8), SizedBox(width: 8),
const Icon( Icon(
Icons Icons
.chevron_right_outlined, .chevron_right_outlined,
color: Colors color: isDarkTheme ? Color(0xFF000000) : Colors.white, // Set your desired color here
.white, // Set your desired color here
) )
], ],
), ),
@ -1391,7 +1398,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'ar' 'ar'
? 12 ? 12
: 14, : 14,
color: Color(0xFF898C81), color: isDarkTheme ? Color(0xFFEEEEEE) : Color(0xFF898C81),
), ),
), ),
SizedBox(height: 15), SizedBox(height: 15),
@ -1408,8 +1415,7 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
context.pop(); context.pop();
}, },
style: ElevatedButton.styleFrom( style: ElevatedButton.styleFrom(
backgroundColor: Color( backgroundColor: isDarkTheme ? Color(0xFF24B4FB) : Color(0xFF82AFCB), // Blueish color for Login
0xFF82AFCB), // Blueish color for Login
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
borderRadius: borderRadius:
BorderRadius.circular(10), BorderRadius.circular(10),
@ -1432,14 +1438,13 @@ class _RegisterScreenState extends ConsumerState<RegisterScreen> {
'ar' 'ar'
? 14 ? 14
: 16, : 16,
color: Colors.white), color: isDarkTheme ? Color(0xFF000000) : Colors.white),
), ),
SizedBox(width: 8), SizedBox(width: 8),
const Icon( Icon(
Icons Icons
.chevron_right_outlined, .chevron_right_outlined,
color: Colors color: isDarkTheme ? Color(0xFF000000) : Colors.white, // Set your desired color here
.white, // Set your desired color here
) )
], ],
), ),

View File

@ -7,7 +7,7 @@ import 'package:uae_stat/presentation/routes/drawer_routes/custom_drawer_routes.
class TermsOfUse extends StatelessWidget { class TermsOfUse extends StatelessWidget {
TermsOfUse({super.key}); TermsOfUse({super.key});
final fcscBanner = Image.asset( final fcscBanner = Image.asset(
BannerAssetPath.fcsc, BannerAssetPath.fcscLogoLight,
height: 40, height: 40,
alignment: Alignment.center, alignment: Alignment.center,
); );

View File

@ -13,6 +13,7 @@ import 'package:shared_preferences/shared_preferences.dart';
import 'package:tutorial_coach_mark/tutorial_coach_mark.dart'; import 'package:tutorial_coach_mark/tutorial_coach_mark.dart';
import 'package:uae_stat/config/api_config.dart'; import 'package:uae_stat/config/api_config.dart';
import 'package:uae_stat/config/connectivity_provider.dart'; import 'package:uae_stat/config/connectivity_provider.dart';
import 'package:uae_stat/config/theme/theme_provider.dart';
import 'package:uae_stat/config/toast_util.dart'; import 'package:uae_stat/config/toast_util.dart';
import 'package:uae_stat/config/toggle_lang_service.dart'; import 'package:uae_stat/config/toggle_lang_service.dart';
import 'package:uae_stat/domain/use_cases/language.dart'; import 'package:uae_stat/domain/use_cases/language.dart';
@ -97,9 +98,11 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
bool isBookmarked = false; // Track bookmark state bool isBookmarked = false; // Track bookmark state
String? bookmarkId; // Stores the ID of the bookmark record in PocketBase String? bookmarkId; // Stores the ID of the bookmark record in PocketBase
late final Locale locale; late final Locale locale;
late ThemeMode currentTheme;
late String mainTopic; late String mainTopic;
late UserService _userService; late UserService _userService;
late double tourCard; late double tourCard;
late bool isDarkTheme;
@override @override
void initState() { void initState() {
@ -110,9 +113,17 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
checkIfBookmarked(); checkIfBookmarked();
locale = ref.read(localeProvider) ?? const Locale('en'); locale = ref.read(localeProvider) ?? const Locale('en');
print('locale-$locale'); print('locale-$locale');
currentTheme = ref.read(themeProvider);
print('123456789');
print(currentTheme);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeMode = (isDark ? 'dark' : 'light');
fetchChartData(widget.dataSets, locale?.languageCode ?? 'en', widget.kpi, fetchChartData(widget.dataSets, locale?.languageCode ?? 'en', widget.kpi,
widget.filter_data) widget.filter_data,themeMode)
.then((_) { .then((_) {
if (_tabsData.isNotEmpty) { if (_tabsData.isNotEmpty) {
// Call onTabSelected for the first tab // Call onTabSelected for the first tab
@ -1399,9 +1410,9 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
}); });
} }
Future<void> fetchChartData(String dataSets, locale, kpi, filter_data) async { Future<void> fetchChartData(String dataSets, locale, kpi, filter_data,themeMode) async {
var data = var data =
await apiService.fetchChartData(dataSets, locale, kpi, filter_data); await apiService.fetchChartData(dataSets, locale, kpi, filter_data,themeMode);
tabFilteredKpi = kpi; tabFilteredKpi = kpi;
print('FETCH KPI- $kpi'); print('FETCH KPI- $kpi');
@ -1502,12 +1513,19 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
print('locale2- $locale'); print('locale2- $locale');
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeMode = (isDark ? 'dark' : 'light');
// Call fetchChartData with correct parameters // Call fetchChartData with correct parameters
fetchChartData( fetchChartData(
widget.dataSets, widget.dataSets,
locale, locale,
tabWiseKpi, // Ensure you are passing the correct KPI here tabWiseKpi, // Ensure you are passing the correct KPI here
formattedFilters // Pass the formatted filter data here formattedFilters, // Pass the formatted filter data here
themeMode
); );
// Navigator.pop(context); // Navigator.pop(context);
@ -1677,7 +1695,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
child: Container( child: Container(
width: MediaQuery.of(context).size.width * 0.7, width: MediaQuery.of(context).size.width * 0.7,
height: MediaQuery.of(context).size.height, height: MediaQuery.of(context).size.height,
color: Colors.white, color: isDarkTheme ? Color(0xFF111111) : Colors.white,
child: Column( child: Column(
children: [ children: [
// Header Section // Header Section
@ -1693,7 +1711,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
UaeNumbersAssetPath.filterCharts, UaeNumbersAssetPath.filterCharts,
semanticsLabel: 'Filter', semanticsLabel: 'Filter',
colorFilter: ColorFilter.mode( colorFilter: ColorFilter.mode(
Color(0xFF8E8E8E), BlendMode.srcIn), isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF8E8E8E), BlendMode.srcIn),
width: 25, width: 25,
height: 25, height: 25,
), ),
@ -1704,7 +1722,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
'المرشحات', 'المرشحات',
), ),
style: TextStyle( style: TextStyle(
color: Color(0xFF8E8E8E), color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF8E8E8E),
fontSize: 20, fontSize: 20,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
fontFamily: context.translate( fontFamily: context.translate(
@ -1763,7 +1781,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Color(0xFF8E8E8E), color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF8E8E8E),
), ),
), ),
InkWell( InkWell(
@ -1838,7 +1856,9 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
) ),
color: isDarkTheme ? Color(0xFFFFFFFF) : null,
), ),
), ),
), ),
@ -1868,7 +1888,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
// "${locale == 'ar' ? 'يختار ' : 'Select '}" // "${locale == 'ar' ? 'يختار ' : 'Select '}"
"${context.translate(filter_text_and_order['en'], filter_text_and_order['ar'])}", "${context.translate(filter_text_and_order['en'], filter_text_and_order['ar'])}",
style: TextStyle( style: TextStyle(
color: Colors.grey, color: isDarkTheme ? Color(0xFFFFFFFF) : Colors.grey,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1931,12 +1951,18 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
ref.watch(localeProvider)?.languageCode ?? 'en'; ref.watch(localeProvider)?.languageCode ?? 'en';
print('locale22- $locale'); print('locale22- $locale');
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeMode = (isDark ? 'dark' : 'light');
fetchChartData( fetchChartData(
widget.dataSets, widget.dataSets,
locale, locale,
tabWiseKpi, // Ensure you are passing the correct KPI here tabWiseKpi, // Ensure you are passing the correct KPI here
formattedFilters // Pass the formatted filter data here formattedFilters, // Pass the formatted filter data here
themeMode
); );
Navigator.pop(context); Navigator.pop(context);
}, },
@ -1993,12 +2019,17 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
ref.watch(localeProvider)?.languageCode ?? 'en'; ref.watch(localeProvider)?.languageCode ?? 'en';
print('locale22- $locale'); print('locale22- $locale');
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeMode = (isDark ? 'dark' : 'light');
fetchChartData( fetchChartData(
widget.dataSets, widget.dataSets,
locale, locale,
tabWiseKpi, // Ensure you are passing the correct KPI here tabWiseKpi, // Ensure you are passing the correct KPI here
formattedFilters // Pass the formatted filter data here formattedFilters, // Pass the formatted filter data here
themeMode
); );
Navigator.pop(context); Navigator.pop(context);
} else { } else {
@ -2310,6 +2341,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
// return 1.0; // Default fallback (should never be reached) // return 1.0; // Default fallback (should never be reached)
// } // }
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
final locale = ref.watch(localeProvider); final locale = ref.watch(localeProvider);
@ -2342,10 +2374,17 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
currentTab = tabWiseKpi; currentTab = tabWiseKpi;
print('Saving currentTab: $currentTab After locale change'); print('Saving currentTab: $currentTab After locale change');
final currentTheme = ref.read(themeProvider);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeString = isDark ? 'dark' : 'light';
final List<Map<String, dynamic>> safeFilterData = final List<Map<String, dynamic>> safeFilterData =
widget.filter_data ?? []; widget.filter_data ?? [];
final String safeKpi = widget.kpi ?? ''; final String safeKpi = widget.kpi ?? '';
fetchChartData(widget.dataSets, localeCode, safeKpi, safeFilterData) fetchChartData(widget.dataSets, localeCode, safeKpi, safeFilterData,themeString)
.then((_) { .then((_) {
print('DEBUG KPI: $safeKpi'); print('DEBUG KPI: $safeKpi');
@ -2362,6 +2401,55 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
} }
}); });
}); });
ref.listen<ThemeMode>(themeProvider, (previous, next) async {
final localeCode = ref.watch(localeProvider)?.languageCode ?? 'en';
print(localeCode);
// Default to 'en' if null
setState(() {
isLoading = true;
print('isLoadingref $isLoading');
});
// fetchChartData(widget.dataSets, localeCode);
print('Saving currentTab: $tabWiseKpi before locale change');
print('localeCodeWgt- $localeCode');
currentTab = tabWiseKpi;
print('Saving currentTab: $currentTab After locale change');
final currentTheme = ref.read(themeProvider);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeString = isDark ? 'dark' : 'light';
final List<Map<String, dynamic>> safeFilterData =
widget.filter_data ?? [];
final String safeKpi = widget.kpi ?? '';
/// 🔥 Call your API
fetchChartData(widget.dataSets, localeCode, safeKpi, safeFilterData, themeString)
.then((_) {
print('DEBUG KPI: $safeKpi');
print('TAB11: $currentTab');
if (currentTab.isNotEmpty) {
onTabSelected(currentTab);
print('TAB1: $currentTab');
} else if (_tabsData.isNotEmpty) {
print('TAB2: $_tabsData');
onTabSelected(_tabsData[0]['id']);
}
});
});
final themeMode = ref.watch(themeProvider);
isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
double myheight = MediaQuery.of(context).size.height; double myheight = MediaQuery.of(context).size.height;
double mywidth = MediaQuery.of(context).size.width; double mywidth = MediaQuery.of(context).size.width;
mainTopic = chartScreenData['main_topic'] ?? ''; mainTopic = chartScreenData['main_topic'] ?? '';
@ -2763,7 +2851,8 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
child: CardWidget( child: CardWidget(
card: card, card: card,
chartScreenData: chartScreenData:
chartScreenData)), chartScreenData,
themeMode: themeMode)),
], ],
)); ));
} else { } else {
@ -2771,7 +2860,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
child: CardWidget( child: CardWidget(
card: card, card: card,
chartScreenData: chartScreenData:
chartScreenData))); chartScreenData,themeMode: themeMode)));
if (tempRow.length == 2) { if (tempRow.length == 2) {
rows.add(Row(children: tempRow)); rows.add(Row(children: tempRow));
tempRow = []; tempRow = [];
@ -2796,6 +2885,21 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
shrinkWrap: true, shrinkWrap: true,
physics: const NeverScrollableScrollPhysics(), physics: const NeverScrollableScrollPhysics(),
itemBuilder: (context, index) { itemBuilder: (context, index) {
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final Map<String, Color> mainTopicColors = {
'ECONOMY': Color(0xFF071F3B),
'SOCIAL': Color(0xFF4F241B),
'ENVIRONMENT': Color(0xFF16523C),
};
final String mainTopic = chartScreenData['main_topic'];
final Color backgroundColor = isDarkTheme
? (mainTopicColors[mainTopic] ?? Colors.white) // fallback if key not found
: Colors.white;
return Card( return Card(
margin: const EdgeInsets.all(10), margin: const EdgeInsets.all(10),
child: Container( child: Container(
@ -2811,7 +2915,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
), // Border color ), // Border color
width: 1, // Border width width: 1, // Border width
), ),
color: Colors.white, color: backgroundColor,
borderRadius: BorderRadius.circular( borderRadius: BorderRadius.circular(
8), // Optional: Rounded corners 8), // Optional: Rounded corners
), ),
@ -2858,7 +2962,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
chartData: chartData:
chartsData[index], chartsData[index],
bodyColor: bodyColor, bodyColor: bodyColor,
chartHeader: chartHeader), chartHeader: chartHeader,isDarkTheme: isDarkTheme),
) )
], ],
), ),
@ -2876,7 +2980,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
), ),
if (isLoading) if (isLoading)
Container( Container(
color: Color(0x98FFFCE5), // Semi-transparent background color: isDarkTheme ? Colors.transparent : Color(0x98FFFCE5), // Semi-transparent background
child: Column( child: Column(
mainAxisAlignment: MainAxisAlignment.center, mainAxisAlignment: MainAxisAlignment.center,
children: [ children: [
@ -2885,8 +2989,7 @@ class _ChartScreen1State extends ConsumerState<ChartScreen1> {
horizontal: 40), // Left & Right space horizontal: 40), // Left & Right space
child: LinearProgressIndicator( child: LinearProgressIndicator(
minHeight: 5, // Adjust thickness minHeight: 5, // Adjust thickness
backgroundColor: backgroundColor: isDarkTheme ? Colors.transparent : Colors.grey[100], // Optional: Background color
Colors.grey[100], // Optional: Background color
valueColor: AlwaysStoppedAnimation<Color>( valueColor: AlwaysStoppedAnimation<Color>(
Color(0xFFAA8E83)), // Loader color Color(0xFFAA8E83)), // Loader color
), ),
@ -2972,9 +3075,10 @@ Color _getColorFromHex(String hexColor) {
class CardWidget extends StatelessWidget { class CardWidget extends StatelessWidget {
final Map<String, dynamic> card; final Map<String, dynamic> card;
final Map<String, dynamic> chartScreenData; final Map<String, dynamic> chartScreenData;
final themeMode;
const CardWidget( const CardWidget(
{Key? key, required this.card, required this.chartScreenData}) {Key? key, required this.card, required this.chartScreenData,required this.themeMode})
: super(key: key); : super(key: key);
@override @override
@ -2995,6 +3099,23 @@ class CardWidget extends StatelessWidget {
), ),
); );
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final Map<String, Color> mainTopicColors = {
'ECONOMY': Color(0xFF071F3B),
'SOCIAL': Color(0xFF4F241B),
'ENVIRONMENT': Color(0xFF16523C),
};
final String mainTopic = chartScreenData['main_topic'];
final Color backgroundColor = isDarkTheme
? (mainTopicColors[mainTopic] ?? Colors.white) // fallback if key not found
: Colors.white;
if (response.isEmpty) { if (response.isEmpty) {
return SizedBox.shrink(); return SizedBox.shrink();
} else if (response.length == 1) { } else if (response.length == 1) {
@ -3010,6 +3131,7 @@ class CardWidget extends StatelessWidget {
// Dynamic border color // Dynamic border color
width: 1, // Adjust border thickness width: 1, // Adjust border thickness
), ),
), ),
child: Card( child: Card(
margin: const EdgeInsets.all(0), margin: const EdgeInsets.all(0),
@ -3023,7 +3145,7 @@ class CardWidget extends StatelessWidget {
padding: const EdgeInsets.only( padding: const EdgeInsets.only(
left: 16.0, right: 16.0, bottom: 2.0, top: 1.0), left: 16.0, right: 16.0, bottom: 2.0, top: 1.0),
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.white, // Move color inside BoxDecoration color: backgroundColor, // Move color inside BoxDecoration
borderRadius: BorderRadius.circular( borderRadius: BorderRadius.circular(
12), // Ensure border radius is applied 12), // Ensure border radius is applied
), ),
@ -3061,7 +3183,9 @@ class CardWidget extends StatelessWidget {
), ),
child: Text( child: Text(
chart_heading ?? 'NA', chart_heading ?? 'NA',
style: TextStyle(color: Colors.white, fontFamily: context.translate( style: TextStyle(
color: Colors.white,
fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),), ),),
@ -3087,7 +3211,7 @@ class CardWidget extends StatelessWidget {
), ),
fontSize: 11, fontSize: 11,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
color: Colors.black87, color: isDarkTheme ? Color(0xFFFFFFFF) : Colors.black87,
), ),
), ),
), ),
@ -3170,7 +3294,7 @@ class CardWidget extends StatelessWidget {
// padding: const EdgeInsets.only( // padding: const EdgeInsets.only(
// left: 10.0, right: 10.0, bottom: 5.0, top: 1.0), // left: 10.0, right: 10.0, bottom: 5.0, top: 1.0),
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.white, // Move color inside BoxDecoration color: backgroundColor, // Move color inside BoxDecoration
borderRadius: borderRadius:
BorderRadius.circular(12), // Ensure border radius is applied BorderRadius.circular(12), // Ensure border radius is applied
), ),
@ -3209,7 +3333,10 @@ class CardWidget extends StatelessWidget {
child: Text( child: Text(
chart_heading ?? 'NA', chart_heading ?? 'NA',
style: style:
TextStyle(color: Colors.white, fontSize: 10, fontFamily: context.translate( TextStyle(
color: Colors.white,
fontSize: 10,
fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),), ),),
@ -3235,7 +3362,7 @@ class CardWidget extends StatelessWidget {
), ),
fontSize: 11, fontSize: 11,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
color: Colors.black87, color: isDarkTheme ? Color(0xFFFFFFFF) : Colors.black87,
), ),
), ),
), ),

View File

@ -17,7 +17,7 @@ class ApiService {
static const String baseUrl = '$apiUrl/api/getDataSet'; static const String baseUrl = '$apiUrl/api/getDataSet';
Future<Map<String, dynamic>> fetchChartData(String dataSets, locale, kpi, Future<Map<String, dynamic>> fetchChartData(String dataSets, locale, kpi,
List<Map<String, dynamic>> filterData) async { List<Map<String, dynamic>> filterData,themeMode) async {
List<dynamic> isChartData = []; List<dynamic> isChartData = [];
List<dynamic> nonChartData = []; List<dynamic> nonChartData = [];
List<dynamic> originalChartsData = []; List<dynamic> originalChartsData = [];
@ -36,11 +36,13 @@ class ApiService {
'kpi': kpi.isNotEmpty ? kpi : null, // Avoid sending empty kpi 'kpi': kpi.isNotEmpty ? kpi : null, // Avoid sending empty kpi
'filter_data': 'filter_data':
filterData.isNotEmpty ? filterData : [], // Avoid empty list filterData.isNotEmpty ? filterData : [], // Avoid empty list
'color_mode' : themeMode,
}; };
// final url = Uri.https('$baseUrl?dataset=$dataSets&language=$locale'); // final url = Uri.https('$baseUrl?dataset=$dataSets&language=$locale');
print('APISErvice - $url'); print('APISErvice - $url');
print('requestBody: $requestBody');
try { try {
final response = await http.post( final response = await http.post(

View File

@ -15,10 +15,12 @@ class ChartWidget extends StatelessWidget {
required this.chartData, required this.chartData,
required this.bodyColor, required this.bodyColor,
required this.chartHeader, required this.chartHeader,
required this.isDarkTheme
}) : super(key: key); }) : super(key: key);
final dynamic chartData; final dynamic chartData;
final Color bodyColor; final Color bodyColor;
final String chartHeader; final String chartHeader;
final isDarkTheme;
List<int> showingTooltipOnSpots = []; // To store indices of active tooltips List<int> showingTooltipOnSpots = []; // To store indices of active tooltips
late LineChartBarData tooltipsOnBar; // Needs proper initialization late LineChartBarData tooltipsOnBar; // Needs proper initialization
@ -336,7 +338,7 @@ class ChartWidget extends StatelessWidget {
), ),
fontSize: isTouched ? 12 : (percentage < 1 ? 10 : 11), fontSize: isTouched ? 12 : (percentage < 1 ? 10 : 11),
fontWeight: FontWeight.bold, fontWeight: FontWeight.bold,
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
// color: Colors.white, // color: Colors.white,
), ),
// titlePositionPercentageOffset: 1.4, // titlePositionPercentageOffset: 1.4,
@ -514,7 +516,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle(fontFamily: context.translate( style: TextStyle(fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),fontSize: 12), ),fontSize: 12,color: isDarkTheme ? Colors.white : null),
softWrap: true, softWrap: true,
maxLines: 2, maxLines: 2,
), ),
@ -706,7 +708,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle(fontFamily: context.translate( style: TextStyle(fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),fontSize: 14, fontWeight: FontWeight.w400), ),fontSize: 14, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
SizedBox(height: 15), SizedBox(height: 15),
@ -807,7 +809,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle(fontFamily: context.translate( style: TextStyle(fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),fontSize: 14, fontWeight: FontWeight.w400), ),fontSize: 14, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
SizedBox(height: 5), SizedBox(height: 5),
@ -1198,7 +1200,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle(fontFamily: context.translate( style: TextStyle(fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),fontSize: 14, fontWeight: FontWeight.w400), ),fontSize: 14, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
SizedBox(height: 5), SizedBox(height: 5),
@ -1432,7 +1434,7 @@ class ChartWidget extends StatelessWidget {
}); });
return Scaffold( return Scaffold(
backgroundColor: Colors.white, backgroundColor: isDarkTheme ? Colors.transparent : Colors.white,
body: Padding( body: Padding(
padding: const EdgeInsets.all(10), padding: const EdgeInsets.all(10),
child: LayoutBuilder( child: LayoutBuilder(
@ -1464,7 +1466,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle( style: TextStyle(
fontFamily: context.translate('Roboto', 'NotoKufi'), fontFamily: context.translate('Roboto', 'NotoKufi'),
fontSize: 14, fontSize: 14,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black,
), ),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
@ -1487,8 +1489,8 @@ class ChartWidget extends StatelessWidget {
sideTitles: SideTitles( sideTitles: SideTitles(
showTitles: true, showTitles: true,
getTitlesWidget: (value, meta) { getTitlesWidget: (value, meta) {
const style = TextStyle( var style = TextStyle(
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
fontSize: 10, fontSize: 10,
); );
@ -1501,7 +1503,7 @@ class ChartWidget extends StatelessWidget {
Container( Container(
width: 1, width: 1,
height: 8, height: 8,
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
margin: EdgeInsets.only(bottom: 2), margin: EdgeInsets.only(bottom: 2),
), ),
Text(value.toInt().toString(), style: style), Text(value.toInt().toString(), style: style),
@ -1528,9 +1530,9 @@ class ChartWidget extends StatelessWidget {
), ),
borderData: FlBorderData( borderData: FlBorderData(
show: true, show: true,
border: const Border( border: Border(
left: BorderSide.none, left: BorderSide.none,
bottom: BorderSide(color: Colors.black), bottom: BorderSide(color: isDarkTheme ? Colors.white : Colors.black),
), ),
), ),
gridData: FlGridData(show: false), gridData: FlGridData(show: false),
@ -1546,7 +1548,7 @@ class ChartWidget extends StatelessWidget {
// if (x == minX || x == maxX) return null; // if (x == minX || x == maxX) return null;
return LineTooltipItem( return LineTooltipItem(
formatNumber(spot.y), formatNumber(spot.y),
const TextStyle(color: Colors.white), TextStyle(color: isDarkTheme ? Colors.white : Colors.white),
); );
}).toList(); }).toList();
}, },
@ -1576,7 +1578,7 @@ class ChartWidget extends StatelessWidget {
fontSize: 9, fontSize: 9,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
// color: color, // color: color,
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
), ),
), ),
) )
@ -1804,7 +1806,7 @@ class ChartWidget extends StatelessWidget {
}); });
return Scaffold( return Scaffold(
backgroundColor: Colors.white, backgroundColor: isDarkTheme ? Colors.transparent : Colors.white,
body: Padding( body: Padding(
padding: const EdgeInsets.all(10), padding: const EdgeInsets.all(10),
child: LayoutBuilder( child: LayoutBuilder(
@ -1836,7 +1838,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle( style: TextStyle(
fontFamily: context.translate('Roboto', 'NotoKufi'), fontFamily: context.translate('Roboto', 'NotoKufi'),
fontSize: 14, fontSize: 14,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black,
), ),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
@ -1859,8 +1861,8 @@ class ChartWidget extends StatelessWidget {
sideTitles: SideTitles( sideTitles: SideTitles(
showTitles: true, showTitles: true,
getTitlesWidget: (value, meta) { getTitlesWidget: (value, meta) {
const style = TextStyle( var style = TextStyle(
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
fontSize: 10, fontSize: 10,
); );
@ -1873,7 +1875,7 @@ class ChartWidget extends StatelessWidget {
Container( Container(
width: 1, width: 1,
height: 8, height: 8,
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
margin: EdgeInsets.only(bottom: 2), margin: EdgeInsets.only(bottom: 2),
), ),
Text(value.toInt().toString(), style: style), Text(value.toInt().toString(), style: style),
@ -1900,9 +1902,9 @@ class ChartWidget extends StatelessWidget {
), ),
borderData: FlBorderData( borderData: FlBorderData(
show: true, show: true,
border: const Border( border: Border(
left: BorderSide.none, left: BorderSide.none,
bottom: BorderSide(color: Colors.black), bottom: BorderSide(color: isDarkTheme ? Colors.white : Colors.black),
), ),
), ),
gridData: FlGridData(show: false), gridData: FlGridData(show: false),
@ -1929,7 +1931,7 @@ class ChartWidget extends StatelessWidget {
} }
return LineTooltipItem( return LineTooltipItem(
formatNumber(spot.y), formatNumber(spot.y),
const TextStyle(color: Colors.white), TextStyle(color: isDarkTheme ? Colors.white : Colors.white),
); );
}).toList(); }).toList();
}, },
@ -1959,7 +1961,7 @@ class ChartWidget extends StatelessWidget {
fontSize: 9, fontSize: 9,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
// color: color, // color: color,
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
), ),
), ),
) )
@ -2105,7 +2107,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle(fontFamily: context.translate( style: TextStyle(fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),fontSize: 14, fontWeight: FontWeight.w400), ),fontSize: 14, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
SizedBox(height: 5), SizedBox(height: 5),
@ -2219,7 +2221,7 @@ class ChartWidget extends StatelessWidget {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
fontSize: 12, fontSize: 12,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
), ),
@ -2460,7 +2462,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle(fontFamily: context.translate( style: TextStyle(fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),fontSize: 14, fontWeight: FontWeight.w400), ),fontSize: 14, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
// SizedBox(height: 5), // SizedBox(height: 5),
@ -2511,7 +2513,7 @@ class ChartWidget extends StatelessWidget {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
fontSize: 12, fontSize: 12,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
), ),
@ -2712,7 +2714,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle(fontFamily: context.translate( style: TextStyle(fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),fontSize: 14, fontWeight: FontWeight.w400), ),fontSize: 14, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
SizedBox(height: 5), SizedBox(height: 5),
@ -3028,7 +3030,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle(fontFamily: context.translate( style: TextStyle(fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),fontSize: 14, fontWeight: FontWeight.w400), ),fontSize: 14, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
SizedBox(height: 5), SizedBox(height: 5),
@ -3208,7 +3210,7 @@ class ChartWidget extends StatelessWidget {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
fontSize: 12, fontSize: 12,
), ),
); );
@ -3240,7 +3242,7 @@ class ChartWidget extends StatelessWidget {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
fontSize: 12, fontSize: 12,
), ),
); );
@ -3529,7 +3531,7 @@ class ChartWidget extends StatelessWidget {
}); });
return Scaffold( return Scaffold(
backgroundColor: Colors.white, backgroundColor: isDarkTheme ? Colors.transparent : Colors.white,
body: Padding( body: Padding(
padding: const EdgeInsets.all(10), padding: const EdgeInsets.all(10),
child: LayoutBuilder( child: LayoutBuilder(
@ -3561,7 +3563,7 @@ class ChartWidget extends StatelessWidget {
style: TextStyle( style: TextStyle(
fontFamily: context.translate('Roboto', 'NotoKufi'), fontFamily: context.translate('Roboto', 'NotoKufi'),
fontSize: 14, fontSize: 14,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,color: isDarkTheme ? Colors.white : Colors.black,
), ),
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
@ -3584,8 +3586,8 @@ class ChartWidget extends StatelessWidget {
sideTitles: SideTitles( sideTitles: SideTitles(
showTitles: true, showTitles: true,
getTitlesWidget: (value, meta) { getTitlesWidget: (value, meta) {
const style = TextStyle( var style = TextStyle(
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
fontSize: 10, fontSize: 10,
); );
@ -3598,7 +3600,7 @@ class ChartWidget extends StatelessWidget {
Container( Container(
width: 1, width: 1,
height: 8, height: 8,
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
margin: EdgeInsets.only(bottom: 2), margin: EdgeInsets.only(bottom: 2),
), ),
Text(value.toInt().toString(), style: style), Text(value.toInt().toString(), style: style),
@ -3625,9 +3627,9 @@ class ChartWidget extends StatelessWidget {
), ),
borderData: FlBorderData( borderData: FlBorderData(
show: true, show: true,
border: const Border( border: Border(
left: BorderSide.none, left: BorderSide.none,
bottom: BorderSide(color: Colors.black), bottom: BorderSide(color: isDarkTheme ? Colors.white : Colors.black),
), ),
), ),
gridData: FlGridData(show: false), gridData: FlGridData(show: false),
@ -3643,7 +3645,7 @@ class ChartWidget extends StatelessWidget {
// if (x == minX || x == maxX) return null; // if (x == minX || x == maxX) return null;
return LineTooltipItem( return LineTooltipItem(
formatNumber(spot.y), formatNumber(spot.y),
const TextStyle(color: Colors.white), TextStyle(color: isDarkTheme ? Colors.white : Colors.white),
); );
}).toList(); }).toList();
}, },
@ -3719,7 +3721,7 @@ class ChartWidget extends StatelessWidget {
fontSize: 9, fontSize: 9,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
// color: color, // color: color,
color: Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
), ),
), ),
) )

View File

@ -13,7 +13,7 @@ TextStyle subtitleStyle(BuildContext context) {
color: const Color(0xFF8E8E8E), color: const Color(0xFF8E8E8E),
); );
} }
TextStyle robotoRegular11(BuildContext context) TextStyle robotoRegular11(BuildContext context,isDarkTheme)
{return TextStyle(fontFamily: context.translate('Roboto', 'NotoKufi'), {return TextStyle(fontFamily: context.translate('Roboto', 'NotoKufi'),
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
fontSize: 12 * 1.1,color: Color(0xFF000000),);} fontSize: 12 * 1.1,color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF000000),);}

View File

@ -100,7 +100,10 @@ extension Dialogs on BuildContext {
final contentText = Text(content); final contentText = Text(content);
return AlertDialog( return AlertDialog(
title: Text(title, title: Text(title,
style: TextStyle(color: Color(0xFF898C81),fontWeight: FontWeight.w700),), style: TextStyle(
color: Color(0xFF898C81),
fontWeight: FontWeight.w700)
),
content: content.length > 300 content: content.length > 300
? SingleChildScrollView( ? SingleChildScrollView(
child:Text( child:Text(

View File

@ -13,6 +13,11 @@ class ThemedFormField extends HookWidget {
required this.controller, required this.controller,
this.validator, this.validator,
this.isObscurable = false, this.isObscurable = false,
this.hintColor,
this.backgroundColor,
this.borderColor,
this.errorBorderColor,
this.errorTextColor,
}); });
final String hintText; final String hintText;
@ -20,6 +25,11 @@ class ThemedFormField extends HookWidget {
final String? Function(String? text)? validator; final String? Function(String? text)? validator;
final TextEditingController controller; final TextEditingController controller;
final bool isObscurable; final bool isObscurable;
final Color? hintColor;
final Color? backgroundColor;
final Color? borderColor;
final Color? errorBorderColor;
final Color? errorTextColor;
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
@ -49,25 +59,40 @@ class ThemedFormField extends HookWidget {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: errorTextColor ?? const Color(0xFFB22222),
),
errorBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(10),
borderSide: BorderSide(
color: errorBorderColor ?? const Color(0xFFB22222),
width: 1,
),
),
focusedErrorBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(10),
borderSide: BorderSide(
color: errorBorderColor ?? const Color(0xFFB22222),
width: 1,
),
), ),
filled: true, filled: true,
fillColor: Colors.white, fillColor: backgroundColor ?? Colors.white,
contentPadding: const EdgeInsets.symmetric(vertical: 14, horizontal: 15), contentPadding: const EdgeInsets.symmetric(vertical: 14, horizontal: 15),
border: OutlineInputBorder( border: OutlineInputBorder(
borderRadius: BorderRadius.circular(10), borderRadius: BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: MyTheme.topicColor(IndicatorTopic.economy).shade300, color: borderColor ?? MyTheme.topicColor(IndicatorTopic.economy).shade300,
), ),
), ),
enabledBorder: OutlineInputBorder( enabledBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(10), borderRadius: BorderRadius.circular(10),
borderSide: BorderSide( borderSide: BorderSide(
color: MyTheme.topicColor(IndicatorTopic.economy).shade300, color: borderColor ?? MyTheme.topicColor(IndicatorTopic.economy).shade300,
), ),
), ),
hintText: hintText, hintText: hintText,
hintStyle: const TextStyle( hintStyle: TextStyle( // dynamic hint color
color: Color(0xffC3C6CB), color: hintColor ?? const Color(0xffC3C6CB),
), ),
prefixIconConstraints: const BoxConstraints( prefixIconConstraints: const BoxConstraints(
maxWidth: 25 + 16 + 10, maxWidth: 25 + 16 + 10,

View File

@ -15,6 +15,9 @@ import 'package:the_validator/the_validator.dart';
import 'package:uae_stat/config/app_links_helper.dart'; import 'package:uae_stat/config/app_links_helper.dart';
import 'package:uae_stat/config/connectivity_provider.dart'; import 'package:uae_stat/config/connectivity_provider.dart';
import 'package:uae_stat/config/my_theme.dart'; import 'package:uae_stat/config/my_theme.dart';
import 'package:uae_stat/config/theme/app_theme.dart';
import 'package:uae_stat/config/theme/service.dart';
import 'package:uae_stat/config/theme/theme_provider.dart';
import 'package:uae_stat/domain/use_cases/auth_use_case.dart'; import 'package:uae_stat/domain/use_cases/auth_use_case.dart';
import 'package:uae_stat/domain/use_cases/language.dart'; import 'package:uae_stat/domain/use_cases/language.dart';
import 'package:uae_stat/infrastructure/services/img_asset_paths/banner_asset_path.dart'; import 'package:uae_stat/infrastructure/services/img_asset_paths/banner_asset_path.dart';
@ -312,6 +315,16 @@ class LoginRoute extends HookConsumerWidget {
} }
} }
Future<void> initializeTheme(BuildContext context,WidgetRef ref, String userId) async {
final themeService = ThemeBaseService();
final theme = await themeService.getUserTheme(userId); // e.g., "dark"
final platformBrightness = MediaQuery.of(context).platformBrightness;
ref.read(themeProvider.notifier).updateTheme(AppThemeExtension.fromString(theme),platformBrightness);
final themeMode = ref.watch(themeProvider);
print('themeMode Login');
print('themeMode $themeMode');
}
@override @override
Widget build(BuildContext context, WidgetRef ref) { Widget build(BuildContext context, WidgetRef ref) {
@ -321,6 +334,11 @@ class LoginRoute extends HookConsumerWidget {
} }
}); });
final themeMode = ref.read(themeProvider);
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
// useEffect(() { // useEffect(() {
// // Wait until first frame is rendered // // Wait until first frame is rendered
// Future.microtask(() { // Future.microtask(() {
@ -373,7 +391,7 @@ class LoginRoute extends HookConsumerWidget {
'NotoKufi', 'NotoKufi',
), ),
fontSize: locale?.languageCode == 'ar' ? 18 : 20, fontSize: locale?.languageCode == 'ar' ? 18 : 20,
color: Color(0xFF898C81), color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF898C81),
fontWeight: FontWeight.w600), fontWeight: FontWeight.w600),
), ),
content: Form( content: Form(
@ -387,6 +405,7 @@ class LoginRoute extends HookConsumerWidget {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: isDarkTheme ? Color(0xFFFFA100) : Colors.red,
), ),
labelText: context.translate( labelText: context.translate(
'Email address', 'Email address',
@ -398,9 +417,42 @@ class LoginRoute extends HookConsumerWidget {
'NotoKufi', 'NotoKufi',
), ),
fontSize: locale?.languageCode == 'ar' ? 13 : 16, fontSize: locale?.languageCode == 'ar' ? 13 : 16,
color: Color(0xFF898C81), // For label text color color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF898C81), // For label text color
// fontWeight: FontWeight.w600, // fontWeight: FontWeight.w600,
), ),
// Default Border
// Bottom border (no outline)
enabledBorder: UnderlineInputBorder(
borderSide: BorderSide(
color: isDarkTheme ? Colors.white : const Color(0xFF898C81),
width: 1,
),
),
focusedBorder: UnderlineInputBorder(
borderSide: BorderSide(
color: isDarkTheme ? const Color(0xFF24B4FB) : Colors.deepPurple,
width: 2,
),
),
errorBorder: UnderlineInputBorder(
borderSide: BorderSide(
color: isDarkTheme ? const Color(0xFFFFA100) : Colors.red,
width: 1,
),
),
focusedErrorBorder: UnderlineInputBorder(
borderSide: BorderSide(
color: isDarkTheme ? const Color(0xFFFFA100) : Colors.red,
width: 2,
),
),
), ),
), ),
), ),
@ -409,9 +461,10 @@ class LoginRoute extends HookConsumerWidget {
onPressed: Navigator.of(dialogCtx, rootNavigator: true).pop, onPressed: Navigator.of(dialogCtx, rootNavigator: true).pop,
style: TextButton.styleFrom( style: TextButton.styleFrom(
// backgroundColor: Colors.white, // Background color // backgroundColor: Colors.white, // Background color
foregroundColor: Color(0xFF92722A), // Font (text) color foregroundColor: isDarkTheme ? Color(0xFF24B4FB) : Color(0xFF92722A), // Font (text) color
side: BorderSide( side: BorderSide(
color: Color(0xFF92722A)), // Border outline color color: isDarkTheme ? Color(0xFF24B4FB) : Color(0xFF92722A)
), // Border outline color
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
borderRadius: borderRadius:
BorderRadius.circular(8), // Optional: Rounded corners BorderRadius.circular(8), // Optional: Rounded corners
@ -439,7 +492,7 @@ class LoginRoute extends HookConsumerWidget {
); );
}, },
style: ElevatedButton.styleFrom( style: ElevatedButton.styleFrom(
backgroundColor: Color(0xFF92722A), backgroundColor: isDarkTheme ? Color(0xFF24B4FB) : Color(0xFF92722A),
foregroundColor: Colors.white, foregroundColor: Colors.white,
padding: EdgeInsets.symmetric( padding: EdgeInsets.symmetric(
horizontal: 10 , vertical: 10), // Optional: Adjusts size horizontal: 10 , vertical: 10), // Optional: Adjusts size
@ -500,7 +553,7 @@ class LoginRoute extends HookConsumerWidget {
), ),
fontWeight: FontWeight.bold, fontWeight: FontWeight.bold,
fontSize: locale?.languageCode == 'ar' ? 12 : 14, fontSize: locale?.languageCode == 'ar' ? 12 : 14,
color: Color(0xFF985400), color: isDarkTheme ? Color(0xFF9EB3E4) : Color(0xFF985400),
), ),
), ),
); );
@ -605,6 +658,7 @@ class LoginRoute extends HookConsumerWidget {
await saveUserId(userId, loginCount); await saveUserId(userId, loginCount);
await getDeviceToken(context, userId); await getDeviceToken(context, userId);
await initializeTheme(context,ref,userId);
} }
try { try {
final bool isProfileComplete = await profileStatus(userId, ref); final bool isProfileComplete = await profileStatus(userId, ref);
@ -681,7 +735,8 @@ class LoginRoute extends HookConsumerWidget {
), ),
), ),
backgroundColor: WidgetStatePropertyAll( backgroundColor: WidgetStatePropertyAll(
MyTheme.topicColor(IndicatorTopic.social), isDarkTheme ? Color(0xFF24B4FB) : Color(0xFFAA8E83),
// MyTheme.topicColor(IndicatorTopic.social),
), ),
// surfaceTintColor: MaterialStatePropertyAll( // surfaceTintColor: MaterialStatePropertyAll(
// MyTheme.economy[800], // MyTheme.economy[800],
@ -705,12 +760,13 @@ class LoginRoute extends HookConsumerWidget {
), ),
fontSize: locale?.languageCode == 'ar' ? 12 : 18, fontSize: locale?.languageCode == 'ar' ? 12 : 18,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
color: isDarkTheme ? Color(0xFF000000) : null,
), ),
), ),
6.horizontalSpace, 6.horizontalSpace,
const Icon( Icon(
Icons.chevron_right_outlined, Icons.chevron_right_outlined,
color: Colors.white, // Set your desired color here color: isDarkTheme ? Color(0xFF000000) : Colors.white, // Set your desired color here
) )
], ],
), ),
@ -725,6 +781,11 @@ class LoginRoute extends HookConsumerWidget {
'Email', 'Email',
'بريد إلكتروني', 'بريد إلكتروني',
), ),
hintColor: isDarkTheme ? Color(0XFFEEEEEE) : Color(0xFFC3C6CB),
backgroundColor: isDarkTheme ? Color(0xFF000000) : Colors.white,
borderColor: isDarkTheme ? Colors.white : MyTheme.topicColor(IndicatorTopic.economy).shade300,
errorBorderColor: isDarkTheme ? const Color(0xFFFFA100) : const Color(0xFFB22222),
errorTextColor: isDarkTheme ? const Color(0xFFFFA100) : const Color(0xFFB22222),
validator: (value) { validator: (value) {
final emailRegex = final emailRegex =
r'^[a-zA-Z0-9àèìòùÀÈÌÒÙéàç~!#$%^&*()_+=-{}|;,.?<>]+@[a-zA-Z0-9àèìòùÀÈÌÒÙéàç~!#$%^&*()_+=-{}|;,.?<>]+\.[a-zA-Z]{2,}$'; r'^[a-zA-Z0-9àèìòùÀÈÌÒÙéàç~!#$%^&*()_+=-{}|;,.?<>]+@[a-zA-Z0-9àèìòùÀÈÌÒÙéàç~!#$%^&*()_+=-{}|;,.?<>]+\.[a-zA-Z]{2,}$';
@ -735,7 +796,7 @@ class LoginRoute extends HookConsumerWidget {
} }
return null; return null;
}, },
imgPath: MiscIconAssetPath.person, imgPath: isDarkTheme ? MiscIconAssetPath.personDark : MiscIconAssetPath.personLight,
controller: emailCtl, controller: emailCtl,
), ),
15.verticalSpace, 15.verticalSpace,
@ -752,7 +813,12 @@ class LoginRoute extends HookConsumerWidget {
'Password', 'Password',
'كلمة المرور', 'كلمة المرور',
), ),
imgPath: MiscIconAssetPath.lock, hintColor: isDarkTheme ? Color(0XFFEEEEEE) : Color(0xFFC3C6CB),
backgroundColor: isDarkTheme ? Color(0xFF000000) : Colors.white,
borderColor: isDarkTheme ? Colors.white : MyTheme.topicColor(IndicatorTopic.economy).shade300,
errorBorderColor: isDarkTheme ? const Color(0xFFFFA100) : const Color(0xFFB22222),
errorTextColor: isDarkTheme ? const Color(0xFFFFA100) : const Color(0xFFB22222),
imgPath: isDarkTheme ? MiscIconAssetPath.lockDark : MiscIconAssetPath.lockLight,
controller: pwCtl, controller: pwCtl,
isObscurable: true, isObscurable: true,
), ),
@ -783,6 +849,7 @@ class LoginRoute extends HookConsumerWidget {
), ),
fontSize: locale?.languageCode == 'ar' ? 38 : 40, fontSize: locale?.languageCode == 'ar' ? 38 : 40,
fontWeight: FontWeight.w300, fontWeight: FontWeight.w300,
color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF000000),
), ),
), ),
10.verticalSpace, 10.verticalSpace,
@ -798,7 +865,7 @@ class LoginRoute extends HookConsumerWidget {
'NotoKufi', 'NotoKufi',
), ),
fontSize: context.translate(18.0, 14.0), fontSize: context.translate(18.0, 14.0),
color: const Color(0xff898C81), color: isDarkTheme ? Color(0xFFEEEEEE) : Color(0xff898C81),
fontWeight: FontWeight.w600, fontWeight: FontWeight.w600,
), ),
), ),
@ -827,7 +894,7 @@ class LoginRoute extends HookConsumerWidget {
), ),
style: TextStyle( style: TextStyle(
fontSize: locale?.languageCode == 'ar' ? 12 : 14, fontSize: locale?.languageCode == 'ar' ? 12 : 14,
color: Color(0xff898C81), color: isDarkTheme ? Color(0xFFCCCCCC) : Color(0xff898C81),
), ),
), ),
const TextSpan( const TextSpan(
@ -840,7 +907,7 @@ class LoginRoute extends HookConsumerWidget {
), ),
style: TextStyle( style: TextStyle(
fontSize: locale?.languageCode == 'ar' ? 12 : 14, fontSize: locale?.languageCode == 'ar' ? 12 : 14,
color: Color(0xFF985400), color: isDarkTheme ? Color(0xFF9EB3E4) : Color(0xFF985400),
), ),
), ),
], ],
@ -903,7 +970,9 @@ class LoginRoute extends HookConsumerWidget {
// ), // ),
// ); // );
final fcscBanner = Image.asset( final fcscBanner = Image.asset(
BannerAssetPath.fcsc, isDarkTheme
? BannerAssetPath.fcscLogoDark
: BannerAssetPath.fcscLogoLight,
height: 40, height: 40,
); );
final screenWidth = MediaQuery.of(context).size.width; final screenWidth = MediaQuery.of(context).size.width;
@ -965,7 +1034,7 @@ class LoginRoute extends HookConsumerWidget {
// _showExitConfirmation(context); // Show exit confirmation dialog // _showExitConfirmation(context); // Show exit confirmation dialog
}, },
child: Scaffold( child: Scaffold(
backgroundColor: Colors.white, backgroundColor: isDarkTheme ? Color(0xFF111111) : Colors.white,
body: SafeArea(child: scaffoldBody), body: SafeArea(child: scaffoldBody),
), ),
); );

View File

@ -156,7 +156,7 @@ class RegisterRoute extends HookConsumerWidget {
'Password', 'Password',
'كلمة المرور', 'كلمة المرور',
), ),
imgPath: MiscIconAssetPath.lock, imgPath: MiscIconAssetPath.personLight,
controller: pwCtl, controller: pwCtl,
isObscurable: true, isObscurable: true,
); );
@ -167,7 +167,7 @@ class RegisterRoute extends HookConsumerWidget {
'Confirm Password', 'Confirm Password',
'كلمة المرور', 'كلمة المرور',
), ),
imgPath: MiscIconAssetPath.lock, imgPath: MiscIconAssetPath.personLight,
controller: cpwCtl, controller: cpwCtl,
isObscurable: true, isObscurable: true,
); );
@ -177,7 +177,7 @@ class RegisterRoute extends HookConsumerWidget {
'اسم المستخدم', 'اسم المستخدم',
), ),
validator: FieldValidator.email(), validator: FieldValidator.email(),
imgPath: MiscIconAssetPath.person, imgPath: MiscIconAssetPath.personLight,
controller: emailCtl, controller: emailCtl,
); );
final nameField = ThemedFormField( final nameField = ThemedFormField(
@ -187,7 +187,7 @@ class RegisterRoute extends HookConsumerWidget {
), ),
validator: (value) => validator: (value) =>
value!.isEmpty ? 'Name must be at least one character' : null, value!.isEmpty ? 'Name must be at least one character' : null,
imgPath: MiscIconAssetPath.person, imgPath: MiscIconAssetPath.personLight,
controller: nameCtl, controller: nameCtl,
); );
final form = Form( final form = Form(
@ -328,7 +328,7 @@ class RegisterRoute extends HookConsumerWidget {
), ),
); );
final fcscBanner = Image.asset( final fcscBanner = Image.asset(
BannerAssetPath.fcsc, BannerAssetPath.fcscLogoLight,
height: 56, height: 56,
); );
final screenWidth = MediaQuery.of(context).size.width; final screenWidth = MediaQuery.of(context).size.width;

View File

@ -170,6 +170,7 @@ import 'package:pocketbase/pocketbase.dart';
import 'package:shared_preferences/shared_preferences.dart'; import 'package:shared_preferences/shared_preferences.dart';
import 'package:uae_stat/config/api_config.dart'; import 'package:uae_stat/config/api_config.dart';
import 'package:uae_stat/config/connectivity_provider.dart'; import 'package:uae_stat/config/connectivity_provider.dart';
import 'package:uae_stat/config/theme/theme_provider.dart';
import 'package:uae_stat/config/toggle_lang_service.dart'; import 'package:uae_stat/config/toggle_lang_service.dart';
import 'package:uae_stat/domain/use_cases/language.dart'; import 'package:uae_stat/domain/use_cases/language.dart';
import 'package:uae_stat/infrastructure/data/p_auth_repo.dart'; import 'package:uae_stat/infrastructure/data/p_auth_repo.dart';
@ -380,6 +381,8 @@ class EconomyStatsState extends ConsumerState<EconomyStatsWidget> {
late List<TargetFocus> homeTargets; late List<TargetFocus> homeTargets;
late List<TargetFocus> previousHomeTargets; late List<TargetFocus> previousHomeTargets;
late final Locale locale; late final Locale locale;
late ThemeMode currentTheme;
// ThemeMode? _previousTheme;
Future<void> handleSkip() async { Future<void> handleSkip() async {
tutorialCoachMark.skip(); tutorialCoachMark.skip();
@ -1084,7 +1087,20 @@ class EconomyStatsState extends ConsumerState<EconomyStatsWidget> {
super.initState(); super.initState();
_userService = UserService(); _userService = UserService();
locale = ref.read(localeProvider) ?? const Locale('en'); locale = ref.read(localeProvider) ?? const Locale('en');
fetchData(locale?.languageCode ?? 'en'); // Listen to theme changes
// Defer the ref.listen to after build is completed
currentTheme = ref.read(themeProvider);
print('123456789');
print(currentTheme);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeMode = (isDark ? 'dark' : 'light');
fetchData(locale?.languageCode ?? 'en', themeMode);
// _fetchUserData(); // _fetchUserData();
_loadLoginCount(); _loadLoginCount();
} }
@ -1143,11 +1159,11 @@ class EconomyStatsState extends ConsumerState<EconomyStatsWidget> {
// } // }
// } // }
Future<void> fetchData(locale) async { Future<void> fetchData(locale,themeMode) async {
// const baseUrl = 'https://pb.venbait.in/api/getHomePageData'; // const baseUrl = 'https://pb.venbait.in/api/getHomePageData';
const baseUrl = '$apiUrl/api/getHomePageData'; const baseUrl = '$apiUrl/api/getHomePageData';
try { try {
final response = await http.get(Uri.parse(baseUrl + '?language=$locale')); final response = await http.get(Uri.parse(baseUrl + '?language=$locale&color_mode=$themeMode'));
if (response.statusCode == 200) { if (response.statusCode == 200) {
setState(() { setState(() {
data = json.decode(response.body); data = json.decode(response.body);
@ -1200,7 +1216,13 @@ class EconomyStatsState extends ConsumerState<EconomyStatsWidget> {
isLoading = true; isLoading = true;
}); });
await _userService.updateLanguage(localeCode); await _userService.updateLanguage(localeCode);
fetchData(localeCode); final currentTheme = ref.read(themeProvider);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeString = isDark ? 'dark' : 'light';
fetchData(localeCode,themeString);
}); });
final isConnected = ref.watch(connectivityProvider); final isConnected = ref.watch(connectivityProvider);
@ -1212,6 +1234,29 @@ class EconomyStatsState extends ConsumerState<EconomyStatsWidget> {
} }
}); });
ref.listen<ThemeMode>(themeProvider, (previous, next) async {
final localeCode = ref.watch(localeProvider)?.languageCode ?? 'en';
print(localeCode);
// Default to 'en' if null
setState(() {
isLoading = true;
print('isLoadingref $isLoading');
});
final currentTheme = ref.read(themeProvider);
final isDark = currentTheme == ThemeMode.dark ||
(currentTheme == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final themeString = isDark ? 'dark' : 'light';
fetchData(localeCode,themeString);
});
final isDarkTheme = ref.watch(themeProvider) == ThemeMode.dark ||
(ref.watch(themeProvider) == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
double myheight = MediaQuery.of(context).size.height; double myheight = MediaQuery.of(context).size.height;
double mywidth = MediaQuery.of(context).size.width; double mywidth = MediaQuery.of(context).size.width;
@ -1239,6 +1284,14 @@ class EconomyStatsState extends ConsumerState<EconomyStatsWidget> {
} }
String firstMainTopic = data.first['main_topic'] ?? ''; String firstMainTopic = data.first['main_topic'] ?? '';
return Container( return Container(
decoration: isDarkTheme
? BoxDecoration(
image: DecorationImage(
image: AssetImage('assets/dark_bg.png'),
fit: BoxFit.cover,
),
)
: null,
height: myheight, height: myheight,
// color: Colors.cyan, // color: Colors.cyan,
child: Padding( child: Padding(
@ -1344,6 +1397,7 @@ class EconomyStatsState extends ConsumerState<EconomyStatsWidget> {
borderColor, borderColor,
mainTopic['color_pattern'], mainTopic['color_pattern'],
mainTopic['main_topic']), mainTopic['main_topic']),
), ),
), ),
], ],
@ -1526,6 +1580,13 @@ class InfoCard extends StatelessWidget {
final encodedTitle = Uri.encodeComponent(title); final encodedTitle = Uri.encodeComponent(title);
final encodedKey = Uri.encodeQueryComponent('home'); final encodedKey = Uri.encodeQueryComponent('home');
return Consumer(
builder: (context, ref, _) {
final themeMode = ref.watch(themeProvider);
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
return GestureDetector( return GestureDetector(
onTap: () { onTap: () {
context.push( context.push(
@ -1540,6 +1601,7 @@ class InfoCard extends StatelessWidget {
// padding: const EdgeInsets.all(10), // padding: const EdgeInsets.all(10),
padding: const EdgeInsets.only(bottom: 0.5, top: 1, left: 10, right: 10), padding: const EdgeInsets.only(bottom: 0.5, top: 1, left: 10, right: 10),
decoration: BoxDecoration( decoration: BoxDecoration(
color: isDarkTheme ? Color(0xFF111111) : null,
border: Border.all(color: bordercolor), border: Border.all(color: bordercolor),
borderRadius: BorderRadius.circular(8), borderRadius: BorderRadius.circular(8),
), ),
@ -1579,7 +1641,7 @@ class InfoCard extends StatelessWidget {
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
), ),
color: Color(0xFF000000), color: isDarkTheme ? Color(0xFFFFFFFF) : Color(0xFF000000),
), ),
), ),
const SizedBox(height: 0.3), const SizedBox(height: 0.3),
@ -1645,5 +1707,9 @@ class InfoCard extends StatelessWidget {
), ),
), ),
); );
}
);
} }
} }

View File

@ -17,6 +17,7 @@ import 'package:flutter_gen/gen_l10n/app_localizations.dart';
import 'package:uae_stat/config/api_config.dart'; import 'package:uae_stat/config/api_config.dart';
import 'package:uae_stat/config/connectivity_provider.dart'; import 'package:uae_stat/config/connectivity_provider.dart';
import 'package:uae_stat/config/my_theme.dart'; import 'package:uae_stat/config/my_theme.dart';
import 'package:uae_stat/config/theme/theme_provider.dart';
import 'package:uae_stat/config/toggle_lang_service.dart'; import 'package:uae_stat/config/toggle_lang_service.dart';
import 'package:uae_stat/domain/use_cases/language.dart'; import 'package:uae_stat/domain/use_cases/language.dart';
import 'package:uae_stat/infrastructure/services/img_asset_paths/icons/misc_icon_asset_path.dart'; import 'package:uae_stat/infrastructure/services/img_asset_paths/icons/misc_icon_asset_path.dart';
@ -534,6 +535,11 @@ class _EditProfileState extends ConsumerState<EditProfile> {
await _fetchUserData(); await _fetchUserData();
}); });
final themeMode = ref.read(themeProvider);
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
return PopScope( return PopScope(
canPop: false, // Allow back navigation only if not login screen canPop: false, // Allow back navigation only if not login screen
onPopInvokedWithResult: (didPop, result) { onPopInvokedWithResult: (didPop, result) {
@ -568,7 +574,9 @@ class _EditProfileState extends ConsumerState<EditProfile> {
], ],
), ),
) )
: SingleChildScrollView( : Container(
color: isDarkTheme ? Color(0xFF111111) : null,
child: SingleChildScrollView(
child: Padding( child: Padding(
padding: const EdgeInsets.only( padding: const EdgeInsets.only(
left: 10.0, right: 10.0, top: 3.0), left: 10.0, right: 10.0, top: 3.0),
@ -1318,6 +1326,9 @@ class _EditProfileState extends ConsumerState<EditProfile> {
), ),
), ),
), ),
)
//bottomNavigationBar: MyBottomNavBar(), //bottomNavigationBar: MyBottomNavBar(),
)); ));
} }

View File

@ -14,6 +14,10 @@ import 'package:shared_preferences/shared_preferences.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart'; import 'package:flutter_gen/gen_l10n/app_localizations.dart';
import 'package:tutorial_coach_mark/tutorial_coach_mark.dart'; import 'package:tutorial_coach_mark/tutorial_coach_mark.dart';
import 'package:uae_stat/config/injector.dart'; import 'package:uae_stat/config/injector.dart';
import 'package:uae_stat/config/theme/app_theme.dart';
import 'package:uae_stat/config/theme/service.dart';
import 'package:uae_stat/config/theme/themeDialog.dart';
import 'package:uae_stat/config/theme/theme_provider.dart';
import 'package:uae_stat/domain/repos/t_auth_repo.dart'; import 'package:uae_stat/domain/repos/t_auth_repo.dart';
import 'package:uae_stat/domain/use_cases/language.dart'; import 'package:uae_stat/domain/use_cases/language.dart';
import 'package:uae_stat/infrastructure/data/p_auth_repo.dart'; import 'package:uae_stat/infrastructure/data/p_auth_repo.dart';
@ -44,6 +48,7 @@ class BaseScaffold extends ConsumerStatefulWidget {
this.appbarColor, this.appbarColor,
this.mytitleColor, this.mytitleColor,
this.bottomColor = null, this.bottomColor = null,
this.backgroundColor,
}); });
final Widget body; final Widget body;
final Widget title; final Widget title;
@ -56,6 +61,7 @@ class BaseScaffold extends ConsumerStatefulWidget {
final List<Widget>? actions; final List<Widget>? actions;
final Color? bottomColor; final Color? bottomColor;
final Color? appbarColor, mytitleColor; final Color? appbarColor, mytitleColor;
final Color? backgroundColor;
@override @override
_BaseScaffoldState createState() => _BaseScaffoldState(); _BaseScaffoldState createState() => _BaseScaffoldState();
@ -830,6 +836,111 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
context.go('/login'); // Redirect to login after logout context.go('/login'); // Redirect to login after logout
} }
// void _showThemeDialog(BuildContext context) async {
// AppTheme? result = await showDialog<AppTheme>(
// context: context,
// builder: (context) => ThemeSelectorDialog(initialTheme: AppTheme.system),
// );
//
// if (result != null) {
// // You can now use `result` to apply the selected theme
// print('Selected theme: $result');
// final prefs = await SharedPreferences.getInstance();
// final userId = prefs.getString('userId') ?? '';
// // Example: save to PocketBase or local preferences
// final themeService = ThemeBaseService();
// await themeService.updateUserTheme(userId, result.name);
// }
// }
// void showThemeDialog(BuildContext context, WidgetRef ref) async {
// final currentTheme = ref.read(themeProvider);
// final current = currentTheme == ThemeMode.light
// ? AppTheme.light
// : currentTheme == ThemeMode.dark
// ? AppTheme.dark
// : AppTheme.system;
//
// final selected = await showDialog<AppTheme>(
// context: context,
// builder: (context) => ThemeSelectorDialog(initialTheme: current),
// );
//
// if (selected != null) {
// ref.read(themeProvider.notifier).updateTheme(selected);
// final themeService = ThemeBaseService();
// await themeService.updateUserTheme(userId, selected.name);
// }
// }
// void showThemeDialog(BuildContext context, WidgetRef ref) async {
// final currentTheme = ref.read(themeProvider);
// final current = currentTheme == ThemeMode.light
// ? AppTheme.light
// : currentTheme == ThemeMode.dark
// ? AppTheme.dark
// : AppTheme.system;
//
// final selected = await showDialog<AppTheme>(
// context: context,
// builder: (context) => ThemeSelectorDialog(initialTheme: current),
// );
//
// if (selected != null) {
// // Update app theme locally
// ref.read(themeProvider.notifier).updateTheme(selected);
//
// // Detect real system brightness if 'system' is selected
// String themeToSend;
// if (selected == AppTheme.system) {
// final brightness = MediaQuery.of(context).platformBrightness;
// themeToSend = brightness == Brightness.dark ? 'dark' : 'light';
// } else {
// themeToSend = selected.name;
// }
//
// // Save to PocketBase
// await ThemeBaseService().updateUserTheme(userId, themeToSend);
// }
// }
void _openThemeDialog(BuildContext context, WidgetRef ref, String userId) async {
final currentThemeMode = ref.read(themeProvider); // ThemeMode
final platformBrightness = MediaQuery.of(context).platformBrightness;
// Convert ThemeMode to AppTheme
AppTheme initialAppTheme;
if (currentThemeMode == ThemeMode.light) {
initialAppTheme = AppTheme.light;
} else if (currentThemeMode == ThemeMode.dark) {
initialAppTheme = AppTheme.dark;
} else {
initialAppTheme = AppTheme.system;
}
final selectedTheme = await showDialog<AppTheme>(
context: context,
builder: (_) => ThemeSelectorDialog(initialTheme: initialAppTheme),
);
if (selectedTheme != null) {
// Update UI immediately
ref.read(themeProvider.notifier).updateTheme(selectedTheme, platformBrightness);
// Send only 'light' or 'dark' to PocketBase
final themeToSend = selectedTheme == AppTheme.system
? (platformBrightness == Brightness.dark ? 'dark' : 'light')
: selectedTheme.name;
await ThemeBaseService().updateUserTheme(userId, themeToSend);
}
}
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
final locale = ref.watch(localeProvider); final locale = ref.watch(localeProvider);
@ -837,6 +948,12 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
String currentRoute = GoRouterState.of(context).matchedLocation; String currentRoute = GoRouterState.of(context).matchedLocation;
double myheight = MediaQuery.of(context).size.height; double myheight = MediaQuery.of(context).size.height;
double mywidth = MediaQuery.of(context).size.width; double mywidth = MediaQuery.of(context).size.width;
final themeMode = ref.read(themeProvider);
final isDarkTheme = themeMode == ThemeMode.dark ||
(themeMode == ThemeMode.system &&
MediaQuery.of(context).platformBrightness == Brightness.dark);
final String currentRoute1 = ModalRoute.of(context)?.settings.name ?? '';
return Scaffold( return Scaffold(
backgroundColor: Colors.white, backgroundColor: Colors.white,
@ -849,7 +966,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
: Alignment.centerLeft, : Alignment.centerLeft,
child: DefaultTextStyle( child: DefaultTextStyle(
style: TextStyle( style: TextStyle(
color: widget.colorChange ? Colors.white : Color(0xFF414042), color: widget.colorChange ? Colors.white : Color(0xFFFFFFFF),
fontSize: 22, fontSize: 22,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
@ -863,6 +980,22 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
scrolledUnderElevation: 0, scrolledUnderElevation: 0,
titleSpacing: 0, titleSpacing: 0,
flexibleSpace: (isDarkTheme && currentRoute == '/myhomepage')
? Container(
decoration: const BoxDecoration(
image: DecorationImage(
image: AssetImage('assets/dark_bg.png'),
fit: BoxFit.cover,
),
),
)
: (isDarkTheme && currentRoute == '/uaenumbers')
? Container(
decoration: const BoxDecoration(
color: Color(0xFF333333),
),
)
: null,
backgroundColor: widget.appbarColor ?? Colors.white, backgroundColor: widget.appbarColor ?? Colors.white,
leadingWidth: widget.showBackButton ? mywidth * 0.18 : null, leadingWidth: widget.showBackButton ? mywidth * 0.18 : null,
bottom: widget.showDivider bottom: widget.showDivider
@ -940,7 +1073,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
padding: EdgeInsets.zero, padding: EdgeInsets.zero,
constraints: BoxConstraints(), constraints: BoxConstraints(),
key: drawerKey, key: drawerKey,
color: widget.colorChange ? Colors.white : Colors.black, color: isDarkTheme ? Colors.white : Colors.black,
icon: const Icon(Icons.menu, size: 30), icon: const Icon(Icons.menu, size: 30),
onPressed: () { onPressed: () {
Scaffold.of(context).openDrawer(); Scaffold.of(context).openDrawer();
@ -954,7 +1087,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
), ),
drawer: Drawer( drawer: Drawer(
backgroundColor: Colors.white, backgroundColor: isDarkTheme ? Color(0xFF111111) : Colors.white,
child: Column(children: [ child: Column(children: [
Expanded( Expanded(
child: ListView( child: ListView(
@ -1034,9 +1167,15 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
if (userId == "guest") ...[ if (userId == "guest") ...[
Text(userName ?? 'Guest User'), Text(userName ?? 'Guest User',
style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
),),
] else ...[ ] else ...[
Text(userName ?? 'Loading...'), Text(userName ?? 'Loading...',
style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
),),
Tooltip( Tooltip(
message: userEmail ?? message: userEmail ??
'Loading...', // Shows full email on hover 'Loading...', // Shows full email on hover
@ -1048,7 +1187,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
child: Text( child: Text(
userEmail ?? 'Loading...', userEmail ?? 'Loading...',
style: TextStyle(fontSize: 12, style: TextStyle(fontSize: 12,
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1071,9 +1210,10 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
if (userId != 'guest') if (userId != 'guest')
ListTile( ListTile(
leading: Icon(Icons.notifications_none), leading: Icon(Icons.notifications_none,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
title: Text(AppLocalizations.of(context)!.notification, title: Text(AppLocalizations.of(context)!.notification,
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1083,7 +1223,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
onTap: () => _navigateTo(context, '/notification'), onTap: () => _navigateTo(context, '/notification'),
), ),
ListTile( ListTile(
leading: Icon(Icons.message_outlined), leading: Icon(Icons.message_outlined,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
// leading: Image.asset( // leading: Image.asset(
// DrawerAssetIconPath.feedback, // DrawerAssetIconPath.feedback,
// color: Colors.black, // color: Colors.black,
@ -1093,6 +1233,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
// title: const Text('Feedback'), // title: const Text('Feedback'),
title: Text(AppLocalizations.of(context)!.feedback_title, title: Text(AppLocalizations.of(context)!.feedback_title,
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1102,7 +1243,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
if (role == 'admin') if (role == 'admin')
ListTile( ListTile(
leading: Icon(Icons.manage_accounts_outlined), leading: Icon(Icons.manage_accounts_outlined,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
// leading: Image.asset( // leading: Image.asset(
// DrawerAssetIconPath.manageUser, // DrawerAssetIconPath.manageUser,
// color: Colors.black, // color: Colors.black,
@ -1113,6 +1254,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
title: Text( title: Text(
AppLocalizations.of(context)!.manage_user, AppLocalizations.of(context)!.manage_user,
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1121,11 +1263,12 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
onTap: () => _navigateTo(context, '/manageuser'), onTap: () => _navigateTo(context, '/manageuser'),
), ),
ListTile( ListTile(
leading: Icon(Icons.bookmarks_outlined), leading: Icon(Icons.bookmarks_outlined,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
// title: const Text('Bookmark'), // title: const Text('Bookmark'),
title: Text( title: Text(
AppLocalizations.of(context)!.bookmark_title, AppLocalizations.of(context)!.bookmark_title,
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1134,7 +1277,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
onTap: () => _navigateTo(context, '/bookmark'), onTap: () => _navigateTo(context, '/bookmark'),
), ),
ListTile( ListTile(
leading: Icon(Icons.menu_book_outlined), leading: Icon(Icons.menu_book_outlined,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
// leading: Image.asset( // leading: Image.asset(
// DrawerAssetIconPath.guide, // DrawerAssetIconPath.guide,
// color: Colors.black, // color: Colors.black,
@ -1144,6 +1287,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
// title: const Text('User Guide'), // title: const Text('User Guide'),
title: Text(AppLocalizations.of(context)!.guide_title, title: Text(AppLocalizations.of(context)!.guide_title,
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1152,9 +1296,10 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
onTap: () => _navigateTo(context, '/user-guide'), onTap: () => _navigateTo(context, '/user-guide'),
), ),
ListTile( ListTile(
leading: Icon(Icons.mail_outlined), leading: Icon(Icons.mail_outlined,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
title: Text(context.translate('Contact Us', 'اتصل بنا'), title: Text(context.translate('Contact Us', 'اتصل بنا'),
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1163,10 +1308,11 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
if (userId != 'guest') if (userId != 'guest')
ListTile( ListTile(
leading: Icon(Icons.logout), leading: Icon(Icons.logout,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
// title: const Text('Logout'), // title: const Text('Logout'),
title: Text(AppLocalizations.of(context)!.logout, title: Text(AppLocalizations.of(context)!.logout,
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1176,10 +1322,11 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
if (userId == 'guest') if (userId == 'guest')
ListTile( ListTile(
leading: Icon(Icons.login), leading: Icon(Icons.login,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
// title: const Text('Login'), // title: const Text('Login'),
title: Text(AppLocalizations.of(context)!.login_title, title: Text(AppLocalizations.of(context)!.login_title,
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1189,10 +1336,11 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
if (userId == 'guest') if (userId == 'guest')
ListTile( ListTile(
leading: Icon(Icons.app_registration), leading: Icon(Icons.app_registration,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
// title: const Text('Register'), // title: const Text('Register'),
title: Text(AppLocalizations.of(context)!.register_title, title: Text(AppLocalizations.of(context)!.register_title,
style: TextStyle( style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate( fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
@ -1200,6 +1348,17 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
onTap: () => context.go('/register'), onTap: () => context.go('/register'),
), ),
ListTile(
leading: Icon(Icons.lightbulb_circle_outlined,color: isDarkTheme ? Color(0xFFFFFFFF) : null),
title: Text(context.translate('Theme','سمة'),
style: TextStyle(
color: isDarkTheme ? Color(0xFFAAAAAA) : null,
fontFamily: context.translate(
'Roboto',
'NotoKufi',
), ),),
onTap: () => _openThemeDialog(context, ref, userId),
),
], ],
), ),
), ),
@ -1211,7 +1370,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
if (snapshot.connectionState == ConnectionState.waiting) { if (snapshot.connectionState == ConnectionState.waiting) {
return Text( return Text(
'Loading version...', 'Loading version...',
style: TextStyle(fontSize: 12, color: Colors.grey,fontFamily: context.translate( style: TextStyle(fontSize: 12, color: isDarkTheme ? Color(0xFFAAAAAA) : Colors.grey,fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),), ),),
@ -1229,7 +1388,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
} else { } else {
return Text( return Text(
'Version ${snapshot.data}', 'Version ${snapshot.data}',
style: TextStyle(fontSize: 12, color: Colors.grey,fontFamily: context.translate( style: TextStyle(fontSize: 12, color: isDarkTheme ? Color(0xFFAAAAAA) : Colors.grey,fontFamily: context.translate(
'Roboto', 'Roboto',
'NotoKufi', 'NotoKufi',
),), ),),
@ -1240,8 +1399,25 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
), ),
])), ])),
bottomNavigationBar: BottomNavigationBar( bottomNavigationBar: Stack(
backgroundColor: Colors.white, children: [
if (isDarkTheme)
Positioned(
bottom: 0,
left: 0,
right: 0,
child: Container(
height: kBottomNavigationBarHeight + 0, // Adjust as needed
decoration: BoxDecoration(
image: DecorationImage(
image: AssetImage('assets/dark_bg.png'), // your dark mode image
fit: BoxFit.cover,
),
),
),
),
BottomNavigationBar(
backgroundColor: isDarkTheme ? Color(0xFF000000) : Colors.white,
currentIndex: _getSelectedIndex(currentRoute), currentIndex: _getSelectedIndex(currentRoute),
onTap: (index) => _onItemTapped(context, index), onTap: (index) => _onItemTapped(context, index),
type: BottomNavigationBarType.fixed, type: BottomNavigationBarType.fixed,
@ -1253,7 +1429,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
child: Image.asset( child: Image.asset(
BottomBarAssetIconPath.home, BottomBarAssetIconPath.home,
color: _getSelectedIndex(currentRoute) == 0 color: _getSelectedIndex(currentRoute) == 0
? Colors.black ? (isDarkTheme ? Color(0xFF24B4FB) : Colors.black)
: Color(0xFF989898), : Color(0xFF989898),
width: 23.98, width: 23.98,
height: 25, height: 25,
@ -1270,7 +1446,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
child: Image.asset( child: Image.asset(
BottomBarAssetIconPath.uaeMap, BottomBarAssetIconPath.uaeMap,
color: _getSelectedIndex(currentRoute) == 1 color: _getSelectedIndex(currentRoute) == 1
? Colors.black ? (isDarkTheme ? Color(0xFF24B4FB) : Colors.black)
: Color(0xFF989898), : Color(0xFF989898),
width: 23.98, width: 23.98,
height: 25, height: 25,
@ -1286,7 +1462,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
child: Image.asset( child: Image.asset(
BottomBarAssetIconPath.ranking, BottomBarAssetIconPath.ranking,
color: _getSelectedIndex(currentRoute) == 2 color: _getSelectedIndex(currentRoute) == 2
? Colors.black ? (isDarkTheme ? Color(0xFF24B4FB) : Colors.black)
: Color(0xFF989898), : Color(0xFF989898),
width: 23.98, width: 23.98,
height: 25, height: 25,
@ -1302,7 +1478,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
child: Image.asset( child: Image.asset(
BottomBarAssetIconPath.globe, BottomBarAssetIconPath.globe,
color: _getSelectedIndex(currentRoute) == 3 color: _getSelectedIndex(currentRoute) == 3
? Colors.black ? (isDarkTheme ? Color(0xFF24B4FB) : Colors.black)
: Color(0xFF989898), : Color(0xFF989898),
width: 23.98, width: 23.98,
height: 25, height: 25,
@ -1313,7 +1489,7 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
], ],
key: bottomNavKey, key: bottomNavKey,
selectedItemColor: Colors.black, selectedItemColor: isDarkTheme ? Color(0xFF24B4FB) : Colors.black,
unselectedItemColor: Colors.grey, unselectedItemColor: Colors.grey,
selectedLabelStyle: TextStyle( selectedLabelStyle: TextStyle(
fontFamily: context.translate( fontFamily: context.translate(
@ -1331,6 +1507,102 @@ class _BaseScaffoldState extends ConsumerState<BaseScaffold> {
), ),
showUnselectedLabels: true, showUnselectedLabels: true,
), ),
],
),
// BottomNavigationBar(
// backgroundColor: isDarkTheme ? Color(0xFF00000080) : Colors.white,
// currentIndex: _getSelectedIndex(currentRoute),
// onTap: (index) => _onItemTapped(context, index),
// type: BottomNavigationBarType.fixed,
// items: [
// BottomNavigationBarItem(
// icon: Padding(
// padding:
// const EdgeInsets.only(bottom: 4), // Adjust this for spacing
// child: Image.asset(
// BottomBarAssetIconPath.home,
// color: _getSelectedIndex(currentRoute) == 0
// ? Colors.black
// : Color(0xFF989898),
// width: 23.98,
// height: 25,
// ),
// ),
// // label: 'Home',
// label: AppLocalizations.of(context)!.nav_home,
// ),
// BottomNavigationBarItem(
// // icon: Icon(Icons.map),
// icon: Padding(
// padding:
// const EdgeInsets.only(bottom: 4), // Adjust this for spacing
// child: Image.asset(
// BottomBarAssetIconPath.uaeMap,
// color: _getSelectedIndex(currentRoute) == 1
// ? Colors.black
// : Color(0xFF989898),
// width: 23.98,
// height: 25,
// ),
// ),
// // label: 'UAE Numbers'
// label: AppLocalizations.of(context)!.nav_uae,
// ),
// BottomNavigationBarItem(
// icon: Padding(
// padding:
// const EdgeInsets.only(bottom: 4), // Adjust this for spacing
// child: Image.asset(
// BottomBarAssetIconPath.ranking,
// color: _getSelectedIndex(currentRoute) == 2
// ? Colors.black
// : Color(0xFF989898),
// width: 23.98,
// height: 25,
// ),
// ),
// // label: 'Competitiveness',
// label: AppLocalizations.of(context)!.nav_competitiveness,
// ),
// BottomNavigationBarItem(
// icon: Padding(
// padding:
// const EdgeInsets.only(bottom: 4), // Adjust this for spacing
// child: Image.asset(
// BottomBarAssetIconPath.globe,
// color: _getSelectedIndex(currentRoute) == 3
// ? Colors.black
// : Color(0xFF989898),
// width: 23.98,
// height: 25,
// ),
// ),
// // label: 'Country Profile',
// label: AppLocalizations.of(context)!.country_profile,
// ),
// ],
// key: bottomNavKey,
// selectedItemColor: Colors.black,
// unselectedItemColor: Colors.grey,
// selectedLabelStyle: TextStyle(
// fontFamily: context.translate(
// 'Roboto',
// 'NotoKufi',
// ),
// fontSize: 10, // Font size for unselected label
// ),
// unselectedLabelStyle: TextStyle(
// fontFamily: context.translate(
// 'Roboto',
// 'NotoKufi',
// ),
// fontSize: 10, // Font size for unselected label
// ),
// showUnselectedLabels: true,
// ),
body: widget.body, body: widget.body,
); );
} }

View File

@ -1,8 +1,8 @@
name: uae_stat name: uae_stat
description: "View statistics about the UAE from the Federal Center for Statistics and Competitiveness." description: "View statistics about the UAE from the Federal Center for Statistics and Competitiveness."
publish_to: "none" publish_to: "none"
#version: 1.0.59+60 #version: 1.0.60+61
version: 1.0.5+6 version: 1.0.6+7
environment: environment:
sdk: ">=3.2.3 <4.0.0" sdk: ">=3.2.3 <4.0.0"
@ -104,6 +104,7 @@ flutter:
generate: true generate: true
uses-material-design: true uses-material-design: true
assets: assets:
- assets/dark_bg.png
- assets/user_guide_videos/ - assets/user_guide_videos/
- assets/logos/ - assets/logos/
- assets/logos/from_alsaray/ - assets/logos/from_alsaray/