Commit 4b72c960 authored by alexpott's avatar alexpott

Issue #1839318 by JohnAlbin, echoz: Added Replace drupal.base.css library with...

Issue #1839318 by JohnAlbin, echoz: Added Replace drupal.base.css library with normalize.css for all themes.
parent 909533e7
...@@ -95,7 +95,7 @@ function _drupal_maintenance_theme() { ...@@ -95,7 +95,7 @@ function _drupal_maintenance_theme() {
// These CSS files are normally added by system_page_build(), except // These CSS files are normally added by system_page_build(), except
// system.maintenance.css. When the database is inactive, it's not called so // system.maintenance.css. When the database is inactive, it's not called so
// we add them here. // we add them here.
drupal_add_library('system', 'drupal.base'); drupal_add_library('system', 'normalize');
} }
/** /**
......
/**
* @file
* Provides a base styling for HTML elements in Drupal.
*/
/**
* Block-level HTML5 display definition.
*
* Provides display values for browsers that don't recognize the new elements
* and therefore display them inline by default.
*/
article,
aside,
details,
figcaption,
figure,
footer,
header,
main,
nav,
section,
summary {
display: block;
}
/**
* Form elements.
*/
form {
margin: 0;
padding: 0;
}
fieldset {
border: 1px solid #ccc;
margin: 1em 0;
padding: 0.5em;
}
label {
display: block;
font-weight: bold;
}
input {
/* Keep form elements from overflowing their containers. */
max-width: 100%;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
/**
* Table elements.
*/
table {
border-collapse: collapse;
width: 100%;
}
caption {
text-align: left; /* LTR */
}
[dir="rtl"] caption {
text-align: right;
}
th {
padding-right: 1em; /* LTR */
text-align: left; /* LTR */
}
[dir="rtl"] th {
text-align: right;
padding-left: 1em;
padding-right: 0;
}
thead > tr {
border-bottom: 1px solid #000;
}
tr {
border-bottom: 1px solid #ccc;
padding: 0.1em 0.6em;
}
/**
* Miscellaneous elements.
*/
hr {
border: 1px solid gray;
height: 1px;
}
img {
border: 0;
}
...@@ -77,10 +77,6 @@ h4.label { ...@@ -77,10 +77,6 @@ h4.label {
.form-type-checkbox .description { .form-type-checkbox .description {
margin-left: 2.4em; margin-left: 2.4em;
} }
input.form-checkbox,
input.form-radio {
vertical-align: middle;
}
.marker, .marker,
.form-required { .form-required {
color: #e00; color: #e00;
......
...@@ -1353,18 +1353,6 @@ function system_library_info() { ...@@ -1353,18 +1353,6 @@ function system_library_info() {
), ),
); );
// Drupal's base CSS.
$libraries['drupal.base'] = array(
'title' => 'Drupal base CSS',
'version' => \Drupal::VERSION,
'css' => array(
'core/misc/drupal.base.css' => array(
'every_page' => TRUE,
'weight' => CSS_BASE - 10,
),
),
);
// jQuery UI. // jQuery UI.
$libraries['jquery.ui.core'] = array( $libraries['jquery.ui.core'] = array(
'title' => 'jQuery UI: Core', 'title' => 'jQuery UI: Core',
...@@ -2170,7 +2158,7 @@ function system_filetransfer_info() { ...@@ -2170,7 +2158,7 @@ function system_filetransfer_info() {
*/ */
function system_page_build(&$page) { function system_page_build(&$page) {
// Note: ensure the same CSS is loaded in _drupal_maintenance_theme(). // Note: ensure the same CSS is loaded in _drupal_maintenance_theme().
$page['#attached']['library'][] = array('system', 'drupal.base'); $page['#attached']['library'][] = array('system', 'normalize');
$path = drupal_get_path('module', 'system'); $path = drupal_get_path('module', 'system');
// Adjust the weights to load these early. // Adjust the weights to load these early.
$page['#attached']['css'][$path . '/css/system.module.css'] = array('weight' => CSS_COMPONENT - 10, 'every_page' => TRUE); $page['#attached']['css'][$path . '/css/system.module.css'] = array('weight' => CSS_COMPONENT - 10, 'every_page' => TRUE);
......
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
} }
input.password-confirm, input.password-confirm,
input.password-field { input.password-field {
width: 16em; width: 13.7em;
margin-bottom: 0.4em; margin-bottom: 0.4em;
} }
div.password-confirm { div.password-confirm {
...@@ -63,7 +63,7 @@ div.password-confirm { ...@@ -63,7 +63,7 @@ div.password-confirm {
div.form-item div.password-suggestions { div.form-item div.password-suggestions {
padding: 0.2em 0.5em; padding: 0.2em 0.5em;
margin: 0.7em 0; margin: 0.7em 0;
width: 38.5em; max-width: 34.7em;
border: 1px solid #b4b4b4; border: 1px solid #b4b4b4;
} }
div.password-suggestions ul { div.password-suggestions ul {
...@@ -73,7 +73,7 @@ div.password-suggestions ul { ...@@ -73,7 +73,7 @@ div.password-suggestions ul {
.password-parent { .password-parent {
clear: left; /* LTR */ clear: left; /* LTR */
margin: 0; margin: 0;
width: 36.3em; max-width: 33em;
} }
[dir="rtl"] .confirm-parent, [dir="rtl"] .confirm-parent,
[dir="rtl"] .password-parent { [dir="rtl"] .password-parent {
...@@ -88,6 +88,7 @@ div.password-suggestions ul { ...@@ -88,6 +88,7 @@ div.password-suggestions ul {
div.password-confirm { div.password-confirm {
float: none; float: none;
width: auto; width: auto;
max-width: 100%;
} }
.password-indicator { .password-indicator {
margin-bottom: 0.4em; margin-bottom: 0.4em;
...@@ -96,13 +97,16 @@ div.password-suggestions ul { ...@@ -96,13 +97,16 @@ div.password-suggestions ul {
input.password-field { input.password-field {
margin-bottom: 0; margin-bottom: 0;
width: 100%; width: 100%;
max-width: none;
} }
div.form-item div.password-suggestions { div.form-item div.password-suggestions {
width: auto; width: auto;
max-width: 100%;
} }
.confirm-parent, .confirm-parent,
.password-parent { .password-parent {
clear: none; clear: none;
width: 100%; width: 100%;
max-width: none;
} }
} }
...@@ -43,9 +43,6 @@ p { ...@@ -43,9 +43,6 @@ p {
del { del {
text-decoration: line-through; text-decoration: line-through;
} }
tr.odd {
background-color: #dddddd;
}
img { img {
outline: 0; outline: 0;
} }
...@@ -202,6 +199,19 @@ table table { ...@@ -202,6 +199,19 @@ table table {
#footer-wrapper table { #footer-wrapper table {
font-size: 1em; font-size: 1em;
} }
tr {
border-bottom: 1px solid #ccc;
padding: 0.1em 0.6em;
background: #efefef;
background: rgba(0, 0, 0, 0.063);
}
thead > tr {
border-bottom: 1px solid #000;
}
tr.odd {
background: #e4e4e4;
background: rgba(0, 0, 0, 0.105);
}
table tr th { table tr th {
background: #757575; background: #757575;
background: rgba(0, 0, 0, 0.51); background: rgba(0, 0, 0, 0.51);
...@@ -231,15 +241,6 @@ tr th { ...@@ -231,15 +241,6 @@ tr th {
border-color: #555; border-color: #555;
border-color: rgba(255, 255, 255, 0.18); border-color: rgba(255, 255, 255, 0.18);
} }
tr.odd {
background: #e4e4e4;
background: rgba(0, 0, 0, 0.105);
}
tr,
tr.even {
background: #efefef;
background: rgba(0, 0, 0, 0.063);
}
table ul.links { table ul.links {
margin: 0; margin: 0;
padding: 0; padding: 0;
...@@ -1274,6 +1275,13 @@ div.password-confirm { ...@@ -1274,6 +1275,13 @@ div.password-confirm {
/* -------------- Form Elements ------------- */ /* -------------- Form Elements ------------- */
form {
margin: 0;
padding: 0;
}
fieldset {
margin: 1em 0;
}
details, details,
fieldset, fieldset,
.filter-wrapper { .filter-wrapper {
...@@ -1305,9 +1313,18 @@ details summary a:active { ...@@ -1305,9 +1313,18 @@ details summary a:active {
details .details-description { details .details-description {
font-style: italic; font-style: italic;
} }
label {
display: block;
font-weight: bold;
}
input { input {
margin: 2px 0; margin: 2px 0;
padding: 4px; padding: 4px;
/* Keep form elements from overflowing their containers. */
max-width: 100%;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
} }
input, input,
textarea { textarea {
......
...@@ -30,25 +30,6 @@ function seven_library_info() { ...@@ -30,25 +30,6 @@ function seven_library_info() {
return $libraries; return $libraries;
} }
/**
* Implements hook_preprocess_HOOK() for maintenance-page.html.twig.
*/
function seven_preprocess_maintenance_page(&$variables) {
// While markup for normal pages is split into page.tpl.php and html.tpl.php,
// the markup for the maintenance page is all in the single
// maintenance-page.html.twig template. So, to have what's done in
// seven_preprocess_html() also happen on the maintenance page, it has to be
// called here.
seven_preprocess_html($variables);
}
/**
* Implements hook_preprocess_HOOK() for html.tpl.php.
*/
function seven_preprocess_html(&$variables) {
drupal_add_library('system', 'normalize');
}
/** /**
* Implements hook_preprocess_HOOK() for page.tpl.php. * Implements hook_preprocess_HOOK() for page.tpl.php.
*/ */
......
...@@ -500,6 +500,12 @@ table { ...@@ -500,6 +500,12 @@ table {
margin: 0 0 10px; margin: 0 0 10px;
font-size: 0.923em; font-size: 0.923em;
} }
caption {
text-align: left; /* LTR */
}
[dir="rtl"] caption {
text-align: right;
}
th { th {
padding: 10px 12px; padding: 10px 12px;
background: #f5f5f2; background: #f5f5f2;
...@@ -512,8 +518,12 @@ th { ...@@ -512,8 +518,12 @@ th {
[dir="rtl"] th { [dir="rtl"] th {
text-align: right; text-align: right;
} }
tbody tr { tr {
border-bottom: 1px solid #e6e4df; border-bottom: 1px solid #e6e4df;
padding: 0.1em 0.6em;
}
thead > tr {
border-bottom: 1px solid #000;
} }
tbody tr:hover { tbody tr:hover {
background: #f7fcff; background: #f7fcff;
...@@ -649,15 +659,24 @@ details summary { ...@@ -649,15 +659,24 @@ details summary {
/** /**
* Form elements. * Form elements.
*/ */
form {
margin: 0;
padding: 0;
}
fieldset {
margin: 1em 0;
}
.form-item { .form-item {
margin: 1em 0; margin: 1em 0;
} }
.form-type-checkbox { .form-type-checkbox {
padding: 0; padding: 0;
} }
.form-item label { label {
display: block;
margin: 0; margin: 0;
padding: 0; padding: 0;
font-weight: bold;
} }
.form-item label.option { .form-item label.option {
font-size: 0.923em; font-size: 0.923em;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment