diff --git a/apps/client/src/widgets/type_widgets/helpers/SplitEditor.tsx b/apps/client/src/widgets/type_widgets/helpers/SplitEditor.tsx
index 64fffd1fc..f2554d9e1 100644
--- a/apps/client/src/widgets/type_widgets/helpers/SplitEditor.tsx
+++ b/apps/client/src/widgets/type_widgets/helpers/SplitEditor.tsx
@@ -16,19 +16,25 @@ export default function SplitEditor({ note }: TypeWidgetProps) {
const splitEditorOrientation = useSplitOrientation();
const [ readOnly ] = useNoteLabelBoolean(note, "readOnly");
+ const editor = (!readOnly &&
+
+
Detail goes here.
+
Errors go here.
+
+ );
+
+ const preview = (
+
+
Preview goes here
+
Buttons go here
+
+ );
+
return (
- {!readOnly && (
-
-
Detail goes here.
-
Errors go here.
-
- )}
-
-
-
Preview goes here
-
Buttons go here
-
+ {splitEditorOrientation === "horizontal"
+ ? <>{editor}{preview}>
+ : <>{preview}{editor}>}
)
}
diff --git a/apps/client/src/widgets/type_widgets_old/abstract_split_type_widget.ts b/apps/client/src/widgets/type_widgets_old/abstract_split_type_widget.ts
index 3850bd083..5234f0037 100644
--- a/apps/client/src/widgets/type_widgets_old/abstract_split_type_widget.ts
+++ b/apps/client/src/widgets/type_widgets_old/abstract_split_type_widget.ts
@@ -104,11 +104,6 @@ export default abstract class AbstractSplitTypeWidget extends TypeWidget {
return;
}
- let elements = [ this.$editorCol[0], this.$previewCol[0] ];
- if (this.layoutOrientation === "vertical") {
- elements.reverse();
- }
-
this.splitInstance?.destroy();
if (!this.isReadOnly) {
@@ -158,10 +153,4 @@ export default abstract class AbstractSplitTypeWidget extends TypeWidget {
return this.editorTypeWidget.getData();
}
- entitiesReloadedEvent({ loadResults }: EventData<"entitiesReloaded">) {
- if (loadResults.isOptionReloaded("splitEditorOrientation")) {
- this.refresh();
- }
- }
-
}