Compare commits

..

No commits in common. 'master' and 'fix/fix-issues' have entirely different histories.

@ -7,28 +7,14 @@ trigger:
- push - push
steps: steps:
- name: app-build # - name: app-build
image: ghcr.io/cirruslabs/flutter:3.13.9 # image: cirrusci/flutter:stable
commands: # commands:
- cd ./Sources/justMUSIC/ # - cd ./Sources/justMUSIC/
- flutter build apk # - flutter build apk
- name: build-web
image: ghcr.io/cirruslabs/flutter:3.13.9
environment:
FIREBASE_TOKEN:
from_secret: FIREBASE_TOKEN
commands:
- cd ./Sources/justMUSIC/
- flutter build web --web-renderer canvaskit
- curl -sL https://firebase.tools | bash
- firebase deploy --token $${FIREBASE_TOKEN}
when:
branch:
- PROD-WEB
- name: code-analysis - name: code-analysis
image: ghcr.io/cirruslabs/flutter:3.13.9 image: cirrusci/flutter:stable
environment: environment:
SONAR_TOKEN: SONAR_TOKEN:
from_secret: SONAR_TOKEN from_secret: SONAR_TOKEN
@ -40,4 +26,3 @@ steps:
- export PATH=$SONAR_SCANNER_HOME/bin:$PATH - export PATH=$SONAR_SCANNER_HOME/bin:$PATH
- export SONAR_SCANNER_OPTS="-server" - export SONAR_SCANNER_OPTS="-server"
- sonar-scanner -D sonar.projectKey=JustMusic -D sonar.sources=./Sources/justMUSIC -D sonar.host.url=https://codefirst.iut.uca.fr/sonar - sonar-scanner -D sonar.projectKey=JustMusic -D sonar.sources=./Sources/justMUSIC -D sonar.host.url=https://codefirst.iut.uca.fr/sonar
ddepends_on: [app-build]

Binary file not shown.

Before

Width:  |  Height:  |  Size: 162 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 844 KiB

@ -33,15 +33,13 @@ JustMusic est un projet collaboratif à but lucratif pour Android/IOS utilisant
C'est un réseau social donc l'utilisateur pourra publier et commenter des posts. Il pourra s'abonner à d'autre utilisateurs pour voir leurs post sur son fil d'actualité. C'est un réseau social donc l'utilisateur pourra publier et commenter des posts. Il pourra s'abonner à d'autre utilisateurs pour voir leurs post sur son fil d'actualité.
**Lien pour tester la version web:** [Just Music](https://justmusic-435d5.web.app) 🎶
## Répartition du Gitlab ## Répartition du Gitlab
La racine de notre gitlab est composé de deux dossier essentielles au projet: La racine de notre gitlab est composé de deux dossier essentielles au projet:
[**Sources**](Sources) : **Code de l'application** [**src**](src) : **Code de l'application**
[**Documentation**](Documentation) : **Regroupe l'entièreté de la documentation** [**doc**](doc) : **Regroupe l'entièreté de la documentation**
</br> </br>
@ -49,33 +47,10 @@ La racine de notre gitlab est composé de deux dossier essentielles au projet:
## Fonctionnement ## Fonctionnement
<div align = center>
<img src="Documentation/Images/Overview.png" />
</div>
### Feeds
Une fois authentifié vous aurez la possibilité de voir les posts capsules de vos amis, de voir les musiques qu'ils mettent en avant accompagner éventuellement d'une image, d'une description, de leurs localisations... (Vous n'avez pas d'amis, pas de soucis, cliquer seulement sur l'icon en haut a gauche de la page pour suivre nimporte quel personne que vous voulez), Mais aussi juste d'un simple mouvement du doigt swiper pour vous retrouvez sur la page Discovery où vous verrais les posts récents en tendance dans le monde 🌎
Amuser vous à cliquer sur les posts pour ecouter la music mais aussi connaître les détails et savoir qui a commenter 💬 et liker ❤️. Si la musique vous plaît enregistrer la et vous la retrouverez lorsque vous aurez envie de poster.
### Post
Pour participer à cette aventure musicale avec des gens du monde entier, cliquez simplement sur l'icône JustMusic. Gardez à l'esprit que vous ne pourrez poster qu'une fois par jour, donc réfléchissez bien à la musique que vous souhaitez mettre en avant. N'hésitez pas à ajouter une photo et une description pour rendre votre publication plus chaleureuse 😃.
### Profil
Consultez l'aperçu de votre profil pour savoir combien de personnes vous suivent et que vous suivez. Vous pouvez également voir le nombre de capsules que vous avez publiées, personnaliser les paramètres de votre compte selon vos préférences, et explorez votre historique de capsules pour vous remémorer vos précédentes publications 🎧.
#### Bonne aventure musicale 🎵🌟
## Deploiement ## Deploiement
- [x] &nbsp; ![IOS](https://img.shields.io/badge/IOS-000?style=for-the-badge&logo=apple&logoColor=black&color=white) - [x] &nbsp; ![IOS](https://img.shields.io/badge/IOS-000?style=for-the-badge&logo=apple&logoColor=black&color=white)
- [x] &nbsp; ![Android](https://img.shields.io/badge/Android-000?style=for-the-badge&logo=android&logoColor=white&color=green) - [x] &nbsp; ![Android](https://img.shields.io/badge/Android-000?style=for-the-badge&logo=android&logoColor=white&color=green)
- [x] &nbsp; ![Safari](https://img.shields.io/badge/Safari-000000.svg?style=for-the-badge&logo=Safari&logoColor=white)
## Techniciens ## Techniciens
@ -87,7 +62,7 @@ Consultez l'aperçu de votre profil pour savoir combien de personnes vous suiven
<img src ="https://codefirst.iut.uca.fr/git/avatars/1ff65c9c5ab0e8c8883fb48adbcf972f?size=870" height="50px"> <img src ="https://codefirst.iut.uca.fr/git/avatars/1ff65c9c5ab0e8c8883fb48adbcf972f?size=870" height="50px">
</a> </a>
<a href = "https://codefirst.iut.uca.fr/git/david.d_almeida"> <a href = "https://codefirst.iut.uca.fr/git/david.d_almeida">
<img src ="https://codefirst.iut.uca.fr/git/avatars/a16fa2dc52ceae18d8923c91121caa66?size=870" height="50px"> <img src ="https://codefirst.iut.uca.fr/git/avatars/0f8eaaad1e26d3de644ca522eccaea7c?size=870" height="50px">
</a> </a>
<a href = "https://codefirst.iut.uca.fr/git/rayhan.hassou"> <a href = "https://codefirst.iut.uca.fr/git/rayhan.hassou">
<img src ="https://codefirst.iut.uca.fr/git/avatars/84062b2bb326d9e9154a9859b375e599?size=870" height="50px"> <img src ="https://codefirst.iut.uca.fr/git/avatars/84062b2bb326d9e9154a9859b375e599?size=870" height="50px">

@ -1,5 +0,0 @@
{
"projects": {
"default": "justmusic-435d5"
}
}

@ -4,7 +4,7 @@
# This file should be version controlled and should not be manually edited. # This file should be version controlled and should not be manually edited.
version: version:
revision: "db7ef5bf9f59442b0e200a90587e8fa5e0c6336a" revision: "2524052335ec76bb03e04ede244b071f1b86d190"
channel: "stable" channel: "stable"
project_type: app project_type: app
@ -13,26 +13,11 @@ project_type: app
migration: migration:
platforms: platforms:
- platform: root - platform: root
create_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a create_revision: 2524052335ec76bb03e04ede244b071f1b86d190
base_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a base_revision: 2524052335ec76bb03e04ede244b071f1b86d190
- platform: android
create_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
base_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
- platform: ios - platform: ios
create_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a create_revision: 2524052335ec76bb03e04ede244b071f1b86d190
base_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a base_revision: 2524052335ec76bb03e04ede244b071f1b86d190
- platform: linux
create_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
base_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
- platform: macos
create_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
base_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
- platform: web
create_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
base_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
- platform: windows
create_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
base_revision: db7ef5bf9f59442b0e200a90587e8fa5e0c6336a
# User provided section # User provided section

@ -3,7 +3,7 @@ package="com.justdev.justmusic">
<application <application
android:label="JustMUSIC" android:label="JustMUSIC"
android:name="${applicationName}" android:name="${applicationName}"
android:icon="@mipmap/ic_launcher"> android:icon="@mipmap/launcher_icon">
<activity <activity
android:name=".MainActivity" android:name=".MainActivity"

@ -1,17 +0,0 @@
{
"hosting": {
"site": "justmusic-435d5",
"public": "build/web",
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
],
"rewrites": [
{
"source": "**",
"destination": "/index.html"
}
]
}
}

@ -1,5 +1,5 @@
# Uncomment this line to define a global platform for your project # Uncomment this line to define a global platform for your project
platform :ios, '11.0' # platform :ios, '11.0'
# CocoaPods analytics sends network stats synchronously affecting flutter build latency. # CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true' ENV['COCOAPODS_DISABLE_STATS'] = 'true'

@ -953,6 +953,6 @@ SPEC CHECKSUMS:
PromisesObjC: c50d2056b5253dadbd6c2bea79b0674bd5a52fa4 PromisesObjC: c50d2056b5253dadbd6c2bea79b0674bd5a52fa4
sqflite: 31f7eba61e3074736dff8807a9b41581e4f7f15a sqflite: 31f7eba61e3074736dff8807a9b41581e4f7f15a
PODFILE CHECKSUM: 6b9eb94e9f98a329f2ef624b852a6e42d090af2b PODFILE CHECKSUM: 70d9d25280d0dd177a5f637cdb0f0b0b12c6a189
COCOAPODS: 1.14.3 COCOAPODS: 1.14.3

@ -15,7 +15,6 @@
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
C95EC3D52B114F7D00A316A2 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = C95EC3D42B114F7D00A316A2 /* GoogleService-Info.plist */; };
DE887488687930BD9A821E09 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 895D1BE06AED43E6E7367693 /* Pods_Runner.framework */; }; DE887488687930BD9A821E09 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 895D1BE06AED43E6E7367693 /* Pods_Runner.framework */; };
/* End PBXBuildFile section */ /* End PBXBuildFile section */
@ -65,7 +64,6 @@
97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; }; 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; }; 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
C7930A860EC8743E6A941D8D /* Pods_RunnerTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_RunnerTests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; C7930A860EC8743E6A941D8D /* Pods_RunnerTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_RunnerTests.framework; sourceTree = BUILT_PRODUCTS_DIR; };
C95EC3D42B114F7D00A316A2 /* GoogleService-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = "<group>"; };
F782B307897A4B77B59D0897 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; }; F782B307897A4B77B59D0897 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };
/* End PBXFileReference section */ /* End PBXFileReference section */
@ -132,7 +130,6 @@
97C146F01CF9000F007C117D /* Runner */ = { 97C146F01CF9000F007C117D /* Runner */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
C95EC3D42B114F7D00A316A2 /* GoogleService-Info.plist */,
97C146FA1CF9000F007C117D /* Main.storyboard */, 97C146FA1CF9000F007C117D /* Main.storyboard */,
97C146FD1CF9000F007C117D /* Assets.xcassets */, 97C146FD1CF9000F007C117D /* Assets.xcassets */,
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
@ -266,7 +263,6 @@
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
C95EC3D52B114F7D00A316A2 /* GoogleService-Info.plist in Resources */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
}; };

