POST
|
Thanks Noah! We use this a lot. When can we expect resolution to this?
... View more
05-10-2021
07:01 AM
|
0
|
0
|
6024
|
POST
|
Hi Noah, Please look at the screenshot that I'm sharing. Topmost symbol is chopped initially but gets better after zoom-in/zoom-out. Screenshot is the output from your codepen sample. This is the same issue as FeatureLayer symbol cut off after change of attrib... - Esri Community
... View more
05-06-2021
06:16 AM
|
0
|
2
|
6044
|
POST
|
Hi, This is happening in 4.19 version as well. Any resolution? You can find a sample in Images chopped when using Class Breaks Renderer / ... - Esri Community. Thanks!
... View more
04-30-2021
07:42 AM
|
0
|
1
|
1070
|
POST
|
Hi, I'm trying to display graphics on a client side feature layer using class-breaks renderer and picture-marker symbol. Symbols (or images) are getting chopped. Does anyone know why? Thanks! Following is the sample code: <html> <head> <meta charset="utf-8" /> <meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no" /> <title>Add or remove graphics from a FeatureLayer | Sample | ArcGIS API for JavaScript 4.19</title> <link rel="stylesheet" href="https://js.arcgis.com/4.19/esri/themes/light/main.css" /> <script src="https://js.arcgis.com/4.19/"></script> <style> html, body, #viewDiv { padding: 0; margin: 0; height: 100%; width: 100%; } #add { margin-bottom: 5px; } #actions { padding: 5px; } button:disabled { opacity: 0.4; -moz-opacity: 0.4; /* Firefox and Mozilla browsers */ -webkit-opacity: 0.4; /* Safari */ cursor: default; } </style> <script> require([ "esri/Map", "esri/views/MapView", "esri/Basemap", "esri/layers/VectorTileLayer", "esri/layers/FeatureLayer", "esri/Graphic", "esri/widgets/Legend" ], function( Map, MapView, Basemap, VectorTileLayer, FeatureLayer, Graphic, Legend ) { // create map using custom basemap from ArcGIS Online const map = new Map({ basemap: new Basemap({ baseLayers: [ new VectorTileLayer({ portalItem: {id: "474f0cb226884dd68f707ab0f2f1aa10"} }) ], referenceLayers: [ new VectorTileLayer({ portalItem: {id: "1768e8369a214dfab4e2167d5c5f2454"} }) ] }) }); const view = new MapView({ container: "viewDiv", map: map, zoom: 3, center: [-122.18, 37.49] // longitude, latitude }); // create empty FeatureLayer const monumentLayer = new FeatureLayer({ // create an instance of esri/layers/support/Field for each field object title: "National Monuments", fields: [ { name: "ObjectID", alias: "ObjectID", type: "oid" }, { name: "Name", alias: "Name", type: "string" }, { name: "Type", alias: "Type", type: "string" }, { name: "Count", alias: "Count", type: "integer" } ], objectIdField: "ObjectID", geometryType: "point", spatialReference: { wkid: 4326 }, source: [], // adding an empty feature collection renderer: { type: "class-breaks", // autocasts as new ClassBreaksRenderer() field: "count", // other properties set in step number 2 classBreakInfos: [ { minValue: 0, maxValue: 100, symbol: { type: "picture-marker", // autocasts as new SimpleFillSymbol() url: "https://static.arcgis.com/images/Symbols/Shapes/BlackStarLargeB.png", height: "30px", width: "30px" }, label: "< 35%" // label for symbol in legend }, { minValue: 101, maxValue: 200, symbol: { type: "picture-marker", // autocasts as new SimpleFillSymbol() url: "https://static.arcgis.com/images/Symbols/Shapes/BlackStarLargeB.png", height: "40px", width: "40px" }, label: "35 - 50%" // label for symbol in legend }, { minValue: 201, maxValue: 500, symbol: { type: "picture-marker", // autocasts as new SimpleFillSymbol() url: "https://static.arcgis.com/images/Symbols/Shapes/BlackStarLargeB.png", height: "50px", width: "50px" }, label: "50 - 75%" // label for symbol in legend }, { minValue: 501, maxValue: 1000, symbol: { type: "picture-marker", // autocasts as new SimpleFillSymbol() url: "https://static.arcgis.com/images/Symbols/Shapes/BlackStarLargeB.png", height: "60px", width: "60px" }, label: "> 75%" // label for symbol in legend } ] } , popupTemplate: { title: "{Name}:{Count}" } }); map.add(monumentLayer); // add legend const legend = new Legend({ view: view }); view.ui.add(legend, "bottom-left"); // add buttons to the mapView view.ui.add(document.getElementById("actions"), "top-right"); const addBtn = document.getElementById("add"); const removeBtn = document.getElementById("remove"); addBtn.addEventListener("click", addFeatures); removeBtn.addEventListener("click", removeFeatures); // check if features have already been added to determine disabled state of buttons monumentLayer.queryFeatures().then(function(results){ if (results.features.length === 0){ addBtn.disabled = false; removeBtn.disabled = true; } else { addBtn.disabled = true; removeBtn.disabled = false; } }); // fires when "Add Features" button is clicked function addFeatures(){ // data to be added to the map const data = [ { LATITUDE: 32.6735, LONGITUDE: -117.2425, TYPE: "National Monument", NAME: "Cabrillo National Monument", COUNT: 100 }, { LATITUDE: 32.6935, LONGITUDE: -117.2925, TYPE: "National Monument", NAME: "Cabrillo National Monument", COUNT: 110 }, { LATITUDE: 35.2234, LONGITUDE: -118.5590, TYPE: "National Monument", NAME: "Cesar E. Chavez National Monument", COUNT: 200 }, { LATITUDE: 35.9234, LONGITUDE: -118.9590, TYPE: "National Monument", NAME: "Cesar E. Chavez National Monument", COUNT: 200 }, { LATITUDE: 37.6251, LONGITUDE: -119.0850, TYPE: "National Monument", NAME: "Devils Postpile National Monument", COUNT: 300 }, { LATITUDE: 35.2915, LONGITUDE: -115.0935, TYPE: "National Monument", NAME: "Castle Mountains National Monument", COUNT: 400 }, { LATITUDE: 41.7588, LONGITUDE: -121.5267, TYPE: "National Monument", NAME: "Lava Beds National Monument", COUNT: 500 }, { LATITUDE: 37.8970, LONGITUDE: -122.5811, TYPE: "National Monument", NAME: "Muir Woods National Monument", COUNT: 600 }, { LATITUDE: 41.8868, LONGITUDE: -121.3717, TYPE: "National Monument", NAME: "Tule Lake National Monument", COUNT: 700 } ]; // create an array of graphics based on the data above var graphics = []; var graphic; for (var i=0; i<data.length; i++){ graphic = new Graphic({ geometry: { type: "point", latitude: data[i].LATITUDE, longitude: data[i].LONGITUDE }, attributes: data[i] }); graphics.push(graphic); } // addEdits object tells applyEdits that you want to add the features const addEdits = { addFeatures: graphics }; // apply the edits to the layer applyEditsToLayer(addEdits); } // fires when "Remove Features" button clicked function removeFeatures(){ // query for the features you want to remove monumentLayer.queryFeatures().then(function(results){ // edits object tells apply edits that you want to delete the features const deleteEdits = { deleteFeatures: results.features }; // apply edits to the layer applyEditsToLayer(deleteEdits); }); } function applyEditsToLayer(edits) { monumentLayer .applyEdits(edits) .then(function(results) { // if edits were removed if (results.deleteFeatureResults.length > 0){ console.log( results.deleteFeatureResults.length, "features have been removed" ); addBtn.disabled = false; removeBtn.disabled = true; } // if features were added - call queryFeatures to return // newly added graphics if (results.addFeatureResults.length > 0){ var objectIds = []; results.addFeatureResults.forEach(function(item) { objectIds.push(item.objectId); }); // query the newly added features from the layer monumentLayer .queryFeatures({ objectIds: objectIds }) .then(function(results){ console.log( results.features.length, "features have been added." ); addBtn.disabled = true; removeBtn.disabled = false; }) } }) .catch(function(error) { console.log(error); }); } }); </script> </head> <body> <div id="viewDiv"></div> <div id="actions" class="esri-widget"> <button class="esri-button" id="add">Add 7 Features</button> <button class="esri-button" id="remove">Remove 7 Features</button> </div> </body> </html>
... View more
04-29-2021
12:14 PM
|
0
|
10
|
6293
|
POST
|
Hi Sarah, When I do AddToDefinition on feature service created in STBDS with "supportsLod":true in "advancedQueryCapabilities", the created feature layer has the setting to false. What is the correct way to set Lod? Following is a portion of my AddToDefinition: { "layers": [ { "allowGeometryUpdates": false, "capabilities": "Create,Editing,Uploads,Query,Update,Delete,Extract", ... "advancedQueryCapabilities":{ ... "supportsLod":true, ... }, "lodInfos": [...], ... ] } --Thanks
... View more
01-27-2021
03:53 PM
|
0
|
0
|
2670
|
POST
|
Hi Noah, I was able to reproduce the issue by using angular-esri-webpack sample. This is only happening in production(ng build --prod), not development. I made the following changes to the sample: 1. remove "devtool" option for production from extra-webpack-config.js const ArcGISPlugin = require('@arcgis/webpack-plugin'); module.exports = { plugins: [new ArcGISPlugin()], node: { process: false, global: false, fs: "empty" } //,devtool: 'eval' } 2. Replaced the code in esri-map.component.ts initializeMap() method with this: async initializeMap() { const DEFAULT_WORKER_URL = "https://js.arcgis.com/4.15/"; const DEFAULT_LOADER_URL = `${DEFAULT_WORKER_URL}dojo/dojo-lite.js`; esriConfig.workers.loaderUrl = DEFAULT_LOADER_URL; esriConfig.workers.loaderConfig = { baseUrl: `${DEFAULT_WORKER_URL}dojo`, packages: [ { name: "esri", location: `${DEFAULT_WORKER_URL}esri` }, { name: "dojo", location: `${DEFAULT_WORKER_URL}dojo` }, { name: "dojox", location: `${DEFAULT_WORKER_URL}dojox` }, { name: "dstore", location: `${DEFAULT_WORKER_URL}dstore` }, { name: "moment", location: `${DEFAULT_WORKER_URL}moment` }, { name: "@dojo", location: `${DEFAULT_WORKER_URL}@dojo` }, { name: "cldrjs", location: `${DEFAULT_WORKER_URL}cldrjs`, main: "dist/cldr" }, { name: "globalize", location: `${DEFAULT_WORKER_URL}globalize`, main: "dist/globalize" }, { name: "maquette", location: `${DEFAULT_WORKER_URL}maquette`, main: "dist/maquette.umd" }, { name: "maquette-css-transitions", location: `${DEFAULT_WORKER_URL}maquette-css-transitions`, main: "dist/maquette-css-transitions.umd" }, { name: "maquette-jsx", location: `${DEFAULT_WORKER_URL}maquette-jsx`, main: "dist/maquette-jsx.umd" }, { name: "tslib", location: `${DEFAULT_WORKER_URL}tslib`, main: "tslib" } ] }; // Configure the Map const mapProperties = { basemap: this._basemap }; const map = new Map(mapProperties); const citiesRenderer = { type: "simple", // autocasts as new SimpleRenderer() symbol: { type: "simple-marker", // autocasts as new SimpleMarkerSymbol() size: 5, color: [0, 244, 255, 1] } }; const featureReduction: any = { type: "cluster", clusterRadius: "100px", popupTemplate: { // cluster_count is an aggregate field indicating the number // of features summarized by the cluster content: "This cluster represents {cluster_count} earthquakes." }, // You should adjust the clusterMinSize to properly fit labels clusterMinSize: "24px", clusterMaxSize: "60px", labelingInfo: [{ // turn off deconfliction to ensure all clusters are labeled deconflictionStrategy: "none", labelExpressionInfo: { expression: "check: Text($feature.cluster_count, '#,###')" }, symbol: { type: "text", color: "#004a5d", font: { weight: "bold", family: "Noto Sans", size: "12px" } }, labelPlacement: "center-center", }] } const citiesLayer = new FeatureLayer({ url: "https://services.arcgis.com/V6ZHFr6zdgNZuVG0/arcgis/rest/services/WorldCities/FeatureServer/0", renderer: citiesRenderer as any, definitionExpression: "adm = 'United States of America'", featureReduction: featureReduction }); map.add(citiesLayer); // Initialize the MapView const mapViewProperties = { container: this.mapViewEl.nativeElement, center: this._center, zoom: this._zoom, map: map }; this._view = new MapView(mapViewProperties); // wait for the map to load await this._view.when(); return this._view; } After these changes, the sample works fine in development (ng serve --open). Webgl errors show up after building (ng build --prod) and then opening the sample in Chrome/Edge browser after hosting the app in IIS. Thanks
... View more
01-21-2021
12:53 PM
|
0
|
1
|
1576
|
POST
|
Hi, I'm trying to do point clustering as in the sample. I get the following errors in the console: WebGL: INVALID_ENUM: texImage2D: invalid type WebGL: INVALID_ENUM: texSubImage2D: invalid type [.WebGL-000002347B9A8180]RENDER WARNING: texture bound to texture unit 3 is not renderable. It might be non-power-of-2 or have incompatible texture filtering (maybe)? This is what I set for FeatureLayer featureReduction (unique value renderer): { type: "cluster", clusterRadius: 100, clusterMinSize: "20px", clusterMaxSize: "50px", popupTemplate: { content: "This cluster represents {cluster_count} features.", fieldInfos: [ { fieldName: "cluster_count", format: { places: 0, digitSeparator: true } } ] }, labelingInfo: [{ deconflictionStrategy: "none", labelExpressionInfo: { expression: "Text($feature.cluster_count, '#,####')" }, symbol: { type: "text", color: "#004a5d", font: { weight: "bold", family: "Noto Sans", size: "12px" } }, labelPlacement: "center-center" }] } Does anyone know why? Thanks!
... View more
01-11-2021
02:33 PM
|
0
|
5
|
1616
|
POST
|
I'm getting the same response from https://tool-online.com/en/coordinate-converter.php# -Thanks
... View more
12-04-2020
12:44 PM
|
0
|
1
|
795
|
POST
|
Hi Dan, I tried this instead: point1 = {"spatialReference":{"wkid":3857},"x":-27763769.230105422,"y":-6212655.210572942} let point2 = webMercatorUtils.project(point1, { wkid: 4326 }); point2 : {"spatialReference":{"wkid":4326},"x":110.5938175582902,"y":-48.63203914410154} let point3 = webMercatorUtils.project(point2, { wkid: 3857 }); point3: {"spatialReference":{"latestWkid":3857,"wkid":102100},"x":12311247.455472855,"y":-6212655.210572806} Does that address datum? Thanks!
... View more
12-04-2020
08:08 AM
|
0
|
0
|
805
|
POST
|
Hi, Using WebMercatorUtils to convert a point from webmercator to geographic and then back to webmercator doesn't give the original value back. Any ideas why? point1: {x: -27763769.230105422, y: -6212655.210572942} webMercatorUtils.webMercatorToGeographic() on point1 returns point2 point2: {x: 110.5938175582902, y: -48.63203914410154} webMercatorUtils.geographicToWebMercator() on point2 returns point3 point3: {x: 12311247.455472855, y: -6212655.210572806} I was hoping point1 and point3 to be same but that doesn't seem to be the case. Thanks!
... View more
12-03-2020
02:32 PM
|
0
|
5
|
850
|
POST
|
How can we reload a portal hosted feature layer to reflect changes to its time settings on portal? I tried removing it from the map and adding it back but that didn't do it.
... View more
11-18-2020
07:15 AM
|
0
|
0
|
323
|
POST
|
When is the FeatureTable (version 4.15) widget expected to be out of beta and released for use?
... View more
06-18-2020
01:22 PM
|
0
|
2
|
446
|
POST
|
Hi, When is the FeatureTable(ver. 4.15) widget expected to be out of beta and released for use? Thanks!
... View more
06-18-2020
01:17 PM
|
0
|
1
|
449
|
Online Status |
Offline
|
Date Last Visited |
08-17-2022
12:51 PM
|