Rolling back classes

This commit is contained in:
okbel
2018-03-01 14:39:25 -03:00
parent eaf403353f
commit 300e518c2d
5 changed files with 16 additions and 11 deletions
@@ -14,10 +14,15 @@ import styles from './DraftArea.css';
export default class DraftArea extends React.Component {
renderCharCount() {
const { value, maxCharCount } = this.props;
const className = cn(styles.charCount, 'talk-commentbox-char-count', {
[`${styles.charMax} talk-commentbox-char-max`]:
value.length > maxCharCount,
});
const className = cn(
styles.charCount,
'talk-plugin-commentbox-char-count',
{
[`${styles.charMax} talk-plugin-commentbox-char-max`]:
value.length > maxCharCount,
}
);
const remaining = maxCharCount - value.length;
return (
@@ -52,7 +57,9 @@ export default class DraftArea extends React.Component {
return (
<div>
<div className={cn(styles.container, 'talk-commentbox-container')}>
<div
className={cn(styles.container, 'talk-plugin-commentbox-container')}
>
<label htmlFor={id} className="screen-reader-text" aria-hidden={true}>
{label}
</label>
@@ -12,7 +12,7 @@ const DraftAreaContent = ({
disabled,
}) => (
<textarea
className={cn(styles.content, 'talk-commentbox-textarea')}
className={cn(styles.content, 'talk-plugin-commentbox-textarea')}
value={value}
placeholder={placeholder}
id={id}
@@ -9,7 +9,7 @@ import CommentForm from '../containers/CommentForm';
import { notifyForNewCommentStatus } from '../helpers';
// TODO: (kiwi) Need to adapt CSS classes post refactor to match the rest.
export const name = 'talk-commentbox';
export const name = 'talk-plugin-commentbox';
/**
* Container for posting a new Comment
@@ -82,8 +82,6 @@ DraftAreaContainer.propTypes = {
const slots = ['draftArea'];
console.log('spreaded fragment', getSlotFragmentSpreads(slots, 'comment'));
export default withFragments({
root: gql`
fragment TalkEmbedStream_DraftArea_root on RootQuery {
+2 -2
View File
@@ -97,8 +97,8 @@ module.exports = {
elements: {
logoutButton: '.talk-stream-userbox-logout',
signInButton: '#coralSignInButton',
commentBoxTextarea: '.talk-commentbox-textarea',
commentBoxPostButton: '.talk-commentbox-button',
commentBoxTextarea: '.talk-plugin-commentbox-textarea',
commentBoxPostButton: '.talk-plugin-commentbox-button',
firstComment: '.talk-stream-comment.talk-stream-comment-level-0',
firstCommentContent:
'.talk-stream-comment.talk-stream-comment-level-0 .talk-stream-comment-content',