Skip to content

Commit

Permalink
Merge branch 'master' into feature-arcgis-server-support
Browse files Browse the repository at this point in the history
  • Loading branch information
underbluewaters committed Oct 11, 2023
2 parents c7b7b7c + aec0a5a commit 3f76d40
Show file tree
Hide file tree
Showing 72 changed files with 973 additions and 10 deletions.
23 changes: 22 additions & 1 deletion packages/client/src/draw/MapSettingsPopup.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import {
} from "../generated/graphql";
import { FormElementLayoutContext } from "../surveys/SurveyAppLayout";
import { MeasureControlContext, MeasureControlLockId } from "../MeasureControl";
import useDialog from "../components/useDialog";

type PopupPosition = "top" | "bottom";

Expand Down Expand Up @@ -192,7 +193,16 @@ const Item: FunctionComponent<{
disabled?: boolean;
phoneOnly?: boolean;
selected?: boolean;
}> = ({ onClick, title, Icon, disabled, phoneOnly, selected }) => {
onDisabledClick?: (e: React.MouseEvent<any, MouseEvent>) => any;
}> = ({
onClick,
title,
Icon,
disabled,
phoneOnly,
selected,
onDisabledClick,
}) => {
const { isSmall } = useContext(FormElementLayoutContext).style;
if (phoneOnly && !isSmall) {
return null;
Expand All @@ -204,6 +214,9 @@ const Item: FunctionComponent<{
} ${selected ? "font-semibold " : ""}`}
onClick={(e) => {
if (disabled) {
if (onDisabledClick) {
onDisabledClick(e);
}
e.preventDefault();
e.stopPropagation();
} else {
Expand Down Expand Up @@ -323,6 +336,7 @@ export function Measure(props: MapSettingsActionItem<{}>) {
const { t } = useTranslation("surveys");
const mapContext = useContext(MapContext);
const measureContext = useContext(MeasureControlContext);
const { alert } = useDialog();
return (
<Item
{...props}
Expand All @@ -348,6 +362,13 @@ export function Measure(props: MapSettingsActionItem<{}>) {
></path>
</svg>
)}
onDisabledClick={() => {
alert(
t(
"Finish drawing your shape first. Afterwards you will be able to use the measure tool."
)
);
}}
onClick={() => {
if (measureContext.state === "disabled") {
measureContext.reset();
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/af/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "staaf tans...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "Voordat jy 'n projek skep, moet jy jou e-posadres verifieer. Gaan asseblief jou inkassie na vir 'n verifikasie-e-pos vanaf <2>[email protected]</2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "Deur 'n projek te skep, stem jy in tot ons <2>Gebruiksbepalings</2> en <6>Privaatheidsbeleid</6>.",
"close": "naby",
"Copied!": "Gekopieer!",
"Copy Link": "Kopieer skakel",
"Copy Reference": "Kopieer verwysing",
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/ar/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "مصادقة ...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "قبل إنشاء مشروع ، يجب عليك التحقق من عنوان بريدك الإلكتروني. يرجى التحقق من البريد الوارد بحثًا عن رسالة بريد إلكتروني للتحقق من <2> [email protected] </2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "من خلال إنشاء مشروع ، فإنك توافق على <2> شروط الاستخدام </ 2> و <6> سياسة الخصوصية </ 6>.",
"close": "يغلق",
"Copied!": "نسخ!",
"Copy Link": "نسخ الوصلة",
"Copy Reference": "نسخة المرجع",
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/bg/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "удостоверяване...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "Преди да създадете проект, трябва да потвърдите своя имейл адрес. Моля, проверете входящата си кутия за имейл за потвърждение от <2>[email protected]</2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "Създавайки проект, вие се съгласявате с нашите <2>Условия за ползване</2> и <6>Декларация за поверителност</6>.",
"close": "близо",
"Copied!": "Копирано!",
"Copy Link": "Копирай връзка",
"Copy Reference": "Копиране на справка",
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/da/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "godkender...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "Før du opretter et projekt, skal du bekræfte din e-mailadresse. Tjek venligst din indbakke for en bekræftelses-e-mail fra <2>[email protected]</2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "Ved at oprette et projekt accepterer du vores <2>Brugervilkår</2> og <6>Privatlivspolitik</6>.",
"close": "tæt",
"Copied!": "Kopieret!",
"Copy Link": "Kopier link",
"Copy Reference": "Kopiér reference",
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/de/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "authentifizieren...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "Bevor Sie ein Projekt erstellen, müssen Sie Ihre E-Mail-Adresse bestätigen. Bitte überprüfen Sie Ihren Posteingang auf eine Bestätigungs-E-Mail von <2>[email protected]</2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "Indem Sie ein Projekt erstellen, stimmen Sie unseren <2>Nutzungsbedingungen</2> und unserer <6>Datenschutzerklärung</6> zu.",
"close": "schließen",
"Copied!": "Kopiert!",
"Copy Link": "Link kopieren",
"Copy Reference": "Referenz kopieren",
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/dv/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "އޮތެންޓިކޭޓް ކުރުން...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "ޕްރޮޖެކްޓެއް އުފެއްދުމުގެ ކުރިން އީމެއިލް އެޑްރެސް ވެރިފައި ކުރަން ޖެހެ އެވެ. <2>[email protected]</2 އިން ވެރިފިކޭޝަން އީމެއިލް އަކަށް އިންބޮކްސް ބަލާށެވެ>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "ޕްރޮޖެކްޓެއް އުފައްދައިގެން، އަޅުގަނޑުމެންގެ <2>ޓާރމްސް އޮފް ޔޫސް</2> އަދި <6>ޕްރައިވެސީ ޕޮލިސީ</6> އަށް ތިޔަބޭފުޅުން އެއްބަސްވެވަޑައިގަންނަވަނީ.",
"close": "ކައިރީގައި",
"Copied!": "ކޮޕީކޮށްފައި!",
"Copy Link": "ލިންކް ކޮޕީ ކުރޭ",
"Copy Reference": "ކޮޕީ ރެފަރެންސް",
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/el/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "έλεγχος ταυτότητας...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "Πριν δημιουργήσετε ένα έργο, πρέπει να επαληθεύσετε τη διεύθυνση email σας. Ελέγξτε τα εισερχόμενά σας για ένα μήνυμα ηλεκτρονικού ταχυδρομείου επαλήθευσης από το <2>[email protected]</2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "Δημιουργώντας ένα έργο, συμφωνείτε με τους <2>Όρους Χρήσης</2> και την <6>Πολιτική Απορρήτου</6> μας.",
"close": "Κλείσε",
"Copied!": "Αντιγράφηκε!",
"Copy Link": "Αντιγραφή συνδέσμου",
"Copy Reference": "Αντιγραφή αναφοράς",
Expand Down
2 changes: 2 additions & 0 deletions packages/client/src/lang/en/admin.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"Admins will be given full access to change project settings. They can manage data layers, change access control settings, and moderate the discussion forums.": "Admins will be given full access to change project settings. They can manage data layers, change access control settings, and moderate the discussion forums.",
"Affiliations and Bio": "Affiliations and Bio",
"Always on": "Always on",
"Amount of spatial data that can be uploaded to this project. We limit this amount initially to prevent abuse and to identify important projects.": "Amount of spatial data that can be uploaded to this project. We limit this amount initially to prevent abuse and to identify important projects.",
"Anyone can visit the project and participate. Can only be enabled for <1>listed</1> projects.": "Anyone can visit the project and participate. Can only be enabled for <1>listed</1> projects.",
"Approve": "Approve",
"Approve access": "Approve access",
Expand Down Expand Up @@ -70,6 +71,7 @@
"Create Group": "Create Group",
"Create a thumbnail image that best represents this basemap": "Create a thumbnail image that best represents this basemap",
"Created At": "Created At",
"Data Hosting Quota": "Data Hosting Quota",
"Data Layers": "Data Layers",
"Data Storage Location": "Data Storage Location",
"Data layer administration requires at least a tablet-sized screen.": "Data layer administration requires at least a tablet-sized screen.",
Expand Down
11 changes: 11 additions & 0 deletions packages/client/src/lang/en/admin:data.json
Original file line number Diff line number Diff line change
@@ -1,29 +1,40 @@
{
"Add Data": "Add Data",
"Add Folder": "Add Folder",
"Calculated Tile Count": "Calculated Tile Count",
"Cancel upload": "Cancel upload",
"Check that you uploaded a supported file type. If you would like to <2>contact support</2> about this error, reference upload ID ": "Check that you uploaded a supported file type. If you would like to <2>contact support</2> about this error, reference upload ID ",
"Contact [email protected] to discuss your needs and we may be able to increase your quota.": "Contact [email protected] to discuss your needs and we may be able to increase your quota.",
"Dismiss": "Dismiss",
"Drag and drop spatial data files here to upload.": "Drag and drop spatial data files here to upload.",
"Edit": "Edit",
"Estimated tile package size": "Estimated tile package size",
"Has changes since last publish": "Has changes since last publish",
"Last modified ": "Last modified ",
"Layer Z-Ordering": "Layer Z-Ordering",
"Leaving this page will cancel your spatial data file upload. Are you sure you want to cancel?": "Leaving this page will cancel your spatial data file upload. Are you sure you want to cancel?",
"MapBox fees to generate package (w/o free tier)": "MapBox fees to generate package (w/o free tier)",
"No Tile Packages found. Related maps cannot be used offline until created. <2>Generating tile packages may incure fees from MapBox</2>": "No Tile Packages found. Related maps cannot be used offline until created. <2>Generating tile packages may incure fees from MapBox</2>",
"No changes": "No changes",
"NumGeostatsValues": "{{count}} values",
"NumGeostatsValues_plural": "NumGeostatsValues_plural",
"Provide a MapBox Secret Key in your <2>project settings</2> to enable browsing of maps in your account.": "Provide a MapBox Secret Key in your <2>project settings</2> to enable browsing of maps in your account.",
"Publish": "Publish",
"Required tiling settings": "Required tiling settings",
"Show more": "Show more",
"Style save error - ": "Style save error - ",
"Table of Contents": "Table of Contents",
"The tile package below will be made available for download to users who need to use these maps offline. Make sure the maximum zoom level supported by the existing tile package meets your needs. If not you can generate a new one which will replace it when finished.": "The tile package below will be made available for download to users who need to use these maps offline. Make sure the maximum zoom level supported by the existing tile package meets your needs. If not you can generate a new one which will replace it when finished.",
"Tile Packages": "Tile Packages",
"Upload Data": "Upload Data",
"Upload Failed": "Upload Failed",
"Upload Tasks": "Upload Tasks",
"Upload hosting quotas are designed to prevent abuse": "Upload hosting quotas are designed to prevent abuse",
"Upload spatial data files": "Upload spatial data files",
"Used in": "Used in",
"View": "View",
"Zoom levels": "Zoom levels",
"Zoom to Project Bounds": "Zoom to Project Bounds",
"applying cartography": "applying cartography",
"complete": "complete",
"converting...": "converting...",
Expand Down
15 changes: 14 additions & 1 deletion packages/client/src/lang/en/homepage.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
{
"": "",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.",
"Click on the map to start measuring.": "Click on the map to start measuring.",
"Copied!": "Copied!",
"Copy Link": "Copy Link",
"Copy Reference": "Copy Reference",
"Create an account": "Create an account",
"Create your own SeaSketch project.": "Create your own SeaSketch project.",
"Dismiss": "Dismiss",
"Double-click to finish measuring or click to draw a path.": "Double-click to finish measuring or click to draw a path.",
"Drag points to modify the measured distance.": "Drag points to modify the measured distance.",
"Email sent. Check your inbox 📨": "Email sent. Check your inbox 📨",
"Get started": "Get started",
"Latest Discussions": "Latest Discussions",
Expand All @@ -30,7 +34,16 @@
"SeaSketch puts powerful tools into the hands of ocean planners,\n stakeholders and the public that were once limited to GIS\n professionals, enabling participatory marine spatial planning\n processes that are closely tied to the relevant science and\n information. SeaSketch is being used around the globe in small\n agency teams and large community-driven initiatives to make better\n management decisions every day.": "SeaSketch puts powerful tools into the hands of ocean planners,\n stakeholders and the public that were once limited to GIS\n professionals, enabling participatory marine spatial planning\n processes that are closely tied to the relevant science and\n information. SeaSketch is being used around the globe in small\n agency teams and large community-driven initiatives to make better\n management decisions every day.",
"Sending email...": "Sending email...",
"Sign In": "Sign In",
"Tap again to measure a path, or use the buttons below to finish or start over.": "Tap again to measure a path, or use the buttons below to finish or start over.",
"Tap the map to start measuring.": "Tap the map to start measuring.",
"You are accessing SeaSketch from the beta domain next.seasket.ch. For the best experience, please use <2>www.seasketch.org</2>. If you are using offline features <5>read these instructions</5>.": "You are accessing SeaSketch from the beta domain next.seasket.ch. For the best experience, please use <2>www.seasketch.org</2>. If you are using offline features <5>read these instructions</5>.",
"Zoom to bounds": "Zoom to bounds",
"authenticating...": "authenticating..."
"authenticating...": "authenticating...",
"close": "close",
"finish": "finish",
"kilometers": "kilometers",
"meters": "meters",
"miles": "miles",
"nautical miles": "nautical miles",
"reset": "reset"
}
9 changes: 1 addition & 8 deletions packages/client/src/lang/en/nav.json
Original file line number Diff line number Diff line change
@@ -1,26 +1,19 @@
{
"About": "About",
"Account settings": "Account settings",
"Add data": "Add data",
"Add folder": "Add folder",
"Are you sure you want to delete {{name}}?": "Are you sure you want to delete {{name}}?",
"Contact support": "Contact support",
"Default Visibility": "Default Visibility",
"Delete": "Delete",
"Delete Item": "Delete Item",
"Developer API": "Developer API",
"Edit": "Edit",
"Edit metadata": "Edit metadata",
"Metadata": "Metadata",
"Projects": "Projects",
"Publish": "Publish",
"SeaSketch logo": "SeaSketch logo",
"Sign In": "Sign In",
"Sign in": "Sign in",
"Sign out": "Sign out",
"Signed in as": "Signed in as",
"Tree Editor": "Tree Editor",
"Z-Order": "Z-Order",
"Zoom to bounds": "Zoom to bounds",
"view": "view"
"Zoom to bounds": "Zoom to bounds"
}
1 change: 1 addition & 0 deletions packages/client/src/lang/en/sketching.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"Delete Geometry": "Delete Geometry",
"Edit": "Edit",
"Export as GeoJSON": "Export as GeoJSON",
"Finish using the measurement tool before continuing to sketch.": "Finish using the measurement tool before continuing to sketch.",
"Folder": "Folder",
"Name": "Name",
"New": "New",
Expand Down
3 changes: 3 additions & 0 deletions packages/client/src/lang/en/surveys.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"Basemap": "Basemap",
"Begin": "Begin",
"Cancel": "Cancel",
"Cancel measurement": "Cancel measurement",
"Change choices": "Change choices",
"Close": "Close",
"Complete Submission": "Complete Submission",
Expand All @@ -32,6 +33,7 @@
"Expand Map": "Expand Map",
"Facilitated Response": "Facilitated Response",
"Finish Sector": "Finish Sector",
"Finish drawing your shape first. Afterwards you will be able to use the measure tool.": "Finish drawing your shape first. Afterwards you will be able to use the measure tool.",
"Focus on location": "Focus on location",
"Focus on shapes": "Focus on shapes",
"High": "High",
Expand All @@ -41,6 +43,7 @@
"Invalid shape": "Invalid shape",
"Language": "Language",
"Low": "Low",
"Measure": "Measure",
"New Shape": "New Shape",
"Next": "Next",
"Next Question": "Next Question",
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/es/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "autentificando...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "Antes de crear un proyecto, debe verificar su dirección de correo electrónico. Por favor, busque en su bandeja de entrada un correo electrónico de verificación de <2>[email protected]</2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "Al crear un proyecto, acepta nuestras <2>Condiciones de uso</2> y <6>Política de privacidad</6>.",
"close": "cerrar",
"Copied!": "¡Copiado!",
"Copy Link": "Copiar link",
"Copy Reference": "Copiar referencia",
Expand Down
1 change: 1 addition & 0 deletions packages/client/src/lang/et/homepage.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"authenticating...": "autentimine...",
"Before creating a project, you must verify your email address. Please check your inbox for a verification email from <2>[email protected]</2>": "Enne projekti loomist peate kinnitama oma e-posti aadressi. Kontrollige oma postkasti kinnitusmeili aadressilt <2>[email protected]</2>",
"By creating a project, you are agreeing to our <2>Terms of Use</2> and <6>Privacy Policy</6>.": "Projekti luues nõustute meie <2>kasutustingimuste</2> ja <6>privaatsuseeskirjadega</6>.",
"close": "Sulge",
"Copied!": "Kopeeritud!",
"Copy Link": "Kopeeri link",
"Copy Reference": "Kopeeri viide",
Expand Down
Loading

0 comments on commit 3f76d40

Please sign in to comment.