Skip to content

Commit

Permalink
Update Partners' modal
Browse files Browse the repository at this point in the history
  • Loading branch information
starsep committed Nov 18, 2023
1 parent 1205e8b commit 3770389
Show file tree
Hide file tree
Showing 6 changed files with 83 additions and 73 deletions.
Binary file added public/img/logo-cez.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/logo-pw.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions public/locales/en/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,13 @@
"thanks_for_report": "Thank you for sending a report. It will be reviewed by the site administrators."
},
"partners": {
"e_health_centre": "e-Health Centre",
"honorary_patronage": "Honorary patronage",
"gugik": "Head Office of Geodesy and Cartography in Poland",
"acting": "acting",
"chief_geodesist": "Chief Geodesist of Poland",
"main_scientific_partner": "The Main Scientific Partner",
"warsaw_university_of_technology": "Warsaw University of Technology",
"wroclaw_medical_university": "Wroclaw Medical University"
},
"common": {
Expand Down
2 changes: 2 additions & 0 deletions public/locales/pl/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,13 @@
"thanks_for_report": "Dziękujemy za wysłanie zgłoszenia. Zostanieono przeanalizowane przez administratorów strony."
},
"partners": {
"e_health_centre": "Centrum e-Zdrowia",
"honorary_patronage": "Patronat honorowy",
"gugik": "Główny Urząd Geodezji i Kartografii",
"acting": "p. o.",
"chief_geodesist": "Główny Geodeta Kraju",
"main_scientific_partner": "Główny Partner Naukowy",
"warsaw_university_of_technology": "Politechnika Warszawska",
"wroclaw_medical_university": "Uniwersytet Medyczny im. Piastów Śląskich we Wrocławiu"
},
"common": {
Expand Down
149 changes: 77 additions & 72 deletions src/components/partnersModal.tsx
Original file line number Diff line number Diff line change
@@ -1,91 +1,96 @@
import React, { FC } from "react";
import { useTranslation } from "react-i18next";

interface Partner {
name: string;
person: string | null;
role: string | null;
image: string;
imageHeight: number;
url: string;
}

const PartnersModal: FC<{}> = () => {
const { t } = useTranslation();
const cloudFerro = "CloudFerro";
const partners: Partner[] = [
{
name: "CloudFerro",
person: null,
role: null,
image: "cloudferro_logo-dark.png",
imageHeight: 55,
url: "https://cloudferro.com/",
},
{
name: t("partners.wroclaw_medical_university"),
person: null,
role: t("partners.main_scientific_partner"),
image: "logo-umw.jpg", // TODO: vector logo
imageHeight: 40,
url: "https://www.umw.edu.pl",
},
{
name: t("partners.e_health_centre"),
person: null,
role: null,
image: "logo-cez.png",
imageHeight: 67,
url: "https://cez.gov.pl",
},
{
name: t("partners.warsaw_university_of_technology"),
person: null,
role: null,
image: "logo-pw.png",
imageHeight: 80,
url: "https://pw.edu.pl/",
},
{
name: t("partners.gugik"),
person: "Alicja Kulka",
role: `${t("partners.acting")} ${t("partners.chief_geodesist")}`,
image: "logo-gugik-short.png",
imageHeight: 55,
url: "https://www.gov.pl/web/gugik",
},
];
return (
<>
<section className="modal-card-body has-text-weight-light" id="partners-modal">
<div className="pb-3 pt-5 pl-5 box">
<div className="media partner-row">
<div className="media-left">
<figure className="image">
<img
alt={t("partners.gugik")}
src="./img/logo-gugik-short.png"
/>
</figure>
</div>
<div className="media-content">
<a href="http://www.gugik.gov.pl/" rel="noopener noreferrer" target="_blank">
{t("partners.gugik")}
</a>
<p className="is-size-6">
{/* eslint-disable-next-line react/jsx-no-literals */}
<span className="has-text-weight-semibold">Alicja Kulka</span>
</p>
<span
className="has-text-weight-light has-text-grey is-size-6"
>
{t("partners.acting")}
&nbsp;
{t("partners.chief_geodesist")}
</span>
</div>
</div>

<div className="media partner-row">
<div className="media-left">
<figure className="image">
<img
// TODO: vector logo
src="./img/logo-umw.jpg"
alt={t("partners.wroclaw_medical_university")}
style={{ height: "40px" }}
/>
</figure>
</div>
<div className="media-content">
<a href="https://www.umw.edu.pl" rel="noopener noreferrer" target="_blank">
{t("partners.wroclaw_medical_university")}
</a>
<p className="is-size-6">
<span className="has-text-weight-light has-text-grey is-size-6">
{t("partners.main_scientific_partner")}
</span>
</p>
</div>
</div>

<div className="media partner-row">
<div className="media-left">
<figure className="image">
<img
alt={cloudFerro}
src="./img/cloudferro_logo-dark.png"
style={{ height: "55px" }}
/>
</figure>
</div>
<div className="media-content">
<a href="https://cloudferro.com/" rel="noopener noreferrer" target="_blank">
{cloudFerro}
</a>
{partners.map((partner) => (
<div className="media partner-row">
<div className="media-left">
<figure className="image">
<img
alt={partner.name}
src={`./img/${partner.image}`}
style={{ height: `${partner.imageHeight}px` }}
/>
</figure>
</div>
<div className="media-content">
<a href={partner.url} rel="noopener noreferrer" target="_blank">{partner.name}</a>
{partner.person !== null && (
<p className="is-size-6">
<span className="has-text-weight-semibold">{partner.person}</span>
</p>
)}
{partner.role !== null && (
<div className="has-text-weight-light has-text-grey is-size-6">
{partner.role}
</div>
)}
</div>
</div>
</div>
))}
</div>
</section>
<footer className="modal-card-foot p-2">
<div className="notification is-info is-light">
{t("modal.become_openaedmap_partner")}
&nbsp;
<a
className="has-text-weight-medium"
href="mailto:[email protected]"
>
{t("modal.contact_us")}
</a>
<a className="has-text-weight-medium" href="mailto:[email protected]">{t("modal.contact_us")}</a>
.
</div>
</footer>
Expand Down
3 changes: 2 additions & 1 deletion src/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -84,5 +84,6 @@ a.navbar-item:focus-within, a.navbar-item:hover {
}

.partner-row {
flex-wrap: wrap;
flex-wrap: wrap;
align-items: center !important;
}

0 comments on commit 3770389

Please sign in to comment.