diff --git a/README.md b/README.md index 9e76983..38830dd 100644 --- a/README.md +++ b/README.md @@ -94,6 +94,20 @@ public function panel(Panel $panel): Panel } ``` +### Available image providers + +#### `Swis\Filament\Backgrounds\Images\CuratedBySwis` + +Default curated set of (free to use) images from [multiple sources](#license), based on the day of the month. You can find the images in the [resources/images/curated-by-swis](resources/images/curated-by-swis) directory. + +#### `Swis\Filament\Backgrounds\Images\MyImages` + +[Use your own images](#use-your-own-images). + +#### `Swis\Filament\Backgrounds\Images\Triangles` + +A set of low poly patterns created using [Trianglify](https://github.com/qrohlf/trianglify). You can find the patterns in the [resources/images/triangles](resources/images/triangles) directory. + ### Writing a custom image provider To create your own image provider, you need to implement the `ProvidesImages` interface. This interface has one method, `getImage`, which should return an `Image` object. The image object takes two arguments, the first is the CSS `background-image` property, the second is the attribution text. The image will be directly used as background-image in CSS, so it should include `url()`, which allows you to even use gradients or other fancy stuff! diff --git a/resources/images/triangles/01.svg b/resources/images/triangles/01.svg new file mode 100644 index 0000000..aaab77f --- /dev/null +++ b/resources/images/triangles/01.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/02.svg b/resources/images/triangles/02.svg new file mode 100644 index 0000000..7fe8e75 --- /dev/null +++ b/resources/images/triangles/02.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/03.svg b/resources/images/triangles/03.svg new file mode 100644 index 0000000..003627a --- /dev/null +++ b/resources/images/triangles/03.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/04.svg b/resources/images/triangles/04.svg new file mode 100644 index 0000000..89be450 --- /dev/null +++ b/resources/images/triangles/04.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/05.svg b/resources/images/triangles/05.svg new file mode 100644 index 0000000..a04cf5f --- /dev/null +++ b/resources/images/triangles/05.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/06.svg b/resources/images/triangles/06.svg new file mode 100644 index 0000000..3ea8434 --- /dev/null +++ b/resources/images/triangles/06.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/07.svg b/resources/images/triangles/07.svg new file mode 100644 index 0000000..8d99b64 --- /dev/null +++ b/resources/images/triangles/07.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/08.svg b/resources/images/triangles/08.svg new file mode 100644 index 0000000..28a3697 --- /dev/null +++ b/resources/images/triangles/08.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/09.svg b/resources/images/triangles/09.svg new file mode 100644 index 0000000..f837590 --- /dev/null +++ b/resources/images/triangles/09.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/10.svg b/resources/images/triangles/10.svg new file mode 100644 index 0000000..31f0e99 --- /dev/null +++ b/resources/images/triangles/10.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/11.svg b/resources/images/triangles/11.svg new file mode 100644 index 0000000..b192dce --- /dev/null +++ b/resources/images/triangles/11.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/12.svg b/resources/images/triangles/12.svg new file mode 100644 index 0000000..cc304c1 --- /dev/null +++ b/resources/images/triangles/12.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/13.svg b/resources/images/triangles/13.svg new file mode 100644 index 0000000..499ddd1 --- /dev/null +++ b/resources/images/triangles/13.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/14.svg b/resources/images/triangles/14.svg new file mode 100644 index 0000000..bd4b12f --- /dev/null +++ b/resources/images/triangles/14.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/15.svg b/resources/images/triangles/15.svg new file mode 100644 index 0000000..fce3c5c --- /dev/null +++ b/resources/images/triangles/15.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/16.svg b/resources/images/triangles/16.svg new file mode 100644 index 0000000..f570c80 --- /dev/null +++ b/resources/images/triangles/16.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/17.svg b/resources/images/triangles/17.svg new file mode 100644 index 0000000..3c77b07 --- /dev/null +++ b/resources/images/triangles/17.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/18.svg b/resources/images/triangles/18.svg new file mode 100644 index 0000000..d3fa766 --- /dev/null +++ b/resources/images/triangles/18.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/19.svg b/resources/images/triangles/19.svg new file mode 100644 index 0000000..2c81f15 --- /dev/null +++ b/resources/images/triangles/19.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/20.svg b/resources/images/triangles/20.svg new file mode 100644 index 0000000..f16e7aa --- /dev/null +++ b/resources/images/triangles/20.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/21.svg b/resources/images/triangles/21.svg new file mode 100644 index 0000000..dce83a6 --- /dev/null +++ b/resources/images/triangles/21.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/22.svg b/resources/images/triangles/22.svg new file mode 100644 index 0000000..ce4ca62 --- /dev/null +++ b/resources/images/triangles/22.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/23.svg b/resources/images/triangles/23.svg new file mode 100644 index 0000000..1bd80e7 --- /dev/null +++ b/resources/images/triangles/23.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/24.svg b/resources/images/triangles/24.svg new file mode 100644 index 0000000..41d41e2 --- /dev/null +++ b/resources/images/triangles/24.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/resources/images/triangles/25.svg b/resources/images/triangles/25.svg new file mode 100644 index 0000000..a3bd90c --- /dev/null +++ b/resources/images/triangles/25.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/ImageProviders/Triangles.php b/src/ImageProviders/Triangles.php new file mode 100644 index 0000000..e6fa07c --- /dev/null +++ b/src/ImageProviders/Triangles.php @@ -0,0 +1,21 @@ +getImage(); + + expect($image->image)->toStartWith('url("http://localhost/images/swisnl/filament-backgrounds/triangles/')->toEndWith('.svg")'); +});