{"version":3,"sources":["webpack:///./js/src/common/shapes/SearchState.js","webpack:///./js/src/appheader/MultipleResults.jsx","webpack:///./js/src/appheader/index.jsx","webpack:///./js/src/common/geocoder/utils.js","webpack:///./js/src/common/geocoder/components/ErrorBox.jsx","webpack:///./js/src/common/geocoder/components/LocationList.jsx","webpack:///./js/src/common/geocoder/components/SearchIndicator.jsx","webpack:///./js/src/common/geocoder/components/index.jsx","webpack:///./js/src/common/geocoder/index.jsx"],"names":["prop_types__WEBPACK_IMPORTED_MODULE_0__","__webpack_require__","shape","url","string","searchType","instance","isFetching","bool","errorMessage","locations","arrayOf","preprocessResults","func","MultipleResults","_ref","data","react_default","a","createElement","className","map","_ref2","_ref2$Parcel","Parcel","Address","Owner1","ParcelID","key","react_router_es","to","createParcelDetailsRouteFromParcelID","concat","defaultProps","propTypes","number","isRequired","popupStyles","Object","freeze","overlayStyles","zIndex","contentStyles","position","top","right","width","maxHeight","overflow","maxWidth","initialState","showNoResultsPopup","showMultipleResultsPopup","AppHeader","_this","setState","state","assign","clearSearch","props","callback","arguments","length","undefined","resetSearch","noop","performSearch","v","updateSearchQuery","Component","prevProps","prevError","error","prevData","prevPathname","location","pathname","_this$props","this","push","router","isEqual","resetComponentState","openNoResultsPopup","openMultipleResultsPopup","get","lng","lat","createMapRouteFromLatLng","parcelID","_this$props2","query","fetching","_this$state","searchingIndicator","id","Fragment","pwd_unitybar_min_default","theme","currentAppName","appNameClickHandler","homeRoute","hasMapAction","mapActionHandler","mapRoute","mapActionTitle","hasHelpAction","helpActionHandler","helpRoute","helpActionTitle","hasSearch","isSearching","searchChangeHandler","handleUpdateQuery","searchSubmitHandler","handlePerformSearch","searchBoxValue","parcelViewerUrl","showCreditsExplorerLink","creditsExplorerUrl","retrofitMapUrl","showRetrofitMapLink","showRetrofitCampaignLink","currentPath","reactjs_popup_es","open","closeOnDocumentClick","onClose","closeNoResultsPopup","overlayStyle","contentStyle","role","type","onClick","aria-hidden","closeMultipleResultsPopup","navigateToDetails","Match","Type","Value","X","Y","hot","connect","_ref$appheader","appheader","unitybar","dispatch","updateUnityBarSearchQuery","performUnityBarGeocoderSearch","clearGeocoderSearch","resetGeocoder","withRouter","isSearchActive","searchState","d","__webpack_exports__","ErrorBox","LocationList","locationItems","node","i","locationDisplayName","selectLocation","displayName","parcelDetailsRoute","includes","CAP_PAGE","WALKTHROUGH_LIST","renderLocation","suggestion","createSuggestion","object","SearchIndicator","isAlert","icon","Geocoder","components_classCallCheck","components_getPrototypeOf","call","searchQuery","onKeyDown","bind","components_assertThisInitialized","search","handleInputChange","queryStringSearch","runGeocoderSearch","keyCode","_ref3","target","value","isActive","_ref4","locationList","LocationList_LocationList","isMultipleLocations","searchIndicator","SearchIndicator_SearchIndicator","errorBox","ErrorBox_ErrorBox","name","placeholder","onChange","GeocoderContainer","selectLocationAction","getSearchUrl","geocoderActions","components_Geocoder","input","completeSearch","GEOCODER_SEARCH","SearchState","identity","objectOf","bindActionCreators"],"mappings":"0FAAA,IAAAA,EAAAC,EAAA,KAEeC,oBAAM,CACjBC,IAAKC,SACLC,WAAYD,SACZE,SAAUF,SACVG,WAAYC,OACZC,aAAcL,SACdM,UAAWC,kBAAQP,UACnBQ,kBAAmBC,mMCHR,SAASC,EAATC,GAAmC,IAARC,EAAQD,EAARC,KACtC,OAAKA,EAKDC,EAAAC,EAAAC,cAAA,OAAKC,UAAU,oBACXH,EAAAC,EAAAC,cAAA,KAAGC,UAAU,gCAAb,4DAGAH,EAAAC,EAAAC,cAAA,KAAGC,UAAU,gCAAb,8BAGAH,EAAAC,EAAAC,cAAA,MAAIC,UAAU,yBACTJ,EAAKK,IAAI,SAAAC,GAAA,IAAAC,EAAAD,EAAGE,OAAUC,EAAbF,EAAaE,QAASC,EAAtBH,EAAsBG,OAAQC,EAA9BJ,EAA8BI,SAA9B,OACNV,EAAAC,EAAAC,cAAA,MAAIS,IAAKD,GACLV,EAAAC,EAAAC,cAACU,EAAA,EAAD,CACIC,GAAIC,YAAqCJ,IAD7C,G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B9B,SAAUF,SAAOgC,WACjB0K,aAAcjM,OAAKuB,WACnB2K,gBAAiBO,mBAASzM,QAAMuB,WAChCsH,YAAa0D,IAAYhL,WACzBxB,kBAAmBC,OACnB6K,kBAAmBtL,UAwBR2I,gBArBf,SAAyBvF,GACrB,MAAO,CACHkG,YAAalG,EAAMgI,SAI3B,SAA4BrC,EAAUxF,GAAO,IACjCkJ,EAAyBlJ,EAAzBkJ,qBACR,MAAO,CACHE,gBAAiBQ,YACb,CACI5B,sBACAuB,mBACAxJ,gBACAmJ,wBAEJ1D,KAKGJ,CAGb6D","file":"pwd.parcelviewer.1.bundle.0cc62d01ee8bb1ca61a3.js","sourcesContent":["import { string, bool, shape, func, arrayOf } from 'prop-types';\n\nexport default shape({\n url: string,\n searchType: string,\n instance: string,\n isFetching: bool,\n errorMessage: string,\n locations: arrayOf(string),\n preprocessResults: func,\n});\n","import React from 'react';\nimport { arrayOf, number, shape } from 'prop-types';\nimport { Link } from 'react-router';\n\nimport { createParcelDetailsRouteFromParcelID } from 'common/routes';\n\nexport default function MultipleResults({ data }) {\n if (!data) {\n return null;\n }\n\n return (\n
\n

\n We could not find a single exact match for that address.\n

\n

\n Did you mean one of these?\n

\n \n
\n );\n}\n\nMultipleResults.defaultProps = {\n data: null,\n};\n\nMultipleResults.propTypes = {\n data: arrayOf(\n shape({\n Parcel: shape({\n ParcelID: number.isRequired,\n }).isRequired,\n }).isRequired,\n ),\n};\n","import React, { Component } from 'react';\nimport { arrayOf, bool, func, number, shape, string } from 'prop-types';\nimport UnityBar from 'pwd-unitybar';\nimport { connect } from 'react-redux';\nimport { withRouter } from 'react-router';\nimport isEqual from 'lodash/isEqual';\nimport get from 'lodash/get';\nimport noop from 'lodash/noop';\nimport Popup from 'reactjs-popup';\nimport { hot } from 'react-hot-loader/root';\n\nimport {\n homeRoute,\n mapRoute,\n helpRoute,\n createParcelDetailsRouteFromParcelID,\n createMapRouteFromLatLng,\n} from 'common/routes';\n\nimport {\n updateUnityBarSearchQuery,\n performUnityBarGeocoderSearch,\n clearGeocoderSearch,\n resetGeocoder,\n} from './actions';\n\nimport MultipleResults from './MultipleResults';\n\nconst popupStyles = Object.freeze({\n overlayStyles: Object.freeze({\n zIndex: 2001,\n }),\n contentStyles: Object.freeze({\n position: 'absolute',\n top: '50px',\n right: '5px',\n width: '520px',\n maxHeight: '80%',\n overflow: 'auto',\n maxWidth: 'calc(100% - 10px)',\n }),\n});\n\nconst initialState = Object.freeze({\n showNoResultsPopup: false,\n showMultipleResultsPopup: false,\n});\n\nconst INTERSECTION = 'Intersection';\n\nclass AppHeader extends Component {\n state = initialState;\n\n componentDidUpdate(prevProps) {\n const {\n error: prevError,\n data: prevData,\n location: { pathname: prevPathname },\n } = prevProps;\n\n const {\n data,\n error,\n router: { push },\n location: { pathname },\n } = this.props;\n\n if (!isEqual(prevPathname, pathname)) {\n return this.resetComponentState();\n }\n\n if (error && !prevError) {\n return this.openNoResultsPopup();\n }\n\n if (isEqual(data, prevData)) {\n return null;\n }\n\n if (!data) {\n return null;\n }\n\n if (!data.length) {\n return this.openNoResultsPopup();\n }\n\n if (data.length > 1) {\n return this.openMultipleResultsPopup();\n }\n\n const matchType = get(data, '[0].Match.Value', null);\n\n if (matchType === INTERSECTION) {\n const lng = get(data, '[0].X', null);\n const lat = get(data, '[0].Y', null);\n\n return this.resetComponentState(() =>\n push(createMapRouteFromLatLng(lat, lng)),\n );\n }\n\n const parcelID = get(data, '[0].Parcel.ParcelID', null);\n\n return this.resetComponentState(() =>\n push(createParcelDetailsRouteFromParcelID(parcelID)),\n );\n }\n\n componentWillUnmount() {\n const { resetSearch } = this.props;\n return resetSearch();\n }\n\n openNoResultsPopup = () =>\n this.setState(state =>\n Object.assign({}, state, {\n showNoResultsPopup: true,\n showMultipleResultsPopup: false,\n }),\n );\n\n openMultipleResultsPopup = () =>\n this.setState(state =>\n Object.assign({}, state, {\n showNoResultsPopup: false,\n showMultipleResultsPopup: true,\n }),\n );\n\n closeNoResultsPopup = () => {\n const { clearSearch } = this.props;\n\n return this.setState(\n state =>\n Object.assign({}, state, {\n showNoResultsPopup: false,\n }),\n clearSearch,\n );\n };\n\n closeMultipleResultsPopup = () => {\n const { clearSearch } = this.props;\n\n return this.setState(\n state =>\n Object.assign({}, state, {\n showMultipleResultsPopup: false,\n }),\n clearSearch,\n );\n };\n\n resetComponentState = (callback = null) =>\n this.setState(\n () => initialState,\n () => {\n const { resetSearch } = this.props;\n\n resetSearch();\n\n return callback ? callback() : noop();\n },\n );\n\n handlePerformSearch = () => {\n const { performSearch } = this.props;\n return this.setState(\n state =>\n Object.assign({}, state, {\n showNoResultsPopup: false,\n showMultipleResultsPopup: false,\n }),\n performSearch,\n );\n };\n\n handleUpdateQuery = v => {\n const { updateSearchQuery } = this.props;\n updateSearchQuery(v);\n return this.setState(state =>\n Object.assign({}, state, {\n showNoResultsPopup: false,\n showMultipleResultsPopup: false,\n }),\n );\n };\n\n render() {\n const {\n query,\n fetching,\n data,\n router: { push },\n location: { pathname },\n } = this.props;\n\n const { showNoResultsPopup, showMultipleResultsPopup } = this.state;\n\n const searchingIndicator = (\n \n \n \n );\n return (\n <>\n push(homeRoute)}\n hasMapAction\n mapActionHandler={() => push(mapRoute)}\n mapActionTitle=\"Explore the map\"\n hasHelpAction\n helpActionHandler={() => push(helpRoute)}\n helpActionTitle=\"Learn about stormwater charges\"\n hasSearch\n isSearching={fetching}\n searchChangeHandler={this.handleUpdateQuery}\n searchSubmitHandler={this.handlePerformSearch}\n searchBoxValue={query}\n searchingIndicator={searchingIndicator}\n parcelViewerUrl=\"https://stormwater.phila.gov/parcelviewer/\"\n showCreditsExplorerLink\n creditsExplorerUrl=\"https://stormwater.phila.gov/explore/\"\n retrofitMapUrl=\"https://water.phila.gov/stormwater/connect/\"\n showRetrofitMapLink\n showRetrofitCampaignLink\n currentPath={pathname}\n />\n \n
\n \n ×\n Close\n \n

\n We could not find a match for that address. Please\n try searching for a different address.\n

\n
\n \n \n \n \n \n );\n }\n}\n\nAppHeader.defaultProps = {\n error: null,\n data: null,\n};\n\nAppHeader.propTypes = {\n router: shape({\n push: func.isRequired,\n }).isRequired,\n location: shape({\n pathname: string.isRequired,\n }).isRequired,\n query: string.isRequired,\n fetching: bool.isRequired,\n error: arrayOf(string),\n updateSearchQuery: func.isRequired,\n performSearch: func.isRequired,\n clearSearch: func.isRequired,\n resetSearch: func.isRequired,\n data: arrayOf(\n shape({\n Parcel: shape({\n ParcelID: number,\n }),\n Match: shape({\n Type: string,\n Value: string,\n }),\n X: number,\n Y: number,\n }),\n ),\n};\n\nfunction mapStateToProps({\n appheader: {\n unitybar: { query },\n fetching,\n error,\n data,\n },\n}) {\n return {\n query,\n fetching,\n error,\n data,\n };\n}\n\nfunction mapDispatchToProps(dispatch) {\n return {\n updateSearchQuery: v => dispatch(updateUnityBarSearchQuery(v)),\n performSearch: () => dispatch(performUnityBarGeocoderSearch()),\n clearSearch: () => dispatch(clearGeocoderSearch()),\n resetSearch: () => dispatch(resetGeocoder()),\n };\n}\n\nexport default hot(\n connect(\n mapStateToProps,\n mapDispatchToProps,\n )(withRouter(AppHeader)),\n);\n","// eslint-disable-next-line import/prefer-default-export\nexport function isSearchActive(searchState, searchType, instance) {\n return (\n searchState.searchType === searchType &&\n searchState.instance === instance\n );\n}\n","/* eslint react/prefer-stateless-function:0 */\n\nimport React, { Component } from 'react';\nimport { func, string } from 'prop-types';\n\nexport default class ErrorBox extends Component {\n render() {\n const { clearSearch, errorMessage } = this.props;\n\n return (\n
\n
\n \n ×\n Close\n \n
{errorMessage}
\n
\n
\n );\n }\n}\n\nErrorBox.propTypes = {\n clearSearch: func.isRequired,\n errorMessage: string.isRequired,\n};\n","/* eslint-disable class-methods-use-this */\n/* eslint-disable react/no-array-index-key */\nimport React, { Component } from 'react';\nimport { func, arrayOf, object, string } from 'prop-types';\nimport { Link } from 'react-router';\nimport includes from 'lodash/includes';\n\nimport { CAP_PAGE, WALKTHROUGH_LIST } from 'common/constants';\nimport { createParcelDetailsRouteFromParcelID } from 'common/routes';\n\nexport default class LocationList extends Component {\n createSuggestion = locationItems => {\n if (locationItems.length > 1) {\n return (\n
\n
Did you mean one of these?
\n
    \n {locationItems.map((node, i) => (\n
  • {node}
  • \n ))}\n
\n
\n );\n }\n\n return '';\n };\n\n renderLocation = location => {\n const { locationDisplayName, selectLocation, instance } = this.props;\n\n const displayName = locationDisplayName(location);\n const parcelDetailsRoute = createParcelDetailsRouteFromParcelID(\n location.Parcel.ParcelID,\n );\n\n return includes([CAP_PAGE, WALKTHROUGH_LIST], instance) ? (\n selectLocation(location)}\n type=\"button\"\n className=\"multiple-results-disambiguation-button\"\n >\n {displayName}\n \n ) : (\n {displayName}\n );\n };\n\n render() {\n const { locations, clearSearch } = this.props;\n const locationItems = locations.map(this.renderLocation);\n const suggestion = this.createSuggestion(locationItems);\n return (\n
\n
\n \n ×\n Close\n \n
We could not find a match for that address.
\n {suggestion}\n
\n
\n );\n }\n}\n\nLocationList.propTypes = {\n locations: arrayOf(object).isRequired,\n clearSearch: func.isRequired,\n selectLocation: func.isRequired,\n instance: string.isRequired,\n locationDisplayName: func.isRequired,\n};\n","/* eslint react/prefer-stateless-function:0 */\n\nimport React, { Component } from 'react';\nimport { bool } from 'prop-types';\n\nexport default class SearchIndicator extends Component {\n render() {\n const { isAlert, isFetching } = this.props;\n\n let icon = '';\n\n if (isAlert) {\n icon = ;\n } else if (isFetching) {\n icon = ;\n }\n\n return {icon};\n }\n}\n\nSearchIndicator.propTypes = {\n isFetching: bool.isRequired,\n isAlert: bool.isRequired,\n};\n","/* eslint-disable react/destructuring-assignment */\nimport React, { Component } from 'react';\nimport { func, string } from 'prop-types';\n\nimport SearchState from 'shapes/SearchState';\n\nimport ErrorBox from './ErrorBox';\nimport LocationList from './LocationList';\nimport SearchIndicator from './SearchIndicator';\nimport { isSearchActive } from '../utils';\n\nexport default class Geocoder extends Component {\n constructor(props) {\n super(props);\n this.state = { searchQuery: '' };\n this.onKeyDown = this.onKeyDown.bind(this);\n this.search = this.search.bind(this);\n this.handleInputChange = this.handleInputChange.bind(this);\n }\n\n componentWillReceiveProps({ queryStringSearch: searchQuery }) {\n if (searchQuery && !this.props.queryStringSearch) {\n this.setState({ searchQuery });\n this.props.runGeocoderSearch(searchQuery);\n }\n }\n\n onKeyDown({ keyCode }) {\n if (keyCode === 13) {\n this.search();\n }\n }\n\n handleInputChange({ target: { value: searchQuery } }) {\n this.setState({ searchQuery });\n }\n\n search() {\n this.props.runGeocoderSearch(this.state.searchQuery);\n }\n\n render() {\n const {\n clearSearch,\n locationDisplayName,\n selectLocation,\n instance,\n searchState,\n searchType,\n } = this.props;\n\n const isActive = isSearchActive(searchState, searchType, instance);\n\n const { locationList, isMultipleLocations } =\n isActive &&\n searchState.locations &&\n searchState.locations.length > 1\n ? {\n locationList: (\n \n ),\n isMultipleLocations: true,\n }\n : {\n locationList: '',\n isMultipleLocations: false,\n };\n\n const isAlert =\n isActive && (!!searchState.errorMessage || isMultipleLocations);\n\n const searchIndicator = isActive ? (\n \n ) : null;\n\n const errorBox =\n isActive && searchState.errorMessage ? (\n \n ) : null;\n\n return (\n
\n
\n \n {searchIndicator}\n \n \n \n \n \n
\n {locationList}\n {errorBox}\n
\n );\n }\n}\n\nGeocoder.defaultProps = {\n queryStringSearch: '',\n};\n\nGeocoder.propTypes = {\n runGeocoderSearch: func.isRequired,\n clearSearch: func.isRequired,\n locationDisplayName: func.isRequired,\n selectLocation: func.isRequired,\n instance: string.isRequired,\n searchState: SearchState.isRequired,\n searchType: string.isRequired,\n queryStringSearch: string,\n};\n","import React from 'react';\nimport { func, string, objectOf } from 'prop-types';\nimport { bindActionCreators } from 'redux';\nimport { connect } from 'react-redux';\nimport noop from 'lodash/noop';\nimport identity from 'lodash/identity';\n\nimport SearchState from 'shapes/SearchState';\n\nimport {\n runGeocoderSearch,\n completeSearch,\n clearSearch,\n GEOCODER_SEARCH,\n} from './actions';\nimport Geocoder from './components';\n\nfunction GeocoderContainer(props) {\n const {\n selectLocationAction,\n locationDisplayName,\n getSearchUrl,\n instance,\n searchState,\n preprocessResults,\n geocoderActions,\n queryStringSearch,\n } = props;\n\n function selectLocation(location) {\n geocoderActions.completeSearch(location, instance, GEOCODER_SEARCH);\n geocoderActions.clearSearch();\n geocoderActions.selectLocationAction(location);\n }\n\n return (\n geocoderActions.clearSearch()}\n runGeocoderSearch={input =>\n geocoderActions.runGeocoderSearch(\n getSearchUrl,\n instance,\n input,\n selectLocationAction,\n preprocessResults,\n )\n }\n selectLocationAction={selectLocationAction}\n selectLocation={selectLocation}\n locationDisplayName={locationDisplayName}\n preprocessResults={preprocessResults}\n instance={instance}\n searchState={searchState}\n searchType={GEOCODER_SEARCH}\n queryStringSearch={queryStringSearch}\n />\n );\n}\n\n/*\n selectLocationAction and locationDisplayName are passed in as props\n to customize the GeocoderContainer for a specific application.\n Note that we use the term location instead of parcel since it is more\n generic.\n\n selectLocationAction should be an action creator that takes a location object\n (an application-specific object representing a location) and updates the\n store with the location.\n\n locationDisplayName should be a function that takes a location object and returns\n a name to display in the disambiguation list of locations in the UI.\n*/\n\nGeocoderContainer.defaultProps = {\n selectLocationAction: noop,\n preprocessResults: identity,\n queryStringSearch: '',\n};\n\nGeocoderContainer.propTypes = {\n selectLocationAction: func,\n locationDisplayName: func.isRequired,\n instance: string.isRequired,\n getSearchUrl: func.isRequired,\n geocoderActions: objectOf(func).isRequired,\n searchState: SearchState.isRequired,\n preprocessResults: func,\n queryStringSearch: string,\n};\n\nfunction mapStateToProps(state) {\n return {\n searchState: state.search,\n };\n}\n\nfunction mapDispatchToProps(dispatch, props) {\n const { selectLocationAction } = props;\n return {\n geocoderActions: bindActionCreators(\n {\n runGeocoderSearch,\n completeSearch,\n clearSearch,\n selectLocationAction,\n },\n dispatch,\n ),\n };\n}\n\nexport default connect(\n mapStateToProps,\n mapDispatchToProps,\n)(GeocoderContainer);\n"],"sourceRoot":""}