Alannikos768 commited on
Commit
db78a80
1 Parent(s): 20a060a

first config

Browse files
Files changed (1) hide show
  1. app.py +67 -0
app.py ADDED
@@ -0,0 +1,67 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import os
2
+ import sys
3
+ import streamlit as st
4
+
5
+ def sidebar_content():
6
+
7
+ st.sidebar.markdown("### 欢迎关注")
8
+
9
+ st.sidebar.markdown("""
10
+ <style>
11
+ .sidebar-link {
12
+ display: inline-flex;
13
+ align-items: center;
14
+ margin: 0px 10px 10px 0px;
15
+ padding: 5px 10px;
16
+ text-decoration: none;
17
+ border-radius: 5px;
18
+ border: 1px solid #ddd;
19
+ color: #000; /* 黑色文字 */
20
+ background-color: #ffcc00; /* 黄色背景 */
21
+ }
22
+ .sidebar-link:hover {
23
+ background-color: #e6b800; /* 深黄色 */
24
+ }
25
+ .sidebar-link img {
26
+ width: 20px;
27
+ height: 20px;
28
+ margin-right: 5px;
29
+ }
30
+ </style>
31
+
32
+ <a href="https://github.com/Alannikos" target="_blank" class="sidebar-link">
33
+ <img src="https://cdn.jsdelivr.net/npm/simple-icons@13.7.0/icons/github.svg" alt="GitHub"> GitHub
34
+ </a>
35
+ <a href="https://space.bilibili.com/3494365446015137" target="_blank" class="sidebar-link">
36
+ <img src="https://cdn.jsdelivr.net/npm/simple-icons@13.7.0/icons/bilibili.svg" alt="Bilibili"> Bilibili
37
+ </a>
38
+ <a href="https://huggingface.co/" target="_blank" class="sidebar-link">
39
+ <img src="https://cdn.jsdelivr.net/npm/simple-icons@13.7.0/icons/huggingface.svg" alt="Hugging Face"> Hugging Face
40
+ </a>
41
+ """, unsafe_allow_html=True)
42
+
43
+ # 在侧边栏底部添加内容
44
+ st.sidebar.markdown("---")
45
+ st.sidebar.markdown("### 关于我们")
46
+ st.sidebar.markdown("FunGPT --- 智能情感调酒师")
47
+ st.sidebar.markdown("© 2024 FunGPT Team")
48
+ st.sidebar.markdown("[联系我们](#) | [使用条款](#)")
49
+
50
+ def main():
51
+ st.set_page_config(
52
+ page_title="FunGPT App",
53
+ page_icon="🧊",
54
+ layout="centered",
55
+ initial_sidebar_state="expanded",
56
+ menu_items={
57
+ 'Get Help': 'https://www.extremelycoolapp.com/help',
58
+ 'Report a bug': "https://www.extremelycoolapp.com/bug",
59
+ 'About': "# This is a header. This is an *extremely* cool app!"
60
+ }
61
+ )
62
+ st.title("FunGPT - 您的情感调酒师🍹")
63
+
64
+ sidebar_content()
65
+
66
+ if __name__ == '__main__':
67
+ main()