Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/vicktornl/wagtail-stock-images
Search stock images (e.g. via Unsplash) and save them to your Wagtail image library.
https://github.com/vicktornl/wagtail-stock-images
Last synced: 3 months ago
JSON representation
Search stock images (e.g. via Unsplash) and save them to your Wagtail image library.
- Host: GitHub
- URL: https://github.com/vicktornl/wagtail-stock-images
- Owner: vicktornl
- License: mit
- Created: 2022-01-17T08:06:56.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2022-02-24T21:25:47.000Z (almost 3 years ago)
- Last Synced: 2024-04-16T23:48:52.443Z (9 months ago)
- Language: Python
- Homepage:
- Size: 536 KB
- Stars: 11
- Watchers: 0
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-wagtail - Wagtail Stock Images - Search stock images (e.g. via Unsplash) and save them to your Wagtail image library. (Apps / Media)
README
# Wagtail Stock Images
[![Version](https://img.shields.io/pypi/v/wagtail-stock-images.svg?style=flat)](https://pypi.python.org/pypi/wagtail-stock-images/)
![CI](https://github.com/vicktornl/wagtail-stock-images/actions/workflows/ci.yml/badge.svg)Search stock images (e.g. via Unsplash) and save them to your Wagtail image library.
![Search](./docs/search.jpg)
![Saving](./docs/saving.jpg)## Requirements
- Python 3
- Django >= 2
- Wagtail >= 3## Installation
Install the package
```
pip install wagtail-stock-images
```Add `wagtail_stock_images` to your `INSTALLED_APPS`
```python
INSTALLED_APPS = [
...
"wagtail_stock_images",
]
```## Settings
`WAGTAIL_STOCK_IMAGES_SEARCH_ENGINE`
Default: `wagtail_stock_images.contrib.unsplash.UnsplashSearchEngine`
## Available search engines
### Unsplash
```python
WAGTAIL_STOCK_IMAGES_SEARCH_ENGINE = "wagtail_stock_images.contrib.unsplash.UnsplashSearchEngine"
WAGTAIL_STOCK_IMAGES_UNSPLASH_CLIENT_ID = ""
WAGTAIL_STOCK_IMAGES_UNSPLASH_CLIENT_SECRET = ""
WAGTAIL_STOCK_IMAGES_UNSPLASH_REDIRECT_URI = ""
```## Custom search engine
```python
from wagtail_stock_images.engine import AbstractSearchEnginefrom MyCustomSearchEngine(AbstractSearchEngine):
...
```