базовая пометка запрещенного контента

This commit is contained in:
Alexey Kasyanchuk
2017-01-05 12:08:15 +03:00
parent a100575779
commit db5d53ebc7
5 changed files with 281 additions and 6 deletions

View File

@ -13,7 +13,9 @@ return (
<div>
<ListItem
onClick={() => window.router('/torrent/' + torrent.hash)}
primaryText={<span className='break-word'>{torrent.name}</span>}
primaryText={<span className='break-word' style={{
color: torrent.contentCategory != 'xxx' ? 'black' : 'grey'
}}>{torrent.name}</span>}
secondaryText={
<div className='column' style={{height: 'auto', whiteSpace: 'normal'}}>
<div>
@ -119,7 +121,10 @@ return (
}
rightIcon={
<a href={`magnet:?xt=urn:btih:${torrent.hash}`}>
<svg style={{height: '24px'}} onClick={(e) => {
<svg style={{
height: '24px',
fill: torrent.contentCategory != 'xxx' ? 'black' : 'grey'
}} onClick={(e) => {
e.preventDefault();
e.stopPropagation();
var win = window.open(`magnet:?xt=urn:btih:${torrent.hash}`, '_self');

View File

@ -111,8 +111,8 @@ const TorrentInformation = (props) => {
<ListItem
// leftAvatar={<Avatar icon={<EditorInsertChart />} backgroundColor={yellow600} />}
rightIcon={<ActionInfo />}
primaryText="Adult content"
secondaryText='unknown'
primaryText="Category"
secondaryText={torrent.contentCategory || 'unknown'}
/>
</List>
);