0

I have an issue with alignement of 4 input text in VueJs.

enter image description here

My container CSS

.step__field-container {
    display: -ms-flexbox;
    display: flex;
    -ms-flex-direction: column;
    flex-direction: column;
    -ms-flex-pack: center;
    justify-content: center;
    -ms-flex-align: start;
    align-items: flex-start;
    width: 100%;
    max-width: 520px;
    margin: 40px auto auto;
}

My input CSS

.input__field {
    width: 100%;
    height: 50px;
    max-width: 334px;
    background-color: #fff;
    border: 1px solid #e9e9e9;
    padding-left: 20px;
    font-size: 15px;
    line-height: 50px;
}

Please help us.

Thanks

3
  • 1
    If you are using some form of a loop you could wrap every two in a div. You can use % to check for every even loop. i.e. 0 % 2 Commented Dec 2, 2020 at 12:30
  • 1
    Post your complete code. A demo using Codesandbox would be useful. Commented Dec 2, 2020 at 13:13
  • Below my survey template file Commented Dec 2, 2020 at 15:39

1 Answer 1

1

If you want a fixed two input fields per row, the following code will do the trick. And using row/column div is also recommended. See here for details.

.step__field-container

display: -ms-table;
display: table;

.input__field

width:50%;
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.