// code: page parts in the one page language (docs/ui-language.md). Tokens only. // File view (blob page, RepoFile canvas): the sheet is the only box. The code sits on the sheet's // own surface, 13.5px mono on 22px lines, with a 72px number column and no ring or fill inside. .sheet > .file > .file-view { background: none; border: 0; border-radius: 0; padding: 10px 0; } .sheet > .file > .file-view .file-table { font-family: 'IBM Plex Mono', monospace; font-size: 13.5px; line-height: 22px; .ln { box-sizing: border-box; width: 72px; min-width: 72px; max-width: 72px; padding: 0 18px 0 0; background: var(--surface); border-right: 0; color: var(--muted); a { color: inherit; } } .code { padding: 0 16px 0 0; } } // The line count reads as mono and quiet, the way the canvas sets it. .sheet > .sheet-tools > .mono { font-family: 'IBM Plex Mono', monospace; font-size: 13px; color: var(--muted); white-space: nowrap; } // Scrub (files at one commit): the same tree rows as the repo home, in the sheet. .sheet [data-scrub-tree] { padding: 4px 0; } .sheet [data-scrub-tree] .tree-entry { display: flex; align-items: center; gap: 10px; height: 30px; min-width: 0; padding: 0 18px; } .sheet [data-scrub-tree] .tree-kind { display: inline-flex; flex: none; color: var(--muted); } .sheet [data-scrub-tree] .kind-icon { flex: none; width: 14px; height: 14px; fill: none; stroke: currentColor; } .sheet [data-scrub-tree] .tree-entry-name { flex: 1 1 auto; min-width: 0; overflow: hidden; font-family: 'IBM Plex Mono', monospace; font-size: 13px; white-space: nowrap; text-overflow: ellipsis; color: var(--text); text-decoration: none; } .sheet [data-scrub-tree] .tree-entry:hover { background: var(--surface-2); } // Markdown on a file page: the same reading column as the repo home README. .sheet > .file > .markdown-body { max-width: 796px; padding: 22px 28px 28px; } // Code in a sheet is one soft chip, the same radius everywhere. main code { border-radius: 6px; } // A release's downloads wrap onto more lines instead of running past the sheet. .opened > .sub { flex-wrap: wrap; gap: 4px 16px; min-width: 0; > a { min-width: 0; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } } // Checks: the summary reads on one line, and Show checks opens its list as the shared panel under it, // over the page, so a tools row keeps its height. .checks-summary { flex-wrap: nowrap; .checks-details { position: relative; flex-basis: auto; > .status-list { position: absolute; z-index: 30; top: calc(100% + 6px); left: 0; width: max-content; max-width: min(520px, calc(100vw - 32px)); margin: 0; padding: 10px 14px; } } } // A commit's message under its tools row is text, not a code box: the title is the head already. .sheet > .sec > pre.commit-message { margin: 0; padding: 14px 0; border: 0; border-radius: 0; background: none; white-space: pre-wrap; } // Split diff columns: the numbers and the comment mark keep their width, the two code halves share // the rest. .diff-table.diff-split { > colgroup > .col-plus { width: 22px; } > colgroup > .col-ln { width: 52px; } } // A file's head reads in order, name, change and counts, with nothing pushed to the far end. .diff-file-header.sheet-tools { justify-content: flex-start; gap: 12px; } // Above the files: the count and the view choices on one line, the count first. .diff-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; min-height: 32px; padding: 0 4px; > h2 { margin: 0; font-size: 15px; font-weight: 600; } > .diff-toolbar { margin: 0; } } // A commit's status sits in its line as one more word, and its list opens as the shared panel. .commit-status { display: inline-block; vertical-align: baseline; &[open] > .status-list { left: 0; right: auto; width: max-content; max-width: min(460px, calc(100vw - 32px)); padding: 10px 14px; } }