roosterjs-content-model-api 0.24.0 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.d.ts +48 -42
- package/lib/index.js +99 -87
- package/lib/index.js.map +1 -1
- package/lib/modelApi/block/setModelAlignment.d.ts +5 -5
- package/lib/modelApi/block/setModelAlignment.js +62 -62
- package/lib/modelApi/block/setModelAlignment.js.map +1 -1
- package/lib/modelApi/block/setModelDirection.d.ts +5 -5
- package/lib/modelApi/block/setModelDirection.js +68 -69
- package/lib/modelApi/block/setModelDirection.js.map +1 -1
- package/lib/modelApi/block/setModelIndentation.d.ts +8 -5
- package/lib/modelApi/block/setModelIndentation.js +138 -47
- package/lib/modelApi/block/setModelIndentation.js.map +1 -1
- package/lib/modelApi/block/toggleModelBlockQuote.d.ts +5 -5
- package/lib/modelApi/block/toggleModelBlockQuote.js +50 -48
- package/lib/modelApi/block/toggleModelBlockQuote.js.map +1 -1
- package/lib/modelApi/common/clearModelFormat.d.ts +5 -5
- package/lib/modelApi/common/clearModelFormat.js +129 -129
- package/lib/modelApi/common/clearModelFormat.js.map +1 -1
- package/lib/modelApi/common/wrapBlock.d.ts +16 -16
- package/lib/modelApi/common/wrapBlock.js +48 -44
- package/lib/modelApi/common/wrapBlock.js.map +1 -1
- package/lib/modelApi/entity/insertEntityModel.d.ts +5 -5
- package/lib/modelApi/entity/insertEntityModel.js +79 -75
- package/lib/modelApi/entity/insertEntityModel.js.map +1 -1
- package/lib/modelApi/image/applyImageBorderFormat.d.ts +5 -5
- package/lib/modelApi/image/applyImageBorderFormat.js +57 -57
- package/lib/modelApi/image/applyImageBorderFormat.js.map +1 -1
- package/lib/modelApi/link/matchLink.d.ts +29 -0
- package/lib/modelApi/link/matchLink.js +95 -0
- package/lib/modelApi/link/matchLink.js.map +1 -0
- package/lib/modelApi/list/findListItemsInSameThread.d.ts +7 -5
- package/lib/modelApi/list/findListItemsInSameThread.js +114 -112
- package/lib/modelApi/list/findListItemsInSameThread.js.map +1 -1
- package/lib/modelApi/list/setListType.d.ts +7 -5
- package/lib/modelApi/list/setListType.js +113 -116
- package/lib/modelApi/list/setListType.js.map +1 -1
- package/lib/modelApi/selection/adjustSegmentSelection.d.ts +5 -5
- package/lib/modelApi/selection/adjustSegmentSelection.js +47 -47
- package/lib/modelApi/selection/adjustSegmentSelection.js.map +1 -1
- package/lib/modelApi/selection/adjustTrailingSpaceSelection.d.ts +6 -6
- package/lib/modelApi/selection/adjustTrailingSpaceSelection.js +55 -55
- package/lib/modelApi/selection/adjustTrailingSpaceSelection.js.map +1 -1
- package/lib/modelApi/selection/adjustWordSelection.d.ts +5 -5
- package/lib/modelApi/selection/adjustWordSelection.js +121 -121
- package/lib/modelApi/selection/adjustWordSelection.js.map +1 -1
- package/lib/modelApi/selection/collapseTableSelection.d.ts +5 -5
- package/lib/modelApi/selection/collapseTableSelection.js +16 -16
- package/lib/modelApi/selection/collapseTableSelection.js.map +1 -1
- package/lib/modelApi/table/alignTable.d.ts +5 -5
- package/lib/modelApi/table/alignTable.js +12 -12
- package/lib/modelApi/table/alignTable.js.map +1 -1
- package/lib/modelApi/table/alignTableCell.d.ts +9 -9
- package/lib/modelApi/table/alignTableCell.js +58 -58
- package/lib/modelApi/table/alignTableCell.js.map +1 -1
- package/lib/modelApi/table/canMergeCells.d.ts +5 -5
- package/lib/modelApi/table/canMergeCells.js +56 -56
- package/lib/modelApi/table/canMergeCells.js.map +1 -1
- package/lib/modelApi/table/clearSelectedCells.d.ts +8 -0
- package/lib/modelApi/table/clearSelectedCells.js +27 -0
- package/lib/modelApi/table/clearSelectedCells.js.map +1 -0
- package/lib/modelApi/table/createTableStructure.d.ts +5 -5
- package/lib/modelApi/table/createTableStructure.js +19 -19
- package/lib/modelApi/table/createTableStructure.js.map +1 -1
- package/lib/modelApi/table/deleteTable.d.ts +5 -5
- package/lib/modelApi/table/deleteTable.js +11 -11
- package/lib/modelApi/table/deleteTable.js.map +1 -1
- package/lib/modelApi/table/deleteTableColumn.d.ts +5 -5
- package/lib/modelApi/table/deleteTableColumn.js +24 -24
- package/lib/modelApi/table/deleteTableColumn.js.map +1 -1
- package/lib/modelApi/table/deleteTableRow.d.ts +5 -5
- package/lib/modelApi/table/deleteTableRow.js +23 -23
- package/lib/modelApi/table/deleteTableRow.js.map +1 -1
- package/lib/modelApi/table/ensureFocusableParagraphForTable.d.ts +8 -8
- package/lib/modelApi/table/ensureFocusableParagraphForTable.js +56 -56
- package/lib/modelApi/table/ensureFocusableParagraphForTable.js.map +1 -1
- package/lib/modelApi/table/insertTableColumn.d.ts +7 -5
- package/lib/modelApi/table/insertTableColumn.js +28 -22
- package/lib/modelApi/table/insertTableColumn.js.map +1 -1
- package/lib/modelApi/table/insertTableRow.d.ts +7 -5
- package/lib/modelApi/table/insertTableRow.js +32 -26
- package/lib/modelApi/table/insertTableRow.js.map +1 -1
- package/lib/modelApi/table/mergeTableCells.d.ts +5 -5
- package/lib/modelApi/table/mergeTableCells.js +26 -26
- package/lib/modelApi/table/mergeTableCells.js.map +1 -1
- package/lib/modelApi/table/mergeTableColumn.d.ts +5 -5
- package/lib/modelApi/table/mergeTableColumn.js +37 -37
- package/lib/modelApi/table/mergeTableColumn.js.map +1 -1
- package/lib/modelApi/table/mergeTableRow.d.ts +5 -5
- package/lib/modelApi/table/mergeTableRow.js +38 -38
- package/lib/modelApi/table/mergeTableRow.js.map +1 -1
- package/lib/modelApi/table/splitTableCellHorizontally.d.ts +5 -5
- package/lib/modelApi/table/splitTableCellHorizontally.js +54 -54
- package/lib/modelApi/table/splitTableCellHorizontally.js.map +1 -1
- package/lib/modelApi/table/splitTableCellVertically.d.ts +5 -5
- package/lib/modelApi/table/splitTableCellVertically.js +57 -57
- package/lib/modelApi/table/splitTableCellVertically.js.map +1 -1
- package/lib/publicApi/block/setAlignment.d.ts +7 -7
- package/lib/publicApi/block/setAlignment.js +15 -15
- package/lib/publicApi/block/setAlignment.js.map +1 -1
- package/lib/publicApi/block/setDirection.d.ts +7 -7
- package/lib/publicApi/block/setDirection.js +15 -15
- package/lib/publicApi/block/setDirection.js.map +1 -1
- package/lib/publicApi/block/setHeadingLevel.d.ts +7 -7
- package/lib/publicApi/block/setHeadingLevel.js +49 -49
- package/lib/publicApi/block/setHeadingLevel.js.map +1 -1
- package/lib/publicApi/block/setIndentation.d.ts +8 -8
- package/lib/publicApi/block/setIndentation.js +24 -24
- package/lib/publicApi/block/setIndentation.js.map +1 -1
- package/lib/publicApi/block/setParagraphMargin.d.ts +9 -9
- package/lib/publicApi/block/setParagraphMargin.js +32 -32
- package/lib/publicApi/block/setParagraphMargin.js.map +1 -1
- package/lib/publicApi/block/setSpacing.d.ts +7 -7
- package/lib/publicApi/block/setSpacing.js +20 -20
- package/lib/publicApi/block/setSpacing.js.map +1 -1
- package/lib/publicApi/block/toggleBlockQuote.d.ts +9 -9
- package/lib/publicApi/block/toggleBlockQuote.js +38 -34
- package/lib/publicApi/block/toggleBlockQuote.js.map +1 -1
- package/lib/publicApi/entity/insertEntity.d.ts +25 -25
- package/lib/publicApi/entity/insertEntity.js +41 -40
- package/lib/publicApi/entity/insertEntity.js.map +1 -1
- package/lib/publicApi/format/clearFormat.d.ts +6 -6
- package/lib/publicApi/format/clearFormat.js +22 -22
- package/lib/publicApi/format/clearFormat.js.map +1 -1
- package/lib/publicApi/format/getFormatState.d.ts +6 -26
- package/lib/publicApi/format/getFormatState.js +20 -88
- package/lib/publicApi/format/getFormatState.js.map +1 -1
- package/lib/publicApi/image/adjustImageSelection.d.ts +6 -6
- package/lib/publicApi/image/adjustImageSelection.js +25 -25
- package/lib/publicApi/image/adjustImageSelection.js.map +1 -1
- package/lib/publicApi/image/changeImage.d.ts +7 -7
- package/lib/publicApi/image/changeImage.js +34 -34
- package/lib/publicApi/image/changeImage.js.map +1 -1
- package/lib/publicApi/image/insertImage.d.ts +7 -7
- package/lib/publicApi/image/insertImage.js +36 -36
- package/lib/publicApi/image/insertImage.js.map +1 -1
- package/lib/publicApi/image/setImageAltText.d.ts +8 -8
- package/lib/publicApi/image/setImageAltText.js +16 -16
- package/lib/publicApi/image/setImageAltText.js.map +1 -1
- package/lib/publicApi/image/setImageBorder.d.ts +9 -9
- package/lib/publicApi/image/setImageBorder.js +18 -18
- package/lib/publicApi/image/setImageBorder.js.map +1 -1
- package/lib/publicApi/image/setImageBoxShadow.d.ts +8 -8
- package/lib/publicApi/image/setImageBoxShadow.js +28 -28
- package/lib/publicApi/image/setImageBoxShadow.js.map +1 -1
- package/lib/publicApi/link/adjustLinkSelection.d.ts +6 -6
- package/lib/publicApi/link/adjustLinkSelection.js +33 -33
- package/lib/publicApi/link/adjustLinkSelection.js.map +1 -1
- package/lib/publicApi/link/insertLink.d.ts +15 -15
- package/lib/publicApi/link/insertLink.js +119 -128
- package/lib/publicApi/link/insertLink.js.map +1 -1
- package/lib/publicApi/link/removeLink.d.ts +8 -8
- package/lib/publicApi/link/removeLink.js +31 -31
- package/lib/publicApi/link/removeLink.js.map +1 -1
- package/lib/publicApi/list/setListStartNumber.d.ts +7 -7
- package/lib/publicApi/list/setListStartNumber.js +25 -25
- package/lib/publicApi/list/setListStartNumber.js.map +1 -1
- package/lib/publicApi/list/setListStyle.d.ts +7 -7
- package/lib/publicApi/list/setListStyle.js +32 -32
- package/lib/publicApi/list/setListStyle.js.map +1 -1
- package/lib/publicApi/list/toggleBullet.d.ts +8 -8
- package/lib/publicApi/list/toggleBullet.js +19 -19
- package/lib/publicApi/list/toggleBullet.js.map +1 -1
- package/lib/publicApi/list/toggleNumbering.d.ts +8 -8
- package/lib/publicApi/list/toggleNumbering.js +19 -19
- package/lib/publicApi/list/toggleNumbering.js.map +1 -1
- package/lib/publicApi/segment/applySegmentFormat.d.ts +7 -7
- package/lib/publicApi/segment/applySegmentFormat.js +22 -22
- package/lib/publicApi/segment/applySegmentFormat.js.map +1 -1
- package/lib/publicApi/segment/changeCapitalization.d.ts +10 -10
- package/lib/publicApi/segment/changeCapitalization.js +48 -49
- package/lib/publicApi/segment/changeCapitalization.js.map +1 -1
- package/lib/publicApi/segment/changeFontSize.d.ts +8 -8
- package/lib/publicApi/segment/changeFontSize.js +61 -61
- package/lib/publicApi/segment/changeFontSize.js.map +1 -1
- package/lib/publicApi/segment/setBackgroundColor.d.ts +7 -7
- package/lib/publicApi/segment/setBackgroundColor.js +35 -35
- package/lib/publicApi/segment/setBackgroundColor.js.map +1 -1
- package/lib/publicApi/segment/setFontName.d.ts +7 -7
- package/lib/publicApi/segment/setFontName.js +18 -18
- package/lib/publicApi/segment/setFontName.js.map +1 -1
- package/lib/publicApi/segment/setFontSize.d.ts +12 -12
- package/lib/publicApi/segment/setFontSize.js +33 -33
- package/lib/publicApi/segment/setFontSize.js.map +1 -1
- package/lib/publicApi/segment/setTextColor.d.ts +7 -7
- package/lib/publicApi/segment/setTextColor.js +25 -25
- package/lib/publicApi/segment/setTextColor.js.map +1 -1
- package/lib/publicApi/segment/toggleBold.d.ts +6 -6
- package/lib/publicApi/segment/toggleBold.js +20 -20
- package/lib/publicApi/segment/toggleBold.js.map +1 -1
- package/lib/publicApi/segment/toggleCode.d.ts +6 -6
- package/lib/publicApi/segment/toggleCode.js +27 -27
- package/lib/publicApi/segment/toggleCode.js.map +1 -1
- package/lib/publicApi/segment/toggleItalic.d.ts +6 -6
- package/lib/publicApi/segment/toggleItalic.js +14 -14
- package/lib/publicApi/segment/toggleItalic.js.map +1 -1
- package/lib/publicApi/segment/toggleStrikethrough.d.ts +6 -6
- package/lib/publicApi/segment/toggleStrikethrough.js +14 -14
- package/lib/publicApi/segment/toggleStrikethrough.js.map +1 -1
- package/lib/publicApi/segment/toggleSubscript.d.ts +6 -6
- package/lib/publicApi/segment/toggleSubscript.js +14 -14
- package/lib/publicApi/segment/toggleSubscript.js.map +1 -1
- package/lib/publicApi/segment/toggleSuperscript.d.ts +6 -6
- package/lib/publicApi/segment/toggleSuperscript.js +14 -14
- package/lib/publicApi/segment/toggleSuperscript.js.map +1 -1
- package/lib/publicApi/segment/toggleUnderline.d.ts +6 -6
- package/lib/publicApi/segment/toggleUnderline.js +18 -18
- package/lib/publicApi/segment/toggleUnderline.js.map +1 -1
- package/lib/publicApi/table/applyTableBorderFormat.d.ts +8 -8
- package/lib/publicApi/table/applyTableBorderFormat.js +293 -293
- package/lib/publicApi/table/applyTableBorderFormat.js.map +1 -1
- package/lib/publicApi/table/editTable.d.ts +7 -7
- package/lib/publicApi/table/editTable.js +77 -102
- package/lib/publicApi/table/editTable.js.map +1 -1
- package/lib/publicApi/table/formatTable.d.ts +8 -8
- package/lib/publicApi/table/formatTable.js +37 -37
- package/lib/publicApi/table/formatTable.js.map +1 -1
- package/lib/publicApi/table/insertTable.d.ts +11 -11
- package/lib/publicApi/table/insertTable.js +46 -46
- package/lib/publicApi/table/insertTable.js.map +1 -1
- package/lib/publicApi/table/setTableCellShade.d.ts +7 -7
- package/lib/publicApi/table/setTableCellShade.js +32 -32
- package/lib/publicApi/table/setTableCellShade.js.map +1 -1
- package/lib/publicApi/utils/formatImageWithContentModel.d.ts +5 -5
- package/lib/publicApi/utils/formatImageWithContentModel.js +14 -14
- package/lib/publicApi/utils/formatImageWithContentModel.js.map +1 -1
- package/lib/publicApi/utils/formatParagraphWithContentModel.d.ts +5 -5
- package/lib/publicApi/utils/formatParagraphWithContentModel.js +18 -18
- package/lib/publicApi/utils/formatParagraphWithContentModel.js.map +1 -1
- package/lib/publicApi/utils/formatSegmentWithContentModel.d.ts +5 -5
- package/lib/publicApi/utils/formatSegmentWithContentModel.js +46 -46
- package/lib/publicApi/utils/formatSegmentWithContentModel.js.map +1 -1
- package/lib/publicApi/utils/formatTableWithContentModel.d.ts +9 -0
- package/lib/publicApi/utils/formatTableWithContentModel.js +44 -0
- package/lib/publicApi/utils/formatTableWithContentModel.js.map +1 -0
- package/lib-amd/index.d.ts +48 -42
- package/lib-amd/index.js +53 -47
- package/lib-amd/index.js.map +1 -1
- package/lib-amd/modelApi/block/setModelAlignment.d.ts +5 -5
- package/lib-amd/modelApi/block/setModelAlignment.js +62 -62
- package/lib-amd/modelApi/block/setModelAlignment.js.map +1 -1
- package/lib-amd/modelApi/block/setModelDirection.d.ts +5 -5
- package/lib-amd/modelApi/block/setModelDirection.js +68 -69
- package/lib-amd/modelApi/block/setModelDirection.js.map +1 -1
- package/lib-amd/modelApi/block/setModelIndentation.d.ts +8 -5
- package/lib-amd/modelApi/block/setModelIndentation.js +137 -47
- package/lib-amd/modelApi/block/setModelIndentation.js.map +1 -1
- package/lib-amd/modelApi/block/toggleModelBlockQuote.d.ts +5 -5
- package/lib-amd/modelApi/block/toggleModelBlockQuote.js +49 -47
- package/lib-amd/modelApi/block/toggleModelBlockQuote.js.map +1 -1
- package/lib-amd/modelApi/common/clearModelFormat.d.ts +5 -5
- package/lib-amd/modelApi/common/clearModelFormat.js +127 -127
- package/lib-amd/modelApi/common/clearModelFormat.js.map +1 -1
- package/lib-amd/modelApi/common/wrapBlock.d.ts +16 -16
- package/lib-amd/modelApi/common/wrapBlock.js +48 -44
- package/lib-amd/modelApi/common/wrapBlock.js.map +1 -1
- package/lib-amd/modelApi/entity/insertEntityModel.d.ts +5 -5
- package/lib-amd/modelApi/entity/insertEntityModel.js +78 -74
- package/lib-amd/modelApi/entity/insertEntityModel.js.map +1 -1
- package/lib-amd/modelApi/image/applyImageBorderFormat.d.ts +5 -5
- package/lib-amd/modelApi/image/applyImageBorderFormat.js +57 -57
- package/lib-amd/modelApi/image/applyImageBorderFormat.js.map +1 -1
- package/lib-amd/modelApi/link/matchLink.d.ts +29 -0
- package/lib-amd/modelApi/link/matchLink.js +95 -0
- package/lib-amd/modelApi/link/matchLink.js.map +1 -0
- package/lib-amd/modelApi/list/findListItemsInSameThread.d.ts +7 -5
- package/lib-amd/modelApi/list/findListItemsInSameThread.js +116 -114
- package/lib-amd/modelApi/list/findListItemsInSameThread.js.map +1 -1
- package/lib-amd/modelApi/list/setListType.d.ts +7 -5
- package/lib-amd/modelApi/list/setListType.js +113 -116
- package/lib-amd/modelApi/list/setListType.js.map +1 -1
- package/lib-amd/modelApi/selection/adjustSegmentSelection.d.ts +5 -5
- package/lib-amd/modelApi/selection/adjustSegmentSelection.js +48 -48
- package/lib-amd/modelApi/selection/adjustSegmentSelection.js.map +1 -1
- package/lib-amd/modelApi/selection/adjustTrailingSpaceSelection.d.ts +6 -6
- package/lib-amd/modelApi/selection/adjustTrailingSpaceSelection.js +54 -54
- package/lib-amd/modelApi/selection/adjustTrailingSpaceSelection.js.map +1 -1
- package/lib-amd/modelApi/selection/adjustWordSelection.d.ts +5 -5
- package/lib-amd/modelApi/selection/adjustWordSelection.js +120 -120
- package/lib-amd/modelApi/selection/adjustWordSelection.js.map +1 -1
- package/lib-amd/modelApi/selection/collapseTableSelection.d.ts +5 -5
- package/lib-amd/modelApi/selection/collapseTableSelection.js +17 -17
- package/lib-amd/modelApi/selection/collapseTableSelection.js.map +1 -1
- package/lib-amd/modelApi/table/alignTable.d.ts +5 -5
- package/lib-amd/modelApi/table/alignTable.js +14 -14
- package/lib-amd/modelApi/table/alignTable.js.map +1 -1
- package/lib-amd/modelApi/table/alignTableCell.d.ts +9 -9
- package/lib-amd/modelApi/table/alignTableCell.js +59 -59
- package/lib-amd/modelApi/table/alignTableCell.js.map +1 -1
- package/lib-amd/modelApi/table/canMergeCells.d.ts +5 -5
- package/lib-amd/modelApi/table/canMergeCells.js +58 -58
- package/lib-amd/modelApi/table/canMergeCells.js.map +1 -1
- package/lib-amd/modelApi/table/clearSelectedCells.d.ts +8 -0
- package/lib-amd/modelApi/table/clearSelectedCells.js +28 -0
- package/lib-amd/modelApi/table/clearSelectedCells.js.map +1 -0
- package/lib-amd/modelApi/table/createTableStructure.d.ts +5 -5
- package/lib-amd/modelApi/table/createTableStructure.js +20 -20
- package/lib-amd/modelApi/table/createTableStructure.js.map +1 -1
- package/lib-amd/modelApi/table/deleteTable.d.ts +5 -5
- package/lib-amd/modelApi/table/deleteTable.js +13 -13
- package/lib-amd/modelApi/table/deleteTable.js.map +1 -1
- package/lib-amd/modelApi/table/deleteTableColumn.d.ts +5 -5
- package/lib-amd/modelApi/table/deleteTableColumn.js +24 -24
- package/lib-amd/modelApi/table/deleteTableColumn.js.map +1 -1
- package/lib-amd/modelApi/table/deleteTableRow.d.ts +5 -5
- package/lib-amd/modelApi/table/deleteTableRow.js +23 -23
- package/lib-amd/modelApi/table/deleteTableRow.js.map +1 -1
- package/lib-amd/modelApi/table/ensureFocusableParagraphForTable.d.ts +8 -8
- package/lib-amd/modelApi/table/ensureFocusableParagraphForTable.js +57 -57
- package/lib-amd/modelApi/table/ensureFocusableParagraphForTable.js.map +1 -1
- package/lib-amd/modelApi/table/insertTableColumn.d.ts +7 -5
- package/lib-amd/modelApi/table/insertTableColumn.js +27 -22
- package/lib-amd/modelApi/table/insertTableColumn.js.map +1 -1
- package/lib-amd/modelApi/table/insertTableRow.d.ts +7 -5
- package/lib-amd/modelApi/table/insertTableRow.js +30 -25
- package/lib-amd/modelApi/table/insertTableRow.js.map +1 -1
- package/lib-amd/modelApi/table/mergeTableCells.d.ts +5 -5
- package/lib-amd/modelApi/table/mergeTableCells.js +26 -26
- package/lib-amd/modelApi/table/mergeTableCells.js.map +1 -1
- package/lib-amd/modelApi/table/mergeTableColumn.d.ts +5 -5
- package/lib-amd/modelApi/table/mergeTableColumn.js +37 -37
- package/lib-amd/modelApi/table/mergeTableColumn.js.map +1 -1
- package/lib-amd/modelApi/table/mergeTableRow.d.ts +5 -5
- package/lib-amd/modelApi/table/mergeTableRow.js +38 -38
- package/lib-amd/modelApi/table/mergeTableRow.js.map +1 -1
- package/lib-amd/modelApi/table/splitTableCellHorizontally.d.ts +5 -5
- package/lib-amd/modelApi/table/splitTableCellHorizontally.js +53 -53
- package/lib-amd/modelApi/table/splitTableCellHorizontally.js.map +1 -1
- package/lib-amd/modelApi/table/splitTableCellVertically.d.ts +5 -5
- package/lib-amd/modelApi/table/splitTableCellVertically.js +56 -56
- package/lib-amd/modelApi/table/splitTableCellVertically.js.map +1 -1
- package/lib-amd/publicApi/block/setAlignment.d.ts +7 -7
- package/lib-amd/publicApi/block/setAlignment.js +16 -16
- package/lib-amd/publicApi/block/setAlignment.js.map +1 -1
- package/lib-amd/publicApi/block/setDirection.d.ts +7 -7
- package/lib-amd/publicApi/block/setDirection.js +16 -16
- package/lib-amd/publicApi/block/setDirection.js.map +1 -1
- package/lib-amd/publicApi/block/setHeadingLevel.d.ts +7 -7
- package/lib-amd/publicApi/block/setHeadingLevel.js +50 -50
- package/lib-amd/publicApi/block/setHeadingLevel.js.map +1 -1
- package/lib-amd/publicApi/block/setIndentation.d.ts +8 -8
- package/lib-amd/publicApi/block/setIndentation.js +24 -24
- package/lib-amd/publicApi/block/setIndentation.js.map +1 -1
- package/lib-amd/publicApi/block/setParagraphMargin.d.ts +9 -9
- package/lib-amd/publicApi/block/setParagraphMargin.js +32 -32
- package/lib-amd/publicApi/block/setParagraphMargin.js.map +1 -1
- package/lib-amd/publicApi/block/setSpacing.d.ts +7 -7
- package/lib-amd/publicApi/block/setSpacing.js +21 -21
- package/lib-amd/publicApi/block/setSpacing.js.map +1 -1
- package/lib-amd/publicApi/block/toggleBlockQuote.d.ts +9 -9
- package/lib-amd/publicApi/block/toggleBlockQuote.js +38 -34
- package/lib-amd/publicApi/block/toggleBlockQuote.js.map +1 -1
- package/lib-amd/publicApi/entity/insertEntity.d.ts +25 -25
- package/lib-amd/publicApi/entity/insertEntity.js +40 -39
- package/lib-amd/publicApi/entity/insertEntity.js.map +1 -1
- package/lib-amd/publicApi/format/clearFormat.d.ts +6 -6
- package/lib-amd/publicApi/format/clearFormat.js +22 -22
- package/lib-amd/publicApi/format/clearFormat.js.map +1 -1
- package/lib-amd/publicApi/format/getFormatState.d.ts +6 -26
- package/lib-amd/publicApi/format/getFormatState.js +21 -86
- package/lib-amd/publicApi/format/getFormatState.js.map +1 -1
- package/lib-amd/publicApi/image/adjustImageSelection.d.ts +6 -6
- package/lib-amd/publicApi/image/adjustImageSelection.js +26 -26
- package/lib-amd/publicApi/image/adjustImageSelection.js.map +1 -1
- package/lib-amd/publicApi/image/changeImage.d.ts +7 -7
- package/lib-amd/publicApi/image/changeImage.js +34 -34
- package/lib-amd/publicApi/image/changeImage.js.map +1 -1
- package/lib-amd/publicApi/image/insertImage.d.ts +7 -7
- package/lib-amd/publicApi/image/insertImage.js +36 -36
- package/lib-amd/publicApi/image/insertImage.js.map +1 -1
- package/lib-amd/publicApi/image/setImageAltText.d.ts +8 -8
- package/lib-amd/publicApi/image/setImageAltText.js +17 -17
- package/lib-amd/publicApi/image/setImageAltText.js.map +1 -1
- package/lib-amd/publicApi/image/setImageBorder.d.ts +9 -9
- package/lib-amd/publicApi/image/setImageBorder.js +18 -18
- package/lib-amd/publicApi/image/setImageBorder.js.map +1 -1
- package/lib-amd/publicApi/image/setImageBoxShadow.d.ts +8 -8
- package/lib-amd/publicApi/image/setImageBoxShadow.js +29 -29
- package/lib-amd/publicApi/image/setImageBoxShadow.js.map +1 -1
- package/lib-amd/publicApi/link/adjustLinkSelection.d.ts +6 -6
- package/lib-amd/publicApi/link/adjustLinkSelection.js +32 -32
- package/lib-amd/publicApi/link/adjustLinkSelection.js.map +1 -1
- package/lib-amd/publicApi/link/insertLink.d.ts +15 -15
- package/lib-amd/publicApi/link/insertLink.js +116 -125
- package/lib-amd/publicApi/link/insertLink.js.map +1 -1
- package/lib-amd/publicApi/link/removeLink.d.ts +8 -8
- package/lib-amd/publicApi/link/removeLink.js +31 -31
- package/lib-amd/publicApi/link/removeLink.js.map +1 -1
- package/lib-amd/publicApi/list/setListStartNumber.d.ts +7 -7
- package/lib-amd/publicApi/list/setListStartNumber.js +26 -26
- package/lib-amd/publicApi/list/setListStartNumber.js.map +1 -1
- package/lib-amd/publicApi/list/setListStyle.d.ts +7 -7
- package/lib-amd/publicApi/list/setListStyle.js +32 -32
- package/lib-amd/publicApi/list/setListStyle.js.map +1 -1
- package/lib-amd/publicApi/list/toggleBullet.d.ts +8 -8
- package/lib-amd/publicApi/list/toggleBullet.js +20 -20
- package/lib-amd/publicApi/list/toggleBullet.js.map +1 -1
- package/lib-amd/publicApi/list/toggleNumbering.d.ts +8 -8
- package/lib-amd/publicApi/list/toggleNumbering.js +20 -20
- package/lib-amd/publicApi/list/toggleNumbering.js.map +1 -1
- package/lib-amd/publicApi/segment/applySegmentFormat.d.ts +7 -7
- package/lib-amd/publicApi/segment/applySegmentFormat.js +23 -23
- package/lib-amd/publicApi/segment/applySegmentFormat.js.map +1 -1
- package/lib-amd/publicApi/segment/changeCapitalization.d.ts +10 -10
- package/lib-amd/publicApi/segment/changeCapitalization.js +49 -50
- package/lib-amd/publicApi/segment/changeCapitalization.js.map +1 -1
- package/lib-amd/publicApi/segment/changeFontSize.d.ts +8 -8
- package/lib-amd/publicApi/segment/changeFontSize.js +60 -60
- package/lib-amd/publicApi/segment/changeFontSize.js.map +1 -1
- package/lib-amd/publicApi/segment/setBackgroundColor.d.ts +7 -7
- package/lib-amd/publicApi/segment/setBackgroundColor.js +34 -34
- package/lib-amd/publicApi/segment/setBackgroundColor.js.map +1 -1
- package/lib-amd/publicApi/segment/setFontName.d.ts +7 -7
- package/lib-amd/publicApi/segment/setFontName.js +19 -19
- package/lib-amd/publicApi/segment/setFontName.js.map +1 -1
- package/lib-amd/publicApi/segment/setFontSize.d.ts +12 -12
- package/lib-amd/publicApi/segment/setFontSize.js +34 -34
- package/lib-amd/publicApi/segment/setFontSize.js.map +1 -1
- package/lib-amd/publicApi/segment/setTextColor.d.ts +7 -7
- package/lib-amd/publicApi/segment/setTextColor.js +26 -26
- package/lib-amd/publicApi/segment/setTextColor.js.map +1 -1
- package/lib-amd/publicApi/segment/toggleBold.d.ts +6 -6
- package/lib-amd/publicApi/segment/toggleBold.js +20 -20
- package/lib-amd/publicApi/segment/toggleBold.js.map +1 -1
- package/lib-amd/publicApi/segment/toggleCode.d.ts +6 -6
- package/lib-amd/publicApi/segment/toggleCode.js +27 -27
- package/lib-amd/publicApi/segment/toggleCode.js.map +1 -1
- package/lib-amd/publicApi/segment/toggleItalic.d.ts +6 -6
- package/lib-amd/publicApi/segment/toggleItalic.js +15 -15
- package/lib-amd/publicApi/segment/toggleItalic.js.map +1 -1
- package/lib-amd/publicApi/segment/toggleStrikethrough.d.ts +6 -6
- package/lib-amd/publicApi/segment/toggleStrikethrough.js +15 -15
- package/lib-amd/publicApi/segment/toggleStrikethrough.js.map +1 -1
- package/lib-amd/publicApi/segment/toggleSubscript.d.ts +6 -6
- package/lib-amd/publicApi/segment/toggleSubscript.js +15 -15
- package/lib-amd/publicApi/segment/toggleSubscript.js.map +1 -1
- package/lib-amd/publicApi/segment/toggleSuperscript.d.ts +6 -6
- package/lib-amd/publicApi/segment/toggleSuperscript.js +15 -15
- package/lib-amd/publicApi/segment/toggleSuperscript.js.map +1 -1
- package/lib-amd/publicApi/segment/toggleUnderline.d.ts +6 -6
- package/lib-amd/publicApi/segment/toggleUnderline.js +18 -18
- package/lib-amd/publicApi/segment/toggleUnderline.js.map +1 -1
- package/lib-amd/publicApi/table/applyTableBorderFormat.d.ts +8 -8
- package/lib-amd/publicApi/table/applyTableBorderFormat.js +292 -292
- package/lib-amd/publicApi/table/applyTableBorderFormat.js.map +1 -1
- package/lib-amd/publicApi/table/editTable.d.ts +7 -7
- package/lib-amd/publicApi/table/editTable.js +66 -88
- package/lib-amd/publicApi/table/editTable.js.map +1 -1
- package/lib-amd/publicApi/table/formatTable.d.ts +8 -8
- package/lib-amd/publicApi/table/formatTable.js +37 -37
- package/lib-amd/publicApi/table/formatTable.js.map +1 -1
- package/lib-amd/publicApi/table/insertTable.d.ts +11 -11
- package/lib-amd/publicApi/table/insertTable.js +45 -45
- package/lib-amd/publicApi/table/insertTable.js.map +1 -1
- package/lib-amd/publicApi/table/setTableCellShade.d.ts +7 -7
- package/lib-amd/publicApi/table/setTableCellShade.js +32 -32
- package/lib-amd/publicApi/table/setTableCellShade.js.map +1 -1
- package/lib-amd/publicApi/utils/formatImageWithContentModel.d.ts +5 -5
- package/lib-amd/publicApi/utils/formatImageWithContentModel.js +15 -15
- package/lib-amd/publicApi/utils/formatImageWithContentModel.js.map +1 -1
- package/lib-amd/publicApi/utils/formatParagraphWithContentModel.d.ts +5 -5
- package/lib-amd/publicApi/utils/formatParagraphWithContentModel.js +19 -19
- package/lib-amd/publicApi/utils/formatParagraphWithContentModel.js.map +1 -1
- package/lib-amd/publicApi/utils/formatSegmentWithContentModel.d.ts +5 -5
- package/lib-amd/publicApi/utils/formatSegmentWithContentModel.js +45 -45
- package/lib-amd/publicApi/utils/formatSegmentWithContentModel.js.map +1 -1
- package/lib-amd/publicApi/utils/formatTableWithContentModel.d.ts +9 -0
- package/lib-amd/publicApi/utils/formatTableWithContentModel.js +42 -0
- package/lib-amd/publicApi/utils/formatTableWithContentModel.js.map +1 -0
- package/lib-mjs/index.d.ts +48 -42
- package/lib-mjs/index.js +48 -42
- package/lib-mjs/index.js.map +1 -1
- package/lib-mjs/modelApi/block/setModelAlignment.d.ts +5 -5
- package/lib-mjs/modelApi/block/setModelAlignment.js +58 -58
- package/lib-mjs/modelApi/block/setModelAlignment.js.map +1 -1
- package/lib-mjs/modelApi/block/setModelDirection.d.ts +5 -5
- package/lib-mjs/modelApi/block/setModelDirection.js +64 -65
- package/lib-mjs/modelApi/block/setModelDirection.js.map +1 -1
- package/lib-mjs/modelApi/block/setModelIndentation.d.ts +8 -5
- package/lib-mjs/modelApi/block/setModelIndentation.js +134 -43
- package/lib-mjs/modelApi/block/setModelIndentation.js.map +1 -1
- package/lib-mjs/modelApi/block/toggleModelBlockQuote.d.ts +5 -5
- package/lib-mjs/modelApi/block/toggleModelBlockQuote.js +46 -44
- package/lib-mjs/modelApi/block/toggleModelBlockQuote.js.map +1 -1
- package/lib-mjs/modelApi/common/clearModelFormat.d.ts +5 -5
- package/lib-mjs/modelApi/common/clearModelFormat.js +125 -125
- package/lib-mjs/modelApi/common/clearModelFormat.js.map +1 -1
- package/lib-mjs/modelApi/common/wrapBlock.d.ts +16 -16
- package/lib-mjs/modelApi/common/wrapBlock.js +43 -39
- package/lib-mjs/modelApi/common/wrapBlock.js.map +1 -1
- package/lib-mjs/modelApi/entity/insertEntityModel.d.ts +5 -5
- package/lib-mjs/modelApi/entity/insertEntityModel.js +75 -71
- package/lib-mjs/modelApi/entity/insertEntityModel.js.map +1 -1
- package/lib-mjs/modelApi/image/applyImageBorderFormat.d.ts +5 -5
- package/lib-mjs/modelApi/image/applyImageBorderFormat.js +54 -54
- package/lib-mjs/modelApi/image/applyImageBorderFormat.js.map +1 -1
- package/lib-mjs/modelApi/link/matchLink.d.ts +29 -0
- package/lib-mjs/modelApi/link/matchLink.js +91 -0
- package/lib-mjs/modelApi/link/matchLink.js.map +1 -0
- package/lib-mjs/modelApi/list/findListItemsInSameThread.d.ts +7 -5
- package/lib-mjs/modelApi/list/findListItemsInSameThread.js +110 -108
- package/lib-mjs/modelApi/list/findListItemsInSameThread.js.map +1 -1
- package/lib-mjs/modelApi/list/setListType.d.ts +7 -5
- package/lib-mjs/modelApi/list/setListType.js +109 -112
- package/lib-mjs/modelApi/list/setListType.js.map +1 -1
- package/lib-mjs/modelApi/selection/adjustSegmentSelection.d.ts +5 -5
- package/lib-mjs/modelApi/selection/adjustSegmentSelection.js +43 -43
- package/lib-mjs/modelApi/selection/adjustSegmentSelection.js.map +1 -1
- package/lib-mjs/modelApi/selection/adjustTrailingSpaceSelection.d.ts +6 -6
- package/lib-mjs/modelApi/selection/adjustTrailingSpaceSelection.js +51 -51
- package/lib-mjs/modelApi/selection/adjustTrailingSpaceSelection.js.map +1 -1
- package/lib-mjs/modelApi/selection/adjustWordSelection.d.ts +5 -5
- package/lib-mjs/modelApi/selection/adjustWordSelection.js +117 -117
- package/lib-mjs/modelApi/selection/adjustWordSelection.js.map +1 -1
- package/lib-mjs/modelApi/selection/collapseTableSelection.d.ts +5 -5
- package/lib-mjs/modelApi/selection/collapseTableSelection.js +12 -12
- package/lib-mjs/modelApi/selection/collapseTableSelection.js.map +1 -1
- package/lib-mjs/modelApi/table/alignTable.d.ts +5 -5
- package/lib-mjs/modelApi/table/alignTable.js +8 -8
- package/lib-mjs/modelApi/table/alignTable.js.map +1 -1
- package/lib-mjs/modelApi/table/alignTableCell.d.ts +9 -9
- package/lib-mjs/modelApi/table/alignTableCell.js +53 -53
- package/lib-mjs/modelApi/table/alignTableCell.js.map +1 -1
- package/lib-mjs/modelApi/table/canMergeCells.d.ts +5 -5
- package/lib-mjs/modelApi/table/canMergeCells.js +52 -52
- package/lib-mjs/modelApi/table/canMergeCells.js.map +1 -1
- package/lib-mjs/modelApi/table/clearSelectedCells.d.ts +8 -0
- package/lib-mjs/modelApi/table/clearSelectedCells.js +23 -0
- package/lib-mjs/modelApi/table/clearSelectedCells.js.map +1 -0
- package/lib-mjs/modelApi/table/createTableStructure.d.ts +5 -5
- package/lib-mjs/modelApi/table/createTableStructure.js +15 -15
- package/lib-mjs/modelApi/table/createTableStructure.js.map +1 -1
- package/lib-mjs/modelApi/table/deleteTable.d.ts +5 -5
- package/lib-mjs/modelApi/table/deleteTable.js +7 -7
- package/lib-mjs/modelApi/table/deleteTable.js.map +1 -1
- package/lib-mjs/modelApi/table/deleteTableColumn.d.ts +5 -5
- package/lib-mjs/modelApi/table/deleteTableColumn.js +20 -20
- package/lib-mjs/modelApi/table/deleteTableColumn.js.map +1 -1
- package/lib-mjs/modelApi/table/deleteTableRow.d.ts +5 -5
- package/lib-mjs/modelApi/table/deleteTableRow.js +19 -19
- package/lib-mjs/modelApi/table/deleteTableRow.js.map +1 -1
- package/lib-mjs/modelApi/table/ensureFocusableParagraphForTable.d.ts +8 -8
- package/lib-mjs/modelApi/table/ensureFocusableParagraphForTable.js +52 -52
- package/lib-mjs/modelApi/table/ensureFocusableParagraphForTable.js.map +1 -1
- package/lib-mjs/modelApi/table/insertTableColumn.d.ts +7 -5
- package/lib-mjs/modelApi/table/insertTableColumn.js +24 -18
- package/lib-mjs/modelApi/table/insertTableColumn.js.map +1 -1
- package/lib-mjs/modelApi/table/insertTableRow.d.ts +7 -5
- package/lib-mjs/modelApi/table/insertTableRow.js +28 -22
- package/lib-mjs/modelApi/table/insertTableRow.js.map +1 -1
- package/lib-mjs/modelApi/table/mergeTableCells.d.ts +5 -5
- package/lib-mjs/modelApi/table/mergeTableCells.js +22 -22
- package/lib-mjs/modelApi/table/mergeTableCells.js.map +1 -1
- package/lib-mjs/modelApi/table/mergeTableColumn.d.ts +5 -5
- package/lib-mjs/modelApi/table/mergeTableColumn.js +33 -33
- package/lib-mjs/modelApi/table/mergeTableColumn.js.map +1 -1
- package/lib-mjs/modelApi/table/mergeTableRow.d.ts +5 -5
- package/lib-mjs/modelApi/table/mergeTableRow.js +34 -34
- package/lib-mjs/modelApi/table/mergeTableRow.js.map +1 -1
- package/lib-mjs/modelApi/table/splitTableCellHorizontally.d.ts +5 -5
- package/lib-mjs/modelApi/table/splitTableCellHorizontally.js +50 -50
- package/lib-mjs/modelApi/table/splitTableCellHorizontally.js.map +1 -1
- package/lib-mjs/modelApi/table/splitTableCellVertically.d.ts +5 -5
- package/lib-mjs/modelApi/table/splitTableCellVertically.js +53 -53
- package/lib-mjs/modelApi/table/splitTableCellVertically.js.map +1 -1
- package/lib-mjs/publicApi/block/setAlignment.d.ts +7 -7
- package/lib-mjs/publicApi/block/setAlignment.js +12 -12
- package/lib-mjs/publicApi/block/setAlignment.js.map +1 -1
- package/lib-mjs/publicApi/block/setDirection.d.ts +7 -7
- package/lib-mjs/publicApi/block/setDirection.js +12 -12
- package/lib-mjs/publicApi/block/setDirection.js.map +1 -1
- package/lib-mjs/publicApi/block/setHeadingLevel.d.ts +7 -7
- package/lib-mjs/publicApi/block/setHeadingLevel.js +46 -46
- package/lib-mjs/publicApi/block/setHeadingLevel.js.map +1 -1
- package/lib-mjs/publicApi/block/setIndentation.d.ts +8 -8
- package/lib-mjs/publicApi/block/setIndentation.js +21 -21
- package/lib-mjs/publicApi/block/setIndentation.js.map +1 -1
- package/lib-mjs/publicApi/block/setParagraphMargin.d.ts +9 -9
- package/lib-mjs/publicApi/block/setParagraphMargin.js +29 -29
- package/lib-mjs/publicApi/block/setParagraphMargin.js.map +1 -1
- package/lib-mjs/publicApi/block/setSpacing.d.ts +7 -7
- package/lib-mjs/publicApi/block/setSpacing.js +17 -17
- package/lib-mjs/publicApi/block/setSpacing.js.map +1 -1
- package/lib-mjs/publicApi/block/toggleBlockQuote.d.ts +9 -9
- package/lib-mjs/publicApi/block/toggleBlockQuote.js +35 -31
- package/lib-mjs/publicApi/block/toggleBlockQuote.js.map +1 -1
- package/lib-mjs/publicApi/entity/insertEntity.d.ts +25 -25
- package/lib-mjs/publicApi/entity/insertEntity.js +38 -37
- package/lib-mjs/publicApi/entity/insertEntity.js.map +1 -1
- package/lib-mjs/publicApi/format/clearFormat.d.ts +6 -6
- package/lib-mjs/publicApi/format/clearFormat.js +19 -19
- package/lib-mjs/publicApi/format/clearFormat.js.map +1 -1
- package/lib-mjs/publicApi/format/getFormatState.d.ts +6 -26
- package/lib-mjs/publicApi/format/getFormatState.js +17 -83
- package/lib-mjs/publicApi/format/getFormatState.js.map +1 -1
- package/lib-mjs/publicApi/image/adjustImageSelection.d.ts +6 -6
- package/lib-mjs/publicApi/image/adjustImageSelection.js +22 -22
- package/lib-mjs/publicApi/image/adjustImageSelection.js.map +1 -1
- package/lib-mjs/publicApi/image/changeImage.d.ts +7 -7
- package/lib-mjs/publicApi/image/changeImage.js +31 -31
- package/lib-mjs/publicApi/image/changeImage.js.map +1 -1
- package/lib-mjs/publicApi/image/insertImage.d.ts +7 -7
- package/lib-mjs/publicApi/image/insertImage.js +33 -33
- package/lib-mjs/publicApi/image/insertImage.js.map +1 -1
- package/lib-mjs/publicApi/image/setImageAltText.d.ts +8 -8
- package/lib-mjs/publicApi/image/setImageAltText.js +13 -13
- package/lib-mjs/publicApi/image/setImageAltText.js.map +1 -1
- package/lib-mjs/publicApi/image/setImageBorder.d.ts +9 -9
- package/lib-mjs/publicApi/image/setImageBorder.js +15 -15
- package/lib-mjs/publicApi/image/setImageBorder.js.map +1 -1
- package/lib-mjs/publicApi/image/setImageBoxShadow.d.ts +8 -8
- package/lib-mjs/publicApi/image/setImageBoxShadow.js +25 -25
- package/lib-mjs/publicApi/image/setImageBoxShadow.js.map +1 -1
- package/lib-mjs/publicApi/link/adjustLinkSelection.d.ts +6 -6
- package/lib-mjs/publicApi/link/adjustLinkSelection.js +30 -30
- package/lib-mjs/publicApi/link/adjustLinkSelection.js.map +1 -1
- package/lib-mjs/publicApi/link/insertLink.d.ts +15 -15
- package/lib-mjs/publicApi/link/insertLink.js +116 -125
- package/lib-mjs/publicApi/link/insertLink.js.map +1 -1
- package/lib-mjs/publicApi/link/removeLink.d.ts +8 -8
- package/lib-mjs/publicApi/link/removeLink.js +28 -28
- package/lib-mjs/publicApi/link/removeLink.js.map +1 -1
- package/lib-mjs/publicApi/list/setListStartNumber.d.ts +7 -7
- package/lib-mjs/publicApi/list/setListStartNumber.js +22 -22
- package/lib-mjs/publicApi/list/setListStartNumber.js.map +1 -1
- package/lib-mjs/publicApi/list/setListStyle.d.ts +7 -7
- package/lib-mjs/publicApi/list/setListStyle.js +29 -29
- package/lib-mjs/publicApi/list/setListStyle.js.map +1 -1
- package/lib-mjs/publicApi/list/toggleBullet.d.ts +8 -8
- package/lib-mjs/publicApi/list/toggleBullet.js +16 -16
- package/lib-mjs/publicApi/list/toggleBullet.js.map +1 -1
- package/lib-mjs/publicApi/list/toggleNumbering.d.ts +8 -8
- package/lib-mjs/publicApi/list/toggleNumbering.js +16 -16
- package/lib-mjs/publicApi/list/toggleNumbering.js.map +1 -1
- package/lib-mjs/publicApi/segment/applySegmentFormat.d.ts +7 -7
- package/lib-mjs/publicApi/segment/applySegmentFormat.js +19 -19
- package/lib-mjs/publicApi/segment/applySegmentFormat.js.map +1 -1
- package/lib-mjs/publicApi/segment/changeCapitalization.d.ts +10 -10
- package/lib-mjs/publicApi/segment/changeCapitalization.js +45 -46
- package/lib-mjs/publicApi/segment/changeCapitalization.js.map +1 -1
- package/lib-mjs/publicApi/segment/changeFontSize.d.ts +8 -8
- package/lib-mjs/publicApi/segment/changeFontSize.js +58 -58
- package/lib-mjs/publicApi/segment/changeFontSize.js.map +1 -1
- package/lib-mjs/publicApi/segment/setBackgroundColor.d.ts +7 -7
- package/lib-mjs/publicApi/segment/setBackgroundColor.js +32 -32
- package/lib-mjs/publicApi/segment/setBackgroundColor.js.map +1 -1
- package/lib-mjs/publicApi/segment/setFontName.d.ts +7 -7
- package/lib-mjs/publicApi/segment/setFontName.js +15 -15
- package/lib-mjs/publicApi/segment/setFontName.js.map +1 -1
- package/lib-mjs/publicApi/segment/setFontSize.d.ts +12 -12
- package/lib-mjs/publicApi/segment/setFontSize.js +28 -28
- package/lib-mjs/publicApi/segment/setFontSize.js.map +1 -1
- package/lib-mjs/publicApi/segment/setTextColor.d.ts +7 -7
- package/lib-mjs/publicApi/segment/setTextColor.js +22 -22
- package/lib-mjs/publicApi/segment/setTextColor.js.map +1 -1
- package/lib-mjs/publicApi/segment/toggleBold.d.ts +6 -6
- package/lib-mjs/publicApi/segment/toggleBold.js +17 -17
- package/lib-mjs/publicApi/segment/toggleBold.js.map +1 -1
- package/lib-mjs/publicApi/segment/toggleCode.d.ts +6 -6
- package/lib-mjs/publicApi/segment/toggleCode.js +24 -24
- package/lib-mjs/publicApi/segment/toggleCode.js.map +1 -1
- package/lib-mjs/publicApi/segment/toggleItalic.d.ts +6 -6
- package/lib-mjs/publicApi/segment/toggleItalic.js +11 -11
- package/lib-mjs/publicApi/segment/toggleItalic.js.map +1 -1
- package/lib-mjs/publicApi/segment/toggleStrikethrough.d.ts +6 -6
- package/lib-mjs/publicApi/segment/toggleStrikethrough.js +11 -11
- package/lib-mjs/publicApi/segment/toggleStrikethrough.js.map +1 -1
- package/lib-mjs/publicApi/segment/toggleSubscript.d.ts +6 -6
- package/lib-mjs/publicApi/segment/toggleSubscript.js +11 -11
- package/lib-mjs/publicApi/segment/toggleSubscript.js.map +1 -1
- package/lib-mjs/publicApi/segment/toggleSuperscript.d.ts +6 -6
- package/lib-mjs/publicApi/segment/toggleSuperscript.js +11 -11
- package/lib-mjs/publicApi/segment/toggleSuperscript.js.map +1 -1
- package/lib-mjs/publicApi/segment/toggleUnderline.d.ts +6 -6
- package/lib-mjs/publicApi/segment/toggleUnderline.js +15 -15
- package/lib-mjs/publicApi/segment/toggleUnderline.js.map +1 -1
- package/lib-mjs/publicApi/table/applyTableBorderFormat.d.ts +8 -8
- package/lib-mjs/publicApi/table/applyTableBorderFormat.js +290 -290
- package/lib-mjs/publicApi/table/applyTableBorderFormat.js.map +1 -1
- package/lib-mjs/publicApi/table/editTable.d.ts +7 -7
- package/lib-mjs/publicApi/table/editTable.js +74 -99
- package/lib-mjs/publicApi/table/editTable.js.map +1 -1
- package/lib-mjs/publicApi/table/formatTable.d.ts +8 -8
- package/lib-mjs/publicApi/table/formatTable.js +34 -34
- package/lib-mjs/publicApi/table/formatTable.js.map +1 -1
- package/lib-mjs/publicApi/table/insertTable.d.ts +11 -11
- package/lib-mjs/publicApi/table/insertTable.js +43 -43
- package/lib-mjs/publicApi/table/insertTable.js.map +1 -1
- package/lib-mjs/publicApi/table/setTableCellShade.d.ts +7 -7
- package/lib-mjs/publicApi/table/setTableCellShade.js +29 -29
- package/lib-mjs/publicApi/table/setTableCellShade.js.map +1 -1
- package/lib-mjs/publicApi/utils/formatImageWithContentModel.d.ts +5 -5
- package/lib-mjs/publicApi/utils/formatImageWithContentModel.js +11 -11
- package/lib-mjs/publicApi/utils/formatImageWithContentModel.js.map +1 -1
- package/lib-mjs/publicApi/utils/formatParagraphWithContentModel.d.ts +5 -5
- package/lib-mjs/publicApi/utils/formatParagraphWithContentModel.js +14 -14
- package/lib-mjs/publicApi/utils/formatParagraphWithContentModel.js.map +1 -1
- package/lib-mjs/publicApi/utils/formatSegmentWithContentModel.d.ts +5 -5
- package/lib-mjs/publicApi/utils/formatSegmentWithContentModel.js +42 -42
- package/lib-mjs/publicApi/utils/formatSegmentWithContentModel.js.map +1 -1
- package/lib-mjs/publicApi/utils/formatTableWithContentModel.d.ts +9 -0
- package/lib-mjs/publicApi/utils/formatTableWithContentModel.js +40 -0
- package/lib-mjs/publicApi/utils/formatTableWithContentModel.js.map +1 -0
- package/package.json +4 -6
- package/lib/modelApi/common/retrieveModelFormatState.d.ts +0 -5
- package/lib/modelApi/common/retrieveModelFormatState.js +0 -173
- package/lib/modelApi/common/retrieveModelFormatState.js.map +0 -1
- package/lib-amd/modelApi/common/retrieveModelFormatState.d.ts +0 -5
- package/lib-amd/modelApi/common/retrieveModelFormatState.js +0 -173
- package/lib-amd/modelApi/common/retrieveModelFormatState.js.map +0 -1
- package/lib-mjs/modelApi/common/retrieveModelFormatState.d.ts +0 -5
- package/lib-mjs/modelApi/common/retrieveModelFormatState.js +0 -169
- package/lib-mjs/modelApi/common/retrieveModelFormatState.js.map +0 -1
package/lib-amd/index.d.ts
CHANGED
|
@@ -1,42 +1,48 @@
|
|
|
1
|
-
export { default as insertTable } from './publicApi/table/insertTable';
|
|
2
|
-
export { default as formatTable } from './publicApi/table/formatTable';
|
|
3
|
-
export { default as setTableCellShade } from './publicApi/table/setTableCellShade';
|
|
4
|
-
export { default as editTable } from './publicApi/table/editTable';
|
|
5
|
-
export { default as applyTableBorderFormat } from './publicApi/table/applyTableBorderFormat';
|
|
6
|
-
export { default as toggleBullet } from './publicApi/list/toggleBullet';
|
|
7
|
-
export { default as toggleNumbering } from './publicApi/list/toggleNumbering';
|
|
8
|
-
export { default as toggleBold } from './publicApi/segment/toggleBold';
|
|
9
|
-
export { default as toggleItalic } from './publicApi/segment/toggleItalic';
|
|
10
|
-
export { default as toggleUnderline } from './publicApi/segment/toggleUnderline';
|
|
11
|
-
export { default as toggleStrikethrough } from './publicApi/segment/toggleStrikethrough';
|
|
12
|
-
export { default as toggleSubscript } from './publicApi/segment/toggleSubscript';
|
|
13
|
-
export { default as toggleSuperscript } from './publicApi/segment/toggleSuperscript';
|
|
14
|
-
export { default as setBackgroundColor } from './publicApi/segment/setBackgroundColor';
|
|
15
|
-
export { default as setFontName } from './publicApi/segment/setFontName';
|
|
16
|
-
export { default as setFontSize } from './publicApi/segment/setFontSize';
|
|
17
|
-
export { default as setTextColor } from './publicApi/segment/setTextColor';
|
|
18
|
-
export { default as changeFontSize } from './publicApi/segment/changeFontSize';
|
|
19
|
-
export { default as applySegmentFormat } from './publicApi/segment/applySegmentFormat';
|
|
20
|
-
export { default as changeCapitalization } from './publicApi/segment/changeCapitalization';
|
|
21
|
-
export { default as insertImage } from './publicApi/image/insertImage';
|
|
22
|
-
export { default as setListStyle } from './publicApi/list/setListStyle';
|
|
23
|
-
export { default as setListStartNumber } from './publicApi/list/setListStartNumber';
|
|
24
|
-
export { default as setIndentation } from './publicApi/block/setIndentation';
|
|
25
|
-
export { default as setAlignment } from './publicApi/block/setAlignment';
|
|
26
|
-
export { default as setDirection } from './publicApi/block/setDirection';
|
|
27
|
-
export { default as setHeadingLevel } from './publicApi/block/setHeadingLevel';
|
|
28
|
-
export { default as toggleBlockQuote } from './publicApi/block/toggleBlockQuote';
|
|
29
|
-
export { default as setSpacing } from './publicApi/block/setSpacing';
|
|
30
|
-
export { default as setImageBorder } from './publicApi/image/setImageBorder';
|
|
31
|
-
export { default as setImageBoxShadow } from './publicApi/image/setImageBoxShadow';
|
|
32
|
-
export { default as changeImage } from './publicApi/image/changeImage';
|
|
33
|
-
export { default as getFormatState } from './publicApi/format/getFormatState';
|
|
34
|
-
export { default as clearFormat } from './publicApi/format/clearFormat';
|
|
35
|
-
export { default as insertLink } from './publicApi/link/insertLink';
|
|
36
|
-
export { default as removeLink } from './publicApi/link/removeLink';
|
|
37
|
-
export { default as adjustLinkSelection } from './publicApi/link/adjustLinkSelection';
|
|
38
|
-
export { default as setImageAltText } from './publicApi/image/setImageAltText';
|
|
39
|
-
export { default as adjustImageSelection } from './publicApi/image/adjustImageSelection';
|
|
40
|
-
export { default as setParagraphMargin } from './publicApi/block/setParagraphMargin';
|
|
41
|
-
export { default as toggleCode } from './publicApi/segment/toggleCode';
|
|
42
|
-
export { default as insertEntity } from './publicApi/entity/insertEntity';
|
|
1
|
+
export { default as insertTable } from './publicApi/table/insertTable';
|
|
2
|
+
export { default as formatTable } from './publicApi/table/formatTable';
|
|
3
|
+
export { default as setTableCellShade } from './publicApi/table/setTableCellShade';
|
|
4
|
+
export { default as editTable } from './publicApi/table/editTable';
|
|
5
|
+
export { default as applyTableBorderFormat } from './publicApi/table/applyTableBorderFormat';
|
|
6
|
+
export { default as toggleBullet } from './publicApi/list/toggleBullet';
|
|
7
|
+
export { default as toggleNumbering } from './publicApi/list/toggleNumbering';
|
|
8
|
+
export { default as toggleBold } from './publicApi/segment/toggleBold';
|
|
9
|
+
export { default as toggleItalic } from './publicApi/segment/toggleItalic';
|
|
10
|
+
export { default as toggleUnderline } from './publicApi/segment/toggleUnderline';
|
|
11
|
+
export { default as toggleStrikethrough } from './publicApi/segment/toggleStrikethrough';
|
|
12
|
+
export { default as toggleSubscript } from './publicApi/segment/toggleSubscript';
|
|
13
|
+
export { default as toggleSuperscript } from './publicApi/segment/toggleSuperscript';
|
|
14
|
+
export { default as setBackgroundColor } from './publicApi/segment/setBackgroundColor';
|
|
15
|
+
export { default as setFontName } from './publicApi/segment/setFontName';
|
|
16
|
+
export { default as setFontSize } from './publicApi/segment/setFontSize';
|
|
17
|
+
export { default as setTextColor } from './publicApi/segment/setTextColor';
|
|
18
|
+
export { default as changeFontSize } from './publicApi/segment/changeFontSize';
|
|
19
|
+
export { default as applySegmentFormat } from './publicApi/segment/applySegmentFormat';
|
|
20
|
+
export { default as changeCapitalization } from './publicApi/segment/changeCapitalization';
|
|
21
|
+
export { default as insertImage } from './publicApi/image/insertImage';
|
|
22
|
+
export { default as setListStyle } from './publicApi/list/setListStyle';
|
|
23
|
+
export { default as setListStartNumber } from './publicApi/list/setListStartNumber';
|
|
24
|
+
export { default as setIndentation } from './publicApi/block/setIndentation';
|
|
25
|
+
export { default as setAlignment } from './publicApi/block/setAlignment';
|
|
26
|
+
export { default as setDirection } from './publicApi/block/setDirection';
|
|
27
|
+
export { default as setHeadingLevel } from './publicApi/block/setHeadingLevel';
|
|
28
|
+
export { default as toggleBlockQuote } from './publicApi/block/toggleBlockQuote';
|
|
29
|
+
export { default as setSpacing } from './publicApi/block/setSpacing';
|
|
30
|
+
export { default as setImageBorder } from './publicApi/image/setImageBorder';
|
|
31
|
+
export { default as setImageBoxShadow } from './publicApi/image/setImageBoxShadow';
|
|
32
|
+
export { default as changeImage } from './publicApi/image/changeImage';
|
|
33
|
+
export { default as getFormatState } from './publicApi/format/getFormatState';
|
|
34
|
+
export { default as clearFormat } from './publicApi/format/clearFormat';
|
|
35
|
+
export { default as insertLink } from './publicApi/link/insertLink';
|
|
36
|
+
export { default as removeLink } from './publicApi/link/removeLink';
|
|
37
|
+
export { default as adjustLinkSelection } from './publicApi/link/adjustLinkSelection';
|
|
38
|
+
export { default as setImageAltText } from './publicApi/image/setImageAltText';
|
|
39
|
+
export { default as adjustImageSelection } from './publicApi/image/adjustImageSelection';
|
|
40
|
+
export { default as setParagraphMargin } from './publicApi/block/setParagraphMargin';
|
|
41
|
+
export { default as toggleCode } from './publicApi/segment/toggleCode';
|
|
42
|
+
export { default as insertEntity } from './publicApi/entity/insertEntity';
|
|
43
|
+
export { insertTableRow } from './modelApi/table/insertTableRow';
|
|
44
|
+
export { insertTableColumn } from './modelApi/table/insertTableColumn';
|
|
45
|
+
export { formatTableWithContentModel } from './publicApi/utils/formatTableWithContentModel';
|
|
46
|
+
export { setListType } from './modelApi/list/setListType';
|
|
47
|
+
export { findListItemsInSameThread } from './modelApi/list/findListItemsInSameThread';
|
|
48
|
+
export { setModelIndentation } from './modelApi/block/setModelIndentation';
|
package/lib-amd/index.js
CHANGED
|
@@ -1,48 +1,54 @@
|
|
|
1
|
-
define(["require", "exports", "./publicApi/table/insertTable", "./publicApi/table/formatTable", "./publicApi/table/setTableCellShade", "./publicApi/table/editTable", "./publicApi/table/applyTableBorderFormat", "./publicApi/list/toggleBullet", "./publicApi/list/toggleNumbering", "./publicApi/segment/toggleBold", "./publicApi/segment/toggleItalic", "./publicApi/segment/toggleUnderline", "./publicApi/segment/toggleStrikethrough", "./publicApi/segment/toggleSubscript", "./publicApi/segment/toggleSuperscript", "./publicApi/segment/setBackgroundColor", "./publicApi/segment/setFontName", "./publicApi/segment/setFontSize", "./publicApi/segment/setTextColor", "./publicApi/segment/changeFontSize", "./publicApi/segment/applySegmentFormat", "./publicApi/segment/changeCapitalization", "./publicApi/image/insertImage", "./publicApi/list/setListStyle", "./publicApi/list/setListStartNumber", "./publicApi/block/setIndentation", "./publicApi/block/setAlignment", "./publicApi/block/setDirection", "./publicApi/block/setHeadingLevel", "./publicApi/block/toggleBlockQuote", "./publicApi/block/setSpacing", "./publicApi/image/setImageBorder", "./publicApi/image/setImageBoxShadow", "./publicApi/image/changeImage", "./publicApi/format/getFormatState", "./publicApi/format/clearFormat", "./publicApi/link/insertLink", "./publicApi/link/removeLink", "./publicApi/link/adjustLinkSelection", "./publicApi/image/setImageAltText", "./publicApi/image/adjustImageSelection", "./publicApi/block/setParagraphMargin", "./publicApi/segment/toggleCode", "./publicApi/entity/insertEntity"], function (require, exports, insertTable_1, formatTable_1, setTableCellShade_1, editTable_1, applyTableBorderFormat_1, toggleBullet_1, toggleNumbering_1, toggleBold_1, toggleItalic_1, toggleUnderline_1, toggleStrikethrough_1, toggleSubscript_1, toggleSuperscript_1, setBackgroundColor_1, setFontName_1, setFontSize_1, setTextColor_1, changeFontSize_1, applySegmentFormat_1, changeCapitalization_1, insertImage_1, setListStyle_1, setListStartNumber_1, setIndentation_1, setAlignment_1, setDirection_1, setHeadingLevel_1, toggleBlockQuote_1, setSpacing_1, setImageBorder_1, setImageBoxShadow_1, changeImage_1, getFormatState_1, clearFormat_1, insertLink_1, removeLink_1, adjustLinkSelection_1, setImageAltText_1, adjustImageSelection_1, setParagraphMargin_1, toggleCode_1, insertEntity_1) {
|
|
2
|
-
"use strict";
|
|
3
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.insertEntity = exports.toggleCode = exports.setParagraphMargin = exports.adjustImageSelection = exports.setImageAltText = exports.adjustLinkSelection = exports.removeLink = exports.insertLink = exports.clearFormat = exports.getFormatState = exports.changeImage = exports.setImageBoxShadow = exports.setImageBorder = exports.setSpacing = exports.toggleBlockQuote = exports.setHeadingLevel = exports.setDirection = exports.setAlignment = exports.setIndentation = exports.setListStartNumber = exports.setListStyle = exports.insertImage = exports.changeCapitalization = exports.applySegmentFormat = exports.changeFontSize = exports.setTextColor = exports.setFontSize = exports.setFontName = exports.setBackgroundColor = exports.toggleSuperscript = exports.toggleSubscript = exports.toggleStrikethrough = exports.toggleUnderline = exports.toggleItalic = exports.toggleBold = exports.toggleNumbering = exports.toggleBullet = exports.applyTableBorderFormat = exports.editTable = exports.setTableCellShade = exports.formatTable = exports.insertTable = void 0;
|
|
5
|
-
Object.defineProperty(exports, "insertTable", { enumerable: true, get: function () { return insertTable_1.default; } });
|
|
6
|
-
Object.defineProperty(exports, "formatTable", { enumerable: true, get: function () { return formatTable_1.default; } });
|
|
7
|
-
Object.defineProperty(exports, "setTableCellShade", { enumerable: true, get: function () { return setTableCellShade_1.default; } });
|
|
8
|
-
Object.defineProperty(exports, "editTable", { enumerable: true, get: function () { return editTable_1.default; } });
|
|
9
|
-
Object.defineProperty(exports, "applyTableBorderFormat", { enumerable: true, get: function () { return applyTableBorderFormat_1.default; } });
|
|
10
|
-
Object.defineProperty(exports, "toggleBullet", { enumerable: true, get: function () { return toggleBullet_1.default; } });
|
|
11
|
-
Object.defineProperty(exports, "toggleNumbering", { enumerable: true, get: function () { return toggleNumbering_1.default; } });
|
|
12
|
-
Object.defineProperty(exports, "toggleBold", { enumerable: true, get: function () { return toggleBold_1.default; } });
|
|
13
|
-
Object.defineProperty(exports, "toggleItalic", { enumerable: true, get: function () { return toggleItalic_1.default; } });
|
|
14
|
-
Object.defineProperty(exports, "toggleUnderline", { enumerable: true, get: function () { return toggleUnderline_1.default; } });
|
|
15
|
-
Object.defineProperty(exports, "toggleStrikethrough", { enumerable: true, get: function () { return toggleStrikethrough_1.default; } });
|
|
16
|
-
Object.defineProperty(exports, "toggleSubscript", { enumerable: true, get: function () { return toggleSubscript_1.default; } });
|
|
17
|
-
Object.defineProperty(exports, "toggleSuperscript", { enumerable: true, get: function () { return toggleSuperscript_1.default; } });
|
|
18
|
-
Object.defineProperty(exports, "setBackgroundColor", { enumerable: true, get: function () { return setBackgroundColor_1.default; } });
|
|
19
|
-
Object.defineProperty(exports, "setFontName", { enumerable: true, get: function () { return setFontName_1.default; } });
|
|
20
|
-
Object.defineProperty(exports, "setFontSize", { enumerable: true, get: function () { return setFontSize_1.default; } });
|
|
21
|
-
Object.defineProperty(exports, "setTextColor", { enumerable: true, get: function () { return setTextColor_1.default; } });
|
|
22
|
-
Object.defineProperty(exports, "changeFontSize", { enumerable: true, get: function () { return changeFontSize_1.default; } });
|
|
23
|
-
Object.defineProperty(exports, "applySegmentFormat", { enumerable: true, get: function () { return applySegmentFormat_1.default; } });
|
|
24
|
-
Object.defineProperty(exports, "changeCapitalization", { enumerable: true, get: function () { return changeCapitalization_1.default; } });
|
|
25
|
-
Object.defineProperty(exports, "insertImage", { enumerable: true, get: function () { return insertImage_1.default; } });
|
|
26
|
-
Object.defineProperty(exports, "setListStyle", { enumerable: true, get: function () { return setListStyle_1.default; } });
|
|
27
|
-
Object.defineProperty(exports, "setListStartNumber", { enumerable: true, get: function () { return setListStartNumber_1.default; } });
|
|
28
|
-
Object.defineProperty(exports, "setIndentation", { enumerable: true, get: function () { return setIndentation_1.default; } });
|
|
29
|
-
Object.defineProperty(exports, "setAlignment", { enumerable: true, get: function () { return setAlignment_1.default; } });
|
|
30
|
-
Object.defineProperty(exports, "setDirection", { enumerable: true, get: function () { return setDirection_1.default; } });
|
|
31
|
-
Object.defineProperty(exports, "setHeadingLevel", { enumerable: true, get: function () { return setHeadingLevel_1.default; } });
|
|
32
|
-
Object.defineProperty(exports, "toggleBlockQuote", { enumerable: true, get: function () { return toggleBlockQuote_1.default; } });
|
|
33
|
-
Object.defineProperty(exports, "setSpacing", { enumerable: true, get: function () { return setSpacing_1.default; } });
|
|
34
|
-
Object.defineProperty(exports, "setImageBorder", { enumerable: true, get: function () { return setImageBorder_1.default; } });
|
|
35
|
-
Object.defineProperty(exports, "setImageBoxShadow", { enumerable: true, get: function () { return setImageBoxShadow_1.default; } });
|
|
36
|
-
Object.defineProperty(exports, "changeImage", { enumerable: true, get: function () { return changeImage_1.default; } });
|
|
37
|
-
Object.defineProperty(exports, "getFormatState", { enumerable: true, get: function () { return getFormatState_1.default; } });
|
|
38
|
-
Object.defineProperty(exports, "clearFormat", { enumerable: true, get: function () { return clearFormat_1.default; } });
|
|
39
|
-
Object.defineProperty(exports, "insertLink", { enumerable: true, get: function () { return insertLink_1.default; } });
|
|
40
|
-
Object.defineProperty(exports, "removeLink", { enumerable: true, get: function () { return removeLink_1.default; } });
|
|
41
|
-
Object.defineProperty(exports, "adjustLinkSelection", { enumerable: true, get: function () { return adjustLinkSelection_1.default; } });
|
|
42
|
-
Object.defineProperty(exports, "setImageAltText", { enumerable: true, get: function () { return setImageAltText_1.default; } });
|
|
43
|
-
Object.defineProperty(exports, "adjustImageSelection", { enumerable: true, get: function () { return adjustImageSelection_1.default; } });
|
|
44
|
-
Object.defineProperty(exports, "setParagraphMargin", { enumerable: true, get: function () { return setParagraphMargin_1.default; } });
|
|
45
|
-
Object.defineProperty(exports, "toggleCode", { enumerable: true, get: function () { return toggleCode_1.default; } });
|
|
46
|
-
Object.defineProperty(exports, "insertEntity", { enumerable: true, get: function () { return insertEntity_1.default; } });
|
|
47
|
-
});
|
|
1
|
+
define(["require", "exports", "./publicApi/table/insertTable", "./publicApi/table/formatTable", "./publicApi/table/setTableCellShade", "./publicApi/table/editTable", "./publicApi/table/applyTableBorderFormat", "./publicApi/list/toggleBullet", "./publicApi/list/toggleNumbering", "./publicApi/segment/toggleBold", "./publicApi/segment/toggleItalic", "./publicApi/segment/toggleUnderline", "./publicApi/segment/toggleStrikethrough", "./publicApi/segment/toggleSubscript", "./publicApi/segment/toggleSuperscript", "./publicApi/segment/setBackgroundColor", "./publicApi/segment/setFontName", "./publicApi/segment/setFontSize", "./publicApi/segment/setTextColor", "./publicApi/segment/changeFontSize", "./publicApi/segment/applySegmentFormat", "./publicApi/segment/changeCapitalization", "./publicApi/image/insertImage", "./publicApi/list/setListStyle", "./publicApi/list/setListStartNumber", "./publicApi/block/setIndentation", "./publicApi/block/setAlignment", "./publicApi/block/setDirection", "./publicApi/block/setHeadingLevel", "./publicApi/block/toggleBlockQuote", "./publicApi/block/setSpacing", "./publicApi/image/setImageBorder", "./publicApi/image/setImageBoxShadow", "./publicApi/image/changeImage", "./publicApi/format/getFormatState", "./publicApi/format/clearFormat", "./publicApi/link/insertLink", "./publicApi/link/removeLink", "./publicApi/link/adjustLinkSelection", "./publicApi/image/setImageAltText", "./publicApi/image/adjustImageSelection", "./publicApi/block/setParagraphMargin", "./publicApi/segment/toggleCode", "./publicApi/entity/insertEntity", "./modelApi/table/insertTableRow", "./modelApi/table/insertTableColumn", "./publicApi/utils/formatTableWithContentModel", "./modelApi/list/setListType", "./modelApi/list/findListItemsInSameThread", "./modelApi/block/setModelIndentation"], function (require, exports, insertTable_1, formatTable_1, setTableCellShade_1, editTable_1, applyTableBorderFormat_1, toggleBullet_1, toggleNumbering_1, toggleBold_1, toggleItalic_1, toggleUnderline_1, toggleStrikethrough_1, toggleSubscript_1, toggleSuperscript_1, setBackgroundColor_1, setFontName_1, setFontSize_1, setTextColor_1, changeFontSize_1, applySegmentFormat_1, changeCapitalization_1, insertImage_1, setListStyle_1, setListStartNumber_1, setIndentation_1, setAlignment_1, setDirection_1, setHeadingLevel_1, toggleBlockQuote_1, setSpacing_1, setImageBorder_1, setImageBoxShadow_1, changeImage_1, getFormatState_1, clearFormat_1, insertLink_1, removeLink_1, adjustLinkSelection_1, setImageAltText_1, adjustImageSelection_1, setParagraphMargin_1, toggleCode_1, insertEntity_1, insertTableRow_1, insertTableColumn_1, formatTableWithContentModel_1, setListType_1, findListItemsInSameThread_1, setModelIndentation_1) {
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.setModelIndentation = exports.findListItemsInSameThread = exports.setListType = exports.formatTableWithContentModel = exports.insertTableColumn = exports.insertTableRow = exports.insertEntity = exports.toggleCode = exports.setParagraphMargin = exports.adjustImageSelection = exports.setImageAltText = exports.adjustLinkSelection = exports.removeLink = exports.insertLink = exports.clearFormat = exports.getFormatState = exports.changeImage = exports.setImageBoxShadow = exports.setImageBorder = exports.setSpacing = exports.toggleBlockQuote = exports.setHeadingLevel = exports.setDirection = exports.setAlignment = exports.setIndentation = exports.setListStartNumber = exports.setListStyle = exports.insertImage = exports.changeCapitalization = exports.applySegmentFormat = exports.changeFontSize = exports.setTextColor = exports.setFontSize = exports.setFontName = exports.setBackgroundColor = exports.toggleSuperscript = exports.toggleSubscript = exports.toggleStrikethrough = exports.toggleUnderline = exports.toggleItalic = exports.toggleBold = exports.toggleNumbering = exports.toggleBullet = exports.applyTableBorderFormat = exports.editTable = exports.setTableCellShade = exports.formatTable = exports.insertTable = void 0;
|
|
5
|
+
Object.defineProperty(exports, "insertTable", { enumerable: true, get: function () { return insertTable_1.default; } });
|
|
6
|
+
Object.defineProperty(exports, "formatTable", { enumerable: true, get: function () { return formatTable_1.default; } });
|
|
7
|
+
Object.defineProperty(exports, "setTableCellShade", { enumerable: true, get: function () { return setTableCellShade_1.default; } });
|
|
8
|
+
Object.defineProperty(exports, "editTable", { enumerable: true, get: function () { return editTable_1.default; } });
|
|
9
|
+
Object.defineProperty(exports, "applyTableBorderFormat", { enumerable: true, get: function () { return applyTableBorderFormat_1.default; } });
|
|
10
|
+
Object.defineProperty(exports, "toggleBullet", { enumerable: true, get: function () { return toggleBullet_1.default; } });
|
|
11
|
+
Object.defineProperty(exports, "toggleNumbering", { enumerable: true, get: function () { return toggleNumbering_1.default; } });
|
|
12
|
+
Object.defineProperty(exports, "toggleBold", { enumerable: true, get: function () { return toggleBold_1.default; } });
|
|
13
|
+
Object.defineProperty(exports, "toggleItalic", { enumerable: true, get: function () { return toggleItalic_1.default; } });
|
|
14
|
+
Object.defineProperty(exports, "toggleUnderline", { enumerable: true, get: function () { return toggleUnderline_1.default; } });
|
|
15
|
+
Object.defineProperty(exports, "toggleStrikethrough", { enumerable: true, get: function () { return toggleStrikethrough_1.default; } });
|
|
16
|
+
Object.defineProperty(exports, "toggleSubscript", { enumerable: true, get: function () { return toggleSubscript_1.default; } });
|
|
17
|
+
Object.defineProperty(exports, "toggleSuperscript", { enumerable: true, get: function () { return toggleSuperscript_1.default; } });
|
|
18
|
+
Object.defineProperty(exports, "setBackgroundColor", { enumerable: true, get: function () { return setBackgroundColor_1.default; } });
|
|
19
|
+
Object.defineProperty(exports, "setFontName", { enumerable: true, get: function () { return setFontName_1.default; } });
|
|
20
|
+
Object.defineProperty(exports, "setFontSize", { enumerable: true, get: function () { return setFontSize_1.default; } });
|
|
21
|
+
Object.defineProperty(exports, "setTextColor", { enumerable: true, get: function () { return setTextColor_1.default; } });
|
|
22
|
+
Object.defineProperty(exports, "changeFontSize", { enumerable: true, get: function () { return changeFontSize_1.default; } });
|
|
23
|
+
Object.defineProperty(exports, "applySegmentFormat", { enumerable: true, get: function () { return applySegmentFormat_1.default; } });
|
|
24
|
+
Object.defineProperty(exports, "changeCapitalization", { enumerable: true, get: function () { return changeCapitalization_1.default; } });
|
|
25
|
+
Object.defineProperty(exports, "insertImage", { enumerable: true, get: function () { return insertImage_1.default; } });
|
|
26
|
+
Object.defineProperty(exports, "setListStyle", { enumerable: true, get: function () { return setListStyle_1.default; } });
|
|
27
|
+
Object.defineProperty(exports, "setListStartNumber", { enumerable: true, get: function () { return setListStartNumber_1.default; } });
|
|
28
|
+
Object.defineProperty(exports, "setIndentation", { enumerable: true, get: function () { return setIndentation_1.default; } });
|
|
29
|
+
Object.defineProperty(exports, "setAlignment", { enumerable: true, get: function () { return setAlignment_1.default; } });
|
|
30
|
+
Object.defineProperty(exports, "setDirection", { enumerable: true, get: function () { return setDirection_1.default; } });
|
|
31
|
+
Object.defineProperty(exports, "setHeadingLevel", { enumerable: true, get: function () { return setHeadingLevel_1.default; } });
|
|
32
|
+
Object.defineProperty(exports, "toggleBlockQuote", { enumerable: true, get: function () { return toggleBlockQuote_1.default; } });
|
|
33
|
+
Object.defineProperty(exports, "setSpacing", { enumerable: true, get: function () { return setSpacing_1.default; } });
|
|
34
|
+
Object.defineProperty(exports, "setImageBorder", { enumerable: true, get: function () { return setImageBorder_1.default; } });
|
|
35
|
+
Object.defineProperty(exports, "setImageBoxShadow", { enumerable: true, get: function () { return setImageBoxShadow_1.default; } });
|
|
36
|
+
Object.defineProperty(exports, "changeImage", { enumerable: true, get: function () { return changeImage_1.default; } });
|
|
37
|
+
Object.defineProperty(exports, "getFormatState", { enumerable: true, get: function () { return getFormatState_1.default; } });
|
|
38
|
+
Object.defineProperty(exports, "clearFormat", { enumerable: true, get: function () { return clearFormat_1.default; } });
|
|
39
|
+
Object.defineProperty(exports, "insertLink", { enumerable: true, get: function () { return insertLink_1.default; } });
|
|
40
|
+
Object.defineProperty(exports, "removeLink", { enumerable: true, get: function () { return removeLink_1.default; } });
|
|
41
|
+
Object.defineProperty(exports, "adjustLinkSelection", { enumerable: true, get: function () { return adjustLinkSelection_1.default; } });
|
|
42
|
+
Object.defineProperty(exports, "setImageAltText", { enumerable: true, get: function () { return setImageAltText_1.default; } });
|
|
43
|
+
Object.defineProperty(exports, "adjustImageSelection", { enumerable: true, get: function () { return adjustImageSelection_1.default; } });
|
|
44
|
+
Object.defineProperty(exports, "setParagraphMargin", { enumerable: true, get: function () { return setParagraphMargin_1.default; } });
|
|
45
|
+
Object.defineProperty(exports, "toggleCode", { enumerable: true, get: function () { return toggleCode_1.default; } });
|
|
46
|
+
Object.defineProperty(exports, "insertEntity", { enumerable: true, get: function () { return insertEntity_1.default; } });
|
|
47
|
+
Object.defineProperty(exports, "insertTableRow", { enumerable: true, get: function () { return insertTableRow_1.insertTableRow; } });
|
|
48
|
+
Object.defineProperty(exports, "insertTableColumn", { enumerable: true, get: function () { return insertTableColumn_1.insertTableColumn; } });
|
|
49
|
+
Object.defineProperty(exports, "formatTableWithContentModel", { enumerable: true, get: function () { return formatTableWithContentModel_1.formatTableWithContentModel; } });
|
|
50
|
+
Object.defineProperty(exports, "setListType", { enumerable: true, get: function () { return setListType_1.setListType; } });
|
|
51
|
+
Object.defineProperty(exports, "findListItemsInSameThread", { enumerable: true, get: function () { return findListItemsInSameThread_1.findListItemsInSameThread; } });
|
|
52
|
+
Object.defineProperty(exports, "setModelIndentation", { enumerable: true, get: function () { return setModelIndentation_1.setModelIndentation; } });
|
|
53
|
+
});
|
|
48
54
|
//# sourceMappingURL=index.js.map
|
package/lib-amd/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../packages-content-model/roosterjs-content-model-api/lib/index.ts"],"names":[],"mappings":";;;;IAAS,0GAAA,OAAO,OAAe;IACtB,0GAAA,OAAO,OAAe;IACtB,sHAAA,OAAO,OAAqB;IAC5B,sGAAA,OAAO,OAAa;IACpB,gIAAA,OAAO,OAA0B;IACjC,4GAAA,OAAO,OAAgB;IACvB,kHAAA,OAAO,OAAmB;IAC1B,wGAAA,OAAO,OAAc;IACrB,4GAAA,OAAO,OAAgB;IACvB,kHAAA,OAAO,OAAmB;IAC1B,0HAAA,OAAO,OAAuB;IAC9B,kHAAA,OAAO,OAAmB;IAC1B,sHAAA,OAAO,OAAqB;IAC5B,wHAAA,OAAO,OAAsB;IAC7B,0GAAA,OAAO,OAAe;IACtB,0GAAA,OAAO,OAAe;IACtB,4GAAA,OAAO,OAAgB;IACvB,gHAAA,OAAO,OAAkB;IACzB,wHAAA,OAAO,OAAsB;IAC7B,4HAAA,OAAO,OAAwB;IAC/B,0GAAA,OAAO,OAAe;IACtB,4GAAA,OAAO,OAAgB;IACvB,wHAAA,OAAO,OAAsB;IAC7B,gHAAA,OAAO,OAAkB;IACzB,4GAAA,OAAO,OAAgB;IACvB,4GAAA,OAAO,OAAgB;IACvB,kHAAA,OAAO,OAAmB;IAC1B,oHAAA,OAAO,OAAoB;IAC3B,wGAAA,OAAO,OAAc;IACrB,gHAAA,OAAO,OAAkB;IACzB,sHAAA,OAAO,OAAqB;IAC5B,0GAAA,OAAO,OAAe;IACtB,gHAAA,OAAO,OAAkB;IACzB,0GAAA,OAAO,OAAe;IACtB,wGAAA,OAAO,OAAc;IACrB,wGAAA,OAAO,OAAc;IACrB,0HAAA,OAAO,OAAuB;IAC9B,kHAAA,OAAO,OAAmB;IAC1B,4HAAA,OAAO,OAAwB;IAC/B,wHAAA,OAAO,OAAsB;IAC7B,wGAAA,OAAO,OAAc;IACrB,4GAAA,OAAO,OAAgB","sourcesContent":["export { default as insertTable } from './publicApi/table/insertTable';\nexport { default as formatTable } from './publicApi/table/formatTable';\nexport { default as setTableCellShade } from './publicApi/table/setTableCellShade';\nexport { default as editTable } from './publicApi/table/editTable';\nexport { default as applyTableBorderFormat } from './publicApi/table/applyTableBorderFormat';\nexport { default as toggleBullet } from './publicApi/list/toggleBullet';\nexport { default as toggleNumbering } from './publicApi/list/toggleNumbering';\nexport { default as toggleBold } from './publicApi/segment/toggleBold';\nexport { default as toggleItalic } from './publicApi/segment/toggleItalic';\nexport { default as toggleUnderline } from './publicApi/segment/toggleUnderline';\nexport { default as toggleStrikethrough } from './publicApi/segment/toggleStrikethrough';\nexport { default as toggleSubscript } from './publicApi/segment/toggleSubscript';\nexport { default as toggleSuperscript } from './publicApi/segment/toggleSuperscript';\nexport { default as setBackgroundColor } from './publicApi/segment/setBackgroundColor';\nexport { default as setFontName } from './publicApi/segment/setFontName';\nexport { default as setFontSize } from './publicApi/segment/setFontSize';\nexport { default as setTextColor } from './publicApi/segment/setTextColor';\nexport { default as changeFontSize } from './publicApi/segment/changeFontSize';\nexport { default as applySegmentFormat } from './publicApi/segment/applySegmentFormat';\nexport { default as changeCapitalization } from './publicApi/segment/changeCapitalization';\nexport { default as insertImage } from './publicApi/image/insertImage';\nexport { default as setListStyle } from './publicApi/list/setListStyle';\nexport { default as setListStartNumber } from './publicApi/list/setListStartNumber';\nexport { default as setIndentation } from './publicApi/block/setIndentation';\nexport { default as setAlignment } from './publicApi/block/setAlignment';\nexport { default as setDirection } from './publicApi/block/setDirection';\nexport { default as setHeadingLevel } from './publicApi/block/setHeadingLevel';\nexport { default as toggleBlockQuote } from './publicApi/block/toggleBlockQuote';\nexport { default as setSpacing } from './publicApi/block/setSpacing';\nexport { default as setImageBorder } from './publicApi/image/setImageBorder';\nexport { default as setImageBoxShadow } from './publicApi/image/setImageBoxShadow';\nexport { default as changeImage } from './publicApi/image/changeImage';\nexport { default as getFormatState } from './publicApi/format/getFormatState';\nexport { default as clearFormat } from './publicApi/format/clearFormat';\nexport { default as insertLink } from './publicApi/link/insertLink';\nexport { default as removeLink } from './publicApi/link/removeLink';\nexport { default as adjustLinkSelection } from './publicApi/link/adjustLinkSelection';\nexport { default as setImageAltText } from './publicApi/image/setImageAltText';\nexport { default as adjustImageSelection } from './publicApi/image/adjustImageSelection';\nexport { default as setParagraphMargin } from './publicApi/block/setParagraphMargin';\nexport { default as toggleCode } from './publicApi/segment/toggleCode';\nexport { default as insertEntity } from './publicApi/entity/insertEntity';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../packages-content-model/roosterjs-content-model-api/lib/index.ts"],"names":[],"mappings":";;;;IAAS,0GAAA,OAAO,OAAe;IACtB,0GAAA,OAAO,OAAe;IACtB,sHAAA,OAAO,OAAqB;IAC5B,sGAAA,OAAO,OAAa;IACpB,gIAAA,OAAO,OAA0B;IACjC,4GAAA,OAAO,OAAgB;IACvB,kHAAA,OAAO,OAAmB;IAC1B,wGAAA,OAAO,OAAc;IACrB,4GAAA,OAAO,OAAgB;IACvB,kHAAA,OAAO,OAAmB;IAC1B,0HAAA,OAAO,OAAuB;IAC9B,kHAAA,OAAO,OAAmB;IAC1B,sHAAA,OAAO,OAAqB;IAC5B,wHAAA,OAAO,OAAsB;IAC7B,0GAAA,OAAO,OAAe;IACtB,0GAAA,OAAO,OAAe;IACtB,4GAAA,OAAO,OAAgB;IACvB,gHAAA,OAAO,OAAkB;IACzB,wHAAA,OAAO,OAAsB;IAC7B,4HAAA,OAAO,OAAwB;IAC/B,0GAAA,OAAO,OAAe;IACtB,4GAAA,OAAO,OAAgB;IACvB,wHAAA,OAAO,OAAsB;IAC7B,gHAAA,OAAO,OAAkB;IACzB,4GAAA,OAAO,OAAgB;IACvB,4GAAA,OAAO,OAAgB;IACvB,kHAAA,OAAO,OAAmB;IAC1B,oHAAA,OAAO,OAAoB;IAC3B,wGAAA,OAAO,OAAc;IACrB,gHAAA,OAAO,OAAkB;IACzB,sHAAA,OAAO,OAAqB;IAC5B,0GAAA,OAAO,OAAe;IACtB,gHAAA,OAAO,OAAkB;IACzB,0GAAA,OAAO,OAAe;IACtB,wGAAA,OAAO,OAAc;IACrB,wGAAA,OAAO,OAAc;IACrB,0HAAA,OAAO,OAAuB;IAC9B,kHAAA,OAAO,OAAmB;IAC1B,4HAAA,OAAO,OAAwB;IAC/B,wHAAA,OAAO,OAAsB;IAC7B,wGAAA,OAAO,OAAc;IACrB,4GAAA,OAAO,OAAgB;IACvB,gHAAA,cAAc,OAAA;IACd,sHAAA,iBAAiB,OAAA;IAEjB,0IAAA,2BAA2B,OAAA;IAC3B,0GAAA,WAAW,OAAA;IACX,sIAAA,yBAAyB,OAAA;IACzB,0HAAA,mBAAmB,OAAA","sourcesContent":["export { default as insertTable } from './publicApi/table/insertTable';\r\nexport { default as formatTable } from './publicApi/table/formatTable';\r\nexport { default as setTableCellShade } from './publicApi/table/setTableCellShade';\r\nexport { default as editTable } from './publicApi/table/editTable';\r\nexport { default as applyTableBorderFormat } from './publicApi/table/applyTableBorderFormat';\r\nexport { default as toggleBullet } from './publicApi/list/toggleBullet';\r\nexport { default as toggleNumbering } from './publicApi/list/toggleNumbering';\r\nexport { default as toggleBold } from './publicApi/segment/toggleBold';\r\nexport { default as toggleItalic } from './publicApi/segment/toggleItalic';\r\nexport { default as toggleUnderline } from './publicApi/segment/toggleUnderline';\r\nexport { default as toggleStrikethrough } from './publicApi/segment/toggleStrikethrough';\r\nexport { default as toggleSubscript } from './publicApi/segment/toggleSubscript';\r\nexport { default as toggleSuperscript } from './publicApi/segment/toggleSuperscript';\r\nexport { default as setBackgroundColor } from './publicApi/segment/setBackgroundColor';\r\nexport { default as setFontName } from './publicApi/segment/setFontName';\r\nexport { default as setFontSize } from './publicApi/segment/setFontSize';\r\nexport { default as setTextColor } from './publicApi/segment/setTextColor';\r\nexport { default as changeFontSize } from './publicApi/segment/changeFontSize';\r\nexport { default as applySegmentFormat } from './publicApi/segment/applySegmentFormat';\r\nexport { default as changeCapitalization } from './publicApi/segment/changeCapitalization';\r\nexport { default as insertImage } from './publicApi/image/insertImage';\r\nexport { default as setListStyle } from './publicApi/list/setListStyle';\r\nexport { default as setListStartNumber } from './publicApi/list/setListStartNumber';\r\nexport { default as setIndentation } from './publicApi/block/setIndentation';\r\nexport { default as setAlignment } from './publicApi/block/setAlignment';\r\nexport { default as setDirection } from './publicApi/block/setDirection';\r\nexport { default as setHeadingLevel } from './publicApi/block/setHeadingLevel';\r\nexport { default as toggleBlockQuote } from './publicApi/block/toggleBlockQuote';\r\nexport { default as setSpacing } from './publicApi/block/setSpacing';\r\nexport { default as setImageBorder } from './publicApi/image/setImageBorder';\r\nexport { default as setImageBoxShadow } from './publicApi/image/setImageBoxShadow';\r\nexport { default as changeImage } from './publicApi/image/changeImage';\r\nexport { default as getFormatState } from './publicApi/format/getFormatState';\r\nexport { default as clearFormat } from './publicApi/format/clearFormat';\r\nexport { default as insertLink } from './publicApi/link/insertLink';\r\nexport { default as removeLink } from './publicApi/link/removeLink';\r\nexport { default as adjustLinkSelection } from './publicApi/link/adjustLinkSelection';\r\nexport { default as setImageAltText } from './publicApi/image/setImageAltText';\r\nexport { default as adjustImageSelection } from './publicApi/image/adjustImageSelection';\r\nexport { default as setParagraphMargin } from './publicApi/block/setParagraphMargin';\r\nexport { default as toggleCode } from './publicApi/segment/toggleCode';\r\nexport { default as insertEntity } from './publicApi/entity/insertEntity';\r\nexport { insertTableRow } from './modelApi/table/insertTableRow';\r\nexport { insertTableColumn } from './modelApi/table/insertTableColumn';\r\n\r\nexport { formatTableWithContentModel } from './publicApi/utils/formatTableWithContentModel';\r\nexport { setListType } from './modelApi/list/setListType';\r\nexport { findListItemsInSameThread } from './modelApi/list/findListItemsInSameThread';\r\nexport { setModelIndentation } from './modelApi/block/setModelIndentation';\r\n"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ContentModelDocument } from 'roosterjs-content-model-types';
|
|
2
|
-
/**
|
|
3
|
-
* @internal
|
|
4
|
-
*/
|
|
5
|
-
export declare function setModelAlignment(model: ContentModelDocument, alignment: 'left' | 'center' | 'right' | 'justify'): boolean;
|
|
1
|
+
import type { ContentModelDocument } from 'roosterjs-content-model-types';
|
|
2
|
+
/**
|
|
3
|
+
* @internal
|
|
4
|
+
*/
|
|
5
|
+
export declare function setModelAlignment(model: ContentModelDocument, alignment: 'left' | 'center' | 'right' | 'justify'): boolean;
|
|
@@ -1,63 +1,63 @@
|
|
|
1
|
-
define(["require", "exports", "../table/alignTable", "roosterjs-content-model-core"], function (require, exports, alignTable_1, roosterjs_content_model_core_1) {
|
|
2
|
-
"use strict";
|
|
3
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.setModelAlignment = void 0;
|
|
5
|
-
var ResultMap = {
|
|
6
|
-
left: {
|
|
7
|
-
ltr: 'start',
|
|
8
|
-
rtl: 'end',
|
|
9
|
-
},
|
|
10
|
-
center: {
|
|
11
|
-
ltr: 'center',
|
|
12
|
-
rtl: 'center',
|
|
13
|
-
},
|
|
14
|
-
right: {
|
|
15
|
-
ltr: 'end',
|
|
16
|
-
rtl: 'start',
|
|
17
|
-
},
|
|
18
|
-
justify: {
|
|
19
|
-
ltr: 'justify',
|
|
20
|
-
rtl: 'justify',
|
|
21
|
-
},
|
|
22
|
-
};
|
|
23
|
-
var TableAlignMap = {
|
|
24
|
-
left: {
|
|
25
|
-
ltr: 'alignLeft',
|
|
26
|
-
rtl: 'alignRight',
|
|
27
|
-
},
|
|
28
|
-
center: {
|
|
29
|
-
ltr: 'alignCenter',
|
|
30
|
-
rtl: 'alignCenter',
|
|
31
|
-
},
|
|
32
|
-
right: {
|
|
33
|
-
ltr: 'alignRight',
|
|
34
|
-
rtl: 'alignLeft',
|
|
35
|
-
},
|
|
36
|
-
};
|
|
37
|
-
/**
|
|
38
|
-
* @internal
|
|
39
|
-
*/
|
|
40
|
-
function setModelAlignment(model, alignment) {
|
|
41
|
-
var paragraphOrListItemOrTable = (0, roosterjs_content_model_core_1.getOperationalBlocks)(model, ['ListItem'], ['TableCell']);
|
|
42
|
-
paragraphOrListItemOrTable.forEach(function (_a) {
|
|
43
|
-
var block = _a.block;
|
|
44
|
-
var newAlignment = ResultMap[alignment][block.format.direction == 'rtl' ? 'rtl' : 'ltr'];
|
|
45
|
-
if (block.blockType === 'Table' && alignment !== 'justify') {
|
|
46
|
-
(0, alignTable_1.alignTable)(block, TableAlignMap[alignment][block.format.direction == 'rtl' ? 'rtl' : 'ltr']);
|
|
47
|
-
}
|
|
48
|
-
else if (block) {
|
|
49
|
-
if (block.blockType === 'BlockGroup' && block.blockGroupType === 'ListItem') {
|
|
50
|
-
block.blocks.forEach(function (b) {
|
|
51
|
-
var format = b.format;
|
|
52
|
-
format.textAlign = newAlignment;
|
|
53
|
-
});
|
|
54
|
-
}
|
|
55
|
-
var format = block.format;
|
|
56
|
-
format.textAlign = newAlignment;
|
|
57
|
-
}
|
|
58
|
-
});
|
|
59
|
-
return paragraphOrListItemOrTable.length > 0;
|
|
60
|
-
}
|
|
61
|
-
exports.setModelAlignment = setModelAlignment;
|
|
62
|
-
});
|
|
1
|
+
define(["require", "exports", "../table/alignTable", "roosterjs-content-model-core"], function (require, exports, alignTable_1, roosterjs_content_model_core_1) {
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.setModelAlignment = void 0;
|
|
5
|
+
var ResultMap = {
|
|
6
|
+
left: {
|
|
7
|
+
ltr: 'start',
|
|
8
|
+
rtl: 'end',
|
|
9
|
+
},
|
|
10
|
+
center: {
|
|
11
|
+
ltr: 'center',
|
|
12
|
+
rtl: 'center',
|
|
13
|
+
},
|
|
14
|
+
right: {
|
|
15
|
+
ltr: 'end',
|
|
16
|
+
rtl: 'start',
|
|
17
|
+
},
|
|
18
|
+
justify: {
|
|
19
|
+
ltr: 'justify',
|
|
20
|
+
rtl: 'justify',
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
var TableAlignMap = {
|
|
24
|
+
left: {
|
|
25
|
+
ltr: 'alignLeft',
|
|
26
|
+
rtl: 'alignRight',
|
|
27
|
+
},
|
|
28
|
+
center: {
|
|
29
|
+
ltr: 'alignCenter',
|
|
30
|
+
rtl: 'alignCenter',
|
|
31
|
+
},
|
|
32
|
+
right: {
|
|
33
|
+
ltr: 'alignRight',
|
|
34
|
+
rtl: 'alignLeft',
|
|
35
|
+
},
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* @internal
|
|
39
|
+
*/
|
|
40
|
+
function setModelAlignment(model, alignment) {
|
|
41
|
+
var paragraphOrListItemOrTable = (0, roosterjs_content_model_core_1.getOperationalBlocks)(model, ['ListItem'], ['TableCell']);
|
|
42
|
+
paragraphOrListItemOrTable.forEach(function (_a) {
|
|
43
|
+
var block = _a.block;
|
|
44
|
+
var newAlignment = ResultMap[alignment][block.format.direction == 'rtl' ? 'rtl' : 'ltr'];
|
|
45
|
+
if (block.blockType === 'Table' && alignment !== 'justify') {
|
|
46
|
+
(0, alignTable_1.alignTable)(block, TableAlignMap[alignment][block.format.direction == 'rtl' ? 'rtl' : 'ltr']);
|
|
47
|
+
}
|
|
48
|
+
else if (block) {
|
|
49
|
+
if (block.blockType === 'BlockGroup' && block.blockGroupType === 'ListItem') {
|
|
50
|
+
block.blocks.forEach(function (b) {
|
|
51
|
+
var format = b.format;
|
|
52
|
+
format.textAlign = newAlignment;
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
var format = block.format;
|
|
56
|
+
format.textAlign = newAlignment;
|
|
57
|
+
}
|
|
58
|
+
});
|
|
59
|
+
return paragraphOrListItemOrTable.length > 0;
|
|
60
|
+
}
|
|
61
|
+
exports.setModelAlignment = setModelAlignment;
|
|
62
|
+
});
|
|
63
63
|
//# sourceMappingURL=setModelAlignment.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setModelAlignment.js","sourceRoot":"","sources":["../../../../../packages-content-model/roosterjs-content-model-api/lib/modelApi/block/setModelAlignment.ts"],"names":[],"mappings":";;;;IAQA,IAAM,SAAS,GAGX;QACA,IAAI,EAAE;YACF,GAAG,EAAE,OAAO;YACZ,GAAG,EAAE,KAAK;SACb;QACD,MAAM,EAAE;YACJ,GAAG,EAAE,QAAQ;YACb,GAAG,EAAE,QAAQ;SAChB;QACD,KAAK,EAAE;YACH,GAAG,EAAE,KAAK;YACV,GAAG,EAAE,OAAO;SACf;QACD,OAAO,EAAE;YACL,GAAG,EAAE,SAAS;YACd,GAAG,EAAE,SAAS;SACjB;KACJ,CAAC;IAEF,IAAM,aAAa,GAGf;QACA,IAAI,EAAE;YACF,GAAG,EAAE,WAAW;YAChB,GAAG,EAAE,YAAY;SACpB;QACD,MAAM,EAAE;YACJ,GAAG,EAAE,aAAa;YAClB,GAAG,EAAE,aAAa;SACrB;QACD,KAAK,EAAE;YACH,GAAG,EAAE,YAAY;YACjB,GAAG,EAAE,WAAW;SACnB;KACJ,CAAC;IAEF;;OAEG;IACH,SAAgB,iBAAiB,CAC7B,KAA2B,EAC3B,SAAkD;QAElD,IAAM,0BAA0B,GAAG,IAAA,mDAAoB,EACnD,KAAK,EACL,CAAC,UAAU,CAAC,EACZ,CAAC,WAAW,CAAC,CAChB,CAAC;QAEF,0BAA0B,CAAC,OAAO,CAAC,UAAC,EAAS;gBAAP,KAAK,WAAA;YACvC,IAAM,YAAY,GAAG,SAAS,CAAC,SAAS,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,SAAS,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;YAC3F,IAAI,KAAK,CAAC,SAAS,KAAK,OAAO,IAAI,SAAS,KAAK,SAAS,EAAE;gBACxD,IAAA,uBAAU,EACN,KAAK,EACL,aAAa,CAAC,SAAS,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,SAAS,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAC5E,CAAC;aACL;iBAAM,IAAI,KAAK,EAAE;gBACd,IAAI,KAAK,CAAC,SAAS,KAAK,YAAY,IAAI,KAAK,CAAC,cAAc,KAAK,UAAU,EAAE;oBACzE,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,UAAA,CAAC;wBACV,IAAA,MAAM,GAAK,CAAC,OAAN,CAAO;wBACrB,MAAM,CAAC,SAAS,GAAG,YAAY,CAAC;oBACpC,CAAC,CAAC,CAAC;iBACN;gBACO,IAAA,MAAM,GAAK,KAAK,OAAV,CAAW;gBACzB,MAAM,CAAC,SAAS,GAAG,YAAY,CAAC;aACnC;QACL,CAAC,CAAC,CAAC;QAEH,OAAO,0BAA0B,CAAC,MAAM,GAAG,CAAC,CAAC;IACjD,CAAC;IA9BD,8CA8BC","sourcesContent":["import { alignTable } from '../table/alignTable';\nimport { getOperationalBlocks } from 'roosterjs-content-model-core';\nimport type {\n ContentModelDocument,\n ContentModelListItem,\n TableAlignOperation,\n} from 'roosterjs-content-model-types';\n\nconst ResultMap: Record<\n 'left' | 'center' | 'right' | 'justify',\n Record<'ltr' | 'rtl', 'start' | 'center' | 'end' | 'justify'>\n> = {\n left: {\n ltr: 'start',\n rtl: 'end',\n },\n center: {\n ltr: 'center',\n rtl: 'center',\n },\n right: {\n ltr: 'end',\n rtl: 'start',\n },\n justify: {\n ltr: 'justify',\n rtl: 'justify',\n },\n};\n\nconst TableAlignMap: Record<\n 'left' | 'center' | 'right',\n Record<'ltr' | 'rtl', TableAlignOperation>\n> = {\n left: {\n ltr: 'alignLeft',\n rtl: 'alignRight',\n },\n center: {\n ltr: 'alignCenter',\n rtl: 'alignCenter',\n },\n right: {\n ltr: 'alignRight',\n rtl: 'alignLeft',\n },\n};\n\n/**\n * @internal\n */\nexport function setModelAlignment(\n model: ContentModelDocument,\n alignment: 'left' | 'center' | 'right' | 'justify'\n) {\n const paragraphOrListItemOrTable = getOperationalBlocks<ContentModelListItem>(\n model,\n ['ListItem'],\n ['TableCell']\n );\n\n paragraphOrListItemOrTable.forEach(({ block }) => {\n const newAlignment = ResultMap[alignment][block.format.direction == 'rtl' ? 'rtl' : 'ltr'];\n if (block.blockType === 'Table' && alignment !== 'justify') {\n alignTable(\n block,\n TableAlignMap[alignment][block.format.direction == 'rtl' ? 'rtl' : 'ltr']\n );\n } else if (block) {\n if (block.blockType === 'BlockGroup' && block.blockGroupType === 'ListItem') {\n block.blocks.forEach(b => {\n const { format } = b;\n format.textAlign = newAlignment;\n });\n }\n const { format } = block;\n format.textAlign = newAlignment;\n }\n });\n\n return paragraphOrListItemOrTable.length > 0;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"setModelAlignment.js","sourceRoot":"","sources":["../../../../../packages-content-model/roosterjs-content-model-api/lib/modelApi/block/setModelAlignment.ts"],"names":[],"mappings":";;;;IAQA,IAAM,SAAS,GAGX;QACA,IAAI,EAAE;YACF,GAAG,EAAE,OAAO;YACZ,GAAG,EAAE,KAAK;SACb;QACD,MAAM,EAAE;YACJ,GAAG,EAAE,QAAQ;YACb,GAAG,EAAE,QAAQ;SAChB;QACD,KAAK,EAAE;YACH,GAAG,EAAE,KAAK;YACV,GAAG,EAAE,OAAO;SACf;QACD,OAAO,EAAE;YACL,GAAG,EAAE,SAAS;YACd,GAAG,EAAE,SAAS;SACjB;KACJ,CAAC;IAEF,IAAM,aAAa,GAGf;QACA,IAAI,EAAE;YACF,GAAG,EAAE,WAAW;YAChB,GAAG,EAAE,YAAY;SACpB;QACD,MAAM,EAAE;YACJ,GAAG,EAAE,aAAa;YAClB,GAAG,EAAE,aAAa;SACrB;QACD,KAAK,EAAE;YACH,GAAG,EAAE,YAAY;YACjB,GAAG,EAAE,WAAW;SACnB;KACJ,CAAC;IAEF;;OAEG;IACH,SAAgB,iBAAiB,CAC7B,KAA2B,EAC3B,SAAkD;QAElD,IAAM,0BAA0B,GAAG,IAAA,mDAAoB,EACnD,KAAK,EACL,CAAC,UAAU,CAAC,EACZ,CAAC,WAAW,CAAC,CAChB,CAAC;QAEF,0BAA0B,CAAC,OAAO,CAAC,UAAC,EAAS;gBAAP,KAAK,WAAA;YACvC,IAAM,YAAY,GAAG,SAAS,CAAC,SAAS,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,SAAS,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;YAC3F,IAAI,KAAK,CAAC,SAAS,KAAK,OAAO,IAAI,SAAS,KAAK,SAAS,EAAE;gBACxD,IAAA,uBAAU,EACN,KAAK,EACL,aAAa,CAAC,SAAS,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,SAAS,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAC5E,CAAC;aACL;iBAAM,IAAI,KAAK,EAAE;gBACd,IAAI,KAAK,CAAC,SAAS,KAAK,YAAY,IAAI,KAAK,CAAC,cAAc,KAAK,UAAU,EAAE;oBACzE,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,UAAA,CAAC;wBACV,IAAA,MAAM,GAAK,CAAC,OAAN,CAAO;wBACrB,MAAM,CAAC,SAAS,GAAG,YAAY,CAAC;oBACpC,CAAC,CAAC,CAAC;iBACN;gBACO,IAAA,MAAM,GAAK,KAAK,OAAV,CAAW;gBACzB,MAAM,CAAC,SAAS,GAAG,YAAY,CAAC;aACnC;QACL,CAAC,CAAC,CAAC;QAEH,OAAO,0BAA0B,CAAC,MAAM,GAAG,CAAC,CAAC;IACjD,CAAC;IA9BD,8CA8BC","sourcesContent":["import { alignTable } from '../table/alignTable';\r\nimport { getOperationalBlocks } from 'roosterjs-content-model-core';\r\nimport type {\r\n ContentModelDocument,\r\n ContentModelListItem,\r\n TableAlignOperation,\r\n} from 'roosterjs-content-model-types';\r\n\r\nconst ResultMap: Record<\r\n 'left' | 'center' | 'right' | 'justify',\r\n Record<'ltr' | 'rtl', 'start' | 'center' | 'end' | 'justify'>\r\n> = {\r\n left: {\r\n ltr: 'start',\r\n rtl: 'end',\r\n },\r\n center: {\r\n ltr: 'center',\r\n rtl: 'center',\r\n },\r\n right: {\r\n ltr: 'end',\r\n rtl: 'start',\r\n },\r\n justify: {\r\n ltr: 'justify',\r\n rtl: 'justify',\r\n },\r\n};\r\n\r\nconst TableAlignMap: Record<\r\n 'left' | 'center' | 'right',\r\n Record<'ltr' | 'rtl', TableAlignOperation>\r\n> = {\r\n left: {\r\n ltr: 'alignLeft',\r\n rtl: 'alignRight',\r\n },\r\n center: {\r\n ltr: 'alignCenter',\r\n rtl: 'alignCenter',\r\n },\r\n right: {\r\n ltr: 'alignRight',\r\n rtl: 'alignLeft',\r\n },\r\n};\r\n\r\n/**\r\n * @internal\r\n */\r\nexport function setModelAlignment(\r\n model: ContentModelDocument,\r\n alignment: 'left' | 'center' | 'right' | 'justify'\r\n) {\r\n const paragraphOrListItemOrTable = getOperationalBlocks<ContentModelListItem>(\r\n model,\r\n ['ListItem'],\r\n ['TableCell']\r\n );\r\n\r\n paragraphOrListItemOrTable.forEach(({ block }) => {\r\n const newAlignment = ResultMap[alignment][block.format.direction == 'rtl' ? 'rtl' : 'ltr'];\r\n if (block.blockType === 'Table' && alignment !== 'justify') {\r\n alignTable(\r\n block,\r\n TableAlignMap[alignment][block.format.direction == 'rtl' ? 'rtl' : 'ltr']\r\n );\r\n } else if (block) {\r\n if (block.blockType === 'BlockGroup' && block.blockGroupType === 'ListItem') {\r\n block.blocks.forEach(b => {\r\n const { format } = b;\r\n format.textAlign = newAlignment;\r\n });\r\n }\r\n const { format } = block;\r\n format.textAlign = newAlignment;\r\n }\r\n });\r\n\r\n return paragraphOrListItemOrTable.length > 0;\r\n}\r\n"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ContentModelDocument } from 'roosterjs-content-model-types';
|
|
2
|
-
/**
|
|
3
|
-
* @internal
|
|
4
|
-
*/
|
|
5
|
-
export declare function setModelDirection(model: ContentModelDocument, direction: 'ltr' | 'rtl'): boolean;
|
|
1
|
+
import type { ContentModelDocument } from 'roosterjs-content-model-types';
|
|
2
|
+
/**
|
|
3
|
+
* @internal
|
|
4
|
+
*/
|
|
5
|
+
export declare function setModelDirection(model: ContentModelDocument, direction: 'ltr' | 'rtl'): boolean;
|
|
@@ -1,70 +1,69 @@
|
|
|
1
|
-
define(["require", "exports", "../list/findListItemsInSameThread", "roosterjs-content-model-core"], function (require, exports, findListItemsInSameThread_1, roosterjs_content_model_core_1) {
|
|
2
|
-
"use strict";
|
|
3
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.setModelDirection = void 0;
|
|
5
|
-
/**
|
|
6
|
-
* @internal
|
|
7
|
-
*/
|
|
8
|
-
function setModelDirection(model, direction) {
|
|
9
|
-
var paragraphOrListItemOrTable = (0, roosterjs_content_model_core_1.getOperationalBlocks)(model, ['ListItem'], ['TableCell']);
|
|
10
|
-
paragraphOrListItemOrTable.forEach(function (_a) {
|
|
11
|
-
var block = _a.block;
|
|
12
|
-
if ((0, roosterjs_content_model_core_1.isBlockGroupOfType)(block, 'ListItem')) {
|
|
13
|
-
var items = (0, findListItemsInSameThread_1.findListItemsInSameThread)(model, block);
|
|
14
|
-
items.forEach(function (item) {
|
|
15
|
-
item.levels.forEach(function (level) {
|
|
16
|
-
level.format.direction = direction;
|
|
17
|
-
});
|
|
18
|
-
item.blocks.forEach(function (block) { return internalSetDirection(block.format, direction); });
|
|
19
|
-
});
|
|
20
|
-
}
|
|
21
|
-
else if (block) {
|
|
22
|
-
internalSetDirection(block.format, direction, block);
|
|
23
|
-
}
|
|
24
|
-
});
|
|
25
|
-
return paragraphOrListItemOrTable.length > 0;
|
|
26
|
-
}
|
|
27
|
-
exports.setModelDirection = setModelDirection;
|
|
28
|
-
function internalSetDirection(format, direction, block) {
|
|
29
|
-
var wasRtl = format.direction == 'rtl';
|
|
30
|
-
var isRtl = direction == 'rtl';
|
|
31
|
-
if (wasRtl != isRtl) {
|
|
32
|
-
format.direction = direction;
|
|
33
|
-
// Adjust margin when change direction
|
|
34
|
-
|
|
35
|
-
var
|
|
36
|
-
|
|
37
|
-
setProperty(format, '
|
|
38
|
-
setProperty(format, '
|
|
39
|
-
setProperty(format, '
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
setProperty(cell.format, '
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
});
|
|
1
|
+
define(["require", "exports", "../list/findListItemsInSameThread", "roosterjs-content-model-core"], function (require, exports, findListItemsInSameThread_1, roosterjs_content_model_core_1) {
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.setModelDirection = void 0;
|
|
5
|
+
/**
|
|
6
|
+
* @internal
|
|
7
|
+
*/
|
|
8
|
+
function setModelDirection(model, direction) {
|
|
9
|
+
var paragraphOrListItemOrTable = (0, roosterjs_content_model_core_1.getOperationalBlocks)(model, ['ListItem'], ['TableCell']);
|
|
10
|
+
paragraphOrListItemOrTable.forEach(function (_a) {
|
|
11
|
+
var block = _a.block;
|
|
12
|
+
if ((0, roosterjs_content_model_core_1.isBlockGroupOfType)(block, 'ListItem')) {
|
|
13
|
+
var items = (0, findListItemsInSameThread_1.findListItemsInSameThread)(model, block);
|
|
14
|
+
items.forEach(function (item) {
|
|
15
|
+
item.levels.forEach(function (level) {
|
|
16
|
+
level.format.direction = direction;
|
|
17
|
+
});
|
|
18
|
+
item.blocks.forEach(function (block) { return internalSetDirection(block.format, direction); });
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
else if (block) {
|
|
22
|
+
internalSetDirection(block.format, direction, block);
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
return paragraphOrListItemOrTable.length > 0;
|
|
26
|
+
}
|
|
27
|
+
exports.setModelDirection = setModelDirection;
|
|
28
|
+
function internalSetDirection(format, direction, block) {
|
|
29
|
+
var wasRtl = format.direction == 'rtl';
|
|
30
|
+
var isRtl = direction == 'rtl';
|
|
31
|
+
if (wasRtl != isRtl) {
|
|
32
|
+
format.direction = direction;
|
|
33
|
+
// Adjust margin when change direction
|
|
34
|
+
var marginLeft = format.marginLeft;
|
|
35
|
+
var paddingLeft = format.paddingLeft;
|
|
36
|
+
setProperty(format, 'marginLeft', format.marginRight);
|
|
37
|
+
setProperty(format, 'marginRight', marginLeft);
|
|
38
|
+
setProperty(format, 'paddingLeft', format.paddingRight);
|
|
39
|
+
setProperty(format, 'paddingRight', paddingLeft);
|
|
40
|
+
// If whole Table direction changed, flip cell side borders
|
|
41
|
+
if (block && block.blockType == 'Table') {
|
|
42
|
+
block.rows.forEach(function (row) {
|
|
43
|
+
row.cells.forEach(function (cell) {
|
|
44
|
+
// Optimise by skipping cells with unchanged borders
|
|
45
|
+
(0, roosterjs_content_model_core_1.updateTableCellMetadata)(cell, function (metadata) {
|
|
46
|
+
if (metadata === null || metadata === void 0 ? void 0 : metadata.borderOverride) {
|
|
47
|
+
var storeBorderLeft = cell.format.borderLeft;
|
|
48
|
+
setProperty(cell.format, 'borderLeft', cell.format.borderRight);
|
|
49
|
+
setProperty(cell.format, 'borderRight', storeBorderLeft);
|
|
50
|
+
}
|
|
51
|
+
return metadata;
|
|
52
|
+
});
|
|
53
|
+
});
|
|
54
|
+
});
|
|
55
|
+
// Apply changed borders
|
|
56
|
+
(0, roosterjs_content_model_core_1.applyTableFormat)(block, undefined /* newFormat */, true /* keepCellShade*/);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
function setProperty(format, key, value) {
|
|
61
|
+
if (value) {
|
|
62
|
+
format[key] = value;
|
|
63
|
+
}
|
|
64
|
+
else {
|
|
65
|
+
delete format[key];
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
});
|
|
70
69
|
//# sourceMappingURL=setModelDirection.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setModelDirection.js","sourceRoot":"","sources":["../../../../../packages-content-model/roosterjs-content-model-api/lib/modelApi/block/setModelDirection.ts"],"names":[],"mappings":";;;;IAiBA;;OAEG;IACH,SAAgB,iBAAiB,CAAC,KAA2B,EAAE,SAAwB;QACnF,IAAM,0BAA0B,GAAG,IAAA,mDAAoB,EACnD,KAAK,EACL,CAAC,UAAU,CAAC,EACZ,CAAC,WAAW,CAAC,CAChB,CAAC;QAEF,0BAA0B,CAAC,OAAO,CAAC,UAAC,EAAS;gBAAP,KAAK,WAAA;YACvC,IAAI,IAAA,iDAAkB,EAAuB,KAAK,EAAE,UAAU,CAAC,EAAE;gBAC7D,IAAM,KAAK,GAAG,IAAA,qDAAyB,EAAC,KAAK,EAAE,KAAK,CAAC,CAAC;gBAEtD,KAAK,CAAC,OAAO,CAAC,UAAA,IAAI;oBACd,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,UAAA,KAAK;wBACrB,KAAK,CAAC,MAAM,CAAC,SAAS,GAAG,SAAS,CAAC;oBACvC,CAAC,CAAC,CAAC;oBAEH,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,UAAA,KAAK,IAAI,OAAA,oBAAoB,CAAC,KAAK,CAAC,MAAM,EAAE,SAAS,CAAC,EAA7C,CAA6C,CAAC,CAAC;gBAChF,CAAC,CAAC,CAAC;aACN;iBAAM,IAAI,KAAK,EAAE;gBACd,oBAAoB,CAAC,KAAK,CAAC,MAAM,EAAE,SAAS,EAAE,KAAK,CAAC,CAAC;aACxD;QACL,CAAC,CAAC,CAAC;QAEH,OAAO,0BAA0B,CAAC,MAAM,GAAG,CAAC,CAAC;IACjD,CAAC;IAxBD,8CAwBC;IAED,SAAS,oBAAoB,CACzB,MAA+B,EAC/B,SAAwB,EACxB,KAAyB;QAEzB,IAAM,MAAM,GAAG,MAAM,CAAC,SAAS,IAAI,KAAK,CAAC;QACzC,IAAM,KAAK,GAAG,SAAS,IAAI,KAAK,CAAC;QAEjC,IAAI,MAAM,IAAI,KAAK,EAAE;YACjB,MAAM,CAAC,SAAS,GAAG,SAAS,CAAC;YAE7B,sCAAsC;YACtC,
|
|
1
|
+
{"version":3,"file":"setModelDirection.js","sourceRoot":"","sources":["../../../../../packages-content-model/roosterjs-content-model-api/lib/modelApi/block/setModelDirection.ts"],"names":[],"mappings":";;;;IAiBA;;OAEG;IACH,SAAgB,iBAAiB,CAAC,KAA2B,EAAE,SAAwB;QACnF,IAAM,0BAA0B,GAAG,IAAA,mDAAoB,EACnD,KAAK,EACL,CAAC,UAAU,CAAC,EACZ,CAAC,WAAW,CAAC,CAChB,CAAC;QAEF,0BAA0B,CAAC,OAAO,CAAC,UAAC,EAAS;gBAAP,KAAK,WAAA;YACvC,IAAI,IAAA,iDAAkB,EAAuB,KAAK,EAAE,UAAU,CAAC,EAAE;gBAC7D,IAAM,KAAK,GAAG,IAAA,qDAAyB,EAAC,KAAK,EAAE,KAAK,CAAC,CAAC;gBAEtD,KAAK,CAAC,OAAO,CAAC,UAAA,IAAI;oBACd,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,UAAA,KAAK;wBACrB,KAAK,CAAC,MAAM,CAAC,SAAS,GAAG,SAAS,CAAC;oBACvC,CAAC,CAAC,CAAC;oBAEH,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,UAAA,KAAK,IAAI,OAAA,oBAAoB,CAAC,KAAK,CAAC,MAAM,EAAE,SAAS,CAAC,EAA7C,CAA6C,CAAC,CAAC;gBAChF,CAAC,CAAC,CAAC;aACN;iBAAM,IAAI,KAAK,EAAE;gBACd,oBAAoB,CAAC,KAAK,CAAC,MAAM,EAAE,SAAS,EAAE,KAAK,CAAC,CAAC;aACxD;QACL,CAAC,CAAC,CAAC;QAEH,OAAO,0BAA0B,CAAC,MAAM,GAAG,CAAC,CAAC;IACjD,CAAC;IAxBD,8CAwBC;IAED,SAAS,oBAAoB,CACzB,MAA+B,EAC/B,SAAwB,EACxB,KAAyB;QAEzB,IAAM,MAAM,GAAG,MAAM,CAAC,SAAS,IAAI,KAAK,CAAC;QACzC,IAAM,KAAK,GAAG,SAAS,IAAI,KAAK,CAAC;QAEjC,IAAI,MAAM,IAAI,KAAK,EAAE;YACjB,MAAM,CAAC,SAAS,GAAG,SAAS,CAAC;YAE7B,sCAAsC;YACtC,IAAM,UAAU,GAAG,MAAM,CAAC,UAAU,CAAC;YACrC,IAAM,WAAW,GAAG,MAAM,CAAC,WAAW,CAAC;YAEvC,WAAW,CAAC,MAAM,EAAE,YAAY,EAAE,MAAM,CAAC,WAAW,CAAC,CAAC;YACtD,WAAW,CAAC,MAAM,EAAE,aAAa,EAAE,UAAU,CAAC,CAAC;YAC/C,WAAW,CAAC,MAAM,EAAE,aAAa,EAAE,MAAM,CAAC,YAAY,CAAC,CAAC;YACxD,WAAW,CAAC,MAAM,EAAE,cAAc,EAAE,WAAW,CAAC,CAAC;YAEjD,2DAA2D;YAC3D,IAAI,KAAK,IAAI,KAAK,CAAC,SAAS,IAAI,OAAO,EAAE;gBACrC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,UAAA,GAAG;oBAClB,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,UAAA,IAAI;wBAClB,oDAAoD;wBACpD,IAAA,sDAAuB,EAAC,IAAI,EAAE,UAAA,QAAQ;4BAClC,IAAI,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,cAAc,EAAE;gCAC1B,IAAM,eAAe,GAAG,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC;gCAC/C,WAAW,CAAC,IAAI,CAAC,MAAM,EAAE,YAAY,EAAE,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;gCAChE,WAAW,CAAC,IAAI,CAAC,MAAM,EAAE,aAAa,EAAE,eAAe,CAAC,CAAC;6BAC5D;4BACD,OAAO,QAAQ,CAAC;wBACpB,CAAC,CAAC,CAAC;oBACP,CAAC,CAAC,CAAC;gBACP,CAAC,CAAC,CAAC;gBAEH,wBAAwB;gBACxB,IAAA,+CAAgB,EAAC,KAAK,EAAE,SAAS,CAAC,eAAe,EAAE,IAAI,CAAC,kBAAkB,CAAC,CAAC;aAC/E;SACJ;IACL,CAAC;IAED,SAAS,WAAW,CAChB,MAAmD,EACnD,GAAwD,EACxD,KAAyB;QAEzB,IAAI,KAAK,EAAE;YACP,MAAM,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;SACvB;aAAM;YACH,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;SACtB;IACL,CAAC","sourcesContent":["import { findListItemsInSameThread } from '../list/findListItemsInSameThread';\r\nimport {\r\n applyTableFormat,\r\n getOperationalBlocks,\r\n isBlockGroupOfType,\r\n updateTableCellMetadata,\r\n} from 'roosterjs-content-model-core';\r\nimport type {\r\n BorderFormat,\r\n ContentModelBlock,\r\n ContentModelBlockFormat,\r\n ContentModelDocument,\r\n ContentModelListItem,\r\n MarginFormat,\r\n PaddingFormat,\r\n} from 'roosterjs-content-model-types';\r\n\r\n/**\r\n * @internal\r\n */\r\nexport function setModelDirection(model: ContentModelDocument, direction: 'ltr' | 'rtl') {\r\n const paragraphOrListItemOrTable = getOperationalBlocks<ContentModelListItem>(\r\n model,\r\n ['ListItem'],\r\n ['TableCell']\r\n );\r\n\r\n paragraphOrListItemOrTable.forEach(({ block }) => {\r\n if (isBlockGroupOfType<ContentModelListItem>(block, 'ListItem')) {\r\n const items = findListItemsInSameThread(model, block);\r\n\r\n items.forEach(item => {\r\n item.levels.forEach(level => {\r\n level.format.direction = direction;\r\n });\r\n\r\n item.blocks.forEach(block => internalSetDirection(block.format, direction));\r\n });\r\n } else if (block) {\r\n internalSetDirection(block.format, direction, block);\r\n }\r\n });\r\n\r\n return paragraphOrListItemOrTable.length > 0;\r\n}\r\n\r\nfunction internalSetDirection(\r\n format: ContentModelBlockFormat,\r\n direction: 'ltr' | 'rtl',\r\n block?: ContentModelBlock\r\n) {\r\n const wasRtl = format.direction == 'rtl';\r\n const isRtl = direction == 'rtl';\r\n\r\n if (wasRtl != isRtl) {\r\n format.direction = direction;\r\n\r\n // Adjust margin when change direction\r\n const marginLeft = format.marginLeft;\r\n const paddingLeft = format.paddingLeft;\r\n\r\n setProperty(format, 'marginLeft', format.marginRight);\r\n setProperty(format, 'marginRight', marginLeft);\r\n setProperty(format, 'paddingLeft', format.paddingRight);\r\n setProperty(format, 'paddingRight', paddingLeft);\r\n\r\n // If whole Table direction changed, flip cell side borders\r\n if (block && block.blockType == 'Table') {\r\n block.rows.forEach(row => {\r\n row.cells.forEach(cell => {\r\n // Optimise by skipping cells with unchanged borders\r\n updateTableCellMetadata(cell, metadata => {\r\n if (metadata?.borderOverride) {\r\n const storeBorderLeft = cell.format.borderLeft;\r\n setProperty(cell.format, 'borderLeft', cell.format.borderRight);\r\n setProperty(cell.format, 'borderRight', storeBorderLeft);\r\n }\r\n return metadata;\r\n });\r\n });\r\n });\r\n\r\n // Apply changed borders\r\n applyTableFormat(block, undefined /* newFormat */, true /* keepCellShade*/);\r\n }\r\n }\r\n}\r\n\r\nfunction setProperty(\r\n format: MarginFormat & PaddingFormat & BorderFormat,\r\n key: keyof (MarginFormat & PaddingFormat & BorderFormat),\r\n value: string | undefined\r\n) {\r\n if (value) {\r\n format[key] = value;\r\n } else {\r\n delete format[key];\r\n }\r\n}\r\n"]}
|