Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / web / core / modules / ckeditor / js / views / KeyboardView.es6.js
index 094f390cd0dfe0fab94129ace77a6972976b41d8..cf2ead9937b69a21ce67edd0b066e2ba713f9c4f 100644 (file)
                 }
                 // Wrap between rows.
                 else {
-                  $container.closest('.ckeditor-row').prev().find('.ckeditor-toolbar-group').not('.placeholder').find('.ckeditor-toolbar-group-buttons').eq(-1).append($button);
+                  $container
+                    .closest('.ckeditor-row')
+                    .prev()
+                    .find('.ckeditor-toolbar-group')
+                    .not('.placeholder')
+                    .find('.ckeditor-toolbar-group-buttons')
+                    .eq(-1)
+                    .append($button);
                 }
               }
             }
                   .off()
                   .remove();
                 // Focus on the first button in the active toolbar.
-                $activeButtons.find('.ckeditor-toolbar-group-buttons').eq(0).children().eq(0).children().trigger('focus');
+                $activeButtons
+                  .find('.ckeditor-toolbar-group-buttons')
+                  .eq(0)
+                  .children()
+                  .eq(0)
+                  .children()
+                  .trigger('focus');
               }
               // Otherwise, move it.
               else {
             // Wrap between rows. Insert the group before the placeholder group
             // at the end of the previous row.
             else {
-              $group.insertBefore($container.closest('.ckeditor-row').prev().find('.ckeditor-toolbar-groups').children().eq(-1));
+              const $rowChildElement = $container
+                .closest('.ckeditor-row')
+                .prev()
+                .find('.ckeditor-toolbar-groups')
+                .children()
+                .eq(-1);
+              $group.insertBefore($rowChildElement);
             }
           }
           // Move right between sibling groups.
         // Move groups between rows.
         else if (_.indexOf(upDownKeys, event.keyCode) > -1) {
           dir = (_.indexOf([38, 63232], event.keyCode) > -1) ? 'prev' : 'next';
-          $group.closest('.ckeditor-row')[dir]().find('.ckeditor-toolbar-groups').eq(0).prepend($group);
+          $group
+            .closest('.ckeditor-row')[dir]()
+            .find('.ckeditor-toolbar-groups')
+            .eq(0)
+            .prepend($group);
         }
 
         Drupal.ckeditor.registerGroupMove(this, $group);