diff options
| author | Mark Otto <[email protected]> | 2014-05-22 23:01:42 -0700 |
|---|---|---|
| committer | Mark Otto <[email protected]> | 2014-05-22 23:01:42 -0700 |
| commit | d66b65ddde1b2f1a5cb14f601d30c552c79d7626 (patch) | |
| tree | d7f07c493e959cebd256939bf28bcbf4af468a28 /docs/assets/js/_src | |
| parent | 91d51d3fba1cc2f80138bb2858ce67c28c9c8a89 (diff) | |
| parent | 10e9fef85c6afde2b3804df928d9351b0f110a6c (diff) | |
| download | bootstrap-d66b65ddde1b2f1a5cb14f601d30c552c79d7626.tar.xz bootstrap-d66b65ddde1b2f1a5cb14f601d30c552c79d7626.zip | |
Merge branch 'master' into icon_paths
Conflicts:
dist/css/bootstrap.css.map
docs/dist/css/bootstrap.css.map
Diffstat (limited to 'docs/assets/js/_src')
| -rw-r--r-- | docs/assets/js/_src/application.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/docs/assets/js/_src/application.js b/docs/assets/js/_src/application.js index 08ca5f907..74556a3da 100644 --- a/docs/assets/js/_src/application.js +++ b/docs/assets/js/_src/application.js @@ -53,6 +53,23 @@ $('.bs-top').affix() }, 100) + // theme toggler + ;(function () { + var stylesheetLink = $('#bs-theme-stylesheet') + var themeBtn = $('.bs-docs-theme-toggle') + themeBtn.click(function () { + var href = stylesheetLink.attr('href'); + if (!href || href.indexOf('data') === 0) { + stylesheetLink.attr('href', stylesheetLink.attr('data-href')) + themeBtn.text('Disable theme preview') + } + else { + stylesheetLink.attr('href', '') + themeBtn.text('Preview theme') + } + }) + })(); + // tooltip demo $('.tooltip-demo').tooltip({ selector: '[data-toggle="tooltip"]', |
