Commit 985775c7 authored by Uditha Prabhasha 's avatar Uditha Prabhasha

update parent page bottom nav bar

parent 10e73d8d
...@@ -493,6 +493,12 @@ ...@@ -493,6 +493,12 @@
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.19" "languageVersion": "2.19"
}, },
{
"name": "simple_gesture_detector",
"rootUri": "file:///Users/avishkanew/.pub-cache/hosted/pub.dev/simple_gesture_detector-0.2.1",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{ {
"name": "sky_engine", "name": "sky_engine",
"rootUri": "file:///Users/avishka/Desktop/FLUTTER/flutter/bin/cache/pkg/sky_engine", "rootUri": "file:///Users/avishka/Desktop/FLUTTER/flutter/bin/cache/pkg/sky_engine",
...@@ -547,6 +553,12 @@ ...@@ -547,6 +553,12 @@
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "3.0" "languageVersion": "3.0"
}, },
{
"name": "table_calendar",
"rootUri": "file:///Users/avishkanew/.pub-cache/hosted/pub.dev/table_calendar-3.0.8",
"packageUri": "lib/",
"languageVersion": "2.12"
},
{ {
"name": "term_glyph", "name": "term_glyph",
"rootUri": "file:///Users/avishkanew/.pub-cache/hosted/pub.dev/term_glyph-1.2.1", "rootUri": "file:///Users/avishkanew/.pub-cache/hosted/pub.dev/term_glyph-1.2.1",
...@@ -674,7 +686,7 @@ ...@@ -674,7 +686,7 @@
"languageVersion": "3.0" "languageVersion": "3.0"
} }
], ],
"generated": "2024-03-17T10:38:35.142846Z", "generated": "2024-03-18T12:13:20.503381Z",
"generator": "pub", "generator": "pub",
"generatorVersion": "3.0.1" "generatorVersion": "3.0.1"
} }
...@@ -330,6 +330,10 @@ shared_preferences_windows ...@@ -330,6 +330,10 @@ shared_preferences_windows
2.19 2.19
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.3.2/ file:///Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.3.2/
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.3.2/lib/ file:///Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.3.2/lib/
simple_gesture_detector
2.12
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/simple_gesture_detector-0.2.1/
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/simple_gesture_detector-0.2.1/lib/
source_span source_span
2.14 2.14
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/source_span-1.9.1/ file:///Users/avishkanew/.pub-cache/hosted/pub.dev/source_span-1.9.1/
...@@ -362,6 +366,10 @@ synchronized ...@@ -362,6 +366,10 @@ synchronized
3.0 3.0
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/synchronized-3.1.0+1/ file:///Users/avishkanew/.pub-cache/hosted/pub.dev/synchronized-3.1.0+1/
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/synchronized-3.1.0+1/lib/ file:///Users/avishkanew/.pub-cache/hosted/pub.dev/synchronized-3.1.0+1/lib/
table_calendar
2.12
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/table_calendar-3.0.8/
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/table_calendar-3.0.8/lib/
term_glyph term_glyph
2.12 2.12
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/term_glyph-1.2.1/ file:///Users/avishkanew/.pub-cache/hosted/pub.dev/term_glyph-1.2.1/
......
{"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_ios","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_ios-0.8.9+1/","native_build":true,"dependencies":[]},{"name":"path_provider_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_foundation-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.3.5/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"url_launcher_ios","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_ios-6.2.4/","native_build":true,"dependencies":[]},{"name":"video_player_avfoundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_avfoundation-2.4.11/","native_build":true,"dependencies":[]}],"android":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"flutter_plugin_android_lifecycle","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17/","native_build":true,"dependencies":[]},{"name":"image_picker_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_android-0.8.9+3/","native_build":true,"dependencies":["flutter_plugin_android_lifecycle"]},{"name":"path_provider_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_android-2.2.2/","native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_android-2.2.1/","native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","native_build":true,"dependencies":[]},{"name":"url_launcher_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_android-6.3.0/","native_build":true,"dependencies":[]},{"name":"video_player_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_android-2.4.11/","native_build":true,"dependencies":[]}],"macos":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"file_selector_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_macos-0.9.3+3/","native_build":true,"dependencies":[]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_macos-0.2.1+1/","native_build":false,"dependencies":["file_selector_macos"]},{"name":"path_provider_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_foundation-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.3.5/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"url_launcher_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_macos-3.1.0/","native_build":true,"dependencies":[]}],"linux":[{"name":"file_selector_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_linux-0.9.2+1/","native_build":true,"dependencies":[]},{"name":"image_picker_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_linux-0.2.1+1/","native_build":false,"dependencies":["file_selector_linux"]},{"name":"path_provider_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_linux-2.2.1/","native_build":false,"dependencies":[]},{"name":"shared_preferences_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_linux-2.3.2/","native_build":false,"dependencies":["path_provider_linux"]},{"name":"url_launcher_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_linux-3.1.1/","native_build":true,"dependencies":[]}],"windows":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"file_selector_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_windows-0.9.3+1/","native_build":true,"dependencies":[]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_windows-0.2.1+1/","native_build":false,"dependencies":["file_selector_windows"]},{"name":"path_provider_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_windows-2.2.1/","native_build":false,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.3.2/","native_build":false,"dependencies":["path_provider_windows"]},{"name":"url_launcher_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_windows-3.1.1/","native_build":true,"dependencies":[]}],"web":[{"name":"cloud_firestore_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore_web-3.8.10/","dependencies":["firebase_core_web"]},{"name":"firebase_auth_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth_web-5.8.12/","dependencies":["firebase_core_web"]},{"name":"firebase_core_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core_web-2.10.0/","dependencies":[]},{"name":"firebase_storage_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage_web-3.6.17/","dependencies":["firebase_core_web"]},{"name":"image_picker_for_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_for_web-2.2.0/","dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","dependencies":[]},{"name":"shared_preferences_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_web-2.2.1/","dependencies":[]},{"name":"url_launcher_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_web-2.0.19/","dependencies":[]},{"name":"video_player_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_web-2.0.17/","dependencies":[]}]},"dependencyGraph":[{"name":"cloud_firestore","dependencies":["cloud_firestore_web","firebase_core"]},{"name":"cloud_firestore_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"file_selector_linux","dependencies":[]},{"name":"file_selector_macos","dependencies":[]},{"name":"file_selector_windows","dependencies":[]},{"name":"firebase_auth","dependencies":["firebase_auth_web","firebase_core"]},{"name":"firebase_auth_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"firebase_core","dependencies":["firebase_core_web"]},{"name":"firebase_core_web","dependencies":[]},{"name":"firebase_storage","dependencies":["firebase_core","firebase_storage_web"]},{"name":"firebase_storage_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"flutter_plugin_android_lifecycle","dependencies":[]},{"name":"image_picker","dependencies":["image_picker_android","image_picker_for_web","image_picker_ios","image_picker_linux","image_picker_macos","image_picker_windows"]},{"name":"image_picker_android","dependencies":["flutter_plugin_android_lifecycle"]},{"name":"image_picker_for_web","dependencies":[]},{"name":"image_picker_ios","dependencies":[]},{"name":"image_picker_linux","dependencies":["file_selector_linux"]},{"name":"image_picker_macos","dependencies":["file_selector_macos"]},{"name":"image_picker_windows","dependencies":["file_selector_windows"]},{"name":"path_provider","dependencies":["path_provider_android","path_provider_foundation","path_provider_linux","path_provider_windows"]},{"name":"path_provider_android","dependencies":[]},{"name":"path_provider_foundation","dependencies":[]},{"name":"path_provider_linux","dependencies":[]},{"name":"path_provider_windows","dependencies":[]},{"name":"rive_common","dependencies":[]},{"name":"shared_preferences","dependencies":["shared_preferences_android","shared_preferences_foundation","shared_preferences_linux","shared_preferences_web","shared_preferences_windows"]},{"name":"shared_preferences_android","dependencies":[]},{"name":"shared_preferences_foundation","dependencies":[]},{"name":"shared_preferences_linux","dependencies":["path_provider_linux"]},{"name":"shared_preferences_web","dependencies":[]},{"name":"shared_preferences_windows","dependencies":["path_provider_windows"]},{"name":"sqflite","dependencies":[]},{"name":"url_launcher","dependencies":["url_launcher_android","url_launcher_ios","url_launcher_linux","url_launcher_macos","url_launcher_web","url_launcher_windows"]},{"name":"url_launcher_android","dependencies":[]},{"name":"url_launcher_ios","dependencies":[]},{"name":"url_launcher_linux","dependencies":[]},{"name":"url_launcher_macos","dependencies":[]},{"name":"url_launcher_web","dependencies":[]},{"name":"url_launcher_windows","dependencies":[]},{"name":"video_player","dependencies":["video_player_android","video_player_avfoundation","video_player_web"]},{"name":"video_player_android","dependencies":[]},{"name":"video_player_avfoundation","dependencies":[]},{"name":"video_player_web","dependencies":[]}],"date_created":"2024-03-17 16:08:35.268387","version":"3.10.1"} {"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_ios","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_ios-0.8.9+1/","native_build":true,"dependencies":[]},{"name":"path_provider_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_foundation-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.3.5/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"url_launcher_ios","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_ios-6.2.4/","native_build":true,"dependencies":[]},{"name":"video_player_avfoundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_avfoundation-2.4.11/","native_build":true,"dependencies":[]}],"android":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"flutter_plugin_android_lifecycle","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17/","native_build":true,"dependencies":[]},{"name":"image_picker_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_android-0.8.9+3/","native_build":true,"dependencies":["flutter_plugin_android_lifecycle"]},{"name":"path_provider_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_android-2.2.2/","native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_android-2.2.1/","native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","native_build":true,"dependencies":[]},{"name":"url_launcher_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_android-6.3.0/","native_build":true,"dependencies":[]},{"name":"video_player_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_android-2.4.11/","native_build":true,"dependencies":[]}],"macos":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"file_selector_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_macos-0.9.3+3/","native_build":true,"dependencies":[]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_macos-0.2.1+1/","native_build":false,"dependencies":["file_selector_macos"]},{"name":"path_provider_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_foundation-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.3.5/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"url_launcher_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_macos-3.1.0/","native_build":true,"dependencies":[]}],"linux":[{"name":"file_selector_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_linux-0.9.2+1/","native_build":true,"dependencies":[]},{"name":"image_picker_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_linux-0.2.1+1/","native_build":false,"dependencies":["file_selector_linux"]},{"name":"path_provider_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_linux-2.2.1/","native_build":false,"dependencies":[]},{"name":"shared_preferences_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_linux-2.3.2/","native_build":false,"dependencies":["path_provider_linux"]},{"name":"url_launcher_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_linux-3.1.1/","native_build":true,"dependencies":[]}],"windows":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"file_selector_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_windows-0.9.3+1/","native_build":true,"dependencies":[]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_windows-0.2.1+1/","native_build":false,"dependencies":["file_selector_windows"]},{"name":"path_provider_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_windows-2.2.1/","native_build":false,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.3.2/","native_build":false,"dependencies":["path_provider_windows"]},{"name":"url_launcher_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_windows-3.1.1/","native_build":true,"dependencies":[]}],"web":[{"name":"cloud_firestore_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore_web-3.8.10/","dependencies":["firebase_core_web"]},{"name":"firebase_auth_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth_web-5.8.12/","dependencies":["firebase_core_web"]},{"name":"firebase_core_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core_web-2.10.0/","dependencies":[]},{"name":"firebase_storage_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage_web-3.6.17/","dependencies":["firebase_core_web"]},{"name":"image_picker_for_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_for_web-2.2.0/","dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","dependencies":[]},{"name":"shared_preferences_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_web-2.2.1/","dependencies":[]},{"name":"url_launcher_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_web-2.0.19/","dependencies":[]},{"name":"video_player_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_web-2.0.17/","dependencies":[]}]},"dependencyGraph":[{"name":"cloud_firestore","dependencies":["cloud_firestore_web","firebase_core"]},{"name":"cloud_firestore_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"file_selector_linux","dependencies":[]},{"name":"file_selector_macos","dependencies":[]},{"name":"file_selector_windows","dependencies":[]},{"name":"firebase_auth","dependencies":["firebase_auth_web","firebase_core"]},{"name":"firebase_auth_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"firebase_core","dependencies":["firebase_core_web"]},{"name":"firebase_core_web","dependencies":[]},{"name":"firebase_storage","dependencies":["firebase_core","firebase_storage_web"]},{"name":"firebase_storage_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"flutter_plugin_android_lifecycle","dependencies":[]},{"name":"image_picker","dependencies":["image_picker_android","image_picker_for_web","image_picker_ios","image_picker_linux","image_picker_macos","image_picker_windows"]},{"name":"image_picker_android","dependencies":["flutter_plugin_android_lifecycle"]},{"name":"image_picker_for_web","dependencies":[]},{"name":"image_picker_ios","dependencies":[]},{"name":"image_picker_linux","dependencies":["file_selector_linux"]},{"name":"image_picker_macos","dependencies":["file_selector_macos"]},{"name":"image_picker_windows","dependencies":["file_selector_windows"]},{"name":"path_provider","dependencies":["path_provider_android","path_provider_foundation","path_provider_linux","path_provider_windows"]},{"name":"path_provider_android","dependencies":[]},{"name":"path_provider_foundation","dependencies":[]},{"name":"path_provider_linux","dependencies":[]},{"name":"path_provider_windows","dependencies":[]},{"name":"rive_common","dependencies":[]},{"name":"shared_preferences","dependencies":["shared_preferences_android","shared_preferences_foundation","shared_preferences_linux","shared_preferences_web","shared_preferences_windows"]},{"name":"shared_preferences_android","dependencies":[]},{"name":"shared_preferences_foundation","dependencies":[]},{"name":"shared_preferences_linux","dependencies":["path_provider_linux"]},{"name":"shared_preferences_web","dependencies":[]},{"name":"shared_preferences_windows","dependencies":["path_provider_windows"]},{"name":"sqflite","dependencies":[]},{"name":"url_launcher","dependencies":["url_launcher_android","url_launcher_ios","url_launcher_linux","url_launcher_macos","url_launcher_web","url_launcher_windows"]},{"name":"url_launcher_android","dependencies":[]},{"name":"url_launcher_ios","dependencies":[]},{"name":"url_launcher_linux","dependencies":[]},{"name":"url_launcher_macos","dependencies":[]},{"name":"url_launcher_web","dependencies":[]},{"name":"url_launcher_windows","dependencies":[]},{"name":"video_player","dependencies":["video_player_android","video_player_avfoundation","video_player_web"]},{"name":"video_player_android","dependencies":[]},{"name":"video_player_avfoundation","dependencies":[]},{"name":"video_player_web","dependencies":[]}],"date_created":"2024-03-18 17:43:20.593655","version":"3.10.1"}
\ No newline at end of file \ No newline at end of file
...@@ -77,19 +77,19 @@ class _AttendanceState extends State<Attendance> { ...@@ -77,19 +77,19 @@ class _AttendanceState extends State<Attendance> {
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Text( // Text(
'Bright Sparkle ', // ' ',
style: TextStyle( // style: TextStyle(
color: Color(0xFF11324D), // color: Color(0xFF11324D),
fontSize: 24, // fontSize: 24,
fontFamily: 'Poppins', // fontFamily: 'Poppins',
fontWeight: FontWeight.w500, // fontWeight: FontWeight.w500,
height: 0.04, // height: 0.04,
letterSpacing: -0.96, // letterSpacing: -0.96,
), // ),
), // ),
Padding( Padding(
padding: const EdgeInsets.fromLTRB(5, 40, 5, 5), padding: const EdgeInsets.fromLTRB(5, 20, 5, 5),
child: Container( child: Container(
width: 358, width: 358,
height: 76, height: 76,
...@@ -676,30 +676,32 @@ class _AttendanceState extends State<Attendance> { ...@@ -676,30 +676,32 @@ class _AttendanceState extends State<Attendance> {
label: 'Profile', label: 'Profile',
), ),
], ],
selectedItemColor: Colors.blue, selectedItemColor: Color.fromARGB(255, 103, 103, 103),
onTap: (index) async { onTap: (index) {
final prefs = await SharedPreferences.getInstance();
String rool = prefs.get('rool').toString();
// Handle bottom navigation item tap // Handle bottom navigation item tap
switch (index) {
if (index == 0) { case 0:
// Navigate to Home
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => TeacherHomePage()), MaterialPageRoute(builder: (context) => TeacherHomePage()),
); );
} break;
if (index == 1) { case 1:
// Navigate to Chat
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => ChatScreen()), MaterialPageRoute(builder: (context) => ChatScreen()),
); );
} break;
if (index == 2) { case 2:
// Navigate to Profile
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => TeacherProfilePage(uid: user?.uid)), builder: (context) => TeacherProfilePage(uid: user?.uid)),
); );
break;
} }
}, },
), ),
......
...@@ -5,6 +5,8 @@ import 'package:image_picker/image_picker.dart'; ...@@ -5,6 +5,8 @@ import 'package:image_picker/image_picker.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_storage/firebase_storage.dart'; import 'package:firebase_storage/firebase_storage.dart';
import 'package:mobile_application_kids/TeacherProfile.dart';
import 'package:mobile_application_kids/teacherhome.dart';
class ChatScreen extends StatefulWidget { class ChatScreen extends StatefulWidget {
@override @override
...@@ -93,7 +95,23 @@ class _ChatScreenState extends State<ChatScreen> { ...@@ -93,7 +95,23 @@ class _ChatScreenState extends State<ChatScreen> {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Scaffold( return Scaffold(
appBar: AppBar( appBar: AppBar(
title: Text('Chat '), title: Text(' '),
actions: [
Container(
alignment: Alignment.centerRight,
padding: EdgeInsets.only(right: 16),
child: Text('Chat',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
),
),
),
],
), ),
body: Column( body: Column(
children: <Widget>[ children: <Widget>[
...@@ -170,6 +188,7 @@ class _ChatScreenState extends State<ChatScreen> { ...@@ -170,6 +188,7 @@ class _ChatScreenState extends State<ChatScreen> {
), ),
], ],
), ),
); );
} }
......
...@@ -58,18 +58,19 @@ class CheckKidsPage extends StatelessWidget { ...@@ -58,18 +58,19 @@ class CheckKidsPage extends StatelessWidget {
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Text( // Text(
'Bright Sparkle ', // 'Bright Sparkle ',
style: TextStyle(
color: Color(0xFF11324D), // style: TextStyle(
fontSize: 24, // color: Color(0xFF11324D),
fontFamily: 'Poppins', // fontSize: 24,
fontWeight: FontWeight.w500, // fontFamily: 'Poppins',
height: 0.04, // fontWeight: FontWeight.w500,
letterSpacing: -0.96, // height: 0.04,
), // letterSpacing: -0.96,
), // ),
SizedBox(height: 30), // ),
SizedBox(height: 20), // space between titles at the top of the page
Text( Text(
'Select Kids ', 'Select Kids ',
style: TextStyle( style: TextStyle(
...@@ -234,10 +235,12 @@ class CheckKidsPage extends StatelessWidget { ...@@ -234,10 +235,12 @@ class CheckKidsPage extends StatelessWidget {
label: 'Profile', label: 'Profile',
), ),
], ],
selectedItemColor: Colors.blue, selectedItemColor: Color.fromARGB(255, 103, 103, 103),
onTap: (index) { onTap: (index) {
// Handle bottom navigation item tap
switch (index) { switch (index) {
case 0: case 0:
// Navigate to Home
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => TeacherHomePage()), MaterialPageRoute(builder: (context) => TeacherHomePage()),
...@@ -255,9 +258,7 @@ class CheckKidsPage extends StatelessWidget { ...@@ -255,9 +258,7 @@ class CheckKidsPage extends StatelessWidget {
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => TeacherProfilePage( builder: (context) => TeacherProfilePage(uid: user?.uid)),
uid: user?.uid,
)),
); );
break; break;
} }
......
...@@ -5,8 +5,11 @@ import 'package:firebase_auth/firebase_auth.dart'; ...@@ -5,8 +5,11 @@ import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:image_picker/image_picker.dart'; import 'package:image_picker/image_picker.dart';
import 'package:mobile_application_kids/Attendance.dart'; import 'package:mobile_application_kids/Attendance.dart';
import 'package:mobile_application_kids/ChatScreen.dart';
import 'package:mobile_application_kids/ChildrenVideo.dart'; import 'package:mobile_application_kids/ChildrenVideo.dart';
import 'package:mobile_application_kids/ReportKids.dart'; import 'package:mobile_application_kids/ReportKids.dart';
import 'package:mobile_application_kids/TeacherProfile.dart';
import 'package:mobile_application_kids/teacherhome.dart';
import 'CheckKids.dart'; import 'CheckKids.dart';
import 'ChildrenActiPhone.dart'; import 'ChildrenActiPhone.dart';
import 'ChildrenHomePage.dart'; import 'ChildrenHomePage.dart';
...@@ -214,6 +217,50 @@ class ChildrenActivity extends StatelessWidget { ...@@ -214,6 +217,50 @@ class ChildrenActivity extends StatelessWidget {
), ),
), ),
), ),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Color.fromARGB(255, 103, 103, 103),
onTap: (index) {
// Handle bottom navigation item tap
switch (index) {
case 0:
// Navigate to Home
Navigator.push(
context,
MaterialPageRoute(builder: (context) => TeacherHomePage()),
);
break;
case 1:
// Navigate to Chat
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ChatScreen()),
);
break;
case 2:
// Navigate to Profile
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherProfilePage(uid: user?.uid)),
);
break;
}
},
),
); );
} }
......
...@@ -3,9 +3,12 @@ import 'dart:async'; ...@@ -3,9 +3,12 @@ import 'dart:async';
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/ChatScreen.dart';
import 'package:mobile_application_kids/TeacherProfile.dart';
import 'package:mobile_application_kids/teacherchat.dart'; import 'package:mobile_application_kids/teacherchat.dart';
import 'package:mobile_application_kids/classroomview.dart'; import 'package:mobile_application_kids/classroomview.dart';
import 'package:mobile_application_kids/addclassroom.dart'; import 'package:mobile_application_kids/addclassroom.dart';
import 'package:mobile_application_kids/teacherhome.dart';
import 'childrenProfile.dart'; import 'childrenProfile.dart';
...@@ -86,7 +89,7 @@ class ChildrenHomePage extends StatelessWidget { ...@@ -86,7 +89,7 @@ class ChildrenHomePage extends StatelessWidget {
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Text( Text(
'Bright Sparkle ', '$classroom',
style: TextStyle( style: TextStyle(
color: Color(0xFF11324D), color: Color(0xFF11324D),
fontSize: 24, fontSize: 24,
...@@ -185,31 +188,28 @@ class ChildrenHomePage extends StatelessWidget { ...@@ -185,31 +188,28 @@ class ChildrenHomePage extends StatelessWidget {
], ],
), ),
trailing: Container( trailing: Container(
height: 35.0, height: 40.0,
width: 80.0, width: 100.0,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Color.fromARGB(203, 164, 88, 177), color: Colors.blueAccent,
borderRadius: BorderRadius.circular(4.0), borderRadius: BorderRadius.circular(8.0),
), ),
child: TextButton( child: TextButton(
onPressed: () { onPressed: () {
print(document); print(document);
// Handle view class button press // Handle view class button press
Navigator.of(context).push( Navigator.push(
context,
MaterialPageRoute( MaterialPageRoute(
builder: (_) => builder: (context) =>
ChildrenProfilePage(document, 'C'), ChildrenProfilePage(document, "C"),
), ),
); );
}, },
child: Text( child: Text(
'View', 'View',
style: TextStyle( style: poppinsTextStyle.copyWith(
color: Colors.white, color: Colors.white,
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
height: 1,
), ),
), ),
), ),
...@@ -224,6 +224,50 @@ class ChildrenHomePage extends StatelessWidget { ...@@ -224,6 +224,50 @@ class ChildrenHomePage extends StatelessWidget {
], ],
), ),
), ),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Color.fromARGB(255, 103, 103, 103),
onTap: (index) {
// Handle bottom navigation item tap
switch (index) {
case 0:
// Navigate to Home
Navigator.push(
context,
MaterialPageRoute(builder: (context) => TeacherHomePage()),
);
break;
case 1:
// Navigate to Chat
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ChatScreen()),
);
break;
case 2:
// Navigate to Profile
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherProfilePage(uid: user?.uid)),
);
break;
}
},
),
), ),
); );
} }
......
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
import 'package:mobile_application_kids/progressReport.dart';
import 'package:mobile_application_kids/teacherchat.dart';
import 'package:mobile_application_kids/classroomview.dart';
import 'package:mobile_application_kids/addclassroom.dart';
import 'package:mobile_application_kids/teacherhome.dart';
import 'package:url_launcher/url_launcher.dart';
import 'ActivitiesView.dart';
import 'ChatScreen.dart';
import 'TeacherProfile.dart';
import 'kidsReportView.dart';
class pChildrenProfilePage extends StatelessWidget {
late User? user;
late final Stream<QuerySnapshot> _usersStream, _usersStream2;
int _age = 10;
String role = '';
late final userDetails;
pChildrenProfilePage(document, role) {
print(role);
this.role = role;
this.userDetails = document;
user = FirebaseAuth.instance.currentUser;
initializeStreams();
calculateAge(userDetails['Birthday']);
}
void initializeStreams() {
_usersStream = FirebaseFirestore.instance
.collection('classroom')
.where('userId', isEqualTo: user?.uid)
.snapshots();
_usersStream2 = FirebaseFirestore.instance
.collection('students')
.where('user', isEqualTo: user?.uid)
.snapshots();
}
@override
Widget build(BuildContext context) {
return WillPopScope(
onWillPop: () async {
// Disable the back button press
return false;
},
child: Scaffold(
appBar: AppBar(
leading: IconButton(
icon: Icon(Icons.arrow_back),
onPressed: () {
Navigator.of(context).pop();
},
),
actions: [
Text(
'Children ',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
),
)
],
),
body: SingleChildScrollView(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
userDetails['className'],
// 'Bright Sparkle ',
style: TextStyle(
color: Color(0xFF11324D),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.04,
letterSpacing: -0.96,
),
),
Padding(
padding: const EdgeInsets.fromLTRB(5, 40, 5, 5),
child: Container(
width: 358,
height: 255,
decoration: ShapeDecoration(
color: Colors.white,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(13.64),
),
shadows: [
BoxShadow(
color: Color(0x0C000000),
blurRadius: 181.84,
offset: Offset(0, 4.55),
spreadRadius: 0,
)
],
),
child: SingleChildScrollView(
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
SingleChildScrollView(
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Padding(
padding:
const EdgeInsets.fromLTRB(0, 10, 0, 0),
child: Container(
width: 84,
height: 84,
decoration: ShapeDecoration(
image: DecorationImage(
image: AssetImage(
"lib/assets/Ellipse 8.png"),
fit: BoxFit.fill,
),
shape: OvalBorder(),
),
),
),
const SizedBox(height: 11),
Container(
width: double.infinity,
height: 20,
padding: const EdgeInsets.only(
left: 45, right: 43),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.center,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Container(
width: 124,
height: double.infinity,
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.center,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Text(
userDetails['Firstname'],
style: TextStyle(
color: Color(0xFF11324D),
fontSize: 20,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.06,
letterSpacing: -0.80,
),
),
const SizedBox(width: 3),
Container(
width: 7,
height: 7,
decoration: ShapeDecoration(
color: Color(0xFF00E332),
shape: OvalBorder(),
),
),
],
),
),
],
),
),
const SizedBox(height: 11),
Text(
userDetails['role'],
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.07,
),
),
const SizedBox(height: 11),
Padding(
padding: const EdgeInsets.all(8.0),
child: Container(
width: double.infinity,
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Text.rich(
TextSpan(
children: [
TextSpan(
text: 'Age',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
),
),
TextSpan(
text: ' : ',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
),
),
TextSpan(
text: _age.toString(),
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
),
),
],
),
),
const SizedBox(width: 17),
Text.rich(
TextSpan(
children: [
TextSpan(
text: 'Birthday',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
),
),
TextSpan(
text: ' : ',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
),
),
TextSpan(
text: userDetails['Birthday'],
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
),
),
],
),
),
const SizedBox(width: 17),
Text.rich(
TextSpan(
children: [
TextSpan(
text: 'Sex',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
),
),
TextSpan(
text: ' : ',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
),
),
TextSpan(
text: userDetails['Sex'],
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
),
),
],
),
),
],
),
),
),
Padding(
padding: const EdgeInsets.fromLTRB(
50, 20, 40, 0),
child: Container(
width: 302,
height: 37,
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Container(
padding: const EdgeInsets.only(
top: 12,
left: 10,
bottom: 11.63,
),
decoration: ShapeDecoration(
color: Colors.white,
shape: RoundedRectangleBorder(
borderRadius:
BorderRadius.circular(6)),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 4,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Center(
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.center,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
GestureDetector(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) =>
ChatScreen()),
);
},
child: Container(
height: double.infinity,
child: Row(
mainAxisSize:
MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment
.start,
crossAxisAlignment:
CrossAxisAlignment
.center,
children: [
Icon(
Icons.chat,
color:
Colors.black26,
),
Text(
'Chat',
style: TextStyle(
color:
Colors.black,
fontSize: 12,
fontFamily:
'Poppins',
fontWeight:
FontWeight
.w400,
height: 0.08,
),
),
const SizedBox(
width: 10),
],
),
),
),
],
),
),
),
const SizedBox(width: 16),
Container(
padding: const EdgeInsets.only(
top: 12,
left: 10,
bottom: 11.63,
),
decoration: ShapeDecoration(
color: Colors.white,
shape: RoundedRectangleBorder(
borderRadius:
BorderRadius.circular(6)),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 4,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.center,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
GestureDetector(
onTap: () {
_getPhoneNumber(user?.uid);
},
child: Container(
height: double.infinity,
child: Row(
mainAxisSize:
MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment
.start,
crossAxisAlignment:
CrossAxisAlignment
.center,
children: [
Icon(
Icons.call,
color: Colors.black26,
),
Text(
'Call',
style: TextStyle(
color: Colors.black,
fontSize: 12,
fontFamily:
'Poppins',
fontWeight:
FontWeight.w400,
height: 0.08,
),
),
const SizedBox(
width: 10),
],
),
),
),
],
),
),
const SizedBox(width: 16),
GestureDetector(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) =>
UserActivitiesScreen(
userId: user!.uid)),
);
},
child: Container(
padding: const EdgeInsets.only(
top: 11,
bottom: 12,
),
decoration: ShapeDecoration(
color: Colors.white,
shape: RoundedRectangleBorder(
borderRadius:
BorderRadius.circular(
6)),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 4,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.center,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Container(
height: double.infinity,
child: Row(
mainAxisSize:
MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment
.center,
crossAxisAlignment:
CrossAxisAlignment
.center,
children: [
Icon(
Icons.book,
color: Colors.black26,
),
Text(
'Activites',
style: TextStyle(
color: Colors.black,
fontSize: 12,
fontFamily:
'Poppins',
fontWeight:
FontWeight.w400,
),
),
const SizedBox(
width: 10),
],
),
),
],
),
),
),
],
),
),
)
],
),
),
],
),
))),
Padding(
padding: const EdgeInsets.fromLTRB(8, 30, 0, 0),
child: SingleChildScrollView(
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
role == "P"
? Container(
width: 359,
height: 178,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Container(
width: 359,
height: 128,
clipBehavior: Clip.antiAlias,
decoration: ShapeDecoration(
image: DecorationImage(
image:
AssetImage("lib/assets/banner.png"),
fit: BoxFit.cover,
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10),
),
shadows: [
BoxShadow(
color: Color(0x19000000),
blurRadius: 20,
offset: Offset(0, 2),
spreadRadius: 0,
)
],
),
),
const SizedBox(height: 8),
Container(
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Container(
padding: const EdgeInsets.symmetric(
horizontal: 40, vertical: 18), //play game button
decoration: ShapeDecoration(
color: Color(0xFF48B62C),
shape: RoundedRectangleBorder(
borderRadius:
BorderRadius.circular(4)),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 4,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.center,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Text(
'Play Here ',
style: TextStyle(
color: Colors.white,
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
height: 0.06,
),
),
],
),
),
],
),
),
],
),
)
: Container(),
SizedBox(
height: 10,
),
Text(
'Report',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.06,
),
),
const SizedBox(height: 20),
Padding(
padding: EdgeInsets.only(
left: MediaQuery.of(context).size.width * 0.04),
child: SingleChildScrollView(
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
GestureDetector(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) =>
ReportKidsViewPage(
sid: userDetails.id)),
);
},
child: Container(
width:
MediaQuery.of(context).size.width * 0.4,
height: 135,
child: Stack(
children: [
Positioned(
left: 0,
top: 0,
child: Container(
width:
MediaQuery.of(context).size.width,
height: 135,
decoration: ShapeDecoration(
color: Color(0xFFF1EFFF),
shape: RoundedRectangleBorder(
borderRadius:
BorderRadius.circular(8.44),
),
),
),
),
Positioned(
left: 16,
top: 17,
child: Container(
width: 119.18,
height: 100.88,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Padding(
padding:
const EdgeInsets.fromLTRB(0, 0, 0, 5),
child: Container(
width: 16.88,
height: 16.88,
clipBehavior: Clip.antiAlias,
decoration: BoxDecoration(),
child: Stack(children: [
Icon(
Icons.person_3,
color: Colors.black26,
),
]),
),
),
const SizedBox(height: 0),
SizedBox(
width: 119.18,
child: Text.rich(
TextSpan(
children: [
TextSpan(
text: 'Monthly \npsycholo. report \n ',
style: TextStyle(
color:
Color(0xFF403572),
fontSize: 14,
fontFamily: 'poppins',
fontWeight:
FontWeight.w500,
// letterSpacing: 0.08,
height: 0.9,
),
),
],
),
),
),
const SizedBox(height: 1),
SizedBox(
width: 119.18,
child: Opacity(
opacity: 0.70,
child: Text(
'Some short description of this type of report.',
style: TextStyle(
color: Color(0xFF8DAEAE),
fontSize: 9.55,
fontFamily: 'poppins',
fontWeight:
FontWeight.w400,
height: 0,
),
),
),
),
],
),
),
),
],
),
),
),
SizedBox(
width: 10,
),
GestureDetector(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) =>
progressReport()));
},
child: Container(
width: 150,
height: 135,
child: Stack(
children: [
Positioned(
left: 0,
top: 0,
child: Container(
width: 170,
height: 135,
decoration: ShapeDecoration(
color: Color(0xFFC4F3F3),
shape: RoundedRectangleBorder(
borderRadius:
BorderRadius.circular(8.44),
),
),
),
),
Positioned(
left: 16,
top: 17,
child: Container(
width: 119.18,
height: 100.88,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Padding(
padding:
const EdgeInsets.fromLTRB(0, 0, 0, 5),
child: Container(
width: 16.88,
height: 16.88,
clipBehavior: Clip.antiAlias,
decoration: BoxDecoration(),
child: Stack(children: [
Icon(
Icons.calendar_month,
color: Colors.black26,
),
]),
),
),
const SizedBox(height: 1),
SizedBox(
width: 119.18,
child: Text.rich(
TextSpan(
children: [
TextSpan(
text: 'Monthly prediction report \n',
style: TextStyle(
color:
Color(0xFF479696),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight:
FontWeight.w500,
height: 0.9,
),
),
],
),
),
),
const SizedBox(height: 1),
SizedBox(
width: 119.18,
child: Opacity(
opacity: 0.70,
child: Text(
'Some short description of this type of report.',
style: TextStyle(
color: Color(0xFF8DAEAE),
fontSize: 9.55,
fontFamily: 'poppins',
fontWeight:
FontWeight.w400,
height: 0,
),
),
),
),
],
),
),
),
],
),
),
),
],
),
),
),
],
),
),
)
],
),
),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Colors.blue,
onTap: (index) {
// Handle bottom navigation item tap
if (index == 0) {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => TeacherHomePage()),
);
}
if (index == 1) {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ChatScreen()),
);
}
if (index == 2) {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherProfilePage(uid: user?.uid)),
);
}
},
),
),
);
}
_launchPhone(url) async {
if (await canLaunch(url)) {
await launch(url);
} else {
throw 'Could not launch $url';
}
}
Future<String?> _getPhoneNumber(userUID) async {
try {
var snapshot = await FirebaseFirestore.instance
.collection('students')
.where('user', isEqualTo: userUID)
.get();
if (snapshot.docs.isNotEmpty) {
// Assuming 'phone' is the field containing the phone number
String mobile = snapshot.docs.first['Parentphone'];
final url = 'tel:$mobile';
_launchPhone(url);
} else {
return null; // Document not found
}
} catch (e) {
print("Error getting phone number: $e");
return null;
}
}
void calculateAge(birthday) {
String birthdayText = birthday.trim();
if (birthdayText.isNotEmpty) {
try {
DateTime birthday = DateTime.parse(birthdayText);
DateTime now = DateTime.now();
Duration difference = now.difference(birthday);
_age = (difference.inDays / 365).floor();
} catch (e) {
print('Invalid date format: $e');
// Handle invalid date format
}
} else {
// Handle empty input
}
}
}
...@@ -61,18 +61,18 @@ class ReportKidsPage extends StatelessWidget { ...@@ -61,18 +61,18 @@ class ReportKidsPage extends StatelessWidget {
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Text( // Text(
'Bright Sparkle ', // 'Bright Sparkle ',
style: TextStyle( // style: TextStyle(
color: Color(0xFF11324D), // color: Color(0xFF11324D),
fontSize: 24, // fontSize: 24,
fontFamily: 'Poppins', // fontFamily: 'Poppins',
fontWeight: FontWeight.w500, // fontWeight: FontWeight.w500,
height: 0.04, // height: 0.04,
letterSpacing: -0.96, // letterSpacing: -0.96,
), // ),
), // ),
SizedBox(height: 30), SizedBox(height: 20), // sspace here between texts
Text( Text(
'Select Kids ', 'Select Kids ',
style: TextStyle( style: TextStyle(
...@@ -89,7 +89,7 @@ class ReportKidsPage extends StatelessWidget { ...@@ -89,7 +89,7 @@ class ReportKidsPage extends StatelessWidget {
stream: _usersStream, stream: _usersStream,
builder: (context, snapshot) { builder: (context, snapshot) {
print("--------------------------------------"); print("--------------------------------------");
print(snapshot.data!.docs.length); // print(snapshot.data!.docs.length);
if (snapshot.connectionState == ConnectionState.waiting) { if (snapshot.connectionState == ConnectionState.waiting) {
return CircularProgressIndicator(); return CircularProgressIndicator();
} }
...@@ -229,10 +229,12 @@ class ReportKidsPage extends StatelessWidget { ...@@ -229,10 +229,12 @@ class ReportKidsPage extends StatelessWidget {
label: 'Profile', label: 'Profile',
), ),
], ],
selectedItemColor: Colors.blue, selectedItemColor: Color.fromARGB(255, 103, 103, 103),
onTap: (index) { onTap: (index) {
// Handle bottom navigation item tap
switch (index) { switch (index) {
case 0: case 0:
// Navigate to Home
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => TeacherHomePage()), MaterialPageRoute(builder: (context) => TeacherHomePage()),
...@@ -250,9 +252,7 @@ class ReportKidsPage extends StatelessWidget { ...@@ -250,9 +252,7 @@ class ReportKidsPage extends StatelessWidget {
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => TeacherProfilePage( builder: (context) => TeacherProfilePage(uid: user?.uid)),
uid: user?.uid,
)),
); );
break; break;
} }
......
...@@ -2,13 +2,14 @@ import 'package:cloud_firestore/cloud_firestore.dart'; ...@@ -2,13 +2,14 @@ import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/login.dart'; import 'package:mobile_application_kids/login.dart';
import 'package:mobile_application_kids/p_or_t.dart';
import 'package:mobile_application_kids/teacherchat.dart'; import 'package:mobile_application_kids/teacherchat.dart';
import 'package:mobile_application_kids/teacherhome.dart'; import 'package:mobile_application_kids/teacherhome.dart';
import 'ChatScreen.dart'; import 'ChatScreen.dart';
class TeacherProfilePage extends StatefulWidget { class TeacherProfilePage extends StatefulWidget {
final String? uid; // Make uid nullable final String? uid;
TeacherProfilePage({required this.uid, Key? key}); TeacherProfilePage({required this.uid, Key? key});
...@@ -18,7 +19,6 @@ class TeacherProfilePage extends StatefulWidget { ...@@ -18,7 +19,6 @@ class TeacherProfilePage extends StatefulWidget {
class _TeacherProfilePageState extends State<TeacherProfilePage> { class _TeacherProfilePageState extends State<TeacherProfilePage> {
late User? user; late User? user;
late final Stream<QuerySnapshot> _usersStream;
late String fullName = ""; late String fullName = "";
late String email = ""; late String email = "";
late String state = ""; late String state = "";
...@@ -36,34 +36,24 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -36,34 +36,24 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
void initState() { void initState() {
super.initState(); super.initState();
user = FirebaseAuth.instance.currentUser; user = FirebaseAuth.instance.currentUser;
initializeStreams();
getUserData(); getUserData();
} }
void initializeStreams() { Future<void> getUserData() async {
print("Document does not exist " + uid);
FirebaseFirestore.instance FirebaseFirestore.instance
.collection('users') .collection('users')
.doc( .doc(user?.uid)
uid) // Assuming you want to get a specific document based on the user's UID
.get() .get()
.then((DocumentSnapshot documentSnapshot) { .then((DocumentSnapshot documentSnapshot) {
if (documentSnapshot.exists) { if (documentSnapshot.exists) {
// Access the data of the document
targetDoc = documentSnapshot.data() as Map<String, dynamic>? ?? {}; targetDoc = documentSnapshot.data() as Map<String, dynamic>? ?? {};
print("doc" + targetDoc.toString());
// Check if the document ID matches a specific value
setState(() { setState(() {
// Process the document data
fullName = targetDoc['fullName']; fullName = targetDoc['fullName'];
email = targetDoc['email']; email = targetDoc['email'];
state = targetDoc['state']; state = targetDoc['state'];
capacity = targetDoc['enrolmentCapacity']; capacity = targetDoc['enrolmentCapacity'];
school = targetDoc['school']; school = targetDoc['school'];
}); });
print(
"Full Name: $fullName, Email: $email, State: $state, Capacity: $capacity, School: $school");
} else { } else {
print("Document does not exist"); print("Document does not exist");
} }
...@@ -76,7 +66,6 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -76,7 +66,6 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return WillPopScope( return WillPopScope(
onWillPop: () async { onWillPop: () async {
// Disable the back button press
return false; return false;
}, },
child: Scaffold( child: Scaffold(
...@@ -88,395 +77,81 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -88,395 +77,81 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
}, },
), ),
actions: [ actions: [
Text( Padding(
'Profile ', padding: const EdgeInsets.only(right: 16.0),
child: Text(
'Teacher Profile',
style: TextStyle( style: TextStyle(
color: Color(0xFF554994), color: Color(0xFF554994),
fontSize: 24, fontSize: 24,
fontFamily: 'Poppins', fontFamily: 'Poppins',
fontWeight: FontWeight.w700, fontWeight: FontWeight.w700,
height: 0.04, ),
letterSpacing: -0.96,
), ),
) )
], ],
), ),
body: Padding( body: Center(
padding: const EdgeInsets.all(16.0), child: Padding(
padding: const EdgeInsets.all(30.0),
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Text( Center(
'Bright Sparkle', child: Image.asset(
style: TextStyle( "lib/assets/teacherprof.png",
color: Color(0xFF11324D), fit: BoxFit.fitHeight,
fontSize: 24, height: 300,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.04,
letterSpacing: -0.96,
),
),
Padding(
padding: const EdgeInsets.fromLTRB(8, 30, 0, 0),
child: SingleChildScrollView(
child: Column(
children: [
Container(
width: 363,
height: 77,
padding: const EdgeInsets.symmetric(horizontal: 2),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Container(
width: 77,
height: 77,
decoration: ShapeDecoration(
image: DecorationImage(
image: AssetImage("lib/assets/Ellipse 8.png"),
fit: BoxFit.cover,
),
shape: OvalBorder(),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 12.32,
offset: Offset(0, 3.08),
spreadRadius: 0,
)
],
),
),
const SizedBox(width: 120),
SizedBox(
width: 148,
child: Text(
' ',
style: TextStyle(
color: Color(0xFF473D7F),
fontSize: 23,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
height: 0,
),
),
),
],
),
),
SizedBox(
height: 40,
),
Align(
alignment: Alignment.centerLeft,
child: Container(
width: 139,
height: 42,
child: Stack(
children: [
Positioned(
left: 0,
top: 0,
child: Text(
'Full Name',
style: TextStyle(
color: Color(0xFF797C7B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.07,
),
),
),
Positioned(
left: 4,
top: 24,
child: Text(
fullName,
style: TextStyle(
color: Color(0xFF000D07),
fontSize: 18,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.06,
),
),
),
],
),
),
),
SizedBox(height: 10),
Align(
alignment: Alignment.centerLeft,
child: Container(
width: 265,
height: 42,
child: Stack(
children: [
Positioned(
left: 0,
top: 0,
child: Text(
'Email Address',
style: TextStyle(
color: Color(0xFF797C7B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.07,
),
),
),
Positioned(
left: 4,
top: 24,
child: Text(
email,
style: TextStyle(
color: Color(0xFF000D07),
fontSize: 18,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.06,
),
), ),
), ),
], SizedBox(height: 30),
Text(
'Name: $fullName',
style: TextStyle(fontSize: 18, fontWeight: FontWeight.w400),
), ),
)),
SizedBox(height: 10), SizedBox(height: 10),
Align( Text(
alignment: Alignment.centerLeft, 'Email: $email',
child: Container( style: TextStyle(fontSize: 18, fontWeight: FontWeight.w400),
width: 291,
height: 42,
child: Stack(
children: [
Positioned(
left: 0,
top: 0,
child: Text(
'Address',
style: TextStyle(
color: Color(0xFF797C7B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.07,
),
),
),
Positioned(
left: 4,
top: 24,
child: Text(
state,
style: TextStyle(
color: Color(0xFF000D07),
fontSize: 18,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.06,
),
),
),
],
), ),
)),
SizedBox(height: 10), SizedBox(height: 10),
Align( Text(
alignment: Alignment.centerLeft, 'Address: $state',
child: Container( style: TextStyle(fontSize: 18, fontWeight: FontWeight.w400),
width: 291,
height: 42,
child: Stack(
children: [
Positioned(
left: 0,
top: 0,
child: Text(
'Capacity',
style: TextStyle(
color: Color(0xFF797C7B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.07,
),
),
),
Positioned(
left: 4,
top: 24,
child: Text(
capacity,
style: TextStyle(
color: Color(0xFF000D07),
fontSize: 18,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.06,
),
),
),
],
), ),
)),
SizedBox(height: 10), SizedBox(height: 10),
Align(
alignment: Alignment.centerLeft,
child: Container(
width: 291,
height: 42,
child: Stack(
children: [
Positioned(
left: 0,
top: 0,
child: Text(
'School',
style: TextStyle(
color: Color(0xFF797C7B),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.07,
),
),
),
Positioned(
left: 4,
top: 24,
child: Text(
school,
style: TextStyle(
color: Color(0xFF000D07),
fontSize: 18,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0.06,
),
),
),
],
),
)),
SizedBox(
height: 20,
),
Align(
alignment: Alignment.centerLeft,
child: Container(
width: 80,
height: 24,
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Icon(
Icons.help,
color: const Color.fromARGB(255, 185, 184, 179),
size: 30.0,
),
const SizedBox(width: 10),
Text( Text(
'Help', 'Capacity: $capacity',
style: TextStyle( style: TextStyle(fontSize: 18, fontWeight: FontWeight.w400),
color: Colors.black,
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0,
),
),
],
), ),
)), SizedBox(height: 10),
SizedBox(
height: 20,
),
Align(
alignment: Alignment.centerLeft,
child: GestureDetector(
onTap: () => {},
child: Container(
width: 92,
height: 24,
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Icon(
Icons.info,
color:
const Color.fromARGB(255, 166, 165, 160),
size: 30.0,
),
const SizedBox(width: 10),
Text( Text(
'About', 'School: $school',
style: TextStyle( style: TextStyle(fontSize: 18, fontWeight: FontWeight.w400),
color: Colors.black,
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0,
),
),
],
),
), ),
)), SizedBox(height: 20),
SizedBox( Center(
height: 20, child: ElevatedButton(
onPressed: _signOut,
style: ElevatedButton.styleFrom(
primary: Colors.blueAccent,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10.0),
), ),
Align(
alignment: Alignment.centerLeft,
child: GestureDetector(
onTap: () {
_signOut(context);
},
child: Container(
width: 110,
height: 24,
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Icon(
Icons.home,
color:
const Color.fromARGB(255, 212, 212, 207),
size: 30.0,
), ),
const SizedBox(width: 10), child: Padding(
Text( padding: const EdgeInsets.all(10.0),
child: Text(
'Sign Out', 'Sign Out',
style: TextStyle( style: TextStyle(color: const Color.fromARGB(255, 255, 255, 255)),
color: Colors.black,
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
height: 0,
), ),
), ),
],
), ),
), ),
)),
],
)),
)
], ],
), ),
), ),
),
bottomNavigationBar: BottomNavigationBar( bottomNavigationBar: BottomNavigationBar(
items: const [ items: const [
BottomNavigationBarItem( BottomNavigationBarItem(
...@@ -495,24 +170,22 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -495,24 +170,22 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
selectedItemColor: Colors.blue, selectedItemColor: Colors.blue,
currentIndex: 2, currentIndex: 2,
onTap: (index) { onTap: (index) {
// Handle bottom navigation item tap
if (index == 0) { if (index == 0) {
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => TeacherHomePage()), MaterialPageRoute(builder: (context) => TeacherHomePage()),
); );
} } else if (index == 1) {
if (index == 1) {
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => ChatScreen()), MaterialPageRoute(builder: (context) => ChatScreen()),
); );
} } else if (index == 2) {
if (index == 2) {
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => TeacherProfilePage(uid: user?.uid)), builder: (context) => TeacherProfilePage(uid: user?.uid),
),
); );
} }
}, },
...@@ -521,48 +194,19 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -521,48 +194,19 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
); );
} }
Future<void> _signOut(context) async { Future<void> _signOut() async {
try { try {
await _auth.signOut(); await _auth.signOut();
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => builder: (context) => ParentTeacherPage(
LoginPage(backgroundColor: Color.fromARGB(255, 255, 255, 255))), backgroundColor: Color.fromARGB(255, 255, 255, 255),
),
),
); );
} catch (e) { } catch (e) {
print('Error signing out: $e'); print('Error signing out: $e');
} }
} }
// Define a function to fetch user data from Firestore
Future<void> getUserData() async {
FirebaseFirestore.instance
.collection('users')
.doc(user
?.uid) // Assuming you want to get a specific document based on the user's UID
.get()
.then((DocumentSnapshot documentSnapshot) {
if (documentSnapshot.exists) {
// Access the data of the document
targetDoc = documentSnapshot.data() as Map<String, dynamic>? ?? {};
// Check if the document ID matches a specific value
setState(() {
// Process the document data
fullName = targetDoc['fullName'];
String email = targetDoc['email'];
String state = targetDoc['state'];
String capacity = targetDoc['enrolmentCapacity'];
String school = targetDoc['school'];
});
print(
"Full Name: $fullName, Email: $email, State: $state, Capacity: $capacity, School: $school");
} else {
print("Document does not exist");
}
}).catchError((error) {
print("Error getting document: $error");
});
}
} }
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/ChatScreen.dart';
import 'package:mobile_application_kids/TeacherProfile.dart';
import 'package:mobile_application_kids/teacherhome.dart';
class ActivitiesPage extends StatelessWidget { class ActivitiesPage extends StatelessWidget {
@override @override
...@@ -168,6 +171,51 @@ class CameraScreen extends StatelessWidget { ...@@ -168,6 +171,51 @@ class CameraScreen extends StatelessWidget {
body: Center( body: Center(
child: Text('Camera Screen Placeholder'), child: Text('Camera Screen Placeholder'),
), ),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Color.fromARGB(255, 103, 103, 103),
onTap: (index) {
// Handle bottom navigation item tap
switch (index) {
case 0:
// Navigate to Home
Navigator.push(
context,
MaterialPageRoute(builder: (context) => TeacherHomePage()),
);
break;
case 1:
// Navigate to Chat
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ChatScreen()),
);
break;
case 2:
// Navigate to Profile
var user;
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherProfilePage(uid: user?.uid)),
);
break;
}
},
),
); );
} }
} }
\ No newline at end of file
import 'package:flutter/material.dart';
import 'package:intl/intl.dart';
import 'package:table_calendar/table_calendar.dart';
class CalendarScreen extends StatefulWidget {
@override
_CalendarScreenState createState() => _CalendarScreenState();
}
class _CalendarScreenState extends State<CalendarScreen> {
late CalendarFormat _calendarFormat;
late DateTime _focusedDay;
late DateTime _selectedDay;
@override
void initState() {
super.initState();
_calendarFormat = CalendarFormat.month;
_focusedDay = DateTime.now();
_selectedDay = DateTime.now();
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text(' '),
actions: [
Container(
alignment: Alignment.centerRight,
padding: EdgeInsets.only(right: 16),
child: Text('Calendar',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
),
),
),
],
),
body: SingleChildScrollView(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: const EdgeInsets.symmetric(horizontal: 16.0),
child: Text(
DateFormat.yMMMM().format(_focusedDay),
style: TextStyle(fontSize: 24, fontWeight: FontWeight.bold),
),
),
SizedBox(height: 20),
TableCalendar(
firstDay: DateTime.utc(2020),
lastDay: DateTime.utc(2030),
focusedDay: _focusedDay,
calendarFormat: _calendarFormat,
selectedDayPredicate: (day) {
return isSameDay(_selectedDay, day);
},
onDaySelected: (selectedDay, focusedDay) {
setState(() {
_selectedDay = selectedDay;
_focusedDay = focusedDay;
});
},
onPageChanged: (focusedDay) {
setState(() {
_focusedDay = focusedDay;
});
},
headerVisible: false, // This removes the button next to the month name
calendarStyle: CalendarStyle(
defaultTextStyle: TextStyle(fontSize: 16),
selectedDecoration: BoxDecoration(
color: Colors.blue,
shape: BoxShape.circle,
),
todayDecoration: BoxDecoration(
color: Colors.transparent,
shape: BoxShape.circle,
border: Border.all(color: Colors.blue, width: 2),
),
),
daysOfWeekStyle: DaysOfWeekStyle(
weekdayStyle: TextStyle(color: Colors.black87),
weekendStyle: TextStyle(color: Colors.red),
),
),
SizedBox(height: 20),
Container(
margin: EdgeInsets.symmetric(horizontal: 16),
child: Text(
'Special Notes',
style: TextStyle(fontSize: 18, fontWeight: FontWeight.bold),
),
),
],
),
),
);
}
}
...@@ -16,7 +16,7 @@ import 'kidsReportView.dart'; ...@@ -16,7 +16,7 @@ import 'kidsReportView.dart';
class ChildrenProfilePage extends StatelessWidget { class ChildrenProfilePage extends StatelessWidget {
late User? user; late User? user;
late final Stream<QuerySnapshot> _usersStream, _usersStream2; late final Stream<QuerySnapshot> _usersStream, _usersStream2;
int _age = 0; int _age = 10;
String role = ''; String role = '';
late final userDetails; late final userDetails;
ChildrenProfilePage(document, role) { ChildrenProfilePage(document, role) {
...@@ -75,7 +75,8 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -75,7 +75,8 @@ class ChildrenProfilePage extends StatelessWidget {
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Text( Text(
'Bright Sparkle ', userDetails['className'],
// 'Bright Sparkle ',
style: TextStyle( style: TextStyle(
color: Color(0xFF11324D), color: Color(0xFF11324D),
fontSize: 24, fontSize: 24,
...@@ -593,7 +594,7 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -593,7 +594,7 @@ class ChildrenProfilePage extends StatelessWidget {
], ],
), ),
), ),
const SizedBox(height: 14), const SizedBox(height: 8),
Container( Container(
child: Row( child: Row(
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
...@@ -604,7 +605,7 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -604,7 +605,7 @@ class ChildrenProfilePage extends StatelessWidget {
children: [ children: [
Container( Container(
padding: const EdgeInsets.symmetric( padding: const EdgeInsets.symmetric(
horizontal: 40, vertical: 12), horizontal: 40, vertical: 18), //play game button
decoration: ShapeDecoration( decoration: ShapeDecoration(
color: Color(0xFF48B62C), color: Color(0xFF48B62C),
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
...@@ -679,7 +680,7 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -679,7 +680,7 @@ class ChildrenProfilePage extends StatelessWidget {
sid: userDetails.id)), sid: userDetails.id)),
); );
}, },
child: Container( child: Container(
width: width:
MediaQuery.of(context).size.width * 0.4, MediaQuery.of(context).size.width * 0.4,
height: 135, height: 135,
...@@ -716,8 +717,7 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -716,8 +717,7 @@ class ChildrenProfilePage extends StatelessWidget {
children: [ children: [
Padding( Padding(
padding: padding:
const EdgeInsets.fromLTRB( const EdgeInsets.fromLTRB(0, 0, 0, 5),
0, 0, 0, 10),
child: Container( child: Container(
width: 16.88, width: 16.88,
height: 16.88, height: 16.88,
...@@ -725,35 +725,36 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -725,35 +725,36 @@ class ChildrenProfilePage extends StatelessWidget {
decoration: BoxDecoration(), decoration: BoxDecoration(),
child: Stack(children: [ child: Stack(children: [
Icon( Icon(
Icons.book, Icons.person_3,
color: Colors.black26, color: Colors.black26,
), ),
]), ]),
), ),
), ),
const SizedBox(height: 1), const SizedBox(height: 0),
SizedBox( SizedBox(
width: 119.18, width: 119.18,
child: Text.rich( child: Text.rich(
TextSpan( TextSpan(
children: [ children: [
TextSpan( TextSpan(
text: 'Monthly \n ', text: 'Monthly \npsycholo. report \n ',
style: TextStyle( style: TextStyle(
color: color:
Color(0xFF403572), Color(0xFF403572),
fontSize: 14, fontSize: 14,
fontFamily: 'Roboto', fontFamily: 'poppins',
fontWeight: fontWeight:
FontWeight.w500, FontWeight.w500,
height: 0.09, // letterSpacing: 0.08,
height: 0.9,
), ),
), ),
], ],
), ),
), ),
), ),
const SizedBox(height: 12), const SizedBox(height: 1),
SizedBox( SizedBox(
width: 119.18, width: 119.18,
child: Opacity( child: Opacity(
...@@ -762,8 +763,8 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -762,8 +763,8 @@ class ChildrenProfilePage extends StatelessWidget {
'Some short description of this type of report.', 'Some short description of this type of report.',
style: TextStyle( style: TextStyle(
color: Color(0xFF8DAEAE), color: Color(0xFF8DAEAE),
fontSize: 10.55, fontSize: 9.55,
fontFamily: 'Roboto', fontFamily: 'poppins',
fontWeight: fontWeight:
FontWeight.w400, FontWeight.w400,
height: 0, height: 0,
...@@ -825,8 +826,7 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -825,8 +826,7 @@ class ChildrenProfilePage extends StatelessWidget {
children: [ children: [
Padding( Padding(
padding: padding:
const EdgeInsets.fromLTRB( const EdgeInsets.fromLTRB(0, 0, 0, 5),
0, 0, 0, 10),
child: Container( child: Container(
width: 16.88, width: 16.88,
height: 16.88, height: 16.88,
...@@ -834,7 +834,7 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -834,7 +834,7 @@ class ChildrenProfilePage extends StatelessWidget {
decoration: BoxDecoration(), decoration: BoxDecoration(),
child: Stack(children: [ child: Stack(children: [
Icon( Icon(
Icons.book, Icons.calendar_month,
color: Colors.black26, color: Colors.black26,
), ),
]), ]),
...@@ -847,22 +847,22 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -847,22 +847,22 @@ class ChildrenProfilePage extends StatelessWidget {
TextSpan( TextSpan(
children: [ children: [
TextSpan( TextSpan(
text: 'Monthly \n', text: 'Monthly prediction report \n',
style: TextStyle( style: TextStyle(
color: color:
Color(0xFF479696), Color(0xFF479696),
fontSize: 14, fontSize: 14,
fontFamily: 'Roboto', fontFamily: 'Poppins',
fontWeight: fontWeight:
FontWeight.w500, FontWeight.w500,
height: 0.09, height: 0.9,
), ),
), ),
], ],
), ),
), ),
), ),
const SizedBox(height: 12), const SizedBox(height: 1),
SizedBox( SizedBox(
width: 119.18, width: 119.18,
child: Opacity( child: Opacity(
...@@ -871,8 +871,8 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -871,8 +871,8 @@ class ChildrenProfilePage extends StatelessWidget {
'Some short description of this type of report.', 'Some short description of this type of report.',
style: TextStyle( style: TextStyle(
color: Color(0xFF8DAEAE), color: Color(0xFF8DAEAE),
fontSize: 10.55, fontSize: 9.55,
fontFamily: 'Roboto', fontFamily: 'poppins',
fontWeight: fontWeight:
FontWeight.w400, FontWeight.w400,
height: 0, height: 0,
......
...@@ -4,8 +4,12 @@ import 'package:cloud_firestore/cloud_firestore.dart'; ...@@ -4,8 +4,12 @@ import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/Attendance.dart'; import 'package:mobile_application_kids/Attendance.dart';
import 'package:mobile_application_kids/ChatScreen.dart';
import 'package:mobile_application_kids/ChildrenActivity.dart'; import 'package:mobile_application_kids/ChildrenActivity.dart';
import 'package:mobile_application_kids/ReportKids.dart'; import 'package:mobile_application_kids/ReportKids.dart';
import 'package:mobile_application_kids/TeacherProfile.dart';
import 'package:mobile_application_kids/calendar.dart';
import 'package:mobile_application_kids/teacherhome.dart';
import 'CheckKids.dart'; import 'CheckKids.dart';
import 'ChildrenHomePage.dart'; import 'ChildrenHomePage.dart';
import 'addstudent.dart'; import 'addstudent.dart';
...@@ -32,13 +36,23 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -32,13 +36,23 @@ class ClassroomViewPage extends StatelessWidget {
double width = MediaQuery.of(context).size.width; double width = MediaQuery.of(context).size.width;
return Scaffold( return Scaffold(
appBar: AppBar( appBar: AppBar(
leading: IconButton( title: Text(' '),
icon: Icon(Icons.arrow_back), actions: [
onPressed: () { Container(
Navigator.pop(context); alignment: Alignment.centerRight,
}, padding: EdgeInsets.only(right: 16),
child: Text('Class Room',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
), ),
title: Text('Class Room '), ),
),
],
), ),
body: SingleChildScrollView( body: SingleChildScrollView(
child: Padding( child: Padding(
...@@ -56,29 +70,25 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -56,29 +70,25 @@ class ClassroomViewPage extends StatelessWidget {
SizedBox(height: 10), SizedBox(height: 10),
Center( Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(8.0), padding: const EdgeInsets.all(8.8),
child: Container( child: Container(
width: MediaQuery.of(context).size.width * 0.9, width: MediaQuery.of(context).size.width * 1,
height: MediaQuery.of(context).size.height / 20, height: MediaQuery.of(context).size.height / 12,
child: SingleChildScrollView( child: SingleChildScrollView(
scrollDirection: Axis.horizontal, scrollDirection: Axis.horizontal,
child: Row( child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.end, crossAxisAlignment: CrossAxisAlignment.center, // Adjusted crossAxisAlignment
children: [ children: [
Container( Container(
child: SingleChildScrollView( child: SingleChildScrollView(
scrollDirection: Axis scrollDirection: Axis.horizontal, // Enable horizontal scrolling
.horizontal, // Enable horizontal scrolling
child: Container( child: Container(
width: 333, width: 333,
padding: const EdgeInsets.symmetric( padding: const EdgeInsets.symmetric(horizontal: 50, vertical: 5),
horizontal: 56, vertical: 5),
decoration: ShapeDecoration( decoration: ShapeDecoration(
color: Color.fromARGB(255, 255, 255, 255), color: Color.fromARGB(255, 255, 255, 255),
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(6)),
borderRadius: BorderRadius.circular(6)),
shadows: [ shadows: [
BoxShadow( BoxShadow(
color: Color(0x3F000000), color: Color(0x3F000000),
...@@ -90,42 +100,37 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -90,42 +100,37 @@ class ClassroomViewPage extends StatelessWidget {
), ),
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.center, mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center, crossAxisAlignment: CrossAxisAlignment.center, // Adjusted crossAxisAlignment
children: [ children: [
Container( Container(
width: 32, width: 36,
height: 32, height: 36,
decoration: ShapeDecoration( decoration: ShapeDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage('lib/assets/Vector 2.png'),
'lib/assets/Vector 2.png'),
fit: BoxFit.fill, fit: BoxFit.fill,
), ),
shape: OvalBorder(), shape: OvalBorder(),
), ),
), ),
const SizedBox(width: 40), const SizedBox(width: 6),
FutureBuilder<String>( FutureBuilder<String>(
future: getStudentCount(), future: getStudentCount(),
builder: (context, snapshot) { builder: (context, snapshot) {
if (snapshot.connectionState == if (snapshot.connectionState == ConnectionState.waiting) {
ConnectionState.waiting) {
return CircularProgressIndicator(); // Show loading indicator return CircularProgressIndicator(); // Show loading indicator
} }
if (snapshot.hasError) { if (snapshot.hasError) {
return Text( return Text('Error: ${snapshot.error}'); // Show error message
'Error: ${snapshot.error}'); // Show error message
} }
// Use the result of getStudentCount // Use the result of getStudentCount
return Text( return Text(
'Children ' + 'Children Count ' + (snapshot.data ?? '0'), // Default to '0' if data is null
(snapshot.data ??
'0'), // Default to '0' if data is null
style: TextStyle( style: TextStyle(
color: Colors.black, color: Colors.black,
fontSize: 12, fontSize: 15,
fontFamily: 'Poppins', fontFamily: 'Poppins',
fontWeight: FontWeight.w400, fontWeight: FontWeight.w600,
), ),
); );
}, },
...@@ -135,17 +140,13 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -135,17 +140,13 @@ class ClassroomViewPage extends StatelessWidget {
onTap: () => Navigator.push( onTap: () => Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => builder: (context) => AddStudentPage(classname: documents)),
AddStudentPage(
classname: documents)),
), ),
child: Container( child: Container(
margin: EdgeInsets.only(left: 8.0), margin: EdgeInsets.only(left: 32.0),
decoration: BoxDecoration( decoration: BoxDecoration(
color: color: Colors.blueAccent,
Color.fromARGB(203, 164, 88, 177), borderRadius: BorderRadius.circular(4.20),
borderRadius:
BorderRadius.circular(4.20),
), ),
child: Icon( child: Icon(
Icons.add, Icons.add,
...@@ -164,6 +165,7 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -164,6 +165,7 @@ class ClassroomViewPage extends StatelessWidget {
), ),
), ),
), ),
SizedBox(height: 10), SizedBox(height: 10),
GridView.count( GridView.count(
crossAxisCount: 2, crossAxisCount: 2,
...@@ -372,7 +374,7 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -372,7 +374,7 @@ class ClassroomViewPage extends StatelessWidget {
right: 8, right: 8,
bottom: 8, bottom: 8,
child: Image.asset( child: Image.asset(
"lib/assets/Vector22.png", // Replace with your image URL "lib/assets/Vector22.png",
width: 59, width: 59,
height: 81, height: 81,
fit: BoxFit.cover, fit: BoxFit.cover,
...@@ -445,7 +447,7 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -445,7 +447,7 @@ class ClassroomViewPage extends StatelessWidget {
right: 8, right: 8,
bottom: 8, bottom: 8,
child: Image.asset( child: Image.asset(
"lib/assets/Vector23.png", // Replace with your image URL "lib/assets/Vector23.png",
width: 59, width: 59,
height: 81, height: 81,
fit: BoxFit.cover, fit: BoxFit.cover,
...@@ -538,7 +540,7 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -538,7 +540,7 @@ class ClassroomViewPage extends StatelessWidget {
right: 8, right: 8,
bottom: 8, bottom: 8,
child: Image.asset( child: Image.asset(
"lib/assets/Vector24.png", // Replace with your image URL "lib/assets/Vector24.png",
width: 59, width: 59,
height: 81, height: 81,
fit: BoxFit.cover, fit: BoxFit.cover,
...@@ -549,7 +551,13 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -549,7 +551,13 @@ class ClassroomViewPage extends StatelessWidget {
), ),
), ),
), ),
Padding( GestureDetector(
onTap: () {
Navigator.of(context).push(MaterialPageRoute(
builder: (_) => CalendarScreen(),
));
},
child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(10.0),
child: Container( child: Container(
width: 170, width: 170,
...@@ -614,6 +622,8 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -614,6 +622,8 @@ class ClassroomViewPage extends StatelessWidget {
), ),
), ),
), ),
),
GestureDetector( GestureDetector(
onTap: () { onTap: () {
Navigator.of(context).push(MaterialPageRoute( Navigator.of(context).push(MaterialPageRoute(
...@@ -692,6 +702,50 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -692,6 +702,50 @@ class ClassroomViewPage extends StatelessWidget {
), ),
), ),
), ),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Color.fromARGB(255, 103, 103, 103),
onTap: (index) {
// Handle bottom navigation item tap
switch (index) {
case 0:
// Navigate to Home
Navigator.push(
context,
MaterialPageRoute(builder: (context) => TeacherHomePage()),
);
break;
case 1:
// Navigate to Chat
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ChatScreen()),
);
break;
case 2:
// Navigate to Profile
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherProfilePage(uid: user?.uid)),
);
break;
}
},
),
); );
} }
......
...@@ -78,7 +78,23 @@ class _KidsReportPageState extends State<KidsReportPage> { ...@@ -78,7 +78,23 @@ class _KidsReportPageState extends State<KidsReportPage> {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Scaffold( return Scaffold(
appBar: AppBar( appBar: AppBar(
title: Text('Student Report'), title: Text(' '),
actions: [
Container(
alignment: Alignment.centerRight,
padding: EdgeInsets.only(right: 16),
child: Text('Student Report',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
),
),
),
],
), ),
body: SingleChildScrollView( body: SingleChildScrollView(
child: Center( child: Center(
...@@ -305,7 +321,10 @@ class _KidsReportPageState extends State<KidsReportPage> { ...@@ -305,7 +321,10 @@ class _KidsReportPageState extends State<KidsReportPage> {
dialogType: DialogType.success, dialogType: DialogType.success,
animType: AnimType.rightSlide, animType: AnimType.rightSlide,
title: 'Successfully Created', title: 'Successfully Created',
btnOkOnPress: () {}, btnOkOnPress: () {
// Navigate back to the previous page
Navigator.pop(context);
},
)..show(); )..show();
} }
} }
\ No newline at end of file
...@@ -22,17 +22,26 @@ class KidsReportsPage extends StatelessWidget { ...@@ -22,17 +22,26 @@ class KidsReportsPage extends StatelessWidget {
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
// Text(
// 'Bright Sparkle ',
// style: TextStyle(
// color: Color(0xFF11324D),
// fontSize: 24,
// fontFamily: 'Poppins',
// fontWeight: FontWeight.w500,
// height: 0.04,
// letterSpacing: -0.96,
// ),
// ),
SizedBox(height: 20), // Add space here
Text( Text(
'Bright Sparkle ', 'Select Kids ',
style: TextStyle( style: TextStyle(
fontSize: 18, color: Color(0xFF21205B),
fontWeight: FontWeight.bold, fontSize: 16,
), fontFamily: 'Poppins',
), fontWeight: FontWeight.w500,
Text( height: 0.06,
'Select Kid',
style: TextStyle(
fontSize: 18,
), ),
), ),
SizedBox(height: 16), SizedBox(height: 16),
......
...@@ -194,8 +194,8 @@ class _LoginPage extends State<LoginPage> { ...@@ -194,8 +194,8 @@ class _LoginPage extends State<LoginPage> {
context: context, context: context,
dialogType: DialogType.info, dialogType: DialogType.info,
animType: AnimType.rightSlide, animType: AnimType.rightSlide,
title: ' login Perent', title: ' login Parent',
desc: ' Go to your home page', desc: ' Go to your parent home page',
btnCancelOnPress: () {}, btnCancelOnPress: () {},
btnOkOnPress: () { btnOkOnPress: () {
Navigator.pushReplacement( Navigator.pushReplacement(
......
...@@ -61,7 +61,7 @@ class _MyHomePageState extends State<MyHomePage> { ...@@ -61,7 +61,7 @@ class _MyHomePageState extends State<MyHomePage> {
@override @override
void initState() { void initState() {
super.initState(); super.initState();
Timer.periodic(Duration(milliseconds: 800), (timer) { Timer.periodic(Duration(milliseconds: 700), (timer) {
setState(() { setState(() {
// Toggle between zoom in and zoom out // Toggle between zoom in and zoom out
scaleFactor = scaleFactor == 1.0 ? 1.05 : 1.0; scaleFactor = scaleFactor == 1.0 ? 1.05 : 1.0;
......
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/sign_in_up.dart';
import 'ParentLogin.dart'; import 'ParentLogin.dart';
import 'login.dart'; import 'login.dart';
...@@ -20,7 +21,11 @@ class ParentTeacherPage extends StatelessWidget { ...@@ -20,7 +21,11 @@ class ParentTeacherPage extends StatelessWidget {
color: const Color.fromARGB(255, 0, 0, 0), color: const Color.fromARGB(255, 0, 0, 0),
), ),
onPressed: () { onPressed: () {
Navigator.pop(context); Navigator.pushAndRemoveUntil(
context,
MaterialPageRoute(builder: (context) => SignInUpPage(backgroundColor: Colors.white,)),
(Route<dynamic> route) => false,
);
}, },
), ),
), ),
......
...@@ -16,15 +16,6 @@ class ParentTeacherSignUpPage extends StatelessWidget { ...@@ -16,15 +16,6 @@ class ParentTeacherSignUpPage extends StatelessWidget {
appBar: AppBar( appBar: AppBar(
backgroundColor: Colors.transparent, backgroundColor: Colors.transparent,
elevation: 0, elevation: 0,
leading: IconButton(
icon: Icon(
Icons.arrow_back,
color: const Color.fromARGB(255, 0, 0, 0),
),
onPressed: () {
Navigator.pop(context);
},
),
), ),
body: Container( body: Container(
color: backgroundColor, color: backgroundColor,
......
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/ChildrenProfile_parent.dart';
import 'package:mobile_application_kids/classroomview.dart'; import 'package:mobile_application_kids/classroomview.dart';
import 'package:mobile_application_kids/addclassroom.dart'; import 'package:mobile_application_kids/addclassroom.dart';
import 'package:mobile_application_kids/games.dart'; import 'package:mobile_application_kids/games.dart';
import 'package:mobile_application_kids/parentProfile.dart';
import 'package:mobile_application_kids/teacherchat.dart'; import 'package:mobile_application_kids/teacherchat.dart';
import 'ChatScreen.dart'; import 'ChatScreen.dart';
...@@ -43,13 +45,16 @@ class ParentHomePage extends StatelessWidget { ...@@ -43,13 +45,16 @@ class ParentHomePage extends StatelessWidget {
}, },
child: Scaffold( child: Scaffold(
appBar: AppBar( appBar: AppBar(
// leading: Flexible( automaticallyImplyLeading: false,
// child: Image.asset( centerTitle: false,
// 'lib/assets/logo.png', title: Container(
// fit: BoxFit.contain, width: 230,
// height: 150, // Adjust the height to make the logo bigger child: Image.asset(
// ), 'lib/assets/i2.png',
// ), fit: BoxFit.fitHeight,
alignment: Alignment.topLeft,
),
),
actions: [ actions: [
IconButton( IconButton(
icon: Icon(Icons.notifications), icon: Icon(Icons.notifications),
...@@ -60,11 +65,11 @@ class ParentHomePage extends StatelessWidget { ...@@ -60,11 +65,11 @@ class ParentHomePage extends StatelessWidget {
], ],
), ),
body: Padding( body: Padding(
padding: const EdgeInsets.all(16.0), padding: const EdgeInsets.all(10.0),
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
SizedBox(height: 20), SizedBox(height: 12),
Text( Text(
'Explore, learn, and play in our magical world of wonder!', 'Explore, learn, and play in our magical world of wonder!',
style: poppinsTextStyle.copyWith( style: poppinsTextStyle.copyWith(
...@@ -72,38 +77,42 @@ class ParentHomePage extends StatelessWidget { ...@@ -72,38 +77,42 @@ class ParentHomePage extends StatelessWidget {
fontSize: 13, fontSize: 13,
), ),
), ),
SizedBox(height: 10), SizedBox(height: 20),
Expanded( Expanded(
child: ClipRRect(
borderRadius: BorderRadius.circular(10),
child: Image.asset( child: Image.asset(
'lib/assets/teacherhome.png', 'lib/assets/teacherhome.png',
fit: BoxFit.contain, fit: BoxFit.fitHeight,
), ),
), ),
SizedBox(height: 20), ),
Row( // SizedBox(height: 20),
mainAxisAlignment: MainAxisAlignment.center, // Row(
children: [ // mainAxisAlignment: MainAxisAlignment.center,
TextButton( // children: [
onPressed: () { // // // TextButton(
// Navigate to the AddClassroomPage // // // onPressed: () {
Navigator.push( // // // // Navigate to the AddClassroomPage
context, // // // Navigator.push(
MaterialPageRoute( // // // context,
builder: (context) => AddClassroomPage()), // // // MaterialPageRoute(
); // // // builder: (context) => AddClassroomPage()),
}, // // // );
child: Row( // // // },
children: [], // // // child: Row(
), // // // children: [],
), // // // ),
], // // ),
), // ],
// ),
SizedBox(height: 10),
Divider(), Divider(),
SizedBox(height: 10), SizedBox(height: 10),
Text( Text(
'All Kids', 'All Kids',
style: poppinsTextStyle.copyWith( style: poppinsTextStyle.copyWith(
fontSize: 16, fontSize: 18,
fontWeight: FontWeight.bold, fontWeight: FontWeight.bold,
), ),
), ),
...@@ -163,11 +172,11 @@ class ParentHomePage extends StatelessWidget { ...@@ -163,11 +172,11 @@ class ParentHomePage extends StatelessWidget {
], ],
), ),
trailing: Container( trailing: Container(
height: 35.0, height: 40.0,
width: 80.0, width: 100.0,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Color.fromARGB(203, 164, 88, 177), color: Colors.blueAccent,
borderRadius: BorderRadius.circular(4.0), borderRadius: BorderRadius.circular(8.0),
), ),
child: TextButton( child: TextButton(
onPressed: () { onPressed: () {
...@@ -177,7 +186,7 @@ class ParentHomePage extends StatelessWidget { ...@@ -177,7 +186,7 @@ class ParentHomePage extends StatelessWidget {
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => builder: (context) =>
ChildrenProfilePage(document, "P"), pChildrenProfilePage(document, "P"),
), ),
); );
}, },
...@@ -199,50 +208,6 @@ class ParentHomePage extends StatelessWidget { ...@@ -199,50 +208,6 @@ class ParentHomePage extends StatelessWidget {
], ],
), ),
), ),
// bottomNavigationBar: BottomNavigationBar(
// items: const [
// BottomNavigationBarItem(
// icon: Icon(Icons.home),
// label: 'Home',
// ),
// BottomNavigationBarItem(
// icon: Icon(Icons.chat),
// label: 'Chat',
// ),
// BottomNavigationBarItem(
// icon: Icon(Icons.person),
// label: 'Profile',
// ),
// ],
// selectedItemColor: Colors.blue,
// onTap: (index) {
// // Handle bottom navigation item tap
// switch (index) {
// case 0:
// break;
// case 1:
// // Navigate to Chat
// Navigator.push(
// context,
// MaterialPageRoute(builder: (context) => ChatScreen()),
// );
// break;
// case 2:
// // Navigate to Profile
// Navigator.push(
// context,
// MaterialPageRoute(
// builder: (context) => TeacherProfilePage(
// uid: user?.uid,
// )),
// );
// break;
// }
// },
// ),
bottomNavigationBar: BottomNavigationBar( bottomNavigationBar: BottomNavigationBar(
items: const [ items: const [
BottomNavigationBarItem( BottomNavigationBarItem(
...@@ -254,7 +219,7 @@ class ParentHomePage extends StatelessWidget { ...@@ -254,7 +219,7 @@ class ParentHomePage extends StatelessWidget {
label: 'Chat', label: 'Chat',
), ),
BottomNavigationBarItem( BottomNavigationBarItem(
icon: Icon(Icons.videogame_asset), icon: Icon(Icons.sports_baseball),
label: 'Games', label: 'Games',
), ),
BottomNavigationBarItem( BottomNavigationBarItem(
...@@ -262,37 +227,43 @@ class ParentHomePage extends StatelessWidget { ...@@ -262,37 +227,43 @@ class ParentHomePage extends StatelessWidget {
label: 'Profile', label: 'Profile',
), ),
], ],
selectedItemColor: Color(0xFF7A1FA0), selectedItemColor: Colors.blueAccent,
unselectedItemColor: Color(0xFFA9ABAD), unselectedItemColor: Colors.grey,
selectedLabelStyle: TextStyle(color: Color(0xFF7A1FA0)),
unselectedLabelStyle: TextStyle(color: Color.fromARGB(0, 197, 16, 16)),
currentIndex: 0, currentIndex: 0,
onTap: (index) { onTap: (index) {
// Handle bottom navigation item tap
switch (index) { switch (index) {
case 0: case 0:
break; // Navigate to Home
// Navigator.push(
// context,
// MaterialPageRoute(builder: (context) => ParentHomePage()),
// );
// break;
case 1: case 1:
// Navigate to Chat
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => ChatScreen()), MaterialPageRoute(builder: (context) => ChatScreen()),
); );
break; break;
case 2: case 2:
// Handle Game // Navigate to Games
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(builder: (context) => GamesPage()),
builder: (context) => GamesPage(
),
),
); );
break; break;
case 3: case 3:
// Navigate to Profile
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => TeacherProfilePage( builder: (context) => ParentProfilePage(
uid: user?.uid, uid: user?.uid,
phoneNo: phoneNo,
role: role,
), ),
), ),
); );
...@@ -300,6 +271,7 @@ class ParentHomePage extends StatelessWidget { ...@@ -300,6 +271,7 @@ class ParentHomePage extends StatelessWidget {
} }
}, },
), ),
), ),
); );
} }
......
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
import 'package:mobile_application_kids/ChatScreen.dart';
import 'package:mobile_application_kids/p_or_t.dart';
import 'package:mobile_application_kids/parenthome.dart';
class ParentProfilePage extends StatefulWidget {
final String? uid;
final String phoneNo;
final String role;
ParentProfilePage({required this.uid, required this.phoneNo, required this.role, Key? key});
@override
_ParentProfilePageState createState() => _ParentProfilePageState(uid!, phoneNo, role);
}
class _ParentProfilePageState extends State<ParentProfilePage> {
late User? user;
late String fullName = "";
late String email = "";
late String phoneNo = "";
final FirebaseAuth _auth = FirebaseAuth.instance;
late String uid;
late String role;
_ParentProfilePageState(this.uid, this.phoneNo, this.role);
@override
void initState() {
super.initState();
user = FirebaseAuth.instance.currentUser;
getUserData();
}
Future<void> getUserData() async {
try {
DocumentSnapshot documentSnapshot = await FirebaseFirestore.instance
.collection('users')
.doc(uid)
.get();
if (documentSnapshot.exists) {
Map<String, dynamic> targetDoc = documentSnapshot.data() as Map<String, dynamic>;
setState(() {
fullName = targetDoc['fullName'];
email = targetDoc['email'];
phoneNo = targetDoc['phoneNo'];
});
print("Full Name: $fullName, Email: $email, Phone Number: $phoneNo");
} else {
print("Document does not exist");
}
} catch (error) {
print("Error getting document: $error");
}
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text(' '),
actions: [
Container(
alignment: Alignment.centerRight,
padding: EdgeInsets.only(right: 16),
child: Text('Parent Profile',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
),
),
),
],
),
body: SingleChildScrollView(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
SizedBox(height: 20),
Container(
decoration: BoxDecoration(
image: DecorationImage(
image: AssetImage('lib/assets/parentprof.PNG'),
fit: BoxFit.fitHeight,
),
),
height: 300, // Adjust height as needed
),
Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
SizedBox(height: 10),
ListTile(
leading: Icon(Icons.person),
title: Text(
'Full Name: $fullName',
style: TextStyle(
fontSize: 18,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
),
),
),
ListTile(
leading: Icon(Icons.email),
title: Text(
'Email: $email',
style: TextStyle(
fontSize: 18,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
),
),
),
ListTile(
leading: Icon(Icons.phone),
title: Text(
'Phone Number: $phoneNo',
style: TextStyle(
fontSize: 18,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
),
),
),
],
),
),
SizedBox(height: 20),
Center(
child: ElevatedButton(
onPressed: () => _signOut(context),
style: ElevatedButton.styleFrom(
primary: Colors.blueAccent,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10.0),
),
),
child: Padding(
padding: const EdgeInsets.all(10.0),
child: Text(
'Sign Out',
style: TextStyle(color: const Color.fromARGB(255, 255, 255, 255)),
),
),
),
),
],
),
),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Colors.blue,
currentIndex: 2,
onTap: (index) {
if (index == 0) {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ParentHomePage(phoneNo, role)),
);
}
if (index == 1) {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ChatScreen()),
);
}
},
),
);
}
Future<void> _signOut(BuildContext context) async {
try {
await _auth.signOut();
Navigator.pushAndRemoveUntil(
context,
MaterialPageRoute(builder: (BuildContext context) => ParentTeacherPage(backgroundColor: Color.fromARGB(255, 255, 255, 255))),
(route) => false,
);
} catch (e) {
print('Error signing out: $e');
}
}
}
...@@ -37,15 +37,16 @@ class TeacherHomePage extends StatelessWidget { ...@@ -37,15 +37,16 @@ class TeacherHomePage extends StatelessWidget {
}, },
child: Scaffold( child: Scaffold(
appBar: AppBar( appBar: AppBar(
// leading: Padding( automaticallyImplyLeading: false,
// padding: const EdgeInsets.only(left: 20), centerTitle: false,
// child: SizedBox( title: Container(
// child: Image.asset( width: 230,
// 'lib/assets/logo.png', child: Image.asset(
// fit: BoxFit.contain, 'lib/assets/i2.png',
// ), fit: BoxFit.fitHeight,
// ), alignment: Alignment.topLeft,
// ), ),
),
actions: [ actions: [
IconButton( IconButton(
icon: Icon(Icons.notifications), icon: Icon(Icons.notifications),
...@@ -56,11 +57,11 @@ class TeacherHomePage extends StatelessWidget { ...@@ -56,11 +57,11 @@ class TeacherHomePage extends StatelessWidget {
], ],
), ),
body: Padding( body: Padding(
padding: const EdgeInsets.all(16.0), padding: const EdgeInsets.all(12.0),
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
SizedBox(height: 20), SizedBox(height: 10),
Text( Text(
'Explore, learn, and play in our magical world of wonder!', 'Explore, learn, and play in our magical world of wonder!',
style: poppinsTextStyle.copyWith( style: poppinsTextStyle.copyWith(
...@@ -68,11 +69,14 @@ class TeacherHomePage extends StatelessWidget { ...@@ -68,11 +69,14 @@ class TeacherHomePage extends StatelessWidget {
fontSize: 13, fontSize: 13,
), ),
), ),
SizedBox(height: 10), SizedBox(height: 12),
Expanded( Expanded(
child: ClipRRect(
borderRadius: BorderRadius.circular(10),
child: Image.asset( child: Image.asset(
'lib/assets/teacherhome.png', 'lib/assets/teacherhome.png',
fit: BoxFit.contain, fit: BoxFit.fitHeight,
),
), ),
), ),
Row( Row(
...@@ -89,6 +93,7 @@ class TeacherHomePage extends StatelessWidget { ...@@ -89,6 +93,7 @@ class TeacherHomePage extends StatelessWidget {
}, },
child: Row( child: Row(
children: [ children: [
SizedBox(height: 12),
Text( Text(
'Create New Class Room Here', 'Create New Class Room Here',
style: poppinsTextStyle.copyWith( style: poppinsTextStyle.copyWith(
...@@ -96,8 +101,9 @@ class TeacherHomePage extends StatelessWidget { ...@@ -96,8 +101,9 @@ class TeacherHomePage extends StatelessWidget {
fontSize: 16, fontSize: 16,
), ),
), ),
SizedBox(height: 12),
Container( Container(
margin: EdgeInsets.only(left: 20.0), margin: EdgeInsets.only(left: 23.0),
padding: EdgeInsets.all(8.0), padding: EdgeInsets.all(8.0),
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.blueAccent, color: Colors.blueAccent,
...@@ -114,7 +120,7 @@ class TeacherHomePage extends StatelessWidget { ...@@ -114,7 +120,7 @@ class TeacherHomePage extends StatelessWidget {
], ],
), ),
Divider(), Divider(),
SizedBox(height: 10), SizedBox(height: 8),
Text( Text(
'Class Rooms', 'Class Rooms',
style: poppinsTextStyle.copyWith( style: poppinsTextStyle.copyWith(
......
...@@ -648,6 +648,14 @@ packages: ...@@ -648,6 +648,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.3.2" version: "2.3.2"
simple_gesture_detector:
dependency: transitive
description:
name: simple_gesture_detector
sha256: ba2cd5af24ff20a0b8d609cec3f40e5b0744d2a71804a2616ae086b9c19d19a3
url: "https://pub.dev"
source: hosted
version: "0.2.1"
sky_engine: sky_engine:
dependency: transitive dependency: transitive
description: flutter description: flutter
...@@ -717,6 +725,14 @@ packages: ...@@ -717,6 +725,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "3.1.0+1" version: "3.1.0+1"
table_calendar:
dependency: "direct main"
description:
name: table_calendar
sha256: "7f1270313c0cdb245b583ed8518982c01d4a7e95869b3c30abcbae3b642c45d0"
url: "https://pub.dev"
source: hosted
version: "3.0.8"
term_glyph: term_glyph:
dependency: transitive dependency: transitive
description: description:
......
...@@ -47,6 +47,7 @@ dependencies: ...@@ -47,6 +47,7 @@ dependencies:
url_launcher: ^6.1.14 url_launcher: ^6.1.14
cached_network_image: ^3.3.1 cached_network_image: ^3.3.1
charts_flutter: ^0.12.0 charts_flutter: ^0.12.0
table_calendar: ^3.0.8
dev_dependencies: dev_dependencies:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment