forked from mavicompanion/google-drive-clone
-
Notifications
You must be signed in to change notification settings - Fork 0
/
home.html
375 lines (366 loc) · 19.3 KB
/
home.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
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Meta Tags: Define document's character set and responsive design -->
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="icon" type="image/x-icon" href="./img/google-drive.png">
<title>Drive</title>
<!-- Link to Bootstrap CSS for responsive design and pre-built components -->
<link
href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/css/bootstrap.min.css"
rel="stylesheet"
integrity="sha384-rbsA2VBKQhggwzxH7pPCaAqO46MgnOM80zW1RWuH61DGLwZJEdK2Kadq2F9CUG65"
crossorigin="anonymous"
/>
<!-- Font Awesome for icons used throughout the page -->
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"
integrity="sha512-iecdLmaskl7CVkqkXNQ/ZH/XLlvWZOJyj7Yy7tcenmpD1ypASozpmT/E0iPtmFIB46ZmdtAc9eNBvH0H/ZpiBw=="
crossorigin="anonymous"
referrerpolicy="no-referrer"
/>
<!-- Link to custom stylesheet for further design customization -->
<link rel="stylesheet" href="./style.css" />
<!-- Firebase Configuration -->
<script type="module" src="./js/auth.js"></script>
<script type="module" src="./js/home.js"></script>
</head>
<body>
<input type="file" id="fileInput" style="display:none;" />
<div id="status"></div>
<div id="fullScreenLoader" class="d-none justify-content-center align-items-center position-fixed top-0 start-0 w-100 h-100 bg-white" style="z-index: 1050; display: none;">
<div class="spinner-border text-primary" role="status">
<span class="visually-hidden">Loading...</span>
</div>
</div>
<!-- Main container for the entire layout (Bootstrap Fluid Container) -->
<div class="container-fluid p-0 d-flex h-100">
<!-- Sidebar: Vertical navigation and information area -->
<div
class="d-flex flex-column flex-shrink-0 px-4 py-3 offcanvas-md offcanvas-start"
style="width: 250px"
id="sideBar"
>
<!-- Header of Sidebar: Displays logo and app title -->
<div class="d-flex mt-2">
<!-- App logo on the left side -->
<span
><img
src="./img/google-drive.png"
width="36px"
class="me-2 ms-2"
alt="App Logo"
/></span>
<!-- App title next to the logo -->
<h5 class="fw-semibold mt-2">Drive</h5>
</div>
<div class="dropdown">
<button class="btn new-button mb-3 mt-4" style="width: 110px" dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
<i class="fa-solid fa-plus fs-5 fw-light"></i>
<span class="ms-3 me-auto fw-semibold">New</span>
</button>
<ul class="dropdown-menu mt-1 rounded-2 new-button-dropdown">
<li class="p-0 dropdown-list-item px-3 py-1 mb-2"><a class="m-0" href="" data-bs-toggle="modal" data-bs-target="#newFolderModal"><img src="./img/new-folder.png" class=" p-0 m-0 me-3" style="width: 20px;" alt="">New Folder</a></li>
<hr class="m-0">
<li class="p-0 dropdown-list-item px-3 py-1 mt-2"><a class="m-0" href="" id="uploadFileButton"><img src="./img/file-upload.png" class=" p-0 m-0 me-3" style="width: 20px;" alt="">Upload File</a></li>
<li class="p-0 dropdown-list-item px-3 py-1 mb-2"><a class="m-0" href=""><img src="./img/new-folder.png" class=" p-0 m-0 me-3" style="width: 20px;" alt="">Upload Folder</a></li>
</ul>
</div>
<!-- Navigation Links for Sidebar -->
<div class="d-flex flex-column flex-fill px-0">
<!-- Home link -->
<a href="./home.html" class="px-2 py-1 mb-1 rounded-pill nav-link active">
<p class="m-0 d-flex align-items-center">
<img src="./img/gdrive-add.png" class="me-2" style="width: 20px;" alt="">My Drive
</p>
</a>
<!-- 1st Year link -->
<a
href="./starred.html"
class="px-2 py-1 mb-1 rounded-pill nav-link"
>
<p class="m-0 d-flex align-items-center">
<img src="./img/star.png" class="me-2" style="width: 20px;" alt="">Starred
</p>
</a>
<!-- Video Lectures link -->
<a
href="./home.html"
class="px-2 py-1 mb-1 rounded-pill nav-link"
>
<p class="m-0 d-flex align-items-center">
<img src="./img/recycle-bin.png" class="me-2" style="width: 20px;" alt="">Bin
</p>
</a>
</div>
</div>
<!-- Main content area -->
<div class="flex-fill d-flex flex-column space-between">
<!-- Responsive Navbar for smaller screens (collapsible menu) -->
<div class="p-3 py-3 d-md-none d-flex text-white bg-dark">
<a
href=""
class="text-white"
data-bs-toggle="offcanvas"
data-bs-target="#sideBar"
>
<i class="fa-solid fa-bars" style="font-size: 25px"></i>
</a>
<span class="ms-3 fw-bold">BU Notes</span>
</div>
<!-- Add the search bar and app buttons here -->
<div class="sea">
<div class="search-container">
<div class="search-box">
<button><i class="button rounded-circle p-2 m-0 fa-solid fa-magnifying-glass"></i></button>
<input type="text" placeholder="Search in Drive" />
<button class="button rounded-circle px-2">
<i class="fas fa-sliders-h"></i>
</button>
</div>
</div>
<div class="appButtonsContainer">
<div class="app-buttons">
<a href="https://github.com/mavicompanion/google-drive-clone" target="_blank" class="btn button p-1 me-1 rounded-circle">
<img src="./img/info-logo.png" class="m-0" alt="">
</a>
<div class="dropdown">
<button class="btn button p-1 me-1 rounded-circle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
<img src="./img/settings.png" class="m-0" alt="">
</button>
<ul class="dropdown-menu dropdown-menu-end mt-2 rounded-1 border-0" style="box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3)">
<li><a class="dropdown-item fw-light py-1" style="margin-right: 6rem;font-size: 15px;" href="#">Settings</a></li>
<li><a class="dropdown-item fw-light py-1" style="margin-right: 6rem;font-size: 15px;" href="#">Get Drive for Desktop</a></li>
<li><a class="dropdown-item fw-light py-1" style="margin-right: 6rem;font-size: 15px;" href="#">Keyboard Shortcuts</a></li>
</ul>
</div>
<!-- More Apps Dropdown -->
<div class="dropdown">
<button class="btn button rounded-pill m-0 p-1 me-1" type="button" data-bs-toggle="dropdown" aria-expanded="false">
<img src="./img/more-apps.png" class="m-0" alt="">
</button>
<ul class="dropdown-menu rounded-5 more-apps mt-2">
<div class="d-flex flex-column align-items-center justify-content-center">
<div class="rounded-5 bg-white d-flex ms-2 me-2 py-3 px-3">
<div class="container text-center mt-3 mb-3">
<div class="row row-cols-3 gy-4">
<div class="col">
<a class="d-flex flex-column text-decoration-none">
<img src="img/google-search.png" alt="Account" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Search</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-maps.png" alt="Search" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Maps</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-gcp.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Cloud</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-news.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">News</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-calendar.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Calendar</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/g-mail.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Gmail</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-photos.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Photos</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-news.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">News</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-meet.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Meet</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-lens.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Lens</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/g-drive.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Drive</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-docs.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Docs</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-forms.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Forms</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-keep.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Keep</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/google-sheets.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Sheets</p>
</a>
</div>
<div class="col">
<a class="d-flex flex-column align-items-center text-decoration-none">
<img src="img/goolge-slides.png" alt="Maps" class="icon-size ms-auto me-auto">
<p class="mt-2 mb-0">Slides</p>
</a>
</div>
</div>
</div>
</div>
<div class="container text-center mt-4 mb-4">
<a href="./index.html" class="btn rounded-button px-4 py-2">
More from Google
</a>
</div>
</div>
</ul>
</div>
<div class="dropdown">
<button class="btn p-0 m-0 ms-2 rounded-circle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
<img id="account-pfp-1" class="m-0" alt="" />
</button>
<ul class="dropdown-menu mt-2 account-container rounded-5">
<div class="text-center fs-small mt-2 " id="account-email">
</div>
<div class="w-100 d-flex flex-column mt-4 mb-0">
<img class="ms-auto me-auto" id="account-pfp" alt="Logo" style="width: 70px;height: 70px;">
<p class="fs-5 text-center mt-1 " id="account-name-message"></p>
</div>
<div class="container text-center">
<a href="./index.html" class="btn rounded-button px-4 py-2 fs-small">
Manage your Google Account
</a>
</div>
<button class="btn btn-light d-flex align-items-center rounded-pill px-3 py-2 shadow-sm m-2 ms-auto me-auto fs-small mt-2" id="sign-out-btn" style="width: fit-content;">
<i class="fa-solid fa-arrow-right-from-bracket m-0 me-2 p-0" style="font-size: small;"></i>
Sign out
</button>
<div class="text-center fs-small mt-5 mb-3">
Privacy Policy - Terms of Service
</div>
</ul>
</div>
</div>
</div>
</div>
<!-- Main content area where the assets (notes, videos) are displayed -->
<div
class="flex-fill ms-md-2 me-md-3 mt-md-3 mb-md-4 content-area py-4 px-1"
>
<!-- Page header -->
<p class="page-title rounded-pill ms-2">My Drive</p>
<div id="folderTitleIndicator" class="d-none d-md-flex ms-2 ms-md-4 gap-1 pe-4 mt-3 mb-2 flex-wrap">
<div class="d-flex align-items-center">
</div>
</div>
<div class="mt-4 px-4">
<div class="row" id="foldersList">
</div>
</div>
<div class="row gap-1 gap-md-3 px-3 px-md-4 mt-4" id="fileList">
<!-- <div class="file-tile bg-slate rounded-4 p-2 pb-3 ms-md-1">
<div class="file-header d-flex align-items-center">
<a
href="#"
data-bs-toggle="tooltip"
title="DMS All slides"
class="file-title d-flex align-items-center"
>
<p class="text-truncate m-0 fw-semibold">DMS All slides</p>
</a>
<div class="dropdown ms-auto">
<button class="file-three-dots btn" id="dropdownMenuButton" data-bs-toggle="dropdown" aria-expanded="false">
<i class="fas fa-ellipsis-v"></i>
</button>
<ul class="dropdown-menu dropdown-menu-end mt-2 rounded-1 border-0" aria-labelledby="dropdownMenuButton" style="box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2)">
<li>
<a class="dropdown-item fw-light py-1" style="font-size: 15px;" href="#">
<img src="./img/open_file_icon.png" style="width: 18px;" class="me-1 ms-0" alt="">
Open
</a>
</li>
<li>
<a class="dropdown-item fw-light py-1" style="font-size: 15px;" href="#">
<img src="./img/download_icon.png" style="width: 18px;" class="me-1 ms-0" alt="">
Download
</a>
</li>
<li>
<a class="dropdown-item fw-light py-1" style="font-size: 15px;" href="#">
<img src="./img/star_icon.png" style="width: 18px;" class="me-1 ms-0" alt="">
Starred
</a>
</li>
</ul>
</div>
</div>
<a href="">
<div class="file-preview rounded-4 d-flex justify-content-center">
<img src="./img/pdf.png" alt="PDF" />
</div>
</a>
</div>-->
</div>
</div>
</div>
<!-- Modal for New Folder -->
<div class="modal fade" id="newFolderModal" tabindex="-1" aria-labelledby="newFolderModalLabel" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered" style="width: fit-content;">
<div class="modal-content px-2 py-4 rounded-3">
<h4 class="modal-title ms-3" id="newFolderModalLabel">New Folder</h4>
<div class="modal-body">
<input type="text" class="form-control rounded-2" id="newFolderName" style="width:310px;height:46px;border:1px solid black;" placeholder="Untitled Folder">
</div>
<div class="d-flex mt-2">
<button type="button" class="btn ms-auto me-3 new-action-button rounded-3" data-bs-dismiss="modal">Cancel</button>
<button type="button" class="btn me-3 new-action-button rounded-3" id="createFolderBtn">Create</button>
</div>
</div>
</div>
</div>
</body>
<!-- Bootstrap and Popper.js scripts for enabling interactivity such as sidebar toggle -->
<script
src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/js/bootstrap.bundle.min.js"
integrity="sha384-kenU1KFdBIe4zVF0s0G1M5b4hcpxyD9F7jL+jjXkk+Q2h455rYXK/7HAuoJl+0I4"
crossorigin="anonymous"
></script>
</html>