From e2a1bfd3d5fb5cbd7e9756de1f4f11b2e604064e Mon Sep 17 00:00:00 2001 From: Renard Date: Sun, 15 Sep 2019 21:21:51 -0300 Subject: Implementación de nuevo estilo de post en boards --- src/Post.js | 41 ++++++++++------------------------------- 1 file changed, 10 insertions(+), 31 deletions(-) (limited to 'src/Post.js') diff --git a/src/Post.js b/src/Post.js index 2525184..e175f91 100644 --- a/src/Post.js +++ b/src/Post.js @@ -14,6 +14,10 @@ const ImageModal = ({ href, trigger }) => ( ); const Post = ({ index, post, locked, dir, threadId }) => { + if (post.IS_DELETED > 0) { + return null; + } + console.log(post); const filesize = require('filesize'); const seedrandom = require("seedrandom"); const rng = seedrandom(threadId + index); @@ -28,11 +32,15 @@ const Post = ({ index, post, locked, dir, threadId }) => { #{index + 1} {post.name}{post.tripcode} - + + {user_id} {post.file !== "" ? - } /> + + } /> + {post.file} {post.image_width}x{post.image_height} {filesize(post.file_size, { bits: true })} + : null} @@ -42,35 +50,6 @@ const Post = ({ index, post, locked, dir, threadId }) => { ); - - return ( - - - #{index + 1} {post.name}{post.tripcode} - - - - - {user_id ? {user_id} : null} - - - - {post.file !== "" ? - - {post.file} {post.image_width}x{post.image_height} - {filesize(post.file_size, { bits: true })} - - } /> - : null} - - - {locked ? null : - ( - Responder - )} - - - ); } export default Post; \ No newline at end of file -- cgit v1.2.1-18-gbd029