@rdlabo/ionic-theme-ios27 1.2.0-2 → 1.2.0-4

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 (180) hide show
  1. package/README.md +15 -2
  2. package/dist/_virtual/_rolldown/runtime.js +13 -0
  3. package/dist/css/ionic-theme-ios27.css +1 -1
  4. package/dist/css/vertical-bars.css +1 -1
  5. package/dist/focus-controller/index.d.ts +4 -2
  6. package/dist/focus-controller/index.d.ts.map +1 -1
  7. package/dist/focus-controller/index.js +100 -57
  8. package/dist/focus-controller/index.js.map +1 -0
  9. package/dist/index.d.ts +10 -8
  10. package/dist/index.d.ts.map +1 -1
  11. package/dist/index.js +54 -60
  12. package/dist/index.js.map +1 -0
  13. package/dist/native/components/index.d.ts +13 -10
  14. package/dist/native/components/index.d.ts.map +1 -1
  15. package/dist/native/components/index.js +39 -41
  16. package/dist/native/components/index.js.map +1 -0
  17. package/dist/native/components/ion-back-button.d.ts +6 -1
  18. package/dist/native/components/ion-back-button.d.ts.map +1 -1
  19. package/dist/native/components/ion-back-button.js +19 -13
  20. package/dist/native/components/ion-back-button.js.map +1 -0
  21. package/dist/native/components/ion-button.d.ts +8 -2
  22. package/dist/native/components/ion-button.d.ts.map +1 -1
  23. package/dist/native/components/ion-button.js +22 -17
  24. package/dist/native/components/ion-button.js.map +1 -0
  25. package/dist/native/components/ion-buttons.d.ts +8 -2
  26. package/dist/native/components/ion-buttons.d.ts.map +1 -1
  27. package/dist/native/components/ion-buttons.js +29 -33
  28. package/dist/native/components/ion-buttons.js.map +1 -0
  29. package/dist/native/components/ion-fab.d.ts +6 -1
  30. package/dist/native/components/ion-fab.d.ts.map +1 -1
  31. package/dist/native/components/ion-fab.js +131 -151
  32. package/dist/native/components/ion-fab.js.map +1 -0
  33. package/dist/native/components/ion-menu-button.d.ts +8 -2
  34. package/dist/native/components/ion-menu-button.d.ts.map +1 -1
  35. package/dist/native/components/ion-menu-button.js +29 -19
  36. package/dist/native/components/ion-menu-button.js.map +1 -0
  37. package/dist/native/components/ion-segment.d.ts +6 -1
  38. package/dist/native/components/ion-segment.d.ts.map +1 -1
  39. package/dist/native/components/ion-segment.js +29 -23
  40. package/dist/native/components/ion-segment.js.map +1 -0
  41. package/dist/native/components/ion-tab-bar.d.ts +6 -1
  42. package/dist/native/components/ion-tab-bar.d.ts.map +1 -1
  43. package/dist/native/components/ion-tab-bar.js +49 -40
  44. package/dist/native/components/ion-tab-bar.js.map +1 -0
  45. package/dist/native/components/searchable-tabs.d.ts +17 -15
  46. package/dist/native/components/searchable-tabs.d.ts.map +1 -1
  47. package/dist/native/components/searchable-tabs.js +382 -435
  48. package/dist/native/components/searchable-tabs.js.map +1 -0
  49. package/dist/native/definitions.d.ts +118 -111
  50. package/dist/native/definitions.d.ts.map +1 -1
  51. package/dist/native/definitions.js +0 -1
  52. package/dist/native/foldable/fold-state.d.ts +5 -0
  53. package/dist/native/foldable/fold-state.d.ts.map +1 -0
  54. package/dist/native/foldable/fold-state.js +14 -0
  55. package/dist/native/foldable/fold-state.js.map +1 -0
  56. package/dist/native/foldable/types.d.ts +12 -0
  57. package/dist/native/foldable/types.d.ts.map +1 -0
  58. package/dist/native/foldable/types.js +0 -0
  59. package/dist/native/index.d.ts +6 -3
  60. package/dist/native/index.d.ts.map +1 -1
  61. package/dist/native/index.js +228 -204
  62. package/dist/native/index.js.map +1 -0
  63. package/dist/native/prehide.d.ts +4 -2
  64. package/dist/native/prehide.d.ts.map +1 -1
  65. package/dist/native/prehide.js +220 -242
  66. package/dist/native/prehide.js.map +1 -0
  67. package/dist/native/runtime.d.ts +3 -1
  68. package/dist/native/runtime.d.ts.map +1 -1
  69. package/dist/native/runtime.js +626 -724
  70. package/dist/native/runtime.js.map +1 -0
  71. package/dist/native/shared/candidate.d.ts +16 -11
  72. package/dist/native/shared/candidate.d.ts.map +1 -1
  73. package/dist/native/shared/candidate.js +96 -95
  74. package/dist/native/shared/candidate.js.map +1 -0
  75. package/dist/native/shared/crossfade.d.ts +6 -4
  76. package/dist/native/shared/crossfade.d.ts.map +1 -1
  77. package/dist/native/shared/crossfade.js +49 -45
  78. package/dist/native/shared/crossfade.js.map +1 -0
  79. package/dist/native/shared/dom.d.ts +7 -5
  80. package/dist/native/shared/dom.d.ts.map +1 -1
  81. package/dist/native/shared/dom.js +163 -211
  82. package/dist/native/shared/dom.js.map +1 -0
  83. package/dist/native/shared/events.d.ts +8 -6
  84. package/dist/native/shared/events.d.ts.map +1 -1
  85. package/dist/native/shared/events.js +12 -7
  86. package/dist/native/shared/events.js.map +1 -0
  87. package/dist/native/shared/icons.d.ts +4 -2
  88. package/dist/native/shared/icons.d.ts.map +1 -1
  89. package/dist/native/shared/icons.js +59 -53
  90. package/dist/native/shared/icons.js.map +1 -0
  91. package/dist/native/shared/modal.d.ts +3 -1
  92. package/dist/native/shared/modal.d.ts.map +1 -1
  93. package/dist/native/shared/modal.js +156 -139
  94. package/dist/native/shared/modal.js.map +1 -0
  95. package/dist/native/vertical-bars-web.d.ts +3 -1
  96. package/dist/native/vertical-bars-web.d.ts.map +1 -1
  97. package/dist/native/vertical-bars-web.js +332 -346
  98. package/dist/native/vertical-bars-web.js.map +1 -0
  99. package/dist/native-integration/index.d.ts +10 -8
  100. package/dist/native-integration/index.d.ts.map +1 -1
  101. package/dist/native-integration/index.js +102 -100
  102. package/dist/native-integration/index.js.map +1 -0
  103. package/dist/native-integration/transition.d.ts +3 -1
  104. package/dist/native-integration/transition.d.ts.map +1 -1
  105. package/dist/native-integration/transition.js +15 -6
  106. package/dist/native-integration/transition.js.map +1 -0
  107. package/dist/searchbar/index.d.ts +4 -2
  108. package/dist/searchbar/index.d.ts.map +1 -1
  109. package/dist/searchbar/index.js +64 -56
  110. package/dist/searchbar/index.js.map +1 -0
  111. package/dist/segment/index.d.ts +3 -1
  112. package/dist/segment/index.d.ts.map +1 -1
  113. package/dist/segment/index.js +465 -324
  114. package/dist/segment/index.js.map +1 -0
  115. package/dist/sheets-of-glass/animations.d.ts +13 -12
  116. package/dist/sheets-of-glass/animations.d.ts.map +1 -1
  117. package/dist/sheets-of-glass/animations.js +496 -306
  118. package/dist/sheets-of-glass/animations.js.map +1 -0
  119. package/dist/sheets-of-glass/index.d.ts +3 -1
  120. package/dist/sheets-of-glass/index.d.ts.map +1 -1
  121. package/dist/sheets-of-glass/index.js +294 -357
  122. package/dist/sheets-of-glass/index.js.map +1 -0
  123. package/dist/sheets-of-glass/interfaces.d.ts +11 -9
  124. package/dist/sheets-of-glass/interfaces.d.ts.map +1 -1
  125. package/dist/sheets-of-glass/interfaces.js +0 -1
  126. package/dist/tab-bar-searchable/animations/enter.d.ts +4 -2
  127. package/dist/tab-bar-searchable/animations/enter.d.ts.map +1 -1
  128. package/dist/tab-bar-searchable/animations/enter.js +50 -69
  129. package/dist/tab-bar-searchable/animations/enter.js.map +1 -0
  130. package/dist/tab-bar-searchable/animations/leave.d.ts +4 -2
  131. package/dist/tab-bar-searchable/animations/leave.d.ts.map +1 -1
  132. package/dist/tab-bar-searchable/animations/leave.js +48 -62
  133. package/dist/tab-bar-searchable/animations/leave.js.map +1 -0
  134. package/dist/tab-bar-searchable/index.d.ts +5 -3
  135. package/dist/tab-bar-searchable/index.d.ts.map +1 -1
  136. package/dist/tab-bar-searchable/index.js +125 -109
  137. package/dist/tab-bar-searchable/index.js.map +1 -0
  138. package/dist/transition/index.d.ts +9 -8
  139. package/dist/transition/index.d.ts.map +1 -1
  140. package/dist/transition/index.js +203 -192
  141. package/dist/transition/index.js.map +1 -0
  142. package/dist/transition/ios.transition.d.ts +7 -5
  143. package/dist/transition/ios.transition.d.ts.map +1 -1
  144. package/dist/transition/ios.transition.js +15 -11
  145. package/dist/transition/ios.transition.js.map +1 -0
  146. package/dist/utils.d.ts +10 -8
  147. package/dist/utils.d.ts.map +1 -1
  148. package/dist/utils.js +58 -66
  149. package/dist/utils.js.map +1 -0
  150. package/dist/vertical-bars.d.ts +5 -4
  151. package/dist/vertical-bars.js +4 -2
  152. package/docs/iphone-duo-with-original-theme.md +18 -29
  153. package/docs/iphone-duo.md +44 -204
  154. package/docs/native-ui-shell.md +15 -11
  155. package/docs/special-markup.md +2 -0
  156. package/docs/vertical-bars.md +283 -0
  157. package/ios/Sources/IonicNativeUIShellPlugin/Components/ShellSearchController.swift +1 -1
  158. package/ios/Sources/IonicNativeUIShellPlugin/Components/ShellVerticalBars.swift +61 -16
  159. package/ios/Sources/IonicNativeUIShellPlugin/Components/ShellVerticalSearch.swift +118 -0
  160. package/ios/Sources/IonicNativeUIShellPlugin/IonicNativeUIShellPlugin.swift +17 -8
  161. package/ios/Sources/IonicNativeUIShellPlugin/Shared/ShellSnapshot.swift +2 -0
  162. package/ios/Tests/IonicNativeUIShellPluginTests/ShellSnapshotTests.swift +40 -0
  163. package/package.json +9 -6
  164. package/src/native/components/index.ts +3 -2
  165. package/src/native/components/ion-button.ts +3 -2
  166. package/src/native/components/ion-buttons.ts +4 -3
  167. package/src/native/components/ion-menu-button.ts +3 -2
  168. package/src/native/components/searchable-tabs.ts +8 -11
  169. package/src/native/definitions.ts +22 -1
  170. package/src/native/foldable/fold-state.ts +9 -0
  171. package/src/native/foldable/types.ts +4 -0
  172. package/src/native/index.ts +17 -3
  173. package/src/native/prehide.ts +3 -1
  174. package/src/native/runtime.ts +14 -9
  175. package/src/native/shared/candidate.ts +39 -10
  176. package/src/native/shared/dom.ts +4 -4
  177. package/src/styles/vertical-bars.scss +12 -2
  178. package/src/tab-bar-searchable/index.ts +40 -9
  179. package/src/vertical-bars.ts +9 -1
  180. package/dist/vertical-bars.d.ts.map +0 -1
