elements.css

Same filename in this branch
  1. main core/themes/claro/css/base/elements.css
  2. main core/themes/admin/css/base/elements.css
Same filename and directory in other branches
  1. 10 core/themes/claro/css/base/elements.css
  2. 11.x core/themes/claro/css/base/elements.css
  3. 9 core/themes/seven/css/base/elements.css
  4. 9 core/themes/claro/css/base/elements.css
  5. 9 core/themes/bartik/css/base/elements.css
  6. 8.9.x core/themes/seven/css/base/elements.css
  7. 8.9.x core/themes/claro/css/base/elements.css
  8. 8.9.x core/themes/bartik/css/base/elements.css
  9. 11.x core/themes/admin/css/base/elements.css
  10. 11.x core/themes/default_admin/css/base/elements.css
/*
 * DO NOT EDIT THIS FILE.
 * See the following change record for more information,
 * https://www.drupal.org/node/3084859
 * @preserve
 */

/**
 * Generic elements.
 */

::selection {
  background: var(--gin-color-primary-light-hover);
}

html {
  font-family: var(--gin-font);
  font-size: 100%;
  font-weight: normal;
  font-style: normal;
  line-height: var(--line-height);
  scroll-padding-block-start: var(--gin-scroll-offset) !important;
}

body {
  overflow-x: hidden;
  word-wrap: break-word;
  hyphens: auto;
  color: var(--gin-color-text);
  background: var(--app-bg-color);

  @media (--admin-large) {
    overflow-x: auto;
  }
}

a,
.link,
button.link {
  word-wrap: break-word;
  color: var(--gin-color-primary);
  overflow-wrap: break-word;
  text-decoration-style: var(--gin-link-decoration-style);
}

*|*:any-link:not(svg|a) {
  -webkit-text-decoration: underline;
  text-decoration: underline;
  text-decoration-style: var(--gin-link-decoration-style);
}

a:hover,
a:focus,
.link:hover,
.link:focus {
  -webkit-text-decoration: none;
  text-decoration: none;
}

a:hover,
.link:hover {
  color: var(--color-link-hover);
}

a:active,
.link:active {
  color: var(--color-link-active);
}

hr {
  height: 1px;
  margin: var(--gin-spacing-xl) 0;
  padding: 0;
  border: none;
  background: var(--color-divider);
}

summary {
  font-weight: bold;
}

/**
 * Reusable heading classes are included to help modules change the styling of
 * headings on a page without affecting accessibility.
 */

h1,
.heading-a {
  margin: var(--space-m) 0 var(--space-s);
  letter-spacing: -0.025em;
  font-size: var(--font-size-h1);
  font-weight: var(--gin-font-weight-normal);
  line-height: var(--line-height-heading);
}

h2,
.heading-b {
  margin: var(--space-m) 0 var(--space-s);
  letter-spacing: -0.025em;
  font-size: var(--gin-font-size-h2);
  font-weight: var(--gin-font-weight-normal);
  line-height: var(--line-height-heading);
}

h3,
.heading-c {
  margin: var(--space-m) 0 var(--space-s);
  letter-spacing: -0.025em;
  font-size: var(--gin-font-size-h3);
  font-weight: var(--gin-font-weight-normal);
  line-height: var(--line-height-heading);
}

h4,
.heading-d {
  margin: var(--space-m) 0 var(--space-s);
  font-size: var(--font-size-h4);
  font-weight: bold;
  line-height: var(--line-height-heading);
}

h5,
.heading-e {
  margin: var(--space-m) 0 var(--space-s);
  font-size: var(--font-size-h5);
  font-weight: bold;
  line-height: var(--line-height-heading);
}

h6,
.heading-f {
  margin: var(--space-m) 0 var(--space-s);
  font-size: var(--font-size-h6);
  font-weight: bold;
  line-height: var(--line-height-heading);
}

p {
  margin: 1em 0;
}

dl {
  margin: 0 0 1.25rem;
}

dl dd,
dl dl {
  margin-block-end: 0.625rem;
  margin-inline-start: 1.25rem;
}

blockquote {
  position: relative;
  margin: var(--gin-spacing-m);
  padding-inline-start: var(--gin-spacing-l);
  font-size: var(--gin-font-size-quote);

  &::before {
    position: absolute;
    display: block;
    width: 0.25rem;
    height: 100%;
    content: "";
    color: var(--color-absolutezero);
    border-radius: 2px;
    background-color: var(--gin-color-primary);
    font-family: var(--font-family-serif);
    font-size: var(--space-xxl);
    line-height: 1em;
    inset-block-start: 0;
    inset-inline-start: 0;
  }

  &::after {
    content: no-close-quote;
  }
}

address {
  font-style: italic;
}

u,
ins {
  -webkit-text-decoration: underline;
  text-decoration: underline;
}

