Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | 854x 1769x 1769x | import type React from "react";
import { ScrollView } from "~components/scroll-view";
import type { ViewReactNode } from "~components/view";
import { View } from "~components/view";
export const PageWrapper: React.FC<{
wrapper?: React.FC<React.PropsWithChildren>;
children?: ViewReactNode;
}> = ({ wrapper: Wrapper, children }) => {
const slot = (
<View className="w-full max-w-screen-md gap-4 web:mx-auto">{children}</View>
);
return (
<ScrollView className="h-full p-2 md:p-4">
{Wrapper ? <Wrapper>{slot}</Wrapper> : slot}
{/* Placeholder for page content not to get under the menu */}
<View className="h-[72px]" />
</ScrollView>
);
};
|