update readme, style
authorClaromes <claromes@hey.com>
Sat, 13 May 2023 02:28:19 +0000 (23:28 -0300)
committerClaromes <claromes@hey.com>
Sat, 13 May 2023 02:28:19 +0000 (23:28 -0300)
README.md
app.py

index 343adba03103dec4d147f7d1c6ebc0798e3fe979..bd4361b7b1b7dd9586c4daca1a3079e970e15b5a 100644 (file)
--- a/README.md
+++ b/README.md
@@ -6,12 +6,30 @@ Archived tweets on Wayback Machine in a easy way
 
 *Thanks Tristan Lee for the idea.*
 
+## Development
+
+### Requirements
+
+- Python 3.8+
+
+### Installation
+
+$ `git clone git@github.com:claromes/waybacktweets.git`
+
+$ `cd waybacktweets`
+
+$ `pip install -r requirements.txt`
+
+$ `streamlit run app.py`
+
+Streamlit will be served at http://localhost:8501
+
 ## Bugs
 
 - [ ] "web.archive.org took too long to respond."
 - [x] `only_deleted` checkbox selected for handles without deleted tweets
 
-## TODO
+## Roadmap
 
 - [ ] Feedbacks
 - [ ] Pagination
diff --git a/app.py b/app.py
index af7689e13fcfedb90a4846ef9159b618260a7cb4..5b2fecd4ad4bebb25bc09992bd58a5dc4ea5895c 100644 (file)
--- a/app.py
+++ b/app.py
@@ -13,32 +13,36 @@ st.set_page_config(
 
 # https://discuss.streamlit.io/t/remove-hide-running-man-animation-on-top-of-page/21773/3
 hide_streamlit_style = """
-                <style>
-                div[data-testid="stToolbar"] {
-                visibility: hidden;
-                height: 0%;
-                position: fixed;
-                }
-                div[data-testid="stDecoration"] {
-                visibility: hidden;
-                height: 0%;
-                position: fixed;
-                }
-                div[data-testid="stStatusWidget"] {
-                visibility: hidden;
-                height: 0%;
-                position: fixed;
-                }
-                #MainMenu {
-                visibility: hidden;
-                height: 0%;
-                }
-                header {
-                visibility: hidden;
-                height: 0%;
-                }
-                </style>
-                """
+<style>
+    div[data-testid="stToolbar"] {
+    visibility: hidden;
+    height: 0%;
+    position: fixed;
+    }
+    div[data-testid="stDecoration"] {
+    visibility: hidden;
+    height: 0%;
+    position: fixed;
+    }
+    div[data-testid="stStatusWidget"] {
+    visibility: hidden;
+    height: 0%;
+    position: fixed;
+    }
+    #MainMenu {
+    visibility: hidden;
+    height: 0%;
+    }
+    header {
+    visibility: hidden;
+    height: 0%;
+    }
+    footer {
+    visibility: hidden;
+    height: 0%;
+    }
+</style>
+"""
 st.markdown(hide_streamlit_style, unsafe_allow_html=True)
 
 def embed(tweet):
@@ -85,7 +89,7 @@ def attr(i):
     {}. **Wayback Machine:** [link]({}) | **MIME Type:** {} | **From:** {} | **Tweet:** [link]({})
     '''.format(i+1, link, mimetype[i], datetime.datetime.strptime(timestamp[i], "%Y%m%d%H%M%S"), tweet_links[i]))
 
-st.title('Wayback Tweets', anchor=False)
+st.title('Wayback Tweets [![GitHub stars](https://img.shields.io/github/stars/claromes/waybacktweets?style=social)](https://github.com/claromes/waybacktweets)', anchor=False)
 st.write('Archived tweets on Wayback Machine')
 
 handle = st.text_input('username', placeholder='username', label_visibility='collapsed')