(${gym.availble_slots === 0 ? i18n('popup_full') : gym.availble_slots === 6 ? i18n('popup_empty') : gym.availble_slots})
';
@@ -3657,13 +3656,13 @@ function getGymPopupContent (gym) {
content += '
';
if (isRaid && !isRaidBattle) {
- content += '
Raid Start: ' + raidBattleDate.toLocaleTimeString(dateTimeLocale) + ' (' + getTimeUntil(raidBattleDate) + ')
';
+ content += `
${i18n('popup_raid_start')}: ` + raidBattleDate.toLocaleTimeString(dateTimeLocale) + ' (' + getTimeUntil(raidBattleDate) + ')
';
}
if (isRaid) {
- content += '
Raid End: ' + raidEndDate.toLocaleTimeString(dateTimeLocale) + ' (' + getTimeUntil(raidEndDate) + ')
';
+ content += `
${i18n('popup_raid_end')}: ${raidEndDate.toLocaleTimeString(dateTimeLocale)} (${getTimeUntil(raidEndDate)})
`;
if (gym.raid_pokemon_id > 0) {
- content += `
Perfect CP: ${getCpAtLevel(gym.raid_pokemon_id, gym.raid_pokemon_form, 20, true)} / Weather: ${getCpAtLevel(gym.raid_pokemon_id, gym.raid_pokemon_form, 25, true)}
`;
- content += `
Worst CP: ${getCpAtLevel(gym.raid_pokemon_id, gym.raid_pokemon_form, 20, false)} / Weather: ${getCpAtLevel(gym.raid_pokemon_id, gym.raid_pokemon_form, 25, false)}
`;
+ content += `
${i18n('popup_perfect_cp')}: ${getCpAtLevel(gym.raid_pokemon_id, gym.raid_pokemon_form, 20, true)} / ${i18n('filters_weather')}: ${getCpAtLevel(gym.raid_pokemon_id, gym.raid_pokemon_form, 25, true)}
`;
+ content += `
${i18n('popup_worst_cp')}: ${getCpAtLevel(gym.raid_pokemon_id, gym.raid_pokemon_form, 20, false)} / ${i18n('filters_weather')}: ${getCpAtLevel(gym.raid_pokemon_id, gym.raid_pokemon_form, 25, false)}
`;
}
}
@@ -3676,10 +3675,10 @@ function getGymPopupContent (gym) {
const updatedDate = new Date(gym.updated * 1000);
const modifiedDate = new Date(gym.last_modified_timestamp * 1000);
if (updatedDate) {
- content += '
Last Updated: ' + updatedDate.toLocaleDateString(dateTimeLocale) + ' ' + updatedDate.toLocaleTimeString(dateTimeLocale) + ' (' + getTimeSince(updatedDate) + ')
';
+ content += `
${i18n('popup_last_updated')}: ${updatedDate.toLocaleDateString(dateTimeLocale)} ${updatedDate.toLocaleTimeString(dateTimeLocale)} (${getTimeSince(updatedDate)})
`;
}
if (modifiedDate) {
- content += '
Last Modified: ' + modifiedDate.toLocaleDateString(dateTimeLocale) + ' ' + modifiedDate.toLocaleTimeString(dateTimeLocale) + ' (' + getTimeSince(modifiedDate) + ')
';
+ content += `
${i18n('popup_last_modified')}: ${modifiedDate.toLocaleDateString(dateTimeLocale)} ${modifiedDate.toLocaleTimeString(dateTimeLocale)} (${getTimeSince(modifiedDate)})
`;
}
content += getNavigation(gym);
return content;
@@ -3687,12 +3686,12 @@ function getGymPopupContent (gym) {
function getCellPopupContent (cell) {
let content = '
';
- content += 'Level ' + cell.level + ' S2 Cell
';
- content += 'Id: ' + cell.id + '
';
+ content += `${i18n('popup_level')} ${cell.level} ${i18n('popup_s2_cell')}
`;
+ content += `${i18n('popup_id')}: ${cell.id}
`;
const updatedDate = new Date(cell.updated * 1000);
- content += 'Last Updated: ' + updatedDate.toLocaleTimeString(dateTimeLocale) + ' (' + getTimeSince(updatedDate) + ')';
+ content += `${i18n('popup_last_updated')}: ${updatedDate.toLocaleTimeString(dateTimeLocale)} (${getTimeSince(updatedDate)})`;
content += '';
return content;
}
@@ -3700,22 +3699,22 @@ function getCellPopupContent (cell) {
function getSubmissionTypeCellPopupContent (cell) {
let content = `
- Level ${cell.level} S2 Cell
- Id: ${cell.id}
- Total Count: ${cell.count}
- Pokestop Count: ${cell.count_pokestops}
- Gym Count: ${cell.count_gyms}
+ ${i18n('popup_level')} ${cell.level} ${i18n('popup_s2_cell')}
+ ${i18n('popup_id')}: ${cell.id}
+ ${i18n('popup_total_count')}: ${cell.count}
+ ${i18n('popup_pokestop_count')}: ${cell.count_pokestops}
+ ${i18n('popup_gym_count')} : ${cell.count_gyms}
`;
const gymThreshold = [2, 6, 20];
if (cell.count_gyms < 3) {
- content += 'Submissions until Gym: ' + (gymThreshold[cell.count_gyms] - cell.count);
+ content += `${i18n('popup_submissions_until_gym')}: (${gymThreshold[cell.count_gyms] - cell.count})`;
} else {
- content += 'Submissions until Gym: Never';
+ content += `${i18n('popup_submissions_until_gym')}: ${i18n('popup_never')}`;
}
if ((cell.count === 1 && cell.count_gyms < 1) || (cell.count === 5 && cell.count_gyms < 2) || (cell.count === 19 && cell.count_gyms < 3)) {
- content += '
Next submission will cause a Gym!';
+ content += `
${i18n('popup_next_submission')}`;
}
content += '';
@@ -3730,34 +3729,34 @@ function degreesToCardinal (d) {
}
function getWeatherPopupContent (weather) {
- const weatherName = weatherTypes[weather.gameplay_condition].name;
- const weatherType = weatherTypes[weather.gameplay_condition].types;
+ const weatherName = i18n(`weather_${weatherTypes[weather.gameplay_condition].name}`);
+ const weatherType = weatherTypes[weather.gameplay_condition].types.map(type => i18n(type));
const weatherTypeIcons = weatherType.map(type => {
return `
`
})
const updatedDate = new Date(weather.updated * 1000);
let extraContent = !showWeatherDetails ? `
` :
- `
Cell ID: ${weather.id}
-
Cell Level: ${weather.level}
-
Lat: ${weather.latitude.toFixed(5)}
-
Lon: ${weather.longitude.toFixed(5)}
-
Gameplay Condition: ${getWeatherName(weather.gameplay_condition)}
-
Wind Direction: ${weather.wind_direction}° (${degreesToCardinal(weather.wind_direction)})
-
Cloud Level: ${weather.cloud_level}
-
Rain Level: ${weather.rain_level}
-
Wind Level: ${weather.wind_level}
-
Snow Level: ${weather.snow_level}
-
Fog Level: ${weather.fog_level}
-
Special Effects Level: ${weather.special_effect_level}
-
Severity: ${weather.severity}
-
Weather Warning: ${weather.warn_weather}
`
+ `
${i18n('popup_cell_id')}: ${weather.id}
+
${i18n('popup_cell_level')}: ${weather.level}
+
${i18n('popup_lat')}: ${weather.latitude.toFixed(5)}
+
${i18n('popup_lon')}: ${weather.longitude.toFixed(5)}
+
${i18n('popup_gameplay_condition')}: ${getWeatherName(weather.gameplay_condition)}
+
${i18n('popup_wind_direction')}: ${weather.wind_direction}° (${degreesToCardinal(weather.wind_direction)})
+
${i18n('popup_cloud')}: ${weather.cloud_level}
+
${i18n('popup_rain')}: ${weather.rain_level}
+
${i18n('popup_wind')}: ${weather.wind_level}
+
${i18n('popup_snow')}: ${weather.snow_level}
+
${i18n('popup_fog')}: ${weather.fog_level}
+
${i18n('popup_special_effects')}: ${weather.special_effect_level}
+
${i18n('popup_severity')}: ${weather.severity}
+
${i18n('popup_warning')}: ${weather.warn_weather}
`
const content = `
- ${weatherName}
- Boosted Types:
${weatherType.join(', ')}
+ ${weatherName}
+ ${i18n('popup_boosted')}:
${weatherType.join(', ')}
${weatherTypeIcons.join(' ')}
${extraContent}
- Last Updated: ${updatedDate.toLocaleTimeString(dateTimeLocale)} (${getTimeSince(updatedDate)})
+ ${i18n('popup_last_updated')}: ${updatedDate.toLocaleTimeString(dateTimeLocale)} (${getTimeSince(updatedDate)})
`;
return content;
}
@@ -3768,13 +3767,13 @@ function getNestPopupContent(nest) {
const content = `
Park: ${nest.name}
- Pokemon: ${pokemonName}
- Average: ${nest.pokemon_avg.toLocaleString()}
- Count: ${nest.pokemon_count.toLocaleString()}
- Last Updated: ${lastUpdated.toLocaleString()}
+ ${i18n('filter_pokemon')}: ${pokemonName}
+ ${i18n('popup_average')}: ${nest.pokemon_avg.toLocaleString()}
+ ${i18n('popup_count')}: ${nest.pokemon_count.toLocaleString()}
+ ${i18n('popup_last_updated')}: ${lastUpdated.toLocaleString()}
- Nest data is estimated
- Verify by checking current spawns
+ ${i18n('popup_nest_data')}
+ ${i18n('popup_verify_by_checking')}
`;
return content;
}
@@ -3789,9 +3788,9 @@ function getPortalPopupContent(portal) {
- Last Updated: ${updated}
+ ${i18n('popup_last_updated')}: ${updated}
-
Date Imported: ${imported}
+
${i18n('popup_date_imported')}: ${imported}
` + getNavigation(portal) + `
`;
return content;
@@ -3811,17 +3810,17 @@ const getNavigation = (data) => {
-
+
|
-
+
|
-
+
|
@@ -4445,7 +4444,7 @@ function getSpawnpointMarker (spawnpoint, ts) {
const hasTimer = spawnpoint.despawn_second !== null;
if (hasTimer) {
const timer = Math.round(spawnpoint.despawn_second / 60);
- content += '
Despawn Timer: ' + timer + ' minutes';
+ content += `
${i18n('popup_despawn_timer')}: ${timer} ${i18n('popup_minutes')}`;
}
const circle = L.circle([spawnpoint.lat, spawnpoint.lon], {
color: hasTimer ? 'green' : 'red',
@@ -4571,13 +4570,13 @@ function getDeviceMarker (device, ts) {
function getDevicePopupContent (device) {
const lastSeenDate = new Date(device.last_seen * 1000);
- const lastSeen = lastSeenDate.toLocaleTimeString(dateTimeLocale) + ' (' + getTimeSince(lastSeenDate) + ')';
+ const lastSeen = `${lastSeenDate.toLocaleTimeString(dateTimeLocale)} (${getTimeSince(lastSeenDate)})`;
const ts = Math.round((new Date()).getTime() / 1000);
const isOffline = isDeviceOffline(device, ts);
- const content = '' + device.uuid + '
' +
- 'Instance: ' + device.instance_name + '
' +
- 'Last Seen: ' + lastSeen + '
' +
- 'Status: ' + (isOffline ? 'Offline' : 'Online');
+ const content = `${device.uuid}
+ ${i18n('popup_instance')}:${device.instance_name}
+ ${i18n('popup_last_seen')}:${lastSeen}
+ ${i18n('popup_status')}:(${isOffline ? i18n('popup_offline') : i18n('popup_online')})`;
return content;
}
@@ -5776,7 +5775,7 @@ function manageIVPopup (id, filter) {
success = true;
} else {
success = false;
- alert('Invalid IV Filter!');
+ alert(`${i18n('popup_invalid_iv_filter')}`);
}
if (!success) {
if (prevShow === true) {
@@ -5804,7 +5803,7 @@ function manageColorPopup (id, filter) {
success = true;
} else {
success = false;
- alert('Invalid color value!');
+ alert(`${i18n('popup_invalid_color_value')}`);
}
if (!success) {
if (prevShow === true) {
@@ -5824,7 +5823,7 @@ function manageGlobalIVPopup (id, filter) {
filter['iv_' + id].filter = result;
return true;
} else {
- alert('Invalid IV Filter!');
+ alert(`${i18n('popup_invalid_iv_filter')}`);
return false;
}
}
@@ -5837,7 +5836,7 @@ function manageGlobalAveragePopup (id, filter) {
filter[id].filter = result;
return true;
} else {
- alert('Invalid Nest Filter!');
+ alert(`${i18n('popup_invalid_nest_filter')}`);
return false;
}
}
@@ -5850,7 +5849,7 @@ function manageGlobalCandyCountPopup (id, filter) {
filter[id].filter = result;
return true;
} else {
- alert('Invalid Quest Filter!');
+ alert(`${i18n('popup_invalid_candy_filter')}`);
return false;
}
}
@@ -5863,7 +5862,7 @@ function manageGlobalStardustCountPopup (id, filter) {
filter[id].filter = result;
return true;
} else {
- alert('Invalid Quest Filter!');
+ alert(`${i18n('popup_invalid_stardust_filter')}`);
return false;
}
}
@@ -5934,11 +5933,11 @@ function getLureIconId (lureId) {
}
function getSize (size) {
- if (size < 1.5) return 'Tiny';
- if (size <= 1.75) return 'Small';
- if (size < 2.25) return 'Normal';
- if (size <= 2.5) return 'Large';
- return 'Big';
+ if (size < 1.5) return i18n('tiny');
+ if (size <= 1.75) return i18n('small');
+ if (size < 2.25) return i18n('normal');
+ if (size <= 2.5) return i18n('large');
+ return i18n('big');
}
function getPokemonIcon(pokemonId, form = 0, evolution = 0, gender = 0, costume = 0, shiny = false) {
diff --git a/static/locales/_en.json b/static/locales/_en.json
index cd188577..89ab9463 100644
--- a/static/locales/_en.json
+++ b/static/locales/_en.json
@@ -5,6 +5,9 @@
"nav_logout": "Logout",
"nav_register": "Register",
"nav_login": "Login",
+ "nav_google_maps": "Open in Google Maps",
+ "nav_apple_maps": "Open in Apple Maps",
+ "nav_waze_maps": "Open in Wave",
"title_profile": "Profile",
"title_login": "Login",
"title_register": "Login",
@@ -83,10 +86,10 @@
"filter_global_avg": "Nest Avg Limit",
"filter_global_candy_count": "Rare Candy Limit",
"filter_global_stardust_count": "Stardust Limit",
- "filter_and": "And",
- "filter_or": "Or",
- "filter_on": "On",
- "filter_off": "Off",
+ "filter_and": "AND",
+ "filter_or": "OR",
+ "filter_on": "ON",
+ "filter_off": "OFF",
"filter_old": "Old",
"filter_new": "New",
"filter_configure": "Configure",
@@ -195,5 +198,157 @@
"prompt_color_value": "Please enter a color value. (i.e. red, blue, green, etc)",
"prompt_nest_avg": "Please enter a nest count average to filter. Example: 5",
"prompt_candy_amount": "Please enter a candy amount to filter. Example: 2",
- "prompt_stardust_amount": "Please enter a stardust amount to filter. Example: 0, 200, 500, 1000, 1500, etc"
-}
\ No newline at end of file
+ "prompt_stardust_amount": "Please enter a stardust amount to filter. Example: 0, 200, 500, 1000, 1500, etc",
+ "popup_slots_available": "Slots Available",
+ "popup_guard": "Guard",
+ "popup_total_cp": "Total CP",
+ "popup_gym_under_attack": "Gym is Under Attack!",
+ "popup_raid_start": "Raid Start",
+ "popup_raid_end": "Raid End",
+ "popup_perfect_cp": "Perfect CP",
+ "popup_worst_cp": "Worst CP",
+ "popup_cp": "CP",
+ "popup_last_updated": "Last Updated",
+ "popup_last_modified": "Last Modified",
+ "popup_level": "Level",
+ "popup_s2_cell": "S2 Cell",
+ "popup_cell_id": "Cell ID",
+ "popup_cell_level": "Cell Level",
+ "popup_id": "ID",
+ "popup_lat": "Lat",
+ "popup_lon": "Lon",
+ "popup_gameplay_condition": "Gameplay Condition",
+ "popup_team": "Team",
+ "popup_gym_last_seen_in_battle": "Gym last seen in battle!",
+ "popup_ex": "EX",
+ "popup_mega": "Mega",
+ "popup_evolution": "Evolution",
+ "popup_fast": "Fast",
+ "popup_charge": "Charge",
+ "popup_unknown_raid_boss": "Unknown Raid Boss",
+ "popup_egg": "Egg",
+ "popup_unknown_gym_name": "Unknown Gym Name",
+ "popup_giovanni": "Giovanni",
+ "popup_exclude_quest": "Exclude Quest",
+ "popup_filter_quest": "Filter Quest",
+ "popup_hide_quest": "Hide Quest",
+ "popup_reward": "Reward",
+ "popup_quest": "Quest",
+ "popup_team_rocket_invasion": "Team Rocket Invasion",
+ "popup_end_time": "End Time",
+ "popup_lure_type": "Lure Type",
+ "popup_lure_end_time": "Lure End Time",
+ "popup_unknown_pokestop_name": "Unknown Pokestop Name",
+ "popup_scan_with_event_account": "Scan with Event Account",
+ "popup_timer": "Timer",
+ "popup_hide": "Hide",
+ "popup_exclude": "Exclude",
+ "popup_theoretical_mega_stat": "Theoretical Mega Stat",
+ "popup_first_last": "First/Last Seen",
+ "popup_last_seen": "Last Seen",
+ "popup_despawn": "Despawn",
+ "popup_lvl": "Lvl",
+ "popup_cp_too_high": "CP Too High",
+ "popup_rank": "Rank",
+ "popup_form": "Form",
+ "popup_count": "Count",
+ "popup_total": "Total",
+ "popup_total_count": "Total Count",
+ "popup_pokestop_count": "Pokestop Count",
+ "popup_gym_count": "Gym Count",
+ "popup_submissions_until_gym": "Submissions Until New Gym",
+ "popup_never": "Never",
+ "popup_next_submission": "Next submission will cause a Gym!",
+ "popup_wind_direction": "Wind Direction",
+ "popup_wind": "Wind Level",
+ "popup_cloud": "Cloud Level",
+ "popup_rain": "Rain Level",
+ "popup_snow": "Snow Level",
+ "popup_fog": "Fog Level",
+ "popup_special_effects": "Special Effects Level",
+ "popup_severity": "Severity",
+ "popup_warning": "Weather Warning",
+ "popup_boosted": "Boosted Types",
+ "popup_park": "Park",
+ "popup_average": "Average",
+ "popup_nest_data": "Nest Data is Estimated",
+ "popup_verify_by_checking": "Verify by Checking Current Spawns",
+ "popup_date_imported": "Date Imported",
+ "popup_despawn_timer": "Despawn Timer",
+ "popup_minutes": "Minutes",
+ "popup_instance": "Instance",
+ "popup_status": "Status",
+ "popup_online": "Online",
+ "popup_offline": "Offline",
+ "popup_invalid_iv_filter": "Invalid IV Filter!",
+ "popup_invalid_color_value": "Invalid Color Value!",
+ "popup_invalid_nest_filter": "Invalid Nest Filter!",
+ "popup_invalid_candy_filter": "Invalid Candy Filter!",
+ "popup_invalid_stardust_filter": "Invalid Stardust Filter!",
+ "tiny": "Tiny",
+ "small": "Small",
+ "normal": "Normal",
+ "large": "Large",
+ "big": "Big",
+ "weather_none": "None",
+ "weather_clear": "Clear",
+ "weather_rain": "Rain",
+ "weather_partly_cloudy": "Partly Cloudy",
+ "weather_cloudy": "Cloudy",
+ "weather_windy": "Windy",
+ "weather_snow": "Snow",
+ "weather_fog": "Fog",
+ "fire": "Fire",
+ "grass": "Grass",
+ "ground": "Ground",
+ "water": "Water",
+ "electric": "Electric",
+ "bug": "Bug",
+ "rock": "Rock",
+ "fairy": "Fairy",
+ "fighting": "Fighting",
+ "poison": "Poison",
+ "dragon": "Dragon",
+ "flying": "Flying",
+ "psychic": "Psychic",
+ "ice": "Ice",
+ "steel": "Steel",
+ "dark": "Dark",
+ "ghost": "Ghost",
+ "common": "Common",
+ "uncommon": "Uncommon",
+ "rare": "Rare",
+ "ultra_rare": "Ultra Rare",
+ "regional": "Regional",
+ "event": "Event",
+ "kanto": "Kanto",
+ "johto": "Johto",
+ "hoenn": "Hoenn",
+ "sinnoh": "Sinnoh",
+ "unova": "Unova",
+ "kalos": "Kalos",
+ "alolan": "Alolan",
+ "galarian": "Galarian",
+ "ways_to_filter": "Ways to Filter",
+ "general_basics": "General Basics",
+ "iv_range": "IV Range",
+ "iv_result": "90-100% IV Pokemon",
+ "level_range": "Level Range",
+ "level_result": "Level 30 to 35 Pokemon",
+ "stats": "Stats",
+ "stats_result": "Pokemon with 0-1 Attack, 14 Defense, & 15 Stamina",
+ "cp_result": "All Pokemon with CP of 2000-3000",
+ "not": "NOT",
+ "not_result": "All Pokemon that do not have their IVs scanned",
+ "pvp": "PVP",
+ "pvp_result": "Pokemon that are rank 1-3 for either Great League OR Ultra League",
+ "stringing_conditions_together": "Stringing Conditions Together",
+ "or": "OR",
+ "or_explanation": "OR operator, for setting separate conditions",
+ "example": "Example",
+ "or_result": "Returns all Pokemon that are either 95-100% IV, L35, OR have a CP of 2500-4000",
+ "and_explanation": "AND operator, for chaining conditions together",
+ "and_result": "All Pokemon with IVs between 80-100, are L25-30, AND have stats of 15/10/10",
+ "advanced": "Advanced",
+ "advanced_result": "Returns all Pokemon that have either CP1400-1500 OR CP2400-2500 AND have 0-1 Attack, 15 Defense, 15 Stamina, OR level 34-35 OR 90-100% IVs OR PVP Great or Ultra league rank between 1-3."
+ }
\ No newline at end of file