-
Notifications
You must be signed in to change notification settings - Fork 38
Release v2.0.17 #2004
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Release v2.0.17 #2004
Changes from all commits
Commits
Show all changes
40 commits
Select commit
Hold shift + click to select a range
6c51b65
Initial plan
Copilot 9979ed6
Add iOS Weather Alerts feature parity with customizable preferences
Copilot 0c96419
Add catalog browser enhancements: Popular Items, Recently Used, per-i…
Copilot 9971b6d
Fix profile name screen: trim whitespace in canSave, route handleSave…
Copilot 9acaa8b
Address CodeRabbit review feedback on catalog browser
andrew-bierman d616941
fix: resolve biome lint errors
andrew-bierman 9427cef
Merge remote-tracking branch 'origin/development' into copilot/add-ch…
claude e3ebffd
Fix missing Share import in TripDetailScreen
andrew-bierman 27fbe21
improve responsiveness
Isthisanmol 5271716
chore(wrangler): add migrations for TikTokContainer to match deletion…
mikib0 79148b7
Merge pull request #1994 from PackRat-AI/chore/DO-migrations
mikib0 85b4337
chore(api): refactor container name to AppContainer
mikib0 ec269ef
chore(wrangler): update migrations
mikib0 8e7fb07
chore(wrangler): update migrations for prod environment
mikib0 f277a24
refactor(api): update comments to match the new container binding name
mikib0 9f3b4c9
Merge branch 'development' into chore/change-container-name
mikib0 ae1e401
Merge pull request #1995 from PackRat-AI/chore/change-container-name
mikib0 09b737e
Merge main into development
github-actions[bot] 9870023
correct import
Isthisanmol fc8a83e
fix-profile-image
Isthisanmol a13db5c
merge development
Isthisanmol 8b7d4de
add-choose-from-catalog-option-again
Isthisanmol a9f8ab9
fix(api): address memory limit issue in video to pack template genera…
mikib0 f3cfef8
Merge pull request #1997 from PackRat-AI/fix/memory-limit-video-pack-…
mikib0 31cbff8
merge development
Isthisanmol ef42a8b
feat: support generating of pack template from youtube videos
mikib0 6570536
Merge pull request #2000 from PackRat-AI/feat/generate-pack-template-…
mikib0 7392548
fix(expo/pack-categories): misaligned empty state text (closes #1981)
mikib0 6afff73
fix(expo/LocationPicker): add SafeAreaView (closes #1992)
mikib0 0534a1b
fix(expo/LocationSearchScreen): adjust search input focus timing (clo…
mikib0 6440a9d
Merge pull request #2001 from PackRat-AI/fix/bug-fixes-26.03.26
mikib0 fd8ff18
add real-time weather-alert and back button to weather screen
Isthisanmol c175e35
revert change
Isthisanmol 1d36d8d
Merge branch 'development' into copilot/add-weather-alerts-feature-ios
Isthisanmol ff134f4
add-weather-alerts-feature
Isthisanmol d774b2c
prevent content from overlapping header on iOS using safe area insets
Isthisanmol 5080b38
safe-area-header-overlap
Isthisanmol e32e492
prevent content from overlapping header on iOS using safe area insets
Isthisanmol c870ddd
safe-area-header-overlap-pack-template
Isthisanmol a482adf
chore: bump version to v2.0.17
mikib0 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,161 @@ | ||
| import { | ||
| Form, | ||
| FormItem, | ||
| FormSection, | ||
| LargeTitleHeader, | ||
| Text, | ||
| Toggle, | ||
| } from '@packrat/ui/nativewindui'; | ||
| import { Icon } from '@roninoss/icons'; | ||
| import { useColorScheme } from 'expo-app/lib/hooks/useColorScheme'; | ||
| import { useTranslation } from 'expo-app/lib/hooks/useTranslation'; | ||
| import * as React from 'react'; | ||
| import { ScrollView, View } from 'react-native'; | ||
| import { useSafeAreaInsets } from 'react-native-safe-area-context'; | ||
|
|
||
| type AlertPreferences = { | ||
| weatherNotifications: boolean; | ||
| locationMonitoring: boolean; | ||
| severeStorms: boolean; | ||
| tornadoWarnings: boolean; | ||
| floodAlerts: boolean; | ||
| fireDanger: boolean; | ||
| winterWeather: boolean; | ||
| extremeTemperature: boolean; | ||
| highWinds: boolean; | ||
| fogAlerts: boolean; | ||
| }; | ||
|
|
||
| type AlertTypeConfig = { | ||
| key: keyof Omit<AlertPreferences, 'weatherNotifications' | 'locationMonitoring'>; | ||
| iconName: string; | ||
| iconColor: string; | ||
| }; | ||
|
|
||
| const ALERT_TYPE_CONFIGS: AlertTypeConfig[] = [ | ||
| { key: 'severeStorms', iconName: 'weather-lightning-rainy', iconColor: '#FFCE56' }, | ||
| { key: 'tornadoWarnings', iconName: 'weather-tornado', iconColor: '#FF6384' }, | ||
| { key: 'floodAlerts', iconName: 'waves', iconColor: '#36A2EB' }, | ||
| { key: 'fireDanger', iconName: 'fire', iconColor: '#FF5722' }, | ||
| { key: 'winterWeather', iconName: 'weather-snowy-heavy', iconColor: '#90CAF9' }, | ||
| { key: 'extremeTemperature', iconName: 'thermometer-alert', iconColor: '#EF5350' }, | ||
| { key: 'highWinds', iconName: 'weather-windy', iconColor: '#4BC0C0' }, | ||
| { key: 'fogAlerts', iconName: 'weather-fog', iconColor: '#B0BEC5' }, | ||
| ]; | ||
|
|
||
| export default function WeatherAlertPreferencesScreen() { | ||
| const insets = useSafeAreaInsets(); | ||
| const { colors } = useColorScheme(); | ||
| const { t } = useTranslation(); | ||
|
|
||
| const [preferences, setPreferences] = React.useState<AlertPreferences>({ | ||
| weatherNotifications: true, | ||
| locationMonitoring: true, | ||
| severeStorms: true, | ||
| tornadoWarnings: true, | ||
| floodAlerts: true, | ||
| fireDanger: true, | ||
| winterWeather: true, | ||
| extremeTemperature: true, | ||
| highWinds: false, | ||
| fogAlerts: false, | ||
| }); | ||
|
mikib0 marked this conversation as resolved.
|
||
|
|
||
| function onToggle(key: keyof AlertPreferences) { | ||
| return (value: boolean) => { | ||
| setPreferences((prev) => ({ ...prev, [key]: value })); | ||
| }; | ||
| } | ||
|
|
||
| const alertTypesDisabled = !preferences.weatherNotifications; | ||
|
|
||
| return ( | ||
| <> | ||
| <LargeTitleHeader title={t('weather.alertPreferencesTitle')} /> | ||
| <ScrollView | ||
| contentInsetAdjustmentBehavior="automatic" | ||
| contentContainerStyle={{ paddingBottom: insets.bottom + 16 }} | ||
| > | ||
| <Form className="gap-5 px-4 pt-4"> | ||
| <FormSection | ||
| materialIconProps={{ name: 'bell-outline' }} | ||
| footnote={t('weather.alertPreferencesDesc')} | ||
| > | ||
| <FormItem className="ios:px-4 ios:pb-2 ios:pt-2 flex-row items-center justify-between px-2 pb-4"> | ||
| <View className="flex-1 flex-row items-center gap-3"> | ||
| <View className="h-8 w-8 items-center justify-center rounded-lg bg-amber-500"> | ||
| <Icon name="bell-ring-outline" size={18} color="white" /> | ||
| </View> | ||
|
mikib0 marked this conversation as resolved.
|
||
| <View className="flex-1"> | ||
| <Text className="font-medium">{t('weather.weatherNotifications')}</Text> | ||
| <Text variant="caption1" className="text-muted-foreground"> | ||
| {t('weather.weatherNotificationsDesc')} | ||
| </Text> | ||
| </View> | ||
| </View> | ||
| <Toggle | ||
| value={preferences.weatherNotifications} | ||
| onValueChange={onToggle('weatherNotifications')} | ||
| /> | ||
| </FormItem> | ||
| <FormItem className="ios:px-4 ios:pb-2 ios:pt-2 flex-row items-center justify-between px-2 pb-4"> | ||
| <View className="flex-1 flex-row items-center gap-3"> | ||
| <View className="h-8 w-8 items-center justify-center rounded-lg bg-blue-500"> | ||
| <Icon name="map-marker-radius-outline" size={18} color="white" /> | ||
| </View> | ||
| <View className="flex-1"> | ||
| <Text className="font-medium">{t('weather.locationMonitoring')}</Text> | ||
| <Text variant="caption1" className="text-muted-foreground"> | ||
| {t('weather.locationMonitoringDesc')} | ||
| </Text> | ||
| </View> | ||
| </View> | ||
| <Toggle | ||
| value={preferences.locationMonitoring} | ||
| onValueChange={onToggle('locationMonitoring')} | ||
| /> | ||
| </FormItem> | ||
| </FormSection> | ||
|
|
||
| <FormSection | ||
| ios={{ title: t('weather.alertTypes') }} | ||
| materialIconProps={{ name: 'alert-outline' }} | ||
| footnote={alertTypesDisabled ? t('weather.weatherNotificationsDesc') : undefined} | ||
| > | ||
| {ALERT_TYPE_CONFIGS.map(({ key, iconName, iconColor }) => ( | ||
| <View | ||
| key={key} | ||
| style={{ opacity: alertTypesDisabled ? 0.5 : 1 }} | ||
| pointerEvents={alertTypesDisabled ? 'none' : 'auto'} | ||
| > | ||
| <FormItem className="ios:px-4 ios:pb-2 ios:pt-2 flex-row items-center justify-between px-2 pb-4"> | ||
| <View className="flex-1 flex-row items-center gap-3"> | ||
| <View | ||
| className="h-8 w-8 items-center justify-center rounded-lg" | ||
| style={{ backgroundColor: alertTypesDisabled ? colors.grey3 : iconColor }} | ||
| > | ||
| <Icon name={iconName as never} size={18} color="white" /> | ||
| </View> | ||
| <View className="flex-1"> | ||
| <Text | ||
| className={ | ||
| alertTypesDisabled ? 'font-medium text-muted-foreground' : 'font-medium' | ||
| } | ||
| > | ||
| {t(`weather.${key}` as never)} | ||
| </Text> | ||
| <Text variant="caption1" className="text-muted-foreground"> | ||
| {t(`weather.${key}Desc` as never)} | ||
| </Text> | ||
| </View> | ||
| </View> | ||
| <Toggle value={preferences[key]} onValueChange={onToggle(key)} /> | ||
| </FormItem> | ||
| </View> | ||
| ))} | ||
| </FormSection> | ||
| </Form> | ||
| </ScrollView> | ||
| </> | ||
| ); | ||
| } | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.