-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcustom-styles.css
More file actions
149 lines (131 loc) · 3.4 KB
/
Copy pathcustom-styles.css
File metadata and controls
149 lines (131 loc) · 3.4 KB
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
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
body {
font-family: 'Noto Sans', ui-sans-serif, system-ui;
}
:root {
--theme-color: #45f3ff;
--content-max-width: 104ch;
--sidebar-toggle-alignment: start;
/* start center end */
--sidebar-toggle-bg: var(--color-mono-2);
--sidebar-toggle-bg-hover: var(--button-bg);
--sidebar-toggle-color: var(--color-mono-4);
--sidebar-toggle-color-hover: var(--button-color);
--sidebar-toggle-height: 42px;
--sidebar-toggle-margin-block: 24px;
--sidebar-toggle-width: 32px;
/* termynal style variables */
--termynal-bg: var(--code-bg);
--termynal-color: var(--code-color);
--termynal-color-subtle: var(--color-mono-5);
--termynal-highlight-color: var(--theme-color);
--termynal-cursor: #00ff00;
--termynal-font: var(--font-family-mono);
--termynal-font-size: var(--font-size-m);
--termynal-border-radius: var(--border-radius);
}
/* Dark mode toggle */
#dark-mode-toggle {
display: block;
padding: 4px 8px;
border-radius: 8px;
border: none;
background: var(--color-mono-2);
color: var(--theme-color);
font-size: 1.1em;
cursor: pointer;
transition: background 0.2s;
}
#dark-mode-toggle:hover {
background: var(--color-mono-4);
color: var(--theme-color);
}
/* Terminaly plugin styles customized to work with light and dark mode both */
[data-termynal] {
width: 100%;
max-width: 100%;
background: var(--termynal-bg);
color: var(--termynal-color);
font-size: var(--termynal-font-size);
font-family: var(--termynal-font);
border-radius: var(--termynal-border-radius);
padding: 38px 15px 10px;
position: relative;
-webkit-box-sizing: border-box;
box-sizing: border-box;
z-index: 1;
}
/* termynal window-control-icons */
[data-termynal]:before {
content: '';
position: absolute;
top: 15px;
left: 15px;
display: inline-block;
width: 15px;
height: 15px;
border-radius: 50%;
/* A little hack to display the window buttons in one pseudo element. */
background: #d9515d;
-webkit-box-shadow: 25px 0 0 #f4c025, 50px 0 0 #3ec930;
box-shadow: 25px 0 0 #f4c025, 50px 0 0 #3ec930;
}
/* termynal label */
[data-termynal]:after {
content: 'bash';
position: absolute;
color: var(--termynal-color-subtle);
top: 5px;
left: 0;
width: 100%;
text-align: center;
}
a[data-terminal-control] {
color: var(--termynal-highlight-color);
position: absolute;
top: 5px;
right: 15px;
z-index: 2;
text-decoration: none;
}
a[data-terminal-control]:hover {
color: var(--termynal-highlight-color);
font-weight: 700;
}
[data-ty] {
display: block;
}
[data-ty]:before {
/* Set up defaults and ensure empty lines are displayed. */
content: '';
display: inline-block;
vertical-align: middle;
}
[data-ty='input']:before,
[data-ty-prompt]:before {
margin-right: 0.75em;
color: var(--termynal-color);
}
[data-ty='input']:before {
content: '$';
}
[data-ty][data-ty-prompt]:before {
content: attr(data-ty-prompt);
}
[data-ty-cursor]:after {
content: attr(data-ty-cursor);
font-family: var(--termynal-font-family);
margin-left: 0.5em;
-webkit-animation: blink 1s infinite;
animation: blink 1s infinite;
}
/* Cursor animation */
@-webkit-keyframes blink {
50% {
opacity: 0;
}
}
@keyframes blink {
50% {
opacity: 0;
}
}