Files
soundcloak/templates/misc.templ
Laptop 39787b6cc9 5
2025-08-28 18:00:48 +03:00

27 lines
543 B
Plaintext

package templates
import (
"git.maid.zone/stuff/soundcloak/lib/cfg"
"git.maid.zone/stuff/soundcloak/lib/textparsing"
)
templ Description(prefs cfg.Preferences, text string, injected templ.Component) {
if text != "" || injected != nil {
<details>
<summary>Description</summary>
<p style="white-space: pre-wrap;">
if text != "" {
if *prefs.ParseDescriptions {
@templ.Raw(textparsing.Format(text))
} else {
{ text }
}
}
if injected != nil {
@injected
}
</p>
</details>
}
}