@burdenoff/fe-libs 2026.819.5 → 2026.823.2

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 (240) hide show
  1. package/README.md +66 -0
  2. package/dist/button/Button.d.ts +1 -1
  3. package/dist/chrome/AppShellLayout.d.ts +14 -0
  4. package/dist/chrome/AppShellLayout.d.ts.map +1 -1
  5. package/dist/chrome/AppShellLayout.js +13 -10
  6. package/dist/chrome/DynamicFooter.d.ts +6 -1
  7. package/dist/chrome/DynamicFooter.d.ts.map +1 -1
  8. package/dist/chrome/DynamicFooter.js +21 -20
  9. package/dist/chrome/Footer.d.ts +6 -0
  10. package/dist/chrome/Footer.d.ts.map +1 -1
  11. package/dist/chrome/Footer.js +46 -45
  12. package/dist/chrome/FooterBar.d.ts +6 -1
  13. package/dist/chrome/FooterBar.d.ts.map +1 -1
  14. package/dist/chrome/FooterBar.js +28 -26
  15. package/dist/chrome/HeaderBar.d.ts.map +1 -1
  16. package/dist/chrome/HeaderBar.js +3 -0
  17. package/dist/chrome/MobileTabBar.d.ts +26 -0
  18. package/dist/chrome/MobileTabBar.d.ts.map +1 -0
  19. package/dist/chrome/MobileTabBar.js +194 -0
  20. package/dist/chrome/NativePageTransition.d.ts +10 -0
  21. package/dist/chrome/NativePageTransition.d.ts.map +1 -0
  22. package/dist/chrome/NativePageTransition.js +19 -0
  23. package/dist/chrome/NativeTopBar.d.ts +21 -0
  24. package/dist/chrome/NativeTopBar.d.ts.map +1 -0
  25. package/dist/chrome/NativeTopBar.js +72 -0
  26. package/dist/chrome/NotificationCenter.d.ts.map +1 -1
  27. package/dist/chrome/NotificationCenter.js +70 -65
  28. package/dist/chrome/ProductSideNav.d.ts.map +1 -1
  29. package/dist/chrome/ProductSideNav.js +44 -74
  30. package/dist/chrome/SwipeNavigation.d.ts +36 -0
  31. package/dist/chrome/SwipeNavigation.d.ts.map +1 -0
  32. package/dist/chrome/SwipeNavigation.js +111 -0
  33. package/dist/chrome/index.d.ts +14 -7
  34. package/dist/chrome/index.d.ts.map +1 -1
  35. package/dist/chrome/mobileTabBar/selectTabs.d.ts +45 -0
  36. package/dist/chrome/mobileTabBar/selectTabs.d.ts.map +1 -0
  37. package/dist/chrome/mobileTabBar/selectTabs.js +28 -0
  38. package/dist/chrome/mobileTabBar/useMobileTabBarVisible.d.ts +18 -0
  39. package/dist/chrome/mobileTabBar/useMobileTabBarVisible.d.ts.map +1 -0
  40. package/dist/chrome/mobileTabBar/useMobileTabBarVisible.js +16 -0
  41. package/dist/chrome/mobileTabBar/useVisibleNavItems.d.ts +18 -0
  42. package/dist/chrome/mobileTabBar/useVisibleNavItems.d.ts.map +1 -0
  43. package/dist/chrome/mobileTabBar/useVisibleNavItems.js +41 -0
  44. package/dist/chrome/nativeTopBarTitle.d.ts +15 -0
  45. package/dist/chrome/nativeTopBarTitle.d.ts.map +1 -0
  46. package/dist/chrome/nativeTopBarTitle.js +22 -0
  47. package/dist/chrome/swipe/swipeMath.d.ts +25 -0
  48. package/dist/chrome/swipe/swipeMath.d.ts.map +1 -0
  49. package/dist/chrome/swipe/swipeMath.js +14 -0
  50. package/dist/chrome/swipe/swipeState.d.ts +10 -0
  51. package/dist/chrome/swipe/swipeState.d.ts.map +1 -0
  52. package/dist/chrome/swipe/swipeState.js +11 -0
  53. package/dist/chrome.js +8 -1
  54. package/dist/shared/components/DesktopUpdateToast.d.ts +9 -0
  55. package/dist/shared/components/DesktopUpdateToast.d.ts.map +1 -0
  56. package/dist/shared/components/DesktopUpdateToast.js +39 -0
  57. package/dist/shared/components/PWAInstallBanner.js +1 -1
  58. package/dist/shared/components/SSORedirectGuard.d.ts.map +1 -1
  59. package/dist/shared/components/SSORedirectGuard.js +41 -45
  60. package/dist/shared/components/index.d.ts +2 -0
  61. package/dist/shared/components/index.d.ts.map +1 -1
  62. package/dist/shared/config/authBridgeUrls.d.ts +10 -0
  63. package/dist/shared/config/authBridgeUrls.d.ts.map +1 -1
  64. package/dist/shared/config/authBridgeUrls.js +16 -12
  65. package/dist/shared/config/gatewayUrls.d.ts.map +1 -1
  66. package/dist/shared/config/gatewayUrls.js +22 -19
  67. package/dist/shared/config/index.d.ts +1 -1
  68. package/dist/shared/config/index.d.ts.map +1 -1
  69. package/dist/shared/hooks/shell/useNavRegistry.d.ts +7 -0
  70. package/dist/shared/hooks/shell/useNavRegistry.d.ts.map +1 -1
  71. package/dist/shared/hooks/usePWA.d.ts.map +1 -1
  72. package/dist/shared/hooks/usePWA.js +34 -30
  73. package/dist/shared/native/consumers.d.ts +15 -1
  74. package/dist/shared/native/consumers.d.ts.map +1 -1
  75. package/dist/shared/native/consumers.js +26 -7
  76. package/dist/shared/native/desktop.d.ts +123 -0
  77. package/dist/shared/native/desktop.d.ts.map +1 -0
  78. package/dist/shared/native/desktop.js +280 -0
  79. package/dist/shared/native/entry.d.ts +39 -0
  80. package/dist/shared/native/entry.d.ts.map +1 -0
  81. package/dist/shared/native/entry.js +13 -0
  82. package/dist/shared/native/hooks/index.d.ts +10 -0
  83. package/dist/shared/native/hooks/index.d.ts.map +1 -1
  84. package/dist/shared/native/hooks/index.js +6 -0
  85. package/dist/shared/native/hooks/useActionSheet.d.ts +63 -0
  86. package/dist/shared/native/hooks/useActionSheet.d.ts.map +1 -0
  87. package/dist/shared/native/hooks/useActionSheet.js +45 -0
  88. package/dist/shared/native/hooks/useDesktop.d.ts +15 -0
  89. package/dist/shared/native/hooks/useDesktop.d.ts.map +1 -0
  90. package/dist/shared/native/hooks/useDesktop.js +18 -0
  91. package/dist/shared/native/hooks/useDesktopUpdateState.d.ts +7 -0
  92. package/dist/shared/native/hooks/useDesktopUpdateState.d.ts.map +1 -0
  93. package/dist/shared/native/hooks/useDesktopUpdateState.js +20 -0
  94. package/dist/shared/native/hooks/useDesktopWindowState.d.ts +7 -0
  95. package/dist/shared/native/hooks/useDesktopWindowState.d.ts.map +1 -0
  96. package/dist/shared/native/hooks/useDesktopWindowState.js +9 -0
  97. package/dist/shared/native/hooks/useHaptics.d.ts +1 -0
  98. package/dist/shared/native/hooks/useHaptics.d.ts.map +1 -1
  99. package/dist/shared/native/hooks/useHaptics.js +6 -6
  100. package/dist/shared/native/hooks/useNetworkStatus.d.ts +23 -0
  101. package/dist/shared/native/hooks/useNetworkStatus.d.ts.map +1 -0
  102. package/dist/shared/native/hooks/useNetworkStatus.js +29 -0
  103. package/dist/shared/native/hooks/usePullToRefresh.d.ts +62 -0
  104. package/dist/shared/native/hooks/usePullToRefresh.d.ts.map +1 -0
  105. package/dist/shared/native/hooks/usePullToRefresh.js +84 -0
  106. package/dist/shared/native/index.d.ts +6 -1
  107. package/dist/shared/native/index.d.ts.map +1 -1
  108. package/dist/shared/native/platform.d.ts.map +1 -1
  109. package/dist/shared/native/platform.js +2 -1
  110. package/dist/shared/native/purchases.d.ts +7 -1
  111. package/dist/shared/native/purchases.d.ts.map +1 -1
  112. package/dist/shared/native/purchases.js +3 -3
  113. package/dist/shared/native/types.d.ts +136 -0
  114. package/dist/shared/native/types.d.ts.map +1 -1
  115. package/dist/shared/providers/AppShellProvider.d.ts.map +1 -1
  116. package/dist/shared/providers/AppShellProvider.js +117 -115
  117. package/dist/shared/providers/shell/ThemeProvider.d.ts.map +1 -1
  118. package/dist/shared/providers/shell/ThemeProvider.js +64 -51
  119. package/dist/shared/providers/shell/authProvider/useSsoDepositBootGuard.d.ts.map +1 -1
  120. package/dist/shared/providers/shell/authProvider/useSsoDepositBootGuard.js +25 -29
  121. package/dist/shared/utils/gatewayFetchRewrite.d.ts.map +1 -1
  122. package/dist/shared/utils/gatewayFetchRewrite.js +87 -84
  123. package/dist/shared-components.js +2 -1
  124. package/dist/shared-config.js +10 -10
  125. package/dist/shared-native.js +21 -13
  126. package/dist/shared.js +120 -111
  127. package/dist/shell-native/actionSheet.d.ts +7 -0
  128. package/dist/shell-native/actionSheet.d.ts.map +1 -0
  129. package/dist/shell-native/actionSheet.js +26 -0
  130. package/dist/shell-native/app-lifecycle.d.ts +4 -0
  131. package/dist/shell-native/app-lifecycle.d.ts.map +1 -0
  132. package/dist/shell-native/app-lifecycle.js +12 -0
  133. package/dist/shell-native/auth-navigation.d.ts +4 -0
  134. package/dist/shell-native/auth-navigation.d.ts.map +1 -0
  135. package/dist/shell-native/auth-navigation.js +95 -0
  136. package/dist/shell-native/back-button.d.ts +8 -0
  137. package/dist/shell-native/back-button.d.ts.map +1 -0
  138. package/dist/shell-native/back-button.js +49 -0
  139. package/dist/shell-native/boot.d.ts +10 -0
  140. package/dist/shell-native/boot.d.ts.map +1 -0
  141. package/dist/shell-native/boot.js +65 -0
  142. package/dist/shell-native/bridge.d.ts +7 -0
  143. package/dist/shell-native/bridge.d.ts.map +1 -0
  144. package/dist/shell-native/bridge.js +30 -0
  145. package/dist/shell-native/browser.d.ts +12 -0
  146. package/dist/shell-native/browser.d.ts.map +1 -0
  147. package/dist/shell-native/browser.js +45 -0
  148. package/dist/shell-native/capacitor-config.d.ts +21 -0
  149. package/dist/shell-native/capacitor-config.d.ts.map +1 -0
  150. package/dist/shell-native/capacitor-config.js +102 -0
  151. package/dist/shell-native/clipboard.d.ts +3 -0
  152. package/dist/shell-native/clipboard.d.ts.map +1 -0
  153. package/dist/shell-native/clipboard.js +26 -0
  154. package/dist/shell-native/deep-link.d.ts +19 -0
  155. package/dist/shell-native/deep-link.d.ts.map +1 -0
  156. package/dist/shell-native/deep-link.js +53 -0
  157. package/dist/shell-native/desktop-bridge.d.ts +14 -0
  158. package/dist/shell-native/desktop-bridge.d.ts.map +1 -0
  159. package/dist/shell-native/desktop-bridge.js +17 -0
  160. package/dist/shell-native/device.d.ts +4 -0
  161. package/dist/shell-native/device.d.ts.map +1 -0
  162. package/dist/shell-native/device.js +27 -0
  163. package/dist/shell-native/dialog.d.ts +4 -0
  164. package/dist/shell-native/dialog.d.ts.map +1 -0
  165. package/dist/shell-native/dialog.js +13 -0
  166. package/dist/shell-native/feedback.d.ts +6 -0
  167. package/dist/shell-native/feedback.d.ts.map +1 -0
  168. package/dist/shell-native/feedback.js +29 -0
  169. package/dist/shell-native/index.d.ts +54 -0
  170. package/dist/shell-native/index.d.ts.map +1 -0
  171. package/dist/shell-native/keyboard.d.ts +15 -0
  172. package/dist/shell-native/keyboard.d.ts.map +1 -0
  173. package/dist/shell-native/keyboard.js +42 -0
  174. package/dist/shell-native/network.d.ts +9 -0
  175. package/dist/shell-native/network.d.ts.map +1 -0
  176. package/dist/shell-native/network.js +40 -0
  177. package/dist/shell-native/ota.d.ts +3 -0
  178. package/dist/shell-native/ota.d.ts.map +1 -0
  179. package/dist/shell-native/ota.js +21 -0
  180. package/dist/shell-native/platform.d.ts +21 -0
  181. package/dist/shell-native/platform.d.ts.map +1 -0
  182. package/dist/shell-native/platform.js +51 -0
  183. package/dist/shell-native/preview.d.ts +18 -0
  184. package/dist/shell-native/preview.d.ts.map +1 -0
  185. package/dist/shell-native/preview.js +124 -0
  186. package/dist/shell-native/push.d.ts +14 -0
  187. package/dist/shell-native/push.d.ts.map +1 -0
  188. package/dist/shell-native/push.js +62 -0
  189. package/dist/shell-native/pwa.d.ts +14 -0
  190. package/dist/shell-native/pwa.d.ts.map +1 -0
  191. package/dist/shell-native/pwa.js +49 -0
  192. package/dist/shell-native/service-worker.d.ts +5 -0
  193. package/dist/shell-native/service-worker.d.ts.map +1 -0
  194. package/dist/shell-native/service-worker.js +144 -0
  195. package/dist/shell-native/share.d.ts +4 -0
  196. package/dist/shell-native/share.d.ts.map +1 -0
  197. package/dist/shell-native/share.js +19 -0
  198. package/dist/shell-native/splash.d.ts +16 -0
  199. package/dist/shell-native/splash.d.ts.map +1 -0
  200. package/dist/shell-native/splash.js +25 -0
  201. package/dist/shell-native/system-bars.d.ts +24 -0
  202. package/dist/shell-native/system-bars.d.ts.map +1 -0
  203. package/dist/shell-native/system-bars.js +49 -0
  204. package/dist/shell-native/toast.d.ts +4 -0
  205. package/dist/shell-native/toast.d.ts.map +1 -0
  206. package/dist/shell-native/toast.js +16 -0
  207. package/dist/shell-native/types.d.ts +292 -0
  208. package/dist/shell-native/types.d.ts.map +1 -0
  209. package/dist/shell-native/web-manifest.d.ts +36 -0
  210. package/dist/shell-native/web-manifest.d.ts.map +1 -0
  211. package/dist/shell-native/web-manifest.js +55 -0
  212. package/dist/shell-native.d.ts +2 -0
  213. package/dist/shell-native.js +29 -0
  214. package/dist/ui/action-sheet.d.ts +29 -0
  215. package/dist/ui/action-sheet.d.ts.map +1 -0
  216. package/dist/ui/action-sheet.js +53 -0
  217. package/dist/ui/badge.d.ts +1 -1
  218. package/dist/ui/button.d.ts +1 -1
  219. package/dist/ui/index.d.ts +6 -0
  220. package/dist/ui/index.d.ts.map +1 -1
  221. package/dist/ui/native-welcome.d.ts +61 -0
  222. package/dist/ui/native-welcome.d.ts.map +1 -0
  223. package/dist/ui/native-welcome.js +152 -0
  224. package/dist/ui/offline-banner.d.ts +22 -0
  225. package/dist/ui/offline-banner.d.ts.map +1 -0
  226. package/dist/ui/offline-banner.js +34 -0
  227. package/dist/ui/pull-to-refresh.d.ts +29 -0
  228. package/dist/ui/pull-to-refresh.d.ts.map +1 -0
  229. package/dist/ui/pull-to-refresh.js +44 -0
  230. package/dist/ui/pwa-update-toast.d.ts +34 -0
  231. package/dist/ui/pwa-update-toast.d.ts.map +1 -0
  232. package/dist/ui/pwa-update-toast.js +43 -0
  233. package/dist/ui/select.d.ts +38 -0
  234. package/dist/ui/select.d.ts.map +1 -1
  235. package/dist/ui/select.js +162 -61
  236. package/dist/ui.js +40 -35
  237. package/package.json +93 -4
  238. package/src/shared/styles/app-shell.css +3 -0
  239. package/src/shared/styles/native.css +577 -0
  240. package/dist/node_modules/@capacitor/core/dist/index.js +0 -268
