From 81dcf42eb0bd11110ec30ce3840718b259ec5082 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Mon, 20 Aug 2018 01:20:56 +0200 Subject: [PATCH] edit/page: remove all styling attributes in table editor Prevent accidental or misguided usage of deprecated HTML attributes (width, height, border, cellspacing, cellpadding, align). --- edit/page.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/edit/page.js b/edit/page.js index cdf1f21..c9a6f1e 100644 --- a/edit/page.js +++ b/edit/page.js @@ -51,11 +51,13 @@ CKEDITOR.on('dialogDefinition', function (event) { switch (event.data.name) { case 'table': // override initial attribute values - var infoTab = event.data.definition.getContents('info'); - infoTab.get('txtWidth').default = ''; - infoTab.get('txtBorder').default = '0'; - infoTab.get('txtCellSpace').default = ''; - infoTab.get('txtCellPad').default = ''; + var infotab = event.data.definition.getContents('info'); + infotab.remove('txtWidth'); + infotab.remove('txtHeight'); + infotab.remove('txtBorder'); + infotab.remove('txtCellSpace'); + infotab.remove('txtCellPad'); + infotab.remove('cmbAlign'); break; case 'link': // hide unneeded widgets from the Link Info tab -- 2.30.0