django-jsonform

A better, user-friendly JSON editing form field for Django admin. Also supports Postgres ArrayField.

BSD-3-CLAUSE License

Downloads
129.8K
Stars
334
Committers
16

Bot releases are hidden (Show)

django-jsonform - Version 2.16.0

Published by bhch over 1 year ago

django-jsonform 2.16.0 release notes

Mar 25, 2023

This release brings some new features and some bug fixes.

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

New features

  • oneOf, anyOf, allOf
    Support for oneOf, anyOf and allOf has been added. See Docs.
  • Required properties
    Support for required keyword for object properties.
  • Dark mode
    Support for dark mode.

Bugfixes

  • #92: Fixed validation for choices.
  • #94 : Fixed a bug due to which True/False were treated as valid numbers.

react-json-form (JavaScript)

react-json-form has been updated to version 2.7.1.

Thank you

I want to thank all the people who contributed code, bug reports, feature requests and improvement suggestions.

django-jsonform - Version 2.15.0

Published by bhch almost 2 years ago

django-jsonform 2.15.0 release notes

Nov 21, 2022

This release brings plenty of bug fixes and one breaking change.

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

New features

  • ErrorMap
    A new helper class for setting error messages for custom validation.

Bugfixes

  • #69: Allow hyphens in schema object keys.
  • #70: Made the widget compatible with HTMX.
  • #81: Fixed a bug due to which the error messages were not displayed under input fields.
  • #82: Fixed a bug to display error messages from multiple validators.
  • Minor fixes: #71, #73, #79.

Breaking changes

  • Custom validation
    Due to fixing issue #69 to allow hyphens (dashes) in schema object keys (i.e. field names), you should now use the ErrorMap helper class to construct the error_map object.

react-json-form (JavaScript)

react-json-form has been updated to version 2.4.0.

Thank you

I want to thank my sponsors and all the people who contributed code, bug reports, feature requests and improvement suggestions.

django-jsonform - Version 2.14.0

Published by bhch almost 2 years ago

django-jsonform 2.14.0 release notes

Nov 01, 2022

This release brings a small feature.

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

New features

  • Overriding file-url input field
    Use widget: 'fileinput' to display a simple file input field for file-url. It is useful in those cases where you don’t want to open a modal for choosing images.

react-json-form (JavaScript)

react-json-form has been updated to version 2.3.0.

Thank you

I want to thank my sponsors and all the people who contributed code, bug reports, feature requests and improvement suggestions.

django-jsonform - Version 2.13.0

Published by bhch about 2 years ago

django-jsonform 2.13.0 release notes

Oct 09, 2022

This release brings some minor but important changes.

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

Breaking changes

New features

Bugfixes

  • Some bugfixes in widget's JavaScript library.

react-json-form (JavaScript)

react-json-form has been updated to version 2.2.0.

Thank you

I want to thank all the people who contributed code, bug reports, feature requests and improvement suggestions.

django-jsonform - Version 2.12.0

Published by bhch about 2 years ago

django-jsonform 2.12.0 release notes

Sep 17, 2022

This release brings some exciting new features and a few bugfixes and improvements.

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

New features

  • Data validation
    Support for data validation.

  • Validation keywords
    Support for validation keywords — required, minLength, maxLength, minimum,
    maximum, exclusiveMinimum, exclusiveMaximum, uniqueItems.

  • Autocomplete widget
    New autocomplete widget which can load choices via AJAX requests.

  • File deletion
    A delete button has been added in Media Library thumbnails which will send a
    DELETE request to file handler endpoint. In addition to that, DELETE
    requests will automatically be sent to the server when Clear button is clicked
    or when exiting page without form submission.

  • Rename choices label keyword to title
    For consistency with JSON schema, choice label keyword has been renamed to
    title. However, the label keyword will still continue to work.

  • Range input
    Support for range input widget. Earlier range input was added using the format
    keyword, but as a range input also returns a number value (no need for a specialised format).
    Hence, it didn't make sense to use range as a format. So, now range inputs can
    be created using the widget keyword.

  • Time widget improvements
    Time widget's input spinner is now circular i.e. after reaching maximum or minimum
    value, it will start over (e.g. after 12 for hours, it will go to 0 if the hour is
    incremented and will go from 0 to 12 if decremented).

