mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-28 14:57:12 +00:00
Added flyover popup for desktop user management contents
This commit is contained in:
1 parent
b81e707a91
commit
85398371e3
4 files changed
+116
No files matched your search
+33
@@ -0,0 +1,33 @@
|
||||
.flyover {
|
||||
font-size: 1rem;
|
||||
top: 4.666667em !important;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.flyover_content {
|
||||
width: 24.8em;
|
||||
float: right;
|
||||
padding: 1.333333333333333em;
|
||||
background-color: #fff;
|
||||
border-radius: .2em;
|
||||
box-shadow: 0 0 .533333333333333em rgba(0,0,0,.15);
|
||||
border: 1px solid rgba(0,0,0,.1);
|
||||
}
|
||||
|
||||
.flyover_content:before {
|
||||
content: '';
|
||||
width: 1.333333333333333em;
|
||||
height: 1.333333333333333em;
|
||||
display: block;
|
||||
background-color: #fff;
|
||||
-webkit-transform: rotate(45deg);
|
||||
-moz-transform: rotate(45deg);
|
||||
-ms-transform: rotate(45deg);
|
||||
transform: rotate(45deg);
|
||||
margin: 0 1em 0 1.333333333333333em;
|
||||
position: absolute;
|
||||
top: -.666666666666667em;
|
||||
right: 1.333333333333333em;
|
||||
border-top: 1px solid rgba(0,0,0,.1);
|
||||
border-left: 1px solid rgba(0,0,0,.1);
|
||||
}
|
||||
+52
@@ -0,0 +1,52 @@
|
||||
package com.sap.sailing.gwt.home.shared.usermanagement;
|
||||
|
||||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.dom.client.Element;
|
||||
import com.google.gwt.uibinder.client.UiBinder;
|
||||
import com.google.gwt.uibinder.client.UiField;
|
||||
import com.google.gwt.user.client.ui.AcceptsOneWidget;
|
||||
import com.google.gwt.user.client.ui.Composite;
|
||||
import com.google.gwt.user.client.ui.IsWidget;
|
||||
import com.google.gwt.user.client.ui.PopupPanel;
|
||||
import com.google.gwt.user.client.ui.SimplePanel;
|
||||
import com.google.gwt.user.client.ui.Widget;
|
||||
import com.sap.sailing.gwt.home.shared.usermanagement.UserManagementResources.LocalCss;
|
||||
|
||||
public class UserManagementFlyover extends Composite implements AcceptsOneWidget {
|
||||
|
||||
private static final LocalCss LOCAL_CSS = UserManagementResources.INSTANCE.css();
|
||||
|
||||
interface UserManagementFlyoverUiBinder extends UiBinder<Widget, UserManagementFlyover> {
|
||||
}
|
||||
|
||||
private static UserManagementFlyoverUiBinder uiBinder = GWT.create(UserManagementFlyoverUiBinder.class);
|
||||
|
||||
private final PopupPanel popupPanel = new PopupPanel(true, false);
|
||||
|
||||
@UiField SimplePanel contentContainerUi;
|
||||
|
||||
public UserManagementFlyover(Element autoHidePartner) {
|
||||
LOCAL_CSS.ensureInjected();
|
||||
popupPanel.addStyleName(LOCAL_CSS.flyover());
|
||||
popupPanel.addAutoHidePartner(autoHidePartner);
|
||||
popupPanel.setWidget(uiBinder.createAndBindUi(this));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setWidget(IsWidget w) {
|
||||
contentContainerUi.setWidget(w);
|
||||
}
|
||||
|
||||
public void show() {
|
||||
popupPanel.show();
|
||||
}
|
||||
|
||||
public void hide() {
|
||||
popupPanel.hide();
|
||||
}
|
||||
|
||||
public boolean isShowing() {
|
||||
return popupPanel.isShowing();
|
||||
}
|
||||
|
||||
}
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent">
|
||||
<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder" xmlns:g="urn:import:com.google.gwt.user.client.ui"
|
||||
xmlns:s="urn:import:com.sap.sailing.gwt.home.client.shared">
|
||||
<ui:with field="i18n" type="com.sap.sailing.gwt.ui.client.StringMessages" />
|
||||
<ui:with field="res" type="com.sap.sailing.gwt.common.client.SharedResources" />
|
||||
<ui:with field="local_res" type="com.sap.sailing.gwt.home.shared.usermanagement.UserManagementResources" />
|
||||
<g:HTMLPanel addStyleNames="{res.mediaCss.grid}">
|
||||
<div class="{res.mediaCss.column} {res.mediaCss.small12}">
|
||||
<g:SimplePanel addStyleNames="{local_res.css.flyover_content}" ui:field="contentContainerUi"/>
|
||||
</div>
|
||||
</g:HTMLPanel>
|
||||
</ui:UiBinder>
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
package com.sap.sailing.gwt.home.shared.usermanagement;
|
||||
|
||||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.resources.client.ClientBundle;
|
||||
import com.google.gwt.resources.client.CssResource;
|
||||
|
||||
public interface UserManagementResources extends ClientBundle {
|
||||
|
||||
public static final UserManagementResources INSTANCE = GWT.create(UserManagementResources.class);
|
||||
|
||||
@Source("UserManagement.gss")
|
||||
LocalCss css();
|
||||
|
||||
public interface LocalCss extends CssResource {
|
||||
String flyover();
|
||||
String flyover_content();
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user