From 2ecf1d229dd2a94fd2e6e4c7e55e8bda36c851b3 Mon Sep 17 00:00:00 2001 From: b3ni15 Date: Sun, 27 Jul 2025 00:30:52 +0200 Subject: [PATCH] Add initial iOS project files for iso-test-app - Created Info.plist with essential app configuration including bundle identifiers, versioning, and URL schemes. - Added PrivacyInfo.xcprivacy to specify accessed API types and privacy tracking settings. - Implemented SplashScreen.storyboard for the app's launch screen with a logo and background color. - Established Expo.plist for update configurations, setting updates to check on launch. - Created a bridging header for Swift compatibility. - Added an empty entitlements file for future use. --- app.json | 3 +- app/+not-found.tsx | 39 + app/index.tsx | 36 +- ios/.gitignore | 32 + ios/.xcode.env | 11 + ios/Podfile | 64 + ios/Podfile.lock | 2477 +++++++++++++++++ ios/Podfile.properties.json | 5 + ios/isotestapp.xcodeproj/project.pbxproj | 549 ++++ .../xcschemes/isotestapp.xcscheme | 88 + .../contents.xcworkspacedata | 10 + ios/isotestapp/AppDelegate.swift | 70 + .../App-Icon-1024x1024@1x.png | Bin 0 -> 59468 bytes .../AppIcon.appiconset/Contents.json | 14 + ios/isotestapp/Images.xcassets/Contents.json | 6 + .../Contents.json | 20 + .../SplashScreenLogo.imageset/Contents.json | 23 + .../SplashScreenLogo.imageset/image.png | Bin 0 -> 14711 bytes .../SplashScreenLogo.imageset/image@2x.png | Bin 0 -> 32766 bytes .../SplashScreenLogo.imageset/image@3x.png | Bin 0 -> 52602 bytes ios/isotestapp/Info.plist | 79 + ios/isotestapp/PrivacyInfo.xcprivacy | 48 + ios/isotestapp/SplashScreen.storyboard | 42 + ios/isotestapp/Supporting/Expo.plist | 12 + ios/isotestapp/isotestapp-Bridging-Header.h | 3 + ios/isotestapp/isotestapp.entitlements | 5 + package.json | 5 +- pnpm-lock.yaml | 93 + 28 files changed, 3729 insertions(+), 5 deletions(-) create mode 100644 app/+not-found.tsx create mode 100644 ios/.gitignore create mode 100644 ios/.xcode.env create mode 100644 ios/Podfile create mode 100644 ios/Podfile.lock create mode 100644 ios/Podfile.properties.json create mode 100644 ios/isotestapp.xcodeproj/project.pbxproj create mode 100644 ios/isotestapp.xcodeproj/xcshareddata/xcschemes/isotestapp.xcscheme create mode 100644 ios/isotestapp.xcworkspace/contents.xcworkspacedata create mode 100644 ios/isotestapp/AppDelegate.swift create mode 100644 ios/isotestapp/Images.xcassets/AppIcon.appiconset/App-Icon-1024x1024@1x.png create mode 100644 ios/isotestapp/Images.xcassets/AppIcon.appiconset/Contents.json create mode 100644 ios/isotestapp/Images.xcassets/Contents.json create mode 100644 ios/isotestapp/Images.xcassets/SplashScreenBackground.colorset/Contents.json create mode 100644 ios/isotestapp/Images.xcassets/SplashScreenLogo.imageset/Contents.json create mode 100644 ios/isotestapp/Images.xcassets/SplashScreenLogo.imageset/image.png create mode 100644 ios/isotestapp/Images.xcassets/SplashScreenLogo.imageset/image@2x.png create mode 100644 ios/isotestapp/Images.xcassets/SplashScreenLogo.imageset/image@3x.png create mode 100644 ios/isotestapp/Info.plist create mode 100644 ios/isotestapp/PrivacyInfo.xcprivacy create mode 100644 ios/isotestapp/SplashScreen.storyboard create mode 100644 ios/isotestapp/Supporting/Expo.plist create mode 100644 ios/isotestapp/isotestapp-Bridging-Header.h create mode 100644 ios/isotestapp/isotestapp.entitlements diff --git a/app.json b/app.json index 52010be..dff8e57 100644 --- a/app.json +++ b/app.json @@ -9,7 +9,8 @@ "userInterfaceStyle": "automatic", "newArchEnabled": true, "ios": { - "supportsTablet": true + "supportsTablet": true, + "bundleIdentifier": "com.anonymous.iso-test-app" }, "android": { "adaptiveIcon": { diff --git a/app/+not-found.tsx b/app/+not-found.tsx new file mode 100644 index 0000000..fd108d5 --- /dev/null +++ b/app/+not-found.tsx @@ -0,0 +1,39 @@ +import { Link, Stack } from 'expo-router'; +import React from 'react'; +import { StyleSheet, Text, View } from 'react-native'; + +export default function NotFoundScreen() { + return ( + <> + + + This screen does not exist. + + Go to home screen! + + + + ); +} + +const styles = StyleSheet.create({ + container: { + flex: 1, + alignItems: 'center', + justifyContent: 'center', + padding: 20, + }, + title: { + fontSize: 20, + fontWeight: 'bold', + marginBottom: 10, + }, + link: { + marginTop: 15, + paddingVertical: 15, + }, + linkText: { + color: '#007AFF', + textDecorationLine: 'underline', + }, +}); diff --git a/app/index.tsx b/app/index.tsx index 59b3a5b..d932d16 100644 --- a/app/index.tsx +++ b/app/index.tsx @@ -1,7 +1,38 @@ -import React from "react"; -import { Text, View } from "react-native"; +import * as Notifications from 'expo-notifications'; +import React, { useEffect } from "react"; +import { Button, Platform, Text, View } from "react-native"; + +async function registerForPushNotificationsAsync() { + const { status: existingStatus } = await Notifications.getPermissionsAsync(); + let finalStatus = existingStatus; + if (existingStatus !== 'granted') { + const { status } = await Notifications.requestPermissionsAsync(); + finalStatus = status; + } + if (finalStatus !== 'granted') { + alert('Permission for notifications not granted!'); + return false; + } + return true; +} + +async function sendNotification() { + await Notifications.scheduleNotificationAsync({ + content: { + title: "Hello!", + body: "Ez egy értesítés példája.", + }, + trigger: Platform.OS === 'android' + ? ({ seconds: 1, repeats: false } as any) + : null, + }); +} export default function Index() { + useEffect(() => { + registerForPushNotificationsAsync(); + }, []); + return ( Edit app/index.tsx to edit this screen. +