update endcall button postion
This commit is contained in:
parent
5be6ab12f3
commit
d942222f11
@ -64,13 +64,13 @@ export function ChatOverlay({
|
||||
containerSize.height * 0.6
|
||||
);
|
||||
|
||||
// Position overlay at center when first shown
|
||||
// Position overlay at center (slightly moved up) when first shown
|
||||
const hasPositionedRef = useRef(false);
|
||||
useEffect(() => {
|
||||
if (isVisible && containerRef.current && containerSize.width > 0 && overlayWidth > 0 && overlayHeight > 0) {
|
||||
// Calculate center position
|
||||
// Calculate center position, moved up by 15% of container height
|
||||
const centerX = (containerSize.width - overlayWidth) / 2;
|
||||
const centerY = (containerSize.height - overlayHeight) / 2;
|
||||
const centerY = (containerSize.height - overlayHeight) / 2 - (containerSize.height * 0.15);
|
||||
|
||||
// Only auto-position on first show (when position is at origin)
|
||||
if (!hasPositionedRef.current && position.x === 0 && position.y === 0) {
|
||||
|
||||
@ -1272,8 +1272,8 @@ export function PhoneSimulator({
|
||||
</button>
|
||||
</div>
|
||||
) : (
|
||||
<div className="w-full flex items-center justify-between gap-8">
|
||||
{/* Left side: Mic Toggle */}
|
||||
<div className="w-full flex items-center justify-center gap-4">
|
||||
{/* Mic Toggle */}
|
||||
{phoneMode !== "hand_off" && (
|
||||
<button
|
||||
className={`p-4 rounded-full backdrop-blur-md transition-colors ${
|
||||
@ -1291,7 +1291,7 @@ export function PhoneSimulator({
|
||||
</button>
|
||||
)}
|
||||
|
||||
{/* Right side: End Call Button */}
|
||||
{/* End Call Button */}
|
||||
<button
|
||||
className="p-4 rounded-full bg-red-500 text-white hover:bg-red-600 transition-colors"
|
||||
onClick={handleDisconnect}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user