package main

import "html/template"

type LiveEventMessagePageParams struct {
	BaseEventPageParams
	OpenGraphParams
	HeadParams

	Details          DetailsParams
	Content          template.HTML
	TitleizedContent string

	Clients []ClientReference
}

templ liveEventMessageInnerBlock(params LiveEventMessagePageParams) {
	@templ.Raw(params.Content)
}

templ liveEventMessageTemplate(params LiveEventMessagePageParams, isEmbed bool) {
	<!DOCTYPE html>
	if isEmbed {
		@embeddedPageTemplate(
			params.Event,
			params.NeventNaked,
		) {
			@liveEventMessageInnerBlock(params)
		}
	} else {
		@eventPageTemplate(
			params.TitleizedContent,
			params.OpenGraphParams,
			params.HeadParams,
			params.Clients,
			params.Details,
			params.Event,
		) {
			@liveEventMessageInnerBlock(params)
		}
	}
}
