1. 28 Oct, 2021 2 commits
  2. 27 Oct, 2021 7 commits
    • Robert Knight's avatar
      Improve field name · 4102e483
      Robert Knight authored
      This is a count of the number of reconnections, not including the
      initial connection attempt.
      4102e483
    • Robert Knight's avatar
      Move WebSocket automatic reconnection to streamer service · d9a017a2
      Robert Knight authored
      Move the logic for automatically reconnecting to the WebSocket after an
      unexpected disconnection from the `Socket` WebSocket wrapper class to
      the `StreamerService` service. The Socket class is now responsible only
      for notifying the caller of unexpected disconnections.
      
      Letting StreamerService handle reconnection ensures that a fresh
      WebSocket URL, with a current access token, is used on each attempt. The
      previous approach would re-use the same URL on each attempt. This could
      lead to an obsolete access token being used, with the result that the
      WebSocket connection degraded to an unauthenticated one and not all
      expected updates were received.
      
      As part of this change, the logic for calculating the retry delay has been
      simplified and no longer uses the `retry` package, hopefully making the
      behavior easier to understand.
      d9a017a2
    • Robert Knight's avatar
      Remove obsolete JSX runtime aliases · 44310d04
      Robert Knight authored
      This is no longer needed with the current version of
      @hypothesis/frontend-shared.
      44310d04
    • Robert Knight's avatar
      Remove unused SASS bundling script · 037f2eb5
      Robert Knight authored
      This has been replaced by `buildCSS` from @hypothesis/frontend-build.
      037f2eb5
    • Robert Knight's avatar
      Update @hypothesis/frontend-shared to v4.0.0 · 8e2d612c
      Robert Knight authored
      This required a couple of changes to adapt to the removal of the
      CommonJS build. Some modules from the pattern library web app triggered
      a Babel warning about top-level `this`. I copied across the workaround
      from `rollup.config.js` in the @hypothesis/frontend-shared library.
      8e2d612c
    • Lyza Danger Gardner's avatar
      578a1cd8
    • Robert Knight's avatar
      Fix KaTeX font loading · e3384922
      Robert Knight authored
      When rendering math, the custom KaTex fonts failed to load due to the
      relative URL references in `build/styles/katex.min.css` not matching the
      actual location of the fonts in `build/fonts`. The KaTeX CSS assumes a
      URL structure like:
      
      ```
      katex.min.css
      fonts/
        KaTeX_AMS-Regular.woff2
      ```
      
      Previously font URLs in katex.min.css were rewritten from
      `url('fonts/foo.woff2')` to `url('../fonts/foo.woff2')` by a PostCSS
      plugin when building the CSS bundles. However this got lost when
      replacing the client's local style-bundling script with the one from the
      @hypothesis/frontend-shared package.
      
      By relocating the fonts to a subdirectory of `build/styles` we can make
      the asset references work without needing to do any rewriting of URLs in
      the KaTeX CSS bundle.
      
      In the process, the list of fonts included in the bundle was simplified
      to include just WOFF2 fonts, since all modern browsers support that
      format. Additionally an obsolete reference to fonts in src/styles/vendor
      was removed.
      e3384922
  3. 26 Oct, 2021 3 commits
  4. 25 Oct, 2021 10 commits
  5. 22 Oct, 2021 2 commits
  6. 20 Oct, 2021 1 commit
  7. 19 Oct, 2021 15 commits