Results: 1580
Notes
  • Newest first
  • Oldest first
  • Newest first(All)
  • Oldest first(All)
@mixin triangle($size, $color, $direction) {
  height: 0;
  width: 0;

  border-color: transparent;
  border-style: solid;
  border-width: $size / 2;

  @if $direction == up {
    border-bottom-color: $color;
  } @else if $direction == right {
    border-left-color: $color;
  } @else if $direction == down {
    border-top-color: $color;
  } @else if $direction == left {
    border-right-color: $color;
  } @else {
    @error "Unknown direction #{$direction}.";
  }
}

.next {
  @include triangle(5px, black, right);
}
by Valeri Tandilashvili
4 years ago
0
Sass
conditionals
SASS documentation
0
sass --watch example.scss output.css
SASS will watch example.scss file changes and will compile it immediately after every change
by Valeri Tandilashvili
4 years ago
0
Sass
Sass Crash Course
0
changes in .css files
We don't want to ever touch our .css files when we are dealing with SASS because .css files are going to keep getting recompiled
by Valeri Tandilashvili
4 years ago
0
Sass
0
Extensions (left navigation)  
->  search & install 
->  Manage (left bottom)  
->  Settings  
->  search (live sass...)  
->  Edit in settings.json
Possible values for
format
part of settings:
expanded / compressed
Default location is
null
(root) but we can put
"css/"
When format is
compressed
we can put
.min.css
as
extensionName
by Valeri Tandilashvili
4 years ago
0
Sass
extensions
Sass Crash Course
0
by Valeri Tandilashvili
4 years ago
0
Sass
nested CSS
Sass Crash Course
0
In _config.scss partial file we have:
$primary-color: blue;
$secondary-color: lightblue;
And then we can import the partial into style.scss:
@import 'config';
by Valeri Tandilashvili
4 years ago
0
Sass
partials
Sass Crash Course
0
Setting text color using the container's background-color:
@function set-text-color($color) {
    @if (lightness($color) > 70) {
        @return #333;
    } @else {
        @return #fff;
    }
}
Calling the function - "set-text-color":
h1 {
    background-color: $primary-color;
    color: set-text-color($primary-color);
}
by Valeri Tandilashvili
4 years ago
0
Sass
functions
Sass Crash Course
0
Setting text color using the container's background-color:
// set text color based on bg
@function set-text-color($color) {
    @if (lightness($color) > 70) {
        @return #333;
    } @else {
        @return #fff;
    }
}

// set bg color & text color
@mixin set-background($color) {
    background-color: $color;
    color: set-text-color($color);
}
Use the mixin - "set-background"
h1 {
    @include set-background($primary-color);
}
Changing bg-color effect on text-color: https://youtu.be/nu5mdN2JIwM?t=2333
by Valeri Tandilashvili
4 years ago
0
Sass
functions
Sass Crash Course
0
by Luka Tatarishvili
4 years ago
0
Git
Info
0
Project = Repository
(Woring directory)
Staging = Control what gets committed
Commit = Git's way of save
by Luka Tatarishvili
4 years ago
0
Git
Info
0
Results: 1580