Skip to content

Commit

Permalink
v0.13.0
Browse files Browse the repository at this point in the history
  • Loading branch information
robinparisi committed Jan 22, 2018
1 parent 0b77b8d commit 8794a05
Show file tree
Hide file tree
Showing 11 changed files with 65 additions and 17 deletions.
27 changes: 24 additions & 3 deletions dist/tingle.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* ----------------------------------------------------------- */
/* == tingle v0.12.0 */
/* == tingle v0.13.0 */
/* ----------------------------------------------------------- */

.tingle-modal * {
Expand All @@ -25,6 +25,7 @@
-ms-flex-align: center;
align-items: center;
overflow: hidden;
-webkit-overflow-scrolling: touch;
background: rgba(0, 0, 0, .8);
opacity: 0;
cursor: pointer;
Expand Down Expand Up @@ -132,6 +133,7 @@
-------------------------------------------------------------- */

.tingle-enabled {
position: fixed;
overflow: hidden;
height: 100%;
}
Expand All @@ -141,8 +143,8 @@
}

.tingle-enabled .tingle-content-wrapper {
-webkit-filter: blur(15px);
filter: blur(15px);
-webkit-filter: blur(12px);
filter: blur(12px);
}

.tingle-modal--visible {
Expand Down Expand Up @@ -265,3 +267,22 @@
font-size: 4rem;
}
}

@supports ((-webkit-backdrop-filter: blur(12px)) or (backdrop-filter: blur(12px))) {
.tingle-modal {
-webkit-backdrop-filter: blur(20px);
backdrop-filter: blur(20px);
}

@media (max-width : 540px) {
.tingle-modal {
-webkit-backdrop-filter: blur(8px);
backdrop-filter: blur(8px);
}
}

.tingle-enabled .tingle-content-wrapper {
-webkit-filter: none;
filter: none;
}
}
5 changes: 4 additions & 1 deletion dist/tingle.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*!
* tingle.js
* @author robin_parisi
* @version 0.12.0
* @version 0.13.0
* @url
*/
(function(root, factory) {
Expand Down Expand Up @@ -88,7 +88,9 @@
}

// prevent double scroll
this._scrollPosition = window.pageYOffset;
document.body.classList.add('tingle-enabled');
document.body.style.top = -this._scrollPosition + 'px';

// sticky footer
this.setStickyFooter(this.opts.stickyFooter);
Expand Down Expand Up @@ -129,6 +131,7 @@
}

document.body.classList.remove('tingle-enabled');
window.scrollTo(0, this._scrollPosition);

this.modal.classList.remove('tingle-modal--visible');

Expand Down
2 changes: 1 addition & 1 deletion dist/tingle.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 8794a05

Please sign in to comment.