undingClientRect();

      if (layoutType === 'topbottom') {
        // Calculate new split ratio based on vertical position
        const newRatio = Math.max(0.1, Math.min(0.9, (e.clientY - rect.top) / rect.height));
        splitRatio = newRatio;
      } else {
        // Calculate new split ratio based on horizontal position
        const newRatio = Math.max(0.1, Math.min(0.9, (e.clientX - rect.left) / rect.width));
        splitRatio = newRatio;
      }

      // Update layout and divider position
     