aboutsummaryrefslogtreecommitdiffstats
path: root/web_src/css/modules/tippy.css
blob: 45feab757477a5421f75957ca6f7dd9dc67d78b3 (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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
/* styles are based on node_modules/tippy.js/dist/tippy.css */

/* class to hide tippy target elements on page load */
.tippy-target {
  display: none !important;
}

[data-tippy-root] {
  max-width: calc(100vw - 32px);
}

.tippy-box {
  position: relative;
  background-color: var(--color-body);
  color: var(--color-secondary-dark-6);
  border: 1px solid var(--color-secondary);
  border-radius: var(--border-radius);
  font-size: 1rem;
}

.tippy-content {
  position: relative;
  padding: 1rem; /* if you need different padding, use different data-theme */
  z-index: 1;
}

/* tooltip theme for text tooltips */

.tippy-box[data-theme="tooltip"] {
  background-color: var(--color-tooltip-bg);
  color: var(--color-tooltip-text);
  border: none;
}

.tippy-box[data-theme="tooltip"] .tippy-content {
  padding: 0.5rem 1rem;
}

.tippy-box[data-theme="tooltip"] .tippy-svg-arrow-inner,
.tippy-box[data-theme="tooltip"] .tippy-svg-arrow-outer {
  fill: var(--color-tooltip-bg);
}

/* menu theme for .ui.menu */

.tippy-box[data-theme="menu"] {
  background-color: var(--color-menu);
  color: var(--color-text);
}

.tippy-box[data-theme="menu"] .tippy-content {
  padding: 0;
}

.tippy-box[data-theme="menu"] .tippy-svg-arrow-inner {
  fill: var(--color-menu);
}

/* box-with-header theme to look like .ui.attached.segment. can contain .ui.attached.header */

.tippy-box[data-theme="box-with-header"] .tippy-content {
  background: var(--color-box-body);
  padding: 0;
}

.tippy-box[data-theme="box-with-header"][data-placement^="top"] .tippy-svg-arrow-inner {
  fill: var(--color-box-body);
}

.tippy-box[data-theme="box-with-header"][data-placement^="bottom"] .tippy-svg-arrow-inner {
  fill: var(--color-box-header);
}

.tippy-box[data-placement^="top"] > .tippy-svg-arrow {
  bottom: 0;
}

.tippy-box[data-placement^="top"] > .tippy-svg-arrow::after,
.tippy-box[data-placement^="top"] > .tippy-svg-arrow > svg {
  top: 16px;
  transform: rotate(180deg);
}

.tippy-box[data-placement^="bottom"] > .tippy-svg-arrow {
  top: 0;
}

.tippy-box[data-placement^="bottom"] > .tippy-svg-arrow > svg {
  bottom: 16px;
}

.tippy-box[data-placement^="left"] > .tippy-svg-arrow {
  right: 0;
}

.tippy-box[data-placement^="left"] > .tippy-svg-arrow::after,
.tippy-box[data-placement^="left"] > .tippy-svg-arrow > svg {
  transform: rotate(90deg);
  top: calc(50% - 3px);
  left: 11px;
}

.tippy-box[data-placement^="right"] > .tippy-svg-arrow {
  left: 0;
}

.tippy-box[data-placement^="right"] > .tippy-svg-arrow::after,
.tippy-box[data-placement^="right"] > .tippy-svg-arrow > svg {
  transform: rotate(-90deg);
  top: calc(50% - 3px);
  right: 11px;
}

.tippy-svg-arrow {
  width: 16px;
  height: 16px;
  text-align: initial;
}

.tippy-svg-arrow,
.tippy-svg-arrow > svg {
  position: absolute;
}

.tippy-svg-arrow-outer {
  fill: var(--color-secondary);
}

.tippy-svg-arrow-inner {
  fill: var(--color-body);
}