{{ define "user/fragments/vouchButton" }} {{ $isVouched := false }} {{ $isDenounced := false }} {{ if .VouchRelationship }} {{ if .VouchRelationship.IsDirectVouch }} {{ $isVouched = true }} {{ else if .VouchRelationship.IsDirectDenounce }} {{ $isDenounced = true }} {{ end }} {{ end }} {{ $userDid := "" }} {{ with .VouchRelationship }} {{ $userDid = .SubjectDid.String }} {{ end }} {{ $popoverId := index . "PopoverId" }} {{ if not $popoverId }}{{ $popoverId = printf "vouch-modal-%s" (normalizeForHtmlId $userDid) }}{{ end }} {{ end }}