expo-router 7.0.0-canary-20260121-a63c0dd → 55.0.0-beta.1

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 (132) hide show
  1. package/android/build.gradle +2 -2
  2. package/build/Route.d.ts +1 -1
  3. package/build/Route.d.ts.map +1 -1
  4. package/build/Route.js.map +1 -1
  5. package/build/exports.d.ts +5 -2
  6. package/build/exports.d.ts.map +1 -1
  7. package/build/exports.js +5 -3
  8. package/build/exports.js.map +1 -1
  9. package/build/hooks.d.ts +2 -1
  10. package/build/hooks.d.ts.map +1 -1
  11. package/build/hooks.js +11 -4
  12. package/build/hooks.js.map +1 -1
  13. package/build/index.d.ts +0 -2
  14. package/build/index.d.ts.map +1 -1
  15. package/build/index.js +0 -5
  16. package/build/index.js.map +1 -1
  17. package/build/layouts/DrawerClient.d.ts +2 -2
  18. package/build/layouts/StackClient.d.ts +12 -4
  19. package/build/layouts/StackClient.d.ts.map +1 -1
  20. package/build/layouts/StackClient.js +5 -0
  21. package/build/layouts/StackClient.js.map +1 -1
  22. package/build/layouts/TabsClient.d.ts +28 -17
  23. package/build/layouts/TabsClient.d.ts.map +1 -1
  24. package/build/layouts/TabsClient.js +5 -0
  25. package/build/layouts/TabsClient.js.map +1 -1
  26. package/build/layouts/stack-utils/StackScreen.d.ts +44 -5
  27. package/build/layouts/stack-utils/StackScreen.d.ts.map +1 -1
  28. package/build/layouts/stack-utils/StackScreen.js +50 -9
  29. package/build/layouts/stack-utils/StackScreen.js.map +1 -1
  30. package/build/layouts/stack-utils/toolbar/StackToolbarButton.d.ts +3 -1
  31. package/build/layouts/stack-utils/toolbar/StackToolbarButton.d.ts.map +1 -1
  32. package/build/layouts/stack-utils/toolbar/StackToolbarButton.js.map +1 -1
  33. package/build/layouts/stack-utils/toolbar/StackToolbarMenu.d.ts +3 -1
  34. package/build/layouts/stack-utils/toolbar/StackToolbarMenu.d.ts.map +1 -1
  35. package/build/layouts/stack-utils/toolbar/StackToolbarMenu.js +7 -7
  36. package/build/layouts/stack-utils/toolbar/StackToolbarMenu.js.map +1 -1
  37. package/build/layouts/stack-utils/toolbar/StackToolbarSpacer.d.ts +0 -8
  38. package/build/layouts/stack-utils/toolbar/StackToolbarSpacer.d.ts.map +1 -1
  39. package/build/layouts/stack-utils/toolbar/StackToolbarSpacer.js +1 -1
  40. package/build/layouts/stack-utils/toolbar/StackToolbarSpacer.js.map +1 -1
  41. package/build/link/Link.d.ts +1 -1
  42. package/build/link/elements.d.ts +2 -10
  43. package/build/link/elements.d.ts.map +1 -1
  44. package/build/link/elements.js +1 -9
  45. package/build/link/elements.js.map +1 -1
  46. package/build/link/zoom/link-apple-zoom-target.d.ts +24 -2
  47. package/build/link/zoom/link-apple-zoom-target.d.ts.map +1 -1
  48. package/build/link/zoom/link-apple-zoom-target.js +20 -0
  49. package/build/link/zoom/link-apple-zoom-target.js.map +1 -1
  50. package/build/link/zoom/link-apple-zoom.d.ts +1 -2
  51. package/build/link/zoom/link-apple-zoom.d.ts.map +1 -1
  52. package/build/link/zoom/link-apple-zoom.js.map +1 -1
  53. package/build/native-tabs/NativeBottomTabsNavigator.d.ts.map +1 -1
  54. package/build/native-tabs/NativeBottomTabsNavigator.js +2 -1
  55. package/build/native-tabs/NativeBottomTabsNavigator.js.map +1 -1
  56. package/build/native-tabs/NativeTabTrigger.d.ts +2 -6
  57. package/build/native-tabs/NativeTabTrigger.d.ts.map +1 -1
  58. package/build/native-tabs/NativeTabTrigger.js +2 -6
  59. package/build/native-tabs/NativeTabTrigger.js.map +1 -1
  60. package/build/native-tabs/NativeTabs.d.ts +1 -2
  61. package/build/native-tabs/NativeTabs.d.ts.map +1 -1
  62. package/build/native-tabs/NativeTabs.js +1 -2
  63. package/build/native-tabs/NativeTabs.js.map +1 -1
  64. package/build/native-tabs/index.d.ts +1 -1
  65. package/build/native-tabs/index.d.ts.map +1 -1
  66. package/build/native-tabs/index.js +0 -15
  67. package/build/native-tabs/index.js.map +1 -1
  68. package/build/native-tabs/types.d.ts +2 -0
  69. package/build/native-tabs/types.d.ts.map +1 -1
  70. package/build/native-tabs/types.js.map +1 -1
  71. package/build/primitives/elements.d.ts +4 -2
  72. package/build/primitives/elements.d.ts.map +1 -1
  73. package/build/primitives/elements.js +4 -2
  74. package/build/primitives/elements.js.map +1 -1
  75. package/build/primitives/index.d.ts +0 -1
  76. package/build/primitives/index.d.ts.map +1 -1
  77. package/build/primitives/index.js +1 -4
  78. package/build/primitives/index.js.map +1 -1
  79. package/build/primitives/menu.d.ts +0 -2
  80. package/build/primitives/menu.d.ts.map +1 -1
  81. package/build/primitives/menu.js +0 -2
  82. package/build/primitives/menu.js.map +1 -1
  83. package/build/primitives/types.d.ts +2 -0
  84. package/build/primitives/types.d.ts.map +1 -1
  85. package/build/primitives/types.js.map +1 -1
  86. package/build/testing-library/context-stubs.d.ts +2 -1
  87. package/build/testing-library/context-stubs.d.ts.map +1 -1
  88. package/build/testing-library/context-stubs.js.map +1 -1
  89. package/build/types.d.ts +0 -8
  90. package/build/types.d.ts.map +1 -1
  91. package/build/types.js.map +1 -1
  92. package/build/ui/TabContext.d.ts +1 -1
  93. package/build/ui/TabContext.d.ts.map +1 -1
  94. package/build/ui/TabRouter.d.ts +2 -2
  95. package/build/ui/Tabs.d.ts +2 -2
  96. package/build/ui/Tabs.d.ts.map +1 -1
  97. package/expo-module.config.json +1 -1
  98. package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.module → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.module} +7 -7
  99. package/local-maven-repo/expo/modules/router/expo.modules.router/55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.module.md5 +1 -0
  100. package/local-maven-repo/expo/modules/router/expo.modules.router/55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.module.sha1 +1 -0
  101. package/local-maven-repo/expo/modules/router/expo.modules.router/55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.module.sha256 +1 -0
  102. package/local-maven-repo/expo/modules/router/expo.modules.router/55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.module.sha512 +1 -0
  103. package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.pom → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.pom} +1 -1
  104. package/local-maven-repo/expo/modules/router/expo.modules.router/55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.pom.md5 +1 -0
  105. package/local-maven-repo/expo/modules/router/expo.modules.router/55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.pom.sha1 +1 -0
  106. package/local-maven-repo/expo/modules/router/expo.modules.router/55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.pom.sha256 +1 -0
  107. package/local-maven-repo/expo/modules/router/expo.modules.router/55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.pom.sha512 +1 -0
  108. package/local-maven-repo/expo/modules/router/expo.modules.router/maven-metadata.xml +4 -4
  109. package/local-maven-repo/expo/modules/router/expo.modules.router/maven-metadata.xml.md5 +1 -1
  110. package/local-maven-repo/expo/modules/router/expo.modules.router/maven-metadata.xml.sha1 +1 -1
  111. package/local-maven-repo/expo/modules/router/expo.modules.router/maven-metadata.xml.sha256 +1 -1
  112. package/local-maven-repo/expo/modules/router/expo.modules.router/maven-metadata.xml.sha512 +1 -1
  113. package/package.json +16 -15
  114. package/server.d.ts +1 -15
  115. package/local-maven-repo/expo/modules/router/expo.modules.router/7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.module.md5 +0 -1
  116. package/local-maven-repo/expo/modules/router/expo.modules.router/7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.module.sha1 +0 -1
  117. package/local-maven-repo/expo/modules/router/expo.modules.router/7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.module.sha256 +0 -1
  118. package/local-maven-repo/expo/modules/router/expo.modules.router/7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.module.sha512 +0 -1
  119. package/local-maven-repo/expo/modules/router/expo.modules.router/7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.pom.md5 +0 -1
  120. package/local-maven-repo/expo/modules/router/expo.modules.router/7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.pom.sha1 +0 -1
  121. package/local-maven-repo/expo/modules/router/expo.modules.router/7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.pom.sha256 +0 -1
  122. package/local-maven-repo/expo/modules/router/expo.modules.router/7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.pom.sha512 +0 -1
  123. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd-sources.jar → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1-sources.jar} +0 -0
  124. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd-sources.jar.md5 → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1-sources.jar.md5} +0 -0
  125. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd-sources.jar.sha1 → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1-sources.jar.sha1} +0 -0
  126. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd-sources.jar.sha256 → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1-sources.jar.sha256} +0 -0
  127. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd-sources.jar.sha512 → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1-sources.jar.sha512} +0 -0
  128. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.aar → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.aar} +0 -0
  129. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.aar.md5 → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.aar.md5} +0 -0
  130. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.aar.sha1 → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.aar.sha1} +0 -0
  131. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.aar.sha256 → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.aar.sha256} +0 -0
  132. /package/local-maven-repo/expo/modules/router/expo.modules.router/{7.0.0-canary-20260121-a63c0dd/expo.modules.router-7.0.0-canary-20260121-a63c0dd.aar.sha512 → 55.0.0-beta.1/expo.modules.router-55.0.0-beta.1.aar.sha512} +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"StackClient.js","sourceRoot":"","sources":["../../src/layouts/StackClient.tsx"],"names":[],"mappings":";AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACb,qDAYkC;AAKlC,kDAA2C;AAC3C,+CAAiE;AAEjE,2DAAwD;AACxD,gGAA6F;AAC7F,2EAA2E;AAC3E,0DAO6B;AAC7B,8CAA+D;AAC/D,+CAOuB;AACvB,gDAAkD;AAClD,kDAAoE;AACpE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vB,CAAC,CAAC;AACJ,CAAC;AAED,SAAS,mCAAmC,CAAC,KAAuC;IAClF,MAAM,UAAU,GAAG,IAAA,8CAA2B,EAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IAC7D,OAAO,CAAC,CAAC,UAAU,CAAC,+DAA4C,CAAC,CAAC;AACpE,CAAC;AAED,kBAAe,KAAK,CAAC;AAEd,MAAM,WAAW,GAAyB,CAAC,OAAO,EAAE,EAAE;IAC3D,MAAM,MAAM,GAAG,IAAA,oBAAa,EAAC,OAAO,CAAC,CAAC;IACtC,OAAO;QACL,GAAG,MAAM;QACT,GAAG,IAAA,2BAAmB,EAAC,MAAM,CAAC;KAC/B,CAAC;AACJ,CAAC,CAAC;AANW,QAAA,WAAW,eAMtB","sourcesContent":["'use client';\nimport {\n CommonNavigationAction,\n NavigationAction,\n ParamListBase,\n PartialRoute,\n PartialState,\n Route,\n RouterConfigOptions,\n StackRouter as RNStackRouter,\n StackActionType,\n StackNavigationState,\n type RouteProp,\n} from '@react-navigation/native';\nimport {\n NativeStackNavigationEventMap,\n NativeStackNavigationOptions,\n} from '@react-navigation/native-stack';\nimport { nanoid } from 'nanoid/non-secure';\nimport React, { Children, ComponentProps, useMemo } from 'react';\n\nimport { withLayoutContext } from './withLayoutContext';\nimport { createNativeStackNavigator } from '../fork/native-stack/createNativeStackNavigator';\nimport { useLinkPreviewContext } from '../link/preview/LinkPreviewContext';\nimport {\n getInternalExpoRouterParams,\n INTERNAL_EXPO_ROUTER_IS_PREVIEW_NAVIGATION_PARAM_NAME,\n INTERNAL_EXPO_ROUTER_NO_ANIMATION_PARAM_NAME,\n INTERNAL_EXPO_ROUTER_ZOOM_TRANSITION_SCREEN_ID_PARAM_NAME,\n INTERNAL_EXPO_ROUTER_ZOOM_TRANSITION_SOURCE_ID_PARAM_NAME,\n type InternalExpoRouterParams,\n} from '../navigationParams';\nimport { SingularOptions, getSingularId } from '../useScreens';\nimport {\n type StackScreenProps,\n StackHeader,\n StackScreen,\n StackSearchBar,\n StackToolbar,\n appendScreenStackPropsToOptions,\n} from './stack-utils';\nimport { isChildOfType } from '../utils/children';\nimport { Protected, type ProtectedProps } from '../views/Protected';\nimport { Screen } from '../views/Screen';\n\ntype GetId = NonNullable<RouterConfigOptions['routeGetIdList'][string]>;\n\nconst NativeStackNavigator = createNativeStackNavigator().Navigator;\n\n/**\n * We extend NativeStackNavigationOptions with our custom props\n * to allow for several extra props to be used on web, like modalWidth\n */\nexport type ExtendedStackNavigationOptions = NativeStackNavigationOptions & {\n webModalStyle?: {\n /**\n * Override the width of the modal (px or percentage). Only applies on web platform.\n * @platform web\n */\n width?: number | string;\n /**\n * Override the height of the modal (px or percentage). Applies on web desktop.\n * @platform web\n */\n height?: number | string;\n /**\n * Minimum height of the desktop modal (px or percentage). Overrides the default 640px clamp.\n * @platform web\n */\n minHeight?: number | string;\n /**\n * Minimum width of the desktop modal (px or percentage). Overrides the default 580px.\n * @platform web\n */\n minWidth?: number | string;\n /**\n * Override the border of the desktop modal (any valid CSS border value, e.g. '1px solid #ccc' or 'none').\n * @platform web\n */\n border?: string;\n /**\n * Override the overlay background color (any valid CSS color or rgba/hsla value).\n * @platform web\n */\n overlayBackground?: string;\n /**\n * Override the modal shadow filter (any valid CSS filter value, e.g. 'drop-shadow(0 4px 8px rgba(0,0,0,0.1))' or 'none').\n * @platform web\n */\n shadow?: string;\n };\n};\n\nconst RNStack = withLayoutContext<\n ExtendedStackNavigationOptions,\n typeof NativeStackNavigator,\n StackNavigationState<ParamListBase>,\n NativeStackNavigationEventMap\n>(NativeStackNavigator);\n\ntype RNNavigationAction = Extract<CommonNavigationAction, { type: 'NAVIGATE' }>;\ntype RNPreloadAction = Extract<CommonNavigationAction, { type: 'PRELOAD' }>;\ntype ExpoNavigationAction = Omit<RNNavigationAction, 'payload'> & {\n payload: Omit<RNNavigationAction['payload'], 'params'> & {\n params: RNNavigationAction['payload']['params'] & InternalExpoRouterParams;\n };\n};\n\nfunction isStackAction(\n action: NavigationAction\n): action is StackActionType | RNPreloadAction | ExpoNavigationAction {\n return (\n action.type === 'PUSH' ||\n action.type === 'NAVIGATE' ||\n action.type === 'POP' ||\n action.type === 'POP_TO_TOP' ||\n action.type === 'REPLACE' ||\n action.type === 'PRELOAD'\n );\n}\n\nconst isPreviewAction = (action: NavigationAction): action is ExpoNavigationAction =>\n !!action.payload &&\n 'params' in action.payload &&\n typeof action.payload.params === 'object' &&\n !!getInternalExpoRouterParams(action.payload?.params ?? undefined)[\n INTERNAL_EXPO_ROUTER_IS_PREVIEW_NAVIGATION_PARAM_NAME\n ];\n\nconst getZoomTransitionIdFromAction = (action: NavigationAction): string | undefined => {\n const allParams =\n !!action.payload && 'params' in action.payload && typeof action.payload.params === 'object'\n ? action.payload.params\n : undefined;\n const internalParams = getInternalExpoRouterParams(allParams ?? undefined);\n const val = internalParams[INTERNAL_EXPO_ROUTER_ZOOM_TRANSITION_SOURCE_ID_PARAM_NAME];\n if (val && typeof val === 'string') {\n return val;\n }\n return undefined;\n};\n\n/**\n * React Navigation matches a screen by its name or a 'getID' function that uniquely identifies a screen.\n * When a screen has been uniquely identified, the Stack can only have one instance of that screen.\n *\n * Expo Router allows for a screen to be matched by name and path params, a 'getID' function or a singular id.\n *\n * Instead of reimplementing the entire StackRouter, we can override the getStateForAction method to handle the singular screen logic.\n *\n */\nexport const stackRouterOverride: NonNullable<ComponentProps<typeof RNStack>['UNSTABLE_router']> = (\n original\n) => {\n return {\n getStateForAction: (state, action, options) => {\n if (action.target && action.target !== state.key) {\n return null;\n }\n\n if (!isStackAction(action)) {\n return original.getStateForAction(state, action, options);\n }\n\n // The dynamic getId added to an action, `router.push('screen', { singular: true })`\n const actionSingularOptions =\n action.payload && 'singular' in action.payload\n ? (action.payload.singular as SingularOptions)\n : undefined;\n\n // Handle if 'getID' or 'singular' is set.\n function getIdFunction(): GetId | undefined {\n // Actions can be fired by the user, so we do need to validate their structure.\n if (\n !('payload' in action) ||\n !action.payload ||\n !('name' in action.payload) ||\n typeof action.payload.name !== 'string'\n ) {\n return;\n }\n\n const actionName = action.payload.name;\n\n return (\n // The dynamic singular added to an action, `router.push('screen', { singular: () => 'id' })`\n getActionSingularIdFn(actionSingularOptions, actionName) ||\n // The static getId added as a prop to `<Screen singular />` or `<Screen getId={} />`\n options.routeGetIdList[actionName]\n );\n }\n\n const { routeParamList } = options;\n\n switch (action.type) {\n case 'PUSH':\n case 'NAVIGATE': {\n if (!state.routeNames.includes(action.payload.name)) {\n return null;\n }\n\n // START FORK\n const getId = getIdFunction();\n // const getId = options.routeGetIdList[action.payload.name];\n // END FORK\n const id = getId?.({ params: action.payload.params });\n\n let route: Route<string> | undefined;\n\n if (id !== undefined) {\n route = state.routes.findLast(\n (route) =>\n route.name === action.payload.name && id === getId?.({ params: route.params })\n );\n } else if (action.type === 'NAVIGATE') {\n const currentRoute = state.routes[state.index];\n\n // If the route matches the current one, then navigate to it\n if (action.payload.name === currentRoute.name && !isPreviewAction(action)) {\n route = currentRoute;\n } else if (action.payload.pop) {\n route = state.routes.findLast((route) => route.name === action.payload.name);\n }\n }\n\n // START FORK\n let isPreloadedRoute = false;\n if (isPreviewAction(action) && !route) {\n route = state.preloadedRoutes.find(\n (route) => route.name === action.payload.name && id === route.key\n );\n isPreloadedRoute = !!route;\n }\n // END FORK\n\n if (!route) {\n route = state.preloadedRoutes.find(\n (route) =>\n route.name === action.payload.name && id === getId?.({ params: route.params })\n );\n // START FORK\n isPreloadedRoute = !!route;\n // END FORK\n }\n\n let params;\n\n if (action.type === 'NAVIGATE' && action.payload.merge && route) {\n params =\n action.payload.params !== undefined ||\n routeParamList[action.payload.name] !== undefined\n ? {\n ...routeParamList[action.payload.name],\n ...route.params,\n ...action.payload.params,\n }\n : route.params;\n } else {\n params =\n routeParamList[action.payload.name] !== undefined\n ? {\n ...routeParamList[action.payload.name],\n ...action.payload.params,\n }\n : action.payload.params;\n }\n\n let routes: Route<string>[];\n\n if (route) {\n if (action.type === 'NAVIGATE' && action.payload.pop) {\n routes = [];\n\n // Get all routes until the matching one\n for (const r of state.routes) {\n if (r.key === route.key) {\n routes.push({\n ...route,\n path: action.payload.path !== undefined ? action.payload.path : route.path,\n params,\n });\n break;\n }\n\n routes.push(r);\n }\n } else {\n // START FORK\n // If there is an id, then filter out the existing route with the same id.\n // THIS ACTION IS DANGEROUS. This can cause React Native Screens to freeze\n if (id !== undefined) {\n routes = state.routes.filter((r) => r.key !== route.key);\n } else if (action.type === 'NAVIGATE' && state.routes.length > 0) {\n // The navigation action should only replace the last route if it has the same name and path params.\n const lastRoute = state.routes[state.routes.length - 1];\n if (\n getSingularId(lastRoute.name, { params: lastRoute.params }) ===\n getSingularId(route.name, { params })\n ) {\n routes = state.routes.slice(0, -1);\n } else {\n routes = [...state.routes];\n }\n } else {\n routes = [...state.routes];\n }\n\n // If the routes length is the same as the state routes length, then we are navigating to a new route.\n // Otherwise we are replacing an existing route.\n // For preloaded route, we want to use the same key, so that preloaded screen is used.\n const key =\n routes.length === state.routes.length && !isPreloadedRoute\n ? `${action.payload.name}-${nanoid()}`\n : route.key;\n\n routes.push({\n ...route,\n key,\n path:\n action.type === 'NAVIGATE' && action.payload.path !== undefined\n ? action.payload.path\n : route.path,\n params,\n });\n\n // routes = state.routes.filter((r) => r.key !== route.key);\n // routes.push({\n // ...route,\n // path:\n // action.type === 'NAVIGATE' && action.payload.path !== undefined\n // ? action.payload.path\n // : route.path,\n // params,\n // });\n // END FORK\n }\n } else {\n routes = [\n ...state.routes,\n {\n key: `${action.payload.name}-${nanoid()}`,\n name: action.payload.name,\n path: action.type === 'NAVIGATE' ? action.payload.path : undefined,\n params,\n },\n ];\n }\n\n // START FORK\n // return filterSingular(\n const result = {\n ...state,\n index: routes.length - 1,\n preloadedRoutes: state.preloadedRoutes.filter(\n (route) => routes[routes.length - 1].key !== route.key\n ),\n routes,\n };\n\n if (actionSingularOptions) {\n return filterSingular(result, getId);\n }\n\n const zoomTransitionId = getZoomTransitionIdFromAction(action);\n if (zoomTransitionId) {\n const lastRoute = result.routes[result.routes.length - 1];\n const key = lastRoute.key;\n const modifiedLastRoute: typeof lastRoute = {\n ...lastRoute,\n params: {\n ...lastRoute.params,\n [INTERNAL_EXPO_ROUTER_ZOOM_TRANSITION_SCREEN_ID_PARAM_NAME]: key,\n },\n };\n return {\n ...result,\n routes: [...result.routes.slice(0, -1), modifiedLastRoute],\n };\n }\n\n return result;\n // return {\n // ...state,\n // index: routes.length - 1,\n // preloadedRoutes: state.preloadedRoutes.filter(\n // (route) => routes[routes.length - 1].key !== route.key\n // ),\n // routes,\n // };\n // END FORK\n }\n case 'PRELOAD': {\n // START FORK\n // This will be the case for example for protected route\n if (!state.routeNames.includes(action.payload.name)) {\n return null;\n }\n // END FORK\n const getId = options.routeGetIdList[action.payload.name];\n const id = getId?.({ params: action.payload.params });\n\n let route: Route<string> | undefined;\n\n if (id !== undefined) {\n route = state.routes.find(\n (route) =>\n route.name === action.payload.name && id === getId?.({ params: route.params })\n );\n }\n\n if (route) {\n return {\n ...state,\n routes: state.routes.map((r) => {\n if (r.key !== route?.key) {\n return r;\n }\n return {\n ...r,\n params:\n routeParamList[action.payload.name] !== undefined\n ? {\n ...routeParamList[action.payload.name],\n ...action.payload.params,\n }\n : action.payload.params,\n };\n }),\n };\n } else {\n // START FORK\n const currentPreloadedRoute: (typeof state)['preloadedRoutes'][number] = {\n key: `${action.payload.name}-${nanoid()}`,\n name: action.payload.name,\n params:\n routeParamList[action.payload.name] !== undefined\n ? {\n ...routeParamList[action.payload.name],\n ...action.payload.params,\n }\n : action.payload.params,\n };\n // END FORK\n return {\n ...state,\n // START FORK\n // Adding the current preloaded route to the beginning of the preloadedRoutes array\n // This ensures that the preloaded route will be the next one after the visible route\n // and when navigation will happen, there will be no reshuffling\n // This is a workaround for the link preview navigation issue, when screen would freeze after navigation from native side\n // and reshuffling from react-navigation\n preloadedRoutes: [currentPreloadedRoute].concat(\n state.preloadedRoutes.filter(\n (r) => r.name !== action.payload.name || id !== getId?.({ params: r.params })\n )\n ),\n // preloadedRoutes: state.preloadedRoutes\n // .filter(\n // (r) =>\n // r.name !== action.payload.name ||\n // id !== getId?.({ params: r.params })\n // )\n // .concat({\n // key: `${action.payload.name}-${nanoid()}`,\n // name: action.payload.name,\n // params:\n // routeParamList[action.payload.name] !== undefined\n // ? {\n // ...routeParamList[action.payload.name],\n // ...action.payload.params,\n // }\n // : action.payload.params,\n // }),\n // END FORK\n };\n }\n }\n default: {\n return original.getStateForAction(state, action, options);\n }\n }\n },\n };\n};\n\nfunction getActionSingularIdFn(\n actionGetId: SingularOptions | undefined,\n name: string\n): GetId | undefined {\n if (typeof actionGetId === 'function') {\n return (options) => actionGetId(name, options.params ?? {});\n } else if (actionGetId === true) {\n return (options) => getSingularId(name, options);\n }\n\n return undefined;\n}\n\n/**\n * If there is a dynamic singular on an action, then we need to filter the state to only have singular screens.\n * As multiples may have been added before we did the singular navigation.\n */\nfunction filterSingular<\n T extends\n | StackNavigationState<ParamListBase>\n | PartialState<StackNavigationState<ParamListBase>>\n | null,\n>(state: T, getId?: GetId): T {\n if (!state) {\n return state;\n }\n\n if (!state.routes) {\n return state;\n }\n\n const currentIndex = state.index || state.routes.length - 1;\n const current = state.routes[currentIndex];\n const name = current.name;\n\n const id = getId?.({ params: current.params });\n\n if (!id) {\n return state;\n }\n\n // TypeScript needs a type assertion here for the filter to work.\n let routes = state.routes as PartialRoute<Route<string, object | undefined>>[];\n routes = routes.filter((route, index) => {\n // If the route is the current route, keep it.\n if (index === currentIndex) {\n return true;\n }\n\n // Remove all other routes with the same name and id.\n return name !== route.name || id !== getId?.({ params: route.params });\n });\n\n return {\n ...state,\n index: routes.length - 1,\n routes,\n };\n}\n\nfunction mapProtectedScreen(props: ProtectedProps): ProtectedProps {\n return {\n ...props,\n children: Children.toArray(props.children)\n .map((child, index) => {\n if (isChildOfType(child, StackScreen)) {\n const options = appendScreenStackPropsToOptions({}, child.props);\n const { children, ...rest } = child.props;\n return <Screen key={child.props.name} {...rest} options={options} />;\n } else if (isChildOfType(child, Protected)) {\n return <Protected key={`${index}-${props.guard}`} {...mapProtectedScreen(child.props)} />;\n } else if (isChildOfType(child, StackHeader)) {\n // Ignore Stack.Header, because it can be used to set header options for Stack\n // and we use this function to process children of Stack, as well.\n return null;\n } else {\n if (React.isValidElement(child)) {\n console.warn(`Unknown child element passed to Stack: ${child.type}`);\n } else {\n console.warn(`Unknown child element passed to Stack: ${child}`);\n }\n }\n return null;\n })\n .filter(Boolean),\n };\n}\n\nconst Stack = Object.assign(\n (props: ComponentProps<typeof RNStack>) => {\n const { isStackAnimationDisabled } = useLinkPreviewContext();\n\n const screenOptionsWithCompositionAPIOptions = useMemo<NativeStackScreenOptions>(() => {\n const stackHeader = Children.toArray(props.children).find((child) =>\n isChildOfType(child, StackHeader)\n );\n if (stackHeader) {\n const screenStackProps: StackScreenProps = { children: stackHeader };\n const currentOptions = props.screenOptions;\n if (currentOptions) {\n if (typeof currentOptions === 'function') {\n return (...args) => {\n const options = currentOptions(...args);\n return appendScreenStackPropsToOptions(options, screenStackProps);\n };\n }\n return appendScreenStackPropsToOptions(currentOptions, screenStackProps);\n } else {\n return appendScreenStackPropsToOptions({}, screenStackProps);\n }\n } else {\n return props.screenOptions;\n }\n }, [props.screenOptions, props.children]);\n\n const screenOptions = useMemo(() => {\n const condition = isStackAnimationDisabled ? () => true : shouldDisableAnimationBasedOnParams;\n\n return disableAnimationInScreenOptions(screenOptionsWithCompositionAPIOptions, condition);\n }, [screenOptionsWithCompositionAPIOptions, isStackAnimationDisabled]);\n\n const rnChildren = useMemo(\n () => mapProtectedScreen({ guard: true, children: props.children }).children,\n [props.children]\n );\n\n return (\n <RNStack\n {...props}\n children={rnChildren}\n screenOptions={screenOptions}\n UNSTABLE_router={stackRouterOverride}\n />\n );\n },\n {\n Screen: StackScreen,\n Protected,\n Header: StackHeader,\n SearchBar: StackSearchBar,\n Toolbar: StackToolbar,\n }\n);\n\ntype NativeStackScreenOptions = ComponentProps<typeof RNStack>['screenOptions'];\n\nfunction disableAnimationInScreenOptions(\n options: NativeStackScreenOptions | undefined,\n condition: (route: RouteProp<ParamListBase, string>) => boolean\n): NativeStackScreenOptions {\n if (options && typeof options === 'function') {\n return (props) => {\n const oldOptions = options(props);\n if (condition(props.route)) {\n return {\n ...oldOptions,\n animation: 'none',\n };\n }\n return oldOptions ?? {};\n };\n }\n return (props) => {\n if (condition(props.route)) {\n return {\n ...(options ?? {}),\n animation: 'none',\n };\n }\n return options ?? {};\n };\n}\n\nfunction shouldDisableAnimationBasedOnParams(route: RouteProp<ParamListBase, string>): boolean {\n const expoParams = getInternalExpoRouterParams(route.params);\n return !!expoParams[INTERNAL_EXPO_ROUTER_NO_ANIMATION_PARAM_NAME];\n}\n\nexport default Stack;\n\nexport const StackRouter: typeof RNStackRouter = (options) => {\n const router = RNStackRouter(options);\n return {\n ...router,\n ...stackRouterOverride(router),\n };\n};\n"]}
