package pages import ( "git.ekzyis.com/ekzyis/delphi.market/server/router/pages/components" "git.ekzyis.com/ekzyis/delphi.market/types" "github.com/dustin/go-humanize" ) // TODO: Add countdown? Use or at least show somewhere precise timestamps? templ Market(m types.Market, p0 []types.Point, p1 []types.Point, quoteNo types.MarketQuote, quoteYes types.MarketQuote, uQuantityNo int, uQuantityYes int) { @components.Head() @components.Nav()
{ m.Question }
{ humanize.Time(m.EndDate) }
if m.Description != "" { { m.Description } } else { <empty> }
― { m.User.Name }, { humanize.Time(m.CreatedAt) }
@components.MarketForm(m, 1, quoteYes, uQuantityYes)
@components.MarketForm(m, 0, quoteNo, uQuantityNo)
@components.Modal(nil) @components.Footer() }