@@ -136,20 +136,16 @@ class HomebrewGamesApp {
136136
137137 // Update page title and header
138138 const systemName = this . getSystemDisplayName ( system ) ;
139- const statusNames = {
140- 'new-games' : 'New Games' ,
141- 'ports' : 'Ports' ,
142- 're-releases' : 'Re-Releases' ,
143- 'in-development' : 'In Development'
144- } ;
145- const statusName = statusNames [ status ] || status . charAt ( 0 ) . toUpperCase ( ) + status . slice ( 1 ) ;
146- document . getElementById ( 'page-title' ) . textContent = `${ systemName } Games` ;
147- document . getElementById ( 'current-system' ) . textContent = systemName ;
148- document . getElementById ( 'current-status' ) . textContent = statusName ;
149- document . title = `${ systemName } ${ statusName } Games - Homebrew Games Archive` ;
139+ const statusKey = `category-${ status } ` ;
140+ const statusName = this . translations [ statusKey ] || status . charAt ( 0 ) . toUpperCase ( ) + status . slice ( 1 ) ;
141+
142+ // Update the title with the new format: "Section name" "System name" "total of games"
143+ document . getElementById ( 'page-title' ) . textContent = `${ statusName } ${ systemName } ` ;
144+ document . title = `${ statusName } ${ systemName } - Homebrew Games Archive` ;
150145
151146 // Filter and display games
152147 this . filterGames ( system , status ) ;
148+ this . updateGamesCount ( ) ;
153149 this . resetGamesList ( ) ;
154150 this . loadMoreGames ( ) ;
155151 }
@@ -160,12 +156,12 @@ class HomebrewGamesApp {
160156 'super-nintendo' : 'Super Nintendo' ,
161157 'master-system' : 'Master System' ,
162158 'nes' : 'NES' ,
163- 'playstation-1' : 'PlayStation' ,
159+ 'playstation-1' : 'PlayStation 1 ' ,
164160 'nintendo-64' : 'Nintendo 64' ,
165161 'sega-saturn' : 'Sega Saturn' ,
166162 'sega-dreamcast' : 'Sega Dreamcast'
167163 } ;
168- return systemNames [ system ] || system ;
164+ return systemNames [ system ] || system . charAt ( 0 ) . toUpperCase ( ) + system . slice ( 1 ) ;
169165 }
170166
171167 async loadGamesData ( ) {
@@ -218,6 +214,7 @@ class HomebrewGamesApp {
218214 ) ;
219215 this . sortGames ( ) ;
220216 this . hasMoreGames = this . filteredGames . length > 0 ;
217+ this . updateGamesCount ( ) ;
221218 }
222219
223220 sortGames ( ) {
@@ -253,6 +250,13 @@ class HomebrewGamesApp {
253250 } ) ;
254251 }
255252
253+ updateGamesCount ( ) {
254+ const gamesTotalElement = document . getElementById ( 'games-total' ) ;
255+ if ( gamesTotalElement && this . filteredGames ) {
256+ gamesTotalElement . textContent = this . filteredGames . length ;
257+ }
258+ }
259+
256260 sortByNumbers ( a , b , ascending = true ) {
257261 // Extract numbers from strings and sort by them
258262 const getNumbers = ( str ) => {
0 commit comments