]> git.ipfire.org Git - thirdparty/bootstrap.git/commitdiff
adds a note on typography docs about rem units on font-size-base (#23988)
authorAndres Galante <agalante@gmail.com>
Tue, 3 Oct 2017 01:59:07 +0000 (18:59 -0700)
committerMark Otto <markd.otto@gmail.com>
Tue, 3 Oct 2017 01:59:07 +0000 (18:59 -0700)
docs/4.0/content/typography.md

index 74ecbe61476c905394d949c5b52753fde1ff714f..d76070889aa771377bacb68bd6c316628e5aa425 100644 (file)
@@ -16,7 +16,7 @@ Bootstrap sets basic global display, typography, and link styles. When more cont
 - Set the global link color via `$link-color` and apply link underlines only on `:hover`.
 - Use `$body-bg` to set a `background-color` on the `<body>` (`#fff` by default).
 
-These styles can be found within `_reboot.scss`, and the global variables are defined in `_variables.scss`.
+These styles can be found within `_reboot.scss`, and the global variables are defined in `_variables.scss`. Make sure to set `$font-size-base` in `rem`.
 
 ## Headings
 
@@ -297,24 +297,24 @@ Here's an example of it in practice. Choose whatever `font-size`s and media quer
 
 {% highlight scss %}
 html {
-  font-size: 14px;
+  font-size: 1rem;
 }
 
 @include media-breakpoint-up(sm) {
   html {
-    font-size: 16px;
+    font-size: 1.2rem;
   }
 }
 
 @include media-breakpoint-up(md) {
   html {
-    font-size: 20px;
+    font-size: 1.4rem;
   }
 }
 
 @include media-breakpoint-up(lg) {
   html {
-    font-size: 28px;
+    font-size: 1.6rem;
   }
 }
 {% endhighlight %}