@ionic/core 8.6.3-dev.11751378808.12cc4a5c → 8.6.3-dev.11751478001.1cb7436f

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/components/focus-visible.js +27 -18
  2. package/components/ion-select.js +3 -3
  3. package/components/modal.js +8 -220
  4. package/dist/cjs/{focus-visible-CCvKiLh3.js → focus-visible-ZV7jHMPt.js} +27 -18
  5. package/dist/cjs/ion-app_8.cjs.entry.js +1 -1
  6. package/dist/cjs/ion-datetime_3.cjs.entry.js +1 -1
  7. package/dist/cjs/ion-modal.cjs.entry.js +8 -220
  8. package/dist/cjs/ion-select_3.cjs.entry.js +3 -3
  9. package/dist/collection/components/modal/animations/ios.enter.js +2 -2
  10. package/dist/collection/components/modal/animations/ios.leave.js +2 -2
  11. package/dist/collection/components/modal/modal.js +4 -87
  12. package/dist/collection/components/select/select.js +3 -3
  13. package/dist/collection/utils/focus-visible.js +27 -18
  14. package/dist/docs.json +1 -1
  15. package/dist/esm/{focus-visible-BmVRXR1y.js → focus-visible-DZ2gZBzK.js} +27 -18
  16. package/dist/esm/ion-app_8.entry.js +1 -1
  17. package/dist/esm/ion-datetime_3.entry.js +1 -1
  18. package/dist/esm/ion-modal.entry.js +8 -220
  19. package/dist/esm/ion-select_3.entry.js +3 -3
  20. package/dist/ionic/ionic.esm.js +1 -1
  21. package/dist/ionic/{p-01123ecf.entry.js → p-2d46fbe7.entry.js} +1 -1
  22. package/dist/ionic/{p-5f671887.entry.js → p-78a61b3f.entry.js} +1 -1
  23. package/dist/ionic/p-7d5cf8c1.entry.js +4 -0
  24. package/dist/ionic/p-9e32212d.entry.js +4 -0
  25. package/dist/ionic/p-DZ2gZBzK.js +4 -0
  26. package/dist/types/components/modal/modal.d.ts +0 -6
  27. package/hydrate/index.js +38 -241
  28. package/hydrate/index.mjs +38 -241
  29. package/package.json +1 -1
  30. package/dist/collection/components/modal/animations/ios.transition.js +0 -143
  31. package/dist/ionic/p-4ddc10ef.entry.js +0 -4
  32. package/dist/ionic/p-6f74a187.entry.js +0 -4
  33. package/dist/ionic/p-BmVRXR1y.js +0 -4
  34. package/dist/types/components/modal/animations/ios.transition.d.ts +0 -14
