aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/twbs/bootstrap/site/layouts/shortcodes
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2021-07-29 08:25:05 +0000
committerMario <mario@mariovavti.com>2021-07-29 08:25:05 +0000
commitd459dfac74e90c29950d49a82edc19fd913d435e (patch)
tree7bed5f2dbc318f87bbe0f4be2cde3dde09cd97c7 /vendor/twbs/bootstrap/site/layouts/shortcodes
parentcec2f0d894b80f3affeb60cff2d4afa49a2019a8 (diff)
downloadvolse-hubzilla-d459dfac74e90c29950d49a82edc19fd913d435e.tar.gz
volse-hubzilla-d459dfac74e90c29950d49a82edc19fd913d435e.tar.bz2
volse-hubzilla-d459dfac74e90c29950d49a82edc19fd913d435e.zip
update to bootstrap 5.0.2
Diffstat (limited to 'vendor/twbs/bootstrap/site/layouts/shortcodes')
-rw-r--r--vendor/twbs/bootstrap/site/layouts/shortcodes/bs-table.html9
-rw-r--r--vendor/twbs/bootstrap/site/layouts/shortcodes/scss-docs.html33
-rw-r--r--vendor/twbs/bootstrap/site/layouts/shortcodes/table.html30
3 files changed, 72 insertions, 0 deletions
diff --git a/vendor/twbs/bootstrap/site/layouts/shortcodes/bs-table.html b/vendor/twbs/bootstrap/site/layouts/shortcodes/bs-table.html
new file mode 100644
index 000000000..40b9b8ce5
--- /dev/null
+++ b/vendor/twbs/bootstrap/site/layouts/shortcodes/bs-table.html
@@ -0,0 +1,9 @@
+{{- /*
+ Usage: `bs-table "class class-foo"`,
+ where class can be anything
+*/ -}}
+
+{{- $css_class := .Get 0 | default "table" -}}
+{{- $html_table := .Inner | markdownify -}}
+{{- $html_table = replace $html_table "<table>" (printf `<table class="%s">` $css_class) -}}
+{{- $html_table | safeHTML -}}
diff --git a/vendor/twbs/bootstrap/site/layouts/shortcodes/scss-docs.html b/vendor/twbs/bootstrap/site/layouts/shortcodes/scss-docs.html
new file mode 100644
index 000000000..16a906e77
--- /dev/null
+++ b/vendor/twbs/bootstrap/site/layouts/shortcodes/scss-docs.html
@@ -0,0 +1,33 @@
+{{- /*
+ Usage: `scss-docs name="name" file="file/_location.scss"`
+
+ Prints everything between `// scss-docs-start "name"` and `// scss-docs-end "name"`
+ comments in the docs.
+
+ Optional parameters:
+ strip-default: Remove the ` !default` flag from variable assignments - default: `true`
+*/ -}}
+
+{{- $name := .Get "name" -}}
+{{- $file := .Get "file" -}}
+{{- $strip_default := .Get "strip-default" | default "true" -}}
+
+{{- $start := printf "// scss-docs-start %s\n" $name -}}
+{{- $end := printf "// scss-docs-end %s" $name -}}
+{{- $regex := printf "%s(.|\n)*%s" $start $end -}}
+
+{{- $css := readFile $file -}}
+{{- $match := findRE $regex $css 1 -}}
+
+{{- if (eq (len $match) 0) -}}
+ {{- errorf "Got no matches for %q in %q! (called in %q)" $name $file $.Page.Path -}}
+{{- end -}}
+
+{{- $remove_start := replace (index $match 0) $start "" -}}
+{{- $result := replace $remove_start $end "" -}}
+
+{{- if (ne $strip_default "false") -}}
+ {{- $result = replace $result " !default" "" -}}
+{{- end -}}
+
+{{- highlight $result "scss" "" -}}
diff --git a/vendor/twbs/bootstrap/site/layouts/shortcodes/table.html b/vendor/twbs/bootstrap/site/layouts/shortcodes/table.html
new file mode 100644
index 000000000..43f230ab8
--- /dev/null
+++ b/vendor/twbs/bootstrap/site/layouts/shortcodes/table.html
@@ -0,0 +1,30 @@
+{{- /*
+ Usage: `table [args]`
+
+ `args` are optional and can be one of the following:
+ class: any class(es) to be added to the `table` - default ""
+ simplified: show a simplified version in the examples - default `true`
+*/ -}}
+
+{{- $simplified := .Get "simplified" | default true -}}
+
+{{- $table_attributes := "" -}}
+{{- $table_content := " ...\n" -}}
+
+{{- with .Get "class" -}}
+{{- $table_attributes = printf ` class="%s"` . -}}
+{{- end -}}
+
+{{- if eq $simplified "false" -}}
+{{- $table_content = partialCached "table-content" . -}}
+{{- end -}}
+
+{{- $table := printf "<table%s>\n%s</table>" $table_attributes $table_content -}}
+
+<div class="bd-example">
+ <table{{ with .Get "class" }} class="{{ . }}"{{ end }}>
+ {{ partialCached "table-content" . }}
+ </table>
+</div>
+
+{{- highlight $table "html" "" -}}