@ -1,5 +1,6 @@
import UIKit import UIKit
import Flutter import Flutter
import FirebaseCore
@UIApplicationMain @UIApplicationMain
@objc class AppDelegate: FlutterAppDelegate { @objc class AppDelegate: FlutterAppDelegate {

@ -1,36 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CLIENT_ID</key>
<string>994903990520-n6jd98ena56kb1tvtrd67tvb5et3nfbf.apps.googleusercontent.com</string>
<key>REVERSED_CLIENT_ID</key>
<string>com.googleusercontent.apps.994903990520-n6jd98ena56kb1tvtrd67tvb5et3nfbf</string>
<key>ANDROID_CLIENT_ID</key>
<string>994903990520-073l30b0afj0uq7apsvc8p8ukantpu6q.apps.googleusercontent.com</string>
<key>API_KEY</key>
<string>AIzaSyBbYqsR6t7JTi8_XFNEHd43IRuKlYGeI3U</string>
<key>GCM_SENDER_ID</key>
<string>994903990520</string>
<key>PLIST_VERSION</key>
<string>1</string>
<key>BUNDLE_ID</key>
<string>com.example.justmusic</string>
<key>PROJECT_ID</key>
<string>justmusic-435d5</string>
<key>STORAGE_BUCKET</key>
<string>justmusic-435d5.appspot.com</string>
<key>IS_ADS_ENABLED</key>
<false></false>
<key>IS_ANALYTICS_ENABLED</key>
<false></false>
<key>IS_APPINVITE_ENABLED</key>
<true></true>
<key>IS_GCM_ENABLED</key>
<true></true>
<key>IS_SIGNIN_ENABLED</key>
<true></true>
<key>GOOGLE_APP_ID</key>
<string>1:994903990520:ios:93188f32e320babe0a9b0d</string>
</dict>
</plist>

@ -22,17 +22,6 @@
<string>$(FLUTTER_BUILD_NAME)</string> <string>$(FLUTTER_BUILD_NAME)</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>CFBundleURLSchemes</key>
<array>
<string>com.googleusercontent.apps.994903990520-n6jd98ena56kb1tvtrd67tvb5et3nfbf</string>
</array>
</dict>
</array>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>$(FLUTTER_BUILD_NUMBER)</string> <string>$(FLUTTER_BUILD_NUMBER)</string>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import '../values/constants.dart'; import '../values/constants.dart';

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:ionicons/ionicons.dart'; import 'package:ionicons/ionicons.dart';
import 'package:tuple/tuple.dart'; import 'package:tuple/tuple.dart';

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import '../main.dart'; import '../main.dart';
import '../model/Music.dart'; import '../model/Music.dart';

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:justmusic/values/constants.dart'; import 'package:justmusic/values/constants.dart';
import 'package:tuple/tuple.dart'; import 'package:tuple/tuple.dart';

@ -1,9 +1,7 @@
import 'dart:io'; import 'dart:io';
import 'package:animated_appear/animated_appear.dart'; import 'package:animated_appear/animated_appear.dart';
import 'package:auto_size_text/auto_size_text.dart'; import 'package:auto_size_text/auto_size_text.dart';
import 'package:firebase_storage/firebase_storage.dart'; import 'package:flutter/Material.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
@ -62,7 +60,6 @@ class _EditablePostComponentState extends State<EditablePostComponent> with Tick
} }
Future pickImage(ImageSource source) async { Future pickImage(ImageSource source) async {
try { try {
final image = await ImagePicker().pickImage(source: source, imageQuality: 20); final image = await ImagePicker().pickImage(source: source, imageQuality: 20);
if (image == null) return; if (image == null) return;
@ -74,7 +71,6 @@ class _EditablePostComponentState extends State<EditablePostComponent> with Tick
} on PlatformException catch (e) { } on PlatformException catch (e) {
print('Failed to pick image: $e'); print('Failed to pick image: $e');
} }
} }
void _updateDescription(String text) { void _updateDescription(String text) {
@ -185,10 +181,7 @@ class _EditablePostComponentState extends State<EditablePostComponent> with Tick
borderRadius: BorderRadius.circular(20), borderRadius: BorderRadius.circular(20),
child: InstaImageViewer( child: InstaImageViewer(
backgroundIsTransparent: true, backgroundIsTransparent: true,
child: kIsWeb?InstaImageViewer( child: Image(
backgroundIsTransparent: true,
child: Image.network(image!.path)
):Image(
image: FileImage(image!), image: FileImage(image!),
fit: BoxFit.cover, fit: BoxFit.cover,
), ),
@ -256,8 +249,8 @@ class _EditablePostComponentState extends State<EditablePostComponent> with Tick
width: double.infinity, width: double.infinity,
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [ kIsWeb?Container() children: [
:Expanded( Expanded(
flex: 5, flex: 5,
child: GestureDetector( child: GestureDetector(
onTap: () { onTap: () {
@ -268,7 +261,7 @@ class _EditablePostComponentState extends State<EditablePostComponent> with Tick
), ),
), ),
), ),
kIsWeb?Container():SizedBox( SizedBox(
width: 15, width: 15,
), ),
Expanded( Expanded(

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:justmusic/main.dart'; import 'package:justmusic/main.dart';
@ -34,9 +34,7 @@ class _HistoricComponentState extends State<HistoricComponent> {
.getHistoryCapsulesMonthWhitIdUser(MyApp.userViewModel.userCurrent.id, widget.month, widget.year), .getHistoryCapsulesMonthWhitIdUser(MyApp.userViewModel.userCurrent.id, widget.month, widget.year),
builder: (context, snapshot) { builder: (context, snapshot) {
if (snapshot.hasData) { if (snapshot.hasData) {
return Container( return Wrap(
constraints: const BoxConstraints( maxWidth: 600),
child: Wrap(
spacing: 14, spacing: 14,
runSpacing: 14, runSpacing: 14,
children: List.generate(getNumberOfDaysInMonth(widget.year, widget.month), (index) { children: List.generate(getNumberOfDaysInMonth(widget.year, widget.month), (index) {
@ -65,19 +63,13 @@ class _HistoricComponentState extends State<HistoricComponent> {
); );
} }
if (checkCapsule != null) { if (checkCapsule != null) {
return Tooltip( return Container(
message: "${checkCapsule.item2.artists.first.name} - ${checkCapsule.item2.title}".length < 30? "${checkCapsule.item2.artists.first.name} - ${checkCapsule.item2.title}": "${checkCapsule.item2.artists.first.name} - ${checkCapsule.item2.title}".substring(0,30)+"...",
decoration: const BoxDecoration(
border: Border.fromBorderSide(BorderSide(color: Color(0xFF3A3A3A), width: 1)),
color: tooltipBackground, borderRadius: BorderRadius.all(Radius.circular(20))
),
child: Container(
decoration: BoxDecoration( decoration: BoxDecoration(
image: DecorationImage(image: NetworkImage((checkCapsule.item2.cover)!)), image: DecorationImage(image: NetworkImage((checkCapsule.item2.cover)!)),
borderRadius: BorderRadius.circular(5)), borderRadius: BorderRadius.circular(5)),
height: 60, height: 60,
width: 60, width: 60,
)); );
} else { } else {
return Container( return Container(
color: bgColor, color: bgColor,
@ -95,7 +87,6 @@ class _HistoricComponentState extends State<HistoricComponent> {
// Generate widgets // Generate widgets
}), }),
),
); );
} else { } else {
return CupertinoActivityIndicator(); return CupertinoActivityIndicator();

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import '../values/constants.dart'; import '../values/constants.dart';

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:justmusic/components/play_button_component.dart'; import 'package:justmusic/components/play_button_component.dart';
import 'package:text_scroll/text_scroll.dart'; import 'package:text_scroll/text_scroll.dart';

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:flutter_animated_play_button/flutter_animated_play_button.dart'; import 'package:flutter_animated_play_button/flutter_animated_play_button.dart';
import 'package:ionicons/ionicons.dart'; import 'package:ionicons/ionicons.dart';

@ -1,6 +1,6 @@
import 'dart:ui'; import 'dart:ui';
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
class PostButtonComponent extends StatefulWidget { class PostButtonComponent extends StatefulWidget {

@ -152,8 +152,10 @@ class _PostComponentState extends State<PostComponent> with TickerProviderStateM
children: [ children: [
SizedBox( SizedBox(
width: double.infinity, width: double.infinity,
child: Image.network( child: FadeInImage.assetNetwork(
widget.post.music.cover!, image: widget.post.music.cover!,
fadeInDuration: const Duration(milliseconds: 100),
placeholder: "assets/images/loadingPlaceholder.gif",
), ),
), ),
Image( Image(
@ -194,9 +196,11 @@ class _PostComponentState extends State<PostComponent> with TickerProviderStateM
child: ClipRRect( child: ClipRRect(
borderRadius: BorderRadius.circular(13), borderRadius: BorderRadius.circular(13),
// implement image // implement image
child: Image.network( child: FadeInImage.assetNetwork(
widget.post.selfie!, image: widget.post.selfie!,
fit: BoxFit.cover, fit: BoxFit.cover,
fadeInDuration: const Duration(milliseconds: 100),
placeholder: "assets/images/loadingPlaceholder.gif",
), ),
), ),
), ),

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import '../config/routes.dart'; import '../config/routes.dart';
import '../model/User.dart'; import '../model/User.dart';

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:justmusic/components/profil_picture_component.dart'; import 'package:justmusic/components/profil_picture_component.dart';

@ -1,4 +1,5 @@
import 'package:flutter/material.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/Material.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import '../main.dart'; import '../main.dart';
import '../model/User.dart' as justMusic; import '../model/User.dart' as justMusic;

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import '../values/constants.dart'; import '../values/constants.dart';

@ -136,7 +136,7 @@ class _TopNavBarComponentState extends State<TopNavBarComponent> with TickerProv
Widget build(BuildContext context) { Widget build(BuildContext context) {
choice = widget.choice; choice = widget.choice;
return SafeArea(top:true,child: Container( return SafeArea(top:true,child: Container(
padding: EdgeInsets.symmetric(horizontal: defaultPadding, vertical: 20), padding: EdgeInsets.symmetric(horizontal: defaultPadding),
width: double.infinity, width: double.infinity,
height: 100, height: 100,
child: Row( child: Row(

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:justmusic/screens/add_friend_screen.dart'; import 'package:justmusic/screens/add_friend_screen.dart';
import 'package:justmusic/screens/capsule_historic_screen.dart'; import 'package:justmusic/screens/capsule_historic_screen.dart';
import 'package:justmusic/screens/change_password_screen.dart'; import 'package:justmusic/screens/change_password_screen.dart';

@ -5,7 +5,6 @@ import 'package:firebase_auth/firebase_auth.dart';
import 'package:firebase_core/firebase_core.dart'; import 'package:firebase_core/firebase_core.dart';
import 'package:firebase_messaging/firebase_messaging.dart'; import 'package:firebase_messaging/firebase_messaging.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
@ -20,7 +19,6 @@ import 'package:justmusic/screens/profile_screen.dart';
import 'package:justmusic/screens/registration_screen.dart'; import 'package:justmusic/screens/registration_screen.dart';
import 'package:justmusic/screens/verify_email_screen.dart'; import 'package:justmusic/screens/verify_email_screen.dart';
import 'package:justmusic/screens/welcome_screen.dart'; import 'package:justmusic/screens/welcome_screen.dart';
import 'package:justmusic/values/constants.dart';
import 'package:justmusic/view_model/CommentViewModel.dart'; import 'package:justmusic/view_model/CommentViewModel.dart';
import 'package:justmusic/view_model/MusicViewModel.dart'; import 'package:justmusic/view_model/MusicViewModel.dart';
import 'package:justmusic/view_model/PostViewModel.dart'; import 'package:justmusic/view_model/PostViewModel.dart';
@ -28,8 +26,9 @@ import 'package:justmusic/view_model/UserViewModel.dart';
import 'package:justmusic/model/User.dart' as userJustMusic; import 'package:justmusic/model/User.dart' as userJustMusic;
import 'firebase_options.dart'; import 'firebase_options.dart';
import 'package:timezone/data/latest.dart' as tz; import 'package:timezone/data/latest.dart' as tz;
import 'package:flutter/material.dart';
import 'package:intl/intl.dart';
import 'package:intl/date_symbol_data_local.dart'; import 'package:intl/date_symbol_data_local.dart';
import 'package:fullscreen_window/fullscreen_window.dart';
Future<void> main() async { Future<void> main() async {
tz.initializeTimeZones(); tz.initializeTimeZones();
@ -40,9 +39,7 @@ Future<void> main() async {
options: DefaultFirebaseOptions.currentPlatform, options: DefaultFirebaseOptions.currentPlatform,
); );
await initializeDateFormatting('fr_FR', null); await initializeDateFormatting('fr_FR', null);
if (!kIsWeb) {
await FirebaseMessaging.instance.requestPermission(sound: true); await FirebaseMessaging.instance.requestPermission(sound: true);
}
runApp(const MyApp()); runApp(const MyApp());
} }
@ -66,7 +63,6 @@ class _MyAppState extends State<MyApp> {
@override @override
void initState() { void initState() {
FullScreenWindow.setFullScreen(true); // enter fullscreen
super.initState(); super.initState();
} }
@ -80,13 +76,12 @@ class _MyAppState extends State<MyApp> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
SystemChrome.setEnabledSystemUIMode(SystemUiMode.immersiveSticky); SystemChrome.setEnabledSystemUIMode(SystemUiMode.immersiveSticky);
Paint.enableDithering = true; // enter fullscreen Paint.enableDithering = true;
return ScreenUtilInit( return ScreenUtilInit(
useInheritedMediaQuery: true, useInheritedMediaQuery: true,
builder: (context, child) { builder: (context, child) {
return MaterialApp( return MaterialApp(
color: bgColor,
routes: { routes: {
'/welcome': (context) => const WellcomeScreen(), '/welcome': (context) => const WellcomeScreen(),
'/feed': (context) => const FeedScreen(), '/feed': (context) => const FeedScreen(),
@ -121,7 +116,7 @@ class _MyAppState extends State<MyApp> {
MyApp.userViewModel.userCurrent = userSnapshot.data!; MyApp.userViewModel.userCurrent = userSnapshot.data!;
return FeedScreen(); return FeedScreen();
} else { } else {
return WellcomeScreen(); return const Text('User data not found');
} }
} }
}, },

@ -1,34 +0,0 @@
import 'package:tuple/tuple.dart';
import 'Music.dart';
class Capsule {
final String _id;
late Music _music;
Tuple2<String?,String?> _location;
DateTime _date;
// Constructor
Capsule(this._id, this._location, this._date);
//Getters and setters
String get id => _id;
Music get music => _music;
set music(Music value) {
_music = value;
}
Tuple2<String?, String?> get location => _location;
set location(Tuple2<String?, String?> value) {
_location = value;
}
DateTime get date => _date;
set date(DateTime value) {
_date = value;
}
}

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:justmusic/values/constants.dart'; import 'package:justmusic/values/constants.dart';

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import '../components/historic_component.dart'; import '../components/historic_component.dart';
@ -77,9 +77,8 @@ class _CapsuleHistoricScreenState extends State<CapsuleHistoricScreen> {
mainAxisAlignment: MainAxisAlignment.center, mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center, crossAxisAlignment: CrossAxisAlignment.center,
children: [ children: [
Container( Padding(
padding: const EdgeInsets.only(top: 80, left: 30, right: 30), padding: const EdgeInsets.only(top: 80, left: 60, right: 60),
constraints: const BoxConstraints( maxWidth: 700),
child: Align( child: Align(
alignment: Alignment.center, alignment: Alignment.center,
child: Row( child: Row(
@ -131,6 +130,8 @@ class _CapsuleHistoricScreenState extends State<CapsuleHistoricScreen> {
child: SizedBox( child: SizedBox(
width: double.infinity, width: double.infinity,
child: Container( child: Container(
padding: EdgeInsets.symmetric(horizontal: 15),
constraints: BoxConstraints(maxWidth: 600),
child: Column( child: Column(
children: [ children: [
HistoricComponent( HistoricComponent(

@ -1,6 +1,6 @@
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:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';

@ -1,5 +1,5 @@
import 'dart:async'; import 'dart:async';
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
@ -612,7 +612,6 @@ class _DetailPostScreenState extends State<DetailPostScreen> {
Expanded( Expanded(
child: TextField( child: TextField(
keyboardAppearance: Brightness.dark, keyboardAppearance: Brightness.dark,
keyboardType: TextInputType.text,
controller: _textController, controller: _textController,
focusNode: myFocusNode, focusNode: myFocusNode,
onSubmitted: (value) async { onSubmitted: (value) async {
@ -627,6 +626,7 @@ class _DetailPostScreenState extends State<DetailPostScreen> {
setState(() {}); setState(() {});
}, },
cursorColor: primaryColor, cursorColor: primaryColor,
keyboardType: TextInputType.emailAddress,
style: GoogleFonts.plusJakartaSans(color: Colors.white), style: GoogleFonts.plusJakartaSans(color: Colors.white),
decoration: InputDecoration( decoration: InputDecoration(
suffixIcon: _textController.text.isEmpty suffixIcon: _textController.text.isEmpty

@ -25,15 +25,13 @@ class _FeedScreenState extends State<FeedScreen> with SingleTickerProviderStateM
late Animation<double> animation; late Animation<double> animation;
late List<Post> friendFeed; late List<Post> friendFeed;
Timer? timer; Timer? timer;
var pageFriend = 0;
late List<Post> discoveryFeed; late List<Post> discoveryFeed;
late Tuple2<List<Post>, List<Post>> displayFeed; late Tuple2<List<Post>, List<Post>> displayFeed;
bool isDismissed = true; bool isDismissed = true;
bool choiceFeed = true; bool choiceFeed = true;
PageController controller = PageController(); PageController controller = PageController();
@override @override
void initState() { void initState() {
super.initState(); super.initState();
@ -126,26 +124,9 @@ class _FeedScreenState extends State<FeedScreen> with SingleTickerProviderStateM
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
displayFeed = displayFeed =
Tuple2(MyApp.postViewModel.postsFriends.toList(), MyApp.postViewModel.bestPosts.toList()); Tuple2(MyApp.postViewModel.postsFriends.reversed.toList(), MyApp.postViewModel.bestPosts.reversed.toList());
bool empty = bool empty =
(choiceFeed == true && displayFeed.item1.isEmpty) || (choiceFeed == false && displayFeed.item2.isEmpty); (choiceFeed == true && displayFeed.item1.isEmpty) || (choiceFeed == false && displayFeed.item2.isEmpty);
ScrollController _scrollController = ScrollController();
_scrollController.addListener(() {
if (_scrollController.position.maxScrollExtent ==
_scrollController.position.pixels) {
print("fin");
if (choiceFeed) {
setState(() {
MyApp.postViewModel.getMorePostsFriends();
});
} else {
setState(() {
MyApp.postViewModel.getMoreBestPosts();
});
}
}
});
return Scaffold( return Scaffold(
resizeToAvoidBottomInset: false, resizeToAvoidBottomInset: false,
backgroundColor: bgColor, backgroundColor: bgColor,
@ -204,7 +185,6 @@ class _FeedScreenState extends State<FeedScreen> with SingleTickerProviderStateM
physics: const BouncingScrollPhysics(parent: AlwaysScrollableScrollPhysics()), physics: const BouncingScrollPhysics(parent: AlwaysScrollableScrollPhysics()),
clipBehavior: Clip.none, clipBehavior: Clip.none,
shrinkWrap: false, shrinkWrap: false,
controller: _scrollController,
itemCount: displayFeed.item1.length, itemCount: displayFeed.item1.length,
itemBuilder: (BuildContext context, int index) { itemBuilder: (BuildContext context, int index) {
return Padding( return Padding(
@ -213,7 +193,6 @@ class _FeedScreenState extends State<FeedScreen> with SingleTickerProviderStateM
PostComponent(callback: openDetailPost, post: displayFeed.item1[index], index: index), PostComponent(callback: openDetailPost, post: displayFeed.item1[index], index: index),
); );
}, },
), ),
), ),
), ),
@ -233,7 +212,6 @@ class _FeedScreenState extends State<FeedScreen> with SingleTickerProviderStateM
triggerMode: RefreshIndicatorTriggerMode.onEdge, triggerMode: RefreshIndicatorTriggerMode.onEdge,
onRefresh: _refresh, onRefresh: _refresh,
child: ListView.builder( child: ListView.builder(
controller: _scrollController,
physics: const BouncingScrollPhysics(parent: AlwaysScrollableScrollPhysics()), physics: const BouncingScrollPhysics(parent: AlwaysScrollableScrollPhysics()),
clipBehavior: Clip.none, clipBehavior: Clip.none,
shrinkWrap: false, shrinkWrap: false,

@ -2,7 +2,7 @@ import 'dart:async';
import 'package:auto_size_text/auto_size_text.dart'; import 'package:auto_size_text/auto_size_text.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:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
@ -52,9 +52,9 @@ class _ForgetPasswordScreenState extends State<ForgetPasswordScreen> {
setState(() => canResendEmail = true); setState(() => canResendEmail = true);
} on FirebaseAuthException catch (e) { } on FirebaseAuthException catch (e) {
if (e.code == "invalid-email") { if (e.code == "invalid-email") {
error = "Format de mail incorrect";
} else if (e.code == "user-not-found") {
error = "Mail incorrect"; error = "Mail incorrect";
} else if (e.code == "user-not-found") {
error = "Format de mail incorrect";
} else if (e.code == "too-many-requests") { } else if (e.code == "too-many-requests") {
error = error =
"Trop de tentatives. Veuillez réessayer plus tard"; "Trop de tentatives. Veuillez réessayer plus tard";

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:justmusic/config/routes.dart'; import 'package:justmusic/config/routes.dart';
import 'package:lottie/lottie.dart'; import 'package:lottie/lottie.dart';

@ -1,4 +1,4 @@
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import '../values/constants.dart'; import '../values/constants.dart';

@ -85,7 +85,7 @@ class _LoginScreenState extends State<LoginScreen> {
mainAxisAlignment: MainAxisAlignment.end, mainAxisAlignment: MainAxisAlignment.end,
children: [ children: [
Text( Text(
"Te revoilà !", "Te revoilà!",
style: GoogleFonts.plusJakartaSans( style: GoogleFonts.plusJakartaSans(
color: Colors.white, fontWeight: FontWeight.w600, fontSize: 38.h), color: Colors.white, fontWeight: FontWeight.w600, fontSize: 38.h),
), ),
@ -95,7 +95,7 @@ class _LoginScreenState extends State<LoginScreen> {
SizedBox( SizedBox(
width: 230.w, width: 230.w,
child: Text( child: Text(
"Bon retour parmis nous. Tu nous as manqué !", "Bon retour parmis nous tu nous as manqué!",
style: GoogleFonts.plusJakartaSans( style: GoogleFonts.plusJakartaSans(
color: Colors.white, fontWeight: FontWeight.w400, fontSize: 20.h), color: Colors.white, fontWeight: FontWeight.w400, fontSize: 20.h),
textAlign: TextAlign.center, textAlign: TextAlign.center,
@ -116,7 +116,7 @@ class _LoginScreenState extends State<LoginScreen> {
keyboardAppearance: Brightness.dark, keyboardAppearance: Brightness.dark,
validator: (value) { validator: (value) {
if (value == null || value.isEmpty) { if (value == null || value.isEmpty) {
return 'Entrez un email valide'; return 'entrez un email valide';
} }
return null; return null;
}, },
@ -148,7 +148,7 @@ class _LoginScreenState extends State<LoginScreen> {
obscureText: passenable, obscureText: passenable,
validator: (value) { validator: (value) {
if (value == null || value.isEmpty) { if (value == null || value.isEmpty) {
return 'Entrez un mot de passe valide'; return 'entrez un mot de passe valide';
} }
return null; return null;
}, },
@ -202,7 +202,7 @@ class _LoginScreenState extends State<LoginScreen> {
child: Padding( child: Padding(
padding: EdgeInsets.only(top: 10), padding: EdgeInsets.only(top: 10),
child: Text( child: Text(
"Mot de passe oublié ?", "Mot de passe oublié?",
style: GoogleFonts.plusJakartaSans(color: Colors.white), style: GoogleFonts.plusJakartaSans(color: Colors.white),
), ),
)), )),
@ -226,14 +226,14 @@ class _LoginScreenState extends State<LoginScreen> {
child: RichText( child: RichText(
textAlign: TextAlign.center, textAlign: TextAlign.center,
text: TextSpan( text: TextSpan(
text: 'Pas encore inscrit ?', text: 'Pas encore inscrit?',
style: GoogleFonts.plusJakartaSans( style: GoogleFonts.plusJakartaSans(
color: Colors.white, color: Colors.white,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,
fontSize: 15), fontSize: 15),
children: <TextSpan>[ children: <TextSpan>[
TextSpan( TextSpan(
text: " Sinscrire", text: " Sinscire",
style: GoogleFonts.plusJakartaSans( style: GoogleFonts.plusJakartaSans(
fontSize: 15, fontSize: 15,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,

@ -1,7 +1,7 @@
import 'dart:io'; import 'dart:io';
import 'dart:ui'; import 'dart:ui';
import 'package:animations/animations.dart'; import 'package:animations/animations.dart';
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:justmusic/components/back_button.dart'; import 'package:justmusic/components/back_button.dart';
import 'package:justmusic/screens/launching_rocker_screen.dart'; import 'package:justmusic/screens/launching_rocker_screen.dart';

@ -2,7 +2,6 @@ import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:justmusic/services/AuthService.dart';
import 'package:justmusic/values/icons.dart'; import 'package:justmusic/values/icons.dart';
import '../components/profile_component.dart'; import '../components/profile_component.dart';
import '../components/setting_part_component.dart'; import '../components/setting_part_component.dart';
@ -33,40 +32,7 @@ class _ProfileScreenState extends State<ProfileScreen> {
Navigator.of(context).push(routeUser(MyApp.userViewModel.userCurrent)); Navigator.of(context).push(routeUser(MyApp.userViewModel.userCurrent));
} }
void openConfirmationDelete() { void _openPassword() {
showCupertinoModalPopup<void>(
context: context,
barrierColor: Colors.black.withOpacity(0.7),
builder: (BuildContext context) => Container(
child: CupertinoActionSheet(
title: Text(
'Supprimer mon compte',
style: GoogleFonts.plusJakartaSans(fontWeight: FontWeight.bold),
),
actions: <CupertinoActionSheetAction>[
CupertinoActionSheetAction(
onPressed: () {
MyApp.userViewModel.delete();
Navigator.pop(context);
Navigator.of(context).push(routeWelcome());
},
child: Text('Confirmer', style: TextStyle(color: Colors.blue),),
),
],
cancelButton: CupertinoActionSheetAction(
isDestructiveAction: true,
onPressed: () {
Navigator.pop(context);
},
child: const Text('Annuler'),
),
),
),
);
}
void openPassword() {
Navigator.of(context).push(routePassword()); Navigator.of(context).push(routePassword());
} }
@ -156,12 +122,12 @@ class _ProfileScreenState extends State<ProfileScreen> {
SettingPartComponent( SettingPartComponent(
icon: JustMusicIcon.password, icon: JustMusicIcon.password,
label: 'Modifier mon mot de passe', label: 'Modifier mon mot de passe',
action: openPassword, action: _openPassword,
), ),
SettingPartComponent( const SettingPartComponent(
icon: JustMusicIcon.trash, icon: JustMusicIcon.trash,
label: 'Supprimer mon compte', label: 'Supprimer mon compte',
action: openConfirmationDelete, action: null,
), ),
SettingPartComponent( SettingPartComponent(
icon: JustMusicIcon.cross, icon: JustMusicIcon.cross,

@ -1,6 +1,6 @@
import 'dart:ui'; import 'dart:ui';
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import '../components/city_list_component.dart'; import '../components/city_list_component.dart';

@ -1,7 +1,7 @@
import 'dart:async'; import 'dart:async';
import 'dart:ui'; import 'dart:ui';
import 'package:flutter/material.dart'; import 'package:flutter/Material.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';

@ -1,5 +1,8 @@
import 'dart:io'; import 'dart:io';
import 'package:flutter/material.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:firebase_core/firebase_core.dart';
import 'package:flutter/Material.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
@ -143,11 +146,10 @@ class _UserScreenState extends State<UserScreen> {
padding: const EdgeInsets.symmetric(horizontal: settingPadding), padding: const EdgeInsets.symmetric(horizontal: settingPadding),
child: Column( child: Column(
mainAxisAlignment: MainAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Container( Padding(
padding: EdgeInsets.only(top: 68.h, bottom: 40), padding: EdgeInsets.only(top: 68.h, bottom: 40),
constraints: const BoxConstraints( maxWidth: 500),
child: Stack( child: Stack(
alignment: Alignment.center, alignment: Alignment.center,
children: [ children: [
@ -250,11 +252,7 @@ class _UserScreenState extends State<UserScreen> {
SizedBox( SizedBox(
height: 40, height: 40,
), ),
Container( RecapComponent(user: widget.user)
constraints: const BoxConstraints( maxWidth: 500),
child: RecapComponent(user: widget.user),
)
], ],
), ),
), ),

@ -2,7 +2,7 @@ import 'dart:async';
import 'package:auto_size_text/auto_size_text.dart'; import 'package:auto_size_text/auto_size_text.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:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:google_fonts/google_fonts.dart'; import 'package:google_fonts/google_fonts.dart';
import 'package:justmusic/main.dart'; import 'package:justmusic/main.dart';

@ -78,7 +78,7 @@ class WellcomeScreen extends StatelessWidget {
child: Padding( child: Padding(
padding: const EdgeInsets.all(3.0), padding: const EdgeInsets.all(3.0),
child: Text( child: Text(
"Tu as déja un compte ? Connexion", "Tu as déja un compte? Connexion",
style: GoogleFonts.plusJakartaSans( style: GoogleFonts.plusJakartaSans(
color: Colors.white, color: Colors.white,
fontWeight: FontWeight.w400, fontWeight: FontWeight.w400,

@ -1,33 +0,0 @@
import 'package:cloud_firestore/cloud_firestore.dart';
class CapsuleService {
Future<List<bool>> recapSevenDays(String id) async {
List<bool> recapList = [];
DateTime sevenDaysAgo = DateTime.now().subtract(Duration(days: 6));
QuerySnapshot<Map<String, dynamic>> response = await FirebaseFirestore
.instance
.collection("capsules")
.where("user_id", isEqualTo: id)
.get();
List<Map<String, dynamic>?> capsuleList = response.docs
.map((DocumentSnapshot<Map<String, dynamic>> doc) => doc.data())
.toList();
for (int i = 0; i < 7; i++) {
DateTime date = sevenDaysAgo.add(Duration(days: i));
bool capsuleExists = capsuleList.any((post) =>
post?["date"] != null &&
post?["date"].toDate().year == date.year &&
post?["date"].toDate().month == date.month &&
post?["date"].toDate().day == date.day);
recapList.add(capsuleExists);
}
return recapList;
}
}

@ -38,7 +38,7 @@ class GeoApi {
Position position = await Geolocator.getCurrentPosition( Position position = await Geolocator.getCurrentPosition(
desiredAccuracy: LocationAccuracy.high); desiredAccuracy: LocationAccuracy.high);
String apiUrl = String apiUrl =
'https://api.openweathermap.org/data/2.5/find?lat=${position.latitude}&lon=${position.longitude}&cnt=10&appid=$apiKey'; 'http://api.openweathermap.org/data/2.5/find?lat=${position.latitude}&lon=${position.longitude}&cnt=10&appid=$apiKey';
var response = await http.get(Uri.parse(apiUrl)); var response = await http.get(Uri.parse(apiUrl));
if (response.statusCode == 200) { if (response.statusCode == 200) {
var data = json.decode(response.body); var data = json.decode(response.body);

@ -37,7 +37,7 @@ class MusicService {
List<Tuple2<int, String>> capsules = []; List<Tuple2<int, String>> capsules = [];
var querySnapshot = await FirebaseFirestore.instance var querySnapshot = await FirebaseFirestore.instance
.collection('capsules') .collection('posts')
.where('user_id', isEqualTo: idUser) .where('user_id', isEqualTo: idUser)
.where('date', isGreaterThanOrEqualTo: DateTime(year, month)) .where('date', isGreaterThanOrEqualTo: DateTime(year, month))
.where('date', isLessThan: DateTime(year, month + 1)) .where('date', isLessThan: DateTime(year, month + 1))

@ -23,15 +23,6 @@ class PostService {
var userRef = MyApp.db.collection("users").doc(id); var userRef = MyApp.db.collection("users").doc(id);
var capsule = {
"user_id": id,
"date": DateTime.now(),
"place": [location?.item1, location?.item2],
"song_id": idMusic,
};
await MyApp.db.collection("capsules").doc(postAdd.id).set(capsule);
await MyApp.db.runTransaction((transaction) async { await MyApp.db.runTransaction((transaction) async {
var userSnapshot = await transaction.get(userRef); var userSnapshot = await transaction.get(userRef);
if (userSnapshot.exists) { if (userSnapshot.exists) {
@ -51,41 +42,16 @@ class PostService {
deletePost() {} deletePost() {}
Future<List<QueryDocumentSnapshot<Map<String, dynamic>>>> getPopularPosts(int limit) async { Future<List<QueryDocumentSnapshot<Map<String, dynamic>>>> getPopularPosts(
DateTime twentyFourHoursAgo = DateTime.now().subtract(Duration(hours: 24)); {int limit = 10,
var response = await FirebaseFirestore.instance QueryDocumentSnapshot<Map<String, dynamic>>? offset}) async {
.collection("posts")
.where("date", isGreaterThan: twentyFourHoursAgo)
.orderBy("date", descending: true)
.limit(limit)
.get();
MyApp.postViewModel.lastPostDiscovery = response.docs.isNotEmpty
? response.docs.last
: MyApp.postViewModel.lastPostDiscovery;
var filteredPosts = response.docs.where((doc) {
String user = doc["user_id"];
return user != MyApp.userViewModel.userCurrent.id;
}).toList();
return filteredPosts;
}
Future<List<QueryDocumentSnapshot<Map<String, dynamic>>>> getMorePopularPosts(int limit) async {
DateTime twentyFourHoursAgo = DateTime.now().subtract(Duration(hours: 24));
QuerySnapshot<Map<String, dynamic>> response; QuerySnapshot<Map<String, dynamic>> response;
response = await FirebaseFirestore.instance response = await FirebaseFirestore.instance
.collection("posts") .collection("posts")
.where("date", isGreaterThan: twentyFourHoursAgo) .orderBy("date")
.orderBy("date", descending: true)
.limit(limit) .limit(limit)
.startAfterDocument(MyApp.postViewModel.lastPostDiscovery)
.get(); .get();
MyApp.postViewModel.lastPostDiscovery = response.docs.isNotEmpty
? response.docs.last
: MyApp.postViewModel.lastPostDiscovery;
var filteredPosts = response.docs.where((doc) { var filteredPosts = response.docs.where((doc) {
String user = doc["user_id"]; String user = doc["user_id"];
return user != MyApp.userViewModel.userCurrent.id; return user != MyApp.userViewModel.userCurrent.id;
@ -93,41 +59,18 @@ class PostService {
return filteredPosts; return filteredPosts;
} }
Future<List<QueryDocumentSnapshot<Map<String, dynamic>>>> getPostsFriends(int limit) async { Future<List<QueryDocumentSnapshot<Map<String, dynamic>>>> getPostsFriends(
var response = await FirebaseFirestore.instance {int limit = 10, int offset = 0}) async {
.collection("posts")
.where("user_id", whereIn: [
MyApp.userViewModel.userCurrent.id,
...MyApp.userViewModel.userCurrent.followed
])
.where("")
.orderBy("date", descending: true)
.limit(limit)
.get();
MyApp.postViewModel.lastPostFriend = response.docs.isNotEmpty
? response.docs.last
: MyApp.postViewModel.lastPostFriend;
return response.docs;
}
Future<List<QueryDocumentSnapshot<Map<String, dynamic>>>> getMorePostsFriends(int limit) async {
var response = await FirebaseFirestore.instance var response = await FirebaseFirestore.instance
.collection("posts") .collection("posts")
.where("user_id", whereIn: [ .where("user_id", whereIn: [
MyApp.userViewModel.userCurrent.id, MyApp.userViewModel.userCurrent.id,
...MyApp.userViewModel.userCurrent.followed ...MyApp.userViewModel.userCurrent.followed
]) ])
.orderBy("date", descending: true) .orderBy("date")
.limit(limit) .limit(limit)
.startAfterDocument(MyApp.postViewModel.lastPostFriend)
.get(); .get();
MyApp.postViewModel.lastPostFriend = response.docs.isNotEmpty
? response.docs.last
: MyApp.postViewModel.lastPostFriend;
return response.docs; return response.docs;
} }
@ -150,6 +93,35 @@ class PostService {
return !isTodayAvailable; return !isTodayAvailable;
} }
Future<List<bool>> recapSevenDays(String id) async {
List<bool> recapList = [];
DateTime sevenDaysAgo = DateTime.now().subtract(Duration(days: 6));
QuerySnapshot<Map<String, dynamic>> response = await FirebaseFirestore
.instance
.collection("posts")
.where("user_id", isEqualTo: id)
.get();
List<Map<String, dynamic>?> postList = response.docs
.map((DocumentSnapshot<Map<String, dynamic>> doc) => doc.data())
.toList();
for (int i = 0; i < 7; i++) {
DateTime date = sevenDaysAgo.add(Duration(days: i));
bool postExists = postList.any((post) =>
post?["date"] != null &&
post?["date"].toDate().year == date.year &&
post?["date"].toDate().month == date.month &&
post?["date"].toDate().day == date.day);
recapList.add(postExists);
}
return recapList;
}
Future<List<String>> getLikesByPostId(String id) async { Future<List<String>> getLikesByPostId(String id) async {
var response = var response =
await FirebaseFirestore.instance.collection("posts").doc(id).get(); await FirebaseFirestore.instance.collection("posts").doc(id).get();

@ -24,7 +24,6 @@ const searchBarColor = Color(0xFF161616);
const postbutton = Color(0xFF1B1B1B); const postbutton = Color(0xFF1B1B1B);
const fillButton = Color(0xFF633AF4); const fillButton = Color(0xFF633AF4);
const selectedButton = Color(0xFF1F1B2E); const selectedButton = Color(0xFF1F1B2E);
const tooltipBackground = Color(0xFF2D2D2D);
// All constants important too us // All constants important too us
const defaultPadding = 30.0; const defaultPadding = 30.0;

@ -1,5 +0,0 @@
const geoKey = "85a2724ad38b3994c2b7ebe1d239bbff";
const clientId = "d9b82921bbdf43efa15d0c34c28c6f93";
const clientSecret = "ba01687f59ea4ab7ad00c769e89e44d8";
const keyApiFirebase =
"AAAA56TmIPg:APA91bFeKMr_i6CbUuuUdFI1XkdaNE2A7OVHzxrPIsOSlDfhR6qzZwof7JNGxthWUKj1dRHQMheWNYaLbf3AtXUp9o4DX_gB2073yR4urqUEh9CjvnxVws_9g1cWMgmFS3EpaQEA3icC";

@ -241,12 +241,8 @@ class MusicViewModel {
var musics = await getMusicsWithIds(capsulesData.map((capsule) => capsule.item2).toList()); var musics = await getMusicsWithIds(capsulesData.map((capsule) => capsule.item2).toList());
for (var capsule in capsulesData) { for (var capsule in capsulesData) {
var music = musics.firstWhere( var music = musics.firstWhere((music) => music.id == capsule.item2);
(music) => music.id == capsule.item2, print(capsule.item1);
orElse: () => Music("-1", "", "", "", 0, 0, false, []),
);
if (music.id != "-1")
capsules.add(Tuple2(capsule.item1, music)); capsules.add(Tuple2(capsule.item1, music));
} }
return capsules; return capsules;

@ -1,7 +1,6 @@
import 'dart:io'; import 'dart:io';
import 'package:justmusic/model/Post.dart'; import 'package:justmusic/model/Post.dart';
import 'package:justmusic/services/CapsuleService.dart';
import 'package:justmusic/services/PostService.dart'; import 'package:justmusic/services/PostService.dart';
import 'package:tuple/tuple.dart'; import 'package:tuple/tuple.dart';
@ -12,10 +11,7 @@ import '../model/mapper/PostMapper.dart';
class PostViewModel { class PostViewModel {
List<Post> _postsFriends = []; List<Post> _postsFriends = [];
List<Post> _bestPosts = []; List<Post> _bestPosts = [];
var lastPostFriend;
var lastPostDiscovery;
final PostService _postService = PostService(); final PostService _postService = PostService();
final CapsuleService _capsuleService = CapsuleService();
// Constructor // Constructor
PostViewModel(); PostViewModel();
@ -30,10 +26,10 @@ class PostViewModel {
await _postService.createPost(description, idMusic, image, location); await _postService.createPost(description, idMusic, image, location);
} }
Future<List<Post>> getPostsFriends({int limit = 10}) async { Future<List<Post>> getPostsFriends() async {
try { try {
_postsFriends = []; _postsFriends = [];
var responseData = await _postService.getPostsFriends(limit); var responseData = await _postService.getPostsFriends();
List<String> ids = []; List<String> ids = [];
var postsFutures = responseData.map((value) { var postsFutures = responseData.map((value) {
ids.add(value.data()["song_id"]); ids.add(value.data()["song_id"]);
@ -44,7 +40,7 @@ class PostViewModel {
for (int i = 0; i < posts.length; i++) { for (int i = 0; i < posts.length; i++) {
posts[i].music = musics[i]; posts[i].music = musics[i];
} }
_postsFriends.addAll(posts); _postsFriends = posts;
return _postsFriends; return _postsFriends;
} catch (e) { } catch (e) {
print(e); print(e);
@ -53,29 +49,13 @@ class PostViewModel {
} }
} }
void getMorePostsFriends({int limit = 10}) async { List<Post> getMorePostsFriends() {
try { throw new Error();
var responseData = await _postService.getMorePostsFriends(limit);
List<String> ids = [];
var postsFutures = responseData.map((value) {
ids.add(value.data()["song_id"]);
return PostMapper.toModel(value);
}).toList();
var posts = await Future.wait(postsFutures);
List<Music> musics = await MyApp.musicViewModel.getMusicsWithIds(ids);
for (int i = 0; i < posts.length; i++) {
posts[i].music = musics[i];
}
_postsFriends.addAll(posts);
} catch (e) {
print(e);
}
} }
Future<List<Post>> getBestPosts({int limit = 10}) async { Future<List<Post>> getBestPosts() async {
try { try {
_bestPosts = []; var responseData = await _postService.getPopularPosts();
var responseData = await _postService.getPopularPosts(limit);
List<String> ids = []; List<String> ids = [];
var postsFutures = responseData.map((value) async { var postsFutures = responseData.map((value) async {
ids.add(value.data()["song_id"]); ids.add(value.data()["song_id"]);
@ -86,7 +66,7 @@ class PostViewModel {
for (int i = 0; i < posts.length; i++) { for (int i = 0; i < posts.length; i++) {
posts[i].music = musics[i]; posts[i].music = musics[i];
} }
_bestPosts.addAll(posts); _bestPosts = posts;
return _bestPosts; return _bestPosts;
} catch (e) { } catch (e) {
print(e); print(e);
@ -95,28 +75,13 @@ class PostViewModel {
} }
} }
void getMoreBestPosts({int limit = 10}) async { List<Post> getMoreBestPosts() {
try { throw new Error();
var responseData = await _postService.getMorePopularPosts(limit);
List<String> ids = [];
var postsFutures = responseData.map((value) async {
ids.add(value.data()["song_id"]);
return await PostMapper.toModel(value);
}).toList();
var posts = await Future.wait(postsFutures);
List<Music> musics = await MyApp.musicViewModel.getMusicsWithIds(ids);
for (int i = 0; i < posts.length; i++) {
posts[i].music = musics[i];
}
_bestPosts.addAll(posts);
} catch (e) {
print(e);
}
} }
Future<List<bool>> recapSevenDays(String id) async { Future<List<bool>> recapSevenDays(String id) async {
try { try {
return await _capsuleService.recapSevenDays(id); return await _postService.recapSevenDays(id);
} catch (e) { } catch (e) {
print(e); print(e);
rethrow; rethrow;
@ -147,6 +112,7 @@ class PostViewModel {
print(bool); print(bool);
return bool; return bool;
} catch (e) { } catch (e) {
print("haaaaaaaaa");
rethrow; rethrow;
} }
} }

@ -61,58 +61,58 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: audioplayers name: audioplayers
sha256: c05c6147124cd63e725e861335a8b4d57300b80e6e92cea7c145c739223bbaef sha256: "61583554386721772f9309f509e17712865b38565a903c761f96b1115a979282"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "5.2.1" version: "4.1.0"
audioplayers_android: audioplayers_android:
dependency: transitive dependency: transitive
description: description:
name: audioplayers_android name: audioplayers_android
sha256: b00e1a0e11365d88576320ec2d8c192bc21f1afb6c0e5995d1c57ae63156acb5 sha256: dbdc9b7f2aa2440314c638aa55aadd45c7705e8340d5eddf2e3fb8da32d4ae2c
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "4.0.3" version: "3.0.2"
audioplayers_darwin: audioplayers_darwin:
dependency: transitive dependency: transitive
description: description:
name: audioplayers_darwin name: audioplayers_darwin
sha256: "3034e99a6df8d101da0f5082dcca0a2a99db62ab1d4ddb3277bed3f6f81afe08" sha256: "6aea96df1d12f7ad5a71d88c6d1b22a216211a9564219920124c16768e456e9d"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "5.0.2" version: "4.1.0"
audioplayers_linux: audioplayers_linux:
dependency: transitive dependency: transitive
description: description:
name: audioplayers_linux name: audioplayers_linux
sha256: "60787e73fefc4d2e0b9c02c69885402177e818e4e27ef087074cf27c02246c9e" sha256: "396b62ac62c92dd26c3bc5106583747f57a8b325ebd2b41e5576f840cfc61338"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "3.1.0" version: "2.1.0"
audioplayers_platform_interface: audioplayers_platform_interface:
dependency: transitive dependency: transitive
description: description:
name: audioplayers_platform_interface name: audioplayers_platform_interface
sha256: "365c547f1bb9e77d94dd1687903a668d8f7ac3409e48e6e6a3668a1ac2982adb" sha256: f7daaed4659143094151ecf6bacd927d29ab8acffba98c110c59f0b81ae51143
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "6.1.0" version: "5.0.1"
audioplayers_web: audioplayers_web:
dependency: transitive dependency: transitive
description: description:
name: audioplayers_web name: audioplayers_web
sha256: "22cd0173e54d92bd9b2c80b1204eb1eb159ece87475ab58c9788a70ec43c2a62" sha256: ec84fd46eed1577148ed4113f5998a36a18da4fce7170c37ce3e21b631393339
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "4.1.0" version: "3.1.0"
audioplayers_windows: audioplayers_windows:
dependency: transitive dependency: transitive
description: description:
name: audioplayers_windows name: audioplayers_windows
sha256: "9536812c9103563644ada2ef45ae523806b0745f7a78e89d1b5fb1951de90e1a" sha256: "1d3aaac98a192b8488167711ba1e67d8b96333e8d0572ede4e2912e5bbce69a3"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "3.1.0" version: "2.0.2"
auto_size_text: auto_size_text:
dependency: "direct main" dependency: "direct main"
description: description:
@ -576,14 +576,6 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "9.2.0" version: "9.2.0"
fullscreen_window:
dependency: "direct main"
description:
name: fullscreen_window
sha256: fe3014f91bff16a82d142ba9d834980b8a84b4bb03347a92588d389ad92bd1d3
url: "https://pub.dev"
source: hosted
version: "1.0.4"
geolocator: geolocator:
dependency: "direct main" dependency: "direct main"
description: description:
@ -636,10 +628,10 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: google_fonts name: google_fonts
sha256: f0b8d115a13ecf827013ec9fc883390ccc0e87a96ed5347a3114cac177ef18e8 sha256: "6b6f10f0ce3c42f6552d1c70d2c28d764cf22bb487f50f66cca31dcd5194f4d6"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "6.1.0" version: "4.0.4"
google_identity_services_web: google_identity_services_web:
dependency: transitive dependency: transitive
description: description:
@ -708,10 +700,10 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: http name: http
sha256: "759d1a329847dd0f39226c688d3e06a6b8679668e350e2891a6474f8b4bb8525" sha256: "5895291c13fa8a3bd82e76d5627f69e0d85ca6a30dcac95c4ea19a5d555879c2"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.1.0" version: "0.13.6"
http_parser: http_parser:
dependency: transitive dependency: transitive
description: description:
@ -732,10 +724,10 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: image_picker name: image_picker
sha256: "7d7f2768df2a8b0a3cefa5ef4f84636121987d403130e70b17ef7e2cf650ba84" sha256: "6296e98782726d37f59663f0727d0e978eee1ced1ffed45ccaba591786a7f7b3"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.4" version: "1.0.1"
image_picker_android: image_picker_android:
dependency: transitive dependency: transitive
description: description:
@ -748,10 +740,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: image_picker_for_web name: image_picker_for_web
sha256: "50bc9ae6a77eea3a8b11af5eb6c661eeb858fdd2f734c2a4fd17086922347ef7" sha256: "869fe8a64771b7afbc99fc433a5f7be2fea4d1cb3d7c11a48b6b579eb9c797f0"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "3.0.1" version: "2.2.0"
image_picker_ios: image_picker_ios:
dependency: transitive dependency: transitive
description: description:

@ -20,7 +20,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
version: 1.0.0+1 version: 1.0.0+1
environment: environment:
sdk: '>=3.1.4 <4.0.0' sdk: '>=2.18.2 <3.0.0'
# Dependencies specify other packages that your package needs in order to work. # Dependencies specify other packages that your package needs in order to work.
# To automatically upgrade your package dependencies to the latest versions # To automatically upgrade your package dependencies to the latest versions
@ -31,13 +31,13 @@ environment:
dependencies: dependencies:
flutter: flutter:
sdk: flutter sdk: flutter
http: ^1.1.0 http: ^0.13.5
# The following adds the Cupertino Icons font to your application. # The following adds the Cupertino Icons font to your application.
# Use with the CupertinoIcons class for iOS style icons. # Use with the CupertinoIcons class for iOS style icons.
cupertino_icons: ^1.0.2 cupertino_icons: ^1.0.2
google_fonts: ^6.1.0 google_fonts: ^4.0.4
gradiantbutton: ^0.0.1 gradiantbutton: ^0.0.1
smooth_corner: ^1.1.0 smooth_corner: ^1.1.0
flutter_signin_button: ^2.0.0 flutter_signin_button: ^2.0.0
@ -50,7 +50,7 @@ dependencies:
custom_draggable_widget: ^0.0.2 custom_draggable_widget: ^0.0.2
modal_bottom_sheet: ^2.1.2 modal_bottom_sheet: ^2.1.2
flutter_animated_play_button: ^0.3.0 flutter_animated_play_button: ^0.3.0
audioplayers: ^5.2.1 audioplayers: ^4.1.0
ionicons: ^0.2.2 ionicons: ^0.2.2
top_snackbar_flutter: ^3.1.0 top_snackbar_flutter: ^3.1.0
firebase_core: ^2.15.0 firebase_core: ^2.15.0
@ -77,7 +77,6 @@ dependencies:
cached_network_image: ^3.2.3 cached_network_image: ^3.2.3
google_sign_in: ^6.1.4 google_sign_in: ^6.1.4
flutter_launcher_icons: ^0.13.1 flutter_launcher_icons: ^0.13.1
fullscreen_window: ^1.0.3
dev_dependencies: dev_dependencies:
flutter_test: flutter_test:

Binary file not shown.

Before

Width:  |  Height:  |  Size: 480 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 41 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 41 KiB

@ -1,81 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<!--
If you are serving your web app in a path other than the root, change the
href value below to reflect the base path you are serving from.
The path provided below has to start and end with a slash "/" in order for
it to work correctly.
For more details:
* https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base
This is a placeholder for base href that will be replaced by the value of
the `--base-href` argument provided to `flutter build`.
-->
<base href="$FLUTTER_BASE_HREF">
<meta charset="UTF-8">
<meta content="IE=Edge" http-equiv="X-UA-Compatible">
<meta name="description" content="A new Flutter project.">
<meta name="google-signin-client_id" content="994903990520-pravk8o6o9ehkhe6asjrao4fmlve0lel.apps.googleusercontent.com">
<!-- iOS meta tags & icons -->
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="apple-mobile-web-app-title" content="justmusic">
<link rel="apple-touch-icon" href="icons/icon-192.png">
<!-- Favicon -->
<link rel="icon" type="image/png" href="favicon.png"/>
<title>justmusic</title>
<link rel="manifest" href="manifest.json">
<script>
// The value below is injected by flutter build, do not touch.
const serviceWorkerVersion = null;
</script>
<!-- This script adds the flutter initialization JS code -->
<script src="flutter.js" defer></script>
</head>
<body>
<script>
window.addEventListener('load', function(ev) {
// Download main.dart.js
_flutter.loader.loadEntrypoint({
serviceWorker: {
serviceWorkerVersion: serviceWorkerVersion,
},
onEntrypointLoaded: function(engineInitializer) {
engineInitializer.initializeEngine().then(function(appRunner) {
appRunner.runApp();
});
}
});
});
</script>
</body>
</html>
<style>
/* Centers flutter canvas with a size of the viewport*/
flt-glass-pane {
position: fixed !important; /* Overrides absolute from flutter */
top: 50vh !important;
left: 50vw !important;
max-width: 100vw !important;
max-height: 100vh !important;
transform: translate(-50vw, -50vh) !important;
}
/*
Scrollbar hide doesn't work on iOS, they add a default one when overflow:true and -webkit-overflow-scrolling: touch;
Sadly since iOS 13, this value is forced on iOS -> https://developer.apple.com/documentation/safari-release-notes/safari-13-release-notes
*/
::-webkit-scrollbar {
display: false;
width: 0px;
height: 0px; /* Remove scrollbar space */
background: transparent; /* Optional: just make scrollbar invisible */
}
</style>

@ -1,35 +0,0 @@
{
"name": "justmusic",
"short_name": "justmusic",
"start_url": ".",
"display": "standalone",
"background_color": "#0175C2",
"theme_color": "#0175C2",
"description": "A new Flutter project.",
"orientation": "portrait-primary",
"prefer_related_applications": false,
"icons": [
{
"src": "icons/Icon-192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "icons/Icon-512.png",
"sizes": "512x512",
"type": "image/png"
},
{
"src": "icons/Icon-maskable-192.png",
"sizes": "192x192",
"type": "image/png",
"purpose": "maskable"
},
{
"src": "icons/Icon-maskable-512.png",
"sizes": "512x512",
"type": "image/png",
"purpose": "maskable"
}
]
}
Loading…
Cancel
Save