diff options
Diffstat (limited to 'examples')
3 files changed, 32 insertions, 2 deletions
| diff --git a/examples/djangoproject/djangoproject/static/css/forms.css b/examples/djangoproject/djangoproject/static/css/forms.css new file mode 100644 index 0000000..3830ebd --- /dev/null +++ b/examples/djangoproject/djangoproject/static/css/forms.css @@ -0,0 +1,12 @@ +/* +Form input. + +.error - When form error. + +Example: +    <input type="text" class="text$modifier_class" /> + +Styleguide 2.1 +*/ +input.error { +    border: 1px solid red; } diff --git a/examples/djangoproject/djangoproject/templates/base.html b/examples/djangoproject/djangoproject/templates/base.html index f52ed82..ef4a5c4 100644 --- a/examples/djangoproject/djangoproject/templates/base.html +++ b/examples/djangoproject/djangoproject/templates/base.html @@ -6,6 +6,7 @@          <title>Styleguide Example</title>          <link rel="stylesheet" href="{% static "css/layout.css" %}" type="text/css" />          <link rel="stylesheet" href="{% static "css/buttons.css" %}" type="text/css" /> +        <link rel="stylesheet" href="{% static "css/forms.css" %}" type="text/css" />      </head>      <body>          <header>Styleguide Example</header> diff --git a/examples/djangoproject/djangoproject/templates/styleguide.html b/examples/djangoproject/djangoproject/templates/styleguide.html index 1817a27..05eafb7 100644 --- a/examples/djangoproject/djangoproject/templates/styleguide.html +++ b/examples/djangoproject/djangoproject/templates/styleguide.html @@ -14,7 +14,7 @@  {% endcomment %}  {% styleguideblock styleguide "1.1" %} -    <button class="{{ modifier_class }}">Example Button</button> +    <button class="$modifier_class">Example Button</button>  {% endstyleguideblock %}  {% verbatim %} @@ -22,9 +22,26 @@  <pre>      <code>  {% styleguideblock styleguide "1.1" %} -    <button class="{{ modifier_class }}">Example Button</button> +    <button class="$modifier_class">Example Button</button>  {% endstyleguideblock %}      </code>  </pre>  {% endverbatim %} + +{% comment %} + +{% renderstyleguide styleguide "2" %} +{% renderstyleguide styleguide "2" using "custom.html" %} + +{% endcomment %} +{% renderstyleguide styleguide "2" %} + +{% verbatim %} +<p>This block above was created with a simple template call:</p> +<pre> +    <code> +{% renderstyleguide styleguide "2" %} +    </code> +</pre> +{% endverbatim %}  {% endblock %} | 
