Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/src/vs/sessions/browser/parts/mobile/contributions/media/mobileOverlayViews.css
13406 views
1
/*---------------------------------------------------------------------------------------------
2
* Copyright (c) Microsoft Corporation. All rights reserved.
3
* Licensed under the MIT License. See License.txt in the project root for license information.
4
*--------------------------------------------------------------------------------------------*/
5
6
/* Shared base for full-screen mobile overlay views (terminal, diff). */
7
8
.mobile-overlay-view {
9
position: fixed;
10
inset: 0;
11
z-index: 1000;
12
display: flex;
13
flex-direction: column;
14
background: var(--vscode-editor-background);
15
color: var(--vscode-editor-foreground, var(--vscode-foreground));
16
touch-action: manipulation;
17
-webkit-touch-callout: none;
18
user-select: none;
19
-webkit-user-select: none;
20
}
21
22
/* -- Header ------------------------------------------------------------------------------------- */
23
24
.mobile-overlay-header {
25
display: flex;
26
align-items: center;
27
gap: 4px;
28
height: 56px;
29
min-height: 56px;
30
padding: 0 8px;
31
padding-top: env(safe-area-inset-top);
32
border-bottom: 1px solid var(--vscode-panel-border, var(--vscode-editorWidget-border, transparent));
33
flex-shrink: 0;
34
box-sizing: content-box;
35
}
36
37
.mobile-overlay-back-btn {
38
display: flex;
39
align-items: center;
40
gap: 4px;
41
height: 44px;
42
min-width: 44px;
43
padding: 0 8px;
44
border: none;
45
background: none;
46
color: var(--vscode-foreground);
47
cursor: pointer;
48
border-radius: 4px;
49
font-size: 14px;
50
white-space: nowrap;
51
touch-action: manipulation;
52
}
53
54
.mobile-overlay-back-btn:active {
55
background: var(--vscode-toolbar-hoverBackground);
56
}
57
58
.mobile-overlay-back-btn .back-btn-label {
59
font-size: 14px;
60
color: var(--vscode-foreground);
61
}
62
63
.mobile-overlay-header-info {
64
flex: 1;
65
min-width: 0;
66
display: flex;
67
flex-direction: column;
68
justify-content: center;
69
}
70
71
.mobile-overlay-header-title {
72
font-size: 14px;
73
font-weight: 500;
74
color: var(--vscode-foreground);
75
overflow: hidden;
76
text-overflow: ellipsis;
77
white-space: nowrap;
78
}
79
80
.mobile-overlay-header-subtitle {
81
font-size: 12px;
82
color: var(--vscode-descriptionForeground);
83
overflow: hidden;
84
text-overflow: ellipsis;
85
white-space: nowrap;
86
}
87
88
.mobile-overlay-header-badge {
89
display: inline-flex;
90
align-items: center;
91
gap: 3px;
92
padding: 1px 6px;
93
border-radius: 10px;
94
font-size: 11px;
95
font-weight: 500;
96
white-space: nowrap;
97
flex-shrink: 0;
98
}
99
100
.mobile-overlay-header-badge.success {
101
background-color: color-mix(in srgb, var(--vscode-testing-iconPassed) 20%, transparent);
102
color: var(--vscode-testing-iconPassed);
103
}
104
105
.mobile-overlay-header-badge.error {
106
background-color: color-mix(in srgb, var(--vscode-errorForeground) 20%, transparent);
107
color: var(--vscode-errorForeground);
108
}
109
110
.mobile-overlay-header-badge.running {
111
background-color: color-mix(in srgb, var(--vscode-textLink-foreground) 20%, transparent);
112
color: var(--vscode-textLink-foreground);
113
}
114
115
/* -- Body --------------------------------------------------------------------------------------- */
116
117
.mobile-overlay-body {
118
flex: 1;
119
overflow: hidden;
120
display: flex;
121
flex-direction: column;
122
}
123
124
.mobile-overlay-scroll {
125
flex: 1;
126
overflow-y: auto;
127
overflow-x: auto;
128
-webkit-overflow-scrolling: touch;
129
overscroll-behavior: contain;
130
padding-bottom: env(safe-area-inset-bottom);
131
}
132
133
/* -- Footer toolbar --------------------------------------------------------------------- */
134
135
.mobile-overlay-footer {
136
display: flex;
137
align-items: center;
138
gap: 8px;
139
padding: 8px 12px;
140
padding-bottom: calc(8px + env(safe-area-inset-bottom));
141
border-top: 1px solid var(--vscode-panel-border, transparent);
142
background: var(--vscode-editor-background);
143
flex-shrink: 0;
144
}
145
146
.mobile-overlay-footer-btn {
147
display: flex;
148
align-items: center;
149
gap: 6px;
150
height: 36px;
151
padding: 0 14px;
152
border-radius: 6px;
153
border: 1px solid var(--vscode-widget-border, color-mix(in srgb, var(--vscode-foreground) 15%, transparent));
154
background: transparent;
155
color: var(--vscode-foreground);
156
font-size: 13px;
157
cursor: pointer;
158
touch-action: manipulation;
159
white-space: nowrap;
160
}
161
162
.mobile-overlay-footer-btn:active {
163
background: var(--vscode-toolbar-hoverBackground);
164
}
165
166
/* -- Terminal-specific ---------------------------------------------------------------- */
167
168
.mobile-terminal-output {
169
font-family: var(--monaco-monospace-font, 'SF Mono', Menlo, Monaco, Consolas, monospace);
170
font-size: 13px;
171
line-height: 1.5;
172
white-space: pre; /* preserve columns; horizontal scroll for long lines */
173
color: var(--vscode-editor-foreground, var(--vscode-foreground));
174
padding: 12px 16px;
175
min-height: 100%;
176
box-sizing: border-box;
177
}
178
179
.mobile-terminal-output.truncated::after {
180
content: '\A[output truncated]';
181
display: block;
182
color: var(--vscode-descriptionForeground);
183
font-style: italic;
184
}
185
186
.mobile-terminal-jump-btn {
187
position: absolute;
188
bottom: 64px;
189
right: 16px;
190
right: calc(16px + env(safe-area-inset-right));
191
height: 36px;
192
padding: 0 14px;
193
border-radius: 18px;
194
border: 1px solid var(--vscode-widget-border, transparent);
195
background: var(--vscode-editor-background);
196
color: var(--vscode-foreground);
197
font-size: 13px;
198
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
199
cursor: pointer;
200
touch-action: manipulation;
201
transition: opacity 0.15s ease;
202
}
203
204
.mobile-terminal-jump-btn.hidden {
205
opacity: 0;
206
pointer-events: none;
207
}
208
209
/* -- Diff-specific ------------------------------------------------------------------------ */
210
211
.mobile-diff-output {
212
font-family: var(--monaco-monospace-font, 'SF Mono', Menlo, Monaco, Consolas, monospace);
213
font-size: 12px;
214
line-height: 1.6;
215
white-space: pre;
216
padding: 8px 0;
217
min-height: 100%;
218
box-sizing: border-box;
219
}
220
221
.mobile-diff-hunk-header {
222
display: block;
223
color: var(--vscode-descriptionForeground);
224
background: color-mix(in srgb, var(--vscode-foreground) 6%, transparent);
225
padding: 4px 16px;
226
font-size: 11px;
227
user-select: none;
228
-webkit-user-select: none;
229
}
230
231
.mobile-diff-line {
232
display: flex;
233
gap: 0;
234
}
235
236
.mobile-diff-line-num {
237
flex-shrink: 0;
238
width: 40px;
239
padding: 0 8px;
240
color: var(--vscode-editorLineNumber-foreground);
241
text-align: right;
242
user-select: none;
243
-webkit-user-select: none;
244
}
245
246
.mobile-diff-gutter {
247
flex-shrink: 0;
248
width: 16px;
249
text-align: center;
250
padding: 0 2px;
251
user-select: none;
252
-webkit-user-select: none;
253
}
254
255
.mobile-diff-content {
256
flex: 1;
257
padding: 0 16px 0 4px;
258
user-select: text;
259
-webkit-user-select: text;
260
}
261
262
/* Added lines — soft green tint on the row, vibrant green text. The tint is intentionally very light (8%) so the text remains the loudest visual signal, matching the mockup. */
263
.mobile-diff-line.added {
264
background: color-mix(in srgb, var(--vscode-gitDecoration-addedResourceForeground) 8%, transparent);
265
}
266
267
.mobile-diff-line.added .mobile-diff-line-num,
268
.mobile-diff-line.added .mobile-diff-gutter,
269
.mobile-diff-line.added .mobile-diff-content {
270
color: var(--vscode-gitDecoration-addedResourceForeground);
271
}
272
273
/* Removed lines — same treatment with the deletion color. */
274
.mobile-diff-line.removed {
275
background: color-mix(in srgb, var(--vscode-gitDecoration-deletedResourceForeground) 8%, transparent);
276
}
277
278
.mobile-diff-line.removed .mobile-diff-line-num,
279
.mobile-diff-line.removed .mobile-diff-gutter,
280
.mobile-diff-line.removed .mobile-diff-content {
281
color: var(--vscode-gitDecoration-deletedResourceForeground);
282
}
283
284
.mobile-diff-empty-state {
285
display: flex;
286
align-items: center;
287
justify-content: center;
288
flex: 1;
289
color: var(--vscode-descriptionForeground);
290
font-size: 14px;
291
padding: 32px;
292
text-align: center;
293
}
294
295