fix some youtube videos not properly loading (#2726)

* add player iframe to bskyweb

* iframe for youtube content

* update tests

* ts error
This commit is contained in:
Hailey 2024-02-06 11:05:17 -08:00 committed by GitHub
parent a9ab13e5a9
commit 856f80fc6d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 71 additions and 23 deletions

View file

@ -159,6 +159,7 @@ func serve(cctx *cli.Context) error {
e.GET("/security.txt", func(c echo.Context) error {
return c.Redirect(http.StatusMovedPermanently, "/.well-known/security.txt")
})
e.GET("/iframe/youtube.html", echo.WrapHandler(staticHandler))
e.GET("/static/*", echo.WrapHandler(http.StripPrefix("/static/", staticHandler)), func(next echo.HandlerFunc) echo.HandlerFunc {
return func(c echo.Context) error {
path := c.Request().URL.Path