From 35071d7212cec1fc23e8204bfd392a116a5313ed Mon Sep 17 00:00:00 2001 From: James Vasile Date: Tue, 22 Feb 2011 13:32:45 -0500 Subject: ... --- templates/Makefile | 15 +++++++ templates/__init__.py | 0 templates/__init__.pyc | Bin 0 -> 132 bytes templates/base.tmpl | 112 +++++++++++++++++++++++++++++++++++++++++++++++++ templates/err.tmpl | 23 ++++++++++ templates/two_col.tmpl | 5 +++ 6 files changed, 155 insertions(+) create mode 100644 templates/Makefile create mode 100644 templates/__init__.py create mode 100644 templates/__init__.pyc create mode 100644 templates/base.tmpl create mode 100644 templates/err.tmpl create mode 100644 templates/two_col.tmpl (limited to 'templates') diff --git a/templates/Makefile b/templates/Makefile new file mode 100644 index 0000000..d2d8ed2 --- /dev/null +++ b/templates/Makefile @@ -0,0 +1,15 @@ +CHEETAH=cheetah +TEMPLATES=$(wildcard *.tmpl) +TEMPLATE_PYFILES := $(patsubst %.tmpl,%.py,$(TEMPLATES)) + +## Catch-all tagets +default: $(TEMPLATE_PYFILES) + +%.py: %.tmpl + $(CHEETAH) c $< +templates: $(TEMPLATE_PYFILES) +template: templates + +clean: + rm -rf .\#* \#* *.pyz *.bak + @rm -f $(TEMPLATE_PYFILES) diff --git a/templates/__init__.py b/templates/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/templates/__init__.pyc b/templates/__init__.pyc new file mode 100644 index 0000000..2b2bef4 Binary files /dev/null and b/templates/__init__.pyc differ diff --git a/templates/base.tmpl b/templates/base.tmpl new file mode 100644 index 0000000..eecea31 --- /dev/null +++ b/templates/base.tmpl @@ -0,0 +1,112 @@ +#def default($text, $default) +#if $text + $text +#else + $default +#end if +#end def + + + + $default($title, "Plinth Front End to the Freedom Box") + + + + + + + $css + + + $js + $main_menu_js + $sub_menu_js + + + + +
+
+
+
+ +

+ #block title_block + $title + #end block title_block +

+ #block main_block + $main + #end block main_block + +
+
+ + #block nav_block + $nav + #end block nav_block + #block sidebar_left_block + $sidebar_left + #end block sidebar_left_block + +
+
+ +
+ +
+ #block sidebar_right_block + $sidebar_right + #end block sidebar_right_block + +
+
+
+
+ + + + diff --git a/templates/err.tmpl b/templates/err.tmpl new file mode 100644 index 0000000..1d3f6e1 --- /dev/null +++ b/templates/err.tmpl @@ -0,0 +1,23 @@ +#extends templates.two_col + +#def title_block +Error: $title +
+
+#end def + +#def sidebar_left_block +$sidebar_left +#end def + +#def main_block +$main +#end def + +#def sidebar_right_block +$sidebar_right +#end def + +#def nav_block +$nav +#end def diff --git a/templates/two_col.tmpl b/templates/two_col.tmpl new file mode 100644 index 0000000..0b559ad --- /dev/null +++ b/templates/two_col.tmpl @@ -0,0 +1,5 @@ +#extends templates.base + +#def css + +#end def -- cgit v1.2.3