@@ -105,8 +105,7 @@ The Docsy code tabs look like this:
105105To generate the above tabs, this is what you need to write.
106106Note that the ` tabpane ` includes ` langEqualsHeader=true ` .
107107This auto-formats the code in each tab to match the header name,
108- but more importantly it ensures that all tabs on the page with a language
109- are set to the same thing, so we always want to include it.
108+ and ensures that all tabs on the page with a language are set to the same thing.
110109
111110 {{</* tabpane langEqualsHeader=true */>}}
112111 {{</* tab header="Java" */>}}
@@ -129,7 +128,7 @@ are set to the same thing, so we always want to include it.
129128 {{</* /tab */>}}
130129 {{</* /tabpane */>}}
131130
132- #### Reference Github Examples
131+ #### Reference GitHub Examples
133132
134133To ensure that all code is kept up to date, our goal is to write the code in the repo where it
135134can be executed when Selenium versions are updated to ensure that everything is correct.
@@ -138,19 +137,18 @@ All code examples to be in our
138137[ example directories] ( https://github.com/SeleniumHQ/seleniumhq.github.io/tree/dev/examples ) .
139138
140139This code can be automatically displayed in the documentation using the ` gh-codeblock ` shortcode.
141- The shortcode automatically generates its own html, so if any tab is using this shortcode,
142- set ` text=true ` in the ` tabpane ` /` tab ` to prevent the auto-formatting, and add ` code=true ` in any
143- ` tab ` that still needs to get formatted with code.
144- Either way, set ` langEqualsHeader=true ` to keep the language tabs synchronized throughout the page.
145- Note that the ` gh-codeblock ` line can not be indented at all.
140+ The shortcode automatically generates its own html, so we do not want it to auto-format with the language header.
141+ If all tabs are using this shortcode, set ` text=true ` in the ` tabpane ` and remove ` langEqualsHeader=true ` .
142+ If only some tabs are using this shortcode, keep ` langEqualsHeader=true ` in the ` tabpane ` and add ` text=true `
143+ to the ` tab ` . Note that the ` gh-codeblock ` line can not be indented at all.
146144
147145One great thing about using ` gh-codeblock ` is that it adds a link to the full example.
148146This means you don't have to include any additional context code, just the line(s) that
149147are needed, and the user can navigate to the repo to see how to use it.
150148
151149A basic comparison of code looks like:
152150
153- {{</* tabpane text=true langEqualsHeader=true */>}}
151+ {{</* tabpane text=true */>}}
154152 {{</* tab header="Java" */>}}
155153 {{</* gh-codeblock path="examples/java/src/test/java/dev/selenium/getting_started/FirstScript.java#L46-L47" */>}}
156154 {{</* /tab */>}}
@@ -173,7 +171,7 @@ A basic comparison of code looks like:
173171
174172Which looks like this:
175173
176- {{< tabpane text=true langEqualsHeader=true >}}
174+ {{< tabpane text=true >}}
177175{{< tab header="Java" >}}
178176{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/getting_started/FirstScript.java#L46-L47" >}}
179177{{< /tab >}}
@@ -200,7 +198,7 @@ If you want your example to include something other than code (default) or html
200198you need to first set ` text=true ` ,
201199then change the Hugo syntax for the ` tab ` to use ` % ` instead of ` < ` and ` > ` with curly braces:
202200
203- {{</* tabpane text=true langEqualsHeader=true */>}}
201+ {{</* tabpane text=true */>}}
204202 {{%/* tab header="Java" */%}}
205203 1. Start the driver
206204 {{</* gh-codeblock path="examples/java/src/test/java/dev/selenium/getting_started/FirstScript.java#L17" */>}}
@@ -214,7 +212,7 @@ then change the Hugo syntax for the `tab`to use `%` instead of `<` and `>` with
214212
215213This produces:
216214
217- {{< tabpane text=true langEqualsHeader=true >}}
215+ {{< tabpane text=true >}}
218216{{% tab header="Java" %}}
2192171 . Start the driver
220218{{< gh-codeblock path="examples/java/src/test/java/dev/selenium/getting_started/FirstScript.java#L17" >}}
0 commit comments