25b0bc144832d680179f3ae6f1c1e7e9c98d8a376ee122184fbc70e49dc05f9f.json 48 KB

1
  1. {"ast":null,"code":"import _asyncToGenerator from \"F:/workspace/202226701027/huinongbao-app/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js\";\n/*!\n * (C) Ionic http://ionicframework.com - MIT License\n */\nimport { readTask, writeTask, proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';\nimport { g as getScrollElement, f as findIonContent, p as printIonContentErrorMsg } from './index8.js';\nimport { k as clamp, i as inheritAriaAttributes } from './helpers.js';\nimport { h as hostContext } from './theme.js';\nimport { b as getIonMode } from './ionic-global.js';\nconst TRANSITION = 'all 0.2s ease-in-out';\nconst cloneElement = tagName => {\n const getCachedEl = document.querySelector(`${tagName}.ion-cloned-element`);\n if (getCachedEl !== null) {\n return getCachedEl;\n }\n const clonedEl = document.createElement(tagName);\n clonedEl.classList.add('ion-cloned-element');\n clonedEl.style.setProperty('display', 'none');\n document.body.appendChild(clonedEl);\n return clonedEl;\n};\nconst createHeaderIndex = headerEl => {\n if (!headerEl) {\n return;\n }\n const toolbars = headerEl.querySelectorAll('ion-toolbar');\n return {\n el: headerEl,\n toolbars: Array.from(toolbars).map(toolbar => {\n const ionTitleEl = toolbar.querySelector('ion-title');\n return {\n el: toolbar,\n background: toolbar.shadowRoot.querySelector('.toolbar-background'),\n ionTitleEl,\n innerTitleEl: ionTitleEl ? ionTitleEl.shadowRoot.querySelector('.toolbar-title') : null,\n ionButtonsEl: Array.from(toolbar.querySelectorAll('ion-buttons'))\n };\n })\n };\n};\nconst handleContentScroll = (scrollEl, scrollHeaderIndex, contentEl) => {\n readTask(() => {\n const scrollTop = scrollEl.scrollTop;\n const scale = clamp(1, 1 + -scrollTop / 500, 1.1);\n // Native refresher should not cause titles to scale\n const nativeRefresher = contentEl.querySelector('ion-refresher.refresher-native');\n if (nativeRefresher === null) {\n writeTask(() => {\n scaleLargeTitles(scrollHeaderIndex.toolbars, scale);\n });\n }\n });\n};\nconst setToolbarBackgroundOpacity = (headerEl, opacity) => {\n /**\n * Fading in the backdrop opacity\n * should happen after the large title\n * has collapsed, so it is handled\n * by handleHeaderFade()\n */\n if (headerEl.collapse === 'fade') {\n return;\n }\n if (opacity === undefined) {\n headerEl.style.removeProperty('--opacity-scale');\n } else {\n headerEl.style.setProperty('--opacity-scale', opacity.toString());\n }\n};\nconst handleToolbarBorderIntersection = (ev, mainHeaderIndex, scrollTop) => {\n if (!ev[0].isIntersecting) {\n return;\n }\n /**\n * There is a bug in Safari where overflow scrolling on a non-body element\n * does not always reset the scrollTop position to 0 when letting go. It will\n * set to 1 once the rubber band effect has ended. This causes the background to\n * appear slightly on certain app setups.\n *\n * Additionally, we check if user is rubber banding (scrolling is negative)\n * as this can mean they are using pull to refresh. Once the refresher starts,\n * the content is transformed which can cause the intersection observer to erroneously\n * fire here as well.\n */\n const scale = ev[0].intersectionRatio > 0.9 || scrollTop <= 0 ? 0 : (1 - ev[0].intersectionRatio) * 100 / 75;\n setToolbarBackgroundOpacity(mainHeaderIndex.el, scale === 1 ? undefined : scale);\n};\n/**\n * If toolbars are intersecting, hide the scrollable toolbar content\n * and show the primary toolbar content. If the toolbars are not intersecting,\n * hide the primary toolbar content and show the scrollable toolbar content\n */\nconst handleToolbarIntersection = (ev,\n// TODO(FW-2832): type (IntersectionObserverEntry[] triggers errors which should be sorted)\nmainHeaderIndex, scrollHeaderIndex, scrollEl) => {\n writeTask(() => {\n const scrollTop = scrollEl.scrollTop;\n handleToolbarBorderIntersection(ev, mainHeaderIndex, scrollTop);\n const event = ev[0];\n const intersection = event.intersectionRect;\n const intersectionArea = intersection.width * intersection.height;\n const rootArea = event.rootBounds.width * event.rootBounds.height;\n const isPageHidden = intersectionArea === 0 && rootArea === 0;\n const leftDiff = Math.abs(intersection.left - event.boundingClientRect.left);\n const rightDiff = Math.abs(intersection.right - event.boundingClientRect.right);\n const isPageTransitioning = intersectionArea > 0 && (leftDiff >= 5 || rightDiff >= 5);\n if (isPageHidden || isPageTransitioning) {\n return;\n }\n if (event.isIntersecting) {\n setHeaderActive(mainHeaderIndex, false);\n setHeaderActive(scrollHeaderIndex);\n } else {\n /**\n * There is a bug with IntersectionObserver on Safari\n * where `event.isIntersecting === false` when cancelling\n * a swipe to go back gesture. Checking the intersection\n * x, y, width, and height provides a workaround. This bug\n * does not happen when using Safari + Web Animations,\n * only Safari + CSS Animations.\n */\n const hasValidIntersection = intersection.x === 0 && intersection.y === 0 || intersection.width !== 0 && intersection.height !== 0;\n if (hasValidIntersection && scrollTop > 0) {\n setHeaderActive(mainHeaderIndex);\n setHeaderActive(scrollHeaderIndex, false);\n setToolbarBackgroundOpacity(mainHeaderIndex.el);\n }\n }\n });\n};\nconst setHeaderActive = (headerIndex, active = true) => {\n const headerEl = headerIndex.el;\n if (active) {\n headerEl.classList.remove('header-collapse-condense-inactive');\n headerEl.removeAttribute('aria-hidden');\n } else {\n headerEl.classList.add('header-collapse-condense-inactive');\n headerEl.setAttribute('aria-hidden', 'true');\n }\n};\nconst scaleLargeTitles = (toolbars = [], scale = 1, transition = false) => {\n toolbars.forEach(toolbar => {\n const ionTitle = toolbar.ionTitleEl;\n const titleDiv = toolbar.innerTitleEl;\n if (!ionTitle || ionTitle.size !== 'large') {\n return;\n }\n titleDiv.style.transition = transition ? TRANSITION : '';\n titleDiv.style.transform = `scale3d(${scale}, ${scale}, 1)`;\n });\n};\nconst handleHeaderFade = (scrollEl, baseEl, condenseHeader) => {\n readTask(() => {\n const scrollTop = scrollEl.scrollTop;\n const baseElHeight = baseEl.clientHeight;\n const fadeStart = condenseHeader ? condenseHeader.clientHeight : 0;\n /**\n * If we are using fade header with a condense\n * header, then the toolbar backgrounds should\n * not begin to fade in until the condense\n * header has fully collapsed.\n *\n * Additionally, the main content should not\n * overflow out of the container until the\n * condense header has fully collapsed. When\n * using just the condense header the content\n * should overflow out of the container.\n */\n if (condenseHeader !== null && scrollTop < fadeStart) {\n baseEl.style.setProperty('--opacity-scale', '0');\n scrollEl.style.setProperty('clip-path', `inset(${baseElHeight}px 0px 0px 0px)`);\n return;\n }\n const distanceToStart = scrollTop - fadeStart;\n const fadeDuration = 10;\n const scale = clamp(0, distanceToStart / fadeDuration, 1);\n writeTask(() => {\n scrollEl.style.removeProperty('clip-path');\n baseEl.style.setProperty('--opacity-scale', scale.toString());\n });\n });\n};\nconst headerIosCss = \"ion-header{display:block;position:relative;-ms-flex-order:-1;order:-1;width:100%;z-index:10}ion-header ion-toolbar:first-of-type{padding-top:var(--ion-safe-area-top, 0)}.header-ios ion-toolbar:last-of-type{--border-width:0 0 0.55px}@supports ((-webkit-backdrop-filter: blur(0)) or (backdrop-filter: blur(0))){.header-background{left:0;right:0;top:0;bottom:0;position:absolute;-webkit-backdrop-filter:saturate(180%) blur(20px);backdrop-filter:saturate(180%) blur(20px)}.header-translucent-ios ion-toolbar{--opacity:.8}.header-collapse-condense-inactive .header-background{-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px)}}.header-ios.ion-no-border ion-toolbar:last-of-type{--border-width:0}.header-collapse-fade ion-toolbar{--opacity-scale:inherit}.header-collapse-condense{z-index:9}.header-collapse-condense ion-toolbar{position:-webkit-sticky;position:sticky;top:0}.header-collapse-condense ion-toolbar:first-of-type{padding-top:0px;z-index:1}.header-collapse-condense ion-toolbar{--background:var(--ion-background-color, #fff);z-index:0}.header-collapse-condense ion-toolbar:last-of-type{--border-width:0px}.header-collapse-condense ion-toolbar ion-searchbar{padding-top:0px;padding-bottom:13px}.header-collapse-main{--opacity-scale:1}.header-collapse-main ion-toolbar{--opacity-scale:inherit}.header-collapse-main ion-toolbar.in-toolbar ion-title,.header-collapse-main ion-toolbar.in-toolbar ion-buttons{-webkit-transition:all 0.2s ease-in-out;transition:all 0.2s ease-in-out}.header-collapse-condense-inactive:not(.header-collapse-condense) ion-toolbar.in-toolbar ion-title,.header-collapse-condense-inactive:not(.header-collapse-condense) ion-toolbar.in-toolbar ion-buttons.buttons-collapse{opacity:0;pointer-events:none}.header-collapse-condense-inactive.header-collapse-condense ion-toolbar.in-toolbar ion-title,.header-collapse-condense-inactive.header-collapse-condense ion-toolbar.in-toolbar ion-buttons.buttons-collapse{visibility:hidden}ion-header.header-ios:not(.header-collapse-main):has(~ion-content ion-header.header-ios[collapse=condense],~ion-content ion-header.header-ios.header-collapse-condense){opacity:0}\";\nconst IonHeaderIosStyle0 = headerIosCss;\nconst headerMdCss = \"ion-header{display:block;position:relative;-ms-flex-order:-1;order:-1;width:100%;z-index:10}ion-header ion-toolbar:first-of-type{padding-top:var(--ion-safe-area-top, 0)}.header-md{-webkit-box-shadow:0 2px 4px -1px rgba(0, 0, 0, 0.2), 0 4px 5px 0 rgba(0, 0, 0, 0.14), 0 1px 10px 0 rgba(0, 0, 0, 0.12);box-shadow:0 2px 4px -1px rgba(0, 0, 0, 0.2), 0 4px 5px 0 rgba(0, 0, 0, 0.14), 0 1px 10px 0 rgba(0, 0, 0, 0.12)}.header-collapse-condense{display:none}.header-md.ion-no-border{-webkit-box-shadow:none;box-shadow:none}\";\nconst IonHeaderMdStyle0 = headerMdCss;\nconst Header = /*@__PURE__*/proxyCustomElement(class Header extends HTMLElement {\n constructor() {\n var _this;\n super();\n _this = this;\n this.__registerHost();\n this.inheritedAttributes = {};\n this.setupFadeHeader = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(function* (contentEl, condenseHeader) {\n const scrollEl = _this.scrollEl = yield getScrollElement(contentEl);\n /**\n * Handle fading of toolbars on scroll\n */\n _this.contentScrollCallback = () => {\n handleHeaderFade(_this.scrollEl, _this.el, condenseHeader);\n };\n scrollEl.addEventListener('scroll', _this.contentScrollCallback);\n handleHeaderFade(_this.scrollEl, _this.el, condenseHeader);\n });\n return function (_x, _x2) {\n return _ref.apply(this, arguments);\n };\n }();\n this.collapse = undefined;\n this.translucent = false;\n }\n componentWillLoad() {\n this.inheritedAttributes = inheritAriaAttributes(this.el);\n }\n componentDidLoad() {\n this.checkCollapsibleHeader();\n }\n componentDidUpdate() {\n this.checkCollapsibleHeader();\n }\n disconnectedCallback() {\n this.destroyCollapsibleHeader();\n }\n checkCollapsibleHeader() {\n var _this2 = this;\n return _asyncToGenerator(function* () {\n const mode = getIonMode(_this2);\n if (mode !== 'ios') {\n return;\n }\n const {\n collapse\n } = _this2;\n const hasCondense = collapse === 'condense';\n const hasFade = collapse === 'fade';\n _this2.destroyCollapsibleHeader();\n if (hasCondense) {\n const pageEl = _this2.el.closest('ion-app,ion-page,.ion-page,page-inner');\n const contentEl = pageEl ? findIonContent(pageEl) : null;\n // Cloned elements are always needed in iOS transition\n writeTask(() => {\n const title = cloneElement('ion-title');\n title.size = 'large';\n cloneElement('ion-back-button');\n });\n yield _this2.setupCondenseHeader(contentEl, pageEl);\n } else if (hasFade) {\n const pageEl = _this2.el.closest('ion-app,ion-page,.ion-page,page-inner');\n const contentEl = pageEl ? findIonContent(pageEl) : null;\n if (!contentEl) {\n printIonContentErrorMsg(_this2.el);\n return;\n }\n const condenseHeader = contentEl.querySelector('ion-header[collapse=\"condense\"]');\n yield _this2.setupFadeHeader(contentEl, condenseHeader);\n }\n })();\n }\n destroyCollapsibleHeader() {\n if (this.intersectionObserver) {\n this.intersectionObserver.disconnect();\n this.intersectionObserver = undefined;\n }\n if (this.scrollEl && this.contentScrollCallback) {\n this.scrollEl.removeEventListener('scroll', this.contentScrollCallback);\n this.contentScrollCallback = undefined;\n }\n if (this.collapsibleMainHeader) {\n this.collapsibleMainHeader.classList.remove('header-collapse-main');\n this.collapsibleMainHeader = undefined;\n }\n }\n setupCondenseHeader(contentEl, pageEl) {\n var _this3 = this;\n return _asyncToGenerator(function* () {\n if (!contentEl || !pageEl) {\n printIonContentErrorMsg(_this3.el);\n return;\n }\n if (typeof IntersectionObserver === 'undefined') {\n return;\n }\n _this3.scrollEl = yield getScrollElement(contentEl);\n const headers = pageEl.querySelectorAll('ion-header');\n _this3.collapsibleMainHeader = Array.from(headers).find(header => header.collapse !== 'condense');\n if (!_this3.collapsibleMainHeader) {\n return;\n }\n const mainHeaderIndex = createHeaderIndex(_this3.collapsibleMainHeader);\n const scrollHeaderIndex = createHeaderIndex(_this3.el);\n if (!mainHeaderIndex || !scrollHeaderIndex) {\n return;\n }\n setHeaderActive(mainHeaderIndex, false);\n setToolbarBackgroundOpacity(mainHeaderIndex.el, 0);\n /**\n * Handle interaction between toolbar collapse and\n * showing/hiding content in the primary ion-header\n * as well as progressively showing/hiding the main header\n * border as the top-most toolbar collapses or expands.\n */\n const toolbarIntersection = ev => {\n handleToolbarIntersection(ev, mainHeaderIndex, scrollHeaderIndex, _this3.scrollEl);\n };\n _this3.intersectionObserver = new IntersectionObserver(toolbarIntersection, {\n root: contentEl,\n threshold: [0.25, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1]\n });\n _this3.intersectionObserver.observe(scrollHeaderIndex.toolbars[scrollHeaderIndex.toolbars.length - 1].el);\n /**\n * Handle scaling of large iOS titles and\n * showing/hiding border on last toolbar\n * in primary header\n */\n _this3.contentScrollCallback = () => {\n handleContentScroll(_this3.scrollEl, scrollHeaderIndex, contentEl);\n };\n _this3.scrollEl.addEventListener('scroll', _this3.contentScrollCallback);\n writeTask(() => {\n if (_this3.collapsibleMainHeader !== undefined) {\n _this3.collapsibleMainHeader.classList.add('header-collapse-main');\n }\n });\n })();\n }\n render() {\n const {\n translucent,\n inheritedAttributes\n } = this;\n const mode = getIonMode(this);\n const collapse = this.collapse || 'none';\n // banner role must be at top level, so remove role if inside a menu\n const roleType = hostContext('ion-menu', this.el) ? 'none' : 'banner';\n return h(Host, Object.assign({\n key: 'b6cc27f0b08afc9fcc889683525da765d80ba672',\n role: roleType,\n class: {\n [mode]: true,\n // Used internally for styling\n [`header-${mode}`]: true,\n [`header-translucent`]: this.translucent,\n [`header-collapse-${collapse}`]: true,\n [`header-translucent-${mode}`]: this.translucent\n }\n }, inheritedAttributes), mode === 'ios' && translucent && h(\"div\", {\n key: '395766d4dcee3398bc91960db21f922095292f14',\n class: \"header-background\"\n }), h(\"slot\", {\n key: '09a67ece27b258ff1248805d43d92a49b2c6859a'\n }));\n }\n get el() {\n return this;\n }\n static get style() {\n return {\n ios: IonHeaderIosStyle0,\n md: IonHeaderMdStyle0\n };\n }\n}, [36, \"ion-header\", {\n \"collapse\": [1],\n \"translucent\": [4]\n}]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"ion-header\"];\n components.forEach(tagName => {\n switch (tagName) {\n case \"ion-header\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, Header);\n }\n break;\n }\n });\n}\nexport { Header as H, defineCustomElement as d };","map":{"version":3,"names":["readTask","writeTask","proxyCustomElement","HTMLElement","h","Host","g","getScrollElement","f","findIonContent","p","printIonContentErrorMsg","k","clamp","i","inheritAriaAttributes","hostContext","b","getIonMode","TRANSITION","cloneElement","tagName","getCachedEl","document","querySelector","clonedEl","createElement","classList","add","style","setProperty","body","appendChild","createHeaderIndex","headerEl","toolbars","querySelectorAll","el","Array","from","map","toolbar","ionTitleEl","background","shadowRoot","innerTitleEl","ionButtonsEl","handleContentScroll","scrollEl","scrollHeaderIndex","contentEl","scrollTop","scale","nativeRefresher","scaleLargeTitles","setToolbarBackgroundOpacity","opacity","collapse","undefined","removeProperty","toString","handleToolbarBorderIntersection","ev","mainHeaderIndex","isIntersecting","intersectionRatio","handleToolbarIntersection","event","intersection","intersectionRect","intersectionArea","width","height","rootArea","rootBounds","isPageHidden","leftDiff","Math","abs","left","boundingClientRect","rightDiff","right","isPageTransitioning","setHeaderActive","hasValidIntersection","x","y","headerIndex","active","remove","removeAttribute","setAttribute","transition","forEach","ionTitle","titleDiv","size","transform","handleHeaderFade","baseEl","condenseHeader","baseElHeight","clientHeight","fadeStart","distanceToStart","fadeDuration","headerIosCss","IonHeaderIosStyle0","headerMdCss","IonHeaderMdStyle0","Header","constructor","_this","this","__registerHost","inheritedAttributes","setupFadeHeader","_ref","_asyncToGenerator","contentScrollCallback","addEventListener","_x","_x2","apply","arguments","translucent","componentWillLoad","componentDidLoad","checkCollapsibleHeader","componentDidUpdate","disconnectedCallback","destroyCollapsibleHeader","_this2","mode","hasCondense","hasFade","pageEl","closest","title","setupCondenseHeader","intersectionObserver","disconnect","removeEventListener","collapsibleMainHeader","_this3","IntersectionObserver","headers","find","header","toolbarIntersection","root","threshold","observe","length","render","roleType","Object","assign","key","role","class","ios","md","defineCustomElement","customElements","components","get","define","H","d"],"sources":["F:/workspace/202226701027/huinongbao-app/node_modules/@ionic/core/components/header.js"],"sourcesContent":["/*!\n * (C) Ionic http://ionicframework.com - MIT License\n */\nimport { readTask, writeTask, proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';\nimport { g as getScrollElement, f as findIonContent, p as printIonContentErrorMsg } from './index8.js';\nimport { k as clamp, i as inheritAriaAttributes } from './helpers.js';\nimport { h as hostContext } from './theme.js';\nimport { b as getIonMode } from './ionic-global.js';\n\nconst TRANSITION = 'all 0.2s ease-in-out';\nconst cloneElement = (tagName) => {\n const getCachedEl = document.querySelector(`${tagName}.ion-cloned-element`);\n if (getCachedEl !== null) {\n return getCachedEl;\n }\n const clonedEl = document.createElement(tagName);\n clonedEl.classList.add('ion-cloned-element');\n clonedEl.style.setProperty('display', 'none');\n document.body.appendChild(clonedEl);\n return clonedEl;\n};\nconst createHeaderIndex = (headerEl) => {\n if (!headerEl) {\n return;\n }\n const toolbars = headerEl.querySelectorAll('ion-toolbar');\n return {\n el: headerEl,\n toolbars: Array.from(toolbars).map((toolbar) => {\n const ionTitleEl = toolbar.querySelector('ion-title');\n return {\n el: toolbar,\n background: toolbar.shadowRoot.querySelector('.toolbar-background'),\n ionTitleEl,\n innerTitleEl: ionTitleEl ? ionTitleEl.shadowRoot.querySelector('.toolbar-title') : null,\n ionButtonsEl: Array.from(toolbar.querySelectorAll('ion-buttons')),\n };\n }),\n };\n};\nconst handleContentScroll = (scrollEl, scrollHeaderIndex, contentEl) => {\n readTask(() => {\n const scrollTop = scrollEl.scrollTop;\n const scale = clamp(1, 1 + -scrollTop / 500, 1.1);\n // Native refresher should not cause titles to scale\n const nativeRefresher = contentEl.querySelector('ion-refresher.refresher-native');\n if (nativeRefresher === null) {\n writeTask(() => {\n scaleLargeTitles(scrollHeaderIndex.toolbars, scale);\n });\n }\n });\n};\nconst setToolbarBackgroundOpacity = (headerEl, opacity) => {\n /**\n * Fading in the backdrop opacity\n * should happen after the large title\n * has collapsed, so it is handled\n * by handleHeaderFade()\n */\n if (headerEl.collapse === 'fade') {\n return;\n }\n if (opacity === undefined) {\n headerEl.style.removeProperty('--opacity-scale');\n }\n else {\n headerEl.style.setProperty('--opacity-scale', opacity.toString());\n }\n};\nconst handleToolbarBorderIntersection = (ev, mainHeaderIndex, scrollTop) => {\n if (!ev[0].isIntersecting) {\n return;\n }\n /**\n * There is a bug in Safari where overflow scrolling on a non-body element\n * does not always reset the scrollTop position to 0 when letting go. It will\n * set to 1 once the rubber band effect has ended. This causes the background to\n * appear slightly on certain app setups.\n *\n * Additionally, we check if user is rubber banding (scrolling is negative)\n * as this can mean they are using pull to refresh. Once the refresher starts,\n * the content is transformed which can cause the intersection observer to erroneously\n * fire here as well.\n */\n const scale = ev[0].intersectionRatio > 0.9 || scrollTop <= 0 ? 0 : ((1 - ev[0].intersectionRatio) * 100) / 75;\n setToolbarBackgroundOpacity(mainHeaderIndex.el, scale === 1 ? undefined : scale);\n};\n/**\n * If toolbars are intersecting, hide the scrollable toolbar content\n * and show the primary toolbar content. If the toolbars are not intersecting,\n * hide the primary toolbar content and show the scrollable toolbar content\n */\nconst handleToolbarIntersection = (ev, // TODO(FW-2832): type (IntersectionObserverEntry[] triggers errors which should be sorted)\nmainHeaderIndex, scrollHeaderIndex, scrollEl) => {\n writeTask(() => {\n const scrollTop = scrollEl.scrollTop;\n handleToolbarBorderIntersection(ev, mainHeaderIndex, scrollTop);\n const event = ev[0];\n const intersection = event.intersectionRect;\n const intersectionArea = intersection.width * intersection.height;\n const rootArea = event.rootBounds.width * event.rootBounds.height;\n const isPageHidden = intersectionArea === 0 && rootArea === 0;\n const leftDiff = Math.abs(intersection.left - event.boundingClientRect.left);\n const rightDiff = Math.abs(intersection.right - event.boundingClientRect.right);\n const isPageTransitioning = intersectionArea > 0 && (leftDiff >= 5 || rightDiff >= 5);\n if (isPageHidden || isPageTransitioning) {\n return;\n }\n if (event.isIntersecting) {\n setHeaderActive(mainHeaderIndex, false);\n setHeaderActive(scrollHeaderIndex);\n }\n else {\n /**\n * There is a bug with IntersectionObserver on Safari\n * where `event.isIntersecting === false` when cancelling\n * a swipe to go back gesture. Checking the intersection\n * x, y, width, and height provides a workaround. This bug\n * does not happen when using Safari + Web Animations,\n * only Safari + CSS Animations.\n */\n const hasValidIntersection = (intersection.x === 0 && intersection.y === 0) || (intersection.width !== 0 && intersection.height !== 0);\n if (hasValidIntersection && scrollTop > 0) {\n setHeaderActive(mainHeaderIndex);\n setHeaderActive(scrollHeaderIndex, false);\n setToolbarBackgroundOpacity(mainHeaderIndex.el);\n }\n }\n });\n};\nconst setHeaderActive = (headerIndex, active = true) => {\n const headerEl = headerIndex.el;\n if (active) {\n headerEl.classList.remove('header-collapse-condense-inactive');\n headerEl.removeAttribute('aria-hidden');\n }\n else {\n headerEl.classList.add('header-collapse-condense-inactive');\n headerEl.setAttribute('aria-hidden', 'true');\n }\n};\nconst scaleLargeTitles = (toolbars = [], scale = 1, transition = false) => {\n toolbars.forEach((toolbar) => {\n const ionTitle = toolbar.ionTitleEl;\n const titleDiv = toolbar.innerTitleEl;\n if (!ionTitle || ionTitle.size !== 'large') {\n return;\n }\n titleDiv.style.transition = transition ? TRANSITION : '';\n titleDiv.style.transform = `scale3d(${scale}, ${scale}, 1)`;\n });\n};\nconst handleHeaderFade = (scrollEl, baseEl, condenseHeader) => {\n readTask(() => {\n const scrollTop = scrollEl.scrollTop;\n const baseElHeight = baseEl.clientHeight;\n const fadeStart = condenseHeader ? condenseHeader.clientHeight : 0;\n /**\n * If we are using fade header with a condense\n * header, then the toolbar backgrounds should\n * not begin to fade in until the condense\n * header has fully collapsed.\n *\n * Additionally, the main content should not\n * overflow out of the container until the\n * condense header has fully collapsed. When\n * using just the condense header the content\n * should overflow out of the container.\n */\n if (condenseHeader !== null && scrollTop < fadeStart) {\n baseEl.style.setProperty('--opacity-scale', '0');\n scrollEl.style.setProperty('clip-path', `inset(${baseElHeight}px 0px 0px 0px)`);\n return;\n }\n const distanceToStart = scrollTop - fadeStart;\n const fadeDuration = 10;\n const scale = clamp(0, distanceToStart / fadeDuration, 1);\n writeTask(() => {\n scrollEl.style.removeProperty('clip-path');\n baseEl.style.setProperty('--opacity-scale', scale.toString());\n });\n });\n};\n\nconst headerIosCss = \"ion-header{display:block;position:relative;-ms-flex-order:-1;order:-1;width:100%;z-index:10}ion-header ion-toolbar:first-of-type{padding-top:var(--ion-safe-area-top, 0)}.header-ios ion-toolbar:last-of-type{--border-width:0 0 0.55px}@supports ((-webkit-backdrop-filter: blur(0)) or (backdrop-filter: blur(0))){.header-background{left:0;right:0;top:0;bottom:0;position:absolute;-webkit-backdrop-filter:saturate(180%) blur(20px);backdrop-filter:saturate(180%) blur(20px)}.header-translucent-ios ion-toolbar{--opacity:.8}.header-collapse-condense-inactive .header-background{-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px)}}.header-ios.ion-no-border ion-toolbar:last-of-type{--border-width:0}.header-collapse-fade ion-toolbar{--opacity-scale:inherit}.header-collapse-condense{z-index:9}.header-collapse-condense ion-toolbar{position:-webkit-sticky;position:sticky;top:0}.header-collapse-condense ion-toolbar:first-of-type{padding-top:0px;z-index:1}.header-collapse-condense ion-toolbar{--background:var(--ion-background-color, #fff);z-index:0}.header-collapse-condense ion-toolbar:last-of-type{--border-width:0px}.header-collapse-condense ion-toolbar ion-searchbar{padding-top:0px;padding-bottom:13px}.header-collapse-main{--opacity-scale:1}.header-collapse-main ion-toolbar{--opacity-scale:inherit}.header-collapse-main ion-toolbar.in-toolbar ion-title,.header-collapse-main ion-toolbar.in-toolbar ion-buttons{-webkit-transition:all 0.2s ease-in-out;transition:all 0.2s ease-in-out}.header-collapse-condense-inactive:not(.header-collapse-condense) ion-toolbar.in-toolbar ion-title,.header-collapse-condense-inactive:not(.header-collapse-condense) ion-toolbar.in-toolbar ion-buttons.buttons-collapse{opacity:0;pointer-events:none}.header-collapse-condense-inactive.header-collapse-condense ion-toolbar.in-toolbar ion-title,.header-collapse-condense-inactive.header-collapse-condense ion-toolbar.in-toolbar ion-buttons.buttons-collapse{visibility:hidden}ion-header.header-ios:not(.header-collapse-main):has(~ion-content ion-header.header-ios[collapse=condense],~ion-content ion-header.header-ios.header-collapse-condense){opacity:0}\";\nconst IonHeaderIosStyle0 = headerIosCss;\n\nconst headerMdCss = \"ion-header{display:block;position:relative;-ms-flex-order:-1;order:-1;width:100%;z-index:10}ion-header ion-toolbar:first-of-type{padding-top:var(--ion-safe-area-top, 0)}.header-md{-webkit-box-shadow:0 2px 4px -1px rgba(0, 0, 0, 0.2), 0 4px 5px 0 rgba(0, 0, 0, 0.14), 0 1px 10px 0 rgba(0, 0, 0, 0.12);box-shadow:0 2px 4px -1px rgba(0, 0, 0, 0.2), 0 4px 5px 0 rgba(0, 0, 0, 0.14), 0 1px 10px 0 rgba(0, 0, 0, 0.12)}.header-collapse-condense{display:none}.header-md.ion-no-border{-webkit-box-shadow:none;box-shadow:none}\";\nconst IonHeaderMdStyle0 = headerMdCss;\n\nconst Header = /*@__PURE__*/ proxyCustomElement(class Header extends HTMLElement {\n constructor() {\n super();\n this.__registerHost();\n this.inheritedAttributes = {};\n this.setupFadeHeader = async (contentEl, condenseHeader) => {\n const scrollEl = (this.scrollEl = await getScrollElement(contentEl));\n /**\n * Handle fading of toolbars on scroll\n */\n this.contentScrollCallback = () => {\n handleHeaderFade(this.scrollEl, this.el, condenseHeader);\n };\n scrollEl.addEventListener('scroll', this.contentScrollCallback);\n handleHeaderFade(this.scrollEl, this.el, condenseHeader);\n };\n this.collapse = undefined;\n this.translucent = false;\n }\n componentWillLoad() {\n this.inheritedAttributes = inheritAriaAttributes(this.el);\n }\n componentDidLoad() {\n this.checkCollapsibleHeader();\n }\n componentDidUpdate() {\n this.checkCollapsibleHeader();\n }\n disconnectedCallback() {\n this.destroyCollapsibleHeader();\n }\n async checkCollapsibleHeader() {\n const mode = getIonMode(this);\n if (mode !== 'ios') {\n return;\n }\n const { collapse } = this;\n const hasCondense = collapse === 'condense';\n const hasFade = collapse === 'fade';\n this.destroyCollapsibleHeader();\n if (hasCondense) {\n const pageEl = this.el.closest('ion-app,ion-page,.ion-page,page-inner');\n const contentEl = pageEl ? findIonContent(pageEl) : null;\n // Cloned elements are always needed in iOS transition\n writeTask(() => {\n const title = cloneElement('ion-title');\n title.size = 'large';\n cloneElement('ion-back-button');\n });\n await this.setupCondenseHeader(contentEl, pageEl);\n }\n else if (hasFade) {\n const pageEl = this.el.closest('ion-app,ion-page,.ion-page,page-inner');\n const contentEl = pageEl ? findIonContent(pageEl) : null;\n if (!contentEl) {\n printIonContentErrorMsg(this.el);\n return;\n }\n const condenseHeader = contentEl.querySelector('ion-header[collapse=\"condense\"]');\n await this.setupFadeHeader(contentEl, condenseHeader);\n }\n }\n destroyCollapsibleHeader() {\n if (this.intersectionObserver) {\n this.intersectionObserver.disconnect();\n this.intersectionObserver = undefined;\n }\n if (this.scrollEl && this.contentScrollCallback) {\n this.scrollEl.removeEventListener('scroll', this.contentScrollCallback);\n this.contentScrollCallback = undefined;\n }\n if (this.collapsibleMainHeader) {\n this.collapsibleMainHeader.classList.remove('header-collapse-main');\n this.collapsibleMainHeader = undefined;\n }\n }\n async setupCondenseHeader(contentEl, pageEl) {\n if (!contentEl || !pageEl) {\n printIonContentErrorMsg(this.el);\n return;\n }\n if (typeof IntersectionObserver === 'undefined') {\n return;\n }\n this.scrollEl = await getScrollElement(contentEl);\n const headers = pageEl.querySelectorAll('ion-header');\n this.collapsibleMainHeader = Array.from(headers).find((header) => header.collapse !== 'condense');\n if (!this.collapsibleMainHeader) {\n return;\n }\n const mainHeaderIndex = createHeaderIndex(this.collapsibleMainHeader);\n const scrollHeaderIndex = createHeaderIndex(this.el);\n if (!mainHeaderIndex || !scrollHeaderIndex) {\n return;\n }\n setHeaderActive(mainHeaderIndex, false);\n setToolbarBackgroundOpacity(mainHeaderIndex.el, 0);\n /**\n * Handle interaction between toolbar collapse and\n * showing/hiding content in the primary ion-header\n * as well as progressively showing/hiding the main header\n * border as the top-most toolbar collapses or expands.\n */\n const toolbarIntersection = (ev) => {\n handleToolbarIntersection(ev, mainHeaderIndex, scrollHeaderIndex, this.scrollEl);\n };\n this.intersectionObserver = new IntersectionObserver(toolbarIntersection, {\n root: contentEl,\n threshold: [0.25, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1],\n });\n this.intersectionObserver.observe(scrollHeaderIndex.toolbars[scrollHeaderIndex.toolbars.length - 1].el);\n /**\n * Handle scaling of large iOS titles and\n * showing/hiding border on last toolbar\n * in primary header\n */\n this.contentScrollCallback = () => {\n handleContentScroll(this.scrollEl, scrollHeaderIndex, contentEl);\n };\n this.scrollEl.addEventListener('scroll', this.contentScrollCallback);\n writeTask(() => {\n if (this.collapsibleMainHeader !== undefined) {\n this.collapsibleMainHeader.classList.add('header-collapse-main');\n }\n });\n }\n render() {\n const { translucent, inheritedAttributes } = this;\n const mode = getIonMode(this);\n const collapse = this.collapse || 'none';\n // banner role must be at top level, so remove role if inside a menu\n const roleType = hostContext('ion-menu', this.el) ? 'none' : 'banner';\n return (h(Host, Object.assign({ key: 'b6cc27f0b08afc9fcc889683525da765d80ba672', role: roleType, class: {\n [mode]: true,\n // Used internally for styling\n [`header-${mode}`]: true,\n [`header-translucent`]: this.translucent,\n [`header-collapse-${collapse}`]: true,\n [`header-translucent-${mode}`]: this.translucent,\n } }, inheritedAttributes), mode === 'ios' && translucent && h(\"div\", { key: '395766d4dcee3398bc91960db21f922095292f14', class: \"header-background\" }), h(\"slot\", { key: '09a67ece27b258ff1248805d43d92a49b2c6859a' })));\n }\n get el() { return this; }\n static get style() { return {\n ios: IonHeaderIosStyle0,\n md: IonHeaderMdStyle0\n }; }\n}, [36, \"ion-header\", {\n \"collapse\": [1],\n \"translucent\": [4]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"ion-header\"];\n components.forEach(tagName => { switch (tagName) {\n case \"ion-header\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, Header);\n }\n break;\n } });\n}\n\nexport { Header as H, defineCustomElement as d };\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,QAAQ,EAAEC,SAAS,EAAEC,kBAAkB,EAAEC,WAAW,EAAEC,CAAC,EAAEC,IAAI,QAAQ,+BAA+B;AAC7G,SAASC,CAAC,IAAIC,gBAAgB,EAAEC,CAAC,IAAIC,cAAc,EAAEC,CAAC,IAAIC,uBAAuB,QAAQ,aAAa;AACtG,SAASC,CAAC,IAAIC,KAAK,EAAEC,CAAC,IAAIC,qBAAqB,QAAQ,cAAc;AACrE,SAASX,CAAC,IAAIY,WAAW,QAAQ,YAAY;AAC7C,SAASC,CAAC,IAAIC,UAAU,QAAQ,mBAAmB;AAEnD,MAAMC,UAAU,GAAG,sBAAsB;AACzC,MAAMC,YAAY,GAAIC,OAAO,IAAK;EAC9B,MAAMC,WAAW,GAAGC,QAAQ,CAACC,aAAa,CAAC,GAAGH,OAAO,qBAAqB,CAAC;EAC3E,IAAIC,WAAW,KAAK,IAAI,EAAE;IACtB,OAAOA,WAAW;EACtB;EACA,MAAMG,QAAQ,GAAGF,QAAQ,CAACG,aAAa,CAACL,OAAO,CAAC;EAChDI,QAAQ,CAACE,SAAS,CAACC,GAAG,CAAC,oBAAoB,CAAC;EAC5CH,QAAQ,CAACI,KAAK,CAACC,WAAW,CAAC,SAAS,EAAE,MAAM,CAAC;EAC7CP,QAAQ,CAACQ,IAAI,CAACC,WAAW,CAACP,QAAQ,CAAC;EACnC,OAAOA,QAAQ;AACnB,CAAC;AACD,MAAMQ,iBAAiB,GAAIC,QAAQ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