Create app.py
Browse files
app.py
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import streamlit as st
|
| 2 |
+
import calendar
|
| 3 |
+
|
| 4 |
+
# Function to display the full calendar for a specific month and year
|
| 5 |
+
def display_full_calendar(year, month):
|
| 6 |
+
# Display the entire month calendar
|
| 7 |
+
st.write(f"### {calendar.month_name[month]} {year}")
|
| 8 |
+
st.text(calendar.month(year, month))
|
| 9 |
+
|
| 10 |
+
# Streamlit app title
|
| 11 |
+
st.title('2025 Calendar Viewer')
|
| 12 |
+
|
| 13 |
+
# Get user input for the month and year (default to 2025)
|
| 14 |
+
year = 2025
|
| 15 |
+
month = st.slider('Select month:', 1, 12, 1)
|
| 16 |
+
|
| 17 |
+
# Display the calendar for the selected month of the year 2025
|
| 18 |
+
display_full_calendar(year, month)
|
| 19 |
+
|
| 20 |
+
# Optionally, display all months in 2025
|
| 21 |
+
if st.checkbox('Show all months for 2025'):
|
| 22 |
+
for month in range(1, 13):
|
| 23 |
+
display_full_calendar(year, month)
|