aboutsummaryrefslogtreecommitdiff
path: root/styles/_alert.scss
blob: e041d4b8b97967c5b502676dd6d29adb86694d15 (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
46
47
48
49
50
51
52
53
54
55
56
57
@use "./variables" as *;

div[role="alert"] {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.75rem;

  padding: 1rem;
  margin-block: 1.5rem;
  margin-inline: 0.5rem;

  border-radius: 8px;
  border: 1px solid rgba(0,0,0,0.1);
  box-shadow: 0 4px 6px rgba(0,0,0,0.05), inset 0 1px 0 rgba(255,255,255,0.5);
  //background-image: $glossyGradient;

  svg {
    width: 2em;
    height: 2em;
    margin-inline-end: 0.5rem;
    color: inherit;
    vertical-align: middle;
    flex-shrink: 0;
  }

  p {
    margin-block: 0;
    font-weight: 500;
  }
}

div[role="alert"].note {
  background-color: #e7f3ff;
  color: #004a99;
  border-color: #b3d7ff;

  &::before {
    content: "i";
    background-color: #004a99;
    color: white;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
  }
}

div[role="alert"].warning {
  background-color: #fff4ce;
  color: #856404;
  border-color: #ffeeba;

  &::before {
    content: "!";
    background-color: #856404;
    color: white;
    box-shadow: 0 1px 2px rgba(0,0,0,0.2);
  }
}