inital-release
This commit is contained in:
@@ -95,7 +95,7 @@ class TabletCrosswordGame {
|
||||
const headerHeight = 70
|
||||
const progressHeight = 50
|
||||
const sidebarWidth = 180
|
||||
const padding = 60 // 15px on each side x2
|
||||
const padding = 60 // Total padding
|
||||
|
||||
const availableHeight = window.innerHeight - headerHeight - progressHeight - padding
|
||||
const availableWidth = window.innerWidth - sidebarWidth - padding
|
||||
@@ -105,8 +105,20 @@ class TabletCrosswordGame {
|
||||
|
||||
let cellSize = Math.min(maxFromHeight, maxFromWidth)
|
||||
|
||||
// Tablet range: 50-90px for good visibility and touch
|
||||
cellSize = Math.max(50, Math.min(90, cellSize))
|
||||
// Tablet range: 45-80px for better fit and touch
|
||||
cellSize = Math.max(45, Math.min(80, cellSize))
|
||||
|
||||
console.log('Tablet grid:', {
|
||||
screenWidth: window.innerWidth,
|
||||
screenHeight: window.innerHeight,
|
||||
availableHeight,
|
||||
availableWidth,
|
||||
rows,
|
||||
cols,
|
||||
cellSize,
|
||||
totalGridHeight: rows * cellSize,
|
||||
totalGridWidth: cols * cellSize
|
||||
})
|
||||
|
||||
return cellSize
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user