Scenario
Two flexbox elements sitting side by side, inside a container, with quill in the left element. Quill having bounds set to the left element, not document.body and overflow-wrap added to the .ql-editor class.
Issue As quill reaches the right most bound of the editor it breaks to the next line, but still continually pushes the right flexbox element, shrinking it until it is impossible to shrink it anymore.
Desired functionality To have quill confined to the bounds of the flexbox element which contains it, without expanding the element and WITHOUT the need to specify a width in order to support responsive designs.
Anyone have an idea how to achieve this?
Here is an example to further illustrate the issue.
var toolbarOptions = [[{ 'header': [1, 2, 3, 4, 5, 6, false] }, 'bold', 'italic', 'underline', { 'list': 'bullet' }, { 'color': [] }, { 'background': [] }, { 'align': [] }]];
var quill = new Quill('.editor', {
theme: 'snow',
bounds: '.left',
modules:
{
toolbar: toolbarOptions
}
});
this.quill = quill;
this.quill.root.innerHTML = "Type in here until you get a second line the quill editor... it will happen eventually";
.container
{
display: flex;
flex-direction: initial;
}
.left
{
display: flex;
flex-direction: column;
}
.right
{
display: flex;
}
.ql-editor
{
overflow-wrap: anywhere;
}
<link href="https://cdn.quilljs.com/1.3.6/quill.snow.css" rel="stylesheet"/>
<script src="https://cdn.quilljs.com/1.3.6/quill.js"></script>
<div class="container">
<div class="left">
<div class="editor">
</div>
</div>
<div class="right">
Just a place holder
</div>
</div>