Constructor
new TextInputWidget(…args)
- Source:
Create a text input widget.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
args |
any |
<repeatable> |
Extends
Methods
cdInsertContent(text) → {TextInputWidget}
- Source:
Insert text while keeping the undo/redo functionality.
Parameters:
Name | Type | Description |
---|---|---|
text |
string |
Returns:
- Type
- TextInputWidget
getWikitextFromPaste(html) → {string}
- Source:
Convert HTML code of a paste into wikitext.
Parameters:
Name | Type | Description |
---|---|---|
html |
string | Pasted HTML. |
Returns:
- Type
- string
getWikitextFromSelection() → {Promise.<string>}
- Source:
Given a selection, get its content as wikitext.
Returns:
- Type
- Promise.<string>
(async) maybeConvertElementToWikitext(data) → {string}
- Source:
Given the return value of module:utilsWindow.cleanUpPasteDom, convert the HTML to wikitext if necessary.
Parameters:
Name | Type | Description | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
data |
object | Return value of module:utilsWindow.cleanUpPasteDom. Properties
|
Returns:
- Type
- string