1
+ {"version":3,"file":"StackClient.js","sourceRoot":"","sources":["../../src/layouts/StackClient.tsx"],"names":[],"mappings":";AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACb,qDAYkC;AAKlC,kDAA2C;AAC3C,+CAAiE;AAEjE,2DAAwD;AACxD,gGAA6F;AAC7F,2EAA2E;AAC3E,0DAO6B;AAC7B,8CAA+D;AAC/D,+CAOuB;AACvB,gDAAkD;AAClD,kDAAoE;AACpE,4CAAyC;AAIzC,MAAM,oBAAoB,GAAG,IAAA,uDAA0B,GAAE,CAAC,SAAS,CAAC;AA8CpE,MAAM,OAAO,GAAG,IAAA,qCAAiB,EAK/B,oBAAoB,CAAC,CAAC;AAUxB,SAAS,aAAa,CACpB,MAAwB;IAExB,OAAO,CACL,MAAM,CAAC,IAAI,KAAK,MAAM;QACtB,MAAM,CAAC,IAAI,KAAK,UAAU;QAC1B,MAAM,CAAC,IAAI,KAAK,KAAK;QACrB,MAAM,CAAC,IAAI,KAAK,YAAY;QAC5B,MAAM,CAAC,IAAI,KAAK,SAAS;QACzB,MA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AAM;QACT,GAAG,IAAA,2BAAmB,EAAC,MAAM,CAAC;KAC/B,CAAC;AACJ,CAAC,CAAC;AANW,QAAA,WAAW,eAMtB","sourcesContent":["'use client';\nimport {\n CommonNavigationAction,\n NavigationAction,\n ParamListBase,\n PartialRoute,\n PartialState,\n Route,\n RouterConfigOptions,\n StackRouter as RNStackRouter,\n StackActionType,\n StackNavigationState,\n type RouteProp,\n} from '@react-navigation/native';\nimport {\n NativeStackNavigationEventMap,\n NativeStackNavigationOptions,\n} from '@react-navigation/native-stack';\nimport { nanoid } from 'nanoid/non-secure';\nimport React, { Children, ComponentProps, useMemo } from 'react';\n\nimport { withLayoutContext } from './withLayoutContext';\nimport { createNativeStackNavigator } from '../fork/native-stack/createNativeStackNavigator';\nimport { useLinkPreviewContext } from '../link/preview/LinkPreviewContext';\nimport {\n getInternalExpoRouterParams,\n INTERNAL_EXPO_ROUTER_IS_PREVIEW_NAVIGATION_PARAM_NAME,\n INTERNAL_EXPO_ROUTER_NO_ANIMATION_PARAM_NAME,\n INTERNAL_EXPO_ROUTER_ZOOM_TRANSITION_SCREEN_ID_PARAM_NAME,\n INTERNAL_EXPO_ROUTER_ZOOM_TRANSITION_SOURCE_ID_PARAM_NAME,\n type InternalExpoRouterParams,\n} from '../navigationParams';\nimport { SingularOptions, getSingularId } from '../useScreens';\nimport {\n type StackScreenProps,\n StackHeader,\n StackScreen,\n StackSearchBar,\n StackToolbar,\n appendScreenStackPropsToOptions,\n} from './stack-utils';\nimport { isChildOfType } from '../utils/children';\nimport { Protected, type ProtectedProps } from '../views/Protected';\nimport { Screen } from '../views/Screen';\n\ntype GetId = NonNullable<RouterConfigOptions['routeGetIdList'][string]>;\n\nconst NativeStackNavigator = createNativeStackNavigator().Navigator;\n\n/**\n * We extend NativeStackNavigationOptions with our custom props\n * to allow for several extra props to be used on web, like modalWidth\n */\nexport type ExtendedStackNavigationOptions = NativeStackNavigationOptions & {\n webModalStyle?: {\n /**\n * Override the width of the modal (px or percentage). Only applies on web platform.\n * @platform web\n */\n width?: number | string;\n /**\n * Override the height of the modal (px or percentage). Applies on web desktop.\n * @platform web\n */\n height?: number | string;\n /**\n * Minimum height of the desktop modal (px or percentage). Overrides the default 640px clamp.\n * @platform web\n */\n minHeight?: number | string;\n /**\n * Minimum width of the desktop modal (px or percentage). Overrides the default 580px.\n * @platform web\n */\n minWidth?: number | string;\n /**\n * Override the border of the desktop modal (any valid CSS border value, e.g. '1px solid #ccc' or 'none').\n * @platform web\n */\n border?: string;\n /**\n * Override the overlay background color (any valid CSS color or rgba/hsla value).\n * @platform web\n */\n overlayBackground?: string;\n /**\n * Override the modal shadow filter (any valid CSS filter value, e.g. 'drop-shadow(0 4px 8px rgba(0,0,0,0.1))' or 'none').\n * @platform web\n */\n shadow?: string;\n };\n};\n\nconst RNStack = withLayoutContext<\n ExtendedStackNavigationOptions,\n typeof NativeStackNavigator,\n StackNavigationState<ParamListBase>,\n NativeStackNavigationEventMap\n>(NativeStackNavigator);\n\ntype RNNavigationAction = Extract<CommonNavigationAction, { type: 'NAVIGATE' }>;\ntype RNPreloadAction = Extract<CommonNavigationAction, { type: 'PRELOAD' }>;\ntype ExpoNavigationAction = Omit<RNNavigationAction, 'payload'> & {\n payload: Omit<RNNavigationAction['payload'], 'params'> & {\n params: RNNavigationAction['payload']['params'] & InternalExpoRouterParams;\n };\n};\n\nfunction isStackAction(\n action: NavigationAction\n): action is StackActionType | RNPreloadAction | ExpoNavigationAction {\n return (\n action.type === 'PUSH' ||\n action.type === 'NAVIGATE' ||\n action.type === 'POP' ||\n action.type === 'POP_TO_TOP' ||\n action.type === 'REPLACE' ||\n action.type === 'PRELOAD'\n );\n}\n\nconst isPreviewAction = (action: NavigationAction): action is ExpoNavigationAction =>\n !!action.payload &&\n 'params' in action.payload &&\n typeof action.payload.params === 'object' &&\n !!getInternalExpoRouterParams(action.payload?.params ?? undefined)[\n INTERNAL_EXPO_ROUTER_IS_PREVIEW_NAVIGATION_PARAM_NAME\n ];\n\nconst getZoomTransitionIdFromAction = (action: NavigationAction): string | undefined => {\n const allParams =\n !!action.payload && 'params' in action.payload && typeof action.payload.params === 'object'\n ? action.payload.params\n : undefined;\n const internalParams = getInternalExpoRouterParams(allParams ?? undefined);\n const val = internalParams[INTERNAL_EXPO_ROUTER_ZOOM_TRANSITION_SOURCE_ID_PARAM_NAME];\n if (val && typeof val === 'string') {\n return val;\n }\n return undefined;\n};\n\n/**\n * React Navigation matches a screen by its name or a 'getID' function that uniquely identifies a screen.\n * When a screen has been uniquely identified, the Stack can only have one instance of that screen.\n *\n * Expo Router allows for a screen to be matched by name and path params, a 'getID' function or a singular id.\n *\n * Instead of reimplementing the entire StackRouter, we can override the getStateForAction method to handle the singular screen logic.\n *\n */\nexport const stackRouterOverride: NonNullable<ComponentProps<typeof RNStack>['UNSTABLE_router']> = (\n original\n) => {\n return {\n getStateForAction: (state, action, options) => {\n if (action.target && action.target !== state.key) {\n return null;\n }\n\n if (!isStackAction(action)) {\n return original.getStateForAction(state, action, options);\n }\n\n // The dynamic getId added to an action, `router.push('screen', { singular: true })`\n const actionSingularOptions =\n action.payload && 'singular' in action.payload\n ? (action.payload.singular as SingularOptions)\n : undefined;\n\n // Handle if 'getID' or 'singular' is set.\n function getIdFunction(): GetId | undefined {\n // Actions can be fired by the user, so we do need to validate their structure.\n if (\n !('payload' in action) ||\n !action.payload ||\n !('name' in action.payload) ||\n typeof action.payload.name !== 'string'\n ) {\n return;\n }\n\n const actionName = action.payload.name;\n\n return (\n // The dynamic singular added to an action, `router.push('screen', { singular: () => 'id' })`\n getActionSingularIdFn(actionSingularOptions, actionName) ||\n // The static getId added as a prop to `<Screen singular />` or `<Screen getId={} />`\n options.routeGetIdList[actionName]\n );\n }\n\n const { routeParamList } = options;\n\n switch (action.type) {\n case 'PUSH':\n case 'NAVIGATE': {\n if (!state.routeNames.includes(action.payload.name)) {\n return null;\n }\n\n // START FORK\n const getId = getIdFunction();\n // const getId = options.routeGetIdList[action.payload.name];\n // END FORK\n const id = getId?.({ params: action.payload.params });\n\n let route: Route<string> | undefined;\n\n if (id !== undefined) {\n route = state.routes.findLast(\n (route) =>\n route.name === action.payload.name && id === getId?.({ params: route.params })\n );\n } else if (action.type === 'NAVIGATE') {\n const currentRoute = state.routes[state.index];\n\n // If the route matches the current one, then navigate to it\n if (action.payload.name === currentRoute.name && !isPreviewAction(action)) {\n route = currentRoute;\n } else if (action.payload.pop) {\n route = state.routes.findLast((route) => route.name === action.payload.name);\n }\n }\n\n // START FORK\n let isPreloadedRoute = false;\n if (isPreviewAction(action) && !route) {\n route = state.preloadedRoutes.find(\n (route) => route.name === action.payload.name && id === route.key\n );\n isPreloadedRoute = !!route;\n }\n // END FORK\n\n if (!route) {\n route = state.preloadedRoutes.find(\n (route) =>\n route.name === action.payload.name && id === getId?.({ params: route.params })\n );\n // START FORK\n isPreloadedRoute = !!route;\n // END FORK\n }\n\n let params;\n\n if (action.type === 'NAVIGATE' && action.payload.merge && route) {\n params =\n action.payload.params !== undefined ||\n routeParamList[action.payload.name] !== undefined\n ? {\n ...routeParamList[action.payload.name],\n ...route.params,\n ...action.payload.params,\n }\n : route.params;\n } else {\n params =\n routeParamList[action.payload.name] !== undefined\n ? {\n ...routeParamList[action.payload.name],\n ...action.payload.params,\n }\n : action.payload.params;\n }\n\n let routes: Route<string>[];\n\n if (route) {\n if (action.type === 'NAVIGATE' && action.payload.pop) {\n routes = [];\n\n // Get all routes until the matching one\n for (const r of state.routes) {\n if (r.key === route.key) {\n routes.push({\n ...route,\n path: action.payload.path !== undefined ? action.payload.path : route.path,\n params,\n });\n break;\n }\n\n routes.push(r);\n }\n } else {\n // START FORK\n // If there is an id, then filter out the existing route with the same id.\n // THIS ACTION IS DANGEROUS. This can cause React Native Screens to freeze\n if (id !== undefined) {\n routes = state.routes.filter((r) => r.key !== route.key);\n } else if (action.type === 'NAVIGATE' && state.routes.length > 0) {\n // The navigation action should only replace the last route if it has the same name and path params.\n const lastRoute = state.routes[state.routes.length - 1];\n if (\n getSingularId(lastRoute.name, { params: lastRoute.params }) ===\n getSingularId(route.name, { params })\n ) {\n routes = state.routes.slice(0, -1);\n } else {\n routes = [...state.routes];\n }\n } else {\n routes = [...state.routes];\n }\n\n // If the routes length is the same as the state routes length, then we are navigating to a new route.\n // Otherwise we are replacing an existing route.\n // For preloaded route, we want to use the same key, so that preloaded screen is used.\n const key =\n routes.length === state.routes.length && !isPreloadedRoute\n ? `${action.payload.name}-${nanoid()}`\n : route.key;\n\n routes.push({\n ...route,\n key,\n path:\n action.type === 'NAVIGATE' && action.payload.path !== undefined\n ? action.payload.path\n : route.path,\n params,\n });\n\n // routes = state.routes.filter((r) => r.key !== route.key);\n // routes.push({\n // ...route,\n // path:\n // action.type === 'NAVIGATE' && action.payload.path !== undefined\n // ? action.payload.path\n // : route.path,\n // params,\n // });\n // END FORK\n }\n } else {\n routes = [\n ...state.routes,\n {\n key: `${action.payload.name}-${nanoid()}`,\n name: action.payload.name,\n path: action.type === 'NAVIGATE' ? action.payload.path : undefined,\n params,\n },\n ];\n }\n\n // START FORK\n // return filterSingular(\n const result = {\n ...state,\n index: routes.length - 1,\n preloadedRoutes: state.preloadedRoutes.filter(\n (route) => routes[routes.length - 1].key !== route.key\n ),\n routes,\n };\n\n if (actionSingularOptions) {\n return filterSingular(result, getId);\n }\n\n const zoomTransitionId = getZoomTransitionIdFromAction(action);\n if (zoomTransitionId) {\n const lastRoute = result.routes[result.routes.length - 1];\n const key = lastRoute.key;\n const modifiedLastRoute: typeof lastRoute = {\n ...lastRoute,\n params: {\n ...lastRoute.params,\n [INTERNAL_EXPO_ROUTER_ZOOM_TRANSITION_SCREEN_ID_PARAM_NAME]: key,\n },\n };\n return {\n ...result,\n routes: [...result.routes.slice(0, -1), modifiedLastRoute],\n };\n }\n\n return result;\n // return {\n // ...state,\n // index: routes.length - 1,\n // preloadedRoutes: state.preloadedRoutes.filter(\n // (route) => routes[routes.length - 1].key !== route.key\n // ),\n // routes,\n // };\n // END FORK\n }\n case 'PRELOAD': {\n // START FORK\n // This will be the case for example for protected route\n if (!state.routeNames.includes(action.payload.name)) {\n return null;\n }\n // END FORK\n const getId = options.routeGetIdList[action.payload.name];\n const id = getId?.({ params: action.payload.params });\n\n let route: Route<string> | undefined;\n\n if (id !== undefined) {\n route = state.routes.find(\n (route) =>\n route.name === action.payload.name && id === getId?.({ params: route.params })\n );\n }\n\n if (route) {\n return {\n ...state,\n routes: state.routes.map((r) => {\n if (r.key !== route?.key) {\n return r;\n }\n return {\n ...r,\n params:\n routeParamList[action.payload.name] !== undefined\n ? {\n ...routeParamList[action.payload.name],\n ...action.payload.params,\n }\n : action.payload.params,\n };\n }),\n };\n } else {\n // START FORK\n const currentPreloadedRoute: (typeof state)['preloadedRoutes'][number] = {\n key: `${action.payload.name}-${nanoid()}`,\n name: action.payload.name,\n params:\n routeParamList[action.payload.name] !== undefined\n ? {\n ...routeParamList[action.payload.name],\n ...action.payload.params,\n }\n : action.payload.params,\n };\n // END FORK\n return {\n ...state,\n // START FORK\n // Adding the current preloaded route to the beginning of the preloadedRoutes array\n // This ensures that the preloaded route will be the next one after the visible route\n // and when navigation will happen, there will be no reshuffling\n // This is a workaround for the link preview navigation issue, when screen would freeze after navigation from native side\n // and reshuffling from react-navigation\n preloadedRoutes: [currentPreloadedRoute].concat(\n state.preloadedRoutes.filter(\n (r) => r.name !== action.payload.name || id !== getId?.({ params: r.params })\n )\n ),\n // preloadedRoutes: state.preloadedRoutes\n // .filter(\n // (r) =>\n // r.name !== action.payload.name ||\n // id !== getId?.({ params: r.params })\n // )\n // .concat({\n // key: `${action.payload.name}-${nanoid()}`,\n // name: action.payload.name,\n // params:\n // routeParamList[action.payload.name] !== undefined\n // ? {\n // ...routeParamList[action.payload.name],\n // ...action.payload.params,\n // }\n // : action.payload.params,\n // }),\n // END FORK\n };\n }\n }\n default: {\n return original.getStateForAction(state, action, options);\n }\n }\n },\n };\n};\n\nfunction getActionSingularIdFn(\n actionGetId: SingularOptions | undefined,\n name: string\n): GetId | undefined {\n if (typeof actionGetId === 'function') {\n return (options) => actionGetId(name, options.params ?? {});\n } else if (actionGetId === true) {\n return (options) => getSingularId(name, options);\n }\n\n return undefined;\n}\n\n/**\n * If there is a dynamic singular on an action, then we need to filter the state to only have singular screens.\n * As multiples may have been added before we did the singular navigation.\n */\nfunction filterSingular<\n T extends\n | StackNavigationState<ParamListBase>\n | PartialState<StackNavigationState<ParamListBase>>\n | null,\n>(state: T, getId?: GetId): T {\n if (!state) {\n return state;\n }\n\n if (!state.routes) {\n return state;\n }\n\n const currentIndex = state.index || state.routes.length - 1;\n const current = state.routes[currentIndex];\n const name = current.name;\n\n const id = getId?.({ params: current.params });\n\n if (!id) {\n return state;\n }\n\n // TypeScript needs a type assertion here for the filter to work.\n let routes = state.routes as PartialRoute<Route<string, object | undefined>>[];\n routes = routes.filter((route, index) => {\n // If the route is the current route, keep it.\n if (index === currentIndex) {\n return true;\n }\n\n // Remove all other routes with the same name and id.\n return name !== route.name || id !== getId?.({ params: route.params });\n });\n\n return {\n ...state,\n index: routes.length - 1,\n routes,\n };\n}\n\nfunction mapProtectedScreen(props: ProtectedProps): ProtectedProps {\n return {\n ...props,\n children: Children.toArray(props.children)\n .map((child, index) => {\n if (isChildOfType(child, StackScreen)) {\n const options = appendScreenStackPropsToOptions({}, child.props);\n const { children, ...rest } = child.props;\n return <Screen key={child.props.name} {...rest} options={options} />;\n } else if (isChildOfType(child, Protected)) {\n return <Protected key={`${index}-${props.guard}`} {...mapProtectedScreen(child.props)} />;\n } else if (isChildOfType(child, StackHeader)) {\n // Ignore Stack.Header, because it can be used to set header options for Stack\n // and we use this function to process children of Stack, as well.\n return null;\n } else {\n if (React.isValidElement(child)) {\n console.warn(`Unknown child element passed to Stack: ${child.type}`);\n } else {\n console.warn(`Unknown child element passed to Stack: ${child}`);\n }\n }\n return null;\n })\n .filter(Boolean),\n };\n}\n\n/**\n * Renders a native stack navigator.\n *\n * @hideType\n */\nconst Stack = Object.assign(\n (props: ComponentProps<typeof RNStack>) => {\n const { isStackAnimationDisabled } = useLinkPreviewContext();\n\n const screenOptionsWithCompositionAPIOptions = useMemo<NativeStackScreenOptions>(() => {\n const stackHeader = Children.toArray(props.children).find((child) =>\n isChildOfType(child, StackHeader)\n );\n if (stackHeader) {\n const screenStackProps: StackScreenProps = { children: stackHeader };\n const currentOptions = props.screenOptions;\n if (currentOptions) {\n if (typeof currentOptions === 'function') {\n return (...args) => {\n const options = currentOptions(...args);\n return appendScreenStackPropsToOptions(options, screenStackProps);\n };\n }\n return appendScreenStackPropsToOptions(currentOptions, screenStackProps);\n } else {\n return appendScreenStackPropsToOptions({}, screenStackProps);\n }\n } else {\n return props.screenOptions;\n }\n }, [props.screenOptions, props.children]);\n\n const screenOptions = useMemo(() => {\n const condition = isStackAnimationDisabled ? () => true : shouldDisableAnimationBasedOnParams;\n\n return disableAnimationInScreenOptions(screenOptionsWithCompositionAPIOptions, condition);\n }, [screenOptionsWithCompositionAPIOptions, isStackAnimationDisabled]);\n\n const rnChildren = useMemo(\n () => mapProtectedScreen({ guard: true, children: props.children }).children,\n [props.children]\n );\n\n return (\n <RNStack\n {...props}\n children={rnChildren}\n screenOptions={screenOptions}\n UNSTABLE_router={stackRouterOverride}\n />\n );\n },\n {\n Screen: StackScreen,\n Protected,\n Header: StackHeader,\n SearchBar: StackSearchBar,\n Toolbar: StackToolbar,\n }\n);\n\ntype NativeStackScreenOptions = ComponentProps<typeof RNStack>['screenOptions'];\n\nfunction disableAnimationInScreenOptions(\n options: NativeStackScreenOptions | undefined,\n condition: (route: RouteProp<ParamListBase, string>) => boolean\n): NativeStackScreenOptions {\n if (options && typeof options === 'function') {\n return (props) => {\n const oldOptions = options(props);\n if (condition(props.route)) {\n return {\n ...oldOptions,\n animation: 'none',\n };\n }\n return oldOptions ?? {};\n };\n }\n return (props) => {\n if (condition(props.route)) {\n return {\n ...(options ?? {}),\n animation: 'none',\n };\n }\n return options ?? {};\n };\n}\n\nfunction shouldDisableAnimationBasedOnParams(route: RouteProp<ParamListBase, string>): boolean {\n const expoParams = getInternalExpoRouterParams(route.params);\n return !!expoParams[INTERNAL_EXPO_ROUTER_NO_ANIMATION_PARAM_NAME];\n}\n\nexport default Stack;\n\nexport const StackRouter: typeof RNStackRouter = (options) => {\n const router = RNStackRouter(options);\n return {\n ...router,\n ...stackRouterOverride(router),\n };\n};\n"]}
@@ -3,7 +3,7 @@ import { ParamListBase, TabNavigationState } from '@react-navigation/native';
3
3
  import React, { ComponentProps } from 'react';
