{"version":3,"sources":["source/assets/js/site/site.es6.js","source/_patterns/components/additional-dates/additional-dates.es6.js","source/_patterns/components/filters/filters-properties.es6.js","source/_patterns/components/filters/filters.es6.js","source/_patterns/components/nav/nav--secondary.es6.js","source/_patterns/components/modal/modal.es6.js","source/_patterns/components/nav-section/nav-section.es6.js","source/_patterns/components/property-listing/property-listing.es6.js","source/_patterns/components/ready-to-apply-block/ready-to-apply-block.es6.js","source/_patterns/components/tab-interface/tab-interface.es6.js","source/_patterns/pages/properties/property-detail.es6.js"],"names":["printLink","document","querySelector","toggleDateBlock","dateButton","dateBlock","updateDateBlock","window","innerWidth","style","display","addEventListener","classList","add","remove","setAttribute","propertyFiltersToggle","getElementById","propertyFilterForm","runPropertyFilterToggle","button","this","hidden","resetPropertyFilterToggle","toggleFilters","filterType","filterButton","filterForm","updateFilterForm","searchToggle","searchWrapper","navSecondary","navLastPrimaryLink","setSearchToggle","getAttribute","modalButtons","querySelectorAll","modalClose","modalVideo","pauseVideo","contentWindow","postMessage","length","event","forEach","e","key","observer","MutationObserver","mutations","mutation","type","modalOverlay","disconnect","config","childList","subtree","observe","body","softGateButton","handleMutations","sessionStorage","setItem","getItem","click","sectionNav","sectionNavButton","sectionNavDisplay","sectionNavExpanded","mapView","$","Drupal","behaviors","propertyToggleBehavior","attach","context","settings","toggleListBtn","toggleListView","toggleMapBtn","toggleMapView","toggleTopView","propertyListing","setPropertyToogle","activeBtn","activeView","inactiveBtn","inactiveView","id","getVisibleHeight","element","rect","getBoundingClientRect","windowHeight","innerHeight","documentElement","clientHeight","Math","max","min","bottom","top","updateVisibleHeight","siteHeader","filterTotal","filterActions","filterItems","topHeight","actionsHeight","offsetHeight","headerHeight","maxHeight","onScroll","IntersectionObserver","callback","entries","entry","isIntersecting","removeEventListener","root","threshold","on","scrollTimeout","scrollY","clearTimeout","setTimeout","jQuery","applyToggle","applyContent","updateContentVisibility","isExpanded","toggle","tabbed","tablist","tabs","panels","switchTab","oldTab","newTab","focus","removeAttribute","index","Array","prototype","indexOf","call","oldIndex","tab","i","parentNode","preventDefault","currentTab","currentTarget","dir","which","panel","propertyDetails","classAdded","lastScrollY","isDetailsBottomInView","el","propertyScroll"],"mappings":"AACA,MAAMA,UAAYC,SAASC,cAAc,iBCAzC,SAASC,kBACP,MAAMC,EAAaH,SAASC,cAAc,6BACpCG,EAAYJ,SAASC,cAAc,4BAIzC,SAASI,IACHC,OAAOC,WAJM,KAKfH,EAAUI,MAAMC,QAAU,OAC1BN,EAAWK,MAAMC,QAAU,SAE3BL,EAAUI,MAAMC,QAAU,QAC1BN,EAAWK,MAAMC,QAAU,QAP1BN,GAAeC,IAYpBD,EAAWO,iBAAiB,QAAS,KAC/BJ,OAAOC,WAfM,MAgBiB,SAA5BH,EAAUI,MAAMC,SAClBL,EAAUI,MAAMC,QAAU,QAC1BL,EAAUO,UAAUC,IAAI,YAExBR,EAAUI,MAAMC,QAAU,OAC1BL,EAAUO,UAAUE,OAAO,cAMjCP,OAAOI,iBAAiB,SAAUL,GAClCA,KD7BEN,WACFA,UAAUe,aAAa,SAAU,UCgCnCd,SAASU,iBAAiB,mBAAoBR,iBCpC9C,MAAMa,sBAAwBf,SAASgB,eAAe,2BAChDC,mBAAqBjB,SAASgB,eAAe,2CAEnD,SAASE,0BACPH,sBAAsBL,iBAAiB,SAAS,WAC9C,MAAMS,EAASC,MAEmB,IAA9BH,mBAAmBI,QACrBJ,mBAAmBI,QAAS,EAC5BF,EAAOL,aAAa,gBAAiB,UAErCG,mBAAmBI,QAAS,EAC5BF,EAAOL,aAAa,gBAAiB,aAK3C,SAASQ,4BACHhB,OAAOC,YAAc,MAEvBQ,sBAAsBD,aAAa,gBAAiB,SACpDG,mBAAmBI,QAAS,GCpBhC,SAASE,cAAcC,GACrB,MAAMC,EAAezB,SAASC,cAAc,mBACtCyB,EAAa1B,SAASC,cAAc,yBAK1C,SAAS0B,IACHrB,OAAOC,WALM,KAMfmB,EAAWlB,MAAMC,QAAU,OAC3BgB,EAAajB,MAA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AAUC,IALZ,qBAMdgJ,YAAa,GAENA,YAActJ,OAAOoH,QAAUmC,cAExCF,gBAAgBhJ,UAAUE,OAVV,qBAWhB+I,YAAa,GAIfC,YAAcvJ,OAAOoH,QAGnBiC,iBAEFrJ,OAAOI,iBAAiB,SAAUsJ","file":"custom.min.js","sourcesContent":["// Add elements and classes to print link from Entity Print module.\nconst printLink = document.querySelector('a.print__link');\n\nif (printLink) {\n printLink.setAttribute('target', '_blank');\n}\n","// Function to toggle the Additional date visibility on mobile\nfunction toggleDateBlock() {\n const dateButton = document.querySelector('.additional-dates__button');\n const dateBlock = document.querySelector('.additional-dates__block');\n const breakpoint = 880;\n\n if (!dateButton || !dateBlock) return;\n function updateDateBlock() {\n if (window.innerWidth < breakpoint) {\n dateBlock.style.display = 'none';\n dateButton.style.display = 'flex';\n } else {\n dateBlock.style.display = 'block';\n dateButton.style.display = 'none';\n }\n }\n\n // Event listener for button click to toggle form visibility on mobile\n dateButton.addEventListener('click', () => {\n if (window.innerWidth < breakpoint) {\n if (dateBlock.style.display === 'none') {\n dateBlock.style.display = 'block';\n dateBlock.classList.add('active');\n } else {\n dateBlock.style.display = 'none';\n dateBlock.classList.remove('active');\n }\n }\n });\n\n // Event listener for window resize to adjust visibility\n window.addEventListener('resize', updateDateBlock);\n updateDateBlock();\n}\n\n// Initialize the toggle functionality after the DOM loads\ndocument.addEventListener('DOMContentLoaded', toggleDateBlock);\n","const propertyFiltersToggle = document.getElementById('property-filters-toggle');\nconst propertyFilterForm = document.getElementById('views-exposed-form-property-list-page-3');\n\nfunction runPropertyFilterToggle() {\n propertyFiltersToggle.addEventListener('click', function handleClick() {\n const button = this;\n\n if (propertyFilterForm.hidden === true) {\n propertyFilterForm.hidden = false;\n button.setAttribute('aria-expanded', 'true');\n } else {\n propertyFilterForm.hidden = true;\n button.setAttribute('aria-expanded', 'false');\n }\n });\n}\n\nfunction resetPropertyFilterToggle() {\n if (window.innerWidth >= 880) {\n // Reset the elements if window size is equal or greater than 880px\n propertyFiltersToggle.setAttribute('aria-expanded', 'false');\n propertyFilterForm.hidden = false;\n } else {\n // propertyFiltersToggle.setAttribute('aria-expanded', 'true');\n }\n}\n\nif (propertyFiltersToggle) {\n if (window.innerWidth < 880) {\n // Set property filter form to hidden on pageload\n propertyFilterForm.hidden = true;\n\n // Run property filter toggle function if clicked\n runPropertyFilterToggle();\n }\n\n // Adjust filter display on window resize\n window.addEventListener('resize', resetPropertyFilterToggle);\n}\n","// Function to toggle the visibility of filters (News or Events) on mobile\nfunction toggleFilters(filterType) {\n const filterButton = document.querySelector('.filter__button');\n const filterForm = document.querySelector('.sidebar-filters form');\n const breakpoint = 880;\n\n if (!filterButton || !filterForm) return;\n\n function updateFilterForm() {\n if (window.innerWidth < breakpoint) {\n filterForm.style.display = 'none';\n filterButton.style.display = 'flex';\n } else {\n filterForm.style.display = 'flex';\n filterButton.style.display = 'none';\n }\n }\n\n // Event listener for button click to toggle form visibility on mobile\n filterButton.addEventListener('click', () => {\n if (window.innerWidth < breakpoint) {\n if (filterForm.style.display === 'none') {\n filterForm.style.display = 'flex';\n filterForm.classList.add('active');\n } else {\n filterForm.style.display = 'none';\n filterForm.classList.remove('active');\n }\n }\n });\n\n // Event listener for window resize to adjust visibility\n window.addEventListener('resize', updateFilterForm);\n updateFilterForm();\n}\n\n// Initialize the toggle functionality for both News and Events after the DOM loads\ndocument.addEventListener('DOMContentLoaded', () => {\n if (document.querySelector('.listing-container')) {\n toggleFilters();\n }\n});\n","const searchToggle = document.getElementById('usa-search-toggle');\nconst searchWrapper = document.getElementById('usa-search-wrapper');\nconst navSecondary = document.querySelector('.usa-nav__secondary-links');\nconst navLastPrimaryLink = document.querySelector('ul.usa-nav__primary .usa-nav__primary-item:last-child button');\n\nfunction setSearchToggle() {\n // Check the window width\n if (window.innerWidth >= 1024) {\n // Hide search if button aria-expanded is false\n if (searchToggle.getAttribute('aria-expanded') === 'false') {\n searchWrapper.hidden = true;\n }\n } else {\n // Reset the elements if window size is less than 1024px\n searchWrapper.hidden = false;\n searchToggle.setAttribute('aria-expanded', 'false');\n navSecondary.hidden = false;\n }\n}\n\nif (searchToggle) {\n // Toggle search on button click\n // eslint-disable-next-line func-names\n searchToggle.addEventListener('click', function searchClick() {\n const isHidden = searchWrapper.hidden === true || false;\n\n if (isHidden) {\n searchWrapper.hidden = false;\n navSecondary.hidden = true;\n this.setAttribute('aria-expanded', 'true');\n } else {\n searchWrapper.hidden = true;\n navSecondary.hidden = false;\n this.setAttribute('aria-expanded', 'false');\n }\n });\n\n // Search toggle setting and display\n setSearchToggle();\n\n // Adjust search toggle on window resize\n window.addEventListener('resize', setSearchToggle);\n}\n\nif (window.innerWidth < 1024) {\n // Remove button styling for last item in the primary nav on mobile.\n navLastPrimaryLink.classList.remove('usa-nav__link--button');\n}\n","// TODO If applicable, add Vimeo video check. See previous commits of this document.\nconst modalButtons = document.querySelectorAll('.usa-button--modal');\nconst modalClose = document.querySelectorAll('.usa-modal__close');\nconst modalVideo = document.querySelector('.usa-modal__main iframe');\n\n// const playVideo = () => {\n// if (modalVideo.contentWindow) {\n// // Play Videos\n// modalVideo.contentWindow.postMessage\n// ('{ \"event\":\"command\", \"func\":\"playVideo\", \"args\":\"\" }', '*');\n// }\n// };\n\n// Pause video\nconst pauseVideo = () => {\n if (modalVideo.contentWindow) {\n // YouTube only\n modalVideo.contentWindow.postMessage('{ \"event\": \"command\", \"func\": \"stopVideo\", \"args\":\"\" }', '*');\n }\n};\n\nif (modalVideo !== null) {\n // Play video if modal button is clicked\n // modalButtons.forEach((e) => {\n // e.addEventListener('click', () => {\n // console.log('button modal clicked');\n // playVideo();\n // });\n // });\n\n // Pause video when close button is clicked\n if (modalVideo.length > 0) {\n document.addEventListener('DOMContentLoaded', (event) => {\n modalClose.forEach((e) => {\n e.addEventListener('click', () => {\n pauseVideo();\n });\n });\n });\n }\n\n // Pause video if esc key is pressed\n document.addEventListener('keydown', (e) => {\n if (e.key === 'Escape') {\n // Currently this only works if the focus is outside the iframe\n pauseVideo();\n }\n });\n\n // Set up observer for dynamic modal overlay\n const observer = new MutationObserver((mutations) => {\n mutations.forEach((mutation) => {\n if (mutation.type === 'childList') {\n const modalOverlay = document.querySelectorAll('.usa-modal-overlay');\n\n if (modalOverlay) {\n modalOverlay.forEach((e) => {\n e.addEventListener('click', () => {\n pauseVideo();\n });\n\n // Disconnect the observer if no longer needed\n observer.disconnect();\n });\n }\n }\n });\n });\n\n // Configuration for the observer\n const config = { childList: true, subtree: true };\n\n // Start observing the target node for configured mutations\n observer.observe(document.body, config);\n}\n\n// Open soft gate modal on pageload and set sessionStorage key/value\nconst softGateButton = document.querySelector('.usa-button--soft-gate');\n\nif (softGateButton) {\n // Observer callback function to handle modal overlay detection\n const handleMutations = (mutations, observer) => {\n mutations.forEach((mutation) => {\n if (mutation.type === 'childList') {\n const modalOverlay = document.querySelector('.usa-modal-overlay');\n\n if (modalOverlay) {\n const closeButtons = document.querySelectorAll('.usa-modal-overlay, .usa-modal--soft-gate [data-close-modal]');\n\n closeButtons.forEach((button) => {\n button.addEventListener('click', () => {\n sessionStorage.setItem('softGateModal', 'closed');\n observer.disconnect(); // Stop observing when modal is closed\n });\n });\n }\n }\n });\n };\n\n // Set up and start the observer\n const observer = new MutationObserver(handleMutations);\n observer.observe(document.body, { childList: true, subtree: true });\n\n // Trigger modal opening if sessionStorage key isn't set\n if (!sessionStorage.getItem('softGateModal')) {\n window.addEventListener('load', () => softGateButton.click());\n const modal = document.querySelector('.usa-modal--soft-gate');\n modal.style.display = 'inline-block';\n }\n}\n","const sectionNav = document.querySelector('.nav-section');\nconst sectionNavButton = document.querySelector('.nav-section__button');\n\n// Check window size\nfunction sectionNavDisplay() {\n if (window.innerWidth > 900) {\n // Show section nav\n sectionNav.hidden = false;\n } else {\n // Hide section nav\n sectionNav.hidden = true;\n sectionNavButton.setAttribute('aria-expanded', 'false');\n }\n}\n\n// If section nav is present\nif (sectionNav) {\n // Show/hide section nav on page load\n sectionNavDisplay();\n\n // Show/hide section nav on resize\n window.addEventListener('resize', () => {\n sectionNavDisplay();\n });\n\n // On section nav button click\n sectionNavButton.addEventListener('click', () => {\n // Toggle button attributes\n const sectionNavExpanded = sectionNavButton.getAttribute('aria-expanded') === 'true' || false;\n sectionNavButton.setAttribute('aria-expanded', !sectionNavExpanded);\n\n // Toggle section nav display\n sectionNav.hidden = !sectionNav.hidden;\n });\n}\n","let mapView = false;\n(function ($, Drupal) {\n Drupal.behaviors.propertyToggleBehavior = {\n attach(context, settings) {\n // Variables\n const toggleListBtn = document.getElementById('property-toggle-list');\n const toggleListView = document.getElementById('property-list-view');\n const toggleMapBtn = document.getElementById('property-toggle-map');\n const toggleMapView = document.getElementById('property-map-view');\n const toggleTopView = document.getElementById('property-top');\n const propertyListing = document.querySelector('.property-listing');\n\n // List and Map Toggle\n function setPropertyToogle(activeBtn, activeView, inactiveBtn, inactiveView) {\n mapView = false;\n if (activeView.id === 'property-map-view') {\n mapView = true;\n }\n activeBtn.setAttribute('aria-expanded', 'true');\n inactiveBtn.setAttribute('aria-expanded', 'false');\n activeBtn.classList.add('usa-button--base');\n activeBtn.classList.remove('usa-button--outline');\n inactiveBtn.classList.add('usa-button--outline');\n inactiveBtn.classList.remove('usa-button--base');\n inactiveView.hidden = true;\n activeView.hidden = false;\n if (activeView === toggleMapView) {\n toggleTopView.classList.add('property-listing__results--map');\n } else {\n toggleTopView.classList.remove('property-listing__results--map');\n }\n }\n\n function setPropertyMobile() {\n if (window.innerWidth < 880) {\n toggleMapView.hidden = true;\n toggleListView.hidden = false;\n toggleMapBtn.setAttribute('aria-expanded', 'false');\n toggleMapBtn.classList.remove('usa-button--base');\n toggleMapBtn.classList.add('usa-button--outline');\n toggleListBtn.setAttribute('aria-expanded', 'true');\n toggleListBtn.classList.remove('usa-button--outline');\n toggleListBtn.classList.add('usa-button--base');\n toggleTopView.classList.remove('property-listing__results--map');\n }\n }\n\n function getVisibleHeight(element) {\n const rect = element.getBoundingClientRect();\n const windowHeight = (window.innerHeight || document.documentElement.clientHeight);\n return Math.max(0, Math.min(rect.bottom, windowHeight) - Math.max(rect.top, 0));\n }\n\n function updateVisibleHeight() {\n const siteHeader = document.querySelector('.usa-header');\n const filterTotal = document.querySelector('.property-listing__filter-total');\n const filterActions = document.querySelector('.property-filters__actions');\n const filterItems = document.querySelector('.property-filters__items');\n const topHeight = getVisibleHeight(filterTotal);\n const actionsHeight = filterActions.offsetHeight;\n let headerHeight = 0;\n\n if (siteHeader) {\n headerHeight = getVisibleHeight(siteHeader);\n }\n\n if (window.innerWidth >= 880) {\n filterItems.style.maxHeight = `calc(100vh - ${topHeight}px - ${actionsHeight}px - ${headerHeight}px)`;\n } else {\n filterItems.style.maxHeight = 'auto';\n }\n }\n\n const onScroll = () => {\n const rect = toggleListView.getBoundingClientRect();\n if (rect.top <= 0) {\n propertyListing.classList.add('property-listing--scrolled');\n } else {\n propertyListing.classList.remove('property-listing--scrolled');\n }\n };\n\n const callback = (entries, observer) => {\n entries.forEach((entry) => {\n if (entry.isIntersecting) {\n window.addEventListener('scroll', onScroll);\n } else {\n window.removeEventListener('scroll', onScroll);\n propertyListing.classList.remove('property-listing--scrolled');\n }\n });\n };\n\n const observer = new IntersectionObserver(callback, {\n root: null,\n threshold: 0,\n });\n\n if (propertyListing) {\n if (mapView === true) {\n setPropertyToogle(toggleMapBtn, toggleMapView, toggleListBtn, toggleListView);\n }\n $(toggleListBtn).on('click', () => {\n setPropertyToogle(toggleListBtn, toggleListView, toggleMapBtn, toggleMapView);\n });\n\n $(toggleMapBtn).on('click', () => {\n setPropertyToogle(toggleMapBtn, toggleMapView, toggleListBtn, toggleListView);\n });\n\n $(window).on('resize', setPropertyMobile);\n updateVisibleHeight();\n\n $(window).on('scroll', () => {\n let scrollTimeout;\n updateVisibleHeight();\n\n if (window.scrollY === 0) {\n clearTimeout(scrollTimeout);\n scrollTimeout = setTimeout(updateVisibleHeight, 255);\n }\n });\n\n $(window).on('resize', updateVisibleHeight);\n observer.observe(toggleListView);\n }\n },\n };\n})(jQuery, Drupal);\n","const applyToggle = document.getElementById('ready-to-apply-block__toggle');\nconst applyContent = document.getElementById('ready-to-apply-block__content');\n\nfunction updateContentVisibility() {\n if (window.innerWidth > 880) {\n applyContent.style.display = 'block';\n applyToggle.style.display = 'none';\n } else {\n applyToggle.style.display = 'inline-flex';\n const isExpanded = applyToggle.getAttribute('aria-expanded') === 'true';\n applyContent.style.display = isExpanded ? 'block' : 'none';\n }\n}\n\nif (applyToggle) {\n applyToggle.addEventListener('click', () => {\n const isExpanded = applyToggle.getAttribute('aria-expanded') === 'true';\n applyToggle.setAttribute('aria-expanded', !isExpanded);\n applyContent.style.display = isExpanded ? 'none' : 'block';\n applyToggle.classList.toggle('usa-button--toggle-up', isExpanded);\n applyToggle.classList.toggle('usa-button--toggle-down', !isExpanded);\n });\n\n window.addEventListener('resize', updateContentVisibility);\n window.addEventListener('load', updateContentVisibility);\n}\n","// Tabs based on https://inclusive-components.design/tabbed-interfaces/\nconst tabbed = document.querySelector('.tabbed');\n\nif (tabbed) {\n const tablist = tabbed.querySelector('ul');\n const tabs = tablist.querySelectorAll('a');\n const panels = tabbed.querySelectorAll('[id^=\"section\"]');\n\n // The tab switching function\n const switchTab = (oldTab, newTab) => {\n newTab.focus();\n // Make the active tab focusable by the user (Tab key)\n newTab.removeAttribute('tabindex');\n // Set the selected state\n newTab.setAttribute('aria-selected', 'true');\n oldTab.removeAttribute('aria-selected');\n oldTab.setAttribute('tabindex', '-1');\n\n // Get the indices of the new and old tabs to find the correct\n // tab panels to show and hide\n const index = Array.prototype.indexOf.call(tabs, newTab);\n const oldIndex = Array.prototype.indexOf.call(tabs, oldTab);\n panels[oldIndex].hidden = true;\n panels[index].hidden = false;\n };\n\n // Add the tablist role to the first