Software zum Installieren eines Smart-Mirror Frameworks , zum Nutzen von hochschulrelevanten Informationen, auf einem Raspberry-Pi.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

README.md 4.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. # font-family-name-quotes
  2. Specify whether or not quotation marks should be used around font family names.
  3. <!-- prettier-ignore -->
  4. ```css
  5. a { font-family: "Times New Roman", 'Ancient Runes', serif; }
  6. /** ↑ ↑ ↑ ↑
  7. * These quotation marks and this one */
  8. ```
  9. This rule checks the `font` and `font-family` properties.
  10. This rule ignores `$sass`, `@less`, and `var(--custom-property)` variable syntaxes.
  11. ## Options
  12. `string`: `"always-where-required"|"always-where-recommended"|"always-unless-keyword"`
  13. _Please read the following to understand these options_:
  14. - The `font` and `font-family` properties accept a short list of special **keywords**: `inherit`, `serif`, `sans-serif`, `cursive`, `fantasy`, `system-ui`, and `monospace`. If you wrap these words in quotes, the browser will not interpret them as keywords, but will instead look for a font by that name (e.g. will look for a `"sans-serif"` font) -- which is almost _never_ what you want. Instead, you use these keywords to point to the built-in, generic fallbacks (right?). Therefore, _all of the options below enforce no quotes around these keywords_. (If you actually want to use a font named `"sans-serif"`, turn this rule off.)
  15. - Quotes are **recommended** [in the spec](https://www.w3.org/TR/CSS2/fonts.html#font-family-prop) with "font family names that contain white space, digits, or punctuation characters other than hyphens".
  16. - Quotes are **required** around font-family names when they are not [valid CSS identifiers](https://www.w3.org/TR/CSS2/syndata.html#value-def-identifier). For example, a font family name requires quotes around it if it contains `$`, `!` or `/`, but does not require quotes just because it contains spaces or a (non-initial) number or underscore. _You can probably bet that almost every font family name you use **will** be a valid CSS identifier_.
  17. - Quotes should **never** be used around vendor prefixed system fonts such as `-apple-system` and `BlinkMacSystemFont`.
  18. For more on these subtleties, read ["Unquoted font family names in CSS"](https://mathiasbynens.be/notes/unquoted-font-family), by Mathias Bynens.
  19. **Caveat:** This rule does not currently understand escape sequences such as those described by Mathias. If you want to use the font family name "Hawaii 5-0" you will need to wrap it in quotes, instead of escaping it as `Hawaii \35 -0` or `Hawaii\ 5-0`.
  20. ### `"always-unless-keyword"`
  21. Expect quotes around every font family name that is not a keyword.
  22. The following patterns are considered violations:
  23. <!-- prettier-ignore -->
  24. ```css
  25. a { font-family: Arial, sans-serif; }
  26. ```
  27. <!-- prettier-ignore -->
  28. ```css
  29. a { font-family: Times New Roman, Times, serif; }
  30. ```
  31. <!-- prettier-ignore -->
  32. ```css
  33. a { font: 1em Arial, sans-serif; }
  34. ```
  35. The following patterns are _not_ considered violations:
  36. <!-- prettier-ignore -->
  37. ```css
  38. a { font-family: 'Arial', sans-serif; }
  39. ```
  40. <!-- prettier-ignore -->
  41. ```css
  42. a { font-family: "Times New Roman", "Times", serif; }
  43. ```
  44. <!-- prettier-ignore -->
  45. ```css
  46. a { font: 1em 'Arial', sans-serif; }
  47. ```
  48. ### `"always-where-required"`
  49. Expect quotes only when quotes are _required_ according to the criteria above, and disallow quotes in all other cases.
  50. The following patterns are considered violations:
  51. <!-- prettier-ignore -->
  52. ```css
  53. a { font-family: "Arial", sans-serif; }
  54. ```
  55. <!-- prettier-ignore -->
  56. ```css
  57. a { font-family: 'Times New Roman', Times, serif; }
  58. ```
  59. <!-- prettier-ignore -->
  60. ```css
  61. a { font: 1em "Arial", sans-serif; }
  62. ```
  63. The following patterns are _not_ considered violations:
  64. <!-- prettier-ignore -->
  65. ```css
  66. a { font-family: Arial, sans-serif; }
  67. ```
  68. <!-- prettier-ignore -->
  69. ```css
  70. a { font-family: Arial, sans-serif; }
  71. ```
  72. <!-- prettier-ignore -->
  73. ```css
  74. a { font-family: Times New Roman, Times, serif; }
  75. ```
  76. <!-- prettier-ignore -->
  77. ```css
  78. a { font-family: "Hawaii 5-0"; }
  79. ```
  80. <!-- prettier-ignore -->
  81. ```css
  82. a { font: 1em Arial, sans-serif; }
  83. ```
  84. ### `"always-where-recommended"`
  85. Expect quotes only when quotes are _recommended_ according to the criteria above, and disallow quotes in all other cases. (This includes all cases where quotes are _required_, as well.)
  86. The following patterns are considered violations:
  87. <!-- prettier-ignore -->
  88. ```css
  89. a { font-family: Times New Roman, Times, serif; }
  90. ```
  91. <!-- prettier-ignore -->
  92. ```css
  93. a { font-family: MyFontVersion6, sake_case_font; }
  94. ```
  95. <!-- prettier-ignore -->
  96. ```css
  97. a { font-family: 'Arial', sans-serif; }
  98. ```
  99. <!-- prettier-ignore -->
  100. ```css
  101. a { font: 1em Times New Roman, Times, serif; }
  102. ```
  103. The following patterns are _not_ considered violations:
  104. <!-- prettier-ignore -->
  105. ```css
  106. a { font-family: 'Times New Roman', Times, serif; }
  107. ```
  108. <!-- prettier-ignore -->
  109. ```css
  110. a { font-family: "MyFontVersion6", "sake_case_font"; }
  111. ```
  112. <!-- prettier-ignore -->
  113. ```css
  114. a { font-family: Arial, sans-serif; }
  115. ```
  116. <!-- prettier-ignore -->
  117. ```css
  118. a { font: 1em 'Times New Roman', Times, serif; }
  119. ```