mirror of
https://github.com/flarum/framework.git
synced 2025-05-28 11:05:41 +08:00
Major CSS revamp
- Get rid of Bootstrap (except we still rely on some JS) - Use BEM class names - Rework variables/theme config - Fix various bugs, including some on mobile The CSS is still not ideal – it needs to be cleaned up some more. But that can be a focus for after beta.
This commit is contained in:
42
less/lib/FormControl.less
Executable file
42
less/lib/FormControl.less
Executable file
@ -0,0 +1,42 @@
|
||||
.FormControl {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 36px;
|
||||
padding: 8px 13px;
|
||||
font-size: 13px;
|
||||
line-height: 1.5;
|
||||
color: @control-color;
|
||||
background-color: @control-bg;
|
||||
border: 2px solid transparent;
|
||||
border-radius: @border-radius;
|
||||
.transition(~"border-color .15s, background .15s");
|
||||
-webkit-appearance: none;
|
||||
|
||||
&:focus,
|
||||
&.focus {
|
||||
background-color: @body-bg;
|
||||
color: @text-color;
|
||||
border-color: @primary-color;
|
||||
outline: none;
|
||||
}
|
||||
|
||||
// Placeholder
|
||||
.placeholder(@control-color);
|
||||
|
||||
// Disabled and read-only inputs
|
||||
&[disabled],
|
||||
&[readonly],
|
||||
fieldset[disabled] & {
|
||||
// background-color: @input-bg-disabled;
|
||||
opacity: 1; // iOS fix for unreadable disabled content; see https://github.com/twbs/bootstrap/issues/11655
|
||||
}
|
||||
|
||||
&[disabled],
|
||||
fieldset[disabled] & {
|
||||
cursor: disallowed;
|
||||
}
|
||||
|
||||
textarea& {
|
||||
height: auto;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user