Skip to content

Conversation

@johnnyporkchops
Copy link
Contributor

Summary (required)

  • Resolves #issue_number

  • Keyword search document highlights

  • Proximity search document display

Required reviewers

(Include who is required to review prior to merge. For example: One designer and two front end developer reviews are required prior to merge)

Impacted areas of the application

General components of the application that this PR will affect:
Rulemakings datatable

Screenshots

(Include a screenshot of the new/updated features in context (“in the wild”). If it is an interface change, include both before and after screenshots)

Related PRs

Related PRs against other branches:

branch PR
fix/other_pr link
feature/other_pr link

How to test

(Include any information that may be helpful to the reviewer(s). This might include links to sample pages to test or any local environmental setup that is unusual such as environment variable (never credentials), API version to point to, etc)

System architecture updates (if applicable)

(If this pull request changes our current system diagram, include a description of those changes here and create a new ticket to update the system diagram)

@johnnyporkchops johnnyporkchops marked this pull request as draft January 9, 2026 14:59
Copy link
Member

@patphongs patphongs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@johnnyporkchops Thanks for your work on this. On my initial look, this is what I've found so far. I'll take a closer look next week.

}
}
}
return eligible_documents.map(doc => `<strong>${doc}</strong><br>Comment deadline: ${comment_deadline}<br><a class="button--cta" href="/legal/rulemakings/${row.rm_no}/add-comments/">Submit a comment</a>`).join('');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since there is the potential of multiple documents being open for comment at once, we should think about making each of these buttons unique somehow. Maybe using the document ID /legal/rulemakings/${row.rm_no}/[doc_id]/add-comments/". If we do this though, we'll probably need to tweak the logic of the rulemaking comment application as well. But first, let's confirm with stakeholders if this is a potential issue or if there will only ever be one document open for comment at once. If there will only be one, then we can scrap the idea of having multiple comment buttons.

Comment on lines 70 to 75
$('#search-input').on('change', function(e) {
handleKeywordSearchChange(e);
});

let new_val;
const handleKeywordSearchChange = function(e) {
const newVal = e.target.value;
new_val = e.target.value;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When you enter a keyword search and then do a page refresh, you'll see that q=undefined in the URL. It appears that this new_val variable is declared but never initialized?

John Carroll and others added 3 commits January 22, 2026 15:04
…ight() function to clean highlight, updated comment button URL to add doc id, added import of legal-search styles for highlights, made the extra empty <th> column conditional
@codecov
Copy link

codecov bot commented Jan 23, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.20%. Comparing base (58b4240) to head (993be8f).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #6932   +/-   ##
========================================
  Coverage    80.20%   80.20%           
========================================
  Files          253      253           
  Lines         6324     6324           
========================================
  Hits          5072     5072           
  Misses        1252     1252           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

…simplified some logic and cleaned up spacing / console debug statements
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

3 participants