Skip to content

Commit

Permalink
Merge pull request #238 from Esri/sketch-updates
Browse files Browse the repository at this point in the history
Sketch updates
  • Loading branch information
jmhauck authored May 21, 2023
2 parents 95168ce + a7b4f1d commit ff7607d
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
12 changes: 12 additions & 0 deletions src/components/map-draw-tools/map-draw-tools.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,18 @@ export class MapDrawTools {
this._init();
}

/**
* StencilJS: Called every time the component is disconnected from the DOM
*
* @returns void
*/
disconnectedCallback(): void {
// cancel any existing create operations
this._sketchWidget.cancel();
// clear any current temp sketch
this._clearSketch();
}

/**
* Renders the component.
*/
Expand Down
4 changes: 3 additions & 1 deletion src/components/public-notification/public-notification.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -761,7 +761,9 @@ export class PublicNotification {
// REFINE will only ever be 1 ISelectionSet
Object.keys(cur.refineInfos).forEach(k => {
const refineIds: IRefineIds = cur.refineInfos[k];
this._updateIds(k, refineIds.layerView, refineIds.addIds, prev);
if (refineIds.addIds.length > 0) {
this._updateIds(k, refineIds.layerView, refineIds.addIds, prev);
}
});
}
}
Expand Down

0 comments on commit ff7607d

Please sign in to comment.