django-jsoneditor icon indicating copy to clipboard operation
django-jsoneditor copied to clipboard

What is the proper way to modify width and hight of the field in admin panel?

Open anryangelov opened this issue 4 years ago • 2 comments

Should I override https://github.com/nnseva/django-jsoneditor/blob/6150a3d1ae9f97246e6b635eec62b203b7021586/jsoneditor/static/django-jsoneditor/django-jsoneditor.css#L3

anryangelov avatar Sep 02 '21 13:09 anryangelov

You can override static files using a common project-wide static folder as described in the Django documentation.

nnseva avatar Sep 03 '21 07:09 nnseva

I've done it that way but I am not sure whether it is necessary to extend JSONEditro.

class CustomJSONEditor(JSONEditor):
    class Media:
        css = {"all": ("my_jsoneditor/my_django_jsoneditor.css",)}

where my_django_jsoneditor.css contains

  div div .outer_jsoneditor {
    width: 610px;
}

Maybe with project-wide static folder there is no need to extend JSONEditor. I will check it. Thanks for your answer.

anryangelov avatar Sep 03 '21 08:09 anryangelov