Be notified of new releases
Create your free GitHub account today to subscribe to this repository for new releases and build software alongside 28 million developers.Sign up
Added 2 attributes: backgroundColor and borderColor.
backgroundColor allows to modify the color of the main background, and
borderColor allows to modify the color of the external border.
New Feature: Change values of the fields with up/down keys
This makes it possible to change values quickly, but with maximum precision.
You can turn on/off this feature by setting
Colpick Remix is now Wcolpick!
The new name is more simple and immediate: Wcolpick -> Web Color Picker
I'm developing also a desktop color picker: Dcolpick
1. Renamed as Wcolpick.
2. Renamed jQuery.fn functions.
I've removed "colpick" from the name of the function, so the new names are:
1. Added 3 new options:
submitBackground, you can change the background color of the fields and the button: it is possible to set a color object or an hexadecimal (like
enableSubmit (it was necessary).
3. Now, if the string is unidentified,
decodeFromCSS will return an hsba object.
4. Now, if the inputed parameter is a string,
encodeToCSS will return the string untouched.
- General cleanup and optimizations.
positionwill be always lowercased.
7. Code improvements:
- Removed comments from all the options, to reduce the size of the file: there is documentation for this!
- Alphabetically reordered all the options.
1. Merged the 4 files "color-schemes.css", "layouts.css", "layouts-s.css" and "layouts-xl.css" into "colpickRmx.css".
Now is more simple uploading and using the plugin (there are only 2 files to upload rather than 6!)
2. Now is possible to display the color picker at the center of viewport.
You can set "position" property value to "center" (only for flat="false").
3. Now is possible to override the automatic positioning.
You can set "top" and "left" of the attribute "overridePos", that is received on the "onBeforeShow" function's object.
4. Added 2 new jQuery functions:
- encodeToCSS: Converts an rgba, hsba, hsla object into a string like "rgba(.....)" or "hsla(.....)".
- decodeFromCSS: Does the opposite of the previous function.
5. Added compatibility with hsl/hsla color spaces (hsla: hsl + alpha channel).
- The object received by onChange and onSubmit, now, will contain also the hsl and hsla attributes of the chosen color.
- Now, is possible to send an hsl/hsla color to "setColpickColor", and is possible to set an hsl/hsla color at "color" property (in both cases it will be converted into hsba).
- Now, is possible to obtain an hsl/hsla object from "getColpickColor" function, by send "hsl" or "hsla" as type.
- Added 6 new jQuery functions to convert from/to hsla: "hexToHsla", "rgbaToHsla", "hsbaToHsla", "hslaToHex", "hslaToRgba", "hslaToHsba".
- Improved performance: readapted/rewrited various functions, and removed various useless color space conversions.
- Changed behaviour of livePreview: now, the "mousemove" event will move the indicators (but will not update colors).
- Slightly reorganized the HTML structure of the plugin.
- Removed double "--" from the names of color schemes, and replaced with a single "-": With this change, "light--full" becomes "light-full", and "dark--full" becomes "dark-full".
- For greyscale colors (with the same r,g,b values), now, the hue will be setted at 0, rather than 300.
- The colors entered by input, now, will be always checked, to avoid wrong values.
HAPPY NEW YEAR!
Added "arrowsColor" and "checkersColor" options.
- Replaced "lightArrows" with "arrowsColor": now is possible to force both light or dark color for arrows.
- Added "checkersColor" option: it do the same as "arrowsColor", but with checkerboards.
1. [MILESTONE] The plugin now fully supports the Alpha Channel!
The Alpha Channel is a value between 0 to 1 (represented by a percent value between 0 to 100), that represents the opacity of the color (0 means transparent, and 1 means full opacity): https://en.wikipedia.org/wiki/Alpha_compositing
2. Releated to Alpha Channel:
- Is always possible to enable or disable the Alpha Channel with the new option "enableAlpha" (Default: "true").
- Added a checkerboard behind the two, new and current, colors to show correctly the change in opacity.
3. Added support to hex shortcuts!
3 chars and 4 chars hexadecimals strings: https://en.wikipedia.org/wiki/Web_colors#Shorthand_hexadecimal_form
4. Changed style of Submit button.
The new design is a circle with a drop inside. (Removed the text)
5. Now, if you change the value of a field by using arrows, the field's arrows will change color.
Is possible to change this color in "color-schemes.css": https://github.com/firestormxyz/colpick-remix/blob/b521513a9bf4eb6284c5f4fa09a66f695167e766/colpick-remix/color-schemes.css#L77
6. Added 4 new options to show or hide the outlines of Alpha bar, Hue bar, Current and New color, and Color Selector.
The options are respectively: "alphaOutline", "hueOutline", "colorOutline", and "colorSelOutline".
7. Added an option to choose the width to the external border of the plugin.
It's an integer value that specify the width in pixels.
8. Now is possible to cancel destruction of color picker by simply return false to onDestroy.
9. Rewrited getCurrentColpickColor as getColpickColor, and added functionality:
- As the name says, now this function can return also the new color, as well as the current.
- The new rewrited function can also return whatever type of color you want (rgb, rgb + alpha, hsb, hsb + alpha, hex, hex + alpha).
(See documentation for more info)
10. Other improvements:
- Merged all parameters of all "callback functions" (onLoaded, onBeforeShow, etc...) in a single object.
(IMPORTANT: With this change is necessary to change the way to obtain the single parameters from this functions, I will explain later how to do)
- Now, if livePreview is 'false', the color will be updated only on click and release, for all elements of the plugin.
- Redesigned Small variant to improve legibility.
- Changed font to "Arial" to improve compatibility (there are no notable visual changes between "Arial" and "Aktiv Grotesk").
- Generally improved all layouts, and reduced size of css files.
- Replaced parseInt with Math.round, where it was possible, to improve performance (see this: https://jsperf.com/math-floor-vs-math-round-vs-parseint/55).
- Improved compatibility with older browsers.
- Moved css files in "colpick-remix" folder, and removed the "css" folder.
- Other various improvements that I don't remember.
- Fixed a bug that allowed to set a hue value and, maybe, saturation and brightness values, beyond the limits!
- Now, in input fields, if you not change the value, the onChange will no longer be fired (except when livePreview is false, where is necessary!).
- Other various bugfixes that I don't remember.
1. Added new Compact Style
Makes the layouts more compact, to save space!
2. Added Readonly option
Added options to set input fields (or only hex field) as readonly.
3. Readded appendToBody option as a feature
Now, "appendToBody" is a feature, and is not related to the previous "positioning bug"! (That bug is fixed!)
4. Improvements and bugfix
- Improved algorithm that manages dynamic positioning.
- Renamed some classes.