mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-10-29 15:02:25 -05:00
[feature] Use blurhashes in frontend, tidy up gallery view a bit (#3948)
* [feature] Use blurhashes in frontend, tidy up gallery view a bit * weeeeeeeeeeeeeeeee * beep boop
This commit is contained in:
parent
85fb63f46f
commit
3949117be0
17 changed files with 508 additions and 124 deletions
|
|
@ -48,10 +48,10 @@ type WebPage struct {
|
|||
// Can be nil.
|
||||
Stylesheets []string
|
||||
|
||||
// Paths to JS files to add to
|
||||
// the page as "script" entries.
|
||||
// JS files to add to the
|
||||
// page as "script" entries.
|
||||
// Can be nil.
|
||||
Javascript []string
|
||||
Javascript []JavascriptEntry
|
||||
|
||||
// Extra parameters to pass to
|
||||
// the template for rendering,
|
||||
|
|
@ -60,6 +60,21 @@ type WebPage struct {
|
|||
Extra map[string]any
|
||||
}
|
||||
|
||||
type JavascriptEntry struct {
|
||||
// Insert <script> tag at the end
|
||||
// of <body> rather than in <head>.
|
||||
Bottom bool
|
||||
|
||||
// Path to the js file.
|
||||
Src string
|
||||
|
||||
// Use async="" attribute.
|
||||
Async bool
|
||||
|
||||
// Use defer="" attribute.
|
||||
Defer bool
|
||||
}
|
||||
|
||||
// TemplateWebPage renders the given HTML template and
|
||||
// page params within the standard GtS "page" template.
|
||||
//
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue