-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
232 lines (225 loc) · 10.5 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="SociUnityHub - Connect, Share, and Collaborate with Others">
<meta name="keywords" content="social media, community, networking, sharing, collaboration">
<meta name="author" content="Amira Alaa">
<meta name="robots" content="index, follow">
<!-- OpenGraph meta tags for social media sharing -->
<meta property="og:title" content="SociUnityHub">
<meta property="og:description" content="Connect, Share, and Collaborate with Others">
<meta property="og:image" content="your-image-url.jpg">
<meta property="og:url" content="https://amiraalaa3.github.io/SocialHub/">
<meta property="og:type" content="website">
<!-- logo -->
<link rel="icon" href="./images/logo.png">
<!-- Bootstrap -->
<link rel="stylesheet" href="./bootstrap-5.2.3-dist/css/bootstrap.min.css">
<script src="./bootstrap-5.2.3-dist/js/bootstrap.bundle.js"></script>
<!-- font -->
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Borel&family=Cairo:wght@200;300;400;500;600;700;800&display=swap"
rel="stylesheet">
<!-- CSS -->
<link rel="stylesheet" href="./Style/style.css">
<!-- axios -->
<script src="https://unpkg.com/axios/dist/axios.min.js"></script>
<title>SociUnityHub</title>
</head>
<body>
<!-- ======= LOADER ======== -->
<div id="loader">
<div class="lds-ring"><div></div><div></div><div></div><div></div></div>
</div>
<!-- modals -->
<!-- login modal -->
<div class="modal fade" id="login-model" tabindex="-1" aria-labelledby="loginModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="loginModalLabel">Login</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<form>
<div class="mb-3">
<label for="username-input" class="col-form-label">Username:</label>
<input type="text" class="form-control" id="username-input" required>
</div>
<div class="mb-3">
<label for="password-input" class="col-form-label">Password:</label>
<input type="password" class="form-control" id="password-input" required>
</div>
</form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Close</button>
<button type="button" class="btn btn-primary" onclick="loginClicked();">Login</button>
</div>
</div>
</div>
</div>
<!-- register modal -->
<div class="modal fade" id="register-model" tabindex="-1" aria-labelledby="registerModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="registerModalLabel">Register A New User </h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<form>
<div class="mb-3">
<label for="register-name-input" class="col-form-label">Name:</label>
<input type="text" class="form-control" id="register-name-input" required>
</div>
<div class="mb-3">
<label for="register-username-input" class="col-form-label">Username:</label>
<input type="text" class="form-control" id="register-username-input" required>
</div>
<!-- profile_image -->
<div class="mb-3">
<label for="register-profile-image" class="col-form-label">Profile Image:</label>
<input type="file" accept="image/*" class="form-control" id="register-profile-image">
</div>
<div class="mb-3">
<label for="register-email-input" class="col-form-label">Email:</label>
<input type="email" class="form-control" id="register-email-input" required>
</div>
<div class="mb-3">
<label for="register-password-input" class="col-form-label">Password:</label>
<input type="password" class="form-control" id="register-password-input" required>
</div>
</form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Close</button>
<button type="button" class="btn btn-primary" onclick="Register();">Register</button>
</div>
</div>
</div>
</div>
<!-- Create post modal -->
<div class="modal fade" id="Add-post-model" tabindex="-1" aria-labelledby="Add-postModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="Add-postModalLabel"></h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<form>
<div class="mb-3">
<label for="post-title" class="col-form-label">Title:</label>
<input type="text" class="form-control" id="post-title">
<input type="hidden" value="" id="post-id-input">
</div>
<div class="mb-3">
<label for="post-body" class="col-form-label">Body:</label>
<textarea class="form-control" id="post-body" rows="5"></textarea>
</div>
<div class="mb-3">
<label for="post-img" class="col-form-label">Image:</label>
<input type="file" accept="image/*" class="form-control" id="post-img">
</div>
</form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Close</button>
<button type="button" class="btn btn-primary" id="post-modal-submit-btn" onclick="createNewPost();">Create</button>
</div>
</div>
</div>
</div>
<!-- Delete post modal -->
<div class="modal fade" id="Delete-post-model" tabindex="-1" aria-labelledby="Delete-postModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="Delete-postModalLabel">
Are You Sure You Want To Delete The Post ?
</h5>
<input type="hidden" value="" id="delete-post-id">
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Close</button>
<button type="button" class="btn btn-danger" onclick="confirmDelete();">Delete</button>
</div>
</div>
</div>
</div>
<!-- Bootstrap Alert Login -->
<div id="liveAlertPlaceholder" class="show fade" style="position:fixed; z-index:99999; width:40%; bottom:0; right:0;">
</div>
<!-- add new post -->
<div class="d-flex" id="add-post" onclick="addBtnClick()">
<ion-icon name="add-outline"></ion-icon>
</div>
<!-- navbar -->
<div class="container pt-3 fixed-top">
<div class="d-flex justify-content-center">
<div class="col-9">
<nav class="navbar navbar-expand-lg bg-body-tertiary py-2 rounded shadow" style="background-color: white;">
<div class="container">
<a class="navbar-brand" href="index.html">
<img src="./images/logo.png" alt="Logo" width="40" height="40" class="d-inline-block">
SociUnityHub
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav">
<li class="nav-item">
<a class="nav-link active" aria-current="page" href="index.html">Home</a>
</li>
<li class="nav-item">
<a class="nav-link card-cursor" onclick="profileClick();">Profile</a>
</li>
</ul>
<!-- user non-login -->
<div class="d-flex w-100 justify-content-end" id="logout-div">
<button type="button" id="btn-login" class="btn btn-outline-success" data-bs-toggle="modal"
data-bs-target="#login-model">Login</button>
<button type="button" class="btn btn-success mx-2" id="btn-register" data-bs-toggle="modal"
data-bs-target="#register-model">Register</button>
</div>
<!-- user login -->
<div class="d-flex w-100 justify-content-end align-items-center" id="login-div">
<div class="d-flex align-items-center" >
<h6 id="username-nav" class="pe-2"></h6>
<img class="rounded-circle border-5" style="width: 40px; height: 40px;" src="./images/user.png"
alt="user-image" id="user-image-nav">
</div>
<button type="button" class="btn btn-danger mx-2" id="btn-logout" onclick="logout();">Logout</button>
</div>
</div>
</div>
</nav>
</div>
</div>
</div>
<!-- Content -->
<div class="container mt-5 pt-4" style="height: 1000px;">
<div class="d-flex justify-content-center">
<div class="col-9">
<!-- posts -->
<div id="posts">
<!-- post -->
</div>
</div>
</div>
</div>
<!-- javascript -->
<script src="./Js/mainLogic.js"></script>
<script src="./Js/home.js"></script>
<!-- icon -->
<script type="module" src="https://unpkg.com/[email protected]/dist/ionicons/ionicons.esm.js"></script>
<script nomodule src="https://unpkg.com/[email protected]/dist/ionicons/ionicons.js"></script>
</body>
</html>