dependabot/npm_and_yarn/mathjs-7.5.1
Keith Paterson 3 years ago
parent 1bd3b3b2e4
commit da597f80e4

10
package-lock.json generated

@ -1,6 +1,6 @@
{
"name": "flightgear-airports",
"version": "0.0.30",
"version": "0.0.32",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@ -12331,6 +12331,14 @@
"resolved": "https://registry.npmjs.org/leaflet-rotatedmarker/-/leaflet-rotatedmarker-0.2.0.tgz",
"integrity": "sha1-RGf0n5jRv9VpWb2cZwUgPdJgEnc="
},
"leaflet-search": {
"version": "2.9.9",
"resolved": "https://registry.npmjs.org/leaflet-search/-/leaflet-search-2.9.9.tgz",
"integrity": "sha512-sGPjkMz9gQP+CKrY0G/RjQFWHdt1/KDJQiouv1dWogtN66rcE/aPR/DOduCXM3Um+VgsAmr5+jRQ0iK3Fs9I8A==",
"requires": {
"leaflet": "*"
}
},
"leaflet-sidebar-v2": {
"version": "3.2.1",
"resolved": "https://registry.npmjs.org/leaflet-sidebar-v2/-/leaflet-sidebar-v2-3.2.1.tgz",

@ -106,6 +106,7 @@
"leaflet": "^1.5.1",
"leaflet-editable": "^1.2.0",
"leaflet-polylinedecorator": "^1.6.0",
"leaflet-search": "^2.9.9",
"leaflet-sidebar-v2": "^3.2.1",
"leaflet-textpath": "^1.2.0",
"lokijs": "^1.5.8",

@ -110,6 +110,9 @@ You should have received a copy of the GNU General Public License along with FG
}
},
methods: {
getLayer () {
return this.groundnetLayerGroup;
},
getIdLayerGroup() {
return this.idLayerGroup;
},

@ -53,6 +53,7 @@ You should have received a copy of the GNU General Public License along with FG
<script lang="js">
import 'leaflet/dist/leaflet.css'
import 'leaflet-search/dist/leaflet-search.src.css'
import '@/assets/button.css'
import { LMap, LTileLayer, LMarker, LCircle, LLayerGroup, LControl, LTooltip } from 'vue2-leaflet'
import LeafletSidebar from './LeafletSidebar'
@ -67,6 +68,7 @@ You should have received a copy of the GNU General Public License along with FG
import { Loading } from 'element-ui'
import L from 'leaflet'
import { LeafletSearch } from 'leaflet-search'
// https://github.com/KoRiGaN/Vue2Leaflet/issues/103
delete L.Icon.Default.prototype._getIconUrl
@ -77,7 +79,7 @@ You should have received a copy of the GNU General Public License along with FG
})
export default {
name: 'flightgear-map',
components: { LMap, LTileLayer, LMarker, LCircle, LTooltip, LeafletSidebar, AiLayer, EditBar, ToolBar, EditLayer, TowerLayer, PavementLayer, LLayerGroup, LControl, ThresholdLayer, ToolLayer },
components: { LMap, LTileLayer, LMarker, LCircle, LTooltip, LeafletSidebar, AiLayer, EditBar, ToolBar, EditLayer, TowerLayer, PavementLayer, LLayerGroup, LControl, ThresholdLayer, ToolLayer, LeafletSearch },
props: [],
created () {
this.loadingInstance = null
@ -241,6 +243,16 @@ You should have received a copy of the GNU General Public License along with FG
}
this.$refs.towerLayer.zoomUpdated()
}
if (this.$refs.editLayer !== undefined && this.searchControl === undefined && this.$refs.editLayer.getLayer() === e.layer) {
this.searchControl = new L.Control.Search({
layer: this.$refs.editLayer.getLayer(),
position: 'topleft',
propertyName: 'searchTerm',
marker: {animate: false},
initial: false
})
this.searchControl.addTo(this.$refs.map.mapObject)
}
},
onSelectedPolygon (ring) {
var parkings = this.$refs.editLayer.getParkings(ring)
@ -367,7 +379,7 @@ You should have received a copy of the GNU General Public License along with FG
},
async centerUpdated (center) {
if (center !== this.$store.state.Settings.center) {
this.$store.dispatch('setCenter', center)
this.$store.dispatch('setCenter', {lat: Number(center.lat), lng: Number(center.lng)})
this.$refs.airportLayer.setVisible(this.zoom < 12)
if (this.$refs.thresholdLayer) {
this.$refs.thresholdLayer.setVisible(this.zoom >= 12)

@ -64,7 +64,7 @@
this.searchterm !== undefined &&
this.searchterm.length >= 3 &&
this.searchterm.length <= 4) {
// Not found so it might have been excluded due to no traffic
// Not found so it might have been excluded due to no traffic
this.$store.dispatch('getAirport', this.searchterm)
}
this.lastResult = result

@ -11,7 +11,7 @@ L.HoldNode = L.Marker.extend({
if(this._icon!==null) {
this._icon.childNodes[0].style['background-color'] = 'red';
}
},
},
deselect() {
if(this._icon!==null) {
this._icon.childNodes[0].style['background-color'] = '#4838cc';
@ -31,7 +31,7 @@ L.HoldNode = L.Marker.extend({
this.featureLookup[this.glueindex].push(this);
},
/**
*
*
*/
follow(dragIndex, event) {
@ -61,18 +61,18 @@ L.HoldNode = L.Marker.extend({
element.updateEndVertex(event.latlng);
element.updateMiddle();
}
} else if (element instanceof L.Editable.VertexMarker) {
} else if (element instanceof L.Editable.VertexMarker) {
console.log(element);
element.setLatLng(event.latlng);
element.latlngs.forEach((latlng, index) => {
console.log(latlng);
console.log(latlng);
if(latlng.__vertex === element) {
latlng.update(event.latlng);
}
});
element.editor.feature.setLatLngs(element.latlngs);
element.editor.feature.updateMiddle();
}
}
}
})
}
@ -80,7 +80,7 @@ L.HoldNode = L.Marker.extend({
var holdNode = function (n, layerGroup) {
//console.log(n.attr('lat') + " " + n.attr('lon'));
var latlon = convert(n.attr('lat') + " " + n.attr('lon'));
var latlon = convert(n.attr('lat') + " " + n.attr('lon'));
var fa_icon = null;
if (n.attr('holdPointType') === 'PushBack') {
fa_icon = "<div style='background-color:#4838cc;' class='marker-pin'></div><i class='fas fa-arrows-alt-h'></i>";
@ -93,8 +93,9 @@ var holdNode = function (n, layerGroup) {
iconSize: [30, 42],
iconAnchor: [15, 42]
});
const node = new L.HoldNode([latlon.decimalLatitude, latlon.decimalLongitude], { icon: icon });
const node = new L.HoldNode([latlon.decimalLatitude, latlon.decimalLongitude], { icon: icon });
node.glueindex = n.attr('index');
node.feature = { properties: { searchTerm: n.attr('index')}};
node.holdPointType = n.attr('holdPointType');
node.addTo(layerGroup);
node.addListeners();

@ -442,6 +442,8 @@ var parkingSpot = function (n, layerGroup) {
});
circle.id = n.attr('index');
circle.glueindex = n.attr('index');
circle.feature = { properties: { searchTerm: n.attr('index') + ' ' + n.attr('name')}};
/*
<Parking index="2"
type="gate"

@ -43,18 +43,18 @@ L.RunwayNode = L.Marker.extend({
},
select() {
try {
this._icon.style['color'] = 'red';
this._icon.style['color'] = 'red';
} catch (error) {
console.error(error);
}
},
},
deselect() {
try {
this._icon.style['color'] = 'black';
this._icon.style['color'] = 'black';
} catch (error) {
console.error(error);
}
},
},
extensions: function (editLayer) {
this.options.attributes = {};
if (typeof this.featureLookup[this.glueindex] === 'undefined') {
@ -63,7 +63,7 @@ L.RunwayNode = L.Marker.extend({
this.featureLookup[this.glueindex].push(this);
},
/**
*
*
*/
follow(dragIndex, event) {
@ -93,18 +93,18 @@ L.RunwayNode = L.Marker.extend({
element.updateEndVertex(event.latlng);
element.updateMiddle();
}
} else if (element instanceof L.Editable.VertexMarker) {
} else if (element instanceof L.Editable.VertexMarker) {
console.log(element);
element.setLatLng(event.latlng);
element.latlngs.forEach((latlng, index) => {
console.log(latlng);
console.log(latlng);
if(latlng.__vertex === element) {
latlng.update(event.latlng);
}
});
element.editor.feature.setLatLngs(element.latlngs);
element.editor.feature.updateMiddle();
}
}
}
})
}
@ -120,7 +120,9 @@ var runwayNode = function (n, layerGroup) {
});
var node = new L.RunwayNode([latlon.decimalLatitude, latlon.decimalLongitude], { icon: icon, attributes: {} });
node.glueindex = n.attr('index');
$.each( n.attrs, function( key, value ) {
node.feature = n.attr('index');
$.each( n.attrs, function( key, value ) {
if(isNaN(value))
node.options.attributes[ key ] = value;
else

@ -10,6 +10,7 @@ const extendTaxiSegment = function (taxiwaySegment) {
taxiwaySegment.__proto__.begin;
taxiwaySegment.__proto__.end;
taxiwaySegment.__proto__.bidirectional;
taxiwaySegment.__proto__.updateBeginVertex = function (latlng) {
if (this._latlngs[0].__vertex) {
this._latlngs[0].__vertex.setLatLng(latlng);
@ -244,6 +245,8 @@ const extendTaxiSegment = function (taxiwaySegment) {
polyline.editor.refresh();
//polyline.editor.reset();
polyline.featureLookup = this.featureLookup;
polyline.feature = { properties: {searchTerm: 'Arc ' + nextIndex + '-' + taxiwaySegment.end}};
polyline.options.attributes.name = taxiwaySegment.options.attributes.name;
polyline.options.attributes.direction = taxiwaySegment.options.attributes.direction;
polyline.options.attributes.isPushBackRoute = taxiwaySegment.options.attributes.isPushBackRoute;

@ -14,6 +14,10 @@ Vue.config.productionTip = false
Vue.use(ElementUI)
Vue.config.errorHandler = (err, vm, info) => {
console.error(err)
}
/* eslint-disable no-new */
new Vue({
components: { App },

Loading…
Cancel
Save