testomatio-editor-blocks 0.4.83 → 0.4.84
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.
|
@@ -394,7 +394,11 @@ function TestStepContent({ block, editor, stepNumber, viewMode, autoFocusEnabled
|
|
|
394
394
|
const viewTransitionRef = useRef(false);
|
|
395
395
|
useEffect(() => {
|
|
396
396
|
var _a;
|
|
397
|
-
|
|
397
|
+
// Measure the block's node-view box (the step's real available width). The
|
|
398
|
+
// immediate parent is a `display: contents` anchor with no box, so its width
|
|
399
|
+
// reads as 0 and would wrongly force the vertical layout — in horizontal view
|
|
400
|
+
// that spurious flip remounts the editor and collapses the step on open.
|
|
401
|
+
const el = (_a = containerRef.current) === null || _a === void 0 ? void 0 : _a.closest(".bn-block-content");
|
|
398
402
|
if (!el)
|
|
399
403
|
return;
|
|
400
404
|
const observer = new ResizeObserver((entries) => {
|
package/package.json
CHANGED
|
@@ -510,7 +510,11 @@ function TestStepContent({
|
|
|
510
510
|
const viewTransitionRef = useRef(false);
|
|
511
511
|
|
|
512
512
|
useEffect(() => {
|
|
513
|
-
|
|
513
|
+
// Measure the block's node-view box (the step's real available width). The
|
|
514
|
+
// immediate parent is a `display: contents` anchor with no box, so its width
|
|
515
|
+
// reads as 0 and would wrongly force the vertical layout — in horizontal view
|
|
516
|
+
// that spurious flip remounts the editor and collapses the step on open.
|
|
517
|
+
const el = containerRef.current?.closest(".bn-block-content");
|
|
514
518
|
if (!el) return;
|
|
515
519
|
const observer = new ResizeObserver((entries) => {
|
|
516
520
|
for (const entry of entries) {
|