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aA,IAEfvF,EAAAA,cAAA,OAAKC,UAAU,aACbD,EAAAA,cAAA,MAAIC,UAAU,YAAW,cACxBqF,EAAWvB,KAAI,CAACZ,EAAU0C,IAEvB7F,EAAAA,cAAA,OACEiE,IAAKd,EAAS9C,WAAWqC,KACzBzC,UAAW,GAAG4F,EAAQ,IAAM,GAAK,sBACjC7F,EAAAA,cAAC8F,EAAmB,CAAC3C,SAAUA,EAAUjB,UAAWA,QAK5DlC,EAAAA,cAAA,OAAKC,UAAU,iBACbD,EAAAA,cAAA,MAAIC,UAAU,QAAO,sBACrBD,EAAAA,cAAC4E,EAAiB,CAACC,UAAWA,KAEhC7E,EAAAA,cAACqE,EAAqB,CAACC,eAAgBA,IACvCtE,EAAAA,cAAA,OAAKC,UAAU,iBACbD,EAAAA,cAAA,OAAKC,UAAU,YACZ+B,EAAM0D,QACL1F,EAAAA,cAAA,UAAQC,UAAU,8BAA8B0F,QAASD,GAAQ,SAKrE1F,EAAAA,cAAA,OAAKC,UAAU,wDACbD,EAAAA,cAAA,OAAKC,UAAU,SACZsF,GACCvF,EAAAA,cAAA,UACEC,UAAU,gCACV0F,QAASF,EACTG,SAAUJ,IAAWnF,EAAWR,MAAM,yBAO5C,EC1FVkG,IAAAA,SAAsB,CACpBC,aACF,G","sources":["webpack://housing-hub/./app/javascript/bundles/Waitlists/WaitlistStatusCard.js","webpack://housing-hub/./app/javascript/bundles/Waitlists/WaitlistPageMeta.js","webpack://housing-hub/./app/javascript/bundles/Properties/PropertyBuildingInfo.js","webpack://housing-hub/./app/javascript/bundles/Properties/FullPropertyDetails.js","webpack://housing-hub/./app/javascript/bundles/Properties/PropertyImagesSection.js","webpack://housing-hub/./app/javascript/bundles/Waitlists/WaitlistDocuments.js","webpack://housing-hub/./app/javascript/bundles/WaitlistPage.js","webpack://housing-hub/./app/javascript/packs/application.js"],"sourcesContent":["import React from 'react';\n\nconst WaitlistStatusCard = ({ open, avg_wait_time, avg_wait_time_units }) => {\n return (\n
\n
\n
\n Current Status\n \n {open === true ? 'Open' : 'Closed'}\n \n
\n
\n Estimated Wait\n \n {avg_wait_time || 'N/A'} {avg_wait_time_units}\n \n
\n
\n
\n );\n};\n\nexport default WaitlistStatusCard;\n","import React from 'react';\n\nconst WaitlistPageMeta = ({\n applicantPreferences,\n applicantHouseholdSize,\n attributes\n}) => {\n\n const mappedPreferences = {\n Displaced: 'displaced',\n 'Working Family': 'working_family',\n Disabled: 'disabled',\n 'Victim of Domestic Violence': 'domestic_violence',\n Homeless: 'homeless',\n Elderly: 'senior_citizen',\n 'I require the use of a mobility device': 'mobility_device'\n };\n\n const matchedPreferences = () => {\n\n if (!applicantPreferences) {\n return 'No Preferences';\n }\n const matches = attributes.preferences.reduce((acc, pref) => {\n if (applicantPreferences[mappedPreferences[pref]] === true) {\n acc.push(pref);\n }\n return acc;\n }, []);\n\n if (matches.length === 0) {\n return 'No Preferences';\n }\n return matches.join(', ');\n };\n\n const applicantIncomeLimit = attributes.household_income_limits.find(\n incomeLimit => {\n return incomeLimit.household_size === applicantHouseholdSize;\n }\n );\n\n return (\n
\n
\n

\n Waitlist Type:{' '}\n \n {attributes.waitlist_types.join(', ')}\n \n

\n

\n Bedrooms:{' '}\n \n {attributes.unit_groups.join(', ')}\n \n

\n

\n Applicant Requirements:{' '}\n \n {attributes.applicant_requirements.join(', ')}\n \n

\n

\n Preference Characteristics I Match:{' '}\n {matchedPreferences()}\n

\n

\n Yearly Minimum Income for My Household Size:{' '}\n \n {applicantIncomeLimit &&\n `$${applicantIncomeLimit.income_min.toLocaleString()}`}\n \n

\n

\n Yearly Maximum Income for My Household Size:{' '}\n \n {applicantIncomeLimit &&\n `$${applicantIncomeLimit.income_max.toLocaleString()}`}\n \n

\n
\n
\n

Waitlist Description

\n

{attributes.description}

\n
\n
\n );\n};\n\nexport default WaitlistPageMeta;\n","import React from 'react';\n\nconst PropertyBuildingInfo = props => {\n const { attributes, relationships, locations } = props;\n\n const locationString = relationships.locations.data\n .reduce((acc, loc) => {\n const id = loc.id;\n const locData = locations.find(locationMatch => {\n return locationMatch.id === id;\n });\n acc.push(locData.attributes.short_name);\n return acc;\n }, [])\n .join(', ');\n\n return (\n
\n

{attributes.name}

\n {attributes.scattered_site ? (\n

\n Multiple sites in {locationString}\n

\n ) : (\n

\n {attributes.street_address}\n
\n {attributes.city}, {attributes.state} {attributes.zip_code}\n

\n )}\n

{attributes.website}

\n

\n Building Types:{' '}\n \n {attributes.building_types.join(', ')}\n \n

\n

\n Total Units in Property:{' '}\n {attributes.total_units}\n

\n

\n Bedroom Sizes:{' '}\n \n {attributes.unit_groups.join(', ')}\n \n

\n
\n );\n};\n\nexport default PropertyBuildingInfo;\n","import React from 'react';\nimport PropertyBuildingInfo from './PropertyBuildingInfo';\n\nconst FullPropertyDetails = props => {\n const {\n property: { attributes, relationships },\n locations\n } = props;\n\n const propertyAttributes = {\n accessibility_features: 'Accessibility',\n pets: 'Pets',\n amenities: 'Amenities',\n application_fee: 'Application Fee',\n security_deposit: 'Security Deposit',\n background_checks: 'Background Checks',\n utilities: 'Utilities residents pay'\n };\n\n return (\n
\n
\n \n
\n
\n {Object.keys(propertyAttributes).map(attribute => {\n return (\n

\n {propertyAttributes[attribute]}:{' '}\n {Array.isArray(attributes[attribute]) ? (\n \n {attributes[attribute].length > 0\n ? attributes[attribute].join(', ')\n : `No ${attribute.replace(/_/g, ' ')}`}\n \n ) : (\n \n {attributes[attribute]\n ? `$${attributes[attribute]}`\n : `No ${attribute.replace(/_/g, ' ')}`}\n \n )}\n

\n );\n })}\n
\n
\n );\n};\n\nexport default FullPropertyDetails;\n","import React from 'react';\n\nconst PropertyImagesSection = ({ propertyImages }) => {\n if (propertyImages.length === 0) {\n return null;\n }\n\n return (\n
\n
\n
\n
\n \"property\"\n
\n
\n
\n
\n
\n {propertyImages.slice(1, 5).map(image => {\n return (\n
\n
\n
\n \"property\"\n
\n
\n
\n );\n })}\n
\n
\n
\n );\n};\n\nexport default PropertyImagesSection;\n","import React from 'react';\n\nconst WaitlistDocuments = ({ documents }) => {\n return (\n \n );\n};\n\nexport default WaitlistDocuments;\n","import React from 'react';\nimport WaitlistStatusCard from './Waitlists/WaitlistStatusCard';\nimport WaitlistPageMeta from './Waitlists/WaitlistPageMeta';\nimport FullPropertyDetails from './Properties/FullPropertyDetails';\nimport PropertyImagesSection from './Properties/PropertyImagesSection';\nimport WaitlistDocuments from './Waitlists/WaitlistDocuments';\n\nconst WaitlistPage = props => {\n if (!props.waitlistData.waitlist) {\n return null;\n }\n\n const {\n waitlistData: {\n waitlist: { attributes },\n properties,\n locations,\n propertyImages,\n documents\n },\n applicantId,\n applicantHouseholdSize,\n applicantPreferences,\n joined,\n joinWaitlist,\n goBack\n } = props;\n\n return (\n
\n
\n
\n

{attributes.name}

\n
\n
\n
\n {applicantId && (\n \n Add me to Waitlist\n \n )}\n
\n
\n
\n
\n
\n \n
\n
\n \n
\n

Properties

\n {properties.map((property, index) => {\n return (\n \n \n
\n );\n })}\n
\n
\n

Waitlist Documents

\n \n
\n \n
\n
\n {props.goBack && (\n \n )}\n
\n
\n
\n {applicantId && (\n \n Add me to Waitlist\n \n )}\n
\n
\n
\n \n );\n};\n\nexport default WaitlistPage;\n","// Support component names relative to this directory:\nimport ReactOnRails from 'react-on-rails';\n\nimport WaitlistPage from '../bundles/WaitlistPage';\n\n// This is how react_on_rails can see the HelloWorld in the browser.\nReactOnRails.register({\n WaitlistPage,\n});"],"names":["WaitlistStatusCard","open","avg_wait_time","avg_wait_time_units","React","className","WaitlistPageMeta","applicantPreferences","applicantHouseholdSize","attributes","mappedPreferences","Displaced","Disabled","Homeless","Elderly","applicantIncomeLimit","household_income_limits","find","incomeLimit","household_size","waitlist_types","join","unit_groups","applicant_requirements","matchedPreferences","matches","preferences","reduce","acc","pref","push","length","income_min","toLocaleString","income_max","description","props","relationships","locations","locationString","data","loc","id","locData","locationMatch","short_name","name","scattered_site","street_address","city","state","zip_code","website","building_types","total_units","property","propertyAttributes","accessibility_features","pets","amenities","application_fee","security_deposit","background_checks","utilities","PropertyBuildingInfo","Object","keys","map","attribute","key","Array","isArray","replace","PropertyImagesSection","propertyImages","src","image_url","alt","slice","image","WaitlistDocuments","documents","document","title","href","document_url","target","rel","waitlistData","waitlist","properties","applicantId","joined","joinWaitlist","goBack","onClick","disabled","index","FullPropertyDetails","ReactOnRails","WaitlistPage"],"sourceRoot":""}