charettes / django-colorful

Extension to the Django web framework that provides database and form color fields
https://pypi.python.org/pypi/django-colorful
MIT License
169 stars 58 forks source link

modal dialog? #43

Closed ulges closed 7 years ago

ulges commented 7 years ago

Hi there,

we use RGBColorField (great tool!) in our django application. I wonder if it's possible for it to behave like a modal dialog...?

Scenario:

Are there any solutions for preventing the web page from closing before closing the color picker dialog?

Thanks in advance! Adrian

charettes commented 7 years ago

Hello Adrian!

I'm not sure I understand your request. From what I know the color input toggle is a node of the page and cannot outlive it. Would it be possible to provide screenshots to assist your report?

Best, Simon

ulges commented 7 years ago

Sure -

1.) I clicked on the RGBColorField below (bottom left, where it says "Farbe"), and the color picker dialog opens. shot1

2.) I close the browser tab. The color picker dialog is still there, but with a different web page in the background. shot2

In case it's relevant: I'm running Firefox 55.0.2 and Django 1.11.5.

Cheers, Adrian

charettes commented 7 years ago

Hey Adrian,

Thanks for the screenshots! It looks like this is actually the default behaviour of the <input type="color" /> and there isn't much this project can do about it.

I managed to reproduce using this fiddle on Ubuntu/macOS Firefox/Chrome.

Best, Simon

ulges commented 7 years ago

OK - thanks anyway for looking into it. Cheers, Adrian