From a8040cb36f85ff14d9754f68d9149ae3e88bc0e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maciej=20Go=C5=82aszewski?= Date: Fri, 21 Feb 2020 13:08:23 +0100 Subject: [PATCH] Fix dangling comma. --- src/button/buttonview.js | 4 +-- src/button/switchbuttonview.js | 4 +-- src/colorgrid/colorgridview.js | 2 +- src/dropdown/dropdownview.js | 2 +- src/editorui/bodycollection.js | 2 +- src/list/listview.js | 2 +- src/panel/balloon/balloonpanelview.js | 2 +- src/panel/balloon/contextualballoon.js | 2 +- src/panel/sticky/stickypanelview.js | 2 +- src/toolbar/block/blockbuttonview.js | 2 +- src/toolbar/toolbarview.js | 4 +-- src/tooltip/tooltipview.js | 2 +- tests/_utils-tests/utils.js | 4 +-- tests/focuscycler.js | 2 +- tests/manual/tickets/228/1.js | 2 +- tests/panel/balloon/contextualballoon.js | 4 +-- tests/panel/sticky/stickypanelview.js | 4 +-- tests/template.js | 40 ++++++++++++------------ 18 files changed, 43 insertions(+), 43 deletions(-) diff --git a/src/button/buttonview.js b/src/button/buttonview.js index 039586cd..ebab8bc0 100644 --- a/src/button/buttonview.js +++ b/src/button/buttonview.js @@ -139,7 +139,7 @@ export default class ButtonView extends View { bind.if( 'isVisible', 'ck-hidden', value => !value ), bind.to( 'isOn', value => value ? 'ck-on' : 'ck-off' ), bind.if( 'withText', 'ck-button_with-text' ), - bind.if( 'withKeystroke', 'ck-button_with-keystroke' ), + bind.if( 'withKeystroke', 'ck-button_with-keystroke' ) ], type: bind.to( 'type', value => value ? value : 'button' ), tabindex: bind.to( 'tabindex' ), @@ -232,7 +232,7 @@ export default class ButtonView extends View { 'ck-button__label' ], style: bind.to( 'labelStyle' ), - id: `ck-editor__aria-label_${ ariaLabelUid }`, + id: `ck-editor__aria-label_${ ariaLabelUid }` }, children: [ diff --git a/src/button/switchbuttonview.js b/src/button/switchbuttonview.js index 45a4bf0d..aaafd2a3 100644 --- a/src/button/switchbuttonview.js +++ b/src/button/switchbuttonview.js @@ -77,7 +77,7 @@ export default class SwitchButtonView extends ButtonView { class: [ 'ck', 'ck-button__toggle' - ], + ] }, children: [ @@ -88,7 +88,7 @@ export default class SwitchButtonView extends ButtonView { class: [ 'ck', 'ck-button__toggle__inner' - ], + ] } } ] diff --git a/src/colorgrid/colorgridview.js b/src/colorgrid/colorgridview.js index 7f9c3d5c..5865ec03 100644 --- a/src/colorgrid/colorgridview.js +++ b/src/colorgrid/colorgridview.js @@ -87,7 +87,7 @@ export default class ColorGridView extends View { focusPrevious: 'arrowleft', // Navigate grid items forwards using the arrowdown key. - focusNext: 'arrowright', + focusNext: 'arrowright' } } ); diff --git a/src/dropdown/dropdownview.js b/src/dropdown/dropdownview.js index 1d45063a..f651e02c 100644 --- a/src/dropdown/dropdownview.js +++ b/src/dropdown/dropdownview.js @@ -198,7 +198,7 @@ export default class DropdownView extends View { buttonView.extendTemplate( { attributes: { class: [ - 'ck-dropdown__button', + 'ck-dropdown__button' ] } } ); diff --git a/src/editorui/bodycollection.js b/src/editorui/bodycollection.js index 521a0286..8e4c218f 100644 --- a/src/editorui/bodycollection.js +++ b/src/editorui/bodycollection.js @@ -53,7 +53,7 @@ export default class BodyCollection extends ViewCollection { 'ck-body', 'ck-rounded-corners' ], - dir: this.locale.uiLanguageDirection, + dir: this.locale.uiLanguageDirection }, children: this } ).render(); diff --git a/src/list/listview.js b/src/list/listview.js index 0909fa81..0b05a0f8 100644 --- a/src/list/listview.js +++ b/src/list/listview.js @@ -67,7 +67,7 @@ export default class ListView extends View { focusPrevious: 'arrowup', // Navigate toolbar items forwards using the arrowdown key. - focusNext: 'arrowdown', + focusNext: 'arrowdown' } } ); diff --git a/src/panel/balloon/balloonpanelview.js b/src/panel/balloon/balloonpanelview.js index 8d04bd78..bbd17f56 100644 --- a/src/panel/balloon/balloonpanelview.js +++ b/src/panel/balloon/balloonpanelview.js @@ -719,7 +719,7 @@ BalloonPanelView.defaultPositions = { top: getSouthTop( targetRect, balloonRect ), left: targetRect.right - BalloonPanelView.arrowHorizontalOffset, name: 'arrow_nw' - } ), + } ) }; // Returns the top coordinate for positions starting with `north*`. diff --git a/src/panel/balloon/contextualballoon.js b/src/panel/balloon/contextualballoon.js index de6a43c7..0d19a50d 100644 --- a/src/panel/balloon/contextualballoon.js +++ b/src/panel/balloon/contextualballoon.js @@ -597,7 +597,7 @@ class RotatorView extends View { } ] }, - this.buttonNextView, + this.buttonNextView ] }, { diff --git a/src/panel/sticky/stickypanelview.js b/src/panel/sticky/stickypanelview.js index 4d027b2f..17ddb893 100644 --- a/src/panel/sticky/stickypanelview.js +++ b/src/panel/sticky/stickypanelview.js @@ -182,7 +182,7 @@ export default class StickyPanelView extends View { 'ck-sticky-panel__content', // Toggle class of the panel when "sticky" state changes in the view. bind.if( 'isSticky', 'ck-sticky-panel__content_sticky' ), - bind.if( '_isStickyToTheLimiter', 'ck-sticky-panel__content_sticky_bottom-limit' ), + bind.if( '_isStickyToTheLimiter', 'ck-sticky-panel__content_sticky_bottom-limit' ) ], style: { width: bind.to( 'isSticky', isSticky => { diff --git a/src/toolbar/block/blockbuttonview.js b/src/toolbar/block/blockbuttonview.js index 49da9d81..d65045f8 100644 --- a/src/toolbar/block/blockbuttonview.js +++ b/src/toolbar/block/blockbuttonview.js @@ -55,7 +55,7 @@ export default class BlockButtonView extends ButtonView { class: 'ck-block-toolbar-button', style: { top: bind.to( 'top', val => toPx( val ) ), - left: bind.to( 'left', val => toPx( val ) ), + left: bind.to( 'left', val => toPx( val ) ) } } } ); diff --git a/src/toolbar/toolbarview.js b/src/toolbar/toolbarview.js index 344f2a0b..29496825 100644 --- a/src/toolbar/toolbarview.js +++ b/src/toolbar/toolbarview.js @@ -178,7 +178,7 @@ export default class ToolbarView extends View { 'ck', 'ck-toolbar', bind.to( 'class' ), - bind.if( 'isCompact', 'ck-toolbar_compact' ), + bind.if( 'isCompact', 'ck-toolbar_compact' ) ], role: 'toolbar', 'aria-label': bind.to( 'ariaLabel' ) @@ -318,7 +318,7 @@ class ItemsView extends View { class: [ 'ck', 'ck-toolbar__items' - ], + ] }, children: this.children } ); diff --git a/src/tooltip/tooltipview.js b/src/tooltip/tooltipview.js index 5f3dfae6..d37f5841 100644 --- a/src/tooltip/tooltipview.js +++ b/src/tooltip/tooltipview.js @@ -77,7 +77,7 @@ export default class TooltipView extends View { children: [ { - text: bind.to( 'text' ), + text: bind.to( 'text' ) } ] } diff --git a/tests/_utils-tests/utils.js b/tests/_utils-tests/utils.js index ce6d0aff..9a2cbc49 100644 --- a/tests/_utils-tests/utils.js +++ b/tests/_utils-tests/utils.js @@ -19,7 +19,7 @@ describe( 'utils', () => { it( 'creates collections and regions', () => { const view = testUtils.createTestUIView( { foo: el => el.firstChild, - bar: el => el.lastChild, + bar: el => el.lastChild } ); expect( view.foo._parentElement ).to.equal( document.body.firstChild ); @@ -29,7 +29,7 @@ describe( 'utils', () => { it( 'is rendered', () => { const view = testUtils.createTestUIView( { foo: el => el.firstChild, - bar: el => el.lastChild, + bar: el => el.lastChild } ); expect( view.isRendered ).to.be.true; diff --git a/tests/focuscycler.js b/tests/focuscycler.js index 82163e0e..c6bb50ff 100644 --- a/tests/focuscycler.js +++ b/tests/focuscycler.js @@ -376,7 +376,7 @@ describe( 'FocusCycler', () => { cycler = new FocusCycler( { focusables, focusTracker, keystrokeHandler, actions: { - focusPrevious: [ 'arrowup', 'arrowleft' ], + focusPrevious: [ 'arrowup', 'arrowleft' ] } } ); diff --git a/tests/manual/tickets/228/1.js b/tests/manual/tickets/228/1.js index 4ee41a70..198fa845 100644 --- a/tests/manual/tickets/228/1.js +++ b/tests/manual/tickets/228/1.js @@ -11,6 +11,6 @@ import ArticlePluginSet from '@ckeditor/ckeditor5-core/tests/_utils/articleplugi ClassicEditor .create( document.querySelector( '#editor' ), { plugins: [ ArticlePluginSet ], - toolbar: [ 'heading' ], + toolbar: [ 'heading' ] } ) .catch( err => console.error( err.stack ) ); diff --git a/tests/panel/balloon/contextualballoon.js b/tests/panel/balloon/contextualballoon.js index 7b7f3f29..6ee4452b 100644 --- a/tests/panel/balloon/contextualballoon.js +++ b/tests/panel/balloon/contextualballoon.js @@ -276,7 +276,7 @@ describe( 'ContextualBalloon', () => { balloon.add( { view: viewB, position: { - target: 'foo', + target: 'foo' } } ); @@ -290,7 +290,7 @@ describe( 'ContextualBalloon', () => { const data = { view: viewB, position: { - target: 'foo', + target: 'foo' } }; diff --git a/tests/panel/sticky/stickypanelview.js b/tests/panel/sticky/stickypanelview.js index e45d520a..f7d51c5f 100644 --- a/tests/panel/sticky/stickypanelview.js +++ b/tests/panel/sticky/stickypanelview.js @@ -345,7 +345,7 @@ describe( 'StickyPanelView', () => { it( 'is false if view.isSticky is false', () => { testUtils.sinon.stub( limiterElement, 'getBoundingClientRect' ).returns( { - top: 10, + top: 10 } ); expect( view.isSticky ).to.be.false; @@ -477,7 +477,7 @@ describe( 'StickyPanelView', () => { it( 'is not set if view.isSticky is false', () => { testUtils.sinon.stub( limiterElement, 'getBoundingClientRect' ).returns( { - top: 10, + top: 10 } ); expect( view.isSticky ).to.be.false; diff --git a/tests/template.js b/tests/template.js index 40a7ebd3..b01dcc76 100644 --- a/tests/template.js +++ b/tests/template.js @@ -101,7 +101,7 @@ describe( 'Template', () => { it( 'defines #children collection', () => { const elementTpl = new Template( { - tag: 'p', + tag: 'p' } ); const textTpl = new Template( { @@ -119,7 +119,7 @@ describe( 'Template', () => { const def = { tag: 'p', attributes: { - a: 'foo', + a: 'foo' }, children: [ { @@ -167,7 +167,7 @@ describe( 'Template', () => { describe( 'DOM Node', () => { it( 'creates HTMLElement', () => { const el = new Template( { - tag: 'p', + tag: 'p' } ).render(); expect( el ).to.be.instanceof( HTMLElement ); @@ -882,7 +882,7 @@ describe( 'Template', () => { tag: 'p', attributes: { style: { - width: '20px', + width: '20px' } } } ); @@ -906,7 +906,7 @@ describe( 'Template', () => { tag: 'p', attributes: { style: { - left: '20px', + left: '20px' } } } ); @@ -1224,14 +1224,14 @@ describe( 'Template', () => { tag: 'a', attributes: { foo: 'af', - bar: 'ab', + bar: 'ab' }, children: [ { tag: 'b', attributes: { foo: 'bf', - bar: 'bb', + bar: 'bb' } } ] @@ -1274,14 +1274,14 @@ describe( 'Template', () => { tag: 'a', attributes: { foo: 'af', - bar: 'ab', + bar: 'ab' }, children: [ { tag: 'b', attributes: { foo: 'bf', - bar: 'bb', + bar: 'bb' } } ] @@ -1546,7 +1546,7 @@ describe( 'Template', () => { const template = new Template( { tag: 'div', children: [ - viewA, + viewA ] } ); @@ -1596,7 +1596,7 @@ describe( 'Template', () => { setElement( { tag: 'p', on: { - x: bind.to( 'a' ), + x: bind.to( 'a' ) } } ); @@ -1648,7 +1648,7 @@ describe( 'Template', () => { { tag: 'span', attributes: { - 'class': 'y', + 'class': 'y' }, on: { 'test@p': bind.to( 'c' ) @@ -1660,10 +1660,10 @@ describe( 'Template', () => { { tag: 'span', attributes: { - 'class': 'y', + 'class': 'y' } } - ], + ] } ], on: { @@ -1761,7 +1761,7 @@ describe( 'Template', () => { } ], on: { - x: bind.to( 'a' ), + x: bind.to( 'a' ) } } ); @@ -2313,7 +2313,7 @@ describe( 'Template', () => { const def = { tag: 'p', attributes: { - a: 'foo', + a: 'foo' } }; const ext = { @@ -2470,7 +2470,7 @@ describe( 'Template', () => { it( 'creates new - no attributes', () => { extensionTest( { - tag: 'p', + tag: 'p' }, { attributes: { @@ -2711,7 +2711,7 @@ describe( 'Template', () => { expectToThrowCKEditorError( () => { extensionTest( { - tag: 'p', + tag: 'p' }, { children: [ @@ -2895,7 +2895,7 @@ describe( 'Template', () => { Template.extend( template.children[ 0 ], { attributes: { - class: 'B', + class: 'B' }, children: [ 'B', @@ -2982,7 +2982,7 @@ describe( 'Template', () => { { tag: 'span' } - ], + ] }, { on: {