Custom Spectrum Palette

Modifies Spectrum color pickers to offer the user’s selection of preset colors and accept input.

目前為 2023-11-12 提交的版本,檢視 最新版本

作者
Salvatos
評價
0 0 0
版本
3
建立日期
2021-12-09
更新日期
2023-11-12
尺寸
3.8 KB
授權條款
未知
腳本執行於

This Kanka script modifies Spectrum color pickers to offer the user’s selection of preset colors instead of the handful of defaults. This applies to forms such as Events, Relations and Map Markers. Let me know if you find another that would need this.

The script as released will show the same colors as standard, but split into two rows to demonstrate the syntax. To customize your palette, you will need to add your color values in any valid format to the palette setting in the spectrumSettings function, as identified in the script.

  • Each line enclosed in square brackets corresponds to a row of options in the color picker. There is no technical limit to the number of colors per row (that I know of).
  • Each line should end with a comma, except the last row.
  • Values are enclosed in quotation marks and separated by commas.

Valid formats are listed in Spectrum’s documentation: https://bgrins.github.io/spectrum/#details-acceptedColorInputs


If my scripts are making your life easier, please consider tipping via Ko-fi (no account needed):

Support me on Ko-fi.com