feat: add fullscreen mode toggle button
- Add src/utils/fullscreen.js with createFullscreenButton() helper - Fullscreen button appears in bottom-right corner of all scenes - Click to toggle fullscreen mode - Uses Phaser's built-in scale manager Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import { fontSize } from '../utils/responsive.js';
|
||||
import { createFullscreenButton } from '../utils/fullscreen.js';
|
||||
|
||||
export default class IntroScene extends Phaser.Scene {
|
||||
constructor() {
|
||||
@@ -78,6 +79,9 @@ export default class IntroScene extends Phaser.Scene {
|
||||
fontSize: fontSize(16),
|
||||
fill: '#ffff99'
|
||||
}).setOrigin(0.5);
|
||||
|
||||
// Fullscreen button
|
||||
createFullscreenButton(this);
|
||||
}
|
||||
|
||||
drawWaves() {
|
||||
|
||||
Reference in New Issue
Block a user