-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #19 from bedirhantong/notifications_tab
Notifications tab
- Loading branch information
Showing
55 changed files
with
2,507 additions
and
1,057 deletions.
There are no files selected for viewing
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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,5 @@ | ||
# Launch Screen Assets | ||
|
||
You can customize the launch screen with your own desired assets by replacing the image files in this directory. | ||
|
||
You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. |
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,12 @@ | ||
import Flutter | ||
import UIKit | ||
import XCTest | ||
|
||
class RunnerTests: XCTestCase { | ||
|
||
func testExample() { | ||
// If you add code to the Runner application, consider adding tests here. | ||
// See https://developer.apple.com/documentation/xctest for more information about using XCTest. | ||
} | ||
|
||
} |
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
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
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,122 @@ | ||
import '../features/authentication/objects/thread.dart'; | ||
import '../features/authentication/objects/user.dart'; | ||
|
||
class AppStarter { | ||
static List<Thread> allThreads = [ | ||
Thread( | ||
whoPosted: 'me', | ||
whatTextIsPosted: 'Recent Illustration of mine', | ||
whatImageIsPosted: 'assets/images/temp_user_images/bdo_post.png', | ||
whenPosted: '6 hours', | ||
likeNum: 23, | ||
height: calculateHeight( | ||
'How you doin\'?', | ||
230, | ||
), | ||
username: 'bdotng'), | ||
Thread( | ||
whoPosted: 'serhan', | ||
whatTextIsPosted: 'All of my dream is to be a pilot.', | ||
whatImageIsPosted: 'assets/images/temp_user_images/f35.png', | ||
whenPosted: '2 days', | ||
likeNum: 23, | ||
height: calculateHeight( | ||
'They don\'t know that we know they know we know.', | ||
250, | ||
), | ||
username: 'srhnbymz'), | ||
Thread( | ||
whoPosted: 'musa', | ||
whatTextIsPosted: | ||
'Bir şeyler denedim yine because I am Musa, I do such things.', | ||
whatImageIsPosted: 'assets/images/temp_user_images/musa_post.png', | ||
whenPosted: '2 hours', | ||
likeNum: 23, | ||
height: calculateHeight( | ||
'PIVOT!', | ||
450, | ||
), | ||
username: 'alatasms'), | ||
Thread( | ||
whoPosted: 'sinan', | ||
whatTextIsPosted: 'Smelly Cat, Smelly Cat, what are they feeding you?', | ||
whenPosted: 'last year', | ||
likeNum: 23, | ||
height: calculateHeight( | ||
'Smelly Cat, Smelly Cat, what are they feeding you?', | ||
50, | ||
), | ||
username: 'demir_exe'), | ||
Thread( | ||
whoPosted: 'yusuf', | ||
whatTextIsPosted: 'Sen de benim gibi bir şeyler denedin mi?', | ||
whatImageIsPosted: 'assets/images/temp_user_images/yusuf_post.png', | ||
whenPosted: '3 min', | ||
likeNum: 23, | ||
height: calculateHeight( | ||
'Could I be wearing any more clothes?', | ||
200, | ||
), | ||
username: 'yuciferr'), | ||
Thread( | ||
whoPosted: 'onur', | ||
whatTextIsPosted: | ||
'Mükemmel şarkı her sabah dinliyorum. Bunsuz güne başlayamıyorum', | ||
whatImageIsPosted: 'assets/images/temp_user_images/onur_post.png', | ||
whenPosted: '13 hours', | ||
likeNum: 23, | ||
height: calculateHeight( | ||
'Welcome to the real world. It sucks! You\'re gonna love it.', | ||
190, | ||
), | ||
username: '10urcetin'), | ||
]; | ||
|
||
static double calculateHeight(String postContent, double imageHeight) { | ||
// Verilen metni satır sayısına bölmek için gerekli işlemler | ||
List<String> lines = postContent.split('\n'); | ||
int totalLines = lines.length; | ||
|
||
// Satır sayısı 0 ise varsayılan bir değer döndür | ||
if (totalLines == 0) { | ||
return 0.0; | ||
} | ||
|
||
return (totalLines * 12) + imageHeight; | ||
} | ||
|
||
static List<User> allUsers = [ | ||
User( | ||
name: "ucak_adam", | ||
email: "[email protected]", | ||
password: "123", | ||
phoneNumber: "012321321", | ||
bio: "", | ||
profilePictureLink: 'assets/images/temp_user_images/serhan.jpg', | ||
), | ||
User( | ||
name: "si_sharp", | ||
email: "[email protected]", | ||
password: "123", | ||
phoneNumber: "012321321", | ||
bio: "", | ||
profilePictureLink: 'assets/images/temp_user_images/musa.jpg', | ||
), | ||
User( | ||
name: "10nur", | ||
email: "[email protected]", | ||
password: "123", | ||
phoneNumber: "012321321", | ||
bio: "", | ||
profilePictureLink: 'assets/images/temp_user_images/onur.jpg', | ||
), | ||
User( | ||
name: "yucifer", | ||
email: "[email protected]", | ||
password: "123", | ||
phoneNumber: "012321321", | ||
bio: "", | ||
profilePictureLink: 'assets/images/temp_user_images/yusuf.jpg', | ||
), | ||
]; | ||
} |
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,31 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:like_button/like_button.dart'; | ||
|
||
import '../screens/comments_of_post_screen/build_post_include_all.dart'; | ||
import '../screens/comments_of_post_screen/comments_of_post_screen.dart'; | ||
|
||
class Thread { | ||
String whoPosted; | ||
String username; | ||
String? whatTextIsPosted; | ||
String? whatImageIsPosted; | ||
String whenPosted; | ||
double height; | ||
List<Widget>? commentsListWidget; | ||
String? id; | ||
int likeNum; | ||
|
||
// String token = ""; | ||
|
||
Thread({ | ||
required this.whoPosted, | ||
this.whatTextIsPosted, | ||
this.whatImageIsPosted, | ||
required this.whenPosted, | ||
required this.likeNum, | ||
this.commentsListWidget, | ||
required this.height, | ||
required this.username, | ||
this.id, | ||
}); | ||
} |
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,47 @@ | ||
import 'package:threads_clone/src/features/authentication/objects/thread.dart'; | ||
|
||
class User { | ||
String? id; | ||
String name = "edit here"; | ||
String? username = "edit here"; | ||
String email = "edit here"; | ||
String password = "edit here"; | ||
String phoneNumber = "edit here"; | ||
String profilePictureLink = ""; | ||
String bio = "edit here"; | ||
bool isPrivate = false; | ||
List<User> friends = []; | ||
List<Thread> threadsPosted = []; | ||
List<Thread> threadsLiked = []; | ||
|
||
// String token = ""; | ||
|
||
User({ | ||
this.username, | ||
required this.profilePictureLink, | ||
required this.name, | ||
required this.email, | ||
required this.password, | ||
required this.phoneNumber, | ||
required this.bio, | ||
// required this.token | ||
}); | ||
// | ||
// User.fromJson(Map<String, dynamic> json) { | ||
// id = json['id']; | ||
// name = json['name']; | ||
// email = json['email']; | ||
// password = json['password']; | ||
// token = json['token']; | ||
// } | ||
// | ||
// Map<String, dynamic> toJson() { | ||
// final Map<String, dynamic> data = <String, dynamic>{}; | ||
// data['id'] = id; | ||
// data['name'] = name; | ||
// data['email'] = email; | ||
// data['password'] = password; | ||
// data['token'] = token; | ||
// return data; | ||
// }); | ||
} |
Oops, something went wrong.