Medium Editor widget for Django
Project description
# Django Medium Editor
Adds [Medium Editor](https://yabwe.github.io/medium-editor/) to [Django](https://www.djangoproject.com/).
## Supported Environments
* Django 1.9
* Python 3.4
## Installation
1. Install **django-mediumeditor**
via PyPi:
```
pip install django-mediumeditor
```
via GIT:
```
pip install git+https://github.com/g3rd/django-mediumeditor.git
```
2. Install app
```
INSTALLED_APPS = [
...
'mediumeditor',
]
```
## Usage
### Django Admin
Add to Admin class
```
from mediumeditor.admin import MediumEditorAdmin
@admin.register(MyModel)
class MyModelAdmin(MediumEditorAdmin, admin.ModelAdmin):
...
mediumeditor_fields = ('my_text_field', )
...
```
### Forms
**NOTE:** This is untested
1. Override the Widget for the field
```
from mediumeditor.widget import MediumEditorTextarea
class MyForm(forms.ModelForm):
...
class Meta:
model = MyModel
widgets = {
'my_text_field': MediumEditorTextarea(),
}
```
2. In the ```<head>``` of the template
```
{{ form.media }}
```
## Contributing
[Take out some bugs](https://github.com/g3rd/django-mediumeditor/issues)
[Report issues or feature requests](https://github.com/g3rd/django-mediumeditor/issues)
## Todo
Since this is a very new project,
- [ ] Pypi
- [ ] Documentation
- [ ] Clean-up Django admin display
- Toolbar style
- Anchor configuration toolbar
- Bold to use ```<strong>```
- Italic to use ```<em>```
- Inline styles do not inherit Django Admin (see H2 and unordered lists)
- [ ] Expand Django support to 1.8
- [ ] Expand Python support to 2
- [ ] Tests!
- [ ] Configure the toolbar - globally
- [ ] Configure the toolbar - per form
- [ ] Configure the toolbar - per field
## License
MIT: https://github.com/g3rd/django-mediumeditor/blob/master/LICENSE
Adds [Medium Editor](https://yabwe.github.io/medium-editor/) to [Django](https://www.djangoproject.com/).
## Supported Environments
* Django 1.9
* Python 3.4
## Installation
1. Install **django-mediumeditor**
via PyPi:
```
pip install django-mediumeditor
```
via GIT:
```
pip install git+https://github.com/g3rd/django-mediumeditor.git
```
2. Install app
```
INSTALLED_APPS = [
...
'mediumeditor',
]
```
## Usage
### Django Admin
Add to Admin class
```
from mediumeditor.admin import MediumEditorAdmin
@admin.register(MyModel)
class MyModelAdmin(MediumEditorAdmin, admin.ModelAdmin):
...
mediumeditor_fields = ('my_text_field', )
...
```
### Forms
**NOTE:** This is untested
1. Override the Widget for the field
```
from mediumeditor.widget import MediumEditorTextarea
class MyForm(forms.ModelForm):
...
class Meta:
model = MyModel
widgets = {
'my_text_field': MediumEditorTextarea(),
}
```
2. In the ```<head>``` of the template
```
{{ form.media }}
```
## Contributing
[Take out some bugs](https://github.com/g3rd/django-mediumeditor/issues)
[Report issues or feature requests](https://github.com/g3rd/django-mediumeditor/issues)
## Todo
Since this is a very new project,
- [ ] Pypi
- [ ] Documentation
- [ ] Clean-up Django admin display
- Toolbar style
- Anchor configuration toolbar
- Bold to use ```<strong>```
- Italic to use ```<em>```
- Inline styles do not inherit Django Admin (see H2 and unordered lists)
- [ ] Expand Django support to 1.8
- [ ] Expand Python support to 2
- [ ] Tests!
- [ ] Configure the toolbar - globally
- [ ] Configure the toolbar - per form
- [ ] Configure the toolbar - per field
## License
MIT: https://github.com/g3rd/django-mediumeditor/blob/master/LICENSE
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
Close
Hashes for django-mediumeditor-0.1.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8ca9b47f9f940a07f4e7edc7cf0eb43895f0c18dac83fea449463ab5c86fc79d |
|
MD5 | 0c881db012b511870f7714e29a1f40e0 |
|
BLAKE2b-256 | 631e266380a823409abd830a230df1d1e3bd354acf3f7864fd7410c097d42801 |