From e167239f4f7eacd4afc3d5aadca09967ab8f8628 Mon Sep 17 00:00:00 2001 From: dan Date: Thu, 2 Jul 2026 14:46:36 +0000 Subject: [PATCH] fix: nativewind home layout, TabBarIcon types, rerun-hint quoting - Give EditScreenInfo's outer View w-full: ScreenContent centers its children, so the unconstrained View sized to the text's intrinsic single-line width and the description clipped at the screen edge. - Inset the Show Details button with mx-6; the Container only has safe-area padding, which is zero horizontally on iPhones, so the stretched button touched the screen edges. - Type TabBarIcon color as ColorValue: Expo Router's Tabs on SDK 56 passes ColorValue to tabBarIcon, which fails typechecking against color: string. @expo/vector-icons accepts string | OpaqueColorValue. - Only quote the rerun-hint project name when it contains characters that actually need shell quoting. --- .changeset/nativewind-home-layout.md | 6 ++++++ cli/src/templates/base/components/TabBarIcon.tsx.ejs | 4 ++-- .../templates/packages/expo-router/stack/app/index.tsx.ejs | 2 ++ .../packages/nativewind/components/EditScreenInfo.tsx.ejs | 3 ++- cli/src/utilities/systemCommand.ts | 5 +++++ 5 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 .changeset/nativewind-home-layout.md diff --git a/.changeset/nativewind-home-layout.md b/.changeset/nativewind-home-layout.md new file mode 100644 index 00000000..a64bc714 --- /dev/null +++ b/.changeset/nativewind-home-layout.md @@ -0,0 +1,6 @@ +--- +'create-expo-stack': patch +'rn-new': patch +--- + +Fix Nativewind template layout: inset the Show Details button from the screen edges, constrain EditScreenInfo so its description text wraps instead of clipping, type TabBarIcon color as ColorValue for SDK 56 tabs, and only quote the rerun-hint project name when it needs shell quoting. diff --git a/cli/src/templates/base/components/TabBarIcon.tsx.ejs b/cli/src/templates/base/components/TabBarIcon.tsx.ejs index e75c9d3f..7da59c5d 100644 --- a/cli/src/templates/base/components/TabBarIcon.tsx.ejs +++ b/cli/src/templates/base/components/TabBarIcon.tsx.ejs @@ -1,9 +1,9 @@ import FontAwesome from '@expo/vector-icons/FontAwesome'; -import { StyleSheet } from 'react-native'; +import { ColorValue, StyleSheet } from 'react-native'; export const TabBarIcon = (props: { name: React.ComponentProps['name']; - color: string; + color: ColorValue; }) => { return ; }; diff --git a/cli/src/templates/packages/expo-router/stack/app/index.tsx.ejs b/cli/src/templates/packages/expo-router/stack/app/index.tsx.ejs index 7590c81f..5f78480d 100644 --- a/cli/src/templates/packages/expo-router/stack/app/index.tsx.ejs +++ b/cli/src/templates/packages/expo-router/stack/app/index.tsx.ejs @@ -33,6 +33,8 @@ export default function Home() { <% if (props.stylingPackage?.name === "unistyles") { %>