1. 20 Oct, 2020 11 commits
  2. 16 Oct, 2020 9 commits
  3. 15 Oct, 2020 1 commit
    • Robert Knight's avatar
      Remove checks for IE 11 in `TagEditor` component · da788daf
      Robert Knight authored
      `TagEditor` tested if the browser was IE 11 to determine whether to
      check the `inputType` property of `InputEvent`. However it is not only
      IE 11 that did not support this property.
      
      From reading the comments in https://github.com/hypothesis/client/pull/1558 it
      appears that the `inputType` checks was originally added to resolve an
      issue with accepting suggestions by pressing Enter in an earlier version
      of `TagEditor` that used the `<datalist>` element. As far as I can tell
      this is no longer applicable. `<datalist>` was replaced by a custom UI
      and accepting suggestions by pressing Enter works without this logic.
      Therefore this commit removes it entirely.
      da788daf
  4. 14 Oct, 2020 8 commits
    • Robert Knight's avatar
      Fix `Promise.prototype.finally` polyfill loading in older browsers · 77478163
      Robert Knight authored
      The sidebar application failed to load in Safari 10 due to the ES 2018
      polyfill bundle, which contains a polyfill for
      `Promise.prototype.finally`, not being loaded in that browser.
      
      The issue was that 'es2018' was not listed in the polyfill bundles to
      build in `gulpfile.js` or in the list of bundles required by the sidebar
      app in `boot.js`.
      
      This commit fixes these issues and makes the issue less likely to occur
      in future by:
      
       - Removing the need to manually list each polyfill bundle in
         `gulpfile.js`. Instead the `src/shared/polyfills` dir is listed and
         every non-`index.js` file is used as the root of a bundle.
       - Factoring out the polyfills common to the sidebar and annotator app
         into a variable and including "es2018" there
      77478163
    • Robert Knight's avatar
      Remove `Element.closest` polyfill · 0fd302bd
      Robert Knight authored
      Element.closest is natively supported [1] by our minimum browser targets.
      
      [1] https://developer.mozilla.org/en-US/docs/Web/API/Element/closest#Browser_compatibility
      0fd302bd
    • Robert Knight's avatar
      Fix `document.evaluate` feature test in Edge Legacy · 2e6b8a6e
      Robert Knight authored
      This API is available in Edge Legacy but with a quirk that arguments
      that are optional in the spec are required in this browser.
      
      This fixes an issue that the client would incorrectly abort startup in
      Edge Legacy with a warning that the browser is unsupported.
      2e6b8a6e
    • Robert Knight's avatar
      Remove `createNodeIterator` polyfill · 7545b9a2
      Robert Knight authored
      This polyfilled the optional-ness of the `filter` and deprecated
      `expandEntityRefrences` arguments of `document.createNodeIterator` in IE
      11, which is no longer supported.
      7545b9a2
    • Robert Knight's avatar
      Remove `document.baseURI` polyfill · 93d916b8
      Robert Knight authored
      This was only needed for IE 11, which is no longer supported.
      93d916b8
    • Robert Knight's avatar
      Remove `custom-event` polyfill · c837812e
      Robert Knight authored
      This was only needed for IE 11, which is no longer supported.
      c837812e
    • Robert Knight's avatar
      Remove `document.evaluate` polyfill · 9588558a
      Robert Knight authored
      This was only needed for IE 11, which is no longer supported.
      9588558a
    • Robert Knight's avatar
      Gracefully abort startup in old browsers · e1f314b3
      Robert Knight authored
      Run a series of feature tests at the very start of the boot process and
      abort with a console warning if they fail.
      
      We display a console warning rather than a louder warning to avoid being
      disruptive on sites maintained by publishers which embed Hypothesis and
      which still want to support older browsers. On those sites the
      Hypothesis annotation feature will simply be missing.
      e1f314b3
  5. 13 Oct, 2020 9 commits
  6. 12 Oct, 2020 2 commits
    • Eduardo Sanz García's avatar
      refactor adder.js · e4049374
      Eduardo Sanz García authored
      Code reorganisation:
      
      * Adder has a simplified API: added a public method display that internally calls private methods _target and _showAt
      * Performance improvement in _target method by removing multiple calls to this._width() and this._height()
      * More strict type for arrowDirection
      e4049374
    • Eduardo Sanz García's avatar
      find suitable zIndex for the adder · 701203c5
      Eduardo Sanz García authored
      resolves #2009
      701203c5