Bugfixes

  • #58: Overriding the widget in custom form's Meta class was not respected.
  • #61: Widget didn't accept attrs argument.
  • Minor improvements and fixes in widget's CSS.

react-json-form (JavaScript)

react-json-form has been updated to version 2.1.0.

Thank you

Thanks to all the people who contributed bug reports, feature requests and improvement suggestions.

django-jsonform - Version 2.11.1

Published by bhch about 2 years ago

django-jsonform 2.11.1 release notes

Aug 30, 2022

This is a minor release.

What's new

Bugfixes

  • #54: Multiselect widget didn’t work with integer types.

react-json-form (JavaScript)

react-json-form has been updated to version 2.0.2.

django-jsonform - Version 2.11.0

Published by bhch about 2 years ago

django-jsonform 2.11.0 release notes

Aug 16, 2022

This release brings plenty of bugfixes, some exciting new features and some deprecations.

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

Deprecation notice

  • JSONFORM_UPLOAD_HANDLER
    The JSONFORM_UPLOAD_HANDLER setting has been deprecated and will be removed
    in future.
    Please read about the new way to upload files in the Uploading files document.

New features

  • Brand new JavaScript API for controlling the widget in the browser.
  • Interactive playground: https://bhch.github.io/react-json-form/.
  • New file upload modal dialog which provides the ability to browse files form the server while uploading.
  • Support for enum keyword (alias for choices).
  • Support for placeholder keyword.
  • Support for date-time keyword (alias for datetime).
  • Support for handler keyword for string input. This can be used for specifying the url for the file upload handler on a per input field basis.
  • JSONField now accepts a new parameter called file_handler which can be used for specifying the url of the file handler on a per widget basis.
  • Now django-jsonform settings will be namespaced under DJANGO_JSONFORM setting.

Bugfixes

  • #45: Default value for number and boolean types was ignored if the default value was 0 or False.
  • #46: Fixed a bug due to which the multiselect widget didn't work on top-level arrays.
  • #47: Fixed a bug in CSS when two widget fields were displayed in a single fieldset row.
  • #48: Array's minItems keyword was ignored if default value for array was provided or if the form field had initial data.
  • Fixed a bug to make select input respect falsy options. Earlier, the select input would not update the selected value if a falsy option was selected.
  • Minor improvements and fixes in widget's CSS.

react-json-form (JavaScript)

react-json-form has been updated to version 2.0.0.


Finally, huge thanks to...

  • All my sponsors for their support. I really appreciate it.
  • All the people for contributing bug reports and improvement suggestions.
django-jsonform - Version 2.10.1

Published by bhch over 2 years ago

django-jsonform 2.10.1 release notes

June 10, 2022

django-jsonform v2.10.1 fixes a "high" severity security vulnerability which affects all previous versions.

XSS (Cross Site Scripting) vulnerability in the admin form

django-jsonform stores the raw JSON data of the database field in a hidden textarea on the admin page.

However, that data was kept in the textarea after unescaping it using the safe template filter. This opens up possibilities for XSS attacks.

This only affects the admin pages where the django-jsonform is rendered.

django-jsonform - Version 2.10.0

Published by bhch over 2 years ago

django-jsonform 2.10.0 release notes

June 03, 2022

This release brings some exciting new features while remaining fully backwards-compatible with the previous release (2.9.x).

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

