@corbe30/fortune-excel 1.2.2 → 1.2.4

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.
@@ -16,10 +16,10 @@ var __extends = (this && this.__extends) || (function () {
16
16
  })();
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
18
  exports.FortuneSheetCelldata = void 0;
19
- var ReadXml_js_1 = require("./ReadXml.js");
20
- var method_js_1 = require("../common/method.js");
21
- var constant_js_1 = require("../common/constant.js");
22
- var FortuneBase_js_1 = require("./FortuneBase.js");
19
+ var ReadXml_1 = require("./ReadXml");
20
+ var method_1 = require("../common/method");
21
+ var constant_1 = require("../common/constant");
22
+ var FortuneBase_1 = require("./FortuneBase");
23
23
  var FortuneSheetCelldata = /** @class */ (function (_super) {
24
24
  __extends(FortuneSheetCelldata, _super);
25
25
  function FortuneSheetCelldata(cell, styles, sharedStrings, mergeCells, sheetFile, ReadXml) {
@@ -33,7 +33,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
33
33
  _this.mergeCells = mergeCells;
34
34
  var attrList = cell.attributeList;
35
35
  var r = attrList.r, s = attrList.s, t = attrList.t;
36
- var range = (0, method_js_1.getcellrange)(r);
36
+ var range = (0, method_1.getcellrange)(r);
37
37
  _this.r = range.row[0];
38
38
  _this.c = range.column[0];
39
39
  _this.v = _this.generateValue(s, t);
@@ -59,7 +59,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
59
59
  var numfmts = this.styles["numfmts"];
60
60
  var clrScheme = this.styles["clrScheme"];
61
61
  var sharedStrings = this.sharedStrings;
62
- var cellValue = new FortuneBase_js_1.FortuneSheetCelldataValue();
62
+ var cellValue = new FortuneBase_1.FortuneSheetCelldataValue();
63
63
  if (f != null) {
64
64
  var formula = f[0], attrList = formula.attributeList;
65
65
  var t_1 = attrList.t, ref = attrList.ref, si = attrList.si;
@@ -71,7 +71,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
71
71
  }
72
72
  // console.log(ref, t, si);
73
73
  if (ref != null || (formulaValue != null && formulaValue.length > 0)) {
74
- formulaValue = (0, method_js_1.escapeCharacter)(formulaValue);
74
+ formulaValue = (0, method_1.escapeCharacter)(formulaValue);
75
75
  cellValue.f = (formulaValue.startsWith('=') ? "" : "=") + formulaValue;
76
76
  }
77
77
  }
@@ -182,8 +182,8 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
182
182
  }
183
183
  if (numFmtId != undefined) {
184
184
  var numf = numfmts[parseInt(numFmtId)];
185
- var cellFormat = new FortuneBase_js_1.FortuneSheetCellFormat();
186
- cellFormat.fa = (0, method_js_1.escapeCharacter)(numf);
185
+ var cellFormat = new FortuneBase_1.FortuneSheetCellFormat();
186
+ cellFormat.fa = (0, method_1.escapeCharacter)(numf);
187
187
  // console.log(numf, numFmtId, this.v);
188
188
  cellFormat.t = t || "n";
189
189
  cellValue.ct = cellFormat;
@@ -218,7 +218,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
218
218
  }
219
219
  if (colors != null && colors.length > 0) {
220
220
  var color = colors[0];
221
- var fc = (0, ReadXml_js_1.getColor)(color, this.styles, "t");
221
+ var fc = (0, ReadXml_1.getColor)(color, this.styles, "t");
222
222
  if (fc != null) {
223
223
  cellValue.fc = fc;
224
224
  }
@@ -226,7 +226,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
226
226
  if (familyOverrides != null && familyOverrides.length > 0) {
227
227
  var val = familyOverrides[0].attributeList.val;
228
228
  if (val != null) {
229
- familyFont = constant_js_1.fontFamilys[val];
229
+ familyFont = constant_1.fontFamilys[val];
230
230
  }
231
231
  }
232
232
  if (family != null && family.length > 0) {
@@ -385,10 +385,10 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
385
385
  var borderIdNum = parseInt(borderId);
386
386
  var border = borders[borderIdNum];
387
387
  // this._borderId = borderIdNum;
388
- var borderObject = new FortuneBase_js_1.FortuneSheetborderInfoCellForImp();
388
+ var borderObject = new FortuneBase_1.FortuneSheetborderInfoCellForImp();
389
389
  borderObject.rangeType = "cell";
390
390
  // borderObject.cells = [];
391
- var borderCellValue = new FortuneBase_js_1.FortuneSheetborderInfoCellValue();
391
+ var borderCellValue = new FortuneBase_1.FortuneSheetborderInfoCellValue();
392
392
  borderCellValue.row_index = this.r;
393
393
  borderCellValue.col_index = this.c;
394
394
  var lefts = border.getInnerElements("left");
@@ -445,7 +445,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
445
445
  if (/&#\d+;/.test(value)) {
446
446
  value = this.htmlDecode(value);
447
447
  }
448
- if (t == constant_js_1.ST_CellType["SharedString"]) {
448
+ if (t == constant_1.ST_CellType["SharedString"]) {
449
449
  var siIndex = parseInt(v[0].value);
450
450
  var sharedSI = sharedStrings[siIndex];
451
451
  var rFlag = sharedSI.getInnerElements("r");
@@ -456,7 +456,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
456
456
  tFlag.forEach(function (t) {
457
457
  text_1 += t.value;
458
458
  });
459
- text_1 = (0, method_js_1.escapeCharacter)(text_1);
459
+ text_1 = (0, method_1.escapeCharacter)(text_1);
460
460
  //isContainMultiType(text) &&
461
461
  if (familyFont == "Roman" && text_1.length > 0) {
462
462
  var textArray = text_1.split("");
@@ -467,7 +467,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
467
467
  }
468
468
  var cellFormat = cellValue.ct;
469
469
  if (cellFormat == null) {
470
- cellFormat = new FortuneBase_js_1.FortuneSheetCellFormat();
470
+ cellFormat = new FortuneBase_1.FortuneSheetCellFormat();
471
471
  }
472
472
  if (cellFormat.s == null) {
473
473
  cellFormat.s = [];
@@ -475,15 +475,15 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
475
475
  for (var i = 0; i < textArray.length; i++) {
476
476
  var w = textArray[i];
477
477
  var type = null, ff = wholef;
478
- if ((0, method_js_1.isChinese)(w)) {
478
+ if ((0, method_1.isChinese)(w)) {
479
479
  type = "c";
480
480
  ff = "宋体";
481
481
  }
482
- else if ((0, method_js_1.isJapanese)(w)) {
482
+ else if ((0, method_1.isJapanese)(w)) {
483
483
  type = "j";
484
484
  ff = "Yu Gothic";
485
485
  }
486
- else if ((0, method_js_1.isKoera)(w)) {
486
+ else if ((0, method_1.isKoera)(w)) {
487
487
  type = "k";
488
488
  ff = "Malgun Gothic";
489
489
  }
@@ -570,7 +570,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
570
570
  InlineString.v = text_1;
571
571
  var cellFormat = cellValue.ct;
572
572
  if (cellFormat == null) {
573
- cellFormat = new FortuneBase_js_1.FortuneSheetCellFormat();
573
+ cellFormat = new FortuneBase_1.FortuneSheetCellFormat();
574
574
  }
575
575
  if (cellValue.ff != null) {
576
576
  InlineString.ff = cellValue.ff;
@@ -613,15 +613,15 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
613
613
  if (tFlag != null && tFlag.length > 0) {
614
614
  var text = tFlag[0].value;
615
615
  text = _this.replaceSpecialWrap(text);
616
- text = (0, method_js_1.escapeCharacter)(text);
616
+ text = (0, method_1.escapeCharacter)(text);
617
617
  InlineString.v = text;
618
618
  }
619
619
  if (rPr != null && rPr.length > 0) {
620
620
  var frpr = rPr[0];
621
- var sz = (0, ReadXml_js_1.getlineStringAttr)(frpr, "sz"), rFont = (0, ReadXml_js_1.getlineStringAttr)(frpr, "rFont"), family = (0, ReadXml_js_1.getlineStringAttr)(frpr, "family"), charset = (0, ReadXml_js_1.getlineStringAttr)(frpr, "charset"), scheme = (0, ReadXml_js_1.getlineStringAttr)(frpr, "scheme"), b = (0, ReadXml_js_1.getlineStringAttr)(frpr, "b"), i = (0, ReadXml_js_1.getlineStringAttr)(frpr, "i"), u = (0, ReadXml_js_1.getlineStringAttr)(frpr, "u"), strike = (0, ReadXml_js_1.getlineStringAttr)(frpr, "strike"), vertAlign = (0, ReadXml_js_1.getlineStringAttr)(frpr, "vertAlign"), color = void 0;
621
+ var sz = (0, ReadXml_1.getlineStringAttr)(frpr, "sz"), rFont = (0, ReadXml_1.getlineStringAttr)(frpr, "rFont"), family = (0, ReadXml_1.getlineStringAttr)(frpr, "family"), charset = (0, ReadXml_1.getlineStringAttr)(frpr, "charset"), scheme = (0, ReadXml_1.getlineStringAttr)(frpr, "scheme"), b = (0, ReadXml_1.getlineStringAttr)(frpr, "b"), i = (0, ReadXml_1.getlineStringAttr)(frpr, "i"), u = (0, ReadXml_1.getlineStringAttr)(frpr, "u"), strike = (0, ReadXml_1.getlineStringAttr)(frpr, "strike"), vertAlign = (0, ReadXml_1.getlineStringAttr)(frpr, "vertAlign"), color = void 0;
622
622
  var cEle = frpr.getInnerElements("color");
623
623
  if (cEle != null && cEle.length > 0) {
624
- color = (0, ReadXml_js_1.getColor)(cEle[0], _this.styles, "t");
624
+ color = (0, ReadXml_1.getColor)(cEle[0], _this.styles, "t");
625
625
  }
626
626
  var ff = void 0;
627
627
  // if(family!=null){
@@ -711,7 +711,7 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
711
711
  });
712
712
  var cellFormat = cellValue.ct;
713
713
  if (cellFormat == null) {
714
- cellFormat = new FortuneBase_js_1.FortuneSheetCellFormat();
714
+ cellFormat = new FortuneBase_1.FortuneSheetCellFormat();
715
715
  }
716
716
  cellFormat.t = "inlineStr";
717
717
  cellFormat.s = styles_1;
@@ -719,11 +719,11 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
719
719
  }
720
720
  }
721
721
  // to be confirmed
722
- else if (t == constant_js_1.ST_CellType["InlineString"] && v != null) {
722
+ else if (t == constant_1.ST_CellType["InlineString"] && v != null) {
723
723
  cellValue.v = "'" + value;
724
724
  }
725
725
  else {
726
- value = (0, method_js_1.escapeCharacter)(value);
726
+ value = (0, method_1.escapeCharacter)(value);
727
727
  cellValue.v = value;
728
728
  }
729
729
  }
@@ -749,11 +749,11 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
749
749
  var fg = void 0, bg = void 0;
750
750
  if (fgColors != null) {
751
751
  var fgColor = fgColors[0];
752
- fg = (0, ReadXml_js_1.getColor)(fgColor, this.styles);
752
+ fg = (0, ReadXml_1.getColor)(fgColor, this.styles);
753
753
  }
754
754
  if (bgColors != null) {
755
755
  var bgColor = bgColors[0];
756
- bg = (0, ReadXml_js_1.getColor)(bgColor, this.styles);
756
+ bg = (0, ReadXml_1.getColor)(bgColor, this.styles);
757
757
  }
758
758
  // console.log(fgColors,bgColors,clrScheme);
759
759
  if (fg != null) {
@@ -785,13 +785,13 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
785
785
  var colorRet = "#000000";
786
786
  if (colors != null) {
787
787
  var color = colors[0];
788
- colorRet = (0, ReadXml_js_1.getColor)(color, this.styles, "b");
788
+ colorRet = (0, ReadXml_1.getColor)(color, this.styles, "b");
789
789
  if (colorRet == null) {
790
790
  colorRet = "#000000";
791
791
  }
792
792
  }
793
- var ret = new FortuneBase_js_1.FortuneSheetborderInfoCellValueStyle();
794
- ret.style = constant_js_1.borderTypes[style];
793
+ var ret = new FortuneBase_1.FortuneSheetborderInfoCellValueStyle();
794
+ ret.style = constant_1.borderTypes[style];
795
795
  ret.color = colorRet;
796
796
  return ret;
797
797
  };
@@ -801,5 +801,5 @@ var FortuneSheetCelldata = /** @class */ (function (_super) {
801
801
  });
802
802
  };
803
803
  return FortuneSheetCelldata;
804
- }(FortuneBase_js_1.FortuneSheetCelldataBase));
804
+ }(FortuneBase_1.FortuneSheetCelldataBase));
805
805
  exports.FortuneSheetCelldata = FortuneSheetCelldata;
@@ -1,5 +1,5 @@
1
- import { IuploadfileList } from "../common/ICommon.js";
2
- import { FortuneFileBase } from "./FortuneBase.js";
1
+ import { IuploadfileList } from "../common/ICommon";
2
+ import { FortuneFileBase } from "./FortuneBase";
3
3
  export declare class FortuneFile {
4
4
  private files;
5
5
  private sheetNameList;
@@ -12,42 +12,42 @@ var __rest = (this && this.__rest) || function (s, e) {
12
12
  };
13
13
  Object.defineProperty(exports, "__esModule", { value: true });
14
14
  exports.FortuneFile = void 0;
15
- var FortuneSheet_js_1 = require("./FortuneSheet.js");
16
- var constant_js_1 = require("../common/constant.js");
17
- var ReadXml_js_1 = require("./ReadXml.js");
18
- var method_js_1 = require("../common/method.js");
19
- var FortuneBase_js_1 = require("./FortuneBase.js");
20
- var FortuneImage_js_1 = require("./FortuneImage.js");
15
+ var FortuneSheet_1 = require("./FortuneSheet");
16
+ var constant_1 = require("../common/constant");
17
+ var ReadXml_1 = require("./ReadXml");
18
+ var method_1 = require("../common/method");
19
+ var FortuneBase_1 = require("./FortuneBase");
20
+ var FortuneImage_1 = require("./FortuneImage");
21
21
  var FortuneFile = /** @class */ (function () {
22
22
  function FortuneFile(files, fileName) {
23
23
  this.columnWidthSet = [];
24
24
  this.rowHeightSet = [];
25
25
  this.files = files;
26
26
  this.fileName = fileName;
27
- this.readXml = new ReadXml_js_1.ReadXml(files);
27
+ this.readXml = new ReadXml_1.ReadXml(files);
28
28
  this.getSheetNameList();
29
- this.sharedStrings = this.readXml.getElementsByTagName("sst/si", constant_js_1.sharedStringsFile);
30
- this.calcChain = this.readXml.getElementsByTagName("calcChain/c", constant_js_1.calcChainFile);
29
+ this.sharedStrings = this.readXml.getElementsByTagName("sst/si", constant_1.sharedStringsFile);
30
+ this.calcChain = this.readXml.getElementsByTagName("calcChain/c", constant_1.calcChainFile);
31
31
  this.styles = {};
32
- this.styles["cellXfs"] = this.readXml.getElementsByTagName("cellXfs/xf", constant_js_1.stylesFile);
33
- this.styles["cellStyleXfs"] = this.readXml.getElementsByTagName("cellStyleXfs/xf", constant_js_1.stylesFile);
34
- this.styles["cellStyles"] = this.readXml.getElementsByTagName("cellStyles/cellStyle", constant_js_1.stylesFile);
35
- this.styles["fonts"] = this.readXml.getElementsByTagName("fonts/font", constant_js_1.stylesFile);
36
- this.styles["fills"] = this.readXml.getElementsByTagName("fills/fill", constant_js_1.stylesFile);
37
- this.styles["borders"] = this.readXml.getElementsByTagName("borders/border", constant_js_1.stylesFile);
38
- this.styles["clrScheme"] = this.readXml.getElementsByTagName("a:clrScheme/a:dk1|a:lt1|a:dk2|a:lt2|a:accent1|a:accent2|a:accent3|a:accent4|a:accent5|a:accent6|a:hlink|a:folHlink", constant_js_1.theme1File);
39
- this.styles["indexedColors"] = this.readXml.getElementsByTagName("colors/indexedColors/rgbColor", constant_js_1.stylesFile);
40
- this.styles["mruColors"] = this.readXml.getElementsByTagName("colors/mruColors/color", constant_js_1.stylesFile);
41
- this.imageList = new FortuneImage_js_1.ImageList(files);
42
- var numfmts = this.readXml.getElementsByTagName("numFmt/numFmt", constant_js_1.stylesFile);
43
- var numFmtDefaultC = JSON.parse(JSON.stringify(constant_js_1.numFmtDefault));
32
+ this.styles["cellXfs"] = this.readXml.getElementsByTagName("cellXfs/xf", constant_1.stylesFile);
33
+ this.styles["cellStyleXfs"] = this.readXml.getElementsByTagName("cellStyleXfs/xf", constant_1.stylesFile);
34
+ this.styles["cellStyles"] = this.readXml.getElementsByTagName("cellStyles/cellStyle", constant_1.stylesFile);
35
+ this.styles["fonts"] = this.readXml.getElementsByTagName("fonts/font", constant_1.stylesFile);
36
+ this.styles["fills"] = this.readXml.getElementsByTagName("fills/fill", constant_1.stylesFile);
37
+ this.styles["borders"] = this.readXml.getElementsByTagName("borders/border", constant_1.stylesFile);
38
+ this.styles["clrScheme"] = this.readXml.getElementsByTagName("a:clrScheme/a:dk1|a:lt1|a:dk2|a:lt2|a:accent1|a:accent2|a:accent3|a:accent4|a:accent5|a:accent6|a:hlink|a:folHlink", constant_1.theme1File);
39
+ this.styles["indexedColors"] = this.readXml.getElementsByTagName("colors/indexedColors/rgbColor", constant_1.stylesFile);
40
+ this.styles["mruColors"] = this.readXml.getElementsByTagName("colors/mruColors/color", constant_1.stylesFile);
41
+ this.imageList = new FortuneImage_1.ImageList(files);
42
+ var numfmts = this.readXml.getElementsByTagName("numFmt/numFmt", constant_1.stylesFile);
43
+ var numFmtDefaultC = JSON.parse(JSON.stringify(constant_1.numFmtDefault));
44
44
  for (var i = 0; i < numfmts.length; i++) {
45
45
  var attrList = numfmts[i].attributeList;
46
- var numfmtid = (0, method_js_1.getXmlAttibute)(attrList, "numFmtId", "49");
47
- var formatcode = (0, method_js_1.getXmlAttibute)(attrList, "formatCode", "@");
46
+ var numfmtid = (0, method_1.getXmlAttibute)(attrList, "numFmtId", "49");
47
+ var formatcode = (0, method_1.getXmlAttibute)(attrList, "formatCode", "@");
48
48
  // console.log(numfmtid, formatcode);
49
- if (!(numfmtid in constant_js_1.numFmtDefault)) {
50
- numFmtDefaultC[numfmtid] = constant_js_1.numFmtDefaultMap[formatcode] || formatcode;
49
+ if (!(numfmtid in constant_1.numFmtDefault)) {
50
+ numFmtDefaultC[numfmtid] = constant_1.numFmtDefaultMap[formatcode] || formatcode;
51
51
  }
52
52
  }
53
53
  // console.log(JSON.stringify(numFmtDefaultC), numfmts);
@@ -57,7 +57,7 @@ var FortuneFile = /** @class */ (function () {
57
57
  * @return All sheet name of workbook
58
58
  */
59
59
  FortuneFile.prototype.getSheetNameList = function () {
60
- var workbookRelList = this.readXml.getElementsByTagName("Relationships/Relationship", constant_js_1.workbookRels);
60
+ var workbookRelList = this.readXml.getElementsByTagName("Relationships/Relationship", constant_1.workbookRels);
61
61
  if (workbookRelList == null) {
62
62
  return;
63
63
  }
@@ -94,13 +94,13 @@ var FortuneFile = /** @class */ (function () {
94
94
  * @return workBook information
95
95
  */
96
96
  FortuneFile.prototype.getWorkBookInfo = function () {
97
- var Company = this.readXml.getElementsByTagName("Company", constant_js_1.appFile);
98
- var AppVersion = this.readXml.getElementsByTagName("AppVersion", constant_js_1.appFile);
99
- var creator = this.readXml.getElementsByTagName("dc:creator", constant_js_1.coreFile);
100
- var lastModifiedBy = this.readXml.getElementsByTagName("cp:lastModifiedBy", constant_js_1.coreFile);
101
- var created = this.readXml.getElementsByTagName("dcterms:created", constant_js_1.coreFile);
102
- var modified = this.readXml.getElementsByTagName("dcterms:modified", constant_js_1.coreFile);
103
- this.info = new FortuneBase_js_1.FortuneFileInfo();
97
+ var Company = this.readXml.getElementsByTagName("Company", constant_1.appFile);
98
+ var AppVersion = this.readXml.getElementsByTagName("AppVersion", constant_1.appFile);
99
+ var creator = this.readXml.getElementsByTagName("dc:creator", constant_1.coreFile);
100
+ var lastModifiedBy = this.readXml.getElementsByTagName("cp:lastModifiedBy", constant_1.coreFile);
101
+ var created = this.readXml.getElementsByTagName("dcterms:created", constant_1.coreFile);
102
+ var modified = this.readXml.getElementsByTagName("dcterms:modified", constant_1.coreFile);
103
+ this.info = new FortuneBase_1.FortuneFileInfo();
104
104
  this.info.name = this.fileName;
105
105
  this.info.creator = creator.length > 0 ? creator[0].value : "";
106
106
  this.info.lastmodifiedby =
@@ -115,7 +115,7 @@ var FortuneFile = /** @class */ (function () {
115
115
  */
116
116
  FortuneFile.prototype.getSheetsFull = function (isInitialCell) {
117
117
  if (isInitialCell === void 0) { isInitialCell = true; }
118
- var sheets = this.readXml.getElementsByTagName("sheets/sheet", constant_js_1.workBookFile);
118
+ var sheets = this.readXml.getElementsByTagName("sheets/sheet", constant_1.workBookFile);
119
119
  var sheetList = {};
120
120
  for (var key in sheets) {
121
121
  var sheet = sheets[key];
@@ -133,14 +133,14 @@ var FortuneFile = /** @class */ (function () {
133
133
  var drawing = this.readXml.getElementsByTagName("worksheet/drawing", sheetFile), drawingFile = void 0, drawingRelsFile = void 0;
134
134
  if (drawing != null && drawing.length > 0) {
135
135
  var attrList = drawing[0].attributeList;
136
- var rid_1 = (0, method_js_1.getXmlAttibute)(attrList, "r:id", null);
136
+ var rid_1 = (0, method_1.getXmlAttibute)(attrList, "r:id", null);
137
137
  if (rid_1 != null) {
138
138
  drawingFile = this.getDrawingFile(rid_1, sheetFile);
139
139
  drawingRelsFile = this.getDrawingRelsFile(drawingFile);
140
140
  }
141
141
  }
142
142
  if (sheetFile != null) {
143
- var sheet_1 = new FortuneSheet_js_1.FortuneSheet(sheetName, sheetId, order, isInitialCell, {
143
+ var sheet_1 = new FortuneSheet_1.FortuneSheet(sheetName, sheetId, order, isInitialCell, {
144
144
  sheetFile: sheetFile,
145
145
  readXml: this.readXml,
146
146
  sheetList: sheetList,
@@ -281,9 +281,9 @@ var FortuneFile = /** @class */ (function () {
281
281
  for (var i = 0; i < drawing.length; i++) {
282
282
  var relationship = drawing[i];
283
283
  var attrList = relationship.attributeList;
284
- var relationshipId = (0, method_js_1.getXmlAttibute)(attrList, "Id", null);
284
+ var relationshipId = (0, method_1.getXmlAttibute)(attrList, "Id", null);
285
285
  if (relationshipId == rid) {
286
- var target = (0, method_js_1.getXmlAttibute)(attrList, "Target", null);
286
+ var target = (0, method_1.getXmlAttibute)(attrList, "Target", null);
287
287
  if (target != null) {
288
288
  return target.replace(/\.\.\//g, "");
289
289
  }
@@ -314,7 +314,7 @@ var FortuneFile = /** @class */ (function () {
314
314
  };
315
315
  FortuneFile.prototype.serialize = function () {
316
316
  var _a;
317
- var FortuneOutPutFile = new FortuneBase_js_1.FortuneFileBase();
317
+ var FortuneOutPutFile = new FortuneBase_1.FortuneFileBase();
318
318
  FortuneOutPutFile.info = this.info;
319
319
  FortuneOutPutFile.sheets = [];
320
320
  for (var _i = 0, _b = this.sheets; _i < _b.length; _i++) {
@@ -1,5 +1,5 @@
1
- import { IuploadfileList } from "../common/ICommon.js";
2
- import { FortuneImageBase } from "./FortuneBase.js";
1
+ import { IuploadfileList } from "../common/ICommon";
2
+ import { FortuneImageBase } from "./FortuneBase";
3
3
  export declare class ImageList {
4
4
  private images;
5
5
  constructor(files: IuploadfileList);
@@ -16,8 +16,8 @@ var __extends = (this && this.__extends) || (function () {
16
16
  })();
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
18
  exports.ImageList = void 0;
19
- var FortuneBase_js_1 = require("./FortuneBase.js");
20
- var emf_js_1 = require("../common/emf.js");
19
+ var FortuneBase_1 = require("./FortuneBase");
20
+ var emf_1 = require("../common/emf");
21
21
  var ImageList = /** @class */ (function () {
22
22
  function ImageList(files) {
23
23
  if (files == null) {
@@ -34,15 +34,15 @@ var ImageList = /** @class */ (function () {
34
34
  if (suffix == "emf") {
35
35
  var pNum = 0; // number of the page, that you want to render
36
36
  var scale = 1; // the scale of the document
37
- var wrt = new emf_js_1.ToContext2D(pNum, scale);
37
+ var wrt = new emf_1.ToContext2D(pNum, scale);
38
38
  var inp, out, stt;
39
- emf_js_1.FromEMF.K = [];
40
- inp = emf_js_1.FromEMF.C;
41
- out = emf_js_1.FromEMF.K;
39
+ emf_1.FromEMF.K = [];
40
+ inp = emf_1.FromEMF.C;
41
+ out = emf_1.FromEMF.K;
42
42
  stt = 4;
43
43
  for (var p in inp)
44
44
  out[inp[p]] = p.slice(stt);
45
- emf_js_1.FromEMF.Parse(files[fileKey], wrt);
45
+ emf_1.FromEMF.Parse(files[fileKey], wrt);
46
46
  this.images[fileKey] = wrt.canvas.toDataURL("image/png");
47
47
  }
48
48
  else {
@@ -71,4 +71,4 @@ var Image = /** @class */ (function (_super) {
71
71
  }
72
72
  Image.prototype.setDefault = function () { };
73
73
  return Image;
74
- }(FortuneBase_js_1.FortuneImageBase));
74
+ }(FortuneBase_1.FortuneImageBase));
@@ -1,4 +1,4 @@
1
- import { FortuneSheetBase } from "./FortuneBase.js";
1
+ import { FortuneSheetBase } from "./FortuneBase";
2
2
  export declare class FortuneSheet extends FortuneSheetBase {
3
3
  private readXml;
4
4
  private sheetFile;