@@ -1,218 +1,242 @@
1
- import { Capacitor, registerPlugin } from '@capacitor/core';
2
- import { setConfig } from '../transition/ios.transition';
3
- import { createRuntime } from './runtime';
4
- import { createVerticalBarsWebProjection } from './vertical-bars-web';
5
- import { prehideVerticalBarsToolbarSources } from './prehide';
6
- import { observeVerticalBarsModals } from './shared/modal';
7
- const plugin = registerPlugin('IonicNativeUIShell');
8
- export const IonicNativeUIShell = plugin;
1
+ import { setConfig } from "../transition/ios.transition.js";
2
+ import { observeVerticalBarsModals } from "./shared/modal.js";
3
+ import { createRuntime } from "./runtime.js";
4
+ import { createVerticalBarsWebProjection } from "./vertical-bars-web.js";
5
+ import { prehideVerticalBarsToolbarSources } from "./prehide.js";
6
+ import { Capacitor, registerPlugin } from "@capacitor/core";
7
+ //#region src/native/index.ts
8
+ const plugin = registerPlugin("IonicNativeUIShell");
9
+ const IonicNativeUIShell = plugin;
9
10
  let active;
10
11
  let activeConfiguration;
11
12
  const web = (reason) => ({
12
- getStatus: () => ({ state: 'web', projected: 0, updates: 0, reason }),
13
- suspend: async () => ({ resume: async () => { } }),
14
- destroy: async () => { },
13
+ getStatus: () => ({
14
+ state: "web",
15
+ projected: 0,
16
+ updates: 0,
17
+ reason
18
+ }),
19
+ suspend: async () => ({ resume: async () => {} }),
20
+ destroy: async () => {}
15
21
  });
