Skip to content

Commit

Permalink
clean up feature state examples, style guide (#14699)
Browse files Browse the repository at this point in the history
  • Loading branch information
kbhawkey authored and k8s-ci-robot committed Jun 4, 2019
1 parent e66b9a5 commit 88fe150
Showing 1 changed file with 18 additions and 20 deletions.
38 changes: 18 additions & 20 deletions content/en/docs/contribute/style/hugo-shortcodes/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Read more about shortcodes in the [Hugo documentation](https://gohugo.io/content
{{% /capture %}}

{{% capture body %}}

## Feature state

In a markdown page (`.md` file) on this site, you can add a shortcode to display version and state of the documented feature.
Expand Down Expand Up @@ -39,50 +40,49 @@ The valid values for `state` are:

The displayed Kubernetes version defaults to that of the page or the site. This can be changed by passing the <code>for_k8s_version</code> shortcode parameter.

````
```
{{</* feature-state for_k8s_version="v1.10" state="stable" */>}}
````
```

Renders to:

{{< feature-state for_k8s_version="v1.10" state="stable" >}}

#### Alpha feature

````
{{</* feature-state feature-state state="alpha" */>}}
````
```
{{</* feature-state state="alpha" */>}}
```

Renders to:

{{< feature-state state="alpha" >}}


#### Beta feature

````
{{</* feature-state feature-state state="beta" */>}}
````
```
{{</* feature-state state="beta" */>}}
```

Renders to:

{{< feature-state state="beta" >}}

#### Stable feature

````
{{</* feature-state feature-state state="stable" */>}}
````
```
{{</* feature-state state="stable" */>}}
```

Renders to:

{{< feature-state state="stable" >}}

#### Deprecated feature

````
{{</* feature-state feature-state state="deprecated" */>}}
````
```
{{</* feature-state state="deprecated" */>}}
```

Renders to:

Expand All @@ -99,9 +99,9 @@ The raw data for glossary terms is stored at [https://github.com/kubernetes/webs

For example, the following include within the markdown renders to {{< glossary_tooltip text="cluster" term_id="cluster" >}} with a tooltip:

````liquid
```liquid
{{</* glossary_tooltip text="cluster" term_id="cluster" */>}}
````
```

## Table captions

Expand Down Expand Up @@ -235,7 +235,6 @@ Renders to:
{{< tab name="JSON File" include="podtemplate" />}}
{{< /tabs >}}


{{% /capture %}}

{{% capture whatsnext %}}
Expand All @@ -244,5 +243,4 @@ Renders to:
* Learn about [using page templates](/docs/home/contribute/page-templates/).
* Learn about [staging your changes](/docs/home/contribute/stage-documentation-changes/)
* Learn about [creating a pull request](/docs/home/contribute/create-pull-request/).
{{% /capture %}}

{{% /capture %}}

0 comments on commit 88fe150

Please sign in to comment.