@flozy/editor 3.1.3 → 3.1.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.
|
@@ -91,15 +91,9 @@ const EditorButton = props => {
|
|
|
91
91
|
}
|
|
92
92
|
break;
|
|
93
93
|
case "actionTrigger":
|
|
94
|
-
if (readOnly) {
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
} = buttonLink || {};
|
|
98
|
-
const refUrl = url ? url.includes("http") ? url : `//${url}` : "Link";
|
|
99
|
-
props.component = "a";
|
|
100
|
-
if (refUrl !== "Link") {
|
|
101
|
-
props.href = refUrl;
|
|
102
|
-
}
|
|
94
|
+
if (!readOnly) {
|
|
95
|
+
props.component = "button";
|
|
96
|
+
props.onClick = () => {};
|
|
103
97
|
} else {
|
|
104
98
|
props.component = "button";
|
|
105
99
|
props.onClick = handleTrigger;
|
|
@@ -136,6 +130,8 @@ const EditorButton = props => {
|
|
|
136
130
|
}
|
|
137
131
|
};
|
|
138
132
|
break;
|
|
133
|
+
default:
|
|
134
|
+
return {};
|
|
139
135
|
}
|
|
140
136
|
return props;
|
|
141
137
|
};
|