Skip to content

Commit

Permalink
updated home.py
Browse files Browse the repository at this point in the history
  • Loading branch information
revanth1718 committed Jun 7, 2024
1 parent c5985e4 commit e87352c
Showing 1 changed file with 33 additions and 5 deletions.
38 changes: 33 additions & 5 deletions streamlit/home.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,40 @@
# Filter the 2020 dataframe
df2020 = df[df['SalaryUSD'] < 200000]

# Load CSS file
def local_css(file_name):
with open(file_name) as f:
st.markdown(f'<style>{f.read()}</style>', unsafe_allow_html=True)
#######################################
# CSS STYLING
#######################################

css = """
<style>
.analysis-container {
font-family: 'Courier New', Courier, monospace;
background-color: #D8DEDF;
padding: 15px;
border-radius: 10px;
margin-top: 150px;
margin-bottom: 110px;
}
.analysis-container-extra {
font-family: 'Courier New', Courier, monospace;
background-color: #D8DEDF;
padding: 15px;
border-radius: 10px;
margin-top: 50px;
margin-bottom: 20px;
}
.analysis-title {
font-size: 18px;
font-weight: bold;
color: #333333;
margin-bottom: 10px;
}
</style>
"""

local_css("https://raw.githubusercontent.com/Recode-Hive/Stackoverflow-Analysis/main/streamlit/style.css")
st.markdown(css, unsafe_allow_html=True)

#######################################
# DATA PREPARATION FOR VISUALISATION
Expand Down

0 comments on commit e87352c

Please sign in to comment.