-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix feature zoom #154
Fix feature zoom #154
Conversation
src/demo-app/app/app.component.ts
Outdated
@@ -98,6 +98,11 @@ export class AppComponent implements OnInit { | |||
const features: Feature[] = results.features; | |||
if (features[0]) { | |||
this.featureService.updateFeatures(features, features[0].source); | |||
const a = features.filter(feature => | |||
feature.source === 'Entités cliquées' || |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't use translation strings
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
@@ -61,7 +61,9 @@ export class OverlayDirective implements OnInit, OnDestroy { | |||
|
|||
this.map.addOverlay(olFeature); | |||
}, this); | |||
|
|||
if (features[0].source === 'Entités cliquées' || features[0].source === 'Clicked Feature') { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't use translation strings
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
New cleaner behavior. If you select a feature in the feature list, if the feature extent intersects the map extent, highlight feature only. If feature extents do not intersects, then move to . |
highlighting result in the feature list. But do not zoom on. action = 'none'