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

Add translations for strings #295

Merged
merged 3 commits into from
May 20, 2020
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
2 changes: 1 addition & 1 deletion apps/public-reference/pages/HousingCounselors.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export default class extends Component<HousingCounselorsProps> {
})}
{this.props.counselors.length == 0 && (
<article className="flex-row flex-wrap max-w-5xl m-auto py-8 border-b-2">
<p>None found.</p>
<p>{t("t.noneFound")}</p>
</article>
)}
</Layout>
Expand Down
4 changes: 2 additions & 2 deletions apps/public-reference/pages/disclaimer.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import Layout from "../layouts/application"
import { PageHeader, MarkdownSection } from "@bloom-housing/ui-components"
import { PageHeader, MarkdownSection, t } from "@bloom-housing/ui-components"
import PageContent from "../page_content/disclaimer.mdx"

export default () => {
const pageTitle = <>Endorsement Disclaimers</>
const pageTitle = <>{t("pageTitle.disclaimer")}</>

return (
<Layout>
Expand Down
6 changes: 4 additions & 2 deletions apps/public-reference/pages/listing.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ export default class extends Component<ListingProps> {
<p className="text-gray-700 text-base">{listing.developer}</p>
<p className="text-xs">
<a href={googleMapsHref} target="_blank" aria-label="Opens in new window">
View on Map
{t("t.viewOnMap")}
</a>
</p>
</div>
Expand All @@ -165,7 +165,9 @@ export default class extends Component<ListingProps> {

return (
<>
<h2 className="mt-4 mb-2">{percent}% AMI Unit</h2>
<h2 className="mt-4 mb-2">
{t("listings.percentAMIUnit", { percent: percent })}
</h2>
<GroupedTable
headers={unitSummariesHeaders}
data={groupedUnits}
Expand Down
4 changes: 2 additions & 2 deletions apps/public-reference/pages/privacy.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { MarkdownSection, PageHeader } from "@bloom-housing/ui-components"
import { MarkdownSection, PageHeader, t } from "@bloom-housing/ui-components"
import Layout from "../layouts/application"
import PageContent from "../page_content/privacy_policy.mdx"

export default () => {
const pageTitle = <>Privacy Policy</>
const pageTitle = <>{t("pageTitle.privacy")}</>

return (
<Layout>
Expand Down
7 changes: 5 additions & 2 deletions shared/ui-components/src/locales/general.json
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@
"occupancyDescriptionSomeSro": "Occupancy for this building varies by unit type. SROs are limited to 1 person per unit, regardless of age. For all other unit types, occupancy limits do not count children under 6.",
"people": "people",
"person": "person",
"percentAMIUnit": "%{percent}% AMI Unit",
"priorityUnits": "Priority Units",
"priorityUnitsDescription": "This building has units set aside if any of the following apply to you or someone in your household:",
"remainingUnitsAfterPreferenceConsideration": "After all preference holders have been considered, any remaining units will be available to qualified applicants.",
Expand Down Expand Up @@ -188,7 +189,7 @@
},
"pageTitle": {
"additionalResources": "More Housing Opportunities",
"disclaimer": "Disclaimer",
"disclaimer": "Endorsement Disclaimers",
"housingCounselors": "Housing Counselors",
"getAssistance": "Get Assistance",
"rentalListings": "See Rentals",
Expand All @@ -214,6 +215,7 @@
"minimumIncome": "Minimum Income",
"neighborhood": "Neighborhood",
"none": "None",
"noneFound": "None found.",
"occupancy": "Occupancy",
"or": "or",
"petsPolicy": "Pets Policy",
Expand All @@ -225,7 +227,8 @@
"sqFeet": "sqft",
"unitAmenities": "Unit Amenities",
"unitFeatures": "Unit Features",
"unitType": "Unit Type"
"unitType": "Unit Type",
"viewOnMap": "View on Map"
},
"welcome": {
"allApplicationClosed": "All applications are currently closed, but you can view closed listings.",
Expand Down