devexpress-richedit 24.1.7-build-24274-0102 → 24.1.7-build-24288-0102

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.
@@ -11356,10 +11356,11 @@ class color_model_info_ColorModelInfo {
11356
11356
  }
11357
11357
  static get nullColor() { return color_model_info_ColorModelInfo.makeByColor(ColorHelper.AUTOMATIC_COLOR); }
11358
11358
  ;
11359
- static makeByThemeColorIndex(themeColorIndex, tint = 0) {
11359
+ static makeByThemeColorIndex(themeColorIndex, tint = 0, themeValue = ThemeColorValues.None) {
11360
11360
  const result = new color_model_info_ColorModelInfo();
11361
11361
  result.themeColorIndex = themeColorIndex;
11362
11362
  result.tint = tint;
11363
+ result.themeValue = themeValue;
11363
11364
  return result;
11364
11365
  }
11365
11366
  static makeByColor(color, tint = 0) {
@@ -28870,6 +28871,7 @@ class StylesManager {
28870
28871
  }
28871
28872
  addTableCellStyleCore(oldStyle) {
28872
28873
  var newStyle = oldStyle.clone();
28874
+ this.tableCellStyleNameToIndex[newStyle.styleName] = this.documentModel.tableCellStyles.push(newStyle) - 1;
28873
28875
  newStyle.characterProperties = this.documentModel.cache.mergedCharacterPropertiesCache.getItem(oldStyle.characterProperties);
28874
28876
  newStyle.tableCellProperties = this.documentModel.cache.tableCellPropertiesCache.getItem(oldStyle.tableCellProperties);
28875
28877
  return newStyle;
@@ -48019,7 +48021,7 @@ class TextManipulator extends RunsBaseManipulator {
48019
48021
  return null;
48020
48022
  const historyItems = history.historyItems;
48021
48023
  const result = history.currentIndex == historyItems.length - 1 ? this.getLastHistoryItemNode(historyItems, null, checkType) : null;
48022
- return !result.empty ? result : null;
48024
+ return (result === null || result === void 0 ? void 0 : result.empty) ? null : result;
48023
48025
  }
48024
48026
  getLastHistoryItemNode(historyItems, parent, checkType) {
48025
48027
  for (let ind = historyItems.length - 1, item; item = historyItems[ind]; ind--) {
@@ -69877,7 +69879,7 @@ class HtmlImporter {
69877
69879
  const missTag = HtmlImporter.MapMissTablePropertiesByTagNames[utils_list.ListUtils.last(this.levelInfo).tagImporter.elementTag()];
69878
69880
  utils_list.ListUtils.forEach(this.currElementChildren, (childElement) => {
69879
69881
  const childElemStyle = this.getStyles(childElement);
69880
- if (!Object.keys(childElemStyle).length)
69882
+ if (childElement.nodeType !== Node.ELEMENT_NODE)
69881
69883
  return;
69882
69884
  for (var prop in this.getStyles(element)) {
69883
69885
  if (missTag && /^(border|background|marginLeft)/gi.test(prop))
@@ -72277,6 +72279,7 @@ class ParagraphFrame extends rectangle.Rectangle {
72277
72279
 
72278
72280
 
72279
72281
 
72282
+
72280
72283
  class InputPosition extends InputPositionBase {
72281
72284
  constructor(selection) {
72282
72285
  super();
@@ -72294,13 +72297,23 @@ class InputPosition extends InputPositionBase {
72294
72297
  }
72295
72298
  getMergedSectionPropertiesRaw() {
72296
72299
  if (!this.mergedSectionPropertiesRaw) {
72297
- var interval = this.intervalsInfo.interval;
72298
- var intervalStartPosition = interval.start;
72299
- var intervalEndPosition = interval.end;
72300
- var sections = this.model.sections;
72301
- var sectionIndex = search.SearchUtils.normedInterpolationIndexOf(sections, (s) => s.startLogPosition.value, intervalStartPosition);
72300
+ let sectionIndex;
72301
+ let intervalEndPosition;
72302
+ const sections = this.model.sections;
72303
+ const pageIndex = this.selection.pageIndex;
72304
+ if (pageIndex < 0) {
72305
+ const interval = this.intervalsInfo.interval;
72306
+ const intervalStartPosition = interval.start;
72307
+ intervalEndPosition = interval.end;
72308
+ sectionIndex = search.SearchUtils.normedInterpolationIndexOf(sections, (s) => s.startLogPosition.value, intervalStartPosition);
72309
+ }
72310
+ else {
72311
+ const layoutPage = this.selection.layout.pages[pageIndex];
72312
+ sectionIndex = Section.getPageSectionIndex(layoutPage, sections);
72313
+ intervalEndPosition = layoutPage.getEndPosition();
72314
+ }
72302
72315
  this.mergedSectionPropertiesRaw = sections[sectionIndex++].sectionProperties.clone();
72303
- for (var section; (section = sections[sectionIndex]) && (section.startLogPosition.value < intervalEndPosition); sectionIndex++)
72316
+ for (let section; (section = sections[sectionIndex]) && (section.startLogPosition.value < intervalEndPosition); sectionIndex++)
72304
72317
  InputPositionBase.mergePropertiesRaw(this.mergedSectionPropertiesRaw, section.sectionProperties, SectionPropertyDescriptor.ALL_FIELDS);
72305
72318
  }
72306
72319
  return this.mergedSectionPropertiesRaw;
@@ -74909,9 +74922,10 @@ class StyleManager {
74909
74922
  string.StringMapUtils.forEach(this.info, (info) => action(info));
74910
74923
  }
74911
74924
  addStyle(dest) {
74925
+ var _a;
74912
74926
  if (this.currInfo.isDefault && !this.isDefaultProcessed) {
74913
74927
  this.isDefaultProcessed = true;
74914
- if (this.defaultStyle.styleName === this.currInfo.name)
74928
+ if (((_a = this.defaultStyle) === null || _a === void 0 ? void 0 : _a.styleName) === this.currInfo.name)
74915
74929
  this.applyProperties(dest, this.defaultStyle);
74916
74930
  else
74917
74931
  this.defaultStyle = this.addToModel(this.applyProperties(dest, this.createEmpty()));
@@ -77714,7 +77728,7 @@ class OpenXmlColorImportHelper {
77714
77728
  if (themeValue != ThemeColorValues.None) {
77715
77729
  const themeColorIndex = ThemeColorIndexCalculator.calculateThemeColorIndex(themeValue);
77716
77730
  return themeColorIndex != ThemeColorIndexConstants.None ?
77717
- color_model_info_ColorModelInfo.makeByThemeColorIndex(themeColorIndex, OpenXmlColorImportHelper.getTint(data, reader, 'themeTint', 'themeShade')) :
77731
+ color_model_info_ColorModelInfo.makeByThemeColorIndex(themeColorIndex, OpenXmlColorImportHelper.getTint(data, reader, 'themeTint', 'themeShade'), themeValue) :
77718
77732
  color_model_info_ColorModelInfo.makeByThemeColorIndex(DXColor.empty);
77719
77733
  }
77720
77734
  else {
@@ -77745,7 +77759,7 @@ class OpenXmlColorImportHelper {
77745
77759
  if (themeValue != ThemeColorValues.None) {
77746
77760
  const themeColorIndex = ThemeColorIndexCalculator.calculateThemeColorIndex(themeValue);
77747
77761
  if (themeColorIndex != ThemeColorIndexConstants.None)
77748
- return color_model_info_ColorModelInfo.makeByThemeColorIndex(themeColorIndex, tint);
77762
+ return color_model_info_ColorModelInfo.makeByThemeColorIndex(themeColorIndex, tint, themeValue);
77749
77763
  }
77750
77764
  return color_model_info_ColorModelInfo.makeByColor(data.readerHelper.getWpSTColorValue(reader, 'fill', DXColor.empty), tint);
77751
77765
  }