@@ -1,92 +1,62 @@
1
- import { useNavRegistryStore as e } from "../shared/hooks/shell/useNavRegistry.js";
2
- import { hasMatchingPermission as t, useSafePermissions as n } from "../shared/providers/shell/PermissionProvider.js";
3
- import { useShellUi as r } from "../shared/providers/shell/ShellUiProvider.js";
4
- import { useSafePersonaSurface as i } from "../shared/providers/shell/PersonaSurfaceProvider.js";
5
- import { appendContextToPath as a, useCurrentContextSearchParams as o } from "../shared/hooks/useCurrentContextSearchParams.js";
6
- import { useShellLabel as s } from "../shared/providers/shell/useShellLabel.js";
7
- import { applyNavVisibility as c } from "./sideNavigation/navVisibility.js";
8
- import { SideNavigation as l } from "./SideNavigation.js";
9
- import { NavCustomizeDialog as u } from "./NavCustomizeDialog.js";
10
- import { PersonaSimulationPill as d, PersonaSurfaceControls as f } from "./PersonaSurfaceControls.js";
11
- import { useMemo as p } from "react";
12
- import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
13
- import { useLocation as _, useNavigate as v } from "react-router";
1
+ import { useShellUi as e } from "../shared/providers/shell/ShellUiProvider.js";
2
+ import { appendContextToPath as t, useCurrentContextSearchParams as n } from "../shared/hooks/useCurrentContextSearchParams.js";
3
+ import { useShellLabel as r } from "../shared/providers/shell/useShellLabel.js";
4
+ import { SideNavigation as i } from "./SideNavigation.js";
5
+ import { NavCustomizeDialog as a } from "./NavCustomizeDialog.js";
6
+ import { PersonaSimulationPill as o, PersonaSurfaceControls as s } from "./PersonaSurfaceControls.js";
7
+ import { useVisibleNavItems as c } from "./mobileTabBar/useVisibleNavItems.js";
8
+ import { Fragment as l, jsx as u, jsxs as d } from "react/jsx-runtime";
9
+ import { useLocation as f, useNavigate as p } from "react-router";
14
10
  //#region src/chrome/ProductSideNav.tsx