4
4
  import { Href } from '../types';
5
5
  import { Protected } from '../views/Protected';
6
- declare const BottomTabNavigator: React.ComponentType<Omit<import("@react-navigation/bottom-tabs").BottomTabNavigatorProps, "children" | "layout" | "initialRouteName" | "id" | "screenOptions" | "screenListeners" | "screenLayout" | "UNSTABLE_router" | "UNSTABLE_routeNamesChangeBehavior"> & import("@react-navigation/native").DefaultRouterOptions<string> & {
6
+ declare const BottomTabNavigator: React.ComponentType<Omit<import("@react-navigation/bottom-tabs").BottomTabNavigatorProps, "children" | "layout" | "initialRouteName" | "id" | "screenListeners" | "screenOptions" | "screenLayout" | "UNSTABLE_router" | "UNSTABLE_routeNamesChangeBehavior"> & import("@react-navigation/native").DefaultRouterOptions<string> & ({
7
7
  children: React.ReactNode;
8
8
  layout?: ((props: {
9
9
  state: TabNavigationState<ParamListBase>;
@@ -22,7 +22,7 @@ declare const BottomTabNavigator: React.ComponentType<Omit<import("@react-naviga
22
22
  beforeRemove: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "beforeRemove", true>;
23
23
  }> | ((props: {
24
24
  route: import("@react-navigation/native").RouteProp<ParamListBase, string>;
25
- navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>;
25
+ navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>;
26
26
  }) => Partial<{
27
27
  tabPress: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "tabPress", true>;
28
28
  tabLongPress: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "tabLongPress", unknown>;
@@ -35,10 +35,10 @@ declare const BottomTabNavigator: React.ComponentType<Omit<import("@react-naviga
35
35
  }>) | undefined;
36
36
  screenOptions?: BottomTabNavigationOptions | ((props: {
37
37
  route: import("@react-navigation/native").RouteProp<ParamListBase, string>;
38
- navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>;
38
+ navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>;
39
39
  theme: ReactNavigation.Theme;
40
40
  }) => BottomTabNavigationOptions) | undefined;
41
- screenLayout?: ((props: import("@react-navigation/native").ScreenLayoutArgs<ParamListBase, string, BottomTabNavigationOptions, import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>>) => React.ReactElement) | undefined;
41
+ screenLayout?: ((props: import("@react-navigation/native").ScreenLayoutArgs<ParamListBase, string, BottomTabNavigationOptions, import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>>) => React.ReactElement) | undefined;
42
42
  UNSTABLE_router?: (<Action extends Readonly<{
43
43
  type: string;
44
44
  payload?: object;
@@ -46,14 +46,16 @@ declare const BottomTabNavigator: React.ComponentType<Omit<import("@react-naviga
46
46
  target?: string;
47
47
  }>>(original: import("@react-navigation/native").Router<TabNavigationState<ParamListBase>, Action>) => Partial<import("@react-navigation/native").Router<TabNavigationState<ParamListBase>, Action>>) | undefined;
48
48
  UNSTABLE_routeNamesChangeBehavior?: "firstMatch" | "lastUnhandled";
49
- } & {
49
+ } & ({
50
50
  id?: undefined;
51
- }>;
51
+ } | {
52
+ id: string;
53
+ }))>;
52
54
  export type BottomTabNavigator = typeof BottomTabNavigator;
53
55
  type TabsProps = BottomTabNavigationOptions & {
54
56
  href?: Href | null;
55
57
  };
56
- declare const ExpoTabs: React.ForwardRefExoticComponent<Omit<Omit<import("@react-navigation/bottom-tabs").BottomTabNavigatorProps, "children" | "layout" | "initialRouteName" | "id" | "screenOptions" | "screenListeners" | "screenLayout" | "UNSTABLE_router" | "UNSTABLE_routeNamesChangeBehavior"> & import("@react-navigation/native").DefaultRouterOptions<string> & {
58
+ declare const ExpoTabs: React.ForwardRefExoticComponent<Omit<Omit<import("@react-navigation/bottom-tabs").BottomTabNavigatorProps, "children" | "layout" | "initialRouteName" | "id" | "screenListeners" | "screenOptions" | "screenLayout" | "UNSTABLE_router" | "UNSTABLE_routeNamesChangeBehavior"> & import("@react-navigation/native").DefaultRouterOptions<string> & ({
57
59
  children: React.ReactNode;
58
60
  layout?: ((props: {
59
61
  state: TabNavigationState<ParamListBase>;
@@ -72,7 +74,7 @@ declare const ExpoTabs: React.ForwardRefExoticComponent<Omit<Omit<import("@react
72
74
  beforeRemove: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "beforeRemove", true>;
73
75
  }> | ((props: {
74
76
  route: import("@react-navigation/native").RouteProp<ParamListBase, string>;
75
- navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>;
77
+ navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>;
76
78
  }) => Partial<{
77
79
  tabPress: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "tabPress", true>;
78
80
  tabLongPress: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "tabLongPress", unknown>;
@@ -85,10 +87,10 @@ declare const ExpoTabs: React.ForwardRefExoticComponent<Omit<Omit<import("@react
85
87
  }>) | undefined;
86
88
  screenOptions?: BottomTabNavigationOptions | ((props: {
87
89
  route: import("@react-navigation/native").RouteProp<ParamListBase, string>;
88
- navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>;
90
+ navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>;
89
91
  theme: ReactNavigation.Theme;
90
92
  }) => BottomTabNavigationOptions) | undefined;
91
- screenLayout?: ((props: import("@react-navigation/native").ScreenLayoutArgs<ParamListBase, string, BottomTabNavigationOptions, import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>>) => React.ReactElement) | undefined;
93
+ screenLayout?: ((props: import("@react-navigation/native").ScreenLayoutArgs<ParamListBase, string, BottomTabNavigationOptions, import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>>) => React.ReactElement) | undefined;
92
94
  UNSTABLE_router?: (<Action extends Readonly<{
93
95
  type: string;
94
96
  payload?: object;
@@ -96,9 +98,11 @@ declare const ExpoTabs: React.ForwardRefExoticComponent<Omit<Omit<import("@react
96
98
  target?: string;
97
99
  }>>(original: import("@react-navigation/native").Router<TabNavigationState<ParamListBase>, Action>) => Partial<import("@react-navigation/native").Router<TabNavigationState<ParamListBase>, Action>>) | undefined;
98
100
  UNSTABLE_routeNamesChangeBehavior?: "firstMatch" | "lastUnhandled";
99
- } & {
101
+ } & ({
100
102
  id?: undefined;
101
- }, "children"> & Partial<Pick<Omit<import("@react-navigation/bottom-tabs").BottomTabNavigatorProps, "children" | "layout" | "initialRouteName" | "id" | "screenOptions" | "screenListeners" | "screenLayout" | "UNSTABLE_router" | "UNSTABLE_routeNamesChangeBehavior"> & import("@react-navigation/native").DefaultRouterOptions<string> & {
103
+ } | {
104
+ id: string;
105
+ })), "children"> & Partial<Pick<Omit<import("@react-navigation/bottom-tabs").BottomTabNavigatorProps, "children" | "layout" | "initialRouteName" | "id" | "screenListeners" | "screenOptions" | "screenLayout" | "UNSTABLE_router" | "UNSTABLE_routeNamesChangeBehavior"> & import("@react-navigation/native").DefaultRouterOptions<string> & ({
102
106
  children: React.ReactNode;
103
107
  layout?: ((props: {
104
108
  state: TabNavigationState<ParamListBase>;
@@ -117,7 +121,7 @@ declare const ExpoTabs: React.ForwardRefExoticComponent<Omit<Omit<import("@react
117
121
  beforeRemove: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "beforeRemove", true>;
118
122
  }> | ((props: {
119
123
  route: import("@react-navigation/native").RouteProp<ParamListBase, string>;
120
- navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>;
124
+ navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>;
121
125
  }) => Partial<{
122
126
  tabPress: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "tabPress", true>;
123
127
  tabLongPress: import("@react-navigation/native").EventListenerCallback<BottomTabNavigationEventMap & import("@react-navigation/native").EventMapCore<TabNavigationState<ParamListBase>>, "tabLongPress", unknown>;
@@ -130,10 +134,10 @@ declare const ExpoTabs: React.ForwardRefExoticComponent<Omit<Omit<import("@react
130
134
  }>) | undefined;
131
135
  screenOptions?: BottomTabNavigationOptions | ((props: {
132
136
  route: import("@react-navigation/native").RouteProp<ParamListBase, string>;
133
- navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>;
137
+ navigation: import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>;
134
138
  theme: ReactNavigation.Theme;
135
139
  }) => BottomTabNavigationOptions) | undefined;
136
- screenLayout?: ((props: import("@react-navigation/native").ScreenLayoutArgs<ParamListBase, string, BottomTabNavigationOptions, import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, undefined>>) => React.ReactElement) | undefined;
140
+ screenLayout?: ((props: import("@react-navigation/native").ScreenLayoutArgs<ParamListBase, string, BottomTabNavigationOptions, import("@react-navigation/bottom-tabs").BottomTabNavigationProp<ParamListBase, string, string | undefined>>) => React.ReactElement) | undefined;
137
141
  UNSTABLE_router?: (<Action extends Readonly<{
138
142
  type: string;
139
143
  payload?: object;
@@ -141,12 +145,19 @@ declare const ExpoTabs: React.ForwardRefExoticComponent<Omit<Omit<import("@react
141
145
  target?: string;
142
146
  }>>(original: import("@react-navigation/native").Router<TabNavigationState<ParamListBase>, Action>) => Partial<import("@react-navigation/native").Router<TabNavigationState<ParamListBase>, Action>>) | undefined;
143
147
  UNSTABLE_routeNamesChangeBehavior?: "firstMatch" | "lastUnhandled";
144
- } & {
148
+ } & ({
145
149
  id?: undefined;
146
- }, "children">> & React.RefAttributes<unknown>> & {
150
+ } | {
151
+ id: string;
152
+ })), "children">> & React.RefAttributes<unknown>> & {
147
153
  Screen: (props: import("..").ScreenProps<TabsProps, TabNavigationState<ParamListBase>, BottomTabNavigationEventMap>) => null;
148
154
  Protected: typeof Protected;
149
155
  };
156
+ /**
157
+ * Renders a tabs navigator.
158
+ *
159
+ * @hideType
160
+ */
150
161
  declare const Tabs: ((props: ComponentProps<typeof ExpoTabs>) => React.JSX.Element) & {
151
162
  Screen: (props: import("..").ScreenProps<TabsProps, TabNavigationState<ParamListBase>, BottomTabNavigationEventMap>) => null;
152
163
  Protected: React.FunctionComponent<import("../views/Protected").ProtectedProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"TabsClient.d.ts","sourceRoot":"","sources":["../../src/layouts/TabsClient.tsx"],"names":[],"mappings":"AAEA,OAAO,EACL,2BAA2B,EAC3B,0BAA0B,EAE3B,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC7E,OAAO,KAAK,EAAE,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAK9C,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0CZ,CAAC;AAEH;;;;GAIG;AACH,QAAA,MAAM,IAAI,WACA,cAAc,CAAC,OAAO,QAAQ,CAAC;;;CAOxC,CAAC;AAEF,eAAe,IAAI,CAAC"}
@@ -42,6 +42,11 @@ const ExpoTabs = (0, withLayoutContext_1.withLayoutContext)(BottomTabNavigator,
42
42
  return screen;
43
43
  });
44
44
  });
45
+ /**
46
+ * Renders a tabs navigator.
47
+ *
48
+ * @hideType
49
+ */
45
50
  const Tabs = Object.assign((props) => {
46
51
  return <ExpoTabs {...props} UNSTABLE_router={TabRouter_1.tabRouterOverride}/>;
47
52
  }, {
@@ -1 +1 @@
1
- {"version":3,"file":"TabsClient.js","sourceRoot":"","sources":["../../src/layouts/TabsClient.tsx"],"names":[],"mappings":";AAAA,YAAY,CAAC;;;;;AAEb,+DAIuC;AAEvC,kDAA8C;AAC9C,+CAAmD;AAEnD,2DAAwD;AACxD,uCAAoC;AAEpC,2CAAgD;AAChD,kDAA+C;AAE/C,gDAAgD;AAChD,MAAM,kBAAkB,GAAG,IAAA,sCAAwB,GAAE,CAAC,SAAS,CAAC;AAMhE,MAAM,QAAQ,GAAG,IAAA,qCAAiB,EAKhC,kBAAkB,EAAE,CAAC,OAAO,EAAE,EAAE;IAChC,oCAAoC;IACpC,OAAO,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE;QAC5B,IAAI,OAAO,MAAM,CAAC,OAAO,KAAK,UAAU,IAAI,MAAM,CAAC,OAAO,EAAE,IAAI,KAAK,SAAS,EAAE,CAAC;YAC/E,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,GAAG,MAAM,CAAC,OAAO,CAAC;YAC5C,IAAI,OAAO,CAAC,YAAY,EAAE,CAAC;gBACzB,MAAM,IAAI,KAAK,CAAC,gDAAgD,CAAC,CAAC;YACpE,CAAC;YAC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EF,kBAAe,IAAI,CAAC","sourcesContent":["'use client';\n\nimport {\n BottomTabNavigationEventMap,\n BottomTabNavigationOptions,\n createBottomTabNavigator,\n} from '@react-navigation/bottom-tabs';\nimport { ParamListBase, TabNavigationState } from '@react-navigation/native';\nimport React, { ComponentProps } from 'react';\nimport { Pressable, Platform } from 'react-native';\n\nimport { withLayoutContext } from './withLayoutContext';\nimport { Link } from '../link/Link';\nimport { Href } from '../types';\nimport { tabRouterOverride } from './TabRouter';\nimport { Protected } from '../views/Protected';\n\n// This is the only way to access the navigator.\nconst BottomTabNavigator = createBottomTabNavigator().Navigator;\n\nexport type BottomTabNavigator = typeof BottomTabNavigator;\n\ntype TabsProps = BottomTabNavigationOptions & { href?: Href | null };\n\nconst ExpoTabs = withLayoutContext<\n TabsProps,\n typeof BottomTabNavigator,\n TabNavigationState<ParamListBase>,\n BottomTabNavigationEventMap\n>(BottomTabNavigator, (screens) => {\n // Support the `href` shortcut prop.\n return screens.map((screen) => {\n if (typeof screen.options !== 'function' && screen.options?.href !== undefined) {\n const { href, ...options } = screen.options;\n if (options.tabBarButton) {\n throw new Error('Cannot use `href` and `tabBarButton` together.');\n }\n return {\n ...screen,\n options: {\n ...options,\n tabBarItemStyle: href == null ? { display: 'none' } : options.tabBarItemStyle,\n // @ts-expect-error: TODO(@kitten): This isn't properly typed\n tabBarButton: (props) => {\n if (href == null) {\n return null;\n }\n const children =\n Platform.OS === 'web' ? props.children : <Pressable>{props.children}</Pressable>;\n // TODO: React Navigation types these props as Animated.WithAnimatedValue<StyleProp<ViewStyle>>\n // While Link expects a TextStyle. We need to reconcile these types.\n return (\n <Link\n {...(props as any)}\n style={[{ display: 'flex' }, props.style as any]}\n href={href}\n asChild={Platform.OS !== 'web'}\n children={children}\n />\n );\n },\n },\n };\n }\n return screen;\n });\n});\n\nconst Tabs = Object.assign(\n (props: ComponentProps<typeof ExpoTabs>) => {\n return <ExpoTabs {...props} UNSTABLE_router={tabRouterOverride} />;\n },\n {\n Screen: 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C,CAAC,wBAAS,CAAC,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,wBAAS,CAAC,CAAC;wBACnF,+FAA+F;wBAC/F,0EAA0E;wBAC1E,OAAO,CACL,CAAC,WAAI,CACH,IAAK,KAAa,CAAC,CACnB,KAAK,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,KAAK,CAAC,KAAY,CAAC,CAAC,CACjD,IAAI,CAAC,CAAC,IAAI,CAAC,CACX,OAAO,CAAC,CAAC,uBAAQ,CAAC,EAAE,KAAK,KAAK,CAAC,CAC/B,QAAQ,CAAC,CAAC,QAAQ,CAAC,EACnB,CACH,CAAC;oBACJ,CAAC;iBACF;aACF,CAAC;QACJ,CAAC;QACD,OAAO,MAAM,CAAC;IAChB,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH;;;;GAIG;AACH,MAAM,IAAI,GAAG,MAAM,CAAC,MAAM,CACxB,CAAC,KAAsC,EAAE,EAAE;IACzC,OAAO,CAAC,QAAQ,CAAC,IAAI,KAAK,CAAC,CAAC,eAAe,CAAC,CAAC,6BAAiB,CAAC,EAAG,CAAC;AACrE,CAAC,EACD;IACE,MAAM,EAAE,QAAQ,CAAC,MAAM;IACvB,SAAS,EAAT,qBAAS;CACV,CACF,CAAC;AAEF,kBAAe,IAAI,CAAC","sourcesContent":["'use client';\n\nimport {\n BottomTabNavigationEventMap,\n BottomTabNavigationOptions,\n createBottomTabNavigator,\n} from '@react-navigation/bottom-tabs';\nimport { ParamListBase, TabNavigationState } from '@react-navigation/native';\nimport React, { ComponentProps } from 'react';\nimport { Pressable, Platform } from 'react-native';\n\nimport { withLayoutContext } from './withLayoutContext';\nimport { Link } from '../link/Link';\nimport { Href } from '../types';\nimport { tabRouterOverride } from './TabRouter';\nimport { Protected } from '../views/Protected';\n\n// This is the only way to access the navigator.\nconst BottomTabNavigator = createBottomTabNavigator().Navigator;\n\nexport type BottomTabNavigator = typeof BottomTabNavigator;\n\ntype TabsProps = BottomTabNavigationOptions & { href?: Href | null };\n\nconst ExpoTabs = withLayoutContext<\n TabsProps,\n typeof BottomTabNavigator,\n TabNavigationState<ParamListBase>,\n BottomTabNavigationEventMap\n>(BottomTabNavigator, (screens) => {\n // Support the `href` shortcut prop.\n return screens.map((screen) => {\n if (typeof screen.options !== 'function' && screen.options?.href !== undefined) {\n const { href, ...options } = screen.options;\n if (options.tabBarButton) {\n throw new Error('Cannot use `href` and `tabBarButton` together.');\n }\n return {\n ...screen,\n options: {\n ...options,\n tabBarItemStyle: href == null ? { display: 'none' } : options.tabBarItemStyle,\n // @ts-expect-error: TODO(@kitten): This isn't properly typed\n tabBarButton: (props) => {\n if (href == null) {\n return null;\n }\n const children =\n Platform.OS === 'web' ? props.children : <Pressable>{props.children}</Pressable>;\n // TODO: React Navigation types these props as Animated.WithAnimatedValue<StyleProp<ViewStyle>>\n // While Link expects a TextStyle. We need to reconcile these types.\n return (\n <Link\n {...(props as any)}\n style={[{ display: 'flex' }, props.style as any]}\n href={href}\n asChild={Platform.OS !== 'web'}\n children={children}\n />\n );\n },\n },\n };\n }\n return screen;\n });\n});\n\n/**\n * Renders a tabs navigator.\n *\n * @hideType\n */\nconst Tabs = Object.assign(\n (props: ComponentProps<typeof ExpoTabs>) => {\n return <ExpoTabs {...props} UNSTABLE_router={tabRouterOverride} />;\n },\n {\n Screen: ExpoTabs.Screen,\n Protected,\n }\n);\n\nexport default Tabs;\n"]}
@@ -5,10 +5,49 @@ export interface StackScreenProps extends PropsWithChildren {
5
5
  name?: string;
6
6
  options?: NativeStackNavigationOptions;
7
7
  }
8
- export declare function StackScreen({ children, options, ...rest }: StackScreenProps): import("react").JSX.Element;
9
- export declare namespace StackScreen {
10
- var Title: typeof StackScreenTitle;
11
- var BackButton: typeof StackScreenBackButton;
12
- }
8
+ /**
9
+ * Component used to define a screen in a native stack navigator.
10
+ *
11
+ * Can be used in the `_layout.tsx` files, or directly in page components.
12
+ *
13
+ * When configuring header inside page components, prefer using `Stack.Toolbar`, `Stack.Header` and `Stack.Screen.*` components.
14
+ *
15
+ * @example
16
+ * ```tsx app/_layout.tsx
17
+ * import { Stack } from 'expo-router';
18
+ *
19
+ * export default function Layout() {
20
+ * return (
21
+ * <Stack>
22
+ * <Stack.Screen
23
+ * name="home"
24
+ * options={{ title: 'Home' }}
25
+ * />
26
+ * </Stack>
27
+ * );
28
+ * }
29
+ * ```
30
+ *
31
+ * @example
32
+ * ```tsx app/home.tsx
33
+ * import { Stack } from 'expo-router';
34
+ *
35
+ * export default function HomePage() {
36
+ * return (
37
+ * <>
38
+ * <Stack.Screen
39
+ * options={{ headerTransparent: true }}
40
+ * />
41
+ * <Stack.Screen.Title>Welcome Home</Stack.Screen.Title>
42
+ * // Page content
43
+ * </>
44
+ * );
45
+ * }
46
+ * ```
47
+ */
48
+ export declare const StackScreen: (({ children, options, ...rest }: StackScreenProps) => import("react").JSX.Element) & {
49
+ Title: typeof StackScreenTitle;
50
+ BackButton: typeof StackScreenBackButton;
51
+ };
13
52
  export declare function appendScreenStackPropsToOptions(options: NativeStackNavigationOptions, props: StackScreenProps): NativeStackNavigationOptions;
14
53
  //# sourceMappingURL=StackScreen.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"StackScreen.d.ts","sourceRoot":"","sources":["../../../src/layouts/stack-utils/StackScreen.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,4BAA4B,EAAE,MAAM,gCAAgC,CAAC;AAC9E,OAAO,EAAqC,KAAK,iBAAiB,EAAkB,MAAM,OAAO,CAAC;AAGlG,OAAO,EACL,gBAAgB,EAEhB,qBAAqB,EAEtB,MAAM,UAAU,CAAC;AAKlB,MAAM,WAAW,gBAAiB,SAAQ,iBAAiB;IACzD,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,4BAA4B,CAAC;CACxC;AAUD,wBAAgB,WAAW,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,IAAI,EAAE,EAAE,gBAAgB,+BAmB3E;yBAnBe,WAAW;;;;AAwB3B,wBAAgB,+BAA+B,CAC7C,OAAO,EAAE,4BAA4B,EACrC,KAAK,EAAE,gBAAgB,GACtB,4BAA4B,CA2C9B"}
1
+ {"version":3,"file":"StackScreen.d.ts","sourceRoot":"","sources":["../../../src/layouts/stack-utils/StackScreen.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,4BAA4B,EAAE,MAAM,gCAAgC,CAAC;AAC9E,OAAO,EAAqC,KAAK,iBAAiB,EAAkB,MAAM,OAAO,CAAC;AAGlG,OAAO,EACL,gBAAgB,EAEhB,qBAAqB,EAEtB,MAAM,UAAU,CAAC;AAKlB,MAAM,WAAW,gBAAiB,SAAQ,iBAAiB;IACzD,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,4BAA4B,CAAC;CACxC;AAUD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,eAAO,MAAM,WAAW,oCAC+B,gBAAgB;;;CAwBtE,CAAC;AAEF,wBAAgB,+BAA+B,CAC7C,OAAO,EAAE,4BAA4B,EACrC,KAAK,EAAE,gBAAgB,GACtB,4BAA4B,CA2C9B"}
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  'use client';
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.StackScreen = StackScreen;
4
+ exports.StackScreen = void 0;
5
5
  exports.appendScreenStackPropsToOptions = appendScreenStackPropsToOptions;
6
6
  const react_1 = require("react");
7
7
  const StackHeaderComponent_1 = require("./StackHeaderComponent");
@@ -12,20 +12,61 @@ const Screen_1 = require("../../views/Screen");
12
12
  function extractBottomToolbars(children) {
13
13
  return ((0, children_1.getAllChildrenOfType)(children, toolbar_1.StackToolbar).filter((child) => child.props.placement === 'bottom' || child.props.placement === undefined) ?? []);
14
14
  }
15
- function StackScreen({ children, options, ...rest }) {
15
+ /**
16
+ * Component used to define a screen in a native stack navigator.
17
+ *
18
+ * Can be used in the `_layout.tsx` files, or directly in page components.
19
+ *
20
+ * When configuring header inside page components, prefer using `Stack.Toolbar`, `Stack.Header` and `Stack.Screen.*` components.
21
+ *
22
+ * @example
23
+ * ```tsx app/_layout.tsx
24
+ * import { Stack } from 'expo-router';
25
+ *
26
+ * export default function Layout() {
27
+ * return (
28
+ * <Stack>
29
+ * <Stack.Screen
30
+ * name="home"
31
+ * options={{ title: 'Home' }}
32
+ * />
33
+ * </Stack>
34
+ * );
35
+ * }
36
+ * ```
37
+ *
38
+ * @example
39
+ * ```tsx app/home.tsx
40
+ * import { Stack } from 'expo-router';
41
+ *
42
+ * export default function HomePage() {
43
+ * return (
44
+ * <>
45
+ * <Stack.Screen
46
+ * options={{ headerTransparent: true }}
47
+ * />
48
+ * <Stack.Screen.Title>Welcome Home</Stack.Screen.Title>
49
+ * // Page content
50
+ * </>
51
+ * );
52
+ * }
53
+ * ```
54
+ */
55
+ exports.StackScreen = Object.assign(function StackScreen({ children, options, ...rest }) {
16
56
  // This component will only render when used inside a page.
17
57
  const updatedOptions = (0, react_1.useMemo)(() => appendScreenStackPropsToOptions(options ?? {}, {
18
58
  children,
19
59
  }), [options, children]);
20
60
  const bottomToolbars = (0, react_1.useMemo)(() => extractBottomToolbars(children), [children]);
21
61
  return (<>
22
- <Screen_1.Screen {...rest} options={updatedOptions}/>
23
- {/* Bottom toolbar is a native component rendered separately */}
24
- {bottomToolbars}
25
- </>);
26
- }
27
- StackScreen.Title = screen_1.StackScreenTitle;
28
- StackScreen.BackButton = screen_1.StackScreenBackButton;
62
+ <Screen_1.Screen {...rest} options={updatedOptions}/>
63
+ {/* Bottom toolbar is a native component rendered separately */}
64
+ {bottomToolbars}
65
+ </>);
66
+ }, {
67
+ Title: screen_1.StackScreenTitle,
68
+ BackButton: screen_1.StackScreenBackButton,
69
+ });
29
70
  function appendScreenStackPropsToOptions(options, props) {
30
71
  let updatedOptions = { ...options, ...props.options };
31
72
  function appendChildOptions(child, opts) {
@@ -1 +1 @@
1
- {"version":3,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,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE,EAAE;QACzC,IAAI,IAAA,sBAAc,EAAC,KAAK,CAAC,EAAE,CAAC;YAC1B,cAAc,GAAG,kBAAkB,CAAC,KAAK,EAAE,cAAc,CAAC,CAAC;QAC7D,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,OAAO,cAAc,CAAC;AACxB,CAAC","sourcesContent":["'use client';\nimport { NativeStackNavigationOptions } from '@react-navigation/native-stack';\nimport { Children, isValidElement, useMemo, type PropsWithChildren, type ReactNode } from 'react';\n\nimport { StackHeaderComponent, appendStackHeaderPropsToOptions } from './StackHeaderComponent';\nimport {\n StackScreenTitle,\n appendStackScreenTitlePropsToOptions,\n StackScreenBackButton,\n appendStackScreenBackButtonPropsToOptions,\n} from './screen';\nimport { StackToolbar, appendStackToolbarPropsToOptions, type StackToolbarProps } from './toolbar';\nimport { getAllChildrenOfType, isChildOfType } from '../../utils/children';\nimport { Screen } from '../../views/Screen';\n\nexport interface StackScreenProps extends PropsWithChildren {\n name?: string;\n options?: NativeStackNavigationOptions;\n}\n\nfunction extractBottomToolbars(children: ReactNode): React.ReactElement<StackToolbarProps>[] {\n return (\n getAllChildrenOfType(children, StackToolbar).filter(\n (child) => child.props.placement === 'bottom' || child.props.placement === undefined\n ) ?? []\n );\n}\n\nexport function StackScreen({ children, options, ...rest }: StackScreenProps) {\n // This component will only render when used inside a page.\n const updatedOptions = useMemo(\n () =>\n appendScreenStackPropsToOptions(options ?? {}, {\n children,\n }),\n [options, children]\n );\n\n const bottomToolbars = useMemo(() => extractBottomToolbars(children), [children]);\n\n return (\n <>\n <Screen {...rest} options={updatedOptions} />\n {/* Bottom toolbar is a native component rendered separately */}\n {bottomToolbars}\n </>\n );\n}\n\nStackScreen.Title = StackScreenTitle;\nStackScreen.BackButton = StackScreenBackButton;\n\nexport function appendScreenStackPropsToOptions(\n options: NativeStackNavigationOptions,\n props: StackScreenProps\n): NativeStackNavigationOptions {\n let updatedOptions = { ...options, ...props.options };\n\n function appendChildOptions(child: React.ReactElement, opts: NativeStackNavigationOptions) {\n if (isChildOfType(child, StackHeaderComponent)) {\n return appendStackHeaderPropsToOptions(opts, child.props);\n }\n\n if (isChildOfType(child, StackScreenTitle)) {\n return appendStackScreenTitlePropsToOptions(opts, child.props);\n }\n\n if (isChildOfType(child, StackScreenBackButton)) {\n return appendStackScreenBackButtonPropsToOptions(opts, child.props);\n }\n\n if (isChildOfType(child, StackToolbar)) {\n const placement = child.props.placement ?? 'bottom';\n\n if (placement === 'bottom') {\n throw new Error(\n `Stack.Toolbar with placement=\"bottom\" cannot be used inside Stack.Screen in _layout.tsx. Please move it to the page component.`\n );\n }\n\n return appendStackToolbarPropsToOptions(opts, child.props);\n }\n\n const typeName =\n typeof child.type === 'function'\n ? (child.type as { name?: string }).name || 'Unknown'\n : String(child.type);\n console.warn(`Unknown child element passed to Stack.Screen: ${typeName}`);\n return opts;\n }\n\n Children.forEach(props.children, (child) => {\n if (isValidElement(child)) {\n updatedOptions = appendChildOptions(child, updatedOptions);\n }\n });\n\n return updatedOptions;\n}\n"]}
1
+ {"version":3,"file":"StackScreen.js","sourceRoot":"","sources":["../../../src/layouts/stack-utils/StackScreen.tsx"],"names":[],"mappings":";AAAA,YAAY,CAAC;;;AA+Fb,0EA8CC;AA3ID,iCAAkG;AAElG,iEAA+F;AAC/F,qCAKkB;AAClB,uCAAmG;AACnG,mDAA2E;AAC3E,+CAA4C;AAO5C,SAAS,qBAAqB,CAAC,QAAmB;IAChD,OAAO,CACL,IAAA,+BAAoB,EAAC,QAAQ,EAAE,sBAAY,CAAC,CAAC,MAAM,CACjD,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,SAAS,KAAK,QAAQ,IAAI,KAAK,CAAC,KAAK,CAAC,SAAS,KAAK,SAAS,CACrF,IAAI,EAAE,CACR,CAAC;AACJ,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;G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KAAK,EAAE,8BAAqB,CAAC,EAAE,CAAC;YAChD,OAAO,IAAA,kDAAyC,EAAC,IAAI,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC;QACtE,CAAC;QAED,IAAI,IAAA,wBAAa,EAAC,KAAK,EAAE,sBAAY,CAAC,EAAE,CAAC;YACvC,MAAM,SAAS,GAAG,KAAK,CAAC,KAAK,CAAC,SAAS,IAAI,QAAQ,CAAC;YAEpD,IAAI,SAAS,KAAK,QAAQ,EAAE,CAAC;gBAC3B,MAAM,IAAI,KAAK,CACb,gIAAgI,CACjI,CAAC;YACJ,CAAC;YAED,OAAO,IAAA,0CAAgC,EAAC,IAAI,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC;QAC7D,CAAC;QAED,MAAM,QAAQ,GACZ,OAAO,KAAK,CAAC,IAAI,KAAK,UAAU;YAC9B,CAAC,CAAE,KAAK,CAAC,IAA0B,CAAC,IAAI,IAAI,SAAS;YACrD,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;QACzB,OAAO,CAAC,IAAI,CAAC,iDAAiD,QAAQ,EAAE,CAAC,CAAC;QAC1E,OAAO,IAAI,CAAC;IACd,CAAC;IAED,gBAAQ,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE,EAAE;QACzC,IAAI,IAAA,sBAAc,EAAC,KAAK,CAAC,EAAE,CAAC;YAC1B,cAAc,GAAG,kBAAkB,CAAC,KAAK,EAAE,cAAc,CAAC,CAAC;QAC7D,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,OAAO,cAAc,CAAC;AACxB,CAAC","sourcesContent":["'use client';\nimport { NativeStackNavigationOptions } from '@react-navigation/native-stack';\nimport { Children, isValidElement, useMemo, type PropsWithChildren, type ReactNode } from 'react';\n\nimport { StackHeaderComponent, appendStackHeaderPropsToOptions } from './StackHeaderComponent';\nimport {\n StackScreenTitle,\n appendStackScreenTitlePropsToOptions,\n StackScreenBackButton,\n appendStackScreenBackButtonPropsToOptions,\n} from './screen';\nimport { StackToolbar, appendStackToolbarPropsToOptions, type StackToolbarProps } from './toolbar';\nimport { getAllChildrenOfType, isChildOfType } from '../../utils/children';\nimport { Screen } from '../../views/Screen';\n\nexport interface StackScreenProps extends PropsWithChildren {\n name?: string;\n options?: NativeStackNavigationOptions;\n}\n\nfunction extractBottomToolbars(children: ReactNode): React.ReactElement<StackToolbarProps>[] {\n return (\n getAllChildrenOfType(children, StackToolbar).filter(\n (child) => child.props.placement === 'bottom' || child.props.placement === undefined\n ) ?? []\n );\n}\n\n/**\n * Component used to define a screen in a native stack navigator.\n *\n * Can be used in the `_layout.tsx` files, or directly in page components.\n *\n * When configuring header inside page components, prefer using `Stack.Toolbar`, `Stack.Header` and `Stack.Screen.*` components.\n *\n * @example\n * ```tsx app/_layout.tsx\n * import { Stack } from 'expo-router';\n *\n * export default function Layout() {\n * return (\n * <Stack>\n * <Stack.Screen\n * name=\"home\"\n * options={{ title: 'Home' }}\n * />\n * </Stack>\n * );\n * }\n * ```\n *\n * @example\n * ```tsx app/home.tsx\n * import { Stack } from 'expo-router';\n *\n * export default function HomePage() {\n * return (\n * <>\n * <Stack.Screen\n * options={{ headerTransparent: true }}\n * />\n * <Stack.Screen.Title>Welcome Home</Stack.Screen.Title>\n * // Page content\n * </>\n * );\n * }\n * ```\n */\nexport const StackScreen = Object.assign(\n function StackScreen({ children, options, ...rest }: StackScreenProps) {\n // This component will only render when used inside a page.\n const updatedOptions = useMemo(\n () =>\n appendScreenStackPropsToOptions(options ?? {}, {\n children,\n }),\n [options, children]\n );\n\n const bottomToolbars = useMemo(() => extractBottomToolbars(children), [children]);\n\n return (\n <>\n <Screen {...rest} options={updatedOptions} />\n {/* Bottom toolbar is a native component rendered separately */}\n {bottomToolbars}\n </>\n );\n },\n {\n Title: StackScreenTitle,\n BackButton: StackScreenBackButton,\n }\n);\n\nexport function appendScreenStackPropsToOptions(\n options: NativeStackNavigationOptions,\n props: StackScreenProps\n): NativeStackNavigationOptions {\n let updatedOptions = { ...options, ...props.options };\n\n function appendChildOptions(child: React.ReactElement, opts: NativeStackNavigationOptions) {\n if (isChildOfType(child, StackHeaderComponent)) {\n return appendStackHeaderPropsToOptions(opts, child.props);\n }\n\n if (isChildOfType(child, StackScreenTitle)) {\n return appendStackScreenTitlePropsToOptions(opts, child.props);\n }\n\n if (isChildOfType(child, StackScreenBackButton)) {\n return appendStackScreenBackButtonPropsToOptions(opts, child.props);\n }\n\n if (isChildOfType(child, StackToolbar)) {\n const placement = child.props.placement ?? 'bottom';\n\n if (placement === 'bottom') {\n throw new Error(\n `Stack.Toolbar with placement=\"bottom\" cannot be used inside Stack.Screen in _layout.tsx. Please move it to the page component.`\n );\n }\n\n return appendStackToolbarPropsToOptions(opts, child.props);\n }\n\n const typeName =\n typeof child.type === 'function'\n ? (child.type as { name?: string }).name || 'Unknown'\n : String(child.type);\n console.warn(`Unknown child element passed to Stack.Screen: ${typeName}`);\n return opts;\n }\n\n Children.forEach(props.children, (child) => {\n if (isValidElement(child)) {\n updatedOptions = appendChildOptions(child, updatedOptions);\n }\n });\n\n return updatedOptions;\n}\n"]}
@@ -65,12 +65,14 @@ export interface StackToolbarButtonProps {
65
65
  * Icon to display in the button.
66
66
  *
67
67
  * Can be a string representing an SFSymbol or an image source.
68
+ *
69
+ * > **Note**: When used in `placement="bottom"`, only string SFSymbols are supported. Use the `image` prop to provide custom images.
68
70
  */
69
71
  icon?: StackHeaderItemSharedProps['icon'];
70
72
  /**
71
73
  * Image to display in the button.
72
74
  *
73
- * > **Note**: This prop is only supported in `Stack.Toolbar.Bottom`.
75
+ * > **Note**: This prop is only supported in toolbar with `placement="bottom"`.
74
76
  */
75
77
  image?: ImageRef;
76
78
  onPress?: () => void;
@@ -1 +1 @@
1
- {"version":3,"file":"StackToolbarButton.d.ts","sourceRoot":"","sources":["../../../../src/layouts/stack-utils/toolbar/StackToolbarButton.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,2BA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