You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
98 lines
2.0 KiB
SCSS
98 lines
2.0 KiB
SCSS
@import "_colors.scss";
|
|
// Here we are using a library cloned from github and importing it.
|
|
@import "angled-edges/_angled-edges.scss";
|
|
|
|
$breakpoint: 800px;
|
|
|
|
$style1: (foreground: $color-light, background: $color-secondary);
|
|
$style2: (foreground: $color-primary, background: $color-highlight1);
|
|
$style3: (foreground: $color-primary, background: $color-highlight2);
|
|
|
|
@mixin transform($value) {
|
|
-webkit-transform: $value;
|
|
-moz-transform: $value;
|
|
-ms-transform: $value;
|
|
transform: $value;
|
|
}
|
|
|
|
@mixin content-style($foreground, $background){
|
|
color: $foreground;
|
|
background-color: $background;
|
|
}
|
|
|
|
// Sass supports inheritance. This is how we can create a common class for extention
|
|
%link-shared {
|
|
font-size: 16px;
|
|
margin-left: 10px;
|
|
margin-right: 10px;
|
|
padding: 10px;
|
|
border-radius: 10px;
|
|
}
|
|
|
|
|
|
body {
|
|
font-family: sans-serif;
|
|
text-align: center;
|
|
background: linear-gradient(155deg, $color-primary 70%, $color-secondary 70%);
|
|
color: $color-light;
|
|
min-height: 100vh;
|
|
}
|
|
|
|
h1 {
|
|
color: $color-highlight1;
|
|
}
|
|
|
|
h2 {
|
|
color: $color-highlight2;
|
|
}
|
|
|
|
a {
|
|
@extend %link-shared;
|
|
@include content-style($style3...);
|
|
}
|
|
|
|
.profile-header {
|
|
a {
|
|
//Example of inheritance
|
|
@extend %link-shared;
|
|
@include content-style($style1...); //Don't forget a spread operator.
|
|
}
|
|
}
|
|
|
|
.profile-body {
|
|
display: flex;
|
|
align-items: stretch;
|
|
justify-content: space-around;
|
|
margin-top: 32px;
|
|
margin-left: 10vw;
|
|
margin-right: 10vw;
|
|
@media screen and (max-width: $breakpoint){
|
|
flex-direction: column;
|
|
}
|
|
}
|
|
|
|
.profile-section {
|
|
@include angled-edge("outside bottom", "lower right", $color-highlight1);
|
|
@include angled-edge("outside top", "upper right", $color-highlight1);
|
|
@include content-style($style2...);
|
|
// margin: 16px;
|
|
margin: 120px 16px 120px 16px;
|
|
//border-radius: 10px;
|
|
width: 340px;
|
|
.profile-content{
|
|
padding: 20px;
|
|
}
|
|
@media screen and (max-width: $breakpoint){
|
|
width: 100%;
|
|
}
|
|
|
|
}
|
|
|
|
.profile-logo {
|
|
font-size: 60px;
|
|
font-family: cursive;
|
|
@include transform(rotate(25deg));
|
|
}
|
|
|
|
//More Complex mixin
|