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

org.bklab.flow.components.html.LimitWidthSpan Maven / Gradle / Ivy

There is a newer version: 22.0.1
Show newest version
package org.bklab.flow.components.html;

import com.vaadin.flow.component.html.Span;
import org.bklab.flow.factory.SpanFactory;

public class LimitWidthSpan extends Span {

    public LimitWidthSpan(String text, String maxWidth) {
        super(text);
        getStyle()
                .set("width", maxWidth)
                .set("text-overflow", "ellipsis")
                .set("display", "block")
                .set("white-space", "nowrap")
                .set("overflow", "hidden");
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy