From 8cca63945016623d2b1f34fee49635f691bdfa3a Mon Sep 17 00:00:00 2001
From: lasjorg <28780271+lasjorg@users.noreply.github.com>
Date: Mon, 16 Dec 2019 16:18:30 +0100
Subject: [PATCH] fix(challenge): check inline styles on elements, add solution
(#37756)
---
...eight-of-an-element-dynamically.english.md | 41 ++++++++++++++-----
1 file changed, 30 insertions(+), 11 deletions(-)
diff --git a/curriculum/challenges/english/04-data-visualization/data-visualization-with-d3/update-the-height-of-an-element-dynamically.english.md b/curriculum/challenges/english/04-data-visualization/data-visualization-with-d3/update-the-height-of-an-element-dynamically.english.md
index da7eafee23..1f31b73245 100644
--- a/curriculum/challenges/english/04-data-visualization/data-visualization-with-d3/update-the-height-of-an-element-dynamically.english.md
+++ b/curriculum/challenges/english/04-data-visualization/data-visualization-with-d3/update-the-height-of-an-element-dynamically.english.md
@@ -25,23 +25,23 @@ Add the style()
method to the code in the editor to set the h
```yml
tests:
- text: The first div
should have a height
of 12 pixels.
- testString: assert($('div').eq(0).css('height') == '12px');
+ testString: assert($('div').eq(0)[0].style.height === '12px');
- text: The second div
should have a height
of 31 pixels.
- testString: assert($('div').eq(1).css('height') == '31px');
+ testString: assert($('div').eq(1)[0].style.height === '31px');
- text: The third div
should have a height
of 22 pixels.
- testString: assert($('div').eq(2).css('height') == '22px');
+ testString: assert($('div').eq(2)[0].style.height === '22px');
- text: The fourth div
should have a height
of 17 pixels.
- testString: assert($('div').eq(3).css('height') == '17px');
+ testString: assert($('div').eq(3)[0].style.height === '17px');
- text: The fifth div
should have a height
of 25 pixels.
- testString: assert($('div').eq(4).css('height') == '25px');
+ testString: assert($('div').eq(4)[0].style.height === '25px');
- text: The sixth div
should have a height
of 18 pixels.
- testString: assert($('div').eq(5).css('height') == '18px');
+ testString: assert($('div').eq(5)[0].style.height === '18px');
- text: The seventh div
should have a height
of 29 pixels.
- testString: assert($('div').eq(6).css('height') == '29px');
+ testString: assert($('div').eq(6)[0].style.height === '29px');
- text: The eighth div
should have a height
of 14 pixels.
- testString: assert($('div').eq(7).css('height') == '14px');
+ testString: assert($('div').eq(7)[0].style.height === '14px');
- text: The ninth div
should have a height
of 9 pixels.
- testString: assert($('div').eq(8).css('height') == '9px');
+ testString: assert($('div').eq(8)[0].style.height === '9px');
```
@@ -88,8 +88,27 @@ tests:
## Solution
-```js
-// solution required
+```html
+
+
+
+
```