comment intro

This commit is contained in:
Jeremy Kauffman 2019-07-10 10:43:55 -04:00
parent 610f36459f
commit bee401fd84
3 changed files with 46 additions and 42 deletions

View file

@ -36,48 +36,47 @@ export function CommentCreate(props: Props) {
} }
return ( return (
<React.Fragment> <section>
{commentAck !== true && ( {commentAck !== true && (
<section> <div className="card__content markdown-preview">
<div className="card__content"> <p>A few things to know before participating in the comment alpha:</p>
<div className="media__title">About comments..</div> <ul>
</div> <li>During the alpha, all comments are sent to a LBRY, Inc. server, not the LBRY network itself.</li>
<div className="card__content"> <li>During the alpha, comments are not decentralized or censorship resistant (but we repeat ourselves).</li>
<div className="media__subtitle">I acknowledge something.</div> <li>
</div> When the alpha ends, we will attempt to transition comments, but do not promise to so. Any transition will
<div className="card__content"> likely involve publishing previous comments under a single archive handle.
<Button button="primary" onClick={handleCommentAck} label={__('Got it!')} /> </li>
</div> </ul>
</section> <Button button="primary" onClick={handleCommentAck} label={__('Got it!')} />
</div>
)} )}
{commentAck === true && ( {commentAck === true && (
<section> <Form onSubmit={handleSubmit}>
<Form onSubmit={handleSubmit}> <div className="card__content">
<div className="card__content"> <ChannelSection channel={channel} onChannelChange={handleChannelChange} />
<ChannelSection channel={channel} onChannelChange={handleChannelChange} /> </div>
</div> <div className="card__content">
<div className="card__content"> <FormField
<FormField disabled={channel === CHANNEL_NEW}
disabled={channel === CHANNEL_NEW} type="textarea"
type="textarea" name="content_description"
name="content_description" label={__('Comment')}
label={__('Comment')} placeholder={__('Your comment')}
placeholder={__('Your comment')} value={commentValue}
value={commentValue} onChange={handleCommentChange}
onChange={handleCommentChange} />
/> </div>
</div> <div className="card__actions">
<div className="card__actions"> <Button
<Button button="primary"
button="primary" disabled={channel === CHANNEL_NEW || !commentValue.length}
disabled={channel === CHANNEL_NEW || !commentValue.length} type="submit"
type="submit" label={__('Post')}
label={__('Post')} />
/> </div>
</div> </Form>
</Form>
</section>
)} )}
</React.Fragment> </section>
); );
} }

View file

@ -291,7 +291,9 @@ class FilePage extends React.Component<Props> {
<ClaimTags uri={uri} type="large" /> <ClaimTags uri={uri} type="large" />
<FileDetails uri={uri} /> <FileDetails uri={uri} />
<div className="media__info-title">{__('Comments')}</div> <div className="media__info-title">
{__('Comments')} <span className="badge badge--alert">ALPHA</span>
</div>
<CommentCreate uri={uri} /> <CommentCreate uri={uri} />
<CommentsList uri={uri} /> <CommentsList uri={uri} />
</div> </div>

View file

@ -530,5 +530,8 @@
"Got it": "Got it", "Got it": "Got it",
"View Your Feed": "View Your Feed", "View Your Feed": "View Your Feed",
"View Your Channels": "View Your Channels", "View Your Channels": "View Your Channels",
"Unfollow": "Unfollow" "Unfollow": "Unfollow",
} "myChannelName": "myChannelName",
"This LBC remains yours. It is a deposit to reserve the name and can be undone at any time.": "This LBC remains yours. It is a deposit to reserve the name and can be undone at any time.",
"Create channel": "Create channel"
}