@rdlabo/ionic-theme-ios27 1.2.0-beta.pr231.sha22a35d481cf3 → 1.2.0-beta.pr237.sha90661d2c01a8

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 (166) hide show
  1. package/README.md +21 -0
  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 +6 -1
  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 +116 -122
  50. package/dist/native/definitions.d.ts.map +1 -1
  51. package/dist/native/definitions.js +0 -6
  52. package/dist/native/index.d.ts +6 -4
  53. package/dist/native/index.d.ts.map +1 -1
  54. package/dist/native/index.js +229 -176
  55. package/dist/native/index.js.map +1 -0
  56. package/dist/native/prehide.d.ts +4 -2
  57. package/dist/native/prehide.d.ts.map +1 -1
  58. package/dist/native/prehide.js +218 -242
  59. package/dist/native/prehide.js.map +1 -0
  60. package/dist/native/runtime.d.ts +3 -1
  61. package/dist/native/runtime.d.ts.map +1 -1
  62. package/dist/native/runtime.js +626 -722
  63. package/dist/native/runtime.js.map +1 -0
  64. package/dist/native/shared/candidate.d.ts +15 -11
  65. package/dist/native/shared/candidate.d.ts.map +1 -1
  66. package/dist/native/shared/candidate.js +88 -95
  67. package/dist/native/shared/candidate.js.map +1 -0
  68. package/dist/native/shared/crossfade.d.ts +6 -4
  69. package/dist/native/shared/crossfade.d.ts.map +1 -1
  70. package/dist/native/shared/crossfade.js +49 -45
  71. package/dist/native/shared/crossfade.js.map +1 -0
  72. package/dist/native/shared/dom.d.ts +6 -4
  73. package/dist/native/shared/dom.d.ts.map +1 -1
  74. package/dist/native/shared/dom.js +163 -211
  75. package/dist/native/shared/dom.js.map +1 -0
  76. package/dist/native/shared/events.d.ts +8 -6
  77. package/dist/native/shared/events.d.ts.map +1 -1
  78. package/dist/native/shared/events.js +12 -7
  79. package/dist/native/shared/events.js.map +1 -0
  80. package/dist/native/shared/icons.d.ts +4 -2
  81. package/dist/native/shared/icons.d.ts.map +1 -1
  82. package/dist/native/shared/icons.js +59 -53
  83. package/dist/native/shared/icons.js.map +1 -0
  84. package/dist/native/shared/modal.d.ts +3 -1
  85. package/dist/native/shared/modal.d.ts.map +1 -1
  86. package/dist/native/shared/modal.js +156 -139
  87. package/dist/native/shared/modal.js.map +1 -0
  88. package/dist/native/vertical-bars-web.d.ts +3 -1
  89. package/dist/native/vertical-bars-web.d.ts.map +1 -1
  90. package/dist/native/vertical-bars-web.js +332 -344
  91. package/dist/native/vertical-bars-web.js.map +1 -0
  92. package/dist/native-integration/index.d.ts +10 -8
  93. package/dist/native-integration/index.d.ts.map +1 -1
  94. package/dist/native-integration/index.js +102 -100
  95. package/dist/native-integration/index.js.map +1 -0
  96. package/dist/native-integration/transition.d.ts +3 -1
  97. package/dist/native-integration/transition.d.ts.map +1 -1
  98. package/dist/native-integration/transition.js +15 -6
  99. package/dist/native-integration/transition.js.map +1 -0
  100. package/dist/searchbar/index.d.ts +4 -2
  101. package/dist/searchbar/index.d.ts.map +1 -1
  102. package/dist/searchbar/index.js +64 -56
  103. package/dist/searchbar/index.js.map +1 -0
  104. package/dist/segment/index.d.ts +3 -1
  105. package/dist/segment/index.d.ts.map +1 -1
  106. package/dist/segment/index.js +465 -324
  107. package/dist/segment/index.js.map +1 -0
  108. package/dist/sheets-of-glass/animations.d.ts +13 -12
  109. package/dist/sheets-of-glass/animations.d.ts.map +1 -1
  110. package/dist/sheets-of-glass/animations.js +496 -306
  111. package/dist/sheets-of-glass/animations.js.map +1 -0
  112. package/dist/sheets-of-glass/index.d.ts +3 -1
  113. package/dist/sheets-of-glass/index.d.ts.map +1 -1
  114. package/dist/sheets-of-glass/index.js +294 -357
  115. package/dist/sheets-of-glass/index.js.map +1 -0
  116. package/dist/sheets-of-glass/interfaces.d.ts +11 -9
  117. package/dist/sheets-of-glass/interfaces.d.ts.map +1 -1
  118. package/dist/sheets-of-glass/interfaces.js +0 -1
  119. package/dist/tab-bar-searchable/animations/enter.d.ts +4 -2
  120. package/dist/tab-bar-searchable/animations/enter.d.ts.map +1 -1
  121. package/dist/tab-bar-searchable/animations/enter.js +50 -69
  122. package/dist/tab-bar-searchable/animations/enter.js.map +1 -0
  123. package/dist/tab-bar-searchable/animations/leave.d.ts +4 -2
  124. package/dist/tab-bar-searchable/animations/leave.d.ts.map +1 -1
  125. package/dist/tab-bar-searchable/animations/leave.js +48 -62
  126. package/dist/tab-bar-searchable/animations/leave.js.map +1 -0
  127. package/dist/tab-bar-searchable/index.d.ts +5 -3
  128. package/dist/tab-bar-searchable/index.d.ts.map +1 -1
  129. package/dist/tab-bar-searchable/index.js +125 -109
  130. package/dist/tab-bar-searchable/index.js.map +1 -0
  131. package/dist/transition/index.d.ts +9 -8
  132. package/dist/transition/index.d.ts.map +1 -1
  133. package/dist/transition/index.js +203 -192
  134. package/dist/transition/index.js.map +1 -0
  135. package/dist/transition/ios.transition.d.ts +7 -5
  136. package/dist/transition/ios.transition.d.ts.map +1 -1
  137. package/dist/transition/ios.transition.js +15 -11
  138. package/dist/transition/ios.transition.js.map +1 -0
  139. package/dist/utils.d.ts +10 -8
  140. package/dist/utils.d.ts.map +1 -1
  141. package/dist/utils.js +58 -66
  142. package/dist/utils.js.map +1 -0
  143. package/dist/vertical-bars.d.ts +4 -5
  144. package/dist/vertical-bars.js +3 -3
  145. package/docs/iphone-duo-with-original-theme.md +24 -8
  146. package/docs/iphone-duo.md +59 -44
  147. package/docs/native-ui-shell.md +5 -3
  148. package/ios/Sources/IonicNativeUIShellPlugin/Components/ShellSearchController.swift +1 -1
  149. package/ios/Sources/IonicNativeUIShellPlugin/Components/ShellVerticalBars.swift +27 -2
  150. package/ios/Sources/IonicNativeUIShellPlugin/Components/ShellVerticalSearch.swift +118 -0
  151. package/ios/Sources/IonicNativeUIShellPlugin/IonicNativeUIShellPlugin.swift +27 -179
  152. package/ios/Tests/IonicNativeUIShellPluginTests/ShellSnapshotTests.swift +37 -0
  153. package/package.json +8 -5
  154. package/src/native/components/index.ts +3 -2
  155. package/src/native/components/ion-button.ts +3 -2
  156. package/src/native/components/ion-buttons.ts +3 -2
  157. package/src/native/components/searchable-tabs.ts +8 -11
  158. package/src/native/definitions.ts +16 -20
  159. package/src/native/index.ts +75 -32
  160. package/src/native/runtime.ts +18 -12
  161. package/src/native/shared/candidate.ts +13 -6
  162. package/src/native/vertical-bars-web.ts +2 -0
  163. package/src/styles/vertical-bars.scss +8 -0
  164. package/src/tab-bar-searchable/index.ts +40 -9
  165. package/src/vertical-bars.ts +7 -2
  166. package/dist/vertical-bars.d.ts.map +0 -1
