@@ -677,20 +677,10 @@ window.onhashchange = () => {
677677
678678populateVersions ( ) ;
679679
680- let comparisonMode = false ;
681680/* ============================================
682681 UI HELPER FUNCTIONS
683682 ============================================ */
684683
685- /**
686- * Show loading state for comparison
687- */
688- const showComparisonLoading = ( ) => {
689- if ( ! comparisonResults ) return ;
690- comparisonResults . innerHTML = '<p style="text-align: center; padding: 20px;">Loading comparison...</p>' ;
691- comparisonResults . classList . remove ( 'hide' ) ;
692- } ;
693-
694684/**
695685 * Show error state for comparison
696686 * @param {Error } error - The error object
@@ -718,9 +708,6 @@ const showComparisonError = (error) => {
718708 * @param {string } versionB - Target version (optional)
719709 */
720710const switchToComparisonMode = ( versionA = null , versionB = null ) => {
721- // Update mode
722- comparisonMode = true ;
723-
724711 // Update button states
725712 if ( comparisonViewBtn && singleViewBtn ) {
726713 comparisonViewBtn . classList . add ( 'active' , 'btn-primary' ) ;
@@ -972,18 +959,6 @@ const handleEnhancedComparisonURL = async () => {
972959
973960 return { shouldCompare : false } ;
974961} ;
975-
976- /**
977- * Populate version dropdowns for comparison mode
978- */
979- const populateComparisonVersions = ( ) => {
980- if ( versionSelectDropdown && versionSelectDropdown . innerHTML ) {
981- const options = versionSelectDropdown . innerHTML ;
982- if ( versionASelect ) versionASelect . innerHTML = options ;
983- if ( versionBSelect ) versionBSelect . innerHTML = options ;
984- }
985- } ;
986-
987962/**
988963 * Reset comparison form selections
989964 */
@@ -1067,7 +1042,6 @@ const updatePrereleaseLabels = () => {
10671042 * Handle stable version changes - fetch changelogs and populate packages
10681043 */
10691044const handleStableVersionChange = async ( ) => {
1070- console . log ( '🟢 handleStableVersionChange FIRED' ) ;
10711045 const stableA = versionASelect . value ;
10721046 const stableB = versionBSelect . value ;
10731047
@@ -1095,7 +1069,6 @@ const handleStableVersionChange = async () => {
10951069 * Handle package selection - populate pre-release versions
10961070 */
10971071const handlePackageChange = ( ) => {
1098- console . log ( '🟢 handlePackageChange FIRED' ) ;
10991072 const selectedPackage = comparisonPackageSelect . value ;
11001073
11011074 if ( versionAPrereleaseSelect ) versionAPrereleaseSelect . value = '' ;
@@ -1130,8 +1103,6 @@ const handlePackageChange = () => {
11301103 * Switch to single view mode
11311104 */
11321105const switchToSingleViewMode = ( ) => {
1133- console . log ( '🔵 Switching to SINGLE VIEW mode' ) ;
1134- comparisonMode = false ;
11351106
11361107 // Update button styles
11371108 singleViewBtn . classList . add ( 'active' , 'btn-primary' ) ;
@@ -1145,25 +1116,6 @@ const switchToSingleViewMode = () => {
11451116 clearComparisonURLParams ( ) ;
11461117} ;
11471118
1148- /**
1149- * Switch to comparison view mode
1150- */
1151- const switchToComparisonViewMode = ( ) => {
1152- console . log ( '🔵 Switching to COMPARISON VIEW mode' ) ;
1153- comparisonMode = true ;
1154-
1155- // Update button styles
1156- comparisonViewBtn . classList . add ( 'active' , 'btn-primary' ) ;
1157- comparisonViewBtn . classList . remove ( 'btn-default' ) ;
1158- singleViewBtn . classList . remove ( 'active' , 'btn-primary' ) ;
1159- singleViewBtn . classList . add ( 'btn-default' ) ;
1160-
1161- // Toggle visibility (centralized view state)
1162- updateUIVisibility ( 'comparison' ) ;
1163-
1164- populateComparisonVersions ( ) ;
1165- } ;
1166-
11671119/**
11681120 * Validate comparison form inputs
11691121 */
@@ -1357,10 +1309,8 @@ const handleClearClick = () => {
13571309 */
13581310const setupComparisonEventListeners = ( ) => {
13591311 if ( comparisonListenersInitialized ) {
1360- console . log ( '🔴 Comparison listeners already initialized,skipping......' ) ;
13611312 return ;
13621313 }
1363- console . log ( '🟢 Setting up comparison event listeners first time......' ) ;
13641314 comparisonListenersInitialized = true ;
13651315 // Mode toggle buttons
13661316 if ( singleViewBtn ) singleViewBtn . addEventListener ( 'click' , switchToSingleViewMode ) ;
@@ -1451,12 +1401,6 @@ const initializeComparisonMode = async () => {
14511401 await loadEnhancedComparisonFromURL ( enhancedParams ) ;
14521402 return ;
14531403 }
1454-
1455- // Check for standard comparison URL
1456- const urlParams = await handleComparisonURLParams ( ) ;
1457- if ( urlParams . shouldCompare ) {
1458- await loadStandardComparisonFromURL ( urlParams ) ;
1459- }
14601404} ;
14611405
14621406/**
0 commit comments