@arcgis/core 4.34.0-next.110 → 4.34.0-next.112
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/PopupTemplate.js +1 -1
- package/analysis/VolumeMeasurement/volumeMeasurementConfiguration.js +1 -1
- package/arcade/functions/knowledgegraph.js +1 -1
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/07fd94b1d5f39356565b.js +1 -0
- package/assets/esri/core/workers/chunks/{49c1e69793d49a0fe1fd.js → 16d66770ef841564ee3f.js} +1 -1
- package/assets/esri/core/workers/chunks/17103e6542aae53c7301.js +1 -0
- package/assets/esri/core/workers/chunks/188272af9a6470ccfe31.js +1 -0
- package/assets/esri/core/workers/chunks/1d807057327ba90ab770.js +1 -0
- package/assets/esri/core/workers/chunks/{509392131ec473d6b988.js → 1dfca37f95f2b968aa54.js} +1 -1
- package/assets/esri/core/workers/chunks/2248c3040e2f9a8b5cbc.js +1 -0
- package/assets/esri/core/workers/chunks/2266a8f2c2ec37c19bb4.js +1 -0
- package/assets/esri/core/workers/chunks/297b11752f9c251cd7be.js +1 -0
- package/assets/esri/core/workers/chunks/2bbe8277578b033f92d4.js +1 -0
- package/assets/esri/core/workers/chunks/2ca8b0c1ca399fd5dc2f.js +1 -0
- package/assets/esri/core/workers/chunks/2f9e79a67eae746d55d3.js +1 -0
- package/assets/esri/core/workers/chunks/{91edfa6f93ffba500853.js → 3116b35a92cc0afd9fd3.js} +1 -1
- package/assets/esri/core/workers/chunks/3495162f4608f5205d87.js +1 -0
- package/assets/esri/core/workers/chunks/36fe6b8228e622407ec2.js +1 -0
- package/assets/esri/core/workers/chunks/374831c7e3d88bc473b8.js +1 -0
- package/assets/esri/core/workers/chunks/{06e60fc7715d08ede59d.js → 3edffdb0e282ed562ac7.js} +1 -1
- package/assets/esri/core/workers/chunks/3ffdf73aaecc42448f8a.js +1 -0
- package/assets/esri/core/workers/chunks/4239572007ecfac49dc1.js +1 -0
- package/assets/esri/core/workers/chunks/441ead5bce80f639934e.js +1 -0
- package/assets/esri/core/workers/chunks/4470a3fff217f2bfeec5.js +1 -0
- package/assets/esri/core/workers/chunks/44c3b5a507814103f4b4.js +1 -0
- package/assets/esri/core/workers/chunks/44e40484acb577039c82.js +1 -0
- package/assets/esri/core/workers/chunks/4a73622445536b8c55f1.js +1 -0
- package/assets/esri/core/workers/chunks/524293f92791c55f6e2c.js +1 -0
- package/assets/esri/core/workers/chunks/5e60542f80bdacb6e7af.js +1 -0
- package/assets/esri/core/workers/chunks/616e3d1947eda575a25a.js +1 -0
- package/assets/esri/core/workers/chunks/620a94b54be3ed78350d.js +1 -0
- package/assets/esri/core/workers/chunks/{fe690be68faf6985d4b5.js → 740e6d2831dcb01ee96a.js} +1 -1
- package/assets/esri/core/workers/chunks/75535e2e487ed2616acf.js +1 -0
- package/assets/esri/core/workers/chunks/7698f4f4471b6e1c12ef.js +1 -0
- package/assets/esri/core/workers/chunks/7786fc1b3779df832e0a.js +1 -0
- package/assets/esri/core/workers/chunks/7810f870d71f80ca4f41.js +1 -0
- package/assets/esri/core/workers/chunks/78b35a19332e58c8c279.js +1 -0
- package/assets/esri/core/workers/chunks/7a9a0fcf78a1863c5dea.js +1 -0
- package/assets/esri/core/workers/chunks/80c492f8fdab7698596a.js +1 -0
- package/assets/esri/core/workers/chunks/80d2182dac1a49cfd923.js +1 -0
- package/assets/esri/core/workers/chunks/81501abaabf10e9bef1b.js +1 -0
- package/assets/esri/core/workers/chunks/82f1cd3896401c85df35.js +1 -0
- package/assets/esri/core/workers/chunks/868ee8f429e7caddc045.js +1 -0
- package/assets/esri/core/workers/chunks/{11e96a312f1294d34c50.js → 881df4fd1dc594576457.js} +1 -1
- package/assets/esri/core/workers/chunks/8cf2669900bb45cb094a.js +1 -0
- package/assets/esri/core/workers/chunks/8ec6ad6d76b4755a4cf6.js +1 -0
- package/assets/esri/core/workers/chunks/92c306d02569e7cd9af3.js +1 -0
- package/assets/esri/core/workers/chunks/98dbafa4d45fdf790fff.js +1 -0
- package/assets/esri/core/workers/chunks/9c571ff94911f7c4459a.js +1 -0
- package/assets/esri/core/workers/chunks/9dc6eeaac94aff385cf9.js +1 -0
- package/assets/esri/core/workers/chunks/9e4f37367d61a2e13053.js +1 -0
- package/assets/esri/core/workers/chunks/9e5e05d6430712b0b1bc.js +1 -0
- package/assets/esri/core/workers/chunks/a16526adc0dbffdc1ffc.js +1 -0
- package/assets/esri/core/workers/chunks/a1c4509a3865139eb570.js +1 -0
- package/assets/esri/core/workers/chunks/a33a0b6700a860153a67.js +1 -0
- package/assets/esri/core/workers/chunks/ae6066ea6cb373dc6db3.js +1 -0
- package/assets/esri/core/workers/chunks/aea8553a2aa54cfd694b.js +1 -0
- package/assets/esri/core/workers/chunks/af0f82f7efa6e983eca5.js +1 -0
- package/assets/esri/core/workers/chunks/bd02e9d6c7ba491dd35f.js +1 -0
- package/assets/esri/core/workers/chunks/{6d97aa70848cd9bad680.js → bf9b2949894cc2a1e6b3.js} +1 -1
- package/assets/esri/core/workers/chunks/bfc1e8aec7aace3ff30e.js +1 -0
- package/assets/esri/core/workers/chunks/c55c096669677321a227.js +1 -0
- package/assets/esri/core/workers/chunks/cd3b843ffd4010038c74.js +1 -0
- package/assets/esri/core/workers/chunks/d0767001601412f17ada.js +1 -0
- package/assets/esri/core/workers/chunks/d5fa879de92da4441771.js +1 -0
- package/assets/esri/core/workers/chunks/dec0ed841f9ff1ceff43.js +1 -0
- package/assets/esri/core/workers/chunks/e7b96da2a615086d91a7.js +1 -0
- package/assets/esri/core/workers/chunks/e7c9d9e1205a8e246bfa.js +1 -0
- package/assets/esri/core/workers/chunks/f06d185e7defc4272ae7.js +1 -0
- package/assets/esri/core/workers/chunks/f2f3ce7a0f3e394d27c4.js +1 -0
- package/assets/esri/core/workers/chunks/f98689562017583f73ee.js +1 -0
- package/assets/esri/core/workers/chunks/{498331263094c442d11f.js → fd410a56286f9b8a5903.js} +15 -15
- package/assets/esri/libs/parquet/pkg/bundle_bg.wasm +0 -0
- package/assets/esri/themes/base/widgets/_Editor.scss +35 -2
- package/assets/esri/themes/base/widgets/_FeatureTable.scss +2 -0
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/chunks/Envelope.js +1 -1
- package/chunks/Geometry.js +1 -1
- package/chunks/MultiPathImpl.js +1 -1
- package/chunks/Point2D.js +1 -1
- package/chunks/UnitFactory.js +1 -1
- package/chunks/containsOperator.js +1 -1
- package/chunks/densifyOperator.js +1 -1
- package/chunks/differenceOperator.js +1 -1
- package/chunks/intersectsOperator.js +1 -1
- package/chunks/persistableUrlUtils.js +1 -1
- package/config.js +1 -1
- package/core/SetUtils.js +1 -1
- package/core/libs/gl-matrix-2/math/quat.js +1 -1
- package/core/unitUtils.js +1 -1
- package/editing/fieldUtils.js +5 -0
- package/geometry/Extent.js +1 -1
- package/geometry/Geometry.js +1 -1
- package/geometry/Point.js +1 -1
- package/geometry/SpatialReference.js +1 -1
- package/geometry/ellipsoidUtils.js +1 -1
- package/geometry/operators/support/jsonConverter.js +1 -1
- package/geometry/support/MeshTransform.js +1 -1
- package/geometry/support/axisAngleDegrees.js +1 -1
- package/geometry/support/meshUtils/exporters/gltf/gltf.js +1 -1
- package/geometry/support/meshUtils/rotate.js +1 -1
- package/geometry/support/meshUtils/scale.js +1 -1
- package/geometry/support/meshUtils/vertexSpaceConversion.js +1 -1
- package/geometry/support/plane.js +1 -1
- package/geometry/support/polygonUtils.js +1 -1
- package/interfaces.d.ts +100 -9
- package/kernel.js +1 -1
- package/layers/Layer.js +1 -1
- package/layers/MapNotesLayer.js +1 -1
- package/layers/graphics/data/QueryEngine.js +1 -1
- package/layers/save/groupLayerUtils.js +1 -1
- package/layers/support/DateTimeFieldFormat.js +1 -1
- package/layers/support/FieldFormat.js +1 -1
- package/layers/support/NumberFieldFormat.js +1 -1
- package/layers/support/arcgisLayerUrl.js +1 -1
- package/layers/support/fieldFormatUtils.js +1 -1
- package/layers/support/fieldUtils.js +1 -1
- package/layers/support/serviceCapabilitiesUtils.js +1 -1
- package/package.json +1 -1
- package/popup/ExpressionInfo.js +1 -1
- package/popup/FieldInfo.js +1 -1
- package/popup/content/AttachmentsContent.js +1 -1
- package/popup/content/BarChartMediaInfo.js +1 -1
- package/popup/content/ColumnChartMediaInfo.js +1 -1
- package/popup/content/Content.js +1 -1
- package/popup/content/CustomContent.js +1 -1
- package/popup/content/ExpressionContent.js +1 -1
- package/popup/content/FieldsContent.js +1 -1
- package/popup/content/ImageMediaInfo.js +1 -1
- package/popup/content/LineChartMediaInfo.js +1 -1
- package/popup/content/MediaContent.js +1 -1
- package/popup/content/PieChartMediaInfo.js +1 -1
- package/popup/content/RelationshipContent.js +1 -1
- package/popup/content/TextContent.js +1 -1
- package/popup/content/UtilityNetworkAssociationsContent.js +1 -1
- package/popup/content/mixins/ChartMediaInfo.js +1 -1
- package/popup/content/mixins/MediaInfo.js +1 -1
- package/popup/content.js +1 -1
- package/popup/support/FieldInfoFormat.js +1 -1
- package/rest/geometryService/utils.js +1 -1
- package/rest/knowledgeGraphService.d.ts +1 -0
- package/support/popupUtils.js +1 -1
- package/support/revision.js +1 -1
- package/symbols/support/symbolUtils.js +1 -1
- package/time/TimeExtent.js +1 -1
- package/views/2d/layers/features/processor/TrackStrategy.js +1 -1
- package/views/2d/layers/features/sources/strategies/FeatureDrillDownTileLoadStrategy.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillComputation.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillController.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillVisualization.js +1 -1
- package/views/3d/environment/CloudsRenderer.js +1 -1
- package/views/3d/interactive/measurementTools/areaMeasurement3D/AreaMeasurement3DView.js +1 -1
- package/views/3d/interactive/measurementTools/directLineMeasurement3D/DirectLineMeasurement3DView.js +1 -1
- package/views/3d/layers/FlowSubView3D.js +1 -1
- package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
- package/views/3d/support/flow/geometryUtils.js +1 -1
- package/views/3d/support/pointsOfInterest/Focus.js +1 -1
- package/views/3d/terrain/TerrainSurface.js +1 -1
- package/views/3d/webgl-engine/lib/CutFillDepth.js +1 -1
- package/views/draw/DrawOperation.js +1 -1
- package/views/interactive/editGeometry/EditGeometry.js +1 -1
- package/webdoc/support/webdocSaveUtils.js +1 -1
- package/widgets/BasemapLayerList.js +1 -1
- package/widgets/BatchAttributeForm/templates/support/createBatchFormTemplate.js +1 -1
- package/widgets/Editor/CreateFeaturesWorkflow.js +1 -1
- package/widgets/Editor/EditorViewModel.js +1 -1
- package/widgets/Editor/MergeFeaturesWorkflow.js +1 -1
- package/widgets/Editor/MergeFeaturesWorkflowData.js +1 -1
- package/widgets/Editor/SplitFeatureWorkflow.js +1 -1
- package/widgets/Editor/UpdateFeaturesWorkflow.js +1 -1
- package/widgets/Editor/UpdateRecordWorkflow.js +1 -1
- package/widgets/Editor/UpdateWorkflow.js +1 -1
- package/widgets/Editor/Workflow.js +1 -1
- package/widgets/Editor/components/FeatureList.js +1 -1
- package/widgets/Editor/components/MergeFeaturesList.js +5 -0
- package/widgets/Editor/components/Notices.js +1 -1
- package/widgets/Editor/components/PanelContent.js +1 -1
- package/widgets/Editor/components/UpdateFeaturePanelContent.js +1 -1
- package/widgets/Editor/css.js +1 -1
- package/widgets/Editor/support/EditorItem.js +1 -1
- package/widgets/Editor/support/SketchController.js +1 -1
- package/widgets/Editor/support/errors.js +1 -1
- package/widgets/Editor/support/mergeFeaturesUtils.js +1 -1
- package/widgets/Editor/support/splitFeatureUtils.js +1 -1
- package/widgets/Editor/workflowUtils.js +1 -1
- package/widgets/Editor.js +1 -1
- package/widgets/FeatureForm/FeatureFormUtilityNetworkAssociations/UtilityNetworkAssociationItemList.js +1 -1
- package/widgets/FeatureForm/FieldInput.js +1 -1
- package/widgets/FeatureForm.js +1 -1
- package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
- package/widgets/FeatureTable/FieldColumn.js +1 -1
- package/widgets/FeatureTable/support/FeatureStore.js +1 -1
- package/widgets/LayerList.js +1 -1
- package/widgets/Legend/support/ActiveLayerInfo.js +1 -1
- package/widgets/Legend/support/utils.js +1 -1
- package/widgets/PanoramicVideoViewer.js +1 -1
- package/widgets/support/FilterCondition.js +1 -1
- package/assets/esri/core/workers/chunks/09cdb05dc054fe3523f9.js +0 -1
- package/assets/esri/core/workers/chunks/0d34a4bb52ce17c4275c.js +0 -1
- package/assets/esri/core/workers/chunks/0f934d73ebb90a4a4481.js +0 -1
- package/assets/esri/core/workers/chunks/1c3a1dff1c3719e37a0d.js +0 -1
- package/assets/esri/core/workers/chunks/2059c930ed8a9a7c93ff.js +0 -1
- package/assets/esri/core/workers/chunks/20ecaa7a007ee398eea7.js +0 -1
- package/assets/esri/core/workers/chunks/25d8e37561d0c8601e52.js +0 -1
- package/assets/esri/core/workers/chunks/25f64be34a92472c9a78.js +0 -1
- package/assets/esri/core/workers/chunks/266f84f11befdc0484ce.js +0 -1
- package/assets/esri/core/workers/chunks/28ce35e349dd79c26741.js +0 -1
- package/assets/esri/core/workers/chunks/2da9bfe51b1969db092d.js +0 -1
- package/assets/esri/core/workers/chunks/2ffb4531294ca7a975cd.js +0 -1
- package/assets/esri/core/workers/chunks/36a855002674616d9b48.js +0 -1
- package/assets/esri/core/workers/chunks/36fd2bb614f32cdaf6c3.js +0 -1
- package/assets/esri/core/workers/chunks/38a055b62f75b0a1b4a6.js +0 -1
- package/assets/esri/core/workers/chunks/420b75a64c7c60ef17ae.js +0 -1
- package/assets/esri/core/workers/chunks/48e03a72a3f4c2d43d54.js +0 -1
- package/assets/esri/core/workers/chunks/49fa1c48ea21029b4fd7.js +0 -1
- package/assets/esri/core/workers/chunks/4ef84c9dd600a03cc569.js +0 -1
- package/assets/esri/core/workers/chunks/4fa230dc6e5e87b0dec1.js +0 -1
- package/assets/esri/core/workers/chunks/55cbb11be12f94d3b492.js +0 -1
- package/assets/esri/core/workers/chunks/55eb6a0f1e4569a65f2a.js +0 -1
- package/assets/esri/core/workers/chunks/5cbccd233f2deda1a3ba.js +0 -1
- package/assets/esri/core/workers/chunks/5f892d771592c88dee30.js +0 -1
- package/assets/esri/core/workers/chunks/6b12eba0b2d5e226ad73.js +0 -1
- package/assets/esri/core/workers/chunks/827ecfa9ac52518b99fb.js +0 -1
- package/assets/esri/core/workers/chunks/863f2de7068e2b420c5d.js +0 -1
- package/assets/esri/core/workers/chunks/87a8f839575d58d0ea33.js +0 -1
- package/assets/esri/core/workers/chunks/8978ca7f51d41ffa80cf.js +0 -1
- package/assets/esri/core/workers/chunks/8f05eb08948cd7e37326.js +0 -1
- package/assets/esri/core/workers/chunks/91a51effd465c40ad5d5.js +0 -1
- package/assets/esri/core/workers/chunks/92c1ddecb8ddec5e564f.js +0 -1
- package/assets/esri/core/workers/chunks/aa1e6154ef7abee76778.js +0 -1
- package/assets/esri/core/workers/chunks/aa255bdeabe558f1cd9a.js +0 -1
- package/assets/esri/core/workers/chunks/aaed35a6414859233678.js +0 -1
- package/assets/esri/core/workers/chunks/abedf3b4fdf1fef28661.js +0 -1
- package/assets/esri/core/workers/chunks/ac033e23ddf1abf468b2.js +0 -1
- package/assets/esri/core/workers/chunks/af1d7a17f59eb115edb8.js +0 -1
- package/assets/esri/core/workers/chunks/b1e67b68658f3b87e9d5.js +0 -1
- package/assets/esri/core/workers/chunks/b56899501876a183a5ad.js +0 -1
- package/assets/esri/core/workers/chunks/b5dbb20edffd705bbf8d.js +0 -1
- package/assets/esri/core/workers/chunks/c490d9397ec99ef17645.js +0 -1
- package/assets/esri/core/workers/chunks/c8c8cf43fd640d2f5cb1.js +0 -1
- package/assets/esri/core/workers/chunks/c9c1f1c97097c9f4abca.js +0 -1
- package/assets/esri/core/workers/chunks/c9cf90bba5790dade955.js +0 -1
- package/assets/esri/core/workers/chunks/cac13cf937e18303624a.js +0 -1
- package/assets/esri/core/workers/chunks/d19d69d48f88aed1e385.js +0 -1
- package/assets/esri/core/workers/chunks/d2a99b85928a10ca2a36.js +0 -1
- package/assets/esri/core/workers/chunks/dce632e4f3b944ea9947.js +0 -1
- package/assets/esri/core/workers/chunks/ddfaa05725c27b449a3e.js +0 -1
- package/assets/esri/core/workers/chunks/de12fd5cfa0238266f91.js +0 -1
- package/assets/esri/core/workers/chunks/df8279e1baf378faf85f.js +0 -1
- package/assets/esri/core/workers/chunks/dfcc0941ab30bf157175.js +0 -1
- package/assets/esri/core/workers/chunks/e31356965b90e9187b56.js +0 -1
- package/assets/esri/core/workers/chunks/e38ac1bbe8dcfeec5032.js +0 -1
- package/assets/esri/core/workers/chunks/e7acd87ef8de5e38fdc7.js +0 -1
- package/assets/esri/core/workers/chunks/e9b2f4d7026b67054bbc.js +0 -1
- package/assets/esri/core/workers/chunks/eb3a267c83924ff73464.js +0 -1
- package/assets/esri/core/workers/chunks/ef70f450c5875b86c535.js +0 -1
- package/assets/esri/core/workers/chunks/f36dc774b9866b70627e.js +0 -1
- package/assets/esri/core/workers/chunks/ff515bf0b5485abe8397.js +0 -1
- package/assets/esri/core/workers/chunks/ffac85e7d504a4a026f1.js +0 -1
- package/views/interactive/editGeometry/CheckpointingEditGeometryOperations.js +0 -5
- package/views/interactive/editGeometry/operations/ReplayableAppendVertex.js +0 -5
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import e from"../../core/Error.js";import{getDeepValue as n,setDeepValue as i}from"../../core/object.js";import{union as t}from"../../core/SetUtils.js";import{parseWhereClause as r}from"../../core/sql.js";import{getDomainRange as l}from"./domainUtils.js";import{supportsFieldConfiguration as o}from"./layerUtils.js";import{getFieldNameFromSimpleExpression as s}from"../../support/arcadeExpressionUtils.js";import{isStringOrNull as a,isString as u}from"../../support/guards.js";import{loadArcade as f}from"../../support/loadArcade.js";const d=/^([0-9_])/,c=/[^a-z0-9_\u0080-\uffff]+/gi;function p(e){if(null==e)return null;return e.trim().replaceAll(c,"_").replace(d,"F$1")||null}const m=["field","field2","field3","normalizationField","rotationInfo.field","proportionalSymbolInfo.field","proportionalSymbolInfo.normalizationField","colorInfo.field","colorInfo.normalizationField"],y=["field","normalizationField"];function g(e,n){if(null!=e&&null!=n)for(const i of Array.isArray(e)?e:[e])if(F(m,i,n),"visualVariables"in i&&i.visualVariables)for(const e of i.visualVariables)F(y,e,n)}function F(e,t,r){if(e)for(const l of e){const e=n(l,t),o=e&&"function"!=typeof e&&r.get(e);o&&i(l,o.name,t)}}function I(e,n){if(null!=e&&n?.fields?.length)if("startField"in e){const i=n.get(e.startField),t=n.get(e.endField);e.startField=i?.name??null,e.endField=t?.name??null}else{const i=n.get(e.startTimeField),t=n.get(e.endTimeField);e.startTimeField=i?.name??null,e.endTimeField=t?.name??null}}const b=new Set;function w(e,n){return e&&n?(b.clear(),x(b,e,n),Array.from(b).sort()):[]}function x(e,n,i){if(i)if(n?.fields?.length)if(i.includes("*"))for(const{name:t}of n.fields)e.add(t);else for(const t of i)T(e,n,t);else{if(i.includes("*"))return e.clear(),void e.add("*");for(const n of i)null!=n&&e.add(n)}}function T(e,n,i){if("string"==typeof i)if(n){const t=n.get(i);t&&e.add(t.name)}else e.add(i)}function h(e,n){return null==n||null==e?[]:n.includes("*")?(e.fields??[]).map(e=>e.name):n}function v(e,n,i=1){if(!n||!e)return[];if(n.includes("*"))return["*"];const t=w(e,n);return t.length/e.fields.length>=i?["*"]:t}async function S(e,n,i,t){if(!t)return;const r=s(t);if(r)T(e,n,r);else{const{arcadeUtils:r}=await f(),l=r.extractFieldNames(t,i?.partitions??n?.fields?.map(e=>e.name));for(const t of l)T(e,i?.index??n,t)}}async function A(n,i,t){if(t&&"1=1"!==t){const l=await r(t,i);if(!l.isStandardized)throw new e("fieldUtils:collectFilterFields","Where clause is not standardized",{where:t});x(n,i,l.fieldNames)}}function E({displayField:e,fields:n}){return e||(n?.length?_(n,"name-or-title")||_(n,"unique-identifier")||_(n,"type-or-category")||$(n):null)}function $(e){for(const n of e){if(!n?.name)continue;const e=n.name.toLowerCase();if(e.includes("name")||e.includes("title"))return n.name}return null}function _(e,n){for(const i of e)if(i?.valueType&&i.valueType===n)return i.name;return null}async function N(e){if(!e)return[];const n=new Set;return await L(n,e),Array.from(n).sort()}async function L(e,n){if(!n)return;const i=n.elevationInfo?.featureExpressionInfo;return i?i.collectRequiredFields(e,n.fieldsIndex):void 0}function M(e,n,i){i.onStatisticExpression?S(e,n,null,i.onStatisticExpression.expression):e.add(i.onStatisticField)}async function j(e,n,i){if(!n||!i||!("fields"in i))return;const t=[],r=i.popupTemplate;t.push(O(e,n,r)),i.fields&&t.push(...i.fields.map(async i=>M(e,n.fieldsIndex,i))),await Promise.all(t)}async function D(e,n){const{fieldsIndex:i,trackInfo:t}=n;if(!n||!t||!i)return;const r=[t.latestObservations.renderer?.collectRequiredFields(e,i),t.previousObservations.renderer?.collectRequiredFields(e,i),t.trackLines.renderer?.collectRequiredFields(e,i)];t.popupTemplate&&r.push(O(e,n,t.popupTemplate));for(const l of[t.latestObservations.labelingInfo,t.previousObservations.labelingInfo,t.trackLines.labelingInfo])if(l)for(const n of l)r.push(Z(e,i,n));await Promise.all(r)}async function O(e,n,i){const t=[];i?.expressionInfos&&t.push(...i.expressionInfos.map(i=>S(e,n.fieldsIndex,null,i.expression)));const r=i?.content;if(Array.isArray(r))for(const l of r)"expression"===l.type&&l.expressionInfo&&t.push(S(e,n.fieldsIndex,null,l.expressionInfo.expression));await Promise.all(t)}async function R(e,n,i){n&&(n.timeInfo&&i?.timeExtent&&x(e,n.fieldsIndex,[n.timeInfo.startField,n.timeInfo.endField]),n.floorInfo&&x(e,n.fieldsIndex,[n.floorInfo.floorField]),null!=i?.where&&await A(e,n.fieldsIndex,i.where))}async function V(e,n,i){n&&i&&await Promise.all(i.map(i=>k(e,n,i)))}async function k(e,n,i){n&&i&&(i.valueExpression?await S(e,n.fieldsIndex,null,i.valueExpression):i.field&&T(e,n.fieldsIndex,i.field))}async function C(e){if(!e)return[];const n="timeInfo"in e&&e.timeInfo;return n?w(e.fieldsIndex,[e.trackIdField,n.startField,n.endField]):[]}function U(e){return e?w(e.fieldsIndex,J(e)):[]}function q(e){if(!e)return[];const n=e.geometryFieldsInfo;return n?w(e.fieldsIndex,[n.shapeAreaField,n.shapeLengthField]):[]}async function X(e,n,i){if(!n||!i)return;const t=n.fieldsIndex;await Promise.all(i.filters.map(n=>A(e,t,n.where)))}const z=new Set(["oid","global-id","guid"]),P=new Set(["oid","global-id"]),B=[/^fnode_$/i,/^tnode_$/i,/^lpoly_$/i,/^rpoly_$/i,/^poly_$/i,/^shape$/i,/^shape_$/i,/^subclass$/i,/^subclass_$/i,/^rings_ok$/i,/^rings_nok$/i,/objectid/i,/^perimeter_/i,/_perimeter$/i,/_i$/i];function G(e){const n=new Set;W(e).forEach(e=>n.add(e)),q(e).forEach(e=>n.add(e.toLowerCase()));const i=e&&"infoFor3D"in e?e.infoFor3D:void 0;return i&&(Object.values(i.assetMapFieldRoles).forEach(e=>n.add(e.toLowerCase())),Object.values(i.transformFieldRoles).forEach(e=>n.add(e.toLowerCase()))),Array.from(n)}function J(e){if(!e)return[];const n="editFieldsInfo"in e&&e.editFieldsInfo;if(!n)return[];const{creationDateField:i,creatorField:t,editDateField:r,editorField:l}=n;return[i,t,r,l].filter(Boolean)}function W(e){return J(e).map(e=>e.toLowerCase())}function H(e,n){return e.editable&&!z.has(e.type)&&!W(n).includes(e.name?.toLowerCase()??"")}function K(e,n){const i=e.name?.toLowerCase()??"";return!(null!=n?.objectIdField&&i===n.objectIdField.toLowerCase()||null!=n?.globalIdField&&i===n.globalIdField.toLowerCase()||G(n).includes(i)||P.has(e.type)||B.some(e=>e.test(i)))}async function Q(e){if(!e)return[];const n=new Set;return await Y(n,e),Array.from(n).sort()}async function Y(e,n){const{labelingInfo:i,fieldsIndex:t}=n;i?.length&&await Promise.all(i.map(n=>Z(e,t,n)))}async function Z(e,n,i){if(!i)return;const t=i.getLabelExpression(),r=i.where;if("arcade"===t.type)await S(e,n,null,t.expression);else{const i=t.expression.match(/{[^}]*}/g);i&&i.forEach(i=>{T(e,n,i.slice(1,-1))})}await A(e,n,r)}function ee(e){const n=e.defaultValue;return void 0!==n&&oe(e,n)?n:e.nullable?null:void 0}function ne(e){const n="string"==typeof e?{type:e}:e;return Fe(n)?255:"esriFieldTypeDate"===n.type||"date"===n.type?8:void 0}function ie(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)}function te(e){return null===e||ie(e)}function re(e){return null===e||Number.isInteger(e)}function le(){return!0}function oe(e,n){let i;switch(e.type){case"date":case"integer":case"long":case"small-integer":case"big-integer":case"esriFieldTypeDate":case"esriFieldTypeInteger":case"esriFieldTypeLong":case"esriFieldTypeSmallInteger":case"esriFieldTypeBigInteger":i=e.nullable?re:Number.isInteger;break;case"double":case"single":case"esriFieldTypeSingle":case"esriFieldTypeDouble":i=e.nullable?te:ie;break;case"string":case"esriFieldTypeString":i=e.nullable?a:u;break;default:i=le}return 1===arguments.length?i:i(n)}const se=["integer","small-integer","big-integer","long"],ae=["single","double"],ue=[...se,...ae],fe=["esriFieldTypeInteger","esriFieldTypeSmallInteger","esriFieldTypeLong","esriFieldTypeBigInteger"],de=["esriFieldTypeSingle","esriFieldTypeDouble"],ce=new Set([...se,...fe]),pe=new Set([...ae,...de]),me=t(ce,pe);function ye(e){return null!=e&&ce.has(e.type)}function ge(e){return null!=e&&me.has(e.type)}function Fe(e){return null!=e&&("string"===e.type||"esriFieldTypeString"===e.type)}function Ie(e){return null!=e&&("date"===e.type||"esriFieldTypeDate"===e.type)}function be(e){return null!=e&&("date-only"===e.type||"esriFieldTypeDateOnly"===e.type)}function we(e){return null!=e&&("timestamp-offset"===e.type||"esriFieldTypeTimestampOffset"===e.type)}function xe(e){return null!=e&&("time-only"===e.type||"esriFieldTypeTimeOnly"===e.type)}function Te(e){return null!=e&&("oid"===e.type||"esriFieldTypeOID"===e.type)}function he(e){return null!=e&&("global-id"===e.type||"esriFieldTypeGlobalID"===e.type)}function ve(e,n){return null===Ae(e,n)}function Se(e){return null==e||"number"==typeof e&&isNaN(e)?null:e}function Ae(e,n){return null==e||e.nullable&&null===n?null:oe(e,n)?ge(e)&&!Ee(e.type,Number(n))?"numeric-range-validation-error::out-of-range":null:"type-validation-error::invalid-type"}function Ee(e,n){const i="string"==typeof e?_e(e):e;if(!i)return!1;const t=i.min,r=i.max;return i.isInteger?Number.isInteger(n)&&n>=t&&n<=r:n>=t&&n<=r}function $e(e,n){const i=l(e,n);return i||(ge(e)?_e(e.type):void 0)}function _e(e){switch(e){case"esriFieldTypeSmallInteger":case"small-integer":return Le;case"esriFieldTypeInteger":case"esriFieldTypeLong":case"integer":case"long":return Me;case"esriFieldTypeBigInteger":case"big-integer":return je;case"esriFieldTypeSingle":case"single":return Oe;case"esriFieldTypeDouble":case"double":return Re}}function Ne(e){if(!ie(e))return null;if(Number.isInteger(e)){if(e>=Le.min&&e<=Le.max)return"esriFieldTypeSmallInteger";if(e>=Me.min&&e<=Me.max)return"esriFieldTypeInteger";if(e>=je.min&&e<=je.max)return"esriFieldTypeBigInteger"}return e>=Oe.min&&e<=Oe.max?"esriFieldTypeSingle":"esriFieldTypeDouble"}const Le={min:-32768,max:32767,isInteger:!0,rawMin:-32768,rawMax:32767},Me={min:-2147483648,max:2147483647,isInteger:!0,rawMin:-2147483648,rawMax:2147483647},je={min:-Number.MAX_SAFE_INTEGER,max:Number.MAX_SAFE_INTEGER,isInteger:!0,rawMin:-Number.MAX_SAFE_INTEGER,rawMax:Number.MAX_SAFE_INTEGER},De=(2-2**-23)*2**127,Oe={min:-De,max:De,isInteger:!1,rawMin:-De,rawMax:De},Re={min:-Number.MAX_VALUE,max:Number.MAX_VALUE,isInteger:!1,rawMin:-Number.MAX_VALUE,rawMax:Number.MAX_VALUE};function Ve(e,n,i){switch(e){case"domain-validation-error::invalid-coded-value":return`Value ${i} is not in the coded domain - field: ${n.name}, domain: ${JSON.stringify(n.domain)}`;case"domain-validation-error::value-out-of-range":return`Value ${i} is out of the range of valid values - field: ${n.name}, domain: ${JSON.stringify(n.domain)}`;case"type-validation-error::invalid-type":return`Value ${i} is not a valid value for the field type - field: ${n.name}, type: ${n.type}, nullable: ${n.nullable}`;case"numeric-range-validation-error::out-of-range":{const{min:e,max:t}=_e(n.type);return`Value ${i} is out of range for the number type - field: ${n.name}, type: ${n.type}, value range is ${e} to ${t}`}}}function ke(e,n){return!Ce(e,n,null)}function Ce(e,n,i){if(!e?.attributes||!n){if(null!=i)for(const e of n??[])i.add(e);return!0}const t=new Set(Object.keys(e.attributes));let r=!1;for(const l of n)if(!t.has(l)){if(r=!0,null==i)break;i.add(l)}return r}async function Ue(e,n){const i=new Set;for(const t of n)await S(i,e.fieldsIndex,null,t);return Array.from(i).sort()}function qe(e){return!!e&&["raster.itempixelvalue","raster.servicepixelvalue"].some(n=>e.toLowerCase().startsWith(n))}async function Xe(e,n){const i=new Set;return e?.collectRequiredFields&&await e.collectRequiredFields(i,n),Array.from(i).sort()}function ze(e){const n=e?.match(/{[^}]+}/g);return n?n.map(e=>e.slice(1,-1).split(":")[0].trim()):[]}function Pe(e,n){return o(n)?n.getFieldAlias(e.name):e.alias}export{je as bigIntegerRange,S as collectArcadeFieldNames,X as collectDisplayFilterFields,L as collectElevationFields,j as collectFeatureReductionFields,T as collectField,x as collectFields,R as collectFilterFields,Y as collectLabelingFields,V as collectOrderByInfos,O as collectPopupTemplateFields,A as collectSQLFieldNames,D as collectTrackInfoFields,Re as doubleRange,ze as extractSubstitutionTemplatesFromString,ke as featureHasFields,w as fixFields,g as fixRendererFields,I as fixTimeInfoFields,de as floatJSONTypes,ae as floatTypes,E as getDisplayFieldName,J as getEditTrackingFields,Pe as getEffectiveFieldAlias,N as getElevationFields,Ue as getExpressionFields,U as getFeatureEditFields,q as getFeatureGeometryFields,ne as getFieldDefaultLength,ee as getFieldDefaultValue,$e as getFieldRange,Q as getLabelingFields,G as getLowerCaseDefaultHiddenFields,W as getLowerCaseEditTrackingFields,Ne as getNumericTypeForValue,Xe as getRendererFields,C as getTimeFields,fe as integerJSONTypes,Me as integerRange,se as integerTypes,Ie as isDateField,be as isDateOnlyField,H as isFieldEditable,K as isFieldVisibleByDefault,he as isGlobalIDField,ye as isIntegerField,Ee as isNumberInRange,ge as isNumericField,Te as isObjectIDField,qe as isRasterPixelValueField,Fe as isStringField,xe as isTimeOnlyField,we as isTimestampOffsetField,ve as isValidFieldValue,oe as isValueMatchingFieldType,p as normalizeFieldName,ue as numericTypes,v as packFields,Ce as populateMissingFields,m as rendererFields,Se as sanitizeNullFieldValue,Oe as singleRange,Le as smallIntegerRange,h as unpackFieldNames,Ae as validateFieldValue,Ve as validationErrorToString,y as visualVariableFields};
|
|
5
|
+
import e from"../../core/Error.js";import{getDeepValue as n,setDeepValue as i}from"../../core/object.js";import{union as t}from"../../core/SetUtils.js";import{parseWhereClause as r}from"../../core/sql.js";import{getDomainRange as l}from"./domainUtils.js";import{getFieldNameFromSimpleExpression as o}from"../../support/arcadeExpressionUtils.js";import{isStringOrNull as s,isString as a}from"../../support/guards.js";import{loadArcade as u}from"../../support/loadArcade.js";const f=/^([0-9_])/,d=/[^a-z0-9_\u0080-\uffff]+/gi;function c(e){if(null==e)return null;return e.trim().replaceAll(d,"_").replace(f,"F$1")||null}const p=["field","field2","field3","normalizationField","rotationInfo.field","proportionalSymbolInfo.field","proportionalSymbolInfo.normalizationField","colorInfo.field","colorInfo.normalizationField"],m=["field","normalizationField"];function y(e,n){if(null!=e&&null!=n)for(const i of Array.isArray(e)?e:[e])if(g(p,i,n),"visualVariables"in i&&i.visualVariables)for(const e of i.visualVariables)g(m,e,n)}function g(e,t,r){if(e)for(const l of e){const e=n(l,t),o=e&&"function"!=typeof e&&r.get(e);o&&i(l,o.name,t)}}function F(e,n){if(null!=e&&n?.fields?.length)if("startField"in e){const i=n.get(e.startField),t=n.get(e.endField);e.startField=i?.name??null,e.endField=t?.name??null}else{const i=n.get(e.startTimeField),t=n.get(e.endTimeField);e.startTimeField=i?.name??null,e.endTimeField=t?.name??null}}const I=new Set;function b(e,n){return e&&n?(I.clear(),w(I,e,n),Array.from(I).sort()):[]}function w(e,n,i){if(i)if(n?.fields?.length)if(i.includes("*"))for(const{name:t}of n.fields)e.add(t);else for(const t of i)x(e,n,t);else{if(i.includes("*"))return e.clear(),void e.add("*");for(const n of i)null!=n&&e.add(n)}}function x(e,n,i){if("string"==typeof i)if(n){const t=n.get(i);t&&e.add(t.name)}else e.add(i)}function T(e,n){return null==n||null==e?[]:n.includes("*")?(e.fields??[]).map(e=>e.name):n}function h(e,n,i=1){if(!n||!e)return[];if(n.includes("*"))return["*"];const t=b(e,n);return t.length/e.fields.length>=i?["*"]:t}async function v(e,n,i,t){if(!t)return;const r=o(t);if(r)x(e,n,r);else{const{arcadeUtils:r}=await u(),l=r.extractFieldNames(t,i?.partitions??n?.fields?.map(e=>e.name));for(const t of l)x(e,i?.index??n,t)}}async function S(n,i,t){if(t&&"1=1"!==t){const l=await r(t,i);if(!l.isStandardized)throw new e("fieldUtils:collectFilterFields","Where clause is not standardized",{where:t});w(n,i,l.fieldNames)}}function E({displayField:e,fields:n}){return e||(n?.length?$(n,"name-or-title")||$(n,"unique-identifier")||$(n,"type-or-category")||A(n):null)}function A(e){for(const n of e){if(!n?.name)continue;const e=n.name.toLowerCase();if(e.includes("name")||e.includes("title"))return n.name}return null}function $(e,n){for(const i of e)if(i?.valueType&&i.valueType===n)return i.name;return null}async function _(e){if(!e)return[];const n=new Set;return await N(n,e),Array.from(n).sort()}async function N(e,n){if(!n)return;const i=n.elevationInfo?.featureExpressionInfo;return i?i.collectRequiredFields(e,n.fieldsIndex):void 0}function L(e,n,i){i.onStatisticExpression?v(e,n,null,i.onStatisticExpression.expression):e.add(i.onStatisticField)}async function M(e,n,i){if(!n||!i||!("fields"in i))return;const t=[],r=i.popupTemplate;t.push(D(e,n,r)),i.fields&&t.push(...i.fields.map(async i=>L(e,n.fieldsIndex,i))),await Promise.all(t)}async function j(e,n){const{fieldsIndex:i,trackInfo:t}=n;if(!n||!t||!i)return;const r=[t.latestObservations.renderer?.collectRequiredFields(e,i),t.previousObservations.renderer?.collectRequiredFields(e,i),t.trackLines.renderer?.collectRequiredFields(e,i)];t.popupTemplate&&r.push(D(e,n,t.popupTemplate));for(const l of[t.latestObservations.labelingInfo,t.previousObservations.labelingInfo,t.trackLines.labelingInfo])if(l)for(const n of l)r.push(Y(e,i,n));await Promise.all(r)}async function D(e,n,i){const t=[];i?.expressionInfos&&t.push(...i.expressionInfos.map(i=>v(e,n.fieldsIndex,null,i.expression)));const r=i?.content;if(Array.isArray(r))for(const l of r)"expression"===l.type&&l.expressionInfo&&t.push(v(e,n.fieldsIndex,null,l.expressionInfo.expression));await Promise.all(t)}async function O(e,n,i){n&&(n.timeInfo&&i?.timeExtent&&w(e,n.fieldsIndex,[n.timeInfo.startField,n.timeInfo.endField]),n.floorInfo&&w(e,n.fieldsIndex,[n.floorInfo.floorField]),null!=i?.where&&await S(e,n.fieldsIndex,i.where))}async function R(e,n,i){n&&i&&await Promise.all(i.map(i=>V(e,n,i)))}async function V(e,n,i){n&&i&&(i.valueExpression?await v(e,n.fieldsIndex,null,i.valueExpression):i.field&&x(e,n.fieldsIndex,i.field))}async function k(e){if(!e)return[];const n="timeInfo"in e&&e.timeInfo;return n?b(e.fieldsIndex,[e.trackIdField,n.startField,n.endField]):[]}function C(e){return e?b(e.fieldsIndex,G(e)):[]}function U(e){if(!e)return[];const n=e.geometryFieldsInfo;return n?b(e.fieldsIndex,[n.shapeAreaField,n.shapeLengthField]):[]}async function q(e,n,i){if(!n||!i)return;const t=n.fieldsIndex;await Promise.all(i.filters.map(n=>S(e,t,n.where)))}const X=new Set(["oid","global-id","guid"]),z=new Set(["oid","global-id"]),P=[/^fnode_$/i,/^tnode_$/i,/^lpoly_$/i,/^rpoly_$/i,/^poly_$/i,/^shape$/i,/^shape_$/i,/^subclass$/i,/^subclass_$/i,/^rings_ok$/i,/^rings_nok$/i,/objectid/i,/^perimeter_/i,/_perimeter$/i,/_i$/i];function B(e){const n=new Set;J(e).forEach(e=>n.add(e)),U(e).forEach(e=>n.add(e.toLowerCase()));const i=e&&"infoFor3D"in e?e.infoFor3D:void 0;return i&&(Object.values(i.assetMapFieldRoles).forEach(e=>n.add(e.toLowerCase())),Object.values(i.transformFieldRoles).forEach(e=>n.add(e.toLowerCase()))),Array.from(n)}function G(e){if(!e)return[];const n="editFieldsInfo"in e&&e.editFieldsInfo;if(!n)return[];const{creationDateField:i,creatorField:t,editDateField:r,editorField:l}=n;return[i,t,r,l].filter(Boolean)}function J(e){return G(e).map(e=>e.toLowerCase())}function W(e,n){return e.editable&&!X.has(e.type)&&!J(n).includes(e.name?.toLowerCase()??"")}function H(e,n){const i=e.name?.toLowerCase()??"";return!(null!=n?.objectIdField&&i===n.objectIdField.toLowerCase()||null!=n?.globalIdField&&i===n.globalIdField.toLowerCase()||B(n).includes(i)||z.has(e.type)||P.some(e=>e.test(i)))}async function K(e){if(!e)return[];const n=new Set;return await Q(n,e),Array.from(n).sort()}async function Q(e,n){const{labelingInfo:i,fieldsIndex:t}=n;i?.length&&await Promise.all(i.map(n=>Y(e,t,n)))}async function Y(e,n,i){if(!i)return;const t=i.getLabelExpression(),r=i.where;if("arcade"===t.type)await v(e,n,null,t.expression);else{const i=t.expression.match(/{[^}]*}/g);i&&i.forEach(i=>{x(e,n,i.slice(1,-1))})}await S(e,n,r)}function Z(e){const n=e.defaultValue;return void 0!==n&&le(e,n)?n:e.nullable?null:void 0}function ee(e){const n="string"==typeof e?{type:e}:e;return ge(n)?255:"esriFieldTypeDate"===n.type||"date"===n.type?8:void 0}function ne(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)}function ie(e){return null===e||ne(e)}function te(e){return null===e||Number.isInteger(e)}function re(){return!0}function le(e,n){let i;switch(e.type){case"date":case"integer":case"long":case"small-integer":case"big-integer":case"esriFieldTypeDate":case"esriFieldTypeInteger":case"esriFieldTypeLong":case"esriFieldTypeSmallInteger":case"esriFieldTypeBigInteger":i=e.nullable?te:Number.isInteger;break;case"double":case"single":case"esriFieldTypeSingle":case"esriFieldTypeDouble":i=e.nullable?ie:ne;break;case"string":case"esriFieldTypeString":i=e.nullable?s:a;break;default:i=re}return 1===arguments.length?i:i(n)}const oe=["integer","small-integer","big-integer","long"],se=["single","double"],ae=[...oe,...se],ue=["esriFieldTypeInteger","esriFieldTypeSmallInteger","esriFieldTypeLong","esriFieldTypeBigInteger"],fe=["esriFieldTypeSingle","esriFieldTypeDouble"],de=new Set([...oe,...ue]),ce=new Set([...se,...fe]),pe=t(de,ce);function me(e){return null!=e&&de.has(e.type)}function ye(e){return null!=e&&pe.has(e.type)}function ge(e){return null!=e&&("string"===e.type||"esriFieldTypeString"===e.type)}function Fe(e){return null!=e&&("date"===e.type||"esriFieldTypeDate"===e.type)}function Ie(e){return null!=e&&("date-only"===e.type||"esriFieldTypeDateOnly"===e.type)}function be(e){return null!=e&&("timestamp-offset"===e.type||"esriFieldTypeTimestampOffset"===e.type)}function we(e){return null!=e&&("time-only"===e.type||"esriFieldTypeTimeOnly"===e.type)}function xe(e){return null!=e&&("oid"===e.type||"esriFieldTypeOID"===e.type)}function Te(e){return null!=e&&("global-id"===e.type||"esriFieldTypeGlobalID"===e.type)}function he(e,n){return null===Se(e,n)}function ve(e){return null==e||"number"==typeof e&&isNaN(e)?null:e}function Se(e,n){return null==e||e.nullable&&null===n?null:le(e,n)?ye(e)&&!Ee(e.type,Number(n))?"numeric-range-validation-error::out-of-range":null:"type-validation-error::invalid-type"}function Ee(e,n){const i="string"==typeof e?$e(e):e;if(!i)return!1;const t=i.min,r=i.max;return i.isInteger?Number.isInteger(n)&&n>=t&&n<=r:n>=t&&n<=r}function Ae(e,n){const i=l(e,n);return i||(ye(e)?$e(e.type):void 0)}function $e(e){switch(e){case"esriFieldTypeSmallInteger":case"small-integer":return Ne;case"esriFieldTypeInteger":case"esriFieldTypeLong":case"integer":case"long":return Le;case"esriFieldTypeBigInteger":case"big-integer":return Me;case"esriFieldTypeSingle":case"single":return De;case"esriFieldTypeDouble":case"double":return Oe}}function _e(e){if(!ne(e))return null;if(Number.isInteger(e)){if(e>=Ne.min&&e<=Ne.max)return"esriFieldTypeSmallInteger";if(e>=Le.min&&e<=Le.max)return"esriFieldTypeInteger";if(e>=Me.min&&e<=Me.max)return"esriFieldTypeBigInteger"}return e>=De.min&&e<=De.max?"esriFieldTypeSingle":"esriFieldTypeDouble"}const Ne={min:-32768,max:32767,isInteger:!0,rawMin:-32768,rawMax:32767},Le={min:-2147483648,max:2147483647,isInteger:!0,rawMin:-2147483648,rawMax:2147483647},Me={min:-Number.MAX_SAFE_INTEGER,max:Number.MAX_SAFE_INTEGER,isInteger:!0,rawMin:-Number.MAX_SAFE_INTEGER,rawMax:Number.MAX_SAFE_INTEGER},je=(2-2**-23)*2**127,De={min:-je,max:je,isInteger:!1,rawMin:-je,rawMax:je},Oe={min:-Number.MAX_VALUE,max:Number.MAX_VALUE,isInteger:!1,rawMin:-Number.MAX_VALUE,rawMax:Number.MAX_VALUE};function Re(e,n,i){switch(e){case"domain-validation-error::invalid-coded-value":return`Value ${i} is not in the coded domain - field: ${n.name}, domain: ${JSON.stringify(n.domain)}`;case"domain-validation-error::value-out-of-range":return`Value ${i} is out of the range of valid values - field: ${n.name}, domain: ${JSON.stringify(n.domain)}`;case"type-validation-error::invalid-type":return`Value ${i} is not a valid value for the field type - field: ${n.name}, type: ${n.type}, nullable: ${n.nullable}`;case"numeric-range-validation-error::out-of-range":{const{min:e,max:t}=$e(n.type);return`Value ${i} is out of range for the number type - field: ${n.name}, type: ${n.type}, value range is ${e} to ${t}`}}}function Ve(e,n){return!ke(e,n,null)}function ke(e,n,i){if(!e?.attributes||!n){if(null!=i)for(const e of n??[])i.add(e);return!0}const t=new Set(Object.keys(e.attributes));let r=!1;for(const l of n)if(!t.has(l)){if(r=!0,null==i)break;i.add(l)}return r}async function Ce(e,n){const i=new Set;for(const t of n)await v(i,e.fieldsIndex,null,t);return Array.from(i).sort()}function Ue(e){return!!e&&["raster.itempixelvalue","raster.servicepixelvalue"].some(n=>e.toLowerCase().startsWith(n))}async function qe(e,n){const i=new Set;return e?.collectRequiredFields&&await e.collectRequiredFields(i,n),Array.from(i).sort()}function Xe(e){const n=e?.match(/{[^}]+}/g);return n?n.map(e=>e.slice(1,-1).split(":")[0].trim()):[]}export{Me as bigIntegerRange,v as collectArcadeFieldNames,q as collectDisplayFilterFields,N as collectElevationFields,M as collectFeatureReductionFields,x as collectField,w as collectFields,O as collectFilterFields,Q as collectLabelingFields,R as collectOrderByInfos,D as collectPopupTemplateFields,S as collectSQLFieldNames,j as collectTrackInfoFields,Oe as doubleRange,Xe as extractSubstitutionTemplatesFromString,Ve as featureHasFields,b as fixFields,y as fixRendererFields,F as fixTimeInfoFields,fe as floatJSONTypes,se as floatTypes,E as getDisplayFieldName,G as getEditTrackingFields,_ as getElevationFields,Ce as getExpressionFields,C as getFeatureEditFields,U as getFeatureGeometryFields,ee as getFieldDefaultLength,Z as getFieldDefaultValue,Ae as getFieldRange,K as getLabelingFields,B as getLowerCaseDefaultHiddenFields,J as getLowerCaseEditTrackingFields,_e as getNumericTypeForValue,qe as getRendererFields,k as getTimeFields,ue as integerJSONTypes,Le as integerRange,oe as integerTypes,Fe as isDateField,Ie as isDateOnlyField,W as isFieldEditable,H as isFieldVisibleByDefault,Te as isGlobalIDField,me as isIntegerField,Ee as isNumberInRange,ye as isNumericField,xe as isObjectIDField,Ue as isRasterPixelValueField,ge as isStringField,we as isTimeOnlyField,be as isTimestampOffsetField,he as isValidFieldValue,le as isValueMatchingFieldType,c as normalizeFieldName,ae as numericTypes,h as packFields,ke as populateMissingFields,p as rendererFields,ve as sanitizeNullFieldValue,De as singleRange,Ne as smallIntegerRange,T as unpackFieldNames,Se as validateFieldValue,Re as validationErrorToString,m as visualVariableFields};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import has from"../../core/has.js";import{isHostedAgolService as t,parse as s}from"./arcgisLayerUrl.js";import{getGltfQueryFormat as e}from"./infoFor3D.js";import{
|
|
5
|
+
import has from"../../core/has.js";import{isHostedAgolService as t,parse as s}from"./arcgisLayerUrl.js";import{getGltfQueryFormat as e}from"./infoFor3D.js";import{readNumber as r,readBoolean as p}from"../../rest/support/jsonUtils.js";const o={name:"supportsName",size:"supportsSize",contentType:"supportsContentType",keywords:"supportsKeywords",exifInfo:"supportsExifInfo"};function u(t){const s=t?.supportedSpatialAggregationStatistics?.map(t=>t.toLowerCase());return{envelope:!!s?.includes("envelopeaggregate"),centroid:!!s?.includes("centroidaggregate"),convexHull:!!s?.includes("convexhullaggregate")}}function n(t,s){const e=t?.supportedOperationsWithCacheHint?.map(t=>t.toLowerCase());return!!e?.includes(s.toLowerCase())}function i(t){const s=t?.supportedStatisticTypes?.map(t=>t.toLowerCase());return{count:!!s?.includes("count"),sum:!!s?.includes("sum"),min:!!s?.includes("min"),max:!!s?.includes("max"),avg:!!s?.includes("avg"),var:!!s?.includes("var"),stddev:!!s?.includes("stddev"),percentileContinuous:!!s?.includes("percentile_cont"),percentileDiscrete:!!s?.includes("percentile_disc"),envelope:!!s?.includes("envelopeaggregate"),centroid:!!s?.includes("centroidaggregate"),convexHull:!!s?.includes("convexhullaggregate")}}function a(t){const s=t?.supportedNormalizationTypes?.map(t=>t.toLowerCase());return{field:!!s?.includes("field"),log:!!s?.includes("log"),naturalLog:!!s?.includes("naturallog"),percentOfTotal:!!s?.includes("percentoftotal"),squareRoot:!!s?.includes("squareroot")}}function c(t,s){return{analytics:d(t),attachment:l(t),data:y(t),metadata:m(t),operations:g(t.capabilities,t,s),query:C(t,s),queryAttributeBins:Q(t),queryRelated:v(t),queryTopFeatures:h(t),editing:A(t)}}function d(t){return{supportsCacheHint:n(t.advancedQueryCapabilities,"queryAnalytics")}}function l(t){const s=t.attachmentProperties,e={supportsName:!1,supportsSize:!1,supportsContentType:!1,supportsKeywords:!1,supportsExifInfo:!1,supportsCacheHint:n(t.advancedQueryCapabilities,"queryAttachments"),supportsOrderByFields:p(t.advancedQueryCapabilities,"supportsQueryAttachmentOrderByFields",!1),supportsResize:p(t,"supportsAttachmentsResizing",!1),supportsTypeWildcard:p(t.advancedQueryCapabilities,"supportsQueryAttachmentWithTypeWildcard",!1)};return s&&Array.isArray(s)&&s.forEach(t=>{const s=o[t.name];s&&(e[s]=!!t.isEnabled)}),e}function y(t){return{isVersioned:p(t,"isDataVersioned",!1),isBranchVersioned:p(t,"isDataBranchVersioned",!1),supportsAttachment:p(t,"hasAttachments",!1),supportsM:p(t,"hasM",!1),supportsZ:p(t,"hasZ",!1)}}function m(t){return{supportsAdvancedFieldProperties:p(t,"supportsFieldDescriptionProperty",!1)}}function g(t,e,r){const o=t?.toLowerCase().split(",").map(t=>t.trim())??[],u=r?s(r):null,n=o.includes("MapServer"===u?.serverType?"data":"query"),i=o.includes("editing")&&!e.datesInUnknownTimezone&&!(!0===e.uniqueIdInfo?.OIDFieldContainsHashValue);let a=i&&o.includes("create"),c=i&&o.includes("delete"),d=i&&o.includes("update");const l=o.includes("changetracking"),y=e.advancedQueryCapabilities;return i&&!(a||c||d)&&(a=c=d=!0),{supportsCalculate:p(e,"supportsCalculate",!1),supportsTruncate:p(e,"supportsTruncate",!1),supportsValidateSql:p(e,"supportsValidateSql",!1),supportsAdd:a,supportsDelete:c,supportsEditing:i,supportsChangeTracking:l,supportsQuery:n,supportsQueryAnalytics:p(y,"supportsQueryAnalytic",!1),supportsQueryAttachments:p(y,"supportsQueryAttachments",!1),supportsQueryBins:p(y,"supportsQueryBins",!1)||!!e.queryBinsCapabilities,supportsQueryPivot:p(y,"supportsQueryPivot",!1),supportsQueryTopFeatures:p(y,"supportsTopFeaturesQuery",!1),supportsResizeAttachments:p(e,"supportsAttachmentsResizing",!1),supportsSync:o.includes("sync"),supportsUpdate:d,supportsExceedsLimitStatistics:p(e,"supportsExceedsLimitStatistics",!1),supportsAsyncConvert3D:p(e,"supportsAsyncConvert3D",!1)}}function C(s,o){const i=s.advancedQueryCapabilities,a=s.ownershipBasedAccessControlForFeatures,c=s.archivingInfo,d=s.currentVersion,l=o?.includes("MapServer"),y=!l||d>=has("mapserver-pbf-version-support"),m=t(o),g=new Set((s.supportedQueryFormats??"").split(",").map(t=>t.toLowerCase().trim()));return{maxRecordCount:r(s,"maxRecordCount",void 0),maxRecordCountFactor:r(s,"maxRecordCountFactor",void 0),maxUniqueIDCount:r(s,"maxUniqueIDCount",void 0),standardMaxRecordCount:r(s,"standardMaxRecordCount",void 0),supportedSpatialAggregationStatistics:u(i),supportsCacheHint:p(i,"supportsQueryWithCacheHint",!1)||n(i,"query"),supportsCentroid:p(i,"supportsReturningGeometryCentroid",!1),supportsCentroidOnDegeneratedQuantizedGeometry:m||null==o,supportsCompactGeometry:m,supportsCurrentUser:p(i,"supportsCurrentUserQueries",!1),supportsDefaultSpatialReference:p(i,"supportsDefaultSR",!1),supportsDegeneratedQuantizedGeometry:p(i,"supportsDegeneratedQuantizedGeometry",!1),supportsDisjointSpatialRelationship:p(i,"supportsDisjointSpatialRel",!1),supportsDistance:p(i,"supportsQueryWithDistance",!1),supportsDistinct:p(i,"supportsDistinct",s.supportsAdvancedQueries),supportsExtent:p(i,"supportsReturningQueryExtent",!1),supportsFormatPBF:y&&g.has("pbf"),supportsFullTextSearch:p(i,"supportsFullTextSearch",!1),supportsGeometryProperties:p(i,"supportsReturningGeometryProperties",!1),supportsHavingClause:p(i,"supportsHavingClause",!1),supportsHistoricMoment:p(c,"supportsQueryWithHistoricMoment",!1),supportsMaxRecordCountFactor:p(i,"supportsMaxRecordCountFactor",!1),supportsOrderBy:p(i,"supportsOrderBy",s.supportsAdvancedQueries),supportsPagination:p(i,"supportsPagination",!1),supportsPaginationOnAggregatedQueries:p(i,"supportsPaginationOnAggregatedQueries",!1),supportsPercentileStatistics:p(i,"supportsPercentileStatistics",!1),supportsQuantization:p(s,"supportsCoordinatesQuantization",!1),supportsQuantizationEditMode:p(s,"supportsQuantizationEditMode",!1),supportsQueryByAnonymous:p(a,"allowAnonymousToQuery",!0),supportsQueryByOthers:p(a,"allowOthersToQuery",!0),supportsQueryGeometry:p(s,"supportsReturningQueryGeometry",!1),supportsResultType:p(i,"supportsQueryWithResultType",!1),supportsReturnMesh:!!e(s.infoFor3D),supportsSpatialAggregationStatistics:p(i,"supportsSpatialAggregationStatistics",!1),supportsSqlExpression:p(i,"supportsSqlExpression",!1),supportsStandardizedQueriesOnly:p(s,"useStandardizedQueries",!1),supportsStatistics:p(i,"supportsStatistics",s.supportsStatistics),supportsTopFeaturesQuery:p(i,"supportsTopFeaturesQuery",!1),supportsTrueCurve:p(i,"supportsTrueCurve",!1),tileMaxRecordCount:r(s,"tileMaxRecordCount",void 0)}}function v(t){const s=t.advancedQueryCapabilities,e=p(s,"supportsAdvancedQueryRelated",!1);return{supportsPagination:p(s,"supportsQueryRelatedPagination",!1),supportsCount:e,supportsOrderBy:e,supportsCacheHint:n(s,"queryRelated")}}function h(t){return{supportsCacheHint:n(t.advancedQueryCapabilities,"queryTopFilter")}}function Q(t){const s=t?t.queryBinsCapabilities:void 0;return{supportsDate:p(s,"supportsDateBin",!1),supportsFixedInterval:p(s,"supportsFixedIntervalBin",!1),supportsAutoInterval:p(s,"supportsAutoIntervalBin",!1),supportsFixedBoundaries:p(s,"supportsFixedBoundariesBin",!1),supportsStackBy:p(s,"supportsStackBy",!1),supportsSplitBy:p(s,"supportsSplitBy",!1),supportsSnapToData:p(s,"supportsSnapToData",!1),supportsReturnFullIntervalBin:p(s,"supportsReturnFullIntervalBin",!1),supportsFirstDayOfWeek:p(s,"supportsFirstDayOfWeek",!1),supportsNormalization:p(s,"supportsNormalization",!1),supportedStatistics:i(s),supportedNormalizationTypes:a(s)}}function A(t){const s=t.ownershipBasedAccessControlForFeatures,e=t?t.advancedEditingCapabilities:void 0;return{supportsGeometryUpdate:p(t,"allowGeometryUpdates",!0),supportsGlobalId:p(t,"supportsApplyEditsWithGlobalIds",!1),supportsReturnServiceEditsInSourceSpatialReference:p(t,"supportsReturnServiceEditsInSourceSR",!1),supportsRollbackOnFailure:p(t,"supportsRollbackOnFailureParameter",!1),supportsUpdateWithoutM:p(t,"allowUpdateWithoutMValues",!1),supportsUploadWithItemId:p(t,"supportsAttachmentsByUploadId",!1),supportsDeleteByAnonymous:p(s,"allowAnonymousToDelete",!0),supportsDeleteByOthers:p(s,"allowOthersToDelete",!0),supportsUpdateByAnonymous:p(s,"allowAnonymousToUpdate",!0),supportsUpdateByOthers:p(s,"allowOthersToUpdate",!0),supportsAsyncApplyEdits:p(e,"supportsAsyncApplyEdits",!1),zDefault:r(t,"zDefault",void 0)}}function S(t){return{operations:{supportsAppend:p(t,"supportsAppend",!1),supportsCoverageQuery:t?.playbackInfo?.klv["0601"]??!1,supportsExportClip:p(t,"supportsExportClip",!1),supportsExportFrameset:p(t,"supportsExportFrameset",!1),supportsMensuration:p(t,"supportsMensuration",!1),supportsPreviews:p(t,"supportsPreviews",!1),supportsUpdate:p(t,"supportsUpdate",!1)}}}export{c as getFeatureLayerCapabilities,S as getVideoLayerCapabilities};
|
package/package.json
CHANGED
package/popup/ExpressionInfo.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as r}from"tslib";import{JSONSupport as t}from"../core/JSONSupport.js";import{property as e}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/Logger.js";import"../core/RandomLCG.js";import{subclass as o}from"../core/accessorSupport/decorators/subclass.js";var s;let p=s=class extends t{constructor(r){super(r),this.name=null,this.title=null,this.expression=null,this.returnType=null}clone(){return new s({name:this.name,title:this.title,expression:this.expression,returnType:this.returnType})}};r([e({type:String,json:{write:!0}})],p.prototype,"name",void 0),r([e({type:String,json:{write:!0}})],p.prototype,"title",void 0),r([e({type:String,json:{write:!0}})],p.prototype,"expression",void 0),r([e({type:["string","number"],json:{write:!0}})],p.prototype,"returnType",void 0),p=s=r([o("esri.popup.ExpressionInfo")],p);export{
|
|
5
|
+
import{__decorate as r}from"tslib";import{JSONSupport as t}from"../core/JSONSupport.js";import{property as e}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/Logger.js";import"../core/RandomLCG.js";import{subclass as o}from"../core/accessorSupport/decorators/subclass.js";var s;let p=s=class extends t{constructor(r){super(r),this.name=null,this.title=null,this.expression=null,this.returnType=null}clone(){return new s({name:this.name,title:this.title,expression:this.expression,returnType:this.returnType})}};r([e({type:String,json:{write:!0}})],p.prototype,"name",void 0),r([e({type:String,json:{write:!0}})],p.prototype,"title",void 0),r([e({type:String,json:{write:!0}})],p.prototype,"expression",void 0),r([e({type:["string","number"],json:{write:!0}})],p.prototype,"returnType",void 0),p=s=r([o("esri.popup.ExpressionInfo")],p);const i=p;export{i as default};
|
package/popup/FieldInfo.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{ClonableMixin as o}from"../core/Clonable.js";import{JSONMap as e}from"../core/jsonMap.js";import{JSONSupport as r}from"../core/JSONSupport.js";import{property as s}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/Logger.js";import"../core/RandomLCG.js";import{enumeration as i}from"../core/accessorSupport/decorators/enumeration.js";import{reader as l}from"../core/accessorSupport/decorators/reader.js";import{subclass as p}from"../core/accessorSupport/decorators/subclass.js";import{fieldInfoFormatFromFieldFormat as a,fieldFormatFromFieldInfoFormat as n,formatTypes as m}from"../layers/support/fieldFormatUtils.js";import
|
|
5
|
+
import{__decorate as t}from"tslib";import{ClonableMixin as o}from"../core/Clonable.js";import{JSONMap as e}from"../core/jsonMap.js";import{JSONSupport as r}from"../core/JSONSupport.js";import{property as s}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/Logger.js";import"../core/RandomLCG.js";import{enumeration as i}from"../core/accessorSupport/decorators/enumeration.js";import{reader as l}from"../core/accessorSupport/decorators/reader.js";import{subclass as p}from"../core/accessorSupport/decorators/subclass.js";import{fieldInfoFormatFromFieldFormat as a,fieldFormatFromFieldInfoFormat as n,formatTypes as m}from"../layers/support/fieldFormatUtils.js";import c from"./support/FieldInfoFormat.js";let d=class extends(o(r)){constructor(t){super(t),this.fieldName=null,this.isEditable=!0,this.label=null,this.statisticType=null,this.stringFieldOption="text-box",this.tooltip=null,this.visible=!0}set fieldFormat(t){this._set("fieldFormat",t),this._set("format",t?a(t):null)}set format(t){this._set("format",t),this._set("fieldFormat",t?n(t):null)}readFormat(t,o){if(!o.fieldFormat)return t?c.fromJSON(t):null}clone(){const t=super.clone();return t._set("format",this.format?.clone()),t._set("fieldFormat",this.fieldFormat?.clone()),t}};t([s({value:null,clonable:!1,types:m,json:{write:{overridePolicy(t,o,e){const{fieldName:r}=this;return{enabled:!!r&&!r.startsWith("expression/")&&!r.startsWith("relationships/")&&!!e?.writeFieldFormat}}}}})],d.prototype,"fieldFormat",null),t([s({type:String,json:{write:!0}})],d.prototype,"fieldName",void 0),t([s({value:null,clonable:!1,type:c,json:{write:!0}})],d.prototype,"format",null),t([l("format")],d.prototype,"readFormat",null),t([s({type:Boolean,json:{write:{alwaysWriteDefaults:!0},default:!0}})],d.prototype,"isEditable",void 0),t([s({type:String,json:{write:!0}})],d.prototype,"label",void 0),t([s({type:["count","sum","min","max","avg","stddev","var"],json:{write:!0}})],d.prototype,"statisticType",void 0),t([i(new e({richtext:"rich-text",textarea:"text-area",textbox:"text-box"}),{default:"text-box"})],d.prototype,"stringFieldOption",void 0),t([s({type:String,json:{write:!0}})],d.prototype,"tooltip",void 0),t([s({type:Boolean,json:{write:!0}})],d.prototype,"visible",void 0),d=t([p("esri.popup.FieldInfo")],d);const f=d;export{f as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{ClonableMixin as o}from"../../core/Clonable.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as r}from"../../core/accessorSupport/decorators/subclass.js";import s from"./Content.js";import p from"../support/AttachmentsOrderByInfo.js";let i=class extends(o(s)){constructor(t){super(t),this.attachmentKeywords=null,this.attachmentTypes=null,this.description=null,this.displayType="auto",this.orderByFields=null,this.title=null,this.type="attachments"}};t([e({type:[String],json:{write:!0}})],i.prototype,"attachmentKeywords",void 0),t([e({type:[["application","audio","image","model","text","video"]],json:{write:!0}})],i.prototype,"attachmentTypes",void 0),t([e({type:String,json:{write:!0}})],i.prototype,"description",void 0),t([e({type:["auto","preview","list"],json:{write:!0}})],i.prototype,"displayType",void 0),t([e({type:[p],json:{write:!0}})],i.prototype,"orderByFields",void 0),t([e({type:String,json:{write:!0}})],i.prototype,"title",void 0),t([e({type:["attachments"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],i.prototype,"type",void 0),i=t([r("esri.popup.content.AttachmentsContent")],i);export{
|
|
5
|
+
import{__decorate as t}from"tslib";import{ClonableMixin as o}from"../../core/Clonable.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as r}from"../../core/accessorSupport/decorators/subclass.js";import s from"./Content.js";import p from"../support/AttachmentsOrderByInfo.js";let i=class extends(o(s)){constructor(t){super(t),this.attachmentKeywords=null,this.attachmentTypes=null,this.description=null,this.displayType="auto",this.orderByFields=null,this.title=null,this.type="attachments"}};t([e({type:[String],json:{write:!0}})],i.prototype,"attachmentKeywords",void 0),t([e({type:[["application","audio","image","model","text","video"]],json:{write:!0}})],i.prototype,"attachmentTypes",void 0),t([e({type:String,json:{write:!0}})],i.prototype,"description",void 0),t([e({type:["auto","preview","list"],json:{write:!0}})],i.prototype,"displayType",void 0),t([e({type:[p],json:{write:!0}})],i.prototype,"orderByFields",void 0),t([e({type:String,json:{write:!0}})],i.prototype,"title",void 0),t([e({type:["attachments"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],i.prototype,"type",void 0),i=t([r("esri.popup.content.AttachmentsContent")],i);const n=i;export{n as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as r}from"tslib";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";import e from"./mixins/ChartMediaInfo.js";import{chartTypeKebabDict as s}from"./support/chartMediaInfoUtils.js";var a;let i=a=class extends e{constructor(r){super(r),this.type="bar-chart"}clone(){return new a({altText:this.altText,title:this.title,caption:this.caption,value:this.value?.clone()})}};r([t({type:["bar-chart"],readOnly:!0,json:{type:["barchart"],read:!1,write:{writer:s.write,isRequired:!0}}})],i.prototype,"type",void 0),i=a=r([o("esri.popup.content.BarChartMediaInfo")],i);export{
|
|
5
|
+
import{__decorate as r}from"tslib";import{property as t}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";import e from"./mixins/ChartMediaInfo.js";import{chartTypeKebabDict as s}from"./support/chartMediaInfoUtils.js";var a;let i=a=class extends e{constructor(r){super(r),this.type="bar-chart"}clone(){return new a({altText:this.altText,title:this.title,caption:this.caption,value:this.value?.clone()})}};r([t({type:["bar-chart"],readOnly:!0,json:{type:["barchart"],read:!1,write:{writer:s.write,isRequired:!0}}})],i.prototype,"type",void 0),i=a=r([o("esri.popup.content.BarChartMediaInfo")],i);const p=i;export{p as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";import e from"./mixins/ChartMediaInfo.js";import{chartTypeKebabDict as s}from"./support/chartMediaInfoUtils.js";var i;let p=i=class extends e{constructor(t){super(t),this.type="column-chart"}clone(){return new i({altText:this.altText,title:this.title,caption:this.caption,value:this.value?.clone()})}};t([r({type:["column-chart"],readOnly:!0,json:{type:["columnchart"],read:!1,write:{writer:s.write,isRequired:!0}}})],p.prototype,"type",void 0),p=i=t([o("esri.popup.content.ColumnChartMediaInfo")],p);export{
|
|
5
|
+
import{__decorate as t}from"tslib";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as o}from"../../core/accessorSupport/decorators/subclass.js";import e from"./mixins/ChartMediaInfo.js";import{chartTypeKebabDict as s}from"./support/chartMediaInfoUtils.js";var i;let p=i=class extends e{constructor(t){super(t),this.type="column-chart"}clone(){return new i({altText:this.altText,title:this.title,caption:this.caption,value:this.value?.clone()})}};t([r({type:["column-chart"],readOnly:!0,json:{type:["columnchart"],read:!1,write:{writer:s.write,isRequired:!0}}})],p.prototype,"type",void 0),p=i=t([o("esri.popup.content.ColumnChartMediaInfo")],p);const a=p;export{a as default};
|
package/popup/content/Content.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as o}from"tslib";import{JSONSupport as t}from"../../core/JSONSupport.js";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";let s=class extends t{constructor(o){super(o),this.type=null}};o([r({type:["attachments","custom","fields","media","text","expression","relationship","utility-network-associations"],readOnly:!0,json:{read:!1,write:!0}})],s.prototype,"type",void 0),s=o([e("esri.popup.content.Content")],s);export{
|
|
5
|
+
import{__decorate as o}from"tslib";import{JSONSupport as t}from"../../core/JSONSupport.js";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";let s=class extends t{constructor(o){super(o),this.type=null}};o([r({type:["attachments","custom","fields","media","text","expression","relationship","utility-network-associations"],readOnly:!0,json:{read:!1,write:!0}})],s.prototype,"type",void 0),s=o([e("esri.popup.content.Content")],s);const p=s;export{p as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as o}from"tslib";import{clone as
|
|
5
|
+
import{__decorate as o}from"tslib";import{clone as t}from"../../core/lang.js";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import s from"./Content.js";var p;let i=p=class extends s{constructor(o){super(o),this.creator=null,this.destroyer=null,this.outFields=null,this.type="custom"}clone(){return new p({creator:this.creator,destroyer:this.destroyer,outFields:Array.isArray(this.outFields)?t(this.outFields):null})}};o([r()],i.prototype,"creator",void 0),o([r()],i.prototype,"destroyer",void 0),o([r()],i.prototype,"outFields",void 0),o([r({type:["custom"],readOnly:!0})],i.prototype,"type",void 0),i=p=o([e("esri.popup.content.CustomContent")],i);const c=i;export{c as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as o}from"tslib";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as r}from"../../core/accessorSupport/decorators/subclass.js";import s from"../ElementExpressionInfo.js";import t from"./Content.js";var p;let n=p=class extends t{constructor(o){super(o),this.expressionInfo=null,this.type="expression"}clone(){return new p({expressionInfo:this.expressionInfo?.clone()})}};o([e({type:s,json:{write:!0}})],n.prototype,"expressionInfo",void 0),o([e({type:["expression"],readOnly:!0,json:{read:!1,write:!0}})],n.prototype,"type",void 0),n=p=o([r("esri.popup.content.ExpressionContent")],n);export{
|
|
5
|
+
import{__decorate as o}from"tslib";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as r}from"../../core/accessorSupport/decorators/subclass.js";import s from"../ElementExpressionInfo.js";import t from"./Content.js";var p;let n=p=class extends t{constructor(o){super(o),this.expressionInfo=null,this.type="expression"}clone(){return new p({expressionInfo:this.expressionInfo?.clone()})}};o([e({type:s,json:{write:!0}})],n.prototype,"expressionInfo",void 0),o([e({type:["expression"],readOnly:!0,json:{read:!1,write:!0}})],n.prototype,"type",void 0),n=p=o([r("esri.popup.content.ExpressionContent")],n);const i=n;export{i as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{clone as
|
|
5
|
+
import{__decorate as t}from"tslib";import{clone as o}from"../../core/lang.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import{subclass as r}from"../../core/accessorSupport/decorators/subclass.js";import i from"../FieldInfo.js";import s from"./Content.js";var p;let n=p=class extends s{constructor(t){super(t),this.attributes=null,this.description=null,this.fieldInfos=null,this.title=null,this.type="fields"}clone(){return new p(o({attributes:this.attributes,description:this.description,fieldInfos:this.fieldInfos,title:this.title}))}};t([e({type:Object,json:{write:!0}})],n.prototype,"attributes",void 0),t([e({type:String,json:{write:!0}})],n.prototype,"description",void 0),t([e({type:[i],json:{write:!0}})],n.prototype,"fieldInfos",void 0),t([e({type:String,json:{write:!0}})],n.prototype,"title",void 0),t([e({type:["fields"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],n.prototype,"type",void 0),n=p=t([r("esri.popup.content.FieldsContent")],n);const l=n;export{l as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as e}from"tslib";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as t}from"../../core/accessorSupport/decorators/subclass.js";import o from"./mixins/MediaInfo.js";import s from"./support/ImageMediaInfoValue.js";var i;let p=i=class extends o{constructor(e){super(e),this.refreshInterval=0,this.type="image",this.value=void 0}clone(){return new i({altText:this.altText,title:this.title,caption:this.caption,refreshInterval:this.refreshInterval,value:this.value?.clone()})}};e([r({type:Number,json:{write:!0}})],p.prototype,"refreshInterval",void 0),e([r({type:["image"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],p.prototype,"type",void 0),e([r({type:s,json:{write:{isRequired:!0}}})],p.prototype,"value",void 0),p=i=e([t("esri.popup.content.ImageMediaInfo")],p);export{
|
|
5
|
+
import{__decorate as e}from"tslib";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as t}from"../../core/accessorSupport/decorators/subclass.js";import o from"./mixins/MediaInfo.js";import s from"./support/ImageMediaInfoValue.js";var i;let p=i=class extends o{constructor(e){super(e),this.refreshInterval=0,this.type="image",this.value=void 0}clone(){return new i({altText:this.altText,title:this.title,caption:this.caption,refreshInterval:this.refreshInterval,value:this.value?.clone()})}};e([r({type:Number,json:{write:!0}})],p.prototype,"refreshInterval",void 0),e([r({type:["image"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],p.prototype,"type",void 0),e([r({type:s,json:{write:{isRequired:!0}}})],p.prototype,"value",void 0),p=i=e([t("esri.popup.content.ImageMediaInfo")],p);const a=p;export{a as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import o from"./mixins/ChartMediaInfo.js";import{chartTypeKebabDict as
|
|
5
|
+
import{__decorate as t}from"tslib";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import o from"./mixins/ChartMediaInfo.js";import{chartTypeKebabDict as s}from"./support/chartMediaInfoUtils.js";var i;let p=i=class extends o{constructor(t){super(t),this.type="line-chart"}clone(){return new i({altText:this.altText,title:this.title,caption:this.caption,value:this.value?.clone()})}};t([r({type:["line-chart"],readOnly:!0,json:{type:["linechart"],read:!1,write:{writer:s.write,isRequired:!0}}})],p.prototype,"type",void 0),p=i=t([e("esri.popup.content.LineChartMediaInfo")],p);const a=p;export{a as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{clone as o}from"../../core/lang.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import{reader as r}from"../../core/accessorSupport/decorators/reader.js";import{subclass as i}from"../../core/accessorSupport/decorators/subclass.js";import{writer as s}from"../../core/accessorSupport/decorators/writer.js";import p from"./BarChartMediaInfo.js";import a from"./ColumnChartMediaInfo.js";import n from"./Content.js";import d from"./ImageMediaInfo.js";import m from"./LineChartMediaInfo.js";import f from"./PieChartMediaInfo.js";import{types as c}from"./support/mediaInfoTypes.js";var l;let u=l=class extends n{constructor(t){super(t),this.activeMediaInfoIndex=null,this.attributes=null,this.description=null,this.mediaInfos=null,this.title=null,this.type="media"}readMediaInfos(t){return t&&t.map(t=>"image"===t.type?d.fromJSON(t):"barchart"===t.type?p.fromJSON(t):"columnchart"===t.type?a.fromJSON(t):"linechart"===t.type?m.fromJSON(t):"piechart"===t.type?f.fromJSON(t):void 0).filter(Boolean)}writeMediaInfos(t,o){o.mediaInfos=t&&t.map(t=>t.toJSON())}clone(){return new l(o({activeMediaInfoIndex:this.activeMediaInfoIndex,attributes:this.attributes,description:this.description,mediaInfos:this.mediaInfos,title:this.title}))}};t([e()],u.prototype,"activeMediaInfoIndex",void 0),t([e({type:Object,json:{write:!0}})],u.prototype,"attributes",void 0),t([e({type:String,json:{write:!0}})],u.prototype,"description",void 0),t([e({types:[c]})],u.prototype,"mediaInfos",void 0),t([r("mediaInfos")],u.prototype,"readMediaInfos",null),t([s("mediaInfos")],u.prototype,"writeMediaInfos",null),t([e({type:String,json:{write:!0}})],u.prototype,"title",void 0),t([e({type:["media"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],u.prototype,"type",void 0),u=l=t([i("esri.popup.content.MediaContent")],u);export{
|
|
5
|
+
import{__decorate as t}from"tslib";import{clone as o}from"../../core/lang.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import{reader as r}from"../../core/accessorSupport/decorators/reader.js";import{subclass as i}from"../../core/accessorSupport/decorators/subclass.js";import{writer as s}from"../../core/accessorSupport/decorators/writer.js";import p from"./BarChartMediaInfo.js";import a from"./ColumnChartMediaInfo.js";import n from"./Content.js";import d from"./ImageMediaInfo.js";import m from"./LineChartMediaInfo.js";import f from"./PieChartMediaInfo.js";import{types as c}from"./support/mediaInfoTypes.js";var l;let u=l=class extends n{constructor(t){super(t),this.activeMediaInfoIndex=null,this.attributes=null,this.description=null,this.mediaInfos=null,this.title=null,this.type="media"}readMediaInfos(t){return t&&t.map(t=>"image"===t.type?d.fromJSON(t):"barchart"===t.type?p.fromJSON(t):"columnchart"===t.type?a.fromJSON(t):"linechart"===t.type?m.fromJSON(t):"piechart"===t.type?f.fromJSON(t):void 0).filter(Boolean)}writeMediaInfos(t,o){o.mediaInfos=t&&t.map(t=>t.toJSON())}clone(){return new l(o({activeMediaInfoIndex:this.activeMediaInfoIndex,attributes:this.attributes,description:this.description,mediaInfos:this.mediaInfos,title:this.title}))}};t([e()],u.prototype,"activeMediaInfoIndex",void 0),t([e({type:Object,json:{write:!0}})],u.prototype,"attributes",void 0),t([e({type:String,json:{write:!0}})],u.prototype,"description",void 0),t([e({types:[c]})],u.prototype,"mediaInfos",void 0),t([r("mediaInfos")],u.prototype,"readMediaInfos",null),t([s("mediaInfos")],u.prototype,"writeMediaInfos",null),t([e({type:String,json:{write:!0}})],u.prototype,"title",void 0),t([e({type:["media"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],u.prototype,"type",void 0),u=l=t([i("esri.popup.content.MediaContent")],u);const I=u;export{I as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import o from"./mixins/ChartMediaInfo.js";import{chartTypeKebabDict as
|
|
5
|
+
import{__decorate as t}from"tslib";import{property as r}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import o from"./mixins/ChartMediaInfo.js";import{chartTypeKebabDict as s}from"./support/chartMediaInfoUtils.js";var i;let p=i=class extends o{constructor(t){super(t),this.type="pie-chart"}clone(){return new i({altText:this.altText,title:this.title,caption:this.caption,value:this.value?.clone()})}};t([r({type:["pie-chart"],readOnly:!0,json:{type:["piechart"],read:!1,write:{writer:s.write,isRequired:!0}}})],p.prototype,"type",void 0),p=i=t([e("esri.popup.content.PieChartMediaInfo")],p);const a=p;export{a as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{ClonableMixin as o}from"../../core/Clonable.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import{Integer as r}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as i}from"../../core/accessorSupport/decorators/subclass.js";import
|
|
5
|
+
import{__decorate as t}from"tslib";import{ClonableMixin as o}from"../../core/Clonable.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import{Integer as r}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as i}from"../../core/accessorSupport/decorators/subclass.js";import s from"./Content.js";import p from"../support/RelatedRecordsInfoFieldOrder.js";let n=class extends(o(s)){constructor(t){super(t),this.description=null,this.displayCount=null,this.displayType="list",this.orderByFields=null,this.relationshipId=null,this.title=null,this.type="relationship"}};t([e({type:String,json:{write:!0}})],n.prototype,"description",void 0),t([e({type:Number,json:{type:r,write:!0}})],n.prototype,"displayCount",void 0),t([e({type:["list"],json:{write:{isRequired:!0}}})],n.prototype,"displayType",void 0),t([e({type:[p],json:{write:!0}})],n.prototype,"orderByFields",void 0),t([e({type:Number,json:{type:r,write:{isRequired:!0}}})],n.prototype,"relationshipId",void 0),t([e({type:String,json:{write:!0}})],n.prototype,"title",void 0),t([e({type:["relationship"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],n.prototype,"type",void 0),n=t([i("esri.popup.content.RelationshipContent")],n);const l=n;export{l as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{property as
|
|
5
|
+
import{__decorate as t}from"tslib";import{property as o}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import r from"./Content.js";var s;let p=s=class extends r{constructor(t){super(t),this.text=null,this.type="text"}clone(){return new s({text:this.text})}};t([o({type:String,json:{write:!0}})],p.prototype,"text",void 0),t([o({type:["text"],readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],p.prototype,"type",void 0),p=s=t([e("esri.popup.content.TextContent")],p);const i=p;export{i as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as o}from"tslib";import{ClonableMixin as t}from"../../core/Clonable.js";import{property as r}from"../../core/accessorSupport/decorators/property.js";import{Integer as s}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{enumeration as i}from"../../core/accessorSupport/decorators/enumeration.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import p from"./Content.js";import n from"../support/UtilityNetworkAssociationType.js";let c=class extends(t(p)){constructor(o){super(o),this.description=null,this.displayCount=null,this.title=null,this.associationTypes=[],this.type="utility-network-associations"}};o([r({type:String,json:{write:!0}})],c.prototype,"description",void 0),o([r({type:Number,json:{type:s,write:!0}})],c.prototype,"displayCount",void 0),o([r({type:String,json:{write:!0}})],c.prototype,"title",void 0),o([r({type:[n],json:{write:!0}})],c.prototype,"associationTypes",void 0),o([i({utilityNetworkAssociations:"utility-network-associations"})],c.prototype,"type",void 0),c=o([e("esri.popup.content.UtilityNetworkAssociationsContent")],c);export{
|
|
5
|
+
import{__decorate as o}from"tslib";import{ClonableMixin as t}from"../../core/Clonable.js";import{property as r}from"../../core/accessorSupport/decorators/property.js";import{Integer as s}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{enumeration as i}from"../../core/accessorSupport/decorators/enumeration.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import p from"./Content.js";import n from"../support/UtilityNetworkAssociationType.js";let c=class extends(t(p)){constructor(o){super(o),this.description=null,this.displayCount=null,this.title=null,this.associationTypes=[],this.type="utility-network-associations"}};o([r({type:String,json:{write:!0}})],c.prototype,"description",void 0),o([r({type:Number,json:{type:s,write:!0}})],c.prototype,"displayCount",void 0),o([r({type:String,json:{write:!0}})],c.prototype,"title",void 0),o([r({type:[n],json:{write:!0}})],c.prototype,"associationTypes",void 0),o([i({utilityNetworkAssociations:"utility-network-associations"})],c.prototype,"type",void 0),c=o([e("esri.popup.content.UtilityNetworkAssociationsContent")],c);const a=c;export{a as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as
|
|
5
|
+
import{__decorate as o}from"tslib";import{property as r}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as t}from"../../../core/accessorSupport/decorators/subclass.js";import e from"./MediaInfo.js";import s from"../support/ChartMediaInfoValue.js";let p=class extends e{constructor(o){super(o),this.type=null,this.value=void 0}};o([r({type:["bar-chart","column-chart","line-chart","pie-chart"],readOnly:!0,json:{read:!1,write:!0}})],p.prototype,"type",void 0),o([r({type:s,json:{write:{isRequired:!0}}})],p.prototype,"value",void 0),p=o([t("esri.popup.content.mixins.ChartMediaInfo")],p);const i=p;export{i as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{JSONSupport as o}from"../../../core/JSONSupport.js";import{property as r}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as e}from"../../../core/accessorSupport/decorators/subclass.js";let p=class extends o{constructor(t){super(t),this.altText=null,this.caption="",this.title="",this.type=null}};t([r({type:String,json:{write:!0}})],p.prototype,"altText",void 0),t([r({type:String,json:{write:!0}})],p.prototype,"caption",void 0),t([r({type:String,json:{write:!0}})],p.prototype,"title",void 0),t([r({type:["image","bar-chart","column-chart","line-chart","pie-chart"],readOnly:!0,json:{read:!1,write:!0}})],p.prototype,"type",void 0),p=t([e("esri.popup.content.mixins.MediaInfo")],p);export{
|
|
5
|
+
import{__decorate as t}from"tslib";import{JSONSupport as o}from"../../../core/JSONSupport.js";import{property as r}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as e}from"../../../core/accessorSupport/decorators/subclass.js";let p=class extends o{constructor(t){super(t),this.altText=null,this.caption="",this.title="",this.type=null}};t([r({type:String,json:{write:!0}})],p.prototype,"altText",void 0),t([r({type:String,json:{write:!0}})],p.prototype,"caption",void 0),t([r({type:String,json:{write:!0}})],p.prototype,"title",void 0),t([r({type:["image","bar-chart","column-chart","line-chart","pie-chart"],readOnly:!0,json:{read:!1,write:!0}})],p.prototype,"type",void 0),p=t([e("esri.popup.content.mixins.MediaInfo")],p);const i=p;export{i as default};
|
package/popup/content.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import t from"./content/AttachmentsContent.js";import n from"./content/Content.js";export{default as CustomContent}from"./content/CustomContent.js";import
|
|
5
|
+
import t from"./content/AttachmentsContent.js";import n from"./content/Content.js";export{default as CustomContent}from"./content/CustomContent.js";import o from"./content/ExpressionContent.js";import e from"./content/FieldsContent.js";import i from"./content/MediaContent.js";import s from"./content/RelationshipContent.js";import r from"./content/TextContent.js";import m from"./content/UtilityNetworkAssociationsContent.js";function p(t){return t instanceof n}const a={base:null,key:"type",typeMap:{attachment:t,media:i,text:r,expression:o,field:e,relationship:s,utilityNetworkAssociations:m}},c={base:null,key:"type",typeMap:{attachment:t,media:i,text:r,expression:o,field:e,relationship:s}};export{t as AttachmentsContent,n as BaseContent,o as ExpressionContent,e as FieldsContent,i as MediaContent,s as RelationshipContent,r as TextContent,m as UtilityNetworkAssociationsContent,p as isContent,a as persistableTypes,c as persistableWebSceneTypes};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as o}from"tslib";import{ClonableMixin as r}from"../../core/Clonable.js";import{JSONSupport as t}from"../../core/JSONSupport.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import{Integer as p}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{enumeration as s}from"../../core/accessorSupport/decorators/enumeration.js";import{subclass as a}from"../../core/accessorSupport/decorators/subclass.js";import{dateFormatJSONMap as i}from"../../intl/date.js";let c=class extends(r(t)){constructor(o){super(o),this.dateFormat=null,this.digitSeparator=!1,this.places=null}};o([s(i)],c.prototype,"dateFormat",void 0),o([e({type:Boolean,json:{write:!0}})],c.prototype,"digitSeparator",void 0),o([e({type:p,json:{write:!0}})],c.prototype,"places",void 0),c=o([a("esri.popup.support.FieldInfoFormat")],c);export{
|
|
5
|
+
import{__decorate as o}from"tslib";import{ClonableMixin as r}from"../../core/Clonable.js";import{JSONSupport as t}from"../../core/JSONSupport.js";import{property as e}from"../../core/accessorSupport/decorators/property.js";import{Integer as p}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{enumeration as s}from"../../core/accessorSupport/decorators/enumeration.js";import{subclass as a}from"../../core/accessorSupport/decorators/subclass.js";import{dateFormatJSONMap as i}from"../../intl/date.js";let c=class extends(r(t)){constructor(o){super(o),this.dateFormat=null,this.digitSeparator=!1,this.places=null}};o([s(i)],c.prototype,"dateFormat",void 0),o([e({type:Boolean,json:{write:!0}})],c.prototype,"digitSeparator",void 0),o([e({type:p,json:{write:!0}})],c.prototype,"places",void 0),c=o([a("esri.popup.support.FieldInfoFormat")],c);const m=c;export{m as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{
|
|
5
|
+
import{getGeometryType as e,getJsonType as t}from"../../geometry/support/jsonUtils.js";function r(e){return{geometryType:t(e[0]),geometries:e.map(e=>e.toJSON())}}function o(t,r,o){const n=e(r);return t.map(e=>{const t=n.fromJSON(e);return t.spatialReference=o,t})}export{o as decodeGeometries,r as encodeGeometries};
|
|
@@ -16,6 +16,7 @@ export const executeSearchStreaming: __esri.knowledgeGraphService["executeSearch
|
|
|
16
16
|
export const executeUpdateGraphProperty: __esri.knowledgeGraphService["executeUpdateGraphProperty"];
|
|
17
17
|
export const executeUpdateNamedType: __esri.knowledgeGraphService["executeUpdateNamedType"];
|
|
18
18
|
export const executeUpdateSearchIndex: __esri.knowledgeGraphService["executeUpdateSearchIndex"];
|
|
19
|
+
export const fetchAllClientDataKeys: __esri.knowledgeGraphService["fetchAllClientDataKeys"];
|
|
19
20
|
export const fetchAsynchronousFindPathsResultData: __esri.knowledgeGraphService["fetchAsynchronousFindPathsResultData"];
|
|
20
21
|
export const fetchClientDataAtKeys: __esri.knowledgeGraphService["fetchClientDataAtKeys"];
|
|
21
22
|
export const fetchKnowledgeGraph: __esri.knowledgeGraphService["fetchKnowledgeGraph"];
|
package/support/popupUtils.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import e from"../PopupTemplate.js";import{isFieldVisibleByDefault as t,isFieldEditable as i,getDisplayFieldName as n,isRasterPixelValueField as o}from"../layers/support/fieldUtils.js";import r from"../popup/FieldInfo.js";import s from"../popup/content/AttachmentsContent.js";import l from"../popup/content/FieldsContent.js";import a from"../popup/support/FieldInfoFormat.js";function d({displayField:t,editFieldsInfo:i,fields:n,objectIdField:o,title:r},s){if(!n)return null;const l=b({editFieldsInfo:i,fields:n,objectIdField:o},s);if(!l.length)return null;const a=I({titleBase:r,fields:n,displayField:t}),d=y();return new e({title:a,content:d,fieldInfos:l})}function u(t){const{fields:i,featureReduction:n,title:o}=t,r=n.fields;if(!r)return null;const s=w(r,i??[]);if(!s.length)return null;const l=v();return new e({title:o,content:l,fieldInfos:s})}const c=(e,i)=>i.visibleFieldNames?i.visibleFieldNames.has(e.name):t(e,i);function f({fields:e,ignoreFieldTypes:t,sortDisabled:i}){const n=e;return t&&(e=e.filter(e=>!t.includes(e.type))),e===n&&(e=e.slice()),!0!==i&&e.sort(p),e}function p(e,t){return"oid"===e.type?-1:"oid"===t.type?1:j(e)?-1:j(t)?1:(e.alias||e.name).toLocaleLowerCase().localeCompare((t.alias||t.name).toLocaleLowerCase())}function m(e,t){return new l({fieldInfos:b(e,t).filter(e=>e.visible)})}function b(e,t){const n=t?.visibleFieldNames;return f({fields:e.fields??[],ignoreFieldTypes:t?.ignoreFieldTypes||C,sortDisabled:t?.sortDisabled}).map(t=>new r({fieldName:t.name,isEditable:i(t,e),label:t.alias,format:g(t),visible:c(t,{...e,visibleFieldNames:n})}))}function w(e,t){return e.map(e=>new r({fieldName:e.name,isEditable:!1,label:e.alias,format:F(e,t),visible:!0}))}function F(e,t){const{onStatisticField:i,onStatisticExpression:n,statisticType:o}=e;if(i){const e=t.find(e=>i===e.name);if(e)return g(e)}return"number"===n?.returnType?new a({digitSeparator:!0,places:2}):"count"===o?new a({digitSeparator:!0,places:0}):void 0}function g(e){switch(e.type){case"small-integer":case"integer":
|
|
5
|
+
import e from"../PopupTemplate.js";import{isFieldVisibleByDefault as t,isFieldEditable as i,getDisplayFieldName as n,isRasterPixelValueField as o}from"../layers/support/fieldUtils.js";import r from"../popup/FieldInfo.js";import s from"../popup/content/AttachmentsContent.js";import l from"../popup/content/FieldsContent.js";import a from"../popup/support/FieldInfoFormat.js";function d({displayField:t,editFieldsInfo:i,fields:n,objectIdField:o,title:r},s){if(!n)return null;const l=b({editFieldsInfo:i,fields:n,objectIdField:o},s);if(!l.length)return null;const a=I({titleBase:r,fields:n,displayField:t}),d=y();return new e({title:a,content:d,fieldInfos:l})}function u(t){const{fields:i,featureReduction:n,title:o}=t,r=n.fields;if(!r)return null;const s=w(r,i??[]);if(!s.length)return null;const l=v();return new e({title:o,content:l,fieldInfos:s})}const c=(e,i)=>i.visibleFieldNames?i.visibleFieldNames.has(e.name):t(e,i);function f({fields:e,ignoreFieldTypes:t,sortDisabled:i}){const n=e;return t&&(e=e.filter(e=>!t.includes(e.type))),e===n&&(e=e.slice()),!0!==i&&e.sort(p),e}function p(e,t){return"oid"===e.type?-1:"oid"===t.type?1:j(e)?-1:j(t)?1:(e.alias||e.name).toLocaleLowerCase().localeCompare((t.alias||t.name).toLocaleLowerCase())}function m(e,t){return new l({fieldInfos:b(e,t).filter(e=>e.visible)})}function b(e,t){const n=t?.visibleFieldNames;return f({fields:e.fields??[],ignoreFieldTypes:t?.ignoreFieldTypes||C,sortDisabled:t?.sortDisabled}).map(t=>new r({fieldName:t.name,isEditable:i(t,e),label:t.alias,format:g(t),visible:c(t,{...e,visibleFieldNames:n})}))}function w(e,t){return e.map(e=>new r({fieldName:e.name,isEditable:!1,label:e.alias,format:F(e,t),visible:!0}))}function F(e,t){const{onStatisticField:i,onStatisticExpression:n,statisticType:o}=e;if(i){const e=t.find(e=>i===e.name);if(e)return g(e)}return"number"===n?.returnType?new a({digitSeparator:!0,places:2}):"count"===o?new a({digitSeparator:!0,places:0}):void 0}function g(e){switch(e.type){case"small-integer":case"integer":return new a({digitSeparator:!0,places:0});case"single":case"double":return new a({digitSeparator:!0,places:2});case"string":return o(e.name)?new a({digitSeparator:!0,places:0}):void 0;default:return}}function y(){return[new l,new s]}function v(){return[new l]}function I(e){const t=n(e),{titleBase:i}=e;return t?`${i}: {${t.trim()}}`:i??""}function j(e){if("name"===(e.name&&e.name.toLowerCase()))return!0;const t=e.alias?.toLowerCase();return"name"===t}const C=["geometry","blob","raster","guid","xml"];export{b as createFieldInfos,m as createFieldsContent,d as createPopupTemplate,u as createPopupTemplateForFeatureReduction};
|
package/support/revision.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
const
|
|
5
|
+
const e="20251011",c="cedf9a663008b6fdee68d041212060a4ced4359c";export{e as buildDate,c as commitHash};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import"../../core/has.js";import{pt2px as e,toPt as t,px2pt as l}from"../../core/screenUtils.js";import{isSubtypeGroupLayer as a}from"../../layers/support/layerUtils.js";import{loadArcade as i}from"../../support/loadArcade.js";import{getStroke as r}from"./gfxUtils.js";import{renderSymbol as s,renderOnce as o}from"./renderUtils.js";import{isSymbol3D as n}from"./typeUtils.js";import{applyColorToSymbol as c,applySizesToSymbol as u,applyRotationToSymbol as p,getColorFromSymbol as f,applyOpacityToColor as y}from"./utils.js";import{renderRelationshipRamp as h}from"../../widgets/Legend/styles/support/relationshipUtils.js";import{getRelationshipRampElement as d}from"../../widgets/Legend/support/relationshipRampUtils.js";let m=null;const b=[255,255,255];function g(e,t){return Math.floor(Math.random()*(t-e+1)+e)}function w(e,t,l){const{backgroundColor:a,outline:i,dotSize:r}=e,s=l?.swatchSize||22,o=.8,n=Math.round(s*s/Math.max(r,.5)**2*o),c=window.devicePixelRatio,u=document.createElement("canvas"),p=s*c;u.width=p,u.height=p,u.style.width=u.width/c+"px",u.style.height=u.height/c+"px";const f=u.getContext("2d");if(a&&(f.fillStyle=a.toCss(!0),f.fillRect(0,0,p,p),f.fill()),f.fillStyle=t?.toCss(!0)??"",m&&m.length/2===n)for(let h=0;h<2*n;h+=2){const e=m[h],t=m[h+1];f.fillRect(e,t,r*c,r*c),f.fill()}else{m=[];for(let e=0;e<2*n;e+=2){const e=g(0,p),t=g(0,p);m.push(e,t),f.fillRect(e,t,r*c,r*c),f.fill()}}i&&(i.color&&(f.strokeStyle=i.color.toCss(!0)),f.lineWidth=i.width,f.strokeRect(0,0,p,p));const y=new Image(s,s);return y.src=u.toDataURL(),y.ariaLabel=l?.ariaLabel??null,y.alt=l?.ariaLabel??"",y}function S(e,t={}){const l=t.radius||40,a=2*Math.PI*l,i=e.length,o=a/i,n=[],c=r(t.outline);null!=c?.width&&(c.width*=2),(c||t.backgroundColor)&&n.push({shape:{type:"circle",cx:l,cy:l,r:l},fill:t.backgroundColor,stroke:c,offset:[0,0]});const u=t.values,p=u&&u.length===i&&100===u.reduce((e,t)=>e+t,0),f=[0];for(let r=0;r<i;r++){let t=null;p&&(t=u[r]*a/100,f.push(t+f[r])),n.push({shape:{type:"circle",cx:l,cy:l,r:l/2},fill:[0,0,0,0],stroke:{width:l,dashArray:`${(t??o)/2} ${a}`,dashoffset:"-"+(p?f[r]/2:r*(o/2)),color:e[r]},offset:[0,0]})}let y=null;const h=2*l+(c?.width||0),d=t.holePercentage;if(d){c&&n.push({shape:{type:"circle",cx:l,cy:l,r:l*d},fill:null,stroke:c,offset:[0,0]});const e=h/2;y=[[{shape:{type:"circle",cx:e,cy:e,r:e},fill:b,stroke:c?{...c,color:b}:null,offset:[0,0]},{shape:{type:"circle",cx:e,cy:e,r:l*d},fill:[0,0,0],stroke:null,offset:[0,0]}]]}return s([n],[h,h],{cssEffectFilter:t.cssEffectFilter,ignoreStrokeWidth:!0,masking:y,rotations:[-90],ariaLabel:t.ariaLabel})}function v(e,t={}){const l=e?.authoringInfo;if(!("relationship"===l?.type)||!l?.numClasses||!e.uniqueValueInfos)return null;const{focus:a,numClasses:i}=l,r=d({focus:a,numClasses:i,infos:e.uniqueValueInfos}),s=t?.node||document.createElement("div");return o(s,()=>h(r,t.id||"relationship",{opacity:t.opacity||1,cssEffectFilter:t.cssEffectFilter,ariaLabel:t.ariaLabel})),s}function V(e,t={}){const l=24,a=75,i="horizontal"===t.align,r=i?a:l,s=i?l:a,o=t.width??r,n=t.height??s,c=t.gradient??!0,u=window.devicePixelRatio,p=o*u,f=n*u,y=document.createElement("canvas");y.width=p,y.height=f,y.ariaLabel=t.ariaLabel??null,y.style.width=`${o}px`,y.style.height=`${n}px`;const h=y.getContext("2d"),d=i?p:0,m=i?0:f;if(c){const t=h.createLinearGradient(0,0,d,m),l=e.length,a=1===l?0:1/(l-1);e.forEach((e,l)=>t.addColorStop(l*a,e.toString())),h.fillStyle=t,h.fillRect(0,0,p,f)}else{const t=i?p/e.length:p,l=i?f:f/e.length;let a=0,r=0;for(const s of e)h.fillStyle=s.toString(),h.fillRect(a,r,t,l),a=i?a+t:0,r=i?0:r+l}const b=document.createElement("div");return b.style.width=`${o}px`,b.style.height=`${n}px`,x(b,t?.cssEffectFilter),b.appendChild(y),b}function k(e){const t=e.match(/drop-shadow\(\s*([^\s]+)\s+[^\s]+\s+[^\s]+\s+.+?\)/);return t?t[1]:null}function x(l,a){if(!a)return;l.style.filter=a;const i=k(a);if(i){const a=e(t(i));a<0?l.style.marginLeft=`${Math.abs(a)}px`:l.style.marginRight=`${a}px`}}async function L(e,t){switch(e.type){case"web-style":{const{previewWebStyleSymbol:l}=await import("./previewWebStyleSymbol.js");return l(e,L,t)}case"label-3d":case"line-3d":case"mesh-3d":case"point-3d":case"polygon-3d":{const{previewSymbol3D:l}=await import("./previewSymbol3D.js");return l(e,t)}case"simple-marker":case"simple-line":case"simple-fill":case"picture-marker":case"picture-fill":case"text":{const{previewSymbol2D:l}=await import("./previewSymbol2D.js");return l(e,t)}case"cim":{const{previewCIMSymbol:l}=await import("./previewCIMSymbol.js");return l(e,t)}default:return}}function R(e){return e&&void 0!==e.opacity?e.opacity*("parent"in e?R(e.parent):1):1}async function
|
|
5
|
+
import"../../core/has.js";import{pt2px as e,toPt as t,px2pt as l}from"../../core/screenUtils.js";import{isSubtypeGroupLayer as a}from"../../layers/support/layerUtils.js";import{loadArcade as i}from"../../support/loadArcade.js";import{getStroke as r}from"./gfxUtils.js";import{renderSymbol as s,renderOnce as o}from"./renderUtils.js";import{isSymbol3D as n}from"./typeUtils.js";import{applyColorToSymbol as c,applySizesToSymbol as u,applyRotationToSymbol as p,getColorFromSymbol as f,applyOpacityToColor as y}from"./utils.js";import{renderRelationshipRamp as h}from"../../widgets/Legend/styles/support/relationshipUtils.js";import{getRelationshipRampElement as d}from"../../widgets/Legend/support/relationshipRampUtils.js";let m=null;const b=[255,255,255];function g(e,t){return Math.floor(Math.random()*(t-e+1)+e)}function w(e,t,l){const{backgroundColor:a,outline:i,dotSize:r}=e,s=l?.swatchSize||22,o=.8,n=Math.round(s*s/Math.max(r,.5)**2*o),c=window.devicePixelRatio,u=document.createElement("canvas"),p=s*c;u.width=p,u.height=p,u.style.width=u.width/c+"px",u.style.height=u.height/c+"px";const f=u.getContext("2d");if(a&&(f.fillStyle=a.toCss(!0),f.fillRect(0,0,p,p),f.fill()),f.fillStyle=t?.toCss(!0)??"",m&&m.length/2===n)for(let h=0;h<2*n;h+=2){const e=m[h],t=m[h+1];f.fillRect(e,t,r*c,r*c),f.fill()}else{m=[];for(let e=0;e<2*n;e+=2){const e=g(0,p),t=g(0,p);m.push(e,t),f.fillRect(e,t,r*c,r*c),f.fill()}}i&&(i.color&&(f.strokeStyle=i.color.toCss(!0)),f.lineWidth=i.width,f.strokeRect(0,0,p,p));const y=new Image(s,s);return y.src=u.toDataURL(),y.ariaLabel=l?.ariaLabel??null,y.alt=l?.ariaLabel??"",y}function S(e,t={}){const l=t.radius||40,a=2*Math.PI*l,i=e.length,o=a/i,n=[],c=r(t.outline);null!=c?.width&&(c.width*=2),(c||t.backgroundColor)&&n.push({shape:{type:"circle",cx:l,cy:l,r:l},fill:t.backgroundColor,stroke:c,offset:[0,0]});const u=t.values,p=u&&u.length===i&&100===u.reduce((e,t)=>e+t,0),f=[0];for(let r=0;r<i;r++){let t=null;p&&(t=u[r]*a/100,f.push(t+f[r])),n.push({shape:{type:"circle",cx:l,cy:l,r:l/2},fill:[0,0,0,0],stroke:{width:l,dashArray:`${(t??o)/2} ${a}`,dashoffset:"-"+(p?f[r]/2:r*(o/2)),color:e[r]},offset:[0,0]})}let y=null;const h=2*l+(c?.width||0),d=t.holePercentage;if(d){c&&n.push({shape:{type:"circle",cx:l,cy:l,r:l*d},fill:null,stroke:c,offset:[0,0]});const e=h/2;y=[[{shape:{type:"circle",cx:e,cy:e,r:e},fill:b,stroke:c?{...c,color:b}:null,offset:[0,0]},{shape:{type:"circle",cx:e,cy:e,r:l*d},fill:[0,0,0],stroke:null,offset:[0,0]}]]}return s([n],[h,h],{cssEffectFilter:t.cssEffectFilter,ignoreStrokeWidth:!0,masking:y,rotations:[-90],ariaLabel:t.ariaLabel})}function v(e,t={}){const l=e?.authoringInfo;if(!("relationship"===l?.type)||!l?.numClasses||!e.uniqueValueInfos)return null;const{focus:a,numClasses:i}=l,r=d({focus:a,numClasses:i,infos:e.uniqueValueInfos}),s=t?.node||document.createElement("div");return o(s,()=>h(r,t.id||"relationship",{opacity:t.opacity||1,cssEffectFilter:t.cssEffectFilter,ariaLabel:t.ariaLabel})),s}function V(e,t={}){const l=24,a=75,i="horizontal"===t.align,r=i?a:l,s=i?l:a,o=t.width??r,n=t.height??s,c=t.gradient??!0,u=window.devicePixelRatio,p=o*u,f=n*u,y=document.createElement("canvas");y.width=p,y.height=f,y.ariaLabel=t.ariaLabel??null,y.style.width=`${o}px`,y.style.height=`${n}px`;const h=y.getContext("2d"),d=i?p:0,m=i?0:f;if(c){const t=h.createLinearGradient(0,0,d,m),l=e.length,a=1===l?0:1/(l-1);e.forEach((e,l)=>t.addColorStop(l*a,e.toString())),h.fillStyle=t,h.fillRect(0,0,p,f)}else{const t=i?p/e.length:p,l=i?f:f/e.length;let a=0,r=0;for(const s of e)h.fillStyle=s.toString(),h.fillRect(a,r,t,l),a=i?a+t:0,r=i?0:r+l}const b=document.createElement("div");return b.style.width=`${o}px`,b.style.height=`${n}px`,x(b,t?.cssEffectFilter),b.appendChild(y),b}function k(e){const t=e.match(/drop-shadow\(\s*([^\s]+)\s+[^\s]+\s+[^\s]+\s+.+?\)/);return t?t[1]:null}function x(l,a){if(!a)return;l.style.filter=a;const i=k(a);if(i){const a=e(t(i));a<0?l.style.marginLeft=`${Math.abs(a)}px`:l.style.marginRight=`${a}px`}}async function L(e,t){switch(e.type){case"web-style":{const{previewWebStyleSymbol:l}=await import("./previewWebStyleSymbol.js");return l(e,L,t)}case"label-3d":case"line-3d":case"mesh-3d":case"point-3d":case"polygon-3d":{const{previewSymbol3D:l}=await import("./previewSymbol3D.js");return l(e,t)}case"simple-marker":case"simple-line":case"simple-fill":case"picture-marker":case"picture-fill":case"text":{const{previewSymbol2D:l}=await import("./previewSymbol2D.js");return l(e,t)}case"cim":{const{previewCIMSymbol:l}=await import("./previewCIMSymbol.js");return l(e,t)}default:return}}function R(e){return e&&void 0!==e.opacity?e.opacity*("parent"in e?R(e.parent):1):1}async function F(e,t){if(!e)return;const l=e.sourceLayer,a=(null!=t&&t.useSourceLayer?l:e.layer)??l,r=t?.ignoreOpacity?1:R(a);if(null!=e.symbol&&(null==t||!0!==t.ignoreGraphicSymbol)){const l="web-style"===e.symbol.type?await e.symbol.fetchSymbol({...t,acceptedFormats:t?.webStyleAcceptedFormats,cache:t?.webStyleCache}):e.symbol.clone();return c(l,null,{add:r}),l}const s=t?.renderer??I(a);let o=s&&"getSymbolAsync"in s?await s.getSymbolAsync(e,t):null;if(!o)return;if(o="web-style"===o.type?await o.fetchSymbol({...t,acceptedFormats:t?.webStyleAcceptedFormats,cache:t?.webStyleCache}):o.clone(),!(s&&"visualVariables"in s&&s.visualVariables?.length&&j(o)))return c(o,null,{add:r}),o;if("arcadeRequiredForVisualVariables"in s&&s.arcadeRequiredForVisualVariables&&null==t?.arcade){const e={...t};e.arcade=await i(),t=e}const{getColor:n,getOpacity:f,getAllSizes:y,getRotationAngle:h}=await import("../../renderers/visualVariables/support/visualVariableUtils.js"),d=[],m=[],b=[],g=[];for(const i of s.visualVariables)switch(i.type){case"color":d.push(i);break;case"opacity":m.push(i);break;case"rotation":g.push(i);break;case"size":i.target||b.push(i)}const w=!!d.length&&d[d.length-1],S=w?n(w,e,t):null,v=!!t?.ignoreOpacity,V=!!m.length&&m[m.length-1],k=V?f(V,e,t):null;if(c(o,S,v?void 0:{override:k,add:r}),b.length&&!0!==t?.ignoreSizeVariables){const l=y(b,e,t);await u(o,l)}if(!0!==t?.ignoreRotationVariables)for(const i of g)p(o,h(i,e,t),i.axis);return o}async function C(e,t){if(!e)return;const{layer:l,sourceLayer:a}=e,r=R(l??a);if(null!=e.symbol&&(null==t||!0!==t.ignoreGraphicSymbol)){const l="web-style"===e.symbol.type?await e.symbol.fetchSymbol({...t,acceptedFormats:t?.webStyleAcceptedFormats}):e.symbol.clone();return f(l,r)}const s=t?.renderer??I(l)??I(a);let o=s&&"getSymbolAsync"in s?await s.getSymbolAsync(e,t):void 0;if(!o)return;o="web-style"===o.type?await o.fetchSymbol({...t,acceptedFormats:t?.webStyleAcceptedFormats}):o.clone();const n=f(o,void 0);if(!s||!("visualVariables"in s)||"visualVariables"in s&&!s.visualVariables||"visualVariables"in s&&!s.visualVariables?.length||!j(o))return n?y(n,r):void 0;if("arcadeRequiredForVisualVariables"in s&&s.arcadeRequiredForVisualVariables&&null==t?.arcade){const e={...t};e.arcade=await i(),t=e}const{getColor:c,getOpacity:u}=await import("../../renderers/visualVariables/support/visualVariableUtils.js"),p=[],h=[];if(s.visualVariables)for(const i of s.visualVariables)switch(i.type){case"color":p.push(i);break;case"opacity":h.push(i)}const d=p.length>0?p[p.length-1]:null,m=(d?c(d,e,t):void 0)??n,b=h.length>0?h[h.length-1]:null,g=b?u(b,e,t):null;return null!=m&&null!=g&&(m.a=g),m?y(m,r):null}function j(e){return!n(e)||"water"!==e.symbolLayers.at(0)?.type}function I(e){if(e)return"renderer"in e?e.renderer:void 0}async function U(e,t,l){if(!e)return;const{layer:a,sourceLayer:i}=e,r=l?.renderer??I(a)??I(i);if(!r)return null;if("visualVariables"in r&&r.visualVariables?.length){const{getRampStops:i}=await import("../../widgets/Legend/support/colorRampUtils.js"),{getRampStops:s}=await import("../../widgets/Legend/support/sizeRampUtils.js"),{getFormatOptionsForVisualVariable:o}=await import("../../widgets/Legend/support/utils.js");let n=null;for(const c of r.visualVariables){const u=t?o(a,c,t.timeZone):null;let p=null;switch(c.type){case"color":p=await i(c,null,u);break;case"opacity":p=await i(c);break;case"size":c.target||(p=await s(r,c,null,l?.scale||t?.scale,t,u))}if(p?.length){const t=p.find((t,l)=>{const a=e.attributes[c.field];return 0===l?a>=t.value:l===p?.length-1?a<=t.value:t.value===a});if(t){n=t.label;break}}}if(n)return n}switch(r.type){case"class-breaks":{const t="getClassBreakInfo"in r?await r.getClassBreakInfo(e,l):null;return t?.label??(t&&r.classBreakInfos?.length>1)?`${t.minValue} - ${t.maxValue}`:null}case"unique-value":{const t="getUniqueValueInfo"in r?await r.getUniqueValueInfo(e,l):null;return t?.label}}return null}async function z(e,t){e?.layer&&a(e.layer)&&((e=e.cloneShallow()).layer=e.layer.findSublayerForFeature(e)??null);const i=null===e?t?.fallbackSymbol??null:await F(e,{ignoreGraphicSymbol:!!e.layer,ignoreOpacity:t?.ignoreOpacity??!0,ignoreRotationVariables:t?.ignoreRotationVariables??!0,ignoreSizeVariables:t?.ignoreSizeVariables??!0})??t?.fallbackSymbol??null;if(!i)return null;const r=await L(i,{geometry:t.useGeometryForShape?e?.geometry??null:null,useMarkerSymbolSize:!1!==t.useMarkerSymbolSize,size:{width:l(t.widthInPixels??16),height:l(t.heightInPixels??16)},..."cim"===i?.type?{cimOptions:{feature:{attributes:e?.attributes??{}}}}:{}});if(!r)return null;return"element"===(t?.format??"element")?r:r.outerHTML}export{C as getDisplayedColor,F as getDisplayedSymbol,U as getLegendLabel,z as previewGraphic,V as renderColorRampPreviewHTML,w as renderDotDensityPreviewHTML,S as renderPieChartPreviewHTML,L as renderPreviewHTML,v as renderRelationshipRampPreviewHTML};
|
package/time/TimeExtent.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{JSONSupport as e}from"../core/JSONSupport.js";import{truncateDate as r,offsetDate as s}from"../core/timeUtils.js";import{property as n}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/Logger.js";import"../core/RandomLCG.js";import{reader as i}from"../core/accessorSupport/decorators/reader.js";import{subclass as l}from"../core/accessorSupport/decorators/subclass.js";import{writer as o}from"../core/accessorSupport/decorators/writer.js";import{system as a}from"./constants.js";var u;let m=class extends e{static{u=this}static get allTime(){return
|
|
5
|
+
import{__decorate as t}from"tslib";import{JSONSupport as e}from"../core/JSONSupport.js";import{truncateDate as r,offsetDate as s}from"../core/timeUtils.js";import{property as n}from"../core/accessorSupport/decorators/property.js";import"../core/has.js";import"../core/Logger.js";import"../core/RandomLCG.js";import{reader as i}from"../core/accessorSupport/decorators/reader.js";import{subclass as l}from"../core/accessorSupport/decorators/subclass.js";import{writer as o}from"../core/accessorSupport/decorators/writer.js";import{system as a}from"./constants.js";var u;let m=class extends e{static{u=this}static get allTime(){return p}static get empty(){return d}static fromArray(t){return new u({start:null!=t[0]?new Date(t[0]):t[0],end:null!=t[1]?new Date(t[1]):t[1]})}constructor(t){super(t),this.end=null,this.start=null}readEnd(t,e){return null!=e.end?new Date(e.end):null}writeEnd(t,e){e.end=t?.getTime()??null}get isAllTime(){return this.equals(u.allTime)}get isEmpty(){return this.equals(u.empty)}readStart(t,e){return null!=e.start?new Date(e.start):null}writeStart(t,e){e.start=t?.getTime()??null}clone(){return new u({end:this.end,start:this.start})}equals(t){if(!t)return!1;const e=this.start?.getTime()??this.start,r=this.end?.getTime()??this.end,s=t.start?.getTime()??t.start,n=t.end?.getTime()??t.end;return e===s&&r===n}expandTo(t,e=a){if(this.isEmpty||this.isAllTime)return this.clone();let n=this.start;n&&(n=r(n,t,e));let i=this.end;if(i){const n=r(i,t,e);i=i.getTime()===n.getTime()?n:s(n,1,t,e)}return new u({start:n,end:i})}intersection(t){if(!t)return this.clone();if(this.isEmpty||t.isEmpty)return u.empty;if(this.isAllTime)return t.clone();if(t.isAllTime)return this.clone();const e=this.start?.getTime()??-1/0,r=this.end?.getTime()??1/0,s=t.start?.getTime()??-1/0,n=t.end?.getTime()??1/0;let i,l;return s>=e&&s<=r?i=s:e>=s&&e<=n&&(i=e),r>=s&&r<=n?l=r:n>=e&&n<=r&&(l=n),null==i||null==l||isNaN(i)||isNaN(l)?u.empty:new u({start:i===-1/0?null:new Date(i),end:l===1/0?null:new Date(l)})}offset(t,e,r=a){if(this.isEmpty||this.isAllTime)return this.clone();const n=new u,{start:i,end:l}=this;return null!=i&&(n.start=s(i,t,e,r)),null!=l&&(n.end=s(l,t,e,r)),n}toArray(){return this.isEmpty?[void 0,void 0]:[this.start?.getTime()??null,this.end?.getTime()??null]}union(t){if(!t||t.isEmpty)return this.clone();if(this.isEmpty)return t.clone();if(this.isAllTime||t.isAllTime)return p.clone();const e=null!=this.start&&null!=t.start?new Date(Math.min(this.start.getTime(),t.start.getTime())):null,r=null!=this.end&&null!=t.end?new Date(Math.max(this.end.getTime(),t.end.getTime())):null;return new u({start:e,end:r})}};t([n({type:Date,json:{write:{allowNull:!0}}})],m.prototype,"end",void 0),t([i("end")],m.prototype,"readEnd",null),t([o("end")],m.prototype,"writeEnd",null),t([n({readOnly:!0,json:{read:!1}})],m.prototype,"isAllTime",null),t([n({readOnly:!0,json:{read:!1}})],m.prototype,"isEmpty",null),t([n({type:Date,json:{write:{allowNull:!0}}})],m.prototype,"start",void 0),t([i("start")],m.prototype,"readStart",null),t([o("start")],m.prototype,"writeStart",null),m=u=t([l("esri.time.TimeExtent")],m);const p=new m,d=new m({start:void 0,end:void 0});export{m as default};
|