Skip to content

Commit f2859e2

Browse files
committed
Change layout and <a> to button
1 parent 69c6919 commit f2859e2

File tree

1 file changed

+25
-24
lines changed

1 file changed

+25
-24
lines changed

src/fourc_webviewer/gui_utils.py

Lines changed: 25 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -109,36 +109,37 @@ def _toolbar(server_controller):
109109
html.Img(
110110
src="https://raw.githubusercontent.com/4C-multiphysics/4C-webviewer/refs/heads/main/images/4C-logo/negative-white/4C-logo-landscape_negative.svg",
111111
alt="4C Logo",
112-
style="height: 50px; width: auto; filter: invert(1); padding-left: 20px",
112+
style="height: 50px; width: auto; filter: invert(1); padding-left: 20px; padding-right: 10px;",
113113
class_="me-2",
114114
)
115115

116-
with html.Div(style="padding-left: 20px;"):
117-
vuetify.VToolbarTitle(
118-
"4C Webviewer",
119-
tag="h1",
120-
shrink=True,
121-
class_="mx-4",
122-
style="font-weight: 500;",
123-
)
124-
with vuetify.VTooltip(location="top"):
125-
with html.Template(v_slot_activator="{ props }"):
126-
with html.A(
127-
v_bind="props",
128-
href="https://4c-multiphysics.github.io/4C/documentation/index.html",
129-
target="_blank", # opens in a new tab
130-
style="text-decoration: none; color: inherit; cursor: help;", # icon should look normal
131-
):
132-
vuetify.VIcon(
133-
"mdi-book-open-blank-variant-outline",
134-
size=36,
135-
color="#555",
136-
style="padding-left: 10px;",
137-
)
138-
html.Span("4C Documentation")
116+
with vuetify.VTooltip(location="top"):
117+
with html.Template(v_slot_activator="{ props }"):
118+
with vuetify.VBtn(
119+
tag="a",
120+
v_bind="{...props, target: '_blank'}",
121+
v_tooltip="4C Documentation",
122+
href="https://4c-multiphysics.github.io/4C/documentation/index.html",
123+
icon=True,
124+
rel="noopener noreferrer",
125+
):
126+
vuetify.VIcon(
127+
"mdi-book-open-blank-variant-outline",
128+
size=36,
129+
color="#666",
130+
)
131+
html.Span("4C Documentation")
139132

140133
vuetify.VSpacer()
141134

135+
vuetify.VToolbarTitle(
136+
"4C Webviewer",
137+
tag="h1",
138+
shrink=True,
139+
class_="mx-4",
140+
style="font-weight: 500; padding-right: 10px;",
141+
)
142+
142143
vuetify.VFileInput(
143144
label="Input file",
144145
v_model=("fourc_yaml_file",),

0 commit comments

Comments
 (0)