diff options
author | Vitaly Takmazov | 2018-06-28 17:01:56 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2023-01-13 10:37:53 +0300 |
commit | bec5843fd6059fe25dcdc3e91352882aa1caa4d8 (patch) | |
tree | fa458e205d411593ed61059192bd9dfe3bca00a9 | |
parent | 96a7f550b4d27dbf8a50f6b692b4be9d734423e5 (diff) |
cleanup class names
-rw-r--r-- | vnext/src/components/Chat.js | 4 | ||||
-rw-r--r-- | vnext/src/components/Contacts.js | 22 | ||||
-rw-r--r-- | vnext/src/components/Feeds.js | 4 | ||||
-rw-r--r-- | vnext/src/components/PM.js | 12 | ||||
-rw-r--r-- | vnext/src/components/Post.js | 10 |
5 files changed, 28 insertions, 24 deletions
diff --git a/vnext/src/components/Chat.js b/vnext/src/components/Chat.js index fa187f42..e7beef35 100644 --- a/vnext/src/components/Chat.js +++ b/vnext/src/components/Chat.js @@ -44,8 +44,8 @@ export default class Chat extends React.Component { const { chats } = this.state; const uname = this.props.match.params.user; return ( - <div id="content"> - <article> + <div className="msgs"> + <article className="msg-cont"> {uname ? ( <div className="chatroom"> diff --git a/vnext/src/components/Contacts.js b/vnext/src/components/Contacts.js index aea537d4..509db3b3 100644 --- a/vnext/src/components/Contacts.js +++ b/vnext/src/components/Contacts.js @@ -28,16 +28,18 @@ export default class Contacts extends React.Component { const { pms } = this.state; const user = this.props.visitor; return ( - <div style={wrapperStyle} className="msg-cont"> - <ul style={chatListStyle} ref="chats"> - { - pms && pms.map((chat) => - <li key={chat.uname} style={chatTitleStyle}> - <Contact key={chat.uname} user={chat} /> - </li> - ) - } - </ul> + <div className="msgs"> + <div style={wrapperStyle} className="msg-cont"> + <ul style={chatListStyle} ref="chats"> + { + pms && pms.map((chat) => + <li key={chat.uname} style={chatTitleStyle}> + <Contact key={chat.uname} user={chat} /> + </li> + ) + } + </ul> + </div> </div> ); } diff --git a/vnext/src/components/Feeds.js b/vnext/src/components/Feeds.js index 997ac642..821a93f7 100644 --- a/vnext/src/components/Feeds.js +++ b/vnext/src/components/Feeds.js @@ -129,8 +129,8 @@ class Feed extends React.Component { </React.Fragment> ); return this.state.msgs.length > 0 ? ( - <div className="msgs" id="content">{nodes}</div> - ) : this.state.error ? <div>error</div> : this.state.loading ? <div className="msgs" id="content"><Spinner /><Spinner /><Spinner /><Spinner /></div> : <div>No more messages</div>; + <div className="msgs">{nodes}</div> + ) : this.state.error ? <div>error</div> : this.state.loading ? <div className="msgs"><Spinner /><Spinner /><Spinner /><Spinner /></div> : <div>No more messages</div>; } } diff --git a/vnext/src/components/PM.js b/vnext/src/components/PM.js index 44b81129..1833f3a3 100644 --- a/vnext/src/components/PM.js +++ b/vnext/src/components/PM.js @@ -4,13 +4,13 @@ import Avatar from './Avatar'; import { format } from '../utils/embed'; export default function PM(props) { - const {chat} = props; + const { chat } = props; return ( - <li style={chatItemStyle}> - <Avatar user={chat.user} /> - <p dangerouslySetInnerHTML={{ __html: format(chat.body) }} /> - </li> - ); + <li style={chatItemStyle}> + <Avatar user={chat.user} /> + <p dangerouslySetInnerHTML={{ __html: format(chat.body) }} /> + </li> + ); } const chatItemStyle = { diff --git a/vnext/src/components/Post.js b/vnext/src/components/Post.js index 7bde7432..e8ebab5c 100644 --- a/vnext/src/components/Post.js +++ b/vnext/src/components/Post.js @@ -40,11 +40,13 @@ export default class Post extends React.Component { } render() { return ( - <article> - <MessageInput rows="7" text={this.state.body} data={{ mid: 0, timestamp: "0" }} onSend={this.postMessage}> - *weather It's very cold today! + <div className="msgs"> + <article className="msg-cont"> + <MessageInput rows="7" text={this.state.body} data={{ mid: 0, timestamp: "0" }} onSend={this.postMessage}> + *weather It's very cold today! </MessageInput> - </article> + </article> + </div> ); } } |