@@ -1,188 +1,241 @@
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
- export { HingeStatus } from './definitions';
8
- const plugin = registerPlugin('IonicNativeUIShell');
9
- 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;
10
10
  let active;
11
11
  let activeConfiguration;
12
12
  const web = (reason) => ({
13
- getStatus: () => ({ state: 'web', projected: 0, updates: 0, reason }),
14
- suspend: async () => ({ resume: async () => { } }),
15
- destroy: async () => { },
13
+ getStatus: () => ({
14
+ state: "web",
15
+ projected: 0,
16
+ updates: 0,
17
+ reason
18
+ }),
19
+ suspend: async () => ({ resume: async () => {} }),
20
+ destroy: async () => {}
16
21
  });
17
22
  const combine = (native, fallback) => ({
18
- getStatus() {
19
- const nativeStatus = native.getStatus();
20
- const fallbackStatus = fallback.getStatus();
21
- return {
22
- ...nativeStatus,
23
- state: nativeStatus.state === 'stopped' && fallbackStatus.state === 'stopped' ? 'stopped' : nativeStatus.projected > 0 ? 'native' : 'web',
24
- projected: nativeStatus.projected + fallbackStatus.projected,
25
- updates: nativeStatus.updates + fallbackStatus.updates,
26
- };
27
- },
28
- async suspend() {
29
- const [nativeLease, fallbackLease] = await Promise.all([native.suspend(), fallback.suspend()]);
30
- return { resume: async () => void (await Promise.all([nativeLease.resume(), fallbackLease.resume()])) };
31
- },
32
- async destroy() {
33
- await Promise.all([native.destroy(), fallback.destroy()]);
34
- },
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
+ }
35
40
  });
