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

V2 style copy updates #1680

Merged
merged 7 commits into from
Jan 22, 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
4 changes: 2 additions & 2 deletions components/NavbarComponents.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,10 +114,10 @@ export const NavbarLinkEffective: React.FC<
<NavDropdown.Item onClick={handleClick}>
<NavLink
className={isMobile ? "navLink-primary" : ""}
href="/learn/to-write-effective-testimony"
href="/learn/testimony-basics"
{...other}
>
{t("navigation.toWriteEffectiveTestimony")}
{t("navigation.aboutTestimony")}
</NavLink>
</NavDropdown.Item>
)
Expand Down
36 changes: 31 additions & 5 deletions components/bill/SmartDisclaimer.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import { useTranslation } from "next-i18next"
import { Trans, useTranslation } from "next-i18next"
import Image from "react-bootstrap/Image"
import styled from "styled-components"
import { useMediaQuery } from "usehooks-ts"
import { Col, Row } from "../bootstrap"
import { NavLink } from "components/Navlink"
import * as links from "../links"

const SmartTagDesc = styled(Row)`
font-size: 12px;
Expand All @@ -16,17 +18,41 @@ export const SmartDisclaimer = () => {
<>
{isMobile ? (
<div className={`m-3`}>
<Row className={`fs-5 fw-bold`}>{t("bill.smart_summary")}</Row>
<SmartTagDesc>{t("bill.smart_disclaimer")}</SmartTagDesc>
<Row className={`fs-5 fw-bold`} fontSize={"12px"}>
{t("bill.smart_summary")}
</Row>
<SmartTagDesc>
<Col>
aaerhart marked this conversation as resolved.
Show resolved Hide resolved
<Trans
t={t}
i18nKey="bill.smart_disclaimer"
components={[
// eslint-disable-next-line react/jsx-key
<links.Internal href="/about/how-maple-uses-ai" />
]}
/>
</Col>
</SmartTagDesc>
</div>
) : (
<Row className={`d-flex my-3`} xs="auto">
<Row className={`d-flex my-3`} fontSize={"12px"} xs="auto">
<Col>
<Image src="/images/smart-summary.svg" alt={t("bill.smart_tag")} />
</Col>
<Col className={`mt-1`} xs="10">
<Row className={`fs-5 fw-bold`}>{t("bill.smart_summary")}</Row>
<SmartTagDesc>{t("bill.smart_disclaimer")}</SmartTagDesc>
<SmartTagDesc>
<Col>
<Trans
t={t}
i18nKey="bill.smart_disclaimer"
components={[
// eslint-disable-next-line react/jsx-key
<links.Internal href="/about/how-maple-uses-ai" />
]}
/>
</Col>
</SmartTagDesc>
</Col>
</Row>
)}
Expand Down
4 changes: 2 additions & 2 deletions components/bill/Summary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export const Summary = ({
className="m-1"
onClick={handleShowBillDetails}
>
{t("bill.read_more")}
{t("bill.view_bill")}
</StyledButton>
) : (
<links.External
Expand Down Expand Up @@ -131,7 +131,7 @@ export const Summary = ({
) : (
<></>
)}
<Row className="fst-italic mx-1 mb-3">{bill.summary}</Row>
<Row className="mx-1 mb-3">{bill.summary}</Row>
<Row className={`d-flex mx-0 my-1`} xs="auto">
{bill.topics?.map(t => (
<SmartTag key={t.topic} icon={t.category} tagName={t.topic} />
Expand Down
4 changes: 2 additions & 2 deletions pages/learn/[slug].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ interface IParams extends ParsedUrlQuery {

const tabs: TabsType[] = [
{
label: "To Write Effective Testimony",
slug: "to-write-effective-testimony",
label: "Testimony Basics",
slug: "testimony-basics",
index: 1,
Component: Basics
},
Expand Down
2 changes: 1 addition & 1 deletion pages/learn/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export default function Page() {
const router = useRouter()

useEffect(() => {
router.push("/learn/to-write-effective-testimony")
router.push("/learn/testimony-basics")
})

return null
Expand Down
5 changes: 3 additions & 2 deletions public/locales/en/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"old_session": "this bill is from session {{billCourt}} - not the current session",
"read_more": "Read More",
"download_pdf": "Download PDF",
"view_bill": "View Bill Text",
"icon": {
"commerce": "Commerce",
"crime_and_law_enforcement": "Crime and Law Enforcement",
Expand All @@ -30,7 +31,7 @@
},
"smart_tag": "AI Smart Tag",
"smart_summary": "Smart Summary & Tags",
"smart_disclaimer": "This content has been generated using artificial intelligence and may not accurately reflect the details of the legislation. To report an inaccuracy or to suggest an improvement, please email [email protected]"
"smart_disclaimer": "This content has been generated using artificial intelligence and may not accurately reflect the details of the legislation. Learn more about <0>how MAPLE uses AI</0>. To report an inaccuracy or to suggest an improvement, please email [email protected]"
},
"bill_updates": "Bill Updates",
"browse_bills": "browse bills",
Expand Down Expand Up @@ -76,7 +77,7 @@
"privacyAndConduct": "Privacy Policy & Code of Conduct",
"signOut": "Sign Out",
"supportMaple": "Support MAPLE",
"toWriteEffectiveTestimony": "To Write Effective Testimony",
"aboutTestimony": "About Testimony",
"viewProfile": "View Profile",
"whyUseMaple": "Why Use MAPLE"
},
Expand Down
2 changes: 1 addition & 1 deletion public/locales/en/learnComponents.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"basics": {
"title": "To Write Effective Testimony",
"title": "Testimony Basics",
"intro": "All laws passed by state legislatures should consider feedback from residents and community stakeholders. In Massachusetts, one way to have your voice heard is by submitting written testimony regarding specific bills. This website, the MAPLE platform, can help you submit your written testimony to the MA Legislature. However, please note that this is not an official government website and is not the only way to submit your testimony. Here are the essential things to know before submitting testimony:",
"content": [
{
Expand Down
Loading