TrungLC commited on
Commit
6bcfe02
·
verified ·
1 Parent(s): 38a2a29

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -37
app.py CHANGED
@@ -239,8 +239,10 @@ def process_files(thuoc_file, xetnghiem_file, thuoc_plt_file, icd_plt_file):
239
  return output_text, file1, file2, file3, file4, file5, filerealtime
240
 
241
 
242
- with gr.Blocks(title="triggertool PLT", css="""
243
- /* ===== HEADER ===== */
 
 
244
  #plt-header {
245
  background: linear-gradient(135deg, #e65c00 0%, #d44c00 45%, #b33b00 100%);
246
  border-radius: 16px; padding: 28px 40px; margin-bottom: 18px;
@@ -255,12 +257,6 @@ with gr.Blocks(title="triggertool PLT", css="""
255
  pointer-events: none;
256
  }
257
  #plt-ecg { position:absolute; bottom:6px; left:0; right:0; width:100%; height:20px; opacity:0.12; }
258
- #header-logo-left {
259
- position: absolute; left: 20px; top: 50%; transform: translateY(-50%);
260
- width: 90px; height: 90px; border-radius: 50%; object-fit: cover;
261
- border: 2px solid rgba(255,255,255,0.35);
262
- box-shadow: 0 4px 16px rgba(0,0,0,0.4), 0 0 20px rgba(255,160,60,0.3);
263
- }
264
  #logo-pulse-ring {
265
  position:absolute; left:20px; top:50%; transform:translateY(-50%);
266
  width:90px; height:90px; border-radius:50%;
@@ -277,41 +273,15 @@ with gr.Blocks(title="triggertool PLT", css="""
277
  text-shadow: 0 2px 8px rgba(0,0,0,0.5);
278
  font-family: 'Segoe UI','Arial',sans-serif; margin: 0;
279
  }
280
- #header-separator { width: 60px; height: 2px; background: linear-gradient(to right,transparent,rgba(255,255,255,0.5),transparent); border-radius: 2px; }
281
  #animated-credit {
282
  font-size: 13px; font-weight: 600; color: #FFD700 !important;
283
  min-height: 18px; letter-spacing: 0.3px;
284
- font-family: 'Segoe UI', sans-serif;
285
- text-shadow: 0 1px 6px rgba(0,0,0,0.6);
286
  }
287
  #animated-credit * { color: #FFD700 !important; }
288
  .credit-char { display: inline-block; color: #FFD700 !important; }
289
-
290
- /* ===== SECTION LABELS ===== */
291
- .section-label {
292
- font-size: 13px; font-weight: 700; color: #c84a00;
293
- border-left: 3px solid #e65c00; padding-left: 8px; margin-bottom: 4px;
294
- }
295
-
296
- /* ===== UPLOAD CARDS ===== */
297
- .upload-card {
298
- background: #fff8f5; border: 1px solid #ffd0b0;
299
- border-radius: 10px; padding: 8px 10px;
300
- }
301
-
302
- /* ===== RUN BUTTON ===== */
303
- .run-btn { background: linear-gradient(135deg,#e65c00,#c84a00) !important; color:white !important; border-radius:10px !important; font-weight:700 !important; }
304
-
305
- /* ===== RESULT BOX ===== */
306
- #result-summary textarea {
307
- background: #fff8f5 !important; border: 1px solid #ffd0b0 !important;
308
- border-radius:10px !important; font-size:13px !important;
309
- }
310
-
311
- /* ===== ACCORDION ===== */
312
- .download-accordion { border: 1px solid #ffd0b0 !important; border-radius: 12px !important; }
313
- .download-accordion .label-wrap { background: #fff3ec !important; }
314
- """) as demo:
315
 
316
  # ===== HEADER HTML =====
317
  gr.HTML("""
 
239
  return output_text, file1, file2, file3, file4, file5, filerealtime
240
 
241
 
242
+ with gr.Blocks(title="triggertool PLT") as demo:
243
+
244
+ # ===== INJECT CSS =====
245
+ gr.HTML("""<style>
246
  #plt-header {
247
  background: linear-gradient(135deg, #e65c00 0%, #d44c00 45%, #b33b00 100%);
248
  border-radius: 16px; padding: 28px 40px; margin-bottom: 18px;
 
257
  pointer-events: none;
258
  }
259
  #plt-ecg { position:absolute; bottom:6px; left:0; right:0; width:100%; height:20px; opacity:0.12; }
 
 
 
 
 
 
260
  #logo-pulse-ring {
261
  position:absolute; left:20px; top:50%; transform:translateY(-50%);
262
  width:90px; height:90px; border-radius:50%;
 
273
  text-shadow: 0 2px 8px rgba(0,0,0,0.5);
274
  font-family: 'Segoe UI','Arial',sans-serif; margin: 0;
275
  }
276
+ #header-separator { width:60px; height:2px; background:linear-gradient(to right,transparent,rgba(255,255,255,0.5),transparent); border-radius:2px; }
277
  #animated-credit {
278
  font-size: 13px; font-weight: 600; color: #FFD700 !important;
279
  min-height: 18px; letter-spacing: 0.3px;
280
+ font-family: 'Segoe UI', sans-serif; text-shadow: 0 1px 6px rgba(0,0,0,0.6);
 
281
  }
282
  #animated-credit * { color: #FFD700 !important; }
283
  .credit-char { display: inline-block; color: #FFD700 !important; }
284
+ </style>""")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
285
 
286
  # ===== HEADER HTML =====
287
  gr.HTML("""