Custom Spectrum Palette

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

当前为 2021-12-09 提交的版本,查看 最新版本

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。

您需要先安装用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

作者
Salvatos
评分
0 0 0
版本
1
创建于
2021-12-09
更新于
2021-12-09
大小
3.4 KB
许可证
暂无
适用于

This Kanka script modifies Spectrum color pickers to offer the user’s selection of preset colors instead of the handful of defaults, and makes it possible to enter values directly in the field under the color picker. 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