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

Disable Copy and Paste Buttons #71

Closed
Zamaruu opened this issue Jun 20, 2021 · 1 comment
Closed

Disable Copy and Paste Buttons #71

Zamaruu opened this issue Jun 20, 2021 · 1 comment
Labels
question Further information is requested

Comments

@Zamaruu
Copy link

Zamaruu commented Jun 20, 2021

Hi, my question would be how to disable the copy and paste buttons in the editor, cause on Flutter Web they seem kind of useless and out of position.

@Zamaruu Zamaruu added the question Further information is requested label Jun 20, 2021
@tneotia
Copy link
Owner

tneotia commented Jun 20, 2021

Widget htmlEditor = HtmlEditor(
  controller: controller, //required
  //other options
  toolbarOptions: HtmlToolbarOptions(
    defaultToolbarButtons: [
        //add any other buttons here otherwise only a few buttons will show up!
        OtherButtons(copy: false, paste: false),
    ]
  )
);

See more details at https://github.com/tneotia/html-editor-enhanced#toolbar. You can also view the source to see the default button code and copy paste that with this change.

By the way in v2.2.0 those buttons are removed by default (I was trying to reduce the clutter on initial setup), if you want to upgrade your version.

@Zamaruu Zamaruu closed this as completed Jun 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants