diff --git a/core/modules/book/book.libraries.yml b/core/modules/book/book.libraries.yml index 8923101..2382e75 100644 --- a/core/modules/book/book.libraries.yml +++ b/core/modules/book/book.libraries.yml @@ -11,8 +11,7 @@ navigation: version: VERSION css: theme: - css/components/navigation.css: {} - css/components/pager.css: {} + css/book.theme.css: {} admin: version: VERSION diff --git a/core/modules/book/book.module b/core/modules/book/book.module index 5497a0a..6368a73 100644 --- a/core/modules/book/book.module +++ b/core/modules/book/book.module @@ -163,6 +163,11 @@ function book_form_node_form_alter(&$form, FormStateInterface $form_state, $form 'book/admin', ], ], + '#attributes' => array( + 'class' => array( + 'js-hide', + ), + ), ); $form['#entity_builders'][] = 'book_node_builder'; } diff --git a/core/modules/book/css/book.admin.css b/core/modules/book/css/book.admin.css deleted file mode 100644 index 1059aad..0000000 --- a/core/modules/book/css/book.admin.css +++ /dev/null @@ -1,11 +0,0 @@ -/** - * @file - * Administration styles for the Book module. - */ - -/** - * Book outline on book edit form. - */ -.js .book-outline-form .form-submit { - display: none; -} diff --git a/core/modules/book/css/book.theme.css b/core/modules/book/css/book.theme.css new file mode 100644 index 0000000..8f1f7de --- /dev/null +++ b/core/modules/book/css/book.theme.css @@ -0,0 +1,40 @@ +/** + * @file + * Styling for the Book module. + */ + +.book-navigation .menu { + padding-bottom: 0; + padding-top: 1em; +} +.book-navigation .book-pager { + margin: 0; + overflow: auto; + padding: 0.5em 0; +} +.book-pager__item { + display: inline-block; + list-style-type: none; + vertical-align: top; +} +.book-pager__item--previous { + text-align: left; /* LTR */ + width: 45%; +} +[dir="rtl"] .book-pager__item--previous { + float: right; + text-align: right; +} +.book-pager__item--center { + text-align: center; + width: 8%; +} +.book-pager__item--next { + float: right; /* LTR */ + text-align: right; /* LTR */ + width: 45%; +} +[dir="rtl"] .book-pager__item--next { + float: left; + text-align: left; +} diff --git a/core/modules/book/css/components/navigation.css b/core/modules/book/css/components/navigation.css deleted file mode 100644 index 2684a4d..0000000 --- a/core/modules/book/css/components/navigation.css +++ /dev/null @@ -1,9 +0,0 @@ -/** - * @file - * Styling for the book module navigation. - */ - -.book-navigation .menu { - padding-bottom: 0; - padding-top: 1em; -} diff --git a/core/modules/book/css/components/pager.css b/core/modules/book/css/components/pager.css deleted file mode 100644 index d0a88dd..0000000 --- a/core/modules/book/css/components/pager.css +++ /dev/null @@ -1,36 +0,0 @@ -/** - * @file - * Styling for the book module navigation. - */ - -.book-navigation .book-pager { - margin: 0; - overflow: auto; - padding: 0.5em 0; -} -.book-pager__item { - display: inline-block; - list-style-type: none; - vertical-align: top; -} -.book-pager__item--previous { - text-align: left; /* LTR */ - width: 45%; -} -[dir="rtl"] .book-pager__item--previous { - float: right; - text-align: right; -} -.book-pager__item--center { - text-align: center; - width: 8%; -} -.book-pager__item--next { - float: right; /* LTR */ - text-align: right; /* LTR */ - width: 45%; -} -[dir="rtl"] .book-pager__item--next { - float: left; - text-align: left; -}