Initial commit: code as received (Create/Anything export)
Insole-production time tracker exported from the Create/Anything AI platform. Baseline snapshot before any reverse-engineering or cleanup. - apps/mobile: Expo Router app (iOS/Android/web), the only workspace - publisher/: standalone OpenNext/AWS deploy tooling for the web side - Backend (/api/tasks, /api/logs + DB) lives remotely, not in this repo
This commit is contained in:
24
apps/mobile/polyfills/web/tabbar.web.tsx
Normal file
24
apps/mobile/polyfills/web/tabbar.web.tsx
Normal file
@@ -0,0 +1,24 @@
|
||||
import { Tabs as ExpoTabs } from 'expo-router/build/layouts/Tabs';
|
||||
import { merge } from 'lodash';
|
||||
import { forwardRef } from 'react';
|
||||
import { Platform } from 'react-native';
|
||||
export const BASE_TAB_BAR_HEIGHT = Platform.OS === 'ios' ? 49 : 56;
|
||||
|
||||
export const Tabs = forwardRef((props: any, ref: any) => {
|
||||
const isInIframe = typeof window !== 'undefined' ? window.self !== window.top : false;
|
||||
const height = props.screenOptions.tabBarStyle?.height || (BASE_TAB_BAR_HEIGHT + (isInIframe ? 34 : 0));
|
||||
|
||||
return (
|
||||
<ExpoTabs
|
||||
{...props}
|
||||
screenOptions={merge(props.screenOptions, {
|
||||
tabBarStyle: merge(props.screenOptions.tabBarStyle, { height }),
|
||||
})}
|
||||
ref={ref}
|
||||
/>
|
||||
);
|
||||
});
|
||||
|
||||
(Tabs as any).Screen = ExpoTabs.Screen;
|
||||
|
||||
export default Tabs;
|
||||
Reference in New Issue
Block a user