8
0
Aleksander Nowodzinski 8 лет назад
Родитель
Сommit
d68babc1a0
1 измененных файлов с 8 добавлено и 4 удалено
  1. 8 4
      packages/ckeditor5-utils/src/dom/scroll.js

+ 8 - 4
packages/ckeditor5-utils/src/dom/scroll.js

@@ -13,10 +13,7 @@ import global from './global';
 import isRange from './isrange';
 import Rect from './rect';
 
-const utils = {
-	scrollViewportToShowTarget,
-	scrollAncestorsToShowTarget
-};
+const utils = {};
 
 /**
  * Makes any page `HTMLElement` or `Range` (`target`) visible inside the browser viewport.
@@ -103,6 +100,13 @@ export function scrollAncestorsToShowTarget( target ) {
 	} while ( ( parent = parent.parentNode ) );
 }
 
+// TODO: Using a property value shorthand in the top of the file
+// causes JSDoc to throw errors. See https://github.com/cksource/docs-builder/issues/75.
+Object.assign( utils, {
+	scrollViewportToShowTarget,
+	scrollAncestorsToShowTarget
+} );
+
 // For testing purposes (easy helper stubbing).
 export { utils as _test };