Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

linkify-notification-repository-header: Security advisory notifications linked with invalid target URL #7225

Open
vintagesucks opened this issue Jan 21, 2024 · 0 comments
Labels
bug help wanted small Issues that new contributors can pick up

Comments

@vintagesucks
Copy link

Description

When notifications are grouped by repository, security advisory notifications are grouped under a "Security Advisories" header. This header is linked by linkify-notification-repository-header, even though the original header does not contain a link. The resulting link is /Security Advisories, which leads nowhere (404).


Original header:

grafik

HTML
<div class="Box-header d-flex flex-items-center p-2 pl-3">
  <h6 class="m-0 flex-auto">Security Advisories</h6>
  <!-- '"` --><!-- </textarea></xmp> -->
  <form class="d-none d-md-block js-grouped-notifications-mark-all-read-button" data-turbo="false" action="/notifications/beta/archive" accept-charset="UTF-8" method="post">
    <input type="hidden" name="authenticity_token" value="<removed>" />
    <input type="hidden" name="notification_ids[]" value="<removed>" />
    <input type="hidden" name="notification_ids[]" value="<removed>" />

    <button type="submit" class="btn btn-sm">
      <span class="d-inline-block text-center" style="width:16px">
        <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check">
          <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg
      ></span>
      Mark as done
    </button>
  </form>
</div>

Header with Refined GitHub:

grafik

HTML
<div class="Box-header d-flex flex-items-center rgh-seen--<removed> p-2 pl-3">
  <h6 class="rgh-seen--<removed> m-0 flex-auto"><a class="color-fg-inherit" href="/Security Advisories"> Security Advisories </a></h6>
  <!-- '"` --><!-- </textarea></xmp> -->
  <form class="d-none d-md-block js-grouped-notifications-mark-all-read-button rgh-seen--<removed>" data-turbo="false" action="/notifications/beta/archive" accept-charset="UTF-8" method="post">
    <input type="hidden" name="authenticity_token" value="<removed>" />
    <input type="hidden" name="notification_ids[]" value="<removed>" />
    <input type="hidden" name="notification_ids[]" value="<removed>" />

    <button type="submit" class="btn btn-sm">
      <span class="d-inline-block text-center" style="width:16px">
        <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check">
          <path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path></svg
      ></span>
      Mark as done
    </button>
  </form>
  <button class="btn btn-sm d-none rgh-open-notifications-button ml-auto" type="button">
    <svg class="octicon octicon-link-external mr-1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" role="img" aria-hidden="true"><path d="M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z"></path></svg>Open all unread
  </button>
</div>

How to replicate the issue + URL

https://github.com/notifications (requires security advisory notifications)

Extension version

24.1.10

Browser(s) used

Firefox Developer Edition 122.0b9 (64-Bit)

@fregante fregante added help wanted small Issues that new contributors can pick up labels Jan 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug help wanted small Issues that new contributors can pick up
Development

No branches or pull requests

2 participants