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

feat: Integrate OpenLaws API #54

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from
Draft

feat: Integrate OpenLaws API #54

wants to merge 4 commits into from

Conversation

evadecker
Copy link
Contributor

@evadecker evadecker commented Sep 11, 2024

What changed?

Create a new /laws page which integrates with the OpenLaws API to allow searching regulations per-state by keyword.

Why?

We probably want a different UI than this, but integrating with a legal API could be helpful for maintaining a feed of new regulations for name and gender markers across different states.

How was this change made?

  • Added an environment variable in Convex for the OpenLaws API Key
  • Created a Convex action that fetches from the OpenLaws API
  • Created a new /laws page to display the results of the action and allow users to type into a search field and use a jurisdiction dropdown

How was this tested?

Tiny amount of manual testing

Anything else?

This would need a lot more UI work and code cleanup before merge and is mostly for testing right now.

Copy link

changeset-bot bot commented Sep 11, 2024

🦋 Changeset detected

Latest commit: 4f2ff9c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
namesake Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

github-actions bot commented Sep 11, 2024

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 4.15%
⬇️ -0.14%
122 / 2937
🔵 Statements 4.15%
⬇️ -0.14%
122 / 2937
🔵 Functions 1.33%
⬇️ -0.03%
1 / 75
🔵 Branches 4.28%
⬇️ -0.13%
3 / 70
File Coverage
File Stmts % Branch % Funcs % Lines Uncovered Lines
Changed Files
convex/openlaws.ts 0% 0% 0% 0% 1-2, 59-68, 70-75, 77-80
src/components/shared/AppHeader.tsx 0% 0% 0% 0% 1-4, 6-7, 9-13, 15, 17-21, 23-25, 29-30, 35
src/components/shared/SearchField.tsx 0% 0% 0% 0% 1, 7-9, 17-28, 31-35, 37-39, 42-43, 46
src/routes/laws/index.tsx 0% 0% 0% 0% 1-3, 5-8, 16, 18-20, 22-23, 25-28, 30-31, 33-39, 41-44, 46-48, 50-53, 55-57, 59-61, 63-71, 77, 79-87, 89-91, 95-98, 101-102, 106
Generated in workflow #44

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant