Download the PHP package arrratars/laravel without Composer
On this page you can find all versions of the php package arrratars/laravel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download arrratars/laravel
More information about arrratars/laravel
Files in arrratars/laravel
Package laravel
Short Description Beautifully crafted unique avatar placeholders for Laravel. A Laravel/PHP port of avvvatars. Deterministic SVG avatars generated from any string input. 60 shapes, 20 color palettes, zero dependencies.
License MIT
Informations about the package laravel
This project is literally avvvatars but for Laravel/PHP.
Same algorithm. Same 60 shapes. Same 20 color palettes. Same deterministic output.
All credit for the original design, shapes, and color system goes to:
- Nusu Alabuga (creator)
- Oguz Yagiz Kara
- Monika Michalczyk (shapes design)
Original repo: https://github.com/nusu/avvvatars
What it does
Pass any string → get a unique, deterministic SVG avatar.
The output is pure SVG. Not tied to Blade. Not tied to HTML. Use it literally anywhere.
Installation
Service provider is auto-discovered. Optionally publish the config:
Quick Start
All The Ways You Can Use It
1. API Endpoint (return as image)
Now you can do:
2. Save to S3
3. Save to local disk
4. Store in database
5. Use in <img> tag via base64
6. Inline SVG in Blade
7. Blade component
8. Helper functions
9. In JSON API responses
Options
| Option | Type | Default | Description |
|---|---|---|---|
style |
'character' | 'shape' |
'character' |
Initials or SVG shape |
size |
int | 32 | Size in pixels |
display_value |
string | null | Override the 2-letter text |
shadow |
bool | false | Drop shadow |
border |
bool | false | Border ring |
border_size |
int | 2 | Border width |
border_color |
string | '#fff' |
Border color |
radius |
int | size | Border radius (circle by default) |
Methods
| Method | Returns | Description |
|---|---|---|
svg($value, $options) |
string |
Complete SVG markup |
render($value, $options) |
string |
Alias for svg() |
toBase64($value, $options) |
string |
Base64 data URI for img src |
toDataUri($value, $options) |
string |
URL-encoded data URI |
toPng($value, $options) |
string |
PNG binary (needs Imagick) |
saveTo($value, $path, $options) |
bool |
Write to file |
How the output looks
The svg() method returns a self-contained SVG like this:
No external dependencies. No CSS required. No JavaScript. Works everywhere SVG is supported.
Credits
PHP/Laravel port of avvvatars. All design, shapes, and colors belong to the original avvvatars team.
License
MIT
All versions of laravel with dependencies
illuminate/support Version ^10.0|^11.0|^12.0
illuminate/view Version ^10.0|^11.0|^12.0