Skip to content

Commit 5a368ad

Browse files
committed
docs: update readme
1 parent a4696d1 commit 5a368ad

File tree

2 files changed

+39
-3
lines changed

2 files changed

+39
-3
lines changed

README.md

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,45 @@
44
55
🎨 Vue Color Pickers for Sketch, Photoshop, Chrome & more
66

7+
![image](https://user-images.githubusercontent.com/30174970/114983369-1e5aa380-9ec3-11eb-9e77-b122d19f1ebd.png)
78

8-
## [Live demo](https://ckpack.github.io/vue-color)
9+
## [Demo](https://ckpack.github.io/vue-color)
910

11+
## Example
12+
```js
13+
<Sketch v-model="colors"/>
14+
15+
import { Sketch } from '@ckpack/vue-color';
16+
17+
let colors = {
18+
hex: '#194d33',
19+
hex8: '#194D33A8',
20+
hsl: { h: 150, s: 0.5, l: 0.2, a: 1 },
21+
hsv: { h: 150, s: 0.66, v: 0.30, a: 1 },
22+
rgba: { r: 25, g: 77, b: 51, a: 1 },
23+
a: 1
24+
};
25+
// or
26+
let colors = '#194d33';
27+
// or
28+
let colors = '#194D33A8';
29+
// or
30+
let colors = { h: 150, s: 0.66, v: 0.30 };
31+
// or
32+
let colors = { r: 255, g: 0, b: 0 };
33+
// etc...
34+
35+
new Vue({
36+
components: {
37+
Sketch,
38+
},
39+
data () {
40+
return {
41+
colors,
42+
};
43+
},
44+
});
45+
```
1046
## License
1147

1248
vue-color is licensed under [The MIT License](LICENSE).

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"name": "vue-color",
3-
"version": "0.0.1",
2+
"name": "@ckpack/vue-color",
3+
"version": "0.0.2",
44
"description": "(vue3.0) 🎨 Vue Color Pickers for Sketch, Photoshop, Chrome & more",
55
"repository": "https://github.com/ckpack/vue-color",
66
"main": "dist/vue-color.ssr.js",

0 commit comments

Comments
 (0)