From f0f33eb9a3a25ae2f0032f630ff84c58cb0ca431 Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Wed, 27 Mar 2013 15:42:11 -0700 Subject: [PATCH] Refactor .list-inline and .list-unstyled * Instead of shared and separate CSS, isolate by class for easier mixin-ability * .list-unstyled is now used as a mixin in .list-inline --- docs/assets/css/bootstrap.css | 6 +++++- less/type.less | 18 ++++++++++-------- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/docs/assets/css/bootstrap.css b/docs/assets/css/bootstrap.css index 5632d3aadd..50d2070015 100644 --- a/docs/assets/css/bootstrap.css +++ b/docs/assets/css/bootstrap.css @@ -546,7 +546,11 @@ li { line-height: 20px; } -.list-unstyled, +.list-unstyled { + margin-left: 0; + list-style: none; +} + .list-inline { margin-left: 0; list-style: none; diff --git a/less/type.less b/less/type.less index 193078c72c..60ad793e90 100644 --- a/less/type.less +++ b/less/type.less @@ -126,18 +126,20 @@ li { } // List options + // Unstyled keeps list items block level, just removes list-style -.list-unstyled, -// Inline turns list items into inline-block -.list-inline { +.list-unstyled { margin-left: 0; list-style: none; } -// Single-line list items -.list-inline > li { - display: inline-block; - padding-left: 5px; - padding-right: 5px; +// Inline turns list items into inline-block +.list-inline { + .list-unstyled(); + > li { + display: inline-block; + padding-left: 5px; + padding-right: 5px; + } } // Description Lists -- 2.47.2