WwTableManager(wwe)

Class WwTableManager

new WwTableManager(wwe)

Creates an instance of WwTableManager.

Parameters:
Name Type Description
wwe WysiwygEditor

WysiwygEditor instance

Methods

destroy()

Destroy.

getTableIDClassName() → {string}

Return new table ID class name string

Returns:
string

isInTable(range) → {boolean}

isInTable
Check whether passed range is in table or not

Parameters:
Name Type Description
range Range

range

Returns:
boolean -

result

isNonTextDeleting(range) → {boolean}

Return whether delete non text or not

Parameters:
Name Type Description
range Range

Range object

Returns:
boolean

isTableOrSubTableElement(pastingNodeName) → {boolean}

Whether pasting element is table element

Parameters:
Name Type Description
pastingNodeName string

Pasting node name

Returns:
boolean

pasteClipboardData($clipboardTable)

Paste clibpard data.

Parameters:
Name Type Description
$clipboardTable jQuery

jQuery table element of clipboard

prepareToTableCellStuffing($trs) → {Object}

Prepare to table cell stuffing

Parameters:
Name Type Description
$trs jQuery

jQuery wrapped TRs

Returns:
Object

resetLastCellNode()

Reset _lastCellNode to null

setLastCellNode(node)

Set _lastCellNode to given node

Parameters:
Name Type Description
node HTMLElement

Table cell

tableCellAppendAidForTableElement(node)

Append table cells

Parameters:
Name Type Description
node HTMLElement

Table element

updateTableHtmlOfClipboardIfNeed($clipboardContainer)

Update table html of clipboard data, if has selected cells.

Parameters:
Name Type Description
$clipboardContainer jQuery

jQuery element

wrapDanglingTableCellsIntoTrIfNeed($container) → {HTMLElement|null}

Wrap dangling table cells with new TR

Parameters:
Name Type Description
$container jQuery

clipboard container

Returns:
HTMLElement | null

wrapTheadAndTbodyIntoTableIfNeed($container) → {HTMLElement|null}

Wrap THEAD followed by TBODY both into Table

Parameters:
Name Type Description
$container jQuery

clipboard container

Returns:
HTMLElement | null

wrapTrsIntoTbodyIfNeed($container) → {HTMLElement|null}

Wrap TRs with new TBODY

Parameters:
Name Type Description
$container jQuery

clipboard container

Returns:
HTMLElement | null