css: disable ligatures in monospace fonts
The choice of the font in app/assets/stylesheets/variables.scss for the rule: $fixed-width-font-family: Courier, monospace; can make it harder to read some of the text in the documentation, at least in some browsers in some OSes. This is especially applicable to the names of the configuration keys and to mentions of the shell commands, which people would usually edit in a text editor or in a shell with a monospace font. Fonts used by <code> tags are also affected. For example, the following ligatures "meld" the letters together: - in config key `gc.reflogExpireUnreachable` the ligature is `fl` - in config key `color.diff.new` -- `ff` - in command name `git config` -- `fi` Add `font-variant-ligatures: none;` [1] to all usages of variable `$fixed-width-font-family` to fix this readability issue. [1] see documentation of this CSS property on MDN: https://developer.mozilla.org/en-US/docs/Web/CSS/font-variant-ligatures Fixes: https://github.com/git/git-scm.com/issues/1817
This commit is contained in:
Родитель
5b9ef80c2b
Коммит
dc846ae388
|
@ -39,6 +39,7 @@ pre {
|
|||
color: $orange;
|
||||
display: block;
|
||||
font-family: $fixed-width-font-family;
|
||||
font-variant-ligatures: none;
|
||||
line-height: 18px;
|
||||
margin-bottom: 1em;
|
||||
overflow: auto;
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
p {
|
||||
em {
|
||||
font-family: $fixed-width-font-family !important;
|
||||
font-variant-ligatures: none;
|
||||
font-style: normal;
|
||||
font-weight: bold;
|
||||
color: $fixed-width-font-color;
|
||||
|
@ -28,6 +29,7 @@
|
|||
display: block;
|
||||
padding: 2px;
|
||||
font-family: $fixed-width-font-family !important;
|
||||
font-variant-ligatures: none;
|
||||
background-color: #eee0b5;
|
||||
}
|
||||
margin-bottom: 15px;
|
||||
|
@ -35,6 +37,7 @@
|
|||
|
||||
dt.hdlist1 {
|
||||
font-family: $fixed-width-font-family !important;
|
||||
font-variant-ligatures: none;
|
||||
}
|
||||
|
||||
// Man pages
|
||||
|
@ -44,6 +47,7 @@
|
|||
margin-bottom: 1em;
|
||||
font-family: $fixed-width-font-family !important;
|
||||
line-height: $fixed-width-line-height;
|
||||
font-variant-ligatures: none;
|
||||
color: $fixed-width-font-color;
|
||||
word-wrap: break-word; /* Internet Explorer 5.5+ */
|
||||
white-space: pre;
|
||||
|
|
|
@ -258,6 +258,7 @@ code {
|
|||
overflow: auto;
|
||||
font-family: $fixed-width-font-family;
|
||||
line-height: $fixed-width-line-height;
|
||||
font-variant-ligatures: none;
|
||||
color: $orange;
|
||||
background-color: #fff;
|
||||
border: solid 1px #efeee6;
|
||||
|
@ -364,6 +365,7 @@ div.more {
|
|||
|
||||
.fixed {
|
||||
font-family: $fixed-width-font-family;
|
||||
font-variant-ligatures: none;
|
||||
}
|
||||
|
||||
.text-center {
|
||||
|
|
Загрузка…
Ссылка в новой задаче