diff --git a/daflmusic/assets/images/Logo_luancher.png b/daflmusic/assets/images/Logo_luancher.png new file mode 100644 index 0000000..2add8b2 Binary files /dev/null and b/daflmusic/assets/images/Logo_luancher.png differ diff --git a/daflmusic/assets/images/Logo_luancher_2.png b/daflmusic/assets/images/Logo_luancher_2.png new file mode 100644 index 0000000..27bafce Binary files /dev/null and b/daflmusic/assets/images/Logo_luancher_2.png differ diff --git a/daflmusic/assets/images/fav_logo.png b/daflmusic/assets/images/fav_logo.png new file mode 100644 index 0000000..6c9a7ea Binary files /dev/null and b/daflmusic/assets/images/fav_logo.png differ diff --git a/daflmusic/assets/images/new_file (2).riv b/daflmusic/assets/images/new_file (2).riv new file mode 100644 index 0000000..d6dc05f Binary files /dev/null and b/daflmusic/assets/images/new_file (2).riv differ diff --git a/daflmusic/assets/images/search_spot_animation.riv b/daflmusic/assets/images/search_spot_animation.riv new file mode 100644 index 0000000..edcef23 Binary files /dev/null and b/daflmusic/assets/images/search_spot_animation.riv differ diff --git a/daflmusic/lib/dafl_card.dart b/daflmusic/lib/dafl_card.dart deleted file mode 100644 index 7c06204..0000000 --- a/daflmusic/lib/dafl_card.dart +++ /dev/null @@ -1,36 +0,0 @@ - -import 'package:flutter/cupertino.dart'; -import 'package:flutter/material.dart'; -import 'package:flutter_swipable/flutter_swipable.dart'; - -class DaflCard extends StatelessWidget { - final color; - double taille = 0; - - DaflCard({required this.color}); - @override - Widget build(BuildContext context) { - double height = MediaQuery.of(context).size.height; - return Swipable( - onSwipeLeft: (finalposition){ - print('dislike'); - }, - onSwipeRight: (finalposition){ - print('like'); - }, - onSwipeUp: (finalposition){ - print('discovery'); - }, - child: Container( - decoration: BoxDecoration( - image: DecorationImage( - image: AssetImage( - 'assets/images/pochette.png'), - fit: BoxFit.cover, - - ), - borderRadius: BorderRadius.all(Radius.circular(20)) - ), - height: height*0.66,),); - } -} diff --git a/daflmusic/lib/discoveryPage/discoveryPage.dart b/daflmusic/lib/discoveryPage/discoveryPage.dart new file mode 100644 index 0000000..c2ddaca --- /dev/null +++ b/daflmusic/lib/discoveryPage/discoveryPage.dart @@ -0,0 +1,180 @@ +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:fluttericon/font_awesome5_icons.dart'; +import 'package:provider/provider.dart'; + +import '../main.dart'; + +class DiscoveryPage extends StatefulWidget { + const DiscoveryPage({Key? key}) : super(key: key); + + @override + State createState() => _DiscoveryPageState(); +} + +class _DiscoveryPageState extends State { + + @override + + Widget build(BuildContext context) { + double height = MediaQuery.of(context).size.height; + double width = MediaQuery.of(context).size.width; + return Scaffold( + backgroundColor: Color(0xFF141414), + resizeToAvoidBottomInset: false, + + body: Padding(padding: EdgeInsets.fromLTRB(30, 50, 30, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Container( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Row( + children: [ + Text('Playlist découverte', style: TextStyle(color: Colors.white, fontWeight: FontWeight.w500, fontSize: 25),), + Spacer(), + Icon(FontAwesome5.sort_amount_down, size: 30, color: Colors.white,), + ] + ), + Padding(padding: EdgeInsets.fromLTRB(0, 5, 0, 0)), + Text('Retrouvez ici vos nouvelles découvertes.', style: TextStyle(color: Colors.grey.withOpacity(0.4), fontSize: 15),), + ], + ), + ), + Expanded( + child: ListView( + + children: [ + SizedBox(height: 40,), + Container( + margin: EdgeInsets.fromLTRB(0, 10, 0, 0), + child: Column( + children: [ + + Container( + margin: EdgeInsets.fromLTRB(0, 5, 0, 0), + width: double.infinity, + child: Row( + children: [ + Container( + height: 60, + width: 60, + decoration: BoxDecoration( + image: DecorationImage( + image: NetworkImage('https://www.goutemesdisques.com/uploads/tx_gmdchron/pi1/L_Etrange_Histoire_de_Mr_Anderson.jpg'), + fit: BoxFit.cover, + ), + border: Border.all(width: 0, color: Colors.grey.withOpacity(0)), + borderRadius: BorderRadius.all(Radius.circular(10)), + ),), + Container( + margin: EdgeInsets.fromLTRB(20, 0, 0, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('IVERSON',style: TextStyle(fontFamily: 'DMSans', color: Colors.white.withOpacity(1) ,fontSize: 20, fontWeight: FontWeight.w800),), + Text('Laylow',style: TextStyle(fontFamily: 'DMSans', color: Colors.white.withOpacity(0.6) ,fontSize: 16, fontWeight: FontWeight.w400),), + + ], + ),), + ], + ), + ), + + + ], + ) + ), + Container( + margin: EdgeInsets.fromLTRB(0, 10, 0, 0), + child: Column( + children: [ + + Container( + margin: EdgeInsets.fromLTRB(0, 5, 0, 0), + width: double.infinity, + child: Row( + children: [ + Container( + height: 60, + width: 60, + decoration: BoxDecoration( + image: DecorationImage( + image: NetworkImage('https://www.goutemesdisques.com/uploads/tx_gmdchron/pi1/L_Etrange_Histoire_de_Mr_Anderson.jpg'), + fit: BoxFit.cover, + ), + border: Border.all(width: 0, color: Colors.grey.withOpacity(0)), + borderRadius: BorderRadius.all(Radius.circular(10)), + ),), + Container( + margin: EdgeInsets.fromLTRB(20, 0, 0, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('IVERSON',style: TextStyle(fontFamily: 'DMSans', color: Colors.white.withOpacity(1) ,fontSize: 20, fontWeight: FontWeight.w800),), + Text('Laylow',style: TextStyle(fontFamily: 'DMSans', color: Colors.white.withOpacity(0.6) ,fontSize: 16, fontWeight: FontWeight.w400),), + + ], + ),), + ], + ), + ), + + + ], + ) + ), + Container( + margin: EdgeInsets.fromLTRB(0, 10, 0, 0), + child: Column( + children: [ + + Container( + margin: EdgeInsets.fromLTRB(0, 5, 0, 0), + width: double.infinity, + child: Row( + children: [ + Container( + height: 60, + width: 60, + decoration: BoxDecoration( + image: DecorationImage( + image: NetworkImage('https://www.goutemesdisques.com/uploads/tx_gmdchron/pi1/L_Etrange_Histoire_de_Mr_Anderson.jpg'), + fit: BoxFit.cover, + ), + border: Border.all(width: 0, color: Colors.grey.withOpacity(0)), + borderRadius: BorderRadius.all(Radius.circular(10)), + ),), + Container( + margin: EdgeInsets.fromLTRB(20, 0, 0, 0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('IVERSON',style: TextStyle(fontFamily: 'DMSans', color: Colors.white.withOpacity(1) ,fontSize: 20, fontWeight: FontWeight.w800),), + Text('Laylow',style: TextStyle(fontFamily: 'DMSans', color: Colors.white.withOpacity(0.6) ,fontSize: 16, fontWeight: FontWeight.w400),), + + ], + ),), + ], + ), + ), + + + ], + ) + ), + + + ], + ), + ), + ], + ),), + ); + } +} diff --git a/daflmusic/lib/homePage/main_homepage.dart b/daflmusic/lib/homePage/main_homepage.dart index d17bc80..49ebe0b 100644 --- a/daflmusic/lib/homePage/main_homepage.dart +++ b/daflmusic/lib/homePage/main_homepage.dart @@ -17,6 +17,8 @@ class MainHomePage extends StatefulWidget { class _MainHomePage extends State { @override Widget build(BuildContext context) { + double height = MediaQuery.of(context).size.height; + double width = MediaQuery.of(context).size.width; return Scaffold( backgroundColor: Color(0xFF141414), body: Stack( @@ -37,59 +39,47 @@ class _MainHomePage extends State { 'assets/images/Logo.png', width: 200, ), - GestureDetector( - child: Container( - child: Align( - alignment: Alignment.center, - child: Text("CONTINUER AVEC SPOTIFY", - style: TextStyle(color: Colors.white ,fontSize: 17, fontWeight: FontWeight.bold), - textAlign: TextAlign.center, - ), - ), - margin: EdgeInsets.fromLTRB(60, 40, 60, 0), - height: 55, - decoration: BoxDecoration( - color: Color(0xFF24CF5F), - borderRadius: BorderRadius.all( - Radius.circular(15)), - border: Border.all( - width: 1.5, - color: Color(0xFF68F097), - ),// Set rounded corner radius - + SizedBox(height: height*0.04,), + SizedBox( + height: 55, + width: width*0.75, + child: ElevatedButton( + style: ElevatedButton.styleFrom( + backgroundColor: Color(0xFF24CF5F), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(15.0), + ),// background// foreground + ), + onPressed: () { + }, + child: Text("CONTINUER AVEC SPOTIFY", + style: TextStyle(color: Colors.white ,fontSize: 17, fontWeight: FontWeight.bold), + textAlign: TextAlign.center, + ), + ),), + SizedBox(height: height*0.015,), + SizedBox( + height: 55, + width: width*0.75, + child: ElevatedButton( + style: ElevatedButton.styleFrom( + backgroundColor: Color(0xFF5C1DC3), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(15.0), + ),// background// foreground ), - ),), - GestureDetector( - onTap: (){ - Navigator.of(context).push( - PageTransition( - duration: Duration(milliseconds: 300), + onPressed: () { + Navigator.of(context).push(PageTransition( + duration: Duration(milliseconds: 300), reverseDuration: Duration(milliseconds: 300), type: PageTransitionType.rightToLeftJoined, childCurrent: widget, child: MainSignUpPage()), - ); - }, - child: Container( - child: Align( - alignment: Alignment.center, - child: Text("S’INSCRIRE MAINTENANT", - style: TextStyle(fontFamily: 'DMSans', color: Colors.white ,fontSize: 17, fontWeight: FontWeight.w700), - textAlign: TextAlign.center, - ), - ), - margin: EdgeInsets.fromLTRB(60, 10, 60, 0), - width: double.infinity, - height: 55, - decoration: BoxDecoration( - color: Color(0xFF951DDE), - borderRadius: BorderRadius.all( - Radius.circular(15)), - border: Border.all( - width: 1.5, - color: Color(0xFFC656ED), - ),// Set rounded corner radius - + ); + }, + child: Text("S’INSCRIRE MAINTENANT", + style: TextStyle(color: Colors.white ,fontSize: 17, fontWeight: FontWeight.bold), + textAlign: TextAlign.center, ), ),), SizedBox(height: 220,), diff --git a/daflmusic/lib/main.dart b/daflmusic/lib/main.dart index 616234f..28981e4 100644 --- a/daflmusic/lib/main.dart +++ b/daflmusic/lib/main.dart @@ -1,3 +1,4 @@ +import 'dart:async'; import 'dart:math'; import 'package:daflmusic/mainPage/main_mainpage.dart'; @@ -8,6 +9,7 @@ import 'package:daflmusic/homePage/main_homepage.dart'; import 'package:daflmusic/signUpPage/main_signUp_page.dart'; import 'package:fluttertoast/fluttertoast.dart'; import 'package:provider/provider.dart'; +import 'package:rive/rive.dart'; void main() { @@ -16,6 +18,7 @@ void main() { class MyApp extends StatelessWidget { + // This widget is the root of your application. @override Widget build(BuildContext context){ @@ -63,6 +66,12 @@ class CardProvider extends ChangeNotifier{ notifyListeners(); } + void isLast(){ + if(_urlImages.length == 1){ + + } + } + void setScreenSize(Size screenSize) => _screenSize = screenSize; @@ -191,4 +200,53 @@ class CardProvider extends ChangeNotifier{ await Future.delayed(Duration(milliseconds: 200)); resetPosition(); } -} \ No newline at end of file +} + + +class Splash extends StatefulWidget { + const Splash({Key? key}) : super(key: key); + + @override + State createState() => _SplashState(); +} + +class _SplashState extends State { + + @override + void initState() { + // TODO: implement initState + super.initState(); + WidgetsBinding.instance.addPostFrameCallback((timeStamp) { + Timer(Duration(seconds: 2), () { + Navigator.pushReplacement(context, + MaterialPageRoute(builder: + (context) =>MainMainPage() + ) + ); + }); + }); + + + } + + + @override + Widget build(BuildContext context) { + return Scaffold( + backgroundColor: Color(0xFF141414), + body: Center( + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Container( + height: 300, + width: 300, + child: RiveAnimation.asset('assets/images/new_file (2).riv'), + ), + SizedBox(height: 50), + ], + ), + ), + ); + } +} diff --git a/daflmusic/lib/mainPage/main_mainpage.dart b/daflmusic/lib/mainPage/main_mainpage.dart index a47dbb9..2d26e4d 100644 --- a/daflmusic/lib/mainPage/main_mainpage.dart +++ b/daflmusic/lib/mainPage/main_mainpage.dart @@ -8,6 +8,10 @@ import 'package:daflmusic/signInPage/main_signIn_page.dart'; import 'package:daflmusic/homePage/main_homepage.dart'; import 'package:daflmusic/signUpPage/main_signUp_page.dart'; +import '../discoveryPage/discoveryPage.dart'; +import '../profilPage/MainProfilPage.dart'; +import '../profilPage/parametre_page.dart'; + class MainMainPage extends StatefulWidget { const MainMainPage({Key? key}) : super(key: key); @@ -15,24 +19,26 @@ class MainMainPage extends StatefulWidget { State createState() => _MainMainPageState(); } -class _MainMainPageState extends State { - int index = 2; +class _MainMainPageState extends State { + int _index = 2; + int get index => _index; final screens = [ - MainHomePage(), - Center(child: Text('Discovery'),), + MainProfilPage(), + DiscoveryPage(), Spots(), Center(child: Text('Tops'),), Center(child: Text('Messages'),), + ParametrePage(), ]; @override Widget build(BuildContext context) { double height = MediaQuery.of(context).size.height; return Scaffold( - body: screens[index], + body: screens[_index], bottomNavigationBar: NavigationBarTheme( data: NavigationBarThemeData( - indicatorColor: Colors.deepPurple, + indicatorColor: Color(0xFF5C1DC3), labelTextStyle: MaterialStateProperty.all( TextStyle(fontSize: 12, fontWeight: FontWeight.w400, color: Colors.grey) ), @@ -47,7 +53,7 @@ class _MainMainPageState extends State { selectedIndex: index, height: height*0.1, onDestinationSelected: (index) => - setState(() => this.index = index), + setState(() => this._index = index), backgroundColor: Color(0xFF232123), destinations: [ NavigationDestination(icon: Icon(Icons.person_outline, color: Colors.grey,), label: 'Profil', selectedIcon: Icon(Icons.person, color: Colors.white,),), diff --git a/daflmusic/lib/profilPage/MainProfilPage.dart b/daflmusic/lib/profilPage/MainProfilPage.dart new file mode 100644 index 0000000..9dcf294 --- /dev/null +++ b/daflmusic/lib/profilPage/MainProfilPage.dart @@ -0,0 +1,221 @@ + +import 'package:daflmusic/profilPage/parametre_page.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:page_transition/page_transition.dart'; + +import '../icons.dart'; +import '../widgets/spots.dart'; + +class MainProfilPage extends StatefulWidget { + const MainProfilPage({Key? key}) : super(key: key); + + @override + State createState() => _MainProfilPageState(); +} + +class _MainProfilPageState extends State { + + + @override + Widget build(BuildContext context) { + double height = MediaQuery.of(context).size.height; + double width = MediaQuery.of(context).size.width; + + return Scaffold( + backgroundColor: Color(0xFF141414), + resizeToAvoidBottomInset: false, + body: Container( + width: double.infinity, + height: double.infinity, + child: Column( + crossAxisAlignment: CrossAxisAlignment.center, + children: [ + Container( + width: double.infinity, + margin: EdgeInsets.fromLTRB(30, 50, 0, 0), + child: Text( + "Profil", + style: TextStyle(fontSize: 25, fontWeight: FontWeight.w600, color: Colors.white),), + ), + Container( + margin: EdgeInsets.fromLTRB(0, 10, 0, 40), + height: height*0.14, + width: height*0.14, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(100.0), + color: Colors.blue,border: Border.all(width: 6.0, color: Colors.white), + + ), + ), + Container( + height: 55, + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(10.0), + color: Colors.transparent, + ), + margin: EdgeInsets.fromLTRB(30, 0, 30, 0), + child: SizedBox( + height: 55, + width: double.infinity, + child: ElevatedButton( + style: ElevatedButton.styleFrom( + backgroundColor: Color(0xFFD9D9D9).withOpacity(0.08), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(10.0), + ),// background// foreground + ), + onPressed: () { + }, + child: Row( + children: [ + Image.asset('assets/images/fav_logo.png', height: 25,), + SizedBox(width: 12,), + Text("Préférences musicales", + style: TextStyle(color: Colors.white ,fontSize: 17, fontWeight: FontWeight.w400), + textAlign: TextAlign.center, + ), + Spacer(), + Icon(Icons.arrow_forward_ios, color: Colors.white.withOpacity(0.3),), + ], + ) + ),), + ), + Container( + height: 55, + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(10.0), + color: Colors.transparent, + ), + margin: EdgeInsets.fromLTRB(30, 10, 30, 0), + child: SizedBox( + height: 55, + width: double.infinity, + child: ElevatedButton( + style: ElevatedButton.styleFrom( + backgroundColor: Color(0xFFD9D9D9).withOpacity(0.08), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(10.0), + ),// background// foreground + ), + onPressed: () { + Navigator.push(context,MaterialPageRoute(builder: (context)=> Destination())); + }, + child: Row( + children: [ + Icon(Icons.remove_red_eye, color: Colors.white,size: 30,), + SizedBox(width: 12,), + Text("Aperçu de mon profil", + style: TextStyle(color: Colors.white ,fontSize: 17, fontWeight: FontWeight.w400), + textAlign: TextAlign.center, + ), + Spacer(), + Icon(Icons.arrow_forward_ios, color: Colors.white.withOpacity(0.3),), + ], + ) + ),), + ), + Container( + height: height*0.27, + width: double.infinity, + margin: EdgeInsets.fromLTRB(30, 15, 30, 0), + child: Column( + children: [ + Row( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.center, + children: [ + Icon(Icons.wifi_tethering, color: Colors.white, size: 35,), + SizedBox(width: 10,), + Text("En cours d'écoute...", + style: TextStyle(color: Colors.white ,fontSize: 17, fontWeight: FontWeight.w400), + textAlign: TextAlign.center, + ), + ], + ), + Container( + margin: EdgeInsets.fromLTRB(0, 10, 0, 0), + height: height*0.14, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(15.0), + color: Color(0xFFD9D9D9).withOpacity(0.08), + ), + child: + Row( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.center, + children: [ + Container( + margin: EdgeInsets.fromLTRB(15, 0, 0, 0), + child: ClipRRect( + borderRadius: BorderRadius.circular(15), + child: Image( + height: 90, + width: 90, + image: NetworkImage( + 'https://images.genius.com/ef4849be3da5fdb22ea9e656679be3a3.600x600x1.jpg'), + ), + ), + ), + Container( + margin: EdgeInsets.fromLTRB(12, 20, 0, 0), + child: Column( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('BAMBINA', style: TextStyle(fontSize:18, fontWeight: FontWeight.w500, color: Colors.white),), + Text('PNL', style: TextStyle(fontSize:16, fontWeight: FontWeight.w400, color: Colors.grey),), + ], + ), + ) + + ], + ), + ), + ], + ), + ), + Spacer(), + Container( + height: 55, + width: double.infinity, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(10.0), + color: Colors.transparent, + ), + margin: EdgeInsets.fromLTRB(30, 0, 30, height*0.04), + child: SizedBox( + height: 55, + width: double.infinity, + child: ElevatedButton( + style: ElevatedButton.styleFrom( + backgroundColor: Color(0xFFD9D9D9).withOpacity(0.08), + shape: RoundedRectangleBorder( + borderRadius: BorderRadius.circular(10.0), + ),// background// foreground + ), + onPressed: () { + Navigator.push(context,MaterialPageRoute(builder: (context)=> ParametrePage())); + }, + child: Row( + children: [ + Icon(Icons.settings, color: Colors.white,size: 30,), + SizedBox(width: 12,), + Text("Paramètres", + style: TextStyle(color: Colors.white ,fontSize: 17, fontWeight: FontWeight.w400), + textAlign: TextAlign.center, + ), + Spacer(), + Icon(Icons.arrow_forward_ios, color: Colors.white.withOpacity(0.3),), + ], + ) + ),), + ), + ], + ), + ), + ); + } +} diff --git a/daflmusic/lib/profilPage/parametre_page.dart b/daflmusic/lib/profilPage/parametre_page.dart new file mode 100644 index 0000000..d9aa065 --- /dev/null +++ b/daflmusic/lib/profilPage/parametre_page.dart @@ -0,0 +1,133 @@ +import 'package:daflmusic/mainPage/main_mainpage.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; + +class ParametrePage extends StatefulWidget { + const ParametrePage({Key? key}) : super(key: key); + + @override + State createState() => _ParametrePageState(); +} + +class _ParametrePageState extends State { + @override + Widget build(BuildContext context) { + double height = MediaQuery.of(context).size.height; + double width = MediaQuery.of(context).size.width; + return Scaffold( + backgroundColor: Color(0xFF141414), + resizeToAvoidBottomInset: false, + appBar: AppBar( + leading: new IconButton( + icon: new Icon(Icons.keyboard_arrow_left, color: Colors.grey.withOpacity(0.7), size: 50,), + onPressed: () => {Navigator.of(context).pop()}, + ), + backgroundColor: Colors.transparent, + elevation: 0, + ), + body: Container( + width: double.infinity, + height: double.infinity, + child: Column( + crossAxisAlignment: CrossAxisAlignment.center, + children: [ + Container( + margin: EdgeInsets.fromLTRB(30, height*0.07, 30, 0), + width: double.infinity, + height: 30, + alignment: Alignment.centerLeft, + decoration: BoxDecoration( + color: Color(0xFFD9D9D9).withOpacity(0.16), + borderRadius: BorderRadius.circular(7.0), + ), + child: Padding( + padding: EdgeInsets.fromLTRB(20, 0, 0, 0), + child: Text('Pseudo', + style: TextStyle( + color: Color(0xFFAEAEAE) + ),), + ) + ), + Padding(padding: EdgeInsets.fromLTRB(30, 0, 30, 0), + child: SizedBox( + width: width, + child: Row( + children: [ + SizedBox( + width: 230, + child: TextField( + style: TextStyle(color: Colors.white), + decoration: InputDecoration( + hintStyle: Theme.of(context).textTheme.caption?.copyWith( + color: Colors.white, + ), + border: InputBorder.none, + hintText: 'Pseudonyme', + ), + cursorColor: Colors.purple, + textAlign: TextAlign.left, + ), + ), + Spacer(), + Padding(padding: EdgeInsets.fromLTRB(0, 0, 20, 0), + child: Text('modifier', + style: TextStyle( color: Colors.blue, fontSize: 17),),), + + ], + ), + ), + ), + Container( + margin: EdgeInsets.fromLTRB(30, 0, 30, 0), + width: double.infinity, + height: 30, + alignment: Alignment.centerLeft, + decoration: BoxDecoration( + color: Color(0xFFD9D9D9).withOpacity(0.16), + borderRadius: BorderRadius.circular(7.0), + ), + child: Padding( + padding: EdgeInsets.fromLTRB(20, 0, 0, 0), + child: Text('Mot de passe', + style: TextStyle( + color: Color(0xFFAEAEAE) + ),), + ) + ), + Padding(padding: EdgeInsets.fromLTRB(30, 0, 30, 0), + child: SizedBox( + width: width, + child: Row( + children: [ + SizedBox( + width: 230, + child: TextField( + obscureText: true, + style: TextStyle(color: Colors.white), + decoration: InputDecoration( + hintStyle: Theme.of(context).textTheme.caption?.copyWith( + color: Colors.white, + ), + border: InputBorder.none, + hintText: 'Mot de passe', + ), + cursorColor: Colors.purple, + textAlign: TextAlign.left, + ), + ), + Spacer(), + Padding(padding: EdgeInsets.fromLTRB(0, 0, 20, 0), + child: Text('modifier', + style: TextStyle( color: Colors.blue, fontSize: 17),),), + + ], + ), + ), + ), + + ], + ), + ), + ); + } +} diff --git a/daflmusic/lib/signInPage/main_signIn_page.dart b/daflmusic/lib/signInPage/main_signIn_page.dart index f4f60fd..10404ee 100644 --- a/daflmusic/lib/signInPage/main_signIn_page.dart +++ b/daflmusic/lib/signInPage/main_signIn_page.dart @@ -6,6 +6,8 @@ import 'package:daflmusic/homePage/main_homepage.dart'; import 'package:daflmusic/signUpPage/main_signUp_page.dart'; import 'package:page_transition/page_transition.dart'; +import '../main.dart'; + class MainSignInPage extends StatefulWidget { const MainSignInPage({Key? key}) : super(key: key); @@ -170,7 +172,7 @@ class _MainSignInPageState extends State { PageTransition( type: PageTransitionType.fade, childCurrent: widget, - child: MainMainPage()), + child: Splash()), ); }, child:Ink( @@ -201,20 +203,24 @@ class _MainSignInPageState extends State { ), ), SizedBox(height: 100,), - Center( - child: RichText( - text: TextSpan( - text: 'Tu n’as pas de compte?', - style: TextStyle(color: Colors.white, fontWeight: FontWeight.normal, fontSize: 17), /*defining default style is optional */ - children: [ - TextSpan( - text: ' s’inscrire', - style: TextStyle(color: Color(0xFF406DE1), fontWeight: FontWeight.normal), - ), - ], - ), + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Tu n’as pas de compte?', style: TextStyle(color: Colors.white, fontWeight: FontWeight.normal, fontSize: 17)), + GestureDetector( + onTap: () { + Navigator.of(context).push( + PageTransition( + type: PageTransitionType.fade, + childCurrent: widget, + child: MainSignUpPage()), + ); + }, + child: Text(' s’inscrire', style: TextStyle(color: Color(0xFF406DE1), fontWeight: FontWeight.normal, fontSize: 16), + ), + ), + ], ), - ), SizedBox(height: 60,), ], ), diff --git a/daflmusic/lib/signUpPage/main_signUp_page.dart b/daflmusic/lib/signUpPage/main_signUp_page.dart index bcd641c..a4fdc43 100644 --- a/daflmusic/lib/signUpPage/main_signUp_page.dart +++ b/daflmusic/lib/signUpPage/main_signUp_page.dart @@ -273,19 +273,23 @@ class _MainSignUpPageState extends State { ), ), SizedBox(height: 100,), - Center( - child: RichText( - text: TextSpan( - text: 'Tu as déjà un compte ?', - style: TextStyle(fontFamily: 'DMSans', color: Colors.white, fontWeight: FontWeight.normal, fontSize: 17), /*defining default style is optional */ - children: [ - TextSpan( - text: ' se connecter', - style: TextStyle(fontFamily: 'DMSans', color: Color(0xFF406DE1), fontWeight: FontWeight.normal), - ), - ], + Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text('Tu n’as déjà un compte?', style: TextStyle(color: Colors.white, fontWeight: FontWeight.normal, fontSize: 17)), + GestureDetector( + onTap: () { + Navigator.of(context).push( + PageTransition( + type: PageTransitionType.fade, + childCurrent: widget, + child: MainSignInPage()), + ); + }, + child: Text(' se connecter', style: TextStyle(color: Color(0xFF406DE1), fontWeight: FontWeight.normal, fontSize: 16), + ), ), - ), + ], ), SizedBox(height: 60,), ], diff --git a/daflmusic/lib/widgets/DaflCard.dart b/daflmusic/lib/widgets/DaflCard.dart index 2d3b914..02912fc 100644 --- a/daflmusic/lib/widgets/DaflCard.dart +++ b/daflmusic/lib/widgets/DaflCard.dart @@ -1,6 +1,5 @@ import 'dart:math'; -import 'package:daflmusic/dafl_card.dart'; import 'package:daflmusic/main.dart'; import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; @@ -58,9 +57,9 @@ class _DaflCardState extends State{ alignment: Alignment(0,0), ), - borderRadius: BorderRadius.all(Radius.circular(20)) - ), + borderRadius: BorderRadius.all(Radius.circular(20)) ), + ), ); Widget buildStamps() { @@ -94,7 +93,7 @@ class _DaflCardState extends State{ borderRadius: BorderRadius.circular(20), child: Container( decoration: BoxDecoration( - color: Colors.black.withOpacity(0.7), + color: Colors.black.withOpacity(0.75), border: Border.all(color: Color(0xFF3F1DC3), width: 6), borderRadius: BorderRadius.all(Radius.circular(20)) diff --git a/daflmusic/lib/widgets/spots.dart b/daflmusic/lib/widgets/spots.dart index 282f089..936b1df 100644 --- a/daflmusic/lib/widgets/spots.dart +++ b/daflmusic/lib/widgets/spots.dart @@ -9,6 +9,8 @@ import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; import 'package:fluttertoast/fluttertoast.dart'; +import 'package:rive/rive.dart'; +import 'package:flutter/src/painting/gradient.dart' as gradiant; class Spots extends StatefulWidget { @@ -44,7 +46,7 @@ class _SpotsState extends State { image: DecorationImage( image: NetworkImage(provider.urlImages.isEmpty != true ?provider.urlImages.last - :"https://www.colorhexa.com/141414.png"), + :"https://i.imgur.com/Uovh293.png"), fit: BoxFit.cover, ), @@ -72,6 +74,13 @@ class _SpotsState extends State { ), ), ), + Center( + child: Container( + width: 300, + height: 300, + child: RiveAnimation.asset('assets/images/search_spot_animation.riv'), + ), + ), Positioned( top: height*0.68, width: width, @@ -82,6 +91,7 @@ class _SpotsState extends State { onTap: () { final provider = Provider.of(context, listen: false); provider.dislike(); + }, child: Image.asset( 'assets/images/bouton_dislike.png', @@ -130,23 +140,13 @@ class _SpotsState extends State { margin: EdgeInsets.fromLTRB(width*0.09,height/5,width*0.09,height/3.7), child: Container( - decoration: BoxDecoration( - boxShadow: [ - BoxShadow( - color: Colors.black.withOpacity(0.25), - spreadRadius: 2, - blurRadius: 10, - offset: Offset(0, 3), // changes position of shadow - ), - ], - ), child: buildCards(), ) ) , ), IgnorePointer(child: Container(height: 200, decoration: BoxDecoration( - gradient: LinearGradient( + gradient: gradiant.LinearGradient( colors: [Colors.black, Colors.transparent], begin: Alignment.topCenter, end: Alignment.bottomCenter, @@ -183,6 +183,8 @@ class _SpotsState extends State { } + + class Destination extends StatelessWidget{ @override Widget build(BuildContext context) { @@ -664,10 +666,11 @@ class PreviewInfo extends StatelessWidget{ double height = MediaQuery.of(context).size.height; double width = MediaQuery.of(context).size.width; return Container( - width: width/1.2, height: height*0.06, + constraints: BoxConstraints(minWidth: 300, maxWidth: 400), + margin: EdgeInsets.fromLTRB(width*0.1, 0, width*0.1, 0), decoration: BoxDecoration( - color: Color(0xFF24243A).withOpacity(0.24), + color: Color(0xFF24243A).withOpacity(0.40), border: Border.all(width: 0, color: Colors.grey.withOpacity(0)), borderRadius: BorderRadius.all(Radius.circular(15)), ), diff --git a/daflmusic/pubspec.lock b/daflmusic/pubspec.lock index 2fb5b3e..7db1933 100644 --- a/daflmusic/pubspec.lock +++ b/daflmusic/pubspec.lock @@ -8,6 +8,20 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.0.7" + archive: + dependency: transitive + description: + name: archive + url: "https://pub.dartlang.org" + source: hosted + version: "3.3.1" + args: + dependency: transitive + description: + name: args + url: "https://pub.dartlang.org" + source: hosted + version: "2.3.1" async: dependency: transitive description: @@ -29,6 +43,20 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.2.1" + checked_yaml: + dependency: transitive + description: + name: checked_yaml + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.1" + cli_util: + dependency: transitive + description: + name: cli_util + url: "https://pub.dartlang.org" + source: hosted + version: "0.3.5" clock: dependency: transitive description: @@ -43,6 +71,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.16.0" + crypto: + dependency: transitive + description: + name: crypto + url: "https://pub.dartlang.org" + source: hosted + version: "3.0.2" cupertino_icons: dependency: "direct main" description: @@ -62,6 +97,13 @@ packages: description: flutter source: sdk version: "0.0.0" + flutter_launcher_icons: + dependency: "direct dev" + description: + name: flutter_launcher_icons + url: "https://pub.dartlang.org" + source: hosted + version: "0.10.0" flutter_lints: dependency: "direct dev" description: @@ -100,6 +142,34 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "8.0.9" + graphs: + dependency: transitive + description: + name: graphs + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.0" + http: + dependency: transitive + description: + name: http + url: "https://pub.dartlang.org" + source: hosted + version: "0.13.5" + http_parser: + dependency: transitive + description: + name: http_parser + url: "https://pub.dartlang.org" + source: hosted + version: "4.0.1" + image: + dependency: transitive + description: + name: image + url: "https://pub.dartlang.org" + source: hosted + version: "3.2.0" js: dependency: transitive description: @@ -107,6 +177,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "0.6.4" + json_annotation: + dependency: transitive + description: + name: json_annotation + url: "https://pub.dartlang.org" + source: hosted + version: "4.7.0" lints: dependency: transitive description: @@ -156,13 +233,27 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.8.2" + petitparser: + dependency: transitive + description: + name: petitparser + url: "https://pub.dartlang.org" + source: hosted + version: "5.0.0" provider: dependency: "direct main" description: name: provider url: "https://pub.dartlang.org" source: hosted - version: "6.0.3" + version: "6.0.4" + rive: + dependency: "direct main" + description: + name: rive + url: "https://pub.dartlang.org" + source: hosted + version: "0.9.1" sky_engine: dependency: transitive description: flutter @@ -210,6 +301,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "0.4.12" + typed_data: + dependency: transitive + description: + name: typed_data + url: "https://pub.dartlang.org" + source: hosted + version: "1.3.1" vector_math: dependency: transitive description: @@ -217,6 +315,20 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.1.2" + xml: + dependency: transitive + description: + name: xml + url: "https://pub.dartlang.org" + source: hosted + version: "6.1.0" + yaml: + dependency: transitive + description: + name: yaml + url: "https://pub.dartlang.org" + source: hosted + version: "3.1.1" sdks: dart: ">=2.18.2 <3.0.0" flutter: ">=3.0.0" diff --git a/daflmusic/pubspec.yaml b/daflmusic/pubspec.yaml index 461b9a4..662bc32 100644 --- a/daflmusic/pubspec.yaml +++ b/daflmusic/pubspec.yaml @@ -45,6 +45,8 @@ dependencies: flutter_swipable: ^1.0.0 provider: ^6.0.1 fluttertoast: ^8.0.9 + rive: ^0.9.1 + dev_dependencies: @@ -52,6 +54,13 @@ dev_dependencies: sdk: flutter flutter_lints: ^2.0.0 + flutter_launcher_icons: ^0.10.0 + +flutter_icons: + android: true + ios: true + image_path: "assets/images/Logo_luancher_2.png" + flutter: