generated from jwson-automation/blueberry_template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
302 additions
and
145 deletions.
There are no files selected for viewing
10 changes: 10 additions & 0 deletions
10
lib/feature/friendsList/provider/FriendsListImageProvider.dart
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import 'package:firebase_storage/firebase_storage.dart'; | ||
import 'package:flutter_riverpod/flutter_riverpod.dart'; | ||
|
||
// 친구목록 이미지 URL을 제공하는 Provider | ||
final friendsListImageProvider = | ||
FutureProvider.family<String, String>((ref, imageName) async { | ||
final storageRef = FirebaseStorage.instance.ref('profileimage/$imageName'); | ||
final downloadUrl = await storageRef.getDownloadURL(); | ||
return downloadUrl; | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
lib/feature/friendsList/widget/FriendBottomSheetLauncher.dart
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import 'package:flutter/material.dart'; | ||
|
||
import '../../../model/FriendModel.dart'; | ||
import 'FriendBottomSheet.dart'; | ||
|
||
class FriendBottomSheetLauncher { | ||
static void show({ | ||
required BuildContext context, | ||
required FriendModel friend, | ||
required String imageUrl, | ||
}) { | ||
showModalBottomSheet( | ||
context: context, | ||
isScrollControlled: true, | ||
shape: const RoundedRectangleBorder( | ||
borderRadius: BorderRadius.vertical( | ||
top: Radius.circular(25.0), | ||
), | ||
), | ||
builder: (context) => FriendBottomSheetWidget( | ||
friend: friend, | ||
imageUrl: imageUrl, | ||
), | ||
); | ||
} | ||
} |
Oops, something went wrong.