@ionic/core 9.0.7-dev.11790871695.14a4111c → 9.0.7-dev.11791305593.188c8151

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 (115) hide show
  1. package/components/index.js +1 -1
  2. package/components/ion-action-sheet.js +1 -1
  3. package/components/ion-alert.js +1 -1
  4. package/components/ion-app.js +1 -1
  5. package/components/ion-content.js +1 -1
  6. package/components/ion-datetime.js +1 -1
  7. package/components/ion-input-otp.js +1 -1
  8. package/components/ion-loading.js +1 -1
  9. package/components/ion-menu-button.js +1 -1
  10. package/components/ion-menu-toggle.js +1 -1
  11. package/components/ion-menu.js +1 -1
  12. package/components/ion-modal.js +1 -1
  13. package/components/ion-popover.js +1 -1
  14. package/components/ion-select-modal.js +1 -1
  15. package/components/ion-select-popover.js +1 -1
  16. package/components/ion-select.js +1 -1
  17. package/components/ion-toast.js +1 -1
  18. package/components/{p-BinR4_P7.js → p-4QPSgC9s.js} +1 -1
  19. package/components/{p-CiXOsJF2.js → p-BHFF2Rku.js} +1 -1
  20. package/components/{p-DPyjiKOq.js → p-BRCkmCrc.js} +1 -1
  21. package/components/p-BsOZAFNI.js +4 -0
  22. package/components/p-CArDvZQz.js +4 -0
  23. package/components/{p-PPagT42x.js → p-CB2RQcuo.js} +1 -1
  24. package/components/p-CKtw0kcb.js +4 -0
  25. package/components/{p-CvzE7FFp.js → p-CZlKzXag.js} +1 -1
  26. package/components/p-CgwJ4NuD.js +4 -0
  27. package/components/{p-CQjNc-Pz.js → p-DjbwrsJd.js} +1 -1
  28. package/components/p-vg8joG77.js +4 -0
  29. package/css/core.css.map +1 -1
  30. package/css/display.css.map +1 -1
  31. package/css/flex-utils.css.map +1 -1
  32. package/css/float-elements.css +1 -1
  33. package/css/float-elements.css.map +1 -1
  34. package/css/global.bundle.css.map +1 -1
  35. package/css/ionic.bundle.css +1 -1
  36. package/css/ionic.bundle.css.map +1 -1
  37. package/css/padding.css.map +1 -1
  38. package/css/structure.css.map +1 -1
  39. package/css/text-alignment.css.map +1 -1
  40. package/css/text-transformation.css.map +1 -1
  41. package/css/typography.css.map +1 -1
  42. package/css/utils.bundle.css +1 -1
  43. package/css/utils.bundle.css.map +1 -1
  44. package/dist/cjs/{index-CElfU-dK.js → index-fm08amr6.js} +2 -1
  45. package/dist/cjs/index.cjs.js +2 -2
  46. package/dist/cjs/ion-action-sheet.cjs.entry.js +1 -1
  47. package/dist/cjs/ion-alert.cjs.entry.js +1 -1
  48. package/dist/cjs/ion-app_8.cjs.entry.js +2 -2
  49. package/dist/cjs/ion-datetime.cjs.entry.js +1 -1
  50. package/dist/cjs/ion-input-otp.cjs.entry.js +30 -5
  51. package/dist/cjs/ion-loading.cjs.entry.js +1 -1
  52. package/dist/cjs/ion-menu_3.cjs.entry.js +5 -4
  53. package/dist/cjs/ion-modal.cjs.entry.js +1 -1
  54. package/dist/cjs/ion-popover.cjs.entry.js +1 -1
  55. package/dist/cjs/ion-select-modal.cjs.entry.js +1 -1
  56. package/dist/cjs/ion-select_3.cjs.entry.js +1 -1
  57. package/dist/cjs/ion-toast.cjs.entry.js +1 -1
  58. package/dist/cjs/ionic.cjs.js +1 -1
  59. package/dist/cjs/loader.cjs.js +1 -1
  60. package/dist/cjs/{overlays-C68wNDWY.js → overlays-CEt1Pxnd.js} +75 -16
  61. package/dist/collection/components/input-otp/input-otp.js +29 -3
  62. package/dist/collection/components/menu/menu.js +4 -3
  63. package/dist/collection/utils/hardware-back-button.js +41 -12
  64. package/dist/collection/utils/menu-controller/index.js +2 -1
  65. package/dist/collection/utils/overlays.js +30 -4
  66. package/dist/docs.json +1 -1
  67. package/dist/esm/{index-B9jhwvmO.js → index-CzPyKjAQ.js} +2 -1
  68. package/dist/esm/index.js +2 -2
  69. package/dist/esm/ion-action-sheet.entry.js +1 -1
  70. package/dist/esm/ion-alert.entry.js +1 -1
  71. package/dist/esm/ion-app_8.entry.js +2 -2
  72. package/dist/esm/ion-datetime.entry.js +1 -1
  73. package/dist/esm/ion-input-otp.entry.js +30 -5
  74. package/dist/esm/ion-loading.entry.js +1 -1
  75. package/dist/esm/ion-menu_3.entry.js +5 -4
  76. package/dist/esm/ion-modal.entry.js +1 -1
  77. package/dist/esm/ion-popover.entry.js +1 -1
  78. package/dist/esm/ion-select-modal.entry.js +1 -1
  79. package/dist/esm/ion-select_3.entry.js +1 -1
  80. package/dist/esm/ion-toast.entry.js +1 -1
  81. package/dist/esm/ionic.js +1 -1
  82. package/dist/esm/loader.js +1 -1
  83. package/dist/esm/{overlays-BQnV0HAU.js → overlays-D5W_ly69.js} +74 -17
  84. package/dist/ionic/index.esm.js +1 -1
  85. package/dist/ionic/ionic.esm.js +1 -1
  86. package/dist/ionic/{p-3a5faaa8.entry.js → p-0111c108.entry.js} +1 -1
  87. package/dist/ionic/{p-636349e2.entry.js → p-22160ced.entry.js} +1 -1
  88. package/dist/ionic/{p-24b0a961.entry.js → p-5112a8ba.entry.js} +1 -1
  89. package/dist/ionic/{p-f9057f70.entry.js → p-5edc856b.entry.js} +1 -1
  90. package/dist/ionic/{p-3bd7e5df.entry.js → p-8a00d904.entry.js} +1 -1
  91. package/dist/ionic/p-C036rEeA.js +4 -0
  92. package/dist/ionic/p-OJpZr8fg.js +4 -0
  93. package/dist/ionic/p-b3346b86.entry.js +4 -0
  94. package/dist/ionic/{p-efa00ce5.entry.js → p-b798b4ec.entry.js} +1 -1
  95. package/dist/ionic/{p-30dcf43b.entry.js → p-d0451c11.entry.js} +1 -1
  96. package/dist/ionic/{p-76309bab.entry.js → p-e063a7bf.entry.js} +1 -1
  97. package/dist/ionic/p-f5dfb3a0.entry.js +4 -0
  98. package/dist/ionic/{p-b1164028.entry.js → p-ff664022.entry.js} +1 -1
  99. package/dist/ionic/{p-7441ed2b.entry.js → p-ffd45970.entry.js} +1 -1
  100. package/dist/types/components/input-otp/input-otp.d.ts +7 -0
  101. package/dist/types/utils/config.d.ts +4 -1
  102. package/dist/types/utils/hardware-back-button.d.ts +11 -0
  103. package/dist/types/utils/overlays.d.ts +5 -2
  104. package/hydrate/index.js +43 -10
  105. package/hydrate/index.mjs +43 -10
  106. package/package.json +1 -1
  107. package/components/p-BNnmwjuy.js +0 -4
  108. package/components/p-BsLM9eQu.js +0 -4
  109. package/components/p-DGLuPe1e.js +0 -4
  110. package/components/p-WMQuK_Tj.js +0 -4
  111. package/components/p-q2WJ5Igc.js +0 -4
  112. package/dist/ionic/p-83448626.entry.js +0 -4
  113. package/dist/ionic/p-Ba6ZV-qU.js +0 -4
  114. package/dist/ionic/p-DZUqAr_6.js +0 -4
  115. package/dist/ionic/p-edcb63e5.entry.js +0 -4
