@arcgis/core 4.32.0-next.20250105 → 4.32.0-next.20250106

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- function t(t,r){switch(r){case"primary":return"touch"===t.pointerType||0===t.button;case"secondary":return"touch"!==t.pointerType&&2===t.button;case"tertiary":return"touch"!==t.pointerType&&1===t.button}}function r(t,r){if("touch"===t.pointerType)return!1;switch(r){case"primary":return 0===t.button;case"secondary":return 2===t.button;case"tertiary":return 1===t.button}}export{r as eventMatchesMousePointerAction,t as eventMatchesPointerAction};
5
+ function r(r,e){switch(e){case"primary":return"touch"===r.pointerType||0===r.button;case"secondary":return"touch"!==r.pointerType&&2===r.button;case"tertiary":return"touch"!==r.pointerType&&1===r.button}}function e(e,t){return t.some((t=>r(e,t)))}function t(r,e){const{button:t,pointerType:n}=r;return"touch"!==n&&e.some((r=>"primary"===r&&0===t||"secondary"===r&&2===t||"tertiary"===r&&1===t))}function n(r,{dragPrimary:e,dragSecondary:t,dragTertiary:n}){return[{key:"primary",value:e},{key:"secondary",value:t},{key:"tertiary",value:n}].filter((e=>e.value===r)).map((r=>r.key))}export{t as eventMatchesMousePointerActions,r as eventMatchesPointerAction,e as eventMatchesPointerActions,n as getPointerActions};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{_ as o}from"../../chunks/tslib.es6.js";import{prefersReducedMotion as e}from"../../core/a11yUtils.js";import t from"../../core/Accessor.js";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as s}from"../../core/accessorSupport/decorators/subclass.js";import a from"./gamepad/GamepadSettings.js";let m=class extends t{constructor(o){super(o),this.browserTouchPanEnabled=!0,this.gamepad=new a,this.momentumEnabled=!0,this.mouseWheelZoomEnabled=!0}get effectiveMomentumEnabled(){return this.momentumEnabled&&!e()}};o([r({type:Boolean})],m.prototype,"browserTouchPanEnabled",void 0),o([r({type:a,nonNullable:!0})],m.prototype,"gamepad",void 0),o([r({type:Boolean})],m.prototype,"momentumEnabled",void 0),o([r({type:Boolean})],m.prototype,"mouseWheelZoomEnabled",void 0),m=o([s("esri.views.navigation.Navigation")],m);const p=m;export{p as default};
5
+ import{_ as o}from"../../chunks/tslib.es6.js";import{prefersReducedMotion as e}from"../../core/a11yUtils.js";import t from"../../core/Accessor.js";import{deprecatedProperty as r}from"../../core/deprecate.js";import a from"../../core/Logger.js";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as m}from"../../core/accessorSupport/decorators/subclass.js";import n from"./NavigationActionMap.js";import p from"./gamepad/GamepadSettings.js";let i=class extends t{constructor(o){super(o),this.actionMap=new n,this.browserTouchPanEnabled=!0,this.gamepad=new p,this.momentumEnabled=!0}get effectiveMomentumEnabled(){return this.momentumEnabled&&!e()}get mouseWheelZoomEnabled(){return"zoom"===this.actionMap.mouseWheel}set mouseWheelZoomEnabled(o){r(a.getLogger(this),"mouseWheelZoomEnabled",{replacement:"actionMap.mouseWheel",version:"4.32",warnOnce:!0}),this.actionMap.mouseWheel=o?"zoom":"none"}};o([s({type:n,nonNullable:!0})],i.prototype,"actionMap",void 0),o([s({type:Boolean})],i.prototype,"browserTouchPanEnabled",void 0),o([s({type:p,nonNullable:!0})],i.prototype,"gamepad",void 0),o([s({type:Boolean})],i.prototype,"momentumEnabled",void 0),o([s({type:Boolean})],i.prototype,"mouseWheelZoomEnabled",null),i=o([m("esri.views.navigation.Navigation")],i);const l=i;export{l as default};
@@ -0,0 +1,4 @@
1
+ import "../../interfaces";
2
+
3
+ import NavigationActionMap = __esri.NavigationActionMap;
4
+ export default NavigationActionMap;
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
+ */
5
+ import{_ as o}from"../../chunks/tslib.es6.js";import r from"../../core/Accessor.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as t}from"../../core/accessorSupport/decorators/subclass.js";const s=()=>e({type:["pan","rotate","zoom","none"],nonNullable:!0});let a=class extends r{constructor(o){super(o),this.dragPrimary="pan",this.dragSecondary="rotate",this.dragTertiary="zoom",this.mouseWheel="zoom"}};o([s()],a.prototype,"dragPrimary",void 0),o([s()],a.prototype,"dragSecondary",void 0),o([s()],a.prototype,"dragTertiary",void 0),o([e({type:["zoom","none"],nonNullable:!0})],a.prototype,"mouseWheel",void 0),a=o([t("esri.views.navigation.NavigationActionMap")],a);const p=a;export{p as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{_ as e}from"../../chunks/tslib.es6.js";import t from"../../Color.js";import{handlesGroup as r}from"../../core/handleUtils.js";import{memoize as i}from"../../core/memoize.js";import{watch as o,on as n}from"../../core/reactiveUtils.js";import{union as s}from"../../core/SetUtils.js";import{getMetersPerVerticalUnitForSR as l}from"../../core/unitUtils.js";import{property as c}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as a}from"../../core/accessorSupport/decorators/subclass.js";import{i as u}from"../../chunks/vec32.js";import{create as p}from"../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as d}from"../../geometry/ellipsoidUtils.js";import{create as m,fromPoints as v}from"../../geometry/support/ray.js";import{GeometryDescriptor as y}from"../../layers/support/ElevationQuery.js";import{externalToInternalIntersectOptions as f}from"../../views/3d/support/hitTest.js";import{newIntersector as h}from"../../views/3d/webgl-engine/lib/Intersector.js";import{StoreResults as w}from"../../views/3d/webgl-engine/lib/IntersectorInterfaces.js";import{toGraphic as _}from"../../views/3d/webgl-engine/lib/intersectorUtilsConversions.js";import g from"./ElevationProfileLine.js";const j=2e5;let I=class extends g{constructor(e){super(e),this.type="view",this.color=new t("#cf4ccf"),this.viewVisualizationEnabled=!0,this.include=null,this.exclude=null,this.numSamplesForPreview=50,this.numSamplesPerChunk=25,this._getQueryElevationDependencies=i(((e,t,r,i,o,n,s)=>({inputGraphicUid:null!=e?x(e):null,visibleLayers:t,maxIntersectionDistance:r,intersectOptions:i,view:o,stationary:n,spatialReference:s}))),this._vecA=p(),this._vecB=p(),this._ray=m()}get minDemResolution(){const e=this._viewModel?.view;if(null==e||"3d"!==e.type)return null;const t=e.pointsOfInterest?.focus?.worldUnitsPerContentPixel;return null==t?null:t*l(e.spatialReference)}get queryElevationDependencies(){const e=this._view;return e?this._getQueryElevationDependencies(this._viewModel?.input,this._visibleLayers,this._maxIntersectionDistance,this._intersectOptions,e,e.stationary,e.spatialReference):null}get _visibleLayers(){return this._view?.map?.allLayers?.filter((e=>e.visible)).toArray()??[]}get _intersectOptions(){const e=this._view;if(null==e||e.destroyed)return{};const t=f(e,{include:this.include,exclude:this.exclude}),r=f(e,{exclude:this._pointCloudLayers});return t.exclude=s(t.exclude,r.exclude),t}get _pointCloudLayers(){const e=this._view;return null==e?[]:e.allLayerViews.toArray().filter((e=>"point-cloud"===e.layer?.type)).map((e=>e.layer))}get _view(){const e=this._viewModel?.view;return null!=e&&"3d"===e.type?e:null}get _maxIntersectionDistance(){const e=this._view;return e?.renderCoordsHelper?d(e.spatialReference).radius/e.renderCoordsHelper.unitInMeters:Number.POSITIVE_INFINITY}get _intersector(){const e=this._view;if(null==e)return null;const t=h(e.state.viewingMode),r=t.options;return r.hud=!1,r.invisibleTerrain=!1,r.backfacesTerrain=!1,r.selectionMode=!1,r.store=w.ALL,t}async queryElevation(e,{noDataValue:t,signal:r}){const i=this.queryElevationDependencies;if(null==i)throw new Error("ElevationProfileLineInput: no dependencies");const o=this._intersector;if(null==o)throw new Error("ElevationProfileLineInput: no view");const{intersectOptions:n,view:s,spatialReference:l}=i,c=s.renderCoordsHelper,a=s.sceneIntersectionHelper,p=this._vecA,d=this._vecA,m=this._vecB,f=this._ray;if(!l)return{geometry:e,noDataValue:t};const h=await y.fromGeometry(e).project(l,r);if(!h)return{geometry:e,noDataValue:t};const w=h.coordinates,_=w.length;for(let y=0;y<_;++y){const e=w[y];u(m,e.x,e.y,e.z??0),c.toRenderCoords(m,l,m),c.setAltitude(p,j,m);const r=v(p,m,f);a.computeIntersection(r,o,n,!0);const s=b(i,o.results.all);s?(s.getIntersectionPoint(d),c.fromRenderCoords(d,d,l),e.z=d[2]):e.z=t}return{geometry:h.export(),noDataValue:t}}attach(e){const t=()=>this._onChange();return r([super.attach(e),o((()=>this.queryElevationDependencies),t),n((()=>e.elevationProvider),"elevation-change",t,{onListenerAdd:t,onListenerRemove:t})])}};function b({view:e,inputGraphicUid:t,maxIntersectionDistance:r},i){for(const o of i){if(null!=o.distanceInRenderSpace&&o.distanceInRenderSpace>r)continue;const i=_(o,e);if(null==i||x(i)!==t)return o}return null}function x(e){if(e.layer&&"objectIdField"in e.layer){const t=e.attributes[e.layer.objectIdField];if(t)return`o-${e.layer.id}-${t}`}return`u-${e.uid}`}e([c({type:t,nonNullable:!0})],I.prototype,"color",void 0),e([c()],I.prototype,"viewVisualizationEnabled",void 0),e([c()],I.prototype,"include",void 0),e([c()],I.prototype,"exclude",void 0),e([c({readOnly:!0})],I.prototype,"minDemResolution",null),e([c()],I.prototype,"queryElevationDependencies",null),e([c()],I.prototype,"_visibleLayers",null),e([c()],I.prototype,"_intersectOptions",null),e([c()],I.prototype,"_pointCloudLayers",null),e([c()],I.prototype,"_view",null),e([c()],I.prototype,"_maxIntersectionDistance",null),e([c()],I.prototype,"_intersector",null),I=e([a("esri.widgets.ElevationProfile.ElevationProfileLineView")],I);const L=I;export{L as default};
5
+ import{_ as e}from"../../chunks/tslib.es6.js";import t from"../../Color.js";import{handlesGroup as r}from"../../core/handleUtils.js";import{memoize as i}from"../../core/memoize.js";import{watch as o,on as n}from"../../core/reactiveUtils.js";import{union as s}from"../../core/SetUtils.js";import{getMetersPerVerticalUnitForSR as l}from"../../core/unitUtils.js";import{property as c}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as a}from"../../core/accessorSupport/decorators/subclass.js";import{i as u}from"../../chunks/vec32.js";import{create as p}from"../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as d}from"../../geometry/ellipsoidUtils.js";import{create as m,fromPoints as v}from"../../geometry/support/ray.js";import{GeometryDescriptor as y}from"../../layers/support/ElevationQuery.js";import{externalToInternalIntersectOptions as f}from"../../views/3d/support/hitTest.js";import{newIntersector as h}from"../../views/3d/webgl-engine/lib/Intersector.js";import{StoreResults as w}from"../../views/3d/webgl-engine/lib/IntersectorInterfaces.js";import{toGraphic as _}from"../../views/3d/webgl-engine/lib/intersectorUtilsConversions.js";import g from"./ElevationProfileLine.js";const j=2e5;let b=class extends g{constructor(e){super(e),this.type="view",this.color=new t("#cf4ccf"),this.viewVisualizationEnabled=!0,this.include=null,this.exclude=null,this.numSamplesForPreview=50,this.numSamplesPerChunk=25,this._getQueryElevationDependencies=i(((e,t,r,i,o,n,s)=>({inputGraphicUid:null!=e?x(e):null,visibleLayers:t,maxIntersectionDistance:r,intersectOptions:i,view:o,stationary:n,spatialReference:s}))),this._vecA=p(),this._vecB=p(),this._ray=m()}get minDemResolution(){const e=this._viewModel?.view;if(null==e||"3d"!==e.type)return null;const t=e.pointsOfInterest?.focus?.worldUnitsPerContentPixel;return null==t?null:t*l(e.spatialReference)}get queryElevationDependencies(){const e=this._view;return e?this._getQueryElevationDependencies(this._viewModel?.input,this._visibleLayers,this._maxIntersectionDistance,this._intersectOptions,e,e.stationary,e.spatialReference):null}get _visibleLayers(){return this._view?.map?.allLayers?.filter((e=>e.visible)).toArray()??[]}get _intersectOptions(){const e=this._view;if(null==e||e.destroyed)return{};const t=f(e,{include:this.include,exclude:this.exclude}),r=f(e,{exclude:this._pointCloudLayers});return t.exclude=s(t.exclude,r.exclude),t}get _pointCloudLayers(){const e=this._view;return null==e?[]:e.allLayerViews.toArray().filter((e=>"point-cloud"===e.layer?.type)).map((e=>e.layer))}get _view(){const e=this._viewModel?.view;return null!=e&&"3d"===e.type?e:null}get _maxIntersectionDistance(){const e=this._view;return e?.renderCoordsHelper?d(e.spatialReference).radius/e.renderCoordsHelper.unitInMeters:Number.POSITIVE_INFINITY}get _intersector(){const e=this._view;if(null==e)return null;const t=h(e.state.viewingMode),r=t.options;return r.hud=!1,r.invisibleTerrain=!1,r.backfacesTerrain=!1,r.selectionMode=!1,r.store=w.ALL,t}async queryElevation(e,{noDataValue:t,signal:r}){const i=this.queryElevationDependencies;if(null==i)throw new Error("ElevationProfileLineInput: no dependencies");const o=this._intersector;if(null==o)throw new Error("ElevationProfileLineInput: no view");const{intersectOptions:n,view:s,spatialReference:l}=i,c=s.renderCoordsHelper,a=s.sceneIntersectionHelper,p=this._vecA,d=this._vecA,m=this._vecB,f=this._ray;if(!l)return{geometry:e,noDataValue:t};const h=await y.fromGeometry(e).project(l,r);if(!h)return{geometry:e,noDataValue:t};const w=h.coordinates,_=w.length;for(let y=0;y<_;++y){const e=w[y];u(m,e.x,e.y,e.z??0),c.toRenderCoords(m,l,m),c.setAltitude(p,j,m);const r=v(p,m,f);a.computeIntersection(r,o,n,!0);const s=I(i,o.results.all);s?(s.getIntersectionPoint(d),c.fromRenderCoords(d,d,l),e.z=d[2]):e.z=t}return{geometry:h.export(),noDataValue:t}}attach(e){const t=()=>this._onChange();return r([super.attach(e),o((()=>this.queryElevationDependencies),t),n((()=>e.elevationProvider),"elevation-change",t,{onListenerAdd:t,onListenerRemove:t})])}};function I({view:e,inputGraphicUid:t,maxIntersectionDistance:r},i){for(const o of i){if(!o.withinDistance(r))continue;const i=_(o,e);if(null==i||x(i)!==t)return o}return null}function x(e){if(e.layer&&"objectIdField"in e.layer){const t=e.attributes[e.layer.objectIdField];if(t)return`o-${e.layer.id}-${t}`}return`u-${e.uid}`}e([c({type:t,nonNullable:!0})],b.prototype,"color",void 0),e([c()],b.prototype,"viewVisualizationEnabled",void 0),e([c()],b.prototype,"include",void 0),e([c()],b.prototype,"exclude",void 0),e([c({readOnly:!0})],b.prototype,"minDemResolution",null),e([c()],b.prototype,"queryElevationDependencies",null),e([c()],b.prototype,"_visibleLayers",null),e([c()],b.prototype,"_intersectOptions",null),e([c()],b.prototype,"_pointCloudLayers",null),e([c()],b.prototype,"_view",null),e([c()],b.prototype,"_maxIntersectionDistance",null),e([c()],b.prototype,"_intersector",null),b=e([a("esri.widgets.ElevationProfile.ElevationProfileLineView")],b);const L=b;export{L as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{_ as t}from"../../chunks/tslib.es6.js";import o from"../../core/Accessor.js";import{when as i}from"../../core/reactiveUtils.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as a}from"../../core/accessorSupport/decorators/subclass.js";let s=class extends o{constructor(t){super(t),this._navigationMode="pan",this.view=null}initialize(){this.addHandles(i((()=>this.view?.inputManager),(()=>this._setNavigationMode())))}destroy(){this.view=null}get state(){return this.view?.ready&&"3d"===this.view?.type?"ready":"disabled"}get navigationMode(){return this._navigationMode}set navigationMode(t){this._navigationMode=t,this._setNavigationMode()}toggle(){"disabled"!==this.state&&(this.navigationMode="pan"!==this.navigationMode?"pan":"rotate")}_setNavigationMode(){const t=this.view?.inputManager;t&&(t.primaryDragAction="pan"===this._navigationMode?"pan":"rotate")}};t([e({readOnly:!0})],s.prototype,"state",null),t([e()],s.prototype,"_navigationMode",void 0),t([e()],s.prototype,"view",void 0),s=t([a("esri.widgets.NavigationToggle.NavigationToggleViewModel")],s);const r=s;export{r as default};
5
+ import{_ as t}from"../../chunks/tslib.es6.js";import o from"../../core/Accessor.js";import{when as i}from"../../core/reactiveUtils.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as a}from"../../core/accessorSupport/decorators/subclass.js";let s=class extends o{constructor(t){super(t),this._navigationMode="pan",this.view=null}initialize(){this.addHandles(i((()=>this.view?.inputManager),(()=>this._setNavigationMode())))}destroy(){this.view=null}get state(){return this.view?.ready&&"3d"===this.view?.type?"ready":"disabled"}get navigationMode(){return this._navigationMode}set navigationMode(t){this._navigationMode=t,this._setNavigationMode()}toggle(){"disabled"!==this.state&&(this.navigationMode="pan"!==this.navigationMode?"pan":"rotate")}_setNavigationMode(){const t=this.view?.navigation.actionMap;if(!t)return;const o="pan"===this._navigationMode;t.dragPrimary=o?"pan":"rotate",t.dragSecondary=o?"rotate":"pan"}};t([e({readOnly:!0})],s.prototype,"state",null),t([e()],s.prototype,"_navigationMode",void 0),t([e()],s.prototype,"view",void 0),s=t([a("esri.widgets.NavigationToggle.NavigationToggleViewModel")],s);const r=s;export{r as default};