mirror of
https://github.com/wassname/talk.git
synced 2026-08-15 12:55:10 +08:00
Take karma into account when doing e2e
This commit is contained in:
@@ -14,7 +14,8 @@ const ApproveButton = ({ active, minimal, onClick, className, disabled }) => {
|
||||
className={cn(
|
||||
styles.root,
|
||||
{ [styles.minimal]: minimal, [styles.active]: active },
|
||||
className
|
||||
className,
|
||||
'talk-admin-approve-button'
|
||||
)}
|
||||
onClick={onClick}
|
||||
disabled={disabled || active}
|
||||
|
||||
@@ -14,7 +14,8 @@ const RejectButton = ({ active, minimal, onClick, className, disabled }) => {
|
||||
className={cn(
|
||||
styles.root,
|
||||
{ [styles.minimal]: minimal, [styles.active]: active },
|
||||
className
|
||||
className,
|
||||
'talk-admin-reject-button'
|
||||
)}
|
||||
onClick={onClick}
|
||||
disabled={disabled || active}
|
||||
|
||||
@@ -24,6 +24,7 @@ const ModerationMenu = ({ asset = {}, items, getModPath, activeTab }) => {
|
||||
>
|
||||
{items.map(queue => (
|
||||
<Link
|
||||
id={`talk-admin-moderate-tab-${queue.key}`}
|
||||
key={queue.key}
|
||||
to={getModPath(queue.key, asset.id)}
|
||||
className={cn('mdl-tabs__tab', styles.tab, {
|
||||
|
||||
@@ -15,6 +15,7 @@ import {
|
||||
} from 'react-virtualized';
|
||||
import throttle from 'lodash/throttle';
|
||||
import key from 'keymaster';
|
||||
import cn from 'classnames';
|
||||
|
||||
const hasComment = (nodes, id) => nodes.some(node => node.id === id);
|
||||
|
||||
@@ -380,6 +381,11 @@ class ModerationQueue extends React.Component {
|
||||
...props
|
||||
} = this.props;
|
||||
|
||||
const rootClassName = cn(
|
||||
styles.root,
|
||||
`talk-admin-moderate-queue-${this.props.activeTab}`
|
||||
);
|
||||
|
||||
if (comments.length === 0) {
|
||||
return (
|
||||
<div className={styles.root}>
|
||||
@@ -401,7 +407,7 @@ class ModerationQueue extends React.Component {
|
||||
|
||||
const comment = comments[index];
|
||||
return (
|
||||
<div className={styles.root}>
|
||||
<div className={rootClassName}>
|
||||
<Comment
|
||||
root={this.props.root}
|
||||
key={comment.id}
|
||||
@@ -423,7 +429,7 @@ class ModerationQueue extends React.Component {
|
||||
const view = this.state.view;
|
||||
|
||||
return (
|
||||
<div className={styles.root}>
|
||||
<div className={rootClassName}>
|
||||
<ViewMore
|
||||
viewMore={() => this.viewNewComments()}
|
||||
count={comments.length - view.length}
|
||||
|
||||
Reference in New Issue
Block a user