File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed
Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -168,9 +168,11 @@ export const TabContent: React.FC<TabContentProps> = ({
168168 setCodePanelAnimating ( true ) ;
169169
170170 if ( codePanelCollapsed ) {
171+ // Expand to previous size
171172 setCodePanelSize ( codePanelExpandedSize ) ;
172173 setCodePanelCollapsed ( false ) ;
173174 } else {
175+ // Collapse to minimum size - convert current size to pixels for storage
174176 const currentSizePx = typeof codePanelSize === 'string'
175177 ? ( parseFloat ( codePanelSize ) / 100 ) * window . innerWidth
176178 : codePanelSize ;
@@ -179,6 +181,7 @@ export const TabContent: React.FC<TabContentProps> = ({
179181 setCodePanelCollapsed ( true ) ;
180182 }
181183
184+ // Reset animation flag after transition completes
182185 setTimeout ( ( ) => {
183186 setCodePanelAnimating ( false ) ;
184187 } , 200 ) ;
You can’t perform that action at this time.
0 commit comments