Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel is required to process package imports. If you need a different preprocessor remove all packages first.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

HTML

            
              <div id="chat">
  
     <div class="nachricht_left">
        <div class="img"><img class="img-circle" width="50px" src="https://gravatar.com/avatar/05985c88be5fa0d7f448e068960452b9?s=80&d=https://static.codepen.io/assets/avatars/user-avatar-80x80-bdcd44a3bfb9a5fd01eb8b86f9e033fa1a9897c3a15b33adfc2649a002dab1b6.png">
            <p>Bassti012</p>  
            <p>223 post</p>      
       </div>
       <div class="content_nachricht"> 
            <div class="date"><span>Gestern um 7:00</span></div>
            <div class="bubble bubbleleft">           
Dignissim tristique a, auctor massa in nascetur lundium, nascetur mid integer dis et egestas rhoncus ac aliquet turpis integer velit, est dolor porttitor auctor, elementum porta sit tristique urna ac proin odio, habitasse ridiculus, non nunc nisi ac integer ultricies vel ac, phasellus ac? Scelerisque, ac sagittis sociis vel dictumst! Ac odio, dis placerat mus platea odio a in arcu! Urna et aliquam, a! Proin. Dolor lacus dolor adipiscing eros, et tincidunt, lundium aliquet tincidunt, porta, placerat urna nec! Urna, adipiscing enim mid ut. Enim amet, a ac mauris vut porttitor risus integer elit, dis od
</div>
       </div>
    </div>
  
     <div class="nachricht_right">
         <div class="img"><img class="img-circle" width="50px" src="https://gravatar.com/avatar/05985c88be5fa0d7f448e068960452b9?s=80&d=https://static.codepen.io/assets/avatars/user-avatar-80x80-bdcd44a3bfb9a5fd01eb8b86f9e033fa1a9897c3a15b33adfc2649a002dab1b6.png">
           <p>Peteri012</p>  
            <p>123 post</p>  
         </div>    
         <div class="content_nachricht">    
            <div class="date"><span>Gestern um 7:12</span></div>
            <div class="bubble bubbleright">
       Dignissim tristique a, auctor massa in nascetur lundium, nascetur mid integer dis et egestas rhoncus ac aliquet turpis integer velit, est dolor porttitor auctor, elementum porta sit tristique urna ac proin odio, habitasse ridiculus, elit, dis od  
           </div>
         </div>
</div>
  
  
  
  
  
  
  
       <div class="nachricht_left">
        <div class="img"><img class="img-circle" width="50px" src="https://gravatar.com/avatar/05985c88be5fa0d7f448e068960452b9?s=80&d=https://static.codepen.io/assets/avatars/user-avatar-80x80-bdcd44a3bfb9a5fd01eb8b86f9e033fa1a9897c3a15b33adfc2649a002dab1b6.png">
            <p>Bassti012</p>  
            <p>223 post</p>      
       </div>
       <div class="content_nachricht"> 
            <div class="date"><span>Gestern um 7:00</span></div>
            <div class="bubble bubbleleft">           
Dignissim tristique a, auctor massa in nascetur lundium, nascetur mid a ac mauris vut porttitor risus integer elit, dis od
</div>
       </div>
    </div>
  
     <div class="nachricht_right">
         <div class="img"><img class="img-circle" width="50px" src="https://gravatar.com/avatar/05985c88be5fa0d7f448e068960452b9?s=80&d=https://static.codepen.io/assets/avatars/user-avatar-80x80-bdcd44a3bfb9a5fd01eb8b86f9e033fa1a9897c3a15b33adfc2649a002dab1b6.png">
           <p>Peteri012</p>  
            <p>123 post</p>  
         </div>    
         <div class="content_nachricht">    
            <div class="date"><span>Gestern um 7:12</span></div>
            <div class="bubble bubbleright">
       Dignissim tristique a, auctor massa in nascetur lundium, nascetur mid integer dis et egestas rhoncus ac aliquet turpis integer velit, est dol ac proin odio, habitasse ridiculus, elit, dis od  
           </div>
         </div>
</div>
  
  
  
  
  
  
  
  
  
  
  
  
  
  
</div>
            
          
!

CSS

            
              *{
  margin:0;
  padding:0;
}


#chat{
  width:90%;
  display:flex;
  margin:0 auto;
  flex-direction:column;
}
.nachricht_left,
.nachricht_right{
  display:flex;
  flex-direction:row;
}
.nachricht_left .content_nachricht .date{
justify-content: flex-start;
}

.date {
     font-size: 8pt;
}   
.date span{
  margin-left:20px;
}





.nachricht_left .img{
  display:flex;
  flex-direction:column;
  text-align:center;
  width:90px;
  order:1;
}
#chat .img img{
  width:80%;
  margin:10%;
}

.nachricht_left .content_nachricht{
  display:flex;
  flex-direction:column;
 flex:8;
  order:2;
}







.nachricht_right .img{
  display:flex;
  flex-direction:column;
  text-align:center;
  width:90px;
  order:2;
}


.nachricht_right .content_nachricht{
  order:1;
display:flex;
  flex:8;
  flex-direction:column;
}
.nachricht_right .content_nachricht .date{
  width:100%;
}
.nachricht_right .content_nachricht .date span{
  float:right;
  margin-right:20px;
}
            
.bubble {
width: 80%;
min-height: 50px;
color: #fff;
padding: 20px;
margin:5px 25px;
background: #e54d42;
border-radius: 10px;
}
.bubbleleft{

}
.bubbleleft:after {
content: '';
position: relative;
border-style: solid;
border-width: 11px 14px 11px 0;
border-color: transparent #e54d42;
display: block;
width: 0;
z-index: 1;
left: -31px;
top: -15px;
}

            
.bubbleright{
width: 80%;
min-height: 50px;
padding: 20px;
color: #fff;
margin-top: 0px;
  margin-left:10%;
background: #503f3c;
border-radius: 10px;
}

.bubbleright:after {
content: '';
position:relative;
border-style: solid;
border-width: 11px 0 14px 14px;
border-color: transparent #503f3c;
display: block;
width: 0;
z-index: 1;
left: calc(100% + 20px);
top: 5px;
}

            
          
!

JS

            
              
            
          
!
999px

Console