DinoPLayZ commited on
Commit
777d78d
Β·
verified Β·
1 Parent(s): 418d0e5

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +111 -12
main.py CHANGED
@@ -749,24 +749,123 @@ async def root(request: Request):
749
 
750
  return f"""
751
  <!DOCTYPE html>
752
- <html>
753
  <head>
 
 
754
  <title>BIP Auto Notifier</title>
 
755
  <style>
756
- body {{ font-family: monospace; background-color: #0d1117; color: #c9d1d9; padding: 20px; font-size: 14px; }}
757
- a {{ color: #58a6ff; text-decoration: none; }}
758
- a:hover {{ text-decoration: underline; }}
759
- pre {{ background-color: #161b22; padding: 20px; border-radius: 6px; display: inline-block; }}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
760
  </style>
761
  </head>
762
  <body>
763
- <pre>{{
764
- "app": "BIP Auto Notifier",
765
- "status": "healthy",
766
- "message": "Background tracker running πŸš€",
767
- "health_endpoint": "<a href="{health_url}">{health_url}</a>",
768
- "assistant_endpoint": "<a href="{assistant_url}">{assistant_url}</a>"
769
- }}</pre>
 
 
 
 
 
 
 
 
 
 
 
770
  </body>
771
  </html>
772
  """
 
749
 
750
  return f"""
751
  <!DOCTYPE html>
752
+ <html lang="en">
753
  <head>
754
+ <meta charset="UTF-8">
755
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
756
  <title>BIP Auto Notifier</title>
757
+ <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap" rel="stylesheet">
758
  <style>
759
+ body {{
760
+ font-family: 'Inter', sans-serif;
761
+ background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
762
+ color: #f8fafc;
763
+ margin: 0;
764
+ display: flex;
765
+ flex-direction: column;
766
+ justify-content: center;
767
+ align-items: center;
768
+ min-height: 100vh;
769
+ padding: 20px;
770
+ box-sizing: border-box;
771
+ }}
772
+ .container {{
773
+ background: rgba(255, 255, 255, 0.05);
774
+ backdrop-filter: blur(10px);
775
+ -webkit-backdrop-filter: blur(10px);
776
+ border: 1px solid rgba(255, 255, 255, 0.1);
777
+ border-radius: 16px;
778
+ padding: 40px;
779
+ max-width: 600px;
780
+ width: 100%;
781
+ box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
782
+ text-align: center;
783
+ }}
784
+ h1 {{
785
+ font-size: 2.5rem;
786
+ margin-bottom: 10px;
787
+ background: linear-gradient(to right, #60a5fa, #c084fc);
788
+ -webkit-background-clip: text;
789
+ -webkit-text-fill-color: transparent;
790
+ font-weight: 700;
791
+ }}
792
+ p.status {{
793
+ font-size: 1.1rem;
794
+ color: #94a3b8;
795
+ margin-bottom: 30px;
796
+ display: flex;
797
+ align-items: center;
798
+ justify-content: center;
799
+ gap: 8px;
800
+ }}
801
+ .indicator {{
802
+ width: 10px;
803
+ height: 10px;
804
+ background-color: #22c55e;
805
+ border-radius: 50%;
806
+ display: inline-block;
807
+ box-shadow: 0 0 10px #22c55e;
808
+ }}
809
+ .links {{
810
+ display: flex;
811
+ flex-direction: column;
812
+ gap: 15px;
813
+ }}
814
+ a.btn {{
815
+ background: rgba(255, 255, 255, 0.1);
816
+ border: 1px solid rgba(255, 255, 255, 0.2);
817
+ color: #e2e8f0;
818
+ padding: 15px 20px;
819
+ border-radius: 12px;
820
+ text-decoration: none;
821
+ font-size: 1.1rem;
822
+ font-weight: 600;
823
+ transition: all 0.3s ease;
824
+ display: flex;
825
+ justify-content: space-between;
826
+ align-items: center;
827
+ }}
828
+ a.btn span.arrow {{
829
+ opacity: 0;
830
+ transform: translateX(-10px);
831
+ transition: all 0.3s ease;
832
+ }}
833
+ a.btn:hover {{
834
+ background: rgba(255, 255, 255, 0.2);
835
+ border-color: rgba(255, 255, 255, 0.4);
836
+ transform: translateY(-2px);
837
+ box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
838
+ }}
839
+ a.btn:hover span.arrow {{
840
+ opacity: 1;
841
+ transform: translateX(0);
842
+ }}
843
+ .footer {{
844
+ margin-top: 30px;
845
+ font-size: 0.9rem;
846
+ color: #64748b;
847
+ }}
848
  </style>
849
  </head>
850
  <body>
851
+ <div class="container">
852
+ <h1>BIP Auto Notifier</h1>
853
+ <p class="status"><span class="indicator"></span> System is Healthy & Tracking πŸš€</p>
854
+
855
+ <div class="links">
856
+ <!-- Added target="_blank" to fix iframe loading issues -->
857
+ <a href="{health_url}" target="_blank" rel="noopener noreferrer" class="btn">
858
+ <span>πŸ₯ Check Real-Time Health Status</span>
859
+ <span class="arrow">β†’</span>
860
+ </a>
861
+ <a href="{assistant_url}" target="_blank" rel="noopener noreferrer" class="btn">
862
+ <span>πŸ€– View Full Assistant Data</span>
863
+ <span class="arrow">β†’</span>
864
+ </a>
865
+ </div>
866
+
867
+ <p class="footer">Cloud Notifier Interface</p>
868
+ </div>
869
  </body>
870
  </html>
871
  """