You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+27-22
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,7 @@
19
19
Great UX starts with two basic principles - ease of use and simplicity. Selecting a color should be as easy as moving a slider, clicking a checkbox or pressing a key just like other basic form elements behave.
20
20
21
21
This is a flexible and minimalistic color picker. Developed with mobile devices and keyboard usage in mind. Key features:
22
-
* Small size - 3.7 KB gzipped (JS and CSS combined)
22
+
* Small size - 3.45 KB gzipped (JS and CSS combined)
23
23
* Supports touch devices
24
24
* Optimized animations
25
25
* Ease of use
@@ -36,7 +36,7 @@ The right color picker, but not the framework you're looking for?
| hue | Number |`0`| A number between `0-359`. **Required**. |
105
+
| saturation | Number |`100`| A number between `0-100`|
106
+
| luminosity | Number |`50`| A number between `0-100`|
107
+
| alpha | Number |`1`| A number between `0-1`|
108
+
| disabled | Boolean |`false`| A boolean to disable UI interactions |
109
+
| step | Number |`2`| Amount of degrees to rotate the picker with keyboard and/or wheel. |
110
+
| variant | String |`collapsible`| Use `persistent` to prevent collapsing/closing |
111
+
| initiallyCollapsed | Boolean |`false`| Hides the palette initially |
112
+
| mouseScroll | Boolean |`false`| Use wheel (scroll) event to rotate. |
107
113
108
114
[Back To Top](#quick-links)
109
115
@@ -121,13 +127,12 @@ Depending on your build tool of choice (webpack, parcel, rollup) you may have to
121
127
122
128
<details>
123
129
<summary>Why is the scroll-to-rotate functionality not turned on by default?</summary>
124
-
<p>It's another non-passive event that could potentially introduce jank on scroll. To rotate the color knob, but stay on the same scrolling position the <code>wheel</code> event is blocked with <code>preventDefault()</code>. Thus, if you really want this feature for your users you'll have to explicitly add <code>:mouse-scroll="true"</code>.</p>
130
+
<p>It's another non-passive event that could potentially introduce jank on scroll. To rotate the color knob, but stay on the same scrolling position the <code>wheel</code> event is blocked with <code>preventDefault()</code>. Thus, if you really want this feature for your users you'll have to explicitly add <code>mouseScroll="true"</code>.</p>
125
131
</details>
126
132
<br>
127
133
128
134
[Back To Top](#quick-links)
129
135
130
-
131
136
## Change log
132
137
133
138
Please see [Releases][link-releases] for more information on what has changed recently.
0 commit comments