Skip to content
This repository has been archived by the owner on Sep 17, 2023. It is now read-only.

Commit

Permalink
Version 1.1.9
Browse files Browse the repository at this point in the history
  • Loading branch information
N0-0NE-Dev committed Mar 19, 2023
1 parent e1c1459 commit 925d656
Show file tree
Hide file tree
Showing 10 changed files with 261 additions and 14 deletions.
6 changes: 6 additions & 0 deletions App.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import AboutScreen from "./src/screens/AboutScreen";
import LoadingScreen from "./src/screens/LoadingScreen";
import { Storage } from "./src/components/Storage";
import StartupScreen from "./src/screens/StartupScreen";
import WeCimaExtractionScreen from "./src/screens/WeCimaExtractionScreen";

const Stack = createNativeStackNavigator();

Expand Down Expand Up @@ -59,6 +60,11 @@ const MyStack = () => {
component={StartupScreen}
options={{ headerShown: false }}
/>
<Stack.Screen
name="WeCima Extraction"
component={WeCimaExtractionScreen}
options={{ headerShown: false, animation: "none" }}
/>
<Stack.Screen name="General Settings" component={GeneralSettingsScreen} />
<Stack.Screen name="About" component={AboutScreen} />
</Stack.Navigator>
Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,15 @@ A streaming app with zero ads built in react native with [scrapers](https://gith
Please check the open and closed issues, update the app to the latest version and restart it at least twice before opening any issues.

## 📄 DMCA:

NoFasel does not own or operate any servers which contain DMCA-protected content, NoFasel scrapes all of its content from third-party websites mainly:

1. [FaselHD](https://www.faselhd.ac/)
2. [Akwam](https://akwam.to/)
3. [HDwatched](https://www.hdwatched.xyz/)
4. [WeCima](https://wecima.tube/)

Please bring up any DMCA violation concerns with them not me.

Please bring up any DMCA violation concerns with them not me.

## ⬇️ Download:

Expand Down
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,8 @@ android {
applicationId "com.n00nedev.nofasel"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 1
versionName "1.0"
versionCode 19
versionName "1.1.19"
}

splits {
Expand Down
14 changes: 7 additions & 7 deletions src/components/ContentCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,20 @@ const ContentCard = ({
<Pressable
style={{ width: width, margin: 5 }}
onPress={() =>
navigation.navigate("Select", { id: id, category: category })
}
>
navigation.navigate(
category == "WeCima" ? "WeCima Extraction" : "Select",
{ id: id, category: category },
)
}>
<ImageBackground
style={{ width: width, height: height }}
imageStyle={{ borderRadius: 15 }}
source={{ uri: imageSource }}
>
source={{ uri: imageSource }}>
<Text
style={{
...styles.ratingTextStyle,
backgroundColor: theme.colors.primary,
}}
>
}}>
{rating ? rating : "N/A"}
</Text>
</ImageBackground>
Expand Down
2 changes: 2 additions & 0 deletions src/components/FeaturedContentCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ const styles = StyleSheet.create({
fontWeight: "bold",
letterSpacing: 1.25,
backgroundColor: "transparent",
color: "white",
},
buttonsParentStyle: {
flexDirection: "row",
Expand All @@ -73,6 +74,7 @@ const styles = StyleSheet.create({
marginRight: 10,
fontSize: 16,
fontWeight: "200",
color: "white"
},
buttonStyle: {
marginLeft: 10,
Expand Down
6 changes: 4 additions & 2 deletions src/data/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/arabic-series.json",
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/arabic-movies.json",
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/featured-content.json",
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/last-scraped.txt"
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/last-scraped.txt",
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/WeCima.json"
],
"fileUrlsHdw": [
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/arabic-series.json",
Expand All @@ -70,7 +71,8 @@
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/hdw-trending-content.json",
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/hdw-all-content.json",
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/hdwmovies.json",
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/hdwseries.json"
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/hdwseries.json",
"https://raw.githubusercontent.com/N0-0NE-Dev/no-fasel-scrapers/main/output/WeCima.json"
],
"genresHdw": [
"Comedy",
Expand Down
168 changes: 168 additions & 0 deletions src/screens/EntireSeasonDownloadScreen.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
import React, { useEffect, useState } from "react";
import { View, StyleSheet, ScrollView, Image, Pressable } from "react-native";
import { Text, TextInput, useTheme } from "react-native-paper";
import ReactNativeBlobUtil from "react-native-blob-util";
import ContentCard from "../components/ContentCard";
import CentredActivityIndicator from "../components/CentredActivityIndicator";

const EntireSeasonDownloadScreen = ({ navigation }) => {
const theme = useTheme();

const [data, setData] = useState(null);
const [featured, setFeatured] = useState(null);
const [searchText, setSearchText] = useState("");
const [use, setUse] = useState([]);

useEffect(() => {
ReactNativeBlobUtil.fs
.readFile(ReactNativeBlobUtil.fs.dirs.DocumentDir + "/WeCima.json")
.then(data => {
const parsedData = Object.entries(JSON.parse(data));
setData(parsedData);
setFeatured(
parsedData.splice(parsedData.length - 11, parsedData.length),
);
setUse(parsedData.splice(parsedData.length - 11, parsedData.length));
});
}, []);

useEffect(() => {
if (data && searchText != "") {
var searched = data.filter(item => {
if (
item[1]["Title"]
.toLowerCase()
.includes(searchText.toLocaleLowerCase())
) {
return item;
} else {
// pass
}
});

if (searched.length > 0) {
setUse(searched);
} else {
setUse(false);
}
} else {
// pass
}
}, [searchText]);

useEffect(() => {
if (searchText === "") {
setUse(featured);
} else {
// pass
}
}, [searchText]);

if (data && featured) {
return (
<ScrollView style={{ flex: 1 }} showsVerticalScrollIndicator={false}>
<View style={styles.searchBarParentStyle}>
<TextInput
placeholder="Search"
mode="flat"
style={styles.searchBarStyle}
left={<TextInput.Icon icon="magnify" color="grey" />}
underlineColor="transparent"
activeUnderlineColor="transparent"
cursorColor="black"
onChangeText={text => setSearchText(text)}
/>
</View>

{use ? (
<View
style={{
flexDirection: "row",
flexWrap: "wrap",
justifyContent: "center",
}}>
{use.map(item => {
return (
<ContentCard
imageSource={
item[1]["Image Source"]
? item[1]["Image Source"]
: "https://imgpile.com/images/TPDrVl.jpg"
}
title={
item[1]["Title"] + " season " + item[1]["Season Number"]
}
id={item[1]["Source"]}
width={180}
height={270}
rating={`S${item[1]["Season Number"]}`}
category={"WeCima"}
navigation={navigation}
key={item[0]}
/>
);
})}
</View>
) : (
<View style={styles.imageParentStyle}>
<Image
source={require("../assets/NotFound.png")}
style={{ width: 860 * 0.3, height: 571 * 0.3 }}
/>
<Text
style={{
...styles.notFoundTextStyle,
color: theme.colors.primary,
}}>
Not Found
</Text>
<Text style={styles.descriptionTextStyle}>
Sorry, the keywords you entered could not be found. Try to check
again or search with different keywords.
</Text>
</View>
)}
</ScrollView>
);
} else {
return <CentredActivityIndicator />;
}
};

const styles = StyleSheet.create({
searchBarStyle: {
margin: 20,
borderRadius: 10,
borderTopRightRadius: 10,
borderTopLeftRadius: 10,
flex: 1,
},
searchBarParentStyle: {
flexDirection: "row",
justifyContent: "space-around",
alignItems: "center",
},
iconStyle: {
marginRight: 20,
borderRadius: 15,
padding: 15,
},
imageParentStyle: {
alignItems: "center",
flex: 1,
justifyContent: "center",
},
notFoundTextStyle: {
fontWeight: "bold",
fontSize: 26,
margin: 20,
},
descriptionTextStyle: {
textAlign: "center",
marginHorizontal: 10,
fontSize: 16,
letterSpacing: 0.75,
},
});

export default EntireSeasonDownloadScreen;
1 change: 0 additions & 1 deletion src/screens/SearchScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,6 @@ const styles = StyleSheet.create({
imageParentStyle: {
alignItems: "center",
flex: 1,
borderColor: "white",
justifyContent: "center",
},
notFoundTextStyle: {
Expand Down
10 changes: 10 additions & 0 deletions src/screens/TabScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import SettingsScreen from "./SettingsScreen";
import { BottomNavigation } from "react-native-paper";
import CentredActivityIndicator from "../components/CentredActivityIndicator";
import ReactNativeBlobUtil from "react-native-blob-util";
import EntireSeasonDownloadScreen from "./EntireSeasonDownloadScreen";

const TabScreen = ({ navigation }) => {
let progress = 0;
Expand Down Expand Up @@ -37,6 +38,12 @@ const TabScreen = ({ navigation }) => {
focusedIcon: "bookmark-minus",
unfocusedIcon: "bookmark-minus-outline",
},
{
key: "entireSeasonDownload",
title: "Season Download",
focusedIcon: "download",
unfocusedIcon: "download-outline",
},
{
key: "settings",
title: "Settings",
Expand All @@ -55,6 +62,9 @@ const TabScreen = ({ navigation }) => {
mylist: () => {
return <WatchlistScreen navigation={navigation} />;
},
entireSeasonDownload: () => {
return <EntireSeasonDownloadScreen navigation={navigation} />;
},
settings: () => {
return <SettingsScreen navigation={navigation} />;
},
Expand Down
59 changes: 59 additions & 0 deletions src/screens/WeCimaExtractionScreen.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
import React, { useState } from "react";
import { Linking, View } from "react-native";
import { ActivityIndicator, Button } from "react-native-paper";
import WebView from "react-native-webview";

const WeCimaExtractionScreen = ({ route }) => {
const { id } = route.params;
const [qualities, setQualities] = useState(null);

const jsCode = `
const qualities = {};
const items = [...document.getElementsByClassName("Season--Download--Wecima--Single")[0].querySelectorAll("a")];
items.forEach((item) => {
const link = item.getAttribute("href");
const resolution = item.querySelector("resolution").innerText;
qualities[resolution] = link;
});
window.ReactNativeWebView.postMessage(JSON.stringify(qualities));
`;

if (!qualities) {
return (
<View style={{ flex: 1, justifyContent: "center" }}>
<ActivityIndicator size={50} />
<View>
<WebView
source={{ uri: `https://wecima.tube/series/${id}` }}
injectedJavaScript={jsCode}
onMessage={event =>
setQualities(JSON.parse(event.nativeEvent.data))
}
/>
</View>
</View>
);
} else {
return (
<View style={{ flex: 1, justifyContent: "center" }}>
{Object.entries(qualities).map(quality => {
return (
<Button
mode="outlined"
style={{ marginTop: 10, borderWidth: 0 }}
labelStyle={{ fontSize: 18, padding: 10 }}
onPress={() => Linking.openURL(quality[1])}>
{quality[0]}
</Button>
);
})}
</View>
);
}
};

export default WeCimaExtractionScreen;

0 comments on commit 925d656

Please sign in to comment.