Skip to main content

A bootstrap 3 row and columns extension for Markdown

Project description

mdx_attr_cols
=============

|attr-cols-ci-badge|

.. |attr-cols-ci-badge| image:: https://travis-ci.org/CTPUG/mdx_attr_cols.png?branch=master
:alt: Travis CI build status
:scale: 100%
:target: https://travis-ci.org/CTPUG/mdx_attr_cols

A Markdown extension to add support for Bootstrap 3 rows and columns.

Licensed under the `ISC License`_.

.. _ISC License: https://github.com/CTPUG/mdx_attr_cols/blob/master/LICENSE


Requirements
============

The mdx_attr_cols plugin requires the following additional Markdown
plugins:

* `attr_list`_ (built-in to the markdown library)
* `mdx_outline`_

.. _attr_list: http://pythonhosted.org/Markdown/extensions/attr_list.html
.. _mdx_outline: https://pypi-hypernode.com/pypi/mdx_outline


Installation
============

Install with ``pip install mdx_attr_cols``.


Documentation
=============

Allows creating bootstrap container rows and columns using section
attributes as provided by the attr_list and mdx_outline extensions.

Markdown example:

.. code:: markdown

Header 1 {: cols=6 }
====================

Some paragraphs go here.

Header 2 {: cols=2 }
====================

More paragraphs go here.

Header 3 {: cols=4 }
====================

Final column.

Header 4
========

This is not in a row or column.

Python usage:

.. code:: python

md = markdown.Markdown(
extensions=[
'mdx_outline',
'attr_list',
'attr_cols',
],
extension_configs={
'attr_cols': {
'columns': 12,
'attr': 'cols',
'tags': ['section'],
}
})

Configuration options:

* ``columns``: Number of columns in a row. Default is ``12``.
* ``tags``: List of HTML tags to look for attributes on. Default is
``['sections']``.
* ``attr``: Name of column width attribute. Default is ``'cols'``.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mdx-attr-cols-0.2.tar.gz (5.0 kB view details)

Uploaded Source

File details

Details for the file mdx-attr-cols-0.2.tar.gz.

File metadata

  • Download URL: mdx-attr-cols-0.2.tar.gz
  • Upload date:
  • Size: 5.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/2.7.15rc1

File hashes

Hashes for mdx-attr-cols-0.2.tar.gz
Algorithm Hash digest
SHA256 88b1f121c2948db8033c968132958b181e6ea221df48a404e5ec05f649252cee
MD5 ff520ca7adc71147ba5c195a2d271d52
BLAKE2b-256 5d1331394e22a676cee1b39a2e4c662d12c3f454318150e81a57b4666de5d8ad

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page