jenkins-bot has submitted this change and it was merged.

Change subject: Remove the "Open" button from link inspectors
......................................................................


Remove the "Open" button from link inspectors

Making consistent with the external-link node inspector. General
reasoning is that in most cases they can be opened from the context
popup anyway, so this is redundant. Since this is the last reference
to the localized "Open", strip it out of qqq and en.

Bug: T109646
Change-Id: Ia12c7862ce8d9f07951c452523465c0cd04f7f74
---
M i18n/en.json
M i18n/qqq.json
M src/ui/inspectors/ve.ui.LinkAnnotationInspector.js
3 files changed, 1 insertion(+), 22 deletions(-)

Approvals:
  Siebrand: Looks good to me, but someone else must approve
  Jforrester: Looks good to me, but someone else must approve
  Esanders: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/i18n/en.json b/i18n/en.json
index ee4a58f..4f293e7 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -93,7 +93,6 @@
        "visualeditor-languageinspector-widget-label-direction": "Direction",
        "visualeditor-languageinspector-widget-label-langcode": "Language code",
        "visualeditor-languageinspector-widget-label-language": "Language",
-       "visualeditor-linkinspector-open": "Open",
        "visualeditor-linkinspector-title": "Link",
        "visualeditor-listbutton-bullet-tooltip": "Bullet list",
        "visualeditor-listbutton-number-tooltip": "Numbered list",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 965c772..d46786c 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -101,7 +101,6 @@
        "visualeditor-languageinspector-widget-label-direction": "Label for the 
language inspector widget, to denote the text direction of the current element 
(left-to-right or right-to-left).\n{{Identical|Direction}}",
        "visualeditor-languageinspector-widget-label-langcode": "Label for the 
language inspector widget, to denote the current block language 
code.\n{{Identical|Language code}}",
        "visualeditor-languageinspector-widget-label-language": "Label for the 
language inspector widget, to denote the current block 
language.\n{{Identical|Language}}",
-       "visualeditor-linkinspector-open": "Label for the button that opens the 
current link in a new window\n{{Identical|Open}}",
        "visualeditor-linkinspector-title": "Title of the link inspector 
dialog.\n{{Identical|Link}}",
        "visualeditor-listbutton-bullet-tooltip": "Tooltip text for the bullet 
list button",
        "visualeditor-listbutton-number-tooltip": "Tooltip text for the 
numbered list button",
diff --git a/src/ui/inspectors/ve.ui.LinkAnnotationInspector.js 
b/src/ui/inspectors/ve.ui.LinkAnnotationInspector.js
index db5ba90..e30c91a 100644
--- a/src/ui/inspectors/ve.ui.LinkAnnotationInspector.js
+++ b/src/ui/inspectors/ve.ui.LinkAnnotationInspector.js
@@ -30,14 +30,6 @@
 
 ve.ui.LinkAnnotationInspector.static.modelClasses = [ ve.dm.LinkAnnotation ];
 
-ve.ui.LinkAnnotationInspector.static.actions = 
ve.ui.LinkAnnotationInspector.super.static.actions.concat( [
-       {
-               action: 'open',
-               label: OO.ui.deferMsg( 'visualeditor-linkinspector-open' ),
-               modes: [ 'edit', 'insert' ]
-       }
-] );
-
 /* Methods */
 
 /**
@@ -58,7 +50,7 @@
 
        this.annotationInput.getTextInputWidget().isValid().done( function ( 
isValid ) {
                isValid = isValid && !!annotation;
-               inspector.actions.forEach( { actions: [ 'open', 'done', 
'insert' ] }, function ( action ) {
+               inspector.actions.forEach( { actions: [ 'done', 'insert' ] }, 
function ( action ) {
                        action.setDisabled( !isValid );
                } );
        } );
@@ -169,17 +161,6 @@
                .next( function () {
                        this.annotationInput.setAnnotation( null );
                }, this );
-};
-
-/**
- * @inheritdoc
- */
-ve.ui.LinkAnnotationInspector.prototype.getActionProcess = function ( action ) 
{
-       if ( action === 'open' ) {
-               window.open( this.annotationInput.getHref() );
-       }
-
-       return 
ve.ui.LinkAnnotationInspector.super.prototype.getActionProcess.call( this, 
action );
 };
 
 /* Registration */

-- 
To view, visit https://gerrit.wikimedia.org/r/244373
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia12c7862ce8d9f07951c452523465c0cd04f7f74
Gerrit-PatchSet: 2
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: DLynch <[email protected]>
Gerrit-Reviewer: Esanders <[email protected]>
Gerrit-Reviewer: Jforrester <[email protected]>
Gerrit-Reviewer: Siebrand <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to