MARI-posa commited on
Commit
8167cc8
1 Parent(s): 8bfdd6d

Update pages/book.py

Browse files
Files changed (1) hide show
  1. pages/book.py +30 -0
pages/book.py CHANGED
@@ -9,6 +9,36 @@ import pickle
9
  import requests
10
  from io import BytesIO
11
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
12
  st.title("Книжные рекомендации")
13
 
14
  # Загрузка модели и токенизатора
 
9
  import requests
10
  from io import BytesIO
11
 
12
+ import base64
13
+ import streamlit as st
14
+ import plotly.express as px
15
+
16
+ page_bg_img = f"""
17
+ <style>
18
+ [data-testid="stAppViewContainer"] > .main {{
19
+ background-image: url("https://i.ibb.co/8dKsZpV/black-and-white-books-piled-stacks.jpg");
20
+ background-size: 130%;
21
+ background-position: top left;
22
+ background-repeat: no-repeat;
23
+ background-attachment: local;
24
+ }}
25
+ [data-testid="stHeader"] {{
26
+ background: rgba(1,1,1,1);
27
+ }}
28
+ [data-testid="stToolbar"] {{
29
+ right: 2rem;
30
+ }}
31
+ div.css-1n76uvr.esravye0 {{
32
+ background-color: rgba(238, 238, 238, 0.5);
33
+ border: 10px solid #EEEEEE;
34
+ padding: 5% 5% 5% 10%;
35
+ border-radius: 5px;
36
+ }}
37
+ </style>
38
+ """
39
+ st.markdown(page_bg_img, unsafe_allow_html=True)
40
+
41
+
42
  st.title("Книжные рекомендации")
43
 
44
  # Загрузка модели и токенизатора