"].join("")
}
var f = e._getItemAddressBlock(o.item);
f && (a = f + a), i(null, a)
}), this._offerStore.events.on("renderHouses", function(t, i) {
var r = '
Найдены объявления по адресам: ';
p["default"].each(t.houses, function(t) {
var i = t.params.city.name_ru;
t.params.street && (i += ", " + t.params.street.name_ru), t.params.house_number && (i += " " + t.params.house_number);
var a = t.params.city ? t.params.city.id : "",
n = t.params.street ? t.params.street.id : "",
o = e.similarOfferUrlQuery;
o.query.city = a, o.query.street = n, o.query.house_number = t.params.house_number, o.query && o.query.cluster && delete o.query.cluster;
var s = o.path + "?" + $.param(o.query);
i = '' + i + "", r += i + " "
}), r += "
", i(null, r)
})
}, e.prototype._getItemHeaderBlock = function(e) {
var t = this.$service("OffersSearch").getEntity(e),
i = this._getItemAddress(t);
if (!i && !t.getCommercialObjectTitle()) return "";
var r = '
';
return i && (r += '' + i + ""), t.getCommercialObjectTitle() && (r += '' + t.getCommercialObjectTitle() + ""), r + "
"
}, e.prototype._getItemAddress = function(e) {
var t = [];
return e.has("params.street.name_ru") && t.push(e.param("params.street.name_ru")), !e.has("params.street.name_ru") && e.param("params.city.rank") > 3 && t.push(e.param("params.city.name_ru")), e.has("params.house_number") && t.length && t.push(e.param("params.house_number")), t.join(", ")
}, e.prototype._initMapPlugin = function() {
var e = this;
return new l["default"](function(t, i) {
e._map = new u["default"](e.$els.map, {
layers: {
sputnik: !0
},
layersButton: !0,
fullscreen: !0,
leafletOptions: {
touchZoom: !0,
scrollWheelZoom: !1,
fullscreenControl: !0,
fullscreenPseudo: !0
},
plugins: {
markercluster: !0,
draw: !1
}
}), e._map.init(e.$resource().getConfig("version")).then(function() {
e._map.addOption("zoomFullLoad", 15)
}).then(function() {
return e._initOfferStores()
}).then(function() {
e._mapReady = !0, t()
})["catch"](function(e) {
i(e)
})
})
}, e.prototype._initOfferStores = function() {
var e = this;
return new l["default"](function(t, i) {
var r = ".card-commercial-map-item";
e._offerStore = new g["default"]({
logger: e.$resources().getLogger(),
map: e._map.getOriginalMap(),
vueFilters: e.$options.filters,
services: e.$service(),
popupItemTemplate: e.popupItemTemplates.commercial,
getPhotoUrl: e.$getPhotoUrl,
popupSelector: r
}), e._map.addOption("offerStore", e._offerStore), t()
})
}, e.prototype._initButtons = function() {
var e = this,
t = this.$resource("CookieApi").get(this._mapButtonsName);
t || (t = this._activeButtons), this._overlays.hide("similar"), p["default"].each(t, function(t) {
var i = p["default"].findIndex(e.buttons, function(e) {
return e.name == t
}); - 1 !== i && (e.buttons[i].active = !0, "similar" === t && e._overlays.show("similar"))
})
}, e.prototype._saveActiveButtons = function() {
var e = [];
p["default"].each(this.buttons, function(t) {
t.active && e.push(t.name)
}), this.$resource("CookieApi").set(this._mapButtonsName, e, {
expires: 365
})
}, e.prototype.beforeDestroy = function() {
this._map && this._map.destroy(), p["default"].each(this._checkIntervals, function(e) {
clearInterval(e)
})
}, n(e, [{
key: "address",
get: function() {
var e = this.offer,
t = "";
return e.params.region && (t += " " + e.params.region.name_ru + ","), e.params.city && (t += " " + e.params.city.name_ru), e.params.district && !e.params.house_number && (t += " " + e.params.district.name_ru), e.params.street && (t += " " + e.params.street.name_ru), e.params.house_number && (t += " " + e.params.house_number), t
}
}], [{
key: "styles",
value: i(1451)(o.asset("./styles/card-commercial-map.scss")),
enumerable: !0
}, {
key: "template",
value: i(1451)(o.asset("./templates/card-commercial-map.jade")),
enumerable: !0
}, {
key: "popupItemTemplates",
value: {
commercial: i(1451)(o.asset("./templates/partials/card-commercial-map-item.jade"))
},
enumerable: !0
}, {
key: "props",
value: {
offer: {
"default": function() {
return {}
}
},
mapScreenMode: {
"default": "frame"
}
},
enumerable: !0
}, {
key: "filters",
value: {
getVisible: function(e) {
return Array.isArray(e) ? e.filter(function(e) {
return e.visible
}) : e
}
},
enumerable: !0
}, {
key: "_mapReady",
value: !1,
enumerable: !0
}, {
key: "_checkIntervals",
value: [],
enumerable: !0
}, {
key: "_map",
value: null,
enumerable: !0
}, {
key: "_overlays",
value: null,
enumerable: !0
}, {
key: "_mapButtonsName",
value: "",
enumerable: !0
}, {
key: "_activeButtons",
value: [],
enumerable: !0
}, {
key: "_offerStore",
value: null,
enumerable: !0
}]);
var t = e;
return e = o.ComponentVue(e) || e
}();
t["default"] = M, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
Object.defineProperty(t, "__esModule", {
value: !0
});
var n = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
o = i(117),
s = r(o),
l = function() {
function e(t) {
a(this, e), this._map = t, this._overlays = {}, this._subLayers = {}
}
return n(e, [{
key: "set",
value: function(e) {
this._overlays = e
}
}, {
key: "add",
value: function(e, t, i) {
this._overlays[e] = t, i && (this._subLayers[e] = i)
}
}, {
key: "has",
value: function(e) {
return "undefined" != typeof this._overlays[e]
}
}, {
key: "getVisibleState",
value: function() {
var e = this,
t = {};
return s["default"].each(this._overlays, function(i, r) {
t[r] = !!e._map.hasLayer(i)
}), t
}
}, {
key: "isShown",
value: function(e) {
return this._overlays[e] ? !!this._map.hasLayer(this._overlays[e]) : !1
}
}, {
key: "show",
value: function(e) {
if (this._overlays[e]) {
var t = this._overlays[e];
if (this._map.hasLayer(t) || this._map.addLayer(t), this._subLayers[e] && s["default"].isArray(this._subLayers[e])) {
var i = !0,
r = !1,
a = void 0;
try {
for (var n, o = this._subLayers[e][Symbol.iterator](); !(i = (n = o.next()).done); i = !0) {
var l = n.value;
this._map.hasLayer(l) || (this._map.addOverlayLayer ? this._map.addOverlayLayer(l) : this._map.addLayer(l))
}
} catch (c) {
r = !0, a = c
} finally {
try {
!i && o["return"] && o["return"]()
} finally {
if (r) throw a
}
}
}
}
}
}, {
key: "hide",
value: function(e) {
if (this._overlays[e]) {
var t = this._overlays[e];
if (this._map.hasLayer(t) && this._map.removeLayer(t), this._subLayers[e] && s["default"].isArray(this._subLayers[e])) {
var i = !0,
r = !1,
a = void 0;
try {
for (var n, o = this._subLayers[e][Symbol.iterator](); !(i = (n = o.next()).done); i = !0) {
var l = n.value;
this._map.hasLayer(l) && this._map.removeLayer(l)
}
} catch (c) {
r = !0, a = c
} finally {
try {
!i && o["return"] && o["return"]()
} finally {
if (r) throw a
}
}
}
}
}
}, {
key: "toggle",
value: function(e) {
if (this._overlays[e]) {
var t = this._overlays[e];
this._map.hasLayer(t) ? this.hide(e) : this.show(e)
}
}
}]), e
}();
t["default"] = l
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = i(117),
o = r(n),
s = i(612),
l = r(s),
c = i(1423),
p = r(c),
d = i(15),
u = r(d),
f = function() {
function e(t) {
var i = this;
a(this, e);
var r = ["map", "vueFilters", "services", "getPhotoUrl"];
if (!o["default"].keys(o["default"].pick(t, r)).length) throw new Error("[OfferStore] обязательные options для конструктора: " + r.join(","));
this.events = new p["default"], this._map = t.map, this._vueFilters = t.vueFilters, this._services = t.services, this._getPhotoUrl = t.getPhotoUrl, this._popupSelector = t.popupSelector || ".ymap-offer-item", this._offers = {}, this._count = 0, this._zoomFullLoad = this._map.options.zoomFullLoad, L.Icon.Default.imagePath = "/static/img/leaflet", this._group = L.markerClusterGroup({
clusterType: "offers",
maxClusterRadius: function(e) {
return e >= i._zoomFullLoad ? 20 : 40
},
removeOutsideVisibleBounds: !0,
animateAddingMarkers: !1,
polygonOptions: {
fillColor: "#000"
},
singleMarkerMode: !0,
zoomToBoundsOnClick: !0,
iconCreateFunction: function(e) {
var t, r = e.getChildCount(),
a = "",
n = "";
if (e._zoom && e._zoom >= i._zoomFullLoad) n = "ymap-offer-pin-group", t = new L.Point(40, 40), a = '
' + r + "
";
else {
n = "ymap-offer-pin-cluster", t = {
x: 50,
y: 50
};
var o = String(r).length;
switch (o) {
case 1:
n += " _digit1", t = {
x: 30,
y: 30
};
break;
case 2:
n += " _digit2", t = {
x: 40,
y: 40
};
break;
case 3:
n += " _digit3", t = {
x: 50,
y: 50
};
break;
case 4:
default:
n += " _digit4", t = {
x: 60,
y: 60
}
}
t = new L.Point(t.x, t.y), a = '
' + r + "
"
}
return 1 == r && (a = '', n = "ymap-offer-pin", t = new L.Point(40, 40)), new L.DivIcon({
html: a,
className: n,
iconSize: t
})
}
}), this._group.addTo(this._map), this._map.on("popupopen", function(e) {
var t = $(e.popup._container),
r = $(e.target._container),
a = {
height: r.height(),
width: r.width()
};
e.popup._container.className = e.popup._container.className.replace(/ _reposition-right| _reposition-left| _reposition-bottom/g, "");
var n = i._map.latLngToContainerPoint(e.popup.getLatLng()),
o = {
height: t.height(),
width: t.width(),
offset: {}
};
o.offset.top = function() {
return n.y - o.height
}, o.offset.left = function() {
return n.x - o.width / 2
};
var s = function() {
var t = n.x + o.width / 2 + 8,
r = n.y + o.height / 2,
a = [t, r];
e.popup.setLatLng(i._map.containerPointToLatLng(a)), e.popup._container.className += " _reposition-right"
},
l = function() {
var t = n.x - o.width / 2 - 6,
r = n.y + o.height / 2,
a = [t, r];
e.popup.setLatLng(i._map.containerPointToLatLng(a)), e.popup._container.className += " _reposition-left"
},
c = function() {
var t = n.x,
r = n.y + o.height + 8,
a = [t, r];
e.popup.setLatLng(i._map.containerPointToLatLng(a)), e.popup._container.className += " _reposition-bottom"
};
if (o.offset.left() < 0) return void s();
if (o.offset.left() + o.width > a.width) return void l();
if (o.offset.top() < 0) {
var p = a.height - n.y,
d = n.y,
u = d >= o.height / 2 && p >= o.height / 2;
return u ? o.offset.left() < 0 ? void s() : o.offset.left() + o.width > a.width ? void l() : void(.7 > d / p && c()) : void(.7 > d / p && c())
}
e.popup.setLatLng(i._map.containerPointToLatLng([n.x, n.y - 8]))
})
}
return e.prototype.getLayer = function() {
return this._group
}, e.prototype.addOffers = function(e) {
var t = this;
o["default"].each(e, function(e) {
t.hasOffer(e._id) || t.createMarker(e)
})
}, e.prototype.hasOffer = function(e) {
return !!this._offers[e]
}, e.prototype.getCount = function() {
return this._count
}, e.prototype.getCountInBounds = function() {
var e = 0,
t = this._map.getBounds();
return o["default"].each(this._offers, function(i) {
i.marker && i.marker.getLatLng && t.contains(i.marker.getLatLng()) && e++
}), e
}, e.prototype.getOffer = function(e) {
return this._offers[e] ? this._offers[e] : !1
}, e.prototype.createMarker = function(e) {
var t = this;
if (!e.params || !e.params.location) return !1;
if (!e.params.location.lat || !e.params.location.lat) return !1;
var i = e._id;
this._offers[i] = this.createOfferBlank(e._id, [e.params.location.lat, e.params.location.lon]);
var r = this,
a = function(e) {
if (e.target.options.id) {
var i = e.target.options.id,
a = r.getOffer(i);
if (a) return a.popup ? ("mouseover" == e.type && a.marker.openPopup(), void setTimeout(function() {
r.initPopupBehaviour(e)
}, 0)) : void r.getOfferInfo(i, function(i, n) {
if (!i) {
var o = r.buildOfferViewData(n),
s = {
offerView: o
};
t.events.emit("renderCard", s, function(t, i) {
a.popup = L.popup({
closeButton: !1,
autoPan: !1,
minWidth: 200,
maxWidth: 400
}).setContent(i), a.marker.bindPopup(a.popup).openPopup(), r.bindPopupClose(e), r.initPopupBehaviour(e)
})
}
})
}
};
return this._offers[i].marker = L.marker(this._offers[i].location, {
id: i,
params: e.params
}).addTo(this._group).on("click", function(e) {
var i = e.target.options.id;
t.events.emit("openCard", i)
}).on("mouseover", function(e) {
e.target.options.timeout = setTimeout(function() {
delete e.target.options.timeout, a(e)
}, 150)
}).on("mouseout", function(e) {
return !e.target._map.hasLayer(e.target._popup) && e.target.options.timeout ? void clearTimeout(e.target.options.timeout) : void delete e.target.options.timeout
}), this._count++, this._offers[i]
}, e.prototype.bindPopupClose = function(e) {
var t = e.target._popup._container;
$(t).on("mouseleave.custom", function() {
setTimeout(function() {
e.target.closePopup()
}, 0)
})
}, e.prototype.initPopupBehaviour = function(e) {
var t = this;
if (e.target._popup)
for (var i = e.target._popup._contentNode, r = i.querySelectorAll(this._popupSelector), a = 0; a < r.length; a++) ! function(e, i) {
$(e).off("click").on("click", function() {
var e = this.getAttribute("data-id");
t.events.emit("openCard", e)
})
}(r[a])
}, e.prototype.getOfferViewData = function(e, t) {
var i = this;
this.getOfferInfo(e, function(e, r) {
return e ? void t(e) : void t(null, i.buildOfferViewData(r))
})
}, e.prototype.getOfferViewDataBulk = function(e) {
var t = this;
return new u["default"](function(i, r) {
var a = [];
if (o["default"].each(e, function(e) {
var i = t.getOffer(e);
i.info || a.push(e)
}), 0 == a.length) {
var n = [];
return o["default"].each(e, function(e) {
var i = t.getOffer(e);
n.push(t.buildOfferViewData(i.info))
}), void i(n)
}
var s = t._services.getOffersSearch().getQuery({
query: [{
ids: a
}]
});
t._services.getOffersSearch().search(s).then(function(r) {
var a = [];
r.result && (o["default"].each(r.result, function(e) {
var i = t.getOffer(e.id);
i.info = e
}), o["default"].each(e, function(e) {
var i = t.getOffer(e);
a.push(t.buildOfferViewData(i.info))
})), i(a)
})["catch"](function(e) {
r(e)
})
})
}, e.prototype.buildOfferViewData = function(e) {
var t = new Vue({
data: {
offer: null
},
filters: this._vueFilters
}),
i = "";
e.photos && e.photos.length && this._getPhotoUrl && (i = this._getPhotoUrl(e.photos[0].url_mask, 80, 60, !0));
var r = [],
a = [];
"commercial" === e.rubric ? (o["default"].get(e, "params.type.title") && r.push(e.params.type.title), a = ["{{offer.params.total_area | divide 100 | floor | ifEmpty ''}}"]) : (r = l["default"](e), a = ["{{offer.params.total_area | divide 100 | floor | ifEmpty '-'}} / ", "{{offer.params.living_area | divide 100 | floor| ifEmpty '-'}} / ", "{{offer.params.kitchen_area | divide 100 | floor | ifEmpty '-'}}"]), t.offer = e;
var n = {
id: e.id,
item: e,
photo: i,
price: t.$interpolate("{{offer.params.price | spaces}}"),
price_short: String((e.params.price / 1e6).toFixed(1)).replace(".", ","),
price_per_sqm: t.$interpolate("{{offer.params.price_per_sqm | spaces}}"),
rent_period: e.params.rent_period,
header: r,
area: t.$interpolate(a.join("")),
floors: t.$interpolate("{{offer.params.floor}} / {{offer.params.floors_count}} эт.")
};
return n
}, e.prototype.getGroupPopupContent = function(e, t) {
var i = this,
r = e.reduce(function(e, t, r) {
var a = o["default"].get(t, "options.id"),
n = o["default"].get(i.getOffer(a), "info.house_id", "unknown_" + r),
s = o["default"].get(t, "options.params"),
l = o["default"].get(s, "city.id", "unknown_" + r),
c = o["default"].get(s, "street.id", "unknown_" + r),
p = o["default"].get(s, "house_addresses[0].house_number") || o["default"].get(s, "house_number", "unknown_" + r),
d = l + "_" + c + "_" + p,
u = o["default"].find(e, function(e) {
return e.key == d || e.id == n
});
return u ? (u.count++, e) : (e.push({
count: 1,
id: n,
key: d,
params: s
}), e)
}, []);
if (r.length > 1) this.events.emit("renderHouses", {
houses: r
}, function(e, i) {
t(null, {
type: "houses",
html: i
})
});
else {
var a = function() {
var r = 3,
a = o["default"].pluck(e, "options.id").slice(0, r);
if (!a) return t(null, null), {
v: void 0
};
var n = e.length,
s = n > r;
i.getOfferViewDataBulk(a).then(function(e) {
var r = {
offerViews: e,
count: n,
linkMore: s
};
i.events.emit("renderCards", r, function(e, i) {
t(null, {
type: "offers",
html: i,
ids: a
})
})
})["catch"](function(e) {
t(e)
})
}();
if ("object" == typeof a) return a.v
}
}, e.prototype.getOfferInfo = function(e, t) {
var i = this,
r = this,
a = r.getOffer(e);
if (a.info) return void t(null, a.info);
var n = this._services.getOffersSearch().getQuery({
id: e
});
this._services.getOffersSearch().get(n).then(function(e) {
a || (a = i.createMarker(e.result)), a.info = e.result, t(null, a.info)
})["catch"](function(e) {
t(e)
})
}, e.prototype.createOfferBlank = function(e, t) {
return {
id: e,
location: t,
info: null,
view: null,
marker: null,
popup: null
}
}, e.prototype.clear = function() {
this._offers = {}, this._count = 0, this._group.clearLayers()
}, e.prototype.clearByBounds = function() {
var e = this,
t = this._map.getBounds();
t = t.pad(.5);
var i = 0;
o["default"].each(this._offers, function(r) {
t.contains(r.marker.getLatLng()) || (e._group.removeLayer(r.marker), e._count--, delete e._offers[r.id], i++)
})
}, e
}();
t["default"] = f, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
var r, a, n, o, s, l, c, p = i(1424),
d = i(1437),
u = Function.prototype.apply,
f = Function.prototype.call,
m = Object.create,
h = Object.defineProperty,
g = Object.defineProperties,
_ = Object.prototype.hasOwnProperty,
y = {
configurable: !0,
enumerable: !1,
writable: !0
};
r = function(e, t) {
var i;
return d(t), _.call(this, "__ee__") ? i = this.__ee__ : (i = y.value = m(null), h(this, "__ee__", y), y.value = null), i[e] ? "object" == typeof i[e] ? i[e].push(t) : i[e] = [i[e], t] : i[e] = t, this
}, a = function(e, t) {
var i, a;
return d(t), a = this, r.call(this, e, i = function() {
n.call(a, e, i), u.call(t, this, arguments)
}), i.__eeOnceListener__ = t, this
}, n = function(e, t) {
var i, r, a, n;
if (d(t), !_.call(this, "__ee__")) return this;
if (i = this.__ee__, !i[e]) return this;
if (r = i[e], "object" == typeof r)
for (n = 0; a = r[n]; ++n) a !== t && a.__eeOnceListener__ !== t || (2 === r.length ? i[e] = r[n ? 0 : 1] : r.splice(n, 1));
else r !== t && r.__eeOnceListener__ !== t || delete i[e];
return this
}, o = function(e) {
var t, i, r, a, n;
if (_.call(this, "__ee__") && (a = this.__ee__[e]))
if ("object" == typeof a) {
for (i = arguments.length, n = new Array(i - 1), t = 1; i > t; ++t) n[t - 1] = arguments[t];
for (a = a.slice(), t = 0; r = a[t]; ++t) u.call(r, this, n)
} else switch (arguments.length) {
case 1:
f.call(a, this);
break;
case 2:
f.call(a, this, arguments[1]);
break;
case 3:
f.call(a, this, arguments[1], arguments[2]);
break;
default:
for (i = arguments.length, n = new Array(i - 1), t = 1; i > t; ++t) n[t - 1] = arguments[t];
u.call(a, this, n)
}
}, s = {
on: r,
once: a,
off: n,
emit: o
}, l = {
on: p(r),
once: p(a),
off: p(n),
emit: p(o)
}, c = g({}, l), e.exports = t = function(e) {
return null == e ? m(c) : g(Object(e), l)
}, t.methods = s
}, function(e, t, i) {
"use strict";
var r, a = i(1425),
n = i(1432),
o = i(1433),
s = i(1434);
r = e.exports = function(e, t) {
var i, r, o, l, c;
return arguments.length < 2 || "string" != typeof e ? (l = t, t = e, e = null) : l = arguments[2], null == e ? (i = o = !0, r = !1) : (i = s.call(e, "c"), r = s.call(e, "e"), o = s.call(e, "w")), c = {
value: t,
configurable: i,
enumerable: r,
writable: o
}, l ? a(n(l), c) : c
}, r.gs = function(e, t, i) {
var r, l, c, p;
return "string" != typeof e ? (c = i, i = t, t = e, e = null) : c = arguments[3], null == t ? t = void 0 : o(t) ? null == i ? i = void 0 : o(i) || (c = i, i = void 0) : (c = t, t = i = void 0), null == e ? (r = !0, l = !1) : (r = s.call(e, "c"), l = s.call(e, "e")), p = {
get: t,
set: i,
configurable: r,
enumerable: l
}, c ? a(n(c), p) : p
}
}, function(e, t, i) {
"use strict";
e.exports = i(1426)() ? Object.assign : i(1427)
}, function(e, t) {
"use strict";
e.exports = function() {
var e, t = Object.assign;
return "function" != typeof t ? !1 : (e = {
foo: "raz"
}, t(e, {
bar: "dwa"
}, {
trzy: "trzy"
}), e.foo + e.bar + e.trzy === "razdwatrzy")
}
}, function(e, t, i) {
"use strict";
var r = i(1428),
a = i(1431),
n = Math.max;
e.exports = function(e, t) {
var i, o, s, l = n(arguments.length, 2);
for (e = Object(a(e)), s = function(r) {
try {
e[r] = t[r]
} catch (a) {
i || (i = a)
}
}, o = 1; l > o; ++o) t = arguments[o], r(t).forEach(s);
if (void 0 !== i) throw i;
return e
}
}, function(e, t, i) {
"use strict";
e.exports = i(1429)() ? Object.keys : i(1430)
}, function(e, t) {
"use strict";
e.exports = function() {
try {
return Object.keys("primitive"), !0
} catch (e) {
return !1
}
}
}, function(e, t) {
"use strict";
var i = Object.keys;
e.exports = function(e) {
return i(null == e ? e : Object(e))
}
}, function(e, t) {
"use strict";
e.exports = function(e) {
if (null == e) throw new TypeError("Cannot use null or undefined");
return e
}
}, function(e, t) {
"use strict";
var i = Array.prototype.forEach,
r = Object.create,
a = function(e, t) {
var i;
for (i in e) t[i] = e[i]
};
e.exports = function(e) {
var t = r(null);
return i.call(arguments, function(e) {
null != e && a(Object(e), t)
}), t
}
}, function(e, t) {
"use strict";
e.exports = function(e) {
return "function" == typeof e
}
}, function(e, t, i) {
"use strict";
e.exports = i(1435)() ? String.prototype.contains : i(1436)
}, function(e, t) {
"use strict";
var i = "razdwatrzy";
e.exports = function() {
return "function" != typeof i.contains ? !1 : i.contains("dwa") === !0 && i.contains("foo") === !1
}
}, function(e, t) {
"use strict";
var i = String.prototype.indexOf;
e.exports = function(e) {
return i.call(this, e, arguments[1]) > -1
}
}, function(e, t) {
"use strict";
e.exports = function(e) {
if ("function" != typeof e) throw new TypeError(e + " is not a function");
return e
}
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
Object.defineProperty(t, "__esModule", {
value: !0
});
var a = i(1439),
n = r(a);
t["default"] = n["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
Object.defineProperty(t, "__esModule", {
value: !0
});
var n = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
o = i(1440),
s = r(o),
l = i(1441),
c = r(l),
p = i(1442),
d = r(p),
u = i(1443),
f = r(u),
m = i(1444),
h = r(m),
g = i(1445),
_ = r(g),
y = i(1423),
b = r(y),
v = i(1446),
x = r(v),
w = i(1449),
M = function() {
function e(t, i) {
a(this, e);
var r = {
key: "rukgmi5124",
DialogClass: null,
ButtonClass: null,
resolveIfNoProject: !0
};
this._config = (0, _["default"])(r, i), this.DialogClass = this._config.DialogClass, this.ButtonClass = this._config.ButtonClass, this._events = new b["default"], this._map = t.map, this._loaded = !1, this._firms = {}, this._firmsByType = {}, this._count = 0, this._container = null, this._overlay = L.markerClusterGroup({
clusterType: "infrastructure",
maxClusterRadius: 1,
removeOutsideVisibleBounds: !0,
animateAddingMarkers: !1,
polygonOptions: {
fillColor: "#000"
},
singleMarkerMode: !0,
zoomToBoundsOnClick: !0,
iconCreateFunction: function(e) {
var t, i, r = e.getChildCount(),
a = e.getAllChildMarkers(),
n = "",
o = "_infrastructure";
if (1 == r) i = (0, s["default"])(a, "0.options.type"), n = '', o = "_infrastructure", t = new L.Point(18, 18);
else {
o = "_infrastructure", t = {
x: 0,
y: 18
};
var l = {};
(0, c["default"])(a, function(e) {
l[e.options.type] || (l[e.options.type] = e.options.firm)
}), n = "", (0, c["default"])(l, function(e, i) {
n += '', t.x += 18
}), e.options.firms = l, t = new L.Point(t.x, t.y)
}
return new L.DivIcon({
html: n,
className: o,
iconSize: t
})
}
}), this._overlay.addTo(this._map), this._allTypesVisible = !1, this._types = this._config.types, this._rubricTypeIndex = {}, this._loader = new x["default"]({
key: this._config.key,
cacheCatalogApi: this._config.cacheCatalogApi
}, this._map.projectDetector.getProject(), this._types), this._init(), this._copyrightShown = !1, this._copyrightText = '\n Лицензионное соглашение\n \n '
}
return n(e, [{
key: "onInfrastructureToggle",
value: function(e) {
this._events.on("infrastructureToggle", e)
}
}, {
key: "isLoaded",
value: function() {
return this._loaded
}
}, {
key: "getVisibleState",
value: function() {
var e = {};
return (0, c["default"])(this._types, function(t, i) {
e[i] = t.visible
}), e
}
}, {
key: "getVisibleTypes",
value: function() {
var e = [];
return (0, c["default"])(this._types, function(t, i) {
t.visible && e.push(i)
}), e
}
}, {
key: "isAllShown",
value: function() {
var e = !0;
return (0, c["default"])(this._types, function(t) {
return t.visible ? void 0 : (e = !1, !1)
}), e
}
}, {
key: "isAnythingShown",
value: function() {
var e = !1;
return (0, c["default"])(this._types, function(t) {
return t.visible ? (e = !0, !1) : void 0
}), e
}
}, {
key: "showAll",
value: function() {
var e = this;
(0, c["default"])(this._types, function(t, i) {
e._types[i].visible = !0, e.show(i)
})
}
}, {
key: "hideAll",
value: function() {
var e = this;
(0, c["default"])(this._types, function(t, i) {
e._types[i].visible = !1, e.hide(i)
})
}
}, {
key: "toggleType",
value: function(e) {
"undefined" != typeof this._types[e] && (this._types[e].visible ? this.hide(e) : this.show(e))
}
}, {
key: "show",
value: function(e) {
var t = this;
return (0, d["default"])(e) ? void(0, c["default"])(e, function(e) {
t.show(e)
}) : void("undefined" != typeof this._types[e] && (this._types[e].visible = !0, this._firmsByType[e] && (0, c["default"])(this._firmsByType[e], function(e, i) {
t._events.emit("showFirm", i)
})))
}
}, {
key: "hide",
value: function(e) {
var t = this;
return (0, d["default"])(e) ? void(0, c["default"])(e, function(e) {
t.hide(e)
}) : void("undefined" != typeof this._types[e] && (this._types[e].visible = !1, this._firmsByType[e] && (0, c["default"])(this._firmsByType[e], function(e, i) {
t._events.emit("hideFirm", i)
})))
}
}, {
key: "loadInPointRadius",
value: function(e, t) {
var i = this;
return new Promise(function(r, a) {
i.clear(), i._setGisProjectToLoader().then(function() {
return i._loader.loadInPointRadius(e)
}).then(function(e) {
i._processFirms(e, t), i._loaded = !0, r((0, f["default"])(i._firmsByType))
})["catch"](function(e) {
return i.isNoProjectError(e) && i._config.resolveIfNoProject === !0 ? r([]) : e instanceof w.LoaderError && e.code ? void([w.LoaderErrorCodes.NO_PROJECT].indexOf(e.code) > -1 ? r([]) : a(e)) : a(e)
})
})
}
}, {
key: "loadInBounds",
value: function(e, t) {
var i = this;
return new Promise(function(r, a) {
var n = {};
if (n.point1 = e.top_left.join(","), n.point2 = e.bottom_right.join(","), !t.types) return void r(null);
var o = {
bounds: n,
limit: 15,
types: t.types
};
t.limit && (o.limit = t.limit), i._loader.loadInBounds(o).then(function(e) {
i._processFirms(e, t), r()
})["catch"](function(e) {
return i.isNoProjectError(e) && i._config.resolveIfNoProject === !0 ? r([]) : e instanceof w.LoaderError && e.code ? void([w.LoaderErrorCodes.NO_PROJECT].indexOf(e.code) > -1 ? r([]) : a(e)) : a(e)
})
})
}
}, {
key: "clear",
value: function() {
this._loaded = !1, this._overlay.clearLayers(), this._firms = {}, this._firmsByType = {}, this._count = 0
}
}, {
key: "getCount",
value: function() {
return this._count
}
}, {
key: "getDetailedCount",
value: function() {
var e = 0,
t = {};
return (0, c["default"])(this._firmsByType, function(i, r) {
t[r] = (0, f["default"])(i).length, e += t[r]
}), t.total = e, t
}
}, {
key: "getTypeCount",
value: function(e) {
if (this._firmsByType[e]) {
var t = (0, f["default"])(this._firmsByType[e]).length;
return t
}
return 0
}
}, {
key: "getPopupContent",
value: function(e, t) {
var i, r = '
';
if (e.options.firm) i = [e.options.firm];
else {
if (!e.options.firms) return;
i = e.options.firms
}(0, c["default"])(i, function(e, t) {
r += '
"
}, function(e, t, i) {
"use strict";
function r(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var a = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
n = i(145),
o = function() {
function e() {
r(this, t)
}
a(e, null, [{
key: "template",
value: i(1544)(n.asset("./templates/tip.jade")),
enumerable: !0
}, {
key: "styles",
value: i(1544)(n.asset("./styles/tip.scss")),
enumerable: !0
}, {
key: "props",
value: {
position: {
"default": "_top"
},
alignment: {
"default": "_center"
},
skin: {
"default": "_dark"
},
iconDecorator: {
"default": "_dark"
},
title: {
"default": ""
},
text: {
"default": ""
},
width: null
},
enumerable: !0
}]);
var t = e;
return e = n.ComponentVue(e) || e
}();
t["default"] = o, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./Tip": 1543,
"./Tip.js": 1543,
"./styles/tip.scss": 1545,
"./templates/tip.jade": 1547
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1544
}, function(e, t, i) {
var r = i(1546);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, '.widget-tip{display:inline-block;position:relative;z-index:99;vertical-align:top;margin:0 0 0 4px;white-space:nowrap;text-decoration:none;cursor:pointer}.widget-tip .widget-tip__title,.widget-tip:visited .widget-tip__title{transition:color .2s linear,border-color .2s linear}.widget-tip:focus .widget-tip__title,.widget-tip:hover .widget-tip__title{transition:none}.widget-tip .widget-tip__title{color:#0168bb;border-bottom:1px dotted #0168bb;border-bottom:none}.widget-tip:visited .widget-tip__title{color:#0168bb;border-bottom:1px dotted #0168bb}.widget-tip:focus .widget-tip__title,.widget-tip:hover .widget-tip__title{color:#c03c40;border-bottom:1px dotted #c03c40}.widget-tip__icon{position:relative;z-index:100;top:-2px;margin:0}.widget-tip__icon._dark{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0}.widget-tip__icon._dark:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:.5;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwYXRoIGZpbGw9IiMyMzFGMjAiIGQ9Ik0xMCwyYy00LjQxOCwwLTgsMy41ODItOCw4YzAsNC40MTgsMy41ODIsOCw4LDhjNC40MTgsMCw4LTMuNTgyLDgtOEMxOCw1LjU4MiwxNC40MTgsMiwxMCwyeiBNMTAuNzgyLDE0Ljg5OGMtMC4yMiwwLjIxNC0wLjQ4NCwwLjMyMi0wLjc5MywwLjMyMmMtMC4zMDcsMC0wLjU3NC0wLjEwNS0wLjc5OS0wLjMxNmMtMC4yMjUtMC4yMS0wLjMzNy0wLjQ2NS0wLjMzNy0wLjc2M2MwLTAuMjk5LDAuMTEtMC41NTUsMC4zMzEtMC43N2MwLjIyMS0wLjIxNSwwLjQ4NC0wLjMyNCwwLjc5Mi0wLjMyNGMwLjMwOSwwLDAuNTc1LDAuMTA1LDAuNzk5LDAuMzE1YzAuMjI1LDAuMjEyLDAuMzM4LDAuNDY1LDAuMzM4LDAuNzY0QzExLjExMiwxNC40MjQsMTEuMDAyLDE0LjY4NCwxMC43ODIsMTQuODk4eiBNMTIuNTQ3LDkuMzg3Yy0wLjE4OCwwLjIzNS0wLjMzNCwwLjQwMi0wLjQzMiwwLjVzLTAuMjM5LDAuMjIzLTAuNCwwLjM3NGMtMC4xNjEsMC4xNTItMC4zMTksMC4yODQtMC40MzMsMC4zOTZjLTAuMTEzLDAuMTEyLTAuMjQ3LDAuMjA4LTAuMzE0LDAuMjg2Yy0wLjE3NywwLjIxNS0wLjM1MiwwLjUxOS0wLjM1MiwwLjkxdjAuNTAzSDkuNDA3di0wLjczOWMwLTAuMzktMC4wOTEtMC42OCwwLjAwMS0wLjg3MWMwLjA5NC0wLjE5LDAuMTU5LTAuNDQyLDAuNDcyLTAuNzU1bDEuMDcxLTEuMDdjMC4yMjYtMC4yNDUsMC4zMzgtMC41NDUsMC4zMzgtMC45MDZzLTAuMTE3LTAuNjU2LTAuMzUzLTAuODk1Yy0wLjIzNC0wLjI0MS0wLjUzNy0wLjM0Ni0wLjkxLTAuMzQ2Yy0wLjM3MiwwLTAuNjgyLDAuMTQ0LTAuOTMyLDAuMzc0Yy0wLjI1LDAuMjI5LTAuMzk0LDAuMzctMC40MzMsMC45NzVINi44ODZjMC4wOTktMS4yMSwwLjQzOS0xLjYxMSwxLjAyMS0yLjEwNGMwLjU4Mi0wLjQ5NCwxLjMwOS0wLjc5OCwyLjE3OS0wLjc5OGMwLjg3MSwwLDEuNTgsMC4yMzcsMi4xMjcsMC43MWMwLjU0OCwwLjQ3NSwwLjgyLDEuMTM4LDAuODIsMS45ODlDMTMuMDMzLDguNTA2LDEyLjg2OSw4Ljk5NiwxMi41NDcsOS4zODd6Ii8+PC9zdmc+)}.widget-tip__icon._light{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0}.widget-tip__icon._light:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwYXRoIGZpbGw9IiNGRkZGRkYiIGQ9Ik0xMCwyYy00LjQxOCwwLTgsMy41ODItOCw4czMuNTgyLDgsOCw4czgtMy41ODIsOC04UzE0LjQxOCwyLDEwLDJ6IE0xMC43ODIsMTQuODk4Yy0wLjIyLDAuMjEzLTAuNDg0LDAuMzIyLTAuNzkzLDAuMzIyYy0wLjMwNywwLTAuNTc0LTAuMTA1LTAuNzk5LTAuMzE2cy0wLjMzNy0wLjQ2NS0wLjMzNy0wLjc2NHMwLjExLTAuNTU1LDAuMzMxLTAuNzdjMC4yMjEtMC4yMTUsMC40ODQtMC4zMjQsMC43OTItMC4zMjRjMC4zMDksMCwwLjU3NSwwLjEwNSwwLjc5OSwwLjMxNGMwLjIyNSwwLjIxMywwLjMzOCwwLjQ2NiwwLjMzOCwwLjc2NUMxMS4xMTEsMTQuNDI0LDExLjAwMiwxNC42ODQsMTAuNzgyLDE0Ljg5OHogTTEyLjU0Nyw5LjM4N2MtMC4xODgsMC4yMzUtMC4zMzQsMC40MDItMC40MzIsMC41Yy0wLjA5OCwwLjA5OC0wLjIzOSwwLjIyMy0wLjQsMC4zNzRjLTAuMTYsMC4xNTItMC4zMTgsMC4yODQtMC40MzMsMC4zOTZjLTAuMTEzLDAuMTEyLTAuMjQ3LDAuMjA4LTAuMzE0LDAuMjg2Yy0wLjE3NywwLjIxNS0wLjM1MiwwLjUxOS0wLjM1MiwwLjkxdjAuNTAySDkuNDA3di0wLjczOGMwLTAuMzkxLTAuMDkxLTAuNjgsMC4wMDEtMC44NzFjMC4wOTQtMC4xODksMC4xNTktMC40NDIsMC40NzItMC43NTVsMS4wNzEtMS4wN2MwLjIyNi0wLjI0NSwwLjMzOC0wLjU0NSwwLjMzOC0wLjkwNmMwLTAuMzYxLTAuMTE3LTAuNjU2LTAuMzU0LTAuODk1Yy0wLjIzMy0wLjI0MS0wLjUzNy0wLjM0Ni0wLjkxLTAuMzQ2Yy0wLjM3MiwwLTAuNjgyLDAuMTQ0LTAuOTMyLDAuMzc0QzguODQ0LDcuMzc3LDguNyw3LjUxOCw4LjY2MSw4LjEyM0g2Ljg4NmMwLjA5OS0xLjIxLDAuNDM5LTEuNjExLDEuMDIxLTIuMTA0YzAuNTgyLTAuNDk0LDEuMzA5LTAuNzk4LDIuMTc5LTAuNzk4YzAuODcxLDAsMS41OCwwLjIzNywyLjEyNywwLjcxYzAuNTQ4LDAuNDc1LDAuODIsMS4xMzgsMC44MiwxLjk4OUMxMy4wMzMsOC41MDYsMTIuODY5LDguOTk2LDEyLjU0Nyw5LjM4N3oiLz48L3N2Zz4=)}.widget-tip__title{font-size:15px;margin-left:6px}.widget-tip__content,.widget-tip__title{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;line-height:18px;color:#000}.widget-tip__content{font-size:13px;position:absolute;z-index:101;box-sizing:border-box;padding:0;height:0;white-space:normal;overflow:hidden;opacity:0;cursor:default}.widget-tip__content:after,.widget-tip__content:before{content:"";position:absolute;border-left:8px solid transparent;border-right:8px solid transparent}.widget-tip__content:before{border-bottom:6px solid transparent}.widget-tip__content:after{border-top:6px solid transparent}.widget-tip._top .widget-tip__content{bottom:80%;margin-bottom:8px}.widget-tip._top .widget-tip__content:before{display:none}.widget-tip._top._center .widget-tip__content:after{left:50%;bottom:0;margin:0 0 -6px -8px}.widget-tip._top._right .widget-tip__content:after{left:100%;bottom:0;margin:0 0 -6px -24px}.widget-tip._bottom .widget-tip__content{top:80%;margin-top:8px}.widget-tip._bottom .widget-tip__content:after{display:none}.widget-tip._bottom._center .widget-tip__content:before{left:50%;top:0;margin:-6px 0 0 -8px}.widget-tip._center .widget-tip__content{left:50%}.widget-tip._right .widget-tip__content{right:-3px}.widget-tip._dark .widget-tip__content{background:#333;border-radius:3px;color:#fff;width:0;height:0}.widget-tip._dark .widget-tip__content:before{border-bottom-color:#333}.widget-tip._dark .widget-tip__content:after{border-top-color:#333}.widget-tip._light .widget-tip__content{background:#fff;border:2px solid #c03c40;margin-bottom:20px}.widget-tip._light .widget-tip__content:after{margin:-2px 0 -10px -10px;border:2px solid #c03c40;border-top:none;border-left:none;background:#fff;width:15px;height:15px;-webkit-transform:rotate(45deg) translateX(0) scale(1);transform:rotate(45deg) translateX(0) scale(1)}.widget-tip:hover .widget-tip__content{height:auto;opacity:1;transition:top .2s linear,bottom .2s linear,opacity .2s linear;overflow:visible}.widget-tip:hover._top .widget-tip__content{bottom:100%}.widget-tip:hover._bottom .widget-tip__content{top:100%}.widget-tip:hover._dark .widget-tip__content{padding:9px 11px}.widget-tip:hover._light .widget-tip__content{padding:14px 13px}', ""])
}, function(e, t) {
e.exports = "
{{title}}
{{{text}}}
"
}, function(e, t, i) {
"use strict";
function r(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var a = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
n = i(145),
o = function() {
function e() {
r(this, t)
}
a(e, [{
key: "getAccessibilityData",
get: function() {
var e = [];
return this.roads && this.roads.distance_to_city && e.push({
type: "Машина или автобус",
name: Math.round(this.roads.distance_to_city / 1e3) + " км от города",
direction: this.roads.name_ru
}), this.stations && this.stations.directions[0] && e.push({
type: "Электричка",
name: this.stations.name_ru,
direction: this.stations.directions[0].name_ru
}), e
}
}], [{
key: "styles",
value: i(1549)(n.asset("./styles/accessibility.scss")),
enumerable: !0
}, {
key: "template",
value: i(1549)(n.asset("./templates/accessibility.jade")),
enumerable: !0
}, {
key: "props",
value: {
stations: {
required: !0
},
roads: {
required: !0
}
},
enumerable: !0
}]);
var t = e;
return e = n.ComponentVue(e) || e
}();
t["default"] = o, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./Accessibility": 1548,
"./Accessibility.js": 1548,
"./styles/accessibility.scss": 1550,
"./templates/accessibility.jade": 1552
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1549
}, function(e, t, i) {
var r = i(1551);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, ".card-dacha-accessibility{position:relative;margin-bottom:48px}.card-dacha-accessibility__title{font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:36px;line-height:42px;margin:0 0 24px}.card-dacha-accessibility__header{color:gray;padding-bottom:18px}.card-dacha-accessibility__row{padding-bottom:12px}.card-dacha-accessibility__col1{display:inline-block;min-width:150px;width:25%;vertical-align:top}.card-dacha-accessibility__col2{display:inline-block;min-width:200px;width:35%;vertical-align:top}.card-dacha-accessibility__col3{display:inline-block;max-width:40%;vertical-align:top}", ""])
}, function(e, t) {
e.exports = '
Транспортная доступность
Вид транспортаНаправлениеМестоположение
{{row.type}}{{row.direction}}{{row.name}}
'
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
o = i(145),
s = i(1554),
l = r(s),
c = i(1555),
p = r(c),
d = i(1556),
u = r(d),
f = i(1557),
m = r(f),
h = i(510),
g = r(h),
_ = i(1038),
y = r(_),
b = i(760),
v = r(b),
x = i(117),
w = r(x),
M = function() {
function e() {
a(this, t), this.breadcrumbs = [], this.phonesVisible = !1, this.similarOffers = [], this.isVisibleDummySimilar = !0, this.seoLinks = [], this.seoSimilar = [], this.isReadyOtherOffers = !1
}
e.prototype.compiledBe = function() {
this.initData()
}, e.prototype.compiled = function() {
this.initData()
}, e.prototype.ready = function() {
var e = this;
this.$analytics("OPEN_DACHA_CARD"), this._initPhoto(), this._initOtherOffers(), this.$on("_changeRequest", function() {
e._destroyFotorama(), e._initPhoto(), e.phonesVisible = !1
})
}, e.prototype.initData = function() {
this.$root.pageMeta = w["default"].merge(this.$root.pageMeta, this._getOpenGraph());
var e = this.$request().getContext("Project").getProjectDomain(),
t = new l["default"](this.offer, e);
this.breadcrumbs = t.getBreadcrumbs();
var i = new u["default"](this.offer, e);
this.seoLinks = i.getLinks()
}, e.prototype.showGallery = function() {
var e = this;
if (!this.offer.hasPhotos()) return this;
for (var t = [], i = this.offer.param("photos"), r = $(this.$els.galleryClone).data("fotorama").activeIndex, a = 0; a < i.length; a++) t[a] = {
href: this.$getPhotoUrl(i[a].url_mask, 1200, 800, !1),
thumb: this.$getPhotoUrl(i[a].url_mask, 70, 70, !0),
title: i[a].description
};
return this._gallery || (this._gallery = new g["default"](this.$resource()), this._gallery.on("closed", function() {
e.$emit("galleryClosed")
})), this._gallery.setData({
header: this.header,
price: this.offer.param("params.price"),
is_newbuilding: this.offer.param("params.is_newbuilding"),
photos: t,
index: r
}), this.$emit("beforeGalleryOpen"), this._gallery.open(), this.$emit("galleryOpen"), this
}, e.prototype.onClickDiscard = function() {
this.$emit("toggle_discard")
}, e.prototype.onChangePhoneState = function(e) {
this.phonesVisible = e
}, e.prototype._initOtherOffers = function() {
var e = this,
t = this._getOtherData();
t.promises.then(function(i) {
e._initSimilarOffers(i), e._initSeoOffers(i, t.seoKeys), e.seoLinks = e._seoLinks, e.isReadyOtherOffers = !0, e.isVisibleDummySimilar = !1
})["catch"](function(t) {
e.isVisibleDummySimilar = !1, e.$logError(t)
})
}, e.prototype._initSimilarOffers = function(e) {
var t = w["default"].get(e, "similarOffers.result", []);
t.length && (this.similarOffers = this._getSortedSimilarByDistrict(t))
}, e.prototype._initSeoOffers = function(e, t) {
for (var i = this.similarOffers.length ? this._getRepeatedIds([], this.similarOffers) : [], r = 0; r < t.length; r++) {
var a = this.$service("OffersSearch").getEntities(w["default"].get(e, t[r] + ".result", [])),
n = this._getSortedOffers(i, a);
if (n.length) {
r < t.length - 1 && (i = this._getRepeatedIds(i, n));
var o = this.seoLinks[r];
o.offers = n, this.seoSimilar.push(o)
} else this._seoLinks.push(this.seoLinks[r])
}
}, e.prototype._getSortedSimilarByDistrict = function(e) {
var t = this;
return e = this.$service("OffersSearch").getEntities(e), !this.offer.has("params.district.id") || e.length < 4 ? e : w["default"].sortBy(e, function(e) {
return e.param("params.district.id") !== t.offer.param("params.district.id")
})
}, e.prototype._getRepeatedIds = function(e, t) {
var i = t.slice(0, 4).map(function(e) {
return e.getId()
});
return e.concat(i)
}, e.prototype._getSortedOffers = function(e, t) {
if (!e.length || !t.length) return t;
var i = t.filter(function(t) {
return !w["default"].includes(e, t.getId())
});
if (i.length < 4) return [];
var r = i.slice(0, 4),
a = t.filter(function(e) {
return !w["default"].includes(r, e)
});
return r.concat(a)
}, e.prototype._getOtherData = function() {
var e = this,
t = {},
i = new p["default"](this.offer);
t.similarOffers = this.$service("OffersSearch").search(i.getApiQuery());
var r = new m["default"](this.offer).getQueries(this.seoLinks);
return w["default"].size(r.queries) && w["default"].forEach(r.queries, function(i, r) {
t[r] = e.$service("OffersSearch").search(i)
}), {
promises: this.$runPromises(t),
seoKeys: r.keys
}
}, e.prototype._initPhoto = function() {
this.offer.hasPhotos() && (this.$els.galleryClone && $(this.$els.galleryClone).remove(), $(this.$els.gallery).show(), this.$els.galleryClone = this.$els.gallery.cloneNode(!0), $(this.$els.gallery).hide(), $(this.$els.gallery).after(this.$els.galleryClone), this._initFotorama())
}, e.prototype._initFotorama = function() {
var e = this,
t = {
width: "100%",
nav: "thumbs",
thumbheight: 70,
thumbmargin: 4,
thumbborderwidth: 4,
fit: "contain",
click: !1,
arrows: "always",
spinner: {
lines: 13,
color: "rgba(0, 0, 0, .75)"
}
};
t.height = $(this.$els.galleryClone).css({
opacity: 1
}).height();
for (var i = [], r = this.offer.param("photos"), a = 0; a < r.length; a++) i[a] = {
img: this.$getPhotoUrl(r[a].url_mask, 1200, 800, !1),
thumb: this.$getPhotoUrl(r[a].url_mask, 70, 70, !0)
};
t.data = i;
var n = void 0;
$(this.$els.galleryClone).on("fotorama:ready", function(t, i) {
n = $(e.$els.galleryClone).find(".fotorama__stage__shaft"), n.on("click.shaft", function() {
e.showGallery()
})
}), $(this.$els.galleryClone).on("fotorama:show", function(e, t) {
n && n.off("click.shaft")
}), $(this.$els.galleryClone).on("fotorama:showend", function(t, i) {
n && n.on("click.shaft", function() {
e.showGallery()
})
}), $(this.$els.galleryClone).fotorama(t)
}, e.prototype._destroyFotorama = function() {
this.$els.galleryClone && $(this.$els.galleryClone).data("fotorama") && $(this.$els.galleryClone).data("fotorama").destroy()
}, e.prototype._getOpenGraph = function() {
var e = this,
t = new y["default"],
i = this.header,
r = [];
if (this.offer.has("params.city.name_ru") && r.push(this.offer.param("params.city.name_ru")), this.offer.has("params.total_area")) {
var a = this.offer.param("params.total_area") / 100;
a = this.$options.filters.typographyDivider(a), r.push(a + " м2")
}
var n = this.$request().getProtocol(),
o = "";
o = this.offer.has("params.city.params.domain") ? this.offer.param("params.city.params.domain") : this.offer.param("params.region.params.domain");
var s = this.$request().getContext("Geo"),
l = "";
l = "city" === s.getSearchContext() && s.getCities.length ? s.getCities()[0].name_ru : s.getParam("region.name_ru");
var c = i.join(", ") + ", " + this.$options.filters.spaces(this.offer.param("params.price")) + " руб. — N1 " + l;
if (t.addTitle(c), t.addType("website"), t.addDescription(r.join(", ")), t.addUrl(n + "://" + o + "/view/" + this.offer.getId()), this.offer.hasPhotos()) this.offer.param("photos").forEach(function(i) {
var r = e.$getPhotoUrl(i.url_mask, 1200, 800, !1);
t.addImage(r).addCustomTag("link", {
rel: "image_src",
href: r
})
});
else {
var p = "https://n1.ru/static/img/Public/logo.png";
t.addImage(p).addCustomTag("link", {
rel: "image_src",
href: p
})
}
return {
openGraph: t.build()
}
}, n(e, [{
key: "header",
get: function() {
var e = [];
return this.offer.has("params.type.grammatical_cases.accusative") ? e.push(this.offer.param("params.type.grammatical_cases.accusative")) : e.push("дачу"), this.offer.has("params.city.name_ru") && e.push(this.offer.param("params.city.name_ru")), "rent_out" === this.offer.param("deal_type") ? e[0] = "Сдам " + e[0].toLowerCase() : "sell" === this.offer.param("deal_type") && (e[0] = "Продам " + e[0].toLowerCase()), e
}
}, {
key: "dealParams",
get: function() {
var e = {},
t = {
is_haggle: "Торг",
is_pawn: "В залоге",
is_deposit: "Внесен задаток"
};
for (var i in t) this.offer.param("params." + i) && (e[i] = t[i]);
return {
count: w["default"].size(e),
result: e
}
}
}, {
key: "hasHomesteadParams",
get: function() {
return this.offer.hasParams(["homestead_area", "ownership_type.title", "has_electricity", "has_water_supply", "has_gas_supply", "has_plantings"])
}
}, {
key: "hasOutbuildingParams",
get: function() {
return this.offer.hasParams(["total_area", "release_date.year", "has_bathhouse", "has_toilet", "has_garage", "has_greenhouse"])
}
}, {
key: "hasSummerCottageParams",
get: function() {
return this.offer.hasParams(["has_security", "has_asphalt_road", "is_available_in_winter", "is_shop_near", "is_water_near", "is_forest_near", "distance_to_bus_stop_type.title"])
}
}, {
key: "defaultEmailMessage",
get: function() {
return v["default"](this.offer)
}
}, {
key: "hasLocation",
get: function() {
return this.offer.has("params.district.name_ru") || this.offer.has("params.area.name_ru") || this.offer.has("params.summer_cottage_area.name_ru")
}
}, {
key: "hasReference",
get: function() {
return this.offer.has("params.reference_point") && this.offer.param("params.reference_point").length > 2 && !this.offer.has("params.summer_cottage_area.name_ru")
}
}, {
key: "isComplaintBetaActive",
get: function() {
var e = this.$request().getBetaFeatures().get("complaints_advanced"),
t = this.$projectConfig().getParam("isN1ComplaintServiceEnable", !1);
return e && t
}
}, {
key: "hasAccessibility",
get: function() {
return Boolean(this.offer.param("params.railway_stations[0]") || this.offer.param("params.roads[0]"))
}
}], [{
key: "styles",
value: i(1558)(o.asset("./styles/card-dacha-content.scss")),
enumerable: !0
}, {
key: "template",
value: i(1558)(o.asset("./templates/card-dacha-content.jade")),
enumerable: !0
}, {
key: "props",
value: {
offer: {
required: !0
},
isDiscarded: {
type: Boolean,
required: !0
},
isFavorite: {
type: Boolean,
required: !0
},
offerPrices: {
type: Array,
"default": null
}
},
enumerable: !0
}, {
key: "filters",
value: {
typographyDivider: i(777)
},
enumerable: !0
}, {
key: "components",
value: {
breadcrumbs: i(1490),
contacts: i(1495),
costSubscription: i(1503),
description: i(1508),
favoriteSwitcher: i(677),
map: i(1560),
accessibility: i(1548),
pricesTable: i(1518),
sideBanners: i(1528),
similarOffers: i(1576),
shareLink: i(1533),
tip: i(1543)
},
enumerable: !0
}, {
key: "partials",
value: {
actions: i(1558)(o.asset("./templates/partials/card-dacha-content-actions.jade")),
dealParams: i(1558)(o.asset("./templates/partials/card-dacha-content-deal-params.jade")),
header: i(1558)(o.asset("./templates/partials/card-dacha-content-header.jade")),
footer: i(1558)(o.asset("./templates/partials/card-dacha-content-footer.jade")),
location: i(1558)(o.asset("./templates/partials/card-dacha-content-location.jade")),
media: i(1558)(o.asset("./templates/partials/card-dacha-content-media.jade")),
params: i(1558)(o.asset("./templates/partials/card-dacha-content-params.jade")),
price: i(1558)(o.asset("./templates/partials/card-dacha-content-price.jade"))
},
enumerable: !0
}, {
key: "_seoLinks",
value: [],
enumerable: !0
}]);
var t = e;
return e = o.ComponentVue(e) || e
}();
t["default"] = M, e.exports = t["default"]
}, function(e, t) {
"use strict";
function i(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var r = function() {
function e(t, r) {
i(this, e), this._offer = t, this._domain = r, this._cityUrl = this._getCityUrl(), this._regionUrl = this._getRegionUrl(), this._basePart = this._getBasePart()
}
return e.prototype.getCityCrumb = function() {
if (!this._cityUrl && !this._regionUrl) return null;
var e = this._cityUrl || this._regionUrl,
t = "Недвижимость";
"rent_out" === this._offer.param("deal_type") && (t = "Аренда", e += "snyat/");
var i = this._cityUrl ? "city" : "region";
return t += this._offer.has("params." + i + ".grammatical_cases_ru.locative") ? " в " + this._offer.param("params." + i + ".grammatical_cases_ru.locative") : ", " + this._offer.param("params." + i + ".name_ru"), {
url: e,
title: t
}
}, e.prototype.getRubricCrumb = function() {
if (!this._cityUrl && !this._regionUrl) return null;
var e = (this._cityUrl || this._regionUrl) + this._basePart.url,
t = this._basePart.title;
return {
url: e + "/",
title: t
}
}, e.prototype.getAreaCrumb = function() {
var e = this._getArea();
if (!this._regionUrl || !e) return null;
var t = "" + this._regionUrl + this._basePart.url + "/" + e.url + "/",
i = e.title;
return {
url: t,
title: i
}
}, e.prototype.getDistrictCrumb = function() {
var e = this._getDistrict();
if (!this._cityUrl || !e) return null;
var t = "" + this._cityUrl + this._basePart.url + "/" + e.url + "/",
i = e.title;
return {
url: t,
title: i
}
}, e.prototype.getTypeCrumb = function() {
var e = this._getType();
if (!this._cityUrl && !this._regionUrl || !e) return null;
var t = (this._cityUrl || this._regionUrl) + (this._basePart.url + "/" + e.url + "/"),
i = e.title;
return {
url: t,
title: i
}
}, e.prototype.getBreadcrumbs = function() {
var e = [],
t = this.getCityCrumb();
t && e.push(t);
var i = this.getRubricCrumb();
i && e.push(i);
var r = this.getAreaCrumb();
r && e.push(r);
var a = this.getDistrictCrumb();
a && e.push(a);
var n = this.getTypeCrumb();
return n && e.push(n), e
}, e.prototype._getCityUrl = function() {
if (!this._offer.has("params.city")) return null;
var e = "/";
return this._offer.has("params.city.params.domain") ? this._offer.param("params.city.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.city.params.domain") + "/") : (this._offer.param("params.region.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.region.params.domain") + "/"), this._offer.has("params.city.name_translit") && (e += "city-" + this._offer.param("params.city.name_translit") + "/")), e
}, e.prototype._getRegionUrl = function() {
if (!this._offer.has("params.region")) return null;
var e = "/";
return this._offer.param("params.region.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.region.params.domain") + "/"), e += "region-" + this._offer.param("params.region.name_translit") + "/"
}, e.prototype._getBasePart = function() {
var e = [],
t = "Дачи, садовые участки";
return "rent_out" === this._offer.param("deal_type") && e.push("snyat"), e.push("dacha"), "rent_out" === this._offer.param("deal_type") && (t = "Аренда дач, садовых участков"), {
title: t,
url: e.join("/")
}
}, e.prototype._getArea = function() {
if (!this._offer.has("params.area.name_translit") || !this._offer.has("params.area.name_ru")) return null;
var e = this._offer.param("params.area.name_ru"),
t = "area-" + this._offer.param("params.area.name_translit");
return {
title: e,
url: t
}
}, e.prototype._getDistrict = function() {
if (!this._offer.has("params.district.name_translit") || !this._offer.has("params.district.name_ru")) return null;
var e = this._offer.param("params.district.name_ru"),
t = "district-" + this._offer.param("params.district.name_translit");
return {
title: e,
url: t
}
}, e.prototype._getType = function() {
if (!this._offer.param("params.type")) return null;
var e = this._offer.param("params.type.title");
this._offer.has("params.type.grammatical_cases_plural.nominative") && (e = this._offer.param("params.type.grammatical_cases_plural.nominative")), e = e[0].toUpperCase() + e.slice(1);
var t = "type-" + this._offer.param("params.type.value");
return {
title: e,
url: t
}
}, e
}();
t["default"] = r, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = i(1411),
o = r(n),
s = function() {
function e(t) {
a(this, e), this._offer = t
}
return e.prototype.getApiQuery = function() {
var e = arguments.length <= 0 || void 0 === arguments[0] ? 20 : arguments[0],
t = {
price_min: o["default"](this._offer.param("params.price"), "-50%"),
price_max: o["default"](this._offer.param("params.price"), "+50%")
};
return this._offer.has("params.type.value") && (t.type = this._offer.param("params.type.value")), this._offer.has("params.city.id") ? t.city_id = this._offer.param("params.city.id").toString() : this._offer.has("params.region.id") && (t.region_id = this._offer.param("params.region.id").toString()), {
limit: e,
sort: "-has_photos,-creation_date",
query: [{
rubric: this._offer.param("rubric"),
deal_type: this._offer.param("deal_type"),
exclude_ids: [this._offer.getId()],
status: "published",
filter: t
}]
}
}, e
}();
t["default"] = s, e.exports = t["default"]
}, function(e, t) {
"use strict";
function i(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var r = function() {
function e(t, r) {
i(this, e), this._offer = t, this._domain = r, this._cityUrl = this._getCityUrl(), this._basePart = this._getBasePart(), this._type = this._getType()
}
return e.prototype.getDistrictLink = function() {
var e = this._getDistrict();
if (!this._cityUrl || !this._type || !e) return null;
var t = [this._basePart, this._type.url, e.url],
i = this._type.title + e.title;
return "rent_out" === this._offer.param("deal_type") && (i = "Снять " + i), i = i.substr(0, 1).toUpperCase() + i.substr(1), {
name: "district",
url: "" + this._cityUrl + t.join("/") + "/",
title: i
}
}, e.prototype.getAreaLink = function() {
var e = this._getArea();
if (!this._offer.has("params.region.name_translit") || !this._type || !e) return null;
var t = "/region-" + this._offer.param("params.region.name_translit") + "/",
i = [this._basePart, this._type.url, e.url],
r = this._type.title + e.title;
return "rent_out" === this._offer.param("deal_type") && (r = "Снять " + r), r = r.substr(0, 1).toUpperCase() + r.substr(1), {
name: "area",
url: "" + t + i.join("/") + "/",
title: r
}
}, e.prototype.getLinks = function() {
var e = [],
t = this.getDistrictLink();
t && e.push(t);
var i = this.getAreaLink();
return i && e.push(i), e
}, e.prototype._getCityUrl = function() {
if (!this._offer.has("params.city")) return null;
var e = "/";
return this._offer.has("params.city.params.domain") ? this._offer.param("params.city.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.city.params.domain") + "/") : (this._offer.param("params.region.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.region.params.domain") + "/"), this._offer.has("params.city.name_translit") && (e += "city-" + this._offer.param("params.city.name_translit") + "/")), e
}, e.prototype._getBasePart = function() {
var e = [];
return "rent_out" === this._offer.param("deal_type") && e.push("snyat"), e.push("dacha"), e.join("/")
}, e.prototype._getType = function() {
if (!this._offer.param("params.type")) return null;
var e = this._offer.param("params.type.title");
this._offer.has("params.type.grammatical_cases_plural.nominative") && (e = this._offer.param("params.type.grammatical_cases_plural.nominative")), e = e[0].toLowerCase() + e.slice(1);
var t = "type-" + this._offer.param("params.type.value");
return {
title: e,
url: t
}
}, e.prototype._getDistrict = function() {
if (!this._offer.has("params.district.name_translit")) return null;
var e = "";
e = this._offer.has("params.district.grammatical_cases_ru.locative") ? " " + this._offer.param("params.district.grammatical_cases_ru.locative") : ", " + this._offer.param("params.district.name_ru");
var t = "district-" + this._offer.param("params.district.name_translit");
return {
title: e,
url: t
}
}, e.prototype._getArea = function() {
if (!this._offer.has("params.area.name_translit")) return null;
var e = "";
e = this._offer.has("params.area.grammatical_cases_ru.locative") ? " " + this._offer.param("params.area.grammatical_cases_ru.locative") : ", " + this._offer.param("params.area.name_ru");
var t = "area-" + this._offer.param("params.area.name_translit");
return {
title: e,
url: t
}
}, e
}();
t["default"] = r, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = i(117),
o = r(n),
s = function() {
function e(t) {
a(this, e), this._offer = t, this._baseQuery = this._getBaseQuery()
}
return e.prototype.getDistrictQuery = function() {
if (!this._baseQuery || !this._offer.has("params.district.id")) return null;
var e = o["default"].cloneDeep(this._baseQuery);
return this._offer.has("params.city.id") ? e.query[0].filter.city_id = this._offer.param("params.city.id").toString() : this._offer.has("params.region.id") && (e.query[0].filter.region_id = this._offer.param("params.region.id").toString()), e.query[0].filter.district = this._offer.param("params.district.id").toString(), e
}, e.prototype.getAreaQuery = function() {
if (!this._baseQuery || !this._offer.has("params.area.id")) return null;
var e = o["default"].cloneDeep(this._baseQuery);
return this._offer.has("params.region.id") && (e.query[0].filter.region_id = this._offer.param("params.region.id").toString()), e.query[0].filter.area_id = this._offer.param("params.area.id").toString(), e
}, e.prototype.getQueries = function(e) {
for (var t = [], i = {}, r = 0; r < e.length; r++) {
var a = e[r];
if ("district" !== a.name)
if ("area" !== a.name);
else {
t.push("area");
var n = this.getAreaQuery();
n && (i.area = n)
}
else {
t.push("district");
var o = this.getDistrictQuery();
o && (i.district = o)
}
}
return {
keys: t,
queries: i
}
}, e.prototype._getBaseQuery = function() {
return this._offer.has("params.type.value") ? {
limit: 20,
sort: "-creation_date",
query: [{
rubric: this._offer.param("rubric"),
deal_type: this._offer.param("deal_type"),
exclude_ids: [this._offer.getId()],
status: "published",
filter: {
type: this._offer.param("params.type.value")
}
}]
} : null
}, e
}();
t["default"] = s, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./Accessibility/Accessibility": 1548,
"./Accessibility/Accessibility.js": 1548,
"./Accessibility/styles/accessibility.scss": 1550,
"./Accessibility/templates/accessibility.jade": 1552,
"./CardDachaContent": 1553,
"./CardDachaContent.js": 1553,
"./Map/ButtonsConfig": 1559,
"./Map/ButtonsConfig.js": 1559,
"./Map/Map": 1560,
"./Map/Map.js": 1560,
"./Map/styles/card-dacha-map.scss": 1564,
"./Map/templates/card-dacha-map.jade": 1566,
"./Map/templates/partials/card-dacha-map-dummy.jade": 1567,
"./Map/templates/partials/card-dacha-map-footer.jade": 1568,
"./Map/templates/partials/card-dacha-map-header.jade": 1569,
"./Map/templates/partials/card-dacha-map-item.jade": 1570,
"./SimilarDacha/Item/Item": 1571,
"./SimilarDacha/Item/Item.js": 1571,
"./SimilarDacha/Item/styles/similar-dacha-item.scss": 1573,
"./SimilarDacha/Item/templates/similar-dacha-item.jade": 1575,
"./SimilarDacha/SimilarDacha": 1576,
"./SimilarDacha/SimilarDacha.js": 1576,
"./SimilarDacha/styles/similar-dacha.scss": 1578,
"./SimilarDacha/templates/partials/similar-dacha-item-dummy.jade": 1580,
"./SimilarDacha/templates/similar-dacha.jade": 1581,
"./styles/card-dacha-content.scss": 1582,
"./templates/card-dacha-content.jade": 1584,
"./templates/partials/card-dacha-content-actions.jade": 1585,
"./templates/partials/card-dacha-content-deal-params.jade": 1586,
"./templates/partials/card-dacha-content-footer.jade": 1587,
"./templates/partials/card-dacha-content-header.jade": 1588,
"./templates/partials/card-dacha-content-location.jade": 1589,
"./templates/partials/card-dacha-content-media.jade": 1590,
"./templates/partials/card-dacha-content-params.jade": 1591,
"./templates/partials/card-dacha-content-price.jade": 1592
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1558
}, function(e, t) {
"use strict";
t.__esModule = !0, t["default"] = function() {
return [{
name: "similar",
active: !1,
visible: !0,
title: "Похожие объявления"
}]
}, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
o = i(145),
s = i(480),
l = r(s),
c = i(1421),
p = r(c),
d = i(1561),
u = r(d),
f = i(1559),
m = r(f),
h = i(1562),
g = r(h),
_ = i(117),
y = r(_),
b = function() {
function e() {
a(this, t), this.isVisibleDummy = !0, this.similar = {
offers: [],
urlQuery: ""
}
}
e.prototype.ready = function() {
var e = this;
this.offer.hasLocation() && this._getMapData().then(function(t) {
e._map = t.map;
var i = y["default"].get(t, "similarOffers.result", []);
i.length && (e.similar.offers = i), e._initOfferStore(), e._initOverlays(), e._initButtons(), e.isVisibleDummy = !1, e._initOffer(), e._initSimilarOffers()
})["catch"](function(t) {
e.$logError(t)
})
}, e.prototype._getMapData = function() {
var e = this,
t = {},
i = new l["default"](this.$els.map, {
layers: {
sputnik: !0
},
layersButton: !0,
fullscreen: !0,
leafletOptions: {
touchZoom: !0,
scrollWheelZoom: !1,
fullscreenControl: !0,
fullscreenPseudo: !0
},
plugins: {
markercluster: !0,
draw: !1
}
});
t.map = i.init(this.$resource().getConfig("version")).then(function() {
return i.addOption("zoomFullLoad", 15), i.onFullScreenChange(function() {
var t = i.isFullScreen();
t ? $("body").addClass("_fit-window-height") : $("body").removeClass("_fit-window-height"), e.$root.view.fitWindowHeightMode = t
}), i
});
var r = new g["default"](this.offer),
a = r.getLocationApiQuery();
return a && (t.similarOffers = this.$service("OffersSearch").search(a), this.similar.urlQuery = r.getOffersUrlQuery()), this.$runPromises(t)
}, e.prototype._initOfferStore = function() {
this._offerStore = new u["default"]({
logger: this.$resources().getLogger(),
map: this._map.getOriginalMap(),
vueFilters: this.$options.filters,
services: this.$service(),
getPhotoUrl: this.$getPhotoUrl,
popupSelector: this._popup.selector
}), this._map.addOption("offerStore", this._offerStore)
}, e.prototype._initOverlays = function() {
this._overlays = new p["default"](this._map), this._overlays.add("similar", this._offerStore.getLayer())
}, e.prototype._initButtons = function() {
var e = this.buttons[0],
t = this.$user().getLocalSettings().getValue("DACHA_MAP_BUTTONS", !1);
t || (t = this._activeButtons), t.length ? (this._overlays.show("similar"), e.active = !0) : (this._overlays.hide("similar"), e.active = !1)
}, e.prototype._initOffer = function() {
var e = new L.Marker([this.offer.param("params.location.lat"), this.offer.param("params.location.lon")], {
icon: L.icon({
className: ".card-dacha-map__pin-icon",
iconUrl: "/static/img/Public/icon-map-pin-main.png",
iconSize: [36, 46],
iconAnchor: [18, 46]
})
});
this._map.addLayer(e), this._map.setView(this.offer.param("params.location"), 15)
}, e.prototype._initSimilarOffers = function() {
var e = this;
this.similar.offers.length && (this._offerStore.addOffers(this.similar.offers), this._offerStore.events.on("openCard", function(t) {
e._openCard(t)
}), this._offerStore.events.on("renderCard", function(t, i) {
e._renderCard(t, i)
}), this._offerStore.events.on("renderCards", function(t, i) {
e._renderCards(t, i)
}))
}, e.prototype._openCard = function(e) {
var t = window.location.protocol + "//" + window.location.hostname;
t += "/view/" + e + "/?offer_similar_dacha_variant_inf&open_card_dacha", window.open(t)
}, e.prototype._renderCard = function(e, t) {
var i = document.createElement("div");
i.innerHTML = this._popup.header + this._popup.item, this.offerVm = new Vue({
el: i,
data: {
properties: e.offerView,
id: e.offerView.id,
count: 1
},
filters: this.$options.filters
}), t(null, i.innerHTML)
}, e.prototype._renderCards = function(e, t) {
var i = y["default"].last(e.offerViews),
r = document.createElement("div");
r.innerHTML = this._popup.header, new Vue({
el: r,
data: {
properties: i
}
});
var a = r.innerHTML,
n = document.createElement("div");
n.innerHTML = this._popup.item;
var o = new Vue({
el: n,
data: {
properties: {},
id: ""
},
filters: this.$options.filters
});
if (y["default"].each(e.offerViews, function(e) {
o.properties = e, o.id = e.item.id, a += n.innerHTML
}), e.linkMore) {
var s = this.offer.param("params.summer_cottage_area.id"),
l = y["default"].get(i.item, "params.summer_cottage_area.id");
s === l && (e.count = e.count + 1), this.similar.urlQuery.query.summer_cottage_area_id = l;
var c = document.createElement("div");
c.innerHTML = this._popup.footer, new Vue({
el: c,
data: {
url: this.similar.urlQuery.path + "?" + $.param(this.similar.urlQuery.query),
count: e.count
},
filters: this.$options.filters
}), a += c.innerHTML
}
t(null, a)
}, e.prototype.toggleOverlay = function(e) {
var t = this.buttons[0];
t.active = !t.active, t.active ? (this._overlays.show("similar"), this.$user().getLocalSettings().setValue("DACHA_MAP_BUTTONS", ["similar"])) : (this._overlays.hide("similar"), this.$user().getLocalSettings().setValue("DACHA_MAP_BUTTONS", []))
}, e.prototype.beforeDestroy = function() {
this._map && this._map.destroy()
}, n(e, [{
key: "buttons",
get: function() {
return m["default"]()
}
}], [{
key: "styles",
value: i(1563)(o.asset("./styles/card-dacha-map.scss")),
enumerable: !0
}, {
key: "template",
value: i(1563)(o.asset("./templates/card-dacha-map.jade")),
enumerable: !0
}, {
key: "components",
value: {
preloader: i(405)
},
enumerable: !0
}, {
key: "partials",
value: {
dummy: i(1563)(o.asset("./templates/partials/card-dacha-map-dummy.jade"))
},
enumerable: !0
}, {
key: "props",
value: {
offer: {
required: !0
}
},
enumerable: !0
}, {
key: "_popup",
value: {
header: i(1563)(o.asset("./templates/partials/card-dacha-map-header.jade")),
item: i(1563)(o.asset("./templates/partials/card-dacha-map-item.jade")),
footer: i(1563)(o.asset("./templates/partials/card-dacha-map-footer.jade")),
selector: ".card-dacha-map-item"
},
enumerable: !0
}, {
key: "_map",
value: null,
enumerable: !0
}, {
key: "_offerStore",
value: null,
enumerable: !0
}, {
key: "_overlays",
value: null,
enumerable: !0
}, {
key: "_activeButtons",
value: ["similar"],
enumerable: !0
}]);
var t = e;
return e = o.ComponentVue(e) || e
}();
t["default"] = b, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = i(1423),
o = r(n),
s = i(15),
l = r(s),
c = i(117),
p = r(c),
d = function() {
function e(t) {
var i = this;
a(this, e);
var r = ["map", "vueFilters", "services", "getPhotoUrl"];
if (!p["default"].keys(p["default"].pick(t, r)).length) throw new Error("[DachaOfferStore] обязательные options для конструктора: " + r.join(","));
this.events = new o["default"], this._map = t.map, this._vueFilters = t.vueFilters, this._services = t.services, this._getPhotoUrl = t.getPhotoUrl, this._popupSelector = t.popupSelector, this._offers = {}, this._count = 0, this._zoomFullLoad = this._map.options.zoomFullLoad, L.Icon.Default.imagePath = "/static/img/leaflet", this._group = L.markerClusterGroup({
clusterType: "offers",
maxClusterRadius: function(e) {
return e >= i._zoomFullLoad ? 20 : 40
},
removeOutsideVisibleBounds: !0,
animateAddingMarkers: !1,
polygonOptions: {
fillColor: "#000"
},
singleMarkerMode: !0,
zoomToBoundsOnClick: !0,
iconCreateFunction: function(e) {
var t, r = e.getChildCount(),
a = "",
n = "";
if (e._zoom && e._zoom >= i._zoomFullLoad) n = "ymap-offer-pin-group", t = new L.Point(40, 40), a = '
' + r + "
";
else {
n = "ymap-offer-pin-cluster", t = {
x: 50,
y: 50
};
var o = String(r).length;
switch (o) {
case 1:
n += " _digit1", t = {
x: 30,
y: 30
};
break;
case 2:
n += " _digit2", t = {
x: 40,
y: 40
};
break;
case 3:
n += " _digit3", t = {
x: 50,
y: 50
};
break;
case 4:
default:
n += " _digit4", t = {
x: 60,
y: 60
}
}
t = new L.Point(t.x, t.y), a = '
"
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
o = i(145),
s = i(1594),
l = r(s),
c = i(1595),
p = r(c),
d = i(510),
u = r(d),
f = i(1038),
m = r(f),
h = i(779),
g = r(h),
_ = i(1596),
y = r(_),
b = i(117),
v = r(b),
x = function() {
function e() {
a(this, t), this.crumbs = [], this.seoLinks = [], this.phonesVisible = !1
}
e.prototype.createdBe = function() {
this.initData()
}, e.prototype.created = function() {
this.initData()
}, e.prototype.ready = function() {
var e = this;
this.$analytics("OPEN_PARKING_CARD"), this._initPhoto(), this.$on("_changeRequest", function() {
e._destroyFotorama(), e._initPhoto(), e.phonesVisible = !1
})
}, e.prototype.initData = function() {
this.$root.pageMeta = v["default"].merge(this.$root.pageMeta, this._getOpenGraph());
var e = this.$request().getContext("Project").getProjectDomain();
this.crumbs = new l["default"](this.offer, e).getBreadcrumbs(), this.seoLinks = new p["default"](this.offer, e).getLinks()
}, e.prototype.showGallery = function() {
var e = this;
this._gallery || (this._gallery = new u["default"](this.$resource()), this._gallery.on("closed", function() {
e.$emit("galleryClosed")
})), this._gallery.setData({
header: [this.offer.getFullTitle("гараж")],
price: this.offer.param("params.price"),
is_newbuilding: this.offer.param("params.is_newbuilding"),
photos: this.galleryPhotos,
index: $(this.$els.galleryClone).data("fotorama").activeIndex
}), this.$emit("beforeGalleryOpen"), this._gallery.open(), this.$emit("galleryOpen")
}, e.prototype.onClickDiscard = function() {
this.$emit("toggle_discard")
}, e.prototype.onChangePhoneState = function(e) {
this.phonesVisible = e
}, e.prototype._initPhoto = function() {
this.offer.hasPhotos() && (this.$els.galleryClone && $(this.$els.galleryClone).remove(), $(this.$els.gallery).show(), this.$els.galleryClone = this.$els.gallery.cloneNode(!0), $(this.$els.gallery).hide(), $(this.$els.gallery).after(this.$els.galleryClone), this._initFotorama())
}, e.prototype._initFotorama = function() {
var e = this,
t = {
width: "100%",
height: $(this.$els.galleryClone).css({
opacity: 1
}).height(),
nav: "thumbs",
thumbheight: 70,
thumbmargin: 4,
thumbborderwidth: 4,
fit: "contain",
click: !1,
arrows: "always",
spinner: {
lines: 13,
color: "rgba(0, 0, 0, .75)"
},
data: this.galleryPhotos
},
i = null;
$(this.$els.galleryClone).on("fotorama:ready", function() {
i = $(e.$els.galleryClone).find(".fotorama__stage__shaft"), i.on("click.shaft", function() {
e.showGallery()
})
}), $(this.$els.galleryClone).on("fotorama:show", function(e, t) {
i && i.off("click.shaft")
}), $(this.$els.galleryClone).on("fotorama:showend", function() {
i && i.on("click.shaft", function() {
e.showGallery()
})
}), $(this.$els.galleryClone).fotorama(t)
}, e.prototype._destroyFotorama = function() {
this.$els.galleryClone && $(this.$els.galleryClone).data("fotorama") && $(this.$els.galleryClone).data("fotorama").destroy()
}, e.prototype._getOpenGraph = function() {
var e = this,
t = new m["default"],
i = "",
r = this.$request().getContext("Geo"),
a = r.getCities();
i = r.inCitySearchContext() && a.length ? a[0].name_ru : r.getParam("region.name_ru");
var n = this.offer.getFullTitle("гараж") + ", ";
n += this.$options.filters.spaces(this.offer.param("params.price")) + " руб. — N1 " + i, t.addType("website"), t.addTitle(n);
var o = [];
if (this.offer.has("params.city.name_ru") ? o.push(this.offer.param("params.city.name_ru")) : o.push(this.offer.param("params.region.name_ru")), this.offer.has("params.street.name_ru")) {
var s = this.offer.getStreetWithAbbr();
this.offer.has("params.house_number") && (s += ", д. " + this.offer.param("params.house_number")), o.push(s)
}
if (this.offer.has("params.total_area")) {
var l = this.offer.param("params.total_area") / 100;
o.push("Общая площадь - " + this.$options.filters.typographyDivider(l) + " м2")
}
t.addDescription(o.join(", "));
var c = this.$request().getProtocol(),
p = "";
return p = this.offer.has("params.city.params.domain") ? this.offer.param("params.city.params.domain") : this.offer.param("params.region.params.domain"), t.addUrl(c + "://" + p + this.offer.getUrl()), this.offer.hasPhotos() && this.offer.param("photos").forEach(function(i) {
var r = e.$getPhotoUrl(i.url_mask, 1200, 800, !1);
t.addImage(r).addCustomTag("link", {
rel: "image_src",
href: r
})
}), {
openGraph: t.build()
}
}, n(e, [{
key: "dealParams",
get: function() {
return this.offer.getParams({
is_haggle: "Торг",
is_pawn: "В залоге",
is_deposit: "Внесен задаток"
})
}
}, {
key: "locationTitle",
get: function() {
var e = this.offer.getParams({
"district.name_ru": this.offer.param("params.district.name_ru"),
"microdistrict.name_ru": this.offer.param("params.microdistrict.name_ru"),
"garage_cooperative.title": this.offer.param("params.garage_cooperative.title")
});
return !this.offer.hasCityInTitle() && this.offer.has("params.city.name_ru") && e.unshift(this.offer.param("params.city.name_ru")), e.join(", ")
}
}, {
key: "defaultEmailMessage",
get: function() {
return g["default"](this.offer)
}
}, {
key: "galleryPhotos",
get: function() {
return this.offer.hasPhotos() ? y["default"](this.offer.param("photos"), [1200, 800], [70, 70]) : []
}
}, {
key: "hasGarageParams",
get: function() {
return this.offer.hasParams(["total_area", "has_cellar", "has_looking_hole"])
}
}, {
key: "hasMap",
get: function() {
var e = this.offer.has("params.house_number"),
t = this.offer.has("params.street.name_ru");
return this.offer.hasLocation() || this.offer.has("params.city.name_ru") && t || !t && this.offer.param("params.city.rank") > 3 && e
}
}], [{
key: "styles",
value: i(1597)(o.asset("./styles/card-garages-content.scss")),
enumerable: !0
}, {
key: "template",
value: i(1597)(o.asset("./templates/card-garages-content.jade")),
enumerable: !0
}, {
key: "props",
value: {
offer: {
required: !0
},
isDiscarded: {
type: Boolean,
required: !0
},
isFavorite: {
type: Boolean,
required: !0
}
},
enumerable: !0
}, {
key: "filters",
value: {
divide: i(23),
spaces: i(20),
typographyDivider: i(777)
},
enumerable: !0
}, {
key: "components",
value: {
breadcrumbs: i(1490),
contacts: i(1495),
costSubscription: i(1503),
description: i(1508),
favoriteSwitcher: i(677),
map: i(1599),
sideBanners: i(1528),
similarOffers: i(1610),
shareLink: i(1533)
},
enumerable: !0
}, {
key: "partials",
value: {
actions: i(1597)(o.asset("./templates/partials/card-garages-content-actions.jade")),
contacts: i(1597)(o.asset("./templates/partials/card-garages-content-contacts.jade")),
dealParams: i(1597)(o.asset("./templates/partials/card-garages-content-deal-params.jade")),
header: i(1597)(o.asset("./templates/partials/card-garages-content-header.jade")),
location: i(1597)(o.asset("./templates/partials/card-garages-content-location.jade")),
media: i(1597)(o.asset("./templates/partials/card-garages-content-media.jade")),
params: i(1597)(o.asset("./templates/partials/card-garages-content-params.jade")),
price: i(1597)(o.asset("./templates/partials/card-garages-content-price.jade"))
},
enumerable: !0
}, {
key: "_gallery",
value: null,
enumerable: !0
}]);
var t = e;
return e = o.ComponentVue(e) || e
}();
t["default"] = x, e.exports = t["default"]
}, function(e, t) {
"use strict";
function i(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var r = function() {
function e(t, r) {
i(this, e), this._offer = t, this._domain = r, this._cityUrl = this._getCityUrl(), this._basePart = this._getBasePart()
}
return e.prototype.getCityCrumb = function() {
if (!this._cityUrl) return null;
var e = this._cityUrl,
t = "Недвижимость";
return "rent_out" === this._offer.param("deal_type") && (e += "snyat/", t = "Аренда"), t += this._offer.has("params.city.grammatical_cases_ru.locative") ? " в " + this._offer.param("params.city.grammatical_cases_ru.locative") : ", " + this._offer.param("params.city.name_ru"), {
url: e,
title: t
}
}, e.prototype.getRubricCrumb = function() {
return this._cityUrl ? {
url: "" + this._cityUrl + this._basePart.url + "/",
title: this._basePart.title
} : null
}, e.prototype.getGeoCrumb = function(e) {
return this._cityUrl && e ? {
url: "" + this._cityUrl + this._basePart.url + "/" + e.url + "/",
title: e.title
} : null
}, e.prototype.getBreadcrumbs = function() {
var e = [],
t = this.getCityCrumb();
t && e.push(t);
var i = this.getRubricCrumb();
i && e.push(i);
var r = this.getGeoCrumb(this._getDistrict());
r && e.push(r);
var a = this.getGeoCrumb(this._getMicrodistrict());
a && e.push(a);
var n = this.getGeoCrumb(this._getStreet());
n && e.push(n);
var o = this.getGeoCrumb(this._getType());
o && e.push(o);
var s = this.getGeoCrumb(this._getGsk());
return s && e.push(s), e
}, e.prototype._getCityUrl = function() {
if (!this._offer.has("params.city")) return null;
var e = "/";
return this._offer.has("params.city.params.domain") ? this._offer.param("params.city.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.city.params.domain") + "/") : (this._offer.param("params.region.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.region.params.domain") + "/"), this._offer.has("params.city.name_translit") && (e += "city-" + this._offer.param("params.city.name_translit") + "/")), e
}, e.prototype._getBasePart = function() {
var e = ["garazhi"],
t = "Гаражи, парковки";
return "rent_out" === this._offer.param("deal_type") && (e.unshift("snyat"), t = "Аренда гаражей, парковок"), {
title: t,
url: e.join("/")
}
}, e.prototype._getDistrict = function() {
return this._offer.has("params.district.name_translit") && this._offer.has("params.district.name_ru") ? {
title: this._offer.param("params.district.name_ru"),
url: "district-" + this._offer.param("params.district.name_translit")
} : null
}, e.prototype._getMicrodistrict = function() {
return this._offer.has("params.microdistrict.name_translit") && this._offer.has("params.microdistrict.name_ru") ? {
title: "мкр. " + this._offer.param("params.microdistrict.name_ru"),
url: "microdistrict-" + this._offer.param("params.microdistrict.name_translit")
} : null
}, e.prototype._getStreet = function() {
if (!this._offer.has("params.street.name_translit") || !this._offer.has("params.street.name_ru")) return null;
var e = "ул" === this._offer.param("params.street.abbr_raw_ru") ? "ул. " : "";
return {
title: "" + e + this._offer.param("params.street.name_ru"),
url: "street-" + this._offer.param("params.street.name_translit")
}
}, e.prototype._getType = function() {
if (!this._offer.param("params.type")) return null;
var e = {
fundamental_garage: "type-kapitalniy",
parking_place: "type-parkovka",
metal_garage: "type-metallicheskiy",
vegetable_store: "type-ovoschehranilische"
},
t = e[this._offer.param("params.type.value")];
if (!t) return null;
var i = this._offer.param("params.type.title");
return this._offer.has("params.type.grammatical_cases_plural.nominative") && (i = this._offer.param("params.type.grammatical_cases_plural.nominative")), i = i[0].toUpperCase() + i.slice(1), {
title: i,
url: t
}
}, e.prototype._getGsk = function() {
return this._offer.has("params.garage_cooperative.title_seo") && this._offer.param("params.garage_cooperative.title") ? {
title: this._offer.param("params.garage_cooperative.title"),
url: "gsk-" + this._offer.param("params.garage_cooperative.title_seo")
} : null
}, e
}();
t["default"] = r, e.exports = t["default"]
}, function(e, t) {
"use strict";
function i(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var r = function() {
function e(t, r) {
i(this, e), this._offer = t, this._domain = r, this._cityUrl = this._getCityUrl(), this._basePart = this._getBasePart(), this._type = this._getType()
}
return e.prototype.getGeoLink = function(e, t) {
if (!this._cityUrl || !this._type || !t) return null;
var i = [this._basePart, this._type.url, t.url];
return {
name: e,
url: "" + this._cityUrl + i.join("/") + "/",
title: this._type.title + t.title
}
}, e.prototype.getLinks = function() {
var e = [],
t = this.getGeoLink("district", this._getDistrict());
t && e.push(t);
var i = this.getGeoLink("microdistrict", this._getMicrodistrict());
i && e.push(i);
var r = this.getGeoLink("street", this._getStreet());
r && e.push(r);
var a = this.getGeoLink("gsk", this._getGsk());
return a && e.push(a), e
}, e.prototype._getCityUrl = function() {
if (!this._offer.has("params.city")) return null;
var e = "/";
return this._offer.has("params.city.params.domain") ? this._offer.param("params.city.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.city.params.domain") + "/") : (this._offer.param("params.region.params.domain") !== this._domain && (e = "http://" + this._offer.param("params.region.params.domain") + "/"), this._offer.has("params.city.name_translit") && (e += "city-" + this._offer.param("params.city.name_translit") + "/")), e
}, e.prototype._getBasePart = function() {
var e = ["garazhi"];
return "rent_out" === this._offer.param("deal_type") && e.unshift("snyat"), e.join("/")
}, e.prototype._getType = function() {
if (!this._offer.param("params.type")) return null;
var e = {
fundamental_garage: "type-kapitalniy",
parking_place: "type-parkovka",
metal_garage: "type-metallicheskiy",
vegetable_store: "type-ovoschehranilische"
},
t = e[this._offer.param("params.type.value")];
if (!t) return null;
var i = "";
return i = this._offer.has("params.type.grammatical_cases_plural.nominative") ? this._offer.param("params.type.grammatical_cases_plural.nominative") : this._offer.param("params.type.title"), i = "rent_out" === this._offer.param("deal_type") ? "Снять " + i[0].toLowerCase() + i.slice(1) : i[0].toUpperCase() + i.slice(1), {
title: i,
url: t
}
}, e.prototype._getDistrict = function() {
if (!this._offer.has("params.district.name_translit")) return null;
var e = "";
return e = this._offer.has("params.district.grammatical_cases_ru.locative") ? " " + this._offer.param("params.district.grammatical_cases_ru.locative") : ", " + this._offer.param("params.district.name_ru"), {
title: e,
url: "district-" + this._offer.param("params.district.name_translit")
}
}, e.prototype._getMicrodistrict = function() {
return this._offer.has("params.microdistrict.name_translit") ? {
title: " в микрорайоне " + this._offer.param("params.microdistrict.name_ru"),
url: "microdistrict-" + this._offer.param("params.microdistrict.name_translit")
} : null
}, e.prototype._getStreet = function() {
if (!this._offer.has("params.street.name_translit")) return null;
var e = "";
return this._offer.has("params.street.abbr_raw_ru") && this._offer.has("params.street.name_raw_ru") ? (e = this._offer.param("params.street.abbr_raw_ru") + ". " + this._offer.param("params.street.name_raw_ru"), e = "мкр" === this._offer.param("params.street.abbr_raw_ru") ? " в " + e : " на " + e) : e = ", " + this._offer.param("params.street.name_ru"), {
title: e,
url: "street-" + this._offer.param("params.street.name_translit")
}
}, e.prototype._getGsk = function() {
return this._offer.has("params.garage_cooperative.title_seo") && this._offer.param("params.garage_cooperative.title") ? {
title: ", " + this._offer.param("params.garage_cooperative.title"),
url: "gsk-" + this._offer.param("params.garage_cooperative.title_seo")
} : null
}, e
}();
t["default"] = r, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
t.__esModule = !0, t["default"] = function(e, t, r) {
for (var a = i(113)(rawData.config), n = [], o = 0; o < e.length; o++) e[o].type && "video" === e[o].type ? n[o] = {
type: "iframe",
img: e[o].link,
href: e[o].link,
thumb: e[o].thumb,
title: ""
} : n[o] = {
img: a(e[o].url_mask, t[0], t[1], !1),
href: a(e[o].url_mask, t[0], t[1], !1),
thumb: a(e[o].url_mask, r[0], r[1], !0),
title: e[o].description
};
return n
}, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./CardGaragesContent": 1593,
"./CardGaragesContent.js": 1593,
"./Map/ButtonsConfig": 1598,
"./Map/ButtonsConfig.js": 1598,
"./Map/Map": 1599,
"./Map/Map.js": 1599,
"./Map/styles/card-garages-map.scss": 1603,
"./Map/templates/card-garages-map.jade": 1605,
"./Map/templates/partials/card-garages-map-dummy.jade": 1606,
"./Map/templates/partials/card-garages-map-footer.jade": 1607,
"./Map/templates/partials/card-garages-map-header.jade": 1608,
"./Map/templates/partials/card-garages-map-item.jade": 1609,
"./SimilarGarages/SimilarGarages": 1610,
"./SimilarGarages/SimilarGarages.js": 1610,
"./SimilarGarages/Slider/Item/Item": 1614,
"./SimilarGarages/Slider/Item/Item.js": 1614,
"./SimilarGarages/Slider/Item/styles/similar-garages-item.scss": 1616,
"./SimilarGarages/Slider/Item/templates/similar-garages-item.jade": 1618,
"./SimilarGarages/Slider/Slider": 1619,
"./SimilarGarages/Slider/Slider.js": 1619,
"./SimilarGarages/Slider/styles/similar-garages-slider.scss": 1621,
"./SimilarGarages/Slider/templates/similar-garages-slider.jade": 1623,
"./SimilarGarages/styles/similar-garages.scss": 1624,
"./SimilarGarages/templates/partials/similar-garages-dummy.jade": 1626,
"./SimilarGarages/templates/partials/similar-garages-links.jade": 1627,
"./SimilarGarages/templates/similar-garages.jade": 1628,
"./styles/card-garages-content.scss": 1629,
"./templates/card-garages-content.jade": 1631,
"./templates/partials/card-garages-content-actions.jade": 1632,
"./templates/partials/card-garages-content-contacts.jade": 1633,
"./templates/partials/card-garages-content-deal-params.jade": 1634,
"./templates/partials/card-garages-content-header.jade": 1635,
"./templates/partials/card-garages-content-location.jade": 1636,
"./templates/partials/card-garages-content-media.jade": 1637,
"./templates/partials/card-garages-content-params.jade": 1638,
"./templates/partials/card-garages-content-price.jade": 1639
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1597
}, function(e, t) {
"use strict";
t.__esModule = !0, t["default"] = function() {
return [{
name: "shop",
active: !1,
visible: !0,
title: "Магазины",
targetName: "mall"
}, {
name: "similar",
active: !1,
visible: !0,
title: "Похожие объявления"
}]
}, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
o = i(145),
s = i(480),
l = r(s),
c = i(1421),
p = r(c),
d = i(1600),
u = r(d),
f = i(1438),
m = r(f),
h = i(1450),
g = r(h),
_ = i(1601),
y = r(_),
b = i(1598),
v = r(b),
x = i(117),
w = r(x),
M = function() {
function e() {
a(this, t), this.isVisibleDummy = !0, this.similar = {
offers: [],
urlQuery: ""
}, this.view = "map", this.hasPanorama = !1, this.panoramaInited = !1
}
e.prototype.ready = function() {
var e = this;
this._initMap(), this._getData().then(function(t) {
e.similar.offers = w["default"].get(t, "offers.result", []), e._location = t.map.location, e._zoom = t.map.zoom, e._initOfferStore(), e._initOverlays(), e._initButtons(), e.isVisibleDummy = !1, e._initOffer(), e._initSimilarOffers()
}).then(function() {
e._initInfrastructure()
})["catch"](this.$logError)
}, e.prototype._getData = function() {
var e = {
map: this._getDataMap()
},
t = new y["default"](this.offer),
i = t.getApiQuery();
return i && (e.offers = this.$service("OffersSearch").search(i), this.similar.urlQuery = t.getOffersUrlQuery()), this.$runPromises(e)
}, e.prototype._getDataMap = function() {
var e = this;
return this._map.init(this.$resource().getConfig("version")).then(function() {
return e.offer.hasLocation() ? {
location: e.offer.param("params.location"),
zoom: 16
} : e._getDataByAddress()
}).then(function(t) {
return e._map.addOption("zoomFullLoad", t.zoom), e._map.onFullScreenChange(function() {
var t = e._map.isFullScreen();
t ? $("body").addClass("_fit-window-height") : $("body").removeClass("_fit-window-height"), e.$root.view.fitWindowHeightMode = t
}), t
})
}, e.prototype._getDataByAddress = function() {
return this._map.findByAddress(this.address).then(function(e) {
var t = {
house: 16,
street: 14
},
i = t[e.kind];
return {
location: {
lat: e.location[0],
lon: e.location[1]
},
zoom: i ? i : 11
}
})
}, e.prototype._getOverlayByButtonName = function(e) {
return "similar" === e ? this._overlays : this._infrastructure
}, e.prototype._initMap = function() {
this._map = new l["default"](this.$els.map, {
layers: {
sputnik: !0
},
layersButton: !0,
fullscreen: !0,
leafletOptions: {
touchZoom: !0,
scrollWheelZoom: !1,
fullscreenControl: !0,
fullscreenPseudo: !0
},
plugins: {
markercluster: !0,
draw: !1
}
})
}, e.prototype._initOfferStore = function() {
this._offerStore = new u["default"]({
logger: this.$resources().getLogger(),
map: this._map.getOriginalMap(),
vueFilters: this.$options.filters,
services: this.$service(),
getPhotoUrl: this.$getPhotoUrl,
popupSelector: this._popup.selector
}), this._map.addOption("offerStore", this._offerStore)
}, e.prototype._initOverlays = function() {
this._overlays = new p["default"](this._map), this._overlays.add("similar", this._offerStore.getLayer()), this._overlays.hide("similar")
}, e.prototype._initButtons = function() {
var e = this.$user().getLocalSettings().getValue(this._cookieName, this._activeButtons);
w["default"].each(this.buttons, function(t) {
t.active = w["default"].includes(e, t.name)
})
}, e.prototype._initOffer = function() {
var e = new L.Marker([this._location.lat, this._location.lon], {
icon: L.icon({
className: ".card-garages-map__pin-icon",
iconUrl: "/static/img/Public/icon-map-pin-main.png",
iconSize: [36, 46],
iconAnchor: [18, 46]
})
});
this._map.addLayer(e), this._map.setView(this._location, this._zoom)
}, e.prototype._initSimilarOffers = function() {
var e = this;
this.similar.offers.length && (this._offerStore.addOffers(this.similar.offers), this._offerStore.events.on("openCard", function(t) {
e._openCard(t)
}), this._offerStore.events.on("renderCard", function(t, i) {
e._renderCard(t, i)
}), this._offerStore.events.on("renderCards", function(t, i) {
e._renderCards(t, i)
}))
}, e.prototype._initInfrastructure = function() {
var e = this,
t = {
map: this._map.getOriginalMap()
},
i = {
types: g["default"]
};
this._infrastructure = new m["default"](t, i), this._map.addOption("infrastructure", this._infrastructure), this._infrastructure.loadInPointRadius(this._location, {
loadAllTypes: !0,
showOnMap: !1
}).then(function(t) {
w["default"].each(e.buttons, function(i) {
i.visible = Boolean("similar" === i.name && e.similar.offers.length || w["default"].includes(t, i.name));
var r = e._getOverlayByButtonName(i.name);
i.visible && i.active && r.show(i.name)
})
})["catch"](this.$logError)
}, e.prototype._initPanorama = function() {
var e = this;
this.hasPanorama = !0;
var t = document.createElement("script"),
i = document.getElementsByTagName("head")[0];
"undefined" == typeof google ? (t.onload = t.onreadystatechange = function() {
t.readyState && "loaded" !== t.readyState && "complete" !== t.readyState || google.load("maps", "3", {
callback: e._setPanorama
})
}, t.setAttribute("type", "text/javascript"), t.setAttribute("src", "https://www.google.com/jsapi"), i.appendChild(t)) : this.panoramaInited || this._setPanorama()
}, e.prototype._setPanorama = function() {
var e = this;
this.panoramaInited = !0;
var t = new google.maps.LatLng(this._location.lat, this._location.lon),
i = new google.maps.StreetViewService,
r = 100;
i.getPanoramaByLocation(t, r, function(i, r) {
var a = w["default"].get(i, "location.latLng", !1);
if (r === google.maps.StreetViewStatus.OK && a) {
var n = {
position: i.location.latLng,
pov: {
heading: google.maps.geometry.spherical.computeHeading(i.location.latLng, t),
pitch: 0
}
};
new google.maps.StreetViewPanorama(e.$els.panorama, n)
} else e.hasPanorama = !1
})
}, e.prototype._openCard = function(e) {
var t = window.location.protocol + "//" + window.location.hostname;
t += "/view/" + e + "/?offer_similar_garages_variant_inf&open_card_garages", window.open(t)
}, e.prototype._renderCard = function(e, t) {
var i = document.createElement("div");
i.innerHTML = this._popup.header + this._popup.item, this.offerVm = new Vue({
el: i,
data: {
properties: e.offerView,
id: e.offerView.id,
count: 1
},
filters: this.$options.filters
}), t(null, i.innerHTML)
}, e.prototype._renderCards = function(e, t) {
var i = w["default"].last(e.offerViews),
r = document.createElement("div");
r.innerHTML = this._popup.header, new Vue({
el: r,
data: {
properties: i
}
});
var a = r.innerHTML,
n = document.createElement("div");
n.innerHTML = this._popup.item;
var o = new Vue({
el: n,
data: {
properties: {},
id: ""
},
filters: this.$options.filters
});
if (w["default"].each(e.offerViews, function(e) {
o.properties = e, o.id = e.item.id, a += n.innerHTML
}), e.linkMore) {
var s = w["default"].get(i.item, "params.street.id", null);
s && (this.similar.urlQuery.query.street = s);
var l = w["default"].get(i.item, "params.house_number", null);
l && (this.similar.urlQuery.query.house_number = l);
var c = document.createElement("div");
c.innerHTML = this._popup.footer, new Vue({
el: c,
data: {
url: this.similar.urlQuery.path + "?" + $.param(this.similar.urlQuery.query),
count: e.count
},
filters: this.$options.filters
}), a += c.innerHTML
}
t(null, a)
}, e.prototype._saveActiveButtons = function() {
var e = this.buttons.filter(function(e) {
return e.active
});
this._activeButtons = w["default"].map(e, function(e) {
return e.name
}), this.$user().getLocalSettings().setValue(this._cookieName, this._activeButtons)
}, e.prototype.onToggleOverlay = function(e) {
var t = w["default"].find(this.buttons, function(t) {
return t.name === e
});
t.active = !t.active;
var i = this._getOverlayByButtonName(t.name);
t.active ? i.show(t.name) : i.hide(t.name), this._saveActiveButtons()
}, e.prototype.onSetView = function(e) {
this.view = e, this.panoramaInited || this._initPanorama()
}, e.prototype.beforeDestroy = function() {
this._map && this._map.destroy()
}, n(e, [{
key: "buttons",
get: function() {
return v["default"]()
}
}, {
key: "address",
get: function() {
var e = [];
return this.offer.has("params.region.name_ru") && e.push(this.offer.param("params.region.name_ru")), this.offer.has("params.city.name_ru") && e.push(this.offer.param("params.city.name_ru")), this.offer.has("params.street.name_ru") && e.push(this.offer.param("params.street.name_ru")), this.offer.has("params.house_number") && e.push(this.offer.param("params.house_number")), e.join(", ")
}
}, {
key: "gisLink",
get: function() {
if (!this.offer.hasLocation()) return null;
var e = "https://2gis.ru/to/";
return e += this.offer.param("params.location.lon") + "," + this.offer.param("params.location.lat") + "?", this.offer.has("params.street.name_ru") && this.offer.has("params.house_number") && (e += this.offer.param("params.street.name_ru") + ", ", e += encodeURIComponent(this.offer.param("params.house_number")) + "/?"), e += "?queryState=center/" + this.offer.param("params.location.lon") + ",", e += this.offer.param("params.location.lat") + "/zoom/15/routeTab"
}
}], [{
key: "styles",
value: i(1602)(o.asset("./styles/card-garages-map.scss")),
enumerable: !0
}, {
key: "template",
value: i(1602)(o.asset("./templates/card-garages-map.jade")),
enumerable: !0
}, {
key: "components",
value: {
preloader: i(405)
},
enumerable: !0
}, {
key: "partials",
value: {
dummy: i(1602)(o.asset("./templates/partials/card-garages-map-dummy.jade"))
},
enumerable: !0
}, {
key: "props",
value: {
offer: {
required: !0
}
},
enumerable: !0
}, {
key: "_popup",
value: {
header: i(1602)(o.asset("./templates/partials/card-garages-map-header.jade")),
item: i(1602)(o.asset("./templates/partials/card-garages-map-item.jade")),
footer: i(1602)(o.asset("./templates/partials/card-garages-map-footer.jade")),
selector: ".card-garages-map-item"
},
enumerable: !0
}, {
key: "_map",
value: null,
enumerable: !0
}, {
key: "_offerStore",
value: null,
enumerable: !0
}, {
key: "_overlays",
value: null,
enumerable: !0
}, {
key: "_infrastructure",
value: null,
enumerable: !0
}, {
key: "_activeButtons",
value: ["shop", "similar"],
enumerable: !0
}, {
key: "_location",
value: null,
enumerable: !0
}, {
key: "_zoom",
value: null,
enumerable: !0
}, {
key: "_cookieName",
value: "GARAGES_MAP_BUTTONS",
enumerable: !0
}]);
var t = e;
return e = o.ComponentVue(e) || e
}();
t["default"] = M, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = i(1423),
o = r(n),
s = i(15),
l = r(s),
c = i(117),
p = r(c),
d = function() {
function e(t) {
var i = this;
a(this, e);
var r = ["map", "vueFilters", "services", "getPhotoUrl"];
if (!p["default"].keys(p["default"].pick(t, r)).length) throw new Error("[GaragesOfferStore] обязательные options для конструктора: " + r.join(","));
this.events = new o["default"], this._map = t.map, this._vueFilters = t.vueFilters, this._services = t.services, this._getPhotoUrl = t.getPhotoUrl, this._popupSelector = t.popupSelector, this._offers = {}, this._count = 0, this._zoomFullLoad = this._map.options.zoomFullLoad, L.Icon.Default.imagePath = "/static/img/leaflet", this._group = L.markerClusterGroup({
clusterType: "offers",
maxClusterRadius: function(e) {
return e >= i._zoomFullLoad ? 20 : 40
},
removeOutsideVisibleBounds: !0,
animateAddingMarkers: !1,
polygonOptions: {
fillColor: "#000"
},
singleMarkerMode: !0,
zoomToBoundsOnClick: !0,
iconCreateFunction: function(e) {
var t, r = e.getChildCount(),
a = "",
n = "";
if (e._zoom && e._zoom >= i._zoomFullLoad) n = "ymap-offer-pin-group", t = new L.Point(40, 40), a = '
' + r + "
";
else {
n = "ymap-offer-pin-cluster", t = {
x: 50,
y: 50
};
var o = String(r).length;
switch (o) {
case 1:
n += " _digit1", t = {
x: 30,
y: 30
};
break;
case 2:
n += " _digit2", t = {
x: 40,
y: 40
};
break;
case 3:
n += " _digit3", t = {
x: 50,
y: 50
};
break;
case 4:
default:
n += " _digit4", t = {
x: 60,
y: 60
}
}
t = new L.Point(t.x, t.y), a = '
' + r + "
"
}
return 1 == r && (a = '', n = "ymap-offer-pin", t = new L.Point(40, 40)), new L.DivIcon({
html: a,
className: n,
iconSize: t
})
}
}), this._group.addTo(this._map), this._map.on("popupopen", function(e) {
var t = $(e.popup._container),
r = $(e.target._container),
a = {
height: r.height(),
width: r.width()
};
e.popup._container.className = e.popup._container.className.replace(/ _reposition-right| _reposition-left| _reposition-bottom/g, "");
var n = i._map.latLngToContainerPoint(e.popup.getLatLng()),
o = {
height: t.height(),
width: t.width(),
offset: {}
};
o.offset.top = function() {
return n.y - o.height
}, o.offset.left = function() {
return n.x - o.width / 2
};
var s = function() {
var t = n.x + o.width / 2 + 8,
r = n.y + o.height / 2,
a = [t, r];
e.popup.setLatLng(i._map.containerPointToLatLng(a)), e.popup._container.className += " _reposition-right"
},
l = function() {
var t = n.x - o.width / 2 - 6,
r = n.y + o.height / 2,
a = [t, r];
e.popup.setLatLng(i._map.containerPointToLatLng(a)), e.popup._container.className += " _reposition-left"
},
c = function() {
var t = n.x,
r = n.y + o.height + 8,
a = [t, r];
e.popup.setLatLng(i._map.containerPointToLatLng(a)), e.popup._container.className += " _reposition-bottom"
};
if (o.offset.left() < 0) return void s();
if (o.offset.left() + o.width > a.width) return void l();
if (o.offset.top() < 0) {
var p = a.height - n.y,
d = n.y,
u = d >= o.height / 2 && p >= o.height / 2;
return u ? o.offset.left() < 0 ? void s() : o.offset.left() + o.width > a.width ? void l() : void(.7 > d / p && c()) : void(.7 > d / p && c())
}
e.popup.setLatLng(i._map.containerPointToLatLng([n.x, n.y - 8]))
})
}
return e.prototype.getLayer = function() {
return this._group
}, e.prototype.addOffers = function(e) {
var t = this;
p["default"].each(e, function(e) {
t.hasOffer(e._id) || t.createMarker(e)
})
}, e.prototype.hasOffer = function(e) {
return !!this._offers[e]
}, e.prototype.getCount = function() {
return this._count
}, e.prototype.getCountInBounds = function() {
var e = 0,
t = this._map.getBounds();
return p["default"].each(this._offers, function(i) {
i.marker && i.marker.getLatLng && t.contains(i.marker.getLatLng()) && e++
}), e
}, e.prototype.getOffer = function(e) {
return this._offers[e] ? this._offers[e] : !1
}, e.prototype.createMarker = function(e) {
var t = this;
if (!e.params || !e.params.location) return !1;
if (!e.params.location.lat || !e.params.location.lat) return !1;
var i = e._id;
this._offers[i] = this.createOfferBlank(e._id, [e.params.location.lat, e.params.location.lon]);
var r = this,
a = function(e) {
if (e.target.options.id) {
var i = e.target.options.id,
a = r.getOffer(i);
if (a) return a.popup ? ("mouseover" == e.type && a.marker.openPopup(), void setTimeout(function() {
r.initPopupBehaviour(e)
}, 0)) : void r.getOfferInfo(i, function(i, n) {
if (!i) {
var o = r.buildOfferViewData(n),
s = {
offerView: o
};
t.events.emit("renderCard", s, function(t, i) {
a.popup = L.popup({
closeButton: !1,
autoPan: !1,
minWidth: 200,
maxWidth: 400
}).setContent(i), a.marker.bindPopup(a.popup).openPopup(), r.bindPopupClose(e), r.initPopupBehaviour(e)
})
}
})
}
};
return this._offers[i].marker = L.marker(this._offers[i].location, {
id: i,
params: e.params
}).addTo(this._group).on("click", function(e) {
var i = e.target.options.id;
t.events.emit("openCard", i)
}).on("mouseover", function(e) {
e.target.options.timeout = setTimeout(function() {
delete e.target.options.timeout, a(e)
}, 150)
}).on("mouseout", function(e) {
return !e.target._map.hasLayer(e.target._popup) && e.target.options.timeout ? void clearTimeout(e.target.options.timeout) : void delete e.target.options.timeout
}), this._count++, this._offers[i]
}, e.prototype.bindPopupClose = function(e) {
$(e.target._popup._container).on("mouseleave.custom", function() {
setTimeout(function() {
e.target.closePopup()
}, 0)
})
}, e.prototype.initPopupBehaviour = function(e) {
var t = this;
if (e.target._popup)
for (var i = e.target._popup._contentNode, r = i.querySelectorAll(this._popupSelector), a = 0; a < r.length; a++) ! function(e, i) {
$(e).off("click").on("click", function() {
var e = this.getAttribute("data-id");
t.events.emit("openCard", e)
})
}(r[a])
}, e.prototype.getOfferViewData = function(e, t) {
var i = this;
this.getOfferInfo(e, function(e, r) {
return e ? void t(e) : void t(null, i.buildOfferViewData(r))
})
}, e.prototype.getOfferViewDataBulk = function(e) {
var t = this;
return new l["default"](function(i, r) {
var a = [];
if (p["default"].each(e, function(e) {
var i = t.getOffer(e);
i.info || a.push(e)
}), 0 == a.length) {
var n = [];
return p["default"].each(e, function(e) {
var i = t.getOffer(e);
n.push(t.buildOfferViewData(i.info))
}), void i(n)
}
var o = t._services.getOffersSearch().getQuery({
query: [{
ids: a
}]
});
t._services.getOffersSearch().search(o).then(function(r) {
var a = [];
r.result && (p["default"].each(r.result, function(e) {
var i = t.getOffer(e.id);
i.info = e
}), p["default"].each(e, function(e) {
var i = t.getOffer(e);
a.push(t.buildOfferViewData(i.info))
})), i(a)
})["catch"](function(e) {
r(e)
})
})
}, e.prototype.buildOfferViewData = function(e) {
var t = new Vue({
data: {
offer: e
},
filters: this._vueFilters
}),
i = null;
p["default"].get(e, "photos[0].url_mask") && this._getPhotoUrl && (i = this._getPhotoUrl(e.photos[0].url_mask, 80, 60, !0));
var r = null;
p["default"].get(e, "params.rent_period") && (r = "/мес.");
var a = null;
p["default"].get(e, "params.total_area") && (a = t.$interpolate("{{offer.params.total_area | divide 100 | floor}}"));
var n = p["default"].get(e, "params.city.name_ru", null),
o = p["default"].get(e, "params.street.name_ru", null),
s = p["default"].get(e, "params.house_number", null),
l = "";
return o ? l = o : n && p["default"].get(e, "params.city.rank", 0) > 3 && (l = n), l && s && (l += ", " + s), {
id: e.id,
item: e,
photo: i,
price: t.$interpolate("{{offer.params.price | spaces}}"),
rent_period: r,
title: p["default"].get(e, "params.type.title", null),
total_area: a,
address: l,
garage_cooperative: p["default"].get(e, "params.garage_cooperative.title", null)
}
}, e.prototype.getGroupPopupContent = function(e, t) {
var i = this,
r = 2,
a = p["default"].pluck(e, "options.id").slice(0, r);
if (!a) return void t(null, null);
var n = e.length,
o = n > r;
this.getOfferViewDataBulk(a).then(function(e) {
var r = {
offerViews: e,
count: n,
linkMore: o
};
i.events.emit("renderCards", r, function(e, i) {
t(null, {
type: "offers",
html: i,
ids: a
})
})
})["catch"](function(e) {
t(e)
})
}, e.prototype.getOfferInfo = function(e, t) {
var i = this,
r = this,
a = r.getOffer(e);
if (a.info) return void t(null, a.info);
var n = this._services.getOffersSearch().getQuery({
id: e
});
this._services.getOffersSearch().get(n).then(function(e) {
a || (a = i.createMarker(e.result)), a.info = e.result, t(null, a.info)
})["catch"](function(e) {
t(e)
})
}, e.prototype.createOfferBlank = function(e, t) {
return {
id: e,
location: t,
info: null,
view: null,
marker: null,
popup: null
}
}, e.prototype.clear = function() {
this._offers = {}, this._count = 0, this._group.clearLayers()
}, e.prototype.clearByBounds = function() {
var e = this,
t = this._map.getBounds();
t = t.pad(.5), p["default"].each(this._offers, function(i) {
t.contains(i.marker.getLatLng()) || (e._group.removeLayer(i.marker), e._count--, delete e._offers[i.id])
})
}, e
}();
t["default"] = d, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = i(1411),
o = r(n),
s = i(117),
l = r(s),
c = function() {
function e(t) {
a(this, e), this._offer = t, this._baseQuery = this._getBaseQuery()
}
return e.prototype.getOffersUrlQuery = function() {
return this._baseQuery ? {
path: "/search/",
query: {
rubric: this._baseQuery.rubric,
deal_type: this._baseQuery.deal_type,
price_min: this._baseQuery.filter.price_min,
price_max: this._baseQuery.filter.price_max,
garages_type: this._baseQuery.filter.type,
city: this._baseQuery.filter.city_id
}
} : null
}, e.prototype.getApiQuery = function() {
var e = arguments.length <= 0 || void 0 === arguments[0] ? 20 : arguments[0],
t = this._offer.hasLocation() || this._offer.has("params.microdistrict.id") || this._offer.has("params.district.id") || this._offer.param("params.city.rank", 0) > 3;
if (!this._baseQuery || !t) return null;
var i = l["default"].cloneDeep(this._baseQuery);
return this._offer.hasLocation() ? i.filter.geo_distance = [{
center: [this._offer.param("params.location.lon"), this._offer.param("params.location.lat")],
radius: 2e3
}] : this._offer.has("params.microdistrict.id") ? i.filter.microdistrict = this._offer.param("params.microdistrict.id").toString() : this._offer.has("params.district.id") && (i.filter.district = this._offer.param("params.district.id").toString()), {
limit: e,
sort: "-special,-has_photos,-creation_date",
query: [i]
}
}, e.prototype._getBaseQuery = function() {
return this._offer.has("params.type.value") && this._offer.has("params.city.id") ? {
rubric: this._offer.param("rubric"),
deal_type: this._offer.param("deal_type"),
exclude_ids: [this._offer.getId()],
status: "published",
filter: {
price_min: o["default"](this._offer.param("params.price"), "-30%"),
price_max: o["default"](this._offer.param("params.price"), "+30%"),
type: this._offer.param("params.type.value"),
city_id: this._offer.param("params.city.id").toString()
}
} : null
}, e
}();
t["default"] = c, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./ButtonsConfig": 1598,
"./ButtonsConfig.js": 1598,
"./Map": 1599,
"./Map.js": 1599,
"./styles/card-garages-map.scss": 1603,
"./templates/card-garages-map.jade": 1605,
"./templates/partials/card-garages-map-dummy.jade": 1606,
"./templates/partials/card-garages-map-footer.jade": 1607,
"./templates/partials/card-garages-map-header.jade": 1608,
"./templates/partials/card-garages-map-item.jade": 1609
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1602
}, function(e, t, i) {
var r = i(1604);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, '.card-garages-map{position:relative}.card-garages-map__title{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:36px;line-height:42px;margin:0 0 24px}.card-garages-map__content{position:relative;display:none;height:360px;background:#f2f2f2}.card-garages-map__content._active{display:block}.card-garages-map__preloader{position:absolute;height:100%;width:100%;text-align:center;padding-top:166px}.card-garages-map__text{position:absolute;top:0;right:0;bottom:0;left:0;margin:auto;box-sizing:border-box;padding-top:83px;background:transparent url("/static/img/Public/panorama-cap.png") 50% 0 no-repeat;color:gray;width:250px;height:123px;text-align:center}.card-garages-map__controls{margin:6px 0 0}.card-garages-map__button{margin:12px 12px 0 0}.card-garages-map__pin-icon{cursor:move!important;cursor:-webkit-grab!important;cursor:-o-grab!important;cursor:-ms-grab!important;cursor:grab!important}.card-garages-map .infrastructure-icon{cursor:pointer}.card-garages-map .infrastructure-icon._shop{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.card-garages-map .infrastructure-icon._shop:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjE4cHgiIGhlaWdodD0iMThweCIgdmlld0JveD0iMCAwIDE4IDE4Ij48ZGV2cz48cGF0aCBpZD0iZ3JvY2VyeSIgZD0iTTE0LjUsMy41QzEzLjUsMy41LDEzLDQsMTMsNUgzbDEuMDU5LDZIMTN2MUg0LjgyM2MtMC43NjUsMC0wLjc2NSwwLjc0LDAsMC43NjRoMS4xNDdoNi4xMTdoMS4xNDdDMTMuNjE3LDEyLjc2NCwxNCwxMi4zODMsMTQsMTJ2LTFWNWMwLTAuNSwwLjIzOC0wLjczNSwwLjc2NS0wLjczNUgxNlYzLjVIMTQuNXogTTEyLDEyLjcwNWMtMC42MzMsMC0xLjE0NiwwLjUxNC0xLjE0NiwxLjE0OEMxMC44NTQsMTQuNDg2LDExLjM2NywxNSwxMiwxNXMxLjE0Ni0wLjUxNCwxLjE0Ni0xLjE0NkMxMy4xNDYsMTMuMjE5LDEyLjYzMywxMi43MDUsMTIsMTIuNzA1eiBNNiwxMi43MDVjLTAuNjM0LDAtMS4xNDcsMC41MTQtMS4xNDcsMS4xNDhDNC44NTMsMTQuNDg2LDUuMzY2LDE1LDYsMTVjMC42MzMsMCwxLjE0Ni0wLjUxNCwxLjE0Ni0xLjE0NkM3LjE0NiwxMy4yMTksNi42MzMsMTIuNzA1LDYsMTIuNzA1eiIvPjwvZGV2cz48dXNlIHhsaW5rOmhyZWY9IiNncm9jZXJ5IiBmaWxsPSJub25lIiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjIiLz48dXNlIHhsaW5rOmhyZWY9IiNncm9jZXJ5IiBmaWxsPSIjNzkzRDBFIi8+PC9zdmc+)}.card-garages-map-tabs__item{display:inline-block;vertical-align:bottom;padding:2px 16px 0;cursor:pointer;font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:17px;line-height:24px;color:#000;line-height:38px;border:1px solid #c4c4c4;border-radius:0 3px 0 0;margin:0 -1px 0 0}.card-garages-map-tabs__item:first-child{border-top-left-radius:3px}.card-garages-map-tabs__item._active{cursor:default;padding-top:8px;border-radius:3px 3px 0 0;background-color:#d9d9d9}.card-garages-map-tabs__item._disabled{cursor:default;color:gray}.card-garages-map-link{float:right;margin-top:-36px;box-sizing:border-box;border:none;border-radius:3px;cursor:pointer;font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;text-align:center;transition:background-color .1s ease;background-color:#fff;color:#000;border:1px solid #c4c4c4;height:30px;padding:0 18px;font-size:15px;line-height:30px;padding:0 17px;line-height:28px;line-height:26px;text-decoration:none}.card-garages-map-link:focus{border-color:#000;background-color:#fff}.card-garages-map-link:hover{background-color:#f2f2f2}.card-garages-map-link:active{background-color:#fff}.card-garages-map-link:disabled{color:rgba(0,0,0,.5)}.card-garages-map-link__icon,.card-garages-map-link__text{display:inline-block;vertical-align:middle}.card-garages-map-link__icon{width:12px;height:12px;position:relative;z-index:1;margin-left:6px;opacity:.3}.card-garages-map-link__icon:before{content:"";width:12px;height:12px;background-position:50% 50%;background-size:100% 100%;background-image:url("/svg/go-out.svg?color=000");position:absolute;left:0;top:0;opacity:1}.card-garages-map-button{box-sizing:border-box;border:none;border-radius:3px;cursor:pointer;font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;text-align:center;transition:background-color .1s ease;background-color:#fff;color:#000;border:1px solid #c4c4c4;height:36px;padding:0 18px;font-size:17px;padding:0 17px;line-height:34px;text-decoration:none;display:inline-block;position:relative;-ms-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;padding:0 12px 0 10px}.card-garages-map-button:focus{border-color:#000;background-color:#fff}.card-garages-map-button:hover{background-color:#f2f2f2}.card-garages-map-button:active{background-color:#fff}.card-garages-map-button:disabled{color:rgba(0,0,0,.5)}.card-garages-map-button._active{background:#d9d9d9}.card-garages-map-button__icon{position:relative;top:-2px}.card-garages-map-button__icon._shop{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.card-garages-map-button__icon._shop:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjE4cHgiIGhlaWdodD0iMThweCIgdmlld0JveD0iMCAwIDE4IDE4Ij48ZGV2cz48cGF0aCBpZD0iZ3JvY2VyeSIgZD0iTTE0LjUsMy41QzEzLjUsMy41LDEzLDQsMTMsNUgzbDEuMDU5LDZIMTN2MUg0LjgyM2MtMC43NjUsMC0wLjc2NSwwLjc0LDAsMC43NjRoMS4xNDdoNi4xMTdoMS4xNDdDMTMuNjE3LDEyLjc2NCwxNCwxMi4zODMsMTQsMTJ2LTFWNWMwLTAuNSwwLjIzOC0wLjczNSwwLjc2NS0wLjczNUgxNlYzLjVIMTQuNXogTTEyLDEyLjcwNWMtMC42MzMsMC0xLjE0NiwwLjUxNC0xLjE0NiwxLjE0OEMxMC44NTQsMTQuNDg2LDExLjM2NywxNSwxMiwxNXMxLjE0Ni0wLjUxNCwxLjE0Ni0xLjE0NkMxMy4xNDYsMTMuMjE5LDEyLjYzMywxMi43MDUsMTIsMTIuNzA1eiBNNiwxMi43MDVjLTAuNjM0LDAtMS4xNDcsMC41MTQtMS4xNDcsMS4xNDhDNC44NTMsMTQuNDg2LDUuMzY2LDE1LDYsMTVjMC42MzMsMCwxLjE0Ni0wLjUxNCwxLjE0Ni0xLjE0NkM3LjE0NiwxMy4yMTksNi42MzMsMTIuNzA1LDYsMTIuNzA1eiIvPjwvZGV2cz48dXNlIHhsaW5rOmhyZWY9IiNncm9jZXJ5IiBmaWxsPSJub25lIiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjIiLz48dXNlIHhsaW5rOmhyZWY9IiNncm9jZXJ5IiBmaWxsPSIjNzkzRDBFIi8+PC9zdmc+)}.card-garages-map-button__icon._similar{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.card-garages-map-button__icon._similar:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;border-radius:8px;border:2px solid #fff;background:#c03c40;width:12px;height:12px}.ymap-offer-pin{text-align:center}.ymap-offer-pin:after{content:\'\';display:inline-block;height:100%;vertical-align:middle}.ymap-offer-pin__inner{display:inline-block;vertical-align:middle;border:2px solid #fff;background:#c03c40;border-radius:50%;width:12px;height:12px}.ymap-offer-pin__price{font-size:11px;line-height:18px;font-family:Arial,FreeSans,Geneva CY,Nimbus Sans L,"sans-serif";display:block;border-radius:4px;background:#fafaf9;box-shadow:0 1px 1px rgba(0,0,0,.9)}.ymap-offer-pin-cluster{text-align:center}.ymap-offer-pin-cluster:after{content:\'\';display:inline-block;height:100%;vertical-align:middle}.ymap-offer-pin-cluster__inner{display:inline-block;background:hsla(0,0%,100%,.9);border-radius:50%;border:2px solid rgba(192,60,64,.9);font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:13px;line-height:18px;color:#000;text-align:center;background-clip:padding-box;box-sizing:border-box}.ymap-offer-pin-cluster__inner:after{content:\'\';display:inline-block;height:100%;vertical-align:middle}.ymap-offer-pin-cluster._digit1 .ymap-offer-pin-cluster__inner{width:30px;height:30px}.ymap-offer-pin-cluster._digit2 .ymap-offer-pin-cluster__inner{width:40px;height:40px}.ymap-offer-pin-cluster._digit3 .ymap-offer-pin-cluster__inner{width:50px;height:50px}.ymap-offer-pin-cluster._digit4 .ymap-offer-pin-cluster__inner{width:60px;height:60px}.ymap-offer-pin-cluster__inner span{vertical-align:middle}.ymap-offer-pin-group{text-align:center}.ymap-offer-pin-group:after{content:\'\';display:inline-block;height:100%;vertical-align:middle}.ymap-offer-pin-group__inner{width:20px;height:20px;box-sizing:border-box;display:inline-block;background:#c03c40;border-radius:50%;border:2px solid #fff;font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:10px;line-height:15px;color:#fff;text-align:center}.ymap-offer-pin-group__inner span{vertical-align:top;display:inline-block}.ymap-newhomes-pin{text-align:center}.ymap-newhomes-pin:after{content:\'\';display:inline-block;height:100%;vertical-align:middle}.ymap-newhomes-pin._estate .ymap-newhomes-pin__inner,.ymap-newhomes-pin__inner{display:inline-block;vertical-align:middle;width:20px;height:20px}.ymap-newhomes-pin._estate .ymap-newhomes-pin__inner{position:relative;z-index:1}.ymap-newhomes-pin._estate .ymap-newhomes-pin__inner:before{content:"";width:20px;height:20px;background-position:50% 50%;background-size:100% 100%;background-image:url("/svg/pin-estate.svg");position:absolute;left:0;top:0;opacity:1}.ymap-newhomes-pin._estate._premium .ymap-newhomes-pin__inner{display:inline-block;vertical-align:middle;width:20px;position:relative;z-index:1;height:31px}.ymap-newhomes-pin._estate._premium .ymap-newhomes-pin__inner:before{content:"";width:20px;height:31px;background-position:50% 50%;background-size:100% 100%;background-image:url("/svg/pin-estate-premium.svg");position:absolute;left:0;top:0;opacity:1}.ymap-newhomes-pin._building .ymap-newhomes-pin__inner{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1}.ymap-newhomes-pin._building .ymap-newhomes-pin__inner:before{content:"";width:20px;height:20px;background-position:50% 50%;background-size:100% 100%;background-image:url("/svg/pin-building.svg");position:absolute;left:0;top:0;opacity:1}.ymap-offer-box__more{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:13px;line-height:18px;color:#000;line-height:30px;background:#fff;border-top:1px solid #c4c4c4;padding:6px 0;text-align:center}.leaflet-container .ymap-offer-box__more-link{text-decoration:none;cursor:pointer}.leaflet-container .ymap-offer-box__more-link,.leaflet-container .ymap-offer-box__more-link:visited{transition:color .2s linear,border-color .2s linear}.leaflet-container .ymap-offer-box__more-link:focus,.leaflet-container .ymap-offer-box__more-link:hover{transition:none}.leaflet-container .ymap-offer-box__more-link,.leaflet-container .ymap-offer-box__more-link:visited{color:#0168bb}.leaflet-container .ymap-offer-box__more-link:focus,.leaflet-container .ymap-offer-box__more-link:hover{color:#c03c40;border-bottom:1px solid;border-color:rgba(192,60,64,.3)}.leaflet-popup{position:absolute;text-align:center}.leaflet-popup-content-wrapper{padding:1px;text-align:left;border-radius:1px}.leaflet-popup-content{margin:14px 20px;line-height:1.4}.leaflet-popup-content p{margin:18px 0}.leaflet-popup-tip-container{margin:0 auto;width:40px;height:20px;position:relative;overflow:hidden}.leaflet-popup-tip{width:15px;height:15px;padding:1px;margin:-8px auto 0;-webkit-transform:rotate(45deg);transform:rotate(45deg)}.leaflet-popup-content-wrapper,.leaflet-popup-tip{background:#fff;box-shadow:0 3px 14px rgba(0,0,0,.4)}.leaflet-container a.leaflet-popup-close-button{position:absolute;top:0;right:0;padding:4px 5px 0 0;text-align:center;width:18px;height:14px;font:16px/14px Tahoma,Verdana,sans-serif;color:#c3c3c3;text-decoration:none;font-weight:700;background:transparent}.leaflet-container a.leaflet-popup-close-button:hover{color:#999}.leaflet-popup-scrolled{overflow:auto;border-bottom:1px solid #ddd;border-top:1px solid #ddd}.ymap-offer-item{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:13px;line-height:18px;color:#000;line-height:20px;padding:10px;background:#fff;cursor:pointer;min-width:255px}.ymap-offer-item:after{content:\'\';display:table;clear:both}.ymap-offer-item+.ymap-offer-item{border-top:1px solid #c4c4c4}.ymap-offer-item:hover{background:#fbfbfb}.ymap-offer-item._no-hover:hover{background:#fff}.ymap-offer-item._infrastructure{min-width:0}.ymap-offer-item__img-h{float:left;margin-right:8px;width:80px;height:60px;position:relative;box-sizing:border-box!important;background:#f2f2f2}.ymap-offer-item__img-h:after{content:"";width:100%;height:100%;position:absolute;display:block;z-index:2;left:0;top:0}.ymap-offer-item__img-h._no-photo:before{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxnPjxjaXJjbGUgY3g9IjEwIiBjeT0iMTEiIHI9IjIuMjUiLz48cGF0aCBkPSJNMTQuMDMxLDUuMDMxTDEyLDNIOEw1Ljk5LDUuMDMxSDJWMTdoMTZWNS4wMzFIMTQuMDMxeiBNMTAsMTQuNTA4Yy0xLjkzNCwwLTMuNS0xLjU2OC0zLjUtMy41MDdjMC0xLjg5LDEuNDk0LTMuNDE4LDMuMzYyLTMuNDkzaDAuMjY3YzEuODczLDAuMDcsMy4zNzEsMS42MDEsMy4zNzEsMy40OTNDMTMuNSwxMi45MzgsMTEuOTM0LDE0LjUwOCwxMCwxNC41MDh6Ii8+PC9nPjwvc3ZnPg==);content:"";width:30px;height:30px;position:absolute;left:50%;top:50%;margin:-15px 0 0 -15px;background-size:100% 100%;background-repeat:no-repeat;opacity:.15}.ymap-offer-item__price{font-weight:700}.ymap-offer-item__rubl-icon{font:normal normal 700 1em ALSRubl-Arial,Arial,FreeSans,Geneva CY,Nimbus Sans L,"sans-serif"}.ymap-offer-item__address{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:700;color:#0168bb}.ymap-offer-item__area{white-space:nowrap}.ymap-offer-item__link{text-decoration:none;cursor:pointer}.ymap-offer-item__link,.ymap-offer-item__link:visited{transition:color .2s linear,border-color .2s linear}.ymap-offer-item__link:focus,.ymap-offer-item__link:hover{transition:none}.ymap-offer-item__link,.ymap-offer-item__link:visited{color:#0168bb}.ymap-offer-item__link:focus,.ymap-offer-item__link:hover{color:#c03c40;border-bottom:1px solid;border-color:rgba(192,60,64,.3)}.ymap-offer-item__firm{margin-bottom:5px;line-height:18px}.ymap-offer-item__firm:last-child{margin:0}.ymap-offer-item__firm-icon{float:left}.ymap-offer-item__firm-icon._school{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._school:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjE4cHgiIGhlaWdodD0iMThweCIgdmlld0JveD0iMCAwIDE4IDE4Ij48cGF0aCBpZD0ic2Nob29sIiBkPSJNOSwzLjUxN0wxLjUyMSw3LjQzNEw5LDExLjM1MWw0LjMzMS0yLjE4YzAsMCwwLDEuOTc3LDAsMi45NjJjMCwxLjU2NywxLjU3NCwxLjU2NywxLjU3NCwxLjU2N3YtMC43ODRjMCwwLTAuNzg3LTAuMDQ0LTAuNzg3LTAuNzgzYzAtMS4xNzUsMC0zLjQwMiwwLTMuNDAybDIuMzYtMS4yOTdMOSwzLjUxN3ogTTUuNDU4LDEwLjU2NnYxLjU2NmMwLDAuMzksMC4yNTYsMC45MSwwLjc4NywxLjE3NUw5LDE0LjQ4M2wyLjM2Mi0xLjE3NmMwLjUzMS0wLjI2NSwxLjIxOS0wLjc4NywxLjE4MS0xLjE3NXYtMS41NjZMOSwxMi4yOEw1LjQ1OCwxMC41NjZ6Ii8+PHVzZSB4bGluazpocmVmPSIjc2Nob29sIiBmaWxsPSJub25lIiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjIuMyIvPjx1c2UgeGxpbms6aHJlZj0iI3NjaG9vbCIgZmlsbD0iIzFFOThGRiIvPjwvc3ZnPg==)}.ymap-offer-item__firm-icon._hospital{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._hospital:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHdpZHRoPSIxOHB4IiBoZWlnaHQ9IjE4cHgiIHZpZXdCb3g9IjAgMCAxOCAxOCI+PGRlZnM+PGcgaWQ9ImNyb3NzIj48cmVjdCB4PSIzIiB5PSI3IiB3aWR0aD0iMTEiIGhlaWdodD0iMyIvPjxyZWN0IHg9IjciIHk9IjMiIHdpZHRoPSIzIiBoZWlnaHQ9IjExIi8+PC9nPjwvZGVmcz48dXNlIHhsaW5rOmhyZWY9IiNjcm9zcyIgZmlsbD0ibm9uZSIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIi8+PHVzZSB4bGluazpocmVmPSIjY3Jvc3MiIGZpbGw9InJlZCIvPjwvc3ZnPg==)}.ymap-offer-item__firm-icon._playschool{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._playschool:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IiB3aWR0aD0iMThweCIgaGVpZ2h0PSIxOHB4IiB2aWV3Qm94PSIwIDAgMTggMTgiPjxwYXRoIGlkPSJudXJzZXJ5IiBkPSJNNS41LDExLjk5MWMtMC44MjksMC0xLjUsMC42NzQtMS41LDEuNTA1QzQsMTQuMzI2LDQuNjcxLDE1LDUuNSwxNUM2LjMyOCwxNSw3LDE0LjMyNiw3LDEzLjQ5NkM3LDEyLjY2NSw2LjMyOCwxMS45OTEsNS41LDExLjk5MXogTTUuNSwxMy43NDZjLTAuMTM5LDAtMC4yNS0wLjExMS0wLjI1LTAuMjVjMC0wLjE0LDAuMTExLTAuMjUyLDAuMjUtMC4yNTJjMC4xMzgsMCwwLjI1LDAuMTEyLDAuMjUsMC4yNTJDNS43NSwxMy42MzUsNS42MzgsMTMuNzQ2LDUuNSwxMy43NDZ6IE0xMS41LDExLjk5MWMtMC44MjksMC0xLjUsMC42NzQtMS41LDEuNTA1QzEwLDE0LjMyNiwxMC42NzEsMTUsMTEuNSwxNWMwLjgyOCwwLDEuNS0wLjY3NCwxLjUtMS41MDRDMTMsMTIuNjY1LDEyLjMyOCwxMS45OTEsMTEuNSwxMS45OTF6IE0xMS41LDEzLjc0NmMtMC4xMzksMC0wLjI1LTAuMTExLTAuMjUtMC4yNWMwLTAuMTQsMC4xMTEtMC4yNTIsMC4yNS0wLjI1MmMwLjEzOCwwLDAuMjUsMC4xMTIsMC4yNSwwLjI1MkMxMS43NSwxMy42MzUsMTEuNjM4LDEzLjc0NiwxMS41LDEzLjc0NnogTTE1LjUsNC40OWMtMS42NTksMC0yLjUsMC44NDMtMi41LDIuNTA3YzAsMC4yNzcsMC4yMjQsMC41MDEsMC41LDAuNTAxUzE0LDcuMjc0LDE0LDYuOTk3YzAtMS4wOTcsMC40MDYtMS41MDUsMS41LTEuNTA1YzAuMjc2LDAsMC41LTAuMjI0LDAuNS0wLjUwMVMxNS43NzYsNC40OSwxNS41LDQuNDl6IE04LjUsMTJjMi44MywwLDUuMTYtMS43NSw1LjQ2NC00SDMuMDM2QzMuMzQsMTAuMjUsNS42NjksMTIsOC41LDEyeiBNOCwzLjAzOUM1LjQwMiwzLjIzMywzLjMyMiw0Ljg4NiwzLjAzNiw3SDhWMy4wMzl6Ii8+PHVzZSB4bGluazpocmVmPSIjbnVyc2VyeSIgZmlsbD0ibm9uZSIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIi8+PHVzZSB4bGluazpocmVmPSIjbnVyc2VyeSIgZmlsbD0iI2YyNTVjOCIvPjwvc3ZnPg==)}.ymap-offer-item__firm-icon._pharmacy{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._pharmacy:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjE4cHgiIGhlaWdodD0iMThweCIgdmlld0JveD0iMCAwIDE4IDE4Ij48cGF0aCBpZD0iZHJ1Z3MiIGQ9Ik0xMy44NjksNC4wM0wxMy44NjksNC4wM2MtMC41NzQtMC41ODctMS4zMzEtMC44OC0yLjA4Ny0wLjg4Yy0wLjc1NywwLTEuNTEzLDAuMjkzLTIuMDg3LDAuODc5IEw0LjEzMiw5LjcxYy0xLjE0OCwxLjE3Mi0xLjE0OCwzLjA4OS0wLjAwMSw0LjI2bDAuMDAxLDAuMDAxYzAuMTQ0LDAuMTQ2LDAuMjk4LDAuMjc0LDAuNDYxLDAuMzg0IGMwLjAyNiwwLjAxOCwwLjA1NiwwLjAyNywwLjA4MiwwLjA0NGMwLjQ3MiwwLjI5NiwxLjAwNiwwLjQ1MSwxLjU0MywwLjQ1MWMwLjI2MiwwLDAuNTIxLTAuMDQ5LDAuNzc1LTAuMTE5IGMwLjQ4LTAuMTMzLDAuOTM2LTAuMzc3LDEuMzExLTAuNzZsNS41NjMtNS42ODFDMTUuMDE3LDcuMTE4LDE1LjAxNyw1LjIwMSwxMy44NjksNC4wM3ogTTEyLjgyNSw3LjIyNmwtMi43ODIsMi44NEw3Ljk1Niw3LjkzNSBsMi43ODItMi44NDFjMC4yNzYtMC4yODEsMC42NDctMC40MzcsMS4wNDQtMC40MzdjMC4zODYsMCwwLjc0NywwLjE0NiwxLjAyMSwwLjQxNGwwLjAyMywwLjAyMyBjMC4yNzYsMC4yODMsMC40MjksMC42NiwwLjQyOSwxLjA2NUMxMy4yNTUsNi41NjMsMTMuMTAyLDYuOTQyLDEyLjgyNSw3LjIyNnoiLz48dXNlIHhsaW5rOmhyZWY9IiNkcnVncyIgZmlsbD0ibm9uZSIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyLjUiLz48dXNlIHhsaW5rOmhyZWY9IiNkcnVncyIgZmlsbD0iIzFBQkFCNCIvPjwvc3ZnPg==)}.ymap-offer-item__firm-icon._sport{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._sport:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjE4cHgiIGhlaWdodD0iMThweCIgdmlld0JveD0iMCAwIDE4IDE4Ij48Y2lyY2xlIGZpbGw9IiNGRkZGRkYiIGN4PSI5IiBjeT0iOSIgcj0iNy43NSIvPjxwYXRoIGZpbGw9IiMxQkFEMDMiIGQ9Ik05LDIuNUM1LjQxOSwyLjUsMi41LDUuNDE5LDIuNSw5YzAsMy41ODIsMi45MTksNi41LDYuNSw2LjVzNi41LTIuOTE4LDYuNS02LjVDMTUuNSw1LjQxOSwxMi41ODEsMi41LDksMi41eiBNOSwzLjY0NmMyLjAzOSwwLDMuODAzLDEuMTI3LDQuNzA3LDIuNzk3Yy0wLjg1MywwLjU2Ni0xLjYzNywwLjg2MS0xLjY0OCwxLjQxMWMtMC4wMDcsMC4zODEsMCwwLjQ5LDAsMC43NjNjMCwwLjM4MywwLjE5OSwwLjg3NSwwLjc2NiwxLjE0N2wxLjMzOCwwLjY0NmMtMC4xNTMsMC41NjYtMC40LDEuMDc4LTAuNzE3LDEuNTUzbC0xLjAwNC0wLjY3Yy0wLjU3NC0wLjM4MS0xLjE0Ny0wLjYzNy0xLjUyOS0wLjM4MWwtMS4xNDcsMC43NjRjLTAuNTMsMC4zNTQtMC40NzUsMC43NjYtMC4zODIsMS4xNDZsMC4zNTcsMS40ODJDOS40OTgsMTQuMzM4LDkuMjUyLDE0LjM1Miw5LDE0LjM1MmMtMC41MywwLTEuMDQ3LTAuMDcyLTEuNTI5LTAuMjE1di0xLjMxNGMwLTAuNzY2LTAuMzgzLTEuMTQ2LTAuNzY1LTEuNTI5Yy0wLjM4My0wLjM4My0wLjc2Ni0wLjc2Ni0xLjUzLTAuNzY2SDMuODYyQzMuNzIsMTAuMDQ1LDMuNjQ2LDkuNTMsMy42NDYsOUMzLjY0Niw2LjAzNSw2LjAzNCwzLjY0Niw5LDMuNjQ2TDksMy42NDZ6IE02LjcwNiw2LjMyM0w2LjMyMyw3Ljg1NGMtMC4xMDgsMC40MzMtMC4zOTcsMC44OCwwLDEuMTQ2bDEuMTQ3LDAuNzY1YzAuNzY1LDAuNTA5LDEuMTAyLDAuMjE0LDEuNTI5LDBsMC43NjUtMC4zODJDMTAuMzM0LDkuMDk4LDEwLjUyOSw5LDEwLjUyOSw4LjIzNVY2LjcwN2MwLTAuMzgyLDAuMDA2LTAuNjExLTAuNzY1LTAuNzY1TDcuODU0LDUuNTU5QzcuMDUyLDUuMzk5LDYuOTAxLDUuNTQyLDYuNzA2LDYuMzIzTDYuNzA2LDYuMzIzeiIvPjwvc3ZnPg==)}.ymap-offer-item__firm-icon._cafe{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._cafe:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IiB3aWR0aD0iMThweCIgaGVpZ2h0PSIxOHB4IiB2aWV3Qm94PSIwIDAgMTggMTgiPjxkZXZzPjxwYXRoIGlkPSJmb29kIiBkPSJNOCw1SDcuNVYyaC0xdjNINlYySDV2NC41QzUsNy4yNzcsNiw3LjIyMyw2LDh2N2MwLDAuMzg5LDAuNSwxLDEsMXMxLTAuNSwxLTFWOGMwLTAuNzc3LDEtMC43MjMsMS0xLjVWMkg4VjV6IE0xMS41MDEsMy41QzExLjExMyw0LjI3NywxMSw2LDExLDd2M2MwLDAuNSwwLjYxMSwxLDEuMDAxLDF2NGMwLDAuNSwwLjUsMSwxLDFDMTMuNSwxNiwxNCwxNS41LDE0LDE1VjJDMTMuMjI1LDIsMTEuOTkzLDIuNTE2LDExLjUwMSwzLjV6Ii8+PC9kZXZzPjx1c2UgeGxpbms6aHJlZj0iI2Zvb2QiIGZpbGw9Im5vbmUiIHN0cm9rZT0id2hpdGUiIHN0cm9rZS13aWR0aD0iMiIvPjx1c2UgeGxpbms6aHJlZj0iI2Zvb2QiIGZpbGw9IiMwRTQ3NzkiLz48L3N2Zz4=)}.ymap-offer-item__firm-icon._shop{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._shop:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjE4cHgiIGhlaWdodD0iMThweCIgdmlld0JveD0iMCAwIDE4IDE4Ij48ZGV2cz48cGF0aCBpZD0iZ3JvY2VyeSIgZD0iTTE0LjUsMy41QzEzLjUsMy41LDEzLDQsMTMsNUgzbDEuMDU5LDZIMTN2MUg0LjgyM2MtMC43NjUsMC0wLjc2NSwwLjc0LDAsMC43NjRoMS4xNDdoNi4xMTdoMS4xNDdDMTMuNjE3LDEyLjc2NCwxNCwxMi4zODMsMTQsMTJ2LTFWNWMwLTAuNSwwLjIzOC0wLjczNSwwLjc2NS0wLjczNUgxNlYzLjVIMTQuNXogTTEyLDEyLjcwNWMtMC42MzMsMC0xLjE0NiwwLjUxNC0xLjE0NiwxLjE0OEMxMC44NTQsMTQuNDg2LDExLjM2NywxNSwxMiwxNXMxLjE0Ni0wLjUxNCwxLjE0Ni0xLjE0NkMxMy4xNDYsMTMuMjE5LDEyLjYzMywxMi43MDUsMTIsMTIuNzA1eiBNNiwxMi43MDVjLTAuNjM0LDAtMS4xNDcsMC41MTQtMS4xNDcsMS4xNDhDNC44NTMsMTQuNDg2LDUuMzY2LDE1LDYsMTVjMC42MzMsMCwxLjE0Ni0wLjUxNCwxLjE0Ni0xLjE0NkM3LjE0NiwxMy4yMTksNi42MzMsMTIuNzA1LDYsMTIuNzA1eiIvPjwvZGV2cz48dXNlIHhsaW5rOmhyZWY9IiNncm9jZXJ5IiBmaWxsPSJub25lIiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjIiLz48dXNlIHhsaW5rOmhyZWY9IiNncm9jZXJ5IiBmaWxsPSIjNzkzRDBFIi8+PC9zdmc+)}.ymap-offer-item__firm-icon._cinema{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._cinema:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IiB3aWR0aD0iMThweCIgaGVpZ2h0PSIxOHB4IiB2aWV3Qm94PSIwIDAgMTggMTgiPjxkZXZzPjxwYXRoIGlkPSJjaW5lbWEiIGQ9Ik0xMy4yMzUsMmwtMS43MjEsMC40NzZsMC44MzcsMi4yMTNMMTQsNC4yMjNMMTMuMjM1LDJ6IE0xMC40NjMsMi43NTVMOC4yMTcsMy4zODRsMC44NiwyLjIxM2wyLjI0Ny0wLjYyOUwxMC40NjMsMi43NTV6IE03LjE4OSwzLjY2NGwtMS45ODMsMC41NmwwLjg2LDIuMjEyTDguMDUsNS44NzdMNy4xODksMy42NjR6IE00LjE3OCw0LjUwM0wyLDUuMjUzbDEsMS45NWwyLjAxNS0wLjQ4OEw0LjE3OCw0LjUwM3ogTTMsN3Y3LjAyNkMzLDE0LjUxNCwzLjUsMTUsNCwxNWgxMGMwLjUsMCwxLTAuNDg2LDEtMC45NzRWN0gzeiBNNSw4Ljk5OGg4VjExSDVWOC45OTh6Ii8+PC9kZXZzPjx1c2UgeGxpbms6aHJlZj0iI2NpbmVtYSIgZmlsbD0ibm9uZSIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIyIi8+PHVzZSB4bGluazpocmVmPSIjY2luZW1hIiBmaWxsPSIjYTgxY2VjIi8+PC9zdmc+)}.ymap-offer-item__firm-icon._theatre{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._theatre:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IiB3aWR0aD0iMThweCIgaGVpZ2h0PSIxOHB4IiB2aWV3Qm94PSIwIDAgMTggMTgiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDE4IDE4IiB4bWw6c3BhY2U9InByZXNlcnZlIj48ZGV2cz48cGF0aCBpZD0ibWFzayIgIGQ9Ik0zLjc4MSwyQzMuMzkzLDIsMywyLjM5MywzLDIuNzgydjUuNWMwLDEuNzIyLDAuNzY0LDMuNzgxLDMuODc1LDMuNzgxQzcuMTU0LDEyLjA2Myw2Ljc1NiwxMi4wMzUsNywxMnYtMkg0LjVjMCwwLDAuNTU2LTIsMi41LTJWNi4zNDRDNyw1LjYzMSw3LjEwOSw0Ljg5MSw3LjUsNC41QzcuODksNC4xMDksOC4zODgsMy4xOTEsMTAsNGwxLDAuNVYyLjc4MkMxMSwyLjM5MywxMC42MDcsMiwxMC4yMTksMkM5LjQ5NiwyLDgsMyw3LDNTNC41MDQsMiwzLjc4MSwyTDMuNzgxLDJ6IE01LDRjMC41NTIsMCwxLDAuNDQ4LDEsMWMwLDAuNTUzLTAuNDQ4LDEtMSwxQzQuNDQ3LDYsNCw1LjU1Myw0LDVDNCw0LjQ0OCw0LjQ0Nyw0LDUsNHogTTguNzgxLDVDOC40MTQsNSw4LDUuMzkzLDgsNS43ODJWMTFjMCwxLjcyMywwLjg4OSw0LDQsNHM0LTIuMjc3LDQtNFY1Ljc4MkMxNiw1LjM5MywxNS41ODYsNSwxNS4yMTksNUMxNC40OTYsNSwxMyw2LDEyLDZTOS41MDQsNSw4Ljc4MSw1eiBNMTAsN2MwLjU1MywwLDEsMC40NDgsMSwxcy0wLjQ0NywxLTEsMVM5LDguNTUzLDksOFM5LjQ0Nyw3LDEwLDd6IE0xNCw3YzAuNTUzLDAsMSwwLjQ0OCwxLDFzLTAuNDQ3LDEtMSwxcy0xLTAuNDQ3LTEtMVMxMy40NDcsNywxNCw3eiBNOS41LDExSDEyaDIuNWMwLDAtMC41NTYsMi0yLjUsMlM5LjUsMTEsOS41LDExeiIvPjwvZGV2cz48dXNlIHhsaW5rOmhyZWY9IiNtYXNrIiBmaWxsPSJub25lIiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjIuMyIvPjx1c2UgeGxpbms6aHJlZj0iI21hc2siIGZpbGw9IiNBODFDRUMiLz48L3N2Zz4=)}.ymap-offer-item__firm-icon._torgovye-centry{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._torgovye-centry:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIxN3B4IiBoZWlnaHQ9IjE2cHgiIHZpZXdCb3g9IjIuNSAzLjUgMTcgMTYiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMi41IDMuNSAxNyAxNiIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+PGRldnM+PHBhdGggIGQ9Ik0xMy4yMzUsMmwtMS43MjEsMC40NzZsMC44MzcsMi4yMTNMMTQsNC4yMjNMMTMuMjM1LDJ6IE0xMC40NjMsMi43NTVMOC4yMTcsMy4zODRsMC44NiwyLjIxM2wyLjI0Ny0wLjYyOSAgIEwxMC40NjMsMi43NTV6IE03LjE4OSwzLjY2NGwtMS45ODMsMC41NmwwLjg2LDIuMjEyTDguMDUsNS44NzdMNy4xODksMy42NjR6IE00LjE3OCw0LjUwM0wyLDUuMjUzbDEsMS45NWwyLjAxNS0wLjQ4OEw0LjE3OCw0LjUwM3ogICAgTTMsN3Y3LjAyNkMzLDE0LjUxNCwzLjUsMTUsNCwxNWgxMGMwLjUsMCwxLTAuNDg2LDEtMC45NzRWN0gzeiBNNSw4Ljk5OGg4VjExSDVWOC45OTh6IiBpZD0iY2luZW1hIj48L3BhdGg+PC9kZXZzPjxwYXRoIGZpbGw9IiM0RDRENEQiIHN0cm9rZT0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIyIiBkPSJNMTYuNSw3LjVoLTF2LTFjMC0wLjU1Mi0wLjQ0Ny0xLTEtMWgtMmMtMC41NTIsMC0xLDAuNDQ4LTEsMXYxaC0xbC0xLDloOEwxNi41LDcuNXogTTE0LjUsNy41aC0ydi0xaDJWNy41eiIvPjxwYXRoIGZpbGw9IiNGRjg5MDAiIGQ9Ik0xNi41LDcuNWgtMXYtMWMwLTAuNTUyLTAuNDQ3LTEtMS0xaC0yYy0wLjU1MiwwLTEsMC40NDgtMSwxdjFoLTFsLTEsOWg4TDE2LjUsNy41eiBNMTQuNSw3LjVoLTJ2LTFoMlY3LjV6Ii8+PHBhdGggZmlsbD0iIzRENEQ0RCIgc3Ryb2tlPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjIiIGQ9Ik0xMC41LDkuNWgtMXYtMWMwLTAuNTUyLTAuNDQ3LTEtMS0xaC0yYy0wLjU1MiwwLTEsMC40NDgtMSwxdjFoLTFsLTEsOWg4TDEwLjUsOS41eiBNOC41LDkuNWgtMnYtMWgyVjkuNXoiLz48cGF0aCBmaWxsPSIjRkY4OTAwIiBkPSJNMTAuNSw5LjVoLTF2LTFjMC0wLjU1Mi0wLjQ0Ny0xLTEtMWgtMmMtMC41NTIsMC0xLDAuNDQ4LTEsMXYxaC0xbC0xLDloOEwxMC41LDkuNXogTTguNSw5LjVoLTJ2LTFoMlY5LjV6Ii8+PC9zdmc+)}.ymap-offer-item__firm-icon._biznes-centry{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;width:18px;height:18px}.ymap-offer-item__firm-icon._biznes-centry:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:1;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIxOHB4IiBoZWlnaHQ9IjE4cHgiIHZpZXdCb3g9IjEuNSAxLjUgMTggMTgiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMS41IDEuNSAxOCAxOCIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+PGRldnM+PHBhdGggIGQ9Ik0xMy4yMzUsMmwtMS43MjEsMC40NzZsMC44MzcsMi4yMTNMMTQsNC4yMjNMMTMuMjM1LDJ6IE0xMC40NjMsMi43NTVMOC4yMTcsMy4zODRsMC44NiwyLjIxM2wyLjI0Ny0wLjYyOSAgIEwxMC40NjMsMi43NTV6IE03LjE4OSwzLjY2NGwtMS45ODMsMC41NmwwLjg2LDIuMjEyTDguMDUsNS44NzdMNy4xODksMy42NjR6IE00LjE3OCw0LjUwM0wyLDUuMjUzbDEsMS45NWwyLjAxNS0wLjQ4OEw0LjE3OCw0LjUwM3ogICAgTTMsN3Y3LjAyNkMzLDE0LjUxNCwzLjUsMTUsNCwxNWgxMGMwLjUsMCwxLTAuNDg2LDEtMC45NzRWN0gzeiBNNSw4Ljk5OGg4VjExSDVWOC45OTh6IiBpZD0iY2luZW1hIj48L3BhdGg+PC9kZXZzPjxwYXRoIHN0cm9rZT0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIyIiBkPSJNMTAuNSwxMC41Yy0wLjU1MywwLTEsMC40NDctMSwxdjFjMCwwLjU1MywwLjQ0NywxLDEsMXMxLTAuNDQ3LDEtMXYtMUMxMS41LDEwLjk0NywxMS4wNTMsMTAuNSwxMC41LDEwLjV6Ii8+PHBhdGggc3Ryb2tlPSIjRkZGRkZGIiBzdHJva2Utd2lkdGg9IjIiIGQ9Ik0xNC41LDEyLjVoLTJjMCwxLjEwNC0wLjg5NSwyLTIsMmMtMS4xMDQsMC0yLTAuODk2LTItMmgtM2gtMXY0YzAsMC41NTMsMC40NDgsMSwxLDFoMTBjMC41NTMsMCwxLTAuNDQ3LDEtMXYtNEgxNC41eiIvPjxwYXRoIHN0cm9rZT0iI0ZGRkZGRiIgc3Ryb2tlLXdpZHRoPSIyIiBkPSJNMTYuNSw2LjVoLTN2LTJjMC0wLjU1Mi0wLjQ0Ny0xLTEtMWgtNGMtMC41NTIsMC0xLDAuNDQ4LTEsMXYyaC0zYy0wLjU1MiwwLTEsMC40NDgtMSwxdjNjMCwwLjU1MywwLjQ0OCwxLDEsMWg0YzAtMS4xMDQsMC44OTYtMiwyLTJjMS4xMDUsMCwyLDAuODk2LDIsMmg0YzAuNTUzLDAsMS0wLjQ0NywxLTF2LTNDMTcuNSw2Ljk0NywxNy4wNTMsNi41LDE2LjUsNi41eiBNMTIuNSw2LjVoLTR2LTJoNFY2LjV6Ii8+PGc+PHBhdGggZmlsbD0iIzRENEQ0RCIgZD0iTTEwLjUsMTAuNWMtMC41NTMsMC0xLDAuNDQ3LTEsMXYxYzAsMC41NTMsMC40NDcsMSwxLDFzMS0wLjQ0NywxLTF2LTFDMTEuNSwxMC45NDcsMTEuMDUzLDEwLjUsMTAuNSwxMC41eiIvPjxwYXRoIGZpbGw9IiM0RDRENEQiIGQ9Ik0xNC41LDEyLjVoLTJjMCwxLjEwNC0wLjg5NSwyLTIsMmMtMS4xMDQsMC0yLTAuODk2LTItMmgtM2gtMXY0YzAsMC41NTMsMC40NDgsMSwxLDFoMTBjMC41NTMsMCwxLTAuNDQ3LDEtMXYtNEgxNC41eiIvPjxwYXRoIGZpbGw9IiM0RDRENEQiIGQ9Ik0xNi41LDYuNWgtM3YtMmMwLTAuNTUyLTAuNDQ3LTEtMS0xaC00Yy0wLjU1MiwwLTEsMC40NDgtMSwxdjJoLTNjLTAuNTUyLDAtMSwwLjQ0OC0xLDF2M2MwLDAuNTUzLDAuNDQ4LDEsMSwxaDRjMC0xLjEwNCwwLjg5Ni0yLDItMmMxLjEwNSwwLDIsMC44OTYsMiwyaDRjMC41NTMsMCwxLTAuNDQ3LDEtMXYtM0MxNy41LDYuOTQ3LDE3LjA1Myw2LjUsMTYuNSw2LjV6IE0xMi41LDYuNWgtNHYtMmg0VjYuNXoiLz48L2c+PC9zdmc+)}.ymap-offer-item__firm-text{display:block}.ymap-offer-item__firm-icon+.ymap-offer-item__firm-text{margin-left:22px}.wrapper .leaflet-fade-anim .leaflet-popup{-webkit-transition:none;transition:none}.wrapper .leaflet-popup{margin-bottom:10px}.wrapper .leaflet-popup-content-wrapper{background:#fff;border:1px solid #c4c4c4;box-shadow:none;padding:1px;text-align:left;border-radius:3px}.wrapper .leaflet-popup-content{margin:0}.wrapper .leaflet-popup-tip-container{margin-top:-1px;position:absolute;width:24px;left:50%;margin-left:-12px}.wrapper .leaflet-popup-tip{box-shadow:none;border:1px solid #c4c4c4;width:12px;height:12px}.wrapper .leaflet-popup._infrastructure .leaflet-popup-content-wrapper{box-shadow:none;border:1px solid rgba(0,0,0,.23);padding:2px;border-radius:3px}.wrapper .leaflet-popup._infrastructure .leaflet-popup-tip-container{margin-top:-1px}.wrapper .leaflet-popup._infrastructure .leaflet-popup-tip{border:1px solid #c4c4c4;width:10px;height:10px}.wrapper .leaflet-popup._reposition-right{margin-bottom:0;margin-left:10px}.wrapper .leaflet-popup._reposition-right .leaflet-popup-tip-container{left:-21px;top:50%;margin:-12px 0 0;transform:rotate(90deg)}.wrapper .leaflet-popup._reposition-bottom{margin-bottom:-10px}.wrapper .leaflet-popup._reposition-bottom .leaflet-popup-tip-container{top:-19px;margin:0 0 0 -12px;transform:rotate(180deg)}.wrapper .leaflet-popup._reposition-left{margin-left:-10px;margin-bottom:0}.wrapper .leaflet-popup._reposition-left .leaflet-popup-tip-container{right:-21px;left:auto;top:50%;margin:-12px 0 0;transform:rotate(-90deg)}.wrapper .leaflet-bar a,.wrapper .leaflet-bar a:hover{width:36px;height:36px;line-height:36px;border-bottom:1px solid #c4c4c4;background-color:#fff}.wrapper .leaflet-bar a:hover{background:#f2f2f2}.wrapper .leaflet-bar a:last-child{border-bottom:0}.wrapper .mode-create .leaflet-control-container{position:absolute;top:0;right:0;bottom:0;left:0;z-index:601}.wrapper .leaflet-bar,.wrapper .leaflet-control-layers,.wrapper .leaflet-touch .leaflet-bar,.wrapper .leaflet-touch .leaflet-control-layers{box-shadow:none;border:1px solid #c4c4c4;border-radius:3px;background:#fff}.wrapper .leaflet-top,.wrapper .leaflet-top .leaflet-control{margin-top:12px}.wrapper .leaflet-left .leaflet-control{margin-left:24px;float:left}.wrapper .leaflet-right .leaflet-control{margin-right:24px}.wrapper .leaflet-control-zoom-in{border-radius:3px 3px 0 0}.wrapper .leaflet-control-zoom-out{border-radius:0 0 3px 3px}.wrapper .leaflet-control-fullscreen-button,.wrapper .leaflet-control-zoom-in,.wrapper .leaflet-control-zoom-out{text-indent:-9999px;position:relative}.wrapper .leaflet-control-fullscreen-button:before,.wrapper .leaflet-control-zoom-in:before,.wrapper .leaflet-control-zoom-out:before{content:"";width:20px;height:20px;position:absolute;left:50%;top:50%;margin:-10px 0 0 -10px;opacity:.5}.wrapper .leaflet-control-fullscreen-button:hover,.wrapper .leaflet-control-zoom-in:hover,.wrapper .leaflet-control-zoom-out:hover{background:#f2f2f2}.wrapper .leaflet-control-zoom-in:before{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAuNSAyMC41IDIwIDIwIiBlbmFibGUtYmFja2dyb3VuZD0ibmV3IDAuNSAyMC41IDIwIDIwIiB4bWw6c3BhY2U9InByZXNlcnZlIj48Zz48Zz48cG9seWdvbiBwb2ludHM9IjE3LjUsMjkuNSAxMS41LDI5LjUgMTEuNSwyMy41IDkuNSwyMy41IDkuNSwyOS41IDMuNSwyOS41IDMuNSwzMS41IDkuNSwzMS41IDkuNSwzNy41IDExLjUsMzcuNSAxMS41LDMxLjUgMTcuNSwzMS41ICIvPjwvZz48L2c+PC9zdmc+)}.wrapper .leaflet-control-zoom-out:before{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9Ii0xMC41IDkuNSAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAtMTAuNSA5LjUgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxnPjxnPjxyZWN0IHg9Ii03LjUiIHk9IjE4LjUiIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiB3aWR0aD0iMTQiIGhlaWdodD0iMiIvPjwvZz48L2c+PC9zdmc+)}.wrapper .leaflet-control-fullscreen-button{border-radius:3px}.wrapper .leaflet-control-fullscreen-button:before{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxnPjxwb2x5Z29uIHBvaW50cz0iMTYsMiAxMiwyIDEyLDQgMTYsNCAxNiw4IDE4LDggMTgsNCAxOCwyICIvPjwvZz48cG9seWdvbiBwb2ludHM9IjgsMTYgNCwxNiA0LDEyIDIsMTIgMiwxNiAyLDE4IDQsMTggOCwxOCAiLz48bGluZSBmaWxsPSJub25lIiBzdHJva2U9IiMwMDAwMDAiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLW1pdGVybGltaXQ9IjEwIiB4MT0iMTciIHkxPSIzIiB4Mj0iMTEiIHkyPSI5Ii8+PGxpbmUgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjMDAwMDAwIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1taXRlcmxpbWl0PSIxMCIgeDE9IjMiIHkxPSIxNyIgeDI9IjkiIHkyPSIxMSIvPjwvc3ZnPg==)}.wrapper .leaflet-fullscreen-on .leaflet-control-fullscreen-button:before{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxnPjxwb2x5Z29uIHBvaW50cz0iMTIsMTAgMTYsMTAgMTYsOCAxMiw4IDEyLDQgMTAsNCAxMCw4IDEwLDEwICIvPjxwb2x5Z29uIHBvaW50cz0iNCwxMiA4LDEyIDgsMTYgMTAsMTYgMTAsMTIgMTAsMTAgOCwxMCA0LDEwICIvPjxsaW5lIGZpbGw9Im5vbmUiIHN0cm9rZT0iIzAwMDAwMCIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbWl0ZXJsaW1pdD0iMTAiIHgxPSIxNyIgeTE9IjMiIHgyPSIxMSIgeTI9IjkiLz48bGluZSBmaWxsPSJub25lIiBzdHJva2U9IiMwMDAwMDAiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLW1pdGVybGltaXQ9IjEwIiB4MT0iMyIgeTE9IjE3IiB4Mj0iOSIgeTI9IjExIi8+PC9nPjwvc3ZnPg==)}.wrapper .leaflet-control-layers-toggle,.wrapper .leaflet-retina .leaflet-control-layers-toggle,.wrapper .leaflet-touch .leaflet-control-layers-toggle{background:transparent;position:relative;width:34px;height:34px;border-radius:3px}.wrapper .leaflet-control-layers-toggle:hover,.wrapper .leaflet-retina .leaflet-control-layers-toggle:hover,.wrapper .leaflet-touch .leaflet-control-layers-toggle:hover{background-color:#f2f2f2}.wrapper .leaflet-control-layers-toggle:before,.wrapper .leaflet-retina .leaflet-control-layers-toggle:before,.wrapper .leaflet-touch .leaflet-control-layers-toggle:before{content:"";background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9Ii0xMC41IDkuNSAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAtMTAuNSA5LjUgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxnPjxnPjxwYXRoIGQ9Ik0tMC41LDIxLjExOGwtNS4xMTgtMi41NkwtOC41LDIwbDgsNGw4LTRsLTIuODgyLTEuNDQxTC0wLjUsMjEuMTE4eiBNLTAuNSwyNS41MWwtNS41MDktMi43NTVMLTguNSwyNGw4LDRsOC00bC0yLjQ5LTEuMjQ1TC0wLjUsMjUuNTF6IE03LjUsMTZsLTgtNGwtOCw0bDgsNEw3LjUsMTZ6Ii8+PC9nPjwvZz48L3N2Zz4=);width:20px;height:20px;position:absolute;left:50%;top:50%;margin:-10px 0 0 -10px;opacity:.5}.wrapper .leaflet-control-traffic{float:right}.wrapper._map .leaflet-top.leaflet-right{margin-top:24px;margin-right:154px}.wrapper._map .leaflet-top.leaflet-right .leaflet-control{float:left;clear:none}.wrapper._map .leaflet-top.leaflet-right .leaflet-control-traffic{float:right}.wrapper .leaflet-control-infrastructure,.wrapper .leaflet-touch .leaflet-control-infrastructure{-ms-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap;box-sizing:border-box;padding:0 16px 0 10px;height:36px;cursor:pointer;position:relative;margin:0!important;border-radius:3px 0 0 3px}.wrapper .leaflet-control-infrastructure:hover,.wrapper .leaflet-touch .leaflet-control-infrastructure:hover{background:#f2f2f2}.wrapper .leaflet-control-infrastructure._active,.wrapper .leaflet-touch .leaflet-control-infrastructure._active{background:#d9d9d9}.wrapper .leaflet-control-infrastructure-text,.wrapper .leaflet-touch .leaflet-control-infrastructure-text{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:17px;line-height:24px;color:#000;vertical-align:middle}@media (max-width:1280px){.wrapper .leaflet-control-infrastructure-text,.wrapper .leaflet-touch .leaflet-control-infrastructure-text{display:none}}@media (max-width:1280px){.wrapper .leaflet-control-infrastructure,.wrapper .leaflet-touch .leaflet-control-infrastructure{padding:0 10px}}.wrapper .leaflet-control-infrastructure-icon,.wrapper .leaflet-touch .leaflet-control-infrastructure-icon{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;margin:7px 4px 7px 1px}.wrapper .leaflet-control-infrastructure-icon:before,.wrapper .leaflet-touch .leaflet-control-infrastructure-icon:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:.5;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwb2x5Z29uIGRpc3BsYXk9Im5vbmUiIHN0cm9rZT0iIzAwMDAwMCIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbWl0ZXJsaW1pdD0iMTAiIHBvaW50cz0iMywzIDkuNSwyMSAxNiwzICIvPjxjaXJjbGUgY3g9IjcuNSIgY3k9IjE1LjUiIHI9IjEuNSIvPjxjaXJjbGUgY3g9IjExLjUiIGN5PSIxNS41IiByPSIxLjUiLz48cG9seWxpbmUgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjMDAwMDAwIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1taXRlcmxpbWl0PSIxMCIgcG9pbnRzPSIzLjcyMiw1IDE1LjI3Nyw1IDE2LDMgMTksMyAiLz48cG9seWdvbiBzdHJva2U9IiMwMDAwMDAiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLW1pdGVybGltaXQ9IjEwIiBwb2ludHM9IjMuNzIyLDUgNi4yNSwxMiAxMi43NSwxMiAxNS4yNzcsNSAiLz48L3N2Zz4=)}@media (max-width:1280px){.wrapper .leaflet-control-infrastructure-icon,.wrapper .leaflet-touch .leaflet-control-infrastructure-icon{margin:7px 0}}@media (max-width:1280px){.wrapper .leaflet-control-infrastructure,.wrapper .leaflet-touch .leaflet-control-infrastructure{position:static}}.wrapper .leaflet-control-infrastructure~.leaflet-control-ecology,.wrapper .leaflet-touch .leaflet-control-infrastructure~.leaflet-control-ecology{border-radius:0;border-left:0}.wrapper .leaflet-control-ecology,.wrapper .leaflet-touch .leaflet-control-ecology{-ms-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap;box-sizing:border-box;padding:0 16px 0 10px;height:36px;cursor:pointer;position:relative;margin:0!important;border-radius:3px 0 0 3px}.wrapper .leaflet-control-ecology:hover,.wrapper .leaflet-touch .leaflet-control-ecology:hover{background:#f2f2f2}.wrapper .leaflet-control-ecology._active,.wrapper .leaflet-touch .leaflet-control-ecology._active{background:#d9d9d9}.wrapper .leaflet-control-ecology-text,.wrapper .leaflet-touch .leaflet-control-ecology-text{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:17px;line-height:24px;color:#000;vertical-align:middle}@media (max-width:1280px){.wrapper .leaflet-control-ecology-text,.wrapper .leaflet-touch .leaflet-control-ecology-text{display:none}}@media (max-width:1280px){.wrapper .leaflet-control-ecology,.wrapper .leaflet-touch .leaflet-control-ecology{padding:0 10px}}.wrapper .leaflet-control-ecology-icon,.wrapper .leaflet-touch .leaflet-control-ecology-icon{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;margin:7px 4px 7px 2px}.wrapper .leaflet-control-ecology-icon:before,.wrapper .leaflet-touch .leaflet-control-ecology-icon:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:.5;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9Ii0xMC41IDkuNSAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAtMTAuNSA5LjUgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwYXRoIGQ9Ik0tNS41OCwxNS4yNmMtMi44MDMsMi44MDItMS44Miw1LjgyMi0xLjQxMyw2LjkyOGMyLjk2NC02LjE1NSw5LjM4Ni03LjY4Myw5LjM4Ni03LjY4M3MtOC4yMjQsNS41NjItOS4yODgsMTIuNDIyYy0wLjA4NSwwLjU0MiwxLjI2NywwLjg0MSwxLjM5MSwwLjE5MmMwLjM3LTEuOTMsMS4xNjktMy41MjEsMS4xNjktMy41MjFjMS44MjUsMC4xNDksNC44OTIsMC4wNjUsNi41NjctMS45MjJjMi4yMjctMi42NDIsMC44NjktNi43NDgsNC4yMTUtOS44NjFDNy4yMywxMS4wODgtMS43OCwxMS40NjEtNS41OCwxNS4yNnoiLz48L3N2Zz4=)}@media (max-width:1280px){.wrapper .leaflet-control-ecology-icon,.wrapper .leaflet-touch .leaflet-control-ecology-icon{margin:7px 0}}.wrapper .leaflet-control-traffic,.wrapper .leaflet-touch .leaflet-control-traffic{-ms-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap;box-sizing:border-box;padding:0 16px 0 10px;height:36px;cursor:pointer;position:relative;margin:0!important;border-radius:0 3px 3px 0;border-left:0}.wrapper .leaflet-control-traffic:hover,.wrapper .leaflet-touch .leaflet-control-traffic:hover{background:#f2f2f2}.wrapper .leaflet-control-traffic._active,.wrapper .leaflet-touch .leaflet-control-traffic._active{background:#d9d9d9}.wrapper .leaflet-control-traffic-text,.wrapper .leaflet-touch .leaflet-control-traffic-text{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:17px;line-height:24px;color:#000;vertical-align:middle}@media (max-width:1280px){.wrapper .leaflet-control-traffic-text,.wrapper .leaflet-touch .leaflet-control-traffic-text{display:none}}@media (max-width:1280px){.wrapper .leaflet-control-traffic,.wrapper .leaflet-touch .leaflet-control-traffic{padding:0 10px}}.wrapper .leaflet-control-traffic-icon,.wrapper .leaflet-touch .leaflet-control-traffic-icon{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;margin:7px 6px 7px 0}.wrapper .leaflet-control-traffic-icon:before,.wrapper .leaflet-touch .leaflet-control-traffic-icon:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:.5;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwb2x5Z29uIHBvaW50cz0iMTYsNSAxOSw1IDE2LDggIi8+PHBvbHlnb24gcG9pbnRzPSIxNiwxMSAxOSwxMSAxNiwxNCAiLz48cG9seWdvbiBwb2ludHM9IjQsNSAxLDUgNCw4ICIvPjxwb2x5Z29uIHBvaW50cz0iNCwxMSAxLDExIDQsMTQgIi8+PHBhdGggZD0iTTQsMnYxNmgxMlYySDR6IE0xMCwxNWMtMS4xMDQsMC0yLTAuODk2LTItMnMwLjg5Ni0yLDItMnMyLDAuODk2LDIsMlMxMS4xMDQsMTUsMTAsMTV6IE0xMCw5QzguODk2LDksOCw4LjEwNCw4LDdzMC44OTYtMiwyLTJzMiwwLjg5NiwyLDJTMTEuMTA0LDksMTAsOXoiLz48L3N2Zz4=)}@media (max-width:1280px){.wrapper .leaflet-control-traffic-icon,.wrapper .leaflet-touch .leaflet-control-traffic-icon{margin:7px 0}}.wrapper .leaflet-right .leaflet-control.leaflet-control-draw{-ms-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap;box-sizing:border-box;padding:0 16px 0 10px;height:36px;cursor:pointer;position:relative;margin:0 12px!important}.wrapper .leaflet-right .leaflet-control.leaflet-control-draw:hover{background:#f2f2f2}.wrapper .leaflet-right .leaflet-control.leaflet-control-draw._active{margin-left:70px!important}.wrapper .leaflet-control-draw-icon{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;margin:7px 6px 7px 3px}.wrapper .leaflet-control-draw-icon:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:.5;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxnPjxwb2x5Z29uIHBvaW50cz0iNC4yNSw5LjQzOCA2LjY4OCwxMS44NzUgMy4xODgsMTUuMzc1IDQuODEyLDE3IDguMzEzLDEzLjQ5OCAxMC43NSwxNS45MzYgMTQsNi4xODggIi8+PHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGZpbGw9Im5vbmUiIHN0cm9rZT0iIzAwMDAwMCIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbWl0ZXJsaW1pdD0iMTAiIGQ9Ik0zLjMsNi42MjdDNC41MzUsNC4xOCw3LjA3MiwyLjUwMSwxMCwyLjUwMWM0LjE0MywwLDcuNSwzLjM1OCw3LjUsNy41MDFjMCwyLjkyOS0xLjY4LDUuNDY1LTQuMTI5LDYuNjk5Ii8+PC9nPjwvc3ZnPg==)}.wrapper .leaflet-control._active .leaflet-control-draw-icon{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;margin:7px 6px 7px 3px}.wrapper .leaflet-control._active .leaflet-control-draw-icon:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:.5;background-image:url(data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjIwcHgiIGhlaWdodD0iMjBweCIgdmlld0JveD0iMCAwIDIwIDIwIj48ZyBmaWxsPSJub25lIiBzdHJva2U9IiMwMDAwMDAiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLW1pdGVybGltaXQ9IjEwIiA+PGxpbmUgeDE9IjQiIHkxPSI0IiB4Mj0iMTYiIHkyPSIxNiIvPjxsaW5lIHgxPSIxNiIgeTE9IjQiIHgyPSI0IiB5Mj0iMTYiLz48L2c+PC9zdmc+)}.wrapper .leaflet-control-draw-text{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:17px;line-height:24px;color:#000;vertical-align:middle}.wrapper .leaflet-control-traffic-icon{display:inline-block;vertical-align:middle;width:20px;height:20px;position:relative;z-index:1;margin:0 4px 0 0;margin:7px 3px 7px 2px}.wrapper .leaflet-control-traffic-icon:before{content:"";position:absolute;left:0;top:0;width:100%;height:100%;background-position:50% 50%;background-size:100% 100%;opacity:.5;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwb2x5Z29uIHBvaW50cz0iMTYsNSAxOSw1IDE2LDggIi8+PHBvbHlnb24gcG9pbnRzPSIxNiwxMSAxOSwxMSAxNiwxNCAiLz48cG9seWdvbiBwb2ludHM9IjQsNSAxLDUgNCw4ICIvPjxwb2x5Z29uIHBvaW50cz0iNCwxMSAxLDExIDQsMTQgIi8+PHBhdGggZD0iTTQsMnYxNmgxMlYySDR6IE0xMCwxNWMtMS4xMDQsMC0yLTAuODk2LTItMnMwLjg5Ni0yLDItMnMyLDAuODk2LDIsMlMxMS4xMDQsMTUsMTAsMTV6IE0xMCw5QzguODk2LDksOCw4LjEwNCw4LDdzMC44OTYtMiwyLTJzMiwwLjg5NiwyLDJTMTEuMTA0LDksMTAsOXoiLz48L3N2Zz4=)}@media (max-width:1280px){.wrapper .leaflet-control-traffic-icon{margin:7px 0}}.wrapper .leaflet-control-attribution{white-space:nowrap}.leaflet-marker-icon._infrastructure{z-index:100!important}.leaflet-control-tooltip{padding:9px 11px;font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:13px;line-height:18px;color:#000;color:#fff}.offers-map svg.tracer{position:absolute;top:0;left:0;width:100%;height:100%;z-index:-1}.offers-map svg.tracer path.drawing-line{stroke:#68b107;stroke-width:3px}.offers-map .mode-create svg.tracer{z-index:600!important}.offers-map path.tracer{stroke-width:3px;stroke-opacity:1;stroke:#68b107;position:absolute;z-index:1001;fill:#68b107;fill-opacity:.1}.offers-map div.polygon-elbow{-webkit-transition:opacity .25s;transition:opacity .25s;box-sizing:border-box}.offers-map div.polygon-elbow:before{display:block;content:"";position:absolute;top:0;right:0;bottom:0;left:0;margin:auto;background:#68b107;width:6px;height:6px;box-shadow:0 0 0 1px #fff,0 0 10px rgba(0,0,0,.35)}.offers-map .leaflet-container,.offers-map .leaflet-container .tracer{cursor:-webkit-grab;cursor:-moz-grab}.offers-map .leaflet-container.mode-create,.offers-map .leaflet-container.mode-create .tracer{cursor:crosshair}.leaflet-cluster-anim .leaflet-marker-icon,.leaflet-cluster-anim .leaflet-marker-shadow{-webkit-transition:-webkit-transform .3s ease-out,opacity .3s ease-in;transition:transform .3s ease-out,opacity .3s ease-in}.marker-cluster-small{background-color:hsla(91,60%,72%,.6)}.marker-cluster-small div{background-color:rgba(110,204,57,.6)}.marker-cluster-medium{background-color:rgba(241,211,87,.6)}.marker-cluster-medium div{background-color:rgba(240,194,12,.6)}.marker-cluster-large{background-color:hsla(18,97%,72%,.6)}.marker-cluster-large div{background-color:rgba(241,128,23,.6)}.marker-cluster{background-clip:padding-box;border-radius:20px}.marker-cluster div{width:30px;height:30px;margin-left:5px;margin-top:5px;text-align:center;border-radius:15px;font:12px Helvetica Neue,Arial,Helvetica,sans-serif}.marker-cluster span{line-height:30px}.wrapper .dg-attribution{background-color:transparent!important}.wrapper .dg-attribution__copyright{margin:0 55px 5px 0;text-align:right;white-space:nowrap;font-size:9px;font-family:Helvetica,Arial,sans-serif}.wrapper .dg-attribution__links{display:inline-block;margin:0;padding:0 5px 0 0}.wrapper .dg-attribution__link-item{padding:0;list-style-type:none}.leaflet-container .wrapper .dg-attribution__link{background:linear-gradient(90deg,rgba(8,8,8,.3),rgba(8,8,8,.3)) 0 95% repeat-x;background-size:10px 1px;color:#333;text-decoration:none;font-size:9px;font-family:Helvetica,Arial,sans-serif;cursor:pointer}.leaflet-container .wrapper .dg-attribution__link:hover{background-image:linear-gradient(90deg,#080808,#080808);color:#333;text-decoration:none}.wrapper .dg-attribution__logo-url{background-repeat:no-repeat;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns=\'http://www.w3.org/2000/svg\' height=\'24\' width=\'55\'%3E%3Cpath fill=\'%23a2c124\' d=\'M24.395 12c0-1.454-.222-2.655-.665-4-.148 4.255-4.88 7.818-7.467 10h6.764c.703-2 1.368-3.927 1.368-6m-4.731-9.345C17.631 1.055 15.044 0 12.198 0 5.47 0 0 5.418 0 12s5.47 12 12.198 12c3.105 0 5.95-1.454 8.132-3.345h-8.797V18c5.36-4.545 8.797-7.346 8.797-10 0-1.127-.813-2.655-2.699-2.655-1.478 0-2.698 1.346-2.698 4.655h-3.4c-.74-4.218 1.848-7.673 6.246-7.673.665 0 1.257.218 1.885.328\'/%3E%3Cpath fill=\'%233c4347\' d=\'M36.593 9.345h1.368c0-2-.666-5.127-4.732-5.272-4.732-.219-6.1 2.618-6.1 5.927v5.346c0 4.4 3.438 5.345 6.1 5.345 1.552 0 3.4-.873 4.73-2v-6.69h-5.433v2.654h2.698v2.654c-1.367 1.346-5.433 1.346-5.433-2.654v-5.31c0-4 5.95-4.145 5.618 0h1.183zM54.889 16c0-5.818-6.986-4.073-6.986-7.6 0-1.2.813-2 2.18-2 1.442 0 2.256 1.018 2.256 2.982h2.587c0-2-.665-5.346-4.731-5.346-2.772 0-4.88 1.419-4.88 4.328 0 6.072 7.172 4.072 7.06 7.672-.073 1.455-1.145 2.073-2.365 2.073-1.441 0-2.698-.727-2.44-3.382h-2.66c-.26 3.346 1.44 6 5.359 6 2.699 0 4.732-2.145 4.732-5.345L54.89 16zm-12.198 4h-2.698V4h2.698v16z\'/%3E%3C/svg%3E");width:52px;height:24px;background-size:52px 24px;position:absolute;margin:0 3px 0 0}.wrapper .dg-zoom__in,.wrapper .dg-zoom__out{display:block;text-indent:-9999px;position:relative;box-shadow:none;border:1px solid #c4c4c4;border-radius:3px;background:#fff;width:34px;height:34px}.wrapper .dg-zoom__in:before,.wrapper .dg-zoom__out:before{content:"";width:20px;height:20px;position:absolute;left:50%;top:50%;margin:-10px 0 0 -10px;opacity:.5}.wrapper .dg-zoom__in:hover,.wrapper .dg-zoom__out:hover{background:#f2f2f2}.wrapper .dg-zoom__in{height:35px;border-radius:3px 3px 0 0}.wrapper .dg-zoom__in:before{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9IjAuNSAyMC41IDIwIDIwIiBlbmFibGUtYmFja2dyb3VuZD0ibmV3IDAuNSAyMC41IDIwIDIwIiB4bWw6c3BhY2U9InByZXNlcnZlIj48Zz48Zz48cG9seWdvbiBwb2ludHM9IjE3LjUsMjkuNSAxMS41LDI5LjUgMTEuNSwyMy41IDkuNSwyMy41IDkuNSwyOS41IDMuNSwyOS41IDMuNSwzMS41IDkuNSwzMS41IDkuNSwzNy41IDExLjUsMzcuNSAxMS41LDMxLjUgMTcuNSwzMS41ICIvPjwvZz48L2c+PC9zdmc+)}.wrapper .dg-zoom__out{border-radius:0 0 3px 3px;border-top:0}.wrapper .dg-zoom__out:before{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyMHB4IiBoZWlnaHQ9IjIwcHgiIHZpZXdCb3g9Ii0xMC41IDkuNSAyMCAyMCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAtMTAuNSA5LjUgMjAgMjAiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxnPjxnPjxyZWN0IHg9Ii03LjUiIHk9IjE4LjUiIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiB3aWR0aD0iMTQiIGhlaWdodD0iMiIvPjwvZz48L2c+PC9zdmc+)}.wrapper .dg-label{position:absolute;top:0;left:0;z-index:2000!important;max-width:none;max-height:none;width:300px}.wrapper .dg-label__content{display:inline-block;overflow:hidden;border:1px solid rgba(0,0,0,.23);padding:12px;border-radius:3px;min-width:30px;max-width:300px;width:auto;background:#fff;font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:13px;line-height:18px;color:#000}.leaflet-top .wrapper .dg-label_name_location-error{top:5px}.leaflet-right .wrapper .dg-label_name_location-error{right:40px;left:auto;text-align:right}.leaflet-bottom .wrapper .dg-label_name_location-error{top:4px}.leaflet-left .wrapper .dg-label_name_location-error{left:40px}.map-path-button{text-align:center;border-top:1px solid #c4c4c4;padding:6px 0}.map-path-button__link{background:#fff;height:30px;text-decoration:none;font-family:Arial,FreeSans,Geneva CY,Nimbus Sans L,\'sans-serif\';font-size:12px;line-height:30px}.leaflet-container .map-path-button__link{text-decoration:none;cursor:pointer}.leaflet-container .map-path-button__link .map-path-button__text,.leaflet-container .map-path-button__link:visited .map-path-button__text{transition:color .2s linear,border-color .2s linear}.leaflet-container .map-path-button__link:focus .map-path-button__text,.leaflet-container .map-path-button__link:hover .map-path-button__text{transition:none}.leaflet-container .map-path-button__link .map-path-button__text,.leaflet-container .map-path-button__link:visited .map-path-button__text{color:#0168bb}.leaflet-container .map-path-button__link:focus .map-path-button__text,.leaflet-container .map-path-button__link:hover .map-path-button__text{color:#c03c40;border-bottom:1px solid;border-color:rgba(192,60,64,.3)}.map-path-button__icon{display:inline-block;background:0 50% url("/static/img/2gis-logo.png") no-repeat;background-size:100% auto;width:30px;height:18px;vertical-align:middle;position:relative;top:-1px;margin-left:6px}.map-path-button__text{display:inline}.card-garages-map-dummy__content{width:100%;background:#f2f2f2;height:360px}.card-garages-map-dummy__controls{margin-top:6px}.card-garages-map-dummy__button{display:inline-block;vertical-align:top;background:#f2f2f2;border-radius:3px;height:36px;margin:12px 12px 0 0}.card-garages-map-dummy__button._button-0{width:120px}.card-garages-map-dummy__button._button-1{width:204px}.card-garages-map-footer{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:13px;line-height:18px;color:#000;line-height:30px;background:#fff;border-top:1px solid #d9d9d9;padding:6px 0;text-align:center}.card-garages-map-footer__link{text-decoration:none;cursor:pointer}.card-garages-map-footer__link,.card-garages-map-footer__link:visited{transition:color .2s linear,border-color .2s linear}.card-garages-map-footer__link:focus,.card-garages-map-footer__link:hover{transition:none}.card-garages-map-footer__link,.card-garages-map-footer__link:visited{color:#0168bb}.card-garages-map-footer__link:focus,.card-garages-map-footer__link:hover{color:#c03c40;border-bottom:1px solid;border-color:rgba(192,60,64,.3)}.card-garages-map-header{padding:10px;background:#f2f2f2}.card-garages-map-header__address{font-weight:400;font-size:15px;line-height:24px;font-weight:700}.card-garages-map-header__address,.card-garages-map-header__cooperative{display:inline-block;width:100%;font-family:PTSans,\'sans-serif\';font-style:normal;color:#000}.card-garages-map-header__cooperative{font-weight:400;font-size:13px;line-height:18px}.card-garages-map-item{font-family:PTSans,\'sans-serif\';font-weight:400;font-style:normal;font-size:15px;line-height:24px;color:#000;line-height:22px;padding:7px 10px 10px;background:#fff;cursor:pointer;min-width:275px;border-top:1px solid #d9d9d9}.card-garages-map-item:after{content:\'\';display:table;clear:both}.card-garages-map-item:first-child{border-top:0}.card-garages-map-item:hover{background:#f2f2f2}.card-garages-map-item__preview{float:left;margin:3px 8px 0 0;width:80px;height:60px;position:relative;box-sizing:border-box;background:#f2f2f2}.card-garages-map-item__preview:after{content:"";position:absolute;top:0;left:0;z-index:2;display:block;width:100%;height:100%;box-shadow:inset 0 0 1px rgba(0,0,0,.4)}.card-garages-map-item__preview._no-photo:before{content:"";width:30px;height:30px;background-position:50% 50%;background-size:100% 100%;background-image:url("/svg/photo.svg");position:absolute;left:50%;top:50%;margin:-15px 0 0 -15px;opacity:.15}.card-garages-map-item__title{display:inline;text-decoration:none;cursor:pointer}.card-garages-map-item__title,.card-garages-map-item__title:visited{transition:color .2s linear,border-color .2s linear}.card-garages-map-item__title:focus,.card-garages-map-item__title:hover{transition:none}.card-garages-map-item__title,.card-garages-map-item__title:visited{color:#0168bb}.card-garages-map-item__title:focus,.card-garages-map-item__title:hover{color:#c03c40;border-bottom:1px solid;border-color:rgba(192,60,64,.3)}.card-garages-map-item__param,.card-garages-map-item__price{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.card-garages-map-item__price{font-weight:700}', ""]);
}, function(e, t) {
e.exports = "
"].join("")
}
i(null, a)
}), this._offerStore.events.on("renderHouses", function(t, i) {
var r = '
Найдены объявления по адресам: ';
p["default"].each(t.houses, function(t) {
var i = t.params.city.name_ru;
t.params.street && (i += ", " + t.params.street.name_ru), t.params.house_number && (i += " " + t.params.house_number);
var a = t.params.city ? t.params.city.id : "",
n = t.params.street ? t.params.street.id : "",
o = e.similarOfferUrlQuery;
o.query.city = a, o.query.street = n, o.query.house_number = t.params.house_number, o.query && o.query.cluster && delete o.query.cluster;
var s = o.path + "?" + $.param(o.query);
i = '' + i + "", r += i + " "
}), r += "
"
}, function(e, t, i) {
"use strict";
function r(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var a = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
n = i(145),
o = function() {
function e() {
r(this, t), this.slider = {
current: 0,
showPrev: !1,
showNext: !0
}, this.sliderWidth = 3
}
e.prototype.ready = function() {
var e = this;
this.$onBreakpoint([3, 3, 4], function(t) {
e.sliderWidth = t
})
}, e.prototype.slidePrev = function() {
this.slider.current--, this.slider.showNext = !0, this.slider.current <= 0 && (this.slider.showPrev = !1)
}, e.prototype.slideNext = function() {
this.slider.current++, this.slider.showPrev = !0, this.slider.current >= this.offers.length - this.sliderWidth && (this.slider.showNext = !1)
}, e.prototype.preventDefault = function(e) {
e.preventDefault()
}, a(e, [{
key: "offersCount",
get: function() {
return this.offers && this.offers.length ? this.offers.length : 0
}
}], [{
key: "template",
value: i(1702)(n.asset("./templates/similar-offers.jade")),
enumerable: !0
}, {
key: "styles",
value: i(1702)(n.asset("./styles/similar-offers.scss")),
enumerable: !0
}, {
key: "props",
value: {
offers: {
required: !0
},
name: {
type: String,
required: !0
},
isVisibleDummy: {
type: Boolean,
"default": !1
}
},
enumerable: !0
}, {
key: "partials",
value: {
offerDummy: i(1702)(n.asset("./templates/partials/similar-offer-dummy.jade"))
},
enumerable: !0
}, {
key: "components",
value: {
item: i(1696)
},
enumerable: !0
}]);
var t = e;
return e = n.ComponentVue(e) || e
}();
t["default"] = o, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./Item/Item": 1696,
"./Item/Item.js": 1696,
"./Item/styles/similar-offer.scss": 1698,
"./Item/templates/similar-offer.jade": 1700,
"./SimilarOffers": 1701,
"./SimilarOffers.js": 1701,
"./styles/similar-offers.scss": 1703,
"./templates/partials/similar-offer-dummy.jade": 1705,
"./templates/similar-offers.jade": 1706
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1702
}, function(e, t, i) {
var r = i(1704);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, ".similar-offers{position:relative}.similar-offers__wrapper{display:inline-block;width:100%;margin:8px 0 32px;vertical-align:top}.similar-offers__list{overflow:hidden;margin-left:-15px;margin-right:-15px;white-space:nowrap;position:relative}.similar-offers__list._cols-x3,.similar-offers__list._cols-x4{display:none}@media (max-width:1679px){.similar-offers__list._cols-x3{display:block}}@media (min-width:1680px){.similar-offers__list._cols-x4{display:block}}.similar-offers__list:after,.similar-offers__list:before{content:\"\";position:absolute;top:0;width:15px;height:100%;z-index:2;background:#fff}.similar-offers__list:before{left:0;margin-left:-1px}.similar-offers__list:after{right:0;margin-right:-1px}.similar-offers__item{position:relative;display:inline-block;vertical-align:top;height:100%;transition:left .3s ease;width:33.33333%;z-index:1}@media (min-width:1680px){.similar-offers__item{width:25%}}.similar-offers__controls{position:absolute;left:0;top:9px;width:100%}.similar-offers__arrow{-ms-user-select:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;transition:all .3s cubic-bezier(.1,0,.25,1);-webkit-tap-highlight-color:transparent;position:absolute;z-index:11;width:44px;cursor:pointer}.similar-offers__arrow:hover:before{background-color:hsla(0,0%,100%,.5)}.similar-offers__arrow:before{content:'';position:absolute;top:50%;width:42px;height:54px;margin-top:-27px;background-color:hsla(0,0%,100%,.7);background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiIHdpZHRoPSIyNHB4IiBoZWlnaHQ9IjI0cHgiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZW5hYmxlLWJhY2tncm91bmQ9Im5ldyAwIDAgMjQgMjQiIHhtbDpzcGFjZT0icHJlc2VydmUiPjxwb2x5bGluZSBmaWxsPSJub25lIiBzdHJva2U9IiMwMDAwMDAiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLW1pdGVybGltaXQ9IjEwIiBwb2ludHM9IjgsMyAxNywxMiA4LDIxICIvPjwvc3ZnPg==);background-repeat:no-repeat;background-position:10px 16px;border-radius:2px 0 0 2px}.similar-offers__arrow._prev{left:0}.similar-offers__arrow._prev:before{left:0;-webkit-transform:rotate(180deg) translateX(0) scale(1);transform:rotate(180deg) translateX(0) scale(1)}.similar-offers__arrow._next,.similar-offers__arrow._next:before{right:0}@media (max-width:1279px){.similar-offers__arrow{top:66.5px;height:133px;margin-top:-66.5px}}@media (min-width:1280px) and (max-width:1679px){.similar-offers__arrow{top:96.5px;height:193px;margin-top:-96.5px}}@media (min-width:1680px){.similar-offers__arrow{top:90px;height:180px;margin-top:-90px}}.similar-offer-dummy{display:block;margin-left:15px;margin-right:15px}.similar-offer-dummy__preview{width:100%;position:relative;z-index:1;background:#f2f2f2}.similar-offer-dummy__blank{display:block;width:100%;height:auto;z-index:1}.similar-offer-dummy__text{padding:12px 0}.similar-offer-dummy-text__item{height:12px;background:#f2f2f2;margin:0 0 12px}.similar-offer-dummy-text__item:last-child{margin-bottom:0}.similar-offer-dummy-text__item._header{width:88%}.similar-offer-dummy-text__item._info,.similar-offer-dummy-text__item._subheader{width:57%}.similar-offer-dummy-text__item._price{width:37%}", ""])
}, function(e, t) {
e.exports = '
'
}, function(e, t) {
e.exports = '
'
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
o = i(145),
s = i(1708),
l = r(s),
c = i(1710),
p = r(c),
d = i(1711),
u = r(d),
f = i(117),
m = r(f),
h = i(26),
g = r(h),
_ = function() {
function e() {
a(this, t), this.types = ["price", "price_per_sqm"], this.currentType = "price", this.prices = {}, this.hasDataParts = 0, this.showDummy = !0, this.legend = {
microdistrict: {
active: !0,
visible: !1,
text: ""
},
district: {
active: !0,
visible: !1,
text: ""
},
city: {
active: !0,
visible: !1,
text: ""
}
}
}
e.prototype.ready = function() {
var e = this;
this.$watch("currentType", function(t) {
e.$analytics("SWITCH_CHART_" + t.toUpperCase())
}), this._setTypes(), this._getData().then(function(t) {
e.prices = t.result, e._setOfferPrices(), e._setLegend(), e._renderCharts()
})["catch"](function(t) {
e.$logError(t), e.showDummy = !1
})
}, e.prototype.beforeDestroy = function() {
var e = this;
this.priceCharts && m["default"].each(this.types, function(t) {
e.priceCharts[t].destroy()
})
}, e.prototype._setOfferPrices = function() {
var e = this,
t = this.offer.param("creation_date"),
i = this.offer.param("params.price"),
r = this.offer.param("params.price_per_sqm"),
a = g["default"](),
n = t;
return m["default"].each(this.prices, function(e) {
e.length && (n = g["default"](n).isSame(t) ? g["default"](e[0].date).isAfter(n) ? e[0].date : n : g["default"](e[0].date).isBefore(n) ? e[0].date : n)
}), this.offerPrices.length ? ! function() {
var t = e.offer.param("params.total_area");
if (e.offerPrices = m["default"].filter(e.offerPrices, function(t, i) {
return i > 0 ? g["default"](t.date).format("YYYY-MM-DD") !== g["default"](e.offerPrices[i - 1].date).format("YYYY-MM-DD") : !0
}), e.offerPrices = m["default"].map(e.offerPrices, function(e) {
var i = g["default"](e.date).format("YYYY-MM-DD");
return g["default"](e.date).isBefore(n) && (i = g["default"](n, "YYYY-MM-DD").format("YYYY-MM-DD")), {
date: i,
price: e.price,
price_per_sqm: Math.round(e.price / t * 100)
}
}), g["default"](e.offerPrices[0].date).isBefore(g["default"]())) {
var i = m["default"].cloneDeep(e.offerPrices[0]);
i.date = g["default"]().format("YYYY-MM-DD"), e.offerPrices.unshift(i)
}
}() : (this.offerPrices = [{
date: g["default"](t).isBefore(n) ? g["default"](n, "YYYY-MM-DD").format("YYYY-MM-DD") : g["default"](t).format("YYYY-MM-DD"),
price: i,
price_per_sqm: r
}], g["default"](t).format("YYYY-MM-DD") !== g["default"](a).format("YYYY-MM-DD") && this.offerPrices.unshift({
date: a.format("YYYY-MM-DD"),
price: i,
price_per_sqm: r
})), this.offerPrices.reverse(), this
}, e.prototype._setTypes = function() {
"rent_out" !== this.offer.param("deal_type") && this.offer.has("params.total_area") || (this.types = ["price"])
}, e.prototype._setLegend = function() {
var e = this;
m["default"].forEach(this.legend, function(t, i) {
if (t.visible = e.offer.has("params." + i + ".name_ru") && m["default"].get(e, "prices." + i + ".length") && e.prices[i].length > 1, t.visible) {
var r = e.offer.param("params." + i + ".name_ru");
"microdistrict" === i && (/мкр|жилмассив/.test(r) || (r += " микрорайон")), t.text = r
}
})
}, e.prototype._renderCharts = function() {
var e = this;
this.offerPrices.length && (this.prices.offer = this.offerPrices), m["default"].each(this.prices, function(t) {
t.length > 0 && e.hasDataParts++
}), this.showDummy = !1;
var t = {};
m["default"].each(this.types, function(i) {
var r = {},
a = 0,
n = void 0;
"price_per_sqm" == i ? (a = 1e4, n = e.$els.chartPricePerSqm) : "price" == i && (a = 1e5, n = e.$els.chartPrice), "rent_out" === e.offer.param("deal_type") && (a = 1e3, n = e.$els.chartPrice), e._config.yOffset.min = function(e, t) {
var i = e - .25 * (t - e) - a;
return i > 0 ? i : e
}, e._config.yOffset.max = function(e, t) {
var i = t + .1 * (t - e) + a;
return i
}, t[i] = new l["default"](n, e._config), t[i].setTooltip(new u["default"]({
baseClass: "prices-chart-tooltip"
})), t[i].on("chartLineMouseOver", function(t) {
e.$parent.$emit("chartLineMouseOver", t)
}), t[i].on("chartLineMouseOut", function() {
e.$parent.$emit("chartLineMouseOut")
});
for (var o in e.prices)
if (e.prices[o].length) {
var s = {
cssClass: o,
focus: {
cssClass: "focus " + o,
enabled: !0,
radius: 6
}
};
e.legend[o] && (s.text = e.legend[o].text), "offer" !== o && (s.interpolate = "cardinal"), "offer" === o && (s.circles = {
hoverable: !0,
enabled: !0,
defaultR: 3,
bigR: 6
}, s.text = "Это объявление"), r[o] = new p["default"], r[o].init(o, s), r[o].setData(e._getCurrenTypeData(e.prices[o], i)), t[i].addLine(r[o])
}
t[i].draw()
}), this.priceCharts = t
}, e.prototype._getData = function() {
var e = {};
return this.offer.has("params") && (e = {
region_id: this.offer.param("params.region.id"),
city_id: this.offer.param("params.city.id"),
total_area: this.offer.param("params.total_area"),
deal_type: this.offer.param("deal_type"),
rooms_count: this.offer.param("params.rooms_count"),
is_newbuilding: this.offer.param("params.is_newbuilding"),
rubric: this.offer.param("rubric")
}, this.offer.has("params.district.id") && (e.district_id = this.offer.param("params.district.id")), this.offer.has("params.microdistrict.id") && (e.microdistrict_id = this.offer.param("params.microdistrict.id"))), this.$service("SimilarOffersPrice").getAggregate(e)
}, e.prototype._getCurrenTypeData = function(e, t) {
var i = void 0,
r = function(t) {
var i = [];
return m["default"].forEach(e, function(e) {
var r = m["default"].omit(e, t);
r = m["default"].mapKeys(r, function(e, t) {
return "date" == t ? "x" : "y"
}), r = m["default"].mapValues(r, function(e, t) {
return "x" == t ? g["default"](e, "YYYY-MM-DD").valueOf() : e
}), i.push(r)
}), i
};
switch (t) {
case "price":
i = r("price_per_sqm");
break;
case "price_per_sqm":
i = r("price")
}
return i
}, e.prototype.toggleChartLine = function(e) {
var t = this;
this.legend[e].active = !this.legend[e].active, m["default"].each(this.types, function(i) {
t.priceCharts[i].toggleLine(e, "disabled")
})
}, e.prototype.highlightChartPoint = function(e, t) {
var i = this;
m["default"].each(this.types, function(r) {
i.priceCharts[r] && i.priceCharts[r].highlightPoint(e, "offer", t)
})
}, e.prototype.onMortgageRequestLinkClick = function() {
this.$emit("mortgage_request_link_clicked")
}, n(e, [{
key: "hasMortgage",
get: function() {
return Boolean(this.offer && "sell" === this.offer.param("deal_type") && this.offer.has("params.price"))
}
}], [{
key: "template",
value: i(1712)(o.asset("./templates/similar-prices-chart.jade")),
enumerable: !0
}, {
key: "styles",
value: i(1712)(o.asset("./styles/similar-prices-chart.scss")),
enumerable: !0
}, {
key: "props",
value: {
offer: {
required: !0
},
offerPrices: {
type: Array,
"default": function() {
return []
}
}
},
enumerable: !0
}, {
key: "components",
value: {
costSubscriptionLink: i(1719)
},
enumerable: !0
}, {
key: "partials",
value: {
hypothec: i(1712)(o.asset("./templates/blocks/chart-hypothec.jade")),
legend: i(1712)(o.asset("./templates/blocks/chart-legend.jade")),
switcher: i(1712)(o.asset("./templates/blocks/chart-type-switcher.jade"))
},
enumerable: !0
}, {
key: "_config",
value: {
resizable: !0,
yOffset: {
min: 0,
max: 1e5
},
xOffset: {
min: 0,
max: [3, "days"]
}
},
enumerable: !0
}]);
var t = e;
return e = o.ComponentVue(e) || e
}();
t["default"] = _, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
function n(e, t) {
if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function, not " + typeof t);
e.prototype = Object.create(t && t.prototype, {
constructor: {
value: e,
enumerable: !1,
writable: !0,
configurable: !0
}
}), t && (Object.setPrototypeOf ? Object.setPrototypeOf(e, t) : e.__proto__ = t)
}
t.__esModule = !0;
var o = i(3),
s = r(o),
l = i(1709),
c = r(l),
p = i(117),
d = r(p),
u = i(26),
f = r(u),
m = function(e) {
function t(i) {
var r = arguments.length <= 1 || void 0 === arguments[1] ? {} : arguments[1];
a(this, t), e.call(this), this.config = {
width: 642,
height: 300,
resizable: !1,
margin: {
top: 10,
right: 0,
bottom: 5,
left: 0
},
padding: {
top: 40,
right: 30,
bottom: 10,
left: 30
},
background: {
color: "#fff"
},
svg: {
viewBox: null,
preserveAspectRatio: null
},
maxPeriodToShowAllMonths: 12,
periodDelimeter: 3
}, this.lineConfig = {
xScale: null,
yScale: null,
xAxis: null,
yAxis: null,
minMaxX: null,
minMaxY: null,
lines: {},
overlay: null,
tooltip: null
}, this.svg = null, this.g = null, this.axises = {}, i && this.init(i, r)
}
return n(t, e), t.prototype.init = function(e) {
var t = this,
i = arguments.length <= 1 || void 0 === arguments[1] ? {} : arguments[1];
this.config = d["default"].defaults(i, this.config), this.config.width = e.clientWidth, this.outerWidth = 0, this.outerHeight = 0, this.innerWidth = 0, this.innerHeight = 0, this.width = 0, this.height = 0, this.container = e, this._calcDimensions(), this.config.resizable && $(window).on("resize.chart", function() {
t.config.width = t.container.clientWidth, t.config.width !== t.outerWidth && (t._calcDimensions(), t.erase(), t.draw())
})
}, t.prototype.draw = function() {
this._drawBackground(), this._draw()
}, t.prototype.getWidth = function() {
return this.width
}, t.prototype.getHeight = function() {
return this.height
}, t.prototype.getSvg = function() {
return this.svg
}, t.prototype.getG = function() {
return this.g
}, t.prototype.addLine = function(e) {
this.lineConfig.lines[e.getName()] = e
}, t.prototype.getLine = function(e) {
return "undefined" == typeof this.lineConfig.lines[e] ? !1 : this.lineConfig.lines[e]
}, t.prototype.getXScale = function() {
return this.lineConfig.xScale
}, t.prototype.getYScale = function() {
return this.lineConfig.yScale
}, t.prototype.setTooltip = function(e) {
this.lineConfig.tooltip = e
}, t.prototype.getTooltip = function() {
return this.lineConfig.tooltip
}, t.prototype._calcDimensions = function() {
var e = this.config.margin,
t = this.config.padding;
this.outerWidth = this.config.width, this.outerHeight = this.config.height, this.innerWidth = this.outerWidth - e.left - e.right, this.innerHeight = this.outerHeight - e.top - e.bottom, this.width = this.innerWidth - t.left - t.right, this.height = this.innerHeight - t.top - t.bottom
}, t.prototype.erase = function() {
c["default"].select(this.container).selectAll("*").remove()
}, t.prototype._drawBackground = function() {
var e = this.config.padding;
this.svg = c["default"].select(this.container).append("svg"), this.svg.attr("width", this.outerWidth).attr("height", this.outerHeight), this.config.svg.viewBox && this.svg.attr("viewBox", this.config.svg.viewBox), this.config.svg.preserveAspectRatio && this.svg.attr("preserveAspectRatio", this.config.svg.preserveAspectRatio), this.g = this.svg.append("g").attr("transform", "translate(" + e.left + "," + e.top + ")"), this.g.append("rect").attr("class", "inner").attr("fill", this.config.background.color).attr("width", this.width).attr("height", this.height)
}, t.prototype._draw = function() {
this._calcMinMax(), this._initAxises(), this._drawAxises(), this._drawLines(), this._initTooltip(), this._initMouseEvents()
}, t.prototype._calcMinMax = function() {
var e, t, i, r;
for (var a in this.lineConfig.lines) {
var n = this.lineConfig.lines[a],
o = n.getMinMaxX();
(void 0 == e || o[0] < e) && (e = o[0]), (void 0 == t || o[1] > t) && (t = o[1]);
var s = n.getMinMaxY();
(void 0 == i || s[0] < i) && (i = s[0]), (void 0 == r || s[1] > r) && (r = s[1])
}
this.config.yOffset && (this.config.yOffset.min && "function" == typeof this.config.yOffset.min ? i = this.config.yOffset.min(i, r) : i -= this.config.yOffset.min, this.config.yOffset.max && "function" == typeof this.config.yOffset.max ? r = this.config.yOffset.max(i, r) : r += this.config.yOffset.max), this.config.xOffset && (e = this.config.xOffset.min && "function" == typeof this.config.xOffset.min ? this.config.xOffset.min(e) : f["default"](e).subtract(this.config.xOffset.min[0], this.config.xOffset.min[1]), t = this.config.xOffset.max && "function" == typeof this.config.xOffset.max ? this.config.xOffset.max(t) : f["default"](t).add(this.config.xOffset.max[0], this.config.xOffset.max[1])), this.lineConfig.minMaxX = [e, t], this.lineConfig.minMaxY = [i, r]
}, t.prototype._initTooltip = function() {
if (this.lineConfig.tooltip) {
var e = c["default"].select(this.container).append("div").attr("class", this.lineConfig.tooltip.getBaseClass()).style("opacity", 0);
this.lineConfig.tooltip.setContainer(e)
}
}, t.prototype._getTicksX = function() {
for (var e = this.lineConfig.xScale.domain(), t = 12 * (e[1].getFullYear() - e[0].getFullYear()) + (e[1].getMonth() - e[0].getMonth()), i = Math.floor(t / this.config.maxPeriodToShowAllMonths < 1 ? 1 : t / this.config.maxPeriodToShowAllMonths * this.config.periodDelimeter), r = [], a = f["default"](e[0]), n = f["default"](e[1]).subtract(Math.floor(i / 4), "M"); n > a && f["default"](a).format("MM-YYYY") !== f["default"](e[1]).format("MM-YYYY");) {
var o = a.isSame(e[0]) ? a.valueOf() : a.date(1).valueOf();
r.push(new Date(o)), a = a.add(i, "M")
}
return r.push(new Date(f["default"](e[1]).date(1).valueOf())), r
}, t.prototype._initAxises = function() {
var e = this;
this.lineConfig.xScale = c["default"].time.scale().range([1, this.getWidth()]).domain(this.lineConfig.minMaxX), this.lineConfig.yScale = c["default"].scale.linear().range([this.getHeight(), 0]).domain(this.lineConfig.minMaxY);
var t = null;
this.lineConfig.xAxis = c["default"].svg.axis().scale(this.lineConfig.xScale).tickFormat(function(i) {
var r = {
months: ["января", "февраля", "марта", "апреля", "мая", "июня", "июля", "августа", "сентября", "октября", "ноября", "декабря"],
week_days: ["воскресенье", "понедельник", "вторник", "среда", "четверг", "пятница", "cуббота"],
months_short: ["Янв", "Фев", "Март", "Апр", "Май", "Июн", "Июл", "Авг", "Сен", "Окт", "Ноя", "Дек"]
},
a = e.lineConfig.xScale.domain();
if (i.getHours()) return "";
var n = r.months_short[i.getMonth()];
return (0 === i.getMonth() || t && t.getFullYear() < i.getFullYear()) && (n += " " + i.getFullYear()), (f["default"](i) >= f["default"](a[0]).subtract(3, "d") && f["default"](i) <= f["default"](a[0]).add(3, "d") || f["default"](i) < f["default"](a[0]) || f["default"](i).format("MM-YYYY") === f["default"](a[0]).format("MM-YYYY")) && (n += " " + i.getFullYear()), t = i, n
}).tickValues(this._getTicksX()).orient("bottom").tickSize(0), this.lineConfig.yAxis = c["default"].svg.axis().scale(this.lineConfig.yScale).orient("right").tickFormat(function(e) {
return e ? e.toString().replace(/\B(?=(\d{3})+(?!\d))/g, "?") + "??" : e
}).ticks(6).tickSize(0)
}, t.prototype._drawAxises = function() {
var e = this.config.padding;
this.getG().append("g").attr("class", "x axis").attr("transform", "translate(0," + this.getHeight() + ")").call(this.lineConfig.xAxis), this.getSvg().selectAll(".x line").attr("class", "grid").attr("y2", 5), this.getSvg().selectAll(".x text").attr("y", 12).attr("x", -1).style("text-anchor", "start");
var t = this.getSvg().selectAll(".x .tick")[0];
t && c["default"].select(t.pop()).select("text").style("text-anchor", "end"), this.getSvg().select(".x .tick").attr("transform", "translate(" + (1 - e.left) + ", 0)"), this.getG().append("g").attr("class", "y axis").attr("transform", "translate(" + -e.left + ", 0)").call(this.lineConfig.yAxis), this.getSvg().selectAll(".y line").attr("class", "grid").attr("x2", this.getWidth() + e.right + e.left),
this.getSvg().selectAll(".y text").attr("x", 0).attr("dy", -10), this.getSvg().selectAll(".x .domain").attr("transform", "translate(" + -e.left + ", 0) scale(" + (e.left + e.right + this.getWidth()) / this.getWidth() + ", 1)")
}, t.prototype._drawLines = function() {
var e, t = this,
i = this;
for (var r in this.lineConfig.lines) {
e = this.lineConfig.lines[r];
var a = e.getConfig(),
n = e.getData(),
o = c["default"].svg.line();
! function() {
var t = e.getXName();
o.x(function(e) {
return i.lineConfig.xScale(e[t])
})
}(),
function() {
var t = e.getYName();
o.y(function(e) {
return i.lineConfig.yScale(e[t])
})
}(), a.interpolate && o.interpolate(a.interpolate), e.setD3Object(o);
var s = function() {
var t = e.getName(),
i = e.getConfig(),
r = i.cssClass;
return function(e) {
return "line " + t + " " + r
}
}(),
l = e.getDrawCallback();
if (null != l ? l(e, this, s) : this.getG().append("path").attr("class", s).datum(n).attr("d", o), a.circles.enabled) {
var p = this.getG().append("g").attr("class", "circles " + a.cssClass);
d["default"].forEach(n, function(e) {
var i = 1 === n.length ? a.circles.bigR : a.circles.defaultR,
r = t.lineConfig.xScale.domain();
(f["default"](e.x) > f["default"](r[0]) || 1 === n.length) && p.append("circle").attr("r", i).attr("cx", t.lineConfig.xScale(e.x)).attr("cy", t.lineConfig.yScale(e.y))
})
}
var u = this.getG().append("g").style("display", "none");
a.focus.cssClass && u.attr("class", a.focus.cssClass), u.append("circle").attr("r", a.focus.radius), o.focus = u
}
this.lineConfig.overlay = this.getG().append("rect").attr("class", "overlay").attr("width", this.width).attr("height", this.height)
}, t.prototype.toggleLine = function(e, t) {
var i = c["default"].select(this.container).selectAll("." + e);
i.classed(t, !i.classed(t));
var r = this.getLine(e);
r.toggleLine(t)
}, t.prototype.highlightPoint = function(e, t, i) {
var r = this,
a = this.getLine(t),
n = a.getData(),
o = a.getSvgObject();
d["default"].forEach(n, function(t, a) {
if (f["default"](t.x).format("YYYY-MM-DD") === f["default"](e).format("YYYY-MM-DD") || 0 === a && f["default"](t.x).isAfter(e)) {
if (i) return void r._hideFocus(o.focus);
r._showFocus(o.focus), o.focus.attr("transform", "translate(" + r.lineConfig.xScale(t.x) + "," + r.lineConfig.yScale(t.y) + ")")
}
})
}, t.prototype._initMouseEvents = function() {
var e = this,
t = this;
this.lineConfig.overlay.on("mouseover", function() {
e._mouseOver()
}).on("mouseout", function() {
e._mouseOut()
}).on("mousemove", function() {
t._mouseMove(this)
})
}, t.prototype._mouseOver = function() {
this._showFocusCircles()
}, t.prototype._mouseOut = function() {
this._hideFocusCircles(), this.emit("chartLineMouseOut"), this.lineConfig.tooltip && this.lineConfig.tooltip.hide()
}, t.prototype._mouseMove = function(e) {
if (this.lineConfig.tooltip) var t = {};
for (var i in this.lineConfig.lines) {
var r = this.getLine(i),
a = r.getSvgObject();
if (r.visible && (a.focus || this.lineConfig.tooltip)) {
var n, o = r.getData(),
s = c["default"].bisector(function(e) {
return e.x
}).left,
l = this.lineConfig.xScale.invert(c["default"].mouse(e)[0]),
p = s(o, l, 1),
u = o[p - 1],
f = o[p];
if ("undefined" == typeof f && "undefined" == typeof u) {
this._hideFocus(a.focus);
continue
}
if (this._showFocus(a.focus), n = f && l - u.x > f.x - l ? f : u, "offer" === i && l - u.x < 0) {
this._hideFocus(a.focus);
continue
}
if ("undefined" == typeof n.x) continue;
a.focus && (a.focus.attr("transform", "translate(" + this.lineConfig.xScale(n.x) + "," + this.lineConfig.yScale(n.y) + ")"), this.emit("chartLineMouseOver", n.x)), this.lineConfig.tooltip && (t[i] = n, t[i].text = r.getText())
}
}
if (this.lineConfig.tooltip && d["default"].size(t)) {
var m = c["default"].mouse(this.container);
this.lineConfig.tooltip.show(t, {
x: m[0],
y: m[1]
})
}
}, t.prototype._showFocusCircles = function() {
for (var e in this.lineConfig.lines) {
var t = this.lineConfig.lines[e],
i = t.getSvgObject();
i.focus && i.focus.style("display", null)
}
}, t.prototype._hideFocusCircles = function() {
for (var e in this.lineConfig.lines) {
var t = this.lineConfig.lines[e],
i = t.getSvgObject();
i.focus && i.focus.style("display", "none")
}
}, t.prototype._hideFocus = function(e) {
e.style("display", "none")
}, t.prototype._showFocus = function(e) {
e.style("display", null)
}, t.prototype.destroy = function() {
$(window).off("resize.chart")
}, t
}(s["default"].EventEmitter);
t["default"] = m, e.exports = t["default"]
}, function(e, t, i) {
var r, a;
! function() {
function n(e) {
return e && (e.ownerDocument || e.document || e).documentElement
}
function o(e) {
return e && (e.ownerDocument && e.ownerDocument.defaultView || e.document && e || e.defaultView)
}
function s(e, t) {
return t > e ? -1 : e > t ? 1 : e >= t ? 0 : NaN
}
function l(e) {
return null === e ? NaN : +e
}
function c(e) {
return !isNaN(e)
}
function p(e) {
return {
left: function(t, i, r, a) {
for (arguments.length < 3 && (r = 0), arguments.length < 4 && (a = t.length); a > r;) {
var n = r + a >>> 1;
e(t[n], i) < 0 ? r = n + 1 : a = n
}
return r
},
right: function(t, i, r, a) {
for (arguments.length < 3 && (r = 0), arguments.length < 4 && (a = t.length); a > r;) {
var n = r + a >>> 1;
e(t[n], i) > 0 ? a = n : r = n + 1
}
return r
}
}
}
function d(e) {
return e.length
}
function u(e) {
for (var t = 1; e * t % 1;) t *= 10;
return t
}
function f(e, t) {
for (var i in t) Object.defineProperty(e.prototype, i, {
value: t[i],
enumerable: !1
})
}
function m() {
this._ = Object.create(null)
}
function h(e) {
return (e += "") === vo || e[0] === xo ? xo + e : e
}
function g(e) {
return (e += "")[0] === xo ? e.slice(1) : e
}
function _(e) {
return h(e) in this._
}
function y(e) {
return (e = h(e)) in this._ && delete this._[e]
}
function b() {
var e = [];
for (var t in this._) e.push(g(t));
return e
}
function v() {
var e = 0;
for (var t in this._) ++e;
return e
}
function x() {
for (var e in this._) return !1;
return !0
}
function w() {
this._ = Object.create(null)
}
function M(e) {
return e
}
function L(e, t, i) {
return function() {
var r = i.apply(t, arguments);
return r === t ? e : r
}
}
function j(e, t) {
if (t in e) return t;
t = t.charAt(0).toUpperCase() + t.slice(1);
for (var i = 0, r = wo.length; r > i; ++i) {
var a = wo[i] + t;
if (a in e) return a
}
}
function I() {}
function k() {}
function N(e) {
function t() {
for (var t, r = i, a = -1, n = r.length; ++a < n;)(t = r[a].on) && t.apply(this, arguments);
return e
}
var i = [],
r = new m;
return t.on = function(t, a) {
var n, o = r.get(t);
return arguments.length < 2 ? o && o.on : (o && (o.on = null, i = i.slice(0, n = i.indexOf(o)).concat(i.slice(n + 1)), r.remove(t)), a && i.push(r.set(t, {
on: a
})), e)
}, t
}
function D() {
oo.event.preventDefault()
}
function S() {
for (var e, t = oo.event; e = t.sourceEvent;) t = e;
return t
}
function C(e) {
for (var t = new k, i = 0, r = arguments.length; ++i < r;) t[arguments[i]] = N(t);
return t.of = function(i, r) {
return function(a) {
try {
var n = a.sourceEvent = oo.event;
a.target = e, oo.event = a, t[a.type].apply(i, r)
} finally {
oo.event = n
}
}
}, t
}
function z(e) {
return Lo(e, No), e
}
function T(e) {
return "function" == typeof e ? e : function() {
return jo(e, this)
}
}
function E(e) {
return "function" == typeof e ? e : function() {
return Io(e, this)
}
}
function A(e, t) {
function i() {
this.removeAttribute(e)
}
function r() {
this.removeAttributeNS(e.space, e.local)
}
function a() {
this.setAttribute(e, t)
}
function n() {
this.setAttributeNS(e.space, e.local, t)
}
function o() {
var i = t.apply(this, arguments);
null == i ? this.removeAttribute(e) : this.setAttribute(e, i)
}
function s() {
var i = t.apply(this, arguments);
null == i ? this.removeAttributeNS(e.space, e.local) : this.setAttributeNS(e.space, e.local, i)
}
return e = oo.ns.qualify(e), null == t ? e.local ? r : i : "function" == typeof t ? e.local ? s : o : e.local ? n : a
}
function P(e) {
return e.trim().replace(/\s+/g, " ")
}
function O(e) {
return new RegExp("(?:^|\\s+)" + oo.requote(e) + "(?:\\s+|$)", "g")
}
function Z(e) {
return (e + "").trim().split(/^|\s+/)
}
function H(e, t) {
function i() {
for (var i = -1; ++i < a;) e[i](this, t)
}
function r() {
for (var i = -1, r = t.apply(this, arguments); ++i < a;) e[i](this, r)
}
e = Z(e).map(U);
var a = e.length;
return "function" == typeof t ? r : i
}
function U(e) {
var t = O(e);
return function(i, r) {
if (a = i.classList) return r ? a.add(e) : a.remove(e);
var a = i.getAttribute("class") || "";
r ? (t.lastIndex = 0, t.test(a) || i.setAttribute("class", P(a + " " + e))) : i.setAttribute("class", P(a.replace(t, " ")))
}
}
function G(e, t, i) {
function r() {
this.style.removeProperty(e)
}
function a() {
this.style.setProperty(e, t, i)
}
function n() {
var r = t.apply(this, arguments);
null == r ? this.style.removeProperty(e) : this.style.setProperty(e, r, i)
}
return null == t ? r : "function" == typeof t ? n : a
}
function B(e, t) {
function i() {
delete this[e]
}
function r() {
this[e] = t
}
function a() {
var i = t.apply(this, arguments);
null == i ? delete this[e] : this[e] = i
}
return null == t ? i : "function" == typeof t ? a : r
}
function R(e) {
function t() {
var t = this.ownerDocument,
i = this.namespaceURI;
return i ? t.createElementNS(i, e) : t.createElement(e)
}
function i() {
return this.ownerDocument.createElementNS(e.space, e.local)
}
return "function" == typeof e ? e : (e = oo.ns.qualify(e)).local ? i : t
}
function Q() {
var e = this.parentNode;
e && e.removeChild(this)
}
function V(e) {
return {
__data__: e
}
}
function F(e) {
return function() {
return ko(this, e)
}
}
function W(e) {
return arguments.length || (e = s),
function(t, i) {
return t && i ? e(t.__data__, i.__data__) : !t - !i
}
}
function Y(e, t) {
for (var i = 0, r = e.length; r > i; i++)
for (var a, n = e[i], o = 0, s = n.length; s > o; o++)(a = n[o]) && t(a, o, i);
return e
}
function J(e) {
return Lo(e, So), e
}
function X(e) {
var t, i;
return function(r, a, n) {
var o, s = e[n].update,
l = s.length;
for (n != i && (i = n, t = 0), a >= t && (t = a + 1); !(o = s[t]) && ++t < l;);
return o
}
}
function $(e, t, i) {
function r() {
var t = this[o];
t && (this.removeEventListener(e, t, t.$), delete this[o])
}
function a() {
var a = l(t, lo(arguments));
r.call(this), this.addEventListener(e, this[o] = a, a.$ = i), a._ = t
}
function n() {
var t, i = new RegExp("^__on([^.]+)" + oo.requote(e) + "$");
for (var r in this)
if (t = r.match(i)) {
var a = this[r];
this.removeEventListener(t[1], a, a.$), delete this[r]
}
}
var o = "__on" + e,
s = e.indexOf("."),
l = q;
s > 0 && (e = e.slice(0, s));
var c = Co.get(e);
return c && (e = c, l = K), s ? t ? a : r : t ? I : n
}
function q(e, t) {
return function(i) {
var r = oo.event;
oo.event = i, t[0] = this.__data__;
try {
e.apply(this, t)
} finally {
oo.event = r
}
}
}
function K(e, t) {
var i = q(e, t);
return function(e) {
var t = this,
r = e.relatedTarget;
r && (r === t || 8 & r.compareDocumentPosition(t)) || i.call(t, e)
}
}
function ee(e) {
var t = ".dragsuppress-" + ++To,
i = "click" + t,
r = oo.select(o(e)).on("touchmove" + t, D).on("dragstart" + t, D).on("selectstart" + t, D);
if (null == zo && (zo = "onselectstart" in e ? !1 : j(e.style, "userSelect")), zo) {
var a = n(e).style,
s = a[zo];
a[zo] = "none"
}
return function(e) {
if (r.on(t, null), zo && (a[zo] = s), e) {
var n = function() {
r.on(i, null)
};
r.on(i, function() {
D(), n()
}, !0), setTimeout(n, 0)
}
}
}
function te(e, t) {
t.changedTouches && (t = t.changedTouches[0]);
var i = e.ownerSVGElement || e;
if (i.createSVGPoint) {
var r = i.createSVGPoint();
if (0 > Eo) {
var a = o(e);
if (a.scrollX || a.scrollY) {
i = oo.select("body").append("svg").style({
position: "absolute",
top: 0,
left: 0,
margin: 0,
padding: 0,
border: "none"
}, "important");
var n = i[0][0].getScreenCTM();
Eo = !(n.f || n.e), i.remove()
}
}
return Eo ? (r.x = t.pageX, r.y = t.pageY) : (r.x = t.clientX, r.y = t.clientY), r = r.matrixTransform(e.getScreenCTM().inverse()), [r.x, r.y]
}
var s = e.getBoundingClientRect();
return [t.clientX - s.left - e.clientLeft, t.clientY - s.top - e.clientTop]
}
function ie() {
return oo.event.changedTouches[0].identifier
}
function re(e) {
return e > 0 ? 1 : 0 > e ? -1 : 0
}
function ae(e, t, i) {
return (t[0] - e[0]) * (i[1] - e[1]) - (t[1] - e[1]) * (i[0] - e[0])
}
function ne(e) {
return e > 1 ? 0 : -1 > e ? Oo : Math.acos(e)
}
function oe(e) {
return e > 1 ? Uo : -1 > e ? -Uo : Math.asin(e)
}
function se(e) {
return ((e = Math.exp(e)) - 1 / e) / 2
}
function le(e) {
return ((e = Math.exp(e)) + 1 / e) / 2
}
function ce(e) {
return ((e = Math.exp(2 * e)) - 1) / (e + 1)
}
function pe(e) {
return (e = Math.sin(e / 2)) * e
}
function de() {}
function ue(e, t, i) {
return this instanceof ue ? (this.h = +e, this.s = +t, void(this.l = +i)) : arguments.length < 2 ? e instanceof ue ? new ue(e.h, e.s, e.l) : Ie("" + e, ke, ue) : new ue(e, t, i)
}
function fe(e, t, i) {
function r(e) {
return e > 360 ? e -= 360 : 0 > e && (e += 360), 60 > e ? n + (o - n) * e / 60 : 180 > e ? o : 240 > e ? n + (o - n) * (240 - e) / 60 : n
}
function a(e) {
return Math.round(255 * r(e))
}
var n, o;
return e = isNaN(e) ? 0 : (e %= 360) < 0 ? e + 360 : e, t = isNaN(t) ? 0 : 0 > t ? 0 : t > 1 ? 1 : t, i = 0 > i ? 0 : i > 1 ? 1 : i, o = .5 >= i ? i * (1 + t) : i + t - i * t, n = 2 * i - o, new we(a(e + 120), a(e), a(e - 120))
}
function me(e, t, i) {
return this instanceof me ? (this.h = +e, this.c = +t, void(this.l = +i)) : arguments.length < 2 ? e instanceof me ? new me(e.h, e.c, e.l) : e instanceof ge ? ye(e.l, e.a, e.b) : ye((e = Ne((e = oo.rgb(e)).r, e.g, e.b)).l, e.a, e.b) : new me(e, t, i)
}
function he(e, t, i) {
return isNaN(e) && (e = 0), isNaN(t) && (t = 0), new ge(i, Math.cos(e *= Go) * t, Math.sin(e) * t)
}
function ge(e, t, i) {
return this instanceof ge ? (this.l = +e, this.a = +t, void(this.b = +i)) : arguments.length < 2 ? e instanceof ge ? new ge(e.l, e.a, e.b) : e instanceof me ? he(e.h, e.c, e.l) : Ne((e = we(e)).r, e.g, e.b) : new ge(e, t, i)
}
function _e(e, t, i) {
var r = (e + 16) / 116,
a = r + t / 500,
n = r - i / 200;
return a = be(a) * qo, r = be(r) * Ko, n = be(n) * es, new we(xe(3.2404542 * a - 1.5371385 * r - .4985314 * n), xe(-.969266 * a + 1.8760108 * r + .041556 * n), xe(.0556434 * a - .2040259 * r + 1.0572252 * n))
}
function ye(e, t, i) {
return e > 0 ? new me(Math.atan2(i, t) * Bo, Math.sqrt(t * t + i * i), e) : new me(NaN, NaN, e)
}
function be(e) {
return e > .206893034 ? e * e * e : (e - 4 / 29) / 7.787037
}
function ve(e) {
return e > .008856 ? Math.pow(e, 1 / 3) : 7.787037 * e + 4 / 29
}
function xe(e) {
return Math.round(255 * (.00304 >= e ? 12.92 * e : 1.055 * Math.pow(e, 1 / 2.4) - .055))
}
function we(e, t, i) {
return this instanceof we ? (this.r = ~~e, this.g = ~~t, void(this.b = ~~i)) : arguments.length < 2 ? e instanceof we ? new we(e.r, e.g, e.b) : Ie("" + e, we, fe) : new we(e, t, i)
}
function Me(e) {
return new we(e >> 16, e >> 8 & 255, 255 & e)
}
function Le(e) {
return Me(e) + ""
}
function je(e) {
return 16 > e ? "0" + Math.max(0, e).toString(16) : Math.min(255, e).toString(16)
}
function Ie(e, t, i) {
e = e.toLowerCase();
var r, a, n, o = 0,
s = 0,
l = 0;
if (r = /([a-z]+)\((.*)\)/.exec(e)) switch (a = r[2].split(","), r[1]) {
case "hsl":
return i(parseFloat(a[0]), parseFloat(a[1]) / 100, parseFloat(a[2]) / 100);
case "rgb":
return t(Se(a[0]), Se(a[1]), Se(a[2]))
}
return (n = rs.get(e)) ? t(n.r, n.g, n.b) : (null == e || "#" !== e.charAt(0) || isNaN(n = parseInt(e.slice(1), 16)) || (4 === e.length ? (o = (3840 & n) >> 4, o = o >> 4 | o, s = 240 & n, s = s >> 4 | s, l = 15 & n, l = l << 4 | l) : 7 === e.length && (o = (16711680 & n) >> 16, s = (65280 & n) >> 8, l = 255 & n)), t(o, s, l))
}
function ke(e, t, i) {
var r, a, n = Math.min(e /= 255, t /= 255, i /= 255),
o = Math.max(e, t, i),
s = o - n,
l = (o + n) / 2;
return s ? (a = .5 > l ? s / (o + n) : s / (2 - o - n), r = e == o ? (t - i) / s + (i > t ? 6 : 0) : t == o ? (i - e) / s + 2 : (e - t) / s + 4, r *= 60) : (r = NaN, a = l > 0 && 1 > l ? 0 : r), new ue(r, a, l)
}
function Ne(e, t, i) {
e = De(e), t = De(t), i = De(i);
var r = ve((.4124564 * e + .3575761 * t + .1804375 * i) / qo),
a = ve((.2126729 * e + .7151522 * t + .072175 * i) / Ko),
n = ve((.0193339 * e + .119192 * t + .9503041 * i) / es);
return ge(116 * a - 16, 500 * (r - a), 200 * (a - n))
}
function De(e) {
return (e /= 255) <= .04045 ? e / 12.92 : Math.pow((e + .055) / 1.055, 2.4)
}
function Se(e) {
var t = parseFloat(e);
return "%" === e.charAt(e.length - 1) ? Math.round(2.55 * t) : t
}
function Ce(e) {
return "function" == typeof e ? e : function() {
return e
}
}
function ze(e) {
return function(t, i, r) {
return 2 === arguments.length && "function" == typeof i && (r = i, i = null), Te(t, i, e, r)
}
}
function Te(e, t, i, r) {
function a() {
var e, t = l.status;
if (!t && Ae(l) || t >= 200 && 300 > t || 304 === t) {
try {
e = i.call(n, l)
} catch (r) {
return void o.error.call(n, r)
}
o.load.call(n, e)
} else o.error.call(n, l)
}
var n = {},
o = oo.dispatch("beforesend", "progress", "load", "error"),
s = {},
l = new XMLHttpRequest,
c = null;
return !this.XDomainRequest || "withCredentials" in l || !/^(http(s)?:)?\/\//.test(e) || (l = new XDomainRequest), "onload" in l ? l.onload = l.onerror = a : l.onreadystatechange = function() {
l.readyState > 3 && a()
}, l.onprogress = function(e) {
var t = oo.event;
oo.event = e;
try {
o.progress.call(n, l)
} finally {
oo.event = t
}
}, n.header = function(e, t) {
return e = (e + "").toLowerCase(), arguments.length < 2 ? s[e] : (null == t ? delete s[e] : s[e] = t + "", n)
}, n.mimeType = function(e) {
return arguments.length ? (t = null == e ? null : e + "", n) : t
}, n.responseType = function(e) {
return arguments.length ? (c = e, n) : c
}, n.response = function(e) {
return i = e, n
}, ["get", "post"].forEach(function(e) {
n[e] = function() {
return n.send.apply(n, [e].concat(lo(arguments)))
}
}), n.send = function(i, r, a) {
if (2 === arguments.length && "function" == typeof r && (a = r, r = null), l.open(i, e, !0), null == t || "accept" in s || (s.accept = t + ",*/*"), l.setRequestHeader)
for (var p in s) l.setRequestHeader(p, s[p]);
return null != t && l.overrideMimeType && l.overrideMimeType(t), null != c && (l.responseType = c), null != a && n.on("error", a).on("load", function(e) {
a(null, e)
}), o.beforesend.call(n, l), l.send(null == r ? null : r), n
}, n.abort = function() {
return l.abort(), n
}, oo.rebind(n, o, "on"), null == r ? n : n.get(Ee(r))
}
function Ee(e) {
return 1 === e.length ? function(t, i) {
e(null == t ? i : null)
} : e
}
function Ae(e) {
var t = e.responseType;
return t && "text" !== t ? e.response : e.responseText
}
function Pe() {
var e = Oe(),
t = Ze() - e;
t > 24 ? (isFinite(t) && (clearTimeout(ss), ss = setTimeout(Pe, t)), os = 0) : (os = 1, cs(Pe))
}
function Oe() {
var e = Date.now();
for (ls = as; ls;) e >= ls.t && (ls.f = ls.c(e - ls.t)), ls = ls.n;
return e
}
function Ze() {
for (var e, t = as, i = 1 / 0; t;) t.f ? t = e ? e.n = t.n : as = t.n : (t.t < i && (i = t.t), t = (e = t).n);
return ns = e, i
}
function He(e, t) {
return t - (e ? Math.ceil(Math.log(e) / Math.LN10) : 1)
}
function Ue(e, t) {
var i = Math.pow(10, 3 * bo(8 - t));
return {
scale: t > 8 ? function(e) {
return e / i
} : function(e) {
return e * i
},
symbol: e
}
}
function Ge(e) {
var t = e.decimal,
i = e.thousands,
r = e.grouping,
a = e.currency,
n = r && i ? function(e, t) {
for (var a = e.length, n = [], o = 0, s = r[0], l = 0; a > 0 && s > 0 && (l + s + 1 > t && (s = Math.max(1, t - l)), n.push(e.substring(a -= s, a + s)), !((l += s + 1) > t));) s = r[o = (o + 1) % r.length];
return n.reverse().join(i)
} : M;
return function(e) {
var i = ds.exec(e),
r = i[1] || " ",
o = i[2] || ">",
s = i[3] || "-",
l = i[4] || "",
c = i[5],
p = +i[6],
d = i[7],
u = i[8],
f = i[9],
m = 1,
h = "",
g = "",
_ = !1,
y = !0;
switch (u && (u = +u.substring(1)), (c || "0" === r && "=" === o) && (c = r = "0", o = "="), f) {
case "n":
d = !0, f = "g";
break;
case "%":
m = 100, g = "%", f = "f";
break;
case "p":
m = 100, g = "%", f = "r";
break;
case "b":
case "o":
case "x":
case "X":
"#" === l && (h = "0" + f.toLowerCase());
case "c":
y = !1;
case "d":
_ = !0, u = 0;
break;
case "s":
m = -1, f = "r"
}
"$" === l && (h = a[0], g = a[1]), "r" != f || u || (f = "g"), null != u && ("g" == f ? u = Math.max(1, Math.min(21, u)) : "e" != f && "f" != f || (u = Math.max(0, Math.min(20, u)))), f = us.get(f) || Be;
var b = c && d;
return function(e) {
var i = g;
if (_ && e % 1) return "";
var a = 0 > e || 0 === e && 0 > 1 / e ? (e = -e, "-") : "-" === s ? "" : s;
if (0 > m) {
var l = oo.formatPrefix(e, u);
e = l.scale(e), i = l.symbol + g
} else e *= m;
e = f(e, u);
var v, x, w = e.lastIndexOf(".");
if (0 > w) {
var M = y ? e.lastIndexOf("e") : -1;
0 > M ? (v = e, x = "") : (v = e.substring(0, M), x = e.substring(M))
} else v = e.substring(0, w), x = t + e.substring(w + 1);
!c && d && (v = n(v, 1 / 0));
var L = h.length + v.length + x.length + (b ? 0 : a.length),
j = p > L ? new Array(L = p - L + 1).join(r) : "";
return b && (v = n(j + v, j.length ? p - x.length : 1 / 0)), a += h, e = v + x, ("<" === o ? a + e + j : ">" === o ? j + a + e : "^" === o ? j.substring(0, L >>= 1) + a + e + j.substring(L) : a + (b ? e : j + e)) + i
}
}
}
function Be(e) {
return e + ""
}
function Re() {
this._ = new Date(arguments.length > 1 ? Date.UTC.apply(this, arguments) : arguments[0])
}
function Qe(e, t, i) {
function r(t) {
var i = e(t),
r = n(i, 1);
return r - t > t - i ? i : r
}
function a(i) {
return t(i = e(new ms(i - 1)), 1), i
}
function n(e, i) {
return t(e = new ms(+e), i), e
}
function o(e, r, n) {
var o = a(e),
s = [];
if (n > 1)
for (; r > o;) i(o) % n || s.push(new Date(+o)), t(o, 1);
else
for (; r > o;) s.push(new Date(+o)), t(o, 1);
return s
}
function s(e, t, i) {
try {
ms = Re;
var r = new Re;
return r._ = e, o(r, t, i)
} finally {
ms = Date
}
}
e.floor = e, e.round = r, e.ceil = a, e.offset = n, e.range = o;
var l = e.utc = Ve(e);
return l.floor = l, l.round = Ve(r), l.ceil = Ve(a), l.offset = Ve(n), l.range = s, e
}
function Ve(e) {
return function(t, i) {
try {
ms = Re;
var r = new Re;
return r._ = t, e(r, i)._
} finally {
ms = Date
}
}
}
function Fe(e) {
function t(e) {
function t(t) {
for (var i, a, n, o = [], s = -1, l = 0; ++s < r;) 37 === e.charCodeAt(s) && (o.push(e.slice(l, s)), null != (a = gs[i = e.charAt(++s)]) && (i = e.charAt(++s)), (n = N[i]) && (i = n(t, null == a ? "e" === i ? " " : "0" : a)), o.push(i), l = s + 1);
return o.push(e.slice(l, s)), o.join("")
}
var r = e.length;
return t.parse = function(t) {
var r = {
y: 1900,
m: 0,
d: 1,
H: 0,
M: 0,
S: 0,
L: 0,
Z: null
},
a = i(r, e, t, 0);
if (a != t.length) return null;
"p" in r && (r.H = r.H % 12 + 12 * r.p);
var n = null != r.Z && ms !== Re,
o = new(n ? Re : ms);
return "j" in r ? o.setFullYear(r.y, 0, r.j) : "w" in r && ("W" in r || "U" in r) ? (o.setFullYear(r.y, 0, 1), o.setFullYear(r.y, 0, "W" in r ? (r.w + 6) % 7 + 7 * r.W - (o.getDay() + 5) % 7 : r.w + 7 * r.U - (o.getDay() + 6) % 7)) : o.setFullYear(r.y, r.m, r.d), o.setHours(r.H + (r.Z / 100 | 0), r.M + r.Z % 100, r.S, r.L), n ? o._ : o
}, t.toString = function() {
return e
}, t
}
function i(e, t, i, r) {
for (var a, n, o, s = 0, l = t.length, c = i.length; l > s;) {
if (r >= c) return -1;
if (a = t.charCodeAt(s++), 37 === a) {
if (o = t.charAt(s++), n = D[o in gs ? t.charAt(s++) : o], !n || (r = n(e, i, r)) < 0) return -1
} else if (a != i.charCodeAt(r++)) return -1
}
return r
}
function r(e, t, i) {
w.lastIndex = 0;
var r = w.exec(t.slice(i));
return r ? (e.w = M.get(r[0].toLowerCase()), i + r[0].length) : -1
}
function a(e, t, i) {
v.lastIndex = 0;
var r = v.exec(t.slice(i));
return r ? (e.w = x.get(r[0].toLowerCase()), i + r[0].length) : -1
}
function n(e, t, i) {
I.lastIndex = 0;
var r = I.exec(t.slice(i));
return r ? (e.m = k.get(r[0].toLowerCase()), i + r[0].length) : -1
}
function o(e, t, i) {
L.lastIndex = 0;
var r = L.exec(t.slice(i));
return r ? (e.m = j.get(r[0].toLowerCase()), i + r[0].length) : -1
}
function s(e, t, r) {
return i(e, N.c.toString(), t, r)
}
function l(e, t, r) {
return i(e, N.x.toString(), t, r)
}
function c(e, t, r) {
return i(e, N.X.toString(), t, r)
}
function p(e, t, i) {
var r = b.get(t.slice(i, i += 2).toLowerCase());
return null == r ? -1 : (e.p = r, i)
}
var d = e.dateTime,
u = e.date,
f = e.time,
m = e.periods,
h = e.days,
g = e.shortDays,
_ = e.months,
y = e.shortMonths;
t.utc = function(e) {
function i(e) {
try {
ms = Re;
var t = new ms;
return t._ = e, r(t)
} finally {
ms = Date
}
}
var r = t(e);
return i.parse = function(e) {
try {
ms = Re;
var t = r.parse(e);
return t && t._
} finally {
ms = Date
}
}, i.toString = r.toString, i
}, t.multi = t.utc.multi = ut;
var b = oo.map(),
v = Ye(h),
x = Je(h),
w = Ye(g),
M = Je(g),
L = Ye(_),
j = Je(_),
I = Ye(y),
k = Je(y);
m.forEach(function(e, t) {
b.set(e.toLowerCase(), t)
});
var N = {
a: function(e) {
return g[e.getDay()]
},
A: function(e) {
return h[e.getDay()]
},
b: function(e) {
return y[e.getMonth()]
},
B: function(e) {
return _[e.getMonth()]
},
c: t(d),
d: function(e, t) {
return We(e.getDate(), t, 2)
},
e: function(e, t) {
return We(e.getDate(), t, 2)
},
H: function(e, t) {
return We(e.getHours(), t, 2)
},
I: function(e, t) {
return We(e.getHours() % 12 || 12, t, 2)
},
j: function(e, t) {
return We(1 + fs.dayOfYear(e), t, 3)
},
L: function(e, t) {
return We(e.getMilliseconds(), t, 3)
},
m: function(e, t) {
return We(e.getMonth() + 1, t, 2)
},
M: function(e, t) {
return We(e.getMinutes(), t, 2)
},
p: function(e) {
return m[+(e.getHours() >= 12)]
},
S: function(e, t) {
return We(e.getSeconds(), t, 2)
},
U: function(e, t) {
return We(fs.sundayOfYear(e), t, 2)
},
w: function(e) {
return e.getDay()
},
W: function(e, t) {
return We(fs.mondayOfYear(e), t, 2)
},
x: t(u),
X: t(f),
y: function(e, t) {
return We(e.getFullYear() % 100, t, 2)
},
Y: function(e, t) {
return We(e.getFullYear() % 1e4, t, 4)
},
Z: pt,
"%": function() {
return "%"
}
},
D = {
a: r,
A: a,
b: n,
B: o,
c: s,
d: at,
e: at,
H: ot,
I: ot,
j: nt,
L: ct,
m: rt,
M: st,
p: p,
S: lt,
U: $e,
w: Xe,
W: qe,
x: l,
X: c,
y: et,
Y: Ke,
Z: tt,
"%": dt
};
return t
}
function We(e, t, i) {
var r = 0 > e ? "-" : "",
a = (r ? -e : e) + "",
n = a.length;
return r + (i > n ? new Array(i - n + 1).join(t) + a : a)
}
function Ye(e) {
return new RegExp("^(?:" + e.map(oo.requote).join("|") + ")", "i")
}
function Je(e) {
for (var t = new m, i = -1, r = e.length; ++i < r;) t.set(e[i].toLowerCase(), i);
return t
}
function Xe(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 1));
return r ? (e.w = +r[0], i + r[0].length) : -1
}
function $e(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i));
return r ? (e.U = +r[0], i + r[0].length) : -1
}
function qe(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i));
return r ? (e.W = +r[0], i + r[0].length) : -1
}
function Ke(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 4));
return r ? (e.y = +r[0], i + r[0].length) : -1
}
function et(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 2));
return r ? (e.y = it(+r[0]), i + r[0].length) : -1
}
function tt(e, t, i) {
return /^[+-]\d{4}$/.test(t = t.slice(i, i + 5)) ? (e.Z = -t, i + 5) : -1
}
function it(e) {
return e + (e > 68 ? 1900 : 2e3)
}
function rt(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 2));
return r ? (e.m = r[0] - 1, i + r[0].length) : -1
}
function at(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 2));
return r ? (e.d = +r[0], i + r[0].length) : -1
}
function nt(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 3));
return r ? (e.j = +r[0], i + r[0].length) : -1
}
function ot(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 2));
return r ? (e.H = +r[0], i + r[0].length) : -1
}
function st(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 2));
return r ? (e.M = +r[0], i + r[0].length) : -1
}
function lt(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 2));
return r ? (e.S = +r[0], i + r[0].length) : -1
}
function ct(e, t, i) {
_s.lastIndex = 0;
var r = _s.exec(t.slice(i, i + 3));
return r ? (e.L = +r[0], i + r[0].length) : -1
}
function pt(e) {
var t = e.getTimezoneOffset(),
i = t > 0 ? "-" : "+",
r = bo(t) / 60 | 0,
a = bo(t) % 60;
return i + We(r, "0", 2) + We(a, "0", 2)
}
function dt(e, t, i) {
ys.lastIndex = 0;
var r = ys.exec(t.slice(i, i + 1));
return r ? i + r[0].length : -1
}
function ut(e) {
for (var t = e.length, i = -1; ++i < t;) e[i][0] = this(e[i][0]);
return function(t) {
for (var i = 0, r = e[i]; !r[1](t);) r = e[++i];
return r[0](t)
}
}
function ft() {}
function mt(e, t, i) {
var r = i.s = e + t,
a = r - e,
n = r - a;
i.t = e - n + (t - a)
}
function ht(e, t) {
e && ws.hasOwnProperty(e.type) && ws[e.type](e, t)
}
function gt(e, t, i) {
var r, a = -1,
n = e.length - i;
for (t.lineStart(); ++a < n;) r = e[a], t.point(r[0], r[1], r[2]);
t.lineEnd()
}
function _t(e, t) {
var i = -1,
r = e.length;
for (t.polygonStart(); ++i < r;) gt(e[i], t, 1);
t.polygonEnd()
}
function yt() {
function e(e, t) {
e *= Go, t = t * Go / 2 + Oo / 4;
var i = e - r,
o = i >= 0 ? 1 : -1,
s = o * i,
l = Math.cos(t),
c = Math.sin(t),
p = n * c,
d = a * l + p * Math.cos(s),
u = p * o * Math.sin(s);
Ls.add(Math.atan2(u, d)), r = e, a = l, n = c
}
var t, i, r, a, n;
js.point = function(o, s) {
js.point = e, r = (t = o) * Go, a = Math.cos(s = (i = s) * Go / 2 + Oo / 4), n = Math.sin(s)
}, js.lineEnd = function() {
e(t, i)
}
}
function bt(e) {
var t = e[0],
i = e[1],
r = Math.cos(i);
return [r * Math.cos(t), r * Math.sin(t), Math.sin(i)]
}
function vt(e, t) {
return e[0] * t[0] + e[1] * t[1] + e[2] * t[2]
}
function xt(e, t) {
return [e[1] * t[2] - e[2] * t[1], e[2] * t[0] - e[0] * t[2], e[0] * t[1] - e[1] * t[0]]
}
function wt(e, t) {
e[0] += t[0], e[1] += t[1], e[2] += t[2]
}
function Mt(e, t) {
return [e[0] * t, e[1] * t, e[2] * t]
}
function Lt(e) {
var t = Math.sqrt(e[0] * e[0] + e[1] * e[1] + e[2] * e[2]);
e[0] /= t, e[1] /= t, e[2] /= t
}
function jt(e) {
return [Math.atan2(e[1], e[0]), oe(e[2])]
}
function It(e, t) {
return bo(e[0] - t[0]) < Ao && bo(e[1] - t[1]) < Ao
}
function kt(e, t) {
e *= Go;
var i = Math.cos(t *= Go);
Nt(i * Math.cos(e), i * Math.sin(e), Math.sin(t))
}
function Nt(e, t, i) {
++Is, Ns += (e - Ns) / Is, Ds += (t - Ds) / Is, Ss += (i - Ss) / Is
}
function Dt() {
function e(e, a) {
e *= Go;
var n = Math.cos(a *= Go),
o = n * Math.cos(e),
s = n * Math.sin(e),
l = Math.sin(a),
c = Math.atan2(Math.sqrt((c = i * l - r * s) * c + (c = r * o - t * l) * c + (c = t * s - i * o) * c), t * o + i * s + r * l);
ks += c, Cs += c * (t + (t = o)), zs += c * (i + (i = s)), Ts += c * (r + (r = l)), Nt(t, i, r)
}
var t, i, r;
Os.point = function(a, n) {
a *= Go;
var o = Math.cos(n *= Go);
t = o * Math.cos(a), i = o * Math.sin(a), r = Math.sin(n), Os.point = e, Nt(t, i, r)
}
}
function St() {
Os.point = kt
}
function Ct() {
function e(e, t) {
e *= Go;
var i = Math.cos(t *= Go),
o = i * Math.cos(e),
s = i * Math.sin(e),
l = Math.sin(t),
c = a * l - n * s,
p = n * o - r * l,
d = r * s - a * o,
u = Math.sqrt(c * c + p * p + d * d),
f = r * o + a * s + n * l,
m = u && -ne(f) / u,
h = Math.atan2(u, f);
Es += m * c, As += m * p, Ps += m * d, ks += h, Cs += h * (r + (r = o)), zs += h * (a + (a = s)), Ts += h * (n + (n = l)), Nt(r, a, n)
}
var t, i, r, a, n;
Os.point = function(o, s) {
t = o, i = s, Os.point = e, o *= Go;
var l = Math.cos(s *= Go);
r = l * Math.cos(o), a = l * Math.sin(o), n = Math.sin(s), Nt(r, a, n)
}, Os.lineEnd = function() {
e(t, i), Os.lineEnd = St, Os.point = kt
}
}
function zt(e, t) {
function i(i, r) {
return i = e(i, r), t(i[0], i[1])
}
return e.invert && t.invert && (i.invert = function(i, r) {
return i = t.invert(i, r), i && e.invert(i[0], i[1])
}), i
}
function Tt() {
return !0
}
function Et(e, t, i, r, a) {
var n = [],
o = [];
if (e.forEach(function(e) {
if (!((t = e.length - 1) <= 0)) {
var t, i = e[0],
r = e[t];
if (It(i, r)) {
a.lineStart();
for (var s = 0; t > s; ++s) a.point((i = e[s])[0], i[1]);
return void a.lineEnd()
}
var l = new Pt(i, e, null, !0),
c = new Pt(i, null, l, !1);
l.o = c, n.push(l), o.push(c), l = new Pt(r, e, null, !1), c = new Pt(r, null, l, !0), l.o = c, n.push(l), o.push(c)
}
}), o.sort(t), At(n), At(o), n.length) {
for (var s = 0, l = i, c = o.length; c > s; ++s) o[s].e = l = !l;
for (var p, d, u = n[0];;) {
for (var f = u, m = !0; f.v;)
if ((f = f.n) === u) return;
p = f.z, a.lineStart();
do {
if (f.v = f.o.v = !0, f.e) {
if (m)
for (var s = 0, c = p.length; c > s; ++s) a.point((d = p[s])[0], d[1]);
else r(f.x, f.n.x, 1, a);
f = f.n
} else {
if (m) {
p = f.p.z;
for (var s = p.length - 1; s >= 0; --s) a.point((d = p[s])[0], d[1])
} else r(f.x, f.p.x, -1, a);
f = f.p
}
f = f.o, p = f.z, m = !m
} while (!f.v);
a.lineEnd()
}
}
}
function At(e) {
if (t = e.length) {
for (var t, i, r = 0, a = e[0]; ++r < t;) a.n = i = e[r], i.p = a, a = i;
a.n = i = e[0], i.p = a
}
}
function Pt(e, t, i, r) {
this.x = e, this.z = t, this.o = i, this.e = r, this.v = !1, this.n = this.p = null
}
function Ot(e, t, i, r) {
return function(a, n) {
function o(t, i) {
var r = a(t, i);
e(t = r[0], i = r[1]) && n.point(t, i)
}
function s(e, t) {
var i = a(e, t);
g.point(i[0], i[1])
}
function l() {
y.point = s, g.lineStart()
}
function c() {
y.point = o, g.lineEnd()
}
function p(e, t) {
h.push([e, t]);
var i = a(e, t);
v.point(i[0], i[1])
}
function d() {
v.lineStart(), h = []
}
function u() {
p(h[0][0], h[0][1]), v.lineEnd();
var e, t = v.clean(),
i = b.buffer(),
r = i.length;
if (h.pop(), m.push(h), h = null, r)
if (1 & t) {
e = i[0];
var a, r = e.length - 1,
o = -1;
if (r > 0) {
for (x || (n.polygonStart(), x = !0), n.lineStart(); ++o < r;) n.point((a = e[o])[0], a[1]);
n.lineEnd()
}
} else r > 1 && 2 & t && i.push(i.pop().concat(i.shift())), f.push(i.filter(Zt))
}
var f, m, h, g = t(n),
_ = a.invert(r[0], r[1]),
y = {
point: o,
lineStart: l,
lineEnd: c,
polygonStart: function() {
y.point = p, y.lineStart = d, y.lineEnd = u, f = [], m = []
},
polygonEnd: function() {
y.point = o, y.lineStart = l, y.lineEnd = c, f = oo.merge(f);
var e = Qt(_, m);
f.length ? (x || (n.polygonStart(), x = !0), Et(f, Ut, e, i, n)) : e && (x || (n.polygonStart(), x = !0), n.lineStart(), i(null, null, 1, n), n.lineEnd()), x && (n.polygonEnd(), x = !1), f = m = null
},
sphere: function() {
n.polygonStart(), n.lineStart(), i(null, null, 1, n), n.lineEnd(), n.polygonEnd()
}
},
b = Ht(),
v = t(b),
x = !1;
return y
}
}
function Zt(e) {
return e.length > 1
}
function Ht() {
var e, t = [];
return {
lineStart: function() {
t.push(e = [])
},
point: function(t, i) {
e.push([t, i])
},
lineEnd: I,
buffer: function() {
var i = t;
return t = [], e = null, i
},
rejoin: function() {
t.length > 1 && t.push(t.pop().concat(t.shift()))
}
}
}
function Ut(e, t) {
return ((e = e.x)[0] < 0 ? e[1] - Uo - Ao : Uo - e[1]) - ((t = t.x)[0] < 0 ? t[1] - Uo - Ao : Uo - t[1])
}
function Gt(e) {
var t, i = NaN,
r = NaN,
a = NaN;
return {
lineStart: function() {
e.lineStart(), t = 1
},
point: function(n, o) {
var s = n > 0 ? Oo : -Oo,
l = bo(n - i);
bo(l - Oo) < Ao ? (e.point(i, r = (r + o) / 2 > 0 ? Uo : -Uo), e.point(a, r), e.lineEnd(), e.lineStart(), e.point(s, r), e.point(n, r), t = 0) : a !== s && l >= Oo && (bo(i - a) < Ao && (i -= a * Ao), bo(n - s) < Ao && (n -= s * Ao), r = Bt(i, r, n, o), e.point(a, r), e.lineEnd(), e.lineStart(), e.point(s, r), t = 0), e.point(i = n, r = o), a = s
},
lineEnd: function() {
e.lineEnd(), i = r = NaN
},
clean: function() {
return 2 - t
}
}
}
function Bt(e, t, i, r) {
var a, n, o = Math.sin(e - i);
return bo(o) > Ao ? Math.atan((Math.sin(t) * (n = Math.cos(r)) * Math.sin(i) - Math.sin(r) * (a = Math.cos(t)) * Math.sin(e)) / (a * n * o)) : (t + r) / 2
}
function Rt(e, t, i, r) {
var a;
if (null == e) a = i * Uo, r.point(-Oo, a), r.point(0, a), r.point(Oo, a), r.point(Oo, 0), r.point(Oo, -a), r.point(0, -a), r.point(-Oo, -a), r.point(-Oo, 0), r.point(-Oo, a);
else if (bo(e[0] - t[0]) > Ao) {
var n = e[0] < t[0] ? Oo : -Oo;
a = i * n / 2, r.point(-n, a), r.point(0, a), r.point(n, a)
} else r.point(t[0], t[1])
}
function Qt(e, t) {
var i = e[0],
r = e[1],
a = [Math.sin(i), -Math.cos(i), 0],
n = 0,
o = 0;
Ls.reset();
for (var s = 0, l = t.length; l > s; ++s) {
var c = t[s],
p = c.length;
if (p)
for (var d = c[0], u = d[0], f = d[1] / 2 + Oo / 4, m = Math.sin(f), h = Math.cos(f), g = 1;;) {
g === p && (g = 0), e = c[g];
var _ = e[0],
y = e[1] / 2 + Oo / 4,
b = Math.sin(y),
v = Math.cos(y),
x = _ - u,
w = x >= 0 ? 1 : -1,
M = w * x,
L = M > Oo,
j = m * b;
if (Ls.add(Math.atan2(j * w * Math.sin(M), h * v + j * Math.cos(M))), n += L ? x + w * Zo : x, L ^ u >= i ^ _ >= i) {
var I = xt(bt(d), bt(e));
Lt(I);
var k = xt(a, I);
Lt(k);
var N = (L ^ x >= 0 ? -1 : 1) * oe(k[2]);
(r > N || r === N && (I[0] || I[1])) && (o += L ^ x >= 0 ? 1 : -1)
}
if (!g++) break;
u = _, m = b, h = v, d = e
}
}
return (-Ao > n || Ao > n && 0 > Ls) ^ 1 & o
}
function Vt(e) {
function t(e, t) {
return Math.cos(e) * Math.cos(t) > n
}
function i(e) {
var i, n, l, c, p;
return {
lineStart: function() {
c = l = !1, p = 1
},
point: function(d, u) {
var f, m = [d, u],
h = t(d, u),
g = o ? h ? 0 : a(d, u) : h ? a(d + (0 > d ? Oo : -Oo), u) : 0;
if (!i && (c = l = h) && e.lineStart(), h !== l && (f = r(i, m), (It(i, f) || It(m, f)) && (m[0] += Ao, m[1] += Ao, h = t(m[0], m[1]))), h !== l) p = 0, h ? (e.lineStart(), f = r(m, i), e.point(f[0], f[1])) : (f = r(i, m), e.point(f[0], f[1]), e.lineEnd()), i = f;
else if (s && i && o ^ h) {
var _;
g & n || !(_ = r(m, i, !0)) || (p = 0, o ? (e.lineStart(), e.point(_[0][0], _[0][1]), e.point(_[1][0], _[1][1]), e.lineEnd()) : (e.point(_[1][0], _[1][1]), e.lineEnd(), e.lineStart(), e.point(_[0][0], _[0][1])))
}!h || i && It(i, m) || e.point(m[0], m[1]), i = m, l = h, n = g
},
lineEnd: function() {
l && e.lineEnd(), i = null
},
clean: function() {
return p | (c && l) << 1
}
}
}
function r(e, t, i) {
var r = bt(e),
a = bt(t),
o = [1, 0, 0],
s = xt(r, a),
l = vt(s, s),
c = s[0],
p = l - c * c;
if (!p) return !i && e;
var d = n * l / p,
u = -n * c / p,
f = xt(o, s),
m = Mt(o, d),
h = Mt(s, u);
wt(m, h);
var g = f,
_ = vt(m, g),
y = vt(g, g),
b = _ * _ - y * (vt(m, m) - 1);
if (!(0 > b)) {
var v = Math.sqrt(b),
x = Mt(g, (-_ - v) / y);
if (wt(x, m), x = jt(x), !i) return x;
var w, M = e[0],
L = t[0],
j = e[1],
I = t[1];
M > L && (w = M, M = L, L = w);
var k = L - M,
N = bo(k - Oo) < Ao,
D = N || Ao > k;
if (!N && j > I && (w = j, j = I, I = w), D ? N ? j + I > 0 ^ x[1] < (bo(x[0] - M) < Ao ? j : I) : j <= x[1] && x[1] <= I : k > Oo ^ (M <= x[0] && x[0] <= L)) {
var S = Mt(g, (-_ + v) / y);
return wt(S, m), [x, jt(S)]
}
}
}
function a(t, i) {
var r = o ? e : Oo - e,
a = 0;
return -r > t ? a |= 1 : t > r && (a |= 2), -r > i ? a |= 4 : i > r && (a |= 8), a
}
var n = Math.cos(e),
o = n > 0,
s = bo(n) > Ao,
l = yi(e, 6 * Go);
return Ot(t, i, l, o ? [0, -e] : [-Oo, e - Oo])
}
function Ft(e, t, i, r) {
return function(a) {
var n, o = a.a,
s = a.b,
l = o.x,
c = o.y,
p = s.x,
d = s.y,
u = 0,
f = 1,
m = p - l,
h = d - c;
if (n = e - l, m || !(n > 0)) {
if (n /= m, 0 > m) {
if (u > n) return;
f > n && (f = n)
} else if (m > 0) {
if (n > f) return;
n > u && (u = n)
}
if (n = i - l, m || !(0 > n)) {
if (n /= m, 0 > m) {
if (n > f) return;
n > u && (u = n)
} else if (m > 0) {
if (u > n) return;
f > n && (f = n)
}
if (n = t - c, h || !(n > 0)) {
if (n /= h, 0 > h) {
if (u > n) return;
f > n && (f = n)
} else if (h > 0) {
if (n > f) return;
n > u && (u = n)
}
if (n = r - c, h || !(0 > n)) {
if (n /= h, 0 > h) {
if (n > f) return;
n > u && (u = n)
} else if (h > 0) {
if (u > n) return;
f > n && (f = n)
}
return u > 0 && (a.a = {
x: l + u * m,
y: c + u * h
}), 1 > f && (a.b = {
x: l + f * m,
y: c + f * h
}), a
}
}
}
}
}
}
function Wt(e, t, i, r) {
function a(r, a) {
return bo(r[0] - e) < Ao ? a > 0 ? 0 : 3 : bo(r[0] - i) < Ao ? a > 0 ? 2 : 1 : bo(r[1] - t) < Ao ? a > 0 ? 1 : 0 : a > 0 ? 3 : 2
}
function n(e, t) {
return o(e.x, t.x)
}
function o(e, t) {
var i = a(e, 1),
r = a(t, 1);
return i !== r ? i - r : 0 === i ? t[1] - e[1] : 1 === i ? e[0] - t[0] : 2 === i ? e[1] - t[1] : t[0] - e[0]
}
return function(s) {
function l(e) {
for (var t = 0, i = g.length, r = e[1], a = 0; i > a; ++a)
for (var n, o = 1, s = g[a], l = s.length, c = s[0]; l > o; ++o) n = s[o], c[1] <= r ? n[1] > r && ae(c, n, e) > 0 && ++t : n[1] <= r && ae(c, n, e) < 0 && --t, c = n;
return 0 !== t
}
function c(n, s, l, c) {
var p = 0,
d = 0;
if (null == n || (p = a(n, l)) !== (d = a(s, l)) || o(n, s) < 0 ^ l > 0) {
do c.point(0 === p || 3 === p ? e : i, p > 1 ? r : t); while ((p = (p + l + 4) % 4) !== d)
} else c.point(s[0], s[1])
}
function p(a, n) {
return a >= e && i >= a && n >= t && r >= n
}
function d(e, t) {
p(e, t) && s.point(e, t)
}
function u() {
D.point = m, g && g.push(_ = []), L = !0, M = !1, x = w = NaN
}
function f() {
h && (m(y, b), v && M && k.rejoin(), h.push(k.buffer())), D.point = d, M && s.lineEnd()
}
function m(e, t) {
e = Math.max(-Hs, Math.min(Hs, e)), t = Math.max(-Hs, Math.min(Hs, t));
var i = p(e, t);
if (g && _.push([e, t]), L) y = e, b = t, v = i, L = !1, i && (s.lineStart(), s.point(e, t));
else if (i && M) s.point(e, t);
else {
var r = {
a: {
x: x,
y: w
},
b: {
x: e,
y: t
}
};
N(r) ? (M || (s.lineStart(), s.point(r.a.x, r.a.y)), s.point(r.b.x, r.b.y), i || s.lineEnd(), j = !1) : i && (s.lineStart(), s.point(e, t), j = !1)
}
x = e, w = t, M = i
}
var h, g, _, y, b, v, x, w, M, L, j, I = s,
k = Ht(),
N = Ft(e, t, i, r),
D = {
point: d,
lineStart: u,
lineEnd: f,
polygonStart: function() {
s = k, h = [], g = [], j = !0
},
polygonEnd: function() {
s = I, h = oo.merge(h);
var t = l([e, r]),
i = j && t,
a = h.length;
(i || a) && (s.polygonStart(), i && (s.lineStart(), c(null, null, 1, s), s.lineEnd()), a && Et(h, n, t, c, s), s.polygonEnd()), h = g = _ = null
}
};
return D
}
}
function Yt(e) {
var t = 0,
i = Oo / 3,
r = pi(e),
a = r(t, i);
return a.parallels = function(e) {
return arguments.length ? r(t = e[0] * Oo / 180, i = e[1] * Oo / 180) : [t / Oo * 180, i / Oo * 180]
}, a
}
function Jt(e, t) {
function i(e, t) {
var i = Math.sqrt(n - 2 * a * Math.sin(t)) / a;
return [i * Math.sin(e *= a), o - i * Math.cos(e)]
}
var r = Math.sin(e),
a = (r + Math.sin(t)) / 2,
n = 1 + r * (2 * a - r),
o = Math.sqrt(n) / a;
return i.invert = function(e, t) {
var i = o - t;
return [Math.atan2(e, i) / a, oe((n - (e * e + i * i) * a * a) / (2 * a))]
}, i
}
function Xt() {
function e(e, t) {
Gs += a * e - r * t, r = e, a = t
}
var t, i, r, a;
Fs.point = function(n, o) {
Fs.point = e, t = r = n, i = a = o
}, Fs.lineEnd = function() {
e(t, i)
}
}
function $t(e, t) {
Bs > e && (Bs = e), e > Qs && (Qs = e), Rs > t && (Rs = t), t > Vs && (Vs = t)
}
function qt() {
function e(e, t) {
o.push("M", e, ",", t, n)
}
function t(e, t) {
o.push("M", e, ",", t), s.point = i
}
function i(e, t) {
o.push("L", e, ",", t)
}
function r() {
s.point = e
}
function a() {
o.push("Z")
}
var n = Kt(4.5),
o = [],
s = {
point: e,
lineStart: function() {
s.point = t
},
lineEnd: r,
polygonStart: function() {
s.lineEnd = a
},
polygonEnd: function() {
s.lineEnd = r, s.point = e
},
pointRadius: function(e) {
return n = Kt(e), s
},
result: function() {
if (o.length) {
var e = o.join("");
return o = [], e
}
}
};
return s
}
function Kt(e) {
return "m0," + e + "a" + e + "," + e + " 0 1,1 0," + -2 * e + "a" + e + "," + e + " 0 1,1 0," + 2 * e + "z"
}
function ei(e, t) {
Ns += e, Ds += t, ++Ss
}
function ti() {
function e(e, r) {
var a = e - t,
n = r - i,
o = Math.sqrt(a * a + n * n);
Cs += o * (t + e) / 2, zs += o * (i + r) / 2, Ts += o, ei(t = e, i = r)
}
var t, i;
Ys.point = function(r, a) {
Ys.point = e, ei(t = r, i = a)
}
}
function ii() {
Ys.point = ei
}
function ri() {
function e(e, t) {
var i = e - r,
n = t - a,
o = Math.sqrt(i * i + n * n);
Cs += o * (r + e) / 2, zs += o * (a + t) / 2, Ts += o, o = a * e - r * t, Es += o * (r + e), As += o * (a + t), Ps += 3 * o, ei(r = e, a = t)
}
var t, i, r, a;
Ys.point = function(n, o) {
Ys.point = e, ei(t = r = n, i = a = o)
}, Ys.lineEnd = function() {
e(t, i)
}
}
function ai(e) {
function t(t, i) {
e.moveTo(t + o, i), e.arc(t, i, o, 0, Zo)
}
function i(t, i) {
e.moveTo(t, i), s.point = r
}
function r(t, i) {
e.lineTo(t, i)
}
function a() {
s.point = t
}
function n() {
e.closePath()
}
var o = 4.5,
s = {
point: t,
lineStart: function() {
s.point = i
},
lineEnd: a,
polygonStart: function() {
s.lineEnd = n
},
polygonEnd: function() {
s.lineEnd = a, s.point = t
},
pointRadius: function(e) {
return o = e, s
},
result: I
};
return s
}
function ni(e) {
function t(e) {
return (s ? r : i)(e)
}
function i(t) {
return li(t, function(i, r) {
i = e(i, r), t.point(i[0], i[1])
})
}
function r(t) {
function i(i, r) {
i = e(i, r), t.point(i[0], i[1])
}
function r() {
b = NaN, L.point = n, t.lineStart()
}
function n(i, r) {
var n = bt([i, r]),
o = e(i, r);
a(b, v, y, x, w, M, b = o[0], v = o[1], y = i, x = n[0], w = n[1], M = n[2], s, t), t.point(b, v)
}
function o() {
L.point = i, t.lineEnd()
}
function l() {
r(), L.point = c, L.lineEnd = p
}
function c(e, t) {
n(d = e, u = t), f = b, m = v, h = x, g = w, _ = M, L.point = n
}
function p() {
a(b, v, y, x, w, M, f, m, d, h, g, _, s, t), L.lineEnd = o, o()
}
var d, u, f, m, h, g, _, y, b, v, x, w, M, L = {
point: i,
lineStart: r,
lineEnd: o,
polygonStart: function() {
t.polygonStart(), L.lineStart = l
},
polygonEnd: function() {
t.polygonEnd(), L.lineStart = r
}
};
return L
}
function a(t, i, r, s, l, c, p, d, u, f, m, h, g, _) {
var y = p - t,
b = d - i,
v = y * y + b * b;
if (v > 4 * n && g--) {
var x = s + f,
w = l + m,
M = c + h,
L = Math.sqrt(x * x + w * w + M * M),
j = Math.asin(M /= L),
I = bo(bo(M) - 1) < Ao || bo(r - u) < Ao ? (r + u) / 2 : Math.atan2(w, x),
k = e(I, j),
N = k[0],
D = k[1],
S = N - t,
C = D - i,
z = b * S - y * C;
(z * z / v > n || bo((y * S + b * C) / v - .5) > .3 || o > s * f + l * m + c * h) && (a(t, i, r, s, l, c, N, D, I, x /= L, w /= L, M, g, _), _.point(N, D), a(N, D, I, x, w, M, p, d, u, f, m, h, g, _))
}
}
var n = .5,
o = Math.cos(30 * Go),
s = 16;
return t.precision = function(e) {
return arguments.length ? (s = (n = e * e) > 0 && 16, t) : Math.sqrt(n)
}, t
}
function oi(e) {
var t = ni(function(t, i) {
return e([t * Bo, i * Bo])
});
return function(e) {
return di(t(e))
}
}
function si(e) {
this.stream = e
}
function li(e, t) {
return {
point: t,
sphere: function() {
e.sphere()
},
lineStart: function() {
e.lineStart()
},
lineEnd: function() {
e.lineEnd()
},
polygonStart: function() {
e.polygonStart()
},
polygonEnd: function() {
e.polygonEnd()
}
}
}
function ci(e) {
return pi(function() {
return e
})()
}
function pi(e) {
function t(e) {
return e = s(e[0] * Go, e[1] * Go), [e[0] * u + l, c - e[1] * u]
}
function i(e) {
return e = s.invert((e[0] - l) / u, (c - e[1]) / u), e && [e[0] * Bo, e[1] * Bo]
}
function r() {
s = zt(o = mi(_, y, b), n);
var e = n(h, g);
return l = f - e[0] * u, c = m + e[1] * u, a()
}
function a() {
return p && (p.valid = !1, p = null), t
}
var n, o, s, l, c, p, d = ni(function(e, t) {
return e = n(e, t), [e[0] * u + l, c - e[1] * u]
}),
u = 150,
f = 480,
m = 250,
h = 0,
g = 0,
_ = 0,
y = 0,
b = 0,
v = Zs,
x = M,
w = null,
L = null;
return t.stream = function(e) {
return p && (p.valid = !1), p = di(v(o, d(x(e)))), p.valid = !0, p
}, t.clipAngle = function(e) {
return arguments.length ? (v = null == e ? (w = e, Zs) : Vt((w = +e) * Go), a()) : w
}, t.clipExtent = function(e) {
return arguments.length ? (L = e, x = e ? Wt(e[0][0], e[0][1], e[1][0], e[1][1]) : M, a()) : L
}, t.scale = function(e) {
return arguments.length ? (u = +e, r()) : u
}, t.translate = function(e) {
return arguments.length ? (f = +e[0], m = +e[1], r()) : [f, m]
}, t.center = function(e) {
return arguments.length ? (h = e[0] % 360 * Go, g = e[1] % 360 * Go, r()) : [h * Bo, g * Bo]
}, t.rotate = function(e) {
return arguments.length ? (_ = e[0] % 360 * Go, y = e[1] % 360 * Go, b = e.length > 2 ? e[2] % 360 * Go : 0, r()) : [_ * Bo, y * Bo, b * Bo]
}, oo.rebind(t, d, "precision"),
function() {
return n = e.apply(this, arguments), t.invert = n.invert && i, r()
}
}
function di(e) {
return li(e, function(t, i) {
e.point(t * Go, i * Go)
})
}
function ui(e, t) {
return [e, t]
}
function fi(e, t) {
return [e > Oo ? e - Zo : -Oo > e ? e + Zo : e, t]
}
function mi(e, t, i) {
return e ? t || i ? zt(gi(e), _i(t, i)) : gi(e) : t || i ? _i(t, i) : fi
}
function hi(e) {
return function(t, i) {
return t += e, [t > Oo ? t - Zo : -Oo > t ? t + Zo : t, i]
}
}
function gi(e) {
var t = hi(e);
return t.invert = hi(-e), t
}
function _i(e, t) {
function i(e, t) {
var i = Math.cos(t),
s = Math.cos(e) * i,
l = Math.sin(e) * i,
c = Math.sin(t),
p = c * r + s * a;
return [Math.atan2(l * n - p * o, s * r - c * a), oe(p * n + l * o)]
}
var r = Math.cos(e),
a = Math.sin(e),
n = Math.cos(t),
o = Math.sin(t);
return i.invert = function(e, t) {
var i = Math.cos(t),
s = Math.cos(e) * i,
l = Math.sin(e) * i,
c = Math.sin(t),
p = c * n - l * o;
return [Math.atan2(l * n + c * o, s * r + p * a), oe(p * r - s * a)]
}, i
}
function yi(e, t) {
var i = Math.cos(e),
r = Math.sin(e);
return function(a, n, o, s) {
var l = o * t;
null != a ? (a = bi(i, a), n = bi(i, n), (o > 0 ? n > a : a > n) && (a += o * Zo)) : (a = e + o * Zo, n = e - .5 * l);
for (var c, p = a; o > 0 ? p > n : n > p; p -= l) s.point((c = jt([i, -r * Math.cos(p), -r * Math.sin(p)]))[0], c[1])
}
}
function bi(e, t) {
var i = bt(t);
i[0] -= e, Lt(i);
var r = ne(-i[1]);
return ((-i[2] < 0 ? -r : r) + 2 * Math.PI - Ao) % (2 * Math.PI)
}
function vi(e, t, i) {
var r = oo.range(e, t - Ao, i).concat(t);
return function(e) {
return r.map(function(t) {
return [e, t]
})
}
}
function xi(e, t, i) {
var r = oo.range(e, t - Ao, i).concat(t);
return function(e) {
return r.map(function(t) {
return [t, e]
})
}
}
function wi(e) {
return e.source
}
function Mi(e) {
return e.target
}
function Li(e, t, i, r) {
var a = Math.cos(t),
n = Math.sin(t),
o = Math.cos(r),
s = Math.sin(r),
l = a * Math.cos(e),
c = a * Math.sin(e),
p = o * Math.cos(i),
d = o * Math.sin(i),
u = 2 * Math.asin(Math.sqrt(pe(r - t) + a * o * pe(i - e))),
f = 1 / Math.sin(u),
m = u ? function(e) {
var t = Math.sin(e *= u) * f,
i = Math.sin(u - e) * f,
r = i * l + t * p,
a = i * c + t * d,
o = i * n + t * s;
return [Math.atan2(a, r) * Bo, Math.atan2(o, Math.sqrt(r * r + a * a)) * Bo]
} : function() {
return [e * Bo, t * Bo]
};
return m.distance = u, m
}
function ji() {
function e(e, a) {
var n = Math.sin(a *= Go),
o = Math.cos(a),
s = bo((e *= Go) - t),
l = Math.cos(s);
Js += Math.atan2(Math.sqrt((s = o * Math.sin(s)) * s + (s = r * n - i * o * l) * s), i * n + r * o * l), t = e, i = n, r = o
}
var t, i, r;
Xs.point = function(a, n) {
t = a * Go, i = Math.sin(n *= Go), r = Math.cos(n), Xs.point = e
}, Xs.lineEnd = function() {
Xs.point = Xs.lineEnd = I
}
}
function Ii(e, t) {
function i(t, i) {
var r = Math.cos(t),
a = Math.cos(i),
n = e(r * a);
return [n * a * Math.sin(t), n * Math.sin(i)]
}
return i.invert = function(e, i) {
var r = Math.sqrt(e * e + i * i),
a = t(r),
n = Math.sin(a),
o = Math.cos(a);
return [Math.atan2(e * n, r * o), Math.asin(r && i * n / r)]
}, i
}
function ki(e, t) {
function i(e, t) {
o > 0 ? -Uo + Ao > t && (t = -Uo + Ao) : t > Uo - Ao && (t = Uo - Ao);
var i = o / Math.pow(a(t), n);
return [i * Math.sin(n * e), o - i * Math.cos(n * e)]
}
var r = Math.cos(e),
a = function(e) {
return Math.tan(Oo / 4 + e / 2)
},
n = e === t ? Math.sin(e) : Math.log(r / Math.cos(t)) / Math.log(a(t) / a(e)),
o = r * Math.pow(a(e), n) / n;
return n ? (i.invert = function(e, t) {
var i = o - t,
r = re(n) * Math.sqrt(e * e + i * i);
return [Math.atan2(e, i) / n, 2 * Math.atan(Math.pow(o / r, 1 / n)) - Uo]
}, i) : Di
}
function Ni(e, t) {
function i(e, t) {
var i = n - t;
return [i * Math.sin(a * e), n - i * Math.cos(a * e)]
}
var r = Math.cos(e),
a = e === t ? Math.sin(e) : (r - Math.cos(t)) / (t - e),
n = r / a + e;
return bo(a) < Ao ? ui : (i.invert = function(e, t) {
var i = n - t;
return [Math.atan2(e, i) / a, n - re(a) * Math.sqrt(e * e + i * i)]
}, i)
}
function Di(e, t) {
return [e, Math.log(Math.tan(Oo / 4 + t / 2))]
}
function Si(e) {
var t, i = ci(e),
r = i.scale,
a = i.translate,
n = i.clipExtent;
return i.scale = function() {
var e = r.apply(i, arguments);
return e === i ? t ? i.clipExtent(null) : i : e
}, i.translate = function() {
var e = a.apply(i, arguments);
return e === i ? t ? i.clipExtent(null) : i : e
}, i.clipExtent = function(e) {
var o = n.apply(i, arguments);
if (o === i) {
if (t = null == e) {
var s = Oo * r(),
l = a();
n([
[l[0] - s, l[1] - s],
[l[0] + s, l[1] + s]
])
}
} else t && (o = null);
return o
}, i.clipExtent(null)
}
function Ci(e, t) {
return [Math.log(Math.tan(Oo / 4 + t / 2)), -e]
}
function zi(e) {
return e[0]
}
function Ti(e) {
return e[1]
}
function Ei(e) {
for (var t = e.length, i = [0, 1], r = 2, a = 2; t > a; a++) {
for (; r > 1 && ae(e[i[r - 2]], e[i[r - 1]], e[a]) <= 0;) --r;
i[r++] = a
}
return i.slice(0, r)
}
function Ai(e, t) {
return e[0] - t[0] || e[1] - t[1]
}
function Pi(e, t, i) {
return (i[0] - t[0]) * (e[1] - t[1]) < (i[1] - t[1]) * (e[0] - t[0])
}
function Oi(e, t, i, r) {
var a = e[0],
n = i[0],
o = t[0] - a,
s = r[0] - n,
l = e[1],
c = i[1],
p = t[1] - l,
d = r[1] - c,
u = (s * (l - c) - d * (a - n)) / (d * o - s * p);
return [a + u * o, l + u * p]
}
function Zi(e) {
var t = e[0],
i = e[e.length - 1];
return !(t[0] - i[0] || t[1] - i[1])
}
function Hi() {
or(this), this.edge = this.site = this.circle = null
}
function Ui(e) {
var t = ll.pop() || new Hi;
return t.site = e, t
}
function Gi(e) {
$i(e), nl.remove(e), ll.push(e), or(e)
}
function Bi(e) {
var t = e.circle,
i = t.x,
r = t.cy,
a = {
x: i,
y: r
},
n = e.P,
o = e.N,
s = [e];
Gi(e);
for (var l = n; l.circle && bo(i - l.circle.x) < Ao && bo(r - l.circle.cy) < Ao;) n = l.P, s.unshift(l), Gi(l), l = n;
s.unshift(l), $i(l);
for (var c = o; c.circle && bo(i - c.circle.x) < Ao && bo(r - c.circle.cy) < Ao;) o = c.N, s.push(c), Gi(c), c = o;
s.push(c), $i(c);
var p, d = s.length;
for (p = 1; d > p; ++p) c = s[p], l = s[p - 1], rr(c.edge, l.site, c.site, a);
l = s[0], c = s[d - 1], c.edge = tr(l.site, c.site, null, a), Xi(l), Xi(c)
}
function Ri(e) {
for (var t, i, r, a, n = e.x, o = e.y, s = nl._; s;)
if (r = Qi(s, o) - n, r > Ao) s = s.L;
else {
if (a = n - Vi(s, o), !(a > Ao)) {
r > -Ao ? (t = s.P, i = s) : a > -Ao ? (t = s, i = s.N) : t = i = s;
break
}
if (!s.R) {
t = s;
break
}
s = s.R
}
var l = Ui(e);
if (nl.insert(t, l), t || i) {
if (t === i) return $i(t), i = Ui(t.site), nl.insert(l, i), l.edge = i.edge = tr(t.site, l.site), Xi(t), void Xi(i);
if (!i) return void(l.edge = tr(t.site, l.site));
$i(t), $i(i);
var c = t.site,
p = c.x,
d = c.y,
u = e.x - p,
f = e.y - d,
m = i.site,
h = m.x - p,
g = m.y - d,
_ = 2 * (u * g - f * h),
y = u * u + f * f,
b = h * h + g * g,
v = {
x: (g * y - f * b) / _ + p,
y: (u * b - h * y) / _ + d
};
rr(i.edge, c, m, v), l.edge = tr(c, e, null, v), i.edge = tr(e, m, null, v), Xi(t), Xi(i)
}
}
function Qi(e, t) {
var i = e.site,
r = i.x,
a = i.y,
n = a - t;
if (!n) return r;
var o = e.P;
if (!o) return -(1 / 0);
i = o.site;
var s = i.x,
l = i.y,
c = l - t;
if (!c) return s;
var p = s - r,
d = 1 / n - 1 / c,
u = p / c;
return d ? (-u + Math.sqrt(u * u - 2 * d * (p * p / (-2 * c) - l + c / 2 + a - n / 2))) / d + r : (r + s) / 2
}
function Vi(e, t) {
var i = e.N;
if (i) return Qi(i, t);
var r = e.site;
return r.y === t ? r.x : 1 / 0
}
function Fi(e) {
this.site = e, this.edges = []
}
function Wi(e) {
for (var t, i, r, a, n, o, s, l, c, p, d = e[0][0], u = e[1][0], f = e[0][1], m = e[1][1], h = al, g = h.length; g--;)
if (n = h[g], n && n.prepare())
for (s = n.edges, l = s.length, o = 0; l > o;) p = s[o].end(), r = p.x, a = p.y, c = s[++o % l].start(), t = c.x, i = c.y, (bo(r - t) > Ao || bo(a - i) > Ao) && (s.splice(o, 0, new ar(ir(n.site, p, bo(r - d) < Ao && m - a > Ao ? {
x: d,
y: bo(t - d) < Ao ? i : m
} : bo(a - m) < Ao && u - r > Ao ? {
x: bo(i - m) < Ao ? t : u,
y: m
} : bo(r - u) < Ao && a - f > Ao ? {
x: u,
y: bo(t - u) < Ao ? i : f
} : bo(a - f) < Ao && r - d > Ao ? {
x: bo(i - f) < Ao ? t : d,
y: f
} : null), n.site, null)), ++l)
}
function Yi(e, t) {
return t.angle - e.angle
}
function Ji() {
or(this), this.x = this.y = this.arc = this.site = this.cy = null
}
function Xi(e) {
var t = e.P,
i = e.N;
if (t && i) {
var r = t.site,
a = e.site,
n = i.site;
if (r !== n) {
var o = a.x,
s = a.y,
l = r.x - o,
c = r.y - s,
p = n.x - o,
d = n.y - s,
u = 2 * (l * d - c * p);
if (!(u >= -Po)) {
var f = l * l + c * c,
m = p * p + d * d,
h = (d * f - c * m) / u,
g = (l * m - p * f) / u,
d = g + s,
_ = cl.pop() || new Ji;
_.arc = e, _.site = a, _.x = h + o, _.y = d + Math.sqrt(h * h + g * g), _.cy = d, e.circle = _;
for (var y = null, b = sl._; b;)
if (_.y < b.y || _.y === b.y && _.x <= b.x) {
if (!b.L) {
y = b.P;
break
}
b = b.L
} else {
if (!b.R) {
y = b;
break
}
b = b.R
}
sl.insert(y, _), y || (ol = _)
}
}
}
}
function $i(e) {
var t = e.circle;
t && (t.P || (ol = t.N), sl.remove(t), cl.push(t), or(t), e.circle = null)
}
function qi(e) {
for (var t, i = rl, r = Ft(e[0][0], e[0][1], e[1][0], e[1][1]), a = i.length; a--;) t = i[a], (!Ki(t, e) || !r(t) || bo(t.a.x - t.b.x) < Ao && bo(t.a.y - t.b.y) < Ao) && (t.a = t.b = null, i.splice(a, 1))
}
function Ki(e, t) {
var i = e.b;
if (i) return !0;
var r, a, n = e.a,
o = t[0][0],
s = t[1][0],
l = t[0][1],
c = t[1][1],
p = e.l,
d = e.r,
u = p.x,
f = p.y,
m = d.x,
h = d.y,
g = (u + m) / 2,
_ = (f + h) / 2;
if (h === f) {
if (o > g || g >= s) return;
if (u > m) {
if (n) {
if (n.y >= c) return
} else n = {
x: g,
y: l
};
i = {
x: g,
y: c
}
} else {
if (n) {
if (n.y < l) return
} else n = {
x: g,
y: c
};
i = {
x: g,
y: l
}
}
} else if (r = (u - m) / (h - f), a = _ - r * g, -1 > r || r > 1)
if (u > m) {
if (n) {
if (n.y >= c) return
} else n = {
x: (l - a) / r,
y: l
};
i = {
x: (c - a) / r,
y: c
}
} else {
if (n) {
if (n.y < l) return
} else n = {
x: (c - a) / r,
y: c
};
i = {
x: (l - a) / r,
y: l
}
}
else if (h > f) {
if (n) {
if (n.x >= s) return
} else n = {
x: o,
y: r * o + a
};
i = {
x: s,
y: r * s + a
}
} else {
if (n) {
if (n.x < o) return
} else n = {
x: s,
y: r * s + a
};
i = {
x: o,
y: r * o + a
}
}
return e.a = n, e.b = i, !0
}
function er(e, t) {
this.l = e, this.r = t, this.a = this.b = null
}
function tr(e, t, i, r) {
var a = new er(e, t);
return rl.push(a), i && rr(a, e, t, i), r && rr(a, t, e, r), al[e.i].edges.push(new ar(a, e, t)), al[t.i].edges.push(new ar(a, t, e)), a
}
function ir(e, t, i) {
var r = new er(e, null);
return r.a = t, r.b = i, rl.push(r), r
}
function rr(e, t, i, r) {
e.a || e.b ? e.l === i ? e.b = r : e.a = r : (e.a = r, e.l = t, e.r = i)
}
function ar(e, t, i) {
var r = e.a,
a = e.b;
this.edge = e, this.site = t, this.angle = i ? Math.atan2(i.y - t.y, i.x - t.x) : e.l === t ? Math.atan2(a.x - r.x, r.y - a.y) : Math.atan2(r.x - a.x, a.y - r.y)
}
function nr() {
this._ = null
}
function or(e) {
e.U = e.C = e.L = e.R = e.P = e.N = null
}
function sr(e, t) {
var i = t,
r = t.R,
a = i.U;
a ? a.L === i ? a.L = r : a.R = r : e._ = r, r.U = a, i.U = r, i.R = r.L, i.R && (i.R.U = i), r.L = i
}
function lr(e, t) {
var i = t,
r = t.L,
a = i.U;
a ? a.L === i ? a.L = r : a.R = r : e._ = r, r.U = a, i.U = r, i.L = r.R, i.L && (i.L.U = i), r.R = i
}
function cr(e) {
for (; e.L;) e = e.L;
return e
}
function pr(e, t) {
var i, r, a, n = e.sort(dr).pop();
for (rl = [], al = new Array(e.length), nl = new nr, sl = new nr;;)
if (a = ol, n && (!a || n.y < a.y || n.y === a.y && n.x < a.x)) n.x === i && n.y === r || (al[n.i] = new Fi(n), Ri(n), i = n.x, r = n.y), n = e.pop();
else {
if (!a) break;
Bi(a.arc)
}
t && (qi(t), Wi(t));
var o = {
cells: al,
edges: rl
};
return nl = sl = rl = al = null, o
}
function dr(e, t) {
return t.y - e.y || t.x - e.x
}
function ur(e, t, i) {
return (e.x - i.x) * (t.y - e.y) - (e.x - t.x) * (i.y - e.y)
}
function fr(e) {
return e.x
}
function mr(e) {
return e.y
}
function hr() {
return {
leaf: !0,
nodes: [],
point: null,
x: null,
y: null
}
}
function gr(e, t, i, r, a, n) {
if (!e(t, i, r, a, n)) {
var o = .5 * (i + a),
s = .5 * (r + n),
l = t.nodes;
l[0] && gr(e, l[0], i, r, o, s), l[1] && gr(e, l[1], o, r, a, s), l[2] && gr(e, l[2], i, s, o, n), l[3] && gr(e, l[3], o, s, a, n)
}
}
function _r(e, t, i, r, a, n, o) {
var s, l = 1 / 0;
return function c(e, p, d, u, f) {
if (!(p > n || d > o || r > u || a > f)) {
if (m = e.point) {
var m, h = t - e.x,
g = i - e.y,
_ = h * h + g * g;
if (l > _) {
var y = Math.sqrt(l = _);
r = t - y, a = i - y, n = t + y, o = i + y, s = m
}
}
for (var b = e.nodes, v = .5 * (p + u), x = .5 * (d + f), w = t >= v, M = i >= x, L = M << 1 | w, j = L + 4; j > L; ++L)
if (e = b[3 & L]) switch (3 & L) {
case 0:
c(e, p, d, v, x);
break;
case 1:
c(e, v, d, u, x);
break;
case 2:
c(e, p, x, v, f);
break;
case 3:
c(e, v, x, u, f)
}
}
}(e, r, a, n, o), s
}
function yr(e, t) {
e = oo.rgb(e), t = oo.rgb(t);
var i = e.r,
r = e.g,
a = e.b,
n = t.r - i,
o = t.g - r,
s = t.b - a;
return function(e) {
return "#" + je(Math.round(i + n * e)) + je(Math.round(r + o * e)) + je(Math.round(a + s * e))
}
}
function br(e, t) {
var i, r = {},
a = {};
for (i in e) i in t ? r[i] = wr(e[i], t[i]) : a[i] = e[i];
for (i in t) i in e || (a[i] = t[i]);
return function(e) {
for (i in r) a[i] = r[i](e);
return a
}
}
function vr(e, t) {
return e = +e, t = +t,
function(i) {
return e * (1 - i) + t * i
}
}
function xr(e, t) {
var i, r, a, n = dl.lastIndex = ul.lastIndex = 0,
o = -1,
s = [],
l = [];
for (e += "", t += "";
(i = dl.exec(e)) && (r = ul.exec(t));)(a = r.index) > n && (a = t.slice(n, a), s[o] ? s[o] += a : s[++o] = a), (i = i[0]) === (r = r[0]) ? s[o] ? s[o] += r : s[++o] = r : (s[++o] = null, l.push({
i: o,
x: vr(i, r)
})), n = ul.lastIndex;
return n < t.length && (a = t.slice(n), s[o] ? s[o] += a : s[++o] = a), s.length < 2 ? l[0] ? (t = l[0].x, function(e) {
return t(e) + ""
}) : function() {
return t
} : (t = l.length, function(e) {
for (var i, r = 0; t > r; ++r) s[(i = l[r]).i] = i.x(e);
return s.join("")
})
}
function wr(e, t) {
for (var i, r = oo.interpolators.length; --r >= 0 && !(i = oo.interpolators[r](e, t)););
return i
}
function Mr(e, t) {
var i, r = [],
a = [],
n = e.length,
o = t.length,
s = Math.min(e.length, t.length);
for (i = 0; s > i; ++i) r.push(wr(e[i], t[i]));
for (; n > i; ++i) a[i] = e[i];
for (; o > i; ++i) a[i] = t[i];
return function(e) {
for (i = 0; s > i; ++i) a[i] = r[i](e);
return a
}
}
function Lr(e) {
return function(t) {
return 0 >= t ? 0 : t >= 1 ? 1 : e(t)
}
}
function jr(e) {
return function(t) {
return 1 - e(1 - t)
}
}
function Ir(e) {
return function(t) {
return .5 * (.5 > t ? e(2 * t) : 2 - e(2 - 2 * t))
}
}
function kr(e) {
return e * e
}
function Nr(e) {
return e * e * e
}
function Dr(e) {
if (0 >= e) return 0;
if (e >= 1) return 1;
var t = e * e,
i = t * e;
return 4 * (.5 > e ? i : 3 * (e - t) + i - .75)
}
function Sr(e) {
return function(t) {
return Math.pow(t, e)
}
}
function Cr(e) {
return 1 - Math.cos(e * Uo)
}
function zr(e) {
return Math.pow(2, 10 * (e - 1))
}
function Tr(e) {
return 1 - Math.sqrt(1 - e * e)
}
function Er(e, t) {
var i;
return arguments.length < 2 && (t = .45), arguments.length ? i = t / Zo * Math.asin(1 / e) : (e = 1, i = t / 4),
function(r) {
return 1 + e * Math.pow(2, -10 * r) * Math.sin((r - i) * Zo / t)
}
}
function Ar(e) {
return e || (e = 1.70158),
function(t) {
return t * t * ((e + 1) * t - e)
}
}
function Pr(e) {
return 1 / 2.75 > e ? 7.5625 * e * e : 2 / 2.75 > e ? 7.5625 * (e -= 1.5 / 2.75) * e + .75 : 2.5 / 2.75 > e ? 7.5625 * (e -= 2.25 / 2.75) * e + .9375 : 7.5625 * (e -= 2.625 / 2.75) * e + .984375
}
function Or(e, t) {
e = oo.hcl(e), t = oo.hcl(t);
var i = e.h,
r = e.c,
a = e.l,
n = t.h - i,
o = t.c - r,
s = t.l - a;
return isNaN(o) && (o = 0, r = isNaN(r) ? t.c : r), isNaN(n) ? (n = 0, i = isNaN(i) ? t.h : i) : n > 180 ? n -= 360 : -180 > n && (n += 360),
function(e) {
return he(i + n * e, r + o * e, a + s * e) + ""
}
}
function Zr(e, t) {
e = oo.hsl(e), t = oo.hsl(t);
var i = e.h,
r = e.s,
a = e.l,
n = t.h - i,
o = t.s - r,
s = t.l - a;
return isNaN(o) && (o = 0, r = isNaN(r) ? t.s : r), isNaN(n) ? (n = 0, i = isNaN(i) ? t.h : i) : n > 180 ? n -= 360 : -180 > n && (n += 360),
function(e) {
return fe(i + n * e, r + o * e, a + s * e) + ""
}
}
function Hr(e, t) {
e = oo.lab(e), t = oo.lab(t);
var i = e.l,
r = e.a,
a = e.b,
n = t.l - i,
o = t.a - r,
s = t.b - a;
return function(e) {
return _e(i + n * e, r + o * e, a + s * e) + ""
}
}
function Ur(e, t) {
return t -= e,
function(i) {
return Math.round(e + t * i)
}
}
function Gr(e) {
var t = [e.a, e.b],
i = [e.c, e.d],
r = Rr(t),
a = Br(t, i),
n = Rr(Qr(i, t, -a)) || 0;
t[0] * i[1] < i[0] * t[1] && (t[0] *= -1, t[1] *= -1, r *= -1, a *= -1), this.rotate = (r ? Math.atan2(t[1], t[0]) : Math.atan2(-i[0], i[1])) * Bo, this.translate = [e.e, e.f], this.scale = [r, n], this.skew = n ? Math.atan2(a, n) * Bo : 0
}
function Br(e, t) {
return e[0] * t[0] + e[1] * t[1]
}
function Rr(e) {
var t = Math.sqrt(Br(e, e));
return t && (e[0] /= t, e[1] /= t), t
}
function Qr(e, t, i) {
return e[0] += i * t[0], e[1] += i * t[1], e
}
function Vr(e, t) {
var i, r = [],
a = [],
n = oo.transform(e),
o = oo.transform(t),
s = n.translate,
l = o.translate,
c = n.rotate,
p = o.rotate,
d = n.skew,
u = o.skew,
f = n.scale,
m = o.scale;
return s[0] != l[0] || s[1] != l[1] ? (r.push("translate(", null, ",", null, ")"), a.push({
i: 1,
x: vr(s[0], l[0])
}, {
i: 3,
x: vr(s[1], l[1])
})) : l[0] || l[1] ? r.push("translate(" + l + ")") : r.push(""), c != p ? (c - p > 180 ? p += 360 : p - c > 180 && (c += 360), a.push({
i: r.push(r.pop() + "rotate(", null, ")") - 2,
x: vr(c, p)
})) : p && r.push(r.pop() + "rotate(" + p + ")"), d != u ? a.push({
i: r.push(r.pop() + "skewX(", null, ")") - 2,
x: vr(d, u)
}) : u && r.push(r.pop() + "skewX(" + u + ")"), f[0] != m[0] || f[1] != m[1] ? (i = r.push(r.pop() + "scale(", null, ",", null, ")"), a.push({
i: i - 4,
x: vr(f[0], m[0])
}, {
i: i - 2,
x: vr(f[1], m[1])
})) : 1 == m[0] && 1 == m[1] || r.push(r.pop() + "scale(" + m + ")"), i = a.length,
function(e) {
for (var t, n = -1; ++n < i;) r[(t = a[n]).i] = t.x(e);
return r.join("")
}
}
function Fr(e, t) {
return t = (t -= e = +e) || 1 / t,
function(i) {
return (i - e) / t
}
}
function Wr(e, t) {
return t = (t -= e = +e) || 1 / t,
function(i) {
return Math.max(0, Math.min(1, (i - e) / t))
}
}
function Yr(e) {
for (var t = e.source, i = e.target, r = Xr(t, i), a = [t]; t !== r;) t = t.parent, a.push(t);
for (var n = a.length; i !== r;) a.splice(n, 0, i), i = i.parent;
return a
}
function Jr(e) {
for (var t = [], i = e.parent; null != i;) t.push(e), e = i, i = i.parent;
return t.push(e), t
}
function Xr(e, t) {
if (e === t) return e;
for (var i = Jr(e), r = Jr(t), a = i.pop(), n = r.pop(), o = null; a === n;) o = a, a = i.pop(), n = r.pop();
return o
}
function $r(e) {
e.fixed |= 2
}
function qr(e) {
e.fixed &= -7
}
function Kr(e) {
e.fixed |= 4, e.px = e.x, e.py = e.y
}
function ea(e) {
e.fixed &= -5
}
function ta(e, t, i) {
var r = 0,
a = 0;
if (e.charge = 0, !e.leaf)
for (var n, o = e.nodes, s = o.length, l = -1; ++l < s;) n = o[l], null != n && (ta(n, t, i), e.charge += n.charge, r += n.charge * n.cx, a += n.charge * n.cy);
if (e.point) {
e.leaf || (e.point.x += Math.random() - .5, e.point.y += Math.random() - .5);
var c = t * i[e.point.index];
e.charge += e.pointCharge = c, r += c * e.point.x, a += c * e.point.y
}
e.cx = r / e.charge, e.cy = a / e.charge
}
function ia(e, t) {
return oo.rebind(e, t, "sort", "children", "value"), e.nodes = e, e.links = la, e
}
function ra(e, t) {
for (var i = [e]; null != (e = i.pop());)
if (t(e), (a = e.children) && (r = a.length))
for (var r, a; --r >= 0;) i.push(a[r])
}
function aa(e, t) {
for (var i = [e], r = []; null != (e = i.pop());)
if (r.push(e), (n = e.children) && (a = n.length))
for (var a, n, o = -1; ++o < a;) i.push(n[o]);
for (; null != (e = r.pop());) t(e)
}
function na(e) {
return e.children
}
function oa(e) {
return e.value
}
function sa(e, t) {
return t.value - e.value
}
function la(e) {
return oo.merge(e.map(function(e) {
return (e.children || []).map(function(t) {
return {
source: e,
target: t
}
})
}))
}
function ca(e) {
return e.x
}
function pa(e) {
return e.y
}
function da(e, t, i) {
e.y0 = t, e.y = i
}
function ua(e) {
return oo.range(e.length)
}
function fa(e) {
for (var t = -1, i = e[0].length, r = []; ++t < i;) r[t] = 0;
return r
}
function ma(e) {
for (var t, i = 1, r = 0, a = e[0][1], n = e.length; n > i; ++i)(t = e[i][1]) > a && (r = i, a = t);
return r
}
function ha(e) {
return e.reduce(ga, 0)
}
function ga(e, t) {
return e + t[1]
}
function _a(e, t) {
return ya(e, Math.ceil(Math.log(t.length) / Math.LN2 + 1))
}
function ya(e, t) {
for (var i = -1, r = +e[0], a = (e[1] - r) / t, n = []; ++i <= t;) n[i] = a * i + r;
return n
}
function ba(e) {
return [oo.min(e), oo.max(e)]
}
function va(e, t) {
return e.value - t.value
}
function xa(e, t) {
var i = e._pack_next;
e._pack_next = t, t._pack_prev = e, t._pack_next = i, i._pack_prev = t
}
function wa(e, t) {
e._pack_next = t, t._pack_prev = e
}
function Ma(e, t) {
var i = t.x - e.x,
r = t.y - e.y,
a = e.r + t.r;
return .999 * a * a > i * i + r * r
}
function La(e) {
function t(e) {
p = Math.min(e.x - e.r, p), d = Math.max(e.x + e.r, d), u = Math.min(e.y - e.r, u), f = Math.max(e.y + e.r, f)
}
if ((i = e.children) && (c = i.length)) {
var i, r, a, n, o, s, l, c, p = 1 / 0,
d = -(1 / 0),
u = 1 / 0,
f = -(1 / 0);
if (i.forEach(ja), r = i[0], r.x = -r.r, r.y = 0, t(r), c > 1 && (a = i[1], a.x = a.r, a.y = 0, t(a), c > 2))
for (n = i[2], Na(r, a, n), t(n), xa(r, n), r._pack_prev = n, xa(n, a), a = r._pack_next, o = 3; c > o; o++) {
Na(r, a, n = i[o]);
var m = 0,
h = 1,
g = 1;
for (s = a._pack_next; s !== a; s = s._pack_next, h++)
if (Ma(s, n)) {
m = 1;
break
}
if (1 == m)
for (l = r._pack_prev; l !== s._pack_prev && !Ma(l, n); l = l._pack_prev, g++);
m ? (g > h || h == g && a.r < r.r ? wa(r, a = s) : wa(r = l, a), o--) : (xa(r, n), a = n, t(n))
}
var _ = (p + d) / 2,
y = (u + f) / 2,
b = 0;
for (o = 0; c > o; o++) n = i[o], n.x -= _, n.y -= y, b = Math.max(b, n.r + Math.sqrt(n.x * n.x + n.y * n.y));
e.r = b, i.forEach(Ia)
}
}
function ja(e) {
e._pack_next = e._pack_prev = e
}
function Ia(e) {
delete e._pack_next, delete e._pack_prev
}
function ka(e, t, i, r) {
var a = e.children;
if (e.x = t += r * e.x, e.y = i += r * e.y, e.r *= r, a)
for (var n = -1, o = a.length; ++n < o;) ka(a[n], t, i, r)
}
function Na(e, t, i) {
var r = e.r + i.r,
a = t.x - e.x,
n = t.y - e.y;
if (r && (a || n)) {
var o = t.r + i.r,
s = a * a + n * n;
o *= o, r *= r;
var l = .5 + (r - o) / (2 * s),
c = Math.sqrt(Math.max(0, 2 * o * (r + s) - (r -= s) * r - o * o)) / (2 * s);
i.x = e.x + l * a + c * n, i.y = e.y + l * n - c * a
} else i.x = e.x + r, i.y = e.y
}
function Da(e, t) {
return e.parent == t.parent ? 1 : 2
}
function Sa(e) {
var t = e.children;
return t.length ? t[0] : e.t
}
function Ca(e) {
var t, i = e.children;
return (t = i.length) ? i[t - 1] : e.t
}
function za(e, t, i) {
var r = i / (t.i - e.i);
t.c -= r, t.s += i, e.c += r, t.z += i, t.m += i
}
function Ta(e) {
for (var t, i = 0, r = 0, a = e.children, n = a.length; --n >= 0;) t = a[n], t.z += i, t.m += i, i += t.s + (r += t.c)
}
function Ea(e, t, i) {
return e.a.parent === t.parent ? e.a : i
}
function Aa(e) {
return 1 + oo.max(e, function(e) {
return e.y
})
}
function Pa(e) {
return e.reduce(function(e, t) {
return e + t.x
}, 0) / e.length
}
function Oa(e) {
var t = e.children;
return t && t.length ? Oa(t[0]) : e
}
function Za(e) {
var t, i = e.children;
return i && (t = i.length) ? Za(i[t - 1]) : e
}
function Ha(e) {
return {
x: e.x,
y: e.y,
dx: e.dx,
dy: e.dy
}
}
function Ua(e, t) {
var i = e.x + t[3],
r = e.y + t[0],
a = e.dx - t[1] - t[3],
n = e.dy - t[0] - t[2];
return 0 > a && (i += a / 2, a = 0), 0 > n && (r += n / 2, n = 0), {
x: i,
y: r,
dx: a,
dy: n
}
}
function Ga(e) {
var t = e[0],
i = e[e.length - 1];
return i > t ? [t, i] : [i, t]
}
function Ba(e) {
return e.rangeExtent ? e.rangeExtent() : Ga(e.range())
}
function Ra(e, t, i, r) {
var a = i(e[0], e[1]),
n = r(t[0], t[1]);
return function(e) {
return n(a(e))
}
}
function Qa(e, t) {
var i, r = 0,
a = e.length - 1,
n = e[r],
o = e[a];
return n > o && (i = r, r = a, a = i, i = n, n = o, o = i), e[r] = t.floor(n), e[a] = t.ceil(o), e
}
function Va(e) {
return e ? {
floor: function(t) {
return Math.floor(t / e) * e
},
ceil: function(t) {
return Math.ceil(t / e) * e
}
} : Ml
}
function Fa(e, t, i, r) {
var a = [],
n = [],
o = 0,
s = Math.min(e.length, t.length) - 1;
for (e[s] < e[0] && (e = e.slice().reverse(), t = t.slice().reverse()); ++o <= s;) a.push(i(e[o - 1], e[o])), n.push(r(t[o - 1], t[o]));
return function(t) {
var i = oo.bisect(e, t, 1, s) - 1;
return n[i](a[i](t))
}
}
function Wa(e, t, i, r) {
function a() {
var a = Math.min(e.length, t.length) > 2 ? Fa : Ra,
l = r ? Wr : Fr;
return o = a(e, t, l, i), s = a(t, e, l, wr), n
}
function n(e) {
return o(e)
}
var o, s;
return n.invert = function(e) {
return s(e)
}, n.domain = function(t) {
return arguments.length ? (e = t.map(Number), a()) : e
}, n.range = function(e) {
return arguments.length ? (t = e, a()) : t
}, n.rangeRound = function(e) {
return n.range(e).interpolate(Ur)
}, n.clamp = function(e) {
return arguments.length ? (r = e, a()) : r
}, n.interpolate = function(e) {
return arguments.length ? (i = e, a()) : i
}, n.ticks = function(t) {
return $a(e, t)
}, n.tickFormat = function(t, i) {
return qa(e, t, i)
}, n.nice = function(t) {
return Ja(e, t), a()
}, n.copy = function() {
return Wa(e, t, i, r)
}, a()
}
function Ya(e, t) {
return oo.rebind(e, t, "range", "rangeRound", "interpolate", "clamp")
}
function Ja(e, t) {
return Qa(e, Va(Xa(e, t)[2]))
}
function Xa(e, t) {
null == t && (t = 10);
var i = Ga(e),
r = i[1] - i[0],
a = Math.pow(10, Math.floor(Math.log(r / t) / Math.LN10)),
n = t / r * a;
return .15 >= n ? a *= 10 : .35 >= n ? a *= 5 : .75 >= n && (a *= 2), i[0] = Math.ceil(i[0] / a) * a, i[1] = Math.floor(i[1] / a) * a + .5 * a, i[2] = a, i
}
function $a(e, t) {
return oo.range.apply(oo, Xa(e, t))
}
function qa(e, t, i) {
var r = Xa(e, t);
if (i) {
var a = ds.exec(i);
if (a.shift(), "s" === a[8]) {
var n = oo.formatPrefix(Math.max(bo(r[0]), bo(r[1])));
return a[7] || (a[7] = "." + Ka(n.scale(r[2]))), a[8] = "f", i = oo.format(a.join("")),
function(e) {
return i(n.scale(e)) + n.symbol
}
}
a[7] || (a[7] = "." + en(a[8], r)), i = a.join("")
} else i = ",." + Ka(r[2]) + "f";
return oo.format(i)
}
function Ka(e) {
return -Math.floor(Math.log(e) / Math.LN10 + .01)
}
function en(e, t) {
var i = Ka(t[2]);
return e in Ll ? Math.abs(i - Ka(Math.max(bo(t[0]), bo(t[1])))) + +("e" !== e) : i - 2 * ("%" === e)
}
function tn(e, t, i, r) {
function a(e) {
return (i ? Math.log(0 > e ? 0 : e) : -Math.log(e > 0 ? 0 : -e)) / Math.log(t)
}
function n(e) {
return i ? Math.pow(t, e) : -Math.pow(t, -e)
}
function o(t) {
return e(a(t))
}
return o.invert = function(t) {
return n(e.invert(t))
}, o.domain = function(t) {
return arguments.length ? (i = t[0] >= 0, e.domain((r = t.map(Number)).map(a)), o) : r
}, o.base = function(i) {
return arguments.length ? (t = +i, e.domain(r.map(a)), o) : t
}, o.nice = function() {
var t = Qa(r.map(a), i ? Math : Il);
return e.domain(t), r = t.map(n), o
}, o.ticks = function() {
var e = Ga(r),
o = [],
s = e[0],
l = e[1],
c = Math.floor(a(s)),
p = Math.ceil(a(l)),
d = t % 1 ? 2 : t;
if (isFinite(p - c)) {
if (i) {
for (; p > c; c++)
for (var u = 1; d > u; u++) o.push(n(c) * u);
o.push(n(c))
} else
for (o.push(n(c)); c++ < p;)
for (var u = d - 1; u > 0; u--) o.push(n(c) * u);
for (c = 0; o[c] < s; c++);
for (p = o.length; o[p - 1] > l; p--);
o = o.slice(c, p)
}
return o
}, o.tickFormat = function(e, t) {
if (!arguments.length) return jl;
arguments.length < 2 ? t = jl : "function" != typeof t && (t = oo.format(t));
var r, s = Math.max(.1, e / o.ticks().length),
l = i ? (r = 1e-12, Math.ceil) : (r = -1e-12, Math.floor);
return function(e) {
return e / n(l(a(e) + r)) <= s ? t(e) : ""
}
}, o.copy = function() {
return tn(e.copy(), t, i, r)
}, Ya(o, e)
}
function rn(e, t, i) {
function r(t) {
return e(a(t))
}
var a = an(t),
n = an(1 / t);
return r.invert = function(t) {
return n(e.invert(t))
}, r.domain = function(t) {
return arguments.length ? (e.domain((i = t.map(Number)).map(a)), r) : i
}, r.ticks = function(e) {
return $a(i, e)
}, r.tickFormat = function(e, t) {
return qa(i, e, t)
}, r.nice = function(e) {
return r.domain(Ja(i, e))
}, r.exponent = function(o) {
return arguments.length ? (a = an(t = o), n = an(1 / t), e.domain(i.map(a)), r) : t
}, r.copy = function() {
return rn(e.copy(), t, i)
}, Ya(r, e)
}
function an(e) {
return function(t) {
return 0 > t ? -Math.pow(-t, e) : Math.pow(t, e)
}
}
function nn(e, t) {
function i(i) {
return n[((a.get(i) || ("range" === t.t ? a.set(i, e.push(i)) : NaN)) - 1) % n.length]
}
function r(t, i) {
return oo.range(e.length).map(function(e) {
return t + i * e
})
}
var a, n, o;
return i.domain = function(r) {
if (!arguments.length) return e;
e = [], a = new m;
for (var n, o = -1, s = r.length; ++o < s;) a.has(n = r[o]) || a.set(n, e.push(n));
return i[t.t].apply(i, t.a)
}, i.range = function(e) {
return arguments.length ? (n = e, o = 0, t = {
t: "range",
a: arguments
}, i) : n
}, i.rangePoints = function(a, s) {
arguments.length < 2 && (s = 0);
var l = a[0],
c = a[1],
p = e.length < 2 ? (l = (l + c) / 2, 0) : (c - l) / (e.length - 1 + s);
return n = r(l + p * s / 2, p), o = 0, t = {
t: "rangePoints",
a: arguments
}, i
}, i.rangeRoundPoints = function(a, s) {
arguments.length < 2 && (s = 0);
var l = a[0],
c = a[1],
p = e.length < 2 ? (l = c = Math.round((l + c) / 2), 0) : (c - l) / (e.length - 1 + s) | 0;
return n = r(l + Math.round(p * s / 2 + (c - l - (e.length - 1 + s) * p) / 2), p), o = 0, t = {
t: "rangeRoundPoints",
a: arguments
}, i
}, i.rangeBands = function(a, s, l) {
arguments.length < 2 && (s = 0), arguments.length < 3 && (l = s);
var c = a[1] < a[0],
p = a[c - 0],
d = a[1 - c],
u = (d - p) / (e.length - s + 2 * l);
return n = r(p + u * l, u), c && n.reverse(), o = u * (1 - s), t = {
t: "rangeBands",
a: arguments
}, i
}, i.rangeRoundBands = function(a, s, l) {
arguments.length < 2 && (s = 0), arguments.length < 3 && (l = s);
var c = a[1] < a[0],
p = a[c - 0],
d = a[1 - c],
u = Math.floor((d - p) / (e.length - s + 2 * l));
return n = r(p + Math.round((d - p - (e.length - s) * u) / 2), u), c && n.reverse(), o = Math.round(u * (1 - s)), t = {
t: "rangeRoundBands",
a: arguments
}, i
}, i.rangeBand = function() {
return o
}, i.rangeExtent = function() {
return Ga(t.a[0])
}, i.copy = function() {
return nn(e, t)
}, i.domain(e)
}
function on(e, t) {
function i() {
var i = 0,
n = t.length;
for (a = []; ++i < n;) a[i - 1] = oo.quantile(e, i / n);
return r
}
function r(e) {
return isNaN(e = +e) ? void 0 : t[oo.bisect(a, e)]
}
var a;
return r.domain = function(t) {
return arguments.length ? (e = t.map(l).filter(c).sort(s), i()) : e
}, r.range = function(e) {
return arguments.length ? (t = e, i()) : t
}, r.quantiles = function() {
return a
}, r.invertExtent = function(i) {
return i = t.indexOf(i), 0 > i ? [NaN, NaN] : [i > 0 ? a[i - 1] : e[0], i < a.length ? a[i] : e[e.length - 1]]
}, r.copy = function() {
return on(e, t)
}, i()
}
function sn(e, t, i) {
function r(t) {
return i[Math.max(0, Math.min(o, Math.floor(n * (t - e))))]
}
function a() {
return n = i.length / (t - e), o = i.length - 1, r
}
var n, o;
return r.domain = function(i) {
return arguments.length ? (e = +i[0], t = +i[i.length - 1], a()) : [e, t]
}, r.range = function(e) {
return arguments.length ? (i = e, a()) : i
}, r.invertExtent = function(t) {
return t = i.indexOf(t), t = 0 > t ? NaN : t / n + e, [t, t + 1 / n]
}, r.copy = function() {
return sn(e, t, i)
}, a()
}
function ln(e, t) {
function i(i) {
return i >= i ? t[oo.bisect(e, i)] : void 0
}
return i.domain = function(t) {
return arguments.length ? (e = t, i) : e
}, i.range = function(e) {
return arguments.length ? (t = e, i) : t
}, i.invertExtent = function(i) {
return i = t.indexOf(i), [e[i - 1], e[i]]
}, i.copy = function() {
return ln(e, t)
}, i
}
function cn(e) {
function t(e) {
return +e
}
return t.invert = t, t.domain = t.range = function(i) {
return arguments.length ? (e = i.map(t), t) : e
}, t.ticks = function(t) {
return $a(e, t)
}, t.tickFormat = function(t, i) {
return qa(e, t, i)
}, t.copy = function() {
return cn(e)
}, t
}
function pn() {
return 0
}
function dn(e) {
return e.innerRadius
}
function un(e) {
return e.outerRadius
}
function fn(e) {
return e.startAngle
}
function mn(e) {
return e.endAngle
}
function hn(e) {
return e && e.padAngle
}
function gn(e, t, i, r) {
return (e - i) * t - (t - r) * e > 0 ? 0 : 1
}
function _n(e, t, i, r, a) {
var n = e[0] - t[0],
o = e[1] - t[1],
s = (a ? r : -r) / Math.sqrt(n * n + o * o),
l = s * o,
c = -s * n,
p = e[0] + l,
d = e[1] + c,
u = t[0] + l,
f = t[1] + c,
m = (p + u) / 2,
h = (d + f) / 2,
g = u - p,
_ = f - d,
y = g * g + _ * _,
b = i - r,
v = p * f - u * d,
x = (0 > _ ? -1 : 1) * Math.sqrt(b * b * y - v * v),
w = (v * _ - g * x) / y,
M = (-v * g - _ * x) / y,
L = (v * _ + g * x) / y,
j = (-v * g + _ * x) / y,
I = w - m,
k = M - h,
N = L - m,
D = j - h;
return I * I + k * k > N * N + D * D && (w = L, M = j), [
[w - l, M - c],
[w * i / b, M * i / b]
]
}
function yn(e) {
function t(t) {
function o() {
c.push("M", n(e(p), s))
}
for (var l, c = [], p = [], d = -1, u = t.length, f = Ce(i), m = Ce(r); ++d < u;) a.call(this, l = t[d], d) ? p.push([+f.call(this, l, d), +m.call(this, l, d)]) : p.length && (o(), p = []);
return p.length && o(), c.length ? c.join("") : null
}
var i = zi,
r = Ti,
a = Tt,
n = bn,
o = n.key,
s = .7;
return t.x = function(e) {
return arguments.length ? (i = e, t) : i
}, t.y = function(e) {
return arguments.length ? (r = e, t) : r
}, t.defined = function(e) {
return arguments.length ? (a = e, t) : a
}, t.interpolate = function(e) {
return arguments.length ? (o = "function" == typeof e ? n = e : (n = zl.get(e) || bn).key, t) : o
}, t.tension = function(e) {
return arguments.length ? (s = e, t) : s
}, t
}
function bn(e) {
return e.join("L")
}
function vn(e) {
return bn(e) + "Z"
}
function xn(e) {
for (var t = 0, i = e.length, r = e[0], a = [r[0], ",", r[1]]; ++t < i;) a.push("H", (r[0] + (r = e[t])[0]) / 2, "V", r[1]);
return i > 1 && a.push("H", r[0]), a.join("")
}
function wn(e) {
for (var t = 0, i = e.length, r = e[0], a = [r[0], ",", r[1]]; ++t < i;) a.push("V", (r = e[t])[1], "H", r[0]);
return a.join("")
}
function Mn(e) {
for (var t = 0, i = e.length, r = e[0], a = [r[0], ",", r[1]]; ++t < i;) a.push("H", (r = e[t])[0], "V", r[1]);
return a.join("")
}
function Ln(e, t) {
return e.length < 4 ? bn(e) : e[1] + kn(e.slice(1, -1), Nn(e, t))
}
function jn(e, t) {
return e.length < 3 ? bn(e) : e[0] + kn((e.push(e[0]), e), Nn([e[e.length - 2]].concat(e, [e[1]]), t))
}
function In(e, t) {
return e.length < 3 ? bn(e) : e[0] + kn(e, Nn(e, t))
}
function kn(e, t) {
if (t.length < 1 || e.length != t.length && e.length != t.length + 2) return bn(e);
var i = e.length != t.length,
r = "",
a = e[0],
n = e[1],
o = t[0],
s = o,
l = 1;
if (i && (r += "Q" + (n[0] - 2 * o[0] / 3) + "," + (n[1] - 2 * o[1] / 3) + "," + n[0] + "," + n[1], a = e[1], l = 2), t.length > 1) {
s = t[1], n = e[l], l++, r += "C" + (a[0] + o[0]) + "," + (a[1] + o[1]) + "," + (n[0] - s[0]) + "," + (n[1] - s[1]) + "," + n[0] + "," + n[1];
for (var c = 2; c < t.length; c++, l++) n = e[l], s = t[c], r += "S" + (n[0] - s[0]) + "," + (n[1] - s[1]) + "," + n[0] + "," + n[1]
}
if (i) {
var p = e[l];
r += "Q" + (n[0] + 2 * s[0] / 3) + "," + (n[1] + 2 * s[1] / 3) + "," + p[0] + "," + p[1]
}
return r
}
function Nn(e, t) {
for (var i, r = [], a = (1 - t) / 2, n = e[0], o = e[1], s = 1, l = e.length; ++s < l;) i = n, n = o, o = e[s], r.push([a * (o[0] - i[0]), a * (o[1] - i[1])]);
return r
}
function Dn(e) {
if (e.length < 3) return bn(e);
var t = 1,
i = e.length,
r = e[0],
a = r[0],
n = r[1],
o = [a, a, a, (r = e[1])[0]],
s = [n, n, n, r[1]],
l = [a, ",", n, "L", Tn(Al, o), ",", Tn(Al, s)];
for (e.push(e[i - 1]); ++t <= i;) r = e[t], o.shift(), o.push(r[0]), s.shift(), s.push(r[1]), En(l, o, s);
return e.pop(), l.push("L", r), l.join("")
}
function Sn(e) {
if (e.length < 4) return bn(e);
for (var t, i = [], r = -1, a = e.length, n = [0], o = [0]; ++r < 3;) t = e[r], n.push(t[0]), o.push(t[1]);
for (i.push(Tn(Al, n) + "," + Tn(Al, o)), --r; ++r < a;) t = e[r], n.shift(), n.push(t[0]), o.shift(), o.push(t[1]), En(i, n, o);
return i.join("")
}
function Cn(e) {
for (var t, i, r = -1, a = e.length, n = a + 4, o = [], s = []; ++r < 4;) i = e[r % a], o.push(i[0]), s.push(i[1]);
for (t = [Tn(Al, o), ",", Tn(Al, s)], --r; ++r < n;) i = e[r % a], o.shift(), o.push(i[0]), s.shift(), s.push(i[1]), En(t, o, s);
return t.join("")
}
function zn(e, t) {
var i = e.length - 1;
if (i)
for (var r, a, n = e[0][0], o = e[0][1], s = e[i][0] - n, l = e[i][1] - o, c = -1; ++c <= i;) r = e[c], a = c / i, r[0] = t * r[0] + (1 - t) * (n + a * s), r[1] = t * r[1] + (1 - t) * (o + a * l);
return Dn(e)
}
function Tn(e, t) {
return e[0] * t[0] + e[1] * t[1] + e[2] * t[2] + e[3] * t[3]
}
function En(e, t, i) {
e.push("C", Tn(Tl, t), ",", Tn(Tl, i), ",", Tn(El, t), ",", Tn(El, i), ",", Tn(Al, t), ",", Tn(Al, i))
}
function An(e, t) {
return (t[1] - e[1]) / (t[0] - e[0])
}
function Pn(e) {
for (var t = 0, i = e.length - 1, r = [], a = e[0], n = e[1], o = r[0] = An(a, n); ++t < i;) r[t] = (o + (o = An(a = n, n = e[t + 1]))) / 2;
return r[t] = o, r
}
function On(e) {
for (var t, i, r, a, n = [], o = Pn(e), s = -1, l = e.length - 1; ++s < l;) t = An(e[s], e[s + 1]), bo(t) < Ao ? o[s] = o[s + 1] = 0 : (i = o[s] / t, r = o[s + 1] / t, a = i * i + r * r, a > 9 && (a = 3 * t / Math.sqrt(a), o[s] = a * i, o[s + 1] = a * r));
for (s = -1; ++s <= l;) a = (e[Math.min(l, s + 1)][0] - e[Math.max(0, s - 1)][0]) / (6 * (1 + o[s] * o[s])), n.push([a || 0, o[s] * a || 0]);
return n
}
function Zn(e) {
return e.length < 3 ? bn(e) : e[0] + kn(e, On(e))
}
function Hn(e) {
for (var t, i, r, a = -1, n = e.length; ++a < n;) t = e[a], i = t[0], r = t[1] - Uo, t[0] = i * Math.cos(r), t[1] = i * Math.sin(r);
return e
}
function Un(e) {
function t(t) {
function l() {
h.push("M", s(e(_), d), p, c(e(g.reverse()), d), "Z")
}
for (var u, f, m, h = [], g = [], _ = [], y = -1, b = t.length, v = Ce(i), x = Ce(a), w = i === r ? function() {
return f
} : Ce(r), M = a === n ? function() {
return m
} : Ce(n); ++y < b;) o.call(this, u = t[y], y) ? (g.push([f = +v.call(this, u, y), m = +x.call(this, u, y)]), _.push([+w.call(this, u, y), +M.call(this, u, y)])) : g.length && (l(), g = [], _ = []);
return g.length && l(), h.length ? h.join("") : null
}
var i = zi,
r = zi,
a = 0,
n = Ti,
o = Tt,
s = bn,
l = s.key,
c = s,
p = "L",
d = .7;
return t.x = function(e) {
return arguments.length ? (i = r = e, t) : r
}, t.x0 = function(e) {
return arguments.length ? (i = e, t) : i
}, t.x1 = function(e) {
return arguments.length ? (r = e, t) : r
}, t.y = function(e) {
return arguments.length ? (a = n = e, t) : n
}, t.y0 = function(e) {
return arguments.length ? (a = e, t) : a
}, t.y1 = function(e) {
return arguments.length ? (n = e, t) : n
}, t.defined = function(e) {
return arguments.length ? (o = e, t) : o
}, t.interpolate = function(e) {
return arguments.length ? (l = "function" == typeof e ? s = e : (s = zl.get(e) || bn).key, c = s.reverse || s, p = s.closed ? "M" : "L", t) : l
}, t.tension = function(e) {
return arguments.length ? (d = e, t) : d
}, t
}
function Gn(e) {
return e.radius
}
function Bn(e) {
return [e.x, e.y]
}
function Rn(e) {
return function() {
var t = e.apply(this, arguments),
i = t[0],
r = t[1] - Uo;
return [i * Math.cos(r), i * Math.sin(r)]
}
}
function Qn() {
return 64
}
function Vn() {
return "circle"
}
function Fn(e) {
var t = Math.sqrt(e / Oo);
return "M0," + t + "A" + t + "," + t + " 0 1,1 0," + -t + "A" + t + "," + t + " 0 1,1 0," + t + "Z"
}
function Wn(e) {
return function() {
var t, i;
(t = this[e]) && (i = t[t.active]) && (--t.count ? delete t[t.active] : delete this[e], t.active += .5, i.event && i.event.interrupt.call(this, this.__data__, i.index))
}
}
function Yn(e, t, i) {
return Lo(e, Bl), e.namespace = t, e.id = i, e
}
function Jn(e, t, i, r) {
var a = e.id,
n = e.namespace;
return Y(e, "function" == typeof i ? function(e, o, s) {
e[n][a].tween.set(t, r(i.call(e, e.__data__, o, s)))
} : (i = r(i), function(e) {
e[n][a].tween.set(t, i)
}))
}
function Xn(e) {
return null == e && (e = ""),
function() {
this.textContent = e
}
}
function $n(e) {
return null == e ? "__transition__" : "__transition_" + e + "__"
}
function qn(e, t, i, r, a) {
var n = e[i] || (e[i] = {
active: 0,
count: 0
}),
o = n[r];
if (!o) {
var s = a.time;
o = n[r] = {
tween: new m,
time: s,
delay: a.delay,
duration: a.duration,
ease: a.ease,
index: t
}, a = null, ++n.count, oo.timer(function(a) {
function l(i) {
if (n.active > r) return p();
var a = n[n.active];
a && (--n.count, delete n[n.active], a.event && a.event.interrupt.call(e, e.__data__, a.index)), n.active = r, o.event && o.event.start.call(e, e.__data__, t), o.tween.forEach(function(i, r) {
(r = r.call(e, e.__data__, t)) && h.push(r)
}), u = o.ease, d = o.duration, oo.timer(function() {
return m.c = c(i || 1) ? Tt : c, 1
}, 0, s)
}
function c(i) {
if (n.active !== r) return 1;
for (var a = i / d, s = u(a), l = h.length; l > 0;) h[--l].call(e, s);
return a >= 1 ? (o.event && o.event.end.call(e, e.__data__, t), p()) : void 0
}
function p() {
return --n.count ? delete n[r] : delete e[i], 1
}
var d, u, f = o.delay,
m = ls,
h = [];
return m.t = f + s, a >= f ? l(a - f) : void(m.c = l)
}, 0, s)
}
}
function Kn(e, t, i) {
e.attr("transform", function(e) {
var r = t(e);
return "translate(" + (isFinite(r) ? r : i(e)) + ",0)"
})
}
function eo(e, t, i) {
e.attr("transform", function(e) {
var r = t(e);
return "translate(0," + (isFinite(r) ? r : i(e)) + ")"
})
}
function to(e) {
return e.toISOString()
}
function io(e, t, i) {
function r(t) {
return e(t)
}
function a(e, i) {
var r = e[1] - e[0],
a = r / i,
n = oo.bisect($l, a);
return n == $l.length ? [t.year, Xa(e.map(function(e) {
return e / 31536e6
}), i)[2]] : n ? t[a / $l[n - 1] < $l[n] / a ? n - 1 : n] : [ec, Xa(e, i)[2]]
}
return r.invert = function(t) {
return ro(e.invert(t))
}, r.domain = function(t) {
return arguments.length ? (e.domain(t), r) : e.domain().map(ro)
}, r.nice = function(e, t) {
function i(i) {
return !isNaN(i) && !e.range(i, ro(+i + 1), t).length
}
var n = r.domain(),
o = Ga(n),
s = null == e ? a(o, 10) : "number" == typeof e && a(o, e);
return s && (e = s[0], t = s[1]), r.domain(Qa(n, t > 1 ? {
floor: function(t) {
for (; i(t = e.floor(t));) t = ro(t - 1);
return t
},
ceil: function(t) {
for (; i(t = e.ceil(t));) t = ro(+t + 1);
return t
}
} : e))
}, r.ticks = function(e, t) {
var i = Ga(r.domain()),
n = null == e ? a(i, 10) : "number" == typeof e ? a(i, e) : !e.range && [{
range: e
}, t];
return n && (e = n[0], t = n[1]), e.range(i[0], ro(+i[1] + 1), 1 > t ? 1 : t)
}, r.tickFormat = function() {
return i
}, r.copy = function() {
return io(e.copy(), t, i)
}, Ya(r, e)
}
function ro(e) {
return new Date(e)
}
function ao(e) {
return JSON.parse(e.responseText)
}
function no(e) {
var t = co.createRange();
return t.selectNode(co.body), t.createContextualFragment(e.responseText)
}
var oo = {
version: "3.5.6"
},
so = [].slice,
lo = function(e) {
return so.call(e)
},
co = this.document;
if (co) try {
lo(co.documentElement.childNodes)[0].nodeType
} catch (po) {
lo = function(e) {
for (var t = e.length, i = new Array(t); t--;) i[t] = e[t];
return i
}
}
if (Date.now || (Date.now = function() {
return +new Date
}), co) try {
co.createElement("DIV").style.setProperty("opacity", 0, "")
} catch (uo) {
var fo = this.Element.prototype,
mo = fo.setAttribute,
ho = fo.setAttributeNS,
go = this.CSSStyleDeclaration.prototype,
_o = go.setProperty;
fo.setAttribute = function(e, t) {
mo.call(this, e, t + "")
}, fo.setAttributeNS = function(e, t, i) {
ho.call(this, e, t, i + "")
}, go.setProperty = function(e, t, i) {
_o.call(this, e, t + "", i)
}
}
oo.ascending = s, oo.descending = function(e, t) {
return e > t ? -1 : t > e ? 1 : t >= e ? 0 : NaN
}, oo.min = function(e, t) {
var i, r, a = -1,
n = e.length;
if (1 === arguments.length) {
for (; ++a < n;)
if (null != (r = e[a]) && r >= r) {
i = r;
break
}
for (; ++a < n;) null != (r = e[a]) && i > r && (i = r)
} else {
for (; ++a < n;)
if (null != (r = t.call(e, e[a], a)) && r >= r) {
i = r;
break
}
for (; ++a < n;) null != (r = t.call(e, e[a], a)) && i > r && (i = r)
}
return i
}, oo.max = function(e, t) {
var i, r, a = -1,
n = e.length;
if (1 === arguments.length) {
for (; ++a < n;)
if (null != (r = e[a]) && r >= r) {
i = r;
break
}
for (; ++a < n;) null != (r = e[a]) && r > i && (i = r)
} else {
for (; ++a < n;)
if (null != (r = t.call(e, e[a], a)) && r >= r) {
i = r;
break
}
for (; ++a < n;) null != (r = t.call(e, e[a], a)) && r > i && (i = r)
}
return i
}, oo.extent = function(e, t) {
var i, r, a, n = -1,
o = e.length;
if (1 === arguments.length) {
for (; ++n < o;)
if (null != (r = e[n]) && r >= r) {
i = a = r;
break
}
for (; ++n < o;) null != (r = e[n]) && (i > r && (i = r), r > a && (a = r))
} else {
for (; ++n < o;)
if (null != (r = t.call(e, e[n], n)) && r >= r) {
i = a = r;
break
}
for (; ++n < o;) null != (r = t.call(e, e[n], n)) && (i > r && (i = r), r > a && (a = r))
}
return [i, a]
}, oo.sum = function(e, t) {
var i, r = 0,
a = e.length,
n = -1;
if (1 === arguments.length)
for (; ++n < a;) c(i = +e[n]) && (r += i);
else
for (; ++n < a;) c(i = +t.call(e, e[n], n)) && (r += i);
return r
}, oo.mean = function(e, t) {
var i, r = 0,
a = e.length,
n = -1,
o = a;
if (1 === arguments.length)
for (; ++n < a;) c(i = l(e[n])) ? r += i : --o;
else
for (; ++n < a;) c(i = l(t.call(e, e[n], n))) ? r += i : --o;
return o ? r / o : void 0
}, oo.quantile = function(e, t) {
var i = (e.length - 1) * t + 1,
r = Math.floor(i),
a = +e[r - 1],
n = i - r;
return n ? a + n * (e[r] - a) : a
}, oo.median = function(e, t) {
var i, r = [],
a = e.length,
n = -1;
if (1 === arguments.length)
for (; ++n < a;) c(i = l(e[n])) && r.push(i);
else
for (; ++n < a;) c(i = l(t.call(e, e[n], n))) && r.push(i);
return r.length ? oo.quantile(r.sort(s), .5) : void 0
}, oo.variance = function(e, t) {
var i, r, a = e.length,
n = 0,
o = 0,
s = -1,
p = 0;
if (1 === arguments.length)
for (; ++s < a;) c(i = l(e[s])) && (r = i - n, n += r / ++p, o += r * (i - n));
else
for (; ++s < a;) c(i = l(t.call(e, e[s], s))) && (r = i - n, n += r / ++p, o += r * (i - n));
return p > 1 ? o / (p - 1) : void 0
}, oo.deviation = function() {
var e = oo.variance.apply(this, arguments);
return e ? Math.sqrt(e) : e
};
var yo = p(s);
oo.bisectLeft = yo.left, oo.bisect = oo.bisectRight = yo.right, oo.bisector = function(e) {
return p(1 === e.length ? function(t, i) {
return s(e(t), i)
} : e)
}, oo.shuffle = function(e, t, i) {
(n = arguments.length) < 3 && (i = e.length, 2 > n && (t = 0));
for (var r, a, n = i - t; n;) a = Math.random() * n-- | 0, r = e[n + t], e[n + t] = e[a + t], e[a + t] = r;
return e
}, oo.permute = function(e, t) {
for (var i = t.length, r = new Array(i); i--;) r[i] = e[t[i]];
return r
}, oo.pairs = function(e) {
for (var t, i = 0, r = e.length - 1, a = e[0], n = new Array(0 > r ? 0 : r); r > i;) n[i] = [t = a, a = e[++i]];
return n
}, oo.zip = function() {
if (!(r = arguments.length)) return [];
for (var e = -1, t = oo.min(arguments, d), i = new Array(t); ++e < t;)
for (var r, a = -1, n = i[e] = new Array(r); ++a < r;) n[a] = arguments[a][e];
return i
}, oo.transpose = function(e) {
return oo.zip.apply(oo, e)
}, oo.keys = function(e) {
var t = [];
for (var i in e) t.push(i);
return t
}, oo.values = function(e) {
var t = [];
for (var i in e) t.push(e[i]);
return t
}, oo.entries = function(e) {
var t = [];
for (var i in e) t.push({
key: i,
value: e[i]
});
return t
}, oo.merge = function(e) {
for (var t, i, r, a = e.length, n = -1, o = 0; ++n < a;) o += e[n].length;
for (i = new Array(o); --a >= 0;)
for (r = e[a], t = r.length; --t >= 0;) i[--o] = r[t];
return i
};
var bo = Math.abs;
oo.range = function(e, t, i) {
if (arguments.length < 3 && (i = 1, arguments.length < 2 && (t = e, e = 0)), (t - e) / i === 1 / 0) throw new Error("infinite range");
var r, a = [],
n = u(bo(i)),
o = -1;
if (e *= n, t *= n, i *= n, 0 > i)
for (;
(r = e + i * ++o) > t;) a.push(r / n);
else
for (;
(r = e + i * ++o) < t;) a.push(r / n);
return a
}, oo.map = function(e, t) {
var i = new m;
if (e instanceof m) e.forEach(function(e, t) {
i.set(e, t)
});
else if (Array.isArray(e)) {
var r, a = -1,
n = e.length;
if (1 === arguments.length)
for (; ++a < n;) i.set(a, e[a]);
else
for (; ++a < n;) i.set(t.call(e, r = e[a], a), r)
} else
for (var o in e) i.set(o, e[o]);
return i
};
var vo = "__proto__",
xo = "\x00";
f(m, {
has: _,
get: function(e) {
return this._[h(e)]
},
set: function(e, t) {
return this._[h(e)] = t
},
remove: y,
keys: b,
values: function() {
var e = [];
for (var t in this._) e.push(this._[t]);
return e
},
entries: function() {
var e = [];
for (var t in this._) e.push({
key: g(t),
value: this._[t]
});
return e
},
size: v,
empty: x,
forEach: function(e) {
for (var t in this._) e.call(this, g(t), this._[t])
}
}), oo.nest = function() {
function e(t, o, s) {
if (s >= n.length) return r ? r.call(a, o) : i ? o.sort(i) : o;
for (var l, c, p, d, u = -1, f = o.length, h = n[s++], g = new m; ++u < f;)(d = g.get(l = h(c = o[u]))) ? d.push(c) : g.set(l, [c]);
return t ? (c = t(), p = function(i, r) {
c.set(i, e(t, r, s))
}) : (c = {}, p = function(i, r) {
c[i] = e(t, r, s)
}), g.forEach(p), c
}
function t(e, i) {
if (i >= n.length) return e;
var r = [],
a = o[i++];
return e.forEach(function(e, a) {
r.push({
key: e,
values: t(a, i)
})
}), a ? r.sort(function(e, t) {
return a(e.key, t.key)
}) : r
}
var i, r, a = {},
n = [],
o = [];
return a.map = function(t, i) {
return e(i, t, 0)
}, a.entries = function(i) {
return t(e(oo.map, i, 0), 0)
}, a.key = function(e) {
return n.push(e), a
}, a.sortKeys = function(e) {
return o[n.length - 1] = e, a
}, a.sortValues = function(e) {
return i = e, a
}, a.rollup = function(e) {
return r = e, a
}, a
}, oo.set = function(e) {
var t = new w;
if (e)
for (var i = 0, r = e.length; r > i; ++i) t.add(e[i]);
return t
}, f(w, {
has: _,
add: function(e) {
return this._[h(e += "")] = !0, e
},
remove: y,
values: b,
size: v,
empty: x,
forEach: function(e) {
for (var t in this._) e.call(this, g(t))
}
}), oo.behavior = {}, oo.rebind = function(e, t) {
for (var i, r = 1, a = arguments.length; ++r < a;) e[i = arguments[r]] = L(e, t, t[i]);
return e
};
var wo = ["webkit", "ms", "moz", "Moz", "o", "O"];
oo.dispatch = function() {
for (var e = new k, t = -1, i = arguments.length; ++t < i;) e[arguments[t]] = N(e);
return e
}, k.prototype.on = function(e, t) {
var i = e.indexOf("."),
r = "";
if (i >= 0 && (r = e.slice(i + 1), e = e.slice(0, i)), e) return arguments.length < 2 ? this[e].on(r) : this[e].on(r, t);
if (2 === arguments.length) {
if (null == t)
for (e in this) this.hasOwnProperty(e) && this[e].on(r, null);
return this
}
}, oo.event = null, oo.requote = function(e) {
return e.replace(Mo, "\\$&")
};
var Mo = /[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,
Lo = {}.__proto__ ? function(e, t) {
e.__proto__ = t
} : function(e, t) {
for (var i in t) e[i] = t[i]
},
jo = function(e, t) {
return t.querySelector(e)
},
Io = function(e, t) {
return t.querySelectorAll(e)
},
ko = function(e, t) {
var i = e.matches || e[j(e, "matchesSelector")];
return (ko = function(e, t) {
return i.call(e, t)
})(e, t)
};
"function" == typeof Sizzle && (jo = function(e, t) {
return Sizzle(e, t)[0] || null
}, Io = Sizzle, ko = Sizzle.matchesSelector), oo.selection = function() {
return oo.select(co.documentElement)
};
var No = oo.selection.prototype = [];
No.select = function(e) {
var t, i, r, a, n = [];
e = T(e);
for (var o = -1, s = this.length; ++o < s;) {
n.push(t = []), t.parentNode = (r = this[o]).parentNode;
for (var l = -1, c = r.length; ++l < c;)(a = r[l]) ? (t.push(i = e.call(a, a.__data__, l, o)), i && "__data__" in a && (i.__data__ = a.__data__)) : t.push(null)
}
return z(n)
}, No.selectAll = function(e) {
var t, i, r = [];
e = E(e);
for (var a = -1, n = this.length; ++a < n;)
for (var o = this[a], s = -1, l = o.length; ++s < l;)(i = o[s]) && (r.push(t = lo(e.call(i, i.__data__, s, a))), t.parentNode = i);
return z(r)
};
var Do = {
svg: "http://www.w3.org/2000/svg",
xhtml: "http://www.w3.org/1999/xhtml",
xlink: "http://www.w3.org/1999/xlink",
xml: "http://www.w3.org/XML/1998/namespace",
xmlns: "http://www.w3.org/2000/xmlns/"
};
oo.ns = {
prefix: Do,
qualify: function(e) {
var t = e.indexOf(":"),
i = e;
return t >= 0 && (i = e.slice(0, t), e = e.slice(t + 1)), Do.hasOwnProperty(i) ? {
space: Do[i],
local: e
} : e
}
}, No.attr = function(e, t) {
if (arguments.length < 2) {
if ("string" == typeof e) {
var i = this.node();
return e = oo.ns.qualify(e), e.local ? i.getAttributeNS(e.space, e.local) : i.getAttribute(e)
}
for (t in e) this.each(A(t, e[t]));
return this
}
return this.each(A(e, t))
}, No.classed = function(e, t) {
if (arguments.length < 2) {
if ("string" == typeof e) {
var i = this.node(),
r = (e = Z(e)).length,
a = -1;
if (t = i.classList) {
for (; ++a < r;)
if (!t.contains(e[a])) return !1
} else
for (t = i.getAttribute("class"); ++a < r;)
if (!O(e[a]).test(t)) return !1;
return !0
}
for (t in e) this.each(H(t, e[t]));
return this
}
return this.each(H(e, t))
}, No.style = function(e, t, i) {
var r = arguments.length;
if (3 > r) {
if ("string" != typeof e) {
2 > r && (t = "");
for (i in e) this.each(G(i, e[i], t));
return this
}
if (2 > r) {
var a = this.node();
return o(a).getComputedStyle(a, null).getPropertyValue(e)
}
i = ""
}
return this.each(G(e, t, i))
}, No.property = function(e, t) {
if (arguments.length < 2) {
if ("string" == typeof e) return this.node()[e];
for (t in e) this.each(B(t, e[t]));
return this
}
return this.each(B(e, t))
}, No.text = function(e) {
return arguments.length ? this.each("function" == typeof e ? function() {
var t = e.apply(this, arguments);
this.textContent = null == t ? "" : t
} : null == e ? function() {
this.textContent = ""
} : function() {
this.textContent = e
}) : this.node().textContent
}, No.html = function(e) {
return arguments.length ? this.each("function" == typeof e ? function() {
var t = e.apply(this, arguments);
this.innerHTML = null == t ? "" : t
} : null == e ? function() {
this.innerHTML = ""
} : function() {
this.innerHTML = e
}) : this.node().innerHTML
}, No.append = function(e) {
return e = R(e), this.select(function() {
return this.appendChild(e.apply(this, arguments))
})
}, No.insert = function(e, t) {
return e = R(e), t = T(t), this.select(function() {
return this.insertBefore(e.apply(this, arguments), t.apply(this, arguments) || null)
})
}, No.remove = function() {
return this.each(Q)
}, No.data = function(e, t) {
function i(e, i) {
var r, a, n, o = e.length,
p = i.length,
d = Math.min(o, p),
u = new Array(p),
f = new Array(p),
h = new Array(o);
if (t) {
var g, _ = new m,
y = new Array(o);
for (r = -1; ++r < o;) _.has(g = t.call(a = e[r], a.__data__, r)) ? h[r] = a : _.set(g, a), y[r] = g;
for (r = -1; ++r < p;)(a = _.get(g = t.call(i, n = i[r], r))) ? a !== !0 && (u[r] = a, a.__data__ = n) : f[r] = V(n), _.set(g, !0);
for (r = -1; ++r < o;) _.get(y[r]) !== !0 && (h[r] = e[r])
} else {
for (r = -1; ++r < d;) a = e[r], n = i[r], a ? (a.__data__ = n, u[r] = a) : f[r] = V(n);
for (; p > r; ++r) f[r] = V(i[r]);
for (; o > r; ++r) h[r] = e[r]
}
f.update = u, f.parentNode = u.parentNode = h.parentNode = e.parentNode, s.push(f), l.push(u), c.push(h)
}
var r, a, n = -1,
o = this.length;
if (!arguments.length) {
for (e = new Array(o = (r = this[0]).length); ++n < o;)(a = r[n]) && (e[n] = a.__data__);
return e
}
var s = J([]),
l = z([]),
c = z([]);
if ("function" == typeof e)
for (; ++n < o;) i(r = this[n], e.call(r, r.parentNode.__data__, n));
else
for (; ++n < o;) i(r = this[n], e);
return l.enter = function() {
return s
}, l.exit = function() {
return c
}, l
}, No.datum = function(e) {
return arguments.length ? this.property("__data__", e) : this.property("__data__")
}, No.filter = function(e) {
var t, i, r, a = [];
"function" != typeof e && (e = F(e));
for (var n = 0, o = this.length; o > n; n++) {
a.push(t = []), t.parentNode = (i = this[n]).parentNode;
for (var s = 0, l = i.length; l > s; s++)(r = i[s]) && e.call(r, r.__data__, s, n) && t.push(r)
}
return z(a)
}, No.order = function() {
for (var e = -1, t = this.length; ++e < t;)
for (var i, r = this[e], a = r.length - 1, n = r[a]; --a >= 0;)(i = r[a]) && (n && n !== i.nextSibling && n.parentNode.insertBefore(i, n), n = i);
return this
}, No.sort = function(e) {
e = W.apply(this, arguments);
for (var t = -1, i = this.length; ++t < i;) this[t].sort(e);
return this.order()
}, No.each = function(e) {
return Y(this, function(t, i, r) {
e.call(t, t.__data__, i, r)
})
}, No.call = function(e) {
var t = lo(arguments);
return e.apply(t[0] = this, t), this
}, No.empty = function() {
return !this.node()
}, No.node = function() {
for (var e = 0, t = this.length; t > e; e++)
for (var i = this[e], r = 0, a = i.length; a > r; r++) {
var n = i[r];
if (n) return n
}
return null
}, No.size = function() {
var e = 0;
return Y(this, function() {
++e
}), e
};
var So = [];
oo.selection.enter = J, oo.selection.enter.prototype = So, So.append = No.append, So.empty = No.empty, So.node = No.node, So.call = No.call, So.size = No.size, So.select = function(e) {
for (var t, i, r, a, n, o = [], s = -1, l = this.length; ++s < l;) {
r = (a = this[s]).update, o.push(t = []), t.parentNode = a.parentNode;
for (var c = -1, p = a.length; ++c < p;)(n = a[c]) ? (t.push(r[c] = i = e.call(a.parentNode, n.__data__, c, s)), i.__data__ = n.__data__) : t.push(null)
}
return z(o)
}, So.insert = function(e, t) {
return arguments.length < 2 && (t = X(this)), No.insert.call(this, e, t)
}, oo.select = function(e) {
var t;
return "string" == typeof e ? (t = [jo(e, co)], t.parentNode = co.documentElement) : (t = [e], t.parentNode = n(e)), z([t])
}, oo.selectAll = function(e) {
var t;
return "string" == typeof e ? (t = lo(Io(e, co)), t.parentNode = co.documentElement) : (t = e, t.parentNode = null), z([t])
}, No.on = function(e, t, i) {
var r = arguments.length;
if (3 > r) {
if ("string" != typeof e) {
2 > r && (t = !1);
for (i in e) this.each($(i, e[i], t));
return this
}
if (2 > r) return (r = this.node()["__on" + e]) && r._;
i = !1
}
return this.each($(e, t, i))
};
var Co = oo.map({
mouseenter: "mouseover",
mouseleave: "mouseout"
});
co && Co.forEach(function(e) {
"on" + e in co && Co.remove(e)
});
var zo, To = 0;
oo.mouse = function(e) {
return te(e, S())
};
var Eo = this.navigator && /WebKit/.test(this.navigator.userAgent) ? -1 : 0;
oo.touch = function(e, t, i) {
if (arguments.length < 3 && (i = t, t = S().changedTouches), t)
for (var r, a = 0, n = t.length; n > a; ++a)
if ((r = t[a]).identifier === i) return te(e, r)
}, oo.behavior.drag = function() {
function e() {
this.on("mousedown.drag", a).on("touchstart.drag", n)
}
function t(e, t, a, n, o) {
return function() {
function s() {
var e, i, r = t(u, h);
r && (e = r[0] - b[0], i = r[1] - b[1], m |= e | i, b = r, f({
type: "drag",
x: r[0] + c[0],
y: r[1] + c[1],
dx: e,
dy: i
}))
}
function l() {
t(u, h) && (_.on(n + g, null).on(o + g, null), y(m && oo.event.target === d), f({
type: "dragend"
}))
}
var c, p = this,
d = oo.event.target,
u = p.parentNode,
f = i.of(p, arguments),
m = 0,
h = e(),
g = ".drag" + (null == h ? "" : "-" + h),
_ = oo.select(a(d)).on(n + g, s).on(o + g, l),
y = ee(d),
b = t(u, h);
r ? (c = r.apply(p, arguments), c = [c.x - b[0], c.y - b[1]]) : c = [0, 0], f({
type: "dragstart"
})
}
}
var i = C(e, "drag", "dragstart", "dragend"),
r = null,
a = t(I, oo.mouse, o, "mousemove", "mouseup"),
n = t(ie, oo.touch, M, "touchmove", "touchend");
return e.origin = function(t) {
return arguments.length ? (r = t, e) : r
}, oo.rebind(e, i, "on")
}, oo.touches = function(e, t) {
return arguments.length < 2 && (t = S().touches), t ? lo(t).map(function(t) {
var i = te(e, t);
return i.identifier = t.identifier, i
}) : []
};
var Ao = 1e-6,
Po = Ao * Ao,
Oo = Math.PI,
Zo = 2 * Oo,
Ho = Zo - Ao,
Uo = Oo / 2,
Go = Oo / 180,
Bo = 180 / Oo,
Ro = Math.SQRT2,
Qo = 2,
Vo = 4;
oo.interpolateZoom = function(e, t) {
function i(e) {
var t = e * y;
if (_) {
var i = le(h),
o = n / (Qo * u) * (i * ce(Ro * t + h) - se(h));
return [r + o * c, a + o * p, n * i / le(Ro * t + h)]
}
return [r + e * c, a + e * p, n * Math.exp(Ro * t)]
}
var r = e[0],
a = e[1],
n = e[2],
o = t[0],
s = t[1],
l = t[2],
c = o - r,
p = s - a,
d = c * c + p * p,
u = Math.sqrt(d),
f = (l * l - n * n + Vo * d) / (2 * n * Qo * u),
m = (l * l - n * n - Vo * d) / (2 * l * Qo * u),
h = Math.log(Math.sqrt(f * f + 1) - f),
g = Math.log(Math.sqrt(m * m + 1) - m),
_ = g - h,
y = (_ || Math.log(l / n)) / Ro;
return i.duration = 1e3 * y, i
}, oo.behavior.zoom = function() {
function e(e) {
e.on(S, d).on(Wo + ".zoom", f).on("dblclick.zoom", m).on(E, u)
}
function t(e) {
return [(e[0] - L.x) / L.k, (e[1] - L.y) / L.k]
}
function i(e) {
return [e[0] * L.k + L.x, e[1] * L.k + L.y]
}
function r(e) {
L.k = Math.max(I[0], Math.min(I[1], e))
}
function a(e, t) {
t = i(t), L.x += e[0] - t[0], L.y += e[1] - t[1]
}
function n(t, i, n, o) {
t.__chart__ = {
x: L.x,
y: L.y,
k: L.k
}, r(Math.pow(2, o)), a(g = i, n), t = oo.select(t), k > 0 && (t = t.transition().duration(k)), t.call(e.event)
}
function s() {
x && x.domain(v.range().map(function(e) {
return (e - L.x) / L.k
}).map(v.invert)), M && M.domain(w.range().map(function(e) {
return (e - L.y) / L.k
}).map(w.invert))
}
function l(e) {
N++ || e({
type: "zoomstart"
})
}
function c(e) {
s(), e({
type: "zoom",
scale: L.k,
translate: [L.x, L.y]
})
}
function p(e) {
--N || (e({
type: "zoomend"
}), g = null)
}
function d() {
function e() {
d = 1, a(oo.mouse(r), f), c(s)
}
function i() {
u.on(z, null).on(T, null), m(d && oo.event.target === n), p(s)
}
var r = this,
n = oo.event.target,
s = A.of(r, arguments),
d = 0,
u = oo.select(o(r)).on(z, e).on(T, i),
f = t(oo.mouse(r)),
m = ee(r);
Gl.call(r), l(s)
}
function u() {
function e() {
var e = oo.touches(m);
return f = L.k, e.forEach(function(e) {
e.identifier in g && (g[e.identifier] = t(e))
}), e
}
function i() {
var t = oo.event.target;
oo.select(t).on(v, o).on(x, s), w.push(t);
for (var i = oo.event.changedTouches, r = 0, a = i.length; a > r; ++r) g[i[r].identifier] = null;
var l = e(),
c = Date.now();
if (1 === l.length) {
if (500 > c - b) {
var p = l[0];
n(m, p, g[p.identifier], Math.floor(Math.log(L.k) / Math.LN2) + 1), D()
}
b = c
} else if (l.length > 1) {
var p = l[0],
d = l[1],
u = p[0] - d[0],
f = p[1] - d[1];
_ = u * u + f * f
}
}
function o() {
var e, t, i, n, o = oo.touches(m);
Gl.call(m);
for (var s = 0, l = o.length; l > s; ++s, n = null)
if (i = o[s], n = g[i.identifier]) {
if (t) break;
e = i, t = n
}
if (n) {
var p = (p = i[0] - e[0]) * p + (p = i[1] - e[1]) * p,
d = _ && Math.sqrt(p / _);
e = [(e[0] + i[0]) / 2, (e[1] + i[1]) / 2], t = [(t[0] + n[0]) / 2, (t[1] + n[1]) / 2], r(d * f)
}
b = null, a(e, t), c(h)
}
function s() {
if (oo.event.touches.length) {
for (var t = oo.event.changedTouches, i = 0, r = t.length; r > i; ++i) delete g[t[i].identifier];
for (var a in g) return void e()
}
oo.selectAll(w).on(y, null), M.on(S, d).on(E, u), j(), p(h)
}
var f, m = this,
h = A.of(m, arguments),
g = {},
_ = 0,
y = ".zoom-" + oo.event.changedTouches[0].identifier,
v = "touchmove" + y,
x = "touchend" + y,
w = [],
M = oo.select(m),
j = ee(m);
i(), l(h), M.on(S, null).on(E, i)
}
function f() {
var e = A.of(this, arguments);
y ? clearTimeout(y) : (Gl.call(this), h = t(g = _ || oo.mouse(this)), l(e)), y = setTimeout(function() {
y = null, p(e)
}, 50), D(), r(Math.pow(2, .002 * Fo()) * L.k), a(g, h), c(e)
}
function m() {
var e = oo.mouse(this),
i = Math.log(L.k) / Math.LN2;
n(this, e, t(e), oo.event.shiftKey ? Math.ceil(i) - 1 : Math.floor(i) + 1)
}
var h, g, _, y, b, v, x, w, M, L = {
x: 0,
y: 0,
k: 1
},
j = [960, 500],
I = Yo,
k = 250,
N = 0,
S = "mousedown.zoom",
z = "mousemove.zoom",
T = "mouseup.zoom",
E = "touchstart.zoom",
A = C(e, "zoomstart", "zoom", "zoomend");
return Wo || (Wo = "onwheel" in co ? (Fo = function() {
return -oo.event.deltaY * (oo.event.deltaMode ? 120 : 1)
}, "wheel") : "onmousewheel" in co ? (Fo = function() {
return oo.event.wheelDelta
}, "mousewheel") : (Fo = function() {
return -oo.event.detail
}, "MozMousePixelScroll")), e.event = function(e) {
e.each(function() {
var e = A.of(this, arguments),
t = L;
Hl ? oo.select(this).transition().each("start.zoom", function() {
L = this.__chart__ || {
x: 0,
y: 0,
k: 1
}, l(e)
}).tween("zoom:zoom", function() {
var i = j[0],
r = j[1],
a = g ? g[0] : i / 2,
n = g ? g[1] : r / 2,
o = oo.interpolateZoom([(a - L.x) / L.k, (n - L.y) / L.k, i / L.k], [(a - t.x) / t.k, (n - t.y) / t.k, i / t.k]);
return function(t) {
var r = o(t),
s = i / r[2];
this.__chart__ = L = {
x: a - r[0] * s,
y: n - r[1] * s,
k: s
}, c(e)
}
}).each("interrupt.zoom", function() {
p(e)
}).each("end.zoom", function() {
p(e)
}) : (this.__chart__ = L, l(e), c(e), p(e))
})
}, e.translate = function(t) {
return arguments.length ? (L = {
x: +t[0],
y: +t[1],
k: L.k
}, s(), e) : [L.x, L.y]
}, e.scale = function(t) {
return arguments.length ? (L = {
x: L.x,
y: L.y,
k: +t
}, s(), e) : L.k
}, e.scaleExtent = function(t) {
return arguments.length ? (I = null == t ? Yo : [+t[0], +t[1]], e) : I
}, e.center = function(t) {
return arguments.length ? (_ = t && [+t[0], +t[1]], e) : _
}, e.size = function(t) {
return arguments.length ? (j = t && [+t[0], +t[1]], e) : j
}, e.duration = function(t) {
return arguments.length ? (k = +t, e) : k
}, e.x = function(t) {
return arguments.length ? (x = t, v = t.copy(), L = {
x: 0,
y: 0,
k: 1
}, e) : x
}, e.y = function(t) {
return arguments.length ? (M = t, w = t.copy(), L = {
x: 0,
y: 0,
k: 1
}, e) : M
}, oo.rebind(e, A, "on")
};
var Fo, Wo, Yo = [0, 1 / 0];
oo.color = de, de.prototype.toString = function() {
return this.rgb() + ""
}, oo.hsl = ue;
var Jo = ue.prototype = new de;
Jo.brighter = function(e) {
return e = Math.pow(.7, arguments.length ? e : 1), new ue(this.h, this.s, this.l / e)
}, Jo.darker = function(e) {
return e = Math.pow(.7, arguments.length ? e : 1), new ue(this.h, this.s, e * this.l)
}, Jo.rgb = function() {
return fe(this.h, this.s, this.l)
}, oo.hcl = me;
var Xo = me.prototype = new de;
Xo.brighter = function(e) {
return new me(this.h, this.c, Math.min(100, this.l + $o * (arguments.length ? e : 1)))
}, Xo.darker = function(e) {
return new me(this.h, this.c, Math.max(0, this.l - $o * (arguments.length ? e : 1)))
}, Xo.rgb = function() {
return he(this.h, this.c, this.l).rgb()
}, oo.lab = ge;
var $o = 18,
qo = .95047,
Ko = 1,
es = 1.08883,
ts = ge.prototype = new de;
ts.brighter = function(e) {
return new ge(Math.min(100, this.l + $o * (arguments.length ? e : 1)), this.a, this.b)
}, ts.darker = function(e) {
return new ge(Math.max(0, this.l - $o * (arguments.length ? e : 1)), this.a, this.b)
}, ts.rgb = function() {
return _e(this.l, this.a, this.b)
}, oo.rgb = we;
var is = we.prototype = new de;
is.brighter = function(e) {
e = Math.pow(.7, arguments.length ? e : 1);
var t = this.r,
i = this.g,
r = this.b,
a = 30;
return t || i || r ? (t && a > t && (t = a), i && a > i && (i = a), r && a > r && (r = a), new we(Math.min(255, t / e), Math.min(255, i / e), Math.min(255, r / e))) : new we(a, a, a)
}, is.darker = function(e) {
return e = Math.pow(.7, arguments.length ? e : 1), new we(e * this.r, e * this.g, e * this.b)
}, is.hsl = function() {
return ke(this.r, this.g, this.b)
}, is.toString = function() {
return "#" + je(this.r) + je(this.g) + je(this.b)
};
var rs = oo.map({
aliceblue: 15792383,
antiquewhite: 16444375,
aqua: 65535,
aquamarine: 8388564,
azure: 15794175,
beige: 16119260,
bisque: 16770244,
black: 0,
blanchedalmond: 16772045,
blue: 255,
blueviolet: 9055202,
brown: 10824234,
burlywood: 14596231,
cadetblue: 6266528,
chartreuse: 8388352,
chocolate: 13789470,
coral: 16744272,
cornflowerblue: 6591981,
cornsilk: 16775388,
crimson: 14423100,
cyan: 65535,
darkblue: 139,
darkcyan: 35723,
darkgoldenrod: 12092939,
darkgray: 11119017,
darkgreen: 25600,
darkgrey: 11119017,
darkkhaki: 12433259,
darkmagenta: 9109643,
darkolivegreen: 5597999,
darkorange: 16747520,
darkorchid: 10040012,
darkred: 9109504,
darksalmon: 15308410,
darkseagreen: 9419919,
darkslateblue: 4734347,
darkslategray: 3100495,
darkslategrey: 3100495,
darkturquoise: 52945,
darkviolet: 9699539,
deeppink: 16716947,
deepskyblue: 49151,
dimgray: 6908265,
dimgrey: 6908265,
dodgerblue: 2003199,
firebrick: 11674146,
floralwhite: 16775920,
forestgreen: 2263842,
fuchsia: 16711935,
gainsboro: 14474460,
ghostwhite: 16316671,
gold: 16766720,
goldenrod: 14329120,
gray: 8421504,
green: 32768,
greenyellow: 11403055,
grey: 8421504,
honeydew: 15794160,
hotpink: 16738740,
indianred: 13458524,
indigo: 4915330,
ivory: 16777200,
khaki: 15787660,
lavender: 15132410,
lavenderblush: 16773365,
lawngreen: 8190976,
lemonchiffon: 16775885,
lightblue: 11393254,
lightcoral: 15761536,
lightcyan: 14745599,
lightgoldenrodyellow: 16448210,
lightgray: 13882323,
lightgreen: 9498256,
lightgrey: 13882323,
lightpink: 16758465,
lightsalmon: 16752762,
lightseagreen: 2142890,
lightskyblue: 8900346,
lightslategray: 7833753,
lightslategrey: 7833753,
lightsteelblue: 11584734,
lightyellow: 16777184,
lime: 65280,
limegreen: 3329330,
linen: 16445670,
magenta: 16711935,
maroon: 8388608,
mediumaquamarine: 6737322,
mediumblue: 205,
mediumorchid: 12211667,
mediumpurple: 9662683,
mediumseagreen: 3978097,
mediumslateblue: 8087790,
mediumspringgreen: 64154,
mediumturquoise: 4772300,
mediumvioletred: 13047173,
midnightblue: 1644912,
mintcream: 16121850,
mistyrose: 16770273,
moccasin: 16770229,
navajowhite: 16768685,
navy: 128,
oldlace: 16643558,
olive: 8421376,
olivedrab: 7048739,
orange: 16753920,
orangered: 16729344,
orchid: 14315734,
palegoldenrod: 15657130,
palegreen: 10025880,
paleturquoise: 11529966,
palevioletred: 14381203,
papayawhip: 16773077,
peachpuff: 16767673,
peru: 13468991,
pink: 16761035,
plum: 14524637,
powderblue: 11591910,
purple: 8388736,
rebeccapurple: 6697881,
red: 16711680,
rosybrown: 12357519,
royalblue: 4286945,
saddlebrown: 9127187,
salmon: 16416882,
sandybrown: 16032864,
seagreen: 3050327,
seashell: 16774638,
sienna: 10506797,
silver: 12632256,
skyblue: 8900331,
slateblue: 6970061,
slategray: 7372944,
slategrey: 7372944,
snow: 16775930,
springgreen: 65407,
steelblue: 4620980,
tan: 13808780,
teal: 32896,
thistle: 14204888,
tomato: 16737095,
turquoise: 4251856,
violet: 15631086,
wheat: 16113331,
white: 16777215,
whitesmoke: 16119285,
yellow: 16776960,
yellowgreen: 10145074
});
rs.forEach(function(e, t) {
rs.set(e, Me(t))
}), oo.functor = Ce, oo.xhr = ze(M), oo.dsv = function(e, t) {
function i(e, i, n) {
arguments.length < 3 && (n = i, i = null);
var o = Te(e, t, null == i ? r : a(i), n);
return o.row = function(e) {
return arguments.length ? o.response(null == (i = e) ? r : a(e)) : i
}, o
}
function r(e) {
return i.parse(e.responseText)
}
function a(e) {
return function(t) {
return i.parse(t.responseText, e)
}
}
function n(t) {
return t.map(o).join(e)
}
function o(e) {
return s.test(e) ? '"' + e.replace(/\"/g, '""') + '"' : e
}
var s = new RegExp('["' + e + "\n]"),
l = e.charCodeAt(0);
return i.parse = function(e, t) {
var r;
return i.parseRows(e, function(e, i) {
if (r) return r(e, i - 1);
var a = new Function("d", "return {" + e.map(function(e, t) {
return JSON.stringify(e) + ": d[" + t + "]"
}).join(",") + "}");
r = t ? function(e, i) {
return t(a(e), i)
} : a
})
}, i.parseRows = function(e, t) {
function i() {
if (p >= c) return o;
if (a) return a = !1, n;
var t = p;
if (34 === e.charCodeAt(t)) {
for (var i = t; i++ < c;)
if (34 === e.charCodeAt(i)) {
if (34 !== e.charCodeAt(i + 1)) break;
++i
}
p = i + 2;
var r = e.charCodeAt(i + 1);
return 13 === r ? (a = !0, 10 === e.charCodeAt(i + 2) && ++p) : 10 === r && (a = !0), e.slice(t + 1, i).replace(/""/g, '"')
}
for (; c > p;) {
var r = e.charCodeAt(p++),
s = 1;
if (10 === r) a = !0;
else if (13 === r) a = !0, 10 === e.charCodeAt(p) && (++p, ++s);
else if (r !== l) continue;
return e.slice(t, p - s)
}
return e.slice(t)
}
for (var r, a, n = {}, o = {}, s = [], c = e.length, p = 0, d = 0;
(r = i()) !== o;) {
for (var u = []; r !== n && r !== o;) u.push(r), r = i();
t && null == (u = t(u, d++)) || s.push(u)
}
return s
}, i.format = function(t) {
if (Array.isArray(t[0])) return i.formatRows(t);
var r = new w,
a = [];
return t.forEach(function(e) {
for (var t in e) r.has(t) || a.push(r.add(t))
}), [a.map(o).join(e)].concat(t.map(function(t) {
return a.map(function(e) {
return o(t[e])
}).join(e)
})).join("\n")
}, i.formatRows = function(e) {
return e.map(n).join("\n")
}, i
}, oo.csv = oo.dsv(",", "text/csv"), oo.tsv = oo.dsv(" ", "text/tab-separated-values");
var as, ns, os, ss, ls, cs = this[j(this, "requestAnimationFrame")] || function(e) {
setTimeout(e, 17)
};
oo.timer = function(e, t, i) {
var r = arguments.length;
2 > r && (t = 0), 3 > r && (i = Date.now());
var a = i + t,
n = {
c: e,
t: a,
f: !1,
n: null
};
ns ? ns.n = n : as = n, ns = n, os || (ss = clearTimeout(ss), os = 1, cs(Pe))
}, oo.timer.flush = function() {
Oe(), Ze()
}, oo.round = function(e, t) {
return t ? Math.round(e * (t = Math.pow(10, t))) / t : Math.round(e)
};
var ps = ["y", "z", "a", "f", "p", "n", "µ", "m", "", "k", "M", "G", "T", "P", "E", "Z", "Y"].map(Ue);
oo.formatPrefix = function(e, t) {
var i = 0;
return e && (0 > e && (e *= -1), t && (e = oo.round(e, He(e, t))), i = 1 + Math.floor(1e-12 + Math.log(e) / Math.LN10), i = Math.max(-24, Math.min(24, 3 * Math.floor((i - 1) / 3)))), ps[8 + i / 3]
};
var ds = /(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i,
us = oo.map({
b: function(e) {
return e.toString(2)
},
c: function(e) {
return String.fromCharCode(e)
},
o: function(e) {
return e.toString(8)
},
x: function(e) {
return e.toString(16)
},
X: function(e) {
return e.toString(16).toUpperCase()
},
g: function(e, t) {
return e.toPrecision(t)
},
e: function(e, t) {
return e.toExponential(t)
},
f: function(e, t) {
return e.toFixed(t)
},
r: function(e, t) {
return (e = oo.round(e, He(e, t))).toFixed(Math.max(0, Math.min(20, He(e * (1 + 1e-15), t))))
}
}),
fs = oo.time = {},
ms = Date;
Re.prototype = {
getDate: function() {
return this._.getUTCDate()
},
getDay: function() {
return this._.getUTCDay()
},
getFullYear: function() {
return this._.getUTCFullYear()
},
getHours: function() {
return this._.getUTCHours()
},
getMilliseconds: function() {
return this._.getUTCMilliseconds()
},
getMinutes: function() {
return this._.getUTCMinutes()
},
getMonth: function() {
return this._.getUTCMonth()
},
getSeconds: function() {
return this._.getUTCSeconds()
},
getTime: function() {
return this._.getTime()
},
getTimezoneOffset: function() {
return 0
},
valueOf: function() {
return this._.valueOf()
},
setDate: function() {
hs.setUTCDate.apply(this._, arguments)
},
setDay: function() {
hs.setUTCDay.apply(this._, arguments)
},
setFullYear: function() {
hs.setUTCFullYear.apply(this._, arguments)
},
setHours: function() {
hs.setUTCHours.apply(this._, arguments)
},
setMilliseconds: function() {
hs.setUTCMilliseconds.apply(this._, arguments)
},
setMinutes: function() {
hs.setUTCMinutes.apply(this._, arguments)
},
setMonth: function() {
hs.setUTCMonth.apply(this._, arguments)
},
setSeconds: function() {
hs.setUTCSeconds.apply(this._, arguments)
},
setTime: function() {
hs.setTime.apply(this._, arguments)
}
};
var hs = Date.prototype;
fs.year = Qe(function(e) {
return e = fs.day(e), e.setMonth(0, 1), e
}, function(e, t) {
e.setFullYear(e.getFullYear() + t)
}, function(e) {
return e.getFullYear()
}), fs.years = fs.year.range, fs.years.utc = fs.year.utc.range, fs.day = Qe(function(e) {
var t = new ms(2e3, 0);
return t.setFullYear(e.getFullYear(), e.getMonth(), e.getDate()), t
}, function(e, t) {
e.setDate(e.getDate() + t)
}, function(e) {
return e.getDate() - 1
}), fs.days = fs.day.range, fs.days.utc = fs.day.utc.range, fs.dayOfYear = function(e) {
var t = fs.year(e);
return Math.floor((e - t - 6e4 * (e.getTimezoneOffset() - t.getTimezoneOffset())) / 864e5)
}, ["sunday", "monday", "tuesday", "wednesday", "thursday", "friday", "saturday"].forEach(function(e, t) {
t = 7 - t;
var i = fs[e] = Qe(function(e) {
return (e = fs.day(e)).setDate(e.getDate() - (e.getDay() + t) % 7), e
}, function(e, t) {
e.setDate(e.getDate() + 7 * Math.floor(t))
}, function(e) {
var i = fs.year(e).getDay();
return Math.floor((fs.dayOfYear(e) + (i + t) % 7) / 7) - (i !== t)
});
fs[e + "s"] = i.range, fs[e + "s"].utc = i.utc.range, fs[e + "OfYear"] = function(e) {
var i = fs.year(e).getDay();
return Math.floor((fs.dayOfYear(e) + (i + t) % 7) / 7)
}
}), fs.week = fs.sunday, fs.weeks = fs.sunday.range, fs.weeks.utc = fs.sunday.utc.range, fs.weekOfYear = fs.sundayOfYear;
var gs = {
"-": "",
_: " ",
0: "0"
},
_s = /^\s*\d+/,
ys = /^%/;
oo.locale = function(e) {
return {
numberFormat: Ge(e),
timeFormat: Fe(e)
}
};
var bs = oo.locale({
decimal: ".",
thousands: ",",
grouping: [3],
currency: ["$", ""],
dateTime: "%a %b %e %X %Y",
date: "%m/%d/%Y",
time: "%H:%M:%S",
periods: ["AM", "PM"],
days: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"],
shortDays: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"],
months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],
shortMonths: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]
});
oo.format = bs.numberFormat, oo.geo = {}, ft.prototype = {
s: 0,
t: 0,
add: function(e) {
mt(e, this.t, vs), mt(vs.s, this.s, this), this.s ? this.t += vs.t : this.s = vs.t
},
reset: function() {
this.s = this.t = 0
},
valueOf: function() {
return this.s
}
};
var vs = new ft;
oo.geo.stream = function(e, t) {
e && xs.hasOwnProperty(e.type) ? xs[e.type](e, t) : ht(e, t)
};
var xs = {
Feature: function(e, t) {
ht(e.geometry, t)
},
FeatureCollection: function(e, t) {
for (var i = e.features, r = -1, a = i.length; ++r < a;) ht(i[r].geometry, t)
}
},
ws = {
Sphere: function(e, t) {
t.sphere()
},
Point: function(e, t) {
e = e.coordinates, t.point(e[0], e[1], e[2])
},
MultiPoint: function(e, t) {
for (var i = e.coordinates, r = -1, a = i.length; ++r < a;) e = i[r], t.point(e[0], e[1], e[2])
},
LineString: function(e, t) {
gt(e.coordinates, t, 0)
},
MultiLineString: function(e, t) {
for (var i = e.coordinates, r = -1, a = i.length; ++r < a;) gt(i[r], t, 0)
},
Polygon: function(e, t) {
_t(e.coordinates, t)
},
MultiPolygon: function(e, t) {
for (var i = e.coordinates, r = -1, a = i.length; ++r < a;) _t(i[r], t)
},
GeometryCollection: function(e, t) {
for (var i = e.geometries, r = -1, a = i.length; ++r < a;) ht(i[r], t)
}
};
oo.geo.area = function(e) {
return Ms = 0, oo.geo.stream(e, js), Ms
};
var Ms, Ls = new ft,
js = {
sphere: function() {
Ms += 4 * Oo
},
point: I,
lineStart: I,
lineEnd: I,
polygonStart: function() {
Ls.reset(), js.lineStart = yt
},
polygonEnd: function() {
var e = 2 * Ls;
Ms += 0 > e ? 4 * Oo + e : e, js.lineStart = js.lineEnd = js.point = I
}
};
oo.geo.bounds = function() {
function e(e, t) {
b.push(v = [p = e, u = e]), d > t && (d = t), t > f && (f = t)
}
function t(t, i) {
var r = bt([t * Go, i * Go]);
if (_) {
var a = xt(_, r),
n = [a[1], -a[0], 0],
o = xt(n, a);
Lt(o), o = jt(o);
var l = t - m,
c = l > 0 ? 1 : -1,
h = o[0] * Bo * c,
g = bo(l) > 180;
if (g ^ (h > c * m && c * t > h)) {
var y = o[1] * Bo;
y > f && (f = y)
} else if (h = (h + 360) % 360 - 180, g ^ (h > c * m && c * t > h)) {
var y = -o[1] * Bo;
d > y && (d = y)
} else d > i && (d = i), i > f && (f = i);
g ? m > t ? s(p, t) > s(p, u) && (u = t) : s(t, u) > s(p, u) && (p = t) : u >= p ? (p > t && (p = t), t > u && (u = t)) : t > m ? s(p, t) > s(p, u) && (u = t) : s(t, u) > s(p, u) && (p = t)
} else e(t, i);
_ = r, m = t
}
function i() {
x.point = t
}
function r() {
v[0] = p, v[1] = u, x.point = e, _ = null
}
function a(e, i) {
if (_) {
var r = e - m;
y += bo(r) > 180 ? r + (r > 0 ? 360 : -360) : r
} else h = e, g = i;
js.point(e, i), t(e, i)
}
function n() {
js.lineStart()
}
function o() {
a(h, g), js.lineEnd(), bo(y) > Ao && (p = -(u = 180)), v[0] = p, v[1] = u, _ = null
}
function s(e, t) {
return (t -= e) < 0 ? t + 360 : t
}
function l(e, t) {
return e[0] - t[0]
}
function c(e, t) {
return t[0] <= t[1] ? t[0] <= e && e <= t[1] : e < t[0] || t[1] < e
}
var p, d, u, f, m, h, g, _, y, b, v, x = {
point: e,
lineStart: i,
lineEnd: r,
polygonStart: function() {
x.point = a, x.lineStart = n, x.lineEnd = o, y = 0, js.polygonStart()
},
polygonEnd: function() {
js.polygonEnd(), x.point = e, x.lineStart = i, x.lineEnd = r, 0 > Ls ? (p = -(u = 180), d = -(f = 90)) : y > Ao ? f = 90 : -Ao > y && (d = -90), v[0] = p, v[1] = u
}
};
return function(e) {
f = u = -(p = d = 1 / 0), b = [], oo.geo.stream(e, x);
var t = b.length;
if (t) {
b.sort(l);
for (var i, r = 1, a = b[0], n = [a]; t > r; ++r) i = b[r], c(i[0], a) || c(i[1], a) ? (s(a[0], i[1]) > s(a[0], a[1]) && (a[1] = i[1]), s(i[0], a[1]) > s(a[0], a[1]) && (a[0] = i[0])) : n.push(a = i);
for (var o, i, m = -(1 / 0), t = n.length - 1, r = 0, a = n[t]; t >= r; a = i, ++r) i = n[r], (o = s(a[1], i[0])) > m && (m = o, p = i[0], u = a[1])
}
return b = v = null, p === 1 / 0 || d === 1 / 0 ? [
[NaN, NaN],
[NaN, NaN]
] : [
[p, d],
[u, f]
]
}
}(), oo.geo.centroid = function(e) {
Is = ks = Ns = Ds = Ss = Cs = zs = Ts = Es = As = Ps = 0, oo.geo.stream(e, Os);
var t = Es,
i = As,
r = Ps,
a = t * t + i * i + r * r;
return Po > a && (t = Cs, i = zs, r = Ts, Ao > ks && (t = Ns, i = Ds, r = Ss), a = t * t + i * i + r * r, Po > a) ? [NaN, NaN] : [Math.atan2(i, t) * Bo, oe(r / Math.sqrt(a)) * Bo]
};
var Is, ks, Ns, Ds, Ss, Cs, zs, Ts, Es, As, Ps, Os = {
sphere: I,
point: kt,
lineStart: Dt,
lineEnd: St,
polygonStart: function() {
Os.lineStart = Ct
},
polygonEnd: function() {
Os.lineStart = Dt
}
},
Zs = Ot(Tt, Gt, Rt, [-Oo, -Oo / 2]),
Hs = 1e9;
oo.geo.clipExtent = function() {
var e, t, i, r, a, n, o = {
stream: function(e) {
return a && (a.valid = !1), a = n(e), a.valid = !0, a
},
extent: function(s) {
return arguments.length ? (n = Wt(e = +s[0][0], t = +s[0][1], i = +s[1][0], r = +s[1][1]), a && (a.valid = !1, a = null), o) : [
[e, t],
[i, r]
]
}
};
return o.extent([
[0, 0],
[960, 500]
])
}, (oo.geo.conicEqualArea = function() {
return Yt(Jt)
}).raw = Jt, oo.geo.albers = function() {
return oo.geo.conicEqualArea().rotate([96, 0]).center([-.6, 38.7]).parallels([29.5, 45.5]).scale(1070)
}, oo.geo.albersUsa = function() {
function e(e) {
var n = e[0],
o = e[1];
return t = null, i(n, o), t || (r(n, o), t) || a(n, o), t
}
var t, i, r, a, n = oo.geo.albers(),
o = oo.geo.conicEqualArea().rotate([154, 0]).center([-2, 58.5]).parallels([55, 65]),
s = oo.geo.conicEqualArea().rotate([157, 0]).center([-3, 19.9]).parallels([8, 18]),
l = {
point: function(e, i) {
t = [e, i]
}
};
return e.invert = function(e) {
var t = n.scale(),
i = n.translate(),
r = (e[0] - i[0]) / t,
a = (e[1] - i[1]) / t;
return (a >= .12 && .234 > a && r >= -.425 && -.214 > r ? o : a >= .166 && .234 > a && r >= -.214 && -.115 > r ? s : n).invert(e)
}, e.stream = function(e) {
var t = n.stream(e),
i = o.stream(e),
r = s.stream(e);
return {
point: function(e, a) {
t.point(e, a), i.point(e, a), r.point(e, a)
},
sphere: function() {
t.sphere(), i.sphere(), r.sphere()
},
lineStart: function() {
t.lineStart(), i.lineStart(), r.lineStart()
},
lineEnd: function() {
t.lineEnd(), i.lineEnd(), r.lineEnd()
},
polygonStart: function() {
t.polygonStart(), i.polygonStart(), r.polygonStart()
},
polygonEnd: function() {
t.polygonEnd(), i.polygonEnd(), r.polygonEnd()
}
}
}, e.precision = function(t) {
return arguments.length ? (n.precision(t), o.precision(t), s.precision(t), e) : n.precision()
}, e.scale = function(t) {
return arguments.length ? (n.scale(t), o.scale(.35 * t), s.scale(t), e.translate(n.translate())) : n.scale()
}, e.translate = function(t) {
if (!arguments.length) return n.translate();
var c = n.scale(),
p = +t[0],
d = +t[1];
return i = n.translate(t).clipExtent([
[p - .455 * c, d - .238 * c],
[p + .455 * c, d + .238 * c]
]).stream(l).point, r = o.translate([p - .307 * c, d + .201 * c]).clipExtent([
[p - .425 * c + Ao, d + .12 * c + Ao],
[p - .214 * c - Ao, d + .234 * c - Ao]
]).stream(l).point, a = s.translate([p - .205 * c, d + .212 * c]).clipExtent([
[p - .214 * c + Ao, d + .166 * c + Ao],
[p - .115 * c - Ao, d + .234 * c - Ao]
]).stream(l).point, e
}, e.scale(1070)
};
var Us, Gs, Bs, Rs, Qs, Vs, Fs = {
point: I,
lineStart: I,
lineEnd: I,
polygonStart: function() {
Gs = 0, Fs.lineStart = Xt
},
polygonEnd: function() {
Fs.lineStart = Fs.lineEnd = Fs.point = I, Us += bo(Gs / 2)
}
},
Ws = {
point: $t,
lineStart: I,
lineEnd: I,
polygonStart: I,
polygonEnd: I
},
Ys = {
point: ei,
lineStart: ti,
lineEnd: ii,
polygonStart: function() {
Ys.lineStart = ri
},
polygonEnd: function() {
Ys.point = ei, Ys.lineStart = ti, Ys.lineEnd = ii
}
};
oo.geo.path = function() {
function e(e) {
return e && ("function" == typeof s && n.pointRadius(+s.apply(this, arguments)), o && o.valid || (o = a(n)), oo.geo.stream(e, o)), n.result()
}
function t() {
return o = null, e
}
var i, r, a, n, o, s = 4.5;
return e.area = function(e) {
return Us = 0, oo.geo.stream(e, a(Fs)), Us
}, e.centroid = function(e) {
return Ns = Ds = Ss = Cs = zs = Ts = Es = As = Ps = 0, oo.geo.stream(e, a(Ys)), Ps ? [Es / Ps, As / Ps] : Ts ? [Cs / Ts, zs / Ts] : Ss ? [Ns / Ss, Ds / Ss] : [NaN, NaN]
}, e.bounds = function(e) {
return Qs = Vs = -(Bs = Rs = 1 / 0), oo.geo.stream(e, a(Ws)), [
[Bs, Rs],
[Qs, Vs]
]
}, e.projection = function(e) {
return arguments.length ? (a = (i = e) ? e.stream || oi(e) : M, t()) : i
}, e.context = function(e) {
return arguments.length ? (n = null == (r = e) ? new qt : new ai(e), "function" != typeof s && n.pointRadius(s), t()) : r
}, e.pointRadius = function(t) {
return arguments.length ? (s = "function" == typeof t ? t : (n.pointRadius(+t), +t), e) : s
}, e.projection(oo.geo.albersUsa()).context(null)
}, oo.geo.transform = function(e) {
return {
stream: function(t) {
var i = new si(t);
for (var r in e) i[r] = e[r];
return i
}
}
}, si.prototype = {
point: function(e, t) {
this.stream.point(e, t)
},
sphere: function() {
this.stream.sphere()
},
lineStart: function() {
this.stream.lineStart()
},
lineEnd: function() {
this.stream.lineEnd()
},
polygonStart: function() {
this.stream.polygonStart()
},
polygonEnd: function() {
this.stream.polygonEnd()
}
}, oo.geo.projection = ci, oo.geo.projectionMutator = pi, (oo.geo.equirectangular = function() {
return ci(ui)
}).raw = ui.invert = ui, oo.geo.rotation = function(e) {
function t(t) {
return t = e(t[0] * Go, t[1] * Go), t[0] *= Bo, t[1] *= Bo, t
}
return e = mi(e[0] % 360 * Go, e[1] * Go, e.length > 2 ? e[2] * Go : 0), t.invert = function(t) {
return t = e.invert(t[0] * Go, t[1] * Go), t[0] *= Bo, t[1] *= Bo, t
}, t
}, fi.invert = ui, oo.geo.circle = function() {
function e() {
var e = "function" == typeof r ? r.apply(this, arguments) : r,
t = mi(-e[0] * Go, -e[1] * Go, 0).invert,
a = [];
return i(null, null, 1, {
point: function(e, i) {
a.push(e = t(e, i)), e[0] *= Bo, e[1] *= Bo
}
}), {
type: "Polygon",
coordinates: [a]
}
}
var t, i, r = [0, 0],
a = 6;
return e.origin = function(t) {
return arguments.length ? (r = t, e) : r
}, e.angle = function(r) {
return arguments.length ? (i = yi((t = +r) * Go, a * Go), e) : t
}, e.precision = function(r) {
return arguments.length ? (i = yi(t * Go, (a = +r) * Go), e) : a
}, e.angle(90)
}, oo.geo.distance = function(e, t) {
var i, r = (t[0] - e[0]) * Go,
a = e[1] * Go,
n = t[1] * Go,
o = Math.sin(r),
s = Math.cos(r),
l = Math.sin(a),
c = Math.cos(a),
p = Math.sin(n),
d = Math.cos(n);
return Math.atan2(Math.sqrt((i = d * o) * i + (i = c * p - l * d * s) * i), l * p + c * d * s)
}, oo.geo.graticule = function() {
function e() {
return {
type: "MultiLineString",
coordinates: t()
}
}
function t() {
return oo.range(Math.ceil(n / g) * g, a, g).map(u).concat(oo.range(Math.ceil(c / _) * _, l, _).map(f)).concat(oo.range(Math.ceil(r / m) * m, i, m).filter(function(e) {
return bo(e % g) > Ao
}).map(p)).concat(oo.range(Math.ceil(s / h) * h, o, h).filter(function(e) {
return bo(e % _) > Ao
}).map(d))
}
var i, r, a, n, o, s, l, c, p, d, u, f, m = 10,
h = m,
g = 90,
_ = 360,
y = 2.5;
return e.lines = function() {
return t().map(function(e) {
return {
type: "LineString",
coordinates: e
}
})
}, e.outline = function() {
return {
type: "Polygon",
coordinates: [u(n).concat(f(l).slice(1), u(a).reverse().slice(1), f(c).reverse().slice(1))]
}
}, e.extent = function(t) {
return arguments.length ? e.majorExtent(t).minorExtent(t) : e.minorExtent()
}, e.majorExtent = function(t) {
return arguments.length ? (n = +t[0][0], a = +t[1][0], c = +t[0][1], l = +t[1][1], n > a && (t = n, n = a, a = t), c > l && (t = c, c = l, l = t), e.precision(y)) : [
[n, c],
[a, l]
]
}, e.minorExtent = function(t) {
return arguments.length ? (r = +t[0][0], i = +t[1][0], s = +t[0][1], o = +t[1][1], r > i && (t = r, r = i, i = t), s > o && (t = s, s = o, o = t), e.precision(y)) : [
[r, s],
[i, o]
]
}, e.step = function(t) {
return arguments.length ? e.majorStep(t).minorStep(t) : e.minorStep()
}, e.majorStep = function(t) {
return arguments.length ? (g = +t[0], _ = +t[1], e) : [g, _]
}, e.minorStep = function(t) {
return arguments.length ? (m = +t[0], h = +t[1], e) : [m, h]
}, e.precision = function(t) {
return arguments.length ? (y = +t, p = vi(s, o, 90), d = xi(r, i, y), u = vi(c, l, 90), f = xi(n, a, y), e) : y
}, e.majorExtent([
[-180, -90 + Ao],
[180, 90 - Ao]
]).minorExtent([
[-180, -80 - Ao],
[180, 80 + Ao]
])
}, oo.geo.greatArc = function() {
function e() {
return {
type: "LineString",
coordinates: [t || r.apply(this, arguments), i || a.apply(this, arguments)]
}
}
var t, i, r = wi,
a = Mi;
return e.distance = function() {
return oo.geo.distance(t || r.apply(this, arguments), i || a.apply(this, arguments))
}, e.source = function(i) {
return arguments.length ? (r = i, t = "function" == typeof i ? null : i, e) : r
}, e.target = function(t) {
return arguments.length ? (a = t, i = "function" == typeof t ? null : t, e) : a
}, e.precision = function() {
return arguments.length ? e : 0
}, e
}, oo.geo.interpolate = function(e, t) {
return Li(e[0] * Go, e[1] * Go, t[0] * Go, t[1] * Go)
}, oo.geo.length = function(e) {
return Js = 0, oo.geo.stream(e, Xs), Js
};
var Js, Xs = {
sphere: I,
point: I,
lineStart: ji,
lineEnd: I,
polygonStart: I,
polygonEnd: I
},
$s = Ii(function(e) {
return Math.sqrt(2 / (1 + e))
}, function(e) {
return 2 * Math.asin(e / 2)
});
(oo.geo.azimuthalEqualArea = function() {
return ci($s)
}).raw = $s;
var qs = Ii(function(e) {
var t = Math.acos(e);
return t && t / Math.sin(t)
}, M);
(oo.geo.azimuthalEquidistant = function() {
return ci(qs)
}).raw = qs, (oo.geo.conicConformal = function() {
return Yt(ki)
}).raw = ki, (oo.geo.conicEquidistant = function() {
return Yt(Ni)
}).raw = Ni;
var Ks = Ii(function(e) {
return 1 / e
}, Math.atan);
(oo.geo.gnomonic = function() {
return ci(Ks)
}).raw = Ks, Di.invert = function(e, t) {
return [e, 2 * Math.atan(Math.exp(t)) - Uo]
}, (oo.geo.mercator = function() {
return Si(Di)
}).raw = Di;
var el = Ii(function() {
return 1
}, Math.asin);
(oo.geo.orthographic = function() {
return ci(el)
}).raw = el;
var tl = Ii(function(e) {
return 1 / (1 + e)
}, function(e) {
return 2 * Math.atan(e)
});
(oo.geo.stereographic = function() {
return ci(tl)
}).raw = tl, Ci.invert = function(e, t) {
return [-t, 2 * Math.atan(Math.exp(e)) - Uo]
}, (oo.geo.transverseMercator = function() {
var e = Si(Ci),
t = e.center,
i = e.rotate;
return e.center = function(e) {
return e ? t([-e[1], e[0]]) : (e = t(), [e[1], -e[0]])
}, e.rotate = function(e) {
return e ? i([e[0], e[1], e.length > 2 ? e[2] + 90 : 90]) : (e = i(), [e[0], e[1], e[2] - 90])
}, i([0, 0, 90])
}).raw = Ci, oo.geom = {}, oo.geom.hull = function(e) {
function t(e) {
if (e.length < 3) return [];
var t, a = Ce(i),
n = Ce(r),
o = e.length,
s = [],
l = [];
for (t = 0; o > t; t++) s.push([+a.call(this, e[t], t), +n.call(this, e[t], t), t]);
for (s.sort(Ai), t = 0; o > t; t++) l.push([s[t][0], -s[t][1]]);
var c = Ei(s),
p = Ei(l),
d = p[0] === c[0],
u = p[p.length - 1] === c[c.length - 1],
f = [];
for (t = c.length - 1; t >= 0; --t) f.push(e[s[c[t]][2]]);
for (t = +d; t < p.length - u; ++t) f.push(e[s[p[t]][2]]);
return f
}
var i = zi,
r = Ti;
return arguments.length ? t(e) : (t.x = function(e) {
return arguments.length ? (i = e, t) : i
}, t.y = function(e) {
return arguments.length ? (r = e, t) : r
}, t)
}, oo.geom.polygon = function(e) {
return Lo(e, il), e
};
var il = oo.geom.polygon.prototype = [];
il.area = function() {
for (var e, t = -1, i = this.length, r = this[i - 1], a = 0; ++t < i;) e = r, r = this[t], a += e[1] * r[0] - e[0] * r[1];
return .5 * a
}, il.centroid = function(e) {
var t, i, r = -1,
a = this.length,
n = 0,
o = 0,
s = this[a - 1];
for (arguments.length || (e = -1 / (6 * this.area())); ++r < a;) t = s, s = this[r], i = t[0] * s[1] - s[0] * t[1], n += (t[0] + s[0]) * i, o += (t[1] + s[1]) * i;
return [n * e, o * e]
}, il.clip = function(e) {
for (var t, i, r, a, n, o, s = Zi(e), l = -1, c = this.length - Zi(this), p = this[c - 1]; ++l < c;) {
for (t = e.slice(), e.length = 0, a = this[l], n = t[(r = t.length - s) - 1], i = -1; ++i < r;) o = t[i], Pi(o, p, a) ? (Pi(n, p, a) || e.push(Oi(n, o, p, a)), e.push(o)) : Pi(n, p, a) && e.push(Oi(n, o, p, a)), n = o;
s && e.push(e[0]), p = a
}
return e
};
var rl, al, nl, ol, sl, ll = [],
cl = [];
Fi.prototype.prepare = function() {
for (var e, t = this.edges, i = t.length; i--;) e = t[i].edge, e.b && e.a || t.splice(i, 1);
return t.sort(Yi), t.length
}, ar.prototype = {
start: function() {
return this.edge.l === this.site ? this.edge.a : this.edge.b
},
end: function() {
return this.edge.l === this.site ? this.edge.b : this.edge.a
}
}, nr.prototype = {
insert: function(e, t) {
var i, r, a;
if (e) {
if (t.P = e, t.N = e.N, e.N && (e.N.P = t), e.N = t, e.R) {
for (e = e.R; e.L;) e = e.L;
e.L = t
} else e.R = t;
i = e
} else this._ ? (e = cr(this._), t.P = null, t.N = e, e.P = e.L = t, i = e) : (t.P = t.N = null, this._ = t, i = null);
for (t.L = t.R = null, t.U = i, t.C = !0, e = t; i && i.C;) r = i.U, i === r.L ? (a = r.R, a && a.C ? (i.C = a.C = !1, r.C = !0, e = r) : (e === i.R && (sr(this, i), e = i, i = e.U), i.C = !1, r.C = !0, lr(this, r))) : (a = r.L, a && a.C ? (i.C = a.C = !1, r.C = !0, e = r) : (e === i.L && (lr(this, i), e = i, i = e.U), i.C = !1, r.C = !0, sr(this, r))), i = e.U;
this._.C = !1
},
remove: function(e) {
e.N && (e.N.P = e.P), e.P && (e.P.N = e.N), e.N = e.P = null;
var t, i, r, a = e.U,
n = e.L,
o = e.R;
if (i = n ? o ? cr(o) : n : o, a ? a.L === e ? a.L = i : a.R = i : this._ = i, n && o ? (r = i.C, i.C = e.C, i.L = n, n.U = i, i !== o ? (a = i.U, i.U = e.U, e = i.R, a.L = e, i.R = o, o.U = i) : (i.U = a, a = i, e = i.R)) : (r = e.C, e = i), e && (e.U = a), !r) {
if (e && e.C) return void(e.C = !1);
do {
if (e === this._) break;
if (e === a.L) {
if (t = a.R, t.C && (t.C = !1, a.C = !0, sr(this, a), t = a.R), t.L && t.L.C || t.R && t.R.C) {
t.R && t.R.C || (t.L.C = !1, t.C = !0, lr(this, t), t = a.R), t.C = a.C, a.C = t.R.C = !1, sr(this, a), e = this._;
break
}
} else if (t = a.L, t.C && (t.C = !1, a.C = !0, lr(this, a), t = a.L), t.L && t.L.C || t.R && t.R.C) {
t.L && t.L.C || (t.R.C = !1, t.C = !0, sr(this, t), t = a.L), t.C = a.C, a.C = t.L.C = !1, lr(this, a), e = this._;
break
}
t.C = !0, e = a, a = a.U
} while (!e.C);
e && (e.C = !1)
}
}
}, oo.geom.voronoi = function(e) {
function t(e) {
var t = new Array(e.length),
r = s[0][0],
a = s[0][1],
n = s[1][0],
o = s[1][1];
return pr(i(e), s).cells.forEach(function(i, s) {
var l = i.edges,
c = i.site,
p = t[s] = l.length ? l.map(function(e) {
var t = e.start();
return [t.x, t.y]
}) : c.x >= r && c.x <= n && c.y >= a && c.y <= o ? [
[r, o],
[n, o],
[n, a],
[r, a]
] : [];
p.point = e[s]
}), t
}
function i(e) {
return e.map(function(e, t) {
return {
x: Math.round(n(e, t) / Ao) * Ao,
y: Math.round(o(e, t) / Ao) * Ao,
i: t
}
})
}
var r = zi,
a = Ti,
n = r,
o = a,
s = pl;
return e ? t(e) : (t.links = function(e) {
return pr(i(e)).edges.filter(function(e) {
return e.l && e.r
}).map(function(t) {
return {
source: e[t.l.i],
target: e[t.r.i]
}
})
}, t.triangles = function(e) {
var t = [];
return pr(i(e)).cells.forEach(function(i, r) {
for (var a, n, o = i.site, s = i.edges.sort(Yi), l = -1, c = s.length, p = s[c - 1].edge, d = p.l === o ? p.r : p.l; ++l < c;) a = p, n = d, p = s[l].edge, d = p.l === o ? p.r : p.l, r < n.i && r < d.i && ur(o, n, d) < 0 && t.push([e[r], e[n.i], e[d.i]])
}), t
}, t.x = function(e) {
return arguments.length ? (n = Ce(r = e), t) : r
}, t.y = function(e) {
return arguments.length ? (o = Ce(a = e), t) : a
}, t.clipExtent = function(e) {
return arguments.length ? (s = null == e ? pl : e, t) : s === pl ? null : s
}, t.size = function(e) {
return arguments.length ? t.clipExtent(e && [
[0, 0], e
]) : s === pl ? null : s && s[1]
}, t)
};
var pl = [
[-1e6, -1e6],
[1e6, 1e6]
];
oo.geom.delaunay = function(e) {
return oo.geom.voronoi().triangles(e)
}, oo.geom.quadtree = function(e, t, i, r, a) {
function n(e) {
function n(e, t, i, r, a, n, o, s) {
if (!isNaN(i) && !isNaN(r))
if (e.leaf) {
var l = e.x,
p = e.y;
if (null != l)
if (bo(l - i) + bo(p - r) < .01) c(e, t, i, r, a, n, o, s);
else {
var d = e.point;
e.x = e.y = e.point = null, c(e, d, l, p, a, n, o, s), c(e, t, i, r, a, n, o, s)
}
else e.x = i, e.y = r, e.point = t
} else c(e, t, i, r, a, n, o, s)
}
function c(e, t, i, r, a, o, s, l) {
var c = .5 * (a + s),
p = .5 * (o + l),
d = i >= c,
u = r >= p,
f = u << 1 | d;
e.leaf = !1, e = e.nodes[f] || (e.nodes[f] = hr()), d ? a = c : s = c, u ? o = p : l = p, n(e, t, i, r, a, o, s, l)
}
var p, d, u, f, m, h, g, _, y, b = Ce(s),
v = Ce(l);
if (null != t) h = t, g = i, _ = r, y = a;
else if (_ = y = -(h = g = 1 / 0), d = [], u = [], m = e.length, o)
for (f = 0; m > f; ++f) p = e[f], p.x < h && (h = p.x), p.y < g && (g = p.y), p.x > _ && (_ = p.x), p.y > y && (y = p.y), d.push(p.x), u.push(p.y);
else
for (f = 0; m > f; ++f) {
var x = +b(p = e[f], f),
w = +v(p, f);
h > x && (h = x), g > w && (g = w), x > _ && (_ = x), w > y && (y = w), d.push(x), u.push(w)
}
var M = _ - h,
L = y - g;
M > L ? y = g + M : _ = h + L;
var j = hr();
if (j.add = function(e) {
n(j, e, +b(e, ++f), +v(e, f), h, g, _, y)
}, j.visit = function(e) {
gr(e, j, h, g, _, y)
}, j.find = function(e) {
return _r(j, e[0], e[1], h, g, _, y)
}, f = -1, null == t) {
for (; ++f < m;) n(j, e[f], d[f], u[f], h, g, _, y);
--f
} else e.forEach(j.add);
return d = u = e = p = null, j
}
var o, s = zi,
l = Ti;
return (o = arguments.length) ? (s = fr, l = mr, 3 === o && (a = i, r = t, i = t = 0), n(e)) : (n.x = function(e) {
return arguments.length ? (s = e, n) : s
}, n.y = function(e) {
return arguments.length ? (l = e, n) : l
}, n.extent = function(e) {
return arguments.length ? (null == e ? t = i = r = a = null : (t = +e[0][0], i = +e[0][1], r = +e[1][0], a = +e[1][1]), n) : null == t ? null : [
[t, i],
[r, a]
]
}, n.size = function(e) {
return arguments.length ? (null == e ? t = i = r = a = null : (t = i = 0, r = +e[0], a = +e[1]), n) : null == t ? null : [r - t, a - i]
}, n)
}, oo.interpolateRgb = yr, oo.interpolateObject = br, oo.interpolateNumber = vr, oo.interpolateString = xr;
var dl = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,
ul = new RegExp(dl.source, "g");
oo.interpolate = wr, oo.interpolators = [function(e, t) {
var i = typeof t;
return ("string" === i ? rs.has(t.toLowerCase()) || /^(#|rgb\(|hsl\()/i.test(t) ? yr : xr : t instanceof de ? yr : Array.isArray(t) ? Mr : "object" === i && isNaN(t) ? br : vr)(e, t)
}], oo.interpolateArray = Mr;
var fl = function() {
return M
},
ml = oo.map({
linear: fl,
poly: Sr,
quad: function() {
return kr
},
cubic: function() {
return Nr
},
sin: function() {
return Cr
},
exp: function() {
return zr
},
circle: function() {
return Tr
},
elastic: Er,
back: Ar,
bounce: function() {
return Pr
}
}),
hl = oo.map({
"in": M,
out: jr,
"in-out": Ir,
"out-in": function(e) {
return Ir(jr(e))
}
});
oo.ease = function(e) {
var t = e.indexOf("-"),
i = t >= 0 ? e.slice(0, t) : e,
r = t >= 0 ? e.slice(t + 1) : "in";
return i = ml.get(i) || fl, r = hl.get(r) || M, Lr(r(i.apply(null, so.call(arguments, 1))))
}, oo.interpolateHcl = Or, oo.interpolateHsl = Zr, oo.interpolateLab = Hr, oo.interpolateRound = Ur, oo.transform = function(e) {
var t = co.createElementNS(oo.ns.prefix.svg, "g");
return (oo.transform = function(e) {
if (null != e) {
t.setAttribute("transform", e);
var i = t.transform.baseVal.consolidate()
}
return new Gr(i ? i.matrix : gl)
})(e)
}, Gr.prototype.toString = function() {
return "translate(" + this.translate + ")rotate(" + this.rotate + ")skewX(" + this.skew + ")scale(" + this.scale + ")"
};
var gl = {
a: 1,
b: 0,
c: 0,
d: 1,
e: 0,
f: 0
};
oo.interpolateTransform = Vr, oo.layout = {}, oo.layout.bundle = function() {
return function(e) {
for (var t = [], i = -1, r = e.length; ++i < r;) t.push(Yr(e[i]));
return t
}
}, oo.layout.chord = function() {
function e() {
var e, c, d, u, f, m = {},
h = [],
g = oo.range(n),
_ = [];
for (i = [], r = [], e = 0, u = -1; ++u < n;) {
for (c = 0, f = -1; ++f < n;) c += a[u][f];
h.push(c), _.push(oo.range(n)), e += c
}
for (o && g.sort(function(e, t) {
return o(h[e], h[t])
}), s && _.forEach(function(e, t) {
e.sort(function(e, i) {
return s(a[t][e], a[t][i])
})
}), e = (Zo - p * n) / e, c = 0, u = -1; ++u < n;) {
for (d = c, f = -1; ++f < n;) {
var y = g[u],
b = _[y][f],
v = a[y][b],
x = c,
w = c += v * e;
m[y + "-" + b] = {
index: y,
subindex: b,
startAngle: x,
endAngle: w,
value: v
}
}
r[y] = {
index: y,
startAngle: d,
endAngle: c,
value: (c - d) / e
}, c += p
}
for (u = -1; ++u < n;)
for (f = u - 1; ++f < n;) {
var M = m[u + "-" + f],
L = m[f + "-" + u];
(M.value || L.value) && i.push(M.value < L.value ? {
source: L,
target: M
} : {
source: M,
target: L
})
}
l && t()
}
function t() {
i.sort(function(e, t) {
return l((e.source.value + e.target.value) / 2, (t.source.value + t.target.value) / 2)
})
}
var i, r, a, n, o, s, l, c = {},
p = 0;
return c.matrix = function(e) {
return arguments.length ? (n = (a = e) && a.length, i = r = null, c) : a
}, c.padding = function(e) {
return arguments.length ? (p = e, i = r = null, c) : p
}, c.sortGroups = function(e) {
return arguments.length ? (o = e, i = r = null, c) : o
}, c.sortSubgroups = function(e) {
return arguments.length ? (s = e, i = null, c) : s
}, c.sortChords = function(e) {
return arguments.length ? (l = e, i && t(), c) : l
}, c.chords = function() {
return i || e(), i
}, c.groups = function() {
return r || e(), r
}, c
}, oo.layout.force = function() {
function e(e) {
return function(t, i, r, a) {
if (t.point !== e) {
var n = t.cx - e.x,
o = t.cy - e.y,
s = a - i,
l = n * n + o * o;
if (l > s * s / g) {
if (m > l) {
var c = t.charge / l;
e.px -= n * c, e.py -= o * c
}
return !0
}
if (t.point && l && m > l) {
var c = t.pointCharge / l;
e.px -= n * c, e.py -= o * c
}
}
return !t.charge
}
}
function t(e) {
e.px = oo.event.x, e.py = oo.event.y, s.resume()
}
var i, r, a, n, o, s = {},
l = oo.dispatch("start", "tick", "end"),
c = [1, 1],
p = .9,
d = _l,
u = yl,
f = -30,
m = bl,
h = .1,
g = .64,
_ = [],
y = [];
return s.tick = function() {
if ((r *= .99) < .005) return l.end({
type: "end",
alpha: r = 0
}), !0;
var t, i, s, d, u, m, g, b, v, x = _.length,
w = y.length;
for (i = 0; w > i; ++i) s = y[i], d = s.source, u = s.target, b = u.x - d.x, v = u.y - d.y, (m = b * b + v * v) && (m = r * n[i] * ((m = Math.sqrt(m)) - a[i]) / m, b *= m, v *= m, u.x -= b * (g = d.weight / (u.weight + d.weight)), u.y -= v * g, d.x += b * (g = 1 - g), d.y += v * g);
if ((g = r * h) && (b = c[0] / 2, v = c[1] / 2, i = -1, g))
for (; ++i < x;) s = _[i], s.x += (b - s.x) * g, s.y += (v - s.y) * g;
if (f)
for (ta(t = oo.geom.quadtree(_), r, o), i = -1; ++i < x;)(s = _[i]).fixed || t.visit(e(s));
for (i = -1; ++i < x;) s = _[i], s.fixed ? (s.x = s.px, s.y = s.py) : (s.x -= (s.px - (s.px = s.x)) * p, s.y -= (s.py - (s.py = s.y)) * p);
l.tick({
type: "tick",
alpha: r
})
}, s.nodes = function(e) {
return arguments.length ? (_ = e, s) : _
}, s.links = function(e) {
return arguments.length ? (y = e, s) : y
}, s.size = function(e) {
return arguments.length ? (c = e, s) : c
}, s.linkDistance = function(e) {
return arguments.length ? (d = "function" == typeof e ? e : +e, s) : d
}, s.distance = s.linkDistance, s.linkStrength = function(e) {
return arguments.length ? (u = "function" == typeof e ? e : +e, s) : u
}, s.friction = function(e) {
return arguments.length ? (p = +e, s) : p
}, s.charge = function(e) {
return arguments.length ? (f = "function" == typeof e ? e : +e, s) : f
}, s.chargeDistance = function(e) {
return arguments.length ? (m = e * e, s) : Math.sqrt(m)
}, s.gravity = function(e) {
return arguments.length ? (h = +e, s) : h
}, s.theta = function(e) {
return arguments.length ? (g = e * e, s) : Math.sqrt(g)
}, s.alpha = function(e) {
return arguments.length ? (e = +e, r ? r = e > 0 ? e : 0 : e > 0 && (l.start({
type: "start",
alpha: r = e
}), oo.timer(s.tick)), s) : r
}, s.start = function() {
function e(e, r) {
if (!i) {
for (i = new Array(l), s = 0; l > s; ++s) i[s] = [];
for (s = 0; p > s; ++s) {
var a = y[s];
i[a.source.index].push(a.target), i[a.target.index].push(a.source)
}
}
for (var n, o = i[t], s = -1, c = o.length; ++s < c;)
if (!isNaN(n = o[s][e])) return n;
return Math.random() * r
}
var t, i, r, l = _.length,
p = y.length,
m = c[0],
h = c[1];
for (t = 0; l > t; ++t)(r = _[t]).index = t, r.weight = 0;
for (t = 0; p > t; ++t) r = y[t], "number" == typeof r.source && (r.source = _[r.source]), "number" == typeof r.target && (r.target = _[r.target]), ++r.source.weight, ++r.target.weight;
for (t = 0; l > t; ++t) r = _[t], isNaN(r.x) && (r.x = e("x", m)), isNaN(r.y) && (r.y = e("y", h)), isNaN(r.px) && (r.px = r.x), isNaN(r.py) && (r.py = r.y);
if (a = [], "function" == typeof d)
for (t = 0; p > t; ++t) a[t] = +d.call(this, y[t], t);
else
for (t = 0; p > t; ++t) a[t] = d;
if (n = [], "function" == typeof u)
for (t = 0; p > t; ++t) n[t] = +u.call(this, y[t], t);
else
for (t = 0; p > t; ++t) n[t] = u;
if (o = [], "function" == typeof f)
for (t = 0; l > t; ++t) o[t] = +f.call(this, _[t], t);
else
for (t = 0; l > t; ++t) o[t] = f;
return s.resume()
}, s.resume = function() {
return s.alpha(.1)
}, s.stop = function() {
return s.alpha(0)
}, s.drag = function() {
return i || (i = oo.behavior.drag().origin(M).on("dragstart.force", $r).on("drag.force", t).on("dragend.force", qr)), arguments.length ? void this.on("mouseover.force", Kr).on("mouseout.force", ea).call(i) : i
}, oo.rebind(s, l, "on")
};
var _l = 20,
yl = 1,
bl = 1 / 0;
oo.layout.hierarchy = function() {
function e(a) {
var n, o = [a],
s = [];
for (a.depth = 0; null != (n = o.pop());)
if (s.push(n), (c = i.call(e, n, n.depth)) && (l = c.length)) {
for (var l, c, p; --l >= 0;) o.push(p = c[l]), p.parent = n, p.depth = n.depth + 1;
r && (n.value = 0), n.children = c
} else r && (n.value = +r.call(e, n, n.depth) || 0), delete n.children;
return aa(a, function(e) {
var i, a;
t && (i = e.children) && i.sort(t), r && (a = e.parent) && (a.value += e.value)
}), s
}
var t = sa,
i = na,
r = oa;
return e.sort = function(i) {
return arguments.length ? (t = i, e) : t
}, e.children = function(t) {
return arguments.length ? (i = t, e) : i
}, e.value = function(t) {
return arguments.length ? (r = t, e) : r
}, e.revalue = function(t) {
return r && (ra(t, function(e) {
e.children && (e.value = 0)
}), aa(t, function(t) {
var i;
t.children || (t.value = +r.call(e, t, t.depth) || 0), (i = t.parent) && (i.value += t.value)
})), t
}, e
}, oo.layout.partition = function() {
function e(t, i, r, a) {
var n = t.children;
if (t.x = i, t.y = t.depth * a, t.dx = r, t.dy = a, n && (o = n.length)) {
var o, s, l, c = -1;
for (r = t.value ? r / t.value : 0; ++c < o;) e(s = n[c], i, l = s.value * r, a), i += l
}
}
function t(e) {
var i = e.children,
r = 0;
if (i && (a = i.length))
for (var a, n = -1; ++n < a;) r = Math.max(r, t(i[n]));
return 1 + r
}
function i(i, n) {
var o = r.call(this, i, n);
return e(o[0], 0, a[0], a[1] / t(o[0])), o
}
var r = oo.layout.hierarchy(),
a = [1, 1];
return i.size = function(e) {
return arguments.length ? (a = e, i) : a
}, ia(i, r)
}, oo.layout.pie = function() {
function e(o) {
var s, l = o.length,
c = o.map(function(i, r) {
return +t.call(e, i, r)
}),
p = +("function" == typeof r ? r.apply(this, arguments) : r),
d = ("function" == typeof a ? a.apply(this, arguments) : a) - p,
u = Math.min(Math.abs(d) / l, +("function" == typeof n ? n.apply(this, arguments) : n)),
f = u * (0 > d ? -1 : 1),
m = (d - l * f) / oo.sum(c),
h = oo.range(l),
g = [];
return null != i && h.sort(i === vl ? function(e, t) {
return c[t] - c[e]
} : function(e, t) {
return i(o[e], o[t])
}), h.forEach(function(e) {
g[e] = {
data: o[e],
value: s = c[e],
startAngle: p,
endAngle: p += s * m + f,
padAngle: u
}
}), g
}
var t = Number,
i = vl,
r = 0,
a = Zo,
n = 0;
return e.value = function(i) {
return arguments.length ? (t = i, e) : t
}, e.sort = function(t) {
return arguments.length ? (i = t, e) : i
}, e.startAngle = function(t) {
return arguments.length ? (r = t, e) : r
}, e.endAngle = function(t) {
return arguments.length ? (a = t, e) : a
}, e.padAngle = function(t) {
return arguments.length ? (n = t, e) : n
}, e
};
var vl = {};
oo.layout.stack = function() {
function e(s, l) {
if (!(u = s.length)) return s;
var c = s.map(function(i, r) {
return t.call(e, i, r)
}),
p = c.map(function(t) {
return t.map(function(t, i) {
return [n.call(e, t, i), o.call(e, t, i)]
})
}),
d = i.call(e, p, l);
c = oo.permute(c, d), p = oo.permute(p, d);
var u, f, m, h, g = r.call(e, p, l),
_ = c[0].length;
for (m = 0; _ > m; ++m)
for (a.call(e, c[0][m], h = g[m], p[0][m][1]), f = 1; u > f; ++f) a.call(e, c[f][m], h += p[f - 1][m][1], p[f][m][1]);
return s
}
var t = M,
i = ua,
r = fa,
a = da,
n = ca,
o = pa;
return e.values = function(i) {
return arguments.length ? (t = i, e) : t
}, e.order = function(t) {
return arguments.length ? (i = "function" == typeof t ? t : xl.get(t) || ua, e) : i
}, e.offset = function(t) {
return arguments.length ? (r = "function" == typeof t ? t : wl.get(t) || fa, e) : r
}, e.x = function(t) {
return arguments.length ? (n = t, e) : n
}, e.y = function(t) {
return arguments.length ? (o = t, e) : o
}, e.out = function(t) {
return arguments.length ? (a = t, e) : a
}, e
};
var xl = oo.map({
"inside-out": function(e) {
var t, i, r = e.length,
a = e.map(ma),
n = e.map(ha),
o = oo.range(r).sort(function(e, t) {
return a[e] - a[t]
}),
s = 0,
l = 0,
c = [],
p = [];
for (t = 0; r > t; ++t) i = o[t], l > s ? (s += n[i], c.push(i)) : (l += n[i], p.push(i));
return p.reverse().concat(c)
},
reverse: function(e) {
return oo.range(e.length).reverse()
},
"default": ua
}),
wl = oo.map({
silhouette: function(e) {
var t, i, r, a = e.length,
n = e[0].length,
o = [],
s = 0,
l = [];
for (i = 0; n > i; ++i) {
for (t = 0, r = 0; a > t; t++) r += e[t][i][1];
r > s && (s = r), o.push(r)
}
for (i = 0; n > i; ++i) l[i] = (s - o[i]) / 2;
return l
},
wiggle: function(e) {
var t, i, r, a, n, o, s, l, c, p = e.length,
d = e[0],
u = d.length,
f = [];
for (f[0] = l = c = 0, i = 1; u > i; ++i) {
for (t = 0, a = 0; p > t; ++t) a += e[t][i][1];
for (t = 0, n = 0, s = d[i][0] - d[i - 1][0]; p > t; ++t) {
for (r = 0, o = (e[t][i][1] - e[t][i - 1][1]) / (2 * s); t > r; ++r) o += (e[r][i][1] - e[r][i - 1][1]) / s;
n += o * e[t][i][1]
}
f[i] = l -= a ? n / a * s : 0, c > l && (c = l)
}
for (i = 0; u > i; ++i) f[i] -= c;
return f
},
expand: function(e) {
var t, i, r, a = e.length,
n = e[0].length,
o = 1 / a,
s = [];
for (i = 0; n > i; ++i) {
for (t = 0, r = 0; a > t; t++) r += e[t][i][1];
if (r)
for (t = 0; a > t; t++) e[t][i][1] /= r;
else
for (t = 0; a > t; t++) e[t][i][1] = o
}
for (i = 0; n > i; ++i) s[i] = 0;
return s
},
zero: fa
});
oo.layout.histogram = function() {
function e(e, n) {
for (var o, s, l = [], c = e.map(i, this), p = r.call(this, c, n), d = a.call(this, p, c, n), n = -1, u = c.length, f = d.length - 1, m = t ? 1 : 1 / u; ++n < f;) o = l[n] = [], o.dx = d[n + 1] - (o.x = d[n]), o.y = 0;
if (f > 0)
for (n = -1; ++n < u;) s = c[n], s >= p[0] && s <= p[1] && (o = l[oo.bisect(d, s, 1, f) - 1], o.y += m, o.push(e[n]));
return l
}
var t = !0,
i = Number,
r = ba,
a = _a;
return e.value = function(t) {
return arguments.length ? (i = t, e) : i
}, e.range = function(t) {
return arguments.length ? (r = Ce(t), e) : r
}, e.bins = function(t) {
return arguments.length ? (a = "number" == typeof t ? function(e) {
return ya(e, t)
} : Ce(t), e) : a
}, e.frequency = function(i) {
return arguments.length ? (t = !!i, e) : t
}, e
}, oo.layout.pack = function() {
function e(e, n) {
var o = i.call(this, e, n),
s = o[0],
l = a[0],
c = a[1],
p = null == t ? Math.sqrt : "function" == typeof t ? t : function() {
return t
};
if (s.x = s.y = 0, aa(s, function(e) {
e.r = +p(e.value)
}), aa(s, La), r) {
var d = r * (t ? 1 : Math.max(2 * s.r / l, 2 * s.r / c)) / 2;
aa(s, function(e) {
e.r += d
}), aa(s, La), aa(s, function(e) {
e.r -= d
})
}
return ka(s, l / 2, c / 2, t ? 1 : 1 / Math.max(2 * s.r / l, 2 * s.r / c)), o
}
var t, i = oo.layout.hierarchy().sort(va),
r = 0,
a = [1, 1];
return e.size = function(t) {
return arguments.length ? (a = t, e) : a
}, e.radius = function(i) {
return arguments.length ? (t = null == i || "function" == typeof i ? i : +i, e) : t
}, e.padding = function(t) {
return arguments.length ? (r = +t, e) : r
}, ia(e, i)
}, oo.layout.tree = function() {
function e(e, a) {
var p = o.call(this, e, a),
d = p[0],
u = t(d);
if (aa(u, i), u.parent.m = -u.z, ra(u, r), c) ra(d, n);
else {
var f = d,
m = d,
h = d;
ra(d, function(e) {
e.x < f.x && (f = e), e.x > m.x && (m = e), e.depth > h.depth && (h = e)
});
var g = s(f, m) / 2 - f.x,
_ = l[0] / (m.x + s(m, f) / 2 + g),
y = l[1] / (h.depth || 1);
ra(d, function(e) {
e.x = (e.x + g) * _, e.y = e.depth * y
})
}
return p
}
function t(e) {
for (var t, i = {
A: null,
children: [e]
}, r = [i]; null != (t = r.pop());)
for (var a, n = t.children, o = 0, s = n.length; s > o; ++o) r.push((n[o] = a = {
_: n[o],
parent: t,
children: (a = n[o].children) && a.slice() || [],
A: null,
a: null,
z: 0,
m: 0,
c: 0,
s: 0,
t: null,
i: o
}).a = a);
return i.children[0]
}
function i(e) {
var t = e.children,
i = e.parent.children,
r = e.i ? i[e.i - 1] : null;
if (t.length) {
Ta(e);
var n = (t[0].z + t[t.length - 1].z) / 2;
r ? (e.z = r.z + s(e._, r._), e.m = e.z - n) : e.z = n
} else r && (e.z = r.z + s(e._, r._));
e.parent.A = a(e, r, e.parent.A || i[0])
}
function r(e) {
e._.x = e.z + e.parent.m, e.m += e.parent.m
}
function a(e, t, i) {
if (t) {
for (var r, a = e, n = e, o = t, l = a.parent.children[0], c = a.m, p = n.m, d = o.m, u = l.m; o = Ca(o), a = Sa(a), o && a;) l = Sa(l), n = Ca(n), n.a = e, r = o.z + d - a.z - c + s(o._, a._), r > 0 && (za(Ea(o, e, i), e, r), c += r, p += r), d += o.m, c += a.m, u += l.m, p += n.m;
o && !Ca(n) && (n.t = o, n.m += d - p), a && !Sa(l) && (l.t = a, l.m += c - u, i = e)
}
return i
}
function n(e) {
e.x *= l[0], e.y = e.depth * l[1]
}
var o = oo.layout.hierarchy().sort(null).value(null),
s = Da,
l = [1, 1],
c = null;
return e.separation = function(t) {
return arguments.length ? (s = t, e) : s
}, e.size = function(t) {
return arguments.length ? (c = null == (l = t) ? n : null, e) : c ? null : l
}, e.nodeSize = function(t) {
return arguments.length ? (c = null == (l = t) ? null : n, e) : c ? l : null
}, ia(e, o)
}, oo.layout.cluster = function() {
function e(e, n) {
var o, s = t.call(this, e, n),
l = s[0],
c = 0;
aa(l, function(e) {
var t = e.children;
t && t.length ? (e.x = Pa(t), e.y = Aa(t)) : (e.x = o ? c += i(e, o) : 0, e.y = 0, o = e)
});
var p = Oa(l),
d = Za(l),
u = p.x - i(p, d) / 2,
f = d.x + i(d, p) / 2;
return aa(l, a ? function(e) {
e.x = (e.x - l.x) * r[0], e.y = (l.y - e.y) * r[1]
} : function(e) {
e.x = (e.x - u) / (f - u) * r[0], e.y = (1 - (l.y ? e.y / l.y : 1)) * r[1]
}), s
}
var t = oo.layout.hierarchy().sort(null).value(null),
i = Da,
r = [1, 1],
a = !1;
return e.separation = function(t) {
return arguments.length ? (i = t, e) : i
}, e.size = function(t) {
return arguments.length ? (a = null == (r = t), e) : a ? null : r
}, e.nodeSize = function(t) {
return arguments.length ? (a = null != (r = t), e) : a ? r : null
}, ia(e, t)
}, oo.layout.treemap = function() {
function e(e, t) {
for (var i, r, a = -1, n = e.length; ++a < n;) r = (i = e[a]).value * (0 > t ? 0 : t), i.area = isNaN(r) || 0 >= r ? 0 : r
}
function t(i) {
var n = i.children;
if (n && n.length) {
var o, s, l, c = d(i),
p = [],
u = n.slice(),
m = 1 / 0,
h = "slice" === f ? c.dx : "dice" === f ? c.dy : "slice-dice" === f ? 1 & i.depth ? c.dy : c.dx : Math.min(c.dx, c.dy);
for (e(u, c.dx * c.dy / i.value), p.area = 0;
(l = u.length) > 0;) p.push(o = u[l - 1]), p.area += o.area, "squarify" !== f || (s = r(p, h)) <= m ? (u.pop(), m = s) : (p.area -= p.pop().area, a(p, h, c, !1), h = Math.min(c.dx, c.dy), p.length = p.area = 0, m = 1 / 0);
p.length && (a(p, h, c, !0), p.length = p.area = 0), n.forEach(t)
}
}
function i(t) {
var r = t.children;
if (r && r.length) {
var n, o = d(t),
s = r.slice(),
l = [];
for (e(s, o.dx * o.dy / t.value), l.area = 0; n = s.pop();) l.push(n), l.area += n.area, null != n.z && (a(l, n.z ? o.dx : o.dy, o, !s.length), l.length = l.area = 0);
r.forEach(i)
}
}
function r(e, t) {
for (var i, r = e.area, a = 0, n = 1 / 0, o = -1, s = e.length; ++o < s;)(i = e[o].area) && (n > i && (n = i), i > a && (a = i));
return r *= r, t *= t, r ? Math.max(t * a * m / r, r / (t * n * m)) : 1 / 0
}
function a(e, t, i, r) {
var a, n = -1,
o = e.length,
s = i.x,
c = i.y,
p = t ? l(e.area / t) : 0;
if (t == i.dx) {
for ((r || p > i.dy) && (p = i.dy); ++n < o;) a = e[n], a.x = s, a.y = c, a.dy = p, s += a.dx = Math.min(i.x + i.dx - s, p ? l(a.area / p) : 0);
a.z = !0, a.dx += i.x + i.dx - s, i.y += p, i.dy -= p
} else {
for ((r || p > i.dx) && (p = i.dx); ++n < o;) a = e[n], a.x = s, a.y = c, a.dx = p, c += a.dy = Math.min(i.y + i.dy - c, p ? l(a.area / p) : 0);
a.z = !1, a.dy += i.y + i.dy - c, i.x += p, i.dx -= p
}
}
function n(r) {
var a = o || s(r),
n = a[0];
return n.x = 0, n.y = 0, n.dx = c[0], n.dy = c[1], o && s.revalue(n), e([n], n.dx * n.dy / n.value), (o ? i : t)(n), u && (o = a), a
}
var o, s = oo.layout.hierarchy(),
l = Math.round,
c = [1, 1],
p = null,
d = Ha,
u = !1,
f = "squarify",
m = .5 * (1 + Math.sqrt(5));
return n.size = function(e) {
return arguments.length ? (c = e, n) : c
}, n.padding = function(e) {
function t(t) {
var i = e.call(n, t, t.depth);
return null == i ? Ha(t) : Ua(t, "number" == typeof i ? [i, i, i, i] : i)
}
function i(t) {
return Ua(t, e)
}
if (!arguments.length) return p;
var r;
return d = null == (p = e) ? Ha : "function" == (r = typeof e) ? t : "number" === r ? (e = [e, e, e, e], i) : i, n
}, n.round = function(e) {
return arguments.length ? (l = e ? Math.round : Number, n) : l != Number
}, n.sticky = function(e) {
return arguments.length ? (u = e, o = null, n) : u
}, n.ratio = function(e) {
return arguments.length ? (m = e, n) : m
}, n.mode = function(e) {
return arguments.length ? (f = e + "", n) : f
}, ia(n, s)
}, oo.random = {
normal: function(e, t) {
var i = arguments.length;
return 2 > i && (t = 1), 1 > i && (e = 0),
function() {
var i, r, a;
do i = 2 * Math.random() - 1, r = 2 * Math.random() - 1, a = i * i + r * r; while (!a || a > 1);
return e + t * i * Math.sqrt(-2 * Math.log(a) / a)
}
},
logNormal: function() {
var e = oo.random.normal.apply(oo, arguments);
return function() {
return Math.exp(e())
}
},
bates: function(e) {
var t = oo.random.irwinHall(e);
return function() {
return t() / e
}
},
irwinHall: function(e) {
return function() {
for (var t = 0, i = 0; e > i; i++) t += Math.random();
return t
}
}
}, oo.scale = {};
var Ml = {
floor: M,
ceil: M
};
oo.scale.linear = function() {
return Wa([0, 1], [0, 1], wr, !1)
};
var Ll = {
s: 1,
g: 1,
p: 1,
r: 1,
e: 1
};
oo.scale.log = function() {
return tn(oo.scale.linear().domain([0, 1]), 10, !0, [1, 10])
};
var jl = oo.format(".0e"),
Il = {
floor: function(e) {
return -Math.ceil(-e)
},
ceil: function(e) {
return -Math.floor(-e)
}
};
oo.scale.pow = function() {
return rn(oo.scale.linear(), 1, [0, 1])
}, oo.scale.sqrt = function() {
return oo.scale.pow().exponent(.5)
}, oo.scale.ordinal = function() {
return nn([], {
t: "range",
a: [
[]
]
})
}, oo.scale.category10 = function() {
return oo.scale.ordinal().range(kl)
}, oo.scale.category20 = function() {
return oo.scale.ordinal().range(Nl)
}, oo.scale.category20b = function() {
return oo.scale.ordinal().range(Dl)
}, oo.scale.category20c = function() {
return oo.scale.ordinal().range(Sl)
};
var kl = [2062260, 16744206, 2924588, 14034728, 9725885, 9197131, 14907330, 8355711, 12369186, 1556175].map(Le),
Nl = [2062260, 11454440, 16744206, 16759672, 2924588, 10018698, 14034728, 16750742, 9725885, 12955861, 9197131, 12885140, 14907330, 16234194, 8355711, 13092807, 12369186, 14408589, 1556175, 10410725].map(Le),
Dl = [3750777, 5395619, 7040719, 10264286, 6519097, 9216594, 11915115, 13556636, 9202993, 12426809, 15186514, 15190932, 8666169, 11356490, 14049643, 15177372, 8077683, 10834324, 13528509, 14589654].map(Le),
Sl = [3244733, 7057110, 10406625, 13032431, 15095053, 16616764, 16625259, 16634018, 3253076, 7652470, 10607003, 13101504, 7695281, 10394312, 12369372, 14342891, 6513507, 9868950, 12434877, 14277081].map(Le);
oo.scale.quantile = function() {
return on([], [])
}, oo.scale.quantize = function() {
return sn(0, 1, [0, 1])
}, oo.scale.threshold = function() {
return ln([.5], [0, 1])
}, oo.scale.identity = function() {
return cn([0, 1])
}, oo.svg = {}, oo.svg.arc = function() {
function e() {
var e = Math.max(0, +i.apply(this, arguments)),
c = Math.max(0, +r.apply(this, arguments)),
p = o.apply(this, arguments) - Uo,
d = s.apply(this, arguments) - Uo,
u = Math.abs(d - p),
f = p > d ? 0 : 1;
if (e > c && (m = c, c = e, e = m), u >= Ho) return t(c, f) + (e ? t(e, 1 - f) : "") + "Z";
var m, h, g, _, y, b, v, x, w, M, L, j, I = 0,
k = 0,
N = [];
if ((_ = (+l.apply(this, arguments) || 0) / 2) && (g = n === Cl ? Math.sqrt(e * e + c * c) : +n.apply(this, arguments), f || (k *= -1), c && (k = oe(g / c * Math.sin(_))), e && (I = oe(g / e * Math.sin(_)))), c) {
y = c * Math.cos(p + k), b = c * Math.sin(p + k), v = c * Math.cos(d - k), x = c * Math.sin(d - k);
var D = Math.abs(d - p - 2 * k) <= Oo ? 0 : 1;
if (k && gn(y, b, v, x) === f ^ D) {
var S = (p + d) / 2;
y = c * Math.cos(S), b = c * Math.sin(S), v = x = null
}
} else y = b = 0;
if (e) {
w = e * Math.cos(d - I), M = e * Math.sin(d - I), L = e * Math.cos(p + I), j = e * Math.sin(p + I);
var C = Math.abs(p - d + 2 * I) <= Oo ? 0 : 1;
if (I && gn(w, M, L, j) === 1 - f ^ C) {
var z = (p + d) / 2;
w = e * Math.cos(z), M = e * Math.sin(z), L = j = null
}
} else w = M = 0;
if ((m = Math.min(Math.abs(c - e) / 2, +a.apply(this, arguments))) > .001) {
h = c > e ^ f ? 0 : 1;
var T = null == L ? [w, M] : null == v ? [y, b] : Oi([y, b], [L, j], [v, x], [w, M]),
E = y - T[0],
A = b - T[1],
P = v - T[0],
O = x - T[1],
Z = 1 / Math.sin(Math.acos((E * P + A * O) / (Math.sqrt(E * E + A * A) * Math.sqrt(P * P + O * O))) / 2),
H = Math.sqrt(T[0] * T[0] + T[1] * T[1]);
if (null != v) {
var U = Math.min(m, (c - H) / (Z + 1)),
G = _n(null == L ? [w, M] : [L, j], [y, b], c, U, f),
B = _n([v, x], [w, M], c, U, f);
m === U ? N.push("M", G[0], "A", U, ",", U, " 0 0,", h, " ", G[1], "A", c, ",", c, " 0 ", 1 - f ^ gn(G[1][0], G[1][1], B[1][0], B[1][1]), ",", f, " ", B[1], "A", U, ",", U, " 0 0,", h, " ", B[0]) : N.push("M", G[0], "A", U, ",", U, " 0 1,", h, " ", B[0])
} else N.push("M", y, ",", b);
if (null != L) {
var R = Math.min(m, (e - H) / (Z - 1)),
Q = _n([y, b], [L, j], e, -R, f),
V = _n([w, M], null == v ? [y, b] : [v, x], e, -R, f);
m === R ? N.push("L", V[0], "A", R, ",", R, " 0 0,", h, " ", V[1], "A", e, ",", e, " 0 ", f ^ gn(V[1][0], V[1][1], Q[1][0], Q[1][1]), ",", 1 - f, " ", Q[1], "A", R, ",", R, " 0 0,", h, " ", Q[0]) : N.push("L", V[0], "A", R, ",", R, " 0 0,", h, " ", Q[0])
} else N.push("L", w, ",", M)
} else N.push("M", y, ",", b), null != v && N.push("A", c, ",", c, " 0 ", D, ",", f, " ", v, ",", x), N.push("L", w, ",", M), null != L && N.push("A", e, ",", e, " 0 ", C, ",", 1 - f, " ", L, ",", j);
return N.push("Z"), N.join("")
}
function t(e, t) {
return "M0," + e + "A" + e + "," + e + " 0 1," + t + " 0," + -e + "A" + e + "," + e + " 0 1," + t + " 0," + e
}
var i = dn,
r = un,
a = pn,
n = Cl,
o = fn,
s = mn,
l = hn;
return e.innerRadius = function(t) {
return arguments.length ? (i = Ce(t), e) : i
}, e.outerRadius = function(t) {
return arguments.length ? (r = Ce(t), e) : r
}, e.cornerRadius = function(t) {
return arguments.length ? (a = Ce(t), e) : a
}, e.padRadius = function(t) {
return arguments.length ? (n = t == Cl ? Cl : Ce(t), e) : n
}, e.startAngle = function(t) {
return arguments.length ? (o = Ce(t), e) : o
}, e.endAngle = function(t) {
return arguments.length ? (s = Ce(t), e) : s
}, e.padAngle = function(t) {
return arguments.length ? (l = Ce(t), e) : l
}, e.centroid = function() {
var e = (+i.apply(this, arguments) + +r.apply(this, arguments)) / 2,
t = (+o.apply(this, arguments) + +s.apply(this, arguments)) / 2 - Uo;
return [Math.cos(t) * e, Math.sin(t) * e]
}, e
};
var Cl = "auto";
oo.svg.line = function() {
return yn(M)
};
var zl = oo.map({
linear: bn,
"linear-closed": vn,
step: xn,
"step-before": wn,
"step-after": Mn,
basis: Dn,
"basis-open": Sn,
"basis-closed": Cn,
bundle: zn,
cardinal: In,
"cardinal-open": Ln,
"cardinal-closed": jn,
monotone: Zn
});
zl.forEach(function(e, t) {
t.key = e, t.closed = /-closed$/.test(e)
});
var Tl = [0, 2 / 3, 1 / 3, 0],
El = [0, 1 / 3, 2 / 3, 0],
Al = [0, 1 / 6, 2 / 3, 1 / 6];
oo.svg.line.radial = function() {
var e = yn(Hn);
return e.radius = e.x, delete e.x, e.angle = e.y, delete e.y, e
}, wn.reverse = Mn, Mn.reverse = wn, oo.svg.area = function() {
return Un(M)
}, oo.svg.area.radial = function() {
var e = Un(Hn);
return e.radius = e.x, delete e.x, e.innerRadius = e.x0, delete e.x0, e.outerRadius = e.x1, delete e.x1, e.angle = e.y, delete e.y, e.startAngle = e.y0, delete e.y0, e.endAngle = e.y1, delete e.y1, e
}, oo.svg.chord = function() {
function e(e, s) {
var l = t(this, n, e, s),
c = t(this, o, e, s);
return "M" + l.p0 + r(l.r, l.p1, l.a1 - l.a0) + (i(l, c) ? a(l.r, l.p1, l.r, l.p0) : a(l.r, l.p1, c.r, c.p0) + r(c.r, c.p1, c.a1 - c.a0) + a(c.r, c.p1, l.r, l.p0)) + "Z"
}
function t(e, t, i, r) {
var a = t.call(e, i, r),
n = s.call(e, a, r),
o = l.call(e, a, r) - Uo,
p = c.call(e, a, r) - Uo;
return {
r: n,
a0: o,
a1: p,
p0: [n * Math.cos(o), n * Math.sin(o)],
p1: [n * Math.cos(p), n * Math.sin(p)]
}
}
function i(e, t) {
return e.a0 == t.a0 && e.a1 == t.a1
}
function r(e, t, i) {
return "A" + e + "," + e + " 0 " + +(i > Oo) + ",1 " + t
}
function a(e, t, i, r) {
return "Q 0,0 " + r
}
var n = wi,
o = Mi,
s = Gn,
l = fn,
c = mn;
return e.radius = function(t) {
return arguments.length ? (s = Ce(t), e) : s
}, e.source = function(t) {
return arguments.length ? (n = Ce(t), e) : n
}, e.target = function(t) {
return arguments.length ? (o = Ce(t), e) : o
}, e.startAngle = function(t) {
return arguments.length ? (l = Ce(t), e) : l
}, e.endAngle = function(t) {
return arguments.length ? (c = Ce(t), e) : c
}, e
}, oo.svg.diagonal = function() {
function e(e, a) {
var n = t.call(this, e, a),
o = i.call(this, e, a),
s = (n.y + o.y) / 2,
l = [n, {
x: n.x,
y: s
}, {
x: o.x,
y: s
}, o];
return l = l.map(r), "M" + l[0] + "C" + l[1] + " " + l[2] + " " + l[3]
}
var t = wi,
i = Mi,
r = Bn;
return e.source = function(i) {
return arguments.length ? (t = Ce(i), e) : t
}, e.target = function(t) {
return arguments.length ? (i = Ce(t), e) : i
}, e.projection = function(t) {
return arguments.length ? (r = t, e) : r
}, e
}, oo.svg.diagonal.radial = function() {
var e = oo.svg.diagonal(),
t = Bn,
i = e.projection;
return e.projection = function(e) {
return arguments.length ? i(Rn(t = e)) : t
}, e
}, oo.svg.symbol = function() {
function e(e, r) {
return (Pl.get(t.call(this, e, r)) || Fn)(i.call(this, e, r))
}
var t = Vn,
i = Qn;
return e.type = function(i) {
return arguments.length ? (t = Ce(i), e) : t
}, e.size = function(t) {
return arguments.length ? (i = Ce(t), e) : i
}, e
};
var Pl = oo.map({
circle: Fn,
cross: function(e) {
var t = Math.sqrt(e / 5) / 2;
return "M" + -3 * t + "," + -t + "H" + -t + "V" + -3 * t + "H" + t + "V" + -t + "H" + 3 * t + "V" + t + "H" + t + "V" + 3 * t + "H" + -t + "V" + t + "H" + -3 * t + "Z"
},
diamond: function(e) {
var t = Math.sqrt(e / (2 * Zl)),
i = t * Zl;
return "M0," + -t + "L" + i + ",0 0," + t + " " + -i + ",0Z"
},
square: function(e) {
var t = Math.sqrt(e) / 2;
return "M" + -t + "," + -t + "L" + t + "," + -t + " " + t + "," + t + " " + -t + "," + t + "Z"
},
"triangle-down": function(e) {
var t = Math.sqrt(e / Ol),
i = t * Ol / 2;
return "M0," + i + "L" + t + "," + -i + " " + -t + "," + -i + "Z"
},
"triangle-up": function(e) {
var t = Math.sqrt(e / Ol),
i = t * Ol / 2;
return "M0," + -i + "L" + t + "," + i + " " + -t + "," + i + "Z"
}
});
oo.svg.symbolTypes = Pl.keys();
var Ol = Math.sqrt(3),
Zl = Math.tan(30 * Go);
No.transition = function(e) {
for (var t, i, r = Hl || ++Rl, a = $n(e), n = [], o = Ul || {
time: Date.now(),
ease: Dr,
delay: 0,
duration: 250
}, s = -1, l = this.length; ++s < l;) {
n.push(t = []);
for (var c = this[s], p = -1, d = c.length; ++p < d;)(i = c[p]) && qn(i, p, a, r, o), t.push(i)
}
return Yn(n, a, r)
}, No.interrupt = function(e) {
return this.each(null == e ? Gl : Wn($n(e)))
};
var Hl, Ul, Gl = Wn($n()),
Bl = [],
Rl = 0;
Bl.call = No.call, Bl.empty = No.empty, Bl.node = No.node, Bl.size = No.size, oo.transition = function(e, t) {
return e && e.transition ? Hl ? e.transition(t) : e : oo.selection().transition(e)
}, oo.transition.prototype = Bl, Bl.select = function(e) {
var t, i, r, a = this.id,
n = this.namespace,
o = [];
e = T(e);
for (var s = -1, l = this.length; ++s < l;) {
o.push(t = []);
for (var c = this[s], p = -1, d = c.length; ++p < d;)(r = c[p]) && (i = e.call(r, r.__data__, p, s)) ? ("__data__" in r && (i.__data__ = r.__data__), qn(i, p, n, a, r[n][a]), t.push(i)) : t.push(null)
}
return Yn(o, n, a)
}, Bl.selectAll = function(e) {
var t, i, r, a, n, o = this.id,
s = this.namespace,
l = [];
e = E(e);
for (var c = -1, p = this.length; ++c < p;)
for (var d = this[c], u = -1, f = d.length; ++u < f;)
if (r = d[u]) {
n = r[s][o], i = e.call(r, r.__data__, u, c), l.push(t = []);
for (var m = -1, h = i.length; ++m < h;)(a = i[m]) && qn(a, m, s, o, n), t.push(a)
}
return Yn(l, s, o)
}, Bl.filter = function(e) {
var t, i, r, a = [];
"function" != typeof e && (e = F(e));
for (var n = 0, o = this.length; o > n; n++) {
a.push(t = []);
for (var i = this[n], s = 0, l = i.length; l > s; s++)(r = i[s]) && e.call(r, r.__data__, s, n) && t.push(r)
}
return Yn(a, this.namespace, this.id)
}, Bl.tween = function(e, t) {
var i = this.id,
r = this.namespace;
return arguments.length < 2 ? this.node()[r][i].tween.get(e) : Y(this, null == t ? function(t) {
t[r][i].tween.remove(e)
} : function(a) {
a[r][i].tween.set(e, t)
})
}, Bl.attr = function(e, t) {
function i() {
this.removeAttribute(s)
}
function r() {
this.removeAttributeNS(s.space, s.local)
}
function a(e) {
return null == e ? i : (e += "", function() {
var t, i = this.getAttribute(s);
return i !== e && (t = o(i, e), function(e) {
this.setAttribute(s, t(e))
})
})
}
function n(e) {
return null == e ? r : (e += "", function() {
var t, i = this.getAttributeNS(s.space, s.local);
return i !== e && (t = o(i, e), function(e) {
this.setAttributeNS(s.space, s.local, t(e))
})
})
}
if (arguments.length < 2) {
for (t in e) this.attr(t, e[t]);
return this
}
var o = "transform" == e ? Vr : wr,
s = oo.ns.qualify(e);
return Jn(this, "attr." + e, t, s.local ? n : a)
}, Bl.attrTween = function(e, t) {
function i(e, i) {
var r = t.call(this, e, i, this.getAttribute(a));
return r && function(e) {
this.setAttribute(a, r(e))
}
}
function r(e, i) {
var r = t.call(this, e, i, this.getAttributeNS(a.space, a.local));
return r && function(e) {
this.setAttributeNS(a.space, a.local, r(e))
}
}
var a = oo.ns.qualify(e);
return this.tween("attr." + e, a.local ? r : i)
}, Bl.style = function(e, t, i) {
function r() {
this.style.removeProperty(e)
}
function a(t) {
return null == t ? r : (t += "", function() {
var r, a = o(this).getComputedStyle(this, null).getPropertyValue(e);
return a !== t && (r = wr(a, t), function(t) {
this.style.setProperty(e, r(t), i)
})
})
}
var n = arguments.length;
if (3 > n) {
if ("string" != typeof e) {
2 > n && (t = "");
for (i in e) this.style(i, e[i], t);
return this
}
i = ""
}
return Jn(this, "style." + e, t, a)
}, Bl.styleTween = function(e, t, i) {
function r(r, a) {
var n = t.call(this, r, a, o(this).getComputedStyle(this, null).getPropertyValue(e));
return n && function(t) {
this.style.setProperty(e, n(t), i)
}
}
return arguments.length < 3 && (i = ""), this.tween("style." + e, r)
}, Bl.text = function(e) {
return Jn(this, "text", e, Xn)
}, Bl.remove = function() {
var e = this.namespace;
return this.each("end.transition", function() {
var t;
this[e].count < 2 && (t = this.parentNode) && t.removeChild(this)
})
}, Bl.ease = function(e) {
var t = this.id,
i = this.namespace;
return arguments.length < 1 ? this.node()[i][t].ease : ("function" != typeof e && (e = oo.ease.apply(oo, arguments)), Y(this, function(r) {
r[i][t].ease = e
}))
}, Bl.delay = function(e) {
var t = this.id,
i = this.namespace;
return arguments.length < 1 ? this.node()[i][t].delay : Y(this, "function" == typeof e ? function(r, a, n) {
r[i][t].delay = +e.call(r, r.__data__, a, n)
} : (e = +e, function(r) {
r[i][t].delay = e
}))
}, Bl.duration = function(e) {
var t = this.id,
i = this.namespace;
return arguments.length < 1 ? this.node()[i][t].duration : Y(this, "function" == typeof e ? function(r, a, n) {
r[i][t].duration = Math.max(1, e.call(r, r.__data__, a, n))
} : (e = Math.max(1, e), function(r) {
r[i][t].duration = e
}))
}, Bl.each = function(e, t) {
var i = this.id,
r = this.namespace;
if (arguments.length < 2) {
var a = Ul,
n = Hl;
try {
Hl = i, Y(this, function(t, a, n) {
Ul = t[r][i], e.call(t, t.__data__, a, n)
})
} finally {
Ul = a, Hl = n
}
} else Y(this, function(a) {
var n = a[r][i];
(n.event || (n.event = oo.dispatch("start", "end", "interrupt"))).on(e, t)
});
return this
}, Bl.transition = function() {
for (var e, t, i, r, a = this.id, n = ++Rl, o = this.namespace, s = [], l = 0, c = this.length; c > l; l++) {
s.push(e = []);
for (var t = this[l], p = 0, d = t.length; d > p; p++)(i = t[p]) && (r = i[o][a], qn(i, p, o, n, {
time: r.time,
ease: r.ease,
delay: r.delay + r.duration,
duration: r.duration
})), e.push(i)
}
return Yn(s, o, n)
}, oo.svg.axis = function() {
function e(e) {
e.each(function() {
var e, c = oo.select(this),
p = this.__chart__ || i,
d = this.__chart__ = i.copy(),
u = null == l ? d.ticks ? d.ticks.apply(d, s) : d.domain() : l,
f = null == t ? d.tickFormat ? d.tickFormat.apply(d, s) : M : t,
m = c.selectAll(".tick").data(u, d),
h = m.enter().insert("g", ".domain").attr("class", "tick").style("opacity", Ao),
g = oo.transition(m.exit()).style("opacity", Ao).remove(),
_ = oo.transition(m.order()).style("opacity", 1),
y = Math.max(a, 0) + o,
b = Ba(d),
v = c.selectAll(".domain").data([0]),
x = (v.enter().append("path").attr("class", "domain"), oo.transition(v));
h.append("line"), h.append("text");
var w, L, j, I, k = h.select("line"),
N = _.select("line"),
D = m.select("text").text(f),
S = h.select("text"),
C = _.select("text"),
z = "top" === r || "left" === r ? -1 : 1;
if ("bottom" === r || "top" === r ? (e = Kn, w = "x", j = "y", L = "x2", I = "y2", D.attr("dy", 0 > z ? "0em" : ".71em").style("text-anchor", "middle"), x.attr("d", "M" + b[0] + "," + z * n + "V0H" + b[1] + "V" + z * n)) : (e = eo, w = "y", j = "x", L = "y2", I = "x2", D.attr("dy", ".32em").style("text-anchor", 0 > z ? "end" : "start"), x.attr("d", "M" + z * n + "," + b[0] + "H0V" + b[1] + "H" + z * n)), k.attr(I, z * a), S.attr(j, z * y), N.attr(L, 0).attr(I, z * a), C.attr(w, 0).attr(j, z * y), d.rangeBand) {
var T = d,
E = T.rangeBand() / 2;
p = d = function(e) {
return T(e) + E
}
} else p.rangeBand ? p = d : g.call(e, d, p);
h.call(e, p, d), _.call(e, d, d)
})
}
var t, i = oo.scale.linear(),
r = Ql,
a = 6,
n = 6,
o = 3,
s = [10],
l = null;
return e.scale = function(t) {
return arguments.length ? (i = t, e) : i
}, e.orient = function(t) {
return arguments.length ? (r = t in Vl ? t + "" : Ql, e) : r
}, e.ticks = function() {
return arguments.length ? (s = arguments, e) : s
}, e.tickValues = function(t) {
return arguments.length ? (l = t, e) : l
}, e.tickFormat = function(i) {
return arguments.length ? (t = i, e) : t
}, e.tickSize = function(t) {
var i = arguments.length;
return i ? (a = +t, n = +arguments[i - 1], e) : a
}, e.innerTickSize = function(t) {
return arguments.length ? (a = +t, e) : a
}, e.outerTickSize = function(t) {
return arguments.length ? (n = +t, e) : n
}, e.tickPadding = function(t) {
return arguments.length ? (o = +t, e) : o
}, e.tickSubdivide = function() {
return arguments.length && e
}, e
};
var Ql = "bottom",
Vl = {
top: 1,
right: 1,
bottom: 1,
left: 1
};
oo.svg.brush = function() {
function e(n) {
n.each(function() {
var n = oo.select(this).style("pointer-events", "all").style("-webkit-tap-highlight-color", "rgba(0,0,0,0)").on("mousedown.brush", a).on("touchstart.brush", a),
o = n.selectAll(".background").data([0]);
o.enter().append("rect").attr("class", "background").style("visibility", "hidden").style("cursor", "crosshair"), n.selectAll(".extent").data([0]).enter().append("rect").attr("class", "extent").style("cursor", "move");
var s = n.selectAll(".resize").data(h, M);
s.exit().remove(), s.enter().append("g").attr("class", function(e) {
return "resize " + e
}).style("cursor", function(e) {
return Fl[e]
}).append("rect").attr("x", function(e) {
return /[ew]$/.test(e) ? -3 : null
}).attr("y", function(e) {
return /^[ns]/.test(e) ? -3 : null
}).attr("width", 6).attr("height", 6).style("visibility", "hidden"), s.style("display", e.empty() ? "none" : null);
var l, d = oo.transition(n),
u = oo.transition(o);
c && (l = Ba(c), u.attr("x", l[0]).attr("width", l[1] - l[0]), i(d)), p && (l = Ba(p), u.attr("y", l[0]).attr("height", l[1] - l[0]), r(d)), t(d)
})
}
function t(e) {
e.selectAll(".resize").attr("transform", function(e) {
return "translate(" + d[+/e$/.test(e)] + "," + u[+/^s/.test(e)] + ")"
})
}
function i(e) {
e.select(".extent").attr("x", d[0]), e.selectAll(".extent,.n>rect,.s>rect").attr("width", d[1] - d[0])
}
function r(e) {
e.select(".extent").attr("y", u[0]), e.selectAll(".extent,.e>rect,.w>rect").attr("height", u[1] - u[0])
}
function a() {
function a() {
32 == oo.event.keyCode && (N || (b = null, C[0] -= d[1], C[1] -= u[1], N = 2), D())
}
function h() {
32 == oo.event.keyCode && 2 == N && (C[0] += d[1], C[1] += u[1], N = 0, D())
}
function g() {
var e = oo.mouse(x),
a = !1;
v && (e[0] += v[0], e[1] += v[1]), N || (oo.event.altKey ? (b || (b = [(d[0] + d[1]) / 2, (u[0] + u[1]) / 2]), C[0] = d[+(e[0] < b[0])], C[1] = u[+(e[1] < b[1])]) : b = null), I && _(e, c, 0) && (i(L), a = !0), k && _(e, p, 1) && (r(L), a = !0), a && (t(L), M({
type: "brush",
mode: N ? "move" : "resize"
}))
}
function _(e, t, i) {
var r, a, o = Ba(t),
l = o[0],
c = o[1],
p = C[i],
h = i ? u : d,
g = h[1] - h[0];
return N && (l -= p, c -= g + p), r = (i ? m : f) ? Math.max(l, Math.min(c, e[i])) : e[i], N ? a = (r += p) + g : (b && (p = Math.max(l, Math.min(c, 2 * b[i] - r))), r > p ? (a = r, r = p) : a = p), h[0] != r || h[1] != a ? (i ? s = null : n = null, h[0] = r, h[1] = a, !0) : void 0
}
function y() {
g(), L.style("pointer-events", "all").selectAll(".resize").style("display", e.empty() ? "none" : null), oo.select("body").style("cursor", null), z.on("mousemove.brush", null).on("mouseup.brush", null).on("touchmove.brush", null).on("touchend.brush", null).on("keydown.brush", null).on("keyup.brush", null), S(), M({
type: "brushend"
})
}
var b, v, x = this,
w = oo.select(oo.event.target),
M = l.of(x, arguments),
L = oo.select(x),
j = w.datum(),
I = !/^(n|s)$/.test(j) && c,
k = !/^(e|w)$/.test(j) && p,
N = w.classed("extent"),
S = ee(x),
C = oo.mouse(x),
z = oo.select(o(x)).on("keydown.brush", a).on("keyup.brush", h);
if (oo.event.changedTouches ? z.on("touchmove.brush", g).on("touchend.brush", y) : z.on("mousemove.brush", g).on("mouseup.brush", y), L.interrupt().selectAll("*").interrupt(), N) C[0] = d[0] - C[0], C[1] = u[0] - C[1];
else if (j) {
var T = +/w$/.test(j),
E = +/^n/.test(j);
v = [d[1 - T] - C[0], u[1 - E] - C[1]], C[0] = d[T], C[1] = u[E]
} else oo.event.altKey && (b = C.slice());
L.style("pointer-events", "none").selectAll(".resize").style("display", null), oo.select("body").style("cursor", w.style("cursor")), M({
type: "brushstart"
}), g()
}
var n, s, l = C(e, "brushstart", "brush", "brushend"),
c = null,
p = null,
d = [0, 0],
u = [0, 0],
f = !0,
m = !0,
h = Wl[0];
return e.event = function(e) {
e.each(function() {
var e = l.of(this, arguments),
t = {
x: d,
y: u,
i: n,
j: s
},
i = this.__chart__ || t;
this.__chart__ = t, Hl ? oo.select(this).transition().each("start.brush", function() {
n = i.i, s = i.j, d = i.x, u = i.y, e({
type: "brushstart"
})
}).tween("brush:brush", function() {
var i = Mr(d, t.x),
r = Mr(u, t.y);
return n = s = null,
function(a) {
d = t.x = i(a), u = t.y = r(a), e({
type: "brush",
mode: "resize"
})
}
}).each("end.brush", function() {
n = t.i, s = t.j, e({
type: "brush",
mode: "resize"
}), e({
type: "brushend"
})
}) : (e({
type: "brushstart"
}), e({
type: "brush",
mode: "resize"
}), e({
type: "brushend"
}))
})
}, e.x = function(t) {
return arguments.length ? (c = t, h = Wl[!c << 1 | !p], e) : c
}, e.y = function(t) {
return arguments.length ? (p = t, h = Wl[!c << 1 | !p], e) : p
}, e.clamp = function(t) {
return arguments.length ? (c && p ? (f = !!t[0], m = !!t[1]) : c ? f = !!t : p && (m = !!t), e) : c && p ? [f, m] : c ? f : p ? m : null
}, e.extent = function(t) {
var i, r, a, o, l;
return arguments.length ? (c && (i = t[0], r = t[1], p && (i = i[0], r = r[0]), n = [i, r], c.invert && (i = c(i), r = c(r)), i > r && (l = i, i = r, r = l), i == d[0] && r == d[1] || (d = [i, r])), p && (a = t[0], o = t[1], c && (a = a[1], o = o[1]), s = [a, o], p.invert && (a = p(a), o = p(o)), a > o && (l = a, a = o, o = l), a == u[0] && o == u[1] || (u = [a, o])), e) : (c && (n ? (i = n[0], r = n[1]) : (i = d[0], r = d[1], c.invert && (i = c.invert(i), r = c.invert(r)), i > r && (l = i, i = r, r = l))), p && (s ? (a = s[0], o = s[1]) : (a = u[0], o = u[1], p.invert && (a = p.invert(a), o = p.invert(o)), a > o && (l = a, a = o, o = l))), c && p ? [
[i, a],
[r, o]
] : c ? [i, r] : p && [a, o])
}, e.clear = function() {
return e.empty() || (d = [0, 0], u = [0, 0], n = s = null), e
}, e.empty = function() {
return !!c && d[0] == d[1] || !!p && u[0] == u[1]
}, oo.rebind(e, l, "on")
};
var Fl = {
n: "ns-resize",
e: "ew-resize",
s: "ns-resize",
w: "ew-resize",
nw: "nwse-resize",
ne: "nesw-resize",
se: "nwse-resize",
sw: "nesw-resize"
},
Wl = [
["n", "e", "s", "w", "nw", "ne", "se", "sw"],
["e", "w"],
["n", "s"],
[]
],
Yl = fs.format = bs.timeFormat,
Jl = Yl.utc,
Xl = Jl("%Y-%m-%dT%H:%M:%S.%LZ");
Yl.iso = Date.prototype.toISOString && +new Date("2000-01-01T00:00:00.000Z") ? to : Xl, to.parse = function(e) {
var t = new Date(e);
return isNaN(t) ? null : t
}, to.toString = Xl.toString, fs.second = Qe(function(e) {
return new ms(1e3 * Math.floor(e / 1e3))
}, function(e, t) {
e.setTime(e.getTime() + 1e3 * Math.floor(t))
}, function(e) {
return e.getSeconds()
}), fs.seconds = fs.second.range, fs.seconds.utc = fs.second.utc.range, fs.minute = Qe(function(e) {
return new ms(6e4 * Math.floor(e / 6e4))
}, function(e, t) {
e.setTime(e.getTime() + 6e4 * Math.floor(t))
}, function(e) {
return e.getMinutes()
}), fs.minutes = fs.minute.range, fs.minutes.utc = fs.minute.utc.range, fs.hour = Qe(function(e) {
var t = e.getTimezoneOffset() / 60;
return new ms(36e5 * (Math.floor(e / 36e5 - t) + t))
}, function(e, t) {
e.setTime(e.getTime() + 36e5 * Math.floor(t))
}, function(e) {
return e.getHours()
}), fs.hours = fs.hour.range, fs.hours.utc = fs.hour.utc.range, fs.month = Qe(function(e) {
return e = fs.day(e), e.setDate(1), e
}, function(e, t) {
e.setMonth(e.getMonth() + t)
}, function(e) {
return e.getMonth()
}), fs.months = fs.month.range, fs.months.utc = fs.month.utc.range;
var $l = [1e3, 5e3, 15e3, 3e4, 6e4, 3e5, 9e5, 18e5, 36e5, 108e5, 216e5, 432e5, 864e5, 1728e5, 6048e5, 2592e6, 7776e6, 31536e6],
ql = [
[fs.second, 1],
[fs.second, 5],
[fs.second, 15],
[fs.second, 30],
[fs.minute, 1],
[fs.minute, 5],
[fs.minute, 15],
[fs.minute, 30],
[fs.hour, 1],
[fs.hour, 3],
[fs.hour, 6],
[fs.hour, 12],
[fs.day, 1],
[fs.day, 2],
[fs.week, 1],
[fs.month, 1],
[fs.month, 3],
[fs.year, 1]
],
Kl = Yl.multi([
[".%L", function(e) {
return e.getMilliseconds()
}],
[":%S", function(e) {
return e.getSeconds()
}],
["%I:%M", function(e) {
return e.getMinutes()
}],
["%I %p", function(e) {
return e.getHours()
}],
["%a %d", function(e) {
return e.getDay() && 1 != e.getDate()
}],
["%b %d", function(e) {
return 1 != e.getDate()
}],
["%B", function(e) {
return e.getMonth()
}],
["%Y", Tt]
]),
ec = {
range: function(e, t, i) {
return oo.range(Math.ceil(e / i) * i, +t, i).map(ro)
},
floor: M,
ceil: M
};
ql.year = fs.year, fs.scale = function() {
return io(oo.scale.linear(), ql, Kl)
};
var tc = ql.map(function(e) {
return [e[0].utc, e[1]]
}),
ic = Jl.multi([
[".%L", function(e) {
return e.getUTCMilliseconds()
}],
[":%S", function(e) {
return e.getUTCSeconds()
}],
["%I:%M", function(e) {
return e.getUTCMinutes()
}],
["%I %p", function(e) {
return e.getUTCHours()
}],
["%a %d", function(e) {
return e.getUTCDay() && 1 != e.getUTCDate()
}],
["%b %d", function(e) {
return 1 != e.getUTCDate()
}],
["%B", function(e) {
return e.getUTCMonth()
}],
["%Y", Tt]
]);
tc.year = fs.year.utc, fs.scale.utc = function() {
return io(oo.scale.linear(), tc, ic)
}, oo.text = ze(function(e) {
return e.responseText
}), oo.json = function(e, t) {
return Te(e, "application/json", ao, t)
}, oo.html = function(e, t) {
return Te(e, "text/html", no, t)
}, oo.xml = ze(function(e) {
return e.responseXML
}), r = oo, a = "function" == typeof r ? r.call(t, i, t, e) : r, !(void 0 !== a && (e.exports = a)), this.d3 = oo
}()
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = i(1709),
o = r(n),
s = i(117),
l = r(s),
c = function() {
function e() {
a(this, e), this.config = {
xName: "x",
yName: "y",
cssClass: null,
focus: {
enabled: !1,
radius: 5,
text: void 0,
cssClass: void 0
},
interpolate: void 0,
circles: {
hoverable: !1,
enabled: !1,
defaultR: 5,
bigR: 10
},
text: ""
}, this.data = [], this.visible = !0, this.name = null, this.line = null
}
return e.prototype.init = function(e) {
var t = arguments.length <= 1 || void 0 === arguments[1] ? {} : arguments[1];
this.config = l["default"].defaults(t, this.config), this.drawCallback = null, this.name = e
}, e.prototype.getText = function() {
return this.config.text
}, e.prototype.getConfig = function() {
return this.config
}, e.prototype.getName = function() {
return this.name
}, e.prototype.getXName = function() {
return this.config.xName
}, e.prototype.getYName = function() {
return this.config.yName
}, e.prototype.getData = function() {
return this.data
}, e.prototype.setData = function(e) {
this.data = this._prepareData(e)
}, e.prototype.getMinMaxX = function() {
var e = this;
return o["default"].extent(this.data, function(t) {
return t[e.getXName()]
})
}, e.prototype.getMinMaxY = function() {
var e = this;
return o["default"].extent(this.data, function(t) {
return t[e.getYName()]
})
}, e.prototype.setD3Object = function(e) {
this.line = e
}, e.prototype.getSvgObject = function() {
return this.line
}, e.prototype.setDrawCallback = function(e) {
this.drawCallback = e
}, e.prototype.getDrawCallback = function() {
return this.drawCallback
}, e.prototype._prepareData = function(e) {
return e
}, e.prototype.toggleLine = function() {
this.visible = !this.visible
}, e
}();
t["default"] = c, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = i(117),
o = r(n),
s = function() {
function e() {
var t = arguments.length <= 0 || void 0 === arguments[0] ? {} : arguments[0];
a(this, e), this.config = {
baseClass: "tooltip",
titleDateFormat: "dd mmmm yyyy"
}, this.config = o["default"].defaults(t, this.config), this.container = null
}
return e.prototype.setContainer = function(e) {
this.container = e
}, e.prototype.getContainer = function() {
return this.container
}, e.prototype.getBaseClass = function() {
return this.config.baseClass
}, e.prototype.hide = function() {
this.container.transition().duration(250).style("opacity", 0), this.container.transition().delay(250).style("display", "none")
}, e.prototype.show = function(e, t) {
var i = ['
'],
r = !1;
for (var a in e) {
var n = e[a];
if (0 != n) {
var o = new Vue({
data: {
x: n.x,
y: n.y,
text: n.text,
baseClass: this.config.baseClass
}
});
(r || e.city) && "city" !== a || (i.unshift(o.$interpolate('
{{x | date \'' + this.config.titleDateFormat + "'}}
")), r = !0), i.push('
'), i.push(o.$interpolate('{{text}}')), "offer" === a && i.push(o.$interpolate("{{x | date 'd mmm yyyy' | lowerCase}}")), i.push(""), i.push(o.$interpolate(['', "{{{y | thinSpaces}}} ", ''].join(""))), i.push("
"
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var n = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
o = i(145),
s = i(1740),
l = r(s),
c = i(1742),
p = r(c),
d = i(142),
u = r(d),
f = i(532),
m = r(f),
h = i(117),
g = r(h),
_ = function() {
function e() {
a(this, t), this.requestForm = null, this.requestFormSending = !1, this.requestSuccess = !1, this.requestErrorMessage = "", this.countForm = null, this.countFormAttached = !1, this.contactsStorage = null, this.bannerLoaded = !1
}
e.prototype.ready = function() {
this._initCountForm()
}, e.prototype._setDefaultCountData = function(e) {
var t = Number(this.offer.param("params.price")),
i = void 0;
i = t >= 0 && 999999999 >= t ? t : 0;
var r = Math.round(.2 * i);
e.setData({
price: i,
initialFee: r
}, !0)
}, e.prototype._initCountForm = function() {
var e = new p["default"];
e.init(), this.countForm = e, this._setDefaultCountData(e), this.countFormAttached = !0
}, e.prototype._sendToMail = function(e) {
var t = {
offer: {
id: this.offer.getId(),
link: this.offer.getFullUrl(),
region: this.offer.param("params.region.name_ru"),
city: this.offer.param("params.city.name_ru")
},
request: {
email_name: e.email_name || "N1.RU",
phone: this.$options.filters.phoneFormatted(e.phone),
email: "noreply@n1.ru",
price: this.offer.param("params.price")
}
};
return this.$service("Mailer").sendMortageRequest(new u["default"](t))
}, e.prototype._sendToAdmin = function(e) {
var t = {
phone: e.phone
};
e.email_name && (t.name = e.email_name);
var i = e.params || null;
return this._mSubmitLeadRequest("mortgage", t, i)
}, e.prototype._initRequestForm = function() {
var e = this;
this.requestForm || (this.requestForm = new l["default"], this.contactsStorage = new m["default"]({
request: this.$request(),
form: this.requestForm
}), this.contactsStorage.setToForm(), this.requestForm.on("submit", function(t) {
var i = e.countForm.getData();
i.mortgageAmount = e.countForm.getMortgageAmount();
var r = e._mapCountFormToApi(i);
e.contactsStorage.setToStorage(t), e._sendToAdmin(Object.assign({}, t, {
params: r
})).then(function(t) {
e.requestSuccess = !0, e.requestErrorMessage = "", e.$analytics("MORTAGE_REQUEST_SENT")
})["catch"](function(t) {
e.$logError(t), e.requestErrorMessage = "Ошибка сервиса. Попробуйте повторить попозже"
})["finally"](function() {
e.requestFormSending = !1
}), e._sendToMail(g["default"].cloneDeep(t))["catch"](function(t) {
e.$logError(t)
})
}))
}, e.prototype._mapCountFormToApi = function(e) {
var t = {},
i = {
price: "full_price",
initialFee: "initial_fee",
creditPeriod: "mortgage_term",
mortgageAmount: "mortgage_amount"
};
for (var r in e) {
var a = e[r];
null !== a && i[r] && (t[i[r]] = a)
}
return t
}, e.prototype.scrollToMe = function(e) {
var t = $(this.$el).offset().top;
e || (e = Math.abs(t - $(window).scrollTop()) / 4), $("html, body").animate({
scrollTop: t - 20
}, {
duration: e
})
}, e.prototype.onBannerLoaded = function(e) {
return e.success ? void(this.bannerLoaded = !0) : void this._initRequestForm()
}, n(e, [{
key: "showPreload",
get: function() {
return !this.countFormAttached
}
}, {
key: "geoLocation",
get: function() {
return this.offer.has("params.city.id") && this.offer.has("params.region.id") ? {
city: {
id: this.offer.param("params.city.id", null)
},
region: {
id: this.offer.param("params.region.id", null)
}
} : null
}
}], [{
key: "styles",
value: i(1745)(o.asset("./styles/mortgage-calc.scss")),
enumerable: !0
}, {
key: "template",
value: i(1745)(o.asset("./templates/mortgage-calc.jade")),
enumerable: !0
}, {
key: "partials",
value: {
banner: i(1745)(o.asset("./templates/partials/banner.jade"))
},
enumerable: !0
}, {
key: "components",
value: {
CountForm: i(1746),
RequestForm: i(1766),
Preloader: i(405),
MortgageCalcDisplay: i(1756),
Banner: i(264)
},
enumerable: !0
}, {
key: "filters",
value: {
phoneFormatted: i(528)
},
enumerable: !0
}, {
key: "mixins",
value: [i(413)],
enumerable: !0
}, {
key: "props",
value: {
offer: {
"default": null
},
analyticsParams: {
type: Object,
"default": function() {
return {}
}
}
},
enumerable: !0
}]);
var t = e;
return e = o.ComponentVue(e) || e
}();
t["default"] = _, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
function n(e, t) {
if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function, not " + typeof t);
e.prototype = Object.create(t && t.prototype, {
constructor: {
value: e,
enumerable: !1,
writable: !0,
configurable: !0
}
}), t && (Object.setPrototypeOf ? Object.setPrototypeOf(e, t) : e.__proto__ = t)
}
t.__esModule = !0;
var o = i(288),
s = r(o),
l = i(1741),
c = r(l),
p = function(e) {
function t() {
var i = arguments.length <= 0 || void 0 === arguments[0] ? "requestForm" : arguments[0];
a(this, t), e.call(this, i), this.createFields(c["default"])
}
return n(t, e), t
}(s["default"]);
t["default"] = p, e.exports = t["default"]
}, function(e, t) {
"use strict";
t.__esModule = !0, t["default"] = {
email_name: {
caption: "",
type: "String",
view: "InputText",
required: !1,
maxLength: 255,
viewOptions: {
placeholder: "Ваше имя"
},
errors: {
required: "Укажите свое имя"
}
},
phone: {
caption: "",
type: "String",
view: "InputNumber",
required: !0,
maxLength: 11,
validate: [{
isLength: [11]
}],
viewOptions: {
placeholder: "Телефон",
type: "phone"
},
errors: {
required: "Пожалуйста, укажите контактный телефон для связи с вами",
isLength: "Введите номер целиком"
}
}
}, e.exports = t["default"]
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
function n(e, t) {
if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function, not " + typeof t);
e.prototype = Object.create(t && t.prototype, {
constructor: {
value: e,
enumerable: !1,
writable: !0,
configurable: !0
}
}), t && (Object.setPrototypeOf ? Object.setPrototypeOf(e, t) : e.__proto__ = t)
}
t.__esModule = !0;
var o = i(288),
s = r(o),
l = i(1743),
c = i(1744),
p = r(c),
d = function(e) {
function t() {
var i = arguments.length <= 0 || void 0 === arguments[0] ? "countForm" : arguments[0];
a(this, t), e.call(this, i), this.createFields(p["default"]), this._priceFieldValue = null, this._initialFeeFieldValue = null, this._interestRateFieldValue = null, this._creditPeriodFieldValue = null
}
return n(t, e), t.prototype.init = function() {
var e = this;
this.getField("price").on("validValue", function(t, i) {
e.getField("initialFee").setAttr("validate", [{
isBound: [Math.round(.2 * i), Math.round(.8 * i)]
}]);
var r = e.getField("initialFee").getRawValue();
null !== r && e.getField("initialFee").setRawValue(r).validate(), e._priceFieldValue = i
}).on("invalidValue", function(t, i) {
e._priceFieldValue = null
}), this.getField("initialFee").on("validValue", function(t, i) {
e._initialFeeFieldValue = i
}).on("invalidValue", function(t, i) {
e._initialFeeFieldValue = null
}), this.getField("creditPeriod").on("validValue", function(t, i) {
e._creditPeriodFieldValue = i
}).on("invalidValue", function(t, i) {
e._creditPeriodFieldValue = null
}), this.getField("interestRate").on("validValue", function(t, i) {
e._interestRateFieldValue = i
}).on("invalidValue", function(t, i) {
e._interestRateFieldValue = null
})
}, t.prototype.getCalcDataset = function() {
if (null === this._priceFieldValue || null === this._creditPeriodFieldValue || null === this._interestRateFieldValue || null === this._initialFeeFieldValue) return null;
var e = l.calcMonthlyFee(this._priceFieldValue, this._initialFeeFieldValue, this._interestRateFieldValue, this._creditPeriodFieldValue),
t = l.calcOverFee(this._priceFieldValue, this._initialFeeFieldValue, this._creditPeriodFieldValue, e),
i = l.calcTotalFee(this._priceFieldValue, t),
r = {
initialFee: this._initialFeeFieldValue,
monthlyFee: e,
overFee: t,
totalFee: i
};
return r
}, t.prototype.getMortgageAmount = function() {
return null === this._priceFieldValue ? null : this._priceFieldValue - this._initialFeeFieldValue
}, t
}(s["default"]);
t["default"] = d, e.exports = t["default"]
}, function(e, t) {
"use strict";
function i(e, t, i, r) {
var a = e - t,
n = i / 12 / 100,
o = r,
s = a * (n + n / (Math.pow(1 + n, o) - 1));
return s
}
function r(e, t, i, r) {
var a = e - t,
n = r,
o = i,
s = n * o - a;
return s
}
function a(e, t) {
var i = e,
r = t,
a = i + r;
return a
}
t.__esModule = !0, t.calcMonthlyFee = i, t.calcOverFee = r, t.calcTotalFee = a
}, function(e, t) {
"use strict";
t.__esModule = !0, t["default"] = {
price: {
caption: 'Стоимость объекта, ',
type: "Number",
view: "InputNumber",
required: !0,
maxLength: 255,
validate: [{
isInt: !0,
isBound: [0, 999999999]
}],
viewOptions: {
type: "spaces"
},
errors: {
required: "Заполните поле для расчетов",
isBound: "Введите число до %2%"
}
},
initialFee: {
caption: 'Первоначальный взнос, ',
type: "Number",
view: "InputNumber",
required: !0,
maxLength: 255,
viewOptions: {
type: "spaces"
},
errors: {
required: "Заполните поле для расчетов",
isBound: 'Взнос может составлять: от 20% (%1% ) до 80% (%2% )'
}
},
creditPeriod: {
caption: "Срок кредита, мес.",
type: "Number",
view: "InputNumber",
required: !0,
defaultValue: 120,
maxLength: 255,
validate: [{
isBound: [12, 360]
}],
viewOptions: {
type: "number"
},
errors: {
required: "Заполните поле для расчетов",
isBound: "Укажите срок кредитования от %1% до %2% месяцев"
}
},
interestRate: {
caption: "Процентная ставка, %",
type: "Number",
view: "InputNumber",
required: !0,
maxLength: 255,
sanitize: [{
toFloat: !0
}],
validate: [{
isFloat: !0,
isBound: [1, 30]
}],
defaultValue: 12,
viewOptions: {
mask: {
mask: "9{1,2}.9",
placeholder: ""
}
},
errors: {
required: "Заполните поле для расчетов",
isBound: "Укажите процентную ставку от %1% до %2% процентов"
}
}
}, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./CalcMath": 1743,
"./CalcMath.js": 1743,
"./CountForm/CountForm": 1742,
"./CountForm/CountForm.js": 1742,
"./CountForm/CountFormView": 1746,
"./CountForm/CountFormView.js": 1746,
"./CountForm/FieldView/CalcInputNumber/CalcInputNumber": 1748,
"./CountForm/FieldView/CalcInputNumber/CalcInputNumber.js": 1748,
"./CountForm/FieldView/CalcInputNumber/styles/calc-input-number.scss": 1750,
"./CountForm/FieldView/CalcInputNumber/templates/calc-input-number.jade": 1752,
"./CountForm/formFields": 1744,
"./CountForm/formFields.js": 1744,
"./CountForm/styles/mortgage-calc-count-form.scss": 1753,
"./CountForm/templates/mortgage-calc-count-form.jade": 1755,
"./Display/Display": 1756,
"./Display/Display.js": 1756,
"./Display/styles/mortgage-calc-display.scss": 1758,
"./Display/templates/mortgage-calc-display.jade": 1760,
"./MortgageCalc": 1739,
"./MortgageCalc.js": 1739,
"./RequestForm/FieldView/CalcInputNumber/CalcInputNumber": 1761,
"./RequestForm/FieldView/CalcInputNumber/CalcInputNumber.js": 1761,
"./RequestForm/FieldView/CalcInputNumber/styles/calc-input-number.scss": 1763,
"./RequestForm/FieldView/CalcInputNumber/templates/calc-input-number.jade": 1765,
"./RequestForm/RequestForm": 1740,
"./RequestForm/RequestForm.js": 1740,
"./RequestForm/RequestFormView": 1766,
"./RequestForm/RequestFormView.js": 1766,
"./RequestForm/formFields": 1741,
"./RequestForm/formFields.js": 1741,
"./RequestForm/styles/mortgage-calc-request-form.scss": 1768,
"./RequestForm/templates/mortgage-calc-request-form.jade": 1770,
"./styles/mortgage-calc.scss": 1771,
"./templates/mortgage-calc.jade": 1773,
"./templates/partials/banner.jade": 1774
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1745
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
function n(e, t) {
if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function, not " + typeof t);
e.prototype = Object.create(t && t.prototype, {
constructor: {
value: e,
enumerable: !1,
writable: !0,
configurable: !0
}
}), t && (Object.setPrototypeOf ? Object.setPrototypeOf(e, t) : e.__proto__ = t)
}
t.__esModule = !0;
var o = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
s = i(145),
l = i(311),
c = r(l),
p = function(e) {
function t() {
a(this, r), e.apply(this, arguments)
}
n(t, e), o(t, null, [{
key: "template",
value: i(1747)(s.asset("./templates/mortgage-calc-count-form.jade")),
enumerable: !0
}, {
key: "styles",
value: i(1747)(s.asset("./styles/mortgage-calc-count-form.scss")),
enumerable: !0
}, {
key: "components",
value: {
InputNumber: i(347),
InputText: i(317)
},
enumerable: !0
}, {
key: "props",
value: {
form: null,
loading: {
type: Boolean,
"default": !1
},
success: {
type: Boolean,
"default": !0
},
errorMessage: {
type: String,
"default": ""
}
},
enumerable: !0
}]);
var r = t;
return t = s.ComponentVue(t) || t
}(c["default"]);
t["default"] = p, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./CountForm": 1742,
"./CountForm.js": 1742,
"./CountFormView": 1746,
"./CountFormView.js": 1746,
"./FieldView/CalcInputNumber/CalcInputNumber": 1748,
"./FieldView/CalcInputNumber/CalcInputNumber.js": 1748,
"./FieldView/CalcInputNumber/styles/calc-input-number.scss": 1750,
"./FieldView/CalcInputNumber/templates/calc-input-number.jade": 1752,
"./formFields": 1744,
"./formFields.js": 1744,
"./styles/mortgage-calc-count-form.scss": 1753,
"./templates/mortgage-calc-count-form.jade": 1755
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1747
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
function n(e, t) {
if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function, not " + typeof t);
e.prototype = Object.create(t && t.prototype, {
constructor: {
value: e,
enumerable: !1,
writable: !0,
configurable: !0
}
}), t && (Object.setPrototypeOf ? Object.setPrototypeOf(e, t) : e.__proto__ = t)
}
t.__esModule = !0;
var o = i(1155),
s = r(o),
l = function(e) {
function t(r) {
a(this, t), e.call(this, r), this.styles = i(1749)(this._getStylePath("./styles/calc-input-number.scss")), this.template = i(1749)(this._getTemplatePath("./templates/calc-input-number.jade"))
}
return n(t, e), t
}(s["default"]);
t["default"] = l, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./CalcInputNumber": 1748,
"./CalcInputNumber.js": 1748,
"./styles/calc-input-number.scss": 1750,
"./templates/calc-input-number.jade": 1752
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1749
}, function(e, t, i) {
var r = i(1751);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, "", ""])
}, function(e, t) {
e.exports = '
name --> {{field.getName()}}
value --> {{value | json}}
valid Value {{field.getValue() | json}}
field.getErrors--> {{field.getErrors() | json}}
'
}, function(e, t, i) {
var r = i(1754);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, ".mortgage-calc-count-form__inner{padding:0 36px 30px;position:relative}.mortgage-calc-count-form__display{margin-top:8px}.mortgage-calc-count-form__group{position:relative;z-index:2}.mortgage-calc-count-form__row{vertical-align:top}@media (max-width:1679px){.mortgage-calc-count-form__row{width:480px}}@media (min-width:1680px){.mortgage-calc-count-form__row{width:50%;display:inline-block;box-sizing:border-box}.mortgage-calc-count-form__row:first-child{padding-right:12px}.mortgage-calc-count-form__row:last-child{padding-left:12px}}.mortgage-calc-count-form__message._error{color:#c03c40;margin-bottom:12px}.mortgage-calc-count-form__field{vertical-align:top;width:50%;display:inline-block;box-sizing:border-box;margin-bottom:18px}.mortgage-calc-count-form__field:first-child{padding-right:12px}.mortgage-calc-count-form__field:last-child{padding-left:12px}.mortgage-calc-count-form__field .field-number__input,.mortgage-calc-count-form__field .field-text__input{box-sizing:border-box;margin:0;padding:0 11px;width:100%;background-color:#fff;border:1px solid #c4c4c4;border-radius:0;vertical-align:top;-webkit-appearance:none;-moz-appearance:textfield;font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:17px;color:#000;height:36px;height:42px}.mortgage-calc-count-form__field .field-number__input::-webkit-input-placeholder,.mortgage-calc-count-form__field .field-text__input::-webkit-input-placeholder{color:gray;opacity:1}.mortgage-calc-count-form__field .field-number__input::-moz-placeholder,.mortgage-calc-count-form__field .field-text__input::-moz-placeholder{color:gray;opacity:1}.mortgage-calc-count-form__field .field-number__input:-ms-input-placeholder,.mortgage-calc-count-form__field .field-text__input:-ms-input-placeholder{color:gray;opacity:1}.mortgage-calc-count-form__field .field-number__input._focus,.mortgage-calc-count-form__field .field-number__input:focus,.mortgage-calc-count-form__field .field-text__input._focus,.mortgage-calc-count-form__field .field-text__input:focus{background-color:#fff;border-color:#000;color:#000}.mortgage-calc-count-form__field .field-number__input._disabled,.mortgage-calc-count-form__field .field-number__input:disabled,.mortgage-calc-count-form__field .field-text__input._disabled,.mortgage-calc-count-form__field .field-text__input:disabled{background-color:#f3f3f3;border-color:#d9d9d9;color:#c5c5c5}.mortgage-calc-count-form__field .field-number__input._error,.mortgage-calc-count-form__field .field-text__input._error{background-color:#ffedee;border-color:#c03c40;color:#c03c40}.mortgage-calc-count-form__field .field-number__label{display:block;margin-bottom:6px}@media (min-width:1680px){.mortgage-calc-count-form__field._creditPeriod,.mortgage-calc-count-form__field._initialFee,.mortgage-calc-count-form__field._interestRate,.mortgage-calc-count-form__field._price{position:relative}.mortgage-calc-count-form__field._creditPeriod .form-errors,.mortgage-calc-count-form__field._initialFee .form-errors,.mortgage-calc-count-form__field._interestRate .form-errors,.mortgage-calc-count-form__field._price .form-errors{position:absolute;width:200px}}.mortgage-calc-count-form__field .form-errors{margin-bottom:-6px}", ""])
}, function(e, t) {
e.exports = ""
}, function(e, t, i) {
"use strict";
function r(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
t.__esModule = !0;
var a = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
n = i(145),
o = function() {
function e() {
r(this, t)
}
a(e, [{
key: "dataset",
get: function() {
return this.form.getCalcDataset()
}
}], [{
key: "template",
value: i(1757)(n.asset("./templates/mortgage-calc-display.jade")),
enumerable: !0
}, {
key: "styles",
value: i(1757)(n.asset("./styles/mortgage-calc-display.scss")),
enumerable: !0
}, {
key: "props",
value: {
visualization: {
type: String,
"default": "plain"
},
form: null
},
enumerable: !0
}]);
var t = e;
return e = n.ComponentVue(e) || e
}();
t["default"] = o, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./Display": 1756,
"./Display.js": 1756,
"./styles/mortgage-calc-display.scss": 1758,
"./templates/mortgage-calc-display.jade": 1760
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1757
}, function(e, t, i) {
var r = i(1759);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, ".mortgage-calc-display-plain__title{margin-bottom:12px;font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:30px;line-height:36px}.mortgage-calc-display-plain__pane{position:relative}.mortgage-calc-display-plain__data-field{font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:17px;line-height:24px;color:#000;display:inline-block}@media (max-width:1279px){.mortgage-calc-display-plain__data-field{margin-bottom:12px}.mortgage-calc-display-plain__data-field:not(:last-child){width:228px;margin-right:24px}.mortgage-calc-display-plain__data-field:last-child{display:block}}@media (min-width:1280px){.mortgage-calc-display-plain__data-field:not(:last-child){width:228px;margin-right:24px}}@media (min-width:1680px){.mortgage-calc-display-plain__data-field:not(:last-child){width:200px;margin-right:24px}}.mortgage-calc-display-plain__data-field-label{margin-bottom:8px;font-size:17px}@media (min-width:1280px){.mortgage-calc-display-plain__data-field-label{margin-bottom:6px}}.mortgage-calc-display-plain__data-field-value{font-size:30px}.mortgage-calc-display-plain__data-field-value._monthlyFee,.mortgage-calc-display-plain__data-field-value._overFee,.mortgage-calc-display-plain__data-field-value._totalFee{color:#c03c40}", ""])
}, function(e, t) {
e.exports = '
Укажите все параметры для отображения диаграммы
Расчет
Укажите все параметры для отображения расчетов по ипотеке
Ежемесячный платеж
{{{dataset.monthlyFee | round | thinSpaces}}}
Сумма переплаты
{{{dataset.overFee | round | thinSpaces}}}
Общая выплата
{{{dataset.totalFee | round | thinSpaces}}}
'
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
function n(e, t) {
if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function, not " + typeof t);
e.prototype = Object.create(t && t.prototype, {
constructor: {
value: e,
enumerable: !1,
writable: !0,
configurable: !0
}
}), t && (Object.setPrototypeOf ? Object.setPrototypeOf(e, t) : e.__proto__ = t)
}
t.__esModule = !0;
var o = i(1155),
s = r(o),
l = function(e) {
function t(r) {
a(this, t), e.call(this, r), this.styles = i(1762)(this._getStylePath("./styles/calc-input-number.scss")), this.template = i(1762)(this._getTemplatePath("./templates/calc-input-number.jade"))
}
return n(t, e), t
}(s["default"]);
t["default"] = l, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./CalcInputNumber": 1761,
"./CalcInputNumber.js": 1761,
"./styles/calc-input-number.scss": 1763,
"./templates/calc-input-number.jade": 1765
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1762
}, function(e, t, i) {
var r = i(1764);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, "", ""])
}, function(e, t) {
e.exports = '
name --> {{field.getName()}}
value --> {{value | json}}
valid Value {{field.getValue() | json}}
field.getErrors--> {{field.getErrors() | json}}
'
}, function(e, t, i) {
"use strict";
function r(e) {
return e && e.__esModule ? e : {
"default": e
}
}
function a(e, t) {
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function")
}
function n(e, t) {
if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function, not " + typeof t);
e.prototype = Object.create(t && t.prototype, {
constructor: {
value: e,
enumerable: !1,
writable: !0,
configurable: !0
}
}), t && (Object.setPrototypeOf ? Object.setPrototypeOf(e, t) : e.__proto__ = t)
}
t.__esModule = !0;
var o = function() {
function e(e, t) {
for (var i = 0; i < t.length; i++) {
var r = t[i];
r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r)
}
}
return function(t, i, r) {
return i && e(t.prototype, i), r && e(t, r), t
}
}(),
s = i(145),
l = i(311),
c = r(l),
p = function(e) {
function t() {
a(this, r), e.apply(this, arguments)
}
n(t, e), o(t, null, [{
key: "template",
value: i(1767)(s.asset("./templates/mortgage-calc-request-form.jade")),
enumerable: !0
}, {
key: "styles",
value: i(1767)(s.asset("./styles/mortgage-calc-request-form.scss")),
enumerable: !0
}, {
key: "components",
value: {
InputNumber: i(347),
InputText: i(317)
},
enumerable: !0
}, {
key: "props",
value: {
form: null,
loading: {
type: Boolean,
"default": !1
},
success: {
type: Boolean,
"default": !0
},
errorMessage: {
type: String,
"default": ""
}
},
enumerable: !0
}]);
var r = t;
return t = s.ComponentVue(t) || t
}(c["default"]);
t["default"] = p, e.exports = t["default"]
}, function(e, t, i) {
function r(e) {
return i(a(e))
}
function a(e) {
return n[e] || function() {
throw new Error("Cannot find module '" + e + "'.")
}()
}
var n = {
"./FieldView/CalcInputNumber/CalcInputNumber": 1761,
"./FieldView/CalcInputNumber/CalcInputNumber.js": 1761,
"./FieldView/CalcInputNumber/styles/calc-input-number.scss": 1763,
"./FieldView/CalcInputNumber/templates/calc-input-number.jade": 1765,
"./RequestForm": 1740,
"./RequestForm.js": 1740,
"./RequestFormView": 1766,
"./RequestFormView.js": 1766,
"./formFields": 1741,
"./formFields.js": 1741,
"./styles/mortgage-calc-request-form.scss": 1768,
"./templates/mortgage-calc-request-form.jade": 1770
};
r.keys = function() {
return Object.keys(n)
}, r.resolve = a, e.exports = r, r.id = 1767
}, function(e, t, i) {
var r = i(1769);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, ".mortgage-calc-request-success{height:100%;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-ms-flex-pack:center;justify-content:center;-ms-flex-line-pack:center;align-content:center;-ms-flex-align:center;align-items:center}.mortgage-calc-request-success__msg{-ms-flex-order:0;order:0;-ms-flex:0 1 auto;flex:0 1 auto;-webkit-align-self:auto;-ms-flex-item-align:auto;align-self:auto}.mortgage-calc-request-success__msg-header{font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:30px;line-height:36px;margin-bottom:18px;text-align:center}.mortgage-calc-request-success__msg-subtitle{text-align:center}.mortgage-calc-request-form__success{position:absolute;top:0;left:0;right:0;bottom:0;background-color:#f2f2f2}.mortgage-calc-request-form__success.fade-transition{transition:opacity .5s ease}.mortgage-calc-request-form__success.fade-enter{opacity:.2}.mortgage-calc-request-form__success.fade-leave{opacity:0}.mortgage-calc-request-form__inner{border-top:1px solid #d9d9d9;padding:24px 36px;position:relative}.mortgage-calc-request-form__footer-info{font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:15px;line-height:18px;color:#000;color:gray;margin-top:4px}.mortgage-calc-request-form__title{margin-bottom:18px;font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:30px;line-height:36px}.mortgage-calc-request-form__subtitle{margin-bottom:18px}.mortgage-calc-request-form__buttons{vertical-align:top;display:inline-block}@media (min-width:1280px){.mortgage-calc-request-form__buttons{margin-left:24px}}@media (max-width:1279px){.mortgage-calc-request-form__submit-block{display:block}}@media (min-width:1280px) and (max-width:1679px){.mortgage-calc-request-form__submit-block{display:inline-block}}@media (min-width:1680px){.mortgage-calc-request-form__submit-block{display:inline-block}}.mortgage-calc-request-form__button._submit{box-sizing:border-box;border:none;border-radius:3px;cursor:pointer;font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;text-align:center;transition:background-color .1s ease;background-color:#c03c40;border:1px solid #c03c40;color:#fff;height:42px;padding:0 24px;font-size:17px;line-height:42px;margin-right:12px}.mortgage-calc-request-form__button._submit:focus{border-color:#000;background-color:#b32e33}.mortgage-calc-request-form__button._submit:hover{background-color:#d94348}.mortgage-calc-request-form__button._submit:active{background-color:#c03c40}.mortgage-calc-request-form__button._cancel{text-decoration:none;cursor:pointer}.mortgage-calc-request-form__button._cancel,.mortgage-calc-request-form__button._cancel:visited{transition:color .2s linear,border-color .2s linear}.mortgage-calc-request-form__button._cancel:focus,.mortgage-calc-request-form__button._cancel:hover{transition:none}.mortgage-calc-request-form__button._cancel,.mortgage-calc-request-form__button._cancel:visited{color:#0168bb}.mortgage-calc-request-form__button._cancel:focus,.mortgage-calc-request-form__button._cancel:hover{color:#c03c40;border-bottom:1px solid;border-color:rgba(192,60,64,.3)}.mortgage-calc-request-form__error{margin-top:12px;display:inline-block;color:#c03c40}.mortgage-calc-request-form__row{display:inline-block;vertical-align:top;width:480px}@media (min-width:1680px){.mortgage-calc-request-form__row{width:423px}}.mortgage-calc-request-form__field{margin-bottom:18px;vertical-align:top;width:50%;display:inline-block;box-sizing:border-box}.mortgage-calc-request-form__field:first-child{padding-right:12px}.mortgage-calc-request-form__field:last-child{padding-left:12px}.mortgage-calc-request-form__field .field-number__input,.mortgage-calc-request-form__field .field-text__input{box-sizing:border-box;margin:0;padding:0 11px;width:100%;background-color:#fff;border:1px solid #c4c4c4;border-radius:0;vertical-align:top;-webkit-appearance:none;-moz-appearance:textfield;font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:17px;color:#000;height:36px;height:42px}.mortgage-calc-request-form__field .field-number__input::-webkit-input-placeholder,.mortgage-calc-request-form__field .field-text__input::-webkit-input-placeholder{color:gray;opacity:1}.mortgage-calc-request-form__field .field-number__input::-moz-placeholder,.mortgage-calc-request-form__field .field-text__input::-moz-placeholder{color:gray;opacity:1}.mortgage-calc-request-form__field .field-number__input:-ms-input-placeholder,.mortgage-calc-request-form__field .field-text__input:-ms-input-placeholder{color:gray;opacity:1}.mortgage-calc-request-form__field .field-number__input._focus,.mortgage-calc-request-form__field .field-number__input:focus,.mortgage-calc-request-form__field .field-text__input._focus,.mortgage-calc-request-form__field .field-text__input:focus{background-color:#fff;border-color:#000;color:#000}.mortgage-calc-request-form__field .field-number__input._disabled,.mortgage-calc-request-form__field .field-number__input:disabled,.mortgage-calc-request-form__field .field-text__input._disabled,.mortgage-calc-request-form__field .field-text__input:disabled{background-color:#f3f3f3;border-color:#d9d9d9;color:#c5c5c5}.mortgage-calc-request-form__field .field-number__input._error,.mortgage-calc-request-form__field .field-text__input._error{background-color:#ffedee;border-color:#c03c40;color:#c03c40}.mortgage-calc-request-form__field .field-number__label{display:block;margin-bottom:6px}", ""]);
}, function(e, t) {
e.exports = ''
}, function(e, t, i) {
var r = i(1772);
"string" == typeof r && (r = [
[e.id, r, ""]
]);
i(165)(r, {});
r.locals && (e.exports = r.locals)
}, function(e, t, i) {
t = e.exports = i(164)(), t.push([e.id, ".mortgage-calc{font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:17px;line-height:24px;color:#000;padding:28px 0 6px;background:#f2f2f2;position:relative}.mortgage-calc._success{padding:27px 48px 42px;text-align:center}.mortgage-calc__header{padding:0 36px}.mortgage-calc__title{font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:36px;line-height:42px;margin-bottom:15px}.mortgage-calc__preloader{position:absolute;left:0;right:0;bottom:0;top:0;opacity:1;background:hsla(0,0%,100%,.5)}.mortgage-calc__preloader-widget{position:absolute;left:0;right:0;bottom:0;top:0;margin:auto}.mortgage-calc-banner{font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:17px;line-height:24px;color:#000;border-top:1px solid #d9d9d9}.mortgage-calc-banner__content{display:inline-block;box-sizing:border-box;width:100%;padding:24px 36px;vertical-align:top;font-size:0}.mortgage-calc-banner__media{display:inline-block;margin-right:24px;vertical-align:top;width:228px}@media (min-width:1680px){.mortgage-calc-banner__media{width:200px;vertical-align:middle}}.mortgage-calc-banner__img{display:inline-block;max-width:100%}.mortgage-calc-banner__info{display:inline-block;vertical-align:top}@media (max-width:1279px){.mortgage-calc-banner__info{width:270px}}@media (min-width:1280px) and (max-width:1679px){.mortgage-calc-banner__info{width:510px}}@media (min-width:1680px){.mortgage-calc-banner__info{width:646px;vertical-align:middle}}.mortgage-calc-banner__text{display:inline-block;width:100%;vertical-align:top;font-size:17px;margin-bottom:12px}@media (min-width:1680px){.mortgage-calc-banner__text{width:422px;margin-right:54px;margin-bottom:0;vertical-align:middle}}.mortgage-calc-banner__button{display:inline-block;width:170px;vertical-align:middle;box-sizing:border-box;border:none;border-radius:3px;cursor:pointer;font-family:PTSans,'sans-serif';font-style:normal;text-align:center;transition:background-color .1s ease;background-color:#c03c40;border:1px solid #c03c40;color:#fff;height:42px;padding:0 24px;font-size:17px;line-height:42px;padding:0 12px;line-height:40px;font-weight:400;text-decoration:none}.mortgage-calc-banner__button:focus{border-color:#000;background-color:#b32e33}.mortgage-calc-banner__button:hover{background-color:#d94348}.mortgage-calc-banner__button:active{background-color:#c03c40}.mortgage-calc-banner__footer{border-top:1px solid #d9d9d9;padding:18px 36px 30px;position:relative;font-family:PTSans,'sans-serif';font-weight:400;font-style:normal;font-size:15px;line-height:18px;color:#000;color:gray}", ""])
}, function(e, t) {
e.exports = "
Ипотечный калькулятор
"
}, function(e, t) {
e.exports = "
Реклама посреднических услуг. Сервис по подбору ипотечных кредитов банков предоставляется рекламодателями — ипотечными брокерами. Администрация сайта не участвует в отношениях, которые возникли или могут возникнуть между пользователями и рекламодателем. С перечнем банков-партнеров можно ознакомиться у брокера партнера. Администрация сайта не несет ответственности за невозможность выдачи ипотеки под конкретный объект недвижимости.