package api import ( "net/http" "github.com/gin-gonic/gin" ) var userIconSvg = []byte(` `) var faceIconSvg = []byte(` `) var cameraIconSvg = []byte(` `) var photoIconSvg = []byte(` `) var rawIconSvg = []byte(` `) var fileIconSvg = []byte(` `) var videoIconSvg = []byte(` `) var folderIconSvg = []byte(``) var albumIconSvg = folderIconSvg var labelIconSvg = []byte(` `) var portraitIconSvg = []byte(` `) var brokenIconSvg = []byte(` `) var uncachedIconSvg = []byte(` `) // GetSvg returns SVG placeholder symbols. // // GET /api/v1/svg/* func GetSvg(router *gin.RouterGroup) { router.GET("/svg/user", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", userIconSvg) }) router.GET("/svg/face", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", faceIconSvg) }) router.GET("/svg/camera", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", cameraIconSvg) }) router.GET("/svg/photo", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", photoIconSvg) }) router.GET("/svg/raw", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", rawIconSvg) }) router.GET("/svg/file", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", fileIconSvg) }) router.GET("/svg/video", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", videoIconSvg) }) router.GET("/svg/label", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", labelIconSvg) }) router.GET("/svg/portrait", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", portraitIconSvg) }) router.GET("/svg/folder", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", folderIconSvg) }) router.GET("/svg/album", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", albumIconSvg) }) router.GET("/svg/broken", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", brokenIconSvg) }) router.GET("/svg/uncached", func(c *gin.Context) { c.Data(http.StatusOK, "image/svg+xml", uncachedIconSvg) }) }