Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions apps/expo/app/(app)/(tabs)/(home)/index.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'use client';

import type { LargeTitleSearchBarRef, ListDataItem } from '@packrat/ui/nativewindui';
import type { LargeTitleSearchBarMethods, ListDataItem } from '@packrat/ui/nativewindui';
import {
LargeTitleHeader,
List,
Expand Down Expand Up @@ -167,7 +167,7 @@ function DemoIcon() {

export default function DashboardScreen() {
const [searchValue, setSearchValue] = useState('');
const searchBarRef = useRef<LargeTitleSearchBarRef>(null);
const searchBarRef = useRef<LargeTitleSearchBarMethods>(null);
const { t } = useTranslation();

const dashboardLayout = useRef([
Expand Down
6 changes: 3 additions & 3 deletions apps/expo/app/(app)/(tabs)/profile/index.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { AlertRef } from '@packrat/ui/nativewindui';
import type { AlertMethods } from '@packrat/ui/nativewindui';
import {
ActivityIndicator,
Alert,
Expand Down Expand Up @@ -140,7 +140,7 @@ function ListFooterComponent() {
const { colors } = useColorScheme();
const { t } = useTranslation();

const alertRef = useRef<AlertRef>(null);
const alertRef = useRef<AlertMethods>(null);
const [isSigningOut, setIsSigningOut] = useState(false);

const handleSignOut = async () => {
Expand All @@ -150,7 +150,7 @@ function ListFooterComponent() {
alertRef.current?.alert({
title: t('auth.loggedOut'),
message: t('auth.loggedOutMessage'),
materialIcon: { name: 'check-circle-outline', color: colors.green },
materialIcon: { name: 'check-circle-outline', color: 'rgb(48, 164, 108)' },
buttons: [
{
text: t('auth.stayLoggedOut'),
Expand Down
2 changes: 1 addition & 1 deletion apps/expo/app/(app)/(tabs)/profile/name.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export default function NameScreen() {
contentContainerStyle={{ paddingBottom: insets.bottom }}
>
<Form className="gap-5 px-4 pt-8">
<FormSection materialIconProps={{ name: 'person-outline' }}>
<FormSection materialIconProps={{ name: 'account-outline' }}>
<FormItem>
<TextField
textContentType="givenName"
Expand Down
6 changes: 3 additions & 3 deletions apps/expo/app/(app)/messages/chat.android.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -238,17 +238,17 @@ const CONTEXT_MENU_ITEMS = [
createDropdownItem({
actionKey: 'reply',
title: 'Reply',
icon: { name: 'arrow-left-bold-outline' },
icon: { name: 'arrowshape.left' },
}),
createDropdownItem({
actionKey: 'sticker',
title: 'Sticker',
icon: { name: 'plus-box-outline' },
icon: { name: 'plus.app' },
}),
createDropdownItem({
actionKey: 'copy',
title: 'Copy',
icon: { name: 'clipboard-outline' },
icon: { name: 'clipboard' },
}),
];

Expand Down
12 changes: 6 additions & 6 deletions apps/expo/app/(app)/messages/chat.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { ContextMenuRef } from '@packrat/ui/nativewindui';
import type { ContextMenuMethods } from '@packrat/ui/nativewindui';
import {
Avatar,
AvatarFallback,
Expand Down Expand Up @@ -329,17 +329,17 @@ const CONTEXT_MENU_ITEMS = [
createContextItem({
actionKey: 'reply',
title: 'Reply',
icon: { name: 'arrow-left-bold-outline' },
icon: { name: 'arrowshape.left' },
}),
createContextItem({
actionKey: 'sticker',
title: 'Sticker',
icon: { name: 'plus-box-outline' },
icon: { name: 'plus.app' },
}),
createContextItem({
actionKey: 'copy',
title: 'Copy',
icon: { name: 'clipboard-outline' },
icon: { name: 'clipboard' },
}),
];

Expand All @@ -352,8 +352,8 @@ function ChatBubble({
isSameNextSender: boolean;
translateX: SharedValue<number>;
}) {
const contextMenuRef = React.useRef<ContextMenuRef>(null);
const contextMenuRef2 = React.useRef<ContextMenuRef>(null);
const contextMenuRef = React.useRef<ContextMenuMethods>(null);
const contextMenuRef2 = React.useRef<ContextMenuMethods>(null);
const { colors } = useColorScheme();
const rootStyle = useAnimatedStyle(() => {
return {
Expand Down
5 changes: 2 additions & 3 deletions apps/expo/app/(app)/messages/conversations.android.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ export default function ConversationsAndroidScreen() {
>
<Toolbar
leftView={<View className="flex-1" />}
rightView={<ToolbarCTA className="h-8 w-8" icon={{ name: 'pencil-box-outline' }} />}
rightView={<ToolbarCTA className="h-8 w-8" icon={{ name: 'square.and.pencil' }} />}
iosBlurIntensity={30}
/>
</Animated.View>
Expand Down Expand Up @@ -114,14 +114,13 @@ function LeftView() {
createDropdownItem({
actionKey: 'go-home',
title: 'Go Home',
icon: { name: 'home' },
icon: { name: 'house.fill' },
}),
createDropdownItem({
actionKey: 'toggle-theme',
title: 'Toggle Theme',
icon: {
name: isDarkColorScheme ? 'moon.stars' : 'sun.min',
Comment on lines +117 to 123
namingScheme: 'sfSymbol',
},
}),
];
Expand Down
9 changes: 4 additions & 5 deletions apps/expo/app/(app)/messages/conversations.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -113,19 +113,18 @@ function LeftView({
createDropdownItem({
actionKey: 'go-home',
title: 'Go Home',
icon: { name: 'home' },
icon: { name: 'house.fill' },
}),
createDropdownItem({
actionKey: 'select-messages',
title: 'Select messages',
icon: { name: 'checkmark.circle', namingScheme: 'sfSymbol' },
icon: { name: 'checkmark.circle' },
}),
createDropdownItem({
actionKey: 'toggle-theme',
title: 'Toggle Theme',
icon: {
name: isDarkColorScheme ? 'moon.stars' : 'sun.min',
namingScheme: 'sfSymbol',
},
}),
];
Expand Down Expand Up @@ -220,12 +219,12 @@ const CONTEXT_MENU_ITEMS = [
createContextItem({
actionKey: 'hide-alerts',
title: 'Hide Alerts',
icon: { name: 'bell-outline' },
icon: { name: 'bell' },
}),
createContextItem({
actionKey: 'delete',
title: 'Delete',
icon: { name: 'trash-can-outline', color: 'red' },
icon: { name: 'trash', color: 'red' },
destructive: true,
}),
];
Expand Down
4 changes: 2 additions & 2 deletions apps/expo/app/(app)/settings/index.android.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,12 @@ export default function SettingsAndroidStyleScreen() {
/>
)}
<List
rootStyle={Platform.select({
style={Platform.select({
ios: undefined,
default: { paddingTop: insets.top },
})}
stickyHeaderIndices={Platform.select({ ios: undefined, default: [1] })}
rootClassName="bg-background ios:bg-background"
className="bg-background ios:bg-background"
contentContainerClassName="pt-4 ios:pt-0"
contentInsetAdjustmentBehavior="automatic"
variant="full-width"
Expand Down
2 changes: 1 addition & 1 deletion apps/expo/app/(app)/shopping-list.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ function ShoppingItemCard({ item }: { item: (typeof SHOPPING_LIST)[0] }) {

{item.purchased && (
<View className="mt-3 flex-row items-center gap-1">
<Icon name="check-circle" size={16} color={colors.green} />
<Icon name="check-circle" size={16} color={'rgb(48, 164, 108)'} />
<Text variant="footnote" className="text-green-500">
{t('shopping.purchased')}
Comment on lines 145 to 149
</Text>
Expand Down
6 changes: 3 additions & 3 deletions apps/expo/app/_layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { Stack } from 'expo-router';
import { StatusBar } from 'expo-status-bar';
import '../global.css';

import { Alert, type AlertRef } from '@packrat-ai/nativewindui';
import { Alert, type AlertMethods } from '@packrat-ai/nativewindui';
import * as Sentry from '@sentry/react-native';
import { userStore } from 'expo-app/features/auth/store';
import { useColorScheme, useInitialAndroidBarSync } from 'expo-app/lib/hooks/useColorScheme';
Expand All @@ -29,12 +29,12 @@ export {
ErrorBoundary,
} from 'expo-router';

export let appAlert: React.RefObject<AlertRef | null>;
export let appAlert: React.RefObject<AlertMethods | null>;

function RootLayout() {
useInitialAndroidBarSync();

appAlert = useRef<AlertRef>(null);
appAlert = useRef<AlertMethods>(null);

const { colorScheme, isDarkColorScheme } = useColorScheme();

Expand Down
4 changes: 2 additions & 2 deletions apps/expo/app/auth/(create-account)/credentials.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { AlertRef } from '@packrat/ui/nativewindui';
import type { AlertMethods } from '@packrat/ui/nativewindui';
import {
AlertAnchor,
Button,
Expand Down Expand Up @@ -109,7 +109,7 @@ export default function CredentialsScreen() {
const [focusedTextField, setFocusedTextField] = React.useState<
'email' | 'password' | 'confirm-password' | null
>(null);
const alertRef = React.useRef<AlertRef>(null);
const alertRef = React.useRef<AlertMethods>(null);

// Get data from previous screen
const params = useLocalSearchParams<{
Expand Down
4 changes: 2 additions & 2 deletions apps/expo/app/auth/(login)/forgot-password.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { AlertRef } from '@packrat/ui/nativewindui';
import type { AlertMethods } from '@packrat/ui/nativewindui';
import {
AlertAnchor,
Button,
Expand Down Expand Up @@ -32,7 +32,7 @@ const emailSchema = z.object({
export default function ForgotPasswordScreen() {
const insets = useSafeAreaInsets();
const { t } = useTranslation();
const alertRef = React.useRef<AlertRef>(null);
const alertRef = React.useRef<AlertMethods>(null);
const [isLoading, setIsLoading] = React.useState(false);
const { forgotPassword } = useAuthActions();
const needsReauth = useAtomValue(needsReauthAtom);
Expand Down
4 changes: 2 additions & 2 deletions apps/expo/app/auth/(login)/reset-password.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { AlertRef } from '@packrat/ui/nativewindui';
import type { AlertMethods } from '@packrat/ui/nativewindui';
import {
AlertAnchor,
Button,
Expand Down Expand Up @@ -107,7 +107,7 @@ export default function ResetPasswordScreen() {
const [focusedTextField, setFocusedTextField] = React.useState<
'password' | 'confirm-password' | null
>(null);
const alertRef = React.useRef<AlertRef>(null);
const alertRef = React.useRef<AlertMethods>(null);

// Get data from previous screen
const params = useLocalSearchParams<{
Expand Down
4 changes: 2 additions & 2 deletions apps/expo/app/auth/index.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { AlertRef } from '@packrat/ui/nativewindui';
import type { AlertMethods } from '@packrat/ui/nativewindui';
import { ActivityIndicator, AlertAnchor, Button, Text } from '@packrat/ui/nativewindui';
import AsyncStorage from '@react-native-async-storage/async-storage';
import { featureFlags } from 'expo-app/config';
Expand Down Expand Up @@ -27,7 +27,7 @@ type RouteParams = {
export default function AuthIndexScreen() {
const { signInWithGoogle, signInWithApple, isLoading } = useAuth();
const { t } = useTranslation();
const alertRef = React.useRef<AlertRef>(null);
const alertRef = React.useRef<AlertMethods>(null);
const {
redirectTo = '/',
showSignInCopy,
Expand Down
4 changes: 2 additions & 2 deletions apps/expo/app/auth/one-time-password.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { AlertRef } from '@packrat/ui/nativewindui';
import type { AlertMethods } from '@packrat/ui/nativewindui';
import { ActivityIndicator, AlertAnchor, Button, Text, TextField } from '@packrat/ui/nativewindui';
import { useHeaderHeight } from '@react-navigation/elements';
import { useAuthActions } from 'expo-app/features/auth/hooks/useAuthActions';
Expand Down Expand Up @@ -38,7 +38,7 @@ export default function OneTimePasswordScreen() {
const [codeValues, setCodeValues] = React.useState(Array(NUM_OF_CODE_CHARACTERS).fill(''));
const [errorIndexes, setErrorIndexes] = React.useState<number[]>([]);
const [isLoading, setIsLoading] = React.useState(false);
const alertRef = React.useRef<AlertRef>(null);
const alertRef = React.useRef<AlertMethods>(null);
const headerHeight = useHeaderHeight();
const params = useLocalSearchParams<{ email: string; mode: string }>();
const email = params.email || '';
Expand Down
6 changes: 3 additions & 3 deletions apps/expo/features/ai-packs/screens/AIPacksScreen.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import {
ActivityIndicator,
Alert,
type AlertRef,
type AlertMethods,
Button,
LargeTitleHeader,
Text,
Expand All @@ -20,7 +20,7 @@ import { useGeneratePacks } from '../hooks/useGeneratedPacks';
export function AIPacksScreen() {
const { colors } = useColorScheme();
const { t } = useTranslation();
const alertRef = useRef<AlertRef>(null);
const alertRef = useRef<AlertMethods>(null);
const { mutateAsync: generatePacks, isPending, generatedPacksFromStore } = useGeneratePacks();
const [packsModalVisible, setPacksModalVisible] = useState(false);
const router = useRouter();
Expand All @@ -35,7 +35,7 @@ export function AIPacksScreen() {
alertRef.current?.alert({
title: t('ai.packsGenerated'),
message: t('ai.successfullyGenerated', { count: packs.length }),
materialIcon: { name: 'backpack', color: colors.green },
materialIcon: { name: 'bag-personal', color: 'rgb(48, 164, 108)' },
buttons: [
{ text: t('ai.return'), onPress: () => {} },
{
Expand Down
2 changes: 1 addition & 1 deletion apps/expo/features/ai/components/WebSearchGenerativeUI.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ export function WebSearchGenerativeUI({ toolInvocation }: WebSearchGenerativeUIP
toolInvocation.output.data.sources.length > 0 && (
<View className="mb-6">
<View className="flex-row items-center mb-3">
<Icon name="link" size={16} color={colors.green} />
<Icon name="link" size={16} color={'rgb(48, 164, 108)'} />
<Text variant="caption1" className="uppercase tracking-wide">
{t('ai.tools.sources', {
count: toolInvocation.output.data.sources.length,
Expand Down
4 changes: 2 additions & 2 deletions apps/expo/features/auth/components/DeleteAccountButton.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { AlertRef } from '@packrat/ui/nativewindui';
import type { AlertMethods } from '@packrat/ui/nativewindui';
import { ActivityIndicator, Alert, Button, Text } from '@packrat/ui/nativewindui';
import { Icon } from '@roninoss/icons';
import { useAuth } from 'expo-app/features/auth/hooks/useAuth';
Expand All @@ -11,7 +11,7 @@ export function DeleteAccountButton() {
const { colors } = useColorScheme();
const { deleteAccount } = useAuth();
const { t } = useTranslation();
const alertRef = useRef<AlertRef>(null);
const alertRef = useRef<AlertMethods>(null);
const [isDeleting, setIsDeleting] = useState(false);

return (
Expand Down
2 changes: 1 addition & 1 deletion apps/expo/features/catalog/components/CatalogItemCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export function CatalogItemCard({ item, onPress }: CatalogItemCardProps) {
</View>
{item.ratingValue && (
<View className="flex-row items-center">
<Icon name="star" size={14} color={colors.yellow} />
<Icon name="star" size={14} color={'rgb(255, 204, 0)'} />
<Text className="ml-1 text-xs text-muted-foreground">
{item.ratingValue.toFixed(1)}
</Text>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export function CatalogItemSelectCard({ item, isSelected, onToggle }: CatalogIte
</View>
{item.ratingValue && (
<View className="flex-row items-center">
<Icon name="star" size={14} color={colors.yellow} />
<Icon name="star" size={14} color={'rgb(255, 204, 0)'} />
<Text className="ml-1 text-xs text-muted-foreground">
{item.ratingValue.toFixed(1)}
Comment on lines 56 to 60
</Text>
Expand Down
4 changes: 2 additions & 2 deletions apps/expo/features/catalog/components/ItemReviews.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export function ItemReviews({ reviews }: ItemReviewsProps) {
<View className="flex-row items-center">
{review.verified && (
<View className="mr-2 flex-row items-center">
<Icon name="check-circle-outline" size={14} color={colors.green} />
<Icon name="check-circle-outline" size={14} color={'rgb(48, 164, 108)'} />
<Text className="ml-1 text-xs text-green-900 dark:text-green-500">
{t('catalog.verified')}
</Text>
Expand All @@ -81,7 +81,7 @@ export function ItemReviews({ reviews }: ItemReviewsProps) {
key={star}
name={star <= review.rating ? 'star' : 'star-outline'}
size={14}
color={colors.yellow}
color={'rgb(255, 204, 0)'}
/>
))}
</View>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ export function CatalogItemDetailScreen() {
</View>
{item.ratingValue && (
<View className="flex-row items-center">
<Icon name="star" size={16} color={colors.yellow} />
<Icon name="star" size={16} color={'rgb(255, 204, 0)'} />
<Text className="ml-1 text-sm text-muted-foreground">
{item.ratingValue.toFixed(1)}
</Text>
Expand Down
Loading
Loading