summaryrefslogtreecommitdiffstats
path: root/toolkit/themes/shared/design-system/text-and-typography.css
blob: 123847fe8b703ecb224c52630a5ec2d888ba9795 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

/* Typography scale */
:root {
  font: message-box;
}

h1,
.heading-xlarge {
  font-weight: var(--font-weight-bold);
  font-size: var(--font-size-xxlarge);
}

h2,
.heading-large {
  font-weight: var(--font-weight-bold);
  font-size: var(--font-size-xlarge);
}

h3,
.heading-medium {
  font-weight: var(--font-weight-bold);
  font-size: var(--font-size-large);
}

/* Text helpers */
.text-deemphasized {
  font-size: var(--font-size-small);
  color: var(--text-color-deemphasized);
}

.text-error {
  color: var(--text-color-error);
  font-weight: var(--font-weight-bold);
}

.text-truncated-ellipsis {
  /* Will not work on `display: flex` items
    unless you wrap its contents with another element that has this class. */
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}