freealise commited on
Commit
45a391a
·
1 Parent(s): 48a174a

link to dict

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -71,8 +71,6 @@ output_style = st.selectbox(
71
  # User input
72
  sentence = st.text_input('Enter a sentence to analyze:')
73
 
74
- st.markdown("<iframe src='https://freeali.se/freealise/translate/index.htm' rows='16' cols='32' name='dict' id='dict'></iframe>", unsafe_allow_html=True)
75
-
76
  if sentence:
77
  # Display the input sentence
78
  st.text(sentence)
@@ -105,7 +103,9 @@ if sentence:
105
  for line in ud_output[2:]:
106
  # Each UD line as a table row
107
  cells = line.replace('_', '\\_').replace('|', '&#124;').replace(':', '&colon;').split('\t')
108
- cells[2] = "<iframe src='https://freeali.se/freealise/translate/index.htm#gsc.q="+cells[2]+"&gsc.tab=1&gsc.sort=' width='128' height='64'></iframe><br/><iframe src='https://freeali.se/freealise/translate/loader.htm?q="+cells[2]+"' width='128' height='64'></iframe><a href='https://freeali.se/freealise/translate/index.htm#gsc.q="+cells[2]+"&gsc.tab=1&gsc.sort=' target='dict'>" + cells[2] + "</a>"
 
 
109
  table_md += "| " + " | ".join(cells) + " |\n"
110
  table_md += "</div>" # Close the RTL div
111
  print(table_md)
 
71
  # User input
72
  sentence = st.text_input('Enter a sentence to analyze:')
73
 
 
 
74
  if sentence:
75
  # Display the input sentence
76
  st.text(sentence)
 
103
  for line in ud_output[2:]:
104
  # Each UD line as a table row
105
  cells = line.replace('_', '\\_').replace('|', '&#124;').replace(':', '&colon;').split('\t')
106
+ cells[2] = "<iframe src='https://freeali.se/freealise/translate/index.htm#gsc.q="+cells[2]+"&gsc.tab=1&gsc.sort=' width='256' height='128'></iframe><br/>" +
107
+ "<iframe src='https://freeali.se/freealise/translate/loader.htm?q="+cells[2]+"' width='256' height='128'></iframe><br/>" +
108
+ "<a href='javascript:' onclick=''>" + cells[2] + "</a>"
109
  table_md += "| " + " | ".join(cells) + " |\n"
110
  table_md += "</div>" # Close the RTL div
111
  print(table_md)