@@ -18,6 +18,11 @@ export declare class InputOTP implements ComponentInterface {
18
18
  * focus behavior when an input box is focused.
19
19
  */
20
20
  private isKeyboardNavigation;
21
+ /**
22
+ * The `length` watcher runs before new inputs render, so
23
+ * `componentDidRender` updates their tab indexes instead.
24
+ */
25
+ private updateTabIndexesAfterRender;
21
26
  el: HTMLIonInputOtpElement;
22
27
  private inputValues;
23
28
  hasFocus: boolean;
@@ -137,6 +142,7 @@ export declare class InputOTP implements ComponentInterface {
137
142
  */
138
143
  setFocus(index?: number): Promise<void>;
139
144
  valueChanged(): void;
145
+ lengthChanged(): void;
140
146
  /**
141
147
  * Processes the separators prop into an array of numbers.
142
148
  *
@@ -150,6 +156,7 @@ export declare class InputOTP implements ComponentInterface {
150
156
  private processSeparators;
151
157
  componentWillLoad(): void;
152
158
  componentDidLoad(): void;
159
+ componentDidRender(): void;
153
160
  /**
154
161
  * Get the regex pattern for allowed characters.
155
162
  * If a pattern is provided, use it to create a regex pattern
@@ -168,7 +168,10 @@ export interface IonicConfig {
168
168
  /**
169
169
  * @experimental
170
170
  * If `true`, the [CloseWatcher API](https://github.com/WICG/close-watcher) will be used to handle
171
- * all Escape key and hardware back button presses to dismiss menus and overlays and to navigate.
171
+ * Escape key and Android back button presses that dismiss menus and overlays. It's only active
172
+ * while a menu or an overlay other than a toast is open, so back navigation works as usual
173
+ * otherwise. Hybrid apps still handle the hardware back button through the native `backbutton`
174
+ * event.
172
175
  * Note that the `hardwareBackButton` config option must also be `true`.
173
176
  */
174
177
  experimentalCloseWatcher?: boolean;
@@ -26,6 +26,17 @@ export declare const shouldUseCloseWatcher: () => any;
26
26
  * will still happen.
27
27
  */
28
28
  export declare const blockHardwareBackButton: () => void;
29
+ /**
30
+ * Registers a check for whether the back button
31
+ * has something to close. The CloseWatcher is only
32
+ * active while one of these checks passes.
33
+ */
34
+ export declare const addCloseWatcherCondition: (condition: () => boolean) => void;
35
+ /**
36
+ * Call this whenever something the back button
37
+ * can close opens or closes.
38
+ */
39
+ export declare const updateCloseWatcher: () => void;
29
40
  export declare const startHardwareBackButton: () => void;
30
41
  export declare const OVERLAY_BACK_BUTTON_PRIORITY = 100;
31
42
  export declare const MENU_BACK_BUTTON_PRIORITY = 99;
@@ -82,7 +82,8 @@ export declare const setRootAriaHidden: (hidden?: boolean) => void;
82
82
  * Cleans up root `aria-hidden` and `backdrop-no-scroll` when
83
83
  * an overlay is removed from the DOM without going through
84
84
  * the `dismiss()` flow (e.g., when a framework unmounts the
85
- * overlay during a route change).
85
+ * overlay during a route change). Also releases the
86
+ * CloseWatcher if nothing is left to close.
86
87
  *
87
88
  * Should be called from an overlay's `disconnectedCallback`
88
89
  * when the overlay was still presented at the time of removal.
@@ -90,7 +91,9 @@ export declare const setRootAriaHidden: (hidden?: boolean) => void;
90
91
  export declare const cleanupRootFocusTrapAccessibility: () => void;
91
92
  /**
92
93
  * Re-applies the root lock that `cleanupRootFocusTrapAccessibility()` released.
93
- * Call from `connectedCallback` when the overlay is still presented.
94
+ * Call from `connectedCallback` when the overlay is still presented. Also
95
+ * re-arms the CloseWatcher, which every overlay needs, so that happens
96
+ * before the `locksAppRoot` check.
94
97
  *
95
98
  * A synchronous move keeps the overlay connected, so the lock survives. A
96
99
  * detach with a re-insert in a later task releases it, which is the shape a
package/hydrate/index.js CHANGED
@@ -8083,6 +8083,11 @@ const CoreDelegate = () => {
8083
8083
 
8084
8084
  let lastOverlayIndex = 0;
8085
8085
  let lastId = 0;
8086
+ /**
8087
+ * Every overlay except toast, which doesn't trap
8088
+ * focus or close on back.
8089
+ */
8090
+ const NON_TOAST_OVERLAYS = 'ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-popover';
8086
8091
  const activeAnimations = new WeakMap();
8087
8092
  /**
8088
8093
  * Determines if the overlay's backdrop is always blocking (no background interaction).
@@ -8207,7 +8212,7 @@ const focusElementInOverlay = (hostToFocus, overlay) => {
8207
8212
  * Should NOT include: Toast
8208
8213
  */
8209
8214
  const trapKeyboardFocus = (ev, doc) => {
8210
- const lastOverlay = getPresentedOverlay(doc, 'ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-popover');
8215
+ const lastOverlay = getPresentedOverlay(doc, NON_TOAST_OVERLAYS);
8211
8216
  const target = ev.target;
8212
8217
  /**
8213
8218
  * If no active overlay, ignore this event.
@@ -8513,7 +8518,8 @@ const setRootAriaHidden = (hidden = false) => {
8513
8518
  * Cleans up root `aria-hidden` and `backdrop-no-scroll` when
8514
8519
  * an overlay is removed from the DOM without going through
8515
8520
  * the `dismiss()` flow (e.g., when a framework unmounts the
8516
- * overlay during a route change).
8521
+ * overlay during a route change). Also releases the
8522
+ * CloseWatcher if nothing is left to close.
8517
8523
  *
8518
8524
  * Should be called from an overlay's `disconnectedCallback`
8519
8525
  * when the overlay was still presented at the time of removal.
@@ -8543,7 +8549,9 @@ const applyRootLock = (el) => {
8543
8549
  };
8544
8550
  /**
8545
8551
  * Re-applies the root lock that `cleanupRootFocusTrapAccessibility()` released.
8546
- * Call from `connectedCallback` when the overlay is still presented.
8552
+ * Call from `connectedCallback` when the overlay is still presented. Also
8553
+ * re-arms the CloseWatcher, which every overlay needs, so that happens
8554
+ * before the `locksAppRoot` check.
8547
8555
  *
8548
8556
  * A synchronous move keeps the overlay connected, so the lock survives. A
8549
8557
  * detach with a re-insert in a later task releases it, which is the shape a
@@ -21254,6 +21262,11 @@ class InputOTP {
21254
21262
  * focus behavior when an input box is focused.
21255
21263
  */
21256
21264
  this.isKeyboardNavigation = false;
21265
+ /**
21266
+ * The `length` watcher runs before new inputs render, so
21267
+ * `componentDidRender` updates their tab indexes instead.
21268
+ */
21269
+ this.updateTabIndexesAfterRender = false;
21257
21270
  this.inputValues = [];
21258
21271
  this.hasFocus = false;
21259
21272
  this.previousInputValues = [];
@@ -21613,6 +21626,10 @@ class InputOTP {
21613
21626
  this.initializeValues();
21614
21627
  this.updateTabIndexes();
21615
21628
  }
21629
+ lengthChanged() {
21630
+ this.initializeValues();
21631
+ this.updateTabIndexesAfterRender = true;
21632
+ }
21616
21633
  /**
21617
21634
  * Processes the separators prop into an array of numbers.
21618
21635
  *
@@ -21669,6 +21686,12 @@ class InputOTP {
21669
21686
  componentDidLoad() {
21670
21687
  this.updateTabIndexes();
21671
21688
  }
21689
+ componentDidRender() {
21690
+ if (this.updateTabIndexesAfterRender) {
21691
+ this.updateTabIndexesAfterRender = false;
21692
+ this.updateTabIndexes();
21693
+ }
21694
+ }
21672
21695
  /**
21673
21696
  * Get the regex pattern for allowed characters.
21674
21697
  * If a pattern is provided, use it to create a regex pattern
@@ -21846,7 +21869,7 @@ class InputOTP {
21846
21869
  const tabbableIndex = this.getTabbableIndex();
21847
21870
  const pattern = this.getPattern();
21848
21871
  const hasDescription = el.querySelector('.input-otp-description')?.textContent?.trim() !== '';
21849
- return (hAsync(Host, { key: 'bd37661e13cde21feff30c663e6813ce3fff0d9a', class: createColorClasses$1(color, {
21872
+ return (hAsync(Host, { key: 'def9fbd4fa135e6f435380c6ea86ac1621b4a111', class: createColorClasses$1(color, {
21850
21873
  [mode]: true,
21851
21874
  'has-focus': hasFocus,
21852
21875
  [`input-otp-size-${size}`]: true,
@@ -21854,20 +21877,30 @@ class InputOTP {
21854
21877
  [`input-otp-fill-${fill}`]: true,
21855
21878
  'input-otp-disabled': disabled,
21856
21879
  'input-otp-readonly': readonly,
21857
- }) }, hAsync("div", { key: '5e206f870024f1ecfebda999ff31e6e815774deb', role: "group", "aria-label": "One-time password input", class: "input-otp-group", ...inheritedAttributes }, Array.from({ length }).map((_, index) => (hAsync(Fragment, null, hAsync("div", { class: "native-wrapper" }, hAsync("input", { class: "native-input", id: `${inputId}-${index}`, "aria-label": `Input ${index + 1} of ${length}`, type: "text", autoCapitalize: autocapitalize, inputmode: inputmode, pattern: pattern, disabled: disabled, readOnly: readonly, tabIndex: index === tabbableIndex ? 0 : -1, value: inputValues[index] || '', autocomplete: "one-time-code", ref: (el) => (inputRefs[index] = el), onInput: this.onInput(index), onBlur: this.onBlur, onFocus: this.onFocus(index), onKeyDown: this.onKeyDown(index), onPaste: this.onPaste })), this.showSeparator(index) && hAsync("div", { class: "input-otp-separator" }))))), hAsync("div", { key: 'c268f838ddab2c8d6a612a11c7d38e6ca076436d', class: {
21880
+ }) }, hAsync("div", { key: '5d3d7646a3d4fc856b7b2e1f53d29fca47b10baf', role: "group", "aria-label": "One-time password input", class: "input-otp-group", ...inheritedAttributes }, Array.from({ length }).map((_, index) => (hAsync(Fragment, null, hAsync("div", { class: "native-wrapper" }, hAsync("input", { class: "native-input", id: `${inputId}-${index}`, "aria-label": `Input ${index + 1} of ${length}`, type: "text", autoCapitalize: autocapitalize, inputmode: inputmode, pattern: pattern, disabled: disabled, readOnly: readonly, tabIndex: index === tabbableIndex ? 0 : -1, value: inputValues[index] || '', autocomplete: "one-time-code", ref: (el) => {
21881
+ if (el) {
21882
+ inputRefs[index] = el;
21883
+ }
21884
+ else {
21885
+ // The input was removed, so drop its ref and any after it.
21886
+ inputRefs.splice(index);
21887
+ }
21888
+ }, onInput: this.onInput(index), onBlur: this.onBlur, onFocus: this.onFocus(index), onKeyDown: this.onKeyDown(index), onPaste: this.onPaste })), this.showSeparator(index) && hAsync("div", { class: "input-otp-separator" }))))), hAsync("div", { key: '9d72a4ab35b5fdd6bba9701050c385ed253b310f', class: {
21858
21889
  'input-otp-description': true,
21859
21890
  'input-otp-description-hidden': !hasDescription,
21860
- } }, hAsync("slot", { key: 'c0736359b26f609b795e399fc1ad9b540632af18' }))));
21891
+ } }, hAsync("slot", { key: '7deb3373c0d4e5deac22fa51577d271b9bb3a6d2' }))));
21861
21892
  }
21862
21893
  get el() { return getElement(this); }
21863
21894
  static get watchers() { return {
21864
21895
  "value": [{
21865
21896
  "valueChanged": 0
21866
21897
  }],
21867
- "separators": [{
21898
+ "length": [{
21899
+ "lengthChanged": 0
21900
+ }, {
21868
21901
  "processSeparators": 0
21869
21902
  }],
21870
- "length": [{
21903
+ "separators": [{
21871
21904
  "processSeparators": 0
21872
21905
  }]
21873
21906
  }; }
@@ -24579,14 +24612,14 @@ class Menu {
24579
24612
  * the ionBackButton listener in the menu controller
24580
24613
  * will handle closing the menu when Escape is pressed.
24581
24614
  */
24582
- return (hAsync(Host, { key: '1208ba437fa58680325408d3d4c8580950da1d68', onKeyDown: shouldUseCloseWatcher() ? null : this.onKeydown, role: "navigation", "aria-label": inheritedAttributes['aria-label'] || 'menu', class: {
24615
+ return (hAsync(Host, { key: '5cf26df26d4e539860cbeaea98ec621b98c3fcfc', onKeyDown: shouldUseCloseWatcher() ? null : this.onKeydown, role: "navigation", "aria-label": inheritedAttributes['aria-label'] || 'menu', class: {
24583
24616
  [mode]: true,
24584
24617
  [`menu-type-${type}`]: true,
24585
24618
  'menu-enabled': !disabled,
24586
24619
  [`menu-side-${side}`]: true,
24587
24620
  'menu-pane-visible': isPaneVisible,
24588
24621
  'split-pane-side': hostContext('ion-split-pane', el),
24589
- } }, hAsync("div", { key: 'c0ddc957b7a7956b41901d77ae02d91e73071c55', class: "menu-inner", part: "container", ref: (el) => (this.menuInnerEl = el) }, hAsync("slot", { key: '6e44c56116431a024f114ab85ded1b822c942fac' })), hAsync("ion-backdrop", { key: '5f4bbcf84444d96ec6b02bf567e1aaf95f59078d', ref: (el) => (this.backdropEl = el), class: "menu-backdrop", tappable: false, stopPropagation: false, part: "backdrop" })));
24622
+ } }, hAsync("div", { key: 'f337016e293bb8665c99762e0c389dd6c372bb33', class: "menu-inner", part: "container", ref: (el) => (this.menuInnerEl = el) }, hAsync("slot", { key: '4c3fe331aa42cd57d7ad9bd1f5910f8eeb62d7da' })), hAsync("ion-backdrop", { key: '61af7ea876d81574841e1dd3e81e2352e555d096', ref: (el) => (this.backdropEl = el), class: "menu-backdrop", tappable: false, stopPropagation: false, part: "backdrop" })));
24590
24623
  }
24591
24624
  get el() { return getElement(this); }
24592
24625
  static get watchers() { return {
package/hydrate/index.mjs CHANGED
@@ -8081,6 +8081,11 @@ const CoreDelegate = () => {
8081
8081
 
8082
8082
  let lastOverlayIndex = 0;
8083
8083
  let lastId = 0;
8084
+ /**
8085
+ * Every overlay except toast, which doesn't trap
8086
+ * focus or close on back.
8087
+ */
8088
+ const NON_TOAST_OVERLAYS = 'ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-popover';
8084
8089
  const activeAnimations = new WeakMap();
8085
8090
  /**
8086
8091
  * Determines if the overlay's backdrop is always blocking (no background interaction).
@@ -8205,7 +8210,7 @@ const focusElementInOverlay = (hostToFocus, overlay) => {
8205
8210
  * Should NOT include: Toast
8206
8211
  */
8207
8212
  const trapKeyboardFocus = (ev, doc) => {
8208
- const lastOverlay = getPresentedOverlay(doc, 'ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-popover');
8213
+ const lastOverlay = getPresentedOverlay(doc, NON_TOAST_OVERLAYS);
8209
8214
  const target = ev.target;
8210
8215
  /**
8211
8216
  * If no active overlay, ignore this event.
@@ -8511,7 +8516,8 @@ const setRootAriaHidden = (hidden = false) => {
8511
8516
  * Cleans up root `aria-hidden` and `backdrop-no-scroll` when
8512
8517
  * an overlay is removed from the DOM without going through
8513
8518
  * the `dismiss()` flow (e.g., when a framework unmounts the
8514
- * overlay during a route change).
8519
+ * overlay during a route change). Also releases the
8520
+ * CloseWatcher if nothing is left to close.
8515
8521
  *
8516
8522
  * Should be called from an overlay's `disconnectedCallback`
8517
8523
  * when the overlay was still presented at the time of removal.
@@ -8541,7 +8547,9 @@ const applyRootLock = (el) => {
8541
8547
  };
8542
8548
  /**
8543
8549
  * Re-applies the root lock that `cleanupRootFocusTrapAccessibility()` released.
8544
- * Call from `connectedCallback` when the overlay is still presented.
8550
+ * Call from `connectedCallback` when the overlay is still presented. Also
8551
+ * re-arms the CloseWatcher, which every overlay needs, so that happens
8552
+ * before the `locksAppRoot` check.
8545
8553
  *
8546
8554
  * A synchronous move keeps the overlay connected, so the lock survives. A
8547
8555
  * detach with a re-insert in a later task releases it, which is the shape a
@@ -21252,6 +21260,11 @@ class InputOTP {
21252
21260
  * focus behavior when an input box is focused.
21253
21261
  */
21254
21262
  this.isKeyboardNavigation = false;
21263
+ /**
21264
+ * The `length` watcher runs before new inputs render, so
21265
+ * `componentDidRender` updates their tab indexes instead.
21266
+ */
21267
+ this.updateTabIndexesAfterRender = false;
21255
21268
  this.inputValues = [];
21256
21269
  this.hasFocus = false;
21257
21270
  this.previousInputValues = [];
@@ -21611,6 +21624,10 @@ class InputOTP {
21611
21624
  this.initializeValues();
21612
21625
  this.updateTabIndexes();
21613
21626
  }
21627
+ lengthChanged() {
21628
+ this.initializeValues();
21629
+ this.updateTabIndexesAfterRender = true;
21630
+ }
21614
21631
  /**
21615
21632
  * Processes the separators prop into an array of numbers.
21616
21633
  *
@@ -21667,6 +21684,12 @@ class InputOTP {
21667
21684
  componentDidLoad() {
21668
21685
  this.updateTabIndexes();
21669
21686
  }
21687
+ componentDidRender() {
21688
+ if (this.updateTabIndexesAfterRender) {
21689
+ this.updateTabIndexesAfterRender = false;
21690
+ this.updateTabIndexes();
21691
+ }
21692
+ }
21670
21693
  /**
21671
21694
  * Get the regex pattern for allowed characters.
21672
21695
  * If a pattern is provided, use it to create a regex pattern
@@ -21844,7 +21867,7 @@ class InputOTP {
21844
21867
  const tabbableIndex = this.getTabbableIndex();
21845
21868
  const pattern = this.getPattern();
21846
21869
  const hasDescription = el.querySelector('.input-otp-description')?.textContent?.trim() !== '';
21847
- return (hAsync(Host, { key: 'bd37661e13cde21feff30c663e6813ce3fff0d9a', class: createColorClasses$1(color, {
21870
+ return (hAsync(Host, { key: 'def9fbd4fa135e6f435380c6ea86ac1621b4a111', class: createColorClasses$1(color, {
21848
21871
  [mode]: true,
21849
21872
  'has-focus': hasFocus,
21850
21873
  [`input-otp-size-${size}`]: true,
@@ -21852,20 +21875,30 @@ class InputOTP {
21852
21875
  [`input-otp-fill-${fill}`]: true,
21853
21876
  'input-otp-disabled': disabled,
21854
21877
  'input-otp-readonly': readonly,
21855
- }) }, hAsync("div", { key: '5e206f870024f1ecfebda999ff31e6e815774deb', role: "group", "aria-label": "One-time password input", class: "input-otp-group", ...inheritedAttributes }, Array.from({ length }).map((_, index) => (hAsync(Fragment, null, hAsync("div", { class: "native-wrapper" }, hAsync("input", { class: "native-input", id: `${inputId}-${index}`, "aria-label": `Input ${index + 1} of ${length}`, type: "text", autoCapitalize: autocapitalize, inputmode: inputmode, pattern: pattern, disabled: disabled, readOnly: readonly, tabIndex: index === tabbableIndex ? 0 : -1, value: inputValues[index] || '', autocomplete: "one-time-code", ref: (el) => (inputRefs[index] = el), onInput: this.onInput(index), onBlur: this.onBlur, onFocus: this.onFocus(index), onKeyDown: this.onKeyDown(index), onPaste: this.onPaste })), this.showSeparator(index) && hAsync("div", { class: "input-otp-separator" }))))), hAsync("div", { key: 'c268f838ddab2c8d6a612a11c7d38e6ca076436d', class: {
21878
+ }) }, hAsync("div", { key: '5d3d7646a3d4fc856b7b2e1f53d29fca47b10baf', role: "group", "aria-label": "One-time password input", class: "input-otp-group", ...inheritedAttributes }, Array.from({ length }).map((_, index) => (hAsync(Fragment, null, hAsync("div", { class: "native-wrapper" }, hAsync("input", { class: "native-input", id: `${inputId}-${index}`, "aria-label": `Input ${index + 1} of ${length}`, type: "text", autoCapitalize: autocapitalize, inputmode: inputmode, pattern: pattern, disabled: disabled, readOnly: readonly, tabIndex: index === tabbableIndex ? 0 : -1, value: inputValues[index] || '', autocomplete: "one-time-code", ref: (el) => {
21879
+ if (el) {
21880
+ inputRefs[index] = el;
21881
+ }
21882
+ else {
21883
+ // The input was removed, so drop its ref and any after it.
21884
+ inputRefs.splice(index);
21885
+ }
21886
+ }, onInput: this.onInput(index), onBlur: this.onBlur, onFocus: this.onFocus(index), onKeyDown: this.onKeyDown(index), onPaste: this.onPaste })), this.showSeparator(index) && hAsync("div", { class: "input-otp-separator" }))))), hAsync("div", { key: '9d72a4ab35b5fdd6bba9701050c385ed253b310f', class: {
21856
21887
  'input-otp-description': true,
21857
21888
  'input-otp-description-hidden': !hasDescription,
21858
- } }, hAsync("slot", { key: 'c0736359b26f609b795e399fc1ad9b540632af18' }))));
21889
+ } }, hAsync("slot", { key: '7deb3373c0d4e5deac22fa51577d271b9bb3a6d2' }))));
21859
21890
  }
21860
21891
  get el() { return getElement(this); }
21861
21892
  static get watchers() { return {
21862
21893
  "value": [{
21863
21894
  "valueChanged": 0
21864
21895
  }],
21865
- "separators": [{
21896
+ "length": [{
21897
+ "lengthChanged": 0
21898
+ }, {
21866
21899
  "processSeparators": 0
21867
21900
  }],
21868
- "length": [{
21901
+ "separators": [{
21869
21902
  "processSeparators": 0
21870
21903
  }]
21871
21904
  }; }
@@ -24577,14 +24610,14 @@ class Menu {
24577
24610
  * the ionBackButton listener in the menu controller
24578
24611
  * will handle closing the menu when Escape is pressed.
24579
24612
  */
24580
- return (hAsync(Host, { key: '1208ba437fa58680325408d3d4c8580950da1d68', onKeyDown: shouldUseCloseWatcher() ? null : this.onKeydown, role: "navigation", "aria-label": inheritedAttributes['aria-label'] || 'menu', class: {
24613
+ return (hAsync(Host, { key: '5cf26df26d4e539860cbeaea98ec621b98c3fcfc', onKeyDown: shouldUseCloseWatcher() ? null : this.onKeydown, role: "navigation", "aria-label": inheritedAttributes['aria-label'] || 'menu', class: {
24581
24614
  [mode]: true,
24582
24615
  [`menu-type-${type}`]: true,
24583
24616
  'menu-enabled': !disabled,
24584
24617
  [`menu-side-${side}`]: true,
24585
24618
  'menu-pane-visible': isPaneVisible,
24586
24619
  'split-pane-side': hostContext('ion-split-pane', el),
24587
- } }, hAsync("div", { key: 'c0ddc957b7a7956b41901d77ae02d91e73071c55', class: "menu-inner", part: "container", ref: (el) => (this.menuInnerEl = el) }, hAsync("slot", { key: '6e44c56116431a024f114ab85ded1b822c942fac' })), hAsync("ion-backdrop", { key: '5f4bbcf84444d96ec6b02bf567e1aaf95f59078d', ref: (el) => (this.backdropEl = el), class: "menu-backdrop", tappable: false, stopPropagation: false, part: "backdrop" })));
24620
+ } }, hAsync("div", { key: 'f337016e293bb8665c99762e0c389dd6c372bb33', class: "menu-inner", part: "container", ref: (el) => (this.menuInnerEl = el) }, hAsync("slot", { key: '4c3fe331aa42cd57d7ad9bd1f5910f8eeb62d7da' })), hAsync("ion-backdrop", { key: '61af7ea876d81574841e1dd3e81e2352e555d096', ref: (el) => (this.backdropEl = el), class: "menu-backdrop", tappable: false, stopPropagation: false, part: "backdrop" })));
24588
24621
  }
24589
24622
  get el() { return getElement(this); }
24590
24623
  static get watchers() { return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ionic/core",
3
- "version": "9.0.7-dev.11790871695.14a4111c",
3
+ "version": "9.0.7-dev.11791305593.188c8151",
4
4
  "description": "Base components for Ionic",
5
5
  "engines": {
6
6
  "node": ">= 16"
@@ -1,4 +0,0 @@
1
- /*!
2
- * (C) Ionic http://ionicframework.com - MIT License
3
- */
4
- import{d as t}from"./p-ZjP4CjeZ.js";import{MENU_BACK_BUTTON_PRIORITY as e}from"./p-q2WJ5Igc.js";import{p as n}from"./p-BriaEJK8.js";import{c as r}from"./p-DlUdjUlf.js";import{b as s}from"./p-BEiYs-sz.js";import{c as a}from"./p-LH1I_Zhd.js";const o=t=>a().duration(t?400:300),i=t=>{let e,n;const r=t.width+8,i=a(),u=a();t.isEndSide?(e=r+"px",n="0px"):(e=-r+"px",n="0px"),i.addElement(t.menuInnerEl).fromTo("transform",`translateX(${e})`,`translateX(${n})`);const c="ios"===s(t),p=c?.2:.25;return u.addElement(t.backdropEl).fromTo("opacity",.01,p),o(c).addAnimation([i,u])},u=t=>{let e,n;const r=s(t),i=t.width;t.isEndSide?(e=-i+"px",n=i+"px"):(e=i+"px",n=-i+"px");const u=a().addElement(t.menuInnerEl).fromTo("transform",`translateX(${n})`,"translateX(0px)"),c=a().addElement(t.contentEl).fromTo("transform","translateX(0px)",`translateX(${e})`),p=a().addElement(t.backdropEl).fromTo("opacity",.01,.32);return o("ios"===r).addAnimation([u,c,p])},c=t=>{const e=s(t),n=t.width*(t.isEndSide?-1:1)+"px",r=a().addElement(t.contentEl).fromTo("transform","translateX(0px)",`translateX(${n})`);return o("ios"===e).addAnimation(r)},p=(()=>{const s=new Map,a=[],o=async(t,e=!1)=>{if(await w(),"start"===t||"end"===t){const r=a.filter((e=>e.side===t&&!e.disabled));if(r.length>=1)return r.length>1&&e&&n(`menuController queried for a menu on the "${t}" side, but ${r.length} menus were found. The first menu reference will be used. If this is not the behavior you want then pass the ID of the menu instead of its side.`,r.map((t=>t.el))),r[0].el;const s=a.filter((e=>e.side===t));if(s.length>=1)return s.length>1&&e&&n(`menuController queried for a menu on the "${t}" side, but ${s.length} menus were found. The first menu reference will be used. If this is not the behavior you want then pass the ID of the menu instead of its side.`,s.map((t=>t.el))),s[0].el}else if(null!=t)return d((e=>e.menuId===t));return d((t=>!t.disabled))||(a.length>0?a[0].el:void 0)},p=async()=>(await w(),f()),m=(t,e)=>{s.set(t,e)},f=()=>d((t=>t._isOpen)),l=()=>a.some((t=>t.isAnimating)),d=t=>{const e=a.find(t);if(void 0!==e)return e.el},w=()=>Promise.all(Array.from(document.querySelectorAll("ion-menu")).map((t=>new Promise((e=>r(t,e))))));return m("reveal",c),m("push",u),m("overlay",i),t?.addEventListener("ionBackButton",(t=>{const n=f();n&&t.detail.register(e,(()=>n.close()))})),{registerAnimation:m,get:o,getMenus:async()=>(await w(),a.map((t=>t.el))),getOpen:p,isEnabled:async t=>{const e=await o(t);return!!e&&!e.disabled},swipeGesture:async(t,e)=>{const n=await o(e);return n&&(n.swipeGesture=t),n},isAnimating:async()=>(await w(),l()),isOpen:async t=>{if(null!=t){const e=await o(t);return void 0!==e&&e.isOpen()}return void 0!==await p()},enable:async(t,e)=>{const n=await o(e);return n&&(n.disabled=!t),n},toggle:async t=>{const e=await o(t,!0);return!!e&&e.toggle()},close:async t=>{const e=await(void 0!==t?o(t,!0):p());return void 0!==e&&e.close()},open:async t=>{const e=await o(t,!0);return!!e&&e.open()},_getOpenSync:f,_createAnimation:(t,e)=>{const n=s.get(t);if(!n)throw new Error("animation not registered");return n(e)},_register:t=>{a.indexOf(t)<0&&a.push(t)},_unregister:t=>{const e=a.indexOf(t);e>-1&&a.splice(e,1)},_setOpen:async(t,e,n,r)=>{if(l())return!1;if(e){const e=await p();e&&t.el!==e&&await e.setOpen(!1,!1)}return t._setOpen(e,n,r)}}})();export{p as m}
@@ -1,4 +0,0 @@
1
- /*!
2
- * (C) Ionic http://ionicframework.com - MIT License
3
- */
4
- import{m as a}from"./p-BNnmwjuy.js";const t=async t=>{const s=await a.get(t);return!(!s||!await s.isActive())};export{t as u}
@@ -1,4 +0,0 @@
1
- /*!
2
- * (C) Ionic http://ionicframework.com - MIT License
3
- */
4
- import{d as t,H as i,i as o,p as e,w as a,e as s,h as r,f as n,t as d}from"./p-BriaEJK8.js";import{i as h,b as p,a as l,d as c,r as m,f,p as u}from"./p-B8HBLiYi.js";import{C as b,a as x,d as v}from"./p-Canp1qah.js";import{p as w,g,e as k,r as y,j as A,l as Y}from"./p-DlUdjUlf.js";import{c as S}from"./p-B-hirT0v.js";import{g as C}from"./p-CIGNaXM1.js";import{G as D,O as E,F as O,n as M,d as T,B,h as P,r as I,j as N,k as j,e as R,f as $,g as z}from"./p-WMQuK_Tj.js";import{g as L}from"./p-byZM6qHV.js";import{e as F,w as W}from"./p-CVVUo4J1.js";import{b as H}from"./p-BEiYs-sz.js";import{KEYBOARD_DID_OPEN as V}from"./p-D7-vHX0A.js";import{c as Z}from"./p-LH1I_Zhd.js";import{g as K}from"./p-hHmYLOfE.js";import{createGesture as U}from"./p-D0YpjgON.js";import{w as _}from"./p-ZjP4CjeZ.js";import{d as G}from"./p-BSJriPuC.js";var J;!function(t){t.Dark="DARK",t.Light="LIGHT",t.Default="DEFAULT"}(J||(J={}));const q={getEngine(){const t=C();if(t?.isPluginAvailable("StatusBar"))return t.Plugins.StatusBar},setStyle(t){const i=this.getEngine();i&&i.setStyle(t)},getStyle:async function(){const t=this.getEngine();if(!t)return J.Default;const{style:i}=await t.getInfo();return i}},X=(t,i)=>{if(1===i)return 0;const o=1/(1-i);return t*o+-i*o},Q=()=>{!_||_.innerWidth>=768||q.setStyle({style:J.Dark})},tt=(t=J.Default)=>{!_||_.innerWidth>=768||q.setStyle({style:t})},it=t=>{const i=h(t)?g(t).querySelector(".inner-scroll"):t;return!p(t)&&0===i.scrollTop},ot=async(t,i)=>{"function"==typeof t.canDismiss&&await t.canDismiss(void 0,D)&&(i.isRunning()?i.onFinish((()=>{t.dismiss(void 0,"handler")}),{oneTimeCallback:!0}):t.dismiss(void 0,"handler"))},et=t=>.00255275*2.71828**(-14.9619*t)-1.00255*2.71828**(-.0380968*t)+1,at=.915,st=(t,i)=>k(400,t/Math.abs(1.1*i),500),rt=(t,i)=>{const o=window.innerHeight,e=t.getBoundingClientRect().top,a=Math.round(1e3*(1-i/(o-e)))/1e3;return Math.max(0,Math.min(1,a))},nt=t=>{const{currentBreakpoint:i,backdropBreakpoint:o,expandToScroll:e}=t,a=void 0===o||o<i,s=a?`calc(var(--backdrop-opacity) * ${i})`:"0",r=Z("backdropAnimation").fromTo("opacity",0,s);return a&&r.beforeStyles({"pointer-events":"none"}).afterClearStyles(["pointer-events"]),{wrapperAnimation:Z("wrapperAnimation").keyframes([{offset:0,opacity:1,transform:"translateY(100%)"},{offset:1,opacity:1,transform:`translateY(${100-100*i}%)`}]),backdropAnimation:r,contentAnimation:e?void 0:Z("contentAnimation").keyframes([{offset:0,opacity:1,maxHeight:100*(1-i)+"%"},{offset:1,opacity:1,maxHeight:100*i+"%"}])}},dt=t=>{const{currentBreakpoint:i,backdropBreakpoint:o}=t,e=`calc(var(--backdrop-opacity) * ${X(i,o)})`,a=[{offset:0,opacity:e},{offset:1,opacity:0}],s=[{offset:0,opacity:e},{offset:o,opacity:0},{offset:1,opacity:0}],r=Z("backdropAnimation").keyframes(0!==o?s:a);return{wrapperAnimation:Z("wrapperAnimation").keyframes([{offset:0,opacity:1,transform:`translateY(${100-100*i}%)`},{offset:1,opacity:1,transform:"translateY(100%)"}]),backdropAnimation:r}},ht=(t,i)=>{const{presentingEl:o,currentBreakpoint:e,expandToScroll:a}=i,s=g(t),{wrapperAnimation:r,backdropAnimation:n,contentAnimation:d}=void 0!==e?nt(i):{backdropAnimation:Z().fromTo("opacity",.01,"var(--backdrop-opacity)").beforeStyles({"pointer-events":"none"}).afterClearStyles(["pointer-events"]),wrapperAnimation:Z().fromTo("transform","translateY(100vh)","translateY(0vh)"),contentAnimation:void 0};n.addElement(s.querySelector("ion-backdrop")),r.addElement(s.querySelectorAll(".modal-wrapper, .modal-shadow")).beforeStyles({opacity:1}),!a&&d?.addElement(t.querySelector(".ion-page"));const h=Z("entering-base").addElement(t).easing("cubic-bezier(0.32,0.72,0,1)").duration(500).addAnimation([r]);if(d&&h.addAnimation(d),o){const t=window.innerWidth<768,i="ION-MODAL"===o.tagName&&void 0!==o.presentingElement,e=g(o),a=Z().beforeStyles({transform:"translateY(0)","transform-origin":"top center",overflow:"hidden"}),s=document.body;if(t){const t=CSS.supports("width","max(0px, 1px)")?"max(30px, var(--ion-safe-area-top))":"30px",e=`translateY(${i?"-10px":t}) scale(0.915)`;a.afterStyles({transform:e}).beforeAddWrite((()=>s.style.setProperty("background-color","black"))).addElement(o).keyframes([{offset:0,filter:"contrast(1)",transform:"translateY(0px) scale(1)",borderRadius:"0px"},{offset:1,filter:"contrast(0.85)",transform:e,borderRadius:"10px 10px 0 0"}]),h.addAnimation(a)}else if(h.addAnimation(n),i){const t=`translateY(-10px) scale(${i?at:1})`;a.afterStyles({transform:t}).addElement(e.querySelector(".modal-wrapper")).keyframes([{offset:0,filter:"contrast(1)",transform:"translateY(0) scale(1)"},{offset:1,filter:"contrast(0.85)",transform:t}]);const o=Z().afterStyles({transform:t}).addElement(e.querySelector(".modal-shadow")).keyframes([{offset:0,opacity:"1",transform:"translateY(0) scale(1)"},{offset:1,opacity:"0",transform:t}]);h.addAnimation([a,o])}else r.fromTo("opacity","0","1")}else h.addAnimation(n);return h},pt=(t,i,o=500)=>{const{presentingEl:e,currentBreakpoint:a}=i,s=g(t),{wrapperAnimation:r,backdropAnimation:n}=void 0!==a?dt(i):{backdropAnimation:Z().fromTo("opacity","var(--backdrop-opacity)",0),wrapperAnimation:Z().fromTo("transform","translateY(0vh)","translateY(100vh)")};n.addElement(s.querySelector("ion-backdrop")),r.addElement(s.querySelectorAll(".modal-wrapper, .modal-shadow")).beforeStyles({opacity:1});const d=Z("leaving-base").addElement(t).easing("cubic-bezier(0.32,0.72,0,1)").duration(o).addAnimation(r);if(e){const t=window.innerWidth<768,i="ION-MODAL"===e.tagName&&void 0!==e.presentingElement,o=g(e),a=Z().beforeClearStyles(["transform"]).afterClearStyles(["transform"]).onFinish((t=>{1===t&&(e.style.setProperty("overflow",""),Array.from(s.querySelectorAll("ion-modal:not(.overlay-hidden)")).filter((t=>void 0!==t.presentingElement)).length<=1&&s.style.setProperty("background-color",""))})),s=document.body;if(t){const t=CSS.supports("width","max(0px, 1px)")?"max(30px, var(--ion-safe-area-top))":"30px",o=`translateY(${i?"-10px":t}) scale(0.915)`;a.addElement(e).keyframes([{offset:0,filter:"contrast(0.85)",transform:o,borderRadius:"10px 10px 0 0"},{offset:1,filter:"contrast(1)",transform:"translateY(0px) scale(1)",borderRadius:"0px"}]),d.addAnimation(a)}else if(d.addAnimation(n),i){const t=`translateY(-10px) scale(${i?at:1})`;a.addElement(o.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 e=Z().addElement(o.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([a,e])}else r.fromTo("opacity","1","0")}else d.addAnimation(n);return d},lt=(t,i)=>{const{currentBreakpoint:o,expandToScroll:e}=i,a=g(t),{wrapperAnimation:s,backdropAnimation:r,contentAnimation:n}=void 0!==o?nt(i):{backdropAnimation:Z().fromTo("opacity",.01,"var(--backdrop-opacity)").beforeStyles({"pointer-events":"none"}).afterClearStyles(["pointer-events"]),wrapperAnimation:Z().keyframes([{offset:0,opacity:.01,transform:"translateY(40px)"},{offset:1,opacity:1,transform:"translateY(0px)"}]),contentAnimation:void 0};r.addElement(a.querySelector("ion-backdrop")),s.addElement(a.querySelector(".modal-wrapper")),!e&&n?.addElement(t.querySelector(".ion-page"));const d=Z().addElement(t).easing("cubic-bezier(0.36,0.66,0.04,1)").duration(280).addAnimation([r,s]);return n&&d.addAnimation(n),d},ct=(t,i)=>{const{currentBreakpoint:o}=i,e=g(t),{wrapperAnimation:a,backdropAnimation:s}=void 0!==o?dt(i):{backdropAnimation:Z().fromTo("opacity","var(--backdrop-opacity)",0),wrapperAnimation:Z().keyframes([{offset:0,opacity:.99,transform:"translateY(0px)"},{offset:1,opacity:0,transform:"translateY(40px)"}])};return s.addElement(e.querySelector("ion-backdrop")),a.addElement(e.querySelector(".modal-wrapper")),Z().easing("cubic-bezier(0.47,0,0.745,0.715)").duration(200).addAnimation([s,a])};let mt=null,ft=!1;const ut=()=>{if(null!==mt)return mt;const t=_?.document;if(!t?.body)return 0;const i=t.createElement("div");i.style.cssText="position:fixed;visibility:hidden;pointer-events:none;top:0;left:0;padding-top:var(--ion-safe-area-top,0px);",t.body.appendChild(i);const o=parseFloat(getComputedStyle(i).paddingTop)||0;return i.remove(),mt=o,ft||(ft=!0,y((()=>{mt=null,ft=!1}))),o},bt=t=>{const i=getComputedStyle(t),o=M(i.getPropertyValue("--width")),e=M(i.getPropertyValue("--height"));return"fullscreen"===o&&"fullscreen"===e?{vertical:!0,horizontal:!0}:xt(t)},xt=t=>{const i=t.shadowRoot?.querySelector(".modal-wrapper");if(null==i||void 0===_)return{vertical:!1,horizontal:!1};const o=t.classList.contains("overlay-hidden");o&&t.classList.remove("overlay-hidden");const{width:e,height:a}=i.getBoundingClientRect();return o&&t.classList.add("overlay-hidden"),{vertical:a>=_.innerHeight-5,horizontal:e>=_.innerWidth-5}},vt=(t,i)=>{t.style.setProperty("--ion-safe-area-top",i.top),t.style.setProperty("--ion-safe-area-bottom",i.bottom),t.style.setProperty("--ion-safe-area-left",i.left),t.style.setProperty("--ion-safe-area-right",i.right)},wt=t(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),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.ionDragStart=o(this,"ionDragStart",7),this.ionDragMove=o(this,"ionDragMove",7),this.ionDragEnd=o(this,"ionDragEnd",7),this.lockController=S(),this.triggerController=T(),this.coreDelegate=b(),this.isSheetModal=!1,this.inheritedAttributes={},this.inline=!1,this.gestureAnimationDismissing=!1,this.isPresenting=!1,this.presented=!1,this.hasController=!1,this.keyboardClose=!0,this.expandToScroll=!0,this.backdropBreakpoint=0,this.handleBehavior="cycle",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:i}=this;"cycle"===i&&void 0===t&&this.moveToNextBreakpoint()},this.onBackdropTap=()=>{const{sheetTransition:t}=this;void 0===t&&this.dismiss(void 0,B)},this.onLifecycle=t=>{const i=this.usersElement,o=gt[t.type];if(i&&o){const e=new CustomEvent(o,{bubbles:!1,cancelable:!1,detail:t.detail});i.dispatchEvent(e)}},this.onModalFocus=t=>{const{dragHandleEl:i,el:o}=this;t.target===o&&null==o.shadowRoot?.activeElement&&i&&-1!==i.tabIndex&&i.focus()},this.onSlotChange=({target:t})=>{t.assignedElements().forEach((t=>{t.querySelectorAll("ion-modal").forEach((t=>{null===t.getAttribute("data-parent-ion-modal")&&t.setAttribute("data-parent-ion-modal",this.el.id)}))}))}}onIsOpenChange(t,i){!0===t&&!1===i?this.present():!1===t&&!0===i&&this.dismiss()}triggerChanged(){const{trigger:t,el:i,triggerController:o}=this;t&&o.addClickListener(i,t)}onWindowResize(){this.presented&&(clearTimeout(this.resizeTimeout),this.resizeTimeout=setTimeout((()=>{const t=this.getSafeAreaContext();if(!t.isCardModal||this.enterAnimation||this.leaveAnimation||this.handleViewTransition(),t.isSheetModal&&this.updateSheetOffsetTop(),!t.isSheetModal&&!t.isCardModal){this.updateSafeAreaOverrides();const{contentEl:t,hasFooter:i}=this.findContentAndFooter();this.clearContentSafeAreaPadding(t),this.applyFullscreenSafeAreaTo(t,i)}}),50))}breakpointsChanged(t){void 0!==t&&(this.sortedBreakpoints=t.sort(((t,i)=>t-i)))}connectedCallback(){const{el:t}=this;P(t),this.triggerChanged(),(this.presented||this.isPresenting)&&this.restoreSafeAreaOverrides(),this.presented&&(I(t),this.initParentRemovalObserver())}disconnectedCallback(){this.triggerController.removeClickListener(),this.cleanupViewTransitionListener(),this.cleanupParentRemovalObserver(),this.cleanupSafeAreaOverrides(),this.presented&&N()}componentWillLoad(){const{breakpoints:t,initialBreakpoint:i,el:o,htmlAttributes:a}=this,s=this.isSheetModal=void 0!==t&&void 0!==i,r=["aria-label","role"];this.inheritedAttributes=A(o,r),o.parentNode&&(this.cachedOriginalParent=o.parentNode),void 0!==a&&r.forEach((t=>{a[t]&&(this.inheritedAttributes={...this.inheritedAttributes,[t]:a[t]},delete a[t])})),s&&(this.currentBreakpoint=this.initialBreakpoint),void 0===t||void 0===i||t.includes(i)||e("[ion-modal] - Your breakpoints array must include the initialBreakpoint value."),this.htmlAttributes?.id||j(this.el)}componentDidLoad(){!0===this.isOpen&&y((()=>this.present())),this.breakpointsChanged(this.breakpoints),this.triggerChanged()}getDelegate(t=!1){if(this.workingDelegate&&!t)return{delegate:this.workingDelegate,inline:this.inline};const i=this.inline=null!==this.el.parentNode&&!this.hasController;return{inline:i,delegate:this.workingDelegate=i?this.delegate||this.coreDelegate:this.delegate}}async checkCanDismiss(t,i){const{canDismiss:o}=this;return"function"==typeof o?o(t,i):o}async present(){const t=await this.lockController.lock();if(this.presented)return void t();const{presentingElement:i,el:o}=this;this.currentBreakpoint=this.initialBreakpoint;const{inline:e,delegate:s}=this.getDelegate(!0);this.ionMount.emit(),this.usersElement=await x(s,o,this.component,["ion-page"],this.componentProps,e),Y(o)?await F(this.usersElement):this.keepContentsMounted||await W(),a((()=>this.el.classList.add("show-modal"))),this.isSheetModal=void 0!==this.breakpoints&&void 0!==this.initialBreakpoint,this.isPresenting=!0;const r=void 0!==i;try{this.setInitialSafeAreaOverrides(),r&&"ios"===H(this)&&(this.statusBarStyle=await q.getStyle(),Q()),await R(this,"modalEnter",ht,lt,{presentingEl:i,currentBreakpoint:this.initialBreakpoint,backdropBreakpoint:this.backdropBreakpoint,expandToScroll:this.expandToScroll})}finally{this.isPresenting=!1}this.updateSafeAreaOverrides(),this.applyFullscreenSafeArea(),"undefined"!=typeof window&&(this.keyboardOpenCallback=()=>{this.gesture&&(this.gesture.enable(!1),y((()=>{this.gesture&&this.gesture.enable(!0)})))},window.addEventListener(V,this.keyboardOpenCallback)),this.isSheetModal?this.initSheetGesture():r&&this.initSwipeToClose(),this.initViewTransitionListener(),this.initParentRemovalObserver(),t()}initSwipeToClose(){if("ios"!==H(this))return;const{el:t}=this,i=this.leaveAnimation||s.get("modalLeave",pt),o=this.animation=i(t,{presentingEl:this.presentingElement,expandToScroll:this.expandToScroll});f(t)?(this.gesture=((t,i,o,e,a,s,r)=>{const n=.5,d=t.offsetHeight;let p=!1,f=!1,u=null,b=!0,x=0;const v=U({el:t,gestureName:"modalSwipeToClose",gesturePriority:E,direction:"y",threshold:10,canStart:t=>{const i=t.event.target;return null===i||!i.closest||(u=l(i),u?it(u):null===i.closest("ion-footer"))},onStart:o=>{const{deltaY:e}=o;window.getSelection()?.removeAllRanges(),b=!u||!h(u)||u.scrollY,f=void 0!==t.canDismiss&&!0!==t.canDismiss,e>0&&u&&c(u),i.progressStart(!0,p?1:0),a()},onMove:e=>{const{deltaY:a}=e;a>0&&u&&c(u);const r=e.deltaY/d,h=r>=0&&f,p=h?.2:.9999,l=h?et(r/p):r,m=k(1e-4,l,p);i.progressStep(m),m>=n&&x<n?tt(o):m<n&&x>=n&&Q(),x=m;const b={currentY:e.currentY,deltaY:e.deltaY,velocityY:e.velocityY,progress:rt(t,e.deltaY)};s(b)},onEnd:o=>{const a=o.velocityY,s=o.deltaY/d,h=s>=0&&f,l=h?.2:.9999,c=h?et(s/l):s,x=k(1e-4,c,l),w=!h&&(o.deltaY+1e3*a)/d>=n;let g=w?-.001:.001;w?(i.easing("cubic-bezier(0.32, 0.72, 0, 1)"),g+=K([0,0],[.32,.72],[0,1],[1,1],x)[0]):(i.easing("cubic-bezier(1, 0, 0.68, 0.28)"),g+=K([0,0],[1,0],[.68,.28],[1,1],x)[0]);const y=st(w?s*d:(1-x)*d,a);p=w,v.enable(!1),u&&m(u,b),i.onFinish((()=>{w||v.enable(!0)})).progressEnd(w?1:0,g,y);const A=h&&x>l/4;A?ot(t,i):w&&e();const Y=h?A&&"function"==typeof t.canDismiss:w,S={currentY:o.currentY,deltaY:o.deltaY,velocityY:o.velocityY,progress:rt(t,o.deltaY),isDismissing:Y};r(S)}});return v})(t,o,this.statusBarStyle??J.Default,(()=>this.cardOnDismiss()),(()=>this.onDragStart()),(t=>this.onDragMove(t)),(t=>this.onDragEnd(t))),this.gesture.enable(!0)):u(t)}initSheetGesture(){const{wrapperEl:t,initialBreakpoint:i,backdropBreakpoint:o}=this;if(!t||void 0===i)return;const e=this.enterAnimation||s.get("modalEnter",ht),a=this.animation=e(this.el,{presentingEl:this.presentingElement,currentBreakpoint:i,backdropBreakpoint:o,expandToScroll:this.expandToScroll});a.progressStart(!0,1);const{gesture:r,moveSheetToBreakpoint:n,resetContentScroll:d}=((t,i,o,e,a,s,r=[],n,d,p,c,m,f,u)=>{const b={WRAPPER_KEYFRAMES:[{offset:0,transform:"translateY(0%)"},{offset:1,transform:"translateY(100%)"}],BACKDROP_KEYFRAMES:0!==a?[{offset:0,opacity:"var(--backdrop-opacity)"},{offset:1-a,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%"}]},x=t.querySelector("ion-content"),v=x?.scrollY??!0,w=o.clientHeight;let A=e,Y=0,S=!1,C=null,D=null,E=null,M=null;const T=r[r.length-1],B=r[0],P=s.childAnimations.find((t=>"wrapperAnimation"===t.id)),I=s.childAnimations.find((t=>"backdropAnimation"===t.id)),N=s.childAnimations.find((t=>"contentAnimation"===t.id)),j=()=>{!1!==t.focusTrap&&!1!==t.showBackdrop&&(t.style.setProperty("pointer-events","auto"),i.style.setProperty("pointer-events","auto"),t.classList.remove(O))},R=()=>{t.style.setProperty("pointer-events","none"),i.style.setProperty("pointer-events","none"),t.classList.add(O)},$=i=>{if(!D&&(D=Array.from(t.querySelectorAll("ion-footer")),!D.length))return;const o=t.querySelector(".ion-page");if(M=i,"stationary"===i)D.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"),o?.style.removeProperty("padding-bottom"),o?.appendChild(t)}));else{let i=0;D.forEach(((o,e)=>{const a=o.getBoundingClientRect(),s=document.body.getBoundingClientRect();i+=o.clientHeight;const r=a.top-s.top,n=a.left-s.left;if(o.style.setProperty("--pinned-width",`${o.clientWidth}px`),o.style.setProperty("--pinned-height",`${o.clientHeight}px`),o.style.setProperty("--pinned-top",`${r}px`),o.style.setProperty("--pinned-left",`${n}px`),0===e){E=r;const i=t.querySelector("ion-header");i&&(E-=i.clientHeight)}})),D.forEach((t=>{o?.style.setProperty("padding-bottom",`${i}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)}))}};P&&I&&(P.keyframes([...b.WRAPPER_KEYFRAMES]),I.keyframes([...b.BACKDROP_KEYFRAMES]),N?.keyframes([...b.CONTENT_KEYFRAMES]),s.progressStart(!0,1-A),A>a&&!1!==t.focusTrap&&!1!==t.showBackdrop?j():R()),x&&A!==T&&n&&(x.scrollY=!1);const z=i=>{const{breakpoint:o,canDismiss:e,breakpointOffset:d,animated:h}=i,l=e&&0===o,m=l?A:o,f=0!==m;return A=0,P&&I&&(P.keyframes([{offset:0,transform:`translateY(${100*d}%)`},{offset:1,transform:`translateY(${100*(1-m)}%)`}]),I.keyframes([{offset:0,opacity:`calc(var(--backdrop-opacity) * ${X(1-d,a)})`},{offset:1,opacity:`calc(var(--backdrop-opacity) * ${X(m,a)})`}]),N&&N.keyframes([{offset:0,maxHeight:100*(1-d)+"%"},{offset:1,maxHeight:100*m+"%"}]),s.progressStep(0)),H.enable(!1),l?ot(t,s):f||p(),!x||m!==r[r.length-1]&&n||(x.scrollY=v),n||0!==m||$("stationary"),new Promise((i=>{s.onFinish((()=>{f?(n||$("stationary"),P&&I?y((()=>{P.keyframes([...b.WRAPPER_KEYFRAMES]),I.keyframes([...b.BACKDROP_KEYFRAMES]),N?.keyframes([...b.CONTENT_KEYFRAMES]),s.progressStart(!0,1-m),A=m,c(A),A>a&&!1!==t.focusTrap&&!1!==t.showBackdrop?j():R(),H.enable(!0),i()})):(H.enable(!0),i())):i()}),{oneTimeCallback:!0}).progressEnd(1,0,h?500:0)}))},L=t=>{const i=o.getBoundingClientRect().top+t,e=F(i);return r.reduce(((t,i)=>Math.abs(i-e)<Math.abs(t-e)?i:t))},F=t=>{const i=r[r.length-1],o=W(r[0]),e=W(i),a=Math.round((o-t)/(o-e)*1e3)/1e3;return Math.max(0,Math.min(1,a))},W=i=>{const o=t.getBoundingClientRect();return window.innerHeight-o.height*i},H=U({el:o,gestureName:"modalSheet",gesturePriority:40,direction:"y",threshold:10,canStart:t=>{const i=l(t.event.target);return A=d(),!(i&&(!n||1===A))||it(i)},onStart:i=>{if(window.getSelection()?.removeAllRanges(),S=void 0!==t.canDismiss&&!0!==t.canDismiss&&0===B,!n){const t=l(i.event.target);C=t&&h(t)?g(t).querySelector(".inner-scroll"):t}n||$("moving"),i.deltaY>0&&x&&(x.scrollY=!1),y((()=>{t.focus()})),s.progressStart(!0,1-A),m()},onMove:t=>{if(n||null===E||null===M||(t.currentY>=E&&"moving"===M?$("stationary"):t.currentY<E&&"stationary"===M&&$("moving")),!n&&t.deltaY<=0&&C)return;t.deltaY>0&&x&&(x.scrollY=!1);const i=r.length>1?1-r[1]:void 0,o=1-A+t.deltaY/w,e=void 0!==i&&o>=i&&S,a=e?.95:.9999,d=e&&void 0!==i?i+et((o-i)/(a-i)):o;Y=k(1e-4,d,a),s.progressStep(Y);const h=L(t.deltaY),p={currentY:t.currentY,deltaY:t.deltaY,velocityY:t.velocityY,progress:F(t.currentY),snapBreakpoint:h};f(p)},onEnd:i=>{const o=L(i.deltaY),e=S&&0===o?"function"==typeof t.canDismiss:0===o,a={currentY:i.currentY,deltaY:i.deltaY,velocityY:i.velocityY,progress:F(i.currentY),snapBreakpoint:o,isDismissing:e};if(!n&&i.deltaY<=0&&C&&C.scrollTop>0)return $("stationary"),void u({...a,isDismissing:!1});z({breakpoint:o,breakpointOffset:Y,canDismiss:S,animated:!0}),u(a)}});return{gesture:H,moveSheetToBreakpoint:z,resetContentScroll:()=>{x&&(x.scrollY=v)}}})(this.el,this.backdropEl,t,i,o,a,this.sortedBreakpoints,this.expandToScroll,(()=>this.currentBreakpoint??0),(()=>this.sheetOnDismiss()),(t=>{this.currentBreakpoint!==t&&(this.currentBreakpoint=t,this.ionBreakpointDidChange.emit({breakpoint:t}))}),(()=>this.onDragStart()),(t=>this.onDragMove(t)),(t=>this.onDragEnd(t)));this.gesture=r,this.moveSheetToBreakpoint=n,this.resetSheetContentScroll=d,this.gesture.enable(!0),(!1===this.showBackdrop||!1===this.focusTrap||o>0)&&this.setupChildRoutePassthrough()}setupChildRoutePassthrough(){this.cachedPageParent=this.getOriginalPageParent();const t=this.cachedPageParent;if(!t||"ION-APP"===t.tagName)return;if(Array.from(t.children).some((t=>!(t===this.el||t instanceof i&&"none"===window.getComputedStyle(t).display||"TEMPLATE"===t.tagName||"SLOT"===t.tagName||t.nodeType===Node.TEXT_NODE&&!t.textContent?.trim()))))return;t.classList.add("ion-page-overlay-passthrough");const o=t.parentElement;"ION-ROUTER-OUTLET"===o?.tagName&&"ION-APP"!==o.parentElement?.tagName&&(o.style.setProperty("pointer-events","none"),o.setAttribute("data-overlay-passthrough","true"))}getOriginalPageParent(){if(!this.cachedOriginalParent)return null;let t=this.cachedOriginalParent;for(;t&&!t.classList.contains("ion-page");)t=t.parentElement;return t}cleanupChildRoutePassthrough(){const t=this.cachedPageParent;if(!t)return;t.classList.remove("ion-page-overlay-passthrough");const i=t.parentElement;i?.hasAttribute("data-overlay-passthrough")&&(i.style.removeProperty("pointer-events"),i.removeAttribute("data-overlay-passthrough")),this.cachedPageParent=void 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}))}cardOnDismiss(){this.gestureAnimationDismissing=!0,tt(this.statusBarStyle),this.animation.onFinish((async()=>{await this.dismiss(void 0,D),this.gestureAnimationDismissing=!1}))}async dismiss(t,i){if(this.gestureAnimationDismissing&&i!==D)return!1;clearTimeout(this.resizeTimeout),this.resizeTimeout=void 0;const o=await this.lockController.lock();if(await this.dismissNestedModals(),"handler"!==i&&!await this.checkCanDismiss(t,i))return o(),!1;const{presentingElement:e}=this;void 0!==e&&"ios"===H(this)&&tt(this.statusBarStyle),"undefined"!=typeof window&&this.keyboardOpenCallback&&(window.removeEventListener(V,this.keyboardOpenCallback),this.keyboardOpenCallback=void 0);const s=await $(this,t,i,"modalLeave",pt,ct,{presentingEl:e,currentBreakpoint:this.currentBreakpoint??this.initialBreakpoint,backdropBreakpoint:this.backdropBreakpoint,expandToScroll:this.expandToScroll});if(s){const{delegate:t}=this.getDelegate();await v(t,this.usersElement),a((()=>this.el.classList.remove("show-modal"))),this.animation&&this.animation.destroy(),this.gesture&&this.gesture.destroy(),this.resetSheetContentScroll?.(),this.resetSheetContentScroll=void 0,this.cleanupViewTransitionListener(),this.cleanupParentRemovalObserver(),this.cleanupSafeAreaOverrides(),this.cleanupChildRoutePassthrough()}return this.currentBreakpoint=void 0,this.animation=void 0,o(),s}onDidDismiss(){return z(this.el,"ionModalDidDismiss")}onWillDismiss(){return z(this.el,"ionModalWillDismiss")}async setCurrentBreakpoint(t){if(!this.isSheetModal)return void e("[ion-modal] - setCurrentBreakpoint is only supported on sheet modals.");if(!this.breakpoints.includes(t))return void e(`[ion-modal] - Attempted to set invalid breakpoint value ${t}. Please double check that the breakpoint value is part of your defined breakpoints.`);const{currentBreakpoint:i,moveSheetToBreakpoint:o,canDismiss:a,breakpoints:s,animated:r}=this;i!==t&&o&&(this.sheetTransition=o({breakpoint:t,breakpointOffset:1-i,canDismiss:void 0!==a&&!0!==a&&0===s[0],animated:r}),await this.sheetTransition,this.sheetTransition=void 0)}async getCurrentBreakpoint(){return this.currentBreakpoint}async moveToNextBreakpoint(){const{breakpoints:t,currentBreakpoint:i}=this;if(!t||null==i)return!1;const o=t.filter((t=>0!==t)),e=o.indexOf(i),a=o[(e+1)%o.length];return await this.setCurrentBreakpoint(a),!0}initViewTransitionListener(){"ios"!==H(this)||!this.presentingElement||this.enterAnimation||this.leaveAnimation||(this.currentViewIsPortrait=window.innerWidth<768)}handleViewTransition(){if(!this.presented)return;const t=window.innerWidth<768;if(this.currentViewIsPortrait===t)return;this.viewTransitionAnimation&&(this.viewTransitionAnimation.destroy(),this.viewTransitionAnimation=void 0);const{presentingElement:i}=this;if(!i)return;let o;o=this.currentViewIsPortrait&&!t?((t,i,o=300)=>{const{presentingEl:e}=i;if(!e)return Z("portrait-to-landscape-transition");const a="ION-MODAL"===e.tagName&&void 0!==e.presentingElement,s=g(e),r=document.body,n=Z("portrait-to-landscape-transition").addElement(t).easing("cubic-bezier(0.32,0.72,0,1)").duration(o),d=Z().beforeStyles({transform:"translateY(0)","transform-origin":"top center",overflow:"hidden"});if(a){const t="translateY(-10px) scale(0.915)",i="translateY(0px) scale(1)";d.addElement(e).afterStyles({transform:i}).fromTo("transform",t,i).fromTo("filter","contrast(0.85)","contrast(1)");const o=Z().addElement(s.querySelector(".modal-shadow")).afterStyles({transform:i,opacity:"0"}).fromTo("transform",t,i);n.addAnimation([d,o])}else{const i=g(t),o=Z().addElement(i.querySelectorAll(".modal-wrapper, .modal-shadow")).fromTo("opacity","1","1"),a=Z().addElement(i.querySelector("ion-backdrop")).fromTo("opacity","var(--backdrop-opacity)","var(--backdrop-opacity)"),s=`translateY(${CSS.supports("width","max(0px, 1px)")?"max(30px, var(--ion-safe-area-top))":"30px"}) scale(0.915)`;d.addElement(e).afterStyles({transform:"translateY(0px) scale(1)","border-radius":"0px"}).beforeAddWrite((()=>r.style.setProperty("background-color",""))).fromTo("transform",s,"translateY(0px) scale(1)").fromTo("filter","contrast(0.85)","contrast(1)").fromTo("border-radius","10px 10px 0 0","0px"),n.addAnimation([d,o,a])}return n})(this.el,{presentingEl:i}):((t,i,o=300)=>{const{presentingEl:e}=i;if(!e)return Z("landscape-to-portrait-transition");const a="ION-MODAL"===e.tagName&&void 0!==e.presentingElement,s=g(e),r=document.body,n=Z("landscape-to-portrait-transition").addElement(t).easing("cubic-bezier(0.32,0.72,0,1)").duration(o),d=Z().beforeStyles({transform:"translateY(0)","transform-origin":"top center",overflow:"hidden"});if(a){const t="translateY(-10px) scale(0.915)",i="translateY(0) scale(1)";d.addElement(e).afterStyles({transform:i}).fromTo("transform",t,i);const o=Z().addElement(s.querySelector(".modal-shadow")).afterStyles({transform:i,opacity:"0"}).fromTo("transform",t,i);n.addAnimation([d,o])}else{const i=g(t),o=Z().addElement(i.querySelectorAll(".modal-wrapper, .modal-shadow")).fromTo("opacity","1","1"),a=Z().addElement(i.querySelector("ion-backdrop")).fromTo("opacity","var(--backdrop-opacity)","var(--backdrop-opacity)"),s=`translateY(${CSS.supports("width","max(0px, 1px)")?"max(30px, var(--ion-safe-area-top))":"30px"}) scale(0.915)`;d.addElement(e).afterStyles({transform:s}).beforeAddWrite((()=>r.style.setProperty("background-color","black"))).keyframes([{offset:0,transform:"translateY(0px) scale(1)",filter:"contrast(1)",borderRadius:"0px"},{offset:.2,transform:"translateY(0px) scale(1)",filter:"contrast(1)",borderRadius:"10px 10px 0 0"},{offset:1,transform:s,filter:"contrast(0.85)",borderRadius:"10px 10px 0 0"}]),n.addAnimation([d,o,a])}return n})(this.el,{presentingEl:i}),this.currentViewIsPortrait=t,this.viewTransitionAnimation=o,o.play().then((()=>{this.viewTransitionAnimation=void 0,y((()=>this.updateSafeAreaOverrides())),this.reinitSwipeToClose()}))}cleanupViewTransitionListener(){this.resizeTimeout&&(clearTimeout(this.resizeTimeout),this.resizeTimeout=void 0),this.viewTransitionAnimation&&(this.viewTransitionAnimation.destroy(),this.viewTransitionAnimation=void 0)}reinitSwipeToClose(){"ios"===H(this)&&this.presentingElement&&(this.gesture&&(this.gesture.destroy(),this.gesture=void 0),this.animation&&(this.animation.progressEnd(0,0,0),this.animation.destroy(),this.animation=void 0),y((()=>{this.ensureCorrectModalPosition(),this.initSwipeToClose()})))}ensureCorrectModalPosition(){const{el:t,presentingElement:i}=this,o=g(t).querySelector(".modal-wrapper");if(o&&(o.style.transform="translateY(0vh)",o.style.opacity="1"),"ION-MODAL"===i?.tagName)if(window.innerWidth<768){const t=CSS.supports("width","max(0px, 1px)")?"max(30px, var(--ion-safe-area-top))":"30px";i.style.transform=`translateY(${t}) scale(0.915)`}else i.style.transform="translateY(0px) scale(1)"}async dismissNestedModals(){const t=document.querySelectorAll(`ion-modal[data-parent-ion-modal="${this.el.id}"]`);t?.forEach((async t=>{await t.dismiss(void 0,"parent-dismissed")}))}initParentRemovalObserver(){"undefined"!=typeof MutationObserver&&"undefined"!=typeof window&&this.cachedOriginalParent&&this.cachedOriginalParent.nodeType!==Node.DOCUMENT_NODE&&this.cachedOriginalParent.nodeType!==Node.DOCUMENT_FRAGMENT_NODE&&(this.hasController||this.cachedOriginalParent===document.body||"ION-APP"===this.cachedOriginalParent.tagName||(this.cleanupParentRemovalObserver(),this.parentRemovalObserver=new MutationObserver((t=>{t.forEach((t=>{"childList"===t.type&&t.removedNodes.length>0&&(Array.from(t.removedNodes).some((t=>{const i=t===this.cachedOriginalParent,o=!!this.cachedOriginalParent&&t.contains?.(this.cachedOriginalParent);return i||o}))||this.cachedOriginalParent&&!this.cachedOriginalParent.isConnected)&&(this.dismiss(void 0,"parent-removed"),this.cachedOriginalParent=void 0)}))})),this.parentRemovalObserver.observe(document.body,{childList:!0,subtree:!0})))}cleanupParentRemovalObserver(){this.parentRemovalObserver?.disconnect(),this.parentRemovalObserver=void 0}onDragStart(){this.ionDragStart.emit()}onDragMove(t){this.ionDragMove.emit(t)}onDragEnd(t){this.ionDragEnd.emit(t)}getSafeAreaContext(){return{isSheetModal:this.isSheetModal,isCardModal:void 0!==this.presentingElement&&"ios"===H(this),presentingElement:this.presentingElement,breakpoints:this.breakpoints,currentBreakpoint:this.currentBreakpoint}}watchHeightForContent(){var t;this.isSheetModal||(this.unsubscribeHeightChange?.(),this.unsubscribeHeightChange=(t=()=>{this.el.querySelectorAll("ion-content").forEach((t=>t.recalculateDimensions()))},w(this.el,"--height",(()=>t()))))}setInitialSafeAreaOverrides(){const t={...this.getSafeAreaContext(),coveredAxes:bt(this.el)},i=(t=>{const{isSheetModal:i,isCardModal:o}=t;if(i)return{top:"0px",bottom:"inherit",left:"0px",right:"0px"};if(o)return{top:"inherit",bottom:"inherit",left:"0px",right:"0px"};const{vertical:e,horizontal:a}=t.coveredAxes??{vertical:!0,horizontal:!0};return{top:e?"inherit":"0px",bottom:e?"inherit":"0px",left:a?"inherit":"0px",right:a?"inherit":"0px"}})(t);var o;vt(this.el,i),this.watchHeightForContent(),t.isSheetModal&&(this.updateSheetOffsetTop(),this.unsubscribeRootSafeAreaTop?.(),this.unsubscribeRootSafeAreaTop=(o=t=>this.updateSheetOffsetTop(t),w(_?.document?.body,"--ion-safe-area-top",o,ut())))}updateSheetOffsetTop(t){const i=t??ut();this.el.style.setProperty("--ion-modal-offset-top",`${i}px`)}updateSafeAreaOverrides(){const{wrapperEl:t,el:i}=this,o=this.getSafeAreaContext();if(o.isSheetModal)return;if(o.isCardModal)return;if(!t)return;const e=(t=>{const i=t.getBoundingClientRect();return{top:i.top<=5?"inherit":"0px",bottom:i.bottom>=(_?.innerHeight??0)-5?"inherit":"0px",left:i.left<=5?"inherit":"0px",right:i.right>=(_?.innerWidth??0)-5?"inherit":"0px"}})(t);vt(i,e)}applyFullscreenSafeArea(){const t=this.getSafeAreaContext();if(t.isSheetModal||t.isCardModal)return;const{contentEl:i,hasFooter:o}=this.findContentAndFooter();this.applyFullscreenSafeAreaTo(i,o)}applyFullscreenSafeAreaTo(t,i){t&&!i&&t.style.setProperty("--internal-content-safe-area-padding-bottom","var(--ion-safe-area-bottom, 0px)")}clearContentSafeAreaPadding(t){t&&t.style.removeProperty("--internal-content-safe-area-padding-bottom")}findContentAndFooter(){let t=null,i=!1;for(const o of Array.from(this.el.children)){"ION-CONTENT"===o.tagName&&(t=o),"ION-FOOTER"===o.tagName&&(i=!0);for(const e of Array.from(o.children))"ION-CONTENT"!==e.tagName||t||(t=e),"ION-FOOTER"===e.tagName&&(i=!0)}return{contentEl:t,hasFooter:i}}cleanupSafeAreaOverrides(){var t;(t=this.el).style.removeProperty("--ion-safe-area-top"),t.style.removeProperty("--ion-safe-area-bottom"),t.style.removeProperty("--ion-safe-area-left"),t.style.removeProperty("--ion-safe-area-right"),this.unsubscribeRootSafeAreaTop?.(),this.unsubscribeRootSafeAreaTop=void 0,this.unsubscribeHeightChange?.(),this.unsubscribeHeightChange=void 0,this.el.style.removeProperty("--ion-modal-offset-top");const{contentEl:i}=this.findContentAndFooter();this.clearContentSafeAreaPadding(i)}restoreSafeAreaOverrides(){this.setInitialSafeAreaOverrides(),this.applyFullscreenSafeArea(),y((()=>{if(!this.presented||!this.el.isConnected||this.isPresenting)return;const{width:t,height:i}=this.el.getBoundingClientRect();0===t&&0===i||this.updateSafeAreaOverrides()}))}render(){const{handle:t,isSheetModal:i,presentingElement:o,htmlAttributes:e,handleBehavior:a,inheritedAttributes:s,focusTrap:d,expandToScroll:h}=this,p=!1!==t&&i,l=H(this),c=void 0!==o&&"ios"===l,m="cycle"===a;return r(n,{key:"17a95bd7722bac2344bea041aff97db17f55c0cf","no-router":!0,tabIndex:m&&i&&p?0:-1,...e,style:{zIndex:`${2e4+this.overlayIndex}`},class:{[l]:!0,"modal-default":!c&&!i,"modal-card":c,"modal-sheet":i,"modal-no-expand-scroll":i&&!h,"overlay-hidden":!0,[O]:!1===d,...L(this.cssClass)},onIonBackdropTap:this.onBackdropTap,onIonModalDidPresent:this.onLifecycle,onIonModalWillPresent:this.onLifecycle,onIonModalWillDismiss:this.onLifecycle,onIonModalDidDismiss:this.onLifecycle,onFocus:this.onModalFocus},r("ion-backdrop",{key:"9dab1ef4771c0d847ba2be8672afbaa2748517f3",ref:t=>this.backdropEl=t,visible:this.showBackdrop,tappable:this.backdropDismiss,part:"backdrop"}),"ios"===l&&r("div",{key:"64af7ed1c5f552b61fc4b9387b926acc76c8a99a",class:"modal-shadow"}),r("div",{key:"7e76d77d5b2e8f0467bb793facf5aa86f8d01bbe",role:"dialog",...s,"aria-modal":"true",tabIndex:-1,class:"modal-wrapper ion-overlay-wrapper",part:"content",ref:t=>this.wrapperEl=t},p&&r("button",{key:"5efc0bb0a59adcc594ac48da9fd90e57908a7ffb",class:"modal-handle",tabIndex:m?0:-1,"aria-label":"Activate to adjust the size of the dialog overlaying the screen",onClick:m?this.onHandleClick:void 0,part:"handle",ref:t=>this.dragHandleEl=t}),r("slot",{key:"6175fcd0b39c086b4e9eb9e96c4d631c2a86774b",onSlotchange:this.onSlotChange})))}get el(){return this}static get watchers(){return{isOpen:[{onIsOpenChange:0}],trigger:[{triggerChanged:0}],breakpoints:[{breakpointsChanged:0}]}}static get style(){return{ios:':host{--width:100%;--min-width:auto;--max-width:auto;--height:100%;--min-height:auto;--max-height:100%;--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-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;outline:none}.modal-shadow{position:absolute;background:transparent}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--width:600px;--height:500px}}@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-modal-offset-top, 0px) + 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:100%;--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-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;outline:none}.modal-shadow{position:absolute;background:transparent}@media only screen and (min-width: 768px) and (min-height: 600px){:host{--width:600px;--height:500px}}@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-modal-offset-top, 0px) + 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}'}}},[289,"ion-modal",{hasController:[4,"has-controller"],overlayIndex:[2,"overlay-index"],delegate:[16],keyboardClose:[4,"keyboard-close"],enterAnimation:[16],leaveAnimation:[16],breakpoints:[16],expandToScroll:[4,"expand-to-scroll"],initialBreakpoint:[2,"initial-breakpoint"],backdropBreakpoint:[2,"backdrop-breakpoint"],handle:[4],handleBehavior:[1,"handle-behavior"],component:[1],componentProps:[16],cssClass:[1,"css-class"],backdropDismiss:[4,"backdrop-dismiss"],showBackdrop:[4,"show-backdrop"],animated:[4],presentingElement:[16],htmlAttributes:[16],isOpen:[4,"is-open"],trigger:[1],keepContentsMounted:[4,"keep-contents-mounted"],focusTrap:[4,"focus-trap"],canDismiss:[4,"can-dismiss"],isSheetModal:[32],presented:[32],present:[64],dismiss:[64],onDidDismiss:[64],onWillDismiss:[64],setCurrentBreakpoint:[64],getCurrentBreakpoint:[64]},[[9,"resize","onWindowResize"]],{isOpen:[{onIsOpenChange:0}],trigger:[{triggerChanged:0}],breakpoints:[{breakpointsChanged:0}]}]),gt={ionModalDidPresent:"ionViewDidEnter",ionModalWillPresent:"ionViewWillEnter",ionModalWillDismiss:"ionViewWillLeave",ionModalDidDismiss:"ionViewDidLeave"};function kt(){"undefined"!=typeof customElements&&["ion-modal","ion-backdrop"].forEach((t=>{switch(t){case"ion-modal":customElements.get(d(t))||customElements.define(d(t),wt);break;case"ion-backdrop":customElements.get(d(t))||G()}}))}export{wt as M,kt as d}
@@ -1,4 +0,0 @@
1
- /*!
2
- * (C) Ionic http://ionicframework.com - MIT License
3
- */
4
- import{d as n}from"./p-ZjP4CjeZ.js";import{f as e,c as o,g as t,a as i,b as a}from"./p-DlUdjUlf.js";import{OVERLAY_BACK_BUTTON_PRIORITY as s,shouldUseCloseWatcher as d}from"./p-q2WJ5Igc.js";import{e as r,c,p as l}from"./p-BriaEJK8.js";import{b as u}from"./p-BEiYs-sz.js";import{C as m}from"./p-Canp1qah.js";import{B as p}from"./p-B_gJaBk0.js";const f='[tabindex]:not([tabindex^="-"]):not([hidden]):not([disabled]), input:not([type=hidden]):not([tabindex^="-"]):not([hidden]):not([disabled]), textarea:not([tabindex^="-"]):not([hidden]):not([disabled]), button:not([tabindex^="-"]):not([hidden]):not([disabled]), select:not([tabindex^="-"]):not([hidden]):not([disabled]), ion-checkbox:not([tabindex^="-"]):not([hidden]):not([disabled]), ion-radio:not([tabindex^="-"]):not([hidden]):not([disabled]), .ion-focusable:not([tabindex^="-"]):not([hidden]):not([disabled]), .ion-focusable[disabled="false"]:not([tabindex^="-"]):not([hidden])',h=(n,e)=>{const o=n.querySelector(f);b(o,e??n)},v=(n,e)=>{const o=Array.from(n.querySelectorAll(f));b(o.length>0?o[o.length-1]:null,e??n)},b=(n,o)=>{let t=n;const i=n?.shadowRoot;if(i&&(t=i.querySelector(f)||n),t){const n=t.closest("ion-radio-group");n?n.setFocus():e(t)}else o.focus()};let w=0,y=0;const g=new WeakMap,x=n=>"ION-TOAST"!==n.tagName&&!1!==n.focusTrap&&(n=>!1!==n.showBackdrop&&!((n.backdropBreakpoint??0)>0))(n),k=n=>({create:e=>P(n,e),dismiss:(e,o,t)=>N(document,e,o,n,t),getTop:async()=>J(document,n)}),j=k("ion-alert"),O=k("ion-action-sheet"),T=k("ion-loading"),B=k("ion-modal"),C=k("ion-popover"),A=k("ion-toast"),D=n=>{"undefined"!=typeof document&&E(document);const e=w++;n.overlayIndex=e},I=n=>(n.hasAttribute("id")||(n.id="ion-overlay-"+ ++y),n.id),P=(n,e)=>"undefined"!=typeof window&&void 0!==window.customElements?window.customElements.whenDefined(n).then((()=>{const t=document.createElement(n);return t.classList.add("overlay-hidden"),Object.assign(t,{...e,hasController:!0}),W(document).appendChild(t),new Promise((n=>o(t,n)))})):Promise.resolve(),S=(n,o)=>{let t=n;const i=n?.shadowRoot;i&&(t=i.querySelector(f)||n),t?e(t):o.focus()},E=n=>{0===w&&(w=1,n.addEventListener("focus",(e=>{((n,e)=>{const o=J(e,"ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-popover"),i=n.target;o&&i&&(o.classList.contains(dn)||(o.shadowRoot?(()=>{if(o.contains(i))o.lastFocus=i;else if("ION-TOAST"===i.tagName)S(o.lastFocus,o);else{const n=o.lastFocus;h(o),n===e.activeElement&&v(o),o.lastFocus=e.activeElement}})():(()=>{if(o===i)o.lastFocus=void 0;else if("ION-TOAST"===i.tagName)S(o.lastFocus,o);else{const n=t(o);if(!n.contains(i))return;const a=n.querySelector(".ion-overlay-wrapper");if(!a)return;if(a.contains(i)||i===n.querySelector("ion-backdrop"))o.lastFocus=i;else{const n=o.lastFocus;h(a,o),n===e.activeElement&&v(a,o),o.lastFocus=e.activeElement}}})()))})(e,n)}),!0),n.addEventListener("ionBackButton",(e=>{const o=J(n);o?.backdropDismiss&&e.detail.register(s,(()=>{o.dismiss(void 0,en)}))})),d()||n.addEventListener("keydown",(e=>{if("Escape"===e.key){const e=J(n);e?.backdropDismiss&&e.dismiss(void 0,en)}})))},N=(n,e,o,t,i)=>{const a=J(n,t,i);return a?a.dismiss(e,o):Promise.reject("overlay does not exist")},q=(n,e)=>((n,e)=>(void 0===e&&(e="ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-popover,ion-toast"),Array.from(n.querySelectorAll(e)).filter((n=>n.overlayIndex>0))))(n,e).filter((n=>!n.classList.contains("overlay-hidden"))),J=(n,e,o)=>{const t=q(n,e);return(void 0===o?t:t.filter((n=>n.id===o))).slice(-1)[0]},M=()=>W(document).querySelector("ion-router-outlet, #ion-view-container-root"),$=(n=!1)=>{const e=M();e&&(n?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden"))},z=()=>{"undefined"!=typeof document&&(q(document).some((n=>x(n)))||($(!1),document.body.classList.remove(p)))},F=n=>{M()?.contains(n)||$(!0),document.body.classList.add(p)},G=n=>{if("undefined"==typeof document)return;const e=n;x(e)&&F(e)},L=async(n,e,o,i,a)=>{if(n.presented)return;"ION-TOAST"!==n.el.tagName&&U(n.el);const s=n.el,d=x(s);n.presented=!0,n.willPresent.emit(),d&&F(s),n.willPresentShorthand?.emit();const c=u(n),l=n.enterAnimation?n.enterAnimation:r.get(e,"ios"===c?o:i);if(await Z(n,l,n.el,a)&&(n.didPresent.emit(),n.didPresentShorthand?.emit()),n.keyboardClose&&(null===document.activeElement||!n.el.contains(document.activeElement))){const e=t(n.el).querySelector('[role="dialog"][tabindex]')??n.el;try{e.focus({preventScroll:!0})}catch{e.focus()}}n.el.removeAttribute("aria-hidden"),n.el.removeAttribute("inert")},U=async n=>{let e=document.activeElement;if(!e)return;e.blur();const o=e?.shadowRoot;o&&(e=o.querySelector(f)||e),await n.onDidDismiss(),null!==document.activeElement&&document.activeElement!==document.body||e.focus()},V=async(e,o,t,i,a,s,d)=>{if(!e.presented)return!1;const l=(void 0!==n?q(n):[]).filter((n=>x(n))),m=e.el;x(m)&&1===l.length&&l[0].id===m.id&&($(!1),document.body.classList.remove(p)),e.presented=!1;try{e.el.style.setProperty("pointer-events","none"),e.willDismiss.emit({data:o,role:t}),e.willDismissShorthand?.emit({data:o,role:t});const n=u(e),c=e.leaveAnimation?e.leaveAnimation:r.get(i,"ios"===n?a:s);t!==on&&await Z(e,c,e.el,d),e.didDismiss.emit({data:o,role:t}),e.didDismissShorthand?.emit({data:o,role:t}),(g.get(e)||[]).forEach((n=>n.destroy())),g.delete(e),e.el.classList.add("overlay-hidden"),e.el.style.removeProperty("pointer-events"),void 0!==e.el.lastFocus&&(e.el.lastFocus=void 0)}catch(n){c(`[${e.el.tagName.toLowerCase()}] - `,n)}return e.el.remove(),!0},W=n=>n.querySelector("ion-app")||n.body,Z=async(n,e,o,t)=>{o.classList.remove("overlay-hidden");const i=e(n.el,t);n.animated&&r.getBoolean("animated",!0)||i.duration(0),n.keyboardClose&&i.beforeAddWrite((()=>{const n=o.ownerDocument.activeElement;n?.matches("input,ion-input, ion-textarea")&&n.blur()}));const a=g.get(n)||[];return g.set(n,[...a,i]),await i.play(),!0},_=(n,e)=>{let o;const t=new Promise((n=>o=n));return K(n,e,(n=>{o(n.detail)})),t},K=(n,e,o)=>{const t=i=>{a(n,e,t),o(i)};i(n,e,t)},Y=n=>"cancel"===n||n===en,H=n=>n(),Q=(n,e)=>{if("function"==typeof n)return r.get("_zoneGate",H)((()=>{try{return n(e)}catch(n){throw n}}))},R=["","100%","100vw","100vh","100dvw","100dvh","100svw","100svh"],X=["auto","fit-content","min-content","max-content"],nn=n=>{const e=n.trim().toLowerCase();return R.includes(e)?"fullscreen":X.some((n=>e.endsWith(n)))?"content":"definite"},en="backdrop",on="gesture",tn=39,an=n=>{let e,o=!1;const t=m(),i=(i=!1)=>{if(e&&!i)return{delegate:e,inline:o};const{el:a,hasController:s,delegate:d}=n;return o=null!==a.parentNode&&!s,e=o?d||t:d,{inline:o,delegate:e}};return{attachViewToDom:async e=>{const{delegate:o}=i(!0);if(o)return await o.attachViewToDom(n.el,e);const{hasController:t}=n;if(t&&void 0!==e)throw new Error("framework delegate is missing");return null},removeViewFromDom:()=>{const{delegate:e}=i();e&&void 0!==n.el&&e.removeViewFromDom(n.el.parentElement,n.el)}}},sn=()=>{let n;const e=()=>{n&&(n(),n=void 0)};return{addClickListener:(o,t)=>{e();const i=void 0!==t?document.getElementById(t):null;i?n=((n,e)=>{const o=()=>{e.present()};return n.addEventListener("click",o),()=>{n.removeEventListener("click",o)}})(i,o):l(`[${o.tagName.toLowerCase()}] - A trigger element with the ID "${t}" was not found in the DOM. The trigger element must be in the DOM when the "trigger" property is set on an overlay component.`,o)},removeClickListener:e}},dn="ion-disable-focus-trap";export{en as B,dn as F,on as G,tn as O,j as a,O as b,an as c,sn as d,L as e,V as f,_ as g,D as h,Y as i,z as j,I as k,T as l,B as m,nn as n,h as o,C as p,J as q,G as r,Q as s,A as t,v as u}
@@ -1,4 +0,0 @@
1
- /*!
2
- * (C) Ionic http://ionicframework.com - MIT License
3
- */
4
- import{w as t}from"./p-ZjP4CjeZ.js";import{e,c as n}from"./p-BriaEJK8.js";const o=()=>e.get("experimentalCloseWatcher",!1)&&void 0!==t&&"CloseWatcher"in t,r=()=>{document.addEventListener("backbutton",(()=>{}))},i=()=>{const e=document;let r=!1;const i=()=>{if(r)return;let t=0,o=[];const i=new CustomEvent("ionBackButton",{bubbles:!1,detail:{register(e,n){o.push({priority:e,handler:n,id:t++})}}});e.dispatchEvent(i);const a=()=>{if(o.length>0){let t={priority:Number.MIN_SAFE_INTEGER,handler:()=>{},id:-1};o.forEach((e=>{e.priority>=t.priority&&(t=e)})),r=!0,o=o.filter((e=>e.id!==t.id)),(async t=>{try{if(t?.handler){const e=t.handler(a);null!=e&&await e}}catch(t){n("[ion-app] - Exception in startHardwareBackButton:",t)}})(t).then((()=>r=!1))}};a()};if(o()){let e;const n=()=>{e?.destroy(),e=new t.CloseWatcher,e.onclose=()=>{i(),n()}};n()}else e.addEventListener("backbutton",i)},a=100,c=99;export{c as MENU_BACK_BUTTON_PRIORITY,a as OVERLAY_BACK_BUTTON_PRIORITY,r as blockHardwareBackButton,o as shouldUseCloseWatcher,i as startHardwareBackButton}
@@ -1,4 +0,0 @@
1
- /*!
2
- * (C) Ionic http://ionicframework.com - MIT License
3
- */
4
- import{r as t,d as e,i,c as n,h as o,f as s,g as r}from"./p-D9OR05yj.js";import{g as a}from"./p-hHmYLOfE.js";import{q as d,B as h,o as l,u as c,G as m,v as p}from"./p-DZUqAr_6.js";import{G as u}from"./p-B_gJaBk0.js";import{s as b,i as f,l as g,e as v}from"./p-B4xjg_Qu.js";import{m as x}from"./p-Ba6ZV-qU.js";import{b as w,a as y}from"./p-CrAPHbJ3.js";import{h as k,c as z}from"./p-byZM6qHV.js";import{u as C,v as j}from"./p-BvabGprD.js";import"./p-B4ELlbJE.js";import"./p-Dojwmvde.js";import"./p-B4wzg4z4.js";const A=class{constructor(i){t(this,i),this.ionWillOpen=e(this,"ionWillOpen",7),this.ionWillClose=e(this,"ionWillClose",7),this.ionDidOpen=e(this,"ionDidOpen",7),this.ionDidClose=e(this,"ionDidClose",7),this.ionMenuChange=e(this,"ionMenuChange",7),this.lastOnEnd=0,this.blocker=u.createBlocker({disableScroll:!0}),this.didLoad=!1,this.operationCancelled=!1,this.isAnimating=!1,this._isOpen=!1,this.inheritedAttributes={},this.handleFocus=t=>{const e=d(document);e&&!e.contains(this.el)||this.trapKeyboardFocus(t,document)},this.isPaneVisible=!1,this.isEndSide=!1,this.disabled=!1,this.side="start",this.swipeGesture=!0,this.maxEdgeStart=50}typeChanged(t,e){const i=this.contentEl;i&&(void 0!==e&&i.classList.remove(`menu-content-${e}`),i.classList.add(`menu-content-${t}`),i.removeAttribute("style")),this.menuInnerEl&&this.menuInnerEl.removeAttribute("style"),this.animation=void 0}disabledChanged(){this.updateState(),this.ionMenuChange.emit({disabled:this.disabled,open:this._isOpen})}sideChanged(){this.isEndSide=b(this.side,this.el),this.animation=void 0}swipeGestureChanged(){this.updateState()}async connectedCallback(){"undefined"!=typeof customElements&&null!=customElements&&await customElements.whenDefined("ion-menu"),void 0===this.type&&(this.type=i.get("menuType","overlay"));const t=void 0!==this.contentId?document.getElementById(this.contentId):null;null!==t?(this.el.contains(t)&&n('[ion-menu] - The "contentId" should refer to the main view\'s ion-content, not the ion-content inside of the ion-menu.'),this.contentEl=t,t.classList.add("menu-content"),this.typeChanged(this.type,void 0),this.sideChanged(),x._register(this),this.menuChanged(),this.gesture=(await import("./p-D0YpjgON.js")).createGesture({el:document,gestureName:"menu-swipe",gesturePriority:30,threshold:10,blurOnStart:!0,canStart:t=>this.canStart(t),onWillStart:()=>this.onWillStart(),onStart:()=>this.onStart(),onMove:t=>this.onMove(t),onEnd:t=>this.onEnd(t)}),this.updateState()):n('[ion-menu] - Must have a "content" element to listen for drag events on.')}componentWillLoad(){this.inheritedAttributes=f(this.el)}async componentDidLoad(){this.didLoad=!0;const t=this.el.closest("ion-split-pane");null!==t&&(this.isPaneVisible=await t.isVisible()),this.menuChanged(),this.updateState()}menuChanged(){this.didLoad&&this.ionMenuChange.emit({disabled:this.disabled,open:this._isOpen})}async disconnectedCallback(){await this.close(!1),this.blocker.destroy(),x._unregister(this),this.animation&&this.animation.destroy(),this.gesture&&(this.gesture.destroy(),this.gesture=void 0),this.animation=void 0,this.contentEl=void 0}onSplitPaneChanged(t){const e=this.el.closest("ion-split-pane");null!==e&&e===t.target&&(this.isPaneVisible=t.detail.visible,this.updateState())}onBackdropClick(t){this._isOpen&&this.lastOnEnd<t.timeStamp-100&&t.composedPath&&!t.composedPath().includes(this.menuInnerEl)&&(t.preventDefault(),t.stopPropagation(),this.close(void 0,h))}onKeydown(t){"Escape"===t.key&&this.close(void 0,h)}isOpen(){return Promise.resolve(this._isOpen)}isActive(){return Promise.resolve(this._isActive())}open(t=!0){return this.setOpen(!0,t)}close(t=!0,e){return this.setOpen(!1,t,e)}toggle(t=!0){return this.setOpen(!this._isOpen,t)}setOpen(t,e=!0,i){return document.activeElement?.blur(),x._setOpen(this,t,e,i)}trapKeyboardFocus(t,e){const i=t.target;if(i)if(this.el.contains(i))this.lastFocus=i;else{const{el:t}=this;l(t),this.lastFocus===e.activeElement&&c(t)}}async _setOpen(t,e=!0,i){return!(!this._isActive()||this.isAnimating||t===this._isOpen||(this.beforeAnimation(t,i),await this.loadAnimation(),await this.startAnimation(t,e),this.operationCancelled?(this.operationCancelled=!1,1):(this.afterAnimation(t,i),0)))}async loadAnimation(){const t=this.menuInnerEl.offsetWidth,e=b(this.side,this.el);if(t===this.width&&void 0!==this.animation&&e===this.isEndSide)return;this.width=t,this.isEndSide=e,this.animation&&(this.animation.destroy(),this.animation=void 0);const n=this.animation=await x._createAnimation(this.type,this);i.getBoolean("animated",!0)||n.duration(0),n.fill("both")}async startAnimation(t,e){const i=!t,n=w(this),o="ios"===n?"cubic-bezier(0.32,0.72,0,1)":"cubic-bezier(0.0,0.0,0.2,1)",s="ios"===n?"cubic-bezier(1, 0, 0.68, 0.28)":"cubic-bezier(0.4, 0, 0.6, 1)",r=this.animation.direction(i?"reverse":"normal").easing(i?s:o);e?await r.play():r.play({sync:!0}),"reverse"===r.getDirection()&&r.direction("normal")}_isActive(){return!this.disabled&&!this.isPaneVisible}canSwipe(){return this.swipeGesture&&!this.isAnimating&&this._isActive()}canStart(t){return!(document.querySelector("ion-modal.show-modal")||!this.canSwipe())&&(!!this._isOpen||!x._getOpenSync()&&_(window,t.currentX,this.isEndSide,this.maxEdgeStart))}onWillStart(){return this.beforeAnimation(!this._isOpen,m),this.loadAnimation()}onStart(){this.isAnimating&&this.animation?this.animation.progressStart(!0,this._isOpen?1:0):g(!1,"isAnimating has to be true")}onMove(t){if(!this.isAnimating||!this.animation)return void g(!1,"isAnimating has to be true");const e=S(t.deltaX,this._isOpen,this.isEndSide)/this.width;this.animation.progressStep(this._isOpen?1-e:e)}onEnd(t){if(!this.isAnimating||!this.animation)return void g(!1,"isAnimating has to be true");const e=this._isOpen,i=this.isEndSide,n=S(t.deltaX,e,i),o=this.width,s=n/o,r=t.velocityX,d=o/2,h=r>=0&&(r>.2||t.deltaX>d),l=r<=0&&(r<-.2||t.deltaX<-d),c=e?i?h:l:i?l:h;let p=!e&&c;e&&!c&&(p=!0),this.lastOnEnd=t.currentTime;let u=c?.001:-.001;u+=a([0,0],[.4,0],[.6,1],[1,1],v(0,s<0?.01:s,.9999))[0]||0;const b=this._isOpen?!c:c;this.animation.easing("cubic-bezier(0.4, 0.0, 0.6, 1)").onFinish((()=>this.afterAnimation(p,m)),{oneTimeCallback:!0}).progressEnd(b?1:0,this._isOpen?1-u:u,300)}beforeAnimation(t,e){g(!this.isAnimating,"_before() should not be called while animating"),y("android")&&this.el.setAttribute("aria-hidden","true"),this.el.classList.add(D),this.el.setAttribute("tabindex","0"),this.backdropEl&&this.backdropEl.classList.add(B),this.contentEl&&(this.contentEl.classList.add(E),this.contentEl.setAttribute("aria-hidden","true")),this.blocker.block(),this.isAnimating=!0,t?this.ionWillOpen.emit():this.ionWillClose.emit({role:e})}afterAnimation(t,e){if(this._isOpen=t,this.isAnimating=!1,this._isOpen||this.blocker.unblock(),t){y("android")&&this.el.removeAttribute("aria-hidden"),this.ionDidOpen.emit();const t=document.activeElement?.closest("ion-menu");t!==this.el&&this.el.focus(),document.addEventListener("focus",this.handleFocus,!0)}else this.el.removeAttribute("aria-hidden"),this.el.classList.remove(D),this.el.removeAttribute("tabindex"),this.contentEl&&(this.contentEl.classList.remove(E),this.contentEl.removeAttribute("aria-hidden")),this.backdropEl&&this.backdropEl.classList.remove(B),this.animation&&this.animation.stop(),this.ionDidClose.emit({role:e}),document.removeEventListener("focus",this.handleFocus,!0)}updateState(){const t=this._isActive();this.gesture&&this.gesture.enable(t&&this.swipeGesture),t||(this.isAnimating&&(this.operationCancelled=!0),this.afterAnimation(!1,m))}render(){const{type:t,disabled:e,el:i,isPaneVisible:n,inheritedAttributes:r,side:a}=this,d=w(this);return o(s,{key:"1208ba437fa58680325408d3d4c8580950da1d68",onKeyDown:p()?null:this.onKeydown,role:"navigation","aria-label":r["aria-label"]||"menu",class:{[d]:!0,[`menu-type-${t}`]:!0,"menu-enabled":!e,[`menu-side-${a}`]:!0,"menu-pane-visible":n,"split-pane-side":k("ion-split-pane",i)}},o("div",{key:"c0ddc957b7a7956b41901d77ae02d91e73071c55",class:"menu-inner",part:"container",ref:t=>this.menuInnerEl=t},o("slot",{key:"6e44c56116431a024f114ab85ded1b822c942fac"})),o("ion-backdrop",{key:"5f4bbcf84444d96ec6b02bf567e1aaf95f59078d",ref:t=>this.backdropEl=t,class:"menu-backdrop",tappable:!1,stopPropagation:!1,part:"backdrop"}))}get el(){return r(this)}static get watchers(){return{type:[{typeChanged:0}],disabled:[{disabledChanged:0}],side:[{sideChanged:0}],swipeGesture:[{swipeGestureChanged:0}]}}},S=(t,e,i)=>Math.max(0,e!==i?-t:t),_=(t,e,i,n)=>i?e>=t.innerWidth-n:e<=n,D="show-menu",B="show-backdrop",E="menu-content-open";A.style={ios:":host{--width:304px;--min-width:auto;--max-width:auto;--height:100%;--min-height:auto;--max-height:auto;--background:var(--ion-background-color, #fff);left:0;right:0;top:0;bottom:0;display:none;position:absolute;contain:strict}:host(.show-menu){display:block}.menu-inner{-webkit-transform:translateX(-9999px);transform:translateX(-9999px);display:-ms-flexbox;display:flex;position:absolute;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:justify;justify-content:space-between;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);background:var(--background);contain:strict}:host(.menu-side-start) .menu-inner{--ion-safe-area-right:0px;top:0;bottom:0}:host(.menu-side-start) .menu-inner{inset-inline-start:0;inset-inline-end:auto}:host-context([dir=rtl]):host(.menu-side-start) .menu-inner,:host-context([dir=rtl]).menu-side-start .menu-inner{--ion-safe-area-right:unset;--ion-safe-area-left:0px}@supports selector(:dir(rtl)){:host(.menu-side-start:dir(rtl)) .menu-inner{--ion-safe-area-right:unset;--ion-safe-area-left:0px}}:host(.menu-side-end) .menu-inner{--ion-safe-area-left:0px;top:0;bottom:0}:host(.menu-side-end) .menu-inner{inset-inline-start:auto;inset-inline-end:0}:host-context([dir=rtl]):host(.menu-side-end) .menu-inner,:host-context([dir=rtl]).menu-side-end .menu-inner{--ion-safe-area-left:unset;--ion-safe-area-right:0px}@supports selector(:dir(rtl)){:host(.menu-side-end:dir(rtl)) .menu-inner{--ion-safe-area-left:unset;--ion-safe-area-right:0px}}ion-backdrop{display:none;opacity:0.01;z-index:-1}@media (max-width: 340px){.menu-inner{--width:264px}}:host(.menu-type-reveal){z-index:0}:host(.menu-type-reveal.show-menu) .menu-inner{-webkit-transform:translate3d(0, 0, 0);transform:translate3d(0, 0, 0)}:host(.menu-type-overlay){z-index:1000}:host(.menu-type-overlay) .show-backdrop{display:block;cursor:pointer}:host(.menu-pane-visible){-ms-flex:0 1 auto;flex:0 1 auto;width:var(--side-width, var(--width));min-width:var(--side-min-width, var(--min-width));max-width:var(--side-max-width, var(--max-width))}:host(.menu-pane-visible.split-pane-side){left:0;right:0;top:0;bottom:0;position:relative;-webkit-box-shadow:none;box-shadow:none;z-index:0}:host(.menu-pane-visible.split-pane-side.menu-enabled){display:-ms-flexbox;display:flex;-ms-flex-negative:0;flex-shrink:0}:host(.menu-pane-visible.split-pane-side){-ms-flex-order:-1;order:-1}:host(.menu-pane-visible.split-pane-side[side=end]){-ms-flex-order:1;order:1}:host(.menu-pane-visible) .menu-inner{left:0;right:0;width:auto;-webkit-transform:none;transform:none;-webkit-box-shadow:none;box-shadow:none}:host(.menu-pane-visible) ion-backdrop{display:hidden !important}:host(.menu-pane-visible.split-pane-side){-webkit-border-start:0;border-inline-start:0;-webkit-border-end:var(--border);border-inline-end:var(--border);border-top:0;border-bottom:0;min-width:var(--side-min-width);max-width:var(--side-max-width)}:host(.menu-pane-visible.split-pane-side[side=end]){-webkit-border-start:var(--border);border-inline-start:var(--border);-webkit-border-end:0;border-inline-end:0;border-top:0;border-bottom:0;min-width:var(--side-min-width);max-width:var(--side-max-width)}:host(.menu-type-push){z-index:1000}:host(.menu-type-push) .show-backdrop{display:block}",md:":host{--width:304px;--min-width:auto;--max-width:auto;--height:100%;--min-height:auto;--max-height:auto;--background:var(--ion-background-color, #fff);left:0;right:0;top:0;bottom:0;display:none;position:absolute;contain:strict}:host(.show-menu){display:block}.menu-inner{-webkit-transform:translateX(-9999px);transform:translateX(-9999px);display:-ms-flexbox;display:flex;position:absolute;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:justify;justify-content:space-between;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);background:var(--background);contain:strict}:host(.menu-side-start) .menu-inner{--ion-safe-area-right:0px;top:0;bottom:0}:host(.menu-side-start) .menu-inner{inset-inline-start:0;inset-inline-end:auto}:host-context([dir=rtl]):host(.menu-side-start) .menu-inner,:host-context([dir=rtl]).menu-side-start .menu-inner{--ion-safe-area-right:unset;--ion-safe-area-left:0px}@supports selector(:dir(rtl)){:host(.menu-side-start:dir(rtl)) .menu-inner{--ion-safe-area-right:unset;--ion-safe-area-left:0px}}:host(.menu-side-end) .menu-inner{--ion-safe-area-left:0px;top:0;bottom:0}:host(.menu-side-end) .menu-inner{inset-inline-start:auto;inset-inline-end:0}:host-context([dir=rtl]):host(.menu-side-end) .menu-inner,:host-context([dir=rtl]).menu-side-end .menu-inner{--ion-safe-area-left:unset;--ion-safe-area-right:0px}@supports selector(:dir(rtl)){:host(.menu-side-end:dir(rtl)) .menu-inner{--ion-safe-area-left:unset;--ion-safe-area-right:0px}}ion-backdrop{display:none;opacity:0.01;z-index:-1}@media (max-width: 340px){.menu-inner{--width:264px}}:host(.menu-type-reveal){z-index:0}:host(.menu-type-reveal.show-menu) .menu-inner{-webkit-transform:translate3d(0, 0, 0);transform:translate3d(0, 0, 0)}:host(.menu-type-overlay){z-index:1000}:host(.menu-type-overlay) .show-backdrop{display:block;cursor:pointer}:host(.menu-pane-visible){-ms-flex:0 1 auto;flex:0 1 auto;width:var(--side-width, var(--width));min-width:var(--side-min-width, var(--min-width));max-width:var(--side-max-width, var(--max-width))}:host(.menu-pane-visible.split-pane-side){left:0;right:0;top:0;bottom:0;position:relative;-webkit-box-shadow:none;box-shadow:none;z-index:0}:host(.menu-pane-visible.split-pane-side.menu-enabled){display:-ms-flexbox;display:flex;-ms-flex-negative:0;flex-shrink:0}:host(.menu-pane-visible.split-pane-side){-ms-flex-order:-1;order:-1}:host(.menu-pane-visible.split-pane-side[side=end]){-ms-flex-order:1;order:1}:host(.menu-pane-visible) .menu-inner{left:0;right:0;width:auto;-webkit-transform:none;transform:none;-webkit-box-shadow:none;box-shadow:none}:host(.menu-pane-visible) ion-backdrop{display:hidden !important}:host(.menu-pane-visible.split-pane-side){-webkit-border-start:0;border-inline-start:0;-webkit-border-end:var(--border);border-inline-end:var(--border);border-top:0;border-bottom:0;min-width:var(--side-min-width);max-width:var(--side-max-width)}:host(.menu-pane-visible.split-pane-side[side=end]){-webkit-border-start:var(--border);border-inline-start:var(--border);-webkit-border-end:0;border-inline-end:0;border-top:0;border-bottom:0;min-width:var(--side-min-width);max-width:var(--side-max-width)}:host(.menu-type-overlay) .menu-inner{-webkit-box-shadow:4px 0px 16px rgba(0, 0, 0, 0.18);box-shadow:4px 0px 16px rgba(0, 0, 0, 0.18)}"};const O=async t=>{const e=await x.get(t);return!(!e||!await e.isActive())},P=class{constructor(e){t(this,e),this.inheritedAttributes={},this.visible=!1,this.disabled=!1,this.autoHide=!0,this.type="button",this.onClick=async()=>x.toggle(this.menu)}componentWillLoad(){this.inheritedAttributes=f(this.el)}componentDidLoad(){this.visibilityChanged()}async visibilityChanged(){this.visible=await O(this.menu)}render(){const{color:t,disabled:e,inheritedAttributes:n}=this,r=w(this),a=i.get("menuIcon","ios"===r?C:j),d=this.autoHide&&!this.visible,h={type:this.type},l=n["aria-label"]||"menu";return o(s,{key:"b8869377822b082c6c4d3f16135b50b733eabf65",onClick:this.onClick,"aria-disabled":e?"true":null,"aria-hidden":d?"true":null,class:z(t,{[r]:!0,button:!0,"menu-button-hidden":d,"menu-button-disabled":e,"in-toolbar":k("ion-toolbar",this.el),"in-toolbar-color":k("ion-toolbar[color]",this.el),"ion-activatable":!0,"ion-focusable":!0})},o("button",{key:"48fc0a7011414b60dd7d5136f247e937ae4bb8c8",...h,disabled:e,class:"button-native",part:"native","aria-label":l},o("span",{key:"8c712f28c5afd345e403a9afc525931112852708",class:"button-inner"},o("slot",{key:"dd872325e42baf435188478c8d1cfc416075089d"},o("ion-icon",{key:"a4f02bdb715b07792c17e12c7837873d70171f88",part:"icon",icon:a,mode:r,lazy:!1,"aria-hidden":"true"}))),"md"===r&&o("ion-ripple-effect",{key:"564e2a8a804e14d1135502f7b17d8b7b9862e81b",type:"unbounded"})))}get el(){return r(this)}};P.style={ios:':host{--background:transparent;--color-focused:currentColor;--border-radius:initial;--padding-top:0;--padding-bottom:0;color:var(--color);text-align:center;text-decoration:none;text-overflow:ellipsis;text-transform:none;white-space:nowrap;-webkit-font-kerning:none;font-kerning:none}.button-native{border-radius:var(--border-radius);font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;-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);-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:-ms-flexbox;display:flex;position:relative;-ms-flex-flow:row nowrap;flex-flow:row nowrap;-ms-flex-negative:0;flex-shrink:0;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;width:100%;height:100%;min-height:inherit;border:0;outline:none;background:var(--background);line-height:1;cursor:pointer;overflow:hidden;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;z-index:0;-webkit-appearance:none;-moz-appearance:none;appearance:none}.button-inner{display:-ms-flexbox;display:flex;position:relative;-ms-flex-flow:row nowrap;flex-flow:row nowrap;-ms-flex-negative:0;flex-shrink:0;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;width:100%;height:100%;min-height:inherit;z-index:1}ion-icon{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;pointer-events:none}:host(.menu-button-hidden){display:none}:host(.menu-button-disabled){cursor:default;opacity:0.5;pointer-events:none}:host(.ion-focused) .button-native{color:var(--color-focused)}:host(.ion-focused) .button-native::after{background:var(--background-focused);opacity:var(--background-focused-opacity)}.button-native::after{left:0;right:0;top:0;bottom:0;position:absolute;content:"";opacity:0}@media (any-hover: hover){:host(:hover) .button-native{color:var(--color-hover)}:host(:hover) .button-native::after{background:var(--background-hover);opacity:var(--background-hover-opacity, 0)}}:host(.ion-color) .button-native{color:var(--ion-color-base)}:host(.in-toolbar:not(.in-toolbar-color)){color:var(--ion-toolbar-color, var(--color))}:host{--background-focused:currentColor;--background-focused-opacity:.1;--border-radius:4px;--color:var(--ion-color-primary, #0054e9);--padding-start:5px;--padding-end:5px;min-height:32px;font-size:clamp(31px, 1.9375rem, 38.13px)}:host(.ion-activated){opacity:0.4}@media (any-hover: hover){:host(:hover){opacity:0.6}}',md:':host{--background:transparent;--color-focused:currentColor;--border-radius:initial;--padding-top:0;--padding-bottom:0;color:var(--color);text-align:center;text-decoration:none;text-overflow:ellipsis;text-transform:none;white-space:nowrap;-webkit-font-kerning:none;font-kerning:none}.button-native{border-radius:var(--border-radius);font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;-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);-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:-ms-flexbox;display:flex;position:relative;-ms-flex-flow:row nowrap;flex-flow:row nowrap;-ms-flex-negative:0;flex-shrink:0;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;width:100%;height:100%;min-height:inherit;border:0;outline:none;background:var(--background);line-height:1;cursor:pointer;overflow:hidden;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;z-index:0;-webkit-appearance:none;-moz-appearance:none;appearance:none}.button-inner{display:-ms-flexbox;display:flex;position:relative;-ms-flex-flow:row nowrap;flex-flow:row nowrap;-ms-flex-negative:0;flex-shrink:0;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;width:100%;height:100%;min-height:inherit;z-index:1}ion-icon{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;pointer-events:none}:host(.menu-button-hidden){display:none}:host(.menu-button-disabled){cursor:default;opacity:0.5;pointer-events:none}:host(.ion-focused) .button-native{color:var(--color-focused)}:host(.ion-focused) .button-native::after{background:var(--background-focused);opacity:var(--background-focused-opacity)}.button-native::after{left:0;right:0;top:0;bottom:0;position:absolute;content:"";opacity:0}@media (any-hover: hover){:host(:hover) .button-native{color:var(--color-hover)}:host(:hover) .button-native::after{background:var(--background-hover);opacity:var(--background-hover-opacity, 0)}}:host(.ion-color) .button-native{color:var(--ion-color-base)}:host(.in-toolbar:not(.in-toolbar-color)){color:var(--ion-toolbar-color, var(--color))}:host{--background-focused:currentColor;--background-focused-opacity:.12;--background-hover:currentColor;--background-hover-opacity:.04;--border-radius:50%;--color:initial;--padding-start:8px;--padding-end:8px;width:3rem;height:3rem;font-size:1.5rem}:host(.ion-color.ion-focused)::after{background:var(--ion-color-base)}@media (any-hover: hover){:host(.ion-color:hover) .button-native::after{background:var(--ion-color-base)}}'};const G=class{constructor(e){t(this,e),this.visible=!1,this.autoHide=!0,this.onClick=()=>x.toggle(this.menu)}connectedCallback(){this.visibilityChanged()}async visibilityChanged(){this.visible=await O(this.menu)}render(){const t=w(this),e=this.autoHide&&!this.visible;return o(s,{key:"76d21ea6493b8161860c941e3754fef1e20395cc",onClick:this.onClick,"aria-hidden":e?"true":null,class:{[t]:!0,"menu-toggle-hidden":e}},o("slot",{key:"9383610fd3105e1928a38788eb596e313e2b07f8"}))}};G.style=":host(.menu-toggle-hidden){display:none}";export{A as ion_menu,P as ion_menu_button,G as ion_menu_toggle}
@@ -1,4 +0,0 @@
1
- /*!
2
- * (C) Ionic http://ionicframework.com - MIT License
3
- */
4
- import{n as t,c as e}from"./p-B4xjg_Qu.js";import{M as n}from"./p-DZUqAr_6.js";import{a as r}from"./p-D9OR05yj.js";import{b as s}from"./p-CrAPHbJ3.js";import{c as a}from"./p-B4wzg4z4.js";const o=t=>a().duration(t?400:300),i=t=>{let e,n;const r=t.width+8,i=a(),u=a();t.isEndSide?(e=r+"px",n="0px"):(e=-r+"px",n="0px"),i.addElement(t.menuInnerEl).fromTo("transform",`translateX(${e})`,`translateX(${n})`);const c="ios"===s(t),p=c?.2:.25;return u.addElement(t.backdropEl).fromTo("opacity",.01,p),o(c).addAnimation([i,u])},u=t=>{let e,n;const r=s(t),i=t.width;t.isEndSide?(e=-i+"px",n=i+"px"):(e=i+"px",n=-i+"px");const u=a().addElement(t.menuInnerEl).fromTo("transform",`translateX(${n})`,"translateX(0px)"),c=a().addElement(t.contentEl).fromTo("transform","translateX(0px)",`translateX(${e})`),p=a().addElement(t.backdropEl).fromTo("opacity",.01,.32);return o("ios"===r).addAnimation([u,c,p])},c=t=>{const e=s(t),n=t.width*(t.isEndSide?-1:1)+"px",r=a().addElement(t.contentEl).fromTo("transform","translateX(0px)",`translateX(${n})`);return o("ios"===e).addAnimation(r)},p=(()=>{const s=new Map,a=[],o=async(t,e=!1)=>{if(await d(),"start"===t||"end"===t){const n=a.filter((e=>e.side===t&&!e.disabled));if(n.length>=1)return n.length>1&&e&&r(`menuController queried for a menu on the "${t}" side, but ${n.length} menus were found. The first menu reference will be used. If this is not the behavior you want then pass the ID of the menu instead of its side.`,n.map((t=>t.el))),n[0].el;const s=a.filter((e=>e.side===t));if(s.length>=1)return s.length>1&&e&&r(`menuController queried for a menu on the "${t}" side, but ${s.length} menus were found. The first menu reference will be used. If this is not the behavior you want then pass the ID of the menu instead of its side.`,s.map((t=>t.el))),s[0].el}else if(null!=t)return w((e=>e.menuId===t));return w((t=>!t.disabled))||(a.length>0?a[0].el:void 0)},p=async()=>(await d(),f()),m=(t,e)=>{s.set(t,e)},f=()=>w((t=>t._isOpen)),l=()=>a.some((t=>t.isAnimating)),w=t=>{const e=a.find(t);if(void 0!==e)return e.el},d=()=>Promise.all(Array.from(document.querySelectorAll("ion-menu")).map((t=>new Promise((n=>e(t,n))))));return m("reveal",c),m("push",u),m("overlay",i),t?.addEventListener("ionBackButton",(t=>{const e=f();e&&t.detail.register(n,(()=>e.close()))})),{registerAnimation:m,get:o,getMenus:async()=>(await d(),a.map((t=>t.el))),getOpen:p,isEnabled:async t=>{const e=await o(t);return!!e&&!e.disabled},swipeGesture:async(t,e)=>{const n=await o(e);return n&&(n.swipeGesture=t),n},isAnimating:async()=>(await d(),l()),isOpen:async t=>{if(null!=t){const e=await o(t);return void 0!==e&&e.isOpen()}return void 0!==await p()},enable:async(t,e)=>{const n=await o(e);return n&&(n.disabled=!t),n},toggle:async t=>{const e=await o(t,!0);return!!e&&e.toggle()},close:async t=>{const e=await(void 0!==t?o(t,!0):p());return void 0!==e&&e.close()},open:async t=>{const e=await o(t,!0);return!!e&&e.open()},_getOpenSync:f,_createAnimation:(t,e)=>{const n=s.get(t);if(!n)throw new Error("animation not registered");return n(e)},_register:t=>{a.indexOf(t)<0&&a.push(t)},_unregister:t=>{const e=a.indexOf(t);e>-1&&a.splice(e,1)},_setOpen:async(t,e,n,r)=>{if(l())return!1;if(e){const e=await p();e&&t.el!==e&&await e.setOpen(!1,!1)}return t._setOpen(e,n,r)}}})();export{p as m}