create-expo-stack 2.20.0-next.ff2bed4 → 2.20.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.
- package/README.md +1 -3
- package/build/cli.js +3 -2
- package/build/commands/create-expo-stack.js +9 -30
- package/build/constants.js +4 -4
- package/build/templates/base/App.tsx.ejs +12 -51
- package/build/templates/base/app.json.ejs +1 -0
- package/build/templates/base/babel.config.js.ejs +13 -16
- package/build/templates/base/components/Button.tsx.ejs +1 -0
- package/build/templates/base/components/Container.tsx.ejs +1 -0
- package/build/templates/base/package.json.ejs +34 -67
- package/build/templates/base/tsconfig.json.ejs +12 -7
- package/build/templates/packages/expo-router/drawer/app/+not-found.tsx.ejs +19 -60
- package/build/templates/packages/expo-router/drawer/app/_layout.tsx.ejs +2 -41
- package/build/templates/packages/expo-router/stack/app/+not-found.tsx.ejs +34 -66
- package/build/templates/packages/expo-router/stack/app/_layout.tsx.ejs +15 -51
- package/build/templates/packages/expo-router/stack/app/details.tsx.ejs +37 -5
- package/build/templates/packages/expo-router/stack/app/index.tsx.ejs +34 -11
- package/build/templates/packages/expo-router/tabs/app/+not-found.tsx.ejs +21 -60
- package/build/templates/packages/expo-router/tabs/app/_layout.tsx.ejs +8 -48
- package/build/templates/packages/nativewind/global.css +3 -2
- package/build/templates/packages/nativewind/metro.config.js +3 -4
- package/build/templates/packages/nativewind/nativewind-env.d.ts +1 -3
- package/build/templates/packages/nativewind/tailwind.config.js.ejs +15 -0
- package/build/templates/packages/nativewindui/components/Container.tsx.ejs +1 -0
- package/build/templates/packages/nativewindui/components/EditScreenInfo.tsx.ejs +1 -1
- package/build/templates/packages/nativewindui/components/ScreenContent.tsx.ejs +1 -1
- package/build/templates/packages/nativewindui/components/nativewindui/Icon/Icon.ios.tsx.ejs +52 -0
- package/build/templates/packages/nativewindui/components/nativewindui/Icon/Icon.tsx.ejs +58 -0
- package/build/templates/packages/nativewindui/components/nativewindui/Icon/index.ts.ejs +16 -0
- package/build/templates/packages/nativewindui/components/nativewindui/Icon/types.ts.ejs +18 -0
- package/build/templates/packages/nativewindui/components/{ThemeToggle.tsx.ejs → nativewindui/ThemeToggle.tsx.ejs} +8 -10
- package/build/templates/packages/nativewindui/drawer/app/(drawer)/index.tsx.ejs +17 -19
- package/build/templates/packages/nativewindui/drawer/app/+not-found.tsx.ejs +4 -44
- package/build/templates/packages/nativewindui/drawer/app/_layout.tsx.ejs +2 -2
- package/build/templates/packages/nativewindui/drawer/app/modal.tsx.ejs +4 -4
- package/build/templates/packages/nativewindui/lib/useColorScheme.tsx.ejs +3 -37
- package/build/templates/packages/nativewindui/stack/app/+not-found.tsx.ejs +1 -1
- package/build/templates/packages/nativewindui/stack/app/_layout.tsx.ejs +17 -34
- package/build/templates/packages/nativewindui/stack/app/index.tsx.ejs +230 -275
- package/build/templates/packages/nativewindui/stack/app/modal.tsx.ejs +7 -7
- package/build/templates/packages/nativewindui/tabs/app/(tabs)/index.tsx.ejs +6 -7
- package/build/templates/packages/nativewindui/tabs/app/+not-found.tsx.ejs +0 -40
- package/build/templates/packages/nativewindui/theme/colors.ts.ejs +52 -0
- package/build/templates/packages/nativewindui/theme/index.ts.ejs +2 -2
- package/build/templates/packages/nativewindui/theme/with-opacity.ts.ejs +155 -0
- package/build/templates/packages/react-navigation/App.tsx.ejs +2 -42
- package/build/types/constants.d.ts +1 -1
- package/build/types/types.d.ts +3 -3
- package/build/types/utilities/configAnalytics.d.ts +2 -2
- package/build/types/utilities/validateProjectName.d.ts +2 -1
- package/build/types.js +1 -3
- package/build/utilities/clearNavigationPackages.js +2 -2
- package/build/utilities/clearStylingPackages.js +2 -2
- package/build/utilities/configAnalytics.js +5 -4
- package/build/utilities/configureProjectFiles.js +31 -68
- package/build/utilities/copyBaseAssets.js +3 -2
- package/build/utilities/generateNWUI.js +8 -7
- package/build/utilities/generateProjectFiles.js +4 -9
- package/build/utilities/getPackageManager.js +6 -5
- package/build/utilities/printOutput.js +5 -16
- package/build/utilities/renderTitle.js +3 -2
- package/build/utilities/runCLI.js +15 -17
- package/build/utilities/runEasConfigure.js +3 -2
- package/build/utilities/runIgnite.js +3 -2
- package/build/utilities/showHelp.js +3 -4
- package/build/utilities/systemCommand.js +3 -3
- package/build/utilities/usePackage.js +3 -2
- package/build/utilities/validateProjectName.js +3 -2
- package/package.json +74 -71
- package/build/templates/packages/nativewind/postcss.config.mjs +0 -5
- package/build/templates/packages/nativewindui/components/BackButton.tsx.ejs +0 -23
- package/build/templates/packages/nativewindui/components/Button.tsx.ejs +0 -41
- package/build/templates/packages/nativewindui/lib/useHeaderSearchBar.tsx.ejs +0 -31
- package/build/templates/packages/restyle/components/BackButton.tsx.ejs +0 -15
- package/build/templates/packages/restyle/components/Button.tsx.ejs +0 -40
- package/build/templates/packages/restyle/components/Container.tsx.ejs +0 -6
- package/build/templates/packages/restyle/components/EditScreenInfo.tsx.ejs +0 -29
- package/build/templates/packages/restyle/components/ScreenContent.tsx.ejs +0 -21
- package/build/templates/packages/restyle/theme/Box.tsx.ejs +0 -6
- package/build/templates/packages/restyle/theme/Text.tsx.ejs +0 -6
- package/build/templates/packages/restyle/theme/index.ts.ejs +0 -6
- package/build/templates/packages/restyle/theme/theme.ts.ejs +0 -67
- package/build/templates/packages/tamagui/components/BackButton.tsx.ejs +0 -19
- package/build/templates/packages/tamagui/components/Button.tsx.ejs +0 -18
- package/build/templates/packages/tamagui/components/Container.tsx.ejs +0 -6
- package/build/templates/packages/tamagui/components/EditScreenInfo.tsx.ejs +0 -29
- package/build/templates/packages/tamagui/components/ScreenContent.tsx.ejs +0 -23
- package/build/templates/packages/tamagui/tamagui.config.ts.ejs +0 -130
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { Icon } from '@roninoss/icons';
|
|
2
1
|
import { StatusBar } from 'expo-status-bar';
|
|
3
2
|
import { Linking, Platform, View } from 'react-native';
|
|
4
3
|
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
4
|
+
import { Icon } from '@/components/nativewindui/Icon';
|
|
5
|
+
import { Text } from '@/components/nativewindui/Text';
|
|
6
|
+
import { useColorScheme } from '@/lib/useColorScheme';
|
|
7
7
|
|
|
8
8
|
export default function ModalScreen() {
|
|
9
9
|
const { colors, colorScheme } = useColorScheme();
|
|
@@ -12,10 +12,10 @@ export default function ModalScreen() {
|
|
|
12
12
|
<StatusBar
|
|
13
13
|
style={Platform.OS === 'ios' ? 'light' : colorScheme === 'dark' ? 'light' : 'dark'}
|
|
14
14
|
/>
|
|
15
|
-
<View className="
|
|
16
|
-
<Icon name="
|
|
15
|
+
<View className="pb-safe items-center justify-center gap-1 px-12 flex-1">
|
|
16
|
+
<Icon name="doc.badge.plus" size={42} color={colors.grey} />
|
|
17
17
|
<Text variant="title3" className="pb-1 text-center font-semibold">
|
|
18
|
-
|
|
18
|
+
NativewindUI
|
|
19
19
|
</Text>
|
|
20
20
|
<Text color="tertiary" variant="subhead" className="pb-4 text-center">
|
|
21
21
|
You can install any of the free components from the{' '}
|
|
@@ -23,7 +23,7 @@ export default function ModalScreen() {
|
|
|
23
23
|
onPress={() => Linking.openURL('https://nativewindui.com')}
|
|
24
24
|
variant="subhead"
|
|
25
25
|
className="text-primary">
|
|
26
|
-
|
|
26
|
+
NativewindUI
|
|
27
27
|
</Text>
|
|
28
28
|
{' website.'}
|
|
29
29
|
</Text>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Stack } from 'expo-router';
|
|
2
2
|
import { useHeaderHeight } from '@react-navigation/elements';
|
|
3
|
-
import {
|
|
3
|
+
import { FlashList } from '@shopify/flash-list';
|
|
4
4
|
import { cssInterop } from 'nativewind';
|
|
5
5
|
import * as React from 'react';
|
|
6
6
|
import {
|
|
@@ -72,7 +72,7 @@ export default function Home() {
|
|
|
72
72
|
<>
|
|
73
73
|
<Stack.Screen options={{ title: 'Tab One' }} />
|
|
74
74
|
<Container>
|
|
75
|
-
<
|
|
75
|
+
<FlashList
|
|
76
76
|
contentInsetAdjustmentBehavior="automatic"
|
|
77
77
|
keyboardShouldPersistTaps="handled"
|
|
78
78
|
data={data}
|
|
@@ -83,14 +83,13 @@ export default function Home() {
|
|
|
83
83
|
ItemSeparatorComponent={renderItemSeparator}
|
|
84
84
|
renderItem={renderItem}
|
|
85
85
|
ListEmptyComponent={COMPONENTS.length === 0 ? ListEmptyComponent : undefined}
|
|
86
|
-
recycleItems
|
|
87
86
|
/>
|
|
88
87
|
</Container>
|
|
89
88
|
</>
|
|
90
89
|
);
|
|
91
90
|
}
|
|
92
91
|
|
|
93
|
-
cssInterop(
|
|
92
|
+
cssInterop(FlashList, {
|
|
94
93
|
className: 'style',
|
|
95
94
|
contentContainerClassName: 'contentContainerStyle',
|
|
96
95
|
});
|
|
@@ -125,7 +124,7 @@ function ListEmptyComponent() {
|
|
|
125
124
|
variant='subhead'
|
|
126
125
|
className='text-primary'
|
|
127
126
|
>
|
|
128
|
-
|
|
127
|
+
NativewindUI
|
|
129
128
|
</Text>
|
|
130
129
|
{' website.'}
|
|
131
130
|
</Text>
|
|
@@ -467,7 +466,7 @@ const COMPONENTS: ComponentItem[] = [
|
|
|
467
466
|
onPress={async () => {
|
|
468
467
|
try {
|
|
469
468
|
const result = await Share.share({
|
|
470
|
-
message: '
|
|
469
|
+
message: 'NativewindUI | Familiar interface, native feel.',
|
|
471
470
|
});
|
|
472
471
|
if (result.action === Share.sharedAction) {
|
|
473
472
|
if (result.activityType) {
|
|
@@ -524,7 +523,7 @@ const COMPONENTS: ComponentItem[] = [
|
|
|
524
523
|
const TWITTER_AVATAR_URI = 'https://pbs.twimg.com/profile_images/1782428433898708992/1voyv4_A_400x400.jpg';
|
|
525
524
|
return (
|
|
526
525
|
<View className='items-center'>
|
|
527
|
-
<Avatar alt="
|
|
526
|
+
<Avatar alt="NativewindUI Avatar">
|
|
528
527
|
<AvatarImage source={{ uri: TWITTER_AVATAR_URI }} />
|
|
529
528
|
<AvatarFallback>
|
|
530
529
|
<Text>NUI</Text>
|
|
@@ -6,18 +6,9 @@ import { Link, Stack } from 'expo-router';
|
|
|
6
6
|
import { Text, View } from 'react-native';
|
|
7
7
|
<% } else if (props.stylingPackage?.name === "stylesheet") { %>
|
|
8
8
|
import { StyleSheet, Text, View } from 'react-native';
|
|
9
|
-
<% } else if (props.stylingPackage?.name === "tamagui") { %>
|
|
10
|
-
import { YStack } from "tamagui";
|
|
11
|
-
import { Container, Main, Subtitle, Title } from "../tamagui.config";
|
|
12
|
-
<% } else if (props.stylingPackage?.name === "restyle") { %>
|
|
13
|
-
import { Box, Text, makeStyles } from 'theme';
|
|
14
9
|
<% } %>
|
|
15
10
|
|
|
16
11
|
export default function NotFoundScreen() {
|
|
17
|
-
<% if (props.stylingPackage?.name === "restyle") { %>
|
|
18
|
-
const styles = useStyles();
|
|
19
|
-
<% } %>
|
|
20
|
-
|
|
21
12
|
<% if (props.stylingPackage?.name === "unistyles") {%>
|
|
22
13
|
const { styles } = useStyles(stylesheet);
|
|
23
14
|
<% } %>
|
|
@@ -33,30 +24,6 @@ export default function NotFoundScreen() {
|
|
|
33
24
|
</Link>
|
|
34
25
|
</View>
|
|
35
26
|
</>
|
|
36
|
-
<% } else if (props.stylingPackage?.name === "tamagui") {%>
|
|
37
|
-
<Container>
|
|
38
|
-
<Stack.Screen options={{ title: "Oops!" }} />
|
|
39
|
-
<Main>
|
|
40
|
-
<YStack>
|
|
41
|
-
<Title>{"This screen doesn't exist."}</Title>
|
|
42
|
-
<Link href="/">
|
|
43
|
-
<Subtitle>Go to home screen!</Subtitle>
|
|
44
|
-
</Link>
|
|
45
|
-
</YStack>
|
|
46
|
-
</Main>
|
|
47
|
-
</Container>
|
|
48
|
-
<% } else if (props.stylingPackage?.name === "restyle") {%>
|
|
49
|
-
<>
|
|
50
|
-
<Stack.Screen options={{ title: 'Oops!' }} />
|
|
51
|
-
<Box flex={1} justifyContent="center" alignItems="center" padding="ml_24">
|
|
52
|
-
<Text variant="title">{"This screen doesn't exist."}</Text>
|
|
53
|
-
<Link href="/" style={styles.link}>
|
|
54
|
-
<Text variant="body" color="blue">
|
|
55
|
-
Go to home screen!
|
|
56
|
-
</Text>
|
|
57
|
-
</Link>
|
|
58
|
-
</Box>
|
|
59
|
-
</>
|
|
60
27
|
<% } else { %>
|
|
61
28
|
<>
|
|
62
29
|
<Stack.Screen options={{ title: "Oops!" }} />
|
|
@@ -120,11 +87,4 @@ export default function NotFoundScreen() {
|
|
|
120
87
|
color: '#2e78b7',
|
|
121
88
|
},
|
|
122
89
|
});
|
|
123
|
-
<% } else if (props.stylingPackage?.name === "restyle") { %>
|
|
124
|
-
const useStyles = makeStyles((theme) => ({
|
|
125
|
-
link: {
|
|
126
|
-
marginTop: theme.spacing.m_16,
|
|
127
|
-
paddingVertical: theme.spacing.m_16,
|
|
128
|
-
},
|
|
129
|
-
}));
|
|
130
90
|
<% } %>
|
|
@@ -14,8 +14,21 @@ const IOS_SYSTEM_COLORS = {
|
|
|
14
14
|
foreground: 'rgb(0, 0, 0)',
|
|
15
15
|
root: 'rgb(255, 255, 255)',
|
|
16
16
|
card: 'rgb(255, 255, 255)',
|
|
17
|
+
cardForeground: 'rgb(8, 28, 30)',
|
|
18
|
+
popover: 'rgb(230, 230, 235)',
|
|
19
|
+
popoverForeground: 'rgb(0, 0, 0)',
|
|
17
20
|
destructive: 'rgb(255, 56, 43)',
|
|
18
21
|
primary: 'rgb(0, 123, 254)',
|
|
22
|
+
primaryForeground: 'rgb(255, 255, 255)',
|
|
23
|
+
secondary: 'rgb(45, 175, 231)',
|
|
24
|
+
secondaryForeground: 'rgb(255, 255, 255)',
|
|
25
|
+
muted: 'rgb(175, 176, 180)',
|
|
26
|
+
mutedForeground: 'rgb(142, 142, 147)',
|
|
27
|
+
accent: 'rgb(255, 40, 84)',
|
|
28
|
+
accentForeground: 'rgb(255, 255, 255)',
|
|
29
|
+
border: 'rgb(230, 230, 235)',
|
|
30
|
+
input: 'rgb(210, 210, 215)',
|
|
31
|
+
ring: 'rgb(230, 230, 235)',
|
|
19
32
|
},
|
|
20
33
|
dark: {
|
|
21
34
|
grey6: 'rgb(21, 21, 24)',
|
|
@@ -28,8 +41,21 @@ const IOS_SYSTEM_COLORS = {
|
|
|
28
41
|
foreground: 'rgb(255, 255, 255)',
|
|
29
42
|
root: 'rgb(0, 0, 0)',
|
|
30
43
|
card: 'rgb(28, 28, 30)',
|
|
44
|
+
cardForeground: 'rgb(255, 255, 255)',
|
|
45
|
+
popover: 'rgb(40, 40, 42)',
|
|
46
|
+
popoverForeground: 'rgb(255, 255, 255)',
|
|
31
47
|
destructive: 'rgb(254, 67, 54)',
|
|
32
48
|
primary: 'rgb(3, 133, 255)',
|
|
49
|
+
primaryForeground: 'rgb(255, 255, 255)',
|
|
50
|
+
secondary: 'rgb(100, 211, 254)',
|
|
51
|
+
secondaryForeground: 'rgb(255, 255, 255)',
|
|
52
|
+
muted: 'rgb(70, 70, 73)',
|
|
53
|
+
mutedForeground: 'rgb(142, 142, 147)',
|
|
54
|
+
accent: 'rgb(255, 52, 95)',
|
|
55
|
+
accentForeground: 'rgb(255, 255, 255)',
|
|
56
|
+
border: 'rgb(40, 40, 42)',
|
|
57
|
+
input: 'rgb(55, 55, 57)',
|
|
58
|
+
ring: 'rgb(40, 40, 42)',
|
|
33
59
|
},
|
|
34
60
|
} as const;
|
|
35
61
|
|
|
@@ -47,8 +73,21 @@ const ANDROID_COLORS = {
|
|
|
47
73
|
foreground: 'rgb(0, 0, 0)',
|
|
48
74
|
root: 'rgb(255, 255, 255)',
|
|
49
75
|
card: 'rgb(255, 255, 255)',
|
|
76
|
+
cardForeground: 'rgb(24, 28, 35)',
|
|
77
|
+
popover: 'rgb(215, 217, 228)',
|
|
78
|
+
popoverForeground: 'rgb(0, 0, 0)',
|
|
50
79
|
destructive: 'rgb(186, 26, 26)',
|
|
51
80
|
primary: 'rgb(0, 112, 233)',
|
|
81
|
+
primaryForeground: 'rgb(255, 255, 255)',
|
|
82
|
+
secondary: 'rgb(176, 201, 255)',
|
|
83
|
+
secondaryForeground: 'rgb(20, 55, 108)',
|
|
84
|
+
muted: 'rgb(193, 198, 215)',
|
|
85
|
+
mutedForeground: 'rgb(65, 71, 84)',
|
|
86
|
+
accent: 'rgb(169, 73, 204)',
|
|
87
|
+
accentForeground: 'rgb(255, 255, 255)',
|
|
88
|
+
border: 'rgb(215, 217, 228)',
|
|
89
|
+
input: 'rgb(210, 210, 215)',
|
|
90
|
+
ring: 'rgb(215, 217, 228)',
|
|
52
91
|
},
|
|
53
92
|
dark: {
|
|
54
93
|
grey6: 'rgb(16, 19, 27)',
|
|
@@ -61,8 +100,21 @@ const ANDROID_COLORS = {
|
|
|
61
100
|
foreground: 'rgb(255, 255, 255)',
|
|
62
101
|
root: 'rgb(0, 0, 0)',
|
|
63
102
|
card: 'rgb(16, 19, 27)',
|
|
103
|
+
cardForeground: 'rgb(224, 226, 237)',
|
|
104
|
+
popover: 'rgb(39, 42, 50)',
|
|
105
|
+
popoverForeground: 'rgb(224, 226, 237)',
|
|
64
106
|
destructive: 'rgb(147, 0, 10)',
|
|
65
107
|
primary: 'rgb(3, 133, 255)',
|
|
108
|
+
primaryForeground: 'rgb(255, 255, 255)',
|
|
109
|
+
secondary: 'rgb(28, 60, 114)',
|
|
110
|
+
secondaryForeground: 'rgb(189, 209, 255)',
|
|
111
|
+
muted: 'rgb(216, 226, 255)',
|
|
112
|
+
mutedForeground: 'rgb(139, 144, 160)',
|
|
113
|
+
accent: 'rgb(83, 0, 111)',
|
|
114
|
+
accentForeground: 'rgb(238, 177, 255)',
|
|
115
|
+
border: 'rgb(39, 42, 50)',
|
|
116
|
+
input: 'rgb(55, 55, 57)',
|
|
117
|
+
ring: 'rgb(39, 42, 50)',
|
|
66
118
|
},
|
|
67
119
|
} as const;
|
|
68
120
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Theme } from '@react-navigation/native';
|
|
2
|
-
|
|
1
|
+
import { Theme, DefaultTheme, DarkTheme } from '@react-navigation/native';
|
|
2
|
+
|
|
3
3
|
import { COLORS } from './colors';
|
|
4
4
|
|
|
5
5
|
const NAV_THEME: { light: Theme; dark: Theme } = {
|
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
export function withOpacity(color: string, opacity: number): string {
|
|
2
|
+
if (opacity < 0 || opacity > 1) {
|
|
3
|
+
throw new Error('Opacity should be between 0 and 1.');
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
// Detect the color format and delegate to the appropriate function
|
|
7
|
+
if (isNamedColor(color)) {
|
|
8
|
+
return withOpacityNamedColor(color, opacity);
|
|
9
|
+
} else if (color.startsWith('#')) {
|
|
10
|
+
return withOpacityHex(color, opacity);
|
|
11
|
+
} else if (color.startsWith('rgba')) {
|
|
12
|
+
return withOpacityRgba(color, opacity);
|
|
13
|
+
} else if (color.startsWith('rgb')) {
|
|
14
|
+
return withOpacityRgb(color, opacity);
|
|
15
|
+
} else if (color.startsWith('hsla')) {
|
|
16
|
+
return withOpacityHsla(color, opacity);
|
|
17
|
+
} else if (color.startsWith('hsl')) {
|
|
18
|
+
return withOpacityHsl(color, opacity);
|
|
19
|
+
} else {
|
|
20
|
+
throw new Error('Unsupported color format');
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
// Helper function for HEX colors
|
|
25
|
+
function withOpacityHex(hex: string, opacity: number): string {
|
|
26
|
+
const hexCode = hex.replace('#', '');
|
|
27
|
+
const expandedHex =
|
|
28
|
+
hexCode.length === 3
|
|
29
|
+
? hexCode
|
|
30
|
+
.split('')
|
|
31
|
+
.map((x) => x + x)
|
|
32
|
+
.join('')
|
|
33
|
+
: hexCode;
|
|
34
|
+
|
|
35
|
+
const r = parseInt(expandedHex.substr(0, 2), 16);
|
|
36
|
+
const g = parseInt(expandedHex.substr(2, 2), 16);
|
|
37
|
+
const b = parseInt(expandedHex.substr(4, 2), 16);
|
|
38
|
+
|
|
39
|
+
return `rgba(${r}, ${g}, ${b}, ${opacity})`;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
// Helper function for RGB colors
|
|
43
|
+
function withOpacityRgb(rgb: string, opacity: number): string {
|
|
44
|
+
const match = rgb.match(/^rgb\((\d+), (\d+), (\d+)\)$/);
|
|
45
|
+
if (!match) {
|
|
46
|
+
throw new Error('Invalid RGB color format');
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
const r = parseInt(match[1], 10);
|
|
50
|
+
const g = parseInt(match[2], 10);
|
|
51
|
+
const b = parseInt(match[3], 10);
|
|
52
|
+
|
|
53
|
+
return `rgba(${r}, ${g}, ${b}, ${opacity})`;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
// Helper function for RGBA colors
|
|
57
|
+
function withOpacityRgba(rgba: string, opacity: number): string {
|
|
58
|
+
const match = rgba.match(/^rgba\((\d+), (\d+), (\d+), ([0-1]?(?:\.\d+)?)\)$/);
|
|
59
|
+
if (!match) {
|
|
60
|
+
throw new Error('Invalid RGBA color format');
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
const r = parseInt(match[1], 10);
|
|
64
|
+
const g = parseInt(match[2], 10);
|
|
65
|
+
const b = parseInt(match[3], 10);
|
|
66
|
+
|
|
67
|
+
return `rgba(${r}, ${g}, ${b}, ${opacity})`;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
// Helper function for HSL colors with opacity
|
|
71
|
+
function withOpacityHsl(hsl: string, opacity: number): string {
|
|
72
|
+
// Updated regex to handle space-separated HSL format with optional decimals
|
|
73
|
+
const match = hsl.match(/^hsl\((\d+(\.\d+)?)(?:\s+)(\d+(\.\d+)?)%\s+(\d+(\.\d+)?)%\)$/);
|
|
74
|
+
|
|
75
|
+
if (!match) {
|
|
76
|
+
throw new Error('Invalid HSL color format');
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
const h = match[1]; // Hue (can be an integer or decimal)
|
|
80
|
+
const s = match[3]; // Saturation (can be an integer or decimal)
|
|
81
|
+
const l = match[5]; // Lightness (can be an integer or decimal)
|
|
82
|
+
|
|
83
|
+
return `hsla(${h}, ${s}%, ${l}%, ${opacity})`;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
// Helper function for HSLA colors
|
|
87
|
+
function withOpacityHsla(hsla: string, opacity: number): string {
|
|
88
|
+
const match = hsla.match(/^hsla\((\d+), (\d+)%?, (\d+)%?, ([0-1]?(?:\.\d+)?)\)$/);
|
|
89
|
+
if (!match) {
|
|
90
|
+
throw new Error('Invalid HSLA color format');
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
const h = match[1];
|
|
94
|
+
const s = match[2];
|
|
95
|
+
const l = match[3];
|
|
96
|
+
|
|
97
|
+
return `hsla(${h}, ${s}%, ${l}%, ${opacity})`;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
// Helper function for named colors (basic implementation)
|
|
101
|
+
function isNamedColor(color: string): boolean {
|
|
102
|
+
const namedColors = new Set([
|
|
103
|
+
'red',
|
|
104
|
+
'green',
|
|
105
|
+
'blue',
|
|
106
|
+
'yellow',
|
|
107
|
+
'black',
|
|
108
|
+
'white',
|
|
109
|
+
'gray',
|
|
110
|
+
'orange',
|
|
111
|
+
'purple',
|
|
112
|
+
'brown',
|
|
113
|
+
'pink',
|
|
114
|
+
'cyan',
|
|
115
|
+
'magenta',
|
|
116
|
+
'lime',
|
|
117
|
+
'teal',
|
|
118
|
+
'indigo',
|
|
119
|
+
'violet',
|
|
120
|
+
'gold',
|
|
121
|
+
'silver',
|
|
122
|
+
]);
|
|
123
|
+
return namedColors.has(color.toLowerCase());
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
// Helper function for named color opacity
|
|
127
|
+
function withOpacityNamedColor(color: string, opacity: number): string {
|
|
128
|
+
return `rgba(${namedColorToRgb(color)}, ${opacity})`;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
// Converts a named color to RGB (simplified, basic colors only)
|
|
132
|
+
function namedColorToRgb(color: string): string {
|
|
133
|
+
const colors: { [key: string]: string } = {
|
|
134
|
+
red: '255, 0, 0',
|
|
135
|
+
green: '0, 255, 0',
|
|
136
|
+
blue: '0, 0, 255',
|
|
137
|
+
yellow: '255, 255, 0',
|
|
138
|
+
black: '0, 0, 0',
|
|
139
|
+
white: '255, 255, 255',
|
|
140
|
+
gray: '128, 128, 128',
|
|
141
|
+
orange: '255, 165, 0',
|
|
142
|
+
purple: '128, 0, 128',
|
|
143
|
+
brown: '165, 42, 42',
|
|
144
|
+
pink: '255, 192, 203',
|
|
145
|
+
cyan: '0, 255, 255',
|
|
146
|
+
magenta: '255, 0, 255',
|
|
147
|
+
lime: '0, 255, 0',
|
|
148
|
+
teal: '0, 128, 128',
|
|
149
|
+
indigo: '75, 0, 130',
|
|
150
|
+
violet: '238, 130, 238',
|
|
151
|
+
gold: '255, 215, 0',
|
|
152
|
+
silver: '192, 192, 192',
|
|
153
|
+
};
|
|
154
|
+
return colors[color.toLowerCase()] || '0, 0, 0'; // default to black if color is unknown
|
|
155
|
+
}
|
|
@@ -9,7 +9,7 @@ import './unistyles';
|
|
|
9
9
|
import { DefaultTheme, DarkTheme } from '@react-navigation/native';
|
|
10
10
|
import { useUnistyles } from 'react-native-unistyles';
|
|
11
11
|
import { useMemo } from 'react';
|
|
12
|
-
<% } else if (props.stylingPackage?.name === "
|
|
12
|
+
<% } else if (props.stylingPackage?.name === "nativewind" || props.stylingPackage?.name === "stylesheet") { %>
|
|
13
13
|
import { DefaultTheme, DarkTheme } from '@react-navigation/native';
|
|
14
14
|
import { useColorScheme } from 'react-native';
|
|
15
15
|
import { useMemo } from 'react';
|
|
@@ -18,19 +18,6 @@ import { useMemo } from 'react';
|
|
|
18
18
|
import './translation';
|
|
19
19
|
<% } %>
|
|
20
20
|
import "react-native-gesture-handler";
|
|
21
|
-
<% if (props.stylingPackage?.name === "tamagui") { %>
|
|
22
|
-
import React from "react";
|
|
23
|
-
import { TamaguiProvider } from 'tamagui';
|
|
24
|
-
import * as SplashScreen from 'expo-splash-screen';
|
|
25
|
-
import { useFonts } from 'expo-font';
|
|
26
|
-
|
|
27
|
-
import config from './tamagui.config'
|
|
28
|
-
|
|
29
|
-
SplashScreen.preventAutoHideAsync();
|
|
30
|
-
<% } else if (props.stylingPackage?.name === "restyle") { %>
|
|
31
|
-
import { ThemeProvider } from '@shopify/restyle';
|
|
32
|
-
import { theme } from 'theme';
|
|
33
|
-
<% } %>
|
|
34
21
|
|
|
35
22
|
<% if (props.analyticsPackage?.name === "vexo-analytics") { %>
|
|
36
23
|
import { vexo } from 'vexo-analytics';
|
|
@@ -43,34 +30,7 @@ import "react-native-gesture-handler";
|
|
|
43
30
|
<% } %>
|
|
44
31
|
|
|
45
32
|
export default function App() {
|
|
46
|
-
<% if (props.stylingPackage?.name === "
|
|
47
|
-
const [loaded] = useFonts({
|
|
48
|
-
Inter: require("@tamagui/font-inter/otf/Inter-Medium.otf"),
|
|
49
|
-
InterBold: require("@tamagui/font-inter/otf/Inter-Bold.otf"),
|
|
50
|
-
});
|
|
51
|
-
|
|
52
|
-
const colorScheme = useColorScheme();
|
|
53
|
-
const theme = useMemo(() => colorScheme === 'dark' ? DarkTheme : DefaultTheme, [colorScheme]);
|
|
54
|
-
|
|
55
|
-
if (!loaded) {
|
|
56
|
-
return null;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
return (
|
|
60
|
-
<TamaguiProvider config={config}>
|
|
61
|
-
<Navigation theme={theme} onReady={() => SplashScreen.hideAsync()} />
|
|
62
|
-
</TamaguiProvider>
|
|
63
|
-
);
|
|
64
|
-
<% } else if (props.stylingPackage?.name === "restyle") { %>
|
|
65
|
-
const colorScheme = useColorScheme();
|
|
66
|
-
const navigationTheme = useMemo(() => colorScheme === 'dark' ? DarkTheme : DefaultTheme, [colorScheme]);
|
|
67
|
-
|
|
68
|
-
return (
|
|
69
|
-
<ThemeProvider theme={theme}>
|
|
70
|
-
<Navigation theme={navigationTheme} />
|
|
71
|
-
</ThemeProvider>
|
|
72
|
-
);
|
|
73
|
-
<% } else if (props.stylingPackage?.name === "unistyles") { %>
|
|
33
|
+
<% if (props.stylingPackage?.name === "unistyles") { %>
|
|
74
34
|
const { theme, rt } = useUnistyles();
|
|
75
35
|
|
|
76
36
|
const baseTheme = rt.colorScheme === 'dark' ? DarkTheme : DefaultTheme;
|
|
@@ -4,7 +4,7 @@ export declare const RN_NEW_TITLE = "rn new";
|
|
|
4
4
|
export declare const TITLE_TEXT: string;
|
|
5
5
|
export declare const DEFAULT_APP_NAME = "my-expo-app";
|
|
6
6
|
export declare const defaultOptions: CliResults;
|
|
7
|
-
export declare const
|
|
7
|
+
export declare const nativewindUIOptions: SelectedComponents[];
|
|
8
8
|
export declare const navigationValidationError = "You must pass in either --react-navigation or --expo-router if you want to use the --tabs or --drawer+tabs options";
|
|
9
9
|
export declare const projectNameValidationError = "A project with the name";
|
|
10
10
|
export declare const bunInstallationError = "Cancelled to install recommended version of Bun.";
|
package/build/types/types.d.ts
CHANGED
|
@@ -7,16 +7,16 @@ export interface CliFlags {
|
|
|
7
7
|
eas: boolean;
|
|
8
8
|
publish: boolean;
|
|
9
9
|
}
|
|
10
|
-
export declare const availablePackages: readonly ["@react-navigation/drawer", "expo-router", "expoRouter", "firebase", "nativewind", "nativewindui", "nwui", "react-navigation", "reactNavigation", "react-native-gesture-handler", "react-native-reanimated", "reactnavigation", "stylesheet", "supabase", "
|
|
10
|
+
export declare const availablePackages: readonly ["@react-navigation/drawer", "expo-router", "expoRouter", "firebase", "nativewind", "nativewindui", "nwui", "react-navigation", "reactNavigation", "react-native-gesture-handler", "react-native-reanimated", "reactnavigation", "stylesheet", "supabase", "unistyles", "i18next", "zustand", "vexo-analytics"];
|
|
11
11
|
export type AuthenticationSelect = 'supabase' | 'firebase' | undefined;
|
|
12
12
|
export type NavigationSelect = 'react-navigation' | 'expo-router' | undefined;
|
|
13
13
|
export type NavigationTypes = 'stack' | 'tabs' | 'drawer + tabs' | undefined;
|
|
14
|
-
export type StylingSelect = 'nativewind' | '
|
|
14
|
+
export type StylingSelect = 'nativewind' | 'stylesheet' | 'unistyles' | 'nativewindui';
|
|
15
15
|
export type PackageManager = 'yarn' | 'npm' | 'pnpm' | 'bun';
|
|
16
16
|
export type StateManagementSelect = 'zustand' | undefined;
|
|
17
17
|
export type Internalization = 'i18next';
|
|
18
18
|
export type Analytics = 'vexo-analytics';
|
|
19
|
-
export type SelectedComponents = 'action-sheet' | 'activity-indicator' | 'activity-view' | 'avatar' | '
|
|
19
|
+
export type SelectedComponents = 'action-sheet' | 'activity-indicator' | 'activity-view' | 'avatar' | 'button' | 'date-picker' | 'picker' | 'progress-indicator' | 'ratings-indicator' | 'slider' | 'text' | 'toggle';
|
|
20
20
|
export type AvailablePackages = {
|
|
21
21
|
name: (typeof availablePackages)[number];
|
|
22
22
|
type: 'navigation' | 'styling' | 'authentication' | 'internationalization' | 'state-management' | 'analytics';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Analytics, AuthenticationSelect, CliFlags, Internalization, NavigationSelect, NavigationTypes, PackageManager, SelectedComponents, StylingSelect } from '../types';
|
|
2
|
-
export declare function storeConfigAnalytics({ timestamp, cesVersion, authType, internalization,
|
|
2
|
+
export declare function storeConfigAnalytics({ timestamp, cesVersion, authType, internalization, nativewindUIComponents, navigationLibrary, navigationType, packageManager, packageManagerVersion, stylingLibrary, eas, importAlias, noGit, noInstall, overwrite, os, osPlatform, osArch, osRelease, analytics }: {
|
|
3
3
|
timestamp: string;
|
|
4
4
|
cesVersion: string;
|
|
5
5
|
authType?: AuthenticationSelect;
|
|
@@ -9,7 +9,7 @@ export declare function storeConfigAnalytics({ timestamp, cesVersion, authType,
|
|
|
9
9
|
packageManager: PackageManager;
|
|
10
10
|
packageManagerVersion: string;
|
|
11
11
|
internalization?: Internalization;
|
|
12
|
-
|
|
12
|
+
nativewindUIComponents?: SelectedComponents[];
|
|
13
13
|
os: string;
|
|
14
14
|
osPlatform: string;
|
|
15
15
|
osArch: string;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import { ExistsResult } from 'fs-jetpack/types';
|
|
2
1
|
import { GluegunPrompt } from 'gluegun';
|
|
2
|
+
type ExistsResult = false | 'dir' | 'file' | 'other';
|
|
3
3
|
export declare function validateProjectName(exists: (path: string) => ExistsResult, removeAsync: (path?: string) => Promise<void>, prompt: GluegunPrompt | null, projectName: string, overwrite: boolean): Promise<void>;
|
|
4
|
+
export {};
|
package/build/types.js
CHANGED
|
@@ -16,11 +16,9 @@ exports.availablePackages = [
|
|
|
16
16
|
'reactnavigation',
|
|
17
17
|
'stylesheet',
|
|
18
18
|
'supabase',
|
|
19
|
-
'tamagui',
|
|
20
|
-
'restyle',
|
|
21
19
|
'unistyles',
|
|
22
20
|
'i18next',
|
|
23
21
|
'zustand',
|
|
24
22
|
'vexo-analytics'
|
|
25
23
|
];
|
|
26
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
24
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHlwZXMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvdHlwZXMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBV2EsUUFBQSxpQkFBaUIsR0FBRztJQUMvQiwwQkFBMEI7SUFDMUIsYUFBYTtJQUNiLFlBQVk7SUFDWixVQUFVO0lBQ1YsWUFBWTtJQUNaLGNBQWM7SUFDZCxNQUFNO0lBQ04sa0JBQWtCO0lBQ2xCLGlCQUFpQjtJQUNqQiw4QkFBOEI7SUFDOUIseUJBQXlCO0lBQ3pCLGlCQUFpQjtJQUNqQixZQUFZO0lBQ1osVUFBVTtJQUNWLFdBQVc7SUFDWCxTQUFTO0lBQ1QsU0FBUztJQUNULGdCQUFnQjtDQUNSLENBQUMifQ==
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.default = clearNavigationPackages;
|
|
4
3
|
function clearNavigationPackages(cliResults) {
|
|
5
4
|
const stylingPackageIndex = cliResults.packages.findIndex((p) => p.type === 'navigation');
|
|
6
5
|
if (stylingPackageIndex !== -1) {
|
|
@@ -8,4 +7,5 @@ function clearNavigationPackages(cliResults) {
|
|
|
8
7
|
}
|
|
9
8
|
return cliResults;
|
|
10
9
|
}
|
|
11
|
-
|
|
10
|
+
exports.default = clearNavigationPackages;
|
|
11
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2xlYXJOYXZpZ2F0aW9uUGFja2FnZXMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvdXRpbGl0aWVzL2NsZWFyTmF2aWdhdGlvblBhY2thZ2VzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBRUEsU0FBd0IsdUJBQXVCLENBQUMsVUFBc0I7SUFDcEUsTUFBTSxtQkFBbUIsR0FBRyxVQUFVLENBQUMsUUFBUSxDQUFDLFNBQVMsQ0FBQyxDQUFDLENBQUMsRUFBRSxFQUFFLENBQUMsQ0FBQyxDQUFDLElBQUksS0FBSyxZQUFZLENBQUMsQ0FBQztJQUMxRixJQUFJLG1CQUFtQixLQUFLLENBQUMsQ0FBQyxFQUFFLENBQUM7UUFDL0IsVUFBVSxDQUFDLFFBQVEsQ0FBQyxNQUFNLENBQUMsbUJBQW1CLEVBQUUsQ0FBQyxDQUFDLENBQUM7SUFDckQsQ0FBQztJQUNELE9BQU8sVUFBVSxDQUFDO0FBQ3BCLENBQUM7QUFORCwwQ0FNQyJ9
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.default = clearStylingPackages;
|
|
4
3
|
function clearStylingPackages(cliResults) {
|
|
5
4
|
const stylingPackageIndex = cliResults.packages.findIndex((p) => p.type === 'styling');
|
|
6
5
|
if (stylingPackageIndex !== -1) {
|
|
@@ -8,4 +7,5 @@ function clearStylingPackages(cliResults) {
|
|
|
8
7
|
}
|
|
9
8
|
return cliResults;
|
|
10
9
|
}
|
|
11
|
-
|
|
10
|
+
exports.default = clearStylingPackages;
|
|
11
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2xlYXJTdHlsaW5nUGFja2FnZXMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvdXRpbGl0aWVzL2NsZWFyU3R5bGluZ1BhY2thZ2VzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBRUEsU0FBd0Isb0JBQW9CLENBQUMsVUFBc0I7SUFDakUsTUFBTSxtQkFBbUIsR0FBRyxVQUFVLENBQUMsUUFBUSxDQUFDLFNBQVMsQ0FBQyxDQUFDLENBQUMsRUFBRSxFQUFFLENBQUMsQ0FBQyxDQUFDLElBQUksS0FBSyxTQUFTLENBQUMsQ0FBQztJQUN2RixJQUFJLG1CQUFtQixLQUFLLENBQUMsQ0FBQyxFQUFFLENBQUM7UUFDL0IsVUFBVSxDQUFDLFFBQVEsQ0FBQyxNQUFNLENBQUMsbUJBQW1CLEVBQUUsQ0FBQyxDQUFDLENBQUM7SUFDckQsQ0FBQztJQUNELE9BQU8sVUFBVSxDQUFDO0FBQ3BCLENBQUM7QUFORCx1Q0FNQyJ9
|
|
@@ -9,13 +9,13 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.storeConfigAnalytics =
|
|
12
|
+
exports.storeConfigAnalytics = void 0;
|
|
13
13
|
const google_auth_library_1 = require("google-auth-library");
|
|
14
14
|
const googleapis_1 = require("googleapis");
|
|
15
15
|
const key_data = 'eyJ0eXBlIjoic2VydmljZV9hY2NvdW50IiwicHJvamVjdF9pZCI6ImNyZWF0ZS1leHBvLXN0YWNrLWFuYWx5dGljcyI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SFJTeW4xQUVaZHBneHIzOGU0ZnBQVlpTVkVDZ1lBWkw2K0pTdXoxY3BsaXloQ3lJU2NXXG5RWEFTMTNiRXMvbHd6MjhZT3ltN2JnMzVzZjdhOFBPMjBocGNPWnVERERySlpjME9LbG9tNXQzSHYxUDIreWNOXG5NczFQbnBqRjFEYlZ6ZFBDcm8xTkxKdTk4eEVYNWJXSXRDUkF1Q1hKUS90MWVKL3d6TThjbGhLYnRYVGdQTHl4XG5mSnViMERTWFpqUmtYUFNDcU0yb0t3PT1cbi0tLS0tRU5EIFBSSVZBVEUgS0VZLS0tLS1cbiIsImNsaWVudF9lbWFpbCI6ImNlcy1hbmFseXRpY3NAY3JlYXRlLWV4cG8tc3RhY2stYW5hbHl0aWNzLmlhbS5nc2VydmljZWFjY291bnQuY29tIiwiY2xpZW50X2lkIjoiMTEyMjg4MzM5NDYxNTA5NDM0MTcwIiwiYXV0aF91cmkiOiJodHRwczovL2FjY291bnRzLmdvb2dsZS5jb20vby9vYXV0aDIvYXV0aCIsInRva2VuX3VyaSI6Imh0dHBzOi8vb2F1dGgyLmdvb2dsZWFwaXMuY29tL3Rva2VuIiwiYXV0aF9wcm92aWRlcl94NTA5X2NlcnRfdXJsIjoiaHR0cHM6Ly93d3cuZ29vZ2xlYXBpcy5jb20vb2F1dGgyL3YxL2NlcnRzIiwiY2xpZW50X3g1MDlfY2VydF91cmwiOiJodHRwczovL3d3dy5nb29nbGVhcGlzLmNvbS9yb2JvdC92MS9tZXRhZGF0YS94NTA5L2Nlcy1hbmFseXRpY3MlNDBjcmVhdGUtZXhwby1zdGFjay1hbmFseXRpY3MuaWFtLmdzZXJ2aWNlYWNjb3VudC5jb20iLCJ1bml2ZXJzZV9kb21haW4iOiJnb29nbGVhcGlzLmNvbSJ9';
|
|
16
16
|
const keys = Buffer.from(key_data, 'base64').toString('utf-8');
|
|
17
17
|
function storeConfigAnalytics(_a) {
|
|
18
|
-
return __awaiter(this, arguments, void 0, function* ({ timestamp, cesVersion, authType, internalization,
|
|
18
|
+
return __awaiter(this, arguments, void 0, function* ({ timestamp, cesVersion, authType, internalization, nativewindUIComponents = [], navigationLibrary, navigationType, packageManager, packageManagerVersion, stylingLibrary, eas, importAlias, noGit, noInstall, overwrite, os, osPlatform, osArch, osRelease, analytics }) {
|
|
19
19
|
var _b;
|
|
20
20
|
if (process.env.NODE_ENV === 'development' || process.env.NODE_ENV === 'test') {
|
|
21
21
|
console.log('Skipping analytics in development or test environment');
|
|
@@ -42,7 +42,7 @@ function storeConfigAnalytics(_a) {
|
|
|
42
42
|
packageManager,
|
|
43
43
|
packageManagerVersion !== null && packageManagerVersion !== void 0 ? packageManagerVersion : '',
|
|
44
44
|
internalization !== null && internalization !== void 0 ? internalization : '',
|
|
45
|
-
(_b =
|
|
45
|
+
(_b = nativewindUIComponents === null || nativewindUIComponents === void 0 ? void 0 : nativewindUIComponents.join(',')) !== null && _b !== void 0 ? _b : '',
|
|
46
46
|
authType !== null && authType !== void 0 ? authType : '',
|
|
47
47
|
eas ? 'true' : 'false',
|
|
48
48
|
importAlias ? 'true' : 'false',
|
|
@@ -66,4 +66,5 @@ function storeConfigAnalytics(_a) {
|
|
|
66
66
|
}
|
|
67
67
|
});
|
|
68
68
|
}
|
|
69
|
-
|
|
69
|
+
exports.storeConfigAnalytics = storeConfigAnalytics;
|
|
70
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29uZmlnQW5hbHl0aWNzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL3V0aWxpdGllcy9jb25maWdBbmFseXRpY3MudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7O0FBQUEsNkRBQWlEO0FBQ2pELDJDQUFvQztBQWFwQyxNQUFNLFFBQVEsR0FDWixza0dBQXNrRyxDQUFDO0FBRXprRyxNQUFNLElBQUksR0FBRyxNQUFNLENBQUMsSUFBSSxDQUF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