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

Release to val #1202

Merged
merged 2 commits into from
Feb 25, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions lib/libs/email/content/email-components.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Column, Heading, Hr, Link, Row, Section, Text } from "@react-email/components";
import { ReactNode } from "react";
import { ReactNode, Fragment } from "react";
import {
Attachment,
AttachmentKey,
Expand Down Expand Up @@ -190,7 +190,16 @@ const PackageDetails = ({ details }: { details: Record<string, ReactNode> }) =>
Summary:
</Heading>
</Text>
<Text style={styles.text.base}>{value ?? "No additional information submitted"}</Text>
<Text style={styles.text.base}>
{value
? value.split("\n").map((line, index, array) => (
<Fragment key={index}>
{line}
{index !== array.length - 1 && <br />}
</Fragment>
))
: "No additional information submitted"}
</Text>
</Row>
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ export default () => {
<Waiver1915bStateEmail
variables={{
...emailTemplateValue,
additionalInformation: "",
waiverNumber: "CO-1234.R21.00",
attachments: {
b4WaiverApplication: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ export default () => {
<Waiver1915bStateEmail
variables={{
...emailTemplateValue,
additionalInformation:
"This is text\n\n\nwith a bunch of b/n linebreaks\n\n\n\n\n\n\n\n to test that linebreaks get converted to <br> elements",
attachments: {
b4WaiverApplication: {
label: "1915(b) Comprehensive (Contracting) Waiver Application Pre-print",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export default () => {
variables={{
...emailTemplateValue,
waiverNumber: "CO-1234.R21.00",
additionalInformation: "Testing with an emoji 😄",
attachments: {
b4IndependentAssessment: {
label: "1915(b) Comprehensive (Contracting) Waiver Independent Assessment",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7529,7 +7529,20 @@ exports[`Initial Submission State Email Snapshot Test > renders a Amendment Cont
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
This is text
<br />
<br />
<br />
with a bunch of b/n linebreaks
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
to test that linebreaks get converted to &lt;br&gt; elements
</p>
</tr>
</tbody>
Expand Down Expand Up @@ -8023,7 +8036,7 @@ exports[`Initial Submission State Email Snapshot Test > renders a Amendment Cont
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
Testing with an emoji 😄
</p>
</tr>
</tbody>
Expand Down Expand Up @@ -8517,7 +8530,7 @@ exports[`Initial Submission State Email Snapshot Test > renders a Amendment Cont
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
No additional information submitted
</p>
</tr>
</tbody>
Expand Down Expand Up @@ -9012,7 +9025,7 @@ exports[`Initial Submission State Email Snapshot Test > renders a Amendment Cont
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
No additional information submitted
</p>
</tr>
</tbody>
Expand Down Expand Up @@ -17982,7 +17995,20 @@ exports[`Initial Submission State Email Snapshot Test > renders a Initial Contra
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
This is text
<br />
<br />
<br />
with a bunch of b/n linebreaks
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
to test that linebreaks get converted to &lt;br&gt; elements
</p>
</tr>
</tbody>
Expand Down Expand Up @@ -18477,7 +18503,20 @@ exports[`Initial Submission State Email Snapshot Test > renders a Initial Contra
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
This is text
<br />
<br />
<br />
with a bunch of b/n linebreaks
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
to test that linebreaks get converted to &lt;br&gt; elements
</p>
</tr>
</tbody>
Expand Down Expand Up @@ -27410,7 +27449,20 @@ exports[`Initial Submission State Email Snapshot Test > renders a Renewal Contra
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
This is text
<br />
<br />
<br />
with a bunch of b/n linebreaks
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
to test that linebreaks get converted to &lt;br&gt; elements
</p>
</tr>
</tbody>
Expand Down Expand Up @@ -27904,7 +27956,7 @@ exports[`Initial Submission State Email Snapshot Test > renders a Renewal Contra
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
Testing with an emoji 😄
</p>
</tr>
</tbody>
Expand Down Expand Up @@ -28399,7 +28451,7 @@ exports[`Initial Submission State Email Snapshot Test > renders a Renewal Contra
<p
style="font-size: 14px; line-height: 1.4; margin: 12px 0px; color: rgb(51, 51, 51);"
>
This submission includes necessary documentation for requested updates to the state’s Medicaid plan, in alignment with CMS requirements.
Testing with an emoji 😄
</p>
</tr>
</tbody>
Expand Down
2 changes: 1 addition & 1 deletion react-app/src/components/Footer/Footer.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ describe("FAQFooter", () => {
</BrowserRouter>,
);

expect(screen.queryByText("View FAQ")).toBeInTheDocument();
expect(screen.queryByText("View FAQs")).toBeInTheDocument();
expect(screen.queryByText("Do you have questions or need support?")).toBeInTheDocument();
});
});
2 changes: 1 addition & 1 deletion react-app/src/components/Footer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ export const FAQFooter = () => {
<p className="text-lg">Do you have questions or need support?</p>
<Link to="/faq" target="_blank">
<Button className="mx-4" size="lg">
View FAQ
View FAQs
</Button>
</Link>
</Alert>
Expand Down
6 changes: 3 additions & 3 deletions react-app/src/components/Layout/index.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ describe("Layout", () => {
await setupLayoutTest(VIEW_MODES.DESKTOP);
expect(screen.getByText("Home")).toBeInTheDocument();
expect(screen.getByText("Dashboard")).toBeInTheDocument();
expect(screen.getByText("FAQ")).toBeInTheDocument();
expect(screen.getByText("View FAQs")).toBeInTheDocument();
expect(screen.getByText("Webforms")).toBeInTheDocument();
expect(screen.queryByText("Sign In")).not.toBeInTheDocument();
expect(screen.queryByText("Register")).not.toBeInTheDocument();
Expand All @@ -261,7 +261,7 @@ describe("Layout", () => {
it("renders nav links for unauthenticated user in desktop view", async () => {
await setupLayoutTest(VIEW_MODES.DESKTOP, null);
expect(screen.getByText("Home")).toBeInTheDocument();
expect(screen.getByText("FAQ")).toBeInTheDocument();
expect(screen.getByText("View FAQs")).toBeInTheDocument();
expect(screen.queryByText("Dashboard")).not.toBeInTheDocument();
expect(screen.queryByText("Webforms")).not.toBeInTheDocument();
});
Expand All @@ -278,7 +278,7 @@ describe("Layout", () => {

expect(screen.getByText("Home")).toBeInTheDocument();
expect(screen.getByText("Dashboard")).toBeInTheDocument();
expect(screen.getByText("FAQ")).toBeInTheDocument();
expect(screen.getByText("View FAQs")).toBeInTheDocument();
expect(screen.getByText("Webforms")).toBeInTheDocument();

// Close the menu
Expand Down
2 changes: 1 addition & 1 deletion react-app/src/components/Layout/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const useGetLinks = () => {
),
},
{
name: "FAQ",
name: "View FAQs",
link: "/faq",
condition: true,
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ exports[`Toggle Withdraw Rai components > renders disable withdraw rai correctly
<button
class="inline-flex items-center justify-center text-[16px] font-bold ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 bg-primary text-slate-50 hover:bg-primary-dark h-11 rounded-md px-8 mx-4"
>
View FAQ
View FAQs
</button>
</a>
</div>
Expand Down Expand Up @@ -364,7 +364,7 @@ exports[`Toggle Withdraw Rai components > renders disable withdraw rai correctly
<button
class="inline-flex items-center justify-center text-[16px] font-bold ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 bg-primary text-slate-50 hover:bg-primary-dark h-11 rounded-md px-8 mx-4"
>
View FAQ
View FAQs
</button>
</a>
</div>
Expand Down Expand Up @@ -605,7 +605,7 @@ exports[`Toggle Withdraw Rai components > renders disable withdraw rai correctly
<button
class="inline-flex items-center justify-center text-[16px] font-bold ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 bg-primary text-slate-50 hover:bg-primary-dark h-11 rounded-md px-8 mx-4"
>
View FAQ
View FAQs
</button>
</a>
</div>
Expand Down Expand Up @@ -789,7 +789,7 @@ exports[`Toggle Withdraw Rai components > renders disable withdraw rai correctly
<button
class="inline-flex items-center justify-center text-[16px] font-bold ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 bg-primary text-slate-50 hover:bg-primary-dark h-11 rounded-md px-8 mx-4"
>
View FAQ
View FAQs
</button>
</a>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ exports[`WithdrawPackageAction components > renders WithdrawPackageActionWaiver
<button
class="inline-flex items-center justify-center text-[16px] font-bold ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 bg-primary text-slate-50 hover:bg-primary-dark h-11 rounded-md px-8 mx-4"
>
View FAQ
View FAQs
</button>
</a>
</div>
Expand Down Expand Up @@ -816,7 +816,7 @@ exports[`WithdrawPackageAction components > renders WithdrawPackageActionWaiver
<button
class="inline-flex items-center justify-center text-[16px] font-bold ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 bg-primary text-slate-50 hover:bg-primary-dark h-11 rounded-md px-8 mx-4"
>
View FAQ
View FAQs
</button>
</a>
</div>
Expand Down
2 changes: 1 addition & 1 deletion react-app/src/features/welcome/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ export const Welcome = () => {
<div className="flex justify-around items-center text-xl px-10 py-2 max-w-screen-xl mx-auto">
<h4>Do you have questions or need support?</h4>
<Link to="/faq" target={FAQ_TAB}>
<Button>View FAQ</Button>
<Button>View FAQs</Button>
</Link>
</div>
</section>
Expand Down
Loading