core/misc/dialog/off-canvas.css | 8 ++++---- core/misc/dialog/off-canvas.details.css | 2 +- core/misc/dialog/off-canvas.es6.js | 6 +++--- core/misc/dialog/off-canvas.form.css | 2 +- core/misc/dialog/off-canvas.js | 4 ++-- core/misc/dialog/off-canvas.table.css | 2 +- core/modules/outside_in/css/outside_in.motion.css | 2 +- .../system/templates/off-canvas-page-wrapper.html.twig | 10 +++++----- .../tests/src/FunctionalJavascript/OffCanvasTest.php | 2 +- .../tests/src/FunctionalJavascript/OffCanvasTestBase.php | 14 +++++++------- .../templates/content/off-canvas-page-wrapper.html.twig | 10 +++++----- 11 files changed, 31 insertions(+), 31 deletions(-) diff --git a/core/misc/dialog/off-canvas.css b/core/misc/dialog/off-canvas.css index 2f20771..52a8b9e 100644 --- a/core/misc/dialog/off-canvas.css +++ b/core/misc/dialog/off-canvas.css @@ -40,15 +40,15 @@ } /* - * Force the tray to be 100% width at the same breakpoint the dialog system uses - * to expand dialog widths. + * Force the off-canvas dialog to be 100% width at the same breakpoint the + * dialog system uses to expand dialog widths. */ @media all and (max-width: 48em) { /* 768px */ .ui-dialog.ui-dialog-off-canvas { width: 100% !important; } - /* When tray is at 100% width stop the body from scrolling */ - .js-tray-open { + /* When off-canvas dialog is at 100% width stop the body from scrolling */ + .js-off-canvas-dialog-open { height: 100%; overflow-y: hidden; } diff --git a/core/misc/dialog/off-canvas.details.css b/core/misc/dialog/off-canvas.details.css index 9495d62..fcd526f 100644 --- a/core/misc/dialog/off-canvas.details.css +++ b/core/misc/dialog/off-canvas.details.css @@ -1,6 +1,6 @@ /** * @file - * Visual styling for summary and details in the Settings Tray module's off-canvas dialog. + * Visual styling for summary and details in the off-canvas dialog. */ #drupal-off-canvas details, diff --git a/core/misc/dialog/off-canvas.es6.js b/core/misc/dialog/off-canvas.es6.js index 9273dfe..a82ff22 100644 --- a/core/misc/dialog/off-canvas.es6.js +++ b/core/misc/dialog/off-canvas.es6.js @@ -7,7 +7,7 @@ (function ($, Drupal, debounce, displace) { // The minimum width to use body displace needs to match the width at which - // the tray will be %100 width. @see outside_in.module.css + // the off-canvas dialog will be 100% width. @see core/misc/dialog/off-canvas.css const minDisplaceWidth = 768; /** @@ -132,7 +132,7 @@ }, 'dialog:beforecreate': function (event, dialog, $element, settings) { if ($element.is('#drupal-off-canvas')) { - $('body').addClass('js-tray-open'); + $('body').addClass('js-off-canvas-dialog-open'); // @see http://api.jqueryui.com/position/ settings.position = { my: 'left top', @@ -146,7 +146,7 @@ }, 'dialog:beforeclose': function (event, dialog, $element) { if ($element.is('#drupal-off-canvas')) { - $('body').removeClass('js-tray-open'); + $('body').removeClass('js-off-canvas-dialog-open'); // Remove all *.off-canvas events $(document).off('.off-canvas'); $(window).off('.off-canvas'); diff --git a/core/misc/dialog/off-canvas.form.css b/core/misc/dialog/off-canvas.form.css index f59400a..670778e 100644 --- a/core/misc/dialog/off-canvas.form.css +++ b/core/misc/dialog/off-canvas.form.css @@ -1,6 +1,6 @@ /** * @file - * Visual styling for forms in the Settings Tray module's off-canvas dialog. + * Visual styling for forms in the off-canvas dialog. */ #drupal-off-canvas form { diff --git a/core/misc/dialog/off-canvas.js b/core/misc/dialog/off-canvas.js index ceac21b..0e645b1 100644 --- a/core/misc/dialog/off-canvas.js +++ b/core/misc/dialog/off-canvas.js @@ -87,7 +87,7 @@ }, 'dialog:beforecreate': function dialogBeforecreate(event, dialog, $element, settings) { if ($element.is('#drupal-off-canvas')) { - $('body').addClass('js-tray-open'); + $('body').addClass('js-off-canvas-dialog-open'); settings.position = { my: 'left top', @@ -100,7 +100,7 @@ }, 'dialog:beforeclose': function dialogBeforeclose(event, dialog, $element) { if ($element.is('#drupal-off-canvas')) { - $('body').removeClass('js-tray-open'); + $('body').removeClass('js-off-canvas-dialog-open'); $(document).off('.off-canvas'); $(window).off('.off-canvas'); diff --git a/core/misc/dialog/off-canvas.table.css b/core/misc/dialog/off-canvas.table.css index fdc889e..7e7cd2e 100644 --- a/core/misc/dialog/off-canvas.table.css +++ b/core/misc/dialog/off-canvas.table.css @@ -1,6 +1,6 @@ /** * @file - * Visual styling for tables in the Settings Tray module's off-canvas dialog. + * Visual styling for tables in the off-canvas dialog. */ #drupal-off-canvas table * { diff --git a/core/modules/outside_in/css/outside_in.motion.css b/core/modules/outside_in/css/outside_in.motion.css index 4bdd236..620180a 100644 --- a/core/modules/outside_in/css/outside_in.motion.css +++ b/core/modules/outside_in/css/outside_in.motion.css @@ -16,7 +16,7 @@ /* Transition the editables on the page, their contextual links and their hover states. */ .dialog-off-canvas__main-canvas .contextual, .dialog-off-canvas__main-canvas .js-outside-in-edit-mode .outside-in-editable, -.dialog-off-canvas__main-canvas.js-tray-open .js-outside-in-edit-mode .outside-in-editable { +.dialog-off-canvas__main-canvas.js-off-canvas-dialog-open .js-outside-in-edit-mode .outside-in-editable { -webkit-transition: all .7s ease; -moz-transition: all .7s ease; transition: all .7s ease; diff --git a/core/modules/system/templates/off-canvas-page-wrapper.html.twig b/core/modules/system/templates/off-canvas-page-wrapper.html.twig index f448bfd..98b67ba 100644 --- a/core/modules/system/templates/off-canvas-page-wrapper.html.twig +++ b/core/modules/system/templates/off-canvas-page-wrapper.html.twig @@ -5,13 +5,13 @@ * * For consistent wrapping to {{ page }} render in all themes. The * "data-off-canvas-main-canvas" attribute is required by the off-canvas dialog. - * This is used by the core/drupal.off_canvas library to select the - * "main canvas" page element as opposed to the "off canvas" which is the tray + * This is used by the core/drupal.dialog.off_canvas library to select the + * "main canvas" page element as opposed to the "off canvas" which is the dialog * itself. The "main canvas" element must be resized according to the width of * the "off canvas" dialog so that no portion of the "main canvas" is obstructed - * by the tray. The tray can vary in width when opened and can be resized by the - * user. The "data-off-canvas-main-canvas" attribute cannot be removed without - * breaking the off-canvas dialog functionality. + * by the off-canvas dialog. The off-canvas dialog can vary in width when opened + * and can be resized by the user. The "data-off-canvas-main-canvas" attribute + * cannot be removed without breaking the off-canvas dialog functionality. * * Available variables: * - children: Contains the child elements of the page. diff --git a/core/modules/system/tests/src/FunctionalJavascript/OffCanvasTest.php b/core/modules/system/tests/src/FunctionalJavascript/OffCanvasTest.php index 240362b..80b1980 100644 --- a/core/modules/system/tests/src/FunctionalJavascript/OffCanvasTest.php +++ b/core/modules/system/tests/src/FunctionalJavascript/OffCanvasTest.php @@ -44,7 +44,7 @@ public function testOffCanvasLinks() { $web_assert->elementExists('css', '#drupal-off-canvas'); // Check that response text is on page. $web_assert->pageTextContains("Thing $link_index says hello"); - $off_canvas_tray = $this->getTray(); + $off_canvas_tray = $this->getOffCanvasDialog(); // Check that tray is visible. $this->assertEquals(TRUE, $off_canvas_tray->isVisible()); diff --git a/core/modules/system/tests/src/FunctionalJavascript/OffCanvasTestBase.php b/core/modules/system/tests/src/FunctionalJavascript/OffCanvasTestBase.php index 6ee6190..6b74b5e 100644 --- a/core/modules/system/tests/src/FunctionalJavascript/OffCanvasTestBase.php +++ b/core/modules/system/tests/src/FunctionalJavascript/OffCanvasTestBase.php @@ -15,8 +15,8 @@ protected function drupalGet($path, array $options = [], array $headers = []) { $return = parent::drupalGet($path, $options, $headers); - // After the page loaded we need to additionally wait until the settings - // tray Ajax activity is done. + // After the page loaded we need to additionally wait until the off-canvas + // dialog Ajax activity is done. $this->assertSession()->assertWaitOnAjaxRequest(); return $return; @@ -41,7 +41,7 @@ protected function enableTheme($theme) { */ protected function waitForOffCanvasToOpen() { $web_assert = $this->assertSession(); - // Wait just slightly longer than the tray CSS animation. + // Wait just slightly longer than the off-canvas dialog CSS animation. // @see core/misc/dialog/off-canvas.motion.css $this->getSession()->wait(800); $web_assert->assertWaitOnAjaxRequest(); @@ -60,10 +60,10 @@ protected function waitForOffCanvasToClose() { * * @return \Behat\Mink\Element\NodeElement|null */ - protected function getTray() { - $tray = $this->getSession()->getPage()->find('css', '.ui-dialog[aria-describedby="drupal-off-canvas"]'); - $this->assertEquals(FALSE, empty($tray), 'The tray was found.'); - return $tray; + protected function getOffCanvasDialog() { + $off_canvas_dialog = $this->getSession()->getPage()->find('css', '.ui-dialog[aria-describedby="drupal-off-canvas"]'); + $this->assertEquals(FALSE, empty($off_canvas_dialog), 'The off-canvas dialog was found.'); + return $off_canvas_dialog; } /** diff --git a/core/themes/stable/templates/content/off-canvas-page-wrapper.html.twig b/core/themes/stable/templates/content/off-canvas-page-wrapper.html.twig index 690371e..1199337 100644 --- a/core/themes/stable/templates/content/off-canvas-page-wrapper.html.twig +++ b/core/themes/stable/templates/content/off-canvas-page-wrapper.html.twig @@ -5,13 +5,13 @@ * * For consistent wrapping to {{ page }} render in all themes. The * "data-off-canvas-main-canvas" attribute is required by the off-canvas dialog. - * This is used by the core/drupal.off_canvas library to select the - * "main canvas" page element as opposed to the "off canvas" which is the tray + * This is used by the core/drupal.dialog.off_canvas library to select the + * "main canvas" page element as opposed to the "off canvas" which is the dialog * itself. The "main canvas" element must be resized according to the width of * the "off canvas" dialog so that no portion of the "main canvas" is obstructed - * by the tray. The tray can vary in width when opened and can be resized by the - * user. The "data-off-canvas-main-canvas" attribute cannot be removed without - * breaking the off-canvas dialog functionality. + * by the off-canvas dialog. The off-canvas dialog can vary in width when opened + * and can be resized by the user. The "data-off-canvas-main-canvas" attribute + * cannot be removed without breaking the off-canvas dialog functionality. * * Available variables: * - children: Contains the child elements of the page.