jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/335611 )
Change subject: Support removal of links from Link card ...................................................................... Support removal of links from Link card Change-Id: Ibcf2dd053e23ee438191ea6d8853fa8d9da37f28 --- M modules/tools/mw.cx.tools.LinkTool.js 1 file changed, 8 insertions(+), 1 deletion(-) Approvals: jenkins-bot: Verified Nikerabbit: Looks good to me, approved diff --git a/modules/tools/mw.cx.tools.LinkTool.js b/modules/tools/mw.cx.tools.LinkTool.js index 5a8f754..699d845 100644 --- a/modules/tools/mw.cx.tools.LinkTool.js +++ b/modules/tools/mw.cx.tools.LinkTool.js @@ -39,7 +39,9 @@ framed: false, classes: [ 'cx-tools-link-remove-button' ] } ); - + this.removeLinkButton.connect( this, { + click: 'removeLink' + } ); this.actions = [ this.addLinkButton, this.removeLinkButton @@ -83,5 +85,10 @@ return panel.$element; }; +mw.cx.tools.LinkTool.prototype.removeLink = function () { + this.translationUnitUIModel.remove(); + this.destroy(); +}; + /* Register */ mw.cx.tools.translationToolFactory.register( mw.cx.tools.LinkTool ); -- To view, visit https://gerrit.wikimedia.org/r/335611 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ibcf2dd053e23ee438191ea6d8853fa8d9da37f28 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/ContentTranslation Gerrit-Branch: master Gerrit-Owner: Santhosh <santhosh.thottin...@gmail.com> Gerrit-Reviewer: Nikerabbit <niklas.laxst...@gmail.com> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits