diff --git a/pkgdown.yml b/pkgdown.yml index 7e07f568..c8a7065f 100644 --- a/pkgdown.yml +++ b/pkgdown.yml @@ -2,7 +2,7 @@ pandoc: 3.1.11 pkgdown: 2.1.0 pkgdown_sha: ~ articles: {} -last_built: 2024-09-01T19:11Z +last_built: 2024-09-01T19:34Z urls: reference: https://trafficonese.github.io/leaflet.extras2/reference article: https://trafficonese.github.io/leaflet.extras2/articles diff --git a/reference/addHeightgraph.html b/reference/addHeightgraph.html index 02aa466c..43415533 100644 --- a/reference/addHeightgraph.html +++ b/reference/addHeightgraph.html @@ -5,7 +5,7 @@ addGeoJSON."> +addGeoJSON."> Skip to contents @@ -155,25 +155,23 @@

See also

Examples

-
if (FALSE) { # \dontrun{
-library(leaflet)
+    
library(leaflet)
 library(leaflet.extras2)
 library(sf)
 
 data <- st_cast(st_as_sf(leaflet::atlStorms2005[4,]), "LINESTRING")
 data <- st_transform(data, 4326)
 data <- data.frame(st_coordinates(data))
-data$elev <-  runif(nrow(data), 10, 500)
+data$elev <- round(runif(nrow(data), 10, 500), 2)
 data$L1 <- NULL
 L1 <- round(seq.int(1, 4, length.out = nrow(data)))
-data <- st_as_sf(st_sfc(lapply(split(data, L1), sfg_linestring)))
 data <- st_as_sf(st_sfc(lapply(split(data, L1), function(x) {
-    st_linestring(as.matrix(x))
+  st_linestring(as.matrix(x))
 })))
 data$steepness <- 1:nrow(data)
 data$suitability <- nrow(data):1
 data$popup <- apply(data, 1, function(x) {
- sprintf("Steepness: %s<br>Suitability: %s", x$steepness, x$suitability)
+  sprintf("Steepness: %s<br>Suitability: %s", x$steepness, x$suitability)
 })
 
 leaflet() %>%
@@ -181,8 +179,8 @@ 

Examples addHeightgraph(color = "red", columns = c("steepness", "suitability"), opacity = 1, data = data, group = "heightgraph", options = heightgraphOptions(width = 400)) -} # } -

+
+
diff --git a/reference/addHexbin.html b/reference/addHexbin.html index 94006fe2..1460df34 100644 --- a/reference/addHexbin.html +++ b/reference/addHexbin.html @@ -148,8 +148,8 @@

Examples colorRange = c("red", "yellow", "blue"), radiusRange = c(10, 20) )) -
- +
+ diff --git a/reference/addHistory.html b/reference/addHistory.html index 7df5631d..91cabfa5 100644 --- a/reference/addHistory.html +++ b/reference/addHistory.html @@ -85,8 +85,8 @@

Examplesleaflet() %>% addTiles() %>% addHistory() -
- +
+ diff --git a/reference/addLabelgun.html b/reference/addLabelgun.html index 528dddc0..83511cbf 100644 --- a/reference/addLabelgun.html +++ b/reference/addLabelgun.html @@ -1,7 +1,7 @@ Add addLabelgun Plugin — addLabelgun • leaflet.extras2 +to labels of your choice (with higher weight)."> Skip to contents @@ -87,6 +87,21 @@

Referenceshttps://github.com/Geovation/labelgun

+
+

Examples

+
library(leaflet)
+library(leaflet.extras2)
+
+leaflet() %>%
+  addTiles() %>%
+  addMarkers(data = breweries91,
+             label = ~brewery,
+             group = "markers",
+             labelOptions = labelOptions(permanent = TRUE)) %>%
+  addLabelgun("markers", 1)
+
+
+
diff --git a/reference/addMapkeyMarkers.html b/reference/addMapkeyMarkers.html index 021811fe..84b2e22b 100644 --- a/reference/addMapkeyMarkers.html +++ b/reference/addMapkeyMarkers.html @@ -166,8 +166,8 @@

Examples background = "transparent"), group = "mapkey", label = ~state, popup = ~village) -
- +
+ diff --git a/reference/addMovingMarker.html b/reference/addMovingMarker.html index 315b4d4e..8f8a9158 100644 --- a/reference/addMovingMarker.html +++ b/reference/addMovingMarker.html @@ -1,7 +1,7 @@ Add Moving Markers — addMovingMarker • leaflet.extras2 +Alternatively, coordinates can also be passed as numeric vectors.">
Skip to contents @@ -157,8 +157,7 @@

See also

Examples

-
if (FALSE) { # \dontrun{
-library(sf)
+    
library(sf)
 library(leaflet)
 library(leaflet.extras2)
 
@@ -176,8 +175,8 @@ 

Examples movingOptions = movingMarkerOptions(autostart = TRUE, loop = TRUE), label="I am a pirate!", popup="Arrr") -} # } -

+
+
diff --git a/reference/addSidebyside.html b/reference/addSidebyside.html index bfe32bf0..f88264b1 100644 --- a/reference/addSidebyside.html +++ b/reference/addSidebyside.html @@ -118,8 +118,8 @@

Examples addSidebyside(layerId = "sidecontrols", rightId = "baseid", leftId = "cartoid") -
- +
+ diff --git a/reference/addSpinner.html b/reference/addSpinner.html index ef8cdf48..f355cca8 100644 --- a/reference/addSpinner.html +++ b/reference/addSpinner.html @@ -79,8 +79,8 @@

Examples startSpinner(options = list("lines" = 7, "length" = 20)) %>% addMarkers(~long, ~lat, popup = ~as.character(mag), label = ~as.character(mag)) %>% stopSpinner() -
- +
+ diff --git a/reference/addTimeslider.html b/reference/addTimeslider.html index f280e465..d873076d 100644 --- a/reference/addTimeslider.html +++ b/reference/addTimeslider.html @@ -3,7 +3,7 @@ enables you to dynamically add and remove Markers/Lines on a map by using a JQuery UI slider."> +JQuery UI slider."> Skip to contents @@ -167,13 +167,13 @@

See also

Examples

-
if (FALSE) { # \dontrun{
-library(leaflet)
+    
library(leaflet)
 library(leaflet.extras2)
 library(sf)
 
 data <- sf::st_as_sf(leaflet::atlStorms2005[1,])
 data <- st_cast(data, "POINT")
+#> Warning: repeating attributes for all sub-geometries for which they may not be constant
 data$time = as.POSIXct(
   seq.POSIXt(Sys.time() - 1000, Sys.time(), length.out = nrow(data)))
 
@@ -185,8 +185,8 @@ 

Examples timeAttribute = "time", range = TRUE)) %>% setView(-72, 22, 4) -} # } -

+
+
diff --git a/reference/addWMS.html b/reference/addWMS.html index 93c4a7e5..95c42813 100644 --- a/reference/addWMS.html +++ b/reference/addWMS.html @@ -143,8 +143,8 @@

Examples transparent = TRUE, format = "image/png", info_format = "text/html")) -
- +
+ diff --git a/reference/historyOptions.html b/reference/historyOptions.html index f2da36bd..0e6998ee 100644 --- a/reference/historyOptions.html +++ b/reference/historyOptions.html @@ -147,8 +147,8 @@

