Add functions to get wallpaper urls

This commit is contained in:
bytedream 2022-06-23 14:27:15 +02:00
parent bfad0caa9a
commit a283ba7247

View file

@ -1,4 +1,14 @@
package crunchyroll package crunchyroll
import "fmt"
// Wallpaper contains a wallpaper name which can be set via Account.ChangeWallpaper. // Wallpaper contains a wallpaper name which can be set via Account.ChangeWallpaper.
type Wallpaper string type Wallpaper string
func (w *Wallpaper) TinyUrl() string {
return fmt.Sprintf("https://static.crunchyroll.com/assets/wallpaper/360x115/%s", *w)
}
func (w *Wallpaper) BigUrl() string {
return fmt.Sprintf("https://static.crunchyroll.com/assets/wallpaper/1920x400/%s", *w)
}