mirror of
https://github.com/imfing/hextra.git
synced 2025-10-13 15:01:53 -04:00
feat(shortcode): added markdown attribute support for headers (#851)
docs: added "no-step-marker" example for steps
This commit is contained in:
@@ -4,6 +4,8 @@ title: Steps
|
||||
|
||||
A built-in component to display a series of steps.
|
||||
|
||||
You can use the Markdown attribute `{class="no-step-marker"}` to prevent a heading from being counted as a step.
|
||||
|
||||
## Example
|
||||
|
||||
{{% steps %}}
|
||||
@@ -16,6 +18,10 @@ This is the first step.
|
||||
|
||||
This is the second step.
|
||||
|
||||
#### Step subheading {class="no-step-marker"}
|
||||
|
||||
This will not be counted as a step.
|
||||
|
||||
### Step 3
|
||||
|
||||
This is the third step.
|
||||
@@ -43,5 +49,9 @@ This is the first step.
|
||||
|
||||
This is the second step.
|
||||
|
||||
#### Step subheading {class="no-step-marker"}
|
||||
|
||||
This will not be counted as a step.
|
||||
|
||||
{{%/* /steps */%}}
|
||||
```
|
||||
|
@@ -715,6 +715,7 @@
|
||||
"msupsub",
|
||||
"mtable",
|
||||
"mtight",
|
||||
"no-step-marker",
|
||||
"not-prose",
|
||||
"nulldelimiter",
|
||||
"op-symbol",
|
||||
|
@@ -1,4 +1,4 @@
|
||||
<h{{ .Level }}>
|
||||
<h{{ .Level }} {{- with .Attributes.class }} class="{{ . }}" {{- end }}>
|
||||
{{- .Text | safeHTML -}}
|
||||
{{- if gt .Level 1 -}}
|
||||
<span class="hx:absolute hx:-mt-20" id="{{ .Anchor | safeURL }}"></span>
|
||||
|
Reference in New Issue
Block a user