{% assign demo-code = code %} {% assign demo-code = demo-code | replace_regex: '\{% (end)?hide %\}', '' %} {% assign demo-code = demo-code | replace_regex: 'href="#"', 'href="javascript:void(0)"' %}
{% if include.max-width %}
{% endif %} {% if include.columns %}
{% endif %} {% if include.modal %}
{% endif %} {% if include.wrapper %}
{% endif %} {{ demo-code }} {% if include.wrapper %}
{% endif %} {% if include.columns %}
{% endif %} {% if include.max-width %}
{% endif %}
{% capture html %} {{ code }} {% removeemptylines %} {{ site.captured_global.scripts | last }} {% endremoveemptylines %} {% endcapture %} {% assign html = html | strip %} {% assign html = html | replace_regex: '// @formatter:(off|on)', '' %} {% capture new_line %} {% endcapture %} {% assign html = html | replace_regex: "\n\n+", new_line %} {% assign html = html | replace_regex: 'url\(([^\)]+)\)', 'url(...)' %} {% assign html = html | replace_regex: 'src="([^"]+)"', 'src="..."' %} {% assign html = html | replace_regex: 'href="([^#][^"]+)"', 'href="#"' %} {% assign html = html | replace_regex: '\{% hide %\}.*?\{% endhide %\}', '' %} {% assign html = html | replace_regex: 'class=" ', 'class="' %} {% assign html = html | htmlbeautifier %}
{% highlight html %}{{ html }}{% endhighlight %}