GUACAMOLE-773: Consider Pickr available only if initialization has completed.

In previous versions of Pickr, catching exceptions during Pickr creation
was sufficient to detect whether Pickr can be used with the current
browser. This is no longer the case, and we must instead rely on the
lack of an "init" event.
This commit is contained in:
Michael Jumper
2021-06-02 15:45:47 -07:00
parent 700e2023af
commit 82161ae712

View File

@@ -202,7 +202,7 @@ angular.module('form').provider('colorPickerService', function colorPickerServic
* selectColor(), false otherwise.
*/
service.isAvailable = function isAvailable() {
return !!pickr;
return pickrInitComplete;
};
/**