Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

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

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

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.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

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

Visit your global Editor Settings.

HTML

              
                #app

              
            
!

CSS

              
                @import url('https://fonts.googleapis.com/css?family=Raleway:400,700')
$font-family:  'Raleway', sans-serif
$font-size-light: 400
$font-size-bold: 700

body
  overflow-x: hidden
  background: #fff
  height: 1000px
  font-family: $font-family
 
  


.nav
  position: absolute
  display: flex
  flex-direction: row
  font-size: 20px
  color: #fff
  justify-content: center
  align-items: center
  z-index: 3
  list-style: none
  background: #000
  padding: 30px 
  width: 100%
  font-weight: bold
  left: 50%
  margin-top: 2%
  transform: translate(-50%, -40%)
  @media screen and (max-width: 300px)
    font-size: 10px
  
  li
    margin-left: 70px
    margin-right: 70px
    &:hover
      cursor: pointer
      color: yellow
   
  @media screen and (max-width: 600px)
    li
      margin-left: 30px
      margin-right: 30px
      font-size: 10px
      
      
  
      

    
  
  
  

  
  
.video
  width: 100vw
  height: 80%
  border: 2px solid #000
  
 
  
.overlay
  background: rgba(0,0,0,0.5)
  position: relative
  width: 100%
  height: 100%
  overflow: hidden
  
  
  
.text
  position: absolute
  font-weight: $font-size-bold
  color: #fff
  text-align: center
  font-size: 7em
  top: 60%
  text-shadow: 0px 0px 2px #000, 0px 0px 4px #000
  z-index: 3
  left: 50%
  transform: translate(-50%, -50%)
  font-style: bold
  
  @media screen and (max-width: 700px)
    display: none
  
  
 
  
 
.message
  position: relative
  z-index: 7
  font-size: 20px
  color: yellow
  @media screen and (max-width: 376px)
    font-size: 13px
              
            
!

JS

              
                const Video = (props) => {
  return (
    <video className="video" autoPlay muted loop>
      <source src={props.videoUrl}  type={props.type} />
    </video>
   );
} 


const  Message = (props) => {
    return (
        <p> {props.message }</p>
    )
}


const Menu = (props) => {
   
  return (
      
    <ul className="nav">
      <li>Home</li>
      <li>Blog</li>
      <li>About</li>
      <li>Contact</li>
    </ul>
  
  )
        
}
 
 const Title = (props) => {
   return (
     <h1 className="text">{props.title}</h1>
   )
 };


class App extends React.Component {
  constructor(props){
    super(props);
    this.state ={
      videoUrl: "http://thenewcode.com/assets/videos/fashion.mp4",
      type: "video/mp4"
    }
  }
  
  render(){
    return (
      <div>
        <Menu />
         <Title title="Women & Men Collection" />
            <Video className="video" videoUrl = {this.state.videoUrl} type =   {this.state.type}/>
        <div className="container">
          <div className="row" style={{marginTop :"60px"}}>
            <div className="col-md-6">
              <p className="text-center text-muted">
                Lorem ipsum dolor sit amet, consectetur adipisicing elit. Officia quae earum inventore quo unde, tempora a laudantium assumenda quis minus praesentium rerum eaque itaque recusandae natus dicta iusto non aperiam.
              </p>
            </div>
            <div className="col-md-6">
              <p className="text-center text-muted">
                Lorem ipsum dolor sit amet, consectetur adipisicing elit. Officia quae earum inventore quo unde, tempora a laudantium assumenda quis minus praesentium rerum eaque itaque recusandae natus dicta iusto non aperiam.
              </p>
            </div>
          </div>
        </div>
      </div>
     
     )
  }
}


ReactDOM.render(<App />, document.getElementById("app"));

 
              
            
!
999px

Console