cleanup and update of jquery-colorpicker dependency

This commit is contained in:
Darko Luketic 2021-11-29 01:25:11 +01:00
parent 665970e71a
commit d02db09056
63 changed files with 13398 additions and 4845 deletions

View File

@ -1,13 +0,0 @@
{
"folders":
[
{
"follow_symlinks": true,
"path": ".",
"folder_exclude_patterns": [
"min",
"trans"
]
}
]
}

View File

@ -1,18 +1,21 @@
<?php
require_once ('global.php');
require_once (CRAYON_RESOURCE_PHP);
require_once('global.php');
require_once(CRAYON_RESOURCE_PHP);
/* Manages fonts once they are loaded. */
class CrayonFonts extends CrayonUserResourceCollection {
// Properties and Constants ===============================================
const DEFAULT_FONT = 'monaco';
const DEFAULT_FONT_NAME = 'Monaco';
class CrayonFonts extends CrayonUserResourceCollection
{
// Properties and Constants ===============================================
// Methods ================================================================
const DEFAULT_FONT = 'monaco';
const DEFAULT_FONT_NAME = 'Monaco';
function __construct() {
$this->set_default(self::DEFAULT_FONT, self::DEFAULT_FONT_NAME);
// Methods ================================================================
function __construct()
{
$this->set_default(self::DEFAULT_FONT, self::DEFAULT_FONT_NAME);
$this->directory(CRAYON_FONT_PATH);
$this->relative_directory(CRAYON_FONT_DIR);
$this->extension('css');
@ -30,7 +33,6 @@ class CrayonFonts extends CrayonUserResourceCollection {
}
CrayonLog::debug($this->directory());
CrayonLog::debug($this->user_directory());
}
}
}
?>

View File

@ -629,5 +629,3 @@ class CrayonFormatter {
return ' ' . $dim_mode . ': ' . $hl->setting_val($name) . $dim_unit . ';';
}
}
?>

View File

@ -1,423 +1,449 @@
<?php
// Class includes
require_once ('global.php');
require_once (CRAYON_PARSER_PHP);
require_once (CRAYON_FORMATTER_PHP);
require_once (CRAYON_SETTINGS_PHP);
require_once (CRAYON_LANGS_PHP);
require_once('global.php');
require_once(CRAYON_PARSER_PHP);
require_once(CRAYON_FORMATTER_PHP);
require_once(CRAYON_SETTINGS_PHP);
require_once(CRAYON_LANGS_PHP);
/* The main class for managing the syntax highlighter */
class CrayonHighlighter {
// Properties and Constants ===============================================
private $id = '';
// URL is initially NULL, meaning none provided
private $url = NULL;
private $code = '';
private $formatted_code = '';
private $title = '';
private $line_count = 0;
private $marked_lines = array();
private $range = NULL;
private $error = '';
// Determine whether the code needs to be loaded, parsed or formatted
private $needs_load = FALSE;
private $needs_format = FALSE;
// Record the script run times
private $runtime = array();
// Whether the code is mixed
private $is_mixed = FALSE;
// Inline code on a single floating line
private $is_inline = FALSE;
private $is_highlighted = TRUE;
// Objects
// Stores the CrayonLang being used
private $language = NULL;
// A copy of the current global settings which can be overridden
private $settings = NULL;
// Methods ================================================================
function __construct($url = NULL, $language = NULL, $id = NULL) {
if ($url !== NULL) {
$this->url($url);
}
if ($language !== NULL) {
$this->language($language);
}
// Default ID
$id = $id !== NULL ? $id : uniqid();
$this->id($id);
}
/* Tries to load the code locally, then attempts to load it remotely */
private function load() {
if (empty($this->url)) {
$this->error('The specified URL is empty, please provide a valid URL.');
return;
}
// Try to replace the URL with an absolute path if it is local, used to prevent scripts
// from executing when they are loaded.
$url = $this->url;
if ($this->setting_val(CrayonSettings::DECODE_ATTRIBUTES)) {
$url = CrayonUtil::html_entity_decode($url);
}
$url = CrayonUtil::pathf($url);
$site_http = CrayonGlobalSettings::site_url();
$scheme = parse_url($url, PHP_URL_SCHEME);
// Try to replace the site URL with a path to force local loading
if (empty($scheme)) {
// No url scheme is given - path may be given as relative
$url = CrayonUtil::path_slash($site_http) . CrayonUtil::path_slash($this->setting_val(CrayonSettings::LOCAL_PATH)) . $url;
}
$http_code = 0;
// If available, use the built in wp remote http get function.
if (function_exists('wp_remote_get')) {
$url_uid = 'crayon_' . CrayonUtil::str_uid($url);
$cached = get_transient($url_uid, 'crayon-syntax');
CrayonSettingsWP::load_cache();
if ($cached !== FALSE) {
$content = $cached;
$http_code = 200;
} else {
$response = @wp_remote_get($url, array('sslverify' => false, 'timeout' => 20));
$content = wp_remote_retrieve_body($response);
$http_code = wp_remote_retrieve_response_code($response);
$cache = $this->setting_val(CrayonSettings::CACHE);
$cache_sec = CrayonSettings::get_cache_sec($cache);
if ($cache_sec > 1 && $http_code >= 200 && $http_code < 400) {
set_transient($url_uid, $content, $cache_sec);
CrayonSettingsWP::add_cache($url_uid);
}
}
} else if (in_array(parse_url($url, PHP_URL_SCHEME), array('ssl', 'http', 'https'))) {
// Fallback to cURL. At this point, the URL scheme must be valid.
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_HEADER, FALSE);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);
// For https connections, we do not require SSL verification
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 20);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
curl_setopt($ch, CURLOPT_FRESH_CONNECT, FALSE);
curl_setopt($ch, CURLOPT_MAXREDIRS, 5);
if (isset($_SERVER['HTTP_USER_AGENT'])) {
curl_setopt($ch, CURLOPT_USERAGENT, $_SERVER['HTTP_USER_AGENT']);
}
$content = curl_exec($ch);
$error = curl_error($ch);
$http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
}
if ($http_code >= 200 && $http_code < 400) {
$this->code($content);
} else {
if (empty($this->code)) {
// If code is also given, just use that
$this->error("The provided URL ('$this->url'), parsed remotely as ('$url'), could not be accessed.");
}
}
$this->needs_load = FALSE;
}
/* Central point of access for all other functions to update code. */
public function process() {
$tmr = new CrayonTimer();
$this->runtime = NULL;
if ($this->needs_load) {
$tmr->start();
$this->load();
$this->runtime[CRAYON_LOAD_TIME] = $tmr->stop();
}
if (!empty($this->error) || empty($this->code)) {
// Disable highlighting for errors and empty code
return;
}
if ($this->language === NULL) {
$this->language_detect();
}
if ($this->needs_format) {
$tmr->start();
try {
// Parse before hand to read modes
$code = $this->code;
// If inline, then combine lines into one
if ($this->is_inline) {
$code = preg_replace('#[\r\n]+#ms', '', $code);
if ($this->setting_val(CrayonSettings::TRIM_WHITESPACE)) {
$code = trim($code);
}
}
// Decode html entities (e.g. if using visual editor or manually encoding)
if ($this->setting_val(CrayonSettings::DECODE)) {
$code = CrayonUtil::html_entity_decode($code);
}
// Save code so output is plain output is the same
$this->code = $code;
// Allow mixed if langauge supports it and setting is set
CrayonParser::parse($this->language->id());
if (!$this->setting_val(CrayonSettings::MIXED) || !$this->language->mode(CrayonParser::ALLOW_MIXED)) {
// Format the code with the generated regex and elements
$this->formatted_code = CrayonFormatter::format_code($code, $this->language, $this);
} else {
// Format the code with Mixed Highlighting
$this->formatted_code = CrayonFormatter::format_mixed_code($code, $this->language, $this);
}
} catch (Exception $e) {
$this->error($e->message());
return;
}
$this->needs_format = FALSE;
$this->runtime[CRAYON_FORMAT_TIME] = $tmr->stop();
}
}
/* Used to format the glue in between code when finding mixed languages */
private function format_glue($glue, $highlight = TRUE) {
// TODO $highlight
return CrayonFormatter::format_code($glue, $this->language, $this, $highlight);
}
class CrayonHighlighter
{
// Properties and Constants ===============================================
private $id = '';
// URL is initially NULL, meaning none provided
private $url = NULL;
private $code = '';
private $formatted_code = '';
private $title = '';
private $line_count = 0;
private $marked_lines = array();
private $range = NULL;
private $error = '';
// Determine whether the code needs to be loaded, parsed or formatted
private $needs_load = FALSE;
private $needs_format = FALSE;
// Record the script run times
private $runtime = array();
// Whether the code is mixed
private $is_mixed = FALSE;
// Inline code on a single floating line
private $is_inline = FALSE;
private $is_highlighted = TRUE;
/* Sends the code to the formatter for printing. Apart from the getters and setters, this is
the only other function accessible outside this class. $show_lines can also be a string. */
function output($show_lines = TRUE, $print = TRUE) {
$this->process();
if (empty($this->error)) {
// If no errors have occured, print the formatted code
$ret = CrayonFormatter::print_code($this, $this->formatted_code, $show_lines, $print);
} else {
$ret = CrayonFormatter::print_error($this, $this->error, '', $print);
}
// Reset the error message at the end of the print session
$this->error = '';
// If $print = FALSE, $ret will contain the output
return $ret;
}
// Objects
// Stores the CrayonLang being used
private $language = NULL;
// A copy of the current global settings which can be overridden
private $settings = NULL;
// Getters and Setters ====================================================
function code($code = NULL) {
if ($code === NULL) {
return $this->code;
} else {
// Trim whitespace
if ($this->setting_val(CrayonSettings::TRIM_WHITESPACE)) {
$code = preg_replace("#(?:^\\s*\\r?\\n)|(?:\\r?\\n\\s*$)#", '', $code);
}
// Methods ================================================================
function __construct($url = NULL, $language = NULL, $id = NULL)
{
if ($url !== NULL) {
$this->url($url);
}
if ($language !== NULL) {
$this->language($language);
}
// Default ID
$id = $id !== NULL ? $id : uniqid();
$this->id($id);
}
/* Tries to load the code locally, then attempts to load it remotely */
private function load()
{
if (empty($this->url)) {
$this->error('The specified URL is empty, please provide a valid URL.');
return;
}
// Try to replace the URL with an absolute path if it is local, used to prevent scripts
// from executing when they are loaded.
$url = $this->url;
if ($this->setting_val(CrayonSettings::DECODE_ATTRIBUTES)) {
$url = CrayonUtil::html_entity_decode($url);
}
$url = CrayonUtil::pathf($url);
$site_http = CrayonGlobalSettings::site_url();
$scheme = parse_url($url, PHP_URL_SCHEME);
// Try to replace the site URL with a path to force local loading
if (empty($scheme)) {
// No url scheme is given - path may be given as relative
$url = CrayonUtil::path_slash($site_http) . CrayonUtil::path_slash($this->setting_val(CrayonSettings::LOCAL_PATH)) . $url;
}
$http_code = 0;
// If available, use the built in wp remote http get function.
if (function_exists('wp_remote_get')) {
$url_uid = 'crayon_' . CrayonUtil::str_uid($url);
$cached = get_transient($url_uid, 'crayon-syntax');
CrayonSettingsWP::load_cache();
if ($cached !== FALSE) {
$content = $cached;
$http_code = 200;
} else {
$response = @wp_remote_get($url, array('sslverify' => false, 'timeout' => 20));
$content = wp_remote_retrieve_body($response);
$http_code = wp_remote_retrieve_response_code($response);
$cache = $this->setting_val(CrayonSettings::CACHE);
$cache_sec = CrayonSettings::get_cache_sec($cache);
if ($cache_sec > 1 && $http_code >= 200 && $http_code < 400) {
set_transient($url_uid, $content, $cache_sec);
CrayonSettingsWP::add_cache($url_uid);
}
}
} else if (in_array(parse_url($url, PHP_URL_SCHEME), array('ssl', 'http', 'https'))) {
// Fallback to cURL. At this point, the URL scheme must be valid.
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_HEADER, FALSE);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);
// For https connections, we do not require SSL verification
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 20);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
curl_setopt($ch, CURLOPT_FRESH_CONNECT, FALSE);
curl_setopt($ch, CURLOPT_MAXREDIRS, 5);
if (isset($_SERVER['HTTP_USER_AGENT'])) {
curl_setopt($ch, CURLOPT_USERAGENT, $_SERVER['HTTP_USER_AGENT']);
}
$content = curl_exec($ch);
$error = curl_error($ch);
$http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
}
if ($http_code >= 200 && $http_code < 400) {
$this->code($content);
} else {
if (empty($this->code)) {
// If code is also given, just use that
$this->error("The provided URL ('$this->url'), parsed remotely as ('$url'), could not be accessed.");
}
}
$this->needs_load = FALSE;
}
/* Central point of access for all other functions to update code. */
public function process()
{
$tmr = new CrayonTimer();
$this->runtime = NULL;
if ($this->needs_load) {
$tmr->start();
$this->load();
$this->runtime[CRAYON_LOAD_TIME] = $tmr->stop();
}
if (!empty($this->error) || empty($this->code)) {
// Disable highlighting for errors and empty code
return;
}
if ($this->language === NULL) {
$this->language_detect();
}
if ($this->needs_format) {
$tmr->start();
try {
// Parse before hand to read modes
$code = $this->code;
// If inline, then combine lines into one
if ($this->is_inline) {
$code = preg_replace('#[\r\n]+#ms', '', $code);
if ($this->setting_val(CrayonSettings::TRIM_WHITESPACE)) {
$code = trim($code);
}
}
// Decode html entities (e.g. if using visual editor or manually encoding)
if ($this->setting_val(CrayonSettings::DECODE)) {
$code = CrayonUtil::html_entity_decode($code);
}
// Save code so output is plain output is the same
$this->code = $code;
// Allow mixed if langauge supports it and setting is set
CrayonParser::parse($this->language->id());
if (!$this->setting_val(CrayonSettings::MIXED) || !$this->language->mode(CrayonParser::ALLOW_MIXED)) {
// Format the code with the generated regex and elements
$this->formatted_code = CrayonFormatter::format_code($code, $this->language, $this);
} else {
// Format the code with Mixed Highlighting
$this->formatted_code = CrayonFormatter::format_mixed_code($code, $this->language, $this);
}
} catch (Exception $e) {
$this->error($e->message());
return;
}
$this->needs_format = FALSE;
$this->runtime[CRAYON_FORMAT_TIME] = $tmr->stop();
}
}
/* Used to format the glue in between code when finding mixed languages */
private function format_glue($glue, $highlight = TRUE)
{
// TODO $highlight
return CrayonFormatter::format_code($glue, $this->language, $this, $highlight);
}
/* Sends the code to the formatter for printing. Apart from the getters and setters, this is
the only other function accessible outside this class. $show_lines can also be a string. */
function output($show_lines = TRUE, $print = TRUE)
{
$this->process();
if (empty($this->error)) {
// If no errors have occured, print the formatted code
$ret = CrayonFormatter::print_code($this, $this->formatted_code, $show_lines, $print);
} else {
$ret = CrayonFormatter::print_error($this, $this->error, '', $print);
}
// Reset the error message at the end of the print session
$this->error = '';
// If $print = FALSE, $ret will contain the output
return $ret;
}
// Getters and Setters ====================================================
function code($code = NULL)
{
if ($code === NULL) {
return $this->code;
} else {
// Trim whitespace
if ($this->setting_val(CrayonSettings::TRIM_WHITESPACE)) {
$code = preg_replace("#(?:^\\s*\\r?\\n)|(?:\\r?\\n\\s*$)#", '', $code);
}
if ($this->setting_val(CrayonSettings::TRIM_CODE_TAG)) {
$code = preg_replace('#^\s*<\s*code[^>]*>#msi', '', $code);
$code = preg_replace('#</\s*code[^>]*>\s*$#msi', '', $code);
}
$before = $this->setting_val(CrayonSettings::WHITESPACE_BEFORE);
if ($before > 0) {
$code = str_repeat("\n", $before) . $code;
}
$after = $this->setting_val(CrayonSettings::WHITESPACE_AFTER);
if ($after > 0) {
$code = $code . str_repeat("\n", $after);
}
if (!empty($code)) {
$this->code = $code;
$this->needs_format = TRUE;
}
}
}
$before = $this->setting_val(CrayonSettings::WHITESPACE_BEFORE);
if ($before > 0) {
$code = str_repeat("\n", $before) . $code;
}
$after = $this->setting_val(CrayonSettings::WHITESPACE_AFTER);
if ($after > 0) {
$code = $code . str_repeat("\n", $after);
}
function language($id = NULL) {
if ($id === NULL || !is_string($id)) {
return $this->language;
}
if ( ($lang = CrayonResources::langs()->get($id)) != FALSE || ($lang = CrayonResources::langs()->alias($id)) != FALSE ) {
// Set the language if it exists or look for an alias
$this->language = $lang;
} else {
$this->language_detect();
}
// Prepare the language for use, even if we have no code, we need the name
CrayonParser::parse($this->language->id());
}
function language_detect() {
// Attempt to detect the language
if (!empty($id)) {
$this->log("The language '$id' could not be loaded.");
}
$this->language = CrayonResources::langs()->detect($this->url, $this->setting_val(CrayonSettings::FALLBACK_LANG));
}
if (!empty($code)) {
$this->code = $code;
$this->needs_format = TRUE;
}
}
}
function url($url = NULL) {
if ($url === NULL) {
return $this->url;
} else {
$this->url = $url;
$this->needs_load = TRUE;
}
}
function language($id = NULL)
{
if ($id === NULL || !is_string($id)) {
return $this->language;
}
function title($title = NULL) {
if (!CrayonUtil::str($this->title, $title)) {
return $this->title;
}
}
if (($lang = CrayonResources::langs()->get($id)) != FALSE || ($lang = CrayonResources::langs()->alias($id)) != FALSE) {
// Set the language if it exists or look for an alias
$this->language = $lang;
} else {
$this->language_detect();
}
function line_count($line_count = NULL) {
if (!CrayonUtil::num($this->line_count, $line_count)) {
return $this->line_count;
}
}
// Prepare the language for use, even if we have no code, we need the name
CrayonParser::parse($this->language->id());
}
function marked($str = NULL) {
if ($str === NULL) {
return $this->marked_lines;
}
// If only an int is given
if (is_int($str)) {
$array = array($str);
return CrayonUtil::arr($this->marked_lines, $array);
}
// A string with ints separated by commas, can also contain ranges
$array = CrayonUtil::trim_e($str);
$array = array_unique($array);
$lines = array();
foreach ($array as $line) {
// Check for ranges
if (strpos($line, '-') !== FALSE) {
$ranges = CrayonUtil::range_str($line);
$lines = array_merge($lines, $ranges);
} else {
// Otherwise check the string for a number
$line = intval($line);
if ($line !== 0) {
$lines[] = $line;
}
}
}
return CrayonUtil::arr($this->marked_lines, $lines);
}
function range($str = NULL) {
if ($str === NULL) {
return $this->range;
} else {
$range = CrayonUtil::range_str_single($str);
if ($range) {
$this->range = $range;
}
}
return FALSE;
}
function language_detect()
{
// Attempt to detect the language
if (!empty($id)) {
$this->log("The language '$id' could not be loaded.");
}
$this->language = CrayonResources::langs()->detect($this->url, $this->setting_val(CrayonSettings::FALLBACK_LANG));
}
function log($var) {
if ($this->setting_val(CrayonSettings::ERROR_LOG)) {
CrayonLog::log($var);
}
}
function url($url = NULL)
{
if ($url === NULL) {
return $this->url;
} else {
$this->url = $url;
$this->needs_load = TRUE;
}
}
function id($id = NULL) {
if ($id == NULL) {
return $this->id;
} else {
$this->id = strval($id);
}
}
function error($string = NULL) {
if (!$string) {
return $this->error;
}
$this->error .= $string;
$this->log($string);
// Add the error string and ensure no further processing occurs
$this->needs_load = FALSE;
$this->needs_format = FALSE;
}
function title($title = NULL)
{
if (!CrayonUtil::str($this->title, $title)) {
return $this->title;
}
}
// Set and retreive settings
// TODO fix this, it's too limiting
function settings($mixed = NULL) {
if ($this->settings == NULL) {
$this->settings = CrayonGlobalSettings::get_obj();
}
if ($mixed === NULL) {
return $this->settings;
} else if (is_string($mixed)) {
return $this->settings->get($mixed);
} else if (is_array($mixed)) {
$this->settings->set($mixed);
return TRUE;
}
return FALSE;
}
function line_count($line_count = NULL)
{
if (!CrayonUtil::num($this->line_count, $line_count)) {
return $this->line_count;
}
}
/* Retrieve a single setting's value for use in the formatter. By default, on failure it will
* return TRUE to ensure FALSE is only sent when a setting is found. This prevents a fake
* FALSE when the formatter checks for a positive setting (Show/Enable) and fails. When a
* negative setting is needed (Hide/Disable), $default_return should be set to FALSE. */
// TODO fix this (see above)
function setting_val($name = NULL, $default_return = TRUE) {
if (is_string($name) && $setting = $this->settings($name)) {
return $setting->value();
} else {
// Name not valid
return (is_bool($default_return) ? $default_return : TRUE);
}
}
// Set a setting value
// TODO fix this (see above)
function setting_set($name = NULL, $value = TRUE) {
$this->settings->set($name, $value);
}
function marked($str = NULL)
{
if ($str === NULL) {
return $this->marked_lines;
}
// If only an int is given
if (is_int($str)) {
$array = array($str);
return CrayonUtil::arr($this->marked_lines, $array);
}
// A string with ints separated by commas, can also contain ranges
$array = CrayonUtil::trim_e($str);
$array = array_unique($array);
$lines = array();
foreach ($array as $line) {
// Check for ranges
if (strpos($line, '-') !== FALSE) {
$ranges = CrayonUtil::range_str($line);
$lines = array_merge($lines, $ranges);
} else {
// Otherwise check the string for a number
$line = intval($line);
if ($line !== 0) {
$lines[] = $line;
}
}
}
return CrayonUtil::arr($this->marked_lines, $lines);
}
// Used to find current index in dropdown setting
function setting_index($name = NULL) {
$setting = $this->settings($name);
if (is_string($name) && $setting->is_array()) {
return $setting->index();
} else {
// Returns -1 to avoid accidentally selecting an item in a dropdown
return CrayonSettings::INVALID;
}
}
function range($str = NULL)
{
if ($str === NULL) {
return $this->range;
} else {
$range = CrayonUtil::range_str_single($str);
if ($range) {
$this->range = $range;
}
}
return FALSE;
}
function formatted_code() {
return $this->formatted_code;
}
function log($var)
{
if ($this->setting_val(CrayonSettings::ERROR_LOG)) {
CrayonLog::log($var);
}
}
function runtime() {
return $this->runtime;
}
function is_highlighted($highlighted = NULL) {
if ($highlighted === NULL) {
return $this->is_highlighted;
} else {
$this->is_highlighted = $highlighted;
}
}
function is_mixed($mixed = NULL) {
if ($mixed === NULL) {
return $this->is_mixed;
} else {
$this->is_mixed = $mixed;
}
}
function is_inline($inline = NULL) {
if ($inline === NULL) {
return $this->is_inline;
} else {
$inline = CrayonUtil::str_to_bool($inline, FALSE);
$this->is_inline = $inline;
}
}
function id($id = NULL)
{
if ($id == NULL) {
return $this->id;
} else {
$this->id = strval($id);
}
}
function error($string = NULL)
{
if (!$string) {
return $this->error;
}
$this->error .= $string;
$this->log($string);
// Add the error string and ensure no further processing occurs
$this->needs_load = FALSE;
$this->needs_format = FALSE;
}
// Set and retreive settings
// TODO fix this, it's too limiting
function settings($mixed = NULL)
{
if ($this->settings == NULL) {
$this->settings = CrayonGlobalSettings::get_obj();
}
if ($mixed === NULL) {
return $this->settings;
} else if (is_string($mixed)) {
return $this->settings->get($mixed);
} else if (is_array($mixed)) {
$this->settings->set($mixed);
return TRUE;
}
return FALSE;
}
/* Retrieve a single setting's value for use in the formatter. By default, on failure it will
* return TRUE to ensure FALSE is only sent when a setting is found. This prevents a fake
* FALSE when the formatter checks for a positive setting (Show/Enable) and fails. When a
* negative setting is needed (Hide/Disable), $default_return should be set to FALSE. */
// TODO fix this (see above)
function setting_val($name = NULL, $default_return = TRUE)
{
if (is_string($name) && $setting = $this->settings($name)) {
return $setting->value();
} else {
// Name not valid
return (is_bool($default_return) ? $default_return : TRUE);
}
}
// Set a setting value
// TODO fix this (see above)
function setting_set($name = NULL, $value = TRUE)
{
$this->settings->set($name, $value);
}
// Used to find current index in dropdown setting
function setting_index($name = NULL)
{
$setting = $this->settings($name);
if (is_string($name) && $setting->is_array()) {
return $setting->index();
} else {
// Returns -1 to avoid accidentally selecting an item in a dropdown
return CrayonSettings::INVALID;
}
}
function formatted_code()
{
return $this->formatted_code;
}
function runtime()
{
return $this->runtime;
}
function is_highlighted($highlighted = NULL)
{
if ($highlighted === NULL) {
return $this->is_highlighted;
} else {
$this->is_highlighted = $highlighted;
}
}
function is_mixed($mixed = NULL)
{
if ($mixed === NULL) {
return $this->is_mixed;
} else {
$this->is_mixed = $mixed;
}
}
function is_inline($inline = NULL)
{
if ($inline === NULL) {
return $this->is_inline;
} else {
$inline = CrayonUtil::str_to_bool($inline, FALSE);
$this->is_inline = $inline;
}
}
}
?>

File diff suppressed because it is too large Load Diff

View File

@ -1,265 +1,275 @@
<?php
require_once ('global.php');
require_once (CRAYON_LANGS_PHP);
require_once('global.php');
require_once(CRAYON_LANGS_PHP);
/* Manages parsing the syntax for any given language, constructing the regex, and validating the
elements. */
class CrayonParser {
// Properties and Constants ===============================================
const CASE_INSENSITIVE = 'CASE_INSENSITIVE';
const MULTI_LINE = 'MULTI_LINE';
const SINGLE_LINE = 'SINGLE_LINE';
const ALLOW_MIXED = 'ALLOW_MIXED';
//const NO_END_TAG = '(?![^<]*>)'; // No longer used
const HTML_CHAR = 'HTML_CHAR';
const HTML_CHAR_REGEX = '<|>|(&([\w-]+);?)|[ \t]+';
const CRAYON_ELEMENT = 'CRAYON_ELEMENT';
const CRAYON_ELEMENT_REGEX = '\{\{crayon-internal:[^\}]*\}\}';
const CRAYON_ELEMENT_REGEX_CAPTURE = '\{\{crayon-internal:([^\}]*)\}\}';
private static $modes = array(self::CASE_INSENSITIVE => TRUE, self::MULTI_LINE => TRUE, self::SINGLE_LINE => TRUE, self::ALLOW_MIXED => TRUE);
class CrayonParser
{
// Properties and Constants ===============================================
const CASE_INSENSITIVE = 'CASE_INSENSITIVE';
const MULTI_LINE = 'MULTI_LINE';
const SINGLE_LINE = 'SINGLE_LINE';
const ALLOW_MIXED = 'ALLOW_MIXED';
//const NO_END_TAG = '(?![^<]*>)'; // No longer used
const HTML_CHAR = 'HTML_CHAR';
const HTML_CHAR_REGEX = '<|>|(&([\w-]+);?)|[ \t]+';
const CRAYON_ELEMENT = 'CRAYON_ELEMENT';
const CRAYON_ELEMENT_REGEX = '\{\{crayon-internal:[^\}]*\}\}';
const CRAYON_ELEMENT_REGEX_CAPTURE = '\{\{crayon-internal:([^\}]*)\}\}';
// Methods ================================================================
private function __construct() {}
private static $modes = array(self::CASE_INSENSITIVE => TRUE, self::MULTI_LINE => TRUE, self::SINGLE_LINE => TRUE, self::ALLOW_MIXED => TRUE);
/**
* Parse all languages stored in CrayonLangs.
* Avoid using this unless you must list the details in language files for all languages.
* @return array Array of all loaded CrayonLangs.
*/
public static function parse_all() {
$langs = CrayonResources::langs()->get();
if (empty($langs)) {
return FALSE;
}
foreach ($langs as $lang) {
self::parse($lang->id());
}
return $langs;
}
// Methods ================================================================
private function __construct()
{
}
/* Read a syntax file and parse the regex rules within it, this may require several other
files containing lists of keywords and such to be read. Updates the parsed elements and
regex in the CrayonLang with the given $id. */
public static function parse($id) {
// Verify the language is loaded and has not been parsed before
if ( !($lang = CrayonResources::langs()->get($id)) ) {
CrayonLog::syslog("The language with id '$id' was not loaded and could not be parsed.");
return FALSE;
} else if ($lang->is_parsed()) {
return;
}
// Read language file
$path = CrayonResources::langs()->path($id);
/**
* Parse all languages stored in CrayonLangs.
* Avoid using this unless you must list the details in language files for all languages.
* @return array Array of all loaded CrayonLangs.
*/
public static function parse_all()
{
$langs = CrayonResources::langs()->get();
if (empty($langs)) {
return FALSE;
}
foreach ($langs as $lang) {
self::parse($lang->id());
}
return $langs;
}
/* Read a syntax file and parse the regex rules within it, this may require several other
files containing lists of keywords and such to be read. Updates the parsed elements and
regex in the CrayonLang with the given $id. */
public static function parse($id)
{
// Verify the language is loaded and has not been parsed before
if (!($lang = CrayonResources::langs()->get($id))) {
CrayonLog::syslog("The language with id '$id' was not loaded and could not be parsed.");
return FALSE;
} else if ($lang->is_parsed()) {
return;
}
// Read language file
$path = CrayonResources::langs()->path($id);
CrayonLog::debug('Parsing language ' . $path);
if ( ($file = CrayonUtil::lines($path, 'wcs')) === FALSE ) {
if (($file = CrayonUtil::lines($path, 'wcs')) === FALSE) {
CrayonLog::debug('Parsing failed ' . $path);
return FALSE;
}
return FALSE;
}
// Extract the language name
$name_pattern = '#^[ \t]*name[ \t]+([^\r\n]+)[ \t]*#mi';
preg_match($name_pattern, $file, $name);
if (count($name) > 1) {
$name = $name[1];
$lang->name($name);
$file = preg_replace($name_pattern, '', $file);
} else {
$name = $lang->id();
}
// Extract the language name
$name_pattern = '#^[ \t]*name[ \t]+([^\r\n]+)[ \t]*#mi';
preg_match($name_pattern, $file, $name);
if (count($name) > 1) {
$name = $name[1];
$lang->name($name);
$file = preg_replace($name_pattern, '', $file);
} else {
$name = $lang->id();
}
// Extract the language version
$version_pattern = '#^[ \t]*version[ \t]+([^\r\n]+)[ \t]*#mi';
preg_match($version_pattern, $file, $version);
if (count($version) > 1) {
$version = $version[1];
$lang->version($version);
$file = preg_replace($version_pattern, '', $file);
}
// Extract the language version
$version_pattern = '#^[ \t]*version[ \t]+([^\r\n]+)[ \t]*#mi';
preg_match($version_pattern, $file, $version);
if (count($version) > 1) {
$version = $version[1];
$lang->version($version);
$file = preg_replace($version_pattern, '', $file);
}
// Extract the modes
$mode_pattern = '#^[ \t]*(' . implode('|', array_keys(self::$modes)) . ')[ \t]+(?:=[ \t]*)?([^\r\n]+)[ \t]*#mi';
preg_match_all($mode_pattern, $file, $mode_matches);
if (count($mode_matches) == 3) {
for ($i = 0; $i < count($mode_matches[0]); $i++) {
$lang->mode($mode_matches[1][$i], $mode_matches[2][$i]);
}
$file = preg_replace($mode_pattern, '', $file);
}
// Extract the modes
$mode_pattern = '#^[ \t]*(' . implode('|', array_keys(self::$modes)) . ')[ \t]+(?:=[ \t]*)?([^\r\n]+)[ \t]*#mi';
preg_match_all($mode_pattern, $file, $mode_matches);
if (count($mode_matches) == 3) {
for ($i = 0; $i < count($mode_matches[0]); $i++) {
$lang->mode($mode_matches[1][$i], $mode_matches[2][$i]);
}
$file = preg_replace($mode_pattern, '', $file);
}
/* Add reserved Crayon element. This is used by Crayon internally. */
$crayon_element = new CrayonElement(self::CRAYON_ELEMENT, $path, self::CRAYON_ELEMENT_REGEX);
$lang->element(self::CRAYON_ELEMENT, $crayon_element);
/* Add reserved Crayon element. This is used by Crayon internally. */
$crayon_element = new CrayonElement(self::CRAYON_ELEMENT, $path, self::CRAYON_ELEMENT_REGEX);
$lang->element(self::CRAYON_ELEMENT, $crayon_element);
// Extract elements, classes and regex
$pattern = '#^[ \t]*([\w:]+)[ \t]+(?:\[([\w\t ]*)\][ \t]+)?([^\r\n]+)[ \t]*#m';
preg_match_all($pattern, $file, $matches);
// Extract elements, classes and regex
$pattern = '#^[ \t]*([\w:]+)[ \t]+(?:\[([\w\t ]*)\][ \t]+)?([^\r\n]+)[ \t]*#m';
preg_match_all($pattern, $file, $matches);
if (!empty($matches[0])) {
$elements = $matches[1];
$classes = $matches[2];
$regexes = $matches[3];
} else {
CrayonLog::syslog("No regex patterns and/or elements were parsed from language file at '$path'.");
}
if (!empty($matches[0])) {
$elements = $matches[1];
$classes = $matches[2];
$regexes = $matches[3];
} else {
CrayonLog::syslog("No regex patterns and/or elements were parsed from language file at '$path'.");
}
// Remember state in case we encounter catchable exceptions
$error = FALSE;
for ($i = 0; $i < count($matches[0]); $i++) {
// References
$name = &$elements[$i];
$class = &$classes[$i];
$regex = &$regexes[$i];
$name = trim(strtoupper($name));
// Ensure both the element and regex are valid
if (empty($name) || empty($regex)) {
CrayonLog::syslog("Element(s) and/or regex(es) are missing in '$path'.");
$error = TRUE;
continue;
}
// Look for fallback element
$pieces = explode(':', $name);
if (count($pieces) == 2) {
$name = $pieces[0];
$fallback = $pieces[1];
} else if (count($pieces) == 1) {
$name = $pieces[0];
$fallback = '';
} else {
CrayonLog::syslog("Too many colons found in element name '$name' in '$path'");
$error = TRUE;
continue;
}
// Create a new CrayonElement
$element = new CrayonElement($name, $path);
$element->fallback($fallback);
if (!empty($class)) {
// Avoid setting known css to blank
$element->css($class);
}
if ($element->regex($regex) === FALSE) {
$error = TRUE;
continue;
}
// Add the regex to the element
$lang->element($name, $element);
$state = $error ? CrayonLang::PARSED_ERRORS : CrayonLang::PARSED_SUCCESS;
$lang->state($state);
}
// Remember state in case we encounter catchable exceptions
$error = FALSE;
for ($i = 0; $i < count($matches[0]); $i++) {
// References
$name = &$elements[$i];
$class = &$classes[$i];
$regex = &$regexes[$i];
$name = trim(strtoupper($name));
// Ensure both the element and regex are valid
if (empty($name) || empty($regex)) {
CrayonLog::syslog("Element(s) and/or regex(es) are missing in '$path'.");
$error = TRUE;
continue;
}
// Look for fallback element
$pieces = explode(':', $name);
if (count($pieces) == 2) {
$name = $pieces[0];
$fallback = $pieces[1];
} else if (count($pieces) == 1) {
$name = $pieces[0];
$fallback = '';
} else {
CrayonLog::syslog("Too many colons found in element name '$name' in '$path'");
$error = TRUE;
continue;
}
// Create a new CrayonElement
$element = new CrayonElement($name, $path);
$element->fallback($fallback);
if (!empty($class)) {
// Avoid setting known css to blank
$element->css($class);
}
if ($element->regex($regex) === FALSE) {
$error = TRUE;
continue;
}
// Add the regex to the element
$lang->element($name, $element);
$state = $error ? CrayonLang::PARSED_ERRORS : CrayonLang::PARSED_SUCCESS;
$lang->state($state);
}
/* Prevents < > and other html entities from being printed as is, which could lead to actual html tags
* from the printed code appearing on the page - not good. This can also act to color any HTML entities
* that are not picked up by previously defined elements.
*/
$html = new CrayonElement(self::HTML_CHAR, $path, self::HTML_CHAR_REGEX);
$lang->element(self::HTML_CHAR, $html);
}
/* Prevents < > and other html entities from being printed as is, which could lead to actual html tags
* from the printed code appearing on the page - not good. This can also act to color any HTML entities
* that are not picked up by previously defined elements.
*/
$html = new CrayonElement(self::HTML_CHAR, $path, self::HTML_CHAR_REGEX);
$lang->element(self::HTML_CHAR, $html);
}
// Validates regex and accesses data stored in a CrayonElement
public static function validate_regex($regex, $element) {
if (is_string($regex) && @get_class($element) == CRAYON_ELEMENT_CLASS) {
// If the (?alt) tag has been used, insert the file into the regex
$file = self::regex_match('#\(\?alt:(.+?)\)#', $regex);
if ( count($file) == 2 ) {
// Element 0 has full match, 1 has captured groups
for ($i = 0; $i < count($file[1]); $i++) {
$file_lines = CrayonUtil::lines(dirname($element->path()) . crayon_s() . $file[1][$i], 'rcwh');
if ($file_lines !== FALSE) {
$file_lines = implode('|', $file_lines);
// If any spaces exist, treat them as whitespace
$file_lines = preg_replace('#[ \t]+#msi', '\s+', $file_lines);
$regex = str_replace($file[0][$i], "(?:$file_lines)", $regex);
} else {
CrayonLog::syslog("Parsing of '{$element->path()}' failed, an (?alt) tag failed for the element '{$element->name()}'" );
return FALSE;
}
}
}
// Validates regex and accesses data stored in a CrayonElement
public static function validate_regex($regex, $element)
{
if (is_string($regex) && @get_class($element) == CRAYON_ELEMENT_CLASS) {
// If the (?alt) tag has been used, insert the file into the regex
$file = self::regex_match('#\(\?alt:(.+?)\)#', $regex);
if (count($file) == 2) {
// Element 0 has full match, 1 has captured groups
for ($i = 0; $i < count($file[1]); $i++) {
$file_lines = CrayonUtil::lines(dirname($element->path()) . crayon_s() . $file[1][$i], 'rcwh');
if ($file_lines !== FALSE) {
$file_lines = implode('|', $file_lines);
// If any spaces exist, treat them as whitespace
$file_lines = preg_replace('#[ \t]+#msi', '\s+', $file_lines);
$regex = str_replace($file[0][$i], "(?:$file_lines)", $regex);
} else {
CrayonLog::syslog("Parsing of '{$element->path()}' failed, an (?alt) tag failed for the element '{$element->name()}'");
return FALSE;
}
}
}
// If the (?default:element) function is used, replace the regex with the default, if exists
$def = self::regex_match('#\(\?default(?:\:(\w+))?\)#', $regex);
if ( count($def) == 2 ) {
// Load default language
$default = CrayonResources::langs()->get(CrayonLangs::DEFAULT_LANG);
// If default has not been loaded, we can't use it, skip the element
if (!$default) {
CrayonLog::syslog(
"Could not use default regex in the element '{$element->name()}' in '{$element->path()}'");
return FALSE;
}
for ($i = 0; $i < count($def[1]); $i++) {
// If an element has been provided
$element_name = ( !empty($def[1][$i]) ) ? $def[1][$i] : $element->name();
if (($default_element = $default->element($element_name)) != FALSE) {
$regex = str_replace($def[0][$i], '(?:' . $default_element->regex() .')', $regex);
} else {
CrayonLog::syslog("The language at '{$element->path()}' referred to the Default Language regex for element '{$element->name()}', which did not exist.");
// If the (?default:element) function is used, replace the regex with the default, if exists
$def = self::regex_match('#\(\?default(?:\:(\w+))?\)#', $regex);
if (count($def) == 2) {
// Load default language
$default = CrayonResources::langs()->get(CrayonLangs::DEFAULT_LANG);
// If default has not been loaded, we can't use it, skip the element
if (!$default) {
CrayonLog::syslog(
"Could not use default regex in the element '{$element->name()}' in '{$element->path()}'");
return FALSE;
}
for ($i = 0; $i < count($def[1]); $i++) {
// If an element has been provided
$element_name = (!empty($def[1][$i])) ? $def[1][$i] : $element->name();
if (($default_element = $default->element($element_name)) != FALSE) {
$regex = str_replace($def[0][$i], '(?:' . $default_element->regex() . ')', $regex);
} else {
CrayonLog::syslog("The language at '{$element->path()}' referred to the Default Language regex for element '{$element->name()}', which did not exist.");
if (CRAYON_DEBUG) {
CrayonLog::syslog("Default language URL: " . CrayonResources::langs()->url(CrayonLangs::DEFAULT_LANG));
CrayonLog::syslog("Default language Path: " . CrayonResources::langs()->path(CrayonLangs::DEFAULT_LANG));
}
return FALSE;
}
}
}
return FALSE;
}
}
}
// If the (?html) tag is used, escape characters in html (<, > and &)
$html = self::regex_match('#\(\?html:(.+?)\)#', $regex);
if ( count($html) == 2 ) {
for ($i = 0; $i < count($html[1]); $i++) {
$regex = str_replace($html[0][$i], htmlentities($html[1][$i]), $regex);
}
}
// If the (?html) tag is used, escape characters in html (<, > and &)
$html = self::regex_match('#\(\?html:(.+?)\)#', $regex);
if (count($html) == 2) {
for ($i = 0; $i < count($html[1]); $i++) {
$regex = str_replace($html[0][$i], htmlentities($html[1][$i]), $regex);
}
}
// Ensure all parenthesis are atomic to avoid conflicting with element matches
$regex = CrayonUtil::esc_atomic($regex);
// Ensure all parenthesis are atomic to avoid conflicting with element matches
$regex = CrayonUtil::esc_atomic($regex);
// Escape #, this is our delimiter
$regex = CrayonUtil::esc_hash($regex);
// Escape #, this is our delimiter
$regex = CrayonUtil::esc_hash($regex);
// Test if regex is valid
if (@preg_match("#$regex#", '') === FALSE) {
CrayonLog::syslog("The regex for the element '{$element->name()}' in '{$element->path()}' is not valid.");
return FALSE;
}
// Test if regex is valid
if (@preg_match("#$regex#", '') === FALSE) {
CrayonLog::syslog("The regex for the element '{$element->name()}' in '{$element->path()}' is not valid.");
return FALSE;
}
return $regex;
} else {
return '';
}
}
return $regex;
} else {
return '';
}
}
public static function validate_css($css) {
if (is_string($css)) {
// Remove dots in CSS class and convert to lowercase
$css = str_replace('.', '', $css);
$css = strtolower($css);
$css = explode(' ', $css);
$css_str = '';
foreach ($css as $c) {
if (!empty($c)) {
$css_str .= $c . ' ';
}
}
return trim($css_str);
} else {
return '';
}
}
public static function validate_css($css)
{
if (is_string($css)) {
// Remove dots in CSS class and convert to lowercase
$css = str_replace('.', '', $css);
$css = strtolower($css);
$css = explode(' ', $css);
$css_str = '';
foreach ($css as $c) {
if (!empty($c)) {
$css_str .= $c . ' ';
}
}
return trim($css_str);
} else {
return '';
}
}
public static function regex_match($pattern, $subject) {
if (preg_match_all($pattern, $subject, $matches)) {
return $matches;
}
return array();
}
public static function regex_match($pattern, $subject)
{
if (preg_match_all($pattern, $subject, $matches)) {
return $matches;
}
return array();
}
public static function modes() {
return self::$modes;
}
public static function modes()
{
return self::$modes;
}
public static function is_mode($name) {
return is_string($name) && array_key_exists($name, self::$modes);
}
public static function is_mode($name)
{
return is_string($name) && array_key_exists($name, self::$modes);
}
}
?>

View File

@ -1,296 +1,333 @@
<?php
require_once ('global.php');
require_once (CRAYON_LANGS_PHP);
require_once (CRAYON_THEMES_PHP);
require_once (CRAYON_FONTS_PHP);
require_once('global.php');
require_once(CRAYON_LANGS_PHP);
require_once(CRAYON_THEMES_PHP);
require_once(CRAYON_FONTS_PHP);
class CrayonResources {
private static $langs = NULL;
private static $themes = NULL;
private static $fonts = NULL;
class CrayonResources
{
private static $langs = NULL;
private static $themes = NULL;
private static $fonts = NULL;
private function __construct() {}
private function __construct()
{
}
public static function langs() {
public static function langs()
{
if (self::$langs == NULL) {
self::$langs = new CrayonLangs();
}
return self::$langs;
}
return self::$langs;
}
public static function themes() {
public static function themes()
{
if (self::$themes == NULL) {
self::$themes = new CrayonThemes();
}
return self::$themes;
}
return self::$themes;
}
public static function fonts() {
public static function fonts()
{
if (self::$fonts == NULL) {
self::$fonts = new CrayonFonts();
}
return self::$fonts;
}
return self::$fonts;
}
}
class CrayonResourceCollection {
// Properties and Constants ===============================================
class CrayonResourceCollection
{
// Properties and Constants ===============================================
// Loaded resources
// Loaded resources
private $collection = array();
// Loading state
private $collection = array();
// Loading state
private $state = self::UNLOADED;
// Directory containing resources
private $state = self::UNLOADED;
// Directory containing resources
private $dir = '';
private $default_id = '';
private $default_name = '';
const UNLOADED = -1;
const LOADING = 0;
const LOADED = 1;
private $dir = '';
private $default_id = '';
private $default_name = '';
const UNLOADED = -1;
const LOADING = 0;
const LOADED = 1;
// Methods ================================================================
// Methods ================================================================
/* Override in subclasses. Returns the absolute path for a given resource. Does not check for its existence. */
public function path($id) {
return '';
}
/* Override in subclasses. Returns the absolute path for a given resource. Does not check for its existence. */
public function path($id)
{
return '';
}
/* Verifies a resource exists. */
public function exists($id) {
return file_exists($this->path($id));
}
/* Verifies a resource exists. */
public function exists($id)
{
return file_exists($this->path($id));
}
/* Load all the available languages. Doesn't parse them for their names and regex. */
public function load() {
// Load only once
/* Load all the available languages. Doesn't parse them for their names and regex. */
public function load()
{
// Load only once
if (!$this->is_state_unloaded()) {
return;
}
$this->state = self::LOADING;
$this->load_process();
$this->state = self::LOADED;
}
if (!$this->is_state_unloaded()) {
return;
}
$this->state = self::LOADING;
$this->load_process();
$this->state = self::LOADED;
}
public function load_resources($dir = NULL) {
public function load_resources($dir = NULL)
{
if ($dir === NULL) {
$dir = $this->dir;
}
if (!$this->is_state_loading()) {
if (!$this->is_state_loading()) {
// Load only once
return;
}
try {
// Look in directory for resources
return;
}
try {
// Look in directory for resources
if (!is_dir($dir)) {
CrayonLog::syslog('The resource directory is missing, should be at \'' . $dir . '\'.');
} else if (($handle = @opendir($dir)) != FALSE) {
// Loop over directory contents
while (($file = readdir($handle)) !== FALSE) {
if ($file != "." && $file != "..") {
// Check if $file is directory, remove extension when checking for existence.
if (!is_dir($dir)) {
CrayonLog::syslog('The resource directory is missing, should be at \'' . $dir . '\'.');
} else if (($handle = @opendir($dir)) != FALSE) {
// Loop over directory contents
while (($file = readdir($handle)) !== FALSE) {
if ($file != "." && $file != "..") {
// Check if $file is directory, remove extension when checking for existence.
if (!is_dir($dir . $file)) {
$file = CrayonUtil::path_rem_ext($file);
}
if ($this->exists($file)) {
$this->add_resource($this->resource_instance($file));
}
}
}
closedir($handle);
}
} catch (Exception $e) {
CrayonLog::syslog('An error occured when trying to load resources: ' . $e->getFile() . $e->getLine());
}
}
if (!is_dir($dir . $file)) {
$file = CrayonUtil::path_rem_ext($file);
}
if ($this->exists($file)) {
$this->add_resource($this->resource_instance($file));
}
}
}
closedir($handle);
}
} catch (Exception $e) {
CrayonLog::syslog('An error occured when trying to load resources: ' . $e->getFile() . $e->getLine());
}
}
/* Override in subclasses. */
public function load_process() {
if (!$this->is_state_loading()) {
return;
}
$this->load_resources();
$this->add_default();
}
/* Override in subclasses. */
public function load_process()
{
if (!$this->is_state_loading()) {
return;
}
$this->load_resources();
$this->add_default();
}
/* Override in subclasses */
public function add_default() {
if (!$this->is_state_loading()) {
return FALSE;
} else if (!$this->is_loaded($this->default_id)) {
CrayonLog::syslog('The default resource could not be loaded from \'' . $this->dir . '\'.');
// Add the default, but it will not be functionable
/* Override in subclasses */
public function add_default()
{
if (!$this->is_state_loading()) {
return FALSE;
} else if (!$this->is_loaded($this->default_id)) {
CrayonLog::syslog('The default resource could not be loaded from \'' . $this->dir . '\'.');
// Add the default, but it will not be functionable
$default = $this->resource_instance($this->default_id, $this->default_name);
$this->add($this->default_id, $default);
return TRUE;
}
return FALSE;
}
$default = $this->resource_instance($this->default_id, $this->default_name);
$this->add($this->default_id, $default);
return TRUE;
}
return FALSE;
}
/* Returns the default resource */
public function set_default($id, $name) {
$this->default_id = $id;
$this->default_name = $name;
}
/* Returns the default resource */
public function set_default($id, $name)
{
$this->default_id = $id;
$this->default_name = $name;
}
/* Returns the default resource */
public function get_default() {
return $this->get($this->default_id);
}
/* Returns the default resource */
public function get_default()
{
return $this->get($this->default_id);
}
/* Override in subclasses to create subclass object if needed */
public function resource_instance($id, $name = NULL) {
return new CrayonResource($id, $name);
}
/* Override in subclasses to create subclass object if needed */
public function resource_instance($id, $name = NULL)
{
return new CrayonResource($id, $name);
}
public function add($id, $resource) {
if (is_string($id) && !empty($id)) {
$this->collection[$id] = $resource;
asort($this->collection);
public function add($id, $resource)
{
if (is_string($id) && !empty($id)) {
$this->collection[$id] = $resource;
asort($this->collection);
CrayonLog::debug('Added resource: ' . $this->path($id));
} else {
} else {
CrayonLog::syslog('Could not add resource: ', $id);
}
}
}
public function add_resource($resource) {
$this->add($resource->id(), $resource);
}
public function add_resource($resource)
{
$this->add($resource->id(), $resource);
}
public function remove($name) {
if (is_string($name) && !empty($name) && array_key_exists($name, $this->collection)) {
unset($this->collection[$name]);
}
}
public function remove($name)
{
if (is_string($name) && !empty($name) && array_key_exists($name, $this->collection)) {
unset($this->collection[$name]);
}
}
public function remove_all() {
$this->collection = array();
}
public function remove_all()
{
$this->collection = array();
}
/* Returns the resource for the given id or NULL if it can't be found */
public function get($id = NULL) {
$this->load();
if ($id === NULL) {
return $this->collection;
} else if (is_string($id) && $this->is_loaded($id)) {
return $this->collection[$id];
}
return NULL;
}
/* Returns the resource for the given id or NULL if it can't be found */
public function get($id = NULL)
{
$this->load();
if ($id === NULL) {
return $this->collection;
} else if (is_string($id) && $this->is_loaded($id)) {
return $this->collection[$id];
}
return NULL;
}
public function get_array() {
$array = array();
foreach ($this->get() as $resource) {
$array[$resource->id()] = $resource->name();
}
return $array;
}
public function get_array()
{
$array = array();
foreach ($this->get() as $resource) {
$array[$resource->id()] = $resource->name();
}
return $array;
}
public function is_loaded($id) {
if (is_string($id)) {
return array_key_exists($id, $this->collection);
}
return FALSE;
}
public function is_loaded($id)
{
if (is_string($id)) {
return array_key_exists($id, $this->collection);
}
return FALSE;
}
public function get_state() {
return $this->state;
}
public function get_state()
{
return $this->state;
}
public function is_state_loaded() {
return $this->state == self::LOADED;
}
public function is_state_loaded()
{
return $this->state == self::LOADED;
}
public function is_state_loading() {
return $this->state == self::LOADING;
}
public function is_state_loading()
{
return $this->state == self::LOADING;
}
public function is_state_unloaded() {
return $this->state == self::UNLOADED;
}
public function is_state_unloaded()
{
return $this->state == self::UNLOADED;
}
public function directory($dir = NULL) {
public function directory($dir = NULL)
{
if ($dir === NULL) {
return $this->dir;
} else {
$this->dir = CrayonUtil::path_slash($dir);
}
}
}
public function url($id) {
return '';
}
public function url($id)
{
return '';
}
public function get_css($id, $ver = NULL) {
$resource = $this->get($id);
return '<link rel="stylesheet" type="text/css" href="' . $this->url($resource->id()) . ($ver ? "?ver=$ver" : '') . '" />' . CRAYON_NL;
}
public function get_css($id, $ver = NULL)
{
$resource = $this->get($id);
return '<link rel="stylesheet" type="text/css" href="' . $this->url($resource->id()) . ($ver ? "?ver=$ver" : '') . '" />' . CRAYON_NL;
}
}
class CrayonUsedResourceCollection extends CrayonResourceCollection {
class CrayonUsedResourceCollection extends CrayonResourceCollection
{
// Checks if any resoruces are being used
public function is_used($id = NULL) {
if ($id === NULL) {
foreach ($this->get() as $resource) {
if ($resource->used()) {
return TRUE;
}
}
return FALSE;
} else {
$resource = $this->get($id);
if (!$resource) {
return FALSE;
} else {
return $resource->used();
}
}
}
// Checks if any resoruces are being used
public function is_used($id = NULL)
{
if ($id === NULL) {
foreach ($this->get() as $resource) {
if ($resource->used()) {
return TRUE;
}
}
return FALSE;
} else {
$resource = $this->get($id);
if (!$resource) {
return FALSE;
} else {
return $resource->used();
}
}
}
public function set_used($id, $value = TRUE) {
$resource = $this->get($id);
if ($resource !== NULL && !$resource->used()) {
$resource->used($value == TRUE);
return TRUE;
}
return FALSE;
}
public function set_used($id, $value = TRUE)
{
$resource = $this->get($id);
if ($resource !== NULL && !$resource->used()) {
$resource->used($value == TRUE);
return TRUE;
}
return FALSE;
}
public function get_used() {
$used = array();
foreach ($this->get() as $resource) {
if ($resource->used()) {
$used[] = $resource;
}
}
return $used;
}
public function get_used()
{
$used = array();
foreach ($this->get() as $resource) {
if ($resource->used()) {
$used[] = $resource;
}
}
return $used;
}
// XXX Override
public function resource_instance($id, $name = NULL) {
return new CrayonUsedResource($id, $name);
}
// XXX Override
public function resource_instance($id, $name = NULL)
{
return new CrayonUsedResource($id, $name);
}
public function get_used_css() {
$used = $this->get_used();
$css = array();
foreach ($used as $resource) {
$url = $this->url($resource->id());
$css[$resource->id()] = $url;
}
return $css;
}
public function get_used_css()
{
$used = $this->get_used();
$css = array();
foreach ($used as $resource) {
$url = $this->url($resource->id());
$css[$resource->id()] = $url;
}
return $css;
}
}
class CrayonUserResourceCollection extends CrayonUsedResourceCollection {
class CrayonUserResourceCollection extends CrayonUsedResourceCollection
{
private $user_dir = '';
private $curr_dir = NULL;
// TODO better to use a base dir and relative
@ -299,17 +336,20 @@ class CrayonUserResourceCollection extends CrayonUsedResourceCollection {
private $extension = '';
// XXX Override
public function resource_instance($id, $name = NULL) {
public function resource_instance($id, $name = NULL)
{
$resource = $this->create_user_resource_instance($id, $name);
$resource->user($this->curr_dir == $this->user_directory());
return $resource;
}
public function create_user_resource_instance($id, $name = NULL) {
public function create_user_resource_instance($id, $name = NULL)
{
return new CrayonUserResource($id, $name);
}
public function user_directory($dir = NULL) {
public function user_directory($dir = NULL)
{
if ($dir === NULL) {
return $this->user_dir;
} else {
@ -317,21 +357,24 @@ class CrayonUserResourceCollection extends CrayonUsedResourceCollection {
}
}
public function relative_directory($relative_directory = NULL) {
public function relative_directory($relative_directory = NULL)
{
if ($relative_directory == NULL) {
return $this->relative_directory;
}
$this->relative_directory = $relative_directory;
}
public function extension($extension = NULL) {
public function extension($extension = NULL)
{
if ($extension == NULL) {
return $this->extension;
}
$this->extension = $extension;
}
public function load_resources($dir = NULL) {
public function load_resources($dir = NULL)
{
$this->curr_dir = $this->directory();
parent::load_resources($this->curr_dir);
$this->curr_dir = $this->user_directory();
@ -339,11 +382,13 @@ class CrayonUserResourceCollection extends CrayonUsedResourceCollection {
$this->curr_dir = NULL;
}
public function current_directory() {
public function current_directory()
{
return $this->curr_dir;
}
public function dir_is_user($id, $user = NULL) {
public function dir_is_user($id, $user = NULL)
{
if ($user === NULL) {
if ($this->is_state_loading()) {
// We seem to be loading resources - use current directory
@ -360,95 +405,112 @@ class CrayonUserResourceCollection extends CrayonUsedResourceCollection {
return $user;
}
public function dirpath($user = NULL) {
public function dirpath($user = NULL)
{
$path = $user ? $this->user_directory() : $this->directory();
return CrayonUtil::path_slash($path);
}
public function dirpath_for_id($id, $user = NULL) {
public function dirpath_for_id($id, $user = NULL)
{
$user = $this->dir_is_user($id, $user);
return $this->dirpath($user) . $id;
}
public function dirurl($user = NULL) {
public function dirurl($user = NULL)
{
$path = $user ? CrayonGlobalSettings::upload_url() : CrayonGlobalSettings::plugin_path();
return CrayonUtil::path_slash($path . $this->relative_directory());
}
// XXX Override
public function path($id, $user = NULL) {
public function path($id, $user = NULL)
{
$user = $this->dir_is_user($id, $user);
return $this->dirpath($user) . $this->filename($id, $user);
}
// XXX Override
public function url($id, $user = NULL) {
public function url($id, $user = NULL)
{
$user = $this->dir_is_user($id, $user);
return $this->dirurl($user) . $this->filename($id, $user);
}
public function filename($id, $user = NULL) {
public function filename($id, $user = NULL)
{
return "$id.$this->extension";
}
}
class CrayonResource {
private $id = '';
private $name = '';
class CrayonResource
{
private $id = '';
private $name = '';
function __construct($id, $name = NULL) {
$id = $this->clean_id($id);
CrayonUtil::str($this->id, $id);
( empty($name) ) ? $this->name( self::clean_name($this->id) ) : $this->name($name);
}
function __construct($id, $name = NULL)
{
$id = $this->clean_id($id);
CrayonUtil::str($this->id, $id);
(empty($name)) ? $this->name(self::clean_name($this->id)) : $this->name($name);
}
function __tostring() {
return $this->name;
}
function __tostring()
{
return $this->name;
}
function id() {
return $this->id;
}
function id()
{
return $this->id;
}
function name($name = NULL) {
if ($name === NULL) {
return $this->name;
} else {
$this->name = $name;
}
}
function name($name = NULL)
{
if ($name === NULL) {
return $this->name;
} else {
$this->name = $name;
}
}
function clean_id($id) {
$id = CrayonUtil::space_to_hyphen( strtolower(trim($id)) );
function clean_id($id)
{
$id = CrayonUtil::space_to_hyphen(strtolower(trim($id)));
return preg_replace('#[^\w-]#msi', '', $id);
}
}
public static function clean_name($id) {
$id = CrayonUtil::hyphen_to_space( strtolower(trim($id)) );
return CrayonUtil::ucwords($id);
}
public static function clean_name($id)
{
$id = CrayonUtil::hyphen_to_space(strtolower(trim($id)));
return CrayonUtil::ucwords($id);
}
}
class CrayonUsedResource extends CrayonResource {
class CrayonUsedResource extends CrayonResource
{
// Keeps track of usage
private $used = FALSE;
private $used = FALSE;
function used($used = NULL) {
if ($used === NULL) {
return $this->used;
} else {
$this->used = ($used ? TRUE : FALSE);
}
}
function used($used = NULL)
{
if ($used === NULL) {
return $this->used;
} else {
$this->used = ($used ? TRUE : FALSE);
}
}
}
class CrayonUserResource extends CrayonUsedResource {
class CrayonUserResource extends CrayonUsedResource
{
// Keeps track of user modifications
private $user = FALSE;
function user($user = NULL) {
function user($user = NULL)
{
if ($user === NULL) {
return $this->user;
} else {
@ -457,22 +519,23 @@ class CrayonUserResource extends CrayonUsedResource {
}
}
class CrayonVersionResource extends CrayonUserResource {
class CrayonVersionResource extends CrayonUserResource
{
// Adds version
private $version = '';
private $version = '';
function __construct($id, $name = NULL, $version = NULL) {
parent::__construct($id, $name);
$this->version($version);
}
function __construct($id, $name = NULL, $version = NULL)
{
parent::__construct($id, $name);
$this->version($version);
}
function version($version = NULL) {
if ($version === NULL) {
return $this->version;
} else if (is_string($version)) {
$this->version = $version;
}
}
function version($version = NULL)
{
if ($version === NULL) {
return $this->version;
} else if (is_string($version)) {
$this->version = $version;
}
}
}
?>

View File

@ -7,7 +7,8 @@ require_once(CRAYON_THEMES_PHP);
* Stores CrayonSetting objects.
* Each Crayon instance stores an instance of this class containing its specific settings.
*/
class CrayonSettings {
class CrayonSettings
{
// Properties and Constants ===============================================
const INVALID = -1; // Used for invalid dropdown index
// Plugin data
@ -121,7 +122,8 @@ class CrayonSettings {
private static $cache_array;
public static function get_cache_sec($cache) {
public static function get_cache_sec($cache)
{
$values = array_values(self::$cache_array);
if (array_key_exists($cache, $values)) {
return $values[$cache];
@ -136,11 +138,13 @@ class CrayonSettings {
// The settings with default values
private static $default = NULL;
function __construct() {
function __construct()
{
$this->init();
}
function copy() {
function copy()
{
$settings = new CrayonSettings();
foreach ($this->settings as $setting) {
$settings->set($setting); // Overuse of set?
@ -150,7 +154,8 @@ class CrayonSettings {
// Methods ================================================================
private function init() {
private function init()
{
global $CRAYON_VERSION;
crayon_load_plugin_textdomain();
@ -271,7 +276,8 @@ class CrayonSettings {
// Getter and Setter ======================================================
// TODO this needs simplification
function set($name, $value = NULL, $replace = FALSE) {
function set($name, $value = NULL, $replace = FALSE)
{
// Set associative array of settings
if (is_array($name)) {
$keys = array_keys($name);
@ -309,7 +315,8 @@ class CrayonSettings {
}
}
function get($name = NULL) {
function get($name = NULL)
{
if ($name === NULL) {
$copy = array();
foreach ($this->settings as $name => $setting) {
@ -324,7 +331,8 @@ class CrayonSettings {
return FALSE;
}
function val($name = NULL) {
function val($name = NULL)
{
if (($setting = self::get($name)) != FALSE) {
return $setting->value();
} else {
@ -332,7 +340,8 @@ class CrayonSettings {
}
}
function val_str($name) {
function val_str($name)
{
if (($setting = self::get($name)) != FALSE) {
$def = $setting->def();
$index = $setting->value();
@ -344,7 +353,8 @@ class CrayonSettings {
}
}
function get_array() {
function get_array()
{
$array = array();
foreach ($this->settings as $setting) {
$array[$setting->name()] = $setting->value();
@ -352,13 +362,15 @@ class CrayonSettings {
return $array;
}
function is_setting($name) {
function is_setting($name)
{
return (is_string($name) && array_key_exists($name, $this->settings));
}
/* Gets default settings, either as associative array of name=>value or CrayonSetting
objects */
public static function get_defaults($name = NULL, $objects = TRUE) {
public static function get_defaults($name = NULL, $objects = TRUE)
{
if (self::$default === NULL) {
self::$default = new CrayonSettings();
}
@ -386,7 +398,8 @@ class CrayonSettings {
}
}
public static function get_defaults_array() {
public static function get_defaults_array()
{
return self::get_defaults(NULL, FALSE);
}
@ -399,7 +412,8 @@ class CrayonSettings {
* @param string $name
* @param mixed $value
*/
public static function validate($name, $value) {
public static function validate($name, $value)
{
if (!is_string($name)) {
return '';
}
@ -470,7 +484,8 @@ class CrayonSettings {
// Takes an associative array of "smart settings" and regular settings. Smart settings can be used
// to configure regular settings quickly.
// E.g. 'max_height="20px"' will set 'height="20"', 'height_mode="0", height_unit="0"'
public static function smart_settings($settings) {
public static function smart_settings($settings)
{
if (!is_array($settings)) {
return FALSE;
}
@ -524,7 +539,8 @@ class CrayonSettings {
}
// Used for height and width smart settings, I couldn't bear to copy paste code twice...
private static function smart_hw($name, $set, $mode, $unit, &$settings) {
private static function smart_hw($name, $set, $mode, $unit, &$settings)
{
if (!is_string($name) || !is_string($set) || !is_string($mode) || !is_string($unit) || !is_array($settings)) {
return;
}
@ -557,7 +573,8 @@ class CrayonSettings {
* These settings can be overriden by individual Crayons.
* Also manages global site settings and paths.
*/
class CrayonGlobalSettings {
class CrayonGlobalSettings
{
// The global settings stored as a CrayonSettings object.
private static $global = NULL;
/* These are used to load local files reliably and prevent scripts like PHP from executing
@ -572,50 +589,60 @@ class CrayonGlobalSettings {
private static $upload_url = '';
private static $mkdir = NULL;
private function __construct() {
private function __construct()
{
}
private static function init() {
private static function init()
{
if (self::$global === NULL) {
self::$global = new CrayonSettings();
}
}
public static function get($name = NULL) {
public static function get($name = NULL)
{
self::init();
return self::$global->get($name);
}
public static function get_array() {
public static function get_array()
{
self::init();
return self::$global->get_array();
}
public static function get_obj() {
public static function get_obj()
{
self::init();
return self::$global->copy();
}
public static function val($name = NULL) {
public static function val($name = NULL)
{
self::init();
return self::$global->val($name);
}
public static function val_str($name = NULL) {
public static function val_str($name = NULL)
{
self::init();
return self::$global->val_str($name);
}
public static function has_changed($input, $setting, $value) {
public static function has_changed($input, $setting, $value)
{
return $input == $setting && $value != CrayonGlobalSettings::val($setting);
}
public static function set($name, $value = NULL, $replace = FALSE) {
public static function set($name, $value = NULL, $replace = FALSE)
{
self::init();
self::$global->set($name, $value, $replace);
}
public static function site_url($site_http = NULL) {
public static function site_url($site_http = NULL)
{
if ($site_http === NULL) {
return self::$site_http;
} else {
@ -623,7 +650,8 @@ class CrayonGlobalSettings {
}
}
public static function site_path($site_path = NULL) {
public static function site_path($site_path = NULL)
{
if ($site_path === NULL) {
return self::$site_path;
} else {
@ -631,7 +659,8 @@ class CrayonGlobalSettings {
}
}
public static function plugin_path($plugin_path = NULL) {
public static function plugin_path($plugin_path = NULL)
{
if ($plugin_path === NULL) {
return self::$plugin_path;
} else {
@ -639,7 +668,8 @@ class CrayonGlobalSettings {
}
}
public static function upload_path($upload_path = NULL) {
public static function upload_path($upload_path = NULL)
{
if ($upload_path === NULL) {
return self::$upload_path;
} else {
@ -647,7 +677,8 @@ class CrayonGlobalSettings {
}
}
public static function upload_url($upload_url = NULL) {
public static function upload_url($upload_url = NULL)
{
if ($upload_url === NULL) {
return self::$upload_url;
} else {
@ -655,7 +686,8 @@ class CrayonGlobalSettings {
}
}
public static function set_mkdir($mkdir = NULL) {
public static function set_mkdir($mkdir = NULL)
{
if ($mkdir === NULL) {
return self::$mkdir;
} else {
@ -663,7 +695,8 @@ class CrayonGlobalSettings {
}
}
public static function mkdir($dir = NULL) {
public static function mkdir($dir = NULL)
{
if (self::$mkdir) {
call_user_func(self::$mkdir, $dir);
} else {
@ -678,14 +711,17 @@ $INT = new CrayonValidator('#\d+#');
/**
* Validation class.
*/
class CrayonValidator {
class CrayonValidator
{
private $pattern = '#*#msi';
public function __construct($pattern) {
public function __construct($pattern)
{
$this->pattern($pattern);
}
public function pattern($pattern) {
public function pattern($pattern)
{
if ($pattern === NULL) {
return $pattern;
} else {
@ -693,11 +729,13 @@ class CrayonValidator {
}
}
public function validate($str) {
public function validate($str)
{
return preg_match($this->pattern, $str) !== FALSE;
}
public function sanitize($str) {
public function sanitize($str)
{
preg_match_all($this->pattern, $str, $matches);
$result = '';
foreach ($matches as $match) {
@ -707,14 +745,18 @@ class CrayonValidator {
}
}
class CrayonNonNegIntValidator extends CrayonValidator {
public function __construct() {
class CrayonNonNegIntValidator extends CrayonValidator
{
public function __construct()
{
parent::__construct('#\d+#');
}
}
class CrayonIntValidator extends CrayonValidator {
public function __construct() {
class CrayonIntValidator extends CrayonValidator
{
public function __construct()
{
parent::__construct('#-?\d+#');
}
}
@ -723,7 +765,8 @@ class CrayonIntValidator extends CrayonValidator {
* Individual setting.
* Can store boolean, string, dropdown (with array of strings), etc.
*/
class CrayonSetting {
class CrayonSetting
{
private $name = '';
/* The type of variables that can be set as the value.
* For dropdown settings, value is int, even though value() will return a string. */
@ -738,7 +781,8 @@ class CrayonSetting {
private $validator = NULL;
public function __construct($name, $default = '', $value = NULL, $locked = NULL) {
public function __construct($name, $default = '', $value = NULL, $locked = NULL)
{
$this->name($name);
if ($default !== NULL) {
$this->def($default); // Perform first to set type
@ -751,29 +795,35 @@ class CrayonSetting {
}
}
function __tostring() {
function __tostring()
{
return $this->name;
}
function copy() {
function copy()
{
return new CrayonSetting($this->name, $this->default, $this->value, $this->locked);
}
function name($name = NULL) {
function name($name = NULL)
{
if (!CrayonUtil::str($this->name, $name)) {
return $this->name;
}
}
function type() {
function type()
{
return $this->type;
}
function is_array() {
function is_array()
{
return $this->is_array;
}
function locked($locked = NULL) {
function locked($locked = NULL)
{
if ($locked === NULL) {
return $this->locked;
} else {
@ -788,7 +838,8 @@ class CrayonSetting {
* value() returns string value at current index for dropdown settings.
* @param $value
*/
function value($value = NULL) {
function value($value = NULL)
{
if ($value === NULL) {
/*if ($this->is_array) {
return $this->default[$this->value]; // value at index
@ -812,7 +863,8 @@ class CrayonSetting {
}
}
function array_value() {
function array_value()
{
if ($this->is_array) {
return NULL;
}
@ -824,7 +876,8 @@ class CrayonSetting {
* For dropdown settings, default value is array of all possible value strings.
* @param $default
*/
function def($default = NULL) {
function def($default = NULL)
{
// Only allow default to be set once
if ($this->type === NULL && $default !== NULL) {
@ -864,7 +917,8 @@ class CrayonSetting {
* @param int|string $index
* @return FALSE if not dropdown setting
*/
function index($index = NULL) {
function index($index = NULL)
{
if (!$this->is_array) {
return FALSE;
} else if ($index === NULL) {
@ -885,7 +939,8 @@ class CrayonSetting {
/**
* Finds the index of a string in an array setting
*/
function find_index($str) {
function find_index($str)
{
if (!$this->is_array || is_string($str)) {
return FALSE;
}
@ -897,7 +952,8 @@ class CrayonSetting {
return FALSE;
}
function validator($validator) {
function validator($validator)
{
if ($validator === NULL) {
return $this->validator;
} else {
@ -905,7 +961,8 @@ class CrayonSetting {
}
}
function sanitize($str) {
function sanitize($str)
{
if ($this->validator != NULL) {
return $this->validator->sanitize($str);
} else {
@ -914,5 +971,3 @@ class CrayonSetting {
}
}
?>

View File

@ -9,7 +9,8 @@ require_once(CRAYON_SETTINGS_PHP);
CrayonHighlighter and any non-WP classes will only use CrayonSettings to separate
the implementation of global settings and ensure any system can use them. */
class CrayonSettingsWP {
class CrayonSettingsWP
{
// Properties and Constants ===============================================
// A copy of the current options in db
@ -45,12 +46,14 @@ class CrayonSettingsWP {
const SAMPLE_CODE = 'sample-code';
const CACHE_CLEAR = 'crayon-cache-clear';
private function __construct() {
private function __construct()
{
}
// Methods ================================================================
public static function admin_load() {
public static function admin_load()
{
self::$admin_page = $admin_page = add_options_page('Crayon Syntax Highlighter ' . crayon__('Settings'), 'Crayon', 'manage_options', 'crayon_settings', 'CrayonSettingsWP::settings');
add_action("admin_print_scripts-$admin_page", 'CrayonSettingsWP::admin_scripts');
add_action("admin_print_styles-$admin_page", 'CrayonSettingsWP::admin_styles');
@ -73,7 +76,8 @@ class CrayonSettingsWP {
}
}
public static function admin_styles() {
public static function admin_styles()
{
global $CRAYON_VERSION;
if (CRAYON_MINIFY) {
wp_enqueue_style('crayon', plugins_url(CRAYON_STYLE_MIN, __FILE__), array('editor-buttons'), $CRAYON_VERSION);
@ -84,7 +88,8 @@ class CrayonSettingsWP {
}
}
public static function admin_scripts() {
public static function admin_scripts()
{
global $CRAYON_VERSION;
if (CRAYON_MINIFY) {
@ -102,7 +107,8 @@ class CrayonSettingsWP {
}
}
public static function other_scripts() {
public static function other_scripts()
{
global $CRAYON_VERSION;
self::load_settings(TRUE);
$deps = array('jquery', 'crayon_util_js');
@ -114,7 +120,8 @@ class CrayonSettingsWP {
wp_enqueue_script('crayon_js', plugins_url(CRAYON_JS, __FILE__), $deps, $CRAYON_VERSION);
}
public static function init_js_settings() {
public static function init_js_settings()
{
// This stores JS variables used in AJAX calls and in the JS files
global $CRAYON_VERSION;
self::load_settings(TRUE);
@ -147,7 +154,8 @@ class CrayonSettingsWP {
}
}
public static function init_admin_js_settings() {
public static function init_admin_js_settings()
{
if (!self::$admin_js_settings) {
// We need to load themes at this stage
CrayonSettingsWP::load_settings();
@ -189,7 +197,8 @@ class CrayonSettingsWP {
}
}
public static function settings() {
public static function settings()
{
if (!current_user_can('manage_options')) {
wp_die(crayon__('You do not have sufficient permissions to access this page.'));
}
@ -238,11 +247,12 @@ class CrayonSettingsWP {
<div id="crayon-theme-editor-wrap" class="wrap"></div>
<?php
<?php
}
// Load the global settings and update them from the db
public static function load_settings($just_load_settings = FALSE) {
public static function load_settings($just_load_settings = FALSE)
{
if (self::$options === NULL) {
// Load settings from db
if (!(self::$options = get_option(self::OPTIONS))) {
@ -291,12 +301,14 @@ class CrayonSettingsWP {
}
}
public static function get_settings() {
public static function get_settings()
{
return get_option(self::OPTIONS);
}
// Saves settings from CrayonGlobalSettings, or provided array, to the db
public static function save_settings($settings = NULL) {
public static function save_settings($settings = NULL)
{
if ($settings === NULL) {
$settings = CrayonGlobalSettings::get_array();
}
@ -308,7 +320,8 @@ class CrayonSettingsWP {
/**
* This loads the posts marked as containing Crayons
*/
public static function load_posts() {
public static function load_posts()
{
if (self::$crayon_posts === NULL) {
// Load from db
if (!(self::$crayon_posts = get_option(self::POSTS))) {
@ -330,7 +343,8 @@ class CrayonSettingsWP {
/**
* Saves the marked posts to the db
*/
public static function save_posts($posts = NULL) {
public static function save_posts($posts = NULL)
{
if ($posts === NULL) {
$posts = self::$crayon_posts;
}
@ -341,7 +355,8 @@ class CrayonSettingsWP {
/**
* Adds a post as containing a Crayon
*/
public static function add_post($id, $save = TRUE) {
public static function add_post($id, $save = TRUE)
{
self::load_posts();
if (!in_array($id, self::$crayon_posts)) {
self::$crayon_posts[] = $id;
@ -354,7 +369,8 @@ class CrayonSettingsWP {
/**
* Removes a post as not containing a Crayon
*/
public static function remove_post($id, $save = TRUE) {
public static function remove_post($id, $save = TRUE)
{
self::load_posts();
$key = array_search($id, self::$crayon_posts);
if ($key === false) {
@ -366,7 +382,8 @@ class CrayonSettingsWP {
}
}
public static function remove_posts() {
public static function remove_posts()
{
self::$crayon_posts = array();
self::save_posts();
}
@ -376,7 +393,8 @@ class CrayonSettingsWP {
/**
* This loads the posts marked as containing Crayons
*/
public static function load_legacy_posts($force = FALSE) {
public static function load_legacy_posts($force = FALSE)
{
if (self::$crayon_legacy_posts === NULL || $force) {
// Load from db
if (!(self::$crayon_legacy_posts = get_option(self::LEGACY_POSTS))) {
@ -398,7 +416,8 @@ class CrayonSettingsWP {
/**
* Saves the marked posts to the db
*/
public static function save_legacy_posts($posts = NULL) {
public static function save_legacy_posts($posts = NULL)
{
if ($posts === NULL) {
$posts = self::$crayon_legacy_posts;
}
@ -409,7 +428,8 @@ class CrayonSettingsWP {
/**
* Adds a post as containing a Crayon
*/
public static function add_legacy_post($id, $save = TRUE) {
public static function add_legacy_post($id, $save = TRUE)
{
self::load_legacy_posts();
if (!in_array($id, self::$crayon_legacy_posts)) {
self::$crayon_legacy_posts[] = $id;
@ -422,7 +442,8 @@ class CrayonSettingsWP {
/**
* Removes a post as not containing a Crayon
*/
public static function remove_legacy_post($id, $save = TRUE) {
public static function remove_legacy_post($id, $save = TRUE)
{
self::load_legacy_posts();
$key = array_search($id, self::$crayon_legacy_posts);
if ($key === false) {
@ -434,14 +455,16 @@ class CrayonSettingsWP {
}
}
public static function remove_legacy_posts() {
public static function remove_legacy_posts()
{
self::$crayon_legacy_posts = array();
self::save_legacy_posts();
}
// Cache
public static function add_cache($name) {
public static function add_cache($name)
{
self::load_cache();
if (!in_array($name, self::$cache)) {
self::$cache[] = $name;
@ -449,7 +472,8 @@ class CrayonSettingsWP {
self::save_cache();
}
public static function remove_cache($name) {
public static function remove_cache($name)
{
self::load_cache();
$key = array_search($name, self::$cache);
if ($key === false) {
@ -459,7 +483,8 @@ class CrayonSettingsWP {
self::save_cache();
}
public static function clear_cache() {
public static function clear_cache()
{
self::load_cache();
foreach (self::$cache as $name) {
delete_transient($name);
@ -468,7 +493,8 @@ class CrayonSettingsWP {
self::save_cache();
}
public static function load_cache() {
public static function load_cache()
{
// Load cache from db
if (!(self::$cache = get_option(self::CACHE))) {
self::$cache = array();
@ -476,14 +502,16 @@ class CrayonSettingsWP {
}
}
public static function save_cache() {
public static function save_cache()
{
update_option(self::CACHE, self::$cache);
self::load_cache();
}
// Paths
public static function admin_init() {
public static function admin_init()
{
// Load default settings if they don't exist
self::load_settings();
@ -518,19 +546,22 @@ class CrayonSettingsWP {
// Wrapper functions
private static function add_section($name, $title, $callback = NULL) {
private static function add_section($name, $title, $callback = NULL)
{
$callback = (empty($callback) ? 'blank' : $callback);
add_settings_section($name, $title, 'CrayonSettingsWP::' . $callback, self::SETTINGS);
}
private static function add_field($section, $title, $callback, $args = array()) {
private static function add_field($section, $title, $callback, $args = array())
{
$unique = preg_replace('#\\s#', '_', strtolower($title));
add_settings_field($unique, $title, 'CrayonSettingsWP::' . $callback, self::SETTINGS, $section, $args);
}
// Validates all the settings passed from the form in $inputs
public static function settings_validate($inputs) {
public static function settings_validate($inputs)
{
// Load current settings from db
self::load_settings(TRUE);
@ -630,12 +661,14 @@ class CrayonSettingsWP {
// Section callback functions
public static function blank() {
public static function blank()
{
} // Used for required callbacks with blank content
// Input Drawing ==========================================================
private static function input($args) {
private static function input($args)
{
$id = '';
$size = 40;
$margin = FALSE;
@ -648,7 +681,8 @@ class CrayonSettingsWP {
self::$options[$id], '" style="margin-left: ', ($margin ? '20px' : '0px'), ';" crayon-preview="', ($preview ? 1 : 0), '" />', ($break ? CRAYON_BR : '');
}
private static function checkbox($args, $line_break = TRUE, $preview = TRUE) {
private static function checkbox($args, $line_break = TRUE, $preview = TRUE)
{
if (empty($args) || !is_array($args) || count($args) != 2) {
return;
}
@ -661,7 +695,8 @@ class CrayonSettingsWP {
}
// Draws a dropdown by loading the default value (an array) from a setting
private static function dropdown($id, $line_break = TRUE, $preview = TRUE, $echo = TRUE, $resources = NULL, $selected = NULL) {
private static function dropdown($id, $line_break = TRUE, $preview = TRUE, $echo = TRUE, $resources = NULL, $selected = NULL)
{
if (!array_key_exists($id, self::$options)) {
return;
}
@ -686,7 +721,8 @@ class CrayonSettingsWP {
}
}
private static function button($args = array()) {
private static function button($args = array())
{
extract($args);
CrayonUtil::set_var($id, '');
CrayonUtil::set_var($class, '');
@ -695,26 +731,27 @@ class CrayonSettingsWP {
return '<a id="' . $id . '" class="button-primary ' . $class . '" onclick="' . $onclick . '">' . $title . '</a>';
}
private static function info_span($name, $text) {
private static function info_span($name, $text)
{
echo '<span id="', $name, '-info">', $text, '</span>';
}
private static function span($text) {
private static function span($text)
{
echo '<span>', $text, '</span>';
}
// General Fields =========================================================
public static function help() {
public static function help()
{
global $CRAYON_WEBSITE, $CRAYON_TWITTER, $CRAYON_GIT, $CRAYON_PLUGIN_WP, $CRAYON_DONATE;
if (CrayonGlobalSettings::val(CrayonSettings::HIDE_HELP)) {
return;
}
echo '<div id="crayon-help" class="updated settings-error crayon-help">
<p><strong>Howdy, coder!</strong> Thanks for using Crayon. <strong>Useful Links:</strong> <a href="' . $CRAYON_WEBSITE . '" target="_blank">Documentation</a>, <a href="' . $CRAYON_GIT . '" target="_blank">GitHub</a>, <a href="' . $CRAYON_PLUGIN_WP . '" target="_blank">Plugin Page</a>, <a href="' . $CRAYON_TWITTER . '" target="_blank">Twitter</a>. Crayon has always been free. If you value my work please consider a <a href="' . $CRAYON_DONATE . '">small donation</a> to show your appreciation. Thanks! <a class="crayon-help-close">X</a></p></div>
';
}
public static function help_screen() {
public static function help_screen()
{
$screen = get_current_screen();
if ($screen->id != self::$admin_page) {
@ -722,7 +759,8 @@ class CrayonSettingsWP {
}
}
public static function metrics() {
public static function metrics()
{
echo '<div id="crayon-section-metrics" class="crayon-hide-inline">';
self::checkbox(array(CrayonSettings::HEIGHT_SET, '<span class="crayon-span-50">' . crayon__('Height') . ' </span>'), FALSE);
self::dropdown(CrayonSettings::HEIGHT_MODE, FALSE);
@ -760,7 +798,8 @@ class CrayonSettingsWP {
echo '</div>';
}
public static function toolbar() {
public static function toolbar()
{
echo '<div id="crayon-section-toolbar" class="crayon-hide-inline">';
self::span(crayon__('Display the Toolbar') . ' ');
self::dropdown(CrayonSettings::TOOLBAR);
@ -775,7 +814,8 @@ class CrayonSettingsWP {
echo '</div>';
}
public static function lines() {
public static function lines()
{
echo '<div id="crayon-section-lines" class="crayon-hide-inline">';
self::checkbox(array(CrayonSettings::STRIPED, crayon__('Display striped code lines')));
self::checkbox(array(CrayonSettings::MARKING, crayon__('Enable line marking for important lines')));
@ -789,7 +829,8 @@ class CrayonSettingsWP {
echo '</div>';
}
public static function langs() {
public static function langs()
{
echo '<a name="langs"></a>';
// Specialised dropdown for languages
if (array_key_exists(CrayonSettings::FALLBACK_LANG, self::$options)) {
@ -818,7 +859,8 @@ class CrayonSettingsWP {
}
}
public static function show_langs() {
public static function show_langs()
{
CrayonSettingsWP::load_settings();
require_once(CRAYON_PARSER_PHP);
if (($langs = CrayonParser::parse_all()) != FALSE) {
@ -846,7 +888,8 @@ class CrayonSettingsWP {
exit();
}
public static function posts() {
public static function posts()
{
echo '<a name="posts"></a>';
echo self::button(array('id' => 'show-posts', 'title' => crayon__('Show Crayon Posts')));
echo ' <input type="submit" name="', self::OPTIONS, '[refresh_tags]" id="refresh_tags" class="button-primary" value="', crayon__('Refresh'), '" />';
@ -854,7 +897,8 @@ class CrayonSettingsWP {
echo '<div id="crayon-subsection-posts-info"></div>';
}
public static function post_cmp($a, $b) {
public static function post_cmp($a, $b)
{
$a = $a->post_modified;
$b = $b->post_modified;
if ($a == $b) {
@ -864,7 +908,8 @@ class CrayonSettingsWP {
}
}
public static function show_posts() {
public static function show_posts()
{
CrayonSettingsWP::load_settings();
$postIDs = self::load_posts();
$legacy_posts = self::load_legacy_posts();
@ -903,7 +948,8 @@ class CrayonSettingsWP {
exit();
}
public static function show_preview() {
public static function show_preview()
{
echo '<div id="content">';
self::load_settings(); // Run first to ensure global settings loaded
@ -970,7 +1016,8 @@ class Human {
exit();
}
public static function theme($editor = FALSE) {
public static function theme($editor = FALSE)
{
$db_theme = self::$options[CrayonSettings::THEME]; // Theme name from db
if (!array_key_exists(CrayonSettings::THEME, self::$options)) {
$db_theme = '';
@ -1022,7 +1069,8 @@ class Human {
}
}
public static function font($editor = FALSE) {
public static function font($editor = FALSE)
{
$db_font = self::$options[CrayonSettings::FONT]; // Theme name from db
if (!array_key_exists(CrayonSettings::FONT, self::$options)) {
$db_font = '';
@ -1049,7 +1097,8 @@ class Human {
self::checkbox(array(CrayonSettings::ENQUEUE_FONTS, crayon__('Enqueue fonts in the header (more efficient).') . self::help_button('http://aramk.com/blog/2012/01/07/enqueuing-themes-and-fonts-in-crayon/')));
}
public static function code($editor = FALSE) {
public static function code($editor = FALSE)
{
echo '<div id="crayon-section-code-interaction" class="crayon-hide-inline-only">';
self::checkbox(array(CrayonSettings::PLAIN, crayon__('Enable plain code view and display') . ' '), FALSE);
self::dropdown(CrayonSettings::SHOW_PLAIN);
@ -1085,7 +1134,8 @@ class Human {
self::input(array('id' => CrayonSettings::WHITESPACE_AFTER, 'size' => 2, 'break' => TRUE));
}
public static function tags() {
public static function tags()
{
self::checkbox(array(CrayonSettings::INLINE_TAG, crayon__('Capture Inline Tags') . self::help_button('http://aramk.com/blog/2012/03/07/inline-crayons/')));
self::checkbox(array(CrayonSettings::INLINE_WRAP, crayon__('Wrap Inline Tags') . self::help_button('http://aramk.com/blog/2012/03/07/inline-crayons/')));
self::checkbox(array(CrayonSettings::CODE_TAG_CAPTURE, crayon__('Capture &lt;code&gt; as')), FALSE);
@ -1101,7 +1151,8 @@ class Human {
self::checkbox(array(CrayonSettings::PLAIN_TAG, crayon__('Enable [plain][/plain] tag.') . self::help_button('http://aramk.com/blog/2011/12/27/mini-tags-in-crayon/')));
}
public static function files() {
public static function files()
{
echo '<a name="files"></a>';
echo crayon__('When loading local files and a relative path is given for the URL, use the absolute path'), ': ',
'<div style="margin-left: 20px">', home_url(), '/';
@ -1109,7 +1160,8 @@ class Human {
echo '</div>', crayon__('Followed by your relative URL.');
}
public static function tag_editor() {
public static function tag_editor()
{
$can_convert = self::load_legacy_posts();
if ($can_convert) {
$disabled = '';
@ -1135,7 +1187,8 @@ class Human {
self::input(array('id' => CrayonSettings::TAG_EDITOR_QUICKTAG_BUTTON_TEXT, 'break' => TRUE));
}
public static function misc() {
public static function misc()
{
echo crayon__('Clear the cache used to store remote code requests'), ': ';
self::dropdown(CrayonSettings::CACHE, false);
echo '<input type="submit" id="', self::CACHE_CLEAR, '" name="', self::CACHE_CLEAR, '" class="button-secondary" value="', crayon__('Clear Now'), '" /><br/>';
@ -1155,14 +1208,16 @@ class Human {
// Debug Fields ===========================================================
public static function errors() {
public static function errors()
{
self::checkbox(array(CrayonSettings::ERROR_LOG, crayon__('Log errors for individual Crayons')));
self::checkbox(array(CrayonSettings::ERROR_LOG_SYS, crayon__('Log system-wide errors')));
self::checkbox(array(CrayonSettings::ERROR_MSG_SHOW, crayon__('Display custom message for errors')));
self::input(array('id' => CrayonSettings::ERROR_MSG, 'size' => 60, 'margin' => TRUE));
}
public static function log() {
public static function log()
{
$log = CrayonLog::log();
touch(CRAYON_LOG_FILE);
$exists = file_exists(CRAYON_LOG_FILE);
@ -1188,7 +1243,8 @@ class Human {
// About Fields ===========================================================
public static function info() {
public static function info()
{
global $CRAYON_VERSION, $CRAYON_DATE, $CRAYON_AUTHOR, $CRAYON_WEBSITE, $CRAYON_TWITTER, $CRAYON_GIT, $CRAYON_PLUGIN_WP, $CRAYON_AUTHOR_SITE, $CRAYON_EMAIL, $CRAYON_DONATE;
echo '<a name="info"></a>';
$version = '<strong>' . crayon__('Version') . ':</strong> ' . $CRAYON_VERSION;
@ -1224,10 +1280,7 @@ class Human {
<a id="git-icon" class="small-icon" title="GitHub" href="' . $CRAYON_GIT . '" target="_blank"></a>
<a id="wp-icon" class="small-icon" title="Plugin Page" href="' . $CRAYON_PLUGIN_WP . '" target="_blank"></a>
<a id="twitter-icon" class="small-icon" title="Twitter" href="' . $CRAYON_TWITTER . '" target="_blank"></a>
<a id="gmail-icon" class="small-icon" title="Email" href="mailto:' . $CRAYON_EMAIL . '" target="_blank"></a>
<div id="crayon-donate"><a href="' . $CRAYON_DONATE . '" title="Donate" target="_blank">
<img src="' . plugins_url(CRAYON_DONATE_BUTTON, __FILE__) . '"></a>
</div>';
<a id="gmail-icon" class="small-icon" title="Email" href="mailto:' . $CRAYON_EMAIL . '" target="_blank"></a>';
echo '
<table id="crayon-info" border="0">
@ -1244,14 +1297,15 @@ class Human {
<td colspan="2">' . $links . '</td>
</tr>
</table>';
}
public static function help_button($link) {
public static function help_button($link)
{
return ' <a href="' . $link . '" target="_blank" class="crayon-question">' . crayon__('?') . '</a>';
}
public static function plugin_row_meta($meta, $file) {
public static function plugin_row_meta($meta, $file)
{
global $CRAYON_DONATE;
if ($file == CrayonWP::basename()) {
$meta[] = '<a href="options-general.php?page=crayon_settings">' . crayon__('Settings') . '</a>';
@ -1269,5 +1323,3 @@ if (defined('ABSPATH') && is_admin()) {
add_action('admin_menu', 'CrayonSettingsWP::admin_load');
add_filter('plugin_row_meta', 'CrayonSettingsWP::plugin_row_meta', 10, 2);
}
?>

View File

@ -41,5 +41,3 @@ class CrayonThemes extends CrayonUserResourceCollection {
}
}
?>

View File

@ -3,7 +3,7 @@
Plugin Name: Crayon Syntax Highlighter
Plugin URI: https://github.com/aramk/crayon-syntax-highlighter
Description: Supports multiple languages, themes, highlighting from a URL, local file or post text.
Version: 2.8.4
Version: 2.8.6
Author: Aram Kocharyan
Author URI: http://aramk.com/
Text Domain: crayon-syntax-highlighter
@ -1336,5 +1336,3 @@ if (defined('ABSPATH')) {
}
add_filter('init', 'CrayonWP::init_ajax');
}
?>

View File

@ -1,35 +1,35 @@
<?php
// Switches
define('CRAYON_DEBUG', FALSE);
const CRAYON_DEBUG = FALSE;
define('CRAYON_TAG_EDITOR', TRUE);
define('CRAYON_THEME_EDITOR', TRUE);
const CRAYON_TAG_EDITOR = TRUE;
const CRAYON_THEME_EDITOR = TRUE;
define('CRAYON_MINIFY', TRUE);
const CRAYON_MINIFY = TRUE;
// Constants
// General definitions
define('CRAYON_DOMAIN', 'crayon-syntax-highlighter');
const CRAYON_DOMAIN = 'crayon-syntax-highlighter';
// These are overridden by functions since v1.1.1
$CRAYON_VERSION = '1.1.1';
$CRAYON_DATE = '27th September, 2011';
$CRAYON_VERSION = '2.8.6';
$CRAYON_DATE = '29th November, 2021';
$CRAYON_AUTHOR = 'Aram Kocharyan';
$CRAYON_AUTHOR_SITE = 'http://aramk.com';
$CRAYON_DONATE = 'http://bit.ly/crayondonate';
$CRAYON_AUTHOR_SITE = 'https://aramk.com';
$CRAYON_DONATE = 'https://bit.ly/crayondonate';
$CRAYON_WEBSITE = 'https://github.com/aramk/crayon-syntax-highlighter';
$CRAYON_EMAIL = 'crayon.syntax@gmail.com';
$CRAYON_TWITTER = 'http://twitter.com/crayonsyntax';
$CRAYON_GIT = 'http://github.com/aramk/crayon-syntax-highlighter';
$CRAYON_TWITTER = 'https://twitter.com/crayonsyntax';
$CRAYON_GIT = 'https://git.icod.de/dalu/crayon-syntax-highlighter';
$CRAYON_PLUGIN_WP = 'https://wordpress.org/plugins/crayon-syntax-highlighter/';
// XXX Used to name the class
define('CRAYON_HIGHLIGHTER', 'CrayonHighlighter');
define('CRAYON_ELEMENT_CLASS', 'CrayonElement');
define('CRAYON_SETTING_CLASS', 'CrayonSetting');
const CRAYON_HIGHLIGHTER = 'CrayonHighlighter';
const CRAYON_ELEMENT_CLASS = 'CrayonElement';
const CRAYON_SETTING_CLASS = 'CrayonSetting';
// Directories
@ -50,97 +50,98 @@ define('CRAYON_TAG_EDITOR_DIR', crayon_s('tag-editor'));
// Paths
define('CRAYON_ROOT_PATH', crayon_pf(dirname(__FILE__)));
define('CRAYON_LANG_PATH', CRAYON_ROOT_PATH . CRAYON_LANG_DIR);
define('CRAYON_THEME_PATH', CRAYON_ROOT_PATH . CRAYON_THEME_DIR);
define('CRAYON_FONT_PATH', CRAYON_ROOT_PATH . CRAYON_FONT_DIR);
define('CRAYON_UTIL_PATH', CRAYON_ROOT_PATH . CRAYON_UTIL_DIR);
define('CRAYON_TAG_EDITOR_PATH', CRAYON_ROOT_PATH . CRAYON_UTIL_DIR . CRAYON_TAG_EDITOR_DIR);
define('CRAYON_THEME_EDITOR_PATH', CRAYON_ROOT_PATH . CRAYON_UTIL_DIR . CRAYON_THEME_EDITOR_DIR);
define("CRAYON_ROOT_PATH", crayon_pf(dirname(__FILE__)));
const CRAYON_LANG_PATH = CRAYON_ROOT_PATH . CRAYON_LANG_DIR;
const CRAYON_THEME_PATH = CRAYON_ROOT_PATH . CRAYON_THEME_DIR;
const CRAYON_FONT_PATH = CRAYON_ROOT_PATH . CRAYON_FONT_DIR;
const CRAYON_UTIL_PATH = CRAYON_ROOT_PATH . CRAYON_UTIL_DIR;
const CRAYON_TAG_EDITOR_PATH = CRAYON_ROOT_PATH . CRAYON_UTIL_DIR . CRAYON_TAG_EDITOR_DIR;
const CRAYON_THEME_EDITOR_PATH = CRAYON_ROOT_PATH . CRAYON_UTIL_DIR . CRAYON_THEME_EDITOR_DIR;
// Files
define('CRAYON_LOG_FILE', CRAYON_ROOT_PATH . 'log.txt');
define('CRAYON_TOUCH_FILE', CRAYON_UTIL_PATH . 'touch.txt');
define('CRAYON_LOG_MAX_SIZE', 50000); // Bytes
const CRAYON_LOG_FILE = CRAYON_ROOT_PATH . 'log.txt';
const CRAYON_TOUCH_FILE = CRAYON_UTIL_PATH . 'touch.txt';
const CRAYON_LOG_MAX_SIZE = 50000; // Bytes
define('CRAYON_README_FILE', CRAYON_ROOT_PATH . 'readme.txt');
define('CRAYON_LANG_EXT', CRAYON_LANG_PATH . 'extensions.txt');
define('CRAYON_LANG_ALIAS', CRAYON_LANG_PATH . 'aliases.txt');
define('CRAYON_LANG_DELIM', CRAYON_LANG_PATH . 'delimiters.txt');
define('CRAYON_HELP_FILE', CRAYON_UTIL_PATH . 'help.htm');
const CRAYON_README_FILE = CRAYON_ROOT_PATH . 'readme.txt';
const CRAYON_LANG_EXT = CRAYON_LANG_PATH . 'extensions.txt';
const CRAYON_LANG_ALIAS = CRAYON_LANG_PATH . 'aliases.txt';
const CRAYON_LANG_DELIM = CRAYON_LANG_PATH . 'delimiters.txt';
const CRAYON_HELP_FILE = CRAYON_UTIL_PATH . 'help.htm';
// Minified
define('CRAYON_JS_MIN', CRAYON_JS_MIN_DIR . 'crayon.min.js');
define('CRAYON_JS_TE_MIN', CRAYON_JS_MIN_DIR . 'crayon.te.min.js');
const CRAYON_JS_MIN = CRAYON_JS_MIN_DIR . 'crayon.min.js';
const CRAYON_JS_TE_MIN = CRAYON_JS_MIN_DIR . 'crayon.te.min.js';
// Source
define('CRAYON_JQUERY_POPUP', CRAYON_JS_SRC_DIR . 'jquery.popup.js');
define('CRAYON_JS', CRAYON_JS_SRC_DIR . 'crayon.js');
define('CRAYON_JS_ADMIN', CRAYON_JS_SRC_DIR . 'crayon_admin.js');
define('CRAYON_JS_UTIL', CRAYON_JS_SRC_DIR . 'util.js');
define('CRAYON_CSSJSON_JS', CRAYON_JS_SRC_DIR . 'cssjson.js');
const CRAYON_JQUERY_POPUP = CRAYON_JS_SRC_DIR . 'jquery.popup.js';
const CRAYON_JS = CRAYON_JS_SRC_DIR . 'crayon.js';
const CRAYON_JS_ADMIN = CRAYON_JS_SRC_DIR . 'crayon_admin.js';
const CRAYON_JS_UTIL = CRAYON_JS_SRC_DIR . 'util.js';
const CRAYON_CSSJSON_JS = CRAYON_JS_SRC_DIR . 'cssjson.js';
define('CRAYON_CSS_JQUERY_COLORPICKER', CRAYON_JS_DIR . 'jquery-colorpicker/jquery.colorpicker.css');
define('CRAYON_JS_JQUERY_COLORPICKER', CRAYON_JS_DIR . 'jquery-colorpicker/jquery.colorpicker.js');
define('CRAYON_JS_TINYCOLOR', CRAYON_JS_DIR . 'tinycolor-min.js');
define('CRAYON_TAG_EDITOR_JS', 'crayon_tag_editor.js');
define('CRAYON_COLORBOX_JS', 'colorbox/jquery.colorbox-min.js');
define('CRAYON_COLORBOX_CSS', 'colorbox/colorbox.css');
define('CRAYON_TAG_EDITOR_PHP', CRAYON_TAG_EDITOR_PATH . 'crayon_tag_editor_wp.class.php');
define('CRAYON_TINYMCE_JS', 'crayon_tinymce.js');
define('CRAYON_QUICKTAGS_JS', 'crayon_qt.js');
define('CRAYON_STYLE', CRAYON_CSS_SRC_DIR . 'crayon_style.css');
define('CRAYON_STYLE_ADMIN', CRAYON_CSS_SRC_DIR . 'admin_style.css');
define('CRAYON_STYLE_GLOBAL', CRAYON_CSS_SRC_DIR . 'global_style.css');
define('CRAYON_STYLE_MIN', CRAYON_CSS_MIN_DIR . 'crayon.min.css');
define('CRAYON_LOGO', CRAYON_CSS_DIR . 'images/crayon_logo.png');
define('CRAYON_DONATE_BUTTON', CRAYON_CSS_DIR . 'images/donate.png');
define('CRAYON_THEME_EDITOR_PHP', CRAYON_THEME_EDITOR_PATH . 'theme_editor.php');
define('CRAYON_THEME_EDITOR_JS', CRAYON_UTIL_DIR . CRAYON_THEME_EDITOR_DIR . 'theme_editor.js');
define('CRAYON_THEME_EDITOR_STYLE', CRAYON_UTIL_DIR . CRAYON_THEME_EDITOR_DIR . 'theme_editor.css');
define('CRAYON_THEME_EDITOR_BUTTON', CRAYON_CSS_DIR . 'images/theme_editor.png');
const CRAYON_CSS_JQUERY_COLORPICKER = CRAYON_JS_DIR . 'jquery-colorpicker/jquery.colorpicker.css';
const CRAYON_JS_JQUERY_COLORPICKER = CRAYON_JS_DIR . 'jquery-colorpicker/jquery.colorpicker.js';
const CRAYON_JS_TINYCOLOR = CRAYON_JS_DIR . 'tinycolor-min.js';
const CRAYON_TAG_EDITOR_JS = 'crayon_tag_editor.js';
const CRAYON_COLORBOX_JS = 'colorbox/jquery.colorbox-min.js';
const CRAYON_COLORBOX_CSS = 'colorbox/colorbox.css';
const CRAYON_TAG_EDITOR_PHP = CRAYON_TAG_EDITOR_PATH . 'crayon_tag_editor_wp.class.php';
const CRAYON_TINYMCE_JS = 'crayon_tinymce.js';
const CRAYON_QUICKTAGS_JS = 'crayon_qt.js';
const CRAYON_STYLE = CRAYON_CSS_SRC_DIR . 'crayon_style.css';
const CRAYON_STYLE_ADMIN = CRAYON_CSS_SRC_DIR . 'admin_style.css';
const CRAYON_STYLE_GLOBAL = CRAYON_CSS_SRC_DIR . 'global_style.css';
const CRAYON_STYLE_MIN = CRAYON_CSS_MIN_DIR . 'crayon.min.css';
const CRAYON_LOGO = CRAYON_CSS_DIR . 'images/crayon_logo.png';
const CRAYON_DONATE_BUTTON = CRAYON_CSS_DIR . 'images/donate.png';
const CRAYON_THEME_EDITOR_PHP = CRAYON_THEME_EDITOR_PATH . 'theme_editor.php';
const CRAYON_THEME_EDITOR_JS = CRAYON_UTIL_DIR . CRAYON_THEME_EDITOR_DIR . 'theme_editor.js';
const CRAYON_THEME_EDITOR_STYLE = CRAYON_UTIL_DIR . CRAYON_THEME_EDITOR_DIR . 'theme_editor.css';
const CRAYON_THEME_EDITOR_BUTTON = CRAYON_CSS_DIR . 'images/theme_editor.png';
// PHP Files
define('CRAYON_FORMATTER_PHP', CRAYON_ROOT_PATH . 'crayon_formatter.class.php');
define('CRAYON_HIGHLIGHTER_PHP', CRAYON_ROOT_PATH . 'crayon_highlighter.class.php');
define('CRAYON_LANGS_PHP', CRAYON_ROOT_PATH . 'crayon_langs.class.php');
define('CRAYON_PARSER_PHP', CRAYON_ROOT_PATH . 'crayon_parser.class.php');
define('CRAYON_SETTINGS_PHP', CRAYON_ROOT_PATH . 'crayon_settings.class.php');
define('CRAYON_THEMES_PHP', CRAYON_ROOT_PATH . 'crayon_themes.class.php');
define('CRAYON_FONTS_PHP', CRAYON_ROOT_PATH . 'crayon_fonts.class.php');
define('CRAYON_RESOURCE_PHP', CRAYON_ROOT_PATH . 'crayon_resource.class.php');
define('CRAYON_UTIL_PHP', CRAYON_UTIL_DIR . 'crayon_util.class.php');
define('CRAYON_TIMER_PHP', CRAYON_UTIL_DIR . 'crayon_timer.class.php');
define('CRAYON_LOG_PHP', CRAYON_UTIL_DIR . 'crayon_log.class.php');
const CRAYON_FORMATTER_PHP = CRAYON_ROOT_PATH . 'crayon_formatter.class.php';
const CRAYON_HIGHLIGHTER_PHP = CRAYON_ROOT_PATH . 'crayon_highlighter.class.php';
const CRAYON_LANGS_PHP = CRAYON_ROOT_PATH . 'crayon_langs.class.php';
const CRAYON_PARSER_PHP = CRAYON_ROOT_PATH . 'crayon_parser.class.php';
const CRAYON_SETTINGS_PHP = CRAYON_ROOT_PATH . 'crayon_settings.class.php';
const CRAYON_THEMES_PHP = CRAYON_ROOT_PATH . 'crayon_themes.class.php';
const CRAYON_FONTS_PHP = CRAYON_ROOT_PATH . 'crayon_fonts.class.php';
const CRAYON_RESOURCE_PHP = CRAYON_ROOT_PATH . 'crayon_resource.class.php';
const CRAYON_UTIL_PHP = CRAYON_UTIL_DIR . 'crayon_util.class.php';
const CRAYON_TIMER_PHP = CRAYON_UTIL_DIR . 'crayon_timer.class.php';
const CRAYON_LOG_PHP = CRAYON_UTIL_DIR . 'crayon_log.class.php';
// Script time
define('CRAYON_LOAD_TIME', 'Load Time');
const CRAYON_LOAD_TIME = 'Load Time';
//define('CRAYON_PARSE_TIME', 'Parse Time');
define('CRAYON_FORMAT_TIME', 'Format Time');
const CRAYON_FORMAT_TIME = 'Format Time';
// Printing
define('CRAYON_BR', "<br />");
define('CRAYON_NL', "\r\n");
define('CRAYON_BL', CRAYON_BR . CRAYON_NL);
define('CRAYON_DASH', "==============================================================================");
define('CRAYON_LINE', "------------------------------------------------------------------------------");
const CRAYON_BR = "<br />";
const CRAYON_NL = "\r\n";
const CRAYON_BL = CRAYON_BR . CRAYON_NL;
const CRAYON_DASH = "==============================================================================";
const CRAYON_LINE = "------------------------------------------------------------------------------";
// Load utilities
require_once (CRAYON_UTIL_PHP);
require_once (CRAYON_TIMER_PHP);
require_once (CRAYON_LOG_PHP);
require_once(CRAYON_UTIL_PHP);
require_once(CRAYON_TIMER_PHP);
require_once(CRAYON_LOG_PHP);
// Turn on the error & exception handlers
//crayon_handler_on();
// GLOBAL FUNCTIONS
// Check for forwardslash/backslash in folder path to structure paths
function crayon_s($url = '') {
// Check for forward slash/backslash in folder path to structure paths
function crayon_s($url = '')
{
$url = strval($url);
if (!empty($url) && !preg_match('#(\\\\|/)$#', $url)) {
return $url . '/';
@ -152,7 +153,8 @@ function crayon_s($url = '') {
}
// Returns path using forward slashes, slash added at the end
function crayon_pf($url, $slash = TRUE) {
function crayon_pf($url, $slash = TRUE)
{
$url = trim(strval($url));
if ($slash) {
$url = crayon_s($url);
@ -161,12 +163,14 @@ function crayon_pf($url, $slash = TRUE) {
}
// Returns path using back slashes
function crayon_pb($url) {
function crayon_pb($url)
{
return str_replace('/', '\\', crayon_s(trim(strval($url))));
}
// Get/Set plugin information
function crayon_set_info($info_array) {
function crayon_set_info($info_array)
{
global $CRAYON_VERSION, $CRAYON_DATE, $CRAYON_AUTHOR, $CRAYON_WEBSITE;
if (!is_array($info_array)) {
return;
@ -177,45 +181,53 @@ function crayon_set_info($info_array) {
crayon_set_info_key('PluginURI', $info_array, $CRAYON_WEBSITE);
}
function crayon_set_info_key($key, $array, &$info) {
function crayon_set_info_key($key, $array, &$info)
{
if (array_key_exists($key, $array)) {
$info = $array[$key];
return true;
} else {
return FALSE;
}
}
function crayon_vargs(&$var, $default) {
function crayon_vargs(&$var, $default)
{
$var = isset($var) ? $var : $default;
}
// Checks if the input is a valid PHP file and matches the $valid filename
function crayon_is_php_file($filepath, $valid) {
function crayon_is_php_file($filepath, $valid)
{
$path = pathinfo(crayon_pf($filepath));
return is_file($filepath) && $path['extension'] === 'php' && $path['filename'] === $valid;
}
// Stops the script if crayon_is_php_file() returns false or a remote path is given
function crayon_die_if_not_php($filepath, $valid) {
function crayon_die_if_not_php($filepath, $valid)
{
if (!crayon_is_php_file($filepath, $valid) || crayon_is_path_url($filepath)) {
die("[ERROR] '$filepath' is not a valid PHP file for '$valid'");
}
}
function crayon_is_path_url($path) {
function crayon_is_path_url($path)
{
$parts = parse_url($path);
return isset($parts['scheme']) && strlen($parts['scheme']) > 1;
}
// LANGUAGE TRANSLATION FUNCTIONS
function crayon_load_plugin_textdomain() {
function crayon_load_plugin_textdomain()
{
if (function_exists('load_plugin_textdomain')) {
load_plugin_textdomain(CRAYON_DOMAIN, false, CRAYON_DIR . CRAYON_TRANS_DIR);
}
}
function crayon__($text) {
function crayon__($text)
{
if (function_exists('__')) {
return __($text, CRAYON_DOMAIN);
} else {
@ -223,7 +235,8 @@ function crayon__($text) {
}
}
function crayon_e($text) {
function crayon_e($text)
{
if (function_exists('_e')) {
_e($text, CRAYON_DOMAIN);
} else {
@ -231,7 +244,8 @@ function crayon_e($text) {
}
}
function crayon_n($singular, $plural, $count) {
function crayon_n($singular, $plural, $count)
{
if (function_exists('_n')) {
return _n($singular, $plural, $count, CRAYON_DOMAIN);
} else {
@ -239,12 +253,11 @@ function crayon_n($singular, $plural, $count) {
}
}
function crayon_x($text, $context) {
function crayon_x($text, $context)
{
if (function_exists('_x')) {
return _x($text, $context, CRAYON_DOMAIN);
} else {
return $text;
}
}
?>

View File

@ -0,0 +1,13 @@
# https://editorconfig.org
root = true
[*]
charset = utf-8
indent_style = space
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
[*.js,*.json,*.html,*.css]
indent_size = 2

View File

@ -0,0 +1,34 @@
{
"env": {
"browser": true,
"es6": true
},
"extends": "eslint:recommended",
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parserOptions": {
"ecmaVersion": 2018
},
"rules": {
"indent": [
"error",
2
],
"no-trailing-whitespace": true,
"no-multi-space": true,
"linebreak-style": [
"error",
"unix"
],
"quotes": [
"error",
"single"
],
"semi": [
"error",
"always"
]
}
}

View File

@ -1 +1,8 @@
/nbproject/private/
/nbproject/
.svn
.idea/*
/debug/
/node_modules/
/bower_components/
/npm-debug.log

View File

@ -0,0 +1,7 @@
{
"rules": {
"indentation": 2,
"no-descending-specificity": null
},
"extends": "stylelint-config-recommended"
}

View File

@ -0,0 +1,81 @@
# Change Log
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).
## 1.2.20 - 2019-09-01
### Fixed
- Merged security patches for third party components.
## 1.2.19 - 2019-07-11
### Fixed
- Merged security patches for third party components.
## 1.2.18 - 2019-05-13
### Added
- Merged PR #159 by @NicolasCARPi; Added `cancelOnExit` option in response to #158.
## 1.2.17 - 2018-07-15
### Fixed
- Merged PR #148 by @teambuktu; Input event for ui-colorpicker-number.
## 1.2.16 - 2018-02-19
### Fixed
- Merged PR #145 by @gentoo90; accept numpad keys on hex inputs.
## 1.2.15 - 2018-02-12
### Fixed
- Fix #144 by @Backslider23; memory part doesn't enable OK button correctly.
- Fixed black initialization issue in rgbslider part.
## 1.2.14 - 2017-12-10
### Added
- PR #143 by @zaeder; `ready` event at end of widget creation.
## 1.2.13 - 2017-05-02
### Fixed
- Fix #137 by @larsinsd; Typing in hex input does not enable OK button.
- Fix #139 by @s1738berger; Colorpicker cannot get disabled with option
'buttonImageOnly'
- Fix #130 by @actionpark; Return `css` and `hex` color in all events.
## 1.2.12 - 2017-03-29
### Fixed
- Fixed #136 by @mateuszf; Cannot disable animation.
## 1.2.11 - 2017-03-29
### Fixed
- Fixed #134 by @larsinsd and @justzuhri; `Ctrl+V` not working on Mac OS-X.
## 1.2.10 - 2017-03-29
### Added
- Added Copic color swatches.
- Added Prismacolor color swatches.
- Added DIN 6164 color swatches.
- Added ISCC-NBS color swatches.
## 1.2.9 - 2017-01-21
### Fixed
- Implemented fix #135 by @cosmicnet; replaced `.attr()` calls with `.prop()`.
## 1.2.8 - 2017-01-05
### Added
- Polish (`pl`) translation added from PR #133 by @kniziol.
### Changed
- Replaced deprecated `.bind()`, `.unbind()`, `.delegate()` and `.undelegate()`
functions by `.on()` and `.off()` for jQuery 3.0.0 compatibility.
- Documented jQueryUI 1.12.0+ requirement for jQuery 3.0.0+.
## 1.2.7 - 2016-12-24
### Added
- Ukranian (`uk`) translation added from PR #131 by @ashep.
## 1.2.6 - 2016-10-28
### Fixed
- Allow focussing and keyboard support on the "map" and "bar" parts.
## 1.2.5 - 2016-10-28
### Fixed
- The "None" and "Transparent" radiobuttons didn't always refresh in certain
color states.

View File

@ -0,0 +1,21 @@
MIT License
Copyright (c) 2011 Martijn van der Lee
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View File

@ -1,231 +0,0 @@
jQuery.colorpicker v0.9.3
Copyright (c) 2011-2012 Martijn W. van der Lee
Licensed under the MIT.
Full-featured colorpicker for jQueryUI with full theming support.
Most images from jPicker by Christopher T. Tillman.
Sourcecode created from scratch by Martijn W. van der Lee.
IE support; make sure you have a doctype defined, or the colorpicker will not
display correctly.
Options:
alpha: false
Whether or not to show the inputs for alpha.
altAlpha: true
Change the opacity of the altField element(s) according to the alpha
setting.
altField: ''
Change the background color of the elements specified in this element.
altOnChange: true
If true, the altField element(s) are updated on every change, otherwise
only upon closing.
altProperties: 'background-color'
Comma-separated list of CSS properties to set color of in the altField.
The following properties are allowed, all others are ignored.
background-color
color
border-color
outline-color
autoOpen: false
If true, the dialog opens automatically upon page load.
buttonColorize: false
If a buttonimage is specified, change the background color of the
image when the color is changed.
buttonImage: 'images/ui-colorpicker.png'
Same as jQueryUI DatePicker.
buttonImageOnly: false
Same as jQueryUI DatePicker.
buttonText: null
Same as jQueryUI DatePicker. If null, use language default.
closeOnEscape: true
Close the window when pressing the Escape key on the keyboard.
closeOnOutside: true
Close the window when clicking outside the colorpicker display.
color: '#00FF00'
Initial color. Formats recognized are:
#rrggbb
rrggbb (same as previous, but without the #)
rgb(rrr,ggg,bbb)
rgba(rrr,ggg,bbb,a.a)
rgb(rrr%,ggg%,bbb%)
rgba(rrr%,ggg%,bbb%,aaa%)
w3c-defined color name
colorFormat: 'HEX'
Specifies the format of the color string returned in callbacks.
You can either specify one of the predefined formats:
#HEX #112233
#HEX3 #123 if possible, otherwise false.
HEX 112233
HEX3 123 if possible, otherwise false.
RGB rgb(123,45,67) if opaque, otherwise false.
RGBA rgba(123,45,67,0.123%)
RGB% rgb(12%,34%,56%) if opaque, otherwise false.
RGBA% rgba(12%,34%,56%,0.123%)
HSL hsl(123,45,67) if opaque, otherwise false.
HSLA hsla(123,45,67,0.123%)
HSL% hsl(12%,34%,56%) if opaque, otherwise false.
HSLA% hsla(12%,34%,56%,0.123%)
NAME Closest color name
EXACT Exact name if possible, otherwise false.
or specify your own format...
Each color channel is specified as a pair of two characters.
The first character determines the color channel:
a Alpha
r, g, b RGB color space; red, green and blue
h, s, v HSV color space; hue, saturation and value
c, m, y, k CMYK color space; cyan, magenta, yellow and black
L, A, B LAB color space; Luminosity, *A and *B.
The second character specifies the data type:
x Two-digit hexadecimal notation.
d Decimal (0-255) notation.
f Floating point (0-1) notation, not rounded.
p Percentage (0-100) notation, not rounded.
If you prefix a valid pair with a backslash, it won't be replaced.
All patterns are case sensitive.
For example, to create the common hex color format, use "#rxgxbx".
For an rgba() format, use "rgba(rd,gd,bd,af)"
You can also specify an array of formats where the first non-FALSE one
is returned. Note that the only formats able to return FALSE are the
predefined formats HEX3 and EXACT. For example, this array will output
HEX3 format if possible or HEX format otherwise:
['HEX3', 'HEX']
dragggable: true
Make the dialog draggable if the header is visible and the dialog is
not inline.
duration: 'fast'
Same as jQueryUI DatePicker.
hsv: true
Whether or not to show the inputs for HSV.
layout: { ... }
Set the position of elements in a table layout.
You could create any layout possible with HTML tables by specifying
cell position and size of each part.
@todo document how this works.
limit: ''
Limit the selectable colors to any of the predefined limits:
'' No limitations, allow 8bpp color for a palette of
all 16 million colors.
'websafe' Set of 216 colors composed of 00, 33, 66, 99, cc
and ff color channel values in #rrggbb.
'nibble' 4 bits per color, can be easily converted to #rgb
format.
The palette is limited to 4096 colors.
'binary' Allow only #00 or #ff as color channel values for
primary colors only; only 8 colors are available
with this limit.
'name' Limit to closest color name.
modal:
Ensures no other controls on screen can be used while the dialog is
opened.
Also look at showCancelButton and closeOnEscape to use in combination
with the modal option. closeOnOutside is redundant when used with modal.
mode: 'h'
Determines the functionality of the map and bar components. Allowed
values are; 'h', 's', 'l', 'r', 'g', 'b' or 'a', for hue, saturation,
luminosity, red, green, blue and alpha respectively.
parts: ''
Determine which parts to display.
Use any of the preset names ('full', 'popup' or 'inline') or specify
an array of part names (i.e. ['header', 'map', 'bar', 'hex', 'hsv',
'rgb', 'alpha', 'lab', 'cmyk', 'preview', 'swatches', 'footer']).
If an empty string is given, the parts will be automatically chosen as
preset 'popup' or 'inline' depending on the context in which the
colorpicker is used.
rgb: true, // Show RGB controls and modes
Whether or not to show the inputs for RGB.
regional: '',
Sets the language to use. Note that you must load the appropriate
language file from the i18n directory. '' is included by default.
showAnim: 'fadeIn'
Same as jQueryUI DatePicker.
showCancelButton: true
Show the Cancel button if buttonpane is visible.
showCloseButton: true
Show the Close button if the header is visible.
If the dialog is inline, the close button is never shown.
showNoneButton: false
Show the None/Revert button if buttonpane is visible.
showOn: 'focus'
Same as jQueryUI DatePicker.
showOptions: {}
Same as jQueryUI DatePicker.
swatches: null
'null' to show swatches of HTML colors or provide your own object
with colornames and {r:1, g:1, b:1} array.
For example { 'red': {r:1, g:0, b:0}, 'blue': {r:0, g:0, b:1} }
title: null
Title to display in the header. If null, use language default.
Events:
init: null
Triggered on initially setting the color. Called only once.
Callbacks recieve same data as select event.
close: null
Triggered when the popup is closed.
Callbacks recieve same data as select event and an additional number
of fields containing the current color in all supported color spaces.
These are rgb{}, hsv{}, cmyk{}, lab{}, hsl{} and a.
Most values are floating point numbers in range [0,1] for accuracy.
The a and b values in the lab color space have range [-1,1].
select: null
Triggered on each change, confirmation (click on OK button) and
cancellation (click on Cancel, outside window or window close button)
respectively.
The event recieves a jQuery event object and a data object containing
the elements 'formatted' (with the color formatted according to
formatColor).
Note that select may be triggered in rapid succession when dragging
the mouse accross the map or bar and may be triggered without a change
in color upon specific user interactions.
Methods:
open
Open the dialog
close
Close the dialog
destroy
Destroy the widget
setColor
Set the current color to the specified color. Accepts any
CSS-confirmant color specification.

View File

@ -0,0 +1,539 @@
<p align="center"><img src="images/logotype-a.png"></p>
<p align="center">A full-featured colorpicker for jQueryUI with full theming support.</p>
[![Release](https://badge.fury.io/js/vanderlee-colorpicker.svg)](https://badge.fury.io/js/vanderlee-colorpicker)
[![License](https://img.shields.io/github/license/vanderlee/colorpicker.svg)](https://choosealicense.com/licenses/mit/)
Copyright © 2011-2019 Martijn W. van der Lee.
Most images from jPicker by Christopher T. Tillman.
Sourcecode created from scratch by Martijn W. van der Lee.
Features
--------
- jQueryUI (themeroller-based) look & feel
- Familiar interface layout
- Highly configurable
- Control parts
- Layout
- Input/output formats
- Swatches
- Many more
- Accurate color model
- Supports localization
- English, Dutch, French, etc.
- Easily translatable (https://www.transifex.com/projects/p/jquery-colorpicker/)
- Smart window alignment
- Complete API with events and methods
- Easily extendable with plugins
- Many examples included: RGB-Sliders with CSS gradients, Per-user cookie
memory for colors.
- Documented
- Limited Unit tests (QUnit-based)
- Disable/enable
- Keyboard support
Requirements
------------
jQuery 1.7.1 or higher required (will not work with v1.6 or before).
jQueryUI 1.8.0 or higher required.
For jQuery 3.0.0 or higher, you must use jQueryUI 1.12.0 or higher.
IE support; make sure you have a doctype defined, or the colorpicker will not
display correctly.
Installation
------------
With **npm**: `npm install vanderlee-colorpicker`
With **yarn**: `yarn add vanderlee-colorpicker`
With **bower** (deprecated): `bower install colorpicker`
Zip archive: https://github.com/vanderlee/colorpicker/archive/master.zip
jQueryUI custom build
---------------------
If you download a custom build of jQueryUI, you need these components:
* Dialog (includes Core, Widget, Mouse, Position, Draggable and Resizable)
* Fade Effect (only if you use the `showAnim` option, includes Effects Core)
To use the `parts/jquery.ui.colorpicker-rgbslider.js` plugin, you must add:
* Slider (includes Core, Widget and Mouse)
To use the demo page included in the documentation, you must add:
* Tabs (includes Core and Widget)
Browser support
---------------
Tested various versions of this plugin with the following browsers:
- Chrome 31-54
- FireFox 25-48
- Opera 17-39
- Internet Explorer 10-11
- Edge 20-25
Keyboard support
----------------
You can use the arrow keys to move the cursors on the map and bar controls.
Steps are measures in on-screen pixels.
Holding the `shift` key while using the arrow keys takes steps 10x larger.
Pressing the `page down` and `page up` keys does the same for vertical movement.
Holding the `ctrl` key while using the arrow keys takes you to the edges.
Pressing the `home` and `end` keys does the same for vertical movement.
Documentation
=============
`.colorpicker(options)`
--------------------
Turns an element into a colorpicker.
Options
-------
### alpha (false)
Whether or not to show the inputs for alpha.
### altAlpha (true)
Change the opacity of the altField element(s) according to the alpha setting.
### altField ('')
Change the background color of the elements specified in this element.
### altOnChange (true)
If true, the altField element(s) are updated on every change, otherwise
only upon closing.
### altProperties (background-color)
Comma-separated list of CSS properties to set color of in the altField.
The following properties are allowed, all others are ignored.
* ``background-color``
* ``border-color``
* ``color``
* ``fill``
* ``outline-color``
* ``stroke``
### autoOpen (false)
If true, the dialog opens automatically upon page load.
### buttonClass (null)
If this option is set to a string, the button will be assigned the
class specified.
### buttonColorize (false)
If a `buttonImage` is specified, change the background color of the
image when the color is changed.
### buttonImage ('images/ui-colorpicker.png')
Same as jQueryUI DatePicker.
### buttonImageOnly (false)
Same as jQueryUI DatePicker.
### buttonText (null)
Same as jQueryUI DatePicker. If null, use language default.
### cancelOnExit (false)
If true, the value is reverted to the original one on exit.
### closeOnEscape (true)
Close the window when pressing the Escape key on the keyboard.
### closeOnOutside (true)
Close the window when clicking outside the colorpicker display.
### color ('#00FF00')
Initial color. Formats recognized are:
* #rrggbb
* rrggbb (same as previous, but without the #)
* rgb(rrr,ggg,bbb)
* rgba(rrr,ggg,bbb,a.a)
* rgb(rrr%,ggg%,bbb%)
* rgba(rrr%,ggg%,bbb%,aaa%)
* w3c-defined color name
### colorFormat ('HEX')
Specifies the format of the color string returned in callbacks.
You can either specify one of the predefined formats:
* ``#HEX`` #112233 (#RRGGBB)
* ``#HEX3`` #123 (#RGB) if possible, otherwise false.
* ``HEX`` 112233 (RRGGBB)
* ``HEX3`` 123 (RGB) if possible, otherwise false.
* ``#HEXA`` #11223344 (#RRGGBBAA)
* ``#HEXA4`` #1234 (#RGBA) if possible, otherwise false.
* ``HEXA`` 11223344 (RRGGBBAA)
* ``HEXA4 `` 1234 (RGBA) if possible, otherwise false.
* ``RGB`` rgb(123,45,67) if opaque, otherwise false.
* ``RGBA`` rgba(123,45,67,0.123%)
* ``RGB%`` rgb(12%,34%,56%) if opaque, otherwise false.
* ``RGBA%`` rgba(12%,34%,56%,0.123%)
* ``HSL`` hsl(123,45,67) if opaque, otherwise false.
* ``HSLA`` hsla(123,45,67,0.123%)
* ``HSL%`` hsl(12%,34%,56%) if opaque, otherwise false.
* ``HSLA%`` hsla(12%,34%,56%,0.123%)
* ``NAME`` Closest color name
* ``EXACT`` Exact name if possible, otherwise false.
or specify your own format...
Each color channel is specified as a pair of two characters.
The first character determines the color channel:
* ``a`` Alpha
* ``r, g, b`` RGB color space; red, green and blue
* ``h, s, v`` HSV color space; hue, saturation and value
* ``c, m, y, k`` CMYK color space; cyan, magenta, yellow and black
* ``L, A, B`` LAB color space; Luminosity, *A and *B.
The second character specifies the data type:
* ``x`` Two-digit hexadecimal notation.
* ``d`` Decimal (0-255) notation.
* ``f`` Floating point (0-1) notation, not rounded.
* ``p`` Percentage (0-100) notation, not rounded.
If you prefix a valid pair with a backslash, it won't be replaced.
All patterns are case sensitive.
For example, to create the common hex color format, use "#rxgxbx".
For an rgba() format, use "rgba(rd,gd,bd,af)"
You can also specify an array of formats where the first non-FALSE one
is returned. Note that the only formats able to return FALSE are the
predefined formats HEX3 and EXACT. For example, this array will output
HEX3 format if possible or HEX format otherwise:
* ``['HEX3', 'HEX']``
### disabled (false)
Disable or enable the colorpicker and all it's controls by setting this option.
If you disable the `input` using the `disabled` HTML attribute before attaching
a colorpicker, it will automatically be disabled.
You can change this option using the `option` method call.
### draggable (true)
Make the dialog draggable if the header is visible and the dialog is
not inline.
### containment (null)
If the dialog is draggable, constrains dragging to within the bounds of the
specified element or region. Same as jQueryUI Draggable.
### duration ('fast')
Same as jQueryUI DatePicker.
### hideOn ('button')
Specifies what user events will hide the colorpicker if not inline.
Specify multiple events by separating with space.
* ``focus`` When the element goes out of focus (either tab or click)
* ``click`` When the element is clicked (for non-inputs)
* ``alt`` When clicking on an element specified with as altField
* ``button`` When clicking on the button created if this event is specified.
* ``all`` selects all possible triggers
* ``both`` same as ``all`` (deprecated, kept backwards compatibility)
### hsv (true)
Whether or not to show the inputs for HSV.
### inline (true)
If set to false, attaching to a non-input will still make the dialog
a popup instead of inline. Make sure you handle events to catch the
color change, otherwise you can't use the color.
### inlineFrame (true)
If enabled, shows a border and background when inline. Disabling may
allow closer integration.
### layout ({ ... })
Set the position of elements in a table layout.
You could create any layout possible with HTML tables by specifying
cell position and size of each part.
The layout option takes a map (object) with each property name matching one of
the available parts (including any possible custom or plugin parts). The value
is a an array with four coordinates on order `[`left`, `top`, `width`,
`height`]`.
The coordinates correspond to cells in a table, so if you want to have a part
at top-left and spanning two rows and three columns, the value would be
`[0, 0, 3, 2]`.
Care should be taken to ensure no parts overlap (best to just draw out a grid
on paper first). Behavior is undefined if parts overlap. You need not cover
the entire rectangular area; any empty cells will be simply remain empty.
The default layout is as follows:
{
map: [0, 0, 1, 5],
bar: [1, 0, 1, 5],
preview: [2, 0, 1, 1],
hsv: [2, 1, 1, 1],
rgb: [2, 2, 1, 1],
alpha: [2, 3, 1, 1],
hex: [2, 4, 1, 1],
lab: [3, 1, 1, 1],
cmyk: [3, 2, 1, 2],
swatches: [4, 0, 1, 5]
}
### limit ('')
Limit the selectable colors to any of the predefined limits:
* ``''`` No limitations, allow 8bpp color for a palette of all 16 million
colors.
* ``websafe`` Set of 216 colors composed of 00, 33, 66, 99, cc and ff color
channel values in #rrggbb.
* ``nibble`` 4 bits per color, can be easily converted to #rgb format. The
palette is limited to 4096 colors.
* ``binary`` Allow only #00 or #ff as color channel values for primary colors
only; only 8 colors are available with this limit.
* ``name`` Limit to closest color name.
### modal (false)
Ensures no other controls on screen can be used while the dialog is
opened.
Also look at showCancelButton and closeOnEscape to use in combination
with the modal option. closeOnOutside is redundant when used with modal.
### mode ('h')
Determines the functionality of the map and bar components. Allowed
values are; 'h', 's', 'l', 'r', 'g', 'b' or 'a', for hue, saturation,
luminosity, red, green, blue and alpha respectively.
### okOnEnter (false)
Close the window when pressing the Enter key on the keyboard, keeping the
selected color.
### part
Use the part option to specify options specific to parts (including plugin
parts). By default, the following part options are available:
### parts ('')
Determine which parts to display.
Use any of the preset names ('full', 'popup' or 'inline') or specify an array
of part names (i.e. ['header', 'map', 'bar', 'hex', 'hsv',
'rgb', 'alpha', 'lab', 'cmyk', 'preview', 'swatches', 'footer']).
If an empty string is given, the parts will be automatically chosen as
preset 'popup' or 'inline' depending on the context in which the
colorpicker is used.
### position (null)
Specify the position of the dialog as a jQueryUI position object.
See [jQueryUI .position() API documentation](http://api.jqueryui.com/position/)
for information on how to use.
ColorPicker adds an additional option to the `of` option; the value `'element'`
will refer to the element to which the ColorPicker is attached, including if it
is invisible).
By default, the dialog will attached to the bottom-left of the element, flipping
on collision.
### regional ('')
Sets the language to use. Note that you must load the appropriate language file
from the i18n directory. '' is included by default.
### revert (false)
If enabled, closing the dialog through any means but the OK button will revert
the color back to the previous state, as if pressing the Cancel button.
The revert option changes the behavior of the [X] button in the header, the
Escape keyboard button and clicking outside the dialog, when any of these
features are enabled.
### rgb (true)
Whether or not to show the inputs for RGB.
### showAnim ('fadeIn')
Same as jQueryUI DatePicker.
### showCancelButton (true)
Show the Cancel button if buttonpane is visible.
### showCloseButton (true)
Show the Close button if the header is visible.
If the dialog is inline, the close button is never shown.
### showNoneButton (false)
Show the None/Revert button if buttonpane is visible.
### showOn ('focus click alt')
Specifies what user events will show the colorpicker if not inline.
Specify multiple events by separating with space.
* ``focus`` When the element comes into focus (either tab or click)
* ``click`` When the element is clicked (for non-inputs)
* ``alt`` When clicking on an element specified with as altField
* ``button`` When clicking on the button created if this event is specified.
* ``all`` selects all possible triggers
* ``both`` same as ``all`` (deprecated, kept backwards compatibility)
### showOptions ({})
Same as jQueryUI DatePicker.
### swatches (null)
'null' to show swatches of HTML colors or provide your own object
with colornames and {r:1, g:1, b:1} array.
For example { 'red': {r:1, g:0, b:0}, 'blue': {r:0, g:0, b:1} }
Alternatively, load a predefined set of swatches and specify the name.
For example, for the pantone set, specify 'pantone'.
### swatchesWidth (84)
Width of the swatches display in pixels.
### title (null)
Title to display in the header. If null, use language default.
Events
------
Each event receives a jQuery `event` object and an object containing the
elements 'formatted' (with the color formatted according to `formatColor`),
the Colorpicker element that triggered the event and the color represented in a
number of format:
* `hex: rrggbb`
* `css: #rrggbb`
* `a: ...`
* `rgb: {r: ..., g: ..., b: ...}`
* `hsv: {h: ..., s: ..., v: ...}`
* `cmyk: {c: ..., m: ..., y: ..., k: ...}`
* `hsl: {h: ..., s: ..., l: ...}`
* `lab: {l: ..., a: ..., b: ...}`
Note that select may be triggered in rapid succession when dragging
the mouse across the map or bar and may be triggered without a change
in color upon specific user interactions.
### cancel (event, {formatted: ..., colorPicker: ...})
Triggered when the dialog is closed through the cancel button.
### close (event, {formatted: ..., colorPicker: ...})
Triggered when the popup is closed.
### init (event, {formatted: ..., colorPicker: ...})
Triggered on initially setting the color. Called only once.
Callbacks receive same data as select event.
### ok (event, {formatted: ..., colorPicker: ...})
Triggered when the dialog is closed through the cancel button.
### open (event, {formatted: ..., colorPicker: ...})
Triggered whenever the dialog is opened.
### ready (event, {formatted: ..., colorPicker: ...})
Triggered after creating the widget/dialog.
### select (event, {formatted: ..., colorPicker: ...})
Triggered on each change, confirmation (click on OK button) and
cancellation (click on Cancel, outside window or window close button)
respectively.
### stop(event, {formatted: ..., colorPicker: ...})
Triggered when the user stops changing a control. This only affects the map
and bar parts. Where the `select` event will trigger on each mouse move, the
`stop` event will only trigger when the mouse button is released. For other
controls, `stop` and `select` are both triggered.
The callback is otherwise identical to `select`. When both are triggered,
`select` is triggered before `stop`.
Methods
-------
### open
Open the dialog
### close
Close the dialog
### destroy
Destroy the widget
### setColor
Set the current color to the specified color. Accepts any CSS-confirming color
specification.
Plugins
-------
Colorpicker is extensible with several types of plugins. A number of plugins
is provided for use. The plugins are constructed such that you only need to
load the javascript file after the Colorpicker plugin itself is loaded.
### limits
Limits let you limit the possible colors, as used by the 'limit' option.
No plugins included.
### parsers
Parser take a textual representation of a color and return a Color object.
If no match is found, nothing is returned and the next parser is tried.
Parsers are tried in order of appearance.
Included plugins:
* ``cmyk-parser`` Parses a ``cmyk(c, y, m, k)`` format, similar
to rgba.
* ``cmyk-percentage-parser`` Parses a ``cmyk(c%, y%, m%, k%)`` format with
percentages.
### parts
You can add additional visual parts, usually controls, that interact
with the rest of Colorpicker framework.
Included plugins:
* ``memory`` Cookie-based memory nodes.
* ``rgbsliders`` Set of three red/green/blue sliders with dynamically
adjusted gradients.
* ``swatchesswitcher`` Switch through all available sets of swatches.
### partslists
Partslists are a convenient way to select multiple parts at once without having
to specify each one individually.
No plugins included.
### regional
Regional (in the i18n directory) plugins contain localized texts
(a.k.a. translations). A number of languages is provided.
Included regionals:
* ``de`` German (Deutsch).
* ``el`` Greece.
* ``en`` English (default).
* ``fr`` French.
* ``nl`` Dutch.
* ``pt-br`` Brazilian Portuguese.
* ``ru`` Russian.
### swatches
Swatches are collections of predefined and named colors. By default the
standard ``html`` colors are loaded.
Setting `swatches` using the `option` method will switch the displayed swatches.
Included plugins:
* ``crayola`` Crayola pencil color names
* ``pantone`` Pantone color codes
* ``ral-classic`` Classic RAL paint numbers
* ``x11`` X11 color palette (using "gray", not "grey").
### writers
Writers take a Color object and output a textual representation of the color.
Writers are used for the colorFormat option.
No plugins included.
Objects
-------
Colorpicker uses a Color object internally to represent a color and convert
between the supported color models.
You can create a new Color object through $.colorpicker.Color.

View File

@ -1,20 +1,28 @@
Fix the weird one-pixel vertical shift bug.
Caused by ui-widget class.
Only happens in Chrome and only on some, not all.
Disappears and re-appears at different zoom levels.
In hex input, accept (and strip) '#' symbol on copy/past.
Completely destroy object when closed.
Enabled/disabled
isRTL? What to RTL, besides button?
Disable selection in MSIE: this.dialog.on('selectstart', function(event) { return false; })
Special rendering mode for color_none? Use [X] images?
Fix parsing from input with websafe colors
Recognize "transparent" color name.
Limit number of events triggered.
Small size variant (128x128)
isRTL? What to RTL, besides button?
Undo/redo memory?
ARIA support.
Allow only set (dec/hex) characters in inputs
Most-recently-used swatches
HSL/HSV distance calculations should take into account cyclic hue.
$.undelegate and remove keydown methods for opening upon close()
Separate into a pure dialog and a "caller" plugin.
Implement a getColor method.
Use preconfigured/default output color.
Allow optional manual specification of color.
Fix the weird one-pixel vertical shift bug.
Caused by ui-widget class.
Only happens in Chrome and only on some, not all.
Disappears and re-appears at different zoom levels.
In hex input, accept (and strip) '#' symbol on copy/past.
Completely destroy object when closed.
Enabled/disabled
isRTL? What to RTL, besides button?
Disable selection in MSIE: this.dialog.on('selectstart', function(event) { return false; })
Special rendering mode for color_none? Use [X] images?
Fix parsing from input with websafe colors
Recognize "transparent" color name.
Limit number of events triggered.
Small size variant (128x128)
isRTL? What to RTL, besides button?
Undo/redo memory?
ARIA support.
Allow only set (dec/hex) characters in inputs
Most-recently-used swatches
HSL/HSV distance calculations should take into account cyclic hue.
Support CSS4 color format draft proposals: http://dev.w3.org/csswg/css-color/
Add more swatches; i.e. http://en.wikipedia.org/wiki/List_of_8-bit_computer_hardware_palettes
Allow Cancel button to be enabled even when no change. Extra value for `showCancelButton`?

View File

@ -0,0 +1,26 @@
{
"name": "colorpicker",
"version": "1.2.20",
"homepage": "https://github.com/vanderlee/colorpicker",
"authors": [
"Martijn van der Lee <martijn@vanderlee.com>"
],
"description": "JQuery colorpicker: themeroller styling, RGB, HSL, CMYK and L*A*B support. Standard look & feel, configurable. Works as a popup or inline.",
"main": "jquery.colorpicker.js",
"keywords": [
"jquery",
"colorpicker"
],
"license": "MIT",
"ignore": [
"**/.*",
"node_modules",
"bower_components",
"test",
"tests"
],
"dependencies": {
"jquery": ">=1.7.1",
"jquery-ui": ">=1.8.0"
}
}

View File

@ -0,0 +1,641 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>jQuery Colorpicker</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<!-- jQuery/jQueryUI (hosted) -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/jquery-ui.js"></script>
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/themes/ui-lightness/jquery-ui.css" rel="stylesheet" type="text/css"/>
<style>
body {
font-family: 'Segoe UI', Verdana, Arial, Helvetica, sans-serif;
font-size: 62.5%;
}
</style>
<script src="jquery.colorpicker.js"></script>
<link href="jquery.colorpicker.css" rel="stylesheet" type="text/css"/>
<script src="i18n/jquery.ui.colorpicker-nl.js"></script>
<script src="swatches/jquery.ui.colorpicker-pantone.js"></script>
<script src="swatches/jquery.ui.colorpicker-crayola.js"></script>
<script src="swatches/jquery.ui.colorpicker-ral-classic.js"></script>
<script src="swatches/jquery.ui.colorpicker-x11.js"></script>
<script src="swatches/jquery.ui.colorpicker-copic.js"></script>
<script src="swatches/jquery.ui.colorpicker-prismacolor.js"></script>
<script src="swatches/jquery.ui.colorpicker-isccnbs.js"></script>
<script src="swatches/jquery.ui.colorpicker-din6164.js"></script>
<script src="parts/jquery.ui.colorpicker-rgbslider.js"></script>
<script src="parts/jquery.ui.colorpicker-memory.js"></script>
<script src="parts/jquery.ui.colorpicker-swatchesswitcher.js"></script>
<script src="parsers/jquery.ui.colorpicker-cmyk-parser.js"></script>
<script src="parsers/jquery.ui.colorpicker-cmyk-percentage-parser.js"></script>
<script>
$(function() {
$('#tabs').tabs();
});
</script>
</head>
<body>
<h1>jQuery ColorPicker - Demo page</h1>
<div id="tabs">
<ul>
<li><a href="#tab-input">Basic &lt;input&gt;</a></li>
<li><a href="#tab-element">Basic element</a></li>
<li><a href="#tab-full">All features</a></li>
<li><a href="#tab-i18n">Localization</a></li>
<li><a href="#tab-websafe">Websafe colors</a></li>
<li><a href="#tab-alt">Alternative display field</a></li>
<li><a href="#tab-events">Events</a></li>
<li><a href="#tab-input-format">Input formatting</a></li>
<li><a href="#tab-format">Output formatting</a></li>
<li><a href="#tab-format-list">Output format list</a></li>
<li><a href="#tab-dialog">In a dialog</a></li>
<li><a href="#tab-modal">Modal</a></li>
<li><a href="#tab-no-inline">Any element to popup</a></li>
<li><a href="#tab-layout">Custom layout</a></li>
<li><a href="#tab-pantone">Custom swatches</a></li>
<li><a href="#tab-swatches-array">Custom swatches - array</a></li>
<li><a href="#tab-hidden-input">Hidden input</a></li>
<li><a href="#tab-plugins">Plugins</a></li>
<li><a href="#tab-buttonImageOnly">buttonImageOnly</a></li>
<li><a href="#tab-revert">Revert</a></li>
<li><a href="#tab-okonenter">Close on enter</a></li>
<li><a href="#tab-128">128-pixel map and bar</a></li>
<li><a href="#tab-customcolor">Custom color format</a></li>
<li><a href="#tab-position">Centered in window</a></li>
<li><a href="#tab-disable">Disable/enable</a></li>
<li><a href="#tab-noanim">No show animation</a></li>
</ul>
<div id="tab-input">
<h2>Basic &lt;input&gt; example, without any options</h2>
<input type="text" class="cp-basic" value="fe9810"/>
<script>
$(function() {
});
</script>
</div>
<div id="tab-element">
<h2>Basic element (&lt;span&gt;> example, without any options</h2>
<span class="cp-basic" style="display: inline-block; vertical-align: top;"></span>
<script>
$(function() {
$('.cp-basic').colorpicker();
});
</script>
</div>
<div id="tab-full">
<h2>Fully-featured example</h2>
<input type="text" class="cp-full" value="186aa7"/>
<script>
$(function() {
$('.cp-full').colorpicker({
parts: 'full',
showOn: 'both',
buttonColorize: true,
showNoneButton: true,
alpha: true,
colorFormat: 'RGBA'
});
});
</script>
</div>
<div id="tab-i18n">
<h2>Localized to Dutch (nl)</h2>
<input type="text" class="cp-i18n" value="ccea73"/>
<script>
$(function() {
$('.cp-i18n').colorpicker({
regional: 'nl',
showNoneButton: true,
alpha: true
});
});
</script>
</div>
<div id="tab-websafe">
<h2>Limit to websafe colors</h2>
<input type="text" class="cp-websafe" value="0fa7c2"/>
<script>
$(function() {
$('.cp-websafe').colorpicker({
limit: 'websafe'
});
});
</script>
</div>
<div id="tab-alt">
<h2>Alternative field class</h2>
<input type="text" class="cp-alt" value="b762ae"/>
<span class="cp-alt-target" style="display: inline-block; border: thin solid black; padding: .5em 4em;">
<div style=" background-color: white; border: thin solid black; padding: .25em 2em; font-size: 1.25em; font-weight: bold;">Background-color on outside, text color here</div>
</span>
<script>
$(function() {
$('.cp-alt').colorpicker({
altField: '.cp-alt-target',
altProperties: 'background-color,color',
altAlpha: true,
alpha: true
});
});
</script>
</div>
<div id="tab-events">
<h2>Events</h2>
<input type="text" class="cp-events" value="92b64a"/>
<div class="cp-events-log" style="vertical-align: top; display: inline-block; border: thin solid black; height: 10em; overflow-y: scroll; width: 50em;"></div>
<script>
$(function() {
var count = 0;
function addToEventLog(label, message) {
var line = '<div>#'+(++count)+' '+label+': '+message+'</div>',
log = $('.cp-events-log');
log.append(line).scrollTop(log[0].scrollHeight);
}
$('.cp-events').colorpicker({
init: function(event, color) {
addToEventLog('Init', color.formatted, color.colorPicker.color.toCSS());
},
select: function(event, color) {
addToEventLog('Select', color.formatted);
},
stop: function(event, color) {
addToEventLog('Stop', color.formatted);
},
close: function(event, color) {
addToEventLog('Close', color.formatted + ' r:' + color.rgb.r + ' g:' + color.rgb.g + ' b:' + color.rgb.b + ' a:' + color.a);
},
ok: function(event, color) {
addToEventLog('Ok', color.formatted + ' r:' + color.rgb.r + ' g:' + color.rgb.g + ' b:' + color.rgb.b + ' a:' + color.a);
},
open: function(event, color) {
addToEventLog('Open', color.formatted + ' r:' + color.rgb.r + ' g:' + color.rgb.g + ' b:' + color.rgb.b + ' a:' + color.a);
},
cancel: function(event, color) {
addToEventLog('Cancel', color.formatted + ' r:' + color.rgb.r + ' g:' + color.rgb.g + ' b:' + color.rgb.b + ' a:' + color.a);
}
});
});
</script>
</div>
<div id="tab-format">
<h2>Output formatting HSLA</h2>
<input type="text" class="cp-format" value="918237"/>
<span class="cp-format-output"></span>
<script>
$(function() {
$('.cp-format').colorpicker({
colorFormat: 'HSLA',
alpha: true,
init: function(event, color) {
$('.cp-format-output').text(color.formatted);
},
select: function(event, color) {
$('.cp-format-output').text(color.formatted);
}
});
});
</script>
</div>
<div id="tab-format-list">
<h2>Output format list</h2>
You can specify a list of output formats, the first perfect match for the color is output.<br/>
<input type="text" class="cp-name" value="a92fb4"/>
<span class="cp-name-output"></span>
<script>
$(function() {
$('.cp-name').colorpicker({
parts: 'full',
colorFormat: ['EXACT', '#HEX3', 'RGB', 'RGBA'],
init: function(event, color) {
$('.cp-name-output').text(color.formatted);
},
select: function(event, color) {
$('.cp-name-output').text(color.formatted);
}
});
});
</script>
</div>
<div id="tab-dialog">
<h2>Dialog with Colorpicker popup (demonstrates z-index)</h2>
<button id="cp-dialog-open">Open dialog</button>
<div id="cp-dialog-modal" title="Basic modal dialog">
Basic &lt;input&gt; example, without any options: <input type="text" class="cp-onclick" value="fe9810"/>
<br/>
Basic element example, without any options: <span class="cp-onclick" style="display: inline-block; vertical-align: top;"></span>
</div>
<script>
$(function() {
var dialogModal = $('#cp-dialog-modal').dialog({
autoOpen: false,
minWidth: 500,
modal: true,
buttons: { 'Close': function() {
$(this).dialog('close');
}
}
});
$('.cp-onclick').colorpicker({
showOn: 'click',
inlineFrame: false
});
$('#cp-dialog-open').click(function() {
dialogModal.dialog('open');
});
});
</script>
</div>
<div id="tab-modal">
<h2>Modal (and showCancelButton, closeOnEscape, showCloseButton)</h2>
<input type="text" class="cp-modal" value="9ba73f"/>
<script>
$(function() {
$('.cp-modal').colorpicker({
parts: 'draggable',
showCloseButton: false,
modal: true,
showCancelButton: false,
closeOnEscape: false
});
});
</script>
</div>
<div id="tab-input-format">
<h2>Input formatting</h2>
Demonstrates the ability to parse common color formats as input.<br/>
<input type="text" class="cp-input" value="rgb(123,42,87)"/>
<script>
$(function() {
$('.cp-input').colorpicker({
colorFormat: ['RGBA']
});
});
</script>
</div>
<div id="tab-no-inline">
<h2>Popup from any element (&lt;em&gt;)</h2>
Just click on this <em>Emphasized</em> word to show the colorpicker.
<script>
$(function() {
$('em').colorpicker({
inline: false
});
});
</script>
</div>
<div id="tab-layout">
<h2>Custom layout</h2>
It's easy to arrange a new layout for the dialog. Especially handy when used in a sidebar.<br/>
<input type="text" class="cp-layout" value="92b7a5"/>
<script>
$(function() {
$('.cp-layout').colorpicker({
parts: ['header', 'map', 'bar', 'hex', 'hsv', 'rgb', 'alpha', 'preview', 'swatches', 'footer'],
alpha: true,
layout: {
hex: [0, 0, 2, 1],
preview: [2, 0, 1, 1],
map: [0, 1, 3, 1], // Left, Top, Width, Height (in table cells).
bar: [0, 2, 1, 4],
swatches: [2, 2, 1, 4],
rgb: [1, 2, 1, 1],
hsv: [1, 3, 1, 1],
alpha: [1, 4, 1, 1],
lab: [0, 5, 1, 1],
cmyk: [1, 5, 1, 2]
}
});
});
</script>
</div>
<div id="tab-pantone">
<h2>Custom swatches</h2>
Use the Pantone PMS colors as swatches<br/>
<input type="text" class="cp-pantone" value="242"/>
<span class="cp-pantone-output"></span>
<script>
$(function() {
$('.cp-pantone').colorpicker({
parts: 'full',
swatches: 'pantone',
colorFormat: 'NAME',
swatchesWidth: 173,
limit: 'name',
init: function(event, color) {
$('.cp-pantone-output').text(color.formatted);
},
select: function(event, color) {
$('.cp-pantone-output').text(color.formatted);
}
});
});
</script>
</div>
<div id="tab-swatches-array">
<h2>Custom swatches - array</h2>
Use an array of swatches<br/>
<input type="text" class="cp-custom-array" value="666666"/>
<span class="cp-custom-array-output"></span>
<script>
$(function() {
/** Correctly handles the order of swatches.
*/
jQuery.colorpicker.swatches.custom_array = [
{name: '000000', r: 0, g: 0, b: 0},
{name: '444444', r: 0.266666666666667, g: 0.266666666666667, b:
0.266666666666667},
{name: '666666', r: 0.4, g: 0.4, b: 0.4},
{name: '999999', r: 0.6, g: 0.6, b: 0.6}
];
/** This is supported, but does not respect the order in chrome.
Black appears at the end of the list of swatches. */
jQuery.colorpicker.swatches.custom = {
'000000': {r: 0, g: 0, b: 0},
'444444': {r: 0.266666666666667, g: 0.266666666666667, b:
0.266666666666667},
'666666': {r: 0.4, g: 0.4, b: 0.4},
'999999': {r: 0.6, g: 0.6, b: 0.6}
};
$('.cp-custom-array').colorpicker({
parts: 'full',
swatches: 'custom_array',
colorFormat: 'NAME',
swatchesWidth: 173,
limit: 'name',
init: function(event, color) {
$('.cp-custom-array-output').text(color.formatted);
},
select: function(event, color) {
$('.cp-custom-array-output').text(color.formatted);
},
containment: 'body'
});
});
</script>
</div>
<div id="tab-hidden-input">
<h2>Hidden input</h2>
Uses a hidden input and buttons to pop open the colorpicker<br/>
<input type="hidden" class="cp-hidden-input" value="#abc123"/>
<button id="cp-hidden-input-open">Open</button>
<script>
$(function() {
var dialogHidden = $('.cp-hidden-input').colorpicker();
$('#cp-hidden-input-open').click(function(e) {
e.stopPropagation();
dialogHidden.colorpicker('open');
});
});
</script>
</div>
<div id="tab-plugins">
<h2>Plugins</h2>
Demonstrates how to extend the set of parts with plugins.<br/>
<ol>
<li>RGB Slider - Individual RGB sliders</li>
<li>Memory - Store and retrieve colors with cookies</li>
<li>Swatches Switcher - Switch between different sets of swatches</li>
</ol>
<input type="text" class="cp-plugins" value="#18b7af"/>
<script>
$(function() {
$('.cp-plugins').colorpicker({
parts: ['header', 'preview', 'hex', 'rgbslider', 'memory', 'swatches', 'swatchesswitcher', 'footer'],
layout: {
preview: [0, 0, 1, 1],
hex: [1, 0, 1, 1],
rgbslider: [0, 1, 2, 1],
memory: [0, 2, 2, 1],
swatchesswitcher: [2, 0, 1, 1],
swatches: [2, 1, 1, 2]
}
});
});
</script>
</div>
<div id="tab-buttonImageOnly">
<h2>Only a button image</h2>
<input type="text" class="cp-buttonImageOnly" value="#18b7af"/>
<br/>
<label for="toggle-cp-buttonImageOnly-disable">Enabled: <input type="checkbox" id="toggle-cp-buttonImageOnly-disable" checked="checked"/></label>
<script>
$(function() {
$('.cp-buttonImageOnly').colorpicker({
showOn: 'both',
buttonImageOnly: true
});
$('#toggle-cp-buttonImageOnly-disable').click(function() {
$('.cp-buttonImageOnly').colorpicker($(this).is(':checked') ? 'enable' : 'disable');
});
});
</script>
</div>
<div id="tab-revert">
<h2>Revert color on non-button exit.</h2>
<p>Reverts the color on escape, clickOnOutside or close window
using the [X] button.</p>
<p>Open the Colorpicker, change color and click outside window,
press ESC key or click the [X] button in the header. The dialog
should now close and the previous color restored in the
input.</p>
<input type="text" class="cp-revert" value=""/>
<script>
$(function() {
$('.cp-revert').colorpicker({
revert: true,
parts: 'full',
showNoneButton: true
});
});
</script>
</div>
<div id="tab-okonenter">
<h2>Close OK on enter</h2>
Close the popup by pressing the enter key, keeping the selected color.
<input type="text" class="cp-okonenter" value="a83b19"/>
<script>
$(function() {
$('.cp-okonenter').colorpicker({
okOnEnter: true
});
});
</script>
</div>
<div id="tab-128">
<h2>128-pixel map and bar</h2>
<span class="cp-128" style="display: inline-block; vertical-align: top;"></span>
<script>
$(function() {
$('.cp-128').colorpicker({
parts: ['map', 'bar'],
layout: {
map: [0, 0, 1, 1], // Left, Top, Width, Height (in table cells).
bar: [1, 0, 1, 1]
},
part: {
map: { size: 128 },
bar: { size: 128 }
}
});
});
</script>
</div>
<div id="tab-customcolor">
<h2>Custom color format</h2>
<input type="text" size="80" class="cp-customcolor" value="0;83.782958984375;83.782958984375;4.736328125" style="display: inline-block; vertical-align: top;"/>
<script>
$(function() {
$.colorpicker.parsers['csv-cmyk'] = function (color) {
var m = /^(\d+(?:\.\d+)?)\s*[,;]\s*(\d+(?:\.\d+)?)\s*[,;]\s*(\d+(?:\.\d+)?)\s*[,;]\s*(\d+(?:\.\d+)?)/.exec(color);
if (m) {
return (new $.colorpicker.Color()).setCMYK(
m[1] / 100,
m[2] / 100,
m[3] / 100,
m[4] / 100
);
}
};
$('.cp-customcolor').colorpicker({
showOn: 'both',
colorFormat: ['cp,mp,yp,kp'],
buttonImageOnly: true,
buttonColorize: true,
});
});
</script>
</div>
<div id="tab-position">
<h2>Centered using position option</h2>
<input type="text" class="cp-position"/>
<script>
$(function() {
$('.cp-position').colorpicker({
position: {
my: 'center',
at: 'center',
of: window
},
modal: true
});
});
</script>
</div>
<div id="tab-disable">
<h2>Disable/enable</h2>
<label for="toggle-cp-disable">Enabled: <input type="checkbox" id="toggle-cp-disable"/></label>
<br/>
Disabled by default:
<input type="text" class="cp-disable" value="186aa7" disabled="disabled"/>
<br/>
Disabled using option:
<input type="text" class="cp-disable-option" value="186aa7"/>
<br/>
<span class="cp-disable-option" style="display: inline-block; vertical-align: top;"></span>
<script>
$(function() {
$('.cp-disable').colorpicker({
showOn: 'both',
buttonColorize: true
});
$('.cp-disable-option').colorpicker({
parts: 'full',
// parts: ['header', 'preview', 'hex', 'rgbslider', 'memory', 'swatches', 'swatchesswitcher', 'footer'],
// layout: {
// preview: [0, 0, 1, 1],
// hex: [1, 0, 1, 1],
// rgbslider: [0, 1, 2, 1],
// memory: [0, 2, 2, 1],
// swatchesswitcher: [2, 0, 1, 1],
// swatches: [2, 1, 1, 2]
// },
showOn: 'both',
disabled: true,
buttonColorize: true,
alpha: true
});
$('#toggle-cp-disable').click(function() {
$('.cp-disable, .cp-disable-option').colorpicker($(this).is(':checked') ? 'enable' : 'disable');
});
});
</script>
</div>
<div id="tab-noanim">
<h2>No show animation</h2>
<input type="text" class="cp-noanim" value="8e44ad"/>
<script>
$(function() {
$('.cp-noanim').colorpicker({
showAnim: ''
});
});
</script>
</div>
</div>
</body>
</html>

View File

@ -0,0 +1,27 @@
;jQuery(function($) {
$.colorpicker.regional['de'] = {
ok: 'OK',
cancel: 'Abbrechen',
none: 'Keine',
button: 'Farbe',
title: 'Wähle eine Farbe',
transparent: 'Transparent',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

View File

@ -0,0 +1,28 @@
;
jQuery(function ($) {
$.colorpicker.regional['el'] = {
"alphaA": "A",
"button": "Χρώμα",
"cancel": "Άκυρο",
"cmykC": "C",
"cmykK": "K",
"cmykM": "M",
"cmykY": "Y",
"hslH": "H",
"hslL": "L",
"hslS": "S",
"hsvH": "H",
"hsvS": "S",
"hsvV": "V",
"labA": "a",
"labB": "b",
"labL": "L",
"none": "Κανένα",
"ok": "Επιβεβαίωση",
"rgbB": "B",
"rgbG": "G",
"rgbR": "Κ",
"title": "Επιλέξτε χρώμα",
"transparent": "Διαφάνεια"
};
});

View File

@ -0,0 +1,27 @@
;jQuery(function($) {
$.colorpicker.regional['en-GB'] = {
ok: 'OK',
cancel: 'Cancel',
none: 'None',
button: 'Colour',
title: 'Pick a colour',
transparent: 'Transparent',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

View File

@ -0,0 +1,27 @@
;jQuery(function($) {
$.colorpicker.regional['en-US'] = {
ok: 'OK',
cancel: 'Cancel',
none: 'None',
button: 'Color',
title: 'Pick a color',
transparent: 'Transparent',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

View File

@ -1,4 +1,4 @@
jQuery(function($) {
;jQuery(function($) {
$.colorpicker.regional['en'] = {
ok: 'OK',
cancel: 'Cancel',

View File

@ -0,0 +1,27 @@
;jQuery(function($) {
$.colorpicker.regional['es'] = {
ok: 'OK',
cancel: 'Cancelar',
none: 'Ninguno',
button: 'Color',
title: 'Selecciona un color',
transparent: 'Transparente',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

View File

@ -1,4 +1,4 @@
jQuery(function($) {
;jQuery(function($) {
$.colorpicker.regional['fr'] = {
ok: 'OK',
cancel: 'Annuler',

View File

@ -1,4 +1,4 @@
jQuery(function($) {
;jQuery(function($) {
$.colorpicker.regional['nl'] = {
ok: 'OK',
cancel: 'Annuleren',

View File

@ -0,0 +1,27 @@
;jQuery(function($) {
$.colorpicker.regional['pl'] = {
ok: 'OK',
cancel: 'Anuluj',
none: 'Wyczyść',
button: 'Kolor',
title: 'Wskaż kolor',
transparent: 'Przezroczysty',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

View File

@ -0,0 +1,27 @@
;jQuery(function($) {
$.colorpicker.regional['pt-br'] = {
ok: 'OK',
cancel: 'Cancelar',
none: 'Nenhum',
button: 'Cor',
title: 'Escolha uma cor',
transparent: 'Transparente',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

View File

@ -0,0 +1,27 @@
;jQuery(function($) {
$.colorpicker.regional['ru'] = {
ok: 'OK',
cancel: 'Отменить',
none: 'Никакой',
button: 'Цвет',
title: 'Выбрать цвет',
transparent: 'Прозрачный',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

View File

@ -0,0 +1,27 @@
;jQuery(function($) {
$.colorpicker.regional['sr'] = {
ok: 'OK',
cancel: 'Odustani',
none: 'Nijedno',
button: 'Boja',
title: 'Izaberi boju',
transparent: 'Providno',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

View File

@ -0,0 +1,27 @@
;jQuery(function ($) {
$.colorpicker.regional['uk'] = {
ok: 'ОК',
cancel: 'Скасувати',
none: 'Ніякий',
button: 'Колір',
title: 'Обрати колір',
transparent: 'Прозорий',
hsvH: 'H',
hsvS: 'S',
hsvV: 'V',
rgbR: 'R',
rgbG: 'G',
rgbB: 'B',
labL: 'L',
labA: 'a',
labB: 'b',
hslH: 'H',
hslS: 'S',
hslL: 'L',
cmykC: 'C',
cmykM: 'M',
cmykY: 'Y',
cmykK: 'K',
alphaA: 'A'
};
});

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -1,210 +1,332 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>jQuery Colorpicker</title>
<!-- jQuery/jQueryUI (hosted) -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.js"></script>
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/ui-lightness/jquery-ui.css" rel="stylesheet" type="text/css"/>
<style>
body {
font-family: 'Segoe UI', Verdana, Arial, Helvetica, sans-serif;
font-size: 62.5%;
}
</style>
<script src="jquery.colorpicker.js"></script>
<link href="jquery.colorpicker.css" rel="stylesheet" type="text/css"/>
<script src="i18n/jquery.ui.colorpicker-nl.js"></script>
</head>
<body>
<h1>jQuery ColorPicker</h1>
<hr/>
Basic &lt;input&gt; example, without any options: <input type="text" class="cp-basic" value="fe9810"/>
<hr/>
Basic &lt;div&gt; example, without any options: <span class="cp-basic" style="display: inline-block; vertical-align: top;"></span>
<script>
$( function() {
$('.cp-basic').colorpicker();
});
</script>
<hr/>
Fully-featured example: <input type="text" class="cp-full" value="186aa7"/>
<script>
$( function() {
$('.cp-full').colorpicker({
parts: 'full',
showOn: 'both',
buttonColorize: true,
showNoneButton: true,
alpha: true
});
});
</script>
<hr/>
Localized to Dutch (nl): <input type="text" class="cp-nl" value="ccea73"/>
<script>
$( function() {
$('.cp-nl').colorpicker({
regional: 'nl',
showNoneButton: true,
alpha: true
});
});
</script>
<hr/>
Limit to websafe colors: <input type="text" class="cp-websafe" value="0fa7c2"/>
<script>
$( function() {
$('.cp-websafe').colorpicker({
limit: 'websafe'
});
});
</script>
<hr/>
Alternative field class: <input type="text" class="cp-alt" value="b762ae"/>
<span class="cp-alt-target" style="display: inline-block; border: thin solid black; padding: .5em 4em;">
<div style=" background-color: white; border: thin solid black; padding: .25em 2em; font-size: 1.25em; font-weight: bold;">Background-color on outside, text color here</div>
</span>
<script>
$( function() {
$('.cp-alt').colorpicker({
altField: '.cp-alt-target',
altProperties: 'background-color,color',
altAlpha: true,
alpha: true
});
});
</script>
<hr/>
Events: <input type="text" class="cp-events" value="92b64a"/>
<div class="cp-events-log" style="vertical-align: top; display: inline-block; border: thin solid black; height: 10em; overflow-y: scroll; width: 50em;"></div>
<script>
$( function() {
var count = 0;
function addToEventLog(label, message) {
var line = '<div>#'+(++count)+' '+label+': '+message+'</div>';
var log = $('.cp-events-log');
log.append(line).scrollTop(log[0].scrollHeight);
}
$('.cp-events').colorpicker({
init: function(event, color) {
addToEventLog('Init', color.formatted);
},
select: function(event, color) {
addToEventLog('Select', color.formatted);
},
close: function(event, color) {
addToEventLog('Close', color.formatted + ' r:' + color.rgb.r + ' g:' + color.rgb.g + ' b:' + color.rgb.b + ' a:' + color.a);
}
});
});
</script>
<hr/>
Output formatting HSLA: <input type="text" class="cp-format" value="918237"/>
<span class="cp-format-output"></span>
<script>
$( function() {
$('.cp-format').colorpicker({
colorFormat: 'HSLA',
alpha: true,
init: function(event, color) {
$('.cp-format-output').text(color.formatted);
},
select: function(event, color) {
$('.cp-format-output').text(color.formatted);
}
});
});
</script>
<hr/>
Output format list: <input type="text" class="cp-name" value="a92fb4"/>
<span class="cp-name-output"></span>
<script>
$( function() {
$('.cp-name').colorpicker({
parts: 'full',
colorFormat: ['NAME', 'EXACT', '#HEX3', 'RGB', 'RGBA'],
init: function(event, color) {
$('.cp-name-output').text(color.formatted);
},
select: function(event, color) {
$('.cp-name-output').text(color.formatted);
}
});
});
</script>
<hr/>
Dialog with Colorpicker popup (demonstrates z-index):
<button id="cp-dialog-open">Open dialog</button>
<div id="cp-dialog-modal" title="Basic modal dialog">
Basic &lt;input&gt; example, without any options: <input type="text" class="cp-basic" value="fe9810"/>
<br/>
Basic &lt;div&gt; example, without any options: <span class="cp-basic" style="display: inline-block; vertical-align: top;"></span>
</div>
<script>
$(function() {
var dialog = $('#cp-dialog-modal').dialog({
autoOpen: false,
minWidth: 500,
modal: true,
buttons: { 'Close': function() {
$(this).dialog('close');
}
}
});
$('#cp-dialog-open').click(function() {
dialog.dialog('open');
});
});
</script>
<hr/>
Modal (and showCancelButton, closeOnEscape, showCloseButton): <input type="text" class="cp-modal" value="9ba73f"/>
<script>
$( function() {
$('.cp-modal').colorpicker({
parts: 'draggable',
showCloseButton: false,
modal: true,
showCancelButton: false,
closeOnEscape: false
});
});
</script>
<hr/>
Input formatting: <input type="text" class="cp-input" value="rgb(123,42,87)"/>
<script>
$( function() {
$('.cp-input').colorpicker({
colorFormat: ['RGBA']
});
});
</script>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>jQuery.Colorpicker</title>
<!-- jQuery/jQueryUI (hosted) -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.24/jquery-ui.js"></script>
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.24/themes/ui-lightness/jquery-ui.css" rel="stylesheet" type="text/css"/>
<!-- Markdown parser -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/pagedown/1.0/Markdown.Converter.min.js"></script>
<!-- Prettyprint -->
<link href="https://cdnjs.cloudflare.com/ajax/libs/prettify/r298/prettify.min.css" rel="stylesheet" type="text/css"/>
<script src="https://cdnjs.cloudflare.com/ajax/libs/prettify/r298/prettify.min.js"></script>
<!-- Index -->
<style>
body {
font-family: "Segoe UI", Verdana, Helvetica, Arial, sans-serif;
font-size: 11px;
padding: 3em 8em 1em 4em;
}
#logo {
background: url('images/logotype-a.png') no-repeat center center;
background-size: contain;
height: 20em;
}
#preview {
text-align: center;
}
#preview > * {
box-shadow: 0 0 2em silver;
padding: 2em;
}
.chapter {
-webkit-columns: 460px;
-moz-columns: 460px;
columns: 460px;
-webkit-column-gap: 4em;
-moz-column-gap: 4em;
column-gap: 4em;
-webkit-column-rule: thin solid silver;
-moz-column-rule: thin solid silver;
column-rule: thin solid silver;
text-align: justify;
}
h1,
h2 {
background: black;
color: white;
padding: .2em .4em;
}
h1 {
margin-top: 1em;
}
h2 {
background: gray;
}
hr {
border-top: double;
margin: 2em 25%;
}
#footer {
margin-top: 4em;
text-align: center;
color: silver;
border-top: thin solid silver;
padding-top: 1em;
}
.output {
font-family: monospace;
border: solid thin silver;
padding: .2em .4em;
background-color: #cf3;
}
.clickable {
cursor: pointer;
}
pre {
tab-size: 4;
overflow-x: auto;
background-color: #eee;
-webkit-column-break-inside: avoid;
}
</style>
<script>
$(function() {
function tabsToSpaces(line, tabsize) {
var out = '',
tabsize = tabsize || 4,
c;
for (c in line) {
var ch = line.charAt(c);
if (ch === '\t') {
do {
out += ' ';
} while (out.length % tabsize);
} else {
out += ch;
}
}
return out;
}
function visualizeElement(element, type) {
var code = $(element).html().split('\n'),
tabsize = 4,
minlength = 2E53,
l;
// Convert tabs to spaces
for (l in code) {
code[l] = tabsToSpaces(code[l], tabsize);
}
// determine minimum length
var minlength = 2E53;
var first = 2E53;
var last = 0;
for (l in code) {
if (/\S/.test(code[l])) {
minlength = Math.min(minlength, /^\s*/.exec(code[l])[0].length);
first = Math.min(first, l);
last = Math.max(last, l);
}
}
code = code.slice(first, last + 1);
// strip tabs at start
for (l in code) {
code[l] = code[l].slice(minlength);
}
// recombine
code = code.join('\n');
var fragment = $('<pre class="prettyprint"><code/></pre>').text(code).insertAfter(element);
$('<h3 class="clickable">'+type+'&hellip;</h3>').insertBefore(fragment).click(function() {
fragment.slideToggle();
});
}
// extract html fragments
$('div.prettyprint, span.prettyprint').each(function() {
visualizeElement(this, 'HTML');
});
// extract scripts
$('script.prettyprint').each(function() {
visualizeElement(this, 'Javascript');
});
// Include the readme
var markdown = new Markdown.Converter();
$.get('README.md', function(readme) {
$('#readme').html(markdown.makeHtml(readme));
$('#readme h1').each(function() {
$(this).nextUntil('h1').wrapAll('<div class="chapter"/>');
});
$('#readme pre').addClass('prettyprint');
prettyPrint();
// build menu
var menuitems = [];
$('h1').each(function() {
var text = $(this).text(),
id = $(this).attr('id') || 'chapter '+text;
$(this).attr('id', id);
menuitems.push('<a href="#'+id+'">'+text+'</a>');
});
$(menu).html(menuitems.join(' &mdash; '));
}, 'html');
});
</script>
<!-- Plugin -->
<script src="jquery.colorpicker.js"></script>
<link href="jquery.colorpicker.css" rel="stylesheet" type="text/css"/>
<!-- Plugin extensions -->
<script src="i18n/jquery.ui.colorpicker-nl.js"></script>
<script src="parts/jquery.ui.colorpicker-rgbslider.js"></script>
<script src="parts/jquery.ui.colorpicker-memory.js"></script>
</head>
<body>
<a href="https://github.com/vanderlee/colorpicker"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_darkblue_121621.png" alt="Fork me on GitHub"></a>
<div id="menu"></div>
<div id="logo"></div>
<div id="preview">
<span id="colorpicker-preview" style="display: inline-block; vertical-align: top;"></span>
<script>
$(function() {
$('#colorpicker-preview').colorpicker({
parts: 'full',
alpha: true
});
});
</script>
</div>
<div id="book">
<div id="readme"></div>
<h1>Examples</h1>
<div id="examples" class="chapter">
Try it yourself&hellip;
<h2>Simple popup</h2>
<div class="prettyprint">
<input type="text" id="colorpicker-popup" value="fe9810"/>
</div>
<script class="prettyprint">
$(function() {
$('#colorpicker-popup').colorpicker();
});
</script>
<h2>Fully featured popup</h2>
<div class="prettyprint">
<input type="text" id="colorpicker-full" value="fe9810"/>
</div>
<script class="prettyprint">
$(function() {
$('#colorpicker-full').colorpicker({
parts: 'full',
alpha: true,
showOn: 'both',
buttonColorize: true,
showNoneButton: true
});
});
</script>
<h2>Custom layout</h2>
<div class="prettyprint">
<input type="text" id="colorpicker-layout" value="fe9810"/>
</div>
<script class="prettyprint">
$(function() {
$('#colorpicker-layout').colorpicker({
parts: [ 'header', 'map', 'bar', 'hex',
'hsv', 'rgb', 'alpha', 'preview',
'swatches', 'footer'
],
alpha: true,
layout: {
hex: [0, 0, 2, 1],
preview: [2, 0, 1, 1],
map: [0, 1, 3, 1],
bar: [0, 2, 1, 4],
swatches: [2, 2, 1, 4],
rgb: [1, 2, 1, 1],
hsv: [1, 3, 1, 1],
alpha: [1, 4, 1, 1],
lab: [0, 5, 1, 1],
cmyk: [1, 5, 1, 2]
}
});
});
</script>
<h2>Plugins</h2>
<div class="prettyprint">
<input type="text" id="colorpicker-plugins" value="fe9810"/>
</div>
<script class="prettyprint">
$(function() {
$('#colorpicker-plugins').colorpicker({
parts: [ 'header', 'preview', 'hex',
'rgbslider', 'memory', 'footer'
],
layout: {
preview: [0, 0, 1, 1],
hex: [1, 0, 1, 1],
rgbslider: [0, 1, 2, 1],
memory: [0, 2, 2, 1]
}
});
});
</script>
<h2>Localization</h2>
<div class="prettyprint">
<input type="text" id="colorpicker-l10n" value="fe9810"/>
</div>
<script class="prettyprint">
$(function() {
$('#colorpicker-l10n').colorpicker({
parts: 'draggable',
regional: 'nl',
showNoneButton: true,
alpha: true
});
});
</script>
<h2>More examples&hellip;</h2>
Click here view a lot more demo's <a href="demo.html" target="_blank">Demos</a>
</div>
<h1>Unittest</h1>
<div id="unittest" class="chapter">
jQuery.colorpicker comes with a small set of QUnit-based unittests.<br/>
Click here to run the tests in a new window: <a href="test/index.html" target="_blank">Unittests</a>
</div>
</div>
<div id="footer">
Copyright &copy; 2011-2017 Martijn van der Lee. MIT Open Source license applies.
</div>
</body>
</html>

View File

@ -1,199 +1,238 @@
.ui-colorpicker,
.ui-dialog.ui-colorpicker {
width: auto;
white-space: nowrap;
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.ui-colorpicker-inline {
position: static;
}
.ui-colorpicker-buttonset {
float: left;
margin-left: .4em;
}
.ui-colorpicker-buttonset .ui-button {
margin: .5em 0 .5em 0;
cursor: pointer;
}
.ui-colorpicker-buttonpane {
background-image: none;
margin: .7em 0 0 0;
padding: 0 .2em;
border-left: 0;
border-right: 0;
border-bottom: 0;
}
.ui-colorpicker-buttonpane button {
float: right;
margin: .5em .2em .4em;
cursor: pointer;
padding: .2em .6em .3em .6em;
width: auto;
overflow: visible;
}
.ui-colorpicker-buttonpane button.ui-colorpicker-current {
float: left;
}
.ui-colorpicker table {
font-size: 100%; /* Reset browser table font-size */
margin: 0;
}
.ui-colorpicker table td {
vertical-align: top;
}
.ui-colorpicker-padding-left {
padding-left: 10px;
}
.ui-colorpicker-padding-top {
padding-top: 10px;
}
.ui-colorpicker-border {
border: 1px inset;
display: inline-block;
}
/* Bar & map */
.ui-colorpicker-map > *,
.ui-colorpicker-bar > * {
position: absolute;
cursor: crosshair;
}
.ui-colorpicker-map-pointer,
.ui-colorpicker-bar-pointer {
position: absolute;
}
/* Map */
.ui-colorpicker-map,
.ui-colorpicker-map > * {
display: block;
width: 256px;
height: 256px;
overflow: hidden;
}
.ui-colorpicker-map-layer-1,
.ui-colorpicker-map-layer-2 {
background: url(images/map.png) no-repeat;
}
.ui-colorpicker-map-layer-alpha {
background: url(images/map-opacity.png);
}
.ui-colorpicker-map-pointer {
display: inline-block;
width: 15px;
height: 15px;
background: url(images/map-pointer.png) no-repeat;
}
/* Bar */
.ui-colorpicker-bar,
.ui-colorpicker-bar > * {
display: block;
width: 20px;
height: 256px;
overflow: hidden;
background-repeat: repeat-x;
}
.ui-colorpicker-bar-layer-1,
.ui-colorpicker-bar-layer-2,
.ui-colorpicker-bar-layer-3,
.ui-colorpicker-bar-layer-4 {
background: url(images/bar.png) repeat-x;
}
.ui-colorpicker-bar-layer-alpha {
background: url(images/bar-opacity.png);
}
.ui-colorpicker-bar-layer-alphabar {
background: url(images/bar-alpha.png);
}
.ui-colorpicker-bar-pointer {
display: inline-block;
width: 20px;
height: 7px;
background: url(images/bar-pointer.png) no-repeat;
}
/* Preview */
.ui-colorpicker-preview {
text-align: center;
}
.ui-colorpicker-preview-initial {
cursor: pointer;
}
.ui-colorpicker-preview-initial,
.ui-colorpicker-preview-current {
width: 50px;
height: 20px;
display: inline-block;
}
.ui-colorpicker-preview-initial-alpha,
.ui-colorpicker-preview-current-alpha {
width: 50px;
height: 20px;
display: inline-block;
background: url(images/preview-opacity.png) repeat;
}
/* Inputs */
.ui-colorpicker-rgb label,
.ui-colorpicker-hsv label,
.ui-colorpicker-hsl label,
.ui-colorpicker-lab label,
.ui-colorpicker-cmyk label,
.ui-colorpicker-alpha label {
width: 1.5em;
display: inline-block;
}
.ui-colorpicker-number {
margin: .1em;
width: 4em;
}
/* Hex */
.ui-colorpicker-hex {
text-align: center;
}
/* Swatches */
.ui-colorpicker-swatches {
width: 84px;
height: 256px;
overflow: auto;
background-color: #f8f8f8;
}
.ui-colorpicker-swatch {
cursor: pointer;
float: left;
width: 11px;
height: 11px;
border-right: 1px solid black;
border-bottom: 1px solid black;
}
.ui-colorpicker,
.ui-dialog.ui-colorpicker {
width: auto;
white-space: nowrap;
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-ms-user-select: none;
user-select: none;
}
.ui-colorpicker-inline {
position: static;
}
.ui-colorpicker-buttonset {
float: left;
margin-left: .4em;
}
.ui-colorpicker-buttonset .ui-button {
margin: .5em 0 .5em 0;
cursor: pointer;
}
.ui-colorpicker-buttonpane {
background-image: none;
margin: .7em 0 0 0;
padding: 0 .2em;
border-left: 0;
border-right: 0;
border-bottom: 0;
}
.ui-colorpicker-buttonpane button {
float: right;
margin: .5em .2em .4em;
cursor: pointer;
padding: .2em .6em .3em .6em;
width: auto;
overflow: visible;
}
.ui-colorpicker-buttonpane button.ui-colorpicker-current {
float: left;
}
.ui-colorpicker table {
width: 100%;
font-size: 100%; /* Reset browser table font-size */
margin: 0;
}
.ui-colorpicker table td {
vertical-align: top;
}
.ui-colorpicker-padding-left {
padding-left: 10px;
}
.ui-colorpicker-padding-top {
padding-top: 10px;
}
.ui-colorpicker-border {
border: 1px inset;
display: inline-block;
}
/* Bar & map */
.ui-colorpicker-map > *,
.ui-colorpicker-bar > * {
position: absolute;
cursor: crosshair;
}
.ui-colorpicker-map-pointer,
.ui-colorpicker-bar-pointer {
position: absolute;
left: 0;
}
/* Map */
.ui-colorpicker-map,
.ui-colorpicker-map > * {
display: block;
width: 256px;
height: 256px;
overflow: hidden;
}
.ui-colorpicker-map-layer-1,
.ui-colorpicker-map-layer-2 {
background: url(images/map.png) no-repeat;
}
.ui-colorpicker-map-128,
.ui-colorpicker-map-128 > * {
width: 128px;
height: 128px;
}
.ui-colorpicker-map-128 .ui-colorpicker-map-layer-1,
.ui-colorpicker-map-128 .ui-colorpicker-map-layer-2 {
background: url(images/128/map.png) no-repeat;
}
.ui-colorpicker-map-layer-alpha {
background: url(images/map-opacity.png);
}
.ui-colorpicker-map-pointer {
display: inline-block;
width: 15px;
height: 15px;
background: url(images/map-pointer.png) no-repeat;
}
/* Bar */
.ui-colorpicker-bar,
.ui-colorpicker-bar > * {
display: block;
width: 20px;
height: 256px;
overflow: hidden;
background-repeat: repeat-x;
}
.ui-colorpicker-bar-128,
.ui-colorpicker-bar-128 > * {
height: 128px;
}
.ui-colorpicker-bar-layer-1,
.ui-colorpicker-bar-layer-2,
.ui-colorpicker-bar-layer-3,
.ui-colorpicker-bar-layer-4 {
background: url(images/bar.png) repeat-x;
}
.ui-colorpicker-bar-128 .ui-colorpicker-bar-layer-1,
.ui-colorpicker-bar-128 .ui-colorpicker-bar-layer-2,
.ui-colorpicker-bar-128 .ui-colorpicker-bar-layer-3,
.ui-colorpicker-bar-128 .ui-colorpicker-bar-layer-4 {
background: url(images/128/bar.png) repeat-x;
}
.ui-colorpicker-bar-layer-alpha {
background: url(images/bar-opacity.png);
}
.ui-colorpicker-bar-layer-alphabar {
background: url(images/bar-alpha.png);
}
.ui-colorpicker-bar-128 .ui-colorpicker-bar-layer-alphabar {
background: url(images/128/bar-alpha.png);
}
.ui-colorpicker-bar-pointer {
display: inline-block;
width: 20px;
height: 7px;
background: url(images/bar-pointer.png) no-repeat;
}
/* Preview */
.ui-colorpicker-preview {
text-align: center;
height: 20px;
}
.ui-colorpicker-preview-initial {
cursor: pointer;
}
.ui-colorpicker-preview-initial,
.ui-colorpicker-preview-current {
width: 50px;
height: 20px;
display: inline-block;
}
.ui-colorpicker-preview-initial-alpha,
.ui-colorpicker-preview-current-alpha {
width: 50px;
height: 20px;
display: inline-block;
background: url(images/preview-opacity.png) repeat;
}
/* Inputs */
.ui-colorpicker-rgb label,
.ui-colorpicker-hsv label,
.ui-colorpicker-hsl label,
.ui-colorpicker-lab label,
.ui-colorpicker-cmyk label,
.ui-colorpicker-alpha label {
width: 1.5em;
display: inline-block;
}
.ui-colorpicker-number {
margin: .1em;
width: 4em;
}
/* Hex */
.ui-colorpicker-hex {
text-align: center;
}
/* Swatches */
.ui-colorpicker-swatches {
height: 256px;
overflow: auto;
background-color: #f8f8f8;
}
.ui-colorpicker-swatch {
cursor: pointer;
float: left;
width: 11px;
height: 11px;
border-right: 1px solid black;
border-bottom: 1px solid black;
}
.ui-colorpicker-disabled {
opacity: .5;
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";
filter: alpha(opacity=50);
pointer-events: none;
}
.ui-colorpicker-disabled * {
cursor: default !important;
}

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,32 @@
{
"name": "vanderlee-colorpicker",
"version": "1.2.20",
"homepage": "https://github.com/vanderlee/colorpicker",
"author": "Martijn van der Lee <martijn@vanderlee.com>",
"repository": {
"type": "git",
"url": "https://github.com/vanderlee/colorpicker"
},
"description": "JQuery colorpicker: themeroller styling, RGB, HSL, CMYK and L*A*B support. Standard look & feel, configurable. Works as a popup or inline.",
"main": "jquery.colorpicker.js",
"keywords": [
"jquery",
"colorpicker"
],
"license": "MIT",
"ignore": [
"**/.*",
"node_modules",
"bower_components",
"test"
],
"dependencies": {
"jquery": ">=1.7.1",
"jquery-ui": ">=1.8.0"
},
"devDependencies": {
"eslint": "^5.15.1",
"stylelint": "^9.10.1",
"stylelint-config-recommended": "^2.1.0"
}
}

View File

@ -0,0 +1,13 @@
jQuery(function($) {
$.colorpicker.parsers['CMYK'] = function (color) {
var m = /^cmyk\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/.exec(color);
if (m) {
return (new $.colorpicker.Color()).setCMYK(
m[1] / 255,
m[2] / 255,
m[3] / 255,
m[4] / 255
);
}
};
});

View File

@ -0,0 +1,13 @@
jQuery(function($) {
$.colorpicker.parsers['CMYK%'] = function (color) {
var m = /^cmyk\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*\)$/.exec(color);
if (m) {
return (new $.colorpicker.Color()).setCMYK(
m[1] / 100,
m[2] / 100,
m[3] / 100,
m[4] / 100
);
}
};
});

View File

@ -0,0 +1,80 @@
jQuery(function($) {
$.colorpicker.parts.memory = function (inst) {
var that = this,
container,
selectNode = function(node) {
inst.color = inst._parseColor($(node).css('backgroundColor'));
inst._change();
},
deleteNode = function(node) {
node.remove();
},
addNode = function(color) {
var $node = $('<div/>').addClass('ui-colorpicker-swatch').css('backgroundColor', color);
$node.mousedown(function(e) {
e.stopPropagation();
if (!inst.options.disabled) {
switch (e.which) {
case 1:
selectNode(this);
break;
case 3:
deleteNode($node);
setMemory();
break;
}
}
}).on('contextmenu', function(e) {
e.preventDefault();
});
container.append($node);
},
getMemory = function() {
if (window.localStorage) {
var memory = localStorage.getItem('colorpicker-memory');
if (memory) {
return JSON.parse(memory);
}
}
return $.map((document.cookie.match(/\bcolorpicker-memory=([^;]*)/) || [0, ''])[1].split(','),unescape);
};
setMemory = function() {
var colors = [];
$('> *', container).each(function() {
colors.push($(this).css('backgroundColor'));
});
if (window.localStorage) {
localStorage.setItem('colorpicker-memory',JSON.stringify(colors));
}
else {
var expdate=new Date();
expdate.setDate(expdate.getDate() + (365 * 10));
document.cookie = 'colorpicker-memory='+$.map(colors,escape).join()+';expires='+expdate.toUTCString();
}
};
this.init = function () {
container = $('<div/>')
.addClass('ui-colorpicker-memory ui-colorpicker-border ui-colorpicker-swatches')
.css({
width: 84,
height: 84,
cursor: 'crosshair'
})
.appendTo($('.ui-colorpicker-memory-container', inst.dialog));
$.each(getMemory(), function() {
addNode(this);
});
container.mousedown(function(e) {
if (!inst.options.disabled) {
addNode(inst.color.toCSS());
setMemory();
}
});
};
};
});

View File

@ -0,0 +1,80 @@
jQuery(function($) {
/**
* Set a horizontal gradient background image on an element.
* Uses the now-deprecated $.browser
* @param $ element
* @param $.colorpicker.Color startColor
* @param $.colorpicker.Color endColor
* @returns {undefined}
*/
function setGradient(element, startColor, endColor) {
var start = startColor.toCSS(),
end = endColor.toCSS(),
styles = window.getComputedStyle(document.documentElement, ''),
prefix = (Array.prototype.slice.call(styles).join('').match(/-(moz|webkit|ms)-/) || (styles.OLink === '' && ['', 'o']))[1];
element.css('background-image', '-'+prefix+'-linear-gradient(left, '+start+' 0%, '+end+' 100%)');
}
$.colorpicker.parts.rgbslider = function (inst) {
var that = this,
sliders = { r: $('<div class="ui-colorpicker-slider"/>'),
g: $('<div class="ui-colorpicker-slider"/>'),
b: $('<div class="ui-colorpicker-slider"/>')
};
this.updateGradients = function () {
var color = inst.color.getRGB();
setGradient(sliders.r, new $.colorpicker.Color(0, color.g, color.b), new $.colorpicker.Color(1, color.g, color.b));
setGradient(sliders.g, new $.colorpicker.Color(color.r, 0, color.b), new $.colorpicker.Color(color.r, 1, color.b));
setGradient(sliders.b, new $.colorpicker.Color(color.r, color.g, 0), new $.colorpicker.Color(color.r, color.g, 1));
};
this.init = function () {
$('<div class="ui-colorpicker-rgbslider"/>').append(sliders.r, sliders.g, sliders.b)
.appendTo($('.ui-colorpicker-rgbslider-container', inst.dialog));
function refresh() {
var r = sliders.r.slider('value') / 255,
g = sliders.g.slider('value') / 255,
b = sliders.b.slider('value') / 255;
inst.color.setRGB(r, g, b);
inst._change();
that.updateGradients();
}
$(sliders.r).add(sliders.g).add(sliders.b).slider({
min: 0,
max: 255,
step: 1,
slide: refresh,
change: refresh
});
this.updateGradients();
};
this.repaint = function () {
$.each(inst.color.getRGB(), function (index, value) {
var input = sliders[index];
value = Math.round(value * 255);
if (input.slider('value') !== value) {
input.slider('value', value);
}
});
};
this.update = function () {
this.repaint();
};
this.disable = function (disabled) {
sliders.r.slider(disabled ? 'disable' : 'enable');
sliders.g.slider(disabled ? 'disable' : 'enable');
sliders.b.slider(disabled ? 'disable' : 'enable');
};
};
});

View File

@ -0,0 +1,35 @@
jQuery(function($) {
$.colorpicker.parts.swatchesswitcher = function (inst) {
var that = this,
part = null;
this.init = function () {
var names = $.map($.colorpicker.swatches, function(v, name) { return name; }).sort(),
current = inst.options.swatches || 'html',
select = $('<select>').width(inst.options.swatchesWidth + 2);
part = $('<div/>')
.addClass('ui-colorpicker-swatchesswitcher')
.css('text-align', 'center')
.appendTo($('.ui-colorpicker-swatchesswitcher-container', inst.dialog));
select.appendTo(part);
$.each(names, function(x, name) {
var label = $.colorpicker.swatchesNames[name]
|| name.replace(/[-_]/, ' ').replace(/^([a-z\u00E0-\u00FC])|\s+([a-z\u00E0-\u00FC])/g, function($1) {
return $1.toUpperCase();
});
$('<option>').val(name).text(label).appendTo(select);
});
select.val(current);
select.change(function() {
inst.option('swatches', $(this).val());
});
};
this.disable = function (disabled) {
$('select', part).prop('disabled', disabled);
};
};
});

View File

@ -0,0 +1,363 @@
jQuery(function($) {
$.colorpicker.swatchesNames['copic'] = 'Copic';
$.colorpicker.swatches['copic'] = [
{name: 'Colorless Blender', r: 1, g: 1, b: 1},
{name: 'Black', r: 0.1921568627451, g: 0.16862745098039, b: 0.16862745098039},
{name: 'Special Black', r: 0.011764705882353, g: 0.027450980392157, b: 0.031372549019608},
{name: 'Frost Blue', r: 0.86666666666667, g: 0.94117647058824, b: 0.95686274509804},
{name: 'Pale Porcelain Blue', r: 0.90196078431373, g: 0.95686274509804, b: 0.96078431372549},
{name: 'Pale Celestine', r: 0.94117647058824, g: 0.97647058823529, b: 0.99607843137255},
{name: 'Mint Blue', r: 0.83921568627451, g: 0.93333333333333, b: 0.94901960784314},
{name: 'Robin\'s Egg Blue', r: 0.70196078431373, g: 0.89019607843137, b: 0.94509803921569},
{name: 'Tahitian Blue', r: 0.45098039215686, g: 0.81176470588235, b: 0.90196078431373},
{name: 'Process Blue', r: 0.25098039215686, g: 0.77254901960784, b: 0.90196078431373},
{name: 'Peacock Blue', r: 0, g: 0.70196078431373, b: 0.90196078431373},
{name: 'Ice Blue', r: 0.7843137254902, g: 0.90196078431373, b: 0.94117647058824},
{name: 'Light Blue', r: 0.44313725490196, g: 0.81176470588235, b: 0.92156862745098},
{name: 'Cyanine Blue', r: 0, g: 0.73725490196078, b: 0.91764705882353},
{name: 'Lapis Lazuli', r: 0.11372549019608, g: 0.54117647058824, b: 0.79607843137255},
{name: 'Baby Blue', r: 0.85882352941176, g: 0.92941176470588, b: 0.97647058823529},
{name: 'Phthalo Blue', r: 0.57254901960784, g: 0.76078431372549, b: 0.90980392156863},
{name: 'Sky', r: 0.54117647058824, g: 0.8078431372549, b: 0.95294117647059},
{name: 'Cobalt Blue', r: 0.39607843137255, g: 0.70196078431373, b: 0.89019607843137},
{name: 'Royal Blue', r: 0.098039215686275, g: 0.42745098039216, b: 0.71372549019608},
{name: 'Ultramarine', r: 0.003921568627451, g: 0.46666666666667, b: 0.75686274509804},
{name: 'Pale Blue', r: 0.88627450980392, g: 0.93725490196078, b: 0.96862745098039},
{name: 'Manganese Blue', r: 0.50980392156863, g: 0.76470588235294, b: 0.92941176470588},
{name: 'Antwerp Blue', r: 0.082352941176471, g: 0.43529411764706, b: 0.64313725490196},
{name: 'Prussian Blue', r: 0.16862745098039, g: 0.3921568627451, b: 0.66274509803922},
{name: 'Powder Blue', r: 0.88627450980392, g: 0.94117647058824, b: 0.9843137254902},
{name: 'Smoky Blue', r: 0.45882352941176, g: 0.75294117647059, b: 0.91764705882353},
{name: 'Soft Greenish Blue', r: 0.67843137254902, g: 0.80392156862745, b: 0.86274509803922},
{name: 'Pale Blue Gray', r: 0.85490196078431, g: 0.88235294117647, b: 0.95294117647059},
{name: 'Light Hydrangea', r: 0.65490196078431, g: 0.73333333333333, b: 0.87843137254902},
{name: 'Clematis', r: 0.4078431372549, g: 0.53333333333333, b: 0.77254901960784},
{name: 'Stratospheric Blue', r: 0.12941176470588, g: 0.39607843137255, b: 0.68235294117647},
{name: 'Iris', r: 0.23137254901961, g: 0.27843137254902, b: 0.6156862745098},
{name: 'Pale Grayish Blue', r: 0.83529411764706, g: 0.88627450980392, b: 0.92156862745098},
{name: 'Light Crockery Blue', r: 0.5843137254902, g: 0.75686274509804, b: 0.85490196078431},
{name: 'Light Grayish Cobalt', r: 0.37647058823529, g: 0.77254901960784, b: 0.81176470588235},
{name: 'Night Blue', r: 0.27058823529412, g: 0.47843137254902, b: 0.60392156862745},
{name: 'Agate', r: 0.058823529411765, g: 0.32941176470588, b: 0.49411764705882},
{name: 'Pale Aqua', r: 0.89803921568627, g: 0.95686274509804, b: 0.92941176470588},
{name: 'Snow Green', r: 0.93725490196078, g: 0.97254901960784, b: 0.95294117647059},
{name: 'Aqua Blue', r: 0.78039215686275, g: 0.90196078431373, b: 0.98039215686275},
{name: 'New Blue', r: 0.77647058823529, g: 0.90980392156863, b: 0.91764705882353},
{name: 'Holiday Blue', r: 0.11372549019608, g: 0.72156862745098, b: 0.8078431372549},
{name: 'Petroleum Blue', r: 0.11372549019608, g: 0.72156862745098, b: 0.8078431372549},
{name: 'Blue Green', r: 0.86274509803922, g: 0.94117647058824, b: 0.93725490196078},
{name: 'Cool Shadow', r: 0.86274509803922, g: 0.94117647058824, b: 0.93725490196078},
{name: 'Moon White', r: 0.8078431372549, g: 0.92156862745098, b: 0.94509803921569},
{name: 'Mint Green', r: 0.76862745098039, g: 0.90588235294118, b: 0.91372549019608},
{name: 'Aqua', r: 0.62745098039216, g: 0.85098039215686, b: 0.82352941176471},
{name: 'Teal Blue', r: 0.2156862745098, g: 0.75294117647059, b: 0.69019607843137},
{name: 'Coral Sea', r: 0.74117647058824, g: 0.89803921568627, b: 0.86666666666667},
{name: 'Aqua Mint', r: 0.73725490196078, g: 0.88627450980392, b: 0.84313725490196},
{name: 'Horizon Green', r: 0.63921568627451, g: 0.85490196078431, b: 0.84313725490196},
{name: 'Nile Blue', r: 0.68627450980392, g: 0.87450980392157, b: 0.87450980392157},
{name: 'Duck Blue', r: 0, g: 0.71372549019608, b: 0.72549019607843},
{name: 'Ice Mint', r: 0.67450980392157, g: 0.81176470588235, b: 0.81960784313725},
{name: 'Jasper', r: 0.3921568627451, g: 0.74509803921569, b: 0.74509803921569},
{name: 'Ocean Mist', r: 0.85490196078431, g: 0.92549019607843, b: 0.93333333333333},
{name: 'Ice Ocean', r: 0.45490196078431, g: 0.72156862745098, b: 0.73333333333333},
{name: 'Abyss Green', r: 0.34901960784314, g: 0.56862745098039, b: 0.55686274509804},
{name: 'Bronze', r: 0.28627450980392, g: 0.43921568627451, b: 0.41960784313725},
{name: 'Gray Sky', r: 0.72941176470588, g: 0.75686274509804, b: 0.72549019607843},
{name: 'Green Gray', r: 0.72941176470588, g: 0.75686274509804, b: 0.72549019607843},
{name: 'Bush', r: 0.50588235294118, g: 0.63529411764706, b: 0.56862745098039},
{name: 'Flagstone Blue', r: 0.43137254901961, g: 0.6078431372549, b: 0.52941176470588},
{name: 'Mauve Shadow', r: 0.87843137254902, g: 0.86274509803922, b: 0.92941176470588},
{name: 'Iridescent Mauve', r: 0.91764705882353, g: 0.90588235294118, b: 0.94901960784314},
{name: 'Pale Thistle', r: 0.91764705882353, g: 0.90588235294118, b: 0.94901960784314},
{name: 'Viola', r: 0.76862745098039, g: 0.78823529411765, b: 0.90196078431373},
{name: 'Prune', r: 0.66666666666667, g: 0.72156862745098, b: 0.85882352941176},
{name: 'Blue Berry', r: 0.48627450980392, g: 0.5921568627451, b: 0.8078431372549},
{name: 'Blue Violet', r: 0.91764705882353, g: 0.90588235294118, b: 0.94901960784314},
{name: 'Soft Violet', r: 0.83137254901961, g: 0.82352941176471, b: 0.90980392156863},
{name: 'Hydrangea Blue', r: 0.51764705882353, g: 0.56862745098039, b: 0.7843137254902},
{name: 'Deep Reddish Blue', r: 0.43137254901961, g: 0.51764705882353, b: 0.74117647058824},
{name: 'Dull Lavender', r: 0.81176470588235, g: 0.85882352941176, b: 0.94509803921569},
{name: 'Grayish Lavender', r: 0.69411764705882, g: 0.75294117647059, b: 0.86666666666667},
{name: 'Grayish Violet', r: 0.50588235294118, g: 0.51764705882353, b: 0.65490196078431},
{name: 'Slate', r: 0.21960784313725, g: 0.27058823529412, b: 0.34509803921569},
{name: 'Pale Lavender', r: 0.91764705882353, g: 0.90588235294118, b: 0.94901960784314},
{name: 'Bluebell', r: 0.62352941176471, g: 0.65490196078431, b: 0.73725490196078},
{name: 'Cool Gray No.0', r: 0.87843137254902, g: 0.90588235294118, b: 0.92941176470588},
{name: 'Cool Gray No.00', r: 0.87843137254902, g: 0.90588235294118, b: 0.92941176470588},
{name: 'Cool Gray No.1', r: 0.85490196078431, g: 0.89019607843137, b: 0.90980392156863},
{name: 'Cool Gray No.10', r: 0.12549019607843, g: 0.16862745098039, b: 0.1921568627451},
{name: 'Cool Gray No.2', r: 0.8, g: 0.84313725490196, b: 0.86666666666667},
{name: 'Cool Gray No.3', r: 0.75686274509804, g: 0.8, b: 0.82352941176471},
{name: 'Cool Gray No.4', r: 0.57254901960784, g: 0.62745098039216, b: 0.67058823529412},
{name: 'Cool Gray No.5', r: 0.57254901960784, g: 0.62745098039216, b: 0.67058823529412},
{name: 'Cool Gray No.6', r: 0.38823529411765, g: 0.43921568627451, b: 0.47450980392157},
{name: 'Cool Gray No.7', r: 0.38823529411765, g: 0.43921568627451, b: 0.47450980392157},
{name: 'Cool Gray No.8', r: 0.32549019607843, g: 0.36470588235294, b: 0.4},
{name: 'Cool Gray No.9', r: 0.23529411764706, g: 0.27843137254902, b: 0.30196078431373},
{name: 'Skin White', r: 0.9921568627451, g: 0.95294117647059, b: 0.91764705882353},
{name: 'Pale Fruit Pink', r: 0.99607843137255, g: 0.96078431372549, b: 0.93333333333333},
{name: 'Floral White', r: 1, g: 0.98039215686275, b: 0.95686274509804},
{name: 'Pink Flamingo', r: 1, g: 0.93333333333333, b: 0.89411764705882},
{name: 'Fruit Pink', r: 0.99607843137255, g: 0.92549019607843, b: 0.87843137254902},
{name: 'Lipstick Natural', r: 0.89411764705882, g: 0.73725490196078, b: 0.76862745098039},
{name: 'Light Mahogany', r: 0.8, g: 0.50588235294118, b: 0.4156862745098},
{name: 'Brown', r: 0.7921568627451, g: 0.39607843137255, b: 0.32549019607843},
{name: 'Burnt Sienna', r: 0.85098039215686, g: 0.4156862745098, b: 0.30980392156863},
{name: 'Bareley Beige', r: 0.99607843137255, g: 0.91372549019608, b: 0.83921568627451},
{name: 'Light Suntan', r: 0.91372549019608, g: 0.77254901960784, b: 0.68627450980392},
{name: 'Dark Suntan', r: 0.9843137254902, g: 0.73333333333333, b: 0.55294117647059},
{name: 'Reddish Brass', r: 0.72156862745098, g: 0.37254901960784, b: 0.34117647058824},
{name: 'Copper', r: 0.53333333333333, g: 0.32549019607843, b: 0.30196078431373},
{name: 'Redwood', r: 0.76862745098039, g: 0.32156862745098, b: 0.21960784313725},
{name: 'Baby Skin Pink', r: 0.9921568627451, g: 0.88627450980392, b: 0.78039215686275},
{name: 'Hazelnut', r: 0.92549019607843, g: 0.7921568627451, b: 0.69411764705882},
{name: 'Caribe Cocoa', r: 0.82352941176471, g: 0.64313725490196, b: 0.50980392156863},
{name: 'Africano', r: 0.6, g: 0.46274509803922, b: 0.38823529411765},
{name: 'Burnt Umber', r: 0.53333333333333, g: 0.27450980392157, b: 0.21176470588235},
{name: 'Bisque', r: 0.96862745098039, g: 0.94117647058824, b: 0.83921568627451},
{name: 'Brick Beige', r: 0.94901960784314, g: 0.90196078431373, b: 0.8078431372549},
{name: 'Sand', r: 0.95294117647059, g: 0.82352941176471, b: 0.69411764705882},
{name: 'Orientale', r: 0.94117647058824, g: 0.7921568627451, b: 0.65098039215686},
{name: 'Chamois', r: 0.90196078431373, g: 0.76470588235294, b: 0.63921568627451},
{name: 'Sepia', r: 0.8, g: 0.56862745098039, b: 0.34901960784314},
{name: 'Leather', r: 0.77254901960784, g: 0.45490196078431, b: 0.24705882352941},
{name: 'Brick White', r: 0.94901960784314, g: 0.90980392156863, b: 0.86274509803922},
{name: 'Pearl White', r: 0.99607843137255, g: 0.94509803921569, b: 0.88235294117647},
{name: 'Sand White', r: 0.95294117647059, g: 0.91764705882353, b: 0.85098039215686},
{name: 'Dull Ivory', r: 0.90980392156863, g: 0.85490196078431, b: 0.74117647058824},
{name: 'Clay', r: 0.54117647058824, g: 0.43137254901961, b: 0.34901960784314},
{name: 'Dark Brown', r: 0.54117647058824, g: 0.43137254901961, b: 0.34901960784314},
{name: 'Dark Bark', r: 0.38823529411765, g: 0.29803921568627, b: 0.23529411764706},
{name: 'Egg Shell', r: 0.95686274509804, g: 0.92156862745098, b: 0.94117647058824},
{name: 'Milky White', r: 0.99607843137255, g: 0.92549019607843, b: 0.83921568627451},
{name: 'Raw Silk', r: 0.94509803921569, g: 0.87450980392157, b: 0.72549019607843},
{name: 'Light Camel', r: 0.94509803921569, g: 0.87450980392157, b: 0.72549019607843},
{name: 'Light Walnut', r: 0.69411764705882, g: 0.52156862745098, b: 0.34509803921569},
{name: 'Walnut', r: 0.60392156862745, g: 0.49803921568627, b: 0.42352941176471},
{name: 'Ash Rose', r: 0.93725490196078, g: 0.91764705882353, b: 0.90196078431373},
{name: 'Champagne', r: 0.63137254901961, g: 0.51764705882353, b: 0.48627450980392},
{name: 'Cocoa Brown', r: 0.63137254901961, g: 0.51764705882353, b: 0.48627450980392},
{name: 'Maroon', r: 0.49803921568627, g: 0.37647058823529, b: 0.30588235294118},
{name: 'Cashew', r: 0.29019607843137, g: 0.17254901960784, b: 0.13333333333333},
{name: 'Ivory', r: 0.94117647058824, g: 0.90196078431373, b: 0.76078431372549},
{name: 'Khaki', r: 0.68235294117647, g: 0.62352941176471, b: 0.50196078431373},
{name: 'Fig', r: 0.43529411764706, g: 0.37647058823529, b: 0.30196078431373},
{name: 'Pecan', r: 0.35294117647059, g: 0.28627450980392, b: 0.22352941176471},
{name: 'Tea Rose', r: 0.99607843137255, g: 0.82352941176471, b: 0.72549019607843},
{name: 'Flesh Pink', r: 0.98823529411765, g: 0.73725490196078, b: 0.49411764705882},
{name: 'Deep Orange', r: 0.70588235294118, g: 0.37647058823529, b: 0.20392156862745},
{name: 'Baked Clay', r: 0.70588235294118, g: 0.37647058823529, b: 0.20392156862745},
{name: 'Fluorescent Dull Blue', r: 0.019607843137255, g: 0.56078431372549, b: 0.8156862745098},
{name: 'Fluorescent Dull Blue Green', r: 0.3843137254902, g: 0.79607843137255, b: 0.90980392156863},
{name: 'Fluorescent Pink', r: 0.96078431372549, g: 0.63921568627451, b: 0.78039215686275},
{name: 'Fluorescent Dull Violet', r: 0.49803921568627, g: 0.45490196078431, b: 0.71372549019608},
{name: 'Fluorescent Yellow Orange', r: 1, g: 0.96470588235294, b: 0.5921568627451},
{name: 'Fluorescent Yellow', r: 0.61960784313725, g: 0.80392156862745, b: 0.26274509803922},
{name: 'Fluorescent Dull Yellow Green', r: 0.61960784313725, g: 0.80392156862745, b: 0.26274509803922},
{name: 'Fluorescent Orange', r: 0.99607843137255, g: 0.8, b: 0.6},
{name: 'Jade Green', r: 0.89019607843137, g: 0.94901960784314, b: 0.92941176470588},
{name: 'Pale Green', r: 0.91764705882353, g: 0.96078431372549, b: 0.92941176470588},
{name: 'Crystal Opal', r: 0.94509803921569, g: 0.96862745098039, b: 0.95294117647059},
{name: 'Spectrum Green', r: 0.81176470588235, g: 0.90980392156863, b: 0.82745098039216},
{name: 'Meadow Green', r: 0.71372549019608, g: 0.85490196078431, b: 0.61176470588235},
{name: 'Emerald Green', r: 0.41176470588235, g: 0.75294117647059, b: 0.48235294117647},
{name: 'Nile Green', r: 0.48235294117647, g: 0.77254901960784, b: 0.46274509803922},
{name: 'Veronese Green', r: 0.47843137254902, g: 0.76862745098039, b: 0.39607843137255},
{name: 'Sea Green', r: 0.82352941176471, g: 0.90980392156863, b: 0.76862745098039},
{name: 'Apple Green', r: 0.5921568627451, g: 0.81176470588235, b: 0.56470588235294},
{name: 'Malachite', r: 0.37647058823529, g: 0.75686274509804, b: 0.59607843137255},
{name: 'Forest Green', r: 0.07843137254902, g: 0.70196078431373, b: 0.49019607843137},
{name: 'Bright Parrot Green', r: 0.17647058823529, g: 0.72549019607843, b: 0.54117647058824},
{name: 'Wax White', r: 0.92941176470588, g: 0.96470588235294, b: 0.85882352941176},
{name: 'Lime Green', r: 0.76862745098039, g: 0.89411764705882, b: 0.80392156862745},
{name: 'Willow', r: 0.76470588235294, g: 0.87843137254902, b: 0.70588235294118},
{name: 'Ocean Green', r: 0.066666666666667, g: 0.58039215686275, b: 0.3843137254902},
{name: 'Pine Tree Green', r: 0.098039215686275, g: 0.48627450980392, b: 0.36470588235294},
{name: 'Dim Green', r: 0.89411764705882, g: 0.94509803921569, b: 0.87450980392157},
{name: 'Pistachio', r: 0.84313725490196, g: 0.90588235294118, b: 0.65882352941176},
{name: 'Mistletoe', r: 0.34117647058824, g: 0.61960784313725, b: 0.47058823529412},
{name: 'Spring Dim Green', r: 0.8, g: 0.85490196078431, b: 0.72549019607843},
{name: 'Verdigris', r: 0.6156862745098, g: 0.76470588235294, b: 0.66666666666667},
{name: 'Grayish Olive', r: 0.59607843137255, g: 0.65490196078431, b: 0.52549019607843},
{name: 'Olive', r: 0.37254901960784, g: 0.49411764705882, b: 0.22745098039216},
{name: 'Neutral Gray No.0', r: 0.92549019607843, g: 0.93333333333333, b: 0.92941176470588},
{name: 'Neutral Gray No.1', r: 0.88627450980392, g: 0.89019607843137, b: 0.89803921568627},
{name: 'Neutral Gray No.10', r: 0.1921568627451, g: 0.1843137254902, b: 0.18823529411765},
{name: 'Neutral Gray No.2', r: 0.85490196078431, g: 0.85882352941176, b: 0.86666666666667},
{name: 'Neutral Gray No.3', r: 0.81960784313725, g: 0.82352941176471, b: 0.83137254901961},
{name: 'Neutral Gray No.4', r: 0.73725490196078, g: 0.74117647058824, b: 0.75686274509804},
{name: 'Neutral Gray No.5', r: 0.65882352941176, g: 0.66274509803922, b: 0.67843137254902},
{name: 'Neutral Gray No.6', r: 0.58039215686275, g: 0.5843137254902, b: 0.6},
{name: 'Neutral Gray No.7', r: 0.46666666666667, g: 0.47058823529412, b: 0.48627450980392},
{name: 'Neutral Gray No.8', r: 0.38823529411765, g: 0.3921568627451, b: 0.4},
{name: 'Neutral Gray No.9', r: 0.29803921568627, g: 0.30196078431373, b: 0.30980392156863},
{name: 'Pinkish White', r: 0.99607843137255, g: 0.91764705882353, b: 0.88235294117647},
{name: 'Cherry White', r: 0.99607843137255, g: 0.94117647058824, b: 0.90588235294118},
{name: 'Pink Beryl', r: 0.99607843137255, g: 0.95294117647059, b: 0.93725490196078},
{name: 'Pinkish Vanilla', r: 0.9921568627451, g: 0.87843137254902, b: 0.84705882352941},
{name: 'Flesh', r: 0.9921568627451, g: 0.82745098039216, b: 0.78039215686275},
{name: 'Salmon Red', r: 0.96470588235294, g: 0.56862745098039, b: 0.48235294117647},
{name: 'Vermilion', r: 0.94901960784314, g: 0.40392156862745, b: 0.32941176470588},
{name: 'Pale Cherry Pink', r: 0.9921568627451, g: 0.88235294117647, b: 0.83529411764706},
{name: 'Light Tea Rose', r: 0.98823529411765, g: 0.82745098039216, b: 0.75686274509804},
{name: 'Light Rouse', r: 0.96078431372549, g: 0.6078431372549, b: 0.57254901960784},
{name: 'Lipstick Orange', r: 0.95686274509804, g: 0.51764705882353, b: 0.42352941176471},
{name: 'Blush', r: 0.98823529411765, g: 0.84313725490196, b: 0.81176470588235},
{name: 'Sardonyx', r: 0.98039215686275, g: 0.75686274509804, b: 0.71372549019608},
{name: 'Light Prawn', r: 0.97254901960784, g: 0.71764705882353, b: 0.69411764705882},
{name: 'Prawn', r: 0.94901960784314, g: 0.45882352941176, b: 0.47450980392157},
{name: 'Cadmium Red', r: 0.94509803921569, g: 0.31372549019608, b: 0.3843137254902},
{name: 'Lipstick Red', r: 0.92941176470588, g: 0.090196078431373, b: 0.29411764705882},
{name: 'Pale Yellowish Pink', r: 0.98823529411765, g: 0.89019607843137, b: 0.87450980392157},
{name: 'Peach', r: 0.98039215686275, g: 0.75686274509804, b: 0.72941176470588},
{name: 'Coral', r: 0.94901960784314, g: 0.44313725490196, b: 0.52156862745098},
{name: 'Carmine', r: 0.90980392156863, g: 0.42352941176471, b: 0.45490196078431},
{name: 'Garnet', r: 0.79607843137255, g: 0.28235294117647, b: 0.47843137254902},
{name: 'Bougainvillaea', r: 0.93333333333333, g: 0.51764705882353, b: 0.55686274509804},
{name: 'Strong Red', r: 0.87843137254902, g: 0.30196078431373, b: 0.41176470588235},
{name: 'Currant', r: 0.82352941176471, g: 0.48627450980392, b: 0.5843137254902},
{name: 'Cardinal', r: 0.71764705882353, g: 0.30980392156863, b: 0.43921568627451},
{name: 'Rose Pink', r: 0.94509803921569, g: 0.7843137254902, b: 0.83921568627451},
{name: 'Rose Mist', r: 0.94509803921569, g: 0.61176470588235, b: 0.72549019607843},
{name: 'Rose Red', r: 0.82745098039216, g: 0.4156862745098, b: 0.57647058823529},
{name: 'Dark Red', r: 0.49019607843137, g: 0.16862745098039, b: 0.25882352941176},
{name: 'Water Lily', r: 0.94509803921569, g: 0.85490196078431, b: 0.91764705882353},
{name: 'Pale Purple', r: 0.95686274509804, g: 0.88627450980392, b: 0.93333333333333},
{name: 'Evening Primrose', r: 0.94901960784314, g: 0.91764705882353, b: 0.96078431372549},
{name: 'Sugared Almond Pink', r: 0.98039215686275, g: 0.83529411764706, b: 0.90196078431373},
{name: 'Shock Pink', r: 0.96470588235294, g: 0.63921568627451, b: 0.74901960784314},
{name: 'Cerise', r: 0.95294117647059, g: 0.52549019607843, b: 0.68627450980392},
{name: 'Fuchsia', r: 0.88235294117647, g: 0.44313725490196, b: 0.67450980392157},
{name: 'Pale Pink', r: 0.9921568627451, g: 0.92549019607843, b: 0.95686274509804},
{name: 'Pink', r: 0.9843137254902, g: 0.83921568627451, b: 0.86666666666667},
{name: 'Tender Pink', r: 0.97647058823529, g: 0.78823529411765, b: 0.84313725490196},
{name: 'Begonia Pink', r: 0.95686274509804, g: 0.5843137254902, b: 0.71764705882353},
{name: 'Deep Magenta', r: 0.85882352941176, g: 0.49411764705882, b: 0.70196078431373},
{name: 'Red Violet', r: 0.82352941176471, g: 0.4078431372549, b: 0.66666666666667},
{name: 'Light Pink', r: 0.9921568627451, g: 0.90980392156863, b: 0.90588235294118},
{name: 'Pure Pink', r: 0.97254901960784, g: 0.72941176470588, b: 0.78823529411765},
{name: 'Dog Rose Flower', r: 0.95686274509804, g: 0.57647058823529, b: 0.74509803921569},
{name: 'Crimson', r: 0.93725490196078, g: 0.28235294117647, b: 0.50196078431373},
{name: 'Shadow Pink', r: 0.98039215686275, g: 0.82745098039216, b: 0.8078431372549},
{name: 'Dark Pink', r: 0.97647058823529, g: 0.68627450980392, b: 0.68235294117647},
{name: 'Salmon Pink', r: 0.97254901960784, g: 0.73333333333333, b: 0.71372549019608},
{name: 'Cotton Candy', r: 0.97647058823529, g: 0.7921568627451, b: 0.87058823529412},
{name: 'Hollyhock', r: 0.91372549019608, g: 0.64705882352941, b: 0.7921568627451},
{name: 'Begonia', r: 0.8156862745098, g: 0.6156862745098, b: 0.68235294117647},
{name: 'Raspberry', r: 0.72156862745098, g: 0.4156862745098, b: 0.51764705882353},
{name: 'Peony', r: 0.54509803921569, g: 0.34117647058824, b: 0.43137254901961},
{name: 'Garyish Cherry', r: 0.90196078431373, g: 0.83137254901961, b: 0.88627450980392},
{name: 'Smokey Purple', r: 0.90588235294118, g: 0.71372549019608, b: 0.8},
{name: 'Baby Blossoms', r: 0.71372549019608, g: 0.51764705882353, b: 0.63137254901961},
{name: 'Argyle Purple', r: 0.35294117647059, g: 0.28235294117647, b: 0.34509803921569},
{name: 'Toner Gray No.0', r: 0.92549019607843, g: 0.93333333333333, b: 0.92941176470588},
{name: 'Toner Gray No.1', r: 0.91764705882353, g: 0.91764705882353, b: 0.90980392156863},
{name: 'Toner Gray No.10', r: 0.19607843137255, g: 0.18039215686275, b: 0.17647058823529},
{name: 'Toner Gray No.2', r: 0.87843137254902, g: 0.87843137254902, b: 0.87058823529412},
{name: 'Toner Gray No.3', r: 0.81960784313725, g: 0.82352941176471, b: 0.8},
{name: 'Toner Gray No.4', r: 0.73725490196078, g: 0.73333333333333, b: 0.72549019607843},
{name: 'Toner Gray No.5', r: 0.65882352941176, g: 0.65490196078431, b: 0.63921568627451},
{name: 'Toner Gray No.6', r: 0.58039215686275, g: 0.5843137254902, b: 0.56470588235294},
{name: 'Toner Gray No.7', r: 0.46666666666667, g: 0.46274509803922, b: 0.45490196078431},
{name: 'Toner Gray No.8', r: 0.38823529411765, g: 0.3921568627451, b: 0.37254901960784},
{name: 'Toner Gray No.9', r: 0.29803921568627, g: 0.29411764705882, b: 0.28627450980392},
{name: 'Pale Heath', r: 0.91372549019608, g: 0.89803921568627, b: 0.95294117647059},
{name: 'Rose Quartz', r: 0.94117647058824, g: 0.92941176470588, b: 0.96470588235294},
{name: 'Heath', r: 0.89411764705882, g: 0.75686274509804, b: 0.85098039215686},
{name: 'Lilac', r: 0.90196078431373, g: 0.66666666666667, b: 0.8078431372549},
{name: 'Marigold', r: 0.88627450980392, g: 0.65098039215686, b: 0.7921568627451},
{name: 'Lavender', r: 0.8078431372549, g: 0.5843137254902, b: 0.76078431372549},
{name: 'Violet', r: 0.52941176470588, g: 0.32941176470588, b: 0.63137254901961},
{name: 'Pale Lilac', r: 0.93333333333333, g: 0.84313725490196, b: 0.91372549019608},
{name: 'Mallow', r: 0.82745098039216, g: 0.65098039215686, b: 0.80392156862745},
{name: 'Amethyst', r: 0.62745098039216, g: 0.57254901960784, b: 0.78039215686275},
{name: 'Wisteria', r: 0.88627450980392, g: 0.87843137254902, b: 0.92941176470588},
{name: 'Ash Lavender', r: 0.69803921568627, g: 0.69411764705882, b: 0.8156862745098},
{name: 'Pale Blackberry', r: 0.52156862745098, g: 0.49803921568627, b: 0.67843137254902},
{name: 'Eggplant', r: 0.41960784313725, g: 0.4, b: 0.55686274509804},
{name: 'Pale Grape', r: 0.90980392156863, g: 0.76862745098039, b: 0.8156862745098},
{name: 'Early Grape', r: 0.89803921568627, g: 0.75686274509804, b: 0.85882352941176},
{name: 'Light Grape', r: 0.71764705882353, g: 0.48627450980392, b: 0.65882352941176},
{name: 'Aubergine', r: 0.32156862745098, g: 0.26274509803922, b: 0.34509803921569},
{name: 'Warm Gray No.0', r: 0.92549019607843, g: 0.92549019607843, b: 0.89411764705882},
{name: 'Warm Gray No.00', r: 0.95294117647059, g: 0.95294117647059, b: 0.92156862745098},
{name: 'Warm Gray No.1', r: 0.90588235294118, g: 0.90588235294118, b: 0.87450980392157},
{name: 'Warm Gray No.10', r: 0.18823529411765, g: 0.1843137254902, b: 0.16862745098039},
{name: 'Warm Gray No.2', r: 0.86666666666667, g: 0.86666666666667, b: 0.83529411764706},
{name: 'Warm Gray No.3', r: 0.82352941176471, g: 0.82352941176471, b: 0.7921568627451},
{name: 'Warm Gray No.4', r: 0.73725490196078, g: 0.74117647058824, b: 0.71764705882353},
{name: 'Warm Gray No.5', r: 0.65882352941176, g: 0.66274509803922, b: 0.64313725490196},
{name: 'Warm Gray No.6', r: 0.58039215686275, g: 0.5843137254902, b: 0.56078431372549},
{name: 'Warm Gray No.7', r: 0.46666666666667, g: 0.47058823529412, b: 0.45098039215686},
{name: 'Warm Gray No.8', r: 0.38823529411765, g: 0.3921568627451, b: 0.37254901960784},
{name: 'Warm Gray No.9', r: 0.29803921568627, g: 0.30196078431373, b: 0.28235294117647},
{name: 'Barium Yellow', r: 0.99607843137255, g: 0.9921568627451, b: 0.87450980392157},
{name: 'Pale Lemon', r: 1, g: 0.98823529411765, b: 0.91372549019608},
{name: 'Yellow Fluorite', r: 0.99607843137255, g: 0.99607843137255, b: 0.95686274509804},
{name: 'Canary Yellow', r: 0.96470588235294, g: 0.95294117647059, b: 0.58823529411765},
{name: 'Acacia', r: 0.92941176470588, g: 0.89803921568627, b: 0.33725490196078},
{name: 'Yellow', r: 0.99607843137255, g: 0.96078431372549, b: 0.42352941176471},
{name: 'Acid Yellow', r: 0.99607843137255, g: 0.94901960784314, b: 0},
{name: 'Pale Yellow', r: 1, g: 0.9843137254902, b: 0.8},
{name: 'Lemon Yellow', r: 0.9843137254902, g: 0.96862745098039, b: 0.68235294117647},
{name: 'Cadmium Yellow', r: 0.99607843137255, g: 0.91372549019608, b: 0.42352941176471},
{name: 'Golden Yellow', r: 1, g: 0.89411764705882, b: 0.33333333333333},
{name: 'Lightning Yellow', r: 0.99607843137255, g: 0.92941176470588, b: 0.33333333333333},
{name: 'Napoli Yellow', r: 1, g: 0.91372549019608, b: 0.24313725490196},
{name: 'Buttercup Yellow', r: 1, g: 0.93333333333333, b: 0.76078431372549},
{name: 'Yellowish Beige', r: 0.9843137254902, g: 0.89019607843137, b: 0.70196078431373},
{name: 'Mustard', r: 0.94117647058824, g: 0.86666666666667, b: 0.40392156862745},
{name: 'Lionet Gold', r: 0.7921568627451, g: 0.65882352941176, b: 0.41176470588235},
{name: 'Cashmere', r: 0.97647058823529, g: 0.87058823529412, b: 0.75294117647059},
{name: 'Maize', r: 1, g: 0.84705882352941, b: 0.47450980392157},
{name: 'Honey', r: 1, g: 0.82352941176471, b: 0.45490196078431},
{name: 'Mimosa Yellow', r: 0.90196078431373, g: 0.90196078431373, b: 0.61960784313725},
{name: 'Lily White', r: 0.94901960784314, g: 0.96862745098039, b: 0.87843137254902},
{name: 'Green Bice', r: 0.88627450980392, g: 0.92156862745098, b: 0.69803921568627},
{name: 'Yellow Green', r: 0.87058823529412, g: 0.91764705882353, b: 0.66666666666667},
{name: 'Salad', r: 0.83921568627451, g: 0.89803921568627, b: 0.57254901960784},
{name: 'Yellowish Green', r: 0.76862745098039, g: 0.87450980392157, b: 0.57254901960784},
{name: 'Acid Green', r: 0.64705882352941, g: 0.81176470588235, b: 0.30980392156863},
{name: 'Lettuce Green', r: 0.50980392156863, g: 0.77254901960784, b: 0.4},
{name: 'Mignonette', r: 0.89803921568627, g: 0.94117647058824, b: 0.8156862745098},
{name: 'Chartreuse', r: 0.83137254901961, g: 0.89803921568627, b: 0.62352941176471},
{name: 'Grass Green', r: 0.44705882352941, g: 0.75686274509804, b: 0.33725490196078},
{name: 'Anise', r: 0.96862745098039, g: 0.96470588235294, b: 0.74509803921569},
{name: 'New Leaf', r: 0.90196078431373, g: 0.92156862745098, b: 0.56078431372549},
{name: 'Celadon Green', r: 0.8156862745098, g: 0.88235294117647, b: 0.48235294117647},
{name: 'Pale Cobalt Green', r: 0.83529411764706, g: 0.92156862745098, b: 0.83137254901961},
{name: 'Cobalt Green', r: 0.70588235294118, g: 0.86274509803922, b: 0.71764705882353},
{name: 'Pale Moss', r: 0.83921568627451, g: 0.91372549019608, b: 0.83921568627451},
{name: 'Pea Green', r: 0.62745098039216, g: 0.7921568627451, b: 0.63529411764706},
{name: 'Moss', r: 0.50588235294118, g: 0.74901960784314, b: 0.54901960784314},
{name: 'Putty', r: 0.85490196078431, g: 0.84313725490196, b: 0.68235294117647},
{name: 'Grayish Yellow', r: 0.82352941176471, g: 0.82352941176471, b: 0.61176470588235},
{name: 'Pale Olive', r: 0.79607843137255, g: 0.77647058823529, b: 0.36862745098039},
{name: 'Spanish Olive', r: 0.5843137254902, g: 0.56078431372549, b: 0.011764705882353},
{name: 'Marine Green', r: 0.30588235294118, g: 0.4156862745098, b: 0.082352941176471},
{name: 'Powder Pink', r: 0.99607843137255, g: 0.83921568627451, b: 0.74117647058824},
{name: 'Silk', r: 0.99607843137255, g: 0.92549019607843, b: 0.84705882352941},
{name: 'Pale Chiffon', r: 1, g: 0.95294117647059, b: 0.89803921568627},
{name: 'Peach Puff', r: 0.99607843137255, g: 0.85490196078431, b: 0.76078431372549},
{name: 'Light Orange', r: 0.98823529411765, g: 0.86274509803922, b: 0.77254901960784},
{name: 'Chrome Orange', r: 0.99607843137255, g: 0.76470588235294, b: 0.41176470588235},
{name: 'Cadmium Orange', r: 0.94901960784314, g: 0.43529411764706, b: 0.22352941176471},
{name: 'Chinese Orange', r: 0.94509803921569, g: 0.33333333333333, b: 0.14117647058824},
{name: 'Loquat', r: 1, g: 0.88627450980392, b: 0.65098039215686},
{name: 'Caramel', r: 0.99607843137255, g: 0.7843137254902, b: 0.30588235294118},
{name: 'Pumpkin Yellow', r: 0.9843137254902, g: 0.72156862745098, b: 0.51764705882353},
{name: 'Apricot', r: 0.99607843137255, g: 0.71764705882353, b: 0.16078431372549},
{name: 'Sanguine', r: 0.94901960784314, g: 0.41960784313725, b: 0.23529411764706},
{name: 'Yellowish Shade', r: 1, g: 0.88235294117647, b: 0.74901960784314},
{name: 'Cream', r: 0.96078431372549, g: 0.86666666666667, b: 0.69411764705882},
{name: 'Yellow Ochre', r: 0.92549019607843, g: 0.81176470588235, b: 0.54509803921569},
{name: 'Pale Sepia', r: 0.94117647058824, g: 0.81176470588235, b: 0.3921568627451},
{name: 'Tuscan Orange', r: 0.83529411764706, g: 0.4, b: 0.21960784313725},
{name: 'Macadamia Nut', r: 0.99607843137255, g: 0.94901960784314, b: 0.85490196078431},
{name: 'Light Reddish Yellow', r: 1, g: 0.87058823529412, b: 0.65882352941176},
{name: 'Yellowish Skin Pink', r: 0.9921568627451, g: 0.85490196078431, b: 0.76862745098039},
{name: 'Atoll', r: 0.98039215686275, g: 0.68235294117647, b: 0.37647058823529},
{name: 'Orange', r: 0.95294117647059, g: 0.43921568627451, b: 0.13333333333333},
{name: 'Mellow Peach', r: 0.9921568627451, g: 0.77647058823529, b: 0.55294117647059}
];
});

View File

@ -0,0 +1,125 @@
jQuery(function($) {
$.colorpicker.swatchesNames['crayola'] = 'Crayola';
$.colorpicker.swatches['crayola'] = [
{name: 'Almond', r: 0.937254901960784, g: 0.858823529411765, b: 0.772549019607843},
{name: 'Antique Brass', r: 0.803921568627451, g: 0.584313725490196, b: 0.458823529411765},
{name: 'Apricot', r: 0.992156862745098, g: 0.850980392156863, b: 0.709803921568627},
{name: 'Aquamarine', r: 0.470588235294118, g: 0.858823529411765, b: 0.886274509803922},
{name: 'Asparagus', r: 0.529411764705882, g: 0.662745098039216, b: 0.419607843137255},
{name: 'Atomic Tangerine', r: 1, g: 0.643137254901961, b: 0.454901960784314},
{name: 'Banana Mania', r: 0.980392156862745, g: 0.905882352941176, b: 0.709803921568627},
{name: 'Beaver', r: 0.623529411764706, g: 0.505882352941176, b: 0.43921568627451},
{name: 'Bittersweet', r: 0.992156862745098, g: 0.486274509803922, b: 0.431372549019608},
{name: 'Black', r: 0.137254901960784, g: 0.137254901960784, b: 0.137254901960784},
{name: 'Blue', r: 0.12156862745098, g: 0.458823529411765, b: 0.996078431372549},
{name: 'Blue Bell', r: 0.67843137254902, g: 0.67843137254902, b: 0.83921568627451},
{name: 'Blue Green', r: 0.0980392156862745, g: 0.619607843137255, b: 0.741176470588235},
{name: 'Blue Violet', r: 0.450980392156863, g: 0.4, b: 0.741176470588235},
{name: 'Blush', r: 0.870588235294118, g: 0.364705882352941, b: 0.513725490196078},
{name: 'Brick Red', r: 0.796078431372549, g: 0.254901960784314, b: 0.329411764705882},
{name: 'Brown', r: 0.705882352941177, g: 0.403921568627451, b: 0.301960784313725},
{name: 'Burnt Orange', r: 1, g: 0.498039215686275, b: 0.286274509803922},
{name: 'Burnt Sienna', r: 0.917647058823529, g: 0.494117647058824, b: 0.364705882352941},
{name: 'Cadet Blue', r: 0.690196078431373, g: 0.717647058823529, b: 0.776470588235294},
{name: 'Canary', r: 1, g: 1, b: 0.6},
{name: 'Caribbean Green', r: 0.109803921568627, g: 0.827450980392157, b: 0.635294117647059},
{name: 'Carnation Pink', r: 1, g: 0.666666666666667, b: 0.8},
{name: 'Cerise', r: 0.866666666666667, g: 0.266666666666667, b: 0.572549019607843},
{name: 'Cerulean', r: 0.113725490196078, g: 0.674509803921569, b: 0.83921568627451},
{name: 'Chestnut', r: 0.737254901960784, g: 0.364705882352941, b: 0.345098039215686},
{name: 'Copper', r: 0.866666666666667, g: 0.580392156862745, b: 0.458823529411765},
{name: 'Cornflower', r: 0.603921568627451, g: 0.807843137254902, b: 0.92156862745098},
{name: 'Cotton Candy', r: 1, g: 0.737254901960784, b: 0.850980392156863},
{name: 'Dandelion', r: 0.992156862745098, g: 0.858823529411765, b: 0.427450980392157},
{name: 'Denim', r: 0.168627450980392, g: 0.423529411764706, b: 0.768627450980392},
{name: 'Desert Sand', r: 0.937254901960784, g: 0.803921568627451, b: 0.72156862745098},
{name: 'Eggplant', r: 0.431372549019608, g: 0.317647058823529, b: 0.376470588235294},
{name: 'Electric Lime', r: 0.113725490196078, g: 0.976470588235294, b: 0.0784313725490196},
{name: 'Fern', r: 0.443137254901961, g: 0.737254901960784, b: 0.470588235294118},
{name: 'Forest Green', r: 0.427450980392157, g: 0.682352941176471, b: 0.505882352941176},
{name: 'Fuchsia', r: 0.764705882352941, g: 0.392156862745098, b: 0.772549019607843},
{name: 'Fuzzy Wuzzy Brown', r: 0.8, g: 0.4, b: 0.4},
{name: 'Gold', r: 0.905882352941176, g: 0.776470588235294, b: 0.592156862745098},
{name: 'Goldenrod', r: 0.988235294117647, g: 0.850980392156863, b: 0.458823529411765},
{name: 'Granny Smith Apple', r: 0.658823529411765, g: 0.894117647058824, b: 0.627450980392157},
{name: 'Gray', r: 0.584313725490196, g: 0.568627450980392, b: 0.549019607843137},
{name: 'Green', r: 0.109803921568627, g: 0.674509803921569, b: 0.470588235294118},
{name: 'Green Yellow', r: 0.941176470588235, g: 0.909803921568627, b: 0.568627450980392},
{name: 'Hot Magenta', r: 1, g: 0.113725490196078, b: 0.807843137254902},
{name: 'Inch Worm', r: 0.698039215686274, g: 0.925490196078431, b: 0.364705882352941},
{name: 'Indigo', r: 0.364705882352941, g: 0.462745098039216, b: 0.796078431372549},
{name: 'Jazzberry Jam', r: 0.792156862745098, g: 0.215686274509804, b: 0.403921568627451},
{name: 'Jungle Green', r: 0.231372549019608, g: 0.690196078431373, b: 0.56078431372549},
{name: 'Laser Lemon', r: 0.992156862745098, g: 0.988235294117647, b: 0.454901960784314},
{name: 'Lavender', r: 0.988235294117647, g: 0.705882352941177, b: 0.835294117647059},
{name: 'Macaroni and Cheese', r: 1, g: 0.741176470588235, b: 0.533333333333333},
{name: 'Magenta', r: 0.964705882352941, g: 0.392156862745098, b: 0.686274509803922},
{name: 'Mahogany', r: 0.803921568627451, g: 0.290196078431373, b: 0.290196078431373},
{name: 'Manatee', r: 0.592156862745098, g: 0.603921568627451, b: 0.666666666666667},
{name: 'Mango Tango', r: 1, g: 0.509803921568627, b: 0.262745098039216},
{name: 'Maroon', r: 0.784313725490196, g: 0.219607843137255, b: 0.352941176470588},
{name: 'Mauvelous', r: 0.937254901960784, g: 0.596078431372549, b: 0.666666666666667},
{name: 'Melon', r: 0.992156862745098, g: 0.737254901960784, b: 0.705882352941177},
{name: 'Midnight Blue', r: 0.101960784313725, g: 0.282352941176471, b: 0.462745098039216},
{name: 'Mountain Meadow', r: 0.188235294117647, g: 0.729411764705882, b: 0.56078431372549},
{name: 'Navy Blue', r: 0.0980392156862745, g: 0.454901960784314, b: 0.823529411764706},
{name: 'Neon Carrot', r: 1, g: 0.63921568627451, b: 0.262745098039216},
{name: 'Olive Green', r: 0.729411764705882, g: 0.72156862745098, b: 0.423529411764706},
{name: 'Orange', r: 1, g: 0.458823529411765, b: 0.219607843137255},
{name: 'Orchid', r: 0.901960784313726, g: 0.658823529411765, b: 0.843137254901961},
{name: 'Outer Space', r: 0.254901960784314, g: 0.290196078431373, b: 0.298039215686275},
{name: 'Outrageous Orange', r: 1, g: 0.431372549019608, b: 0.290196078431373},
{name: 'Pacific Blue', r: 0.109803921568627, g: 0.662745098039216, b: 0.788235294117647},
{name: 'Peach', r: 1, g: 0.811764705882353, b: 0.670588235294118},
{name: 'Periwinkle', r: 0.772549019607843, g: 0.815686274509804, b: 0.901960784313726},
{name: 'Piggy Pink', r: 0.992156862745098, g: 0.843137254901961, b: 0.894117647058824},
{name: 'Pine Green', r: 0.0823529411764706, g: 0.501960784313725, b: 0.470588235294118},
{name: 'Pink Flamingo', r: 0.988235294117647, g: 0.454901960784314, b: 0.992156862745098},
{name: 'Pink Sherbet', r: 0.968627450980392, g: 0.501960784313725, b: 0.631372549019608},
{name: 'Plum', r: 0.556862745098039, g: 0.270588235294118, b: 0.52156862745098},
{name: 'Purple Heart', r: 0.454901960784314, g: 0.258823529411765, b: 0.784313725490196},
{name: 'Purple Mountains Majesty', r: 0.615686274509804, g: 0.505882352941176, b: 0.729411764705882},
{name: 'Purple Pizzazz', r: 1, g: 0.113725490196078, b: 0.807843137254902},
{name: 'Radical Red', r: 1, g: 0.286274509803922, b: 0.423529411764706},
{name: 'Raw Sienna', r: 0.83921568627451, g: 0.541176470588235, b: 0.349019607843137},
{name: 'Razzle Dazzle Rose', r: 1, g: 0.282352941176471, b: 0.815686274509804},
{name: 'Razzmatazz', r: 0.890196078431372, g: 0.145098039215686, b: 0.419607843137255},
{name: 'Red', r: 0.933333333333333, g: 0.125490196078431, b: 0.301960784313725},
{name: 'Red Orange', r: 1, g: 0.325490196078431, b: 0.286274509803922},
{name: 'Red Violet', r: 0.752941176470588, g: 0.266666666666667, b: 0.56078431372549},
{name: 'Robin Egg Blue', r: 0.12156862745098, g: 0.807843137254902, b: 0.796078431372549},
{name: 'Royal Purple', r: 0.470588235294118, g: 0.317647058823529, b: 0.662745098039216},
{name: 'Salmon', r: 1, g: 0.607843137254902, b: 0.666666666666667},
{name: 'Scarlet', r: 0.988235294117647, g: 0.156862745098039, b: 0.27843137254902},
{name: 'Screamin Green', r: 0.462745098039216, g: 1, b: 0.47843137254902},
{name: 'Sea Green', r: 0.623529411764706, g: 0.886274509803922, b: 0.749019607843137},
{name: 'Sepia', r: 0.647058823529412, g: 0.411764705882353, b: 0.309803921568627},
{name: 'Shadow', r: 0.541176470588235, g: 0.474509803921569, b: 0.364705882352941},
{name: 'Shamrock', r: 0.270588235294118, g: 0.807843137254902, b: 0.635294117647059},
{name: 'Shocking Pink', r: 0.984313725490196, g: 0.494117647058824, b: 0.992156862745098},
{name: 'Silver', r: 0.803921568627451, g: 0.772549019607843, b: 0.76078431372549},
{name: 'Sky Blue', r: 0.501960784313725, g: 0.854901960784314, b: 0.92156862745098},
{name: 'Spring Green', r: 0.925490196078431, g: 0.917647058823529, b: 0.745098039215686},
{name: 'Sunglow', r: 1, g: 0.811764705882353, b: 0.282352941176471},
{name: 'Sunset Orange', r: 0.992156862745098, g: 0.368627450980392, b: 0.325490196078431},
{name: 'Tan', r: 0.980392156862745, g: 0.654901960784314, b: 0.423529411764706},
{name: 'Tickle Me Pink', r: 0.988235294117647, g: 0.537254901960784, b: 0.674509803921569},
{name: 'Timberwolf', r: 0.858823529411765, g: 0.843137254901961, b: 0.823529411764706},
{name: 'Tropical Rain Forest', r: 0.0901960784313725, g: 0.501960784313725, b: 0.427450980392157},
{name: 'Tumbleweed', r: 0.870588235294118, g: 0.666666666666667, b: 0.533333333333333},
{name: 'Turquoise Blue', r: 0.466666666666667, g: 0.866666666666667, b: 0.905882352941176},
{name: 'Unmellow Yellow', r: 0.992156862745098, g: 0.988235294117647, b: 0.454901960784314},
{name: 'Violet (Purple)', r: 0.572549019607843, g: 0.431372549019608, b: 0.682352941176471},
{name: 'Violet Red', r: 0.968627450980392, g: 0.325490196078431, b: 0.580392156862745},
{name: 'Vivid Tangerine', r: 1, g: 0.627450980392157, b: 0.537254901960784},
{name: 'Vivid Violet', r: 0.56078431372549, g: 0.313725490196078, b: 0.615686274509804},
{name: 'White', r: 0.929411764705882, g: 0.929411764705882, b: 0.929411764705882},
{name: 'Wild Blue Yonder', r: 0.635294117647059, g: 0.67843137254902, b: 0.815686274509804},
{name: 'Wild Strawberry', r: 1, g: 0.262745098039216, b: 0.643137254901961},
{name: 'Wild Watermelon', r: 0.988235294117647, g: 0.423529411764706, b: 0.52156862745098},
{name: 'Wisteria', r: 0.803921568627451, g: 0.643137254901961, b: 0.870588235294118},
{name: 'Yellow', r: 0.988235294117647, g: 0.909803921568627, b: 0.513725490196078},
{name: 'Yellow Green', r: 0.772549019607843, g: 0.890196078431372, b: 0.517647058823529},
{name: 'Yellow Orange', r: 1, g: 0.713725490196078, b: 0.325490196078431}
];
});

View File

@ -0,0 +1,579 @@
jQuery(function ($) {
$.colorpicker.swatchesNames['din6164'] = 'DIN 6164';
$.colorpicker.swatches['din6164'] = [
{name: 'TSD 1-1-1', r: 0.8, g: 0.78823529411765, b: 0.71372549019608},
{name: 'TSD 1-1-2', r: 0.69019607843137, g: 0.67843137254902, b: 0.63137254901961},
{name: 'TSD 1-1-3', r: 0.56470588235294, g: 0.55686274509804, b: 0.50196078431373},
{name: 'TSD 1-1-4', r: 0.47058823529412, g: 0.46274509803922, b: 0.41960784313725},
{name: 'TSD 1-1-5', r: 0.3843137254902, g: 0.38039215686275, b: 0.34509803921569},
{name: 'TSD 1-1-6', r: 0.33725490196078, g: 0.32941176470588, b: 0.29411764705882},
{name: 'TSD 1-1-7', r: 0.26274509803922, g: 0.25882352941176, b: 0.23529411764706},
{name: 'TSD 1-2-1', r: 0.82352941176471, g: 0.8, b: 0.65882352941176},
{name: 'TSD 1-2-2', r: 0.69019607843137, g: 0.67058823529412, b: 0.55294117647059},
{name: 'TSD 1-2-3', r: 0.56862745098039, g: 0.55686274509804, b: 0.45490196078431},
{name: 'TSD 1-2-4', r: 0.49803921568627, g: 0.47843137254902, b: 0.3843137254902},
{name: 'TSD 1-2-5', r: 0.4156862745098, g: 0.39607843137255, b: 0.32156862745098},
{name: 'TSD 1-2-6', r: 0.34117647058824, g: 0.32941176470588, b: 0.27058823529412},
{name: 'TSD 1-2-7', r: 0.25098039215686, g: 0.24313725490196, b: 0.20392156862745},
{name: 'TSD 1-3-1', r: 0.8, g: 0.77254901960784, b: 0.55294117647059},
{name: 'TSD 1-3-2', r: 0.69019607843137, g: 0.67450980392157, b: 0.47843137254902},
{name: 'TSD 1-3-3', r: 0.55686274509804, g: 0.54117647058824, b: 0.38823529411765},
{name: 'TSD 1-3-4', r: 0.49411764705882, g: 0.46274509803922, b: 0.32941176470588},
{name: 'TSD 1-3-5', r: 0.4, g: 0.38039215686275, b: 0.27450980392157},
{name: 'TSD 1-3-6', r: 0.33333333333333, g: 0.32156862745098, b: 0.23529411764706},
{name: 'TSD 1-4-1', r: 0.82745098039216, g: 0.78823529411765, b: 0.48627450980392},
{name: 'TSD 1-4-2', r: 0.68235294117647, g: 0.65882352941176, b: 0.40392156862745},
{name: 'TSD 1-4-3', r: 0.56862745098039, g: 0.54901960784314, b: 0.32941176470588},
{name: 'TSD 1-4-4', r: 0.48627450980392, g: 0.45882352941176, b: 0.27843137254902},
{name: 'TSD 1-4-5', r: 0.41176470588235, g: 0.38823529411765, b: 0.24313725490196},
{name: 'TSD 1-5-1', r: 0.76470588235294, g: 0.71372549019608, b: 0.34117647058824},
{name: 'TSD 1-5-2', r: 0.66274509803922, g: 0.62352941176471, b: 0.29019607843137},
{name: 'TSD 1-5-3', r: 0.57647058823529, g: 0.53333333333333, b: 0.23921568627451},
{name: 'TSD 1-5-4', r: 0.48627450980392, g: 0.44705882352941, b: 0.2078431372549},
{name: 'TSD 1-6-1', r: 0.7843137254902, g: 0.72549019607843, b: 0.16078431372549},
{name: 'TSD 1-6-2', r: 0.70196078431373, g: 0.64313725490196, b: 0.16078431372549},
{name: 'TSD 1-6-3', r: 0.63921568627451, g: 0.56470588235294, b: 0.15686274509804},
{name: 'TSD 2-1-1', r: 0.83137254901961, g: 0.7921568627451, b: 0.72156862745098},
{name: 'TSD 2-1-2', r: 0.71372549019608, g: 0.67843137254902, b: 0.61960784313725},
{name: 'TSD 2-1-3', r: 0.56078431372549, g: 0.53333333333333, b: 0.49411764705882},
{name: 'TSD 2-1-4', r: 0.51764705882353, g: 0.49411764705882, b: 0.44705882352941},
{name: 'TSD 2-1-5', r: 0.42745098039216, g: 0.4, b: 0.36470588235294},
{name: 'TSD 2-1-6', r: 0.35686274509804, g: 0.33333333333333, b: 0.29803921568627},
{name: 'TSD 2-1-7', r: 0.27843137254902, g: 0.25882352941176, b: 0.24705882352941},
{name: 'TSD 2-2-1', r: 0.83529411764706, g: 0.76078431372549, b: 0.63529411764706},
{name: 'TSD 2-2-2', r: 0.70980392156863, g: 0.64705882352941, b: 0.53333333333333},
{name: 'TSD 2-2-3', r: 0.61176470588235, g: 0.55294117647059, b: 0.45882352941176},
{name: 'TSD 2-2-4', r: 0.50588235294118, g: 0.46274509803922, b: 0.3843137254902},
{name: 'TSD 2-2-5', r: 0.41176470588235, g: 0.37647058823529, b: 0.32156862745098},
{name: 'TSD 2-2-6', r: 0.34901960784314, g: 0.31372549019608, b: 0.26274509803922},
{name: 'TSD 2-2-7', r: 0.25098039215686, g: 0.22745098039216, b: 0.19607843137255},
{name: 'TSD 2-3-1', r: 0.85098039215686, g: 0.74509803921569, b: 0.54117647058824},
{name: 'TSD 2-3-2', r: 0.70588235294118, g: 0.61960784313725, b: 0.45882352941176},
{name: 'TSD 2-3-3', r: 0.62352941176471, g: 0.54117647058824, b: 0.40392156862745},
{name: 'TSD 2-3-4', r: 0.52549019607843, g: 0.45882352941176, b: 0.34117647058824},
{name: 'TSD 2-3-5', r: 0.44313725490196, g: 0.38039215686275, b: 0.27843137254902},
{name: 'TSD 2-3-6', r: 0.35686274509804, g: 0.31372549019608, b: 0.23921568627451},
{name: 'TSD 2-4-1', r: 0.78039215686275, g: 0.65882352941176, b: 0.41176470588235},
{name: 'TSD 2-4-2', r: 0.66274509803922, g: 0.55686274509804, b: 0.33333333333333},
{name: 'TSD 2-4-3', r: 0.62745098039216, g: 0.52549019607843, b: 0.32156862745098},
{name: 'TSD 2-4-4', r: 0.50980392156863, g: 0.42352941176471, b: 0.27450980392157},
{name: 'TSD 2-4-5', r: 0.41176470588235, g: 0.33333333333333, b: 0.19607843137255},
{name: 'TSD 2-5-1', r: 0.85882352941176, g: 0.69411764705882, b: 0.32156862745098},
{name: 'TSD 2-5-2', r: 0.73333333333333, g: 0.59607843137255, b: 0.29019607843137},
{name: 'TSD 2-5-3', r: 0.6156862745098, g: 0.50196078431373, b: 0.24313725490196},
{name: 'TSD 2-5-4', r: 0.52941176470588, g: 0.42352941176471, b: 0.20392156862745},
{name: 'TSD 2-6-1', r: 0.85882352941176, g: 0.67058823529412, b: 0.023529411764706},
{name: 'TSD 2-6-2', r: 0.74509803921569, g: 0.57647058823529, b: 0.10980392156863},
{name: 'TSD 3-1-1', r: 0.82745098039216, g: 0.77647058823529, b: 0.72156862745098},
{name: 'TSD 3-1-2', r: 0.70980392156863, g: 0.65098039215686, b: 0.6},
{name: 'TSD 3-1-3', r: 0.5921568627451, g: 0.54509803921569, b: 0.49803921568627},
{name: 'TSD 3-1-4', r: 0.49019607843137, g: 0.44705882352941, b: 0.41176470588235},
{name: 'TSD 3-1-5', r: 0.41960784313725, g: 0.3843137254902, b: 0.35294117647059},
{name: 'TSD 3-1-6', r: 0.33725490196078, g: 0.30196078431373, b: 0.27058823529412},
{name: 'TSD 3-1-7', r: 0.27450980392157, g: 0.24705882352941, b: 0.22745098039216},
{name: 'TSD 3-2-1', r: 0.8156862745098, g: 0.70588235294118, b: 0.6078431372549},
{name: 'TSD 3-2-2', r: 0.72156862745098, g: 0.61960784313725, b: 0.52549019607843},
{name: 'TSD 3-2-3', r: 0.6156862745098, g: 0.52941176470588, b: 0.44705882352941},
{name: 'TSD 3-2-4', r: 0.52941176470588, g: 0.44705882352941, b: 0.37647058823529},
{name: 'TSD 3-2-5', r: 0.43137254901961, g: 0.36470588235294, b: 0.30588235294118},
{name: 'TSD 3-2-6', r: 0.35294117647059, g: 0.29803921568627, b: 0.25098039215686},
{name: 'TSD 3-2-7', r: 0.28235294117647, g: 0.23137254901961, b: 0.18823529411765},
{name: 'TSD 3-3-1', r: 0.85490196078431, g: 0.68627450980392, b: 0.52549019607843},
{name: 'TSD 3-3-2', r: 0.73333333333333, g: 0.5921568627451, b: 0.43921568627451},
{name: 'TSD 3-3-3', r: 0.63137254901961, g: 0.49803921568627, b: 0.3843137254902},
{name: 'TSD 3-3-4', r: 0.53725490196078, g: 0.42352941176471, b: 0.32549019607843},
{name: 'TSD 3-3-5', r: 0.43921568627451, g: 0.34117647058824, b: 0.25098039215686},
{name: 'TSD 3-3-6', r: 0.36470588235294, g: 0.28627450980392, b: 0.21960784313725},
{name: 'TSD 3-4-1', r: 0.86666666666667, g: 0.65490196078431, b: 0.42352941176471},
{name: 'TSD 3-4-2', r: 0.76078431372549, g: 0.57647058823529, b: 0.37254901960784},
{name: 'TSD 3-4-3', r: 0.65490196078431, g: 0.48235294117647, b: 0.30980392156863},
{name: 'TSD 3-4-4', r: 0.54117647058824, g: 0.39607843137255, b: 0.25098039215686},
{name: 'TSD 3-4-5', r: 0.44313725490196, g: 0.32156862745098, b: 0.2},
{name: 'TSD 3-5-1', r: 0.87450980392157, g: 0.62745098039216, b: 0.30196078431373},
{name: 'TSD 3-5-2', r: 0.74509803921569, g: 0.53725490196078, b: 0.25490196078431},
{name: 'TSD 3-5-3', r: 0.63137254901961, g: 0.44705882352941, b: 0.22745098039216},
{name: 'TSD 3-5-4', r: 0.53333333333333, g: 0.37647058823529, b: 0.20392156862745},
{name: 'TSD 3-6-1', r: 0.87058823529412, g: 0.5843137254902, b: 0.13333333333333},
{name: 'TSD 3-6-2', r: 0.77647058823529, g: 0.52549019607843, b: 0.12549019607843},
{name: 'TSD 4-1-1', r: 0.85490196078431, g: 0.76862745098039, b: 0.71372549019608},
{name: 'TSD 4-1-2', r: 0.70588235294118, g: 0.63137254901961, b: 0.5843137254902},
{name: 'TSD 4-1-3', r: 0.59607843137255, g: 0.52941176470588, b: 0.49411764705882},
{name: 'TSD 4-1-4', r: 0.49411764705882, g: 0.44313725490196, b: 0.4156862745098},
{name: 'TSD 4-1-5', r: 0.41960784313725, g: 0.37254901960784, b: 0.34901960784314},
{name: 'TSD 4-1-6', r: 0.34509803921569, g: 0.30196078431373, b: 0.28627450980392},
{name: 'TSD 4-1-7', r: 0.27843137254902, g: 0.25098039215686, b: 0.23529411764706},
{name: 'TSD 4-2-1', r: 0.84313725490196, g: 0.69803921568627, b: 0.6156862745098},
{name: 'TSD 4-2-2', r: 0.72156862745098, g: 0.5921568627451, b: 0.52156862745098},
{name: 'TSD 4-2-3', r: 0.61960784313725, g: 0.50196078431373, b: 0.43137254901961},
{name: 'TSD 4-2-4', r: 0.52941176470588, g: 0.43529411764706, b: 0.38039215686275},
{name: 'TSD 4-2-5', r: 0.43921568627451, g: 0.34901960784314, b: 0.30196078431373},
{name: 'TSD 4-2-6', r: 0.34509803921569, g: 0.28627450980392, b: 0.24705882352941},
{name: 'TSD 4-3-1', r: 0.86274509803922, g: 0.63529411764706, b: 0.49019607843137},
{name: 'TSD 4-3-2', r: 0.74509803921569, g: 0.56078431372549, b: 0.44313725490196},
{name: 'TSD 4-3-3', r: 0.64313725490196, g: 0.47058823529412, b: 0.36470588235294},
{name: 'TSD 4-3-4', r: 0.52941176470588, g: 0.39607843137255, b: 0.30980392156863},
{name: 'TSD 4-3-5', r: 0.45098039215686, g: 0.32941176470588, b: 0.25882352941176},
{name: 'TSD 4-3-6', r: 0.35686274509804, g: 0.27058823529412, b: 0.21960784313725},
{name: 'TSD 4-4-1', r: 0.88235294117647, g: 0.6, b: 0.3921568627451},
{name: 'TSD 4-4-2', r: 0.75294117647059, g: 0.52156862745098, b: 0.36470588235294},
{name: 'TSD 4-4-3', r: 0.64705882352941, g: 0.45098039215686, b: 0.31372549019608},
{name: 'TSD 4-4-4', r: 0.54901960784314, g: 0.37647058823529, b: 0.25490196078431},
{name: 'TSD 4-4-5', r: 0.46666666666667, g: 0.31372549019608, b: 0.21176470588235},
{name: 'TSD 4-5-1', r: 0.88235294117647, g: 0.56862745098039, b: 0.30196078431373},
{name: 'TSD 4-5-2', r: 0.75686274509804, g: 0.48627450980392, b: 0.25882352941176},
{name: 'TSD 4-5-3', r: 0.64705882352941, g: 0.41176470588235, b: 0.22745098039216},
{name: 'TSD 4-6-1', r: 0.89803921568627, g: 0.53725490196078, b: 0.12156862745098},
{name: 'TSD 5-1-1', r: 0.83137254901961, g: 0.72156862745098, b: 0.68235294117647},
{name: 'TSD 5-1-2', r: 0.73725490196078, g: 0.64313725490196, b: 0.61176470588235},
{name: 'TSD 5-1-3', r: 0.62352941176471, g: 0.54509803921569, b: 0.51764705882353},
{name: 'TSD 5-1-4', r: 0.49803921568627, g: 0.42745098039216, b: 0.4},
{name: 'TSD 5-1-5', r: 0.4156862745098, g: 0.35686274509804, b: 0.33725490196078},
{name: 'TSD 5-1-6', r: 0.34509803921569, g: 0.29019607843137, b: 0.27450980392157},
{name: 'TSD 5-1-7', r: 0.27058823529412, g: 0.24313725490196, b: 0.23529411764706},
{name: 'TSD 5-2-1', r: 0.87058823529412, g: 0.66274509803922, b: 0.58823529411765},
{name: 'TSD 5-2-2', r: 0.73333333333333, g: 0.56078431372549, b: 0.49411764705882},
{name: 'TSD 5-2-3', r: 0.63921568627451, g: 0.48627450980392, b: 0.42745098039216},
{name: 'TSD 5-2-4', r: 0.52941176470588, g: 0.40392156862745, b: 0.36078431372549},
{name: 'TSD 5-2-5', r: 0.44313725490196, g: 0.33333333333333, b: 0.29411764705882},
{name: 'TSD 5-2-6', r: 0.36470588235294, g: 0.27843137254902, b: 0.25098039215686},
{name: 'TSD 5-3-1', r: 0.90196078431373, g: 0.61960784313725, b: 0.50196078431373},
{name: 'TSD 5-3-2', r: 0.75294117647059, g: 0.52941176470588, b: 0.42745098039216},
{name: 'TSD 5-3-3', r: 0.63921568627451, g: 0.43529411764706, b: 0.35686274509804},
{name: 'TSD 5-3-4', r: 0.51764705882353, g: 0.36078431372549, b: 0.29803921568627},
{name: 'TSD 5-3-5', r: 0.44705882352941, g: 0.31372549019608, b: 0.26274509803922},
{name: 'TSD 5-4-1', r: 0.90196078431373, g: 0.57647058823529, b: 0.43529411764706},
{name: 'TSD 5-4-2', r: 0.77254901960784, g: 0.48627450980392, b: 0.35686274509804},
{name: 'TSD 5-4-3', r: 0.65098039215686, g: 0.4, b: 0.29411764705882},
{name: 'TSD 5-4-4', r: 0.54901960784314, g: 0.34901960784314, b: 0.25098039215686},
{name: 'TSD 5-4-5', r: 0.45098039215686, g: 0.27843137254902, b: 0.20392156862745},
{name: 'TSD 5-5-1', r: 0.90588235294118, g: 0.52549019607843, b: 0.32941176470588},
{name: 'TSD 5-5-2', r: 0.77254901960784, g: 0.43921568627451, b: 0.25490196078431},
{name: 'TSD 5-5-3', r: 0.65490196078431, g: 0.36862745098039, b: 0.22352941176471},
{name: 'TSD 6-1-1', r: 0.83529411764706, g: 0.69803921568627, b: 0.67058823529412},
{name: 'TSD 6-1-2', r: 0.73333333333333, g: 0.6156862745098, b: 0.58823529411765},
{name: 'TSD 6-1-3', r: 0.60392156862745, g: 0.50980392156863, b: 0.49411764705882},
{name: 'TSD 6-1-4', r: 0.48627450980392, g: 0.41176470588235, b: 0.4},
{name: 'TSD 6-1-5', r: 0.41960784313725, g: 0.34901960784314, b: 0.33725490196078},
{name: 'TSD 6-1-6', r: 0.36078431372549, g: 0.29803921568627, b: 0.28235294117647},
{name: 'TSD 6-1-7', r: 0.27843137254902, g: 0.23529411764706, b: 0.22352941176471},
{name: 'TSD 6-2-1', r: 0.88627450980392, g: 0.64313725490196, b: 0.5921568627451},
{name: 'TSD 6-2-2', r: 0.75294117647059, g: 0.54117647058824, b: 0.50588235294118},
{name: 'TSD 6-2-3', r: 0.64313725490196, g: 0.45882352941176, b: 0.42745098039216},
{name: 'TSD 6-2-4', r: 0.53725490196078, g: 0.3843137254902, b: 0.35294117647059},
{name: 'TSD 6-2-5', r: 0.44705882352941, g: 0.32156862745098, b: 0.29803921568627},
{name: 'TSD 6-2-6', r: 0.36078431372549, g: 0.25490196078431, b: 0.23529411764706},
{name: 'TSD 6-3-1', r: 0.98039215686275, g: 0.61176470588235, b: 0.53333333333333},
{name: 'TSD 6-3-2', r: 0.78039215686275, g: 0.50980392156863, b: 0.44313725490196},
{name: 'TSD 6-3-3', r: 0.64313725490196, g: 0.4078431372549, b: 0.36078431372549},
{name: 'TSD 6-3-4', r: 0.55294117647059, g: 0.35294117647059, b: 0.30980392156863},
{name: 'TSD 6-3-5', r: 0.44705882352941, g: 0.28235294117647, b: 0.25098039215686},
{name: 'TSD 6-4-2', r: 0.78823529411765, g: 0.43529411764706, b: 0.33333333333333},
{name: 'TSD 6-4-3', r: 0.64705882352941, g: 0.35294117647059, b: 0.28235294117647},
{name: 'TSD 6-4-4', r: 0.54117647058824, g: 0.29411764705882, b: 0.23137254901961},
{name: 'TSD 6-4-5', r: 0.45490196078431, g: 0.25490196078431, b: 0.21176470588235},
{name: 'TSD 6-5-2', r: 0.77647058823529, g: 0.38039215686275, b: 0.27058823529412},
{name: 'TSD 6-5-3', r: 0.65098039215686, g: 0.30980392156863, b: 0.21960784313725},
{name: 'TSD 6-6-2', r: 0.77647058823529, g: 0.32941176470588, b: 0.1843137254902},
{name: 'TSD 7-1-1', r: 0.80392156862745, g: 0.63529411764706, b: 0.63137254901961},
{name: 'TSD 7-1-2', r: 0.74117647058824, g: 0.6, b: 0.5843137254902},
{name: 'TSD 7-1-3', r: 0.63529411764706, g: 0.51372549019608, b: 0.50196078431373},
{name: 'TSD 7-1-4', r: 0.50588235294118, g: 0.41176470588235, b: 0.41176470588235},
{name: 'TSD 7-1-5', r: 0.44313725490196, g: 0.36078431372549, b: 0.35294117647059},
{name: 'TSD 7-1-6', r: 0.36078431372549, g: 0.29803921568627, b: 0.29411764705882},
{name: 'TSD 7-1-7', r: 0.29019607843137, g: 0.23529411764706, b: 0.22745098039216},
{name: 'TSD 7-2-1', r: 0.88235294117647, g: 0.5921568627451, b: 0.58039215686275},
{name: 'TSD 7-2-2', r: 0.73333333333333, g: 0.49803921568627, b: 0.48627450980392},
{name: 'TSD 7-2-3', r: 0.64313725490196, g: 0.43529411764706, b: 0.41960784313725},
{name: 'TSD 7-2-4', r: 0.54901960784314, g: 0.36862745098039, b: 0.36078431372549},
{name: 'TSD 7-2-5', r: 0.47058823529412, g: 0.31372549019608, b: 0.30588235294118},
{name: 'TSD 7-2-6', r: 0.36078431372549, g: 0.24705882352941, b: 0.23921568627451},
{name: 'TSD 7-3-2', r: 0.77647058823529, g: 0.47058823529412, b: 0.43921568627451},
{name: 'TSD 7-3-3', r: 0.65882352941176, g: 0.38823529411765, b: 0.36470588235294},
{name: 'TSD 7-3-4', r: 0.55686274509804, g: 0.32549019607843, b: 0.30980392156863},
{name: 'TSD 7-3-5', r: 0.45098039215686, g: 0.26666666666667, b: 0.25098039215686},
{name: 'TSD 7-3-6', r: 0.37254901960784, g: 0.22745098039216, b: 0.21960784313725},
{name: 'TSD 7-4-2', r: 0.76078431372549, g: 0.3843137254902, b: 0.34509803921569},
{name: 'TSD 7-4-3', r: 0.64313725490196, g: 0.33725490196078, b: 0.30588235294118},
{name: 'TSD 7-4-4', r: 0.54901960784314, g: 0.27450980392157, b: 0.24705882352941},
{name: 'TSD 7-5-2', r: 0.76078431372549, g: 0.32549019607843, b: 0.28235294117647},
{name: 'TSD 7-5-3', r: 0.66666666666667, g: 0.29019607843137, b: 0.25490196078431},
{name: 'TSD 7-6-2', r: 0.74509803921569, g: 0.27843137254902, b: 0.23529411764706},
{name: 'TSD 8-1-1', r: 0.85098039215686, g: 0.68627450980392, b: 0.68235294117647},
{name: 'TSD 8-1-2', r: 0.74509803921569, g: 0.6, b: 0.60392156862745},
{name: 'TSD 8-1-3', r: 0.63529411764706, g: 0.50588235294118, b: 0.51372549019608},
{name: 'TSD 8-1-4', r: 0.53725490196078, g: 0.42745098039216, b: 0.43529411764706},
{name: 'TSD 8-1-5', r: 0.43529411764706, g: 0.34509803921569, b: 0.34509803921569},
{name: 'TSD 8-1-6', r: 0.35686274509804, g: 0.29019607843137, b: 0.29411764705882},
{name: 'TSD 8-1-7', r: 0.26666666666667, g: 0.2156862745098, b: 0.21960784313725},
{name: 'TSD 8-2-1', r: 0.91372549019608, g: 0.61176470588235, b: 0.63137254901961},
{name: 'TSD 8-2-2', r: 0.76862745098039, g: 0.51764705882353, b: 0.52941176470588},
{name: 'TSD 8-2-3', r: 0.64705882352941, g: 0.43921568627451, b: 0.45490196078431},
{name: 'TSD 8-2-4', r: 0.53725490196078, g: 0.35686274509804, b: 0.37254901960784},
{name: 'TSD 8-2-5', r: 0.45098039215686, g: 0.29803921568627, b: 0.31372549019608},
{name: 'TSD 8-2-6', r: 0.37647058823529, g: 0.25490196078431, b: 0.25882352941176},
{name: 'TSD 8-3-2', r: 0.77647058823529, g: 0.44705882352941, b: 0.47843137254902},
{name: 'TSD 8-3-3', r: 0.64705882352941, g: 0.36470588235294, b: 0.38039215686275},
{name: 'TSD 8-3-4', r: 0.54901960784314, g: 0.30980392156863, b: 0.33333333333333},
{name: 'TSD 8-3-5', r: 0.45490196078431, g: 0.25882352941176, b: 0.26666666666667},
{name: 'TSD 8-4-2', r: 0.77254901960784, g: 0.37647058823529, b: 0.4078431372549},
{name: 'TSD 8-4-3', r: 0.63921568627451, g: 0.30196078431373, b: 0.32941176470588},
{name: 'TSD 8-4-4', r: 0.54117647058824, g: 0.26274509803922, b: 0.27843137254902},
{name: 'TSD 8-5-2', r: 0.74509803921569, g: 0.30196078431373, b: 0.34509803921569},
{name: 'TSD 8-5-3', r: 0.64313725490196, g: 0.25882352941176, b: 0.29411764705882},
{name: 'TSD 8-5-4', r: 0.53333333333333, g: 0.22745098039216, b: 0.24313725490196},
{name: 'TSD 9-1-1', r: 0.86274509803922, g: 0.71372549019608, b: 0.72549019607843},
{name: 'TSD 9-1-2', r: 0.72156862745098, g: 0.58823529411765, b: 0.59607843137255},
{name: 'TSD 9-1-3', r: 0.61960784313725, g: 0.49803921568627, b: 0.50980392156863},
{name: 'TSD 9-1-4', r: 0.51764705882353, g: 0.42352941176471, b: 0.43921568627451},
{name: 'TSD 9-1-5', r: 0.43137254901961, g: 0.34901960784314, b: 0.36470588235294},
{name: 'TSD 9-1-6', r: 0.35686274509804, g: 0.28627450980392, b: 0.30588235294118},
{name: 'TSD 9-1-7', r: 0.29019607843137, g: 0.23921568627451, b: 0.24313725490196},
{name: 'TSD 9-2-2', r: 0.77254901960784, g: 0.52156862745098, b: 0.55686274509804},
{name: 'TSD 9-2-3', r: 0.63529411764706, g: 0.42745098039216, b: 0.45490196078431},
{name: 'TSD 9-2-4', r: 0.54901960784314, g: 0.36862745098039, b: 0.40392156862745},
{name: 'TSD 9-2-5', r: 0.44705882352941, g: 0.29803921568627, b: 0.32156862745098},
{name: 'TSD 9-2-6', r: 0.36470588235294, g: 0.25490196078431, b: 0.27450980392157},
{name: 'TSD 9-3-2', r: 0.76470588235294, g: 0.44705882352941, b: 0.50196078431373},
{name: 'TSD 9-3-3', r: 0.64313725490196, g: 0.37647058823529, b: 0.42352941176471},
{name: 'TSD 9-3-4', r: 0.54901960784314, g: 0.30588235294118, b: 0.35294117647059},
{name: 'TSD 9-3-5', r: 0.45490196078431, g: 0.27058823529412, b: 0.30588235294118},
{name: 'TSD 9-4-2', r: 0.78039215686275, g: 0.37647058823529, b: 0.43137254901961},
{name: 'TSD 9-4-3', r: 0.63529411764706, g: 0.31372549019608, b: 0.36470588235294},
{name: 'TSD 9-4-4', r: 0.53333333333333, g: 0.25882352941176, b: 0.30980392156863},
{name: 'TSD 9-5-2', r: 0.75294117647059, g: 0.30196078431373, b: 0.37647058823529},
{name: 'TSD 9-5-3', r: 0.63921568627451, g: 0.27450980392157, b: 0.33333333333333},
{name: 'TSD 10-1-1', r: 0.86666666666667, g: 0.70980392156863, b: 0.75294117647059},
{name: 'TSD 10-1-2', r: 0.71372549019608, g: 0.58039215686275, b: 0.63921568627451},
{name: 'TSD 10-1-3', r: 0.6078431372549, g: 0.50196078431373, b: 0.54117647058824},
{name: 'TSD 10-1-4', r: 0.51372549019608, g: 0.41960784313725, b: 0.45490196078431},
{name: 'TSD 10-1-5', r: 0.42352941176471, g: 0.34901960784314, b: 0.38039215686275},
{name: 'TSD 10-1-6', r: 0.34117647058824, g: 0.27450980392157, b: 0.30196078431373},
{name: 'TSD 10-1-7', r: 0.25882352941176, g: 0.2156862745098, b: 0.23529411764706},
{name: 'TSD 10-2-2', r: 0.76862745098039, g: 0.54509803921569, b: 0.64313725490196},
{name: 'TSD 10-2-3', r: 0.65098039215686, g: 0.44705882352941, b: 0.53333333333333},
{name: 'TSD 10-2-4', r: 0.52549019607843, g: 0.35686274509804, b: 0.42352941176471},
{name: 'TSD 10-2-5', r: 0.43529411764706, g: 0.30196078431373, b: 0.36470588235294},
{name: 'TSD 10-2-6', r: 0.36078431372549, g: 0.23529411764706, b: 0.28627450980392},
{name: 'TSD 10-3-2', r: 0.77647058823529, g: 0.45490196078431, b: 0.5921568627451},
{name: 'TSD 10-3-3', r: 0.67058823529412, g: 0.3921568627451, b: 0.50980392156863},
{name: 'TSD 10-3-4', r: 0.56078431372549, g: 0.33725490196078, b: 0.43137254901961},
{name: 'TSD 10-3-5', r: 0.45490196078431, g: 0.25490196078431, b: 0.34117647058824},
{name: 'TSD 10-4-3', r: 0.65490196078431, g: 0.32156862745098, b: 0.47450980392157},
{name: 'TSD 10-4-4', r: 0.54509803921569, g: 0.25882352941176, b: 0.38823529411765},
{name: 'TSD 11-1-1', r: 0.82352941176471, g: 0.72549019607843, b: 0.79607843137255},
{name: 'TSD 11-1-2', r: 0.72941176470588, g: 0.63137254901961, b: 0.71372549019608},
{name: 'TSD 11-1-3', r: 0.6078431372549, g: 0.51764705882353, b: 0.5843137254902},
{name: 'TSD 11-1-4', r: 0.49803921568627, g: 0.41960784313725, b: 0.47058823529412},
{name: 'TSD 11-1-5', r: 0.42352941176471, g: 0.36470588235294, b: 0.41176470588235},
{name: 'TSD 11-1-6', r: 0.32941176470588, g: 0.28627450980392, b: 0.32549019607843},
{name: 'TSD 11-1-7', r: 0.26274509803922, g: 0.23137254901961, b: 0.25098039215686},
{name: 'TSD 11-2-2', r: 0.71764705882353, g: 0.52941176470588, b: 0.68627450980392},
{name: 'TSD 11-2-3', r: 0.62352941176471, g: 0.46666666666667, b: 0.6},
{name: 'TSD 11-2-4', r: 0.51764705882353, g: 0.37647058823529, b: 0.48235294117647},
{name: 'TSD 11-2-5', r: 0.43921568627451, g: 0.31764705882353, b: 0.4078431372549},
{name: 'TSD 11-2-6', r: 0.34901960784314, g: 0.25490196078431, b: 0.31764705882353},
{name: 'TSD 11-3-3', r: 0.6156862745098, g: 0.40392156862745, b: 0.56470588235294},
{name: 'TSD 11-3-4', r: 0.51764705882353, g: 0.32156862745098, b: 0.48235294117647},
{name: 'TSD 11-3-5', r: 0.44705882352941, g: 0.28235294117647, b: 0.4156862745098},
{name: 'TSD 11-4-4', r: 0.52941176470588, g: 0.27450980392157, b: 0.50196078431373},
{name: 'TSD 11-4-5', r: 0.42352941176471, g: 0.23529411764706, b: 0.39607843137255},
{name: 'TSD 12-1-1', r: 0.78823529411765, g: 0.70196078431373, b: 0.8},
{name: 'TSD 12-1-2', r: 0.66666666666667, g: 0.58823529411765, b: 0.67450980392157},
{name: 'TSD 12-1-3', r: 0.56078431372549, g: 0.48235294117647, b: 0.58039215686275},
{name: 'TSD 12-1-4', r: 0.47450980392157, g: 0.4156862745098, b: 0.49411764705882},
{name: 'TSD 12-1-5', r: 0.37647058823529, g: 0.32549019607843, b: 0.38823529411765},
{name: 'TSD 12-1-6', r: 0.30980392156863, g: 0.27058823529412, b: 0.31764705882353},
{name: 'TSD 12-1-7', r: 0.24705882352941, g: 0.21960784313725, b: 0.25490196078431},
{name: 'TSD 12-2-2', r: 0.63137254901961, g: 0.52549019607843, b: 0.68627450980392},
{name: 'TSD 12-2-3', r: 0.52941176470588, g: 0.42352941176471, b: 0.57647058823529},
{name: 'TSD 12-2-4', r: 0.47058823529412, g: 0.37254901960784, b: 0.50588235294118},
{name: 'TSD 12-2-5', r: 0.37254901960784, g: 0.29803921568627, b: 0.40392156862745},
{name: 'TSD 12-2-6', r: 0.30196078431373, g: 0.24705882352941, b: 0.32941176470588},
{name: 'TSD 12-3-3', r: 0.51764705882353, g: 0.36470588235294, b: 0.58823529411765},
{name: 'TSD 12-3-4', r: 0.42745098039216, g: 0.30196078431373, b: 0.48627450980392},
{name: 'TSD 12-3-5', r: 0.36470588235294, g: 0.26666666666667, b: 0.4156862745098},
{name: 'TSD 12-4-4', r: 0.42352941176471, g: 0.27058823529412, b: 0.47843137254902},
{name: 'TSD 12-4-5', r: 0.34117647058824, g: 0.21960784313725, b: 0.38823529411765},
{name: 'TSD 13-1-1', r: 0.76078431372549, g: 0.71372549019608, b: 0.8078431372549},
{name: 'TSD 13-1-2', r: 0.63921568627451, g: 0.5921568627451, b: 0.68627450980392},
{name: 'TSD 13-1-3', r: 0.54509803921569, g: 0.50196078431373, b: 0.5843137254902},
{name: 'TSD 13-1-4', r: 0.45490196078431, g: 0.41960784313725, b: 0.49411764705882},
{name: 'TSD 13-1-5', r: 0.37254901960784, g: 0.34509803921569, b: 0.41176470588235},
{name: 'TSD 13-1-6', r: 0.30588235294118, g: 0.28235294117647, b: 0.33333333333333},
{name: 'TSD 13-1-7', r: 0.25098039215686, g: 0.23921568627451, b: 0.27058823529412},
{name: 'TSD 13-2-2', r: 0.5921568627451, g: 0.52941176470588, b: 0.69411764705882},
{name: 'TSD 13-2-3', r: 0.49019607843137, g: 0.42745098039216, b: 0.57647058823529},
{name: 'TSD 13-2-4', r: 0.42745098039216, g: 0.36862745098039, b: 0.50196078431373},
{name: 'TSD 13-2-5', r: 0.34509803921569, g: 0.29803921568627, b: 0.41176470588235},
{name: 'TSD 13-2-6', r: 0.29411764705882, g: 0.24705882352941, b: 0.34117647058824},
{name: 'TSD 13-3-3', r: 0.46274509803922, g: 0.37254901960784, b: 0.58823529411765},
{name: 'TSD 13-3-4', r: 0.40392156862745, g: 0.31764705882353, b: 0.50588235294118},
{name: 'TSD 13-3-5', r: 0.32941176470588, g: 0.26274509803922, b: 0.41176470588235},
{name: 'TSD 14-1-1', r: 0.73725490196078, g: 0.72549019607843, b: 0.82352941176471},
{name: 'TSD 14-1-2', r: 0.62352941176471, g: 0.61176470588235, b: 0.71372549019608},
{name: 'TSD 14-1-3', r: 0.52156862745098, g: 0.50196078431373, b: 0.58823529411765},
{name: 'TSD 14-1-4', r: 0.43137254901961, g: 0.42352941176471, b: 0.48627450980392},
{name: 'TSD 14-1-5', r: 0.34901960784314, g: 0.34117647058824, b: 0.4078431372549},
{name: 'TSD 14-1-6', r: 0.28235294117647, g: 0.27450980392157, b: 0.33333333333333},
{name: 'TSD 14-2-2', r: 0.54117647058824, g: 0.51372549019608, b: 0.69411764705882},
{name: 'TSD 14-2-3', r: 0.47058823529412, g: 0.44705882352941, b: 0.60392156862745},
{name: 'TSD 14-2-4', r: 0.39607843137255, g: 0.37254901960784, b: 0.50980392156863},
{name: 'TSD 14-2-5', r: 0.32549019607843, g: 0.30196078431373, b: 0.41960784313725},
{name: 'TSD 14-2-6', r: 0.25882352941176, g: 0.24313725490196, b: 0.32941176470588},
{name: 'TSD 14-3-3', r: 0.42745098039216, g: 0.38823529411765, b: 0.59607843137255},
{name: 'TSD 14-3-4', r: 0.36470588235294, g: 0.32549019607843, b: 0.51764705882353},
{name: 'TSD 14-3-5', r: 0.29803921568627, g: 0.26666666666667, b: 0.4156862745098},
{name: 'TSD 14-4-4', r: 0.32549019607843, g: 0.28627450980392, b: 0.50196078431373},
{name: 'TSD 15-1-1', r: 0.69803921568627, g: 0.70196078431373, b: 0.77647058823529},
{name: 'TSD 15-1-2', r: 0.58823529411765, g: 0.58823529411765, b: 0.67450980392157},
{name: 'TSD 15-1-3', r: 0.49019607843137, g: 0.49019607843137, b: 0.57254901960784},
{name: 'TSD 15-1-4', r: 0.41960784313725, g: 0.4156862745098, b: 0.48627450980392},
{name: 'TSD 15-1-5', r: 0.34117647058824, g: 0.34509803921569, b: 0.40392156862745},
{name: 'TSD 15-1-6', r: 0.26666666666667, g: 0.26666666666667, b: 0.31372549019608},
{name: 'TSD 15-1-7', r: 0.22745098039216, g: 0.22352941176471, b: 0.24705882352941},
{name: 'TSD 15-2-2', r: 0.53725490196078, g: 0.54901960784314, b: 0.69411764705882},
{name: 'TSD 15-2-3', r: 0.43137254901961, g: 0.43921568627451, b: 0.56470588235294},
{name: 'TSD 15-2-4', r: 0.37254901960784, g: 0.37254901960784, b: 0.49019607843137},
{name: 'TSD 15-2-5', r: 0.29803921568627, g: 0.30588235294118, b: 0.4156862745098},
{name: 'TSD 15-2-6', r: 0.25098039215686, g: 0.25098039215686, b: 0.32941176470588},
{name: 'TSD 15-3-2', r: 0.48235294117647, g: 0.48627450980392, b: 0.70196078431373},
{name: 'TSD 15-3-3', r: 0.38823529411765, g: 0.3921568627451, b: 0.5921568627451},
{name: 'TSD 15-3-4', r: 0.32156862745098, g: 0.33333333333333, b: 0.50196078431373},
{name: 'TSD 15-3-5', r: 0.27058823529412, g: 0.26666666666667, b: 0.40392156862745},
{name: 'TSD 15-4-3', r: 0.35294117647059, g: 0.36470588235294, b: 0.58823529411765},
{name: 'TSD 15-4-4', r: 0.28627450980392, g: 0.30196078431373, b: 0.49411764705882},
{name: 'TSD 15-5-3', r: 0.31372549019608, g: 0.33725490196078, b: 0.6},
{name: 'TSD 15-5-4', r: 0.26274509803922, g: 0.26666666666667, b: 0.50196078431373},
{name: 'TSD 16-1-1', r: 0.70196078431373, g: 0.72156862745098, b: 0.81176470588235},
{name: 'TSD 16-1-2', r: 0.57647058823529, g: 0.6078431372549, b: 0.69019607843137},
{name: 'TSD 16-1-3', r: 0.47843137254902, g: 0.50588235294118, b: 0.5843137254902},
{name: 'TSD 16-1-4', r: 0.38823529411765, g: 0.4156862745098, b: 0.48627450980392},
{name: 'TSD 16-1-5', r: 0.32156862745098, g: 0.34117647058824, b: 0.4},
{name: 'TSD 16-1-6', r: 0.26274509803922, g: 0.27450980392157, b: 0.32156862745098},
{name: 'TSD 16-1-7', r: 0.22352941176471, g: 0.22352941176471, b: 0.25882352941176},
{name: 'TSD 16-2-2', r: 0.49019607843137, g: 0.53725490196078, b: 0.70588235294118},
{name: 'TSD 16-2-3', r: 0.41176470588235, g: 0.45490196078431, b: 0.58823529411765},
{name: 'TSD 16-2-4', r: 0.33333333333333, g: 0.37254901960784, b: 0.48627450980392},
{name: 'TSD 16-2-5', r: 0.27843137254902, g: 0.30588235294118, b: 0.4078431372549},
{name: 'TSD 16-2-6', r: 0.23529411764706, g: 0.24705882352941, b: 0.32549019607843},
{name: 'TSD 16-3-2', r: 0.42745098039216, g: 0.49019607843137, b: 0.70196078431373},
{name: 'TSD 16-3-3', r: 0.34901960784314, g: 0.4078431372549, b: 0.58823529411765},
{name: 'TSD 16-3-4', r: 0.28627450980392, g: 0.33725490196078, b: 0.49411764705882},
{name: 'TSD 16-3-5', r: 0.25490196078431, g: 0.28627450980392, b: 0.42352941176471},
{name: 'TSD 16-4-3', r: 0.29019607843137, g: 0.37254901960784, b: 0.59607843137255},
{name: 'TSD 16-4-4', r: 0.24313725490196, g: 0.30980392156863, b: 0.49803921568627},
{name: 'TSD 16-4-5', r: 0.21176470588235, g: 0.25098039215686, b: 0.41176470588235},
{name: 'TSD 16-5-4', r: 0.19607843137255, g: 0.29019607843137, b: 0.49411764705882},
{name: 'TSD 17-1-1', r: 0.69803921568627, g: 0.74509803921569, b: 0.8156862745098},
{name: 'TSD 17-1-2', r: 0.54901960784314, g: 0.6, b: 0.67058823529412},
{name: 'TSD 17-1-3', r: 0.47450980392157, g: 0.52156862745098, b: 0.5843137254902},
{name: 'TSD 17-1-4', r: 0.3921568627451, g: 0.43529411764706, b: 0.48235294117647},
{name: 'TSD 17-1-5', r: 0.32941176470588, g: 0.36862745098039, b: 0.4078431372549},
{name: 'TSD 17-1-6', r: 0.27843137254902, g: 0.29411764705882, b: 0.31764705882353},
{name: 'TSD 17-1-7', r: 0.21960784313725, g: 0.23137254901961, b: 0.25490196078431},
{name: 'TSD 17-2-1', r: 0.56862745098039, g: 0.66666666666667, b: 0.80392156862745},
{name: 'TSD 17-2-2', r: 0.48235294117647, g: 0.57647058823529, b: 0.69411764705882},
{name: 'TSD 17-2-3', r: 0.39607843137255, g: 0.48235294117647, b: 0.5921568627451},
{name: 'TSD 17-2-4', r: 0.33333333333333, g: 0.40392156862745, b: 0.49803921568627},
{name: 'TSD 17-2-5', r: 0.28235294117647, g: 0.33333333333333, b: 0.4078431372549},
{name: 'TSD 17-2-6', r: 0.22745098039216, g: 0.27058823529412, b: 0.32941176470588},
{name: 'TSD 17-3-1', r: 0.46666666666667, g: 0.65098039215686, b: 0.83529411764706},
{name: 'TSD 17-3-2', r: 0.36862745098039, g: 0.52941176470588, b: 0.68235294117647},
{name: 'TSD 17-3-3', r: 0.32549019607843, g: 0.46274509803922, b: 0.6},
{name: 'TSD 17-3-4', r: 0.27058823529412, g: 0.38823529411765, b: 0.50588235294118},
{name: 'TSD 17-3-5', r: 0.21960784313725, g: 0.30980392156863, b: 0.3921568627451},
{name: 'TSD 17-4-2', r: 0.28235294117647, g: 0.52549019607843, b: 0.72156862745098},
{name: 'TSD 17-4-3', r: 0.21960784313725, g: 0.42352941176471, b: 0.58039215686275},
{name: 'TSD 17-4-4', r: 0.2078431372549, g: 0.36078431372549, b: 0.49019607843137},
{name: 'TSD 17-4-5', r: 0.16470588235294, g: 0.29803921568627, b: 0.40392156862745},
{name: 'TSD 17-5-2', r: 0.1843137254902, g: 0.49019607843137, b: 0.71764705882353},
{name: 'TSD 17-5-3', r: 0.13725490196078, g: 0.41960784313725, b: 0.59607843137255},
{name: 'TSD 18-1-1', r: 0.67843137254902, g: 0.75686274509804, b: 0.7921568627451},
{name: 'TSD 18-1-2', r: 0.54901960784314, g: 0.63137254901961, b: 0.67058823529412},
{name: 'TSD 18-1-3', r: 0.46666666666667, g: 0.52549019607843, b: 0.54901960784314},
{name: 'TSD 18-1-4', r: 0.39607843137255, g: 0.45490196078431, b: 0.47843137254902},
{name: 'TSD 18-1-5', r: 0.33725490196078, g: 0.38039215686275, b: 0.4},
{name: 'TSD 18-1-6', r: 0.25882352941176, g: 0.29411764705882, b: 0.30588235294118},
{name: 'TSD 18-1-7', r: 0.22352941176471, g: 0.23921568627451, b: 0.25098039215686},
{name: 'TSD 18-2-1', r: 0.53725490196078, g: 0.71372549019608, b: 0.7921568627451},
{name: 'TSD 18-2-2', r: 0.47843137254902, g: 0.61960784313725, b: 0.69411764705882},
{name: 'TSD 18-2-3', r: 0.4156862745098, g: 0.53333333333333, b: 0.5921568627451},
{name: 'TSD 18-2-4', r: 0.34901960784314, g: 0.45490196078431, b: 0.50196078431373},
{name: 'TSD 18-2-5', r: 0.28235294117647, g: 0.36862745098039, b: 0.4078431372549},
{name: 'TSD 18-2-6', r: 0.21960784313725, g: 0.29411764705882, b: 0.32549019607843},
{name: 'TSD 18-3-1', r: 0.4156862745098, g: 0.69803921568627, b: 0.8078431372549},
{name: 'TSD 18-3-2', r: 0.3843137254902, g: 0.60392156862745, b: 0.68627450980392},
{name: 'TSD 18-3-3', r: 0.31372549019608, g: 0.52156862745098, b: 0.60392156862745},
{name: 'TSD 18-3-4', r: 0.27058823529412, g: 0.43137254901961, b: 0.49019607843137},
{name: 'TSD 18-3-5', r: 0.2078431372549, g: 0.35294117647059, b: 0.40392156862745},
{name: 'TSD 18-3-6', r: 0.17647058823529, g: 0.29019607843137, b: 0.32156862745098},
{name: 'TSD 18-4-2', r: 0.22352941176471, g: 0.58823529411765, b: 0.71764705882353},
{name: 'TSD 18-4-3', r: 0.1921568627451, g: 0.47450980392157, b: 0.5843137254902},
{name: 'TSD 18-4-4', r: 0.14509803921569, g: 0.4, b: 0.45882352941176},
{name: 'TSD 18-4-5', r: 0.14117647058824, g: 0.35294117647059, b: 0.4078431372549},
{name: 'TSD 18-5-3', r: 0, g: 0.47843137254902, b: 0.59607843137255},
{name: 'TSD 19-1-1', r: 0.69019607843137, g: 0.78823529411765, b: 0.7843137254902},
{name: 'TSD 19-1-2', r: 0.59607843137255, g: 0.68235294117647, b: 0.68235294117647},
{name: 'TSD 19-1-3', r: 0.49803921568627, g: 0.56078431372549, b: 0.56470588235294},
{name: 'TSD 19-1-4', r: 0.41176470588235, g: 0.47058823529412, b: 0.47843137254902},
{name: 'TSD 19-1-5', r: 0.34509803921569, g: 0.38823529411765, b: 0.3921568627451},
{name: 'TSD 19-1-6', r: 0.28235294117647, g: 0.31372549019608, b: 0.31764705882353},
{name: 'TSD 19-1-7', r: 0.2156862745098, g: 0.23921568627451, b: 0.24313725490196},
{name: 'TSD 19-2-1', r: 0.5843137254902, g: 0.7843137254902, b: 0.7921568627451},
{name: 'TSD 19-2-2', r: 0.48235294117647, g: 0.64705882352941, b: 0.66666666666667},
{name: 'TSD 19-2-3', r: 0.41176470588235, g: 0.55294117647059, b: 0.56470588235294},
{name: 'TSD 19-2-4', r: 0.33725490196078, g: 0.46274509803922, b: 0.47843137254902},
{name: 'TSD 19-2-5', r: 0.29019607843137, g: 0.38823529411765, b: 0.39607843137255},
{name: 'TSD 19-2-6', r: 0.22352941176471, g: 0.30588235294118, b: 0.32156862745098},
{name: 'TSD 19-3-2', r: 0.36078431372549, g: 0.65882352941176, b: 0.67843137254902},
{name: 'TSD 19-3-3', r: 0.28627450980392, g: 0.53333333333333, b: 0.55686274509804},
{name: 'TSD 19-3-4', r: 0.23137254901961, g: 0.44313725490196, b: 0.46274509803922},
{name: 'TSD 19-3-5', r: 0.22745098039216, g: 0.38039215686275, b: 0.39607843137255},
{name: 'TSD 19-3-6', r: 0.17254901960784, g: 0.30196078431373, b: 0.30588235294118},
{name: 'TSD 19-4-2', r: 0.15686274509804, g: 0.66274509803922, b: 0.69803921568627},
{name: 'TSD 19-4-3', r: 0.18823529411765, g: 0.53725490196078, b: 0.55686274509804},
{name: 'TSD 19-4-4', r: 0.13725490196078, g: 0.44705882352941, b: 0.45882352941176},
{name: 'TSD 19-4-5', r: 0.086274509803922, g: 0.36862745098039, b: 0.38039215686275},
{name: 'TSD 20-1-1', r: 0.72941176470588, g: 0.83137254901961, b: 0.80392156862745},
{name: 'TSD 20-1-2', r: 0.59607843137255, g: 0.69019607843137, b: 0.67058823529412},
{name: 'TSD 20-1-3', r: 0.50588235294118, g: 0.5921568627451, b: 0.57647058823529},
{name: 'TSD 20-1-4', r: 0.41176470588235, g: 0.48627450980392, b: 0.47450980392157},
{name: 'TSD 20-1-5', r: 0.33725490196078, g: 0.4, b: 0.38823529411765},
{name: 'TSD 20-1-6', r: 0.27058823529412, g: 0.31764705882353, b: 0.30980392156863},
{name: 'TSD 20-1-7', r: 0.22352941176471, g: 0.25490196078431, b: 0.25098039215686},
{name: 'TSD 20-2-1', r: 0.64313725490196, g: 0.83921568627451, b: 0.7921568627451},
{name: 'TSD 20-2-2', r: 0.54117647058824, g: 0.71764705882353, b: 0.68235294117647},
{name: 'TSD 20-2-3', r: 0.44313725490196, g: 0.5921568627451, b: 0.56862745098039},
{name: 'TSD 20-2-4', r: 0.36470588235294, g: 0.49803921568627, b: 0.47450980392157},
{name: 'TSD 20-2-5', r: 0.29411764705882, g: 0.4078431372549, b: 0.38823529411765},
{name: 'TSD 20-2-6', r: 0.23921568627451, g: 0.33333333333333, b: 0.31764705882353},
{name: 'TSD 20-3-2', r: 0.4156862745098, g: 0.72156862745098, b: 0.67058823529412},
{name: 'TSD 20-3-3', r: 0.34509803921569, g: 0.59607843137255, b: 0.55294117647059},
{name: 'TSD 20-3-4', r: 0.27450980392157, g: 0.49019607843137, b: 0.45490196078431},
{name: 'TSD 20-3-5', r: 0.23137254901961, g: 0.4156862745098, b: 0.3843137254902},
{name: 'TSD 20-3-6', r: 0.16470588235294, g: 0.32941176470588, b: 0.30980392156863},
{name: 'TSD 20-4-3', r: 0.2, g: 0.61176470588235, b: 0.55294117647059},
{name: 'TSD 20-4-4', r: 0.14901960784314, g: 0.49803921568627, b: 0.45098039215686},
{name: 'TSD 20-4-5', r: 0.14901960784314, g: 0.4078431372549, b: 0.36862745098039},
{name: 'TSD 20-5-4', r: 0, g: 0.49411764705882, b: 0.43921568627451},
{name: 'TSD 20-5-5', r: 0, g: 0.4078431372549, b: 0.36078431372549},
{name: 'TSD 21-1-1', r: 0.72941176470588, g: 0.83529411764706, b: 0.78823529411765},
{name: 'TSD 21-1-2', r: 0.6078431372549, g: 0.69019607843137, b: 0.65098039215686},
{name: 'TSD 21-1-3', r: 0.50588235294118, g: 0.56862745098039, b: 0.54117647058824},
{name: 'TSD 21-1-4', r: 0.4156862745098, g: 0.47843137254902, b: 0.45882352941176},
{name: 'TSD 21-1-5', r: 0.36078431372549, g: 0.4078431372549, b: 0.38823529411765},
{name: 'TSD 21-1-6', r: 0.28627450980392, g: 0.32549019607843, b: 0.30588235294118},
{name: 'TSD 21-1-7', r: 0.21176470588235, g: 0.24705882352941, b: 0.23137254901961},
{name: 'TSD 21-2-1', r: 0.62352941176471, g: 0.81176470588235, b: 0.73333333333333},
{name: 'TSD 21-2-2', r: 0.52549019607843, g: 0.69411764705882, b: 0.63137254901961},
{name: 'TSD 21-2-3', r: 0.43137254901961, g: 0.57254901960784, b: 0.51764705882353},
{name: 'TSD 21-2-4', r: 0.38039215686275, g: 0.50588235294118, b: 0.45098039215686},
{name: 'TSD 21-2-5', r: 0.30980392156863, g: 0.40392156862745, b: 0.36862745098039},
{name: 'TSD 21-2-6', r: 0.26274509803922, g: 0.33333333333333, b: 0.30196078431373},
{name: 'TSD 21-3-2', r: 0.42352941176471, g: 0.70980392156863, b: 0.6078431372549},
{name: 'TSD 21-3-3', r: 0.36470588235294, g: 0.58039215686275, b: 0.50588235294118},
{name: 'TSD 21-3-4', r: 0.30196078431373, g: 0.50196078431373, b: 0.42745098039216},
{name: 'TSD 21-3-5', r: 0.25490196078431, g: 0.4078431372549, b: 0.34901960784314},
{name: 'TSD 21-3-6', r: 0.20392156862745, g: 0.32941176470588, b: 0.27450980392157},
{name: 'TSD 21-4-2', r: 0.33725490196078, g: 0.71764705882353, b: 0.5843137254902},
{name: 'TSD 21-4-3', r: 0.27450980392157, g: 0.6, b: 0.48235294117647},
{name: 'TSD 21-4-4', r: 0.21176470588235, g: 0.50588235294118, b: 0.41176470588235},
{name: 'TSD 21-4-5', r: 0.20392156862745, g: 0.41960784313725, b: 0.33725490196078},
{name: 'TSD 21-5-3', r: 0.14117647058824, g: 0.60392156862745, b: 0.45882352941176},
{name: 'TSD 21-5-4', r: 0.047058823529412, g: 0.49019607843137, b: 0.38039215686275},
{name: 'TSD 21-5-5', r: 0.047058823529412, g: 0.4078431372549, b: 0.30588235294118},
{name: 'TSD 22-1-1', r: 0.77647058823529, g: 0.85098039215686, b: 0.76078431372549},
{name: 'TSD 22-1-2', r: 0.61960784313725, g: 0.68235294117647, b: 0.63137254901961},
{name: 'TSD 22-1-3', r: 0.52549019607843, g: 0.57647058823529, b: 0.53725490196078},
{name: 'TSD 22-1-4', r: 0.45882352941176, g: 0.49803921568627, b: 0.45882352941176},
{name: 'TSD 22-1-5', r: 0.37647058823529, g: 0.4078431372549, b: 0.38039215686275},
{name: 'TSD 22-1-6', r: 0.29411764705882, g: 0.32549019607843, b: 0.30196078431373},
{name: 'TSD 22-1-7', r: 0.24705882352941, g: 0.26666666666667, b: 0.24705882352941},
{name: 'TSD 22-2-1', r: 0.69411764705882, g: 0.85098039215686, b: 0.72941176470588},
{name: 'TSD 22-2-2', r: 0.5843137254902, g: 0.71372549019608, b: 0.61176470588235},
{name: 'TSD 22-2-3', r: 0.48235294117647, g: 0.5843137254902, b: 0.49803921568627},
{name: 'TSD 22-2-4', r: 0.41960784313725, g: 0.50980392156863, b: 0.43529411764706},
{name: 'TSD 22-2-5', r: 0.33725490196078, g: 0.4078431372549, b: 0.34509803921569},
{name: 'TSD 22-2-6', r: 0.27843137254902, g: 0.34117647058824, b: 0.28627450980392},
{name: 'TSD 22-3-2', r: 0.50588235294118, g: 0.69803921568627, b: 0.55294117647059},
{name: 'TSD 22-3-3', r: 0.43137254901961, g: 0.58823529411765, b: 0.46666666666667},
{name: 'TSD 22-3-4', r: 0.37254901960784, g: 0.50980392156863, b: 0.40392156862745},
{name: 'TSD 22-3-5', r: 0.29803921568627, g: 0.40392156862745, b: 0.31372549019608},
{name: 'TSD 22-3-6', r: 0.24313725490196, g: 0.33333333333333, b: 0.25882352941176},
{name: 'TSD 22-4-2', r: 0.42745098039216, g: 0.69803921568627, b: 0.50588235294118},
{name: 'TSD 22-4-3', r: 0.37647058823529, g: 0.6078431372549, b: 0.43921568627451},
{name: 'TSD 22-4-4', r: 0.31372549019608, g: 0.50980392156863, b: 0.36078431372549},
{name: 'TSD 22-4-5', r: 0.26274509803922, g: 0.42352941176471, b: 0.30196078431373},
{name: 'TSD 22-4-6', r: 0.21176470588235, g: 0.33333333333333, b: 0.23921568627451},
{name: 'TSD 22-5-3', r: 0.29019607843137, g: 0.59607843137255, b: 0.3921568627451},
{name: 'TSD 22-5-4', r: 0.23529411764706, g: 0.49803921568627, b: 0.32549019607843},
{name: 'TSD 22-5-5', r: 0.2078431372549, g: 0.41960784313725, b: 0.27058823529412},
{name: 'TSD 22-6-3', r: 0.18039215686275, g: 0.59607843137255, b: 0.34901960784314},
{name: 'TSD 22-6-4', r: 0.17647058823529, g: 0.50196078431373, b: 0.29019607843137},
{name: 'TSD 23-1-1', r: 0.76470588235294, g: 0.81176470588235, b: 0.74509803921569},
{name: 'TSD 23-1-2', r: 0.65882352941176, g: 0.70588235294118, b: 0.63921568627451},
{name: 'TSD 23-1-3', r: 0.53725490196078, g: 0.58039215686275, b: 0.52156862745098},
{name: 'TSD 23-1-4', r: 0.46666666666667, g: 0.49803921568627, b: 0.45098039215686},
{name: 'TSD 23-1-5', r: 0.37647058823529, g: 0.40392156862745, b: 0.36862745098039},
{name: 'TSD 23-1-6', r: 0.30588235294118, g: 0.32941176470588, b: 0.29803921568627},
{name: 'TSD 23-1-7', r: 0.24705882352941, g: 0.25882352941176, b: 0.23921568627451},
{name: 'TSD 23-2-1', r: 0.70588235294118, g: 0.8156862745098, b: 0.67843137254902},
{name: 'TSD 23-2-2', r: 0.5921568627451, g: 0.68235294117647, b: 0.56862745098039},
{name: 'TSD 23-2-3', r: 0.49411764705882, g: 0.5843137254902, b: 0.48235294117647},
{name: 'TSD 23-2-4', r: 0.42745098039216, g: 0.49019607843137, b: 0.4078431372549},
{name: 'TSD 23-2-5', r: 0.36078431372549, g: 0.41176470588235, b: 0.34901960784314},
{name: 'TSD 23-2-6', r: 0.27450980392157, g: 0.31764705882353, b: 0.25882352941176},
{name: 'TSD 23-3-1', r: 0.64313725490196, g: 0.81176470588235, b: 0.61176470588235},
{name: 'TSD 23-3-2', r: 0.54509803921569, g: 0.69803921568627, b: 0.52941176470588},
{name: 'TSD 23-3-3', r: 0.46666666666667, g: 0.5843137254902, b: 0.43921568627451},
{name: 'TSD 23-3-4', r: 0.39607843137255, g: 0.49803921568627, b: 0.37254901960784},
{name: 'TSD 23-3-5', r: 0.32156862745098, g: 0.40392156862745, b: 0.30588235294118},
{name: 'TSD 23-3-6', r: 0.27058823529412, g: 0.33725490196078, b: 0.25490196078431},
{name: 'TSD 23-4-2', r: 0.51372549019608, g: 0.69411764705882, b: 0.46274509803922},
{name: 'TSD 23-4-3', r: 0.42745098039216, g: 0.59607843137255, b: 0.3921568627451},
{name: 'TSD 23-4-4', r: 0.38039215686275, g: 0.50588235294118, b: 0.33725490196078},
{name: 'TSD 23-4-5', r: 0.31372549019608, g: 0.4078431372549, b: 0.26666666666667},
{name: 'TSD 23-4-6', r: 0.24313725490196, g: 0.32156862745098, b: 0.2156862745098},
{name: 'TSD 23-5-2', r: 0.48627450980392, g: 0.71764705882353, b: 0.41960784313725},
{name: 'TSD 23-5-3', r: 0.4078431372549, g: 0.6, b: 0.34117647058824},
{name: 'TSD 23-5-4', r: 0.33333333333333, g: 0.49411764705882, b: 0.27058823529412},
{name: 'TSD 23-5-5', r: 0.27058823529412, g: 0.41176470588235, b: 0.2156862745098},
{name: 'TSD 23-6-2', r: 0.45490196078431, g: 0.72156862745098, b: 0.33333333333333},
{name: 'TSD 23-6-3', r: 0.38039215686275, g: 0.60392156862745, b: 0.27450980392157},
{name: 'TSD 23-6-4', r: 0.30588235294118, g: 0.49803921568627, b: 0.21176470588235},
{name: 'TSD 24-1-1', r: 0.78823529411765, g: 0.8078431372549, b: 0.73725490196078},
{name: 'TSD 24-1-2', r: 0.67450980392157, g: 0.69019607843137, b: 0.62352941176471},
{name: 'TSD 24-1-3', r: 0.56470588235294, g: 0.58039215686275, b: 0.53333333333333},
{name: 'TSD 24-1-4', r: 0.47058823529412, g: 0.48627450980392, b: 0.43921568627451},
{name: 'TSD 24-1-5', r: 0.37647058823529, g: 0.38823529411765, b: 0.34901960784314},
{name: 'TSD 24-1-6', r: 0.29803921568627, g: 0.30980392156863, b: 0.27450980392157},
{name: 'TSD 24-1-7', r: 0.24313725490196, g: 0.25098039215686, b: 0.22745098039216},
{name: 'TSD 24-2-1', r: 0.77647058823529, g: 0.81960784313725, b: 0.67450980392157},
{name: 'TSD 24-2-2', r: 0.65490196078431, g: 0.69411764705882, b: 0.56078431372549},
{name: 'TSD 24-2-3', r: 0.54901960784314, g: 0.5843137254902, b: 0.47843137254902},
{name: 'TSD 24-2-4', r: 0.45882352941176, g: 0.47843137254902, b: 0.38823529411765},
{name: 'TSD 24-2-5', r: 0.37254901960784, g: 0.3921568627451, b: 0.31372549019608},
{name: 'TSD 24-2-6', r: 0.32156862745098, g: 0.32941176470588, b: 0.26666666666667},
{name: 'TSD 24-3-1', r: 0.75294117647059, g: 0.81960784313725, b: 0.5921568627451},
{name: 'TSD 24-3-2', r: 0.63529411764706, g: 0.69019607843137, b: 0.50196078431373},
{name: 'TSD 24-3-3', r: 0.54117647058824, g: 0.58823529411765, b: 0.42352941176471},
{name: 'TSD 24-3-4', r: 0.43921568627451, g: 0.48235294117647, b: 0.34509803921569},
{name: 'TSD 24-3-5', r: 0.36470588235294, g: 0.4, b: 0.28235294117647},
{name: 'TSD 24-3-6', r: 0.29803921568627, g: 0.32156862745098, b: 0.22745098039216},
{name: 'TSD 24-4-1', r: 0.74117647058824, g: 0.82745098039216, b: 0.50980392156863},
{name: 'TSD 24-4-2', r: 0.6156862745098, g: 0.68627450980392, b: 0.43529411764706},
{name: 'TSD 24-4-3', r: 0.53725490196078, g: 0.58823529411765, b: 0.36862745098039},
{name: 'TSD 24-4-4', r: 0.43529411764706, g: 0.49019607843137, b: 0.30588235294118},
{name: 'TSD 24-4-5', r: 0.37254901960784, g: 0.41176470588235, b: 0.25098039215686},
{name: 'TSD 24-5-1', r: 0.72941176470588, g: 0.83921568627451, b: 0.42352941176471},
{name: 'TSD 24-5-2', r: 0.59607843137255, g: 0.69019607843137, b: 0.33725490196078},
{name: 'TSD 24-5-3', r: 0.52156862745098, g: 0.5921568627451, b: 0.29803921568627},
{name: 'TSD 24-5-4', r: 0.42745098039216, g: 0.48235294117647, b: 0.23529411764706},
{name: 'TSD 24-5-5', r: 0.36078431372549, g: 0.39607843137255, b: 0.19607843137255},
{name: 'TSD 24-6-2', r: 0.58823529411765, g: 0.69019607843137, b: 0.2156862745098},
{name: 'TSD 24-6-3', r: 0.51372549019608, g: 0.5921568627451, b: 0.17647058823529},
{name: 'TSD 24-6-4', r: 0.43137254901961, g: 0.49411764705882, b: 0.16078431372549},
{name: 'TSD 14-1-7', r: 0.23137254901961, g: 0.22352941176471, b: 0.25882352941176}
];
});

View File

@ -0,0 +1,273 @@
jQuery(function ($) {
$.colorpicker.swatchesNames['isccnbs'] = 'ISCC-NBS';
$.colorpicker.swatches['isccnbs'] = [
{name: 'Vivid Pink', r: 1, g: 0.70980392156863, b: 0.72941176470588},
{name: 'Strong Pink', r: 0.91764705882353, g: 0.57647058823529, b: 0.6},
{name: 'Deep Pink', r: 0.89411764705882, g: 0.44313725490196, b: 0.47843137254902},
{name: 'Light Pink', r: 0.97647058823529, g: 0.8, b: 0.7921568627451},
{name: 'Moderate Pink', r: 0.87058823529412, g: 0.64705882352941, b: 0.64313725490196},
{name: 'Dark Pink', r: 0.75294117647059, g: 0.50196078431373, b: 0.50588235294118},
{name: 'Pale Pink', r: 0.91764705882353, g: 0.84705882352941, b: 0.84313725490196},
{name: 'Grayish Pink', r: 0.76862745098039, g: 0.68235294117647, b: 0.67843137254902},
{name: 'Pinkish White', r: 0.91764705882353, g: 0.89019607843137, b: 0.88235294117647},
{name: 'Pinkish Gray', r: 0.75686274509804, g: 0.71372549019608, b: 0.70196078431373},
{name: 'Vivid Red', r: 0.74509803921569, g: 0, b: 0.19607843137255},
{name: 'Strong Red', r: 0.73725490196078, g: 0.24705882352941, b: 0.29019607843137},
{name: 'Deep Red', r: 0.51764705882353, g: 0.10588235294118, b: 0.17647058823529},
{name: 'Very Deep Red', r: 0.36078431372549, g: 0.035294117647059, b: 0.13725490196078},
{name: 'Moderate Red', r: 0.67058823529412, g: 0.30588235294118, b: 0.32156862745098},
{name: 'Dark Red', r: 0.44705882352941, g: 0.1843137254902, b: 0.2156862745098},
{name: 'Very Dark Red', r: 0.24705882352941, g: 0.090196078431373, b: 0.15686274509804},
{name: 'Light Grayish Red', r: 0.67843137254902, g: 0.53333333333333, b: 0.51764705882353},
{name: 'Grayish Red', r: 0.56470588235294, g: 0.36470588235294, b: 0.36470588235294},
{name: 'Dark Grayish Red', r: 0.32941176470588, g: 0.23921568627451, b: 0.24705882352941},
{name: 'Blackish Red', r: 0.18039215686275, g: 0.11372549019608, b: 0.12941176470588},
{name: 'Reddish Gray', r: 0.56078431372549, g: 0.50588235294118, b: 0.49803921568627},
{name: 'Dark Reddish Gray', r: 0.36078431372549, g: 0.31372549019608, b: 0.30980392156863},
{name: 'Reddish Black', r: 0.15686274509804, g: 0.12549019607843, b: 0.13333333333333},
{name: 'Vivid Yellowish Pink', r: 1, g: 0.71764705882353, b: 0.64705882352941},
{name: 'Strong Yellowish Pink', r: 0.97647058823529, g: 0.57647058823529, b: 0.47450980392157},
{name: 'Deep Yellowish Pink', r: 0.90196078431373, g: 0.40392156862745, b: 0.12941176470588},
{name: 'Light Yellowish Pink', r: 0.95686274509804, g: 0.76078431372549, b: 0.76078431372549},
{name: 'Moderate Yellowish Pink', r: 0.85098039215686, g: 0.65098039215686, b: 0.66274509803922},
{name: 'Dark Yellowish Pink', r: 0.76862745098039, g: 0.51372549019608, b: 0.47450980392157},
{name: 'Pale Yellowish Pink', r: 0.92549019607843, g: 0.83529411764706, b: 0.77254901960784},
{name: 'Grayish Yellowish Pink', r: 0.78039215686275, g: 0.67843137254902, b: 0.63921568627451},
{name: 'Brownish Pink', r: 0.76078431372549, g: 0.67450980392157, b: 0.6},
{name: 'Vivid Reddish Orange', r: 0.88627450980392, g: 0.34509803921569, b: 0.13333333333333},
{name: 'Strong Reddish Orange', r: 0.85098039215686, g: 0.37647058823529, b: 0.23137254901961},
{name: 'Deep Reddish Orange', r: 0.66666666666667, g: 0.21960784313725, b: 0.11764705882353},
{name: 'Moderate Reddish Orange', r: 0.79607843137255, g: 0.42745098039216, b: 0.31764705882353},
{name: 'Dark Reddish Orange', r: 0.61960784313725, g: 0.27843137254902, b: 0.19607843137255},
{name: 'Grayish Reddish Orange', r: 0.70588235294118, g: 0.45490196078431, b: 0.36862745098039},
{name: 'Strong Reddish Brown', r: 0.53333333333333, g: 0.17647058823529, b: 0.090196078431373},
{name: 'Deep Reddish Brown', r: 0.33725490196078, g: 0.027450980392157, b: 0.047058823529412},
{name: 'Light Reddish Brown', r: 0.65882352941176, g: 0.48627450980392, b: 0.42745098039216},
{name: 'Moderate Reddish Brown', r: 0.47450980392157, g: 0.26666666666667, b: 0.23137254901961},
{name: 'Dark Reddish Brown', r: 0.24313725490196, g: 0.11372549019608, b: 0.11764705882353},
{name: 'Light Grayish Reddish Brown', r: 0.5921568627451, g: 0.49803921568627, b: 0.45098039215686},
{name: 'Grayish Reddish Brown', r: 0.40392156862745, g: 0.29803921568627, b: 0.27843137254902},
{name: 'Dark Grayish Reddish Brown', r: 0.26274509803922, g: 0.18823529411765, b: 0.18039215686275},
{name: 'Vivid Orange', r: 0.95294117647059, g: 0.51764705882353, b: 0},
{name: 'Brilliant Orange', r: 0.9921568627451, g: 0.58039215686275, b: 0.24705882352941},
{name: 'Strong Orange', r: 0.92941176470588, g: 0.52941176470588, b: 0.17647058823529},
{name: 'Deep Orange', r: 0.74509803921569, g: 0.39607843137255, b: 0.086274509803922},
{name: 'Light Orange', r: 0.98039215686275, g: 0.70980392156863, b: 0.49803921568627},
{name: 'Moderate Orange', r: 0.85098039215686, g: 0.56470588235294, b: 0.34509803921569},
{name: 'Brownish Orange', r: 0.68235294117647, g: 0.41176470588235, b: 0.21960784313725},
{name: 'Strong Brown', r: 0.50196078431373, g: 0.27450980392157, b: 0.10588235294118},
{name: 'Deep Brown', r: 0.34901960784314, g: 0.2, b: 0.098039215686275},
{name: 'Light Brown', r: 0.65098039215686, g: 0.48235294117647, b: 0.35686274509804},
{name: 'Moderate Brown', r: 0.43529411764706, g: 0.30588235294118, b: 0.2156862745098},
{name: 'Dark Brown', r: 0.25882352941176, g: 0.14509803921569, b: 0.094117647058824},
{name: 'Light Grayish Brown', r: 0.5843137254902, g: 0.50196078431373, b: 0.43921568627451},
{name: 'Grayish Brown', r: 0.38823529411765, g: 0.31764705882353, b: 0.27843137254902},
{name: 'Dark Grayish Brown', r: 0.24313725490196, g: 0.19607843137255, b: 0.17254901960784},
{name: 'Light Brownish Gray', r: 0.55686274509804, g: 0.50980392156863, b: 0.47450980392157},
{name: 'Brownish Gray', r: 0.35686274509804, g: 0.31372549019608, b: 0.30980392156863},
{name: 'Brownish Black', r: 0.15686274509804, g: 0.12549019607843, b: 0.10980392156863},
{name: 'Vivid Orange Yellow', r: 0.96470588235294, g: 0.65098039215686, b: 0},
{name: 'Brilliant Orange Yellow', r: 1, g: 0.75686274509804, b: 0.30980392156863},
{name: 'Strong Orange Yellow', r: 0.91764705882353, g: 0.63529411764706, b: 0.12941176470588},
{name: 'Deep Orange Yellow', r: 0.78823529411765, g: 0.52156862745098, b: 0},
{name: 'Light Orange Yellow', r: 0.9843137254902, g: 0.78823529411765, b: 0.49803921568627},
{name: 'Moderate Orange Yellow', r: 0.89019607843137, g: 0.65882352941176, b: 0.34117647058824},
{name: 'Dark Orange Yellow', r: 0.74509803921569, g: 0.54117647058824, b: 0.23921568627451},
{name: 'Pale Orange Yellow', r: 0.98039215686275, g: 0.83921568627451, b: 0.64705882352941},
{name: 'Strong Yellowish Brown', r: 0.6, g: 0.39607843137255, b: 0.082352941176471},
{name: 'Deep Yellowish Brown', r: 0.39607843137255, g: 0.27058823529412, b: 0.13333333333333},
{name: 'Light Yellowish Brown', r: 0.75686274509804, g: 0.60392156862745, b: 0.41960784313725},
{name: 'Moderate Yellowish Brown', r: 0.50980392156863, g: 0.4, b: 0.26666666666667},
{name: 'Dark Yellowish Brown', r: 0.29411764705882, g: 0.21176470588235, b: 0.12941176470588},
{name: 'Light Grayish Yellowish Brown', r: 0.68235294117647, g: 0.6078431372549, b: 0.50980392156863},
{name: 'Grayish Yellowish Brown', r: 0.49411764705882, g: 0.42745098039216, b: 0.35294117647059},
{name: 'Dark Grayish Yellowish Brown', r: 0.28235294117647, g: 0.23529411764706, b: 0.19607843137255},
{name: 'Vivid Yellow', r: 0.95294117647059, g: 0.76470588235294, b: 0},
{name: 'Brilliant Yellow', r: 0.98039215686275, g: 0.85490196078431, b: 0.36862745098039},
{name: 'Strong Yellow', r: 0.83137254901961, g: 0.68627450980392, b: 0.2156862745098},
{name: 'Deep Yellow', r: 0.68627450980392, g: 0.55294117647059, b: 0.074509803921569},
{name: 'Light Yellow', r: 0.97254901960784, g: 0.87058823529412, b: 0.49411764705882},
{name: 'Moderate Yellow', r: 0.78823529411765, g: 0.68235294117647, b: 0.36470588235294},
{name: 'Dark Yellow', r: 0.67058823529412, g: 0.56862745098039, b: 0.26666666666667},
{name: 'Pale Yellow', r: 0.95294117647059, g: 0.89803921568627, b: 0.67058823529412},
{name: 'Grayish Yellow', r: 0.76078431372549, g: 0.69803921568627, b: 0.50196078431373},
{name: 'Dark Grayish Yellow', r: 0.63137254901961, g: 0.56078431372549, b: 0.37647058823529},
{name: 'Yellowish White', r: 0.94117647058824, g: 0.91764705882353, b: 0.83921568627451},
{name: 'Yellowish Gray', r: 0.74901960784314, g: 0.72156862745098, b: 0.64705882352941},
{name: 'Light Olive Brown', r: 0.58823529411765, g: 0.44313725490196, b: 0.090196078431373},
{name: 'Moderate Olive Brown', r: 0.42352941176471, g: 0.32941176470588, b: 0.11764705882353},
{name: 'Dark Olive Brown', r: 0.23137254901961, g: 0.1921568627451, b: 0.12941176470588},
{name: 'Vivid Greenish Yellow', r: 0.86274509803922, g: 0.82745098039216, b: 0},
{name: 'Brilliant Greenish Yellow', r: 0.91372549019608, g: 0.89411764705882, b: 0.31372549019608},
{name: 'Strong Greenish Yellow', r: 0.74509803921569, g: 0.71764705882353, b: 0.18039215686275},
{name: 'Deep Greenish Yellow', r: 0.6078431372549, g: 0.58039215686275, b: 0},
{name: 'Light Greenish Yellow', r: 0.91764705882353, g: 0.90196078431373, b: 0.47450980392157},
{name: 'Moderate Greenish Yellow', r: 0.72549019607843, g: 0.70588235294118, b: 0.34901960784314},
{name: 'Dark Greenish Yellow', r: 0.59607843137255, g: 0.58039215686275, b: 0.24313725490196},
{name: 'Pale Greenish Yellow', r: 0.92156862745098, g: 0.90980392156863, b: 0.64313725490196},
{name: 'Grayish Greenish Yellow', r: 0.72549019607843, g: 0.70980392156863, b: 0.49019607843137},
{name: 'Light Olive', r: 0.52549019607843, g: 0.49411764705882, b: 0.21176470588235},
{name: 'Moderate Olive', r: 0.4, g: 0.36470588235294, b: 0.11764705882353},
{name: 'Dark Olive', r: 0.25098039215686, g: 0.23921568627451, b: 0.12941176470588},
{name: 'Light Grayish Olive', r: 0.54901960784314, g: 0.52941176470588, b: 0.40392156862745},
{name: 'Grayish Olive', r: 0.35686274509804, g: 0.34509803921569, b: 0.25882352941176},
{name: 'Dark Grayish Olive', r: 0.21176470588235, g: 0.2078431372549, b: 0.15294117647059},
{name: 'Light Olive Gray', r: 0.54117647058824, g: 0.52941176470588, b: 0.46274509803922},
{name: 'Olive Gray', r: 0.34117647058824, g: 0.33333333333333, b: 0.29803921568627},
{name: 'Olive Black', r: 0.14509803921569, g: 0.14117647058824, b: 0.11372549019608},
{name: 'Vivid Yellow Green', r: 0.55294117647059, g: 0.71372549019608, b: 0},
{name: 'Brilliant Yellow Green', r: 0.74117647058824, g: 0.85490196078431, b: 0.34117647058824},
{name: 'Strong Yellow Green', r: 0.49411764705882, g: 0.62352941176471, b: 0.18039215686275},
{name: 'Deep Yellow Green', r: 0.27450980392157, g: 0.44313725490196, b: 0.16078431372549},
{name: 'Light Yellow Green', r: 0.78823529411765, g: 0.86274509803922, b: 0.53725490196078},
{name: 'Moderate Yellow Green', r: 0.54117647058824, g: 0.60392156862745, b: 0.35686274509804},
{name: 'Pale Yellow Green', r: 0.85490196078431, g: 0.87450980392157, b: 0.71764705882353},
{name: 'Grayish Yellow Green', r: 0.56078431372549, g: 0.5921568627451, b: 0.47450980392157},
{name: 'Strong Olive Green', r: 0.25098039215686, g: 0.30980392156863, b: 0},
{name: 'Deep Olive Green', r: 0.13725490196078, g: 0.1843137254902, b: 0},
{name: 'Moderate Olive Green', r: 0.29019607843137, g: 0.36470588235294, b: 0.13725490196078},
{name: 'Dark Olive Green', r: 0.16862745098039, g: 0.23921568627451, b: 0.14901960784314},
{name: 'Grayish Olive Green', r: 0.31764705882353, g: 0.34117647058824, b: 0.26666666666667},
{name: 'Dark Grayish Olive Green', r: 0.1921568627451, g: 0.21176470588235, b: 0.16862745098039},
{name: 'Vivid Yellowish Green', r: 0.15294117647059, g: 0.65098039215686, b: 0.29803921568627},
{name: 'Brilliant Yellowish Green', r: 0.51372549019608, g: 0.82745098039216, b: 0.49019607843137},
{name: 'Strong Yellowish Green', r: 0.26666666666667, g: 0.58039215686275, b: 0.29019607843137},
{name: 'Deep Yellowish Green', r: 0, g: 0.3843137254902, b: 0.17647058823529},
{name: 'Very Deep Yellowish Green', r: 0, g: 0.1921568627451, b: 0.094117647058824},
{name: 'Very Light Yellowish Green', r: 0.71372549019608, g: 0.89803921568627, b: 0.68627450980392},
{name: 'Light Yellowish Green', r: 0.57647058823529, g: 0.77254901960784, b: 0.57254901960784},
{name: 'Moderate Yellowish Green', r: 0.40392156862745, g: 0.57254901960784, b: 0.40392156862745},
{name: 'Dark Yellowish Green', r: 0.2078431372549, g: 0.36862745098039, b: 0.23137254901961},
{name: 'Very Dark Yellowish Green', r: 0.090196078431373, g: 0.21176470588235, b: 0.12549019607843},
{name: 'Vivid Green', r: 0, g: 0.53333333333333, b: 0.33725490196078},
{name: 'Brilliant Green', r: 0.24313725490196, g: 0.70588235294118, b: 0.53725490196078},
{name: 'Strong Green', r: 0, g: 0.47450980392157, b: 0.34901960784314},
{name: 'Deep Green', r: 0, g: 0.32941176470588, b: 0.23921568627451},
{name: 'Very Light Green', r: 0.55686274509804, g: 0.81960784313725, b: 0.69803921568627},
{name: 'Light Green', r: 0.4156862745098, g: 0.67058823529412, b: 0.55686274509804},
{name: 'Moderate Green', r: 0.23137254901961, g: 0.47058823529412, b: 0.38039215686275},
{name: 'Dark Green', r: 0.10588235294118, g: 0.30196078431373, b: 0.24313725490196},
{name: 'Very Dark Green', r: 0.10980392156863, g: 0.2078431372549, b: 0.17647058823529},
{name: 'Very Pale Green', r: 0.78039215686275, g: 0.90196078431373, b: 0.84313725490196},
{name: 'Pale Green', r: 0.55294117647059, g: 0.63921568627451, b: 0.6},
{name: 'Grayish Green', r: 0.36862745098039, g: 0.44313725490196, b: 0.4156862745098},
{name: 'Dark Grayish Green', r: 0.22745098039216, g: 0.29411764705882, b: 0.27843137254902},
{name: 'Blackish Green', r: 0.10196078431373, g: 0.14117647058824, b: 0.12941176470588},
{name: 'Greenish White', r: 0.87450980392157, g: 0.92941176470588, b: 0.90980392156863},
{name: 'Light Greenish Gray', r: 0.69803921568627, g: 0.74509803921569, b: 0.70980392156863},
{name: 'Greenish Gray', r: 0.49019607843137, g: 0.53725490196078, b: 0.51764705882353},
{name: 'Dark Greenish Gray', r: 0.30588235294118, g: 0.34117647058824, b: 0.33333333333333},
{name: 'Greenish Black', r: 0.11764705882353, g: 0.13725490196078, b: 0.12941176470588},
{name: 'Vivid Bluish Green', r: 0, g: 0.53333333333333, b: 0.50980392156863},
{name: 'Brilliant Bluish Green', r: 0, g: 0.65098039215686, b: 0.57647058823529},
{name: 'Strong Bluish Green', r: 0, g: 0.47843137254902, b: 0.45490196078431},
{name: 'Deep Bluish Green', r: 0, g: 0.26666666666667, b: 0.24705882352941},
{name: 'Very Light Bluish Green', r: 0.58823529411765, g: 0.87058823529412, b: 0.81960784313725},
{name: 'Light Bluish Green', r: 0.4, g: 0.67843137254902, b: 0.64313725490196},
{name: 'Moderate Bluish Green', r: 0.1921568627451, g: 0.47058823529412, b: 0.45098039215686},
{name: 'Dark Bluish Green', r: 0, g: 0.29411764705882, b: 0.28627450980392},
{name: 'Very Dark Bluish Green', r: 0, g: 0.16470588235294, b: 0.16078431372549},
{name: 'Vivid Greenish Blue', r: 0, g: 0.52156862745098, b: 0.63137254901961},
{name: 'Brilliant Greenish Blue', r: 0.13725490196078, g: 0.61960784313725, b: 0.72941176470588},
{name: 'Strong Greenish Blue', r: 0, g: 0.46666666666667, b: 0.56862745098039},
{name: 'Deep Greenish Blue', r: 0.18039215686275, g: 0.51764705882353, b: 0.5843137254902},
{name: 'Very Light Greenish Blue', r: 0.61176470588235, g: 0.81960784313725, b: 0.86274509803922},
{name: 'Light Greenish Blue', r: 0.4, g: 0.66666666666667, b: 0.73725490196078},
{name: 'Moderate Greenish Blue', r: 0.21176470588235, g: 0.45882352941176, b: 0.53333333333333},
{name: 'Dark Greenish Blue', r: 0, g: 0.28627450980392, b: 0.34509803921569},
{name: 'Very Dark Greenish Blue', r: 0, g: 0.18039215686275, b: 0.23137254901961},
{name: 'Vivid Blue', r: 0, g: 0.63137254901961, b: 0.76078431372549},
{name: 'Brilliant Blue', r: 0.28627450980392, g: 0.5921568627451, b: 0.8156862745098},
{name: 'Strong Blue', r: 0, g: 0.40392156862745, b: 0.64705882352941},
{name: 'Deep Blue', r: 0, g: 0.25490196078431, b: 0.4156862745098},
{name: 'Very Light Blue', r: 0.63137254901961, g: 0.7921568627451, b: 0.94509803921569},
{name: 'Light Blue', r: 0.43921568627451, g: 0.63921568627451, b: 0.8},
{name: 'Moderate Blue', r: 0.26274509803922, g: 0.41960784313725, b: 0.5843137254902},
{name: 'Dark Blue', r: 0, g: 0.18823529411765, b: 0.30588235294118},
{name: 'Very Pale Blue', r: 0.73725490196078, g: 0.83137254901961, b: 0.90196078431373},
{name: 'Pale Blue', r: 0.56862745098039, g: 0.63921568627451, b: 0.69019607843137},
{name: 'Grayish Blue', r: 0.32549019607843, g: 0.4078431372549, b: 0.47058823529412},
{name: 'Dark Grayish Blue', r: 0.21176470588235, g: 0.27058823529412, b: 0.30980392156863},
{name: 'Blackish Blue', r: 0.12549019607843, g: 0.15686274509804, b: 0.18823529411765},
{name: 'Bluish White', r: 0.91372549019608, g: 0.91372549019608, b: 0.92941176470588},
{name: 'Light Bluish Gray', r: 0.70588235294118, g: 0.73725490196078, b: 0.75294117647059},
{name: 'Bluish Gray', r: 0.50588235294118, g: 0.52941176470588, b: 0.54509803921569},
{name: 'Dark Bluish Gray', r: 0.31764705882353, g: 0.34509803921569, b: 0.36862745098039},
{name: 'Bluish Black', r: 0.12549019607843, g: 0.14117647058824, b: 0.15686274509804},
{name: 'Vivid Purplish Blue', r: 0.18823529411765, g: 0.14901960784314, b: 0.47843137254902},
{name: 'Brilliant Purplish Blue', r: 0.42352941176471, g: 0.47450980392157, b: 0.72156862745098},
{name: 'Strong Purplish Blue', r: 0.32941176470588, g: 0.35294117647059, b: 0.65490196078431},
{name: 'Deep Purplish Blue', r: 0.15294117647059, g: 0.14117647058824, b: 0.34509803921569},
{name: 'Very Light Purplish Blue', r: 0.70196078431373, g: 0.73725490196078, b: 0.88627450980392},
{name: 'Light Purplish Blue', r: 0.52941176470588, g: 0.56862745098039, b: 0.74901960784314},
{name: 'Moderate Purplish Blue', r: 0.30588235294118, g: 0.31764705882353, b: 0.50196078431373},
{name: 'Dark Purplish Blue', r: 0.14509803921569, g: 0.14117647058824, b: 0.25098039215686},
{name: 'Very Pale Purplish Blue', r: 0.75294117647059, g: 0.7843137254902, b: 0.88235294117647},
{name: 'Pale Purplish Blue', r: 0.54901960784314, g: 0.57254901960784, b: 0.67450980392157},
{name: 'Grayish Purplish Blue', r: 0.29803921568627, g: 0.31764705882353, b: 0.42745098039216},
{name: 'Vivid Violet', r: 0.56470588235294, g: 0.39607843137255, b: 0.7921568627451},
{name: 'Brilliant Violet', r: 0.49411764705882, g: 0.45098039215686, b: 0.72156862745098},
{name: 'Strong Violet', r: 0.37647058823529, g: 0.30588235294118, b: 0.5921568627451},
{name: 'Deep Violet', r: 0.19607843137255, g: 0.090196078431373, b: 0.30196078431373},
{name: 'Very Light Violet', r: 0.86274509803922, g: 0.8156862745098, b: 1},
{name: 'Light Violet', r: 0.54901960784314, g: 0.50980392156863, b: 0.71372549019608},
{name: 'Moderate Violet', r: 0.37647058823529, g: 0.30588235294118, b: 0.50588235294118},
{name: 'Dark Violet', r: 0.1843137254902, g: 0.12941176470588, b: 0.25098039215686},
{name: 'Very Pale Violet', r: 0.76862745098039, g: 0.76470588235294, b: 0.86666666666667},
{name: 'Pale Violet', r: 0.58823529411765, g: 0.56470588235294, b: 0.67058823529412},
{name: 'Grayish Violet', r: 0.33333333333333, g: 0.29803921568627, b: 0.41176470588235},
{name: 'Vivid Purple', r: 0.60392156862745, g: 0.30588235294118, b: 0.68235294117647},
{name: 'Brilliant Purple', r: 0.82745098039216, g: 0.6, b: 0.90196078431373},
{name: 'Strong Purple', r: 0.52941176470588, g: 0.33725490196078, b: 0.57254901960784},
{name: 'Deep Purple', r: 0.37647058823529, g: 0.1843137254902, b: 0.41960784313725},
{name: 'Very Deep Purple', r: 0.25098039215686, g: 0.10196078431373, b: 0.29803921568627},
{name: 'Very Light Purple', r: 0.83529411764706, g: 0.72941176470588, b: 0.85882352941176},
{name: 'Light Purple', r: 0.71372549019608, g: 0.5843137254902, b: 0.75294117647059},
{name: 'Moderate Purple', r: 0.52549019607843, g: 0.37647058823529, b: 0.55686274509804},
{name: 'Dark Purple', r: 0.33725490196078, g: 0.23529411764706, b: 0.36078431372549},
{name: 'Very Dark Purple', r: 0.18823529411765, g: 0.098039215686275, b: 0.20392156862745},
{name: 'Very Pale Purple', r: 0.83921568627451, g: 0.7921568627451, b: 0.86666666666667},
{name: 'Pale Purple', r: 0.66666666666667, g: 0.59607843137255, b: 0.66274509803922},
{name: 'Grayish Purple', r: 0.47450980392157, g: 0.4078431372549, b: 0.47058823529412},
{name: 'Dark Grayish Purple', r: 0.31372549019608, g: 0.25098039215686, b: 0.30196078431373},
{name: 'Blackish Purple', r: 0.16078431372549, g: 0.11764705882353, b: 0.16078431372549},
{name: 'Purplish White', r: 0.90980392156863, g: 0.89019607843137, b: 0.89803921568627},
{name: 'Light Purplish Gray', r: 0.74901960784314, g: 0.72549019607843, b: 0.74117647058824},
{name: 'Purplish Gray', r: 0.54509803921569, g: 0.52156862745098, b: 0.53725490196078},
{name: 'Dark Purplish Gray', r: 0.36470588235294, g: 0.33333333333333, b: 0.35686274509804},
{name: 'Purplish Black', r: 0.14117647058824, g: 0.12941176470588, b: 0.14117647058824},
{name: 'Vivid Reddish Purple', r: 0.52941176470588, g: 0, b: 0.45490196078431},
{name: 'Strong Reddish Purple', r: 0.61960784313725, g: 0.30980392156863, b: 0.53333333333333},
{name: 'Deep Reddish Purple', r: 0.43921568627451, g: 0.16078431372549, b: 0.38823529411765},
{name: 'Very Deep Reddish Purple', r: 0.32941176470588, g: 0.098039215686275, b: 0.30588235294118},
{name: 'Light Reddish Purple', r: 0.71764705882353, g: 0.51764705882353, b: 0.65490196078431},
{name: 'Moderate Reddish Purple', r: 0.56862745098039, g: 0.36078431372549, b: 0.51372549019608},
{name: 'Dark Reddish Purple', r: 0.36470588235294, g: 0.22352941176471, b: 0.32941176470588},
{name: 'Very Dark Reddish Purple', r: 0.20392156862745, g: 0.090196078431373, b: 0.1921568627451},
{name: 'Pale Reddish Purple', r: 0.66666666666667, g: 0.54117647058824, b: 0.61960784313725},
{name: 'Grayish Reddish Purple', r: 0.51372549019608, g: 0.3921568627451, b: 0.47450980392157},
{name: 'Brilliant Purplish Pink', r: 1, g: 0.7843137254902, b: 0.83921568627451},
{name: 'Strong Purplish Pink', r: 0.90196078431373, g: 0.56078431372549, b: 0.67450980392157},
{name: 'Deep Purplish Pink', r: 0.87058823529412, g: 0.43529411764706, b: 0.63137254901961},
{name: 'Light Purplish Pink', r: 0.93725490196078, g: 0.73333333333333, b: 0.8},
{name: 'Moderate Purplish Pink', r: 0.83529411764706, g: 0.5921568627451, b: 0.68235294117647},
{name: 'Dark Purplish Pink', r: 0.75686274509804, g: 0.49411764705882, b: 0.56862745098039},
{name: 'Pale Purplish Pink', r: 0.90980392156863, g: 0.8, b: 0.84313725490196},
{name: 'Grayish Purplish Pink', r: 0.76470588235294, g: 0.65098039215686, b: 0.69411764705882},
{name: 'Vivid Purplish Red', r: 0.8078431372549, g: 0.27450980392157, b: 0.46274509803922},
{name: 'Strong Purplish Red', r: 0.70196078431373, g: 0.26666666666667, b: 0.42352941176471},
{name: 'Deep Purplish Red', r: 0.47058823529412, g: 0.094117647058824, b: 0.29019607843137},
{name: 'Very Deep Purplish Red', r: 0.32941176470588, g: 0.074509803921569, b: 0.23137254901961},
{name: 'Moderate Purplish Red', r: 0.65882352941176, g: 0.31764705882353, b: 0.43137254901961},
{name: 'Dark Purplish Red', r: 0.40392156862745, g: 0.1921568627451, b: 0.27843137254902},
{name: 'Very Dark Purplish Red', r: 0.21960784313725, g: 0.082352941176471, b: 0.17254901960784},
{name: 'Light Grayish Purplish Red', r: 0.68627450980392, g: 0.52549019607843, b: 0.55686274509804},
{name: 'Grayish Purplish Red', r: 0.56862745098039, g: 0.37254901960784, b: 0.42745098039216},
{name: 'White', r: 0.94901960784314, g: 0.95294117647059, b: 0.95686274509804},
{name: 'Light Gray', r: 0.72549019607843, g: 0.72156862745098, b: 0.70980392156863},
{name: 'Medium Gray', r: 0.51764705882353, g: 0.51764705882353, b: 0.50980392156863},
{name: 'Dark Gray', r: 0.33333333333333, g: 0.33333333333333, b: 0.33333333333333},
{name: 'Black', r: 0.13333333333333, g: 0.13333333333333, b: 0.13333333333333}
];
});

View File

@ -0,0 +1,942 @@
jQuery(function($) {
$.colorpicker.swatchesNames['pantone'] = 'Pantone';
$.colorpicker.swatches['pantone'] = [
{name: '100', r: 0.956862745098039, g: 0.929411764705882, b: 0.486274509803922},
{name: '101', r: 0.956862745098039, g: 0.929411764705882, b: 0.27843137254902},
{name: '102', r: 0.976470588235294, g: 0.909803921568627, b: 0.0784313725490196},
{name: '103', r: 0.776470588235294, g: 0.67843137254902, b: 0.0588235294117647},
{name: '104', r: 0.67843137254902, g: 0.607843137254902, b: 0.0470588235294118},
{name: '105', r: 0.509803921568627, g: 0.458823529411765, b: 0.0588235294117647},
{name: '106', r: 0.968627450980392, g: 0.909803921568627, b: 0.349019607843137},
{name: '107', r: 0.976470588235294, g: 0.898039215686275, b: 0.149019607843137},
{name: '108', r: 0.976470588235294, g: 0.866666666666667, b: 0.0862745098039216},
{name: '109', r: 0.976470588235294, g: 0.83921568627451, b: 0.0862745098039216},
{name: '110', r: 0.847058823529412, g: 0.709803921568627, b: 0.0666666666666667},
{name: '111', r: 0.666666666666667, g: 0.576470588235294, b: 0.0392156862745098},
{name: '112', r: 0.6, g: 0.517647058823529, b: 0.0392156862745098},
{name: '113', r: 0.976470588235294, g: 0.898039215686275, b: 0.356862745098039},
{name: '114', r: 0.976470588235294, g: 0.886274509803922, b: 0.298039215686275},
{name: '115', r: 0.976470588235294, g: 0.87843137254902, b: 0.298039215686275},
{name: '116', r: 0.988235294117647, g: 0.819607843137255, b: 0.0862745098039216},
{name: '116 2X', r: 0.968627450980392, g: 0.709803921568627, b: 0.0470588235294118},
{name: '117', r: 0.776470588235294, g: 0.627450980392157, b: 0.0470588235294118},
{name: '118', r: 0.666666666666667, g: 0.556862745098039, b: 0.0392156862745098},
{name: '119', r: 0.537254901960784, g: 0.466666666666667, b: 0.0980392156862745},
{name: '120', r: 0.976470588235294, g: 0.886274509803922, b: 0.498039215686275},
{name: '1205', r: 0.968627450980392, g: 0.909803921568627, b: 0.666666666666667},
{name: '121', r: 0.976470588235294, g: 0.87843137254902, b: 0.43921568627451},
{name: '1215', r: 0.976470588235294, g: 0.87843137254902, b: 0.549019607843137},
{name: '122', r: 0.988235294117647, g: 0.847058823529412, b: 0.337254901960784},
{name: '1225', r: 1, g: 0.8, b: 0.286274509803922},
{name: '123', r: 1, g: 0.776470588235294, b: 0.117647058823529},
{name: '1235', r: 0.988235294117647, g: 0.709803921568627, b: 0.0784313725490196},
{name: '124', r: 0.87843137254902, g: 0.666666666666667, b: 0.0588235294117647},
{name: '1245', r: 0.749019607843137, g: 0.568627450980392, b: 0.0470588235294118},
{name: '125', r: 0.709803921568627, g: 0.549019607843137, b: 0.0392156862745098},
{name: '1255', r: 0.63921568627451, g: 0.498039215686275, b: 0.0784313725490196},
{name: '126', r: 0.63921568627451, g: 0.509803921568627, b: 0.0196078431372549},
{name: '1265', r: 0.486274509803922, g: 0.388235294117647, b: 0.0862745098039216},
{name: '127', r: 0.956862745098039, g: 0.886274509803922, b: 0.529411764705882},
{name: '128', r: 0.956862745098039, g: 0.858823529411765, b: 0.376470588235294},
{name: '129', r: 0.949019607843137, g: 0.819607843137255, b: 0.23921568627451},
{name: '130', r: 0.917647058823529, g: 0.686274509803922, b: 0.0588235294117647},
{name: '130 2X', r: 0.886274509803922, g: 0.568627450980392, b: 0},
{name: '131', r: 0.776470588235294, g: 0.576470588235294, b: 0.0392156862745098},
{name: '132', r: 0.619607843137255, g: 0.486274509803922, b: 0.0392156862745098},
{name: '133', r: 0.43921568627451, g: 0.356862745098039, b: 0.0392156862745098},
{name: '134', r: 1, g: 0.847058823529412, b: 0.498039215686275},
{name: '1345', r: 1, g: 0.83921568627451, b: 0.568627450980392},
{name: '135', r: 0.988235294117647, g: 0.788235294117647, b: 0.388235294117647},
{name: '1355', r: 0.988235294117647, g: 0.807843137254902, b: 0.529411764705882},
{name: '136', r: 0.988235294117647, g: 0.749019607843137, b: 0.286274509803922},
{name: '1365', r: 0.988235294117647, g: 0.729411764705882, b: 0.368627450980392},
{name: '137', r: 0.988235294117647, g: 0.63921568627451, b: 0.0666666666666667},
{name: '1375', r: 0.976470588235294, g: 0.607843137254902, b: 0.0470588235294118},
{name: '138', r: 0.847058823529412, g: 0.549019607843137, b: 0.00784313725490196},
{name: '1385', r: 0.8, g: 0.47843137254902, b: 0.00784313725490196},
{name: '139', r: 0.686274509803922, g: 0.458823529411765, b: 0.0196078431372549},
{name: '1395', r: 0.6, g: 0.376470588235294, b: 0.0274509803921569},
{name: '140', r: 0.47843137254902, g: 0.356862745098039, b: 0.0666666666666667},
{name: '1405', r: 0.419607843137255, g: 0.27843137254902, b: 0.0784313725490196},
{name: '141', r: 0.949019607843137, g: 0.807843137254902, b: 0.407843137254902},
{name: '142', r: 0.949019607843137, g: 0.749019607843137, b: 0.286274509803922},
{name: '143', r: 0.937254901960784, g: 0.698039215686274, b: 0.176470588235294},
{name: '144', r: 0.886274509803922, g: 0.549019607843137, b: 0.0196078431372549},
{name: '145', r: 0.776470588235294, g: 0.498039215686275, b: 0.0274509803921569},
{name: '146', r: 0.619607843137255, g: 0.419607843137255, b: 0.0196078431372549},
{name: '147', r: 0.447058823529412, g: 0.368627450980392, b: 0.149019607843137},
{name: '148', r: 1, g: 0.83921568627451, b: 0.607843137254902},
{name: '1485', r: 1, g: 0.717647058823529, b: 0.466666666666667},
{name: '149', r: 0.988235294117647, g: 0.8, b: 0.576470588235294},
{name: '1495', r: 1, g: 0.6, b: 0.247058823529412},
{name: '150', r: 0.988235294117647, g: 0.67843137254902, b: 0.337254901960784},
{name: '1505', r: 0.956862745098039, g: 0.486274509803922, b: 0},
{name: '151', r: 0.968627450980392, g: 0.498039215686275, b: 0},
{name: '152', r: 0.866666666666667, g: 0.458823529411765, b: 0},
{name: '1525', r: 0.709803921568627, g: 0.329411764705882, b: 0},
{name: '153', r: 0.737254901960784, g: 0.427450980392157, b: 0.0392156862745098},
{name: '1535', r: 0.549019607843137, g: 0.266666666666667, b: 0},
{name: '154', r: 0.6, g: 0.349019607843137, b: 0.0196078431372549},
{name: '1545', r: 0.27843137254902, g: 0.133333333333333, b: 0},
{name: '155', r: 0.956862745098039, g: 0.858823529411765, b: 0.666666666666667},
{name: '1555', r: 0.976470588235294, g: 0.749019607843137, b: 0.619607843137255},
{name: '156', r: 0.949019607843137, g: 0.776470588235294, b: 0.549019607843137},
{name: '1565', r: 0.988235294117647, g: 0.647058823529412, b: 0.466666666666667},
{name: '157', r: 0.929411764705882, g: 0.627450980392157, b: 0.309803921568627},
{name: '1575', r: 0.988235294117647, g: 0.529411764705882, b: 0.266666666666667},
{name: '158', r: 0.909803921568627, g: 0.458823529411765, b: 0.0666666666666667},
{name: '1585', r: 0.976470588235294, g: 0.419607843137255, b: 0.0274509803921569},
{name: '159', r: 0.776470588235294, g: 0.376470588235294, b: 0.0196078431372549},
{name: '1595', r: 0.819607843137255, g: 0.356862745098039, b: 0.0196078431372549},
{name: '160', r: 0.619607843137255, g: 0.329411764705882, b: 0.0392156862745098},
{name: '1605', r: 0.627450980392157, g: 0.309803921568627, b: 0.0666666666666667},
{name: '161', r: 0.388235294117647, g: 0.227450980392157, b: 0.0666666666666667},
{name: '1615', r: 0.517647058823529, g: 0.247058823529412, b: 0.0588235294117647},
{name: '162', r: 0.976470588235294, g: 0.776470588235294, b: 0.666666666666667},
{name: '1625', r: 0.976470588235294, g: 0.647058823529412, b: 0.549019607843137},
{name: '163', r: 0.988235294117647, g: 0.619607843137255, b: 0.43921568627451},
{name: '1635', r: 0.976470588235294, g: 0.556862745098039, b: 0.427450980392157},
{name: '164', r: 0.988235294117647, g: 0.498039215686275, b: 0.247058823529412},
{name: '1645', r: 0.976470588235294, g: 0.447058823529412, b: 0.258823529411765},
{name: '165', r: 0.976470588235294, g: 0.388235294117647, b: 0.00784313725490196},
{name: '165 2X', r: 0.917647058823529, g: 0.309803921568627, b: 0},
{name: '1655', r: 0.976470588235294, g: 0.337254901960784, b: 0.00784313725490196},
{name: '166', r: 0.866666666666667, g: 0.349019607843137, b: 0},
{name: '1665', r: 0.866666666666667, g: 0.309803921568627, b: 0.0196078431372549},
{name: '167', r: 0.737254901960784, g: 0.309803921568627, b: 0.0274509803921569},
{name: '1675', r: 0.647058823529412, g: 0.247058823529412, b: 0.0588235294117647},
{name: '168', r: 0.427450980392157, g: 0.188235294117647, b: 0.0666666666666667},
{name: '1685', r: 0.517647058823529, g: 0.207843137254902, b: 0.0666666666666667},
{name: '169', r: 0.976470588235294, g: 0.729411764705882, b: 0.666666666666667},
{name: '170', r: 0.976470588235294, g: 0.537254901960784, b: 0.447058823529412},
{name: '171', r: 0.976470588235294, g: 0.376470588235294, b: 0.227450980392157},
{name: '172', r: 0.968627450980392, g: 0.286274509803922, b: 0.00784313725490196},
{name: '173', r: 0.819607843137255, g: 0.266666666666667, b: 0.0784313725490196},
{name: '174', r: 0.576470588235294, g: 0.2, b: 0.0666666666666667},
{name: '175', r: 0.427450980392157, g: 0.2, b: 0.129411764705882},
{name: '176', r: 0.976470588235294, g: 0.686274509803922, b: 0.67843137254902},
{name: '1765', r: 0.976470588235294, g: 0.619607843137255, b: 0.63921568627451},
{name: '1767', r: 0.976470588235294, g: 0.698039215686274, b: 0.717647058823529},
{name: '177', r: 0.976470588235294, g: 0.509803921568627, b: 0.498039215686275},
{name: '1775', r: 0.976470588235294, g: 0.517647058823529, b: 0.556862745098039},
{name: '1777', r: 0.988235294117647, g: 0.4, b: 0.458823529411765},
{name: '178', r: 0.976470588235294, g: 0.368627450980392, b: 0.349019607843137},
{name: '1785', r: 0.988235294117647, g: 0.309803921568627, b: 0.349019607843137},
{name: '1787', r: 0.956862745098039, g: 0.247058823529412, b: 0.309803921568627},
{name: '1788', r: 0.937254901960784, g: 0.168627450980392, b: 0.176470588235294},
{name: '1788 2X', r: 0.83921568627451, g: 0.129411764705882, b: 0},
{name: '179', r: 0.886274509803922, g: 0.23921568627451, b: 0.156862745098039},
{name: '1795', r: 0.83921568627451, g: 0.156862745098039, b: 0.156862745098039},
{name: '1797', r: 0.8, g: 0.176470588235294, b: 0.188235294117647},
{name: '180', r: 0.756862745098039, g: 0.219607843137255, b: 0.156862745098039},
{name: '1805', r: 0.686274509803922, g: 0.149019607843137, b: 0.149019607843137},
{name: '1807', r: 0.627450980392157, g: 0.188235294117647, b: 0.2},
{name: '181', r: 0.486274509803922, g: 0.176470588235294, b: 0.137254901960784},
{name: '1810', r: 0.486274509803922, g: 0.129411764705882, b: 0.117647058823529},
{name: '1817', r: 0.356862745098039, g: 0.176470588235294, b: 0.156862745098039},
{name: '182', r: 0.976470588235294, g: 0.749019607843137, b: 0.756862745098039},
{name: '183', r: 0.988235294117647, g: 0.549019607843137, b: 0.6},
{name: '184', r: 0.988235294117647, g: 0.368627450980392, b: 0.447058823529412},
{name: '185', r: 0.909803921568627, g: 0.0666666666666667, b: 0.176470588235294},
{name: '185 2X', r: 0.819607843137255, g: 0.0862745098039216, b: 0},
{name: '186', r: 0.807843137254902, g: 0.0666666666666667, b: 0.149019607843137},
{name: '187', r: 0.686274509803922, g: 0.117647058823529, b: 0.176470588235294},
{name: '188', r: 0.486274509803922, g: 0.129411764705882, b: 0.156862745098039},
{name: '189', r: 1, g: 0.63921568627451, b: 0.698039215686274},
{name: '1895', r: 0.988235294117647, g: 0.749019607843137, b: 0.788235294117647},
{name: '190', r: 0.988235294117647, g: 0.458823529411765, b: 0.556862745098039},
{name: '1905', r: 0.988235294117647, g: 0.607843137254902, b: 0.698039215686274},
{name: '191', r: 0.956862745098039, g: 0.27843137254902, b: 0.419607843137255},
{name: '1915', r: 0.956862745098039, g: 0.329411764705882, b: 0.486274509803922},
{name: '192', r: 0.898039215686275, g: 0.0196078431372549, b: 0.227450980392157},
{name: '1925', r: 0.87843137254902, g: 0.0274509803921569, b: 0.27843137254902},
{name: '193', r: 0.768627450980392, g: 0, b: 0.262745098039216},
{name: '1935', r: 0.756862745098039, g: 0.0196078431372549, b: 0.219607843137255},
{name: '194', r: 0.6, g: 0.129411764705882, b: 0.207843137254902},
{name: '1945', r: 0.658823529411765, g: 0.0470588235294118, b: 0.207843137254902},
{name: '1955', r: 0.576470588235294, g: 0.0862745098039216, b: 0.219607843137255},
{name: '196', r: 0.980392156862745, g: 0.835294117647059, b: 0.882352941176471},
{name: '197', r: 0.964705882352941, g: 0.647058823529412, b: 0.745098039215686},
{name: '198', r: 0.937254901960784, g: 0.356862745098039, b: 0.517647058823529},
{name: '199', r: 0.627450980392157, g: 0.152941176470588, b: 0.294117647058824},
{name: '200', r: 0.768627450980392, g: 0.117647058823529, b: 0.227450980392157},
{name: '201', r: 0.63921568627451, g: 0.149019607843137, b: 0.219607843137255},
{name: '202', r: 0.549019607843137, g: 0.149019607843137, b: 0.2},
{name: '203', r: 0.949019607843137, g: 0.686274509803922, b: 0.756862745098039},
{name: '204', r: 0.929411764705882, g: 0.47843137254902, b: 0.619607843137255},
{name: '205', r: 0.898039215686275, g: 0.298039215686275, b: 0.486274509803922},
{name: '206', r: 0.827450980392157, g: 0.0196078431372549, b: 0.27843137254902},
{name: '207', r: 0.752941176470588, g: 0, b: 0.305882352941176},
{name: '208', r: 0.556862745098039, g: 0.137254901960784, b: 0.266666666666667},
{name: '209', r: 0.458823529411765, g: 0.149019607843137, b: 0.23921568627451},
{name: '210', r: 1, g: 0.627450980392157, b: 0.749019607843137},
{name: '211', r: 1, g: 0.466666666666667, b: 0.658823529411765},
{name: '212', r: 0.976470588235294, g: 0.309803921568627, b: 0.556862745098039},
{name: '213', r: 0.917647058823529, g: 0.0588235294117647, b: 0.419607843137255},
{name: '214', r: 0.8, g: 0.00784313725490196, b: 0.337254901960784},
{name: '215', r: 0.647058823529412, g: 0.0196078431372549, b: 0.266666666666667},
{name: '216', r: 0.486274509803922, g: 0.117647058823529, b: 0.247058823529412},
{name: '217', r: 0.956862745098039, g: 0.749019607843137, b: 0.819607843137255},
{name: '218', r: 0.929411764705882, g: 0.447058823529412, b: 0.666666666666667},
{name: '219', r: 0.886274509803922, g: 0.156862745098039, b: 0.509803921568627},
{name: '220', r: 0.666666666666667, g: 0, b: 0.309803921568627},
{name: '221', r: 0.576470588235294, g: 0, b: 0.258823529411765},
{name: '222', r: 0.43921568627451, g: 0.0980392156862745, b: 0.23921568627451},
{name: '223', r: 0.976470588235294, g: 0.576470588235294, b: 0.768627450980392},
{name: '224', r: 0.956862745098039, g: 0.419607843137255, b: 0.686274509803922},
{name: '225', r: 0.929411764705882, g: 0.156862745098039, b: 0.576470588235294},
{name: '226', r: 0.83921568627451, g: 0.00784313725490196, b: 0.43921568627451},
{name: '227', r: 0.67843137254902, g: 0, b: 0.356862745098039},
{name: '228', r: 0.549019607843137, g: 0, b: 0.298039215686275},
{name: '229', r: 0.427450980392157, g: 0.129411764705882, b: 0.247058823529412},
{name: '230', r: 1, g: 0.627450980392157, b: 0.8},
{name: '231', r: 0.988235294117647, g: 0.43921568627451, b: 0.729411764705882},
{name: '232', r: 0.956862745098039, g: 0.247058823529412, b: 0.647058823529412},
{name: '233', r: 0.807843137254902, g: 0, b: 0.486274509803922},
{name: '234', r: 0.666666666666667, g: 0, b: 0.4},
{name: '235', r: 0.556862745098039, g: 0.0196078431372549, b: 0.329411764705882},
{name: '236', r: 0.976470588235294, g: 0.686274509803922, b: 0.827450980392157},
{name: '2365', r: 0.968627450980392, g: 0.768627450980392, b: 0.847058823529412},
{name: '237', r: 0.956862745098039, g: 0.517647058823529, b: 0.768627450980392},
{name: '2375', r: 0.917647058823529, g: 0.419607843137255, b: 0.749019607843137},
{name: '238', r: 0.929411764705882, g: 0.309803921568627, b: 0.686274509803922},
{name: '2385', r: 0.858823529411765, g: 0.156862745098039, b: 0.647058823529412},
{name: '239', r: 0.87843137254902, g: 0.129411764705882, b: 0.619607843137255},
{name: '2395', r: 0.768627450980392, g: 0, b: 0.549019607843137},
{name: '240', r: 0.768627450980392, g: 0.0588235294117647, b: 0.537254901960784},
{name: '2405', r: 0.658823529411765, g: 0, b: 0.47843137254902},
{name: '241', r: 0.67843137254902, g: 0, b: 0.458823529411765},
{name: '2415', r: 0.607843137254902, g: 0, b: 0.43921568627451},
{name: '242', r: 0.486274509803922, g: 0.109803921568627, b: 0.317647058823529},
{name: '2425', r: 0.529411764705882, g: 0, b: 0.356862745098039},
{name: '243', r: 0.949019607843137, g: 0.729411764705882, b: 0.847058823529412},
{name: '244', r: 0.929411764705882, g: 0.627450980392157, b: 0.827450980392157},
{name: '245', r: 0.909803921568627, g: 0.498039215686275, b: 0.788235294117647},
{name: '246', r: 0.8, g: 0, b: 0.627450980392157},
{name: '247', r: 0.717647058823529, g: 0, b: 0.556862745098039},
{name: '248', r: 0.63921568627451, g: 0.0196078431372549, b: 0.498039215686275},
{name: '249', r: 0.498039215686275, g: 0.156862745098039, b: 0.376470588235294},
{name: '250', r: 0.929411764705882, g: 0.768627450980392, b: 0.866666666666667},
{name: '251', r: 0.886274509803922, g: 0.619607843137255, b: 0.83921568627451},
{name: '252', r: 0.827450980392157, g: 0.419607843137255, b: 0.776470588235294},
{name: '253', r: 0.686274509803922, g: 0.137254901960784, b: 0.647058823529412},
{name: '254', r: 0.627450980392157, g: 0.176470588235294, b: 0.588235294117647},
{name: '255', r: 0.466666666666667, g: 0.176470588235294, b: 0.419607843137255},
{name: '256', r: 0.898039215686275, g: 0.768627450980392, b: 0.83921568627451},
{name: '2562', r: 0.847058823529412, g: 0.658823529411765, b: 0.847058823529412},
{name: '2563', r: 0.819607843137255, g: 0.627450980392157, b: 0.8},
{name: '2567', r: 0.749019607843137, g: 0.576470588235294, b: 0.8},
{name: '257', r: 0.827450980392157, g: 0.647058823529412, b: 0.788235294117647},
{name: '2572', r: 0.776470588235294, g: 0.529411764705882, b: 0.819607843137255},
{name: '2573', r: 0.729411764705882, g: 0.486274509803922, b: 0.737254901960784},
{name: '2577', r: 0.666666666666667, g: 0.447058823529412, b: 0.749019607843137},
{name: '258', r: 0.607843137254902, g: 0.309803921568627, b: 0.588235294117647},
{name: '2582', r: 0.666666666666667, g: 0.27843137254902, b: 0.729411764705882},
{name: '2583', r: 0.619607843137255, g: 0.309803921568627, b: 0.647058823529412},
{name: '2587', r: 0.556862745098039, g: 0.27843137254902, b: 0.67843137254902},
{name: '259', r: 0.447058823529412, g: 0.0862745098039216, b: 0.419607843137255},
{name: '2592', r: 0.576470588235294, g: 0.0588235294117647, b: 0.647058823529412},
{name: '2593', r: 0.529411764705882, g: 0.168627450980392, b: 0.576470588235294},
{name: '2597', r: 0.4, g: 0, b: 0.549019607843137},
{name: '260', r: 0.407843137254902, g: 0.117647058823529, b: 0.356862745098039},
{name: '2602', r: 0.509803921568627, g: 0.0470588235294118, b: 0.556862745098039},
{name: '2603', r: 0.43921568627451, g: 0.0784313725490196, b: 0.47843137254902},
{name: '2607', r: 0.356862745098039, g: 0.00784313725490196, b: 0.47843137254902},
{name: '261', r: 0.368627450980392, g: 0.129411764705882, b: 0.329411764705882},
{name: '2612', r: 0.43921568627451, g: 0.117647058823529, b: 0.447058823529412},
{name: '2613', r: 0.4, g: 0.0666666666666667, b: 0.427450980392157},
{name: '2617', r: 0.337254901960784, g: 0.0470588235294118, b: 0.43921568627451},
{name: '262', r: 0.329411764705882, g: 0.137254901960784, b: 0.266666666666667},
{name: '2622', r: 0.376470588235294, g: 0.176470588235294, b: 0.349019607843137},
{name: '2623', r: 0.356862745098039, g: 0.0980392156862745, b: 0.368627450980392},
{name: '2627', r: 0.298039215686275, g: 0.0784313725490196, b: 0.368627450980392},
{name: '263', r: 0.87843137254902, g: 0.807843137254902, b: 0.87843137254902},
{name: '2635', r: 0.788235294117647, g: 0.67843137254902, b: 0.847058823529412},
{name: '264', r: 0.776470588235294, g: 0.666666666666667, b: 0.858823529411765},
{name: '2645', r: 0.709803921568627, g: 0.568627450980392, b: 0.819607843137255},
{name: '265', r: 0.588235294117647, g: 0.388235294117647, b: 0.768627450980392},
{name: '2655', r: 0.607843137254902, g: 0.427450980392157, b: 0.776470588235294},
{name: '266', r: 0.427450980392157, g: 0.156862745098039, b: 0.666666666666667},
{name: '2665', r: 0.537254901960784, g: 0.309803921568627, b: 0.749019607843137},
{name: '267', r: 0.349019607843137, g: 0.0666666666666667, b: 0.556862745098039},
{name: '268', r: 0.309803921568627, g: 0.129411764705882, b: 0.43921568627451},
{name: '2685', r: 0.337254901960784, g: 0, b: 0.549019607843137},
{name: '269', r: 0.266666666666667, g: 0.137254901960784, b: 0.349019607843137},
{name: '2695', r: 0.266666666666667, g: 0.137254901960784, b: 0.368627450980392},
{name: '270', r: 0.729411764705882, g: 0.686274509803922, b: 0.827450980392157},
{name: '2705', r: 0.67843137254902, g: 0.619607843137255, b: 0.827450980392157},
{name: '2706', r: 0.819607843137255, g: 0.807843137254902, b: 0.866666666666667},
{name: '2707', r: 0.749019607843137, g: 0.819607843137255, b: 0.898039215686275},
{name: '2708', r: 0.686274509803922, g: 0.737254901960784, b: 0.858823529411765},
{name: '271', r: 0.619607843137255, g: 0.568627450980392, b: 0.776470588235294},
{name: '2715', r: 0.576470588235294, g: 0.47843137254902, b: 0.8},
{name: '2716', r: 0.647058823529412, g: 0.627450980392157, b: 0.83921568627451},
{name: '2717', r: 0.647058823529412, g: 0.729411764705882, b: 0.87843137254902},
{name: '2718', r: 0.356862745098039, g: 0.466666666666667, b: 0.8},
{name: '272', r: 0.537254901960784, g: 0.466666666666667, b: 0.729411764705882},
{name: '2725', r: 0.447058823529412, g: 0.317647058823529, b: 0.737254901960784},
{name: '2726', r: 0.4, g: 0.337254901960784, b: 0.737254901960784},
{name: '2727', r: 0.368627450980392, g: 0.407843137254902, b: 0.768627450980392},
{name: '2728', r: 0.188235294117647, g: 0.266666666666667, b: 0.709803921568627},
{name: '273', r: 0.219607843137255, g: 0.0980392156862745, b: 0.47843137254902},
{name: '2735', r: 0.309803921568627, g: 0, b: 0.576470588235294},
{name: '2736', r: 0.286274509803922, g: 0.188235294117647, b: 0.67843137254902},
{name: '2738', r: 0.176470588235294, g: 0, b: 0.556862745098039},
{name: '274', r: 0.168627450980392, g: 0.0666666666666667, b: 0.4},
{name: '2745', r: 0.247058823529412, g: 0, b: 0.466666666666667},
{name: '2746', r: 0.247058823529412, g: 0.156862745098039, b: 0.576470588235294},
{name: '2747', r: 0.109803921568627, g: 0.0784313725490196, b: 0.419607843137255},
{name: '2748', r: 0.117647058823529, g: 0.109803921568627, b: 0.466666666666667},
{name: '275', r: 0.149019607843137, g: 0.0588235294117647, b: 0.329411764705882},
{name: '2755', r: 0.207843137254902, g: 0, b: 0.427450980392157},
{name: '2756', r: 0.2, g: 0.156862745098039, b: 0.458823529411765},
{name: '2757', r: 0.0784313725490196, g: 0.0862745098039216, b: 0.329411764705882},
{name: '2758', r: 0.0980392156862745, g: 0.129411764705882, b: 0.407843137254902},
{name: '276', r: 0.168627450980392, g: 0.129411764705882, b: 0.27843137254902},
{name: '2765', r: 0.168627450980392, g: 0.0470588235294118, b: 0.337254901960784},
{name: '2766', r: 0.168627450980392, g: 0.149019607843137, b: 0.356862745098039},
{name: '2767', r: 0.0784313725490196, g: 0.129411764705882, b: 0.23921568627451},
{name: '2768', r: 0.0666666666666667, g: 0.129411764705882, b: 0.317647058823529},
{name: '277', r: 0.709803921568627, g: 0.819607843137255, b: 0.909803921568627},
{name: '278', r: 0.6, g: 0.729411764705882, b: 0.866666666666667},
{name: '279', r: 0.4, g: 0.537254901960784, b: 0.8},
{name: '280', r: 0, g: 0.168627450980392, b: 0.498039215686275},
{name: '281', r: 0, g: 0.156862745098039, b: 0.407843137254902},
{name: '282', r: 0, g: 0.149019607843137, b: 0.329411764705882},
{name: '283', r: 0.607843137254902, g: 0.768627450980392, b: 0.886274509803922},
{name: '284', r: 0.458823529411765, g: 0.666666666666667, b: 0.858823529411765},
{name: '285', r: 0.227450980392157, g: 0.458823529411765, b: 0.768627450980392},
{name: '286', r: 0, g: 0.219607843137255, b: 0.658823529411765},
{name: '287', r: 0, g: 0.219607843137255, b: 0.576470588235294},
{name: '288', r: 0, g: 0.2, b: 0.498039215686275},
{name: '289', r: 0, g: 0.149019607843137, b: 0.286274509803922},
{name: '290', r: 0.768627450980392, g: 0.847058823529412, b: 0.886274509803922},
{name: '2905', r: 0.576470588235294, g: 0.776470588235294, b: 0.87843137254902},
{name: '291', r: 0.658823529411765, g: 0.807843137254902, b: 0.886274509803922},
{name: '2915', r: 0.376470588235294, g: 0.686274509803922, b: 0.866666666666667},
{name: '292', r: 0.458823529411765, g: 0.698039215686274, b: 0.866666666666667},
{name: '2925', r: 0, g: 0.556862745098039, b: 0.83921568627451},
{name: '293', r: 0, g: 0.317647058823529, b: 0.729411764705882},
{name: '2935', r: 0, g: 0.356862745098039, b: 0.749019607843137},
{name: '294', r: 0, g: 0.247058823529412, b: 0.529411764705882},
{name: '2945', r: 0, g: 0.329411764705882, b: 0.627450980392157},
{name: '295', r: 0, g: 0.219607843137255, b: 0.419607843137255},
{name: '2955', r: 0, g: 0.23921568627451, b: 0.419607843137255},
{name: '296', r: 0, g: 0.176470588235294, b: 0.27843137254902},
{name: '2965', r: 0, g: 0.2, b: 0.298039215686275},
{name: '297', r: 0.509803921568627, g: 0.776470588235294, b: 0.886274509803922},
{name: '2975', r: 0.729411764705882, g: 0.87843137254902, b: 0.886274509803922},
{name: '298', r: 0.317647058823529, g: 0.709803921568627, b: 0.87843137254902},
{name: '2985', r: 0.317647058823529, g: 0.749019607843137, b: 0.886274509803922},
{name: '299', r: 0, g: 0.63921568627451, b: 0.866666666666667},
{name: '2995', r: 0, g: 0.647058823529412, b: 0.858823529411765},
{name: '300', r: 0, g: 0.447058823529412, b: 0.776470588235294},
{name: '3005', r: 0, g: 0.517647058823529, b: 0.788235294117647},
{name: '301', r: 0, g: 0.356862745098039, b: 0.6},
{name: '3015', r: 0, g: 0.43921568627451, b: 0.619607843137255},
{name: '302', r: 0, g: 0.309803921568627, b: 0.427450980392157},
{name: '3025', r: 0, g: 0.329411764705882, b: 0.419607843137255},
{name: '303', r: 0, g: 0.247058823529412, b: 0.329411764705882},
{name: '3035', r: 0, g: 0.266666666666667, b: 0.329411764705882},
{name: '304', r: 0.647058823529412, g: 0.866666666666667, b: 0.886274509803922},
{name: '305', r: 0.43921568627451, g: 0.807843137254902, b: 0.886274509803922},
{name: '306', r: 0, g: 0.737254901960784, b: 0.886274509803922},
{name: '306 2X', r: 0, g: 0.63921568627451, b: 0.819607843137255},
{name: '307', r: 0, g: 0.47843137254902, b: 0.647058823529412},
{name: '308', r: 0, g: 0.376470588235294, b: 0.486274509803922},
{name: '309', r: 0, g: 0.247058823529412, b: 0.286274509803922},
{name: '310', r: 0.447058823529412, g: 0.819607843137255, b: 0.866666666666667},
{name: '3105', r: 0.498039215686275, g: 0.83921568627451, b: 0.858823529411765},
{name: '311', r: 0.156862745098039, g: 0.768627450980392, b: 0.847058823529412},
{name: '3115', r: 0.176470588235294, g: 0.776470588235294, b: 0.83921568627451},
{name: '312', r: 0, g: 0.67843137254902, b: 0.776470588235294},
{name: '3125', r: 0, g: 0.717647058823529, b: 0.776470588235294},
{name: '313', r: 0, g: 0.6, b: 0.709803921568627},
{name: '3135', r: 0, g: 0.607843137254902, b: 0.666666666666667},
{name: '314', r: 0, g: 0.509803921568627, b: 0.607843137254902},
{name: '3145', r: 0, g: 0.517647058823529, b: 0.556862745098039},
{name: '315', r: 0, g: 0.419607843137255, b: 0.466666666666667},
{name: '3155', r: 0, g: 0.427450980392157, b: 0.458823529411765},
{name: '316', r: 0, g: 0.286274509803922, b: 0.309803921568627},
{name: '3165', r: 0, g: 0.337254901960784, b: 0.356862745098039},
{name: '317', r: 0.788235294117647, g: 0.909803921568627, b: 0.866666666666667},
{name: '318', r: 0.576470588235294, g: 0.866666666666667, b: 0.858823529411765},
{name: '319', r: 0.298039215686275, g: 0.807843137254902, b: 0.819607843137255},
{name: '320', r: 0, g: 0.619607843137255, b: 0.627450980392157},
{name: '320 2X', r: 0, g: 0.498039215686275, b: 0.509803921568627},
{name: '321', r: 0, g: 0.529411764705882, b: 0.537254901960784},
{name: '322', r: 0, g: 0.447058823529412, b: 0.447058823529412},
{name: '323', r: 0, g: 0.4, b: 0.388235294117647},
{name: '324', r: 0.666666666666667, g: 0.866666666666667, b: 0.83921568627451},
{name: '3242', r: 0.529411764705882, g: 0.866666666666667, b: 0.819607843137255},
{name: '3245', r: 0.549019607843137, g: 0.87843137254902, b: 0.819607843137255},
{name: '3248', r: 0.47843137254902, g: 0.827450980392157, b: 0.756862745098039},
{name: '325', r: 0.337254901960784, g: 0.788235294117647, b: 0.756862745098039},
{name: '3252', r: 0.337254901960784, g: 0.83921568627451, b: 0.788235294117647},
{name: '3255', r: 0.27843137254902, g: 0.83921568627451, b: 0.756862745098039},
{name: '3258', r: 0.207843137254902, g: 0.768627450980392, b: 0.686274509803922},
{name: '326', r: 0, g: 0.698039215686274, b: 0.666666666666667},
{name: '3262', r: 0, g: 0.756862745098039, b: 0.709803921568627},
{name: '3265', r: 0, g: 0.776470588235294, b: 0.698039215686274},
{name: '3268', r: 0, g: 0.686274509803922, b: 0.6},
{name: '327', r: 0, g: 0.549019607843137, b: 0.509803921568627},
{name: '327 2X', r: 0, g: 0.537254901960784, b: 0.466666666666667},
{name: '3272', r: 0, g: 0.666666666666667, b: 0.619607843137255},
{name: '3275', r: 0, g: 0.698039215686274, b: 0.627450980392157},
{name: '3278', r: 0, g: 0.607843137254902, b: 0.517647058823529},
{name: '328', r: 0, g: 0.466666666666667, b: 0.43921568627451},
{name: '3282', r: 0, g: 0.549019607843137, b: 0.509803921568627},
{name: '3285', r: 0, g: 0.6, b: 0.529411764705882},
{name: '3288', r: 0, g: 0.509803921568627, b: 0.43921568627451},
{name: '329', r: 0, g: 0.427450980392157, b: 0.4},
{name: '3292', r: 0, g: 0.376470588235294, b: 0.337254901960784},
{name: '3295', r: 0, g: 0.509803921568627, b: 0.447058823529412},
{name: '3298', r: 0, g: 0.419607843137255, b: 0.356862745098039},
{name: '330', r: 0, g: 0.349019607843137, b: 0.317647058823529},
{name: '3302', r: 0, g: 0.286274509803922, b: 0.247058823529412},
{name: '3305', r: 0, g: 0.309803921568627, b: 0.258823529411765},
{name: '3308', r: 0, g: 0.266666666666667, b: 0.219607843137255},
{name: '331', r: 0.729411764705882, g: 0.917647058823529, b: 0.83921568627451},
{name: '332', r: 0.627450980392157, g: 0.898039215686275, b: 0.807843137254902},
{name: '333', r: 0.368627450980392, g: 0.866666666666667, b: 0.756862745098039},
{name: '334', r: 0, g: 0.6, b: 0.486274509803922},
{name: '335', r: 0, g: 0.486274509803922, b: 0.4},
{name: '336', r: 0, g: 0.407843137254902, b: 0.329411764705882},
{name: '337', r: 0.607843137254902, g: 0.858823529411765, b: 0.756862745098039},
{name: '3375', r: 0.556862745098039, g: 0.886274509803922, b: 0.737254901960784},
{name: '338', r: 0.47843137254902, g: 0.819607843137255, b: 0.709803921568627},
{name: '3385', r: 0.329411764705882, g: 0.847058823529412, b: 0.658823529411765},
{name: '339', r: 0, g: 0.698039215686274, b: 0.549019607843137},
{name: '3395', r: 0, g: 0.788235294117647, b: 0.576470588235294},
{name: '340', r: 0, g: 0.6, b: 0.466666666666667},
{name: '3405', r: 0, g: 0.698039215686274, b: 0.47843137254902},
{name: '341', r: 0, g: 0.47843137254902, b: 0.368627450980392},
{name: '3415', r: 0, g: 0.486274509803922, b: 0.349019607843137},
{name: '342', r: 0, g: 0.419607843137255, b: 0.329411764705882},
{name: '3425', r: 0, g: 0.407843137254902, b: 0.27843137254902},
{name: '343', r: 0, g: 0.337254901960784, b: 0.247058823529412},
{name: '3435', r: 0.00784313725490196, g: 0.286274509803922, b: 0.188235294117647},
{name: '344', r: 0.709803921568627, g: 0.886274509803922, b: 0.749019607843137},
{name: '345', r: 0.588235294117647, g: 0.847058823529412, b: 0.686274509803922},
{name: '346', r: 0.43921568627451, g: 0.807843137254902, b: 0.607843137254902},
{name: '347', r: 0, g: 0.619607843137255, b: 0.376470588235294},
{name: '348', r: 0, g: 0.529411764705882, b: 0.317647058823529},
{name: '349', r: 0, g: 0.419607843137255, b: 0.247058823529412},
{name: '350', r: 0.137254901960784, g: 0.309803921568627, b: 0.2},
{name: '351', r: 0.709803921568627, g: 0.909803921568627, b: 0.749019607843137},
{name: '352', r: 0.6, g: 0.898039215686275, b: 0.698039215686274},
{name: '353', r: 0.517647058823529, g: 0.886274509803922, b: 0.658823529411765},
{name: '354', r: 0, g: 0.717647058823529, b: 0.376470588235294},
{name: '355', r: 0, g: 0.619607843137255, b: 0.286274509803922},
{name: '356', r: 0, g: 0.47843137254902, b: 0.23921568627451},
{name: '357', r: 0.129411764705882, g: 0.356862745098039, b: 0.2},
{name: '358', r: 0.666666666666667, g: 0.866666666666667, b: 0.588235294117647},
{name: '359', r: 0.627450980392157, g: 0.858823529411765, b: 0.556862745098039},
{name: '360', r: 0.376470588235294, g: 0.776470588235294, b: 0.349019607843137},
{name: '361', r: 0.117647058823529, g: 0.709803921568627, b: 0.227450980392157},
{name: '362', r: 0.2, g: 0.619607843137255, b: 0.207843137254902},
{name: '363', r: 0.23921568627451, g: 0.556862745098039, b: 0.2},
{name: '364', r: 0.227450980392157, g: 0.466666666666667, b: 0.156862745098039},
{name: '365', r: 0.827450980392157, g: 0.909803921568627, b: 0.63921568627451},
{name: '366', r: 0.768627450980392, g: 0.898039215686275, b: 0.556862745098039},
{name: '367', r: 0.666666666666667, g: 0.866666666666667, b: 0.427450980392157},
{name: '368', r: 0.356862745098039, g: 0.749019607843137, b: 0.129411764705882},
{name: '368 2X', r: 0, g: 0.619607843137255, b: 0.0588235294117647},
{name: '369', r: 0.337254901960784, g: 0.666666666666667, b: 0.109803921568627},
{name: '370', r: 0.337254901960784, g: 0.556862745098039, b: 0.0784313725490196},
{name: '371', r: 0.337254901960784, g: 0.419607843137255, b: 0.129411764705882},
{name: '372', r: 0.847058823529412, g: 0.929411764705882, b: 0.588235294117647},
{name: '373', r: 0.807843137254902, g: 0.917647058823529, b: 0.509803921568627},
{name: '374', r: 0.729411764705882, g: 0.909803921568627, b: 0.376470588235294},
{name: '375', r: 0.549019607843137, g: 0.83921568627451, b: 0},
{name: '375 2X', r: 0.329411764705882, g: 0.737254901960784, b: 0},
{name: '376', r: 0.498039215686275, g: 0.729411764705882, b: 0},
{name: '377', r: 0.43921568627451, g: 0.576470588235294, b: 0.00784313725490196},
{name: '378', r: 0.337254901960784, g: 0.388235294117647, b: 0.0784313725490196},
{name: '379', r: 0.87843137254902, g: 0.917647058823529, b: 0.407843137254902},
{name: '380', r: 0.83921568627451, g: 0.898039215686275, b: 0.258823529411765},
{name: '381', r: 0.8, g: 0.886274509803922, b: 0.149019607843137},
{name: '382', r: 0.729411764705882, g: 0.847058823529412, b: 0.0392156862745098},
{name: '382 2X', r: 0.619607843137255, g: 0.768627450980392, b: 0},
{name: '383', r: 0.63921568627451, g: 0.686274509803922, b: 0.0274509803921569},
{name: '384', r: 0.576470588235294, g: 0.6, b: 0.0196078431372549},
{name: '385', r: 0.43921568627451, g: 0.43921568627451, b: 0.0784313725490196},
{name: '386', r: 0.909803921568627, g: 0.929411764705882, b: 0.376470588235294},
{name: '387', r: 0.87843137254902, g: 0.929411764705882, b: 0.266666666666667},
{name: '388', r: 0.83921568627451, g: 0.909803921568627, b: 0.0588235294117647},
{name: '389', r: 0.807843137254902, g: 0.87843137254902, b: 0.0274509803921569},
{name: '390', r: 0.729411764705882, g: 0.768627450980392, b: 0.0196078431372549},
{name: '391', r: 0.619607843137255, g: 0.619607843137255, b: 0.0274509803921569},
{name: '392', r: 0.517647058823529, g: 0.509803921568627, b: 0.0196078431372549},
{name: '393', r: 0.949019607843137, g: 0.937254901960784, b: 0.529411764705882},
{name: '3935', r: 0.949019607843137, g: 0.929411764705882, b: 0.427450980392157},
{name: '394', r: 0.917647058823529, g: 0.929411764705882, b: 0.207843137254902},
{name: '3945', r: 0.937254901960784, g: 0.917647058823529, b: 0.0274509803921569},
{name: '395', r: 0.898039215686275, g: 0.909803921568627, b: 0.0666666666666667},
{name: '3955', r: 0.929411764705882, g: 0.886274509803922, b: 0.0666666666666667},
{name: '396', r: 0.87843137254902, g: 0.886274509803922, b: 0.0470588235294118},
{name: '3965', r: 0.909803921568627, g: 0.866666666666667, b: 0.0666666666666667},
{name: '397', r: 0.756862745098039, g: 0.749019607843137, b: 0.0392156862745098},
{name: '3975', r: 0.709803921568627, g: 0.658823529411765, b: 0.0470588235294118},
{name: '398', r: 0.686274509803922, g: 0.658823529411765, b: 0.0392156862745098},
{name: '3985', r: 0.6, g: 0.549019607843137, b: 0.0392156862745098},
{name: '399', r: 0.6, g: 0.556862745098039, b: 0.0274509803921569},
{name: '3995', r: 0.427450980392157, g: 0.376470588235294, b: 0.00784313725490196},
{name: '400', r: 0.819607843137255, g: 0.776470588235294, b: 0.709803921568627},
{name: '401', r: 0.756862745098039, g: 0.709803921568627, b: 0.647058823529412},
{name: '402', r: 0.686274509803922, g: 0.647058823529412, b: 0.576470588235294},
{name: '403', r: 0.6, g: 0.549019607843137, b: 0.486274509803922},
{name: '404', r: 0.509803921568627, g: 0.458823529411765, b: 0.4},
{name: '405', r: 0.419607843137255, g: 0.368627450980392, b: 0.309803921568627},
{name: '406', r: 0.807843137254902, g: 0.756862745098039, b: 0.709803921568627},
{name: '408', r: 0.658823529411765, g: 0.6, b: 0.549019607843137},
{name: '409', r: 0.6, g: 0.537254901960784, b: 0.486274509803922},
{name: '410', r: 0.486274509803922, g: 0.427450980392157, b: 0.388235294117647},
{name: '411', r: 0.4, g: 0.349019607843137, b: 0.298039215686275},
{name: '412', r: 0.23921568627451, g: 0.188235294117647, b: 0.156862745098039},
{name: '413', r: 0.776470588235294, g: 0.756862745098039, b: 0.698039215686274},
{name: '414', r: 0.709803921568627, g: 0.686274509803922, b: 0.627450980392157},
{name: '415', r: 0.63921568627451, g: 0.619607843137255, b: 0.549019607843137},
{name: '416', r: 0.556862745098039, g: 0.549019607843137, b: 0.47843137254902},
{name: '417', r: 0.466666666666667, g: 0.447058823529412, b: 0.388235294117647},
{name: '418', r: 0.376470588235294, g: 0.368627450980392, b: 0.309803921568627},
{name: '419', r: 0.156862745098039, g: 0.156862745098039, b: 0.129411764705882},
{name: '420', r: 0.819607843137255, g: 0.8, b: 0.749019607843137},
{name: '421', r: 0.749019607843137, g: 0.729411764705882, b: 0.686274509803922},
{name: '422', r: 0.686274509803922, g: 0.666666666666667, b: 0.63921568627451},
{name: '423', r: 0.588235294117647, g: 0.576470588235294, b: 0.556862745098039},
{name: '424', r: 0.509803921568627, g: 0.498039215686275, b: 0.466666666666667},
{name: '425', r: 0.376470588235294, g: 0.376470588235294, b: 0.356862745098039},
{name: '426', r: 0.168627450980392, g: 0.168627450980392, b: 0.156862745098039},
{name: '427', r: 0.866666666666667, g: 0.858823529411765, b: 0.819607843137255},
{name: '428', r: 0.819607843137255, g: 0.807843137254902, b: 0.776470588235294},
{name: '429', r: 0.67843137254902, g: 0.686274509803922, b: 0.666666666666667},
{name: '430', r: 0.568627450980392, g: 0.588235294117647, b: 0.576470588235294},
{name: '431', r: 0.4, g: 0.427450980392157, b: 0.43921568627451},
{name: '432', r: 0.266666666666667, g: 0.309803921568627, b: 0.317647058823529},
{name: '433', r: 0.188235294117647, g: 0.219607843137255, b: 0.227450980392157},
{name: '433 2X', r: 0.0392156862745098, g: 0.0470588235294118, b: 0.0666666666666667},
{name: '434', r: 0.87843137254902, g: 0.819607843137255, b: 0.776470588235294},
{name: '435', r: 0.827450980392157, g: 0.749019607843137, b: 0.717647058823529},
{name: '436', r: 0.737254901960784, g: 0.647058823529412, b: 0.619607843137255},
{name: '437', r: 0.549019607843137, g: 0.43921568627451, b: 0.419607843137255},
{name: '438', r: 0.349019607843137, g: 0.247058823529412, b: 0.23921568627451},
{name: '439', r: 0.286274509803922, g: 0.207843137254902, b: 0.2},
{name: '440', r: 0.247058823529412, g: 0.188235294117647, b: 0.168627450980392},
{name: '441', r: 0.819607843137255, g: 0.819607843137255, b: 0.776470588235294},
{name: '442', r: 0.729411764705882, g: 0.749019607843137, b: 0.717647058823529},
{name: '443', r: 0.63921568627451, g: 0.658823529411765, b: 0.63921568627451},
{name: '444', r: 0.537254901960784, g: 0.556862745098039, b: 0.549019607843137},
{name: '445', r: 0.337254901960784, g: 0.349019607843137, b: 0.349019607843137},
{name: '446', r: 0.286274509803922, g: 0.298039215686275, b: 0.286274509803922},
{name: '447', r: 0.247058823529412, g: 0.247058823529412, b: 0.219607843137255},
{name: '448', r: 0.329411764705882, g: 0.27843137254902, b: 0.176470588235294},
{name: '4485', r: 0.376470588235294, g: 0.298039215686275, b: 0.0666666666666667},
{name: '449', r: 0.329411764705882, g: 0.27843137254902, b: 0.149019607843137},
{name: '4495', r: 0.529411764705882, g: 0.458823529411765, b: 0.188235294117647},
{name: '450', r: 0.376470588235294, g: 0.329411764705882, b: 0.168627450980392},
{name: '4505', r: 0.627450980392157, g: 0.568627450980392, b: 0.317647058823529},
{name: '451', r: 0.67843137254902, g: 0.627450980392157, b: 0.47843137254902},
{name: '4515', r: 0.737254901960784, g: 0.67843137254902, b: 0.458823529411765},
{name: '452', r: 0.768627450980392, g: 0.717647058823529, b: 0.588235294117647},
{name: '4525', r: 0.8, g: 0.749019607843137, b: 0.556862745098039},
{name: '453', r: 0.83921568627451, g: 0.8, b: 0.686274509803922},
{name: '4535', r: 0.858823529411765, g: 0.807843137254902, b: 0.647058823529412},
{name: '454', r: 0.886274509803922, g: 0.847058823529412, b: 0.749019607843137},
{name: '4545', r: 0.898039215686275, g: 0.858823529411765, b: 0.729411764705882},
{name: '455', r: 0.4, g: 0.337254901960784, b: 0.0784313725490196},
{name: '456', r: 0.6, g: 0.529411764705882, b: 0.0784313725490196},
{name: '457', r: 0.709803921568627, g: 0.607843137254902, b: 0.0470588235294118},
{name: '458', r: 0.866666666666667, g: 0.8, b: 0.419607843137255},
{name: '459', r: 0.886274509803922, g: 0.83921568627451, b: 0.486274509803922},
{name: '460', r: 0.917647058823529, g: 0.866666666666667, b: 0.588235294117647},
{name: '461', r: 0.929411764705882, g: 0.898039215686275, b: 0.67843137254902},
{name: '462', r: 0.356862745098039, g: 0.27843137254902, b: 0.137254901960784},
{name: '4625', r: 0.27843137254902, g: 0.137254901960784, b: 0.0666666666666667},
{name: '463', r: 0.458823529411765, g: 0.329411764705882, b: 0.149019607843137},
{name: '4635', r: 0.549019607843137, g: 0.349019607843137, b: 0.2},
{name: '464', r: 0.529411764705882, g: 0.376470588235294, b: 0.156862745098039},
{name: '464 2X', r: 0.43921568627451, g: 0.258823529411765, b: 0.0784313725490196},
{name: '4645', r: 0.698039215686274, g: 0.509803921568627, b: 0.376470588235294},
{name: '465', r: 0.756862745098039, g: 0.658823529411765, b: 0.458823529411765},
{name: '4655', r: 0.768627450980392, g: 0.6, b: 0.466666666666667},
{name: '466', r: 0.819607843137255, g: 0.749019607843137, b: 0.568627450980392},
{name: '4665', r: 0.847058823529412, g: 0.709803921568627, b: 0.588235294117647},
{name: '467', r: 0.866666666666667, g: 0.8, b: 0.647058823529412},
{name: '4675', r: 0.898039215686275, g: 0.776470588235294, b: 0.666666666666667},
{name: '468', r: 0.886274509803922, g: 0.83921568627451, b: 0.709803921568627},
{name: '4685', r: 0.929411764705882, g: 0.827450980392157, b: 0.737254901960784},
{name: '469', r: 0.376470588235294, g: 0.2, b: 0.0666666666666667},
{name: '4695', r: 0.317647058823529, g: 0.149019607843137, b: 0.109803921568627},
{name: '470', r: 0.607843137254902, g: 0.309803921568627, b: 0.0980392156862745},
{name: '4705', r: 0.486274509803922, g: 0.317647058823529, b: 0.23921568627451},
{name: '471', r: 0.737254901960784, g: 0.368627450980392, b: 0.117647058823529},
{name: '471 2X', r: 0.63921568627451, g: 0.266666666666667, b: 0.00784313725490196},
{name: '4715', r: 0.6, g: 0.43921568627451, b: 0.356862745098039},
{name: '472', r: 0.917647058823529, g: 0.666666666666667, b: 0.47843137254902},
{name: '4725', r: 0.709803921568627, g: 0.568627450980392, b: 0.486274509803922},
{name: '473', r: 0.956862745098039, g: 0.768627450980392, b: 0.627450980392157},
{name: '4735', r: 0.8, g: 0.686274509803922, b: 0.607843137254902},
{name: '474', r: 0.956862745098039, g: 0.8, b: 0.666666666666667},
{name: '4745', r: 0.847058823529412, g: 0.749019607843137, b: 0.666666666666667},
{name: '475', r: 0.968627450980392, g: 0.827450980392157, b: 0.709803921568627},
{name: '4755', r: 0.886274509803922, g: 0.8, b: 0.729411764705882},
{name: '476', r: 0.349019607843137, g: 0.23921568627451, b: 0.168627450980392},
{name: '477', r: 0.388235294117647, g: 0.219607843137255, b: 0.149019607843137},
{name: '478', r: 0.47843137254902, g: 0.247058823529412, b: 0.156862745098039},
{name: '479', r: 0.686274509803922, g: 0.537254901960784, b: 0.43921568627451},
{name: '480', r: 0.827450980392157, g: 0.717647058823529, b: 0.63921568627451},
{name: '481', r: 0.87843137254902, g: 0.8, b: 0.729411764705882},
{name: '482', r: 0.898039215686275, g: 0.827450980392157, b: 0.756862745098039},
{name: '483', r: 0.419607843137255, g: 0.188235294117647, b: 0.129411764705882},
{name: '484', r: 0.607843137254902, g: 0.188235294117647, b: 0.109803921568627},
{name: '485', r: 0.847058823529412, g: 0.117647058823529, b: 0.0196078431372549},
{name: '485 2X', r: 0.8, g: 0.0470588235294118, b: 0},
{name: '486', r: 0.929411764705882, g: 0.619607843137255, b: 0.517647058823529},
{name: '487', r: 0.937254901960784, g: 0.709803921568627, b: 0.627450980392157},
{name: '488', r: 0.949019607843137, g: 0.768627450980392, b: 0.686274509803922},
{name: '489', r: 0.949019607843137, g: 0.819607843137255, b: 0.749019607843137},
{name: '490', r: 0.356862745098039, g: 0.149019607843137, b: 0.149019607843137},
{name: '491', r: 0.458823529411765, g: 0.156862745098039, b: 0.156862745098039},
{name: '492', r: 0.568627450980392, g: 0.2, b: 0.219607843137255},
{name: '494', r: 0.949019607843137, g: 0.67843137254902, b: 0.698039215686274},
{name: '495', r: 0.956862745098039, g: 0.737254901960784, b: 0.749019607843137},
{name: '496', r: 0.968627450980392, g: 0.788235294117647, b: 0.776470588235294},
{name: '497', r: 0.317647058823529, g: 0.156862745098039, b: 0.149019607843137},
{name: '4975', r: 0.266666666666667, g: 0.117647058823529, b: 0.109803921568627},
{name: '498', r: 0.427450980392157, g: 0.2, b: 0.168627450980392},
{name: '4985', r: 0.517647058823529, g: 0.286274509803922, b: 0.286274509803922},
{name: '499', r: 0.47843137254902, g: 0.219607843137255, b: 0.176470588235294},
{name: '4995', r: 0.647058823529412, g: 0.419607843137255, b: 0.427450980392157},
{name: '500', r: 0.807843137254902, g: 0.537254901960784, b: 0.549019607843137},
{name: '5005', r: 0.737254901960784, g: 0.529411764705882, b: 0.529411764705882},
{name: '501', r: 0.917647058823529, g: 0.698039215686274, b: 0.698039215686274},
{name: '5015', r: 0.847058823529412, g: 0.67843137254902, b: 0.658823529411765},
{name: '502', r: 0.949019607843137, g: 0.776470588235294, b: 0.768627450980392},
{name: '5025', r: 0.886274509803922, g: 0.737254901960784, b: 0.717647058823529},
{name: '503', r: 0.956862745098039, g: 0.819607843137255, b: 0.8},
{name: '5035', r: 0.929411764705882, g: 0.807843137254902, b: 0.776470588235294},
{name: '504', r: 0.317647058823529, g: 0.117647058823529, b: 0.149019607843137},
{name: '505', r: 0.4, g: 0.117647058823529, b: 0.168627450980392},
{name: '506', r: 0.47843137254902, g: 0.149019607843137, b: 0.219607843137255},
{name: '507', r: 0.847058823529412, g: 0.537254901960784, b: 0.607843137254902},
{name: '508', r: 0.909803921568627, g: 0.647058823529412, b: 0.686274509803922},
{name: '509', r: 0.949019607843137, g: 0.729411764705882, b: 0.749019607843137},
{name: '510', r: 0.956862745098039, g: 0.776470588235294, b: 0.788235294117647},
{name: '511', r: 0.376470588235294, g: 0.129411764705882, b: 0.266666666666667},
{name: '5115', r: 0.309803921568627, g: 0.129411764705882, b: 0.227450980392157},
{name: '512', r: 0.517647058823529, g: 0.129411764705882, b: 0.419607843137255},
{name: '5125', r: 0.458823529411765, g: 0.27843137254902, b: 0.376470588235294},
{name: '513', r: 0.619607843137255, g: 0.137254901960784, b: 0.529411764705882},
{name: '5135', r: 0.576470588235294, g: 0.419607843137255, b: 0.498039215686275},
{name: '514', r: 0.847058823529412, g: 0.517647058823529, b: 0.737254901960784},
{name: '5145', r: 0.67843137254902, g: 0.529411764705882, b: 0.6},
{name: '515', r: 0.909803921568627, g: 0.63921568627451, b: 0.788235294117647},
{name: '5155', r: 0.8, g: 0.686274509803922, b: 0.717647058823529},
{name: '516', r: 0.949019607843137, g: 0.729411764705882, b: 0.827450980392157},
{name: '5165', r: 0.87843137254902, g: 0.788235294117647, b: 0.8},
{name: '517', r: 0.956862745098039, g: 0.8, b: 0.847058823529412},
{name: '5175', r: 0.909803921568627, g: 0.83921568627451, b: 0.819607843137255},
{name: '518', r: 0.317647058823529, g: 0.176470588235294, b: 0.266666666666667},
{name: '5185', r: 0.27843137254902, g: 0.156862745098039, b: 0.207843137254902},
{name: '519', r: 0.388235294117647, g: 0.188235294117647, b: 0.368627450980392},
{name: '5195', r: 0.349019607843137, g: 0.2, b: 0.266666666666667},
{name: '520', r: 0.43921568627451, g: 0.207843137254902, b: 0.447058823529412},
{name: '5205', r: 0.556862745098039, g: 0.407843137254902, b: 0.466666666666667},
{name: '521', r: 0.709803921568627, g: 0.549019607843137, b: 0.698039215686274},
{name: '5215', r: 0.709803921568627, g: 0.576470588235294, b: 0.607843137254902},
{name: '522', r: 0.776470588235294, g: 0.63921568627451, b: 0.756862745098039},
{name: '5225', r: 0.8, g: 0.67843137254902, b: 0.686274509803922},
{name: '523', r: 0.827450980392157, g: 0.717647058823529, b: 0.8},
{name: '5235', r: 0.866666666666667, g: 0.776470588235294, b: 0.768627450980392},
{name: '524', r: 0.886274509803922, g: 0.8, b: 0.827450980392157},
{name: '5245', r: 0.898039215686275, g: 0.827450980392157, b: 0.8},
{name: '525', r: 0.317647058823529, g: 0.149019607843137, b: 0.329411764705882},
{name: '5255', r: 0.207843137254902, g: 0.149019607843137, b: 0.309803921568627},
{name: '526', r: 0.407843137254902, g: 0.129411764705882, b: 0.47843137254902},
{name: '5265', r: 0.286274509803922, g: 0.23921568627451, b: 0.388235294117647},
{name: '527', r: 0.47843137254902, g: 0.117647058823529, b: 0.6},
{name: '5275', r: 0.376470588235294, g: 0.337254901960784, b: 0.466666666666667},
{name: '528', r: 0.686274509803922, g: 0.447058823529412, b: 0.756862745098039},
{name: '5285', r: 0.549019607843137, g: 0.509803921568627, b: 0.6},
{name: '529', r: 0.807843137254902, g: 0.63921568627451, b: 0.827450980392157},
{name: '5295', r: 0.698039215686274, g: 0.658823529411765, b: 0.709803921568627},
{name: '530', r: 0.83921568627451, g: 0.686274509803922, b: 0.83921568627451},
{name: '5305', r: 0.8, g: 0.756862745098039, b: 0.776470588235294},
{name: '531', r: 0.898039215686275, g: 0.776470588235294, b: 0.858823529411765},
{name: '5315', r: 0.858823529411765, g: 0.827450980392157, b: 0.827450980392157},
{name: '532', r: 0.207843137254902, g: 0.219607843137255, b: 0.258823529411765},
{name: '533', r: 0.207843137254902, g: 0.247058823529412, b: 0.356862745098039},
{name: '534', r: 0.227450980392157, g: 0.286274509803922, b: 0.447058823529412},
{name: '535', r: 0.607843137254902, g: 0.63921568627451, b: 0.717647058823529},
{name: '536', r: 0.67843137254902, g: 0.698039215686274, b: 0.756862745098039},
{name: '537', r: 0.768627450980392, g: 0.776470588235294, b: 0.807843137254902},
{name: '538', r: 0.83921568627451, g: 0.827450980392157, b: 0.83921568627451},
{name: '539', r: 0, g: 0.188235294117647, b: 0.286274509803922},
{name: '5395', r: 0.00784313725490196, g: 0.156862745098039, b: 0.227450980392157},
{name: '540', r: 0, g: 0.2, b: 0.356862745098039},
{name: '5405', r: 0.247058823529412, g: 0.376470588235294, b: 0.458823529411765},
{name: '541', r: 0, g: 0.247058823529412, b: 0.466666666666667},
{name: '5415', r: 0.376470588235294, g: 0.486274509803922, b: 0.549019607843137},
{name: '542', r: 0.4, g: 0.576470588235294, b: 0.737254901960784},
{name: '5425', r: 0.517647058823529, g: 0.6, b: 0.647058823529412},
{name: '543', r: 0.576470588235294, g: 0.717647058823529, b: 0.819607843137255},
{name: '5435', r: 0.686274509803922, g: 0.737254901960784, b: 0.749019607843137},
{name: '544', r: 0.717647058823529, g: 0.8, b: 0.858823529411765},
{name: '5445', r: 0.768627450980392, g: 0.8, b: 0.8},
{name: '545', r: 0.768627450980392, g: 0.827450980392157, b: 0.866666666666667},
{name: '5455', r: 0.83921568627451, g: 0.847058823529412, b: 0.827450980392157},
{name: '546', r: 0.0470588235294118, g: 0.219607843137255, b: 0.266666666666667},
{name: '5463', r: 0, g: 0.207843137254902, b: 0.227450980392157},
{name: '5467', r: 0.0980392156862745, g: 0.219607843137255, b: 0.2},
{name: '547', r: 0, g: 0.247058823529412, b: 0.329411764705882},
{name: '5473', r: 0.149019607843137, g: 0.407843137254902, b: 0.427450980392157},
{name: '5477', r: 0.227450980392157, g: 0.337254901960784, b: 0.309803921568627},
{name: '548', r: 0, g: 0.266666666666667, b: 0.349019607843137},
{name: '5483', r: 0.376470588235294, g: 0.568627450980392, b: 0.568627450980392},
{name: '5487', r: 0.4, g: 0.486274509803922, b: 0.447058823529412},
{name: '549', r: 0.368627450980392, g: 0.6, b: 0.666666666666667},
{name: '5493', r: 0.549019607843137, g: 0.686274509803922, b: 0.67843137254902},
{name: '5497', r: 0.568627450980392, g: 0.63921568627451, b: 0.6},
{name: '550', r: 0.529411764705882, g: 0.686274509803922, b: 0.749019607843137},
{name: '5503', r: 0.666666666666667, g: 0.768627450980392, b: 0.749019607843137},
{name: '5507', r: 0.686274509803922, g: 0.729411764705882, b: 0.698039215686274},
{name: '551', r: 0.63921568627451, g: 0.756862745098039, b: 0.788235294117647},
{name: '5513', r: 0.807843137254902, g: 0.847058823529412, b: 0.819607843137255},
{name: '5517', r: 0.788235294117647, g: 0.807843137254902, b: 0.768627450980392},
{name: '552', r: 0.768627450980392, g: 0.83921568627451, b: 0.83921568627451},
{name: '5523', r: 0.83921568627451, g: 0.866666666666667, b: 0.83921568627451},
{name: '5527', r: 0.807843137254902, g: 0.819607843137255, b: 0.776470588235294},
{name: '553', r: 0.137254901960784, g: 0.266666666666667, b: 0.207843137254902},
{name: '5535', r: 0.129411764705882, g: 0.23921568627451, b: 0.188235294117647},
{name: '554', r: 0.0980392156862745, g: 0.368627450980392, b: 0.27843137254902},
{name: '5545', r: 0.309803921568627, g: 0.427450980392157, b: 0.368627450980392},
{name: '555', r: 0.0274509803921569, g: 0.427450980392157, b: 0.329411764705882},
{name: '5555', r: 0.466666666666667, g: 0.568627450980392, b: 0.509803921568627},
{name: '556', r: 0.47843137254902, g: 0.658823529411765, b: 0.568627450980392},
{name: '5565', r: 0.588235294117647, g: 0.666666666666667, b: 0.6},
{name: '557', r: 0.63921568627451, g: 0.756862745098039, b: 0.67843137254902},
{name: '5575', r: 0.686274509803922, g: 0.749019607843137, b: 0.67843137254902},
{name: '558', r: 0.717647058823529, g: 0.807843137254902, b: 0.737254901960784},
{name: '5585', r: 0.768627450980392, g: 0.807843137254902, b: 0.749019607843137},
{name: '559', r: 0.776470588235294, g: 0.83921568627451, b: 0.768627450980392},
{name: '5595', r: 0.847058823529412, g: 0.858823529411765, b: 0.8},
{name: '560', r: 0.168627450980392, g: 0.298039215686275, b: 0.247058823529412},
{name: '5605', r: 0.137254901960784, g: 0.227450980392157, b: 0.176470588235294},
{name: '561', r: 0.149019607843137, g: 0.4, b: 0.349019607843137},
{name: '5615', r: 0.329411764705882, g: 0.407843137254902, b: 0.337254901960784},
{name: '562', r: 0.117647058823529, g: 0.47843137254902, b: 0.427450980392157},
{name: '5625', r: 0.447058823529412, g: 0.517647058823529, b: 0.43921568627451},
{name: '563', r: 0.498039215686275, g: 0.737254901960784, b: 0.666666666666667},
{name: '5635', r: 0.619607843137255, g: 0.666666666666667, b: 0.6},
{name: '564', r: 0.0196078431372549, g: 0.43921568627451, b: 0.368627450980392},
{name: '5645', r: 0.737254901960784, g: 0.756862745098039, b: 0.698039215686274},
{name: '565', r: 0.737254901960784, g: 0.858823529411765, b: 0.8},
{name: '5655', r: 0.776470588235294, g: 0.8, b: 0.729411764705882},
{name: '566', r: 0.819607843137255, g: 0.886274509803922, b: 0.827450980392157},
{name: '5665', r: 0.83921568627451, g: 0.83921568627451, b: 0.776470588235294},
{name: '567', r: 0.149019607843137, g: 0.317647058823529, b: 0.258823529411765},
{name: '568', r: 0, g: 0.447058823529412, b: 0.388235294117647},
{name: '569', r: 0, g: 0.529411764705882, b: 0.447058823529412},
{name: '570', r: 0.498039215686275, g: 0.776470588235294, b: 0.698039215686274},
{name: '571', r: 0.666666666666667, g: 0.858823529411765, b: 0.776470588235294},
{name: '572', r: 0.737254901960784, g: 0.886274509803922, b: 0.807843137254902},
{name: '573', r: 0.8, g: 0.898039215686275, b: 0.83921568627451},
{name: '574', r: 0.286274509803922, g: 0.349019607843137, b: 0.156862745098039},
{name: '5743', r: 0.247058823529412, g: 0.286274509803922, b: 0.149019607843137},
{name: '5747', r: 0.258823529411765, g: 0.27843137254902, b: 0.0862745098039216},
{name: '575', r: 0.329411764705882, g: 0.466666666666667, b: 0.188235294117647},
{name: '5753', r: 0.368627450980392, g: 0.4, b: 0.227450980392157},
{name: '5757', r: 0.419607843137255, g: 0.43921568627451, b: 0.168627450980392},
{name: '576', r: 0.376470588235294, g: 0.556862745098039, b: 0.227450980392157},
{name: '5763', r: 0.466666666666667, g: 0.486274509803922, b: 0.309803921568627},
{name: '5767', r: 0.549019607843137, g: 0.568627450980392, b: 0.309803921568627},
{name: '577', r: 0.709803921568627, g: 0.8, b: 0.556862745098039},
{name: '5773', r: 0.607843137254902, g: 0.619607843137255, b: 0.447058823529412},
{name: '5777', r: 0.666666666666667, g: 0.67843137254902, b: 0.458823529411765},
{name: '578', r: 0.776470588235294, g: 0.83921568627451, b: 0.627450980392157},
{name: '5783', r: 0.709803921568627, g: 0.709803921568627, b: 0.556862745098039},
{name: '5787', r: 0.776470588235294, g: 0.776470588235294, b: 0.6},
{name: '579', r: 0.788235294117647, g: 0.83921568627451, b: 0.63921568627451},
{name: '5793', r: 0.776470588235294, g: 0.776470588235294, b: 0.647058823529412},
{name: '5797', r: 0.827450980392157, g: 0.819607843137255, b: 0.666666666666667},
{name: '580', r: 0.847058823529412, g: 0.866666666666667, b: 0.709803921568627},
{name: '5803', r: 0.847058823529412, g: 0.83921568627451, b: 0.717647058823529},
{name: '5807', r: 0.87843137254902, g: 0.866666666666667, b: 0.737254901960784},
{name: '581', r: 0.376470588235294, g: 0.368627450980392, b: 0.0666666666666667},
{name: '5815', r: 0.286274509803922, g: 0.266666666666667, b: 0.0666666666666667},
{name: '582', r: 0.529411764705882, g: 0.537254901960784, b: 0.0196078431372549},
{name: '5825', r: 0.458823529411765, g: 0.43921568627451, b: 0.168627450980392},
{name: '583', r: 0.666666666666667, g: 0.729411764705882, b: 0.0392156862745098},
{name: '5835', r: 0.619607843137255, g: 0.6, b: 0.349019607843137},
{name: '584', r: 0.807843137254902, g: 0.83921568627451, b: 0.286274509803922},
{name: '5845', r: 0.698039215686274, g: 0.666666666666667, b: 0.43921568627451},
{name: '585', r: 0.858823529411765, g: 0.87843137254902, b: 0.419607843137255},
{name: '5855', r: 0.8, g: 0.776470588235294, b: 0.576470588235294},
{name: '586', r: 0.886274509803922, g: 0.898039215686275, b: 0.517647058823529},
{name: '5865', r: 0.83921568627451, g: 0.807843137254902, b: 0.63921568627451},
{name: '587', r: 0.909803921568627, g: 0.909803921568627, b: 0.607843137254902},
{name: '5875', r: 0.87843137254902, g: 0.858823529411765, b: 0.709803921568627},
{name: '600', r: 0.956862745098039, g: 0.929411764705882, b: 0.686274509803922},
{name: '601', r: 0.949019607843137, g: 0.929411764705882, b: 0.619607843137255},
{name: '602', r: 0.949019607843137, g: 0.917647058823529, b: 0.529411764705882},
{name: '603', r: 0.929411764705882, g: 0.909803921568627, b: 0.356862745098039},
{name: '604', r: 0.909803921568627, g: 0.866666666666667, b: 0.129411764705882},
{name: '605', r: 0.866666666666667, g: 0.807843137254902, b: 0.0666666666666667},
{name: '606', r: 0.827450980392157, g: 0.749019607843137, b: 0.0666666666666667},
{name: '607', r: 0.949019607843137, g: 0.917647058823529, b: 0.737254901960784},
{name: '608', r: 0.937254901960784, g: 0.909803921568627, b: 0.67843137254902},
{name: '609', r: 0.917647058823529, g: 0.898039215686275, b: 0.588235294117647},
{name: '610', r: 0.886274509803922, g: 0.858823529411765, b: 0.447058823529412},
{name: '611', r: 0.83921568627451, g: 0.807843137254902, b: 0.286274509803922},
{name: '612', r: 0.768627450980392, g: 0.729411764705882, b: 0},
{name: '613', r: 0.686274509803922, g: 0.627450980392157, b: 0.0470588235294118},
{name: '614', r: 0.917647058823529, g: 0.886274509803922, b: 0.717647058823529},
{name: '615', r: 0.886274509803922, g: 0.858823529411765, b: 0.666666666666667},
{name: '616', r: 0.866666666666667, g: 0.83921568627451, b: 0.607843137254902},
{name: '617', r: 0.8, g: 0.768627450980392, b: 0.486274509803922},
{name: '618', r: 0.709803921568627, g: 0.666666666666667, b: 0.349019607843137},
{name: '619', r: 0.588235294117647, g: 0.549019607843137, b: 0.156862745098039},
{name: '620', r: 0.517647058823529, g: 0.466666666666667, b: 0.0666666666666667},
{name: '621', r: 0.847058823529412, g: 0.866666666666667, b: 0.807843137254902},
{name: '622', r: 0.756862745098039, g: 0.819607843137255, b: 0.749019607843137},
{name: '623', r: 0.647058823529412, g: 0.749019607843137, b: 0.666666666666667},
{name: '624', r: 0.498039215686275, g: 0.627450980392157, b: 0.549019607843137},
{name: '625', r: 0.356862745098039, g: 0.529411764705882, b: 0.447058823529412},
{name: '626', r: 0.129411764705882, g: 0.329411764705882, b: 0.247058823529412},
{name: '627', r: 0.0470588235294118, g: 0.188235294117647, b: 0.149019607843137},
{name: '628', r: 0.8, g: 0.886274509803922, b: 0.866666666666667},
{name: '629', r: 0.698039215686274, g: 0.847058823529412, b: 0.847058823529412},
{name: '630', r: 0.549019607843137, g: 0.8, b: 0.827450980392157},
{name: '631', r: 0.329411764705882, g: 0.717647058823529, b: 0.776470588235294},
{name: '632', r: 0, g: 0.627450980392157, b: 0.729411764705882},
{name: '633', r: 0, g: 0.498039215686275, b: 0.6},
{name: '634', r: 0, g: 0.4, b: 0.498039215686275},
{name: '635', r: 0.729411764705882, g: 0.87843137254902, b: 0.87843137254902},
{name: '636', r: 0.6, g: 0.83921568627451, b: 0.866666666666667},
{name: '637', r: 0.419607843137255, g: 0.788235294117647, b: 0.858823529411765},
{name: '638', r: 0, g: 0.709803921568627, b: 0.83921568627451},
{name: '639', r: 0, g: 0.627450980392157, b: 0.768627450980392},
{name: '640', r: 0, g: 0.549019607843137, b: 0.698039215686274},
{name: '641', r: 0, g: 0.47843137254902, b: 0.647058823529412},
{name: '642', r: 0.819607843137255, g: 0.847058823529412, b: 0.847058823529412},
{name: '643', r: 0.776470588235294, g: 0.819607843137255, b: 0.83921568627451},
{name: '644', r: 0.607843137254902, g: 0.686274509803922, b: 0.768627450980392},
{name: '645', r: 0.466666666666667, g: 0.588235294117647, b: 0.698039215686274},
{name: '646', r: 0.368627450980392, g: 0.509803921568627, b: 0.63921568627451},
{name: '647', r: 0.149019607843137, g: 0.329411764705882, b: 0.486274509803922},
{name: '648', r: 0, g: 0.188235294117647, b: 0.368627450980392},
{name: '649', r: 0.83921568627451, g: 0.83921568627451, b: 0.847058823529412},
{name: '650', r: 0.749019607843137, g: 0.776470588235294, b: 0.819607843137255},
{name: '651', r: 0.607843137254902, g: 0.666666666666667, b: 0.749019607843137},
{name: '652', r: 0.427450980392157, g: 0.529411764705882, b: 0.658823529411765},
{name: '653', r: 0.2, g: 0.337254901960784, b: 0.529411764705882},
{name: '654', r: 0.0588235294117647, g: 0.168627450980392, b: 0.356862745098039},
{name: '655', r: 0.0470588235294118, g: 0.109803921568627, b: 0.27843137254902},
{name: '656', r: 0.83921568627451, g: 0.858823529411765, b: 0.87843137254902},
{name: '657', r: 0.756862745098039, g: 0.788235294117647, b: 0.866666666666667},
{name: '658', r: 0.647058823529412, g: 0.686274509803922, b: 0.83921568627451},
{name: '659', r: 0.498039215686275, g: 0.549019607843137, b: 0.749019607843137},
{name: '660', r: 0.349019607843137, g: 0.376470588235294, b: 0.658823529411765},
{name: '661', r: 0.176470588235294, g: 0.2, b: 0.556862745098039},
{name: '662', r: 0.0470588235294118, g: 0.0980392156862745, b: 0.458823529411765},
{name: '663', r: 0.886274509803922, g: 0.827450980392157, b: 0.83921568627451},
{name: '664', r: 0.847058823529412, g: 0.8, b: 0.819607843137255},
{name: '665', r: 0.776470588235294, g: 0.709803921568627, b: 0.768627450980392},
{name: '666', r: 0.658823529411765, g: 0.576470588235294, b: 0.67843137254902},
{name: '667', r: 0.498039215686275, g: 0.4, b: 0.537254901960784},
{name: '668', r: 0.4, g: 0.286274509803922, b: 0.458823529411765},
{name: '669', r: 0.27843137254902, g: 0.168627450980392, b: 0.349019607843137},
{name: '670', r: 0.949019607843137, g: 0.83921568627451, b: 0.847058823529412},
{name: '671', r: 0.937254901960784, g: 0.776470588235294, b: 0.827450980392157},
{name: '672', r: 0.917647058823529, g: 0.666666666666667, b: 0.768627450980392},
{name: '673', r: 0.87843137254902, g: 0.549019607843137, b: 0.698039215686274},
{name: '674', r: 0.827450980392157, g: 0.419607843137255, b: 0.619607843137255},
{name: '675', r: 0.737254901960784, g: 0.219607843137255, b: 0.466666666666667},
{name: '676', r: 0.627450980392157, g: 0, b: 0.329411764705882},
{name: '677', r: 0.929411764705882, g: 0.83921568627451, b: 0.83921568627451},
{name: '678', r: 0.917647058823529, g: 0.8, b: 0.807843137254902},
{name: '679', r: 0.898039215686275, g: 0.749019607843137, b: 0.776470588235294},
{name: '680', r: 0.827450980392157, g: 0.619607843137255, b: 0.686274509803922},
{name: '681', r: 0.717647058823529, g: 0.447058823529412, b: 0.556862745098039},
{name: '682', r: 0.627450980392157, g: 0.317647058823529, b: 0.458823529411765},
{name: '683', r: 0.498039215686275, g: 0.156862745098039, b: 0.309803921568627},
{name: '684', r: 0.937254901960784, g: 0.8, b: 0.807843137254902},
{name: '685', r: 0.917647058823529, g: 0.749019607843137, b: 0.768627450980392},
{name: '686', r: 0.87843137254902, g: 0.666666666666667, b: 0.729411764705882},
{name: '687', r: 0.788235294117647, g: 0.537254901960784, b: 0.619607843137255},
{name: '688', r: 0.698039215686274, g: 0.4, b: 0.517647058823529},
{name: '689', r: 0.576470588235294, g: 0.258823529411765, b: 0.4},
{name: '690', r: 0.43921568627451, g: 0.137254901960784, b: 0.258823529411765},
{name: '691', r: 0.937254901960784, g: 0.819607843137255, b: 0.788235294117647},
{name: '692', r: 0.909803921568627, g: 0.749019607843137, b: 0.729411764705882},
{name: '693', r: 0.858823529411765, g: 0.658823529411765, b: 0.647058823529412},
{name: '694', r: 0.788235294117647, g: 0.549019607843137, b: 0.549019607843137},
{name: '695', r: 0.698039215686274, g: 0.419607843137255, b: 0.43921568627451},
{name: '696', r: 0.556862745098039, g: 0.27843137254902, b: 0.286274509803922},
{name: '697', r: 0.498039215686275, g: 0.219607843137255, b: 0.227450980392157},
{name: '698', r: 0.968627450980392, g: 0.819607843137255, b: 0.8},
{name: '699', r: 0.968627450980392, g: 0.749019607843137, b: 0.749019607843137},
{name: '700', r: 0.949019607843137, g: 0.647058823529412, b: 0.666666666666667},
{name: '701', r: 0.909803921568627, g: 0.529411764705882, b: 0.556862745098039},
{name: '702', r: 0.83921568627451, g: 0.376470588235294, b: 0.427450980392157},
{name: '703', r: 0.717647058823529, g: 0.219607843137255, b: 0.266666666666667},
{name: '704', r: 0.619607843137255, g: 0.156862745098039, b: 0.156862745098039},
{name: '705', r: 0.976470588235294, g: 0.866666666666667, b: 0.83921568627451},
{name: '706', r: 0.988235294117647, g: 0.788235294117647, b: 0.776470588235294},
{name: '707', r: 0.988235294117647, g: 0.67843137254902, b: 0.686274509803922},
{name: '708', r: 0.976470588235294, g: 0.556862745098039, b: 0.6},
{name: '709', r: 0.949019607843137, g: 0.407843137254902, b: 0.466666666666667},
{name: '710', r: 0.87843137254902, g: 0.258823529411765, b: 0.317647058823529},
{name: '711', r: 0.819607843137255, g: 0.176470588235294, b: 0.2},
{name: '712', r: 1, g: 0.827450980392157, b: 0.666666666666667},
{name: '713', r: 0.976470588235294, g: 0.788235294117647, b: 0.63921568627451},
{name: '714', r: 0.976470588235294, g: 0.729411764705882, b: 0.509803921568627},
{name: '715', r: 0.988235294117647, g: 0.619607843137255, b: 0.286274509803922},
{name: '716', r: 0.949019607843137, g: 0.517647058823529, b: 0.0666666666666667},
{name: '717', r: 0.827450980392157, g: 0.427450980392157, b: 0},
{name: '718', r: 0.749019607843137, g: 0.356862745098039, b: 0},
{name: '719', r: 0.956862745098039, g: 0.819607843137255, b: 0.686274509803922},
{name: '720', r: 0.937254901960784, g: 0.768627450980392, b: 0.619607843137255},
{name: '721', r: 0.909803921568627, g: 0.698039215686274, b: 0.509803921568627},
{name: '722', r: 0.819607843137255, g: 0.556862745098039, b: 0.329411764705882},
{name: '723', r: 0.729411764705882, g: 0.458823529411765, b: 0.188235294117647},
{name: '724', r: 0.556862745098039, g: 0.286274509803922, b: 0.0196078431372549},
{name: '725', r: 0.458823529411765, g: 0.219607843137255, b: 0.00784313725490196},
{name: '726', r: 0.929411764705882, g: 0.827450980392157, b: 0.709803921568627},
{name: '727', r: 0.886274509803922, g: 0.749019607843137, b: 0.607843137254902},
{name: '728', r: 0.827450980392157, g: 0.658823529411765, b: 0.486274509803922},
{name: '729', r: 0.756862745098039, g: 0.556862745098039, b: 0.376470588235294},
{name: '730', r: 0.666666666666667, g: 0.458823529411765, b: 0.247058823529412},
{name: '731', r: 0.447058823529412, g: 0.247058823529412, b: 0.0392156862745098},
{name: '732', r: 0.376470588235294, g: 0.2, b: 0.0392156862745098},
{name: '801', r: 0, g: 0.666666666666667, b: 0.8},
{name: '801 2X', r: 0, g: 0.537254901960784, b: 0.686274509803922},
{name: '802', r: 0.376470588235294, g: 0.866666666666667, b: 0.286274509803922},
{name: '802 2X', r: 0.109803921568627, g: 0.807843137254902, b: 0.156862745098039},
{name: '803', r: 1, g: 0.929411764705882, b: 0.219607843137255},
{name: '803 2X', r: 1, g: 0.847058823529412, b: 0.0862745098039216},
{name: '804', r: 1, g: 0.576470588235294, b: 0.219607843137255},
{name: '804 2X', r: 1, g: 0.498039215686275, b: 0.117647058823529},
{name: '805', r: 0.976470588235294, g: 0.349019607843137, b: 0.317647058823529},
{name: '805 2X', r: 0.976470588235294, g: 0.227450980392157, b: 0.168627450980392},
{name: '806', r: 1, g: 0, b: 0.576470588235294},
{name: '806 2X', r: 0.968627450980392, g: 0.00784313725490196, b: 0.486274509803922},
{name: '807', r: 0.83921568627451, g: 0, b: 0.619607843137255},
{name: '807 2X', r: 0.749019607843137, g: 0, b: 0.549019607843137},
{name: '808', r: 0, g: 0.709803921568627, b: 0.607843137254902},
{name: '808 2X', r: 0, g: 0.627450980392157, b: 0.529411764705882},
{name: '809', r: 0.866666666666667, g: 0.87843137254902, b: 0.0588235294117647},
{name: '809 2X', r: 0.83921568627451, g: 0.83921568627451, b: 0.0470588235294118},
{name: '810', r: 1, g: 0.8, b: 0.117647058823529},
{name: '810 2X', r: 1, g: 0.737254901960784, b: 0.129411764705882},
{name: '811', r: 1, g: 0.447058823529412, b: 0.27843137254902},
{name: '811 2X', r: 1, g: 0.329411764705882, b: 0.0862745098039216},
{name: '812', r: 0.988235294117647, g: 0.137254901960784, b: 0.4},
{name: '812 2X', r: 0.988235294117647, g: 0.0274509803921569, b: 0.309803921568627},
{name: '813', r: 0.898039215686275, g: 0, b: 0.6},
{name: '813 2X', r: 0.819607843137255, g: 0, b: 0.517647058823529},
{name: '814', r: 0.549019607843137, g: 0.376470588235294, b: 0.756862745098039},
{name: '814 2X', r: 0.43921568627451, g: 0.247058823529412, b: 0.686274509803922}
];
});

View File

@ -0,0 +1,206 @@
jQuery(function ($) {
$.colorpicker.swatchesNames['prismacolor'] = 'Prismacolor';
$.colorpicker.swatches['prismacolor'] = [
{name: 'Process Red', r: 0.98823529411765, g: 0.54901960784314, b: 1},
{name: 'Blush Pink', r: 1, g: 0.65882352941176, b: 0.83137254901961},
{name: 'Warm Grey 20%', r: 0.92941176470588, g: 0.94117647058824, b: 0.94117647058824},
{name: 'Warm Grey 30%', r: 0.90980392156863, g: 0.90980392156863, b: 0.92941176470588},
{name: 'Warm Grey 40%', r: 0.87058823529412, g: 0.87843137254902, b: 0.89019607843137},
{name: 'Warm Grey 50%', r: 0.69803921568627, g: 0.72941176470588, b: 0.74901960784314},
{name: 'Warm Grey 60%', r: 0.65098039215686, g: 0.67843137254902, b: 0.70980392156863},
{name: 'Warm Grey 70%', r: 0.45882352941176, g: 0.49803921568627, b: 0.52549019607843},
{name: 'Warm Grey 80%', r: 0.29019607843137, g: 0.30588235294118, b: 0.34117647058824},
{name: 'Warm Grey 90%', r: 0.13725490196078, g: 0.14117647058824, b: 0.16862745098039},
{name: 'Cool Grey 10%', r: 0.94117647058824, g: 0.95686274509804, b: 0.96470588235294},
{name: 'Cool Grey 20%', r: 0.89803921568627, g: 0.92549019607843, b: 0.93725490196078},
{name: 'Deco Peach', r: 1, g: 0.87058823529412, b: 0.87058823529412},
{name: 'Cool Grey 30%', r: 0.81176470588235, g: 0.86274509803922, b: 0.89019607843137},
{name: 'Cool Grey 40%', r: 0.73333333333333, g: 0.77647058823529, b: 0.80392156862745},
{name: 'Cool Grey 50%', r: 0.64705882352941, g: 0.69019607843137, b: 0.71764705882353},
{name: 'Cool Grey 60%', r: 0.54509803921569, g: 0.62745098039216, b: 0.67450980392157},
{name: 'Cool Grey 70%', r: 0.4078431372549, g: 0.50196078431373, b: 0.55294117647059},
{name: 'Cool Grey 80%', r: 0.31764705882353, g: 0.39607843137255, b: 0.43921568627451},
{name: 'Cool Grey 90%', r: 0.21176470588235, g: 0.27450980392157, b: 0.30588235294118},
{name: 'Metallic Silver Broad', r: 0.5843137254902, g: 0.66274509803922, b: 0.65490196078431},
{name: 'Metallic Silver Fine', r: 0.5843137254902, g: 0.66274509803922, b: 0.65490196078431},
{name: 'Metallic Gold Broad', r: 0.63529411764706, g: 0.69411764705882, b: 0.34117647058824},
{name: 'Light Peach', r: 1, g: 0.87058823529412, b: 0.83137254901961},
{name: 'Metallic Gold Fine', r: 0.63529411764706, g: 0.69411764705882, b: 0.34117647058824},
{name: 'Colorless Blender', r: 1, g: 1, b: 1},
{name: 'Salmon Pink', r: 1, g: 0.76862745098039, b: 0.72156862745098},
{name: 'Spanish Orange', r: 0.98823529411765, g: 0.83137254901961, b: 0.011764705882353},
{name: 'Lime peel', r: 0.83137254901961, g: 0.98039215686275, b: 0.36862745098039},
{name: 'Peacock Blue', r: 0.17254901960784, g: 0.46274509803922, b: 0.72941176470588},
{name: 'Cerulean Blue', r: 0.50196078431373, g: 0.72941176470588, b: 1},
{name: 'Imperial Violet', r: 0.34117647058824, g: 0.47843137254902, b: 0.96862745098039},
{name: 'Parma Violet', r: 0.43921568627451, g: 0.54901960784314, b: 1},
{name: 'Poppy Red', r: 1, g: 0.32941176470588, b: 0.23921568627451},
{name: 'Deco Orange', r: 1, g: 0.72941176470588, b: 0.54901960784314},
{name: 'Deco Yellow', r: 0.96078431372549, g: 0.96078431372549, b: 0.54901960784314},
{name: 'Jasmine', r: 1, g: 0.83137254901961, b: 0.45098039215686},
{name: 'Deco Pink', r: 1, g: 0.87058823529412, b: 1},
{name: 'Deco Blue', r: 0.72156862745098, g: 1, b: 0.96078431372549},
{name: 'Dusty Rose', r: 0.94509803921569, g: 0.84705882352941, b: 0.83529411764706},
{name: 'Clay Rose', r: 0.81960784313725, g: 0.54117647058824, b: 1},
{name: 'Pale Vermilion', r: 1, g: 0.41960784313725, b: 0.070588235294118},
{name: 'Celadon Green', r: 0.69803921568627, g: 0.87058823529412, b: 0.76078431372549},
{name: 'Jade Green', r: 0.65098039215686, g: 0.87843137254902, b: 0.8},
{name: 'Brittany Blue', r: 0.52156862745098, g: 0.72941176470588, b: 0.76862745098039},
{name: 'Mediterranean Blue', r: 0.50196078431373, g: 0.74901960784314, b: 0.98039215686275},
{name: 'Cloud Blue', r: 0.83921568627451, g: 0.92156862745098, b: 0.98823529411765},
{name: 'Blue Slate', r: 0.56078431372549, g: 0.72156862745098, b: 0.98823529411765},
{name: 'Periwinkle', r: 0.41960784313725, g: 0.63137254901961, b: 0.92941176470588},
{name: 'Greyed Lavender', r: 0.76862745098039, g: 0.72156862745098, b: 1},
{name: 'Greyed Lavender Light', r: 0.88627450980392, g: 0.85490196078431, b: 0.92549019607843},
{name: 'Bronze', r: 0.60392156862745, g: 0.66274509803922, b: 0},
{name: 'Yellow Orange', r: 0.98823529411765, g: 0.65882352941176, b: 0.011764705882353},
{name: 'Mahogany Red', r: 0.41176470588235, g: 0.086274509803922, b: 0.35686274509804},
{name: 'Raspberry', r: 0.68235294117647, g: 0.027450980392157, b: 0.39607843137255},
{name: 'Henna', r: 0.72549019607843, g: 0.094117647058824, b: 0.38039215686275},
{name: 'Pumpkin Orange', r: 0.87058823529412, g: 0.32549019607843, b: 0.16862745098039},
{name: 'Mineral Orange', r: 1, g: 0.65882352941176, b: 0.18823529411765},
{name: 'French Grey 10%', r: 0.96078431372549, g: 0.94901960784314, b: 0.94117647058824},
{name: 'French Grey 20%', r: 0.90980392156863, g: 0.90980392156863, b: 0.90196078431373},
{name: 'French Grey 30%', r: 0.8, g: 0.81176470588235, b: 0.78039215686275},
{name: 'French Grey 40%', r: 0.70980392156863, g: 0.72941176470588, b: 0.72156862745098},
{name: 'French Grey 50%', r: 0.64313725490196, g: 0.64313725490196, b: 0.64313725490196},
{name: 'Orange', r: 1, g: 0.54901960784314, b: 0.011764705882353},
{name: 'French Grey 60%', r: 0.57647058823529, g: 0.59607843137255, b: 0.59607843137255},
{name: 'French Grey 70%', r: 0.45882352941176, g: 0.48627450980392, b: 0.48627450980392},
{name: 'French Grey 80%', r: 0.29803921568627, g: 0.32156862745098, b: 0.32941176470588},
{name: 'French Grey 90%', r: 0.15294117647059, g: 0.16470588235294, b: 0.17254901960784},
{name: 'Grass Green', r: 0.32549019607843, g: 0.88235294117647, b: 0.37647058823529},
{name: 'True Green', r: 0.74117647058824, g: 0.98039215686275, b: 0.69019607843137},
{name: 'Apple Green', r: 0.63137254901961, g: 0.96078431372549, b: 0.47843137254902},
{name: 'Dark Purple', r: 0.15686274509804, g: 0, b: 0.87450980392157},
{name: 'Tuscan Red', r: 0.58039215686275, g: 0.17647058823529, b: 0.48235294117647},
{name: 'Sunburst Yellow', r: 0.98039215686275, g: 0.94117647058824, b: 0.2},
{name: 'Peach', r: 1, g: 0.54901960784314, b: 0.54901960784314},
{name: 'Lilac', r: 0.65098039215686, g: 0.65098039215686, b: 1},
{name: 'Light Umber', r: 0.41176470588235, g: 0.45490196078431, b: 0.22745098039216},
{name: 'Lilac Light', r: 0.6156862745098, g: 0.58823529411765, b: 0.77254901960784},
{name: 'Neon Yellow', r: 0.98823529411765, g: 0.90980392156863, b: 0.14117647058824},
{name: 'Neon Orange', r: 0.93725490196078, g: 0.76078431372549, b: 0.32549019607843},
{name: 'Neon Pink', r: 0.76470588235294, g: 0.4156862745098, b: 0.63137254901961},
{name: 'Neon Blue', r: 0.074509803921569, g: 0.60392156862745, b: 0.7921568627451},
{name: 'Yellow Ochre', r: 0.98823529411765, g: 0.83137254901961, b: 0.011764705882353},
{name: 'Neon Yellow Green', r: 0.96470588235294, g: 0.92941176470588, b: 0.38823529411765},
{name: 'Neon Green', r: 0.65882352941176, g: 0.7843137254902, b: 0.37647058823529},
{name: 'Forest Green', r: 0.52156862745098, g: 0.83137254901961, b: 0.56078431372549},
{name: 'Spruce Green', r: 0.18823529411765, g: 0.58039215686275, b: 0.44313725490196},
{name: 'Emerald', r: 0.1843137254902, g: 0.80392156862745, b: 0.17647058823529},
{name: 'Leaf Green', r: 0.39607843137255, g: 0.84313725490196, b: 0.13725490196078},
{name: 'Canary Yellow', r: 0.96862745098039, g: 0.96862745098039, b: 0.011764705882353},
{name: 'Pale Jade', r: 0.74117647058824, g: 0.87058823529412, b: 0.76862745098039},
{name: 'Avocado', r: 0.70980392156863, g: 1, b: 0.019607843137255},
{name: 'Mint Cream', r: 0.70980392156863, g: 0.96078431372549, b: 0.52941176470588},
{name: 'Cold Stone', r: 0.8, g: 0.89019607843137, b: 0.98039215686275},
{name: 'Spearmint', r: 0.14509803921569, g: 0.62745098039216, b: 0.007843137254902},
{name: 'Wheat', r: 0.94901960784314, g: 0.96078431372549, b: 0.8},
{name: 'Green Tea', r: 0.43921568627451, g: 0.7843137254902, b: 0},
{name: 'Muted Turquoise', r: 0.69019607843137, g: 0.90196078431373, b: 0.94901960784314},
{name: 'Mocha Light', r: 0.5843137254902, g: 0.55686274509804, b: 0.31764705882353},
{name: 'Process Red Light', r: 0.90588235294118, g: 0.73333333333333, b: 0.83137254901961},
{name: 'Canary Yellow Light', r: 1, g: 0.96470588235294, b: 0.6},
{name: 'Mocha Dark', r: 0.24313725490196, g: 0.24313725490196, b: 0.03921568627451},
{name: 'Cinnamon Toast', r: 0.87843137254902, g: 0.81176470588235, b: 0.61960784313725},
{name: 'Sky Blue Light', r: 0.50980392156863, g: 0.81960784313725, b: 1},
{name: 'Driftwood', r: 0.85882352941176, g: 0.87058823529412, b: 0.83921568627451},
{name: 'Taupe', r: 0.57647058823529, g: 0.64705882352941, b: 0.54901960784314},
{name: 'Parchment', r: 0.81960784313725, g: 0.85882352941176, b: 0.74901960784314},
{name: 'Ash Grey', r: 0.83921568627451, g: 0.87058823529412, b: 0.81960784313725},
{name: 'Pale Peach', r: 0.96078431372549, g: 0.94117647058824, b: 0.76862745098039},
{name: 'Ballet Pink', r: 0.96078431372549, g: 0.74117647058824, b: 0.87058823529412},
{name: 'Khaki', r: 0.74901960784314, g: 0.76078431372549, b: 0.52941176470588},
{name: 'Tulip Yellow', r: 0.98823529411765, g: 0.94117647058824, b: 0.34901960784314},
{name: 'Oatmeal', r: 0.83137254901961, g: 0.85882352941176, b: 0.54901960784314},
{name: 'Jet Black', r: 0.074509803921569, g: 0.094117647058824, b: 0.090196078431373},
{name: 'Pewter', r: 0.81960784313725, g: 0.87843137254902, b: 0.89019607843137},
{name: 'Eggplant', r: 0.15686274509804, g: 0.050980392156863, b: 0.10196078431373},
{name: 'Cocoa Bean', r: 0.2156862745098, g: 0.26274509803922, b: 0.047058823529412},
{name: 'Yellow Orange Light', r: 0.93725490196078, g: 0.76078431372549, b: 0.32549019607843},
{name: 'Neutral Grey 10%', r: 0.86666666666667, g: 0.86274509803922, b: 0.86666666666667},
{name: 'Neutral Grey 20%', r: 0.76862745098039, g: 0.76470588235294, b: 0.77647058823529},
{name: 'Neutral Grey 30%', r: 0.68235294117647, g: 0.67450980392157, b: 0.69019607843137},
{name: 'Neutral Grey 40%', r: 0.6, g: 0.5921568627451, b: 0.6156862745098},
{name: 'Neutral Grey 50%', r: 0.52549019607843, g: 0.51764705882353, b: 0.54509803921569},
{name: 'Neutral Grey 60%', r: 0.45490196078431, g: 0.45098039215686, b: 0.47843137254902},
{name: 'Neutral Grey 70%', r: 0.3921568627451, g: 0.38823529411765, b: 0.41960784313725},
{name: 'Neutral Grey 80%', r: 0.33333333333333, g: 0.33725490196078, b: 0.36470588235294},
{name: 'Neutral Grey 90%', r: 0.27450980392157, g: 0.28627450980392, b: 0.31764705882353},
{name: 'Cream', r: 0.98823529411765, g: 1, b: 0.83137254901961},
{name: 'Deco Orange Light', r: 0.94117647058824, g: 0.79607843137255, b: 0.65490196078431},
{name: 'Deco Pink Light', r: 0.96862745098039, g: 0.90196078431373, b: 0.93725490196078},
{name: 'Almond Milk', r: 0.9843137254902, g: 0.94509803921569, b: 0.91764705882353},
{name: 'Ultramarine Light', r: 0.54117647058824, g: 0.68235294117647, b: 0.86274509803922},
{name: 'Spring Green', r: 0.58823529411765, g: 0.96862745098039, b: 0.21176470588235},
{name: 'Light Olive Green', r: 0.60392156862745, g: 0.77254901960784, b: 0.36470588235294},
{name: 'Carmine Red Light', r: 0.88235294117647, g: 0.6156862745098, b: 0.58039215686275},
{name: 'Chartreuse', r: 0.83921568627451, g: 1, b: 0.47058823529412},
{name: 'Light Umber 20%', r: 0.89411764705882, g: 0.83529411764706, b: 0.75294117647059},
{name: 'Light Umber 30%', r: 0.87058823529412, g: 0.79607843137255, b: 0.69803921568627},
{name: 'Light Umber 40%', r: 0.81960784313725, g: 0.74901960784314, b: 0.67450980392157},
{name: 'Light Umber 50%', r: 0.79607843137255, g: 0.71372549019608, b: 0.63137254901961},
{name: 'Light Umber 60%', r: 0.76862745098039, g: 0.67843137254902, b: 0.58823529411765},
{name: 'Light Umber 70%', r: 0.74117647058824, g: 0.63921568627451, b: 0.54117647058824},
{name: 'Light Umber 80%', r: 0.71372549019608, g: 0.6078431372549, b: 0.50196078431373},
{name: 'Light Umber 90%', r: 0.54117647058824, g: 0.45490196078431, b: 0.33333333333333},
{name: 'Dark Olive Green', r: 0.29803921568627, g: 0.62352941176471, b: 0.086274509803922},
{name: 'Pink Light', r: 0.87843137254902, g: 0.63921568627451, b: 0.76862745098039},
{name: 'Ballet Pink Light', r: 0.96078431372549, g: 0.87450980392157, b: 0.88235294117647},
{name: 'Dark Green', r: 0.25098039215686, g: 0.70588235294118, b: 0.2156862745098},
{name: 'Parrot Green', r: 0.24705882352941, g: 0.84313725490196, b: 0.50588235294118},
{name: 'Parrot Green Light', r: 0.50588235294118, g: 0.74117647058824, b: 0.70980392156863},
{name: 'Lime Green', r: 0.72941176470588, g: 0.94117647058824, b: 0.69019607843137},
{name: 'Aquamarine', r: 0.25882352941176, g: 0.78039215686275, b: 0.70980392156863},
{name: 'Teal Blue', r: 0.32156862745098, g: 0.63529411764706, b: 0.65490196078431},
{name: 'True Blue', r: 0.41176470588235, g: 0.83137254901961, b: 1},
{name: 'Crimson Red', r: 0.88235294117647, g: 0.007843137254902, b: 0.027450980392157},
{name: 'Copenhagen Blue', r: 0.30196078431373, g: 0.70980392156863, b: 1},
{name: 'Violet Blue Light', r: 0.83137254901961, g: 0.69019607843137, b: 0.88235294117647},
{name: 'Violet Blue', r: 0.14901960784314, g: 0.31764705882353, b: 0.92941176470588},
{name: 'Indigo Blue', r: 0.12156862745098, g: 0.24313725490196, b: 0.73333333333333},
{name: 'Ultramarine', r: 0.2, g: 0.43921568627451, b: 0.98039215686275},
{name: 'Navy Blue', r: 0.023529411764706, g: 0.11372549019608, b: 0.56078431372549},
{name: 'Light Aqua', r: 0.58823529411765, g: 0.90980392156863, b: 0.87058823529412},
{name: 'Light Blue', r: 0.6, g: 0.90980392156863, b: 0.92156862745098},
{name: 'Light Cerulean Blue', r: 0.78039215686275, g: 0.94901960784314, b: 1},
{name: 'Scarlet Lake', r: 1, g: 0.14901960784314, b: 0.43921568627451},
{name: 'Violet', r: 0.14901960784314, g: 0.058823529411765, b: 0.98823529411765},
{name: 'Violet Dark', r: 0.24705882352941, g: 0.24313725490196, b: 0.54509803921569},
{name: 'Mulberry Light', r: 0.83529411764706, g: 0.67843137254902, b: 0.80392156862745},
{name: 'Mulberry', r: 0.76862745098039, g: 0.050980392156863, b: 1},
{name: 'Rhodamine Light', r: 0.85098039215686, g: 0.6078431372549, b: 0.74901960784314},
{name: 'Rhodamine', r: 0.96078431372549, g: 0.011764705882353, b: 0.98823529411765},
{name: 'Rhodamine Dark', r: 0.58039215686275, g: 0.14117647058824, b: 0.49803921568627},
{name: 'Carmine Red', r: 1, g: 0.34117647058824, b: 0.54901960784314},
{name: 'Violet Mist', r: 0.72156862745098, g: 0.83137254901961, b: 1},
{name: 'Dark Umber', r: 0.22352941176471, g: 0.090196078431373, b: 0.086274509803922},
{name: 'Sepia', r: 0.45882352941176, g: 0.44313725490196, b: 0.18823529411765},
{name: 'Sienna Brown', r: 0.83137254901961, g: 0.4156862745098, b: 0.44705882352941},
{name: 'Goldenrod', r: 0.92941176470588, g: 0.65098039215686, b: 0.43921568627451},
{name: 'Magenta', r: 1, g: 0.23921568627451, b: 0.96078431372549},
{name: 'Sand', r: 0.92941176470588, g: 0.76862745098039, b: 0.54901960784314},
{name: 'Buff', r: 0.92156862745098, g: 0.94117647058824, b: 0.92156862745098},
{name: 'Eggshell', r: 0.98039215686275, g: 0.96078431372549, b: 0.83921568627451},
{name: 'Flagstone Red', r: 0.66274509803922, g: 0.43529411764706, b: 0.72156862745098},
{name: 'Brick Beige', r: 0.98823529411765, g: 0.87058823529412, b: 0.76862745098039},
{name: 'Brick White', r: 0.96078431372549, g: 0.94901960784314, b: 0.89019607843137},
{name: 'Pink', r: 1, g: 0.43921568627451, b: 1},
{name: 'Putty', r: 0.90196078431373, g: 0.87058823529412, b: 0.83921568627451},
{name: 'Turquoise Dark', r: 0.10196078431373, g: 0.51372549019608, b: 0.77254901960784},
{name: 'Terra Cotta', r: 0.92941176470588, g: 0.41960784313725, b: 0.43921568627451},
{name: 'Cherry', r: 0.87058823529412, g: 0.24705882352941, b: 0.44705882352941},
{name: 'Dark Brown', r: 0.43529411764706, g: 0.45882352941176, b: 0.23137254901961},
{name: 'Light Walnut', r: 0.85098039215686, g: 0.8, b: 0.70980392156863},
{name: 'Blush Pink Light', r: 0.93333333333333, g: 0.79607843137255, b: 0.80392156862745},
{name: 'Walnut', r: 0.85882352941176, g: 0.58039215686275, b: 0.52156862745098},
{name: 'Burnt Ochre', r: 0.96078431372549, g: 0.65098039215686, b: 0.25098039215686},
{name: 'Light Tan', r: 0.73333333333333, g: 0.67450980392157, b: 0.49411764705882},
{name: 'Blondwood', r: 0.98039215686275, g: 0.96078431372549, b: 0.76078431372549},
{name: 'Warm Black', r: 0.023529411764706, g: 0.031372549019608, b: 0.031372549019608},
{name: 'Black', r: 0.023529411764706, g: 0.031372549019608, b: 0.031372549019608},
{name: 'Warm Grey 10%', r: 0.98823529411765, g: 0.98823529411765, b: 0.98823529411765}
];
});

View File

@ -0,0 +1,218 @@
jQuery(function($) {
$.colorpicker.swatchesNames['ral-classic'] = 'RAL Classic';
$.colorpicker.swatches['ral-classic'] = [
{name:'1000', r:0.80392156862745, g:0.72941176470588, b:0.53333333333333},
{name:'1001', r:0.8156862745098, g:0.69019607843137, b:0.51764705882353},
{name:'1002', r:0.82352941176471, g:0.66666666666667, b:0.42745098039216},
{name:'1003', r:0.97647058823529, g:0.65882352941176, b:0},
{name:'1004', r:0.89411764705882, g:0.61960784313725, b:0},
{name:'1005', r:0.79607843137255, g:0.55686274509804, b:0},
{name:'1006', r:0.88627450980392, g:0.56470588235294, b:0},
{name:'1007', r:0.90980392156863, g:0.54901960784314, b:0},
{name:'1011', r:0.68627450980392, g:0.50196078431373, b:0.30980392156863},
{name:'1012', r:0.86666666666667, g:0.68627450980392, b:0.15294117647059},
{name:'1013', r:0.89019607843137, g:0.85098039215686, b:0.77647058823529},
{name:'1014', r:0.86666666666667, g:0.76862745098039, b:0.60392156862745},
{name:'1015', r:0.90196078431373, g:0.82352941176471, b:0.70980392156863},
{name:'1016', r:0.94509803921569, g:0.86666666666667, b:0.21960784313725},
{name:'1017', r:0.96470588235294, g:0.66274509803922, b:0.31372549019608},
{name:'1018', r:0.98039215686275, g:0.7921568627451, b:0.18823529411765},
{name:'1019', r:0.64313725490196, g:0.56078431372549, b:0.47843137254902},
{name:'1020', r:0.62745098039216, g:0.56078431372549, b:0.39607843137255},
{name:'1021', r:0.96470588235294, g:0.71372549019608, b:0},
{name:'1023', r:0.96862745098039, g:0.70980392156863, b:0},
{name:'1024', r:0.72941176470588, g:0.56078431372549, b:0.29803921568627},
{name:'1026', r:1, g:1, b:0},
{name:'1027', r:0.65490196078431, g:0.49803921568627, b:0.054901960784314},
{name:'1028', r:1, g:0.6078431372549, b:0},
{name:'1032', r:0.88627450980392, g:0.63921568627451, b:0},
{name:'1033', r:0.97647058823529, g:0.60392156862745, b:0.10980392156863},
{name:'1034', r:0.92156862745098, g:0.61176470588235, b:0.32156862745098},
{name:'1035', r:0.56470588235294, g:0.51372549019608, b:0.43921568627451},
{name:'1036', r:0.50196078431373, g:0.3921568627451, b:0.24705882352941},
{name:'1037', r:0.94117647058824, g:0.57254901960784, b:0},
{name:'2000', r:0.85490196078431, g:0.43137254901961, b:0},
{name:'2001', r:0.72941176470588, g:0.28235294117647, b:0.10588235294118},
{name:'2002', r:0.74901960784314, g:0.22352941176471, b:0.13333333333333},
{name:'2003', r:0.96470588235294, g:0.47058823529412, b:0.15686274509804},
{name:'2004', r:0.88627450980392, g:0.32549019607843, b:0.011764705882353},
{name:'2005', r:1, g:0.30196078431373, b:0},
{name:'2007', r:1, g:0.69803921568627, b:0},
{name:'2008', r:0.92941176470588, g:0.41960784313725, b:0.12941176470588},
{name:'2009', r:0.87058823529412, g:0.32549019607843, b:0.027450980392157},
{name:'2010', r:0.8156862745098, g:0.36470588235294, b:0.15686274509804},
{name:'2011', r:0.88627450980392, g:0.43137254901961, b:0.054901960784314},
{name:'2012', r:0.83529411764706, g:0.39607843137255, b:0.30196078431373},
{name:'2013', r:0.57254901960784, g:0.24313725490196, b:0.14509803921569},
{name:'3000', r:0.65490196078431, g:0.16078431372549, b:0.12549019607843},
{name:'3001', r:0.6078431372549, g:0.14117647058824, b:0.13725490196078},
{name:'3002', r:0.6078431372549, g:0.13725490196078, b:0.12941176470588},
{name:'3003', r:0.52549019607843, g:0.10196078431373, b:0.13333333333333},
{name:'3004', r:0.41960784313725, g:0.10980392156863, b:0.13725490196078},
{name:'3005', r:0.34901960784314, g:0.098039215686275, b:0.12156862745098},
{name:'3007', r:0.24313725490196, g:0.12549019607843, b:0.13333333333333},
{name:'3009', r:0.42745098039216, g:0.20392156862745, b:0.17647058823529},
{name:'3011', r:0.47450980392157, g:0.14117647058824, b:0.13725490196078},
{name:'3012', r:0.77647058823529, g:0.51764705882353, b:0.42745098039216},
{name:'3013', r:0.5921568627451, g:0.18039215686275, b:0.14509803921569},
{name:'3014', r:0.79607843137255, g:0.45098039215686, b:0.45882352941176},
{name:'3015', r:0.84705882352941, g:0.62745098039216, b:0.65098039215686},
{name:'3016', r:0.65098039215686, g:0.23921568627451, b:0.1843137254902},
{name:'3017', r:0.79607843137255, g:0.33333333333333, b:0.36470588235294},
{name:'3018', r:0.78039215686275, g:0.24705882352941, b:0.29019607843137},
{name:'3020', r:0.73333333333333, g:0.11764705882353, b:0.062745098039216},
{name:'3022', r:0.81176470588235, g:0.41176470588235, b:0.33333333333333},
{name:'3024', r:1, g:0.17647058823529, b:0.12941176470588},
{name:'3026', r:1, g:0.16470588235294, b:0.10588235294118},
{name:'3027', r:0.67058823529412, g:0.15294117647059, b:0.23529411764706},
{name:'3028', r:0.8, g:0.17254901960784, b:0.14117647058824},
{name:'3031', r:0.65098039215686, g:0.20392156862745, b:0.2156862745098},
{name:'3032', r:0.43921568627451, g:0.11372549019608, b:0.13725490196078},
{name:'3033', r:0.64705882352941, g:0.22745098039216, b:0.17647058823529},
{name:'4001', r:0.50588235294118, g:0.38039215686275, b:0.51372549019608},
{name:'4002', r:0.55294117647059, g:0.23529411764706, b:0.29411764705882},
{name:'4003', r:0.76862745098039, g:0.38039215686275, b:0.54901960784314},
{name:'4004', r:0.39607843137255, g:0.11764705882353, b:0.21960784313725},
{name:'4005', r:0.46274509803922, g:0.4078431372549, b:0.60392156862745},
{name:'4006', r:0.56470588235294, g:0.2, b:0.45098039215686},
{name:'4007', r:0.27843137254902, g:0.14117647058824, b:0.23529411764706},
{name:'4008', r:0.51764705882353, g:0.29803921568627, b:0.50980392156863},
{name:'4009', r:0.6156862745098, g:0.52549019607843, b:0.57254901960784},
{name:'4010', r:0.73725490196078, g:0.25098039215686, b:0.46666666666667},
{name:'4011', r:0.43137254901961, g:0.38823529411765, b:0.52941176470588},
{name:'4012', r:0.41960784313725, g:0.41960784313725, b:0.49803921568627},
{name:'5000', r:0.1921568627451, g:0.30980392156863, b:0.43529411764706},
{name:'5001', r:0.058823529411765, g:0.29803921568627, b:0.3921568627451},
{name:'5002', r:0, g:0.21960784313725, b:0.48235294117647},
{name:'5003', r:0.12156862745098, g:0.21960784313725, b:0.33333333333333},
{name:'5004', r:0.098039215686275, g:0.11764705882353, b:0.15686274509804},
{name:'5005', r:0, g:0.32549019607843, b:0.52941176470588},
{name:'5007', r:0.2156862745098, g:0.41960784313725, b:0.54901960784314},
{name:'5008', r:0.16862745098039, g:0.22745098039216, b:0.26666666666667},
{name:'5009', r:0.13333333333333, g:0.37254901960784, b:0.47058823529412},
{name:'5010', r:0, g:0.30980392156863, b:0.48627450980392},
{name:'5011', r:0.10196078431373, g:0.16862745098039, b:0.23529411764706},
{name:'5012', r:0, g:0.53725490196078, b:0.71372549019608},
{name:'5013', r:0.098039215686275, g:0.1921568627451, b:0.32549019607843},
{name:'5014', r:0.38823529411765, g:0.49019607843137, b:0.58823529411765},
{name:'5015', r:0, g:0.48627450980392, b:0.69019607843137},
{name:'5017', r:0, g:0.35686274509804, b:0.54901960784314},
{name:'5018', r:0.019607843137255, g:0.54509803921569, b:0.54901960784314},
{name:'5019', r:0, g:0.36862745098039, b:0.51372549019608},
{name:'5020', r:0, g:0.25490196078431, b:0.29411764705882},
{name:'5021', r:0, g:0.45882352941176, b:0.46666666666667},
{name:'5022', r:0.13333333333333, g:0.17647058823529, b:0.35294117647059},
{name:'5023', r:0.25882352941176, g:0.41176470588235, b:0.54901960784314},
{name:'5024', r:0.37647058823529, g:0.57647058823529, b:0.67450980392157},
{name:'5025', r:0.12941176470588, g:0.41176470588235, b:0.48627450980392},
{name:'5026', r:0.058823529411765, g:0.18823529411765, b:0.32156862745098},
{name:'6000', r:0.23529411764706, g:0.45490196078431, b:0.37647058823529},
{name:'6001', r:0.21176470588235, g:0.40392156862745, b:0.2078431372549},
{name:'6002', r:0.19607843137255, g:0.34901960784314, b:0.15686274509804},
{name:'6003', r:0.31372549019608, g:0.32549019607843, b:0.23529411764706},
{name:'6004', r:0.007843137254902, g:0.26666666666667, b:0.25882352941176},
{name:'6005', r:0.066666666666667, g:0.25882352941176, b:0.19607843137255},
{name:'6006', r:0.23529411764706, g:0.22352941176471, b:0.18039215686275},
{name:'6007', r:0.17254901960784, g:0.19607843137255, b:0.13333333333333},
{name:'6008', r:0.2156862745098, g:0.20392156862745, b:0.16470588235294},
{name:'6009', r:0.15294117647059, g:0.2078431372549, b:0.16470588235294},
{name:'6010', r:0.30196078431373, g:0.43529411764706, b:0.22352941176471},
{name:'6011', r:0.42352941176471, g:0.48627450980392, b:0.34901960784314},
{name:'6012', r:0.18823529411765, g:0.23921568627451, b:0.22745098039216},
{name:'6013', r:0.49019607843137, g:0.46274509803922, b:0.35294117647059},
{name:'6014', r:0.27843137254902, g:0.25490196078431, b:0.2078431372549},
{name:'6015', r:0.23921568627451, g:0.23921568627451, b:0.21176470588235},
{name:'6016', r:0, g:0.41176470588235, b:0.29803921568627},
{name:'6017', r:0.34509803921569, g:0.49803921568627, b:0.25098039215686},
{name:'6018', r:0.38039215686275, g:0.6, b:0.23137254901961},
{name:'6019', r:0.72549019607843, g:0.8078431372549, b:0.67450980392157},
{name:'6020', r:0.2156862745098, g:0.25882352941176, b:0.1843137254902},
{name:'6021', r:0.54117647058824, g:0.6, b:0.46666666666667},
{name:'6022', r:0.22745098039216, g:0.2, b:0.15294117647059},
{name:'6024', r:0, g:0.51372549019608, b:0.31764705882353},
{name:'6025', r:0.36862745098039, g:0.43137254901961, b:0.23137254901961},
{name:'6026', r:0, g:0.37254901960784, b:0.30588235294118},
{name:'6027', r:0.49411764705882, g:0.72941176470588, b:0.70980392156863},
{name:'6028', r:0.1921568627451, g:0.32941176470588, b:0.25882352941176},
{name:'6029', r:0, g:0.43529411764706, b:0.23921568627451},
{name:'6032', r:0.13725490196078, g:0.49803921568627, b:0.32156862745098},
{name:'6033', r:0.27450980392157, g:0.52941176470588, b:0.49803921568627},
{name:'6034', r:0.47843137254902, g:0.67450980392157, b:0.67450980392157},
{name:'6035', r:0.098039215686275, g:0.30196078431373, b:0.14509803921569},
{name:'6036', r:0.015686274509804, g:0.34117647058824, b:0.29411764705882},
{name:'6037', r:0, g:0.54509803921569, b:0.16078431372549},
{name:'6038', r:0, g:0.70980392156863, b:0.10196078431373},
{name:'7000', r:0.47843137254902, g:0.53333333333333, b:0.55686274509804},
{name:'7001', r:0.54901960784314, g:0.58823529411765, b:0.6156862745098},
{name:'7002', r:0.50588235294118, g:0.47058823529412, b:0.38823529411765},
{name:'7003', r:0.47843137254902, g:0.46274509803922, b:0.41176470588235},
{name:'7004', r:0.6078431372549, g:0.6078431372549, b:0.6078431372549},
{name:'7005', r:0.42352941176471, g:0.43137254901961, b:0.41960784313725},
{name:'7006', r:0.46274509803922, g:0.4156862745098, b:0.36862745098039},
{name:'7008', r:0.45490196078431, g:0.36862745098039, b:0.23921568627451},
{name:'7009', r:0.36470588235294, g:0.37647058823529, b:0.34509803921569},
{name:'7010', r:0.34509803921569, g:0.36078431372549, b:0.33725490196078},
{name:'7011', r:0.32156862745098, g:0.34901960784314, b:0.36470588235294},
{name:'7012', r:0.34117647058824, g:0.36470588235294, b:0.36862745098039},
{name:'7013', r:0.34117647058824, g:0.31372549019608, b:0.26666666666667},
{name:'7015', r:0.30980392156863, g:0.32549019607843, b:0.34509803921569},
{name:'7016', r:0.21960784313725, g:0.24313725490196, b:0.25882352941176},
{name:'7021', r:0.1843137254902, g:0.19607843137255, b:0.20392156862745},
{name:'7022', r:0.29803921568627, g:0.29019607843137, b:0.26666666666667},
{name:'7023', r:0.50196078431373, g:0.50196078431373, b:0.46274509803922},
{name:'7024', r:0.27058823529412, g:0.28627450980392, b:0.30588235294118},
{name:'7026', r:0.2156862745098, g:0.26274509803922, b:0.27058823529412},
{name:'7030', r:0.57254901960784, g:0.55686274509804, b:0.52156862745098},
{name:'7031', r:0.35686274509804, g:0.4078431372549, b:0.42745098039216},
{name:'7032', r:0.70980392156863, g:0.69019607843137, b:0.63137254901961},
{name:'7033', r:0.49803921568627, g:0.50980392156863, b:0.45490196078431},
{name:'7034', r:0.57254901960784, g:0.53333333333333, b:0.43529411764706},
{name:'7035', r:0.77254901960784, g:0.78039215686275, b:0.76862745098039},
{name:'7036', r:0.5921568627451, g:0.57647058823529, b:0.57254901960784},
{name:'7037', r:0.47843137254902, g:0.48235294117647, b:0.47843137254902},
{name:'7038', r:0.69019607843137, g:0.69019607843137, b:0.66274509803922},
{name:'7039', r:0.41960784313725, g:0.4, b:0.36862745098039},
{name:'7040', r:0.59607843137255, g:0.61960784313725, b:0.63137254901961},
{name:'7042', r:0.55686274509804, g:0.57254901960784, b:0.56862745098039},
{name:'7043', r:0.30980392156863, g:0.32156862745098, b:0.31372549019608},
{name:'7044', r:0.71764705882353, g:0.70196078431373, b:0.65882352941176},
{name:'7045', r:0.55294117647059, g:0.57254901960784, b:0.5843137254902},
{name:'7046', r:0.49803921568627, g:0.52549019607843, b:0.54117647058824},
{name:'7047', r:0.7843137254902, g:0.7843137254902, b:0.78039215686275},
{name:'7048', r:0.50588235294118, g:0.48235294117647, b:0.45098039215686},
{name:'8000', r:0.53725490196078, g:0.41176470588235, b:0.24313725490196},
{name:'8001', r:0.6156862745098, g:0.3843137254902, b:0.16862745098039},
{name:'8002', r:0.47450980392157, g:0.30196078431373, b:0.24313725490196},
{name:'8003', r:0.49411764705882, g:0.29411764705882, b:0.14901960784314},
{name:'8004', r:0.55294117647059, g:0.28627450980392, b:0.1921568627451},
{name:'8007', r:0.43921568627451, g:0.27058823529412, b:0.16470588235294},
{name:'8008', r:0.44705882352941, g:0.29019607843137, b:0.14509803921569},
{name:'8011', r:0.35294117647059, g:0.21960784313725, b:0.14901960784314},
{name:'8012', r:0.4, g:0.2, b:0.16862745098039},
{name:'8014', r:0.29019607843137, g:0.2078431372549, b:0.14901960784314},
{name:'8015', r:0.36862745098039, g:0.1843137254902, b:0.14901960784314},
{name:'8016', r:0.29803921568627, g:0.16862745098039, b:0.12549019607843},
{name:'8017', r:0.26666666666667, g:0.1843137254902, b:0.16078431372549},
{name:'8019', r:0.23921568627451, g:0.21176470588235, b:0.2078431372549},
{name:'8022', r:0.10196078431373, g:0.090196078431373, b:0.094117647058824},
{name:'8023', r:0.64313725490196, g:0.34117647058824, b:0.16078431372549},
{name:'8024', r:0.47450980392157, g:0.31372549019608, b:0.21960784313725},
{name:'8025', r:0.45882352941176, g:0.34509803921569, b:0.27843137254902},
{name:'8028', r:0.31764705882353, g:0.22745098039216, b:0.16470588235294},
{name:'8029', r:0.49803921568627, g:0.25098039215686, b:0.1921568627451},
{name:'9001', r:0.91372549019608, g:0.87843137254902, b:0.82352941176471},
{name:'9002', r:0.84313725490196, g:0.83529411764706, b:0.79607843137255},
{name:'9003', r:0.92549019607843, g:0.92549019607843, b:0.90588235294118},
{name:'9004', r:0.16862745098039, g:0.16862745098039, b:0.17254901960784},
{name:'9005', r:0.054901960784314, g:0.054901960784314, b:0.062745098039216},
{name:'9006', r:0.63137254901961, g:0.63137254901961, b:0.62745098039216},
{name:'9007', r:0.52941176470588, g:0.52156862745098, b:0.50588235294118},
{name:'9010', r:0.94509803921569, g:0.92549019607843, b:0.88235294117647},
{name:'9011', r:0.15294117647059, g:0.16078431372549, b:0.16862745098039},
{name:'9016', r:0.94509803921569, g:0.94117647058824, b:0.91764705882353},
{name:'9017', r:0.16470588235294, g:0.16078431372549, b:0.16470588235294},
{name:'9018', r:0.7843137254902, g:0.79607843137255, b:0.76862745098039},
{name:'9022', r:0.52156862745098, g:0.52156862745098, b:0.51372549019608},
{name:'9023', r:0.47450980392157, g:0.48235294117647, b:0.47843137254902}
];
});

View File

@ -0,0 +1,150 @@
jQuery(function($) {
$.colorpicker.swatchesNames['x11'] = 'X11';
$.colorpicker.swatches['x11'] = [
{name: 'Alice Blue', r: 0.94, g: 0.97, b: 1},
{name: 'Antique White', r: 0.98, g: 0.92, b: 0.84},
{name: 'Aqua', r: 0, g: 1, b: 1},
{name: 'Aquamarine', r: 0.5, g: 1, b: 0.83},
{name: 'Azure', r: 0.94, g: 1, b: 1},
{name: 'Beige', r: 0.96, g: 0.96, b: 0.86},
{name: 'Bisque', r: 1, g: 0.89, b: 0.77},
{name: 'Black', r: 0, g: 0, b: 0},
{name: 'Blanched Almond', r: 1, g: 0.92, b: 0.8},
{name: 'Blue', r: 0, g: 0, b: 1},
{name: 'Blue Violet', r: 0.54, g: 0.17, b: 0.89},
{name: 'Brown', r: 0.65, g: 0.16, b: 0.16},
{name: 'Burlywood', r: 0.87, g: 0.72, b: 0.53},
{name: 'Cadet Blue', r: 0.37, g: 0.62, b: 0.63},
{name: 'Chartreuse', r: 0.5, g: 1, b: 0},
{name: 'Chocolate', r: 0.82, g: 0.41, b: 0.12},
{name: 'Coral', r: 1, g: 0.5, b: 0.31},
{name: 'Cornflower', r: 0.39, g: 0.58, b: 0.93},
{name: 'Cornsilk', r: 1, g: 0.97, b: 0.86},
{name: 'Crimson', r: 0.86, g: 0.08, b: 0.24},
{name: 'Cyan', r: 0, g: 1, b: 1},
{name: 'Dark Blue', r: 0, g: 0, b: 0.55},
{name: 'Dark Cyan', r: 0, g: 0.55, b: 0.55},
{name: 'Dark Goldenrod', r: 0.72, g: 0.53, b: 0.04},
{name: 'Dark Gray', r: 0.66, g: 0.66, b: 0.66},
{name: 'Dark Green', r: 0, g: 0.39, b: 0},
{name: 'Dark Khaki', r: 0.74, g: 0.72, b: 0.42},
{name: 'Dark Magenta', r: 0.55, g: 0, b: 0.55},
{name: 'Dark Olive Green', r: 0.33, g: 0.42, b: 0.18},
{name: 'Dark Orange', r: 1, g: 0.55, b: 0},
{name: 'Dark Orchid', r: 0.6, g: 0.2, b: 0.8},
{name: 'Dark Red', r: 0.55, g: 0, b: 0},
{name: 'Dark Salmon', r: 0.91, g: 0.59, b: 0.48},
{name: 'Dark Sea Green', r: 0.56, g: 0.74, b: 0.56},
{name: 'Dark Slate Blue', r: 0.28, g: 0.24, b: 0.55},
{name: 'Dark Slate Gray', r: 0.18, g: 0.31, b: 0.31},
{name: 'Dark Turquoise', r: 0, g: 0.81, b: 0.82},
{name: 'Dark Violet', r: 0.58, g: 0, b: 0.83},
{name: 'Deep Pink', r: 1, g: 0.08, b: 0.58},
{name: 'Deep Sky Blue', r: 0, g: 0.75, b: 1},
{name: 'Dim Gray', r: 0.41, g: 0.41, b: 0.41},
{name: 'Dodger Blue', r: 0.12, g: 0.56, b: 1},
{name: 'Firebrick', r: 0.7, g: 0.13, b: 0.13},
{name: 'Floral White', r: 1, g: 0.98, b: 0.94},
{name: 'Forest Green', r: 0.13, g: 0.55, b: 0.13},
{name: 'Fuchsia', r: 1, g: 0, b: 1},
{name: 'Gainsboro', r: 0.86, g: 0.86, b: 0.86},
{name: 'Ghost White', r: 0.97, g: 0.97, b: 1},
{name: 'Gold', r: 1, g: 0.84, b: 0},
{name: 'Goldenrod', r: 0.85, g: 0.65, b: 0.13},
{name: 'Gray', r: 0.75, g: 0.75, b: 0.75},
{name: 'Web Gray', r: 0.5, g: 0.5, b: 0.5},
{name: 'Green', r: 0, g: 1, b: 0},
{name: 'Web Green', r: 0, g: 0.5, b: 0},
{name: 'Green Yellow', r: 0.68, g: 1, b: 0.18},
{name: 'Honeydew', r: 0.94, g: 1, b: 0.94},
{name: 'Hot Pink', r: 1, g: 0.41, b: 0.71},
{name: 'Indian Red', r: 0.8, g: 0.36, b: 0.36},
{name: 'Indigo', r: 0.29, g: 0, b: 0.51},
{name: 'Ivory', r: 1, g: 1, b: 0.94},
{name: 'Khaki', r: 0.94, g: 0.9, b: 0.55},
{name: 'Lavender', r: 0.9, g: 0.9, b: 0.98},
{name: 'Lavender Blush', r: 1, g: 0.94, b: 0.96},
{name: 'Lawn Green', r: 0.49, g: 0.99, b: 0},
{name: 'Lemon Chiffon', r: 1, g: 0.98, b: 0.8},
{name: 'Light Blue', r: 0.68, g: 0.85, b: 0.9},
{name: 'Light Coral', r: 0.94, g: 0.5, b: 0.5},
{name: 'Light Cyan', r: 0.88, g: 1, b: 1},
{name: 'Light Goldenrod', r: 0.98, g: 0.98, b: 0.82},
{name: 'Light Gray', r: 0.83, g: 0.83, b: 0.83},
{name: 'Light Green', r: 0.56, g: 0.93, b: 0.56},
{name: 'Light Pink', r: 1, g: 0.71, b: 0.76},
{name: 'Light Salmon', r: 1, g: 0.63, b: 0.48},
{name: 'Light Sea Green', r: 0.13, g: 0.7, b: 0.67},
{name: 'Light Sky Blue', r: 0.53, g: 0.81, b: 0.98},
{name: 'Light Slate Gray', r: 0.47, g: 0.53, b: 0.6},
{name: 'Light Steel Blue', r: 0.69, g: 0.77, b: 0.87},
{name: 'Light Yellow', r: 1, g: 1, b: 0.88},
{name: 'Lime', r: 0, g: 1, b: 0},
{name: 'Lime Green', r: 0.2, g: 0.8, b: 0.2},
{name: 'Linen', r: 0.98, g: 0.94, b: 0.9},
{name: 'Magenta', r: 1, g: 0, b: 1},
{name: 'Maroon', r: 0.69, g: 0.19, b: 0.38},
{name: 'Web Maroon', r: 0.5, g: 0, b: 0},
{name: 'Medium Aquamarine', r: 0.4, g: 0.8, b: 0.67},
{name: 'Medium Blue', r: 0, g: 0, b: 0.8},
{name: 'Medium Orchid', r: 0.73, g: 0.33, b: 0.83},
{name: 'Medium Purple', r: 0.58, g: 0.44, b: 0.86},
{name: 'Medium Sea Green', r: 0.24, g: 0.7, b: 0.44},
{name: 'Medium Slate Blue', r: 0.48, g: 0.41, b: 0.93},
{name: 'Medium Spring Green', r: 0, g: 0.98, b: 0.6},
{name: 'Medium Turquoise', r: 0.28, g: 0.82, b: 0.8},
{name: 'Medium Violet Red', r: 0.78, g: 0.08, b: 0.52},
{name: 'Midnight Blue', r: 0.1, g: 0.1, b: 0.44},
{name: 'Mint Cream', r: 0.96, g: 1, b: 0.98},
{name: 'Misty Rose', r: 1, g: 0.89, b: 0.88},
{name: 'Moccasin', r: 1, g: 0.89, b: 0.71},
{name: 'Navajo White', r: 1, g: 0.87, b: 0.68},
{name: 'Navy Blue', r: 0, g: 0, b: 0.5},
{name: 'Old Lace', r: 0.99, g: 0.96, b: 0.9},
{name: 'Olive', r: 0.5, g: 0.5, b: 0},
{name: 'Olive Drab', r: 0.42, g: 0.56, b: 0.14},
{name: 'Orange', r: 1, g: 0.65, b: 0},
{name: 'Orange Red', r: 1, g: 0.27, b: 0},
{name: 'Orchid', r: 0.85, g: 0.44, b: 0.84},
{name: 'Pale Goldenrod', r: 0.93, g: 0.91, b: 0.67},
{name: 'Pale Green', r: 0.6, g: 0.98, b: 0.6},
{name: 'Pale Turquoise', r: 0.69, g: 0.93, b: 0.93},
{name: 'Pale Violet Red', r: 0.86, g: 0.44, b: 0.58},
{name: 'Papaya Whip', r: 1, g: 0.94, b: 0.84},
{name: 'Peach Puff', r: 1, g: 0.85, b: 0.73},
{name: 'Peru', r: 0.8, g: 0.52, b: 0.25},
{name: 'Pink', r: 1, g: 0.75, b: 0.8},
{name: 'Plum', r: 0.87, g: 0.63, b: 0.87},
{name: 'Powder Blue', r: 0.69, g: 0.88, b: 0.9},
{name: 'Purple', r: 0.63, g: 0.13, b: 0.94},
{name: 'Web Purple', r: 0.5, g: 0, b: 0.5},
{name: 'Rebecca Purple', r: 0.4, g: 0.2, b: 0.6},
{name: 'Red', r: 1, g: 0, b: 0},
{name: 'Rosy Brown', r: 0.74, g: 0.56, b: 0.56},
{name: 'Royal Blue', r: 0.25, g: 0.41, b: 0.88},
{name: 'Saddle Brown', r: 0.55, g: 0.27, b: 0.07},
{name: 'Salmon', r: 0.98, g: 0.5, b: 0.45},
{name: 'Sandy Brown', r: 0.96, g: 0.64, b: 0.38},
{name: 'Sea Green', r: 0.18, g: 0.55, b: 0.34},
{name: 'Seashell', r: 1, g: 0.96, b: 0.93},
{name: 'Sienna', r: 0.63, g: 0.32, b: 0.18},
{name: 'Silver', r: 0.75, g: 0.75, b: 0.75},
{name: 'Sky Blue', r: 0.53, g: 0.81, b: 0.92},
{name: 'Slate Blue', r: 0.42, g: 0.35, b: 0.8},
{name: 'Slate Gray', r: 0.44, g: 0.5, b: 0.56},
{name: 'Snow', r: 1, g: 0.98, b: 0.98},
{name: 'Spring Green', r: 0, g: 1, b: 0.5},
{name: 'Steel Blue', r: 0.27, g: 0.51, b: 0.71},
{name: 'Tan', r: 0.82, g: 0.71, b: 0.55},
{name: 'Teal', r: 0, g: 0.5, b: 0.5},
{name: 'Thistle', r: 0.85, g: 0.75, b: 0.85},
{name: 'Tomato', r: 1, g: 0.39, b: 0.28},
{name: 'Turquoise', r: 0.25, g: 0.88, b: 0.82},
{name: 'Violet', r: 0.93, g: 0.51, b: 0.93},
{name: 'Wheat', r: 0.96, g: 0.87, b: 0.7},
{name: 'White', r: 1, g: 1, b: 1},
{name: 'White Smoke', r: 0.96, g: 0.96, b: 0.96},
{name: 'Yellow', r: 1, g: 1, b: 0},
{name: 'Yellow Green', r: 0.6, g: 0.8, b: 0.2}
];
});

39
js/jquery-colorpicker/test/events.js vendored Normal file
View File

@ -0,0 +1,39 @@
module('events');
test('Empty input value should not set altField background to black', function() {
expect(4);
var $input = $('<input type="text" value=""/>').appendTo('#qunit-fixture');
var $altfield = $('<div></div>').appendTo('#qunit-fixture');
equal($altfield.css('backgroundColor'), 'rgba(0, 0, 0, 0)', 'Initial state, no color');
var jqcp = $input.colorpicker({
altField: $altfield
});
equal($altfield.css('backgroundColor'), 'rgba(0, 0, 0, 0)', 'After creation, no color');
jqcp.colorpicker('open');
equal($altfield.css('backgroundColor'), 'rgba(0, 0, 0, 0)', 'After open, no color');
jqcp.colorpicker('close');
equal($altfield.css('backgroundColor'), 'rgba(0, 0, 0, 0)', 'After close, no color');
});
asyncTest('Changing the color in input should trigger a \'change\' event on the input', function() {
expect(1);
var $input = $('<input type="text" value=""/>').appendTo('#qunit-fixture');
$input.change(function() {
ok(true, 'triggered');
start();
});
var jqcp = $input.colorpicker();
jqcp.colorpicker('setColor', 'red');
});

View File

@ -0,0 +1,19 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JQCP QUnit test</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.js"></script>
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/themes/ui-lightness/jquery-ui.css" rel="stylesheet" type="text/css"/>
<link rel="stylesheet" href="http://code.jquery.com/qunit/qunit-1.11.0.css"/>
<script src="http://code.jquery.com/qunit/qunit-1.11.0.js"></script>
</head>
<body>
<div id="qunit"></div>
<div id="qunit-fixture"></div>
<script src="../jquery.colorpicker.js"></script>
<script src="events.js"></script>
<script src="issues.js"></script>
</body>
</html>

22
js/jquery-colorpicker/test/issues.js vendored Normal file
View File

@ -0,0 +1,22 @@
module('issues');
test('#94: Clicking black swatch on empty input does not change input', function() {
expect(4);
var $input = $('<input type="text" value=""/>').appendTo('#qunit-fixture');
var jqcp = $input.colorpicker({
parts: ['swatches']
});
equal($input.val(), '', 'Starts empty');
jqcp.colorpicker('open');
equal($input.val(), '', 'Still empty on open');
$('.ui-colorpicker-swatch[title="white"]').click();
equal($input.val(), 'ffffff', 'Clicking white, input white');
$input.val('');
$('.ui-colorpicker-swatch[title="black"]').click();
equal($input.val(), '000000', 'Clicking black, input black (remains empty in issue #94).');
});

File diff suppressed because it is too large Load Diff