reza fixed blog

master
Reza_ashrafi 3 years ago
parent e0c8e500b2
commit d657813b31
  1. 6
      src/screens/Blog/index.js
  2. 5
      src/screens/Blogs/index.js
  3. 11
      src/screens/Home/components/MyBooks.js

@ -17,7 +17,6 @@ import { LinearGradient } from "expo-linear-gradient";
import HTMLView from "react-native-htmlview";
//components
import Hashtags from "../Blogs/layouts/Hashtags";
import Header from "../Blogs/layouts/Header";
import New from "../Blogs/layouts/New";
import Navbar from "../../components/Navbar";
@ -76,7 +75,6 @@ export const Blog = ({ getInfo, blog, getList, blogs, route, theme }) => {
style={[styles.container, tw("flex")]}
>
<View style={tw("flex px-4 pb-24")}>
<Hashtags />
<View
style={[
tw("w-full rounded-sm overflow-hidden relative"),
@ -184,7 +182,7 @@ export const Blog = ({ getInfo, blog, getList, blogs, route, theme }) => {
stylesheet={{
p: {
color:
theme === "bold"
theme === "light"
? Colors.theme1.gray20
: Colors.theme1.grayF9,
textAlign: "right",
@ -223,7 +221,7 @@ export const Blog = ({ getInfo, blog, getList, blogs, route, theme }) => {
horizontal={true}
inverted={true}
style={[tw("flex flex-row mt-3 pb-3")]}
data={blogs}
data={blogs.filter((blog) => blog.id !== route.params.id)}
renderItem={({ item }) => <New blog={item} />}
keyExtractor={(item, index) => {
return item.id;

@ -15,7 +15,7 @@ import { blog } from "../../redux/actions";
//components
import Navbar from "../../components/Navbar";
import Drawer from "../../components/Drawer";
import Hashtags from "./layouts/Hashtags";
// import Hashtags from "./layouts/Hashtags";
import Header from "./layouts/Header";
import Single from "./layouts/Single";
import New from "./layouts/New";
@ -60,7 +60,7 @@ function Blogs({ getList, blogs }) {
contentContainerStyle={styles.contentContainerStyle}
style={[styles.container, tw("flex px-4")]}
>
<Hashtags />
{/* <Hashtags /> */}
<Single />
<Header title={"تازهترینها از وبلاگ"} />
<FlatList
@ -102,6 +102,7 @@ export default connect(mapStateToProps, mapDispatchToProps)(Blogs);
const styles = StyleSheet.create({
contentContainerStyle: {
paddingBottom: 100,
paddingTop : 30
},
container: {
paddingVertical: 0,

@ -12,15 +12,18 @@ import fontSize from "../../../constants/fontSize";
const ios = Platform.OS === "ios";
function MyBooks({ books, grades, theme }) {
console.log(books);
return books?.filter((book) => book.condition >= 2).length ? (
<View style={[tw("flex w-full mb-5")]}>
<View
style={[
tw(`w-full flex rounded-md pt-3 overflow-hidden`),
{
backgroundColor: theme === 'light' ? Colors.theme1.greenCF + "0F" : Colors.theme1.greenCF + '11',
borderColor: Colors.theme1.greenD9 + (theme === 'light' ? "" : "77"),
backgroundColor:
theme === "light"
? Colors.theme1.greenCF + "0F"
: Colors.theme1.greenCF + "11",
borderColor:
Colors.theme1.greenD9 + (theme === "light" ? "" : "77"),
borderWidth: 1,
},
]}
@ -38,7 +41,7 @@ function MyBooks({ books, grades, theme }) {
>
کتابهای من
</Text>
<FlatList
showsHorizontalScrollIndicator={false}
style={[tw("py-3")]}

Loading…
Cancel
Save