Apply a Style Until a Condition is Met with @while.....hughhhh

Apply a Style Until a Condition is Met with @while.....hughhhh
0

#1

What should be done so that it may work…HELP!

code


#2

font-size requires units.


#3

Still not working…
even I adjust the chrome’s font size …how can i get the green check mark???


#4

What is your current solution?


#5
<style type='text/sass'>
  
 $x:1;
 @while $x < 11 {
  .text-#{$x} { font-size: 5px * $x; }
  $x: $x + 1;
  }
  
</style>

#6
 $x:1;

Put a space between the : and the 1.


#7

I think you have missed out “px” after 5.
As I always wished that my code was right but I could not pass the test either.


  $x: 1;
  @while $x < 11 {
    .text-#{$x} { font-size: $x * 5px;}
    $x: $x + 1;
  }   
</style>

#8

nothing works…


#9

still not working…


#10

You can just skip the challenge if you want.


#11

then how could i get over it…


#12

The code above, with the change I mentioned, will pass the tests on the latest version of Chrome if an extension or setting isn’t interfering with the tests. If the tests aren’t passing then you have some other difference like the spacing that doesn’t impact functionality but will cause the tests to fail. If the tests aren’t running at all, then it is an issue with your browser or settings. You are free to just go to the curriculum page and skip to the next challenge or just skip the entire SASS section. It’s up to you.


#13

hmmm Thanks…


#14

I have passed the test by adding inline style on top of the current code.


#15

but i think it is not gonna work for me…just fed up


#16

What browser are you using? If you are using Chrome, try switch to firefox and use the same code
your code seems fine! Good Luck!


#17

Then just skip it.


#18

Thanks All…it worked on firefox…