Skip to main content

An extended Draftail image block for news sites.

Project description

# Wagtail News Image

This [Django]( app provides an inline image block for the Draftail WYSIWYG editor.

You can play with this plugin on a demo site [here](

This image block supports:

- upload
- search
- resize
- captions
- hyperlinks

This is what the image block looks like in the Draftail WYSIWYG editor:

<img src="./screenshots/WYSIWYG.png" alt="Wagtail WYSIWYG view" width="500px"/>

Clicking on the block reveals a modal, which allows you to edit the image:

<img src="./screenshots/modal.png" alt="Wagtail editor modal" width="500px"/>

## Installation

In `` you need to register the app in `INSTALLED_APPS`


# ...
# ...

In `` you need to add `wagtailnewsimage.urls`. The base url (`wagtailnewsimage/`) can be configured to be whatever you like.

urlpatterns = [
# ...
path(r'wagtailnewsimage/', include('wagtailnewsimage.urls')),
# ...

In `` you need to add `news-image` to your RichTextField features whitelist


class MyPage(Page):
body = RichTextField(features=[
# ...
# ...

## Dependencies

* Wagtail (2+)
* Django (1.11+)
* Django Rest Framework (3+)

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wagtail-news-image-0.0.2.tar.gz (229.4 kB view hashes)

Uploaded Source

Built Distribution

wagtail_news_image-0.0.2-py3-none-any.whl (232.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page