Sha256: e5f6d151de97aab514cac412d3acd6fcb95a1fcc8657a3b913182cb9f38fb4b4

Contents?: true

Size: 345 Bytes

Versions: 6

Compression:

Stored size: 345 Bytes

Contents

;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
			);
		}
	};
});

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
jquery-colorpicker-rails-1.0.16.5 app/assets/javascripts/parsers/jquery.ui.colorpicker-cmyk-percentage-parser.js
jquery-colorpicker-rails-1.0.16.4 vendor/assets/javascripts/parsers/jquery.ui.colorpicker-cmyk-percentage-parser.js
jquery-colorpicker-rails-1.0.16.3 vendor/assets/javascripts/parsers/jquery.ui.colorpicker-cmyk-percentage-parser.js
jquery-colorpicker-rails-1.0.16.2 vendor/assets/javascripts/parsers/jquery.ui.colorpicker-cmyk-percentage-parser.js
jquery-colorpicker-rails-1.0.16.1 vendor/assets/javascripts/parsers/jquery.ui.colorpicker-cmyk-percentage-parser.js
jquery-colorpicker-rails-1.0.16.0 vendor/assets/javascripts/parsers/jquery.ui.colorpicker-cmyk-percentage-parser.js