// All material copyright ESRI, All Rights Reserved, unless otherwise specified.
// See http://@sbaseurl@/jsapi/jsapi/esri/copyright.txt and http://www.arcgis.com/apps/webappbuilder/copyright.txt for details.

//>>built
require({cache:{"esri/tasks/BufferParameters":function(){define("dojo/_base/declare dojo/_base/lang dojo/_base/array dojo/_base/json dojo/has ../kernel ../geometry/Polygon ../geometry/jsonUtils".split(" "),function(D,a,d,c,w,n,B,C){D=D(null,{declaredClass:"esri.tasks.BufferParameters",geometries:null,outSpatialReference:null,bufferSpatialReference:null,distances:null,unit:null,unionResults:!1,geodesic:!1,toJson:function(){var m={unit:this.unit,unionResults:this.unionResults,geodesic:this.geodesic},
y=this.distances,I=this.outSpatialReference,e=this.bufferSpatialReference,b=d.map(this.geometries,function(M){M="extent"===M.type?B.fromExtent(M):M;return M.toJson()},this),q=this.geometries;if(q&&0<q.length){var K="extent"===q[0].type?"esriGeometryPolygon":C.getJsonType(q[0]);m.geometries=c.toJson({geometryType:K,geometries:b});m.inSR=q[0].spatialReference.wkid?q[0].spatialReference.wkid:c.toJson(q[0].spatialReference.toJson())}y&&(m.distances=y.join(","));I&&(m.outSR=I.wkid?I.wkid:c.toJson(I.toJson()));
e&&(m.bufferSR=e.wkid?e.wkid:c.toJson(e.toJson()));return m}});w("extend-esri")&&a.setObject("tasks.BufferParameters",D,n);return D})},"widgets/Screening/layerUtil":function(){define(["dojo/_base/array","dojo/promise/all","dojo/Deferred"],function(D,a,d){return{getLayerInfoArray:function(c){var w=new d,n=[];c.traversal(function(B){n.push(B)});c=D.map(n,function(B){return B.getLayerType()});a(c).then(function(B){var C=[];D.forEach(B,function(m,y){"FeatureLayer"===m&&C.push(n[y])});w.resolve(C)});return w}}})},
"widgets/Screening/placename/placename":function(){define("dojo/_base/declare dojo/dom-construct dojo/query dojo/text!./placename.html dijit/_WidgetsInTemplateMixin dojo/_base/lang dojo/Evented jimu/BaseWidget ../search dojo/dom-geometry dijit/focus dojo/on dojo/dom-attr dojo/keys dojo/_base/event jimu/utils".split(" "),function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M){return D([C,w,B],{baseClass:"jimu-widget-screening-placename",_hasMultipleSourcesInSearch:!0,templateString:c,_windowResizeTimer:null,_buttonNodeEventHandler:null,
_inputNodeEventHandler:null,_submitNodeEventHandler:null,_clearNodeEventHandler:null,constructor:function(z){this._clearNodeEventHandler=this._submitNodeEventHandler=this._inputNodeEventHandler=this._buttonNodeEventHandler=this._windowResizeTimer=null;n.mixin(this,z)},postCreate:function(){this._createSearchInstance()},_createSearchInstance:function(){this._searchInstance=new m({searchOptions:{addLayersFromMap:!1,autoNavigate:!1,autoComplete:!0,minCharacters:0,maxLocations:5,searchDelay:100,enableHighlight:!1},
config:this.config,appConfig:this.appConfig,nls:this.nls,map:this.map},a.create("div",{},this.searchWidgetContainer));this.own(this._searchInstance.on("select-result",n.hitch(this,function(z){this.emit("onSearchComplete",z)})));this.own(this._searchInstance.on("clear-search",n.hitch(this,this._clearResults)));this.own(this._searchInstance.on("search-loaded",n.hitch(this,function(){setTimeout(n.hitch(this,function(){this._searchContainerNodeElement=d(".arcgisSearch .searchGroup .searchInput",this.domNode)[0];
2>this._searchInstance.search.sources.length&&(this._hasMultipleSourcesInSearch=!1);this.onWindowResize()}),1E3)})));this._searchInstance.startup()},_attachSearchNodeEvents:function(){this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.inputNode&&(""!==this._inputNodeEventHandler&&null!==this._inputNodeEventHandler&&void 0!==this._inputNodeEventHandler&&this._inputNodeEventHandler[0].remove(),this._inputNodeEventHandler=this.own(e(this._searchInstance.search.inputNode,"keydown",
n.hitch(this,function(z){z.keyCode!==q.ESCAPE||this.isSingleTabSelected||(K.stop(z),this.emit("focusLastSelectedTab"))}))));this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.submitNode&&(""!==this._submitNodeEventHandler&&null!==this._submitNodeEventHandler&&void 0!==this._submitNodeEventHandler&&this._submitNodeEventHandler[0].remove(),this._submitNodeEventHandler=this.own(e(this._searchInstance.search.submitNode,"keydown",n.hitch(this,function(z){z.keyCode!==q.ESCAPE||
this.isSingleTabSelected||(K.stop(z),this.emit("focusLastSelectedTab"))}))));this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.sourcesBtnNode&&(""!==this._buttonNodeEventHandler&&null!==this._buttonNodeEventHandler&&void 0!==this._buttonNodeEventHandler&&this._buttonNodeEventHandler[0].remove(),this._buttonNodeEventHandler=this.own(e(this._searchInstance.search.sourcesBtnNode,"keydown",n.hitch(this,function(z){z.keyCode!==q.ESCAPE||this.isSingleTabSelected||(K.stop(z),
this.emit("focusLastSelectedTab"))}))));this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.clearNode&&(""!==this._clearNodeEventHandler&&null!==this._clearNodeEventHandler&&void 0!==this._clearNodeEventHandler&&this._clearNodeEventHandler[0].remove(),this._clearNodeEventHandler=this.own(e(this._searchInstance.search.clearNode,"keydown",n.hitch(this,function(z){z.keyCode!==q.ESCAPE||this.isSingleTabSelected||(K.stop(z),this.emit("focusLastSelectedTab"))}))))},_clearResults:function(z){z||
this.map.infoWindow.hide()},clearSearchText:function(){this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.clear()},onWindowResize:function(){this._windowResizeTimer&&clearTimeout(this._windowResizeTimer);this._windowResizeTimer=setTimeout(n.hitch(this,this._resetComponents),500)},_resetComponents:function(){var z;var v=d(".arcgisSearch .searchGroup",this.domNode)[0];this._searchContainerNodeElement||(this._searchContainerNodeElement=d(".arcgisSearch .searchGroup .searchInput",
this.domNode)[0]);this.widgetMainContainer&&this._searchContainerNodeElement&&(z=y.position(this.widgetMainContainer))&&z.w&&(z=z.w-162,this._hasMultipleSourcesInSearch||(z+=32),0<z&&(this._searchContainerNodeElement.style.setProperty("width",z+"px","important"),v&&v.style.setProperty("max-width","100%","important")));this._attachSearchNodeEvents()},resetPlaceNameWidgetValues:function(){this.clearSearchText()},focusFirstNodeOfSelectedTab:function(){I.focus(this.searchHeader)},_focusOutCurrentNode:function(){I.curNode&&
I.curNode.blur()},setFirstFocusNode:function(z){M.initFirstFocusNode(z,this.searchHeader)}})})},"widgets/Screening/search":function(){define("dojo/_base/declare dijit/_WidgetBase dojo/Evented dojo/_base/lang dojo/_base/array esri/dijit/Search esri/tasks/locator esri/layers/FeatureLayer jimu/utils dojo/dom-construct jimu/LayerInfos/LayerInfos ./searchSourceUtils dojo/when dojo/Deferred dojo/promise/all dojo/on esri/InfoTemplate".split(" "),function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z){return D([a,d],
{_urlParams:{},config:null,map:null,searchOptions:null,layerInfosObj:null,constructor:function(v){this._urlParams={};this.layerInfosObj=this.searchOptions=this.map=this.config=null;c.mixin(this,v)},postCreate:function(){this._urlParams={}},startup:function(){this.inherited(arguments);I.getInstance(this.map,this.map.itemInfo).then(c.hitch(this,function(v){this.layerInfosObj=v;this.own(this.layerInfosObj.on("layerInfosFilterChanged",c.hitch(this,this.onLayerInfosFilterChanged)));e.setMap(this.map);
e.setLayerInfosObj(this.layerInfosObj);e.setAppConfig(this.appConfig);b(e.getConfigInfo(this.config.searchSourceSettings)).then(c.hitch(this,function(Q){this.config.searchSourceSettings||(this.config.searchSourceSettings=Q);return K(this._convertConfig(Q)).then(function(S){return w.filter(S,function(U){return U})})})).then(c.hitch(this,function(Q){this.domNode&&this._init(Q)}))}))},_convertConfig:function(v){return w.map(v.sources,c.hitch(this,function(Q){var S=new q;if(Q&&Q.url&&"locator"===Q.type){var U=
{locator:new B(Q.url||""),outFields:["*"],singleLineFieldName:Q.singleLineFieldName||"",name:m.stripHTML(Q.name||""),placeholder:m.stripHTML(Q.placeholder||""),countryCode:Q.countryCode||"",maxSuggestions:Q.maxSuggestions,maxResults:Q.maxResults||6,useMapExtent:!!Q.searchInCurrentMapExtent};Q.enableLocalSearch&&(U.localSearchOptions={minScale:Q.localSearchMinScale,distance:Q.localSearchDistance});S.resolve(U)}else Q&&Q.url&&"query"===Q.type?(U=new C(Q.url||null,{outFields:["*"]}),this.own(M(U,"load",
c.hitch(this,function(g){var G=g.layer;var F=this._getInfoTemplate(G,Q,Q.displayField);var l=null;Q.searchFields&&0<Q.searchFields.length?l=Q.searchFields:(l=[],w.forEach(G.fields,function(E){"esriFieldTypeOID"!==E.type&&E.name!==G.objectIdField&&"esriFieldTypeGeometry"!==E.type&&l.push(E.name)}));g={featureLayer:G,outFields:["*"],searchFields:l,displayField:Q.displayField||"",exactMatch:!!Q.exactMatch,name:m.stripHTML(Q.name||""),placeholder:m.stripHTML(Q.placeholder||""),maxSuggestions:Q.maxSuggestions||
6,maxResults:Q.maxResults||6,infoTemplate:F,useMapExtent:!!Q.searchInCurrentMapExtent,_featureLayerId:Q.layerId};F||delete g.infoTemplate;g._featureLayerId&&(F=this.layerInfosObj.getLayerInfoById(g._featureLayerId),G.setDefinitionExpression(F.getFilter()));S.resolve(g)}))),this.own(M(U,"error",function(){S.resolve(null)}))):S.resolve(null);return S}))},_getInfoTemplate:function(v,Q,S){var U;var g=(U=this.layerInfosObj.getLayerInfoById(Q.layerId))&&U.getInfoTemplate();var G=U&&g;if(U&&!G)return null;
G||(g=new z,g.setTitle("\x26nbsp;"),g.setContent(c.hitch(this,"_formatContent",Q.name,v,S)));return g},_init:function(v){var Q={map:this.map,addLayersFromMap:!1,autoNavigate:!1,autoComplete:!0,minCharacters:0,searchDelay:100,enableInfoWindow:!0,enableHighlight:this.config.searchSourceSettings.showInfoWindowOnSelect,showInfoWindowOnSelect:this.config.searchSourceSettings.showInfoWindowOnSelect,allPlaceholder:m.stripHTML(this.config.searchSourceSettings.allPlaceholder)};var S=1===v.length?0:"all";c.mixin(Q,
this.searchOptions);this._urlParams=this._getUrlParams();this.search=new n(Q,y.create("div",{"class":"searchControl"},this.domNode));this.search.set("sources",v);this.search.set("activeSourceIndex",S);this.own(this.search.on("load",c.hitch(this,this._load)));this.own(this.search.on("select-result",c.hitch(this,this._selectResult)));this.own(this.search.on("clear-search",c.hitch(this,this._clear)));this.own(this.search.on("search-results",c.hitch(this,this._results)));this.own(this.search.on("suggest-results",
c.hitch(this,this._results)));this.search.startup()},_getUrlParams:function(){var v=m.urlToObject(document.location.href);v.query=v.query||{};return v.query},setSearchText:function(v){this.search.set("value",v)},clearSearchText:function(){this.search&&this.search.clear()},_setSearchString:function(){this._urlParams.find&&(this.search.set("value",this._urlParams.find),setTimeout(c.hitch(this,function(){this.search.search()}),1E3))},onLayerInfosFilterChanged:function(v){w.some(v,c.hitch(this,function(Q){this.search&&
this.search.sources&&0<this.search.sources.length&&w.forEach(this.search.sources,function(S){S._featureLayerId===Q.id&&S.featureLayer.setDefinitionExpression(Q.getFilter())})}))},_load:function(v){this.emit("search-loaded",v);this._setSearchString()},_results:function(v){this.emit("search-results",v)},_clear:function(v){this.emit("clear-search",v)},_selectResult:function(v){v&&this.search.sources[v.sourceIndex].featureLayer&&v.result&&v.result.name&&this.setSearchText(v.result.name);this.search.blur();
this.emit("select-result",v)}})})},"esri/dijit/Search":function(){define("require dojo/_base/declare dojo/_base/lang dojo/_base/array dojo/Evented dojo/Deferred dojo/keys dojo/on dojo/query dojo/uacss dojo/regexp dojo/dom dojo/dom-attr dojo/dom-class dojo/dom-style dojo/dom-construct dojo/date/locale dojo/i18n!../nls/jsapi dojo/text!./Search/templates/Search.html dijit/_WidgetBase dijit/_TemplatedMixin dijit/_FocusMixin dijit/a11yclick dijit/focus ../lang ../InfoTemplate ../kernel ../SpatialReference ../graphic ../promiseList ../symbols/PictureMarkerSymbol ../symbols/SimpleMarkerSymbol ../symbols/SimpleLineSymbol ../symbols/SimpleFillSymbol ../symbols/TextSymbol ../symbols/Font ../geometry/Point ../geometry/Extent ../geometry/normalizeUtils ../geometry/scaleUtils ../tasks/locator ../tasks/query ../Color ../styles/basic".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U,g,G,F,l,E,R,aa,W,da,h,V,T,r,u,A,x,H,L,Y,ba,ca,fa,ia){function ka(f,J){f&&J&&(f._layer=J,f._sourceLayer=J)}a=a([S,U,g,w],{declaredClass:"esri.dijit.Search",templateString:Q,reHostedFS:/https?:\/\/services.*\.arcgis\.com/i,constructor:function(f,J){this.css={searchGroup:"searchGroup",searchInput:"searchInput",searchInputGroup:"searchInputGroup",searchBtn:"searchBtn",searchSubmit:"searchSubmit",searchIcon:"searchIcon esri-icon-search",searchButtonText:"searchButtonText",
searchToggle:"searchToggle",searchToggleIcon:"searchIcon esri-icon-down-arrow",searchMenu:"searchMenu",searchMenuHeader:"menuHeader",searchClear:"searchClear",searchClearIcon:"searchIcon esri-icon-close searchClose",searchSpinner:"searchIcon esri-icon-loading-indicator searchSpinner",searchSourceName:"sourceName",suggestionsMenu:"suggestionsMenu",sourcesMenu:"sourcesMenu",activeSource:"active",hasValue:"hasValue",hasButtonMode:"hasButtonMode",hasMultipleSources:"hasMultipleSources",showSuggestions:"showSuggestions",
showSources:"showSources",showNoResults:"showNoResults",searchLoading:"searchLoading",latLonHeader:"searchLatLongHeader",searchMoreResults:"moreResults",searchMoreResultsList:"resultsList",searchMoreResultsHeader:"moreHeader",searchMoreResultsItem:"moreItem",searchMoreResultsListHeader:"popupHeader",searchShowMoreResults:"showMoreResults",searchNoResultsMenu:"noResultsMenu",searchNoResultsBody:"noResultsBody",searchNoResultsHeader:"noResultsHeader",searchNoValueIcon:"noValueIcon esri-icon-notice-triangle",
searchNoValueText:"noValueText",searchNoResultsText:"noResultsText",searchExpandContainer:"searchExpandContainer",searchAnimateContainer:"searchAnimate",searchExpanded:"searchExpanded",searchCollapsed:"searchCollapsed",searchClearFloat:"searchClearFloat"};this._allIndex="all";this._objectIdIdentifier="_objectId";this._deferreds=[];this._sourceNames=[];this.defaultSource={locator:new ba("//geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer"),singleLineFieldName:"SingleLine",outFields:["Addr_type",
"Match_addr","StAddr","City"],name:v.widgets.Search.main.esriLocatorName,localSearchOptions:{minScale:3E5,distance:5E4},placeholder:v.widgets.Search.main.placeholder,highlightSymbol:(new h(D.toUrl("./Search/images/search-pointer.png"),36,36)).setOffset(9,18)};this.options={map:null,theme:"arcgisSearch",visible:!0,value:"",allPlaceholder:"",sources:[this.defaultSource],activeSourceIndex:0,suggestionDelay:150,enableSourcesMenu:!0,enableSuggestionsMenu:!0,enableInfoWindow:!0,showInfoWindowOnSelect:!0,
enableSuggestions:!0,enableButtonMode:!1,autoNavigate:!0,autoSelect:!0,addLayersFromMap:!1,zoomScale:1E3,graphicsLayer:null,enableHighlight:!0,highlightGraphic:null,enableLabel:!1,labelSymbol:(new u).setColor(new fa([181,56,46,.9])).setFont(new A("14px",A.STYLE_NORMAL,A.VARIANT_NORMAL,A.WEIGHT_BOLD,"Arial")),labelGraphic:null,infoTemplate:new E(v.widgets.Search.main.searchResult,'\x3cdiv class\x3d"${searchTheme}"\x3e\x3cdiv id\x3d"${searchMoreResultsId}" class\x3d"${searchMoreResults}"\x3e\x3cdiv class\x3d"${searchMoreResultsItem}"\x3e${searchResult}\x3c/div\x3e\x3cdiv\x3e${searchMoreResultsHtml}\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e'),
searchResults:null,suggestResults:null,selectedResult:null,magicKey:null,selectedFeatureId:null,expanded:!1,maxLength:128,maxResults:6,maxSuggestions:6,locationToAddressDistance:1500,minCharacters:3,enableSearchingAll:!0};f=d.mixin({},this.options,f);this.set(f);this._updateActiveSource();this._i18n=v;this._defaultSR=new aa(4326);this.domNode=J},startup:function(){this.inherited(arguments);this.sources||(this.sources=[]);this._mapLoaded().then(d.hitch(this,this._init))},postCreate:function(){var f=
this;this.inherited(arguments);this._moreResultsId=this.id+"_more_results";this.own(C(this.submitNode,G,d.hitch(this,this._searchButton)));this.own(C(this.sourcesBtnNode,G,d.hitch(this,this._toggleSourcesMenu)));this.own(C(this.inputNode,G,d.hitch(this,this._inputClick)));this.own(C(this.clearNode,G,d.hitch(this,this._clearButton)));this.own(C(this.formNode,"submit",d.hitch(this,function(J){J.preventDefault();this._cancelSuggest();this.search()})));this.own(C(this.inputNode,"keyup",d.hitch(this,function(J){this._inputKey(J)})));
this.own(C(this.sourcesBtnNode,"keyup",d.hitch(this,function(J){this._sourceBtnKey(J)})));this.own(C(this.suggestionsNode,"li:click, li:keyup",function(J){f._suggestionsEvent(J,this)}));this.own(C(this.sourcesNode,"li:click, li:keyup",function(J){f._sourcesEvent(J,this)}));this.own(C(this.inputNode,"input, paste",d.hitch(this,function(){this._suggestDelay()})));this.map&&this.map.infoWindow&&this.map.infoWindow.domNode&&this.enableInfoWindow&&(this.own(C(this.map.infoWindow.domNode,"#"+this._moreResultsId+
"_show:click",d.hitch(this,function(J){this._showMoreResultsClick(J)}))),this.own(C(this.map.infoWindow.domNode,"#"+this._moreResultsId+"_list li a:click",d.hitch(this,function(J){this._moreResultsClick(J)}))),this.own(C(this.map.infoWindow.domNode,"#"+this._moreResultsId+" [data-switch-coordinates]:click",d.hitch(this,function(J){this._switchCoordinatesClick(J)}))));this.value&&this._checkStatus();this._hideMenus();this._updateVisible();this._insertSources(this.sources);this._setPlaceholder(this.activeSourceIndex);
this._updateButtonMode(this.enableButtonMode);this.toggle(this.expanded)},destroy:function(){this.clear();M.empty(this.domNode);this.inherited(arguments)},clear:function(){this.clearGraphics();b.get(this.inputNode,"value")&&b.set(this.inputNode,"value","");this._changeAttrValue("value","");this.set("searchResults",null);this.set("suggestResults",null);this.set("selectedResult",null);this.set("magicKey",null);this.set("selectedFeatureId",null);q.remove(this.containerNode,this.css.hasValue);b.set(this.clearNode,
"title","");this._hideMenus();this._closePopup();this._hideLoading();this.emit("clear-search")},show:function(){K.set(this.domNode,"display","block")},hide:function(){K.set(this.domNode,"display","none")},expand:function(){this.enableButtonMode&&(q.add(this.containerNode,this.css.searchExpanded),q.remove(this.containerNode,this.css.searchCollapsed),this._hideMenus(),this.set("expanded",!0))},collapse:function(){this.enableButtonMode&&(q.remove(this.containerNode,this.css.searchExpanded),q.add(this.containerNode,
this.css.searchCollapsed),this._hideMenus(),this.set("expanded",!1))},toggle:function(f){this.enableButtonMode&&("undefined"===typeof f&&(f=!this.expanded),f?this.expand():this.collapse())},search:function(f){var J=new n;this._mapLoaded().then(d.hitch(this,function(){this._searchDeferred(f).then(d.hitch(this,function(P){var N=P.results;this.set("searchResults",N);0===P.numResults&&(this._noResults(P.value),this._showNoResultsMenu());this._hideLoading();this.emit("search-results",P);this._selectFirstResult(N,
P.activeSourceIndex);J.resolve(N)}),d.hitch(this,function(P){J.reject(P)}))}));return J.promise},suggest:function(f){var J=new n;this._mapLoaded().then(d.hitch(this,function(){this._suggestDeferred(f).then(d.hitch(this,function(P){if(P){var N=P.results;this.set("suggestResults",N);this._insertSuggestions(N,P.value);this.emit("suggest-results",P);J.resolve(N)}}),d.hitch(this,function(P){J.reject(P)}))}));return J.promise},select:function(f){var J=this._getDefaultSymbol(f),P=this.labelSymbol,N=this.sources,
Z=this.activeSourceIndex,ea=this.enableHighlight,oa=this.enableLabel,k=this.autoNavigate,t=this.showInfoWindowOnSelect,O=this.enableInfoWindow,X=this.infoTemplate,ha=f.feature?new W(f.feature.toJson()):null,ja=ha?f.feature._sourceLayer:null;ka(ha,ja);if(Z===this._allIndex){var la=this._getSourceIndexOfResult(f);if(null!==la){var ma=N[la];Z=la}}else ma=N[Z];ma&&(ma.hasOwnProperty("highlightSymbol")&&(J=ma.highlightSymbol),ma.hasOwnProperty("labelSymbol")&&(P=ma.labelSymbol),ma.hasOwnProperty("enableHighlight")&&
(ea=ma.enableHighlight),ma.hasOwnProperty("enableLabel")&&(oa=ma.enableLabel),ma.hasOwnProperty("autoNavigate")&&(k=ma.autoNavigate),ma.hasOwnProperty("showInfoWindowOnSelect")&&(t=ma.showInfoWindowOnSelect),ma.hasOwnProperty("enableInfoWindow")&&(O=ma.enableInfoWindow),ma.hasOwnProperty("infoTemplate")?X=ma.infoTemplate:ma.featureLayer&&ma.featureLayer.infoTemplate&&(X=ma.featureLayer.infoTemplate));this._hideMenus();this._hideLoading();if(ha){N=this.highlightGraphic;var pa=this.graphicsLayer;la=
this.labelGraphic;var qa=d.mixin({},ha.attributes,{searchTheme:this.theme,searchResult:this._searchResultHTML(f),searchMoreResults:this.css.searchMoreResults,searchMoreResultsItem:this.css.searchMoreResultsItem,searchMoreResultsId:this._moreResultsId,searchMoreResultsHtml:this._moreResultsHTML(f)}),ra=null;O&&(ra=X);la?(la.setGeometry(ha.geometry),la.setAttributes(qa),la.setSymbol(P),P&&"textsymbol"===P.type&&la.symbol.setText(f.name)):(la=new W(ha.geometry,P,qa),ka(la,ja),P&&"textsymbol"===P.type&&
la.symbol.setText(f.name),oa&&(pa?pa.add(la):this.map&&this.map.graphics&&this.map.graphics.add(la)));N?(N.setGeometry(ha.geometry),N.setAttributes(qa),N.setInfoTemplate(ra),N.setSymbol(J)):(N=new W(ha.geometry,J,qa,ra),ka(N,ja),ea&&(pa?pa.add(N):this.map&&this.map.graphics&&this.map.graphics.add(N)));N&&N.symbol&&"textsymbol"===N.symbol.type&&N.symbol.setText(f.name);this.map&&this.map.infoWindow&&O&&t&&(this.map.infoWindow.setFeatures([N]),J=this._getPointFromGeometry(N.geometry),this.map.infoWindow.show(J));
this.map&&k&&f&&f.hasOwnProperty("extent")&&"function"===typeof this.map.setExtent&&this.map.setExtent(f.extent,!0);this.set("highlightGraphic",N);this.set("labelGraphic",la)}this.set("selectedResult",f);this.emit("select-result",{result:f,source:ma,sourceIndex:Z})},focus:function(){F.focus(this.inputNode)},blur:function(){this.inputNode.blur();F.curNode&&F.curNode.blur()},clearGraphics:function(){var f=this.highlightGraphic,J=this.graphicsLayer,P=this.labelGraphic;f&&(J?J.remove(f):this.map&&this.map.graphics&&
this.map.graphics.remove(f));P&&(J?J.remove(P):this.map&&this.map.graphics&&this.map.graphics.remove(P));this.set("labelGraphic",null);this.set("highlightGraphic",null)},_mapLoaded:function(){var f=new n;if(this.map)if(this.map.loaded)f.resolve();else C.once(this.map,"load",d.hitch(this,function(){f.resolve()}));else f.resolve();return f.promise},_init:function(){this._getMapLayers().then(d.hitch(this,function(){this.set("loaded",!0);this.emit("load")}))},_clearButton:function(){this.clear();F.focus(this.inputNode)},
_error:function(f){return Error(this.declaredClass+" "+f)},_searchDeferred:function(f){var J=new n,P=this.value,N=this.activeSourceIndex;f&&f.hasOwnProperty("index")&&(N=f.index);this._showLoading();this._hideMenus();this._closePopup();this.clearGraphics();var Z={magicKey:this.magicKey,text:P};f?"string"===typeof f?(Z.text=f,f=this._searchQueries(Z)):f="object"===typeof f&&f.hasOwnProperty("magicKey")?this._searchQueries(f):"object"===typeof f&&f.hasOwnProperty("geometry")?this._searchQueries({geometry:f}):
"object"===typeof f&&f.hasOwnProperty(this._objectIdIdentifier)?this._searchQueries(f):"object"===typeof f&&"point"===f.type?this._searchQueries({point:f}):f instanceof Array&&2===f.length?this._searchQueries({latlon:f}):this._searchQueries(Z):f=this._searchQueries(Z);f.always(d.hitch(this,function(ea){ea=this._formatResults(ea,N,P);J.resolve(ea)}));return J.promise},_suggestDeferred:function(f){var J=new n;this._deferreds.push(J);f||(f=this.value);var P=this.activeSourceIndex;this._suggestQueries({text:f}).always(d.hitch(this,
function(N){var Z;if(N)for(var ea=0;ea<N.length;ea++)N[ea]&&(Z=!0);Z?(N=this._formatResults(N,P,f),J.resolve(N)):J.resolve()}));return J.promise},_getDefaultSymbol:function(f){var J;this.map&&(J=this.map.getBasemap());J||(J="topo");if(f&&f.feature&&f.feature.geometry)var P=f.feature.geometry.type;"polyline"===P?P="line":"circle"===P||"extent"===P?P="polygon":"multipoint"===P&&(P="point");if(P){if(f=ia.getSchemes({theme:"default",basemap:J,geometryType:P}))var N=f.primaryScheme;if(N){N.color&&N.hasOwnProperty("opacity")&&
(N.color.a=N.opacity);var Z=N;f=N.color;N=N.size;switch(P){case "point":var ea=new V;ea.setColor(f);ea.setSize(null!==N?N:Z.size);P=new T;P.setColor(Z.outline.color);P.setWidth(Z.outline.width);ea.setOutline(P);break;case "line":ea=new T;ea.setColor(f);ea.setWidth(null!==N?N:Z.width);break;case "polygon":ea=new r,ea.setColor(f),P=new T,P.setColor(Z.outline.color),P.setWidth(Z.outline.width),ea.setOutline(P)}Z=ea}}return Z},_selectFirstResult:function(f,J){if(this.autoSelect&&f){var P;J===this._allIndex?
P=this._getFirstResult(f):f[J]&&f[J][0]&&(P=f[J][0]);P&&this.select(P)}},_getSourceIndexOfResult:function(f){var J=this.searchResults;if(J)for(var P in J)if(J[P]&&J[P].length)for(var N=0;N<J[P].length;N++)if(J[P][N]===f)return parseInt(P,10);return null},_getFirstResult:function(f){if(f)for(var J in f)if(f[J]&&f[J][0])return f[J][0];return!1},_onFocus:function(){this.map&&"function"===typeof this.map.disableKeyboardNavigation&&this.map.disableKeyboardNavigation();this.emit("focus");this.inherited(arguments)},
_onBlur:function(){this._hideMenus();this.map&&"function"===typeof this.map.enableKeyboardNavigation&&this.map.enableKeyboardNavigation();this.enableButtonMode&&this.loaded&&this.collapse();this.emit("blur");this.inherited(arguments)},_getMapLayers:function(){var f=new n;if(this.addLayersFromMap&&this.map){var J=[],P=this.map.graphicsLayerIds;if(P&&P.length){for(var N=0;N<P.length;N++){var Z=this.map.getLayer(P[N]);Z&&J.push(this._featureLayerLoaded(Z))}da(J).always(d.hitch(this,function(ea){for(var oa,
k=this.sources,t=0;t<ea.length;t++)ea[t]&&ea[t].loaded&&"Feature Layer"===ea[t].type&&(k.push({featureLayer:ea[t],enableSuggestions:!0}),oa=!0);oa&&this.set("sources",k);f.resolve()}))}else f.resolve()}else f.resolve();return f.promise},_switchCoordinatesClick:function(f){f.preventDefault();if(f=b.get(f.target,"data-switch-coordinates"))this._cancelSuggest(),this.set("value",f),this.search()},_moreResultsClick:function(f){f.preventDefault();var J=f.target;f=parseInt(b.get(J,"data-source-index"),10);
J=parseInt(b.get(J,"data-index"),10);var P=this.searchResults;P&&P[f]&&(f=P[f][J])&&this.select(f)},_showMoreResultsClick:function(f){f.preventDefault();if(f=e.byId(this._moreResultsId)){q.toggle(f,this.css.searchShowMoreResults);var J=e.byId(this._moreResultsId+"_show");J&&(q.contains(f,this.css.searchShowMoreResults)?b.set(J,"textContent",v.widgets.Search.main.hideMoreResults):b.set(J,"textContent",v.widgets.Search.main.showMoreResults))}},_featureLayerLoaded:function(f){var J=new n;if(f.loaded)J.resolve(f);
else if(f.loadError)J.reject(this._error("Layer failed to load."));else{var P=C.once(f,"load",d.hitch(this,function(){N.remove();J.resolve(f)}));var N=C.once(f,"error",d.hitch(this,function(){P.remove();J.reject(this._error("Layer could not be loaded."))}))}return J.promise},_getObjectSize:function(f){var J=0,P;for(P in f)f.hasOwnProperty(P)&&J++;return J},_sourcesEvent:function(f,J){var P=b.get(J,"data-index"),N=m("li",this.sourcesNode);J=c.indexOf(N,J);P!==this._allIndex&&(P=parseInt(P,10));"click"===
f.type||f.keyCode===B.ENTER?(this.set("activeSourceIndex",P),F.focus(this.inputNode),this._hideSourcesMenu()):f.keyCode===B.UP_ARROW?(f.stopPropagation(),f.preventDefault(),f=J-1,0>f?F.focus(this.sourcesBtnNode):F.focus(N[f])):f.keyCode===B.DOWN_ARROW?(f.stopPropagation(),f.preventDefault(),f=J+1,f>=N.length?F.focus(this.sourcesBtnNode):F.focus(N[f])):f.keyCode===B.ESCAPE&&(this._hideSourcesMenu(),F.focus(this.inputNode))},_suggestionsEvent:function(f,J){var P=b.get(J,"data-source-index"),N=parseInt(b.get(J,
"data-index"),10),Z=m("li",this.suggestionsNode),ea=this.sources;J=c.indexOf(Z,J);P!==this._allIndex&&(P=parseInt(P,10));var oa;this._clearQueryTimeout();"click"===f.type||f.keyCode===B.ENTER?((Z=this.suggestResults)&&Z[P]&&Z[P][N]&&(oa=Z[P][N]),oa&&(oa.index=P,ea[P].featureLayer?(P=ea[P].featureLayer.objectIdField,oa[this._objectIdIdentifier]=oa.feature.attributes[P],this.set("value",this._getSuggestionName(oa)),this.set("selectedFeatureId",oa.feature.attributes[P])):oa.magicKey&&oa.text&&(this.set("value",
oa.text),this.set("magicKey",oa.magicKey)),this.search(oa),F.focus(this.inputNode))):f.keyCode===B.BACKSPACE||f.keyCode===B.DELETE?F.focus(this.inputNode):f.keyCode===B.UP_ARROW?(f.stopPropagation(),f.preventDefault(),oa=J-1,0>oa?F.focus(this.inputNode):F.focus(Z[oa])):f.keyCode===B.DOWN_ARROW?(f.stopPropagation(),f.preventDefault(),oa=J+1,oa>=Z.length?F.focus(this.inputNode):F.focus(Z[oa])):f.keyCode===B.ESCAPE&&(this._hideMenus(),F.focus(this.inputNode))},_getResultName:function(f){var J;f.hasOwnProperty("name")&&
null!==f.name&&(J=f.name.toString());J||(J=v.widgets.Search.main.untitledResult);return J},_getSuggestionName:function(f){var J;f.hasOwnProperty("name")&&null!==f.name&&(J=f.name.toString());f=f.text||J;f||(f=v.widgets.Search.main.untitledResult);return f},_searchResultHTML:function(f){var J="";if(f.feature&&f.feature.attributes&&f.feature.attributes.Addr_type&&"LatLong"===f.feature.attributes.Addr_type){var P=f.name.split(" ");if(2===P.length){var N=P[0];var Z=P[1]}Z&&N?(f=parseFloat(N),Z=parseFloat(Z),
P=Z+", "+f,J+='\x3cdiv class\x3d"'+this.css.searchMoreResultsItem+'"\x3e',J+='\x3cdiv class\x3d"'+this.css.latLonHeader+'"\x3e'+v.widgets.Search.main.lonlat+"\x3c/div\x3e",J=J+(f+", "+Z)+'\x3c/div\x3e\x3cdiv class\x3d"'+(this.css.searchMoreResultsItem+'"\x3e'),f===Z||90<f||-90>f||180<Z||-180>Z||(J+='\x3cdiv class\x3d"'+this.css.latLonHeader+'"\x3e'+v.widgets.Search.main.reverseLonLatHeader+"\x3c/div\x3e",J+='\x3ca data-switch-coordinates\x3d"'+P+'" tabindex\x3d"0" href\x3d"#"\x3e'+P+"\x3c/a\x3e\x3c/div\x3e")):
J=f.name}else J=f.name;return J},_moreResultsHTML:function(f){var J="",P="",N=this.searchResults,Z=this.sources,ea=0;if(N){P+='\x3cdiv class\x3d"'+this.css.searchMoreResultsItem+'"\x3e';P+='\x3ca href\x3d"#" id\x3d"'+this._moreResultsId+'_show"\x3e'+v.widgets.Search.main.showMoreResults+"\x3c/a\x3e";P=P+'\x3c/div\x3e\x3cdiv class\x3d"'+(this.css.searchMoreResultsList+'"\x3e');P+='\x3cdiv id\x3d"'+this._moreResultsId+'_list"\x3e';for(var oa in N)if(N[oa]){var k=N[oa].length;if(k){var t=1===k&&N[oa][0]===
f;if(1<this._getObjectSize(N)&&!t){var O=this._getSourceName(oa);P+='\x3cdiv class\x3d"'+this.css.searchMoreResultsListHeader+'"\x3e'+O+"\x3c/div\x3e"}if(k&&!t){P+="\x3cul\x3e";O=Z[oa].maxResults||this.maxResults;for(t=0;t<k&&t<O;++t)if(N[oa][t]!==f){var X=this._getResultName(N[oa][t]);P+='\x3cli\x3e\x3ca tabindex\x3d"0" data-index\x3d"'+t+'" data-source-index\x3d"'+oa+'" href\x3d"#"\x3e'+X+"\x3c/a\x3e\x3c/li\x3e";ea++}P+="\x3c/ul\x3e"}}}P+="\x3c/div\x3e\x3c/div\x3e"}ea&&(J+=P);return J},_validField:function(f,
J){return f.getField(J)},_validFields:function(f,J){if(f&&J&&J.length){for(var P=0;P<J.length;P++)if(!this._validField(f,J[P]))return!1;return!0}return!1},_getCodedName:function(f,J){if(f&&f.length)for(var P=0,N=f.length;P<N;P++){var Z=f[P];if(Z.code===J)return Z.name}},_getCodedValue:function(f,J,P){if(f&&f.length)for(var N=0,Z=f.length;N<Z;N++){var ea=f[N],oa=ea.name,k=J;P||(oa=oa.toLowerCase(),k=k.toLowerCase());if(oa===k)return ea.code}return!1},_whereClause:function(f,J,P,N){var Z=null;if(f){var ea=
"";this.reHostedFS.test(J.url)&&this._containsNonLatinCharacter(f)&&(ea="N");if(P&&P.length)for(var oa=0,k=P.length;oa<k;oa++){var t="",O=f.replace(/'/g,"''");t=P[oa];var X=J.getField(t),ha=J.getDomain(t);ha&&"codedValue"===ha.type&&(O=this._getCodedValue(ha.codedValues,O,N));!1!==O&&(X=X.type,"esriFieldTypeString"===X||"esriFieldTypeDate"===X?t=N?t+" \x3d "+ea+"'"+O+"'":"UPPER("+t+") LIKE "+ea+"'%"+O.toUpperCase()+"%'":"esriFieldTypeOID"===X||"esriFieldTypeSmallInteger"===X||"esriFieldTypeInteger"===
X||"esriFieldTypeSingle"===X||"esriFieldTypeDouble"===X?(O=parseFloat(O),t=isNaN(O)?!1:t+" \x3d "+O):t=t+" \x3d "+O,t&&(Z=Z?Z+" or ":"",Z+=t))}}return Z},_suggest:function(f){f||(f={index:this.activeSourceIndex,text:this.value});var J=new n,P=f.index,N=this.sources[P],Z=this.enableSuggestions;N.hasOwnProperty("enableSuggestions")&&(Z=N.enableSuggestions);var ea=0;if(f.hasOwnProperty("text")&&f.text){var oa=d.trim(f.text);ea=f.text.length}f=N.minCharacters||this.minCharacters;if(Z&&oa&&ea>=f&&this._supportsPagination(N)){var k=
"";N.prefix&&(k+=N.prefix);k+=oa;N.suffix&&(k+=N.suffix);var t=this._defaultSR;this.map&&(t=this.map.spatialReference);Z={};N.locator?(N.categories&&(Z.categories=N.categories),N.locator.outSpatialReference=t,this.map&&N.localSearchOptions&&N.localSearchOptions.hasOwnProperty("distance")&&N.localSearchOptions.hasOwnProperty("minScale")&&(ea=this._getScale(),!N.localSearchOptions.minScale||ea&&ea<=parseFloat(N.localSearchOptions.minScale))&&(Z.location=this.map.extent.getCenter(),Z.distance=N.localSearchOptions.distance),
Z.text=k,N.useMapExtent&&this.map&&this.map.extent&&(Z.searchExtent=this.map.extent),N.searchExtent&&(Z.searchExtent=N.searchExtent),Z.maxSuggestions=N.maxSuggestions||this.maxSuggestions,N.sourceCountry&&(Z.countryCode=N.sourceCountry),N.countryCode&&(Z.countryCode=N.countryCode),N.locator.suggestLocations(Z).then(d.hitch(this,function(O){J.resolve(O)}),d.hitch(this,function(O){O||(O=this._error("Locator suggestLocations could not be performed."));J.reject(O)}))):N.featureLayer?this._featureLayerLoaded(N.featureLayer).then(d.hitch(this,
function(){var O=this._getDisplayField(N),X=N.searchFields||[O],ha=[];N.suggestionTemplate?N.suggestionTemplate.replace(/(?:\$\{([^}]+)\})/g,function(pa,qa){ha.push(qa)}):ha=[O];-1===c.indexOf(ha,N.featureLayer.objectIdField)&&ha.push(N.featureLayer.objectIdField);O=this._validField(N.featureLayer,O);var ja=this._validFields(N.featureLayer,ha),la=this._validFields(N.featureLayer,X);if(O&&ja&&la){O=new ca;N.hasOwnProperty("suggestQueryParams")&&d.mixin(O,N.suggestQueryParams);O.outSpatialReference=
t;O.returnGeometry=!1;O.num=N.maxSuggestions||this.maxSuggestions;O.outFields=ha;N.useMapExtent&&this.map&&this.map.extent&&(O.geometry=this.map.extent);N.searchExtent&&(O.geometry=N.searchExtent);if(X=this._whereClause(k,N.featureLayer,X,!1)){O.where=X;var ma=!0}ma?N.featureLayer.queryFeatures(O,d.hitch(this,function(pa){var qa;(pa=pa.features)&&(qa=this._hydrateResults(pa,P,!0));J.resolve(qa)}),d.hitch(this,function(pa){pa||(pa=this._error("FeatureLayer queryFeatures errored with suggestions"));
J.reject(pa)})):J.resolve()}else J.reject(this._error("Invalid FeatureLayer field"))})):J.reject(this._error("Invalid source"))}else J.resolve();return J.promise},_supportsPagination:function(f){var J;f.locator?J=!0:f.featureLayer&&f.featureLayer.advancedQueryCapabilities&&f.featureLayer.advancedQueryCapabilities.supportsPagination&&(J=!0);return J},_suggestQueries:function(f){var J=this.sources,P=this.activeSourceIndex,N=[];if(P===this._allIndex)for(P=0;P<J.length;P++){var Z=f;Z.index=P;Z=this._suggest(Z);
N.push(Z)}else f.index=P,Z=this._suggest(f),N.push(Z);return da(N)},_getPointFromGeometry:function(f){switch(f.type){case "extent":var J=f.getCenter();break;case "multipoint":J=f.getPoint(0);break;case "point":J=f;break;case "polygon":J=f.getCentroid();break;case "polyline":J=f.getPoint(0,0)}return J},_searchQueries:function(f){f.hasOwnProperty("index")||(f.index=this.activeSourceIndex);var J=[];if(f.index===this._allIndex)for(var P=this.sources,N=0;N<P.length;N++){var Z=f;Z.index=N;Z=this._search(Z);
J.push(Z)}else f=this._search(f),J.push(f);return da(J)},_searchButton:function(){this.enableButtonMode&&!this.expanded?(this.expand(),F.focus(this.inputNode)):(this._cancelSuggest(),this.search())},_search:function(f){f||(f={text:this.value,magicKey:null,geometry:null,point:null,index:this.activeSourceIndex,latlon:null});this.selectedFeatureId&&(f.text=null,f[this._objectIdIdentifier]=this.selectedFeatureId);var J,P=new n,N=f.index,Z=this.sources[N],ea;f.hasOwnProperty("text")&&f.text&&(ea=d.trim(f.text));
if(Z){var oa="";Z.prefix&&!f.magicKey&&(oa+=Z.prefix);oa+=ea;Z.suffix&&!f.magicKey&&(oa+=Z.suffix);var k=this._defaultSR;this.map&&(k=this.map.spatialReference);if(Z.locator)if(f.hasOwnProperty("text")&&ea){var t={};Z.categories&&(t.categories=Z.categories);Z.locationType&&(t.locationType=Z.locationType);k&&(Z.locator.outSpatialReference=k);if(this.map&&Z.localSearchOptions&&Z.localSearchOptions.hasOwnProperty("distance")&&Z.localSearchOptions.hasOwnProperty("minScale")){var O=this._getScale();if(!Z.localSearchOptions.minScale||
O&&O<=parseFloat(Z.localSearchOptions.minScale))t.location=this.map.extent.getCenter(),t.distance=Z.localSearchOptions.distance}t.address={};t.maxLocations=Z.maxResults||this.maxResults;Z.useMapExtent&&this.map&&this.map.extent&&(t.searchExtent=this.map.extent);Z.searchExtent&&(t.searchExtent=Z.searchExtent);Z.sourceCountry&&(t.countryCode=Z.sourceCountry);Z.countryCode&&(t.countryCode=Z.countryCode);f.magicKey&&(t.magicKey=f.magicKey);Z.singleLineFieldName?t.address[Z.singleLineFieldName]=oa:t.address["Single Line Input"]=
oa;Z.outFields&&(t.outFields=Z.outFields);Z.locator.addressToLocations(t).then(d.hitch(this,function(X){X=this._hydrateResults(X,N,!1);P.resolve(X)}),d.hitch(this,function(X){X||(X=this._error("Locator addressToLocations could not be performed"));P.reject(X)}))}else f.geometry?(J=this._getPointFromGeometry(f.geometry.geometry))?this._reverseGeocodePoint(N,J).then(function(X){P.resolve(X)},function(X){P.reject(X)}):P.reject(this._error("Invalid point to reverse geocode")):f.point?this._reverseGeocodePoint(N,
f.point).then(function(X){P.resolve(X)},function(X){P.reject(X)}):f.latlon?(t=new x(f.latlon,this._defaultSR),this._reverseGeocodePoint(N,t).then(function(X){P.resolve(X)},function(X){P.reject(X)})):f.hasOwnProperty("text")&&!ea?P.resolve([]):P.reject(this._error("Invalid query type for Locator"));else Z.featureLayer?this._featureLayerLoaded(Z.featureLayer).then(d.hitch(this,function(){var X=this._getDisplayField(Z),ha=Z.searchFields||[X];X=this._validField(Z.featureLayer,X);var ja=this._validFields(Z.featureLayer,
ha);if(X&&ja){X=new ca;Z.hasOwnProperty("searchQueryParams")&&d.mixin(X,Z.searchQueryParams);k&&(X.outSpatialReference=k,ja=this.map&&this.map.getMaxResolution()||1/Y.getUnitValueForSR(k))&&(X.maxAllowableOffset=ja);X.returnGeometry=!0;Z.outFields&&(X.outFields=Z.outFields);if(!f.hasOwnProperty(this._objectIdIdentifier)){this._supportsPagination(Z)&&(X.num=Z.maxResults||this.maxResults);Z.useMapExtent&&this.map&&this.map.extent&&(X.geometry=this.map.extent);Z.searchExtent&&(X.geometry=Z.searchExtent);
var la=Z.exactMatch}f.hasOwnProperty("text")&&ea?(ha=this._whereClause(oa,Z.featureLayer,ha,la))?(X.where=ha,ha=!0):ha=!1:f.hasOwnProperty(this._objectIdIdentifier)?(X.objectIds=[f[this._objectIdIdentifier]],ha=!0):f.geometry?(X.geometry=f.geometry,ha=!0):f.point?(X.geometry=f.point,ha=!0):f.latlon?(J=new x(f.latlon,this._defaultSR),X.geometry=J,ha=!0):(f.hasOwnProperty("text")&&!ea?P.resolve([]):P.reject(this._error("Invalid query type for FeatureLayer")),ha=!1);ha?Z.featureLayer.queryFeatures(X,
d.hitch(this,function(ma){ma=ma.features;var pa;ma&&(pa=this._hydrateResults(ma,N,!1));P.resolve(pa)}),d.hitch(this,function(ma){ma||(ma=this._error("FeatureLayer queryFeatures could not be performed"));P.reject(ma)})):P.resolve()}else P.reject(this._error("Invalid FeatureLayer field"))})):P.reject(this._error("Invalid source"))}else P.reject(this._error("Source is undefined"));return P.promise},_clearQueryTimeout:function(){this._queryTimer&&clearTimeout(this._queryTimer)},_formatResults:function(f,
J,P){P={activeSourceIndex:J,value:P,numResults:0,numErrors:0,errors:null,results:null};var N={},Z={};if(f)if(J===this._allIndex)for(J=0;J<f.length;J++)f[J]&&(f[J]instanceof Error?(N[J]=f[J],P.numErrors++):(Z[J]=f[J],P.numResults+=f[J].length));else f[0]&&(f[0]instanceof Error?(N[J]=f[0],P.numErrors++):(Z[J]=f[0],P.numResults+=f[0].length));P.numErrors&&(P.errors=N);P.numResults&&(P.results=Z);return P},_reverseGeocodePoint:function(f,J){var P=new n,N=this.sources[f];if(J&&N){var Z=N.locationToAddressDistance||
this.locationToAddressDistance;N.locator.outSpatialReference=this._defaultSR;this.map&&(N.locator.outSpatialReference=this.map.spatialReference);N.locator.locationToAddress(J,Z,d.hitch(this,function(ea){ea=this._hydrateResults([ea],f,!1);P.resolve(ea)}),d.hitch(this,function(ea){ea||(ea=this._error("Locator locationToAddress could not be performed"));P.reject(ea)}))}else P.reject(this._error("No point or source defined for reverse geocoding"));return P.promise},_cancelDeferreds:function(){if(this._deferreds&&
this._deferreds.length)for(var f=0;f<this._deferreds.length;f++)this._deferreds[f].cancel(this.declaredClass+" cancelling request");this._deferreds=[]},_sourceBtnKey:function(f){if(f){var J=m("li",this.sourcesNode);f.keyCode===B.UP_ARROW?(f.stopPropagation(),f.preventDefault(),this._showSourcesMenu(),(f=J.length)&&F.focus(J[f-1])):f.keyCode===B.DOWN_ARROW&&(f.stopPropagation(),f.preventDefault(),this._showSourcesMenu(),J[0]&&F.focus(J[0]))}},_inputKey:function(f){if(f){var J=m("li",this.suggestionsNode),
P=this.suggestResults;if(f.keyCode===B.TAB||f.keyCode===B.ESCAPE)this._cancelSuggest(),this._hideMenus();else if(f.keyCode===B.UP_ARROW)f.stopPropagation(),f.preventDefault(),this._cancelSuggest(),P&&this._showSuggestionsMenu(),(f=J.length)&&F.focus(J[f-1]);else if(f.keyCode===B.DOWN_ARROW)f.stopPropagation(),f.preventDefault(),this._cancelSuggest(),P&&this._showSuggestionsMenu(),J[0]&&F.focus(J[0]);else{if(f.ctrlKey||f.metaKey||f.keyCode===B.copyKey||f.keyCode===B.LEFT_ARROW||f.keyCode===B.RIGHT_ARROW||
f.keyCode===B.ENTER)return f;this._suggestDelay()}}},_cancelSuggest:function(){this._cancelDeferreds();this._clearQueryTimeout()},_suggestDelay:function(){this._cancelSuggest();this._changeValue();this._queryTimer=setTimeout(d.hitch(this,function(){this.suggest()}),this.suggestionDelay)},_changeValue:function(){this.set("magicKey",null);this.set("selectedFeatureId",null);this._changeAttrValue("value",this.inputNode.value);this._checkStatus()},_inputClick:function(){this._hideSourcesMenu();this._hideNoResultsMenu()},
_getSourceName:function(f){return this._sourceNames[f]},_loadSources:function(f){f=c.filter(f,function(J){return!!J.featureLayer});f=c.map(f,function(J){return this._featureLayerLoaded(J.featureLayer)},this);return da(f)},_createSourceNameMap:function(f){return this._loadSources(f).then(d.hitch(this,function(){var J=c.map(f,function(P){return P.name||P.featureLayer&&P.featureLayer.name||v.widgets.Search.main.untitledSource});this._preventDuplicateSourceNames(f,J);return J}))},_getDuplicateSourceNameIndexes:function(f){var J=
{},P=[];c.forEach(f,function(N,Z){J.hasOwnProperty(N)?(-1===P.indexOf(J[N])&&P.push(J[N]),P.push(Z)):f.lastIndexOf(N)!==Z&&(J[N]=Z)});return P},_preventDuplicateSourceNames:function(f,J){if(J&&1<J.length){var P=this._getDuplicateSourceNameIndexes(J);c.forEach(P,function(N){J[N]+=this._getFieldsString(f[N])},this)}},_getFieldsString:function(f){var J="",P=f.featureLayer;if(P){f=f.searchFields||[this._getDisplayField(f)];for(var N=0;N<f.length;N++){J=0===N?J+": ":J+", ";var Z=f[N],ea=P.getFieldLabel(Z);
J+=ea||Z}}return J},_splitResult:function(f,J){J=I.escapeString(J);return f.replace(new RegExp("(^|)("+J+")(|$)","ig"),"$1|$2|$3").split("|")},_insertSuggestions:function(f,J){if(this.enableSuggestionsMenu&&this.suggestionsNode){this._hideSourcesMenu();this._hideNoResultsMenu();var P=this.sources;if(f){var N=M.create("div");for(var Z in f)if(f[Z]&&f[Z].length){var ea=this._getSourceName(Z);1<P.length&&this.activeSourceIndex===this._allIndex&&M.create("div",{className:this.css.searchMenuHeader,textContent:ea},
N);ea=M.create("ul",{role:"menu"},N);for(var oa=P[Z].maxSuggestions||this.maxSuggestions,k=0;k<f[Z].length&&k<oa;++k){var t=M.create("li",{"data-index":k,"data-source-index":Z,role:"menuitem",tabindex:0},ea),O=this._getSuggestionName(f[Z][k]);O=this._splitResult(O,J);for(var X=O.length,ha=0;ha<X;ha++){var ja=O[ha];ja.toLowerCase()===J.toLowerCase()?M.create("strong",{textContent:ja},t):(ja=document.createTextNode(ja),M.place(ja,t))}}}}N?(M.place(N,this.suggestionsNode,"only"),this._showSuggestionsMenu()):
(M.empty(this.suggestionsNode),this._hideSuggestionsMenu())}},_insertSources:function(f){if(this.enableSourcesMenu&&f&&1<f.length){var J,P=this.activeSourceIndex,N=M.create("ul",{role:"menu"});if(this.enableSearchingAll){var Z="";P===this._allIndex&&(Z="active");M.create("li",{"data-index":this._allIndex,role:"menuitem",className:Z,tabIndex:0,textContent:v.widgets.Search.main.all},N)}for(J=0;J<f.length;J++){Z="";J===P&&(Z=this.css.activeSource);var ea=this._getSourceName(J);M.create("li",{"data-index":J,
role:"menuitem",className:Z,tabIndex:0,textContent:ea},N)}q.add(this.containerNode,this.css.hasMultipleSources);M.place(N,this.sourcesNode,"only")}else q.remove(this.containerNode,this.css.hasMultipleSources),M.empty(this.sourcesNode)},_showLoading:function(){q.add(this.containerNode,this.css.searchLoading)},_hideLoading:function(){q.remove(this.containerNode,this.css.searchLoading)},_checkStatus:function(){this.value?(q.add(this.containerNode,this.css.hasValue),b.set(this.clearNode,"title",v.widgets.Search.main.clearButtonTitle)):
this.clear()},_closePopup:function(){this.enableInfoWindow&&this.map&&this.map.infoWindow&&this.map.infoWindow.hide()},_noResults:function(f){var J;f&&(J=d.trim(f));var P=M.create("div",{className:this.css.searchNoResultsBody});f&&J?(M.create("div",{className:this.css.searchNoResultsHeader,textContent:v.widgets.Search.main.noResults},P),M.create("div",{className:this.css.searchNoResultsText,textContent:l.substitute({value:'"'+f+'"'},v.widgets.Search.main.noResultsFound)},P)):(f=M.create("div",{},
P),M.create("span",{"aria-hidden":"true",className:this.css.searchNoValueIcon},f),M.create("span",{className:this.css.searchNoValueText,textContent:v.widgets.Search.main.emptyValue},f));M.place(P,this.noResultsMenuNode,"only")},_hideMenus:function(){this._hideSourcesMenu();this._hideSuggestionsMenu();this._hideNoResultsMenu()},_hideNoResultsMenu:function(){q.remove(this.containerNode,this.css.showNoResults)},_showNoResultsMenu:function(){this._hideSourcesMenu();this._hideSuggestionsMenu();q.add(this.containerNode,
this.css.showNoResults)},_hideSourcesMenu:function(){q.remove(this.containerNode,this.css.showSources)},_hideSuggestionsMenu:function(){q.remove(this.containerNode,this.css.showSuggestions)},_showSourcesMenu:function(){this._hideSuggestionsMenu();this._hideNoResultsMenu();q.add(this.containerNode,this.css.showSources)},_showSuggestionsMenu:function(){this._hideSourcesMenu();this._hideNoResultsMenu();q.add(this.containerNode,this.css.showSuggestions)},_toggleSourcesMenu:function(){this._hideSuggestionsMenu();
this._hideNoResultsMenu();q.toggle(this.containerNode,this.css.showSources)},_getFirstStringField:function(f){if(f&&(f=f.fields)&&f.length)for(var J=0;J<f.length;J++){var P=f[J];if("esriFieldTypeString"===P.type)return P.name}return""},_getDisplayField:function(f){return f.displayField||f.featureLayer.displayField||this._getFirstStringField(f.featureLayer)},_validLocation:function(f){return f&&"number"===typeof f.x&&"number"===typeof f.y},_validExtent:function(f){return f&&"number"===typeof f.xmin&&
"number"===typeof f.ymin&&"number"===typeof f.xmax&&"number"===typeof f.ymax},_hydrateResult:function(f,J,P){var N={},Z=this._defaultSR;J=this.sources[J];this.map&&(Z=this.map.spatialReference);if(f.hasOwnProperty("text")&&f.hasOwnProperty("magicKey"))return f;if(f.hasOwnProperty("geometry")){var ea=new W(f.toJson());N.feature=ea;(ea=N.feature.geometry)&&ea.setSpatialReference(Z)}else if(f.hasOwnProperty("location")&&this._validLocation(f.location)){var oa=new x(f.location.x,f.location.y,Z);ea={};
f.hasOwnProperty("attributes")&&(ea=f.attributes);f.hasOwnProperty("address")&&"object"===typeof f.address&&d.mixin(ea,f.address);f.hasOwnProperty("score")&&(ea.score=f.score);N.feature=new W(oa,null,ea,null)}!N.feature&&P&&(ea={},f.hasOwnProperty("attributes")&&(ea=f.attributes),f.hasOwnProperty("score")&&(ea.score=f.score),N.feature=new W(null,null,ea,null));if(N.feature){if(f.hasOwnProperty("extent")&&this._validExtent(f.extent))N.extent=new H(f.extent),N.extent.setSpatialReference(Z);else if(N.feature&&
N.feature.geometry)switch(N.feature.geometry.type){case "extent":N.extent=N.feature.geometry;break;case "multipoint":N.extent=L.getDenormalizedExtent(N.feature.geometry);break;case "polygon":N.extent=L.getDenormalizedExtent(N.feature.geometry);break;case "polyline":N.extent=L.getDenormalizedExtent(N.feature.geometry);break;case "point":this.map?(Z=this.zoomScale,J&&J.zoomScale&&(Z=J.zoomScale),this._getScale()>Z?N.extent=Y.getExtentForScale(this.map,Z).centerAt(N.feature.geometry):N.extent=this.map.extent.centerAt(N.feature.geometry)):
N.extent=new H({xmin:N.feature.geometry.x-.25,ymin:N.feature.geometry.y-.25,xmax:N.feature.geometry.x+.25,ymax:N.feature.geometry.y+.25,spatialReference:this._defaultSR})}else N.extent=null;N.name="";J.featureLayer?J.suggestionTemplate&&P?N.name=l.substitute(f.attributes,J.suggestionTemplate):J.searchTemplate?N.name=l.substitute(f.attributes,J.searchTemplate):(ea=this._getDisplayField(J),P=J.featureLayer.getField(ea),Z=J.featureLayer.getDomain(ea),ea&&f.hasOwnProperty("attributes")&&f.attributes.hasOwnProperty(ea)&&
(f=f.attributes[ea],Z&&"codedValue"===Z.type?N.name=this._getCodedName(Z.codedValues,f):P&&"esriFieldTypeDate"===P.type&&!isNaN(f)?N.name=z.format(new Date(f)):N.name=f)):f.address&&J.searchTemplate?N.name=l.substitute(f.address,J.searchTemplate):f.hasOwnProperty("name")?N.name=f.name:f.hasOwnProperty("attributes")&&"object"===typeof f.attributes&&f.attributes.LongLabel?N.name=f.attributes.LongLabel:f.hasOwnProperty("attributes")&&"object"===typeof f.attributes&&f.attributes.Match_addr?(N.name=f.attributes.Match_addr,
f.attributes.Addr_type&&"POI"===f.attributes.Addr_type&&f.attributes.StAddr&&f.attributes.City?N.name+=" - "+f.attributes.StAddr+", "+f.attributes.City:f.attributes.Addr_type&&"POI"===f.attributes.Addr_type&&f.attributes.City&&(N.name+=" - "+f.attributes.City)):f.hasOwnProperty("address")&&"string"===typeof f.address?N.name=f.address:f.hasOwnProperty("address")&&"object"===typeof f.address&&f.address.hasOwnProperty("Address")?f.address.hasOwnProperty("Match_addr")?N.name=f.address.Match_addr:f.address.hasOwnProperty("Address")&&
(N.name=f.address.Address):N.feature&&N.feature.geometry&&(N.name=N.feature.geometry.x+","+N.feature.geometry.y);J.featureLayer&&N.feature&&ka(N.feature,J.featureLayer);return N}},_getScale:function(){var f;this.map&&"function"===typeof this.map.getScale&&(f=this.map.getScale());return f},_hydrateResults:function(f,J,P,N){N=[];var Z=0;if(f&&f.length)for(Z;Z<f.length;Z++){var ea=this._hydrateResult(f[Z],J,P);ea&&N.push(ea)}return N},_containsNonLatinCharacter:function(f){for(var J=0;J<f.length;J++)if(255<
f.charCodeAt(J))return!0;return!1},_setPlaceholder:function(f){var J="",P=this.sources[f];f===this._allIndex?J=this.allPlaceholder||v.widgets.Search.main.allPlaceholder:P&&P.placeholder&&(J=P.placeholder);var N=v.widgets.Search.main.all;P&&(N=this._getSourceName(f));b.set(this.sourceNameNode,"textContent",N);b.set(this.inputNode,"placeholder",J);b.set(this.inputNode,"title",J)},_updateActiveSource:function(){var f=this.sources,J=this.activeSourceIndex,P;f&&f[J]&&(P=f[J]);P?this.set("activeSource",
P):this.set("activeSource",null)},_updateVisible:function(){this.visible?this.show():this.hide()},_updateButtonMode:function(f){f?(q.toggle(this.containerNode,this.css.searchExpanded,this.expanded),q.toggle(this.containerNode,this.css.searchCollapsed,!this.expanded),q.add(this.containerNode,this.css.hasButtonMode)):(q.remove(this.containerNode,this.css.searchExpanded),q.remove(this.containerNode,this.css.searchCollapsed),q.remove(this.containerNode,this.css.hasButtonMode))},_setDefaultActiveSourceIndex:function(f){f&&
1===f.length||!this.enableSearchingAll?this.set("activeSourceIndex",0):this.set("activeSourceIndex",this._allIndex)},_setEnableSourcesMenuAttr:function(f){this._set("enableSourcesMenu",f);this._created&&this._insertSources(this.sources)},_setEnableSearchingAllAttr:function(f){this._set("enableSearchingAll",f);this._created&&(this._setDefaultActiveSourceIndex(this.sources),this._hideMenus(),this._insertSources(this.sources))},_setSourcesAttr:function(f){this._createSourceNameMap(f).then(d.hitch(this,
function(J){this._sourceNames=J;this._created&&(this._setDefaultActiveSourceIndex(f),this._hideMenus(),this._insertSources(f))}));this._set("sources",f)},_setAllPlaceholderAttr:function(f){this._set("allPlaceholder",f);this._created&&this._setPlaceholder(this.activeSourceIndex)},_setActiveSourceIndexAttr:function(f){this._set("activeSourceIndex",f);this._updateActiveSource();this._created&&(this._setPlaceholder(f),this._hideMenus(),this._insertSources(this.sources))},_setMaxLengthAttr:function(f){this._set("maxLength",
f);this._created&&b.set(this.inputNode,"maxLength",f)},_setValueAttr:function(f){this.set("magicKey",null);this.set("selectedFeatureId",null);this._set("value",f);this._created&&(b.set(this.inputNode,"value",f),this._checkStatus())},_setVisibleAttr:function(f){this._set("visible",f);this._created&&this._updateVisible()},_setEnableButtonModeAttr:function(f){this._set("enableButtonMode",f);this._created&&this._updateButtonMode(f)},_setThemeAttr:function(f){this._created&&(q.remove(this.domNode,this.theme),
q.add(this.domNode,f));this._set("theme",f)}});y("extend-esri")&&d.setObject("dijit.Search",a,R);return a})},"esri/tasks/locator":function(){define("dojo/_base/declare dojo/_base/lang dojo/_base/array dojo/_base/Deferred dojo/_base/json dojo/has ../kernel ../request ../deferredUtils ./Task ./AddressCandidate".split(" "),function(D,a,d,c,w,n,B,C,m,y,I){D=D(y,{declaredClass:"esri.tasks.Locator",_eventMap:{"address-to-locations-complete":["addresses"],"addresses-to-locations-complete":["addresses"],
"location-to-address-complete":["address"],"suggest-locations-complete":["suggestions"]},constructor:function(e){this._geocodeHandler=a.hitch(this,this._geocodeHandler);this._geocodeAddressesHandler=a.hitch(this,this._geocodeAddressesHandler);this._reverseGeocodeHandler=a.hitch(this,this._reverseGeocodeHandler);this.registerConnectEvents()},outSpatialReference:null,setOutSpatialReference:function(e){this.outSpatialReference=e},_geocodeHandler:function(e,b,q,K,M){try{var z=e.candidates;b=[];var v,
Q=z.length,S=e.spatialReference,U;for(v=0;v<Q;v++){var g=z[v];if(U=g.location)U.spatialReference=S;b[v]=new I(g)}this._successHandler([b],"onAddressToLocationsComplete",q,M)}catch(G){this._errorHandler(G,K,M)}},_geocodeAddressesHandler:function(e,b,q,K,M){try{var z=e.locations;b=[];var v,Q=z.length,S=e.spatialReference,U;for(v=0;v<Q;v++){if(U=z[v].location)U.spatialReference=S;b[v]=new I(z[v])}this._successHandler([b],"onAddressesToLocationsComplete",q,M)}catch(g){this._errorHandler(g,K,M)}},addressToLocations:function(e,
b,q,K,M){var z;if(e.address){K=q;q=b;b=e.outFields;M=e.searchExtent;var v=e.countryCode;var Q=e.magicKey;var S=e.distance;var U=e.categories;e.location&&this.normalization&&(z=e.location.normalize());var g=e.locationType;var G=e.maxLocations;var F=e.forStorage;e=e.address}M&&(M=M.shiftCentralMeridian());var l=this.outSpatialReference;e=this._encode(a.mixin({},this._url.query,e,{f:"json",outSR:l&&w.toJson(l.toJson()),outFields:b&&b.join(",")||null,searchExtent:M&&w.toJson(M.toJson()),category:U&&U.join(",")||
null,countryCode:v||null,magicKey:Q||null,distance:S||null,location:z||null,locationType:g||null,maxLocations:G||null,forStorage:F||null}));var E=this._geocodeHandler,R=this._errorHandler,aa=new c(m._dfdCanceller);aa._pendingDfd=C({url:this._url.path+"/findAddressCandidates",content:e,callbackParamName:"callback",load:function(W,da){E(W,da,q,K,aa)},error:function(W){R(W,K,aa)}});return aa},suggestLocations:function(e){var b=new c(m._dfdCanceller);e.hasOwnProperty("location")&&this.normalization&&
(e.location=e.location.normalize());e.searchExtent&&(e.searchExtent=e.searchExtent.shiftCentralMeridian());e=this._encode(a.mixin({},this._url.query,{f:"json",text:e.text,maxSuggestions:e.maxSuggestions,searchExtent:e.searchExtent&&w.toJson(e.searchExtent.toJson()),category:e.categories&&e.categories.join(",")||null,countryCode:e.countryCode||null,location:e.location||null,distance:e.distance||null},{f:"json"}));e=C({url:this._url.path+"/suggest",content:e,callbackParamName:"callback"});b._pendingDfd=
e;e.then(a.hitch(this,function(q){q=q.suggestions||[];this.onSuggestLocationsComplete(q);b.resolve(q)}),a.hitch(this,function(q){this._errorHandler(q);b.reject(q)}));return b},addressesToLocations:function(e,b,q){var K=this.outSpatialReference,M=[],z=e.categories,v=e.locationType,Q=e.countryCode;d.forEach(e.addresses,function(G,F){M.push({attributes:G})});e=this._encode(a.mixin({},this._url.query,{category:z&&z.join(",")||null,locationType:v||null,sourceCountry:Q||null},{addresses:w.toJson({records:M})},
{f:"json",outSR:K&&w.toJson(K.toJson())}));var S=this._geocodeAddressesHandler,U=this._errorHandler,g=new c(m._dfdCanceller);g._pendingDfd=C({url:this._url.path+"/geocodeAddresses",content:e,callbackParamName:"callback",load:function(G,F){S(G,F,b,q,g)},error:function(G){U(G,q,g)}});return g},_reverseGeocodeHandler:function(e,b,q,K,M){try{var z=new I({address:e.address,location:e.location,score:100});this._successHandler([z],"onLocationToAddressComplete",q,M)}catch(v){this._errorHandler(v,K,M)}},locationToAddress:function(e,
b,q,K){e&&this.normalization&&(e=e.normalize());var M=this.outSpatialReference;e=this._encode(a.mixin({},this._url.query,{outSR:M&&w.toJson(M.toJson()),location:e&&w.toJson(e.toJson()),distance:b,f:"json"}));var z=this._reverseGeocodeHandler,v=this._errorHandler,Q=new c(m._dfdCanceller);Q._pendingDfd=C({url:this._url.path+"/reverseGeocode",content:e,callbackParamName:"callback",load:function(S,U){z(S,U,q,K,Q)},error:function(S){v(S,K,Q)}});return Q},onSuggestLocationsComplete:function(){},onAddressToLocationsComplete:function(){},
onAddressesToLocationsComplete:function(){},onLocationToAddressComplete:function(){}});n("extend-esri")&&a.setObject("tasks.Locator",D,B);return D})},"esri/tasks/AddressCandidate":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/has","../kernel","../geometry/Point"],function(D,a,d,c,w){D=D(null,{declaredClass:"esri.tasks.AddressCandidate",constructor:function(n){a.mixin(this,n);this.location=new w(this.location)}});d("extend-esri")&&a.setObject("tasks.AddressCandidate",D,c);return D})},
"esri/styles/basic":function(){define(["dojo/_base/array","dojo/_base/lang","dojo/has","../kernel","../Color"],function(D,a,d,c,w){function n(I,e){if(I){var b={};b.color=new w(I.color);b.opacity=I.opacity||1;switch(e){case "point":b.outline={color:new w(I.outline.color),width:I.outline.width};b.size=I.size;break;case "line":b.width=I.width;break;case "polygon":b.outline={color:new w(I.outline.color),width:I.outline.width}}}return b}function B(I){if("esriGeometryPoint"===I||"esriGeometryMultipoint"===
I)I="point";else if("esriGeometryPolyline"===I)I="line";else if("esriGeometryPolygon"===I||"esriGeometryMultiPatch"===I)I="polygon";return I}var C={"default":{name:"default",label:"Default",description:"Default theme for basic visualization of features.",basemapGroups:{light:"streets gray topo terrain national-geographic oceans osm gray-vector streets-vector topo-vector streets-relief-vector streets-navigation-vector".split(" "),dark:["satellite","hybrid","dark-gray","dark-gray-vector","streets-night-vector"]},
pointSchemes:{light:{primary:{color:[77,77,77,1],outline:{color:[255,255,255,.25],width:1},size:8},secondary:[{color:[226,119,40,1],outline:{color:[255,255,255,.25],width:1},size:8},{color:[255,255,255,1],outline:{color:[51,51,51,.25],width:1},size:8}]},dark:{primary:{color:[255,255,255,1],outline:{color:[92,92,92,.25],width:1},size:8},secondary:[{color:[226,119,40,1],outline:{color:[255,255,255,.25],width:1},size:8},{color:[26,26,26,1],outline:{color:[178,178,178,.25],width:1},size:8}]}},lineSchemes:{light:{primary:{color:[77,
77,77,1],width:2},secondary:[{color:[226,119,40,1],width:2},{color:[255,255,255,1],width:2}]},dark:{primary:{color:[255,255,255,1],width:2},secondary:[{color:[226,119,40,1],width:2},{color:[26,26,26,1],width:2}]}},polygonSchemes:{light:{primary:{color:[227,139,79,1],outline:{color:[255,255,255,.25],width:1},opacity:.8},secondary:[{color:[128,128,128,1],outline:{color:[255,255,255,.25],width:1},opacity:.8},{color:[255,255,255,1],outline:{color:[128,128,128,.25],width:1},opacity:.8}]},dark:{primary:{color:[227,
139,79,1],outline:{color:[92,92,92,.25],width:1},opacity:.8},secondary:[{color:[178,178,178,1],outline:{color:[92,92,92,.25],width:1},opacity:.8},{color:[26,26,26,1],outline:{color:[128,128,128,.25],width:1},opacity:.8}]}}}},m={};(function(){var I,e,b;for(I in C){var q=C[I];var K=q.basemapGroups;var M=m[I]={basemaps:[].concat(K.light).concat(K.dark),point:{},line:{},polygon:{}};for(e in K){var z=K[e];for(b=0;b<z.length;b++){var v=z[b];q.pointSchemes&&(M.point[v]=q.pointSchemes[e]);q.lineSchemes&&
(M.line[v]=q.lineSchemes[e]);q.polygonSchemes&&(M.polygon[v]=q.polygonSchemes[e])}}}})();var y={getAvailableThemes:function(I){var e=[],b;for(b in C){var q=C[b];var K=m[b];I&&-1===D.indexOf(K.basemaps,I)||e.push({name:q.name,label:q.label,description:q.description,basemaps:K.basemaps.slice(0)})}return e},getSchemes:function(I){var e=I.theme,b=I.basemap,q=B(I.geometryType);I=m[e];var K;(I=(I=I&&I[q])&&I[b])&&(K={primaryScheme:n(I.primary,q),secondarySchemes:D.map(I.secondary,function(M){return n(M,
q)})});return K},cloneScheme:function(I){if(I){var e=a.mixin({},I);e.color&&(e.color=new w(e.color));e.outline&&(e.outline={color:e.outline.color&&new w(e.outline.color),width:e.outline.width})}return e}};d("extend-esri")&&a.setObject("styles.basic",y,c);return y})},"widgets/Screening/searchSourceUtils":function(){define("dojo/_base/lang dojo/_base/array dojo/Deferred dojo/when dojo/promise/all jimu/portalUtils esri/lang esri/request".split(" "),function(D,a,d,c,w,n,B,C){return{map:null,layerInfosObj:null,
appConfig:null,_esriLocatorRegExp:/geocode(.){0,3}\.arcgis.com\/arcgis\/rest\/services\/World\/GeocodeServer/g,setMap:function(m){this.map=m},setLayerInfosObj:function(m){this.layerInfosObj=m},setAppConfig:function(m){this.appConfig=m},getConfigInfo:function(m){if(m&&m.sources&&0<m.sources.length){var y=null;return this.searchLayer(this.map)&&m.upgradeFromGeocoder?(y=this.map.itemInfo.itemData.applicationProperties.viewing.search,y=a.map(y.layers,D.hitch(this,function(I,e){e.hintText=I;return this._getQueryTypeGeocoder(e)},
y.hintText)),w(y).then(D.hitch(this,function(I){m.sources=[].concat(I).concat(m.sources);return m}))):m}return c(this._getSourcesFromPortalAndWebmap()).then(D.hitch(this,function(I){return{allPlaceholder:"",showInfoWindowOnSelect:!0,sources:I}}))},_getSourcesFromPortalAndWebmap:function(){var m=[],y=null;this.searchLayer(this.map)&&(y=this.map.itemInfo.itemData.applicationProperties.viewing.search,a.forEach(y.layers,D.hitch(this,function(I,e){e.hintText=I;m.push(this._getQueryTypeGeocoder(e))},y.hintText)));
return n.getPortalSelfInfo(this.appConfig.portalUrl).then(D.hitch(this,function(I){if((I=I.helperServices&&I.helperServices.geocode)&&0<I.length)for(var e=0,b=I.length;e<b;e++){var q=I[e];q&&m.push(this._processSingleLine(q))}return w(m).then(D.hitch(this,function(K){for(var M=[],z=0;z<K.length;z++){var v=K[z];v&&(v&&"query"===v.type?M.push(v):(v={name:v.name||this._getGeocodeName(v.url),url:v.url,singleLineFieldName:v.singleLineFieldName,placeholder:v.placeholder||v.name||this._getGeocodeName(v.url),
maxResults:6,searchInCurrentMapExtent:!1,type:"locator"},v.enableLocalSearch=this._isEsriLocator(v.url),v.localSearchMinScale=3E5,v.localSearchDistance=5E4,M.push(v)))}return M}))}))},_getQueryTypeGeocoder:function(m){var y=this.map.getLayer(m.id),I=null,e=null,b=null;b=B.isDefined(m.subLayer)?m.id+"_"+m.subLayer:m.id;I=this.layerInfosObj.traversal(function(q){return q.id===b?(e=q,!0):!1});return y&&I&&e?(I=B.isDefined(m.subLayer)?e.url||y.url+"/"+m.subLayer:e.url||y.url,{name:e.title,layerId:b,url:I,
placeholder:m.hintText,searchFields:[m.field.name],displayField:m.field.name,exactMatch:m.field.exactMatch||!1,maxResults:6,searchInCurrentMapExtent:!1,type:"query"}):null},_isEsriLocator:function(m){this._esriLocatorRegExp.lastIndex=0;return this._esriLocatorRegExp.test(m)},_processSingleLine:function(m){if(m.singleLineFieldName)return m;if(this._isEsriLocator(m.url))return m.singleLineFieldName="SingleLine",m;var y=new d;C({url:m.url,content:{f:"json"},handleAs:"json",callbackParamName:"callback"}).then(D.hitch(this,
function(I){I.singleLineAddressField&&I.singleLineAddressField.name?(m.singleLineFieldName=I.singleLineAddressField.name,y.resolve(m)):(console.warn(m.url+"has no singleLineFieldName"),y.resolve(null))}),D.hitch(this,function(I){console.error(I);y.resolve(null)}));return y.promise},_getGeocodeName:function(m){if("string"!==typeof m)return"geocoder";m=m.split("/");return m[m.length-2]||"geocoder"},getGeocoderName:function(m){return this._getGeocodeName(m)},hasAppSearchInfo:function(m){return m.itemInfo&&
m.itemInfo.itemData&&m.itemInfo.itemData.applicationProperties&&m.itemInfo.itemData.applicationProperties.viewing&&m.itemInfo.itemData.applicationProperties.viewing.search},searchLayer:function(m){if(!this.hasAppSearchInfo(m))return!1;m=m.itemInfo.itemData.applicationProperties.viewing.search;return m.enabled&&0!==m.layers.length?!0:!1}}})},"widgets/Screening/drawTool/drawTool":function(){define("dojo/_base/declare dojo/text!./drawTool.html dijit/_WidgetsInTemplateMixin dojo/_base/lang dojo/Evented dojo/on dojo/dom-construct dojo/query dojo/dom-class dojo/_base/array jimu/BaseWidget jimu/dijit/DrawBox jimu/dijit/FeatureSetChooserForMultipleLayers jimu/SelectionManager esri/geometry/geometryEngine dojo/_base/html dojo/_base/array ./SelectableLayerItem jimu/dijit/Message dijit/focus dojo/dom-style dojo/keys dojo/_base/event jimu/utils dojo/dom-attr".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U,g,G,F,l){return D([I,d,w],{baseClass:"jimu-widget-screening-drawTool",templateString:a,_drawTool:null,_filteredLayerArray:[],selectTool:null,layerItems:null,currentSelectedDrawTool:null,_selectToolFocusElement:null,constructor:function(E){this._drawTool=null;this._filteredLayerArray=[];this._selectToolFocusElement=this.currentSelectedDrawTool=this.layerItems=this.selectTool=null;c.mixin(this,E)},postCreate:function(){this.layerItems=[];this._createFeatureLayerArr();
this._initializeDrawBoxTools();this.config.drawToolSelectableLayers&&0<this.config.drawToolSelectableLayers.length||!this.config.drawToolSelectableLayers?(this._initializeSelectTool(),this._setFeatureLayersForSelectTool(),this._initLayers()):this._hideLayerChooserListOfSelectTool();this.own(n(this.layerSectionIcon,"click",c.hitch(this,function(E){G.stop(E);this._showOrHideLayerDetailsContainer()})));this.own(n(this.impactSummaryLayerTitle,"click",c.hitch(this,this._showOrHideLayerDetailsContainer)));
this.own(n(this.layerSectionIcon,"keydown",c.hitch(this,function(E){if(E.keyCode===g.ENTER||E.keyCode===g.SPACE)G.stop(E),this._showOrHideLayerDetailsContainer();E.keyCode!==g.ESCAPE||this.isSingleTabSelected||(G.stop(E),this.emit("focusLastSelectedTab"))})));this.own(n(this.impactSummaryLayerTitle,"keydown",c.hitch(this,function(E){if(E.keyCode===g.ENTER||E.keyCode===g.SPACE)G.stop(E),this._showOrHideLayerDetailsContainer()})));this.own(n(this.selectAllLayers,"click",c.hitch(this,function(E){G.stop(E);
this._selectAllLayers()})));this.own(n(this.selectAllLayers,"keydown",c.hitch(this,function(E){if(E.keyCode===g.ENTER||E.keyCode===g.SPACE)G.stop(E),this._selectAllLayers();E.keyCode!==g.ESCAPE||this.isSingleTabSelected||(G.stop(E),this.emit("focusLastSelectedTab"))})));this.own(n(this.singleLayerSelectionWarning,"click",c.hitch(this,function(E){G.stop(E);this._showMessage(this.nls.drawToolWidget.layerSelectionWarningTooltip)})));this.own(n(this.singleLayerSelectionWarning,"keydown",c.hitch(this,
function(E){if(E.keyCode===g.ENTER||E.keyCode===g.SPACE)G.stop(E),this._showMessage(this.nls.drawToolWidget.layerSelectionWarningTooltip);E.keyCode!==g.ESCAPE||this.isSingleTabSelected||(G.stop(E),this.emit("focusLastSelectedTab"))})))},_initLayers:function(){M.empty(this.layerItemsNode);z.forEach(this._filteredLayerArray,c.hitch(this,function(E){if(E&&E.objectIdField&&E.geometryType){var R;z.forEach(this.layerInfoArray,c.hitch(this,function(W){W.id===E.id&&(R=W)}));var aa=new v({layerInfo:R,checked:!0,
layerVisible:!0,map:this.map,nls:this.nls,isSingleTabSelected:this.isSingleTabSelected});this.own(n(aa,"stateChange",c.hitch(this,function(){this.emit("clearExistingSelection");this.selectTool.setFeatureLayers(this._getSelectableLayers());this._updateSelectAllState()})));this.own(n(aa,"focusLastSelectedTab",c.hitch(this,function(){this.emit("focusLastSelectedTab")})));aa.init(E);M.place(aa.domNode,this.layerItemsNode);aa.startup();this.layerItems.push(aa)}}))},_getSelectableLayers:function(){var E=
[];z.forEach(this.layerItems,function(R){R.isLayerVisible()&&R.isChecked()&&E.push(R.featureLayer)},this);return E},_showOrHideLayerDetailsContainer:function(){m.contains(this.layerSectionIcon,"esriCTLayerPanelCollapseIcon")?(m.add(this.entireLayerParentContainer,"esriCTHidden"),m.replace(this.layerSectionIcon,"esriCTLayerPanelExpandIcon","esriCTLayerPanelCollapseIcon"),l.set(this.layerSectionIcon,"aria-expanded","false")):(m.remove(this.entireLayerParentContainer,"esriCTHidden"),m.replace(this.layerSectionIcon,
"esriCTLayerPanelCollapseIcon","esriCTLayerPanelExpandIcon"),l.set(this.layerSectionIcon,"aria-expanded","true"))},_selectAllLayers:function(){var E;M.toggleClass(this.selectAllLayers,"checked");(E=m.contains(this.selectAllLayers,"checked"))?l.set(this.selectAllLayers,"aria-checked","true"):l.set(this.selectAllLayers,"aria-checked","false");z.forEach(this.layerItems,function(R){E?m.contains(R.selectableCheckBox,"checked")||(R.selectableCheckBox.click(),l.set(R.selectableCheckBox,"aria-checked","true")):
m.contains(R.selectableCheckBox,"checked")&&(R.selectableCheckBox.click(),l.set(R.selectableCheckBox,"aria-checked","false"))})},_updateSelectAllState:function(){var E;var R=!0;var aa=m.contains(this.selectAllLayers,"checked");z.forEach(this.layerItems,function(W){m.contains(W.selectableCheckBox,"checked")?R=!1:E=!0});E?(m.remove(this.selectAllLayers,"checked"),l.set(this.selectAllLayers,"aria-checked","false")):aa||(m.add(this.selectAllLayers,"checked"),l.set(this.selectAllLayers,"aria-checked",
"true"));R?(m.remove(this.singleLayerSelectionWarning,"esriCTHidden"),this.singleLayerSelectionWarning.focus()):m.add(this.singleLayerSelectionWarning,"esriCTHidden")},_createFeatureLayerArr:function(){if(this.config.drawToolSelectableLayers)z.forEach(this.config.drawToolSelectableLayers,c.hitch(this,function(R){R=this.layerInfosObj.getLayerInfoById(R).layerObject;""!==R&&null!==R&&void 0!==R&&this._filteredLayerArray.push(R)}));else for(var E in this.filteredLayerObj)this.filteredLayerObj.hasOwnProperty(E)&&
this._filteredLayerArray.push(this.filteredLayerObj[E])},_hideAllTheDrawTools:function(){this._drawTool&&C(".draw-item",this._drawTool.domNode).addClass("esriCTHidden")},_initializeDrawBoxTools:function(){var E;var R=[];var aa=!1;this.config.hasOwnProperty("showPointTool")&&this.config.showPointTool&&R.push("POINT");this.config.hasOwnProperty("showPolylineTool")&&this.config.showPolylineTool&&R.push("POLYLINE");this.config.hasOwnProperty("showExtentTool")&&this.config.showExtentTool&&R.push("EXTENT");
this.config.hasOwnProperty("showPolygonTool")&&this.config.showPolygonTool&&R.push("POLYGON");this.config.hasOwnProperty("showCircleTool")&&this.config.showCircleTool&&R.push("CIRCLE");if(this.config.hasOwnProperty("showPointTool")||this.config.hasOwnProperty("showPolylineTool")||this.config.hasOwnProperty("showExtentTool")||this.config.hasOwnProperty("showPolygonTool")||this.config.hasOwnProperty("showCircleTool"))aa=!0;this.config.hasOwnProperty("showPointTool")||this.config.hasOwnProperty("showPolylineTool")||
this.config.hasOwnProperty("showExtentTool")||this.config.hasOwnProperty("showPolygonTool")||this.config.hasOwnProperty("showCircleTool")||R.push("POINT","POLYLINE","EXTENT","POLYGON");this._drawTool=new e({geoTypes:R,map:this.map,pointSymbol:this.pointSymbol,polylineSymbol:this.polylineSymbol,polygonSymbol:this.polygonSymbol},this.drawToolIconsParentDiv);this._drawTool.startup();this._attachKeydownEventToTheNodes();this._addAriaLabelToDrawTools();aa&&0===R.length&&this._hideAllTheDrawTools();this.own(n(this._drawTool,
"draw-activate",c.hitch(this,function(W){this.currentSelectedDrawTool=W;this._hideLayerChooserListOfSelectTool();this.selectTool&&this.selectTool.isActive()&&this._drawTool.drawToolBar.activate(W);"extent"===W&&this.map.disablePan();this.map.setInfoWindowOnClick(!1)})));this.own(n(this._drawTool,"draw-end",c.hitch(this,function(W){this.clearAllSelections(!0);this._drawTool.drawLayer.clear();this.map.enablePan();(E="polygon"===W.geometry.type?K.simplify(W.geometry):W.geometry)?this.emit("onDrawComplete",
[W]):this._drawTool.drawLayer.clear();this.map.setInfoWindowOnClick(!0);this._activateLastSelectedTool()})))},_initializeSelectTool:function(){this.selectTool=new b({map:this.map,updateSelection:!0,fullyWithin:!1},this.selectToolDiv);var E=C(".btn-clear",this.selectTool.domNode)[0];m.add(E,"esriCTHidden");l.set(E,"tab-index","-1");this._selectToolFocusElement=this.selectTool.domNode.children[0];l.set(this._selectToolFocusElement,"role","button");l.set(this._selectToolFocusElement,"aria-label",this.nls.drawToolWidget.selectToolLabel);
var R=C(".btn-select",this.selectTool.domNode)[0];this.own(n(R,"click",c.hitch(this,function(aa){G.stop(aa);this._activateOrDeactivateSelectTool()})));this.own(n(this.selectToolParent,"keydown",c.hitch(this,function(aa){aa.keyCode!==g.ESCAPE||this.isSingleTabSelected||(G.stop(aa),this.emit("focusLastSelectedTab"));if(aa.keyCode===g.ENTER||aa.keyCode===g.SPACE)G.stop(aa),R.click()})));this.own(n(this.selectTool,"unloading",c.hitch(this,function(){this.currentSelectedDrawTool="selectTool";this._deactivateSelectTool();
var aa=this._getSelectedFeature();this.emit("onSelectionComplete",aa);this._activateLastSelectedTool()})));B.place(this.selectToolParent,C(".draw-items",this.domNode)[0],"last")},deactivateTools:function(){this._drawTool&&this._drawTool.isActive()&&this._drawTool.deactivate();this.selectTool&&this.selectTool.isActive()&&this._deactivateSelectTool();this.map.enablePan()},_setFeatureLayersForSelectTool:function(){this.selectTool.setFeatureLayers(this._filteredLayerArray)},_getSelectedFeature:function(){var E=
[];y.forEach(this._filteredLayerArray,c.hitch(this,function(R){E=E.concat(R.getSelectedFeatures())}));return E},clearAllSelections:function(E){var R=q.getInstance();y.forEach(this._filteredLayerArray,c.hitch(this,function(aa){E&&R.clearSelection(aa)}))},_showMessage:function(E){(new Q({message:E})).message=E},_displayLayerChooserListOfSelectTool:function(){m.remove(this.seperatorAfterSelect,"esriCTHidden");m.remove(this.parentDivOfChooseSymbol,"esriCTHidden")},_hideLayerChooserListOfSelectTool:function(){m.add(this.seperatorAfterSelect,
"esriCTHidden");m.add(this.parentDivOfChooseSymbol,"esriCTHidden")},_deactivateSelectTool:function(){this.selectTool&&this.selectTool.deactivate();this._hideLayerChooserListOfSelectTool()},focusFirstNodeOfSelectedTab:function(){S.focus(this.drawToolHeader)},setFirstFocusNode:function(E){F.initFirstFocusNode(E,this.drawToolHeader)},_attachKeydownEventToTheNodes:function(){z.forEach(this._drawTool.domNode.children[0].children,c.hitch(this,function(E){"block"===U.get(E,"display")&&this.own(n(E,"keydown",
c.hitch(this,function(R){R.keyCode!==g.ESCAPE||this.isSingleTabSelected||(G.stop(R),this.emit("focusLastSelectedTab"))})))}))},_addAriaLabelToDrawTools:function(){z.forEach(this._drawTool.domNode.children[0].children,c.hitch(this,function(E){if("block"===U.get(E,"display")){var R=l.get(E,"title");l.set(E,"aria-label",R);m.add(E,"esriCTDrawItem")}}))},_focusOutCurrentNode:function(){S.curNode&&S.curNode.blur()},_activateOrDeactivateSelectTool:function(){this._drawTool.isActive()&&this._drawTool.deactivate();
this.selectTool&&this.selectTool.isActive()?(this._displayLayerChooserListOfSelectTool(),this.map.disablePan()):this._deactivateSelectTool()},setFocusOnSelectTool:function(){""!==this.selectTool&&null!==this.selectTool&&void 0!==this.selectTool&&(this._focusOutCurrentNode(),S.focus(this._selectToolFocusElement),this.currentSelectedDrawTool=null)},_activateLastSelectedTool:function(){switch(this.currentSelectedDrawTool){case "point":this._focusOutCurrentNode();S.focus(this._drawTool.pointIcon);this.currentSelectedDrawTool=
null;break;case "polyline":this._focusOutCurrentNode();S.focus(this._drawTool.polylineIcon);this.currentSelectedDrawTool=null;break;case "extent":this._focusOutCurrentNode();S.focus(this._drawTool.extentIcon);this.currentSelectedDrawTool=null;break;case "circle":this._focusOutCurrentNode();S.focus(this._drawTool.circleIcon);this.currentSelectedDrawTool=null;break;case "polygon":this._focusOutCurrentNode();S.focus(this._drawTool.polygonIcon);this.currentSelectedDrawTool=null;break;case "selectTool":this._focusOutCurrentNode(),
S.focus(this._selectToolFocusElement)}}})})},"jimu/dijit/FeatureSetChooserForMultipleLayers":function(){define("dojo/on dojo/sniff dojo/mouse dojo/query dojo/Evented dojo/_base/html dojo/_base/lang dojo/_base/array dojo/promise/all dojo/_base/declare dijit/_WidgetBase dijit/_TemplatedMixin dijit/_WidgetsInTemplateMixin dojo/text!./templates/FeatureSetChooserForMultipleLayers.html dijit/popup dijit/TooltipDialog jimu/utils jimu/dijit/DrawBox jimu/dijit/_FeatureSetChooserCore jimu/SelectionManager jimu/dijit/FeatureActionPopupMenu".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U){return y([I,e,b,w],{baseClass:"jimu-multiple-layers-featureset-chooser",declaredClass:"jimu.dijit.FeatureSetChooserForMultipleLayers",templateString:q,drawBox:null,_instances:null,_tooltipDialogTimeoutId1:-1,_tooltipDialogClientX1:-1,_tooltipDialogTimeoutId2:-1,_tooltipDialogClientX2:-1,_tooltipTimeout:1E3,_currentGeoTypeInfo:null,_geoTypeInfos:null,map:null,updateSelection:!1,fullyWithin:!1,geoTypes:null,actions:null,postMixInProperties:function(){this.inherited(arguments);
this.nls=window.jimuNls.featureSetChooser;var g="POINT EXTENT POLYGON CIRCLE POLYLINE FREEHAND_POLYGON".split(" ");this.geoTypes&&0<this.geoTypes.length&&(this.geoTypes=C.filter(this.geoTypes,B.hitch(this,function(G){return 0<=g.indexOf(G)})));this.geoTypes&&0!==this.geoTypes.length||(this.geoTypes=["EXTENT"])},postCreate:function(){this.inherited(arguments);this._instances=[];this.popupMenu=U.getInstance();c(".select-text",this.domNode)[0].innerHTML=this.nls.select;c(".clear-text",this.domNode)[0].innerHTML=
window.jimuNls.common.clear;this._initTooltipDialogs();this._initDrawBox();this._geoTypeInfos=[];this.actions=[];0===this.geoTypes.length&&this.geoTypes.push("EXTENT");1===this.geoTypes.length?n.addClass(this.domNode,"single-geotype"):n.addClass(this.domNode,"multiple-geotypes");var g={POINT:["icon-select-by-point",this.nls.selectByPoint,this.drawBox.pointIcon],EXTENT:["icon-select-by-rect",this.nls.selectByRectangle,this.drawBox.extentIcon],POLYGON:["icon-select-by-polygon",this.nls.selectByPolygon,
this.drawBox.polygonIcon],CIRCLE:["icon-select-by-circle",this.nls.selectByCircle,this.drawBox.circleIcon],POLYLINE:["icon-select-by-line",this.nls.selectByLine,this.drawBox.polylineIcon],FREEHAND_POLYGON:["icon-select-by-freehand-polygon",this.nls.selectByFreehandPolygon,this.drawBox.freehandPolygonIcon]},G=-1;C.forEach("POINT EXTENT POLYGON CIRCLE POLYLINE FREEHAND_POLYGON".split(" "),B.hitch(this,function(F){var l=g[F];if(0<=this.geoTypes.indexOf(F)){var E={geoType:F,action:{iconClass:l[0],label:l[1],
data:{}},dom:l[2]};l={iconClass:l[0],label:l[1],data:{},onExecute:B.hitch(this,this._onDrawItemClicked,E)};this._geoTypeInfos.push(E);this.actions.push(l);"EXTENT"===F&&(G=this._geoTypeInfos.length-1)}}));this.own(D(this.btnSelect,"click",B.hitch(this,function(){z.simulateClickEvent(this._currentGeoTypeInfo.dom);this._hideDrawItems()})));0<=G?(this._setCurrentGeoInfo(this._geoTypeInfos[G]),n.addClass(this.geoTypeIcon,"icon-select-by-rect")):(this._setCurrentGeoInfo(this._geoTypeInfos[0]),n.addClass(this.geoTypeIcon,
this._geoTypeInfos[0].action.iconClass));this.deactivate()},_initTooltipDialogs:function(){var g=a("mac")?"\u2318":"Ctrl",G="- "+this.nls.newSelectionTip+" ("+this.nls.dragMouse+")",F="- "+this.nls.addSelectionTip+" (Shift+"+this.nls.dragBox+")",l="- "+this.nls.removeSelectionTip+" ("+g+"+"+this.nls.dragBox+")",E="- "+this.nls.newSelectionTip+" ("+this.nls.drawShap+")",R="- "+this.nls.addSelectionTip+" (Shift+"+this.nls.darw+")",aa="- "+this.nls.removeSelectionTip+" ("+g+"+"+this.nls.darw+")";g=n.create("div",
{innerHTML:'\x3cdiv class\x3d"title"\x3e\x3c/div\x3e\x3cdiv class\x3d"item new-selection-item"\x3e\x3c/div\x3e\x3cdiv class\x3d"item add-selection-item"\x3e\x3c/div\x3e\x3cdiv class\x3d"item remove-selection-item"\x3e\x3c/div\x3e',"class":"dialog-content"});var W=c(".title",g)[0],da=c(".new-selection-item",g)[0],h=c(".add-selection-item",g)[0],V=c(".remove-selection-item",g)[0];this.tooltipDialog1=new M({content:g});n.addClass(this.tooltipDialog1.domNode,"jimu-multiple-layers-featureset-chooser-tooltipdialog");
this.own(D(this.btnSelect,"mousemove",B.hitch(this,function(T){this._tooltipDialogClientX1=T.clientX})));this.own(D(this.btnSelect,d.enter,B.hitch(this,function(){clearTimeout(this._tooltipDialogTimeoutId1);this._tooltipDialogTimeoutId1=-1;this._tooltipDialogTimeoutId1=setTimeout(B.hitch(this,function(){if(this.tooltipDialog1){var T=this._currentGeoTypeInfo.geoType;"EXTENT"===T?(da.innerHTML=G,h.innerHTML=F,V.innerHTML=l,W.innerHTML=this.nls.selectByRectangle):(da.innerHTML=E,h.innerHTML=R,V.innerHTML=
aa,"POLYGON"===T?W.innerHTML=this.nls.selectByPolygon:"CIRCLE"===T?W.innerHTML=this.nls.selectByCircle:"POLYLINE"===T?W.innerHTML=this.nls.selectByLine:"FREEHAND_POLYGON"===T?W.innerHTML=this.nls.selectByFreehandPolygon:"POINT"===T&&(W.innerHTML=this.nls.selectByPoint));K.open({parent:this.getParent(),popup:this.tooltipDialog1,around:this.btnSelect,position:["below"]});0<=this._tooltipDialogClientX1&&(this.tooltipDialog1.domNode.parentNode.style.left=this._tooltipDialogClientX1+"px")}}),this._tooltipTimeout)})));
this.own(D(this.btnSelect,d.leave,B.hitch(this,function(){clearTimeout(this._tooltipDialogTimeoutId1);this._tooltipDialogTimeoutId1=-1;this._hideTooltipDialog(this.tooltipDialog1)})));g=n.create("div",{innerHTML:this.nls.unselectAllSelectionTip,"class":"dialog-content"});this.tooltipDialog2=new M({content:g});n.addClass(this.tooltipDialog2.domNode,"jimu-multiple-layers-featureset-chooser-tooltipdialog");this.own(D(this.btnClear,"mousemove",B.hitch(this,function(T){this._tooltipDialogClientX2=T.clientX})));
this.own(D(this.btnClear,d.enter,B.hitch(this,function(){clearTimeout(this._tooltipDialogTimeoutId2);this._tooltipDialogTimeoutId2=-1;this._tooltipDialogTimeoutId2=setTimeout(B.hitch(this,function(){this.tooltipDialog2&&(K.open({parent:this.getParent(),popup:this.tooltipDialog2,around:this.btnClear,position:["below"]}),0<=this._tooltipDialogClientX2&&(this.tooltipDialog2.domNode.parentNode.style.left=this._tooltipDialogClientX2+"px"))}),this._tooltipTimeout)})));this.own(D(this.btnClear,d.leave,B.hitch(this,
function(){clearTimeout(this._tooltipDialogTimeoutId2);this._tooltipDialogTimeoutId2=-1;this._hideTooltipDialog(this.tooltipDialog2)})))},_onArrowClicked:function(g){g.stopPropagation();g=n.position(g.target);this._showDrawItems(g)},_setCurrentGeoInfo:function(g){var G=this._currentGeoTypeInfo&&this._currentGeoTypeInfo.geoType;this._currentGeoTypeInfo&&n.removeClass(this.currentDrawItem,this._currentGeoTypeInfo.geoType);this._currentGeoTypeInfo=g;n.addClass(this.currentDrawItem,this._currentGeoTypeInfo.geoType);
this.isActive()?G!==this._currentGeoTypeInfo.geoType&&z.simulateClickEvent(this._currentGeoTypeInfo.dom):z.simulateClickEvent(this._currentGeoTypeInfo.dom)},_showDrawItems:function(g){this.popupMenu.setActions(this.actions);this.popupMenu.markAsSelected(this._currentGeoTypeInfo.action);this.popupMenu.show(g)},_hideDrawItems:function(){this.popupMenu.hide()},_onDrawItemClicked:function(g){this._hideDrawItems();this._setCurrentGeoInfo(g);n.removeClass(this.geoTypeIcon,"icon-select-by-point icon-select-by-circle icon-select-by-rect icon-select-by-polygon icon-select-by-line icon-select-by-freehand-polygon".split(" "));
switch(g.geoType){case "POLYGON":n.addClass(this.geoTypeIcon,"icon-select-by-polygon");break;case "CIRCLE":n.addClass(this.geoTypeIcon,"icon-select-by-circle");break;case "POLYLINE":n.addClass(this.geoTypeIcon,"icon-select-by-line");break;case "FREEHAND_POLYGON":n.addClass(this.geoTypeIcon,"icon-select-by-freehand-polygon");break;case "POINT":n.addClass(this.geoTypeIcon,"icon-select-by-point");break;default:n.addClass(this.geoTypeIcon,"icon-select-by-rect")}},_initDrawBox:function(){this.drawBox=
new v({map:this.map,showClear:!0,keepOneGraphic:!0,deactivateAfterDrawing:!1,geoTypes:this.geoTypes});this.own(D(this.drawBox,"user-clear",B.hitch(this,this._onDrawBoxUserClear)));this.own(D(this.drawBox,"draw-end",B.hitch(this,this._onDrawEnd)));this.own(D(this.drawBox,"draw-activate",B.hitch(this,function(){this.map.infoWindow.hide();n.addClass(this.currentDrawItem,"pressed");n.addClass(this.btnSelect,"selected")})));this.own(D(this.drawBox,"draw-deactivate",B.hitch(this,function(){n.removeClass(this.currentDrawItem,
"pressed");n.removeClass(this.btnSelect,"selected")})));this.own(D(this.btnClear,"click",B.hitch(this,function(){z.simulateClickEvent(this.drawBox.btnClear)})))},disable:function(){this.drawBox.disable();n.addClass(this.domNode,"disabled")},enable:function(){this.drawBox.enable();n.removeClass(this.domNode,"disabled")},isActive:function(){return this.drawBox.isActive()},activate:function(){if(!this.isActive()){var g=this._currentGeoTypeInfo;g||(g=this._geoTypeInfos[0]);this._setCurrentGeoInfo(g)}},
deactivate:function(){this.drawBox.deactivate()},setFeatureLayers:function(g){var G=C.filter(this._instances,B.hitch(this,function(l){return 0>g.indexOf(l.featureLayer)}));C.forEach(G,B.hitch(this,function(l){this._removeInstance(l)}));var F=C.map(this._instances,B.hitch(this,function(l){return l.featureLayer}));C.forEach(g,B.hitch(this,function(l){0>F.indexOf(l)&&this.addFeatureLayer(l)}))},addFeatureLayer:function(g){"esri.layers.FeatureLayer"!==g.declaredClass||this._findInstanceByLayer(g)||(g=
new Q({map:this.map,featureLayer:g,drawBox:this.drawBox,updateSelection:this.updateSelection,fullyWithin:this.fullyWithin}),this._instances.push(g))},removeFeatureLayer:function(g){"esri.layers.FeatureLayer"===g.declaredClass&&(g=this._findInstanceByLayer(g))&&this._removeInstance(g)},setDisplayLayerVisibility:function(g,G){(g=S.getInstance().getDisplayLayer(g.id))&&(G?g.show():g.hide())},_removeInstance:function(g){if(g){var G=this._instances.indexOf(g);0<=G&&(g.destroy(),this._instances.splice(G,
1))}},_findInstanceByLayer:function(g){var G=null;C.some(this._instances,B.hitch(this,function(F){return F.featureLayer===g?(G=F,!0):!1}));return G},clear:function(g){C.forEach(this._instances,B.hitch(this,function(G){G.clear(g)}))},destroy:function(){this._hideTooltipDialog(this.tooltipDialog1);this._hideTooltipDialog(this.tooltipDialog2);C.forEach(this._instances,B.hitch(this,function(g){g.destroy()}));this._instances=[];this.drawBox&&this.drawBox.destroy();this.drawBox=null;this.inherited(arguments)},
_hideTooltipDialog:function(g){g&&K.close(g)},_onDrawBoxUserClear:function(){this.clear(!0);this.emit("user-clear")},_onDrawEnd:function(g,G,F,l,E,R){this.drawBox.clear();0<this._instances.length&&setTimeout(B.hitch(this,function(){if(0<this._instances.length){this.emit("loading");this.disable();var aa=C.map(this._instances,B.hitch(this,function(W){return W.getFeatures()}));m(aa).always(B.hitch(this,function(){this.enable();this._currentGeoTypeInfo&&z.simulateClickEvent(this._currentGeoTypeInfo.dom);
this.emit("unloading",g,G,F,l,E,R)}))}}),50)}})})},"jimu/dijit/_FeatureSetChooserCore":function(){define("dojo/on dojo/sniff dojo/Evented dojo/Deferred dojo/_base/lang dojo/_base/array dojo/_base/declare jimu/utils jimu/symbolUtils jimu/SelectionManager jimu/LayerInfos/LayerInfos esri/graphic esri/tasks/query esri/tasks/QueryTask esri/layers/FeatureLayer esri/symbols/jsonUtils esri/geometry/geometryEngine".split(" "),function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z){return B([d],{baseClass:"jimu-featureset-chooser-core",
_middleFeatureLayer:null,_isLoading:!1,_def:null,_isDestroyed:!1,_handles:null,selectionManager:null,layerInfosObj:null,layerInfo:null,map:null,featureLayer:null,drawBox:null,updateSelection:!1,fullyWithin:!1,constructor:function(v){w.mixin(this,v);this.layerInfosObj=I.getInstanceSync();this.selectionManager=y.getInstance();this.featureLayer.getSelectionSymbol()||this.selectionManager.setSelectionSymbol(this.featureLayer);v=C.getFeatureLayerDefinition(this.featureLayer);delete v.id;this._middleFeatureLayer=
new K({layerDefinition:v,featureSet:null},{id:"featureLayer_"+C.getRandomString()});v=null;var Q=this._middleFeatureLayer.geometryType;"esriGeometryPoint"===Q?v=m.getDefaultMarkerSymbol():"esriGeometryPolyline"===Q?v=m.getDefaultLineSymbol():"esriGeometryPolygon"===Q&&(v=M.fromJson({style:"esriSFSSolid",color:[79,129,189,77],type:"esriSFS",outline:{style:"esriSLSSolid",color:[54,93,141,255],width:1.5,type:"esriSLS"}}));this._middleFeatureLayer.setSelectionSymbol(v);v=D(this.drawBox,"user-clear",w.hitch(this,
this._onDrawBoxUserClear));Q=D(this.drawBox,"draw-end",w.hitch(this,this._onDrawEnd));this._handles=[v,Q];if(this.layerInfo=this.layerInfosObj.getLayerInfoById(this.featureLayer.id))v=D(this.layerInfo,"filterChanged",w.hitch(this,this._handleFilterChange)),this._handles.push(v)},hideMiddleFeatureLayer:function(){if(this._middleFeatureLayer){this._middleFeatureLayer.hide();var v=this.selectionManager.getDisplayLayer(this._middleFeatureLayer.id);v&&v.hide()}},showMiddleFeatureLayer:function(){if(this._middleFeatureLayer){this._middleFeatureLayer.show();
var v=this.selectionManager.getDisplayLayer(this._middleFeatureLayer.id);v&&v.show()}},clear:function(v){this.drawBox.clear();this._clearMiddleFeatureLayer();v&&this.selectionManager.clearSelection(this.featureLayer)},getFeatures:function(){var v=new c,Q=w.hitch(this,function(){var U=this.syncGetFeatures();v.resolve(U)}),S=w.hitch(this,function(U){v.reject(U)});1===this._getDeferredStatus(this._def)?this._def.then(Q,S):Q();return v},syncGetFeatures:function(){return(this.updateSelection?this.featureLayer:
this._middleFeatureLayer).getSelectedFeatures()},isLoading:function(){return 1===this._getDeferredStatus(this._def)},_onLoading:function(){this.drawBox.deactivate();this.emit("loading")},_onUnloading:function(){this.emit("unloading")},_getDeferredStatus:function(v){var Q=0;return Q=v?v.isResolved()?2:v.isRejected()?-1:1:0},_onDrawEnd:function(v,Q,S,U,g,G){if(this.isLoading())throw"should not draw when loading";if(this.featureLayer.visible){var F=new c;this._def=F;var l=K.SELECTION_NEW;U&&(l=K.SELECTION_ADD);
a("mac")?G&&(l=K.SELECTION_SUBTRACT):g&&(l=K.SELECTION_SUBTRACT);this.emit("loading");this._getFeaturesByGeometry(v.geometry).then(w.hitch(this,function(E){this.selectionManager.updateSelectionByFeatures(this.updateSelection?this.featureLayer:this._middleFeatureLayer,E,l);this._onUnloading();F.resolve(E)}),w.hitch(this,function(E){console.error(E);this._onUnloading();F.reject(E)}))}},_addTolerance:function(v){var Q=2.54*this.map.getScale()/9600;return z.buffer(v,10*Q,"meters")},_getFeaturesByGeometry:function(v){"point"!==
v.type&&"polyline"!==v.type||"esriGeometryPoint"!==this.featureLayer.geometryType||(v=this._addTolerance(v));var Q=new c,S=[];if(this.featureLayer.getMap()&&this.featureLayer.mode!==K.MODE_SELECTION)v=this.selectionManager.getClientFeaturesByGeometry(this.featureLayer,v,this.fullyWithin),0<v.length&&(S=n.map(v,w.hitch(this,function(g){return new e(g.toJson())}))),Q.resolve(S);else{S=new b;S.geometry=v;S.outSpatialReference=this.map.spatialReference;S.returnGeometry=!0;S.spatialRelationship=this.fullyWithin?
b.SPATIAL_REL_CONTAINS:b.SPATIAL_REL_INTERSECTS;(v=this.featureLayer.getDefinitionExpression())||(v="1\x3d1");if(this.layerInfo){var U=this.layerInfo.getFilter();U&&(v="("+v+") AND ("+U+")")}v&&(S.where=v);S.outFields=["*"];(new q(this.featureLayer.url)).execute(S).then(w.hitch(this,function(g){Q.resolve(g.features)}),w.hitch(this,function(g){Q.reject(g)}))}return Q},_onDrawBoxUserClear:function(){this.clear()},_clearMiddleFeatureLayer:function(){this._middleFeatureLayer&&(this._middleFeatureLayer.clear(),
this.selectionManager.clearSelection(this._middleFeatureLayer))},_handleFilterChange:function(){var v=this.layerInfo.getFilter()||"1\x3d1",Q=this.featureLayer.getSelectedFeatures(),S=this.featureLayer.objectIdField;if(Q&&0<Q.length){var U=n.map(Q,function(G){return G.attributes[S]}),g=new b;g.where=S+" in ("+U.join(",")+") AND "+v;(new q(this.featureLayer.url)).executeForIds(g).then(w.hitch(this,function(G){n.forEach(Q,function(F){0<=G.indexOf(F.attributes[S])?F.show():F.hide()});this.selectionManager._isLayerNeedDisplayLayer(this.featureLayer)&&
this.selectionManager._updateDisplayLayer(this.featureLayer,Q,K.SELECTION_NEW);this.featureLayer.emit("selection-complete",{features:this.featureLayer.getSelectedFeatures()})}),w.hitch(this,function(G){console.error(G)}))}},destroy:function(){this._isDestroyed||(n.forEach(this._handles,w.hitch(this,function(v){v.remove()})),this._handles=null,this.clear());this._isDestroyed=!0}})})},"widgets/Screening/drawTool/SelectableLayerItem":function(){define("dojo/_base/declare dojo/_base/html dojo/_base/lang dojo/_base/event dojo/on dojo/Evented dijit/_WidgetBase dijit/_TemplatedMixin dijit/_WidgetsInTemplateMixin dojo/text!./SelectableLayerItem.html dojo/dom-attr dojo/keys".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e){return D([B,C,m,n],{baseClass:"jimu-widget-screening-selectable-layer-item",templateString:y,layerName:"layer",layerVisible:!0,checked:!1,constructor:function(b){this.layerName="layer";this.layerVisible=!0;this.checked=!1;d.mixin(this,b)},postCreate:function(){this.inherited(arguments)},init:function(b){this.featureLayer=b;this.layerName=this.layerInfo.title||"layer";this.own(w(this.featureLayer,"selection-clear",d.hitch(this,function(){a.addClass(this.domNode,"no-action")})));
this.layerNameNode.innerHTML=this.layerName;this.layerNameNode.title=this.layerName;a.addClass(this.selectableCheckBox,"checked");I.set(this.selectableCheckBox,"aria-label",this.layerName);I.set(this.selectableCheckBox,"aria-checked","true");this.own(w(this.selectableCheckBox,"click",d.hitch(this,function(q){c.stop(q);this._toggleChecked(q)})));this.own(w(this.selectableCheckBox,"keydown",d.hitch(this,function(q){if(q.keyCode===e.ENTER||q.keyCode===e.SPACE)c.stop(q),this._toggleChecked(q);q.keyCode!==
e.ESCAPE||this.isSingleTabSelected||(c.stop(q),this.emit("focusLastSelectedTab"))})));this.own(w(this.layerContent,"click",d.hitch(this,this._toggleContent)))},isLayerVisible:function(){return this.layerVisible},isChecked:function(){return this.checked},_toggleChecked:function(b){c.stop(b);a.toggleClass(this.selectableCheckBox,"checked");(this.checked=a.hasClass(this.selectableCheckBox,"checked"))?I.set(this.selectableCheckBox,"aria-checked","true"):I.set(this.selectableCheckBox,"aria-checked","false");
this.emit("stateChange",{checked:this.checked,layerInfo:this.layerInfo})}})})},"widgets/Screening/shapefile/shapefile":function(){define("dojo/_base/declare dojo/text!./shapefile.html dijit/_WidgetsInTemplateMixin dojo/_base/lang dojo/on dojo/json dojo/Evented esri/layers/FeatureLayer esri/request jimu/BaseWidget jimu/dijit/Message dijit/focus dojo/keys dojo/_base/event jimu/utils".split(" "),function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K){return D([y,d,B],{baseClass:"jimu-widget-screening-shapefile",templateString:a,
_uploadFormChange:null,nls:null,config:null,map:null,constructor:function(M){this.map=this.config=this.nls=this._uploadFormChange=null;c.mixin(this,M)},postCreate:function(){this._attachEventsToUploadShapefileButton();this._attachFileInputOnChangeEvent()},_attachEventsToUploadShapefileButton:function(){this.own(w(this.uploadShapefileButton,"click",c.hitch(this,function(M){q.stop(M);this.shapefileInput.click()})));this.own(w(this.uploadShapefileButton,"keydown",c.hitch(this,function(M){if(M.keyCode===
b.ENTER||M.keyCode===b.SPACE)q.stop(M),this.shapefileInput.click();M.keyCode!==b.ESCAPE||this.isSingleTabSelected||(q.stop(M),this.emit("focusLastSelectedTab"))})))},_attachFileInputOnChangeEvent:function(){var M;this._uploadFormChange&&this._uploadFormChange.remove();this._uploadFormChange=this.own(w.pausable(this.uploadForm,"change",c.hitch(this,function(z){this.loadingIndicator.show();M={filename:z.target.value.toLowerCase()};this._generateFeatureCollection(M)})))},_generateFeatureCollection:function(M){M=
M.filename.split(".");M=M[0].replace("c:\\fakepath\\","");this._requestFeatureCollection({params:{name:M,targetSR:this.map.spatialReference,maxRecordCount:this.config.maxFeaturesForAnalysis}})},_requestFeatureCollection:function(M){var z,v;M={filetype:"shapefile",publishParameters:n.stringify(M.params),f:"json"};m({url:this.config.generateFeatureCollectionURL,content:M,form:this.uploadForm,handleAs:"json",load:c.hitch(this,function(Q){Q.error?(this.loadingIndicator.hide(),this._showMessage(this.nls.shapefileWidget.unableToUploadShapefileMessage)):
(z=Q.featureCollection.layers[0],this._uploadFormChange[0].pause(),v=new C(z),this.shapefileInput.value="",this._uploadFormChange[0].resume(),this.emit("onShapefileUpload",v),this.loadingIndicator.hide())}),error:c.hitch(this,function(Q){this._uploadFormChange[0].pause();this.shapefileInput.value="";this._uploadFormChange[0].resume();this.loadingIndicator.hide();400===Q.code?Q.details&&0<Q.details.length?this._showMessage(this.nls.shapefileWidget.unableToUploadShapefileMessage+" "+Q.details[0]):this._showMessage(this.nls.shapefileWidget.unableToUploadShapefileMessage+
" "+Q.message):this._showMessage(this.nls.shapefileWidget.unableToUploadShapefileMessage+" "+Q.message)})})},_showMessage:function(M){(new I({message:M})).message=M},focusFirstNodeOfSelectedTab:function(){this._focusOutCurrentNode();e.focus(this.uploadShapefileButton)},setFirstFocusNode:function(M){K.initFirstFocusNode(M,this.uploadShapefileButton)},_focusOutCurrentNode:function(){e.curNode&&e.curNode.blur()},setLastFocusNode:function(M){K.initLastFocusNode(M,this.uploadShapefileButton)}})})},"widgets/Screening/coordinates/coordinates":function(){define("dojo/_base/declare dojo/text!./coordinates.html dijit/_WidgetsInTemplateMixin dojo/_base/lang dojo/on dojo/dom-class dojo/Evented jimu/BaseWidget esri/graphic esri/symbols/jsonUtils esri/SpatialReference esri/geometry/Point esri/graphicsUtils ../search ../geometryUtils ../MapTooltipHandler dijit/focus ../conversionUtils dojo/dom-construct dijit/form/ValidationTextBox dojo/dom-attr dojo/keys dojo/dnd/Source dojo/_base/array dojo/query jimu/dijit/Message ../planSettings/planSettings dojo/dom-geometry dojo/_base/event jimu/utils dijit/form/NumberTextBox".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U,g,G,F,l,E,R,aa,W,da){return D([C,d,B],{baseClass:"jimu-widget-screening-coordinates",templateString:a,_itemList:[],_nodes:[],_mapTooltipHandler:null,_dndContainer:null,_latLongValue:{latitude:"",longitude:""},_windowResizeTimer:null,startPoint:null,startPointForNextLine:null,planSettingsWidget:null,_configuredDirectionUnit:null,_configuredDistanceUnit:null,_hasMultipleSourcesInSearch:!0,_buttonNodeEventHandler:null,_inputNodeEventHandler:null,_submitNodeEventHandler:null,
_clearNodeEventHandler:null,constructor:function(h){this._itemList=[];this._nodes=[];this._dndContainer=this._mapTooltipHandler=null;this._latLongValue={latitude:"",longitude:""};this._configuredDistanceUnit=this._configuredDirectionUnit=this.planSettingsWidget=this.startPointForNextLine=this.startPoint=this._windowResizeTimer=null;this._hasMultipleSourcesInSearch=!0;this._clearNodeEventHandler=this._submitNodeEventHandler=this._inputNodeEventHandler=this._buttonNodeEventHandler=null;c.mixin(this,
h)},postMixInProperties:function(){this.inherited(arguments);this.isRenderIdForAttrs=!0},postCreate:function(){this._initializeCoordinatesWidget();this._createSearchInstance();this._attachKeydownEventToTheNodes()},_createSearchInstance:function(){this._searchInstance=new q({searchOptions:{addLayersFromMap:!1,autoNavigate:!1,autoComplete:!0,minCharacters:0,maxLocations:5,searchDelay:100,enableHighlight:!1},config:this.config,appConfig:this.appConfig,nls:this.nls,map:this.map},Q.create("div",{},this.searchWidgetContainerCoordinatesTab));
this.own(this._searchInstance.on("select-result",c.hitch(this,function(h){this.emit("onSearchComplete",h)})));this.own(this._searchInstance.on("clear-search",c.hitch(this,this._clearResults)));this.own(this._searchInstance.on("search-loaded",c.hitch(this,function(){setTimeout(c.hitch(this,function(){this._searchContainerNodeElement=l(".arcgisSearch .searchGroup .searchInput",this.domNode)[0];2>this._searchInstance.search.sources.length&&(this._hasMultipleSourcesInSearch=!1);this.onWindowResize()}),
1E3)})));this._searchInstance.startup()},_clearResults:function(h){h||this.map.infoWindow.hide()},clearSearchText:function(){this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.clear()},onWindowResize:function(){this._windowResizeTimer&&clearTimeout(this._windowResizeTimer);this._windowResizeTimer=setTimeout(c.hitch(this,this._resetComponents),500)},_resetComponents:function(){var h;var V=l(".arcgisSearch .searchGroup",this.domNode)[0];this._searchContainerNodeElement||
(this._searchContainerNodeElement=l(".arcgisSearch .searchGroup .searchInput",this.domNode)[0]);this.widgetMainContainer&&this._searchContainerNodeElement&&(h=aa.position(this.widgetMainContainer))&&h.w&&(h=h.w-175,this._hasMultipleSourcesInSearch||(h+=32),0<h&&(this._searchContainerNodeElement.style.setProperty("width",h-45+"px","important"),V&&V.style.setProperty("max-width","100%","important")));this._attachSearchNodeEvents()},_initializeCoordinatesWidget:function(){this._configuredDirectionUnit=
c.clone(this.config.traverseDirectionUnit);this._configuredDistanceUnit=c.clone(this.config.traverseUnit);this._nodes=[];this._itemList=[];this._initializeMapTooltipHandler();this._setLatLongInputTextBoxesConstraints();this._createPlanSettings();this.updateAccordingToPlanSettings(this._planSettings);this._attachLatLongTextBoxEvents();this._attachLocateStartPointEvents();this._attachPlanSettingsIconClickEvent();this._setValidatorForInitialRow();this._handleEventsOnInitialRow();this._attachTraverseGridEvents();
this._createTraverseGrid();this._enableOrDisableTraverseGrid(!1)},_createPlanSettings:function(){this._planSettings={};this._planSettings.directionOrAngleType="northAzimuth";this._planSettings.directionOrAngleUnits=this.config.traverseDirectionUnit;this._planSettings.distanceAndLengthUnits=this.config.traverseUnit},updateAccordingToPlanSettings:function(h){this.bearingNode.set("placeHolder",this.nls.units[h.directionOrAngleUnits+"Abbr"]);this.lengthNode.set("placeHolder",this.nls.units[h.distanceAndLengthUnits+
"Abbr"])},_initializeMapTooltipHandler:function(){this._mapTooltipHandler=new M({map:this.map});this._mapTooltipHandler.startup();this.own(w(this._mapTooltipHandler,"clicked",c.hitch(this,function(h){n.contains(this.locateStartPointIcon,"esriCTLocateIconSelected")&&(this.onStartPointSelected(h.mapPoint),this.deactivateLocateIcon())})))},_setLatLongInputTextBoxesConstraints:function(){this.latitudeTextBox.set("constraints",{min:-90,max:90,places:8});this.latitudeTextBox.set("trim",!0);this.longitudeTextBox.set("constraints",
{min:-180,max:180,places:8});this.longitudeTextBox.set("trim",!0)},onStartPointSelected:function(h){this.drawnOrSelectedGraphicsLayer.clear();this.uploadedShapefileGraphicsLayer.clear();var V=new I(4326);K.getProjectedGeometry(h,V,this.geometryService).then(c.hitch(this,function(T){this.setStartPoint(h);this._enableOrDisableTraverseGrid(!0);this.setLatLongTextBoxValue(T.x,T.y)}))},_activateLocateIcon:function(){this.startPointForNextLine?this._mapTooltipHandler.connectEventHandler(this.nls.coordinatesWidget.mapTooltipForUpdateStartPoint):
this._mapTooltipHandler.connectEventHandler(this.nls.coordinatesWidget.mapTooltipForStartPoint);n.add(this.locateStartPointIcon,"esriCTLocateIconSelected")},deactivateLocateIcon:function(){n.contains(this.locateStartPointIcon,"esriCTLocateIconSelected")&&(n.remove(this.locateStartPointIcon,"esriCTLocateIconSelected"),this._mapTooltipHandler.disconnectEventHandler())},setLatLongTextBoxValue:function(h,V){this._latLongValue.latitude=V;this._latLongValue.longitude=h;this.latitudeTextBox.set("value",
V);this.longitudeTextBox.set("value",h)},_attachLocateStartPointEvents:function(){this.own(w(this.locateStartPointIcon,"click",c.hitch(this,function(h){W.stop(h);n.contains(this.locateStartPointIcon,"esriCTLocateIconSelected")?this.deactivateLocateIcon():this._activateLocateIcon()})));this.own(w(this.locateLatAndLong,"click",c.hitch(this,function(h){W.stop(h);this.latitudeTextBox.isValid()&&this.longitudeTextBox.isValid()?this._onLocateLatLongClicked():this._showMessage(this.nls.coordinatesWidget.invalidLatLongMessage)})))},
_onLocateLatLongClicked:function(){if(this.latitudeTextBox.isValid()&&this.longitudeTextBox.isValid()){this._latLongValue.latitude=this.latitudeTextBox.getValue();this._latLongValue.longitude=this.longitudeTextBox.getValue();var h=new I(4326);h=new e(this._latLongValue.longitude,this._latLongValue.latitude,h);K.getProjectedGeometry(h,this.map.spatialReference,this.geometryService).then(c.hitch(this,function(V){this.setStartPoint(V);this._enableOrDisableTraverseGrid(!0);this._locateStartPoint(V)}))}},
_locateStartPoint:function(h){this.map.centerAt(h)},_enableOrDisableTraverseGrid:function(h){h?(this.bearingNode.set("disabled",!1),this.lengthNode.set("disabled",!1),n.replace(this.addButton,"esriCTAddIcon","esriCTAddDisabledIcon"),U.set(this.bearingNode,"tabindex","0"),U.set(this.lengthNode,"tabindex","0"),U.set(this.addButton,"tabindex","0")):(this.bearingNode.set("disabled",!0),this.lengthNode.set("disabled",!0),n.replace(this.addButton,"esriCTAddDisabledIcon","esriCTAddIcon"),U.set(this.bearingNode,
"tabindex","-1"),U.set(this.lengthNode,"tabindex","-1"),U.set(this.addButton,"tabindex","-1"))},_attachTraverseGridEvents:function(){this.own(w(this.addButton,"click",c.hitch(this,function(h){W.stop(h);n.contains(this.addButton,"esriCTAddIcon")&&this._addNewItem()})));this.own(w(this.addButton,"keydown",c.hitch(this,function(h){if(h.keyCode===g.ENTER||h.keyCode===g.SPACE)W.stop(h),n.contains(this.addButton,"esriCTAddIcon")&&this._addNewItem();h.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(h),
this.emit("focusLastSelectedTab"))})));this.own(w(this.expandCollapseNode,"click",c.hitch(this,function(h){W.stop(h);this._onExpandCollapseClicked()})));this.own(w(this.expandCollapseNode,"keydown",c.hitch(this,function(h){if(h.keyCode===g.ENTER||h.keyCode===g.SPACE)W.stop(h),this._onExpandCollapseClicked();h.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(h),this.emit("focusLastSelectedTab"))})))},_addNewItem:function(){var h;(h=this._getValidatedValues())?(this._itemList.push(h),this._createRow(h,
this._itemList.length-1),this._resetEntryRow(),this._drawStraightLine(h,!0),this._showHideTraverseTools()):this.bearingNode.isValid()?""!==this.lengthNode.get("value")&&this.lengthNode.isValid()||(z.focus(this.lengthNode),this.lengthNode.validate(!1)):(z.focus(this.bearingNode),this.bearingNode.validate(!1))},_validateBearing:function(h){return(h=v.categorizeBearingFormat(h,this._planSettings))?h:null},_getValidatedValues:function(h,V){var T={};h?(T=h,V&&("Bearing"!==V&&T.BearingConversions&&(T.Bearing=
this._getBearingAccordingToPlanSettings(T.BearingConversions)),"Length"!==V&&T.LengthConversions&&(T.Length=T.LengthConversions[this._planSettings.distanceAndLengthUnits]))):(T.Bearing=this.bearingNode.get("value"),T.Length=this.lengthNode.get("value"));if(""!==c.trim(T.Bearing.toString())&&""!==c.trim(T.Length.toString())&&(h=this._validateBearing(T.Bearing))){T.BearingConversions=h;if(""===c.trim(T.Length.toString()))return null;if(""!==c.trim(T.Length.toString()))if((h=this._validateLength(T.Length))&&
0!==h.meters){if(0>parseInt(h.meters,10))return null;T.LengthConversions=h}else return null}else return null;return T},_validateLength:function(h,V){switch(V){case "feets":h=v.categorizeLengthFormatForFeet(h);break;case "meters":h=v.categorizeLengthFormat(h,"meters");break;case "uSSurveyFeet":h=v.categorizeLengthFormat(h,"uSSurveyFeet");break;default:h=v.categorizeLengthFormat(h,this._planSettings.distanceAndLengthUnits)}return h?h:null},_createRow:function(h,V){var T=Q.create("div",{"class":"dojoDndItem esriCTRow",
rowIndex:V});Q.create("div",{rowIndex:V},T);var r=this._getBearingAccordingToPlanSettings(h.BearingConversions);this._createFieldInputs(T,r,"esriCTBearingRow");h=this._getRoundedValue(h.LengthConversions,"Length");this._createFieldInputs(T,h,"esriCTLengthRow");this._createDeleteButton(T,V);this._nodes.push(T);this._dndContainer.clearItems();this._dndContainer.insertNodes(!1,this._nodes)},_getBearingAccordingToPlanSettings:function(h,V){if("northAzimuth"===this._planSettings.directionOrAngleType&&
"decimalDegree"===this._planSettings.directionOrAngleUnits)return V?h.naDD:h.naDDRound;if("northAzimuth"===this._planSettings.directionOrAngleType&&"degreeMinuteSeconds"===this._planSettings.directionOrAngleUnits)return h.naDMS;if("southAzimuth"===this._planSettings.directionOrAngleType&&"decimalDegree"===this._planSettings.directionOrAngleUnits)return V?h.saDD:h.saDDRound;if("southAzimuth"===this._planSettings.directionOrAngleType&&"degreeMinuteSeconds"===this._planSettings.directionOrAngleUnits)return h.saDMS;
if("quadrantBearing"===this._planSettings.directionOrAngleType&&"decimalDegree"===this._planSettings.directionOrAngleUnits)return V?h.qb3DD:h.qb3DDRound;if("quadrantBearing"===this._planSettings.directionOrAngleType&&"degreeMinuteSeconds"===this._planSettings.directionOrAngleUnits)return h.qb3DMS},_createFieldInputs:function(h,V,T,r){if("esriCTBearingRow"===T)var u=this.nls.traverseSettings.bearingLabel;else"esriCTLengthRow"===T&&(u=this.nls.traverseSettings.lengthLabel);var A=new S({value:V,"class":T?
T:"",tabindex:0,role:"textbox","aria-label":u});A.placeAt(h);"esriCTBearingRow"===T?(A.validator=c.hitch(this,function(x){return this._bearingValidator(x,[])}),A.invalidMessage=this.nls.newTraverse.invalidBearingMessage):"esriCTLengthRow"===T&&(A.validator=c.hitch(this,this._lengthValidator),A.invalidMessage=this.nls.newTraverse.invalidLengthMessage);this.own(w(A,"blur",c.hitch(this,function(){var x=parseInt(U.get(h,"rowIndex"),10);this._updateParcelValues(A,x,r)})));this.own(w(A,"keypress",c.hitch(this,
function(x){if((x.charCode||x.keyCode)===g.ENTER){var H=parseInt(U.get(h,"rowIndex"),10);this._updateParcelValues(A,H,r)}setTimeout(c.hitch(this,function(){A.validate(!1)}),100);x.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(x),this.emit("focusLastSelectedTab"))})))},_getRoundedValue:function(h,V){h=h[this._planSettings.distanceAndLengthUnits];switch(V){case "Length":var T=this.lengthFieldPlaces}return v.honourPopupRounding(T,h)},_createDeleteButton:function(h,V){var T=Q.create("div",{"class":"esriCTDeleteRow"},
h);V=Q.create("div",{"class":"esriCTDeleteIcon",rowIndex:V,title:this.nls.traverseSettings.deleteButtonTitle,tabindex:0,"aria-label":this.nls.traverseSettings.deleteBearingAndLengthLabel,role:"button"},T);this.own(w(V,"click",c.hitch(this,function(r){W.stop(r);r=parseInt(U.get(r.currentTarget,"rowIndex"),10);this._deleteRow(h,r)})));this.own(w(V,"keydown",c.hitch(this,function(r){if(r.keyCode===g.ENTER||r.keyCode===g.SPACE){W.stop(r);this.emit("restrictFocusOnFirstNode");var u=parseInt(U.get(r.currentTarget,
"rowIndex"),10);this._deleteRow(h,u);this._focusOutCurrentNode();z.focus(this.bearingNode)}r.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(r),this.emit("focusLastSelectedTab"))})))},_createTraverseGrid:function(){var h;this._nodes=[];Q.empty(this.traverseGrid);this._dndContainer=new G(this.traverseGrid,{skipForm:!0,singular:!0});this._dndContainer.copyState=function(){return!1};for(h=0;h<this._itemList.length;h++)this._createRow(this._itemList[h],h);this.own(this._dndContainer.on("DndDrop",
c.hitch(this,this._onDndDrop)));this._dndContainer.insertNodes(!1,this._nodes)},_resetEntryRow:function(h){this.bearingNode.set("value","");this.lengthNode.set("value","");this.bearingNode.reset();this.lengthNode.reset();0<this._itemList.length&&(h=h?this._getBearingAccordingToPlanSettings(this._itemList[this._itemList.length-1].BearingConversions):this._itemList[this._itemList.length-1].Bearing,this.bearingNode.set("value",h),this.bearingNode.textbox.setSelectionRange(0,h.length))},_drawStraightLine:function(h,
V){h=K.getDestinationPoint(this.startPointForNextLine,h.BearingConversions.naDD,h.LengthConversions.meters);this._drawLineAndEndPoint(h,[this.startPointForNextLine,h],V)},_drawLineAndEndPoint:function(h,V,T){h?(V=K.getLineBetweenPoints(V))?(V=new m(V,y.fromJson(this.config.coordinatesSymbology.polyline)),this._addProjectedGraphic(this.drawnOrSelectedGraphicsLayer,V,T),this.startPointForNextLine=c.clone(h),this._drawPoint(h)):this._showMessage(this.nls.newTraverse.unableToDrawLineMessage):this._showMessage(this.nls.newTraverse.invalidEndPointMessage)},
_addProjectedGraphic:function(h,V,T){var r,u={};u.rowIndex=h.graphics.length;V.attributes=u;4326!==this.map.spatialReference.wkid?K.getProjectedGeometry(V.geometry,this.map.spatialReference,this.geometryService).then(c.hitch(this,function(A){A&&(r=new m(A),r.setAttributes(u),r.setSymbol(V.symbol),h.add(r),this.emit("enableClearAOIButton"),this.emit("enableZoomIcon"),T&&(this._setExtentToLayer(h),this.emit("redrawAOI")))})):(h.add(V),T&&this._setExtentToLayer(h))},_drawPoint:function(h){h=new m(h,
y.fromJson(this.config.coordinatesSymbology.point));this._addProjectedGraphic(this.drawnOrSelectedGraphicsLayer,h,!1,!1)},_showHideTraverseTools:function(){this._itemList&&0<this._itemList.length?(n.remove(this.expandCollapseNode,"esriCTHidden"),U.set(this.expandCollapseNode,"tabindex","0")):(n.add(this.expandCollapseNode,"esriCTHidden"),U.set(this.expandCollapseNode,"tabindex","-1"))},_onExpandCollapseClicked:function(){n.toggle(this.traverseGrid,"esriCTHidden");n.contains(this.expandCollapseNode,
"esriCTExpand")?(U.set(this.expandCollapseNode,"title",this.nls.planSettings.collapseGridTooltipText),U.set(this.expandCollapseNode,"aria-label",this.nls.planSettings.collapseGridTooltipText),n.replace(this.expandCollapseNode,"esriCTCollapse","esriCTExpand"),U.set(this.expandCollapseNode,"aria-expanded","true")):(U.set(this.expandCollapseNode,"title",this.nls.planSettings.expandGridTooltipText),U.set(this.expandCollapseNode,"aria-label",this.nls.planSettings.expandGridTooltipText),n.replace(this.expandCollapseNode,
"esriCTExpand","esriCTCollapse"),U.set(this.expandCollapseNode,"aria-expanded","false"));this._setFocusOnExpandCollapseGridButton()},_setExtentToLayer:function(h){0<h.graphics.length&&(h=b.graphicsExtent(h.graphics),this.map.extent.contains(h)||0===this.bufferDistanceTextBox.get("value")&&this.map.setExtent(h.expand(1.5)))},_deleteRow:function(h,V){this._itemList.length&&(this._dndContainer.delItem(h.id),Q.destroy(h),this._nodes.splice(V,1),this._itemList.splice(V,1),this._dndContainer.sync(),this._updateRowIndexes(),
this.setStartPoint(this.startPoint),this._showHideTraverseTools())},_updateRowIndexes:function(){var h=l(".esriCTRow",this.traverseGrid);F.forEach(h,c.hitch(this,function(V,T){var r;U.set(V,"rowIndex",T);(r=l(".esriCTDeleteIcon",V)[0])&&U.set(r,"rowIndex",T);(V=l(".esriCTSymbolContainer",V)[0])&&U.set(V,"rowIndex",T)}))},setStartPoint:function(h){var V=new I(4326);K.getProjectedGeometry(h,V,this.geometryService).then(c.hitch(this,function(T){this.startPoint=T;this.startPointForNextLine=c.clone(T);
this._orgStartPointForNextLine=c.clone(T);0<this._itemList.length?this._reDrawParcel():(this.drawnOrSelectedGraphicsLayer.clear(),this.uploadedShapefileGraphicsLayer.clear(),this._arrayOfAllBoundaryLines=[],this._drawPoint(h),this._setExtentToLayer(this.drawnOrSelectedGraphicsLayer),this.emit("redrawAOI"))}))},_reDrawParcel:function(){this.drawnOrSelectedGraphicsLayer.clear();this.uploadedShapefileGraphicsLayer.clear();this._arrayOfAllBoundaryLines=[];this._drawPoint(this.startPoint);F.forEach(this._itemList,
c.hitch(this,function(h){this._drawStraightLine(h,!1)}));this.emit("redrawAOI");this._setExtentToLayer(this.drawnOrSelectedGraphicsLayer)},_handleEventsOnInitialRow:function(){this.own(w(this.bearingNode,"keydown",c.hitch(this,function(h){this._bearingValueEntered(h);h.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(h),this.emit("focusLastSelectedTab"))})));this.own(w(this.lengthNode,"keydown",c.hitch(this,function(h){this._lengthValueEntered(h);h.keyCode!==g.ESCAPE||this.isSingleTabSelected||
(W.stop(h),this.emit("focusLastSelectedTab"))})))},_bearingValueEntered:function(h){h=h.charCode||h.keyCode;h===g.ENTER||h===g.TAB?(this.bearingNode.get("value"),h===g.ENTER&&this.bearingNode.isValid()?z.focus(this.lengthNode):this.bearingNode.validate(!1)):setTimeout(c.hitch(this,function(){this.bearingNode.validate(!1)}),100)},_setValidatorForInitialRow:function(){this.bearingNode.validator=c.hitch(this,function(h){return this._bearingValidator(h,[])});this.bearingNode.invalidMessage=this.nls.newTraverse.invalidBearingMessage;
this.lengthNode.validator=c.hitch(this,function(h){if(0>parseFloat(h))return this.lengthNode.invalidMessage=this.nls.newTraverse.negativeLengthMessage,!1;this.lengthNode.invalidMessage=this.nls.newTraverse.invalidLengthMessage;return this._lengthValidator(h)});this.lengthNode.invalidMessage=this.nls.newTraverse.invalidLengthMessage},_bearingValidator:function(h,V){return-1!==V.indexOf(h)&&this._itemList&&0<this._itemList.length?!0:this._validateBearing(h,V)},_lengthValidator:function(h,V){return""===
h||"0"===h||0===h?!1:this._validateLength(h,V)},_lengthValueEntered:function(h){h=h.charCode||h.keyCode;h===g.ENTER||h===g.TAB?(this.lengthNode.get("value"),this.lengthNode.isValid()?this.bearingNode.isValid()?this.lengthNode.isValid()?(this._addNewItem(),z.focus(this.bearingNode)):(this.lengthNode.validate(!1),z.focus(this.lengthNode)):(this.bearingNode.validate(!1),z.focus(this.bearingNode)):this.lengthNode.validate(!1)):setTimeout(c.hitch(this,function(){this.lengthNode.validate(!1)}),100)},_attachPlanSettingsIconClickEvent:function(){this.own(w(this.planSettingIcon,
"click",c.hitch(this,function(h){W.stop(h);this._openPlanSettingsDialogBox(h)})))},_openPlanSettingsDialogBox:function(h){this.planSettingsWidget?(this.planSettingsWidget.position=h,this.planSettingsWidget.isTooltipDialogOpened?this.planSettingsWidget.closePopup():this.planSettingsWidget.openPopup()):(this.planSettingsWidget=new R({config:this.config,appConfig:this.appConfig,position:h,nls:this.nls}),this.planSettingsWidget.startup());this.own(w(this.planSettingsWidget,"planSettingsChanged",c.hitch(this,
function(V,T){this._planSettings.directionOrAngleUnits=this.config.traverseDirectionUnit=V;this._planSettings.distanceAndLengthUnits=this.config.traverseUnit=T;this.updateAccordingToPlanSettings(this._planSettings);this._reGenerateTraverseGrid()})));this.own(w(this.planSettingsWidget,"setFocusOnPlanSettingsIcon",c.hitch(this,function(){this._focusOutCurrentNode();z.focus(this.planSettingIcon)})))},_showMessage:function(h){(new E({message:h})).message=h},_attachLatLongTextBoxEvents:function(){this.own(w(this.latitudeTextBox,
"keydown",c.hitch(this,function(h){if(h.keyCode===g.ENTER||h.keyCode===g.SPACE)W.stop(h),this.latitudeTextBox.setValue(v.honourPopupRounding(8,this.latitudeTextBox.getValue())),this.latitudeTextBox.isValid()&&this.longitudeTextBox.isValid()?(this._onLocateLatLongClicked(),setTimeout(c.hitch(this,function(){z.focus(this.longitudeTextBox)}),100)):(this.latitudeTextBox.isValid()&&this.longitudeTextBox.isValid(),z.focus(this.longitudeTextBox));h.keyCode===g.TAB&&this.latitudeTextBox.setValue(v.honourPopupRounding(8,
this.latitudeTextBox.getValue()))})));this.own(w(this.latitudeTextBox,"blur",c.hitch(this,function(){!this.latitudeTextBox.isValid()&&this._latLongValue.latitude&&this.latitudeTextBox.setValue(this._latLongValue.latitude)})));this.own(w(this.longitudeTextBox,"keydown",c.hitch(this,function(h){if(h.keyCode===g.ENTER||h.keyCode===g.SPACE)W.stop(h),this.longitudeTextBox.setValue(v.honourPopupRounding(8,this.longitudeTextBox.getValue())),this.latitudeTextBox.isValid()&&this.longitudeTextBox.isValid()?
(this._onLocateLatLongClicked(),setTimeout(c.hitch(this,function(){z.focus(this.longitudeTextBox)}),100)):this.longitudeTextBox.isValid()&&!this.latitudeTextBox.isValid()?z.focus(this.latitudeTextBox):this._focusOutCurrentNode();h.keyCode===g.TAB&&this.longitudeTextBox.setValue(v.honourPopupRounding(8,this.longitudeTextBox.getValue()))})));this.own(w(this.longitudeTextBox,"blur",c.hitch(this,function(){!this.longitudeTextBox.isValid()&&this._latLongValue.longitude&&this.longitudeTextBox.setValue(this._latLongValue.longitude)})))},
_updateParcelValues:function(h,V){var T,r=!1;if(T=this._itemList[V]){var u=(u=h.get("value"))?c.trim(u.toString()):"";if(n.contains(h.domNode,"esriCTBearingRow")&&String(this._getBearingAccordingToPlanSettings(T.BearingConversions))!==u){var A="Bearing";T.Bearing=u;r=!0}else n.contains(h.domNode,"esriCTLengthRow")&&String(this._getRoundedValue(T.LengthConversions,"Length"))!==u&&(A="Length",T.Length=u,r=!0);r&&((V=this._getValidatedValues(T,A,V))?("Bearing"===A?(A=this._getBearingAccordingToPlanSettings(V.BearingConversions),
T.Bearing=this._getBearingAccordingToPlanSettings(V.BearingConversions,!0),h.set("value",A)):"Length"===A&&(A=this._getRoundedValue(T.LengthConversions,"Length"),T.Length=T.LengthConversions[this._planSettings.distanceAndLengthUnits],h.set("value",A)),this.setStartPoint(this.startPoint)):this._updateValues(T,A,h))}},_updateValues:function(h,V,T){if("Bearing"===V){h.Bearing=this._getBearingAccordingToPlanSettings(h.BearingConversions,!0);var r=this._getBearingAccordingToPlanSettings(h.BearingConversions)}else"Length"===
V&&(h.Length=h.LengthConversions[this._planSettings.distanceAndLengthUnits],r=this._getRoundedValue(h.LengthConversions,"Length"));T.set("value",r)},resetCoordinatesWidgetValue:function(){this.startPointForNextLine=this.startPoint=null;this.deactivateLocateIcon();this.setLatLongTextBoxValue("","");this.latitudeTextBox.reset();this.longitudeTextBox.reset();this._enableOrDisableTraverseGrid(!1);this._nodes=[];this._itemList=[];Q.empty(this.traverseGrid);this.bearingNode.set("value","");this.lengthNode.set("value",
"");this.bearingNode.reset();this.lengthNode.reset();this._showHideTraverseTools();this.clearSearchText();this.planSettingsWidget&&this.planSettingsWidget.config&&(this.planSettingsWidget.config.traverseDirectionUnit=this._configuredDirectionUnit,this.planSettingsWidget.config.traverseUnit=this._configuredDistanceUnit,this.planSettingsWidget.emit("planSettingsChanged",this._configuredDirectionUnit,this._configuredDistanceUnit))},_onDndDrop:function(){var h=[];this._dndContainer.sync();var V=this._dndContainer.getAllNodes();
V.forEach(c.hitch(this,function(T){T=parseInt(U.get(T,"rowIndex"),10);h.push(this._itemList[T])}));this._nodes=V;this._itemList=[];this._itemList=h;this._updateRowIndexes();this.setStartPoint(this.startPoint)},_reGenerateTraverseGrid:function(){this._dndContainer&&(this._dndContainer.destroy(),this._dndContainer=null);Q.empty(this.traverseGrid);this._createTraverseGrid()},focusFirstNodeOfSelectedTab:function(){z.focus(this.coordinatesHeader)},setFirstFocusNode:function(h){da.initFirstFocusNode(h,
this.coordinatesHeader)},_attachKeydownEventToTheNodes:function(){this.own(w(this.locateStartPointIcon,"keydown",c.hitch(this,function(h){if(h.keyCode===g.ENTER||h.keyCode===g.SPACE)W.stop(h),n.contains(this.locateStartPointIcon,"esriCTLocateIconSelected")?this.deactivateLocateIcon():this._activateLocateIcon();h.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(h),this.emit("focusLastSelectedTab"))})));this.own(w(this.latitudeTextBox,"keydown",c.hitch(this,function(h){h.keyCode!==g.ESCAPE||this.isSingleTabSelected||
(W.stop(h),this.emit("focusLastSelectedTab"))})));this.own(w(this.longitudeTextBox,"keydown",c.hitch(this,function(h){h.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(h),this.emit("focusLastSelectedTab"))})));this.own(w(this.locateLatAndLong,"keydown",c.hitch(this,function(h){if(h.keyCode===g.ENTER||h.keyCode===g.SPACE)W.stop(h),this.latitudeTextBox.isValid()&&this.longitudeTextBox.isValid()?(this._onLocateLatLongClicked(),setTimeout(c.hitch(this,function(){this._focusOutCurrentNode();z.focus(this.startPointSection)}),
100)):this._showMessage(this.nls.coordinatesWidget.invalidLatLongMessage);h.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(h),this.emit("focusLastSelectedTab"))})));this.own(w(this.planSettingIcon,"keydown",c.hitch(this,function(h){if(h.keyCode===g.ENTER||h.keyCode===g.SPACE){W.stop(h);var V=aa.position(this.planSettingIcon),T={};T.pageX=V.x+10;T.pageY=V.y+12;this._openPlanSettingsDialogBox(T);this.planSettingsWidget.setFocusToPlanSettingsDialog()}h.keyCode!==g.ESCAPE||this.isSingleTabSelected||
(W.stop(h),this.emit("focusLastSelectedTab"))})))},_setFocusOnExpandCollapseGridButton:function(){this._focusOutCurrentNode();z.focus(this.expandCollapseNode)},_attachSearchNodeEvents:function(){this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.inputNode&&(""!==this._inputNodeEventHandler&&null!==this._inputNodeEventHandler&&void 0!==this._inputNodeEventHandler&&this._inputNodeEventHandler[0].remove(),this._inputNodeEventHandler=this.own(w(this._searchInstance.search.inputNode,
"keydown",c.hitch(this,function(h){h.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(h),this.emit("focusLastSelectedTab"))}))));this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.submitNode&&(""!==this._submitNodeEventHandler&&null!==this._submitNodeEventHandler&&void 0!==this._submitNodeEventHandler&&this._submitNodeEventHandler[0].remove(),this._submitNodeEventHandler=this.own(w(this._searchInstance.search.submitNode,"keydown",c.hitch(this,function(h){h.keyCode!==
g.ESCAPE||this.isSingleTabSelected||(W.stop(h),this.emit("focusLastSelectedTab"))}))));this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.sourcesBtnNode&&(""!==this._buttonNodeEventHandler&&null!==this._buttonNodeEventHandler&&void 0!==this._buttonNodeEventHandler&&this._buttonNodeEventHandler[0].remove(),this._buttonNodeEventHandler=this.own(w(this._searchInstance.search.sourcesBtnNode,"keydown",c.hitch(this,function(h){h.keyCode!==g.ESCAPE||this.isSingleTabSelected||
(W.stop(h),this.emit("focusLastSelectedTab"))}))));this._searchInstance&&this._searchInstance.search&&this._searchInstance.search.clearNode&&(""!==this._clearNodeEventHandler&&null!==this._clearNodeEventHandler&&void 0!==this._clearNodeEventHandler&&this._clearNodeEventHandler[0].remove(),this._clearNodeEventHandler=this.own(w(this._searchInstance.search.clearNode,"keydown",c.hitch(this,function(h){h.keyCode!==g.ESCAPE||this.isSingleTabSelected||(W.stop(h),this.emit("focusLastSelectedTab"))}))))},
_focusOutCurrentNode:function(){z.curNode&&z.curNode.blur()}})})},"widgets/Screening/geometryUtils":function(){define("esri/geometry/Point esri/geometry/Polyline esri/geometry/Polygon esri/geometry/webMercatorUtils dojo/Deferred dojo/_base/array dojo/_base/lang esri/geometry/geometryEngine esri/SpatialReference esri/geometry/scaleUtils".split(" "),function(D,a,d,c,w,n,B,C,m,y){var I={getProjectedGeometry:function(e,b,q){var K=new w;if(c.canProject(e,b)){var M=c.project(e,b);K.resolve(M)}else q.project([e],
b,function(z){M=z[0];K.resolve(M)});return K.promise},getDestinationPoint:function(e,b,q){var K=e.x*Math.PI/180,M=b*Math.PI/180;b=Math.sin(M);M=Math.cos(M);var z=.9966471893352243*Math.tan(e.y*Math.PI/180);e=1/Math.sqrt(1+z*z);var v=z*e,Q=Math.atan2(z,M);z=e*b;var S=1-z*z,U=2.7233160610984375E11*S/4.040829998465916E13,g=1+U/16384*(4096+U*(-768+U*(320-175*U))),G=U/1024*(256+U*(-128+U*(74-47*U))),F=q/(6356752.314245*g),l=0;do{U=Math.cos(2*Q+F);var E=Math.sin(F);var R=Math.cos(F);var aa=G*E*(U+G/4*(R*
(-1+2*U*U)-G/6*U*(-3+4*E*E)*(-3+4*U*U)));var W=F;F=q/(6356752.314245*g)+aa}while(1E-12<Math.abs(F-W)&&200>++l);if(200<=l)return console.error("Formula failed to converge"),null;q=v*E-e*R*M;q=Math.atan2(v*R+e*E*M,.9966471893352243*Math.sqrt(z*z+q*q));S=2.0955066654848088E-4*S*(4+.003352810664775694*(4-3*S));K=(K+(Math.atan2(E*b,e*R-v*E*M)-.003352810664775694*(1-S)*z*(F+S*E*(U+S*R*(-1+2*U*U))))+3*Math.PI)%(2*Math.PI)-Math.PI;q=180*q/Math.PI;K=180*K/Math.PI;return new D(K,q,new m(4326))},getInverseCalculations:function(e,
b){var q=b.x*Math.PI/180-e.x*Math.PI/180,K=.9966471893352243*Math.tan(e.y*Math.PI/180);e=1/Math.sqrt(1+K*K);K*=e;var M=.9966471893352243*Math.tan(b.y*Math.PI/180);b=1/Math.sqrt(1+M*M);M*=b;var z=q,v=0;do{var Q=Math.sin(z);var S=Math.cos(z);var U=b*Q*b*Q+(e*M-K*b*S)*(e*M-K*b*S);U=Math.sqrt(U);if(0==U)return 0;var g=K*M+e*b*S;var G=Math.atan2(U,g);var F=e*b*Q/U;var l=1-F*F;var E=g-2*K*M/l;isNaN(E)&&(E=0);var R=2.0955066654848088E-4*l*(4+.003352810664775694*(4-3*l));var aa=z;z=q+.003352810664775694*
(1-R)*F*(G+R*U*(E+R*g*(-1+2*E*E)))}while(1E-12<Math.abs(z-aa)&&200>++v);if(200<=v)return null;z=2.7233160610984375E11*l/4.040829998465916E13;v=z/1024*(256+z*(-128+z*(74-47*z)));q=Math.atan2(b*Q,e*M-K*b*S);e=Math.atan2(e*Q,-K*b+e*M*S);q=(q+2*Math.PI)%(2*Math.PI);e=(e+2*Math.PI)%(2*Math.PI);K=Number((6356752.314245*(1+z/16384*(4096+z*(-768+z*(320-175*z))))*(G-v*U*(E+v/4*(g*(-1+2*E*E)-v/6*E*(-3+4*U*U)*(-3+4*E*E))))).toFixed(3));q=180*q/Math.PI;e=180*e/Math.PI;return{distance:K,initialBearing:q,finalBearing:e}},
getLineBetweenPoints:function(e){var b,q=[];n.forEach(e,B.hitch(this,function(K){q.push([K.x,K.y])}));0<q.length&&(b=new a({paths:[q],spatialReference:{wkid:4326}}));return b},getAngleBetweenPoints:function(e,b){e=I.getInverseCalculations(e,b);return null===e?0:e.initialBearing},getDistanceBetweenPoints:function(e,b){e=I.getInverseCalculations(e,b);return null===e?0:e.distance},getLengthOfGeometry:function(e){var b;var q={};(b=C.simplify(e))?e.spatialReference.isWebMercator()||4326===e.spatialReference.wkid?
(q.meters=C.geodesicLength(b,"meters"),q.miles=C.geodesicLength(b,"miles"),q.kilometers=C.geodesicLength(b,"kilometers"),q.feet=C.geodesicLength(b,"feet")):(q.meters=C.planarLength(b,"meters"),q.miles=C.planarLength(b,"miles"),q.kilometers=C.planarLength(b,"kilometers"),q.feet=C.planarLength(b,"feet")):(q.meters=0,q.miles=0,q.kilometers=0,q.feet=0);return q},getAreaOfGeometry:function(e){var b=C.simplify(e);var q={};b?e.spatialReference.isWebMercator()||4326===e.spatialReference.wkid?(q.acres=C.geodesicArea(b,
"acres"),q.squareMeters=C.geodesicArea(b,"square-meters"),q.squareFeet=C.geodesicArea(b,"square-feet"),q.squareUsFeet=C.geodesicArea(b,109406),q.squareKilometer=C.geodesicArea(b,"square-kilometers"),q.hectares=C.geodesicArea(b,"hectares"),q.squareMiles=C.geodesicArea(b,"square-miles")):(q.acres=C.planarArea(b,"acres"),q.squareMeters=C.planarArea(b,"square-meters"),q.squareFeet=C.planarArea(b,"square-feet"),q.squareUsFeet=C.planarArea(b,109406),q.squareKilometer=C.planarArea(b,"square-kilometers"),
q.hectares=C.planarArea(b,"hectares"),q.squareMiles=C.planarArea(b,"square-miles")):(q.acres=0,q.squareMeters=0,q.squareFeet=0,q.squareUsFeet=0,q.squareKilometer=0,q.hectares=0,q.squareMiles=0);return q},getPolyLineFromPaths:function(e){var b;var q=new a(new m({wkid:4326}));for(b=0;b<e.length;b++)q.addPath(e[b]);return q},getPolygonFromPolyLines:function(e,b,q,K){var M,z;var v=[];K=K?new d(new m(K)):new d(new m({wkid:4326}));for(M=0;M<e.length;M++)for(z=0;z<e[M].length;z++)v.push(e[M][z]);b?v.push(B.clone(v[0])):
q&&(v[v.length-1][0]=v[0][0],v[v.length-1][1]=v[0][1]);K.isClockwise(v)||v.reverse();K.addRing(v);return K},getPointsForArc:function(e,b,q,K){var M=[];var z=b-e;b=parseInt(z,10);0>=b&&(b=1);var v=Math.abs(z)/Math.abs(b);if(0<v)for(z=0;z<Math.abs(b)+1;z++){var Q=e+v*z;(Q=I.getDestinationPoint(q,Q,Math.abs(K)))&&M.push(Q)}return M},getArcParam:function(e){var b={};0>e.distance?0>e.radius?(b.bearing=e.initBearing+90,b.centerPoint=I.getDestinationPoint(e.chordMidPoint,b.bearing,e.centerAndChordDistance),
b.startAngle=I.getAngleBetweenPoints(b.centerPoint,e.chordEndPoint),b.endAngle=I.getAngleBetweenPoints(b.centerPoint,e.chordStartPoint)):(b.bearing=e.initBearing-90,b.centerPoint=I.getDestinationPoint(e.chordMidPoint,b.bearing,e.centerAndChordDistance),b.startAngle=I.getAngleBetweenPoints(b.centerPoint,e.chordStartPoint),b.endAngle=I.getAngleBetweenPoints(b.centerPoint,e.chordEndPoint)):0<e.radius?(b.bearing=e.initBearing+90,b.centerPoint=I.getDestinationPoint(e.chordMidPoint,b.bearing,e.centerAndChordDistance),
b.startAngle=I.getAngleBetweenPoints(b.centerPoint,e.chordStartPoint),b.endAngle=I.getAngleBetweenPoints(b.centerPoint,e.chordEndPoint)):(b.bearing=e.initBearing-90,b.centerPoint=I.getDestinationPoint(e.chordMidPoint,b.bearing,e.centerAndChordDistance),b.startAngle=I.getAngleBetweenPoints(b.centerPoint,e.chordEndPoint),b.endAngle=I.getAngleBetweenPoints(b.centerPoint,e.chordStartPoint));return b},removeNegativeExponents:function(e){return 1<e.toString().toLowerCase().split("e-").length?0:e},getChordLengthFromArcLength:function(e,
b){e=Math.abs(e);var q=Math.PI*Math.abs(b);b=Math.abs(b)*Math.sin(Math.abs(e)/Math.abs(b)/2);return e<=q?2*b:-2*b},getArcLengthFromChordLength:function(e,b){var q=Math.abs(e);b=Math.abs(b);q=2*Math.asin(q/(2*b))*b;0>e&&(q=2*Math.PI*b-q);return q},chordBearingToTangentBearing:function(e,b,q){var K=180/Math.PI*Math.acos(Math.abs(q)/2/Math.abs(b));b/=Math.abs(b);e=e+90*b-q/Math.abs(q)*b*K;return I.removeNegativeExponents(0>e?e+360:360<=e?e%360:e)},tangentBearingToChordBearing:function(e,b,q){var K=180/
Math.PI*Math.acos(Math.abs(q)/2/Math.abs(b));b/=Math.abs(b);e=e+90*b-q/Math.abs(q)*b*K;return I.removeNegativeExponents(0>e?e+360:360<=e?e%360:e)},getUnitValueForSR:function(e){switch(y.getUnitValueForSR(e)){case 1:return"meters";case 111194.87428468118:return"meters";case .3048:return"feet";case .3048006096:case .3048006096012192:return"uSSurveyFeet"}},getRotationAngleBetweenPoints:function(e,b){e=c.project(e,new m(102100));b=c.project(b,new m(102100));var q=b.x-e.x;e=b.y-e.y;b=180*Math.atan2(Math.abs(q),
Math.abs(e))/Math.PI;var K=180*Math.atan2(Math.abs(e),Math.abs(q))/Math.PI;q=I.removeNegativeExponents(q);e=I.removeNegativeExponents(e);b=I.removeNegativeExponents(b);K=I.removeNegativeExponents(K);if(0===e){if(0===q)return 0;if(0<q)return 90;if(0>q)return 270}else if(0<e){if(0===q)return 0;if(0<q)return b;if(0>q)return 270+K}else if(0>e){if(0===q)return 180;if(0<q)return 90+K;if(0>q)return 180+b}},getScaleDistanceBetweenPoints:function(e,b){e=c.project(e,new m(102100));b=c.project(b,new m(102100));
e=C.distance(e,b,9001);return I.removeNegativeExponents(e)}};return I})},"widgets/Screening/MapTooltipHandler":function(){define("dojo/_base/declare dijit/_WidgetBase dojo/_base/lang dojo/Evented dojo/dom-style dojo/dom-construct dojo/on".split(" "),function(D,a,d,c,w,n,B){return D([a,c],{baseClass:"jimu-widget-screening-MapTooltipHandler",_mapTooltip:null,_mapMoveHandler:null,_mapClickHandler:null,map:null,handleClickFor:null,constructor:function(C){this.handleClickFor=this.map=this._mapClickHandler=
this._mapMoveHandler=this._mapTooltip=null;d.mixin(this,C)},startup:function(){this.handleClickFor||(this.handleClickFor=this.map);this._createTooltip()},connectEventHandler:function(C){C&&this.updateTooltip(C);this._disableWebMapPopup();this._mapClickHandler=this.own(B(this.handleClickFor,"click",d.hitch(this,function(m){this._clicked(m)})))[0];"ontouchstart"in document.documentElement?w.set(this._mapTooltip,"display","none"):(this._mapMoveHandler=this.own(this.map.on("mouse-move",d.hitch(this,this._onMapMouseMove)))[0],
this.own(this.map.on("mouse-out",d.hitch(this,function(){w.set(this._mapTooltip,"display","none")}))))},disconnectEventHandler:function(){this._enableWebMapPopup();this._mapClickHandler&&this._mapClickHandler.remove();this._mapMoveHandler&&(this._mapMoveHandler.remove(),this._mapTooltip.style.display="none")},_createTooltip:function(){this._mapTooltip=n.create("div",{"class":"tooltip",innerHTML:this.toolTipText},this.map.container);w.set(this._mapTooltip,"position","fixed");w.set(this._mapTooltip,
"display","none")},_enableWebMapPopup:function(){this.map&&(this.map.infoWindow.hide(),this.map.setInfoWindowOnClick(!0))},_disableWebMapPopup:function(){this.map&&(this.map.infoWindow.hide(),this.map.setInfoWindowOnClick(!1))},_onMapMouseMove:function(C){if(C.clientX||C.pageY){var m=C.clientX;var y=C.clientY}else m=C.clientX+document.body.scrollLeft-document.body.clientLeft,y=C.clientY+document.body.scrollTop-document.body.clientTop;w.set(this._mapTooltip,"display","none");w.set(this._mapTooltip,
{left:m+15+"px",top:y+"px"});w.set(this._mapTooltip,"display","");this._onMoving(C)},_clicked:function(C){this.emit("clicked",C)},_onMoving:function(C){this.emit("moving",C)},updateTooltip:function(C){this.toolTipText=C;this._mapTooltip.innerHTML=this.toolTipText}})})},"widgets/Screening/conversionUtils":function(){define([],function(){var D={bearingFieldPlaces:4,planSettingsOptions:{directionOrAngleType:["northAzimuth","southAzimuth","quadrantBearing"],directionOrAngleUnits:["decimalDegree","degreeMinuteSeconds"],
distanceAndLengthUnits:["uSSurveyFeet","meters"],areaUnits:["squareUsFeet","acres","squareMeters"],circularCurveParameters:["radiusAndChordLength","radiusAndArcLength"]},getQuadrant:function(a){return{"-1":"NE","-2":"SE","-3":"SW","-4":"NW"}[a]},getQuadrantShortcut:function(a){a=a.toUpperCase();return{NE:"-1",SE:"-2",SW:"-3",NW:"-4"}[a]},getQuadrantShortcutFromDD:function(a){var d;0<=a&&90>=a?d="-1":90<a&&180>=a?d="-2":180<a&&270>a?d="-3":270<=a&&360>a&&(d="-4");return d},getQuadrantAngleFromNADD:function(a){a=
D.getQuadrantAngleAndShortcut(a);return a.quadrant.charAt(0)+a.quadrantAngle+a.quadrant.charAt(1)},getSouthAzimuthFromNorthAzimuth:function(a){var d;180<a?d=a-180:180>a?d=a+180:180===a&&(d=0);return d},DMStoDD:function(a){var d=Math.abs(parseFloat(a.degree));var c=parseFloat(a.minutes);var w=parseFloat(a.seconds);d=d+c/60+w/3600;a.isNegative&&(d*=-1);return d},DDtoDMS:function(a){var d=3600*a.angle;a=Math.round(d%60);a=60==a?0:a;var c=(d-a)/60;d=Math.round(c%60);d=60==d?0:d;return{degree:Math.round((c-
d)/60),minutes:d,seconds:a}},getBearingObjForFormat0:function(a){var d;var c={};c.degree=parseInt(a[1],10);c.minutes=parseInt(a[2]||0,10);c.seconds=parseInt(a[3]||0,10);c.quadrant=D.getQuadrant("-"+a[4]);c.quadrantShortcut="-"+a[4];"string"===typeof a[1]&&(d="-"===a[1].charAt(0));c.decimalDegrees=D.DMStoDD({degree:c.degree,minutes:c.minutes,seconds:c.seconds,isNegative:d});return c},getBearingObjForFormat1:function(a){var d;var c={};c.degree=parseInt(a[2],10);c.minutes=parseInt(a[3]||0,10);c.seconds=
parseInt(a[4]||0,10);c.quadrant=a[1]+a[5];c.quadrantShortcut=D.getQuadrantShortcut(a[1]+a[5]);"string"===typeof a[2]&&(d="-"===a[2].charAt(0));c.decimalDegrees=D.DMStoDD({degree:c.degree,minutes:c.minutes,seconds:c.seconds,isNegative:d});return c},getBearingObjForFormat2:function(a){var d;var c={};c.degree=parseInt(a[2],10);c.minutes=parseInt(a[3]||0,10);c.seconds=parseInt(a[4]||0,10);c.quadrant=a[1]+a[5];c.quadrantShortcut=D.getQuadrantShortcut(a[1]+a[5]);"string"===typeof a[2]&&(d="-"===a[2].charAt(0));
c.decimalDegrees=D.DMStoDD({degree:c.degree,minutes:c.minutes,seconds:c.seconds,isNegative:d});return c},getBearingObjForFormat3:function(a){var d;var c={};c.degree=parseInt(a[1],10);c.minutes=parseInt(a[2]||0,10);c.seconds=parseInt(a[3]||0,10);"string"===typeof a[1]&&(d="-"===a[1].charAt(0));c.decimalDegrees=D.DMStoDD({degree:c.degree,minutes:c.minutes,seconds:c.seconds,isNegative:d});c.quadrantShortcut=D.getQuadrantShortcutFromDD(c.decimalDegrees);c.quadrant=D.getQuadrant(c.quadrantShortcut);return c},
getBearingObjForFormat4:function(a){var d=D.DDtoDMS({angle:a[1]});var c={};c.degree=d.degree;c.minutes=d.minutes;c.seconds=d.seconds;c.decimalDegrees=a[1];c.quadrantShortcut=D.getQuadrantShortcutFromDD(c.decimalDegrees);c.quadrant=D.getQuadrant(c.quadrantShortcut);return c},getBearingObjForFormat5:function(a){var d;var c={};c.degree=parseInt(a[1],10);c.minutes=parseInt(a[2]||0,10);c.seconds=parseInt(a[3]||0,10);"string"===typeof a[1]&&(d="-"===a[1].charAt(0));c.decimalDegrees=D.DMStoDD({degree:c.degree,
minutes:c.minutes,seconds:c.seconds,isNegative:d});c.quadrantShortcut=D.getQuadrantShortcutFromDD(c.decimalDegrees);c.quadrant=D.getQuadrant(c.quadrantShortcut);return c},getBearingObjForFormat6:function(a){var d;var c={};c.degree=parseInt(a[1],10);c.minutes=parseInt(a[2]||0,10);c.seconds=parseInt(a[3]||0,10);c.quadrantShortcut=a[4];c.quadrant=D.getQuadrant(c.quadrantShortcut);"string"===typeof a[1]&&(d="-"===a[1].charAt(0));c.decimalDegrees=D.DMStoDD({degree:c.degree,minutes:c.minutes,seconds:c.seconds,
isNegative:d});return c},getBearingObjForFormat7:function(a){var d={};d.decimalDegrees=a[2];var c=D.DDtoDMS({angle:d.decimalDegrees});d.degree=parseInt(c.degree,10);d.minutes=parseInt(c.minutes||0,10);d.seconds=parseInt(c.seconds||0,10);d.quadrant=a[1]+a[3];d.quadrantShortcut=D.getQuadrantShortcut(d.quadrant);return d},getBearingObjForFormat8:function(a){var d={};d.decimalDegrees=a[1];var c=D.DDtoDMS({angle:d.decimalDegrees});d.degree=parseInt(c.degree,10);d.minutes=parseInt(c.minutes||0,10);d.seconds=
parseInt(c.seconds||0,10);d.quadrantShortcut=a[2];d.quadrant=D.getQuadrant(d.quadrantShortcut);return d},getQuadrantAngleAndShortcut:function(a){var d={};0<=a&&90>=a?(d.quadrantAngle=a,d.quadrant="NE"):90<a&&180>=a?(d.quadrantAngle=180-a,d.quadrant="SE"):180<a&&270>a?(d.quadrantAngle=a-180,d.quadrant="SW"):270<=a&&360>a&&(d.quadrantAngle=360-a,d.quadrant="NW");return d},roundSeconds:function(a){a=Number(a);return 10>a?"0"+a:a},honourPopupRounding:function(a,d){if(isNaN(d))return d;if(isNaN(a)||null===
a)a=4;var c=Math.pow(10,a);d=Math.round(d*c)/c;d=d.toFixed(a);return parseFloat(d)},convertBearingToOutputFormats:function(a){var d={};var c={};360===a.degree&&(a.degree=0);d=a.decimalDegrees;360===d&&(d=0);c.naDD=d;c.naDDRound=D.honourPopupRounding(D.bearingFieldPlaces,d);360===Number(c.naDDRound)&&(c.naDDRound=0);var w=10>a.minutes?"0"+a.minutes:a.minutes;var n=a.seconds;0<Number(w)&&0<Number(D.roundSeconds(n))?c.naDMS=a.degree+"-"+w+"-"+D.roundSeconds(n):0===Number(w)&&0<Number(D.roundSeconds(n))?
c.naDMS=a.degree+"-"+w+"-"+D.roundSeconds(n):0<Number(w)&&0===Number(D.roundSeconds(n))?c.naDMS=a.degree+"-"+w+"-00":0===Number(w)&&0===Number(D.roundSeconds(n))&&(c.naDMS=a.degree+"-00-00");a=D.getQuadrantAngleAndShortcut(d);c.qb3DD=a.quadrant.charAt(0)+a.quadrantAngle+a.quadrant.charAt(1);c.qb3DDRound=a.quadrant.charAt(0)+D.honourPopupRounding(D.bearingFieldPlaces,a.quadrantAngle)+a.quadrant.charAt(1);w=D.DDtoDMS({angle:a.quadrantAngle});n=10>w.minutes?"0"+w.minutes:w.minutes;var B=w.seconds;0<
Number(n)&&0<Number(D.roundSeconds(B))?c.qb3DMS=a.quadrant.charAt(0)+w.degree+"-"+n+"-"+D.roundSeconds(B)+a.quadrant.charAt(1):0===Number(n)&&0<Number(D.roundSeconds(B))?c.qb3DMS=a.quadrant.charAt(0)+w.degree+"-"+n+"-"+D.roundSeconds(B)+a.quadrant.charAt(1):0<Number(n)&&0===Number(D.roundSeconds(B))?c.qb3DMS=a.quadrant.charAt(0)+w.degree+"-"+n+"-00"+a.quadrant.charAt(1):0===Number(n)&&0===Number(D.roundSeconds(B))&&(c.qb3DMS=a.quadrant.charAt(0)+w.degree+"-00-00"+a.quadrant.charAt(1));d=D.getSouthAzimuthFromNorthAzimuth(d);
360===d&&(d=0);c.saDD=d;c.saDDRound=D.honourPopupRounding(D.bearingFieldPlaces,d);360===Number(c.saDDRound)&&(c.saDDRound=0);d=D.DDtoDMS({angle:d});360===d.degree&&(d.degree=0);a=10>d.minutes?"0"+d.minutes:d.minutes;w=d.seconds;0<Number(a)&&0<Number(D.roundSeconds(w))?c.saDMS=d.degree+"-"+a+"-"+D.roundSeconds(w):0===Number(a)&&0<Number(D.roundSeconds(w))?c.saDMS=d.degree+"-"+a+"-"+D.roundSeconds(w):0<Number(a)&&0===Number(D.roundSeconds(w))?c.saDMS=d.degree+"-"+a+"-00":0===Number(a)&&0===Number(D.roundSeconds(w))&&
(c.saDMS=d.degree+"-00-00");return c},getBearingDetailsOfRequiredFormat:function(a,d){var c={};switch(d){case 0:c=D.getBearingObjForFormat0(a);break;case 1:c=D.getBearingObjForFormat1(a);break;case 2:c=D.getBearingObjForFormat2(a);break;case 3:c=D.getBearingObjForFormat3(a);break;case 4:c=D.getBearingObjForFormat4(a);break;case 5:c=D.getBearingObjForFormat5(a);break;case 6:c=D.getBearingObjForFormat6(a);break;case 7:c=D.getBearingObjForFormat7(a);break;case 8:c=D.getBearingObjForFormat8(a)}return D.convertBearingToOutputFormats(c)},
getBearingFormatArr:function(){var a=[];a.push({regex:/^((?:\-)?(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0))(?:\-(0|[0-5]?\d)\-(0|[0-5]\d))?\-([1-4])$/,type:"degreeMinuteSeconds"});a.push({regex:/^([nNsS])((?:\-)?(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0))(?:\-(0|[0-5]?\d)\-(0|[0-5]\d))?([eEwW])$/,type:"degreeMinuteSeconds"});a.push({regex:/^([nNsS])((?:\-)?(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0))(?:\.([0-5]\d)(?:([0-5]\d))?)?([eEwW])$/,type:"degreeMinuteSeconds"});a.push({regex:/^((?:\-)?(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0))(?:\.([0-5]\d)(?:([0-5]\d))?)?$/,
type:"degreeMinuteSeconds"});a.push({regex:/^((?:(?:\-?)(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0)(?:\.\d+)?)|(?:\-?)(?:\.\d+))$/,type:"decimalDegree"});a.push({regex:/^((?:\-)?(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0))(?:\-(0|[0-5]?\d)\-((?:[0-5]\d)))?$/,type:"degreeMinuteSeconds"});a.push({regex:/^((?:\-)?(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0))(?:\.([0-5]\d)(?:([0-5]\d))?)?(\-[1-4])$/,type:"degreeMinuteSeconds"});a.push({regex:/^([nNsS])((?:(?:\-?)(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0)(?:\.\d+)?)|(?:\-?)(?:\.\d+))([eEwW])$/,
type:"decimalDegree"});a.push({regex:/^((?:(?:\-?)(?:3[0-5]\d|[12]\d{2}|[1-9]\d?|0)(?:\.\d+)?)|(?:\-?)(?:\.\d+))(\-[1-4])$/,type:"decimalDegree"});return a},getNorthAzimuthAngle:function(a,d){d=d.toUpperCase();a=Number(a);switch(d){case "-1":case "NE":return(a+360)%360;case "-2":case "SE":return(540-a)%360;case "-3":case "SW":return(540+a)%360;case "-4":case "NW":return(360-a)%360}},convertBearingToNorthAzimuth:function(a,d,c){switch(d){case 0:d=D.getBearingObjForFormat0(a);d=D.getNorthAzimuthAngle(d.decimalDegrees,
"-"+a[4]);d=D.DDtoDMS({angle:d});a[1]=d.degree;a[2]=d.minutes;a[3]=d.seconds;break;case 1:d=D.getBearingObjForFormat1(a);d=D.getNorthAzimuthAngle(d.decimalDegrees,a[1]+a[5]);d=D.DDtoDMS({angle:d});a[2]=d.degree;a[3]=d.minutes;a[4]=d.seconds;break;case 2:d=D.getBearingObjForFormat2(a);d=D.getNorthAzimuthAngle(d.decimalDegrees,a[1]+a[5]);d=D.DDtoDMS({angle:d});a[2]=d.degree;a[3]=d.minutes;a[4]=d.seconds;break;case 3:"northAzimuth"===c.directionOrAngleType||"quadrantBearing"===c.directionOrAngleType?
(d=D.getBearingObjForFormat3(a),d=D.getNorthAzimuthAngle(d.decimalDegrees,"-1"),d=D.DDtoDMS({angle:d}),a[1]=d.degree,a[2]=d.minutes,a[3]=d.seconds):"southAzimuth"===c.directionOrAngleType&&(d=D.getBearingObjForFormat3(a),d=D.getNorthAzimuthAngle(d.decimalDegrees,"-3"),d=D.DDtoDMS({angle:d}),a[1]=d.degree,a[2]=d.minutes,a[3]=d.seconds);break;case 4:"northAzimuth"===c.directionOrAngleType||"quadrantBearing"===c.directionOrAngleType?a[1]=D.getNorthAzimuthAngle(a[1],"-1"):"southAzimuth"===c.directionOrAngleType&&
(a[1]=D.getNorthAzimuthAngle(a[1],"-3"));break;case 5:"northAzimuth"===c.directionOrAngleType?(d=D.getBearingObjForFormat5(a),d=D.getNorthAzimuthAngle(d.decimalDegrees,"-1"),d=D.DDtoDMS({angle:d}),a[1]=d.degree,a[2]=d.minutes,a[3]=d.seconds):"southAzimuth"===c.directionOrAngleType?(d=D.getBearingObjForFormat5(a),d=D.getNorthAzimuthAngle(d.decimalDegrees,"-3"),d=D.DDtoDMS({angle:d}),a[1]=d.degree,a[2]=d.minutes,a[3]=d.seconds):"quadrantBearing"===c.directionOrAngleType&&(a=null);break;case 6:d=D.getBearingObjForFormat6(a);
d=D.getNorthAzimuthAngle(d.decimalDegrees,a[4]);d=D.DDtoDMS({angle:d});a[1]=d.degree;a[2]=d.minutes;a[3]=d.seconds;break;case 7:a[2]=D.getNorthAzimuthAngle(a[2],a[1]+a[3]);break;case 8:a[1]=D.getNorthAzimuthAngle(a[1],a[2])}return a},categorizeBearingFormat:function(a,d){var c,w;a=a.toString();var n=D.getBearingFormatArr();for(w=0;w<n.length;w++)if(n[w].type===d.directionOrAngleUnits&&(c=n[w].regex.exec(a.trim()))&&0<c.length){c=D.convertBearingToNorthAzimuth(c,w,d);break}if(!c)for(w=0;w<n.length;w++)if(n[w].type!==
d.directionOrAngleUnits&&(c=n[w].regex.exec(a.trim()))&&0<c.length){c=D.convertBearingToNorthAzimuth(c,w,d);break}return c?D.getBearingDetailsOfRequiredFormat(c,w):null},metersToUSSurveyFeet:function(a){a=Number(a);return 3.28083333333*a},usSurveyFeetToMeters:function(a){a=Number(a);return.304800609601*a},feetToUSSurveyFeet:function(a){a=Number(a);return D.metersToUSSurveyFeet(.3048*a)},feetToMeters:function(a){a=Number(a);return.3048*a},usSurveyFeetToFeet:function(a){a=Number(a);return 1.000001999999281*
a},metersToFeet:function(a){a=Number(a);return 3.280839895*a},acresToSquareKilometer:function(a){a=Number(a);return.00404686*a},milesToKilometer:function(a){a=Number(a);return 1.60934*a},getLengthObjForFormat0:function(a,d){var c={};"uSSurveyFeet"===d?(c.uSSurveyFeet=Number(a[0]),c.uSSurveyFeetRound=Math.round(1E4*c.uSSurveyFeet)/1E4,c.meters=D.usSurveyFeetToMeters(a[0]),c.metersRound=Math.round(1E4*c.meters)/1E4,c.feet=D.usSurveyFeetToFeet(c.uSSurveyFeet),c.feetRound=Math.round(1E4*c.feet)/1E4):
"meters"===d&&(c.uSSurveyFeet=D.metersToUSSurveyFeet(a[0]),c.uSSurveyFeetRound=Math.round(1E4*c.uSSurveyFeet)/1E4,c.meters=Number(a[0]),c.metersRound=Math.round(1E4*c.meters)/1E4,c.feet=D.metersToFeet(c.meters),c.feetRound=Math.round(1E4*c.feet)/1E4);return c},getLengthObjForFormat1:function(a){var d={};d.uSSurveyFeet=Number(a[2]);d.uSSurveyFeetRound=Math.round(1E4*d.uSSurveyFeet)/1E4;d.meters=D.usSurveyFeetToMeters(a[2]);d.metersRound=Math.round(1E4*d.meters)/1E4;d.feet=D.usSurveyFeetToFeet(d.uSSurveyFeet);
d.feetRound=Math.round(1E4*d.feet)/1E4;return d},getLengthObjForFormat2:function(a){var d={};d.uSSurveyFeet=D.metersToUSSurveyFeet(a[2]);d.uSSurveyFeetRound=Math.round(1E4*d.uSSurveyFeet)/1E4;d.meters=Number(a[2]);d.metersRound=Math.round(1E4*d.meters)/1E4;d.feet=D.metersToFeet(d.meters);d.feetRound=Math.round(1E4*d.feet)/1E4;return d},getLengthObjForFormat3:function(a){var d={};d.uSSurveyFeet=D.feetToUSSurveyFeet(a[2]);d.uSSurveyFeetRound=Math.round(1E4*d.uSSurveyFeet)/1E4;d.meters=D.feetToMeters(a[2]);
d.metersRound=Math.round(1E4*d.meters)/1E4;d.feet=Number(a[2]);d.feetRound=Math.round(1E4*d.feet)/1E4;return d},categorizeLengthFormat:function(a,d){var c,w;var n=[];a=a.toString();n.push(/^((\-?)((0?|([1-9]\d*))(\.\d+)?))$/);n.push(/^(((\-?)((0?|([1-9]\d*))(\.\d+)?))(ft|FT|fT|Ft))$/);n.push(/^(((\-?)((0?|([1-9]\d*))(\.\d+)?))(m|M))$/);for(w=0;w<n.length&&!((c=n[w].exec(a.trim()))&&0<c.length);w++);c?(a=D.getLengthOfRequiredFormat(c,w,d))&&isNaN(a.meters)&&(a=null):a=null;return a},categorizeLengthFormatForFeet:function(a){var d,
c;var w=[];a=a.toString();w.push(/^((\-?)((0?|([1-9]\d*))(\.\d+)?))$/);for(c=0;c<w.length&&!((d=w[c].exec(a.trim()))&&0<d.length);c++);return d?D.getLengthObjForFormat3(d):null},getLengthOfRequiredFormat:function(a,d,c){var w={};switch(d){case 0:w=D.getLengthObjForFormat0(a,c);break;case 1:w=D.getLengthObjForFormat1(a);break;case 2:w=D.getLengthObjForFormat2(a)}return w}};return D})},"widgets/Screening/planSettings/planSettings":function(){define("dojo/_base/declare dojo/_base/lang dojo/_base/array dojo/_base/html dojo/on dijit/TooltipDialog jimu/dijit/formSelect dojo/dom-construct dijit/popup jimu/BaseWidget dojo/Evented dojo/dom-class dijit/focus dojo/keys dojo/_base/event".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K){return D([y,I],{baseClass:"jimu-widget-screening",planSettingsOptions:{directionOrAngleUnits:["decimalDegree","degreeMinuteSeconds"],distanceAndLengthUnits:["uSSurveyFeet","meters"]},isTooltipDialogOpened:!1,constructor:function(M){this.planSettingsOptions={directionOrAngleUnits:["decimalDegree","degreeMinuteSeconds"],distanceAndLengthUnits:["uSSurveyFeet","meters"]};this.isTooltipDialogOpened=!1;a.mixin(this,M)},startup:function(){this._popupDialog=new n({"class":"esriCTPlanSettingsDialog "+
this.baseClass,style:{width:"250px"}});this._popupDialog.startup();"DartTheme"===this.appConfig.theme.name&&e.add(this._popupDialog.domNode,"dart-panel");this.own(w(document.body,"click",a.hitch(this,function(M){this.isPartOfPopup(M.target||M.srcElement)||this.closePopup()})));this.own(w(window,"resize",a.hitch(this,function(){this.closePopup()})));this.createPlanSettingsUI()},createPlanSettingsUI:function(){var M=C.create("div",{"class":"esriCTPlanSettingsContainer"},null);C.create("div",{"class":"esriCTEllipsis esriCTPlanSettingLabel",
innerHTML:this.nls.planSettings.directionUnitLabelText},M);this.directionUnitSelect=new B({"aria-label":this.nls.planSettings.directionUnitLabelText});this._loadOptionsForDropDown(this.directionUnitSelect,this.planSettingsOptions.directionOrAngleUnits,this.config.traverseDirectionUnit);this.directionUnitSelect.placeAt(M);this.own(w(this.directionUnitSelect,"keydown",a.hitch(this,function(z){z.keyCode===q.ESCAPE&&(K.stop(z),this.closePopup())})));C.create("div",{"class":"esriCTEllipsis esriCTPlanSettingLabel",
innerHTML:this.nls.planSettings.distanceUnitLabelText},M);this.distanceUnitSelect=new B({"aria-label":this.nls.planSettings.distanceUnitLabelText});this.own(w(this.distanceUnitSelect,"keydown",a.hitch(this,function(z){z.keyCode===q.ESCAPE&&(K.stop(z),this.closePopup())})));this._loadOptionsForDropDown(this.distanceUnitSelect,this.planSettingsOptions.distanceAndLengthUnits,this.config.traverseUnit);this.distanceUnitSelect.placeAt(M);this._popupDialog.setContent(M);M=C.create("button",{innerHTML:this.nls.common.apply,
"class":"esriCTEllipsis jimu-btn esriCTPlanSettingsBtn"},C.create("div",{"class":"esriCTPlanSettingsBtnContainer"},M));this.own(w(M,"click",a.hitch(this,function(){this._savePlanSettings()})));this.own(w(M,"keydown",a.hitch(this,function(z){if(z.keyCode===q.ENTER||z.keyCode===q.SPACE)K.stop(z),this._savePlanSettings();z.keyCode===q.ESCAPE&&(K.stop(z),this.closePopup())})));this.openPopup()},_savePlanSettings:function(){this.emit("planSettingsChanged",this.directionUnitSelect.get("value"),this.distanceUnitSelect.get("value"));
this.closePopup()},_loadOptionsForDropDown:function(M,z,v){var Q=[],S;d.forEach(z,a.hitch(this,function(U){this.nls.units[U]&&(S={value:U,label:this.nls.units[U]});Q.push(S);v===S.value&&(S.selected=!0)}));M.addOption(Q)},openPopup:function(){m.open({popup:this._popupDialog,x:this.position.pageX+11,y:this.position.pageY,tabindex:"0"});this.isTooltipDialogOpened=!0},closePopup:function(){this._popupDialog&&(m.close(this._popupDialog),this.isTooltipDialogOpened=!1,this._restoreDialog(),this.emit("setFocusOnPlanSettingsIcon"))},
isPartOfPopup:function(M){var z=this._popupDialog.domNode;return M===z||c.isDescendant(M,z)},_restoreDialog:function(){this.directionUnitSelect.set("value",this.config.traverseDirectionUnit);this.distanceUnitSelect.set("value",this.config.traverseUnit)},_focusOutCurrentNode:function(){b.curNode&&b.curNode.blur()},setFocusToPlanSettingsDialog:function(){this._focusOutCurrentNode();b.focus(this.directionUnitSelect)}})})},"widgets/Screening/impactSummaryReport/impactSummaryReport":function(){define("dojo/_base/declare dojo/text!./impactSummaryReport.html dijit/_WidgetsInTemplateMixin dojo/_base/lang dojo/_base/array dojo/Evented jimu/BaseWidget dojo/on dojo/dom-class dojo/dom-attr esri/geometry/geometryEngine esri/geometry/Polyline esri/SpatialReference esri/graphic dojo/dom-construct esri/tasks/query esri/tasks/QueryTask dojo/Deferred ../geometryUtils ../conversionUtils ../highlightSymbolUtils ../fieldSelectorPopup/fieldSelectorPopup esri/lang jimu/utils dojo/query dojo/number dojo/string dojo/promise/all dojo/keys dijit/focus dojo/_base/event esri/arcadeProfiles/fieldCalculateProfile esri/arcade/arcade esri/arcade/Feature esri/support/expressionUtils esri/arcadeProfiles/utils".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U,g,G,F,l,E,R,aa,W,da,h,V,T,r,u,A){return D([B,d,n],{baseClass:"jimu-widget-screening-impactSummaryReport",templateString:a,_feetUnitData:[],_squareFeetUnitData:[],_milesUnitData:[],_acresUnitData:[],_metersUnitData:[],_squareMetersUnitData:[],_kilometersUnitData:[],_squareKilometersUnitData:[],_squareMilesUnitData:[],_hectaresUnitData:[],_printCompleteData:{},_printData:{},_feetUnitInfo:[],_squareFeetUnitInfo:[],_countUnitInfo:[],_milesUnitInfo:[],
_acresUnitInfo:[],_metersUnitInfo:[],_squareMetersUnitInfo:[],_kilometersUnitInfo:[],_squareKilometersUnitInfo:[],_hectaresUnitInfo:[],_squareMilesUnitInfo:[],_intersectFeatureCount:0,isExceedingMaxRecordCount:!1,intersectingFeatureIdsToTolerance:[],intersectingFeatureIds:[],_lengthAnalysisUnitsArray:[],_areaAnalysisUnitsArray:[],_aggregatedFeatureGeometries:[],_featureIntersectResultArr:[],_layerDefinition:null,_isFieldsSelectorClick:!1,_selectedFields:[],constructor:function(x){this._feetUnitData=
[];this._squareFeetUnitData=[];this._milesUnitData=[];this._acresUnitData=[];this._metersUnitData=[];this._squareMetersUnitData=[];this._kilometersUnitData=[];this._squareKilometersUnitData=[];this._squareMilesUnitData=[];this._hectaresUnitData=[];this._printCompleteData={};this._printData={};this._feetUnitInfo=[];this._squareFeetUnitInfo=[];this._countUnitInfo=[];this._milesUnitInfo=[];this._acresUnitInfo=[];this._metersUnitInfo=[];this._squareMetersUnitInfo=[];this._kilometersUnitInfo=[];this._squareKilometersUnitInfo=
[];this._hectaresUnitInfo=[];this._squareMilesUnitInfo=[];this._intersectFeatureCount=0;this.isExceedingMaxRecordCount=!1;this.intersectingFeatureIdsToTolerance=[];this.intersectingFeatureIds=[];this._lengthAnalysisUnitsArray=[];this._areaAnalysisUnitsArray=[];this._aggregatedFeatureGeometries=[];this._featureIntersectResultArr=[];this._layerDefinition=null;this._isFieldsSelectorClick=!1;this._selectedFields=[];c.mixin(this,x)},postCreate:function(){this._layerDefinition=F.getFeatureLayerDefinition(this.featureLayer);
this._lengthAnalysisUnitsArray=["Feet","Miles","Meters","Kilometers"];this._areaAnalysisUnitsArray="SquareFeet Acres SquareMeters SquareKilometers Hectares SquareMiles".split(" ");this.own(C(this.impactSummaryLayerMaxRecordHint,"click",c.hitch(this,function(x){x.stopPropagation();x.preventDefault();this.isExceedingMaxRecordCount?this.emit("showMessage",this.nls.reportsTab.unableToAnalyzeText):this.emit("showMessage",this.nls.reportsTab.layerNotVisibleText)})));this._attachEventToNodes()},_displayLayerNotVisibleText:function(){m.add(this.impactSummaryLayerFeatureCount,
"esriCTHidden");m.remove(this.layerTitleAndFieldParentContainer,"esriCTLayerSectionDisabled");y.set(this.impactSummaryLayerMaxRecordHint,"title",this.nls.reportsTab.layerNotVisibleText);m.remove(this.impactSummaryLayerMaxRecordHint,"esriCTHidden");m.add(this.impactSummaryLayerTitle,"esriCTLayerTitleOverrideWidth");this._showMessage(this.nls.reportsTab.layerNotVisibleText)},generateReport:function(x,H,L){var Y,ba;var ca=new v;this._setAttributeToFeatureLayerContainer();this._setFeatureLayerTitle();
this._attachEventToLayerTitle();this._aggregatedFeatureGeometries=[];this._featureIntersectResultArr=[];(ba=this.layerInfosObj.getLayerInfoById(this.featureLayer.id))&&ba.isVisible()&&ba.isInScale()||ba&&!ba.isVisible()&&!this.config.allowVisibleLayerAnalysisOnly||ba&&!ba.isInScale()&&!this.config.allowVisibleLayerAnalysisOnly||this.isFeatureCollectionLayer?this._getIntersectingFeaturesCount(L).then(c.hitch(this,function(fa){this._getIntersectingFeaturesCount(H).then(c.hitch(this,function(ia){this.intersectingFeatureIdsToTolerance=
this._getUniqueIds(fa,ia);this._getIntersectingFeaturesCount(x).then(c.hitch(this,function(ka){this.intersectingFeatureIds=c.clone(ka);ka=this._getUniqueIds(ia,ka);if(this.isExceedingMaxRecordCount)this._setFeatureLayerIntersectFeatureCount(ka.length),this._pushDataInPrintDataObj(this.configuredLayerLabel,null,null),this._printData={},this._printData=c.clone(this._printCompleteData),this._showMessage(this.nls.reportsTab.unableToAnalyzeText),m.remove(this.layerTitleAndFieldParentContainer,"esriCTLayerSectionDisabled"),
this._showReport(),ca.resolve(this._getReportLayerDetails([]));else{var f=x||H;this._getFeatureByChunks(ka,f).then(c.hitch(this,function(J){var P=[];this._featureIntersectResultArr=[];w.forEach(J,c.hitch(this,function(Z){x&&I.touches(Z.geometry,x)||P.push(Z)}));var N=[];this._setFeatureLayerIntersectFeatureCount(P.length);0<P.length?("esriGeometryPolyline"!==this.featureLayer.geometryType&&"esriGeometryPolygon"!==this.featureLayer.geometryType||!x?N=P:(Y=this._polygonToPolyline(x),N=this._getCutOrWithInFeatures(Y,
P,x)),this._createLayerDetails(N,this.featureLayer.geometryType).then(c.hitch(this,function(){this._filterPrintDataObjAccToConfiguredFields(this.configuredField);m.remove(this.impactSummaryLayerField,"esriCTImpactSummaryLayerFieldIconDisabled");m.remove(this.layerTitleAndFieldParentContainer,"esriCTLayerSectionDisabled");this._featureIntersectResultArr=N;this._showReport();ca.resolve(this._getReportLayerDetails(N))}))):(this._pushDataInPrintDataObj(this.configuredLayerLabel,null,null),this._printData=
{},this._printData=c.clone(this._printCompleteData),this._showMessage(this.nls.reportsTab.noDetailsAvailableText),m.remove(this.layerTitleAndFieldParentContainer,"esriCTLayerSectionDisabled"),this._featureIntersectResultArr=N,this._showReport(),ca.resolve(this._getReportLayerDetails(N)))}))}}))}))})):(this._displayLayerNotVisibleText(),ca.resolve());return ca.promise},retainLastSelectedField:function(){null!==this.retainSelectedFieldsArr&&(this._selectedFields=this.retainSelectedFieldsArr,m.contains(this.impactSummaryLayerField,
"esriCTImpactSummaryLayerFieldIconDisabled")||this._filterFieldsForReport(this.retainSelectedFieldsArr))},_getReportLayerDetails:function(x){var H={};H.id=this.id;H.featureLayerId=this.featureLayer.id;H.features=x;H.printInfo={};H.printInfo.isExceedingMaxRecordCount=this.isExceedingMaxRecordCount;H.printInfo.featureCount=this._intersectFeatureCount;H.printInfo.info=this._printData;H.printInfo.feetUnitInfo=this._feetUnitInfo;H.printInfo.squareFeetUnitInfo=this._squareFeetUnitInfo;H.printInfo.countUnitInfo=
this._countUnitInfo;H.printInfo.milesUnitInfo=this._milesUnitInfo;H.printInfo.acresUnitInfo=this._acresUnitInfo;H.printInfo.metersUnitInfo=this._metersUnitInfo;H.printInfo.squareMetersUnitInfo=this._squareMetersUnitInfo;H.printInfo.kilometersUnitInfo=this._kilometersUnitInfo;H.printInfo.squareKilometersUnitInfo=this._squareKilometersUnitInfo;H.printInfo.squareMilesUnitInfo=this._squareMilesUnitInfo;H.printInfo.hectaresUnitInfo=this._hectaresUnitInfo;H.printInfo.geometryType=this.featureLayer.geometryType;
H.printInfo.groupbyfieldCheckBoxStatus=this.groupbyfieldCheckBoxStatus;return H},_setAttributeToFeatureLayerContainer:function(){y.set(this.impactSummaryLayerContainer,"featureLayerID",this.featureLayer.id)},_setFeatureLayerTitle:function(x){var H=this.configuredLayerLabel;this.configuredLayerLabel||(H=this.configuredLayerLabel=this.featureLayer.name);if(x||0===x)H=R.substitute(this.nls.reportsTab.layerNameWithFeatureCount,{layerName:this.configuredLayerLabel,featureCount:x});y.set(this.impactSummaryLayerTitle,
"innerHTML",F.sanitizeHTML(this.configuredLayerLabel));y.set(this.impactSummaryLayerTitle,"title",F.sanitizeHTML(this.configuredLayerLabel));y.set(this.layerTitleAndFieldParentContainer,"aria-label",H)},_attachEventToLayerTitle:function(){this.own(C(this.layerTitleAndFieldParentContainer,"click",c.hitch(this,function(x){m.contains(x.target,"esriCTImpactSummaryLayerFieldIcon")?m.contains(this.impactSummaryLayerField,"esriCTImpactSummaryLayerFieldIconDisabled")||this._createFieldSelectorPopupWidget():
m.contains(this.layerTitleAndFieldParentContainer,"esriCTLayerSectionDisabled")||this._showOrHideLayerDetailsContainer()})))},_createFieldSelectorPopupWidget:function(){this._isFieldsSelectorClick=!0;if(this._fieldSelectorWidget)this._fieldSelectorWidget.onFieldsSelectorClick();else this._fieldSelectorWidget=new g({outFields:this.configuredField,popupTitle:this.configuredLayerLabel,fieldTitle:this.nls.reportsTab.selectReportFieldTitle,nls:this.nls,appConfig:this.appConfig,retainSelectedFieldsArr:this.retainSelectedFieldsArr}),
C(this._fieldSelectorWidget,"onFieldSelectComplete",c.hitch(this,function(x){this._selectedFields=x;this._filterFieldsForReport(x)})),C(this._fieldSelectorWidget,"onCancel",c.hitch(this,function(){this._selectedFields=null!==this.retainSelectedFieldsArr?this.retainSelectedFieldsArr:this._getAllFields()})),C(this._fieldSelectorWidget,"onClose",c.hitch(this,function(){this._selectedFields=null!==this.retainSelectedFieldsArr?this.retainSelectedFieldsArr:this._getAllFields()})),this._fieldSelectorWidget.startup();
"DartTheme"===this.appConfig.theme.name&&m.add(this._fieldSelectorWidget.fieldsPopup.domNode,"esriCTDartPanel")},_getAllFields:function(){var x;var H=[];for(x in this.configuredField)this.configuredField.hasOwnProperty(x)&&(this.configuredField[x].hasOwnProperty("fieldName")&&H.push(this.configuredField[x].fieldName),this.configuredField[x].hasOwnProperty("name")&&H.push(this.configuredField[x].name));return H},getSelectedFields:function(){return m.contains(this.impactSummaryLayerField,"esriCTImpactSummaryLayerFieldIconDisabled")?
0<this._selectedFields.length?this._selectedFields:0===this._selectedFields.length&&null===this.retainSelectedFieldsArr?this._getAllFields():0===this._selectedFields.length&&0===this.retainSelectedFieldsArr.length?[]:this._getAllFields():this._isFieldsSelectorClick&&0<this._selectedFields.length?this._selectedFields:this._isFieldsSelectorClick&&0===this._selectedFields.length?[]:!this._isFieldsSelectorClick&&0<this._selectedFields.length?this._selectedFields:this._isFieldsSelectorClick||0!==this._selectedFields.length||
null!==this.retainSelectedFieldsArr?this._isFieldsSelectorClick||0!==this._selectedFields.length||0!==this.retainSelectedFieldsArr.length?this._getAllFields():[]:this._getAllFields()},_filterFieldsForReport:function(x){var H=c.clone(this.configuredField),L;for(L in this.configuredField)-1>=x.indexOf(L)&&delete H[L];this._filterPrintDataObjAccToConfiguredFields(H);(x=l(".esriCTAttrTableHighlighted",this.domNode.parentElement))&&0<x.length&&y.get(x[0],"esriCTLayerId")===this.featureLayer.id&&(m.remove(x[0],
"esriCTAttrTableHighlighted"),this.highlightGraphicsLayer.clear());this._showReport();this.emit("printDataUpdated",{id:this.id,printData:this._printData})},_showOrHideLayerDetailsContainer:function(){m.toggle(this.layerTitleAndFieldParentContainer,"esriCTBoldFont");m.toggle(this.impactSummaryLayerDetailContainer,"esriCTHidden");m.contains(this.layerSectionIcon,"esriCTLayerPanelExpand")?(m.replace(this.layerSectionIcon,"esriCTLayerPanelCollapse","esriCTLayerPanelExpand"),y.set(this.layerSectionIcon,
"aria-expanded","true")):(m.replace(this.layerSectionIcon,"esriCTLayerPanelExpand","esriCTLayerPanelCollapse"),y.set(this.layerSectionIcon,"aria-expanded","false"))},_getIntersectingFeaturesCount:function(x){var H,L;var Y=new v;if(x)if(this.isFeatureCollectionLayer){var ba=[];if(0<this.featureLayer.graphics.length)for(L=0;L<this.featureLayer.graphics.length;L++)(H=this.featureLayer.graphics[L].geometry?I.intersects(x,this.featureLayer.graphics[L].geometry):null)&&ba.push(L);Y.resolve(ba)}else{var ca;
ba=new M;H=new z(this.featureLayer.url);(ca=this.layerInfosObj.getLayerInfoById(this.featureLayer.id))&&(L=ca.getFilter()?ca.getFilter():"1\x3d1");L&&(ba.where=L);ba.geometry=x;H.executeForIds(ba,c.hitch(this,function(fa){fa&&0!==fa.length?(fa.length>this.maxFeaturesForAnalysis&&(m.remove(this.impactSummaryLayerMaxRecordHint,"esriCTHidden"),m.add(this.impactSummaryLayerTitle,"esriCTLayerTitleOverrideWidth"),this.isExceedingMaxRecordCount=!0,this.emit("exceedingMaxRecordCount")),Y.resolve(fa)):Y.resolve([])}),
c.hitch(this,function(){Y.resolve([])}))}else Y.resolve([]);return Y.promise},_getFeatureByChunks:function(x,H){var L=new v;var Y=[];var ba=this.featureLayer.maxRecordCount;if(this.isFeatureCollectionLayer)Y.push(this._getIntersectFeature(x,H));else for(;0<x.length;)Y.push(this._getIntersectFeature(x.splice(0,ba),H));aa(Y).then(c.hitch(this,function(ca){var fa=[];w.forEach(ca,c.hitch(this,function(ia){fa=fa.concat(ia)}));L.resolve(fa)}));return L.promise},_getIntersectFeature:function(x,H){var L;
var Y=new v;if(this.isFeatureCollectionLayer){var ba=[];if(0<this.featureLayer.graphics.length)for(x=0;x<this.featureLayer.graphics.length;x++)(L=this.featureLayer.graphics[x].geometry?I.intersects(H,this.featureLayer.graphics[x].geometry):null)&&ba.push(this.featureLayer.graphics[x]);Y.resolve(ba.splice(0,this.maxFeaturesForAnalysis))}else ba=new M,ba.outFields=["*"],ba.returnGeometry=!0,ba.objectIds=x,ba.outSpatialReference=H.spatialReference,H=new z(this.featureLayer.url),H.execute(ba,c.hitch(this,
function(ca){ca.features?Y.resolve(ca.features):Y.resolve([])}),c.hitch(this,function(){Y.resolve([])}));return Y.promise},_setFeatureLayerIntersectFeatureCount:function(x){this._intersectFeatureCount=E.format(x);m.remove(this.impactSummaryLayerFeatureCount,"esriCTLoadingIcon");y.set(this.impactSummaryLayerFeatureCount,"innerHTML","("+this._intersectFeatureCount+")");y.set(this.impactSummaryLayerFeatureCount,"title","("+this._intersectFeatureCount+")");this._setFeatureLayerTitle(x)},_isDonutPolygon:function(x){var H=
!1;"polygon"===x.type&&1<x.rings.length&&w.forEach(x.rings,c.hitch(this,function(L){x.isClockwise(L)||(H=!0)}));return H},_getCutOrWithInFeatures:function(x,H,L){var Y=[];for(var ba=0;ba<x.length;ba++)for(var ca=0;ca<H.length;ca++){var fa=I.cut(H[ca].geometry,x[ba]);0<fa.length?Y=this._getWithinFeature({cutFeatureArr:fa,bufferGeometry:L,featureIntersectResultArr:Y,intersectFeatureArr:H,index:ca}):(I.within(H[ca].geometry,L)?fa=new q(H[ca].geometry,null,H[ca].attributes):(fa=I.intersect(H[ca].geometry,
L),fa=new q(fa,null,H[ca].attributes,null)),Y.push(fa))}return Y},_getWithinFeature:function(x){var H;var L=x.cutFeatureArr;var Y=x.bufferGeometry;var ba=x.intersectFeatureArr;var ca=x.featureIntersectResultArr;var fa=x.index;w.forEach(L,c.hitch(this,function(ia){I.within(ia,Y)&&(H=new q(ia,null,ba[fa].attributes),ca.push(H))}));return ca},_polygonToPolyline:function(x){var H,L;var Y=[];var ba=new e(new b({wkid:102100}));for(L=0;L<x.rings.length;L++){var ca=[];for(H=0;H<x.rings[L].length;H++)ca.push(x.rings[L][H]);
ba.addPath(ca)}Y.push(ba);return Y},_updateFormattedAttribute:function(x){var H=new v,L=[],Y=null;if(!this.isFeatureCollectionLayer){var ba=this.layerInfosObj.getLayerInfoById(this.featureLayer.id);Y=ba.originOperLayer.popupInfo;!Y&&ba&&ba.getPopupInfo&&ba.getPopupInfo()&&(Y=ba.getPopupInfo())}if(Y&&Y.expressionInfos&&0<Y.expressionInfos.length){var ca=this.parseArcadeExpressions(Y.expressionInfos);w.forEach(x,c.hitch(this,function(fa){L.push(this.combineFeatureAttributesAndExpressionResolutions(fa,
ba,Y.expressionInfos,ca))}))}aa(L).then(c.hitch(this,function(fa){w.forEach(x,c.hitch(this,function(ia,ka){var f;-1===this.intersectingFeatureIds.indexOf(ia.attributes[this.featureLayer.objectIdField])&&(f=!0);var J=fa&&0<fa.length&&fa[ka]?c.clone(fa[ka]):c.clone(ia.attributes);J=this._getFormatedAttrs(J,this.featureLayer.fields,Y);x[ka].setAttributes(J);w.forEach(this.featureLayer.fields,c.hitch(this,function(P){x[ka].attributes.hasOwnProperty(P.name)||(x[ka].attributes[P.name]=this.nls.reportsTab.noDataText);
if(x[ka].attributes.hasOwnProperty(P.name)){var N=x[ka].attributes[P.name];void 0===N||""===N||null===N?x[ka].attributes[P.name]=this.nls.reportsTab.noDataText:""===c.trim(N.toString())&&(x[ka].attributes[P.name]=this.nls.reportsTab.noDataText)}}));if(f&&"esriGeometryPolygon"===this.featureLayer.geometryType)this._squareFeetUnitData.push(0),this._acresUnitData.push(0),this._squareMetersUnitData.push(0),this._squareKilometersUnitData.push(0),this._squareMilesUnitData.push(0),this._hectaresUnitData.push(0);
else if(f&&"esriGeometryPolyline"===this.featureLayer.geometryType)this._feetUnitData.push(0),this._milesUnitData.push(0),this._metersUnitData.push(0),this._kilometersUnitData.push(0);else switch(this.featureLayer.geometryType){case "esriGeometryPolygon":ia=Q.getAreaOfGeometry(ia.geometry);this._squareFeetUnitData.push(ia.squareFeet);this._acresUnitData.push(ia.acres);this._squareMetersUnitData.push(ia.squareMeters);this._squareKilometersUnitData.push(ia.squareKilometer);this._squareMilesUnitData.push(ia.squareMiles);
this._hectaresUnitData.push(ia.hectares);break;case "esriGeometryPolyline":ia=Q.getLengthOfGeometry(ia.geometry),this._feetUnitData.push(ia.feet),this._milesUnitData.push(ia.miles),this._metersUnitData.push(ia.meters),this._kilometersUnitData.push(ia.kilometers)}}));H.resolve(x)}));return H},_getFieldText:function(x,H){return x.label?x.label:x.alias?x.alias:H},_createLayerDetails:function(x,H){var L,Y,ba,ca,fa;var ia=Object.keys(this.configuredField).length;var ka=new v;this._updateFormattedAttribute(x).then(c.hitch(this,
function(f){x=f;this._pushDataInPrintDataObj(this.configuredLayerLabel,null,null);for(fa in this.configuredField)for(ba=this.configuredField[fa],ca=this._getFieldText(ba,fa),this._printCompleteData.cols.push(ca),L=0;L<x.length;L++)switch((Y=x[L].attributes[fa])||0===Y?this._pushDataInPrintDataObj(null,L,Y):this._pushDataInPrintDataObj(null,L,""),H){case "esriGeometryPolyline":this._printCompleteData.cols.length===ia&&(this._feetUnitInfo.push(this._feetUnitData[L]),this._milesUnitInfo.push(this._milesUnitData[L]),
this._metersUnitInfo.push(this._metersUnitData[L]),this._kilometersUnitInfo.push(this._kilometersUnitData[L]));break;case "esriGeometryPolygon":this._printCompleteData.cols.length===ia&&(this._squareFeetUnitInfo.push(this._squareFeetUnitData[L]),this._acresUnitInfo.push(this._acresUnitData[L]),this._squareMetersUnitInfo.push(this._squareMetersUnitData[L]),this._squareKilometersUnitInfo.push(this._squareKilometersUnitData[L]),this._squareMilesUnitInfo.push(this._squareMilesUnitData[L]),this._hectaresUnitInfo.push(this._hectaresUnitData[L]));
break;case "esriGeometryPoint":this._printCompleteData.cols.length===ia&&this._countUnitInfo.push(1)}ka.resolve()}));return ka.promise},_pushDataInPrintDataObj:function(x,H,L){x?(this._printCompleteData={},this._feetUnitInfo=[],this._squareFeetUnitInfo=[],this._countUnitInfo=[],this._milesUnitInfo=[],this._acresUnitInfo=[],this._metersUnitInfo=[],this._squareMetersUnitInfo=[],this._kilometersUnitInfo=[],this.squareKilometersUnitInfo=[],this.squareMilesUnitInfo=[],this._hectaresUnitInfo=[],this._printCompleteData.title=
x,this._printCompleteData.rows=[],this._printCompleteData.cols=[]):(L===this.nls.reportsTab.noDataText&&(L="\x3ci\x3e"+L+"\x3c/i\x3e"),this._printCompleteData.rows[H]||this._printCompleteData.rows.push([]),this._printCompleteData.rows[H].push(L))},_filterPrintDataObjAccToConfiguredFields:function(x){var H,L;this._printData={};this._printData=c.clone(this._printCompleteData);for(H=this._printData.cols.length-1;0<=H;--H){var Y=!1;for(L in x)switch(this._printData.cols[H]){case x[L].label:Y=!0;break;
case x[L].alias:Y=!0;break;case L:Y=!0}if(!Y)for(this._printData.cols.splice(H,1),Y=0;Y<this._printData.rows.length;Y++)this._printData.rows[Y].splice(H,1)}},_getFormatedAttrs:function(x,H,L){function Y(fa){if(L&&G.isDefined(L.fieldInfos))for(var ia=0,ka=L.fieldInfos.length;ia<ka;ia++){var f=L.fieldInfos[ia];if(f.fieldName===fa)return f.format}return null}var ba=[null,void 0,""],ca={};w.forEach(H,c.hitch(this,function(fa,ia){if(-1===ba.indexOf(x[fa.name])){var ka="esriFieldTypeDate"===fa.type,f=fa.name;
if("esriFieldTypeDate"===H[ia].type)ca[f]=F.fieldFormatter.getFormattedDate(x[fa.name],Y(fa.name));else if("esriFieldTypeDouble"===H[ia].type||"esriFieldTypeSingle"===H[ia].type||"esriFieldTypeInteger"===H[ia].type||"esriFieldTypeSmallInteger"===H[ia].type)ca[f]=this._getFormattedNumber(x[fa.name],Y(fa.name));ka||(ca[f]=f in ca?ca[f]:x[fa.name],(fa=F.getDisplayValueForCodedValueOrSubtype(this._layerDefinition,fa.name,x))&&fa.isCodedValueOrSubtype&&fa.hasOwnProperty("displayValue")&&-1===ba.indexOf(fa.displayValue)&&
(fa=fa.displayValue,ca[f]=fa||isFinite(fa)?fa:""))}}));L&&L.expressionInfos&&w.forEach(L.expressionInfos,c.hitch(this,function(fa,ia){ia="expression/"+fa.name;-1===ba.indexOf(x[ia])&&("date"===fa.returnType?ca[ia]=F.fieldFormatter.getFormattedDate(x[ia],Y(ia)):"number"===fa.returnType?ca[ia]=this._getFormattedNumber(Number(x[ia]),Y(ia)):"string"===fa.returnType&&(ca[ia]=x[ia]))}));return ca},_getFormattedNumber:function(x,H){if("number"===typeof x){var L=(x.toString().split(".")[1]||"").length;return(x=
F.localizeNumberByFieldInfo(x,{format:{places:H&&"number"===typeof H.places?parseInt(H.places,10):L,digitSeparator:H&&H.digitSeparator}}))||""}return x},_getArrayIndex:function(x,H){var L,Y,ba=[];for(L=0;L<x.length;++L)if(H.length===x[L].length){var ca=x[L];for(Y=0;Y<H.length&&H[Y]===ca[Y];)++Y;Y===H.length&&ba.push(L)}return ba},getSum:function(x,H){x=(H&&0<H.length?w.filter(x,function(L,Y){return-1<H.indexOf(Y)}):x).reduce(function(L,Y){return L+Y},0);return.01<x?S.honourPopupRounding(2,x):x},_getAggregatedColTitle:function(x){switch(x){case "esriGeometryPoint":var H=
this.nls.reportsTab.featureCountText;break;case "esriGeometryPolyline":H=this.nls.reportsTab.featureLengthText;break;case "esriGeometryPolygon":H=this.nls.reportsTab.featureAreaText}return H},_getUnitsForGeometry:function(x,H){switch(x){case "esriGeometryPoint":var L="";break;case "esriGeometryPolyline":L=this._getAnalysisUnitForGeometry(H,x);break;case "esriGeometryPolygon":L=this._getAnalysisUnitForGeometry(H,x)}return L},_getAnalysisUnitForGeometry:function(x,H){switch(x){case "Feet":case "SquareFeet":var L=
"esriGeometryPolygon"===H?this.nls.units.feetAbbr+"\x26sup2":this.nls.units.feetAbbr;break;case "Miles":case "Acres":L="esriGeometryPolygon"===H?this.nls.units.acresAbbr:this.nls.units.milesAbbr;break;case "Meters":case "SquareMeters":L="esriGeometryPolygon"===H?this.nls.units.metersAbbr+"\x26sup2":this.nls.units.metersAbbr;break;case "Kilometers":case "SquareKilometers":L="esriGeometryPolygon"===H?this.nls.units.kilometersAbbr+"\x26sup2":this.nls.units.kilometersAbbr;break;case "Hectares":L="esriGeometryPolygon"===
H?this.nls.reportsTab.hectaresAbbr:this.nls.units.kilometersAbbr;break;case "SquareMiles":L="esriGeometryPolygon"===H?this.nls.units.milesAbbr+"\x26sup2":this.nls.units.milesAbbr}return L},_showMessage:function(x){K.empty(this.impactSummaryLayerDetails);y.set(this.impactSummaryLayerDetailsMsg,"innerHTML",x);m.add(this.impactSummaryLayerDetailsMsg,"esriCTLayerDetailCenterText")},_showReport:function(){var x,H,L=[];var Y=this._printData;K.empty(this.impactSummaryLayerDetails);if(!Y.cols.length&&0<Y.rows.length)this._showMessage(this.nls.reportsTab.noFieldsSelected);
else if(Y.rows&&0<Y.rows.length){y.set(this.impactSummaryLayerDetailsMsg,"innerHTML","");m.remove(this.impactSummaryLayerDetailsMsg,"esriCTLayerDetailCenterText");var ba=[];var ca={};for(H=0;H<Y.rows.length;H++)if(this.groupbyfieldCheckBoxStatus){if(0>ba.indexOf(H)){var fa=this._getArrayIndex(Y.rows,Y.rows[H]);ca[H]=fa;ba=ba.concat(fa)}if(ba.length===Y.rows.length)break}else fa=[],fa.push(H),ca[H]=fa;ba={rows:[],cols:c.clone(Y.cols)};H=this._getAggregatedColTitle(this.featureLayer.geometryType);"esriGeometryPoint"===
this.featureLayer.geometryType?ba.cols.push(H):"esriGeometryPolyline"===this.featureLayer.geometryType?(ba.cols.push(H),ba.cols.push(H),ba.cols.push(H),ba.cols.push(H)):"esriGeometryPolygon"===this.featureLayer.geometryType&&(ba.cols.push(H),ba.cols.push(H),ba.cols.push(H),ba.cols.push(H),ba.cols.push(H),ba.cols.push(H));for(x in ca){H=c.clone(Y.rows[parseInt(x,10)]);if("esriGeometryPolyline"===this.featureLayer.geometryType){H.push(this.getSum(this._feetUnitInfo,ca[parseInt(x,10)]));H.push(this.getSum(this._milesUnitInfo,
ca[parseInt(x,10)]));H.push(this.getSum(this._metersUnitInfo,ca[parseInt(x,10)]));var ia=this.getSum(this._kilometersUnitInfo,ca[parseInt(x,10)]);H.push(ia)}else if("esriGeometryPolygon"===this.featureLayer.geometryType){H.push(this.getSum(this._squareFeetUnitInfo,ca[parseInt(x,10)]));H.push(this.getSum(this._acresUnitInfo,ca[parseInt(x,10)]));H.push(this.getSum(this._squareMetersUnitInfo,ca[parseInt(x,10)]));H.push(this.getSum(this._squareKilometersUnitInfo,ca[parseInt(x,10)]));var ka=this.getSum(this._hectaresUnitInfo,
ca[parseInt(x,10)]);H.push(ka);H.push(this.getSum(this._squareMilesUnitInfo,ca[parseInt(x,10)]))}else if("esriGeometryPoint"===this.featureLayer.geometryType){var f=this.getSum(this._countUnitInfo,ca[parseInt(x,10)]);H.push(f)}ba.rows.push(H);this._featureIntersectResultArr&&("esriGeometryPolyline"===this.featureLayer.geometryType?L.push({features:this._getAggregatedFeatures(ca[x]),sortValue:ia}):"esriGeometryPolygon"===this.featureLayer.geometryType?L.push({features:this._getAggregatedFeatures(ca[x]),
sortValue:ka}):"esriGeometryPoint"===this.featureLayer.geometryType&&L.push({features:this._getAggregatedFeatures(ca[x]),sortValue:f}))}this._renderReport(ba,L)}},_getAggregatedFeatures:function(x){var H=[];w.forEach(x,c.hitch(this,function(L){H.push(this._featureIntersectResultArr[L])}));return H},_sortFeatureArray:function(x,H){var L=x.length-1;return x[L]<H[L]?1:x[L]>H[L]?-1:0},_sortArrayByKey:function(x,H){return x.sortValue<H.sortValue?1:x.sortValue>H.sortValue?-1:0},_createTemplateNode:function(){var x=
K.create("div",{"class":"esriCTImpactSummaryLayerDetailMainNode",tabindex:0,role:"presentation"},this.impactSummaryLayerDetails);var H=K.create("table",{"class":"esriCTAttrTable esriCTCursorPointer",cellpadding:"0px",cellspacing:"0px"},x);K.create("div",{"class":"esriCTInfoDataSeparator"},this.impactSummaryLayerDetails);this.own(C(H,"click",c.hitch(this,function(L){this._highlightSelection(L.currentTarget)})));this.own(C(x,"keydown",c.hitch(this,function(L){L.keyCode!==W.ENTER&&L.keyCode!==W.SPACE||
this._highlightSelection(L.currentTarget.children[0])})));return H},_renderReport:function(x,H){x.rows&&0<x.rows.length&&(x.rows=x.rows.sort(this._sortFeatureArray),this._aggregatedFeatureGeometries=H=H.sort(this._sortArrayByKey),w.forEach(x.rows,c.hitch(this,function(L,Y){var ba;var ca=this._createTemplateNode();y.set(ca,"esriCTTableIndex",Y);y.set(ca,"esriCTLayerId",this.featureLayer.id);w.forEach(L,c.hitch(this,function(fa,ia){ba=K.create("tr",{valign:"top"},ca);var ka=K.create("td",{"class":"esriCTAttrName"},
ba);var f=K.create("td",{"class":"esriCTAttrValue"},ba);var J=F.fieldFormatter.getFormattedUrl(fa);fa=x.cols[ia]+": ";var P=J;switch(this.featureLayer.geometryType){case "esriGeometryPoint":var N=1;break;case "esriGeometryPolyline":N=4;break;case "esriGeometryPolygon":N=6}if(ia>=L.length-N){ia-=L.length-N;.01<=J?(J="esriGeometryPoint"!==this.featureLayer.geometryType?E.format(J,{places:2}):E.format(J),"esriGeometryPolyline"===this.featureLayer.geometryType?P=fa+J+" "+this._getUnitsForGeometry(this.featureLayer.geometryType,
this._lengthAnalysisUnitsArray[ia]):"esriGeometryPolygon"===this.featureLayer.geometryType?P=fa+J+" "+this._getUnitsForGeometry(this.featureLayer.geometryType,this._areaAnalysisUnitsArray[ia]):"esriGeometryPoint"===this.featureLayer.geometryType&&(P=fa+J+" "+this._getUnitsForGeometry(this.featureLayer.geometryType,null))):.01>J&&0!==J?"esriGeometryPolyline"===this.featureLayer.geometryType?P=fa+"  \x3c "+E.format(.01)+" "+this._getUnitsForGeometry(this.featureLayer.geometryType,this._lengthAnalysisUnitsArray[ia]):
"esriGeometryPolygon"===this.featureLayer.geometryType?P=fa+"  \x3c "+E.format(.01)+" "+this._getUnitsForGeometry(this.featureLayer.geometryType,this._areaAnalysisUnitsArray[ia]):"esriGeometryPoint"===this.featureLayer.geometryType&&(P=fa+"  \x3c "+E.format(.01)+" "+this._getUnitsForGeometry(this.featureLayer.geometryType,null)):P=fa+" "+this.nls.reportsTab.notApplicableText;fa="";m.add(ka,"esriCTReportsTabInfoData");J="esriGeometryPolyline"===this.featureLayer.geometryType?"esriCTFieldDistinct"+
this._lengthAnalysisUnitsArray[ia]+"UnitData":"esriCTFieldDistinct"+this._areaAnalysisUnitsArray[ia]+"UnitData";m.add(f,"esriCTInfoDataMeasurement esriCTReportsTabInfoData");if("esriGeometryPolyline"===this.featureLayer.geometryType){switch(this._lengthAnalysisUnitsArray[ia]){case "Feet":case "Miles":case "Meters":case "Kilometers":m.add(f,J),m.add(f,"esriCTEsriGeometryPolyline")}this.config.lengthUnits!==this._lengthAnalysisUnitsArray[ia]&&m.add(f,"esriCTHidden")}if("esriGeometryPolygon"===this.featureLayer.geometryType){switch(this._areaAnalysisUnitsArray[ia]){case "SquareFeet":case "Acres":case "SquareMeters":case "SquareKilometers":case "Hectares":case "SquareMiles":m.add(f,
J),m.add(f,"esriCTEsriGeometryPolygon")}this.config.areaUnits!==this._areaAnalysisUnitsArray[ia]&&m.add(f,"esriCTHidden")}}y.set(ka,"innerHTML",fa);y.set(f,"innerHTML",P)}))})))},_getUniqueIds:function(x,H){if(0===x.length)return H;if(0===H.length)return x;w.forEach(x,c.hitch(this,function(L){L=H.indexOf(L);-1!==L&&H.splice(L,1)}));return x.concat(H)},_highlightSelection:function(x){var H;m.contains(x,"esriCTAttrTableHighlighted")?(m.remove(x,"esriCTAttrTableHighlighted"),this.highlightGraphicsLayer.clear()):
((H=l(".esriCTAttrTableHighlighted",this.domNode.parentElement))&&0<H.length&&m.remove(H[0],"esriCTAttrTableHighlighted"),this.highlightGraphicsLayer.clear(),m.add(x,"esriCTAttrTableHighlighted"),x=y.get(x,"esriCTTableIndex"),x=this._aggregatedFeatureGeometries[parseInt(x,10)].features,w.forEach(x,c.hitch(this,function(L){L=U.getHighLightSymbol(L,this.featureLayer);this.highlightGraphicsLayer.add(L)})))},_attachEventToNodes:function(){var x=this.own(C.pausable(this.layerTitleAndFieldParentContainer,
"keydown",c.hitch(this,function(H){if(H.keyCode===W.ENTER||H.keyCode===W.SPACE)h.stop(H),this._setFocus(),x[0].pause()})));this.own(C(this.layerSectionIcon,"keydown",c.hitch(this,function(H){if(H.keyCode===W.ENTER||H.keyCode===W.SPACE)h.stop(H),m.contains(this.layerTitleAndFieldParentContainer,"esriCTImpactSummaryLayerFieldIcon")?m.contains(this.impactSummaryLayerField,"esriCTImpactSummaryLayerFieldIconDisabled")||this._createFieldSelectorPopupWidget():m.contains(this.layerTitleAndFieldParentContainer,
"esriCTLayerSectionDisabled")||this._showOrHideLayerDetailsContainer();H.keyCode===W.ESCAPE&&(h.stop(H),this._removeFocus(),x[0].resume())})));this.own(C(this.impactSummaryLayerField,"keydown",c.hitch(this,function(H){if(H.keyCode===W.ENTER||H.keyCode===W.SPACE)h.stop(H),m.contains(H.target,"esriCTImpactSummaryLayerFieldIconDisabled")||this._createFieldSelectorPopupWidget();H.keyCode===W.ESCAPE&&(h.stop(H),this._removeFocus(),x[0].resume())})));this.own(C(this.impactSummaryLayerMaxRecordHint,"keydown",
c.hitch(this,function(H){if(H.keyCode===W.ENTER||H.keyCode===W.SPACE)h.stop(H),this.isExceedingMaxRecordCount?this.emit("showMessage",this.nls.reportsTab.unableToAnalyzeText):this.emit("showMessage",this.nls.reportsTab.layerNotVisibleText);H.keyCode===W.ESCAPE&&(h.stop(H),this._removeFocus(),x[0].resume())})))},_removeFocus:function(){this._restrictFocus();this.emit("initializeAccessibility");this._focusOutCurrentNode();da.focus(this.layerTitleAndFieldParentContainer)},_setFocus:function(){this._allowFocus();
this._setFirstFocusNode();this._setLastFocusNode();this._setFocusOnFirstNode()},_restrictFocus:function(){y.set(this.layerSectionIcon,"tabindex","-1");y.set(this.impactSummaryLayerMaxRecordHint,"tabindex","-1");y.set(this.impactSummaryLayerField,"tabindex","-1")},_allowFocus:function(){y.set(this.layerSectionIcon,"tabindex","1");m.contains(this.impactSummaryLayerMaxRecordHint,"esriCTHidden")||y.set(this.impactSummaryLayerMaxRecordHint,"tabindex","1");m.contains(this.impactSummaryLayerField,"esriCTImpactSummaryLayerFieldIconDisabled")||
y.set(this.impactSummaryLayerField,"tabindex","1")},_setFirstFocusNode:function(){F.initFirstFocusNode(this.domNodeObj,this.layerSectionIcon)},_setLastFocusNode:function(){m.contains(this.impactSummaryLayerField,"esriCTImpactSummaryLayerFieldIconDisabled")?m.contains(this.impactSummaryLayerMaxRecordHint,"esriCTHidden")?F.initLastFocusNode(this.domNodeObj,this.layerSectionIcon):F.initLastFocusNode(this.domNodeObj,this.impactSummaryLayerMaxRecordHint):F.initLastFocusNode(this.domNodeObj,this.impactSummaryLayerField)},
_focusOutCurrentNode:function(){da.curNode&&da.curNode.blur()},_setFocusOnFirstNode:function(){this._focusOutCurrentNode();da.focus(this.layerSectionIcon)},parseArcadeExpressions:function(x){if(Array.isArray(x)&&0<x.length){var H={};w.forEach(x,function(L){H[L.name]=T.parseScript(L.expression)})}return H},initArcadeContext:function(x,H,L){var Y=null,ba=null;this.map&&(Y=this.map);H&&H.layerObject&&(H=H.layerObject);x&&x.geometry&&x.geometry.spatialReference&&(ba=x.geometry.spatialReference);return this.getEvalOptions({expression:L,
feature:x,layer:H,map:Y,sr:ba}).context},getEvalOptions:function(x){var H=x.feature,L=x.layer,Y=x.map;x=x.spatialReference;H=H?r.createFromGraphicLikeObject(H.geometry,H.attributes,L):null;if(L){var ba={spatialReference:x};var ca=L.getMap()?u.createFeatureSetFromLayer(L,ba):u.createFeatureSetFromLayerUrl(L.url,ba);ba=(L=A.getServiceUrl(L.url))?u.createFeatureSetCollectionFromServiceUrl(L,ba):null}Y=Y?u.createFeatureSetCollectionFromMap(Y):null;return{context:{vars:{$feature:H,$layer:ca,$datastore:ba,
$map:Y},spatialReference:x}}},combineFeatureAttributesAndExpressionResolutions:function(x,H,L,Y){var ba=new v,ca=[],fa;var ia=c.mixin({},x.attributes);if(Y){x=this.initArcadeContext(x,H,L,Y);for(fa in Y)ca.push(this.executeArcadeExpression(fa,Y[fa],x,ia));aa(ca).then(function(){ba.resolve(ia)})}else ba.resolve(ia);return ba.promise},executeArcadeExpression:function(x,H,L,Y){var ba=new v;(H=T.executeScript(H,L))&&H.then?H.then(function(ca){Y["expression/"+x]=ca?ca.toString():"";ba.resolve(ca)},function(ca){Y["expression/"+
x]=ca?ca.toString():"";ba.resolve(ca)}):(Y["expression/"+x]=H?H.toString():"",ba.resolve(H));return ba.promise}})})},"widgets/Screening/highlightSymbolUtils":function(){define("dojo/_base/lang dojo/_base/array esri/geometry/Point esri/geometry/Polygon esri/geometry/Polyline esri/graphic esri/symbols/SimpleMarkerSymbol esri/symbols/SimpleLineSymbol esri/symbols/SimpleFillSymbol esri/Color".split(" "),function(D,a,d,c,w,n,B,C,m,y){var I={getHighLightSymbol:function(e,b){switch(e.geometry.type){case "point":return I._getPointSymbol(e,
b);case "polyline":return I._getPolyLineSymbol(e,b);case "polygon":return I._getPolygonSymbol(e,b)}},_getSizeInfo:function(e){var b=null;e.renderer.visualVariables&&a.forEach(e.renderer.visualVariables,D.hitch(this,function(q){"sizeInfo"===q.type&&(b=q)}));return b},_getPointSymbol:function(e,b){var q,K;var M=!1;var z=new B(B.STYLE_SQUARE,null,new C(C.STYLE_SOLID,new y([0,255,255,1]),3));z.setColor(null);z.size=30;if(b&&b.renderer)if(b.renderer.symbol)M=!0,z=I._updatePointSymbolProperties(z,b.renderer.symbol);
else if(b.renderer.infos&&0<b.renderer.infos.length){for(K=0;K<b.renderer.infos.length;K++){b.typeIdField?q=e.attributes[b.typeIdField]:b.renderer.attributeField&&(q=e.attributes[b.renderer.attributeField]);var v=b.renderer.infos[K].value;void 0!==q&&null!==q&&""!==q&&void 0!==v&&null!==v&&""!==v&&q.toString()===v.toString()&&(M=!0,z=I._updatePointSymbolProperties(z,b.renderer.infos[K].symbol))}!M&&b.renderer.defaultSymbol&&(M=!0,z=I._updatePointSymbolProperties(z,b.renderer.defaultSymbol))}b&&b.graphics&&
0<b.graphics.length&&b._getSymbol(e)&&((q=e.getShape())&&q.shape?q.shape.hasOwnProperty("r")?(M=!0,z.size=2*q.shape.r+10):q.shape.hasOwnProperty("width")&&(M=!0,b.renderer&&b.renderer.infos&&0<b.renderer.infos.length&&(z=I._updatePointSymbolProperties(z,b.renderer.infos[0].symbol)),z.size=q.shape.width+10):b.renderer.visualVariables&&(M=b._getRenderer(e),q=I._getSizeInfo(b))&&(b=M.getSize(e,{sizeInfo:q,shape:b._getSymbol(e),resolution:b&&b.getResolutionInMeters&&b.getResolutionInMeters()}),null!==
b&&(z.size=b+10)));b=new d(e.geometry.x,e.geometry.y,e.geometry.spatialReference);return new n(b,z,e.attributes)},_updatePointSymbolProperties:function(e,b){if(b.hasOwnProperty("height")&&b.hasOwnProperty("width")){var q=b.height;var K=b.width;q=(q>K?q:K)+10;e.size=q}b.hasOwnProperty("size")&&(!q||q<b.size)&&(e.size=b.size+10);b.hasOwnProperty("xoffset")&&(e.xoffset=b.xoffset);b.hasOwnProperty("yoffset")&&(e.yoffset=b.yoffset);return e},_getPolyLineSymbol:function(e,b){var q,K;var M=5;if(b&&b.renderer)if(b.renderer.symbol&&
b.renderer.symbol.hasOwnProperty("width"))M=b.renderer.symbol.width;else if(b.renderer.infos&&0<b.renderer.infos.length)for(K=0;K<b.renderer.infos.length;K++){b.typeIdField?q=e.attributes[b.typeIdField]:b.renderer.attributeField&&(q=e.attributes[b.renderer.attributeField]);var z=b.renderer.infos[K].value;void 0!==q&&null!==q&&""!==q&&void 0!==z&&null!==z&&""!==z&&q.toString()===z.toString()&&b.renderer.infos[K].symbol.hasOwnProperty("width")&&(M=b.renderer.infos[K].symbol.width)}else b.renderer.defaultSymbol&&
b.renderer.defaultSymbol.hasOwnProperty("width")&&(M=b.renderer.defaultSymbol.width);b=new C(C.STYLE_SOLID,new y([0,255,255,1]),M);M=new w(e.geometry.spatialReference);e.geometry.paths&&0<e.geometry.paths.length&&M.addPath(e.geometry.paths[0]);return new n(M,b,e.attributes)},_getPolygonSymbol:function(e){var b=new m(m.STYLE_SOLID,new C(C.STYLE_SOLID,new y([0,255,255,1]),4),new y([0,0,0,0]));var q=new c(e.geometry.spatialReference);e.geometry.rings&&(q.rings=D.clone(e.geometry.rings));return new n(q,
b,e.attributes)}};return I})},"widgets/Screening/fieldSelectorPopup/fieldSelectorPopup":function(){define("dojo/_base/declare dijit/_WidgetBase dojo/_base/lang dojo/Evented dojo/dom-construct dojo/_base/html dojo/_base/array dojo/query dojo/on dojo/dom-style jimu/dijit/Popup jimu/dijit/CheckBox dojo/NodeList-data".split(" "),function(D,a,d,c,w,n,B,C,m,y,I,e){return D([a,c],{baseClass:"jimu-widget-screening",selectedFields:[],fieldsPopup:null,_selectAllCheckBox:null,_selectAllCheckBoxHandle:null,_fieldsCheckBoxChangeHandle:[],
constructor:function(b){this.selectedFields=[];this._selectAllCheckBoxHandle=this._selectAllCheckBox=this.fieldsPopup=null;this._fieldsCheckBoxChangeHandle=[];d.mixin(this,b)},startup:function(){this._populateConfiguredFields();this._populateSelectedFields();this.onFieldsSelectorClick();m(window,"resize",d.hitch(this,function(){this._setFieldPopupDimensions()}))},_populateConfiguredFields:function(){for(var b in this.outFields)this.selectedFields.push(b)},_populateSelectedFields:function(){null!==
this.retainSelectedFieldsArr&&(this.selectedFields=this.retainSelectedFieldsArr)},_resetSelectAllCheckboxStatus:function(){var b=!0;this._fieldsCheckBox.forEach(function(q){q.checked||(b=!1)});b?(this._selectAllCheckBoxHandle[0].pause(),this._selectAllCheckBox.check()):(this._selectAllCheckBoxHandle[0].pause(),this._selectAllCheckBox.uncheck(!0));this._selectAllCheckBoxHandle[0].resume()},_attachFieldCheckBoxChangeEvent:function(b){this._fieldsCheckBoxChangeHandle.push(this.own(m.pausable(b,"change",
d.hitch(this,function(){this._resetSelectAllCheckboxStatus()}))))},_pauseFieldCheckBoxEvent:function(){this._fieldsCheckBoxChangeHandle.forEach(function(b){b[0].pause()})},_resumeFieldCheckBoxEvent:function(){this._fieldsCheckBoxChangeHandle.forEach(function(b){b[0].resume()})},onFieldsSelectorClick:function(){var b,q=0;var K=n.create("div",{});w.create("div",{"class":"esriCTSelectFieldReportLabel","aria-label":this.fieldTitle,tabindex:"0",role:"presentation",innerHTML:this.fieldTitle},K);var M=w.create("div",
{"class":"esriCTSelectAllReportLabel"},K);this._selectAllCheckBox=new e({checked:!1,label:this.nls.reportsTab.selectAllLabel});this._selectAllCheckBoxHandle=this.own(m.pausable(this._selectAllCheckBox,"change",d.hitch(this,function(v){this._pauseFieldCheckBoxEvent();v?this._fieldsCheckBox.forEach(function(Q){Q.check()}):this._fieldsCheckBox.forEach(function(Q){Q.uncheck(!0)});this._resumeFieldCheckBoxEvent()})));this._selectAllCheckBox.placeAt(M);M=n.create("div",{"class":"esriCTSelectFieldParentContainer",
style:{maxHeight:"350px"}},K);this._fieldsCheckBox=[];for(b in this.outFields){var z=new e({checked:this._isSearchable(this.outFields[b]),label:this.outFields[b].label||this.outFields[b].alias||b});this._attachFieldCheckBoxChangeEvent(z);n.addClass(z.domNode,"esriCTLayerFieldCheckbox");n.addClass(z.labelNode,"jimu-ellipsis");n.setAttr(z.domNode,{title:this.outFields[b].label||this.outFields[b].alias||b});"DartTheme"===this.appConfig.theme.name&&y.set(z.domNode.children[0],"backgroundColor","#4c4c4c");
0===q%3&&(window.isRTL?n.setStyle(z.domNode,"marginRight",0):n.setStyle(z.domNode,"marginLeft",0));z.placeAt(M);C(z.domNode).data("fieldName",b);this._fieldsCheckBox.push(z);q++}this.fieldsPopup=new I({titleLabel:this.popupTitle,autoHeight:!0,content:K,container:window.jimuConfig.layoutId,width:640,maxHeight:600,buttons:[{label:this.nls.common.ok,onClick:d.hitch(this,"_onSearchFieldsOk")},{label:this.nls.common.cancel,onClick:d.hitch(this,"_onCancelClick")}],onClose:d.hitch(this,function(){this.fieldsPopup=
null;this.emit("onClose")})});n.addClass(this.fieldsPopup.domNode,this.appConfig.theme.name+"  "+this.baseClass);this._setFieldPopupDimensions();this._resetSelectAllCheckboxStatus()},_setFieldPopupDimensions:function(){this.fieldsPopup&&(window.appInfo.isRunInMobile?(this.fieldsPopup.set("width",window.innerWidth-100),C(".esriCTLayerFieldCheckbox").addClass("esriCTLayerFieldWithoutMargin"),y.set(C(".esriCTSelectFieldParentContainer")[0],"height","200px")):(this.fieldsPopup.set("width",640),this.fieldsPopup.set("maxHeight",
600),C(".esriCTLayerFieldCheckbox").removeClass("esriCTLayerFieldWithoutMargin")))},_isSearchable:function(b){return B.some(this.selectedFields,d.hitch(this,function(q){return b.hasOwnProperty("name")?b.name===q:b.hasOwnProperty("fieldName")?b.fieldName===q:!1}))},_onSearchFieldsOk:function(){var b=[];B.forEach(this._fieldsCheckBox,function(q){if(q.getValue()){var K=C(q.domNode).data("fieldName");b.push(K[0]);C(q.domNode).removeData()}});this.setSearchFields(b);this.fieldsPopup.close();this.emit("onFieldSelectComplete",
this.selectedFields)},_onCancelClick:function(){this.fieldsPopup.close();this.emit("onCancel")},_getSearchFields:function(){return this.selectedFields},setSearchFields:function(b){this.selectedFields=b}})})},"dojo/NodeList-data":function(){define(["./_base/kernel","./query","./_base/lang","./_base/array","./dom-attr"],function(D,a,d,c,w){var n=a.NodeList,B={},C=0,m=function(e){var b=w.get(e,"data-dojo-dataid");b||(b="pid"+C++,w.set(e,"data-dojo-dataid",b));return b},y=D._nodeData=function(e,b,q){var K=
m(e),M;B[K]||(B[K]={});if(1==arguments.length)return B[K];"string"==typeof b?2<arguments.length?B[K][b]=q:M=B[K][b]:M=d.mixin(B[K],b);return M},I=D._removeNodeData=function(e,b){e=m(e);B[e]&&(b?delete B[e][b]:delete B[e])};n._gcNodeData=D._gcNodeData=function(){var e=a("[data-dojo-dataid]").map(m),b;for(b in B)0>c.indexOf(e,b)&&delete B[b]};d.extend(n,{data:n._adaptWithCondition(y,function(e){return 0===e.length||1==e.length&&"string"==typeof e[0]}),removeData:n._adaptAsForEach(I)});return n})},"esri/arcadeProfiles/fieldCalculateProfile":function(){define("dojo/_base/declare dojo/_base/lang dojo/has ../kernel ../promiseList ../arcade/Feature ../arcade/featureset/support/RecentlyUsedCache ../support/expressionUtils ./utils".split(" "),
function(D,a,d,c,w,n,B,C,m){D=new (D(null,{declaredClass:"esri.arcadeProfiles.FieldCalculateProfile",defaults:{globals:{featureSet:["$layer","$datastore"],async:["$layer","$datastore"]},context:{vars:{$feature:"any",$layer:"any",$datastore:"any"}}},_lruCache:null,constructor:function(){this._lruCache=new B},initialize:function(y){var I=[];m.hasGeometryOperations(y)&&I.push(C.enableGeometryOperations());(m.hasFeatureSetOperations(y)||m.hasVariables(y,this.defaults.globals.featureSet))&&I.push(C.enableFeatureSetOperations());
m.isAsync(y)&&I.push(C.enableAsyncOperations());return w(I)},isAsync:function(y){y=[y];return m.hasFeatureSetOperations(y)||m.hasVariables(y,this.defaults.globals.async)},parse:function(y){return C.createSyntaxTree(y.expression)},compile:function(y){var I=a.clone(this.defaults.context);I.useAsync=y.async;return y.syntaxTree?C.createFunction(y.syntaxTree,I):null},getEvalOptions:function(y){var I=y.expression,e=y.feature,b=y.layer,q=y.spatialReference;y=y.portal;var K,M,z={spatialReference:q,cache:this._lruCache};
if(b&&(I.hasVariable("$layer")&&(K=M=b.getMap()?C.createFeatureSetFromLayer(b,z):C.createFeatureSetFromLayerUrl(b.url,z)),I.hasVariable("$datastore")))var v=(v=m.getServiceUrl(b.url))?C.createFeatureSetCollectionFromServiceUrl(v,z):null;I=e&&I.hasVariable("$feature")?n.createFromGraphicLikeObject(e.geometry,e.attributes,(I.hasFunction("attachments")||I.hasFunction("featuresetbyrelationship"))&&b&&!b.getMap()?M||C.createFeatureSetFromLayerUrl(b.url,z):b):null;if(y){y=y.replace(/\/+$/ig,"");var Q={url:y,
portalUrl:y+"/sharing/rest"}}return{context:{vars:{$feature:I,$layer:K,$datastore:v},services:Q?{portal:Q}:null,lrucache:this._lruCache,spatialReference:q}}}}));d("extend-esri")&&a.setObject("arcadeProfiles.fieldCalculateProfile",D,c);return D})},"esri/arcade/featureset/support/RecentlyUsedCache":function(){define(["require","exports"],function(D,a){var d=function(){function w(n){var B=this;B._keys=[];B._values=[];B.length=0;n&&n.forEach(function(C){B.set(C[0],C[1])})}w.prototype.entries=function(){var n=
this;return[].slice.call(this.keys().map(function(B){return[B,n.get(B)]}))};w.prototype.keys=function(){return[].slice.call(this._keys)};w.prototype.values=function(){return[].slice.call(this._values)};w.prototype.has=function(n){return-1<this._keys.indexOf(n)};w.prototype.get=function(n){n=this._keys.indexOf(n);return-1<n?this._values[n]:void 0};w.prototype.deepGet=function(n){if(!n||!n.length)return null;var B=function(C,m){return void 0===C||null===C?null:m.length?B(C instanceof w?C.get(m[0]):
C[m[0]],m.slice(1)):C};return B(this.get(n[0]),n.slice(1))};w.prototype.set=function(n,B){var C=this._keys.indexOf(n);-1<C?this._values[C]=B:(this._keys.push(n),this._values.push(B),this.length=this._values.length);return this};w.prototype.sortedSet=function(n,B,C,m){var y=this._keys.length;C=C||0;m=void 0!==m?m:y-1;if(0===y)return this._keys.push(n),this._values.push(B),this;if(n===this._keys[C])return this._values.splice(C,0,B),this;if(n===this._keys[m])return this._values.splice(m,0,B),this;if(n>
this._keys[m])return this._keys.splice(m+1,0,n),this._values.splice(m+1,0,B),this;if(n<this._keys[C])return this._values.splice(C,0,B),this._keys.splice(C,0,n),this;if(C>=m)return this;y=C+Math.floor((m-C)/2);return n<this._keys[y]?this.sortedSet(n,B,C,y-1):n>this._keys[y]?this.sortedSet(n,B,y+1,m):this};w.prototype.size=function(){return this.length};w.prototype.clear=function(){this._keys.length=this.length=this._values.length=0;return this};w.prototype.delete=function(n){n=this._keys.indexOf(n);
return-1<n?(this._keys.splice(n,1),this._values.splice(n,1),this.length=this._keys.length,!0):!1};w.prototype.forEach=function(n){var B=this;this._keys.forEach(function(C,m){n(B.get(C),C,m)})};w.prototype.map=function(n){var B=this;return this.keys().map(function(C,m){return n(B.get(C),C,m)})};w.prototype.filter=function(n){var B=this;B._keys.forEach(function(C,m){!1===n(B.get(C),C,m)&&B.delete(C)});return this};w.prototype.clone=function(){return new w(this.entries())};return w}(),c=function(){function w(n){void 0===
n&&(n=20);this.maxEntries=n;this.values=new d}w.prototype.delete=function(n){this.values.has(n)&&this.values.delete(n)};w.prototype.get=function(n){var B=null;this.values.has(n)&&(B=this.values.get(n),this.values.delete(n),this.values.set(n,B));return B};w.prototype.put=function(n,B){if(this.values.size()>=this.maxEntries){var C=this.values.keys()[0];this.values.delete(C)}this.values.set(n,B)};return w}();return function(){function w(n){void 0===n&&(n=20);this.maxEntries=n;this._cache=new c(this.maxEntries)}
w.prototype.clear=function(){this._cache=new c(this.maxEntries)};w.prototype.addToCache=function(n,B){this._cache.put(n,B)};w.prototype.removeFromCache=function(n){this._cache.delete(n)};w.prototype.getFromCache=function(n){return this._cache.get(n)};return w}()})},"widgets/Screening/download/download":function(){define("dojo/_base/declare dojo/_base/lang dojo/Evented jimu/BaseWidget dojo/_base/html dojo/_base/array dojo/on dijit/TooltipDialog jimu/dijit/formSelect dojo/dom-construct dijit/popup jimu/dijit/Message jimu/CSVUtils ./extractDataTask ./createReplica dojo/dom-class jimu/utils dijit/focus dojo/keys dojo/_base/event dojo/has".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U){return D([c,d],{baseClass:"jimu-widget-screening",_popup:null,downloadOptions:[],isTooltipDialogOpened:!1,downLoadStatus:{},constructor:function(g){this._popup=null;this.downloadOptions=[];this.isTooltipDialogOpened=!1;this.downLoadStatus={};a.mixin(this,g)},startup:function(){this._popup=new C({"class":"esriCTDownloadSettingsDialog "+this.baseClass,style:{width:"300px"}});"DartTheme"===this.appConfig.theme.name&&M.add(this._popup.domNode,"dart-panel");
this._popup.startup();this.own(B(document.body,"click",a.hitch(this,function(g){this.isPartOfPopup(g.target||g.srcElement)||this.closePopup()})));this.own(B(window,"resize",a.hitch(this,function(){this.closePopup()})));this._createSettingsDialog()},checkFileForDownload:function(){var g,G;var F=g=G=!1;"extractDataTask"===this.config.downloadSettings.type&&(F=g=G=!0);var l=this._getFilteredDownloadLayers();n.forEach(l,a.hitch(this,function(E){E.allowDownload&&this.downloadFeatureDetailsObj[E.id]&&0<
this.downloadFeatureDetailsObj[E.id].length&&(0<=E.downloadingFileOption.indexOf("csv")&&(F=!0),0<=E.downloadingFileOption.indexOf("shapefile")&&(g=!0),0<=E.downloadingFileOption.indexOf("filegdb")&&(G=!0))}));this.downLoadStatus={isCSVAvailable:F,isShapeFileAvailable:g,isFileGDBAvailable:G}},_createSettingsDialog:function(){var g=y.create("div",{"class":"esriCTDownloadSettingsContainer"},null);y.create("div",{"class":"esriCTEllipsis esriCTDownloadSettingLabel",innerHTML:this.nls.reportsTab.downloadLabelText},
g);this.downloadFormatSelect=new m({"aria-label":this.nls.reportsTab.downloadLabelText});this.own(B(this.downloadFormatSelect,"keydown",a.hitch(this,function(F){F.keyCode===Q.ESCAPE&&(S.stop(F),this.closePopup(),this.emit("setFocusOnDownloadReportButton"))})));this._getOptionsFordownloadFormat();this.downloadFormatSelect.placeAt(g);var G=y.create("button",{innerHTML:this.nls.reportsTab.downloadBtnText,"class":"esriCTEllipsis jimu-btn esriCTDownloadSettingsBtn",tabindex:0,"aria-label":this.nls.reportsTab.downloadBtnText,
role:"button"},y.create("div",{"class":"esriCTDownloadSettingsBtnContainer"},g));this.own(B(G,"click",a.hitch(this,function(F){S.stop(F);this.closePopup();this.emit("setFocusOnDownloadReportButton");this.isAndroidDevice||U("touch")?this._startDownload():this._chooseFileTypeToDownload()})));this.own(B(G,"keydown",a.hitch(this,function(F){if(F.keyCode===Q.ENTER||F.keyCode===Q.SPACE)S.stop(F),this.closePopup(),this.emit("setFocusOnDownloadReportButton"),this.isAndroidDevice?this._startDownload():this._chooseFileTypeToDownload();
F.keyCode===Q.ESCAPE&&(S.stop(F),this.closePopup(),this.emit("setFocusOnDownloadReportButton"))})));this._popup.setContent(g)},_loadOptionsForDropDown:function(g,G){var F=[],l;n.forEach(G,a.hitch(this,function(E){l={value:E,label:this.nls.reportsTab[E]};F.push(l)}));g.addOption(F)},_getOptionsFordownloadFormat:function(){if("extractDataTask"===this.config.downloadSettings.type)var g=["csv","filegdb","shapefile"];else{var G=[];g=["csv"];G=this._getFilteredDownloadLayers();n.forEach(G,a.hitch(this,
function(F){var l=["csv"];if(F.allowDownload){var E=this.filterLayerObj[F.id].capabilities;var R=this.filterLayerObj[F.id].version;1<E.split("Sync").length&&10.4<=R&&(-1===l.indexOf("filegdb")&&l.push("filegdb"),-1===g.indexOf("filegdb")&&g.push("filegdb"),z.isHostedService(F.url)&&(-1===l.indexOf("shapefile")&&l.push("shapefile"),-1===g.indexOf("shapefile")&&g.push("shapefile")));F.downloadingFileOption=l}}))}this._loadOptionsForDropDown(this.downloadFormatSelect,g)},openPopup:function(){I.open({popup:this._popup,
x:this.position.pageX,y:this.position.pageY});this.isTooltipDialogOpened=!0},closePopup:function(){this._popup&&(I.close(this._popup),this.isTooltipDialogOpened=!1)},isPartOfPopup:function(g){var G=this._popup.domNode;return g===G||w.isDescendant(g,G)},_chooseFileTypeToDownload:function(){switch(this.downloadFormatSelect.get("value")){case "csv":this.downLoadStatus.isCSVAvailable?this._exportToCSV():this.emit("showMessage",this.nls.reportsTab.noFeaturesFound);break;case "filegdb":this.downLoadStatus.isFileGDBAvailable?
"syncEnable"===this.config.downloadSettings.type?this._exportFileUsingCreateReplica("filegdb"):"extractDataTask"===this.config.downloadSettings.type&&this.isPointOrLineAOI?this.emit("showMessage",this.nls.reportsTab.unableToDownloadFileGDBText):this._exportFileUsingExtractDataTask("filegdb"):this.emit("showMessage",this.nls.reportsTab.noFeaturesFound);break;case "shapefile":this.downLoadStatus.isShapeFileAvailable?"syncEnable"===this.config.downloadSettings.type?this._exportFileUsingCreateReplica("shapefile"):
"extractDataTask"===this.config.downloadSettings.type&&this.isPointOrLineAOI?this.emit("showMessage",this.nls.reportsTab.unableToDownloadShapefileText):this._exportFileUsingExtractDataTask("shapefile"):this.emit("showMessage",this.nls.reportsTab.noFeaturesFound)}},_startDownload:function(){var g=new e({titleLabel:this.nls.reportsTab.downloadReportConfirmTitle,message:this.nls.reportsTab.downloadReportConfirmMessage,autoHeight:!0,buttons:[{label:this.nls.common.yes,onClick:a.hitch(this,function(){this._chooseFileTypeToDownload();
g.close()})},{label:this.nls.common.no}]})},_exportToCSV:function(){var g,G,F={},l,E,R=[];R=this.config.downloadSettings.layers;this.shapeFileLayerDetails&&(R=R.concat(this.shapeFileLayerDetails));R=this._getFilteredDownloadLayers();n.forEach(R,a.hitch(this,function(aa,W){F={};E=!1;E="extractDataTask"===this.config.downloadSettings.type?!0:aa.allowDownload;g=aa.isShapeFile?aa.layer:this.filterLayerObj[aa.id];G=this._getLayerData(g,this.downloadFeatureDetailsObj[aa.id]);G=dojo.mixin({},G);G=this._removeAnalysisUnitFromCSV(G);
this._addAnalysisDataToCSVData(G,aa.id);l=this._getInfoTemplate(g);0<G.graphicsArray.length&&E&&(F.datas=G.graphicsArray,F.fromClient=!1,F.withGeometry="esriGeometryPoint"===g.geometryType,F.outFields=G.outFields,F.formatNumber=!1,F.formatDate=!0,F.formatCodedValue=!0,(F.popupInfo=l)&&l.expressionInfos&&(F.outFields=this.appendArcadeExpressionsToFields(F.outFields,l.expressionInfos)),this._exportToCSVFile(g,F,W+1))}))},appendArcadeExpressionsToFields:function(g,G){if(g){if(0<G.length){var F=/^expression\//;
n.forEach(G,function(l){n.some(g,function(E){if(F.test(E.name))return E=E.name.substr(11),l.name===E})||g.push({name:"expression/"+l.name,alias:l.title,show:!0})})}return g}},_exportToCSVFile:function(g,G,F){setTimeout(a.hitch(this,function(){b.exportCSVFromFeatureLayer(g.name||"CSV_FILE",g,G)}),100*F)},_removeAnalysisUnitFromCSV:function(g){var G=g.outFields;n.forEach(G,function(F,l){"CSVMeasurementUnit"===F.name&&G.splice(l,1)});return g},_getInfoTemplate:function(g){var G;if(g.infoTemplate)return g.infoTemplate.info;
var F=g.id.split("_");if(F[F.length-1]===g.layerId.toString()){F.pop();var l=F.join("_")}l&&(G=this.map.getLayer(l));return G&&G.infoTemplates&&G.infoTemplates.hasOwnProperty(g.layerId)?G.infoTemplates[g.layerId].infoTemplate.info:null},_getLayerData:function(g,G){var F=[];n.forEach(G,a.hitch(this,function(l){l.attributes.geometry=l.geometry;F.push(l.attributes)}));return"esriGeometryPoint"===g.geometryType?(g=this._formatPointLayerData(F,g),{graphicsArray:g.layerGraphics,outFields:g._outFields}):
{graphicsArray:F,outFields:g.fields}},_formatPointLayerData:function(g,G){var F={};g=a.clone(g);G=G.fields;n.forEach(g,function(E){var R=E.geometry;R&&"point"===R.type&&("x"in E?E._x=R.x:E.x=R.x,"y"in E?E._y=R.y:E.y=R.y);delete E.geometry});G=a.clone(G);var l="";l=-1!==G.indexOf("x")?"_x":"x";G.push({name:l,alias:l,format:{digitSeparator:!1,places:6},show:!0,type:"esriFieldTypeDouble"});l=-1!==G.indexOf("y")?"_y":"y";G.push({name:l,alias:l,format:{digitSeparator:!1,places:6},show:!0,type:"esriFieldTypeDouble"});
F.layerGraphics=g;F._outFields=G;return F},_exportFileUsingExtractDataTask:function(g){this.loadingIndicator.show();g=new q({map:this.map,aoi:this.aoi,fileFormat:g,url:this.config.downloadSettings.extractDataTaskURL});g.startup();this.own(B(g,"onGPTaskSuccess",a.hitch(this,function(G){this._downloadDataFile(G);this.loadingIndicator.hide()})));this.own(B(g,"onGPTaskFailed",a.hitch(this,function(){this.emit("showMessage",this.nls.reportsTab.extractDataTaskFailedMessage);this.loadingIndicator.hide()})))},
_exportFileUsingCreateReplica:function(g){this.loadingIndicator.show();g=new K({map:this.map,config:this.config,aoi:this.aoi,fileFormat:g,filterLayerObj:this.filterLayerObj,nls:this.nls,downloadFeatureDetailsObj:this.downloadFeatureDetailsObj,loadingIndicator:this.loadingIndicator});this.own(B(g,"onRequestSucceeded",a.hitch(this,function(G){this._downloadDataFile(G);this.loadingIndicator.hide()})));this.own(B(g,"onRequestFailed",a.hitch(this,function(){this.loadingIndicator.hide()})));this.own(B(g,
"createReplicaComplete",a.hitch(this,function(G){G&&this.emit("showMessage",G);this.loadingIndicator.hide()})));this.own(B(g,"showErrMessage",a.hitch(this,function(G){this.emit("showMessage",G)})));g.startup()},_downloadDataFile:function(g){var G;for(G in this.filterLayerObj)if(this.filterLayerObj.hasOwnProperty(G)){var F=this.filterLayerObj[G];if(F.credential&&F.credential.token){var l=g.split("replicafiles");var E=F.url;var R=l[0].toLowerCase();R=R.replace(/(^\w+:|^)\/\//,"");if(0<l.length&&-1<
E.toLowerCase().indexOf(R.toLowerCase())){g=g+"?token\x3d"+F.credential.token;break}}}var aa=y.create("iframe",{"class":"esriCTHidden",src:g},this.iframeNode);var W=setInterval(a.hitch(this,function(){var da=aa.contentDocument||aa.contentWindow.document;if("complete"===da.readyState||"interactive"===da.readyState)y.destroy(aa),clearInterval(W)}),4E3)},_addAnalysisDataToCSVData:function(g,G){var F,l;var E=g.graphicsArray.length;if(0<E){for(F=0;F<E;F++){var R=g.graphicsArray[F];if(l=this._getFeatureAnalysisData(G,
F))R.CSVMeasurementUnit=l.analysisResultValue}l&&this._addGeometryUnitToFields(g,l)}},_addGeometryUnitToFields:function(g,G){g.outFields.push({alias:G.analysisResultKey+"("+G.analysisUnit+")",name:"CSVMeasurementUnit",type:"esriFieldTypeDouble"})},_getFeatureAnalysisData:function(g,G){var F,l={};var E="";for(F in this.printData){var R=this.printData[F];if(-1!==F.indexOf(g)&&"esriGeometryPoint"!==R.geometryType){if("esriGeometryPolyline"===R.geometryType)return E=this._getAnalysisUnitForGeometry(this.lengthUnits,
R.geometryType),g=this.lengthUnits+"UnitInfo",g=this._lowerCaseFirstLetter(g),l.analysisResultValue=R[g][G],l.analysisResultKey=this._getAnalysisResultKey(R.geometryType),l.analysisUnit=E,l;if("esriGeometryPolygon"===R.geometryType)return E=this._getAnalysisUnitForGeometry(this.areaUnits,R.geometryType),g=this.areaUnits+"UnitInfo",g=this._lowerCaseFirstLetter(g),l.analysisResultValue=R[g][G],l.analysisResultKey=this._getAnalysisResultKey(R.geometryType),l.analysisUnit=E,l}}},_getAnalysisResultKey:function(g){if("esriGeometryPolygon"===
g)return this.nls.reportsTab.featureCSVAreaText;if("esriGeometryPolyline"===g)return this.nls.reportsTab.featureCSVLengthText},_getAnalysisUnitForGeometry:function(g,G){switch(g){case "Feet":case "SquareFeet":var F="esriGeometryPolygon"===G?this.nls.units.squareFeetAbbr:this.nls.units.feetAbbr;break;case "Miles":case "Acres":F="esriGeometryPolygon"===G?this.nls.units.acresAbbr:this.nls.units.milesAbbr;break;case "Meters":case "SquareMeters":F="esriGeometryPolygon"===G?this.nls.units.squareMetersAbbr:
this.nls.units.metersAbbr;break;case "Kilometers":case "SquareKilometers":F="esriGeometryPolygon"===G?this.nls.units.squareKilometerAbbr:this.nls.units.kilometersAbbr;break;case "Hectares":F="esriGeometryPolygon"===G?this.nls.reportsTab.hectaresAbbr:this.nls.units.kilometersAbbr;break;case "SquareMiles":F="esriGeometryPolygon"===G?this.nls.reportsTab.squareMilesAbbr:this.nls.units.milesAbbr}return F},_getFilteredDownloadLayers:function(){var g=[];g=[];g=this.config.downloadSettings.layers;return g=
g.filter(a.hitch(this,function(G){return this.filterLayerObj.hasOwnProperty(G.id)?!0:!1}))},setFocusOnFormatDropdown:function(){this._focusOutCurrentNode();v.focus(this.downloadFormatSelect)},_lowerCaseFirstLetter:function(g){return g.charAt(0).toLowerCase()+g.slice(1)},_focusOutCurrentNode:function(){v.curNode&&v.curNode.blur()}})})},"widgets/Screening/download/extractDataTask":function(){define("dojo/_base/declare dojo/_base/lang dojo/Evented jimu/BaseWidget esri/tasks/Geoprocessor dojo/Deferred esri/tasks/FeatureSet esri/graphic".split(" "),
function(D,a,d,c,w,n,B,C){return D([c,d],{baseClass:"jimu-widget-screening-extract-data-task",_extractDataTaskGPService:null,choiceList:{filegdb:"File Geodatabase - GDB - .gdb",shapefile:"Shapefile - SHP - .shp"},constructor:function(m){this._extractDataTaskGPService=null;this.choiceList={filegdb:"File Geodatabase - GDB - .gdb",shapefile:"Shapefile - SHP - .shp"};a.mixin(this,m)},startup:function(){this._extractDataTaskGPService=new w(this.url);this._init()},_init:function(){var m=new n,y=new C,I=
[],e=new B;y.geometry=this.aoi.geometry;I.push(y);e=new B;e.features=I;e.displayFieldName="";e.geometryType="esriGeometryPolygon";e.spatialReference=this.map.spatialReference;e.fields=[];e.exceededTransferLimit=!1;this._extractDataTaskGPService.submitJob({Area_of_Interest:e,Feature_Format:this.choiceList[this.fileFormat]},a.hitch(this,function(b){this._extractDataTaskGPService.getResultData(b.jobId,"Output_Zip_File",a.hitch(this,this.onGPTaskSuccess),a.hitch(this,this.onGPTaskFailed))}),a.hitch(this,
this.onGPTaskStatusUpdate),a.hitch(this,this.onGPTaskFailed));return m.promise},onGPTaskSuccess:function(m){this.emit("onGPTaskSuccess",m.value.url)},onGPTaskStatusUpdate:function(m){this.emit("onGPTaskStatusUpdate",m)},onGPTaskFailed:function(m){this.emit("onGPTaskFailed",m)}})})},"esri/tasks/Geoprocessor":function(){define("dojo/_base/declare dojo/_base/lang dojo/_base/array dojo/_base/Deferred dojo/_base/json dojo/has dojo/io-query ../kernel ../request ../deferredUtils ../geometry/normalizeUtils ./Task ./FeatureSet ./JobInfo ./GPMessage ./LinearUnit ./DataFile ./RasterData ./Date ./ParameterValue ./GPResultImageLayer ../layers/ArcGISDynamicMapServiceLayer ../layers/MapImage".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U,g,G){D=D(e,{declaredClass:"esri.tasks.Geoprocessor",_eventMap:{"execute-complete":["results","messages"],"get-result-data-complete":["result"],"get-result-image-complete":["mapImage"],"get-result-image-layer-complete":["layer"],"job-cancel":["jobInfo"],"job-complete":["jobInfo"],"status-update":["jobInfo"]},constructor:function(F){this._jobUpdateHandler=a.hitch(this,this._jobUpdateHandler);this._getJobStatus=a.hitch(this,this._getJobStatus);this._getResultDataHandler=
a.hitch(this,this._getResultDataHandler);this._getResultImageHandler=a.hitch(this,this._getResultImageHandler);this._executeHandler=a.hitch(this,this._executeHandler);this._updateTimers=[];this.registerConnectEvents()},updateDelay:1E3,processSpatialReference:null,outputSpatialReference:null,outSpatialReference:null,setUpdateDelay:function(F){this.updateDelay=F},setProcessSpatialReference:function(F){this.processSpatialReference=F},setOutputSpatialReference:function(F){this._setOutSR(F)},setOutSpatialReference:function(F){this._setOutSR(F)},
__msigns:[{n:"execute",c:3,a:[{i:0,p:["*"]}],e:2,f:1},{n:"submitJob",c:4,a:[{i:0,p:["*"]}],e:3}],_setOutSR:function(F){this.outSpatialReference=this.outputSpatialReference=F},_getOutSR:function(){return this.outSpatialReference||this.outputSpatialReference},_gpEncode:function(F,l,E){for(var R in F){var aa=F[R];a.isArray(aa)?F[R]=w.toJson(d.map(aa,function(W){return this._gpEncode({item:W},!0).item},this)):aa instanceof Date&&(F[R]=aa.getTime())}return this._encode(F,l,E)},_decode:function(F){var l=
F.dataType,E=new S(F);if(-1!==d.indexOf(["GPBoolean","GPDouble","GPLong","GPString"],l))return E;if("GPLinearUnit"===l)E.value=new M(E.value);else if("GPFeatureRecordSetLayer"===l||"GPRecordSet"===l)E.value=new b(E.value);else if("GPDataFile"===l)E.value=new z(E.value);else if("GPDate"===l)F=E.value,a.isString(F)?E.value=new Q({date:F}):E.value=new Date(F);else if("GPRasterData"===l||"GPRasterDataLayer"===l)F=F.value.mapImage,E.value=F?new G(F):new v(E.value);else if(-1!==l.indexOf("GPMultiValue:")){var R=
l.split(":")[1];F=E.value;E.value=d.map(F,function(aa){return this._decode({paramName:"_name",dataType:R,value:aa}).value},this)}else console.log(this.declaredClass+" : GP Data type not handled. : "+E.dataType),E=null;return E},submitJob:function(F,l,E,R,aa){var W=this._getOutSR(),da=aa.assembly;F=this._gpEncode(a.mixin({},this._url.query,{f:"json","env:outSR":W?W.wkid||w.toJson(W.toJson()):null,"env:processSR":this.processSpatialReference?this.processSpatialReference.wkid||w.toJson(this.processSpatialReference.toJson()):
null},F),null,da&&da[0]);var h=this._jobUpdateHandler,V=this._errorHandler;return m({url:this._url.path+"/submitJob",content:F,callbackParamName:"callback",load:function(T,r){h(T,r,!1,l,E,aa.dfd)},error:function(T){V(T,R,aa.dfd)}})},_jobUpdateHandler:function(F,l,E,R,aa,W){var da=F.jobId;l=new q(F);this._successHandler([l],"onStatusUpdate",aa,E&&W);if(!E)switch(clearTimeout(this._updateTimers[da]),this._updateTimers[da]=null,W&&W.progress(l),F.jobStatus){case q.STATUS_SUBMITTED:case q.STATUS_EXECUTING:case q.STATUS_WAITING:case q.STATUS_NEW:var h=
this._getJobStatus;this._updateTimers[da]=setTimeout(function(){h(da,E,R,aa,W)},this.updateDelay);break;default:this._successHandler([l],"onJobComplete",R,W)}},_getJobStatus:function(F,l,E,R,aa){var W=this._jobUpdateHandler;m({url:this._url.path+"/jobs/"+F,content:a.mixin({},this._url.query,{f:"json"}),callbackParamName:"callback",load:function(da,h){W(da,h,l,E,R,aa)},error:this._errorHandler})},_getResultDataHandler:function(F,l,E,R,aa){try{var W=this._decode(F);this._successHandler([W],"onGetResultDataComplete",
E,aa)}catch(da){this._errorHandler(da,R,aa)}},getResultData:function(F,l,E,R){var aa=this._getResultDataHandler,W=this._errorHandler,da=new c(y._dfdCanceller);da._pendingDfd=m({url:this._url.path+"/jobs/"+F+"/results/"+l,content:a.mixin({},this._url.query,{f:"json",returnType:"data"}),callbackParamName:"callback",load:function(h,V){aa(h,V,E,R,da)},error:function(h){W(h,R,da)}});return da},checkJobStatus:function(F,l,E){var R=this._jobUpdateHandler,aa=this._errorHandler,W=new c(y._dfdCanceller);W._pendingDfd=
m({url:this._url.path+"/jobs/"+F,content:a.mixin({},this._url.query,{f:"json"}),callbackParamName:"callback",load:function(da,h){R(da,h,!0,null,l,W)},error:function(da){aa(da,E,W)}});return W},cancelJob:function(F,l,E){var R=this._errorHandler,aa=new c(y._dfdCanceller);aa._pendingDfd=m({url:this._url.path+"/jobs/"+F+"/cancel",content:a.mixin({},this._url.query,{f:"json"}),callbackParamName:"callback",load:a.hitch(this,function(W,da){this._successHandler([W],"onJobCancel",l,aa)}),error:function(W){R(W,
E,aa)}});return aa},execute:function(F,l,E,R){var aa=this._getOutSR(),W=R.assembly;F=this._gpEncode(a.mixin({},this._url.query,{f:"json","env:outSR":aa?aa.wkid||w.toJson(aa.toJson()):null,"env:processSR":this.processSpatialReference?this.processSpatialReference.wkid||w.toJson(this.processSpatialReference.toJson()):null},F),null,W&&W[0]);var da=this._executeHandler,h=this._errorHandler;return m({url:this._url.path+"/execute",content:F,callbackParamName:"callback",load:function(V,T){da(V,T,l,E,R.dfd)},
error:function(V){h(V,E,R.dfd)}})},_executeHandler:function(F,l,E,R,aa){try{var W=F.results,da,h=F.messages;var V=0;for(da=W.length;V<da;V++)W[V]=this._decode(W[V]);V=0;for(da=h.length;V<da;V++)h[V]=new K(h[V]);this._successHandler([W,h],"onExecuteComplete",E,aa)}catch(T){this._errorHandler(T,R,aa)}},_getResultImageHandler:function(F,l,E,R,aa){try{var W=this._decode(F);this._successHandler([W],"onGetResultImageComplete",E,aa)}catch(da){this._errorHandler(da,R,aa)}},getResultImage:function(F,l,E,R,
aa){var W=this._getResultImageHandler,da=this._errorHandler;E=this._gpEncode(a.mixin({},this._url.query,{f:"json"},E.toJson()));var h=new c(y._dfdCanceller);h._pendingDfd=m({url:this._url.path+"/jobs/"+F+"/results/"+l,content:E,callbackParamName:"callback",load:function(V,T){W(V,T,R,aa,h)},error:function(V){da(V,aa,h)}});return h},cancelJobStatusUpdates:function(F){clearTimeout(this._updateTimers[F]);this._updateTimers[F]=null},getResultImageLayer:function(F,l,E,R){if(null==l){var aa=this._url.path.indexOf("/GPServer/");
F=this._url.path.substring(0,aa)+"/MapServer/jobs/"+F}else F=this._url.path+"/jobs/"+F+"/results/"+l;this._url.query&&(F+="?"+B.objectToQuery(this._url.query));l=null==l?new g(F,{imageParameters:E}):new U(F,{imageParameters:E},!0);this.onGetResultImageLayerComplete(l);R&&R(l);return l},onStatusUpdate:function(){},onJobComplete:function(){},onExecuteComplete:function(){},onGetResultDataComplete:function(){},onGetResultImageComplete:function(){},onGetResultImageLayerComplete:function(){},onJobCancel:function(){}});
I._createWrappers(D);n("extend-esri")&&a.setObject("tasks.Geoprocessor",D,C);return D})},"esri/tasks/JobInfo":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/has","../kernel","./GPMessage"],function(D,a,d,c,w){D=D(null,{declaredClass:"esri.tasks.JobInfo",constructor:function(n){this.messages=[];a.mixin(this,n);n=this.messages;var B,C=n.length;for(B=0;B<C;B++)n[B]=new w(n[B])},jobId:"",jobStatus:""});a.mixin(D,{STATUS_CANCELLED:"esriJobCancelled",STATUS_CANCELLING:"esriJobCancelling",
STATUS_DELETED:"esriJobDeleted",STATUS_DELETING:"esriJobDeleting",STATUS_EXECUTING:"esriJobExecuting",STATUS_FAILED:"esriJobFailed",STATUS_NEW:"esriJobNew",STATUS_SUBMITTED:"esriJobSubmitted",STATUS_SUCCEEDED:"esriJobSucceeded",STATUS_TIMED_OUT:"esriJobTimedOut",STATUS_WAITING:"esriJobWaiting"});d("extend-esri")&&a.setObject("tasks.JobInfo",D,c);return D})},"esri/tasks/GPMessage":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/has","../kernel"],function(D,a,d,c){D=D(null,{declaredClass:"esri.tasks.GPMessage",
constructor:function(w){a.mixin(this,w)}});a.mixin(D,{TYPE_INFORMATIVE:"esriJobMessageTypeInformative",TYPE_PROCESS_DEFINITION:"esriJobMessageTypeProcessDefinition",TYPE_PROCESS_START:"esriJobMessageTypeProcessStart",TYPE_PROCESS_STOP:"esriJobMessageTypeProcessStop",TYPE_WARNING:"esriJobMessageTypeWarning",TYPE_ERROR:"esriJobMessageTypeError",TYPE_EMPTY:"esriJobMessageTypeEmpty",TYPE_ABORT:"esriJobMessageTypeAbort"});d("extend-esri")&&a.setObject("tasks.GPMessage",D,c);return D})},"esri/tasks/LinearUnit":function(){define(["dojo/_base/declare",
"dojo/_base/lang","dojo/has","../kernel"],function(D,a,d,c){D=D(null,{declaredClass:"esri.tasks.LinearUnit",constructor:function(w){w&&a.mixin(this,w)},distance:0,units:null,toJson:function(){var w={};this.distance&&(w.distance=this.distance);this.units&&(w.units=this.units);return w}});d("extend-esri")&&a.setObject("tasks.LinearUnit",D,c);return D})},"esri/tasks/DataFile":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/has","../kernel"],function(D,a,d,c){D=D(null,{declaredClass:"esri.tasks.DataFile",
constructor:function(w){w&&a.mixin(this,w)},url:null,itemID:null,toJson:function(){var w={};this.url&&(w.url=this.url);this.itemID&&(w.itemID=this.itemID);return w}});d("extend-esri")&&a.setObject("tasks.DataFile",D,c);return D})},"esri/tasks/RasterData":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/has","../kernel"],function(D,a,d,c){D=D(null,{declaredClass:"esri.tasks.RasterData",constructor:function(w){w&&a.mixin(this,w)},url:null,format:null,itemID:null,toJson:function(){var w=
{};this.url&&(w.url=this.url);this.format&&(w.format=this.format);this.itemID&&(w.itemID=this.itemID);return w}});d("extend-esri")&&a.setObject("tasks.RasterData",D,c);return D})},"esri/tasks/Date":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/date/locale","dojo/has","../kernel"],function(D,a,d,c,w){D=D(null,{declaredClass:"esri.tasks.Date",constructor:function(n){n&&(n.format&&(this.format=n.format),this.date=d.parse(n.date,{selector:"date",datePattern:this.format}))},date:new Date,
format:"EEE MMM dd HH:mm:ss zzz yyyy",toJson:function(){return{date:d.format(this.date,{selector:"date",datePattern:this.format}),format:this.format}}});c("extend-esri")&&a.setObject("tasks.Date",D,w);return D})},"esri/tasks/ParameterValue":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/has","../kernel"],function(D,a,d,c){D=D(null,{declaredClass:"esri.tasks.ParameterValue",constructor:function(w){a.mixin(this,w)}});d("extend-esri")&&a.setObject("tasks.ParameterValue",D,c);return D})},
"esri/tasks/GPResultImageLayer":function(){define("dojo/_base/declare dojo/_base/lang dojo/_base/json dojo/has dojo/io-query ../kernel ../layers/ArcGISDynamicMapServiceLayer".split(" "),function(D,a,d,c,w,n,B){D=D(B,{declaredClass:"esri.tasks._GPResultImageLayer",constructor:function(C,m){m&&m.imageParameters&&m.imageParameters.extent&&(this.initialExtent=this.fullExtent=m.imageParameters.extent,this.spatialReference=this.initialExtent.spatialReference);this.getImageUrl=a.hitch(this,this.getImageUrl);
this.loaded=!0;this.onLoad(this)},getImageUrl:function(C,m,y,I){var e=C.spatialReference.wkid;I(this._url.path+"?"+w.objectToQuery(a.mixin(this._params,{f:"image",bbox:d.toJson(C.toJson()),bboxSR:e,imageSR:e,size:m+","+y})))}});c("extend-esri")&&a.setObject("tasks._GPResultImageLayer",D,n);return D})},"widgets/Screening/download/createReplica":function(){define("dojo/_base/declare dojo/_base/lang dojo/_base/array dojo/string dojo/Evented jimu/BaseWidget esri/request dojo/Deferred dojo/promise/all esri/geometry/projection esri/SpatialReference".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I){return D([n,w],{baseClass:"jimu-widget-screening-create-replica",_extractDataTaskGPService:null,errMessageString:"",responseArray:[],layerDetailsObj:{},constructor:function(e){this._extractDataTaskGPService=null;this.errMessageString="";this.responseArray=[];this.layerDetailsObj={};a.mixin(this,e)},startup:function(){this.responseArray=[];this.layerDetailsObj={};this._loadProjection()},_init:function(){var e,b,q;d.forEach(this.config.downloadSettings.layers,a.hitch(this,
function(K){var M;if(this.downloadFeatureDetailsObj[K.id]&&0<this.downloadFeatureDetailsObj[K.id].length&&-1<K.downloadingFileOption.indexOf(this.fileFormat)&&K.allowDownload){e=K.url.split("/");b=parseInt(e.pop(),10);e=e.join("/");var z=!1;for(M in this.layerDetailsObj)M.toLowerCase()===e.toLowerCase()&&(z=!0,e=M);z||(this.layerDetailsObj[e]={layerInstance:K,layerIndexes:[],layerDetails:{},layerNames:[],wkid:this.filterLayerObj[K.id].spatialReference.wkid});this.layerDetailsObj[e].layerIndexes.push(b);
this.layerDetailsObj[e].layerNames.push(K.layerName);this.layerDetailsObj[e].layerDetails[b]={queryOption:"useFilter",useGeometry:!0,where:this.filterLayerObj[K.id].getDefinitionExpression()||""}}}));this.errMessageString="";for(q in this.layerDetailsObj)this.responseArray.push(this._exportFileUsingCreateReplica(q,this.layerDetailsObj[q]));m(this.responseArray).then(a.hitch(this,function(){this.errMessageString?(this.errMessageString=c.substitute(this.nls.reportsTab.createReplicaFailedMessage,{layerNames:this.errMessageString}),
this.emit("createReplicaComplete",this.errMessageString)):this.emit("createReplicaComplete")}))},_exportFileUsingCreateReplica:function(e,b){var q=this._removeDuplicateLayerIds(b.layerIndexes);var K=new C;if("shapefile"===this.fileFormat){var M=new I({wkid:b.wkid});M=y.project(this.aoi.geometry,M)}else M=this.aoi.geometry;q={f:"json",replicaName:b.layerInstance.layerName,layers:q.join(),layerQueries:JSON.stringify(b.layerDetails),inSR:JSON.stringify(this.aoi.geometry.spatialReference),geometry:JSON.stringify(M),
geometryType:"esriGeometryPolygon",transportType:"esriTransportTypeUrl",returnAttachments:!1,returnAttachmentsDataByUrl:!1,async:!1,syncModel:"none",dataFormat:this.fileFormat};B({url:e+"/createReplica",content:q,handleAs:"json",callbackParamName:"callback"},{usePost:!0}).then(a.hitch(this,function(z){this.onRequestSucceeded(K,z)}),a.hitch(this,function(z){this.errMessageString&&(this.errMessageString+=", ");this.errMessageString+=b.layerNames.join(", ");this.onRequestFailed(K,z)}));return K.promise},
_removeDuplicateLayerIds:function(e){return e.filter(function(b,q,K){return q===K.indexOf(b)})},onRequestSucceeded:function(e,b){e.resolve();if(b.responseUrl)var q=b.responseUrl;else b.URL?q=b.URL:b.resultUrl&&(q=b.resultUrl);q&&this.emit("onRequestSucceeded",q)},onRequestFailed:function(e,b){e.resolve();this.emit("onRequestFailed",b)},_loadProjection:function(){"shapefile"===this.fileFormat?y.load().then(a.hitch(this,function(){this._init()}),a.hitch(this,function(){this.loadingIndicator.hide();
this.emit("showMessage",this.nls.reportsTab.errorInLoadingProjectionModule)})):this._init()}})})},"esri/geometry/projection":function(){define("require exports dojo/Deferred ./pe ../SpatialReference ./GeographicTransformation".split(" "),function(D,a,d,c,w,n){function B(e,b,q,K,M){void 0===K&&(K=null);void 0===M&&(M=!1);if(null===K){var z=n.cacheKey(b,q);void 0!==I[z]?K=I[z]:(K=C(b,q,null),null===K&&(K=new n),I[z]=K)}return m._project(e,b,q instanceof w||!1===M?q:new w(q),K,M)}function C(e,b,q){void 0===
q&&(q=null);e=m._getTransformation(e,b,q);return null!==e?n.fromGE(e):null}Object.defineProperty(a,"__esModule",{value:!0});var m=null;a.isLoaded=function(){return!!m&&c.isLoaded()};a.isSupported=function(){return c.isSupported()};var y=null;a.load=function(){if(y)return y.promise;y=new d;var e=c.load();D(["./geometryEngine"],function(b){m=b;e.then(function(){m._enableProjection(c);y.resolve()},function(q){y.reject(q)})});return y.promise};a.project=function(e,b,q){void 0===q&&(q=null);return e instanceof
Array?0===e.length?[]:B(e,e[0].spatialReference,b,q):B([e],e.spatialReference,b,q)[0]};var I={};a.projectMany=B;a.getTransformation=C;a.getTransformations=function(e,b,q){void 0===q&&(q=null);e=m._getTransformationBySuitability(e,b,q);if(null!==e){b=[];for(q=0;q<e.length;q++)b.push(n.fromGE(e[q]));return b}return[]}})},"esri/geometry/pe":function(){define(["require","exports","../core/tsSupport/extendsHelper","dojo/Deferred","../core/sniff"],function(D,a,d,c,w){function n(z){function v(g,G,F){g[G]=
F(g[G])}a._pe=z;e.init();b.init();q.init();K.init();M.init();a.PeGCSExtent=function(g){function G(){return null!==g&&g.apply(this,arguments)||this}d(G,g);G.prototype.destroy=function(){a._pe.destroy(this)};return G}(a._pe.PeGCSExtent);for(var Q=0,S=[a._pe.PeDatum,a._pe.PeGeogcs,a._pe.PeGeogtran,a._pe.PeObject,a._pe.PeParameter,a._pe.PePrimem,a._pe.PeProjcs,a._pe.PeSpheroid,a._pe.PeUnit];Q<S.length;Q++)z=S[Q],v(z.prototype,"getName",function(g){return function(){return g.call(this,Array(e.PE_NAME_MAX))}});
Q=0;for(S=[a._pe.PeGeogtran,a._pe.PeProjcs];Q<S.length;Q++)z=S[Q],v(z.prototype,"getParameters",function(g){return function(){for(var G=Array(e.PE_PARM_MAX),F=g.call(this),l=0;l<G.length;l++){var E=a._pe.getValue(F,"*");G[l]=E?a._pe.wrapPointer(E,a._pe.PeParameter):null;F+=Int32Array.BYTES_PER_ELEMENT}return G}});v(a._pe.PeHorizon.prototype,"getCoord",function(g){return function(){var G=this.getSize();if(!G)return null;var F=[],l=g.call(this);y(F,G,l);return F}});v(a._pe.PeGTlistExtendedEntry.prototype,
"getEntries",function(g){var G=a._pe._pe_getPeGTlistExtendedGTsSize();return function(){var F=null,l=g.call(this);if(!a._pe.compare(l,a._pe.NULL)){F=[l];var E=this.getSteps();if(1<E){l=a._pe.getPointer(l);for(var R=1;R<E;R++)F.push(a._pe.wrapPointer(l+G*R,a._pe.PeGTlistExtendedGTs))}}return F}});var U=a._pe._pe_getPeHorizonSize();z=function(g){return function(){var G=this._cache;G||(this._cache=G=new Map);if(G.has(g))return G.get(g);var F=null,l=g.call(this);if(!a._pe.compare(l,a._pe.NULL)){F=[l];
var E=l.getNump();if(1<E){l=a._pe.getPointer(l);for(var R=1;R<E;R++)F.push(a._pe.wrapPointer(l+U*R,a._pe.PeHorizon))}}G.set(g,F);return F}};v(a._pe.PeProjcs.prototype,"horizonGcsGenerate",z);v(a._pe.PeProjcs.prototype,"horizonPcsGenerate",z);a._pe.PeObject.prototype.toString=function(g){void 0===g&&(g=e.PE_STR_OPTS_NONE);a._pe.ensureCache.prepare();var G=a._pe.getPointer(this),F=a._pe.ensureInt8(Array(e.PE_BUFFER_MAX));return a._pe.UTF8ToString(a._pe._pe_object_to_string_ext(G,g,F))}}function B(z){if(z){var v=
a._pe.getClass(z);v&&(v=a._pe.getCache(v))&&(z=a._pe.getPointer(z))&&delete v[z]}}function C(z,v){var Q=[];v=Array(v);for(var S=0;S<z;S++)Q.push(a._pe.ensureInt8(v));return Q}function m(z){if(Array.isArray(z[0])){var v=[];z.forEach(function(Q){v.push(Q[0],Q[1])})}else v=z;return v}function y(z,v,Q,S){void 0===S&&(S=!1);if(S)for(S=0;S<2*v;S++)z[S]=a._pe.getValue(Q+S*Float64Array.BYTES_PER_ELEMENT,"double");else{var U=0===z.length;for(S=0;S<v;S++)U&&(z[S]=Array(2)),z[S][0]=a._pe.getValue(Q,"double"),
z[S][1]=a._pe.getValue(Q+Float64Array.BYTES_PER_ELEMENT,"double"),Q+=2*Float64Array.BYTES_PER_ELEMENT}}Object.defineProperty(a,"__esModule",{value:!0});var I;a._pe=null;a.isLoaded=function(){return!!a._pe};a.isSupported=function(){return!!w("esri-wasm")};a.load=function(){if(I)return I.promise;I=new c;D(["./support/pe-wasm"],function(z){z({locateFile:function(v){return D.toUrl("./support/"+v)},onAbort:function(v){I.reject(Error(v))}}).then(function(v){n(v);I.resolve()})});return I.promise};(function(z){function v(U,
g,G){a._pe.ensureCache.prepare();var F=m(G),l=G===F;F=a._pe.ensureFloat64(F);(U=a._pe._pe_geog_to_proj(a._pe.getPointer(U),g,F))&&y(G,g,F,l);return U}function Q(U,g,G){return S(U,g,G,0)}function S(U,g,G,F){a._pe.ensureCache.prepare();var l=m(G),E=G===l;l=a._pe.ensureFloat64(l);(U=a._pe._pe_proj_to_geog_center(a._pe.getPointer(U),g,l,F))&&y(G,g,l,E);return U}z.geogToProj=v;z.projGeog=function(U,g,G,F){switch(F){case e.PE_TRANSFORM_P_TO_G:return Q(U,g,G);case e.PE_TRANSFORM_G_TO_P:return v(U,g,G)}return 0};
z.projToGeog=Q;z.projToGeogCenter=S})(a.PeCSTransformations||(a.PeCSTransformations={}));var e;(function(z){z.init=function(){z.PE_BUFFER_MAX=a._pe.PeDefs.prototype.PE_BUFFER_MAX;z.PE_NAME_MAX=a._pe.PeDefs.prototype.PE_NAME_MAX;z.PE_MGRS_MAX=a._pe.PeDefs.prototype.PE_MGRS_MAX;z.PE_USNG_MAX=a._pe.PeDefs.prototype.PE_USNG_MAX;z.PE_DD_MAX=a._pe.PeDefs.prototype.PE_DD_MAX;z.PE_DDM_MAX=a._pe.PeDefs.prototype.PE_DDM_MAX;z.PE_DMS_MAX=a._pe.PeDefs.prototype.PE_DMS_MAX;z.PE_UTM_MAX=a._pe.PeDefs.prototype.PE_UTM_MAX;
z.PE_PARM_MAX=a._pe.PeDefs.prototype.PE_PARM_MAX;z.PE_TYPE_NONE=a._pe.PeDefs.prototype.PE_TYPE_NONE;z.PE_TYPE_GEOGCS=a._pe.PeDefs.prototype.PE_TYPE_GEOGCS;z.PE_TYPE_PROJCS=a._pe.PeDefs.prototype.PE_TYPE_PROJCS;z.PE_TYPE_GEOGTRAN=a._pe.PeDefs.prototype.PE_TYPE_GEOGTRAN;z.PE_TYPE_COORDSYS=a._pe.PeDefs.prototype.PE_TYPE_COORDSYS;z.PE_TYPE_UNIT=a._pe.PeDefs.prototype.PE_TYPE_UNIT;z.PE_STR_OPTS_NONE=a._pe.PeDefs.prototype.PE_STR_OPTS_NONE;z.PE_STR_AUTH_NONE=a._pe.PeDefs.prototype.PE_STR_AUTH_NONE;z.PE_STR_AUTH_TOP=
a._pe.PeDefs.prototype.PE_STR_AUTH_TOP;z.PE_STR_NAME_CANON=a._pe.PeDefs.prototype.PE_STR_NAME_CANON;z.PE_PARM_X0=a._pe.PeDefs.prototype.PE_PARM_X0;z.PE_PARM_ND=a._pe.PeDefs.prototype.PE_PARM_ND;z.PE_TRANSFORM_1_TO_2=a._pe.PeDefs.prototype.PE_TRANSFORM_1_TO_2;z.PE_TRANSFORM_2_TO_1=a._pe.PeDefs.prototype.PE_TRANSFORM_2_TO_1;z.PE_TRANSFORM_P_TO_G=a._pe.PeDefs.prototype.PE_TRANSFORM_P_TO_G;z.PE_TRANSFORM_G_TO_P=a._pe.PeDefs.prototype.PE_TRANSFORM_G_TO_P;z.PE_HORIZON_RECT=a._pe.PeDefs.prototype.PE_HORIZON_RECT;
z.PE_HORIZON_POLY=a._pe.PeDefs.prototype.PE_HORIZON_POLY;z.PE_HORIZON_LINE=a._pe.PeDefs.prototype.PE_HORIZON_LINE;z.PE_HORIZON_DELTA=a._pe.PeDefs.prototype.PE_HORIZON_DELTA}})(e=a.PeDefs||(a.PeDefs={}));(function(z){function v(g,G){var F=null,l=S[g];l||(l={},S[g]=l);l.hasOwnProperty(String(G))?F=l[G]:(g=a._pe.PeFactory.prototype.factoryByType(g,G),a._pe.compare(g,a._pe.NULL)||(F=g,l[G]=F));return F=Q(F)}function Q(g){if(g){var G=g.getType();switch(G){case e.PE_TYPE_GEOGCS:g=a._pe.castObject(g,a._pe.PeGeogcs);
break;case e.PE_TYPE_PROJCS:g=a._pe.castObject(g,a._pe.PeProjcs);break;case e.PE_TYPE_GEOGTRAN:g=a._pe.castObject(g,a._pe.PeGeogtran);break;default:G&e.PE_TYPE_UNIT&&(g=a._pe.castObject(g,a._pe.PeUnit))}}return g}var S={},U={};z.initialize=function(){a._pe.PeFactory.prototype.initialize(null)};z.coordsys=function(g){return v(e.PE_TYPE_COORDSYS,g)};z.factoryByType=v;z.fromString=function(g,G){var F=null,l=U[g];l||(l={},U[g]=l);l.hasOwnProperty(G)?F=l[G]:(g=a._pe.PeFactory.prototype.fromString(g,G),
a._pe.compare(g,a._pe.NULL)||(F=g,l[G]=F));return F=Q(F)};z.geogcs=function(g){return v(e.PE_TYPE_GEOGCS,g)};z.geogtran=function(g){return v(e.PE_TYPE_GEOGTRAN,g)};z.getCode=function(g){return a._pe.PeFactory.prototype.getCode(g)};z.projcs=function(g){return v(e.PE_TYPE_PROJCS,g)};z.unit=function(g){return v(e.PE_TYPE_UNIT,g)}})(a.PeFactory||(a.PeFactory={}));a.PeGCSExtent=null;var b;(function(z){var v;z.init=function(){z.PE_GTLIST_OPTS_COMMON=a._pe.PeGTlistExtended.prototype.PE_GTLIST_OPTS_COMMON;
v=a._pe._pe_getPeGTlistExtendedEntrySize()};z.getGTlist=function(Q,S,U,g,G,F){var l=null,E=new a._pe.PeInteger(F);try{var R=a._pe.PeGTlistExtended.prototype.getGTlist(Q,S,U,g,G,E);if(F=E.val)if(l=[R],1<F){var aa=a._pe.getPointer(R);for(Q=1;Q<F;Q++)l.push(a._pe.wrapPointer(aa+v*Q,a._pe.PeGTlistExtendedEntry))}}finally{a._pe.destroy(E)}return l}})(b=a.PeGTlistExtended||(a.PeGTlistExtended={}));(function(z){z.destroy=function(v){if(v&&v.length){for(var Q=0;Q<v.length;Q++){var S=v[Q];B(S);S.getEntries().forEach(function(U){B(U);
U=U.getGeogtran();B(U);U.getParameters().forEach(B);[U.getGeogcs1(),U.getGeogcs2()].forEach(function(g){B(g);var G=g.getDatum();B(G);B(G.getSpheroid());B(g.getPrimem());B(g.getUnit())})})}a._pe.PeGTlistExtendedEntry.prototype.Delete(v[0])}}})(a.PeGTlistExtendedEntry||(a.PeGTlistExtendedEntry={}));(function(z){z.geogToGeog=function(v,Q,S,U,g){a._pe.ensureCache.prepare();var G=m(S),F=S===G;G=a._pe.ensureFloat64(G);var l=0;U&&(l=a._pe.ensureFloat64(U));(v=a._pe._pe_geog_to_geog(a._pe.getPointer(v),Q,
G,l,g))&&y(S,Q,G,F);return v}})(a.PeGTTransformations||(a.PeGTTransformations={}));(function(z){function v(S,U,g,G,F,l){a._pe.ensureCache.prepare();switch(S){case "dd":var E=a._pe._pe_geog_to_dd;var R=e.PE_DD_MAX;break;case "ddm":E=a._pe._pe_geog_to_ddm;R=e.PE_DDM_MAX;break;case "dms":E=a._pe._pe_geog_to_dms,R=e.PE_DMS_MAX}S=0;U&&(S=a._pe.getPointer(U));U=m(G);U=a._pe.ensureFloat64(U);R=C(g,R);G=a._pe.ensureInt32(R);if(F=E(S,g,U,F,G))for(E=0;E<g;E++)l[E]=a._pe.UTF8ToString(R[E]);return F}function Q(S,
U,g,G,F){a._pe.ensureCache.prepare();switch(S){case "dd":var l=a._pe._pe_dd_to_geog;break;case "ddm":l=a._pe._pe_ddm_to_geog;break;case "dms":l=a._pe._pe_dms_to_geog}S=0;U&&(S=a._pe.getPointer(U));U=G.map(function(E){return a._pe.ensureString(E)});G=a._pe.ensureInt32(U);U=a._pe.ensureFloat64(Array(2*g));(l=l(S,g,G,U))&&y(F,g,U);return l}z.geog_to_dms=function(S,U,g,G,F){return v("dms",S,U,g,G,F)};z.dms_to_geog=function(S,U,g,G){return Q("dms",S,U,g,G)};z.geog_to_ddm=function(S,U,g,G,F){return v("ddm",
S,U,g,G,F)};z.ddm_to_geog=function(S,U,g,G){return Q("ddm",S,U,g,G)};z.geog_to_dd=function(S,U,g,G,F){return v("dd",S,U,g,G,F)};z.dd_to_geog=function(S,U,g,G){return Q("dd",S,U,g,G)}})(a.PeNotationDms||(a.PeNotationDms={}));var q;(function(z){z.init=function(){z.PE_MGRS_STYLE_NEW=a._pe.PeNotationMgrs.prototype.PE_MGRS_STYLE_NEW;z.PE_MGRS_STYLE_OLD=a._pe.PeNotationMgrs.prototype.PE_MGRS_STYLE_OLD;z.PE_MGRS_STYLE_AUTO=a._pe.PeNotationMgrs.prototype.PE_MGRS_STYLE_AUTO;z.PE_MGRS_180_ZONE_1_PLUS=a._pe.PeNotationMgrs.prototype.PE_MGRS_180_ZONE_1_PLUS;
z.PE_MGRS_ADD_SPACES=a._pe.PeNotationMgrs.prototype.PE_MGRS_ADD_SPACES};z.geog_to_mgrs_extended=function(v,Q,S,U,g,G,F){a._pe.ensureCache.prepare();var l=0;v&&(l=a._pe.getPointer(v));v=m(S);S=a._pe.ensureFloat64(v);v=C(Q,e.PE_MGRS_MAX);var E=a._pe.ensureInt32(v);if(U=a._pe._pe_geog_to_mgrs_extended(l,Q,S,U,g,G,E))for(g=0;g<Q;g++)F[g]=a._pe.UTF8ToString(v[g]);return U};z.mgrs_to_geog_extended=function(v,Q,S,U,g){a._pe.ensureCache.prepare();var G=0;v&&(G=a._pe.getPointer(v));v=S.map(function(F){return a._pe.ensureString(F)});
S=a._pe.ensureInt32(v);v=a._pe.ensureFloat64(Array(2*Q));(U=a._pe._pe_mgrs_to_geog_extended(G,Q,S,U,v))&&y(g,Q,v);return U}})(q=a.PeNotationMgrs||(a.PeNotationMgrs={}));(function(z){z.geog_to_usng=function(v,Q,S,U,g,G,F){a._pe.ensureCache.prepare();var l=0;v&&(l=a._pe.getPointer(v));v=m(S);S=a._pe.ensureFloat64(v);v=C(Q,e.PE_MGRS_MAX);var E=a._pe.ensureInt32(v);if(U=a._pe._pe_geog_to_usng(l,Q,S,U,g,G,E))for(g=0;g<Q;g++)F[g]=a._pe.UTF8ToString(v[g]);return U};z.usng_to_geog=function(v,Q,S,U){a._pe.ensureCache.prepare();
var g=0;v&&(g=a._pe.getPointer(v));v=S.map(function(G){return a._pe.ensureString(G)});S=a._pe.ensureInt32(v);v=a._pe.ensureFloat64(Array(2*Q));(g=a._pe._pe_usng_to_geog(g,Q,S,v))&&y(U,Q,v);return g}})(a.PeNotationUsng||(a.PeNotationUsng={}));var K;(function(z){z.init=function(){z.PE_UTM_OPTS_NONE=a._pe.PeNotationUtm.prototype.PE_UTM_OPTS_NONE;z.PE_UTM_OPTS_ADD_SPACES=a._pe.PeNotationUtm.prototype.PE_UTM_OPTS_ADD_SPACES;z.PE_UTM_OPTS_NS=a._pe.PeNotationUtm.prototype.PE_UTM_OPTS_NS};z.geog_to_utm=function(v,
Q,S,U,g){a._pe.ensureCache.prepare();var G=0;v&&(G=a._pe.getPointer(v));v=m(S);S=a._pe.ensureFloat64(v);v=C(Q,e.PE_UTM_MAX);var F=a._pe.ensureInt32(v);if(U=a._pe._pe_geog_to_utm(G,Q,S,U,F))for(G=0;G<Q;G++)g[G]=a._pe.UTF8ToString(v[G]);return U};z.utm_to_geog=function(v,Q,S,U,g){a._pe.ensureCache.prepare();var G=0;v&&(G=a._pe.getPointer(v));v=S.map(function(F){return a._pe.ensureString(F)});S=a._pe.ensureInt32(v);v=a._pe.ensureFloat64(Array(2*Q));(U=a._pe._pe_utm_to_geog(G,Q,S,U,v))&&y(g,Q,v);return U}})(K=
a.PeNotationUtm||(a.PeNotationUtm={}));var M;(function(z){var v=new Map;z.init=function(){z.PE_PCSINFO_OPTION_NONE=a._pe.PePCSInfo.prototype.PE_PCSINFO_OPTION_NONE;z.PE_PCSINFO_OPTION_DOMAIN=a._pe.PePCSInfo.prototype.PE_PCSINFO_OPTION_DOMAIN;z.PE_POLE_OUTSIDE_BOUNDARY=a._pe.PePCSInfo.prototype.PE_POLE_OUTSIDE_BOUNDARY;z.PE_POLE_POINT=a._pe.PePCSInfo.prototype.PE_POLE_POINT};z.generate=function(Q,S){void 0===S&&(S=z.PE_PCSINFO_OPTION_DOMAIN);var U;if(v.has(Q)){var g=v.get(Q);g[S]&&(U=g[S])}U||(U=a._pe.PePCSInfo.prototype.generate(Q,
S),g||(g=[],v.set(Q,g)),g[S]=U);return U}})(M=a.PePCSInfo||(a.PePCSInfo={}));(function(z){z.version_string=function(){return a._pe.PeVersion.prototype.version_string()}})(a.PeVersion||(a.PeVersion={}));a._init=n})},"esri/core/tsSupport/extendsHelper":function(){define([],function(){return function(){var D=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,d){a.__proto__=d}||function(a,d){for(var c in d)d.hasOwnProperty(c)&&(a[c]=d[c])};return function(a,d){function c(){this.constructor=
a}D(a,d);a.prototype=null===d?Object.create(d):(c.prototype=d.prototype,new c)}}()})},"esri/geometry/GeographicTransformation":function(){define(["require","exports","./GeographicTransformationStep"],function(D,a,d){return function(){function c(w){this.steps=[];this._cached_projection={};this._chain="";this._gtlistentry=null;if(w&&w.steps){var n=0;for(w=w.steps;n<w.length;n++){var B=w[n];B instanceof d?this.steps.push(B):this.steps.push(new d({wkid:B.wkid,wkt:B.wkt,isInverse:B.isInverse}))}}}c.cacheKey=
function(w,n){return[void 0!==w.wkid&&null!==w.wkid?w.wkid.toString():"-1",void 0!==w.wkt&&null!==w.wkt?w.wkt.toString():"",void 0!==n.wkid&&null!==n.wkid?n.wkid.toString():"-1",void 0!==n.wkt&&null!==n.wkt?n.wkt.toString():""].join()};c.fromGE=function(w){var n=new c,B="",C=0;for(w=w.steps;C<w.length;C++){var m=d.fromGE(w[C]);n.steps.push(m);B+=m.uid.toString()+","}n._cached_projection={};n._gtlistentry=null;n._chain=B;return n};c.prototype.getInverse=function(){var w=new c;w.steps=[];for(var n=
this.steps.length-1;0<=n;n--)w.steps.push(this.steps[n].getInverse());return w};c.prototype.getGTListEntry=function(){for(var w="",n=0,B=this.steps;n<B.length;n++)w+=B[n].uid.toString()+",";w!==this._chain&&(this._gtlistentry=null,this._cached_projection={},this._chain=w);return this._gtlistentry};c.prototype.assignCachedGe=function(w,n,B){this._cached_projection[c.cacheKey(w,n)]=B};c.prototype.getCachedGeTransformation=function(w,n){for(var B="",C=0,m=this.steps;C<m.length;C++)B+=m[C].uid.toString()+
",";B!==this._chain&&(this._gtlistentry=null,this._cached_projection={},this._chain=B);w=this._cached_projection[c.cacheKey(w,n)];return void 0===w?null:w};return c}()})},"esri/geometry/GeographicTransformationStep":function(){define(["require","exports"],function(D,a){var d=0;return function(){function c(w){void 0===w&&(w=null);this.uid=d++;w?(this._wkt=void 0!==w.wkt?w.wkt:null,this._wkid=void 0!==w.wkid?w.wkid:-1,this._isInverse=void 0!==w.isInverse?!0===w.isInverse:!1):(this._wkt=null,this._wkid=
-1,this._isInverse=!1)}c.fromGE=function(w){var n=new c;n._wkt=w.wkt;n._wkid=w.wkid;n._isInverse=w.isInverse;return n};Object.defineProperty(c.prototype,"wkt",{get:function(){return this._wkt},set:function(w){this._wkt=w;this.uid=d++},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"wkid",{get:function(){return this._wkid},set:function(w){this._wkid=w;this.uid=d++},enumerable:!0,configurable:!0});Object.defineProperty(c.prototype,"isInverse",{get:function(){return this._isInverse},
set:function(w){this._isInverse=w;this.uid=d++},enumerable:!0,configurable:!0});c.prototype.getInverse=function(){var w=new c;w._wkt=this.wkt;w._wkid=this._wkid;w._isInverse=!this.isInverse;return w};return c}()})},"jimu/dijit/Report":function(){define("dojo/_base/declare jimu/BaseWidget jimu/utils dojo/Evented ./PageUtils dojo/text!./templates/ReportTemplate.html dojo/_base/lang dojo/_base/array dojo/_base/window dojo/dom-construct dojo/dom-class dojo/dom-style dojo/dom dojo/string dojo/on esri/tasks/PrintParameters esri/tasks/PrintTemplate esri/tasks/PrintTask dijit/focus dojo/query dojo/dom-attr".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U){return D([a,c],{baseClass:"jimu-report",_printService:null,_printWindow:null,_sizeInPixels:{},_windowOpenedTimer:null,_shownUnableToPrintMapMsg:!1,printTaskUrl:null,reportLogo:"",reportLayout:{},maxNoOfCols:3,styleSheets:[],styleText:"",constructor:function(){this.inherited(arguments);this._sizeInPixels={};this.printTaskUrl=null;this.reportLayout={};this.styleSheets=[]},postMixInProperties:function(){this.nls=B.mixin(window.jimuNls.common,window.jimuNls.report)},
postCreate:function(){var g={pageSize:w.PageSizes.A4,orientation:w.Orientation.Portrait};this.inherited(arguments);this.setReportLayout(this.reportLayout,g);this.reportLayout.dpi=96;this.printTaskUrl&&this._createPrintTask()},setReportLayout:function(g,G){G||(G=this.reportLayout);this._validateParameters(g)?this.reportLayout=B.mixin(G,g):this.reportLayout=G},setMapLayout:function(g){var G=this.reportLayout.pageSize.MapLayout?this.reportLayout.pageSize.MapLayout:"MAP_ONLY";if("MAP_ONLY"===G)g.exportOptions=
{dpi:this.reportLayout.dpi},this.reportLayout.orientation.Type===w.Orientation.Landscape.Type&&this.reportLayout.pageSize!==w.PageSizes.Custom?(g.exportOptions.width=this._sizeInPixels.Height,g.exportOptions.height=this._sizeInPixels.Width):(g.exportOptions.width=this._sizeInPixels.Width,g.exportOptions.height=this._sizeInPixels.Height);else if(G&&w.PageSizes[G])G+=" "+this.reportLayout.orientation.Type;else{var F=[];Object.keys(w.PageSizes).forEach(function(l){F.push(w.PageSizes[l].MapLayout)});
-1<F.indexOf(G)&&(G+=" "+this.reportLayout.orientation.Type)}g.layout=G;return g},_validateParameters:function(){return this.reportLayout.pageSize!==w.PageSizes.Custom||this.reportLayout.size?!0:!1},_createPrintTask:function(){this._printService=new v(this.printTaskUrl,{async:!1})},_createPrintMapParameters:function(g){var G=new z;if(g.printTemplate)if(G=g.printTemplate,G.format){var F=G.format.toLowerCase();"png32"!==F&&"png8"!==F&&"jpg"!==F&&"gif"!==F&&(G.format="jpg")}else G.format="jpg";else G=
this.setMapLayout(G),G.layoutOptions={customTextElements:[{Date:""}]},G.preserveScale=!0,G.showAttribution=!0,G.format="jpg";F=new M;F.map=g.map;F.template=G;return F},print:function(g,G){if(this._printService){this._shownUnableToPrintMapMsg=!1;var F=screen.width/2;var l=screen.height/1.5;F=11===d.has("ie")?"toolbar\x3dno, location\x3dno, directories\x3dno, status\x3dyes, menubar\x3dno,scrollbars\x3dyes, resizable\x3dyes, width\x3d"+F+", height\x3d"+l+", top\x3d"+(screen.height/2-l/2)+", left\x3d"+
(screen.width/2-F/2):null;l=d.detectUserAgent();(l.browser.hasOwnProperty("firefox")&&l.browser.firefox||l.os.hasOwnProperty("ipad")&&l.os.ipad||l.os.hasOwnProperty("iphone")&&l.os.iphone)&&this._printWindow&&this._printWindow.close();this._printWindow=window.open("","_blank",F,!1);this._windowOpenedTimer&&clearInterval(this._windowOpenedTimer);this._windowOpenedTimer=setInterval(B.hitch(this,function(){this._printWindow.closed&&(clearInterval(this._windowOpenedTimer),this.emit("report-window-closed"))}),
500);this._printWindow.focus();setTimeout(B.hitch(this,function(){m.withDoc(this._printWindow.document,B.hitch(this,function(){this._printWindow.document.open("text/html","replace");this._printWindow.document.write(n);window.isRTL&&I.add(b.byId("reportBody"),"jimu-rtl");(this.styleSheets&&0<this.styleSheets.length||this.styleText&&""!==this.styleText)&&this._addExternalStyleSheets();this._setPageSize();this._setButtonLabels();this._setReportSizeMessage();this._setReportLogo();this._setReportTitle(g);
this._setReportData(G);this._setFootNotes();this._setAccessibility();this._printWindow.document.close()}))}),500)}else this.emit("reportError")},_addExternalStyleSheets:function(){var g=b.byId("reportHead");g&&(C.forEach(this.styleSheets,B.hitch(this,function(G){y.create("link",{rel:"stylesheet",type:"text/css",href:G},g)})),this.styleText&&y.create("style",{type:"text/css",innerHTML:this.styleText},g))},_setPageSize:function(){var g=b.byId("reportMain");if(this.reportLayout){var G=this.reportLayout.pageSize;
this.reportLayout.pageSize===w.PageSizes.Custom&&this.reportLayout.size&&(G=this.reportLayout.size);G=w.getPageSizeInPixels(G,this.reportLayout.dpi)}var F=this.reportLayout.orientation.Type===w.Orientation.Landscape.Type&&this.reportLayout.pageSize!==w.PageSizes.Custom?G.Height:G.Width;this._sizeInPixels=G;e.set(g,{width:F+"px"})},_setReportData:function(g){var G=b.byId("reportData"),F=b.byId("showErrorButton");F.innerHTML=this.nls.unableToPrintMapMsg;G&&C.forEach(g,B.hitch(this,function(l){var E=
y.create("div",{},G);l.addPageBreak&&I.add(E,"esriCTPageBreak");"table"===l.type?this._formatAndRenderTables(E,l):"html"===l.type?this._renderHTMLData(E,l):"map"===l.type?(l.title&&this._addSectionTitle(l.title,E),I.add(E,"esriCTReportMap esriCTReportMapWait"),l.extent&&l.data.map.setExtent(l.extent),this._executePrintTask(l,E,F)):"note"===l.type&&this._createReportNote(E,l)}))},_setFootNotes:function(){var g;if((g=b.byId("footNotes"))&&this.footNotes){var G=d.sanitizeHTML(this.footNotes?this.footNotes:
"");g.innerHTML=d.fieldFormatter.getFormattedUrl(G)}},_setReportLogo:function(){var g;if((g=b.byId("reportLogo"))&&this.reportLogo){I.remove(g,"esriCTHidden");g.src=this.reportLogo;U.set(g,"alt",this.nls.image);var G=b.byId("reportHeader");var F=b.byId("reportMain");var l=b.byId("printTitleDiv");window.isRTL&&y.place(l,G,"first");F&&l&&(g.complete&&e.set(l,{width:F.clientWidth-g.clientWidth-51+"px"}),this.own(K(g,"load",B.hitch(this,function(){setTimeout(B.hitch(this,function(){e.set(l,{width:F.clientWidth-
g.clientWidth-51+"px"})}),300)}))))}},_setReportTitle:function(g){var G=b.byId("reportTitle");G&&g&&(G.value=g);U.set(G,"aria-label",this.nls.title)},_createReportNote:function(g,G){var F="";G.title&&(F=G.title);F=this._addSectionTitle(F,g);I.add(F,"esriCTNotesTitle");var l=y.create("textarea",{"class":"esriCTReportNotes",placeholder:this.nls.notesHint,rows:5,tabindex:"0",role:"textbox","aria-label":this.nls.notesHint},g);var E=y.create("p",{"class":"esriCTReportNotesParagraph"},g);I.add(g,"esriCTNotesContainer");
G.defaultText&&(l.value=G.defaultText);this.own(K(l,"keydown, change",function(){l.style.height="auto";E.innerHTML=d.sanitizeHTML(l.value?l.value:"");l.style.height=l.scrollHeight+"px"}))},_setReportSizeMessage:function(){if(this.reportLayout.pageSize===w.PageSizes.Custom&&this.reportLayout.size){var g=this.reportLayout.size;var G=this.reportLayout.pageSize}else g=this.reportLayout.pageSize,G=this.reportLayout.pageSize.SizeName?this.reportLayout.pageSize.SizeName:this.reportLayout.SizeName;g=this.reportLayout.orientation.Type===
w.Orientation.Landscape.Type&&this.reportLayout.pageSize!==w.PageSizes.Custom?" ("+g.Height+"'' X "+g.Width+"'') ":" ("+g.Width+"'' X "+g.Height+"'') ";b.byId("reportBarMsg").innerHTML=q.substitute(this.nls.reportDimensionsMsg,{paperSize:G+g+this.reportLayout.orientation.Text})},_setButtonLabels:function(){var g=b.byId("printButton");g.innerHTML=this.nls.printButtonLabel;g.title=this.nls.printButtonLabel;g=b.byId("closeButton");g.innerHTML=this.nls.close;g.title=this.nls.close},_executePrintTask:function(g,
G,F){g=this._createPrintMapParameters(g);this._printService.execute(g,B.hitch(this,function(l){G&&(I.remove(G,"esriCTReportMapWait"),l=y.create("img",{src:l.url,"class":"esriCTReportMapImg","aria-label":this.nls.mapArea},G),this.reportLayout.orientation.Type===w.Orientation.Landscape.Type&&I.add(l,"esriCTReportLandscapeMapImg"));this.emit("report-export-task-completed")}),B.hitch(this,function(){I.replace(G,"esriCTReportMapFail","esriCTPageBreak esriCTReportMapWait");this._shownUnableToPrintMapMsg||
(this._shownUnableToPrintMapMsg=!0,F.click());this.emit("report-export-task-failed")}))},_renderHTMLData:function(g,G){g=y.create("div",{"class":"esriCTHTMLData"},g);G.title&&this._addSectionTitle(G.title,g);y.create("div",{innerHTML:G.data},g)},_addSectionTitle:function(g,G){g=d.sanitizeHTML(g?g:"");return y.create("div",{innerHTML:g,"class":g?"esriCTSectionTitle":""},G)},_formatAndRenderTables:function(g,G){var F=G.data,l,E=this.maxNoOfCols;F.maxNoOfCols&&(E=F.maxNoOfCols);F.cols.length>E&&2>=F.cols.length-
E&&(E=F.cols.length);var R=0;for(l=F.cols.length;R<l;R+=E){var aa={cols:[],rows:[]},W=R+E,da=!1;aa.title=0===R?G.title:"";var h=F.cols.length-W;2>=h&&0<h&&(W+=h,da=!0);h=F.cols.slice(R,W);var V=[];for(var T=0;T<F.rows.length;T++)V.push(F.rows[T].slice(R,W));aa.cols=h;aa.rows=V;this._renderTable(y.create("div",{},g),aa,G.data.showRowIndex);if(da)break}},_renderTable:function(g,G,F){this._addSectionTitle(G.title,g);g=y.create("table",{cellpadding:5,style:{width:"100%"},"class":"esriCTTable"},g);var l=
y.create("tbody",{},g);var E=y.create("tr",{},l);F&&y.create("th",{innerHTML:"#",style:{width:"20px"}},E);C.forEach(G.cols,B.hitch(this,function(R){y.create("th",{innerHTML:R},E)}));C.forEach(G.rows,B.hitch(this,function(R,aa){var W=y.create("tr",{},l);F&&y.create("td",{innerHTML:aa+1,style:{"word-wrap":"normal"}},W);C.forEach(R,B.hitch(this,function(da){da=d.fieldFormatter.getFormattedUrl(da);y.create("td",{innerHTML:da},W)}))}))},_setAccessibility:function(){this._setFirstFocusNode();this._setLastFocusNode();
this._focusFirstNodeOfReport()},_setFirstFocusNode:function(){var g=b.byId("reportTitle");""!==g&&null!==g&&void 0!==g&&d.initFirstFocusNode(this._printWindow.document,g)},_setLastFocusNode:function(){var g=S(".esriCTReportNotes",this._printWindow.document);""!==g&&null!==g&&void 0!==g&&0<g.length?d.initLastFocusNode(this._printWindow.document,g[0]):(g=S(".esriCTLocaleDateInputTitle",this._printWindow.document),""!==g&&null!==g&&void 0!==g&&0<g.length?d.initLastFocusNode(this._printWindow.document,
g[0]):(g=S(".esriCTAOIInputArea",this._printWindow.document),""!==g&&null!==g&&void 0!==g&&0<g.length&&d.initLastFocusNode(this._printWindow.document,g[0])))},_focusFirstNodeOfReport:function(){var g=b.byId("reportTitle");""!==g&&null!==g&&void 0!==g&&(Q.curNode&&Q.curNode.blur(),Q.focus(g))}})})},"jimu/dijit/PageUtils":function(){define([],function(){var D={};D.Orientation={Landscape:{Type:"Landscape",Text:window.jimuNls.report.landscape},Portrait:{Type:"Portrait",Text:window.jimuNls.report.portrait}};
D.PageSizes={A0:{Height:46.8,Width:33.1,SizeName:window.jimuNls.report.a0,MapLayout:"MAP_ONLY"},A1:{Height:33.1,Width:23.4,SizeName:window.jimuNls.report.a1,MapLayout:"MAP_ONLY"},A2:{Height:23.4,Width:16.5,SizeName:window.jimuNls.report.a2,MapLayout:"MAP_ONLY"},A3:{Height:16.5,Width:11.7,SizeName:window.jimuNls.report.a3,MapLayout:"A3"},A4:{Height:11.7,Width:8.3,SizeName:window.jimuNls.report.a4,MapLayout:"A4"},A5:{Height:8.3,Width:5.8,SizeName:window.jimuNls.report.a5,MapLayout:"MAP_ONLY"},Letter_ANSI_A:{Height:11,
Width:8.5,SizeName:window.jimuNls.report.letter+" "+window.jimuNls.report.ansi_a,MapLayout:"Letter ANSI A"},Tabloid_ANSI_B:{Height:17,Width:11,SizeName:window.jimuNls.report.tabloid+" "+window.jimuNls.report.ansi_b,MapLayout:"Tabloid ANSI B"},ANSI_C:{Height:22,Width:17,SizeName:window.jimuNls.report.ansi_c,MapLayout:"MAP_ONLY"},ANSI_D:{Height:34,Width:22,SizeName:window.jimuNls.report.ansi_d,MapLayout:"MAP_ONLY"},ANSI_E:{Height:44,Width:34,SizeName:window.jimuNls.report.ansi_e,MapLayout:"MAP_ONLY"},
Legal:{Height:14,Width:8.5,SizeName:window.jimuNls.report.legal,MapLayout:"MAP_ONLY"},Custom:window.jimuNls.common.custom};D.getPageSizeInPixels=function(a,d){return{Height:a.Height*d,Width:a.Width*d}};return D})},"esri/tasks/PrintParameters":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/has","../kernel"],function(D,a,d,c){D=D(null,{declaredClass:"esri.tasks.PrintParameters",map:null,template:null,outSpatialReference:null,extraParameters:null});d("extend-esri")&&a.setObject("tasks.PrintParameters",
D,c);return D})},"esri/tasks/PrintTemplate":function(){define(["dojo/_base/declare","dojo/_base/lang","dojo/has","../kernel"],function(D,a,d,c){D=D(null,{declaredClass:"esri.tasks.PrintTemplate",label:null,exportOptions:{width:800,height:1100,dpi:96},layoutOptions:null,format:"PNG32",layout:"MAP_ONLY",outScale:0,preserveScale:!0,forceFeatureAttributes:!1,showAttribution:null,showLabels:!0});d("extend-esri")&&a.setObject("tasks.PrintTemplate",D,c);return D})},"esri/tasks/PrintTask":function(){define("dojo/_base/declare dojo/_base/lang dojo/_base/array dojo/_base/json dojo/_base/Deferred dojo/has ../kernel ../lang ../layerUtils ../deferredUtils ../Color ../request ../urlUtils ../geometry/Polygon ../renderers/SimpleRenderer ../symbols/FillSymbol ./Geoprocessor ./PrintTemplate ./Task dojo/dom-attr dojo/dom-construct dojox/gfx/_base dojox/gfx/canvas dojox/json/query dojo/has!extend-esri?./PrintParameters dojo/has!extend-esri?./LegendLayer".split(" "),
function(D,a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U,g,G,F){D=D(Q,{declaredClass:"esri.tasks.PrintTask",constructor:function(l,E){this.url=l;this.printGp=new z(this.url);this._handler=a.hitch(this,this._handler);E&&E.async&&(this.async=!0);this._colorEvaluator=F("$..color")},async:!1,_vtlExtent:null,_cimVersion:null,_is11xService:!1,_loadGpServerMetadata:!0,execute:function(l,E,R){if(!this._loadGpServerMetadata)return this._execute(l,E,R);var aa=new w(y._dfdCanceller),W=this._url.path,da=W.lastIndexOf("/GPServer/");
0<da&&(W=W.slice(0,da+9));aa._pendingDfd=e({url:W,callbackParamName:"callback",content:a.mixin({},this._url.query,{f:"json"})}).then(a.hitch(this,function(h){this._loadGpServerMetadata=!1;this.async="esriExecutionTypeAsynchronous"===h.executionType;this._cimVersion=h.cimVersion;this._is11xService=!!this._cimVersion;aa._pendingDfd=this._execute(l);return aa._pendingDfd})).then(a.hitch(this,function(h){this._successHandler([h],null,E,aa)})).otherwise(function(h){R&&R(h);aa.errback(h)});return aa},_handler:function(l,
E,R,aa,W){try{if(this.async)"esriJobSucceeded"===l.jobStatus?this.printGp.getResultData(l.jobId,"Output_File",a.hitch(this,function(h){da=h.value;this._successHandler([da],"onComplete",R,W)})):this._errorHandler(Error(l.jobStatus),aa,W);else{var da=l[0].value;this._successHandler([da],"onComplete",R,W)}}catch(h){this._errorHandler(h,aa,W)}},_execute:function(l,E,R){var aa=this._handler,W=this._errorHandler,da=l.template||new v;da.hasOwnProperty("showLabels")||(da.showLabels=!0);var h=da.exportOptions,
V;h&&(V={outputSize:[h.width,h.height],dpi:h.dpi});h=da.layoutOptions;var T=[];if(h){this.legendAll=!1;h.legendLayers?d.forEach(h.legendLayers,function(ia){var ka={};ka.id=ia.layerId;ia.subLayerIds&&(ka.subLayerIds=ia.subLayerIds);T.push(ka)}):this.legendAll=!0;if("Miles"===h.scalebarUnit||"Kilometers"===h.scalebarUnit){var r="esriKilometers";var u="esriMiles"}else if("Meters"===h.scalebarUnit||"Feet"===h.scalebarUnit)r="esriMeters",u="esriFeet";var A={esriMiles:"mi",esriKilometers:"km",esriFeet:"ft",
esriMeters:"m"};A={titleText:h.titleText,authorText:h.authorText,copyrightText:h.copyrightText,customTextElements:h.customTextElements,scaleBarOptions:{metricUnit:r,metricLabel:A[r],nonMetricUnit:u,nonMetricLabel:A[u]},legendOptions:{operationalLayers:T}}}r=this._getPrintDefinition(l.map,da);l.outSpatialReference&&(r.mapOptions.spatialReference=l.outSpatialReference.toJson());l.template&&C.isDefined(l.template.showAttribution)&&(r.mapOptions.showAttribution=l.template.showAttribution);a.mixin(r,{exportOptions:V,
layoutOptions:A});this.allLayerslegend&&a.mixin(r.layoutOptions,{legendOptions:{operationalLayers:this.allLayerslegend}});if(r.operationalLayers){V=r.operationalLayers;var x=function(ia){return C.fixJson(a.mixin(ia,{type:"esriSLS",cap:void 0,join:void 0,meterLimit:void 0}))},H=/[\u4E00-\u9FFF\u0E00-\u0E7F\u0900-\u097F\u3040-\u309F\u30A0-\u30FF\u31F0-\u31FF]/,L=/[\u0600-\u06FF]/,Y=function(ia){var ka=ia.text,f=(ia=ia.font)&&ia.family&&ia.family.toLowerCase();ka&&ia&&("arial"===f||"arial unicode ms"===
f)&&(ia.family=H.test(ka)?"Arial Unicode MS":"Arial","normal"!==ia.style&&L.test(ka)&&(ia.family="Arial Unicode MS"))};for(A=0;A<V.length;A++)if(V[A].featureCollection&&V[A].featureCollection.layers)for(u=0;u<V[A].featureCollection.layers.length;u++){var ba=V[A].featureCollection.layers[u];if(ba.layerDefinition&&ba.layerDefinition.drawingInfo&&ba.layerDefinition.drawingInfo.renderer&&ba.layerDefinition.drawingInfo.renderer.symbol){var ca=ba.layerDefinition.drawingInfo.renderer;"esriCLS"===ca.symbol.type?
ca.symbol=x(ca.symbol):"esriTS"===ca.symbol.type?Y(ca.symbol):ca.symbol.outline&&"esriCLS"===ca.symbol.outline.type&&(ca.symbol.outline=x(ca.symbol.outline))}if(ba.featureSet&&ba.featureSet.features)for(h=0;h<ba.featureSet.features.length;h++)ca=ba.featureSet.features[h],ca.symbol&&("esriCLS"===ca.symbol.type?ca.symbol=x(ca.symbol):"esriTS"===ca.symbol.type?Y(ca.symbol):ca.symbol.outline&&"esriCLS"===ca.symbol.outline.type&&(ca.symbol.outline=x(ca.symbol.outline)))}}da={Web_Map_as_JSON:c.toJson(C.fixJson(r)),
Format:da.format,Layout_Template:da.layout};l.extraParameters&&(da=a.mixin(da,l.extraParameters));var fa=new w(y._dfdCanceller);l=function(ia,ka){aa(ia,ka,E,R,fa)};r=function(ia){W(ia,R,fa)};fa._pendingDfd=this.async?this.printGp.submitJob(da,l,null,r):this.printGp.execute(da,l,r);return fa},onComplete:function(){},_createMultipointLayer:function(){return{layerDefinition:{name:"multipointLayer",geometryType:"esriGeometryMultipoint",drawingInfo:{renderer:null}},featureSet:{geometryType:"esriGeometryMultipoint",
features:[]}}},_createPolygonLayer:function(){return{layerDefinition:{name:"polygonLayer",geometryType:"esriGeometryPolygon",drawingInfo:{renderer:null}},featureSet:{geometryType:"esriGeometryPolygon",features:[]}}},_createPointLayer:function(){return{layerDefinition:{name:"pointLayer",geometryType:"esriGeometryPoint",drawingInfo:{renderer:null}},featureSet:{geometryType:"esriGeometryPoint",features:[]}}},_createPolylineLayer:function(){return{layerDefinition:{name:"polylineLayer",geometryType:"esriGeometryPolyline",
drawingInfo:{renderer:null}},featureSet:{geometryType:"esriGeometryPolyline",features:[]}}},_convertSvgSymbol:function(l){if(!(8>=n("ie")||!l.path&&"image/svg+xml"!==l.contentType)){var E=G.createSurface(U.create("div"),1024,1024);var R="image/svg+xml"===l.contentType?E.createObject(G.Image,{src:"data:image/svg+xml;base64,"+l.imageData,width:g.pt2px(l.width),height:g.pt2px(l.height),x:0,y:0}):E.createObject(G.Path,l.path).setFill(l.color).setStroke(l.outline);"pendingRender"in E&&E._render(!0);var aa=
E.rawNode.getContext("2d"),W=Math.ceil(R.getBoundingBox().width),da=Math.ceil(R.getBoundingBox().height);R=aa.getImageData(R.getBoundingBox().x,R.getBoundingBox().y,W,da);aa.canvas.width=W;aa.canvas.height=da;aa.putImageData(R,0,0);aa=aa.canvas.toDataURL("image/png");l={type:"esriPMS",imageData:aa.substr(22,aa.length),angle:l.angle,contentType:"image/png",height:l.size?l.size:g.px2pt(da),width:l.size?W/da*l.size:g.px2pt(W),xoffset:l.xoffset,yoffset:l.yoffset};E.destroy();return l}},_convertSvgRenderer:function(l){"simple"===
l.type&&l.symbol&&(l.symbol.path||"image/svg+xml"===l.symbol.contentType)?l.symbol=this._convertSvgSymbol(l.symbol):"uniqueValue"===l.type?(l.defaultSymbol&&(l.defaultSymbol.path||"image/svg+xml"===l.defaultSymbol.contentType)&&(l.defaultSymbol=this._convertSvgSymbol(l.defaultSymbol)),l.uniqueValueInfos&&d.forEach(l.uniqueValueInfos,function(E){if(E.symbol.path||"image/svg+xml"===E.symbol.contentType)E.symbol=this._convertSvgSymbol(E.symbol)},this)):"classBreaks"===l.type&&(l.defaultSymbol&&(l.defaultSymbol.path||
"image/svg+xml"===l.defaultSymbol.contentType)&&(l.defaultSymbol=this._convertSvgSymbol(l.defaultSymbol)),l.classBreakInfos&&d.forEach(l.classBreakInfos,function(E){if(E.symbol.path||"image/svg+xml"===E.symbol.contentType)E.symbol=this._convertSvgSymbol(E.symbol)},this))},_createFeatureCollection:function(l,E,R,aa){var W=this._createPolygonLayer(),da=this._createPolylineLayer(),h=this._createPointLayer(),V=this._createMultipointLayer(),T=this._createPointLayer();T.layerDefinition.name="textLayer";
delete T.layerDefinition.drawingInfo;if("esri.layers.FeatureLayer"===l.declaredClass||"esri.layers.StreamLayer"===l.declaredClass)W.layerDefinition.name=da.layerDefinition.name=h.layerDefinition.name=V.layerDefinition.name=a.getObject("arcgisProps.title",!1,l)||l.name||l.id;var r=l.renderer&&"esri.renderer.SimpleRenderer"===l.renderer.declaredClass;if(!l.renderer||l.renderer.valueExpression||a.isFunction(l.renderer.attributeField))delete W.layerDefinition.drawingInfo,delete da.layerDefinition.drawingInfo,
delete h.layerDefinition.drawingInfo,delete V.layerDefinition.drawingInfo;else{var u=l.renderer.toJson({useLegacyRotationProperties:!0});if("temporal"===u.type){u={latestObservationRenderer:u.latestObservationRenderer,trackLinesRenderer:u.trackRenderer,observationAger:u.observationAger,renderer:u.observationRenderer};var A={};l._trackIdField&&(A.trackIdField=l._trackIdField);l._startTimeField&&(A.startTimeField=l._startTimeField);l._endTimeField&&(A.endTimeField=l._endTimeField);W.layerDefinition.drawingInfo=
u;W.layerDefinition.timeInfo=A;da.layerDefinition.drawingInfo=u;da.layerDefinition.timeInfo=A;h.layerDefinition.drawingInfo=u;h.layerDefinition.timeInfo=A;V.layerDefinition.drawingInfo=u;V.layerDefinition.timeInfo=A}else W.layerDefinition.drawingInfo.renderer=u,da.layerDefinition.drawingInfo.renderer=u,h.layerDefinition.drawingInfo.renderer=u,V.layerDefinition.drawingInfo.renderer=u}u=l.fields;u||!l.renderer||l.renderer.valueExpression||a.isFunction(l.renderer.attributeField)||("esri.renderer.ClassBreaksRenderer"===
l.renderer.declaredClass?(u=[{name:l.renderer.attributeField,type:"esriFieldTypeDouble"}],l.renderer.normalizationField&&u.push({name:l.renderer.normalizationField,type:"esriFieldTypeDouble"})):"esri.renderer.UniqueValueRenderer"===l.renderer.declaredClass&&(u=[{name:l.renderer.attributeField,type:"esriFieldTypeString"}],l.renderer.attributeField2&&u.push({name:l.renderer.attributeField2,type:"esriFieldTypeString"}),l.renderer.attributeField3&&u.push({name:l.renderer.attributeField3,type:"esriFieldTypeString"})));
u&&(W.layerDefinition.fields=u,da.layerDefinition.fields=u,h.layerDefinition.fields=u,V.layerDefinition.fields=u);u=l.graphics;l.isFeatureReductionActive&&l.isFeatureReductionActive()&&(u=l.getSingleGraphics());A=u.length;var x;for(x=0;x<A;x++){var H=u[x];if(!1!==H.visible&&H.geometry){var L=H.toJson();L.symbol&&L.symbol.outline&&L.symbol.outline.color&&L.symbol.outline.color[3]&&!this._is11xService&&(L.symbol.outline.color[3]=255);if(l.renderer&&!L.symbol&&(a.isFunction(l.renderer.attributeField)||
l.renderer.valueExpression||this._isFeatureCollectionRequired(l.renderer,l)||"esri.renderer.DotDensityRenderer"===l.renderer.declaredClass||R)){R=R||l.renderer;var Y=null;try{Y=R.getSymbol(H)}catch(ba){}if(!Y)continue;L.symbol=Y.toJson();this._isFeatureCollectionRequired(R,l)&&this._applyVisualVariables(L.symbol,{renderer:R,graphic:H,symbol:Y,mapResolution:E&&E.getResolutionInMeters(),mapScale:E&&E.getScale()})}L.symbol&&(L.symbol.path||"image/svg+xml"===L.symbol.contentType?L.symbol=this._convertSvgSymbol(L.symbol):
L.symbol.text&&delete L.attributes);switch(H.geometry.type){case "polygon":W.featureSet.features.push(L);break;case "polyline":da.featureSet.features.push(L);break;case "point":L.symbol&&L.symbol.text?T.featureSet.features.push(L):h.featureSet.features.push(L);break;case "multipoint":V.featureSet.features.push(L);break;case "extent":L.geometry=q.fromExtent(H.geometry).toJson(),W.featureSet.features.push(L)}}}E=[];0<W.featureSet.features.length&&E.push(W);0<da.featureSet.features.length&&E.push(da);
0<V.featureSet.features.length&&E.push(V);0<h.featureSet.features.length&&E.push(h);0<T.featureSet.features.length&&E.push(T);if(!E.length)return null;d.forEach(E,function(ba){var ca=d.every(ba.featureSet.features,function(fa){return fa.symbol});if(r||ca)aa&&aa.forceFeatureAttributes||d.forEach(ba.featureSet.features,function(fa){delete fa.attributes}),aa.forceFeatureAttributes||delete ba.layerDefinition.fields;ca&&delete ba.layerDefinition.drawingInfo});d.forEach(E,function(ba){ba.layerDefinition.drawingInfo&&
ba.layerDefinition.drawingInfo.renderer&&this._convertSvgRenderer(ba.layerDefinition.drawingInfo.renderer)},this);return{id:l.id,opacity:l.opacity,minScale:l.minScale||0,maxScale:l.maxScale||0,featureCollection:{layers:E}}},_getPrintDefinition:function(l,E){var R={operationalLayers:this._createOperationalLayers(l,E)},aa=this._vtlExtent||l.extent,W=l.spatialReference;this._vtlExtent=null;l.spatialReference._isWrappable()&&(aa=aa._normalize(!0),W=aa.spatialReference);aa={mapOptions:{showAttribution:l.showAttribution,
extent:aa.toJson(),spatialReference:W.toJson()}};E.preserveScale&&a.mixin(aa.mapOptions,{scale:E.outScale||l.getScale()});l.timeExtent&&a.mixin(aa.mapOptions,{time:[l.timeExtent.startTime.getTime(),l.timeExtent.endTime.getTime()]});l={};a.mixin(l,aa,R);return l},_createOperationalLayers:function(l,E){var R,aa=[],W=0;E.preserveScale&&(W=E.outScale||l.getScale());this.allLayerslegend=this.legendAll?[]:null;this._vtlExtent=null;var da=d.map(l.layerIds,l.getLayer,l);l._mapImageLyr&&da.push(l._mapImageLyr);
for(R=0;R<da.length;R++){var h=da[R];if(h.loaded&&h.visible&&(!W||h.isVisibleAtScale(W))){var V=h.declaredClass;var T={id:h.id,title:a.getObject("arcgisProps.title",!1,h)||h.id,opacity:h.opacity,minScale:h.minScale||0,maxScale:h.maxScale||0};T=a.mixin(T,this._getUrlAndToken(h));h.getNode()&&S.get(h.getNode(),"data-reference")&&(T._isRefLayer=!0);switch(V){case "esri.layers.ArcGISDynamicMapServiceLayer":var r=[];V=!!h._params.layers;if(h._params.dynamicLayers)V=E.outScale?h._getDynLayerObjs(E.outScale):
c.fromJson(h._params.dynamicLayers),d.forEach(V,function(L){r.push({id:L.id,name:L.name,layerDefinition:L});delete L.id;delete L.name;delete L.maxScale;delete L.minScale}),0===r.length&&(T.visibleLayers=[-1]);else if(h.supportsDynamicLayers){if(V||h.layerDefinitions||h.layerTimeOptions){var u=h.createDynamicLayerInfosFromLayerInfos(),A=null;V&&(A=h.visibleLayers);A=m._getVisibleLayers(u,A);var x=m._getLayersForScale(E.outScale||l.getScale(),u);d.forEach(u,function(L){if(!L.subLayerIds){var Y=L.id;
-1<d.indexOf(A,Y)&&-1<d.indexOf(x,Y)&&(L={source:L.source.toJson()},h.layerDefinitions&&h.layerDefinitions[Y]&&(L.definitionExpression=h.layerDefinitions[Y]),h.layerTimeOptions&&h.layerTimeOptions[Y]&&(L.layerTimeOptions=h.layerTimeOptions[Y].toJson()),r.push({id:Y,layerDefinition:L}))}});0===r.length&&(T.visibleLayers=[-1])}}else d.forEach(h.layerInfos,function(L){var Y={id:L.id,layerDefinition:{}};h.layerDefinitions&&h.layerDefinitions[L.id]&&(Y.layerDefinition.definitionExpression=h.layerDefinitions[L.id]);
h.layerTimeOptions&&h.layerTimeOptions[L.id]&&(Y.layerDefinition.layerTimeOptions=h.layerTimeOptions[L.id].toJson());(Y.layerDefinition.definitionExpression||Y.layerDefinition.layerTimeOptions)&&r.push(Y)}),V&&(T.visibleLayers=h.visibleLayers.length?h.visibleLayers:[-1]);r.length&&(T.layers=r);aa.push(T);this.allLayerslegend&&this.allLayerslegend.push({id:h.id,subLayerIds:h.visibleLayers});break;case "esri.layers.ArcGISImageServiceLayer":T=a.mixin(T,{url:h.url,bandIds:h.bandIds,compressionQuality:h.compressionQuality,
format:h.format,interpolation:h.interpolation});h.mosaicRule&&a.mixin(T,{mosaicRule:h.mosaicRule.toJson()});if(h.renderingRule||h.renderer)this._is11xService?(h.renderingRule&&(T.renderingRule=h.renderingRule.toJson()),h.renderer&&(T.layerDefinition=T.layerDefinition||{},T.layerDefinition.drawingInfo=T.layerDefinition.drawingInfo||{},T.layerDefinition.drawingInfo.renderer=h.renderer.toJson())):(V=h.getExportImageRenderingRule())&&a.mixin(T,{renderingRule:V.toJson()});aa.push(T);this.allLayerslegend&&
this.allLayerslegend.push({id:h.id});break;case "esri.layers.RasterXLayer":this._is11xService&&(T=a.mixin(T,{url:h.url,bandIds:h.bandIds,interpolation:h.interpolation}),h.renderer&&(T.layerDefinition=T.layerDefinition||{},T.layerDefinition.drawingInfo=T.layerDefinition.drawingInfo||{},T.layerDefinition.drawingInfo.renderer=h.renderer.toJson()),aa.push(T),this.allLayerslegend&&this.allLayerslegend.push({id:h.id}));break;case "esri.layers.WMSLayer":T=a.mixin(T,{url:h.url,title:h.title,type:"wms",version:h.version,
transparentBackground:h.imageTransparency,visibleLayers:h.visibleLayers});aa.push(T);this.allLayerslegend&&this.allLayerslegend.push({id:h.id,subLayerIds:h.visibleLayers});break;case "esri.virtualearth.VETiledLayer":V=h.mapStyle;"roadOnDemand"===V?V="Road":"aerialWithLabelsOnDemand"===V&&(V="Hybrid");T=a.mixin(T,{visibility:h.visible,type:"BingMaps"+V,culture:h.culture,key:h.bingMapsKey});aa.push(T);break;case "esri.layers.OpenStreetMapLayer":T=a.mixin(T,{credits:h.copyright,type:"OpenStreetMap",
url:b.getAbsoluteUrl(h.tileServers[0])});aa.push(T);break;case "esri.layers.WMTSLayer":T=a.mixin(T,{url:h.url,type:"wmts",layer:h._identifier,style:h._style,format:h.format,tileMatrixSet:h._tileMatrixSetId});aa.push(T);break;case "esri.layers.MapImageLayer":V=h.getImages();d.forEach(V,function(L,Y){L.visible&&L.href&&(T={id:h.id+"_image"+Y,type:"image",title:h.id,minScale:h.minScale||0,maxScale:h.maxScale||0,opacity:h.opacity*L.opacity,extent:L.extent.toJson()},"data:image/png;base64,"===L.href.substr(0,
22)?T.imageData=L.href.substr(22):T.url=L.href,aa.push(T))});break;case "esri.layers.VectorTileLayer":delete T.url;delete T.token;if(this._is11xService&&h.currentStyleInfo.serviceUrl&&h.currentStyleInfo.styleUrl&&(V=B.id&&B.id.findCredential(h.currentStyleInfo.styleUrl),u=B.id&&B.id.findCredential(h.currentStyleInfo.serviceUrl),!V&&!u||"2.1.0"!==this._cimVersion)){T.type="VectorTileLayer";T.styleUrl=h.currentStyleInfo.styleUrl;V&&(T.token=V.token);u&&u.token!==T.token&&(T.additionalTokens=[{url:h.currentStyleInfo.serviceUrl,
token:u.token}]);aa.push(T);break}T.type="image";V=this._vtlExtent||l.extent.offset(0,0);var H=E.exportOptions&&E.exportOptions.dpi||96;u={format:"png",pixelRatio:H/96};"MAP_ONLY"!==E.layout||!E.preserveScale||E.outScale&&E.outScale!==l.getScale()||96!==H||!E.exportOptions||E.exportOptions.width%2===l.width%2&&E.exportOptions.height%2===l.height%2||(u.area={x:0,y:0,width:l.width,height:l.height},E.exportOptions.width%2!==l.width%2&&--u.area.width,E.exportOptions.height%2!==l.height%2&&--u.area.height,
this._vtlExtent||(H=l.toMap({x:u.area.width,y:u.area.height}),V.update(V.xmin,H.y,H.x,V.ymax,V.spatialReference),this._vtlExtent=V));T.extent=V._normalize(!0).toJson();V=h.takeScreenshot(u);V.isResolved()?V.then(function(L){"data:image/png;base64,"===L.dataURL.substr(0,22)&&(T.imageData=L.dataURL.substr(22))}):console.error("PrintTask: VectorTileLayer.takeScreenshot() returned an unresolved Promise");T.imageData&&aa.push(T);break;case "esri.layers.WebTiledLayer":V=h.url.replace(/\$\{/g,"{");T=a.mixin(T,
{type:"WebTiledLayer",urlTemplate:V,credits:h.copyright});h.subDomains&&0<h.subDomains.length&&(T.subDomains=h.subDomains);h._wmtsInfo&&(T.wmtsInfo=h._wmtsInfo);delete T.url;aa.push(T);break;default:if(h.getTileUrl||h.getImageUrl)T=a.mixin(T,{url:h.url}),aa.push(T)}}}da=d.map(l.graphicsLayerIds,l.getLayer,l);for(R=0;R<da.length;R++)h=da[R],h.isFeatureReductionActive&&h.isFeatureReductionActive()&&(h.getSingleGraphics().length?da.splice(++R,0,h.getFeatureReductionLayer()):da[R]=h.getFeatureReductionLayer());
for(R=0;R<da.length;R++)if(h=da[R],h.loaded&&h.visible&&(!W||h.isVisibleAtScale(W)))switch(V=h.declaredClass,V){case "esri.layers.CSVLayer":if(this._is11xService){T={id:h.id,url:h.url,title:h.title,opacity:h.opacity,minScale:h.minScale||0,maxScale:h.maxScale||0,type:"CSV",locationInfo:{latitudeFieldName:h.latitudeFieldName,longitudeFieldName:h.longitudeFieldName},layerDefinition:{drawingInfo:{renderer:h.renderer&&h.renderer.toJson({useLegacyRotationProperties:!0})}}};aa.push(T);break}case "esri.layers.FeatureLayer":case "esri.layers.LabelLayer":case "esri.layers.StreamLayer":if("esri.layers.LabelLayer"===
V&&!E.showLabels||h.renderer&&"esri.renderer.HeatmapRenderer"===h.renderer.declaredClass)continue;V=null;h.url&&h.renderer&&("esri.renderer.ScaleDependentRenderer"===h.renderer.declaredClass?"scale"===h.renderer.rangeType?V=h.renderer.getRendererInfoByScale(l.getScale())&&h.renderer.getRendererInfoByScale(l.getScale()).renderer:"zoom"===h.renderer.rangeType&&(V=h.renderer.getRendererInfoByZoom(l.getZoom())&&h.renderer.getRendererInfoByZoom(l.getZoom()).renderer):V=h.renderer);u=V&&"esri.layers.CSVLayer"!==
h.declaredClass&&!this._isFeatureCollectionRequired(V,h)&&!V.valueExpression;H=h.isFeatureReductionActive&&h.isFeatureReductionActive();if(V&&!H&&"esri.renderer.DotDensityRenderer"!==V.declaredClass&&"esri.layers.StreamLayer"!==h.declaredClass&&(this._is11xService||u)&&("esri.renderer.SimpleRenderer"===V.declaredClass||"esri.renderer.TemporalRenderer"===V.declaredClass||null==V.attributeField||a.isString(V.attributeField)&&h._getField(V.attributeField,!0)))if(T={id:h.id,title:a.getObject("arcgisProps.title",
!1,h)||h.id,opacity:h.opacity,minScale:h.minScale||0,maxScale:h.maxScale||0,layerDefinition:{drawingInfo:{renderer:V.toJson({useLegacyRotationProperties:!0})}}},T=a.mixin(T,this._getUrlAndToken(h)),"esri.renderer.TemporalRenderer"===V.declaredClass&&(u=T.layerDefinition.drawingInfo,u.latestObservationRenderer=u.renderer.latestObservationRenderer,u.trackLinesRenderer=u.renderer.trackRenderer,u.observationAger=u.renderer.observationAger,u.renderer=u.renderer.observationRenderer,h._trackIdField&&(T.layerDefinition.timeInfo=
{trackIdField:h._trackIdField})),this._convertSvgRenderer(T.layerDefinition.drawingInfo.renderer),this._is11xService||1>h.opacity||"esri.renderer.TemporalRenderer"===V.declaredClass||this._updateLayerOpacity(T))if(h._params.source&&(V=h._params.source.toJson(),a.mixin(T.layerDefinition,{source:V})),h.getDefinitionExpression()&&a.mixin(T.layerDefinition,{definitionExpression:h.getDefinitionExpression()}),2!==h.mode)0<h.getSelectedFeatures().length&&(V=d.map(h.getSelectedFeatures(),function(L){return L.attributes[h.objectIdField]}),
0<V.length&&h.getSelectionSymbol()&&a.mixin(T,{selectionObjectIds:V,selectionSymbol:h.getSelectionSymbol().toJson()}));else{V=d.map(h.getSelectedFeatures(),function(L){return L.attributes[h.objectIdField]});if(0===V.length||!h._params.drawMode)break;a.mixin(T.layerDefinition,{objectIds:V});V=null;h.getSelectionSymbol()&&(V=new K(h.getSelectionSymbol()));a.mixin(T.layerDefinition.drawingInfo,{renderer:V&&V.toJson()})}else T=this._createFeatureCollection(h,l,null,E);else T=V&&(V.valueExpression||this._isFeatureCollectionRequired(V,
h)||"esri.renderer.DotDensityRenderer"===V.declaredClass)?this._createFeatureCollection(h,l,V,E):this._createFeatureCollection(h,l,null,E);if(!T)continue;aa.push(T);this.allLayerslegend&&this.allLayerslegend.push({id:h.id});break;case "esri.layers._GraphicsLayer":case "esri.layers.GraphicsLayer":case "esri.layers.WFSLayer":T=this._createFeatureCollection(h,l,null,E);if(!T)continue;aa.push(T);this.allLayerslegend&&this.allLayerslegend.push({id:h.id});break;case "esri.layers.ArcGISImageServiceVectorLayer":T=
{id:h.id,title:a.getObject("arcgisProps.title",!1,h)||h.id,opacity:h.opacity,minScale:h.minScale||0,maxScale:h.maxScale||0,visibility:h.visible,symbolTileSize:h.symbolTileSize,layerDefinition:{drawingInfo:{renderer:h.renderer.toJson({useLegacyRotationProperties:!0})}}},T=a.mixin(T,this._getUrlAndToken(h)),h.mosaicRule&&a.mixin(T,{mosaicRule:h.mosaicRule.toJson()}),aa.push(T),this.allLayerslegend&&this.allLayerslegend.push({id:h.id})}W&&d.forEach(aa,function(L){L.minScale=0;L.maxScale=0});l.graphics&&
0<l.graphics.graphics.length&&(T=this._createFeatureCollection(l.graphics,l,null,E))&&aa.push(T);l._labels&&E.showLabels&&(T=this._createFeatureCollection(l._labels,l,null,E))&&aa.push(T);d.forEach(aa,function(L,Y,ba){L._isRefLayer&&(delete L._isRefLayer,ba.splice(Y,1),ba.push(L))});return aa},_getUrlAndToken:function(l){return{token:l._getToken(),url:l._url?l._url.path:null}},_updateLayerOpacity:function(l){var E=this._colorEvaluator(l);E=d.filter(E,function(da){return a.isArray(da)&&4===da.length});
var R=!0;if(E.length){var aa=E[0][3],W;for(W=1;W<E.length;W++)if(aa!==E[W][3]){R=!1;break}if(R)for(l.opacity=aa/255,W=0;W<E.length;W++)E[W][3]=255}return R},_isFeatureCollectionRequired:function(l,E){if(E&&E.isFeatureReductionActive&&E.isFeatureReductionActive())return!0;var R=!1;if(E=this._getVariable(l,"rotationInfo",!1))R=(R=E.field)&&a.isFunction(R)||E.valueExpression;return l.hasVisualVariables("sizeInfo")||l.hasVisualVariables("colorInfo")||l.hasVisualVariables("opacityInfo")||R},_getVariable:function(l,
E,R){if(l)var aa=(l=l.getVisualVariablesForType(E,R))&&l[0];return aa},_applyVisualVariables:function(l,E){var R=E.renderer,aa=E.graphic,W=E.symbol,da=E.mapResolution,h=E.mapScale,V=W.type;if("textsymbol"!==V&&"shieldlabelsymbol"!==V){var T=this._getVariable(R,"sizeInfo",!1),r=this._getVariable(R,"colorInfo",!1),u=this._getVariable(R,"opacityInfo",!1);E=this._getVariable(R,"rotationInfo",!1);W instanceof M&&(T=this._getVariable(R,"sizeInfo","outline")||T);da=T?R.getSize(aa,{sizeInfo:T,shape:"simplemarkersymbol"===
V?W.style:null,resolution:da,scale:h}):aa.size;null!=da&&("simplemarkersymbol"===V?l.size=g.px2pt(da):"picturemarkersymbol"===V?(h=W.width/W.height*da,l.width=g.px2pt(h),l.height=g.px2pt(da),0!==W.xoffset&&(l.xoffset=g.px2pt(W.xoffset/W.width*h)),0!==W.yoffset&&(l.yoffset=g.px2pt(W.yoffset/W.height*da))):"simplelinesymbol"===V?l.width=g.px2pt(da):l.outline&&(l.outline.width=g.px2pt(da)));r&&(!(W=R.getColor(aa,{colorInfo:r}))||"simplemarkersymbol"!==V&&"simplelinesymbol"!==V&&"simplefillsymbol"!==
V||(l.color=I.toJsonColor(W)));u&&(W=R.getOpacity(aa,{opacityInfo:u}),null!=W&&l.color&&(l.color[3]=Math.round(255*W)));E&&(R=R.getRotationAngle(aa,{rotationInfo:E}))&&(l.angle=-R)}}});n("extend-esri")&&a.setObject("tasks.PrintTask",D,B);return D})},"dojox/gfx/canvas":function(){define("./_base dojo/_base/lang dojo/_base/array dojo/_base/declare dojo/_base/window dojo/dom-geometry dojo/dom ./shape ./path ./arc ./matrix ./decompose ./bezierutils".split(" "),function(D,a,d,c,w,n,B,C,m,y,I,e,b){function q(r,
u,A,x,H,L,Y,ba,ca,fa){var ia=u.length,ka=0;if(fa){var f=fa.l/H;ka=fa.i}else f=u[0]/H;for(;L<Y;){if(L+f>Y){var J={l:(L+f-Y)*H,i:ka};f=Y-L}ka%2||(r.beginPath(),r.arc(A,x,H,L,L+f,ba),ca&&r.stroke());L+=f;++ka;f=u[ka%ia]/H}return J}function K(r,u,A,x){var H=0,L=0,Y=0;if(x){var ba=x.l;Y=x.i}else ba=u[0];for(;1>L;)L=b.tAtLength(r,ba),1==L&&(H=b.computeLength(r),H={l:ba-H,i:Y}),r=b.splitBezierAtT(r,L),Y%2||A.push(r[0]),r=r[1],++Y,ba=u[Y%u.length];return H}function M(r,u,A,x){var H=[u.last.x,u.last.y].concat(A),
L=!(r instanceof Array);A=4===A.length?"quadraticCurveTo":"bezierCurveTo";var Y=[];u=K(H,u.canvasDash,Y,x);for(x=0;x<Y.length;++x)H=Y[x],L?(r.moveTo(H[0],H[1]),r[A].apply(r,H.slice(2))):(r.push("moveTo",[H[0],H[1]]),r.push(A,H.slice(2)));return u}function z(r,u,A,x,H,L,Y){var ba=0,ca=0,fa=0,ia=b.distance(A,x,H,L),ka=0;u=u.canvasDash;var f=A,J=x,P=!(r instanceof Array);Y?(fa=Y.l,ka=Y.i):fa+=u[0];for(;.01<Math.abs(1-ca);){fa>ia&&(ba={l:fa-ia,i:ka},fa=ia);ca=fa/ia;Y=A+(H-A)*ca;var N=x+(L-x)*ca;ka++%
2||(P?(r.moveTo(f,J),r.lineTo(Y,N)):(r.push("moveTo",[f,J]),r.push("lineTo",[Y,N])));f=Y;J=N;fa+=u[ka%u.length]}return ba}var v=D.canvas={},Q=null,S=I.multiplyPoint,U=Math.PI,g=2*U,G=U/2;e=a.extend;if(w.global.CanvasRenderingContext2D){w=w.doc.createElement("canvas").getContext("2d");var F="function"==typeof w.setLineDash,l="function"==typeof w.fillText}var E={solid:"none",shortdash:[4,1],shortdot:[1,1],shortdashdot:[4,1,1,1],shortdashdotdot:[4,1,1,1,1,1],dot:[1,3],dash:[4,3],longdash:[8,3],dashdot:[4,
3,1,3],longdashdot:[8,3,1,3],longdashdotdot:[8,3,1,3,1,3]};v.Shape=c("dojox.gfx.canvas.Shape",C.Shape,{_render:function(r){r.save();this._renderTransform(r);this._renderClip(r);this._renderShape(r);this._renderFill(r,!0);this._renderStroke(r,!0);r.restore()},_renderClip:function(r){this.canvasClip&&(this.canvasClip.render(r),r.clip())},_renderTransform:function(r){if("canvasTransform"in this){var u=this.canvasTransform;r.translate(u.dx,u.dy);r.rotate(u.angle2);r.scale(u.sx,u.sy);r.rotate(u.angle1)}},
_renderShape:function(r){},_renderFill:function(r,u){if("canvasFill"in this){var A=this.fillStyle;if("canvasFillImage"in this){var x=A.width,H=A.height,L=this.canvasFillImage.width,Y=this.canvasFillImage.height,ba=Math.min(x==L?1:x/L,H==Y?1:H/Y),ca=(x-ba*L)/2,fa=(H-ba*Y)/2;Q.width=x;Q.height=H;var ia=Q.getContext("2d");ia.clearRect(0,0,x,H);ia.drawImage(this.canvasFillImage,0,0,L,Y,ca,fa,ba*L,ba*Y);this.canvasFill=r.createPattern(Q,"repeat");delete this.canvasFillImage}r.fillStyle=this.canvasFill;
u&&("pattern"!==A.type||0===A.x&&0===A.y||r.translate(A.x,A.y),r.fill())}else r.fillStyle="rgba(0,0,0,0.0)"},_renderStroke:function(r,u){var A=this.strokeStyle;A?(r.strokeStyle=A.color.toString(),r.lineWidth=A.width,r.lineCap=A.cap,"number"==typeof A.join?(r.lineJoin="miter",r.miterLimit=A.join):r.lineJoin=A.join,this.canvasDash?F?(r.setLineDash(this.canvasDash),u&&r.stroke()):this._renderDashedStroke(r,u):u&&r.stroke()):u||(r.strokeStyle="rgba(0,0,0,0.0)")},_renderDashedStroke:function(r,u){},getEventSource:function(){return null},
on:function(){},connect:function(){},disconnect:function(){},canvasClip:null,setClip:function(r){this.inherited(arguments);var u=r?"width"in r?"rect":"cx"in r?"ellipse":"points"in r?"polyline":"d"in r?"path":null:null;if(r&&!u)return this;this.canvasClip=r?R(u,r):null;this.parent&&this.parent._makeDirty();return this}});var R=function(r,u){switch(r){case "ellipse":return{canvasEllipse:h({shape:u}),render:function(A){return v.Ellipse.prototype._renderShape.call(this,A)}};case "rect":return{shape:a.delegate(u,
{r:0}),render:function(A){return v.Rect.prototype._renderShape.call(this,A)}};case "path":return{canvasPath:aa(u),render:function(A){this.canvasPath._renderShape(A)}};case "polyline":return{canvasPolyline:u.points,render:function(A){return v.Polyline.prototype._renderShape.call(this,A)}}}return null},aa=function(r){var u=new dojox.gfx.canvas.Path;u.canvasPath=[];u._setPath(r.d);return u},W=function(r,u,A){var x=r.prototype[u];r.prototype[u]=A?function(){this.parent&&this.parent._makeDirty();x.apply(this,
arguments);A.call(this);return this}:function(){this.parent&&this.parent._makeDirty();return x.apply(this,arguments)}};W(v.Shape,"setTransform",function(){this.matrix?this.canvasTransform=D.decompose(this.matrix):delete this.canvasTransform});W(v.Shape,"setFill",function(){var r=this.fillStyle;if(r){if("object"==typeof r&&"type"in r){var u=this.surface.rawNode.getContext("2d");switch(r.type){case "linear":case "radial":var A="linear"==r.type?u.createLinearGradient(r.x1,r.y1,r.x2,r.y2):u.createRadialGradient(r.cx,
r.cy,0,r.cx,r.cy,r.r);d.forEach(r.colors,function(x){A.addColorStop(x.offset,D.normalizeColor(x.color).toString())});break;case "pattern":Q||(Q=document.createElement("canvas")),u=new Image,this.surface.downloadImage(u,r.src),this.canvasFillImage=u}}else A=r.toString();this.canvasFill=A}else delete this.canvasFill});W(v.Shape,"setStroke",function(){var r=this.strokeStyle;if(r){var u=this.strokeStyle.style.toLowerCase();u in E&&(u=E[u]);if(u instanceof Array){this.canvasDash=u=u.slice();var A;for(A=
0;A<u.length;++A)u[A]*=r.width;if("butt"!=r.cap){for(A=0;A<u.length;A+=2)u[A]-=r.width,1>u[A]&&(u[A]=1);for(A=1;A<u.length;A+=2)u[A]+=r.width}}else delete this.canvasDash}else delete this.canvasDash;this._needsDash=!F&&!!this.canvasDash});W(v.Shape,"setShape");v.Group=c("dojox.gfx.canvas.Group",v.Shape,{constructor:function(){C.Container._init.call(this)},_render:function(r){r.save();this._renderTransform(r);this._renderClip(r);for(var u=0;u<this.children.length;++u)this.children[u]._render(r);r.restore()},
destroy:function(){C.Container.clear.call(this,!0);v.Shape.prototype.destroy.apply(this,arguments)}});v.Rect=c("dojox.gfx.canvas.Rect",[v.Shape,C.Rect],{_renderShape:function(r){var u=this.shape,A=Math.min(u.r,u.height/2,u.width/2),x=u.x,H=x+u.width,L=u.y;u=L+u.height;var Y=x+A,ba=H-A,ca=L+A,fa=u-A;r.beginPath();r.moveTo(Y,L);A?(r.arc(ba,ca,A,-G,0,!1),r.arc(ba,fa,A,0,G,!1),r.arc(Y,fa,A,G,U,!1),r.arc(Y,ca,A,U,U+G,!1)):(r.lineTo(ba,L),r.lineTo(H,fa),r.lineTo(Y,u),r.lineTo(x,ca));r.closePath()},_renderDashedStroke:function(r,
u){var A=this.shape,x=Math.min(A.r,A.height/2,A.width/2),H=A.x,L=H+A.width,Y=A.y,ba=Y+A.height,ca=H+x,fa=L-x,ia=Y+x,ka=ba-x;x?(r.beginPath(),A=z(r,this,ca,Y,fa,Y),u&&r.stroke(),A=q(r,this.canvasDash,fa,ia,x,-G,0,!1,u,A),r.beginPath(),A=z(r,this,L,ia,L,ka,A),u&&r.stroke(),A=q(r,this.canvasDash,fa,ka,x,0,G,!1,u,A),r.beginPath(),A=z(r,this,fa,ba,ca,ba,A),u&&r.stroke(),A=q(r,this.canvasDash,ca,ka,x,G,U,!1,u,A),r.beginPath(),A=z(r,this,H,ka,H,ia,A),u&&r.stroke(),q(r,this.canvasDash,ca,ia,x,U,U+G,!1,u,
A)):(r.beginPath(),A=z(r,this,ca,Y,fa,Y),A=z(r,this,fa,Y,L,ka,A),A=z(r,this,L,ka,ca,ba,A),z(r,this,ca,ba,H,ia,A),u&&r.stroke())}});var da=[];(function(){var r=y.curvePI4;da.push(r.s,r.c1,r.c2,r.e);for(var u=45;360>u;u+=45){var A=I.rotateg(u);da.push(S(A,r.c1),S(A,r.c2),S(A,r.e))}})();var h=function(r){var u=[],A=r.shape,x=I.normalize([I.translate(A.cx,A.cy),I.scale(A.rx,A.ry)]);var H=S(x,da[0]);u.push([H.x,H.y]);for(A=1;A<da.length;A+=3){var L=S(x,da[A]);var Y=S(x,da[A+1]);H=S(x,da[A+2]);u.push([L.x,
L.y,Y.x,Y.y,H.x,H.y])}if(r._needsDash){H=[];L=u[0];for(A=1;A<u.length;++A)Y=[],K(L.concat(u[A]),r.canvasDash,Y),L=[u[A][4],u[A][5]],H.push(Y);r._dashedPoints=H}return u};v.Ellipse=c("dojox.gfx.canvas.Ellipse",[v.Shape,C.Ellipse],{setShape:function(){this.inherited(arguments);this.canvasEllipse=h(this);return this},setStroke:function(){this.inherited(arguments);F||(this.canvasEllipse=h(this));return this},_renderShape:function(r){var u=this.canvasEllipse,A;r.beginPath();r.moveTo.apply(r,u[0]);for(A=
1;A<u.length;++A)r.bezierCurveTo.apply(r,u[A]);r.closePath()},_renderDashedStroke:function(r,u){var A=this._dashedPoints;r.beginPath();for(var x=0;x<A.length;++x)for(var H=A[x],L=0;L<H.length;++L){var Y=H[L];r.moveTo(Y[0],Y[1]);r.bezierCurveTo(Y[2],Y[3],Y[4],Y[5],Y[6],Y[7])}u&&r.stroke()}});v.Circle=c("dojox.gfx.canvas.Circle",[v.Shape,C.Circle],{_renderShape:function(r){var u=this.shape;r.beginPath();r.arc(u.cx,u.cy,u.r,0,g,1)},_renderDashedStroke:function(r,u){var A=this.shape,x=0,H=this.canvasDash.length;
for(i=0;x<g;){var L=this.canvasDash[i%H]/A.r;i%2||(r.beginPath(),r.arc(A.cx,A.cy,A.r,x,x+L,0),u&&r.stroke());x+=L;++i}}});v.Line=c("dojox.gfx.canvas.Line",[v.Shape,C.Line],{_renderShape:function(r){var u=this.shape;r.beginPath();r.moveTo(u.x1,u.y1);r.lineTo(u.x2,u.y2)},_renderDashedStroke:function(r,u){var A=this.shape;r.beginPath();z(r,this,A.x1,A.y1,A.x2,A.y2);u&&r.stroke()}});v.Polyline=c("dojox.gfx.canvas.Polyline",[v.Shape,C.Polyline],{setShape:function(){this.inherited(arguments);var r=this.shape.points,
u=r[0],A;this.bbox=null;this._normalizePoints();if(r.length)if("number"==typeof u)u=r;else for(u=[],A=0;A<r.length;++A){var x=r[A];u.push(x.x,x.y)}else u=[];this.canvasPolyline=u;return this},_renderShape:function(r){var u=this.canvasPolyline;if(u.length){r.beginPath();r.moveTo(u[0],u[1]);for(var A=2;A<u.length;A+=2)r.lineTo(u[A],u[A+1])}},_renderDashedStroke:function(r,u){var A=this.canvasPolyline,x=0;r.beginPath();for(var H=0;H<A.length;H+=2)x=z(r,this,A[H],A[H+1],A[H+2],A[H+3],x);u&&r.stroke()}});
v.Image=c("dojox.gfx.canvas.Image",[v.Shape,C.Image],{setShape:function(){this.inherited(arguments);var r=new Image;this.surface.downloadImage(r,this.shape.src);this.canvasImage=r;return this},_renderShape:function(r){var u=this.shape;r.drawImage(this.canvasImage,u.x,u.y,u.width,u.height)}});v.Text=c("dojox.gfx.canvas.Text",[v.Shape,C.Text],{_setFont:function(){this.fontStyle?this.canvasFont=D.makeFontString(this.fontStyle):delete this.canvasFont},getTextWidth:function(){var r=this.shape,u=0;if(r.text){var A=
this.surface.rawNode.getContext("2d");A.save();this._renderTransform(A);this._renderFill(A,!1);this._renderStroke(A,!1);this.canvasFont&&(A.font=this.canvasFont);u=A.measureText(r.text).width;A.restore()}return u},_render:function(r){r.save();this._renderTransform(r);this._renderFill(r,!1);this._renderStroke(r,!1);this._renderShape(r);r.restore()},_renderShape:function(r){var u=this.shape;u.text&&(r.textAlign="middle"===u.align?"center":u.align,this.canvasFont&&(r.font=this.canvasFont),this.canvasFill&&
r.fillText(u.text,u.x,u.y),this.strokeStyle&&(r.beginPath(),r.strokeText(u.text,u.x,u.y),r.closePath()))}});W(v.Text,"setFont");l||v.Text.extend({getTextWidth:function(){return 0},getBoundingBox:function(){return null},_renderShape:function(){}});var V={M:"_moveToA",m:"_moveToR",L:"_lineToA",l:"_lineToR",H:"_hLineToA",h:"_hLineToR",V:"_vLineToA",v:"_vLineToR",C:"_curveToA",c:"_curveToR",S:"_smoothCurveToA",s:"_smoothCurveToR",Q:"_qCurveToA",q:"_qCurveToR",T:"_qSmoothCurveToA",t:"_qSmoothCurveToR",
A:"_arcTo",a:"_arcTo",Z:"_closePath",z:"_closePath"};v.Path=c("dojox.gfx.canvas.Path",[v.Shape,m.Path],{constructor:function(){this.lastControl={}},setShape:function(){this.canvasPath=[];this._dashedPath=[];return this.inherited(arguments)},setStroke:function(){this.inherited(arguments);F||(this.segmented=!1,this._confirmSegmented());return this},_setPath:function(){this._dashResidue=null;this.inherited(arguments)},_updateWithSegment:function(r){var u=a.clone(this.last);this[V[r.action]](this.canvasPath,
r.action,r.args,this._needsDash?this._dashedPath:null);this.last=u;this.inherited(arguments)},_renderShape:function(r){var u=this.canvasPath;r.beginPath();for(var A=0;A<u.length;A+=2)r[u[A]].apply(r,u[A+1])},_renderDashedStroke:F?function(){}:function(r,u){var A=this._dashedPath;r.beginPath();for(var x=0;x<A.length;x+=2)r[A[x]].apply(r,A[x+1]);u&&r.stroke()},_moveToA:function(r,u,A,x){r.push("moveTo",[A[0],A[1]]);x&&x.push("moveTo",[A[0],A[1]]);for(u=2;u<A.length;u+=2)r.push("lineTo",[A[u],A[u+1]]),
x&&(this._dashResidue=z(x,this,A[u-2],A[u-1],A[u],A[u+1],this._dashResidue));this.last.x=A[A.length-2];this.last.y=A[A.length-1];this.lastControl={}},_moveToR:function(r,u,A,x){u="x"in this.last?[this.last.x+=A[0],this.last.y+=A[1]]:[this.last.x=A[0],this.last.y=A[1]];r.push("moveTo",u);x&&x.push("moveTo",u);for(u=2;u<A.length;u+=2)r.push("lineTo",[this.last.x+=A[u],this.last.y+=A[u+1]]),x&&(this._dashResidue=z(x,this,x[x.length-1][0],x[x.length-1][1],this.last.x,this.last.y,this._dashResidue));this.lastControl=
{}},_lineToA:function(r,u,A,x){for(u=0;u<A.length;u+=2)x&&(this._dashResidue=z(x,this,this.last.x,this.last.y,A[u],A[u+1],this._dashResidue)),r.push("lineTo",[A[u],A[u+1]]);this.last.x=A[A.length-2];this.last.y=A[A.length-1];this.lastControl={}},_lineToR:function(r,u,A,x){for(u=0;u<A.length;u+=2)r.push("lineTo",[this.last.x+=A[u],this.last.y+=A[u+1]]),x&&(this._dashResidue=z(x,this,x[x.length-1][0],x[x.length-1][1],this.last.x,this.last.y,this._dashResidue));this.lastControl={}},_hLineToA:function(r,
u,A,x){for(u=0;u<A.length;++u)r.push("lineTo",[A[u],this.last.y]),x&&(this._dashResidue=z(x,this,x[x.length-1][0],x[x.length-1][1],A[u],this.last.y,this._dashResidue));this.last.x=A[A.length-1];this.lastControl={}},_hLineToR:function(r,u,A,x){for(u=0;u<A.length;++u)r.push("lineTo",[this.last.x+=A[u],this.last.y]),x&&(this._dashResidue=z(x,this,x[x.length-1][0],x[x.length-1][1],this.last.x,this.last.y,this._dashResidue));this.lastControl={}},_vLineToA:function(r,u,A,x){for(u=0;u<A.length;++u)r.push("lineTo",
[this.last.x,A[u]]),x&&(this._dashResidue=z(x,this,x[x.length-1][0],x[x.length-1][1],this.last.x,A[u],this._dashResidue));this.last.y=A[A.length-1];this.lastControl={}},_vLineToR:function(r,u,A,x){for(u=0;u<A.length;++u)r.push("lineTo",[this.last.x,this.last.y+=A[u]]),x&&(this._dashResidue=z(x,this,x[x.length-1][0],x[x.length-1][1],this.last.x,this.last.y,this._dashResidue));this.lastControl={}},_curveToA:function(r,u,A,x){for(u=0;u<A.length;u+=6)r.push("bezierCurveTo",A.slice(u,u+6)),x&&(this._dashResidue=
M(x,this,r[r.length-1],this._dashResidue));this.last.x=A[A.length-2];this.last.y=A[A.length-1];this.lastControl.x=A[A.length-4];this.lastControl.y=A[A.length-3];this.lastControl.type="C"},_curveToR:function(r,u,A,x){for(u=0;u<A.length;u+=6)r.push("bezierCurveTo",[this.last.x+A[u],this.last.y+A[u+1],this.lastControl.x=this.last.x+A[u+2],this.lastControl.y=this.last.y+A[u+3],this.last.x+A[u+4],this.last.y+A[u+5]]),x&&(this._dashResidue=M(x,this,r[r.length-1],this._dashResidue)),this.last.x+=A[u+4],
this.last.y+=A[u+5];this.lastControl.type="C"},_smoothCurveToA:function(r,u,A,x){for(u=0;u<A.length;u+=4){var H="C"==this.lastControl.type;r.push("bezierCurveTo",[H?2*this.last.x-this.lastControl.x:this.last.x,H?2*this.last.y-this.lastControl.y:this.last.y,A[u],A[u+1],A[u+2],A[u+3]]);x&&(this._dashResidue=M(x,this,r[r.length-1],this._dashResidue));this.lastControl.x=A[u];this.lastControl.y=A[u+1];this.lastControl.type="C"}this.last.x=A[A.length-2];this.last.y=A[A.length-1]},_smoothCurveToR:function(r,
u,A,x){for(u=0;u<A.length;u+=4){var H="C"==this.lastControl.type;r.push("bezierCurveTo",[H?2*this.last.x-this.lastControl.x:this.last.x,H?2*this.last.y-this.lastControl.y:this.last.y,this.last.x+A[u],this.last.y+A[u+1],this.last.x+A[u+2],this.last.y+A[u+3]]);x&&(this._dashResidue=M(x,this,r[r.length-1],this._dashResidue));this.lastControl.x=this.last.x+A[u];this.lastControl.y=this.last.y+A[u+1];this.lastControl.type="C";this.last.x+=A[u+2];this.last.y+=A[u+3]}},_qCurveToA:function(r,u,A,x){for(u=
0;u<A.length;u+=4)r.push("quadraticCurveTo",A.slice(u,u+4));x&&(this._dashResidue=M(x,this,r[r.length-1],this._dashResidue));this.last.x=A[A.length-2];this.last.y=A[A.length-1];this.lastControl.x=A[A.length-4];this.lastControl.y=A[A.length-3];this.lastControl.type="Q"},_qCurveToR:function(r,u,A,x){for(u=0;u<A.length;u+=4)r.push("quadraticCurveTo",[this.lastControl.x=this.last.x+A[u],this.lastControl.y=this.last.y+A[u+1],this.last.x+A[u+2],this.last.y+A[u+3]]),x&&(this._dashResidue=M(x,this,r[r.length-
1],this._dashResidue)),this.last.x+=A[u+2],this.last.y+=A[u+3];this.lastControl.type="Q"},_qSmoothCurveToA:function(r,u,A,x){for(u=0;u<A.length;u+=2){var H="Q"==this.lastControl.type;r.push("quadraticCurveTo",[this.lastControl.x=H?2*this.last.x-this.lastControl.x:this.last.x,this.lastControl.y=H?2*this.last.y-this.lastControl.y:this.last.y,A[u],A[u+1]]);x&&(this._dashResidue=M(x,this,r[r.length-1],this._dashResidue));this.lastControl.type="Q"}this.last.x=A[A.length-2];this.last.y=A[A.length-1]},_qSmoothCurveToR:function(r,
u,A,x){for(u=0;u<A.length;u+=2){var H="Q"==this.lastControl.type;r.push("quadraticCurveTo",[this.lastControl.x=H?2*this.last.x-this.lastControl.x:this.last.x,this.lastControl.y=H?2*this.last.y-this.lastControl.y:this.last.y,this.last.x+A[u],this.last.y+A[u+1]]);x&&(this._dashResidue=M(x,this,r[r.length-1],this._dashResidue));this.lastControl.type="Q";this.last.x+=A[u];this.last.y+=A[u+1]}},_arcTo:function(r,u,A,x){u="a"==u;for(var H=0;H<A.length;H+=7){var L=A[H+5],Y=A[H+6];u&&(L+=this.last.x,Y+=this.last.y);
var ba=y.arcAsBezier(this.last,A[H],A[H+1],A[H+2],A[H+3]?1:0,A[H+4]?1:0,L,Y);d.forEach(ba,function(ca){r.push("bezierCurveTo",ca)});x&&(this._dashResidue=M(x,this,p,this._dashResidue));this.last.x=L;this.last.y=Y}this.lastControl={}},_closePath:function(r,u,A,x){r.push("closePath",[]);x&&(this._dashResidue=z(x,this,this.last.x,this.last.y,x[1][0],x[1][1],this._dashResidue));this.lastControl={}}});d.forEach("moveTo lineTo hLineTo vLineTo curveTo smoothCurveTo qCurveTo qSmoothCurveTo arcTo closePath".split(" "),
function(r){W(v.Path,r)});v.TextPath=c("dojox.gfx.canvas.TextPath",[v.Shape,m.TextPath],{_renderShape:function(r){},_setText:function(){},_setFont:function(){}});v.Surface=c("dojox.gfx.canvas.Surface",C.Surface,{constructor:function(){C.Container._init.call(this);this.pendingImageCount=0;this.makeDirty()},destroy:function(){C.Container.clear.call(this,!0);this.inherited(arguments)},setDimensions:function(r,u){this.width=D.normalizedLength(r);this.height=D.normalizedLength(u);if(!this.rawNode)return this;
r=!1;this.rawNode.width!=this.width&&(this.rawNode.width=this.width,r=!0);this.rawNode.height!=this.height&&(this.rawNode.height=this.height,r=!0);r&&this.makeDirty();return this},getDimensions:function(){return this.rawNode?{width:this.rawNode.width,height:this.rawNode.height}:null},_render:function(r){!this.rawNode||!r&&this.pendingImageCount||(r=this.rawNode.getContext("2d"),r.clearRect(0,0,this.rawNode.width,this.rawNode.height),this.render(r),"pendingRender"in this&&(clearTimeout(this.pendingRender),
delete this.pendingRender))},render:function(r){r.save();for(var u=0;u<this.children.length;++u)this.children[u]._render(r);r.restore()},makeDirty:function(){this.pendingImagesCount||"pendingRender"in this||this._batch||(this.pendingRender=setTimeout(a.hitch(this,this._render),0))},downloadImage:function(r,u){var A=a.hitch(this,this.onImageLoad);!this.pendingImageCount++&&"pendingRender"in this&&(clearTimeout(this.pendingRender),delete this.pendingRender);r.onload=A;r.onerror=A;r.onabort=A;r.src=
u},onImageLoad:function(){--this.pendingImageCount||(this.onImagesLoaded(),this._render())},onImagesLoaded:function(){},getEventSource:function(){return null},connect:function(){},disconnect:function(){},on:function(){}});v.createSurface=function(r,u,A){if(!u&&!A){var x=n.position(r);u=u||x.w;A=A||x.h}"number"==typeof u&&(u+="px");"number"==typeof A&&(A+="px");x=new v.Surface;r=B.byId(r);var H=r.ownerDocument.createElement("canvas");H.width=D.normalizedLength(u);H.height=D.normalizedLength(A);r.appendChild(H);
x.rawNode=H;x._parent=r;return x.surface=x};var T=C.Container;c={openBatch:function(){++this._batch;return this},closeBatch:function(){this._batch=0<this._batch?--this._batch:0;this._makeDirty();return this},_makeDirty:function(){this._batch||this.surface.makeDirty()},add:function(r){this._makeDirty();return T.add.apply(this,arguments)},remove:function(r,u){this._makeDirty();return T.remove.apply(this,arguments)},clear:function(){this._makeDirty();return T.clear.apply(this,arguments)},getBoundingBox:T.getBoundingBox,
_moveChildToFront:function(r){this._makeDirty();return T._moveChildToFront.apply(this,arguments)},_moveChildToBack:function(r){this._makeDirty();return T._moveChildToBack.apply(this,arguments)}};m={createObject:function(r,u){r=new r;r.surface=this.surface;r.setShape(u);this.add(r);return r}};e(v.Group,c);e(v.Group,C.Creator);e(v.Group,m);e(v.Surface,c);e(v.Surface,C.Creator);e(v.Surface,m);v.fixTarget=function(r,u){return!0};return v})},"dojox/gfx/shape":function(){define("./_base dojo/_base/lang dojo/_base/declare dojo/_base/kernel dojo/_base/sniff dojo/on dojo/_base/array dojo/dom-construct dojo/_base/Color ./matrix".split(" "),
function(D,a,d,c,w,n,B,C,m,y){function I(b,q){for(var K=b.length-1;q<K;)b[q]=b[++q];b.length=K}var e=D.shape={};e.Shape=d("dojox.gfx.shape.Shape",null,{constructor:function(){this.parentMatrix=this.parent=this.bbox=this.strokeStyle=this.fillStyle=this.matrix=this.shape=this.rawNode=null;if(w("gfxRegistry")){var b=e.register(this);this.getUID=function(){return b}}},destroy:function(){w("gfxRegistry")&&e.dispose(this);this.rawNode&&"__gfxObject__"in this.rawNode&&(this.rawNode.__gfxObject__=null);this.rawNode=
null},getNode:function(){return this.rawNode},getShape:function(){return this.shape},getTransform:function(){return this.matrix},getFill:function(){return this.fillStyle},getStroke:function(){return this.strokeStyle},getParent:function(){return this.parent},getBoundingBox:function(){return this.bbox},getTransformedBoundingBox:function(){var b=this.getBoundingBox();if(!b)return null;var q=this._getRealMatrix();return[y.multiplyPoint(q,b.x,b.y),y.multiplyPoint(q,b.x+b.width,b.y),y.multiplyPoint(q,b.x+
b.width,b.y+b.height),y.multiplyPoint(q,b.x,b.y+b.height)]},getEventSource:function(){return this.rawNode},setClip:function(b){this.clip=b},getClip:function(){return this.clip},setShape:function(b){this.shape=D.makeParameters(this.shape,b);this.bbox=null;return this},setFill:function(b){if(!b)return this.fillStyle=null,this;var q=null;if("object"==typeof b&&"type"in b)switch(b.type){case "linear":q=D.makeParameters(D.defaultLinearGradient,b);break;case "radial":q=D.makeParameters(D.defaultRadialGradient,
b);break;case "pattern":q=D.makeParameters(D.defaultPattern,b)}else q=D.normalizeColor(b);this.fillStyle=q;return this},setStroke:function(b){if(!b)return this.strokeStyle=null,this;if("string"==typeof b||a.isArray(b)||b instanceof m)b={color:b};b=this.strokeStyle=D.makeParameters(D.defaultStroke,b);b.color=D.normalizeColor(b.color);return this},setTransform:function(b){this.matrix=y.clone(b?y.normalize(b):y.identity);return this._applyTransform()},_applyTransform:function(){return this},moveToFront:function(){var b=
this.getParent();b&&(b._moveChildToFront(this),this._moveToFront());return this},moveToBack:function(){var b=this.getParent();b&&(b._moveChildToBack(this),this._moveToBack());return this},_moveToFront:function(){},_moveToBack:function(){},applyRightTransform:function(b){return b?this.setTransform([this.matrix,b]):this},applyLeftTransform:function(b){return b?this.setTransform([b,this.matrix]):this},applyTransform:function(b){return b?this.setTransform([this.matrix,b]):this},removeShape:function(b){this.parent&&
this.parent.remove(this,b);return this},_setParent:function(b,q){this.parent=b;return this._updateParentMatrix(q)},_updateParentMatrix:function(b){this.parentMatrix=b?y.clone(b):null;return this._applyTransform()},_getRealMatrix:function(){for(var b=this.matrix,q=this.parent;q;)q.matrix&&(b=y.multiply(q.matrix,b)),q=q.parent;return b}});e._eventsProcessing={on:function(b,q){return n(this.getEventSource(),b,e.fixCallback(this,D.fixTarget,q))},connect:function(b,q,K){"on"==b.substring(0,2)&&(b=b.substring(2));
return this.on(b,K?a.hitch(q,K):q)},disconnect:function(b){return b.remove()}};e.fixCallback=function(b,q,K,M){M||(M=K,K=null);if(a.isString(M)){K=K||c.global;if(!K[M])throw['dojox.gfx.shape.fixCallback: scope["',M,'"] is null (scope\x3d"',K,'")'].join("");return function(z){return q(z,b)?K[M].apply(K,arguments||[]):void 0}}return K?function(z){return q(z,b)?M.apply(K,arguments||[]):void 0}:function(z){return q(z,b)?M.apply(K,arguments):void 0}};a.extend(e.Shape,e._eventsProcessing);e.Container={_init:function(){this.children=
[];this._batch=0},openBatch:function(){return this},closeBatch:function(){return this},add:function(b){var q=b.getParent();q&&q.remove(b,!0);this.children.push(b);return b._setParent(this,this._getRealMatrix())},remove:function(b,q){for(var K=0;K<this.children.length;++K)if(this.children[K]==b){q||(b.parent=null,b.parentMatrix=null);I(this.children,K);break}return this},clear:function(b){for(var q,K=0;K<this.children.length;++K)q=this.children[K],q.parent=null,q.parentMatrix=null,b&&q.destroy();this.children=
[];return this},getBoundingBox:function(){if(this.children){var b=null;B.forEach(this.children,function(q){var K=q.getBoundingBox();K&&((q=q.getTransform())&&(K=y.multiplyRectangle(q,K)),b?(b.x=Math.min(b.x,K.x),b.y=Math.min(b.y,K.y),b.endX=Math.max(b.endX,K.x+K.width),b.endY=Math.max(b.endY,K.y+K.height)):b={x:K.x,y:K.y,endX:K.x+K.width,endY:K.y+K.height})});b&&(b.width=b.endX-b.x,b.height=b.endY-b.y);return b}return null},_moveChildToFront:function(b){for(var q=0;q<this.children.length;++q)if(this.children[q]==
b){I(this.children,q);this.children.push(b);break}return this},_moveChildToBack:function(b){for(var q=0;q<this.children.length;++q)if(this.children[q]==b){I(this.children,q);this.children.unshift(b);break}return this}};e.Surface=d("dojox.gfx.shape.Surface",null,{constructor:function(){this._parent=this.rawNode=null;this._nodes=[];this._events=[]},destroy:function(){B.forEach(this._nodes,C.destroy);this._nodes=[];B.forEach(this._events,function(b){b&&b.remove()});this._events=[];this.rawNode=null;
if(w("ie"))for(;this._parent.lastChild;)C.destroy(this._parent.lastChild);else this._parent.innerHTML="";this._parent=null},getEventSource:function(){return this.rawNode},_getRealMatrix:function(){return null},isLoaded:!0,onLoad:function(b){},whenLoaded:function(b,q){var K=a.hitch(b,q);if(this.isLoaded)K(this);else n.once(this,"load",function(M){K(M)})}});a.extend(e.Surface,e._eventsProcessing);e.Rect=d("dojox.gfx.shape.Rect",e.Shape,{constructor:function(b){this.shape=D.getDefault("Rect");this.rawNode=
b},getBoundingBox:function(){return this.shape}});e.Ellipse=d("dojox.gfx.shape.Ellipse",e.Shape,{constructor:function(b){this.shape=D.getDefault("Ellipse");this.rawNode=b},getBoundingBox:function(){if(!this.bbox){var b=this.shape;this.bbox={x:b.cx-b.rx,y:b.cy-b.ry,width:2*b.rx,height:2*b.ry}}return this.bbox}});e.Circle=d("dojox.gfx.shape.Circle",e.Shape,{constructor:function(b){this.shape=D.getDefault("Circle");this.rawNode=b},getBoundingBox:function(){if(!this.bbox){var b=this.shape;this.bbox={x:b.cx-
b.r,y:b.cy-b.r,width:2*b.r,height:2*b.r}}return this.bbox}});e.Line=d("dojox.gfx.shape.Line",e.Shape,{constructor:function(b){this.shape=D.getDefault("Line");this.rawNode=b},getBoundingBox:function(){if(!this.bbox){var b=this.shape;this.bbox={x:Math.min(b.x1,b.x2),y:Math.min(b.y1,b.y2),width:Math.abs(b.x2-b.x1),height:Math.abs(b.y2-b.y1)}}return this.bbox}});e.Polyline=d("dojox.gfx.shape.Polyline",e.Shape,{constructor:function(b){this.shape=D.getDefault("Polyline");this.rawNode=b},setShape:function(b,
q){b&&b instanceof Array?(this.inherited(arguments,[{points:b}]),q&&this.shape.points.length&&this.shape.points.push(this.shape.points[0])):this.inherited(arguments,[b]);return this},_normalizePoints:function(){var b=this.shape.points,q=b&&b.length;if(q&&"number"==typeof b[0]){for(var K=[],M=0;M<q;M+=2)K.push({x:b[M],y:b[M+1]});this.shape.points=K}},getBoundingBox:function(){if(!this.bbox&&this.shape.points.length){for(var b=this.shape.points,q=b.length,K=b[0],M=K.x,z=K.y,v=K.x,Q=K.y,S=1;S<q;++S)K=
b[S],M>K.x&&(M=K.x),v<K.x&&(v=K.x),z>K.y&&(z=K.y),Q<K.y&&(Q=K.y);this.bbox={x:M,y:z,width:v-M,height:Q-z}}return this.bbox}});e.Image=d("dojox.gfx.shape.Image",e.Shape,{constructor:function(b){this.shape=D.getDefault("Image");this.rawNode=b},getBoundingBox:function(){return this.shape},setStroke:function(){return this},setFill:function(){return this}});e.Text=d(e.Shape,{constructor:function(b){this.fontStyle=null;this.shape=D.getDefault("Text");this.rawNode=b},getFont:function(){return this.fontStyle},
setFont:function(b){this.fontStyle="string"==typeof b?D.splitFontString(b):D.makeParameters(D.defaultFont,b);this._setFont();return this},getBoundingBox:function(){var b=null;this.getShape().text&&(b=D._base._computeTextBoundingBox(this));return b}});e.Creator={createShape:function(b){switch(b.type){case D.defaultPath.type:return this.createPath(b);case D.defaultRect.type:return this.createRect(b);case D.defaultCircle.type:return this.createCircle(b);case D.defaultEllipse.type:return this.createEllipse(b);
case D.defaultLine.type:return this.createLine(b);case D.defaultPolyline.type:return this.createPolyline(b);case D.defaultImage.type:return this.createImage(b);case D.defaultText.type:return this.createText(b);case D.defaultTextPath.type:return this.createTextPath(b)}return null},createGroup:function(){return this.createObject(D.Group)},createRect:function(b){return this.createObject(D.Rect,b)},createEllipse:function(b){return this.createObject(D.Ellipse,b)},createCircle:function(b){return this.createObject(D.Circle,
b)},createLine:function(b){return this.createObject(D.Line,b)},createPolyline:function(b){return this.createObject(D.Polyline,b)},createImage:function(b){return this.createObject(D.Image,b)},createText:function(b){return this.createObject(D.Text,b)},createPath:function(b){return this.createObject(D.Path,b)},createTextPath:function(b){return this.createObject(D.TextPath,{}).setText(b)},createObject:function(b,q){return null}};return e})},"dojox/gfx/path":function(){define(["./_base","dojo/_base/lang",
"dojo/_base/declare","./matrix","./shape"],function(D,a,d,c,w){w=d("dojox.gfx.path.Path",w.Shape,{constructor:function(n){this.shape=a.clone(D.defaultPath);this.segments=[];this.tbbox=null;this.absolute=!0;this.last={};this.rawNode=n;this.segmented=!1},setAbsoluteMode:function(n){this._confirmSegmented();this.absolute="string"==typeof n?"absolute"==n:n;return this},getAbsoluteMode:function(){this._confirmSegmented();return this.absolute},getBoundingBox:function(){this._confirmSegmented();return this.bbox&&
"l"in this.bbox?{x:this.bbox.l,y:this.bbox.t,width:this.bbox.r-this.bbox.l,height:this.bbox.b-this.bbox.t}:null},_getRealBBox:function(){this._confirmSegmented();if(this.tbbox)return this.tbbox;var n=this.bbox,B=this._getRealMatrix();this.bbox=null;for(var C=0,m=this.segments.length;C<m;++C)this._updateWithSegment(this.segments[C],B);B=this.bbox;this.bbox=n;return this.tbbox=B?[{x:B.l,y:B.t},{x:B.r,y:B.t},{x:B.r,y:B.b},{x:B.l,y:B.b}]:null},getLastPosition:function(){this._confirmSegmented();return"x"in
this.last?this.last:null},_applyTransform:function(){this.tbbox=null;return this.inherited(arguments)},_updateBBox:function(n,B,C){C&&(B=c.multiplyPoint(C,n,B),n=B.x,B=B.y);this.bbox&&"l"in this.bbox?(this.bbox.l>n&&(this.bbox.l=n),this.bbox.r<n&&(this.bbox.r=n),this.bbox.t>B&&(this.bbox.t=B),this.bbox.b<B&&(this.bbox.b=B)):this.bbox={l:n,b:B,r:n,t:B}},_updateWithSegment:function(n,B){var C=n.args,m=C.length,y;switch(n.action){case "M":case "L":case "C":case "S":case "Q":case "T":for(y=0;y<m;y+=2)this._updateBBox(C[y],
C[y+1],B);this.last.x=C[m-2];this.last.y=C[m-1];this.absolute=!0;break;case "H":for(y=0;y<m;++y)this._updateBBox(C[y],this.last.y,B);this.last.x=C[m-1];this.absolute=!0;break;case "V":for(y=0;y<m;++y)this._updateBBox(this.last.x,C[y],B);this.last.y=C[m-1];this.absolute=!0;break;case "m":y=0;"x"in this.last||(this._updateBBox(this.last.x=C[0],this.last.y=C[1],B),y=2);for(;y<m;y+=2)this._updateBBox(this.last.x+=C[y],this.last.y+=C[y+1],B);this.absolute=!1;break;case "l":case "t":for(y=0;y<m;y+=2)this._updateBBox(this.last.x+=
C[y],this.last.y+=C[y+1],B);this.absolute=!1;break;case "h":for(y=0;y<m;++y)this._updateBBox(this.last.x+=C[y],this.last.y,B);this.absolute=!1;break;case "v":for(y=0;y<m;++y)this._updateBBox(this.last.x,this.last.y+=C[y],B);this.absolute=!1;break;case "c":for(y=0;y<m;y+=6)this._updateBBox(this.last.x+C[y],this.last.y+C[y+1],B),this._updateBBox(this.last.x+C[y+2],this.last.y+C[y+3],B),this._updateBBox(this.last.x+=C[y+4],this.last.y+=C[y+5],B);this.absolute=!1;break;case "s":case "q":for(y=0;y<m;y+=
4)this._updateBBox(this.last.x+C[y],this.last.y+C[y+1],B),this._updateBBox(this.last.x+=C[y+2],this.last.y+=C[y+3],B);this.absolute=!1;break;case "A":for(y=0;y<m;y+=7)this._updateBBox(C[y+5],C[y+6],B);this.last.x=C[m-2];this.last.y=C[m-1];this.absolute=!0;break;case "a":for(y=0;y<m;y+=7)this._updateBBox(this.last.x+=C[y+5],this.last.y+=C[y+6],B);this.absolute=!1}n=[n.action];for(y=0;y<m;++y)n.push(D.formatNumber(C[y],!0));if("string"==typeof this.shape.path)this.shape.path+=n.join("");else for(y=
0,m=n.length;y<m;++y)this.shape.path.push(n[y])},_validSegments:{m:2,l:2,h:1,v:1,c:6,s:4,q:4,t:2,a:7,z:0},_pushSegment:function(n,B){this.tbbox=null;var C=this._validSegments[n.toLowerCase()];"number"==typeof C&&(C?B.length>=C&&(n={action:n,args:B.slice(0,B.length-B.length%C)},this.segments.push(n),this._updateWithSegment(n)):(n={action:n,args:[]},this.segments.push(n),this._updateWithSegment(n)))},_collectArgs:function(n,B){for(var C=0;C<B.length;++C){var m=B[C];"boolean"==typeof m?n.push(m?1:0):
"number"==typeof m?n.push(m):m instanceof Array?this._collectArgs(n,m):"x"in m&&"y"in m&&n.push(m.x,m.y)}},moveTo:function(){this._confirmSegmented();var n=[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?"M":"m",n);return this},lineTo:function(){this._confirmSegmented();var n=[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?"L":"l",n);return this},hLineTo:function(){this._confirmSegmented();var n=[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?
"H":"h",n);return this},vLineTo:function(){this._confirmSegmented();var n=[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?"V":"v",n);return this},curveTo:function(){this._confirmSegmented();var n=[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?"C":"c",n);return this},smoothCurveTo:function(){this._confirmSegmented();var n=[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?"S":"s",n);return this},qCurveTo:function(){this._confirmSegmented();var n=
[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?"Q":"q",n);return this},qSmoothCurveTo:function(){this._confirmSegmented();var n=[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?"T":"t",n);return this},arcTo:function(){this._confirmSegmented();var n=[];this._collectArgs(n,arguments);this._pushSegment(this.absolute?"A":"a",n);return this},closePath:function(){this._confirmSegmented();this._pushSegment("Z",[]);return this},_confirmSegmented:function(){if(!this.segmented){var n=
this.shape.path;this.shape.path=[];this._setPath(n);this.shape.path=this.shape.path.join("");this.segmented=!0}},_setPath:function(n){n=a.isArray(n)?n:n.match(D.pathSvgRegExp);this.segments=[];this.absolute=!0;this.bbox={};this.last={};if(n){for(var B="",C=[],m=n.length,y=0;y<m;++y){var I=n[y],e=parseFloat(I);isNaN(e)?(B&&this._pushSegment(B,C),C=[],B=I):C.push(e)}this._pushSegment(B,C)}},setShape:function(n){this.inherited(arguments,["string"==typeof n?{path:n}:n]);this.segmented=!1;this.segments=
[];D.lazyPathSegmentation||this._confirmSegmented();return this},_2PI:2*Math.PI});d=d("dojox.gfx.path.TextPath",w,{constructor:function(n){"text"in this||(this.text=a.clone(D.defaultTextPath));"fontStyle"in this||(this.fontStyle=a.clone(D.defaultFont))},getText:function(){return this.text},setText:function(n){this.text=D.makeParameters(this.text,"string"==typeof n?{text:n}:n);this._setText();return this},getFont:function(){return this.fontStyle},setFont:function(n){this.fontStyle="string"==typeof n?
D.splitFontString(n):D.makeParameters(D.defaultFont,n);this._setFont();return this}});return D.path={Path:w,TextPath:d}})},"dojox/gfx/arc":function(){define(["./_base","dojo/_base/lang","./matrix"],function(D,a,d){function c(y){var I=Math.cos(y);y=Math.sin(y);var e={x:I+4/3*(1-I),y:y-4/3*I*(1-I)/y};return{s:{x:I,y:-y},c1:{x:e.x,y:-e.y},c2:e,e:{x:I,y:y}}}var w=2*Math.PI,n=Math.PI/4,B=Math.PI/8,C=n+B,m=c(B);return D.arc={unitArcAsBezier:c,curvePI4:m,arcAsBezier:function(y,I,e,b,q,K,M,z){q=!!q;K=!!K;
var v=d._degToRad(b);b=I*I;var Q=e*e,S=d.multiplyPoint(d.rotate(-v),{x:(y.x-M)/2,y:(y.y-z)/2}),U=S.x*S.x,g=S.y*S.y;b=Math.sqrt((b*Q-b*g-Q*U)/(b*g+Q*U));isNaN(b)&&(b=0);b={x:b*I*S.y/e,y:-b*e*S.x/I};q==K&&(b={x:-b.x,y:-b.y});b=d.multiplyPoint([d.translate((y.x+M)/2,(y.y+z)/2),d.rotate(v)],b);I=d.normalize([d.translate(b.x,b.y),d.rotate(v),d.scale(I,e)]);b=d.invert(I);y=d.multiplyPoint(b,y);z=d.multiplyPoint(b,M,z);M=Math.atan2(y.y,y.x);b=M-Math.atan2(z.y,z.x);K&&(b=-b);0>b?b+=w:b>w&&(b-=w);e=B;z=m;
e=K?e:-e;y=[];for(q=b;0<q;q-=n)q<C&&(e=q/2,z=c(e),e=K?e:-e,q=0),S=d.normalize([I,d.rotate(M+e)]),K?(b=d.multiplyPoint(S,z.c1),v=d.multiplyPoint(S,z.c2),S=d.multiplyPoint(S,z.e)):(b=d.multiplyPoint(S,z.c2),v=d.multiplyPoint(S,z.c1),S=d.multiplyPoint(S,z.s)),y.push([b.x,b.y,v.x,v.y,S.x,S.y]),M+=2*e;return y}}})},"dojox/gfx/decompose":function(){define(["./_base","dojo/_base/lang","./matrix"],function(D,a,d){function c(m,y){return Math.abs(m-y)<=1E-6*(Math.abs(m)+Math.abs(y))}function w(m,y,I,e){if(!isFinite(m))return I;
if(!isFinite(I))return m;y=Math.abs(y);e=Math.abs(e);return(y*m+e*I)/(y+e)}function n(m){m=d.normalize(m);var y=-m.xx-m.yy,I=m.xx*m.yy-m.xy*m.yx,e=Math.sqrt(y*y-4*I);y=-(y+(0>y?-e:e))/2;I/=y;e=m.xy/(y-m.xx);var b=1,q=m.xy/(I-m.xx),K=1;c(y,I)&&(e=1,q=b=0,K=1);isFinite(e)||(e=1,b=(y-m.xx)/m.xy,isFinite(b)||(e=(y-m.yy)/m.yx,b=1,isFinite(e)||(e=1,b=m.yx/(y-m.yy))));isFinite(q)||(q=1,K=(I-m.xx)/m.xy,isFinite(K)||(q=(I-m.yy)/m.yx,K=1,isFinite(q)||(q=1,K=m.yx/(I-m.yy))));m=Math.sqrt(e*e+b*b);var M=Math.sqrt(q*
q+K*K);isFinite(e/=m)||(e=0);isFinite(b/=m)||(b=0);isFinite(q/=M)||(q=0);isFinite(K/=M)||(K=0);return{value1:y,value2:I,vector1:{x:e,y:b},vector2:{x:q,y:K}}}function B(m,y){var I=0>m.xx*m.yy||0<m.xy*m.yx?-1:1,e=y.angle1=(Math.atan2(m.yx,m.yy)+Math.atan2(-I*m.xy,I*m.xx))/2;I=Math.cos(e);e=Math.sin(e);y.sx=w(m.xx/I,I,-m.xy/e,e);y.sy=w(m.yy/I,I,m.yx/e,e);return y}function C(m,y){var I=0>m.xx*m.yy||0<m.xy*m.yx?-1:1,e=y.angle2=(Math.atan2(I*m.yx,I*m.xx)+Math.atan2(-m.xy,m.yy))/2;I=Math.cos(e);e=Math.sin(e);
y.sx=w(m.xx/I,I,m.yx/e,e);y.sy=w(m.yy/I,I,-m.xy/e,e);return y}return D.decompose=function(m){var y=d.normalize(m);m={dx:y.dx,dy:y.dy,sx:1,sy:1,angle1:0,angle2:0};if(c(y.xy,0)&&c(y.yx,0))return a.mixin(m,{sx:y.xx,sy:y.yy});if(c(y.xx*y.yx,-y.xy*y.yy))return B(y,m);if(c(y.xx*y.xy,-y.yx*y.yy))return C(y,m);var I=new d.Matrix2D(y);var e=a.mixin(I,{dx:0,dy:0,xy:I.yx,yx:I.xy});I=n([y,e]);e=n([e,y]);I=new d.Matrix2D({xx:I.vector1.x,xy:I.vector2.x,yx:I.vector1.y,yy:I.vector2.y});e=new d.Matrix2D({xx:e.vector1.x,
xy:e.vector1.y,yx:e.vector2.x,yy:e.vector2.y});y=new d.Matrix2D([d.invert(I),y,d.invert(e)]);B(e,m);y.xx*=m.sx;y.yy*=m.sy;C(I,m);y.xx*=m.sx;y.yy*=m.sy;return a.mixin(m,{sx:y.xx,sy:y.yy})}})},"dojox/gfx/bezierutils":function(){define(["./_base"],function(D){D=D.bezierutils={};D.tAtLength=function(B,C){var m=0,y=6==B.length,I=0,e=0,b=y?c:n,q=function(K,M){for(var z=0,v=0;v<K.length-2;v+=2)z+=d(K[v],K[v+1],K[v+2],K[v+3]);v=y?d(B[0],B[1],B[4],B[5]):d(B[0],B[1],B[6],B[7]);z-v>M||I+z>C+M?(++e,K=b(K,.5),
q(K[0],M),Math.abs(I-C)<=M||q(K[1],M)):(I+=z,m+=1/(1<<e))};C&&q(B,.5);return m};var a=D.computeLength=function(B){for(var C=6==B.length,m=0,y=0;y<B.length-2;y+=2)m+=d(B[y],B[y+1],B[y+2],B[y+3]);y=C?d(B[0],B[1],B[4],B[5]):d(B[0],B[1],B[6],B[7]);return.1<m-y?(B=C?c(B,.5):w(B,.5),m=a(B[0],C),m+=a(B[1],C)):m},d=D.distance=function(B,C,m,y){return Math.sqrt((m-B)*(m-B)+(y-C)*(y-C))},c=function(B,C){var m=1-C,y=m*m,I=C*C,e=B[0],b=B[1],q=B[2],K=B[3],M=B[4];B=B[5];var z=y*e+2*m*C*q+I*M;y=y*b+2*m*C*K+I*B;
return[[e,b,m*e+C*q,m*b+C*K,z,y],[z,y,m*q+C*M,m*K+C*B,M,B]]},w=function(B,C){var m=1-C,y=m*m,I=y*m,e=C*C,b=e*C,q=B[0],K=B[1],M=B[2],z=B[3],v=B[4],Q=B[5],S=B[6];B=B[7];var U=I*q+3*y*C*M+3*m*e*v+b*S;I=I*K+3*y*C*z+3*m*e*Q+b*B;return[[q,K,m*q+C*M,m*K+C*z,y*q+2*m*C*M+e*v,y*K+2*m*C*z+e*Q,U,I],[U,I,y*M+2*m*C*v+e*S,y*z+2*m*C*Q+e*B,m*v+C*S,m*Q+C*B,S,B]]},n=D.splitBezierAtT=function(B,C){return 6==B.length?c(B,C):w(B,C)};return D})},"dojox/json/query":function(){define(["dojo/_base/kernel","dojo/_base/lang",
"dojox","dojo/_base/array"],function(D,a,d){a.getObject("json",!0,d);d.json._slice=function(c,w,n,B){var C=c.length,m=[];n=n||C;w=0>w?Math.max(0,w+C):Math.min(C,w);for(n=0>n?Math.max(0,n+C):Math.min(C,n);w<n;w+=B)m.push(c[w]);return m};d.json._find=function(c,w){function n(m){w&&(!0!==w||m instanceof Array?m[w]&&B.push(m[w]):B.push(m));for(var y in m){var I=m[y];w?I&&"object"==typeof I&&n(I):B.push(I)}}var B=[];if(w instanceof Array){if(1==w.length)return c[w[0]];for(var C=0;C<w.length;C++)B.push(c[w[C]])}else n(c);
return B};d.json._distinctFilter=function(c,w){for(var n=[],B={},C=0,m=c.length;C<m;++C){var y=c[C];w(y,C,c)&&("object"==typeof y&&y?y.__included||(y.__included=!0,n.push(y)):B[y+typeof y]||(B[y+typeof y]=!0,n.push(y)))}C=0;for(m=n.length;C<m;++C)n[C]&&delete n[C].__included;return n};return d.json.query=function(c,w){function n(e,b,q,K,M,z,v,Q){return C[Q].match(/[\*\?]/)||"~"==v?"/^"+C[Q].substring(1,C[Q].length-1).replace(/\\([btnfr\\"'])|([^\w\*\?])/g,"\\$1$2").replace(/([\*\?])/g,"[\\w\\W]$1")+
("~"==v?"$/i":"$/")+".test("+b+")":e}var B=0,C=[];c=c.replace(/"(\\.|[^"\\])*"|'(\\.|[^'\\])*'|[\[\]]/g,function(e){B+="["==e?1:"]"==e?-1:0;return"]"==e&&0<B?"`]":'"'==e.charAt(0)||"'"==e.charAt(0)?"`"+(C.push(e)-1):e});var m="";c.replace(/(\]|\)|push|pop|shift|splice|sort|reverse)\s*\(/,function(){throw Error("Unsafe function call");});c=c.replace(/([^<>=]=)([^=])/g,"$1\x3d$2").replace(/@|(\.\s*)?[a-zA-Z\$_]+(\s*:)?/g,function(e){return"."==e.charAt(0)?e:"@"==e?"$obj":(e.match(/:|^(\$|Math|true|false|null)$/)?
"":"$obj.")+e}).replace(/\.?\.?\[(`\]|[^\]])*\]|\?.*|\.\.([\w\$_]+)|\.\*/g,function(e,b,q){return(b=e.match(/^\.?\.?(\[\s*\^?\?|\^?\?|\[\s*==)(.*?)\]?$/))?(q="",e.match(/^\./)&&(m="dojox.json._find("+m,q=",true)"),m=(b[1].match(/=/)?"dojo.map":b[1].match(/\^/)?"dojox.json._distinctFilter":"dojo.filter")+"("+m,q+",function($obj){return "+b[2]+"})"):(b=e.match(/^\[\s*([\/\\].*)\]/))?".concat().sort(function(a,b){"+b[1].replace(/\s*,?\s*([\/\\])\s*([^,\\\/]+)/g,function(K,M,z){return"var av\x3d "+z.replace(/\$obj/,
"a")+",bv\x3d "+z.replace(/\$obj/,"b")+";if(av\x3ebv||bv\x3d\x3dnull){return "+("/"==M?1:-1)+";}\nif(bv\x3eav||av\x3d\x3dnull){return "+("/"==M?-1:1)+";}\n"})+"return 0;})":(b=e.match(/^\[(-?[0-9]*):(-?[0-9]*):?(-?[0-9]*)\]/))?(m="dojox.json._slice("+m,","+(b[1]||0)+","+(b[2]||0)+","+(b[3]||1)+")"):e.match(/^\.\.|\.\*|\[\s*\*\s*\]|,/)?(m="dojox.json._find("+m,("."==e.charAt(1)?",'"+q+"'":e.match(/,/)?","+e:"")+")"):e}).replace(/(\$obj\s*((\.\s*[\w_$]+\s*)|(\[\s*`([0-9]+)\s*`\]))*)(==|~)\s*`([0-9]+)/g,
n).replace(/`([0-9]+)\s*(==|~)\s*(\$obj\s*((\.\s*[\w_$]+)|(\[\s*`([0-9]+)\s*`\]))*)/g,function(e,b,q,K,M,z,v,Q){return n(e,K,M,z,v,Q,q,b)});c=m+("$"==c.charAt(0)?"":"$")+c.replace(/`([0-9]+|\])/g,function(e,b){return"]"==b?"]":C[b]});for(var y=eval("1\x26\x26function($,$1,$2,$3,$4,$5,$6,$7,$8,$9){var $obj\x3d$;return "+c+"}"),I=0;I<arguments.length-1;I++)arguments[I]=arguments[I+1];return w?y.apply(this,arguments):y}})},"esri/tasks/LegendLayer":function(){define(["dojo/_base/declare","dojo/_base/lang",
"dojo/has","../kernel"],function(D,a,d,c){D=D(null,{declaredClass:"esri.tasks.LegendLayer",layerId:null,subLayerIds:null});d("extend-esri")&&a.setObject("tasks.LegendLayer",D,c);return D})},"widgets/Screening/_build-generate_module":function(){define(["dojo/text!./Widget.html","dojo/text!./css/style.css","dojo/i18n!./nls/strings"],function(){})},"url:widgets/Screening/placename/placename.html":'\x3cdiv\x3e\r\n  \x3cdiv class\x3d"esriCTSearchOuterContainer"\x3e\r\n    \x3cdiv data-dojo-attach-point\x3d"searchHeader" class\x3d"esriCTSearchHeader" tabindex\x3d"0" aria-label\x3d"${nls.placenameWidget.placenameLabel}" role\x3d"presentation"\x3e\r\n      ${nls.placenameWidget.placenameLabel}\r\n    \x3c/div\x3e\r\n    \x3cdiv class\x3d"esriCTSearchContainer"\x3e\r\n      \x3cdiv class\x3d"esriCTSearchDiv"\x3e\r\n        \x3cdiv data-dojo-attach-point\x3d"searchWidgetContainer"\x3e\r\n        \x3c/div\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n  \x3c/div\x3e\r\n\x3c/div\x3e',
"url:esri/dijit/Search/templates/Search.html":'\x3cdiv role\x3d"presentation" class\x3d"${theme}"\x3e\r\n  \x3cdiv role\x3d"presentation" class\x3d"${css.searchGroup}" data-dojo-attach-point\x3d"containerNode"\x3e\r\n    \x3cdiv data-dojo-attach-point\x3d"expandNode" class\x3d"${css.searchExpandContainer}"\x3e\r\n      \x3cdiv class\x3d"${css.searchAnimateContainer}"\x3e\r\n        \x3cdiv role\x3d"button" title\x3d"${_i18n.widgets.Search.main.searchIn}" id\x3d"${id}_menu_button" class\x3d"${css.searchBtn} ${css.searchToggle}" tabindex\x3d"0" data-dojo-attach-point\x3d"sourcesBtnNode"\x3e\r\n          \x3cspan aria-hidden\x3d"true" role\x3d"presentation" class\x3d"${css.searchToggleIcon}"\x3e\x3c/span\x3e\x3cspan class\x3d"${css.searchSourceName}" data-dojo-attach-point\x3d"sourceNameNode"\x3e\x3c/span\x3e\r\n        \x3c/div\x3e\r\n        \x3cdiv class\x3d"${css.searchInputGroup}"\x3e\r\n          \x3cform data-dojo-attach-point\x3d"formNode"\x3e\r\n            \x3cinput maxlength\x3d"${maxLength}" autocomplete\x3d"off" type\x3d"text" tabindex\x3d"0" class\x3d"${css.searchInput}" value\x3d"${value}" aria-haspopup\x3d"true" id\x3d"${id}_input" data-dojo-attach-point\x3d"inputNode" role\x3d"textbox"\x3e\r\n          \x3c/form\x3e\r\n          \x3cdiv role\x3d"button" class\x3d"${css.searchClear}" tabindex\x3d"0" data-dojo-attach-point\x3d"clearNode"\x3e\x3cspan aria-hidden\x3d"true" class\x3d"${css.searchClearIcon}"\x3e\x3c/span\x3e\x3cspan aria-hidden\x3d"true" class\x3d"${css.searchSpinner}"\x3e\x3c/span\x3e\r\n          \x3c/div\x3e\r\n          \x3cdiv data-dojo-attach-point\x3d"suggestionsNode" class\x3d"${css.searchMenu} ${css.suggestionsMenu}"\x3e\x3c/div\x3e\r\n        \x3c/div\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n    \x3cdiv role\x3d"button" title\x3d"${_i18n.widgets.Search.main.searchButtonTitle}" class\x3d"${css.searchBtn} ${css.searchSubmit}" tabindex\x3d"0" data-dojo-attach-point\x3d"submitNode"\x3e\r\n      \x3cspan aria-hidden\x3d"true" role\x3d"presentation" class\x3d"${css.searchIcon}"\x3e\x3c/span\x3e\r\n      \x3cspan class\x3d"${css.searchButtonText}"\x3e${_i18n.widgets.Search.main.searchButtonTitle}\x3c/span\x3e\r\n    \x3c/div\x3e\r\n    \x3cdiv data-dojo-attach-point\x3d"sourcesNode" class\x3d"${css.searchMenu} ${css.sourcesMenu}"\x3e\x3c/div\x3e\r\n    \x3cdiv data-dojo-attach-point\x3d"noResultsMenuNode" class\x3d"${css.searchMenu} ${css.searchNoResultsMenu}"\x3e\x3c/div\x3e\r\n    \x3cdiv class\x3d"${css.searchClearFloat}"\x3e\x3c/div\x3e\r\n  \x3c/div\x3e\r\n\x3c/div\x3e',
"url:widgets/Screening/drawTool/drawTool.html":'\x3cdiv\x3e\r\n  \x3cdiv tabindex\x3d"0" role\x3d"presentation" aria-label\x3d"${nls.drawToolWidget.useDrawToolForAOILabel}"\r\n    class\x3d"esriCTDrawBoxLabel" data-dojo-attach-point\x3d"drawToolHeader"\x3e${nls.drawToolWidget.useDrawToolForAOILabel}\x3c/div\x3e\r\n  \x3cdiv class\x3d"esriCTDrawToolIconsParentDiv" data-dojo-attach-point\x3d"drawToolIconsParentDiv"\x3e\r\n  \x3c/div\x3e\r\n  \x3cdiv class\x3d"esriCTSelectToolParentDiv" data-dojo-attach-point\x3d"selectToolParent"\x3e\r\n    \x3cdiv class\x3d"esriCTSelectToolDiv" data-dojo-attach-point\x3d"selectToolDiv"\x3e\r\n    \x3c/div\x3e\r\n  \x3c/div\x3e\r\n  \x3cdiv class\x3d"esriCTWidgetAndBufferSeparator esriCTHidden" data-dojo-attach-point\x3d"seperatorAfterSelect"\x3e\r\n  \x3c/div\x3e\r\n  \x3c!-- Layer chooser starts --\x3e\r\n  \x3cdiv class\x3d"esriCTParentDivOfChooseSymbol esriCTHidden" data-dojo-attach-point\x3d"parentDivOfChooseSymbol"\x3e\r\n    \x3cdiv class\x3d"esriCTExpandCollapseParentContainer"\x3e\r\n      \x3cdiv class\x3d"esriCTLayerPanelOfSelectIcon esriCTLayerPanelExpandIcon" data-dojo-attach-point\x3d"layerSectionIcon"\r\n        role\x3d"button" tabindex\x3d"0" aria-label\x3d"${nls.drawToolWidget.chooseLayerTitle}" aria-expanded\x3d"false"\x3e\r\n      \x3c/div\x3e\r\n      \x3cdiv class\x3d"esriCTSelectableLayerTitle esriCTEllipsis" data-dojo-attach-point\x3d"impactSummaryLayerTitle"\r\n        title\x3d"${nls.drawToolWidget.chooseLayerTitle}"\x3e\r\n        ${nls.drawToolWidget.chooseLayerTitle}\r\n      \x3c/div\x3e\r\n      \x3cdiv class\x3d"esriCTImpactSummaryLayerMaxRecordHint esriCTHidden esriCTCursorPointer"\r\n        data-dojo-attach-point\x3d"singleLayerSelectionWarning" title\x3d"${nls.drawToolWidget.layerSelectionWarningTooltip}"\r\n        role\x3d"button" tabindex\x3d"0" aria-label\x3d"${nls.drawToolWidget.layerSelectionWarningTooltip}"\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n    \x3cdiv data-dojo-attach-point\x3d"entireLayerParentContainer" class\x3d"esriCTHidden"\x3e\r\n      \x3cdiv class\x3d"jimu-widget-screening-selectable-layer-item no-action"\x3e\r\n        \x3cdiv class\x3d"layer-row"\x3e\r\n          \x3cdiv class\x3d"selectable-check checked" title\x3d"${nls.drawToolWidget.selectAllLayersText}"\r\n            data-dojo-attach-point\x3d"selectAllLayers" role\x3d"checkbox" tabindex\x3d"0"\r\n            aria-label\x3d"${nls.drawToolWidget.selectAllLayersText}" aria-checked\x3d"true"\x3e\r\n          \x3c/div\x3e\r\n          \x3cdiv class\x3d"layer-name jimu-ellipsis" title\x3d"${nls.drawToolWidget.selectAllLayersText}"\x3e\r\n            ${nls.drawToolWidget.selectAllLayersText}\x3c/div\x3e\r\n        \x3c/div\x3e\r\n      \x3c/div\x3e\r\n      \x3cdiv class\x3d"layer-nodes" data-dojo-attach-point\x3d"layerItemsNode"\x3e\r\n        \x3cdiv class\x3d"esriCTLayerItems"\x3e\x3c/div\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n  \x3c/div\x3e\r\n  \x3c!-- Layer chooser ends --\x3e\r\n\x3c/div\x3e',
"url:jimu/dijit/templates/FeatureSetChooserForMultipleLayers.html":'\x3cdiv class\x3d"jimu-not-selectable"\x3e\r\n  \x3cdiv class\x3d"draw-item-btn" tabindex\x3d"0"\x3e\r\n    \x3cdiv class\x3d"current-draw-item" data-dojo-attach-point\x3d"currentDrawItem"\x3e\r\n      \x3cdiv class\x3d"btn-select" data-dojo-attach-point\x3d"btnSelect"\x3e\r\n        \x3cdiv class\x3d"labels"\x3e\r\n            \x3cdiv class\x3d"feature-action" data-dojo-attach-point\x3d"geoTypeIcon"\x3e\x3c/div\x3e\r\n            \x3cdiv class\x3d"select-text"\x3e\x3c/div\x3e\r\n        \x3c/div\x3e\r\n        \x3cdiv class\x3d"arrow feature-action icon-drop-down" data-dojo-attach-event\x3d"click:_onArrowClicked"\x3e\x3c/div\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n  \x3c/div\x3e\r\n  \x3cdiv class\x3d"btn-clear" data-dojo-attach-point\x3d"btnClear" tabindex\x3d"0"\x3e\r\n    \x3cdiv class\x3d"feature-action icon-clear-selection"\x3e\x3c/div\x3e\x3cdiv class\x3d"clear-text"\x3e\x3c/div\x3e\r\n  \x3c/div\x3e\r\n\x3c/div\x3e',
"url:widgets/Screening/drawTool/SelectableLayerItem.html":'\x3cdiv\x3e\r\n  \x3cdiv class\x3d"layer-row" data-dojo-attach-point\x3d"layerContent"\x3e\r\n    \x3cdiv class\x3d"selectable-check" title\x3d"${nls.drawToolWidget.toggleSelectability}"\r\n      data-dojo-attach-point\x3d"selectableCheckBox" tabindex\x3d"0" role\x3d"checkbox" aria-checked\x3d"true"\x3e\r\n    \x3c/div\x3e\r\n    \x3cdiv class\x3d"layer-name jimu-ellipsis" data-dojo-attach-point\x3d"layerNameNode"\x3e\x3c/div\x3e\r\n  \x3c/div\x3e\r\n\x3c/div\x3e',
"url:widgets/Screening/shapefile/shapefile.html":'\x3cdiv\x3e\r\n  \x3cdiv class\x3d"esriCTUploadShapefileText"\x3e\r\n    ${label}\r\n  \x3c/div\x3e\r\n  \x3cdiv class\x3d"esriCTUploadShapefileButtonDiv"\x3e\r\n    \x3cform enctype\x3d"multipart/form-data" method\x3d"post" data-dojo-attach-point\x3d"uploadForm"\x3e\r\n      \x3cdiv class\x3d\'jimu-btn jimu-float-trailing jimu-trailing-margin1 esriCTUploadShapefileButton\'\r\n        title\x3d"${label}" data-dojo-attach-point\x3d"uploadShapefileButton"\r\n        role\x3d"button" aria-label\x3d"${label}" tabindex\x3d"0"\x3e\r\n        ${nls.shapefileWidget.uploadShapefileButtonText}\r\n      \x3c/div\x3e\r\n      \x3cinput title\x3d"${label}" data-dojo-attach-point\x3d"shapefileInput"\r\n        type\x3d"file" name\x3d"file" accept\x3d".zip" tabindex\x3d"-1" class\x3d"esriCTHidden" /\x3e\r\n    \x3c/form\x3e\r\n  \x3c/div\x3e\r\n\x3c/div\x3e',
"url:widgets/Screening/coordinates/coordinates.html":'\x3cdiv\x3e\r\n  \x3c!--Coordinates parent container--\x3e\r\n  \x3cdiv class\x3d"esriCTCoordinatesParentDiv"\x3e\r\n    \x3c!--Select start point from Search dijit div--\x3e\r\n    \x3cdiv class\x3d"esriCTSelectStartPointFromSearchDiv" data-dojo-attach-point\x3d"selectStartPointFromSearchDiv"\x3e\r\n      \x3cdiv class\x3d"esriCTSearchOuterContainer"\x3e\r\n        \x3cdiv tabindex\x3d"0" role\x3d"presentation" aria-label\x3d" ${nls.coordinatesWidget.selectStartPointFromSearchText}"\r\n          class\x3d"esriCTSearchHeader" data-dojo-attach-point\x3d"coordinatesHeader"\x3e\r\n          ${nls.coordinatesWidget.selectStartPointFromSearchText}\r\n        \x3c/div\x3e\r\n        \x3cdiv class\x3d"esriCTSearchContainer"\x3e\r\n          \x3cdiv class\x3d"esriCTSearchDiv"\x3e\r\n            \x3cdiv data-dojo-attach-point\x3d"searchWidgetContainerCoordinatesTab"\x3e\r\n            \x3c/div\x3e\r\n          \x3c/div\x3e\r\n          \x3c!--Locate icon for start point node--\x3e\r\n          \x3cdiv class\x3d"esriCTLocateImageNode" title\x3d"${nls.coordinatesWidget.locateByMapClickText}"\r\n            data-dojo-attach-point\x3d"locateStartPointIcon" role\x3d"button" tabindex\x3d"0"\r\n            aria-label\x3d"${nls.coordinatesWidget.locateByMapClickText}"\x3e\r\n          \x3c/div\x3e\r\n        \x3c/div\x3e\r\n      \x3c/div\x3e\r\n      \x3c!--Select start point from latitude and longitude div--\x3e\r\n      \x3cdiv class\x3d"esriCTLatLongInputLabelParentContainer"\x3e\r\n        \x3cdiv class\x3d"esriCTLatLongInputLabelChildContainer"\x3e\r\n          \x3cdiv class\x3d"esriCTLatitudeLabel" data-a11y-label-id\x3d"${id}latitude"\x3e\r\n            ${nls.common.latitude}\r\n          \x3c/div\x3e\r\n          \x3cdiv class\x3d"esriCTLongitudeLabel" data-a11y-label-id\x3d"${id}longitude"\x3e\r\n            ${nls.common.longitude}\r\n          \x3c/div\x3e\r\n        \x3c/div\x3e\r\n        \x3cdiv\x3e\r\n          \x3c!--Latitude textbox--\x3e\r\n          \x3cinput class\x3d"esriCTLatTextBox" data-dojo-type\x3d"dijit/form/NumberTextBox"\r\n            data-dojo-attach-point\x3d\'latitudeTextBox\' placeholder\x3d"${nls.common.latitude}" required role\x3d"textbox"\r\n            aria-required\x3d"true" data-a11y-label-by\x3d"${id}latitude" /\x3e\r\n          \x3c!--Longitude textbox--\x3e\r\n          \x3cinput class\x3d"esriCTLongTextBox" data-dojo-type\x3d"dijit/form/NumberTextBox"\r\n            data-dojo-attach-point\x3d\'longitudeTextBox\' placeholder\x3d"${nls.common.longitude}" required role\x3d"textbox"\r\n            aria-required\x3d"true" data-a11y-label-by\x3d"${id}longitude" /\x3e\r\n          \x3c!--Locate for lat long text--\x3e\r\n          \x3cdiv class\x3d"esriCTLocateForLatLongText" title\x3d"${nls.coordinatesWidget.locateText}"\r\n            data-dojo-attach-point\x3d"locateLatAndLong" role\x3d"button" tabindex\x3d"0"\r\n            aria-label\x3d"${nls.coordinatesWidget.locateText}"\x3e\r\n            ${nls.coordinatesWidget.locateText}\r\n          \x3c/div\x3e\r\n        \x3c/div\x3e\r\n      \x3c/div\x3e\r\n      \x3c!-- Traverse grid container--\x3e\r\n      \x3cdiv class\x3d"esriCTNewTraverseContainer" data-dojo-attach-point\x3d"traverseGridMainContainer"\x3e\r\n        \x3cdiv class\x3d"esriCTBearingDistanceParentDiv"\x3e\r\n          \x3c!--Enter bearing and distance label parent div--\x3e\r\n          \x3cdiv tabindex\x3d"0" role\x3d"presentation" data-dojo-attach-point\x3d"startPointSection"\r\n          class\x3d"esriCTEnterBearingAndDistanceLabelDiv"\x3e\r\n            ${nls.coordinatesWidget.enterBearingAndDistanceLabel}\r\n          \x3c/div\x3e\r\n          \x3cdiv class\x3d"esriCTPlanSettingsIcon" data-dojo-attach-point\x3d"planSettingIcon"\r\n            title\x3d"${nls.coordinatesWidget.planSettingTooltip}" role\x3d"button" tabindex\x3d"0"\r\n            aria-label\x3d"${nls.coordinatesWidget.planSettingTooltip}"\x3e\r\n          \x3c/div\x3e\r\n        \x3c/div\x3e\r\n        \x3c!-- Traverse grid title--\x3e\r\n        \x3cdiv class\x3d"esriCTNewTraverseLabelDiv"\x3e\r\n          \x3cdiv class\x3d"esriCTGridLabels esriCTEllipsis" title\x3d"${nls.traverseSettings.bearingLabel}"\x3e\r\n            ${nls.traverseSettings.bearingLabel}\r\n          \x3c/div\x3e\r\n          \x3cdiv class\x3d"esriCTGridLabels esriCTEllipsis" title\x3d"${nls.traverseSettings.lengthLabel}"\x3e\r\n            ${nls.traverseSettings.lengthLabel}\r\n          \x3c/div\x3e\r\n        \x3c/div\x3e\r\n        \x3c!-- Traverse grid items--\x3e\r\n        \x3cdiv class\x3d"esriCTTraverseGrid" data-dojo-attach-point\x3d"traverseGrid"\x3e\r\n        \x3c/div\x3e\r\n        \x3c!-- Traverse grid initial entry row--\x3e\r\n        \x3cdiv class\x3d"esriCTEntryNodeContent esriCTRow" data-dojo-attach-point\x3d"traverseEntryNode"\x3e\r\n          \x3cdiv data-dojo-attach-point\x3d"bearingNode" data-dojo-type\x3d"dijit/form/ValidationTextBox" required\r\n            role\x3d"textbox" aria-label\x3d"${nls.traverseSettings.bearingLabel}"\x3e\r\n          \x3c/div\x3e\r\n          \x3cdiv data-dojo-attach-point\x3d"lengthNode" data-dojo-type\x3d"dijit/form/ValidationTextBox" required role\x3d"textbox"\r\n            aria-label\x3d"${nls.traverseSettings.lengthLabel}"\x3e\r\n          \x3c/div\x3e\r\n          \x3cdiv class\x3d"esriCTAddRow"\x3e\r\n            \x3cdiv class\x3d"esriCTAddDisabledIcon" data-dojo-attach-point\x3d"addButton" tabindex\x3d"-1" role\x3d"button"\r\n              title\x3d"${nls.traverseSettings.addButtonTitle}" aria-label\x3d"${nls.traverseSettings.addButtonLabel}"\x3e\r\n            \x3c/div\x3e\r\n          \x3c/div\x3e\r\n        \x3c/div\x3e\r\n        \x3c!-- Traverse grid tools container--\x3e\r\n        \x3cdiv class\x3d"esriCTTraverseTool"\x3e\r\n          \x3cdiv class\x3d"esriCTTraverseToolContainer"\x3e\r\n            \x3c!-- Expand/Collapse grid tool--\x3e\r\n            \x3cdiv class\x3d"esriCTHidden  esriCTTraverseToolIcons esriCTCollapse esriCTCursorPointer"\r\n              title\x3d"${nls.planSettings.collapseGridTooltipText}" data-dojo-attach-point\x3d"expandCollapseNode"\r\n              role\x3d"button" tabindex\x3d"-1" aria-label\x3d"${nls.planSettings.collapseGridTooltipText}" aria-expanded\x3d"true"\x3e\r\n            \x3c/div\x3e\r\n          \x3c/div\x3e\r\n        \x3c/div\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n  \x3c/div\x3e',
"url:widgets/Screening/impactSummaryReport/impactSummaryReport.html":'\x3cdiv\x3e\r\n  \x3cdiv class\x3d"esriCTImpactSummaryLayerContainer" data-dojo-attach-point\x3d"impactSummaryLayerContainer"\x3e\r\n    \x3c!--title \x26 field icon table--\x3e\r\n    \x3cdiv class\x3d"esriCTLayerTitleAndFieldParentContainer esriCTLayerSectionDisabled esriCTCursorPointer"\r\n      data-dojo-attach-point\x3d"layerTitleAndFieldParentContainer" tabindex\x3d"0" role\x3d"group"\x3e\r\n      \x3c!--title \x26 field icon row--\x3e\r\n      \x3cdiv class\x3d"esriCTLayerTitleAndFieldChildContainer"\x3e\r\n        \x3cdiv class\x3d"esriCTLayerPanelIcon esriCTLayerPanelExpand" data-dojo-attach-point\x3d"layerSectionIcon" tabindex\x3d"-1"\r\n          role\x3d"button" aria-expanded\x3d"false" aria-label\x3d"${nls.reportsTab.expandCollapseIconLabel}"\x3e\r\n        \x3c/div\x3e\r\n        \x3c!--title--\x3e\r\n        \x3cdiv class\x3d"esriCTImpactSummaryLayerTitle" data-dojo-attach-point\x3d"impactSummaryLayerTitle"\x3e\r\n        \x3c/div\x3e\r\n        \x3c!--field icon--\x3e\r\n        \x3cdiv class\x3d"esriCTImpactSummaryLayerFieldIcon esriCTImpactSummaryLayerFieldIconDisabled"\r\n          data-dojo-attach-point\x3d"impactSummaryLayerField" title\x3d"${nls.reportsTab.attributeChooserTooltip}"\r\n          tabindex\x3d"-1" aria-label\x3d"${nls.reportsTab.attributeChooserTooltip}" role\x3d"button"\x3e\x3c/div\x3e\r\n        \x3c!--feature count--\x3e\r\n        \x3cdiv class\x3d"esriCTImpactSummaryLayerFeatureCount esriCTLoadingIcon"\r\n          data-dojo-attach-point\x3d"impactSummaryLayerFeatureCount"\x3e\x3c/div\x3e\r\n        \x3c!-- Hint for count exceeding max record count --\x3e\r\n        \x3cdiv class\x3d"esriCTImpactSummaryLayerMaxRecordHint esriCTHidden" title\x3d"${nls.reportsTab.unableToAnalyzeText}"\r\n          data-dojo-attach-point\x3d"impactSummaryLayerMaxRecordHint" tabindex\x3d"-1" role\x3d"button"\r\n          aria-label\x3d"${nls.reportsTab.unableToAnalyzeText}"\x3e\x3c/div\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n    \x3c!--layer description--\x3e\r\n    \x3cdiv class\x3d"esriCTImpactSummaryLayerDetailContainer esriCTHidden"\r\n      data-dojo-attach-point\x3d"impactSummaryLayerDetailContainer"\x3e\r\n      \x3cdiv data-dojo-attach-point\x3d"impactSummaryLayerDetailsMsg" class\x3d"esriCTImpactSummaryLayerDetailsMsg"\x3e\x3c/div\x3e\r\n      \x3cdiv data-dojo-attach-point\x3d"impactSummaryLayerDetails" class\x3d"esriCTImpactSummaryLayerDetails"\x3e\x3c/div\x3e\r\n      \x3cdiv data-dojo-attach-point\x3d"noFieldsSelectedContainer" class\x3d"esriCTNoFieldSelectedContainer esriCTHidden"\x3e\r\n        ${nls.reportsTab.noFieldsSelected}\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n  \x3c/div\x3e\r\n\x3c/div\x3e',
"url:jimu/dijit/templates/ReportTemplate.html":'\x3c!DOCTYPE HTML\x3e\r\n\x3chtml lang\x3d"en" dir\x3d"ltr"\x3e\r\n\r\n\x3chead id\x3d"reportHead"\x3e\r\n  \x3cmeta charset\x3d"utf-8"\x3e\r\n  \x3cmeta http-equiv\x3d"X-UA-Compatible" content\x3d"IE\x3dEdge,chrome\x3d1"\x3e\r\n  \x3ctitle\x3e\x3c/title\x3e\r\n  \x3cscript\x3e\r\n    // Show/hide text area controls based on the value\r\n    function onPrintButtonClicked() {\r\n      var notesContainer, i;\r\n      notesContainer \x3d document.getElementsByClassName("esriCTNotesContainer");\r\n      //process notes to show/hide based on contents\r\n      for (i \x3d 0; i \x3c notesContainer.length; i++) {\r\n        if (notesContainer[i]) {\r\n          //Hide the notes which are not having values\r\n          if (notesContainer[i].children[1].value.trim() \x3d\x3d\x3d "") {\r\n            notesContainer[i].className +\x3d " esriCTHideReportNotes";\r\n          }\r\n          else {\r\n            //Removes hidden class if available\r\n            notesContainer[i].className \x3d\r\n              notesContainer[i].className.replace("esriCTHideReportNotes", "");\r\n          }\r\n        }\r\n      }\r\n      //after processing notes, print the window\r\n      window.print();\r\n    }\r\n  \x3c/script\x3e\r\n  \x3c!-- Report prev page css --\x3e\r\n  \x3cstyle type\x3d"text/css"\x3e\r\n    .esriCTReportMapWait {\r\n      height: 5px;\r\n      width: 100%;\r\n      position: relative;\r\n      overflow: hidden;\r\n      background-color: #ddd;\r\n    }\r\n\r\n    .esriCTReportMapWait:before {\r\n      display: block;\r\n      position: absolute;\r\n      content: "";\r\n      left: -200px;\r\n      width: 200px;\r\n      height: 5px;\r\n      background-color: #2980b9;\r\n      animation: loading 2s linear infinite;\r\n    }\r\n\r\n    @keyframes loading {\r\n      from {\r\n        left: -200px;\r\n        width: 30%;\r\n      }\r\n      50% {\r\n        width: 30%;\r\n      }\r\n      70% {\r\n        width: 70%;\r\n      }\r\n      80% {\r\n        left: 50%;\r\n      }\r\n      95% {\r\n        left: 120%;\r\n      }\r\n      to {\r\n        left: 100%;\r\n      }\r\n    }\r\n\r\n    .esriCTHTMLData {\r\n      position: relative;\r\n      width: 100%;\r\n      height: auto;\r\n    }\r\n\r\n    .jimu-rtl .esriCTHTMLData {\r\n      direction: rtl;\r\n    }\r\n\r\n    .esriCTTable {\r\n      margin-top: 10px;\r\n      padding: 0;\r\n      border-collapse: collapse;\r\n      border-spacing: 0;\r\n      width: 100%;\r\n      page-break-inside: avoid;\r\n      table-layout: fixed;\r\n    }\r\n\r\n    .jimu-rtl .esriCTTable {\r\n      direction: rtl;\r\n    }\r\n\r\n    .esriCTTable th {\r\n      border: 1px solid gray;\r\n      background-color: #E4E4E4;\r\n      word-wrap: break-word;\r\n    }\r\n\r\n    .esriCTTable td {\r\n      border: 1px solid gray;\r\n      word-wrap: break-word;\r\n    }\r\n\r\n    .esriCTSectionTitle {\r\n      font-size: 18px;\r\n      color: #0f96cc;\r\n      font-weight: bold;\r\n      margin: 30px 0px;\r\n      width: calc(100% - 10px);\r\n      word-break: break-all;\r\n    }\r\n\r\n    .jimu-rtl .esriCTSectionTitle {\r\n      float: right;\r\n      direction: rtl;\r\n    }\r\n\r\n    .jimu-rtl .esriCTReportMap .esriCTSectionTitle {\r\n      float: none;\r\n    }\r\n\r\n    .esriCTReportLogo {\r\n      float: left;\r\n      max-width: calc(50% - 10px);\r\n      margin: auto 10px auto 0;\r\n      max-height: 90%;\r\n      position: absolute;\r\n      top: 0;\r\n      bottom: 0;\r\n    }\r\n\r\n    .jimu-rtl .esriCTReportLogo {\r\n      float: right;\r\n      margin: auto 0 auto 10px;\r\n    }\r\n\r\n    .esriCTPrintTitleDiv {\r\n      height: 56px;\r\n      float: right;\r\n      min-width: 50%;\r\n    }\r\n\r\n    .jimu-rtl .esriCTPrintTitleDiv {\r\n      float: left;\r\n      direction: rtl;\r\n    }\r\n\r\n    .esriCTInputTitle {\r\n      height: 55px;\r\n      line-height: 55px;\r\n      border: none;\r\n      font-size: 25px;\r\n      width: 100%;\r\n      padding: 0px;\r\n    }\r\n\r\n    .esriCTInputTitle::-ms-clear {\r\n      display: none;\r\n    }\r\n\r\n    .esriCTReportMain {\r\n      background: #FFF;\r\n      border: solid 1px #000;\r\n      margin: 0 auto;\r\n      padding: 20px;\r\n      width: 797px;\r\n    }\r\n\r\n    .esriCTReportMap {\r\n      text-align: center;\r\n    }\r\n\r\n    .esriCTReportMapImg {\r\n      max-width: 96%;\r\n      margin-top: 10px;\r\n    }\r\n\r\n    .esriCTReportLandscapeMapImg {\r\n      max-width: 80%;\r\n    }\r\n\r\n    .esriCTReportMapFail {\r\n      height: 50px;\r\n    }\r\n\r\n    .esriCTReportFooter {\r\n      text-align: center;\r\n      font-size: 80%;\r\n      padding: 10px 0;\r\n      white-space: pre-wrap;\r\n      word-wrap: break-word;\r\n    }\r\n\r\n    .esriCTPrintPage {\r\n      padding: 30px 0;\r\n      margin: 20px auto;\r\n      font-family: arial, sans-serif;\r\n      font-size: 13px;\r\n    }\r\n\r\n    .esriCTReportBar {\r\n      width: 100%;\r\n      position: fixed;\r\n      left: 0;\r\n      top: 0;\r\n      z-index: 6;\r\n      height: 50px;\r\n      background: #e2f1fc;\r\n      border-bottom: 1px solid #000;\r\n    }\r\n\r\n    .jimu-rtl .esriCTReportBar {\r\n      left: inherit;\r\n      right: 0;\r\n    }\r\n\r\n    .esriCTPrintButton,\r\n    .esriCTCloseButton {\r\n      color: #444;\r\n      font-family: Verdana, Helvetica, sans-serif;\r\n      font-size: 12px;\r\n      -moz-border-radius: 3px;\r\n      -webkit-border-radius: 3px;\r\n      border-radius: 3px;\r\n      border: 1px solid #8b8b8b;\r\n      box-shadow: none;\r\n      -webkit-box-shadow: none;\r\n      background: #F2F2F2;\r\n      background: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2ZmZmZmZiIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiNlNWU1ZTUiIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+);\r\n      background: -moz-linear-gradient(top, #F2F2F2 0%, #D1D1D1 100%);\r\n      background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #F2F2F2), color-stop(100%, #D1D1D1));\r\n      background: -webkit-linear-gradient(top, #F2F2F2 0%, #D1D1D1 100%);\r\n      background: -o-linear-gradient(top, #F2F2F2 0%, #D1D1D1 100%);\r\n      background: -ms-linear-gradient(top, #F2F2F2 0%, #D1D1D1 100%);\r\n      background: linear-gradient(to bottom, #F2F2F2 0%, #D1D1D1 100%);\r\n      filter: progid: DXImageTransform.Microsoft.gradient(startColorstr\x3d\'#F2F2F2\', endColorstr\x3d\'#D1D1D1\', GradientType\x3d0);\r\n      margin: 10px 20px;\r\n      line-height: 16px;\r\n      display: block;\r\n      padding: 5px 10px;\r\n      outline: 0;\r\n      text-decoration: none;\r\n      cursor: pointer;\r\n      font-weight: 400;\r\n      white-space: nowrap;\r\n      float: right;\r\n    }\r\n\r\n    .jimu-rtl .esriCTPrintButton,\r\n    .jimu-rtl .esriCTCloseButton {\r\n      float: left;\r\n    }\r\n\r\n    .esriCTPrintButton:hover,\r\n    .esriCTPrintButton:focus,\r\n    .esriCTCloseButton:hover,\r\n    .esriCTCloseButton:focus {\r\n      background: #E5E6E6;\r\n      background: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2ZmZmZmZiIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiNlNWU1ZTUiIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+);\r\n      background: -moz-linear-gradient(top, #E5E6E6 0%, #A0A1A1 100%);\r\n      background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #E5E6E6), color-stop(100%, #A0A1A1));\r\n      background: -webkit-linear-gradient(top, #E5E6E6 0%, #A0A1A1 100%);\r\n      background: -o-linear-gradient(top, #E5E6E6 0%, #A0A1A1 100%);\r\n      background: -ms-linear-gradient(top, #E5E6E6 0%, #A0A1A1 100%);\r\n      background: linear-gradient(to bottom, #E5E6E6 0%, #A0A1A1 100%);\r\n      filter: progid: DXImageTransform.Microsoft.gradient(startColorstr\x3d\'#E5E6E6\', endColorstr\x3d\'#A0A1A1\', GradientType\x3d0);\r\n    }\r\n\r\n    .esriCTReportHeader {\r\n      display: block;\r\n      width: 100%;\r\n      height: 60px;\r\n      border-bottom: 1px solid #000;\r\n      margin-bottom: 5px;\r\n      position: relative;\r\n    }\r\n\r\n    .esriCTReportBarMsg {\r\n      text-align: center;\r\n      margin-top: 16px;\r\n    }\r\n\r\n    .jimu-rtl .esriCTReportBarMsg {\r\n      direction: rtl;\r\n    }\r\n\r\n    .esriCTNotesContainer {\r\n      width: 100%;\r\n      margin-top: 30px;\r\n    }\r\n\r\n    .esriCTReportNotes {\r\n      resize: none;\r\n      width: calc(100% - 5px);\r\n      max-width: calc(100% - 5px);\r\n      font-family: "Arial";\r\n      font-size: 13px;\r\n      border: 1px solid gray;\r\n      overflow-y: hidden;\r\n      /* prevents scroll bar flash */\r\n    }\r\n\r\n    .esriCTReportNotesParagraph {\r\n      display: none;\r\n      white-space: pre-wrap;\r\n      word-wrap: break-word;\r\n    }\r\n\r\n    .jimu-rtl .esriCTReportNotesParagraph {\r\n      float: right;\r\n      direction: rtl;\r\n    }\r\n\r\n    .jimu-rtl .esriCTReportNotes {\r\n      direction: rtl;\r\n    }\r\n\r\n    .esriCTHidden {\r\n      display: none;\r\n    }\r\n  \x3c/style\x3e\r\n  \x3c!-- Media print css --\x3e\r\n  \x3cstyle type\x3d"text/css" media\x3d"print"\x3e\r\n    .esriCTPrintPage {\r\n      padding: 0;\r\n      color: #000;\r\n      margin: 0;\r\n      float: none;\r\n      background: #fff url(none);\r\n    }\r\n\r\n    .esriCTTable {\r\n      page-break-inside: avoid;\r\n      border-collapse: collapse;\r\n      border-spacing: 0;\r\n    }\r\n\r\n    .esriCTPageBreak {\r\n      page-break-after: always;\r\n    }\r\n\r\n    .esriCTReportFooter {\r\n      font-size: 75%;\r\n    }\r\n\r\n    .esriCTReportBar {\r\n      display: none;\r\n    }\r\n\r\n    .esriCTReportMain {\r\n      border: none;\r\n    }\r\n\r\n    .esriCTReportMapImg {\r\n      box-shadow: none;\r\n      border: none;\r\n    }\r\n\r\n    .esriCTReportNotes {\r\n      display: none;\r\n    }\r\n\r\n    .esriCTReportNotesParagraph {\r\n      display: block;\r\n    }\r\n\r\n    .esriCTHideReportNotes {\r\n      display: none;\r\n    }\r\n\r\n    .esriCTTable th {\r\n      border: 1px solid gray;\r\n    }\r\n\r\n    .esriCTTable td {\r\n      border: 1px solid gray;\r\n    }\r\n\r\n    .esriCTTable tr {\r\n      page-break-inside: avoid;\r\n      page-break-after: auto;\r\n    }\r\n\r\n  \x3c/style\x3e\r\n  \x3cscript\x3e\r\n    function showError(evt) {\r\n      alert(document.getElementById(\'showErrorButton\').innerHTML);\r\n    }\r\n  \x3c/script\x3e\r\n\x3c/head\x3e\r\n\r\n\x3cbody id\x3d"reportBody" class\x3d"esriCTPrintPage"\x3e\r\n  \x3cbutton id\x3d"showErrorButton" style\x3d"display: none" onclick\x3d"showError()"\x3e\x3c/button\x3e\r\n  \x3cdiv class\x3d"esriCTReportBar"\x3e\r\n    \x3cdiv id\x3d"closeButton" class\x3d"esriCTCloseButton" title\x3d"Close" onclick\x3d"window.close();"\x3eClose\x3c/div\x3e\r\n    \x3cdiv id\x3d"printButton" class\x3d"esriCTPrintButton" title\x3d"Print" onclick\x3d"onPrintButtonClicked();"\x3ePrint\x3c/div\x3e\r\n    \x3cdiv id\x3d"reportBarMsg" class\x3d"esriCTReportBarMsg"\x3e\x3c/div\x3e\r\n  \x3c/div\x3e\r\n  \x3cdiv id\x3d"reportMain" class\x3d"esriCTReportMain"\x3e\r\n    \x3cdiv id\x3d"reportHeader" class\x3d"esriCTReportHeader"\x3e\r\n      \x3cimg id\x3d"reportLogo" class\x3d"esriCTReportLogo esriCTHidden" src\x3d""\x3e\r\n      \x3cdiv id\x3d"printTitleDiv" class\x3d"esriCTPrintTitleDiv"\x3e\r\n        \x3cinput id\x3d"reportTitle" type\x3d"text" class\x3d"esriCTInputTitle" tabindex\x3d"0" role\x3d"textbox"\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n    \x3cdiv id\x3d"reportData"\x3e\x3c/div\x3e\r\n    \x3cdiv id\x3d"footNotes" class\x3d"esriCTReportFooter"\x3e\r\n    \x3c/div\x3e\r\n  \x3c/div\x3e\r\n\x3c/body\x3e\r\n\r\n\x3c/html\x3e',
"url:widgets/Screening/Widget.html":'\x3cdiv style\x3d"height:100%; overflow:hidden;"\x3e\r\n\t\x3cdiv data-dojo-attach-point\x3d"widgetMainContainer" style\x3d"height: 100%"\x3e\r\n\t\t\x3cdiv class\x3d"esriCTTabContainerParentElement" data-dojo-attach-point\x3d"tabContainerParentElement"\x3e\r\n\t\t\t\x3cdiv class\x3d"esriCTTabLabelMainContainer"\x3e\r\n\t\t\t\t\x3cdiv data-dojo-attach-point\x3d"aoiLabelContainer" tabindex\x3d"0" class\x3d"esriCTAOILabelContainer esriCTTabsOverflowText" role\x3d"presentation"\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3cdiv data-dojo-attach-point\x3d"reportLabelContainer" tabindex\x3d"0"\r\n\t\t\t\t\tclass\x3d"esriCTReportLabelContainer esriCTTabsOverflowText esriCTHidden" role\x3d"presentation"\x3e\x3c/div\x3e\r\n\t\t\t\t\x3c!-- Zoom tool--\x3e\r\n\t\t\t\t\x3cdiv title\x3d"${nls.zoomToLocationTooltipText}" class\x3d"esriCTTraverseToolIcons esriCTZoomToDisableIcon"\r\n\t\t\t\t\tdata-dojo-attach-point\x3d"zoomToNode" tabindex\x3d"-1" role\x3d"button"\r\n\t\t\t\t\taria-label\x3d"${nls.zoomToLocationTooltipText}" aria-disabled\x3d"true"\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\x3c/div\x3e\r\n\t\t\t\x3c!--AOI Tab--\x3e\r\n\t\t\t\x3cdiv class\x3d"esriCTAOITabParentContainer" data-dojo-attach-point\x3d"aoiTabParentContainer"\x3e\r\n\t\t\t\t\x3c!--AOI Buttons--\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTAOIButtonParentContainer" data-dojo-attach-point\x3d"aoiButtonParentContainer"\r\n\t\t\t\t\trole\x3d"tablist"\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTPlacenameButton esriCTCursorPointer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"placenameButton" title\x3d"${config.placenameButtonText}" role\x3d"tab"\r\n\t\t\t\t\t\ttabindex\x3d"0" aria-label\x3d"${config.placenameButtonText}"\x3e\r\n\t\t\t\t\t\t${config.placenameButtonText}\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTDrawToolButton esriCTCursorPointer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"drawToolsButton" title\x3d"${config.drawToolsButtonText}" role\x3d"tab"\r\n\t\t\t\t\t\ttabindex\x3d"0" aria-label\x3d"${config.drawToolsButtonText}"\x3e\r\n\t\t\t\t\t\t${config.drawToolsButtonText}\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTShapefileButton esriCTCursorPointer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"shapefileButton" title\x3d"${config.shapefileButtonText}" role\x3d"tab"\r\n\t\t\t\t\t\ttabindex\x3d"0" aria-label\x3d"${config.shapefileButtonText}"\x3e\r\n\t\t\t\t\t\t${config.shapefileButtonText}\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTCoordinateButton esriCTCursorPointer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"coordinatesButton" title\x3d"${config.coordinatesButtonText}" role\x3d"tab"\r\n\t\t\t\t\t\ttabindex\x3d"0" aria-label\x3d"${config.coordinatesButtonText}"\x3e\r\n\t\t\t\t\t\t${config.coordinatesButtonText}\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3c!--AOI Widgets--\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTAOIWidgetParentContainer" data-dojo-attach-point\x3d"aoiWidgetParentContainer"\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTPlacenameWidgetContainer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"placenameWidgetContainer"\x3e\r\n\t\t\t\t\t\t\x3c!-- Placename widget container --\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTDrawToolWidgetContainer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"drawToolWidgetContainer"\x3e\r\n\t\t\t\t\t\t\x3c!-- Draw Tool widget container --\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTShapefileWidgetContainer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"shapefileWidgetContainer"\x3e\r\n\t\t\t\t\t\t\x3c!-- Shapefile widget container --\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTCoordinateWidgetContainer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"coordinateWidgetContainer"\x3e\r\n\t\t\t\t\t\t\x3c!-- Coordinates widget container --\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3c!--Widget \x26 Buffer separator--\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTWidgetAndBufferSeparator" data-dojo-attach-point\x3d"FeetWidgetAndBufferSeparator"\x3e\x3c/div\x3e\r\n\t\t\t\t\x3c!--AOI Buffer distance--\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTAOIBufferChangeParentContainer"\r\n\t\t\t\t\tdata-dojo-attach-point\x3d"aoiBufferChangeParentContainer"\x3e\r\n\t\t\t\t\t\x3c!-- Buffer distance (optional) --\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTBufferDistanceTitleContainer"\x3e\r\n\t\t\t\t\t\t${nls.bufferDistanceAndUnit.bufferInputTitle}\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c!-- Show results within --\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTBufferDistanceLabel"\x3e\r\n\t\t\t\t\t\t${nls.bufferDistanceAndUnit.bufferInputLabel}\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTBufferDistanceLabelTextBoxContainer"\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTBufferDistanceTextBoxContainer"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"bufferDistanceTextBoxContainer"\x3e\r\n\t\t\t\t\t\t\x3c!-- Buffer distance textbox --\x3e\r\n\t\t\t\t\t\t\x3cinput class\x3d"esriCTDistanceTextBox" data-dojo-type\x3d"dijit/form/NumberTextBox"\r\n\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"bufferDistanceTextBox" required\x3d"true"\r\n\t\t\t\t\t\t\taria-label\x3d"${nls.bufferDistanceAndUnit.bufferDistanceLabel}" role\x3d"textbox"\r\n\t\t\t\t\t\t\taria-required\x3d"true" /\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTBufferDistanceUnitSelectContainer"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"bufferDistanceUnitDropdownContainer"\x3e\r\n\t\t\t\t\t\t\x3c!-- Buffer unit dropdown --\x3e\r\n\t\t\t\t\t\t\x3cselect class\x3d"esriCTDistanceUnit" data-dojo-attach-point\x3d"bufferDistanceUnit"\r\n\t\t\t\t\t\t\tdata-dojo-type\x3d"jimu/dijit/formSelect"\r\n\t\t\t\t\t\t\taria-label\x3d"${nls.bufferDistanceAndUnit.bufferUnitLabel}"\x3e\r\n\t\t\t\t\t\t\t\x3coption value\x3d"UNIT_STATUTE_MILE"\x3e\r\n\t\t\t\t\t\t\t\t${nls.units.miles}\r\n\t\t\t\t\t\t\t\x3c/option\x3e\r\n\t\t\t\t\t\t\t\x3coption value\x3d"UNIT_KILOMETER"\x3e\r\n\t\t\t\t\t\t\t\t${nls.units.kilometers}\r\n\t\t\t\t\t\t\t\x3c/option\x3e\r\n\t\t\t\t\t\t\t\x3coption value\x3d"UNIT_FOOT"\x3e\r\n\t\t\t\t\t\t\t\t${nls.units.feet}\r\n\t\t\t\t\t\t\t\x3c/option\x3e\r\n\t\t\t\t\t\t\t\x3coption value\x3d"UNIT_METER"\x3e\r\n\t\t\t\t\t\t\t\t${nls.units.meters}\r\n\t\t\t\t\t\t\t\x3c/option\x3e\r\n\t\t\t\t\t\t\x3c/select\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3c!--Buffer \x26 Clear AOI Button separator--\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTWidgetAndBufferSeparator" data-dojo-attach-point\x3d"FeetWidgetAndBufferSeparator"\x3e\x3c/div\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTAOIButtonDivContainer"\x3e\r\n\t\t\t\t\t\x3c!--Report Button--\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTShowReportsButtonDiv"\x3e\r\n\t\t\t\t\t\t\x3cdiv data-dojo-attach-point\x3d"showReportsButton"\r\n\t\t\t\t\t\t\tclass\x3d"jimu-btn jimu-float-trailing esriCTShowReportsButton jimu-state-disabled esriCTEllipsis"\r\n\t\t\t\t\t\t\ttitle\x3d"${config.reportTabText}" role\x3d"button" aria-label\x3d"${config.reportTabText}"\x3e\r\n\t\t\t\t\t\t\t${config.reportTabText}\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c!--Clear AOI Button--\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTClearAOIButtonDiv"\x3e\r\n\t\t\t\t\t\t\x3cdiv data-dojo-attach-point\x3d"clearAOIButton"\r\n\t\t\t\t\t\t\tclass\x3d"jimu-btn jimu-float-trailing esriCTClearAOIButton jimu-state-disabled"\r\n\t\t\t\t\t\t\ttitle\x3d"${nls.clearAOIButtonLabel}" role\x3d"button" aria-label\x3d"${nls.clearAOIButtonLabel}"\x3e\r\n\t\t\t\t\t\t\t${nls.clearAOIButtonLabel}\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\x3c/div\x3e\r\n\t\t\t\x3c!--Report Tab--\x3e\r\n\t\t\t\x3cdiv class\x3d"esriCTReportTabParentContainer esriCTHidden" data-dojo-attach-point\x3d"reportTabParentContainer"\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTBackButtonDiv esriCTHidden" data-dojo-attach-point\x3d"backButtonDiv"\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTBackButtonIcon" data-dojo-attach-point\x3d"backButtonIconDiv" tabindex\x3d"0"\r\n\t\t\t\t\t\taria-label\x3d"${nls.common.back}" role\x3d"button"\x3e\x3c/div\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTBackButton" data-dojo-attach-point\x3d"backButton" title\x3d"${nls.common.back}"\x3e\r\n\t\t\t\t\t\t${nls.common.back}\x3c/div\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\x3cdiv class\x3d"esriCTReportsTabPanel" data-dojo-attach-point\x3d"reportsTabPanel"\x3e\r\n\t\t\t\t\t\x3c!--AOI Area--\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTUnitAreaContainer" data-dojo-attach-point\x3d"unitAreaContainer"\x3e\r\n\t\t\t\t\t\t\x3cdiv tabindex\x3d"0" role\x3d"presentation" class\x3d"esriCTHidden esriCTAOIContainers" data-dojo-attach-point\x3d"aoiFeetUnitAreaContainer"\x3e\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\x3cdiv tabindex\x3d"0" role\x3d"presentation" class\x3d"esriCTHidden esriCTAOIContainers"\r\n\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"aoiMilesUnitAreaContainer"\x3e\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\x3cdiv tabindex\x3d"0" role\x3d"presentation" class\x3d"esriCTHidden esriCTAOIContainers"\r\n\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"aoiMetersUnitAreaContainer"\x3e\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\x3cdiv tabindex\x3d"0" role\x3d"presentation" class\x3d"esriCTHidden esriCTAOIContainers"\r\n\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"aoiKilometersUnitAreaContainer"\x3e\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\x3cdiv tabindex\x3d"0" role\x3d"presentation" class\x3d"esriCTHidden esriCTAOIContainers"\r\n\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"aoiHectaresUnitAreaContainer"\x3e\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\x3cdiv tabindex\x3d"0" role\x3d"presentation" class\x3d"esriCTHidden esriCTAOIContainers"\r\n\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"aoiSquareMilesUnitAreaContainer"\x3e\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c!--AOI Area--\x3e\r\n\t\t\t\t\t\x3c!--Download \x26 Print Icons--\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTDownloadAndPrintTableContainer"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"downloadAndPrintTableContainer"\x3e\r\n\t\t\t\t\t\t\x3cdiv class\x3d"esriCTDownloadAndPrintChildContainer"\x3e\r\n\t\t\t\t\t\t\t\x3c!-- refresh button --\x3e\r\n\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTRefreshContainer" title\x3d"${nls.reportsTab.refreshBtnTooltip}"\r\n\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"refreshReportBtn" role\x3d"button"\r\n\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.refreshBtnTooltip}" tabindex\x3d"0"\x3e\r\n\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\x3c!-- download button --\x3e\r\n\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTDownloadContainer" title\x3d"${nls.reportsTab.downloadButtonTooltip}"\r\n\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"downloadReportBtn" role\x3d"button"\r\n\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.downloadButtonTooltip}" tabindex\x3d"0"\x3e\r\n\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\x3c!-- print main button --\x3e\r\n\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTPrintParentContainer" data-dojo-attach-point\x3d"printParentContainer"\x3e\r\n\t\t\t\t\t\t\t\t\x3c!-- print dropdown button --\x3e\r\n\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTPrintContainer" title\x3d"${nls.reportsTab.printButtonTooltip}"\r\n\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"printIconButton" data-dojo-type\x3d"dijit/form/DropDownButton"\r\n\t\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.printButtonTooltip}"\x3e\r\n\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTDropdownButtonLabel"\x3e${nls.reportsTab.printButtonTooltip}\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\x3c!-- tooltip dialog --\x3e\r\n\t\t\t\t\t\t\t\t\t\x3cdiv data-dojo-type\x3d"dijit/TooltipDialog" style\x3d"width: 325px;"\r\n\t\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"printDialog"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTPopupSettingsContainer"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTEllipsis esriCTPopupSettingLabel"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.printLayoutLabelText}\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3cselect data-dojo-type\x3d"jimu/dijit/formSelect"\r\n\t\t\t\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"printLayoutSelect"\r\n\t\t\t\t\t\t\t\t\t\t\t\tclass\x3d"esriCTPrintLayoutDropdown"\r\n\t\t\t\t\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.printLayoutLabelText}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c/select\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTPrintDialogHint" role\x3d"presentation"\r\n\t\t\t\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.printDialogHint}" tabindex\x3d"0"\x3e${nls.reportsTab.printDialogHint}\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTPopupSettingsBtnContainer"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3cbutton type\x3d"submit"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tclass\x3d"esriCTEllipsis jimu-btn esriCTDownloadSettingsBtn"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.printBtnText}"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"printActionButton"\x3e${nls.reportsTab.printBtnText}\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3c/button\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\x3c!-- analysis unit parent container --\x3e\r\n\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTAnalysisUnitParentContainer" data-dojo-attach-point\x3d"analysisUnitParentContainer"\x3e\r\n\t\t\t\t\t\t\t\t\x3c!-- analysis unit button --\x3e\r\n\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTAnalysisUnitSettingContainer" title\x3d"${nls.reportsTab.analysisUnitButtonTooltip}"\r\n\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"analysisUnitButton" data-dojo-type\x3d"dijit/form/DropDownButton"\r\n\t\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.analysisUnitButtonTooltip}"\x3e\r\n\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTDropdownButtonLabel"\x3e${nls.reportsTab.analysisUnitButtonTooltip}\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\x3c!-- tooltip dialog --\x3e\r\n\t\t\t\t\t\t\t\t\t\x3cdiv data-dojo-type\x3d"dijit/TooltipDialog" style\x3d"width: 350px;"\r\n\t\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"analysisUnitDialog"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTUnitSettingsContainer"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c!-- Area unit container --\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTAreaUnitMainPopupContainer"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTEllipsis esriCTPopupSettingLabel"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.analysisAreaUnitLabelText}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.analysisAreaUnitLabelText}\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTAreaDropdownContainer"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\x3cselect data-dojo-type\x3d"jimu/dijit/formSelect"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"analysisAreaUnitSelect"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tclass\x3d"esriCTAnalysisUnitDropdown"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.analysisAreaUnitLabelText}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption selected\x3d"selected" value\x3d"SquareFeet"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.areaSquareFeetUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.areaSquareFeetUnit}\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption value\x3d"Acres" title\x3d"${nls.reportsTab.areaAcresUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.areaAcresUnit}\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption value\x3d"SquareMeters"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.areaSquareMetersUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.areaSquareMetersUnit}\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption value\x3d"SquareKilometers"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.areaSquareKilometersUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.areaSquareKilometersUnit}\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption value\x3d"Hectares"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.areaHectaresUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.areaHectaresUnit}\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption value \x3d "SquareMiles"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.areaSquareMilesUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.areaSquareMilesUnit}\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\x3c/select\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c!-- Area unit container ends --\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c!-- Length unit container --\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTLengthUnitMainPopupContainer"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTEllipsis esriCTPopupSettingLabel"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.analysisLengthUnitLabelText}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.analysisLengthUnitLabelText}\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTLengthDropdownContainer"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\x3cselect data-dojo-type\x3d"jimu/dijit/formSelect"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"analysisLengthUnitSelect"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tclass\x3d"esriCTAnalysisUnitDropdown"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.analysisLengthUnitLabelText}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption selected\x3d"selected" value\x3d"Feet"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.lengthFeetUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.lengthFeetUnit}\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption value\x3d"Miles" title\x3d"${nls.reportsTab.lengthMilesUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.lengthMilesUnit}\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption value\x3d"Meters"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.lengthMetersUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.lengthMetersUnit}\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\x3coption value\x3d"Kilometers"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.lengthKilometersUnit}"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t${nls.reportsTab.lengthKilometersUnit}\x3c/option\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\x3c/select\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c!-- Length unit container ends --\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3cdiv class\x3d"esriCTPopupSettingsBtnContainer"\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3cbutton type\x3d"submit"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tclass\x3d"esriCTEllipsis jimu-btn esriCTDownloadSettingsBtn"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\ttitle\x3d"${nls.reportsTab.analysisCloseBtnText}"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\taria-label\x3d"${nls.reportsTab.analysisCloseBtnText}" tabindex\x3d"0"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\trole\x3d"button"\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tdata-dojo-attach-point\x3d"analysisUnitActionButton"\x3e${nls.reportsTab.analysisCloseBtnText}\r\n\t\t\t\t\t\t\t\t\t\t\t\t\x3c/button\x3e\r\n\t\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c!--Download \x26 Print Icons--\x3e\r\n\t\t\t\t\t\x3c!--Impact summary report--\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTImpactSummaryReportParentContainer"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"impactSummaryReportContainer"\x3e\x3c/div\x3e\r\n\t\t\t\t\t\x3c!--Impact summary report--\x3e\r\n\t\t\t\t\t\x3c!--Upload shapefile to include in analysis--\x3e\r\n\t\t\t\t\t\x3cdiv class\x3d"esriCTUploadShapefileAnalysisTableContainer esriCTHidden"\r\n\t\t\t\t\t\tdata-dojo-attach-point\x3d"uploadShapefileAnalysisTableContainer"\x3e\r\n\t\t\t\t\t\x3c/div\x3e\r\n\t\t\t\t\t\x3c!--Upload shapefile to include in analysis--\x3e\r\n\t\t\t\t\x3c/div\x3e\r\n\t\t\t\x3c/div\x3e\r\n\t\t\x3c/div\x3e\r\n\t\x3c/div\x3e\r\n\t\x3cdiv class\x3d"esriCTErrorMessageMainContainer esriCTHidden" data-dojo-attach-point\x3d"errorMessageMainContainer"\x3e\r\n\t\t${nls.invalidConfiguration}\r\n\t\x3c/div\x3e\r\n\t\x3cdiv data-dojo-attach-point\x3d"iframeContainer" class\x3d"esriCTHidden"\x3e\r\n\t\x3c/div\x3e\r\n\x3c/div\x3e',
"url:widgets/Screening/css/style.css":".esriCTOverridePanelStyle {padding: 0px !important;}.jimu-widget-screening .esriCTTabContainerParentElement {height: 100%;}.jimu-widget-screening .esriCTAOITabParentContainer {height: -moz-calc(100% - 30px); height: -webkit-calc(100% - 30px); height: calc(100% - 30px); padding-left: 10px; padding-right: 10px; padding-bottom: 10px; position: relative; overflow: auto; -webkit-overflow-scrolling: touch;}.jimu-widget-screening .esriCTReportTabParentContainer {position: relative;}.jimu-widget-screening .esriCTTabLabelMainContainer {width: 100%; height: 29px; line-height: 29px; border-bottom: 1px solid #d9dde0; padding: 0 10px;}.jimu-widget-screening .esriCTAOILabelContainer,.jimu-widget-screening .esriCTReportLabelContainer {float: left; width: calc(99% - 46px);}.esriRtl .jimu-widget-screening .esriCTAOILabelContainer,.esriRtl .jimu-widget-screening .esriCTReportLabelContainer {float: right;}.jimu-widget-screening .esriCTWidgetAndBufferSeparator {border-top: 1px solid #d9dde0; height: 1px; margin: 5px 0 10px 0; clear: both;}.jimu-widget-screening .esriCTAOIWidgetParentContainer {margin-top: 10px;}.jimu-widget-screening .esriCTTabsOverflowText {white-space: nowrap; overflow: hidden; text-overflow: ellipsis !important;}.jimu-widget-screening .esriCTZoomToIcon {background-image: url('../images/zoom.png');}.jimu-widget-screening .esriCTZoomToDisableIcon {background-image: url('../images/zoom-disable.png'); cursor: not-allowed;}.dart-panel .jimu-widget-screening .esriCTZoomToIcon {background-image: url('../images/zoom-dart-theme.png');}.jimu-widget-screening .esriCTTraverseToolIcons {height: 28px; width: 28px; background-size: 24px 24px; float: right; background-repeat: no-repeat; margin: 0px 0px 0px 20px; background-position: center;}.jimu-widget-screening .esriCTAOIContainers {padding: 8px;}.esriRtl .jimu-widget-screening .esriCTTraverseToolIcons {float: left; margin: 0px 20px 0px 0px;}.jimu-widget-screening .esriCTReportsTabPanel {text-align: center;}.jimu-widget-screening .esriCTInvisibleLayer {color: #bdc1c8;}.jimu-widget-screening .esriCTDownloadAndPrintTableContainer {width: 100%; overflow: hidden; clear: both; padding-top: 2px; padding-bottom: 2px;}.jimu-widget-screening .esriCTDownloadAndPrintChildContainer {float: right;}.esriRtl .jimu-widget-screening .esriCTDownloadAndPrintChildContainer {float: left;}.jimu-widget-screening .esriCTRefreshContainer {background-image: url(../images/refresh.png); background-size: 20px 20px; width: 20px; height: 20px; cursor: pointer; background-repeat: no-repeat; margin-right: 15px; float: left;}.esriRtl .jimu-widget-screening .esriCTRefreshContainer {margin-right: 0px; margin-left: 10px; float: right}.jimu-widget-screening .esriCTDownloadContainer {background-image: url(../images/download.png); background-size: 20px 20px; width: 20px; height: 20px; cursor: pointer; background-repeat: no-repeat; margin-right: 15px; float: left;}.esriRtl .jimu-widget-screening .esriCTDownloadContainer {margin-right: 0px; margin-left: 10px; float: right}.jimu-widget-screening .esriCTPrintParentContainer {width: 25px; height: 25px; cursor: pointer; margin-right: 10px; float: left;}.esriRtl .jimu-widget-screening .esriCTPrintParentContainer {margin-right: 0px; margin-left: 10px; float: right}.jimu-widget-screening .esriCTPrintContainer {background-image: url('../images/print.png'); background-size: 20px 20px; width: 20px; height: 20px; cursor: pointer; background-repeat: no-repeat;}.jimu-widget-screening .esriCTAnalysisUnitParentContainer {width: 25px; height: 25px; cursor: pointer; margin-right: 10px; float: left;}.esriRtl .jimu-widget-screening .esriCTAnalysisUnitParentContainer {margin-right: 0px; margin-left: 10px; float: right}.jimu-widget-screening .esriCTAnalysisUnitSettingContainer {background: url(../images/analysis-unit-setting.png); background-size: 20px 20px; width: 20px; height: 20px; cursor: pointer; background-repeat: no-repeat;}.jimu-widget-screening .esriCTDownloadBtnDisabled {background-image: url('../images/download-disable.png'); cursor: not-allowed;}.dart-panel .jimu-widget-screening .esriCTDownloadContainer {background-image: url('../images/download-disable.png');}.dart-panel .jimu-widget-screening .esriCTDownloadBtnDisabled {background-image: url('../images/download.png');}.dart-panel .jimu-widget-screening .esriCTPrintContainer {background-image: url('../images/print-disable.png');}.jimu-widget-screening .esriCTPrintContainer .dijitButtonNode {height: 20px !important; width: 30px !important; min-width: 20px !important; border: none !important; background: none !important; box-shadow: none !important;}.jimu-widget-screening .esriCTPrintContainer .dijitDownArrowButton {height: 22px; margin: -3px 0 0 -6px;}.jimu-widget-screening .esriCTPrintContainer .dijitArrowButtonInner {opacity: 0;}.esriRtl .jimu-widget-screening .esriCTPrintContainer {margin-right: 0px;}.jimu-widget-screening .esriCTPrintBtnDisabled {background-image: url('../images/print-disable.png'); cursor: not-allowed;}.dart-panel .jimu-widget-screening .esriCTPrintBtnDisabled {background-image: url('../images/print.png');}.dart-panel .jimu-widget-screening .esriCTRefreshContainer {background-image: url('../images/refresh-grey.png');}.jimu-widget-screening .esriCTPrintBtnDisabled .dijitButtonNode,.jimu-widget-screening .esriCTPrintBtnDisabled .dijitButtonNode span {cursor: not-allowed;}.dart-panel .jimu-widget-screening .esriCTAnalysisUnitSettingContainer {background: url(../images/analysis-unit-setting-disable.png) no-repeat; background-size: 20px 20px;}.jimu-widget-screening .esriCTAnalysisUnitSettingContainer .dijitButtonNode {height: 20px !important; width: 30px !important; min-width: 20px !important; border: none !important; background: none !important; box-shadow: none !important;}.jimu-widget-screening .esriCTAnalysisUnitSettingContainer .dijitDownArrowButton {height: 22px; margin: -3px 0 0 -6px;}@-moz-document url-prefix() {.jimu-widget-screening .esriCTPrintContainer .dijitDownArrowButton {margin: -3px 0 0 -15px;} .jimu-widget-screening .esriCTAnalysisUnitSettingContainer .dijitDownArrowButton {margin: -3px 0 0 -15px;}}.jimu-widget-screening .esriCTAnalysisUnitSettingContainer .dijitArrowButtonInner {opacity: 0;}.jimu-widget-screening .esriCTUploadShapefileAnalysisTableContainer {display: table; width: 100%; height: 100%; padding: 10px 5px;}.jimu-widget-screening .esriCTUploadShapefileAnalysisTableRowContainer {display: table-row;}.jimu-widget-screening .esriCTUploadShapefileForAnalysisText {display: table-cell; padding-left: 5px; padding-right: 5px; vertical-align: middle; text-align: left;}.jimu-widget-screening .esriCTUploadShapefileForAnalysisButtonContainer {display: table-cell; vertical-align: middle;}.jimu-widget-screening .esriCTUploadShapefileForAnalysisButton {margin-right: 10px;}.jimu-widget-screening .esriCTImpactSummaryReportParentContainer {margin-top: 10px; overflow: auto; -webkit-overflow-scrolling: touch; border-top: 1px solid #d9dde0; padding-top: 2px;}.jimu-widget-screening .esriCTLayerFieldCheckbox {width: 167px; margin-bottom: 20px; color: #596679; font-size: 14px; margin-left: 30px;}.jimu-widget-screening .esriCTLayerFieldWithoutMargin {margin-left: 0px !important;}.esriRtl .jimu-widget-screening .esriCTLayerFieldCheckbox {margin-left: 20px; margin-right: 0px;}.jimu-widget-screening .esriCTSelectFieldReportLabel {margin: 2px 5px 20px 5px;}.jimu-widget-screening .esriCTSelectAllReportLabel {margin-bottom: 20px; padding-left: 2px;}.jimu-widget-screening .esriCTSelectFieldParentContainer {overflow: auto; -webkit-overflow-scrolling: touch; padding-top: 2px; padding-left: 2px;}.jimu-widget-screening .esriCTNoFieldSelectedContainer {padding: 5px 10px 5px 5px; text-align: center; line-height: 20px;}.jimu-widget-screening .esriCTLayerFieldCheckbox .label {width: 140px;}.LaunchpadTheme .jimu-widget-screening .esriCTLayerFieldCheckbox .label {width: 129px;}.jimu-widget-screening .esriCTInfoDataSeparator {border-bottom: 1px solid #d9dde0; width: 100%;}.jimu-widget-screening .esriCTInfoDataSeparator:last-of-type {display: none;}.jimu-widget-screening .esriCTInfoDataMeasurement {text-align: right;}.jimu-widget-screening .esriCTAttrTable {border-collapse: collapse; width: 100%; table-layout: fixed; margin-top: 5px;}.jimu-widget-screening .esriCTAttrTableHighlighted td {background-color: #E2F0FB;}.dart-panel .jimu-widget-screening .esriCTAttrTableHighlighted td {background-color: #000000;}.jimu-widget-screening .esriCTAttrTable td {padding: 2px; word-wrap: break-word; padding-bottom: 5px;}.jimu-widget-screening .esriCTAttrTable td:first-child {width: 33%;}.jimu-widget-screening .esriCTAttrTable td.esriCTAttrName {color: #888888; padding-right: 5px;}.jimu-widget-screening .esriCTReportsTabInfoData {padding: 0px !important;}.esriRtl .jimu-widget-screening .esriCTInfoDataMeasurement {text-align: left;}.esriRtl .jimu-widget-screening .esriCTImpactSummaryLayerTitle {float: right;}.esriRtl .jimu-widget-screening .esriCTImpactSummaryLayerFieldIcon {float: left;}.esriRtl .jimu-widget-screening .esriCTImpactSummaryLayerFeatureCount {float: left; padding-right: 0px;}.esriRtl .jimu-widget-screening .esriCTDownloadSettingLabel {margin-left: 15px; margin-right: 0px; float: right;}.jimu-popup .title-label {width: calc(100% - 30px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;}.esriRtl .jimu-widget-screening .esriCTLayerPanelIcon {float: right; margin: 7px 0 7px 5px;}.esriRtl .jimu-widget-screening .esriCTAreaSettingContainer {float: left; margin-left: 5px; margin-right: 0px;}.esriRtl .jimu-widget-screening .esriCTAnalysisUnitSettingContainer {float: left;}.jimu-widget-screening .esriCTAOIButtonParentContainer {display: table; table-layout: fixed; width: 100%; margin-top: 10px; border: 1px solid #d9dde0; clear: both;}.jimu-widget-screening .esriCTPlacenameButton,.jimu-widget-screening .esriCTDrawToolButton,.jimu-widget-screening .esriCTShapefileButton,.jimu-widget-screening .esriCTCoordinateButton {display: table-cell; height: 30px; line-height: 30px; text-align: center; max-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;}.jimu-widget-screening .esriCTDrawToolButton,.jimu-widget-screening .esriCTShapefileButton,.jimu-widget-screening .esriCTCoordinateButton {border-left: 1px solid #d9dde0;}.esriRtl .jimu-widget-screening .esriCTDrawToolButton,.esriRtl .jimu-widget-screening .esriCTShapefileButton,.esriRtl .jimu-widget-screening .esriCTCoordinateButton {border-left: none; border-right: 1px solid #d9dde0;}.jimu-widget-screening .esriCTPlacenameButton:hover,.jimu-widget-screening .esriCTDrawToolButton:hover,.jimu-widget-screening .esriCTShapefileButton:hover,.jimu-widget-screening .esriCTCoordinateButton:hover {background-color: #d9dde0;}.dart-panel .jimu-widget-screening .esriCTPlacenameButton:hover,.dart-panel .jimu-widget-screening .esriCTDrawToolButton:hover,.dart-panel .jimu-widget-screening .esriCTShapefileButton:hover,.dart-panel .jimu-widget-screening .esriCTCoordinateButton:hover {background-color: #262626;}.dart-panel .jimu-widget-screening .esriCTBackButtonIcon {background-image: url('../images/left-arrow-dart-theme.png'); background-color: #4c4c4c;}.esriRtl .dart-panel .jimu-widget-screening .esriCTBackButtonIcon {background-image: url('../images/right-arrow-dart-theme.png');}.jimu-widget-screening .esriCTSearchOuterContainer {padding: 0px 0px 15px 0px; clear: both;}.jimu-widget-screening .esriCTSearchDiv {float: left; clear: both; margin-right: 10px;}.jimu-widget-screening .esriCTSearchHeader {margin: 2px 2px 10px 2px;}.jimu-widget-screening .esriCTSearchDiv .arcgisSearch {float: left; width: 100% !important;}.jimu-widget-screening .esriCTSearchContainer {width: 100%; height: 35px;}.jimu-widget-screening .arcgisSearch .searchGroup .searchInput {width: 170px; padding: 6px 24px 6px 12px !important;}.esriRtl .jimu-widget-screening .arcgisSearch .searchGroup .searchInput {padding: 6px 12px 6px 24px !important;}.jimu-widget-screening .arcgisSearch .searchBtn {padding: 6px;}.jimu-widget-screening .arcgisSearch .searchBtn:focus {outline: 2px solid #24B5CC !important;}.jimu-widget-screening .jimu-widget-search .arcgisSearch .searchGroup .searchInputGroup .searchInput {width: auto;}.jimu-widget-screening .esriCTSearchContainer .searchClear {top: 2px !important;}.jimu-widget-screening .esriCTSelectToolParentDiv {margin-top: 8px; width: 40px;}.jimu-widget-screening .esriCTLayerItems {margin-top: 10px;}.jimu-widget-screening .esriCTLayerPanelOfSelectIcon {display: table-cell; height: 15px; width: 15px; margin: 5px 5px 0 0; float: left; background-position: center center; background-repeat: no-repeat; background-size: 15px 15px; cursor: pointer;}.jimu-widget-screening .esriCTSelectableLayerTitle {height: 25px; padding-top: 7px; cursor: pointer; display: inline-block; margin: 0 auto; width: calc(100% - 50px);}.jimu-widget-screening .esriCTLayerPanelCollapseIcon {background-image: url('../images/panel-collapse.png');}.jimu-widget-screening .esriCTLayerPanelExpandIcon {background-image: url('../images/panel-expand.png');}.jimu-widget-screening .esriCTExpandCollapseParentContainer {width: 100%; text-align: left;}.esriRtl .jimu-widget-screening .esriCTExpandCollapseParentContainer {text-align: right;}.jimu-widget-screening .esriCTSingleLayerSelectionWarning {float: right;}.esriRtl .jimu-widget-screening .esriCTSingleLayerSelectionWarning {float: left;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select.selected {background-color: #DDDDDD; border: 2px solid #000000;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select:active {background-color: #FFF; border: 1px solid #ccc;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select {background-color: #FFF; border: 1px solid #ccc; cursor: default;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select .select-text {display: none;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser {width: 100%;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .draw-item-btn {width: 40px;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select {right: 0;}.esriRtl .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select {left: 0;}.dart-panel .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select {background-color: rgba(255, 255, 255, 0.5);}.dart-panel .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select.selected {background-color: #8a8a8a; border: 2px solid #000000 !important;}.dart-panel .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select:hover {background-color: #8a8a8a !important;}.jimu-widget-screening .esriCTchooseSelection {width: 50%;}.esriRtl .jimu-widget-screening .esriCTLayerPanelOfSelectIcon {float: right; margin: 5px 0px 0 5px;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .draw-item-btn {top: 5px;}.LaunchpadTheme .jimu-widget-screening .esriCTSelectToolParentDiv {margin: 6px 0px 0px 5px;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .draw-item-btn {width: 30px; height: 30px; line-height: 31px;}.LaunchpadTheme .jimu-multiple-layers-featureset-chooser .current-draw-item .btn-select.selected {background-color: #3b8fc4; border-color: #3b8fc4;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select:hover {background-color: #e6e6e6; border-color: #ddd;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select.selected:hover {background-color: #3b8fc4; border-color: #3b8fc4;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .current-draw-item.EXTENT .btn-select .select-icon {background: url(\"../images/select-tool-black.png\") center center no-repeat; left: -2px;}.dart-panel .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .current-draw-item.EXTENT .btn-select .select-icon {background: url(\"../images/select-tool-white.png\") center center no-repeat; left: -2px;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .current-draw-item.EXTENT .btn-select .select-icon {background-image: url('../images/select-tool-gray.png'); top: 4px; background-size: 20px;}.LaunchpadTheme .jimu-multiple-layers-featureset-chooser .current-draw-item .btn-select.selected .select-icon {background-image: url('../images/select-tool-white.png') !important;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select .feature-action {color: #000000; cursor: default;}.dart-panel .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select .feature-action {color: #ffffff !important;}.dart-panel .jimu-multiple-layers-featureset-chooser .btn-select:hover {border: 1px solid #ccc !important;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select .feature-action {color: #6d6e70; cursor: default; line-height: 29px;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .btn-select.selected .feature-action {color: #ffffff;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .current-draw-item .btn-select.selected {line-height: 30px; border-radius: 2px;}.LaunchpadTheme .jimu-widget-screening .jimu-multiple-layers-featureset-chooser .draw-item-btn .current-draw-item {height: 29px;}.jimu-widget-screening .esriCTShapefileWidgetContainer {clear: both; overflow: auto; -webkit-overflow-scrolling: touch; padding-top: 2px; padding-right: 2px; padding-left: 2px;}.jimu-widget-screening .esriCTUploadShapefileText {width: 70%; float: left; text-align: center; padding-right: 10px; height: 35px; display: flex; justify-content: center; align-items: center; display: -webkit-flex; -webkit-justify-content: center; -webkit-align-items: center; overflow: hidden;}.jimu-widget-screening .esriCTUploadShapefileButtonDiv {width: 30%; float: left; margin-bottom: 10px;}.jimu-widget-screening .esriCTUploadShapefileButton {margin-right: 0;}.jimu-widget-screening input[type\x3dfile] {width: 23%; float: right; position: absolute; opacity: 0; margin-right: 10px; cursor: pointer; overflow: hidden;}.jimu-widget-screening input[type\x3dfile]::-webkit-file-upload-button {cursor: pointer;}.jimu-widget-screening .esriCTUpdateStatus {clear: both; float: right;}.esriRtl .jimu-widget-screening .esriCTUploadShapefileText {float: right; text-align: right; padding-right: 0px;}.esriRtl .jimu-widget-screening .esriCTUploadShapefileButtonDiv {float: right;}.esriRtl .jimu-widget-screening input[type\x3dfile] {width: 24%; right: 215px;}.esriRtl .jimu-widget-screening .esriCTUploadShapefileButton {margin: 0;}.jimu-widget-screening .esriCTCoordinateWidgetContainer {clear: both; overflow: auto; -webkit-overflow-scrolling: touch;}.jimu-widget-screening .esriCTSelectStartPointFromSearchDiv {float: left; width: 100%;}.jimu-widget-screening .esriCTSelectStartPointFromMapClickText {display: table-cell; height: 100%; vertical-align: middle; padding-right: 10px;}.jimu-widget-screening .esriCTOrTextDiv {float: none; margin: 0 auto; text-align: center; margin-bottom: 10px; margin-top: 10px;}.jimu-widget-screening .esriCTLocateImageNode {background: url(../images/locate.png) center no-repeat; background-size: 20px; height: 34px; width: 34px; cursor: pointer; display: table-cell; vertical-align: middle; border: 1px solid #57585A; border-radius: 3px;}.dart-panel .jimu-widget-screening .esriCTLocateImageNode {background: url(../images/locate-selected.png) center no-repeat; background-size: 20px;}.jimu-widget-screening .esriCTHighlightLocateIcon {border: 1px solid #d0d0d0;}.jimu-widget-screening .esriCTLatLongInputLabelParentContainer {display: table; width: 100%; padding-top: 10px; padding-bottom: 2px; table-layout: fixed;}.jimu-widget-screening .esriCTLatLongInputLabelChildContainer {display: table-row;}.jimu-widget-screening .esriCTLatitudeLabel {margin-right: 10px;}.jimu-widget-screening .esriCTLatitudeLabel,.jimu-widget-screening .esriCTLongitudeLabel {float: left;}.jimu-widget-screening .esriCTLatitudeLabel,.jimu-widget-screening .esriCTLongitudeLabel,.jimu-widget-screening .esriCTLatTextBox,.jimu-widget-screening .esriCTLongTextBox {display: table-cell; width: 40%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;}.jimu-widget-screening .esriCTLatTextBox {height: 30px; float: left; margin-right: 10px; margin-left: 2px;}.jimu-widget-screening .esriCTLongTextBox {height: 30px; float: left;}.jimu-widget-screening .esriCTBearingDistanceParentDiv {margin-top: 10px; width: 100%;}.jimu-widget-screening .esriCTBearingInputTextBox,.jimu-widget-screening .esriCTDistanceInputTextBox {width: 38%; float: left; height: 30px; padding: 5px; font-size: 12px;}.jimu-widget-screening .dijitNumberTextBox input.dijitInputInner {text-align: center;}.jimu-widget-screening .esriCTAddNewBearingDistanceIcon {background: url(\"../images/add.png\") center no-repeat; background-size: 20px 20px; height: 30px; width: 30px; margin-left: 5px; float: left; cursor: pointer;}.jimu-widget-screening .esriCTLocateIconSelected {background: url(../images/locate-selected.png) center no-repeat; background-color: #57585A; background-size: 20px;}.dart-panel .jimu-widget-screening .esriCTLocateIconSelected {border: 1px solid #fff;}.jimu-widget-screening .esriCTLocateForLatLongText {cursor: pointer; float: left; line-height: 30px; width: 16%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: underline; color: #0000ff; text-align: center;}.jimu-widget-screening .esriCTBearingAndDistanceLabelDiv {padding-top: 10px;}.jimu-widget-screening .esriCTDefaultBearingAndDistanceInputNode {padding-top: 25px;}.jimu-widget-screening .esriCTEnterBearingAndDistanceLabelDiv {float: left; max-width: 88%; margin-right: 5px; line-height: 20px;}.jimu-widget-screening .esriCTPlanSettingsIcon {background: url(../images/settings.png); height: 20px; width: 20px; background-size: 20px 20px; float: right; background-repeat: no-repeat; cursor: pointer; margin-right: 5px;}.dart-panel .jimu-widget-screening .esriCTPlanSettingsIcon {background: url(../images/setting-disable.png); background-size: 20px 20px;}.esriRtl .jimu-widget-screening .esriCTSearchDiv {float: right; margin: 0 0 0 10px;}.esriRtl .jimu-widget-screening .esriCTSelectStartPointFromMapClickText {padding-left: 10px; padding-right: 0px;}.esriRtl .jimu-widget-screening .esriCTLatitudeLabel {float: right; margin-right: 0px;}.esriRtl .jimu-widget-screening .esriCTLatTextBox {float: right; margin-left: 8px; margin-right: 0px;}.esriRtl .jimu-widget-screening .esriCTLongitudeLabel {float: right; margin-right: 8px;}.esriRtl .jimu-widget-screening .esriCTLongTextBox {float: right;}.esriRtl .jimu-widget-screening .esriCTEnterBearingAndDistanceLabelDiv {float: right;}.esriRtl .jimu-widget-screening .esriCTGridLabels {float: right; text-align: right;}.esriRtl .jimu-widget-screening .esriCTRow .dijitTextBox {float: right;}.esriRtl .jimu-widget-screening .esriCTPlanSettingsIcon {float: left;}.esriRtl .jimu-widget-screening .esriCTDeleteRow,.esriRtl .jimu-widget-screening .esriCTAddRow {float: left; margin: 0 0 0 2px;}.jimu-widget-screening .esriCTAOIBufferChangeParentContainer {clear: both;}.jimu-widget-screening input,.jimu-widget-screening select,.jimu-widget-screening option,.jimu-widget-screening .esriCTAOIBufferContainer {color: #86909c;}.jimu-widget-screening .esriCTBufferDistanceLabelTextBoxContainer {clear: both; width: 100%; height: 30px;}.jimu-widget-screening .esriCTBufferDistanceTitleContainer {width: 100%; text-overflow: ellipsis; overflow: hidden; white-space: nowrap;}.jimu-widget-screening .esriCTBufferDistanceLabel {width: 100%; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; margin-top: 10px; margin-bottom: 10px;}.jimu-widget-screening .esriCTDistanceTextBox {width: 100%; float: left; height: 30px !important; text-align: center; border: 1px solid #d9dde0 !important; margin-right: 10px;}.jimu-widget-screening .esriCTDistanceUnit {width: 100%; float: left; height: 30px !important; border-color: #d9dde0 !important; table-layout: fixed !important; box-sizing: border-box;}.jimu-widget-screening .dijitSelectFocused {border-color: #51b1fe; box-shadow: 0px 0px 5px #51b1fe;}.jimu-widget-screening .esriCTSelectedTab,.jimu-widget-screening .esriCTSelectedTab:hover {background-color: #8994a1; border: 1px solid #8994a1; color: #fff;}.jimu-widget-screening .esriCTBufferDistanceUnitSelectContainer {width: calc(70% - 5px); display: inline-block;}.jimu-widget-screening .esriCTBufferDistanceTextBoxContainer {height: 30px; width: 30%; display: inline-block; padding-right: 5px;}.esriRtl .jimu-widget-screening .esriCTDistanceTextBox {float: right; margin-left: 5px; margin-right: 0;}.esriRtl .jimu-widget-screening .esriCTDistanceUnit {float: left;}.esriRtl .jimu-widget-screening .esriCTBufferDistanceTextBoxContainer {padding-left: 5px;}.jimu-widget-screening .esriCTBufferDistanceLabelTextBoxContainer .dijitSelect .dijitButtonContents {border-style: none; background-color: #fafafc; width: 100%;}.jimu-widget-screening .esriCTBufferDistanceLabelTextBoxContainer .dijitSelect .dijitArrowButton {background-color: #fafafc; background-image: none; border-color: #fafafc; padding: 0 !important;}.jimu-widget-screening .esriCTBufferDistanceLabelTextBoxContainer .dijitSelect .dijitInputField {margin-right: 8px; width: 100%; overflow: hidden;}.claro .jimu-widget-screening .dijitTextBox .dijitInputField .dijitPlaceHolder {line-height: 30px !important;}.esriRtl .jimu-widget-screening .esriCTBufferDistanceLabelTextBoxContainer .dijitSelect .dijitInputField {margin-right: 0px;}.jimu-widget-screening .esriCTBufferDistanceLabelTextBoxContainer .dijitTextBox .dijitInputInner {text-align: center;}.claro .dart-panel .jimu-widget-screening .dijitSelect .dijitReset.dijitButtonNode.dijitArrowButton.dijitDownArrowButton.dijitArrowButtonContainer {background-image: url(../../../themes/DartTheme/dijit-css/icons/Icon_Dropdown_16.png);}.dart-panel .jimu-widget-screening .esriCTBufferDistanceLabelTextBoxContainer .dijitSelect .dijitButtonContents,.dart-panel .jimu-widget-screening .esriCTBufferDistanceLabelTextBoxContainer .dijitSelect .dijitArrowButton {background-color: transparent;}.dart-panel .jimu-widget-screening .dijitArrowButtonInner {width: 0px !important;}.dart-panel .arcgisSearch .searchMenu {background-color: #4c4c4c;}.dart-panel .arcgisSearch .searchMenu li:hover,.dart-panel .arcgisSearch .searchMenu li:focus {background-color: #222;}.jimu-widget-screening .esriCTErrorMessageMainContainer {padding: 10px;}.jimu-widget-screening .esriCTAOIButtonDivContainer {width: 100%; overflow: hidden; text-align: right; padding-top: 2px;}.esriRtl .jimu-widget-screening .esriCTAOIButtonDivContainer {text-align: left;}.jimu-widget-screening .esriCTShowReportsButtonDiv {width: 50%; display: inline-block; position: relative; max-width: 140px; padding-left: 10px;}.jimu-widget-screening .esriCTClearAOIButtonDiv {width: 50%; display: inline-block; position: relative; max-width: 140px; padding-left: 10px;}.jimu-widget-screening .esriCTShowReportsButton {width: 100%}.jimu-widget-screening .esriCTClearAOIButton {width: 100%}.jimu-widget-screening .esriCTBackButtonDiv {max-width: 28%; float: left; cursor: pointer;}.esriRtl .jimu-widget-screening .esriCTBackButtonDiv {float: right;}.jimu-widget-screening .esriCTBackButtonIcon {background-image: url('../images/left-arrow.png'); width: 10px; height: 20px; margin: 6px; background-repeat: no-repeat; background-color: #3e3e3e; background-position: center center; float: left;}.esriRtl .jimu-widget-screening .esriCTBackButtonIcon {background-image: url('../images/right-arrow.png'); float: right;}.jimu-widget-screening .esriCTBackButton {float: left; padding: 8px 2px 0 2px;}.esriRtl .jimu-widget-screening .esriCTBackButton {float: right;}.jimu-widget-screening .esriCTNewTraverseContainer {width: 100%; display: inline-block;}.jimu-widget-screening .esriCTNewTraverseLabelDiv {display: inline-block; width: 100%;}.jimu-widget-screening .esriCTGridEmptyLabel {width: 50px; float: left; text-align: left;}.jimu-widget-screening .esriCTGridLabels {width: 48%; float: left; text-align: left;}.jimu-widget-screening .esriCTTraverseGrid {width: 100%; display: table; border-collapse: collapse;}.jimu-widget-screening .esriCTEntryNodeContent {width: 100%; display: table; border-collapse: collapse;}.jimu-widget-screening .dojoDndItemAfter .esriCTSymbolContainer,.jimu-widget-screening .dojoDndItemBefore .esriCTSymbolContainer {background: #E4E4ED !important;}.jimu-widget-screening .esriCTSymbolContainer {border: 1px solid #dedede; width: 50px; height: 30px; padding: 0px 5px; vertical-align: middle; display: table-cell;}.jimu-widget-screening .esriCTDeleteRow,.jimu-widget-screening .esriCTAddRow {color: #CCC; display: table-cell; vertical-align: middle; font-size: 18px; width: 15px; float: right; margin: 0 2px 0 0;}.jimu-widget-screening .esriCTDeleteIcon,.jimu-widget-screening .esriCTAddIcon {cursor: pointer; height: 30px; width: 15px;}.jimu-widget-screening .esriCTAddDisabledIcon {height: 30px; width: 15px;}.jimu-widget-screening .esriCTDeleteIcon {background: url('../images/delete.png') no-repeat center center;}.jimu-widget-screening .esriCTAddIcon {background: url('../images/add.png') no-repeat center center;}.jimu-widget-screening .esriCTAddDisabledIcon {background: url('../images/add-disable.png') no-repeat center center;}.jimu-widget-screening .esriCTTraverseTool {float: left; padding: 5px 5px 5px 0; width: calc(100% - 20px);}.jimu-widget-screening .esriCTTraverseToolContainer {float: right;}.jimu-widget-screening .esriCTCollapse {background-image: url('../images/collapse.png');}.jimu-widget-screening .esriCTExpand {background-image: url('../images/expand.png');}.jimu-widget-screening .esriCTRow .dijitTextBox {width: 46%; float: left;}.jimu-widget-screening .esriCTRow .dijitTextBoxHover {border-color: #d9dde0;}.jimu-widget-screening .esriCTRow .dijitTextBoxFocused {border-color: #d9dde0 !important; box-shadow: none; outline: none;}.jimu-widget-screening .dojoDndItem,.jimu-widget-screening .dojoDndItemAnchor,.jimu-widget-screening .dojoDndItemSelected,.jimu-widget-screening .dojoDndContainerOver,.jimu-widget-screening .dojoDndItemOver {background: none; border: none; padding: 0; cursor: move;}.jimu-widget-screening .esriCTMapPointParentContainer {display: table;}.jimu-widget-screening .esriCTMapPointChildContainer {display: table-row;}.jimu-widget-screening::-ms-clear {display: none;}.jimu-widget-screening .esriCTPlanSettingLabel {padding: 10px 10px 10px 0; width: 200px;}.jimu-widget-screening .esriCTPlanSettingsContainer .dijitSelect {width: 200px !important;}.jimu-widget-screening .esriCTPlanSettingsBtnContainer {padding: 10px; text-align: center;}.jimu-widget-screening .esriCTPlanSettingsBtn {max-width: 150px;}.jimu-widget-screening .esriCTEllipsis {overflow: hidden; text-overflow: ellipsis; white-space: nowrap;}.jimu-widget-screening .esriCTDownloadSettingLabel {margin-right: 15px; width: calc(50% - 18px); float: left; line-height: 30px;}.jimu-widget-screening .esriCTDownloadSettingsContainer .dijitSelect {width: 50% !important;}.jimu-widget-screening .esriCTDownloadSettingsBtnContainer {padding: 10px; text-align: right;}.jimu-widget-screening .esriCTDownloadSettingsBtn {max-width: 150px;}.jimu-widget-screening .esriCTPopupSettingsContainer .esriCTPopupSettingLabel {margin-right: 5px; width: calc(50% - 30px); float: left; line-height: 30px;}.jimu-widget-screening .esriCTPopupSettingsContainer .dijitSelect {width: 55% !important;}.jimu-widget-screening .esriCTPopupSettingsContainer .esriCTPopupSettingsBtnContainer {text-align: right; padding-right: 5px;}.jimu-widget-screening .esriCTPopupSettingsContainer .esriCTPrintDialogHint {font-style: italic; padding-top: 10px;}.jimu-widget-screening .esriCTPrintLayoutDropdown .dijitSelectLabel {text-align: left; overflow: hidden; width: 120px;}.esriRtl .jimu-widget-screening .esriCTPopupSettingsContainer .esriCTPopupSettingLabel {float: right; margin-right: 0px; margin-left: 5px;}.esriRtl .jimu-widget-screening .esriCTPopupSettingsContainer .esriCTPopupSettingsBtnContainer {text-align: left; padding: 0 0 0 5px;}.esriRtl .jimu-widget-screening .esriCTPrintLayoutDropdown .dijitSelectLabel {text-align: right;}.esriRtl .jimu-widget-screening .esriCTDownloadSettingsBtnContainer {text-align: left;}.jimu-widget-screening .esriCTUnitSettingsContainer {width: 100%;}.jimu-widget-screening .esriCTUnitSettingsContainer .esriCTAreaUnitMainPopupContainer {width: 100%; padding-bottom: 5px; padding-top: 5px; overflow: hidden;}.jimu-widget-screening .esriCTUnitSettingsContainer .esriCTLengthUnitMainPopupContainer {width: 100%; padding-bottom: 5px; padding-top: 5px; overflow: hidden;}.jimu-widget-screening .esriCTUnitSettingsContainer .esriCTPopupSettingLabel {width: 45%; float: left; padding-right: 5px; line-height: 30px;}.esriRtl .jimu-widget-screening .esriCTUnitSettingsContainer .esriCTPopupSettingLabel {float: right; padding-right: 0px; padding-left: 5px;}.jimu-widget-screening .esriCTUnitSettingsContainer .esriCTAreaDropdownContainer {width: 55%; float: left;}.jimu-widget-screening .esriCTUnitSettingsContainer .esriCTLengthDropdownContainer {width: 55%; float: left;}.jimu-widget-screening .esriCTUnitSettingsContainer .esriCTPopupSettingsBtnContainer {text-align: right; padding-right: 5px; padding-top: 10px;}.jimu-widget-screening .esriCTAnalysisUnitDropdown {width: 100%;}.jimu-widget-screening .esriCTAnalysisUnitDropdown .dijitSelectLabel {text-align: left; overflow: hidden; width: 120px;}.esriRtl .jimu-widget-screening .esriCTAnalysisUnitDropdown .dijitSelectLabel {text-align: right;}.jimu-widget-screening .esriCTUnitSettingsContainer .dijitSelect {width: 100% !important;}.jimu-widget-screening .esriCTUnitSettingsContainer .esriCTPopupSettingsBtnContainer {text-align: right; padding-right: 5px;}.jimu-widget-screening .esriCTReportAnalysisUnitSettingsDialogLaunchpadTheme {padding: 5px !important;}.esriRtl .jimu-widget-screening .esriCTUnitSettingsContainer .esriCTPopupSettingsBtnContainer {text-align: left; padding: 10px 0 0 5px;}.jimu-widget-screening .esriCTFieldDistinctData .esriCTNoData {font-style: italic;}.jimu-widget-screening .esriCTVisible {display: block;}.jimu-widget-screening .esriCTCursorPointer {cursor: pointer;}.jimu-widget-screening .esriCTDisableReportTab {cursor: not-allowed !important;}.jimu-widget-screening .esriCTAOIButtonSelected {background-color: #d9dde0;}.jimu-widget-screening .esriCTDisplayTableCell {display: table-cell;}.jimu-widget-screening .esriCTVisibilityHidden {visibility: hidden;}.jimu-widget-screening .esriCTBoldFont {font-weight: bold;}.dart-panel .jimu-widget-screening .esriCTAOIButtonSelected {background-color: #262626; color: #fff !important;}.claro .dart-panel .dijitTooltipContainer {color: #ffffff !important; background-color: #4c4c4c !important; background-image: -moz-linear-gradient(bottom, rgba(76, 76, 76, 0.1) 0px, #4c4c4c 10px) !important; background-image: -webkit-linear-gradient(bottom, rgba(76, 76, 76, 0.1) 0px, #4c4c4c 10px) !important; background-image: -o-linear-gradient(bottom, rgba(76, 76, 76, 0.1) 0px, #4c4c4c 10px) !important; background-image: linear-gradient(bottom, rgba(76, 76, 76, 0.1) 0px, #4c4c4c 10px) !important;}.claro .dart-panel .dijitSelect .dijitArrowButton {background-color: transparent;}.jimu-popup.esriCTDartPanel.jimu-widget-screening {color: #ffffff !important; background-color: #4c4c4c !important; background-image: -moz-linear-gradient(bottom, rgba(76, 76, 76, 0.1) 0px, #4c4c4c 10px) !important; background-image: -webkit-linear-gradient(bottom, rgba(76, 76, 76, 0.1) 0px, #4c4c4c 10px) !important; background-image: -o-linear-gradient(bottom, rgba(76, 76, 76, 0.1) 0px, #4c4c4c 10px) !important; background-image: linear-gradient(bottom, rgba(76, 76, 76, 0.1) 0px, #4c4c4c 10px) !important;}.esriCTDartPanel .label.jimu-float-leading {color: #ffffff;}.esriCTDartPanel.jimu-popup .title {color: white;}.jimu-widget-screening .esriCTRow {clear: both; width: 100%;}.jimu-widget-screening .esriCTImpactSummaryLayerContainer {width: 100%;}.jimu-widget-screening .esriCTLayerTitleAndFieldParentContainer {display: table; width: 100%; clear: both; height: 40px; line-height: 40px; padding: 5px 5px 5px 5px; border-bottom: 1px solid #d9dde0; table-layout: fixed;}.jimu-widget-screening .esriCTLayerTitleAndFieldChildContainer {display: table-row;}.jimu-widget-screening .esriCTImpactSummaryLayerTitle {float: left; max-width: calc(100% - 90px); text-align: left; height: 30px; line-height: 30px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; display: table-cell;}.jimu-widget-screening .esriCTLayerTitleOverrideWidth {max-width: calc(100% - 110px);}.jimu-widget-screening .esriCTLayerPanelIcon {display: table-cell; height: 15px; width: 15px; margin: 7px 5px 7px 0; float: left; background-position: center center; background-repeat: no-repeat; background-size: 15px 15px;}.jimu-widget-screening .esriCTLayerPanelCollapse {background-image: url('../images/panel-collapse.png');}.jimu-widget-screening .esriCTLayerPanelExpand {background-image: url('../images/panel-expand.png');}.jimu-widget-screening .esriCTImpactSummaryLayerFeatureCount {float: right; height: 30px; line-height: 30px; display: table-cell; padding-right: 5px; width: 41px; text-align: center;}.jimu-widget-screening .esriCTLoadingIcon {background-image: url('../images/loading-icon.gif'); background-position: center center; background-repeat: no-repeat; height: 20px; width: 20px; margin: 5px 10px;}.jimu-widget-screening .esriCTImpactSummaryLayerMaxRecordHint {background: url(../images/hint.png) center center no-repeat; background-size: 18px 18px; height: 30px; width: 20px; float: right; vertical-align: middle; display: table-cell; margin-right: 5px;}.esriRtl .jimu-widget-screening .esriCTImpactSummaryLayerMaxRecordHint {float: left; margin-left: 5px; margin-right: 0px;}.jimu-widget-screening .esriCTImpactSummaryLayerFieldIcon {background: url(../images/layer-field.png) center center no-repeat; background-size: 18px 18px; height: 30px; width: 20px; float: right; vertical-align: middle; display: table-cell;}.jimu-widget-screening .esriCTImpactSummaryLayerFieldIconDisabled {background: url(../images/layer-field-disable.png) center center no-repeat; cursor: not-allowed; background-size: 20px 20px;}.dart-panel .jimu-widget-screening .esriCTImpactSummaryLayerFieldIcon {background: url(../images/layer-field-disable.png) center center no-repeat; background-size: 20px 20px;}.dart-panel .jimu-widget-screening .esriCTImpactSummaryLayerFieldIconDisabled {background: url(../images/layer-field.png) center center no-repeat; background-size: 18px 18px;}.jimu-widget-screening .esriCTLayerDetailCenterText {text-align: center !important; padding-top: 10px; padding-bottom: 10px;}.jimu-widget-screening .esriCTImpactSummaryLayerDetailContainer {width: 100%; clear: both; text-align: left; padding: 0 10px 5px 5px; border-bottom: 1px solid #d9dde0; min-height: 30px;}.esriRtl .jimu-widget-screening .esriCTImpactSummaryLayerDetailContainer {text-align: right;}.jimu-widget-screening .esriCTTemplateNode {clear: both;}.jimu-widget-screening .esriCTFieldAlias {clear: both; padding: 5px;}.jimu-widget-screening .esriCTFieldDistinctData {width: 100%; clear: both; padding: 5px 5px 5px 15px;}.jimu-widget-screening .esriCTFieldDistinctData a {word-break: break-all;}.esriRtl .jimu-widget-screening .esriCTFieldDistinctData {padding: 5px 15px 5px 5px;}.jimu-widget-screening .esriCTFieldArea {clear: both; padding: 5px;}.jimu-widget-screening .esriCTUnitAreaContainer {float: right; width: 70%; text-align: right;}.esriRtl .jimu-widget-screening .esriCTUnitAreaContainer {float: left; text-align: left;}.jimu-widget-screening .esriCTHidden {display: none !important;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row .layer-name {line-height: 36px; height: 36px;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item {width: 100%; height: 36px; position: relative;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row {height: 36px; position: relative; cursor: pointer;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row\x3ediv {display: inline-block;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row .selectable-check {width: 36px; height: 36px; cursor: pointer; background: url(../images/unchecked.svg) no-repeat center;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row .selectable-check:hover {background: url(../images/unchecked_hover.svg) no-repeat center;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row .selectable-check.checked {background: url(../images/checked.svg) no-repeat center;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row .selectable-check.checked:hover {background: url(../images/checked_hover.svg) no-repeat center;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row .layer-name {margin: 0 5px; position: absolute; left: 36px; right: 72px;}.esriRtl .jimu-widget-screening .jimu-widget-screening-selectable-layer-item .layer-row .layer-name {left: 72px; right: 36px;}.jimu-widget-screening .jimu-widget-screening-selectable-layer-item.no-action .layer-row {cursor: default;}.jimu-widget-screening .esriCTDrawItem:focus {outline: 2px solid #24B5CC !important;}.jimu-widget-screening .esriCTUploadShapefileButton:focus {outline: 2px solid #24B5CC !important;}.jimu-widget-screening .esriCTZoomToIcon:focus {outline: 2px solid #24B5CC !important;}.jimu-widget-screening .arcgisSearch .searchGroup .searchInput:focus {outline: 2px solid #24B5CC !important;}.jimu-widget-screening .esriCTPlacenameButton:focus,.jimu-widget-screening .esriCTDrawToolButton:focus,.jimu-widget-screening .esriCTShapefileButton:focus,.jimu-widget-screening .esriCTCoordinateButton:focus {outline: 2px solid #24B5CC !important;}.jimu-widget-screening .esriCTDropdownButtonLabel {opacity: 0; height: 20px; width: 20px; padding: 5px; overflow: hidden;}.jimu-widget-screening .jimu-multiple-layers-featureset-chooser .draw-item-btn:focus {outline: 2px solid #24B5CC !important;}.jimu-widget-screening .esriCTLayerTitleAndFieldParentContainer:focus {outline: 2px solid #24B5CC !important; outline-offset: -2px;}.jimu-widget-screening .esriCTDownloadContainer:focus {outline: 2px solid #24B5CC !important;}",
"*now":function(D){D(['dojo/i18n!*preload*widgets/Screening/nls/Widget*["ar","bs","ca","cs","da","de","en","el","es","et","fi","fr","he","hr","hu","id","it","ja","ko","lt","lv","nb","nl","pl","pt-br","pt-pt","ro","ru","sk","sl","sr","sv","th","tr","zh-cn","uk","vi","zh-hk","zh-tw","ROOT"]'])},"*noref":1}});
define("dojo/_base/declare dojo/on dojo/_base/lang dojo/dom-class dojo/query dojo/dom-style dojo/dom-construct dijit/_WidgetsInTemplateMixin dojo/Deferred dojo/promise/all dojo/keys dijit/focus dojo/dom-attr dojo/_base/fx jimu/BaseWidget jimu/dijit/LoadingIndicator jimu/portalUtils jimu/dijit/Message esri/layers/GraphicsLayer esri/geometry/geometryEngine esri/graphic esri/tasks/BufferParameters esri/tasks/GeometryService esri/symbols/jsonUtils esri/graphicsUtils jimu/LayerInfos/LayerInfos ./layerUtil ./placename/placename ./drawTool/drawTool ./shapefile/shapefile ./coordinates/coordinates ./impactSummaryReport/impactSummaryReport ./download/download dojo/_base/array ./conversionUtils ./geometryUtils jimu/dijit/Report jimu/dijit/PageUtils dojo/number dijit/popup dojo/colors esri/tasks/PrintTemplate esri/tasks/LegendLayer jimu/portalUrlUtils jimu/utils dojo/date/locale esri/tasks/query esri/tasks/QueryTask esri/request dojo/DeferredList dojo/_base/event dojo/dom-geometry dijit/form/NumberTextBox dijit/form/DropDownButton".split(" "),function(D,
a,d,c,w,n,B,C,m,y,I,e,b,q,K,M,z,v,Q,S,U,g,G,F,l,E,R,aa,W,da,h,V,T,r,u,A,x,H,L,Y,ba,ca,fa,ia,ka,f,J,P,N,Z,ea,oa){return D([K,C],{baseClass:"jimu-widget-screening",_bufferValue:null,_currentActiveTool:null,_geometryService:null,_loadingIndicator:null,_aoiGraphicsLayer:null,_drawnOrSelectedGraphicsLayer:null,_uploadedShapefileGraphicsLayer:null,_toleranceGraphicsLayer:null,_placenameTool:null,_drawTool:null,_shapefileTool:null,_shapefileToolForAnalysis:null,_coordinatesTool:null,_layerInfoArray:null,
_currentPanel:null,_newShapeFileAnalysisArr:null,_downloadFeatureDetailsObj:{},_printData:{},_panels:{},_isReportGenerated:!1,_isExceedingMaxRecordCount:!1,_currentPanelName:"",printOptions:[],_defaultOptions:{"A3 Portrait":{Orientation:"Portrait",SizeName:"A3"},"A3 Landscape":{Orientation:"Landscape",SizeName:"A3"},"A4 Portrait":{Orientation:"Portrait",SizeName:"A4"},"A4 Landscape":{Orientation:"Landscape",SizeName:"A4"},"Letter ANSI A Portrait":{Orientation:"Portrait",SizeName:"Letter_ANSI_A"},
"Letter ANSI A Landscape":{Orientation:"Landscape",SizeName:"Letter_ANSI_A"},"Tabloid ANSI B Portrait":{Orientation:"Portrait",SizeName:"Tabloid_ANSI_B"},"Tabloid ANSI B Landscape":{Orientation:"Landscape",SizeName:"Tabloid_ANSI_B"}},_printServiceChoiceList:[],_isMapOnlyOptionAvailable:!1,_impactSummaryReportObjList:[],_changedFieldsObj:{},_isKeyPressed:!1,_alertMessageObj:null,_allowFocusOnFirstNode:!0,_isSingleTabSelected:!1,_isKeyPressedOnDownloadDialog:!1,constructor:function(k){this._newShapeFileAnalysisArr=
this._currentPanel=this._layerInfoArray=this._coordinatesTool=this._shapefileToolForAnalysis=this._shapefileTool=this._drawTool=this._placenameTool=this._toleranceGraphicsLayer=this._uploadedShapefileGraphicsLayer=this._drawnOrSelectedGraphicsLayer=this._aoiGraphicsLayer=this._loadingIndicator=this._geometryService=this._currentActiveTool=this._bufferValue=null;this._downloadFeatureDetailsObj={};this._printData={};this._panels={};this._isExceedingMaxRecordCount=this._isReportGenerated=!1;this._currentPanelName=
"";this.printOptions=[];this._printServiceChoiceList=[];this._isMapOnlyOptionAvailable=!1;this._impactSummaryReportObjList=[];this._changedFieldsObj={};this._isKeyPressed=!1;this._alertMessageObj=null;this._allowFocusOnFirstNode=!0;this._isKeyPressedOnDownloadDialog=this._isSingleTabSelected=!1;d.mixin(this,k)},postMixInProperties:function(){this.nls.common={};this.nls.units={};d.mixin(this.nls.common,window.jimuNls.common);d.mixin(this.nls.units,window.jimuNls.units)},postCreate:function(){this.openAtStartAysn=
!0;this._setAriaLabelToBufferDistTextBox()},startup:function(){var k;this.inherited(arguments);this._trackNumberOfConfiguredTabs();this._updateNoDataString();this._validateAreaUnit();this._setTheme();this.own(a(document.body,"click",d.hitch(this,function(){this._validateBufferDistance(this.bufferDistanceTextBox.getValue())})));c.add(this.domNode.parentElement,"esriCTOverridePanelStyle");this.appConfig.portalUrl&&""!==d.trim(this.appConfig.portalUrl)?z.getPortalSelfInfo(this.appConfig.portalUrl).then(d.hitch(this,
function(t){this.config.generateFeatureCollectionURL=this.getGenerateOperationUrl();this.config.helperServices=t&&t.helperServices;this.config.helperServices&&this.config.helperServices.geometry?(this._geometryService=new G(this.config.helperServices.geometry.url),(k=this._validateConfiguration())?(this._initLoadingIndicator(),this._filterLayersFromMap(),c.remove(this.backButtonDiv,"esriCTHidden")):this._displayErrorMessageInWidget()):this._showMessage(this.nls.geometryServicesNotFound)}),d.hitch(this,
function(){this._showMessage(this.nls.geometryServicesNotFound)})):this._showMessage(this.nls.geometryServicesNotFound)},_setAriaLabelToBufferDistTextBox:function(){b.set(this.bufferDistanceTextBox,"aria-label",this.nls.bufferDistanceAndUnit.bufferInputTitle+" "+this.nls.bufferDistanceAndUnit.bufferInputLabel+" "+this.bufferDistanceTextBox.getValue()+" "+this.bufferDistanceUnit._getSelectedOptionsAttr().label)},getGenerateOperationUrl:function(){var k=z.getPortal(this.appConfig.portalUrl);return ia.getSharingUrl(k.portalUrl)+
"/content/features/generate"},_validateAreaUnit:function(){switch(this.config.areaUnits){case "Standard":this.config.areaUnits="Acres";this.config.hasOwnProperty("lengthUnits")||(this.config.lengthUnits="Miles");break;case "Metric":this.config.areaUnits="SquareKilometers";this.config.hasOwnProperty("lengthUnits")||(this.config.lengthUnits="Kilometers");break;case "Feet":this.config.areaUnits="SquareFeet";this.config.hasOwnProperty("lengthUnits")||(this.config.lengthUnits="Feet");break;case "Miles":this.config.areaUnits=
"Acres";this.config.hasOwnProperty("lengthUnits")||(this.config.lengthUnits="Miles");break;case "Meters":this.config.areaUnits="SquareMeters";this.config.hasOwnProperty("lengthUnits")||(this.config.lengthUnits="Meters");break;case "Kilometers":this.config.areaUnits="SquareKilometers";this.config.hasOwnProperty("lengthUnits")||(this.config.lengthUnits="Kilometers");break;case "Hectares":this.config.areaUnits="Hectares",this.config.hasOwnProperty("lengthUnits")||(this.config.lengthUnits="Kilometers")}},
_setTheme:function(k){if("DashboardTheme"===this.appConfig.theme.name){if(ka.loadStyleLink(this.baseClass+"dashboardOverrideCSS",this.folderUrl+"/css/dashboardTheme.css",null),this.appConfig.theme.styles&&0<this.appConfig.theme.styles.length)if("light"===this.appConfig.theme.styles[0]||"light"===k)if(k&&"light"!==k){if(k=document.getElementById(this.baseClass+"dashboardOverrideLightCSS"))k.disabled=!0}else ka.loadStyleLink(this.baseClass+"dashboardOverrideLightCSS",this.folderUrl+"/css/dashboardThemeLight.css",
null);else if(k=document.getElementById(this.baseClass+"dashboardOverrideLightCSS"))k.disabled=!0}else{if(k=document.getElementById(this.baseClass+"dashboardOverrideCSS"))k.disabled=!0;if(k=document.getElementById(this.baseClass+"dashboardOverrideLightCSS"))k.disabled=!0}},_displayErrorMessageInWidget:function(){c.add(this.widgetMainContainer,"esriCTHidden");c.remove(this.errorMessageMainContainer,"esriCTHidden")},onOpen:function(){this._drawnOrSelectedGraphicsLayer&&this._drawnOrSelectedGraphicsLayer.graphics&&
this._drawnOrSelectedGraphicsLayer.show();this._aoiGraphicsLayer&&this._aoiGraphicsLayer.graphics&&this._aoiGraphicsLayer.show();this._highlightGraphicsLayer&&this._highlightGraphicsLayer.show()},onClose:function(){this._drawnOrSelectedGraphicsLayer&&this._drawnOrSelectedGraphicsLayer.graphics&&this._drawnOrSelectedGraphicsLayer.hide();this._aoiGraphicsLayer&&this._aoiGraphicsLayer.graphics&&this._aoiGraphicsLayer.hide();this._drawTool&&this._drawTool.deactivateTools();this._coordinatesTool&&this._coordinatesTool.deactivateLocateIcon();
this._highlightGraphicsLayer&&this._highlightGraphicsLayer.hide()},onDeActive:function(){this._drawTool&&this._drawTool.deactivateTools()},_initWidgetComponents:function(){this._initTabControl();this._attachAllEvents();this._setUpPrintDialogPopup();this._setAnalysisUnitDialogPopup();this._disableShowReportsButton();this._createAndAddGraphicsLayer();this._displayConfiguredWidgetAOIButton();this._setBufferInputs();this._canDownload()?this._initDownloadWidget():c.add(this.downloadReportBtn,"esriCTHidden");
this.config.allowShapefilesUpload&&this._initShapeFileForAnalysis();this._displayConfiguredAOIArea();this._initReportDijit();this._setAccessibility();this._loadingIndicator.hide()},_canDownload:function(){var k=!1;if(this.isIOS())k=!1;else return this.config.downloadSettings?"cannotDownload"===this.config.downloadSettings.type?k=!1:"extractDataTask"===this.config.downloadSettings.type?k=!0:"syncEnable"===this.config.downloadSettings.type&&r.some(this.config.downloadSettings.layers,d.hitch(this,function(t){if(t.allowDownload)return k=
!0})):k=!1,k},onReceiveSearchData:function(k){this._loadingIndicator.show();if(k&&k.source&&k.source.locator)if(c.contains(this.placenameButton,"esriCTAOIButtonSelected")){var t=[k.result.feature];this._initToCreateAOIBuffer(t);setTimeout(d.hitch(this,function(){this.map.infoWindow.show(t[0].geometry)}),500)}else c.contains(this.coordinatesButton,"esriCTAOIButtonSelected")&&"point"===k.result.feature.geometry.type&&(this._coordinatesTool.onStartPointSelected(k.result.feature.geometry),this._loadingIndicator.hide());
else{var O=new J;O.outFields=["*"];O.returnGeometry=!0;O.objectIds=[k.result.feature.attributes[k.result.feature._layer.objectIdField]];O.outSpatialReference=this.map.spatialReference;k=new P(k.result.feature._layer.url);k.execute(O,d.hitch(this,function(X){if(X.features)if(c.contains(this.placenameButton,"esriCTAOIButtonSelected")){t=[X.features[0]];this._initToCreateAOIBuffer(t);var ha=this._getPointFromGeometry(t[0].geometry);setTimeout(d.hitch(this,function(){this.map.infoWindow.show(ha)}),500)}else{if(c.contains(this.coordinatesButton,
"esriCTAOIButtonSelected")){if("point"===X.features[0].geometry.type)this._coordinatesTool.onStartPointSelected(X.features[0].geometry);else if("polyline"===X.features[0].geometry.type)this._coordinatesTool.onStartPointSelected(X.features[0].geometry.getPoint(0,0));else if("polygon"===X.features[0].geometry.type)this._coordinatesTool.onStartPointSelected(X.features[0].geometry.getCentroid());this._loadingIndicator.hide()}}else this._loadingIndicator.hide()}),d.hitch(this,function(){this._loadingIndicator.hide()}))}},
_getPointFromGeometry:function(k){switch(k.type){case "extent":var t=k.getCenter();break;case "multipoint":t=k.getPoint(0);break;case "point":t=k;break;case "polygon":t=k.getCentroid();break;case "polyline":t=k.getPoint(0,0)}return t},_initLoadingIndicator:function(){this._loadingIndicator=new M({hidden:!0});this._loadingIndicator.placeAt(this.domNode.parentNode);this._loadingIndicator.startup()},_validateConfiguration:function(){return!this.config.layers||0===this.config.layers.length||0===this.config.layers.length&&
!1===this.config.showPlacenameWidget&&!1===this.config.showDrawToolsWidget&&!1===this.config.showShapefileWidget&&!1===this.config.showCoordinatesWidget?!1:!0},_initTabControl:function(){b.set(this.aoiLabelContainer,"innerHTML",this.config.aoiTabText);b.set(this.reportLabelContainer,"innerHTML",this.config.reportTabText);this._panels.aoiTabParentContainer=this.aoiTabParentContainer;this._panels.reportTabParentContainer=this.reportTabParentContainer;this._currentPanel=this.aoiTabParentContainer;this._currentPanelName=
"aoiTabParentContainer";c.remove(this._currentPanel,"esriCTHidden");n.set(this._currentPanel,"left","0px")},_attachAllEvents:function(){var k;this.own(a(this.placenameButton,"click",d.hitch(this,function(t){ea.stop(t);this._clearSelection();this._onPlacenameButtonClick();this._setAccessibility()})));this.own(a(this.placenameButton,"keydown",d.hitch(this,function(t){t.keyCode!==I.ENTER&&t.keyCode!==I.SPACE||t.shiftKey||(ea.stop(t),this._clearSelection(),this._onPlacenameButtonClick(),this._setAccessibility());
this._navigateAoiTabs(t)})));this.own(a(this.drawToolsButton,"click",d.hitch(this,function(t){ea.stop(t);this._clearSelection();this._onDrawToolsButtonClick();this._setAccessibility()})));this.own(a(this.drawToolsButton,"keydown",d.hitch(this,function(t){t.keyCode!==I.ENTER&&t.keyCode!==I.SPACE||t.shiftKey||(ea.stop(t),this._clearSelection(),this._onDrawToolsButtonClick(),this._setAccessibility());this._navigateAoiTabs(t)})));this.own(a(this.shapefileButton,"click",d.hitch(this,function(t){ea.stop(t);
this._clearSelection();this._onShapefileButtonClick();this._setAccessibility()})));this.own(a(this.shapefileButton,"keydown",d.hitch(this,function(t){t.keyCode!==I.ENTER&&t.keyCode!==I.SPACE||t.shiftKey||(ea.stop(t),this._clearSelection(),this._onShapefileButtonClick(),this._setAccessibility());this._navigateAoiTabs(t)})));this.own(a(this.coordinatesButton,"click",d.hitch(this,function(t){ea.stop(t);this._clearSelection();this._onCoordinatesButtonClick();this._setAccessibility()})));this.own(a(this.coordinatesButton,
"keydown",d.hitch(this,function(t){t.keyCode!==I.ENTER&&t.keyCode!==I.SPACE||t.shiftKey||(ea.stop(t),this._clearSelection(),this._onCoordinatesButtonClick(),this._setAccessibility());this._navigateAoiTabs(t)})));this.own(a(this.clearAOIButton,"click",d.hitch(this,function(t){ea.stop(t);this._clearAOI()})));this.own(a(this.clearAOIButton,"keydown",d.hitch(this,function(t){if(t.keyCode===I.ENTER||t.keyCode===I.SPACE)ea.stop(t),this._clearAOI();t.keyCode!==I.ESCAPE||this._isSingleTabSelected||(ea.stop(t),
this._focusLastSelectedTab())})));this.own(a(this.showReportsButton,"click",d.hitch(this,function(t){ea.stop(t);this._onReportButtonClick()})));this.own(a(this.showReportsButton,"keydown",d.hitch(this,function(t){if(t.keyCode===I.ENTER||t.keyCode===I.SPACE)ea.stop(t),this._onReportButtonClick();t.keyCode!==I.ESCAPE||this._isSingleTabSelected||(ea.stop(t),this._focusLastSelectedTab())})));this.own(a(this.backButtonDiv,"click",d.hitch(this,function(t){ea.stop(t);this._onBackButtonClick();this._setAccessibility()})));
this.own(a(this.backButtonIconDiv,"keydown",d.hitch(this,function(t){if(t.keyCode===I.ENTER||t.keyCode===I.SPACE)ea.stop(t),this._onBackButtonClick(),this._setAccessibility()})));this.own(a(this.zoomToNode,"click",d.hitch(this,function(t){ea.stop(t);this._onZoomButtonClick()})));this.own(a(this.zoomToNode,"keydown",d.hitch(this,function(t){if(t.keyCode===I.ENTER||t.keyCode===I.SPACE)ea.stop(t),this._onZoomButtonClick()})));this.own(a(this.downloadReportBtn,"click",d.hitch(this,function(t){ea.stop(t);
this._onDownloadClick(t)})));this.own(a(this.downloadReportBtn,"keydown",d.hitch(this,function(t){if(t.keyCode===I.ENTER||t.keyCode===I.SPACE){ea.stop(t);t=oa.position(this.downloadReportBtn);var O={};O.pageX=t.x+15;O.pageY=t.y+12;this._onDownloadClick(O);this.downloadWidgetInstance.setFocusOnFormatDropdown()}})));this.own(a(this.refreshReportBtn,"click",d.hitch(this,function(t){ea.stop(t);this._refreshReportPanel()})));this.own(a(this.refreshReportBtn,"keydown",d.hitch(this,function(t){if(t.keyCode===
I.ENTER||t.keyCode===I.SPACE)ea.stop(t),this._refreshReportPanel()})));(k=w(".contentPane",this.map.infoWindow.domNode))&&0<k.length&&(k=k[0],this.own(a(k,"click",d.hitch(this,function(t){c.contains(this.aoiLabelContainer,"esriCTHidden")&&t.target.hasAttribute("data-index")&&t.target.hasAttribute("data-source-index")&&this.backButtonDiv.click()}))));this.own(a(this.bufferDistanceUnitDropdownContainer,"keydown",d.hitch(this,function(t){t.keyCode!==I.ESCAPE||this._isSingleTabSelected||(ea.stop(t),this._focusLastSelectedTab())})));
this.own(a(this.analysisAreaUnitSelect,"keydown",d.hitch(this,function(t){t.keyCode===I.ESCAPE&&(ea.stop(t),this._closeUnitSettingDialog(),this._focusOutCurrentNode(),e.focus(this.analysisUnitButton.focusNode))})));this.own(a(this.analysisLengthUnitSelect,"keydown",d.hitch(this,function(t){t.keyCode===I.ESCAPE&&(ea.stop(t),this._closeUnitSettingDialog(),this._focusOutCurrentNode(),e.focus(this.analysisUnitButton.focusNode))})));this.own(a(this.printLayoutSelect,"keydown",d.hitch(this,function(t){t.keyCode===
I.ESCAPE&&(ea.stop(t),this.closePrintDialog(),this._focusOutCurrentNode(),e.focus(this.printIconButton.focusNode))})));this.own(a(this.map,"extent-change",d.hitch(this,function(){""!==this._drawTool&&null!==this._drawTool&&void 0!==this._drawTool&&"selectTool"===this._drawTool.currentSelectedDrawTool&&this._drawTool.setFocusOnSelectTool()})))},_onBackButtonClick:function(){this._getImpactReportSelectedFields();c.remove(this.aoiLabelContainer,"esriCTHidden");c.add(this.reportLabelContainer,"esriCTHidden");
this._showPanel("aoiTabParentContainer",!0)},_getImpactReportSelectedFields:function(){r.forEach(this._impactSummaryReportObjList,d.hitch(this,function(k){this._changedFieldsObj[k.layerID]=k.getSelectedFields()}))},_refreshReportPanel:function(){this._isReportGenerated=!1;this._getImpactReportSelectedFields();this._onReportTabClick()},_setMaxHeightOfAOIWidgetContainer:function(){var k;if(k=this.domNode.parentElement)k=n.getComputedStyle(k).height,k=parseInt(k,10),k=k-251+"px",n.set(this.placenameWidgetContainer,
"max-height",k),n.set(this.drawToolWidgetContainer,"max-height",k),n.set(this.shapefileWidgetContainer,"max-height",k),n.set(this.coordinateWidgetContainer,"max-height",k)},_setMaxHeightOfImpactSummaryReportContainer:function(){var k,t=0;if(k=this.domNode.parentElement)k=n.getComputedStyle(k).height,k=parseInt(k,10),this.config.allowShapefilesUpload&&(t=this.uploadShapefileAnalysisTableContainer.clientHeight),n.set(this.impactSummaryReportContainer,"height",k-(85+t+20)+"px")},_onPlacenameButtonClick:function(){c.contains(this.placenameWidgetContainer,
"esriCTHidden")&&this._showActiveToolPanel("placename");this._drawTool&&this._drawTool.deactivateTools();this._coordinatesTool&&this._coordinatesTool.deactivateLocateIcon()},_onDrawToolsButtonClick:function(){c.contains(this.drawToolWidgetContainer,"esriCTHidden")&&(this._showActiveToolPanel("drawTool"),this._coordinatesTool&&this._coordinatesTool.deactivateLocateIcon())},_onShapefileButtonClick:function(){c.contains(this.shapefileWidgetContainer,"esriCTHidden")&&this._showActiveToolPanel("shapefile");
this._drawTool&&this._drawTool.deactivateTools();this._coordinatesTool&&this._coordinatesTool.deactivateLocateIcon()},_onCoordinatesButtonClick:function(){c.contains(this.coordinateWidgetContainer,"esriCTHidden")&&this._showActiveToolPanel("coordinates");this._drawTool&&this._drawTool.deactivateTools()},_showActiveToolPanel:function(k){this._deSelectPreviousAOIButton();this._hideAllWidgetContainers();this._currentActiveTool=k;switch(k){case "placename":c.add(this.placenameButton,"esriCTAOIButtonSelected");
this._deSelectAllTabs();b.set(this.placenameButton,"aria-selected","true");c.replace(this.placenameWidgetContainer,"esriCTVisible","esriCTHidden");break;case "drawTool":c.add(this.drawToolsButton,"esriCTAOIButtonSelected");this._deSelectAllTabs();b.set(this.drawToolsButton,"aria-selected","true");c.replace(this.drawToolWidgetContainer,"esriCTVisible","esriCTHidden");break;case "shapefile":c.add(this.shapefileButton,"esriCTAOIButtonSelected");this._deSelectAllTabs();b.set(this.shapefileButton,"aria-selected",
"true");c.replace(this.shapefileWidgetContainer,"esriCTVisible","esriCTHidden");break;case "coordinates":c.add(this.coordinatesButton,"esriCTAOIButtonSelected"),this._deSelectAllTabs(),b.set(this.coordinatesButton,"aria-selected","true"),c.replace(this.coordinateWidgetContainer,"esriCTVisible","esriCTHidden")}},_deSelectPreviousAOIButton:function(){var k;(k=w(".esriCTAOIButtonSelected",this.aoiButtonParentContainer))&&k[0]&&c.remove(k[0],"esriCTAOIButtonSelected")},_hideAllWidgetContainers:function(){var k;
var t=this.aoiWidgetParentContainer.children;for(k=0;k<t.length;k++)c.contains(t[k],"esriCTVisible")&&c.replace(t[k],"esriCTHidden","esriCTVisible")},_onReportTabClick:function(){this._impactSummaryReportObjList=[];this._drawTool&&this._drawTool.deactivateTools();var k=this._getAOIGeometriesInfo();"AllPolygons"===k||"AOIGraphics"===k?(k=A.getAreaOfGeometry(this._getUnionGeometry(this._aoiGraphicsLayer.graphics)),this._calculateSelectedUnitAOIArea(k.squareFeet,"polygon",this.aoiFeetUnitAreaContainer,
"SquareFeet"),this._calculateSelectedUnitAOIArea(k.acres,"polygon",this.aoiMilesUnitAreaContainer,"Acres"),this._calculateSelectedUnitAOIArea(k.squareMeters,"polygon",this.aoiMetersUnitAreaContainer,"SquareMeters"),this._calculateSelectedUnitAOIArea(k.squareKilometer,"polygon",this.aoiKilometersUnitAreaContainer,"SquareKilometers"),this._calculateSelectedUnitAOIArea(k.hectares,"polygon",this.aoiHectaresUnitAreaContainer,"Hectares"),this._calculateSelectedUnitAOIArea(k.squareMiles,"polygon",this.aoiSquareMilesUnitAreaContainer,
"SquareMiles")):"AllLines"===k?(k="coordinates"===this._currentActiveTool?this._getFilteredLineGraphics():this._drawnOrSelectedGraphicsLayer.graphics,k=A.getLengthOfGeometry(this._getUnionGeometry(k)),this._calculateSelectedUnitAOIArea(k.feet,"line",this.aoiFeetUnitAreaContainer,"Feet"),this._calculateSelectedUnitAOIArea(k.miles,"line",this.aoiMilesUnitAreaContainer,"Miles"),this._calculateSelectedUnitAOIArea(k.meters,"line",this.aoiMetersUnitAreaContainer,"Meters"),this._calculateSelectedUnitAOIArea(k.kilometers,
"line",this.aoiKilometersUnitAreaContainer,"Kilometers"),this._calculateSelectedUnitAOIArea(k.kilometers,"line",this.aoiHectaresUnitAreaContainer,"Hectares")):(b.set(this.aoiFeetUnitAreaContainer,"innerHTML",""),b.set(this.aoiMilesUnitAreaContainer,"innerHTML",""),b.set(this.aoiMetersUnitAreaContainer,"innerHTML",""),b.set(this.aoiKilometersUnitAreaContainer,"innerHTML",""),b.set(this.aoiHectaresUnitAreaContainer,"innerHTML",""),b.set(this.aoiSquareMilesUnitAreaContainer,"innerHTML",""));this._isReportGenerated?
this._setAccessibility():(this._clearSelection(),this._toggleReportTabButtons(!1),this._highlightGraphicsLayer.clear(),this._uploadedShapefileGraphicsLayer.clear(),this._initializeImpactSummaryReportWidget());this._setMaxHeightOfImpactSummaryReportContainer()},_getFilteredLineGraphics:function(){var k=[];r.forEach(this._drawnOrSelectedGraphicsLayer.graphics,d.hitch(this,function(t){"polyline"===t.geometry.type&&k.push(t)}));return k},_onDownloadClick:function(k){c.contains(this.downloadReportBtn,
"esriCTDownloadBtnDisabled")||this._initDownloadWidget(k)},_getArrayIndex:function(k,t){var O,X,ha=[];for(O=0;O<k.length;++O)if(t.length===k[O].length){var ja=k[O];for(X=0;X<t.length&&t[X]===ja[X];)++X;X===t.length&&ha.push(O)}return ha},getSum:function(k,t){k=(t&&0<t.length?r.filter(k,function(O,X){return-1<t.indexOf(X)}):k).reduce(function(O,X){return O+X},0);return.01<k?u.honourPopupRounding(2,k):k},_getAggregatedColTitle:function(k){switch(k){case "esriGeometryPoint":var t=this.nls.reportsTab.featureCountText;
break;case "esriGeometryPolyline":switch(this.analysisLengthUnitSelect.get("value")){case "Feet":t=this.nls.reportsTab.featureLengthText+"("+this._getAOIUnitForGeometry("Feet",k)+")";break;case "Miles":t=this.nls.reportsTab.featureLengthText+"("+this._getAOIUnitForGeometry("Miles",k)+")";break;case "Meters":t=this.nls.reportsTab.featureLengthText+"("+this._getAOIUnitForGeometry("Meters",k)+")";break;case "Kilometers":t=this.nls.reportsTab.featureLengthText+"("+this._getAOIUnitForGeometry("Kilometers",
k)+")"}break;case "esriGeometryPolygon":switch(this.analysisAreaUnitSelect.get("value")){case "SquareFeet":t=this.nls.reportsTab.featureAreaText+"("+this._getAOIUnitForGeometry("SquareFeet",k)+")";break;case "Acres":t=this.nls.reportsTab.featureAreaText+"("+this._getAOIUnitForGeometry("Acres",k)+")";break;case "SquareMeters":t=this.nls.reportsTab.featureAreaText+"("+this._getAOIUnitForGeometry("SquareMeters",k)+")";break;case "SquareKilometers":t=this.nls.reportsTab.featureAreaText+"("+this._getAOIUnitForGeometry("SquareKilometers",
k)+")";break;case "Hectares":t=this.nls.reportsTab.featureAreaText+"("+this._getAOIUnitForGeometry("Hectares",k)+")";break;case "SquareMiles":t=this.nls.reportsTab.featureAreaText+"("+this._getAOIUnitForGeometry("SquareMiles",k)+")"}}return t},_getPrintTemplate:function(){var k=[];var t=new ca;this.reportDijit._printService.legendAll=!0;this.reportDijit._printService._getPrintDefinition(this.map,t);r.forEach(this.reportDijit._printService.allLayerslegend,d.hitch(this,function(O){if(O.id!==this._aoiGraphicsLayer.id&&
O.id!==this._drawnOrSelectedGraphicsLayer.id&&O.id!==this._highlightGraphicsLayer.id){var X=this.layerInfosObj.getLayerInfoById(O.id);if(""!==X&&null!==X&&void 0!==X&&X.hasOwnProperty("originOperLayer")){var ha=!0;X.originOperLayer.hasOwnProperty("showLegend")&&(X.originOperLayer.showLegend||(ha=!1));ha&&(X=new fa,X.layerId=O.id,O.subLayerIds&&(X.subLayerIds=O.subLayerIds),k.push(X))}}}));this.reportDijit._printService.legendAll=!1;t.layoutOptions={legendLayers:k,customTextElements:[{Date:""}]};t=
this.reportDijit.setMapLayout(t);this._isMapOnlyOptionAvailable&&(t.layout="MAP_ONLY");t.preserveScale=!0;t.showAttribution=!0;t.format="jpg";return t},_sortFeatureArray:function(k,t){var O=k.length-1;return k[O]<t[O]?1:k[O]>t[O]?-1:0},_setNotApplicableRows:function(k){var t=k.length-1;.01>k[t]&&0!==k[t]?k[t]=" \x3c "+L.format(.01)+" ":0===k[t]&&(k[t]=this.nls.reportsTab.notApplicableText);return k},_getDate:function(){return f.format(new Date,{selector:"date",formatLength:"short",datePattern:"MMM d yyyy H:mm:ss z"})},
_addCommaToAreaAndLengthColumn:function(k,t){r.forEach(k.rows,d.hitch(this,function(O,X){var ha=O.length-1;isNaN(k.rows[X][ha])||(k.rows[X][ha]="esriGeometryPoint"===t?L.format(O[ha]):L.format(O[ha],{places:2}))}));return k},_getProcessedPrintData:function(){var k=[];var t=this.nls.reportsTab.aoiInformationTitle;if(c.contains(this.aoiFeetUnitAreaContainer,"esriCTHidden"))c.contains(this.aoiMilesUnitAreaContainer,"esriCTHidden")?c.contains(this.aoiMetersUnitAreaContainer,"esriCTHidden")?c.contains(this.aoiKilometersUnitAreaContainer,
"esriCTHidden")?c.contains(this.aoiHectaresUnitAreaContainer,"esriCTHidden")?c.contains(this.aoiSquareMilesUnitAreaContainer,"esriCTHidden")||(O=this.aoiSquareMilesUnitAreaContainer.innerHTML):O=this.aoiHectaresUnitAreaContainer.innerHTML:O=this.aoiKilometersUnitAreaContainer.innerHTML:O=this.aoiMetersUnitAreaContainer.innerHTML:O=this.aoiMilesUnitAreaContainer.innerHTML;else var O=this.aoiFeetUnitAreaContainer.innerHTML;t=this.reportDijit.Date?"\x3cdiv class\x3d'esrCTAOIInfoDiv'\x3e\x3cdiv class\x3d'esriAOITitle'\x3e\x3cinput class\x3d'esriCTAOITitleInput' tabindex\x3d'0' type\x3d'text' value\x3d'"+
t+"'role\x3d'textbox' aria-label\x3d'"+t+"'\x3e\x3c/div\x3e\x3cdiv class\x3d'esriCTAOIArea'\x3e\x3cinput class\x3d'esriCTAOIInputArea' tabindex\x3d'0' type\x3d'text' value\x3d'"+O+"'role\x3d'textbox' aria-label\x3d'"+this.nls.reportsTab.aoiAreaText+"'\x3e\x3c/div\x3e\x3cdiv class\x3d'esriCTPrintLocaleDateDiv'\x3e\x3cinput type\x3d'text' tabindex\x3d'0' class\x3d'esriCTLocaleDateInputTitle' value\x3d'"+this._getDate()+"'role\x3d'textbox' aria-label\x3d'"+this.nls.common.date+"'\x3e\x3c/div\x3e\x3c/div\x3e":
"\x3cdiv class\x3d'esrCTAOIInfoDiv'\x3e\x3cdiv class\x3d'esriAOITitle'\x3e\x3cinput class\x3d'esriCTAOITitleInput' tabindex\x3d'0' type\x3d'text' value\x3d'"+t+"'role\x3d'textbox' aria-label\x3d'"+t+"'\x3e\x3c/div\x3e\x3cdiv class\x3d'esriCTAOIArea'\x3e\x3cinput class\x3d'esriCTAOIInputArea' tabindex\x3d'0' type\x3d'text' value\x3d'"+O+"'role\x3d'textbox' aria-label\x3d'"+this.nls.reportsTab.aoiAreaText+"'\x3e\x3c/div\x3e\x3c/div\x3e";k.push({title:"",type:"html",data:t});t={addPageBreak:!0,type:"map",
map:this.map,printTemplate:this._getPrintTemplate()};k.push(t);k.push({type:"note",addPageBreak:!1});t="table";this.config.reportSettings.hasOwnProperty("displaySummaryInReport")&&(this.config.reportSettings.displaySummaryInReport||(t=null));t={title:this.nls.reportsTab.summaryReportTitle,addPageBreak:!1,type:t,data:{showRowIndex:!1,maxNoOfCols:4,rows:[],cols:[this.nls.common.name,this._getAggregatedColTitle("esriGeometryPoint"),this._getAggregatedColTitle("esriGeometryPolygon"),this._getAggregatedColTitle("esriGeometryPolyline")]}};
for(na in this._printData){var X,ha;var ja=this._printData[na].info;O=[];if(ja.rows&&0<ja.rows.length){if(ja.cols&&0<ja.cols.length){O=[ja.title];var la=[];var ma={};for(var pa=0;pa<ja.rows.length;pa++)if(this._printData[na].hasOwnProperty("groupbyfieldCheckBoxStatus")&&this._printData[na].groupbyfieldCheckBoxStatus){if(0>la.indexOf(pa)){var qa=this._getArrayIndex(ja.rows,ja.rows[pa]);ma[pa]=qa;la=la.concat(qa)}if(la.length===ja.rows.length)break}else qa=[],qa.push(pa),ma[pa]=qa;la={showRowIndex:!0,
rows:[],cols:d.clone(ja.cols)};la.cols.push(this._getAggregatedColTitle(this._printData[na].geometryType));for(X in ma){pa=d.clone(ja.rows[parseInt(X,10)]);"esriGeometryPolygon"===this._printData[na].geometryType?ha=this.analysisAreaUnitSelect.get("value"):"esriGeometryPolyline"===this._printData[na].geometryType?ha=this.analysisLengthUnitSelect.get("value"):"esriGeometryPoint"===this._printData[na].geometryType&&(ha="Count");switch(ha){case "Feet":pa.push(this.getSum(this._printData[na].feetUnitInfo,
ma[parseInt(X,10)]));break;case "SquareFeet":pa.push(this.getSum(this._printData[na].squareFeetUnitInfo,ma[parseInt(X,10)]));break;case "Miles":pa.push(this.getSum(this._printData[na].milesUnitInfo,ma[parseInt(X,10)]));break;case "Acres":pa.push(this.getSum(this._printData[na].acresUnitInfo,ma[parseInt(X,10)]));break;case "Meters":pa.push(this.getSum(this._printData[na].metersUnitInfo,ma[parseInt(X,10)]));break;case "SquareMeters":pa.push(this.getSum(this._printData[na].squareMetersUnitInfo,ma[parseInt(X,
10)]));break;case "Kilometers":pa.push(this.getSum(this._printData[na].kilometersUnitInfo,ma[parseInt(X,10)]));break;case "SquareKilometers":pa.push(this.getSum(this._printData[na].squareKilometersUnitInfo,ma[parseInt(X,10)]));break;case "Hectares":pa.push(this.getSum(this._printData[na].hectaresUnitInfo,ma[parseInt(X,10)]));break;case "SquareMiles":pa.push(this.getSum(this._printData[na].squareMilesUnitInfo,ma[parseInt(X,10)]));break;case "Count":pa.push(this.getSum(this._printData[na].countUnitInfo,
ma[parseInt(X,10)]))}la.rows.push(pa)}if(la.rows&&0<la.rows.length){la.rows=la.rows.sort(this._sortFeatureArray);la.rows=r.map(la.rows,d.hitch(this,this._setNotApplicableRows));la.rows=d.hitch(this._hideZeroValueRows(la.rows));la.rows=d.hitch(this._hideNullValueRows(la.rows));la.rows=d.hitch(this._hideNoDataValueRows(la.rows));la.rows=d.hitch(this._hideZeroAndNullValueRows(la.rows));la=this._addCommaToAreaAndLengthColumn(la,this._printData[na].geometryType);ja={title:ja.title,addPageBreak:!1,type:"table",
data:la};k.push(ja);switch(ha){case "Feet":var ra="esriGeometryPoint"!==this._printData[na].geometryType?L.format(this.getSum(this._printData[na].feetUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].feetUnitInfo));break;case "SquareFeet":ra="esriGeometryPoint"!==this._printData[na].geometryType?L.format(this.getSum(this._printData[na].squareFeetUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].squareFeetUnitInfo));break;case "Miles":ra="esriGeometryPoint"!==this._printData[na].geometryType?
L.format(this.getSum(this._printData[na].milesUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].milesUnitInfo));break;case "Acres":ra="esriGeometryPoint"!==this._printData[na].geometryType?L.format(this.getSum(this._printData[na].acresUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].acresUnitInfo));break;case "Meters":ra="esriGeometryPoint"!==this._printData[na].geometryType?L.format(this.getSum(this._printData[na].metersUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].metersUnitInfo));
break;case "SquareMeters":ra="esriGeometryPoint"!==this._printData[na].geometryType?L.format(this.getSum(this._printData[na].squareMetersUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].squareMetersUnitInfo));break;case "Kilometers":ra="esriGeometryPoint"!==this._printData[na].geometryType?L.format(this.getSum(this._printData[na].kilometersUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].kilometersUnitInfo));break;case "SquareKilometers":ra="esriGeometryPoint"!==this._printData[na].geometryType?
L.format(this.getSum(this._printData[na].squareKilometersUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].squareKilometersUnitInfo));break;case "Hectares":ra="esriGeometryPoint"!==this._printData[na].geometryType?L.format(this.getSum(this._printData[na].hectaresUnitInfo),{places:2}):L.format(this.getSum(this._printData[na].hectaresUnitInfo));break;case "SquareMiles":ra="esriGeometryPoint"!==this._printData[na].geometryType?L.format(this.getSum(this._printData[na].squareMilesUnitInfo),
{places:2}):L.format(this.getSum(this._printData[na].squareMilesUnitInfo));break;case "Count":"esriGeometryPoint"===this._printData[na].geometryType&&(ra=L.format(this.getSum(this._printData[na].countUnitInfo)))}ja=0===this._aoiGraphicsLayer.graphics.length?this.nls.reportsTab.notApplicableText:.01>ra&&0!==ra?" \x3c "+L.format(.01)+" ":ra;switch(this._printData[na].geometryType){case "esriGeometryPoint":O=O.concat(ra,this.nls.reportsTab.notApplicableText,this.nls.reportsTab.notApplicableText);break;
case "esriGeometryPolygon":O=O.concat(this._printData[na].featureCount,ja,this.nls.reportsTab.notApplicableText);break;case "esriGeometryPolyline":O=O.concat(this._printData[na].featureCount,this.nls.reportsTab.notApplicableText,ja)}}}}else{O=[ja.title];if(this._printData[na].isExceedingMaxRecordCount){var sa=!0;O[0]+=" *";ra=""}else ra=0===this._aoiGraphicsLayer.graphics.length?this.nls.reportsTab.notApplicableText:0;switch(this._printData[na].geometryType){case "esriGeometryPoint":O=O.concat(this._printData[na].featureCount,
this.nls.reportsTab.notApplicableText,this.nls.reportsTab.notApplicableText);break;case "esriGeometryPolygon":O=O.concat(this._printData[na].featureCount,ra,this.nls.reportsTab.notApplicableText);break;case "esriGeometryPolyline":O=O.concat(this._printData[na].featureCount,this.nls.reportsTab.notApplicableText,ra)}}O&&0<O.length&&t.data.rows.push(O)}if(sa){var na={title:"",type:"html",data:"\x3cdiv class\x3d'esriCTUnableToAnalyzeText'\x3e * "+this.nls.reportsTab.unableToAnalyzeText+"\x3c/div\x3e"};
k.splice(3,0,t,na)}else k.splice(3,0,t);return k},_initReportDijit:function(){if(this.config.reportSettings&&this.config.reportSettings.printTaskURL){var k=this.config.reportSettings.logo?ka.processUrlInWidgetConfig(this.config.reportSettings.logo,this.folderUrl):this.folderUrl+"/images/default-logo.png";var t=this.folderUrl+"/css/reportDijitOverrides.css";this.reportDijit=new x({reportLogo:k,appConfig:this.appConfig,footNotes:this.config.reportSettings.footnote,printTaskUrl:this.config.reportSettings.printTaskURL,
reportLayout:{pageSize:H.PageSizes.Letter,orientation:H.Orientation.Portrait},styleSheets:[t],styleText:this._getStyleTextForReport(),maxNoOfCols:5,Date:!0});this.own(a(this.reportDijit,"reportError",d.hitch(this,function(){this._showMessage(this.nls.reportsTab.errorInPrintingReport)})))}},_getStyleTextForReport:function(){return".esriCTTable th { background-color: "+this.config.reportSettings.columnTitleColor+"; color:"+this.getTextColor(this.config.reportSettings.columnTitleColor)+";} .esriCTNotesTitle { background-color: transparent;}"},
getTextColor:function(k){k=(new ba(k)).toRgb();return.5>1-(.299*k[0]+.587*k[1]+.114*k[2])/255?"#000":"#fff"},_createAndAddGraphicsLayer:function(){this._aoiGraphicsLayer=this._createNewGraphicsLayer("aoiGraphicsLayer");this._drawnOrSelectedGraphicsLayer=this._createNewGraphicsLayer("drawnOrSelectedGraphicsLayer");this._toleranceGraphicsLayer=this._createNewGraphicsLayer("toleranceGraphicsLayer");this._uploadedShapefileGraphicsLayer=this._createNewGraphicsLayer("uploadedShapefileGraphicsLayer");this._highlightGraphicsLayer=
this._createNewGraphicsLayer("highlightGraphicsLayer")},_createNewGraphicsLayer:function(k){var t={};k&&(this.map._layers[k]&&this.map.removeLayer(this.map._layers[k]),t={id:k+this.id});t=new Q(t);this.map.addLayer(t);return this.map.getLayer(k+this.id)},_displayConfiguredWidgetAOIButton:function(){var k=0;if(this.config.showPlacenameWidget){c.replace(this.placenameButton,"esriCTDisplayTableCell","esriCTHidden");var t="placename";k++;this._initializePlacenameWidget()}this.config.showDrawToolsWidget&&
(c.replace(this.drawToolsButton,"esriCTDisplayTableCell","esriCTHidden"),t||(t="drawTool"),k++,this._initializeDrawToolsWidget());this.config.showShapefileWidget&&(c.replace(this.shapefileButton,"esriCTDisplayTableCell","esriCTHidden"),t||(t="shapefile"),k++,this._initializeShapefileWidget());this.config.showCoordinatesWidget&&(c.replace(this.coordinatesButton,"esriCTDisplayTableCell","esriCTHidden"),t||(t="coordinates"),k++,this._initializeCoordinatesWidget());1===k&&c.add(this.aoiButtonParentContainer,
"esriCTHidden");this._showActiveToolPanel(t)},_initializePlacenameWidget:function(){this._placenameTool=new aa({nls:this.nls,config:this.config,map:this.map,appConfig:this.appConfig,widgetMainContainer:this.widgetMainContainer,aoiTabParentContainer:this.aoiTabParentContainer,isSingleTabSelected:this._isSingleTabSelected},B.create("div",{},this.placenameWidgetContainer));this.own(a(this._placenameTool,"onSearchComplete",d.hitch(this,this.onReceiveSearchData)));this._placenameTool.onWindowResize();
this.own(a(this._placenameTool,"focusLastSelectedTab",d.hitch(this,function(){this._focusLastSelectedTab()})))},_initializeDrawToolsWidget:function(){this._drawTool=new W({nls:this.nls,config:this.config,map:this.map,loadingIndicator:this._loadingIndicator,pointSymbol:F.fromJson(this.config.drawToolSymbology.point),polylineSymbol:F.fromJson(this.config.drawToolSymbology.polyline),polygonSymbol:F.fromJson(this.config.drawToolSymbology.polygon),_drawnOrSelectedGraphicsLayer:this._drawnOrSelectedGraphicsLayer,
filteredLayerObj:this._filteredLayerObj,layerInfoArray:this._layerInfoArray,layerInfosObj:this.layerInfosObj,isSingleTabSelected:this._isSingleTabSelected},B.create("div",{},this.drawToolWidgetContainer));this.own(a(this._drawTool,"onDrawComplete",d.hitch(this,function(k){this._initToCreateAOIBuffer(k)})));this.own(a(this._drawTool,"onSelectionComplete",d.hitch(this,function(k){var t;var O=k.filter(function(ha){return"polygon"===ha.geometry.type});if(0<O.length){(t=k.filter(function(ha){return"polygon"!==
ha.geometry.type}))||(t=[]);var X=[];r.forEach(O,d.hitch(this,function(ha){var ja=new J;ja.outFields=["*"];ja.returnGeometry=!0;ja.objectIds=[ha.attributes[ha.getLayer().objectIdField]];ja.outSpatialReference=this.map.spatialReference;ha=new P(ha.getLayer().url);X.push(ha.execute(ja))}));(new Z(X)).then(d.hitch(this,function(ha){r.forEach(ha,d.hitch(this,function(ja){t.push(ja[1].features[0])}));this._initToCreateAOIBuffer(t)}),d.hitch(this,function(){this.loadingIndicator.hide()}))}else this._initToCreateAOIBuffer(k)})));
this.own(a(this._drawTool,"clearExistingSelection",d.hitch(this,function(){this._clearAOI()})));this.own(a(this._drawTool,"focusLastSelectedTab",d.hitch(this,function(){this._focusLastSelectedTab()})))},_initializeShapefileWidget:function(){this._shapefileTool=new da({nls:this.nls,config:this.config,map:this.map,label:this.nls.shapefileWidget.shapefileLabel,loadingIndicator:this._loadingIndicator,isSingleTabSelected:this._isSingleTabSelected},B.create("div",{},this.shapefileWidgetContainer));this.own(a(this._shapefileTool,
"onShapefileUpload",d.hitch(this,function(k){k.graphics&&0<k.graphics.length?this._initToCreateAOIBuffer(k.graphics):this._showMessage(this.nls.noGraphicsShapefile)})));this.own(a(this._shapefileTool,"focusLastSelectedTab",d.hitch(this,function(){this._focusLastSelectedTab()})))},_getFormattedFieldObj:function(k){var t={};r.forEach(k,d.hitch(this,function(O){t[O.name]=O}));return t},_initShapeFileForAnalysis:function(){c.remove(this.uploadShapefileAnalysisTableContainer,"esriCTHidden");this._shapefileToolForAnalysis=
new da({nls:this.nls,config:this.config,map:this.map,label:this.nls.reportsTab.uploadShapefileForAnalysisText,loadingIndicator:this._loadingIndicator,isSingleTabSelected:!0},B.create("div",{},this.uploadShapefileAnalysisTableContainer));this.own(a(this._shapefileToolForAnalysis,"onShapefileUpload",d.hitch(this,function(k){if(k.graphics&&0<k.graphics.length){this._addUploadedShapefileGraphicsOnMap(k.graphics);this.map.setExtent(k.fullExtent);var t=this._getUnionGeometry(this._getOnlyPointGraphics());
var O=this._getUnionGeometry(this._toleranceGraphicsLayer.graphics);var X=this._getUnionGeometry(this._aoiGraphicsLayer.graphics);k.id="ShapeFile_"+Date.now();var ha=this.config.hasOwnProperty("groupbyfieldCheckBoxStatus")?this.config.groupbyfieldCheckBoxStatus:!0;ha=new V({id:k.id,nls:this.nls,isFeatureCollectionLayer:!0,config:this.config,appConfig:this.appConfig,map:this.map,featureLayer:k,aoiGraphicsLayer:this._aoiGraphicsLayer,configuredField:this._getFormattedFieldObj(k.fields),configuredLayerLabel:k.name,
maxFeaturesForAnalysis:this.config.maxFeaturesForAnalysis,layerInfosObj:this.layerInfosObj,highlightGraphicsLayer:this._highlightGraphicsLayer,retainSelectedFieldsArr:null,domNodeObj:this.domNode,groupbyfieldCheckBoxStatus:ha});B.place(ha.domNode,this.impactSummaryReportContainer,0);this.own(a(ha,"printDataUpdated",d.hitch(this,function(ja){this._printData[ja.id].info=ja.printData})));this.own(a(ha,"initializeAccessibility",d.hitch(this,function(){this._setAccessibility()})));ha.generateReport(X,
O,t).then(d.hitch(this,function(ja){var la={};la[ja.id]=d.hitch(ja.printInfo);this._printData=d.mixin(la,this._printData);this._downloadFeatureDetailsObj[ja.id]=ja.features;this._newShapeFileAnalysisArr||(this._newShapeFileAnalysisArr=[]);this._newShapeFileAnalysisArr.push({allowDownload:!0,downloadingFileOption:["csv"],id:k.id,layerName:k.name,url:null,isShapeFile:!0,layer:k});c.contains(this.printButton,"esriCTPrintBtnDisabled")&&0<ja.features.length&&(c.remove(this.printButton,"esriCTPrintBtnDisabled"),
this.printIconButton.set("disabled",!1))}))}else this._showMessage(this.nls.noGraphicsShapefile)})))},_initializeCoordinatesWidget:function(){this._coordinatesTool=new h({nls:this.nls,config:this.config,map:this.map,appConfig:this.appConfig,loadingIndicator:this._loadingIndicator,widgetMainContainer:this.widgetMainContainer,isSearchWidgetConfigured:this._isSearchWidgetConfigured,drawnOrSelectedGraphicsLayer:this._drawnOrSelectedGraphicsLayer,geometryService:this._geometryService,aoiGraphicsLayer:this._aoiGraphicsLayer,
uploadedShapefileGraphicsLayer:this._uploadedShapefileGraphicsLayer,bufferDistanceTextBox:this.bufferDistanceTextBox,isSingleTabSelected:this._isSingleTabSelected},B.create("div",{},this.coordinateWidgetContainer));this.own(a(this._coordinatesTool,"onSearchComplete",d.hitch(this,this.onReceiveSearchData)));this.own(a(this._coordinatesTool,"redrawAOI",d.hitch(this,this._validateAndAddAOI)));this.own(a(this._coordinatesTool,"enableClearAOIButton",d.hitch(this,this._enableClearAOIButton)));this.own(a(this._coordinatesTool,
"enableZoomIcon",d.hitch(this,this._enableZoomIcon)));this.own(a(this._coordinatesTool,"focusLastSelectedTab",d.hitch(this,function(){this._focusLastSelectedTab()})));this.own(a(this._coordinatesTool,"restrictFocusOnFirstNode",d.hitch(this,function(){this._allowFocusOnFirstNode=!1})))},_initToCreateAOIBuffer:function(k){this._aoiGraphicsLayer.clear();this._drawnOrSelectedGraphicsLayer.clear();this._toleranceGraphicsLayer.clear();this._uploadedShapefileGraphicsLayer.clear();this._highlightGraphicsLayer.clear();
(this._drawTool&&!this._drawTool.selectTool||this._drawTool&&!this._drawTool.selectTool.isActive())&&this._drawTool.clearAllSelections();this._coordinatesTool&&"coordinates"!==this._currentActiveTool&&this._coordinatesTool.resetCoordinatesWidgetValue();this._addDrawnOrSelectedGraphicsOnMap(k);this._validateAndAddAOI()||this._setExtentToGraphicsLayer(this._drawnOrSelectedGraphicsLayer,null,!1)},_getOnlyPointGraphics:function(){var k=[];this.config.searchTolerance||(k=[],r.forEach(this._toleranceGraphicsLayer.graphics,
d.hitch(this,function(t){t.geometry&&"point"===t.geometry.type&&k.push(t)})));return k},_createToleranceGraphic:function(k){this._toleranceGraphicsLayer.clear();if(this.config.searchTolerance){var t=new g;t.distances=[this.config.searchTolerance];t.outSpatialReference=this.map.spatialReference;t.unit=this._getBufferParameterUnit();t.geometries=k;this._loadingIndicator.show();setTimeout(d.hitch(this,function(){this._doBufferGeometry(t).then(d.hitch(this,function(O){O&&r.forEach(O,d.hitch(this,function(X){X&&
this._toleranceGraphicsLayer.add(new U(X))}));this._loadingIndicator.hide()}))}),50)}else r.forEach(k,d.hitch(this,function(O){O&&this._toleranceGraphicsLayer.add(new U(O))}))},_getBufferParameterUnit:function(){return"Feet"===this.config.lengthUnits||"Miles"===this.config.lengthUnits?G.UNIT_FOOT:G.UNIT_METER},_addDrawnOrSelectedGraphicsOnMap:function(k){r.forEach(k,d.hitch(this,function(t){if(t&&t.geometry&&t.geometry.type){var O=this._getSymbol(t.geometry.type);if(t=new U(t.geometry,O),O)this._drawnOrSelectedGraphicsLayer.add(t),
this._enableClearAOIButton(),this._setAccessibility();this._enableZoomIcon()}}))},_addUploadedShapefileGraphicsOnMap:function(k){r.forEach(k,d.hitch(this,function(t){if(t&&t.geometry&&t.geometry.type){var O=this._getSymbol(t.geometry.type);(t=new U(t.geometry,O),O)&&this._uploadedShapefileGraphicsLayer.add(t)}}))},_getSymbol:function(k){var t=this.config[this._currentActiveTool+"Symbology"];"extent"===k?k="polygon":"multipoint"===k&&(k="point");return F.fromJson(t[k])},_doBufferGeometry:function(k){var t=
new m;if(this.map.spatialReference.isWebMercator()||4326===this.map.spatialReference.wkid)try{var O=S.geodesicBuffer(k.geometries,k.distances,k.unit,!0);t.resolve(O)}catch(X){t.resolve(null)}else this._geometryService.buffer(k,d.hitch(this,function(X){t.resolve(X)}),d.hitch(this,function(){t.resolve(null)}));return t.promise},_setBufferInputs:function(){this.bufferDistanceTextBox.set("trim",!0);this.bufferDistanceTextBox.set("constraints",{min:0});this.bufferDistanceTextBox.set("value",this.config.defaultBufferDistance);
this._bufferValue=this.bufferDistanceTextBox.getValue();this.bufferDistanceUnit.set("value",this.config.defaultBufferUnit);this._attachBufferDistanceTextboxKeypressEvent();this.own(a(this.bufferDistanceTextBox,"change",d.hitch(this,this._validateBufferDistance)));this.own(a(this.bufferDistanceTextBox,"blur",d.hitch(this,function(){this._isKeyPressed?this._isKeyPressed=!1:(this._validateBufferDistance(this.bufferDistanceTextBox.getValue()),this._validateAndAddAOI())})));this.own(a(this.bufferDistanceUnit,
"change",d.hitch(this,function(){0<this.bufferDistanceTextBox.getValue()&&this._validateAndAddAOI();this._setFocusOnBufferUnitDropdown();this._setAriaLabelToBufferDistTextBox()})))},_validateBufferDistance:function(k){!isNaN(k)&&this.bufferDistanceTextBox.isValid()||this.bufferDistanceTextBox.set("value",0);this._setAriaLabelToBufferDistTextBox()},_initDownloadWidget:function(k){var t=!1;0===this._aoiGraphicsLayer.graphics.length&&0<this._toleranceGraphicsLayer.graphics.length&&(t=!0);0<this._aoiGraphicsLayer.graphics.length&&
0<this._toleranceGraphicsLayer.graphics.length&&0===this.bufferDistanceTextBox.get("value")&&(t=!0);var O=this._aoiGraphicsLayer.graphics;O=O.concat(this._toleranceGraphicsLayer.graphics);O=this._getUnionGeometry(O);O=new U(O);this.downloadWidgetInstance?(this.downloadWidgetInstance.position=k,this.downloadWidgetInstance.downloadFeatureDetailsObj=this._downloadFeatureDetailsObj,this.downloadWidgetInstance.checkFileForDownload(),this.downloadWidgetInstance.aoi=O,this.downloadWidgetInstance.isTooltipDialogOpened?
this.downloadWidgetInstance.closePopup():this.downloadWidgetInstance.openPopup(),this.downloadWidgetInstance.shapeFileLayerDetails=this._newShapeFileAnalysisArr,this.downloadWidgetInstance.isPointOrLineAOI=t,this.downloadWidgetInstance.printData=this._printData,this.downloadWidgetInstance.areaUnits=this.config.areaUnits,this.downloadWidgetInstance.lengthUnits=this.config.lengthUnits):(this.downloadWidgetInstance=new T({config:this.config,position:k,nls:this.nls,map:this.map,aoi:O,loadingIndicator:this._loadingIndicator,
downloadFeatureDetailsObj:this._downloadFeatureDetailsObj,filterLayerObj:this._filteredLayerObj,iframeNode:this.iframeContainer,isAndroidDevice:this.isAndroid(),shapeFileLayerDetails:this._newShapeFileAnalysisArr,isPointOrLineAOI:t,appConfig:this.appConfig,areaUnits:this.config.areaUnits,lengthUnits:this.config.lengthUnits}),this.own(a(this.downloadWidgetInstance,"showMessage",d.hitch(this,function(X){this._showMessage(X)}))),this.own(a(this.downloadWidgetInstance,"toggleReportTabButtons",d.hitch(this,
function(X){this._showMessage(X)}))),this.own(a(this.downloadWidgetInstance,"setFocusOnDownloadReportButton",d.hitch(this,function(){this._setFocusOnDownloadReportButton();this._isKeyPressedOnDownloadDialog=!0}))),this.downloadWidgetInstance.startup())},_attachBufferDistanceTextboxKeypressEvent:function(){this.own(a(this.bufferDistanceTextBox,"keypress",d.hitch(this,function(k){if(k.keyCode===I.ENTER||k.keyCode===I.SPACE)ea.stop(k),this._isKeyPressed=!0,this._allowFocusOnFirstNode=!1,this._validateAndAddAOI(),
this._setFocusOnBufferUnitDropdown();k.keyCode!==I.TAB||k.shiftKey||(this._isKeyPressed=!0,this._allowFocusOnFirstNode=!1,this._validateAndAddAOI(),this._setFocusOnBufferUnitDropdown());k.keyCode===I.TAB&&k.shiftKey&&(this._isKeyPressed=!0);k.keyCode===I.ESCAPE&&(this._isKeyPressed=!0,this._isSingleTabSelected||(ea.stop(k),this._focusLastSelectedTab()))})))},_validateAndAddAOI:function(){var k;var t=[];var O=[];(this._drawTool&&!this._drawTool.selectTool||this._drawTool&&!this._drawTool.selectTool.isActive())&&
this._drawTool.clearAllSelections();if(this._drawnOrSelectedGraphicsLayer&&this._drawnOrSelectedGraphicsLayer.graphics&&0<this._drawnOrSelectedGraphicsLayer.graphics.length){var X=this._drawnOrSelectedGraphicsLayer.graphics;this._loadingIndicator.show();for(k=0;k<X.length;k++)"point"!==X[k].geometry.type&&"polyline"!==X[k].geometry.type||O.push(X[k].geometry),"polygon"===X[k].geometry.type&&(X[k].geometry=S.simplify(X[k].geometry)),t.push(X[k].geometry);0<O.length&&this._createToleranceGraphic(O);
this.bufferDistanceTextBox.isValid()&&0!==Number(this.bufferDistanceTextBox.getValue())?this._drawAOIBuffer(t):this._drawAOIOnMap(t,!1);return!0}this._aoiGraphicsLayer.clear();this._disableShowReportsButton();this._setAccessibility();return!1},_drawAOIBuffer:function(k){var t=new g;t.distances=[this.bufferDistanceTextBox.getValue()];t.outSpatialReference=this.map.spatialReference;t.unit=G[this.bufferDistanceUnit.value];t.geometries=k;this._loadingIndicator.show();setTimeout(d.hitch(this,function(){this._doBufferGeometry(t).then(d.hitch(this,
function(O){O?this._drawAOIOnMap(O,!0):this._showMessage(this.nls.unableToDrawBuffer);this._loadingIndicator.hide()}),d.hitch(this,function(){this._loadingIndicator.hide();this._showMessage(this.nls.unableToDrawBuffer)}))}),50)},_clearAOI:function(){c.contains(this.clearAOIButton,"jimu-state-disabled")||(this._aoiGraphicsLayer.clear(),this._drawnOrSelectedGraphicsLayer.clear(),this._toleranceGraphicsLayer.clear(),this._uploadedShapefileGraphicsLayer.clear(),this._highlightGraphicsLayer.clear(),this._disableClearAOIButton(),
this._disableShowReportsButton(),this._setAccessibility(),this._disableZoomIcon(),this._newShapeFileAnalysisArr=null,this._clearSelection(),this._coordinatesTool&&this._coordinatesTool.resetCoordinatesWidgetValue(),this._resetWidgetParameters())},_resetWidgetParameters:function(){this.bufferDistanceTextBox.set("value",this.config.defaultBufferDistance);this.bufferDistanceUnit.set("value",this.config.defaultBufferUnit);this._placenameTool&&this._placenameTool.resetPlaceNameWidgetValues()},_drawAOIOnMap:function(k,
t){this._loadingIndicator.show();this._aoiGraphicsLayer.clear();r.forEach(k,d.hitch(this,function(O){"point"!==O.type&&"polyline"!==O.type&&(O=new U(O),t&&O.setSymbol(F.fromJson(this.config.aoiSymbol)),this._aoiGraphicsLayer.add(O))}));this._isReportGenerated=!1;0<this._aoiGraphicsLayer.graphics.length||0<this._drawnOrSelectedGraphicsLayer.graphics.length?(this._setExtentToGraphicsLayer(this._aoiGraphicsLayer,this._drawnOrSelectedGraphicsLayer,!1),this._enableShowReportsButton()):this._disableShowReportsButton();
this._setAccessibility();this._loadingIndicator.hide()},resize:function(){this._setMaxHeightOfImpactSummaryReportContainer();if(this._placenameTool)this._placenameTool.onWindowResize();if(this._coordinatesTool)this._coordinatesTool.onWindowResize();this._isKeyPressedOnDownloadDialog&&(this._isKeyPressedOnDownloadDialog=!1,setTimeout(d.hitch(this,function(){this._setFocusOnDownloadReportButton()}),500))},_showMessage:function(k,t){t?(this._alertMessageObj=new v({message:k}),this._alertMessageObj.message=
k,this._alertMessageObj.onClose=d.hitch(this,function(){this._setAccessibility()})):(new v({message:k})).message=k},_setExtentToGraphicsLayer:function(k,t,O){var X=[];0<k.graphics.length&&k.graphics[0].geometry&&(X=k.graphics);t&&0<t.graphics.length&&t.graphics[0].geometry&&(X=X.concat(t.graphics));0<X.length&&(0===this.bufferDistanceTextBox.get("value")?this.map.setExtent(l.graphicsExtent(X).expand(1.5)):O&&this.map.setExtent(l.graphicsExtent(X).expand(1.5)))},_disableClearAOIButton:function(){c.add(this.clearAOIButton,
"jimu-state-disabled");b.set(this.clearAOIButton,"tabindex","-1")},_enableClearAOIButton:function(){c.remove(this.clearAOIButton,"jimu-state-disabled");b.set(this.clearAOIButton,"tabindex","0")},_disableShowReportsButton:function(){c.add(this.showReportsButton,"jimu-state-disabled");b.set(this.showReportsButton,"tabindex","-1")},_enableShowReportsButton:function(){c.remove(this.showReportsButton,"jimu-state-disabled");b.set(this.showReportsButton,"tabindex","0")},_enableZoomIcon:function(){c.contains(this.zoomToNode,
"esriCTZoomToDisableIcon")&&(c.replace(this.zoomToNode,"esriCTZoomToIcon","esriCTZoomToDisableIcon"),c.add(this.zoomToNode,"esriCTCursorPointer"),b.set(this.zoomToNode,"tabindex","0"))},_disableZoomIcon:function(){c.contains(this.zoomToNode,"esriCTZoomToIcon")&&(c.replace(this.zoomToNode,"esriCTZoomToDisableIcon","esriCTZoomToIcon"),c.remove(this.zoomToNode,"esriCTCursorPointer"),b.set(this.zoomToNode,"tabindex","-1"))},_calculateSelectedUnitAOIArea:function(k,t,O,X){.01>k&&0!==k?k=" \x3c "+L.format(.01)+
" ":(k=u.honourPopupRounding(2,k),k=L.format(k));t="polygon"===t?this.nls.reportsTab.featureAreaText+" : "+k+" "+this._getAOIUnitForGeometry(X,t):this.nls.reportsTab.featureLengthText+" : "+k+" "+this._getAOIUnitForGeometry(X,t);b.set(O,"innerHTML",t);b.set(O,"aria-label",this.nls.reportsTab.featureAreaText+" "+k+" "+X)},_getAOIUnitForGeometry:function(k,t){switch(k){case "Feet":case "SquareFeet":var O="polygon"===t||"esriGeometryPolygon"===t?this.nls.units.feetAbbr+"\x26sup2":this.nls.units.feetAbbr;
break;case "Miles":case "Acres":O="polygon"===t||"esriGeometryPolygon"===t?this.nls.units.acresAbbr:this.nls.units.milesAbbr;break;case "Meters":case "SquareMeters":O="polygon"===t||"esriGeometryPolygon"===t?this.nls.units.metersAbbr+"\x26sup2":this.nls.units.metersAbbr;break;case "Kilometers":case "SquareKilometers":O="polygon"===t||"esriGeometryPolygon"===t?this.nls.units.kilometersAbbr+"\x26sup2":this.nls.units.kilometersAbbr;break;case "Hectares":O="polygon"===t||"esriGeometryPolygon"===t?this.nls.reportsTab.hectaresAbbr:
this.nls.units.kilometersAbbr;break;case "SquareMiles":O="polygon"===t||"esriGeometryPolygon"===t?this.nls.units.milesAbbr+"\x26sup2":this.nls.units.milesAbbr}return O},_displayConfiguredAOIArea:function(){c.contains(this.aoiFeetUnitAreaContainer,"esriCTHidden")||c.add(this.aoiFeetUnitAreaContainer,"esriCTHidden");c.contains(this.aoiMilesUnitAreaContainer,"esriCTHidden")||c.add(this.aoiMilesUnitAreaContainer,"esriCTHidden");c.contains(this.aoiMetersUnitAreaContainer,"esriCTHidden")||c.add(this.aoiMetersUnitAreaContainer,
"esriCTHidden");c.contains(this.aoiKilometersUnitAreaContainer,"esriCTHidden")||c.add(this.aoiKilometersUnitAreaContainer,"esriCTHidden");c.contains(this.aoiHectaresUnitAreaContainer,"esriCTHidden")||c.add(this.aoiHectaresUnitAreaContainer,"esriCTHidden");c.contains(this.aoiSquareMilesUnitAreaContainer,"esriCTHidden")||c.add(this.aoiSquareMilesUnitAreaContainer,"esriCTHidden");switch(this.config.areaUnits){case "SquareFeet":c.remove(this.aoiFeetUnitAreaContainer,"esriCTHidden");break;case "Acres":c.remove(this.aoiMilesUnitAreaContainer,
"esriCTHidden");break;case "SquareMeters":c.remove(this.aoiMetersUnitAreaContainer,"esriCTHidden");break;case "SquareKilometers":c.remove(this.aoiKilometersUnitAreaContainer,"esriCTHidden");break;case "Hectares":c.remove(this.aoiHectaresUnitAreaContainer,"esriCTHidden");break;case "SquareMiles":c.remove(this.aoiSquareMilesUnitAreaContainer,"esriCTHidden")}},_toggleReportTabButtons:function(k,t){k?(c.remove(this.downloadReportBtn,"esriCTDownloadBtnDisabled"),b.set(this.downloadReportBtn,"tabindex",
"0"),0<this.printOptions.length?(c.remove(this.printButton,"esriCTPrintBtnDisabled"),this.printIconButton.set("disabled",!1)):(c.add(this.printButton,"esriCTPrintBtnDisabled"),this.printIconButton.set("disabled",!0))):(c.add(this.downloadReportBtn,"esriCTDownloadBtnDisabled"),b.set(this.downloadReportBtn,"tabindex","-1"),c.add(this.printButton,"esriCTPrintBtnDisabled"),this.printIconButton.set("disabled",!0));!k&&t&&(c.remove(this.printButton,"esriCTPrintBtnDisabled"),this.printIconButton.set("disabled",
!1))},_getUnionGeometry:function(k){var t=[];return 0<k.length?(r.forEach(k,d.hitch(this,function(O){t.push(O.geometry)})),S.union(t)):null},_getAOIGeometriesInfo:function(){var k,t;var O=this._drawnOrSelectedGraphicsLayer.graphics.length;var X=k=t=0;if(0<this.bufferDistanceTextBox.get("value"))return"AOIGraphics";r.forEach(this._drawnOrSelectedGraphicsLayer.graphics,d.hitch(this,function(ha){"point"===ha.geometry.type?X++:"polyline"===ha.geometry.type?k++:t++}));return 0<X&&0<k&&"coordinates"===
this._currentActiveTool?"AllLines":X===O?"AllPoints":k===O?"AllLines":t===O?"AllPolygons":"Mixed"},_initializeImpactSummaryReportWidget:function(){var k,t;var O=[];this._isExceedingMaxRecordCount=!1;B.empty(this.impactSummaryReportContainer);this._downloadFeatureDetailsObj={};this._printData={};var X=this._getUnionGeometry(this._getOnlyPointGraphics());var ha=this._getUnionGeometry(this._toleranceGraphicsLayer.graphics);var ja=this._getUnionGeometry(this._aoiGraphicsLayer.graphics);for(k=0;k<this.config.layers.length;k++)if(t=
this._filteredLayerObj[this.config.layers[k].id]){var la=null;this._changedFieldsObj[t.id]&&(la=this._changedFieldsObj[t.id]);var ma=this.config.layers[k].hasOwnProperty("groupbyfieldCheckBoxStatus")?this.config.layers[k].groupbyfieldCheckBoxStatus:this.config.hasOwnProperty("groupbyfieldCheckBoxStatus")?this.config.groupbyfieldCheckBoxStatus:!0;t=new V({id:t.id+"_"+k+Date.now(),nls:this.nls,config:this.config,appConfig:this.appConfig,map:this.map,featureLayer:t,aoiGraphicsLayer:this._aoiGraphicsLayer,
configuredField:this.config.layers[k].selectedFields,configuredLayerLabel:this.config.layers[k].label,maxFeaturesForAnalysis:this.config.maxFeaturesForAnalysis,layerInfosObj:this.layerInfosObj,highlightGraphicsLayer:this._highlightGraphicsLayer,layerID:t.id,retainSelectedFieldsArr:la,domNodeObj:this.domNode,groupbyfieldCheckBoxStatus:ma},B.create("div",{},this.impactSummaryReportContainer));this._impactSummaryReportObjList.push(t);this.own(a(t,"printDataUpdated",d.hitch(this,function(pa){this._printData[pa.id].info=
pa.printData})));this.own(a(t,"showMessage",d.hitch(this,function(pa){this._showMessage(pa)})));this.own(a(t,"initializeAccessibility",d.hitch(this,function(){this._setAccessibility()})));this.own(a(t,"setLastFocusNode",d.hitch(this,function(){this._setLastFocusNode()})));this.own(a(t,"exceedingMaxRecordCount",d.hitch(this,this._displayExceedingFeatureCountError)));O.push(t.generateReport(ja,ha,X))}y(O).then(d.hitch(this,function(pa){var qa=!1;r.forEach(pa,d.hitch(this,function(ra){ra&&(this._downloadFeatureDetailsObj[ra.featureLayerId]=
ra.features,this._printData[ra.id]=d.hitch(ra.printInfo),0<ra.features.length&&!qa&&(qa=!0),this._isReportGenerated=!0)}));r.forEach(this._impactSummaryReportObjList,d.hitch(this,function(ra){ra.retainLastSelectedField()}));this._toggleReportTabButtons(qa,!0);this._setAccessibility();this._isExceedingMaxRecordCount&&""!==this._alertMessageObj&&null!==this._alertMessageObj&&void 0!==this._alertMessageObj&&(this._focusOutCurrentNode(),e.focus(this._alertMessageObj))}))},_displayExceedingFeatureCountError:function(){this._isExceedingMaxRecordCount||
(this._isExceedingMaxRecordCount=!0,this._showMessage(this.nls.reportsTab.intersectingFeatureExceedsMsgOnCompletion,!0))},isAndroid:function(){return-1<navigator.userAgent.toLowerCase().indexOf("android")},isIOS:function(){return!!navigator.platform.match(/iPhone|iPod|iPad/)},_filterLayersFromMap:function(){this._filteredLayerObj={};this._loadingIndicator.show();E.getInstance(this.map,this.map.itemInfo).then(d.hitch(this,function(k){this.layerInfosObj=k;R.getLayerInfoArray(k).then(d.hitch(this,function(t){this._layerInfoArray=
t;this._getLayerObjects(t).then(d.hitch(this,function(O){var X=[];r.forEach(O,function(ha){X.push(this._filterLayer(ha))},this);y(X).then(d.hitch(this,function(){this._initWidgetComponents()}))}))}))}))},_getLayerObjects:function(k){var t=new m;k=r.map(k,function(O){return O.getLayerObject()});y(k).then(function(O){t.resolve(O)});return t},_filterLayer:function(k){var t,O,X;var ha=new m;var ja=/(^.*?MapServer)/gi.exec(k.url);var la=!1;ja&&(t=ja[1]);var ma=this.map.webMapResponse.itemInfo.itemData.operationalLayers;
var pa=k.layerId;for(O=0;O<ma.length;O++)if("ArcGISMapServiceLayer"===ma[O].layerType&&t===ma[O].url&&ja){var qa=ma[O].layerObject.layerInfos;for(X=0;X<qa.length;X++)if(pa===qa[X].id){this._filteredLayerObj[k.id]=k;la=!0;ha.resolve();break}}else if("ArcGISFeatureLayer"===ma[O].layerType){this._filteredLayerObj[k.id]=k;la=!0;ha.resolve();break}la||ha.resolve();return ha.promise},_showPanel:function(k,t){n.set(this._panels[k],{display:"block",left:"-100%"});t?(this._slide(this._panels[k],-100,0),this._slide(this._currentPanel,
0,100)):(this._slide(this._currentPanel,0,-100),this._slide(this._panels[k],100,0));this._currentPanelName=k;this._currentPanel=this._panels[k]},_slide:function(k,t,O){n.set(k,"left",O);0===O?c.remove(k,"esriCTHidden"):c.add(k,"esriCTHidden");n.set(k,"left",t+"%");q.animateProperty({node:k,properties:{left:{start:t,end:O,units:"%"}},duration:300}).play()},_setUpPrintDialogPopup:function(){this.printButton=w(".esriCTPrintContainer",this.downloadAndPrintTableContainer)[0];this.printIconButton.set("disabled",
!0);c.add(this.printDialog.domNode,"esriCTPrintSettingsDialog "+this.baseClass);"DartTheme"===this.appConfig.theme.name&&c.add(this.printDialog.domNode,"dart-panel");this._loadLayoutOptions(this.printLayoutSelect);this.own(a(this.printActionButton,"click",d.hitch(this,function(k){ea.stop(k);this._onPrintActionButtonClick();this._focusOutCurrentNode();e.focus(this.printParentContainer)})));this.own(a(this.printActionButton,"keydown",d.hitch(this,function(k){if(k.keyCode===I.ENTER||k.keyCode===I.SPACE)ea.stop(k),
this._onPrintActionButtonClick(),this._focusOutCurrentNode(),e.focus(this.printIconButton.focusNode);k.keyCode===I.ESCAPE&&(ea.stop(k),this.closePrintDialog(),this._focusOutCurrentNode(),e.focus(this.printIconButton.focusNode))})))},_onPrintActionButtonClick:function(){if(this.reportDijit){var k=d.clone(this.printOptions[this.printLayoutSelect.get("value")]);k.hasOwnProperty("orientation")&&"Portrait"===k.orientation.Type?this.reportDijit.maxNoOfCols=5:this.reportDijit.maxNoOfCols=8;if(k.hasOwnProperty("SizeName")&&
k.hasOwnProperty("PageUnits")&&k.hasOwnProperty("pageSize"))switch(k.PageUnits){case "POINT":k.pageSize.Height=u.honourPopupRounding(2,.0138889*parseFloat(k.pageSize.Height));k.pageSize.Width=u.honourPopupRounding(2,.0138889*parseFloat(k.pageSize.Width));break;case "CENTIMETER":k.pageSize.Height=u.honourPopupRounding(2,.393701*parseFloat(k.pageSize.Height));k.pageSize.Width=u.honourPopupRounding(2,.393701*parseFloat(k.pageSize.Width));break;case "MILLIMETER":k.pageSize.Height=u.honourPopupRounding(2,
.0393701*parseFloat(k.pageSize.Height)),k.pageSize.Width=u.honourPopupRounding(2,.0393701*parseFloat(k.pageSize.Width))}this.reportDijit.setReportLayout(k);k=this._getProcessedPrintData();this.reportDijit.print(this.config.reportSettings.reportTitle,k)}else this._showMessage(this.nls.reportsTab.errorInPrintingReport);this.closePrintDialog()},closePrintDialog:function(){this.printDialog&&Y.close(this.printDialog)},_loadLayoutOptions:function(k){if(this.config.reportSettings.hasOwnProperty("customOptions")&&
this.config.reportSettings.hasOwnProperty("defaultPrintOption"))N({url:this.config.reportSettings.printTaskURL,content:{f:"json"},handleAs:"json",callbackParamName:"callback"}).then(d.hitch(this,function(ha){this._fetchChoiceList(ha,k)}),d.hitch(this,function(){this._showMessage(this.nls.reportsTab.errorInFetchingPrintTask);this.loadingIndicator.hide()}));else{var t,O=[],X=0;for(t in H.PageSizes)"MAP_ONLY"!==H.PageSizes[t].MapLayout&&"Custom"!==t&&(O.push({label:H.PageSizes[t].SizeName+" "+H.Orientation.Portrait.Text,
value:X++}),"Letter_ANSI_A"===t&&(O[X-1].selected=!0),this.printOptions.push({pageSize:H.PageSizes[t],orientation:H.Orientation.Portrait}),O.push({label:H.PageSizes[t].SizeName+" "+H.Orientation.Landscape.Text,value:X++}),this.printOptions.push({pageSize:H.PageSizes[t],orientation:H.Orientation.Landscape}));k.addOption(O);setTimeout(d.hitch(this,function(){this.openAtStartAysn=!0;this._setAccessibility()}),1500)}},_fetchChoiceList:function(k,t){r.forEach(k.parameters,d.hitch(this,function(O){"Layout_Template"===
O.name&&"Layout Template"===O.displayName&&(this._printServiceChoiceList=O.choiceList,this._addDefaultOptionsInWidgetDropdown(t))}))},_addDefaultOptionsInWidgetDropdown:function(k){var t,O,X;var ha=[];var ja=0;var la=X=!1;r.forEach(this._printServiceChoiceList,d.hitch(this,function(qa){var ra=d.clone(qa);"MAP_ONLY"!==ra&&this._defaultOptions[ra]&&(la=!0,t=this._defaultOptions[ra],qa===this.config.reportSettings.defaultPrintOption&&(X=!0),ha.push({label:H.PageSizes[t.SizeName].SizeName+" "+H.Orientation[t.Orientation].Text,
value:ja++,selected:X}),O=d.clone(H.PageSizes[t.SizeName]),t.Orientation===H.Orientation.Landscape.Type&&(qa=d.clone(O),O.Height=qa.Width,O.Width=qa.Height),this.printOptions.push({pageSize:O,orientation:H.Orientation[t.Orientation]}))}));r.forEach(this.config.reportSettings.customOptions,d.hitch(this,function(qa){qa.SizeName===this.config.reportSettings.defaultPrintOption&&(X=!0);ha.push({label:qa.SizeName,value:ja++,selected:X});this.printOptions.push({SizeName:qa.SizeName,pageSize:{Height:qa.Height,
Width:qa.Width,MapLayout:qa.SizeName},MapLayout:qa.SizeName,PageUnits:qa.PageUnits})}));if(!la){if(0<ha.length){k.addOption(ha);return}this._isMapOnlyOptionAvailable=!0;for(var ma in this._defaultOptions)if(this._defaultOptions.hasOwnProperty(ma)&&(O=d.clone(H.PageSizes[this._defaultOptions[ma].SizeName]))){ma===this.config.reportSettings.defaultPrintOption&&(X=!0);ha.push({label:ma,value:ja++,selected:X});if(this._defaultOptions[ma].Orientation===H.Orientation.Landscape.Type){var pa=d.clone(O);O.Height=
pa.Width;O.Width=pa.Height}this.printOptions.push({pageSize:O,orientation:H.Orientation[this._defaultOptions[ma].Orientation]})}}k.addOption(ha);setTimeout(d.hitch(this,function(){this.openAtStartAysn=!0;this._setAccessibility()}),1100)},_setAnalysisUnitDialogPopup:function(){c.add(this.analysisUnitDialog.domNode,"esriCTReportAnalysisUnitSettingsDialog "+this.baseClass);"LaunchpadTheme"===this.appConfig.theme.name&&this.analysisUnitDialog&&this.analysisUnitDialog.domNode&&this.analysisUnitDialog.domNode.children&&
this.analysisUnitDialog.domNode.children[0]&&c.add(this.analysisUnitDialog.domNode.children[0],"esriCTReportAnalysisUnitSettingsDialogLaunchpadTheme");"DartTheme"===this.appConfig.theme.name&&c.add(this.analysisUnitDialog.domNode,"dart-panel");this.analysisAreaUnitSelect.set("value",this.config.areaUnits);this.analysisLengthUnitSelect.set("value",this.config.lengthUnits);this.own(a(this.analysisUnitActionButton,"click",d.hitch(this,function(k){ea.stop(k);this._onAnalysisUnitActionButtonClick();this._focusOutCurrentNode();
e.focus(this.analysisUnitParentContainer)})));this.own(a(this.analysisUnitActionButton,"keydown",d.hitch(this,function(k){if(k.keyCode===I.ENTER||k.keyCode===I.SPACE)ea.stop(k),this._onAnalysisUnitActionButtonClick(),this._focusOutCurrentNode(),e.focus(this.analysisUnitButton.focusNode);k.keyCode===I.ESCAPE&&(ea.stop(k),this._focusOutCurrentNode(),e.focus(this.analysisUnitButton.focusNode))})))},_onAnalysisUnitActionButtonClick:function(){var k=this.analysisAreaUnitSelect.get("value");this.config.areaUnits!==
k&&(this.config.areaUnits=k,this.showAreaSelectedUnitReportData(k));k=this.analysisLengthUnitSelect.get("value");this.config.lengthUnits!==k&&(this.config.lengthUnits=k,this.showLengthSelectedUnitReportData(k));this._closeUnitSettingDialog()},_closeUnitSettingDialog:function(){this.analysisUnitDialog&&Y.close(this.analysisUnitDialog)},showAreaSelectedUnitReportData:function(k){var t=w(".esriCTInfoDataMeasurement",this.domNode);r.forEach(t,function(O){c.contains(O,"esriCTEsriGeometryPolygon")&&(c.contains(O,
"esriCTHidden")||c.add(O,"esriCTHidden"),c.contains(O,"esriCTFieldDistinct"+k+"UnitData")&&c.remove(O,"esriCTHidden"))});this._displayConfiguredAOIArea()},showLengthSelectedUnitReportData:function(k){var t=w(".esriCTInfoDataMeasurement",this.domNode);r.forEach(t,function(O){c.contains(O,"esriCTEsriGeometryPolyline")&&(c.contains(O,"esriCTHidden")||c.add(O,"esriCTHidden"),c.contains(O,"esriCTFieldDistinct"+k+"UnitData")&&c.remove(O,"esriCTHidden"))});this._displayConfiguredAOIArea()},onAppConfigChanged:function(k,
t,O){"styleChange"===t&&this._setTheme(O)},_updateNoDataString:function(){this.config.reportSettings.hasOwnProperty("noDataConfiguredText")&&(this.nls.reportsTab.noDataText=this.config.reportSettings.noDataConfiguredText);this.config.reportSettings.hasOwnProperty("naTextConfiguredValue")&&(this.nls.reportsTab.notApplicableText=this.config.reportSettings.naTextConfiguredValue)},_setAccessibility:function(){this._setFocus()},_setFocus:function(){this._setFirstFocusNode();this._setLastFocusNode();this._focusFirstNodeOfWidgetOrTab()},
_setFirstFocusNode:function(){c.contains(this.aoiLabelContainer,"esriCTHidden")?c.contains(this.reportLabelContainer,"esriCTHidden")?this.zoomToNode?ka.initFirstFocusNode(this.domNode,this.zoomToNode):c.contains(this.placenameWidgetContainer,"esriCTVisible")?this._placenameTool.setFirstFocusNode(this.domNode):c.contains(this.drawToolWidgetContainer,"esriCTVisible")?this._drawTool.setFirstFocusNode(this.domNode):c.contains(this.shapefileWidgetContainer,"esriCTVisible")?this._shapefileTool.setFirstFocusNode(this.domNode):
c.contains(this.coordinateWidgetContainer,"esriCTVisible")&&this._coordinatesTool.setFirstFocusNode(this.domNode):ka.initFirstFocusNode(this.domNode,this.reportLabelContainer):ka.initFirstFocusNode(this.domNode,this.aoiLabelContainer)},_setLastFocusNode:function(){if(c.contains(this._currentPanel,"esriCTAOITabParentContainer"))c.contains(this.clearAOIButton,"jimu-state-disabled")?c.contains(this.showReportsButton,"jimu-state-disabled")?ka.initLastFocusNode(this.domNode,this.bufferDistanceUnitDropdownContainer):
ka.initLastFocusNode(this.domNode,this.showReportsButton):ka.initLastFocusNode(this.domNode,this.clearAOIButton);else if(c.contains(this._currentPanel,"esriCTReportTabParentContainer"))if(this.config.allowShapefilesUpload&&""!==this._shapefileToolForAnalysis&&null!==this._shapefileToolForAnalysis&&void 0!==this._shapefileToolForAnalysis)this._shapefileToolForAnalysis.setLastFocusNode(this.domNode);else{var k=w(".esriCTImpactSummaryLayerContainer",this.domNode);if(""!==k&&null!==k&&void 0!==k&&0<k.length){k=
k[k.length-1];var t=w(".esriCTLayerPanelIcon",k);c.contains(t[0],"esriCTLayerPanelExpand")?c.contains(t[0],"esriCTGroupByFieldIcon")?ka.initLastFocusNode(this.domNode,t[0]):(k=w(".esriCTLayerTitleAndFieldParentContainer",k),ka.initLastFocusNode(this.domNode,k[0])):c.contains(t[0],"esriCTLayerPanelCollapse")&&(k=w(".esriCTImpactSummaryLayerDetailMainNode",k),ka.initLastFocusNode(this.domNode,k[k.length-1]))}}},_focusFirstNodeOfWidgetOrTab:function(){c.contains(this._currentPanel,"esriCTAOITabParentContainer")?
this._allowFocusOnFirstNode?c.contains(this.placenameWidgetContainer,"esriCTVisible")?ka.isAutoFocusFirstNodeWidget(this)&&this._placenameTool.focusFirstNodeOfSelectedTab():c.contains(this.drawToolWidgetContainer,"esriCTVisible")?ka.isAutoFocusFirstNodeWidget(this)&&this._drawTool.focusFirstNodeOfSelectedTab():c.contains(this.shapefileWidgetContainer,"esriCTVisible")?ka.isAutoFocusFirstNodeWidget(this)&&this._shapefileTool.focusFirstNodeOfSelectedTab():c.contains(this.coordinateWidgetContainer,"esriCTVisible")&&
ka.isAutoFocusFirstNodeWidget(this)&&this._coordinatesTool.focusFirstNodeOfSelectedTab():this._allowFocusOnFirstNode=!0:(this._focusOutCurrentNode(),e.focus(this.zoomToNode))},_focusLastSelectedTab:function(){var k=w(".esriCTAOIButtonSelected",this.domNode);k&&0<k.length&&(this._focusOutCurrentNode(),e.focus(k[0]))},_focusLastNodeOfWidget:function(){this._focusOutCurrentNode();e.focus(this.bufferDistanceUnitDropdownContainer)},_setFocusToNextAoiTab:function(k,t){var O,X,ha;var ja=Array.prototype.slice.call(this.aoiButtonParentContainer.children);
var la=k.currentTarget;r.forEach(ja,d.hitch(this,function(ma,pa){ma===la&&(O=pa);if(!c.contains(ma,"esriCTHidden")){if(""===X||null===X||void 0===X)X=pa;ha=pa}}));t&&(O===ha?(this._focusOutCurrentNode(),e.focus(this._getFirstFocusTab(ja))):(this._focusOutCurrentNode(),e.focus(this._getNextFocusTab(ja,O))));t||(O===X?(this._focusOutCurrentNode(),e.focus(this._getLastFocusTab(ja))):(this._focusOutCurrentNode(),e.focus(this._getPreviousFocusTab(ja,O))))},_navigateAoiTabs:function(k){if(k.keyCode===I.RIGHT_ARROW||
k.keyCode===I.UP_ARROW)ea.stop(k),this._setFocusToNextAoiTab(k,!0);if(k.keyCode===I.LEFT_ARROW||k.keyCode===I.DOWN_ARROW)ea.stop(k),this._setFocusToNextAoiTab(k,!1)},_onZoomButtonClick:function(){(0<this._aoiGraphicsLayer.graphics.length||0<this._drawnOrSelectedGraphicsLayer.graphics.length)&&this._setExtentToGraphicsLayer(this._aoiGraphicsLayer,this._drawnOrSelectedGraphicsLayer,!0)},_setFocusOnDownloadReportButton:function(){this._focusOutCurrentNode();e.focus(this.downloadReportBtn)},_onReportButtonClick:function(){c.contains(this.showReportsButton,
"jimu-state-disabled")||(c.add(this.aoiLabelContainer,"esriCTHidden"),c.remove(this.reportLabelContainer,"esriCTHidden"),this._showPanel("reportTabParentContainer"),this._onReportTabClick())},_setFocusOnBufferUnitDropdown:function(){setTimeout(d.hitch(this,function(){this._focusOutCurrentNode();e.focus(this.bufferDistanceUnit)}),50)},_focusOutCurrentNode:function(){e.curNode&&e.curNode.blur()},_deSelectAllTabs:function(){""!==this.placenameButton&&null!==this.placenameButton&&void 0!==this.placenameButton&&
b.set(this.placenameButton,"aria-selected","false");""!==this.drawToolsButton&&null!==this.drawToolsButton&&void 0!==this.drawToolsButton&&b.set(this.drawToolsButton,"aria-selected","false");""!==this.shapefileButton&&null!==this.shapefileButton&&void 0!==this.shapefileButton&&b.set(this.shapefileButton,"aria-selected","false");""!==this.coordinatesButton&&null!==this.coordinatesButton&&void 0!==this.coordinatesButton&&b.set(this.coordinatesButton,"aria-selected","false")},_getFirstFocusTab:function(k){var t;
r.some(k,d.hitch(this,function(O){if(!c.contains(O,"esriCTHidden"))return t=O,!0}));return t},_getLastFocusTab:function(k){var t;k=k.reverse();r.some(k,d.hitch(this,function(O){if(!c.contains(O,"esriCTHidden"))return t=O,!0}));return t},_getNextFocusTab:function(k,t){var O;r.some(k,d.hitch(this,function(X,ha){if(ha>t&&!c.contains(X,"esriCTHidden"))return O=X,!0}));return O},_getPreviousFocusTab:function(k,t){var O;r.forEach(k,d.hitch(this,function(X,ha){if(ha<t&&!c.contains(X,"esriCTHidden"))return O=
X,!0}));return O},_trackNumberOfConfiguredTabs:function(){var k=0;this.config.showPlacenameWidget&&k++;this.config.showDrawToolsWidget&&k++;this.config.showShapefileWidget&&k++;this.config.showCoordinatesWidget&&k++;1===k&&(this._isSingleTabSelected=!0)},_clearSelection:function(){this._drawTool&&this._drawTool.clearAllSelections(!0)},_hideZeroValueRows:function(k){var t=[],O=!0,X;return this.config.reportSettings.hasOwnProperty("hideZeroValueRow")&&this.config.reportSettings.hideZeroValueRow?(r.forEach(k,
d.hitch(this,function(ha){O=!0;r.forEach(ha,d.hitch(this,function(ja,la){X=ha.length-1;isNaN(ja)&&la!==X&&(O=!1);0<parseFloat(ja)&&la!==X&&(O=!1)}));!1===O&&t.push(ha)})),t):k},_hideNullValueRows:function(k){var t=[],O=!0,X;return this.config.reportSettings.hasOwnProperty("hideNullValueRow")&&this.config.reportSettings.hideNullValueRow?(r.forEach(k,d.hitch(this,function(ha){O=!0;r.forEach(ha,d.hitch(this,function(ja,la){X=ha.length-1;"null"!==ja&&la!==X&&(O=!1)}));!1===O&&t.push(ha)})),t):k},_hideNoDataValueRows:function(k){var t=
[],O=!0,X;return this.config.reportSettings.hasOwnProperty("hideNullValueRow")&&this.config.reportSettings.hideNullValueRow?(r.forEach(k,d.hitch(this,function(ha){O=!0;r.forEach(ha,d.hitch(this,function(ja,la){X=ha.length-1;ja!=="\x3ci\x3e"+this.nls.reportsTab.noDataText+"\x3c/i\x3e"&&la!==X&&(O=!1)}));!1===O&&t.push(ha)})),t):k},_hideZeroAndNullValueRows:function(k){var t=[],O=!1,X;return this.config.reportSettings.hasOwnProperty("hideZeroValueRow")&&this.config.reportSettings.hasOwnProperty("hideNullValueRow")&&
this.config.reportSettings.hideZeroValueRow&&this.config.reportSettings.hideNullValueRow?(r.forEach(k,d.hitch(this,function(ha){O=!1;r.forEach(ha,d.hitch(this,function(ja,la){O||(X=ha.length-1,"null"!==ja&&ja!=="\x3ci\x3e"+this.nls.reportsTab.noDataText+"\x3c/i\x3e"&&la!==X&&(O=!0),isNaN(ja)||la===X||(O=0<parseFloat(ja)?!0:!1))}));O&&t.push(ha)})),t):k}})});