thak123 commited on
Commit
9fa869e
1 Parent(s): e411d54

Update index.py

Browse files
Files changed (1) hide show
  1. index.py +14 -6
index.py CHANGED
@@ -56,8 +56,8 @@ df_neu = counts[[x in ['neutral'] for x in counts.FinBERT_label]]
56
  df_neg = counts[[x in ['negative'] for x in counts.FinBERT_label]]
57
 
58
 
59
-
60
- # app.layout = dbc.Container([
61
  dbc.Row([ # row 1
62
  dbc.Col([html.H1('Evolução temporal de sentimento em títulos de notícias')],
63
  className="text-center mt-3 mb-1")]),
@@ -371,13 +371,21 @@ def update_output(selected_topic, selected_domain, start_date, end_date):
371
  # )
372
  # def update_headlines_table(selected_topic, selected_domain, start_date, end_date):
373
  # # Filtering data...
 
 
 
 
 
 
 
 
374
 
375
  app.layout = html.Div(
376
  [
377
  dbc.Tabs(
378
  [
379
- dbc.Tab(label="Tab 1", tab_id="tab-1"),
380
- dbc.Tab(label="Tab 2", tab_id="tab-2"),
381
  ],
382
  id="tabs",
383
  active_tab="tab-1",
@@ -389,9 +397,9 @@ app.layout = html.Div(
389
  @app.callback(Output("content", "children"), [Input("tabs", "active_tab")])
390
  def switch_tab(at):
391
  if at == "tab-1":
392
- return tab1_content
393
  elif at == "tab-2":
394
- return tab2_content
395
  return html.P("This shouldn't ever be displayed...")
396
 
397
  if __name__ == '__main__':
 
56
  df_neg = counts[[x in ['negative'] for x in counts.FinBERT_label]]
57
 
58
 
59
+ # app.layout
60
+ tab_content_1 = dbc.Container([
61
  dbc.Row([ # row 1
62
  dbc.Col([html.H1('Evolução temporal de sentimento em títulos de notícias')],
63
  className="text-center mt-3 mb-1")]),
 
371
  # )
372
  # def update_headlines_table(selected_topic, selected_domain, start_date, end_date):
373
  # # Filtering data...
374
+ tab_content_2 = dcc.Markdown('''
375
+
376
+ # This is an <h1> tag
377
+
378
+ ## This is an <h2> tag
379
+
380
+ ###### This is an <h6> tag
381
+ ''')
382
 
383
  app.layout = html.Div(
384
  [
385
  dbc.Tabs(
386
  [
387
+ dbc.Tab(label="SentDiário", tab_id="tab-1"),
388
+ dbc.Tab(label="Sobre o projeto", tab_id="tab-2"),
389
  ],
390
  id="tabs",
391
  active_tab="tab-1",
 
397
  @app.callback(Output("content", "children"), [Input("tabs", "active_tab")])
398
  def switch_tab(at):
399
  if at == "tab-1":
400
+ return tab_content_1
401
  elif at == "tab-2":
402
+ return tab_content_2
403
  return html.P("This shouldn't ever be displayed...")
404
 
405
  if __name__ == '__main__':