responsive design - Can addEventListener fire event for mobile display? -
not js @ all. using jquery timecircles (http://plugins.jquery.com/timecircles/). , trying 'rebuild' (http://git.wimbarelds.nl/timecircles/readme.php) circles when view / window goes portrait landscape.
the div has circles is:
<div id="datecountdown" data-date="2015-10-08 00:00:00" ></div> my goal mentioned above, have circles rebuild when view changes landscape portrait or vice versa.
i have right before closing body tag:
<script> // find matches var mql = window.matchmedia("(orientation: portrait)"); // if there matches, we're in portrait if(mql.matches) { // portrait orientation } else { // landscape orientation } // add media query change listener mql.addlistener(function(m) { if(m.matches) { $(".datecountdown").timecircles().rebuild(); } else { } }); </script>
Comments
Post a Comment