Hugo Dark Theme Site Generator https://after-dark.habd.as
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

blockquote.html 836B

1234567891011121314151617181920212223
  1. <!--{{/*
  2. Create pull quotes with citations and optional citation links.
  3. Basic usage:
  4. {{< blockquote cite="https://bitly.is/2mkxskj" citelink="https://bitly.is/2mkxskj" >}}
  5. When you create your own Branded Short Domain, you can expect to see up to a 34% increase in CTR when compared to standard bit.ly links.
  6. {{< /blockquote >}}
  7. */}}-->
  8. {{ $body := .Get "text" | default .Inner }}
  9. {{ $class := .Get "class" }}
  10. {{ $citelink := .Get "citelink" }}
  11. {{ $cite := .Get "cite" }}
  12. <blockquote{{ with $class }} class="{{ . }}"{{ end }}{{ with $citelink }} cite="{{ . }}"{{ end }}>
  13. <p>{{- $body | plainify -}}</p>
  14. {{ if $citelink }}
  15. <cite>{{ partial "shortcode/external.html" (dict "href" $citelink "body" $cite) }}</cite>
  16. {{ else if $cite }}
  17. <cite>{{ $cite }}</cite>
  18. {{ else }}
  19. <cite>N.N.</cite>
  20. {{ end }}
  21. </blockquote>