Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Saboten758 committed Aug 27, 2023
1 parent fd289f7 commit 3a5425f
Show file tree
Hide file tree
Showing 16 changed files with 189 additions and 84 deletions.
4 changes: 2 additions & 2 deletions App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import axios from "axios";
const App=()=>{

const [latestVersion, setLatestVersion] = useState("");
const currentVersion = "1.1";
const currentVersion = "1.2";

useEffect(() => {
const init = async () => {
Expand All @@ -16,7 +16,7 @@ const App=()=>{
setLatestVersion(latestRelease.tag_name);

if (latestRelease.tag_name !== currentVersion) {
console.log(latestRelease.tag_name)

Alert.alert("Your app is not up to date!","Please update to the latest version on Github",[{text:'Open Github',onPress: ()=>Linking.openURL("https:github.com/Saboten758/Lemon_Player/releases/latest")},{text:'Cancel'}]);
}
else{
Expand Down
2 changes: 0 additions & 2 deletions Navigators/MainNav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ import { Dimensions } from "react-native";
import { createMaterialTopTabNavigator } from '@react-navigation/material-top-tabs';
import Home from "../Screens/Home";
import SettingsPage from "../Screens/SettingsPage";
import Games from "../Screens/Games";
import Manga from "../Screens/Manga";
import Explore from "../Screens/Explore";


Expand Down
10 changes: 9 additions & 1 deletion Navigators/Root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import Web from "../Others/Web";
import Games from "../Screens/Games";
import Manga from "../Screens/Manga";
import Web2 from "../Others/Web2";
import Shows from "../Screens/Shows";

const Stack=createNativeStackNavigator();

Expand Down Expand Up @@ -46,7 +47,7 @@ const Root=()=>{
headerShown:false

}}/>

<Stack.Screen name="Gran" component={Gran} options={{
headerShown:false

Expand All @@ -58,6 +59,13 @@ const Root=()=>{
},
headerTintColor: 'white',
})}/>
<Stack.Screen name="Shows" component={Shows} options={() => ({
headerTitle: (props) => <LogoTitle {...props} name={"T.V. Shows"} />,
headerStyle: {
backgroundColor: '#3D3C49',
},
headerTintColor: 'white',
})}/>
<Stack.Screen name="Manga" component={Manga} options={() => ({
headerTitle: (props) => <LogoTitle {...props} name={"Manga"} />,
headerStyle: {
Expand Down
6 changes: 4 additions & 2 deletions Others/Web.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ const Web = ({route}) => {
// { text: 'Cancel', style: 'cancel' },
// { text: 'OK', onPress: () => Linking.openURL('https://game.granbluefantasy.jp') },
// ],)
const links=['https://web.simple-mmo.com','https://herta.eu.org','https://mangadex.org','https://manganato.com','https://toonily.com','https://playtictactoe.org/','https://alokpaul-movies-app.netlify.app/']
const links=['https://web.simple-mmo.com','https://herta.eu.org','https://mangadex.org',
'https://manganato.com','https://toonily.com','https://playtictactoe.org/','https://alokpaul-movies-app.netlify.app/',
'https://anix.to/home','https://anilist.co/']

const webviewRef = useRef(null);

Expand Down Expand Up @@ -49,7 +51,7 @@ return (
allowsBackForwardNavigationGestures source={{ uri: links[data] }} style={{ flex: 1 }} />


{!(data===1 )&&(<View style={styles.bottomContainer}>
{!(data===1 || (data>6&&data<=7) )&&(<View style={styles.bottomContainer}>

<ImageBackground resizeMode='cover' source={require('../assets/mood.gif')} style={styles.bottom}>
<Icon.Button
Expand Down
4 changes: 0 additions & 4 deletions Others/Web2.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,6 @@ import { WebView } from 'react-native-webview';
import Icon from 'react-native-vector-icons/FontAwesome';
const Web2 = ({route}) => {
const { data } = route.params;
// Alert.alert("Google Auth Problem","Google Auth is not allowed for web views! Do You want to open on web instead?",[
// { text: 'Cancel', style: 'cancel' },
// { text: 'OK', onPress: () => Linking.openURL('https://game.granbluefantasy.jp') },
// ],)


const webviewRef = useRef(null);
Expand Down
111 changes: 49 additions & 62 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,79 +1,66 @@
This is a new [**React Native**](https://reactnative.dev) project, bootstrapped using [`@react-native-community/cli`](https://github.com/react-native-community/cli).
# Lemon Player

# Getting Started
A chill app where you play music from Live Radio Stations, get vaporwaved by the Plaza Radio, get RSS feeds about anime, manga, games and also chill out with web games :>

>**Note**: Make sure you have completed the [React Native - Environment Setup](https://reactnative.dev/docs/environment-setup) instructions till "Creating a new application" step, before proceeding.
## Table of Contents

## Step 1: Start the Metro Server
- [Features](#features)
- [Installation](#installation)
- [Screenshots](#screenshots)
- [Usage](#usage)
- [Contributing](#contributing)

First, you will need to start **Metro**, the JavaScript _bundler_ that ships _with_ React Native.
## Features

To start Metro, run the following command from the _root_ of your React Native project:
- Simple music player with Nightwave Plaza radio and other radios like J1 FM.
- Gets RSS feeds stright to your Mobile. (Anime News Network, Kotaku, etc.)
- Plays simple webgames by utilizing android WebView.
- Gives recomendations for movies & T.V. shows by utilizing WebView.
- Checks Github Releases for keeping itself updated!

```bash
# using npm
npm start
## Installation

# OR using Yarn
yarn start
```
1. Clone the repository:
```bash
git clone https://github.com/Saboten758/Lemon_Player
2. Navigate to the project directory:
```bash
cd Lemon_Player
3. Install the dependencies:
```bash
npm install
4. Run the project:
```bash
npm start
5. You can also try the latest released apk in the releases section. (Android 9 and up only)
## Step 2: Start your Application
This will start the Metro bundler and launch the project on an emulator or connected device.
Let Metro Bundler run in its _own_ terminal. Open a _new_ terminal from the _root_ of your React Native project. Run the following command to start your _Android_ or _iOS_ app:
## Screenshots
<div style="text-align:center"><img src="https://i.imgur.com/Cg35TkR.jpeg" width="320" height="700" style="display: block; margin: 0 auto" ><br/>
Radio<br/>
<div style="text-align:center"><img src="https://i.imgur.com/xmrcmpL.jpeg" width="320" height="700" style="display: block; margin: 0 auto" ><br/>
Explore Page<br/>
<img src="https://i.imgur.com/vKg1Fao.jpeg" width="320" height="700" style="display: block; margin: 0 auto" ><br/>
Different RSS feeds<br/>
<img src="https://i.imgur.com/WQ6r7Nt.jpeg" width="320" height="700" style="display: block; margin: 0 auto" ><br/>
Plaza Radio & J1 Radio ♫<br/>
<img src="https://i.imgur.com/xMVEbG4.jpeg" width="320" height="700" style="display: block; margin: 0 auto" ><br/>
Manga Page<br/>
<img src="https://i.imgur.com/v2kvu5O.jpeg" width="320" height="700" style="display: block; margin: 0 auto" ><br/>
Exploring RSS feeds using WebView<br/>
### For Android
```bash
# using npm
npm run android
# OR using Yarn
yarn android
```
### For iOS
```bash
# using npm
npm run ios
## Usage
1. Play Online Radio from the Player section
2. Get RSS feeds in the Explore Section
3. Get Movie & Anime Recomendations in the T.V. Shows Section.
4. Read Manga and explore RSS feeds by using android WebView
# OR using Yarn
yarn ios
```
If everything is set up _correctly_, you should see your new app running in your _Android Emulator_ or _iOS Simulator_ shortly provided you have set up your emulator/simulator correctly.
This is one way to run your app — you can also run it directly from within Android Studio and Xcode respectively.

## Step 3: Modifying your App

Now that you have successfully run the app, let's modify it.

1. Open `App.tsx` in your text editor of choice and edit some lines.
2. For **Android**: Press the <kbd>R</kbd> key twice or select **"Reload"** from the **Developer Menu** (<kbd>Ctrl</kbd> + <kbd>M</kbd> (on Window and Linux) or <kbd>Cmd ⌘</kbd> + <kbd>M</kbd> (on macOS)) to see your changes!

For **iOS**: Hit <kbd>Cmd ⌘</kbd> + <kbd>R</kbd> in your iOS Simulator to reload the app and see your changes!

## Congratulations! :tada:

You've successfully run and modified your React Native App. :partying_face:

### Now what?

- If you want to add this new React Native code to an existing application, check out the [Integration guide](https://reactnative.dev/docs/integration-with-existing-apps).
- If you're curious to learn more about React Native, check out the [Introduction to React Native](https://reactnative.dev/docs/getting-started).

# Troubleshooting

If you can't get this to work, see the [Troubleshooting](https://reactnative.dev/docs/troubleshooting) page.

# Learn More

To learn more about React Native, take a look at the following resources:

- [React Native Website](https://reactnative.dev) - learn more about React Native.
- [Getting Started](https://reactnative.dev/docs/environment-setup) - an **overview** of React Native and how setup your environment.
- [Learn the Basics](https://reactnative.dev/docs/getting-started) - a **guided tour** of the React Native **basics**.
- [Blog](https://reactnative.dev/blog) - read the latest official React Native **Blog** posts.
- [`@facebook/react-native`](https://github.com/facebook/react-native) - the Open Source; GitHub **repository** for React Native.
## Contributing
Contributions are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request. Peace!!
16 changes: 8 additions & 8 deletions Screens/Explore.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const Explore=()=>{
const timeslot=["Morning","Day","Afternoon","Evening","Night"]
const imgs=[require('../assets/morning.jpg'),
require('../assets/day.jpg'),
require('../assets/morning.jpg'),
require('../assets/afternoon.jpg'),
require('../assets/eve.jpg'),
require('../assets/night.jpg'),]
const [x,setx]=useState("")
Expand Down Expand Up @@ -63,10 +63,10 @@ const Explore=()=>{
else if(currentdate.getHours()>10 && currentdate.getHours()<12){
key=1
}
else if(currentdate.getHours()>=12 && currentdate.getHours()<16){
else if(currentdate.getHours()>=12 && currentdate.getHours()<17){
key=2
}
else if(currentdate.getHours()>=16 && currentdate.getHours()<20){
else if(currentdate.getHours()>=17 && currentdate.getHours()<20){
key=3
}
else if(currentdate.getHours()>=20 && currentdate.getHours()<=24){
Expand Down Expand Up @@ -94,7 +94,7 @@ const Explore=()=>{
<Card style={{margin:10,backgroundColor:'#3D3C49',width:270,height:240}} >

<Card.Cover
source={require('../assets/arcade.jpg')} resizeMode="stretch"
source={require('../assets/arcade.gif')} resizeMode="stretch"
/>
<Text style={styles.txt2}>Web Games </Text>
</Card>
Expand All @@ -104,18 +104,18 @@ const Explore=()=>{
<Card style={{margin:10,backgroundColor:'#3D3C49',width:270,height:240}} >

<Card.Cover
source={require('../assets/manga.jpg')} resizeMode="stretch"/>
source={require('../assets/manga.gif')} resizeMode="stretch"/>
<Text style={styles.txt2}>Manga</Text>
</Card>
</TouchableOpacity>

<TouchableOpacity onPress={()=>{nav.navigate('Web',{data:6})}} >
<TouchableOpacity onPress={()=>{nav.navigate('Shows')}} >
<Card style={{margin:10,backgroundColor:'#3D3C49',width:270,height:240}} >

<Card.Cover
source={{uri:'https://hips.hearstapps.com/hmg-prod/images/best-fall-movies-1659459329.jpg?crop=0.8297972654408298xw:1xh;center,top&resize=1200:*'}}
source={require('../assets/manga2.jpg')}
/>
<Text style={styles.txt2}>Movies </Text>
<Text style={styles.txt2}>T.V Shows </Text>
</Card>
</TouchableOpacity>
</ScrollView>
Expand Down
2 changes: 1 addition & 1 deletion Screens/Manga.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { useNavigation } from '@react-navigation/native'
import React from 'react'
import { View,ScrollView,TouchableOpacity,StyleSheet,Text, Linking } from 'react-native'
import { View,ScrollView,TouchableOpacity,StyleSheet,Text } from 'react-native'
import { Card, Paragraph, Title } from 'react-native-paper'

const Manga=()=>{
Expand Down
2 changes: 1 addition & 1 deletion Screens/Music.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useEffect, useState } from 'react';
import {ImageBackground,SafeAreaView,StyleSheet,Text,View,FlatList,ActivityIndicator,TouchableOpacity,Image, ScrollView, Dimensions, useWindowDimensions} from 'react-native';
import {ImageBackground,SafeAreaView,StyleSheet,Text,View,FlatList,ActivityIndicator,TouchableOpacity, Dimensions, useWindowDimensions} from 'react-native';
import TrackPlayer, {
useTrackPlayerEvents,
usePlaybackState,
Expand Down
2 changes: 1 addition & 1 deletion Screens/SettingsPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const SettingsPage=()=>{
<TouchableOpacity style={[styles.buttonz,{backgroundColor:'#ff0000'}]}onPress={()=>{Linking.openURL("https://saboten123.itch.io")}}><Text style={[styles.txt2,{color:'black'}]}>itch.io</Text></TouchableOpacity>
</View>
</View>

<Text style={{color:'white'}}>Lemon Player Version 1.2</Text>


</View>
Expand Down
Loading

0 comments on commit 3a5425f

Please sign in to comment.