@kaitify/core 0.0.1-beta.24 → 0.0.1-beta.25
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/kaitify-core.es.js
CHANGED
|
@@ -38050,10 +38050,12 @@ class Editor {
|
|
|
38050
38050
|
this.delete();
|
|
38051
38051
|
return;
|
|
38052
38052
|
} else if (node.isText()) {
|
|
38053
|
-
const
|
|
38054
|
-
|
|
38055
|
-
|
|
38056
|
-
|
|
38053
|
+
const charArray = Array.from(node.textContent.substring(0, offset));
|
|
38054
|
+
const deleteChart = charArray.pop();
|
|
38055
|
+
const deleteChartLength = deleteChart.length;
|
|
38056
|
+
node.textContent = charArray.join("") + node.textContent.substring(offset);
|
|
38057
|
+
this.selection.start.offset = offset - deleteChartLength;
|
|
38058
|
+
this.selection.end.offset = offset - deleteChartLength;
|
|
38057
38059
|
if (isZeroWidthText(deleteChart)) {
|
|
38058
38060
|
this.delete();
|
|
38059
38061
|
return;
|