django-admin-json-editor icon indicating copy to clipboard operation
django-admin-json-editor copied to clipboard

Fixes rendering issues with django 2.2

Open karangupta31 opened this issue 4 years ago • 3 comments

The issues being faced with the bootstrap not rendering properly seem to be because of the django "aligned" class on fieldsets. I have added 2 options to the plugin to remove the aligned class from the plugin.

This is a workaround till we don't have a proper solution.

karangupta31 avatar Jan 14 '21 12:01 karangupta31

This is more adding a new theme than fixing some rendering issues. Then you are removing django admin classes from javascript which does not seem the proper way to handle that, have you tried overriding stuff in css instead? BTW have you tried using the html theme?

xrmx avatar Jan 28 '21 08:01 xrmx

This is more adding a new theme than fixing some rendering issues. Then you are removing django admin classes from javascript which does not seem the proper way to handle that, have you tried overriding stuff in css instead? BTW have you tried using the html theme?

@xrmx I added the new theme, because it looked better overall than the bootstrap theme. The html theme looked really bad.

Overriding stuff in css meant, overriding everything django class had under it. I could have changed a few things and made it work for the test scenarios, but i couldn't assure that those 2/3 or 5 overridden styling would help for any new type of property. Django classes really mess up almost every element from the plugin. I tried to be as generic as possible with the solution i implemented. I agree that this is a hack, but its definitely better than the broken state of the package. I'm open to suggestions.

I read about how django form media works and the different properties, but couldn't find anything that might remove the affect of a parent css from the child. The only 2 options i could make out was what i implemented.

karangupta31 avatar Jan 28 '21 09:01 karangupta31

@abogushov Can you please take a look?

karangupta31 avatar Sep 20 '21 12:09 karangupta31