Spaces:
Sleeping
Sleeping
File size: 1,716 Bytes
10e4cb6 1af4b74 72d0e7a 5e0383e 72d0e7a 5e0383e 72d0e7a 5e0383e 1af4b74 5e0383e 1af4b74 5e0383e 1af4b74 5e0383e 72d0e7a 1af4b74 5e0383e 72d0e7a 1af4b74 10e4cb6 72d0e7a 10e4cb6 72d0e7a 10e4cb6 72d0e7a |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
import streamlit as st
# Inject custom CSS for a centered flower with background gradient
st.markdown(
"""
<style>
/* General background with gradient */
html, body, [data-testid="stAppViewContainer"] {
background-image: linear-gradient(
to bottom right,
rgba(135, 206, 250, 0.5), /* Light Sky Blue */
rgba(255, 223, 186, 0.5), /* Soft Peach */
rgba(192, 192, 192, 0.5), /* Bright Silver */
rgba(169, 169, 169, 0.5), /* Gray */
rgba(240, 248, 255, 0.5), /* Alice Blue */
rgba(173, 216, 230, 0.5) /* Light Blue */
);
background-size: cover;
font-family: 'Arial', sans-serif;
position: relative;
}
/* Centered flower */
.flower {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
width: 150px;
height: 150px;
background-image: url("https://upload.wikimedia.org/wikipedia/commons/thumb/3/30/Red_flower.svg/1200px-Red_flower.svg.png");
background-size: contain;
background-repeat: no-repeat;
}
</style>
""",
unsafe_allow_html=True
)
# Add the flower element to the center of the app
st.markdown('<div class="flower"></div>', unsafe_allow_html=True)
# Streamlit UI elements
st.title("Word Cloud Application")
st.markdown("Welcome to the Word Cloud Application with a beautiful flower in the background!")
# Add some interactivity
if st.button("Click Me"):
st.write("You clicked the button!")
# Add a select box
option = st.selectbox(
"Choose an option:",
["Option 1", "Option 2", "Option 3"]
)
st.write(f"You selected: {option}")
|