Skip to content

Commit 5da3093

Browse files
committed
Add example auto color
1 parent 03277c8 commit 5da3093

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,12 @@ $image = $avatar->background('#ff0000')->generate();
111111
$image = $avatar->color('#ff0000')->generate();
112112
````
113113

114+
### Auto Color
115+
````php
116+
// Will choose a background color based on `name` and a contrasting font color. The color for a specific name will always be the same.
117+
$image = $avatar->autoColor()->generate();
118+
````
119+
114120
### Font file - default: /fonts/OpenSans-Regular.ttf
115121
Two fonts with two variants are included:
116122
* /fonts/OpenSans-Regular.ttf

0 commit comments

Comments
 (0)