coollsd commited on
Commit
5ad161e
·
verified ·
1 Parent(s): 88482c1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -15
app.py CHANGED
@@ -18,7 +18,7 @@ HTML_CONTENT = """
18
  body {
19
  font-family: 'Poppins', sans-serif;
20
  background: #121212;
21
- min-height: 100vh;
22
  margin: 0;
23
  display: flex;
24
  justify-content: center;
@@ -34,19 +34,9 @@ HTML_CONTENT = """
34
  border: 1px solid rgba(255, 255, 255, 0.18);
35
  text-align: center;
36
  max-width: 450px;
37
- width: 90%;
38
  transition: all 0.3s ease;
39
  }
40
- @media (min-width: 768px) {
41
- .container {
42
- width: 60%;
43
- }
44
- }
45
- @media (min-width: 1200px) {
46
- .container {
47
- width: 40%;
48
- }
49
- }
50
  .container:hover {
51
  background: rgba(255, 255, 255, 0.2);
52
  transform: translateY(-5px);
@@ -186,7 +176,7 @@ HTML_CONTENT = """
186
  <div class="container">
187
  <h1>Pro File Uploader</h1>
188
  <form id="uploadForm">
189
- <input type="file" name="files" id="files" class="file-input" accept=".zip,.mp4,.mp3,image/*,.pdf,.txt" required multiple>
190
  <label for="files" class="btn">Choose Files</label>
191
  <div class="file-name" id="fileName"></div>
192
  <button type="button" id="uploadBtn" class="btn" style="display: none; margin-top: 1rem;">Upload Files</button>
@@ -195,7 +185,7 @@ HTML_CONTENT = """
195
  </form>
196
  <div class="result-container" id="resultContainer"></div>
197
  <div class="file-types">
198
- Allowed file types: .zip, .mp4, .mp3, all image types, .pdf, .txt
199
  </div>
200
  </div>
201
 
@@ -401,7 +391,7 @@ async def initiate_upload(cookies: Dict[str, str], filename: str, content_type:
401
  'Sec-GPC': '1',
402
  'Priority': 'u=1, i'
403
  })
404
- print(f'Initiate upload response status: {response.status_code}')
405
  print(f'Initiate upload response headers: {response.headers}')
406
  print(f'Response body: {response.text}')
407
  return response.json()
 
18
  body {
19
  font-family: 'Poppins', sans-serif;
20
  background: #121212;
21
+ height: 100vh;
22
  margin: 0;
23
  display: flex;
24
  justify-content: center;
 
34
  border: 1px solid rgba(255, 255, 255, 0.18);
35
  text-align: center;
36
  max-width: 450px;
37
+ width: 100%;
38
  transition: all 0.3s ease;
39
  }
 
 
 
 
 
 
 
 
 
 
40
  .container:hover {
41
  background: rgba(255, 255, 255, 0.2);
42
  transform: translateY(-5px);
 
176
  <div class="container">
177
  <h1>Pro File Uploader</h1>
178
  <form id="uploadForm">
179
+ <input type="file" name="files" id="files" class="file-input" accept=".zip,.mp4,.txt,.mp3,image/*,.pdf" required multiple>
180
  <label for="files" class="btn">Choose Files</label>
181
  <div class="file-name" id="fileName"></div>
182
  <button type="button" id="uploadBtn" class="btn" style="display: none; margin-top: 1rem;">Upload Files</button>
 
185
  </form>
186
  <div class="result-container" id="resultContainer"></div>
187
  <div class="file-types">
188
+ Allowed file types: .zip, .mp4, .txt,.mp3, all image types, .pdf
189
  </div>
190
  </div>
191
 
 
391
  'Sec-GPC': '1',
392
  'Priority': 'u=1, i'
393
  })
394
+ print(f'Initiate upload response status: {response.status_code}')
395
  print(f'Initiate upload response headers: {response.headers}')
396
  print(f'Response body: {response.text}')
397
  return response.json()