All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.dominokit.domino.ui.row.Row Maven / Gradle / Ivy

package org.dominokit.domino.ui.row;

import elemental2.dom.HTMLDivElement;
import elemental2.dom.HTMLElement;
import org.dominokit.domino.ui.column.Column;
import org.dominokit.domino.ui.style.Style;
import org.dominokit.domino.ui.utils.BaseDominoElement;

import static org.jboss.gwt.elemento.core.Elements.div;

/**
 * @deprecated use {@link org.dominokit.domino.ui.grid.Row}
 */
@Deprecated
public class Row extends BaseDominoElement {

    private HTMLDivElement row;

    private Row(HTMLDivElement row) {
        this.row = row;
        init(this);
    }

    public static Row create() {
        return new Row(div().css("row clearfix").asElement());
    }

    public Column addColumn() {
        Column column = Column.create();
        row.appendChild(column.asElement());
        return column;
    }

    public Row addColumn(Column column) {
        row.appendChild(column.asElement());
        return this;
    }

    @Override
    public HTMLDivElement asElement() {
        return row;
    }

    public Row appendContent(HTMLElement element) {
        row.appendChild(element);
        return this;
    }

    public Row condenced(){
        return Style.of(this).setMarginBottom("0px").get();
    }

    public Style style() {
        return Style.of(this);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy