diff --git a/.idea/Project_JustMusic.iml b/.idea/Project_JustMusic.iml index 0e67cf3..ea13052 100644 --- a/.idea/Project_JustMusic.iml +++ b/.idea/Project_JustMusic.iml @@ -6,6 +6,9 @@ + + + diff --git a/.idea/libraries/Dart_Packages.xml b/.idea/libraries/Dart_Packages.xml deleted file mode 100644 index 0a71dbc..0000000 --- a/.idea/libraries/Dart_Packages.xml +++ /dev/null @@ -1,436 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/libraries/Dart_SDK.xml b/.idea/libraries/Dart_SDK.xml index 6ae284f..8173c5d 100644 --- a/.idea/libraries/Dart_SDK.xml +++ b/.idea/libraries/Dart_SDK.xml @@ -1,25 +1,25 @@ - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + diff --git a/Sources/justMUSIC/assets/images/return_icon.png b/Sources/justMUSIC/assets/images/return_icon.png new file mode 100644 index 0000000..b217978 Binary files /dev/null and b/Sources/justMUSIC/assets/images/return_icon.png differ diff --git a/Sources/justMUSIC/lib/components/profile_component.dart b/Sources/justMUSIC/lib/components/profile_component.dart new file mode 100644 index 0000000..d5dda14 --- /dev/null +++ b/Sources/justMUSIC/lib/components/profile_component.dart @@ -0,0 +1,43 @@ +import 'package:auto_size_text/auto_size_text.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:google_fonts/google_fonts.dart'; +import 'package:justmusic/components/statistics_component.dart'; + +class ProfileComponent extends StatelessWidget { + const ProfileComponent({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return Column( + children: [ + ClipOval( + child: ConstrainedBox( + constraints: BoxConstraints(maxWidth: 200, maxHeight: 200), + child: Image( + image: AssetImage("assets/images/exemple_profile.png"), + height: 100.w, + width: 100.w, + ), + ), + ), + SizedBox( + height: 10, + ), + AutoSizeText( + "@MelinaShow", + style: GoogleFonts.plusJakartaSans( + fontSize: 15.sp, + color: Colors.white, + fontWeight: FontWeight.w400), + maxFontSize: 30, + ), + SizedBox( + height: 20, + ), + StatisticsComponent(), + ], + ); + } +} diff --git a/Sources/justMUSIC/lib/components/statistics_component.dart b/Sources/justMUSIC/lib/components/statistics_component.dart new file mode 100644 index 0000000..436e37c --- /dev/null +++ b/Sources/justMUSIC/lib/components/statistics_component.dart @@ -0,0 +1,80 @@ +import 'package:auto_size_text/auto_size_text.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:google_fonts/google_fonts.dart'; + +import '../values/constants.dart'; + +class StatisticsComponent extends StatelessWidget { + const StatisticsComponent({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return Row( + mainAxisSize: MainAxisSize.min, + children: [ + Expanded( + child: Column( + children: [ + AutoSizeText( + "114", + style: GoogleFonts.plusJakartaSans( + color: Colors.white, + fontWeight: FontWeight.bold, + fontSize: 15.w), + maxFontSize: 30, + ), + AutoSizeText( + "Suivis", + style: GoogleFonts.plusJakartaSans( + color: grayText, fontSize: 12.w), + maxFontSize: 30, + ) + ], + ), + ), + Column( + mainAxisSize: MainAxisSize.min, + children: [ + AutoSizeText( + "5", + style: GoogleFonts.plusJakartaSans( + color: Colors.white, + fontWeight: FontWeight.bold, + fontSize: 15.w), + maxFontSize: 30, + ), + AutoSizeText( + "Followers", + style: + GoogleFonts.plusJakartaSans(color: grayText, fontSize: 12.w), + maxFontSize: 30, + ) + ], + ), + Expanded( + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + AutoSizeText( + "34", + style: GoogleFonts.plusJakartaSans( + color: Colors.white, + fontWeight: FontWeight.bold, + fontSize: 15.w), + maxFontSize: 30, + ), + AutoSizeText( + "Capsules", + style: GoogleFonts.plusJakartaSans( + color: grayText, fontSize: 12.w), + maxFontSize: 30, + ) + ], + ), + ), + ], + ); + } +} diff --git a/Sources/justMUSIC/lib/components/top_nav_bar_component.dart b/Sources/justMUSIC/lib/components/top_nav_bar_component.dart index cb73a50..e681dee 100644 --- a/Sources/justMUSIC/lib/components/top_nav_bar_component.dart +++ b/Sources/justMUSIC/lib/components/top_nav_bar_component.dart @@ -45,7 +45,7 @@ class _TopNavBarComponentState extends State { child: Column( mainAxisAlignment: MainAxisAlignment.start, children: [ - Image( + const Image( image: AssetImage("assets/images/logo.png"), height: 30, ), diff --git a/Sources/justMUSIC/lib/main.dart b/Sources/justMUSIC/lib/main.dart index a633f84..49cae25 100644 --- a/Sources/justMUSIC/lib/main.dart +++ b/Sources/justMUSIC/lib/main.dart @@ -1,7 +1,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; -import 'package:justmusic/screens/feed_screen.dart'; +import 'package:justmusic/screens/profile_screen.dart'; void main() { runApp(const MyApp()); @@ -32,7 +32,7 @@ class MyApp extends StatelessWidget { primarySwatch: Colors.blue, ), home: const SafeArea( - child: FeedScreen(), + child: ProfileScreen(), )); }, designSize: Size(390, 844), diff --git a/Sources/justMUSIC/lib/screens/feed_screen.dart b/Sources/justMUSIC/lib/screens/feed_screen.dart index cae3a5d..3733ef8 100644 --- a/Sources/justMUSIC/lib/screens/feed_screen.dart +++ b/Sources/justMUSIC/lib/screens/feed_screen.dart @@ -2,7 +2,6 @@ import 'package:circular_reveal_animation/circular_reveal_animation.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; - import '../components/comment_component.dart'; import '../components/post_component.dart'; import '../components/top_nav_bar_component.dart'; @@ -84,7 +83,7 @@ class _FeedScreenState extends State builder: ((context) { return Container( height: 720.h, - margin: EdgeInsets.only( + margin: const EdgeInsets.only( top: defaultPadding, left: defaultPadding, right: defaultPadding), @@ -98,24 +97,29 @@ class _FeedScreenState extends State color: Colors.white, borderRadius: BorderRadius.circular(20))), ), - SizedBox( + const SizedBox( height: 10, ), Expanded( - child: SingleChildScrollView( - child: Wrap( - // to apply margin in the main axis of the wrap - runSpacing: 10, - children: [ - PostComponent( - callback: null, - ), - Container(height: 40), - CommentComponent(), - CommentComponent(), - CommentComponent(), - Container(height: 10), - ], + child: ClipRRect( + borderRadius: BorderRadius.only( + topRight: Radius.circular(15), + topLeft: Radius.circular(15)), + child: SingleChildScrollView( + child: Wrap( + // to apply margin in the main axis of the wrap + runSpacing: 10, + children: [ + const PostComponent( + callback: null, + ), + Container(height: 40), + CommentComponent(), + CommentComponent(), + CommentComponent(), + Container(height: 10), + ], + ), ), ), ), diff --git a/Sources/justMUSIC/lib/screens/profile_screen.dart b/Sources/justMUSIC/lib/screens/profile_screen.dart new file mode 100644 index 0000000..b826802 --- /dev/null +++ b/Sources/justMUSIC/lib/screens/profile_screen.dart @@ -0,0 +1,65 @@ +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:google_fonts/google_fonts.dart'; + +import '../components/profile_component.dart'; +import '../values/constants.dart'; + +class ProfileScreen extends StatefulWidget { + const ProfileScreen({Key? key}) : super(key: key); + + @override + State createState() => _ProfileScreenState(); +} + +class _ProfileScreenState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: PreferredSize( + preferredSize: Size(double.infinity, 58), + child: Container( + height: double.infinity, + color: bgAppBar, + child: Padding( + padding: const EdgeInsets.symmetric(horizontal: defaultPadding), + child: Stack( + alignment: Alignment.centerLeft, + children: [ + Image( + image: AssetImage("assets/images/return_icon.png"), + height: 11.h, + ), + Align( + child: Text( + "Profile", + style: GoogleFonts.plusJakartaSans( + color: Colors.white, + fontSize: 14, + fontWeight: FontWeight.bold), + ), + ) + ], + ), + ), + ), + ), + body: Container( + width: double.infinity, + height: double.infinity, + color: bgColor, + child: SingleChildScrollView( + child: Column( + children: [ + Padding( + padding: EdgeInsets.only(top: 68.h), + child: ProfileComponent(), + ), + ], + ), + ), + ), + ); + } +} diff --git a/Sources/justMUSIC/lib/values/constants.dart b/Sources/justMUSIC/lib/values/constants.dart index 0bc9068..e1119e3 100644 --- a/Sources/justMUSIC/lib/values/constants.dart +++ b/Sources/justMUSIC/lib/values/constants.dart @@ -15,6 +15,8 @@ const unactiveFeed = Color(0xFF848484); const gradiantPost = Color(0xFF0D0D0D); const bgModal = Color(0xFF1E1E1E); const bgComment = Color(0xFF222222); +const bgAppBar = Color(0xFF181818); +const grayText = Color(0xFF898989); // All constants important too us diff --git a/Sources/justMUSIC/pubspec.lock b/Sources/justMUSIC/pubspec.lock index 2480f6d..6addfb5 100644 --- a/Sources/justMUSIC/pubspec.lock +++ b/Sources/justMUSIC/pubspec.lock @@ -5,96 +5,84 @@ packages: dependency: transitive description: name: async - sha256: bfe67ef28df125b7dddcea62755991f807aa39a2492a23e1550161692950bbe0 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "2.10.0" + version: "2.9.0" auto_size_text: dependency: "direct main" description: name: auto_size_text - sha256: "3f5261cd3fb5f2a9ab4e2fc3fba84fd9fcaac8821f20a1d4e71f557521b22599" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "3.0.0" boolean_selector: dependency: transitive description: name: boolean_selector - sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "2.1.1" + version: "2.1.0" characters: dependency: transitive description: name: characters - sha256: e6a326c8af69605aec75ed6c187d06b349707a27fbff8222ca9cc2cff167975c - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.2.1" circular_reveal_animation: dependency: "direct main" description: name: circular_reveal_animation - sha256: "198f5a1fa27384dcf950807e0ae07a0da857c04df6233f7468755ee9db102b0c" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.0.1" clock: dependency: transitive description: name: clock - sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.1.1" collection: dependency: transitive description: name: collection - sha256: cfc915e6923fe5ce6e153b0723c753045de46de1b4d63771530504004a45fae0 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "1.17.0" + version: "1.16.0" crypto: dependency: transitive description: name: crypto - sha256: ff625774173754681d66daaf4a448684fb04b78f902da9cb3d308c19cc5e8bab - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "3.0.3" + version: "3.0.2" cupertino_icons: dependency: "direct main" description: name: cupertino_icons - sha256: e35129dc44c9118cee2a5603506d823bab99c68393879edb440e0090d07586be - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.0.5" custom_draggable_widget: dependency: "direct main" description: name: custom_draggable_widget - sha256: "15718003ebcebb84acdf0c625831a880d139a284d8de9d943ef0d0a669f10159" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "0.0.2" fake_async: dependency: transitive description: name: fake_async - sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.3.1" ffi: dependency: transitive description: name: ffi - sha256: ed5337a5660c506388a9f012be0288fb38b49020ce2b45fe1f8b8323fe429f99 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.0.2" flutter: @@ -106,24 +94,21 @@ packages: dependency: "direct dev" description: name: flutter_lints - sha256: "2118df84ef0c3ca93f96123a616ae8540879991b8b57af2f81b76a7ada49b2a4" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.0.2" flutter_screenutil: dependency: "direct main" description: name: flutter_screenutil - sha256: "0a122936b450324cbdfd51be0819cc6fcebb093eb65585e9cd92263f7a1a8a39" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "5.7.0" flutter_signin_button: dependency: "direct main" description: name: flutter_signin_button - sha256: a063ecc5d5308377e103c9c3a89084abf15fca4440636233af6a13abacd5dcae - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.0.0" flutter_test: @@ -135,168 +120,140 @@ packages: dependency: transitive description: name: font_awesome_flutter - sha256: "1f93e5799f0e6c882819e8393a05c6ca5226010f289190f2242ec19f3f0fdba5" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "9.2.0" google_fonts: dependency: "direct main" description: name: google_fonts - sha256: "6b6f10f0ce3c42f6552d1c70d2c28d764cf22bb487f50f66cca31dcd5194f4d6" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "4.0.4" gradiantbutton: dependency: "direct main" description: name: gradiantbutton - sha256: c88ac8567242630cd14231e2a6a861da4e40a02a9a0310af360e05634890d172 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "0.0.1" gradient_borders: dependency: "direct main" description: name: gradient_borders - sha256: "69eeaff519d145a4c6c213ada1abae386bcc8981a4970d923e478ce7ba19e309" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.0.0" http: dependency: transitive description: name: http - sha256: "5895291c13fa8a3bd82e76d5627f69e0d85ca6a30dcac95c4ea19a5d555879c2" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "0.13.6" + version: "0.13.5" http_parser: dependency: transitive description: name: http_parser - sha256: "2aa08ce0341cc9b354a498388e30986515406668dbcc4f7c950c3e715496693b" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "4.0.2" - js: - dependency: transitive - description: - name: js - sha256: "5528c2f391ededb7775ec1daa69e65a2d61276f7552de2b5f7b8d34ee9fd4ab7" - url: "https://pub.dev" - source: hosted - version: "0.6.5" lints: dependency: transitive description: name: lints - sha256: "5e4a9cd06d447758280a8ac2405101e0e2094d2a1dbdd3756aec3fe7775ba593" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.0.1" matcher: dependency: transitive description: name: matcher - sha256: "16db949ceee371e9b99d22f88fa3a73c4e59fd0afed0bd25fc336eb76c198b72" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "0.12.13" + version: "0.12.12" material_color_utilities: dependency: transitive description: name: material_color_utilities - sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "0.2.0" + version: "0.1.5" meta: dependency: transitive description: name: meta - sha256: "6c268b42ed578a53088d834796959e4a1814b5e9e164f147f580a386e5decf42" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.8.0" modal_bottom_sheet: dependency: "direct main" description: name: modal_bottom_sheet - sha256: ef533916a2c3089571c32bd34e410faca77a6849a3f28f748e0794525c5658a0 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.1.2" path: dependency: transitive description: name: path - sha256: db9d4f58c908a4ba5953fcee2ae317c94889433e5024c27ce74a37f94267945b - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.8.2" path_provider: dependency: transitive description: name: path_provider - sha256: "3087813781ab814e4157b172f1a11c46be20179fcc9bea043e0fba36bc0acaa2" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.0.15" path_provider_android: dependency: transitive description: name: path_provider_android - sha256: "2cec049d282c7f13c594b4a73976b0b4f2d7a1838a6dd5aaf7bd9719196bee86" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.0.27" path_provider_foundation: dependency: transitive description: name: path_provider_foundation - sha256: "916731ccbdce44d545414dd9961f26ba5fbaa74bcbb55237d8e65a623a8c7297" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.2.4" path_provider_linux: dependency: transitive description: name: path_provider_linux - sha256: ffbb8cc9ed2c9ec0e4b7a541e56fd79b138e8f47d2fb86815f15358a349b3b57 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.1.11" path_provider_platform_interface: dependency: transitive description: name: path_provider_platform_interface - sha256: "57585299a729335f1298b43245842678cb9f43a6310351b18fb577d6e33165ec" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.0.6" path_provider_windows: dependency: transitive description: name: path_provider_windows - sha256: "1cb68ba4cd3a795033de62ba1b7b4564dace301f952de6bfb3cd91b202b6ee96" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.1.7" platform: dependency: transitive description: name: platform - sha256: "4a451831508d7d6ca779f7ac6e212b4023dd5a7d08a27a63da33756410e32b76" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "3.1.0" plugin_platform_interface: dependency: transitive description: name: plugin_platform_interface - sha256: "43798d895c929056255600343db8f049921cbec94d31ec87f1dc5c16c01935dd" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "2.1.5" sky_engine: @@ -308,106 +265,93 @@ packages: dependency: "direct main" description: name: smooth_corner - sha256: "1e920cffd9644d6f51f9a99674652f8c00f2e9074b275f3edde0de1441ba78e9" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.1.0" source_span: dependency: transitive description: name: source_span - sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "1.9.1" + version: "1.9.0" stack_trace: dependency: transitive description: name: stack_trace - sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "1.11.0" + version: "1.10.0" stream_channel: dependency: transitive description: name: stream_channel - sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "2.1.1" + version: "2.1.0" string_scanner: dependency: transitive description: name: string_scanner - sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "1.2.0" + version: "1.1.1" term_glyph: dependency: transitive description: name: term_glyph - sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.2.1" test_api: dependency: transitive description: name: test_api - sha256: ad540f65f92caa91bf21dfc8ffb8c589d6e4dc0c2267818b4cc2792857706206 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "0.4.16" + version: "0.4.12" text_scroll: dependency: "direct main" description: name: text_scroll - sha256: "7869d86a6fdd725dee56bdd150216a99f0372b82fbfcac319214dbd5f36e1908" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "0.2.0" typed_data: dependency: transitive description: name: typed_data - sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.3.2" vector_math: dependency: transitive description: name: vector_math - sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted - version: "2.1.4" + version: "2.1.2" win32: dependency: transitive description: name: win32 - sha256: "5a751eddf9db89b3e5f9d50c20ab8612296e4e8db69009788d6c8b060a84191c" - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "4.1.4" xdg_directories: dependency: transitive description: name: xdg_directories - sha256: e0b1147eec179d3911f1f19b59206448f78195ca1d20514134e10641b7d7fbff - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.0.1" zoom_tap_animation: dependency: "direct main" description: name: zoom_tap_animation - sha256: d9f7a73cab65aa1546ba6886b5e21d3c8ccccb34e4e5f770301c306d4868bee0 - url: "https://pub.dev" + url: "https://pub.dartlang.org" source: hosted version: "1.1.0" sdks: - dart: ">=2.19.0 <3.0.0" + dart: ">=2.18.2 <3.0.0" flutter: ">=3.3.0"