diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 7d4b9e867..c3faf8075 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -144,13 +144,27 @@ Insert enterprise-specific markdown content here. #### Enterprise name The name used to refer to InfluxData's enterprise offering is subject to change. -To facilitate easy updates in the future, use the `enterprise-name` shortcode when referencing the enterprise product. +To facilitate easy updates in the future, use the `enterprise-name` shortcode +when referencing the enterprise product. +This shortcode accepts a `"short"` parameter which uses the "short-name". ``` This is content that references {{< enterprise-name >}}. +This is content that references {{< enterprise-name "short" >}}. ``` -The product name is stored in `data/products.yml` +Product names are stored in `data/products.yml`. + +#### Enterprise link +References to InfluxDB Enterprise are often accompanied with a link to a page where +visitors can get more information about the Enterprise offering. +This link is subject to change. +Use the `enterprise-link` shortcode when including links to more information about +InfluxDB Enterprise. + +``` +Find more info [here][{{< enterprise-link >}}] +``` ### InfluxDB Cloud Content Some articles are unique to InfluxDB Cloud or at least contain some information specific to InfluxDB Cloud. @@ -187,13 +201,27 @@ Insert Cloud-specific markdown content here. #### InfluxDB Cloud name The name used to refer to InfluxData's cloud offering is subject to change. -To facilitate easy updates in the future, use the `cloud-name` short-code when referencing the cloud product. +To facilitate easy updates in the future, use the `cloud-name` short-code when +referencing the cloud product. +This shortcode accepts a `"short"` parameter which uses the "short-name". ``` This is content that references {{< cloud-name >}}. +This is content that references {{< cloud-name "short" >}}. ``` -The product name is stored in `data/products.yml` +Product names are stored in `data/products.yml`. + +#### InfluxDB Cloud link +References to InfluxDB Cloud are often accompanied with a link to a page where +visitors can get more information. +This link is subject to change. +Use the `cloud-link` shortcode when including links to more information about +InfluxDB Cloud. + +``` +Find more info [here][{{< cloud-link >}}] +``` ### Tabbed Content Shortcodes are available for creating "tabbed" content (content that is changed by a users' selection). diff --git a/data/products.yml b/data/products.yml index 1b948459b..7e06495f9 100644 --- a/data/products.yml +++ b/data/products.yml @@ -1,5 +1,6 @@ enterprise: - name: "InfluxDB 2.0 Enterprise" + name: "InfluxDB Enterprise 2" + shortname: "InfluxDB Enterprise" link: "#" cloud: diff --git a/layouts/shortcodes/enterprise-link.html b/layouts/shortcodes/enterprise-link.html new file mode 100644 index 000000000..b1b18c290 --- /dev/null +++ b/layouts/shortcodes/enterprise-link.html @@ -0,0 +1 @@ +{{- .Site.Data.products.enterprise.link -}} diff --git a/layouts/shortcodes/enterprise-name.html b/layouts/shortcodes/enterprise-name.html index 779715e99..29dd5af9b 100644 --- a/layouts/shortcodes/enterprise-name.html +++ b/layouts/shortcodes/enterprise-name.html @@ -1 +1,6 @@ -{{- .Site.Data.products.enterprise.name -}} +{{ $length := .Get 0 | default "long" }} +{{- if eq $length "long" }} + {{- .Site.Data.products.enterprise.name -}} +{{ else if eq $length "short" }} + {{- .Site.Data.products.enterprise.shortname -}} +{{ end -}}