When "composer" downloads "jquery_colorpicker" library it generates it's contents in "{root}/vendor/*" not in "{jquery_colorpicker_module}/vendor" so the code to replace in "jquery_colorpicker.install" should be:

if(!file_exists(DRUPAL_ROOT . '/vendor/jaypan/jquery_colorpicker/js/colorpicker.js'))

Also the library created in "jquery_colorpicker.libraries.yml" it's wrong.

To workaround this I have copied the library in root to this module root folder.

Comments

bdominguez created an issue. See original summary.

Jaypan’s picture

Can you please give me some more information about how you installed it? Did you run composer update from the module root, or from somewhere else?

Thank you.

bdominguez’s picture

I ran "composer drupal-update" from drupal root folder.

Jaypan’s picture

Status: Active » Fixed

Thank you for that.

I've decided to drop composer as an installer for this module, as it turns out only folders created by composer should be in the /vendor folder, thereby limiting the users of this module to those who know how to use composer.

I've released a new version of the module (8.x-1.0-rc2) that will look for the module in DRUPAL_ROOT/libraries/jquery_colorpicker, so you'll need to move your library from /vendor/jaypan/jquery_colorpicker when updating form RC1 to RC2. Sorry about the hassles.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.