s,
strike,
del {
  -webkit-text-decoration: line-through;
  text-decoration: line-through;
}

big {
  font-size: larger;
}

small {
  font-size: smaller;
}

sub {
  vertical-align: sub;
  font-size: smaller;
  line-height: normal;
}

sup {
  vertical-align: super;
  font-size: smaller;
  line-height: normal;
}

abbr,
acronym {
  border-bottom: dotted 1px;
}

ul {
  margin-block: 0.25em;
  margin-inline: 1.5em 0;
  padding-inline-start: 0;
  list-style-image: none;
}

ol {
  margin-block: 0.25em;
  margin-inline: 2em 0;
  padding: 0;
}

code {
  margin: 0.5em 0;
}

pre {
  margin: 0.5em 0;
  white-space: pre-wrap;
}

details {
  line-height: var(--details-line-height);

  & summary {
    padding: var(--gin-spacing-m);
  }
}

img {
  max-width: 100%;
  height: auto;
}

/**
 * Default focus styles for focused elements.
 *
 * This is applied globally to all interactive elements except Toolbar and
 * Settings Tray since they have their own styles.
 */

.page-wrapper *:focus,
.ui-dialog *:focus {
  outline: var(--focus-outline);
}

/**
 * These elements should not be displayed until they are processed by
 * JavaScript, and views-ui-noscript.css exists so browsers without JavaScript
 * will still display them.
 */

.views-tabs,
.views-display-top > input.button {
  display: none;
}

/* Set a dark color scheme to style native browser elements. */

.gin--dark-mode {
  color-scheme: dark;
}

/* Enforcing colors on visually hidden text does not change anything for the
   user, but it prevents accessibility scanners like Wave from reporting contrast
   errors on visually hidden elements. While this is certainly an issue with the
   scanners and not Gin, this ensures that scans provide an accurate account of
   Gin's contrast support. */

.visually-hidden {
  color: #000;

  .gin--dark-mode & {
    color: #fff;
  }

  &.skip-link {
    color: var(--gin-color-button-text);
  }
}

File

core/themes/default_admin/css/base/elements.css

