Skip to content

Commit

Permalink
Fixed all the issues I could find with highlighting
Browse files Browse the repository at this point in the history
  • Loading branch information
dhochbaum-dcp committed May 8, 2024
1 parent 1036aa2 commit 0cd095d
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
9 changes: 9 additions & 0 deletions app/controllers/map-feature.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
import Controller from '@ember/controller';
import { inject as service } from '@ember/service';
import { action } from '@ember/object';

export default class MapFeatureController extends Controller {
@service mainMap;

queryParams = [
{
search: {
Expand All @@ -11,4 +15,9 @@ export default class MapFeatureController extends Controller {
];

shouldRefresh = false;

@action
clearComparison() {
this.set('mainMap.comparisonSelected', null);
}
}
1 change: 0 additions & 1 deletion app/routes/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ export default Route.extend({
const { mainMap } = this;
mainMap.setProperties({
selected: null,
comparisonSelected: null,
shouldFitBounds: false,
});

Expand Down
2 changes: 2 additions & 0 deletions app/services/main-map.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ export default class MainMapService extends Service {
// used to determine how to zoom
selected = null;

comparisonSelected = null;

currentMeasurement = null;

drawMode = null;
Expand Down
2 changes: 1 addition & 1 deletion app/templates/map-feature.hbs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div class="content-close-button-container">
<LinkTo @route="index" class="close-button" data-test-button="close-route">
<LinkTo @route="index" class="close-button" data-test-button="close-route" onClick={{action "clearComparison"}}>
<span aria-hidden="true">
&times;
</span>
Expand Down

0 comments on commit 0cd095d

Please sign in to comment.