Skip to content

Instantly share code, notes, and snippets.

@productioncoder
Last active November 26, 2021 23:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save productioncoder/b898f7becc6e441a77cb6e12354ae755 to your computer and use it in GitHub Desktop.
Save productioncoder/b898f7becc6e441a77cb6e12354ae755 to your computer and use it in GitHub Desktop.
Youtube AddComment component
import React from 'react';
import './AddComment.scss';
import {Form, Image, TextArea} from "semantic-ui-react";
export function AddComment() {
return (
<div className='add-comment'>
<Image className='user-image' src='http://via.placeholder.com/48x48' circular/>
<Form>
<Form.TextArea control={TextArea} autoHeight placeholder='Add a public comment' />
</Form>
</div>
);
}
@import '../../../styles/shared.scss';
.add-comment {
display: flex;
margin-top: 16px;
margin-bottom: 16px;
form {
flex: 1;
}
.user-image {
width: $avatar-diameter;
height: $avatar-diameter;
margin-right: $avatar-margin;
}
}
/* old content unchanged*/
$avatar-diameter: 48px;
$avatar-margin: 10px;
@muraad33
Copy link

import React from 'react';
import './AddComment.scss';
import {Form, Image, TextArea} from "semantic-ui-react";

export function AddComment() {
return (




<Form.TextArea control={TextArea} autoHeight placeholder='Add a public comment' />


);
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment