|
1 |
| -(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}(g.L || (g.L = {})).Routing = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ |
| 1 | +!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),(f.L||(f.L={})).Routing=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ |
2 | 2 | function corslite(url, callback, cors) {
|
3 | 3 | var sent = false;
|
4 | 4 |
|
@@ -1898,6 +1898,56 @@ if (typeof module !== undefined) module.exports = polyline;
|
1898 | 1898 | endPlaceholder: 'Destino'
|
1899 | 1899 | }
|
1900 | 1900 | },
|
| 1901 | + 'sk': { |
| 1902 | + directions: { |
| 1903 | + N: 'sever', |
| 1904 | + NE: 'serverovýchod', |
| 1905 | + E: 'východ', |
| 1906 | + SE: 'juhovýchod', |
| 1907 | + S: 'juh', |
| 1908 | + SW: 'juhozápad', |
| 1909 | + W: 'západ', |
| 1910 | + NW: 'serverozápad' |
| 1911 | + }, |
| 1912 | + instructions: { |
| 1913 | + // instruction, postfix if the road is named |
| 1914 | + 'Head': |
| 1915 | + ['Mierte na {dir}', ' na {road}'], |
| 1916 | + 'Continue': |
| 1917 | + ['Pokračujte na {dir}', ' na {road}'], |
| 1918 | + 'SlightRight': |
| 1919 | + ['Mierne doprava', ' na {road}'], |
| 1920 | + 'Right': |
| 1921 | + ['Doprava', ' na {road}'], |
| 1922 | + 'SharpRight': |
| 1923 | + ['Prudko doprava', ' na {road}'], |
| 1924 | + 'TurnAround': |
| 1925 | + ['Otočte sa'], |
| 1926 | + 'SharpLeft': |
| 1927 | + ['Prudko doľava', ' na {road}'], |
| 1928 | + 'Left': |
| 1929 | + ['Doľava', ' na {road}'], |
| 1930 | + 'SlightLeft': |
| 1931 | + ['Mierne doľava', ' na {road}'], |
| 1932 | + 'WaypointReached': |
| 1933 | + ['Ste v prejazdovom bode.'], |
| 1934 | + 'Roundabout': |
| 1935 | + ['Odbočte na {exitStr} výjazde', ' na {road}'], |
| 1936 | + 'DestinationReached': |
| 1937 | + ['Prišli ste do cieľa.'], |
| 1938 | + }, |
| 1939 | + formatOrder: function(n) { |
| 1940 | + var i = n % 10 - 1, |
| 1941 | + suffix = ['.', '.', '.']; |
| 1942 | + |
| 1943 | + return suffix[i] ? n + suffix[i] : n + '.'; |
| 1944 | + }, |
| 1945 | + ui: { |
| 1946 | + startPlaceholder: 'Začiatok', |
| 1947 | + viaPlaceholder: 'Cez {viaNumber}', |
| 1948 | + endPlaceholder: 'Koniec' |
| 1949 | + } |
| 1950 | + }, |
1901 | 1951 | 'el': {
|
1902 | 1952 | directions: {
|
1903 | 1953 | N: 'βόρεια',
|
@@ -1968,9 +2018,10 @@ if (typeof module !== undefined) module.exports = polyline;
|
1968 | 2018 |
|
1969 | 2019 | L.Routing.OSRM = L.Class.extend({
|
1970 | 2020 | options: {
|
1971 |
| - serviceUrl: '//router.project-osrm.org/viaroute', |
| 2021 | + serviceUrl: 'https://router.project-osrm.org/viaroute', |
1972 | 2022 | timeout: 30 * 1000,
|
1973 |
| - routingOptions: {} |
| 2023 | + routingOptions: {}, |
| 2024 | + polylinePrecision: 6 |
1974 | 2025 | },
|
1975 | 2026 |
|
1976 | 2027 | initialize: function(options) {
|
@@ -2096,7 +2147,7 @@ if (typeof module !== undefined) module.exports = polyline;
|
2096 | 2147 | },
|
2097 | 2148 |
|
2098 | 2149 | _decodePolyline: function(routeGeometry) {
|
2099 |
| - var cs = polyline.decode(routeGeometry, 6), |
| 2150 | + var cs = polyline.decode(routeGeometry, this.options.polylinePrecision), |
2100 | 2151 | result = new Array(cs.length),
|
2101 | 2152 | i;
|
2102 | 2153 | for (i = cs.length - 1; i >= 0; i--) {
|
|
0 commit comments