Skip to content

Commit

Permalink
Fix double footer in DOM (#324)
Browse files Browse the repository at this point in the history
* remove double divs inside footer

* dash run scripts in footer - footer must be unique - version number in div

* All page content must be contained by landmarks - set role

* role not unique - removed

* not valid aria value

* move stray element

* move version to aside element

* remove div version
  • Loading branch information
tilen1976 authored Apr 29, 2024
1 parent 75f919a commit a0f4b56
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 18 deletions.
7 changes: 1 addition & 6 deletions src/datadoc/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,12 +74,7 @@ def build_app(app: type[Dash]) -> Dash:
],
className="main-content-app",
),
html.Footer(
[
build_footer_control_bar(),
],
className="language-footer",
),
build_footer_control_bar(),
],
className="app-wrapper",
)
Expand Down
21 changes: 9 additions & 12 deletions src/datadoc/frontend/components/control_bars.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

from __future__ import annotations

import dash_bootstrap_components as dbc
import ssb_dash_components as ssb
from dash import html

Expand Down Expand Up @@ -32,18 +31,16 @@
)


def build_footer_control_bar() -> dbc.Row:
def build_footer_control_bar() -> html.Aside:
"""Build footer control bar which resides below all the content."""
return dbc.CardBody(
dbc.Row(
[
dbc.Col(
html.P(f"v{get_app_version()}", className="small"),
align="end",
),
],
justify="between",
),
return html.Aside(
children=[
html.P(
f"v{get_app_version()}",
className="small",
),
],
className="language-footer",
)


Expand Down

0 comments on commit a0f4b56

Please sign in to comment.