Skip to content

Commit d401f46

Browse files
AmirMohammad CheraghaliAmirMohammad Cheraghali
authored andcommitted
feat(ui): Replace Reset View with Share Live button in sidebar
- Replaced Reset View button with 'Share Live' button - Connected to onToggleShare handler - Styled with green theme - Preserved Reset View in mobile menu
1 parent 790436f commit d401f46

1 file changed

Lines changed: 9 additions & 11 deletions

File tree

src/components/Controls.tsx

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -476,7 +476,6 @@ export const Controls: React.FC<ControlsProps> = ({
476476
setCustomColors,
477477
visualizerEngine,
478478
setVisualizerEngine,
479-
onResetCamera,
480479
isRocking,
481480
setIsRocking
482481
}) => {
@@ -1108,16 +1107,15 @@ export const Controls: React.FC<ControlsProps> = ({
11081107
<span className="text-[10px] font-bold">Mol*</span>
11091108
</button>
11101109

1111-
{onResetCamera && (
1112-
<button
1113-
onClick={onResetCamera}
1114-
className={`col-span-2 h-10 flex items-center justify-center gap-2 rounded-lg border transition-all ${cardBg} opacity-80 hover:opacity-100 hover:bg-white/5 border-neutral-700/50`}
1115-
title="Reset camera to default view"
1116-
>
1117-
<RotateCcw className="w-3.5 h-3.5" />
1118-
<span className="text-[10px] font-medium">Reset View</span>
1119-
</button>
1120-
)}
1110+
{/* Share Button - Replaces Reset View */}
1111+
<button
1112+
onClick={onToggleShare}
1113+
className={`col-span-2 h-10 flex items-center justify-center gap-2 rounded-lg border transition-all bg-green-500/10 border-green-500/50 text-green-500 hover:bg-green-500/20 hover:border-green-500`}
1114+
title="Share Live Session"
1115+
>
1116+
<Share2 className="w-3.5 h-3.5" />
1117+
<span className="text-[10px] font-bold">Share</span>
1118+
</button>
11211119

11221120
{/* ROW 3: Layout Grid - Spread across 4 columns */}
11231121
{onSetViewMode && (

0 commit comments

Comments
 (0)