41
+ /** Wraps a runtime handle with the shared enable-lifecycle: reason, suspend hooks and idempotent destroy. */
36
42
  const manage = (handle, lifecycle = {}) => {
37
- let destroyed = false;
38
- return {
39
- getStatus: () => (lifecycle.reason ? { ...handle.getStatus(), reason: lifecycle.reason } : handle.getStatus()),
40
- async suspend() {
41
- const lease = await handle.suspend();
42
- const resume = lifecycle.suspend?.();
43
- return {
44
- async resume() {
45
- await lease.resume();
46
- resume?.();
47
- },
48
- };
49
- },
50
- async destroy() {
51
- if (destroyed)
52
- return;
53
- destroyed = true;
54
- try {
55
- await handle.destroy();
56
- }
57
- finally {
58
- await lifecycle.destroy?.();
59
- lifecycle.release?.();
60
- }
61
- },
62
- };
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
+ };
63
68
  };
64
- export const configureNativeTransition = async () => {
65
- const metrics = typeof document !== 'undefined' && Capacitor.getPlatform() === 'ios' ? (await plugin.getDeviceLayout()).webViewMetrics : { radius: 0 };
66
- setConfig({ radius: metrics.radius });
67
- 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;
68
74
  };
69
- const physicalVerticalBarEdge = (edge, rtl) => (edge === 'leading') !== rtl ? 'left' : 'right';
70
- const elementRtl = (element) => element.closest('[dir]')?.getAttribute('dir') === 'rtl';
71
- export const setVerticalControlAreaPlacement = (placement, rtl) => {
72
- if (typeof document === 'undefined')
73
- return;
74
- const app = document.querySelector('ion-app');
75
- if (!app)
76
- throw new Error('Vertical Control Area requires ion-app');
77
- const { edge, inset } = placement && typeof placement === 'object' ? placement : { edge: placement, inset: 0 };
78
- app.classList.toggle('ios-theme-vertical-bars', edge !== null);
79
- app.classList.toggle('ios-theme-vertical-bars-left', edge !== null && physicalVerticalBarEdge(edge, rtl ?? elementRtl(app)) === 'left');
80
- if (edge && Number.isFinite(inset) && inset > 0)
81
- app.style.setProperty('--ios-theme-vertical-bars-native-inset', `${inset}px`);
82
- else
83
- app.style.removeProperty('--ios-theme-vertical-bars-native-inset');
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";
80
+ const observeNativeVerticalBarsLayout = (doc) => {
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
+ };
84
107
  };
85
- export const enableVerticalControlArea = async () => {
86
- const handle = await enableNativeUIShell({ controls: { tabs: true, toolbar: true }, verticalBarsOnly: true });
87
- return {
88
- getStatus: () => handle.getStatus(),
89
- suspend: () => handle.suspend(),
90
- destroy: () => handle.destroy(),
91
- setPlacement: setVerticalControlAreaPlacement,
92
- };
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"));
93
130
  };
