From ac390fc42fafd8523fe4c18582a2b23fbd544815 Mon Sep 17 00:00:00 2001 From: supunTE Date: Sun, 26 Feb 2023 16:55:43 +0530 Subject: [PATCH 1/2] initialize client --- client.py | 0 client/main.py | 20 ++++++++++++++++++++ client/style.css | 4 ++++ requirements.txt | 1 + 4 files changed, 25 insertions(+) delete mode 100644 client.py create mode 100644 client/main.py create mode 100644 client/style.css create mode 100644 requirements.txt diff --git a/client.py b/client.py deleted file mode 100644 index e69de29..0000000 diff --git a/client/main.py b/client/main.py new file mode 100644 index 0000000..6184e13 --- /dev/null +++ b/client/main.py @@ -0,0 +1,20 @@ +import streamlit as st +import os + +st.set_page_config(page_title="SummarizeIt", page_icon=":page_facing_up:") +st.title("Summarize it") + +# Adding styles +script_dir = os.path.dirname(__file__) +def local_css(file_name): + abs_path_dir = os.path.join(script_dir, file_name) + with open(abs_path_dir) as f: + st.markdown(f'', unsafe_allow_html=True) +local_css("style.css") + +st.text_input("Input URL to Research Paper") +selectable_tags = ['Beginner', 'Sample Tag', 'Tag2', 'Tag3'] +default_tags = ['Beginner'] +tags = st.multiselect( + 'Select tags', + selectable_tags, default_tags) diff --git a/client/style.css b/client/style.css new file mode 100644 index 0000000..4dc3526 --- /dev/null +++ b/client/style.css @@ -0,0 +1,4 @@ +@import url('https://fonts.googleapis.com/css2?family=Fira+Sans:ital,wght@0,200;0,400;0,600;1,200;1,400;1,500&display=swap'); +html, body, [class*="css"] { + font-family: 'Fira Sans', sans-serif; +} \ No newline at end of file diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..e1bccf6 --- /dev/null +++ b/requirements.txt @@ -0,0 +1 @@ +streamlit~=1.18.1 \ No newline at end of file From b09fb33ba0d36891e25c19ce44cb9371d84248dd Mon Sep 17 00:00:00 2001 From: supunTE Date: Sun, 26 Feb 2023 17:10:54 +0530 Subject: [PATCH 2/2] add run frontend command to README.md --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index b1f97de..6627ed5 100644 --- a/README.md +++ b/README.md @@ -10,3 +10,8 @@ {app} - client/server {#} - issue number {name} - branch name + +## Commands + +To run frontend - +`streamlit run client/main.py`