table/converters/downcast
@ckeditor/ckeditor5-table/src/converters/downcast
Filtering
Interfaces
-
DowncastTableOptions
module:table/converters/downcast~DowncastTableOptions
Functions
-
internal
convertParagraphInTableCell( options = { [options.asWidget] } ) → DowncastElementCreatorFunction
module:table/converters/downcast~convertParagraphInTableCell
Overrides paragraph inside table cell conversion.
This converter:
- should be used to override default paragraph conversion.
- It will only convert
<paragraph>
placed directly inside<tableCell>
. - For a single paragraph without attributes it returns
<span>
to simulate data table. - For all other cases it returns
<p>
element.
Parameters
options : object
-
Properties
[ options.asWidget ] : boolean
If set to
true
, the downcast conversion will produce a widget.
Defaults to
{}
Returns
DowncastElementCreatorFunction
Element creator.
-
internal
downcastCell( options = { [options.asWidget] } ) → DowncastElementCreatorFunction
module:table/converters/downcast~downcastCell
Model table cell element to view
<td>
or<th>
element conversion helper.This conversion helper will create proper
<th>
elements for table cells that are in the heading section (heading row or column) and<td>
otherwise.Parameters
options : object
-
Properties
[ options.asWidget ] : boolean
If set to
true
, the downcast conversion will produce a widget.
Defaults to
{}
Returns
DowncastElementCreatorFunction
Element creator.
-
Model table row element to view
<tr>
element conversion helper.Returns
DowncastElementCreatorFunction
Element creator.
-
internal
downcastTable( tableUtils, options ) → DowncastElementCreatorFunction
module:table/converters/downcast~downcastTable
Model table element to view table element conversion helper.
Parameters
tableUtils : TableUtils
options : DowncastTableOptions
Returns
-
internal
isSingleParagraphWithoutAttributes( modelElement ) → boolean
module:table/converters/downcast~isSingleParagraphWithoutAttributes
Checks if given model
<paragraph>
is an only child of a parent (<tableCell>
) and if it has any attribute set.The paragraph should be converted in the editing view to:
- If returned
true
- to a<span class="ck-table-bogus-paragraph">
- If returned
false
- to a<p>
Parameters
modelElement : ModelElement
Returns
boolean
- If returned
Every day, we work hard to keep our documentation complete. Have you spotted outdated information? Is something missing? Please report it via our issue tracker.
With the release of version 42.0.0, we have rewritten much of our documentation to reflect the new import paths and features. We appreciate your feedback to help us ensure its accuracy and completeness.