1. 25 Jan, 2021 8 commits
  2. 22 Jan, 2021 5 commits
    • Lyza Danger Gardner's avatar
      4a1d243a
    • Lyza Danger Gardner's avatar
      Extract things into top-level directory · fcf156df
      Lyza Danger Gardner authored
      Move a few modules from `util` to (for now) the top-level
      directory. These modules have multiple dependencies, or are
      otherwise application-specific, but don't fit comfortably in
      the `helpers` modules.
      fcf156df
    • Lyza Danger Gardner's avatar
      Remove unused utilities · 497659cc
      Lyza Danger Gardner authored
      497659cc
    • Lyza Danger Gardner's avatar
      Extract helpers from util · ebf18e52
      Lyza Danger Gardner authored
      Extract modules from the `util` directory that are specific to
      the application domain or have application dependencies
      ebf18e52
    • Eduardo Sanz García's avatar
      Use shadow DOM to encapsulate sidebar's style · 02c32fab
      Eduardo Sanz García authored
      A side effect of using shadow DOM for the sidebar is that the BucketBar
      'plugin' could not be injected easily using a current query mechanism.
      After consulting with @robertknight, we decided to avoid using the
      normal plugin injection mechanism and instead instantiate the BucketBar
      from the sidebar.
      
      This PR also includes:
      
      - a no documented configuration option to disable the shadow DOM
        encapsulation. This can be removed in the future if not needed.
      - more strict types
      - simplification of the logic in the sidebar
      
      I have tested these changes in the following browsers:
      
      Brower\OS    | MacOS              | Windows
      ------------ | ------------------ | -----------------
      Chrome 57    |  | 
      Chrome beta  |  | 
      Edge 17      |                    | 
      Edge beta    |  | 
      Firefox 53   |  | 
      Firefox beta |  | 
      Safari 10    |  |
      Safari 14    |  |
      02c32fab
  3. 21 Jan, 2021 5 commits
  4. 20 Jan, 2021 2 commits
    • Kyle Keating's avatar
      Improve Adder location for touch screen devices · cd6a1288
      Kyle Keating authored
      - Ensure that the adder location is always below the highlighted selection on a touch devices so that it does not compete with the copy/paste bar.
      - Add a little extra margin (10px) to the adder on touch devices to give room for the selection handles
      - Add helper method `isTouchDevice` for touch devices
      - Add comment in isSelectionBackwards to explain that iOS does not have the same selection object as non-iOS devices
      - Add 1 missing test coverage case in adder.js
      cd6a1288
    • Robert Knight's avatar
      Fix incorrect use of `hasClass` in `Button` test · d0001eaf
      Robert Knight authored
      The Enzyme `hasClass` method was being called on a non-DOM node by
      mistake. This didn't cause any problems, but it just meant that the test
      was not checking what it intended to check.
      d0001eaf
  5. 18 Jan, 2021 12 commits
  6. 15 Jan, 2021 1 commit
  7. 14 Jan, 2021 1 commit
    • Lyza Danger Gardner's avatar
      Refine design and loading state for `NotebookResultCount` · d8f60754
      Lyza Danger Gardner authored
      Redesign the results count for the notebook to better handle its
      behavior when loading (sometimes large) sets of annotations.
      
      Previously, the annotation count used the `visibleCount` store method,
      which returns a count of annotations that are visible on-screen. While
      loading, use the service's reported `total` value to show the number of
      annotations that will be visible once loading is complete.
      
      Do not show thread count while loading, as this cannot be determined
      until all annotations are present and threaded.
      
      Fixes #2864
      d8f60754
  8. 13 Jan, 2021 3 commits
    • Lyza Danger Gardner's avatar
      Adjust UI for sharing annotations on non-shareable documents · 53b33217
      Lyza Danger Gardner authored
      In both the share-this-annotation and share-this-page's-annotations
      components, provide a UI path for when the annotation's URI or the
      page's URI (respectively) are not web-available. That is, to be
      "shareable in context", the URI in question needs to have an
      `http:` or `https:` protocol.
      
      For "share this page's annotations" when the page is not web-accessible,
      explain why the page's annotations can't be shared in context and don't
      provide a sharing link, as it won't work.
      
      For "share this annotation," when the annotation's URI (document) isn't
      web-accessible, provide some explanatory text about how it can't be
      shared in-context, but provide a link to the single-annotation view,
      when available.
      
      These changes are intended to avoid confusion when users try to share an
      annotation or a set of annotations that have been made on a local
      (e.g. PDF) document.
      
      Some SCSS patterns have also been adjusted to accommodate more flexible
      styling of the share-single-annotation panel. The width of the compact
      panel pattern has been increased slightly so that the new wording
      variant for not-shareable-in-context single annotations doesn't risk
      taking up too much vertical space.
      
      Fixes #2786
      53b33217
    • Lyza Danger Gardner's avatar
      3a7c1157
    • Lyza Danger Gardner's avatar
      Add typing utility module · 488664af
      Lyza Danger Gardner authored
      Add a typing utility module with a helper function to "cast" the input
      so that TS understands that it is not null/undefined. This is useful
      in situations where logic would prevent a reference from being empty
      but TS can't follow that logic.
      488664af
  9. 11 Jan, 2021 3 commits