@@ -0,0 +1,4 @@
1
+ /*!
2
+ * (C) Ionic http://ionicframework.com - MIT License
3
+ */
4
+ import{r as e,d as t,m as i,e as o,h as l,j as s,k as r,n as a}from"./p-B_U9CtaY.js";import{c as n}from"./p-ei_RiGrl.js";import{i as c,c as d}from"./p-sObYyvOy.js";import{b as p,a as h,n as b}from"./p-Do-uqmtX.js";import{c as m,b as g,a as f,m as u,s as x}from"./p-aIxOGKys.js";import{i as v}from"./p-C53feagD.js";import{h as w,c as k,g as y}from"./p-DiVJyqlX.js";import{w as j}from"./p-Dtdm8lKC.js";import{w as z,q as C}from"./p-BLV6ykCk.js";import"./p-ZjP4CjeZ.js";import"./p-DzH0J0yi.js";import"./p-BhLqfMrf.js";import"./p-BTEOs1at.js";const O=class{constructor(i){e(this,i),this.ionChange=t(this,"ionChange",7),this.ionCancel=t(this,"ionCancel",7),this.ionDismiss=t(this,"ionDismiss",7),this.ionFocus=t(this,"ionFocus",7),this.ionBlur=t(this,"ionBlur",7),this.ionStyle=t(this,"ionStyle",7),this.inputId="ion-sel-"+A++,this.helperTextId=`${this.inputId}-helper-text`,this.errorTextId=`${this.inputId}-error-text`,this.inheritedAttributes={},this.isExpanded=!1,this.hasFocus=!1,this.cancelText="Cancel",this.disabled=!1,this.interface="alert",this.interfaceOptions={},this.labelPlacement="start",this.multiple=!1,this.name=this.inputId,this.okText="OK",this.required=!1,this.onClick=e=>{const t=e.target,i=t.closest('[slot="start"], [slot="end"]');t===this.el||null===i?(this.setFocus(),this.open(e)):e.preventDefault()},this.onFocus=()=>{this.hasFocus=!0,this.ionFocus.emit()},this.onBlur=()=>{this.hasFocus=!1,this.ionBlur.emit()},this.onLabelClick=e=>{e.target===e.currentTarget&&e.stopPropagation()}}styleChanged(){this.emitStyle()}setValue(e){this.value=e,this.ionChange.emit({value:e})}async connectedCallback(){const{el:e}=this;this.notchController=n(e,(()=>this.notchSpacerEl),(()=>this.labelSlot)),this.updateOverlayOptions(),this.emitStyle(),this.mutationO=j(this.el,"ion-select-option",(async()=>{this.updateOverlayOptions(),a(this)}))}componentWillLoad(){this.inheritedAttributes=p(this.el,["aria-label"])}componentDidLoad(){this.emitStyle()}disconnectedCallback(){this.mutationO&&(this.mutationO.disconnect(),this.mutationO=void 0),this.notchController&&(this.notchController.destroy(),this.notchController=void 0)}async open(e){if(this.disabled||this.isExpanded)return;this.isExpanded=!0;const t=this.overlay=await this.createOverlay(e),i=()=>{const e=this.childOpts.findIndex((e=>e.value===this.value));if(e>-1){const i=t.querySelector(`.select-interface-option:nth-of-type(${e+1})`);if(i){const e=i.querySelector("ion-radio, ion-checkbox");e&&(i.scrollIntoView({block:"nearest"}),e.setFocus()),b(i)}}else{const e=t.querySelector("ion-radio:not(.radio-disabled), ion-checkbox:not(.checkbox-disabled)");e&&(e.setFocus(),b(e.closest("ion-item")))}};if("modal"===this.interface)t.addEventListener("ionModalWillPresent",i,{once:!0});else if("popover"===this.interface)t.addEventListener("ionPopoverWillPresent",i,{once:!0});else{const e=()=>{requestAnimationFrame((()=>{i()}))};"alert"===this.interface?t.addEventListener("ionAlertWillPresent",e,{once:!0}):"action-sheet"===this.interface&&t.addEventListener("ionActionSheetWillPresent",e,{once:!0})}return t.onDidDismiss().then((()=>{this.overlay=void 0,this.isExpanded=!1,this.ionDismiss.emit(),this.setFocus()})),await t.present(),t}createOverlay(e){let t=this.interface;return"action-sheet"===t&&this.multiple&&(i(`[ion-select] - Interface cannot be "${t}" with a multi-value select. Using the "alert" interface instead.`),t="alert"),"popover"!==t||e||(i(`[ion-select] - Interface cannot be a "${t}" without passing an event. Using the "alert" interface instead.`),t="alert"),"action-sheet"===t?this.openActionSheet():"popover"===t?this.openPopover(e):"modal"===t?this.openModal():this.openAlert()}updateOverlayOptions(){const e=this.overlay;if(!e)return;const t=this.childOpts,i=this.value;switch(this.interface){case"action-sheet":e.buttons=this.createActionSheetButtons(t,i);break;case"popover":const o=e.querySelector("ion-select-popover");o&&(o.options=this.createOverlaySelectOptions(t,i));break;case"modal":const l=e.querySelector("ion-select-modal");l&&(l.options=this.createOverlaySelectOptions(t,i));break;case"alert":e.inputs=this.createAlertInputs(t,this.multiple?"checkbox":"radio",i)}}createActionSheetButtons(e,t){const i=e.map((e=>{const i=$(e),o=Array.from(e.classList).filter((e=>"hydrated"!==e)).join(" "),l=`${Y} ${o}`;return{role:c(t,i,this.compareWith)?"selected":"",text:e.textContent,cssClass:l,handler:()=>{this.setValue(i)}}}));return i.push({text:this.cancelText,role:"cancel",handler:()=>{this.ionCancel.emit()}}),i}createAlertInputs(e,t,i){return e.map((e=>{const o=$(e),l=Array.from(e.classList).filter((e=>"hydrated"!==e)).join(" ");return{type:t,cssClass:`${Y} ${l}`,label:e.textContent||"",value:o,checked:c(i,o,this.compareWith),disabled:e.disabled}}))}createOverlaySelectOptions(e,t){return e.map((e=>{const i=$(e),o=Array.from(e.classList).filter((e=>"hydrated"!==e)).join(" ");return{text:e.textContent||"",cssClass:`${Y} ${o}`,value:i,checked:c(t,i,this.compareWith),disabled:e.disabled,handler:e=>{this.setValue(e),this.multiple||this.close()}}}))}async openPopover(e){const{fill:t,labelPlacement:i}=this,l=this.interfaceOptions,s=o(this),r="md"!==s,a=this.multiple,n=this.value;let c=e,d="auto";"floating"===i||"stacked"===i||"md"===s&&void 0!==t?d="cover":c=Object.assign(Object.assign({},e),{detail:{ionShadowTarget:this.nativeWrapperEl}});const p=Object.assign(Object.assign({mode:s,event:c,alignment:"center",size:d,showBackdrop:r},l),{component:"ion-select-popover",cssClass:["select-popover",l.cssClass],componentProps:{header:l.header,subHeader:l.subHeader,message:l.message,multiple:a,value:n,options:this.createOverlaySelectOptions(this.childOpts,n)}});return m.create(p)}async openActionSheet(){const e=o(this),t=this.interfaceOptions,i=Object.assign(Object.assign({mode:e},t),{buttons:this.createActionSheetButtons(this.childOpts,this.value),cssClass:["select-action-sheet",t.cssClass]});return g.create(i)}async openAlert(){const e=this.interfaceOptions,t=this.multiple?"checkbox":"radio",i=o(this),l=Object.assign(Object.assign({mode:i},e),{header:e.header?e.header:this.labelText,inputs:this.createAlertInputs(this.childOpts,t,this.value),buttons:[{text:this.cancelText,role:"cancel",handler:()=>{this.ionCancel.emit()}},{text:this.okText,handler:e=>{this.setValue(e)}}],cssClass:["select-alert",e.cssClass,this.multiple?"multiple-select-alert":"single-select-alert"]});return f.create(l)}openModal(){const{multiple:e,value:t,interfaceOptions:i}=this,l=o(this),s=Object.assign(Object.assign({},i),{mode:l,cssClass:["select-modal",i.cssClass],component:"ion-select-modal",componentProps:{header:i.header,multiple:e,value:t,options:this.createOverlaySelectOptions(this.childOpts,t)}});return u.create(s)}close(){return this.overlay?this.overlay.dismiss():Promise.resolve(!1)}hasValue(){return""!==this.getText()}get childOpts(){return Array.from(this.el.querySelectorAll("ion-select-option"))}get labelText(){const{label:e}=this;if(void 0!==e)return e;const{labelSlot:t}=this;return null!==t?t.textContent:void 0}getText(){const e=this.selectedText;return null!=e&&""!==e?e:I(this.childOpts,this.value,this.compareWith)}setFocus(){this.focusEl&&this.focusEl.focus()}emitStyle(){const{disabled:e}=this;this.ionStyle.emit({"interactive-disabled":e})}renderLabel(){const{label:e}=this;return l("div",{class:{"label-text-wrapper":!0,"label-text-wrapper-hidden":!this.hasLabel},part:"label"},void 0===e?l("slot",{name:"label"}):l("div",{class:"label-text"},e))}componentDidRender(){var e;null===(e=this.notchController)||void 0===e||e.calculateNotchWidth()}get labelSlot(){return this.el.querySelector('[slot="label"]')}get hasLabel(){return void 0!==this.label||null!==this.labelSlot}renderLabelContainer(){return"md"===o(this)&&"outline"===this.fill?[l("div",{class:"select-outline-container"},l("div",{class:"select-outline-start"}),l("div",{class:{"select-outline-notch":!0,"select-outline-notch-hidden":!this.hasLabel}},l("div",{class:"notch-spacer","aria-hidden":"true",ref:e=>this.notchSpacerEl=e},this.label)),l("div",{class:"select-outline-end"})),this.renderLabel()]:this.renderLabel()}renderSelectText(){const{placeholder:e}=this;let t=!1,i=this.getText();return""===i&&void 0!==e&&(i=e,t=!0),l("div",{"aria-hidden":"true",class:{"select-text":!0,"select-placeholder":t},part:t?"placeholder":"text"},i)}renderSelectIcon(){const e=o(this),{isExpanded:t,toggleIcon:i,expandedIcon:s}=this;let r;return r=t&&void 0!==s?s:null!=i?i:"ios"===e?z:C,l("ion-icon",{class:"select-icon",part:"icon","aria-hidden":"true",icon:r})}get ariaLabel(){var e;const{placeholder:t,inheritedAttributes:i}=this,o=this.getText(),l=null!==(e=i["aria-label"])&&void 0!==e?e:this.labelText;let s=o;return""===s&&void 0!==t&&(s=t),void 0!==l&&(s=""===s?l:`${l}, ${s}`),s}renderListbox(){const{disabled:e,inputId:t,isExpanded:i,required:o}=this;return l("button",{disabled:e,id:t,"aria-label":this.ariaLabel,"aria-haspopup":"dialog","aria-expanded":`${i}`,"aria-describedby":this.getHintTextID(),"aria-invalid":this.getHintTextID()===this.errorTextId,"aria-required":`${o}`,onFocus:this.onFocus,onBlur:this.onBlur,ref:e=>this.focusEl=e})}getHintTextID(){const{el:e,helperText:t,errorText:i,helperTextId:o,errorTextId:l}=this;return e.classList.contains("ion-touched")&&e.classList.contains("ion-invalid")&&i?l:t?o:void 0}renderHintText(){const{helperText:e,errorText:t,helperTextId:i,errorTextId:o}=this;return[l("div",{id:i,class:"helper-text",part:"supporting-text helper-text"},e),l("div",{id:o,class:"error-text",part:"supporting-text error-text"},t)]}renderBottomContent(){const{helperText:e,errorText:t}=this;if(e||t)return l("div",{class:"select-bottom"},this.renderHintText())}render(){const{disabled:e,el:t,isExpanded:i,expandedIcon:r,labelPlacement:a,justify:n,placeholder:c,fill:d,shape:p,name:b,value:m,hasFocus:g}=this,f=o(this),u="floating"===a||"stacked"===a,x=!u&&void 0!==n,y=v(t)?"rtl":"ltr",j=w("ion-item",this.el),z="md"===f&&"outline"!==d&&!j,C=this.hasValue(),O=null!==t.querySelector('[slot="start"], [slot="end"]');h(!0,t,b,T(m),e);const $="stacked"===a||"floating"===a&&(C||i||O);return l(s,{key:"c03fb65e8fc9f9aab295e07b282377d57d910519",onClick:this.onClick,class:k(this.color,{[f]:!0,"in-item":j,"in-item-color":w("ion-item.ion-color",t),"select-disabled":e,"select-expanded":i,"has-expanded-icon":void 0!==r,"has-value":C,"label-floating":$,"has-placeholder":void 0!==c,"has-focus":g,"ion-focusable":!0,[`select-${y}`]:!0,[`select-fill-${d}`]:void 0!==d,[`select-justify-${n}`]:x,[`select-shape-${p}`]:void 0!==p,[`select-label-placement-${a}`]:!0})},l("label",{key:"0d0c8ec55269adcac625f2899a547f4e7f3e3741",class:"select-wrapper",id:"select-label",onClick:this.onLabelClick},this.renderLabelContainer(),l("div",{key:"f6dfc93c0e23cbe75a2947abde67d842db2dad78",class:"select-wrapper-inner"},l("slot",{key:"957bfadf9f101f519091419a362d3abdc2be66f6",name:"start"}),l("div",{key:"ca349202a484e7f2e884533fd330f0b136754f7d",class:"native-wrapper",ref:e=>this.nativeWrapperEl=e,part:"container"},this.renderSelectText(),this.renderListbox()),l("slot",{key:"f0e62a6533ff1c8f62bd2d27f60b23385c4fa9ed",name:"end"}),!u&&this.renderSelectIcon()),u&&this.renderSelectIcon(),z&&l("div",{key:"fb840d46bafafb09898ebeebbe8c181906a3d8a2",class:"select-highlight"})),this.renderBottomContent())}get el(){return r(this)}static get watchers(){return{disabled:["styleChanged"],isExpanded:["styleChanged"],placeholder:["styleChanged"],value:["styleChanged"]}}},$=e=>{const t=e.value;return void 0===t?e.textContent||"":t},T=e=>{if(null!=e)return Array.isArray(e)?e.join(","):e.toString()},I=(e,t,i)=>void 0===t?"":Array.isArray(t)?t.map((t=>P(e,t,i))).filter((e=>null!==e)).join(", "):P(e,t,i)||"",P=(e,t,i)=>{const o=e.find((e=>d(t,$(e),i)));return o?o.textContent:null};let A=0;const Y="select-interface-option";O.style={ios:":host{--padding-top:0px;--padding-end:0px;--padding-bottom:0px;--padding-start:0px;--placeholder-color:currentColor;--placeholder-opacity:var(--ion-placeholder-opacity, 0.6);--background:transparent;--border-style:solid;--highlight-color-focused:var(--ion-color-primary, #0054e9);--highlight-color-valid:var(--ion-color-success, #2dd55b);--highlight-color-invalid:var(--ion-color-danger, #c5000f);--highlight-color:var(--highlight-color-focused);display:block;position:relative;width:100%;min-height:44px;font-family:var(--ion-font-family, inherit);white-space:nowrap;cursor:pointer;z-index:2}:host(.select-label-placement-floating),:host(.select-label-placement-stacked){min-height:56px}:host(.ion-color){--highlight-color-focused:var(--ion-color-base)}:host(.in-item){-ms-flex:1 1 0px;flex:1 1 0}:host(.select-disabled){pointer-events:none}:host(.has-focus) button{border:2px solid #5e9ed6}:host([slot=start]),:host([slot=end]){-ms-flex:initial;flex:initial;width:auto}.select-placeholder{color:var(--placeholder-color);opacity:var(--placeholder-opacity)}button{position:absolute;top:0;left:0;right:0;bottom:0;width:100%;height:100%;margin:0;padding:0;border:0;outline:0;clip:rect(0 0 0 0);opacity:0;overflow:hidden;-webkit-appearance:none;-moz-appearance:none}.select-icon{-webkit-margin-start:4px;margin-inline-start:4px;-webkit-margin-end:0;margin-inline-end:0;margin-top:0;margin-bottom:0;position:relative;-ms-flex-negative:0;flex-shrink:0}:host(.in-item-color) .select-icon{color:inherit}:host(.select-label-placement-stacked) .select-icon,:host(.select-label-placement-floating) .select-icon{position:absolute;height:100%}:host(.select-ltr.select-label-placement-stacked) .select-icon,:host(.select-ltr.select-label-placement-floating) .select-icon{right:var(--padding-end, 0)}:host(.select-rtl.select-label-placement-stacked) .select-icon,:host(.select-rtl.select-label-placement-floating) .select-icon{left:var(--padding-start, 0)}.select-text{-ms-flex:1;flex:1;min-width:16px;font-size:inherit;text-overflow:ellipsis;white-space:inherit;overflow:hidden}.select-wrapper{-webkit-padding-start:var(--padding-start);padding-inline-start:var(--padding-start);-webkit-padding-end:var(--padding-end);padding-inline-end:var(--padding-end);padding-top:var(--padding-top);padding-bottom:var(--padding-bottom);border-radius:var(--border-radius);display:-ms-flexbox;display:flex;position:relative;-ms-flex-positive:1;flex-grow:1;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;height:inherit;min-height:inherit;-webkit-transition:background-color 15ms linear;transition:background-color 15ms linear;background:var(--background);line-height:normal;cursor:inherit;-webkit-box-sizing:border-box;box-sizing:border-box}.select-wrapper .select-placeholder{-webkit-transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1)}.select-wrapper-inner{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;overflow:hidden}:host(.select-label-placement-stacked) .select-wrapper-inner,:host(.select-label-placement-floating) .select-wrapper-inner{-ms-flex-positive:1;flex-grow:1}:host(.ion-touched.ion-invalid){--highlight-color:var(--highlight-color-invalid)}:host(.ion-valid){--highlight-color:var(--highlight-color-valid)}.select-bottom{-webkit-padding-start:var(--padding-start);padding-inline-start:var(--padding-start);-webkit-padding-end:var(--padding-end);padding-inline-end:var(--padding-end);padding-top:5px;padding-bottom:0;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;border-top:var(--border-width) var(--border-style) var(--border-color);font-size:0.75rem;white-space:normal}:host(.has-focus.ion-valid),:host(.select-expanded.ion-valid),:host(.ion-touched.ion-invalid),:host(.select-expanded.ion-touched.ion-invalid){--border-color:var(--highlight-color)}.select-bottom .error-text{display:none;color:var(--highlight-color-invalid)}.select-bottom .helper-text{display:block;color:var(--ion-color-step-700, var(--ion-text-color-step-300, #4d4d4d))}:host(.ion-touched.ion-invalid) .select-bottom .error-text{display:block}:host(.ion-touched.ion-invalid) .select-bottom .helper-text{display:none}.label-text-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;max-width:200px;-webkit-transition:color 150ms cubic-bezier(0.4, 0, 0.2, 1), -webkit-transform 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:color 150ms cubic-bezier(0.4, 0, 0.2, 1), -webkit-transform 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:color 150ms cubic-bezier(0.4, 0, 0.2, 1), transform 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:color 150ms cubic-bezier(0.4, 0, 0.2, 1), transform 150ms cubic-bezier(0.4, 0, 0.2, 1), -webkit-transform 150ms cubic-bezier(0.4, 0, 0.2, 1);pointer-events:none}.label-text,::slotted([slot=label]){text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.label-text-wrapper-hidden,.select-outline-notch-hidden{display:none}.native-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-webkit-transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);overflow:hidden}:host(.select-justify-space-between) .select-wrapper{-ms-flex-pack:justify;justify-content:space-between}:host(.select-justify-start) .select-wrapper{-ms-flex-pack:start;justify-content:start}:host(.select-justify-end) .select-wrapper{-ms-flex-pack:end;justify-content:end}:host(.select-label-placement-start) .select-wrapper{-ms-flex-direction:row;flex-direction:row}:host(.select-label-placement-start) .label-text-wrapper{-webkit-margin-start:0;margin-inline-start:0;-webkit-margin-end:16px;margin-inline-end:16px;margin-top:0;margin-bottom:0}:host(.select-label-placement-end) .select-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host(.select-label-placement-end) .label-text-wrapper{-webkit-margin-start:16px;margin-inline-start:16px;-webkit-margin-end:0;margin-inline-end:0;margin-top:0;margin-bottom:0}:host(.select-label-placement-fixed) .label-text-wrapper{-webkit-margin-start:0;margin-inline-start:0;-webkit-margin-end:16px;margin-inline-end:16px;margin-top:0;margin-bottom:0}:host(.select-label-placement-fixed) .label-text-wrapper{-ms-flex:0 0 100px;flex:0 0 100px;width:100px;min-width:100px;max-width:200px}:host(.select-label-placement-stacked) .select-wrapper,:host(.select-label-placement-floating) .select-wrapper{-ms-flex-direction:column;flex-direction:column;-ms-flex-align:start;align-items:start}:host(.select-label-placement-stacked) .label-text-wrapper,:host(.select-label-placement-floating) .label-text-wrapper{max-width:100%}:host(.select-ltr.select-label-placement-stacked) .label-text-wrapper,:host(.select-ltr.select-label-placement-floating) .label-text-wrapper{-webkit-transform-origin:left top;transform-origin:left top}:host(.select-rtl.select-label-placement-stacked) .label-text-wrapper,:host(.select-rtl.select-label-placement-floating) .label-text-wrapper{-webkit-transform-origin:right top;transform-origin:right top}:host(.select-label-placement-stacked) .native-wrapper,:host(.select-label-placement-floating) .native-wrapper{margin-left:0;margin-right:0;margin-top:1px;margin-bottom:0;-ms-flex-positive:1;flex-grow:1;width:100%}:host(.select-label-placement-floating) .label-text-wrapper{-webkit-transform:translateY(100%) scale(1);transform:translateY(100%) scale(1)}:host(.select-label-placement-floating:not(.label-floating)) .native-wrapper .select-placeholder{opacity:0}:host(.select-expanded.select-label-placement-floating) .native-wrapper .select-placeholder,:host(.has-focus.select-label-placement-floating) .native-wrapper .select-placeholder,:host(.has-value.select-label-placement-floating) .native-wrapper .select-placeholder{opacity:1}:host(.label-floating) .label-text-wrapper{-webkit-transform:translateY(50%) scale(0.75);transform:translateY(50%) scale(0.75);max-width:calc(100% / 0.75)}::slotted([slot=start]),::slotted([slot=end]){-ms-flex-negative:0;flex-shrink:0}::slotted([slot=start]:last-of-type){-webkit-margin-end:16px;margin-inline-end:16px;-webkit-margin-start:0;margin-inline-start:0}::slotted([slot=end]:first-of-type){-webkit-margin-start:16px;margin-inline-start:16px;-webkit-margin-end:0;margin-inline-end:0}:host{--border-width:0.55px;--border-color:var(--ion-item-border-color, var(--ion-border-color, var(--ion-color-step-250, var(--ion-background-color-step-250, #c8c7cc))));--highlight-height:0px}.select-icon{width:1.125rem;height:1.125rem;color:var(--ion-color-step-650, var(--ion-text-color-step-350, #595959))}:host(.select-label-placement-stacked) .select-wrapper-inner,:host(.select-label-placement-floating) .select-wrapper-inner{width:calc(100% - 1.125rem - 4px)}:host(.select-disabled){opacity:0.3}::slotted(ion-button[slot=start].button-has-icon-only),::slotted(ion-button[slot=end].button-has-icon-only){--border-radius:50%;--padding-start:0;--padding-end:0;--padding-top:0;--padding-bottom:0;aspect-ratio:1}",md:":host{--padding-top:0px;--padding-end:0px;--padding-bottom:0px;--padding-start:0px;--placeholder-color:currentColor;--placeholder-opacity:var(--ion-placeholder-opacity, 0.6);--background:transparent;--border-style:solid;--highlight-color-focused:var(--ion-color-primary, #0054e9);--highlight-color-valid:var(--ion-color-success, #2dd55b);--highlight-color-invalid:var(--ion-color-danger, #c5000f);--highlight-color:var(--highlight-color-focused);display:block;position:relative;width:100%;min-height:44px;font-family:var(--ion-font-family, inherit);white-space:nowrap;cursor:pointer;z-index:2}:host(.select-label-placement-floating),:host(.select-label-placement-stacked){min-height:56px}:host(.ion-color){--highlight-color-focused:var(--ion-color-base)}:host(.in-item){-ms-flex:1 1 0px;flex:1 1 0}:host(.select-disabled){pointer-events:none}:host(.has-focus) button{border:2px solid #5e9ed6}:host([slot=start]),:host([slot=end]){-ms-flex:initial;flex:initial;width:auto}.select-placeholder{color:var(--placeholder-color);opacity:var(--placeholder-opacity)}button{position:absolute;top:0;left:0;right:0;bottom:0;width:100%;height:100%;margin:0;padding:0;border:0;outline:0;clip:rect(0 0 0 0);opacity:0;overflow:hidden;-webkit-appearance:none;-moz-appearance:none}.select-icon{-webkit-margin-start:4px;margin-inline-start:4px;-webkit-margin-end:0;margin-inline-end:0;margin-top:0;margin-bottom:0;position:relative;-ms-flex-negative:0;flex-shrink:0}:host(.in-item-color) .select-icon{color:inherit}:host(.select-label-placement-stacked) .select-icon,:host(.select-label-placement-floating) .select-icon{position:absolute;height:100%}:host(.select-ltr.select-label-placement-stacked) .select-icon,:host(.select-ltr.select-label-placement-floating) .select-icon{right:var(--padding-end, 0)}:host(.select-rtl.select-label-placement-stacked) .select-icon,:host(.select-rtl.select-label-placement-floating) .select-icon{left:var(--padding-start, 0)}.select-text{-ms-flex:1;flex:1;min-width:16px;font-size:inherit;text-overflow:ellipsis;white-space:inherit;overflow:hidden}.select-wrapper{-webkit-padding-start:var(--padding-start);padding-inline-start:var(--padding-start);-webkit-padding-end:var(--padding-end);padding-inline-end:var(--padding-end);padding-top:var(--padding-top);padding-bottom:var(--padding-bottom);border-radius:var(--border-radius);display:-ms-flexbox;display:flex;position:relative;-ms-flex-positive:1;flex-grow:1;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;height:inherit;min-height:inherit;-webkit-transition:background-color 15ms linear;transition:background-color 15ms linear;background:var(--background);line-height:normal;cursor:inherit;-webkit-box-sizing:border-box;box-sizing:border-box}.select-wrapper .select-placeholder{-webkit-transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1)}.select-wrapper-inner{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;overflow:hidden}:host(.select-label-placement-stacked) .select-wrapper-inner,:host(.select-label-placement-floating) .select-wrapper-inner{-ms-flex-positive:1;flex-grow:1}:host(.ion-touched.ion-invalid){--highlight-color:var(--highlight-color-invalid)}:host(.ion-valid){--highlight-color:var(--highlight-color-valid)}.select-bottom{-webkit-padding-start:var(--padding-start);padding-inline-start:var(--padding-start);-webkit-padding-end:var(--padding-end);padding-inline-end:var(--padding-end);padding-top:5px;padding-bottom:0;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;border-top:var(--border-width) var(--border-style) var(--border-color);font-size:0.75rem;white-space:normal}:host(.has-focus.ion-valid),:host(.select-expanded.ion-valid),:host(.ion-touched.ion-invalid),:host(.select-expanded.ion-touched.ion-invalid){--border-color:var(--highlight-color)}.select-bottom .error-text{display:none;color:var(--highlight-color-invalid)}.select-bottom .helper-text{display:block;color:var(--ion-color-step-700, var(--ion-text-color-step-300, #4d4d4d))}:host(.ion-touched.ion-invalid) .select-bottom .error-text{display:block}:host(.ion-touched.ion-invalid) .select-bottom .helper-text{display:none}.label-text-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;max-width:200px;-webkit-transition:color 150ms cubic-bezier(0.4, 0, 0.2, 1), -webkit-transform 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:color 150ms cubic-bezier(0.4, 0, 0.2, 1), -webkit-transform 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:color 150ms cubic-bezier(0.4, 0, 0.2, 1), transform 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:color 150ms cubic-bezier(0.4, 0, 0.2, 1), transform 150ms cubic-bezier(0.4, 0, 0.2, 1), -webkit-transform 150ms cubic-bezier(0.4, 0, 0.2, 1);pointer-events:none}.label-text,::slotted([slot=label]){text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.label-text-wrapper-hidden,.select-outline-notch-hidden{display:none}.native-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-webkit-transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);transition:opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);overflow:hidden}:host(.select-justify-space-between) .select-wrapper{-ms-flex-pack:justify;justify-content:space-between}:host(.select-justify-start) .select-wrapper{-ms-flex-pack:start;justify-content:start}:host(.select-justify-end) .select-wrapper{-ms-flex-pack:end;justify-content:end}:host(.select-label-placement-start) .select-wrapper{-ms-flex-direction:row;flex-direction:row}:host(.select-label-placement-start) .label-text-wrapper{-webkit-margin-start:0;margin-inline-start:0;-webkit-margin-end:16px;margin-inline-end:16px;margin-top:0;margin-bottom:0}:host(.select-label-placement-end) .select-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host(.select-label-placement-end) .label-text-wrapper{-webkit-margin-start:16px;margin-inline-start:16px;-webkit-margin-end:0;margin-inline-end:0;margin-top:0;margin-bottom:0}:host(.select-label-placement-fixed) .label-text-wrapper{-webkit-margin-start:0;margin-inline-start:0;-webkit-margin-end:16px;margin-inline-end:16px;margin-top:0;margin-bottom:0}:host(.select-label-placement-fixed) .label-text-wrapper{-ms-flex:0 0 100px;flex:0 0 100px;width:100px;min-width:100px;max-width:200px}:host(.select-label-placement-stacked) .select-wrapper,:host(.select-label-placement-floating) .select-wrapper{-ms-flex-direction:column;flex-direction:column;-ms-flex-align:start;align-items:start}:host(.select-label-placement-stacked) .label-text-wrapper,:host(.select-label-placement-floating) .label-text-wrapper{max-width:100%}:host(.select-ltr.select-label-placement-stacked) .label-text-wrapper,:host(.select-ltr.select-label-placement-floating) .label-text-wrapper{-webkit-transform-origin:left top;transform-origin:left top}:host(.select-rtl.select-label-placement-stacked) .label-text-wrapper,:host(.select-rtl.select-label-placement-floating) .label-text-wrapper{-webkit-transform-origin:right top;transform-origin:right top}:host(.select-label-placement-stacked) .native-wrapper,:host(.select-label-placement-floating) .native-wrapper{margin-left:0;margin-right:0;margin-top:1px;margin-bottom:0;-ms-flex-positive:1;flex-grow:1;width:100%}:host(.select-label-placement-floating) .label-text-wrapper{-webkit-transform:translateY(100%) scale(1);transform:translateY(100%) scale(1)}:host(.select-label-placement-floating:not(.label-floating)) .native-wrapper .select-placeholder{opacity:0}:host(.select-expanded.select-label-placement-floating) .native-wrapper .select-placeholder,:host(.has-focus.select-label-placement-floating) .native-wrapper .select-placeholder,:host(.has-value.select-label-placement-floating) .native-wrapper .select-placeholder{opacity:1}:host(.label-floating) .label-text-wrapper{-webkit-transform:translateY(50%) scale(0.75);transform:translateY(50%) scale(0.75);max-width:calc(100% / 0.75)}::slotted([slot=start]),::slotted([slot=end]){-ms-flex-negative:0;flex-shrink:0}::slotted([slot=start]:last-of-type){-webkit-margin-end:16px;margin-inline-end:16px;-webkit-margin-start:0;margin-inline-start:0}::slotted([slot=end]:first-of-type){-webkit-margin-start:16px;margin-inline-start:16px;-webkit-margin-end:0;margin-inline-end:0}:host(.select-fill-solid){--background:var(--ion-color-step-50, var(--ion-background-color-step-50, #f2f2f2));--border-color:var(--ion-color-step-500, var(--ion-background-color-step-500, gray));--border-radius:4px;--padding-start:16px;--padding-end:16px;min-height:56px}:host(.select-fill-solid) .select-wrapper{border-bottom:var(--border-width) var(--border-style) var(--border-color)}:host(.select-expanded.select-fill-solid.ion-valid),:host(.has-focus.select-fill-solid.ion-valid),:host(.select-fill-solid.ion-touched.ion-invalid){--border-color:var(--highlight-color)}:host(.select-fill-solid) .select-bottom{border-top:none}@media (any-hover: hover){:host(.select-fill-solid:hover){--background:var(--ion-color-step-100, var(--ion-background-color-step-100, #e6e6e6));--border-color:var(--ion-color-step-750, var(--ion-background-color-step-750, #404040))}}:host(.select-fill-solid.select-expanded),:host(.select-fill-solid.has-focus){--background:var(--ion-color-step-150, var(--ion-background-color-step-150, #d9d9d9));--border-color:var(--highlight-color)}:host(.select-fill-solid) .select-wrapper{border-start-start-radius:var(--border-radius);border-start-end-radius:var(--border-radius);border-end-end-radius:0px;border-end-start-radius:0px}:host(.label-floating.select-fill-solid) .label-text-wrapper{max-width:calc(100% / 0.75)}:host(.in-item.select-expanded.select-fill-solid) .select-wrapper .select-icon,:host(.in-item.has-focus.select-fill-solid) .select-wrapper .select-icon,:host(.in-item.has-focus.ion-valid.select-fill-solid) .select-wrapper .select-icon,:host(.in-item.ion-touched.ion-invalid.select-fill-solid) .select-wrapper .select-icon{color:var(--highlight-color)}:host(.select-fill-outline){--border-color:var(--ion-color-step-300, var(--ion-background-color-step-300, #b3b3b3));--border-radius:4px;--padding-start:16px;--padding-end:16px;min-height:56px}:host(.select-fill-outline.select-shape-round){--border-radius:28px;--padding-start:32px;--padding-end:32px}:host(.has-focus.select-fill-outline.ion-valid),:host(.select-fill-outline.ion-touched.ion-invalid){--border-color:var(--highlight-color)}@media (any-hover: hover){:host(.select-fill-outline:hover){--border-color:var(--ion-color-step-750, var(--ion-background-color-step-750, #404040))}}:host(.select-fill-outline.select-expanded),:host(.select-fill-outline.has-focus){--border-width:var(--highlight-height);--border-color:var(--highlight-color)}:host(.select-fill-outline) .select-bottom{border-top:none}:host(.select-fill-outline) .select-wrapper{border-bottom:none}:host(.select-ltr.select-fill-outline.select-label-placement-stacked) .label-text-wrapper,:host(.select-ltr.select-fill-outline.select-label-placement-floating) .label-text-wrapper{-webkit-transform-origin:left top;transform-origin:left top}:host(.select-rtl.select-fill-outline.select-label-placement-stacked) .label-text-wrapper,:host(.select-rtl.select-fill-outline.select-label-placement-floating) .label-text-wrapper{-webkit-transform-origin:right top;transform-origin:right top}:host(.select-fill-outline.select-label-placement-stacked) .label-text-wrapper,:host(.select-fill-outline.select-label-placement-floating) .label-text-wrapper{position:absolute;max-width:calc(100% - var(--padding-start) - var(--padding-end))}:host(.select-fill-outline) .label-text-wrapper{position:relative;z-index:1}:host(.label-floating.select-fill-outline) .label-text-wrapper{-webkit-transform:translateY(-32%) scale(0.75);transform:translateY(-32%) scale(0.75);margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;max-width:calc((100% - var(--padding-start) - var(--padding-end) - 8px) / 0.75)}:host(.select-fill-outline.select-label-placement-stacked) select,:host(.select-fill-outline.select-label-placement-floating) select{margin-left:0;margin-right:0;margin-top:6px;margin-bottom:6px}:host(.select-fill-outline) .select-outline-container{left:0;right:0;top:0;bottom:0;display:-ms-flexbox;display:flex;position:absolute;width:100%;height:100%}:host(.select-fill-outline) .select-outline-start,:host(.select-fill-outline) .select-outline-end{pointer-events:none}:host(.select-fill-outline) .select-outline-start,:host(.select-fill-outline) .select-outline-notch,:host(.select-fill-outline) .select-outline-end{border-top:var(--border-width) var(--border-style) var(--border-color);border-bottom:var(--border-width) var(--border-style) var(--border-color);-webkit-box-sizing:border-box;box-sizing:border-box}:host(.select-fill-outline) .select-outline-notch{max-width:calc(100% - var(--padding-start) - var(--padding-end))}:host(.select-fill-outline) .notch-spacer{-webkit-padding-end:8px;padding-inline-end:8px;font-size:calc(1em * 0.75);opacity:0;pointer-events:none}:host(.select-fill-outline) .select-outline-start{-webkit-border-start:var(--border-width) var(--border-style) var(--border-color);border-inline-start:var(--border-width) var(--border-style) var(--border-color)}:host(.select-fill-outline) .select-outline-start{border-start-start-radius:var(--border-radius);border-start-end-radius:0px;border-end-end-radius:0px;border-end-start-radius:var(--border-radius)}:host(.select-fill-outline) .select-outline-start{width:calc(var(--padding-start) - 4px)}:host(.select-fill-outline) .select-outline-end{-webkit-border-end:var(--border-width) var(--border-style) var(--border-color);border-inline-end:var(--border-width) var(--border-style) var(--border-color)}:host(.select-fill-outline) .select-outline-end{border-start-start-radius:0px;border-start-end-radius:var(--border-radius);border-end-end-radius:var(--border-radius);border-end-start-radius:0px}:host(.select-fill-outline) .select-outline-end{-ms-flex-positive:1;flex-grow:1}:host(.label-floating.select-fill-outline) .select-outline-notch{border-top:none}:host(.in-item.select-expanded.select-fill-outline) .select-wrapper .select-icon,:host(.in-item.has-focus.select-fill-outline) .select-wrapper .select-icon,:host(.in-item.has-focus.ion-valid.select-fill-outline) .select-wrapper .select-icon,:host(.in-item.ion-touched.ion-invalid.select-fill-outline) .select-wrapper .select-icon{color:var(--highlight-color)}:host{--border-width:1px;--border-color:var(--ion-item-border-color, var(--ion-border-color, var(--ion-color-step-150, var(--ion-background-color-step-150, rgba(0, 0, 0, 0.13)))));--highlight-height:2px}:host(.select-label-placement-floating.select-expanded) .label-text-wrapper,:host(.select-label-placement-floating.has-focus) .label-text-wrapper,:host(.select-label-placement-stacked.select-expanded) .label-text-wrapper,:host(.select-label-placement-stacked.has-focus) .label-text-wrapper{color:var(--highlight-color)}:host(.has-focus.select-label-placement-floating.ion-valid) .label-text-wrapper,:host(.select-label-placement-floating.ion-touched.ion-invalid) .label-text-wrapper,:host(.has-focus.select-label-placement-stacked.ion-valid) .label-text-wrapper,:host(.select-label-placement-stacked.ion-touched.ion-invalid) .label-text-wrapper{color:var(--highlight-color)}.select-highlight{bottom:-1px;position:absolute;width:100%;height:var(--highlight-height);-webkit-transform:scale(0);transform:scale(0);-webkit-transition:-webkit-transform 200ms;transition:-webkit-transform 200ms;transition:transform 200ms;transition:transform 200ms, -webkit-transform 200ms;background:var(--highlight-color)}.select-highlight{inset-inline-start:0}:host(.select-expanded) .select-highlight,:host(.has-focus) .select-highlight{-webkit-transform:scale(1);transform:scale(1)}:host(.in-item) .select-highlight{bottom:0}:host(.in-item) .select-highlight{inset-inline-start:0}.select-icon{width:0.8125rem;-webkit-transition:-webkit-transform 0.15s cubic-bezier(0.4, 0, 0.2, 1);transition:-webkit-transform 0.15s cubic-bezier(0.4, 0, 0.2, 1);transition:transform 0.15s cubic-bezier(0.4, 0, 0.2, 1);transition:transform 0.15s cubic-bezier(0.4, 0, 0.2, 1), -webkit-transform 0.15s cubic-bezier(0.4, 0, 0.2, 1);color:var(--ion-color-step-500, var(--ion-text-color-step-500, gray))}:host(.select-expanded:not(.has-expanded-icon)) .select-icon{-webkit-transform:rotate(180deg);transform:rotate(180deg)}:host(.in-item.select-expanded) .select-wrapper .select-icon,:host(.in-item.has-focus) .select-wrapper .select-icon,:host(.in-item.has-focus.ion-valid) .select-wrapper .select-icon,:host(.in-item.ion-touched.ion-invalid) .select-wrapper .select-icon{color:var(--ion-color-step-500, var(--ion-text-color-step-500, gray))}:host(.select-expanded) .select-wrapper .select-icon,:host(.has-focus.ion-valid) .select-wrapper .select-icon,:host(.ion-touched.ion-invalid) .select-wrapper .select-icon,:host(.has-focus) .select-wrapper .select-icon{color:var(--highlight-color)}:host(.select-shape-round){--border-radius:16px}:host(.select-label-placement-stacked) .select-wrapper-inner,:host(.select-label-placement-floating) .select-wrapper-inner{width:calc(100% - 0.8125rem - 4px)}:host(.select-disabled){opacity:0.38}::slotted(ion-button[slot=start].button-has-icon-only),::slotted(ion-button[slot=end].button-has-icon-only){--border-radius:50%;--padding-start:8px;--padding-end:8px;--padding-top:8px;--padding-bottom:8px;aspect-ratio:1;min-height:40px}"};const S=class{constructor(t){e(this,t),this.inputId="ion-selopt-"+B++,this.disabled=!1}render(){return l(s,{key:"3a70eea9fa03a9acba582180761d18347c72acee",role:"option",id:this.inputId,class:o(this)})}get el(){return r(this)}};let B=0;S.style=":host{display:none}";const D=class{constructor(t){e(this,t),this.options=[]}findOptionFromEvent(e){const{options:t}=this;return t.find((t=>t.value===e.target.value))}callOptionHandler(e){const t=this.findOptionFromEvent(e),i=this.getValues(e);(null==t?void 0:t.handler)&&x(t.handler,i)}dismissParentPopover(){const e=this.el.closest("ion-popover");e&&e.dismiss()}setChecked(e){const{multiple:t}=this,i=this.findOptionFromEvent(e);t&&i&&(i.checked=e.detail.checked)}getValues(e){const{multiple:t,options:i}=this;if(t)return i.filter((e=>e.checked)).map((e=>e.value));const o=this.findOptionFromEvent(e);return o?o.value:void 0}renderOptions(e){const{multiple:t}=this;return!0===t?this.renderCheckboxOptions(e):this.renderRadioOptions(e)}renderCheckboxOptions(e){return e.map((e=>l("ion-item",{class:Object.assign({"item-checkbox-checked":e.checked},y(e.cssClass))},l("ion-checkbox",{value:e.value,disabled:e.disabled,checked:e.checked,justify:"start",labelPlacement:"end",onIonChange:e=>{this.setChecked(e),this.callOptionHandler(e),a(this)}},e.text))))}renderRadioOptions(e){const t=e.filter((e=>e.checked)).map((e=>e.value))[0];return l("ion-radio-group",{value:t,onIonChange:e=>this.callOptionHandler(e)},e.map((e=>l("ion-item",{class:Object.assign({"item-radio-checked":e.value===t},y(e.cssClass))},l("ion-radio",{value:e.value,disabled:e.disabled,onClick:()=>this.dismissParentPopover(),onKeyUp:e=>{" "===e.key&&this.dismissParentPopover()}},e.text)))))}render(){const{header:e,message:t,options:i,subHeader:r}=this,a=void 0!==r||void 0!==t;return l(s,{key:"ab931b49b59283825bd2afa3f7f995b0e6e05bef",class:o(this)},l("ion-list",{key:"3bd12b67832607596b912a73d5b3ae9b954b244d"},void 0!==e&&l("ion-list-header",{key:"97da930246edf7423a039c030d40e3ff7a5148a3"},e),a&&l("ion-item",{key:"c579df6ea8fac07bb0c59d34c69b149656863224"},l("ion-label",{key:"af699c5f465710ccb13b8cf8e7be66f0e8acfad1",class:"ion-text-wrap"},void 0!==r&&l("h3",{key:"df9a936d42064b134e843c7229f314a2a3ec7e80"},r),void 0!==t&&l("p",{key:"9c3ddad378df00f106afa94e9928cf68c17124dd"},t))),this.renderOptions(i)))}get el(){return r(this)}};D.style={ios:".sc-ion-select-popover-ios-h ion-list.sc-ion-select-popover-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0}ion-list-header.sc-ion-select-popover-ios,ion-label.sc-ion-select-popover-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0}.sc-ion-select-popover-ios-h{overflow-y:auto}",md:".sc-ion-select-popover-md-h ion-list.sc-ion-select-popover-md{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0}ion-list-header.sc-ion-select-popover-md,ion-label.sc-ion-select-popover-md{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0}.sc-ion-select-popover-md-h{overflow-y:auto}ion-list.sc-ion-select-popover-md ion-radio.sc-ion-select-popover-md::part(container){display:none}ion-list.sc-ion-select-popover-md ion-radio.sc-ion-select-popover-md::part(label){margin-left:0;margin-right:0;margin-top:0;margin-bottom:0}ion-item.sc-ion-select-popover-md{--inner-border-width:0}.item-radio-checked.sc-ion-select-popover-md{--background:rgba(var(--ion-color-primary-rgb, 0, 84, 233), 0.08);--background-focused:var(--ion-color-primary, #0054e9);--background-focused-opacity:0.2;--background-hover:var(--ion-color-primary, #0054e9);--background-hover-opacity:0.12}.item-checkbox-checked.sc-ion-select-popover-md{--background-activated:var(--ion-item-color, var(--ion-text-color, #000));--background-focused:var(--ion-item-color, var(--ion-text-color, #000));--background-hover:var(--ion-item-color, var(--ion-text-color, #000));--color:var(--ion-color-primary, #0054e9)}"};export{O as ion_select,S as ion_select_option,D as ion_select_popover}
@@ -0,0 +1,4 @@
1
+ /*!
2
+ * (C) Ionic http://ionicframework.com - MIT License
3
+ */
4
+ import{r as t,d as o,m as i,w as a,e,l as r,h as n,j as s,k as d}from"./p-B_U9CtaY.js";import{f as h,i as p,d as l,r as c,a as m,p as f}from"./p-QwEXyOze.js";import{C as b,a as u,d as w}from"./p-BhLqfMrf.js";import{e as x,g as v,r as g,b as k,h as y}from"./p-Do-uqmtX.js";import{c as A}from"./p-B-hirT0v.js";import{g as B}from"./p-CIGNaXM1.js";import{G as D,O as Y,F as E,e as S,B as j,j as C,k as M,f as T,g as O,h as $}from"./p-aIxOGKys.js";import{g as P}from"./p-DiVJyqlX.js";import{e as I,w as R}from"./p-BROiNJRB.js";import{KEYBOARD_DID_OPEN as z}from"./p-9eeaBrnk.js";import{c as W}from"./p-bNmY-WfR.js";import{g as L}from"./p-hHmYLOfE.js";import{createGesture as H}from"./p-Cl0B-RWe.js";import{w as N}from"./p-ZjP4CjeZ.js";import"./p-DzH0J0yi.js";import"./p-BTEOs1at.js";import"./p-D13Eaw-8.js";var F;!function(t){t.Dark="DARK",t.Light="LIGHT",t.Default="DEFAULT"}(F||(F={}));const K={getEngine(){const t=B();if(null==t?void 0:t.isPluginAvailable("StatusBar"))return t.Plugins.StatusBar},setStyle(t){const o=this.getEngine();o&&o.setStyle(t)},getStyle:async function(){const t=this.getEngine();if(!t)return F.Default;const{style:o}=await t.getInfo();return o}},Z=(t,o)=>{if(1===o)return 0;const i=1/(1-o);return t*i+-o*i},G=()=>{!N||N.innerWidth>=768||K.setStyle({style:F.Dark})},V=(t=F.Default)=>{!N||N.innerWidth>=768||K.setStyle({style:t})},_=async(t,o)=>{"function"==typeof t.canDismiss&&await t.canDismiss(void 0,D)&&(o.isRunning()?o.onFinish((()=>{t.dismiss(void 0,"handler")}),{oneTimeCallback:!0}):t.dismiss(void 0,"handler"))},X=t=>.00255275*2.71828**(-14.9619*t)-1.00255*2.71828**(-.0380968*t)+1,q=.915,J=(t,o)=>x(400,t/Math.abs(1.1*o),500),U=t=>{const{currentBreakpoint:o,backdropBreakpoint:i,expandToScroll:a}=t,e=void 0===i||i<o,r=e?`calc(var(--backdrop-opacity) * ${o})`:"0",n=W("backdropAnimation").fromTo("opacity",0,r);return e&&n.beforeStyles({"pointer-events":"none"}).afterClearStyles(["pointer-events"]),{wrapperAnimation:W("wrapperAnimation").keyframes([{offset:0,opacity:1,transform:"translateY(100%)"},{offset:1,opacity:1,transform:`translateY(${100-100*o}%)`}]),backdropAnimation:n,contentAnimation:a?void 0:W("contentAnimation").keyframes([{offset:0,opacity:1,maxHeight:100*(1-o)+"%"},{offset:1,opacity:1,maxHeight:100*o+"%"}])}},Q=t=>{const{currentBreakpoint:o,backdropBreakpoint:i}=t,a=`calc(var(--backdrop-opacity) * ${Z(o,i)})`,e=[{offset:0,opacity:a},{offset:1,opacity:0}],r=[{offset:0,opacity:a},{offset:i,opacity:0},{offset:1,opacity:0}],n=W("backdropAnimation").keyframes(0!==i?r:e);return{wrapperAnimation:W("wrapperAnimation").keyframes([{offset:0,opacity:1,transform:`translateY(${100-100*o}%)`},{offset:1,opacity:1,transform:"translateY(100%)"}]),backdropAnimation:n}},tt=(t,o)=>{const{presentingEl:i,currentBreakpoint:a,expandToScroll:e}=o,r=v(t),{wrapperAnimation:n,backdropAnimation:s,contentAnimation:d}=void 0!==a?U(o):{backdropAnimation:W().fromTo("opacity",.01,"var(--backdrop-opacity)").beforeStyles({"pointer-events":"none"}).afterClearStyles(["pointer-events"]),wrapperAnimation:W().fromTo("transform","translateY(100vh)","translateY(0vh)"),contentAnimation:void 0};s.addElement(r.querySelector("ion-backdrop")),n.addElement(r.querySelectorAll(".modal-wrapper, .modal-shadow")).beforeStyles({opacity:1}),!e&&(null==d||d.addElement(t.querySelector(".ion-page")));const h=W("entering-base").addElement(t).easing("cubic-bezier(0.32,0.72,0,1)").duration(500).addAnimation([n]);if(d&&h.addAnimation(d),i){const t=window.innerWidth<768,o="ION-MODAL"===i.tagName&&void 0!==i.presentingElement,a=v(i),e=W().beforeStyles({transform:"translateY(0)","transform-origin":"top center",overflow:"hidden"}),r=document.body;if(t){const t=CSS.supports("width","max(0px, 1px)")?"max(30px, var(--ion-safe-area-top))":"30px",a=`translateY(${o?"-10px":t}) scale(0.915)`;e.afterStyles({transform:a}).beforeAddWrite((()=>r.style.setProperty("background-color","black"))).addElement(i).keyframes([{offset:0,filter:"contrast(1)",transform:"translateY(0px) scale(1)",borderRadius:"0px"},{offset:1,filter:"contrast(0.85)",transform:a,borderRadius:"10px 10px 0 0"}]),h.addAnimation(e)}else if(h.addAnimation(s),o){const t=`translateY(-10px) scale(${o?q:1})`;e.afterStyles({transform:t}).addElement(a.querySelector(".modal-wrapper")).keyframes([{offset:0,filter:"contrast(1)",transform:"translateY(0) scale(1)"},{offset:1,filter:"contrast(0.85)",transform:t}]);const i=W().afterStyles({transform:t}).addElement(a.querySelector(".modal-shadow")).keyframes([{offset:0,opacity:"1",transform:"translateY(0) scale(1)"},{offset:1,opacity:"0",transform:t}]);h.addAnimation([e,i])}else n.fromTo("opacity","0","1")}else h.addAnimation(s);return h},ot=(t,o,i=500)=>{const{presentingEl:a,currentBreakpoint:e}=o,r=v(t),{wrapperAnimation:n,backdropAnimation:s}=void 0!==e?Q(o):{backdropAnimation:W().fromTo("opacity","var(--backdrop-opacity)",0),wrapperAnimation:W().fromTo("transform","translateY(0vh)","translateY(100vh)")};s.addElement(r.querySelector("ion-backdrop")),n.addElement(r.querySelectorAll(".modal-wrapper, .modal-shadow")).beforeStyles({opacity:1});const d=W("leaving-base").addElement(t).easing("cubic-bezier(0.32,0.72,0,1)").duration(i).addAnimation(n);if(a){const t=window.innerWidth<768,o="ION-MODAL"===a.tagName&&void 0!==a.presentingElement,i=v(a),e=W().beforeClearStyles(["transform"]).afterClearStyles(["transform"]).onFinish((t=>{1===t&&(a.style.setProperty("overflow",""),Array.from(r.querySelectorAll("ion-modal:not(.overlay-hidden)")).filter((t=>void 0!==t.presentingElement)).length<=1&&r.style.setProperty("background-color",""))})),r=document.body;if(t){const t=CSS.supports("width","max(0px, 1px)")?"max(30px, var(--ion-safe-area-top))":"30px",i=`translateY(${o?"-10px":t}) scale(0.915)`;e.addElement(a).keyframes([{offset:0,filter:"contrast(0.85)",transform:i,borderRadius:"10px 10px 0 0"},{offset:1,filter:"contrast(1)",transform:"translateY(0px) scale(1)",borderRadius:"0px"}]),d.addAnimation(e)}else if(d.addAnimation(s),o){const t=`translateY(-10px) scale(${o?q:1})`;e.addElement(i.querySelector(".modal-wrapper")).afterStyles({transform:"translate3d(0, 0, 0)"}).keyframes([{offset:0,filter:"contrast(0.85)",transform:t},{offset:1,filter:"contrast(1)",transform:"translateY(0) scale(1)"}]);const a=W().addElement(i.querySelector(".modal-shadow")).afterStyles({transform:"translateY(0) scale(1)"}).keyframes([{offset:0,opacity:"0",transform:t},{offset:1,opacity:"1",transform:"translateY(0) scale(1)"}]);d.addAnimation([e,a])}else n.fromTo("opacity","1","0")}else d.addAnimation(s);return d},it=(t,o)=>{const{currentBreakpoint:i,expandToScroll:a}=o,e=v(t),{wrapperAnimation:r,backdropAnimation:n,contentAnimation:s}=void 0!==i?U(o):{backdropAnimation:W().fromTo("opacity",.01,"var(--backdrop-opacity)").beforeStyles({"pointer-events":"none"}).afterClearStyles(["pointer-events"]),wrapperAnimation:W().keyframes([{offset:0,opacity:.01,transform:"translateY(40px)"},{offset:1,opacity:1,transform:"translateY(0px)"}]),contentAnimation:void 0};n.addElement(e.querySelector("ion-backdrop")),r.addElement(e.querySelector(".modal-wrapper")),!a&&(null==s||s.addElement(t.querySelector(".ion-page")));const d=W().addElement(t).easing("cubic-bezier(0.36,0.66,0.04,1)").duration(280).addAnimation([n,r]);return s&&d.addAnimation(s),d},at=(t,o)=>{const{currentBreakpoint:i}=o,a=v(t),{wrapperAnimation:e,backdropAnimation:r}=void 0!==i?Q(o):{backdropAnimation:W().fromTo("opacity","var(--backdrop-opacity)",0),wrapperAnimation:W().keyframes([{offset:0,opacity:.99,transform:"translateY(0px)"},{offset:1,opacity:0,transform:"translateY(40px)"}])};return r.addElement(a.querySelector("ion-backdrop")),e.addElement(a.querySelector(".modal-wrapper")),W().easing("cubic-bezier(0.47,0,0.745,0.715)").duration(200).addAnimation([r,e])},et=class{constructor(i){t(this,i),this.didPresent=o(this,"ionModalDidPresent",7),this.willPresent=o(this,"ionModalWillPresent",7),this.willDismiss=o(this,"ionModalWillDismiss",7),this.didDismiss=o(this,"ionModalDidDismiss",7),this.ionBreakpointDidChange=o(this,"ionBreakpointDidChange",7),this.didPresentShorthand=o(this,"didPresent",7),this.willPresentShorthand=o(this,"willPresent",7),this.willDismissShorthand=o(this,"willDismiss",7),this.didDismissShorthand=o(this,"didDismiss",7),this.ionMount=o(this,"ionMount",7),this.lockController=A(),this.triggerController=S(),this.coreDelegate=b(),this.isSheetModal=!1,this.inheritedAttributes={},this.inline=!1,this.gestureAnimationDismissing=!1,this.presented=!1,this.hasController=!1,this.keyboardClose=!0,this.expandToScroll=!0,this.backdropBreakpoint=0,this.handleBehavior="none",this.backdropDismiss=!0,this.showBackdrop=!0,this.animated=!0,this.isOpen=!1,this.keepContentsMounted=!1,this.focusTrap=!0,this.canDismiss=!0,this.onHandleClick=()=>{const{sheetTransition:t,handleBehavior:o}=this;"cycle"===o&&void 0===t&&this.moveToNextBreakpoint()},this.onBackdropTap=()=>{const{sheetTransition:t}=this;void 0===t&&this.dismiss(void 0,j)},this.onLifecycle=t=>{const o=this.usersElement,i=rt[t.type];if(o&&i){const a=new CustomEvent(i,{bubbles:!1,cancelable:!1,detail:t.detail});o.dispatchEvent(a)}},this.onModalFocus=t=>{const{dragHandleEl:o,el:i}=this;t.target===i&&o&&-1!==o.tabIndex&&o.focus()}}onIsOpenChange(t,o){!0===t&&!1===o?this.present():!1===t&&!0===o&&this.dismiss()}triggerChanged(){const{trigger:t,el:o,triggerController:i}=this;t&&i.addClickListener(o,t)}breakpointsChanged(t){void 0!==t&&(this.sortedBreakpoints=t.sort(((t,o)=>t-o)))}connectedCallback(){const{el:t}=this;C(t),this.triggerChanged()}disconnectedCallback(){this.triggerController.removeClickListener()}componentWillLoad(){var t;const{breakpoints:o,initialBreakpoint:a,el:e,htmlAttributes:r}=this,n=this.isSheetModal=void 0!==o&&void 0!==a,s=["aria-label","role"];this.inheritedAttributes=k(e,s),void 0!==r&&s.forEach((t=>{r[t]&&(this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:r[t]}),delete r[t])})),n&&(this.currentBreakpoint=this.initialBreakpoint),void 0===o||void 0===a||o.includes(a)||i("[ion-modal] - Your breakpoints array must include the initialBreakpoint value."),(null===(t=this.htmlAttributes)||void 0===t?void 0:t.id)||M(this.el)}componentDidLoad(){!0===this.isOpen&&g((()=>this.present())),this.breakpointsChanged(this.breakpoints),this.triggerChanged()}getDelegate(t=!1){if(this.workingDelegate&&!t)return{delegate:this.workingDelegate,inline:this.inline};const o=this.inline=null!==this.el.parentNode&&!this.hasController;return{inline:o,delegate:this.workingDelegate=o?this.delegate||this.coreDelegate:this.delegate}}async checkCanDismiss(t,o){const{canDismiss:i}=this;return"function"==typeof i?i(t,o):i}async present(){const t=await this.lockController.lock();if(this.presented)return void t();const{presentingElement:o,el:i}=this;this.currentBreakpoint=this.initialBreakpoint;const{inline:r,delegate:n}=this.getDelegate(!0);this.ionMount.emit(),this.usersElement=await u(n,i,this.component,["ion-page"],this.componentProps,r),y(i)?await I(this.usersElement):this.keepContentsMounted||await R(),a((()=>this.el.classList.add("show-modal")));const s=void 0!==o;s&&"ios"===e(this)&&(this.statusBarStyle=await K.getStyle(),G()),await T(this,"modalEnter",tt,it,{presentingEl:o,currentBreakpoint:this.initialBreakpoint,backdropBreakpoint:this.backdropBreakpoint,expandToScroll:this.expandToScroll}),"undefined"!=typeof window&&(this.keyboardOpenCallback=()=>{this.gesture&&(this.gesture.enable(!1),g((()=>{this.gesture&&this.gesture.enable(!0)})))},window.addEventListener(z,this.keyboardOpenCallback)),this.isSheetModal?this.initSheetGesture():s&&this.initSwipeToClose(),t()}initSwipeToClose(){var t;if("ios"!==e(this))return;const{el:o}=this,i=this.leaveAnimation||r.get("modalLeave",ot),a=this.animation=i(o,{presentingEl:this.presentingElement,expandToScroll:this.expandToScroll});if(!m(o))return void f(o);const n=null!==(t=this.statusBarStyle)&&void 0!==t?t:F.Default;this.gesture=((t,o,i,a)=>{const e=.5,r=t.offsetHeight;let n=!1,s=!1,d=null,m=null,f=!0,b=0;const u=H({el:t,gestureName:"modalSwipeToClose",gesturePriority:Y,direction:"y",threshold:10,canStart:t=>{const o=t.event.target;if(null===o||!o.closest)return!0;if(d=h(o),d){if(p(d)){const t=v(d);m=t.querySelector(".inner-scroll")}else m=d;return!d.querySelector("ion-refresher")&&0===m.scrollTop}return null===o.closest("ion-footer")},onStart:i=>{const{deltaY:a}=i;f=!d||!p(d)||d.scrollY,s=void 0!==t.canDismiss&&!0!==t.canDismiss,a>0&&d&&l(d),o.progressStart(!0,n?1:0)},onMove:t=>{const{deltaY:a}=t;a>0&&d&&l(d);const n=t.deltaY/r,h=n>=0&&s,p=h?.2:.9999,c=h?X(n/p):n,m=x(1e-4,c,p);o.progressStep(m),m>=e&&b<e?V(i):m<e&&b>=e&&G(),b=m},onEnd:i=>{const h=i.velocityY,p=i.deltaY/r,l=p>=0&&s,m=l?.2:.9999,b=l?X(p/m):p,w=x(1e-4,b,m),v=!l&&(i.deltaY+1e3*h)/r>=e;let g=v?-.001:.001;v?(o.easing("cubic-bezier(0.32, 0.72, 0, 1)"),g+=L([0,0],[.32,.72],[0,1],[1,1],w)[0]):(o.easing("cubic-bezier(1, 0, 0.68, 0.28)"),g+=L([0,0],[1,0],[.68,.28],[1,1],w)[0]);const k=J(v?p*r:(1-w)*r,h);n=v,u.enable(!1),d&&c(d,f),o.onFinish((()=>{v||u.enable(!0)})).progressEnd(v?1:0,g,k),l&&w>m/4?_(t,o):v&&a()}});return u})(o,a,n,(()=>{this.gestureAnimationDismissing=!0,V(this.statusBarStyle),this.animation.onFinish((async()=>{await this.dismiss(void 0,D),this.gestureAnimationDismissing=!1}))})),this.gesture.enable(!0)}initSheetGesture(){const{wrapperEl:t,initialBreakpoint:o,backdropBreakpoint:i}=this;if(!t||void 0===o)return;const a=this.enterAnimation||r.get("modalEnter",tt),e=this.animation=a(this.el,{presentingEl:this.presentingElement,currentBreakpoint:o,backdropBreakpoint:i,expandToScroll:this.expandToScroll});e.progressStart(!0,1);const{gesture:n,moveSheetToBreakpoint:s}=((t,o,i,a,e,r,n=[],s,d,l,c)=>{const m={WRAPPER_KEYFRAMES:[{offset:0,transform:"translateY(0%)"},{offset:1,transform:"translateY(100%)"}],BACKDROP_KEYFRAMES:0!==e?[{offset:0,opacity:"var(--backdrop-opacity)"},{offset:1-e,opacity:0},{offset:1,opacity:0}]:[{offset:0,opacity:"var(--backdrop-opacity)"},{offset:1,opacity:.01}],CONTENT_KEYFRAMES:[{offset:0,maxHeight:"100%"},{offset:1,maxHeight:"0%"}]},f=t.querySelector("ion-content"),b=i.clientHeight;let u=a,w=0,k=!1,y=null,A=null,B=null,D=null;const Y=n[n.length-1],S=n[0],j=r.childAnimations.find((t=>"wrapperAnimation"===t.id)),C=r.childAnimations.find((t=>"backdropAnimation"===t.id)),M=r.childAnimations.find((t=>"contentAnimation"===t.id)),T=()=>{t.style.setProperty("pointer-events","auto"),o.style.setProperty("pointer-events","auto"),t.classList.remove(E)},O=()=>{t.style.setProperty("pointer-events","none"),o.style.setProperty("pointer-events","none"),t.classList.add(E)},$=o=>{if(!A&&(A=Array.from(t.querySelectorAll("ion-footer")),!A.length))return;const i=t.querySelector(".ion-page");if(D=o,"stationary"===o)A.forEach((t=>{t.classList.remove("modal-footer-moving"),t.style.removeProperty("position"),t.style.removeProperty("width"),t.style.removeProperty("height"),t.style.removeProperty("top"),t.style.removeProperty("left"),null==i||i.style.removeProperty("padding-bottom"),null==i||i.appendChild(t)}));else{let o=0;A.forEach(((i,a)=>{const e=i.getBoundingClientRect(),r=document.body.getBoundingClientRect();o+=i.clientHeight;const n=e.top-r.top,s=e.left-r.left;if(i.style.setProperty("--pinned-width",`${i.clientWidth}px`),i.style.setProperty("--pinned-height",`${i.clientHeight}px`),i.style.setProperty("--pinned-top",`${n}px`),i.style.setProperty("--pinned-left",`${s}px`),0===a){B=n;const o=t.querySelector("ion-header");o&&(B-=o.clientHeight)}})),A.forEach((t=>{null==i||i.style.setProperty("padding-bottom",`${o}px`),t.classList.add("modal-footer-moving"),t.style.setProperty("position","absolute"),t.style.setProperty("width","var(--pinned-width)"),t.style.setProperty("height","var(--pinned-height)"),t.style.setProperty("top","var(--pinned-top)"),t.style.setProperty("left","var(--pinned-left)"),document.body.appendChild(t)}))}};j&&C&&(j.keyframes([...m.WRAPPER_KEYFRAMES]),C.keyframes([...m.BACKDROP_KEYFRAMES]),null==M||M.keyframes([...m.CONTENT_KEYFRAMES]),r.progressStart(!0,1-u),u>e?T():O()),f&&u!==Y&&s&&(f.scrollY=!1);const P=o=>{const{breakpoint:i,canDismiss:a,breakpointOffset:d,animated:h}=o,p=a&&0===i,b=p?u:i,w=0!==b;return u=0,j&&C&&(j.keyframes([{offset:0,transform:`translateY(${100*d}%)`},{offset:1,transform:`translateY(${100*(1-b)}%)`}]),C.keyframes([{offset:0,opacity:`calc(var(--backdrop-opacity) * ${Z(1-d,e)})`},{offset:1,opacity:`calc(var(--backdrop-opacity) * ${Z(b,e)})`}]),M&&M.keyframes([{offset:0,maxHeight:100*(1-d)+"%"},{offset:1,maxHeight:100*b+"%"}]),r.progressStep(0)),I.enable(!1),p?_(t,r):w||l(),!f||b!==n[n.length-1]&&s||(f.scrollY=!0),s||0!==b||$("stationary"),new Promise((t=>{r.onFinish((()=>{w?(s||$("stationary"),j&&C?g((()=>{j.keyframes([...m.WRAPPER_KEYFRAMES]),C.keyframes([...m.BACKDROP_KEYFRAMES]),null==M||M.keyframes([...m.CONTENT_KEYFRAMES]),r.progressStart(!0,1-b),u=b,c(u),u>e?T():O(),I.enable(!0),t()})):(I.enable(!0),t())):t()}),{oneTimeCallback:!0}).progressEnd(1,0,h?500:0)}))},I=H({el:i,gestureName:"modalSheet",gesturePriority:40,direction:"y",threshold:10,canStart:t=>{const o=h(t.event.target);if(u=d(),!s&&o)return 0===(p(o)?v(o).querySelector(".inner-scroll"):o).scrollTop;if(1===u&&o){const t=p(o)?v(o).querySelector(".inner-scroll"):o;return!o.querySelector("ion-refresher")&&0===t.scrollTop}return!0},onStart:o=>{if(k=void 0!==t.canDismiss&&!0!==t.canDismiss&&0===S,!s){const t=h(o.event.target);y=t&&p(t)?v(t).querySelector(".inner-scroll"):t}s||$("moving"),o.deltaY>0&&f&&(f.scrollY=!1),g((()=>{t.focus()})),r.progressStart(!0,1-u)},onMove:t=>{if(s||null===B||null===D||(t.currentY>=B&&"moving"===D?$("stationary"):t.currentY<B&&"stationary"===D&&$("moving")),!s&&t.deltaY<=0&&y)return;t.deltaY>0&&f&&(f.scrollY=!1);const o=n.length>1?1-n[1]:void 0,i=1-u+t.deltaY/b,a=void 0!==o&&i>=o&&k,e=a?.95:.9999,d=a&&void 0!==o?o+X((i-o)/(e-o)):i;w=x(1e-4,d,e),r.progressStep(w)},onEnd:t=>{if(!s&&t.deltaY<=0&&y&&y.scrollTop>0)return void $("stationary");const o=u-(t.deltaY+350*t.velocityY)/b,i=n.reduce(((t,i)=>Math.abs(i-o)<Math.abs(t-o)?i:t));P({breakpoint:i,breakpointOffset:w,canDismiss:k,animated:!0})}});return{gesture:I,moveSheetToBreakpoint:P}})(this.el,this.backdropEl,t,o,i,e,this.sortedBreakpoints,this.expandToScroll,(()=>{var t;return null!==(t=this.currentBreakpoint)&&void 0!==t?t:0}),(()=>this.sheetOnDismiss()),(t=>{this.currentBreakpoint!==t&&(this.currentBreakpoint=t,this.ionBreakpointDidChange.emit({breakpoint:t}))}));this.gesture=n,this.moveSheetToBreakpoint=s,this.gesture.enable(!0)}sheetOnDismiss(){this.gestureAnimationDismissing=!0,this.animation.onFinish((async()=>{this.currentBreakpoint=0,this.ionBreakpointDidChange.emit({breakpoint:this.currentBreakpoint}),await this.dismiss(void 0,D),this.gestureAnimationDismissing=!1}))}async dismiss(t,o){var i;if(this.gestureAnimationDismissing&&o!==D)return!1;const r=await this.lockController.lock();if("handler"!==o&&!await this.checkCanDismiss(t,o))return r(),!1;const{presentingElement:n}=this;void 0!==n&&"ios"===e(this)&&V(this.statusBarStyle),"undefined"!=typeof window&&this.keyboardOpenCallback&&(window.removeEventListener(z,this.keyboardOpenCallback),this.keyboardOpenCallback=void 0);const s=await O(this,t,o,"modalLeave",ot,at,{presentingEl:n,currentBreakpoint:null!==(i=this.currentBreakpoint)&&void 0!==i?i:this.initialBreakpoint,backdropBreakpoint:this.backdropBreakpoint,expandToScroll:this.expandToScroll});if(s){const{delegate:t}=this.getDelegate();await w(t,this.usersElement),a((()=>this.el.classList.remove("show-modal"))),this.animation&&this.animation.destroy(),this.gesture&&this.gesture.destroy()}return this.currentBreakpoint=void 0,this.animation=void 0,r(),s}onDidDismiss(){return $(this.el,"ionModalDidDismiss")}onWillDismiss(){return $(this.el,"ionModalWillDismiss")}async setCurrentBreakpoint(t){if(!this.isSheetModal)return void i("[ion-modal] - setCurrentBreakpoint is only supported on sheet modals.");if(!this.breakpoints.includes(t))return void i(`[ion-modal] - Attempted to set invalid breakpoint value ${t}. Please double check that the breakpoint value is part of your defined breakpoints.`);const{currentBreakpoint:o,moveSheetToBreakpoint:a,canDismiss:e,breakpoints:r,animated:n}=this;o!==t&&a&&(this.sheetTransition=a({breakpoint:t,breakpointOffset:1-o,canDismiss:void 0!==e&&!0!==e&&0===r[0],animated:n}),await this.sheetTransition,this.sheetTransition=void 0)}async getCurrentBreakpoint(){return this.currentBreakpoint}async moveToNextBreakpoint(){const{breakpoints:t,currentBreakpoint:o}=this;if(!t||null==o)return!1;const i=t.filter((t=>0!==t)),a=i.indexOf(o),e=i[(a+1)%i.length];return await this.setCurrentBreakpoint(e),!0}render(){const{handle:t,isSheetModal:o,presentingElement:i,htmlAttributes:a,handleBehavior:r,inheritedAttributes:d,focusTrap:h,expandToScroll:p}=this,l=!1!==t&&o,c=e(this),m=void 0!==i&&"ios"===c,f="cycle"===r;return n(s,Object.assign({key:"8add05bb43a2cdb5e3cf180147d31eb85a018fe0","no-router":!0,tabIndex:f&&o&&l?0:-1},a,{style:{zIndex:`${2e4+this.overlayIndex}`},class:Object.assign({[c]:!0,"modal-default":!m&&!o,"modal-card":m,"modal-sheet":o,"modal-no-expand-scroll":o&&!p,"overlay-hidden":!0,[E]:!1===h},P(this.cssClass)),onIonBackdropTap:this.onBackdropTap,onIonModalDidPresent:this.onLifecycle,onIonModalWillPresent:this.onLifecycle,onIonModalWillDismiss:this.onLifecycle,onIonModalDidDismiss:this.onLifecycle,onFocus:this.onModalFocus}),n("ion-backdrop",{key:"90a6605a9564a699d6f66cf71cf6b506796a2963",ref:t=>this.backdropEl=t,visible:this.showBackdrop,tappable:this.backdropDismiss,part:"backdrop"}),"ios"===c&&n("div",{key:"a97d071395333bf803c0a9347bda000cf7500d8d",class:"modal-shadow"}),n("div",Object.assign({key:"e7b7985c7414a13e3ba8dcecf497b76e92edf53e",role:"dialog"},d,{"aria-modal":"true",class:"modal-wrapper ion-overlay-wrapper",part:"content",ref:t=>this.wrapperEl=t}),l&&n("button",{key:"8258b65570b11a8ee9c9df2537d6419cd2e34536",class:"modal-handle",tabIndex:f?0:-1,"aria-label":"Activate to adjust the size of the dialog overlaying the screen",onClick:f?this.onHandleClick:void 0,part:"handle",ref:t=>this.dragHandleEl=t}),n("slot",{key:"394370d0ed03ee03152f8f8abae7ff7664ca5c13"})))}get el(){return d(this)}static get watchers(){return{isOpen:["onIsOpenChange"],trigger:["triggerChanged"]}}},rt={ionModalDidPresent:"ionViewDidEnter",ionModalWillPresent:"ionViewWillEnter",ionModalWillDismiss:"ionViewWillLeave",ionModalDidDismiss:"ionViewDidLeave"};et.style={ios:':host{--width:100%;--min-width:auto;--max-width:auto;--height:100%;--min-height:auto;--max-height:auto;--overflow:hidden;--border-radius:0;--border-width:0;--border-style:none;--border-color:transparent;--background:var(--ion-background-color, #fff);--box-shadow:none;--backdrop-opacity:0;left:0;right:0;top:0;bottom:0;display:-ms-flexbox;display:flex;position:absolute;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;outline:none;color:var(--ion-text-color, #000);contain:strict}.modal-wrapper,ion-backdrop{pointer-events:auto}:host(.overlay-hidden){display:none}.modal-wrapper,.modal-shadow{border-radius:var(--border-radius);width:var(--width);min-width:var(--min-width);max-width:var(--max-width);height:var(--height);min-height:var(--min-height);max-height:var(--max-height);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);background:var(--background);-webkit-box-shadow:var(--box-shadow);box-shadow:var(--box-shadow);overflow:var(--overflow);z-index:10}.modal-shadow{position:absolute;background:transparent}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--width:600px;--height:500px;--ion-safe-area-top:0px;--ion-safe-area-bottom:0px;--ion-safe-area-right:0px;--ion-safe-area-left:0px}}@media only screen and (min-width: 768px) and (min-height: 768px){:host{--width:600px;--height:600px}}.modal-handle{left:0px;right:0px;top:5px;border-radius:8px;-webkit-margin-start:auto;margin-inline-start:auto;-webkit-margin-end:auto;margin-inline-end:auto;position:absolute;width:36px;height:5px;-webkit-transform:translateZ(0);transform:translateZ(0);border:0;background:var(--ion-color-step-350, var(--ion-background-color-step-350, #c0c0be));cursor:pointer;z-index:11}.modal-handle::before{-webkit-padding-start:4px;padding-inline-start:4px;-webkit-padding-end:4px;padding-inline-end:4px;padding-top:4px;padding-bottom:4px;position:absolute;width:36px;height:5px;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%);content:""}:host(.modal-sheet){--height:calc(100% - (var(--ion-safe-area-top) + 10px))}:host(.modal-sheet) .modal-wrapper,:host(.modal-sheet) .modal-shadow{position:absolute;bottom:0}:host(.modal-sheet.modal-no-expand-scroll) ion-footer{position:absolute;bottom:0;width:var(--width)}:host{--backdrop-opacity:var(--ion-backdrop-opacity, 0.4)}:host(.modal-card),:host(.modal-sheet){--border-radius:10px}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--border-radius:10px}}.modal-wrapper{-webkit-transform:translate3d(0, 100%, 0);transform:translate3d(0, 100%, 0)}@media screen and (max-width: 767px){@supports (width: max(0px, 1px)){:host(.modal-card){--height:calc(100% - max(30px, var(--ion-safe-area-top)) - 10px)}}@supports not (width: max(0px, 1px)){:host(.modal-card){--height:calc(100% - 40px)}}:host(.modal-card) .modal-wrapper{border-start-start-radius:var(--border-radius);border-start-end-radius:var(--border-radius);border-end-end-radius:0;border-end-start-radius:0}:host(.modal-card){--backdrop-opacity:0;--width:100%;-ms-flex-align:end;align-items:flex-end}:host(.modal-card) .modal-shadow{display:none}:host(.modal-card) ion-backdrop{pointer-events:none}}@media screen and (min-width: 768px){:host(.modal-card){--width:calc(100% - 120px);--height:calc(100% - (120px + var(--ion-safe-area-top) + var(--ion-safe-area-bottom)));--max-width:720px;--max-height:1000px;--backdrop-opacity:0;--box-shadow:0px 0px 30px 10px rgba(0, 0, 0, 0.1);-webkit-transition:all 0.5s ease-in-out;transition:all 0.5s ease-in-out}:host(.modal-card) .modal-wrapper{-webkit-box-shadow:none;box-shadow:none}:host(.modal-card) .modal-shadow{-webkit-box-shadow:var(--box-shadow);box-shadow:var(--box-shadow)}}:host(.modal-sheet) .modal-wrapper{border-start-start-radius:var(--border-radius);border-start-end-radius:var(--border-radius);border-end-end-radius:0;border-end-start-radius:0}',md:':host{--width:100%;--min-width:auto;--max-width:auto;--height:100%;--min-height:auto;--max-height:auto;--overflow:hidden;--border-radius:0;--border-width:0;--border-style:none;--border-color:transparent;--background:var(--ion-background-color, #fff);--box-shadow:none;--backdrop-opacity:0;left:0;right:0;top:0;bottom:0;display:-ms-flexbox;display:flex;position:absolute;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;outline:none;color:var(--ion-text-color, #000);contain:strict}.modal-wrapper,ion-backdrop{pointer-events:auto}:host(.overlay-hidden){display:none}.modal-wrapper,.modal-shadow{border-radius:var(--border-radius);width:var(--width);min-width:var(--min-width);max-width:var(--max-width);height:var(--height);min-height:var(--min-height);max-height:var(--max-height);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);background:var(--background);-webkit-box-shadow:var(--box-shadow);box-shadow:var(--box-shadow);overflow:var(--overflow);z-index:10}.modal-shadow{position:absolute;background:transparent}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--width:600px;--height:500px;--ion-safe-area-top:0px;--ion-safe-area-bottom:0px;--ion-safe-area-right:0px;--ion-safe-area-left:0px}}@media only screen and (min-width: 768px) and (min-height: 768px){:host{--width:600px;--height:600px}}.modal-handle{left:0px;right:0px;top:5px;border-radius:8px;-webkit-margin-start:auto;margin-inline-start:auto;-webkit-margin-end:auto;margin-inline-end:auto;position:absolute;width:36px;height:5px;-webkit-transform:translateZ(0);transform:translateZ(0);border:0;background:var(--ion-color-step-350, var(--ion-background-color-step-350, #c0c0be));cursor:pointer;z-index:11}.modal-handle::before{-webkit-padding-start:4px;padding-inline-start:4px;-webkit-padding-end:4px;padding-inline-end:4px;padding-top:4px;padding-bottom:4px;position:absolute;width:36px;height:5px;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%);content:""}:host(.modal-sheet){--height:calc(100% - (var(--ion-safe-area-top) + 10px))}:host(.modal-sheet) .modal-wrapper,:host(.modal-sheet) .modal-shadow{position:absolute;bottom:0}:host(.modal-sheet.modal-no-expand-scroll) ion-footer{position:absolute;bottom:0;width:var(--width)}:host{--backdrop-opacity:var(--ion-backdrop-opacity, 0.32)}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--border-radius:2px;--box-shadow:0 28px 48px rgba(0, 0, 0, 0.4)}}.modal-wrapper{-webkit-transform:translate3d(0, 40px, 0);transform:translate3d(0, 40px, 0);opacity:0.01}'};export{et as ion_modal}
@@ -0,0 +1,4 @@
1
+ /*!
2
+ * (C) Ionic http://ionicframework.com - MIT License
3
+ */
4
+ const o="ion-focused",e="ion-focusable",n=["Tab","ArrowDown","Space","Escape"," ","Shift","Enter","ArrowLeft","ArrowRight","ArrowUp","Home","End"],t=t=>{let s=[],c=!1;const r=t?t.shadowRoot:document,i=t||document.body,u=e=>{s.forEach((e=>e.classList.remove(o))),e.forEach((e=>e.classList.add(o))),s=e},f=o=>{o instanceof PointerEvent&&""!==o.pointerType&&(c=!0,setTimeout((()=>{c=!1}),0))},d=o=>{c=!1,n.includes(o.key)||u([])},w=o=>{if(o.target.classList.contains(e)&&!c){const n=o.composedPath().filter((o=>o instanceof HTMLElement&&o.classList.contains(e)));u(n)}},a=()=>{r.activeElement===i&&u([])};return r.addEventListener("keydown",d),r.addEventListener("focusin",w),r.addEventListener("focusout",a),r.addEventListener("pointerdown",f,{passive:!0}),{destroy:()=>{r.removeEventListener("keydown",d),r.removeEventListener("focusin",w),r.removeEventListener("focusout",a),r.removeEventListener("pointerdown",f)},setFocus:u}};export{t as startFocusVisible}
@@ -31,9 +31,6 @@ export declare class Modal implements ComponentInterface, OverlayInterface {
31
31
  private workingDelegate?;
32
32
  private usersElement?;
33
33
  private gestureAnimationDismissing;
34
- private resizeListener?;
35
- private currentViewIsPortrait?;
36
- private viewTransitionAnimation?;
37
34
  lastFocus?: HTMLElement;
38
35
  animation?: Animation;
39
36
  presented: boolean;
@@ -326,8 +323,5 @@ export declare class Modal implements ComponentInterface, OverlayInterface {
326
323
  * if it exists and is focusable, otherwise let the focus trap handle it.
327
324
  */
328
325
  private onModalFocus;
329
- private initViewTransitionListener;
330
- private handleViewTransition;
331
- private cleanupViewTransitionListener;
332
326
  render(): any;
333
327
  }
package/hydrate/index.js CHANGED
@@ -10414,33 +10414,44 @@ const FOCUS_KEYS = [
10414
10414
  ];
10415
10415
  const startFocusVisible = (rootEl) => {
10416
10416
  let currentFocus = [];
10417
- let keyboardMode = true;
10417
+ // Tracks if the last interaction was a pointer event (mouse, touch, pen)
10418
+ // Used to distinguish between pointer and keyboard navigation for focus styling
10419
+ let hadPointerEvent = false;
10418
10420
  const ref = rootEl ? rootEl.shadowRoot : document;
10419
10421
  const root = rootEl ? rootEl : document.body;
10422
+ // Adds or removes the focused class for styling
10420
10423
  const setFocus = (elements) => {
10421
10424
  currentFocus.forEach((el) => el.classList.remove(ION_FOCUSED));
10422
10425
  elements.forEach((el) => el.classList.add(ION_FOCUSED));
10423
10426
  currentFocus = elements;
10424
10427
  };
10425
- const pointerDown = () => {
10426
- keyboardMode = false;
10427
- setFocus([]);
10428
+ // Do not set focus on pointer interactions
10429
+ const pointerDown = (ev) => {
10430
+ if (ev instanceof PointerEvent && ev.pointerType !== '') {
10431
+ hadPointerEvent = true;
10432
+ // Reset after the event loop so only the immediate focusin is suppressed
10433
+ setTimeout(() => {
10434
+ hadPointerEvent = false;
10435
+ }, 0);
10436
+ }
10428
10437
  };
10438
+ // Clear hadPointerEvent so keyboard navigation shows focus
10439
+ // Also, clear focus if the key is not a navigation key
10429
10440
  const onKeydown = (ev) => {
10430
- keyboardMode = FOCUS_KEYS.includes(ev.key);
10431
- if (!keyboardMode) {
10441
+ hadPointerEvent = false;
10442
+ const keyboardEvent = ev;
10443
+ if (!FOCUS_KEYS.includes(keyboardEvent.key)) {
10432
10444
  setFocus([]);
10433
10445
  }
10434
10446
  };
10447
+ // Set focus if the last interaction was NOT a pointer event
10448
+ // This works around iOS/Safari bugs where keydown is not fired for Tab
10435
10449
  const onFocusin = (ev) => {
10436
- if (keyboardMode && ev.composedPath !== undefined) {
10437
- const toFocus = ev.composedPath().filter((el) => {
10438
- // TODO(FW-2832): type
10439
- if (el.classList) {
10440
- return el.classList.contains(ION_FOCUSABLE);
10441
- }
10442
- return false;
10443
- });
10450
+ const target = ev.target;
10451
+ if (target.classList.contains(ION_FOCUSABLE) && !hadPointerEvent) {
10452
+ const toFocus = ev
10453
+ .composedPath()
10454
+ .filter((el) => el instanceof HTMLElement && el.classList.contains(ION_FOCUSABLE));
10444
10455
  setFocus(toFocus);
10445
10456
  }
10446
10457
  };
@@ -10452,14 +10463,12 @@ const startFocusVisible = (rootEl) => {
10452
10463
  ref.addEventListener('keydown', onKeydown);
10453
10464
  ref.addEventListener('focusin', onFocusin);
10454
10465
  ref.addEventListener('focusout', onFocusout);
10455
- ref.addEventListener('touchstart', pointerDown, { passive: true });
10456
- ref.addEventListener('mousedown', pointerDown);
10466
+ ref.addEventListener('pointerdown', pointerDown, { passive: true });
10457
10467
  const destroy = () => {
10458
10468
  ref.removeEventListener('keydown', onKeydown);
10459
10469
  ref.removeEventListener('focusin', onFocusin);
10460
10470
  ref.removeEventListener('focusout', onFocusout);
10461
- ref.removeEventListener('touchstart', pointerDown);
10462
- ref.removeEventListener('mousedown', pointerDown);
10471
+ ref.removeEventListener('pointerdown', pointerDown);
10463
10472
  };
10464
10473
  return {
10465
10474
  destroy,
@@ -21218,7 +21227,7 @@ const iosEnterAnimation$3 = (baseEl, opts) => {
21218
21227
  baseAnimation.addAnimation(contentAnimation);
21219
21228
  }
21220
21229
  if (presentingEl) {
21221
- const isPortrait = window.innerWidth < 768;
21230
+ const isMobile = window.innerWidth < 768;
21222
21231
  const hasCardModal = presentingEl.tagName === 'ION-MODAL' && presentingEl.presentingElement !== undefined;
21223
21232
  const presentingElRoot = getElementRoot(presentingEl);
21224
21233
  const presentingAnimation = createAnimation().beforeStyles({
@@ -21227,7 +21236,7 @@ const iosEnterAnimation$3 = (baseEl, opts) => {
21227
21236
  overflow: 'hidden',
21228
21237
  });
21229
21238
  const bodyEl = document.body;
21230
- if (isPortrait) {
21239
+ if (isMobile) {
21231
21240
  /**
21232
21241
  * Fallback for browsers that does not support `max()` (ex: Firefox)
21233
21242
  * No need to worry about statusbar padding since engines like Gecko
@@ -21305,7 +21314,7 @@ const iosLeaveAnimation$3 = (baseEl, opts, duration = 500) => {
21305
21314
  .duration(duration)
21306
21315
  .addAnimation(wrapperAnimation);
21307
21316
  if (presentingEl) {
21308
- const isPortrait = window.innerWidth < 768;
21317
+ const isMobile = window.innerWidth < 768;
21309
21318
  const hasCardModal = presentingEl.tagName === 'ION-MODAL' && presentingEl.presentingElement !== undefined;
21310
21319
  const presentingElRoot = getElementRoot(presentingEl);
21311
21320
  const presentingAnimation = createAnimation()
@@ -21323,7 +21332,7 @@ const iosLeaveAnimation$3 = (baseEl, opts, duration = 500) => {
21323
21332
  }
21324
21333
  });
21325
21334
  const bodyEl = document.body;
21326
- if (isPortrait) {
21335
+ if (isMobile) {
21327
21336
  const transformOffset = !CSS.supports('width', 'max(0px, 1px)') ? '30px' : 'max(30px, var(--ion-safe-area-top))';
21328
21337
  const modalTransform = hasCardModal ? '-10px' : transformOffset;
21329
21338
  const toPresentingScale = SwipeToCloseDefaults.MIN_PRESENTING_SCALE;
@@ -21370,144 +21379,6 @@ const iosLeaveAnimation$3 = (baseEl, opts, duration = 500) => {
21370
21379
  return baseAnimation;
21371
21380
  };
21372
21381
 
21373
- /**
21374
- * Transition animation from portrait view to landscape view
21375
- * This handles the case where a card modal is open in portrait view
21376
- * and the user switches to landscape view
21377
- */
21378
- const portraitToLandscapeTransition = (baseEl, opts, duration = 300) => {
21379
- const { presentingEl } = opts;
21380
- if (!presentingEl) {
21381
- // No transition needed for non-card modals
21382
- return createAnimation('portrait-to-landscape-transition');
21383
- }
21384
- const hasCardModal = presentingEl.tagName === 'ION-MODAL' && presentingEl.presentingElement !== undefined;
21385
- const presentingElRoot = getElementRoot(presentingEl);
21386
- const bodyEl = document.body;
21387
- const baseAnimation = createAnimation('portrait-to-landscape-transition')
21388
- .addElement(baseEl)
21389
- .easing('cubic-bezier(0.32,0.72,0,1)')
21390
- .duration(duration);
21391
- const presentingAnimation = createAnimation().beforeStyles({
21392
- transform: 'translateY(0)',
21393
- 'transform-origin': 'top center',
21394
- overflow: 'hidden',
21395
- });
21396
- if (!hasCardModal) {
21397
- // Non-card modal: transition from portrait state to landscape state
21398
- // Portrait: presentingEl has transform and body has black background
21399
- // Landscape: no transform, no body background, modal wrapper opacity changes
21400
- const root = getElementRoot(baseEl);
21401
- const wrapperAnimation = createAnimation()
21402
- .addElement(root.querySelectorAll('.modal-wrapper, .modal-shadow'))
21403
- .fromTo('opacity', '1', '1'); // Keep wrapper visible in landscape
21404
- const backdropAnimation = createAnimation()
21405
- .addElement(root.querySelector('ion-backdrop'))
21406
- .fromTo('opacity', 'var(--backdrop-opacity)', 'var(--backdrop-opacity)'); // Keep backdrop visible
21407
- // Animate presentingEl from portrait state back to normal
21408
- const transformOffset = !CSS.supports('width', 'max(0px, 1px)') ? '30px' : 'max(30px, var(--ion-safe-area-top))';
21409
- const toPresentingScale = SwipeToCloseDefaults.MIN_PRESENTING_SCALE;
21410
- const fromTransform = `translateY(${transformOffset}) scale(${toPresentingScale})`;
21411
- presentingAnimation
21412
- .addElement(presentingEl)
21413
- .afterStyles({
21414
- transform: 'translateY(0px) scale(1)',
21415
- 'border-radius': '0px',
21416
- })
21417
- .beforeAddWrite(() => bodyEl.style.setProperty('background-color', ''))
21418
- .fromTo('transform', fromTransform, 'translateY(0px) scale(1)')
21419
- .fromTo('filter', 'contrast(0.85)', 'contrast(1)')
21420
- .fromTo('border-radius', '10px 10px 0 0', '0px');
21421
- baseAnimation.addAnimation([presentingAnimation, wrapperAnimation, backdropAnimation]);
21422
- }
21423
- else {
21424
- // Card modal: transition from portrait card state to landscape card state
21425
- const toPresentingScale = SwipeToCloseDefaults.MIN_PRESENTING_SCALE;
21426
- const transformOffset = !CSS.supports('width', 'max(0px, 1px)') ? '30px' : 'max(30px, var(--ion-safe-area-top))';
21427
- const fromTransform = `translateY(${transformOffset}) scale(${toPresentingScale})`;
21428
- const toTransform = `translateY(-10px) scale(${toPresentingScale})`;
21429
- presentingAnimation
21430
- .addElement(presentingElRoot.querySelector('.modal-wrapper'))
21431
- .fromTo('transform', fromTransform, toTransform)
21432
- .fromTo('filter', 'contrast(0.85)', 'contrast(0.85)'); // Keep same contrast for card
21433
- const shadowAnimation = createAnimation()
21434
- .addElement(presentingElRoot.querySelector('.modal-shadow'))
21435
- .fromTo('opacity', '0', '0') // Shadow stays hidden in landscape for card modals
21436
- .fromTo('transform', fromTransform, toTransform);
21437
- baseAnimation.addAnimation([presentingAnimation, shadowAnimation]);
21438
- }
21439
- return baseAnimation;
21440
- };
21441
- /**
21442
- * Transition animation from landscape view to portrait view
21443
- * This handles the case where a card modal is open in landscape view
21444
- * and the user switches to portrait view
21445
- */
21446
- const landscapeToPortraitTransition = (baseEl, opts, duration = 300) => {
21447
- const { presentingEl } = opts;
21448
- if (!presentingEl) {
21449
- // No transition needed for non-card modals
21450
- return createAnimation('landscape-to-portrait-transition');
21451
- }
21452
- const hasCardModal = presentingEl.tagName === 'ION-MODAL' && presentingEl.presentingElement !== undefined;
21453
- const presentingElRoot = getElementRoot(presentingEl);
21454
- const bodyEl = document.body;
21455
- const baseAnimation = createAnimation('landscape-to-portrait-transition')
21456
- .addElement(baseEl)
21457
- .easing('cubic-bezier(0.32,0.72,0,1)')
21458
- .duration(duration);
21459
- const presentingAnimation = createAnimation().beforeStyles({
21460
- transform: 'translateY(0)',
21461
- 'transform-origin': 'top center',
21462
- overflow: 'hidden',
21463
- });
21464
- if (!hasCardModal) {
21465
- // Non-card modal: transition from landscape state to portrait state
21466
- const root = getElementRoot(baseEl);
21467
- const wrapperAnimation = createAnimation()
21468
- .addElement(root.querySelectorAll('.modal-wrapper, .modal-shadow'))
21469
- .fromTo('opacity', '1', '1'); // Keep wrapper visible
21470
- const backdropAnimation = createAnimation()
21471
- .addElement(root.querySelector('ion-backdrop'))
21472
- .fromTo('opacity', 'var(--backdrop-opacity)', 'var(--backdrop-opacity)'); // Keep backdrop visible
21473
- // Animate presentingEl from normal state to portrait state
21474
- const transformOffset = !CSS.supports('width', 'max(0px, 1px)') ? '30px' : 'max(30px, var(--ion-safe-area-top))';
21475
- const toPresentingScale = SwipeToCloseDefaults.MIN_PRESENTING_SCALE;
21476
- const toTransform = `translateY(${transformOffset}) scale(${toPresentingScale})`;
21477
- presentingAnimation
21478
- .addElement(presentingEl)
21479
- .afterStyles({
21480
- transform: toTransform,
21481
- 'border-radius': '10px 10px 0 0',
21482
- filter: 'contrast(0.85)',
21483
- overflow: 'hidden',
21484
- 'transform-origin': 'top center',
21485
- })
21486
- .beforeAddWrite(() => bodyEl.style.setProperty('background-color', 'black'))
21487
- .fromTo('transform', 'translateY(0px) scale(1)', toTransform)
21488
- .fromTo('filter', 'contrast(1)', 'contrast(0.85)')
21489
- .fromTo('border-radius', '0px', '10px 10px 0 0');
21490
- baseAnimation.addAnimation([presentingAnimation, wrapperAnimation, backdropAnimation]);
21491
- }
21492
- else {
21493
- // Card modal: transition from landscape card state to portrait card state
21494
- const toPresentingScale = SwipeToCloseDefaults.MIN_PRESENTING_SCALE;
21495
- const transformOffset = !CSS.supports('width', 'max(0px, 1px)') ? '30px' : 'max(30px, var(--ion-safe-area-top))';
21496
- const fromTransform = `translateY(-10px) scale(${toPresentingScale})`;
21497
- const toTransform = `translateY(${transformOffset}) scale(${toPresentingScale})`;
21498
- presentingAnimation
21499
- .addElement(presentingElRoot.querySelector('.modal-wrapper'))
21500
- .fromTo('transform', fromTransform, toTransform)
21501
- .fromTo('filter', 'contrast(0.85)', 'contrast(0.85)'); // Keep same contrast for card
21502
- const shadowAnimation = createAnimation()
21503
- .addElement(presentingElRoot.querySelector('.modal-shadow'))
21504
- .fromTo('opacity', '0', '0') // Shadow stays hidden
21505
- .fromTo('transform', fromTransform, toTransform);
21506
- baseAnimation.addAnimation([presentingAnimation, shadowAnimation]);
21507
- }
21508
- return baseAnimation;
21509
- };
21510
-
21511
21382
  const createEnterAnimation = () => {
21512
21383
  const backdropAnimation = createAnimation()
21513
21384
  .fromTo('opacity', 0.01, 'var(--backdrop-opacity)')
@@ -22299,7 +22170,6 @@ class Modal {
22299
22170
  }
22300
22171
  disconnectedCallback() {
22301
22172
  this.triggerController.removeClickListener();
22302
- this.cleanupViewTransitionListener();
22303
22173
  }
22304
22174
  componentWillLoad() {
22305
22175
  var _a;
@@ -22510,8 +22380,6 @@ class Modal {
22510
22380
  else if (hasCardModal) {
22511
22381
  this.initSwipeToClose();
22512
22382
  }
22513
- // Initialize view transition listener for iOS card modals
22514
- this.initViewTransitionListener();
22515
22383
  unlock();
22516
22384
  }
22517
22385
  initSwipeToClose() {
@@ -22665,7 +22533,6 @@ class Modal {
22665
22533
  if (this.gesture) {
22666
22534
  this.gesture.destroy();
22667
22535
  }
22668
- this.cleanupViewTransitionListener();
22669
22536
  }
22670
22537
  this.currentBreakpoint = undefined;
22671
22538
  this.animation = undefined;
@@ -22741,76 +22608,6 @@ class Modal {
22741
22608
  await this.setCurrentBreakpoint(nextBreakpoint);
22742
22609
  return true;
22743
22610
  }
22744
- initViewTransitionListener() {
22745
- // Only enable for iOS card modals when no custom animations are provided
22746
- if (getIonMode$1(this) !== 'ios' || !this.presentingElement || this.enterAnimation || this.leaveAnimation) {
22747
- return;
22748
- }
22749
- // Set initial view state
22750
- this.currentViewIsPortrait = window.innerWidth < 768;
22751
- // Create debounced resize handler
22752
- let resizeTimeout;
22753
- this.resizeListener = () => {
22754
- clearTimeout(resizeTimeout);
22755
- resizeTimeout = setTimeout(() => {
22756
- this.handleViewTransition();
22757
- }, 100); // Debounce for 100ms to avoid excessive calls
22758
- };
22759
- window.addEventListener('resize', this.resizeListener);
22760
- }
22761
- handleViewTransition() {
22762
- const isPortrait = window.innerWidth < 768;
22763
- // Only transition if view state actually changed
22764
- if (this.currentViewIsPortrait === isPortrait) {
22765
- return;
22766
- }
22767
- // Cancel any ongoing transition animation
22768
- if (this.viewTransitionAnimation) {
22769
- this.viewTransitionAnimation.destroy();
22770
- this.viewTransitionAnimation = undefined;
22771
- }
22772
- const { presentingElement } = this;
22773
- if (!presentingElement) {
22774
- return;
22775
- }
22776
- // Create transition animation
22777
- let transitionAnimation;
22778
- if (this.currentViewIsPortrait && !isPortrait) {
22779
- // Portrait to landscape transition
22780
- transitionAnimation = portraitToLandscapeTransition(this.el, {
22781
- presentingEl: presentingElement});
22782
- }
22783
- else {
22784
- // Landscape to portrait transition
22785
- transitionAnimation = landscapeToPortraitTransition(this.el, {
22786
- presentingEl: presentingElement});
22787
- }
22788
- // Update state and play animation
22789
- this.currentViewIsPortrait = isPortrait;
22790
- this.viewTransitionAnimation = transitionAnimation;
22791
- transitionAnimation.play().then(() => {
22792
- this.viewTransitionAnimation = undefined;
22793
- });
22794
- }
22795
- cleanupViewTransitionListener() {
22796
- const hasCardView = !!this.resizeListener;
22797
- if (this.resizeListener) {
22798
- window.removeEventListener('resize', this.resizeListener);
22799
- this.resizeListener = undefined;
22800
- }
22801
- if (this.viewTransitionAnimation) {
22802
- this.viewTransitionAnimation.destroy();
22803
- this.viewTransitionAnimation = undefined;
22804
- }
22805
- if (hasCardView) {
22806
- // If we had a card view, let's trigger the view transition
22807
- // one last time to make sure we're in the right state.
22808
- // This will prevent tricky things like resizing the modal causing
22809
- // it to dismiss programatically too quickly and preventing the view transition
22810
- // from being applied.
22811
- this.handleViewTransition();
22812
- }
22813
- }
22814
22611
  render() {
22815
22612
  const { handle, isSheetModal, presentingElement, htmlAttributes, handleBehavior, inheritedAttributes, focusTrap, expandToScroll, } = this;
22816
22613
  const showHandle = handle !== false && isSheetModal;
@@ -22818,20 +22615,20 @@ class Modal {
22818
22615
  const isCardModal = presentingElement !== undefined && mode === 'ios';
22819
22616
  const isHandleCycle = handleBehavior === 'cycle';
22820
22617
  const isSheetModalWithHandle = isSheetModal && showHandle;
22821
- return (hAsync(Host, Object.assign({ key: '857fbf50b5d0b43c1f1a335d740649cedf1d6e2b', "no-router": true,
22618
+ return (hAsync(Host, Object.assign({ key: '8add05bb43a2cdb5e3cf180147d31eb85a018fe0', "no-router": true,
22822
22619
  // Allow the modal to be navigable when the handle is focusable
22823
22620
  tabIndex: isHandleCycle && isSheetModalWithHandle ? 0 : -1 }, htmlAttributes, { style: {
22824
22621
  zIndex: `${20000 + this.overlayIndex}`,
22825
- }, class: Object.assign({ [mode]: true, ['modal-default']: !isCardModal && !isSheetModal, [`modal-card`]: isCardModal, [`modal-sheet`]: isSheetModal, [`modal-no-expand-scroll`]: isSheetModal && !expandToScroll, 'overlay-hidden': true, [FOCUS_TRAP_DISABLE_CLASS]: focusTrap === false }, getClassMap(this.cssClass)), onIonBackdropTap: this.onBackdropTap, onIonModalDidPresent: this.onLifecycle, onIonModalWillPresent: this.onLifecycle, onIonModalWillDismiss: this.onLifecycle, onIonModalDidDismiss: this.onLifecycle, onFocus: this.onModalFocus }), hAsync("ion-backdrop", { key: '07b6143d368748194e4b209b48c7d9efbeed12e0', ref: (el) => (this.backdropEl = el), visible: this.showBackdrop, tappable: this.backdropDismiss, part: "backdrop" }), mode === 'ios' && hAsync("div", { key: '14eaf25ad683ca5c7369e69908ea93401dd5536b', class: "modal-shadow" }), hAsync("div", Object.assign({ key: '9b996da27066c8dfdce8fcf3abdff65948010b5e',
22622
+ }, class: Object.assign({ [mode]: true, ['modal-default']: !isCardModal && !isSheetModal, [`modal-card`]: isCardModal, [`modal-sheet`]: isSheetModal, [`modal-no-expand-scroll`]: isSheetModal && !expandToScroll, 'overlay-hidden': true, [FOCUS_TRAP_DISABLE_CLASS]: focusTrap === false }, getClassMap(this.cssClass)), onIonBackdropTap: this.onBackdropTap, onIonModalDidPresent: this.onLifecycle, onIonModalWillPresent: this.onLifecycle, onIonModalWillDismiss: this.onLifecycle, onIonModalDidDismiss: this.onLifecycle, onFocus: this.onModalFocus }), hAsync("ion-backdrop", { key: '90a6605a9564a699d6f66cf71cf6b506796a2963', ref: (el) => (this.backdropEl = el), visible: this.showBackdrop, tappable: this.backdropDismiss, part: "backdrop" }), mode === 'ios' && hAsync("div", { key: 'a97d071395333bf803c0a9347bda000cf7500d8d', class: "modal-shadow" }), hAsync("div", Object.assign({ key: 'e7b7985c7414a13e3ba8dcecf497b76e92edf53e',
22826
22623
  /*
22827
22624
  role and aria-modal must be used on the
22828
22625
  same element. They must also be set inside the
22829
22626
  shadow DOM otherwise ion-button will not be highlighted
22830
22627
  when using VoiceOver: https://bugs.webkit.org/show_bug.cgi?id=247134
22831
22628
  */
22832
- role: "dialog" }, inheritedAttributes, { "aria-modal": "true", class: "modal-wrapper ion-overlay-wrapper", part: "content", ref: (el) => (this.wrapperEl = el) }), showHandle && (hAsync("button", { key: 'd3b429aa40e094548a5eeaa295f4cb1b1f921339', class: "modal-handle",
22629
+ role: "dialog" }, inheritedAttributes, { "aria-modal": "true", class: "modal-wrapper ion-overlay-wrapper", part: "content", ref: (el) => (this.wrapperEl = el) }), showHandle && (hAsync("button", { key: '8258b65570b11a8ee9c9df2537d6419cd2e34536', class: "modal-handle",
22833
22630
  // Prevents the handle from receiving keyboard focus when it does not cycle
22834
- tabIndex: !isHandleCycle ? -1 : 0, "aria-label": "Activate to adjust the size of the dialog overlaying the screen", onClick: isHandleCycle ? this.onHandleClick : undefined, part: "handle", ref: (el) => (this.dragHandleEl = el) })), hAsync("slot", { key: '86160fcdf92d6ca2a9afe5c801efb89c32ce2cc1' }))));
22631
+ tabIndex: !isHandleCycle ? -1 : 0, "aria-label": "Activate to adjust the size of the dialog overlaying the screen", onClick: isHandleCycle ? this.onHandleClick : undefined, part: "handle", ref: (el) => (this.dragHandleEl = el) })), hAsync("slot", { key: '394370d0ed03ee03152f8f8abae7ff7664ca5c13' }))));
22835
22632
  }
22836
22633
  get el() { return getElement(this); }
22837
22634
  static get watchers() { return {
@@ -32856,7 +32653,7 @@ class Select {
32856
32653
  const scrollSelectedIntoView = () => {
32857
32654
  const indexOfSelected = this.childOpts.findIndex((o) => o.value === this.value);
32858
32655
  if (indexOfSelected > -1) {
32859
- const selectedItem = overlay.querySelector(`.select-interface-option:nth-child(${indexOfSelected + 1})`);
32656
+ const selectedItem = overlay.querySelector(`.select-interface-option:nth-of-type(${indexOfSelected + 1})`);
32860
32657
  if (selectedItem) {
32861
32658
  /**
32862
32659
  * Browsers such as Firefox do not
@@ -33376,7 +33173,7 @@ class Select {
33376
33173
  * TODO(FW-5592): Remove hasStartEndSlots condition
33377
33174
  */
33378
33175
  const labelShouldFloat = labelPlacement === 'stacked' || (labelPlacement === 'floating' && (hasValue || isExpanded || hasStartEndSlots));
33379
- return (hAsync(Host, { key: 'e33253af9b9daa14460c7c259fb138b4d2b875ae', onClick: this.onClick, class: createColorClasses$1(this.color, {
33176
+ return (hAsync(Host, { key: 'c03fb65e8fc9f9aab295e07b282377d57d910519', onClick: this.onClick, class: createColorClasses$1(this.color, {
33380
33177
  [mode]: true,
33381
33178
  'in-item': inItem,
33382
33179
  'in-item-color': hostContext('ion-item.ion-color', el),
@@ -33394,7 +33191,7 @@ class Select {
33394
33191
  [`select-justify-${justify}`]: justifyEnabled,
33395
33192
  [`select-shape-${shape}`]: shape !== undefined,
33396
33193
  [`select-label-placement-${labelPlacement}`]: true,
33397
- }) }, hAsync("label", { key: '03303b7131c77a78a933e8e496e7251b6b5c485b', class: "select-wrapper", id: "select-label", onClick: this.onLabelClick }, this.renderLabelContainer(), hAsync("div", { key: '9037674db6a0adc189e887c9048f817d5afdf635', class: "select-wrapper-inner" }, hAsync("slot", { key: '7c9226c838ba4bcf5bc0b234fa1613ce335cf73d', name: "start" }), hAsync("div", { key: 'a7432c3efb5c65f88a5e4b0d35c5a433fa4e949d', class: "native-wrapper", ref: (el) => (this.nativeWrapperEl = el), part: "container" }, this.renderSelectText(), this.renderListbox()), hAsync("slot", { key: '028e683df26a8f573d7670da76e0ad26d21c83e0', name: "end" }), !hasFloatingOrStackedLabel && this.renderSelectIcon()), hasFloatingOrStackedLabel && this.renderSelectIcon(), shouldRenderHighlight && hAsync("div", { key: '20341bcae3753048ce905d2aceffa5351a0db125', class: "select-highlight" })), this.renderBottomContent()));
33194
+ }) }, hAsync("label", { key: '0d0c8ec55269adcac625f2899a547f4e7f3e3741', class: "select-wrapper", id: "select-label", onClick: this.onLabelClick }, this.renderLabelContainer(), hAsync("div", { key: 'f6dfc93c0e23cbe75a2947abde67d842db2dad78', class: "select-wrapper-inner" }, hAsync("slot", { key: '957bfadf9f101f519091419a362d3abdc2be66f6', name: "start" }), hAsync("div", { key: 'ca349202a484e7f2e884533fd330f0b136754f7d', class: "native-wrapper", ref: (el) => (this.nativeWrapperEl = el), part: "container" }, this.renderSelectText(), this.renderListbox()), hAsync("slot", { key: 'f0e62a6533ff1c8f62bd2d27f60b23385c4fa9ed', name: "end" }), !hasFloatingOrStackedLabel && this.renderSelectIcon()), hasFloatingOrStackedLabel && this.renderSelectIcon(), shouldRenderHighlight && hAsync("div", { key: 'fb840d46bafafb09898ebeebbe8c181906a3d8a2', class: "select-highlight" })), this.renderBottomContent()));
33398
33195
  }
33399
33196
  get el() { return getElement(this); }
33400
33197
  static get watchers() { return {