Expand all

ve.ui.MWLinkAction

Extends

Constructor

new ve.ui.MWLinkAction(surface) #

Link action.

Opens either MWLinkAnnotationInspector or MWLinkNodeInspector depending on what is selected.

Parameters:

Name Type Description
surface ve.ui.Surface

Surface to act on

Source:
Link action.

Methods

Autolink the selected RFC/PMID/ISBN, which may have trailing punctuation followed by whitespace.

getTrailingPunctuation() #

Match the trailing punctuation set used for autolinks in wikitext. Closing parens are only stripped if open parens are missing from the candidate text, so that URLs with embedded matched parentheses (like wiki articles with disambiguation text) autolink nicely.

Source:
Match the trailing punctuation set used for autolinks in wikitext.

open() → {boolean} #

Open either the 'link' or 'linkNode' window, depending on what is selected.

Source:

Returns:

Action was executed

Type
boolean
Open either the 'link' or 'linkNode' window, depending on what is selected.

getLinkAnnotation(linktext, doc) → {ve.dm.MWExternalLinkAnnotation|ve.dm.MWInternalLinkAnnotation}static #

Get a link annotation from specified link text

This is a static version of the method that can be used in the converter.

Parameters:

Name Type Description
linktext string

Link text

doc HTMLDocument

Document

Source:

Returns:

The annotation to use

Type
ve.dm.MWExternalLinkAnnotation | ve.dm.MWInternalLinkAnnotation

Get a link annotation from specified link text

This is a static version of the method that can be used in the converter.