15
- function y({ logo: y, appName: b, groupOrder: x, groupLabels: S, mobileActions: C, customHeader: w, homeAriaLabel: T, collapseLabel: E }) {
16
- let D = s(), O = T ?? D("nav.goToDashboard", "Go to dashboard"), k = E ?? D("nav.collapse", "Collapse"), A = v(), j = _(), { sidebarCollapsed: M, toggleSidebar: N } = r(), P = o(), F = e((e) => e.items), I = n(), L = i(), R = L?.simulation ?? null, z = I?.hasPermission, B = !!I && !I.isLoading && !I.error, V = !!I && !I.isLoading && !!I.error, H = p(() => {
17
- if (R) {
18
- let e = R.permissionStrings;
19
- return (n) => t(e, n);
20
- }
21
- if (B && z) return z;
22
- if (V) return () => !1;
23
- }, [
24
- R,
25
- B,
26
- V,
27
- z
28
- ]), U = L?.activeSurface ?? null, W = L?.overrides, G = p(() => {
29
- let { items: e } = c(F.filter((e) => e.visible !== !1).sort((e, t) => (e.order ?? 999) - (t.order ?? 999)), {
30
- hasPermission: H,
31
- surfaceVisibleItems: U ? U.visibleItems : null,
32
- labelOverrides: U?.labelOverrides,
33
- overrides: R ? {} : W
34
- });
35
- return e;
36
- }, [
37
- F,
38
- H,
39
- U,
40
- W,
41
- R
42
- ]), K = (e) => {
43
- A(a(e, P));
44
- }, q = () => {
45
- A(a("/", P));
46
- }, J = /* @__PURE__ */ g("div", {
11
+ function m({ logo: m, appName: h, groupOrder: g, groupLabels: _, mobileActions: v, customHeader: y, homeAriaLabel: b, collapseLabel: x }) {
12
+ let S = r(), C = b ?? S("nav.goToDashboard", "Go to dashboard"), w = x ?? S("nav.collapse", "Collapse"), T = p(), E = f(), { sidebarCollapsed: D, toggleSidebar: O } = e(), k = n(), { items: A, persona: j } = c(), M = j?.simulation ?? null, N = j?.activeSurface ?? null, P = (e) => {
13
+ T(t(e, k));
14
+ }, F = () => {
15
+ T(t("/", k));
16
+ }, I = /* @__PURE__ */ d("div", {
47
17
  className: "flex items-center gap-icon-gap cursor-pointer",
48
- onClick: q,
18
+ onClick: F,
49
19
  role: "button",
50
20
  tabIndex: 0,
51
21
  onKeyDown: (e) => {
52
- (e.key === "Enter" || e.key === " ") && (e.preventDefault(), q());
22
+ (e.key === "Enter" || e.key === " ") && (e.preventDefault(), F());
53
23
  },
54
- "aria-label": O,
55
- children: [typeof y == "string" ? /* @__PURE__ */ h("div", {
24
+ "aria-label": C,
25
+ children: [typeof m == "string" ? /* @__PURE__ */ u("div", {
56
26
  className: "size-8 bg-action-primary-bg rounded-md flex items-center justify-center flex-shrink-0",
57
- children: /* @__PURE__ */ h("span", {
27
+ children: /* @__PURE__ */ u("span", {
58
28
  className: "text-action-primary-text font-bold text-sm",
59
- children: y
29
+ children: m
60
30
  })
61
- }) : /* @__PURE__ */ h("div", {
31
+ }) : /* @__PURE__ */ u("div", {
62
32
  className: "size-8 flex items-center justify-center flex-shrink-0",
63
- children: y
64
- }), !M && /* @__PURE__ */ h("h1", {
33
+ children: m
34
+ }), !D && /* @__PURE__ */ u("h1", {
65
35
  className: "text-heading-h4 font-semibold text-text-primary",
66
- children: b
36
+ children: h
67
37
  })]
68
38
  });
69
- return /* @__PURE__ */ g("div", {
39
+ return /* @__PURE__ */ d("div", {
70
40
  "data-tour": "sidenav",
71
41
  className: "h-full",
72
- children: [/* @__PURE__ */ h(l, {
73
- items: G,
74
- currentPath: j.pathname,
75
- collapsed: M,
76
- groupOrder: x,
77
- groupLabels: S,
78
- onItemClick: K,
79
- onToggleCollapse: N,
80
- collapseLabel: k,
81
- mobileActions: C,
82
- header: w ?? J,
83
- footer: L ? /* @__PURE__ */ h(f, {}) : void 0,
84
- contextSearchParams: P
85
- }, L ? `${U?.id ?? "everything"}:${R?.roleId ?? ""}` : void 0), L && /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h(u, {
86
- groupLabels: S,
87
- groupOrder: x
88
- }), /* @__PURE__ */ h(d, {})] })]
42
+ children: [/* @__PURE__ */ u(i, {
43
+ items: A,
44
+ currentPath: E.pathname,
45
+ collapsed: D,
46
+ groupOrder: g,
47
+ groupLabels: _,
48
+ onItemClick: P,
49
+ onToggleCollapse: O,
50
+ collapseLabel: w,
51
+ mobileActions: v,
52
+ header: y ?? I,
53
+ footer: j ? /* @__PURE__ */ u(s, {}) : void 0,
54
+ contextSearchParams: k
55
+ }, j ? `${N?.id ?? "everything"}:${M?.roleId ?? ""}` : void 0), j && /* @__PURE__ */ d(l, { children: [/* @__PURE__ */ u(a, {
56
+ groupLabels: _,
57
+ groupOrder: g
58
+ }), /* @__PURE__ */ u(o, {})] })]
89
59
  });
90
60
  }
91
61
  //#endregion
92
- export { y as ProductSideNav };
62
+ export { m as ProductSideNav };
@@ -0,0 +1,36 @@
1
+ /**
2
+ * SwipeNavigation — iOS-style edge-swipe back (and optional right-edge
3
+ * forward) for installed apps. Renders nothing; attaches document-level
4
+ * pointer listeners and drives CSS via custom properties.
5
+ *
6
+ * DOM / CSS contract (styled in shared/styles/native.css §4):
7
+ * - the swiped element is `rootSelector` (default `[data-swipe-root]`,
8
+ * falling back to `#root`)
9
+ * - during a drag it carries `data-swipe-dir="back"|"forward"` and
10
+ * `--swipe-progress` (0..1); on commit `data-swipe-committing` is added
11
+ * while the CSS transition finishes, then navigation happens
12
+ * - swipes never start inside `[role=dialog]`, open sheets,
13
+ * `[data-swipe-ignore]` / `[data-no-swipe-nav]`, editable fields, or
14
+ * horizontally scrollable containers
15
+ * - Android is back-only (the right edge belongs to the system gesture)
16
+ * - `prefers-reduced-motion`: no transform, but commit still navigates
17
+ */
18
+ export interface SwipeNavigationProps {
19
+ /**
20
+ * Enable the gesture. Default: native Capacitor app, or any installed app
21
+ * on a touch device.
22
+ */
23
+ enabled?: boolean;
24
+ /** Edge hot-zone width in px. Default 24. */
25
+ edgeWidth?: number;
26
+ /** Fraction of the viewport the finger must travel to commit. Default 0.35. */
27
+ commitRatio?: number;
28
+ /** Flick velocity (px/ms) that commits regardless of distance. Default 0.4. */
29
+ velocityThreshold?: number;
30
+ /** Allow right-edge forward swipe. Default: iOS only. */
31
+ forward?: boolean;
32
+ /** Selector for the element that translates during the drag. */
33
+ rootSelector?: string;
34
+ }
35
+ export declare function SwipeNavigation({ enabled, edgeWidth, commitRatio, velocityThreshold, forward, rootSelector, }: SwipeNavigationProps): null;
36
+ //# sourceMappingURL=SwipeNavigation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SwipeNavigation.d.ts","sourceRoot":"","sources":["../../src/chrome/SwipeNavigation.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAkBH,MAAM,WAAW,oBAAoB;IACnC;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,6CAA6C;IAC7C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,+EAA+E;IAC/E,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,+EAA+E;IAC/E,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,yDAAyD;IACzD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,gEAAgE;IAChE,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAkED,wBAAgB,eAAe,CAAC,EAC9B,OAAO,EACP,SAAc,EACd,WAAkB,EAClB,iBAAuB,EACvB,OAAO,EACP,YAAkC,GACnC,EAAE,oBAAoB,QA0JtB"}
@@ -0,0 +1,111 @@
1
+ import { isAndroid as e, isIOS as t, isInstalledApp as n, isNative as r } from "../shared/native/platform.js";
2
+ import { computeProgress as i, shouldCommit as a, shouldStartSwipe as o } from "./swipe/swipeMath.js";
3
+ import { markSwipeCommitted as s } from "./swipe/swipeState.js";
4
+ import { useEffect as c, useRef as l } from "react";
5
+ import { useLocation as u, useNavigate as d } from "react-router";
6
+ //#region src/chrome/SwipeNavigation.tsx
7
+ var f = [
8
+ "[role=dialog]",
9
+ "[data-state=open][data-slot=sheet]",
10
+ "[data-state=open][data-slot=sheet-content]",
11
+ "[data-state=open][data-slot=bottom-sheet-content]",
12
+ "[data-swipe-ignore]",
13
+ "[data-no-swipe-nav]",
14
+ "input",
15
+ "textarea",
16
+ "[contenteditable]"
17
+ ].join(",");
18
+ function p() {
19
+ return typeof window > "u" ? !1 : window.matchMedia?.("(pointer: coarse)")?.matches || navigator.maxTouchPoints > 0;
20
+ }
21
+ function m() {
22
+ return r() || n() && p();
23
+ }
24
+ function h() {
25
+ return typeof window > "u" ? !1 : window.matchMedia?.("(prefers-reduced-motion: reduce)")?.matches ?? !1;
26
+ }
27
+ function g(e) {
28
+ let t = e;
29
+ for (; t && t !== document.body && t !== document.documentElement;) {
30
+ if (t.scrollWidth > t.clientWidth) {
31
+ let e = window.getComputedStyle(t).overflowX;
32
+ if (e === "auto" || e === "scroll") return !0;
33
+ }
34
+ t = t.parentElement;
35
+ }
36
+ return !1;
37
+ }
38
+ function _() {
39
+ let e = typeof window < "u" ? window.history.state : null;
40
+ if (e && typeof e == "object" && "idx" in e) {
41
+ let t = e.idx;
42
+ return typeof t == "number" && t > 0;
43
+ }
44
+ return !0;
45
+ }
46
+ function v({ enabled: n, edgeWidth: r = 24, commitRatio: p = .35, velocityThreshold: v = .4, forward: y, rootSelector: b = "[data-swipe-root]" }) {
47
+ let x = d(), S = u(), C = l(x);
48
+ C.current = x;
49
+ let w = l(S.key);
50
+ return w.current = S.key, c(() => {
51
+ if (typeof window > "u" || !(n ?? m())) return;
52
+ let c = y ?? t(), l = e() ? !1 : c, u = null, d = !1, x = () => document.querySelector(b) ?? document.getElementById("root"), S = (e) => {
53
+ e.style.removeProperty("--swipe-progress"), e.removeAttribute("data-swipe-dir"), e.removeAttribute("data-swipe-committing");
54
+ }, w = (e) => {
55
+ if (d || u || e.pointerType !== "touch") return;
56
+ let t = o(e.clientX, window.innerWidth, r, l);
57
+ if (!t || t === "back" && !_()) return;
58
+ let n = e.target instanceof Element ? e.target : null;
59
+ if (n?.closest(f) || g(n)) return;
60
+ let i = x();
61
+ i && (u = {
62
+ dir: t,
63
+ startX: e.clientX,
64
+ lastX: e.clientX,
65
+ lastT: e.timeStamp,
66
+ velocity: 0,
67
+ root: i
68
+ }, i.setAttribute("data-swipe-dir", t), i.style.setProperty("--swipe-progress", "0"));
69
+ }, T = (e) => {
70
+ if (!u || d || e.pointerType !== "touch") return;
71
+ let t = e.timeStamp - u.lastT;
72
+ if (t > 0) {
73
+ let n = u.dir === "back" ? e.clientX - u.lastX : u.lastX - e.clientX;
74
+ u.velocity = n / t * .7 + .3 * u.velocity;
75
+ }
76
+ u.lastX = e.clientX, u.lastT = e.timeStamp;
77
+ let n = i(u.startX, e.clientX, window.innerWidth, u.dir);
78
+ h() || u.root.style.setProperty("--swipe-progress", String(n));
79
+ }, E = (e, t) => {
80
+ if (!u || e.pointerType !== "touch") return;
81
+ let { dir: n, root: r, startX: o, velocity: c } = u, l = i(o, e.clientX, window.innerWidth, n), f = !t && a(l, Math.max(0, c), p, v);
82
+ if (u = null, !f) {
83
+ r.setAttribute("data-swipe-committing", ""), r.style.setProperty("--swipe-progress", "0"), window.setTimeout(() => S(r), 220);
84
+ return;
85
+ }
86
+ d = !0;
87
+ let m = n === "back" ? -1 : 1, g = () => {
88
+ s(), C.current(m), S(r), d = !1;
89
+ };
90
+ if (h()) {
91
+ g();
92
+ return;
93
+ }
94
+ r.setAttribute("data-swipe-committing", ""), r.style.setProperty("--swipe-progress", "1"), window.setTimeout(g, 240);
95
+ }, D = (e) => E(e, !1), O = (e) => E(e, !0);
96
+ return document.addEventListener("pointerdown", w, { passive: !0 }), document.addEventListener("pointermove", T, { passive: !0 }), document.addEventListener("pointerup", D, { passive: !0 }), document.addEventListener("pointercancel", O, { passive: !0 }), () => {
97
+ document.removeEventListener("pointerdown", w), document.removeEventListener("pointermove", T), document.removeEventListener("pointerup", D), document.removeEventListener("pointercancel", O);
98
+ let e = x();
99
+ e && S(e);
100
+ };
101
+ }, [
102
+ n,
103
+ r,
104
+ p,
105
+ v,
106
+ y,
107
+ b
108
+ ]), null;
109
+ }
110
+ //#endregion
111
+ export { v as SwipeNavigation };
@@ -69,20 +69,20 @@ export { ShortcutHelpDialog } from './ShortcutHelpDialog';
69
69
  export type { AppShellLayoutProps } from './AppShellLayout';
70
70
  export type { HeaderBarProps, MobileActionItem } from './HeaderBar';
71
71
  export type { FooterBarProps, FooterItem, FooterSections } from './FooterBar';
72
- export type { FooterProps, FooterColumn, FooterLink, SocialLink } from './Footer';
72
+ export type { FooterProps, FooterColumn, FooterLink, SocialLink, } from './Footer';
73
73
  export type { SideNavigationProps, NavItem } from './SideNavigation';
74
- export type { GlobalSearchProps, SearchResult, SearchCategory } from './GlobalSearch';
75
- export type { CommandPaletteProps, CommandAction, KeyboardShortcut } from './CommandPalette';
74
+ export type { GlobalSearchProps, SearchResult, SearchCategory, } from './GlobalSearch';
75
+ export type { CommandPaletteProps, CommandAction, KeyboardShortcut, } from './CommandPalette';
76
76
  export type { BreadcrumbsProps, BreadcrumbItem } from './Breadcrumbs';
77
77
  export type { NavLinkProps } from './NavLink';
78
78
  export type { TabsProps, TabItem } from './Tabs';
79
79
  export type { SidebarProps, SidebarSection, SidebarItem } from './Sidebar';
80
- export type { ProfileSwitcherProps, Account as ProfileAccount } from './ProfileSwitcher';
80
+ export type { ProfileSwitcherProps, Account as ProfileAccount, } from './ProfileSwitcher';
81
81
  export type { ProductSwitcherProps, Product } from './ProductSwitcher';
82
82
  export type { LanguageSwitcherProps, Language } from './LanguageSwitcher';
83
83
  export type { GeographySwitcherProps } from './GeographySwitcher';
84
84
  export type { NotificationCenterProps } from './NotificationCenter';
85
- export type { ContextSwitcherProps, Organization, Workspace, Project } from './ContextSwitcher';
85
+ export type { ContextSwitcherProps, Organization, Workspace, Project, } from './ContextSwitcher';
86
86
  export type { LanguagePickerSheetProps } from './LanguagePickerSheet';
87
87
  export type { ProductPickerSheetProps } from './ProductPickerSheet';
88
88
  export type { AccountSwitcherProps, Account } from './AccountSwitcher';
@@ -90,7 +90,7 @@ export type { ShortcutHelpDialogProps } from './ShortcutHelpDialog';
90
90
  export { AutoBreadcrumbs, registerBreadcrumbName, unregisterBreadcrumbName, } from './AutoBreadcrumbs';
91
91
  export { ProductSideNav } from './ProductSideNav';
92
92
  export type { ProductSideNavProps } from './ProductSideNav';
93
- export { PersonaSurfaceControls, PersonaSimulationPill } from './PersonaSurfaceControls';
93
+ export { PersonaSurfaceControls, PersonaSimulationPill, } from './PersonaSurfaceControls';
94
94
  export type { PersonaSurfaceControlsProps } from './PersonaSurfaceControls';
95
95
  export { NavCustomizeDialog } from './NavCustomizeDialog';
96
96
  export type { NavCustomizeDialogProps } from './NavCustomizeDialog';
@@ -113,6 +113,13 @@ export type { PluginWidgetGridProps } from './PluginWidgetGrid';
113
113
  export { PluginContextMenuTarget } from './PluginContextMenuTarget';
114
114
  export type { PluginContextMenuTargetProps } from './PluginContextMenuTarget';
115
115
  export { PluginFooterStrip } from './PluginFooterStrip';
116
- export { ThemePreferences, type ThemePreferencesProps } from './ThemePreferences';
116
+ export { ThemePreferences, type ThemePreferencesProps, } from './ThemePreferences';
117
117
  export { BrandMark, type BrandMarkProps } from './BrandMark';
118
+ export { MobileTabBar, type MobileTabBarProps } from './MobileTabBar';
119
+ export { useMobileTabBarVisible } from './mobileTabBar/useMobileTabBarVisible';
120
+ export { selectMobileTabs } from './mobileTabBar/selectTabs';
121
+ export { NativeTopBar, type NativeTopBarProps } from './NativeTopBar';
122
+ export { SwipeNavigation, type SwipeNavigationProps } from './SwipeNavigation';
123
+ export { NativePageTransition, type NativePageTransitionProps, } from './NativePageTransition';
124
+ export { findNavTitle, useNativeTopBarTitle } from './nativeTopBarTitle';
118
125
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/chrome/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4CG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,YAAY,EAAE,wBAAwB,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAC9E,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,MAAM,EAAE,sBAAsB,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAChF,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,WA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rome/__tests__`.
4
+ */
5
+ /** The minimal shape the selector needs; any nav item satisfies it. */
6
+ export interface MobileTabCandidate {
7
+ id: string;
8
+ path: string;
9
+ /** Lower = more important. Items with a priority are promoted before items without. */
10
+ mobilePriority?: number;
11
+ /** Registry order (tie-breaker after priority). */
12
+ order?: number;
13
+ children?: MobileTabCandidate[];
14
+ }
15
+ export interface MobileTabSelection<T extends MobileTabCandidate> {
16
+ /** Items shown as bottom tabs, in display order. */
17
+ tabs: T[];
18
+ /** Everything else (goes into the "More" sheet), in registry order. */
19
+ more: T[];
20
+ /** Convenience: true when `more` is non-empty (a "More" tab is needed). */
21
+ hasMore: boolean;
22
+ }
23
+ /**
24
+ * Pick the bottom tabs from a list of TOP-LEVEL nav items.
25
+ *
26
+ * - Only the items passed in are considered (children are never promoted to
27
+ * tabs — callers pass the top level of the visible tree).
28
+ * - Items with `mobilePriority` come first, ascending; ties and the rest keep
29
+ * the incoming order (which the visibility pipeline has already sorted by
30
+ * `order`), with `order` as a stable tie-breaker.
31
+ * - Persona "N more…" synthetic parents (`__nav_more__:*`) are never tabs —
32
+ * they always live in the More sheet.
33
+ * - When the list does not fit, `maxTabs` slots are kept for real tabs and
34
+ * the caller renders a "More" tab in addition; when everything fits, `more`
35
+ * is empty and no More tab is needed.
36
+ */
37
+ export declare function selectMobileTabs<T extends MobileTabCandidate>(items: readonly T[], maxTabs?: number): MobileTabSelection<T>;
38
+ /**
39
+ * Path a tab navigates to: parents prefer their `homePath` (same rule as the
40
+ * collapsed sidebar), then the first child, then their own path.
41
+ */
42
+ export declare function resolveTabPath<T extends MobileTabCandidate & {
43
+ homePath?: string;
44
+ }>(item: T): string;
45
+ //# sourceMappingURL=selectTabs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"selectTabs.d.ts","sourceRoot":"","sources":["../../../src/chrome/mobileTabBar/selectTabs.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,uEAAuE;AACvE,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,uFAAuF;IACvF,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,mDAAmD;IACnD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,kBAAkB,EAAE,CAAC;CACjC;AAED,MAAM,WAAW,kBAAkB,CAAC,CAAC,SAAS,kBAAkB;IAC9D,oDAAoD;IACpD,IAAI,EAAE,CAAC,EAAE,CAAC;IACV,uEAAuE;IACvE,IAAI,EAAE,CAAC,EAAE,CAAC;IACV,2EAA2E;IAC3E,OAAO,EAAE,OAAO,CAAC;CAClB;AAKD;;;;;;;;;;;;;GAaG;AACH,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,kBAAkB,EAC3D,KAAK,EAAE,SAAS,CAAC,EAAE,EACnB,OAAO,SAAI,GACV,kBAAkB,CAAC,CAAC,CAAC,CAgCvB;AAED;;;GAGG;AACH,wBAAgB,cAAc,CAC5B,CAAC,SAAS,kBAAkB,GAAG;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAE,EACpD,IAAI,EAAE,CAAC,GAAG,MAAM,CAMjB"}
@@ -0,0 +1,28 @@
1
+ import { NAV_MORE_ID_PREFIX as e } from "../sideNavigation/navVisibility.js";
2
+ //#region src/chrome/mobileTabBar/selectTabs.ts
3
+ var t = (t) => t.id.startsWith(e);
4
+ function n(e, n = 4) {
5
+ let r = Math.max(0, Math.floor(n)), i = [], a = [];
6
+ for (let n of e) t(n) ? a.push(n) : i.push(n);
7
+ let o = i.map((e, t) => ({
8
+ item: e,
9
+ index: t
10
+ })).sort((e, t) => {
11
+ let n = e.item.mobilePriority, r = t.item.mobilePriority;
12
+ if (n !== void 0 && r !== void 0 && n !== r) return n - r;
13
+ if (n !== void 0 && r === void 0) return -1;
14
+ if (n === void 0 && r !== void 0) return 1;
15
+ let i = e.item.order ?? 999, a = t.item.order ?? 999;
16
+ return i === a ? e.index - t.index : i - a;
17
+ }).map(({ item: e }) => e), s = o.length <= r && a.length === 0 ? o : o.slice(0, r), c = new Set(s.map((e) => e.id)), l = e.filter((e) => !c.has(e.id));
18
+ return {
19
+ tabs: s,
20
+ more: l,
21
+ hasMore: l.length > 0
22
+ };
23
+ }
24
+ function r(e) {
25
+ return e.homePath ? e.homePath : e.children && e.children.length > 0 && e.children[0]?.path ? e.children[0].path : e.path;
26
+ }
27
+ //#endregion
28
+ export { r as resolveTabPath, n as selectMobileTabs };
@@ -0,0 +1,18 @@
1
+ /**
2
+ * useMobileTabBarVisible — the single rule shells use to decide whether the
3
+ * installed-app bottom tab bar replaces the desktop header/sidebar/footer.
4
+ *
5
+ * Rule: installed app (Capacitor native, standalone PWA — NOT Electron, which
6
+ * keeps desktop chrome) AND the viewport is below the `md` breakpoint.
7
+ * SSR-safe: `useMediaQuery` returns false without `window`, so the bar is
8
+ * never rendered on the server.
9
+ */
10
+ export interface TabBarVisibilityInputs {
11
+ installed: boolean;
12
+ electron: boolean;
13
+ belowMd: boolean;
14
+ }
15
+ /** Pure decision (unit-tested); the hook just feeds it live values. */
16
+ export declare function computeTabBarVisible({ installed, electron, belowMd, }: TabBarVisibilityInputs): boolean;
17
+ export declare function useMobileTabBarVisible(): boolean;
18
+ //# sourceMappingURL=useMobileTabBarVisible.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useMobileTabBarVisible.d.ts","sourceRoot":"","sources":["../../../src/chrome/mobileTabBar/useMobileTabBarVisible.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAKH,MAAM,WAAW,sBAAsB;IACrC,SAAS,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,OAAO,CAAC;IAClB,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,uEAAuE;AACvE,wBAAgB,oBAAoB,CAAC,EACnC,SAAS,EACT,QAAQ,EACR,OAAO,GACR,EAAE,sBAAsB,GAAG,OAAO,CAElC;AAED,wBAAgB,sBAAsB,IAAI,OAAO,CAShD"}
@@ -0,0 +1,16 @@
1
+ import { isElectron as e, isInstalledApp as t } from "../../shared/native/platform.js";
2
+ import { useMobileBreakpoint as n } from "../../shared/hooks/useBreakpoint.js";
3
+ //#region src/chrome/mobileTabBar/useMobileTabBarVisible.ts
4
+ function r({ installed: e, electron: t, belowMd: n }) {
5
+ return e && !t && n;
6
+ }
7
+ function i() {
8
+ let i = n(768);
9
+ return r({
10
+ installed: t(),
11
+ electron: e(),
12
+ belowMd: i
13
+ });
14
+ }
15
+ //#endregion
16
+ export { i as useMobileTabBarVisible };
@@ -0,0 +1,18 @@
1
+ import { NavItem } from '../sideNavigation/types';
2
+ import { useSafePersonaSurface } from '../../shared/providers/shell/PersonaSurfaceProvider';
3
+ /**
4
+ * A visible nav item. Structurally the sidebar NavItem plus the registry-only
5
+ * `mobilePriority` hint, which survives the visibility pipeline (items are
6
+ * spread, never rebuilt) and lets the tab bar rank without a second lookup.
7
+ */
8
+ export type VisibleNavItem = NavItem & {
9
+ mobilePriority?: number;
10
+ };
11
+ export interface VisibleNavState {
12
+ /** Shaped, ordered, visibility-filtered nav tree (top-level + children). */
13
+ items: VisibleNavItem[];
14
+ /** Persona surface state, surfaced for callers that key on it (ProductSideNav). */
15
+ persona: ReturnType<typeof useSafePersonaSurface>;
16
+ }
17
+ export declare function useVisibleNavItems(): VisibleNavState;
18
+ //# sourceMappingURL=useVisibleNavItems.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useVisibleNavItems.d.ts","sourceRoot":"","sources":["../../../src/chrome/mobileTabBar/useVisibleNavItems.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAIH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AAMvD,OAAO,EAAE,qBAAqB,EAAE,MAAM,qDAAqD,CAAC;AAE5F;;;;GAIG;AACH,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG;IAAE,cAAc,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAEnE,MAAM,WAAW,eAAe;IAC9B,4EAA4E;IAC5E,KAAK,EAAE,cAAc,EAAE,CAAC;IACxB,mFAAmF;IACnF,OAAO,EAAE,UAAU,CAAC,OAAO,qBAAqB,CAAC,CAAC;CACnD;AAED,wBAAgB,kBAAkB,IAAI,eAAe,CAmDpD"}
@@ -0,0 +1,41 @@
1
+ import { useNavRegistryStore as e } from "../../shared/hooks/shell/useNavRegistry.js";
2
+ import { hasMatchingPermission as t, useSafePermissions as n } from "../../shared/providers/shell/PermissionProvider.js";
3
+ import { useSafePersonaSurface as r } from "../../shared/providers/shell/PersonaSurfaceProvider.js";
4
+ import { applyNavVisibility as i } from "../sideNavigation/navVisibility.js";
5
+ import { useMemo as a } from "react";
6
+ //#region src/chrome/mobileTabBar/useVisibleNavItems.ts
7
+ function o() {
8
+ let o = e((e) => e.items), s = n(), c = r(), l = c?.simulation ?? null, u = s?.hasPermission, d = !!s && !s.isLoading && !s.error, f = !!s && !s.isLoading && !!s.error, p = a(() => {
9
+ if (l) {
10
+ let e = l.permissionStrings;
11
+ return (n) => t(e, n);
12
+ }
13
+ if (d && u) return u;
14
+ if (f) return () => !1;
15
+ }, [
16
+ l,
17
+ d,
18
+ f,
19
+ u
20
+ ]), m = c?.activeSurface ?? null, h = c?.overrides;
21
+ return {
22
+ items: a(() => {
23
+ let { items: e } = i(o.filter((e) => e.visible !== !1).sort((e, t) => (e.order ?? 999) - (t.order ?? 999)), {
24
+ hasPermission: p,
25
+ surfaceVisibleItems: m ? m.visibleItems : null,
26
+ labelOverrides: m?.labelOverrides,
27
+ overrides: l ? {} : h
28
+ });
29
+ return e;
30
+ }, [
31
+ o,
32
+ p,
33
+ m,
34
+ h,
35
+ l
36
+ ]),
37
+ persona: c
38
+ };
39
+ }
40
+ //#endregion
41
+ export { o as useVisibleNavItems };
@@ -0,0 +1,15 @@
1
+ import { NavItem } from '../shared/hooks/shell/useNavRegistry';
2
+ /**
3
+ * Deepest registered nav item whose path prefixes the current route — the label
4
+ * the installed-app top bar shows. Matching is segment-aware, so `/workflows`
5
+ * never claims `/workflows-archive`, and `exact` items (typically the product
6
+ * overview) only match their own path. Returns `null` when nothing matches
7
+ * (root, auth and plugin routes); callers fall back to the product name.
8
+ */
9
+ export declare function findNavTitle(items: readonly NavItem[], pathname: string): string | null;
10
+ /**
11
+ * Route-tracking title for `NativeTopBar`. Pass the product name as the
12
+ * fallback for routes the nav registry does not describe.
13
+ */
14
+ export declare function useNativeTopBarTitle(pathname: string, fallback: string): string;
15
+ //# sourceMappingURL=nativeTopBarTitle.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nativeTopBarTitle.d.ts","sourceRoot":"","sources":["../../src/chrome/nativeTopBarTitle.ts"],"names":[],"mappings":"AAaA,OAAO,EAEL,KAAK,OAAO,EACb,MAAM,sCAAsC,CAAC;AAE9C;;;;;;GAMG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,SAAS,OAAO,EAAE,EACzB,QAAQ,EAAE,MAAM,GACf,MAAM,GAAG,IAAI,CAsBf;AAED;;;GAGG;AACH,wBAAgB,oBAAoB,CAClC,QAAQ,EAAE,MAAM,EAChB,QAAQ,EAAE,MAAM,GACf,MAAM,CAMR"}
@@ -0,0 +1,22 @@
1
+ import { useNavRegistryStore as e } from "../shared/hooks/shell/useNavRegistry.js";
2
+ import { useMemo as t } from "react";
3
+ //#region src/chrome/nativeTopBarTitle.ts
4
+ function n(e, t) {
5
+ let n = null, r = -1, i = (e) => {
6
+ for (let a of e) {
7
+ let e = a.path;
8
+ (e === t || a.exact !== !0 && e !== "/" && t.startsWith(`${e}/`)) && e.length > r && (n = a.label, r = e.length), a.children?.length && i(a.children);
9
+ }
10
+ };
11
+ return i(e), n;
12
+ }
13
+ function r(r, i) {
14
+ let a = e((e) => e.items);
15
+ return t(() => n(a, r) ?? i, [
16
+ a,
17
+ r,
18
+ i
19
+ ]);
20
+ }
21
+ //#endregion
22
+ export { n as findNavTitle, r as useNativeTopBarTitle };
@@ -0,0 +1,25 @@
1
+ /**
2
+ * Pure math for edge-swipe navigation. No DOM, no React — unit-tested in
3
+ * `src/chrome/__tests__/swipeMath.test.ts`.
4
+ */
5
+ export type SwipeDirection = "back" | "forward";
6
+ /**
7
+ * Decide whether a touch at `x` starts an edge swipe, and in which direction.
8
+ * `back` = left edge, `forward` = right edge (iOS only — pass
9
+ * `allowForward: false` on Android, whose right edge belongs to the system
10
+ * back gesture).
11
+ */
12
+ export declare function shouldStartSwipe(x: number, innerWidth: number, edgeWidth: number, allowForward: boolean): SwipeDirection | null;
13
+ /**
14
+ * Drag progress 0..1. `back` grows as the finger moves right from the left
15
+ * edge; `forward` grows as it moves left from the right edge. Clamped; motion
16
+ * against the gesture direction is 0.
17
+ */
18
+ export declare function computeProgress(startX: number, x: number, innerWidth: number, dir: SwipeDirection): number;
19
+ /**
20
+ * Commit the navigation when the finger travelled far enough (`ratio` of the
21
+ * viewport) OR was flicked fast enough (`velocity` in px/ms along the gesture
22
+ * direction).
23
+ */
24
+ export declare function shouldCommit(progress: number, velocity: number, ratio: number, velocityThreshold: number): boolean;
25
+ //# sourceMappingURL=swipeMath.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"swipeMath.d.ts","sourceRoot":"","sources":["../../../src/chrome/swipe/swipeMath.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,SAAS,CAAC;AAEhD;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAC9B,CAAC,EAAE,MAAM,EACT,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,OAAO,GACpB,cAAc,GAAG,IAAI,CAKvB;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAC7B,MAAM,EAAE,MAAM,EACd,CAAC,EAAE,MAAM,EACT,UAAU,EAAE,MAAM,EAClB,GAAG,EAAE,cAAc,GAClB,MAAM,CAIR;AAED;;;;GAIG;AACH,wBAAgB,YAAY,CAC1B,QAAQ,EAAE,MAAM,EAChB,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,MAAM,EACb,iBAAiB,EAAE,MAAM,GACxB,OAAO,CAET"}
@@ -0,0 +1,14 @@
1
+ //#region src/chrome/swipe/swipeMath.ts
2
+ function e(e, t, n, r) {
3
+ return t <= 0 || n <= 0 ? null : e <= n ? "back" : r && e >= t - n ? "forward" : null;
4
+ }
5
+ function t(e, t, n, r) {
6
+ if (n <= 0) return 0;
7
+ let i = r === "back" ? t - e : e - t;
8
+ return Math.min(1, Math.max(0, i / n));
9
+ }
10
+ function n(e, t, n, r) {
11
+ return e >= n || t >= r;
12
+ }
13
+ //#endregion
14
+ export { t as computeProgress, n as shouldCommit, e as shouldStartSwipe };