Closed (fixed)
Project:
Style Options
Version:
1.1.x-dev
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
12 Jun 2023 at 06:42 UTC
Updated:
3 Sep 2025 at 07:48 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
immoreel commentedPatch works, thanks!
Comment #3
immoreel commentedComment #4
immoreel commentedOh also: the documentation could use an update about how to install spectrum...
Comment #6
ant1#4: With this patch, it should not be needed as it is done automatticaly.
Comment #7
tijsdeboeckRe #4 , it might be useful to add it in the readme, just in case someone isn't using Composer?
Comment #8
jsheffers commentedThis won't apply to dev, but I was able to get it working manually.
Comment #9
idas commentedComposer didn't install the library for me, but by applying this patch, which fixes the issues with the "once" element, and putting the files in the library manually, everything works smoothly.
Comment #10
jnettikI updated this patch so it works against latest dev. Issue is the .info.yml file was trying to modify the packaged version.
Comment #11
justin2pin commentedCommitted with patch from #10.
Comment #13
alisonIs it possible #10 didn't make it in after all?
-------
I don't see this fix in the 1.1.x commit log on GitLab (or the 1.0.x commit log), or in the June 2024 1.1.0 release (and actually, I don't see a commit link in this issue thread).
So, I looked at the Style Options project on GitLab, and I don't see the changes in any of the relevant files there, either (I figured, sometimes maintainers make the changes manually / in commits not directly tied to issue threads, due to limited time).
Comment #14
alison⚠️ [EDIT - I made mistakes in this patch! - new version on the way - please ignore this entire comment!]
I did some more investigating!
TL;DR: Attached is a new patch that does "what's left" from #10. In my testing, this patch applies cleanly to both 1.1.x-dev and 1.0.x-dev. [EDIT: It also applies cleanly to 1.1.0.]
(I can't change the status back to "needs review," but hopefully this will help anyone who stumbles upon this issue in the meantime!)
More details:
1️⃣ Looks like this commit, March 19, 2024: https://git.drupalcode.org/project/style_options/-/commit/5736bd1fa7b7d8...
core/oncedependency to style_options.libraries.yml2️⃣ This commit, April 21, 2024: https://git.drupalcode.org/project/style_options/-/commit/112a40a8b843b1...
does the change to style_options.info.yml that was in the patch on #10 (simply updating
core_version_requirement)So, the attached patch does "the rest of what was in #10" (other changes to style_options.libraries.yml).
Comment #15
alisonTerribly sorry for my mistakes in #14 and subsequent thread clutter!
This new-new patch (#15) only does two things:
In my testing, this patch (#15) applies cleanly to 1.1.x-dev, 1.0.x-dev, and 1.1.0, and the Spectrum functionality is working properly on my site.
Issue status
Spectrum is still broken for me (1.1.0 and 1.1.x-dev), because the Spectrum library version and external source part of this issue (and the remaining part of the patch on #10) hasn't been committed/fixed, so that's why I'm posting on this thread rather than a new thread. Of course, I can't change the issue status back to "needs review," so maybe this is a bad idea... but hopefully this will help anyone who stumbles upon this issue in the meantime?
Excessive details you probably don't need
"just in case"...
#15 vs. #10
TL;DR: #10 no longer applied because of two "conflicting" commits:
1️⃣ Commit #5736bd1 (March 19, 2024), which conflicted with #10 because it...
core/oncedependency to style_options.libraries.ymlThis new patch (#15) doesn't make any changes to js/color-spectrum.jquery.js -- in my testing, Style Options + Spectrum work fine on my site leaving this JS file as-is. (I'm guessing the changes to js/color-spectrum.jquery.js in earlier versions of this patch were only necessary with the deprecated jQuery implementation?)
2️⃣ Commit #112a40a (April 21, 2024), which conflicted with #10 because it...
core_version_requirementin style_options.info.ymlIn conclusion, this new patch (#15) simply updates the Spectrum library version (1.6.0 => 1.8.0), and uses the external/CDN library.
Comment #16
ant1You're totally right. This patch didn't went through. Pity we cannot reinstate this issue.
Also checked patch on #15 and it does the job more cleanly than older patches.
Comment #17
senthilmohith commentedI have created this patch for the latest version 1.1.x. I tried this and it's working as expected. Please refer the attached screenshot.
Note: preferredFormat changed from "rgb" to "hex". This format will be helpful for the content authors.
Comment #18
allahnoor turab commentedStill issue with latest version of drupal 11.2.3.
Has anyone tested