O
O
olya_0972019-01-26 17:49:29
Sass
olya_097, 2019-01-26 17:49:29

This sass code does not compile, what needs to be fixed?

https://jsfiddle.net/dvt71hn0/1/ This sass code does
not compile No errors

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
iDomanOff, 2019-01-26
@iDomanOff

You need to add spaces after the colon...

$text-color: #333333
$dark-color: #000000
$red-color: #9b1818
$blur-color: #003469
$green-color: #67bc5c

body
  font-family: "RobotoRegular", sans-serif
  color: $text-color
  font-weight: normal
  font-size: 16px
  min-width: 320px
  position: relative
  line-height: 1.6
  -webkit-font-smoothing: antialised
  
h1
  color:#fff
  font-size: 60px
  line-height: 56px
  font-weight: bold
  font-family: "Cleanvertising", sans-serif
  
section
  padding: 58px 0 68px
  &.s_dark
    h2, h3, p
      color:#fff
  h2
    color: $blur-color
    font-size: 50px
    line-height: 56px
    margin-bottom: 50px
    
body input:focus:required:invalid,
body textarea:focus:required:invalid
  color: red
body input:required:valid,
body textarea:required:valid
  color: green

.hidden
  display: none


header
  min-height: 640px
  background-image: url(../img/top__bg.jpg)
  background-position: top center
  background-size: cover

and everything compiles
body {
  font-family: "RobotoRegular", sans-serif;
  color: #333333;
  font-weight: normal;
  font-size: 16px;
  min-width: 320px;
  position: relative;
  line-height: 1.6;
  -webkit-font-smoothing: antialised;
}

h1 {
  color: #fff;
  font-size: 60px;
  line-height: 56px;
  font-weight: bold;
  font-family: "Cleanvertising", sans-serif;
}

section {
  padding: 58px 0 68px;
}

section.s_dark h2, section.s_dark h3, section.s_dark p {
  color: #fff;
}

section h2 {
  color: #003469;
  font-size: 50px;
  line-height: 56px;
  margin-bottom: 50px;
}

body input:focus:required:invalid,
body textarea:focus:required:invalid {
  color: red;
}

body input:required:valid,
body textarea:required:valid {
  color: green;
}

.hidden {
  display: none;
}

header {
  min-height: 640px;
  background-image: url(../img/top__bg.jpg);
  background-position: top center;
  -webkit-background-size: cover;
          background-size: cover;
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question