import React, { useMemo } from "react";
import { PropTypes } from "prop-types";
import { Layer } from "mobility-toolbox-js/ol";
import useTranslation from "../../utils/useTranslation";
import DataLink from "../../components/DataLink";
const comps = {
  de: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", null, "Die Karte stellt die Anzahl der Ein- und Aussteigenden an den Bahnh\xF6fen und Haltestellen der Eisenbahn dar. Die Zahlen beziehen sich auf den durchschnittlichen werkt\xE4glichen Verkehr (Montag bis Freitag) und die f\xFCr den jeweiligen Bahnhof angegebenen Eisenbahnverkehrs\xADunternehmen. Ein- und Aussteigende anderer \xF6ffentlicher Verkehrsmittel sowie Passanten werden nicht ber\xFCcksichtigt. Umsteigende z\xE4hlen sowohl als Aus- wie als Einsteigende, also zweifach."), /*#__PURE__*/React.createElement("p", null, "Daten: ", /*#__PURE__*/React.createElement("a", {
    href: "mailto:stat@sbb.ch"
  }, "stat@sbb.ch"), ".")),
  fr: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", null, "La carte repr\xE9sente le nombre de personnes montant et descendant des trains dans les gares et aux arr\xEAts. Les chiffres se r\xE9f\xE8rent au trafic journalier moyen des jours ouvr\xE9s (lundi \xE0 vendredi) et aux entreprises de transport ferroviaire indiqu\xE9es pour chaque gare. Ni les personnes montant et descendant d\u2019autres modes de transports publics, ni les passant\xB7e\xB7s ne sont pris en compte. Les voyageuses et voyageurs qui changent de train sont compt\xE9s deux fois, \xE0 savoir comme personnes descendant du train et comme personnes montant \xE0 bord."), /*#__PURE__*/React.createElement("p", null, "Donn\xE9es: ", /*#__PURE__*/React.createElement("a", {
    href: "mailto:stat@sbb.ch"
  }, "stat@sbb.ch"), ".")),
  en: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", null, "The map depicts the number of passengers boarding and alighting at railway stations and stops. The figures refer to average weekday traffic (Monday to Friday) and the railway undertakings indicated for the respective station. Passengers boarding and alighting other public transport as well as passers-by are not taken into account. Passengers changing trains are counted twice, as both alighting and boarding."), /*#__PURE__*/React.createElement("p", null, "Data: ", /*#__PURE__*/React.createElement("a", {
    href: "mailto:stat@sbb.ch"
  }, "stat@sbb.ch"), ".")),
  it: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("p", null, "La mappa rappresenta il numero di persone che salgono e scendono dal treno nelle stazioni e alle fermate ferroviarie. I dati si riferiscono al traffico feriale medio (dal luned\xEC al venerd\xEC) e alle imprese di trasporto ferroviario indicate per la rispettiva stazione. Le persone che salgono e scendono da altri mezzi pubblici e i passanti non vengono presi in considerazione. I viaggiatori in coincidenza sono conteggiati due volte, sia quando salgono, sia quando scendono."), /*#__PURE__*/React.createElement("p", null, "Dati: ", /*#__PURE__*/React.createElement("a", {
    href: "mailto:stat@sbb.ch"
  }, "stat@sbb.ch"), "."))
};
function PassagierFrequenzenLayerInfo(_ref) {
  let {
    properties: layer
  } = _ref;
  const {
    i18n,
    t
  } = useTranslation();
  const statisticsLink = useMemo(() => {
    const {
      language: lang
    } = i18n;
    return "https://reporting.sbb.ch".concat(lang === "de" ? "" : "/".concat(lang), "/").concat(t("verkehr"), "?highlighted=row-243");
  }, [i18n, t]);
  return /*#__PURE__*/React.createElement("div", null, comps[i18n.language], /*#__PURE__*/React.createElement("hr", null), /*#__PURE__*/React.createElement("p", null, /*#__PURE__*/React.createElement(DataLink, {
    href: statisticsLink,
    layer: layer
  })), /*#__PURE__*/React.createElement("p", null, /*#__PURE__*/React.createElement(DataLink, {
    href: "https://geo.sbb.ch/portal/home/group.html?id=4778f8efa0ad41a6829f0094339158e2#overview"
  }, t("Zu den Trafimage-Datensätzen im SBB Geoportal (SBB-intern)"))));
}
PassagierFrequenzenLayerInfo.propTypes = {
  properties: PropTypes.instanceOf(Layer)
};
export default /*#__PURE__*/React.memo(PassagierFrequenzenLayerInfo);
//# sourceMappingURL=PassagierFrequenzenLayerInfo.js.map