diff --git a/layouts/shortcodes/grid.html b/layouts/shortcodes/grid.html index 17a3610c..66753f9b 100644 --- a/layouts/shortcodes/grid.html +++ b/layouts/shortcodes/grid.html @@ -2,7 +2,7 @@ doc: Grids. -{{< grid >}} +{{< grid columns="1 2 2 3">}} {{< card >}} title = 'Only title' @@ -25,11 +25,6 @@ ''' {{< /card >}} -{{< /grid >}} - - -{{< grid >}} - {{< card >}} title = 'A card with a dropdown menu' body = ''' @@ -46,19 +41,6 @@ link = 'https://example.com' {{< /card >}} -{{< /grid >}} - - -{{< grid >}} - -{{< card >}} -header = 'Header' -title = 'Card Title' -body = 'Card content' -footer = 'Footer' -{{< /card >}} - - {{< card >}} header = 'Header' title = 'Card Title' @@ -71,7 +53,16 @@ */}}
-
+{{- with .Get "columns" -}} + {{ $columns := split . " " }} + {{ $xs := index $columns 0 }} + {{ $sm := index $columns 1 }} + {{ $md := index $columns 2 }} + {{ $lg := index $columns 3 }} +
+{{- else }} +
+{{- end }} {{ .Inner }}