{ "info": { "author": "Oliver Christen", "author_email": "christen@app-logik.de", "bugtrack_url": null, "classifiers": [ "Development Status :: 2 - Pre-Alpha", "Environment :: Web Environment", "Framework :: Django :: 2.2", "License :: OSI Approved :: Apache Software License", "Operating System :: OS Independent", "Programming Language :: Python :: 3" ], "description": "django-editorjs-field\n===============\n\nThis module integrates the [Editor.js](https://github.com/codex-team/editor.js) widget into model/form fields for [Django](https://www.djangoproject.com).\n-------------------------------------\n\n## Warning\n\nThis is an early prototyp and work in progress\n\n## Installation\n\nInstall with Pip: \n```pip install django-editorjs-field```\n\n## Django Setup\n\n### settings.py\n\n```python\nINSTALLED_APPS = [\n ...\n 'editorjs_field',\n ...\n]\n```\n\n## Use in Django admin\n\n### models.py\n\n```python\nfrom django.db import models\nfrom editorjs_field.fields import EditorJSField\n\n\nclass Article(models.Model):\n title = models.CharField(max_length=100)\n content = EditorJSField()\n```\n\n### admin.py\n\n```python\nfrom django.contrib import admin\nfrom .models import Article\n\n\nclass ArticleAdmin(admin.ModelAdmin):\n list_display = ('title',)\n\n\nadmin.site.register(Article, ArticleAdmin)\n```\n\n## Use the widget in a custom form\n\n### forms.py\n\n```python\nfrom django import forms\nfrom editorjs_field.widgets import EditorJsWidget\n\nclass ArticleEditorForm(forms.Form):\n title = forms.CharField(label='Title')\n document = forms.CharField(label='Document', widget=EditorJsWidget)\n````\n\n## Examples & Development\n\nAn example can be found in the example folder. To run them clone the repository and run:\n\n```shell\n$ cd django-editorjs-field\n$ pipenv install\n$ pipenv shell\n$ cd example\n$ python manage.py migrate\n$ python manage.py createsuperuser\n$ python manage.py runserver\n```\n\nVisit ```http://localhost:8000/admin``` to view the admin widget and \n```http://localhost:8000/``` to view the custom form widget.", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/ochrstn/django-editorjs-field", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "django-editorjs-field", "package_url": "https://pypi.org/project/django-editorjs-field/", "platform": "", "project_url": "https://pypi.org/project/django-editorjs-field/", "project_urls": { "Homepage": "https://github.com/ochrstn/django-editorjs-field" }, "release_url": "https://pypi.org/project/django-editorjs-field/0.0.3/", "requires_dist": null, "requires_python": "", "summary": "editorjs.io integration as django model/form field", "version": "0.0.3" }, "last_serial": 5213143, "releases": { "0.0.3": [ { "comment_text": "", "digests": { "md5": "ef23abe9fb78721662963c79ead50667", "sha256": "f76e476ce756b0f0ec9ba85b380a24236f0c00e91479a9d6bb2cf4bbecdbcb5c" }, "downloads": -1, "filename": "django-editorjs-field-0.0.3.tar.gz", "has_sig": false, "md5_digest": "ef23abe9fb78721662963c79ead50667", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 89951, "upload_time": "2019-05-01T15:47:12", "url": "https://files.pythonhosted.org/packages/ea/b8/cde8cb1a9c9cfeffc2e9cc0b1b5a476f9a90408a17178dea6ff398b359ff/django-editorjs-field-0.0.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "ef23abe9fb78721662963c79ead50667", "sha256": "f76e476ce756b0f0ec9ba85b380a24236f0c00e91479a9d6bb2cf4bbecdbcb5c" }, "downloads": -1, "filename": "django-editorjs-field-0.0.3.tar.gz", "has_sig": false, "md5_digest": "ef23abe9fb78721662963c79ead50667", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 89951, "upload_time": "2019-05-01T15:47:12", "url": "https://files.pythonhosted.org/packages/ea/b8/cde8cb1a9c9cfeffc2e9cc0b1b5a476f9a90408a17178dea6ff398b359ff/django-editorjs-field-0.0.3.tar.gz" } ] }