From bf54d5d76a46fa1da20a0213964a0eda9a96fcbf Mon Sep 17 00:00:00 2001 From: camperbot Date: Fri, 12 May 2023 20:35:58 +0530 Subject: [PATCH] chore(i18n,learn): processed translations (#50366) --- .../jquery/remove-an-element-using-jquery.md | 2 +- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- .../jquery/remove-an-element-using-jquery.md | 2 +- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- .../jquery/remove-an-element-using-jquery.md | 2 +- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- .../jquery/remove-an-element-using-jquery.md | 2 +- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- .../jquery/remove-an-element-using-jquery.md | 2 +- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- .../jquery/remove-an-element-using-jquery.md | 2 +- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- .../jquery/remove-an-element-using-jquery.md | 2 +- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- .../jquery/remove-an-element-using-jquery.md | 2 +- .../64061a98f704a014b44afdb2.md | 10 +- .../6407c4abf5be6d07d8c12ade.md | 12 +- .../6407c6d3f19c4e0a7ba320bb.md | 8 +- .../6407c722498bc80b76d29073.md | 12 +- .../6410e3c19c21cd09c32dc7c6.md | 12 +- .../6410f149110ec60fd40fcfe1.md | 2 +- .../64110727cefd3d1d9bdb0128.md | 4 +- .../6411135e9ee2fa26c882eb02.md | 6 +- .../64112c9cf53d632910ea2f9b.md | 6 +- .../64113124efd2852edafaf25f.md | 14 +-- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- .../css-foundations-exercise-e.md | 20 ++-- .../jquery/remove-an-element-using-jquery.md | 2 +- .../css-foundations-exercise-d.md | 104 ++++++++++++++++-- 29 files changed, 926 insertions(+), 134 deletions(-) diff --git a/curriculum/challenges/arabic/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/arabic/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index 5aeb1a4f6a1..97366562487 100644 --- a/curriculum/challenges/arabic/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/arabic/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery الآن أزل عنصر HTML من صفحتك باستخدام jQuery. -jQuery لديه دالة تسمى `.remove()` التي ستزيل عنصر HTML بالكامل +jQuery has a function called `.remove()` that will remove an HTML element entirely. أزل عنصر `#target4` من الصفحة باستخدام وظيفة `.remove()`. diff --git a/curriculum/challenges/arabic/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/arabic/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index 9ee58af2023..a1deee676a2 100644 --- a/curriculum/challenges/arabic/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/arabic/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -description +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Test 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Test 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Test 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` + diff --git a/curriculum/challenges/chinese-traditional/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/chinese-traditional/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index 20b8d6a13b9..91820544475 100644 --- a/curriculum/challenges/chinese-traditional/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/chinese-traditional/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery 現在學習用 jQuery 從頁面移除 HTML 標籤。 -jQuery 有一個 `.remove()` 方法,能完全移除 HTML 標籤。 +jQuery has a function called `.remove()` that will remove an HTML element entirely. 用 `.remove()` 方法從頁面移除 `#target4` 元素。 diff --git a/curriculum/challenges/chinese-traditional/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/chinese-traditional/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index 9ee58af2023..a1deee676a2 100644 --- a/curriculum/challenges/chinese-traditional/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/chinese-traditional/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -description +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Test 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Test 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Test 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` + diff --git a/curriculum/challenges/chinese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/chinese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index 38b77a357e8..67b9bfaa10c 100644 --- a/curriculum/challenges/chinese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/chinese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery 现在学习用 jQuery 从页面移除 HTML 标签。 -jQuery 有一个 `.remove()` 方法,能完全移除 HTML 标签。 +jQuery has a function called `.remove()` that will remove an HTML element entirely. 用 `.remove()` 方法从页面移除 `#target4` 元素。 diff --git a/curriculum/challenges/chinese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/chinese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index 9ee58af2023..a1deee676a2 100644 --- a/curriculum/challenges/chinese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/chinese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -description +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Test 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Test 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Test 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` + diff --git a/curriculum/challenges/espanol/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/espanol/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index 74f406b2f4f..b8b90107cb7 100644 --- a/curriculum/challenges/espanol/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/espanol/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery Ahora vamos a eliminar un elemento HTML de su página utilizando jQuery. -jQuery tiene una función llamada `.remove()` que eliminará completamente un elemento HTML +jQuery has a function called `.remove()` that will remove an HTML element entirely. Remueve el elemento `#target4` de la página utilizando la función `.remove()`. diff --git a/curriculum/challenges/espanol/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/espanol/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index 9ee58af2023..a1deee676a2 100644 --- a/curriculum/challenges/espanol/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/espanol/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -description +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Test 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Test 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Test 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` + diff --git a/curriculum/challenges/german/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/german/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index 05407a64d5a..718c0d0b2f1 100644 --- a/curriculum/challenges/german/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/german/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery Jetzt wollen wir mit jQuery ein HTML-Element aus deiner Seite entfernen. -jQuery hat eine Funktion namens `.remove()`, die ein HTML-Element vollständig entfernt +jQuery has a function called `.remove()` that will remove an HTML element entirely. Entferne das Element `#target4` aus der Seite, indem du die Funktion `.remove()` verwendest. diff --git a/curriculum/challenges/german/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/german/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index 9ee58af2023..a1deee676a2 100644 --- a/curriculum/challenges/german/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/german/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -description +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Test 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Test 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Test 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` + diff --git a/curriculum/challenges/italian/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/italian/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index 1f80fb1061e..148ff6f8b48 100644 --- a/curriculum/challenges/italian/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/italian/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery Ora rimuoviamo un elemento HTML dalla pagina usando jQuery. -jQuery ha una funzione chiamata `.remove()` per farlo +jQuery has a function called `.remove()` that will remove an HTML element entirely. Rimuovi l'elemento `#target4` dalla pagina utilizzando la funzione `.remove()`. diff --git a/curriculum/challenges/italian/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/italian/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index 9ee58af2023..a1deee676a2 100644 --- a/curriculum/challenges/italian/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/italian/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -description +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Test 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Test 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Test 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` + diff --git a/curriculum/challenges/japanese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/japanese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index 7956a48cd3f..f9866ed3963 100644 --- a/curriculum/challenges/japanese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/japanese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery jQueryを使用して、ページから HTML 要素を削除しましょう。 -jQuery には `.remove()` という関数があり、HTML 要素全体を削除します。 +jQuery has a function called `.remove()` that will remove an HTML element entirely. `.remove()` 関数を使用して、`#target4` 要素をページから削除してください。 diff --git a/curriculum/challenges/japanese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/japanese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index 9ee58af2023..a1deee676a2 100644 --- a/curriculum/challenges/japanese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/japanese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -description +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Test 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Test 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Test 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` + diff --git a/curriculum/challenges/portuguese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/portuguese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index 4e36e8dae25..96594e33c40 100644 --- a/curriculum/challenges/portuguese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/portuguese/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery Agora vamos remover um elemento HTML da sua página usando jQuery. -O jQuery possui uma função chamada `.remove()` que removerá completamente um elemento HTML +jQuery has a function called `.remove()` that will remove an HTML element entirely. Remova o elemento `#target4` da sua página usando a função `.remove()`. diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64061a98f704a014b44afdb2.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64061a98f704a014b44afdb2.md index 04e2a2afb37..adfb38674da 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64061a98f704a014b44afdb2.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64061a98f704a014b44afdb2.md @@ -7,25 +7,25 @@ dashedName: step-1 # --description-- -In this project, you will be building a number sorter. O HTML e o CSS foram fornecidos para você. Feel free to explore them. +Neste projeto, você criará um ordenador de números. O HTML e o CSS foram fornecidos para você. Sinta-se à vontade para explorá-los. -When you are ready, declare a `sortButton` variable and assign it the value of `.getElementById()` with the argument `sort`. +Quando estiver pronto, declare uma variável `sortButton` e atribua a ela o valor de `.getElementById()` com o argumento `sort`. # --hints-- -You should declare a `sortButton` variable with `const`. +Você deve declarar uma variável `sortButton` com `const`. ```js assert.match(code, /const\s+sortButton\s*=/); ``` -You should call `document.getElementById()` with the argument `sort`. +Você deve chamar `document.getElementById()` com o argumento `sort`. ```js assert.match(code, /document\.getElementById\(\s*('|"|`)sort\1\s*\)/); ``` -You should assign the value of `document.getElementById()` to `sortButton`. +Você deve atribuir o valor de `document.getElementById()` a `sortButton`. ```js assert.match(code, /sortButton\s*=\s*document\.getElementById\(\s*('|"|`)sort\1\s*\)/); diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c4abf5be6d07d8c12ade.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c4abf5be6d07d8c12ade.md index 242113e2219..595b90e4c83 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c4abf5be6d07d8c12ade.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c4abf5be6d07d8c12ade.md @@ -7,31 +7,31 @@ dashedName: step-9 # --description-- -To perform an action on each element in the array, use the method that is meant for iterating over arrays. +Para executar uma ação em cada elemento do array, use o método que é feito para percorrer arrays. -Use the `forEach()` method, and pass it an empty callback which takes `num` and `i` as the parameters. +Use o método `forEach()` e passe para ele uma função de callback vazia que recebe `num` e `i` como parâmetros. # --hints-- -You should use the `.forEach()` method to iterate over the `array` parameter. +Você deve usar o método `.forEach()` para percorrer o parâmetro `array`. ```js assert.match(code, /array\.forEach\(/); ``` -Your `.forEach()` method should take a callback function using arrow syntax. +O método `.forEach()` deve receber uma função de callback usando a sintaxe das arrow functions. ```js assert.match(code, /array\.forEach\s*\(\s*\(.*\)\s*=>/); ``` -Your callback function should take two parameters, `num` and `i`. +A função de callback deve receber dois parâmetros, `num` e `i`. ```js assert.match(code, /array\.forEach\s*\(\s*\(\s*num\s*,\s*i\s*\)\s*=>/); ``` -Your callback function should be empty. +A função de callback deve estar vazia. ```js assert.match(code, /array\.forEach\s*\(\s*\(\s*num\s*,\s*i\s*\)\s*=>\s*{\s*}\s*\)/); diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c6d3f19c4e0a7ba320bb.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c6d3f19c4e0a7ba320bb.md index a78e24a016b..1efa915953b 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c6d3f19c4e0a7ba320bb.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c6d3f19c4e0a7ba320bb.md @@ -7,19 +7,19 @@ dashedName: step-12 # --description-- -In your `sortInputArray()` function, call your `updateUI()` function and pass `inputValues` as the argument. +Na função `sortInputArray()`, chame a função `updateUI()` e passe `inputValues` como argumento. -You should now be able to click the `Sort` button and see the inputted array in the `Output` section. +Agora, você deve poder clicar no botão `Sort` e ver o array inserido na seção `Output`. # --hints-- -You should call `updateUI()` in your `sortInputArray()` function. +Você deve chamar `updateUI()` na função `sortInputArray()`. ```js assert.match(sortInputArray.toString(), /updateUI\(/); ``` -You should pass `inputValues` as an argument to `updateUI()`. +Você deve passar `inputValues` como um argumento para `updateUI()`. ```js assert.match(sortInputArray.toString(), /updateUI\(\s*inputValues\s*\)/); diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c722498bc80b76d29073.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c722498bc80b76d29073.md index bb4d792534b..8420869ef8c 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c722498bc80b76d29073.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6407c722498bc80b76d29073.md @@ -7,13 +7,13 @@ dashedName: step-13 # --description-- -Now you need to actually sort the array. The first sorting algorithm you will implement is the bubble sort, which starts at the beginning of the array and 'bubbles up' unsorted values towards the end, iterating through the array until it is completely sorted. +Agora, você precisa realmente ordenar o array. O primeiro algoritmo de ordenação que você implementará é o "bubble sort", que começa no início do array e vai "subindo" entre os valores não ordenados até chegar ao final, iterando através do array até que ele esteja completamente ordenado. -Begin by declaring a `bubbleSort` variable and assigning it an arrow function that takes an `array` parameter. +Comece declarando uma variável `bubbleSort` e atribuindo a ela uma arrow function que recebe um parâmetro `array`. # --hints-- -You should use `const` to declare a `bubbleSort` variable. +Você deve usar `const` para declarar a variável `bubbleSort`. ```js assert.match(code, /const\s+bubbleSort\s*=/); @@ -25,19 +25,19 @@ assert.match(code, /const\s+bubbleSort\s*=/); assert.isFunction(bubbleSort); ``` -`bubbleSort` should use arrow syntax. +`bubbleSort` deve usar a sintaxe das arrow functions. ```js assert.match(code, /const\s+bubbleSort\s*=\s*\(.*\)\s*=>/); ``` -`bubbleSort` should take a single `array` parameter. +`bubbleSort` deve receber um único parâmetro `array`. ```js assert.match(code, /const\s+bubbleSort\s*=\s*\(?\s*array\s*\)?\s*=>/); ``` -`bubbleSort` should be empty. +`bubbleSort` deve estar vazio. ```js assert.match(code, /const\s+bubbleSort\s*=\s*\(?\s*array\s*\)?\s*=>\s*{\s*}/); diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6410e3c19c21cd09c32dc7c6.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6410e3c19c21cd09c32dc7c6.md index d9836c9e6ee..5ac84910207 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6410e3c19c21cd09c32dc7c6.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6410e3c19c21cd09c32dc7c6.md @@ -7,31 +7,31 @@ dashedName: step-17 # --description-- -In your `sortInputArray()` function, declare a `sortedValues` variable. Assign it the value of calling `bubbleSort` with your `inputValues` array. +Na função `sortInputArray()`, declare uma variável `sortedValues`. Atribua a ela o valor da chamada de `bubbleSort` com o array `inputValues`. -Then, update your `updateUI` call to take `sortedValues` as the parameter. +Então, atualize a sua chamada de `updateUI` para que receba `sortedValues` como parâmetro. # --hints-- -You should use `const` to declare a `sortedValues` variable. +Você deve usar `const` para declarar uma variável `sortedValues`. ```js assert.match(code, /const\s+sortedValues\s*=/); ``` -`sortedValues` should be assigned the value of calling `bubbleSort` with your `inputValues` array. +`sortedValues` deve receber por atribuição o valor da chamada de `bubbleSort` com o array `inputValues`. ```js assert.match(code, /const\s+sortedValues\s*=\s*bubbleSort\s*\(\s*inputValues\s*\)/); ``` -`updateUI` should be called with `sortedValues` as the parameter. +`updateUI` deve ser chamada com `sortedValues` como parâmetro. ```js assert.match(code, /updateUI\s*\(\s*sortedValues\s*\)/); ``` -`updateUI` should not be called with `inputValues` as the parameter. +`updateUI` não deve ser chamada com `inputValues` como parâmetro. ```js assert.notMatch(code, /updateUI\s*\(\s*inputValues\s*\)/); diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6410f149110ec60fd40fcfe1.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6410f149110ec60fd40fcfe1.md index cce36a84186..1d105146ee7 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6410f149110ec60fd40fcfe1.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6410f149110ec60fd40fcfe1.md @@ -7,7 +7,7 @@ dashedName: step-22 # --description-- -Time to implement another sorting algorithm. This time, you'll be implementing a selection sort. Selection sort works by finding the smallest value in the array, then swapping it with the first value in the array. Then, it finds the next smallest value in the array, and swaps it with the second value in the array. It continues iterating through the array until it is completely sorted. +É a hora de implementar outro algoritmo de ordenação. This time, you'll be implementing a selection sort. Selection sort works by finding the smallest value in the array, then swapping it with the first value in the array. Then, it finds the next smallest value in the array, and swaps it with the second value in the array. It continues iterating through the array until it is completely sorted. Start by declaring a `selectionSort` variable and assigning it an arrow function that takes an `array` parameter. diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64110727cefd3d1d9bdb0128.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64110727cefd3d1d9bdb0128.md index 797f2aec43e..f06bb2ff1dc 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64110727cefd3d1d9bdb0128.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64110727cefd3d1d9bdb0128.md @@ -7,11 +7,11 @@ dashedName: step-28 # --description-- -Finally, after your outer loop has finished, you need to return the array. Once you've done so, you should be able to see the `Output` change when you click the `Sort` button again. +Por fim, após o término do laço externo, você precisa retornar o array. Depois de fazer isso, você deve poder ver a mudança de `Output` ao clicar no botão `Sort` novamente. # --hints-- -You should `return` the `array` after your outer loop completes. +Você deve utilizar o `return` do `array` depois que o laço externo for concluído. ```js assert.match(code, /const\s+selectionSort\s*=\s*\(\s*array\s*\)\s*=>\s*{\s*for\s*\(\s*let\s+i\s*=\s*0\s*;\s*i\s*<\s*array\.length\s*;\s*i\s*\+\+\s*\)\s*{\s*let\s*minIndex\s*=\s*i\s*;?\s*for\s*\(\s*let\s+j\s*=\s*i\s*\+\s*1\s*;\s*j\s*<\s*array\.length\s*;\s*j\s*\+\+\s*\)\s*{\s*console\.log\(\s*array\s*,\s*array\s*\[\s*j\s*\]\s*,\s*array\s*\[\s*minIndex\s*\]\s*\);\s*if\s*\(\s*array\s*\[\s*j\s*\]\s*<\s*array\s*\[\s*minIndex\s*\]\s*\)\s*{\s*minIndex\s*=\s*j\s*;?\s*}\s*}\s*const\s*temp\s*=\s*array\[i\]\s*;?\s*array\[i\]\s*=\s*array\[minIndex\]\s*;?\s*array\[minIndex\]\s*=\s*temp\s*;?\s*}\s*return\s*array;?\s*/) diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6411135e9ee2fa26c882eb02.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6411135e9ee2fa26c882eb02.md index c550fbfb4e2..a7209eb5b1f 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6411135e9ee2fa26c882eb02.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/6411135e9ee2fa26c882eb02.md @@ -7,13 +7,13 @@ dashedName: step-35 # --description-- -On each iteration of your `while` loop, it is finding an element that is larger than your current value. You need to move that element to the right to make room for your current value. +Em cada iteração do seu laço `while`, ele encontra um elemento que é maior que o seu valor atual. Você precisa mover esse elemento para a direita para abrir espaço para o seu valor atual. -Do so by assigning the value at the `j` index to the next index. +Faça isso atribuindo o valor do índice `j` para o próximo índice. # --hints-- -Before decrementing `j`, assign the value at `j` to the index `j + 1`. +Antes de decrementar `j`, atribua o valor de `j` ao índice `j + 1`. ```js assert.match(code, /const\s+insertionSort\s*=\s*\(\s*array\s*\)\s*=>\s*{\s*for\s*\(\s*let\s+i\s*=\s*1\s*;\s*i\s*<\s*array\.length\s*;\s*i\s*\+\+\s*\)\s*{\s*const\s*currValue\s*=\s*array\s*\[\s*i\s*\]\s*;?\s*let\s*j\s*=\s*i\s*-\s*1\s*;?\s*while\s*\(\s*j\s*>=\s*0\s*&&\s*array\s*\[\s*j\s*\]\s*>\s*currValue\s*\)\s*{\s*array\s*\[\s*j\s*\+\s*1\s*\]\s*=\s*array\s*\[\s*j\s*\];?\s*j--;?\s*\}/); diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64112c9cf53d632910ea2f9b.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64112c9cf53d632910ea2f9b.md index 65dc3e19352..821af2fbdf1 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64112c9cf53d632910ea2f9b.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64112c9cf53d632910ea2f9b.md @@ -7,13 +7,13 @@ dashedName: step-36 # --description-- -After your while loop, you need to insert your current value. Remember that your loop ends when `j` is either out of the array bounds, or when the value at `j` is less than your current value. +Depois do laço while, você precisa inserir o valor atual. Lembre-se de que seu laço de repetição termina quando `j` estiver fora dos limites do array ou quando o valor em `j` for menor que o valor atual. -Use the assignment operator to insert your current value into the correct index. +Use o operador de atribuição para inserir o valor atual no índice correto. # --hints-- -You should assign `currValue` to the index `j + 1`. +Você deve atribuir `currValue` ao índice `j + 1`. ```js assert.match(code, /const\s+insertionSort\s*=\s*\(\s*array\s*\)\s*=>\s*{\s*for\s*\(\s*let\s+i\s*=\s*1\s*;\s*i\s*<\s*array\.length\s*;\s*i\s*\+\+\s*\)\s*{\s*const\s*currValue\s*=\s*array\s*\[\s*i\s*\]\s*;?\s*let\s*j\s*=\s*i\s*-\s*1\s*;?\s*while\s*\(\s*j\s*>=\s*0\s*&&\s*array\s*\[\s*j\s*\]\s*>\s*currValue\s*\)\s*{\s*array\s*\[\s*j\s*\+\s*1\s*\]\s*=\s*array\s*\[\s*j\s*\];?\s*j--;?\s*\}\s*array\s*\[\s*j\s*\+\s*1\s*\]\s*=\s*currValue;?/); diff --git a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64113124efd2852edafaf25f.md b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64113124efd2852edafaf25f.md index fb637a81062..9d9e6c3cb45 100644 --- a/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64113124efd2852edafaf25f.md +++ b/curriculum/challenges/portuguese/15-javascript-algorithms-and-data-structures-22/learn-basic-algorithmic-thinking-by-building-a-number-sorter/64113124efd2852edafaf25f.md @@ -7,23 +7,23 @@ dashedName: step-41 # --description-- -The callback to `.sort()` should return a number. That number determines how to sort the elements `a` and `b`: +A função de callback de `.sort()` deve retornar um número. Esse número determina como ordenar os elementos `a` e `b`: -- If the number is negative, sort `a` before `b`. -- If the number is positive, sort `b` before `a`. -- If the number is zero, do not change the order of `a` and `b`. +- Se o número for negativo, ordene `a` antes de `b`. +- Se o número for positivo, ordene `b` antes de `a`. +- Se o número for zero, não altere a ordem de `a` e `b`. -Keeping in mind that you want the numbers to be sorted in ascending order (smallest to largest), return a single subtraction calculation using `a` and `b` that will correctly sort the numbers with the above logic. +Tendo em mente que você quer que os números sejam classificados em ordem ascendente (do menor para o maior), retorne um único cálculo de subtração, usando `a` e `b`, que ordenará corretamente os números com a lógica acima. # --hints-- -Your callback function should use an explicit `return`. +A função de callback deve usar um `return` explícito. ```js assert.match(code, /const\s+sortedValues\s*=\s*inputValues\s*\.\s*sort\s*\(\s*\(\s*a\s*,\s*b\s*\)\s*=>\s*{\s*return/); ``` -Your callback function should return `a - b`. +A função de callback deve retornar `a - b`. ```js assert.match(code, /const\s+sortedValues\s*=\s*inputValues\s*\.\s*sort\s*\(\s*\(\s*a\s*,\s*b\s*\)\s*=>\s*{\s*return\s*a\s*-\s*b;?\s*}\s*\)/); diff --git a/curriculum/challenges/portuguese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/portuguese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index 9321eeee210..aef6c9105a4 100644 --- a/curriculum/challenges/portuguese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/portuguese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -description +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Teste 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Teste 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Teste 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` + diff --git a/curriculum/challenges/portuguese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-e.md b/curriculum/challenges/portuguese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-e.md index 9c566f1c0fc..7571451d9e3 100644 --- a/curriculum/challenges/portuguese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-e.md +++ b/curriculum/challenges/portuguese/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-e.md @@ -7,18 +7,18 @@ dashedName: css-foundations-exercise-e # --description-- -Understanding how combinators work can become a lot easier when you start playing around with them and see what exactly is affected by them versus what isn't. +Compreender como os combinadores funcionam pode se tornar muito mais fácil quando você começa a brincar com eles e ver o que exatamente é afetado por eles em comparação com o que não é. -The goal of this exercise is to apply styles to elements that are descendants of another element, while leaving elements that aren't descendants of that element unstyled. +O objetivo deste exercício é aplicar estilos aos elementos que são descendentes de outro elemento, deixando elementos que não são descendentes desse elemento sem estilização. -1. You should see a `yellow` background for `p` elements that are descendants of the `div` element. -1. You should see a text color of `red` for elements that are descendants of the `div` element. -1. You should see a font size of `20px` for elements that are descendants of the `div` element. -1. You should center align text for elements that are descendants of the `div` element. +1. Você deve ver um segundo plano na cor `yellow` para elementos `p` que são descendentes do elemento `div`. +1. Você deve ver uma cor de texto `red` para elementos que são descendentes do elemento `div`. +1. Você deve ver um tamanho de fonte de `20px` para os elementos que são descendentes do elemento `div`. +1. Você deve ver o texto alinhado ao centro para elementos que são descendentes do elemento `div`. # --hints-- -You should have a background color of `yellow` on your descendants. +Você deve ter um segundo plano na cor `yellow` em seus descendentes. ```js const styleOne = new __helpers.CSSHelp(document).getStyle('.container .text'); @@ -40,7 +40,7 @@ assert(getCorrectStyle()?.backgroundColor === 'yellow'); ``` -You should have a text color of `red` on your descendants. +Você deve ter a cor do texto `red` em seus descendentes. ```js const styleOne = new __helpers.CSSHelp(document).getStyle('.container .text'); @@ -62,7 +62,7 @@ assert(getCorrectStyle()?.color === 'red'); ``` -You should have a font size of `20px` on your descendants. +Você deve ter um tamanho de fonte de `20px` em seus descendentes. ```js const styleOne = new __helpers.CSSHelp(document).getStyle('.container .text'); @@ -84,7 +84,7 @@ assert(getCorrectStyle()?.fontSize === '20px'); ``` -You should center align the text on your descendants. +Você deve ter o texto alinhado ao centro em seus descendentes. ```js const styleOne = new __helpers.CSSHelp(document).getStyle('.container .text'); diff --git a/curriculum/challenges/ukrainian/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md b/curriculum/challenges/ukrainian/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md index f88830f1d6c..adabe014b8e 100644 --- a/curriculum/challenges/ukrainian/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md +++ b/curriculum/challenges/ukrainian/03-front-end-development-libraries/jquery/remove-an-element-using-jquery.md @@ -10,7 +10,7 @@ dashedName: remove-an-element-using-jquery Видалимо елемент у форматі HTML із вашої сторінки за допомогою jQuery. -jQuery має функцію під назвою `.remove()`, яка повністю видалить HTML-елемент +jQuery has a function called `.remove()` that will remove an HTML element entirely. Видаліть зі сторінки елемент `#target4` за допомогою функції `.remove()`. diff --git a/curriculum/challenges/ukrainian/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md b/curriculum/challenges/ukrainian/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md index de724905411..c820111c942 100644 --- a/curriculum/challenges/ukrainian/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md +++ b/curriculum/challenges/ukrainian/16-the-odin-project/top-learn-css-foundations-projects/css-foundations-exercise-d.md @@ -7,36 +7,124 @@ dashedName: css-foundations-exercise-d # --description-- -опис +With this exercise, we've provided you a completed HTML file, so you will only have to edit the CSS file. For this exercise, it's more important to understand how chaining different selectors works than how to actually add the attributes. + +1. You should see a `width` of `300px` on the `avatar` and `proportioned` class. +1. You should give it a height so that it retains its original square proportions (don't hardcode in a pixel value for the height!). +1. You should give the elements with both the `avatar` and `distorted` classes a `width` of `200px`. +1. You should give it a `height` twice as big as it's width. # --hints-- -Тест 1 +You should have a `width` of `300px` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style?.width === '300px'); ``` -Тест 2 +You should have a height of `auto` on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`) +assert(style?.height === 'auto'); ``` -Тест 3 +You should use a chaining selector on the `avatar` and `proportioned` class. ```js - +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.proportioned`) || new __helpers.CSSHelp(document).getStyle(`.proportioned.avatar`); +assert(style); ``` +You should have a `width` of `200px` on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.width === '200px'); +``` + +You should use a chaining selector on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style); +``` + +You should have a `height` two times the width on the `avatar` and `distorted` class. + +```js +const style = new __helpers.CSSHelp(document).getStyle(`.avatar.distorted`) || new __helpers.CSSHelp(document).getStyle(`.distorted.avatar`); +assert(style?.height === '400px'); +``` # --seed-- ## --seed-contents-- +```css + +``` + ```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css ``` # --solutions-- -`html` + +```html + + + + Chaining Selectors + + + + +
+ Woman with glasses + Man with surprised expression +
+ +
+ Woman with glasses + +
+ + +``` + +```css +.avatar.proportioned { + height: auto; + width: 300px; +} + +.avatar.distorted { + height: 400px; + width: 200px; +} +``` +