You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If i give large Text for header component in my form builder, UI is getting disrupted. There is no way to limit the length as header component does not p
#1524
Closed
hidayathBR opened this issue
Feb 22, 2024
· 2 comments
· Fixed by #1526
Description: If i give large Text for header component in my form builder, UI is getting disrupted. There is no way to limit the length as header component does not provide a prop to do it.
Environment Details:
formBuilder Version:
Browser:
OS:
Expected Behavior: i want to limit the length of the header component from the code.
Actual Behavior
Steps to Reproduce
Screenshot - (optional)
The text was updated successfully, but these errors were encountered:
FormBuilder doesn't try to get in the way of valid inputs. To restrict the max length for labels you should either hook into the onAddField event and add a maxlen attribute to the input (if HTML labels are disabled), or you need to write a function that limits the number of characters into the div[contenteditable].
On the display side, Header elements already wrap by default in browsers, however in your instance you do not have any whitespace or punctuation for the browser to break on. this can be fixed with CSS, either hiding the overflow or allowing the header to break in the middle of a word.
overflow: hidden; //or
word-wrap: break-word;
It makes sense to add word-wrap: break-word to the formBuilder css
Description: If i give large Text for header component in my form builder, UI is getting disrupted. There is no way to limit the length as header component does not provide a prop to do it.
Environment Details:
Expected Behavior: i want to limit the length of the header component from the code.
Actual Behavior
Steps to Reproduce
Screenshot - (optional)
The text was updated successfully, but these errors were encountered: