{# Settings #} {% set root = "../../" %} {% set mainNavActive_1 = "shortcodes" %} {% set sidebarNavActive_1 = "shortcode-base-tables" %} {% set title = "Tables" %} {% include "html/assets/include/nunjucks/partials/head.njk" %} {% include "html/assets/include/nunjucks/partials/core-fonts.njk" %} {% include "html/assets/include/nunjucks/partials/core-css.njk" %} {% include "html/assets/include/nunjucks/partials/core-icons.njk" %} {% include "html/assets/include/nunjucks/partials/css/css-dzsparallaxer.njk" %} {% include "html/assets/include/nunjucks/partials/css/css-showcode.njk" %} {% include "html/assets/include/nunjucks/partials/css/css-unify.njk" %} {% include "html/assets/include/nunjucks/partials/css/css-custom.njk" %}
{% include "html/assets/include/nunjucks/partials/blocks/headers/header-main.njk" %} {% include "html/assets/include/nunjucks/partials/blocks/sidebars/sidebar-shortcode-nav.njk" %} {% include "html/assets/include/nunjucks/partials/blocks/page-title/shortcode-page-title/shortcode-page-title-base.njk" %}

Bootstrap Tables

Due to the widespread use of tables across third-party widgets like calendars and date pickers, folks from Bootstap designed own tables to be opt-in. Just add the base class .table to any <table>, then extend with custom styles or our various included modifier classes. Check out the Bootstrap Table page for more information here .

Basic table

Using the most basic table markup, just add a class .table to the table tag.

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode1" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Table inverse

You can also invert the colors—with light text on dark backgrounds—with .table-dark.

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode2" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Table head option

Similar to default and inverse tables, use one of two modifier classes to make <thead>s appear light or dark gray.

"Use a class .thead-inverse for dark gray and thead-default for light gray."

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode3" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Table striped rows

Use .table-striped to add zebra-striping to any table row within the <tbody>

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode4" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Table bordered

Add .table-bordered for borders on all sides of the table and cells.

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode5" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Hoverable rows

Add .table-hover to enable a hover state on table rows within a <tbody>.

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode6" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Tables With Panel

You may cover any tables with the panel examples. You may choose any predefined Unify panels from here . All panels styles can be changed with global classes. You may also create your own style.

Basic table

Covered with primary card panel.

Basic Table

At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga.

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode7" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Basic table (spacing)

Covered with primary card panel.

Basic Table (spacing)

# First Name Username Status
1 Mark @mdo Delete
2 Jacob @fat Edit
3 Larry @twitter Share
4 htmlstream @htmlstream Submit
{% set contentTarget = "#shortcode8" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Table bordered

Covered with primary card panel.

Table Bordered

# First Name Username Status
1 Mark @mdo Delete
2 Jacob @fat Edit
3 Larry @twitter Share
4 htmlstream @htmlstream Submit
{% set contentTarget = "#shortcode9" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Striped rows

Covered with primary card panel.

Striped Rows

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode10" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}

Hover rows

Covered with primary card panel.

Hover Rows

# First Name Username Status
1 Mark @mdo Expiring
2 Jacob @fat Success
3 Larry @twitter Error!
4 htmlstream @htmlstream Pending
{% set contentTarget = "#shortcode11" %} {% set modalID = "#modalMarkup" %} {% include "html/assets/include/nunjucks/partials/blocks/show-code.njk" %}
{% include "html/assets/include/nunjucks/partials/blocks/cta/cta-main.njk" %} {% include "html/assets/include/nunjucks/partials/blocks/footers/footer-main.njk" %} {% include "html/assets/include/nunjucks/partials/blocks/footers/copyright-footer-main.njk" %} {% include "html/assets/include/nunjucks/partials/blocks/go-to-top/go-to-top-1.njk" %}
{% include "html/assets/include/nunjucks/partials/blocks/modals/modal-markup.njk" %} {% include "html/assets/include/nunjucks/partials/core-js.njk" %} {% include "html/assets/include/nunjucks/partials/js/js-dzsparallaxer.njk" %} {% include "html/assets/include/nunjucks/partials/js/js-jquery-ui-core.njk" %} {% include "html/assets/include/nunjucks/partials/js/js-show-code.njk" %}