1. 22 Apr, 2021 3 commits
    • Robert Knight's avatar
      843f684e
    • Robert Knight's avatar
      Rename property containing unused params in `replaceURLParams` return value · 68f3ef05
      Robert Knight authored
      Rename property from `params` to `unusedParams` for clarity.
      68f3ef05
    • Robert Knight's avatar
      Reimplement service URL fetching · 6b0c776f
      Robert Knight authored
      Change the way that links pointing into the Hypothesis service (eg. for
      tags, users, account settings etc.) are fetched and generated. The new
      implementation better matches patterns used elsewhere in the application
      and ensures that UI components displaying these links re-render if the
      `/api/links` response is received after the component is initially
      rendered.
      
       - Move the logic for rendering the URL templates from the `serviceUrl`
         service into a selector in the `links` store module. Components then
         render links using `store.getLink(...)`. This ensures use of the existing
         mechanism that re-renders components when relevant store data changes.
      
       - Convert the `serviceUrl` service to an ES class
      
       - Move the logic for fetching URL templates from the `/api/links`
         endpoint into an `init` method of the `ServiceURLService` service.
         This matches the convention used by several other services.
      
       - Remove unused `serviceUrl` dependency from `groups` service
      6b0c776f
  2. 20 Apr, 2021 11 commits
  3. 19 Apr, 2021 9 commits
  4. 16 Apr, 2021 12 commits
  5. 15 Apr, 2021 5 commits
    • Kyle Keating's avatar
      Use directLinkedGroupId when loading groups · 375d83d1
      Kyle Keating authored
      Change loadServiceSpecifiedGroups() so that it can pass along an optional group ID setting value from the `directLinkedGroupId` selector to be an initially focused group.
      
      When loading groups from a service e.g. `loadServiceSpecifiedGroups`, previously it assumed that the `directLinkedGroupId` value would never be used in this context. Since the introduction of the Notebook and specifically in the context of LMS, we have both a service setting which contains the groups  (`settings.services[0].groups <Promise>`) and a top level group to set focus too. (`settings.group`).
      375d83d1
    • Robert Knight's avatar
      Revise some comments following PR feedback · 5f3f5421
      Robert Knight authored
      5f3f5421
    • Robert Knight's avatar
      Ensure confirmation dialog appears above top bar · c815849a
      Robert Knight authored
      Set a Z-index that is sufficient to make the dialog appear on top of
      other content in the sidebar, mainly the top bar. We will likely have to
      revise this if `confirm` is used in other contexts in future.
      c815849a
    • Robert Knight's avatar
      Convert existing `window.confirm` calls to use `confirm` prompt · f2352018
      Robert Knight authored
      Convert existing uses of `window.confirm` to use our own `confirm`
      utility which uses the standard Dialog from our pattern library.
      
      Using our own prompt avoids an immediate problem that browsers, starting
      with Chrome v91, are starting to block the use of `window.confirm` in
      third-party iframe. It also makes the visual design of the prompt match
      the rest of the application.
      f2352018
    • Robert Knight's avatar