From 1560b6279fc7c2aa3451dbc099ec7a3ca524ff3e Mon Sep 17 00:00:00 2001 From: Armin Ronacher Date: Thu, 22 Mar 2007 14:36:38 +0100 Subject: [PATCH] [svn] again some changes on the webpage --HG-- branch : trunk --- jinja/parser.py | 5 +++-- www/documentation.tmpl | 12 ------------ www/faq.tmpl | 23 +++++++++++++++++++++-- www/generate.py | 1 + www/layout/base.html | 29 ----------------------------- www/layout/base.tmpl | 24 ++++++------------------ www/static/style.css | 5 +++-- 7 files changed, 34 insertions(+), 65 deletions(-) delete mode 100644 www/documentation.tmpl delete mode 100644 www/layout/base.html diff --git a/jinja/parser.py b/jinja/parser.py index 5ef47c4..5994fb8 100644 --- a/jinja/parser.py +++ b/jinja/parser.py @@ -583,8 +583,9 @@ class Parser(object): if data in self.directives: node = self.directives[data](lineno, gen) else: - raise TemplateSyntaxError('unknown directive %r' % data, - lineno, self.filename) + raise TemplateSyntaxError('unknown directive %r' % + str(data), lineno, + self.filename) # some tags like the extends tag do not output nodes. # so just skip that. if node is not None: diff --git a/www/documentation.tmpl b/www/documentation.tmpl deleted file mode 100644 index 49ae145..0000000 --- a/www/documentation.tmpl +++ /dev/null @@ -1,12 +0,0 @@ -<% extends 'layout/base.tmpl' %> -<% set title = 'Documentation' %> -<% set active_page = 'documentation' %> -<% block content %> -

Documentation

-

- Currently Jinja 1 in still under heavy development and we have neither - released a final version nor do we provide a documentation you can download. - However you can browse the documentation of the current SVN version online: -

-

browse online documentation

-<% endblock %> diff --git a/www/faq.tmpl b/www/faq.tmpl index ac4ebea..69bb4c7 100644 --- a/www/faq.tmpl +++ b/www/faq.tmpl @@ -52,7 +52,7 @@ @@ -66,7 +66,7 @@
  • uncoupled internationalization support
  • expression support in any tag
  • abbility of modifying the context from the template - by using the {% set %}
  • tag. + by using the {% set %} tag.
  • support for function calling with arguments
  • filters can be called with a variable argument count
  • full unicode support
  • @@ -81,5 +81,24 @@
  • test functions like is even etc.
  • block delimiters are exchangeable.
  • no implicit function calling
  • +
  • {% endblock %} doesn't support the optional name argument
  • +
  • {% ifchanged %} is not implemented because of performance + reasons. If there's enough interest an implementation might be added
  • +
  • {% templatetag %} is not implemented because Jinja supports + escaping via {% raw %} or the variable syntax
  • +
  • {% comment %} is not implemented, rather use + {# ... #} for commenting out stuff.
  • +
  • {% now %} is not implemented because Jinja doesn't handle + l10n. Datetime specific stuff should be provided by the application.
  • +
  • {% load %}, loading components for Jinja works from the + application side. Template designers don't have to import stuff on + their own.
  • +
  • {% debug %} is not implemented. You can use the global + function debug().
  • +
  • custom tags are not supported. Most of the stuff that is + possible with django template tags is possible with either functions, + filters, tests or a combination of them.
  • +
  • using keywords like endfor as identifer raises an + exception.
  • <% endblock %> diff --git a/www/generate.py b/www/generate.py index 6edd973..55d659b 100755 --- a/www/generate.py +++ b/www/generate.py @@ -13,6 +13,7 @@ from pygments import highlight from pygments.lexers import get_lexer_by_name from pygments.formatters import HtmlFormatter + _data_re = re.compile( r'(?P.*?).*?' r'(?P.*?).*?' diff --git a/www/layout/base.html b/www/layout/base.html deleted file mode 100644 index bcfd39d..0000000 --- a/www/layout/base.html +++ /dev/null @@ -1,29 +0,0 @@ - - - - Untitled | Jinja Template Engine - - - - - - - - -
    -
    -
    -
    - - - \ No newline at end of file diff --git a/www/layout/base.tmpl b/www/layout/base.tmpl index b6317ff..e881373 100644 --- a/www/layout/base.tmpl +++ b/www/layout/base.tmpl @@ -1,8 +1,8 @@ <% set navigation = [ - ('index', 'Index'), - ('faq', 'FAQ'), - ('documentation', 'Documentation'), - ('download', 'Download') + ('index.html', 'index', 'Index'), + ('faq.html', 'faq', 'FAQ'), + ('documentation/index.html', 'documentation', 'Documentation'), + ('download.html', 'download', 'Download') ] %> @@ -19,23 +19,11 @@

    Jinja

    - <% if trace %> -
    - <% for href, caption in trace %> - <% if loop.last %> - <%= caption %> - <% else %> - <%= caption %> » - <% endif %> - <% endfor %> -
    - <% endif %>
    <% block content %><% endblock %> diff --git a/www/static/style.css b/www/static/style.css index ff33585..644e671 100644 --- a/www/static/style.css +++ b/www/static/style.css @@ -40,7 +40,8 @@ a:hover { } pre { - background-color: #f9f9f9; + background-color: #f8f8f8; + color: #000; border-top: 1px solid #ccc; border-bottom: 1px solid #ccc; padding: 5px; @@ -144,7 +145,7 @@ div.admonition p { } #header h1 { - display: none + display: none; } #navigation { -- 2.26.2