<!doctype>
<html>
  <head>
    <title>Test</title>
    <script type="text/javascript">
      // Polyfill matches & closest for IE11
      // https://developer.mozilla.org/en-US/docs/Web/API/Element/closest#Polyfill
      if (!Element.prototype.matches) {
        Element.prototype.matches = Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector
      }

      if (!Element.prototype.closest) {
        Element.prototype.closest = function(s) {
          var el = this
          var ances