afeiship / react-full-video

Full page background video for react.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

react-full-video

Full page background video for react.

version license size download

installation

npm install -S @jswork/react-full-video

videos

usage

  1. import css
@import "~@jswork/react-full-video/dist/style.css";

// or use sass
@import "~@jswork/react-full-video/dist/style.scss";

// customize your styles:
$react-full-video-options: ()
  1. import js
import React from 'react';
import ReactFullVideo from '@jswork/react-full-video';
import '../../src/components/style.scss';
import styled from 'styled-components';

const Container = styled.div`
  padding: 0;
  margin: 0;
  height: 100%;
  .card {
    position: absolute;
    width: 400px;
    height: 220px;
    background: #fff;
    padding: 20px;
    box-shadow: rgb(0 0 0 / 16%) 0px 3px 10px;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
  }
`;

export default (props: any) => {
  return (
    <Container>
      <ReactFullVideo />
      <div className="card">A nice login ui.</div>
    </Container>
  );
};

preview

license

Code released under the MIT license.

About

Full page background video for react.

License:MIT License


Languages

Language:JavaScript 50.2%Language:TypeScript 40.5%Language:HTML 6.1%Language:SCSS 3.2%