From 12916b06aaf686c56a53feb16b8efbac6f38c8fd Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Tue, 4 Dec 2012 18:25:16 -0800 Subject: [PATCH] Fix up display of dropdown submenu examples on responsive views --- docs/assets/css/docs.css | 36 +++++++++++++++++++++++- docs/components.html | 12 ++++---- docs/templates/pages/components.mustache | 12 ++++---- 3 files changed, 47 insertions(+), 13 deletions(-) diff --git a/docs/assets/css/docs.css b/docs/assets/css/docs.css index 6e9bbb9be7..c7bddd45af 100644 --- a/docs/assets/css/docs.css +++ b/docs/assets/css/docs.css @@ -687,6 +687,21 @@ form.bs-docs-example { margin: 20px; } +/* Dropdowns */ +.bs-docs-example-submenus { + min-height: 180px; +} +.bs-docs-example-submenus > .pull-left + .pull-left { + margin-left: 20px; +} +.bs-docs-example-submenus .dropup > .dropdown-menu, +.bs-docs-example-submenus .dropdown > .dropdown-menu { + display: block; + position: static; + margin-bottom: 5px; + *width: 180px; +} + /* Responsive docs @@ -1013,7 +1028,26 @@ form.bs-docs-example { word-break: break-all; } - /* Modal example */ + /* Examples: dropdowns */ + .bs-docs-example-submenus > .pull-left { + float: none; + clear: both; + } + .bs-docs-example-submenus > .pull-left, + .bs-docs-example-submenus > .pull-left + .pull-left { + margin-left: 0; + } + .bs-docs-example-submenus p { + margin-bottom: 0; + } + .bs-docs-example-submenus .dropup > .dropdown-menu, + .bs-docs-example-submenus .dropdown > .dropdown-menu { + margin-bottom: 10px; + float: none; + max-width: 180px; + } + + /* Examples: modal */ .modal-example .modal { position: relative; top: auto; diff --git a/docs/components.html b/docs/components.html index b5e22e3da5..518924026b 100644 --- a/docs/components.html +++ b/docs/components.html @@ -165,12 +165,12 @@

Sub menus on dropdowns

Add an extra level of dropdown menus, appearing on hover like those of OS X, with some simple markup additions. Add .dropdown-submenu to any li in an existing dropdown menu for automatic styling.

-
+

Default

-
+

Dropup

-
-
+

Left submenu