16
22
  const combine = (native, fallback) => ({
17
- getStatus() {
18
- const nativeStatus = native.getStatus();
19
- const fallbackStatus = fallback.getStatus();
20
- return {
21
- ...nativeStatus,
22
- state: nativeStatus.state === 'stopped' && fallbackStatus.state === 'stopped' ? 'stopped' : nativeStatus.projected > 0 ? 'native' : 'web',
23
- projected: nativeStatus.projected + fallbackStatus.projected,
24
- updates: nativeStatus.updates + fallbackStatus.updates,
25
- };
26
- },
27
- async suspend() {
28
- const [nativeLease, fallbackLease] = await Promise.all([native.suspend(), fallback.suspend()]);
29
- return { resume: async () => void (await Promise.all([nativeLease.resume(), fallbackLease.resume()])) };
30
- },
31
- async destroy() {
32
- await Promise.all([native.destroy(), fallback.destroy()]);
33
- },
23
+ getStatus() {
24
+ const nativeStatus = native.getStatus();
25
+ const fallbackStatus = fallback.getStatus();
26
+ return {
27
+ ...nativeStatus,
28
+ state: nativeStatus.state === "stopped" && fallbackStatus.state === "stopped" ? "stopped" : nativeStatus.projected > 0 ? "native" : "web",
29
+ projected: nativeStatus.projected + fallbackStatus.projected,
30
+ updates: nativeStatus.updates + fallbackStatus.updates
31
+ };
32
+ },
33
+ async suspend() {
34
+ const [nativeLease, fallbackLease] = await Promise.all([native.suspend(), fallback.suspend()]);
35
+ return { resume: async () => void await Promise.all([nativeLease.resume(), fallbackLease.resume()]) };
36
+ },
37
+ async destroy() {
38
+ await Promise.all([native.destroy(), fallback.destroy()]);
39
+ }
34
40
  });
41
+ /** Wraps a runtime handle with the shared enable-lifecycle: reason, suspend hooks and idempotent destroy. */
35
42
  const manage = (handle, lifecycle = {}) => {
36
- let destroyed = false;
37
- return {
38
- getStatus: () => (lifecycle.reason ? { ...handle.getStatus(), reason: lifecycle.reason } : handle.getStatus()),
39
- async suspend() {
40
- const lease = await handle.suspend();
41
- const resume = lifecycle.suspend?.();
42
- return {
43
- async resume() {
44
- await lease.resume();
45
- resume?.();
46
- },
47
- };
48
- },
49
- async destroy() {
50
- if (destroyed)
51
- return;
52
- destroyed = true;
53
- try {
54
- await handle.destroy();
55
- }
56
- finally {
57
- await lifecycle.destroy?.();
58
- lifecycle.release?.();
59
- }
60
- },
61
- };
43
+ let destroyed = false;
44
+ return {
45
+ getStatus: () => lifecycle.reason ? {
46
+ ...handle.getStatus(),
47
+ reason: lifecycle.reason
48
+ } : handle.getStatus(),
49
+ async suspend() {
50
+ const lease = await handle.suspend();
51
+ const resume = lifecycle.suspend?.();
52
+ return { async resume() {
53
+ await lease.resume();
54
+ resume?.();
55
+ } };
56
+ },
57
+ async destroy() {
58
+ if (destroyed) return;
59
+ destroyed = true;
60
+ try {
61
+ await handle.destroy();
62
+ } finally {
63
+ await lifecycle.destroy?.();
64
+ lifecycle.release?.();
65
+ }
66
+ }
67
+ };
62
68
  };
