com.github.fluorumlabs.disconnect.vaadin.VerticalLayout Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of disconnect-vaadin Show documentation
Show all versions of disconnect-vaadin Show documentation
Vaadin components bindings for Disconnect Zero
The newest version!
package com.github.fluorumlabs.disconnect.vaadin;
import com.github.fluorumlabs.disconnect.core.annotations.WebComponent;
import com.github.fluorumlabs.disconnect.vaadin.elements.VerticalLayoutElement;
import com.github.fluorumlabs.disconnect.vaadin.mixins.HasThemableMixin;
import com.github.fluorumlabs.disconnect.vaadin.types.ThemeVariant;
import com.github.fluorumlabs.disconnect.zero.component.AbstractComponent;
import com.github.fluorumlabs.disconnect.zero.component.Component;
import com.github.fluorumlabs.disconnect.zero.component.HasComponents;
import com.github.fluorumlabs.disconnect.zero.component.HasStyle;
import js.extras.JsEnum;
/**
* <vaadin-vertical-layout>
provides a simple way to vertically align your HTML elements.
*
* <vaadin-vertical-layout>
* <div>Item 1</div>
* <div>Item 2</div>
* </vaadin-vertical-layout>
*
* Built-in Theme Variations
* <vaadin-vertical-layout>
supports the following theme variations:
*
*
*
* Theme variation Description
*
*
* theme="margin"
Applies the default amount of CSS margin for the host
* element (specified by the theme)
* theme="padding"
Applies the default amount of CSS padding for the host
* element (specified by the theme)
* theme="spacing"
Applies the default amount of CSS margin between items
* (specified by the theme)
*
*
*/
@WebComponent
public class VerticalLayout extends AbstractComponent
implements HasThemableMixin,
HasStyle, HasComponents> {
public VerticalLayout() {
super(VerticalLayoutElement.TAGNAME());
}
public VerticalLayout(Component>... components) {
this();
add(components);
}
public abstract static class Variant extends ThemeVariant {
public static final Variant MARGIN = JsEnum.of("margin");
public static final Variant PADDING = JsEnum.of("padding");
public static final Variant SPACING_XS = JsEnum.of("spacing-xs");
public static final Variant SPACING_S = JsEnum.of("spacing-s");
public static final Variant SPACING = JsEnum.of("spacing");
public static final Variant SPACING_L = JsEnum.of("spacing-l");
public static final Variant SPACING_XL = JsEnum.of("spacing-xl");
}
}