Unify border-radius
behavior (#26770)
## Changes - no more hardcoded `border-radius`es (apart from `0`) - no more value inconsistencies - no more guessing what pixel value you should use - two new variables: - `--border-radius-medium` (for elements where the normal border radius does not suffice) - `--border-radius-circle` (for displaying circles) --------- Co-authored-by: silverwind <me@silverwind.io>
This commit is contained in:
parent
ac2f8c9ac6
commit
dca2f9371d
17 changed files with 41 additions and 42 deletions
|
@ -16,7 +16,9 @@
|
||||||
--checkbox-mask-indeterminate: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M2 7.75A.75.75 0 012.75 7h10a.75.75 0 010 1.5h-10A.75.75 0 012 7.75z"></path></svg>');
|
--checkbox-mask-indeterminate: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M2 7.75A.75.75 0 012.75 7h10a.75.75 0 010 1.5h-10A.75.75 0 012 7.75z"></path></svg>');
|
||||||
--octicon-chevron-right: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16"><path d="M6.22 3.22a.75.75 0 0 1 1.06 0l4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L9.94 8 6.22 4.28a.75.75 0 0 1 0-1.06Z"></path></svg>');
|
--octicon-chevron-right: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16"><path d="M6.22 3.22a.75.75 0 0 1 1.06 0l4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L9.94 8 6.22 4.28a.75.75 0 0 1 0-1.06Z"></path></svg>');
|
||||||
/* non-color variables */
|
/* non-color variables */
|
||||||
--border-radius: 0.28571429rem;
|
--border-radius: 4px;
|
||||||
|
--border-radius-medium: 6px;
|
||||||
|
--border-radius-circle: 100%;
|
||||||
--opacity-disabled: 0.55;
|
--opacity-disabled: 0.55;
|
||||||
--height-loading: 16rem;
|
--height-loading: 16rem;
|
||||||
--tab-size: 4;
|
--tab-size: 4;
|
||||||
|
@ -309,7 +311,7 @@ details summary > * {
|
||||||
|
|
||||||
progress {
|
progress {
|
||||||
background: var(--color-secondary-dark-1);
|
background: var(--color-secondary-dark-1);
|
||||||
border-radius: 6px;
|
border-radius: var(--border-radius);
|
||||||
border: none;
|
border: none;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
@ -339,7 +341,7 @@ progress::-moz-progress-bar {
|
||||||
::-webkit-scrollbar-thumb {
|
::-webkit-scrollbar-thumb {
|
||||||
box-shadow: inset 0 0 0 6px var(--color-primary);
|
box-shadow: inset 0 0 0 6px var(--color-primary);
|
||||||
border: 2px solid transparent;
|
border: 2px solid transparent;
|
||||||
border-radius: 5px !important;
|
border-radius: var(--border-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
::-webkit-scrollbar-thumb:window-inactive {
|
::-webkit-scrollbar-thumb:window-inactive {
|
||||||
|
@ -454,7 +456,7 @@ a.label,
|
||||||
|
|
||||||
.issue-title code {
|
.issue-title code {
|
||||||
padding: 2px 4px;
|
padding: 2px 4px;
|
||||||
border-radius: 6px;
|
border-radius: var(--border-radius-medium);
|
||||||
background-color: var(--color-markup-code-block);
|
background-color: var(--color-markup-code-block);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1510,7 +1512,7 @@ img.ui.avatar,
|
||||||
margin-left: 0.4em;
|
margin-left: 0.4em;
|
||||||
height: 0.67em;
|
height: 0.67em;
|
||||||
width: 0.67em;
|
width: 0.67em;
|
||||||
border-radius: 0.15em;
|
border-radius: var(--border-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
.attention-icon {
|
.attention-icon {
|
||||||
|
@ -2013,7 +2015,7 @@ a.ui.basic.label:hover {
|
||||||
|
|
||||||
.color-icon {
|
.color-icon {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
border-radius: 100%;
|
border-radius: var(--border-radius-circle);
|
||||||
height: 14px;
|
height: 14px;
|
||||||
width: 14px;
|
width: 14px;
|
||||||
}
|
}
|
||||||
|
|
|
@ -98,7 +98,7 @@
|
||||||
|
|
||||||
.feeds code {
|
.feeds code {
|
||||||
padding: 2px 4px;
|
padding: 2px 4px;
|
||||||
border-radius: 3px;
|
border-radius: var(--border-radius);
|
||||||
background-color: var(--color-markup-code-block);
|
background-color: var(--color-markup-code-block);
|
||||||
word-break: break-all;
|
word-break: break-all;
|
||||||
}
|
}
|
||||||
|
|
|
@ -83,7 +83,7 @@ text-expander .suggestions {
|
||||||
margin-top: 24px;
|
margin-top: 24px;
|
||||||
list-style: none;
|
list-style: none;
|
||||||
background: var(--color-box-body);
|
background: var(--color-box-body);
|
||||||
border-radius: 5px;
|
border-radius: var(--border-radius);
|
||||||
border: 1px solid var(--color-secondary);
|
border: 1px solid var(--color-secondary);
|
||||||
box-shadow: 0 .5rem 1rem var(--color-shadow);
|
box-shadow: 0 .5rem 1rem var(--color-shadow);
|
||||||
}
|
}
|
||||||
|
@ -101,15 +101,15 @@ text-expander .suggestions li + li {
|
||||||
}
|
}
|
||||||
|
|
||||||
text-expander .suggestions li:first-child {
|
text-expander .suggestions li:first-child {
|
||||||
border-radius: 4px 4px 0 0;
|
border-radius: var(--border-radius) var(--border-radius) 0 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
text-expander .suggestions li:last-child {
|
text-expander .suggestions li:last-child {
|
||||||
border-radius: 0 0 4px 4px;
|
border-radius: 0 0 var(--border-radius) var(--border-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
text-expander .suggestions li:only-child {
|
text-expander .suggestions li:only-child {
|
||||||
border-radius: 4px;
|
border-radius: var(--border-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
text-expander .suggestions li:hover {
|
text-expander .suggestions li:hover {
|
||||||
|
|
|
@ -44,5 +44,5 @@
|
||||||
position: absolute !important;
|
position: absolute !important;
|
||||||
resize: none !important;
|
resize: none !important;
|
||||||
overflow: hidden !important;
|
overflow: hidden !important;
|
||||||
border-radius: 4px !important;
|
border-radius: var(--border-radius-medium) !important;
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
background: var(--color-console-bg);
|
background: var(--color-console-bg);
|
||||||
color: var(--color-console-fg);
|
color: var(--color-console-fg);
|
||||||
font-family: var(--fonts-monospace);
|
font-family: var(--fonts-monospace);
|
||||||
border-radius: 5px;
|
border-radius: var(--border-radius);
|
||||||
word-break: break-word;
|
word-break: break-word;
|
||||||
overflow-wrap: break-word;
|
overflow-wrap: break-word;
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
background: none;
|
background: none;
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
border-radius: 4px;
|
border-radius: var(--border-radius-medium);
|
||||||
min-height: 0;
|
min-height: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
.tribute-container {
|
.tribute-container {
|
||||||
box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.25);
|
box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.25);
|
||||||
border-radius: 0.25rem;
|
border-radius: var(--border-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
.tribute-container ul {
|
.tribute-container ul {
|
||||||
|
|
|
@ -221,7 +221,7 @@ textarea:focus,
|
||||||
}
|
}
|
||||||
.g-recaptcha-style iframe,
|
.g-recaptcha-style iframe,
|
||||||
.h-captcha-style iframe {
|
.h-captcha-style iframe {
|
||||||
border-radius: 5px !important;
|
border-radius: var(--border-radius) !important;
|
||||||
width: 302px !important;
|
width: 302px !important;
|
||||||
height: 76px !important;
|
height: 76px !important;
|
||||||
}
|
}
|
||||||
|
|
|
@ -180,7 +180,7 @@
|
||||||
appearance: none;
|
appearance: none;
|
||||||
position: relative;
|
position: relative;
|
||||||
border: 1px solid var(--color-secondary);
|
border: 1px solid var(--color-secondary);
|
||||||
border-radius: 2px;
|
border-radius: var(--border-radius);
|
||||||
background: var(--color-input-background);
|
background: var(--color-input-background);
|
||||||
height: 14px;
|
height: 14px;
|
||||||
width: 14px;
|
width: 14px;
|
||||||
|
@ -433,7 +433,7 @@
|
||||||
font-size: 85%;
|
font-size: 85%;
|
||||||
white-space: break-spaces;
|
white-space: break-spaces;
|
||||||
background-color: var(--color-markup-code-block);
|
background-color: var(--color-markup-code-block);
|
||||||
border-radius: 4px;
|
border-radius: var(--border-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
.markup code br,
|
.markup code br,
|
||||||
|
@ -466,7 +466,7 @@
|
||||||
font-size: 85%;
|
font-size: 85%;
|
||||||
line-height: 1.45;
|
line-height: 1.45;
|
||||||
background-color: var(--color-markup-code-block);
|
background-color: var(--color-markup-code-block);
|
||||||
border-radius: 4px;
|
border-radius: var(--border-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
.markup .highlight pre {
|
.markup .highlight pre {
|
||||||
|
@ -504,7 +504,7 @@
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
background-color: var(--color-markup-code-block);
|
background-color: var(--color-markup-code-block);
|
||||||
border: 1px solid var(--color-secondary);
|
border: 1px solid var(--color-secondary);
|
||||||
border-radius: 3px;
|
border-radius: var(--border-radius);
|
||||||
box-shadow: inset 0 -1px 0 var(--color-secondary);
|
box-shadow: inset 0 -1px 0 var(--color-secondary);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
border-width: 4px;
|
border-width: 4px;
|
||||||
border-style: solid;
|
border-style: solid;
|
||||||
border-color: var(--color-secondary) var(--color-secondary) var(--color-secondary-dark-8) var(--color-secondary-dark-8);
|
border-color: var(--color-secondary) var(--color-secondary) var(--color-secondary-dark-8) var(--color-secondary-dark-8);
|
||||||
border-radius: 100%;
|
border-radius: var(--border-radius-circle);
|
||||||
}
|
}
|
||||||
|
|
||||||
.is-loading.small-loading-icon::after {
|
.is-loading.small-loading-icon::after {
|
||||||
|
|
|
@ -134,7 +134,7 @@
|
||||||
top: -9px;
|
top: -9px;
|
||||||
min-width: 17px;
|
min-width: 17px;
|
||||||
min-height: 17px;
|
min-height: 17px;
|
||||||
border-radius: 17px;
|
border-radius: var(--border-radius-circle);
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
transition: all .2s ease;
|
transition: all .2s ease;
|
||||||
z-index: 500;
|
z-index: 500;
|
||||||
border-radius: 4px;
|
border-radius: var(--border-radius);
|
||||||
box-shadow: 0 8px 24px var(--color-shadow);
|
box-shadow: 0 8px 24px var(--color-shadow);
|
||||||
display: flex;
|
display: flex;
|
||||||
max-width: 50vw;
|
max-width: 50vw;
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
.toast-close,
|
.toast-close,
|
||||||
.toast-icon {
|
.toast-icon {
|
||||||
color: currentcolor;
|
color: currentcolor;
|
||||||
border-radius: 3px;
|
border-radius: var(--border-radius);
|
||||||
background: transparent;
|
background: transparent;
|
||||||
border: none;
|
border: none;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
|
|
@ -117,7 +117,7 @@
|
||||||
|
|
||||||
.repository .issue-content-right #deadlineForm input {
|
.repository .issue-content-right #deadlineForm input {
|
||||||
width: 12.8rem;
|
width: 12.8rem;
|
||||||
border-radius: 4px 0 0 4px;
|
border-radius: var(--border-radius) 0 0 var(--border-radius);
|
||||||
border-right: 0;
|
border-right: 0;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
@ -141,7 +141,7 @@
|
||||||
|
|
||||||
.repository .filter.menu.labels .label-filter .menu .info code {
|
.repository .filter.menu.labels .label-filter .menu .info code {
|
||||||
border: 1px solid var(--color-secondary);
|
border: 1px solid var(--color-secondary);
|
||||||
border-radius: 3px;
|
border-radius: var(--border-radius);
|
||||||
padding: 1px 2px;
|
padding: 1px 2px;
|
||||||
font-size: 11px;
|
font-size: 11px;
|
||||||
}
|
}
|
||||||
|
@ -518,7 +518,7 @@
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
border: 1px solid var(--color-secondary);
|
border: 1px solid var(--color-secondary);
|
||||||
background: var(--color-box-body);
|
background: var(--color-box-body);
|
||||||
border-radius: 3px;
|
border-radius: var(--border-radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
.repository.file.editor .commit-form-wrapper .commit-form::before,
|
.repository.file.editor .commit-form-wrapper .commit-form::before,
|
||||||
|
@ -551,7 +551,7 @@
|
||||||
font: 12px var(--fonts-monospace);
|
font: 12px var(--fonts-monospace);
|
||||||
color: var(--color-text);
|
color: var(--color-text);
|
||||||
background: var(--color-secondary);
|
background: var(--color-secondary);
|
||||||
border-radius: 3px;
|
border-radius: var(--border-radius);
|
||||||
margin: 0 2px;
|
margin: 0 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -709,7 +709,7 @@
|
||||||
align-items: center !important;
|
align-items: center !important;
|
||||||
font-size: 14px !important;
|
font-size: 14px !important;
|
||||||
padding: 7px 10px !important;
|
padding: 7px 10px !important;
|
||||||
border-radius: 6px !important;
|
border-radius: var(--border-radius-medium) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.issue-state-label .svg {
|
.issue-state-label .svg {
|
||||||
|
@ -835,7 +835,7 @@
|
||||||
width: 34px;
|
width: 34px;
|
||||||
height: 34px;
|
height: 34px;
|
||||||
background-color: var(--color-timeline);
|
background-color: var(--color-timeline);
|
||||||
border-radius: 50%;
|
border-radius: var(--border-radius-circle);
|
||||||
display: flex;
|
display: flex;
|
||||||
float: left;
|
float: left;
|
||||||
margin-left: -33px;
|
margin-left: -33px;
|
||||||
|
@ -1049,7 +1049,7 @@
|
||||||
|
|
||||||
.merge-section-info code {
|
.merge-section-info code {
|
||||||
border: 1px solid var(--color-light-border);
|
border: 1px solid var(--color-light-border);
|
||||||
border-radius: 4px;
|
border-radius: var(--border-radius);
|
||||||
padding: 2px 4px;
|
padding: 2px 4px;
|
||||||
background: var(--color-light);
|
background: var(--color-light);
|
||||||
}
|
}
|
||||||
|
@ -2093,7 +2093,7 @@
|
||||||
width: 34px;
|
width: 34px;
|
||||||
height: 34px;
|
height: 34px;
|
||||||
min-height: 0 !important;
|
min-height: 0 !important;
|
||||||
border-radius: 6px;
|
border-radius: var(--border-radius);
|
||||||
display: flex !important;
|
display: flex !important;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
@ -2753,7 +2753,7 @@ tbody.commit-list {
|
||||||
#new-dependency-drop-list.ui.selection.dropdown {
|
#new-dependency-drop-list.ui.selection.dropdown {
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border-radius: 4px 0 0 4px;
|
border-radius: var(--border-radius) 0 0 var(--border-radius);
|
||||||
border-right: 0;
|
border-right: 0;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
@ -2949,7 +2949,7 @@ tbody.commit-list {
|
||||||
margin: 10px 0;
|
margin: 10px 0;
|
||||||
background-color: var(--color-markup-code-block);
|
background-color: var(--color-markup-code-block);
|
||||||
border: 1px solid var(--color-secondary);
|
border: 1px solid var(--color-secondary);
|
||||||
border-radius: 3px;
|
border-radius: var(--border-radius);
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
line-height: 1.5;
|
line-height: 1.5;
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
|
|
||||||
#issue-list .flex-item-body .branches .branch {
|
#issue-list .flex-item-body .branches .branch {
|
||||||
background-color: var(--color-secondary-alpha-40);
|
background-color: var(--color-secondary-alpha-40);
|
||||||
border-radius: 3px;
|
border-radius: var(--border-radius);
|
||||||
padding: 0 4px;
|
padding: 0 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -55,7 +55,6 @@
|
||||||
width: 80px;
|
width: 80px;
|
||||||
height: 6px;
|
height: 6px;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
border-radius: 3px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#issue-list .flex-item-body .checklist progress::-webkit-progress-value {
|
#issue-list .flex-item-body .checklist progress::-webkit-progress-value {
|
||||||
|
|
|
@ -75,12 +75,10 @@
|
||||||
width: 10px;
|
width: 10px;
|
||||||
height: 10px;
|
height: 10px;
|
||||||
background-color: var(--color-secondary-dark-3);
|
background-color: var(--color-secondary-dark-3);
|
||||||
z-index: 9;
|
|
||||||
position: absolute;
|
position: absolute;
|
||||||
display: block;
|
|
||||||
left: -5.5px;
|
left: -5.5px;
|
||||||
top: 40px;
|
top: 40px;
|
||||||
border-radius: 100%;
|
border-radius: var(--border-radius-circle);
|
||||||
border: 2.5px solid var(--color-body);
|
border: 2.5px solid var(--color-body);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -273,7 +273,7 @@
|
||||||
border: 1px solid transparent;
|
border: 1px solid transparent;
|
||||||
padding: 4px 8px;
|
padding: 4px 8px;
|
||||||
margin: -8px 0; /* just like other buttons in the diff box header */
|
margin: -8px 0; /* just like other buttons in the diff box header */
|
||||||
border-radius: 0.285rem; /* just like .ui.tiny.button */
|
border-radius: var(--border-radius);
|
||||||
font-size: 0.857rem; /* just like .ui.tiny.button */
|
font-size: 0.857rem; /* just like .ui.tiny.button */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -107,7 +107,7 @@
|
||||||
|
|
||||||
#readme_profile {
|
#readme_profile {
|
||||||
padding: 1em 2em;
|
padding: 1em 2em;
|
||||||
border-radius: 0.28571429rem;
|
border-radius: var(--border-radius);
|
||||||
background: var(--color-card);
|
background: var(--color-card);
|
||||||
border: 1px solid var(--color-secondary);
|
border: 1px solid var(--color-secondary);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue