rudrashah commited on
Commit
e676301
1 Parent(s): d7ddfa1

frontend changes

Browse files
Files changed (3) hide show
  1. .streamlit/config.toml +2 -0
  2. app.py +7 -3
  3. icons8-translate-480.svg +1 -0
.streamlit/config.toml ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ [theme]
2
+ base = "light"
app.py CHANGED
@@ -34,7 +34,7 @@ def translate_hinglish_to_english(text):
34
  return translated_text
35
 
36
  st.title("RLM-Translator")
37
- st.write("A simple Hinglish to English translator from Hugging Face by [Rudra Shah](https://huggingface.co/rudrashah/RLM-hinglish-translator).")
38
 
39
  col1, col2 = st.columns(2)
40
 
@@ -49,8 +49,12 @@ with col2:
49
 
50
  if st.button("Translate", use_container_width=True, type="primary"):
51
  if hinglish_text != "":
52
- translated_text = translate_hinglish_to_english(hinglish_text)
53
- st.session_state["translated_text"] = translated_text
 
54
  st.rerun()
55
  else:
56
  st.error("Please enter some hinglish text to translate.")
 
 
 
 
34
  return translated_text
35
 
36
  st.title("RLM-Translator")
37
+ st.write("A simple Hinglish to English translator. Enter your Hinglish text and click on Translate to get the English translation.")
38
 
39
  col1, col2 = st.columns(2)
40
 
 
49
 
50
  if st.button("Translate", use_container_width=True, type="primary"):
51
  if hinglish_text != "":
52
+ with st.spinner("Translating..."):
53
+ translated_text = translate_hinglish_to_english(hinglish_text)
54
+ st.session_state["translated_text"] = translated_text
55
  st.rerun()
56
  else:
57
  st.error("Please enter some hinglish text to translate.")
58
+
59
+ st.markdown("*This is in beta Development. Translator might give incorrect results.*")
60
+ st.markdown("Made with ❤️ by [Rudra Shah](https://huggingface.co/rudrashah).")
icons8-translate-480.svg ADDED