Add Showy Homepage dashboard widget
Homepage widget with totals, library, and watchlist mappings. Displays total entries, collections, favorites, library breakdown (movies/series), and watchlist breakdown (movies/series).
This commit is contained in:
1 parent
63aca7e7b8
commit
e660b1ec87
3 files changed
+149
No files matched your search
@@ -0,0 +1,66 @@
|
||||
# Showy Dashboard — Homepage Widget
|
||||
|
||||
Displays Showy library stats on your Homepage dashboard.
|
||||
|
||||
## Setup
|
||||
|
||||
### 1. Showy Access Token
|
||||
|
||||
In your Showy settings pages you can generate a token. Copy it and use it in the widget configuration below.
|
||||
|
||||
The endpoint will be available at `GET /homepage-integration?token=your-secret-token-here`
|
||||
|
||||
### 2. Copy widget into your Homepage install
|
||||
|
||||
Copy this folder (`showydashboard/`) into your Homepage's `src/widgets/` directory.
|
||||
|
||||
### 3. Register the widget
|
||||
|
||||
**`src/widgets/widgets.js`** — add:
|
||||
|
||||
```js
|
||||
import showydashboard from "./showydashboard/widget";
|
||||
|
||||
const widgets = {
|
||||
// ...
|
||||
showydashboard: showydashboard,
|
||||
};
|
||||
```
|
||||
|
||||
**`src/widgets/components.js`** — add:
|
||||
|
||||
```js
|
||||
const components = {
|
||||
// ...
|
||||
showydashboard: dynamic(() => import("./showydashboard/component")),
|
||||
};
|
||||
```
|
||||
|
||||
### 4. Add to your Homepage services.yaml
|
||||
|
||||
```yaml
|
||||
- Showy Library:
|
||||
icon: /icons/showy.png
|
||||
description: Movies & TV-Series Tracking library
|
||||
widget:
|
||||
type: showydashboard
|
||||
url: http://YOUR-SHOWY-HOST:4000
|
||||
dashboardToken: your-secret-token-here
|
||||
fields: ["library", "libraryMovies", "librarySeries", "watchlist", "watchlistMovies", "watchlistSeries"]
|
||||
```
|
||||
|
||||
### Available fields
|
||||
|
||||
| Field | Description |
|
||||
|---|---|
|
||||
| `totalEntries` | All entries in the library |
|
||||
| `library` | Entries not in watchlist |
|
||||
| `libraryMovies` | Movies not in watchlist |
|
||||
| `librarySeries` | TV series not in watchlist |
|
||||
| `watchlist` | Entries in watchlist |
|
||||
| `watchlistMovies` | Movies in watchlist |
|
||||
| `watchlistSeries` | TV series in watchlist |
|
||||
| `collections` | Total collections |
|
||||
| `favorits` | Favorite entries |
|
||||
|
||||
Omit `fields` to show all 9. `url` is just the host base — the widget appends `/api/v1/homepage-integration?token=...` automatically.
|
||||
Reference in new issue
Block a user