Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR introduces a configurable legal text system for terms and conditions and privacy policy links across the intake application. The changes centralize legal text configuration and replace hardcoded legal text with a dynamic component that reads from configuration.
- Adds new configuration types and schemas for legal text composition with DisplayText and Link nodes
- Implements a
TermsAndConditionscomponent that renders legal text based on page-specific configuration - Updates review pages to use the new configurable component instead of hardcoded legal text
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
packages/utils/lib/configuration/types.ts |
Defines Zod schemas for DisplayText and Link configuration nodes |
packages/utils/lib/configuration/legal/index.ts |
Implements legal configuration with defaults, overrides, and helper functions to retrieve legal text by location |
packages/utils/lib/configuration/index.ts |
Exports the new legal configuration module |
packages/utils/.ottehr_config/legal/index.ts |
Creates empty legal overrides configuration file |
packages/utils/.ottehr_config/index.ts |
Exports the legal overrides |
apps/intake/src/components/TermsAndConditions.tsx |
New component that dynamically renders legal text based on configuration |
apps/intake/src/pages/Review.tsx |
Replaces hardcoded legal text with TermsAndConditions component |
apps/intake/src/pages/ReviewPaperwork.tsx |
Replaces hardcoded legal text with TermsAndConditions component |
apps/intake/tests/component/ReviewPage.test.tsx |
Updates tests to work with dynamic configuration |
apps/intake/tests/specs/telemed/PaperworkTelemedReviewScreen.spec.ts |
Updates E2E tests to conditionally check for legal links based on configuration |
apps/intake/tests/specs/in-person/PaperworkReviewScreen.spec.ts |
Updates E2E tests to conditionally check for legal links based on configuration |
apps/intake/tests/specs/in-person/CheckReviewAndSubmitScreen.spec.ts |
Updates E2E tests to conditionally check for legal links based on configuration |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Contributor
…fined access Co-authored-by: imbenham <5749511+imbenham@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: imbenham <isaac.benham@gmail.com>
Fix null check in getLegalCompositionForLocation
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: imbenham <isaac.benham@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: imbenham <isaac.benham@gmail.com>
5 tasks
Contributor
9 tasks
Contributor
…t in tests Co-authored-by: imbenham <5749511+imbenham@users.noreply.github.com>
[WIP] WIP to address review feedback on 'Config ts cs' pull request
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.