@hailin-zheng/editor-core 2.1.3 → 2.1.5
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/index-cjs.js +6 -4
- package/index-cjs.js.map +1 -1
- package/index.js +6 -4
- package/index.js.map +1 -1
- package/med_editor/framework/editor-calendar-vnode.d.ts +1 -1
- package/package.json +1 -1
package/index-cjs.js
CHANGED
@@ -26427,9 +26427,10 @@ class EditorCalendarVNode {
|
|
26427
26427
|
this.currTime.value = null;
|
26428
26428
|
this.selectedTime.value = null;
|
26429
26429
|
}
|
26430
|
-
render(position, dataValue) {
|
26430
|
+
render(position, dataValue, format = 'YYYY-MM-DD HH:mm:ss') {
|
26431
|
+
format = format ?? 'YYYY-MM-DD HH:mm:ss';
|
26431
26432
|
if (!this.currentDate && dataValue) {
|
26432
|
-
const currDataValue = moment__default["default"](dataValue);
|
26433
|
+
const currDataValue = moment__default["default"](dataValue, format);
|
26433
26434
|
this.currYear.value = currDataValue.year();
|
26434
26435
|
this.currMonth.value = currDataValue.month();
|
26435
26436
|
this.selectedDate.value = currDataValue.format('YYYY-MM-DD');
|
@@ -28106,6 +28107,7 @@ class DocEditor {
|
|
28106
28107
|
const index = docRender.getIndex();
|
28107
28108
|
const cursorPos = DocumentCursor.getElementCursorPos(ele, 0, region, index);
|
28108
28109
|
//this.selectionState.resetRange(element, 0);
|
28110
|
+
this.documentEvent.mousedownPos = cursorPos.rect;
|
28109
28111
|
this.scrollToPosition(cursorPos.rect);
|
28110
28112
|
}
|
28111
28113
|
}
|
@@ -28589,7 +28591,7 @@ class DocEditor {
|
|
28589
28591
|
if (!dataEle.isValid(currVal)) {
|
28590
28592
|
currVal = '';
|
28591
28593
|
}
|
28592
|
-
return calendar.render(position, currVal);
|
28594
|
+
return calendar.render(position, currVal, dataEle.props.format);
|
28593
28595
|
}
|
28594
28596
|
calendar.reset();
|
28595
28597
|
return null;
|
@@ -28653,7 +28655,7 @@ class DocEditor {
|
|
28653
28655
|
rule.setRuleOptions({ width: this.viewOptions.docPageSettings.width, pagePL, pagePR, docLeft });
|
28654
28656
|
}
|
28655
28657
|
version() {
|
28656
|
-
return "2.1.
|
28658
|
+
return "2.1.5";
|
28657
28659
|
}
|
28658
28660
|
}
|
28659
28661
|
|