From 6abdfe6dcbbc1e256b8712697a52e394c1741717 Mon Sep 17 00:00:00 2001 From: Scott Anderson Date: Tue, 4 Aug 2020 08:50:17 -0600 Subject: [PATCH] added contrib fn note, added link to group key definition --- .../reference/flux/stdlib/contrib/rows/map.md | 3 ++- layouts/partials/article.html | 1 + layouts/partials/article/flux-contrib.html | 22 +++++++++++++++++++ 3 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 layouts/partials/article/flux-contrib.html diff --git a/content/v2.0/reference/flux/stdlib/contrib/rows/map.md b/content/v2.0/reference/flux/stdlib/contrib/rows/map.md index cd9f0ceb8..de9e9fb77 100644 --- a/content/v2.0/reference/flux/stdlib/contrib/rows/map.md +++ b/content/v2.0/reference/flux/stdlib/contrib/rows/map.md @@ -15,7 +15,8 @@ related: The `rows.map()` function is an alternate implementation of [`map()`](/v2.0/reference/flux/stdlib/built-in/transformations/map/) that is faster, but more limited than `map()`. -`rows.map()` cannot modify table groups key and, therefore, does not need to regroup tables. +`rows.map()` cannot modify [groups keys](/v2.0/reference/glossary/#group-key) and, +therefore, does not need to regroup tables. **Attempts to change columns in the group key are ignored.** _**Function type:** Transformation_ diff --git a/layouts/partials/article.html b/layouts/partials/article.html index dd52b1fa6..c995adfa9 100644 --- a/layouts/partials/article.html +++ b/layouts/partials/article.html @@ -4,6 +4,7 @@ {{ partial "article/product-tags.html" . }} {{ partial "article/stable-version.html" . }} {{ partial "article/flux-experimental.html" . }} + {{ partial "article/flux-contrib.html" . }} {{ .Content }} {{ partial "article/related.html" . }} {{ partial "article/tags.html" . }} diff --git a/layouts/partials/article/flux-contrib.html b/layouts/partials/article/flux-contrib.html new file mode 100644 index 000000000..61bd2f794 --- /dev/null +++ b/layouts/partials/article/flux-contrib.html @@ -0,0 +1,22 @@ +{{ $currentVersion := (index (findRE "[^/]+.*?" .RelPermalink) 0) .RelPermalink }} +{{ $contribPath := print "/" $currentVersion "/reference/flux/stdlib/contrib/" }} + +{{ if in .RelPermalink $contribPath }} + {{ if not (eq .RelPermalink $contribPath) }} + {{ if eq .Kind "page" }} + {{ $name := replaceRE `^\w*\.\w*\(\)` "$0" .Title }} +
+

+ The {{ $name | safeHTML }} is a user-contributed function maintained by the package author. +

+
+ {{ else if eq .Kind "section" }} +
+

+ The {{ if $.Params.list_title }}{{ $.Params.list_title }}{{ else }}{{ .Title }}{{ end }} + is a user-contributed package maintained by the package author. +

+
+ {{ end }} + {{ end }} +{{ end }}