com.github.fluorumlabs.disconnect.vaadin.mixins.HasColumnBaseMixin 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.mixins;
import com.github.fluorumlabs.disconnect.vaadin.elements.mixins.ColumnBaseMixin;
import com.github.fluorumlabs.disconnect.vaadin.renderers.GridHeaderFooterRenderer;
import com.github.fluorumlabs.disconnect.zero.component.Component;
import js.lang.Any;
import javax.annotation.Nullable;
public interface HasColumnBaseMixin- , T extends Component
>
extends Component {
/**
* When set to true, the column is user-resizable.
*/
default boolean resizable() {
return getNode().isResizable();
}
/**
* When set to true, the column is user-resizable.
*/
default T resizable(boolean resizable) {
getNode().setResizable(resizable);
return (T) this;
}
/**
* When true, the column is frozen. When a column inside of a column group is frozen,
* all of the sibling columns inside the group will get frozen also.
*/
default boolean frozen() {
return getNode().isFrozen();
}
/**
* When true, the column is frozen. When a column inside of a column group is frozen,
* all of the sibling columns inside the group will get frozen also.
*/
default T frozen(boolean frozen) {
getNode().setFrozen(frozen);
return (T) this;
}
/**
* When set to true, the cells for this column are hidden.
*/
default boolean hidden() {
return getNode().isHidden();
}
/**
* When set to true, the cells for this column are hidden.
*/
default T hidden(boolean hidden) {
getNode().setHidden(hidden);
return (T) this;
}
/**
* Text content to display in the header cell of the column.
*/
@Nullable
default String header() {
return getNode().getHeader();
}
/**
* Text content to display in the header cell of the column.
*/
default T header(String header) {
getNode().setHeader(header);
return (T) this;
}
/**
* Aligns the columns cell content horizontally.
* Supported values: "start", "center" and "end".
*/
@Nullable
default String textAlign() {
return getNode().getTextAlign();
}
/**
* Aligns the columns cell content horizontally.
* Supported values: "start", "center" and "end".
*/
default T textAlign(String textAlign) {
getNode().setTextAlign(textAlign);
return (T) this;
}
/**
* Custom function for rendering the header content.
* Receives two arguments:
*
*
* root
The header cell content DOM element. Append your content to it.
* column
The <vaadin-grid-column>
element.
*
*/
@Nullable
default GridHeaderFooterRenderer- headerRenderer() {
return getNode().getHeaderRenderer();
}
/**
* Custom function for rendering the header content.
* Receives two arguments:
*
*
* root
The header cell content DOM element. Append your content to it.
* column
The <vaadin-grid-column>
element.
*
*/
default T headerRenderer(GridHeaderFooterRenderer- headerRenderer) {
getNode().setHeaderRenderer(headerRenderer);
return (T) this;
}
/**
* Custom function for rendering the footer content.
* Receives two arguments:
*
*
* root
The footer cell content DOM element. Append your content to it.
* column
The <vaadin-grid-column>
element.
*
*/
@Nullable
default GridHeaderFooterRenderer- footerRenderer() {
return getNode().getFooterRenderer();
}
/**
* Custom function for rendering the footer content.
* Receives two arguments:
*
*
* root
The footer cell content DOM element. Append your content to it.
* column
The <vaadin-grid-column>
element.
*
*/
default T footerRenderer(GridHeaderFooterRenderer- footerRenderer) {
getNode().setFooterRenderer(footerRenderer);
return (T) this;
}
}