Change drawer width + render on language change

This commit is contained in:
Moritz Dieing 2021-02-06 12:06:49 +01:00
parent 4c98976059
commit 619e6da18c
6 changed files with 14 additions and 2 deletions

View File

@ -0,0 +1,6 @@
:host {
--vaadin-app-layout-drawer-offset-size: 400px;
}
[part="drawer"] {
width: var(--vaadin-app-layout-drawer-offset-size);
}

View File

@ -2,7 +2,7 @@
overflow: auto;
margin: 1px;
height: 100%;
max-width: 256px;
max-width: 400px;
padding: 1.1em 0.5em 0.5em 0.5em;
}

View File

@ -16,6 +16,7 @@
justify-content: center;
width: 100%;
padding: 0.5em 0em;
border-radius: 5px 5px 0 0;
}
#ruleName {
@ -24,6 +25,7 @@
#main {
align-items: center;
justify-content: center;
width: 100%;
margin: 0px;
padding-top: 0.2em;

View File

@ -16,6 +16,7 @@
#viewTitle {
font-size: var(--lumo-font-size-l);
cursor: pointer;
bottom: 1em;
}
#helpIcon {
@ -35,7 +36,7 @@
@media (min-width: 1000px) {
#inputBar {
margin-left: 15em;
margin-left: 22em;
}
#viewTitle {

View File

@ -49,5 +49,7 @@ public class DrawerContent extends VerticalLayout implements LocaleChangeObserve
@Override
public void localeChange(LocaleChangeEvent event) {
heading.setText(getTranslation("root.inferenceRules"));
ruleContainer.removeAll();
initRuleContainer();
}
}

View File

@ -26,6 +26,7 @@ import java.util.List;
* the screen.
*/
@CssImport("./styles/view/main/main-view.css")
@CssImport(value = "./styles/view/main/app-layout.css", themeFor = "vaadin-app-layout")
@JsModule("./styles/shared-styles.js")
@JavaScript("./src/svg-pan-zoom.min.js")
@JavaScript("./src/tex-svg-full.js")