View source
  1. /*
  2. * DO NOT EDIT THIS FILE.
  3. * See the following change record for more information,
  4. * https://www.drupal.org/node/3084859
  5. * @preserve
  6. */
  7. /**
  8. * Generic elements.
  9. */
  10. ::selection {
  11. background: var(--gin-color-primary-light-hover);
  12. }
  13. html {
  14. font-family: var(--gin-font);
  15. font-size: 100%;
  16. font-weight: normal;
  17. font-style: normal;
  18. line-height: var(--line-height);
  19. scroll-padding-block-start: var(--gin-scroll-offset) !important;
  20. }
  21. body {
  22. overflow-x: hidden;
  23. word-wrap: break-word;
  24. hyphens: auto;
  25. color: var(--gin-color-text);
  26. background: var(--app-bg-color);
  27. @media (--admin-large) {
  28. overflow-x: auto;
  29. }
  30. }
  31. a,
  32. .link,
  33. button.link {
  34. word-wrap: break-word;
  35. color: var(--gin-color-primary);
  36. overflow-wrap: break-word;
  37. text-decoration-style: var(--gin-link-decoration-style);
  38. }
  39. *|*:any-link:not(svg|a) {
  40. -webkit-text-decoration: underline;
  41. text-decoration: underline;
  42. text-decoration-style: var(--gin-link-decoration-style);
  43. }
  44. a:hover,
  45. a:focus,
  46. .link:hover,
  47. .link:focus {
  48. -webkit-text-decoration: none;
  49. text-decoration: none;
  50. }
  51. a:hover,
  52. .link:hover {
  53. color: var(--color-link-hover);
  54. }
  55. a:active,
  56. .link:active {
  57. color: var(--color-link-active);
  58. }
  59. hr {
  60. height: 1px;
  61. margin: var(--gin-spacing-xl) 0;
  62. padding: 0;
  63. border: none;
  64. background: var(--color-divider);
  65. }
  66. summary {
  67. font-weight: bold;
  68. }
  69. /**
  70. * Reusable heading classes are included to help modules change the styling of
  71. * headings on a page without affecting accessibility.
  72. */
  73. h1,
  74. .heading-a {
  75. margin: var(--space-m) 0 var(--space-s);
  76. letter-spacing: -0.025em;
  77. font-size: var(--font-size-h1);
  78. font-weight: var(--gin-font-weight-normal);
  79. line-height: var(--line-height-heading);
  80. }
  81. h2,
  82. .heading-b {
  83. margin: var(--space-m) 0 var(--space-s);
  84. letter-spacing: -0.025em;
  85. font-size: var(--gin-font-size-h2);
  86. font-weight: var(--gin-font-weight-normal);
  87. line-height: var(--line-height-heading);
  88. }
  89. h3,
  90. .heading-c {
  91. margin: var(--space-m) 0 var(--space-s);
  92. letter-spacing: -0.025em;
  93. font-size: var(--gin-font-size-h3);
  94. font-weight: var(--gin-font-weight-normal);
  95. line-height: var(--line-height-heading);
  96. }
  97. h4,
  98. .heading-d {
  99. margin: var(--space-m) 0 var(--space-s);
  100. font-size: var(--font-size-h4);
  101. font-weight: bold;
  102. line-height: var(--line-height-heading);
  103. }
  104. h5,
  105. .heading-e {
  106. margin: var(--space-m) 0 var(--space-s);
  107. font-size: var(--font-size-h5);
  108. font-weight: bold;
  109. line-height: var(--line-height-heading);
  110. }
  111. h6,
  112. .heading-f {
  113. margin: var(--space-m) 0 var(--space-s);
  114. font-size: var(--font-size-h6);
  115. font-weight: bold;
  116. line-height: var(--line-height-heading);
  117. }
  118. p {
  119. margin: 1em 0;
  120. }
  121. dl {
  122. margin: 0 0 1.25rem;
  123. }
  124. dl dd,
  125. dl dl {
  126. margin-block-end: 0.625rem;
  127. margin-inline-start: 1.25rem;
  128. }
  129. blockquote {
  130. position: relative;
  131. margin: var(--gin-spacing-m);
  132. padding-inline-start: var(--gin-spacing-l);
  133. font-size: var(--gin-font-size-quote);
  134. &::before {
  135. position: absolute;
  136. display: block;
  137. width: 0.25rem;
  138. height: 100%;
  139. content: "";
  140. color: var(--color-absolutezero);
  141. border-radius: 2px;
  142. background-color: var(--gin-color-primary);
  143. font-family: var(--font-family-serif);
  144. font-size: var(--space-xxl);
  145. line-height: 1em;
  146. inset-block-start: 0;
  147. inset-inline-start: 0;
  148. }
  149. &::after {
  150. content: no-close-quote;
  151. }
  152. }
  153. address {
  154. font-style: italic;
  155. }
  156. u,
  157. ins {
  158. -webkit-text-decoration: underline;
  159. text-decoration: underline;
  160. }
  161. s,
  162. strike,
  163. del {
  164. -webkit-text-decoration: line-through;
  165. text-decoration: line-through;
  166. }
  167. big {
  168. font-size: larger;
  169. }
  170. small {
  171. font-size: smaller;
  172. }
  173. sub {
  174. vertical-align: sub;
  175. font-size: smaller;
  176. line-height: normal;
  177. }
  178. sup {
  179. vertical-align: super;
  180. font-size: smaller;
  181. line-height: normal;
  182. }
  183. abbr,
  184. acronym {
  185. border-bottom: dotted 1px;
  186. }
  187. ul {
  188. margin-block: 0.25em;
  189. margin-inline: 1.5em 0;
  190. padding-inline-start: 0;
  191. list-style-image: none;
  192. }
  193. ol {
  194. margin-block: 0.25em;
  195. margin-inline: 2em 0;
  196. padding: 0;
  197. }
  198. code {
  199. margin: 0.5em 0;
  200. }
  201. pre {
  202. margin: 0.5em 0;
  203. white-space: pre-wrap;
  204. }
  205. details {
  206. line-height: var(--details-line-height);
  207. & summary {
  208. padding: var(--gin-spacing-m);
  209. }
  210. }
  211. img {
  212. max-width: 100%;
  213. height: auto;
  214. }
  215. /**
  216. * Default focus styles for focused elements.
  217. *
  218. * This is applied globally to all interactive elements except Toolbar and
  219. * Settings Tray since they have their own styles.
  220. */
  221. .page-wrapper *:focus,
  222. .ui-dialog *:focus {
  223. outline: var(--focus-outline);
  224. }
  225. /**
  226. * These elements should not be displayed until they are processed by
  227. * JavaScript, and views-ui-noscript.css exists so browsers without JavaScript
  228. * will still display them.
  229. */
  230. .views-tabs,
  231. .views-display-top > input.button {
  232. display: none;
  233. }
  234. /* Set a dark color scheme to style native browser elements. */
  235. .gin--dark-mode {
  236. color-scheme: dark;
  237. }
  238. /* Enforcing colors on visually hidden text does not change anything for the
  239. user, but it prevents accessibility scanners like Wave from reporting contrast
  240. errors on visually hidden elements. While this is certainly an issue with the
  241. scanners and not Gin, this ensures that scans provide an accurate account of
  242. Gin's contrast support. */
  243. .visually-hidden {
  244. color: #000;
  245. .gin--dark-mode
  246. &.skip-link {
  247. color: var(--gin-color-button-text);
  248. }
  249. }

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.