Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added stinson filter #251

Merged
merged 3 commits into from
Nov 11, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion site/filters.json
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@
},
{
"name": "Stinson",
"is_done": false,
"is_done": true,
"usage": "stinson"
},
{
Expand Down
41 changes: 41 additions & 0 deletions source/css/stinson.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
/*
*
* Stinson
*
*/

.stinson {
position: relative;
-webkit-filter: contrast(0.75) saturate(0.85) brightness(1.15);
filter: contrast(0.75) saturate(0.85) brightness(1.15); }

.stinson img {
width: 100%;
z-index: 1; }

.stinson:before {
content: '';
display: block;
height: 100%;
width: 100%;
top: 0;
left: 0;
position: absolute;
pointer-events: none;
z-index: 2; }

.stinson:after {
content: '';
display: block;
height: 100%;
width: 100%;
top: 0;
left: 0;
position: absolute;
pointer-events: none;
z-index: 3; }

&::before {
background: rgba(240, 149, 128, .2);
mix-blend-mode: soft-light;
}
3 changes: 2 additions & 1 deletion source/scss/cssgram.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@
@import 'brannan';
@import 'valencia';
@import 'kelvin';
@import 'maven';
@import 'maven';
@import 'stinson';
42 changes: 42 additions & 0 deletions source/scss/stinson.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
/*
*
* Stinson
*
*/

@import 'shared';

// mixin to extend stinson filter
// @mixin stinson
// @param $filters... {filter} - Zero to many css filters to be added
// @example
// img {
// @include stinson;
// }
// or
// img {
// @include stinson(blur(2px));
// }
// or
// img {
// @include stinson(blur(2px)) {
// /*...*/
// };
// }
@mixin stinson($filters...) {
@include filter-base;
filter: contrast(0.75) saturate(0.85) brightness(1.15) $filters;

&::before {
background: rgba(240, 149, 128, .2);
mix-blend-mode: soft-light;
}

@content;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would also add a pseudo element with a light orange light to bring up the warmth in the shadows. This is what I tried and it looked pretty close:

&::before {
  background: rgba(240, 149, 128, .2);
  mix-blend-mode: soft-light;
}

Before changes:

screen shot 2016-11-02 at 10 13 59 am

After:

screen shot 2016-11-02 at 10 13 49 am

}

// stinson Instagram filter
%stinson,
.stinson {
@include stinson;
}