Examples forwardText = "Go forward", orientation = "vertical" )) -
- +
+ diff --git a/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph-bindings.js b/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph-bindings.js new file mode 100644 index 00000000..d89ac920 --- /dev/null +++ b/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph-bindings.js @@ -0,0 +1,38 @@ +LeafletWidget.methods.addHeightgraph = function(data, props, layerId, group, geojson_opts, options) { + var map = this; + + // Add Last Coordinates of every Linestring to first Coordinates of next Linestring + var propkeys = Object.keys(props); + for (var i = 0; i < data.length; i++) { + data[i].properties = {records: props[propkeys[i]].length, summary: propkeys[i]}; + var tmp = data[i].features; + for (var j = 0; j < tmp.length; j++) { + if (tmp[j + 1]) { + var lncrd = tmp[j].geometry.coordinates.length; + tmp[j + 1].geometry.coordinates.unshift( + tmp[j].geometry.coordinates[lncrd - 1]); + } + } + } + + // Add Control + Data to Control + var hg = L.control.heightgraph(options); + map.controls.add(hg, "hg_control"); + hg.addData(data); + + // Add Geojson to Map + let gjlayer = L.geoJson(data, { + onEachFeature: function(feature, layer) { + let extraInfo = { + featureId: feature.id, + properties: feature.properties + }; + let popup = feature.properties ? feature.properties.popup : null; + if (typeof popup !== "undefined" && popup !== null) layer.bindPopup(popup); + layer.on("click", LeafletWidget.methods.mouseHandler(map.id, layerId, group, "heightgraph_click", extraInfo), this); + layer.on("mouseover", LeafletWidget.methods.mouseHandler(map.id, layerId, group, "heightgraph_mouseover", extraInfo), this); + layer.on("mouseout", LeafletWidget.methods.mouseHandler(map.id, layerId, group, "heightgraph_mouseout", extraInfo), this); + } + }); + map.layerManager.addLayer(gjlayer, "geojson", layerId, group); +}; diff --git a/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph.css b/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph.css new file mode 100644 index 00000000..2b71e899 --- /dev/null +++ b/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph.css @@ -0,0 +1 @@ +.heightgraph-container{background-color:rgba(250,250,250,.8);border-radius:10px;display:none;cursor:default;user-select:none}.heightgraph-toggle{cursor:pointer;box-shadow:0 1px 7px rgba(0,0,0,.4);border-radius:5px;width:28px;height:28px;background:#f8f8f9;display:block}.heightgraph-toggle-icon{background:url(img/area-chart.svg) no-repeat center center;background-size:14px 14px;width:26px;height:26px;position:absolute}.heightgraph-close-icon{background:url(img/remove.svg) no-repeat center center;background-size:14px 14px;width:26px;height:26px;position:absolute;right:0;display:none;cursor:pointer}.border-top{fill:none}.legend-hover{cursor:pointer}.legend-text{fill:#000;font-size:10px;cursor:pointer}.tick,.tick text{fill:#000;pointer-events:none}.axis .tick line{visibility:hidden;pointer-events:none}.axis path{stroke:#000;fill:none;stroke-width:2px;shape-rendering:crispEdges;pointer-events:none}.focusbox{display:none;font-size:10px;fill:#000;pointer-events:none}.focusbox rect{fill:rgba(255,255,255,.8);stroke-width:1px;stroke:#888;pointer-events:none}.focusbox text{font-size:12px}.focusLine line{stroke-width:1px;stroke:#141414;display:none;cursor:default;shape-rendering:crispEdges}.height-focus.label rect{fill:rgba(255,255,255,.5);stroke-width:1px;stroke:#888;pointer-events:none;shape-rendering:crispEdges}.height-focus.line{stroke:#141414;stroke-width:1px;shape-rendering:crispEdges}.height-focus.circle{stroke:#fff;stroke-width:1px}.mouse-height-box-text{font-size:12px}.grid .tick{pointer-events:none}.grid .tick line{stroke:#eee;stroke-width:1px;shape-rendering:crispEdges}.grid path{stroke-width:0;pointer-events:none}.tspan{font-weight:700}.select-symbol{cursor:pointer}.select-info{cursor:default}.lineSelection{cursor:move} diff --git a/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph.js b/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph.js new file mode 100644 index 00000000..008c4c1b --- /dev/null +++ b/reference/libs/lfx-heightgraph-1.0.0/L.Control.Heightgraph.js @@ -0,0 +1 @@ +!function(){"use strict";function t(n){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(n)}function n(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}function e(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,r)}return e}function r(t){for(var r=1;rt.length)&&(n=t.length);for(var e=0,r=new Array(n);e=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){e=t[Symbol.iterator]()},n:function(){var t=e.next();return s=t.done,t},e:function(t){u=!0,a=t},f:function(){try{s||null==e.return||e.return()}finally{if(u)throw a}}}}var a="http://www.w3.org/1999/xhtml",s={svg:"http://www.w3.org/2000/svg",xhtml:a,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function u(t){var n=t+="",e=n.indexOf(":");return e>=0&&"xmlns"!==(n=t.slice(0,e))&&(t=t.slice(e+1)),s.hasOwnProperty(n)?{space:s[n],local:t}:t}function l(t){return function(){var n=this.ownerDocument,e=this.namespaceURI;return e===a&&n.documentElement.namespaceURI===a?n.createElement(t):n.createElementNS(e,t)}}function h(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function c(t){var n=u(t);return(n.local?h:l)(n)}function f(){}function d(t){return null==t?f:function(){return this.querySelector(t)}}function p(){return[]}function g(t){return null==t?p:function(){return this.querySelectorAll(t)}}function _(t){return function(){return this.matches(t)}}function v(t){return new Array(t.length)}function y(t,n){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=n}y.prototype={constructor:y,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,n){return this._parent.insertBefore(t,n)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};function m(t,n,e,r,i,o){for(var a,s=0,u=n.length,l=o.length;sn?1:t>=n?0:NaN}function b(t){return function(){this.removeAttribute(t)}}function M(t){return function(){this.removeAttributeNS(t.space,t.local)}}function k(t,n){return function(){this.setAttribute(t,n)}}function A(t,n){return function(){this.setAttributeNS(t.space,t.local,n)}}function S(t,n){return function(){var e=n.apply(this,arguments);null==e?this.removeAttribute(t):this.setAttribute(t,e)}}function T(t,n){return function(){var e=n.apply(this,arguments);null==e?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,e)}}function N(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function C(t){return function(){this.style.removeProperty(t)}}function E(t,n,e){return function(){this.style.setProperty(t,n,e)}}function H(t,n,e){return function(){var r=n.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,e)}}function D(t,n){return t.style.getPropertyValue(n)||N(t).getComputedStyle(t,null).getPropertyValue(n)}function F(t){return function(){delete this[t]}}function P(t,n){return function(){this[t]=n}}function B(t,n){return function(){var e=n.apply(this,arguments);null==e?delete this[t]:this[t]=e}}function O(t){return t.trim().split(/^|\s+/)}function z(t){return t.classList||new I(t)}function I(t){this._node=t,this._names=O(t.getAttribute("class")||"")}function j(t,n){for(var e=z(t),r=-1,i=n.length;++r=0&&(this._names.splice(n,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var rt={},it=null;"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(rt={mouseenter:"mouseover",mouseleave:"mouseout"}));function ot(t,n,e){return t=at(t,n,e),function(n){var e=n.relatedTarget;e&&(e===this||8&e.compareDocumentPosition(this))||t.call(this,n)}}function at(t,n,e){return function(r){var i=it;it=r;try{t.call(this,this.__data__,n,e)}finally{it=i}}}function st(t){return t.trim().split(/^|\s+/).map((function(t){var n="",e=t.indexOf(".");return e>=0&&(n=t.slice(e+1),t=t.slice(0,e)),{type:t,name:n}}))}function ut(t){return function(){var n=this.__on;if(n){for(var e,r=0,i=-1,o=n.length;r=b&&(b=w+1);!(y=_[b])&&++b=0;)(r=i[o])&&(a&&4^r.compareDocumentPosition(a)&&a.parentNode.insertBefore(r,a),a=r);return this},sort:function(t){function n(n,e){return n&&e?t(n.__data__,e.__data__):!n-!e}t||(t=w);for(var e=this._groups,r=e.length,i=new Array(r),o=0;o1?this.each((null==n?C:"function"==typeof n?H:E)(t,n,null==e?"":e)):D(this.node(),t)},property:function(t,n){return arguments.length>1?this.each((null==n?F:"function"==typeof n?B:P)(t,n)):this.node()[t]},classed:function(t,n){var e=O(t+"");if(arguments.length<2){for(var r=z(this.node()),i=-1,o=e.length;++i=0&&(e=t.slice(r+1),t=t.slice(0,r)),t&&!n.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:e}}))}function Tt(t,n){for(var e,r=0,i=t.length;r0)for(var e,r,i=new Array(e),o=0;o=0&&n._call.call(null,t),n=n._next;--Ht}()}finally{Ht=0,function(){var t,n,e=Ct,r=1/0;for(;e;)e._call?(r>e._time&&(r=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:Ct=n);Et=t,Gt(r)}(),Pt=0}}function $t(){var t=Ot.now(),n=t-Ft;n>1e3&&(Bt-=n,Ft=t)}function Gt(t){Ht||(Lt&&(Lt=clearTimeout(Lt)),t-Pt>24?(t<1/0&&(Lt=setTimeout(Xt,t-Ot.now()-Bt)),Dt&&(Dt=clearInterval(Dt))):(Dt||(Ft=Ot.now(),Dt=setInterval($t,1e3)),Ht=1,zt(Xt)))}function Vt(t,n,e){var r=new Rt;return n=null==n?0:+n,r.restart((function(e){r.stop(),t(e+n)}),n,e),r}Rt.prototype=qt.prototype={constructor:Rt,restart:function(t,n,e){if("function"!=typeof t)throw new TypeError("callback is not a function");e=(null==e?It():+e)+(null==n?0:+n),this._next||Et===this||(Et?Et._next=this:Ct=this,Et=this),this._call=t,this._time=e,Gt()},stop:function(){this._call&&(this._call=null,this._time=1/0,Gt())}};var Yt=kt("start","end","cancel","interrupt"),Ut=[];function Wt(t,n,e,r,i,o){var a=t.__transition;if(a){if(e in a)return}else t.__transition={};!function(t,n,e){var r,i=t.__transition;function o(u){var l,h,c,f;if(1!==e.state)return s();for(l in i)if((f=i[l]).name===e.name){if(3===f.state)return Vt(o);4===f.state?(f.state=6,f.timer.stop(),f.on.call("interrupt",t,t.__data__,f.index,f.group),delete i[l]):+l0)throw new Error("too late; already scheduled");return e}function Kt(t,n){var e=Qt(t,n);if(e.state>3)throw new Error("too late; already running");return e}function Qt(t,n){var e=t.__transition;if(!e||!(e=e[n]))throw new Error("transition not found");return e}function Jt(t,n,e){t.prototype=n.prototype=e,e.constructor=t}function tn(t,n){var e=Object.create(t.prototype);for(var r in n)e[r]=n[r];return e}function nn(){}var en="\\s*([+-]?\\d+)\\s*",rn="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",on="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",an=/^#([0-9a-f]{3,8})$/,sn=new RegExp("^rgb\\("+[en,en,en]+"\\)$"),un=new RegExp("^rgb\\("+[on,on,on]+"\\)$"),ln=new RegExp("^rgba\\("+[en,en,en,rn]+"\\)$"),hn=new RegExp("^rgba\\("+[on,on,on,rn]+"\\)$"),cn=new RegExp("^hsl\\("+[rn,on,on]+"\\)$"),fn=new RegExp("^hsla\\("+[rn,on,on,rn]+"\\)$"),dn={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};function pn(){return this.rgb().formatHex()}function gn(){return this.rgb().formatRgb()}function _n(t){var n,e;return t=(t+"").trim().toLowerCase(),(n=an.exec(t))?(e=n[1].length,n=parseInt(n[1],16),6===e?vn(n):3===e?new wn(n>>8&15|n>>4&240,n>>4&15|240&n,(15&n)<<4|15&n,1):8===e?yn(n>>24&255,n>>16&255,n>>8&255,(255&n)/255):4===e?yn(n>>12&15|n>>8&240,n>>8&15|n>>4&240,n>>4&15|240&n,((15&n)<<4|15&n)/255):null):(n=sn.exec(t))?new wn(n[1],n[2],n[3],1):(n=un.exec(t))?new wn(255*n[1]/100,255*n[2]/100,255*n[3]/100,1):(n=ln.exec(t))?yn(n[1],n[2],n[3],n[4]):(n=hn.exec(t))?yn(255*n[1]/100,255*n[2]/100,255*n[3]/100,n[4]):(n=cn.exec(t))?An(n[1],n[2]/100,n[3]/100,1):(n=fn.exec(t))?An(n[1],n[2]/100,n[3]/100,n[4]):dn.hasOwnProperty(t)?vn(dn[t]):"transparent"===t?new wn(NaN,NaN,NaN,0):null}function vn(t){return new wn(t>>16&255,t>>8&255,255&t,1)}function yn(t,n,e,r){return r<=0&&(t=n=e=NaN),new wn(t,n,e,r)}function mn(t){return t instanceof nn||(t=_n(t)),t?new wn((t=t.rgb()).r,t.g,t.b,t.opacity):new wn}function xn(t,n,e,r){return 1===arguments.length?mn(t):new wn(t,n,e,null==r?1:r)}function wn(t,n,e,r){this.r=+t,this.g=+n,this.b=+e,this.opacity=+r}function bn(){return"#"+kn(this.r)+kn(this.g)+kn(this.b)}function Mn(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function kn(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function An(t,n,e,r){return r<=0?t=n=e=NaN:e<=0||e>=1?t=n=NaN:n<=0&&(t=NaN),new Tn(t,n,e,r)}function Sn(t){if(t instanceof Tn)return new Tn(t.h,t.s,t.l,t.opacity);if(t instanceof nn||(t=_n(t)),!t)return new Tn;if(t instanceof Tn)return t;var n=(t=t.rgb()).r/255,e=t.g/255,r=t.b/255,i=Math.min(n,e,r),o=Math.max(n,e,r),a=NaN,s=o-i,u=(o+i)/2;return s?(a=n===o?(e-r)/s+6*(e0&&u<1?0:a,new Tn(a,s,u,t.opacity)}function Tn(t,n,e,r){this.h=+t,this.s=+n,this.l=+e,this.opacity=+r}function Nn(t,n,e){return 255*(t<60?n+(e-n)*t/60:t<180?e:t<240?n+(e-n)*(240-t)/60:n)}function Cn(t){return function(){return t}}function En(t){return 1==(t=+t)?Hn:function(n,e){return e-n?function(t,n,e){return t=Math.pow(t,e),n=Math.pow(n,e)-t,e=1/e,function(r){return Math.pow(t+r*n,e)}}(n,e,t):Cn(isNaN(n)?e:n)}}function Hn(t,n){var e=n-t;return e?function(t,n){return function(e){return t+e*n}}(t,e):Cn(isNaN(t)?n:t)}Jt(nn,_n,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:pn,formatHex:pn,formatHsl:function(){return Sn(this).formatHsl()},formatRgb:gn,toString:gn}),Jt(wn,xn,tn(nn,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new wn(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new wn(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:bn,formatHex:bn,formatRgb:Mn,toString:Mn})),Jt(Tn,(function(t,n,e,r){return 1===arguments.length?Sn(t):new Tn(t,n,e,null==r?1:r)}),tn(nn,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new Tn(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new Tn(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),n=isNaN(t)||isNaN(this.s)?0:this.s,e=this.l,r=e+(e<.5?e:1-e)*n,i=2*e-r;return new wn(Nn(t>=240?t-240:t+120,i,r),Nn(t,i,r),Nn(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var Ln=function t(n){var e=En(n);function r(t,n){var r=e((t=xn(t)).r,(n=xn(n)).r),i=e(t.g,n.g),o=e(t.b,n.b),a=Hn(t.opacity,n.opacity);return function(n){return t.r=r(n),t.g=i(n),t.b=o(n),t.opacity=a(n),t+""}}return r.gamma=t,r}(1);function Dn(t,n){n||(n=[]);var e,r=t?Math.min(n.length,t.length):0,i=n.slice();return function(o){for(e=0;eo&&(i=n.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(e=e[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,u.push({i:a,x:Bn(e,r)})),o=In.lastIndex;return o180?n+=360:n-t>180&&(t+=360),o.push({i:e.push(i(e)+"rotate(",null,r)-2,x:Bn(t,n)})):n&&e.push(i(e)+"rotate("+n+r)}(o.rotate,a.rotate,s,u),function(t,n,e,o){t!==n?o.push({i:e.push(i(e)+"skewX(",null,r)-2,x:Bn(t,n)}):n&&e.push(i(e)+"skewX("+n+r)}(o.skewX,a.skewX,s,u),function(t,n,e,r,o,a){if(t!==e||n!==r){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:Bn(t,e)},{i:s-2,x:Bn(n,r)})}else 1===e&&1===r||o.push(i(o)+"scale("+e+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,u),o=a=null,function(t){for(var n,e=-1,r=u.length;++e=0&&(t=t.slice(0,n)),!t||"start"===t}))}(n)?Zt:Kt;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(n,e),a.on=i}}var me=_t.prototype.constructor;function xe(t){return function(){this.style.removeProperty(t)}}function we(t,n,e){return function(r){this.style.setProperty(t,n.call(this,r),e)}}function be(t,n,e){var r,i;function o(){var o=n.apply(this,arguments);return o!==i&&(r=(i=o)&&we(t,o,e)),r}return o._value=n,o}function Me(t){return function(n){this.textContent=t.call(this,n)}}function ke(t){var n,e;function r(){var r=t.apply(this,arguments);return r!==e&&(n=(e=r)&&Me(r)),n}return r._value=t,r}var Ae=0;function Se(t,n,e,r){this._groups=t,this._parents=n,this._name=e,this._id=r}function Te(t){return _t().transition(t)}function Ne(){return++Ae}var Ce=_t.prototype;Se.prototype=Te.prototype={constructor:Se,select:function(t){var n=this._name,e=this._id;"function"!=typeof t&&(t=d(t));for(var r=this._groups,i=r.length,o=new Array(i),a=0;an?1:t>=n?0:NaN}function Xe(t){var n;return 1===t.length&&(n=t,t=function(t,e){return qe(n(t),e)}),{left:function(n,e,r,i){for(null==r&&(r=0),null==i&&(i=n.length);r>>1;t(n[o],e)<0?r=o+1:i=o}return r},right:function(n,e,r,i){for(null==r&&(r=0),null==i&&(i=n.length);r>>1;t(n[o],e)>0?i=o:r=o+1}return r}}}_t.prototype.interrupt=function(t){return this.each((function(){!function(t,n){var e,r,i,o=t.__transition,a=!0;if(o){for(i in n=null==n?null:n+"",o)(e=o[i]).name===n?(r=e.state>2&&e.state<5,e.state=6,e.timer.stop(),e.on.call(r?"interrupt":"cancel",t,t.__data__,e.index,e.group),delete o[i]):a=!1;a&&delete t.__transition}}(this,t)}))},_t.prototype.transition=function(t){var n,e;t instanceof Se?(n=t._id,t=t._name):(n=Ne(),(e=Ee).time=It(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o=0?(o>=Ge?10:o>=Ve?5:o>=Ye?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(o>=Ge?10:o>=Ve?5:o>=Ye?2:1)}function We(t,n){var e,r,i=t.length,o=-1;if(null==n){for(;++o=e)for(r=e;++or&&(r=e)}else for(;++o=e)for(r=e;++or&&(r=e);return r}function Ze(t,n){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(n).domain(t)}return this}function Ke(){}function Qe(t,n){var e=new Ke;if(t instanceof Ke)t.each((function(t,n){e.set(n,t)}));else if(Array.isArray(t)){var r,i=-1,o=t.length;if(null==n)for(;++ir&&(n=e,e=r,r=n),function(t){return Math.max(e,Math.min(r,t))}}function hr(t,n,e){var r=t[0],i=t[1],o=n[0],a=n[1];return i2?cr:hr,i=o=null,c}function c(n){return isNaN(n=+n)?e:(i||(i=r(a.map(t),s,u)))(t(l(n)))}return c.invert=function(e){return l(n((o||(o=r(s,a.map(t),Bn)))(e)))},c.domain=function(t){return arguments.length?(a=er.call(t,or),l===sr||(l=lr(a)),h()):a.slice()},c.range=function(t){return arguments.length?(s=rr.call(t),h()):s.slice()},c.rangeRound=function(t){return s=rr.call(t),u=qn,h()},c.clamp=function(t){return arguments.length?(l=t?lr(a):sr,c):l!==sr},c.interpolate=function(t){return arguments.length?(u=t,h()):u},c.unknown=function(t){return arguments.length?(e=t,c):e},function(e,r){return t=e,n=r,h()}}()(t,n)}function pr(t,n){if((e=(t=n?t.toExponential(n-1):t.toExponential()).indexOf("e"))<0)return null;var e,r=t.slice(0,e);return[r.length>1?r[0]+r.slice(2):r,+t.slice(e+1)]}function gr(t){return(t=pr(Math.abs(t)))?t[1]:NaN}var _r,vr=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function yr(t){if(!(n=vr.exec(t)))throw new Error("invalid format: "+t);var n;return new mr({fill:n[1],align:n[2],sign:n[3],symbol:n[4],zero:n[5],width:n[6],comma:n[7],precision:n[8]&&n[8].slice(1),trim:n[9],type:n[10]})}function mr(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function xr(t,n){var e=pr(t,n);if(!e)return t+"";var r=e[0],i=e[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}yr.prototype=mr.prototype,mr.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var wr={"%":function(t,n){return(100*t).toFixed(n)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,n){return t.toExponential(n)},f:function(t,n){return t.toFixed(n)},g:function(t,n){return t.toPrecision(n)},o:function(t){return Math.round(t).toString(8)},p:function(t,n){return xr(100*t,n)},r:xr,s:function(t,n){var e=pr(t,n);if(!e)return t+"";var r=e[0],i=e[1],o=i-(_r=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+pr(t,Math.max(0,n+o-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}};function br(t){return t}var Mr,kr,Ar,Sr=Array.prototype.map,Tr=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Nr(t){var n,e,r=void 0===t.grouping||void 0===t.thousands?br:(n=Sr.call(t.grouping,Number),e=t.thousands+"",function(t,r){for(var i=t.length,o=[],a=0,s=n[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(t.substring(i-=s,i+s)),!((u+=s+1)>r));)s=n[a=(a+1)%n.length];return o.reverse().join(e)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?br:function(t){return function(n){return n.replace(/[0-9]/g,(function(n){return t[+n]}))}}(Sr.call(t.numerals,String)),u=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"-":t.minus+"",h=void 0===t.nan?"NaN":t.nan+"";function c(t){var n=(t=yr(t)).fill,e=t.align,c=t.sign,f=t.symbol,d=t.zero,p=t.width,g=t.comma,_=t.precision,v=t.trim,y=t.type;"n"===y?(g=!0,y="g"):wr[y]||(void 0===_&&(_=12),v=!0,y="g"),(d||"0"===n&&"="===e)&&(d=!0,n="0",e="=");var m="$"===f?i:"#"===f&&/[boxX]/.test(y)?"0"+y.toLowerCase():"",x="$"===f?o:/[%p]/.test(y)?u:"",w=wr[y],b=/[defgprs%]/.test(y);function M(t){var i,o,u,f=m,M=x;if("c"===y)M=w(t)+M,t="";else{var k=(t=+t)<0||1/t<0;if(t=isNaN(t)?h:w(Math.abs(t),_),v&&(t=function(t){t:for(var n,e=t.length,r=1,i=-1;r0&&(i=0)}return i>0?t.slice(0,i)+t.slice(n+1):t}(t)),k&&0==+t&&"+"!==c&&(k=!1),f=(k?"("===c?c:l:"-"===c||"("===c?"":c)+f,M=("s"===y?Tr[8+_r/3]:"")+M+(k&&"("===c?")":""),b)for(i=-1,o=t.length;++i(u=t.charCodeAt(i))||u>57){M=(46===u?a+t.slice(i+1):t.slice(i))+M,t=t.slice(0,i);break}}g&&!d&&(t=r(t,1/0));var A=f.length+t.length+M.length,S=A>1)+f+t+M+S.slice(A);break;default:t=S+f+t+M}return s(t)}return _=void 0===_?6:/[gprs]/.test(y)?Math.max(1,Math.min(21,_)):Math.max(0,Math.min(20,_)),M.toString=function(){return t+""},M}return{format:c,formatPrefix:function(t,n){var e=c(((t=yr(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(gr(n)/3))),i=Math.pow(10,-r),o=Tr[8+r/3];return function(t){return e(i*t)+o}}}}function Cr(t,n,e,r){var i,o=function(t,n,e){var r=Math.abs(n-t)/Math.max(0,e),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),o=r/i;return o>=Ge?i*=10:o>=Ve?i*=5:o>=Ye&&(i*=2),n0)return[t];if((r=n0)for(t=Math.ceil(t/a),n=Math.floor(n/a),o=new Array(i=Math.ceil(n-t+1));++s0?r=Ue(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,e):r<0&&(r=Ue(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,e)),r>0?(i[o]=Math.floor(s/r)*r,i[a]=Math.ceil(u/r)*r,n(i)):r<0&&(i[o]=Math.ceil(s*r)/r,i[a]=Math.floor(u*r)/r,n(i)),t},t}function Hr(){var t=dr(sr,sr);return t.copy=function(){return fr(t,Hr())},Ze.apply(t,arguments),Er(t)}function Lr(){it.stopImmediatePropagation()}function Dr(){it.preventDefault(),it.stopImmediatePropagation()}function Fr(t){var n=t.document.documentElement,e=vt(t).on("dragstart.drag",Dr,!0);"onselectstart"in n?e.on("selectstart.drag",Dr,!0):(n.__noselect=n.style.MozUserSelect,n.style.MozUserSelect="none")}function Pr(t){return function(){return t}}function Br(t,n,e,r,i,o,a,s,u,l){this.target=t,this.type=n,this.subject=e,this.identifier=r,this.active=i,this.x=o,this.y=a,this.dx=s,this.dy=u,this._=l}function Or(){return!it.ctrlKey&&!it.button}function zr(){return this.parentNode}function Ir(t){return null==t?{x:it.x,y:it.y}:t}function jr(){return navigator.maxTouchPoints||"ontouchstart"in this}function Rr(){var t,n,e,r,i=Or,o=zr,a=Ir,s=jr,u={},l=kt("start","drag","end"),h=0,c=0;function f(t){t.on("mousedown.drag",d).filter(s).on("touchstart.drag",_).on("touchmove.drag",v).on("touchend.drag touchcancel.drag",y).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function d(){if(!r&&i.apply(this,arguments)){var a=m("mouse",o.apply(this,arguments),xt,this,arguments);a&&(vt(it.view).on("mousemove.drag",p,!0).on("mouseup.drag",g,!0),Fr(it.view),Lr(),e=!1,t=it.clientX,n=it.clientY,a("start"))}}function p(){if(Dr(),!e){var r=it.clientX-t,i=it.clientY-n;e=r*r+i*i>c}u.mouse("drag")}function g(){vt(it.view).on("mousemove.drag mouseup.drag",null),function(t,n){var e=t.document.documentElement,r=vt(t).on("dragstart.drag",null);n&&(r.on("click.drag",Dr,!0),setTimeout((function(){r.on("click.drag",null)}),0)),"onselectstart"in e?r.on("selectstart.drag",null):(e.style.MozUserSelect=e.__noselect,delete e.__noselect)}(it.view,e),Dr(),u.mouse("end")}function _(){if(i.apply(this,arguments)){var t,n,e=it.changedTouches,r=o.apply(this,arguments),a=e.length;for(t=0;t1e-6)if(Math.abs(h*s-u*l)>1e-6&&i){var f=e-o,d=r-a,p=s*s+u*u,g=f*f+d*d,_=Math.sqrt(p),v=Math.sqrt(c),y=i*Math.tan((Qr-Math.acos((p+c-g)/(2*_*v)))/2),m=y/v,x=y/_;Math.abs(m-1)>1e-6&&(this._+="L"+(t+m*l)+","+(n+m*h)),this._+="A"+i+","+i+",0,0,"+ +(h*f>l*d)+","+(this._x1=t+x*s)+","+(this._y1=n+x*u)}else this._+="L"+(this._x1=t)+","+(this._y1=n);else;},arc:function(t,n,e,r,i,o){t=+t,n=+n,o=!!o;var a=(e=+e)*Math.cos(r),s=e*Math.sin(r),u=t+a,l=n+s,h=1^o,c=o?r-i:i-r;if(e<0)throw new Error("negative radius: "+e);null===this._x1?this._+="M"+u+","+l:(Math.abs(this._x1-u)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+u+","+l),e&&(c<0&&(c=c%Jr+Jr),c>ti?this._+="A"+e+","+e+",0,1,"+h+","+(t-a)+","+(n-s)+"A"+e+","+e+",0,1,"+h+","+(this._x1=u)+","+(this._y1=l):c>1e-6&&(this._+="A"+e+","+e+",0,"+ +(c>=Qr)+","+h+","+(this._x1=t+e*Math.cos(i))+","+(this._y1=n+e*Math.sin(i))))},rect:function(t,n,e,r){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+n)+"h"+ +e+"v"+ +r+"h"+-e+"Z"},toString:function(){return this._}};var ii=Math.PI,oi=2*ii;function ai(t){this._context=t}function si(t){return new ai(t)}function ui(t){return t[0]}function li(t){return t[1]}function hi(){var t=ui,n=li,e=ri(!0),r=null,i=si,o=null;function a(a){var s,u,l,h=a.length,c=!1;for(null==r&&(o=i(l=ei())),s=0;s<=h;++s)!(s=t.length)&&(this.options.selectedAttributeIdx=0),this._removeMarkedSegmentsOnMap(),this._resetDrag(!0),this._data=t,this._init_options(),this._prepareData(),this._calculateElevationBounds(),this._appendScales(),this._appendGrid(),0!==Object.keys(t).length&&this._createChart(this.options.selectedAttributeIdx),this._createSelectionBox()},resize:function(t){t.width&&(this.options.width=t.width),t.height&&(this.options.height=t.height),vt(this._container).selectAll("svg").attr("width",this.options.width).attr("height",this.options.height),this._addData(this._data)},_initToggle:function(){t.Browser.touch?t.DomEvent.on(this._container,"click",t.DomEvent.stopPropagation):t.DomEvent.disableClickPropagation(this._container),this.options.expandControls&&(t.DomEvent.on(this._button,"click",this._expand,this),t.DomEvent.on(this._closeButton,"click",this._expand,this))},_dragHandler:function(){"undefined"!=typeof event&&(event.preventDefault(),event.stopPropagation()),this._gotDragged=!0,this._drawDragRectangle()},_drawDragRectangle:function(){if(this._dragStartCoords){var t=this._dragCurrentCoords=this._dragCache.end=xt(this._background.node()),n=Math.min(this._dragStartCoords[0],t[0]),e=Math.max(this._dragStartCoords[0],t[0]);if(this._dragRectangle||this._dragRectangleG)this._dragRectangle.attr("width",e-n).attr("x",n);else{var r=vt(this._container).select("svg").select("g");this._dragRectangleG=r.append("g"),this._dragRectangle=this._dragRectangleG.append("rect").attr("width",e-n).attr("height",this._svgHeight).attr("x",n).attr("class","mouse-drag").style("fill","grey").style("opacity",.5).style("pointer-events","none")}}},_resetDrag:function(t){if(this._dragRectangleG&&(this._dragRectangleG.remove(),this._dragRectangleG=null,this._dragRectangle=null,!0!==t)){var n=this._calculateFullExtent(this._areasFlattended);n&&this._map.fitBounds(n)}},_dragEndHandler:function(){if(!this._dragStartCoords||!this._gotDragged)return this._dragStartCoords=null,this._gotDragged=!1,void this._resetDrag();var t=this._findItemForX(this._dragStartCoords[0]),n=this._findItemForX(this._dragCurrentCoords[0]);this._fitSection(t,n),this._dragStartCoords=null,this._gotDragged=!1},_dragStartHandler:function(){event.preventDefault(),event.stopPropagation(),this._gotDragged=!1,this._dragStartCoords=this._dragCache.start=xt(this._background.node())},_calculateFullExtent:function(n){if(!n||n.length<1)return null;var e=new t.latLngBounds(n[0].latlng,n[0].latlng);return n.forEach((function(t){e.contains(t.latlng)||e.extend(t.latlng)})),e},_fitSection:function(t,n){var e,r=Math.min(t,n),i=Math.max(t,n);r!==i?e=this._calculateFullExtent(this._areasFlattended.slice(r,i+1)):this._areasFlattended.length>0&&(e=[this._areasFlattended[r].latlng,this._areasFlattended[i].latlng]),e&&this._map.fitBounds(e)},_expand:function(){!0!==this.options.expandControls&&(this._showState=!1),this._showState?(vt(this._button).style("display","block"),vt(this._container).selectAll("svg").style("display","none"),vt(this._closeButton).style("display","none")):(vt(this._button).style("display","none"),vt(this._container).selectAll("svg").style("display","block"),vt(this._closeButton).style("display","block")),this._showState=!this._showState,"function"==typeof this.options.expandCallback&&this.options.expandCallback(this._showState)},_removeChart:function(){void 0!==this._svg&&(this._svg.selectAll("path.area").remove(),this._svg.selectAll("path.border-top").remove(),this._svg.selectAll(".legend").remove(),this._svg.selectAll(".lineSelection").remove(),this._svg.selectAll(".horizontalLine").remove(),this._svg.selectAll(".horizontalLineText").remove())},_randomNumber:function(t){return Math.round(Math.random()*(t-0))},_d3ColorCategorical:[xi,wi,Mi,mi,ki,bi],_prepareData:function(){this._coordinates=[],this._elevations=[],this._cumulatedDistances=[],this._cumulatedDistances.push(0),this._categories=[];var n,e=this._data;if(void 0===this._mappings){var r=this._randomNumber(this._d3ColorCategorical.length-1);n=function t(){var n=Qe(),e=[],r=[],i=ir;function o(t){var o=t+"",a=n.get(o);if(!a){if(i!==ir)return i;n.set(o,a=e.push(t))}return r[(a-1)%r.length]}return o.domain=function(t){if(!arguments.length)return e.slice();e=[],n=Qe();for(var r,i,a=-1,s=t.length;++a=e)for(r=e;++oe&&(r=e)}else for(;++o=e)for(r=e;++oe&&(r=e);return r}(this._elevations),e=t-n;this._elevationBounds={min:e<10?n-10:n-.1*e,max:e<10?t+10:t+.1*e}},_showMapMarker:function(t,n,e){var r=this._map.latLngToLayerPoint(t),i=r.y-75;if(!this._mouseHeightFocus){var o=vt(".leaflet-overlay-pane svg").append("g");this._mouseHeightFocus=o.append("svg:line").attr("class","height-focus line").attr("x2","0").attr("y2","0").attr("x1","0").attr("y1","0"),this._mouseHeightFocusLabel=o.append("g").attr("class","height-focus label"),this._mouseHeightFocusLabelRect=this._mouseHeightFocusLabel.append("rect").attr("class","bBox"),this._mouseHeightFocusLabelTextElev=this._mouseHeightFocusLabel.append("text").attr("class","tspan"),this._mouseHeightFocusLabelTextType=this._mouseHeightFocusLabel.append("text").attr("class","tspan"),(this._pointG=o.append("g").attr("class","height-focus circle")).append("svg:circle").attr("r",5).attr("cx",0).attr("cy",0).attr("class","height-focus circle-lower")}this._mouseHeightFocusLabel.style("display","block"),this._mouseHeightFocus.attr("x1",r.x).attr("x2",r.x).attr("y1",r.y).attr("y2",i).style("display","block"),this._pointG.attr("transform","translate("+r.x+","+r.y+")").style("display","block"),this._mouseHeightFocusLabelRect.attr("x",r.x+3).attr("y",i).attr("class","bBox"),this._mouseHeightFocusLabelTextElev.attr("x",r.x+5).attr("y",i+12).text(n+" m").attr("class","tspan mouse-height-box-text"),this._mouseHeightFocusLabelTextType.attr("x",r.x+5).attr("y",i+24).text(e).attr("class","tspan mouse-height-box-text");var a=this._dynamicBoxSize("text.tspan")[1],s=""===e?18:30;wt(".bBox").attr("width",a+10).attr("height",s)},_createChart:function(t){var n=0===this._categories.length?[]:this._categories[t].geometries;this._areasFlattended=[].concat.apply([],n);for(var e=0;ee?e:r)+") rotate("+t.angle+")"})),vt(".horizontalLine").attr("y1",r<0?0:r>e?e:r).attr("y2",r<0?0:r>e?e:r),t._highlightedCoords=r>=e?[]:t._findCoordsForY(r),vt(".horizontalLineText").attr("y",r<=10?0:r>e?e-10:r-10).text(kr(".0f")(t._y.invert(r<0?0:r>e?e:r))+" m"),t._removeMarkedSegmentsOnMap(),t._markSegmentsOnMap(t._highlightedCoords)})).on("end",(function(n){vt(this).classed("active",!1),vt(".horizontalLine").classed("active",!1),t._removeMarkedSegmentsOnMap(),t._markSegmentsOnMap(t._highlightedCoords)})))},_markSegmentsOnMap:function(n){if(n)if(n.length>1){this._markedSegments=t.featureGroup();var e,i=o(n);try{for(i.s();!(e=i.n()).done;){var a=e.value;t.polyline(a,r(r({},this._highlightStyle),{interactive:!1})).addTo(this._markedSegments)}}catch(t){i.e(t)}finally{i.f()}this._markedSegments.addTo(this._map).bringToFront()}else this._markedSegments=t.polyline(n,this._highlightStyle).addTo(this._map)},_removeMarkedSegmentsOnMap:function(){void 0!==this._markedSegments&&this._map.removeLayer(this._markedSegments)},_appendScales:function(){var t=Boolean(this._totalDistance<=10);this._x=Hr().range([0,this._svgWidth]),this._y=Hr().range([this._svgHeight,0]),this._x.domain([0,this._totalDistance]),this._y.domain([this._elevationBounds.min,this._elevationBounds.max]),this._xAxis=Zr().scale(this._x),!0===t?this._xAxis.tickFormat((function(t){return kr(".2f")(t)+" km"})):this._xAxis.tickFormat((function(t){return kr(".0f")(t)+" km"})),this._xAxis.ticks(this.options.xTicks?Math.pow(2,this.options.xTicks):Math.round(this._svgWidth/75),"s"),this._yAxis=Kr().scale(this._y).tickFormat((function(t){return t+" m"})),this._yAxis.ticks(this.options.yTicks?Math.pow(2,this.options.yTicks):Math.round(this._svgHeight/30),"s")},_appendBackground:function(){var n=this._background=vt(this._container).select("svg").select("g").append("rect").attr("width",this._svgWidth).attr("height",this._svgHeight).style("fill","none").style("stroke","none").style("pointer-events","all").on("mousemove.focusbox",this._mousemoveHandler.bind(this)).on("mouseout.focusbox",this._mouseoutHandler.bind(this));t.Browser.android?(n.on("touchstart.drag",this._dragHandler.bind(this)).on("touchstart.drag",this._dragStartHandler.bind(this)).on("touchstart.focusbox",this._mousemoveHandler.bind(this)),t.DomEvent.on(this._container,"touchend",this._dragEndHandler,this)):(n.on("mousemove.focusbox",this._mousemoveHandler.bind(this)).on("mouseout.focusbox",this._mouseoutHandler.bind(this)).on("mousedown.drag",this._dragStartHandler.bind(this)).on("mousemove.drag",this._dragHandler.bind(this)),t.DomEvent.on(this._container,"mouseup",this._dragEndHandler,this))},_appendGrid:function(){this._svg.append("g").attr("class","grid").attr("transform","translate(0,"+this._svgHeight+")").call(this._make_x_axis().tickSize(-this._svgHeight,0,0).ticks(Math.round(this._svgWidth/75)).tickFormat("")),this._svg.append("g").attr("class","grid").call(this._make_y_axis().tickSize(-this._svgWidth,0,0).ticks(Math.round(this._svgHeight/30)).tickFormat("")),this._svg.append("g").attr("transform","translate(0,"+this._svgHeight+")").attr("class","x axis").call(this._xAxis),this._svg.append("g").attr("transform","translate(-2,0)").attr("class","y axis").call(this._yAxis)},_appendAreas:function(t,n,e){var r=this._categories[n].attributes[e].color,i=this;this._area=function(){var t=ui,n=null,e=ri(0),r=li,i=ri(!0),o=null,a=si,s=null;function u(u){var l,h,c,f,d,p=u.length,g=!1,_=new Array(p),v=new Array(p);for(null==o&&(s=a(d=ei())),l=0;l<=p;++l){if(!(l=h;--c)s.point(_[c],v[c]);s.lineEnd(),s.areaEnd()}g&&(_[l]=+t(f,l,u),v[l]=+e(f,l,u),s.point(n?+n(f,l,u):_[l],r?+r(f,l,u):v[l]))}if(d)return s=null,d+""||null}function l(){return hi().defined(i).curve(a).context(o)}return u.x=function(e){return arguments.length?(t="function"==typeof e?e:ri(+e),n=null,u):t},u.x0=function(n){return arguments.length?(t="function"==typeof n?n:ri(+n),u):t},u.x1=function(t){return arguments.length?(n=null==t?null:"function"==typeof t?t:ri(+t),u):n},u.y=function(t){return arguments.length?(e="function"==typeof t?t:ri(+t),r=null,u):e},u.y0=function(t){return arguments.length?(e="function"==typeof t?t:ri(+t),u):e},u.y1=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:ri(+t),u):r},u.lineX0=u.lineY0=function(){return l().x(t).y(e)},u.lineY1=function(){return l().x(t).y(r)},u.lineX1=function(){return l().x(n).y(e)},u.defined=function(t){return arguments.length?(i="function"==typeof t?t:ri(!!t),u):i},u.curve=function(t){return arguments.length?(a=t,null!=o&&(s=a(o)),u):a},u.context=function(t){return arguments.length?(null==t?o=s=null:s=a(o=t),u):o},u}().x((function(t){var n=i._x(t.position);return t.xDiagonalCoordinate=n,n})).y0(this._svgHeight).y1((function(t){return i._y(t.altitude)})).curve(si);this._areapath=this._svg.append("path").attr("class","area"),this._areapath.datum(t).attr("d",this._area).attr("stroke",r).styles(this._graphStyle).style("fill",r).style("pointer-events","none")},_make_x_axis:function(){return Zr().scale(this._x)},_make_y_axis:function(){return Kr().scale(this._y)},_createSelectionBox:function(){var t=this,n=vt(this._container).select("svg"),e=this._width-this._margin.right,r=this._height-this._margin.bottom+this._margin.bottom/2+6,i=[{x:e-25,y:r+3,color:"#000",type:di,id:"leftArrowSelection",angle:0},{x:e-10,y:r,color:"#000",type:di,id:"rightArrowSelection",angle:180}],o=n.selectAll(".select-symbol").data(i);o.remove(),o=n.selectAll(".select-symbol").data(i),t._data.length>1&&o.enter().append("path").merge(o).attr("class","select-symbol").attr("d",pi().type((function(t){return t.type}))).attr("transform",(function(t){return"translate("+t.x+","+t.y+") rotate("+t.angle+")"})).attr("id",(function(t){return t.id})).style("fill",(function(t){return t.color})).on("mousedown",(function(n){"rightArrowSelection"===n.id&&s(),"leftArrowSelection"===n.id&&u(),t._gotDragged=!0,t._dragStartCoords=t._dragCache.start,t._dragCurrentCoords=t._dragCache.end}));var a=function(i){if(t._selectionText&&t._selectionText.remove(),0!==t._categories.length){var o=t._categories[i].info;"function"==typeof t.options.chooseSelectionCallback&&t.options.chooseSelectionCallback(i,o);var a=[{selection:o.text}];t._selectionText=n.selectAll("selection_text").data(a).enter().append("text").attr("x",e-35).attr("y",r+4).text((function(t){return t.selection})).attr("class","select-info").attr("id","selectionText").attr("text-anchor","end")}};a(this.options.selectedAttributeIdx);var s=function(){var n=t.options.selectedAttributeIdx+=1;n===t._categories.length&&(t.options.selectedAttributeIdx=n=0),a(n),t._removeChart(),t._removeMarkedSegmentsOnMap(),t._createChart(n)},u=function(){var n=t.options.selectedAttributeIdx-=1;-1===n&&(t.options.selectedAttributeIdx=n=t._categories.length-1),a(n),t._removeChart(),t._removeMarkedSegmentsOnMap(),t._createChart(n)}},_createLegend:function(){var t=this,n=this,e=[];if(this._categories.length>0)for(var r in this._categories[this.options.selectedAttributeIdx].legend)e.push(this._categories[this.options.selectedAttributeIdx].legend[r]);var i=this._height-this._margin.bottom,o=i+this._margin.bottom/2,a=[{text:this._getTranslation("legend")}],s=this._svg.selectAll(".hlegend-hover").data(e).enter().append("g").attr("class","legend").style("display","none").attr("transform",(function(t,n){return"translate(-8,"+(14*n-28)+")"})),u=s.append("rect").attr("class","legend-rect").attr("x",15).attr("y",36).attr("width",6).attr("height",6);0!==Object.keys(this._graphStyle).length?u.styles(this._graphStyle).style("stroke",(function(t,n){return t.color})).style("fill",(function(t,n){return t.color})):u.style("stroke","black").style("fill",(function(t,n){return t.color})),s.append("text").attr("class","legend-text").attr("x",30).attr("y",42).text((function(t,e){var r=t.text;return n._boxBoundY=(i-2*i/3+7)*e,r}));var l=this._svg.selectAll(".legend-hover").data(a).enter().append("g").attr("class","legend-hover");this._showLegend=!1,l.append("text").attr("x",15).attr("y",o).attr("text-anchor","start").text((function(t,n){return t.text})).on("mouseover",(function(){wt(".legend").style("display","block")})).on("mouseleave",(function(){t._showLegend||wt(".legend").style("display","none")})).on("click",(function(){t._showLegend=!t._showLegend}))},_dynamicBoxSize:function(t){for(var n=wt(t).nodes().length,e=[],r=0;r0&&void 0!==arguments[0]?arguments[0]:1e3;this.mouseoutDelay&&window.clearTimeout(this.mouseoutDelay),this.mouseoutDelay=window.setTimeout((function(){t._mouseoutHandler()}),n)},mapMousemoveHandler:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},e=n.showMapMarker,r=void 0===e||e;if(!1!==this._areasFlattended){var i,a=null,s=2*Math.pow(100,2),u=1.1/111111,l=o(this._areasFlattended);try{for(l.s();!(i=l.n()).done;){var h=i.value,c=t.latlng.lat-h.latlng.lat,f=t.latlng.lng-h.latlng.lng;if(Math.abs(c)1&&void 0!==arguments[1])||arguments[1],r=t.altitude,i=t.position,o=t.latlng,a=t.areaIdx,s=t.type,u=this._dynamicBoxSize(".focusbox text")[1]+10;n=0===a?this._categories[this.options.selectedAttributeIdx].distances[a]:this._categories[this.options.selectedAttributeIdx].distances[a]-this._categories[this.options.selectedAttributeIdx].distances[a-1],e&&this._showMapMarker(o,r,s),this._distTspan.text(" "+i.toFixed(1)+" km"),this._altTspan.text(" "+r+" m"),this._areaTspan.text(" "+n.toFixed(1)+" km"),this._typeTspan.text(" "+s),this._focusRect.attr("width",u),this._focusLine.style("display","block").attr("x1",this._x(i)).attr("x2",this._x(i));var l=this._x(i)-(u+5),h=this._width-this._margin.left-this._margin.right;this._x(i)+uh&&this._focus.style("display","initial").attr("transform","translate("+l+","+this._y(this._elevationBounds.min)+")")},_findItemForX:function(t){var n=Xe((function(t){return t.position})).left,e=this._x.invert(t);return n(this._areasFlattended,e)},_findCoordsForY:function(t){var n=this._y.invert(t);return function(t,n){for(var e=[],r=0;r=n&&e.push(r);for(var i=[],o=0,a=0;a -1) { + resetLabels(markers, weight); + } + }); + + // Call `resetLabels` initially + resetLabels(markers, weight); + } + }) + + + function resetLabels(markers, weight) { + // Call `addLabel` for each marker with an optional weight + var j = 0; + markers.eachLayer(function(label){ + addLabel(label, j, Array.isArray(weight) ? weight[j] : weight); + j++; + }); + // Update the labelEngine + labelEngine.update(); + } + function addLabel(layer, id, weight) { + // Get container of the tooltip + var label = layer.getTooltip()._source._tooltip._container; + if (label) { + // Get bounding rectangle of the label itself + var rect = label.getBoundingClientRect(); + + // Convert the container coordinates (screen space) to Lat/lng + var bottomLeft = map.containerPointToLatLng([rect.left, rect.bottom]); + var topRight = map.containerPointToLatLng([rect.right, rect.top]); + var boundingBox = { + bottomLeft : [bottomLeft.lng, bottomLeft.lat], + topRight : [topRight.lng, topRight.lat] + }; + + // Get Weight + var wght = weight; + wght = typeof wght === 'number' ? wght : parseInt(Math.random() * (5 - 1) + 1); + // console.log(weight + " => " + wght) + + // Ingest the label into labelgun itself + labelEngine.ingestLabel( + boundingBox, + id, + wght, + label, + "Label_" + id, + false + ); + + // Add the label if it hasn't been added to the map already + if (!layer.added) { + layer.addTo(map); + layer.added = true; + } + } + } +}; + diff --git a/reference/libs/lfx-labelgun-1.0.0/labelgun.js b/reference/libs/lfx-labelgun-1.0.0/labelgun.js new file mode 100644 index 00000000..fb42a817 --- /dev/null +++ b/reference/libs/lfx-labelgun-1.0.0/labelgun.js @@ -0,0 +1,569 @@ +(function webpackUniversalModuleDefinition(root, factory) { + if(typeof exports === 'object' && typeof module === 'object') + module.exports = factory(require("rbush")); + else if(typeof define === 'function' && define.amd) + define(["rbush"], factory); + else if(typeof exports === 'object') + exports["labelgun"] = factory(require("rbush")); + else + root["labelgun"] = factory(root["rbush"]); +})(this, function(__WEBPACK_EXTERNAL_MODULE_1__) { +return /******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { +/******/ configurable: false, +/******/ enumerable: true, +/******/ get: getter +/******/ }); +/******/ } +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = ""; +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = 0); +/******/ }) +/************************************************************************/ +/******/ ([ +/* 0 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); + +var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); + +var _rbush = __webpack_require__(1); + +var _rbush2 = _interopRequireDefault(_rbush); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +/** +* @summary create a label gun instance with a hide and show label callback +* @param {function} hideLabel the function responsible for hiding the label on hide event +* @param {function} showLabel the function responsible for showing the label on show event +* @param {number} entries Higher value relates to faster insertion and slower search, and vice versa +*/ +var labelgun = function () { + function labelgun(hideLabel, showLabel, entries) { + _classCallCheck(this, labelgun); + + var usedEntries = entries || 10; + this.tree = (0, _rbush2.default)(usedEntries); + this.allLabels = {}; + this.hasChanged = []; + this.allChanged = false; + this.hideLabel = hideLabel; + this.showLabel = showLabel; + } + + /** + * @name _total + * @summary get the total hidden or shown labels in the tree + * @memberof labelgun.prototype + * @param {string} state whether to return 'hide' or 'show' state label totals + * @returns {number} total number of labels of that state + * @private + */ + + + _createClass(labelgun, [{ + key: "_total", + value: function _total(state) { + var total = 0; + for (var key in this.allLabels) { + if (this.allLabels[key].state == state) { + total += 1; + } + } + return total; + } + + /** + * @name totalShown + * @memberof labelgun + * @method + * @summary Return the total number of shown labels + * @returns {number} Return total number of labels shown + * @public + */ + + }, { + key: "totalShown", + value: function totalShown() { + return this._total("show"); + } + + /** + * @name totalHidden + * @memberof labelgun + * @method + * @summary Return the total number of hidden labels + * @returns {number} Return total number of labels hidden + * @public + */ + + }, { + key: "totalHidden", + value: function totalHidden() { + return this._total("hide"); + } + + /** + * @name getLabelsByState + * @summary Provided a state get all labels of that state + * @param {string} state - the state of the labels to get (show or hide) + * @returns {array} Labels that match the given state (show or hide) + * @private + */ + + }, { + key: "_getLabelsByState", + value: function _getLabelsByState(state) { + var labels = []; + for (var key in this.allLabels) { + if (this.allLabels[key].state == state) { + labels.push(this.allLabels[key]); + } + } + return labels; + } + + /** + * @name getHidden + * @memberof labelgun + * @method + * @summary Return an array of all the hidden labels + * @returns {array} An array of hidden labels + */ + + }, { + key: "getHidden", + value: function getHidden() { + return this._getLabelsByState("hide"); + } + + /** + * @name getShown + * @memberof labelgun + * @method + * @summary Return an array of all shown labels + * @returns {array} An array of shown label + */ + + }, { + key: "getShown", + value: function getShown() { + return this._getLabelsByState("show"); + } + + /** + * @name getCollisions + * @memberof labelgun + * @method + * @summary Return a set of collisions (hidden and shown) for a given label + * @param {string} id - the ID of the label to get + * @returns {array} The list of collisions + */ + + }, { + key: "getCollisions", + value: function getCollisions(id) { + + var label = this.allLabels[id]; + if (label === undefined) { + throw Error("Label doesn't exist :" + JSON.stringify(id)); + } + + var collisions = this.tree.search(label); + var self = collisions.indexOf(label); + + // Remove the label if it's colliding with itself + if (self !== undefined) collisions.splice(self, 1); + return collisions; + } + + /** + * @name getLabel + * @memberof labelgun + * @method + * @summary Convenience function to return a label by ID + * @param {string} id the ID of the label to get + * @returns {object} The label object for the id + */ + + }, { + key: "getLabel", + value: function getLabel(id) { + return this.allLabels[id]; + } + + /** + * @name reset + * @memberof labelgun + * @method + * @summary Destroy the collision tree and labels + * @returns {undefined} + */ + + }, { + key: "reset", + value: function reset() { + this.tree.clear(); + this.allLabels = {}; + this.hasChanged = []; + this.allChanged = false; + } + + /** + * @name _callLabelCallbacks + * @memberof labelgun + * @method + * @summary Perform the related callback for a label depending on where its state is 'show' or 'hide' + * @param {string} [forceState] - the class of which to change the label to + * @returns {undefined} + * @private + */ + + }, { + key: "_callLabelCallbacks", + value: function _callLabelCallbacks(forceState) { + for (var key in this.allLabels) { + this._callLabelStateCallback(this.allLabels[key], forceState); + } + } + + /** + * @name _callLabelStateCallback + * @summary Calls the correct callback for a particular label depending on its state (hidden or shown) + * @param {string} label the label to update + * @param {string} forceState the state of which to change the label to ('show' or 'hide') + * @returns {undefined} + * @private + */ + + }, { + key: "_callLabelStateCallback", + value: function _callLabelStateCallback(label, forceState) { + var state = forceState || label.state; + if (state === "show") this.showLabel(label); + if (state === "hide") this.hideLabel(label); + } + + /** + * @name _compareLabels + * @memberof labelgun + * @method + * @summary Calculates which labels should show and which should hide + * @returns {undefined} + * @private + */ + + }, { + key: "_compareLabels", + value: function _compareLabels() { + var _this = this; + + // Map all the labels to an array and sort based on weight + // highest to lowest + + this.orderedLabels = []; + for (var key in this.allLabels) { + this.orderedLabels.push(this.allLabels[key]); + } + this.orderedLabels.sort(this._compare); + + this.orderedLabels.forEach(function (label) { + + var collisions = _this.tree.search(label); + + if (collisions.length === 0 || label.isDragged || _this._allLower(collisions, label)) { + _this.allLabels[label.id].state = "show"; + } + }); + } + + /** + * @name _allLower + * @memberof labelgun + * @method + * @param {array} collisions - An array of collisions (label objects) + * @param {object} label - The label to check + * @summary Checks if labels are of a lower weight, currently showing, or dragged + * @returns {boolean} - Whether collision are lower or contain already shown or dragged labels + * @private + */ + + }, { + key: "_allLower", + value: function _allLower(collisions, label) { + var collision = void 0; + for (var i = 0; i < collisions.length; i++) { + collision = collisions[i]; + if (collision.state === "show" || collision.weight > label.weight || collision.isDragged) { + return false; + } + } + + return true; + } + + /** + * @name _compare + * @memberof labelgun + * @method + * @param {object} a - First object to compare + * @param {object} b - Second object to compare + * @summary Compares labels weights for sorting + * @returns {number} - The sort value + * @private + */ + + }, { + key: "_compare", + value: function _compare(a, b) { + // High to Low + return b.weight - a.weight; + } + + /** + * @name _setupLabels + * @memberof labelgun + * @method + * @summary Sets up the labels depending on whether all have changed or some have changed + * @returns {undefined} + * @private + */ + + }, { + key: "_setupLabels", + value: function _setupLabels() { + var _this2 = this; + + if (this.allChanged) { + + this.allChanged = false; + this.hasChanged = []; + this.tree.clear(); + + var labels = []; + for (var key in this.allLabels) { + this._handleLabelIngestion(key); + labels.push(this.allLabels[key]); + } + + this.tree.load(labels); + } else if (this.hasChanged.length > 0) { + + this.hasChanged.forEach(function (id) { + _this2._handleLabelIngestion(id); + _this2.tree.insert(_this2.allLabels[id]); + }); + + this.hasChanged = []; + } + } + + /** + * @name _handleLabelIngestion + * @memberof labelgun + * @method + * @summary DRY function for ingesting labels + * @returns {undefined} + * @param {string} id - ID of the label to ingest + * @private + */ + + }, { + key: "_handleLabelIngestion", + value: function _handleLabelIngestion(id) { + var label = this.allLabels[id]; + + this.ingestLabel({ + bottomLeft: [label.minX, label.minY], + topRight: [label.maxX, label.maxY] + }, label.id, label.weight, label.labelObject, label.name, label.isDragged); + } + + /** + * @name update + * @memberof labelgun + * @method + * @param {boolean} onlyChanges - Whether to only update the changes made by labelHasChanged + * @summary Sets all or some of the labels to change and reruns the whole show/hide procedure + * @returns {undefined} + */ + + }, { + key: "update", + value: function update(onlyChanges) { + + if (onlyChanges) { + this.allChanged = false; + } else { + this.allChanged = true; + } + + this._setupLabels(); + this._compareLabels(); + this._callLabelCallbacks(); + } + + /** + * @name removeLabel + * @memberof labelgun + * @method + * @param {string} id - The label id for the label to remove from the tree + * @param {object} label - The label to remove from the tree + * @summary Removes label from tree and allLabels object + * @returns {undefined} + */ + + }, { + key: "removeLabel", + value: function removeLabel(id, label) { + this.tree.remove(label || this.allLabels[id]); + delete this.allLabels[id]; + } + + /** + * @name ingestLabel + * @memberof labelgun + * @method + * @param {object} boundingBox - The bounding box object with bottomLeft and topRight properties + * @param {string} id - The idea of the label + * @param {number} weight - The weight to compareLabels in the collision resolution + * @param {object} labelObject - The object representing the actual label object from your mapping library + * @param {string} labelName - A string depicting the name of the label + * @param {boolean} isDragged - A flag to say whether the lable is being dragged + * @summary Creates a label if it does not already exist, then adds it to the tree, and renders it based on whether it can be shown + * @returns {undefined} + * @public + */ + + }, { + key: "ingestLabel", + value: function ingestLabel(boundingBox, id, weight, labelObject, labelName, isDragged) { + + // Add the new label to the tree + if (weight === undefined || weight === null) { + weight = 0; + } + + if (!boundingBox || !boundingBox.bottomLeft || !boundingBox.topRight) { + throw Error("Bounding box must be defined with bottomLeft and topRight properties"); + } + + if (typeof id !== "string" && typeof id !== "number") { + throw Error("Label IDs must be a string or a number"); + } + + // If there is already a label in the tree, remove it + var oldLabel = this.allLabels[id]; + if (oldLabel) this.removeLabel(oldLabel.id, oldLabel); + + var label = { + minX: boundingBox.bottomLeft[0], + minY: boundingBox.bottomLeft[1], + maxX: boundingBox.topRight[0], + maxY: boundingBox.topRight[1], + state: "hide", + id: id, + weight: weight, + labelObject: labelObject, + name: labelName, + isDragged: isDragged + }; + + //We just store the label into the array. The tree is built when updated + this.allLabels[label.id] = label; + } + + /** + * @name labelHasChanged + * @memberof labelgun + * @param {string} id - The id of the label that has changed in some way + * @method + * @summary Let labelgun know the label has changed in some way (i.e. it's state for example, or that it is dragged) + * @returns {undefined} + */ + + }, { + key: "labelHasChanged", + value: function labelHasChanged(id) { + if (this.hasChanged.indexOf(id) === -1) { + this.hasChanged.push(id); + } + } + }]); + + return labelgun; +}(); + +exports.default = labelgun; + +/***/ }), +/* 1 */ +/***/ (function(module, exports) { + +module.exports = __WEBPACK_EXTERNAL_MODULE_1__; + +/***/ }) +/******/ ]); +}); \ No newline at end of file diff --git a/reference/libs/lfx-labelgun-1.0.0/labelgun.min.js b/reference/libs/lfx-labelgun-1.0.0/labelgun.min.js new file mode 100644 index 00000000..1951da6f --- /dev/null +++ b/reference/libs/lfx-labelgun-1.0.0/labelgun.min.js @@ -0,0 +1 @@ +!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("rbush")):"function"==typeof define&&define.amd?define(["rbush"],t):"object"==typeof exports?exports.labelgun=t(require("rbush")):e.labelgun=t(e.rbush)}(this,function(e){return function(e){function t(l){if(a[l])return a[l].exports;var i=a[l]={i:l,l:!1,exports:{}};return e[l].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var a={};return t.m=e,t.c=a,t.d=function(e,a,l){t.o(e,a)||Object.defineProperty(e,a,{configurable:!1,enumerable:!0,get:l})},t.n=function(e){var a=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(a,"a",a),a},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=0)}([function(e,t,a){"use strict";function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(e,t){for(var a=0;at.weight||a.isDragged)return!1;return!0}},{key:"_compare",value:function(e,t){return t.weight-e.weight}},{key:"_setupLabels",value:function(){var e=this;if(this.allChanged){this.allChanged=!1,this.hasChanged=[],this.tree.clear();var t=[];for(var a in this.allLabels)this._handleLabelIngestion(a),t.push(this.allLabels[a]);this.tree.load(t)}else this.hasChanged.length>0&&(this.hasChanged.forEach(function(t){e._handleLabelIngestion(t),e.tree.insert(e.allLabels[t])}),this.hasChanged=[])}},{key:"_handleLabelIngestion",value:function(e){var t=this.allLabels[e];this.ingestLabel({bottomLeft:[t.minX,t.minY],topRight:[t.maxX,t.maxY]},t.id,t.weight,t.labelObject,t.name,t.isDragged)}},{key:"update",value:function(e){this.allChanged=!e,this._setupLabels(),this._compareLabels(),this._callLabelCallbacks()}},{key:"removeLabel",value:function(e,t){this.tree.remove(t||this.allLabels[e]),delete this.allLabels[e]}},{key:"ingestLabel",value:function(e,t,a,l,i,n){if(void 0!==a&&null!==a||(a=0),!e||!e.bottomLeft||!e.topRight)throw Error("Bounding box must be defined with bottomLeft and topRight properties");if("string"!=typeof t&&"number"!=typeof t)throw Error("Label IDs must be a string or a number");var s=this.allLabels[t];s&&this.removeLabel(s.id,s);var r={minX:e.bottomLeft[0],minY:e.bottomLeft[1],maxX:e.topRight[0],maxY:e.topRight[1],state:"hide",id:t,weight:a,labelObject:l,name:i,isDragged:n};this.allLabels[r.id]=r}},{key:"labelHasChanged",value:function(e){-1===this.hasChanged.indexOf(e)&&this.hasChanged.push(e)}}]),e}();t.default=r},function(t,a){t.exports=e}])}); \ No newline at end of file diff --git a/reference/libs/lfx-labelgun-1.0.0/rbush.min.js b/reference/libs/lfx-labelgun-1.0.0/rbush.min.js new file mode 100644 index 00000000..955b89ee --- /dev/null +++ b/reference/libs/lfx-labelgun-1.0.0/rbush.min.js @@ -0,0 +1 @@ +!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var i;i="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,i.rbush=t()}}(function(){return function t(i,n,e){function r(h,o){if(!n[h]){if(!i[h]){var s="function"==typeof require&&require;if(!o&&s)return s(h,!0);if(a)return a(h,!0);var l=new Error("Cannot find module '"+h+"'");throw l.code="MODULE_NOT_FOUND",l}var f=n[h]={exports:{}};i[h][0].call(f.exports,function(t){var n=i[h][1][t];return r(n?n:t)},f,f.exports,t,i,n,e)}return n[h].exports}for(var a="function"==typeof require&&require,h=0;h=t.minX&&i.maxY>=t.minY}function p(t){return{children:t,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-(1/0),maxY:-(1/0)}}function M(t,i,n,e,r){for(var a,h=[i,n];h.length;)n=h.pop(),i=h.pop(),n-i<=e||(a=i+Math.ceil((n-i)/e/2)*e,g(t,a,i,n,r),h.push(i,a,a,n))}i.exports=e;var g=t("quickselect");e.prototype={all:function(){return this._all(this.data,[])},search:function(t){var i=this.data,n=[],e=this.toBBox;if(!x(t,i))return n;for(var r,a,h,o,s=[];i;){for(r=0,a=i.children.length;r=0&&a[i].children.length>this._maxEntries;)this._split(a,i),i--;this._adjustParentBBoxes(r,a,i)},_split:function(t,i){var n=t[i],e=n.children.length,r=this._minEntries;this._chooseSplitAxis(n,r,e);var h=this._chooseSplitIndex(n,r,e),o=p(n.children.splice(h,n.children.length-h));o.height=n.height,o.leaf=n.leaf,a(n,this.toBBox),a(o,this.toBBox),i?t[i-1].children.push(o):this._splitRoot(n,o)},_splitRoot:function(t,i){this.data=p([t,i]),this.data.height=t.height+1,this.data.leaf=!1,a(this.data,this.toBBox)},_chooseSplitIndex:function(t,i,n){var e,r,a,o,s,l,u,c;for(l=u=1/0,e=i;e<=n-i;e++)r=h(t,0,e,this.toBBox),a=h(t,e,n,this.toBBox),o=m(r,a),s=f(r)+f(a),o=i;r--)a=t.children[r],o(f,t.leaf?s(a):a),c+=u(f);return c},_adjustParentBBoxes:function(t,i,n){for(var e=n;e>=0;e--)o(i[e],t)},_condense:function(t){for(var i,n=t.length-1;n>=0;n--)0===t[n].children.length?n>0?(i=t[n-1].children,i.splice(i.indexOf(t[n]),1)):this.clear():a(t[n],this.toBBox)},_initFormat:function(t){var i=["return a"," - b",";"];this.compareMinX=new Function("a","b",i.join(t[0])),this.compareMinY=new Function("a","b",i.join(t[1])),this.toBBox=new Function("a","return {minX: a"+t[0]+", minY: a"+t[1]+", maxX: a"+t[2]+", maxY: a"+t[3]+"};")}}},{quickselect:2}],2:[function(t,i,n){"use strict";function e(t,i,n,a,h){for(;a>n;){if(a-n>600){var o=a-n+1,s=i-n+1,l=Math.log(o),f=.5*Math.exp(2*l/3),u=.5*Math.sqrt(l*f*(o-f)/o)*(s-o/2<0?-1:1),c=Math.max(n,Math.floor(i-s*f/o+u)),m=Math.min(a,Math.floor(i+(o-s)*f/o+u));e(t,i,c,m,h)}var d=t[i],x=n,p=a;for(r(t,n,i),h(t[a],d)>0&&r(t,n,a);x0;)p--}0===h(t[n],d)?r(t,n,p):(p++,r(t,p,a)),p<=i&&(n=p+1),i<=p&&(a=p-1)}}function r(t,i,n){var e=t[i];t[i]=t[n],t[n]=e}i.exports=e},{}]},{},[1])(1)}); \ No newline at end of file diff --git a/reference/libs/lfx-movingmarker-1.0.0/MovingMarker.js b/reference/libs/lfx-movingmarker-1.0.0/MovingMarker.js new file mode 100644 index 00000000..b1c3b641 --- /dev/null +++ b/reference/libs/lfx-movingmarker-1.0.0/MovingMarker.js @@ -0,0 +1,304 @@ +L.interpolatePosition = function(p1, p2, duration, t) { + var k = t/duration; + k = (k > 0) ? k : 0; + k = (k > 1) ? 1 : k; + return L.latLng(p1.lat + k * (p2.lat - p1.lat), + p1.lng + k * (p2.lng - p1.lng)); +}; + +L.Marker.MovingMarker = L.Marker.extend({ + + //state constants + statics: { + notStartedState: 0, + endedState: 1, + pausedState: 2, + runState: 3 + }, + + options: { + autostart: false, + loop: false, + }, + + initialize: function (latlngs, durations, options) { + L.Marker.prototype.initialize.call(this, latlngs[0], options); + + this._latlngs = latlngs.map(function(e, index) { + return L.latLng(e); + }); + + if (durations instanceof Array) { + this._durations = durations; + } else { + this._durations = this._createDurations(this._latlngs, durations); + } + + this._currentDuration = 0; + this._currentIndex = 0; + + this._state = L.Marker.MovingMarker.notStartedState; + this._startTime = 0; + this._startTimeStamp = 0; // timestamp given by requestAnimFrame + this._pauseStartTime = 0; + this._animId = 0; + this._animRequested = false; + this._currentLine = []; + this._stations = {}; + }, + + isRunning: function() { + return this._state === L.Marker.MovingMarker.runState; + }, + + isEnded: function() { + return this._state === L.Marker.MovingMarker.endedState; + }, + + isStarted: function() { + return this._state !== L.Marker.MovingMarker.notStartedState; + }, + + isPaused: function() { + return this._state === L.Marker.MovingMarker.pausedState; + }, + + start: function() { + if (this.isRunning()) { + return; + } + + if (this.isPaused()) { + this.resume(); + } else { + this._loadLine(0); + this._startAnimation(); + this.fire('start'); + } + }, + + resume: function() { + if (! this.isPaused()) { + return; + } + // update the current line + this._currentLine[0] = this.getLatLng(); + this._currentDuration -= (this._pauseStartTime - this._startTime); + this._startAnimation(); + }, + + pause: function() { + if (! this.isRunning()) { + return; + } + + this._pauseStartTime = Date.now(); + this._state = L.Marker.MovingMarker.pausedState; + this._stopAnimation(); + this._updatePosition(); + }, + + stop: function(elapsedTime) { + if (this.isEnded()) { + return; + } + + this._stopAnimation(); + + if (typeof(elapsedTime) === 'undefined') { + // user call + elapsedTime = 0; + this._updatePosition(); + } + + this._state = L.Marker.MovingMarker.endedState; + this.fire('end', {elapsedTime: elapsedTime}); + }, + + addLatLng: function(latlng, duration) { + this._latlngs.push(L.latLng(latlng)); + this._durations.push(duration); + }, + + moveTo: function(latlng, duration) { + this._stopAnimation(); + this._latlngs = [this.getLatLng(), L.latLng(latlng)]; + this._durations = [duration]; + this._state = L.Marker.MovingMarker.notStartedState; + this.start(); + this.options.loop = false; + }, + + addStation: function(pointIndex, duration) { + if (pointIndex > this._latlngs.length - 2 || pointIndex < 1) { + return; + } + this._stations[pointIndex] = duration; + }, + + onAdd: function (map) { + L.Marker.prototype.onAdd.call(this, map); + + if (this.options.autostart && (! this.isStarted())) { + this.start(); + return; + } + + if (this.isRunning()) { + this._resumeAnimation(); + } + }, + + onRemove: function(map) { + L.Marker.prototype.onRemove.call(this, map); + this._stopAnimation(); + }, + + _createDurations: function (latlngs, duration) { + var lastIndex = latlngs.length - 1; + var distances = []; + var totalDistance = 0; + var distance = 0; + + // compute array of distances between points + for (var i = 0; i < lastIndex; i++) { + distance = latlngs[i + 1].distanceTo(latlngs[i]); + distances.push(distance); + totalDistance += distance; + } + + var ratioDuration = duration / totalDistance; + + var durations = []; + for (i = 0; i < distances.length; i++) { + durations.push(distances[i] * ratioDuration); + } + + return durations; + }, + + _startAnimation: function() { + this._state = L.Marker.MovingMarker.runState; + this._animId = L.Util.requestAnimFrame(function(timestamp) { + this._startTime = Date.now(); + this._startTimeStamp = timestamp; + this._animate(timestamp); + }, this, true); + this._animRequested = true; + }, + + _resumeAnimation: function() { + if (! this._animRequested) { + this._animRequested = true; + this._animId = L.Util.requestAnimFrame(function(timestamp) { + this._animate(timestamp); + }, this, true); + } + }, + + _stopAnimation: function() { + if (this._animRequested) { + L.Util.cancelAnimFrame(this._animId); + this._animRequested = false; + } + }, + + _updatePosition: function() { + var elapsedTime = Date.now() - this._startTime; + this._animate(this._startTimeStamp + elapsedTime, true); + }, + + _loadLine: function(index) { + this._currentIndex = index; + this._currentDuration = this._durations[index]; + this._currentLine = this._latlngs.slice(index, index + 2); + }, + + /** + * Load the line where the marker is + * @param {Number} timestamp + * @return {Number} elapsed time on the current line or null if + * we reached the end or marker is at a station + */ + _updateLine: function(timestamp) { + // time elapsed since the last latlng + var elapsedTime = timestamp - this._startTimeStamp; + + // not enough time to update the line + if (elapsedTime <= this._currentDuration) { + return elapsedTime; + } + + var lineIndex = this._currentIndex; + var lineDuration = this._currentDuration; + var stationDuration; + + while (elapsedTime > lineDuration) { + // substract time of the current line + elapsedTime -= lineDuration; + stationDuration = this._stations[lineIndex + 1]; + + // test if there is a station at the end of the line + if (stationDuration !== undefined) { + if (elapsedTime < stationDuration) { + this.setLatLng(this._latlngs[lineIndex + 1]); + return null; + } + elapsedTime -= stationDuration; + } + + lineIndex++; + + // test if we have reached the end of the polyline + if (lineIndex >= this._latlngs.length - 1) { + + if (this.options.loop) { + lineIndex = 0; + this.fire('loop', {elapsedTime: elapsedTime}); + } else { + // place the marker at the end, else it would be at + // the last position + this.setLatLng(this._latlngs[this._latlngs.length - 1]); + this.stop(elapsedTime); + return null; + } + } + lineDuration = this._durations[lineIndex]; + } + + this._loadLine(lineIndex); + this._startTimeStamp = timestamp - elapsedTime; + this._startTime = Date.now() - elapsedTime; + return elapsedTime; + }, + + _animate: function(timestamp, noRequestAnim) { + this._animRequested = false; + + // find the next line and compute the new elapsedTime + var elapsedTime = this._updateLine(timestamp); + + if (this.isEnded()) { + // no need to animate + return; + } + + if (elapsedTime != null) { + // compute the position + var p = L.interpolatePosition(this._currentLine[0], + this._currentLine[1], + this._currentDuration, + elapsedTime); + this.setLatLng(p); + } + + if (! noRequestAnim) { + this._animId = L.Util.requestAnimFrame(this._animate, this, false); + this._animRequested = true; + } + } +}); + +L.Marker.movingMarker = function (latlngs, duration, options) { + return new L.Marker.MovingMarker(latlngs, duration, options); +}; diff --git a/reference/libs/lfx-movingmarker-1.0.0/lfx-movingmarker-bindings.js b/reference/libs/lfx-movingmarker-1.0.0/lfx-movingmarker-bindings.js new file mode 100644 index 00000000..daa7e934 --- /dev/null +++ b/reference/libs/lfx-movingmarker-1.0.0/lfx-movingmarker-bindings.js @@ -0,0 +1,155 @@ +/* global LeafletWidget, $, L */ +LeafletWidget.methods.addMovingMarker = function( + data, duration, icon, layerId, group, options, + popup, popupOptions, label, labelOptions) { + + var map = this; + if (map.movingmarker === undefined) { + map.movingmarker = {}; + } + if (map.movingmarker[layerId]) { + delete map.movingmarker[layerId]; + } + + if (icon) { + if (icon.class == "awesome" && L.AwesomeMarkers) { + if (icon.squareMarker) { + icon.className = "awesome-marker awesome-marker-square"; + } + options.icon = new L.AwesomeMarkers.icon(icon); + } else { + if (!icon.iconUrl) { + options.icon = L.Icon.Default(); + } + if (icon.iconWidth) { + icon.iconSize = [icon.iconWidth, icon.iconHeight]; + } + if (icon.shadowWidth) { + icon.shadowSize = [icon.shadowWidth, icon.shadowHeight]; + } + if (icon.iconAnchorX) { + icon.iconAnchor = [icon.iconAnchorX, icon.iconAnchorY]; + } + if (icon.shadowAnchorX) { + icon.shadowAnchor = [icon.shadowAnchorX, icon.shadowAnchorY]; + } + if (icon.popupAnchorX) { + icon.popupAnchor = [icon.popupAnchorX, icon.popupAnchorY]; + } + options.icon = new L.Icon(icon); + } + } + + map.movingmarker[layerId] = L.Marker.movingMarker(data, duration, options).addTo(this); + + if (options.pauseOnZoom && options.pauseOnZoom === true) { + map.on('zoomstart', function() { + map.movingmarker[layerId].pause(); + }); + map.on('zoomend', function() { + map.movingmarker[layerId].resume(); + }); + } + + if (popup !== null) { + map.movingmarker[layerId].bindPopup(popup, popupOptions); + } + if (label !== null) { + if (labelOptions !== null) { + if(labelOptions.permanent) { + map.movingmarker[layerId].bindTooltip(label, labelOptions).openTooltip(); + } else { + map.movingmarker[layerId].bindTooltip(label, labelOptions); + } + } else { + map.movingmarker[layerId].bindTooltip(label); + } + } + + if (HTMLWidgets.shinyMode) { + map.movingmarker[layerId].on("click", LeafletWidget.methods.mouseHandler(map.id, layerId, group, "movingmarker_click", null), map); + map.movingmarker[layerId].on("mouseover", LeafletWidget.methods.mouseHandler(map.id, layerId, group, "movingmarker_mouseover", null), map); + } + + map.layerManager.addLayer(map.movingmarker[layerId], "marker", layerId, group); +}; + + +LeafletWidget.methods.startMoving = function(layerId) { + var map = this; + layerId = getids(map, layerId); + layerId.forEach(function(id) { + if (map.movingmarker && map.movingmarker[id]) { + map.movingmarker[id].start(); + } + }) +}; + +LeafletWidget.methods.stopMoving = function(layerId) { + var map = this; + layerId = getids(map, layerId); + layerId.forEach(function(id) { + if (map.movingmarker && map.movingmarker[id]) { + map.movingmarker[id].stop(); + } + }) +}; + +LeafletWidget.methods.pauseMoving = function(layerId) { + var map = this; + layerId = getids(map, layerId); + layerId.forEach(function(id) { + if (map.movingmarker && map.movingmarker[id]) { + map.movingmarker[id].pause(); + } + }) +}; + +LeafletWidget.methods.resumeMoving = function(layerId) { + var map = this; + layerId = getids(map, layerId); + layerId.forEach(function(id) { + if (map.movingmarker && map.movingmarker[id]) { + map.movingmarker[id].resume(); + } + }) +}; + +LeafletWidget.methods.addLatLngMoving = function(layerId, latlng, duration) { + var map = this; + layerId = getids(map, layerId); + layerId.forEach(function(id) { + if (map.movingmarker && map.movingmarker[id]) { + map.movingmarker[id].addLatLng(latlng, duration); + } + }) +}; + +LeafletWidget.methods.moveToMoving = function(layerId, latlng, duration) { + var map = this; + layerId = getids(map, layerId); + layerId.forEach(function(id) { + if (map.movingmarker && map.movingmarker[id]) { + map.movingmarker[id].moveTo(latlng, duration); + } + }) +}; + +LeafletWidget.methods.addStationMoving = function(layerId, pointIndex, duration) { + var map = this; + layerId = getids(map, layerId); + layerId.forEach(function(id) { + if (map.movingmarker && map.movingmarker[id]) { + map.movingmarker[id].addStation(pointIndex, duration); + } + }) +}; + + +getids = function(map, layerId) { + if (layerId === null || layerId === undefined) { + return Object.keys(map.movingmarker) + } else { + return [].concat(layerId); + } +} diff --git a/reference/libs/lfx-timeslider-1.0.0/jquery-ui.css b/reference/libs/lfx-timeslider-1.0.0/jquery-ui.css new file mode 100644 index 00000000..9f48253d --- /dev/null +++ b/reference/libs/lfx-timeslider-1.0.0/jquery-ui.css @@ -0,0 +1,1284 @@ +f/*! jQuery UI - v1.12.1 - 2020-11-29 +* http://jqueryui.com +* Includes: draggable.css, core.css, resizable.css, selectable.css, sortable.css, accordion.css, autocomplete.css, menu.css, button.css, controlgroup.css, checkboxradio.css, datepicker.css, dialog.css, progressbar.css, selectmenu.css, slider.css, spinner.css, tabs.css, tooltip.css, theme.css +* To view and modify this theme, visit http://jqueryui.com/themeroller/?scope=&folderName=base&cornerRadiusShadow=8px&offsetLeftShadow=0px&offsetTopShadow=0px&thicknessShadow=5px&opacityShadow=30&bgImgOpacityShadow=0&bgTextureShadow=flat&bgColorShadow=666666&opacityOverlay=30&bgImgOpacityOverlay=0&bgTextureOverlay=flat&bgColorOverlay=aaaaaa&iconColorError=cc0000&fcError=5f3f3f&borderColorError=f1a899&bgTextureError=flat&bgColorError=fddfdf&iconColorHighlight=777620&fcHighlight=777620&borderColorHighlight=dad55e&bgTextureHighlight=flat&bgColorHighlight=fffa90&iconColorActive=ffffff&fcActive=ffffff&borderColorActive=003eff&bgTextureActive=flat&bgColorActive=007fff&iconColorHover=555555&fcHover=2b2b2b&borderColorHover=cccccc&bgTextureHover=flat&bgColorHover=ededed&iconColorDefault=777777&fcDefault=454545&borderColorDefault=c5c5c5&bgTextureDefault=flat&bgColorDefault=f6f6f6&iconColorContent=444444&fcContent=333333&borderColorContent=dddddd&bgTextureContent=flat&bgColorContent=ffffff&iconColorHeader=444444&fcHeader=333333&borderColorHeader=dddddd&bgTextureHeader=flat&bgColorHeader=e9e9e9&cornerRadius=3px&fwDefault=normal&fsDefault=1em&ffDefault=Arial%2CHelvetica%2Csans-serif +* Copyright jQuery Foundation and other contributors; Licensed MIT */ + +.ui-draggable-handle { + -ms-touch-action: none; + touch-action: none; +} +/* Layout helpers +----------------------------------*/ +.ui-helper-hidden { + display: none; +} +.ui-helper-hidden-accessible { + border: 0; + clip: rect(0 0 0 0); + height: 1px; + margin: -1px; + overflow: hidden; + padding: 0; + position: absolute; + width: 1px; +} +.ui-helper-reset { + margin: 0; + padding: 0; + border: 0; + outline: 0; + line-height: 1.3; + text-decoration: none; + font-size: 100%; + list-style: none; +} +.ui-helper-clearfix:before, +.ui-helper-clearfix:after { + content: ""; + display: table; + border-collapse: collapse; +} +.ui-helper-clearfix:after { + clear: both; +} +.ui-helper-zfix { + width: 100%; + height: 100%; + top: 0; + left: 0; + position: absolute; + opacity: 0; + filter:Alpha(Opacity=0); /* support: IE8 */ +} + +.ui-front { + z-index: 100; +} + + +/* Interaction Cues +----------------------------------*/ +.ui-state-disabled { + cursor: default !important; + pointer-events: none; +} + + +/* Icons +----------------------------------*/ +.ui-icon { + display: inline-block; + vertical-align: middle; + margin-top: -.25em; + position: relative; + text-indent: -99999px; + overflow: hidden; + background-repeat: no-repeat; +} + +.ui-widget-icon-block { + left: 50%; + margin-left: -8px; + display: block; +} + +/* Misc visuals +----------------------------------*/ + +/* Overlays */ +.ui-widget-overlay { + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; +} +.ui-resizable { + position: relative; +} +.ui-resizable-handle { + position: absolute; + font-size: 0.1px; + display: block; + -ms-touch-action: none; + touch-action: none; +} +.ui-resizable-disabled .ui-resizable-handle, +.ui-resizable-autohide .ui-resizable-handle { + display: none; +} +.ui-resizable-n { + cursor: n-resize; + height: 7px; + width: 100%; + top: -5px; + left: 0; +} +.ui-resizable-s { + cursor: s-resize; + height: 7px; + width: 100%; + bottom: -5px; + left: 0; +} +.ui-resizable-e { + cursor: e-resize; + width: 7px; + right: -5px; + top: 0; + height: 100%; +} +.ui-resizable-w { + cursor: w-resize; + width: 7px; + left: -5px; + top: 0; + height: 100%; +} +.ui-resizable-se { + cursor: se-resize; + width: 12px; + height: 12px; + right: 1px; + bottom: 1px; +} +.ui-resizable-sw { + cursor: sw-resize; + width: 9px; + height: 9px; + left: -5px; + bottom: -5px; +} +.ui-resizable-nw { + cursor: nw-resize; + width: 9px; + height: 9px; + left: -5px; + top: -5px; +} +.ui-resizable-ne { + cursor: ne-resize; + width: 9px; + height: 9px; + right: -5px; + top: -5px; +} +.ui-selectable { + -ms-touch-action: none; + touch-action: none; +} +.ui-selectable-helper { + position: absolute; + z-index: 100; + border: 1px dotted black; +} +.ui-sortable-handle { + -ms-touch-action: none; + touch-action: none; +} +.ui-accordion .ui-accordion-header { + display: block; + cursor: pointer; + position: relative; + margin: 2px 0 0 0; + padding: .5em .5em .5em .7em; + font-size: 100%; +} +.ui-accordion .ui-accordion-content { + padding: 1em 2.2em; + border-top: 0; + overflow: auto; +} +.ui-autocomplete { + position: absolute; + top: 0; + left: 0; + cursor: default; +} +.ui-menu { + list-style: none; + padding: 0; + margin: 0; + display: block; + outline: 0; +} +.ui-menu .ui-menu { + position: absolute; +} +.ui-menu .ui-menu-item { + margin: 0; + cursor: pointer; + /* support: IE10, see #8844 */ + list-style-image: url("data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"); +} +.ui-menu .ui-menu-item-wrapper { + position: relative; + padding: 3px 1em 3px .4em; +} +.ui-menu .ui-menu-divider { + margin: 5px 0; + height: 0; + font-size: 0; + line-height: 0; + border-width: 1px 0 0 0; +} +.ui-menu .ui-state-focus, +.ui-menu .ui-state-active { + margin: -1px; +} + +/* icon support */ +.ui-menu-icons { + position: relative; +} +.ui-menu-icons .ui-menu-item-wrapper { + padding-left: 2em; +} + +/* left-aligned */ +.ui-menu .ui-icon { + position: absolute; + top: 0; + bottom: 0; + left: .2em; + margin: auto 0; +} + +/* right-aligned */ +.ui-menu .ui-menu-icon { + left: auto; + right: 0; +} +.ui-button { + padding: .4em 1em; + display: inline-block; + position: relative; + line-height: normal; + margin-right: .1em; + cursor: pointer; + vertical-align: middle; + text-align: center; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + + /* Support: IE <= 11 */ + overflow: visible; +} + +.ui-button, +.ui-button:link, +.ui-button:visited, +.ui-button:hover, +.ui-button:active { + text-decoration: none; +} + +/* to make room for the icon, a width needs to be set here */ +.ui-button-icon-only { + width: 2em; + box-sizing: border-box; + text-indent: -9999px; + white-space: nowrap; +} + +/* no icon support for input elements */ +input.ui-button.ui-button-icon-only { + text-indent: 0; +} + +/* button icon element(s) */ +.ui-button-icon-only .ui-icon { + position: absolute; + top: 50%; + left: 50%; + margin-top: -8px; + margin-left: -8px; +} + +.ui-button.ui-icon-notext .ui-icon { + padding: 0; + width: 2.1em; + height: 2.1em; + text-indent: -9999px; + white-space: nowrap; + +} + +input.ui-button.ui-icon-notext .ui-icon { + width: auto; + height: auto; + text-indent: 0; + white-space: normal; + padding: .4em 1em; +} + +/* workarounds */ +/* Support: Firefox 5 - 40 */ +input.ui-button::-moz-focus-inner, +button.ui-button::-moz-focus-inner { + border: 0; + padding: 0; +} +.ui-controlgroup { + vertical-align: middle; + display: inline-block; +} +.ui-controlgroup > .ui-controlgroup-item { + float: left; + margin-left: 0; + margin-right: 0; +} +.ui-controlgroup > .ui-controlgroup-item:focus, +.ui-controlgroup > .ui-controlgroup-item.ui-visual-focus { + z-index: 9999; +} +.ui-controlgroup-vertical > .ui-controlgroup-item { + display: block; + float: none; + width: 100%; + margin-top: 0; + margin-bottom: 0; + text-align: left; +} +.ui-controlgroup-vertical .ui-controlgroup-item { + box-sizing: border-box; +} +.ui-controlgroup .ui-controlgroup-label { + padding: .4em 1em; +} +.ui-controlgroup .ui-controlgroup-label span { + font-size: 80%; +} +.ui-controlgroup-horizontal .ui-controlgroup-label + .ui-controlgroup-item { + border-left: none; +} +.ui-controlgroup-vertical .ui-controlgroup-label + .ui-controlgroup-item { + border-top: none; +} +.ui-controlgroup-horizontal .ui-controlgroup-label.ui-widget-content { + border-right: none; +} +.ui-controlgroup-vertical .ui-controlgroup-label.ui-widget-content { + border-bottom: none; +} + +/* Spinner specific style fixes */ +.ui-controlgroup-vertical .ui-spinner-input { + + /* Support: IE8 only, Android < 4.4 only */ + width: 75%; + width: calc( 100% - 2.4em ); +} +.ui-controlgroup-vertical .ui-spinner .ui-spinner-up { + border-top-style: solid; +} + +.ui-checkboxradio-label .ui-icon-background { + box-shadow: inset 1px 1px 1px #ccc; + border-radius: .12em; + border: none; +} +.ui-checkboxradio-radio-label .ui-icon-background { + width: 16px; + height: 16px; + border-radius: 1em; + overflow: visible; + border: none; +} +.ui-checkboxradio-radio-label.ui-checkboxradio-checked .ui-icon, +.ui-checkboxradio-radio-label.ui-checkboxradio-checked:hover .ui-icon { + background-image: none; + width: 8px; + height: 8px; + border-width: 4px; + border-style: solid; +} +.ui-checkboxradio-disabled { + pointer-events: none; +} +.ui-datepicker { + width: 17em; + padding: .2em .2em 0; + display: none; +} +.ui-datepicker .ui-datepicker-header { + position: relative; + padding: .2em 0; +} +.ui-datepicker .ui-datepicker-prev, +.ui-datepicker .ui-datepicker-next { + position: absolute; + top: 2px; + width: 1.8em; + height: 1.8em; +} +.ui-datepicker .ui-datepicker-prev-hover, +.ui-datepicker .ui-datepicker-next-hover { + top: 1px; +} +.ui-datepicker .ui-datepicker-prev { + left: 2px; +} +.ui-datepicker .ui-datepicker-next { + right: 2px; +} +.ui-datepicker .ui-datepicker-prev-hover { + left: 1px; +} +.ui-datepicker .ui-datepicker-next-hover { + right: 1px; +} +.ui-datepicker .ui-datepicker-prev span, +.ui-datepicker .ui-datepicker-next span { + display: block; + position: absolute; + left: 50%; + margin-left: -8px; + top: 50%; + margin-top: -8px; +} +.ui-datepicker .ui-datepicker-title { + margin: 0 2.3em; + line-height: 1.8em; + text-align: center; +} +.ui-datepicker .ui-datepicker-title select { + font-size: 1em; + margin: 1px 0; +} +.ui-datepicker select.ui-datepicker-month, +.ui-datepicker select.ui-datepicker-year { + width: 45%; +} +.ui-datepicker table { + width: 100%; + font-size: .9em; + border-collapse: collapse; + margin: 0 0 .4em; +} +.ui-datepicker th { + padding: .7em .3em; + text-align: center; + font-weight: bold; + border: 0; +} +.ui-datepicker td { + border: 0; + padding: 1px; +} +.ui-datepicker td span, +.ui-datepicker td a { + display: block; + padding: .2em; + text-align: right; + text-decoration: none; +} +.ui-datepicker .ui-datepicker-buttonpane { + background-image: none; + margin: .7em 0 0 0; + padding: 0 .2em; + border-left: 0; + border-right: 0; + border-bottom: 0; +} +.ui-datepicker .ui-datepicker-buttonpane button { + float: right; + margin: .5em .2em .4em; + cursor: pointer; + padding: .2em .6em .3em .6em; + width: auto; + overflow: visible; +} +.ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current { + float: left; +} + +/* with multiple calendars */ +.ui-datepicker.ui-datepicker-multi { + width: auto; +} +.ui-datepicker-multi .ui-datepicker-group { + float: left; +} +.ui-datepicker-multi .ui-datepicker-group table { + width: 95%; + margin: 0 auto .4em; +} +.ui-datepicker-multi-2 .ui-datepicker-group { + width: 50%; +} +.ui-datepicker-multi-3 .ui-datepicker-group { + width: 33.3%; +} +.ui-datepicker-multi-4 .ui-datepicker-group { + width: 25%; +} +.ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header, +.ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header { + border-left-width: 0; +} +.ui-datepicker-multi .ui-datepicker-buttonpane { + clear: left; +} +.ui-datepicker-row-break { + clear: both; + width: 100%; + font-size: 0; +} + +/* RTL support */ +.ui-datepicker-rtl { + direction: rtl; +} +.ui-datepicker-rtl .ui-datepicker-prev { + right: 2px; + left: auto; +} +.ui-datepicker-rtl .ui-datepicker-next { + left: 2px; + right: auto; +} +.ui-datepicker-rtl .ui-datepicker-prev:hover { + right: 1px; + left: auto; +} +.ui-datepicker-rtl .ui-datepicker-next:hover { + left: 1px; + right: auto; +} +.ui-datepicker-rtl .ui-datepicker-buttonpane { + clear: right; +} +.ui-datepicker-rtl .ui-datepicker-buttonpane button { + float: left; +} +.ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current, +.ui-datepicker-rtl .ui-datepicker-group { + float: right; +} +.ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header, +.ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header { + border-right-width: 0; + border-left-width: 1px; +} + +/* Icons */ +.ui-datepicker .ui-icon { + display: block; + text-indent: -99999px; + overflow: hidden; + background-repeat: no-repeat; + left: .5em; + top: .3em; +} +.ui-dialog { + position: absolute; + top: 0; + left: 0; + padding: .2em; + outline: 0; +} +.ui-dialog .ui-dialog-titlebar { + padding: .4em 1em; + position: relative; +} +.ui-dialog .ui-dialog-title { + float: left; + margin: .1em 0; + white-space: nowrap; + width: 90%; + overflow: hidden; + text-overflow: ellipsis; +} +.ui-dialog .ui-dialog-titlebar-close { + position: absolute; + right: .3em; + top: 50%; + width: 20px; + margin: -10px 0 0 0; + padding: 1px; + height: 20px; +} +.ui-dialog .ui-dialog-content { + position: relative; + border: 0; + padding: .5em 1em; + background: none; + overflow: auto; +} +.ui-dialog .ui-dialog-buttonpane { + text-align: left; + border-width: 1px 0 0 0; + background-image: none; + margin-top: .5em; + padding: .3em 1em .5em .4em; +} +.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset { + float: right; +} +.ui-dialog .ui-dialog-buttonpane button { + margin: .5em .4em .5em 0; + cursor: pointer; +} +.ui-dialog .ui-resizable-n { + height: 2px; + top: 0; +} +.ui-dialog .ui-resizable-e { + width: 2px; + right: 0; +} +.ui-dialog .ui-resizable-s { + height: 2px; + bottom: 0; +} +.ui-dialog .ui-resizable-w { + width: 2px; + left: 0; +} +.ui-dialog .ui-resizable-se, +.ui-dialog .ui-resizable-sw, +.ui-dialog .ui-resizable-ne, +.ui-dialog .ui-resizable-nw { + width: 7px; + height: 7px; +} +.ui-dialog .ui-resizable-se { + right: 0; + bottom: 0; +} +.ui-dialog .ui-resizable-sw { + left: 0; + bottom: 0; +} +.ui-dialog .ui-resizable-ne { + right: 0; + top: 0; +} +.ui-dialog .ui-resizable-nw { + left: 0; + top: 0; +} +.ui-draggable .ui-dialog-titlebar { + cursor: move; +} +.ui-progressbar { + height: 2em; + text-align: left; + overflow: hidden; +} +.ui-progressbar .ui-progressbar-value { + margin: -1px; + height: 100%; +} +.ui-progressbar .ui-progressbar-overlay { + background: url("data:image/gif;base64,R0lGODlhKAAoAIABAAAAAP///yH/C05FVFNDQVBFMi4wAwEAAAAh+QQJAQABACwAAAAAKAAoAAACkYwNqXrdC52DS06a7MFZI+4FHBCKoDeWKXqymPqGqxvJrXZbMx7Ttc+w9XgU2FB3lOyQRWET2IFGiU9m1frDVpxZZc6bfHwv4c1YXP6k1Vdy292Fb6UkuvFtXpvWSzA+HycXJHUXiGYIiMg2R6W459gnWGfHNdjIqDWVqemH2ekpObkpOlppWUqZiqr6edqqWQAAIfkECQEAAQAsAAAAACgAKAAAApSMgZnGfaqcg1E2uuzDmmHUBR8Qil95hiPKqWn3aqtLsS18y7G1SzNeowWBENtQd+T1JktP05nzPTdJZlR6vUxNWWjV+vUWhWNkWFwxl9VpZRedYcflIOLafaa28XdsH/ynlcc1uPVDZxQIR0K25+cICCmoqCe5mGhZOfeYSUh5yJcJyrkZWWpaR8doJ2o4NYq62lAAACH5BAkBAAEALAAAAAAoACgAAAKVDI4Yy22ZnINRNqosw0Bv7i1gyHUkFj7oSaWlu3ovC8GxNso5fluz3qLVhBVeT/Lz7ZTHyxL5dDalQWPVOsQWtRnuwXaFTj9jVVh8pma9JjZ4zYSj5ZOyma7uuolffh+IR5aW97cHuBUXKGKXlKjn+DiHWMcYJah4N0lYCMlJOXipGRr5qdgoSTrqWSq6WFl2ypoaUAAAIfkECQEAAQAsAAAAACgAKAAAApaEb6HLgd/iO7FNWtcFWe+ufODGjRfoiJ2akShbueb0wtI50zm02pbvwfWEMWBQ1zKGlLIhskiEPm9R6vRXxV4ZzWT2yHOGpWMyorblKlNp8HmHEb/lCXjcW7bmtXP8Xt229OVWR1fod2eWqNfHuMjXCPkIGNileOiImVmCOEmoSfn3yXlJWmoHGhqp6ilYuWYpmTqKUgAAIfkECQEAAQAsAAAAACgAKAAAApiEH6kb58biQ3FNWtMFWW3eNVcojuFGfqnZqSebuS06w5V80/X02pKe8zFwP6EFWOT1lDFk8rGERh1TTNOocQ61Hm4Xm2VexUHpzjymViHrFbiELsefVrn6XKfnt2Q9G/+Xdie499XHd2g4h7ioOGhXGJboGAnXSBnoBwKYyfioubZJ2Hn0RuRZaflZOil56Zp6iioKSXpUAAAh+QQJAQABACwAAAAAKAAoAAACkoQRqRvnxuI7kU1a1UU5bd5tnSeOZXhmn5lWK3qNTWvRdQxP8qvaC+/yaYQzXO7BMvaUEmJRd3TsiMAgswmNYrSgZdYrTX6tSHGZO73ezuAw2uxuQ+BbeZfMxsexY35+/Qe4J1inV0g4x3WHuMhIl2jXOKT2Q+VU5fgoSUI52VfZyfkJGkha6jmY+aaYdirq+lQAACH5BAkBAAEALAAAAAAoACgAAAKWBIKpYe0L3YNKToqswUlvznigd4wiR4KhZrKt9Upqip61i9E3vMvxRdHlbEFiEXfk9YARYxOZZD6VQ2pUunBmtRXo1Lf8hMVVcNl8JafV38aM2/Fu5V16Bn63r6xt97j09+MXSFi4BniGFae3hzbH9+hYBzkpuUh5aZmHuanZOZgIuvbGiNeomCnaxxap2upaCZsq+1kAACH5BAkBAAEALAAAAAAoACgAAAKXjI8By5zf4kOxTVrXNVlv1X0d8IGZGKLnNpYtm8Lr9cqVeuOSvfOW79D9aDHizNhDJidFZhNydEahOaDH6nomtJjp1tutKoNWkvA6JqfRVLHU/QUfau9l2x7G54d1fl995xcIGAdXqMfBNadoYrhH+Mg2KBlpVpbluCiXmMnZ2Sh4GBqJ+ckIOqqJ6LmKSllZmsoq6wpQAAAh+QQJAQABACwAAAAAKAAoAAAClYx/oLvoxuJDkU1a1YUZbJ59nSd2ZXhWqbRa2/gF8Gu2DY3iqs7yrq+xBYEkYvFSM8aSSObE+ZgRl1BHFZNr7pRCavZ5BW2142hY3AN/zWtsmf12p9XxxFl2lpLn1rseztfXZjdIWIf2s5dItwjYKBgo9yg5pHgzJXTEeGlZuenpyPmpGQoKOWkYmSpaSnqKileI2FAAACH5BAkBAAEALAAAAAAoACgAAAKVjB+gu+jG4kORTVrVhRlsnn2dJ3ZleFaptFrb+CXmO9OozeL5VfP99HvAWhpiUdcwkpBH3825AwYdU8xTqlLGhtCosArKMpvfa1mMRae9VvWZfeB2XfPkeLmm18lUcBj+p5dnN8jXZ3YIGEhYuOUn45aoCDkp16hl5IjYJvjWKcnoGQpqyPlpOhr3aElaqrq56Bq7VAAAOw=="); + height: 100%; + filter: alpha(opacity=25); /* support: IE8 */ + opacity: 0.25; +} +.ui-progressbar-indeterminate .ui-progressbar-value { + background-image: none; +} +.ui-selectmenu-menu { + padding: 0; + margin: 0; + position: absolute; + top: 0; + left: 0; + display: none; +} +.ui-selectmenu-menu .ui-menu { + overflow: auto; + overflow-x: hidden; + padding-bottom: 1px; +} +.ui-selectmenu-menu .ui-menu .ui-selectmenu-optgroup { + font-size: 1em; + font-weight: bold; + line-height: 1.5; + padding: 2px 0.4em; + margin: 0.5em 0 0 0; + height: auto; + border: 0; +} +.ui-selectmenu-open { + display: block; +} +.ui-selectmenu-text { + display: block; + margin-right: 20px; + overflow: hidden; + text-overflow: ellipsis; +} +.ui-selectmenu-button.ui-button { + text-align: left; + white-space: nowrap; + width: 14em; +} +.ui-selectmenu-icon.ui-icon { + float: right; + margin-top: 0; +} +.ui-slider { + position: relative; + text-align: left; +} +.ui-slider .ui-slider-handle { + position: absolute; + z-index: 2; + width: 1.2em; + height: 1.2em; + cursor: default; + -ms-touch-action: none; + touch-action: none; +} +.ui-slider .ui-slider-range { + position: absolute; + z-index: 1; + font-size: .7em; + display: block; + border: 0; + background-position: 0 0; +} + +/* support: IE8 - See #6727 */ +.ui-slider.ui-state-disabled .ui-slider-handle, +.ui-slider.ui-state-disabled .ui-slider-range { + filter: inherit; +} + +.ui-slider-horizontal { + height: .8em; +} +.ui-slider-horizontal .ui-slider-handle { + top: -.3em; + margin-left: -.6em; +} +.ui-slider-horizontal .ui-slider-range { + top: 0; + height: 100%; +} +.ui-slider-horizontal .ui-slider-range-min { + left: 0; +} +.ui-slider-horizontal .ui-slider-range-max { + right: 0; +} + +.ui-slider-vertical { + width: .8em; + height: 100px; +} +.ui-slider-vertical .ui-slider-handle { + left: -.3em; + margin-left: 0; + margin-bottom: -.6em; +} +.ui-slider-vertical .ui-slider-range { + left: 0; + width: 100%; +} +.ui-slider-vertical .ui-slider-range-min { + bottom: 0; +} +.ui-slider-vertical .ui-slider-range-max { + top: 0; +} +.ui-spinner { + position: relative; + display: inline-block; + overflow: hidden; + padding: 0; + vertical-align: middle; +} +.ui-spinner-input { + border: none; + background: none; + color: inherit; + padding: .222em 0; + margin: .2em 0; + vertical-align: middle; + margin-left: .4em; + margin-right: 2em; +} +.ui-spinner-button { + width: 1.6em; + height: 50%; + font-size: .5em; + padding: 0; + margin: 0; + text-align: center; + position: absolute; + cursor: default; + display: block; + overflow: hidden; + right: 0; +} +/* more specificity required here to override default borders */ +.ui-spinner a.ui-spinner-button { + border-top-style: none; + border-bottom-style: none; + border-right-style: none; +} +.ui-spinner-up { + top: 0; +} +.ui-spinner-down { + bottom: 0; +} +.ui-tabs { + position: relative;/* position: relative prevents IE scroll bug (element with position: relative inside container with overflow: auto appear as "fixed") */ + padding: .2em; +} +.ui-tabs .ui-tabs-nav { + margin: 0; + padding: .2em .2em 0; +} +.ui-tabs .ui-tabs-nav li { + list-style: none; + float: left; + position: relative; + top: 0; + margin: 1px .2em 0 0; + border-bottom-width: 0; + padding: 0; + white-space: nowrap; +} +.ui-tabs .ui-tabs-nav .ui-tabs-anchor { + float: left; + padding: .5em 1em; + text-decoration: none; +} +.ui-tabs .ui-tabs-nav li.ui-tabs-active { + margin-bottom: -1px; + padding-bottom: 1px; +} +.ui-tabs .ui-tabs-nav li.ui-tabs-active .ui-tabs-anchor, +.ui-tabs .ui-tabs-nav li.ui-state-disabled .ui-tabs-anchor, +.ui-tabs .ui-tabs-nav li.ui-tabs-loading .ui-tabs-anchor { + cursor: text; +} +.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active .ui-tabs-anchor { + cursor: pointer; +} +.ui-tabs .ui-tabs-panel { + display: block; + border-width: 0; + padding: 1em 1.4em; + background: none; +} +.ui-tooltip { + padding: 8px; + position: absolute; + z-index: 9999; + max-width: 300px; +} +body .ui-tooltip { + border-width: 2px; +} + +/* Component containers +----------------------------------*/ +.ui-widget { + font-family: Arial,Helvetica,sans-serif; + font-size: 1em; +} +.ui-widget .ui-widget { + font-size: 1em; +} +.ui-widget input, +.ui-widget select, +.ui-widget textarea, +.ui-widget button { + font-family: Arial,Helvetica,sans-serif; + font-size: 1em; +} +.ui-widget.ui-widget-content { + border: 1px solid #c5c5c5; +} +.ui-widget-content { + border: 1px solid #dddddd; + background: #ffffff; + color: #333333; +} +.ui-widget-content a { + color: #333333; +} +.ui-widget-header { + border: 1px solid #dddddd; + background: #e9e9e9; + color: #333333; + font-weight: bold; +} +.ui-widget-header a { + color: #333333; +} + +/* Interaction states +----------------------------------*/ +.ui-state-default, +.ui-widget-content .ui-state-default, +.ui-widget-header .ui-state-default, +.ui-button, + +/* We use html here because we need a greater specificity to make sure disabled +works properly when clicked or hovered */ +html .ui-button.ui-state-disabled:hover, +html .ui-button.ui-state-disabled:active { + border: 1px solid #c5c5c5; + background: #f6f6f6; + font-weight: normal; + color: #454545; +} +.ui-state-default a, +.ui-state-default a:link, +.ui-state-default a:visited, +a.ui-button, +a:link.ui-button, +a:visited.ui-button, +.ui-button { + color: #454545; + text-decoration: none; +} +.ui-state-hover, +.ui-widget-content .ui-state-hover, +.ui-widget-header .ui-state-hover, +.ui-state-focus, +.ui-widget-content .ui-state-focus, +.ui-widget-header .ui-state-focus, +.ui-button:hover, +.ui-button:focus { + border: 1px solid #cccccc; + background: #ededed; + font-weight: normal; + color: #2b2b2b; +} +.ui-state-hover a, +.ui-state-hover a:hover, +.ui-state-hover a:link, +.ui-state-hover a:visited, +.ui-state-focus a, +.ui-state-focus a:hover, +.ui-state-focus a:link, +.ui-state-focus a:visited, +a.ui-button:hover, +a.ui-button:focus { + color: #2b2b2b; + text-decoration: none; +} + +.ui-visual-focus { + box-shadow: 0 0 3px 1px rgb(94, 158, 214); +} +.ui-state-active, +.ui-widget-content .ui-state-active, +.ui-widget-header .ui-state-active, +a.ui-button:active, +.ui-button:active, +.ui-button.ui-state-active:hover { + border: 1px solid #003eff; + background: #007fff; + font-weight: normal; + color: #ffffff; +} +.ui-icon-background, +.ui-state-active .ui-icon-background { + border: #003eff; + background-color: #ffffff; +} +.ui-state-active a, +.ui-state-active a:link, +.ui-state-active a:visited { + color: #ffffff; + text-decoration: none; +} + +/* Interaction Cues +----------------------------------*/ +.ui-state-highlight, +.ui-widget-content .ui-state-highlight, +.ui-widget-header .ui-state-highlight { + border: 1px solid #dad55e; + background: #fffa90; + color: #777620; +} +.ui-state-checked { + border: 1px solid #dad55e; + background: #fffa90; +} +.ui-state-highlight a, +.ui-widget-content .ui-state-highlight a, +.ui-widget-header .ui-state-highlight a { + color: #777620; +} +.ui-state-error, +.ui-widget-content .ui-state-error, +.ui-widget-header .ui-state-error { + border: 1px solid #f1a899; + background: #fddfdf; + color: #5f3f3f; +} +.ui-state-error a, +.ui-widget-content .ui-state-error a, +.ui-widget-header .ui-state-error a { + color: #5f3f3f; +} +.ui-state-error-text, +.ui-widget-content .ui-state-error-text, +.ui-widget-header .ui-state-error-text { + color: #5f3f3f; +} +.ui-priority-primary, +.ui-widget-content .ui-priority-primary, +.ui-widget-header .ui-priority-primary { + font-weight: bold; +} +.ui-priority-secondary, +.ui-widget-content .ui-priority-secondary, +.ui-widget-header .ui-priority-secondary { + opacity: .7; + filter:Alpha(Opacity=70); /* support: IE8 */ + font-weight: normal; +} +.ui-state-disabled, +.ui-widget-content .ui-state-disabled, +.ui-widget-header .ui-state-disabled { + opacity: .35; + filter:Alpha(Opacity=35); /* support: IE8 */ + background-image: none; +} +.ui-state-disabled .ui-icon { + filter:Alpha(Opacity=35); /* support: IE8 - See #6059 */ +} + +/* Icons +----------------------------------*/ + +/* states and images */ +.ui-icon { + width: 16px; + height: 16px; +} + +/* positioning */ +.ui-icon-blank { background-position: 16px 16px; } +.ui-icon-caret-1-n { background-position: 0 0; } +.ui-icon-caret-1-ne { background-position: -16px 0; } +.ui-icon-caret-1-e { background-position: -32px 0; } +.ui-icon-caret-1-se { background-position: -48px 0; } +.ui-icon-caret-1-s { background-position: -65px 0; } +.ui-icon-caret-1-sw { background-position: -80px 0; } +.ui-icon-caret-1-w { background-position: -96px 0; } +.ui-icon-caret-1-nw { background-position: -112px 0; } +.ui-icon-caret-2-n-s { background-position: -128px 0; } +.ui-icon-caret-2-e-w { background-position: -144px 0; } +.ui-icon-triangle-1-n { background-position: 0 -16px; } +.ui-icon-triangle-1-ne { background-position: -16px -16px; } +.ui-icon-triangle-1-e { background-position: -32px -16px; } +.ui-icon-triangle-1-se { background-position: -48px -16px; } +.ui-icon-triangle-1-s { background-position: -65px -16px; } +.ui-icon-triangle-1-sw { background-position: -80px -16px; } +.ui-icon-triangle-1-w { background-position: -96px -16px; } +.ui-icon-triangle-1-nw { background-position: -112px -16px; } +.ui-icon-triangle-2-n-s { background-position: -128px -16px; } +.ui-icon-triangle-2-e-w { background-position: -144px -16px; } +.ui-icon-arrow-1-n { background-position: 0 -32px; } +.ui-icon-arrow-1-ne { background-position: -16px -32px; } +.ui-icon-arrow-1-e { background-position: -32px -32px; } +.ui-icon-arrow-1-se { background-position: -48px -32px; } +.ui-icon-arrow-1-s { background-position: -65px -32px; } +.ui-icon-arrow-1-sw { background-position: -80px -32px; } +.ui-icon-arrow-1-w { background-position: -96px -32px; } +.ui-icon-arrow-1-nw { background-position: -112px -32px; } +.ui-icon-arrow-2-n-s { background-position: -128px -32px; } +.ui-icon-arrow-2-ne-sw { background-position: -144px -32px; } +.ui-icon-arrow-2-e-w { background-position: -160px -32px; } +.ui-icon-arrow-2-se-nw { background-position: -176px -32px; } +.ui-icon-arrowstop-1-n { background-position: -192px -32px; } +.ui-icon-arrowstop-1-e { background-position: -208px -32px; } +.ui-icon-arrowstop-1-s { background-position: -224px -32px; } +.ui-icon-arrowstop-1-w { background-position: -240px -32px; } +.ui-icon-arrowthick-1-n { background-position: 1px -48px; } +.ui-icon-arrowthick-1-ne { background-position: -16px -48px; } +.ui-icon-arrowthick-1-e { background-position: -32px -48px; } +.ui-icon-arrowthick-1-se { background-position: -48px -48px; } +.ui-icon-arrowthick-1-s { background-position: -64px -48px; } +.ui-icon-arrowthick-1-sw { background-position: -80px -48px; } +.ui-icon-arrowthick-1-w { background-position: -96px -48px; } +.ui-icon-arrowthick-1-nw { background-position: -112px -48px; } +.ui-icon-arrowthick-2-n-s { background-position: -128px -48px; } +.ui-icon-arrowthick-2-ne-sw { background-position: -144px -48px; } +.ui-icon-arrowthick-2-e-w { background-position: -160px -48px; } +.ui-icon-arrowthick-2-se-nw { background-position: -176px -48px; } +.ui-icon-arrowthickstop-1-n { background-position: -192px -48px; } +.ui-icon-arrowthickstop-1-e { background-position: -208px -48px; } +.ui-icon-arrowthickstop-1-s { background-position: -224px -48px; } +.ui-icon-arrowthickstop-1-w { background-position: -240px -48px; } +.ui-icon-arrowreturnthick-1-w { background-position: 0 -64px; } +.ui-icon-arrowreturnthick-1-n { background-position: -16px -64px; } +.ui-icon-arrowreturnthick-1-e { background-position: -32px -64px; } +.ui-icon-arrowreturnthick-1-s { background-position: -48px -64px; } +.ui-icon-arrowreturn-1-w { background-position: -64px -64px; } +.ui-icon-arrowreturn-1-n { background-position: -80px -64px; } +.ui-icon-arrowreturn-1-e { background-position: -96px -64px; } +.ui-icon-arrowreturn-1-s { background-position: -112px -64px; } +.ui-icon-arrowrefresh-1-w { background-position: -128px -64px; } +.ui-icon-arrowrefresh-1-n { background-position: -144px -64px; } +.ui-icon-arrowrefresh-1-e { background-position: -160px -64px; } +.ui-icon-arrowrefresh-1-s { background-position: -176px -64px; } +.ui-icon-arrow-4 { background-position: 0 -80px; } +.ui-icon-arrow-4-diag { background-position: -16px -80px; } +.ui-icon-extlink { background-position: -32px -80px; } +.ui-icon-newwin { background-position: -48px -80px; } +.ui-icon-refresh { background-position: -64px -80px; } +.ui-icon-shuffle { background-position: -80px -80px; } +.ui-icon-transfer-e-w { background-position: -96px -80px; } +.ui-icon-transferthick-e-w { background-position: -112px -80px; } +.ui-icon-folder-collapsed { background-position: 0 -96px; } +.ui-icon-folder-open { background-position: -16px -96px; } +.ui-icon-document { background-position: -32px -96px; } +.ui-icon-document-b { background-position: -48px -96px; } +.ui-icon-note { background-position: -64px -96px; } +.ui-icon-mail-closed { background-position: -80px -96px; } +.ui-icon-mail-open { background-position: -96px -96px; } +.ui-icon-suitcase { background-position: -112px -96px; } +.ui-icon-comment { background-position: -128px -96px; } +.ui-icon-person { background-position: -144px -96px; } +.ui-icon-print { background-position: -160px -96px; } +.ui-icon-trash { background-position: -176px -96px; } +.ui-icon-locked { background-position: -192px -96px; } +.ui-icon-unlocked { background-position: -208px -96px; } +.ui-icon-bookmark { background-position: -224px -96px; } +.ui-icon-tag { background-position: -240px -96px; } +.ui-icon-home { background-position: 0 -112px; } +.ui-icon-flag { background-position: -16px -112px; } +.ui-icon-calendar { background-position: -32px -112px; } +.ui-icon-cart { background-position: -48px -112px; } +.ui-icon-pencil { background-position: -64px -112px; } +.ui-icon-clock { background-position: -80px -112px; } +.ui-icon-disk { background-position: -96px -112px; } +.ui-icon-calculator { background-position: -112px -112px; } +.ui-icon-zoomin { background-position: -128px -112px; } +.ui-icon-zoomout { background-position: -144px -112px; } +.ui-icon-search { background-position: -160px -112px; } +.ui-icon-wrench { background-position: -176px -112px; } +.ui-icon-gear { background-position: -192px -112px; } +.ui-icon-heart { background-position: -208px -112px; } +.ui-icon-star { background-position: -224px -112px; } +.ui-icon-link { background-position: -240px -112px; } +.ui-icon-cancel { background-position: 0 -128px; } +.ui-icon-plus { background-position: -16px -128px; } +.ui-icon-plusthick { background-position: -32px -128px; } +.ui-icon-minus { background-position: -48px -128px; } +.ui-icon-minusthick { background-position: -64px -128px; } +.ui-icon-close { background-position: -80px -128px; } +.ui-icon-closethick { background-position: -96px -128px; } +.ui-icon-key { background-position: -112px -128px; } +.ui-icon-lightbulb { background-position: -128px -128px; } +.ui-icon-scissors { background-position: -144px -128px; } +.ui-icon-clipboard { background-position: -160px -128px; } +.ui-icon-copy { background-position: -176px -128px; } +.ui-icon-contact { background-position: -192px -128px; } +.ui-icon-image { background-position: -208px -128px; } +.ui-icon-video { background-position: -224px -128px; } +.ui-icon-script { background-position: -240px -128px; } +.ui-icon-alert { background-position: 0 -144px; } +.ui-icon-info { background-position: -16px -144px; } +.ui-icon-notice { background-position: -32px -144px; } +.ui-icon-help { background-position: -48px -144px; } +.ui-icon-check { background-position: -64px -144px; } +.ui-icon-bullet { background-position: -80px -144px; } +.ui-icon-radio-on { background-position: -96px -144px; } +.ui-icon-radio-off { background-position: -112px -144px; } +.ui-icon-pin-w { background-position: -128px -144px; } +.ui-icon-pin-s { background-position: -144px -144px; } +.ui-icon-play { background-position: 0 -160px; } +.ui-icon-pause { background-position: -16px -160px; } +.ui-icon-seek-next { background-position: -32px -160px; } +.ui-icon-seek-prev { background-position: -48px -160px; } +.ui-icon-seek-end { background-position: -64px -160px; } +.ui-icon-seek-start { background-position: -80px -160px; } +/* ui-icon-seek-first is deprecated, use ui-icon-seek-start instead */ +.ui-icon-seek-first { background-position: -80px -160px; } +.ui-icon-stop { background-position: -96px -160px; } +.ui-icon-eject { background-position: -112px -160px; } +.ui-icon-volume-off { background-position: -128px -160px; } +.ui-icon-volume-on { background-position: -144px -160px; } +.ui-icon-power { background-position: 0 -176px; } +.ui-icon-signal-diag { background-position: -16px -176px; } +.ui-icon-signal { background-position: -32px -176px; } +.ui-icon-battery-0 { background-position: -48px -176px; } +.ui-icon-battery-1 { background-position: -64px -176px; } +.ui-icon-battery-2 { background-position: -80px -176px; } +.ui-icon-battery-3 { background-position: -96px -176px; } +.ui-icon-circle-plus { background-position: 0 -192px; } +.ui-icon-circle-minus { background-position: -16px -192px; } +.ui-icon-circle-close { background-position: -32px -192px; } +.ui-icon-circle-triangle-e { background-position: -48px -192px; } +.ui-icon-circle-triangle-s { background-position: -64px -192px; } +.ui-icon-circle-triangle-w { background-position: -80px -192px; } +.ui-icon-circle-triangle-n { background-position: -96px -192px; } +.ui-icon-circle-arrow-e { background-position: -112px -192px; } +.ui-icon-circle-arrow-s { background-position: -128px -192px; } +.ui-icon-circle-arrow-w { background-position: -144px -192px; } +.ui-icon-circle-arrow-n { background-position: -160px -192px; } +.ui-icon-circle-zoomin { background-position: -176px -192px; } +.ui-icon-circle-zoomout { background-position: -192px -192px; } +.ui-icon-circle-check { background-position: -208px -192px; } +.ui-icon-circlesmall-plus { background-position: 0 -208px; } +.ui-icon-circlesmall-minus { background-position: -16px -208px; } +.ui-icon-circlesmall-close { background-position: -32px -208px; } +.ui-icon-squaresmall-plus { background-position: -48px -208px; } +.ui-icon-squaresmall-minus { background-position: -64px -208px; } +.ui-icon-squaresmall-close { background-position: -80px -208px; } +.ui-icon-grip-dotted-vertical { background-position: 0 -224px; } +.ui-icon-grip-dotted-horizontal { background-position: -16px -224px; } +.ui-icon-grip-solid-vertical { background-position: -32px -224px; } +.ui-icon-grip-solid-horizontal { background-position: -48px -224px; } +.ui-icon-gripsmall-diagonal-se { background-position: -64px -224px; } +.ui-icon-grip-diagonal-se { background-position: -80px -224px; } + + +/* Misc visuals +----------------------------------*/ + +/* Corner radius */ +.ui-corner-all, +.ui-corner-top, +.ui-corner-left, +.ui-corner-tl { + border-top-left-radius: 3px; +} +.ui-corner-all, +.ui-corner-top, +.ui-corner-right, +.ui-corner-tr { + border-top-right-radius: 3px; +} +.ui-corner-all, +.ui-corner-bottom, +.ui-corner-left, +.ui-corner-bl { + border-bottom-left-radius: 3px; +} +.ui-corner-all, +.ui-corner-bottom, +.ui-corner-right, +.ui-corner-br { + border-bottom-right-radius: 3px; +} + +/* Overlays */ +.ui-widget-overlay { + background: #aaaaaa; + opacity: .3; + filter: Alpha(Opacity=30); /* support: IE8 */ +} +.ui-widget-shadow { + -webkit-box-shadow: 0px 0px 5px #666666; + box-shadow: 0px 0px 5px #666666; +} diff --git a/reference/libs/lfx-timeslider-1.0.0/jquery-ui.min.js b/reference/libs/lfx-timeslider-1.0.0/jquery-ui.min.js new file mode 100644 index 00000000..32d6b54b --- /dev/null +++ b/reference/libs/lfx-timeslider-1.0.0/jquery-ui.min.js @@ -0,0 +1,13 @@ +/*! jQuery UI - v1.12.0 - 2016-07-08 +* http://jqueryui.com +* Includes: widget.js, position.js, data.js, disable-selection.js, effect.js, effects/effect-blind.js, effects/effect-bounce.js, effects/effect-clip.js, effects/effect-drop.js, effects/effect-explode.js, effects/effect-fade.js, effects/effect-fold.js, effects/effect-highlight.js, effects/effect-puff.js, effects/effect-pulsate.js, effects/effect-scale.js, effects/effect-shake.js, effects/effect-size.js, effects/effect-slide.js, effects/effect-transfer.js, focusable.js, form-reset-mixin.js, jquery-1-7.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/datepicker.js, widgets/dialog.js, widgets/draggable.js, widgets/droppable.js, widgets/menu.js, widgets/mouse.js, widgets/progressbar.js, widgets/resizable.js, widgets/selectable.js, widgets/selectmenu.js, widgets/slider.js, widgets/sortable.js, widgets/spinner.js, widgets/tabs.js, widgets/tooltip.js +* Copyright jQuery Foundation and other contributors; Licensed MIT */ + +(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t(jQuery)})(function(t){function e(t){for(var e=t.css("visibility");"inherit"===e;)t=t.parent(),e=t.css("visibility");return"hidden"!==e}function i(t){for(var e,i;t.length&&t[0]!==document;){if(e=t.css("position"),("absolute"===e||"relative"===e||"fixed"===e)&&(i=parseInt(t.css("zIndex"),10),!isNaN(i)&&0!==i))return i;t=t.parent()}return 0}function s(){this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId="ui-datepicker-div",this._inlineClass="ui-datepicker-inline",this._appendClass="ui-datepicker-append",this._triggerClass="ui-datepicker-trigger",this._dialogClass="ui-datepicker-dialog",this._disableClass="ui-datepicker-disabled",this._unselectableClass="ui-datepicker-unselectable",this._currentClass="ui-datepicker-current-day",this._dayOverClass="ui-datepicker-days-cell-over",this.regional=[],this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""},this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},t.extend(this._defaults,this.regional[""]),this.regional.en=t.extend(!0,{},this.regional[""]),this.regional["en-US"]=t.extend(!0,{},this.regional.en),this.dpDiv=n(t("
"))}function n(e){var i="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return e.on("mouseout",i,function(){t(this).removeClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).removeClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).removeClass("ui-datepicker-next-hover")}).on("mouseover",i,o)}function o(){t.datepicker._isDisabledDatepicker(m.inline?m.dpDiv.parent()[0]:m.input[0])||(t(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),t(this).addClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).addClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).addClass("ui-datepicker-next-hover"))}function a(e,i){t.extend(e,i);for(var s in i)null==i[s]&&(e[s]=i[s]);return e}function r(t){return function(){var e=this.element.val();t.apply(this,arguments),this._refresh(),e!==this.element.val()&&this._trigger("change")}}t.ui=t.ui||{},t.ui.version="1.12.0";var h=0,l=Array.prototype.slice;t.cleanData=function(e){return function(i){var s,n,o;for(o=0;null!=(n=i[o]);o++)try{s=t._data(n,"events"),s&&s.remove&&t(n).triggerHandler("remove")}catch(a){}e(i)}}(t.cleanData),t.widget=function(e,i,s){var n,o,a,r={},h=e.split(".")[0];e=e.split(".")[1];var l=h+"-"+e;return s||(s=i,i=t.Widget),t.isArray(s)&&(s=t.extend.apply(null,[{}].concat(s))),t.expr[":"][l.toLowerCase()]=function(e){return!!t.data(e,l)},t[h]=t[h]||{},n=t[h][e],o=t[h][e]=function(t,e){return this._createWidget?(arguments.length&&this._createWidget(t,e),void 0):new o(t,e)},t.extend(o,n,{version:s.version,_proto:t.extend({},s),_childConstructors:[]}),a=new i,a.options=t.widget.extend({},a.options),t.each(s,function(e,s){return t.isFunction(s)?(r[e]=function(){function t(){return i.prototype[e].apply(this,arguments)}function n(t){return i.prototype[e].apply(this,t)}return function(){var e,i=this._super,o=this._superApply;return this._super=t,this._superApply=n,e=s.apply(this,arguments),this._super=i,this._superApply=o,e}}(),void 0):(r[e]=s,void 0)}),o.prototype=t.widget.extend(a,{widgetEventPrefix:n?a.widgetEventPrefix||e:e},r,{constructor:o,namespace:h,widgetName:e,widgetFullName:l}),n?(t.each(n._childConstructors,function(e,i){var s=i.prototype;t.widget(s.namespace+"."+s.widgetName,o,i._proto)}),delete n._childConstructors):i._childConstructors.push(o),t.widget.bridge(e,o),o},t.widget.extend=function(e){for(var i,s,n=l.call(arguments,1),o=0,a=n.length;a>o;o++)for(i in n[o])s=n[o][i],n[o].hasOwnProperty(i)&&void 0!==s&&(e[i]=t.isPlainObject(s)?t.isPlainObject(e[i])?t.widget.extend({},e[i],s):t.widget.extend({},s):s);return e},t.widget.bridge=function(e,i){var s=i.prototype.widgetFullName||e;t.fn[e]=function(n){var o="string"==typeof n,a=l.call(arguments,1),r=this;return o?this.each(function(){var i,o=t.data(this,s);return"instance"===n?(r=o,!1):o?t.isFunction(o[n])&&"_"!==n.charAt(0)?(i=o[n].apply(o,a),i!==o&&void 0!==i?(r=i&&i.jquery?r.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+n+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+n+"'")}):(a.length&&(n=t.widget.extend.apply(null,[n].concat(a))),this.each(function(){var e=t.data(this,s);e?(e.option(n||{}),e._init&&e._init()):t.data(this,s,new i(n,this))})),r}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"
",options:{classes:{},disabled:!1,create:null},_createWidget:function(e,i){i=t(i||this.defaultElement||this)[0],this.element=t(i),this.uuid=h++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},i!==this&&(t.data(i,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===i&&this.destroy()}}),this.document=t(i.style?i.ownerDocument:i.document||i),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var h=s.match(/^([\w:-]*)\s*(.*)$/),l=h[1]+o.eventNamespace,c=h[2];c?n.on(l,c,r):i.on(l,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(p.test(t[0])?e/100:1),parseFloat(t[1])*(p.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o,a=Math.max,r=Math.abs,h=Math.round,l=/left|center|right/,c=/top|center|bottom/,u=/[\+\-]\d+(\.[\d]+)?%?/,d=/^\w+/,p=/%$/,f=t.fn.position;o=function(){var e=t("
").css("position","absolute").appendTo("body").offset({top:1.5,left:1.5}),i=1.5===e.offset().top;return e.remove(),o=function(){return i},i},t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("
"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.widthi?"left":e>0?"right":"center",vertical:0>o?"top":s>0?"bottom":"middle"};u>g&&g>r(e+i)&&(h.horizontal="center"),d>m&&m>r(s+o)&&(h.vertical="middle"),h.important=a(r(e),r(i))>a(r(s),r(o))?"horizontal":"vertical",n.using.call(this,t,h)}),c.offset(t.extend(T,{using:l}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,o=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-o-n;e.collisionWidth>o?h>0&&0>=l?(i=t.left+h+e.collisionWidth-o-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+o-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=a(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,o=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-o-n;e.collisionHeight>o?h>0&&0>=l?(i=t.top+h+e.collisionHeight-o-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+o-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=a(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,a=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-a-h,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-a-o,(0>i||r(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>r(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,a=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-a-h,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,g=-2*e.offset[1];0>c?(s=t.top+p+f+g+e.collisionHeight-a-o,(0>s||r(c)>s)&&(t.top+=p+f+g)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+g-h,(i>0||u>r(i))&&(t.top+=p+f+g))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])}}),t.fn.extend({disableSelection:function(){var t="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}});var c="ui-effects-",u="ui-effects-style",d="ui-effects-animated",p=t;t.effects={effect:{}},function(t,e){function i(t,e,i){var s=u[e.type]||{};return null==t?i||!e.def?null:e.def:(t=s.floor?~~t:parseFloat(t),isNaN(t)?e.def:s.mod?(t+s.mod)%s.mod:0>t?0:t>s.max?s.max:t)}function s(i){var s=l(),n=s._rgba=[];return i=i.toLowerCase(),f(h,function(t,o){var a,r=o.re.exec(i),h=r&&o.parse(r),l=o.space||"rgba";return h?(a=s[l](h),s[c[l].cache]=a[c[l].cache],n=s._rgba=a._rgba,!1):e}),n.length?("0,0,0,0"===n.join()&&t.extend(n,o.transparent),s):o[i]}function n(t,e,i){return i=(i+1)%1,1>6*i?t+6*(e-t)*i:1>2*i?e:2>3*i?t+6*(e-t)*(2/3-i):t}var o,a="backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor",r=/^([\-+])=\s*(\d+\.?\d*)/,h=[{re:/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[t[1],t[2],t[3],t[4]]}},{re:/rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[2.55*t[1],2.55*t[2],2.55*t[3],t[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,parse:function(t){return[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])/,parse:function(t){return[parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),parseInt(t[3]+t[3],16)]}},{re:/hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,space:"hsla",parse:function(t){return[t[1],t[2]/100,t[3]/100,t[4]]}}],l=t.Color=function(e,i,s,n){return new t.Color.fn.parse(e,i,s,n)},c={rgba:{props:{red:{idx:0,type:"byte"},green:{idx:1,type:"byte"},blue:{idx:2,type:"byte"}}},hsla:{props:{hue:{idx:0,type:"degrees"},saturation:{idx:1,type:"percent"},lightness:{idx:2,type:"percent"}}}},u={"byte":{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},d=l.support={},p=t("

")[0],f=t.each;p.style.cssText="background-color:rgba(1,1,1,.5)",d.rgba=p.style.backgroundColor.indexOf("rgba")>-1,f(c,function(t,e){e.cache="_"+t,e.props.alpha={idx:3,type:"percent",def:1}}),l.fn=t.extend(l.prototype,{parse:function(n,a,r,h){if(n===e)return this._rgba=[null,null,null,null],this;(n.jquery||n.nodeType)&&(n=t(n).css(a),a=e);var u=this,d=t.type(n),p=this._rgba=[];return a!==e&&(n=[n,a,r,h],d="array"),"string"===d?this.parse(s(n)||o._default):"array"===d?(f(c.rgba.props,function(t,e){p[e.idx]=i(n[e.idx],e)}),this):"object"===d?(n instanceof l?f(c,function(t,e){n[e.cache]&&(u[e.cache]=n[e.cache].slice())}):f(c,function(e,s){var o=s.cache;f(s.props,function(t,e){if(!u[o]&&s.to){if("alpha"===t||null==n[t])return;u[o]=s.to(u._rgba)}u[o][e.idx]=i(n[t],e,!0)}),u[o]&&0>t.inArray(null,u[o].slice(0,3))&&(u[o][3]=1,s.from&&(u._rgba=s.from(u[o])))}),this):e},is:function(t){var i=l(t),s=!0,n=this;return f(c,function(t,o){var a,r=i[o.cache];return r&&(a=n[o.cache]||o.to&&o.to(n._rgba)||[],f(o.props,function(t,i){return null!=r[i.idx]?s=r[i.idx]===a[i.idx]:e})),s}),s},_space:function(){var t=[],e=this;return f(c,function(i,s){e[s.cache]&&t.push(i)}),t.pop()},transition:function(t,e){var s=l(t),n=s._space(),o=c[n],a=0===this.alpha()?l("transparent"):this,r=a[o.cache]||o.to(a._rgba),h=r.slice();return s=s[o.cache],f(o.props,function(t,n){var o=n.idx,a=r[o],l=s[o],c=u[n.type]||{};null!==l&&(null===a?h[o]=l:(c.mod&&(l-a>c.mod/2?a+=c.mod:a-l>c.mod/2&&(a-=c.mod)),h[o]=i((l-a)*e+a,n)))}),this[n](h)},blend:function(e){if(1===this._rgba[3])return this;var i=this._rgba.slice(),s=i.pop(),n=l(e)._rgba;return l(t.map(i,function(t,e){return(1-s)*n[e]+s*t}))},toRgbaString:function(){var e="rgba(",i=t.map(this._rgba,function(t,e){return null==t?e>2?1:0:t});return 1===i[3]&&(i.pop(),e="rgb("),e+i.join()+")"},toHslaString:function(){var e="hsla(",i=t.map(this.hsla(),function(t,e){return null==t&&(t=e>2?1:0),e&&3>e&&(t=Math.round(100*t)+"%"),t});return 1===i[3]&&(i.pop(),e="hsl("),e+i.join()+")"},toHexString:function(e){var i=this._rgba.slice(),s=i.pop();return e&&i.push(~~(255*s)),"#"+t.map(i,function(t){return t=(t||0).toString(16),1===t.length?"0"+t:t}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),l.fn.parse.prototype=l.fn,c.hsla.to=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e,i,s=t[0]/255,n=t[1]/255,o=t[2]/255,a=t[3],r=Math.max(s,n,o),h=Math.min(s,n,o),l=r-h,c=r+h,u=.5*c;return e=h===r?0:s===r?60*(n-o)/l+360:n===r?60*(o-s)/l+120:60*(s-n)/l+240,i=0===l?0:.5>=u?l/c:l/(2-c),[Math.round(e)%360,i,u,null==a?1:a]},c.hsla.from=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e=t[0]/360,i=t[1],s=t[2],o=t[3],a=.5>=s?s*(1+i):s+i-s*i,r=2*s-a;return[Math.round(255*n(r,a,e+1/3)),Math.round(255*n(r,a,e)),Math.round(255*n(r,a,e-1/3)),o]},f(c,function(s,n){var o=n.props,a=n.cache,h=n.to,c=n.from;l.fn[s]=function(s){if(h&&!this[a]&&(this[a]=h(this._rgba)),s===e)return this[a].slice();var n,r=t.type(s),u="array"===r||"object"===r?s:arguments,d=this[a].slice();return f(o,function(t,e){var s=u["object"===r?t:e.idx];null==s&&(s=d[e.idx]),d[e.idx]=i(s,e)}),c?(n=l(c(d)),n[a]=d,n):l(d)},f(o,function(e,i){l.fn[e]||(l.fn[e]=function(n){var o,a=t.type(n),h="alpha"===e?this._hsla?"hsla":"rgba":s,l=this[h](),c=l[i.idx];return"undefined"===a?c:("function"===a&&(n=n.call(this,c),a=t.type(n)),null==n&&i.empty?this:("string"===a&&(o=r.exec(n),o&&(n=c+parseFloat(o[2])*("+"===o[1]?1:-1))),l[i.idx]=n,this[h](l)))})})}),l.hook=function(e){var i=e.split(" ");f(i,function(e,i){t.cssHooks[i]={set:function(e,n){var o,a,r="";if("transparent"!==n&&("string"!==t.type(n)||(o=s(n)))){if(n=l(o||n),!d.rgba&&1!==n._rgba[3]){for(a="backgroundColor"===i?e.parentNode:e;(""===r||"transparent"===r)&&a&&a.style;)try{r=t.css(a,"backgroundColor"),a=a.parentNode}catch(h){}n=n.blend(r&&"transparent"!==r?r:"_default")}n=n.toRgbaString()}try{e.style[i]=n}catch(h){}}},t.fx.step[i]=function(e){e.colorInit||(e.start=l(e.elem,i),e.end=l(e.end),e.colorInit=!0),t.cssHooks[i].set(e.elem,e.start.transition(e.end,e.pos))}})},l.hook(a),t.cssHooks.borderColor={expand:function(t){var e={};return f(["Top","Right","Bottom","Left"],function(i,s){e["border"+s+"Color"]=t}),e}},o=t.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(p),function(){function e(e){var i,s,n=e.ownerDocument.defaultView?e.ownerDocument.defaultView.getComputedStyle(e,null):e.currentStyle,o={};if(n&&n.length&&n[0]&&n[n[0]])for(s=n.length;s--;)i=n[s],"string"==typeof n[i]&&(o[t.camelCase(i)]=n[i]);else for(i in n)"string"==typeof n[i]&&(o[i]=n[i]);return o}function i(e,i){var s,o,a={};for(s in i)o=i[s],e[s]!==o&&(n[s]||(t.fx.step[s]||!isNaN(parseFloat(o)))&&(a[s]=o));return a}var s=["add","remove","toggle"],n={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};t.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(e,i){t.fx.step[i]=function(t){("none"!==t.end&&!t.setAttr||1===t.pos&&!t.setAttr)&&(p.style(t.elem,i,t.end),t.setAttr=!0)}}),t.fn.addBack||(t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.effects.animateClass=function(n,o,a,r){var h=t.speed(o,a,r);return this.queue(function(){var o,a=t(this),r=a.attr("class")||"",l=h.children?a.find("*").addBack():a;l=l.map(function(){var i=t(this);return{el:i,start:e(this)}}),o=function(){t.each(s,function(t,e){n[e]&&a[e+"Class"](n[e])})},o(),l=l.map(function(){return this.end=e(this.el[0]),this.diff=i(this.start,this.end),this}),a.attr("class",r),l=l.map(function(){var e=this,i=t.Deferred(),s=t.extend({},h,{queue:!1,complete:function(){i.resolve(e)}});return this.el.animate(this.diff,s),i.promise()}),t.when.apply(t,l.get()).done(function(){o(),t.each(arguments,function(){var e=this.el;t.each(this.diff,function(t){e.css(t,"")})}),h.complete.call(a[0])})})},t.fn.extend({addClass:function(e){return function(i,s,n,o){return s?t.effects.animateClass.call(this,{add:i},s,n,o):e.apply(this,arguments)}}(t.fn.addClass),removeClass:function(e){return function(i,s,n,o){return arguments.length>1?t.effects.animateClass.call(this,{remove:i},s,n,o):e.apply(this,arguments)}}(t.fn.removeClass),toggleClass:function(e){return function(i,s,n,o,a){return"boolean"==typeof s||void 0===s?n?t.effects.animateClass.call(this,s?{add:i}:{remove:i},n,o,a):e.apply(this,arguments):t.effects.animateClass.call(this,{toggle:i},s,n,o)}}(t.fn.toggleClass),switchClass:function(e,i,s,n,o){return t.effects.animateClass.call(this,{add:i,remove:e},s,n,o)}})}(),function(){function e(e,i,s,n){return t.isPlainObject(e)&&(i=e,e=e.effect),e={effect:e},null==i&&(i={}),t.isFunction(i)&&(n=i,s=null,i={}),("number"==typeof i||t.fx.speeds[i])&&(n=s,s=i,i={}),t.isFunction(s)&&(n=s,s=null),i&&t.extend(e,i),s=s||i.duration,e.duration=t.fx.off?0:"number"==typeof s?s:s in t.fx.speeds?t.fx.speeds[s]:t.fx.speeds._default,e.complete=n||i.complete,e}function i(e){return!e||"number"==typeof e||t.fx.speeds[e]?!0:"string"!=typeof e||t.effects.effect[e]?t.isFunction(e)?!0:"object"!=typeof e||e.effect?!1:!0:!0}function s(t,e){var i=e.outerWidth(),s=e.outerHeight(),n=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/,o=n.exec(t)||["",0,i,s,0];return{top:parseFloat(o[1])||0,right:"auto"===o[2]?i:parseFloat(o[2]),bottom:"auto"===o[3]?s:parseFloat(o[3]),left:parseFloat(o[4])||0}}t.expr&&t.expr.filters&&t.expr.filters.animated&&(t.expr.filters.animated=function(e){return function(i){return!!t(i).data(d)||e(i)}}(t.expr.filters.animated)),t.uiBackCompat!==!1&&t.extend(t.effects,{save:function(t,e){for(var i=0,s=e.length;s>i;i++)null!==e[i]&&t.data(c+e[i],t[0].style[e[i]])},restore:function(t,e){for(var i,s=0,n=e.length;n>s;s++)null!==e[s]&&(i=t.data(c+e[s]),t.css(e[s],i))},setMode:function(t,e){return"toggle"===e&&(e=t.is(":hidden")?"show":"hide"),e},createWrapper:function(e){if(e.parent().is(".ui-effects-wrapper"))return e.parent();var i={width:e.outerWidth(!0),height:e.outerHeight(!0),"float":e.css("float")},s=t("

").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),n={width:e.width(),height:e.height()},o=document.activeElement;try{o.id}catch(a){o=document.body}return e.wrap(s),(e[0]===o||t.contains(e[0],o))&&t(o).trigger("focus"),s=e.parent(),"static"===e.css("position")?(s.css({position:"relative"}),e.css({position:"relative"})):(t.extend(i,{position:e.css("position"),zIndex:e.css("z-index")}),t.each(["top","left","bottom","right"],function(t,s){i[s]=e.css(s),isNaN(parseInt(i[s],10))&&(i[s]="auto")}),e.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),e.css(n),s.css(i).show()},removeWrapper:function(e){var i=document.activeElement;return e.parent().is(".ui-effects-wrapper")&&(e.parent().replaceWith(e),(e[0]===i||t.contains(e[0],i))&&t(i).trigger("focus")),e}}),t.extend(t.effects,{version:"1.12.0",define:function(e,i,s){return s||(s=i,i="effect"),t.effects.effect[e]=s,t.effects.effect[e].mode=i,s},scaledDimensions:function(t,e,i){if(0===e)return{height:0,width:0,outerHeight:0,outerWidth:0};var s="horizontal"!==i?(e||100)/100:1,n="vertical"!==i?(e||100)/100:1;return{height:t.height()*n,width:t.width()*s,outerHeight:t.outerHeight()*n,outerWidth:t.outerWidth()*s}},clipToBox:function(t){return{width:t.clip.right-t.clip.left,height:t.clip.bottom-t.clip.top,left:t.clip.left,top:t.clip.top}},unshift:function(t,e,i){var s=t.queue();e>1&&s.splice.apply(s,[1,0].concat(s.splice(e,i))),t.dequeue()},saveStyle:function(t){t.data(u,t[0].style.cssText)},restoreStyle:function(t){t[0].style.cssText=t.data(u)||"",t.removeData(u)},mode:function(t,e){var i=t.is(":hidden");return"toggle"===e&&(e=i?"show":"hide"),(i?"hide"===e:"show"===e)&&(e="none"),e},getBaseline:function(t,e){var i,s;switch(t[0]){case"top":i=0;break;case"middle":i=.5;break;case"bottom":i=1;break;default:i=t[0]/e.height}switch(t[1]){case"left":s=0;break;case"center":s=.5;break;case"right":s=1;break;default:s=t[1]/e.width}return{x:s,y:i}},createPlaceholder:function(e){var i,s=e.css("position"),n=e.position();return e.css({marginTop:e.css("marginTop"),marginBottom:e.css("marginBottom"),marginLeft:e.css("marginLeft"),marginRight:e.css("marginRight")}).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()),/^(static|relative)/.test(s)&&(s="absolute",i=t("<"+e[0].nodeName+">").insertAfter(e).css({display:/^(inline|ruby)/.test(e.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:e.css("marginTop"),marginBottom:e.css("marginBottom"),marginLeft:e.css("marginLeft"),marginRight:e.css("marginRight"),"float":e.css("float")}).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()).addClass("ui-effects-placeholder"),e.data(c+"placeholder",i)),e.css({position:s,left:n.left,top:n.top}),i},removePlaceholder:function(t){var e=c+"placeholder",i=t.data(e);i&&(i.remove(),t.removeData(e))},cleanUp:function(e){t.effects.restoreStyle(e),t.effects.removePlaceholder(e)},setTransition:function(e,i,s,n){return n=n||{},t.each(i,function(t,i){var o=e.cssUnit(i);o[0]>0&&(n[i]=o[0]*s+o[1])}),n}}),t.fn.extend({effect:function(){function i(e){function i(){r.removeData(d),t.effects.cleanUp(r),"hide"===s.mode&&r.hide(),a()}function a(){t.isFunction(h)&&h.call(r[0]),t.isFunction(e)&&e()}var r=t(this);s.mode=c.shift(),t.uiBackCompat===!1||o?"none"===s.mode?(r[l](),a()):n.call(r[0],s,i):(r.is(":hidden")?"hide"===l:"show"===l)?(r[l](),a()):n.call(r[0],s,a)}var s=e.apply(this,arguments),n=t.effects.effect[s.effect],o=n.mode,a=s.queue,r=a||"fx",h=s.complete,l=s.mode,c=[],u=function(e){var i=t(this),s=t.effects.mode(i,l)||o;i.data(d,!0),c.push(s),o&&("show"===s||s===o&&"hide"===s)&&i.show(),o&&"none"===s||t.effects.saveStyle(i),t.isFunction(e)&&e()};return t.fx.off||!n?l?this[l](s.duration,h):this.each(function(){h&&h.call(this)}):a===!1?this.each(u).each(i):this.queue(r,u).queue(r,i)},show:function(t){return function(s){if(i(s))return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="show",this.effect.call(this,n)}}(t.fn.show),hide:function(t){return function(s){if(i(s))return t.apply(this,arguments); +var n=e.apply(this,arguments);return n.mode="hide",this.effect.call(this,n)}}(t.fn.hide),toggle:function(t){return function(s){if(i(s)||"boolean"==typeof s)return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="toggle",this.effect.call(this,n)}}(t.fn.toggle),cssUnit:function(e){var i=this.css(e),s=[];return t.each(["em","px","%","pt"],function(t,e){i.indexOf(e)>0&&(s=[parseFloat(i),e])}),s},cssClip:function(t){return t?this.css("clip","rect("+t.top+"px "+t.right+"px "+t.bottom+"px "+t.left+"px)"):s(this.css("clip"),this)},transfer:function(e,i){var s=t(this),n=t(e.to),o="fixed"===n.css("position"),a=t("body"),r=o?a.scrollTop():0,h=o?a.scrollLeft():0,l=n.offset(),c={top:l.top-r,left:l.left-h,height:n.innerHeight(),width:n.innerWidth()},u=s.offset(),d=t("
").appendTo("body").addClass(e.className).css({top:u.top-r,left:u.left-h,height:s.innerHeight(),width:s.innerWidth(),position:o?"fixed":"absolute"}).animate(c,e.duration,e.easing,function(){d.remove(),t.isFunction(i)&&i()})}}),t.fx.step.clip=function(e){e.clipInit||(e.start=t(e.elem).cssClip(),"string"==typeof e.end&&(e.end=s(e.end,e.elem)),e.clipInit=!0),t(e.elem).cssClip({top:e.pos*(e.end.top-e.start.top)+e.start.top,right:e.pos*(e.end.right-e.start.right)+e.start.right,bottom:e.pos*(e.end.bottom-e.start.bottom)+e.start.bottom,left:e.pos*(e.end.left-e.start.left)+e.start.left})}}(),function(){var e={};t.each(["Quad","Cubic","Quart","Quint","Expo"],function(t,i){e[i]=function(e){return Math.pow(e,t+2)}}),t.extend(e,{Sine:function(t){return 1-Math.cos(t*Math.PI/2)},Circ:function(t){return 1-Math.sqrt(1-t*t)},Elastic:function(t){return 0===t||1===t?t:-Math.pow(2,8*(t-1))*Math.sin((80*(t-1)-7.5)*Math.PI/15)},Back:function(t){return t*t*(3*t-2)},Bounce:function(t){for(var e,i=4;((e=Math.pow(2,--i))-1)/11>t;);return 1/Math.pow(4,3-i)-7.5625*Math.pow((3*e-2)/22-t,2)}}),t.each(e,function(e,i){t.easing["easeIn"+e]=i,t.easing["easeOut"+e]=function(t){return 1-i(1-t)},t.easing["easeInOut"+e]=function(t){return.5>t?i(2*t)/2:1-i(-2*t+2)/2}})}();var f=t.effects;t.effects.define("blind","hide",function(e,i){var s={up:["bottom","top"],vertical:["bottom","top"],down:["top","bottom"],left:["right","left"],horizontal:["right","left"],right:["left","right"]},n=t(this),o=e.direction||"up",a=n.cssClip(),r={clip:t.extend({},a)},h=t.effects.createPlaceholder(n);r.clip[s[o][0]]=r.clip[s[o][1]],"show"===e.mode&&(n.cssClip(r.clip),h&&h.css(t.effects.clipToBox(r)),r.clip=a),h&&h.animate(t.effects.clipToBox(r),e.duration,e.easing),n.animate(r,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("bounce",function(e,i){var s,n,o,a=t(this),r=e.mode,h="hide"===r,l="show"===r,c=e.direction||"up",u=e.distance,d=e.times||5,p=2*d+(l||h?1:0),f=e.duration/p,g=e.easing,m="up"===c||"down"===c?"top":"left",_="up"===c||"left"===c,v=0,b=a.queue().length;for(t.effects.createPlaceholder(a),o=a.css(m),u||(u=a["top"===m?"outerHeight":"outerWidth"]()/3),l&&(n={opacity:1},n[m]=o,a.css("opacity",0).css(m,_?2*-u:2*u).animate(n,f,g)),h&&(u/=Math.pow(2,d-1)),n={},n[m]=o;d>v;v++)s={},s[m]=(_?"-=":"+=")+u,a.animate(s,f,g).animate(n,f,g),u=h?2*u:u/2;h&&(s={opacity:0},s[m]=(_?"-=":"+=")+u,a.animate(s,f,g)),a.queue(i),t.effects.unshift(a,b,p+1)}),t.effects.define("clip","hide",function(e,i){var s,n={},o=t(this),a=e.direction||"vertical",r="both"===a,h=r||"horizontal"===a,l=r||"vertical"===a;s=o.cssClip(),n.clip={top:l?(s.bottom-s.top)/2:s.top,right:h?(s.right-s.left)/2:s.right,bottom:l?(s.bottom-s.top)/2:s.bottom,left:h?(s.right-s.left)/2:s.left},t.effects.createPlaceholder(o),"show"===e.mode&&(o.cssClip(n.clip),n.clip=s),o.animate(n,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("drop","hide",function(e,i){var s,n=t(this),o=e.mode,a="show"===o,r=e.direction||"left",h="up"===r||"down"===r?"top":"left",l="up"===r||"left"===r?"-=":"+=",c="+="===l?"-=":"+=",u={opacity:0};t.effects.createPlaceholder(n),s=e.distance||n["top"===h?"outerHeight":"outerWidth"](!0)/2,u[h]=l+s,a&&(n.css(u),u[h]=c+s,u.opacity=1),n.animate(u,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("explode","hide",function(e,i){function s(){b.push(this),b.length===u*d&&n()}function n(){p.css({visibility:"visible"}),t(b).remove(),i()}var o,a,r,h,l,c,u=e.pieces?Math.round(Math.sqrt(e.pieces)):3,d=u,p=t(this),f=e.mode,g="show"===f,m=p.show().css("visibility","hidden").offset(),_=Math.ceil(p.outerWidth()/d),v=Math.ceil(p.outerHeight()/u),b=[];for(o=0;u>o;o++)for(h=m.top+o*v,c=o-(u-1)/2,a=0;d>a;a++)r=m.left+a*_,l=a-(d-1)/2,p.clone().appendTo("body").wrap("
").css({position:"absolute",visibility:"visible",left:-a*_,top:-o*v}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:_,height:v,left:r+(g?l*_:0),top:h+(g?c*v:0),opacity:g?0:1}).animate({left:r+(g?0:l*_),top:h+(g?0:c*v),opacity:g?1:0},e.duration||500,e.easing,s)}),t.effects.define("fade","toggle",function(e,i){var s="show"===e.mode;t(this).css("opacity",s?0:1).animate({opacity:s?1:0},{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("fold","hide",function(e,i){var s=t(this),n=e.mode,o="show"===n,a="hide"===n,r=e.size||15,h=/([0-9]+)%/.exec(r),l=!!e.horizFirst,c=l?["right","bottom"]:["bottom","right"],u=e.duration/2,d=t.effects.createPlaceholder(s),p=s.cssClip(),f={clip:t.extend({},p)},g={clip:t.extend({},p)},m=[p[c[0]],p[c[1]]],_=s.queue().length;h&&(r=parseInt(h[1],10)/100*m[a?0:1]),f.clip[c[0]]=r,g.clip[c[0]]=r,g.clip[c[1]]=0,o&&(s.cssClip(g.clip),d&&d.css(t.effects.clipToBox(g)),g.clip=p),s.queue(function(i){d&&d.animate(t.effects.clipToBox(f),u,e.easing).animate(t.effects.clipToBox(g),u,e.easing),i()}).animate(f,u,e.easing).animate(g,u,e.easing).queue(i),t.effects.unshift(s,_,4)}),t.effects.define("highlight","show",function(e,i){var s=t(this),n={backgroundColor:s.css("backgroundColor")};"hide"===e.mode&&(n.opacity=0),t.effects.saveStyle(s),s.css({backgroundImage:"none",backgroundColor:e.color||"#ffff99"}).animate(n,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("size",function(e,i){var s,n,o,a=t(this),r=["fontSize"],h=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],l=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],c=e.mode,u="effect"!==c,d=e.scale||"both",p=e.origin||["middle","center"],f=a.css("position"),g=a.position(),m=t.effects.scaledDimensions(a),_=e.from||m,v=e.to||t.effects.scaledDimensions(a,0);t.effects.createPlaceholder(a),"show"===c&&(o=_,_=v,v=o),n={from:{y:_.height/m.height,x:_.width/m.width},to:{y:v.height/m.height,x:v.width/m.width}},("box"===d||"both"===d)&&(n.from.y!==n.to.y&&(_=t.effects.setTransition(a,h,n.from.y,_),v=t.effects.setTransition(a,h,n.to.y,v)),n.from.x!==n.to.x&&(_=t.effects.setTransition(a,l,n.from.x,_),v=t.effects.setTransition(a,l,n.to.x,v))),("content"===d||"both"===d)&&n.from.y!==n.to.y&&(_=t.effects.setTransition(a,r,n.from.y,_),v=t.effects.setTransition(a,r,n.to.y,v)),p&&(s=t.effects.getBaseline(p,m),_.top=(m.outerHeight-_.outerHeight)*s.y+g.top,_.left=(m.outerWidth-_.outerWidth)*s.x+g.left,v.top=(m.outerHeight-v.outerHeight)*s.y+g.top,v.left=(m.outerWidth-v.outerWidth)*s.x+g.left),a.css(_),("content"===d||"both"===d)&&(h=h.concat(["marginTop","marginBottom"]).concat(r),l=l.concat(["marginLeft","marginRight"]),a.find("*[width]").each(function(){var i=t(this),s=t.effects.scaledDimensions(i),o={height:s.height*n.from.y,width:s.width*n.from.x,outerHeight:s.outerHeight*n.from.y,outerWidth:s.outerWidth*n.from.x},a={height:s.height*n.to.y,width:s.width*n.to.x,outerHeight:s.height*n.to.y,outerWidth:s.width*n.to.x};n.from.y!==n.to.y&&(o=t.effects.setTransition(i,h,n.from.y,o),a=t.effects.setTransition(i,h,n.to.y,a)),n.from.x!==n.to.x&&(o=t.effects.setTransition(i,l,n.from.x,o),a=t.effects.setTransition(i,l,n.to.x,a)),u&&t.effects.saveStyle(i),i.css(o),i.animate(a,e.duration,e.easing,function(){u&&t.effects.restoreStyle(i)})})),a.animate(v,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){var e=a.offset();0===v.opacity&&a.css("opacity",_.opacity),u||(a.css("position","static"===f?"relative":f).offset(e),t.effects.saveStyle(a)),i()}})}),t.effects.define("scale",function(e,i){var s=t(this),n=e.mode,o=parseInt(e.percent,10)||(0===parseInt(e.percent,10)?0:"effect"!==n?0:100),a=t.extend(!0,{from:t.effects.scaledDimensions(s),to:t.effects.scaledDimensions(s,o,e.direction||"both"),origin:e.origin||["middle","center"]},e);e.fade&&(a.from.opacity=1,a.to.opacity=0),t.effects.effect.size.call(this,a,i)}),t.effects.define("puff","hide",function(e,i){var s=t.extend(!0,{},e,{fade:!0,percent:parseInt(e.percent,10)||150});t.effects.effect.scale.call(this,s,i)}),t.effects.define("pulsate","show",function(e,i){var s=t(this),n=e.mode,o="show"===n,a="hide"===n,r=o||a,h=2*(e.times||5)+(r?1:0),l=e.duration/h,c=0,u=1,d=s.queue().length;for((o||!s.is(":visible"))&&(s.css("opacity",0).show(),c=1);h>u;u++)s.animate({opacity:c},l,e.easing),c=1-c;s.animate({opacity:c},l,e.easing),s.queue(i),t.effects.unshift(s,d,h+1)}),t.effects.define("shake",function(e,i){var s=1,n=t(this),o=e.direction||"left",a=e.distance||20,r=e.times||3,h=2*r+1,l=Math.round(e.duration/h),c="up"===o||"down"===o?"top":"left",u="up"===o||"left"===o,d={},p={},f={},g=n.queue().length;for(t.effects.createPlaceholder(n),d[c]=(u?"-=":"+=")+a,p[c]=(u?"+=":"-=")+2*a,f[c]=(u?"-=":"+=")+2*a,n.animate(d,l,e.easing);r>s;s++)n.animate(p,l,e.easing).animate(f,l,e.easing);n.animate(p,l,e.easing).animate(d,l/2,e.easing).queue(i),t.effects.unshift(n,g,h+1)}),t.effects.define("slide","show",function(e,i){var s,n,o=t(this),a={up:["bottom","top"],down:["top","bottom"],left:["right","left"],right:["left","right"]},r=e.mode,h=e.direction||"left",l="up"===h||"down"===h?"top":"left",c="up"===h||"left"===h,u=e.distance||o["top"===l?"outerHeight":"outerWidth"](!0),d={};t.effects.createPlaceholder(o),s=o.cssClip(),n=o.position()[l],d[l]=(c?-1:1)*u+n,d.clip=o.cssClip(),d.clip[a[h][1]]=d.clip[a[h][0]],"show"===r&&(o.cssClip(d.clip),o.css(l,d[l]),d.clip=s,d[l]=n),o.animate(d,{queue:!1,duration:e.duration,easing:e.easing,complete:i})});var f;t.uiBackCompat!==!1&&(f=t.effects.define("transfer",function(e,i){t(this).transfer(e,i)})),t.ui.focusable=function(i,s){var n,o,a,r,h,l=i.nodeName.toLowerCase();return"area"===l?(n=i.parentNode,o=n.name,i.href&&o&&"map"===n.nodeName.toLowerCase()?(a=t("img[usemap='#"+o+"']"),a.length>0&&a.is(":visible")):!1):(/^(input|select|textarea|button|object)$/.test(l)?(r=!i.disabled,r&&(h=t(i).closest("fieldset")[0],h&&(r=!h.disabled))):r="a"===l?i.href||s:s,r&&t(i).is(":visible")&&e(t(i)))},t.extend(t.expr[":"],{focusable:function(e){return t.ui.focusable(e,null!=t.attr(e,"tabindex"))}}),t.ui.focusable,t.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):t(this[0].form)},t.ui.formResetMixin={_formResetHandler:function(){var e=t(this);setTimeout(function(){var i=e.data("ui-form-reset-instances");t.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var e=this.form.data("ui-form-reset-instances");e.splice(t.inArray(this,e),1),e.length?this.form.data("ui-form-reset-instances",e):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===t.fn.jquery.substring(0,3)&&(t.each(["Width","Height"],function(e,i){function s(e,i,s,o){return t.each(n,function(){i-=parseFloat(t.css(e,"padding"+this))||0,s&&(i-=parseFloat(t.css(e,"border"+this+"Width"))||0),o&&(i-=parseFloat(t.css(e,"margin"+this))||0)}),i}var n="Width"===i?["Left","Right"]:["Top","Bottom"],o=i.toLowerCase(),a={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn["inner"+i]=function(e){return void 0===e?a["inner"+i].call(this):this.each(function(){t(this).css(o,s(this,e)+"px")})},t.fn["outer"+i]=function(e,n){return"number"!=typeof e?a["outer"+i].call(this,e):this.each(function(){t(this).css(o,s(this,e,!0,n)+"px")})}}),t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.ui.escapeSelector=function(){var t=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;return function(e){return e.replace(t,"\\$1")}}(),t.fn.labels=function(){var e,i,s,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),s=this.attr("id"),s&&(e=this.eq(0).parents().last(),o=e.add(e.length?e.siblings():this.siblings()),i="label[for='"+t.ui.escapeSelector(s)+"']",n=n.add(o.find(i).addBack(i))),this.pushStack(n))},t.fn.scrollParent=function(e){var i=this.css("position"),s="absolute"===i,n=e?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var e=t(this);return s&&"static"===e.css("position")?!1:n.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==i&&o.length?o:t(this[0].ownerDocument||document)},t.extend(t.expr[":"],{tabbable:function(e){var i=t.attr(e,"tabindex"),s=null!=i;return(!s||i>=0)&&t.ui.focusable(e,s)}}),t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.widget("ui.accordion",{version:"1.12.0",options:{active:0,animate:{},classes:{"ui-accordion-header":"ui-corner-top","ui-accordion-header-collapsed":"ui-corner-all","ui-accordion-content":"ui-corner-bottom"},collapsible:!1,event:"click",header:"> li > :first-child, > :not(li):even",heightStyle:"auto",icons:{activeHeader:"ui-icon-triangle-1-s",header:"ui-icon-triangle-1-e"},activate:null,beforeActivate:null},hideProps:{borderTopWidth:"hide",borderBottomWidth:"hide",paddingTop:"hide",paddingBottom:"hide",height:"hide"},showProps:{borderTopWidth:"show",borderBottomWidth:"show",paddingTop:"show",paddingBottom:"show",height:"show"},_create:function(){var e=this.options;this.prevShow=this.prevHide=t(),this._addClass("ui-accordion","ui-widget ui-helper-reset"),this.element.attr("role","tablist"),e.collapsible||e.active!==!1&&null!=e.active||(e.active=0),this._processPanels(),0>e.active&&(e.active+=this.headers.length),this._refresh()},_getCreateEventData:function(){return{header:this.active,panel:this.active.length?this.active.next():t()}},_createIcons:function(){var e,i,s=this.options.icons;s&&(e=t(""),this._addClass(e,"ui-accordion-header-icon","ui-icon "+s.header),e.prependTo(this.headers),i=this.active.children(".ui-accordion-header-icon"),this._removeClass(i,s.header)._addClass(i,null,s.activeHeader)._addClass(this.headers,"ui-accordion-icons"))},_destroyIcons:function(){this._removeClass(this.headers,"ui-accordion-icons"),this.headers.children(".ui-accordion-header-icon").remove()},_destroy:function(){var t;this.element.removeAttr("role"),this.headers.removeAttr("role aria-expanded aria-selected aria-controls tabIndex").removeUniqueId(),this._destroyIcons(),t=this.headers.next().css("display","").removeAttr("role aria-hidden aria-labelledby").removeUniqueId(),"content"!==this.options.heightStyle&&t.css("height","")},_setOption:function(t,e){return"active"===t?(this._activate(e),void 0):("event"===t&&(this.options.event&&this._off(this.headers,this.options.event),this._setupEvents(e)),this._super(t,e),"collapsible"!==t||e||this.options.active!==!1||this._activate(0),"icons"===t&&(this._destroyIcons(),e&&this._createIcons()),void 0)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t),this._toggleClass(null,"ui-state-disabled",!!t),this._toggleClass(this.headers.add(this.headers.next()),null,"ui-state-disabled",!!t)},_keydown:function(e){if(!e.altKey&&!e.ctrlKey){var i=t.ui.keyCode,s=this.headers.length,n=this.headers.index(e.target),o=!1;switch(e.keyCode){case i.RIGHT:case i.DOWN:o=this.headers[(n+1)%s];break;case i.LEFT:case i.UP:o=this.headers[(n-1+s)%s];break;case i.SPACE:case i.ENTER:this._eventHandler(e);break;case i.HOME:o=this.headers[0];break;case i.END:o=this.headers[s-1]}o&&(t(e.target).attr("tabIndex",-1),t(o).attr("tabIndex",0),t(o).trigger("focus"),e.preventDefault())}},_panelKeyDown:function(e){e.keyCode===t.ui.keyCode.UP&&e.ctrlKey&&t(e.currentTarget).prev().trigger("focus")},refresh:function(){var e=this.options;this._processPanels(),e.active===!1&&e.collapsible===!0||!this.headers.length?(e.active=!1,this.active=t()):e.active===!1?this._activate(0):this.active.length&&!t.contains(this.element[0],this.active[0])?this.headers.length===this.headers.find(".ui-state-disabled").length?(e.active=!1,this.active=t()):this._activate(Math.max(0,e.active-1)):e.active=this.headers.index(this.active),this._destroyIcons(),this._refresh()},_processPanels:function(){var t=this.headers,e=this.panels;this.headers=this.element.find(this.options.header),this._addClass(this.headers,"ui-accordion-header ui-accordion-header-collapsed","ui-state-default"),this.panels=this.headers.next().filter(":not(.ui-accordion-content-active)").hide(),this._addClass(this.panels,"ui-accordion-content","ui-helper-reset ui-widget-content"),e&&(this._off(t.not(this.headers)),this._off(e.not(this.panels)))},_refresh:function(){var e,i=this.options,s=i.heightStyle,n=this.element.parent();this.active=this._findActive(i.active),this._addClass(this.active,"ui-accordion-header-active","ui-state-active")._removeClass(this.active,"ui-accordion-header-collapsed"),this._addClass(this.active.next(),"ui-accordion-content-active"),this.active.next().show(),this.headers.attr("role","tab").each(function(){var e=t(this),i=e.uniqueId().attr("id"),s=e.next(),n=s.uniqueId().attr("id");e.attr("aria-controls",n),s.attr("aria-labelledby",i)}).next().attr("role","tabpanel"),this.headers.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}).next().attr({"aria-hidden":"true"}).hide(),this.active.length?this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}).next().attr({"aria-hidden":"false"}):this.headers.eq(0).attr("tabIndex",0),this._createIcons(),this._setupEvents(i.event),"fill"===s?(e=n.height(),this.element.siblings(":visible").each(function(){var i=t(this),s=i.css("position");"absolute"!==s&&"fixed"!==s&&(e-=i.outerHeight(!0))}),this.headers.each(function(){e-=t(this).outerHeight(!0)}),this.headers.next().each(function(){t(this).height(Math.max(0,e-t(this).innerHeight()+t(this).height()))}).css("overflow","auto")):"auto"===s&&(e=0,this.headers.next().each(function(){var i=t(this).is(":visible");i||t(this).show(),e=Math.max(e,t(this).css("height","").height()),i||t(this).hide()}).height(e))},_activate:function(e){var i=this._findActive(e)[0];i!==this.active[0]&&(i=i||this.active[0],this._eventHandler({target:i,currentTarget:i,preventDefault:t.noop}))},_findActive:function(e){return"number"==typeof e?this.headers.eq(e):t()},_setupEvents:function(e){var i={keydown:"_keydown"};e&&t.each(e.split(" "),function(t,e){i[e]="_eventHandler"}),this._off(this.headers.add(this.headers.next())),this._on(this.headers,i),this._on(this.headers.next(),{keydown:"_panelKeyDown"}),this._hoverable(this.headers),this._focusable(this.headers)},_eventHandler:function(e){var i,s,n=this.options,o=this.active,a=t(e.currentTarget),r=a[0]===o[0],h=r&&n.collapsible,l=h?t():a.next(),c=o.next(),u={oldHeader:o,oldPanel:c,newHeader:h?t():a,newPanel:l};e.preventDefault(),r&&!n.collapsible||this._trigger("beforeActivate",e,u)===!1||(n.active=h?!1:this.headers.index(a),this.active=r?t():a,this._toggle(u),this._removeClass(o,"ui-accordion-header-active","ui-state-active"),n.icons&&(i=o.children(".ui-accordion-header-icon"),this._removeClass(i,null,n.icons.activeHeader)._addClass(i,null,n.icons.header)),r||(this._removeClass(a,"ui-accordion-header-collapsed")._addClass(a,"ui-accordion-header-active","ui-state-active"),n.icons&&(s=a.children(".ui-accordion-header-icon"),this._removeClass(s,null,n.icons.header)._addClass(s,null,n.icons.activeHeader)),this._addClass(a.next(),"ui-accordion-content-active")))},_toggle:function(e){var i=e.newPanel,s=this.prevShow.length?this.prevShow:e.oldPanel;this.prevShow.add(this.prevHide).stop(!0,!0),this.prevShow=i,this.prevHide=s,this.options.animate?this._animate(i,s,e):(s.hide(),i.show(),this._toggleComplete(e)),s.attr({"aria-hidden":"true"}),s.prev().attr({"aria-selected":"false","aria-expanded":"false"}),i.length&&s.length?s.prev().attr({tabIndex:-1,"aria-expanded":"false"}):i.length&&this.headers.filter(function(){return 0===parseInt(t(this).attr("tabIndex"),10)}).attr("tabIndex",-1),i.attr("aria-hidden","false").prev().attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_animate:function(t,e,i){var s,n,o,a=this,r=0,h=t.css("box-sizing"),l=t.length&&(!e.length||t.index()",delay:300,options:{icons:{submenu:"ui-icon-caret-1-e"},items:"> *",menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element,this.mouseHandled=!1,this.element.uniqueId().attr({role:this.options.role,tabIndex:0}),this._addClass("ui-menu","ui-widget ui-widget-content"),this._on({"mousedown .ui-menu-item":function(t){t.preventDefault()},"click .ui-menu-item":function(e){var i=t(e.target),s=t(t.ui.safeActiveElement(this.document[0]));!this.mouseHandled&&i.not(".ui-state-disabled").length&&(this.select(e),e.isPropagationStopped()||(this.mouseHandled=!0),i.has(".ui-menu").length?this.expand(e):!this.element.is(":focus")&&s.closest(".ui-menu").length&&(this.element.trigger("focus",[!0]),this.active&&1===this.active.parents(".ui-menu").length&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":function(e){if(!this.previousFilter){var i=t(e.target).closest(".ui-menu-item"),s=t(e.currentTarget);i[0]===s[0]&&(this._removeClass(s.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(e,s))}},mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(t,e){var i=this.active||this.element.find(this.options.items).eq(0);e||this.focus(t,i)},blur:function(e){this._delay(function(){var i=!t.contains(this.element[0],t.ui.safeActiveElement(this.document[0]));i&&this.collapseAll(e)})},keydown:"_keydown"}),this.refresh(),this._on(this.document,{click:function(t){this._closeOnDocumentClick(t)&&this.collapseAll(t),this.mouseHandled=!1}})},_destroy:function(){var e=this.element.find(".ui-menu-item").removeAttr("role aria-disabled"),i=e.children(".ui-menu-item-wrapper").removeUniqueId().removeAttr("tabIndex role aria-haspopup");this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeAttr("role aria-labelledby aria-expanded aria-hidden aria-disabled tabIndex").removeUniqueId().show(),i.children().each(function(){var e=t(this);e.data("ui-menu-submenu-caret")&&e.remove()})},_keydown:function(e){var i,s,n,o,a=!0;switch(e.keyCode){case t.ui.keyCode.PAGE_UP:this.previousPage(e);break;case t.ui.keyCode.PAGE_DOWN:this.nextPage(e);break;case t.ui.keyCode.HOME:this._move("first","first",e);break;case t.ui.keyCode.END:this._move("last","last",e);break;case t.ui.keyCode.UP:this.previous(e);break;case t.ui.keyCode.DOWN:this.next(e);break;case t.ui.keyCode.LEFT:this.collapse(e);break;case t.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(e);break;case t.ui.keyCode.ENTER:case t.ui.keyCode.SPACE:this._activate(e);break;case t.ui.keyCode.ESCAPE:this.collapse(e);break;default:a=!1,s=this.previousFilter||"",n=String.fromCharCode(e.keyCode),o=!1,clearTimeout(this.filterTimer),n===s?o=!0:n=s+n,i=this._filterMenuItems(n),i=o&&-1!==i.index(this.active.next())?this.active.nextAll(".ui-menu-item"):i,i.length||(n=String.fromCharCode(e.keyCode),i=this._filterMenuItems(n)),i.length?(this.focus(e,i),this.previousFilter=n,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter}a&&e.preventDefault()},_activate:function(t){this.active&&!this.active.is(".ui-state-disabled")&&(this.active.children("[aria-haspopup='true']").length?this.expand(t):this.select(t))},refresh:function(){var e,i,s,n,o,a=this,r=this.options.icons.submenu,h=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,!!this.element.find(".ui-icon").length),s=h.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var e=t(this),i=e.prev(),s=t("").data("ui-menu-submenu-caret",!0);a._addClass(s,"ui-menu-icon","ui-icon "+r),i.attr("aria-haspopup","true").prepend(s),e.attr("aria-labelledby",i.attr("id"))}),this._addClass(s,"ui-menu","ui-widget ui-widget-content ui-front"),e=h.add(this.element),i=e.find(this.options.items),i.not(".ui-menu-item").each(function(){var e=t(this);a._isDivider(e)&&a._addClass(e,"ui-menu-divider","ui-widget-content")}),n=i.not(".ui-menu-item, .ui-menu-divider"),o=n.children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()}),this._addClass(n,"ui-menu-item")._addClass(o,"ui-menu-item-wrapper"),i.filter(".ui-state-disabled").attr("aria-disabled","true"),this.active&&!t.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(t,e){if("icons"===t){var i=this.element.find(".ui-menu-icon");this._removeClass(i,null,this.options.icons.submenu)._addClass(i,null,e.submenu)}this._super(t,e)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t+""),this._toggleClass(null,"ui-state-disabled",!!t)},focus:function(t,e){var i,s,n;this.blur(t,t&&"focus"===t.type),this._scrollIntoView(e),this.active=e.first(),s=this.active.children(".ui-menu-item-wrapper"),this._addClass(s,null,"ui-state-active"),this.options.role&&this.element.attr("aria-activedescendant",s.attr("id")),n=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper"),this._addClass(n,null,"ui-state-active"),t&&"keydown"===t.type?this._close():this.timer=this._delay(function(){this._close()},this.delay),i=e.children(".ui-menu"),i.length&&t&&/^mouse/.test(t.type)&&this._startOpening(i),this.activeMenu=e.parent(),this._trigger("focus",t,{item:e})},_scrollIntoView:function(e){var i,s,n,o,a,r;this._hasScroll()&&(i=parseFloat(t.css(this.activeMenu[0],"borderTopWidth"))||0,s=parseFloat(t.css(this.activeMenu[0],"paddingTop"))||0,n=e.offset().top-this.activeMenu.offset().top-i-s,o=this.activeMenu.scrollTop(),a=this.activeMenu.height(),r=e.outerHeight(),0>n?this.activeMenu.scrollTop(o+n):n+r>a&&this.activeMenu.scrollTop(o+n-a+r))},blur:function(t,e){e||clearTimeout(this.timer),this.active&&(this._removeClass(this.active.children(".ui-menu-item-wrapper"),null,"ui-state-active"),this._trigger("blur",t,{item:this.active}),this.active=null)},_startOpening:function(t){clearTimeout(this.timer),"true"===t.attr("aria-hidden")&&(this.timer=this._delay(function(){this._close(),this._open(t)},this.delay))},_open:function(e){var i=t.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(".ui-menu").not(e.parents(".ui-menu")).hide().attr("aria-hidden","true"),e.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(i)},collapseAll:function(e,i){clearTimeout(this.timer),this.timer=this._delay(function(){var s=i?this.element:t(e&&e.target).closest(this.element.find(".ui-menu"));s.length||(s=this.element),this._close(s),this.blur(e),this._removeClass(s.find(".ui-state-active"),null,"ui-state-active"),this.activeMenu=s},this.delay)},_close:function(t){t||(t=this.active?this.active.parent():this.element),t.find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false")},_closeOnDocumentClick:function(e){return!t(e.target).closest(".ui-menu").length},_isDivider:function(t){return!/[^\-\u2014\u2013\s]/.test(t.text())},collapse:function(t){var e=this.active&&this.active.parent().closest(".ui-menu-item",this.element);e&&e.length&&(this._close(),this.focus(t,e))},expand:function(t){var e=this.active&&this.active.children(".ui-menu ").find(this.options.items).first();e&&e.length&&(this._open(e.parent()),this._delay(function(){this.focus(t,e)}))},next:function(t){this._move("next","first",t)},previous:function(t){this._move("prev","last",t)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_move:function(t,e,i){var s;this.active&&(s="first"===t||"last"===t?this.active["first"===t?"prevAll":"nextAll"](".ui-menu-item").eq(-1):this.active[t+"All"](".ui-menu-item").eq(0)),s&&s.length&&this.active||(s=this.activeMenu.find(this.options.items)[e]()),this.focus(i,s)},nextPage:function(e){var i,s,n;return this.active?(this.isLastItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.nextAll(".ui-menu-item").each(function(){return i=t(this),0>i.offset().top-s-n}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items)[this.active?"last":"first"]())),void 0):(this.next(e),void 0)},previousPage:function(e){var i,s,n;return this.active?(this.isFirstItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.prevAll(".ui-menu-item").each(function(){return i=t(this),i.offset().top-s+n>0}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items).first())),void 0):(this.next(e),void 0)},_hasScroll:function(){return this.element.outerHeight()",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,_create:function(){var e,i,s,n=this.element[0].nodeName.toLowerCase(),o="textarea"===n,a="input"===n;this.isMultiLine=o||!a&&this._isContentEditable(this.element),this.valueMethod=this.element[o||a?"val":"text"],this.isNewMenu=!0,this._addClass("ui-autocomplete-input"),this.element.attr("autocomplete","off"),this._on(this.element,{keydown:function(n){if(this.element.prop("readOnly"))return e=!0,s=!0,i=!0,void 0; +e=!1,s=!1,i=!1;var o=t.ui.keyCode;switch(n.keyCode){case o.PAGE_UP:e=!0,this._move("previousPage",n);break;case o.PAGE_DOWN:e=!0,this._move("nextPage",n);break;case o.UP:e=!0,this._keyEvent("previous",n);break;case o.DOWN:e=!0,this._keyEvent("next",n);break;case o.ENTER:this.menu.active&&(e=!0,n.preventDefault(),this.menu.select(n));break;case o.TAB:this.menu.active&&this.menu.select(n);break;case o.ESCAPE:this.menu.element.is(":visible")&&(this.isMultiLine||this._value(this.term),this.close(n),n.preventDefault());break;default:i=!0,this._searchTimeout(n)}},keypress:function(s){if(e)return e=!1,(!this.isMultiLine||this.menu.element.is(":visible"))&&s.preventDefault(),void 0;if(!i){var n=t.ui.keyCode;switch(s.keyCode){case n.PAGE_UP:this._move("previousPage",s);break;case n.PAGE_DOWN:this._move("nextPage",s);break;case n.UP:this._keyEvent("previous",s);break;case n.DOWN:this._keyEvent("next",s)}}},input:function(t){return s?(s=!1,t.preventDefault(),void 0):(this._searchTimeout(t),void 0)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,void 0):(clearTimeout(this.searching),this.close(t),this._change(t),void 0)}}),this._initSource(),this.menu=t("