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

How to limit MarkdownBlock to specific toolbar options (e.g. 'strong' only) in Wagtail admin? #146

Open
jim-acb opened this issue Oct 9, 2024 · 1 comment

Comments

@jim-acb
Copy link

jim-acb commented Oct 9, 2024

I am using the wagtail-markdown package with a MarkdownBlock in Wagtail’s StreamField. I would like to restrict the Markdown toolbar in the Wagtail admin interface to only allow the specific options (for example 'strong' only), disabling all other Markdown formatting options.

I attempted the following:

•	Configured the WAGTAILMARKDOWN settings to only allow the <strong> tag using allowed_tags.
WAGTAILMARKDOWN = {
    "allowed_tags": ["strong"],
    "allowed_attributes": {},
    "allowed_styles": [],
    "allowed_settings_mode": "override",
    "extensions": [],
    "extensions_settings_mode": "override",
}

Despite these changes, the editor continues to display all toolbar options, and users can still see other Markdown features.

I would like to request a feature or guidance on how to limit the editor to specific Markdown formatting options.

Thank you!

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

2 participants