New features

  • additionalProperties
    Now additionalProperties key can have a sub-schema of its own. Earlier, additional keys could only be of string type. But now additional keys can be anything. It also supports referencing other schema.
  • Referencing and recursion
    Now you can use the $ref keyword to reference and reuse other parts of the schema. This means you can even recursively nest an object into itself. Support for the $defs keyword has also been added so that you can declare common schema snippets in one place for reusing.
  • JSONField
    JSONField now accepts a new parameter called pre_save_hook which can be used to process or transform the JSON data before saving.

Minor improvements

  • #38: If an array has minItems set to 0 or undefined, it will be kept blank initially. If it has a default value, it will use the default value instead of being blank. Earlier, an empty item was automatically added to an array which could be undesirable in many cases.

react-json-form (JavaScript)

react-json-form has been updated to version 1.12.1.

django-jsonform - Version 2.9.0

Published by bhch over 2 years ago

django-jsonform 2.9.0 release notes

Apr 22, 2022

This version introduces some backwards-incompatible changes with the previous versions related to CSS styling and internal HTML structure.

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

New features

  • Help text
    Support for displaying help text under inputs (using the help_text or helpText keyword).
  • New template filters
    New template filters to help convert datetime strings into datetime objects in templates.
  • Compatibility with Django-Grappelli admin
    Improvements to CSS to ensure compatibility with the Django-Grappelli admin.

Bugfixes

  • #34: Fixed a CSS styling for Djang-Grappelli admin.
  • #35: Fixed a bug to reset file input when the file is cleared.

react-json-form (JavaScript)

react-json-form has been updated to version 1.11.0.

Breaking changes

The internal HTML structure of the widget, i.e. how the the fields are rendered, has been changed. Due to this, some of the CSS code has also been changed.

You don’t need to worry about this unless you’ve written custom CSS styles for the widget. If so, this is something to beware of.

django-jsonform - Version 2.8.1

Published by bhch over 2 years ago

django-jsonform 2.8.1 release notes

Mar 13, 2022

This is a minor release and is fully backwards compatible.

What's new

New features

  • Ask for confirmation before clearing file input

Bugfixes

  • #28: Fixed a bug to make the "Clear" file button visible when filename was too long.

react-json-form (JavaScript)

react-json-form has been updated to version 1.10.0.

django-jsonform - Version 2.8.0

Published by bhch over 2 years ago

django-jsonform 2.8.0 release notes

Feb 14, 2022

This version introduces no breaking changes and is fully compatible with the previous releases (2.7.x).

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

New features

  • Datetime input
    Support for datetime input has been added for string type fields using format: 'datetime' key.
    Read about its usage here: Datetime field.

  • Multiple choice selection
    Support for multiple choice selection. Learn more in usage docs: Multiple selections.

  • Default value for array
    Support for default initial value for an array. Earlier, only array itemscould have a default value.
    The problem with that is when a new item was added, the same default value was also added again.
    With this feature, it is now possible to set multiple default values on an array.

  • Clearable file inputs
    Now file upload inputs can be cleared, i.e. their value can be unset.
    Earlier, it wasn't possible to empty a file input once a value was attached.

  • Callable schema may receive the model instance
    Now the callable schema function may optionally receive the current model instance as an argument.

Bugfixes

  • #25: Fixed a bug where editing a key in an extendable dict (object) made the key disappear.
  • #27: Fixed a bug to make the editor work in admin inlines.

Minor improvements

  • Autogrowing textarea
    Textarea's height will now grow automatically as the user types in. This saves the user from having to manually resize the textarea.

  • Animated list items
    List items will have a nice animation when moved up/down or removed. This will help provide some feedback to the user.
    Earlier it wasn't obvious when list items were moved.

react-json-form (JavaScript)

react-json-form has been updated to version 1.9.0 which brings most of the above listed features.

django-jsonform - Version 2.7.0

Published by bhch over 2 years ago

django-jsonform 2.7.0 release notes

Jan 31, 2022

This version introduces no breaking changes and is fully compatible with the previous releases (2.6.x).

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