63
- export const configureNativeTransition = async () => {
64
- const metrics = typeof document !== 'undefined' && Capacitor.getPlatform() === 'ios' ? await plugin.getWebViewMetrics() : { radius: 0 };
65
- setConfig({ radius: metrics.radius });
66
- return metrics;
69
+ /** Reads the current native WebView geometry and applies it to page transitions. */
70
+ const configureNativeTransition = async () => {
71
+ const metrics = typeof document !== "undefined" && Capacitor.getPlatform() === "ios" ? await plugin.getWebViewMetrics() : { radius: 0 };
72
+ setConfig({ radius: metrics.radius });
73
+ return metrics;
67
74
  };
68
- const physicalVerticalBarEdge = (edge, rtl) => (edge === 'leading') !== rtl ? 'left' : 'right';
69
- const elementRtl = (element) => element.closest('[dir]')?.getAttribute('dir') === 'rtl';
70
- const nativePlacements = new WeakMap();
71
- const horizontalFallbackAttribute = 'data-native-ui-shell-vertical-bars-suspended';
75
+ /** Resolves a logical vertical-bar edge to the physical side for the given direction. */
76
+ const physicalVerticalBarEdge = (edge, rtl) => edge === "leading" !== rtl ? "left" : "right";
77
+ const elementRtl = (element) => element.closest("[dir]")?.getAttribute("dir") === "rtl";
78
+ const nativePlacements = /* @__PURE__ */ new WeakMap();
79
+ const horizontalFallbackAttribute = "data-native-ui-shell-vertical-bars-suspended";
72
80
  const observeNativeVerticalBarsLayout = (doc) => {
73
- const reconcile = () => {
74
- const app = doc.querySelector('ion-app');
75
- if (!app)
76
- return;
77
- const requested = app.classList.contains('ios-theme-vertical-bars') || app.hasAttribute(horizontalFallbackAttribute);
78
- const suspended = requested && nativePlacements.get(app)?.edge == null;
79
- if (app.hasAttribute(horizontalFallbackAttribute) !== suspended)
80
- app.toggleAttribute(horizontalFallbackAttribute, suspended);
81
- if (app.classList.contains('ios-theme-vertical-bars') !== (requested && !suspended)) {
82
- app.classList.toggle('ios-theme-vertical-bars', requested && !suspended);
83
- }
84
- };
85
- const observer = new MutationObserver(reconcile);
86
- observer.observe(doc.documentElement, { childList: true, subtree: true, attributes: true, attributeFilter: ['class'] });
87
- doc.defaultView?.addEventListener('nativeUIShellRefresh', reconcile);
88
- reconcile();
89
- return () => {
90
- observer.disconnect();
91
- doc.defaultView?.removeEventListener('nativeUIShellRefresh', reconcile);
92
- const app = doc.querySelector(`ion-app[${horizontalFallbackAttribute}]`);
93
- if (app) {
94
- app.removeAttribute(horizontalFallbackAttribute);
95
- app.classList.add('ios-theme-vertical-bars');
96
- }
97
- };
81
+ const reconcile = () => {
82
+ const app = doc.querySelector("ion-app");
83
+ if (!app) return;
84
+ const requested = app.classList.contains("ios-theme-vertical-bars") || app.hasAttribute(horizontalFallbackAttribute);
85
+ const suspended = requested && nativePlacements.get(app)?.edge == null;
86
+ if (app.hasAttribute(horizontalFallbackAttribute) !== suspended) app.toggleAttribute(horizontalFallbackAttribute, suspended);
87
+ if (app.classList.contains("ios-theme-vertical-bars") !== (requested && !suspended)) app.classList.toggle("ios-theme-vertical-bars", requested && !suspended);
88
+ };
89
+ const observer = new MutationObserver(reconcile);
90
+ observer.observe(doc.documentElement, {
91
+ childList: true,
92
+ subtree: true,
93
+ attributes: true,
94
+ attributeFilter: ["class"]
95
+ });
96
+ doc.defaultView?.addEventListener("nativeUIShellRefresh", reconcile);
97
+ reconcile();
98
+ return () => {
99
+ observer.disconnect();
100
+ doc.defaultView?.removeEventListener("nativeUIShellRefresh", reconcile);
101
+ const app = doc.querySelector(`ion-app[${horizontalFallbackAttribute}]`);
102
+ if (app) {
103
+ app.removeAttribute(horizontalFallbackAttribute);
104
+ app.classList.add("ios-theme-vertical-bars");
105
+ }
106
+ };
98
107
  };
99
- export const setVerticalControlAreaPlacement = (placement, rtl) => {
100
- if (typeof document === 'undefined')
101
- return;
102
- const app = document.querySelector('ion-app');
103
- if (!app)
104
- throw new Error('Vertical Control Area requires ion-app');
105
- const { edge, inset = 0 } = placement && typeof placement === 'object' ? placement : { edge: placement, inset: 0 };
106
- if (placement && typeof placement === 'object' && placement.nativeEdge !== undefined) {
107
- nativePlacements.set(app, { edge: placement.nativeEdge, rtl });
108
- }
109
- app.removeAttribute(horizontalFallbackAttribute);
110
- app.classList.toggle('ios-theme-vertical-bars', edge !== null);
111
- app.classList.toggle('ios-theme-vertical-bars-left', edge !== null && physicalVerticalBarEdge(edge, rtl ?? elementRtl(app)) === 'left');
112
- if (edge && Number.isFinite(inset) && inset > 0)
113
- app.style.setProperty('--ios-theme-vertical-bars-native-inset', `${inset}px`);
114
- else
115
- app.style.removeProperty('--ios-theme-vertical-bars-native-inset');
116
- document.defaultView?.dispatchEvent(new Event('nativeUIShellRefresh'));
108
+ /**
109
+ * Applies one placement to the CSS layout and both Web/native projections.
110
+ * Pass `rtl` when the document direction is known; otherwise the nearest `dir` attribute is used.
111
+ */
112
+ const setVerticalControlAreaPlacement = (placement, rtl) => {
113
+ if (typeof document === "undefined") return;
114
+ const app = document.querySelector("ion-app");
115
+ if (!app) throw new Error("Vertical Control Area requires ion-app");
116
+ const { edge, inset = 0 } = placement && typeof placement === "object" ? placement : {
117
+ edge: placement,
118
+ inset: 0
119
+ };
120
+ if (placement && typeof placement === "object" && placement.nativeEdge !== void 0) nativePlacements.set(app, {
121
+ edge: placement.nativeEdge,
122
+ rtl
123
+ });
124
+ app.removeAttribute(horizontalFallbackAttribute);
125
+ app.classList.toggle("ios-theme-vertical-bars", edge !== null);
126
+ app.classList.toggle("ios-theme-vertical-bars-left", edge !== null && physicalVerticalBarEdge(edge, rtl ?? elementRtl(app)) === "left");
127
+ if (edge && Number.isFinite(inset) && inset > 0) app.style.setProperty("--ios-theme-vertical-bars-native-inset", `${inset}px`);
128
+ else app.style.removeProperty("--ios-theme-vertical-bars-native-inset");
129
+ document.defaultView?.dispatchEvent(new Event("nativeUIShellRefresh"));
117
130
  };
118
- export const enableVerticalControlArea = async () => {
119
- const handle = await enableNativeUIShell({ controls: { tabs: true, toolbar: true }, verticalBarsOnly: true });
120
- return {
121
- getStatus: () => handle.getStatus(),
122
- suspend: () => handle.suspend(),
123
- destroy: () => handle.destroy(),
124
- setPlacement: setVerticalControlAreaPlacement,
125
- };
131
+ /**
132
+ * Call once after ion-app is mounted. Ionic markup remains the source of truth.
133
+ * Native vertical buttons default to SwiftUI appearance.
134
+ * See VerticalControlAreaOptions for source styling and local overrides.
135
+ */
136
+ const enableVerticalControlArea = async (options = {}) => {
137
+ const handle = await enableNativeUIShell({
138
+ buttonProjection: options.buttonProjection,
139
+ buttonDefaultFill: options.buttonDefaultFill,
140
+ controls: {
141
+ tabs: true,
142
+ toolbar: true
143
+ },
144
+ verticalBarsOnly: true
145
+ });
146
+ return {
147
+ getStatus: () => handle.getStatus(),
148
+ suspend: () => handle.suspend(),
149
+ destroy: () => handle.destroy(),
150
+ setPlacement: setVerticalControlAreaPlacement
151
+ };
126
152
  };
127
- export const enableNativeUIShell = (options = {}) => {
128
- if (options.enabled === false) {
129
- const current = active;
130
- active = undefined;
131
- activeConfiguration = undefined;
132
- return current
133
- ? current.then(async (handle) => {
134
- await handle.destroy();
135
- return web('Disabled');
136
- })
137
- : Promise.resolve(web('Disabled'));
138
- }
139
- if (typeof document === 'undefined')
140
- return Promise.resolve(web('Requires a document'));
141
- const controls = options.controls;
142
- const configuration = JSON.stringify([
143
- options.verticalBarsOnly === true,
144
- ...['tabs', 'toolbar', 'segment', 'fab'].map((component) => !controls || controls[component] === true),
145
- ]);
146
- if (active && activeConfiguration !== configuration)
147
- return Promise.reject(new Error('Native UI Shell is already running with different controls; destroy it before changing configuration.'));
148
- if (active)
149
- return active;
150
- activeConfiguration = configuration;
151
- const stopModals = observeVerticalBarsModals(document);
152
- const prehide = options.controls === undefined || options.controls.toolbar === true ? prehideVerticalBarsToolbarSources(document) : undefined;
153
- let start;
154
- const release = () => {
155
- if (active === start) {
156
- active = undefined;
157
- activeConfiguration = undefined;
158
- }
159
- };
160
- const fallback = (reason) => manage(createVerticalBarsWebProjection(document, options), {
161
- reason,
162
- suspend: () => prehide?.suspend(),
163
- destroy: () => {
164
- prehide?.stop();
165
- stopModals();
166
- },
167
- release,
168
- });
169
- return (start = active =
170
- (async () => {
171
- if (Capacitor.getPlatform() !== 'ios')
172
- return fallback('Requires Capacitor iOS');
173
- let runtime;
174
- let metricsListener;
175
- let stopVerticalBarsLayout;
176
- try {
177
- const capabilities = await plugin.configure({ verticalBarsOnly: options.verticalBarsOnly === true });
178
- if (!capabilities.supported)
179
- return fallback('Requires iOS 26 or later');
180
- if (!options.verticalBarsOnly)
181
- stopVerticalBarsLayout = observeNativeVerticalBarsLayout(document);
182
- const nativeVerticalBars = () => {
183
- const app = document.querySelector('ion-app.ios-theme-vertical-bars');
184
- if (!app)
185
- return false;
186
- const reported = nativePlacements.get(app);
187
- if (!reported?.edge)
188
- return false;
189
- const physicalEdge = app.classList.contains('ios-theme-vertical-bars-left') ? 'left' : 'right';
190
- return physicalEdge === physicalVerticalBarEdge(reported.edge, reported.rtl ?? elementRtl(app));
191
- };
192
- if (!options.verticalBarsOnly) {
193
- metricsListener = await plugin.addListener('webViewMetricsChange', (metrics) => {
194
- setConfig({ radius: metrics.radius });
195
- });
196
- await configureNativeTransition().catch(() => undefined);
197
- }
198
- const native = await createRuntime(document, plugin, options, nativeVerticalBars, options.verticalBarsOnly === true);
199
- runtime = combine(native, createVerticalBarsWebProjection(document, options, () => !nativeVerticalBars() || native.getStatus().state === 'stopped'));
200
- return manage(runtime, {
201
- suspend: () => prehide?.suspend(),
202
- release,
203
- destroy: async () => {
204
- await metricsListener?.remove().catch(() => { });
205
- stopVerticalBarsLayout?.();
206
- prehide?.stop();
207
- stopModals();
208
- },
209
- });
210
- }
211
- catch (error) {
212
- await runtime?.destroy();
213
- await metricsListener?.remove().catch(() => { });
214
- stopVerticalBarsLayout?.();
215
- return fallback(error instanceof Error ? error.message : String(error));
216
- }
217
- })());
153
+ /** Call once at application startup. Ionic markup remains the source of truth. */
154
+ const enableNativeUIShell = (options = {}) => {
155
+ if (options.enabled === false) {
156
+ const current = active;
157
+ active = void 0;
158
+ activeConfiguration = void 0;
159
+ return current ? current.then(async (handle) => {
160
+ await handle.destroy();
161
+ return web("Disabled");
162
+ }) : Promise.resolve(web("Disabled"));
163
+ }
164
+ if (typeof document === "undefined") return Promise.resolve(web("Requires a document"));
165
+ const controls = options.controls;
166
+ const configuration = JSON.stringify([
167
+ options.verticalBarsOnly === true,
168
+ options.buttonProjection ?? "system",
169
+ options.buttonDefaultFill ?? null,
170
+ ...[
171
+ "tabs",
172
+ "toolbar",
173
+ "segment",
174
+ "fab"
175
+ ].map((component) => !controls || controls[component] === true)
176
+ ]);
177
+ if (active && activeConfiguration !== configuration) return Promise.reject(/* @__PURE__ */ new Error("Native UI Shell is already running with different controls; destroy it before changing configuration."));
178
+ if (active) return active;
179
+ activeConfiguration = configuration;
180
+ const stopModals = observeVerticalBarsModals(document);
181
+ const prehide = options.controls === void 0 || options.controls.toolbar === true ? prehideVerticalBarsToolbarSources(document) : void 0;
182
+ let start;
183
+ const release = () => {
184
+ if (active === start) {
185
+ active = void 0;
186
+ activeConfiguration = void 0;
187
+ }
188
+ };
189
+ const fallback = (reason) => manage(createVerticalBarsWebProjection(document, options), {
190
+ reason,
191
+ suspend: () => prehide?.suspend(),
192
+ destroy: () => {
193
+ prehide?.stop();
194
+ stopModals();
195
+ },
196
+ release
197
+ });
198
+ return start = active = (async () => {
199
+ if (Capacitor.getPlatform() !== "ios") return fallback("Requires Capacitor iOS");
200
+ let runtime;
201
+ let metricsListener;
202
+ let stopVerticalBarsLayout;
203
+ try {
204
+ if (!(await plugin.configure({ verticalBarsOnly: options.verticalBarsOnly === true })).supported) return fallback("Requires iOS 26 or later");
205
+ if (!options.verticalBarsOnly) stopVerticalBarsLayout = observeNativeVerticalBarsLayout(document);
206
+ const nativeVerticalBars = () => {
207
+ const app = document.querySelector("ion-app.ios-theme-vertical-bars");
208
+ if (!app) return false;
209
+ const reported = nativePlacements.get(app);
210
+ if (!reported?.edge) return false;
211
+ return (app.classList.contains("ios-theme-vertical-bars-left") ? "left" : "right") === physicalVerticalBarEdge(reported.edge, reported.rtl ?? elementRtl(app));
212
+ };
213
+ if (!options.verticalBarsOnly) {
214
+ metricsListener = await plugin.addListener("webViewMetricsChange", (metrics) => {
215
+ setConfig({ radius: metrics.radius });
216
+ });
217
+ await configureNativeTransition().catch(() => void 0);
218
+ }
219
+ const native = await createRuntime(document, plugin, options, nativeVerticalBars, options.verticalBarsOnly === true);
220
+ runtime = combine(native, createVerticalBarsWebProjection(document, options, () => !nativeVerticalBars() || native.getStatus().state === "stopped"));
221
+ return manage(runtime, {
222
+ suspend: () => prehide?.suspend(),
223
+ release,
224
+ destroy: async () => {
225
+ await metricsListener?.remove().catch(() => {});
226
+ stopVerticalBarsLayout?.();
227
+ prehide?.stop();
228
+ stopModals();
229
+ }
230
+ });
231
+ } catch (error) {
232
+ await runtime?.destroy();
233
+ await metricsListener?.remove().catch(() => {});
234
+ stopVerticalBarsLayout?.();
235
+ return fallback(error instanceof Error ? error.message : String(error));
236
+ }
237
+ })();
218
238
  };
239
+ //#endregion
240
+ export { IonicNativeUIShell, configureNativeTransition, enableNativeUIShell, enableVerticalControlArea, setVerticalControlAreaPlacement };
241
+
242
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/native/index.ts"],"sourcesContent":["import { Capacitor, registerPlugin } from '@capacitor/core';\nimport { setConfig } from '../transition/ios.transition';\nimport type {\n NativeUIShellHandle,\n NativeUIShellOptions,\n NativeUIShellPlugin,\n VerticalBarEdge,\n VerticalBarPlacement,\n VerticalControlAreaHandle,\n VerticalControlAreaOptions,\n WebViewMetrics,\n} from './definitions';\nimport { createRuntime } from './runtime';\nimport { createVerticalBarsWebProjection } from './vertical-bars-web';\nimport { prehideVerticalBarsToolbarSources } from './prehide';\nimport { observeVerticalBarsModals } from './shared/modal';\nexport type {\n NativeUIShellComponent,\n NativeUIShellControls,\n NativeUIShellHandle,\n NativeUIShellOptions,\n NativeUIShellStatus,\n NativeUIShellSuspension,\n VerticalBarEdge,\n VerticalBarPlacement,\n VerticalControlAreaHandle,\n VerticalControlAreaOptions,\n WebViewMetrics,\n} from './definitions';\n\nconst plugin = registerPlugin<NativeUIShellPlugin>('IonicNativeUIShell');\nexport const IonicNativeUIShell = plugin;\nlet active: Promise<NativeUIShellHandle> | undefined;\nlet activeConfiguration: string | undefined;\nconst web = (reason: string): NativeUIShellHandle => ({\n getStatus: () => ({ state: 'web', projected: 0, updates: 0, reason }),\n suspend: async () => ({ resume: async () => {} }),\n destroy: async () => {},\n});\n\nconst combine = (native: NativeUIShellHandle, fallback: NativeUIShellHandle): NativeUIShellHandle => ({\n getStatus() {\n const nativeStatus = native.getStatus();\n const fallbackStatus = fallback.getStatus();\n return {\n ...nativeStatus,\n state:\n nativeStatus.state === 'stopped' && fallbackStatus.state === 'stopped' ? 'stopped' : nativeStatus.projected > 0 ? 'native' : 'web',\n projected: nativeStatus.projected + fallbackStatus.projected,\n updates: nativeStatus.updates + fallbackStatus.updates,\n };\n },\n async suspend() {\n const [nativeLease, fallbackLease] = await Promise.all([native.suspend(), fallback.suspend()]);\n return { resume: async () => void (await Promise.all([nativeLease.resume(), fallbackLease.resume()])) };\n },\n async destroy() {\n await Promise.all([native.destroy(), fallback.destroy()]);\n },\n});\n\n/** Wraps a runtime handle with the shared enable-lifecycle: reason, suspend hooks and idempotent destroy. */\nconst manage = (\n handle: NativeUIShellHandle,\n lifecycle: {\n reason?: string;\n suspend?: () => (() => void) | undefined;\n /** Runs after teardown; clears the shared slot only while this activation owns it. */\n release?: () => void;\n destroy?: () => void | Promise<void>;\n } = {},\n): NativeUIShellHandle => {\n let destroyed = false;\n return {\n getStatus: () => (lifecycle.reason ? { ...handle.getStatus(), reason: lifecycle.reason } : handle.getStatus()),\n async suspend() {\n const lease = await handle.suspend();\n const resume = lifecycle.suspend?.();\n return {\n async resume() {\n await lease.resume();\n resume?.();\n },\n };\n },\n async destroy() {\n if (destroyed) return;\n destroyed = true;\n try {\n await handle.destroy();\n } finally {\n await lifecycle.destroy?.();\n lifecycle.release?.();\n }\n },\n };\n};\n\n/** Reads the current native WebView geometry and applies it to page transitions. */\nexport const configureNativeTransition = async (): Promise<WebViewMetrics> => {\n const metrics = typeof document !== 'undefined' && Capacitor.getPlatform() === 'ios' ? await plugin.getWebViewMetrics() : { radius: 0 };\n setConfig({ radius: metrics.radius });\n return metrics;\n};\n\n/** Resolves a logical vertical-bar edge to the physical side for the given direction. */\nconst physicalVerticalBarEdge = (edge: Exclude<VerticalBarEdge, null>, rtl: boolean): 'left' | 'right' =>\n (edge === 'leading') !== rtl ? 'left' : 'right';\n\nconst elementRtl = (element: Element): boolean => element.closest('[dir]')?.getAttribute('dir') === 'rtl';\n\n// Device facts are supplied by the application; the theme only compares placement.\nconst nativePlacements = new WeakMap<HTMLElement, { edge: VerticalBarEdge; rtl?: boolean }>();\nconst horizontalFallbackAttribute = 'data-native-ui-shell-vertical-bars-suspended';\n\n// Keep the requested rail while ordinary Native UI Shell temporarily uses its\n// horizontal layout. Removing the effective class restores normal measurements,\n// toolbar ownership and safe areas throughout the existing rendering pipeline.\nconst observeNativeVerticalBarsLayout = (doc: Document): (() => void) => {\n const reconcile = () => {\n const app = doc.querySelector<HTMLElement>('ion-app');\n if (!app) return;\n const requested = app.classList.contains('ios-theme-vertical-bars') || app.hasAttribute(horizontalFallbackAttribute);\n const suspended = requested && nativePlacements.get(app)?.edge == null;\n if (app.hasAttribute(horizontalFallbackAttribute) !== suspended) app.toggleAttribute(horizontalFallbackAttribute, suspended);\n if (app.classList.contains('ios-theme-vertical-bars') !== (requested && !suspended)) {\n app.classList.toggle('ios-theme-vertical-bars', requested && !suspended);\n }\n };\n const observer = new MutationObserver(reconcile);\n observer.observe(doc.documentElement, { childList: true, subtree: true, attributes: true, attributeFilter: ['class'] });\n doc.defaultView?.addEventListener('nativeUIShellRefresh', reconcile);\n reconcile();\n return () => {\n observer.disconnect();\n doc.defaultView?.removeEventListener('nativeUIShellRefresh', reconcile);\n const app = doc.querySelector<HTMLElement>(`ion-app[${horizontalFallbackAttribute}]`);\n if (app) {\n app.removeAttribute(horizontalFallbackAttribute);\n app.classList.add('ios-theme-vertical-bars');\n }\n };\n};\n\n/**\n * Applies one placement to the CSS layout and both Web/native projections.\n * Pass `rtl` when the document direction is known; otherwise the nearest `dir` attribute is used.\n */\nexport const setVerticalControlAreaPlacement = (placement: VerticalBarEdge | VerticalBarPlacement, rtl?: boolean): void => {\n if (typeof document === 'undefined') return;\n const app = document.querySelector<HTMLElement>('ion-app');\n if (!app) throw new Error('Vertical Control Area requires ion-app');\n const { edge, inset = 0 } = placement && typeof placement === 'object' ? placement : { edge: placement, inset: 0 };\n if (placement && typeof placement === 'object' && placement.nativeEdge !== undefined) {\n nativePlacements.set(app, { edge: placement.nativeEdge, rtl });\n }\n app.removeAttribute(horizontalFallbackAttribute);\n app.classList.toggle('ios-theme-vertical-bars', edge !== null);\n app.classList.toggle('ios-theme-vertical-bars-left', edge !== null && physicalVerticalBarEdge(edge, rtl ?? elementRtl(app)) === 'left');\n if (edge && Number.isFinite(inset) && inset > 0) app.style.setProperty('--ios-theme-vertical-bars-native-inset', `${inset}px`);\n else app.style.removeProperty('--ios-theme-vertical-bars-native-inset');\n document.defaultView?.dispatchEvent(new Event('nativeUIShellRefresh'));\n};\n\n/**\n * Call once after ion-app is mounted. Ionic markup remains the source of truth.\n * Native vertical buttons default to SwiftUI appearance.\n * See VerticalControlAreaOptions for source styling and local overrides.\n */\nexport const enableVerticalControlArea = async (options: VerticalControlAreaOptions = {}): Promise<VerticalControlAreaHandle> => {\n const handle = await enableNativeUIShell({\n buttonProjection: options.buttonProjection,\n buttonDefaultFill: options.buttonDefaultFill,\n controls: { tabs: true, toolbar: true },\n verticalBarsOnly: true,\n });\n return {\n getStatus: () => handle.getStatus(),\n suspend: () => handle.suspend(),\n destroy: () => handle.destroy(),\n setPlacement: setVerticalControlAreaPlacement,\n };\n};\n\n/** Call once at application startup. Ionic markup remains the source of truth. */\nexport const enableNativeUIShell = (options: NativeUIShellOptions = {}): Promise<NativeUIShellHandle> => {\n if (options.enabled === false) {\n const current = active;\n active = undefined;\n activeConfiguration = undefined;\n return current\n ? current.then(async (handle) => {\n await handle.destroy();\n return web('Disabled');\n })\n : Promise.resolve(web('Disabled'));\n }\n if (typeof document === 'undefined') return Promise.resolve(web('Requires a document'));\n const controls = options.controls;\n const configuration = JSON.stringify([\n options.verticalBarsOnly === true,\n options.buttonProjection ?? 'system',\n // Local source overrides can use this even when the startup projection is system.\n options.buttonDefaultFill ?? null,\n ...(['tabs', 'toolbar', 'segment', 'fab'] as const).map((component) => !controls || controls[component] === true),\n ]);\n if (active && activeConfiguration !== configuration)\n return Promise.reject(\n new Error('Native UI Shell is already running with different controls; destroy it before changing configuration.'),\n );\n if (active) return active;\n activeConfiguration = configuration;\n const stopModals = observeVerticalBarsModals(document);\n const prehide =\n options.controls === undefined || options.controls.toolbar === true ? prehideVerticalBarsToolbarSources(document) : undefined;\n // A slow destroy of a superseded activation must not release a newer one.\n let start: Promise<NativeUIShellHandle>;\n const release = () => {\n if (active === start) {\n active = undefined;\n activeConfiguration = undefined;\n }\n };\n const fallback = (reason: string) =>\n manage(createVerticalBarsWebProjection(document, options), {\n reason,\n suspend: () => prehide?.suspend(),\n destroy: () => {\n prehide?.stop();\n stopModals();\n },\n release,\n });\n return (start = active =\n (async () => {\n if (Capacitor.getPlatform() !== 'ios') return fallback('Requires Capacitor iOS');\n let runtime: NativeUIShellHandle | undefined;\n let metricsListener: Awaited<ReturnType<typeof plugin.addListener>> | undefined;\n let stopVerticalBarsLayout: (() => void) | undefined;\n try {\n const capabilities = await plugin.configure({ verticalBarsOnly: options.verticalBarsOnly === true });\n if (!capabilities.supported) return fallback('Requires iOS 26 or later');\n if (!options.verticalBarsOnly) stopVerticalBarsLayout = observeNativeVerticalBarsLayout(document);\n // The application owns device state and selects the rail through placement classes.\n const nativeVerticalBars = () => {\n const app = document.querySelector<HTMLElement>('ion-app.ios-theme-vertical-bars');\n if (!app) return false;\n const reported = nativePlacements.get(app);\n if (!reported?.edge) return false;\n const physicalEdge = app.classList.contains('ios-theme-vertical-bars-left') ? 'left' : 'right';\n return physicalEdge === physicalVerticalBarEdge(reported.edge, reported.rtl ?? elementRtl(app));\n };\n if (!options.verticalBarsOnly) {\n metricsListener = await plugin.addListener('webViewMetricsChange', (metrics) => {\n setConfig({ radius: metrics.radius });\n });\n await configureNativeTransition().catch(() => undefined);\n }\n const native = await createRuntime(document, plugin, options, nativeVerticalBars, options.verticalBarsOnly === true);\n runtime = combine(\n native,\n createVerticalBarsWebProjection(document, options, () => !nativeVerticalBars() || native.getStatus().state === 'stopped'),\n );\n return manage(runtime, {\n suspend: () => prehide?.suspend(),\n release,\n destroy: async () => {\n await metricsListener?.remove().catch(() => {});\n stopVerticalBarsLayout?.();\n prehide?.stop();\n stopModals();\n },\n });\n } catch (error) {\n await runtime?.destroy();\n await metricsListener?.remove().catch(() => {});\n stopVerticalBarsLayout?.();\n return fallback(error instanceof Error ? error.message : String(error));\n }\n })());\n};\n"],"mappings":";;;;;;;AA8BA,MAAM,SAAS,eAAoC,oBAAoB;AACvE,MAAa,qBAAqB;AAClC,IAAI;AACJ,IAAI;AACJ,MAAM,OAAO,YAAyC;CACpD,kBAAkB;EAAE,OAAO;EAAO,WAAW;EAAG,SAAS;EAAG;CAAO;CACnE,SAAS,aAAa,EAAE,QAAQ,YAAY,CAAC,EAAE;CAC/C,SAAS,YAAY,CAAC;AACxB;AAEA,MAAM,WAAW,QAA6B,cAAwD;CACpG,YAAY;EACV,MAAM,eAAe,OAAO,UAAU;EACtC,MAAM,iBAAiB,SAAS,UAAU;EAC1C,OAAO;GACL,GAAG;GACH,OACE,aAAa,UAAU,aAAa,eAAe,UAAU,YAAY,YAAY,aAAa,YAAY,IAAI,WAAW;GAC/H,WAAW,aAAa,YAAY,eAAe;GACnD,SAAS,aAAa,UAAU,eAAe;EACjD;CACF;CACA,MAAM,UAAU;EACd,MAAM,CAAC,aAAa,iBAAiB,MAAM,QAAQ,IAAI,CAAC,OAAO,QAAQ,GAAG,SAAS,QAAQ,CAAC,CAAC;EAC7F,OAAO,EAAE,QAAQ,YAAY,KAAM,MAAM,QAAQ,IAAI,CAAC,YAAY,OAAO,GAAG,cAAc,OAAO,CAAC,CAAC,EAAG;CACxG;CACA,MAAM,UAAU;EACd,MAAM,QAAQ,IAAI,CAAC,OAAO,QAAQ,GAAG,SAAS,QAAQ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AAM,iBAAiB,OAAO,CAAC,CAAC,YAAY,CAAC,CAAC;KAC9C,yBAAyB;KACzB,SAAS,KAAK;KACd,WAAW;IACb;GACF,CAAC;EACH,SAAS,OAAO;GACd,MAAM,SAAS,QAAQ;GACvB,MAAM,iBAAiB,OAAO,CAAC,CAAC,YAAY,CAAC,CAAC;GAC9C,yBAAyB;GACzB,OAAO,SAAS,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK,CAAC;EACxE;CACF,EAAA,CAAG;AACP"}
@@ -1,5 +1,7 @@
1
+ //#region src/native/prehide.d.ts
1
2
  export declare const prehideVerticalBarsToolbarSources: (doc: Document) => {
2
- suspend: () => () => void;
3
- stop: () => void;
3
+ suspend: () => () => void;
4
+ stop: () => void;
4
5
  };
6
+ //#endregion
5
7
  //# sourceMappingURL=prehide.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"prehide.d.ts","sourceRoot":"","sources":["../../src/native/prehide.ts"],"names":[],"mappings":"AAkCA,eAAO,MAAM,iCAAiC,GAAI,KAAK,QAAQ,KAAG;IAAE,OAAO,EAAE,MAAM,MAAM,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,IAAI,CAAA;CA+N9G,CAAC"}
1
+ {"version":3,"file":"prehide.d.ts","names":[],"sources":["../../src/native/prehide.ts"],"mappings":";qBAkCa,oCAAqC,KAAK;EAAa;EAA2B"}