Skip to content

Commit

Permalink
feat(poi): Add POI only search flag
Browse files Browse the repository at this point in the history
  • Loading branch information
trevorgerhardt committed Feb 27, 2019
1 parent 95a6f7e commit a17a85a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions src/components/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,7 @@ export default class Application extends Component {
onChangeStart={this._setStartWithFeature}
pointsOfInterest={p.pointsOfInterestOptions}
reverseGeocode={p.reverseGeocode}
searchPoiOnly={p.searchPoiOnly}
selectedTimeCutoff={p.timeCutoff}
start={p.start}
updateEnd={p.updateEnd}
Expand Down
5 changes: 2 additions & 3 deletions src/components/form.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,9 @@ export default class Form extends React.PureComponent {
const p = this.props
const poi = p.pointsOfInterest || []
const filterPoi = cfo(poi) // memoized filtering function
const showPoiSelect = poi.length > 0
return (
<React.Fragment>
{showPoiSelect
{p.searchPoiOnly
? <Select
clearable={false}
filterOptions={filterPoi}
Expand All @@ -65,7 +64,7 @@ export default class Form extends React.PureComponent {
/>}
{p.start &&
<React.Fragment>
{showPoiSelect
{p.searchPoiOnly
? <Select
filterOptions={filterPoi}
options={poi}
Expand Down
1 change: 1 addition & 0 deletions src/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,7 @@ table.CardContent td:first-of-type {
font-size: 0.75rem;
line-height: 1rem;
font-weight: bold;
white-space: nowrap;
}

.Card .increase {
Expand Down

0 comments on commit a17a85a

Please sign in to comment.