Search in sources :

Example 26 with Div

use of com.vaadin.flow.component.html.Div in project flow by vaadin.

the class PolymerModelPropertiesView method addUpdateElement.

private Div addUpdateElement(String id) {
    Div div = new Div();
    div.setText("Property value:" + getElement().getProperty("text") + ", model value: " + getModel().getText());
    div.setId(id);
    return div;
}
Also used : Div(com.vaadin.flow.component.html.Div)

Example 27 with Div

use of com.vaadin.flow.component.html.Div in project flow by vaadin.

the class PolymerPropertyChangeEventView method propertyChanged.

private void propertyChanged(PropertyChangeEvent event) {
    Div div = new Div();
    div.setText("New property value: '" + event.getValue() + "', old property value: '" + event.getOldValue() + "'");
    div.addClassName("change-event");
    add(div);
}
Also used : Div(com.vaadin.flow.component.html.Div)

Example 28 with Div

use of com.vaadin.flow.component.html.Div in project flow by vaadin.

the class SubPropertyModelTemplate method click.

@EventHandler
private void click(@ModelItem("status") Status statusItem) {
    Div div = new Div();
    div.setId("statusClick");
    div.setText(statusItem.getMessage());
    ((HasComponents) getParent().get()).add(div);
}
Also used : Div(com.vaadin.flow.component.html.Div) HasComponents(com.vaadin.flow.component.HasComponents) EventHandler(com.vaadin.flow.component.polymertemplate.EventHandler)

Example 29 with Div

use of com.vaadin.flow.component.html.Div in project flow by vaadin.

the class SubPropertyModelTemplate method sync.

@EventHandler
private void sync() {
    Div div = new Div();
    div.setId("synced-msg");
    div.setText(getStatus().getMessage());
    ((HasComponents) getParent().get()).add(div);
}
Also used : Div(com.vaadin.flow.component.html.Div) HasComponents(com.vaadin.flow.component.HasComponents) EventHandler(com.vaadin.flow.component.polymertemplate.EventHandler)

Example 30 with Div

use of com.vaadin.flow.component.html.Div in project flow by vaadin.

the class PaperInputView method showValue.

private void showValue(String value) {
    Div div = new Div();
    div.setText(value);
    div.setClassName("update-value");
    add(div);
}
Also used : Div(com.vaadin.flow.component.html.Div)

Aggregations

Div (com.vaadin.flow.component.html.Div)30 NativeButton (com.vaadin.flow.component.html.NativeButton)7 Text (com.vaadin.flow.component.Text)6 Element (com.vaadin.flow.dom.Element)4 HasComponents (com.vaadin.flow.component.HasComponents)3 EventHandler (com.vaadin.flow.component.polymertemplate.EventHandler)3 Input (com.vaadin.flow.component.html.Input)2 ShadowRoot (com.vaadin.flow.dom.ShadowRoot)2 HasText (com.vaadin.flow.component.HasText)1 H3 (com.vaadin.flow.component.html.H3)1 Hr (com.vaadin.flow.component.html.Hr)1 Label (com.vaadin.flow.component.html.Label)1 Span (com.vaadin.flow.component.html.Span)1 Style (com.vaadin.flow.dom.Style)1 NameField (com.vaadin.flow.uitest.ui.CompositeView.NameField)1