mirror of
https://github.com/AJMicke/KickerELO.git
synced 2026-03-11 13:31:02 +01:00
Merge pull request #25 from AJMicke/develop
Use GitHub logo with transparency, move it to the right of the drawer
This commit is contained in:
@@ -10,6 +10,7 @@ import com.vaadin.flow.component.html.Image;
|
|||||||
import com.vaadin.flow.component.icon.VaadinIcon;
|
import com.vaadin.flow.component.icon.VaadinIcon;
|
||||||
import com.vaadin.flow.component.sidenav.SideNav;
|
import com.vaadin.flow.component.sidenav.SideNav;
|
||||||
import com.vaadin.flow.component.sidenav.SideNavItem;
|
import com.vaadin.flow.component.sidenav.SideNavItem;
|
||||||
|
import com.vaadin.flow.dom.Style;
|
||||||
import com.vaadin.flow.router.Layout;
|
import com.vaadin.flow.router.Layout;
|
||||||
import org.kickerelo.kickerelo.views.*;
|
import org.kickerelo.kickerelo.views.*;
|
||||||
|
|
||||||
@@ -41,12 +42,15 @@ public class KickerAppLayout extends AppLayout {
|
|||||||
new SideNavItem("Historie", History2vs2View.class, VaadinIcon.RECORDS.create()));
|
new SideNavItem("Historie", History2vs2View.class, VaadinIcon.RECORDS.create()));
|
||||||
|
|
||||||
|
|
||||||
Image githubLogo = new Image("https://github.githubassets.com/assets/GitHub-Mark-ea2971cee799.png", "Github");
|
Image githubLogo = new Image("github-mark.png", "Github");
|
||||||
githubLogo.setHeight("30px");
|
githubLogo.setHeight("30px");
|
||||||
Anchor gitLink = new Anchor("https://github.com/AJMicke/KickerELO", githubLogo);
|
Anchor gitLink = new Anchor("https://github.com/AJMicke/KickerELO", githubLogo);
|
||||||
Div spacingDiv = new Div(gitLink);
|
Div spacingDiv = new Div(gitLink);
|
||||||
spacingDiv.setSizeFull();
|
spacingDiv.setSizeFull();
|
||||||
gitLink.setTarget("_blank");
|
gitLink.setTarget("_blank");
|
||||||
addToDrawer(general, nav1, nav2, spacingDiv, gitLink);
|
gitLink.getElement().getStyle().set("background-color", "transparent");
|
||||||
|
Div gitLinkDiv = new Div(gitLink);
|
||||||
|
gitLinkDiv.getStyle().setAlignSelf(Style.AlignSelf.END).setMarginRight("5px");
|
||||||
|
addToDrawer(general, nav1, nav2, spacingDiv, gitLinkDiv);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
BIN
src/main/resources/static/github-mark.png
Normal file
BIN
src/main/resources/static/github-mark.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 6.2 KiB |
Reference in New Issue
Block a user