Difference between revisions of "MediaWiki:Gadget-calculator-core.css"
From WikiAnesthesia
Chris Rishel (talk | contribs) |
Chris Rishel (talk | contribs) |
||
Line 1: | Line 1: | ||
@mobile: ~"only screen and (max-width: 529px)"; | |||
@tablet: ~"only screen and (min-width: 530px) and (max-width: 949px)"; | |||
@desktop: ~"only screen and (min-width: 950px)"; | |||
@font-size: 0.875rem; | |||
.form-control-sm, .custom-select-sm { | .form-control-sm, .custom-select-sm { | ||
/* enlarge by 16/14 = 114.29% */ | |||
font-size: 16px; | font-size: 16px; | ||
/* scale down by 14/16 = 75% */ | |||
transform: scale(0.875); | transform: scale(0.875); | ||
transform-origin: left top; | transform-origin: left top; | ||
/* remove extra white space */ | |||
margin-right: -10%; | margin-right: -10%; | ||
} | } | ||
.calculator, .calculator-calculation { | .calculator, .calculator-calculation { | ||
font-size: | font-size: @font-size !important; | ||
} | } | ||
.calculator-calculation { | .calculator-calculation { | ||
background: #f9fcff; | background: #f9fcff; | ||
margin-bottom: 0.5rem; | margin-bottom: 0.5rem; | ||
.calculator-calculation-info { | |||
flex-direction: column; | |||
} | |||
.collapsing { | |||
-webkit-transition: none; | |||
transition: none; | |||
display: none; | |||
} | |||
.btn { | |||
font-size: inherit !important; | |||
} | |||
} | } | ||
.calculator-inputGroup { | .calculator-inputGroup { | ||
flex-wrap: nowrap; | flex-wrap: nowrap; | ||
margin: 0; | margin: 0; | ||
} | } | ||
.calculator-input-text { | |||
@media @mobile { | |||
padding-right: 0.5rem; | padding-right: 0.5rem; | ||
padding-left: 0.5rem; | padding-left: 0.5rem; | ||
} | } | ||
} | } | ||
.calculator-input-select { | |||
@media @mobile { | |||
padding-right: 1.5rem; | padding-right: 1.5rem; | ||
padding-left: 0.5rem; | padding-left: 0.5rem; | ||
} | } | ||
} | } | ||
.calculator-description-info { | .calculator-description-info { | ||
border-bottom: 1px solid #dee2e6; | border-bottom: 1px solid #dee2e6; | ||
padding: 0.5rem 0rem; | padding: 0.5rem 0rem; | ||
} | } | ||
.calculation-infobox { | |||
padding: 0; | |||
} | |||
@media (max-width: 767px) { | @media (max-width: 767px) { | ||
.calculator-hideLabelMobile { | .calculator-hideLabelMobile { | ||
Line 56: | Line 77: | ||
border: 0; | border: 0; | ||
padding: 0; | padding: 0; | ||
overflow: hidden | overflow: hidden | ||
} | } | ||
} | } | ||
.calculator-SimpleCalculation { | .calculator-SimpleCalculation { | ||
width: 100%; | width: 100%; | ||
max-width: 600px; | max-width: 600px; | ||
.row { | |||
width: 100%; | |||
} | } | ||
.calculator-calculation-title { | |||
background: rgba(0, 0, 0, 0.03); | |||
font-weight: 500; | |||
} | padding: 0.2rem 0.4rem; | ||
} | |||
.calculator-calculation-value { | |||
font-weight: 500; | |||
} | padding: 0.2rem 0.4rem; | ||
text-align: right; | |||
} | |||
.calculator-calculation-variables { | |||
padding: 0.4rem 1rem !important; | |||
} | |||
.form-group { | |||
margin-bottom: 0.5rem; | |||
} | } | ||
} | |||
.calculator-calculation-infoButton { | |||
float: right; | |||
} | |||
} | |||
.calculator-calculation-info { | |||
padding: 0.4rem 1rem !important; | |||
ol, ul { | |||
margin: 0 0 0 1rem; | |||
} | |||
} | |||
.calculator-calculation-formula { | |||
p { | |||
margin-bottom: 0; | |||
} | |||
} | |||
} | } |
Revision as of 23:08, 29 March 2022
@mobile: ~"only screen and (max-width: 529px)"; @tablet: ~"only screen and (min-width: 530px) and (max-width: 949px)"; @desktop: ~"only screen and (min-width: 950px)"; @font-size: 0.875rem; .form-control-sm, .custom-select-sm { /* enlarge by 16/14 = 114.29% */ font-size: 16px; /* scale down by 14/16 = 75% */ transform: scale(0.875); transform-origin: left top; /* remove extra white space */ margin-right: -10%; } .calculator, .calculator-calculation { font-size: @font-size !important; } .calculator-calculation { background: #f9fcff; margin-bottom: 0.5rem; .calculator-calculation-info { flex-direction: column; } .collapsing { -webkit-transition: none; transition: none; display: none; } .btn { font-size: inherit !important; } } .calculator-inputGroup { flex-wrap: nowrap; margin: 0; } .calculator-input-text { @media @mobile { padding-right: 0.5rem; padding-left: 0.5rem; } } .calculator-input-select { @media @mobile { padding-right: 1.5rem; padding-left: 0.5rem; } } .calculator-description-info { border-bottom: 1px solid #dee2e6; padding: 0.5rem 0rem; } .calculation-infobox { padding: 0; } @media (max-width: 767px) { .calculator-hideLabelMobile { display: block; position: absolute; clip: rect(1px,1px,1px,1px); width: 1px; height: 1px; margin: -1px; border: 0; padding: 0; overflow: hidden } } .calculator-SimpleCalculation { width: 100%; max-width: 600px; .row { width: 100%; } .calculator-calculation-title { background: rgba(0, 0, 0, 0.03); font-weight: 500; padding: 0.2rem 0.4rem; } .calculator-calculation-value { font-weight: 500; padding: 0.2rem 0.4rem; text-align: right; } .calculator-calculation-variables { padding: 0.4rem 1rem !important; .form-group { margin-bottom: 0.5rem; } } .calculator-calculation-infoButton { float: right; } .calculator-calculation-info { padding: 0.4rem 1rem !important; ol, ul { margin: 0 0 0 1rem; } } .calculator-calculation-formula { p { margin-bottom: 0; } } }