JSFiddle - React, Tailwind, and code Playground
by rami7250
HTML
<style>
@import url(https://fonts.googleapis.com/css?family=PT+Sans);
body {
font-family: "PT Sans", sans-serif;
background: #192e4d;
}
/* CSS Resets */
aside,
section,
p,
div,
h1,
h2,
h3,
h4,
h5,
h6 {
margin: 0;
padding: 0;
}
aside {
display: block;
}
/* Common Styles */
.btn {
background-color: #ffffff;
padding: 10px;
color: #191919;
font-weight: bold;
border: none;
border-radius: 3px;
margin: 2px;
&:hover {
color: #ffffff;
cursor: pointer;
outline: none;
background-color: #192e4d;
}
}
/* Custom Styles */
.layout {
display: flex;
flex-direction: row;
align-items: center;
justify-content: center;
margin-top: 3%;
}
aside {
color: #fff;
width: 20%;
text-align: center;
padding: 0 5%;
.desc {
font-size: 0.8rem;
}
}
.post {
background: #fff;
box-shadow: 2px 1px 4px 2px rgba(100, 100, 100, 0.4);
width: 500px;
border: 2px solid #f3f3f3;
border-radius: 3px;
color: #191919;
display: flex;
flex-direction: column;
margin: 0;
.info {
padding: 10px 20px;
margin: 0;
border-bottom: 1px solid #d4d4d4;
.user {
font-weight: bold;
text-decoration: none;
color: #191919;
}
}
.post-header {
padding: 10px 20px 0;
display: flex;
flex-direction: row;
width: 100%;
justify-content: flex-start;
.content {
width: 90%;
padding: 10px 0;
.title,
.updated {
color: #a4a5a5;
font-size: 0.9rem;
font-weight: normal;
}
}
.avatar-wrapper {
width: 15%;
padding: 10px 0;
margin: 0;
.avatar {
width: 60px;
height: 60px;
border-radius: 50%;
}
}
}
.post-content {
margin: 0;
padding: 10px 20px 5px;
color: #181818;
.stats {
padding: 10px 0;
color: #a4a5a5;
font-size: 0.8rem;
font-weight: normal;
}
}
.post-comment-feed {
background: #f3f3f3;
padding: 20px;
.add-comment,
.comment {
display: flex;
flex-direction: row;
justify-content: flex-start;
margin-bottom: 10px;
.avatar-wrapper {
margin: 0;
padding:...
CSS
@import url(https://fonts.googleapis.com/css?family=PT+Sans);
body {
font-family: "PT Sans", sans-serif;
background: #192e4d;
}
/* CSS Resets */
aside,
section,
p,
div,
h1,
h2,
h3,
h4,
h5,
h6 {
margin: 0;
padding: 0;
}
aside {
display: block;
}
/* Common Styles */
.btn {
background-color: #ffffff;
padding: 10px;
color: #191919;
font-weight: bold;
border: none;
border-radius: 3px;
margin: 2px;
&:hover {
color: #ffffff;
cursor: pointer;
outline: none;
background-color: #192e4d;
}
}
/* Custom Styles */
.layout {
display: flex;
flex-direction: row;
align-items: center;
justify-content: center;
margin-top: 3%;
}
aside {
color: #fff;
width: 20%;
text-align: center;
padding: 0 5%;
.desc {
font-size: 0.8rem;
}
}
.post {
background: #fff;
box-shadow: 2px 1px 4px 2px rgba(100, 100, 100, 0.4);
width: 500px;
border: 2px solid #f3f3f3;
border-radius: 3px;
color: #191919;
display: flex;
flex-direction: column;
margin: 0;
.info {
padding: 10px 20px;
margin: 0;
border-bottom: 1px solid #d4d4d4;
.user {
font-weight: bold;
text-decoration: none;
color: #191919;
}
}
.post-header {
padding: 10px 20px 0;
display: flex;
flex-direction: row;
width: 100%;
justify-content: flex-start;
.content {
width: 90%;
padding: 10px 0;
.title,
.updated {
color: #a4a5a5;
font-size: 0.9rem;
font-weight: normal;
}
}
.avatar-wrapper {
width: 15%;
padding: 10px 0;
margin: 0;
.avatar {
width: 60px;
height: 60px;
border-radius: 50%;
}
}
}
.post-content {
margin: 0;
padding: 10px 20px 5px;
color: #181818;
.stats {
padding: 10px 0;
color: #a4a5a5;
font-size: 0.8rem;
font-weight: normal;
}
}
.post-comment-feed {
background: #f3f3f3;
padding: 20px;
.add-comment,
.comment {
display: flex;
flex-direction: row;
justify-content: flex-start;
margin-bottom: 10px;
.avatar-wrapper {
margin: 0;
padding:...