devexpress-richedit 23.2.2-beta → 23.2.3

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/bin/gulpfile.js CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (gulpfile.js)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (index-custom.js)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (localization-builder.js)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (nspell-index.js)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (nspell.webpack.config.js)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (webpack-externals.js)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (webpack.config.js)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (client.d.ts)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * DevExpress WebRichEdit (dx.richedit.js)
3
- * Version: 23.2.2
3
+ * Version: 23.2.3
4
4
  * Copyright (c) 2012 - 2023 Developer Express Inc. ALL RIGHTS RESERVED
5
5
  * License: https://www.devexpress.com/Support/EULAs
6
6
  */
@@ -30375,7 +30375,7 @@ function hexToBase64(hexStr) {
30375
30375
  return hexadecimal_converter_btoa(result.join(""));
30376
30376
  }
30377
30377
  function base64ToHex(base64Str) {
30378
- for (var i = 0, bin = atob(base64Str.replace(/[ \r\n]+$/, "")), hex = []; i < bin.length; ++i) {
30378
+ for (var i = 0, bin = hexadecimal_converter_atob(base64Str.replace(/[ \r\n]+$/, "")), hex = []; i < bin.length; ++i) {
30379
30379
  var tmp = bin.charCodeAt(i).toString(16);
30380
30380
  if (tmp.length === 1)
30381
30381
  tmp = "0" + tmp;
@@ -30398,7 +30398,7 @@ function hexadecimal_converter_btoa(bin) {
30398
30398
  }
30399
30399
  return base64.join("");
30400
30400
  }
30401
- function atob(base64) {
30401
+ function hexadecimal_converter_atob(base64) {
30402
30402
  if (/(=[^=]+|={3,})$/.test(base64))
30403
30403
  throw new Error("String contains an invalid character");
30404
30404
  base64 = base64.replace(/=/g, "");
@@ -30624,6 +30624,7 @@ class ModelComparer {
30624
30624
  if (hasLostedRuns && sourceChunk.textRuns.length - this.countNotLoadedPicture(sourceChunk.textRuns) != targetChunk.textRuns.length) {
30625
30625
  if (this.format != DocumentFormat.Rtf || sourceChunk.textBuffer != targetChunk.textBuffer)
30626
30626
  return ModelCheckerResult.Chunk;
30627
+ return ModelCheckerResult.None;
30627
30628
  }
30628
30629
  let skippedRunCount = 0;
30629
30630
  let skippedOffset = 0;
@@ -85184,6 +85185,10 @@ class ColorExporter extends BaseExporter {
85184
85185
 
85185
85186
 
85186
85187
  class SectionExporter extends BaseExporter {
85188
+ constructor(data, _section) {
85189
+ super(data);
85190
+ this._section = _section;
85191
+ }
85187
85192
  static createDefaultProperties() {
85188
85193
  const props = new SectionProperties();
85189
85194
  props.pageSize = new geometry_size.Size(12240, 15840);
@@ -85193,15 +85198,22 @@ class SectionExporter extends BaseExporter {
85193
85198
  props.space = unit_converter/* UnitConverter */.u.hundredthsOfMillimeterToTwips(1250);
85194
85199
  return props;
85195
85200
  }
85196
- exportProperties(section) {
85201
+ exportProperties() {
85197
85202
  this.writer.writeWpStartElement('sectPr');
85198
- this.exportSectionHeadersFootersCore(section);
85199
- this.exportSectionPropertiesCore(section);
85203
+ this.exportSectionHeadersFootersCore(this._section);
85204
+ this.exportSectionPropertiesCore(this._section);
85200
85205
  this.writer.endElement();
85201
85206
  }
85202
85207
  exportHeaderFooter(collection, type) {
85203
85208
  const info = collection.getObject(type);
85204
85209
  if (info) {
85210
+ const currentSectionIndex = this.data.model.sections.indexOf(this._section);
85211
+ const prevSection = this.data.model.sections[currentSectionIndex - 1];
85212
+ if (prevSection) {
85213
+ const prevSectionContainer = info.isHeader ? prevSection.headers : prevSection.footers;
85214
+ if (info === prevSectionContainer.getObject(type))
85215
+ return;
85216
+ }
85205
85217
  const subDocument = this.data.model.subDocuments[info.subDocumentId];
85206
85218
  this.data.exportSubDocumentsList.push(subDocument);
85207
85219
  const relationId = `${subDocument.isHeader() ? 'header' : 'footer'}${subDocument.id}`;
@@ -85408,7 +85420,7 @@ class ParagraphPropertiesExporter extends BaseExporter {
85408
85420
  this.writer.writeWpStringValue('pStyle', this.data.parStyleExporter.getStyleId(this.data.parStyleExporter.getStyleIndexByName(paragraph.paragraphStyle.styleName)));
85409
85421
  this.data.charPropsExporter.exportRunProperties(paragraphRun);
85410
85422
  if (this.shouldExportSectionProperties(subDocument, section, paragraph))
85411
- new SectionExporter(this.data).exportProperties(section);
85423
+ new SectionExporter(this.data, section).exportProperties();
85412
85424
  this.writer.endElement();
85413
85425
  }
85414
85426
  }
@@ -87809,7 +87821,7 @@ class MainSubDocumentExporter extends BaseSubDocumentExporter {
87809
87821
  this.init();
87810
87822
  for (const section of this.data.model.sections)
87811
87823
  this.exportSection(section, section.interval);
87812
- new SectionExporter(this.data).exportProperties(utils_list.ListUtils.last(this.data.model.sections));
87824
+ new SectionExporter(this.data, utils_list.ListUtils.last(this.data.model.sections)).exportProperties();
87813
87825
  this.writer.endElement();
87814
87826
  }
87815
87827
  exportDocumentBackground() {
@@ -95607,6 +95619,7 @@ class BaseFormatter {
95607
95619
  this.layoutPosition.column.height = columnHeight;
95608
95620
  this.layoutPosition.pageArea.height = columnHeight;
95609
95621
  this.layoutPosition.page.height = finalPageHeight;
95622
+ this.layoutPosition.page.minContentHeight = minVisibleAreaHeight;
95610
95623
  }
95611
95624
  createdColumn.paragraphFrames = ParagraphFrameCollector.collect(this.manager.model.colorProvider, createdColumn, this.subDocument.isMain() ?
95612
95625
  this.layoutPosition.page.getPosition() + this.layoutPosition.pageArea.pageOffset : 0, this.subDocument.paragraphs);
@@ -96671,7 +96684,7 @@ class OtherPageAreaFormatter {
96671
96684
  const column = pageArea.columns[0];
96672
96685
  const bottomPos = column.getLastRow().bottom;
96673
96686
  const diff = column.height - bottomPos;
96674
- if (diff > 0) {
96687
+ if (!Number.isNaN(diff)) {
96675
96688
  column.height -= diff;
96676
96689
  pageArea.height -= diff;
96677
96690
  textBox.height -= diff;
@@ -107908,6 +107921,16 @@ class SimpleViewRenderer extends DocumentRenderer {
107908
107921
  utils_list.ListUtils.forEach(column.tablesInfo, (t) => tablesContainer.appendChild(DocumentRenderer.renderTable(t, level, this.viewManager.innerClientProperties.showTableGridLines)), bounds.tables.start, bounds.tables.end);
107909
107922
  return columnElement;
107910
107923
  }
107924
+ updatePageSize(page, pageElement) {
107925
+ if (page.minContentHeight < page.height) {
107926
+ const before = this.viewManager.canvas.offsetHeight;
107927
+ pageElement.style.height = `${page.minContentHeight}px`;
107928
+ if (this.viewManager.canvas.offsetHeight < before) {
107929
+ page.height = page.minContentHeight;
107930
+ }
107931
+ }
107932
+ super.updatePageSize(page, pageElement);
107933
+ }
107911
107934
  }
107912
107935
 
107913
107936
  ;// CONCATENATED MODULE: ./core/src/layout/selection/layout-selection-items.ts
@@ -109792,6 +109815,7 @@ const TAB_KEYCODE = 9;
109792
109815
  const IDEOGRAPHIC_SPACE_CHARCODE = 12288;
109793
109816
  class InputEditorBase {
109794
109817
  constructor(control, eventManager, parent) {
109818
+ this.processTextOnKeyPress = false;
109795
109819
  this.evtHandlersHolder = new event_handlers_holder/* DomEventHandlersHolder */.$();
109796
109820
  this.control = control;
109797
109821
  this.eventManager = eventManager;
@@ -109879,10 +109903,7 @@ class InputEditorBase {
109879
109903
  }
109880
109904
  }
109881
109905
  if (!this.canInsertTextOnInputEvent && !this.control.isTouchMode())
109882
- this.imeTimerId = setTimeout(() => {
109883
- if (!this.isIME)
109884
- this.onTextInput(undefined);
109885
- }, 0);
109906
+ this.processTextOnKeyPress = true;
109886
109907
  this.prevKeyCode = keyCode;
109887
109908
  }
109888
109909
  }
@@ -109902,6 +109923,13 @@ class InputEditorBase {
109902
109923
  if (!evt.altKey) {
109903
109924
  if (this.inputWithAlt)
109904
109925
  this.keyPressTimerId = setTimeout(() => this.onTextInput(undefined), 0);
109926
+ else if (this.processTextOnKeyPress) {
109927
+ this.imeTimerId = setTimeout(() => {
109928
+ if (!this.isIME)
109929
+ this.onTextInput(undefined);
109930
+ }, 0);
109931
+ }
109932
+ this.processTextOnKeyPress = false;
109905
109933
  this.inputWithAlt = false;
109906
109934
  }
109907
109935
  }
@@ -137271,8 +137299,17 @@ class FieldClientRequestManager extends FieldRequestManager {
137271
137299
  const record = this.getRecord();
137272
137300
  const keys = Object.keys(record);
137273
137301
  for (let i = 0, key; key = keys[i]; i++)
137274
- if (key.toLowerCase() == fieldName.toLowerCase())
137275
- return record[key] + '';
137302
+ if (key.toLowerCase() == fieldName.toLowerCase()) {
137303
+ switch (typeof record[key]) {
137304
+ case 'object':
137305
+ if (record[key] instanceof Date)
137306
+ return record[key];
137307
+ return JSON.stringify(record[key], (k, v) => (k && typeof v === 'object') ? v.toString() : v, 1)
137308
+ .replace(/^ +/gm, " ").replace(/\n/g, "").replace(/{ /g, "{").replace(/ }/g, "}").replace(/\[ /g, "[").replace(/ \]/g, "]");
137309
+ default:
137310
+ return String(record[key]);
137311
+ }
137312
+ }
137276
137313
  return '';
137277
137314
  }
137278
137315
  getRecord() {
@@ -140931,6 +140968,9 @@ class FullScreenHelper {
140931
140968
  }
140932
140969
  }
140933
140970
 
140971
+ ;// CONCATENATED MODULE: external "DevExpress.config"
140972
+ var external_DevExpress_config_namespaceObject = DevExpress.config;
140973
+ var external_DevExpress_config_default = /*#__PURE__*/__webpack_require__.n(external_DevExpress_config_namespaceObject);
140934
140974
  ;// CONCATENATED MODULE: ./client/src/client-rich-edit.ts
140935
140975
 
140936
140976
 
@@ -140962,6 +141002,7 @@ class FullScreenHelper {
140962
141002
 
140963
141003
 
140964
141004
 
141005
+
140965
141006
 
140966
141007
 
140967
141008
  class ClientRichEdit {
@@ -140985,6 +141026,8 @@ class ClientRichEdit {
140985
141026
  this.rawDataSource = settings.rawDataSource;
140986
141027
  this.contextMenuSettings = settings.contextMenuSettings;
140987
141028
  this.fullScreenHelper = new FullScreenHelper(element);
141029
+ if (true)
141030
+ external_DevExpress_config_default()(JSON.parse(atob('eyJsaWNlbnNlS2V5IjoiZXdvZ0lDSm1iM0p0WVhRaU9pQXhMQW9nSUNKcGJuUmxjbTVoYkZWellXZGxTV1FpT2lBaVQxWXljbXQwYlhSVk1IRkhXRlp3V0VNNWIweDNaeUlLZlE9PS53WnNHemNlSVJvVUNjRW5qcFE3YkxscHpIM2liVThMYVZGczZZWXpwVDMwYjBLdzFzZ0lYckZ5MFcyNUtFZWZPRWFPTkVTc1dLbGMwRGl5V1I4amxCY1NSUWEyaEJMUXY1S1ZJU1F4aWlYVmhORmRIb2I5NFNBUDZuajNmeExKSVlDdTlydz09In0=')));
140988
141031
  this.prepareElement(element, settings);
140989
141032
  this.initDefaultFontsAndStyles();
140990
141033
  this.initBars(settings.ribbon, settings.fonts);
@@ -141264,6 +141307,7 @@ class ClientRichEdit {
141264
141307
  }
141265
141308
  this.core.horizontalRulerControl.adjust();
141266
141309
  const rulerHeight = this.core.horizontalRulerControl.getHeight();
141310
+ this.core.viewManager.canvas.style.height = "0";
141267
141311
  this.core.viewManager.canvas.style.height = this.element.clientHeight - rulerHeight - ribbonHeight + "px";
141268
141312
  this.core.viewManager.adjust(true);
141269
141313
  }