diff --git a/files/en-us/games/techniques/3d_on_the_web/building_up_a_basic_demo_with_playcanvas/editor/index.md b/files/en-us/games/techniques/3d_on_the_web/building_up_a_basic_demo_with_playcanvas/editor/index.md index f426366e52cf110..d44ce90accda428 100644 --- a/files/en-us/games/techniques/3d_on_the_web/building_up_a_basic_demo_with_playcanvas/editor/index.md +++ b/files/en-us/games/techniques/3d_on_the_web/building_up_a_basic_demo_with_playcanvas/editor/index.md @@ -77,7 +77,7 @@ Now click on the play arrow in the top right corner of the scene to launch and r This looks great! Let's add more shapes to the scene to make it look more interesting. -![PlayCanvas Editor - Boxrender](playcanvas-editor-boxrender.png) +![PlayCanvas Editor - Box render](playcanvas-editor-boxrender.png) ## Adding more shapes @@ -97,7 +97,7 @@ Now follow the same steps as we did before when coloring the cube: ![PlayCanvas Editor - Cylinder material](playcanvas-editor-cylindermaterial.png) -Follow the same approach again to add a cone to the scene, giving it a grayish color (we used EAEFF2.) You should now have three shapes on your scene, something like the below screenshot. +Follow the same approach again to add a cone to the scene, giving it a grayish color (we used `#EAEFF2`.) You should now have three shapes on your scene, something like the below screenshot. ![PlayCanvas Editor - Cone](playcanvas-editor-cone.png) diff --git a/files/en-us/games/techniques/audio_for_web_games/index.md b/files/en-us/games/techniques/audio_for_web_games/index.md index a21425554bb5e9d..d2593d6b52808bd 100644 --- a/files/en-us/games/techniques/audio_for_web_games/index.md +++ b/files/en-us/games/techniques/audio_for_web_games/index.md @@ -143,7 +143,7 @@ The advantage is that we can prime one piece of audio and have our sprites ready ```js const myAudio = document.createElement("audio"); -myAudio.src = "mysprite.mp3"; +myAudio.src = "my-sprite.mp3"; myAudio.play(); myAudio.pause(); ``` diff --git a/files/en-us/games/techniques/control_mechanisms/desktop_with_gamepad/index.md b/files/en-us/games/techniques/control_mechanisms/desktop_with_gamepad/index.md index da104d7f69b9791..f75e1fb5aa5bdf8 100644 --- a/files/en-us/games/techniques/control_mechanisms/desktop_with_gamepad/index.md +++ b/files/en-us/games/techniques/control_mechanisms/desktop_with_gamepad/index.md @@ -346,9 +346,9 @@ if (gamepadAPI.buttonPressed("B")) { } ``` -## The paused and gameover states +## The paused and game-over states -We already learned how to control the whole lifecycle of the game: pausing the gameplay, restarting it, or getting back to the main menu. It works smooth on mobile and desktop, and adding gamepad controls is just as straightforward — in the `update()` function, we check to see if the current state status is `paused` — if so, the relevant actions are enabled: +We already learned how to control the whole lifecycle of the game: pausing the gameplay, restarting it, or getting back to the main menu. It works smooth on mobile and desktop, and adding gamepad controls is just as straightforward — in the `update()` function, we check to see if the current state status is "paused" — if so, the relevant actions are enabled: ```js if (GamepadAPI.buttons.pressed("Start")) { @@ -360,7 +360,7 @@ if (GamepadAPI.buttons.pressed("Back")) { } ``` -Similarly, when the `gameover` state status is active, then we can allow the user to restart the game instead of continuing it: +Similarly, when the "game-over" state status is active, then we can allow the user to restart the game instead of continuing it: ```js if (GamepadAPI.buttons.pressed("Start")) { diff --git a/files/en-us/games/techniques/control_mechanisms/other/index.md b/files/en-us/games/techniques/control_mechanisms/other/index.md index abbc4f722173692..463c0375a3bbde1 100644 --- a/files/en-us/games/techniques/control_mechanisms/other/index.md +++ b/files/en-us/games/techniques/control_mechanisms/other/index.md @@ -72,7 +72,7 @@ You can see it in action by watching [this video](https://www.youtube.com/watch? Have you ever thought about controlling a game only with your hands? It's possible with [Leap Motion](https://www.ultraleap.com/), an immersive controller for games and apps. -Leapmotion is becoming more and more popular due to very good integration with VR headsets — demoing [Rainbow Membrane](https://mozilla.github.io/rainbow/) on an Oculus Rift with Leap Motion attached to it was voted one of the best WebVR experiences by JavaScript developers visiting demo booths at conferences around the world. +Leap Motion is becoming more and more popular due to very good integration with VR headsets — demoing [Rainbow Membrane](https://mozilla.github.io/rainbow/) on an Oculus Rift with Leap Motion attached to it was voted one of the best WebVR experiences by JavaScript developers visiting demo booths at conferences around the world. As well as being great for virtual interfaces, it can also be used for a casual 2D gaming experiences. It would be very difficult to do everything with only your hands, but it's totally doable for the simple Captain Roger's gameplay — steering the ship and shooting the bullets. @@ -158,15 +158,15 @@ The `diff` would be the difference between the initial position of the hand and This approach won't give us the full flexibility of using a Gamepad, or even Leap Motion, but it's definitely an interesting, unconventional alternative. You can use it to scroll a page hands-free, or play theremin, but it should also be enough to move the ship up and down the screen if implemented correctly. -## MaKey MaKey +## Makey Makey -If you want to go completely bananas you can use [MaKey MaKey](https://makeymakey.com/), a board that can turn anything into a controller — it's all about connecting real-world, conductive objects to a computer and using them as touch interfaces. +If you want to go completely bananas you can use [Makey Makey](https://makeymakey.com/), a board that can turn anything into a controller — it's all about connecting real-world, conductive objects to a computer and using them as touch interfaces. ![Controlling a banana piano using Makey Makey.](controls-banana.png) Check out the [banana piano video](https://www.youtube.com/watch?v=_DWQ6ce2Ags), and be sure to visit the [quick start guide](https://learn.sparkfun.com/tutorials/makey-makey-quickstart-guide) for all the needed info. -There's even a [Cylon.js-supported Makey Button functionality](https://cylonjs.com/documentation/drivers/makey-button/) inspired by the MaKey MaKey board, so you can use the popular Cylon robotics framework for your experiments with Arduino or Raspberry Pi. Connecting the boards and using them may look like this: +There's even a [Cylon.js-supported Makey Button functionality](https://cylonjs.com/documentation/drivers/makey-button/) inspired by the Makey Makey board, so you can use the popular Cylon robotics framework for your experiments with Arduino or Raspberry Pi. Connecting the boards and using them may look like this: ```js const Cylon = require("cylon"); diff --git a/files/en-us/games/techniques/tilemaps/index.md b/files/en-us/games/techniques/tilemaps/index.md index d96511c9995b60c..456185408c7f465 100644 --- a/files/en-us/games/techniques/tilemaps/index.md +++ b/files/en-us/games/techniques/tilemaps/index.md @@ -133,4 +133,4 @@ In fast games that might still not be enough. An alternative method would be to - [Demos and source code](https://mozdevs.github.io/gamedev-js-tiles/) - [Grid parts and relationships](https://www.redblobgames.com/grids/parts/) by Amit Patel (May 2021) - - [Isometric graphics in videogames](https://en.wikipedia.org/wiki/Isometric_graphics_in_video_games_and_pixel_art) (Wikipedia) + - [Isometric graphics in video games](https://en.wikipedia.org/wiki/Isometric_graphics_in_video_games_and_pixel_art) (Wikipedia) diff --git a/files/en-us/games/tutorials/2d_breakout_game_phaser/index.md b/files/en-us/games/tutorials/2d_breakout_game_phaser/index.md index 1dff3c1ff633907..c1fc64c70c6581f 100644 --- a/files/en-us/games/tutorials/2d_breakout_game_phaser/index.md +++ b/files/en-us/games/tutorials/2d_breakout_game_phaser/index.md @@ -28,7 +28,7 @@ All the lessons — and the different versions of the [MDN Breakout game](https: 6. [Bounce off the walls](/en-US/docs/Games/Tutorials/2D_breakout_game_Phaser/Bounce_off_the_walls) 7. [Player paddle and controls](/en-US/docs/Games/Tutorials/2D_breakout_game_Phaser/Player_paddle_and_controls) 8. [Game over](/en-US/docs/Games/Tutorials/2D_breakout_game_Phaser/Game_over) -9. [Build the brickfield](/en-US/docs/Games/Tutorials/2D_breakout_game_Phaser/Build_the_brick_field) +9. [Build the brick field](/en-US/docs/Games/Tutorials/2D_breakout_game_Phaser/Build_the_brick_field) 10. [Collision detection](/en-US/docs/Games/Tutorials/2D_breakout_game_Phaser/Collision_detection) 11. [The score](/en-US/docs/Games/Tutorials/2D_breakout_game_Phaser/The_score) 12. [Win the game](/en-US/docs/Games/Tutorials/2D_breakout_game_Phaser/Win_the_game) diff --git a/files/en-us/glossary/accessible_name/index.md b/files/en-us/glossary/accessible_name/index.md index d573dcb58d1eb39..7e5cbe6cdb81c7a 100644 --- a/files/en-us/glossary/accessible_name/index.md +++ b/files/en-us/glossary/accessible_name/index.md @@ -18,7 +18,7 @@ Other elements get their accessible name from the content of associated elements For some elements, the accessible name comes from the element's attributes; for example, the `alt` attribute in the case of {{HTMLElement("img")}}. Given ``, the image's accessible name is "banana." -To create an association between visible content and an element or multiple text nodes and an element, the [`aria-labeledby`](/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-labelledby) attribute can be used. If there is no visible text to associate with a UI element needing an accessible name, the [`aria-label`](/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-label) attribute can be used. Names should not be added to elements marking up inline text, like {{HTMLElement("code")}}, {{HTMLElement("del")}}, and {{HTMLElement("mark")}}. +To create an association between visible content and an element or multiple text nodes and an element, the [`aria-labelledby`](/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-labelledby) attribute can be used. If there is no visible text to associate with a UI element needing an accessible name, the [`aria-label`](/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-label) attribute can be used. Names should not be added to elements marking up inline text, like {{HTMLElement("code")}}, {{HTMLElement("del")}}, and {{HTMLElement("mark")}}. Many elements, such as sections of textual content, don't need an accessible name. All controls should have an accessible name. All images that convey information and aren't purely presentational do too. diff --git a/files/en-us/glossary/entity_header/index.md b/files/en-us/glossary/entity_header/index.md index dc5698d0773e74c..d8d80d70fd26478 100644 --- a/files/en-us/glossary/entity_header/index.md +++ b/files/en-us/glossary/entity_header/index.md @@ -14,7 +14,7 @@ An entity header is an {{glossary("HTTP_header", "HTTP header")}} that describes In the following example, {{HTTPHeader("Content-Length")}} is an entity header, while {{HTTPHeader("Host")}} and {{HTTPHeader("User-Agent")}} are requests headers: ```http -POST /myform.html HTTP/1.1 +POST /my-form.html HTTP/1.1 Host: developer.mozilla.org User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:50.0) Gecko/20100101 Firefox/50.0 Content-Length: 128 diff --git a/files/en-us/glossary/falsy/index.md b/files/en-us/glossary/falsy/index.md index 220cbfd7449fdee..f8c80f3ed761ebb 100644 --- a/files/en-us/glossary/falsy/index.md +++ b/files/en-us/glossary/falsy/index.md @@ -6,6 +6,8 @@ page-type: glossary-definition {{GlossarySidebar}} + + A **falsy** (sometimes written **falsey**) value is a value that is considered false when encountered in a {{Glossary("Boolean")}} context. {{Glossary("JavaScript")}} uses {{Glossary("Type_Conversion", "type conversion")}} to coerce any value to a Boolean in contexts that require it, such as {{Glossary("Conditional", "conditionals")}} and {{Glossary("Loop", "loops")}}. diff --git a/files/en-us/glossary/fetch_metadata_request_header/index.md b/files/en-us/glossary/fetch_metadata_request_header/index.md index 916af11fa2b5dc5..a0790b55248a064 100644 --- a/files/en-us/glossary/fetch_metadata_request_header/index.md +++ b/files/en-us/glossary/fetch_metadata_request_header/index.md @@ -8,7 +8,7 @@ page-type: glossary-definition A **fetch metadata request header** is an {{Glossary("Request header", "HTTP request header")}} that provides additional information about the context from which the request originated. This allows the server to make decisions about whether a request should be allowed based on where the request came from and how the resource will be used. -With this information a server can implement a resource isolation policy, allowing external sites to request only those resources that are intended for sharing, and that are used appropriately. This approach can help mitigate common cross-site web vulnerabilities such as {{Glossary("CSRF")}}, Cross-site Script Inclusion('XSSI'), timing attacks, and cross-origin information leaks. +With this information a server can implement a resource isolation policy, allowing external sites to request only those resources that are intended for sharing, and that are used appropriately. This approach can help mitigate common cross-site web vulnerabilities such as {{Glossary("CSRF")}}, Cross-site Script Inclusion (XSSI), timing attacks, and cross-origin information leaks. These headers are prefixed with `Sec-`, and hence have {{Glossary("Forbidden header name", "forbidden header names")}}. As such, they cannot be modified from JavaScript. diff --git a/files/en-us/glossary/page_load_time/index.md b/files/en-us/glossary/page_load_time/index.md index 7a56ad16b4b2b03..9ae8ce6cd31ab18 100644 --- a/files/en-us/glossary/page_load_time/index.md +++ b/files/en-us/glossary/page_load_time/index.md @@ -11,7 +11,7 @@ page-type: glossary-definition ```js let time = performance.timing; -let pageloadtime = time.loadEventStart - time.navigationStart; +let pageloadTime = time.loadEventStart - time.navigationStart; ``` While page load time 'sounds' like the perfect web performance metric, it isn't. Load times can vary greatly between users depending on device capabilities, network conditions, and, to a lesser extent, distance from the server. The development environment, where page load time is measured, is likely an optimal experience, not reflective of your users' reality. In addition, web performance isn't just about when the load event happens. It's also about {{Glossary("perceived performance")}}, responsiveness, {{Glossary("jank")}} and jitter. diff --git a/files/en-us/glossary/php/index.md b/files/en-us/glossary/php/index.md index 9aadb7a83e2c0db..9e8317259dfc554 100644 --- a/files/en-us/glossary/php/index.md +++ b/files/en-us/glossary/php/index.md @@ -33,15 +33,15 @@ PHP (a recursive initialism for PHP: Hypertext Preprocessor) is an open-source s ```php ``` diff --git a/files/en-us/glossary/response_header/index.md b/files/en-us/glossary/response_header/index.md index a7d68b21ee05377..7a272a0910d653a 100644 --- a/files/en-us/glossary/response_header/index.md +++ b/files/en-us/glossary/response_header/index.md @@ -23,7 +23,7 @@ Etag: "c561c68d0ba92bbeb8b0f612a9199f722e3a621a" Keep-Alive: timeout=5, max=997 Last-Modified: Mon, 18 Jul 2016 02:36:04 GMT Server: Apache -Set-Cookie: mykey=myvalue; expires=Mon, 17-Jul-2017 16:06:00 GMT; Max-Age=31449600; Path=/; secure +Set-Cookie: my-key=my value; expires=Mon, 17-Jul-2017 16:06:00 GMT; Max-Age=31449600; Path=/; secure Transfer-Encoding: chunked Vary: Cookie, Accept-Encoding X-Backend-Server: developer2.webapp.scl3.mozilla.com diff --git a/files/en-us/learn/accessibility/multimedia/index.md b/files/en-us/learn/accessibility/multimedia/index.md index 5346fe1120e2d0d..5f5129e9b3c7490 100644 --- a/files/en-us/learn/accessibility/multimedia/index.md +++ b/files/en-us/learn/accessibility/multimedia/index.md @@ -118,7 +118,7 @@ First of all, let's look at the HTML for the video player, in the HTML:
img[src]
<img src="myimage.png">
but not
+ <img src="my-image.png">
but not
<img>
Used to format the date. For example: -<time datetime="2020-05-24" pubdate> +<time datetime="2020-05-24"> published on 23-05-2020</time>.{{EmbedLiveSample("time-example", 100, 60)}} diff --git a/files/en-us/learn/html/introduction_to_html/html_text_fundamentals/index.md b/files/en-us/learn/html/introduction_to_html/html_text_fundamentals/index.md index 185e81b2e334bda..098010eb8b8aef4 100644 --- a/files/en-us/learn/html/introduction_to_html/html_text_fundamentals/index.md +++ b/files/en-us/learn/html/introduction_to_html/html_text_fundamentals/index.md @@ -993,6 +993,8 @@ Always keep an accessibility mindset. The concept of italics isn't very helpful > [!NOTE] > People strongly associate underlining with hyperlinks. Therefore, on the web, it's best to only underline links. Use the `` element when it's semantically appropriate, but consider using CSS to change the default underline to something more appropriate on the web. The example below illustrates how it can be done. + + ```html
diff --git a/files/en-us/learn/html/multimedia_and_embedding/mozilla_splash_page/index.md b/files/en-us/learn/html/multimedia_and_embedding/mozilla_splash_page/index.md index 15db567f93636fc..6a6163ceb0dd1a8 100644 --- a/files/en-us/learn/html/multimedia_and_embedding/mozilla_splash_page/index.md +++ b/files/en-us/learn/html/multimedia_and_embedding/mozilla_splash_page/index.md @@ -52,7 +52,7 @@ Using your favorite image editor, create 400px wide and 120px wide versions of: - `firefox-addons.jpg` - `mozilla-dinosaur-head.png` -Call them something sensible, e.g. `firefoxlogo400.png` and `firefoxlogo120.png`. +Call them something sensible, e.g. `firefox-logo400.png` and `firefox-logo120.png`. Along with `mdn.svg`, these images will be your icons to link to further resources, inside the `further-info` area. You'll also link to the Firefox logo in the site header. Save copies of all these inside the same directory as `index.html`. diff --git a/files/en-us/learn/html/multimedia_and_embedding/other_embedding_technologies/index.md b/files/en-us/learn/html/multimedia_and_embedding/other_embedding_technologies/index.md index 42ad829f9990ff6..e749e333252b673 100644 --- a/files/en-us/learn/html/multimedia_and_embedding/other_embedding_technologies/index.md +++ b/files/en-us/learn/html/multimedia_and_embedding/other_embedding_technologies/index.md @@ -356,10 +356,10 @@ If you find yourself needing to embed plugin content, this is the kind of inform Let's look at an `