DOMMETI commited on
Commit
af509d8
Β·
verified Β·
1 Parent(s): 370fdb8

Update Home.py

Browse files
Files changed (1) hide show
  1. Home.py +18 -12
Home.py CHANGED
@@ -7,19 +7,20 @@ st.markdown("""
7
  <style>
8
  @import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600&display=swap');
9
  @import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;600&display=swap');
 
10
  body {
11
  background: linear-gradient(135deg, #1e1e2f, #2a2a3b);
12
  font-family: 'Poppins', sans-serif;
13
  color: white;
14
  }
15
 
16
- /* Header Styling */
17
  h1, h2, h3 {
18
  text-align: center;
19
- color: #00FFFF; /* Bright Cyan */
20
  text-shadow: 0px 0px 12px rgba(0, 255, 255, 1),
21
  0px 0px 20px rgba(0, 128, 255, 0.8);
22
  }
 
23
  .custom-subheader {
24
  color: #00FFFF;
25
  font-family: 'Roboto', sans-serif;
@@ -28,7 +29,7 @@ st.markdown("""
28
  margin-bottom: 15px;
29
  text-align: center;
30
  }
31
- /* Section Background */
32
  .section {
33
  background: rgba(255, 255, 255, 0.1);
34
  padding: 20px;
@@ -36,7 +37,7 @@ st.markdown("""
36
  margin-bottom: 30px;
37
  box-shadow: 0px 4px 12px rgba(0, 255, 255, 0.2);
38
  }
39
- /* Glowing Button */
40
  .glow-button {
41
  background: linear-gradient(90deg, #00FFFF, #00CCFF);
42
  border: none;
@@ -52,10 +53,12 @@ st.markdown("""
52
  font-size: 16px;
53
  margin: 10px 5px;
54
  }
 
55
  .glow-button:hover {
56
  transform: scale(1.1);
57
  box-shadow: 0px 0px 20px rgba(0, 255, 255, 1);
58
  }
 
59
  .button-container {
60
  text-align: center;
61
  margin-top: 15px;
@@ -64,11 +67,10 @@ st.markdown("""
64
  </style>
65
  """, unsafe_allow_html=True)
66
 
67
-
68
  # Title
69
  st.markdown("<h1 class='custom-subheader'>🏏 Crick-o-Meter: Unleashing Data-Driven Cricket Insights! πŸ“ŠπŸ”₯</h1>", unsafe_allow_html=True)
70
 
71
- # Lottie Animation
72
  @st.cache_data
73
  def load_lottie_url(url: str):
74
  response = requests.get(url)
@@ -77,7 +79,11 @@ def load_lottie_url(url: str):
77
  return response.json()
78
 
79
  lottie_animation = load_lottie_url("https://lottie.host/6e182649-61a6-4683-8680-5493855ac08a/G0pStmcS8T.json")
80
- st_lottie(lottie_animation, height=200, key="cricket")
 
 
 
 
81
 
82
  # About the App
83
  st.markdown('<div class="section">', unsafe_allow_html=True)
@@ -106,12 +112,12 @@ st.markdown('</div>', unsafe_allow_html=True)
106
  st.markdown('<div class="section">', unsafe_allow_html=True)
107
  st.markdown("<h2 class='custom-subheader'>πŸ“ž Contact Me</h2>", unsafe_allow_html=True)
108
 
109
- # Button Section (Now Centered with Space)
110
  st.markdown('<div class="button-container">', unsafe_allow_html=True)
111
  st.markdown("""
112
- [<button class="glow-button">LinkedIn</button>](https://www.linkedin.com/in/dommeti-thoran-raj-692769191/)
113
- [<button class="glow-button">GitHub</button>](https://github.com/raj2216)
114
- [<button class="glow-button">Email</button>](mailto:rajbunny2216@gmail.com)
115
  """, unsafe_allow_html=True)
116
- st.markdown('</div>', unsafe_allow_html=True
117
 
 
7
  <style>
8
  @import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600&display=swap');
9
  @import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;600&display=swap');
10
+
11
  body {
12
  background: linear-gradient(135deg, #1e1e2f, #2a2a3b);
13
  font-family: 'Poppins', sans-serif;
14
  color: white;
15
  }
16
 
 
17
  h1, h2, h3 {
18
  text-align: center;
19
+ color: #00FFFF;
20
  text-shadow: 0px 0px 12px rgba(0, 255, 255, 1),
21
  0px 0px 20px rgba(0, 128, 255, 0.8);
22
  }
23
+
24
  .custom-subheader {
25
  color: #00FFFF;
26
  font-family: 'Roboto', sans-serif;
 
29
  margin-bottom: 15px;
30
  text-align: center;
31
  }
32
+
33
  .section {
34
  background: rgba(255, 255, 255, 0.1);
35
  padding: 20px;
 
37
  margin-bottom: 30px;
38
  box-shadow: 0px 4px 12px rgba(0, 255, 255, 0.2);
39
  }
40
+
41
  .glow-button {
42
  background: linear-gradient(90deg, #00FFFF, #00CCFF);
43
  border: none;
 
53
  font-size: 16px;
54
  margin: 10px 5px;
55
  }
56
+
57
  .glow-button:hover {
58
  transform: scale(1.1);
59
  box-shadow: 0px 0px 20px rgba(0, 255, 255, 1);
60
  }
61
+
62
  .button-container {
63
  text-align: center;
64
  margin-top: 15px;
 
67
  </style>
68
  """, unsafe_allow_html=True)
69
 
 
70
  # Title
71
  st.markdown("<h1 class='custom-subheader'>🏏 Crick-o-Meter: Unleashing Data-Driven Cricket Insights! πŸ“ŠπŸ”₯</h1>", unsafe_allow_html=True)
72
 
73
+ # Load Lottie Animation
74
  @st.cache_data
75
  def load_lottie_url(url: str):
76
  response = requests.get(url)
 
79
  return response.json()
80
 
81
  lottie_animation = load_lottie_url("https://lottie.host/6e182649-61a6-4683-8680-5493855ac08a/G0pStmcS8T.json")
82
+
83
+ if lottie_animation:
84
+ st_lottie(lottie_animation, height=200, key="cricket")
85
+ else:
86
+ st.error("⚠️ Failed to load animation. Please check your internet connection.")
87
 
88
  # About the App
89
  st.markdown('<div class="section">', unsafe_allow_html=True)
 
112
  st.markdown('<div class="section">', unsafe_allow_html=True)
113
  st.markdown("<h2 class='custom-subheader'>πŸ“ž Contact Me</h2>", unsafe_allow_html=True)
114
 
115
+ # Buttons with Links
116
  st.markdown('<div class="button-container">', unsafe_allow_html=True)
117
  st.markdown("""
118
+ <a href="https://www.linkedin.com/in/dommeti-thoran-raj-692769191/" target="_blank"><button class="glow-button">LinkedIn</button></a>
119
+ <a href="https://github.com/raj2216" target="_blank"><button class="glow-button">GitHub</button></a>
120
+ <a href="mailto:rajbunny2216@gmail.com"><button class="glow-button">Email</button></a>
121
  """, unsafe_allow_html=True)
122
+ st.markdown('</div>', unsafe_allow_html=True)
123