Typo fixes

This commit is contained in:
David Négrier 2020-12-17 15:18:12 +01:00
parent 2236879462
commit 055131ac66
3 changed files with 17 additions and 17 deletions

View file

@ -57,7 +57,7 @@
<form id="gameQuality" hidden>
<section>
<h3>Game quality</h3>
<p class="cautiousText">(Editing this settings will restart the game)</p>
<p class="cautiousText">(Editing these settings will restart the game)</p>
<select id="select-game-quality">
<option value="120">High video quality (120 fps)</option>
<option value="60">Medium video quality (60 fps, recommended)</option>

View file

@ -26,7 +26,7 @@ export class MenuScene extends Phaser.Scene {
constructor() {
super({key: MenuSceneName});
this.gameQualityValue = localUserStore.getGameQualityValue();
this.videoQualityValue = localUserStore.getVideoQualityValue();
}
@ -44,7 +44,7 @@ export class MenuScene extends Phaser.Scene {
this.gameQualityMenuElement = this.add.dom(300, -400).createFromCache(gameSettingsMenuKey);
this.revealMenusAfterInit(this.gameQualityMenuElement, 'gameQuality');
this.input.keyboard.on('keyup-TAB', () => {
this.sideMenuOpened ? this.closeSideMenu() : this.openSideMenu();
});
@ -57,7 +57,7 @@ export class MenuScene extends Phaser.Scene {
this.menuElement.addListener('click');
this.menuElement.on('click', this.onMenuClick.bind(this));
}
private revealMenusAfterInit(menuElement: Phaser.GameObjects.DOMElement, rootDomId: string) {
//Dom elements will appear inside the viewer screen when creating before being moved out of it, which create a flicker effect.
//To prevent this, we put a 'hidden' attribute on the root element, we remove it only after the init is done.
@ -65,11 +65,11 @@ export class MenuScene extends Phaser.Scene {
(menuElement.getChildByID(rootDomId) as HTMLElement).hidden = false;
}, 250);
}
public revealMenuIcon(): void {
(this.menuButton.getChildByID('menuIcon') as HTMLElement).hidden = false
}
openSideMenu() {
if (this.sideMenuOpened) return;
this.sideMenuOpened = true;
@ -85,7 +85,7 @@ export class MenuScene extends Phaser.Scene {
ease: 'Power3'
});
}
private closeSideMenu(): void {
if (!this.sideMenuOpened) return;
this.sideMenuOpened = false;
@ -115,7 +115,7 @@ export class MenuScene extends Phaser.Scene {
this.gameQualityMenuElement.on('click', (event:MouseEvent) => {
event.preventDefault();
if ((event?.target as HTMLInputElement).id === 'gameQualityFormSubmit') {
const gameQualitySelect = this.gameQualityMenuElement.getChildByID('select-game-quality') as HTMLInputElement;
const gameQualitySelect = this.gameQualityMenuElement.getChildByID('select-game-quality') as HTMLInputElement;
const videoQualitySelect = this.gameQualityMenuElement.getChildByID('select-video-quality') as HTMLInputElement;
this.saveSetting(parseInt(gameQualitySelect.value), parseInt(videoQualitySelect.value));
} else if((event?.target as HTMLInputElement).id === 'gameQualityFormCancel') {
@ -143,12 +143,12 @@ export class MenuScene extends Phaser.Scene {
ease: 'Power3'
});
}
private onMenuClick(event:MouseEvent) {
event.preventDefault();
switch ((event?.target as HTMLInputElement).id) {
case 'changeNameButton':
this.closeSideMenu();
@ -175,10 +175,10 @@ export class MenuScene extends Phaser.Scene {
break;
}
}
private async shareUrl() {
await navigator.clipboard.writeText(location.toString());
alert('URL was copy to your clipboard!');
alert('URL is copied to your clipboard!');
}
private saveSetting(valueGame: number, valueVideo: number){
@ -199,4 +199,4 @@ export class MenuScene extends Phaser.Scene {
const sparkHost = 'https://'+window.location.host.replace('play.', 'admin.')+'/register';
window.open(sparkHost, '_blank');
}
}
}

View file

@ -73,9 +73,9 @@
<p>Be sure to keep the repository &quot;Public&quot;.</p>
<p>In your newly created repository, click on the <strong>Settings tab</strong> and scroll down to the <strong>GitHub Pages</strong> section.
Then select the <strong>gh-pages</strong> branch. It might already be selected, but please be sure to click on it nonetheless (otherwise
GitHub will not enable GitHub pages that we use to host your map.</p>
GitHub will not enable GitHub pages).</p>
<p class="text-center"><img src="docs/github_pages.png" alt="" style="width: 70%"></p>
<p>Wait a few minutes a Github will deploy a new website with the content of the repository.
<p>Wait a few minutes... Github will deploy a new website with the content of the repository.
The address of the website is visible in the &quot;GitHub Pages&quot; section.</p>
<p class="text-center"><img src="docs/website_address.png" alt="" style="width: 70%"></p>
<p>Click on the link. You should be redirected directly to WorkAdventure, on your map!</p>