Class VFormLayout

    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.vaadin.flow.component.formlayout.FormLayout

        com.vaadin.flow.component.formlayout.FormLayout.FormItem, com.vaadin.flow.component.formlayout.FormLayout.ResponsiveStep
    • Constructor Summary

      Constructors 
      Constructor Description
      VFormLayout()  
      VFormLayout​(com.vaadin.flow.component.Component... children)  
    • Constructor Detail

      • VFormLayout

        public VFormLayout()
      • VFormLayout

        public VFormLayout​(com.vaadin.flow.component.Component... children)
    • Method Detail

      • addFormItem

        public com.vaadin.flow.component.formlayout.FormLayout.FormItem addFormItem​(com.vaadin.flow.component.Component component,
                                                                                    String label,
                                                                                    int colspan)
        Adds component with given label and colspan value. By default FormLayout has two columns, so if you want full width component, give 2 as a last parameter.
        Parameters:
        component - the component
        label - the label for component
        colspan - the amount of columns this component should consume
        Returns:
        added FormItem
      • withFormItem

        public VFormLayout withFormItem​(com.vaadin.flow.component.Component component,
                                        String label,
                                        int colspan)
      • withResponsiveSteps

        public VFormLayout withResponsiveSteps​(com.vaadin.flow.component.formlayout.FormLayout.ResponsiveStep... steps)
      • withResponsiveSteps

        public VFormLayout withResponsiveSteps​(List<com.vaadin.flow.component.formlayout.FormLayout.ResponsiveStep> steps)
      • withResponsiveStepsOneCol

        public VFormLayout withResponsiveStepsOneCol​(com.vaadin.flow.component.formlayout.FormLayout.ResponsiveStep.LabelsPosition position)
        shorthand for one col configuration
        Parameters:
        position - TOP or ASIDE
        Returns:
        itself for fluent writing
      • withResponsiveStepsTwoCols

        public VFormLayout withResponsiveStepsTwoCols​(com.vaadin.flow.component.formlayout.FormLayout.ResponsiveStep.LabelsPosition position,
                                                      String minWidthTwoCol)
        shorthand for two col configuration
        Parameters:
        position - TOP or ASIDE
        minWidthTwoCol - good value 21em
        Returns:
        itself for fluent writing
      • withResponsiveStepsThreeCols

        public VFormLayout withResponsiveStepsThreeCols​(com.vaadin.flow.component.formlayout.FormLayout.ResponsiveStep.LabelsPosition position,
                                                        String minWidthTwoCol,
                                                        String minWidthThreeCol)
        shorthand for three col configuration
        Parameters:
        position - TOP or ASIDE
        minWidthTwoCol - good value 21em
        minWidthThreeCol - good value 14em
        Returns:
        itself for fluent writing
      • withResponsiveStepsFourCols

        public VFormLayout withResponsiveStepsFourCols​(com.vaadin.flow.component.formlayout.FormLayout.ResponsiveStep.LabelsPosition position,
                                                       String minWidthTwoCol,
                                                       String minWidthThreeCol,
                                                       String minWidthFourthCol)
        shorthand for three col configuration
        Parameters:
        position - TOP or ASIDE
        minWidthTwoCol - good value 21em
        minWidthThreeCol - good value 14em
        minWidthFourthCol - the minimum width of the fourth column
        Returns:
        itself for fluent writing