Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix media query edge case #13546

Merged
merged 13 commits into from
Nov 17, 2020
8 changes: 4 additions & 4 deletions web_src/less/_admin.less
Original file line number Diff line number Diff line change
Expand Up @@ -88,16 +88,16 @@

#notice-table {
.notice-description {
@media only screen and (max-width: 767px) {
@media @mediaSm {
max-width: 80vw;
}
@media only screen and (max-width: 991px) and (min-width: 768px) {
@media @mediaMd {
max-width: 360px;
}
@media only screen and (min-width: 992px) and (max-width: 1199.98px) {
@media @mediaLg {
max-width: 510px;
}
@media only screen and (min-width: 1200px) {
@media @mediaXl {
max-width: 640px;
}
}
Expand Down
14 changes: 7 additions & 7 deletions web_src/less/_base.less
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ a:hover,
margin-right: 0 !important;
}

@media only screen and (max-width: 767px) {
@media @mediaSm {
#navbar:not(.shown) > *:not(:first-child) {
display: none;
}
Expand Down Expand Up @@ -774,7 +774,7 @@ a:hover,
}

&.pagination.menu {
@media only screen and (max-width: 767px) {
@media @mediaSm {
.item:not(.active):not(.navigation),
.item.navigation span.navigation_label {
display: none;
Expand Down Expand Up @@ -900,7 +900,7 @@ footer {
}

// Conditional display
@media only screen and (min-width: 768px) {
@media @mediaMdAndUp {
.mobile-only,
.ui.button.mobile-only {
display: none;
Expand All @@ -913,7 +913,7 @@ footer {
}
}

@media only screen and (max-width: 767px) {
@media @mediaSm {
.not-mobile {
display: none;
}
Expand Down Expand Up @@ -941,7 +941,7 @@ footer {
clip: auto;
}

@media only screen and (max-width: 991px) and (min-width: 768px) {
@media @mediaMd {
.ui.container {
width: 95%;
}
Expand All @@ -956,7 +956,7 @@ footer {
border-width: 1px !important;
}

@media only screen and (max-width: 1200px) {
@media @mediaLgAndDown {
.ui.menu.new-menu {
overflow-x: auto !important;
justify-content: left !important;
Expand Down Expand Up @@ -1398,7 +1398,7 @@ table th[data-sortt-desc] {
}

.dropdown:not(.selection) > .menu.review-box > * {
@media only screen and (max-height: 700px) {
@media (max-height: 700px) {
.CodeMirror,
.CodeMirror-scroll {
min-height: 100px;
Expand Down
4 changes: 2 additions & 2 deletions web_src/less/_dashboard.less
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
left: 90%;
width: 15%;

@media only screen and (max-width: 768px) {
@media @mediaSm {
top: 10px;
left: auto;
width: auto;
Expand All @@ -55,7 +55,7 @@
left: auto !important;
}

@media only screen and (max-width: 768px) {
@media @mediaSm {
width: 100%;
}
}
Expand Down
18 changes: 9 additions & 9 deletions web_src/less/_form.less
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ textarea:focus,
text-align: center;
}

@media only screen and (min-width: 768px) {
@media @mediaMdAndUp {
width: 800px !important;

.header {
Expand All @@ -169,7 +169,7 @@ textarea:focus,
}
}

@media only screen and (max-width: 767px) {
@media @mediaSm {
.optional .title {
margin-left: 15px;
}
Expand Down Expand Up @@ -211,7 +211,7 @@ textarea:focus,
}
}

@media only screen and (min-width: 768px) {
@media @mediaMdAndUp {
.g-recaptcha,
.h-captcha {
margin: 0 auto !important;
Expand All @@ -220,7 +220,7 @@ textarea:focus,
}
}

@media screen and (max-height: 575px) {
@media (max-height: 575px) {
#rc-imageselect,
.g-recaptcha,
.h-captcha {
Expand Down Expand Up @@ -252,7 +252,7 @@ textarea:focus,

.inline.field > label,
input {
@media only screen and (max-width: 768px) {
@media @mediaSm {
width: 100% !important;
}
}
Expand Down Expand Up @@ -290,7 +290,7 @@ textarea:focus,
width: 50% !important;
}

@media only screen and (max-width: 768px) {
@media @mediaSm {
label,
input,
.selection.dropdown {
Expand All @@ -308,7 +308,7 @@ textarea:focus,

&.new.repo {
.ui.form {
@media only screen and (min-width: 768px) {
@media @mediaMdAndUp {
#auto-init {
margin-left: @create-page-form-input-padding+15px;
}
Expand All @@ -317,7 +317,7 @@ textarea:focus,
.selection.dropdown:not(.owner) {
width: 50% !important;

@media only screen and (max-width: 768px) {
@media @mediaSm {
width: 100% !important;
}
}
Expand Down Expand Up @@ -346,7 +346,7 @@ textarea:focus,
}

.new.org .ui.form {
@media only screen and (max-width: 768px) {
@media @mediaSm {
.field button,
.field a {
margin-bottom: 1em;
Expand Down
6 changes: 3 additions & 3 deletions web_src/less/_home.less
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
}

.hero {
@media only screen and (max-width: 767px) {
@media @mediaSm {
h1 {
font-size: 3.5em;
}
Expand All @@ -14,7 +14,7 @@
}
}

@media only screen and (min-width: 768px) {
@media @mediaMdAndUp {
h1 {
font-size: 5.5em;
}
Expand Down Expand Up @@ -52,7 +52,7 @@
footer {
.ui.container .left,
.ui.container .right {
@media only screen and (max-width: 880px) {
@media (max-width: 880px) {
display: block;
text-align: center;
float: none;
Expand Down
30 changes: 15 additions & 15 deletions web_src/less/_repository.less
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@
text-overflow: ellipsis;
}

@media (max-width: 1200px) {
@media @mediaLgAndDown {
.title {
max-width: 150px;
}
Expand Down Expand Up @@ -216,7 +216,7 @@
#clone-panel {
width: 350px;

@media only screen and (max-width: 768px) {
@media @mediaSm {
width: 100%;
}

Expand Down Expand Up @@ -279,7 +279,7 @@
}

.ui.tiny.blue.buttons {
@media only screen and (max-width: 768px) {
@media @mediaSm {
width: 100%;
}
}
Expand Down Expand Up @@ -629,7 +629,7 @@
width: 100%;
}

@media only screen and (max-width: 768px) {
@media @mediaSm {
flex-direction: column;

h1 {
Expand Down Expand Up @@ -1025,7 +1025,7 @@
}
}

@media only screen and (max-width: 767px) {
@media @mediaSm {
.form .button {
width: 100%;

Expand Down Expand Up @@ -1578,7 +1578,7 @@
background: #ffffff;
line-height: 30px;

@media only screen and (max-width: 992px) {
@media @mediaMdAndDown {
flex-direction: column;
align-items: flex-start;
}
Expand Down Expand Up @@ -2019,13 +2019,13 @@

button,
input {
@media only screen and (max-width: 438px) {
@media (max-width: 438px) {
width: 100%;
}
}

button {
@media only screen and (max-width: 768px) {
@media @mediaSm {
margin-bottom: 1em;
}
}
Expand Down Expand Up @@ -2110,7 +2110,7 @@
}
}

@media only screen and (max-width: 767px) {
@media @mediaSm {
.dividing.header .stackable.grid .button {
margin-top: 2px;
margin-bottom: 2px;
Expand Down Expand Up @@ -3002,7 +3002,7 @@ tbody.commit-list {
vertical-align: middle;
}

@media only screen and (max-width: 767.98px) {
@media @mediaSm {
tr.commit-list {
width: 100%;
}
Expand All @@ -3012,7 +3012,7 @@ tbody.commit-list {
}
}

@media only screen and (min-width: 768px) and (max-width: 991.98px) {
@media @mediaMd {
tr.commit-list {
width: 723px;
}
Expand All @@ -3021,7 +3021,7 @@ tbody.commit-list {
}
}

@media only screen and (min-width: 992px) and (max-width: 1199.98px) {
@media @mediaLg {
tr.commit-list {
width: 933px;
}
Expand All @@ -3030,7 +3030,7 @@ tbody.commit-list {
}
}

@media only screen and (min-width: 1200px) {
@media @mediaXl {
tr.commit-list {
width: 1127px;
}
Expand Down Expand Up @@ -3076,7 +3076,7 @@ tbody.commit-list {
}
}

@media only screen and (max-width: 767px) {
@media @mediaSm {
.ui.stackable.menu {
&.mobile--margin-between-items > .item {
margin-top: 5px;
Expand Down Expand Up @@ -3336,7 +3336,7 @@ td.blob-excerpt {
.repository .ui.menu.new-menu {
background: none !important;

@media only screen and (max-width: 1200px) {
@media @mediaLgAndDown {
&::after {
background: none !important;
}
Expand Down
10 changes: 6 additions & 4 deletions web_src/less/_review.less
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@import "variables.less";

.ui.button.add-code-comment {
padding: 2px;
position: absolute;
Expand Down Expand Up @@ -146,7 +148,7 @@ a.blob-excerpt:hover {
margin-left: .5rem;
}

@media only screen and (max-width: 768px) {
@media @mediaSm {
#review-box > .menu {
> .ui.segment {
width: 94vw;
Expand All @@ -161,19 +163,19 @@ a.blob-excerpt:hover {
}
}

@media only screen and (min-width: 768px) and (max-width: 992px) {
@media @mediaMd {
#review-box .CodeMirror-scroll {
max-width: 700px;
}
}

@media only screen and (min-width: 992px) and (max-width: 1200px) {
@media @mediaLg {
#review-box .CodeMirror-scroll {
max-width: 800px;
}
}

@media only screen and (min-width: 1200px) {
@media @mediaXl {
#review-box .CodeMirror-scroll {
max-width: 900px;
}
Expand Down
Loading