From 8e2fdfdb1b54f1fdbfa125bdb0e654f783b8fe4d Mon Sep 17 00:00:00 2001 From: Thomas Welton Date: Thu, 22 Aug 2013 02:54:54 +0100 Subject: [PATCH 1/2] (less) Added glyphicon-block class Prevents elements moving around the page after the font file has loaded by setting a defined width on elements using the icon font. --- glyphicons.less | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/glyphicons.less b/glyphicons.less index 0e0ba986c366..82915ce691c2 100644 --- a/glyphicons.less +++ b/glyphicons.less @@ -29,6 +29,10 @@ -webkit-font-smoothing: antialiased; } +.glyphicon-block{ + width: 1em; +} + // Individual icons .glyphicon-asterisk { &:before { content: "\2a"; } } .glyphicon-plus { &:before { content: "\2b"; } } From f7182ee3ae31ad937b9045acf340362e03d3038a Mon Sep 17 00:00:00 2001 From: Thomas Welton Date: Thu, 22 Aug 2013 10:28:54 +0100 Subject: [PATCH 2/2] (less) Removed glyphicon-block instead target :empty .glyphicons --- glyphicons.less | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/glyphicons.less b/glyphicons.less index 82915ce691c2..7b66e6ba15fa 100644 --- a/glyphicons.less +++ b/glyphicons.less @@ -27,10 +27,10 @@ font-weight: normal; line-height: 1; -webkit-font-smoothing: antialiased; -} -.glyphicon-block{ - width: 1em; + &:empty{ + width: 1em; + } } // Individual icons