Merge pull request #103 from umbraco/temp-annoying-gif

Updates annoying gif to not being shown on mobiles
This commit is contained in:
hartvig
2017-05-01 15:05:04 +02:00
committed by GitHub
+6 -1
View File
@@ -349,7 +349,12 @@ box-shadow: 4px 4px 10px 7px rgba(219,219,219,0.28)
// test for cookie
$(document).ready(function () {
if (document.cookie.indexOf("contribSurveyTaken") == -1) {
document.getElementById("unicornSurvery").style.display = 'block';
// don't show on mobile devices
var ua = navigator.userAgent;
if (!/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini|Mobile|mobile|CriOS/i.test(ua)) {
document.getElementById("unicornSurvery").style.display = 'block';
}
}
});
</script>