@arcgis/core 5.2.0-next.87 → 5.2.0-next.89
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.
- package/Graphic.js +1 -1
- package/arcade/Dictionary.js +1 -1
- package/arcade/Feature.js +1 -1
- package/arcade/ImmutablePointArray.js +1 -1
- package/arcade/Pixel.js +1 -1
- package/arcade/Voxel.js +1 -1
- package/arcade/arcadeAsyncRuntime.js +1 -1
- package/arcade/arcadeCompiler.js +1 -1
- package/arcade/arcadeRuntime.js +1 -1
- package/arcade/containerUtils.js +1 -1
- package/arcade/debug.js +1 -1
- package/arcade/deepClone.js +1 -1
- package/arcade/featureset/actions/SpatialFilter.js +1 -1
- package/arcade/featureset/support/FeatureSet.js +1 -1
- package/arcade/functions/centroid.js +1 -1
- package/arcade/functions/date.js +1 -1
- package/arcade/functions/feature.js +1 -1
- package/arcade/functions/featuresetbase.js +1 -1
- package/arcade/functions/featuresetgeom.js +1 -1
- package/arcade/functions/featuresetstats.js +1 -1
- package/arcade/functions/featuresetstring.js +1 -1
- package/arcade/functions/fieldStats.js +1 -1
- package/arcade/functions/geomasync.js +1 -1
- package/arcade/functions/geometry.js +1 -1
- package/arcade/functions/geomsync.js +1 -1
- package/arcade/functions/knowledgegraph.js +1 -1
- package/arcade/functions/maths.js +1 -1
- package/arcade/functions/stats.js +1 -1
- package/arcade/functions/string.js +1 -1
- package/arcade/functions/track.js +1 -1
- package/arcade/geometry/adapters/accessor.js +2 -0
- package/arcade/geometry/adapters/dehydrated.js +2 -0
- package/arcade/geometry/adapters/gx.js +2 -0
- package/arcade/geometry/adapters/json.js +2 -0
- package/arcade/geometry/adapters/optimized.js +2 -0
- package/arcade/geometry/adapters/tuple.js +2 -0
- package/arcade/geometry/adapters/utils.js +2 -0
- package/arcade/geometry/arrayOfPointsConversions.js +2 -0
- package/arcade/geometry/constructors.js +1 -1
- package/arcade/geometry/functions.js +1 -1
- package/arcade/geometry/isSelfIntersecting.js +2 -0
- package/arcade/geometry/nearestCoordinate.js +2 -0
- package/arcade/geometry/nearestVertex.js +1 -1
- package/arcade/geometry/operators.js +1 -1
- package/arcade/geometry/operatorsWorker.js +1 -1
- package/arcade/geometry/rotate.js +1 -1
- package/arcade/geometry.js +2 -0
- package/arcade/languageUtils.js +1 -1
- package/arcade.js +1 -1
- package/arcgisGlobal.d.ts +1 -0
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{0b8c9657975388f1e4c8.js → 00181785a180e934bf7c.js} +1 -1
- package/assets/esri/core/workers/chunks/{01e648b258efa6408070.js → 0336f4f8498a22347720.js} +1 -1
- package/assets/esri/core/workers/chunks/05393b23ab24126d4236.js +1 -0
- package/assets/esri/core/workers/chunks/07613ecf13c38ad58b79.js +1 -0
- package/assets/esri/core/workers/chunks/08263c07d92c48806834.js +1 -0
- package/assets/esri/core/workers/chunks/090ea7a131f8f60203ed.js +1 -0
- package/assets/esri/core/workers/chunks/09e01fd1c199be0c8e03.js +1 -0
- package/assets/esri/core/workers/chunks/{12d6d73ca1fa55640a4f.js → 0b4a7209b99227a842ad.js} +1 -1
- package/assets/esri/core/workers/chunks/0d95f72e1c07ab867d21.js +1 -0
- package/assets/esri/core/workers/chunks/0dbbac7a2378728571a7.js +1 -0
- package/assets/esri/core/workers/chunks/0f15468ffefd3e9a17b8.js +29 -0
- package/assets/esri/core/workers/chunks/13e92f6a9573a2818fb7.js +1 -0
- package/assets/esri/core/workers/chunks/159b16f47665f94a0305.js +1 -0
- package/assets/esri/core/workers/chunks/15f4f7e34e14e3cf52e6.js +1 -0
- package/assets/esri/core/workers/chunks/19e93d4d37018e3ee849.js +1 -0
- package/assets/esri/core/workers/chunks/{911f3a1b8dd4bc5c9782.js → 1bf5c0a4bc5a960a3fa2.js} +1 -1
- package/assets/esri/core/workers/chunks/1bf967c68d0c795d3fb4.js +1 -0
- package/assets/esri/core/workers/chunks/1c378d489c5402888f76.js +1 -0
- package/assets/esri/core/workers/chunks/1d1e8d8b1fcf2d9f3dfc.js +1 -0
- package/assets/esri/core/workers/chunks/{e5c8f9fef88ca33624e9.js → 1e087fb13b7b0a5d6fec.js} +1 -1
- package/assets/esri/core/workers/chunks/1e192ac0533a5c0b5a7a.js +1 -0
- package/assets/esri/core/workers/chunks/1f9d6180a96d557838e9.js +1 -0
- package/assets/esri/core/workers/chunks/1fe077f57a087c0e9119.js +1 -0
- package/assets/esri/core/workers/chunks/20f6e681ccd8bf884b77.js +1 -0
- package/assets/esri/core/workers/chunks/212222b64039d436b9a6.js +1 -0
- package/assets/esri/core/workers/chunks/22c94f9a69b2157f8dbd.js +1 -0
- package/assets/esri/core/workers/chunks/23addf8b11938e0c96e9.js +1 -0
- package/assets/esri/core/workers/chunks/25a2e02677a74834c8b5.js +1 -0
- package/assets/esri/core/workers/chunks/26ecc841396e5e719b6a.js +1 -0
- package/assets/esri/core/workers/chunks/27c0bed59626c7f64125.js +1 -0
- package/assets/esri/core/workers/chunks/2bc3e7f394386fa75447.js +1 -0
- package/assets/esri/core/workers/chunks/2c9783e3b44986e86797.js +1 -0
- package/assets/esri/core/workers/chunks/2ceb07b125c84b51f02a.js +1 -0
- package/assets/esri/core/workers/chunks/2cf2f2842c19be84ab4d.js +1 -0
- package/assets/esri/core/workers/chunks/2d07d5a9ec67c39ef10c.js +1 -0
- package/assets/esri/core/workers/chunks/{a7c715648a07ed70b122.js → 2ec44ebc48beeba11201.js} +1 -1
- package/assets/esri/core/workers/chunks/2f2d699b072472fa710e.js +1 -0
- package/assets/esri/core/workers/chunks/2f3bbc1f7d4abbbeec2f.js +1 -0
- package/assets/esri/core/workers/chunks/30af0f7c4cfa541c9efd.js +1 -0
- package/assets/esri/core/workers/chunks/30d816bdeea00f6fa1ca.js +1 -0
- package/assets/esri/core/workers/chunks/{39c0a3eb6a870953d530.js → 31a0620a6028e94c7532.js} +3 -3
- package/assets/esri/core/workers/chunks/32f11b4aeae1ef00e466.js +1 -0
- package/assets/esri/core/workers/chunks/37adb55d9f83faad1712.js +1 -0
- package/assets/esri/core/workers/chunks/3869dca884d7ca6488f5.js +1 -0
- package/assets/esri/core/workers/chunks/39b6a5222f45cb8dbc94.js +1 -0
- package/assets/esri/core/workers/chunks/3a9c6f58a1a065c14017.js +1 -0
- package/assets/esri/core/workers/chunks/3aceedec9abfb2fdfa18.js +1 -0
- package/assets/esri/core/workers/chunks/3b552afffaa78bf4fe18.js +1 -0
- package/assets/esri/core/workers/chunks/{fe06cc2f90b2d551e4c1.js → 3bbd2d4a19c3b7ad82e4.js} +1 -1
- package/assets/esri/core/workers/chunks/3de07326da4c47cd2aab.js +1 -0
- package/assets/esri/core/workers/chunks/3f5234120d3a14186c1c.js +1 -0
- package/assets/esri/core/workers/chunks/3f82410d9f701e7ad8eb.js +1 -0
- package/assets/esri/core/workers/chunks/{dbd6bbd3e834ff9d220e.js → 41cf6163758d28fb1968.js} +1 -1
- package/assets/esri/core/workers/chunks/45858d1c6487f4a98e40.js +1 -0
- package/assets/esri/core/workers/chunks/45c1c90ac6c14657f3ff.js +1 -0
- package/assets/esri/core/workers/chunks/46f8c7ae7fb356c3410d.js +1 -0
- package/assets/esri/core/workers/chunks/486f1a3b7269ce6c3911.js +1 -0
- package/assets/esri/core/workers/chunks/497c5a9c95e9a89ac217.js +1 -0
- package/assets/esri/core/workers/chunks/49d36e54644dc2966128.js +1 -0
- package/assets/esri/core/workers/chunks/4aefe6fd4d725a107758.js +1 -0
- package/assets/esri/core/workers/chunks/4b6f433022a6822706cb.js +1 -0
- package/assets/esri/core/workers/chunks/4c7264e3f4156f92d613.js +1 -0
- package/assets/esri/core/workers/chunks/4ee99e654dad6f09abee.js +1 -0
- package/assets/esri/core/workers/chunks/50525b617ef78086d3c7.js +1 -0
- package/assets/esri/core/workers/chunks/{a7727a2377470d586ff9.js → 51c9bd7c03d780fadebc.js} +1 -1
- package/assets/esri/core/workers/chunks/5235b9c21ac4156c2375.js +1 -0
- package/assets/esri/core/workers/chunks/52422500ca3d6cf2e596.js +1 -0
- package/assets/esri/core/workers/chunks/527b87fddf33bb5d519e.js +1 -0
- package/assets/esri/core/workers/chunks/{a4bae2396fae48b57047.js → 595edbc1e9bba47d5676.js} +1 -1
- package/assets/esri/core/workers/chunks/5af16937904c06fb06f6.js +1 -0
- package/assets/esri/core/workers/chunks/5bf65dbfd9c7a5ea187d.js +1 -0
- package/assets/esri/core/workers/chunks/5d7a5aa608ed6192b016.js +1 -0
- package/assets/esri/core/workers/chunks/5d9c92c4e60a4696fdad.js +1 -0
- package/assets/esri/core/workers/chunks/5ed7bc9e6cb7cdee92e2.js +1 -0
- package/assets/esri/core/workers/chunks/{272c8ccdbd3dcc14e99b.js → 5ed89c862eee1345e3af.js} +1 -1
- package/assets/esri/core/workers/chunks/5fbd7d8d8896a224fff3.js +1 -0
- package/assets/esri/core/workers/chunks/607acd9f615f87e14075.js +1 -0
- package/assets/esri/core/workers/chunks/62ee6c247f783acabb74.js +1 -0
- package/assets/esri/core/workers/chunks/64ce2d060ae7cdd412cf.js +1 -0
- package/assets/esri/core/workers/chunks/65f4ca7201e7267bfc81.js +1 -0
- package/assets/esri/core/workers/chunks/67efdd296007a809586c.js +1 -0
- package/assets/esri/core/workers/chunks/680557b8832fbdab7f46.js +1 -0
- package/assets/esri/core/workers/chunks/691434d4c6a38e63d819.js +1 -0
- package/assets/esri/core/workers/chunks/{ba67aaa08e4f11e1140a.js → 696cb3bf167327d5b0b9.js} +1 -1
- package/assets/esri/core/workers/chunks/69700ed16727ed0c4e3a.js +1 -0
- package/assets/esri/core/workers/chunks/6a2d890640b2cd6c5ccb.js +1 -0
- package/assets/esri/core/workers/chunks/6b84982dfaf084a61b93.js +1 -0
- package/assets/esri/core/workers/chunks/{7343a44a2382a1d68497.js → 6b9dbf43c0659e55c539.js} +1 -1
- package/assets/esri/core/workers/chunks/6de5c6af62776e1b9776.js +1 -0
- package/assets/esri/core/workers/chunks/71308dca3fd05687e7bd.js +1 -0
- package/assets/esri/core/workers/chunks/75bddfe2be64379db8fd.js +1 -0
- package/assets/esri/core/workers/chunks/777f2fdf1f4b9f243893.js +1 -0
- package/assets/esri/core/workers/chunks/78085f804969c9282700.js +1 -0
- package/assets/esri/core/workers/chunks/7aa9b61ca9b66f30449f.js +1 -0
- package/assets/esri/core/workers/chunks/7c56446184abcd14678b.js +1 -0
- package/assets/esri/core/workers/chunks/7e41cee4a0ae75e1490d.js +1 -0
- package/assets/esri/core/workers/chunks/7f55a150e4da02786311.js +1 -0
- package/assets/esri/core/workers/chunks/847b02d188ece9b563ad.js +1 -0
- package/assets/esri/core/workers/chunks/86c3d3c7015f1cd55fac.js +1 -0
- package/assets/esri/core/workers/chunks/87e0ceb1a64ab08e679a.js +1 -0
- package/assets/esri/core/workers/chunks/903c7bd079888f65fef1.js +1 -0
- package/assets/esri/core/workers/chunks/9226205850e35b7fc610.js +1 -0
- package/assets/esri/core/workers/chunks/94453d075ce02eff4844.js +1 -0
- package/assets/esri/core/workers/chunks/9474c913e53f69679197.js +1 -0
- package/assets/esri/core/workers/chunks/94ddfe165ac25aef8229.js +1 -0
- package/assets/esri/core/workers/chunks/{75a2c43311f5f9058f62.js → 94f62ff81cc6fb83e73f.js} +1 -1
- package/assets/esri/core/workers/chunks/95ccac3734ac70387b03.js +1 -0
- package/assets/esri/core/workers/chunks/97c7dfd29ad4c2966cb4.js +1 -0
- package/assets/esri/core/workers/chunks/{1354b8442c2c501238f1.js → 986c5024f22bbfc49aba.js} +1 -1
- package/assets/esri/core/workers/chunks/9b81bd62a2c72f592db1.js +1 -0
- package/assets/esri/core/workers/chunks/{62596065747abce1964d.js → 9b8e33985310f281f084.js} +1 -1
- package/assets/esri/core/workers/chunks/9e2b3754a76e0dd4a94a.js +1 -0
- package/assets/esri/core/workers/chunks/a03e7333e3328036f478.js +1 -0
- package/assets/esri/core/workers/chunks/a0565137027c83108953.js +1 -0
- package/assets/esri/core/workers/chunks/a176727a1148ca4fb432.js +1 -0
- package/assets/esri/core/workers/chunks/a3b403f8acb90af19adb.js +1 -0
- package/assets/esri/core/workers/chunks/a4596f028758649da099.js +1 -0
- package/assets/esri/core/workers/chunks/a46ac0be9aabc4cfedc7.js +1 -0
- package/assets/esri/core/workers/chunks/a4a22149077c7780481c.js +1 -0
- package/assets/esri/core/workers/chunks/a6ab627e965fe7e5bd52.js +1 -0
- package/assets/esri/core/workers/chunks/a6d4132a16c51323a38a.js +1 -0
- package/assets/esri/core/workers/chunks/a7954ad55a241af9064f.js +1 -0
- package/assets/esri/core/workers/chunks/a7e6382ecc91c876117f.js +1 -0
- package/assets/esri/core/workers/chunks/a88bf8ae93077e1b48cf.js +1 -0
- package/assets/esri/core/workers/chunks/a8b878c12cb1a6ea012b.js +1 -0
- package/assets/esri/core/workers/chunks/{ec0803cfa5051c4d300d.js → aa0ef4493a7e9bed159f.js} +1 -1
- package/assets/esri/core/workers/chunks/aa8ab28e0c1ae3b55ac0.js +1 -0
- package/assets/esri/core/workers/chunks/add834f867900a7091d2.js +1 -0
- package/assets/esri/core/workers/chunks/{bbf4c2ee4d56bb0f1a81.js → afa6b74d9ca9ed0154af.js} +1 -1
- package/assets/esri/core/workers/chunks/b0e25ccb5a1e57a82628.js +1 -0
- package/assets/esri/core/workers/chunks/b17a9853250ab626d58d.js +1 -0
- package/assets/esri/core/workers/chunks/b19cff0e43fab2632660.js +1 -0
- package/assets/esri/core/workers/chunks/b2e2234fdf8e05bc3312.js +1 -0
- package/assets/esri/core/workers/chunks/b6063d1755def00d4889.js +1 -0
- package/assets/esri/core/workers/chunks/bb56ab53c5a10c9518a6.js +1 -0
- package/assets/esri/core/workers/chunks/bd1a7e95a797e1ed4a7b.js +1 -0
- package/assets/esri/core/workers/chunks/bd2602195e265f8fdb15.js +1 -0
- package/assets/esri/core/workers/chunks/bdfffa5f88b559a4b42d.js +1 -0
- package/assets/esri/core/workers/chunks/{f762f0f6c83748d8e328.js → bee411f08e2a9499f8f5.js} +1 -1
- package/assets/esri/core/workers/chunks/bf11319138facf44752c.js +1 -0
- package/assets/esri/core/workers/chunks/bf357afbabaa8dec4d75.js +1 -0
- package/assets/esri/core/workers/chunks/bf7875fda48b15271a10.js +1 -0
- package/assets/esri/core/workers/chunks/bfa59005a9b191d18546.js +1 -0
- package/assets/esri/core/workers/chunks/bfb8fc6b940bd5510e29.js +1 -0
- package/assets/esri/core/workers/chunks/{b311658b8a223efe35d6.js → c0e073a77484b0dfd383.js} +1 -1
- package/assets/esri/core/workers/chunks/c13aa45ccd5efb662f88.js +1 -0
- package/assets/esri/core/workers/chunks/c176df477bbbbc9c6922.js +1 -0
- package/assets/esri/core/workers/chunks/{073224c6ac77dc9e97af.js → c23943e51734254d31e8.js} +1 -1
- package/assets/esri/core/workers/chunks/c35553d07ad169910742.js +1 -0
- package/assets/esri/core/workers/chunks/c4fef90cf08bbe4f0bb5.js +1 -0
- package/assets/esri/core/workers/chunks/c5c2fed38e0ccf84f1fa.js +1 -0
- package/assets/esri/core/workers/chunks/c80277a313205853a857.js +1 -0
- package/assets/esri/core/workers/chunks/c88bfa51d2a8a024fc24.js +1 -0
- package/assets/esri/core/workers/chunks/c91042f8bf886056a29c.js +1 -0
- package/assets/esri/core/workers/chunks/ca204c110438f7315790.js +1 -0
- package/assets/esri/core/workers/chunks/ca36d85a47179d95f2fc.js +1 -0
- package/assets/esri/core/workers/chunks/cb6fb04fe5c8d90d4196.js +1 -0
- package/assets/esri/core/workers/chunks/ccaeabc3be07f3c96f50.js +1 -0
- package/assets/esri/core/workers/chunks/{85f459297b0214141d43.js → cd02a6078443b8f63927.js} +1 -1
- package/assets/esri/core/workers/chunks/{3a36c132ceddef3d15c8.js → cdbcc4cd9145dd93db49.js} +1 -1
- package/assets/esri/core/workers/chunks/{e90feee1756a2209f93f.js → ce9fe1a89b474f9e7ee7.js} +1 -1
- package/assets/esri/core/workers/chunks/d0cf9ff48f051adbd455.js +1 -0
- package/assets/esri/core/workers/chunks/d119671a32a050517cca.js +1 -0
- package/assets/esri/core/workers/chunks/d26be8313526ecea9c68.js +1 -0
- package/assets/esri/core/workers/chunks/d270b49c037085503016.js +1 -0
- package/assets/esri/core/workers/chunks/{f5eee6e548bb24b5a003.js → d30a7fc8dab4ebb8893b.js} +1 -1
- package/assets/esri/core/workers/chunks/d344c3fd9f6b113bbcd7.js +1 -0
- package/assets/esri/core/workers/chunks/d36bbda9b7261534568f.js +1 -0
- package/assets/esri/core/workers/chunks/d4b0012ae1d3b8a9ba01.js +1 -0
- package/assets/esri/core/workers/chunks/d58d6b55b2749a535eb3.js +1 -0
- package/assets/esri/core/workers/chunks/d6f7aa280f1bd201d4ef.js +1 -0
- package/assets/esri/core/workers/chunks/{60f490afdbe299f89669.js → d871572997600930e017.js} +1 -1
- package/assets/esri/core/workers/chunks/da9aacdb0b4a04f42fb8.js +1 -0
- package/assets/esri/core/workers/chunks/daf7b647bd960d8bad56.js +1 -0
- package/assets/esri/core/workers/chunks/{10ac92dcd3738ec23dfb.js → db04c1bad40d068306ba.js} +1 -1
- package/assets/esri/core/workers/chunks/{3427f0c026301bcf7272.js → db180f8d25471cfa48af.js} +1 -1
- package/assets/esri/core/workers/chunks/ddf284648a73b6993737.js +1 -0
- package/assets/esri/core/workers/chunks/dfbe0efe453587ec5eb2.js +1 -0
- package/assets/esri/core/workers/chunks/e1682e94cc714197ebb4.js +1 -0
- package/assets/esri/core/workers/chunks/e2576c37cf13dc421f69.js +1 -0
- package/assets/esri/core/workers/chunks/e370a3337b3c90240e73.js +1 -0
- package/assets/esri/core/workers/chunks/e39bccc000c768120a32.js +1 -0
- package/assets/esri/core/workers/chunks/e40e08029325f43452d0.js +1 -0
- package/assets/esri/core/workers/chunks/e50adcfb392adfb3f79c.js +1 -0
- package/assets/esri/core/workers/chunks/{0d7d54e74b5639a0be6e.js → e707534a700a2de687ca.js} +1 -1
- package/assets/esri/core/workers/chunks/e823c9ccb7bc348d8824.js +1 -0
- package/assets/esri/core/workers/chunks/e88eee4c2fc4229c2a8b.js +1 -0
- package/assets/esri/core/workers/chunks/e9f29019aa78f07ace66.js +1 -0
- package/assets/esri/core/workers/chunks/ea75c23c44452f45a949.js +1 -0
- package/assets/esri/core/workers/chunks/ea91c57a0b31f3f65ee5.js +1 -0
- package/assets/esri/core/workers/chunks/eda04911553cf99fb99b.js +1 -0
- package/assets/esri/core/workers/chunks/ee77999df3785468b2b6.js +1 -0
- package/assets/esri/core/workers/chunks/ef851a2cff76fd211c07.js +1 -0
- package/assets/esri/core/workers/chunks/f106cc7f559856f69b9f.js +1 -0
- package/assets/esri/core/workers/chunks/f247f3c5148fa0237a7c.js +1 -0
- package/assets/esri/core/workers/chunks/{a26dc2647a15b830390e.js → f253875feb11883deb84.js} +1 -1
- package/assets/esri/core/workers/chunks/f3716ce04d09af31cfb1.js +1 -0
- package/assets/esri/core/workers/chunks/f3d57c5b9dffd12e45b4.js +1 -0
- package/assets/esri/core/workers/chunks/f3e53be08ab9dbdf17ae.js +1 -0
- package/assets/esri/core/workers/chunks/f43ae1c2f89e1c4396cc.js +1 -0
- package/assets/esri/core/workers/chunks/f60ed579981913d44675.js +1 -0
- package/assets/esri/core/workers/chunks/{147d1e7e2852a4197e5f.js → f665fb4c5633e0a459d8.js} +1 -1
- package/assets/esri/core/workers/chunks/f66e597e524b26e61cd3.js +1 -0
- package/assets/esri/core/workers/chunks/{bec140a69cfdb0519680.js → f74c7cbe4bd12f73ae90.js} +1 -1
- package/assets/esri/core/workers/chunks/{e6f6b38eda34708d61c5.js → f7f2102b16d201e5f531.js} +1 -1
- package/assets/esri/core/workers/chunks/f82ae237452b97cfc024.js +1 -0
- package/assets/esri/core/workers/chunks/f83c3597e9332bd991eb.js +1 -0
- package/assets/esri/core/workers/chunks/f8a6d8cdcabcd1d511b6.js +1 -0
- package/assets/esri/core/workers/chunks/f8f7b86bbd62106bc3d4.js +1 -0
- package/assets/esri/core/workers/chunks/f9a4387f850d85c44ca5.js +1 -0
- package/assets/esri/core/workers/chunks/fbc7576ed12964059da6.js +1 -0
- package/assets/esri/core/workers/chunks/fdd0e6d9927d3c43b0d3.js +1 -0
- package/assets/esri/core/workers/chunks/fddcb8be714ad18ad0c8.js +1 -0
- package/assets/esri/core/workers/chunks/{baa46edd87e97f922128.js → ffe749d790320dddfa74.js} +1 -1
- package/chunks/Bufferer-CclWhXVb.js +1 -1
- package/chunks/Distance2DCalculator-DjIp2uQi.js +1 -1
- package/chunks/Envelope.js +1 -1
- package/chunks/GeodeticDistanceCalculator-zRp89-dW.js +1 -1
- package/chunks/GeodeticUtils.js +1 -1
- package/chunks/GeographicTransformation.js +1 -1
- package/chunks/Geometry.js +1 -1
- package/chunks/GlowComposite.glsl.js +9 -7
- package/chunks/MultiPathImpl.js +1 -1
- package/chunks/OperatorCentroid2D.js +1 -1
- package/chunks/OperatorContains.js +2 -0
- package/chunks/OperatorCrosses.js +1 -1
- package/chunks/OperatorCut.js +1 -1
- package/chunks/OperatorDisjoint.js +2 -0
- package/chunks/OperatorDistance.js +2 -0
- package/chunks/OperatorEquals.js +2 -0
- package/chunks/OperatorGeodesicBuffer.js +1 -1
- package/chunks/OperatorGeodeticArea.js +1 -1
- package/chunks/OperatorGeodeticDensifyByLength.js +1 -1
- package/chunks/OperatorGeodeticLength.js +1 -1
- package/chunks/OperatorGraphicBuffer.js +1 -1
- package/chunks/OperatorIntegrate.js +1 -1
- package/chunks/OperatorIntersects.js +1 -1
- package/chunks/OperatorMultiPartToSinglePart.js +1 -1
- package/chunks/OperatorOverlaps.js +1 -1
- package/chunks/OperatorProximity.js +1 -1
- package/chunks/OperatorProximityGeodesic.js +1 -1
- package/chunks/OperatorRelate.js +2 -0
- package/chunks/OperatorShapePreservingLength.js +1 -1
- package/chunks/OperatorShapePreservingProject.js +1 -1
- package/chunks/OperatorSimplifyOGC.js +1 -1
- package/chunks/OperatorTouches.js +1 -1
- package/chunks/OperatorWithin.js +1 -1
- package/chunks/Point2D.js +1 -1
- package/chunks/ProjectionTransformation.js +1 -1
- package/chunks/SideCalculator2D-DX0718xq.js +1 -1
- package/chunks/UnitFactory.js +1 -1
- package/chunks/aiServices.js +1 -1
- package/chunks/array.js +1 -1
- package/chunks/boundedPlane.js +1 -1
- package/chunks/cameraUtilsSpherical.js +1 -1
- package/chunks/languageUtils.js +1 -1
- package/config.js +1 -1
- package/core/accessorSupport/Property.js +1 -1
- package/core/sql/TimeOnly.js +1 -1
- package/core/units.js +1 -1
- package/editing/sharedTemplates/executor/builders/bufferLineToPolygon.js +1 -1
- package/editing/sharedTemplates/executor/builders/bufferPointToPolygon.js +1 -1
- package/editing/sharedTemplates/executor/builders/bufferPolygonToPolygon.js +1 -1
- package/editing/sharedTemplates/executor/builders/pointAtIntersectionVerticesOfLine.js +1 -1
- package/editing/sharedTemplates/executor/builders/support/offsetUtils.js +1 -1
- package/form/elements/inputs/inputUtils.js +1 -1
- package/geometry/operators/areaOperator.js +1 -1
- package/geometry/operators/bufferOperator.js +1 -1
- package/geometry/operators/centroidOperator.js +1 -1
- package/geometry/operators/clipOperator.js +1 -1
- package/geometry/operators/containsOperator.js +1 -1
- package/geometry/operators/convexHullOperator.js +1 -1
- package/geometry/operators/crossesOperator.js +1 -1
- package/geometry/operators/cutOperator.js +1 -1
- package/geometry/operators/densifyOperator.js +1 -1
- package/geometry/operators/differenceOperator.js +1 -1
- package/geometry/operators/disjointOperator.js +1 -1
- package/geometry/operators/distanceOperator.js +1 -1
- package/geometry/operators/equalsOperator.js +1 -1
- package/geometry/operators/generalizeOperator.js +1 -1
- package/geometry/operators/geodesicBufferOperator.js +1 -1
- package/geometry/operators/geodeticAreaOperator.js +1 -1
- package/geometry/operators/geodeticDensifyOperator.js +1 -1
- package/geometry/operators/geodeticDistanceOperator.js +1 -1
- package/geometry/operators/geodeticLengthOperator.js +1 -1
- package/geometry/operators/gx/operatorAutoComplete.js +1 -1
- package/geometry/operators/gx/operatorBuffer.js +1 -1
- package/geometry/operators/gx/operatorDifference.js +1 -1
- package/geometry/operators/gx/operatorIntersection.js +1 -1
- package/geometry/operators/gx/operatorLabelPoint.js +1 -1
- package/geometry/operators/gx/operatorLinesToPolygons.js +1 -1
- package/geometry/operators/gx/operatorPolygonOverlay.js +1 -1
- package/geometry/operators/gx/operatorSimplify.js +1 -1
- package/geometry/operators/gx/operatorSymmetricDifference.js +1 -1
- package/geometry/operators/gx/operatorUnion.js +1 -1
- package/geometry/operators/intersectionOperator.js +1 -1
- package/geometry/operators/intersectsOperator.js +1 -1
- package/geometry/operators/json/containsOperator.js +1 -1
- package/geometry/operators/json/crossesOperator.js +1 -1
- package/geometry/operators/json/disjointOperator.js +1 -1
- package/geometry/operators/json/intersectsOperator.js +1 -1
- package/geometry/operators/json/overlapsOperator.js +1 -1
- package/geometry/operators/json/touchesOperator.js +1 -1
- package/geometry/operators/json/unionOperator.js +1 -1
- package/geometry/operators/json/withinOperator.js +1 -1
- package/geometry/operators/labelPointOperator.js +1 -1
- package/geometry/operators/lengthOperator.js +1 -1
- package/geometry/operators/multiPartToSinglePartOperator.js +1 -1
- package/geometry/operators/offsetOperator.js +1 -1
- package/geometry/operators/overlapsOperator.js +1 -1
- package/geometry/operators/proximityOperator.js +1 -1
- package/geometry/operators/relateOperator.js +1 -1
- package/geometry/operators/reshapeOperator.js +1 -1
- package/geometry/operators/simplifyOGCOperator.js +1 -1
- package/geometry/operators/simplifyOperator.js +1 -1
- package/geometry/operators/support/apiConverter.js +1 -1
- package/geometry/operators/support/jsonConverter.js +1 -1
- package/geometry/operators/support/projectionTransformation.js +1 -1
- package/geometry/operators/symmetricDifferenceOperator.js +1 -1
- package/geometry/operators/touchesOperator.js +1 -1
- package/geometry/operators/unionOperator.js +1 -1
- package/geometry/operators/withinOperator.js +1 -1
- package/geometry/support/convexPolyhedron.js +1 -1
- package/geometry/support/curves/circleUtils.js +1 -1
- package/geometry/support/curves/ellipticArc7Utils.js +1 -1
- package/geometry/support/frustum.js +1 -1
- package/geometry/support/plane.js +1 -1
- package/geometry/support/webMercatorUtils.js +1 -1
- package/kernel.js +1 -1
- package/layers/VectorTileLayer.js +1 -1
- package/layers/graphics/data/FlatFeatureStore.js +1 -1
- package/layers/graphics/data/QueryEngine.js +1 -1
- package/layers/graphics/hydratedFeatures.js +1 -1
- package/layers/mixins/DataSeriesLayer.js +1 -1
- package/layers/support/csvUtils.js +1 -1
- package/layers/support/fieldUtils.js +1 -1
- package/layers/video/VideoController.js +1 -1
- package/package.json +4 -4
- package/support/ArcadeExpression.js +1 -1
- package/support/arcadeUtils.js +1 -1
- package/support/loadArcade.js +1 -1
- package/support/revision.js +1 -1
- package/support/tests/serviceMockDependencies.js +1 -1
- package/views/2d/analysis/AreaMeasurement/AreaMeasurementController.js +1 -1
- package/views/2d/analysis/DistanceMeasurement/DistanceMeasurementController.js +1 -1
- package/views/2d/engine/vectorTiles/TileManager.js +1 -1
- package/views/2d/engine/webgl/util/Fader.js +1 -1
- package/views/2d/layers/features/support/FeatureSetReader.js +1 -1
- package/views/2d/layers/support/RouteLayerWaypointVisualization.js +1 -1
- package/views/3d/analysis/LineOfSight/LineOfSightConfiguration.js +1 -1
- package/views/3d/analysis/LineOfSight/LineOfSightManipulators.js +1 -1
- package/views/3d/analysis/LineOfSight/LineOfSightVisualization.js +1 -1
- package/views/3d/analysis/ShadowCastAnalysisView3D.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementController.js +1 -1
- package/views/3d/input/SceneInputManager.js +1 -1
- package/views/3d/input/handlers/RopePullNavigation.js +2 -0
- package/views/3d/layers/I3SMeshView3D.js +1 -1
- package/views/3d/layers/IntegratedMeshNormals.js +1 -1
- package/views/3d/layers/TiledLayerView3D.js +1 -1
- package/views/3d/layers/graphics/featureExpressionInfoUtils.js +1 -1
- package/views/3d/layers/i3s/I3SNode.js +1 -1
- package/views/3d/layers/i3s/I3SViewportQueries.js +1 -1
- package/views/3d/layers/i3s/SweptSphereVolume.js +1 -1
- package/views/3d/layers/support/FeatureTileVisibility3D.js +1 -1
- package/views/3d/layers/support/IntegratedMesh3DTilesVertexProcessing.js +1 -1
- package/views/3d/state/Frustum.js +1 -1
- package/views/3d/state/controllers/RopePullController.js +2 -0
- package/views/3d/state/utils/ropePullUtils.js +1 -1
- package/views/3d/support/ElevationAgnosticVisibility.js +1 -1
- package/views/3d/support/sphericalTileUtils.js +1 -1
- package/views/3d/terrain/PlanarPatch.js +1 -1
- package/views/3d/terrain/SphericalPatch.js +1 -1
- package/views/3d/terrain/Tile.js +1 -1
- package/views/3d/webgl-engine/effects/RenderPluginManager.js +1 -1
- package/views/3d/webgl-engine/lib/Geometry.js +1 -1
- package/views/3d/webgl-engine/lib/LineMaterial.js +2 -0
- package/views/3d/webgl-engine/lib/Material.js +1 -1
- package/views/3d/webgl-engine/lib/PointMaterial.js +2 -0
- package/views/3d/webgl-engine/lib/RenderGeometry.js +1 -1
- package/views/3d/webgl-engine/lib/SortedRenderGeometryRenderer.js +1 -1
- package/views/3d/webgl-engine/materials/HUDMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/HeatmapDensityMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/LineCalloutMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/LineMarkerMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/MeasurementArrowMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/NativeLineMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
- package/views/SelectionManager.js +1 -1
- package/views/draw/DrawTool.js +1 -1
- package/views/draw/support/createUtils.js +1 -1
- package/views/interactive/editGeometry/operations/OffsetEdgeVertex.js +1 -1
- package/views/interactive/sketch/constraints.js +1 -1
- package/views/popupAdapter.js +1 -1
- package/views/support/GeometryWorker.js +1 -1
- package/views/support/geometry3dUtils.js +1 -1
- package/views/support/selectionUtils.js +1 -1
- package/widgets/AreaMeasurement2D/AreaMeasurement2DTool.js +1 -1
- package/widgets/BatchAttributeForm/expressions/ArcadeExecutorProvider.js +1 -1
- package/widgets/BatchAttributeForm/templates/FieldElementTemplate.js +1 -1
- package/widgets/BatchAttributeForm/templates/support/createBatchFormTemplate.js +1 -1
- package/widgets/BatchAttributeForm/templates/support/hashElementTemplate.js +1 -1
- package/widgets/DistanceMeasurement2D/DistanceMeasurement2DTool.js +1 -1
- package/widgets/FeatureTable/support/types.d.ts +3 -1
- package/widgets/OrientedImageryViewer/adapters/view/MapViewAdapter.js +1 -1
- package/widgets/OrientedImageryViewer/components/ImageViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/components/OrientedImageryVideoViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/imageMeasurementUtils.js +1 -1
- package/widgets/OrientedImageryViewer/support/panConstraint.js +1 -1
- package/widgets/OrientedImageryViewer/support/superimposeUtils.js +1 -1
- package/widgets/OrientedImageryViewer/videoViewerUtils.js +1 -1
- package/widgets/UtilityNetworkTrace/support/GeometryHandler.js +1 -1
- package/widgets/support/SelectionList/selectionListUtils.d.ts +58 -0
- package/widgets/support/SelectionToolbar/SelectionToolbarViewModel.js +1 -1
- package/widgets/support/Selector2D/selectorUtils.js +1 -1
- package/arcade/kernel.js +0 -2
- package/assets/esri/core/workers/chunks/01b7babaefe6500fd6eb.js +0 -1
- package/assets/esri/core/workers/chunks/06e109e92de7fa0956e3.js +0 -1
- package/assets/esri/core/workers/chunks/0775d1e3034d5e7ef7bc.js +0 -1
- package/assets/esri/core/workers/chunks/0993e51d3a9701ed2198.js +0 -1
- package/assets/esri/core/workers/chunks/09a0a1e794ddff65aa08.js +0 -1
- package/assets/esri/core/workers/chunks/0e57d33bd202d0972207.js +0 -1
- package/assets/esri/core/workers/chunks/114ba901fd319ce87dc6.js +0 -1
- package/assets/esri/core/workers/chunks/12a3b55195ce3244259d.js +0 -1
- package/assets/esri/core/workers/chunks/151bac9e519a3b821baf.js +0 -1
- package/assets/esri/core/workers/chunks/156f85ac1885464f0072.js +0 -1
- package/assets/esri/core/workers/chunks/180eebd8b7badc2840c9.js +0 -1
- package/assets/esri/core/workers/chunks/19cb8963d5ec2246357b.js +0 -1
- package/assets/esri/core/workers/chunks/19d4ecee1c161ac0f33c.js +0 -1
- package/assets/esri/core/workers/chunks/19ece9f5313f53384cac.js +0 -1
- package/assets/esri/core/workers/chunks/1d770e8f0fe57d937daa.js +0 -1
- package/assets/esri/core/workers/chunks/1dd22b8df6a52277c64b.js +0 -1
- package/assets/esri/core/workers/chunks/1ede298ab815e9ad625c.js +0 -1
- package/assets/esri/core/workers/chunks/208bc524bd1e0d3aab79.js +0 -1
- package/assets/esri/core/workers/chunks/20a4ae83542c7d39cf0f.js +0 -1
- package/assets/esri/core/workers/chunks/21071ab3d7b2771406ae.js +0 -1
- package/assets/esri/core/workers/chunks/21bfa89363104f041101.js +0 -1
- package/assets/esri/core/workers/chunks/21d0a4d6639d32278f11.js +0 -1
- package/assets/esri/core/workers/chunks/22a75fdc6ba60213a870.js +0 -1
- package/assets/esri/core/workers/chunks/22e004ed97e06536ecef.js +0 -1
- package/assets/esri/core/workers/chunks/23942712a3f6290e0fdb.js +0 -1
- package/assets/esri/core/workers/chunks/242287de82586d42f0a4.js +0 -1
- package/assets/esri/core/workers/chunks/25cb5086eaa412f6820b.js +0 -1
- package/assets/esri/core/workers/chunks/26c8ed0aef59ed6d5267.js +0 -1
- package/assets/esri/core/workers/chunks/2742d62fceaf0736aef0.js +0 -1
- package/assets/esri/core/workers/chunks/276eba546dc8774076ee.js +0 -1
- package/assets/esri/core/workers/chunks/28e02b213da9e682d3dc.js +0 -29
- package/assets/esri/core/workers/chunks/2d8195231cb16247f198.js +0 -1
- package/assets/esri/core/workers/chunks/2db1227ecd421728630d.js +0 -1
- package/assets/esri/core/workers/chunks/2ddc9c9ff6ec243d85e2.js +0 -1
- package/assets/esri/core/workers/chunks/2e712154ebb895d96ba1.js +0 -1
- package/assets/esri/core/workers/chunks/2f2df51d4976ae65edae.js +0 -1
- package/assets/esri/core/workers/chunks/32d31fd4cffdf5a80acb.js +0 -1
- package/assets/esri/core/workers/chunks/33aaa5a49e396a0aca47.js +0 -1
- package/assets/esri/core/workers/chunks/35622088727e120c93b9.js +0 -1
- package/assets/esri/core/workers/chunks/3714cc26f446c4d9cc2c.js +0 -1
- package/assets/esri/core/workers/chunks/3722d40d161d60370936.js +0 -1
- package/assets/esri/core/workers/chunks/3ac4cfeb1af12a9dc27d.js +0 -1
- package/assets/esri/core/workers/chunks/3b009c05eaec5a7048a8.js +0 -1
- package/assets/esri/core/workers/chunks/3b376318df4ff8519370.js +0 -1
- package/assets/esri/core/workers/chunks/3bf37fd3280f4891c76b.js +0 -1
- package/assets/esri/core/workers/chunks/3d18a10a1ecfabe92db3.js +0 -1
- package/assets/esri/core/workers/chunks/3de20165796fa4f76728.js +0 -1
- package/assets/esri/core/workers/chunks/3fbd4c7e25440c4713f2.js +0 -1
- package/assets/esri/core/workers/chunks/407dba2be21255eb47fc.js +0 -1
- package/assets/esri/core/workers/chunks/414093fa4957d17bf551.js +0 -1
- package/assets/esri/core/workers/chunks/44b1a4e8a65221ad3808.js +0 -1
- package/assets/esri/core/workers/chunks/48b31b8534e7bfe42976.js +0 -1
- package/assets/esri/core/workers/chunks/48f6af09436723f2d861.js +0 -1
- package/assets/esri/core/workers/chunks/49e37f653b81f9e4f7cc.js +0 -1
- package/assets/esri/core/workers/chunks/4b4221a869b3f0d517fa.js +0 -1
- package/assets/esri/core/workers/chunks/4b86bcde5992eb752ab0.js +0 -1
- package/assets/esri/core/workers/chunks/4b9095e2bd060efd47c4.js +0 -1
- package/assets/esri/core/workers/chunks/5084de4d0d4961b63ab7.js +0 -1
- package/assets/esri/core/workers/chunks/51a8a47aac1d8d22ba9d.js +0 -1
- package/assets/esri/core/workers/chunks/5324e4feb78203204c0c.js +0 -1
- package/assets/esri/core/workers/chunks/5536cee0dfc183584a9b.js +0 -1
- package/assets/esri/core/workers/chunks/58d10928959ae1e2e8d9.js +0 -1
- package/assets/esri/core/workers/chunks/597a8e3d9e458298fdd3.js +0 -1
- package/assets/esri/core/workers/chunks/5a006ff759fad9fc25cb.js +0 -1
- package/assets/esri/core/workers/chunks/60be6de19c5659091d8f.js +0 -1
- package/assets/esri/core/workers/chunks/61a38237e163b39520e5.js +0 -1
- package/assets/esri/core/workers/chunks/61fcdba6f2097378dce5.js +0 -1
- package/assets/esri/core/workers/chunks/6561c01c67db1f4c546e.js +0 -1
- package/assets/esri/core/workers/chunks/65eff0ae773505495f21.js +0 -1
- package/assets/esri/core/workers/chunks/67452ba9e87962b9e01e.js +0 -1
- package/assets/esri/core/workers/chunks/68195277046861ed39a7.js +0 -1
- package/assets/esri/core/workers/chunks/68705692335d57522030.js +0 -1
- package/assets/esri/core/workers/chunks/6a2a4da3a1cd64ff576f.js +0 -1
- package/assets/esri/core/workers/chunks/6af1680771fd8ae8c7dc.js +0 -1
- package/assets/esri/core/workers/chunks/6c367de583e0e657ca3a.js +0 -1
- package/assets/esri/core/workers/chunks/6d2021a0f0c9a3c6a0e6.js +0 -1
- package/assets/esri/core/workers/chunks/6db4a4f9a9ce7cc738d0.js +0 -1
- package/assets/esri/core/workers/chunks/6f2a9259240769c7cd6e.js +0 -1
- package/assets/esri/core/workers/chunks/724260e36efea90585f4.js +0 -1
- package/assets/esri/core/workers/chunks/74ae1222787389d5fcaa.js +0 -1
- package/assets/esri/core/workers/chunks/74bfaa98da6c5d375f05.js +0 -1
- package/assets/esri/core/workers/chunks/7a68a16f7fea712b9fd6.js +0 -1
- package/assets/esri/core/workers/chunks/7b2174b19d06c16715f0.js +0 -1
- package/assets/esri/core/workers/chunks/7d8e59ad438fb34b476d.js +0 -1
- package/assets/esri/core/workers/chunks/7eb94fc75926bc739233.js +0 -1
- package/assets/esri/core/workers/chunks/80795118467fb31ea4ed.js +0 -1
- package/assets/esri/core/workers/chunks/820c530b8765ecb1f36e.js +0 -1
- package/assets/esri/core/workers/chunks/830daaca32352da6eebe.js +0 -1
- package/assets/esri/core/workers/chunks/852649460d664b0a1a1d.js +0 -1
- package/assets/esri/core/workers/chunks/85c538bf1209f0da1f8e.js +0 -1
- package/assets/esri/core/workers/chunks/8c2921081ca3e7fd0385.js +0 -1
- package/assets/esri/core/workers/chunks/8db3fd97e8eccd3ba1db.js +0 -1
- package/assets/esri/core/workers/chunks/8e225dd0319672103561.js +0 -1
- package/assets/esri/core/workers/chunks/8e79a84e224d05204e7d.js +0 -1
- package/assets/esri/core/workers/chunks/8e9aff66a2d4e2cc102b.js +0 -1
- package/assets/esri/core/workers/chunks/917318f8e186f466dc52.js +0 -1
- package/assets/esri/core/workers/chunks/9267f6a65c2245696eac.js +0 -1
- package/assets/esri/core/workers/chunks/9407db0584c730591161.js +0 -1
- package/assets/esri/core/workers/chunks/958e161634b5bfd50625.js +0 -1
- package/assets/esri/core/workers/chunks/9658b46a7111cda53b0d.js +0 -1
- package/assets/esri/core/workers/chunks/974bcaf2a059b8cfb153.js +0 -1
- package/assets/esri/core/workers/chunks/99881d0a6c2490a16268.js +0 -1
- package/assets/esri/core/workers/chunks/99980c944acb8ff88d6a.js +0 -1
- package/assets/esri/core/workers/chunks/9c227785f4454d3966ea.js +0 -1
- package/assets/esri/core/workers/chunks/9d61d9136f3d00aab530.js +0 -1
- package/assets/esri/core/workers/chunks/9df2685583393a87df2d.js +0 -1
- package/assets/esri/core/workers/chunks/9e840a71906c4deef776.js +0 -1
- package/assets/esri/core/workers/chunks/9ee6e8a6b9bfda758c21.js +0 -1
- package/assets/esri/core/workers/chunks/a03f4605bde69bfb6d41.js +0 -1
- package/assets/esri/core/workers/chunks/a327843cee2057ee76c0.js +0 -1
- package/assets/esri/core/workers/chunks/a557347fb313df6fcc79.js +0 -1
- package/assets/esri/core/workers/chunks/a8da0728a12fc46dca23.js +0 -1
- package/assets/esri/core/workers/chunks/a9ea28e0f22cfe3ccf92.js +0 -1
- package/assets/esri/core/workers/chunks/aae92f23b38ae22dd8bf.js +0 -1
- package/assets/esri/core/workers/chunks/ad3714da9c90d7471385.js +0 -1
- package/assets/esri/core/workers/chunks/b047f9e9ba26037657ed.js +0 -1
- package/assets/esri/core/workers/chunks/b1323800119bd5c1759b.js +0 -1
- package/assets/esri/core/workers/chunks/b18c35f25da18a3219d7.js +0 -1
- package/assets/esri/core/workers/chunks/b1f68ee65cce457d7b5b.js +0 -1
- package/assets/esri/core/workers/chunks/b2d6fd436981c890152f.js +0 -1
- package/assets/esri/core/workers/chunks/b3c518ca8679fbe16ece.js +0 -1
- package/assets/esri/core/workers/chunks/b4b4fe06364bea9b0750.js +0 -1
- package/assets/esri/core/workers/chunks/b61b7005edd9ced925e9.js +0 -1
- package/assets/esri/core/workers/chunks/b661aae7e3ce955a783e.js +0 -1
- package/assets/esri/core/workers/chunks/b66ebe53bd879aa9de57.js +0 -1
- package/assets/esri/core/workers/chunks/b8ca80134abfcc692244.js +0 -1
- package/assets/esri/core/workers/chunks/bbdf10d76d852072c878.js +0 -1
- package/assets/esri/core/workers/chunks/bbeb61d9302323bae9fb.js +0 -1
- package/assets/esri/core/workers/chunks/bbfd2b4af8e498b61af9.js +0 -1
- package/assets/esri/core/workers/chunks/bdafd4f03585351cecc3.js +0 -1
- package/assets/esri/core/workers/chunks/bddd5aa7a14cd45ff91c.js +0 -1
- package/assets/esri/core/workers/chunks/be31c2cb97f664a54306.js +0 -1
- package/assets/esri/core/workers/chunks/be4319827db91aa71bf5.js +0 -1
- package/assets/esri/core/workers/chunks/bef32acf368b4d5aba37.js +0 -1
- package/assets/esri/core/workers/chunks/c1568bcd3f04014152e1.js +0 -1
- package/assets/esri/core/workers/chunks/c1a7c475ce0c59ffa75a.js +0 -1
- package/assets/esri/core/workers/chunks/c229a4eedda468c914a9.js +0 -1
- package/assets/esri/core/workers/chunks/c2b2942456f1b10d0e96.js +0 -1
- package/assets/esri/core/workers/chunks/c308d8f419ba63c583e6.js +0 -1
- package/assets/esri/core/workers/chunks/c5dc2743c7116d0bc0d8.js +0 -1
- package/assets/esri/core/workers/chunks/c68cc3b9c170b8de22dc.js +0 -1
- package/assets/esri/core/workers/chunks/c6ef0636073e28350c91.js +0 -1
- package/assets/esri/core/workers/chunks/c71368cd64f240da1743.js +0 -1
- package/assets/esri/core/workers/chunks/cb2f27e5d465124b9868.js +0 -1
- package/assets/esri/core/workers/chunks/cee2f7f3b3f84688e49d.js +0 -1
- package/assets/esri/core/workers/chunks/d0942860a53b02371e94.js +0 -1
- package/assets/esri/core/workers/chunks/d13eeff678972a245d5d.js +0 -1
- package/assets/esri/core/workers/chunks/d3d7b4cd28a0dc2720d4.js +0 -1
- package/assets/esri/core/workers/chunks/d3ea7ac6fe71c95faa75.js +0 -1
- package/assets/esri/core/workers/chunks/d41e4498aaf4970f48b0.js +0 -1
- package/assets/esri/core/workers/chunks/d56603e1d0031f3c5f3b.js +0 -1
- package/assets/esri/core/workers/chunks/d7c8725ffb175cec5f8a.js +0 -1
- package/assets/esri/core/workers/chunks/d96fa373dcb621c2a869.js +0 -1
- package/assets/esri/core/workers/chunks/da233362b06b6db375f1.js +0 -1
- package/assets/esri/core/workers/chunks/dbc8f15a6be835f4897d.js +0 -1
- package/assets/esri/core/workers/chunks/e00d0036974aaec7d876.js +0 -1
- package/assets/esri/core/workers/chunks/e0c75ae3a211a8da10f7.js +0 -1
- package/assets/esri/core/workers/chunks/e474106292834633e7d4.js +0 -1
- package/assets/esri/core/workers/chunks/e557043f90c051e93925.js +0 -1
- package/assets/esri/core/workers/chunks/e5cbed6f19c743915c8e.js +0 -1
- package/assets/esri/core/workers/chunks/e5ecd93bd32e99bc99d1.js +0 -1
- package/assets/esri/core/workers/chunks/e64ccdb8328eb6514e59.js +0 -1
- package/assets/esri/core/workers/chunks/eb8c4f194bb66a27d418.js +0 -1
- package/assets/esri/core/workers/chunks/ebd8c77df5df63bd3efe.js +0 -1
- package/assets/esri/core/workers/chunks/f14347f5d63f5d102617.js +0 -1
- package/assets/esri/core/workers/chunks/f3c0280b6c87f2383a60.js +0 -1
- package/assets/esri/core/workers/chunks/f42c4dcb8f413ca1c6fd.js +0 -1
- package/assets/esri/core/workers/chunks/f5773321487ec248fa3b.js +0 -1
- package/assets/esri/core/workers/chunks/f76911f71540b058a881.js +0 -1
- package/assets/esri/core/workers/chunks/f988d5a6dcc15fe34797.js +0 -1
- package/assets/esri/core/workers/chunks/fa29b5064d6626cfc019.js +0 -1
- package/assets/esri/core/workers/chunks/fa882d0f4a9826533421.js +0 -1
- package/assets/esri/core/workers/chunks/fb2d43608006f588e3cb.js +0 -1
- package/assets/esri/core/workers/chunks/fbd02e8277fe2252ecd2.js +0 -1
- package/assets/esri/core/workers/chunks/fc1aeea22f8c9d63864a.js +0 -1
- package/assets/esri/core/workers/chunks/fc3c03cfa3d6bf3b37dc.js +0 -1
- package/assets/esri/core/workers/chunks/fcf7299e2ee904ab9882.js +0 -1
- package/assets/esri/core/workers/chunks/ff07d351553deb70b889.js +0 -1
- package/assets/esri/core/workers/chunks/ffee66699f5d26569baf.js +0 -1
- package/chunks/OperatorDefinitions.js +0 -2
- package/chunks/areaOperator.js +0 -2
- package/chunks/bufferOperator.js +0 -2
- package/chunks/centroidOperator.js +0 -2
- package/chunks/clipOperator.js +0 -2
- package/chunks/containsOperator.js +0 -2
- package/chunks/convexHullOperator.js +0 -2
- package/chunks/crossesOperator.js +0 -2
- package/chunks/cutOperator.js +0 -2
- package/chunks/densifyOperator.js +0 -2
- package/chunks/differenceOperator.js +0 -2
- package/chunks/disjointOperator.js +0 -2
- package/chunks/distanceOperator.js +0 -2
- package/chunks/equalsOperator.js +0 -2
- package/chunks/generalizeOperator.js +0 -2
- package/chunks/geodesicBufferOperator.js +0 -2
- package/chunks/geodeticAreaOperator.js +0 -2
- package/chunks/geodeticDensifyOperator.js +0 -2
- package/chunks/geodeticDistanceOperator.js +0 -2
- package/chunks/geodeticLengthOperator.js +0 -2
- package/chunks/intersectionOperator.js +0 -2
- package/chunks/intersectsOperator.js +0 -2
- package/chunks/labelPointOperator.js +0 -2
- package/chunks/lengthOperator.js +0 -2
- package/chunks/multiPartToSinglePartOperator.js +0 -2
- package/chunks/offsetOperator.js +0 -2
- package/chunks/overlapsOperator.js +0 -2
- package/chunks/proximityOperator.js +0 -2
- package/chunks/relateOperator.js +0 -2
- package/chunks/simplifyOperator.js +0 -2
- package/chunks/symmetricDifferenceOperator.js +0 -2
- package/chunks/touchesOperator.js +0 -2
- package/chunks/unionOperator.js +0 -2
- package/chunks/withinOperator.js +0 -2
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{isSome as t,equals as e}from"../../../core/arrayUtils.js";import{asinClamped as r}from"../../../core/mathUtils.js";import{exactEquals as s,set as n,dot as i,subtract as o,squaredDistance as c}from"../../../core/libs/gl-matrix-2/math/vec2.js";import{create as u}from"../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{exactEquals as a,set as h,squaredDistance as l,equals as f,copy as d,subtract as p,scaleAndAdd as m,sub as g,squaredLength as _,dot as x,cross as L,normalize as k}from"../../../core/libs/gl-matrix-2/math/vec3.js";import{UNIT_Z as y,create as v,fromValues as z,clone as M}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{set as P,dot as q}from"../../../core/libs/gl-matrix-2/math/vec4.js";import{create as T}from"../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{directGeodeticSolver as w,inverseGeodeticSolver as j,InverseGeodeticSolverResult as D}from"../../../geometry/geodesicUtils.js";import{toRadians as b}from"../../../geometry/support/geodesicConstants.js";import{fromPositionAndNormal as R,create as A,fromPoints as U,intersectLine as Z,signedDistance as C,projectPoint as I,getNormal as O,distance as S}from"../../../geometry/support/plane.js";import{Sphere as E}from"../../../geometry/support/sphere.js";import{closestPointOnCurve as G}from"../../../geometry/support/curves/closestPointOnCurve.js";import{getEndpoint as V,curveEquals as B}from"../../../geometry/support/curves/curveUtils.js";import{tangentFrame as F}from"../../3d/support/mathUtils.js";import{clone as H,create as J,fromValues as K,createWritable as N,asVec2 as Q,fromVec3 as W}from"./normalizedPoint.js";import{projectPointToVerticalCylinder as X,intersectLineLikes as Y,intersectVerticalPlaneAndLineLike as $,intersectLineLikeAndVerticalCylinder as tt,intersectLineLikeAndCircle as et,intersectVerticalPlanes as rt,intersectVerticalPlaneAndVerticalCylinder as st,intersectVerticalCylinders as nt,projectPointToVerticalPlane as it,intersectVerticalPlaneAndPoint as ot,vectorsHaveCloseZ as ct,isClose as ut,isPointInsidePlane as at,projectPointToLineLike as ht,pointsInsidePlane as lt}from"../../support/geometry3dUtils.js";class ft{intersect(t){return Vt(this,t)}closestPoints(t){return[this.closestTo(t)]}}class dt extends ft{constructor(t){super(),this.point=t}equals(t){return this===t||ge(t)&&a(this.point,t.point)}closestTo(){return H(this.point)}}class pt extends ft{constructor(t,e,r){super(),this.start=t,this.end=e,this.lineLike={start:t,end:e,type:r}}equals(t){return this===t||_e(t)&&this.lineLike.type===t.lineLike.type&&a(this.start,t.start)&&a(this.end,t.end)}closestTo(t){const e=N();return ht(t,this.lineLike,e),e}}class mt extends pt{constructor(t,e){super(t,e,1)}}class gt extends ft{constructor(t,e){super(),this.start=t,this.curve=e}closestTo(t){const{curvePoint:e,t:r}=G(this.start,this.curve,t),s=V(this.curve)[2]??0,n=this.start[2]*(1-r)+s*r;return J(e[0],e[1],n)}equals(t){return this===t||xe(t)&&a(this.start,t.start)&&B(this.curve,t.curve)}}class _t extends pt{constructor(t,e){super(t,e,0)}}class xt extends ft{constructor(t){super(),this.constraints=t}equals(t){return this===t||me(t)&&e(this.constraints,t.constraints,(t,e)=>t.equals(e))}closestTo(t){let e,r=1/0;for(const s of this.constraints){const n=s.closestTo(t),i=l(t,n);i<r&&(r=i,e=n)}return H(e??t)}closestPoints(t){return this.constraints.flatMap(e=>e===this?[]:e.closestPoints(t))}}class Lt extends ft{constructor(t,e){super(),this.center=t,this.radius=e}equals(t){return this===t||ye(t)&&this.center[0]===t.center[0]&&this.center[1]===t.center[1]&&this.radius===t.radius}closestTo(t){const e=N();return X(t,this.center,this.radius,e),e}}class kt extends ft{constructor(t,e){super(),this.center=t,this.radius=e}equals(t){return this===t||ve(t)&&a(this.center,t.center)&&this.radius===t.radius}closestTo(t){const e=N();return X(t,this.center,this.radius,e),e[2]=this.center[2],e}asCircle(){return new yt(H(this.center),this.radius,K(0,0,1))}}class yt extends ft{constructor(t,e,r,s){super(),this.center=t,this.radius=e,this.normal=r,this.slicePlane=s}equals(t){return this===t||ze(t)&&a(this.center,t.center)&&a(this.normal,t.normal)&&this.radius===t.radius}closestTo(t){const{center:e,radius:r}=this;I(this.getPlane(zt),t,vt);const s=g(vt,vt,e),n=_(s);if(ut(n,0))return H(t);const i=r/Math.sqrt(n),o=N();m(o,e,s,i);const{slicePlane:c}=this;if(c&&!at(c,o)){const e=Jt(c,this);return e?.closestTo(t)??H(t)}return o}getPlane(t=A()){return R(this.center,this.normal,t)}}const vt=v(),zt=A();class Mt extends ft{constructor(t){super(),this.z=t}equals(t){return this===t||Le(t)&&this.z===t.z}closestTo(t){return K(t[0],t[1],this.z)}getPlane(t=A()){return h(Pt,0,0,this.z),R(Pt,y,t)}}const Pt=v();class qt extends ft{constructor(t,e,r){super(),this.start=t,this.end=e,this.planeLike={start:Q(t),end:Q(e),type:r}}equals(t){return this===t||ke(t)&&this.planeLike.type===t.planeLike.type&&a(this.start,t.start)&&a(this.end,t.end)}closestTo(t){const e=N();return it(t,this.planeLike,e),e}closestEndTo(t){const{start:e,end:r}=this.planeLike;return Math.sign(i(o(Tt,r,e),o(wt,Q(t),e)))>0?this.end:this.start}getPlane(t=A()){const e=d(jt,this.end);return e[2]+=1,U(this.start,this.end,e,t)}getSlicePlane(t=A()){const{start:e,end:r,type:s}=this.planeLike;if(0===s)return;const n=h(jt,e[0],e[1],0),i=h(Dt,r[0],r[1],0),o=p(Dt,i,n);return R(n,o,t),t}}const Tt=u(),wt=u(),jt=v(),Dt=v();class bt extends qt{constructor(t,e){super(t,e,1)}}class Rt extends qt{constructor(t,e){super(t,e,0)}}class At extends ft{constructor(t,e){super(),this.sphere=new E(t,e),this._center=M(t)}equals(t){return this===t||Me(t)&&this.sphere.exactEquals(t.sphere)}closestTo(t){const e=N();return this.sphere.projectPoint(t,e),e}get center(){return this._center}get radius(){return this.sphere.radius}}class Ut extends ft{constructor(t,e,r){super(),this.start=t,this.end=e,this.getZ=r,this.planeLike={start:Q(t),end:Q(e),type:0}}equals(t){return this===t||Pe(t)&&a(this.start,t.start)&&a(this.end,t.end)&&this.getZ===t.getZ}closestTo(t){return Gt(this,t)}addIfOnTheGround(t,e){for(const r of e){const e=this.getZ(r[0],r[1])??0;ut(r[2],e)&&(r[2]=e,t.push(r))}}}class Zt extends ft{constructor(t,e,r){super(),this._x=t,this._y=e,this._z=r}equals(t){return this===t||Te(t)&&this._x===t._x&&this._y===t._y&&this._z===t._z}closestTo([t,e,r]){return J(this._x??t,this._y??e,this._z??r)}}class Ct extends ft{constructor(t,e,r,s,n){super(),this._origin=t,this._spatialReference=e,this._distanceMeters=r,this._z=s,this._directionDegrees=n}equals(t){return this===t||qe(t)&&s(this._origin,t._origin)&&this._spatialReference===t._spatialReference&&this._distanceMeters===t._distanceMeters&&this._z===t._z&&this._directionDegrees===t._directionDegrees}closestTo([t,e,r]){return n(It,t,e),s(It,this._origin)||this._applyDirectionAndDistance(It),J(It[0],It[1],this._z??r)}_applyDirectionAndDistance(t){if(null!=this._directionDegrees&&null!=this._distanceMeters)w(t,this._origin,this._directionDegrees,this._distanceMeters,this._spatialReference);else if(null!=this._directionDegrees)St(t,this._origin,this._directionDegrees,t,this._spatialReference);else if(null!=this._distanceMeters){const{azimuth:e}=j(Ot,this._origin,t,this._spatialReference);w(t,this._origin,e??0,this._distanceMeters,this._spatialReference)}}}const It=[0,0],Ot=new D;function St(t,e,r,s,n){let{azimuth:i,distance:o}=j(Et,e,s,n);i??=0;let c=o*Math.cos((i-r)*b);c=Math.max(0,c),w(t,e,r,c,n)}const Et=new D;function Gt(t,e){const r=N();return it(e,t.planeLike,r),r[2]=t.getZ(r[0],r[1])??we,r}function Vt(t,e){if(me(t)){const r=[];for(const s of t.constraints){const t=s.intersect(e);t&&r.push(t)}return pe(r)}if(me(e))return Vt(e,t);if(Pe(t))return he(t,e);if(Pe(e))return he(e,t);if(ge(t)){const{point:r}=t;if(ge(e))return a(r,e.point)?t:void 0;const s=e.closestTo(r);return f(s,r)?t:void 0}if(_e(t)){if(ge(e))return Vt(e,t);if(_e(e))return fe(Y(t.lineLike,e.lineLike));if(Le(e))return Bt(t,e);if(ke(e))return fe($(e.planeLike,t.lineLike));if(ye(e))return fe(tt(t.lineLike,e.center,e.radius));if(ze(e))return fe(et(t.lineLike,e));if(ve(e))return Ft(t,e);if(Me(e))return Ht(t,e)}else if(xe(t)){if(ge(e))return Vt(e,t)}else if(Le(t)){if(ge(e)||_e(e))return Vt(e,t);if(Le(e))return Kt(t,e);if(ke(e))return Nt(t,e);if(ye(e))return Qt(t,e);if(ze(e))return Xt(t,e);if(ve(e))return Wt(t,e);if(Me(e))return Yt(t,e)}else if(ke(t)){if(ge(e)||_e(e)||Le(e))return Vt(e,t);if(ke(e))return le(rt(t.planeLike,e.planeLike));if(ye(e))return le(st(t.planeLike,e.center,e.radius));if(ze(e))return te(t,e);if(ve(e))return $t(t,e);if(Me(e))return ee(t,e)}else if(ye(t)){if(ge(e)||_e(e)||Le(e)||ke(e))return Vt(e,t);if(ye(e))return le(nt(Q(t.center),t.radius,Q(e.center),e.radius));if(ze(e))return re();if(ve(e))return se(t,e);if(Me(e))return ne()}else if(ze(t)){if(ge(e)||_e(e)||Le(e)||ke(e)||ye(e))return Vt(e,t);if(ze(e))return ie();if(ve(e))return ie(e.asCircle());if(Me(e))return oe()}else if(ve(t)){if(ge(e)||_e(e)||Le(e)||ke(e)||ye(e)||ze(e))return Vt(e,t);if(ve(e))return ce(e,t);if(Me(e))return ue()}else if(Me(t)){if(ge(e)||_e(e)||Le(e)||ke(e)||ye(e)||ve(e))return Vt(e,t);if(Me(e))return ae()}}const Bt=(()=>{const t=A();return(e,r)=>{const{start:s,end:n}=e;if(ct(s,n)&&ut(s[2],r.z))return e;const i=N();return Z(r.getPlane(t),s,n,i)?new dt(i):void 0}})();function Ft({lineLike:t},{center:e,radius:r}){const s=e[2];return fe(tt(t,e,r).filter(t=>ut(t[2],s)))}function Ht({lineLike:t},{sphere:e}){return fe(e.intersectLine(t.start,t.end))}const Jt=(()=>{const t=T(),e=v(),s=v();return(n,i,o)=>{const{normal:c,center:u,radius:a}=i;F(c,e,s);const h=O(n),l=a*x(h,e),f=a*x(h,s);P(t,u[0],u[1],u[2],1);const d=q(n,t),p=Math.hypot(l,f),g=ut(p,0);if(ut(S(n,u),0)){if(g)return i;if(ut(a,0))return!o||at(o,u)?new dt(H(u)):void 0;L(e,h,c),k(e,e);const t=new Array,r=M(u);m(r,r,e,a),o&&!at(o,r)||t.push(r);const s=M(u);return m(s,s,e,-a),o&&!at(o,s)||t.push(s),fe(t)}if(g)return;const _=-d/p;if(Math.abs(_)>1||ut(_,1))return;const y=Math.atan(l/f),z=r(_)-y,T=Math.PI-z,w=new Array,j=v();m(j,u,e,a*Math.cos(z)),m(j,j,s,a*Math.sin(z)),w.push(j);const D=v();return m(D,u,e,a*Math.cos(T)),m(D,D,s,a*Math.sin(T)),w.push(D),fe(o?lt(o,w):w)}})();function Kt(t,e){return ut(t.z,e.z)?t:void 0}function Nt({z:t},{planeLike:e}){const[r,s]=e.start,[n,i]=e.end,o=K(r,s,t),c=K(n,i,t);return 0===e.type?new mt(o,c):new _t(o,c)}function Qt(t,e){const[r,s]=e.center;return new kt(K(r,s,t.z),e.radius)}function Wt(t,e){return ut(e.center[2],t.z)?e:void 0}const Xt=(()=>{const t=A();return(e,r)=>Jt(e.getPlane(t),r,r.slicePlane)})();function Yt(t,{center:e,radius:r}){const s=Math.abs(e[2]-t.z);if(s>r&&!ut(s,r))return;const n=K(e[0],e[1],t.z),i=Math.sqrt(r**2-s**2);return ut(i,0)?void 0:new kt(n,i)}const $t=(()=>{const t=A();return(e,{center:r,radius:s})=>{const n=st(e.planeLike,r,s),i=r[2];e.getSlicePlane(t);const o=new Array;for(const[c,u]of n){const e=[c,u,i];at(t,e)&&o.push(e)}return fe(o)}})(),te=(()=>{const t=A(),e=A();return(r,s)=>Jt(r.getPlane(t),s,r.getSlicePlane(e))})(),ee=(()=>{const t=A();return(e,{center:r,radius:s})=>{const n=e.getPlane(t),i=C(n,r),o=Math.abs(i);if(o>s&&!ut(o,s))return;const c=Math.sqrt(s**2-i**2);if(ut(c,0)){const t=N();return I(n,r,t),new dt(t)}const u=N(),a=M(O(n));return m(u,r,a,i),new yt(u,c,a,e.getSlicePlane())}})();function re(t,e){}function se(t,e){const r=c(Q(t.center),Q(e.center));if(ut(r,0)&&ut(t.radius,e.radius))return e;return de(nt(Q(t.center),t.radius,Q(e.center),e.radius),e.center[2])}function ne(t,e){}function ie(t,e){}function oe(t,e){}function ce(t,e){if(!ct(t.center,e.center))return;const r=c(Q(t.center),Q(e.center));if(ut(r,0)&&ut(t.radius,e.radius))return t;return de(nt(Q(t.center),t.radius,Q(e.center),e.radius),t.center[2])}function ue(t,e){}function ae(t,e){}function he(t,e){const{planeLike:r,getZ:s}=t,n=new Array;if(ge(e))t.addIfOnTheGround(n,ot(r,e.point));else if(_e(e))t.addIfOnTheGround(n,$(r,e.lineLike));else if(ye(e))for(const[i,o]of st(r,e.center,e.radius)){const t=s(i,o);null!=t&&n.push(z(i,o,t))}else if(ke(e)||Pe(e))for(const[i,o]of rt(r,e.planeLike)){const t=s(i,o)??we;n.push(z(i,o,t))}return fe(n)}function le(t){return pe(t.map(([t,e])=>{const r=K(t,e,0),s=K(t,e,1);return new mt(r,s)}))}function fe(t){return pe(t.map(t=>t?new dt(W(t)):void 0))}function de(t,e){return fe(t.map(([t,r])=>[t,r,e]))}function pe(e){if(0!==e.length)return 1===e.length?e[0]??void 0:new xt(e.filter(t))}function me(t){return t instanceof xt}function ge(t){return t instanceof dt}function _e(t){return t instanceof pt}function xe(t){return t instanceof gt}function Le(t){return t instanceof Mt}function ke(t){return t instanceof qt}function ye(t){return t instanceof Lt}function ve(t){return t instanceof kt}function ze(t){return t instanceof yt}function Me(t){return t instanceof At}function Pe(t){return t instanceof Ut}function qe(t){return t instanceof Ct}function Te(t){return t instanceof Zt}const we=0;export{yt as CircleConstraint,ft as Constraint,Zt as CoordinateConstraint,gt as CurveConstraint,Ut as DrapedLineConstraint,Ct as GeodesicConstraint,kt as HorizontalCircleConstraint,Mt as HorizontalPlaneConstraint,mt as LineConstraint,pt as LineLikeConstraint,dt as PointConstraint,_t as RayConstraint,xt as SetConstraint,At as SphereConstraint,Lt as VerticalCylinderConstraint,bt as VerticalHalfPlaneConstraint,Rt as VerticalPlaneConstraint,qt as VerticalPlaneLikeConstraint,pe as constraintOrSet,xe as isCurve,Pe as isDrapedLine,_e as isLine,ge as isPoint};
|
|
2
|
+
import{isSome as t,equals as e}from"../../../core/arrayUtils.js";import{asinClamped as r}from"../../../core/mathUtils.js";import{exactEquals as s,set as n,dot as i,subtract as o,squaredDistance as c}from"../../../core/libs/gl-matrix-2/math/vec2.js";import{create as u}from"../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{exactEquals as a,set as h,squaredDistance as l,equals as f,copy as d,subtract as p,scaleAndAdd as m,sub as g,squaredLength as _,dot as x,cross as L,normalize as k}from"../../../core/libs/gl-matrix-2/math/vec3.js";import{UNIT_Z as y,create as v,fromValues as z,clone as M}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{set as P,dot as q}from"../../../core/libs/gl-matrix-2/math/vec4.js";import{create as T}from"../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{directGeodeticSolver as w,inverseGeodeticSolver as j,InverseGeodeticSolverResult as D}from"../../../geometry/geodesicUtils.js";import{toRadians as b}from"../../../geometry/support/geodesicConstants.js";import{fromPositionAndNormal as R,create as A,fromPoints as U,intersectLine as Z,signedDistance as C,projectPoint as I,getNormal as O,distance as S}from"../../../geometry/support/plane.js";import{Sphere as E}from"../../../geometry/support/sphere.js";import{closestPointOnCurve as G}from"../../../geometry/support/curves/closestPointOnCurve.js";import{getEndpoint as V,curveEquals as B}from"../../../geometry/support/curves/curveUtils.js";import{tangentFrame as F}from"../../3d/support/mathUtils.js";import{clone as H,create as J,fromValues as K,createWritable as N,asVec2 as Q,fromVec3 as W}from"./normalizedPoint.js";import{projectPointToVerticalCylinder as X,intersectLineLikes as Y,intersectVerticalPlaneAndLineLike as $,intersectLineLikeAndVerticalCylinder as tt,intersectLineLikeAndCircle as et,intersectVerticalPlanes as rt,intersectVerticalPlaneAndVerticalCylinder as st,intersectVerticalCylinders as nt,projectPointToVerticalPlane as it,intersectVerticalPlaneAndPoint as ot,vectorsHaveCloseZ as ct,isClose as ut,isPointInClosedPositiveHalfspace as at,projectPointToLineLike as ht,arePointsInClosedPositiveHalfspace as lt}from"../../support/geometry3dUtils.js";class ft{intersect(t){return Vt(this,t)}closestPoints(t){return[this.closestTo(t)]}}class dt extends ft{constructor(t){super(),this.point=t}equals(t){return this===t||ge(t)&&a(this.point,t.point)}closestTo(){return H(this.point)}}class pt extends ft{constructor(t,e,r){super(),this.start=t,this.end=e,this.lineLike={start:t,end:e,type:r}}equals(t){return this===t||_e(t)&&this.lineLike.type===t.lineLike.type&&a(this.start,t.start)&&a(this.end,t.end)}closestTo(t){const e=N();return ht(t,this.lineLike,e),e}}class mt extends pt{constructor(t,e){super(t,e,1)}}class gt extends ft{constructor(t,e){super(),this.start=t,this.curve=e}closestTo(t){const{curvePoint:e,t:r}=G(this.start,this.curve,t),s=V(this.curve)[2]??0,n=this.start[2]*(1-r)+s*r;return J(e[0],e[1],n)}equals(t){return this===t||xe(t)&&a(this.start,t.start)&&B(this.curve,t.curve)}}class _t extends pt{constructor(t,e){super(t,e,0)}}class xt extends ft{constructor(t){super(),this.constraints=t}equals(t){return this===t||me(t)&&e(this.constraints,t.constraints,(t,e)=>t.equals(e))}closestTo(t){let e,r=1/0;for(const s of this.constraints){const n=s.closestTo(t),i=l(t,n);i<r&&(r=i,e=n)}return H(e??t)}closestPoints(t){return this.constraints.flatMap(e=>e===this?[]:e.closestPoints(t))}}class Lt extends ft{constructor(t,e){super(),this.center=t,this.radius=e}equals(t){return this===t||ye(t)&&this.center[0]===t.center[0]&&this.center[1]===t.center[1]&&this.radius===t.radius}closestTo(t){const e=N();return X(t,this.center,this.radius,e),e}}class kt extends ft{constructor(t,e){super(),this.center=t,this.radius=e}equals(t){return this===t||ve(t)&&a(this.center,t.center)&&this.radius===t.radius}closestTo(t){const e=N();return X(t,this.center,this.radius,e),e[2]=this.center[2],e}asCircle(){return new yt(H(this.center),this.radius,K(0,0,1))}}class yt extends ft{constructor(t,e,r,s){super(),this.center=t,this.radius=e,this.normal=r,this.slicePlane=s}equals(t){return this===t||ze(t)&&a(this.center,t.center)&&a(this.normal,t.normal)&&this.radius===t.radius}closestTo(t){const{center:e,radius:r}=this;I(this.getPlane(zt),t,vt);const s=g(vt,vt,e),n=_(s);if(ut(n,0))return H(t);const i=r/Math.sqrt(n),o=N();m(o,e,s,i);const{slicePlane:c}=this;if(c&&!at(c,o)){const e=Jt(c,this);return e?.closestTo(t)??H(t)}return o}getPlane(t=A()){return R(this.center,this.normal,t)}}const vt=v(),zt=A();class Mt extends ft{constructor(t){super(),this.z=t}equals(t){return this===t||Le(t)&&this.z===t.z}closestTo(t){return K(t[0],t[1],this.z)}getPlane(t=A()){return h(Pt,0,0,this.z),R(Pt,y,t)}}const Pt=v();class qt extends ft{constructor(t,e,r){super(),this.start=t,this.end=e,this.planeLike={start:Q(t),end:Q(e),type:r}}equals(t){return this===t||ke(t)&&this.planeLike.type===t.planeLike.type&&a(this.start,t.start)&&a(this.end,t.end)}closestTo(t){const e=N();return it(t,this.planeLike,e),e}closestEndTo(t){const{start:e,end:r}=this.planeLike;return Math.sign(i(o(Tt,r,e),o(wt,Q(t),e)))>0?this.end:this.start}getPlane(t=A()){const e=d(jt,this.end);return e[2]+=1,U(this.start,this.end,e,t)}getSlicePlane(t=A()){const{start:e,end:r,type:s}=this.planeLike;if(0===s)return;const n=h(jt,e[0],e[1],0),i=h(Dt,r[0],r[1],0),o=p(Dt,i,n);return R(n,o,t),t}}const Tt=u(),wt=u(),jt=v(),Dt=v();class bt extends qt{constructor(t,e){super(t,e,1)}}class Rt extends qt{constructor(t,e){super(t,e,0)}}class At extends ft{constructor(t,e){super(),this.sphere=new E(t,e),this._center=M(t)}equals(t){return this===t||Me(t)&&this.sphere.exactEquals(t.sphere)}closestTo(t){const e=N();return this.sphere.projectPoint(t,e),e}get center(){return this._center}get radius(){return this.sphere.radius}}class Ut extends ft{constructor(t,e,r){super(),this.start=t,this.end=e,this.getZ=r,this.planeLike={start:Q(t),end:Q(e),type:0}}equals(t){return this===t||Pe(t)&&a(this.start,t.start)&&a(this.end,t.end)&&this.getZ===t.getZ}closestTo(t){return Gt(this,t)}addIfOnTheGround(t,e){for(const r of e){const e=this.getZ(r[0],r[1])??0;ut(r[2],e)&&(r[2]=e,t.push(r))}}}class Zt extends ft{constructor(t,e,r){super(),this._x=t,this._y=e,this._z=r}equals(t){return this===t||Te(t)&&this._x===t._x&&this._y===t._y&&this._z===t._z}closestTo([t,e,r]){return J(this._x??t,this._y??e,this._z??r)}}class Ct extends ft{constructor(t,e,r,s,n){super(),this._origin=t,this._spatialReference=e,this._distanceMeters=r,this._z=s,this._directionDegrees=n}equals(t){return this===t||qe(t)&&s(this._origin,t._origin)&&this._spatialReference===t._spatialReference&&this._distanceMeters===t._distanceMeters&&this._z===t._z&&this._directionDegrees===t._directionDegrees}closestTo([t,e,r]){return n(It,t,e),s(It,this._origin)||this._applyDirectionAndDistance(It),J(It[0],It[1],this._z??r)}_applyDirectionAndDistance(t){if(null!=this._directionDegrees&&null!=this._distanceMeters)w(t,this._origin,this._directionDegrees,this._distanceMeters,this._spatialReference);else if(null!=this._directionDegrees)St(t,this._origin,this._directionDegrees,t,this._spatialReference);else if(null!=this._distanceMeters){const{azimuth:e}=j(Ot,this._origin,t,this._spatialReference);w(t,this._origin,e??0,this._distanceMeters,this._spatialReference)}}}const It=[0,0],Ot=new D;function St(t,e,r,s,n){let{azimuth:i,distance:o}=j(Et,e,s,n);i??=0;let c=o*Math.cos((i-r)*b);c=Math.max(0,c),w(t,e,r,c,n)}const Et=new D;function Gt(t,e){const r=N();return it(e,t.planeLike,r),r[2]=t.getZ(r[0],r[1])??we,r}function Vt(t,e){if(me(t)){const r=[];for(const s of t.constraints){const t=s.intersect(e);t&&r.push(t)}return pe(r)}if(me(e))return Vt(e,t);if(Pe(t))return he(t,e);if(Pe(e))return he(e,t);if(ge(t)){const{point:r}=t;if(ge(e))return a(r,e.point)?t:void 0;const s=e.closestTo(r);return f(s,r)?t:void 0}if(_e(t)){if(ge(e))return Vt(e,t);if(_e(e))return fe(Y(t.lineLike,e.lineLike));if(Le(e))return Bt(t,e);if(ke(e))return fe($(e.planeLike,t.lineLike));if(ye(e))return fe(tt(t.lineLike,e.center,e.radius));if(ze(e))return fe(et(t.lineLike,e));if(ve(e))return Ft(t,e);if(Me(e))return Ht(t,e)}else if(xe(t)){if(ge(e))return Vt(e,t)}else if(Le(t)){if(ge(e)||_e(e))return Vt(e,t);if(Le(e))return Kt(t,e);if(ke(e))return Nt(t,e);if(ye(e))return Qt(t,e);if(ze(e))return Xt(t,e);if(ve(e))return Wt(t,e);if(Me(e))return Yt(t,e)}else if(ke(t)){if(ge(e)||_e(e)||Le(e))return Vt(e,t);if(ke(e))return le(rt(t.planeLike,e.planeLike));if(ye(e))return le(st(t.planeLike,e.center,e.radius));if(ze(e))return te(t,e);if(ve(e))return $t(t,e);if(Me(e))return ee(t,e)}else if(ye(t)){if(ge(e)||_e(e)||Le(e)||ke(e))return Vt(e,t);if(ye(e))return le(nt(Q(t.center),t.radius,Q(e.center),e.radius));if(ze(e))return re();if(ve(e))return se(t,e);if(Me(e))return ne()}else if(ze(t)){if(ge(e)||_e(e)||Le(e)||ke(e)||ye(e))return Vt(e,t);if(ze(e))return ie();if(ve(e))return ie(e.asCircle());if(Me(e))return oe()}else if(ve(t)){if(ge(e)||_e(e)||Le(e)||ke(e)||ye(e)||ze(e))return Vt(e,t);if(ve(e))return ce(e,t);if(Me(e))return ue()}else if(Me(t)){if(ge(e)||_e(e)||Le(e)||ke(e)||ye(e)||ve(e))return Vt(e,t);if(Me(e))return ae()}}const Bt=(()=>{const t=A();return(e,r)=>{const{start:s,end:n}=e;if(ct(s,n)&&ut(s[2],r.z))return e;const i=N();return Z(r.getPlane(t),s,n,i)?new dt(i):void 0}})();function Ft({lineLike:t},{center:e,radius:r}){const s=e[2];return fe(tt(t,e,r).filter(t=>ut(t[2],s)))}function Ht({lineLike:t},{sphere:e}){return fe(e.intersectLine(t.start,t.end))}const Jt=(()=>{const t=T(),e=v(),s=v();return(n,i,o)=>{const{normal:c,center:u,radius:a}=i;F(c,e,s);const h=O(n),l=a*x(h,e),f=a*x(h,s);P(t,u[0],u[1],u[2],1);const d=q(n,t),p=Math.hypot(l,f),g=ut(p,0);if(ut(S(n,u),0)){if(g)return i;if(ut(a,0))return!o||at(o,u)?new dt(H(u)):void 0;L(e,h,c),k(e,e);const t=new Array,r=M(u);m(r,r,e,a),o&&!at(o,r)||t.push(r);const s=M(u);return m(s,s,e,-a),o&&!at(o,s)||t.push(s),fe(t)}if(g)return;const _=-d/p;if(Math.abs(_)>1||ut(_,1))return;const y=Math.atan(l/f),z=r(_)-y,T=Math.PI-z,w=new Array,j=v();m(j,u,e,a*Math.cos(z)),m(j,j,s,a*Math.sin(z)),w.push(j);const D=v();return m(D,u,e,a*Math.cos(T)),m(D,D,s,a*Math.sin(T)),w.push(D),fe(o?lt(o,w):w)}})();function Kt(t,e){return ut(t.z,e.z)?t:void 0}function Nt({z:t},{planeLike:e}){const[r,s]=e.start,[n,i]=e.end,o=K(r,s,t),c=K(n,i,t);return 0===e.type?new mt(o,c):new _t(o,c)}function Qt(t,e){const[r,s]=e.center;return new kt(K(r,s,t.z),e.radius)}function Wt(t,e){return ut(e.center[2],t.z)?e:void 0}const Xt=(()=>{const t=A();return(e,r)=>Jt(e.getPlane(t),r,r.slicePlane)})();function Yt(t,{center:e,radius:r}){const s=Math.abs(e[2]-t.z);if(s>r&&!ut(s,r))return;const n=K(e[0],e[1],t.z),i=Math.sqrt(r**2-s**2);return ut(i,0)?void 0:new kt(n,i)}const $t=(()=>{const t=A();return(e,{center:r,radius:s})=>{const n=st(e.planeLike,r,s),i=r[2];e.getSlicePlane(t);const o=new Array;for(const[c,u]of n){const e=[c,u,i];at(t,e)&&o.push(e)}return fe(o)}})(),te=(()=>{const t=A(),e=A();return(r,s)=>Jt(r.getPlane(t),s,r.getSlicePlane(e))})(),ee=(()=>{const t=A();return(e,{center:r,radius:s})=>{const n=e.getPlane(t),i=C(n,r),o=Math.abs(i);if(o>s&&!ut(o,s))return;const c=Math.sqrt(s**2-i**2);if(ut(c,0)){const t=N();return I(n,r,t),new dt(t)}const u=N(),a=M(O(n));return m(u,r,a,i),new yt(u,c,a,e.getSlicePlane())}})();function re(t,e){}function se(t,e){const r=c(Q(t.center),Q(e.center));if(ut(r,0)&&ut(t.radius,e.radius))return e;return de(nt(Q(t.center),t.radius,Q(e.center),e.radius),e.center[2])}function ne(t,e){}function ie(t,e){}function oe(t,e){}function ce(t,e){if(!ct(t.center,e.center))return;const r=c(Q(t.center),Q(e.center));if(ut(r,0)&&ut(t.radius,e.radius))return t;return de(nt(Q(t.center),t.radius,Q(e.center),e.radius),t.center[2])}function ue(t,e){}function ae(t,e){}function he(t,e){const{planeLike:r,getZ:s}=t,n=new Array;if(ge(e))t.addIfOnTheGround(n,ot(r,e.point));else if(_e(e))t.addIfOnTheGround(n,$(r,e.lineLike));else if(ye(e))for(const[i,o]of st(r,e.center,e.radius)){const t=s(i,o);null!=t&&n.push(z(i,o,t))}else if(ke(e)||Pe(e))for(const[i,o]of rt(r,e.planeLike)){const t=s(i,o)??we;n.push(z(i,o,t))}return fe(n)}function le(t){return pe(t.map(([t,e])=>{const r=K(t,e,0),s=K(t,e,1);return new mt(r,s)}))}function fe(t){return pe(t.map(t=>t?new dt(W(t)):void 0))}function de(t,e){return fe(t.map(([t,r])=>[t,r,e]))}function pe(e){if(0!==e.length)return 1===e.length?e[0]??void 0:new xt(e.filter(t))}function me(t){return t instanceof xt}function ge(t){return t instanceof dt}function _e(t){return t instanceof pt}function xe(t){return t instanceof gt}function Le(t){return t instanceof Mt}function ke(t){return t instanceof qt}function ye(t){return t instanceof Lt}function ve(t){return t instanceof kt}function ze(t){return t instanceof yt}function Me(t){return t instanceof At}function Pe(t){return t instanceof Ut}function qe(t){return t instanceof Ct}function Te(t){return t instanceof Zt}const we=0;export{yt as CircleConstraint,ft as Constraint,Zt as CoordinateConstraint,gt as CurveConstraint,Ut as DrapedLineConstraint,Ct as GeodesicConstraint,kt as HorizontalCircleConstraint,Mt as HorizontalPlaneConstraint,mt as LineConstraint,pt as LineLikeConstraint,dt as PointConstraint,_t as RayConstraint,xt as SetConstraint,At as SphereConstraint,Lt as VerticalCylinderConstraint,bt as VerticalHalfPlaneConstraint,Rt as VerticalPlaneConstraint,qt as VerticalPlaneLikeConstraint,pe as constraintOrSet,xe as isCurve,Pe as isDrapedLine,_e as isLine,ge as isPoint};
|
package/views/popupAdapter.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
const e="popup",n="manual";function
|
|
2
|
+
const e="popup",n="manual";function t(e){const{popupElement:n,popup:t}=e||{};return n??t??null}function o(e){return null!=e&&"open"in e&&"declaredClass"in e}function i(e){return!!e&&"arcgis-popup"===e.tagName.toLowerCase()&&"open"in e}function p(t,p,a){const[u,l,c]=p;if(a){const[n,t,p]=a;n&&o(t)&&(t.view=null,n.remove(t,e),t!==l&&l&&t.destroy()),n&&p&&i(p)&&(p.view=null,n.remove(p,e),p!==c&&c&&p.remove())}u&&o(l)&&(l.view=t,u.add(l,{key:e,position:n,internal:!0})),u&&c&&i(c)&&(c.view=t,u.add(c,{key:e,position:n,internal:!0}))}async function a(e,n){const{popup:t,popupElement:p}=e;o(t)?await s(e,t,null,n):p&&i(p)?await s(e,null,p,n):n?.defer(async()=>{await e.setupPopup();const{popup:t,popupElement:p}=e;o(t)&&!e.destroyed&&e.ready&&e.popupEnabled?await s(e,t,null,n):p&&i(p)&&await s(e,null,p,n)}).catch(()=>{})}function u(e,n){const{popup:t,popupElement:p}=e;if(o(t))return t.open(n);if(p&&i(p)){if(n){const{fetchFeatures:e,title:t,...o}=n;delete n.fetchFeatures,Object.assign(p,o),void 0!==t&&(p.heading=t)}p.open=!0}}function l(e,n){o(e)&&e.close(),n&&i(n)&&(n.visible=!1)}async function c(e,n,t,o){const i=e.fetchPopupFeatures(t.screenPoint,{pointerType:t.pointerType});o?await o.open({location:t.mapPoint??void 0,featureStream:i}):(n.location=t.mapPoint??null,n.featureStream=i,n.open=!0)}async function s(e,n,t,p){if(o(n)){const e=await n.viewModel.handleViewClick(p);return void(e?.promises?.length?n.open(e):n.visible&&n.close())}t&&i(t)&&await c(e,t,p)}export{p as addPopup,l as closePopup,c as handlePopupElementClick,o as isPopup,i as isPopupElement,u as openPopupWithOptions,a as openPopupWithViewClick,t as popupFromView};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{max as
|
|
2
|
+
import{max as e,createLength as t,createArea as o}from"../../core/quantity.js";import{deriveLengthUnitFromAreaUnit as r}from"../../core/units.js";import{set as n,scale as i,normalize as s,cross as a,subtract as m,dot as c,add as f}from"../../core/libs/gl-matrix-2/math/vec3.js";import{create as p}from"../../core/libs/gl-matrix-2/factories/vec3f64.js";import{isEarth as u,isSphericalECEF as l}from"../../geometry/ellipsoidUtils.js";import g from"../../geometry/Multipoint.js";import y from"../../geometry/Point.js";import O from"../../geometry/Polygon.js";import S from"../../geometry/Polyline.js";import{projectWithoutEngine as J}from"../../geometry/projectionUtils.js";import N from"../../geometry/SpatialReference.js";import{WGS84ECEFSpatialReference as h,getSphericalPCPF as d,SphericalECEFSpatialReference as j}from"../../geometry/spatialReferenceEllipsoidUtils.js";import{execute as R}from"../../geometry/operators/areaOperator.js";import{execute as w}from"../../geometry/operators/centroidOperator.js";import{execute as x}from"../../geometry/operators/distanceOperator.js";import{load as v,execute as P}from"../../geometry/operators/geodeticAreaOperator.js";import{load as U,execute as L}from"../../geometry/operators/geodeticDistanceOperator.js";import{load as M,execute as b}from"../../geometry/operators/geodeticLengthOperator.js";import{execute as k}from"../../geometry/operators/lengthOperator.js";import{execute as C}from"../../geometry/operators/simplifyOperator.js";import{projectDirection as E}from"../../geometry/projection/projectDirection.js";import{fromJSON as q}from"../../geometry/support/jsonUtils.js";import{isWGS84 as z,isWebMercator as Z,isCGCS2000 as D,equals as W}from"../../geometry/support/spatialReferenceUtils.js";import{makeOrthonormal as $}from"../3d/support/mathUtils.js";import{autoMeasurementMode as A}from"./measurementWorkerUtils.js";async function I({geometryJSON:e,options:t}){await Promise.allSettled([v(),t?.returnLength?M():void 0]);const n=F(e,t),i=t?.unit??"square-meters",s=C(n)??n,a=P(s,{unit:i,...t}),m=o(a,i),c=t?.lengthUnit??r(i);return{area:m,centroid:t?.returnCentroid?G(s).toJSON():void 0,length:t?.returnLength?await H(s,{unit:c}):void 0}}function B(){v(),M(),U()}function F(e,t){const o="rings"in e?O.fromJSON(e):S.fromJSON(e);if(t?.stagedPoint){const e=y.fromJSON(t.stagedPoint),r=("rings"in o?o.rings:o.paths).at(-1);if(r){const{x:t,y:n,z:i,m:s}=e,a=o.hasZ&&o.hasM?[t,n,i??0,s??0]:o.hasZ?[t,n,i??0]:o.hasM?[t,n,s??0]:[t,n];r.push(a)}}return o}function G(e){return w(e)}async function H(e,o){await M();const r=o?.unit??"meters";return t(b(e,{...o,unit:r}),r)}function K({geometryJSON:e,options:t}){return H(F(e,t),t)}async function Q({geometry1JSON:e,geometry2JSON:o,options:r}){await U();const n=y.fromJSON(e),i=y.fromJSON(o),s=r?.unit??"meters";return t(L(n,i,{...r,unit:s}),s)}async function T({geometry1JSON:e,geometry2JSON:o,options:r}){await U();const n=g.fromJSON(e),i=g.fromJSON(o);if(n.points.length!==i.points.length)throw new Error("Input multipoints must have the same number of points.");const s=n.points.length,a=r?.unit??"meters",m=[],c={...r,unit:a};for(let f=0;f<s;f++){const e=n.getPoint(f),o=i.getPoint(f);m.push(null!=e&&null!=o?t(L(e,o,c),a):null)}return m}function V({geometryJSON:e,options:t}){return X(F(e,t),t)}function X(e,t){const n=t?.unit??"square-meters",i=t?.lengthUnit??r(n),s=C(e)??e,a=R(s,{unit:n,...t});return{area:o(a,n),centroid:t?.returnCentroid?G(s).toJSON():void 0,length:t?.returnLength?Y(s,{unit:i}):void 0}}function Y(e,o){const r=o?.unit??"meters";return t(k(e,{...o,unit:r}),r)}function _({geometryJSON:e,options:t}){return Y(F(e,t),t)}function ee({geometry1JSON:e,geometry2JSON:o,options:r}){const n=y.fromJSON(e),i=y.fromJSON(o),s=r?.unit??"meters";return t(x(n,i,{...r,unit:s}),s)}async function te(e){return ie(e.geometryJSON.spatialReference,I,V)(e)}async function oe(e){return ie(e.geometryJSON.spatialReference,K,_)(e)}async function re(e){return ie(e.geometry1JSON.spatialReference,Q,ee)(e)}async function ne(t){const o=ie(t.topLeftJSON.spatialReference,Q,ee),{topLeftJSON:r,topRightJSON:n,bottomRightJSON:i,bottomLeftJSON:s,options:a}=t,[m,c,f,p]=await Promise.all([o({geometry1JSON:s,geometry2JSON:i,options:a}),o({geometry1JSON:r,geometry2JSON:n,options:a}),o({geometry1JSON:i,geometry2JSON:n,options:a}),o({geometry1JSON:s,geometry2JSON:r,options:a})]);return{width:e(m,c),height:e(p,f)}}function ie(e,t,o){switch(A(e)){case 0:return t;case 1:return o}}function se(e){const{geometryJSON:t}=e,o=pe(t.spatialReference);if(!o)throw new Error("Cannot compute horizontal area without a valid spatial reference.");switch(o.mode){case 0:return V(e);case 1:return me(o,e)}}function ae({geometryJSON:e}){const t=q(e);if(!t)return null;const o=C(t);return o?o.toJSON():null}function me(e,{geometryJSON:t,options:o}){const r=F(t,o),n=ge,i=ue,s=le,a=W(r.spatialReference,e.spatialReference)?r.clone():J(r,r.spatialReference,e.spatialReference);if(!a)throw new Error(`Cannot project geometry from ${r.spatialReference?.wkid??"unknown"} to ${e.spatialReference.wkid}.`);fe(a,n,i,s);const{area:m,centroid:c,length:f}=X(a,o);return{area:m,centroid:ce(c,n,i,s,e.spatialReference,r.spatialReference),length:f}}function ce(e,t,o,r,n,s){if(!e)return e;i(o,o,e.x),i(r,r,e.y);const a=ye;return f(a,o,r),f(a,a,t),e.x=a[0],e.y=a[1],e.z=a[2],e.spatialReference=n,J(e,e.spatialReference,s)?.toJSON()??void 0}function fe(e,t,o,r){let f=0;n(t,0,0,0);for(const n of e.rings)for(const e of n)t[0]+=e[0],t[1]+=e[1],t[2]+=e[2],f++;i(t,t,1/f);const p=Oe;s(p,t);const u=Se,l=Math.atan2(p[1],p[0]);n(u,-Math.sin(l),Math.cos(l),0),W(e.spatialReference,h)&&(E(t,p,j,p,e.spatialReference),E(t,u,j,u,e.spatialReference)),$(u,p,o),a(r,o,p);const g=ye;for(const i of e.rings)for(const e of i){n(g,e[0],e[1],e[2]),m(g,g,t);const i=c(o,g),s=c(r,g);e[0]=i,e[1]=s}e.hasZ=!1,e.spatialReference=N.WebMercator}function pe(e){return e?u(e)?z(e)||Z(e)||D(e)||l(e)||W(e,h)?{mode:1,spatialReference:h}:{mode:0,spatialReference:e}:{mode:1,spatialReference:d(e)}:null}const ue=p(),le=p(),ge=p(),ye=p(),Oe=p(),Se=p();export{V as area2D,se as areaHorizontal,te as autoArea2D,re as autoDistance2DBetweenPoints,oe as autoLength2D,ne as autoSize2D,ee as distance2DBetweenPoints,I as geodeticArea,Q as geodeticDistanceBetweenPoints,T as geodeticDistanceBetweenPointsMany,K as geodeticLength,_ as length2D,B as preloadGeodetic,ae as simplify};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{floatEqualAbsolute as t}from"../../core/mathUtils.js";import{subtract as
|
|
2
|
+
import{floatEqualAbsolute as t}from"../../core/mathUtils.js";import{subtract as n,length as r,scaleAndAdd as s,sub as e,dot as o,squaredLength as c,lerp as i,set as u,squaredDistance as a,distance as f}from"../../core/libs/gl-matrix-2/math/vec2.js";import{create as p,fromValues as m,ZEROS as d}from"../../core/libs/gl-matrix-2/factories/vec2f64.js";import{sub as l,cross as h,dot as y,sqrLen as b,scaleAndAdd as j,set as M,subtract as g,copy as x,distance as v,len as q}from"../../core/libs/gl-matrix-2/math/vec3.js";import{create as A,clone as P}from"../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getEpsilon as U}from"../../core/libs/gl-matrix-2/math/common.js";import{fromPositionAndNormal as C,distance as L,intersectLine as k,create as w,isPointInClosedPositiveHalfspace as H}from"../../geometry/support/plane.js";import{tangentFrame as I}from"../3d/support/mathUtils.js";import{intersectLineLikeAndCircle as z}from"./geometry2dUtils.js";function B({start:t,end:r,type:e},i,u){const a=[],f=n(rt,r,t),m=n(st,t,i),d=c(f),l=2*o(f,m),h=l*l-4*d*(c(m)-u*u);if(0===h){const n=-l/(2*d);(0===e||n>=0)&&a.push(s(p(),t,f,n))}else if(h>0){const n=Math.sqrt(h),r=(-l+n)/(2*d);(0===e||r>=0)&&a.push(s(p(),t,f,r));const o=(-l-n)/(2*d);(0===e||o>=0)&&a.push(s(p(),t,f,o))}return a}function D(t,r){const s=t.start,c=t.end,i=n(rt,c,s),u=M(ot,-i[1],i[0],0),a=r.start,f=r.end,p=l(ct,f,a),m=y(p,u),d=M(it,s[0],s[1],0),h=l(ut,d,a),b=y(h,u),g=U();if(Math.abs(m)<g)return Math.abs(b),[];const x=j(at,a,p,b/m);if(0===r.type){const t=l(ft,x,a);if(y(t,p)<-g)return[]}if(1===t.type){const t=e(st,x,s);if(o(t,i)<-g)return[]}return[P(x)]}function E(t,n){return V(Y(mt,n[2],t),n)}function F(t,n){const r=0;return T(Y(mt,r,t),Y(dt,r,n)).map(([t,n])=>m(t,n))}function G(t,n,r){return O(t,Y(mt,t[2],n),r)}function J(t,n){return Q(Y(mt,t[2],n),t)}function K(t,e,o,c=A()){const i=n(rt,t,e),u=r(i);return s(c,e,i,0===u?1:o/u),c[2]=t[2],c}function N(t,n,r){return f(t,n)-r}function O(t,{start:n,end:r,type:s},e=A()){const o=l(et,t,n),c=l(ot,r,n),i=y(o,c)/y(c,c);return j(e,n,c,0===s?Math.max(i,0):i)}function Q({start:t,end:n,type:r},s){const e=l(et,s,t),o=l(ot,n,t);if(0===r&&y(o,e)<-U())return v(t,s);const c=h(ct,o,e);return q(c)/q(o)}const R=(()=>{const t=A(),n=A(),r=A();return({start:s,end:e},{center:o,radius:c,normal:i,slicePlane:a})=>{const f=C(o,i,pt);if($(L(f,s),0)&&$(L(f,e),0)){I(i,t,n);const f=(s,e)=>(g(r,e,o),u(s,y(r,t),y(r,n)),s),p=z({start:f(rt,s),end:f(st,e),type:1},d,c),m=[];for(const[r,s]of p){const e=x(A(),o);j(e,e,t,r),j(e,e,n,s),a&&!tt(a,e)||m.push(e)}return m}const p=A();return k(f,s,e,p)?!$(v(p,o),c)||a&&!tt(a,p)?[]:[p]:[]}})();function S({start:t,end:r,type:s},e,i){const u=[],a=g(et,r,t),f=n(st,t,e),p=c(a),m=2*o(a,f),d=m*m-4*p*(c(f)-i*i);if(0===d){const n=-m/(2*p);(1===s||n>=0)&&u.push(j(A(),t,a,n))}else if(d>0){const n=Math.sqrt(d),r=(-m+n)/(2*p);(1===s||r>=0)&&u.push(j(A(),t,a,r));const e=(-m-n)/(2*p);(1===s||e>=0)&&u.push(j(A(),t,a,e))}return u}function T(t,n){const r=t.start,s=t.end,e=n.start,o=n.end,c=l(et,s,r),i=l(ot,o,e),u=l(ct,e,r),a=h(it,c,i);if(!$(y(u,a),0))return[];const f=b(a);if($(f,0))return[];const p=h(ut,u,i),m=y(p,a)/f,d=j(at,r,c,m);if(0===t.type){const t=l(ft,d,r);if(y(c,t)<-U())return[]}if(0===n.type){const t=l(ft,d,e);if(y(i,t)<-U())return[]}return[P(d)]}function V({start:t,end:n,type:r},s){const e=l(et,s,t),o=l(ot,n,t),c=h(ct,o,e),i=b(c)/b(o),u=U();if(i<u)switch(r){case 1:return[P(s)];case 0:return y(o,e)<-u?[]:[P(s)]}return[]}function W(t,n,r){return $(a(r,t),n*n)?[P(r)]:[]}function X(t,n,r,s){const[e,o]=t,[c,u]=r,a=c-e,f=u-o,p=a*a+f*f,d=Math.sqrt(p);if(d>n+s)return[];if(d<Math.abs(n-s))return[];if($(d,0)&&$(n,s))return[];const l=(n*n-s*s+p)/(2*d),h=Math.sqrt(n*n-l*l),y=h*f/d,b=h*a/d,[j,M]=i(rt,t,r,l/d);return $(y,b)?[m(j,M)]:[m(j+y,M-b),m(j-y,M+b)]}function Y(t,n,{start:r,end:s,type:e}){return M(t.start,r[0],r[1],n),M(t.end,s[0],s[1],n),t.type=nt[e],t}function Z(t,n){return $(t[2],n[2])}function $(n,r){return t(Math.abs(n-r),0,U())}function _(t,n){return n.filter(n=>tt(t,n))}function tt(t,n){return H(t,n)}const nt={0:1,1:0},rt=p(),st=p(),et=A(),ot=A(),ct=A(),it=A(),ut=A(),at=A(),ft=A(),pt=w(),mt={start:A(),end:A(),type:1},dt={start:A(),end:A(),type:1};export{_ as arePointsInClosedPositiveHalfspace,V as intersectLineAndPoint,R as intersectLineLikeAndCircle,S as intersectLineLikeAndVerticalCylinder,T as intersectLineLikes,W as intersectVerticalCylinderAndPoint,X as intersectVerticalCylinders,D as intersectVerticalPlaneAndLineLike,E as intersectVerticalPlaneAndPoint,B as intersectVerticalPlaneAndVerticalCylinder,F as intersectVerticalPlanes,$ as isClose,tt as isPointInClosedPositiveHalfspace,Q as pointToLineLikeDistance,N as pointToVerticalCylinderDistance,J as pointToVerticalPlaneDistance,O as projectPointToLineLike,K as projectPointToVerticalCylinder,G as projectPointToVerticalPlane,Z as vectorsHaveCloseZ};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
function e(e){return!(null==e||"object"!=typeof e||!("id"in e)||!("type"in e))}function n(n){return!!(e(n)&&"on"in n&&n.on)}function r(n){return!!(e(n)&&"graphics"in n&&n.graphics)}function i(n){return!!(e(n)&&"fields"in n&&"fieldsIndex"in n&&"objectIdField"in n&&"createQuery"in n&&n.createQuery&&"queryFeatures"in n&&n.queryFeatures)}function t(e){return i(e)||r(e)}function u(n){return!!(null!=n&&"object"==typeof n&&"layer"in n&&n.layer&&e(n.layer)&&"view"in n)}function c(e){return!(!u(e)||!("queryGraphics"in e))}function o(e){return!!(u(e)&&"highlight"in e&&e.highlight)}function
|
|
2
|
+
function e(e){return!(null==e||"object"!=typeof e||!("id"in e)||!("type"in e))}function n(n){return!!(e(n)&&"on"in n&&n.on)}function r(n){return!!(e(n)&&"graphics"in n&&n.graphics)}function i(n){return!!(e(n)&&"fields"in n&&"fieldsIndex"in n&&"objectIdField"in n&&"createQuery"in n&&n.createQuery&&"queryFeatures"in n&&n.queryFeatures)}function t(e){return i(e)||r(e)}function u(n){return!!(null!=n&&"object"==typeof n&&"layer"in n&&n.layer&&e(n.layer)&&"view"in n)}function c(e){return!(!u(e)||!("queryGraphics"in e))}function o(e){return!!(u(e)&&"highlight"in e&&e.highlight)}function l(e){return!!(u(e)&&"createQuery"in e&&e.createQuery&&"queryFeatures"in e&&e.queryFeatures)}function a(e){return l(e)||c(e)}function f(e,n){return!(null==e||"object"!=typeof e||!("isTable"in e)||!e.isTable)||!!n?.map?.allTables.includes(e)}export{t as isSelectableLayer,e as isSelectableLayerBase,n as isSelectableLayerBaseWithEditing,a as isSelectableLayerView,u as isSelectableLayerViewBase,c as isSelectableLayerViewWithGraphics,o as isSelectableLayerViewWithHighlights,l as isSelectableLayerViewWithObjectIds,r as isSelectableLayerWithGraphics,i as isSelectableLayerWithObjectIds,f as isTableLayer};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{__decorate as e}from"tslib";import t from"../../Graphic.js";import{fetchMessageBundle as r,onLocaleChange as i}from"../../intl.js";import{multiplyOpacity as s,getContrast as a}from"../../core/colorUtils.js";import{destroyMaybe as n}from"../../core/maybe.js";import{watch as o,initial as m}from"../../core/reactiveUtils.js";import{formatDecimal as l,formatImperialArea as p,formatMetricArea as c,formatImperialLength as h,formatMetricLength as u}from"../../core/unitFormatUtils.js";import{convertUnit as d,deriveLengthUnitFromAreaUnit as v}from"../../core/units.js";import{property as y,subclass as g}from"../../core/accessorSupport/decorators.js";import{UpdatingHandles as f}from"../../core/support/UpdatingHandles.js";import{isSupported as _,geodesicDensify as w,geodesicLengths as b,geodesicAreas as L}from"../../geometry/geodesicUtils.js";import j from"../../geometry/Point.js";import S from"../../geometry/Polygon.js";import A from"../../geometry/Polyline.js";import{e as k}from"../../chunks/areaOperator.js";import{e as G,l as x}from"../../chunks/geodeticAreaOperator.js";import{e as M,l as O}from"../../chunks/geodeticDensifyOperator.js";import{e as C,l as H}from"../../chunks/geodeticLengthOperator.js";import{e as R}from"../../chunks/lengthOperator.js";import{e as T}from"../../chunks/simplifyOperator.js";import{polygonCentroidPoint as U}from"../../geometry/support/centroid.js";import q from"../../layers/GraphicsLayer.js";import z from"../../symbols/Font.js";import D from"../../symbols/SimpleFillSymbol.js";import P from"../../symbols/SimpleLineSymbol.js";import E from"../../symbols/SimpleMarkerSymbol.js";import V from"../../symbols/TextSymbol.js";import{SnappingVisualizer2D as F}from"../../views/2d/interactive/SnappingVisualizer2D.js";import W from"../../views/draw/Draw.js";import{createCoordinateHelper as I}from"../../views/interactive/coordinateHelper.js";import{createManipulatorDragEventPipeline as B,screenToMap as J,dragManipulatedObject as N}from"../../views/interactive/dragEventPipeline.js";import{GraphicManipulator as K}from"../../views/interactive/GraphicManipulator.js";import{InteractiveToolBase as Q}from"../../views/interactive/InteractiveToolBase.js";import{EditGeometry as X}from"../../views/interactive/editGeometry/EditGeometry.js";import{EditGeometryOperations as Y}from"../../views/interactive/editGeometry/EditGeometryOperations.js";import{SnappingContext as Z}from"../../views/interactive/snapping/SnappingContext.js";import{createSnapDragEventPipelineStep as $}from"../../views/interactive/snapping/SnappingDragPipelineStep.js";import{setupSnappingToggleHandles as ee}from"../../views/interactive/snapping/snappingUtils.js";const te=1e5;let re=class extends Q{constructor(e){super(e),this._measurementLayer=new q({internal:!0,listMode:"hide",visible:!1,title:"Area measurement layer"}),this._manipulatorLayer=new q({internal:!0,listMode:"hide",visible:!1,title:"Area measurement manipulator layer"}),this._snappingLayer=new q({internal:!0,listMode:"hide",visible:!1,title:"Area measurement snapping layer"}),this._updatingHandles=new f,this._vertices=[],this._drawActive=!1,this.measurement=null,this.measurementLabel=null}initialize(){r("esri/core/t9n/Units").then(e=>{this.messages=e});const e=this.view;this._draw=new W({view:e}),e.map.addMany([this._measurementLayer,this._manipulatorLayer,this._snappingLayer]),e.focus(),this.addHandles([i(async()=>{this.messages=await r("esri/core/t9n/Units")}),o(()=>[this.unit,this.messages],()=>{this._updateGraphics()},m),o(()=>[this.view.effectiveTheme.accentColor,this.view.effectiveTheme.textColor],()=>{if(!this._vertices.length)return;const e=this._vertices.map(({coord:e})=>e);for(const{handle:t}of this._vertices)t.remove();this._vertices=[],this._measurementLayer.removeAll(),this._manipulatorLayer.removeAll(),this._snappingLayer.removeAll(),this.manipulators.removeAll(),this._updateSketch(e)})]),ee(this)}destroy(){const{map:e}=this.view;this._draw.view=null,this._draw=n(this._draw),e.removeMany([this._measurementLayer,this._manipulatorLayer,this._snappingLayer]),this._measurementLayer.removeAll(),this._manipulatorLayer.removeAll(),this._snappingLayer.removeAll(),this._set("measurement",null),this._set("measurementLabel",null),this._measurementLayer=n(this._measurementLayer),this._manipulatorLayer=n(this._manipulatorLayer),this._snappingLayer=n(this._snappingLayer),this._updatingHandles=n(this._updatingHandles),this._resetVertices()}get cursor(){return this._drawActive?"crosshair":null}set editable(e){this._set("editable",e),e||this._draw.reset()}get snappingOptions(){return this.snappingManager.options}get updating(){return this._updatingHandles.updating||this.snappingManager.updating}onActivate(){this._drawActive||0!==this._vertices.length||this._startSketch()}onShow(){this._measurementLayer.visible=!0,this._manipulatorLayer.visible=!0,this._snappingLayer.visible=!0}onHide(){this._measurementLayer.visible=!1,this._manipulatorLayer.visible=!1,this._snappingLayer.visible=!1}reset(){this.manipulators.removeAll(),this._resetVertices(),this._measurementLayer.removeAll(),this._manipulatorLayer.removeAll(),this._set("measurement",null),this._set("measurementLabel",null),this._draw.reset(),this._drawActive=!1}_getSnappingContext(e){return new Z({elevationInfo:{mode:"on-the-ground",offset:0},pointer:e,editGeometryOperations:new Y(new X("point",I(!1,!1,this.view.spatialReference)),2),visualizer:new F(this._snappingLayer)})}_resetVertices(){for(const{handle:e}of this._vertices)e.remove();this._vertices=[]}_startSketch(){this._drawActive=!0;const{snappingManager:e}=this;this._draw.create("polyline",{mode:"click",snappingManager:e}).on(["draw-complete","vertex-add","vertex-update","vertex-remove","cursor-update","undo","redo"],e=>{this._updateSketch(e.vertices),"draw-complete"===e.type&&this._stopSketch()})}_stopSketch(){if(this._vertices.length<3)return this.reset(),void this._startSketch();this.manipulators.forEach(({manipulator:e})=>{e.interactive=!0}),this._drawActive=!1,this.finishToolCreation()}_updateSketch(e){const{spatialReference:t}=this.view;for(;this._vertices.length>e.length;){const{handle:e,manipulator:t}=this._vertices.pop();e.remove(),this.manipulators.remove(t)}for(let r=this._vertices.length;r<e.length;r++){const[i,s]=e[r],a=new j({x:i,y:s,spatialReference:t}),n=ie(a,this.view,this._manipulatorLayer);this.manipulators.add(n);const o=Y.fromGeometry(a,2);o.on("vertex-update",e=>{const t=e.vertices.at(0);t&&(this._vertices[r].coord=[t.pos[0],t.pos[1]],this._updateGraphics())});const m=B(n,(e,t,r,i)=>{const s=this._getSnappingContext(i),{snappingManager:a}=this,n=this._updatingHandles,{snappingStep:m}=$({snappingContext:s,snappingManager:a,updatingHandles:n});t.next(J(this.view)).next(t=>{if("start"===t.action){const r=new j(t.mapStart);e.graphic.geometry=r,o.trySetGeometry(r)}return t}).next(...m).next(N({operations:o})).next(()=>{e.graphic.geometry=o.data.geometry})});this._vertices.push({manipulator:n,coord:[i,s],handle:m})}if(this._vertices.length){const r=this._vertices.length-1,i=this._vertices[r],[s,a]=e[r];i.coord[0]===s&&i.coord[1]===a||(i.coord=[s,a],i.manipulator.graphic.geometry=new j({x:s,y:a,spatialReference:t}));const n=this._drawActive?this._vertices[r].manipulator:null;this.manipulators.forEach(({manipulator:e})=>{e.interactive=null==n||e!==n})}this._updateGraphics()}_updateGraphics(){if(this._vertices.length<2)return void this._measurementLayer.removeAll();const e=se(this._vertices.map(({coord:e})=>e),this.view.spatialReference);if(!e)return;const{measurement:r,fillGeometry:i,outlineGeometry:n}=e;this._set("measurement",r);const o=r?oe(this.messages,r,this.unit):null;if(this._set("measurementLabel",o),!i&&!n)return;let m,l,p;const{graphics:c}=this._measurementLayer,h=3===c.length,{effectiveTheme:u}=this.view;h?(m=c.at(0),l=c.at(1),p=c.at(2)):(m=new t({symbol:new D({color:s(u.accentColor,.3),outline:null})}),l=new t({symbol:new P({color:u.accentColor,width:2})}),p=new t({symbol:new V({color:u.textColor,font:new z({size:14,family:"sans-serif"}),haloColor:s(a(u.textColor,160),.5),haloSize:2})}),c.removeAll(),c.addMany([m,l,p])),m.geometry=i,l.geometry=n;const d=i?U(i):null,v=d?j.fromJSON(d):null;p.geometry=v,p.symbol.text=o?.area??""}};function ie(e,r,i){const a=8,n={style:"circle",color:s(r.effectiveTheme.accentColor,.5),outline:{type:"simple-line",width:0}},o=new E({...n,size:a}),m=new E({...n,size:1.5*a}),l=new t({geometry:e,symbol:o});return new K({view:r,layer:i,graphic:l,focusedSymbol:m,consumesClicks:!1})}function se(e,t){if(2===e.length){const r=new A({paths:[e],spatialReference:t});let i;return i=t.isGeographic?_(t)?w(r,te):M(r,te,{unit:"meters"}):t.isWebMercator?M(r,te,{unit:"meters"}):r,{measurement:null,fillGeometry:null,outlineGeometry:i}}e.push(e[0]);const r=new A({paths:[e],spatialReference:t}),i=new S({rings:[e],spatialReference:t});let s,a,n=null,o=null;if(t.isGeographic)if(_(t)){if(n=w(r,te),o=w(i,te),o=T(o),!o)return null;s=b([r],"meters")[0],a=L([o],"square-meters")[0]}else{if(n=M(r,te,{unit:"meters"}),o=M(i,te,{unit:"meters"}),o=T(o),!o)return null;s=C(r,{unit:"meters"}),a=G(o,{unit:"square-meters"})}else if(t.isWebMercator){if(n=M(r,te,{unit:"meters"}),o=M(i,te,{unit:"meters"}),!o||!n)return null;if(o=T(o),!o)return null;s=C(r,{unit:"meters"}),a=G(o,{unit:"square-meters"})}else{if(n=r,o=T(i),!o)return null;s=R(r,{unit:"meters"}),a=k(o,{unit:"square-meters"})}return{measurement:{geometry:o,area:a,perimeter:s},fillGeometry:o,outlineGeometry:n}}function ae(e){return null!=e}async function ne(e){(e?.isGeographic&&!_(e)||e?.isWebMercator)&&await Promise.all([x(),O(),H()])}function oe(e,t,r){if(!t||!e)return null;const i={area:null,perimeter:null},{area:s,perimeter:a}=t;switch(r){case"metric":i.area=c(e,s,"square-meters");break;case"imperial":i.area=p(e,s,"square-meters");break;default:{const t=d(s,"square-meters",r);i.area=l(e,t,r);break}}const n=v(r);if(n)switch(n){case"metric":i.perimeter=u(e,a,"meters");break;case"imperial":i.perimeter=h(e,a,"meters");break;default:{const t=d(a,"meters",n);i.perimeter=l(e,t,n);break}}else i.perimeter="";return i}e([y()],re.prototype,"_drawActive",void 0),e([y({readOnly:!0})],re.prototype,"cursor",null),e([y({value:!0})],re.prototype,"editable",null),e([y({readOnly:!0})],re.prototype,"measurement",void 0),e([y({readOnly:!0})],re.prototype,"measurementLabel",void 0),e([y()],re.prototype,"messages",void 0),e([y({constructOnly:!0})],re.prototype,"snappingManager",void 0),e([y()],re.prototype,"unit",void 0),e([y()],re.prototype,"updating",null),e([y({constructOnly:!0})],re.prototype,"view",void 0),re=e([g("esri.widgets.AreaMeasurement2D.AreaMeasurement2DTool")],re);export{re as AreaMeasurement2DTool,se as createAreaMeasurementInfo2D,oe as createAreaMeasurementLabel,ae as isSupported,ne as loadGeometryOperators};
|
|
2
|
+
import{__decorate as e}from"tslib";import t from"../../Graphic.js";import{fetchMessageBundle as r,onLocaleChange as i}from"../../intl.js";import{multiplyOpacity as s,getContrast as a}from"../../core/colorUtils.js";import{destroyMaybe as o}from"../../core/maybe.js";import{watch as n,initial as m}from"../../core/reactiveUtils.js";import{formatDecimal as l,formatImperialArea as p,formatMetricArea as c,formatImperialLength as u,formatMetricLength as h}from"../../core/unitFormatUtils.js";import{convertUnit as d,deriveLengthUnitFromAreaUnit as y}from"../../core/units.js";import{property as v,subclass as g}from"../../core/accessorSupport/decorators.js";import{UpdatingHandles as f}from"../../core/support/UpdatingHandles.js";import{isSupported as _,geodesicDensify as w,geodesicLengths as b,geodesicAreas as L}from"../../geometry/geodesicUtils.js";import j from"../../geometry/Point.js";import S from"../../geometry/Polygon.js";import x from"../../geometry/Polyline.js";import{execute as A}from"../../geometry/operators/areaOperator.js";import{execute as G,load as M}from"../../geometry/operators/geodeticAreaOperator.js";import{execute as k,load as O}from"../../geometry/operators/geodeticDensifyOperator.js";import{execute as C,load as H}from"../../geometry/operators/geodeticLengthOperator.js";import{execute as R}from"../../geometry/operators/lengthOperator.js";import{execute as T}from"../../geometry/operators/simplifyOperator.js";import{polygonCentroidPoint as U}from"../../geometry/support/centroid.js";import q from"../../layers/GraphicsLayer.js";import z from"../../symbols/Font.js";import D from"../../symbols/SimpleFillSymbol.js";import P from"../../symbols/SimpleLineSymbol.js";import E from"../../symbols/SimpleMarkerSymbol.js";import V from"../../symbols/TextSymbol.js";import{SnappingVisualizer2D as F}from"../../views/2d/interactive/SnappingVisualizer2D.js";import W from"../../views/draw/Draw.js";import{createCoordinateHelper as I}from"../../views/interactive/coordinateHelper.js";import{createManipulatorDragEventPipeline as B,screenToMap as J,dragManipulatedObject as N}from"../../views/interactive/dragEventPipeline.js";import{GraphicManipulator as K}from"../../views/interactive/GraphicManipulator.js";import{InteractiveToolBase as Q}from"../../views/interactive/InteractiveToolBase.js";import{EditGeometry as X}from"../../views/interactive/editGeometry/EditGeometry.js";import{EditGeometryOperations as Y}from"../../views/interactive/editGeometry/EditGeometryOperations.js";import{SnappingContext as Z}from"../../views/interactive/snapping/SnappingContext.js";import{createSnapDragEventPipelineStep as $}from"../../views/interactive/snapping/SnappingDragPipelineStep.js";import{setupSnappingToggleHandles as ee}from"../../views/interactive/snapping/snappingUtils.js";const te=1e5;let re=class extends Q{constructor(e){super(e),this._measurementLayer=new q({internal:!0,listMode:"hide",visible:!1,title:"Area measurement layer"}),this._manipulatorLayer=new q({internal:!0,listMode:"hide",visible:!1,title:"Area measurement manipulator layer"}),this._snappingLayer=new q({internal:!0,listMode:"hide",visible:!1,title:"Area measurement snapping layer"}),this._updatingHandles=new f,this._vertices=[],this._drawActive=!1,this.measurement=null,this.measurementLabel=null}initialize(){r("esri/core/t9n/Units").then(e=>{this.messages=e});const e=this.view;this._draw=new W({view:e}),e.map.addMany([this._measurementLayer,this._manipulatorLayer,this._snappingLayer]),e.focus(),this.addHandles([i(async()=>{this.messages=await r("esri/core/t9n/Units")}),n(()=>[this.unit,this.messages],()=>{this._updateGraphics()},m),n(()=>[this.view.effectiveTheme.accentColor,this.view.effectiveTheme.textColor],()=>{if(!this._vertices.length)return;const e=this._vertices.map(({coord:e})=>e);for(const{handle:t}of this._vertices)t.remove();this._vertices=[],this._measurementLayer.removeAll(),this._manipulatorLayer.removeAll(),this._snappingLayer.removeAll(),this.manipulators.removeAll(),this._updateSketch(e)})]),ee(this)}destroy(){const{map:e}=this.view;this._draw.view=null,this._draw=o(this._draw),e.removeMany([this._measurementLayer,this._manipulatorLayer,this._snappingLayer]),this._measurementLayer.removeAll(),this._manipulatorLayer.removeAll(),this._snappingLayer.removeAll(),this._set("measurement",null),this._set("measurementLabel",null),this._measurementLayer=o(this._measurementLayer),this._manipulatorLayer=o(this._manipulatorLayer),this._snappingLayer=o(this._snappingLayer),this._updatingHandles=o(this._updatingHandles),this._resetVertices()}get cursor(){return this._drawActive?"crosshair":null}set editable(e){this._set("editable",e),e||this._draw.reset()}get snappingOptions(){return this.snappingManager.options}get updating(){return this._updatingHandles.updating||this.snappingManager.updating}onActivate(){this._drawActive||0!==this._vertices.length||this._startSketch()}onShow(){this._measurementLayer.visible=!0,this._manipulatorLayer.visible=!0,this._snappingLayer.visible=!0}onHide(){this._measurementLayer.visible=!1,this._manipulatorLayer.visible=!1,this._snappingLayer.visible=!1}reset(){this.manipulators.removeAll(),this._resetVertices(),this._measurementLayer.removeAll(),this._manipulatorLayer.removeAll(),this._set("measurement",null),this._set("measurementLabel",null),this._draw.reset(),this._drawActive=!1}_getSnappingContext(e){return new Z({elevationInfo:{mode:"on-the-ground",offset:0},pointer:e,editGeometryOperations:new Y(new X("point",I(!1,!1,this.view.spatialReference)),2),visualizer:new F(this._snappingLayer)})}_resetVertices(){for(const{handle:e}of this._vertices)e.remove();this._vertices=[]}_startSketch(){this._drawActive=!0;const{snappingManager:e}=this;this._draw.create("polyline",{mode:"click",snappingManager:e}).on(["draw-complete","vertex-add","vertex-update","vertex-remove","cursor-update","undo","redo"],e=>{this._updateSketch(e.vertices),"draw-complete"===e.type&&this._stopSketch()})}_stopSketch(){if(this._vertices.length<3)return this.reset(),void this._startSketch();this.manipulators.forEach(({manipulator:e})=>{e.interactive=!0}),this._drawActive=!1,this.finishToolCreation()}_updateSketch(e){const{spatialReference:t}=this.view;for(;this._vertices.length>e.length;){const{handle:e,manipulator:t}=this._vertices.pop();e.remove(),this.manipulators.remove(t)}for(let r=this._vertices.length;r<e.length;r++){const[i,s]=e[r],a=new j({x:i,y:s,spatialReference:t}),o=ie(a,this.view,this._manipulatorLayer);this.manipulators.add(o);const n=Y.fromGeometry(a,2);n.on("vertex-update",e=>{const t=e.vertices.at(0);t&&(this._vertices[r].coord=[t.pos[0],t.pos[1]],this._updateGraphics())});const m=B(o,(e,t,r,i)=>{const s=this._getSnappingContext(i),{snappingManager:a}=this,o=this._updatingHandles,{snappingStep:m}=$({snappingContext:s,snappingManager:a,updatingHandles:o});t.next(J(this.view)).next(t=>{if("start"===t.action){const r=new j(t.mapStart);e.graphic.geometry=r,n.trySetGeometry(r)}return t}).next(...m).next(N({operations:n})).next(()=>{e.graphic.geometry=n.data.geometry})});this._vertices.push({manipulator:o,coord:[i,s],handle:m})}if(this._vertices.length){const r=this._vertices.length-1,i=this._vertices[r],[s,a]=e[r];i.coord[0]===s&&i.coord[1]===a||(i.coord=[s,a],i.manipulator.graphic.geometry=new j({x:s,y:a,spatialReference:t}));const o=this._drawActive?this._vertices[r].manipulator:null;this.manipulators.forEach(({manipulator:e})=>{e.interactive=null==o||e!==o})}this._updateGraphics()}_updateGraphics(){if(this._vertices.length<2)return void this._measurementLayer.removeAll();const e=se(this._vertices.map(({coord:e})=>e),this.view.spatialReference);if(!e)return;const{measurement:r,fillGeometry:i,outlineGeometry:o}=e;this._set("measurement",r);const n=r?ne(this.messages,r,this.unit):null;if(this._set("measurementLabel",n),!i&&!o)return;let m,l,p;const{graphics:c}=this._measurementLayer,u=3===c.length,{effectiveTheme:h}=this.view;u?(m=c.at(0),l=c.at(1),p=c.at(2)):(m=new t({symbol:new D({color:s(h.accentColor,.3),outline:null})}),l=new t({symbol:new P({color:h.accentColor,width:2})}),p=new t({symbol:new V({color:h.textColor,font:new z({size:14,family:"sans-serif"}),haloColor:s(a(h.textColor,160),.5),haloSize:2})}),c.removeAll(),c.addMany([m,l,p])),m.geometry=i,l.geometry=o;const d=i?U(i):null,y=d?j.fromJSON(d):null;p.geometry=y,p.symbol.text=n?.area??""}};function ie(e,r,i){const a=8,o={style:"circle",color:s(r.effectiveTheme.accentColor,.5),outline:{type:"simple-line",width:0}},n=new E({...o,size:a}),m=new E({...o,size:1.5*a}),l=new t({geometry:e,symbol:n});return new K({view:r,layer:i,graphic:l,focusedSymbol:m,consumesClicks:!1})}function se(e,t){if(2===e.length){const r=new x({paths:[e],spatialReference:t});let i;return i=t.isGeographic?_(t)?w(r,te):k(r,te,{unit:"meters"}):t.isWebMercator?k(r,te,{unit:"meters"}):r,{measurement:null,fillGeometry:null,outlineGeometry:i}}e.push(e[0]);const r=new x({paths:[e],spatialReference:t}),i=new S({rings:[e],spatialReference:t});let s,a,o=null,n=null;if(t.isGeographic)if(_(t)){if(o=w(r,te),n=w(i,te),n=T(n),!n)return null;s=b([r],"meters")[0],a=L([n],"square-meters")[0]}else{if(o=k(r,te,{unit:"meters"}),n=k(i,te,{unit:"meters"}),n=T(n),!n)return null;s=C(r,{unit:"meters"}),a=G(n,{unit:"square-meters"})}else if(t.isWebMercator){if(o=k(r,te,{unit:"meters"}),n=k(i,te,{unit:"meters"}),!n||!o)return null;if(n=T(n),!n)return null;s=C(r,{unit:"meters"}),a=G(n,{unit:"square-meters"})}else{if(o=r,n=T(i),!n)return null;s=R(r,{unit:"meters"}),a=A(n,{unit:"square-meters"})}return{measurement:{geometry:n,area:a,perimeter:s},fillGeometry:n,outlineGeometry:o}}function ae(e){return null!=e}async function oe(e){(e?.isGeographic&&!_(e)||e?.isWebMercator)&&await Promise.all([M(),O(),H()])}function ne(e,t,r){if(!t||!e)return null;const i={area:null,perimeter:null},{area:s,perimeter:a}=t;switch(r){case"metric":i.area=c(e,s,"square-meters");break;case"imperial":i.area=p(e,s,"square-meters");break;default:{const t=d(s,"square-meters",r);i.area=l(e,t,r);break}}const o=y(r);if(o)switch(o){case"metric":i.perimeter=h(e,a,"meters");break;case"imperial":i.perimeter=u(e,a,"meters");break;default:{const t=d(a,"meters",o);i.perimeter=l(e,t,o);break}}else i.perimeter="";return i}e([v()],re.prototype,"_drawActive",void 0),e([v({readOnly:!0})],re.prototype,"cursor",null),e([v({value:!0})],re.prototype,"editable",null),e([v({readOnly:!0})],re.prototype,"measurement",void 0),e([v({readOnly:!0})],re.prototype,"measurementLabel",void 0),e([v()],re.prototype,"messages",void 0),e([v({constructOnly:!0})],re.prototype,"snappingManager",void 0),e([v()],re.prototype,"unit",void 0),e([v()],re.prototype,"updating",null),e([v({constructOnly:!0})],re.prototype,"view",void 0),re=e([g("esri.widgets.AreaMeasurement2D.AreaMeasurement2DTool")],re);export{re as AreaMeasurement2DTool,se as createAreaMeasurementInfo2D,ne as createAreaMeasurementLabel,ae as isSupported,oe as loadGeometryOperators};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{createArcadeProfile as e,createArcadeExecutor as
|
|
2
|
+
import{createArcadeProfile as e,createArcadeExecutor as r}from"../../../arcade.js";import t from"../../../core/Logger.js";const s=()=>t.getLogger("esri.widgets.BatchAttributeForm.expressions.ExpressionsManager"),o=e("form-calculation");class c{constructor(){this._executors=new Map,this._executorPromises=new Map}async getArcadeExecutor(e){return this._getArcadeExecutor(e)}async _getArcadeExecutor(e){if(this._executors.has(e))return this._executors.get(e);if(this._executorPromises.has(e))return this._executorPromises.get(e);const r=this._createExecutor(e);return this._executorPromises.set(e,r),r}async _createExecutor(e){try{const t=await r(e,o);return this._executors.set(e,t),t}catch(t){return void s().error("Arcade expression failed to compile.",t,{expression:e})}finally{this._executorPromises.delete(e)}}}export{c as ArcadeExecutorProvider};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{__decorate as e}from"tslib";import{property as t,subclass as
|
|
2
|
+
import{__decorate as e}from"tslib";import o from"../../../core/ReactiveMap.js";import{property as t,subclass as r}from"../../../core/accessorSupport/decorators.js";import{ElementTemplateBase as s}from"./ElementTemplateBase.js";let i=class extends s{constructor(e){super(e),this.domain=null,this.group=null,this.hint=null,this.input=null,this.type="field",this._choiceExpressionExecutorsByLayer=new o}get fieldName(){return this.field.name}addLayer(e,o=null,t){super.addLayer(e,o),t&&this._choiceExpressionExecutorsByLayer.set(e,t)}foldIn(e){for(const o of e.layers)this.addLayer(o,e.getExpressionExecutorsForLayer(o),e.getChoiceExpressionExecutorForLayer(o)??void 0)}getChoiceExpressionExecutorForLayer(e){return this._choiceExpressionExecutorsByLayer.get(e)??null}get hasValueCalculations(){for(const e of this.layers){const o=this.getExpressionExecutorsForLayer(e);if(o?.valueExpression)return!0}return!1}};e([t({clonable:"reference"})],i.prototype,"domain",void 0),e([t({clonable:"reference",constructOnly:!0})],i.prototype,"field",void 0),e([t()],i.prototype,"fieldName",null),e([t({clonable:!1})],i.prototype,"group",void 0),e([t()],i.prototype,"hint",void 0),e([t()],i.prototype,"input",void 0),e([t()],i.prototype,"type",void 0),e([t({clonable:e=>new o(Array.from(e))})],i.prototype,"_choiceExpressionExecutorsByLayer",void 0),e([t()],i.prototype,"hasValueCalculations",null),i=e([r("esri.widgets.BatchAttributeForm.templates.FieldElementTemplate")],i);export{i as FieldElementTemplate};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{createArcadeProfile as e,createArcadeExecutor as t}from"../../../../arcade.js";import{isSome as r}from"../../../../core/arrayUtils.js";import n from"../../../../core/Error.js";import o from"../../../../core/Logger.js";import{getEffectiveFieldAlias as i}from"../../../../editing/fieldUtils.js";import s from"../../../../form/ExpressionInfo.js";import a from"../../../../form/elements/AttachmentElement.js";import{isMultipleChoiceInput as m}from"../../../../form/elements/inputs/inputUtils.js";import
|
|
2
|
+
import{createArcadeProfile as e,createArcadeExecutor as t}from"../../../../arcade.js";import{isSome as r}from"../../../../core/arrayUtils.js";import n from"../../../../core/Error.js";import o from"../../../../core/Logger.js";import{getEffectiveFieldAlias as i}from"../../../../editing/fieldUtils.js";import s from"../../../../form/ExpressionInfo.js";import a from"../../../../form/elements/AttachmentElement.js";import{isMultipleChoiceInput as m,isDynamicChoiceInput as l}from"../../../../form/elements/inputs/inputUtils.js";import p from"../../../../form/elements/inputs/attachments/AttachmentInput.js";import c from"../../../../form/elements/inputs/attachments/AudioInput.js";import d from"../../../../form/elements/inputs/attachments/DocumentInput.js";import f from"../../../../form/elements/inputs/attachments/ImageInput.js";import u from"../../../../form/elements/inputs/attachments/VideoInput.js";import{isAttachmentElement as x,isFieldElement as y,isGroupElement as h,isRelationshipElement as w,isTextElement as E,isUtilityNetworkAssociationsElement as T}from"../../../../form/support/formUtils.js";import{getLowerCaseEditTrackingFields as I,isFieldVisibleByDefault as v}from"../../../../layers/support/fieldUtils.js";import{isNumber as b}from"../../../../support/guards.js";import{layerSupportsAttachments as j,getLayerTimeZone as g}from"../../batchAttributeFormUtils.js";import{makeExpressionInfosMap as P,makeExecutorSetForFormElement as A}from"../../expressions/expressionUtils.js";import{AttachmentElementTemplate as Z}from"../AttachmentElementTemplate.js";import F from"../BatchFormTemplate.js";import{FieldElementTemplate as U}from"../FieldElementTemplate.js";import{GroupElementTemplate as C}from"../GroupElementTemplate.js";import{RelationshipElementTemplate as L}from"../RelationshipElementTemplate.js";import{TextElementTemplate as B}from"../TextElementTemplate.js";import{UtilityNetworkAssociationsElementTemplate as H}from"../UtilityNetworkAssociationsElementTemplate.js";import{isGroupElementTemplate as N}from"./templateUtils.js";import{compileTextElementMarkdownToHTML as V}from"./textElementTemplateUtils.js";const R="expression/dea57012-47ca4b55a000-8df62742ed0c",S=e("form-attachment-filename-calculation"),W=()=>o.getLogger("esri.widgets.BatchAttributeForm.templates.templateUtils");async function k(e,t,r=e.formTemplate){return await e.load(),r?.elements&&r.elements.length>0?G(r,e,t):K(e,t)}async function K(e,{arcadeExecutorProvider:t,attachmentsEnabled:r,formTimeZone:n}){const o=new Set(I(e)),i={arcadeExecutorProvider:t,formTimeZone:n,layer:e},s=[];for(const m of e.fields)_(m,e,o)&&s.push(Y(m,i));const a=await Promise.all(s);return r&&await D(a,{arcadeExecutorProvider:t,expressionInfos:P(void 0),layer:e}),new F({elements:a,title:e.formTemplate?.title,preserveFieldValuesWhenHidden:!0})}function O(e,t){for(const r of e??[])if("group"!==r.type){if("field"===r.type&&!1===r.editable&&!r.editableExpression)return!0}else if(O(r.elements??[]))return!0;return!1}async function D(e,{arcadeExecutorProvider:t,expressionInfos:r,layer:n}){if(!j(n))return;const o=await $(new a({displayFilename:!0,input:new p({attachmentAssociationType:"any",inputTypes:[new f,new d,new u,new c]})}),{arcadeExecutorProvider:t,expressionInfos:r,layer:n});e.push(o)}async function G(e,t,r){let n=null;O(e.elements??[])&&(n=new s({title:"",name:R,expression:"false"}));const o=P(n?[...e.expressionInfos??[],n]:e.expressionInfos),i={description:e.description,elements:new Array,title:e.title,preserveFieldValuesWhenHidden:e.preserveFieldValuesWhenHidden,supportsAttachmentElements:e.supportsAttachmentElements},{elements:a}=e;if(!a)return new F(i);let m=!1;const{arcadeExecutorProvider:l,formTimeZone:p}=r;for(const s of a){const e=await q(s,{arcadeExecutorProvider:l,expressionInfos:o,layer:t,formTimeZone:p});if(e){if(i.elements.push(e),m)continue;"attachment"===e.type&&(m=!0),N(e)&&e.elements.some(e=>("attachment"===e.type&&(m=!0),m))}}return e.supportsAttachmentElements||!r.attachmentsEnabled||m||await D(i.elements,{arcadeExecutorProvider:l,expressionInfos:o,layer:t}),new F(i)}async function $(e,{arcadeExecutorProvider:r,expressionInfos:n,layer:o}){let i=null;if(e.filenameExpression)try{i=await t(e.filenameExpression,S)}catch(m){W().error("Failed to compile attachment filename expression",m)}const s=new Z({allowUserRename:e.allowUserRename,attachmentKeyword:e.attachmentKeyword,description:e.description,displayFilename:e.displayFilename,filenameExpressionExecutor:i,input:e.input,label:e.label,maxAttachmentCount:e.maxAttachmentCount,minAttachmentCount:e.minAttachmentCount,useOriginalFilename:e.useOriginalFilename}),a=await A({element:e,expressionInfos:n,provider:r});return s.addLayer(o,a),s}async function q(e,t){return x(e)?$(e,{arcadeExecutorProvider:t.arcadeExecutorProvider,expressionInfos:t.expressionInfos,layer:t.layer}):y(e)?z(e,t):h(e)?J(e,t):w(e)?M(e,t):E(e)?Q(e,t):T(e)?X(e,t):null}async function z(e,{arcadeExecutorProvider:t,expressionInfos:r,layer:o,formTimeZone:i}){const{fieldsIndex:s}=o,{description:a,domain:p,fieldName:c,hint:d,input:f,label:u}=e;if(null==c||!s.has(c))return W().warn(new n("batch-attribute-form:invalid-form-element-field",`Field element with label '${u}' does not refer to a valid field`)),null;if(!1!==e.editable||e.editableExpression||((e=e.clone()).editableExpression=R),f&&m(f)&&f.otherChoice){const e=f.otherChoice.fieldName,t=s.get(e);t&&t.name!==e&&(f.otherChoice=f.otherChoice.clone(),f.otherChoice.fieldName=t.name)}const x=new U({description:a,domain:p,field:s.get(c),hint:d,input:f,formTimeZone:i,layerTimeZone:g(o),label:u}),y=await A({element:e,expressionInfos:r,provider:t});let h;if(f&&l(f)&&f.choiceExpression){const e=r.get(f.choiceExpression);h=e?await t.getArcadeExecutor(e.expression):void 0}return x.addLayer(o,y,h),x}async function J(e,t){const{arcadeExecutorProvider:r,expressionInfos:n,layer:o}=t,{description:i,label:s,initialState:a}=e,m=[];for(const c of e.elements){const e=await q(c,t);e&&m.push(e)}const l=new C({description:i,elements:m,label:s,initialState:a??"expanded"}),p=await A({element:e,expressionInfos:n,provider:r});return l.addLayer(o,p),l}async function M(e,t){const{description:r,label:n,displayCount:o,displayType:i,orderByFields:s,relationshipId:a}=e,{arcadeExecutorProvider:m,expressionInfos:l,layer:p,formTimeZone:c}=t,d=new L({description:r,...b(o)&&{displayCount:o},displayType:i,formTimeZone:c,label:n,layerTimeZone:g(p),orderByFields:s,relationshipId:a}),f=await A({element:e,expressionInfos:l,provider:m});return d.addLayer(p,f),d}async function Q(e,{arcadeExecutorProvider:t,expressionInfos:n,layer:o,formTimeZone:i}){const{description:s,label:a,text:m,textFormat:l}=e,{fieldsIndex:p}=o,c=m&&"markdown"===l?await V(m):m,d=new B({compiledText:c,description:s,fieldsIndex:p,formTimeZone:i,label:a,layerTimeZone:g(o)}),f=await A({element:e,expressionInfos:n,provider:t}),{expressionParts:u}=d;if(u.length){const e=await Promise.all(u.map(e=>{const r=n.get(e)?.expression??e;return t.getArcadeExecutor(r)}));f.textExpressions=e.filter(r)}return d.addLayer(o,f),d}async function X(e,t){const{associationTypes:r,description:n,label:o}=e,{arcadeExecutorProvider:i,expressionInfos:s,formTimeZone:a,layer:m}=t,l=new H({associationTypes:r,description:n,formTimeZone:a,label:o,layerTimeZone:g(m)}),p=await A({element:e,expressionInfos:s,provider:i});return l.addLayer(m,p),l}async function Y(e,{arcadeExecutorProvider:t,layer:r,formTimeZone:n}){const o=i(e,r)||e.name,s=new U({field:e,formTimeZone:n,label:o,layerTimeZone:g(r)}),a={};return e.editable&&r.userHasUpdateItemPrivileges&&(a.editableExpression=await t.getArcadeExecutor("true")),s.addLayer(r,a),s}function _(e,t,r){return!r.has(e.name.toLowerCase())&&v(e,t)}export{k as createBatchFormTemplate,K as createBatchFormTemplateFromFields};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{numericHash as t}from"../../../../core/string.js";import{isBarcodeScannerInput as n,
|
|
2
|
+
import{numericHash as t}from"../../../../core/string.js";import{isBarcodeScannerInput as n,isDynamicChoiceInput as e,isComboBoxInput as i,isRadioButtonsInput as o,isDatePickerInput as r,isDateTimePickerInput as $,isDateTimeOffsetPickerInput as u,isSwitchInput as c,isTextAreaInput as l,isTextBoxInput as s,isTimePickerInput as a,isMultipleChoiceInput as m}from"../../../../form/elements/inputs/inputUtils.js";import{isFieldElementTemplate as f,isGroupElementTemplate as p,isRelationshipElementTemplate as g,isTextElementTemplate as d,isAttachmentElementTemplate as h,isUtilityNetworkAssociationsElementTemplate as S,isExcludedFromSharedForm as y}from"./templateUtils.js";const O="",N="num:";function b(n){return f(n)?t(x(n)).toString():p(n)?t(C(n)).toString():g(n)?t(j(n)).toString():d(n)?t(J(n)).toString():h(n)?t(w(n)).toString():S(n)?t(L(n)).toString():t(JSON.stringify(n)).toString()}function x(t){return`${v(t)}.${I(t.field)}.${K(t.domain)}.${t.hint??O}.${A(t.input)}`}function C(t){const n=T(t);let e=O;for(const i of t.elements)y(i)||(e+="."+b(i).toString());return`${n}${e}`}function V(n){return t(T(n)).toString()}function T(t){return v(t)+`.${t.initialState}`}function j(t){const{displayCount:n,displayType:e,relationshipId:i}=t;return`${v(t)}.${n}.${e}.${i}.${B(t.orderByFields??[])}`}function J(t){const n=v(t),{compiledText:e}=t;return`${n}.${e??O}`}function w(t){return`${v(t)}.${t.allowUserRename}.${t.attachmentKeyword??O}.${t.displayFilename}.${F(t.input)}.${t.maxAttachmentCount??O}.${t.minAttachmentCount??O}.${t.useOriginalFilename}`}function L(t){return`${v(t)}.${R(t.associationTypes)}`}function v(t){return`${t.label??O}.${t.description??O}.${t.layerTimeZone??O}`}function A(t){if(!t)return O;const{type:f}=t;if(n(t))return f??O;if(e(t)){const{showNoValueOption:n}=t;return`${f}.${n}.${t.noValueOptionLabel??O}`}if(i(t)||o(t)){const{showNoValueOption:n}=t;return`${f}.${n}.${t.noValueOptionLabel??O}`}if(r(t))return`${f}.${U(t)}`;if($(t)){const n=t.min?.getTime(),e=t.max?.getTime(),{includeTime:i}=t;return`${f}.${n}.${e}.${i}`}if(u(t)){const n=U(t),{includeTimeOffset:e,timeResolution:i}=t;return`${f}.${n}.${e}.${i}`}if(c(t)){const{offValue:n,onValue:e}=t;return`${f}.${k(n)}.${k(e)}`}if(l(t)||s(t)){return`${f}.${t.minLength?.toString()??O}.${t.maxLength?.toString()??O}`}if(a(t)){const n=U(t),{timeResolution:e}=t;return`${f}.${n}.${e}`}if(m(t)){return`${f}.${U({min:t.minimumChoices?.toString(),max:t.maximumChoices?.toString()})}.${t.choiceDelimiter??O}.${t.includeSelectAllChoices}.${t.otherChoice?.fieldName??O}.${t.otherChoice?.label??O}.${t.otherChoice?.hint??O}.${D(t)}`}return JSON.stringify(t)}function F(t){return t?JSON.stringify(t.toJSON()):O}function R(t){return t.map(t=>JSON.stringify(t.toJSON())).sort().join(".")}function U(t){return`${t.min??O}.${t.max??O}`}function B(t){return t.map(({field:t,order:n})=>`${t}.${n}`).sort().join(".")}function D(t){return(t.choices??[]).map(({label:t,value:n})=>`${t}.${n}`).sort().join(".")}function I(t){const n=t.name,e=t.alias??O;return`${n}.${e===n?O:e}.${t.nullable}.${t.type}.${t.length??O}.${t.description??O}.${t.editable}.${t.visible}`}function K(t){return t?"coded-value"===t.type?Z(t):"range"===t.type?q(t):JSON.stringify(t):O}function Z(t){const{type:n}=t;return`${n}.${t.codedValues.map(({code:t,name:n})=>`${k(t)}.${n}`).sort().join(".")}`}function k(t){return"number"==typeof t?`${N}${t}`:t}function q(t){const{maxValue:n,minValue:e,type:i}=t;return`${i}.${e}.${n}`}export{b as hashElementTemplate,V as hashGroupElementTemplateWithoutChildren};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{__decorate as e}from"tslib";import t from"../../Graphic.js";import{fetchMessageBundle as i,onLocaleChange as r}from"../../intl.js";import{getContrast as s,multiplyOpacity as
|
|
2
|
+
import{__decorate as e}from"tslib";import t from"../../Graphic.js";import{fetchMessageBundle as i,onLocaleChange as r}from"../../intl.js";import{getContrast as s,multiplyOpacity as o}from"../../core/colorUtils.js";import{handlesGroup as n}from"../../core/handleUtils.js";import{destroyMaybe as a}from"../../core/maybe.js";import{watch as l,initial as p}from"../../core/reactiveUtils.js";import{formatDecimal as m,formatImperialLength as c,formatMetricLength as h}from"../../core/unitFormatUtils.js";import{convertUnit as u}from"../../core/units.js";import{property as d,subclass as y}from"../../core/accessorSupport/decorators.js";import{UpdatingHandles as v}from"../../core/support/UpdatingHandles.js";import{isSupported as g,geodesicLengths as _,geodesicDensify as f}from"../../geometry/geodesicUtils.js";import w from"../../geometry/Point.js";import L from"../../geometry/Polyline.js";import{execute as b,load as S}from"../../geometry/operators/geodeticDensifyOperator.js";import{execute as j,load as M}from"../../geometry/operators/geodeticLengthOperator.js";import{execute as x}from"../../geometry/operators/lengthOperator.js";import C from"../../layers/GraphicsLayer.js";import A from"../../symbols/CIMSymbol.js";import D from"../../symbols/Font.js";import G from"../../symbols/SimpleMarkerSymbol.js";import k from"../../symbols/TextSymbol.js";import{SnappingVisualizer2D as T}from"../../views/2d/interactive/SnappingVisualizer2D.js";import O from"../../views/draw/Draw.js";import{createCoordinateHelper as H}from"../../views/interactive/coordinateHelper.js";import{createManipulatorDragEventPipeline as P,screenToMap as R,dragManipulatedObject as U}from"../../views/interactive/dragEventPipeline.js";import{GraphicManipulator as E}from"../../views/interactive/GraphicManipulator.js";import{InteractiveToolBase as I}from"../../views/interactive/InteractiveToolBase.js";import{EditGeometry as z}from"../../views/interactive/editGeometry/EditGeometry.js";import{EditGeometryOperations as B}from"../../views/interactive/editGeometry/EditGeometryOperations.js";import{SnappingContext as F}from"../../views/interactive/snapping/SnappingContext.js";import{createSnapDragEventPipelineStep as V}from"../../views/interactive/snapping/SnappingDragPipelineStep.js";import{setupSnappingToggleHandles as W}from"../../views/interactive/snapping/snappingUtils.js";const N=1e5;let q=class extends I{constructor(e){super(e),this._measurementLayer=new C({internal:!0,listMode:"hide",visible:!1,title:"DistanceMeasurement2DTool measurement layer"}),this._manipulatorLayer=new C({internal:!0,listMode:"hide",visible:!1,title:"DistanceMeasurement2DTool manipulator layer"}),this._snappingLayer=new C({internal:!0,listMode:"hide",visible:!1,title:"DistanceMeasurement2DTool snapping layer"}),this._updatingHandles=new v,this._vertices=[],this._drawActive=!1,this.measurement=null,this.measurementLabel=null}initialize(){i("esri/core/t9n/Units").then(e=>{this.messages=e});const e=this.view;this._draw=new O({view:e}),e.map.addMany([this._measurementLayer,this._manipulatorLayer,this._snappingLayer]),e.focus(),this.addHandles([r(async()=>{this.messages=await i("esri/core/t9n/Units")}),l(()=>[this.unit,this.messages],()=>{this._updatePolylines()},p),l(()=>[this.view.effectiveTheme.accentColor,this.view.effectiveTheme.textColor],()=>{if(!this._vertices.length)return;const e=this._vertices.map(({coord:e})=>e);for(const{handle:t}of this._vertices)t.remove();this._vertices=[],this._measurementLayer.removeAll(),this._manipulatorLayer.removeAll(),this._snappingLayer.removeAll(),this.manipulators.removeAll(),this._updateSketch(e)})]),W(this)}destroy(){const{map:e}=this.view;this._draw.view=null,this._draw=a(this._draw),e.removeMany([this._measurementLayer,this._manipulatorLayer,this._snappingLayer]),this._measurementLayer.removeAll(),this._manipulatorLayer.removeAll(),this._snappingLayer.removeAll(),this._set("measurement",null),this._set("measurementLabel",null),this._measurementLayer=a(this._measurementLayer),this._manipulatorLayer=a(this._manipulatorLayer),this._snappingLayer=a(this._snappingLayer),this._updatingHandles=a(this._updatingHandles),this._resetVertices()}get cursor(){return this._drawActive?"crosshair":null}set editable(e){this._set("editable",e),e||this._draw.reset()}get snappingOptions(){return this.snappingManager.options}get updating(){return this._updatingHandles.updating||this.snappingManager.updating}onActivate(){this._drawActive||0!==this._vertices.length||this._startSketch()}onShow(){this._measurementLayer.visible=!0,this._manipulatorLayer.visible=!0,this._snappingLayer.visible=!0}onHide(){this._measurementLayer.visible=!1,this._manipulatorLayer.visible=!1,this._snappingLayer.visible=!1}_getSnappingContext(e){return new F({elevationInfo:{mode:"on-the-ground",offset:0},pointer:e,editGeometryOperations:new B(new z("point",H(!1,!1,this.view.spatialReference)),2),visualizer:new T(this._snappingLayer)})}_resetVertices(){for(const{handle:e}of this._vertices)e.remove();this._vertices=[]}_startSketch(){this._drawActive=!0;const{snappingManager:e}=this;this._draw.create("polyline",{mode:"click",snappingManager:e}).on(["draw-complete","vertex-add","vertex-update","vertex-remove","cursor-update","undo","redo"],e=>{this._updateSketch(e.vertices),"draw-complete"===e.type&&this._stopSketch()})}_stopSketch(){this.manipulators.forEach(({manipulator:e})=>{e.interactive=!0}),this._drawActive=!1,this.finishToolCreation()}_updateSketch(e){const{spatialReference:t}=this.view;for(;this._vertices.length>e.length;){const{handle:e,manipulator:t}=this._vertices.pop();e.remove(),this.manipulators.remove(t)}for(let l=this._vertices.length;l<e.length;l++){const[i,r]=e[l],s=new w({x:i,y:r,spatialReference:t}),o=J(s,this.view,this._manipulatorLayer);this.manipulators.add(o);const a=B.fromGeometry(s,2),p=[a.on("vertex-update",e=>{const t=e.vertices.at(0);t&&(this._vertices[l].coord=[t.pos[0],t.pos[1]],this._updatePolylines())}),P(o,(e,t,i,r)=>{const s=this._getSnappingContext(r),{snappingManager:o}=this,n=this._updatingHandles,{snappingStep:l}=V({snappingContext:s,snappingManager:o,updatingHandles:n});t.next(R(this.view)).next(t=>{if("start"===t.action){const i=new w(t.mapStart);e.graphic.geometry=i,a.trySetGeometry(i)}return t}).next(...l).next(U({operations:a})).next(()=>{e.graphic.geometry=a.data.geometry})})];this._vertices.push({manipulator:o,coord:[i,r],handle:n(p)})}const i=this._vertices.length-1,r=this._vertices[i],[s,o]=e[i];r.coord[0]===s&&r.coord[1]===o||(r.coord=[s,o],r.manipulator.graphic.geometry=new w({x:s,y:o,spatialReference:t}));const a=this._drawActive?this._vertices[i].manipulator:null;this.manipulators.forEach(({manipulator:e})=>{e.interactive=null==a||e!==a}),this._updatePolylines()}_updatePolylines(){if(this._vertices.length<2)return void this._measurementLayer.removeAll();const e=K(this._vertices.map(({coord:e})=>e),this.view.spatialReference);if(!e)return;const{measurement:i,drawing:r,original:n}=e;this._set("measurement",i);const a=Y(this.messages,i,this.unit);let l,p;this._set("measurementLabel",a);const{graphics:m}=this._measurementLayer,c=2===m.length,{effectiveTheme:h}=this.view;c?(l=m.at(0),p=m.at(1)):(l=new t({symbol:new A({data:{type:"CIMSymbolReference",symbol:{type:"CIMLineSymbol",symbolLayers:[{type:"CIMSolidStroke",effects:[{type:"CIMGeometricEffectDashes",dashTemplate:[14,12],lineDashEnding:"FullGap",controlPointEnding:"NoConstraint"}],enable:!0,capStyle:"Butt",joinStyle:"Round",width:3.5,color:s(h.accentColor).toArray()},{type:"CIMSolidStroke",enable:!0,capStyle:"Butt",joinStyle:"Round",width:5,color:h.accentColor.toArray()}]}}})}),p=new t({symbol:new k({color:h.textColor,haloColor:o(s(h.textColor,160),.5),haloSize:2,font:new D({size:14,family:"sans-serif"})})}),m.removeAll(),m.addMany([l,p])),l.geometry=r,p.geometry=n.extent?.center,p.symbol.text=a}};function J(e,i,r){const s=o(i.effectiveTheme.accentColor,.5),n={type:"simple-line",width:0},a=8,l=new G({style:"circle",color:s,size:a,outline:n}),p=new G({style:"circle",color:s,size:1.5*a,outline:n}),m=new t({geometry:e,symbol:l});return new E({view:i,layer:r,graphic:m,focusedSymbol:p,consumesClicks:!1})}function K(e,t){const i=new L({paths:[e],spatialReference:t});let r,s;return t.isGeographic?g(t)?(r=_([i],"meters")[0],s=f(i,N)):(r=j(i,{unit:"meters"}),s=b(i,N,{unit:"meters"})):t.isWebMercator?(r=j(i,{unit:"meters"}),s=b(i,N,{unit:"meters"})):(r=x(i,{unit:"meters"}),s=i),{measurement:{geometry:s,length:r},original:i,drawing:s}}function Q(e){return null!=e}async function X(e){(e?.isGeographic&&!g(e)||e?.isWebMercator)&&await Promise.all([S(),M()])}function Y(e,t,i){if(!t||!e)return"";switch(i){case"metric":return h(e,t.length,"meters");case"imperial":return c(e,t.length,"meters");default:return m(e,u(t.length,"meters",i),i)}}e([d()],q.prototype,"_drawActive",void 0),e([d({readOnly:!0})],q.prototype,"cursor",null),e([d({value:!0})],q.prototype,"editable",null),e([d({readOnly:!0})],q.prototype,"measurement",void 0),e([d({readOnly:!0})],q.prototype,"measurementLabel",void 0),e([d()],q.prototype,"messages",void 0),e([d({constructOnly:!0})],q.prototype,"snappingManager",void 0),e([d()],q.prototype,"unit",void 0),e([d()],q.prototype,"updating",null),e([d({constructOnly:!0})],q.prototype,"view",void 0),q=e([y("esri.widgets.DistanceMeasurement2D.DistanceMeasurement2DTool")],q);export{q as DistanceMeasurement2DTool,K as createDistanceMeasurementInfo2D,Y as createDistanceMeasurementLabel,Q as isSupported,X as loadGeometryOperators};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import type Graphic from "../../../Graphic.js";
|
|
2
2
|
import type EsriError from "../../../core/Error.js";
|
|
3
|
+
import type AnnotationFeatureLayer from "../../../layers/AnnotationFeatureLayer.js";
|
|
3
4
|
import type CSVLayer from "../../../layers/CSVLayer.js";
|
|
5
|
+
import type DimensionFeatureLayer from "../../../layers/DimensionFeatureLayer.js";
|
|
4
6
|
import type FeatureLayer from "../../../layers/FeatureLayer.js";
|
|
5
7
|
import type GeoJSONLayer from "../../../layers/GeoJSONLayer.js";
|
|
6
8
|
import type ImageryLayer from "../../../layers/ImageryLayer.js";
|
|
@@ -82,7 +84,7 @@ export interface FormatFunctionParameters {
|
|
|
82
84
|
}
|
|
83
85
|
|
|
84
86
|
/** @since 5.0 */
|
|
85
|
-
export type FeatureTableSupportedLayer = CatalogFootprintLayer | CSVLayer | FeatureLayer | GeoJSONLayer | ImageryLayer | KnowledgeGraphSublayer |
|
|
87
|
+
export type FeatureTableSupportedLayer = AnnotationFeatureLayer | CatalogFootprintLayer | CSVLayer | DimensionFeatureLayer | FeatureLayer | GeoJSONLayer | ImageryLayer | KnowledgeGraphSublayer | OrientedImageryLayer | ParquetLayer | SceneLayer | Sublayer | SubtypeSublayer | WFSLayer;
|
|
86
88
|
|
|
87
89
|
/** @since 5.0 */
|
|
88
90
|
export type FeatureTableSupportedColumn = Column;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import e from"../../../../Graphic.js";import{isSome as t}from"../../../../core/arrayUtils.js";import i from"../../../../core/Logger.js";import{waitTick as o,throwIfAborted as r,isAbortError as a}from"../../../../core/promiseUtils.js";import s from"../../../../geometry/Polygon.js";import{projectAsync as n}from"../../../../geometry/projectionUtils.js";import{
|
|
2
|
+
import e from"../../../../Graphic.js";import{isSome as t}from"../../../../core/arrayUtils.js";import i from"../../../../core/Logger.js";import{waitTick as o,throwIfAborted as r,isAbortError as a}from"../../../../core/promiseUtils.js";import s from"../../../../geometry/Polygon.js";import{projectAsync as n}from"../../../../geometry/projectionUtils.js";import{execute as l}from"../../../../geometry/operators/centroidOperator.js";import{adjustHorizonAngles as p,convertOrientationToPixelLocation as c}from"../../../../layers/orientedImagery/transformations/utils.js";import{fixedImageSize as u}from"../../constants.js";import{activePolygonSymbol as d,polygonSymbol as m}from"../../symbols.js";import{extractHorizonAnglesFromMedia as g}from"../../utils.js";class v{constructor(v){this.viewModel=v,this.createFootprints=async t=>{await o(t);const{coveragePolygons:i,currentBestFeature:r,isAdditionalCoverageVisible:a}=this.viewModel;for(const o of i)o?.imageID===r.attributes.objectId?this.viewModel.bestFeatureFootprint=new e({attributes:{imageID:o?.imageID},geometry:o,symbol:d,visible:!1}):this.viewModel.additionalFootprints.push(new e({attributes:{imageID:o?.imageID},geometry:o,symbol:m.clone(),visible:a}))},this.updateFootprint=async(o,l,p)=>{const{activeViewer:c,mode:m,currentBestFeature:g,currentCoverageVisible:v,footprintExtent:f}=this.viewModel,w=l??g;if(g&&("video"===m?u:c?.imageSize)&&f&&w)try{const i=await this.viewModel.getMapPoint(o);r(p);const a=i.filter(t);if(!a.length)return;const l=[a.map(({x:e,y:t})=>[e,t,1])];l[0].push(l[0][0]);const c=new s({rings:l,spatialReference:a[0].spatialReference}),u=this.viewModel.view?.spatialReference.equals(c.spatialReference)?c:await n(c,this.viewModel.view.spatialReference,p);this.viewModel.updateCurrentCoveragePolygon(new e({geometry:u,attributes:{imageID:w.attributes.objectId},symbol:d,visible:v}))}catch(h){a(h)||i.getLogger(this.viewModel).error("update-footprint",h)}else this.viewModel.updateCurrentCoveragePolygon(null)},this.updateVideoFootprint=async o=>{const{points:p,feature:c,scale:m,options:g}=o,{activeViewer:v,mode:f,currentBestFeature:w,currentCoverageVisible:h,footprintExtent:y}=this.viewModel,M="video"===f?u:v?.imageSize,b=c??w;if(w&&M&&y&&b&&"none"!==f)try{const i={feature:b,mode:f,imageSize:M,footprintExtent:y},o=await this.viewModel.getMapPointForFeature(p,i,g);r(g);const a=o.filter(t);if(!a.length)return;const c=[a.map(({x:e,y:t})=>[e,t,1])];c[0].push(c[0][0]);let u=new s({rings:c,spatialReference:a[0].spatialReference});if(m){const e=u.spatialReference,t=l(u),i=u.rings.map(e=>e.map(([e,i])=>[t.x+(e-t.x)*m,t.y+(i-t.y)*m]));u=new s({rings:i,spatialReference:e})}const v=this.viewModel.view?.spatialReference.equals(u.spatialReference)?u:await n(u,this.viewModel.view.spatialReference,g);this.viewModel.updateCurrentCoveragePolygon(new e({geometry:v,attributes:{imageID:b.attributes.objectId},symbol:d,visible:h}))}catch(C){a(C)||i.getLogger(this.viewModel).error("update-footprint",C)}else this.viewModel.updateCurrentCoveragePolygon(null)},this.updateFootprintPanorama=async(t,i)=>{const{horizontalFieldOfView:o,pitch:a,verticalFieldOfView:l,yaw:m,feature:v,horizonAngles:f}=t,{activeViewer:w,currentBestFeature:h,currentCoverageVisible:y,footprintExtent:M,mode:b}=this.viewModel,C="video"===b||"panoramic-video"===b?u:w?.imageSize,F=v??h;if(!F||!C||!M||"none"===b)return void this.viewModel.updateCurrentCoveragePolygon(null);const{cameraPitch:j,objectId:P}=F.attributes;if(a+j-l/2>180)return void this.viewModel.updateCurrentCoveragePolygon(null);const R=[],I=l/2,x=o/2,V=a-I,D=a+I;if(V>90)return void this.viewModel.updateCurrentCoveragePolygon(null);const z=V<0,E=[-x,I],S=[x,I],B=[x,-I],q=[-x,-I];if(V<90&&D>90){R.push(z?B:q);const e=Math.floor(o/5),t=o/e;for(let i=0;i<=e;i++)R.push([i*t-x,90-a]);R.push(z?q:B)}D<90&&(R.push(E,S),z?R.push(q,B):R.push(B,q));const L=f??g(w?.media),O=R.map(([e,t])=>{const i=a+t,o=m+e,r=L?p(o,i,L):[o,i];return{...c(r[0],r[1],C[0],C[1]),heading:o,pitch:i}}),U={feature:F,mode:b,imageSize:C,footprintExtent:M},A=v?await this.viewModel.getMapPointForFeature(O,U,i):await this.viewModel.getMapPoint(O,i);r(i);const G=[A.map(({x:e,y:t})=>[e,t,1])];G[0].push(G[0][0]);const k=new s({rings:G,spatialReference:A[0].spatialReference}),H=this.viewModel.view?.spatialReference;if(!H)return;const J=H.equals(k.spatialReference)?k:await n(k,H,i);this.viewModel.updateCurrentCoveragePolygon(new e({geometry:J,attributes:{imageID:P},symbol:d.clone(),visible:y}))}}}export{v as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{__decorate as e}from"tslib";import t from"../../../Map.js";import i from"../../../core/Error.js";import{EventedAccessor as r}from"../../../core/Evented.js";import a from"../../../core/Logger.js";import{clamp as s}from"../../../core/mathUtils.js";import{abortMaybe as o}from"../../../core/maybe.js";import{throwIfAborted as n,isAbortError as l}from"../../../core/promiseUtils.js";import{watch as h,syncAndInitial as m,when as d,initial as p}from"../../../core/reactiveUtils.js";import{property as c,subclass as g}from"../../../core/accessorSupport/decorators.js";import{UpdatingHandles as u}from"../../../core/support/UpdatingHandles.js";import y from"../../../geometry/Point.js";import _ from"../../../geometry/Polygon.js";import f from"../../../geometry/SpatialReference.js";import{
|
|
2
|
+
import{__decorate as e}from"tslib";import t from"../../../Map.js";import i from"../../../core/Error.js";import{EventedAccessor as r}from"../../../core/Evented.js";import a from"../../../core/Logger.js";import{clamp as s}from"../../../core/mathUtils.js";import{abortMaybe as o}from"../../../core/maybe.js";import{throwIfAborted as n,isAbortError as l}from"../../../core/promiseUtils.js";import{watch as h,syncAndInitial as m,when as d,initial as p}from"../../../core/reactiveUtils.js";import{property as c,subclass as g}from"../../../core/accessorSupport/decorators.js";import{UpdatingHandles as u}from"../../../core/support/UpdatingHandles.js";import y from"../../../geometry/Point.js";import _ from"../../../geometry/Polygon.js";import f from"../../../geometry/SpatialReference.js";import{execute as v}from"../../../geometry/operators/intersectionOperator.js";import R from"../../../layers/GraphicsLayer.js";import w from"../../../layers/support/RasterFunction.js";import{convolutionKernel as x}from"../../../layers/support/rasterFunctionConstants.js";import C from"../../../layers/support/TileInfo.js";import b from"../../../views/MapView.js";import{getResolutionToScaleFactor as I}from"../../../views/2d/viewpointUtils.js";import j from"../support/NonPanoramicMedia.js";import{rotate as P,constrainViewpoint as H}from"../support/panConstraint.js";const M={click:"click-handle",enhancements:"enhancements-handle"};let L=class extends r{constructor(e){super(e),this._imageChanged=!1,this._panConstraint=null,this._image=null,this._loadController=null,this._overlays=new R({blendMode:"source-atop"}),this._map=new t,this.autoLoad=!1,this.clickAction="none",this.error=null,this.imageRotation=0,this.state="ready",this.updatingHandles=new u,this._cancelLoadWithController=()=>{this._loadController=o(this._loadController)},this._createImageHandles=()=>{this.removeHandles(M.enhancements),this.addHandles(h(()=>[this.brightness,this.contrast,this.sharpness],([e,t,i])=>{this.image?.loaded&&(this.image.effect=`contrast(${10*(t+10)}%) brightness(${10*(e+10)}%)`,this.sharpenImage(this.image,i))},m))},this._createPanConstraint=()=>{const{image:e,imageRenderer:t}=this,i=i=>{const{constraints:r,height:a,width:s,rotation:o}=t,{targetGeometry:n}=i;return"point"===n?.type&&e?.serviceRasterInfo?(H({constraints:r,containerHeight:a,containerWidth:s,imageExtent:e.serviceRasterInfo.extent,rotation:o,viewpoint:i,viewportExtent:t.extent}),i):i};return{constrain:i,applyPanConstraint:i}},this._createResizeHandles=e=>{e.removeHandles("resize"),e.addHandles(h(()=>{if(!this.imageRenderer.ready)return;const{extent:t}=e.serviceRasterInfo,{width:i,height:r,rotation:a}=this.imageRenderer,{extent:s}=P(_.fromExtent(t),a,t.center.x,t.center.y),{width:o,height:n}=s;return Math.max(o/i,n/r)},e=>{if(!this.imageRenderer||null==e)return;const{constraints:t,scale:i,spatialReference:r}=this.imageRenderer,a=t.minScale,s=I(r),o=.25*s,n=s*e;let l=n;const h=[];for(;l>o;)h.push(l),l/=2;h.push(l);const{lods:m}=C.create({scales:h});if(t.set({minScale:n,lods:m}),this._imageChanged)return this.imageRenderer.scale=n,void(this._imageChanged=!1);this.imageRenderer.scale=Math.abs(i-a)<=1e-6?n:i},m),"resize")},this._loadMediaInternal=async(e,t)=>{if(this.state="image-loading",this.clearImage(),this.error=null,this._imageChanged=!0,!e)throw new Error("No media to load");try{const{layer:i}=await e.load(t);n(t),this._image=i,this._updatePanConstraint(),this._createResizeHandles(this._image),this._map.add(this._image),this.imageRotation=e.rotation??0,this.media=e,this.state="image-loaded"}catch(i){if(!l(i))throw this.state="image-load-error",this.error=i,a.getLogger(this).error(`error occurred while loading image ${this._image?.url}`,i),this._image=null,i;this.state="image-load-aborted"}return this._image},this._loadWithController=()=>{this._cancelLoadWithController(),this.media&&(this._loadController=new AbortController,this._loadMediaInternal(this.media,this._loadController))},this._updatePanConstraint=()=>{this._panConstraint&&this.imageRenderer.constraints.customConstraints.remove(this._panConstraint),this._panConstraint=this._createPanConstraint(),this.imageRenderer.constraints.customConstraints.add(this._panConstraint)},this.addGraphic=(e,t)=>{this._overlays.graphics.add(e,t)},this.addManyGraphics=e=>{this._overlays.addMany(e)},this.clearGraphics=()=>{this._overlays.graphics.removeAll()},this.clearImage=()=>{this.image&&this._map.layers.remove(this.image),this._image=null},this.removeGraphic=e=>{this._overlays.remove(e)},this.removeManyGraphics=e=>{this._overlays.removeMany(e)},this._imageRenderer=new b({constraints:{snapToZoom:!0,rotationEnabled:!1},map:this._map,popupEnabled:!1,spatialReference:f.WebMercator,attributionVisible:!1})}destroy(){this.clearImage(),this.media=null,this._imageRenderer.destroy()}initialize(){this.state="initialized",this.addHandles([d(()=>null!=this.media&&this.autoLoad,this._loadWithController,m),h(()=>this.image?.loaded,()=>{this._createImageHandles()}),h(()=>this.imageRotation,()=>{this._rotateImage()}),h(()=>this.imageRenderer.map,(e,t)=>{t?.layers.remove(this._overlays),e?.layers.add(this._overlays)},p),h(()=>this.imageRenderer.map.allLayers.length,e=>{e&&this.imageRenderer.map.layers.reorder(this._overlays,e-1)},m),h(()=>this.clickAction,e=>{this.removeHandles(M.click),"none"!==e&&this.addHandles(this.imageRenderer.on("click",t=>{if(this.image?.loaded&&this.imageRenderer.ready)switch(e){case"emit":t.stopPropagation(),this.emit("click",t);break;case"hittest":t.stopPropagation(),t.defer(async()=>{const e=await this.imageRenderer.hitTest(t.screenPoint,{include:this._overlays});e.results=e.results.filter(e=>"graphic"===e.type),this.emit("hittest-response",e)});break;case"pixel-location":{if(t.stopPropagation(),!this.image?.serviceRasterInfo||!t.mapPoint)return void this.emit("pixel-location",null);const{extent:e,pixelSize:i}=this.image.serviceRasterInfo,r=(t.mapPoint.x-e.xmin)*i.x,a=(e.ymax-t.mapPoint.y)*i.y,s=new y({x:r,y:a,spatialReference:e.spatialReference});this.emit("pixel-location",s);break}}}))},m)])}get brightness(){return this._get("brightness")??0}set brightness(e){this._set("brightness",s(e,-10,10))}get contrast(){return this._get("contrast")??0}set contrast(e){this._set("contrast",s(e,-10,10))}get image(){return this._image}get imagePointsInView(){const{extent:e,ready:t}=this.imageRenderer,i=this.imageRotation,r=this.image?.fullExtent,a=this.image?.serviceRasterInfo,s=!0===this._imageRenderer.allLayerViews.find(({layer:e})=>e===this.image)?.attached;if(!(t&&e&&r&&a&&s))return null;const o=P(_.fromExtent(e),i,e.center.x,e.center.y),n=_.fromExtent(r),l=v(o,n);if(!l)return null;const{rings:h}=l;return h.flat().map(([e,t])=>({x:(e-a.extent.xmin)*a.pixelSize.x,y:(a.extent.ymax-t)*a.pixelSize.y}))}get imageSize(){const{image:e}=this;if(!e?.raster)return null;const{width:t,height:i}=e.raster.rasterInfo;return[t,i]}get imageRenderer(){return this._imageRenderer}get imageView(){return this.imageRenderer.allLayerViews.find(e=>e.layer===this.image)}get sharpness(){return this._get("sharpness")??0}set sharpness(e){this._set("sharpness",s(e,0,1))}get updating(){return this.updatingHandles.updating}_rotateImage(){this.imageRenderer.constraints.rotationEnabled=!0,this.imageRenderer.rotation=this.imageRotation,this.imageRenderer.constraints.rotationEnabled=!1}sharpenImage(e,t){if(!t)return void(e.rasterFunction=null);const i=[0,-1*t,0,-1*t,4*t+1,-1*t,0,-1*t,0],r=new w({functionName:"Convolution",functionArguments:{type:x.userDefined,cols:3,rows:3,kernel:i,convolutionType:x.userDefined}});e.rasterFunction=r}async loadMedia(e,t){this.state="image-loading";const i=this.autoLoad;this.autoLoad=!1;return await this._loadMediaInternal(e,t).finally(()=>{this.autoLoad=i})}};e([c()],L.prototype,"_image",void 0),e([c()],L.prototype,"_imageRenderer",void 0),e([c()],L.prototype,"_loadController",void 0),e([c()],L.prototype,"_overlays",void 0),e([c()],L.prototype,"_map",void 0),e([c({type:Boolean})],L.prototype,"autoLoad",void 0),e([c({type:Number})],L.prototype,"brightness",null),e([c()],L.prototype,"clickAction",void 0),e([c({type:Number})],L.prototype,"contrast",null),e([c({type:Object})],L.prototype,"customParameters",void 0),e([c({type:i})],L.prototype,"error",void 0),e([c({readOnly:!0})],L.prototype,"image",null),e([c({readOnly:!0})],L.prototype,"imagePointsInView",null),e([c({readOnly:!0})],L.prototype,"imageSize",null),e([c({readOnly:!0})],L.prototype,"imageRenderer",null),e([c({type:Number})],L.prototype,"imageRotation",void 0),e([c()],L.prototype,"imageView",null),e([c({type:j})],L.prototype,"media",void 0),e([c({type:Number})],L.prototype,"sharpness",null),e([c()],L.prototype,"state",void 0),e([c()],L.prototype,"updatingHandles",void 0),e([c()],L.prototype,"updating",null),L=e([g("esri.widgets.OrientedImageryViewer.components.ImageViewerViewModel")],L);const E=L;export{E as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import{__decorate as e}from"tslib";import t from"../../../Graphic.js";import i from"../../../core/Accessor.js";import{createTask as o}from"../../../core/asyncUtils.js";import r from"../../../core/Logger.js";import{throwIfAborted as n,isAbortError as s}from"../../../core/promiseUtils.js";import{watch as a,syncAndInitial as d}from"../../../core/reactiveUtils.js";import{property as l,subclass as c}from"../../../core/accessorSupport/decorators.js";import p from"../../../geometry/Extent.js";import h from"../../../geometry/Multipoint.js";import u from"../../../geometry/Polygon.js";import m from"../../../geometry/Polyline.js";import{projectAsync as V}from"../../../geometry/projectionUtils.js";import{e as v}from"../../../chunks/clipOperator.js";import{e as f}from"../../../chunks/intersectionOperator.js";import{createCoveragePolygon as y}from"../../../layers/orientedImagery/core/coverageUtils.js";import{getResolutionToScaleFactor as w}from"../../../views/2d/viewpointUtils.js";import{fixedImageSize as g,videoSpatialReference as M,sampleExtent as P,videoFitScaleTolerance as O}from"../constants.js";import{diamondSymbol as _,crossSymbol as F}from"../symbols.js";import{registryKeys as S}from"../types.js";import{imageGeometryToVideoMapGeometry as x,pixelToVideoMapPoint as R,geoToPixel as E}from"../videoViewerUtils.js";import{coordinateToPoints as L}from"../support/geometryUtils.js";const[j,C]=g,b=new p({...P,spatialReference:M});function G({x:e,y:t}){return[P.xmin+e/j*(P.xmax-P.xmin),P.ymax-t/C*(P.ymax-P.ymin)]}function I(e){if(e.length<2)return[];const t=new m({paths:[e.map(e=>G(e))],spatialReference:M}),i=v(t,b);return"polyline"===i?.type?i.paths:[]}async function T(e,t,i){let o=y(t.attributes).polygon;e.spatialReference.equals(o.spatialReference)||(o=await V(o,e.spatialReference,i),n(i));const r=f(e,o);return"polyline"===r?.type?r:null}async function H(e,t,i){let o=y(t.attributes).polygon;e.spatialReference.equals(o.spatialReference)||(o=await V(o,e.spatialReference,i),n(i));const r=f(e,o);return"polygon"===r?.type?r:null}let A=class extends i{constructor(e){super(e),this.closestFeature=null,this.currentTime=0,this.videoBrightness=0,this.videoContrast=0,this.videoDuration=void 0,this.videoPaused=null,this.videoScale=void 0,this.videoMuted=null,this._referencePointOnVideo=null,this._selectedPointOnVideo=null,this.enableAudio=()=>{const{videoElement:e}=this.oiViewModel;e?.content&&(e.content.muted=!1,this.videoMuted=!1)},this.playVideoHandler=()=>{const e=this.oiViewModel.videoElement?.content;e&&(e.paused?e.play().catch(e=>{r.getLogger(this).error("error playing video",e)}):e.pause())},this.rewindVideoHandler=()=>{const e=this.oiViewModel.videoElement?.content;e&&(e.currentTime=0,e.play().catch(e=>{r.getLogger(this).error("error playing video",e)}))},this.resetVideoHandler=()=>{const{videoElement:e,videoMapView:t,videoLayer:i}=this.oiViewModel;this.removeHandles(S.videoImageClick),this.closestFeature=null,this.clearReferencePointOnVideo(),this.clearOverlayGraphics(),e?.content&&i&&t&&(e.content.pause(),t.map.layers.remove(i),i.destroy(),this.oiViewModel.videoElement=null)},this.resetVideoEnhancementTools=()=>{this.oiViewModel?.videoLayer&&(this.videoBrightness=0,this.videoContrast=0,this._updateVideoEffect())},this.resetVideoScale=()=>{this.videoScale&&(this.oiViewModel.videoMapView.scale=this.videoScale)},this.toggleAudio=()=>{const{videoElement:e}=this.oiViewModel;if(e?.content){const t=e.content.muted;e.content.muted=!t,this.videoMuted=!t}}}initialize(){this.addHandles([a(()=>this.oiViewModel.videoElement?.content,e=>{if(e instanceof HTMLVideoElement){this._startVideo();const t=async()=>{this.currentTime=Number(e.currentTime.toFixed(2)),e.currentTime&&await this._updateVidFootprint(e.currentTime)};e.addEventListener("timeupdate",t),e.addEventListener("play",()=>this._updateVideoIcon(e.paused)),e.addEventListener("pause",()=>this._pauseVideoHandler(e))}},d),a(()=>this._videoMinResolutionForCurrentView,e=>{null!=e&&this._updateVideoScaleForResize(e)},d),a(()=>this.oiViewModel.layer,(e,t)=>{t&&e&&e.uid!==t.uid&&this.oiViewModel.resetVideo()},d)])}destroy(){this.resetVideoHandler()}_pauseVideoHandler(e){this._updateVideoIcon(e.paused),e.paused&&this.oiViewModel.transformAndPlotSelectedLocation()}get _videoMinResolutionForCurrentView(){const{mode:e,videoMapView:t}=this.oiViewModel;if("video"!==e||!t.ready)return;const{width:i,height:o}=t;return i&&o?Math.max(b.width/i,b.height/o):void 0}_updateVideoScaleForResize(e){const{videoMapView:t}=this.oiViewModel,{constraints:i,scale:o,spatialReference:r}=t,n=i.minScale,s=Math.abs(o-n)<=O,a=w(r)*e;i.set({minScale:a}),this.videoScale=a,t.scale=s?a:o,s&&requestAnimationFrame(()=>{const{extent:e,scale:i,constraints:o}=t;e&&Math.abs(i-o.minScale)<=O&&(this.oiViewModel.initialVideoMapViewExtent=e.clone())})}_setVideoInfo(){const{videoElement:e,videoMapView:t}=this.oiViewModel;e?.content&&(this.videoDuration=e.content.duration,this.videoScale=t.scale)}_startVideo(){try{this.enableAudio(),this._setVideoInfo();const e=this.oiViewModel.currentBestFeature;e&&this.playVideoFromSelectedLocation(e)}catch(e){r.getLogger(this).error("oriented-imagery-viewer:video-load",e)}}async _updateVideoFootprintWithGivenFeature(e,t,i){const{activeViewer:o,mode:a,footprintExtent:d}=this.oiViewModel;if(t&&("video"===a?g:o?.imageSize)&&d)try{const o={points:e,feature:t,undefined:void 0,options:i};await this.oiViewModel.updateVideoFootprint(o),n(i)}catch(l){s(l)||r.getLogger(this).error("update-footprint",l)}else this.oiViewModel.updateCurrentCoveragePolygon(null)}async _updateVidFootprint(e){const t=this.oiViewModel.featureCache.find(t=>t.attributes.offsetFromStart===Math.floor(e));null!=t?.attributes.offsetFromStart&&this.closestFeature!==t&&(this.closestFeature=t,await this._updateVideoFootprintWithGivenFeature(this.oiViewModel.videoExtentPoints,t))}_updateVideoIcon(e){this.videoPaused=!!e,!e&&this.oiViewModel.mapImageConversionToolState&&(this.oiViewModel.setMapImageConversionToolState(!1),this.oiViewModel.plotReferencePointOnGround(null),this.clearReferencePointOnVideo()),e||(this.oiViewModel.clearSelectedPointOnViewer(),this.clearOverlayGraphics())}_updateVideoEffect(){if(!this.oiViewModel?.videoLayer)return;const e=1+this.videoBrightness/10,t=1+this.videoContrast/10;this.oiViewModel.videoLayer.effect=`brightness(${e}) contrast(${t})`}handleVideoBrightnessChange(e){this.oiViewModel?.videoLayer&&(this.videoBrightness=e??0,this._updateVideoEffect())}handleVideoContrastChange(e){this.oiViewModel?.videoLayer&&(this.videoContrast=e??0,this._updateVideoEffect())}playVideoFromSelectedLocation(e){const t=e.attributes.offsetFromStart,i=this.oiViewModel.videoElement?.content;this.closestFeature=e,this.resetVideoScale(),this.clearOverlayGraphics(),i&&null!=t&&(i.currentTime=t,i.play().catch(e=>{r.getLogger(this).error("error playing video",e)}))}addOverlayGraphics(e){this.oiViewModel.videoMapView.graphics.addMany(e)}imageGeometryToOverlayGeometry(e){return x(e)}async geometryToOverlayGeometry(e,t,i){const{footprintExtent:o}=this.oiViewModel;if(!o)return null;const r={feature:t,mode:"video",imageSize:g,footprintExtent:o};switch(e.type){case"point":{const t=await this.oiViewModel.getPixelLocationForFeature(e,r,i);return R(t)}case"polyline":{const o=await T(e,t,i);if(!o)return null;const s=(await Promise.all(o.paths.map(async t=>{const o=t.map(t=>L(t,e.spatialReference)),s=await this.oiViewModel.getPixelLocationsForFeature(o,r,i);return n(i),I(s)}))).flat();return s.length?new m({paths:s,spatialReference:M}):null}case"polygon":{const o=await H(e,t,i);if(!o)return null;const s=await Promise.all(o.rings.map(async t=>{const o=t.map(t=>L(t,e.spatialReference)),s=await this.oiViewModel.getPixelLocationsForFeature(o,r,i);return n(i),s.map(e=>{const t=R(e);return[t.x,t.y]})}));return u.fromJSON({rings:s,spatialReference:M})}case"multipoint":{const t=e.points.map(t=>L(t,e.spatialReference)),o=await this.oiViewModel.getPixelLocationsForFeature(t,r,i);return n(i),h.fromJSON({points:o.map(e=>{const t=R(e);return[t.x,t.y]}),spatialReference:M})}case"extent":{const o=u.fromExtent(e),r=await this.geometryToOverlayGeometry(o,t,i);return r?.extent??null}default:return null}}removeOverlayGraphics(e){this.oiViewModel.videoMapView.graphics.removeMany(e)}clearOverlayGraphics(){const e=Array.from(this.oiViewModel.overlayedMapFeatures.values()).flatMap(e=>e.toArray()),t=this.oiViewModel.videoMapView.graphics.toArray().filter(e=>e!==this._referencePointOnVideo&&e!==this._selectedPointOnVideo),i=Array.from(new Set([...this.oiViewModel.overlayedCameraLocations.toArray(),...e,...t]));i.length&&this.removeOverlayGraphics(i)}syncMapImageConversionHandle(){this.removeHandles(S.videoImageClick);const{currentBestFeature:e,footprintExtent:t,mode:i,mapImageConversionToolState:r,state:s,view:a,videoMapView:d}=this.oiViewModel;if(!r||!0!==this.videoPaused||"video-loaded"!==s||!t||!e)return;let l=null;const c=d.on("click",e=>{if(e.stopPropagation(),e.preventDefault(),!e.mapPoint)return;const r=E(e.mapPoint.x,e.mapPoint.y);this.oiViewModel.plotReferencePointOnImage(r),l?.abort(),l=o(async e=>{const o=this.closestFeature??this.oiViewModel.currentBestFeature;if(!o)return;const s={feature:o,mode:i,imageSize:g,footprintExtent:t};let d=await this.oiViewModel.getMapPointForFeature(r,s,{signal:e});n(e);const l=a?.spatialReference;l&&!d.spatialReference.equals(l)&&(d=await V(d,l),n(e)),this.oiViewModel.plotReferencePointOnGround(d)})});this.addHandles(c,S.videoImageClick)}plotReferencePointOnVideo(e){this.clearReferencePointOnVideo(),this._referencePointOnVideo=new t({geometry:R(e),symbol:_.clone()}),this.oiViewModel.videoMapView.graphics.add(this._referencePointOnVideo)}plotSelectedPointOnVideo(e){return this.clearSelectedPointOnVideo(),this._selectedPointOnVideo=new t({geometry:R(e),symbol:F.clone()}),this.oiViewModel.videoMapView.graphics.add(this._selectedPointOnVideo),this._selectedPointOnVideo}clearReferencePointOnVideo(){this._referencePointOnVideo&&(this.oiViewModel.videoMapView.graphics.remove(this._referencePointOnVideo),this._referencePointOnVideo.destroy(),this._referencePointOnVideo=null)}clearSelectedPointOnVideo(){this._selectedPointOnVideo&&(this.oiViewModel.videoMapView.graphics.remove(this._selectedPointOnVideo),this._selectedPointOnVideo.destroy(),this._selectedPointOnVideo=null)}};e([l()],A.prototype,"closestFeature",void 0),e([l()],A.prototype,"currentTime",void 0),e([l()],A.prototype,"oiViewModel",void 0),e([l({type:Number})],A.prototype,"videoBrightness",void 0),e([l({type:Number})],A.prototype,"videoContrast",void 0),e([l()],A.prototype,"videoDuration",void 0),e([l()],A.prototype,"videoPaused",void 0),e([l()],A.prototype,"videoScale",void 0),e([l()],A.prototype,"videoMuted",void 0),e([l()],A.prototype,"_referencePointOnVideo",void 0),e([l()],A.prototype,"_selectedPointOnVideo",void 0),e([l()],A.prototype,"_videoMinResolutionForCurrentView",null),A=e([c("esri.widgets.OrientedImageryViewer.components.OrientedImageryVideoViewModel")],A);const B=A;export{B as default};
|
|
2
|
+
import{__decorate as e}from"tslib";import t from"../../../Graphic.js";import i from"../../../core/Accessor.js";import{createTask as o}from"../../../core/asyncUtils.js";import r from"../../../core/Logger.js";import{throwIfAborted as n,isAbortError as s}from"../../../core/promiseUtils.js";import{watch as a,syncAndInitial as d}from"../../../core/reactiveUtils.js";import{property as l,subclass as c}from"../../../core/accessorSupport/decorators.js";import p from"../../../geometry/Extent.js";import h from"../../../geometry/Multipoint.js";import u from"../../../geometry/Polygon.js";import m from"../../../geometry/Polyline.js";import{projectAsync as V}from"../../../geometry/projectionUtils.js";import{execute as v}from"../../../geometry/operators/clipOperator.js";import{execute as f}from"../../../geometry/operators/intersectionOperator.js";import{createCoveragePolygon as y}from"../../../layers/orientedImagery/core/coverageUtils.js";import{getResolutionToScaleFactor as w}from"../../../views/2d/viewpointUtils.js";import{fixedImageSize as g,videoSpatialReference as M,sampleExtent as P,videoFitScaleTolerance as O}from"../constants.js";import{diamondSymbol as _,crossSymbol as F}from"../symbols.js";import{registryKeys as S}from"../types.js";import{imageGeometryToVideoMapGeometry as x,pixelToVideoMapPoint as R,geoToPixel as E}from"../videoViewerUtils.js";import{coordinateToPoints as L}from"../support/geometryUtils.js";const[j,C]=g,b=new p({...P,spatialReference:M});function G({x:e,y:t}){return[P.xmin+e/j*(P.xmax-P.xmin),P.ymax-t/C*(P.ymax-P.ymin)]}function I(e){if(e.length<2)return[];const t=new m({paths:[e.map(e=>G(e))],spatialReference:M}),i=v(t,b);return"polyline"===i?.type?i.paths:[]}async function T(e,t,i){let o=y(t.attributes).polygon;e.spatialReference.equals(o.spatialReference)||(o=await V(o,e.spatialReference,i),n(i));const r=f(e,o);return"polyline"===r?.type?r:null}async function H(e,t,i){let o=y(t.attributes).polygon;e.spatialReference.equals(o.spatialReference)||(o=await V(o,e.spatialReference,i),n(i));const r=f(e,o);return"polygon"===r?.type?r:null}let A=class extends i{constructor(e){super(e),this.closestFeature=null,this.currentTime=0,this.videoBrightness=0,this.videoContrast=0,this.videoDuration=void 0,this.videoPaused=null,this.videoScale=void 0,this.videoMuted=null,this._referencePointOnVideo=null,this._selectedPointOnVideo=null,this.enableAudio=()=>{const{videoElement:e}=this.oiViewModel;e?.content&&(e.content.muted=!1,this.videoMuted=!1)},this.playVideoHandler=()=>{const e=this.oiViewModel.videoElement?.content;e&&(e.paused?e.play().catch(e=>{r.getLogger(this).error("error playing video",e)}):e.pause())},this.rewindVideoHandler=()=>{const e=this.oiViewModel.videoElement?.content;e&&(e.currentTime=0,e.play().catch(e=>{r.getLogger(this).error("error playing video",e)}))},this.resetVideoHandler=()=>{const{videoElement:e,videoMapView:t,videoLayer:i}=this.oiViewModel;this.removeHandles(S.videoImageClick),this.closestFeature=null,this.clearReferencePointOnVideo(),this.clearOverlayGraphics(),e?.content&&i&&t&&(e.content.pause(),t.map.layers.remove(i),i.destroy(),this.oiViewModel.videoElement=null)},this.resetVideoEnhancementTools=()=>{this.oiViewModel?.videoLayer&&(this.videoBrightness=0,this.videoContrast=0,this._updateVideoEffect())},this.resetVideoScale=()=>{this.videoScale&&(this.oiViewModel.videoMapView.scale=this.videoScale)},this.toggleAudio=()=>{const{videoElement:e}=this.oiViewModel;if(e?.content){const t=e.content.muted;e.content.muted=!t,this.videoMuted=!t}}}initialize(){this.addHandles([a(()=>this.oiViewModel.videoElement?.content,e=>{if(e instanceof HTMLVideoElement){this._startVideo();const t=async()=>{this.currentTime=Number(e.currentTime.toFixed(2)),e.currentTime&&await this._updateVidFootprint(e.currentTime)};e.addEventListener("timeupdate",t),e.addEventListener("play",()=>this._updateVideoIcon(e.paused)),e.addEventListener("pause",()=>this._pauseVideoHandler(e))}},d),a(()=>this._videoMinResolutionForCurrentView,e=>{null!=e&&this._updateVideoScaleForResize(e)},d),a(()=>this.oiViewModel.layer,(e,t)=>{t&&e&&e.uid!==t.uid&&this.oiViewModel.resetVideo()},d)])}destroy(){this.resetVideoHandler()}_pauseVideoHandler(e){this._updateVideoIcon(e.paused),e.paused&&this.oiViewModel.transformAndPlotSelectedLocation()}get _videoMinResolutionForCurrentView(){const{mode:e,videoMapView:t}=this.oiViewModel;if("video"!==e||!t.ready)return;const{width:i,height:o}=t;return i&&o?Math.max(b.width/i,b.height/o):void 0}_updateVideoScaleForResize(e){const{videoMapView:t}=this.oiViewModel,{constraints:i,scale:o,spatialReference:r}=t,n=i.minScale,s=Math.abs(o-n)<=O,a=w(r)*e;i.set({minScale:a}),this.videoScale=a,t.scale=s?a:o,s&&requestAnimationFrame(()=>{const{extent:e,scale:i,constraints:o}=t;e&&Math.abs(i-o.minScale)<=O&&(this.oiViewModel.initialVideoMapViewExtent=e.clone())})}_setVideoInfo(){const{videoElement:e,videoMapView:t}=this.oiViewModel;e?.content&&(this.videoDuration=e.content.duration,this.videoScale=t.scale)}_startVideo(){try{this.enableAudio(),this._setVideoInfo();const e=this.oiViewModel.currentBestFeature;e&&this.playVideoFromSelectedLocation(e)}catch(e){r.getLogger(this).error("oriented-imagery-viewer:video-load",e)}}async _updateVideoFootprintWithGivenFeature(e,t,i){const{activeViewer:o,mode:a,footprintExtent:d}=this.oiViewModel;if(t&&("video"===a?g:o?.imageSize)&&d)try{const o={points:e,feature:t,undefined:void 0,options:i};await this.oiViewModel.updateVideoFootprint(o),n(i)}catch(l){s(l)||r.getLogger(this).error("update-footprint",l)}else this.oiViewModel.updateCurrentCoveragePolygon(null)}async _updateVidFootprint(e){const t=this.oiViewModel.featureCache.find(t=>t.attributes.offsetFromStart===Math.floor(e));null!=t?.attributes.offsetFromStart&&this.closestFeature!==t&&(this.closestFeature=t,await this._updateVideoFootprintWithGivenFeature(this.oiViewModel.videoExtentPoints,t))}_updateVideoIcon(e){this.videoPaused=!!e,!e&&this.oiViewModel.mapImageConversionToolState&&(this.oiViewModel.setMapImageConversionToolState(!1),this.oiViewModel.plotReferencePointOnGround(null),this.clearReferencePointOnVideo()),e||(this.oiViewModel.clearSelectedPointOnViewer(),this.clearOverlayGraphics())}_updateVideoEffect(){if(!this.oiViewModel?.videoLayer)return;const e=1+this.videoBrightness/10,t=1+this.videoContrast/10;this.oiViewModel.videoLayer.effect=`brightness(${e}) contrast(${t})`}handleVideoBrightnessChange(e){this.oiViewModel?.videoLayer&&(this.videoBrightness=e??0,this._updateVideoEffect())}handleVideoContrastChange(e){this.oiViewModel?.videoLayer&&(this.videoContrast=e??0,this._updateVideoEffect())}playVideoFromSelectedLocation(e){const t=e.attributes.offsetFromStart,i=this.oiViewModel.videoElement?.content;this.closestFeature=e,this.resetVideoScale(),this.clearOverlayGraphics(),i&&null!=t&&(i.currentTime=t,i.play().catch(e=>{r.getLogger(this).error("error playing video",e)}))}addOverlayGraphics(e){this.oiViewModel.videoMapView.graphics.addMany(e)}imageGeometryToOverlayGeometry(e){return x(e)}async geometryToOverlayGeometry(e,t,i){const{footprintExtent:o}=this.oiViewModel;if(!o)return null;const r={feature:t,mode:"video",imageSize:g,footprintExtent:o};switch(e.type){case"point":{const t=await this.oiViewModel.getPixelLocationForFeature(e,r,i);return R(t)}case"polyline":{const o=await T(e,t,i);if(!o)return null;const s=(await Promise.all(o.paths.map(async t=>{const o=t.map(t=>L(t,e.spatialReference)),s=await this.oiViewModel.getPixelLocationsForFeature(o,r,i);return n(i),I(s)}))).flat();return s.length?new m({paths:s,spatialReference:M}):null}case"polygon":{const o=await H(e,t,i);if(!o)return null;const s=await Promise.all(o.rings.map(async t=>{const o=t.map(t=>L(t,e.spatialReference)),s=await this.oiViewModel.getPixelLocationsForFeature(o,r,i);return n(i),s.map(e=>{const t=R(e);return[t.x,t.y]})}));return u.fromJSON({rings:s,spatialReference:M})}case"multipoint":{const t=e.points.map(t=>L(t,e.spatialReference)),o=await this.oiViewModel.getPixelLocationsForFeature(t,r,i);return n(i),h.fromJSON({points:o.map(e=>{const t=R(e);return[t.x,t.y]}),spatialReference:M})}case"extent":{const o=u.fromExtent(e),r=await this.geometryToOverlayGeometry(o,t,i);return r?.extent??null}default:return null}}removeOverlayGraphics(e){this.oiViewModel.videoMapView.graphics.removeMany(e)}clearOverlayGraphics(){const e=Array.from(this.oiViewModel.overlayedMapFeatures.values()).flatMap(e=>e.toArray()),t=this.oiViewModel.videoMapView.graphics.toArray().filter(e=>e!==this._referencePointOnVideo&&e!==this._selectedPointOnVideo),i=Array.from(new Set([...this.oiViewModel.overlayedCameraLocations.toArray(),...e,...t]));i.length&&this.removeOverlayGraphics(i)}syncMapImageConversionHandle(){this.removeHandles(S.videoImageClick);const{currentBestFeature:e,footprintExtent:t,mode:i,mapImageConversionToolState:r,state:s,view:a,videoMapView:d}=this.oiViewModel;if(!r||!0!==this.videoPaused||"video-loaded"!==s||!t||!e)return;let l=null;const c=d.on("click",e=>{if(e.stopPropagation(),e.preventDefault(),!e.mapPoint)return;const r=E(e.mapPoint.x,e.mapPoint.y);this.oiViewModel.plotReferencePointOnImage(r),l?.abort(),l=o(async e=>{const o=this.closestFeature??this.oiViewModel.currentBestFeature;if(!o)return;const s={feature:o,mode:i,imageSize:g,footprintExtent:t};let d=await this.oiViewModel.getMapPointForFeature(r,s,{signal:e});n(e);const l=a?.spatialReference;l&&!d.spatialReference.equals(l)&&(d=await V(d,l),n(e)),this.oiViewModel.plotReferencePointOnGround(d)})});this.addHandles(c,S.videoImageClick)}plotReferencePointOnVideo(e){this.clearReferencePointOnVideo(),this._referencePointOnVideo=new t({geometry:R(e),symbol:_.clone()}),this.oiViewModel.videoMapView.graphics.add(this._referencePointOnVideo)}plotSelectedPointOnVideo(e){return this.clearSelectedPointOnVideo(),this._selectedPointOnVideo=new t({geometry:R(e),symbol:F.clone()}),this.oiViewModel.videoMapView.graphics.add(this._selectedPointOnVideo),this._selectedPointOnVideo}clearReferencePointOnVideo(){this._referencePointOnVideo&&(this.oiViewModel.videoMapView.graphics.remove(this._referencePointOnVideo),this._referencePointOnVideo.destroy(),this._referencePointOnVideo=null)}clearSelectedPointOnVideo(){this._selectedPointOnVideo&&(this.oiViewModel.videoMapView.graphics.remove(this._selectedPointOnVideo),this._selectedPointOnVideo.destroy(),this._selectedPointOnVideo=null)}};e([l()],A.prototype,"closestFeature",void 0),e([l()],A.prototype,"currentTime",void 0),e([l()],A.prototype,"oiViewModel",void 0),e([l({type:Number})],A.prototype,"videoBrightness",void 0),e([l({type:Number})],A.prototype,"videoContrast",void 0),e([l()],A.prototype,"videoDuration",void 0),e([l()],A.prototype,"videoPaused",void 0),e([l()],A.prototype,"videoScale",void 0),e([l()],A.prototype,"videoMuted",void 0),e([l()],A.prototype,"_referencePointOnVideo",void 0),e([l()],A.prototype,"_selectedPointOnVideo",void 0),e([l()],A.prototype,"_videoMinResolutionForCurrentView",null),A=e([c("esri.widgets.OrientedImageryViewer.components.OrientedImageryVideoViewModel")],A);const B=A;export{B as default};
|