New features

  • #17: Support for lazy translations within the schema.

Bugfixes

  • #23: Package didn’t work as intended in Django 4.0 due to bad version checking.
django-jsonform - Version 2.6.0

Published by bhch almost 3 years ago

django-jsonform 2.6.0 release notes

Dec 22, 2021

This version introduces no breaking changes and is fully compatible with the previous releases (2.5.x).

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

New features

  • #15: A new keyword called default can be used to specify default values for input fields.
  • #13: A new keyword called readonly (alias readOnly) can be used to make input fields readonly.

react-json-form (JavaScript)

react-json-form has been updated to version 1.7.1.

django-jsonform - Version 2.5.0

Published by bhch almost 3 years ago

django-jsonform 2.5.0 release notes

Nov 19, 2021

This version introduces a breaking change from the previous releases.

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

react-json-form (JavaScript)

react-json-form has been updated to version 1.6.0.

Breaking changes

Earlier version used to set empty string ('') for blank number inputs. This version will use null instead.

It will also change empty strings to null in the initial data as well.

Bugfixes

  • #12: Use null instead of empty string for blank number inputs.

Minor changes

  • Small improvements to the widget's css, such as the group panel’s titles are now bolder.
django-jsonform - Version 2.4.0

Published by bhch almost 3 years ago

django-jsonform 2.4.0 release notes

Nov 08, 2021

This version is fully backwards compatible with the previous version (v2.2.x).

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

react-json-form (JavaScript)

react-json-form has been updated to version 1.5.2. This version fixes the bug related to choice inputs.

Bugfixes

  • #7: Earlier version required psycopg2 to be installed because of ArrayField. Now, psycopg2 isn't required unless ArrayField is used.
  • #9: Choices for the choice input field were not being set from the data.

Minor changes

  • Small improvements to the widget's css and icons
django-jsonform - Version 2.3.0

Published by bhch about 3 years ago

django-jsonform 2.3.0 release notes

Sep 22, 2021

This version is fully backwards compatible with the previous version (v2.2.x).

Like the previous version, it also supports Django >= 2.0 and Python >= 3.4.

What's new

react-json-form (JavaScript)

react-json-form has been updated to version 1.5.1. This version implements following new features and many bugfixes.

Textarea input

Now a textarea input can be specified for a string field using the widget keyword.

Movable array items

Array items can now be re-ordered using arrow buttons.

Bugfixes

  • Choices for boolean type will now return a boolean value.
  • Integer field’s value was set as string before. Now it will be set as a number.
  • Initial blank data was not set for certain fields (booleans, integers).
  • Checkbox couldn’t be unchecked once checked.

Minor changes

  • Small improvements to the widget’s css
  • Javascript performance improvements
django-jsonform - Version 2.2.1

Published by bhch about 3 years ago

django-jsonform 2.2.1 release notes

Sep 21, 2021

This is a minor release and adds no new features.

Bugfixes

  • #3: NoReverseMatch exception was raised if django_jsonform's urls weren't registered.
django-jsonform - Version 2.2.0

Published by bhch about 3 years ago

django-jsonform 2.2.0 release notes

Sep 14, 2021

This version adds no new featurs and is fully backwards compatible.

Fix bad package

Templates and static files weren’t included in the previous builds. This version includes all the required files.

Previous versions are not usable due to this embarrassing mistake.

django-jsonform - Version 2.1.0

Published by bhch about 3 years ago

django-jsonform 2.1.0 release notes

Sep 09, 2021

This version is fully backwards compatible.

What's new

Callable schema

schema can now be a callable. This allows for specifying choices dynamically, among other things.

Minor changes

Improvements to the widget's CSS:

  • Fixed: the remove button overlapped the input field on mobile.
  • Fixed: select input wasn't the same width as other inputs.
Package Rankings
Top 4.48% on Pypi.org
Related Projects