📓 themes/mdl/README.md by @flancia.org ☆

Nikola MDL Mako Template

This theme is based from Material Design Lite templates. It gets the idea from the blog example. This theme is for Nikola static site generator and used Mako templates. The RSS feed icon is getting from Community Icons

Installation

To install:

Enter the command line below at the console

$ nikola theme -i mdl

Edit conf.py for setting these values below:

Refer to Customizing Your Site for more information. If post_type is used, it accepts a dictionary value, where key is the post meta type and value is the icon name from Google Material Design Icons. There is an example in Customization section.

Style development

You can skip this section if the theme is going to be used as it is. As the final styles.css is generated and placed in assets/css folder.

The css file is generated using SASS compiler. If you have it installed, you can generate the final styles.css file by calling make as there is a Makefile that contains the generation commands.

If you want to add custom styles in custom.scss or custom.css, set mdl__custom_css to True. Both files are git-ignored.

JavaScript development

If you want to add custom JavaScript in custom.js, set mdl__custom_js to True. The custom.js file is git-ignored.

Components

Here are the components that used in this theme

Customization

It supports some variables in the config file (conf.py). Below are the default values except post_type, where is {}:

    GLOBAL_CONTEXT = {
        "mdl__version": "1.3.0",
        "mdl__color_scheme": "indigo-pink",
        "mdl__roboto_font": False,
        "mdl__late_load_css": False,
        "mdl__cachebusting": "1",
        "mdl__fixed_header": False,
        "mdl__fixed_drawer": False,
        "mdl__no_drawer_button": False,
        "mdl__no_desktop_drawer_button": False,
        "mdl__multiple_header": False,
        "mdl__header_scroll": False,
        "mdl__header_waterfall": False,
        "mdl__header_waterfall_hide_top": False,
        "mdl__header_transparent": False,
        "mdl__header_seamed": False,
        "mdl__footer": "",
        "mdl__navigation_large_screen_only": False,
        "mdl__drawer_small_screen_only": False,
        "mdl__custom_css": False,
        "mdl__custom_js": False,
        "drawer_title": "",
        "drawer_logo_url": "",
        "drawer_show_title": "",
        "drawer_description": "",
        "drawer_note": "",
        "title_row_middle": False,
        "navigation_row_middle": False,
        "breadcrumb_separator": ">",
        "post_type": {
            "text": "format_align_justify",
        },
        "top_nav_header": False,
        "more_button_header": [
            ("/mobile/", "Mobile Site", "Mobile"),
        ],
        "image_plugin": "colorbox",
    }

Layout

Additional optional MDL classes for outer div element:

Header

Additional optional MDL classes for header element:

footer

Navigation

Drawer

Others

Depreciated GLOBAL_CONTEXT

Depreciated classes

New classes

Known Issues

Dependencies

License

Material Design Lite Apache License Version 2.0

Google Material Design Icons - Attribution 4.0 International

RSS Feed Icons - SIL Open Font License 1.1

jQuery - MIT License

Colorbox - MIT License

Lightbox - MIT License

Templates - Apache License Version 2.0