graff implements for air theme. used for studio homepage.

joe 3f179750b4 init repo 4 年 前
sections 3f179750b4 init repo 4 年 前
src 3f179750b4 init repo 4 年 前
themes 3f179750b4 init repo 4 年 前
.gitignore 3f179750b4 init repo 4 年 前
Makefile 3f179750b4 init repo 4 年 前
README.md 3f179750b4 init repo 4 年 前
STORY 3f179750b4 init repo 4 年 前
__init__.py 3f179750b4 init repo 4 年 前
apidoc.json 3f179750b4 init repo 4 年 前
build.py 3f179750b4 init repo 4 年 前
config.py 3f179750b4 init repo 4 年 前
requirements.txt 3f179750b4 init repo 4 年 前
site.toml 3f179750b4 init repo 4 年 前

README.md

What

graff_air is a business homepage template.

why

see STORY

Intro

The template engine is mustache

  • sections: html partials. header, nav, footer.
  • src: template engine source file.
  • themes: theme folder. one theme each sub-folder.
  • site.json: site config file. > fields in this file are used for injected to template engine variables.

added ['file']=filename

added lambdas ['lambdas']['name']=function

  • web: default build output folder
  • build.py: builder
  • config.py: some base config variables.

suported lambdas

  • equal_output

usage

hash
{
    "username": "admin"
}
{{# lambdas.equal_output }}
    {{username}}==admin ? red : black
{{/ lambdas.equal_output }}

Output:

red

Compile

pip install -r requirements.txt
python build.py

Forther more

Try to hack by changing the .mustache files, or site.toml file, even edit the theme to examine what will happen.