more details
This commit is contained in:
parent
794180fbd2
commit
cc7dfe584a
4 changed files with 53 additions and 19 deletions
|
@ -149,6 +149,14 @@ func (hf *HistoricalFigure) FirstName() string {
|
|||
return strings.Split(hf.Name_, " ")[0]
|
||||
}
|
||||
|
||||
func (hf *HistoricalFigure) Goals() string {
|
||||
return andList(util.Map(hf.Goal, func(g HistoricalFigureGoal) string { return g.String() }))
|
||||
}
|
||||
|
||||
func (hf *HistoricalFigure) Pets() string {
|
||||
return andList(util.Map(hf.JourneyPet, func(g string) string { return articled(strings.ToLower(g)) }))
|
||||
}
|
||||
|
||||
func (x *Honor) Requirement() string {
|
||||
var list []string
|
||||
if x.RequiresAnyMeleeOrRangedSkill {
|
||||
|
|
|
@ -4,20 +4,37 @@
|
|||
|
||||
{{define "content"}}
|
||||
<h3>{{ title .Name }}</h3>
|
||||
{{if .Female }}
|
||||
<i class="fa-solid fa-venus fa-xs"></i>
|
||||
{{else}}
|
||||
<i class="fa-solid fa-mars fa-xs"></i>
|
||||
{{end}}
|
||||
{{ .Race }}
|
||||
{{ if .Deity}}deity{{end}}
|
||||
{{ if .Force}}force{{end}}
|
||||
{{ if .Vampire}}vampire{{end}}
|
||||
{{ if .Werebeast}}werebeast{{end}}
|
||||
{{ if .Necromancer}}necromancer{{end}}
|
||||
{{ if not (or .Deity .Force)}}
|
||||
(*{{ .BirthYear }}{{ if ge .DeathYear 0 }} †{{ .DeathYear }}{{ end }})
|
||||
{{ end }}
|
||||
<p>
|
||||
{{if .Female }}
|
||||
<i class="fa-solid fa-venus fa-xs"></i>
|
||||
{{else}}
|
||||
<i class="fa-solid fa-mars fa-xs"></i>
|
||||
{{end}}
|
||||
{{ .Race }}
|
||||
{{ if .Deity}}deity{{end}}
|
||||
{{ if .Force}}force{{end}}
|
||||
{{ if .Vampire}}vampire{{end}}
|
||||
{{ if .Werebeast}}werebeast{{end}}
|
||||
{{ if .Necromancer}}necromancer{{end}}
|
||||
{{ if not (or .Deity .Force)}}
|
||||
(*{{ .BirthYear }}{{ if ge .DeathYear 0 }} †{{ .DeathYear }}{{ end }})
|
||||
{{ end }}
|
||||
</p>
|
||||
|
||||
<dl class="row">
|
||||
{{- if gt (len .Sphere) 0 -}}
|
||||
<dt class="col-2 col-lg-1">Spheres</dt>
|
||||
<dd class="col-10 col-lg-11">{{ andList .Sphere }}</dd>
|
||||
{{- end -}}
|
||||
{{- if gt (len .Goal) 0 -}}
|
||||
<dt class="col-2 col-lg-1">Goals</dt>
|
||||
<dd class="col-10 col-lg-11">{{ .Goals }}</dd>
|
||||
{{- end -}}
|
||||
{{- if gt (len .JourneyPet) 0 -}}
|
||||
<dt class="col-2 col-lg-1">Pets</dt>
|
||||
<dd class="col-10 col-lg-11">{{ .Pets }}</dd>
|
||||
{{- end -}}
|
||||
</dl>
|
||||
|
||||
<div class="row mt-3">
|
||||
<div class="col-4">
|
||||
|
|
|
@ -3,12 +3,15 @@
|
|||
{{define "title"}}{{ title .Name }}{{end}}
|
||||
|
||||
{{define "content"}}
|
||||
<h1>{{ title .Name }}</h1>
|
||||
<h3>{{ title .Name }}</h3>
|
||||
<p>{{ if .IsVolcano }}volcano{{else}}mountain{{end}}</p>
|
||||
|
||||
<dl class="row">
|
||||
<dt class="col-2 col-lg-1">Height</dt>
|
||||
<dd class="col-10 col-lg-11">{{ .Height }}</dd>
|
||||
</dl>
|
||||
|
||||
<h5>Events</h5>
|
||||
{{ template "events.html" events . }} <p>{{ json . }}</p>
|
||||
|
||||
{{ template "events.html" events . }}
|
||||
|
||||
<p>{{ json . }}</p>
|
||||
{{- end }}
|
|
@ -6,8 +6,14 @@
|
|||
<h3>{{ title .Name }}</h3>
|
||||
<p>{{ .Type }}</p>
|
||||
|
||||
<h5>Events</h5>
|
||||
{{- if ne .ForceId -1 -}}
|
||||
<dl class="row">
|
||||
<dt class="col-2 col-lg-1">Force</dt>
|
||||
<dd class="col-10 col-lg-11">{{ hf .ForceId }}</dd>
|
||||
</dl>
|
||||
{{- end -}}
|
||||
|
||||
<h5>Events</h5>
|
||||
{{ template "events.html" events . }}
|
||||
|
||||
<p>{{ json . }}</p>
|
||||
|
|
Loading…
Reference in a new issue