How to work with Primeng Editor?

Asked

Viewed 444 times

3

Look at the link

Edidor Primeng

Would anyone know how to disable or remove the image upload button

inserir a descrição da imagem aqui

  • Wladyband if you have any questions about how to do CSS Override tells me that I edit the answer in more detail. But just put this style sheet last, after you have already called all the others.

2 answers

1

According to the documentation

Editor provides a default Toolbar with common options, to customize it define your Elements Inside the header element.

Translating

Editor provides a standard toolbar with common options, to customize it define its elements within the element header

For example

<p-editor name="custom" [(ngModel)]="customtext" styleClass="editor-dimensions">
  <p-header>
    <span class="ql-formats">
      <button class="ql-bold"></button>
      <button class="ql-italic"></button>
      <button class="ql-underline"></button>
      <button class="ql-clean"></button>
    </span>
  </p-header>
</p-editor>

Will render as

inserir a descrição da imagem aqui

If you want a higher level of customization, read the documentation on Quill Toolbar, which is what Primeng uses.

  • I even knew this suggestion that you gave, but what I really need and put all the buttons except the upload, would you know to modify the p-header to put everyone but the upload button? please.

  • i did not find in the documentation how to do this.

0


You can create a . css to make one override of the classes you want to change.

In case you take off this button you can do so:

button.ql-image {
    display: none !important;
}

See an image with the result (note the red box).

inserir a descrição da imagem aqui

Browser other questions tagged

You are not signed in. Login or sign up in order to post.