8
0
Aleksander Nowodzinski 6 лет назад
Родитель
Сommit
57a9e58c4a
1 измененных файлов с 2 добавлено и 6 удалено
  1. 2 6
      packages/ckeditor5-table/src/ui/utils.js

+ 2 - 6
packages/ckeditor5-table/src/ui/utils.js

@@ -37,17 +37,13 @@ export function repositionContextualBalloon( editor ) {
  * @returns {module:utils/dom/position~Options}
  */
 export function getBalloonCellPositionData( editor ) {
-	const model = editor.model;
-	const document = model.document;
-	const selection = document.selection;
-	const editingView = editor.editing.view;
-	const firstPosition = selection.getFirstPosition();
+	const firstPosition = editor.model.document.selection.getFirstPosition();
 	const modelTableCell = findAncestor( 'tableCell', firstPosition );
 	const viewTableCell = editor.editing.mapper.toViewElement( modelTableCell );
 	const defaultPositions = BalloonPanelView.defaultPositions;
 
 	return {
-		target: editingView.domConverter.viewToDom( viewTableCell ),
+		target: editor.editing.view.domConverter.viewToDom( viewTableCell ),
 		positions: [
 			defaultPositions.northArrowSouth,
 			defaultPositions.northArrowSouthWest,