diff --git a/client/components/EditableText/index.tsx b/client/components/EditableText/index.tsx index e20ae8677..23f866240 100644 --- a/client/components/EditableText/index.tsx +++ b/client/components/EditableText/index.tsx @@ -28,7 +28,7 @@ export const EditableInput = ({ {loading && } { { flexDirection: 'row', marginTop: 20, justifyContent: 'center', - gap: '8px', + gap: 8, }} > diff --git a/client/components/MultistepForm/MultistepForm.tsx b/client/components/MultistepForm/MultistepForm.tsx index bdf973104..8321becdc 100644 --- a/client/components/MultistepForm/MultistepForm.tsx +++ b/client/components/MultistepForm/MultistepForm.tsx @@ -45,7 +45,7 @@ const loadStyles = (theme) => { return { container: { - height: '800px', + height: 800, backgroundColor: currentTheme.colors.white, alignItems: 'center', justifyContent: 'center', diff --git a/client/components/SearchInput.tsx b/client/components/SearchInput.tsx index 18aeb7e25..5e27b603d 100644 --- a/client/components/SearchInput.tsx +++ b/client/components/SearchInput.tsx @@ -4,7 +4,7 @@ import { MaterialIcons } from '@expo/vector-icons'; import useSearchInput from '~/hooks/search/useSearchInput'; import useTheme from '~/hooks/useTheme'; import useCustomStyles from '~/hooks/useCustomStyles'; -import { RStack, RInput, RButton, RText, RScrollView } from '@packrat/ui'; +import { RStack, RInput, RButton, RText, RScrollView, RIconButton } from '@packrat/ui'; import { View, Pressable } from 'react-native'; export const SearchInput = ({ onSelect, placeholder }) => { @@ -35,8 +35,8 @@ export const SearchInput = ({ onSelect, placeholder }) => { > { @@ -53,7 +53,7 @@ export const SearchInput = ({ onSelect, placeholder }) => { display: 'flex', alignItems: 'center', justifyContent: 'center', - width: '40px', + width: 40, fontSize: 20, }} /> @@ -90,7 +90,7 @@ export const SearchInput = ({ onSelect, placeholder }) => { > {data.map((result, i) => ( { {result.properties.name} {result.properties.osm_value} @@ -132,14 +130,12 @@ export const SearchInput = ({ onSelect, placeholder }) => { setSearchString(text); }} placeholder="Search" - style={{ - width: '100%', - borderRadius: '4', - padding: '16px 8px', - backgroundColor: 'white', - }} value={searchString} fontSize={14} + width={'100%'} + borderRadius={4} + paddingVertical={16} + backgroundColor="white" /> ({ container: { marginTop: 20, marginBottom: 15, - maxWidth: '400px', + maxWidth: 400, }, }); diff --git a/client/components/TripCard.tsx b/client/components/TripCard.tsx index b9442e479..4b715bd4e 100644 --- a/client/components/TripCard.tsx +++ b/client/components/TripCard.tsx @@ -146,7 +146,7 @@ const loadStyles = (theme) => { flex: 1, paddingHorizontal: 60, paddingVertical: 70, - height: Platform.OS === 'web' ? '450px' : '100%', + height: Platform.OS === 'web' ? 450 : '100%', alignSelf: 'center', }, mapCard: { @@ -157,7 +157,7 @@ const loadStyles = (theme) => { padding: currentTheme.size.cardPadding, paddingHorizontal: currentTheme.padding.paddingInside, marginBottom: 20, - height: Platform.OS === 'web' ? '650px' : '100%', + height: Platform.OS === 'web' ? 650 : '100%', overflow: 'hidden', alignSelf: 'center', }, diff --git a/client/components/card/LargeCard.tsx b/client/components/card/LargeCard.tsx index d5cd82c95..d145948b6 100644 --- a/client/components/card/LargeCard.tsx +++ b/client/components/card/LargeCard.tsx @@ -77,7 +77,7 @@ export default function LargeCard({ style={{ color: currentTheme.colors.textPrimary, fontSize: currentTheme.font.size, - fontWeight: 600, + fontWeight: "600", }} > {title && {title}} @@ -120,7 +120,7 @@ const loadStyles = (theme) => { flex: 1, paddingHorizontal: 60, paddingVertical: 70, - height: Platform.OS === 'web' ? '450px' : '100%', + height: Platform.OS === 'web' ? 450 : '100%', }, mapCard: { backgroundColor: currentTheme.colors.card, @@ -130,7 +130,7 @@ const loadStyles = (theme) => { padding: currentTheme.size.cardPadding, paddingHorizontal: currentTheme.padding.paddingInside, marginBottom: 20, - height: Platform.OS === 'web' ? '650px' : '100%', + height: Platform.OS === 'web' ? 650 : '100%', overflow: 'hidden', }, }; diff --git a/client/components/card/index.tsx b/client/components/card/index.tsx index 132abf991..518c14b96 100644 --- a/client/components/card/index.tsx +++ b/client/components/card/index.tsx @@ -78,15 +78,15 @@ export const CustomCard = ({ - + - + {user._id === data.owner_id @@ -159,8 +159,8 @@ export const CustomCard = ({ style={{ alignItems: 'center', justifyContent: 'center', - paddingRight: '16px', - paddingLeft: '16px', + paddingRight: 16, + paddingLeft: 16, }} > @@ -170,14 +170,14 @@ export const CustomCard = ({ style={{ alignItems: 'center', justifyContent: 'center', - paddingRight: '16px', - paddingLeft: '16px', + paddingRight: 16, + paddingLeft: 16, }} > {content} - {footer} + {footer} {/* */} @@ -190,15 +190,15 @@ export const CustomCard = ({ - + {title} - + {user._id === data.owner_id @@ -255,14 +255,14 @@ export const CustomCard = ({ style={{ alignItems: 'center', justifyContent: 'center', - paddingRight: '16px', - paddingLeft: '16px', + paddingRight: 16, + paddingLeft: 16, }} > {content} - {footer} + {footer} ); diff --git a/client/components/dashboard/FeedPreview.tsx b/client/components/dashboard/FeedPreview.tsx index cf6a0e43b..3eaf5a892 100644 --- a/client/components/dashboard/FeedPreview.tsx +++ b/client/components/dashboard/FeedPreview.tsx @@ -41,9 +41,10 @@ const FeedPreviewScroll = () => { style={{ backgroundColor: '#F2F1EB', textTransform: 'capitalize', - padding: '4px 8px', + paddingVertical: 4, + paddingHorizontal: 8, alignSelf: 'center', - borderRadius: '2px', + borderRadius: 2, }} > {item.type} diff --git a/client/components/dashboard/Section.tsx b/client/components/dashboard/Section.tsx index a4fa8e9c4..14029eff2 100644 --- a/client/components/dashboard/Section.tsx +++ b/client/components/dashboard/Section.tsx @@ -9,7 +9,7 @@ const Section = ({ children, onPress }) => { const styles = useCustomStyles(loadStyles); return ( - + {children} @@ -29,7 +29,7 @@ const loadStyles = (theme) => { paddingHorizontal: 10, paddingVertical: 20, backgroundColor: currentTheme.colors.secondaryBlue, - borderRadius: '8px', + borderRadius: 8, }, }; }; diff --git a/client/components/feed/FeedCard.tsx b/client/components/feed/FeedCard.tsx index afb6a8134..113446665 100644 --- a/client/components/feed/FeedCard.tsx +++ b/client/components/feed/FeedCard.tsx @@ -83,21 +83,21 @@ export default function Card({ if (duration) numberOfNights = JSON.parse(duration).numberOfNights; return ( - + - - + + {type === 'pack' && ( @@ -126,7 +126,7 @@ export default function Card({ flexDirection: 'row', alignItems: 'center', justifyContent: 'space-between', - gap: '8px', + gap: 8, // border: '1px solid #ccc', }} > @@ -189,7 +189,7 @@ export default function Card({ style={{ flexDirection: 'column', alignItems: 'flex-start', - gap: '8px', + gap: 8, }} > @@ -201,7 +201,7 @@ export default function Card({ style={{ flexDirection: 'row', alignItems: 'center', - gap: '100px', + gap: 100, }} > @@ -234,7 +234,7 @@ export default function Card({ style={{ flexDirection: 'row', alignItems: 'center', - gap: '8px', + gap: 8, }} > {user?._id === owner_id ? null : ( diff --git a/client/components/feed/FeedSearchFilter.tsx b/client/components/feed/FeedSearchFilter.tsx index ee8f2a876..4679da0bb 100644 --- a/client/components/feed/FeedSearchFilter.tsx +++ b/client/components/feed/FeedSearchFilter.tsx @@ -76,7 +76,7 @@ const FeedSearchFilter = ({ > {feedType === 'public' && ( )} { diff --git a/client/components/item/ItemForm.tsx b/client/components/item/ItemForm.tsx index 95311938e..55c60c040 100644 --- a/client/components/item/ItemForm.tsx +++ b/client/components/item/ItemForm.tsx @@ -42,7 +42,7 @@ export const ItemForm = ({ return ( - + = ({ onSelect, placeholder }) => { const dispatch = useDispatch(); return Platform.OS === 'web' ? ( - + {/* ... */} = ({ onSelect, placeholder }) => { setShowSearchResults(true); }} placeholder={placeholder ?? 'Type here to search'} - style={{ - width: '100%', - borderRadius: '4', - padding: '16px 8px', - backgroundColor: 'white', - }} value={searchString} fontSize={14} + width={'100%'} + borderRadius={4} + paddingVertical={16} + paddingHorizontal={8} + backgroundColor="white" /> = ({ onSelect, placeholder }) => { setSearchString(text)} placeholder="Search" - style={{ - width: '100%', - borderRadius: '4', - padding: '16px 8px', - backgroundColor: 'white', - }} value={searchString} fontSize={14} + width={'100%'} + borderRadius={4} + paddingVertical={16} + paddingHorizontal={8} + backgroundColor="white" /> = ({ onSelect, placeholder }) => { > {searchResults.map((result, i) => ( handleSearchResultClick(result, i)} - // @ts-expect-error > diff --git a/client/components/itemtable/itemTable.tsx b/client/components/itemtable/itemTable.tsx index 9eac12131..43ee41ec0 100644 --- a/client/components/itemtable/itemTable.tsx +++ b/client/components/itemtable/itemTable.tsx @@ -98,7 +98,7 @@ export const ItemsTable = ({ /> @@ -115,12 +115,12 @@ export const ItemsTable = ({ { > { { diff --git a/client/components/map/MapButtonsOverlay.tsx b/client/components/map/MapButtonsOverlay.tsx index 7c9929a85..f26cd13f6 100644 --- a/client/components/map/MapButtonsOverlay.tsx +++ b/client/components/map/MapButtonsOverlay.tsx @@ -227,9 +227,9 @@ const loadStyles = (theme) => { container: { alignItems: 'center', justifyContent: 'center', - height: '400px', + height: 400, width: '100%', - borderRadius: '10px', + borderRadius: 10, }, map: { width: '100%', diff --git a/client/components/map/MapContainer.web.tsx b/client/components/map/MapContainer.web.tsx index 69d0cf956..0a35dd14f 100644 --- a/client/components/map/MapContainer.web.tsx +++ b/client/components/map/MapContainer.web.tsx @@ -29,9 +29,9 @@ const loadStyles = () => ({ alignItems: 'center', justifyContent: 'center', overflow: 'hidden', - marginVertical: '10px', + marginVertical: 10, width: '100%', - height: '400px', - borderRadius: '10px', + height: 400, + borderRadius: 10, }, }); diff --git a/client/components/map/WebMap.web.tsx b/client/components/map/WebMap.web.tsx index 265ca6251..4f8b500be 100644 --- a/client/components/map/WebMap.web.tsx +++ b/client/components/map/WebMap.web.tsx @@ -37,7 +37,7 @@ const WebMap = ({ shape: shapeProp }) => { } = useWebMap({ shape: shapeProp }); const element = ( - + {showModal || isPolygonOrMultiPolygon(shape) ? ( ({ alignItems: 'center', justifyContent: 'center', width: '100%', - borderRadius: '10px', + borderRadius: 10, }, map: { width: '100%', diff --git a/client/components/modal/index.tsx b/client/components/modal/index.tsx index 3417385a7..14e91093a 100644 --- a/client/components/modal/index.tsx +++ b/client/components/modal/index.tsx @@ -81,7 +81,7 @@ export const CustomModal = ({ opacity={0.5} enterStyle={{ opacity: 0 }} exitStyle={{ opacity: 0 }} - minWidth={'400px'} + minWidth={400} /> { const styles = useCustomStyles(loadStyles); const rowData = [ - + { return ( - + Choose a value: { + - - + + - {truncatedName} + {truncatedName} {state[index] ? ( - Loading.... + Loading.... ) : ( <> {!differentUser && ( @@ -105,7 +105,7 @@ const UserDataCard = ({ {type === 'pack' ? ( @@ -145,7 +145,7 @@ const UserDataCard = ({ { @@ -81,18 +81,18 @@ export default function UserDataContainer({ > diff --git a/client/components/weather/WeatherCard.tsx b/client/components/weather/WeatherCard.tsx index 1e9f2b82d..6e4617a93 100644 --- a/client/components/weather/WeatherCard.tsx +++ b/client/components/weather/WeatherCard.tsx @@ -27,12 +27,12 @@ export default function WeatherCard({ return ( - + Welcome @@ -47,12 +47,12 @@ export default function Login() { color="grey" fontWeight="medium" fontSize={14} - style={{ marginTop: '8px' }} + style={{ marginTop: 8 }} > Sign in to continue! - + Sign in @@ -116,7 +116,7 @@ export default function Login() { {/* Google Login starts */} - + Welcome @@ -37,11 +37,11 @@ export default function Register() { color="grey" fontWeight="medium" fontSize={14} - style={{ marginTop: '8px' }} + style={{ marginTop: 8 }} > Sign up to continue! - + registerUser()} - style={{ marginTop: '16px' }} + style={{ marginTop: 16 }} backgroundColor="mediumpurple" > {'Sign up'} @@ -107,7 +107,7 @@ export default function Register() { {/* Google register */} { onPress={onSettingsClick} style={{ backgroundColor: 'transparent', - marginBottom: '16px', + marginBottom: 16, justifyContent: 'center', border: '1px solid lightgray', - borderRadius: '8px', + borderRadius: 8, }} icon={ @@ -72,15 +72,15 @@ const Header = ({ @@ -88,7 +88,7 @@ const Header = ({ ) : ( <> - + {userRealName} {username} @@ -102,16 +102,16 @@ const Header = ({ {isLoading ? ( <> ) : ( @@ -164,12 +164,12 @@ const SkeletonUserDataCard = () => { }} > - + ); };