Update app.py
Browse files
app.py
CHANGED
|
@@ -8,7 +8,7 @@ import qrcode
|
|
| 8 |
from PIL import Image
|
| 9 |
import io
|
| 10 |
|
| 11 |
-
# 自訂 CSS
|
| 12 |
st.markdown("""
|
| 13 |
<style>
|
| 14 |
.stApp header h1 {
|
|
@@ -33,6 +33,15 @@ st.markdown("""
|
|
| 33 |
.st-ds {
|
| 34 |
justify-content: space-between; /* 兩列間距均等 */
|
| 35 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 36 |
</style>
|
| 37 |
""", unsafe_allow_html=True)
|
| 38 |
|
|
@@ -252,5 +261,8 @@ def main():
|
|
| 252 |
except Exception as e:
|
| 253 |
st.error(f"處理檔案時發生錯誤: {str(e)}")
|
| 254 |
|
|
|
|
|
|
|
|
|
|
| 255 |
if __name__ == "__main__":
|
| 256 |
main()
|
|
|
|
| 8 |
from PIL import Image
|
| 9 |
import io
|
| 10 |
|
| 11 |
+
# 自訂 CSS 確保標題不換行、調整圖片大小、優化按鈕布局並添加右下角資訊
|
| 12 |
st.markdown("""
|
| 13 |
<style>
|
| 14 |
.stApp header h1 {
|
|
|
|
| 33 |
.st-ds {
|
| 34 |
justify-content: space-between; /* 兩列間距均等 */
|
| 35 |
}
|
| 36 |
+
/* 添加右下角資訊 */
|
| 37 |
+
.footer {
|
| 38 |
+
position: fixed;
|
| 39 |
+
bottom: 10px;
|
| 40 |
+
right: 10px;
|
| 41 |
+
font-size: 0.9rem;
|
| 42 |
+
color: #666;
|
| 43 |
+
padding: 5px;
|
| 44 |
+
}
|
| 45 |
</style>
|
| 46 |
""", unsafe_allow_html=True)
|
| 47 |
|
|
|
|
| 261 |
except Exception as e:
|
| 262 |
st.error(f"處理檔案時發生錯誤: {str(e)}")
|
| 263 |
|
| 264 |
+
# 添加右下角資訊
|
| 265 |
+
st.markdown('<div class="footer">程式設計:新竹縣立精華國中 藍星宇老師</div>', unsafe_allow_html=True)
|
| 266 |
+
|
| 267 |
if __name__ == "__main__":
|
| 268 |
main()
|