Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trim white space automatically #109

Closed
Bloom2036 opened this issue Nov 15, 2017 · 2 comments
Closed

Trim white space automatically #109

Bloom2036 opened this issue Nov 15, 2017 · 2 comments

Comments

@Bloom2036
Copy link

Example code here

html code

<quill-editor ref="myTextEditor" v-model="content"></quill-editor>

js code

<script>
  export default {
    data() {
      return {
        name: 'example',
        content: '<p>    Example</p>'
      }
    }
</script>

But the editor will trim the space before ' Example',
How to prevent quill editor trim white space?

@surmon-china
Copy link
Owner

  1. use ' ' to replace space. (The content will be pasteHTML by quill, not text.)

<p>&nbsp;&nbsp;&nbsp; Example </p>

  1. add style white-space: normal;

quill Issues links:
slab/quill#1751
slab/quill#1752
slab/quill#996

@Akitha
Copy link

Akitha commented Oct 8, 2018

Add this to styles.css

.ql-editor {
white-space: normal!important;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants