Constructor
new ve.dm.TableCellableNode()abstract
#
DataModel node which can behave as a table cell
- Source:
DataModel node which can behave as a table cell
Methods
getColspan() → {number}
#
Get the number of columns the cell spans
Returns:
Columns spanned
- Type
- number
Get the number of columns the cell spans
getRowspan() → {number}
#
Get the number of rows the cell spans
Returns:
Rows spanned
- Type
- number
Get the number of rows the cell spans
getSpans() → {Object}
#
Get number of columns and rows the cell spans
Returns:
Object containing 'col' and 'row'
- Type
- Object
Get number of columns and rows the cell spans
getStyle() → {string}
#
Get the style of the cell
Returns:
Style, 'header' or 'data'
- Type
- string
Get the style of the cell
onCellableAttributeChange(key, from, to)
#
Handle attributes changes
Parameters:
| Name | Type | Description |
|---|---|---|
key |
string | Attribute key |
from |
string | Old value |
to |
string | New value |
Handle attributes changes
applyAttributes(attributes, domElement)static
#
Parameters:
| Name | Type | Description |
|---|---|---|
attributes |
ve.dm.TableCellableNode.TableAttributes | |
domElement |
HTMLElement |
setAttributes(attributes, domElements, isAlien)static
#
Parameters:
| Name | Type | Description |
|---|---|---|
attributes |
ve.dm.TableCellableNode.TableAttributes | |
domElements |
Array.<HTMLElement> | |
isAlien |
boolean |
- Source:
Type Definitions
TableAttributes
#
Type:
Properties:
| Name | Type | Attributes | Description |
|---|---|---|---|
style |
string | 'header' or 'data' |
|
rowspan |
number |
optional |
|
originalRowspan |
string |
optional |
|
colspan |
number |
optional |
|
originalColspan |
string |
optional |
|
align |
string |
optional |
DOM attribute align (deprecated) |
valign |
string |
optional |
DOM attribute valign (deprecated) |
textAlign |
string |
optional |
CSS property text-align |
verticalAlign |
string |
optional |
CSS property vertical-align |
originalTextAlign |
string |
optional |
CSS property text-align (original value) |
originalVerticalAlign |
string |
optional |
CSS property vertical-align (original value) |
- Source: