|
|
# Frontend plugins
|
|
|
|
|
|
## Wallpapers
|
|
|
|
|
|
You may include wallpaper components for your plugins. They must reside in the `wallpapers` folder in your plugin.
|
|
|
|
|
|
The naming of your wallpaper components can be anything you want. There's no guidelines on the naming schemes besides being CamelCase, but it's recommended to include at least your plugin name and append `Wallpaper`. This ensures there won't be any naming conflicts with other plugins.
|
|
|
|
|
|
The structure would look like this:
|
|
|
|
|
|
```bash
|
|
|
.
|
|
|
├── plugins
|
|
|
│ ├── SimpleWallpaperPlugin
|
|
|
│ │ └── wallpapers
|
|
|
│ │ └── SimpleWallpaper.vue
|
|
|
```
|
|
|
|
|
|
A Wallpaper component must specify the following data in its default export object:
|
|
|
|
|
|
* `wallpaper`
|
|
|
|
|
|
Example code:
|
|
|
|
|
|
```javascript
|
|
|
export default {
|
|
|
name: 'SimpleWallpaper', // must match the filename
|
|
|
wallpaper: {
|
|
|
label: 'Solid color wallpaper'
|
|
|
},
|
|
|
// ... other VueJS code
|
|
|
}
|
|
|
```
|
|
|
|
|
|
Omitting these data points will cause the wallpaper to not show up in the "Wallpaper" system settings page, therefor the user will not be able to use it. |
|
|
\ No newline at end of file |