94
- export const enableNativeUIShell = (options = {}) => {
95
- if (options.enabled === false) {
96
- const current = active;
97
- active = undefined;
98
- activeConfiguration = undefined;
99
- return current
100
- ? current.then(async (handle) => {
101
- await handle.destroy();
102
- return web('Disabled');
103
- })
104
- : Promise.resolve(web('Disabled'));
105
- }
106
- if (typeof document === 'undefined')
107
- return Promise.resolve(web('Requires a document'));
108
- const controls = options.controls;
109
- const configuration = JSON.stringify([
110
- options.verticalBarsOnly === true,
111
- ...['tabs', 'toolbar', 'segment', 'fab'].map((component) => !controls || controls[component] === true),
112
- ]);
113
- if (active && activeConfiguration !== configuration)
114
- return Promise.reject(new Error('Native UI Shell is already running with different controls; destroy it before changing configuration.'));
115
- if (active)
116
- return active;
117
- activeConfiguration = configuration;
118
- const stopModals = observeVerticalBarsModals(document);
119
- const prehide = options.controls === undefined || options.controls.toolbar === true ? prehideVerticalBarsToolbarSources(document) : undefined;
120
- let start;
121
- const release = () => {
122
- if (active === start) {
123
- active = undefined;
124
- activeConfiguration = undefined;
125
- }
126
- };
127
- const fallback = (reason) => manage(createVerticalBarsWebProjection(document, options), {
128
- reason,
129
- suspend: () => prehide?.suspend(),
130
- destroy: () => {
131
- prehide?.stop();
132
- stopModals();
133
- },
134
- release,
135
- });
136
- return (start = active =
137
- (async () => {
138
- if (Capacitor.getPlatform() !== 'ios')
139
- return fallback('Requires Capacitor iOS');
140
- let runtime;
141
- let placementListener;
142
- let monitoring = false;
143
- try {
144
- if (!options.verticalBarsOnly)
145
- await configureNativeTransition().catch(() => undefined);
146
- const capabilities = await plugin.configure({ verticalBarsOnly: options.verticalBarsOnly === true });
147
- if (!capabilities.supported)
148
- return fallback('Requires iOS 26 or later');
149
- let nativeEdge = null;
150
- const nativeVerticalBars = () => {
151
- const root = document.querySelector('ion-app.ios-theme-vertical-bars');
152
- if (!root)
153
- return false;
154
- const domEdge = root.classList.contains('ios-theme-vertical-bars-left') ? 'left' : 'right';
155
- return nativeEdge === null || physicalVerticalBarEdge(nativeEdge, elementRtl(root)) === domEdge;
156
- };
157
- await plugin.startDeviceLayoutMonitoring();
158
- monitoring = true;
159
- placementListener = await plugin.addListener('deviceLayoutChange', ({ placement, webViewMetrics }) => {
160
- nativeEdge = placement.edge;
161
- if (!options.verticalBarsOnly)
162
- setConfig({ radius: webViewMetrics.radius });
163
- document.defaultView?.dispatchEvent(new Event('nativeUIShellRefresh'));
164
- });
165
- nativeEdge = (await plugin.getDeviceLayout()).placement.edge;
166
- const native = await createRuntime(document, plugin, options, nativeVerticalBars, options.verticalBarsOnly === true);
167
- runtime = combine(native, createVerticalBarsWebProjection(document, options, () => !nativeVerticalBars() || native.getStatus().state === 'stopped'));
168
- return manage(runtime, {
169
- suspend: () => prehide?.suspend(),
170
- release,
171
- destroy: async () => {
172
- await placementListener?.remove().catch(() => { });
173
- if (monitoring)
174
- await plugin.stopDeviceLayoutMonitoring().catch(() => { });
175
- prehide?.stop();
176
- stopModals();
177
- },
178
- });
179
- }
180
- catch (error) {
181
- await runtime?.destroy();
182
- await placementListener?.remove().catch(() => { });
183
- if (monitoring)
184
- await plugin.stopDeviceLayoutMonitoring().catch(() => { });
185
- return fallback(error instanceof Error ? error.message : String(error));
186
- }
187
- })());
131
+ /**
132
+ * Call once after ion-app is mounted. Ionic markup remains the source of truth.
133
+ * Set buttonDefaultFill to `solid` for Ionic's default design, or `null` for this
134
+ * theme's glass design. Omitting it is equivalent to `null` (existing behavior).
135
+ * This default affects native vertical projection only; explicit button fills win.
136
+ */
137
+ const enableVerticalControlArea = async (options = {}) => {
138
+ const handle = await enableNativeUIShell({
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
+ };
188
152
  };
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.buttonDefaultFill ?? null,
169
+ ...[
170
+ "tabs",
171
+ "toolbar",
172
+ "segment",
173
+ "fab"
174
+ ].map((component) => !controls || controls[component] === true)
175
+ ]);
176
+ if (active && activeConfiguration !== configuration) return Promise.reject(/* @__PURE__ */ new Error("Native UI Shell is already running with different controls; destroy it before changing configuration."));
177
+ if (active) return active;
178
+ activeConfiguration = configuration;
179
+ const stopModals = observeVerticalBarsModals(document);
180
+ const prehide = options.controls === void 0 || options.controls.toolbar === true ? prehideVerticalBarsToolbarSources(document) : void 0;
181
+ let start;
182
+ const release = () => {
183
+ if (active === start) {
184
+ active = void 0;
185
+ activeConfiguration = void 0;
186
+ }
187
+ };
188
+ const fallback = (reason) => manage(createVerticalBarsWebProjection(document, options), {
189
+ reason,
190
+ suspend: () => prehide?.suspend(),
191
+ destroy: () => {
192
+ prehide?.stop();
193
+ stopModals();
194
+ },
195
+ release
196
+ });
197
+ return start = active = (async () => {
198
+ if (Capacitor.getPlatform() !== "ios") return fallback("Requires Capacitor iOS");
199
+ let runtime;
200
+ let metricsListener;
201
+ let stopVerticalBarsLayout;
202
+ try {
203
+ if (!(await plugin.configure({ verticalBarsOnly: options.verticalBarsOnly === true })).supported) return fallback("Requires iOS 26 or later");
204
+ if (!options.verticalBarsOnly) stopVerticalBarsLayout = observeNativeVerticalBarsLayout(document);
205
+ const nativeVerticalBars = () => {
206
+ const app = document.querySelector("ion-app.ios-theme-vertical-bars");
207
+ if (!app) return false;
208
+ const reported = nativePlacements.get(app);
209
+ if (!reported?.edge) return false;
210
+ return (app.classList.contains("ios-theme-vertical-bars-left") ? "left" : "right") === physicalVerticalBarEdge(reported.edge, reported.rtl ?? elementRtl(app));
211
+ };
212
+ if (!options.verticalBarsOnly) {
213
+ metricsListener = await plugin.addListener("webViewMetricsChange", (metrics) => {
214
+ setConfig({ radius: metrics.radius });
215
+ });
216
+ await configureNativeTransition().catch(() => void 0);
217
+ }
218
+ const native = await createRuntime(document, plugin, options, nativeVerticalBars, options.verticalBarsOnly === true);
219
+ runtime = combine(native, createVerticalBarsWebProjection(document, options, () => !nativeVerticalBars() || native.getStatus().state === "stopped"));
220
+ return manage(runtime, {
221
+ suspend: () => prehide?.suspend(),
222
+ release,
223
+ destroy: async () => {
224
+ await metricsListener?.remove().catch(() => {});
225
+ stopVerticalBarsLayout?.();
226
+ prehide?.stop();
227
+ stopModals();
228
+ }
229
+ });
230
+ } catch (error) {
231
+ await runtime?.destroy();
232
+ await metricsListener?.remove().catch(() => {});
233
+ stopVerticalBarsLayout?.();
234
+ return fallback(error instanceof Error ? error.message : String(error));
235
+ }
236
+ })();
237
+ };
238
+ //#endregion
239
+ export { IonicNativeUIShell, configureNativeTransition, enableNativeUIShell, enableVerticalControlArea, setVerticalControlAreaPlacement };
240
+
241
+ //# 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 * Set buttonDefaultFill to `solid` for Ionic's default design, or `null` for this\n * theme's glass design. Omitting it is equivalent to `null` (existing behavior).\n * This default affects native vertical projection only; explicit button fills win.\n */\nexport const enableVerticalControlArea = async (options: VerticalControlAreaOptions = {}): Promise<VerticalControlAreaHandle> => {\n const handle = await enableNativeUIShell({\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.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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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"}