| b69ab31 | | | 1 | /** |
| b69ab31 | | | 2 | * Copyright (c) Meta Platforms, Inc. and affiliates. |
| b69ab31 | | | 3 | * |
| b69ab31 | | | 4 | * This source code is licensed under the MIT license found in the |
| b69ab31 | | | 5 | * LICENSE file in the root directory of this source tree. |
| b69ab31 | | | 6 | */ |
| b69ab31 | | | 7 | |
| b69ab31 | | | 8 | .head-commit-info { |
| b69ab31 | | | 9 | margin-left: var(--halfpad); |
| b69ab31 | | | 10 | } |
| b69ab31 | | | 11 | .you-are-here-container { |
| b69ab31 | | | 12 | display: flex; |
| b69ab31 | | | 13 | gap: var(--pad); |
| b69ab31 | | | 14 | align-items: center; |
| b69ab31 | | | 15 | } |
| b69ab31 | | | 16 | |
| b69ab31 | | | 17 | .uncommitted-changes { |
| b69ab31 | | | 18 | padding: var(--halfpad) 0; |
| b69ab31 | | | 19 | display: flex; |
| b69ab31 | | | 20 | flex-direction: column; |
| b69ab31 | | | 21 | gap: var(--halfpad); |
| b69ab31 | | | 22 | } |
| b69ab31 | | | 23 | .conflicts-header { |
| b69ab31 | | | 24 | display: flex; |
| b69ab31 | | | 25 | flex-direction: column; |
| b69ab31 | | | 26 | margin: var(--pad) 0; |
| b69ab31 | | | 27 | } |
| b69ab31 | | | 28 | .file-tree { |
| b69ab31 | | | 29 | margin-top: 4px; |
| b69ab31 | | | 30 | } |
| b69ab31 | | | 31 | .file-tree-section { |
| b69ab31 | | | 32 | margin-top: 4px; |
| b69ab31 | | | 33 | } |
| b69ab31 | | | 34 | .file-tree-level { |
| b69ab31 | | | 35 | --file-tree-indent: calc(2 * var(--pad)); |
| b69ab31 | | | 36 | margin-left: var(--file-tree-indent); |
| b69ab31 | | | 37 | position: relative; |
| b69ab31 | | | 38 | } |
| b69ab31 | | | 39 | .changed-files > .file-tree > .file-tree-level { |
| b69ab31 | | | 40 | /* Override the top-level to not have indent */ |
| b69ab31 | | | 41 | margin-left: 0; |
| b69ab31 | | | 42 | } |
| b69ab31 | | | 43 | .file-tree-level > .changed-file { |
| b69ab31 | | | 44 | margin-left: var(--halfpad); |
| b69ab31 | | | 45 | } |
| b69ab31 | | | 46 | .file-tree-folder-path { |
| b69ab31 | | | 47 | display: flex; |
| b69ab31 | | | 48 | align-items: center; |
| b69ab31 | | | 49 | gap: var(--halfpad); |
| b69ab31 | | | 50 | } |
| b69ab31 | | | 51 | .file-tree-folder-path vscode-button::part(control) { |
| b69ab31 | | | 52 | font-size: initial; |
| b69ab31 | | | 53 | max-width: unset; |
| b69ab31 | | | 54 | } |
| b69ab31 | | | 55 | |
| b69ab31 | | | 56 | .changed-files-pages-buttons { |
| b69ab31 | | | 57 | display: flex; |
| b69ab31 | | | 58 | align-items: center; |
| b69ab31 | | | 59 | gap: var(--halfpad); |
| b69ab31 | | | 60 | } |
| b69ab31 | | | 61 | |
| b69ab31 | | | 62 | .file-tree-level .file-tree-level:before { |
| b69ab31 | | | 63 | content: ''; |
| b69ab31 | | | 64 | position: absolute; |
| b69ab31 | | | 65 | left: calc(var(--file-tree-indent) / -2); |
| b69ab31 | | | 66 | height: 100%; |
| b69ab31 | | | 67 | top: 0; |
| b69ab31 | | | 68 | border-left: 1px solid var(--divider-background); |
| b69ab31 | | | 69 | } |
| b69ab31 | | | 70 | .file-tree-level:hover > .file-tree-level:before { |
| b69ab31 | | | 71 | border-left: 1px solid var(--foreground); |
| b69ab31 | | | 72 | } |
| b69ab31 | | | 73 | |
| b69ab31 | | | 74 | .changed-files { |
| b69ab31 | | | 75 | display: flex; |
| b69ab31 | | | 76 | flex-direction: column; |
| b69ab31 | | | 77 | } |
| b69ab31 | | | 78 | .changed-files .changed-file { |
| b69ab31 | | | 79 | display: flex; |
| b69ab31 | | | 80 | align-items: center; |
| b69ab31 | | | 81 | gap: var(--halfpad); |
| b69ab31 | | | 82 | margin-right: var(--halfpad); |
| b69ab31 | | | 83 | transition: color 0.1s; |
| b69ab31 | | | 84 | line-height: 25px; |
| b69ab31 | | | 85 | /* when files are expanded with chunk selection, use position sticky to keep showing path at the top */ |
| b69ab31 | | | 86 | position: sticky; |
| b69ab31 | | | 87 | top: 0; |
| b69ab31 | | | 88 | background-color: var(--changed-files-overflow-color, var(--background)); |
| b69ab31 | | | 89 | z-index: 10; |
| b69ab31 | | | 90 | } |
| b69ab31 | | | 91 | |
| b69ab31 | | | 92 | .changed-files-list .changed-file:nth-child(n + 15):last-child { |
| b69ab31 | | | 93 | margin-bottom: 10px; |
| b69ab31 | | | 94 | } |
| b69ab31 | | | 95 | |
| b69ab31 | | | 96 | .changed-files .banner { |
| b69ab31 | | | 97 | padding: var(--pad); |
| b69ab31 | | | 98 | margin: var(--pad) 0; |
| b69ab31 | | | 99 | max-width: 500px; |
| b69ab31 | | | 100 | } |
| b69ab31 | | | 101 | |
| b69ab31 | | | 102 | .changed-files-list-container { |
| b69ab31 | | | 103 | display: flex; |
| b69ab31 | | | 104 | flex-direction: column; |
| b69ab31 | | | 105 | position: relative; |
| b69ab31 | | | 106 | overflow-y: hidden; |
| b69ab31 | | | 107 | } |
| b69ab31 | | | 108 | |
| b69ab31 | | | 109 | .changed-files-list { |
| b69ab31 | | | 110 | --changed-files-list-height: 500px; |
| b69ab31 | | | 111 | --changed-files-overflow-color: var(--background); |
| b69ab31 | | | 112 | overflow-y: scroll; |
| b69ab31 | | | 113 | max-height: var(--changed-files-list-height); |
| b69ab31 | | | 114 | } |
| b69ab31 | | | 115 | |
| b69ab31 | | | 116 | .changed-file:focus-visible { |
| b69ab31 | | | 117 | outline: var(--focus-border) 1px auto; |
| b69ab31 | | | 118 | outline-offset: -1px; |
| b69ab31 | | | 119 | } |
| b69ab31 | | | 120 | |
| b69ab31 | | | 121 | .changed-files-list .collapsable { |
| b69ab31 | | | 122 | margin: var(--pad) 0; |
| b69ab31 | | | 123 | } |
| b69ab31 | | | 124 | .changed-files-list .collapsable-title { |
| b69ab31 | | | 125 | user-select: none; |
| b69ab31 | | | 126 | |
| b69ab31 | | | 127 | font-weight: 500; |
| b69ab31 | | | 128 | opacity: 0.9; |
| b69ab31 | | | 129 | font-variant: all-small-caps; |
| b69ab31 | | | 130 | } |
| b69ab31 | | | 131 | .changed-files-list .collapsable-contents { |
| b69ab31 | | | 132 | margin-left: calc(2 * var(--pad)); |
| b69ab31 | | | 133 | } |
| b69ab31 | | | 134 | |
| b69ab31 | | | 135 | .changed-files-list:after { |
| b69ab31 | | | 136 | --overflow-gradient-height: 20px; |
| b69ab31 | | | 137 | display: block; |
| b69ab31 | | | 138 | content: ' '; |
| b69ab31 | | | 139 | width: 100%; |
| b69ab31 | | | 140 | height: var(--overflow-gradient-height); |
| b69ab31 | | | 141 | background: linear-gradient(transparent, var(--changed-files-overflow-color)); |
| b69ab31 | | | 142 | z-index: 10; |
| b69ab31 | | | 143 | position: absolute; |
| b69ab31 | | | 144 | bottom: 0px; |
| b69ab31 | | | 145 | left: 0; |
| b69ab31 | | | 146 | top: calc(var(--changed-files-list-height) - var(--overflow-gradient-height)); |
| b69ab31 | | | 147 | pointer-events: none; |
| b69ab31 | | | 148 | } |
| b69ab31 | | | 149 | |
| b69ab31 | | | 150 | .changed-file-path { |
| b69ab31 | | | 151 | display: flex; |
| b69ab31 | | | 152 | align-items: center; |
| b69ab31 | | | 153 | gap: var(--halfpad); |
| b69ab31 | | | 154 | cursor: pointer; |
| b69ab31 | | | 155 | overflow: hidden; |
| b69ab31 | | | 156 | } |
| b69ab31 | | | 157 | |
| b69ab31 | | | 158 | .changed-file-path-text { |
| b69ab31 | | | 159 | white-space: nowrap; |
| b69ab31 | | | 160 | overflow: hidden; |
| b69ab31 | | | 161 | text-overflow: ellipsis; |
| b69ab31 | | | 162 | /* ellipsis dots on the start of the file path rather than the end */ |
| b69ab31 | | | 163 | direction: rtl; |
| b69ab31 | | | 164 | text-align: left; |
| b69ab31 | | | 165 | } |
| b69ab31 | | | 166 | .changed-file-path .tooltip-creator { |
| b69ab31 | | | 167 | overflow: hidden; |
| b69ab31 | | | 168 | } |
| b69ab31 | | | 169 | |
| b69ab31 | | | 170 | .changed-file-path:hover { |
| b69ab31 | | | 171 | color: var(--highlight-foreground); |
| b69ab31 | | | 172 | } |
| b69ab31 | | | 173 | |
| b69ab31 | | | 174 | .file-actions { |
| b69ab31 | | | 175 | display: flex; |
| b69ab31 | | | 176 | flex-wrap: nowrap; |
| b69ab31 | | | 177 | align-items: center; |
| b69ab31 | | | 178 | gap: var(--halfpad); |
| b69ab31 | | | 179 | } |
| b69ab31 | | | 180 | |
| b69ab31 | | | 181 | .file-actions .tooltip-creator { |
| b69ab31 | | | 182 | display: inline-flex; |
| b69ab31 | | | 183 | } |
| b69ab31 | | | 184 | |
| b69ab31 | | | 185 | .file-added { |
| b69ab31 | | | 186 | color: var(--scm-added-foreground); |
| b69ab31 | | | 187 | } |
| b69ab31 | | | 188 | .file-modified { |
| b69ab31 | | | 189 | color: var(--scm-modified-foreground); |
| b69ab31 | | | 190 | } |
| b69ab31 | | | 191 | .file-removed { |
| b69ab31 | | | 192 | color: var(--scm-removed-foreground); |
| b69ab31 | | | 193 | } |
| b69ab31 | | | 194 | .file-missing { |
| b69ab31 | | | 195 | color: var(--scm-missing-foreground); |
| b69ab31 | | | 196 | } |
| b69ab31 | | | 197 | .file-unresolved { |
| b69ab31 | | | 198 | color: var(--scm-modified-foreground); |
| b69ab31 | | | 199 | } |
| b69ab31 | | | 200 | .file-resolved { |
| b69ab31 | | | 201 | color: var(--scm-added-foreground); |
| b69ab31 | | | 202 | } |
| b69ab31 | | | 203 | .file-ignored { |
| b69ab31 | | | 204 | opacity: 0.9; |
| b69ab31 | | | 205 | } |
| b69ab31 | | | 206 | |
| b69ab31 | | | 207 | .file-generated { |
| b69ab31 | | | 208 | opacity: 0.5; |
| b69ab31 | | | 209 | } |
| b69ab31 | | | 210 | .file-partial { |
| b69ab31 | | | 211 | opacity: 0.8; |
| b69ab31 | | | 212 | } |
| b69ab31 | | | 213 | |
| b69ab31 | | | 214 | .show-on-hover, |
| b69ab31 | | | 215 | .file-show-on-hover { |
| b69ab31 | | | 216 | opacity: 0; |
| b69ab31 | | | 217 | transition: opacity 0.1s; |
| b69ab31 | | | 218 | } |
| b69ab31 | | | 219 | .show-on-hover:focus-within, |
| b69ab31 | | | 220 | .file-show-on-hover:focus-within { |
| b69ab31 | | | 221 | opacity: 1; |
| b69ab31 | | | 222 | } |
| b69ab31 | | | 223 | .uncommitted-changes:hover .show-on-hover { |
| b69ab31 | | | 224 | opacity: 1; |
| b69ab31 | | | 225 | } |
| b69ab31 | | | 226 | .changed-file:hover .file-show-on-hover { |
| b69ab31 | | | 227 | opacity: 1; |
| b69ab31 | | | 228 | } |
| b69ab31 | | | 229 | .uncommitted-changes:hover vscode-button:disabled.show-on-hover { |
| b69ab31 | | | 230 | opacity: 0.4; |
| b69ab31 | | | 231 | } |
| b69ab31 | | | 232 | /* make disabled buttons show up on hover for each changed file */ |
| b69ab31 | | | 233 | :is(button, vscode-button).file-show-on-hover:disabled { |
| b69ab31 | | | 234 | opacity: 0 !important; |
| b69ab31 | | | 235 | } |
| b69ab31 | | | 236 | .changed-file:hover :is(button, vscode-button).file-show-on-hover:disabled { |
| b69ab31 | | | 237 | opacity: 0.4 !important; |
| b69ab31 | | | 238 | } |
| b69ab31 | | | 239 | |
| b69ab31 | | | 240 | .changed-file-list .button-rows, |
| b69ab31 | | | 241 | .uncommitted-changes .button-rows { |
| b69ab31 | | | 242 | display: flex; |
| b69ab31 | | | 243 | flex-direction: column; |
| b69ab31 | | | 244 | gap: var(--halfpad); |
| b69ab31 | | | 245 | } |
| b69ab31 | | | 246 | |
| b69ab31 | | | 247 | .changed-file-list .button-row, |
| b69ab31 | | | 248 | .uncommitted-changes .button-row { |
| b69ab31 | | | 249 | display: flex; |
| b69ab31 | | | 250 | flex-wrap: wrap; |
| b69ab31 | | | 251 | gap: var(--halfpad) var(--pad); |
| b69ab31 | | | 252 | align-items: center; |
| b69ab31 | | | 253 | } |
| b69ab31 | | | 254 | |
| b69ab31 | | | 255 | .changed-file-list .button-row { |
| b69ab31 | | | 256 | padding-bottom: var(--halfpad); |
| b69ab31 | | | 257 | } |
| b69ab31 | | | 258 | |
| b69ab31 | | | 259 | .quick-commit-inputs input[type='text'] { |
| b69ab31 | | | 260 | opacity: 0; |
| b69ab31 | | | 261 | transition: opacity 0.1s; |
| b69ab31 | | | 262 | z-index: 1; |
| b69ab31 | | | 263 | } |
| b69ab31 | | | 264 | .uncommitted-changes:hover input[type='text'], |
| b69ab31 | | | 265 | .uncommitted-changes input[type='text']:focus-within, |
| b69ab31 | | | 266 | .quick-commit-inputs input[type='text']:not(:placeholder-shown) { |
| b69ab31 | | | 267 | opacity: 1; |
| b69ab31 | | | 268 | } |
| b69ab31 | | | 269 | |
| b69ab31 | | | 270 | .quick-commit-inputs { |
| b69ab31 | | | 271 | transition: background-color 0.1s; |
| b69ab31 | | | 272 | display: flex; |
| b69ab31 | | | 273 | gap: var(--pad); |
| b69ab31 | | | 274 | align-items: center; |
| b69ab31 | | | 275 | padding: 4px; |
| b69ab31 | | | 276 | margin: -4px; |
| b69ab31 | | | 277 | border-radius: 4px; |
| b69ab31 | | | 278 | position: relative; |
| b69ab31 | | | 279 | } |
| b69ab31 | | | 280 | .quick-commit-inputs:before { |
| b69ab31 | | | 281 | content: ''; |
| b69ab31 | | | 282 | position: absolute; |
| b69ab31 | | | 283 | left: 0; |
| b69ab31 | | | 284 | right: 0; |
| b69ab31 | | | 285 | height: 100%; |
| b69ab31 | | | 286 | width: 100%; |
| b69ab31 | | | 287 | border-radius: 4px; |
| b69ab31 | | | 288 | pointer-events: none; |
| b69ab31 | | | 289 | opacity: 0; |
| b69ab31 | | | 290 | } |
| b69ab31 | | | 291 | .quick-commit-inputs:hover:before { |
| b69ab31 | | | 292 | background-color: var(--button-icon-hover-background); |
| b69ab31 | | | 293 | transition: opacity 0.3s; |
| b69ab31 | | | 294 | opacity: 0.5; |
| b69ab31 | | | 295 | } |