Skip to content
Permalink
Browse files

Remove space between icon and text in meta fields

When minify, the meta icon + text starts rendering
w/o space in between. So, regular and minified
versions are slightly different. To avoid this, we
use only margin-right to the icon for a consistent
look with or without minification.
  • Loading branch information
Vimux committed Mar 25, 2020
1 parent 2260591 commit aff8789609d199e938b7508c23c60bdb389f51aa
Showing with 4 additions and 4 deletions.
  1. +2 −2 layouts/partials/post_meta/categories.html
  2. +2 −2 layouts/partials/post_meta/date.html
@@ -1,7 +1,7 @@
{{- $taxo := "categories" -}}
{{- with .Param $taxo }}
{{- with .Param $taxo -}}
<div class="meta__item-categories meta__item">
{{ partial "svg/category.svg" (dict "class" "meta__icon") }}
{{- partial "svg/category.svg" (dict "class" "meta__icon") -}}
<span class="meta__text">
{{- range $index, $category := . }}
{{- $url := urls.Parse ($category | urlize) -}}
@@ -1,13 +1,13 @@
{{- if not .Date.IsZero }}
<div class="meta__item-datetime meta__item">
{{ partial "svg/time.svg" (dict "class" "meta__icon") }}
{{ partial "svg/time.svg" (dict "class" "meta__icon") -}}
<time class="meta__text" datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">
{{- .Date.Format (.Site.Params.dateformat | default "January 02, 2006") -}}
</time>
{{- if ne .Date .Lastmod }}
<time class="meta__text" datetime="{{ .Lastmod.Format "2006-01-02T15:04:05Z07:00" }}">(
{{- T "meta_lastmod" }}: {{ .Lastmod.Format (.Site.Params.dateformat | default "January 02, 2006") -}}
)</time>
{{- end }}
{{- end -}}
</div>
{{- end }}

0 comments on commit aff8789

Please sign in to comment.
You can’t perform that action at this time.