@portabletext/editor 1.48.0 → 1.48.2
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/_chunks-cjs/editor-provider.cjs +5 -5
- package/lib/_chunks-cjs/editor-provider.cjs.map +1 -1
- package/lib/_chunks-es/editor-provider.js +5 -5
- package/lib/_chunks-es/editor-provider.js.map +1 -1
- package/lib/plugins/index.cjs +16 -5
- package/lib/plugins/index.cjs.map +1 -1
- package/lib/plugins/index.js +16 -5
- package/lib/plugins/index.js.map +1 -1
- package/package.json +1 -1
- package/src/behaviors/behavior.perform-event.ts +8 -4
- package/src/plugins/plugin.one-line.tsx +22 -8
|
@@ -6734,10 +6734,10 @@ function performEvent({
|
|
|
6734
6734
|
}, shouldRun);
|
|
6735
6735
|
if (actions.length !== 0) {
|
|
6736
6736
|
if (actions.some((action) => action.type === "execute")) {
|
|
6737
|
-
|
|
6737
|
+
withUndoStep(editor, () => {
|
|
6738
6738
|
for (const action of actions) {
|
|
6739
6739
|
if (action.type === "effect") {
|
|
6740
|
-
performAction({
|
|
6740
|
+
nativeEventPrevented = !0, performAction({
|
|
6741
6741
|
context: {
|
|
6742
6742
|
keyGenerator,
|
|
6743
6743
|
schema
|
|
@@ -6765,7 +6765,7 @@ function performEvent({
|
|
|
6765
6765
|
continue;
|
|
6766
6766
|
}
|
|
6767
6767
|
if (action.type === "raise") {
|
|
6768
|
-
performEvent({
|
|
6768
|
+
nativeEventPrevented = !0, performEvent({
|
|
6769
6769
|
mode: "raise",
|
|
6770
6770
|
behaviors,
|
|
6771
6771
|
remainingEventBehaviors: behaviors,
|
|
@@ -6779,7 +6779,7 @@ function performEvent({
|
|
|
6779
6779
|
continue;
|
|
6780
6780
|
}
|
|
6781
6781
|
if (isAbstractBehaviorEvent(action.event))
|
|
6782
|
-
performEvent({
|
|
6782
|
+
nativeEventPrevented = !0, performEvent({
|
|
6783
6783
|
mode: "execute",
|
|
6784
6784
|
behaviors,
|
|
6785
6785
|
remainingEventBehaviors: behaviors,
|
|
@@ -6818,7 +6818,7 @@ function performEvent({
|
|
|
6818
6818
|
}
|
|
6819
6819
|
for (const action of actions) {
|
|
6820
6820
|
if (action.type === "effect") {
|
|
6821
|
-
performAction({
|
|
6821
|
+
nativeEventPrevented = !0, performAction({
|
|
6822
6822
|
context: {
|
|
6823
6823
|
keyGenerator,
|
|
6824
6824
|
schema
|