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

org.dominokit.domino.ui.forms.DominoFields Maven / Gradle / Ivy

There is a newer version: 1.0.139
Show newest version
package org.dominokit.domino.ui.forms;

import elemental2.dom.Node;
import org.dominokit.domino.ui.utils.TextNode;

import java.util.function.Supplier;

public class DominoFields {

    public static final DominoFields INSTANCE = new DominoFields();
    private FieldStyle fieldsStyle = FieldStyle.LINED;
    private FieldStyle DEFAULT = () -> fieldsStyle.getStyle();
    private Supplier requiredIndicator = ()-> TextNode.of(" * ");

    private DominoFields() {
    }

    public void setDefaultFieldsStyle(FieldStyle fieldsStyle) {
        this.fieldsStyle = fieldsStyle;
    }

    public FieldStyle getDefaultFieldsStyle(){
        return DEFAULT;
    }

    public Supplier getRequiredIndicator() {
        return requiredIndicator;
    }

    public void setRequiredIndicator(Supplier requiredIndicator) {
        this.requiredIndicator = requiredIndicator;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy