UNPKG

le-player

Version:

The best HTML5 video player made for Lectoriy.

1,071 lines (1,070 loc) 23.8 kB
.leplayer { display: block; outline: 0; position: relative; background-color: transparent; } .leplayer.leplayer--fullscreen { position: absolute; top: 0; bottom: 0; left: 0; right: 0; width: 100% !important; max-width: none !important; } .leplayer-controls { border-collapse: separate; display: -ms-flexbox; display: flex; height: 32px; position: relative; width: 100%; outline: none; } .leplayer-controls--left { margin-right: auto; } .leplayer-controls--right { margin-left: auto; } .leplayer-controls--justify { width: auto; } .leplayer-controls--justify::after { content: ''; width: 1px; display: block; } .leplayer-controls:not(:last-child) { margin-bottom: 10px; } .leplayer-controls.controls-common { margin-top: 10px; } .leplayer-controls.controls-fullscreen { position: relative; width: auto; z-index: 1007; } .leplayer-controls.controls-fullscreen .control { background: #f5f5f5; color: #4a4a4a; } .leplayer-controls.controls-fullscreen .control--tap, .leplayer-controls.controls-fullscreen .control.control--no-iphone:hover { background: #c3c9ce; color: #011f33; } .leplayer-controls.controls-fullscreen .control.disabled { color: #e0e0e0; } .leplayer-controls.controls-fullscreen .control.disabled.control--tap, .leplayer-controls.controls-fullscreen .control.disabled.control--no-iphone:hover { background: #f5f5f5; color: #e0e0e0; } .leplayer-controls.controls-fullscreen .control.play { background: #0170bc; color: white; } .leplayer-controls.controls-fullscreen .control.play.control--tap, .leplayer-controls.controls-fullscreen .control.play.control--no-iphone:hover { background: #004B80; } .leplayer-controls.controls-fullscreen .control.timeline-container.control--tap, .leplayer-controls.controls-fullscreen .control.timeline-container.control--no-iphone:hover { background: #f5f5f5; } .leplayer-controls.controls-fullscreen .control-dropdown__content { background: #f5f5f5; z-index: 1008; } .leplayer-controls.controls-fullscreen .control-checkbox--checked { background: #c3c9ce; color: #011f33; } .leplayer-controls.controls-fullscreen .control-checkbox--checked.control--tap, .leplayer-controls.controls-fullscreen .control-checkbox--checked.control--no-iphone:hover { background: #b5bcc3; } .leplayer-controls.controls-fullscreen .info-control__content { background: #f5f5f5; color: white; } .leplayer-controls.controls-fullscreen .control-text { background: #f5f5f5; color: #4a4a4a; } .leplayer-controls.controls-fullscreen .control-container__item { color: #4a4a4a; } .leplayer-controls.controls-fullscreen .control-container__item:hover { background: #c3c9ce !important; color: #011f33; } .leplayer-controls.controls-fullscreen .control-container__item--active { background: #4a4a4a; color: #f5f5f5; } .leplayer-controls.controls-fullscreen .timeline { background: #dcdcdc; margin: 0; } .leplayer-controls.controls-fullscreen .timeline-container { background: #f5f5f5; } .leplayer-controls.controls-fullscreen .timeline-container .control-text { height: auto; position: relative; } .leplayer-controls.controls-fullscreen .time-marker { background: #0170bc; border-right: 1px solid #0170bc; z-index: 1007; } .leplayer-controls.controls-fullscreen .time-marker.shadow { background: #4a4a4a; border-right: 1px solid #4a4a4a; z-index: 1006; } .leplayer-controls.controls-fullscreen .time-marker .time { background: #0170bc; z-index: 1003; } .leplayer-controls.controls-fullscreen .time-played { background: #4a4a4a; z-index: 1005; } .leplayer-controls.controls-fullscreen .time-buffered { background-color: orange; z-index: 1004; } .leplayer-controls.controls-fullscreen .volume-active { background: #4a4a4a; } .leplayer-controls.controls-fullscreen .volume-slider { height: 144px; } .leplayer-controls.controls-fullscreen .volume-line { background: #dcdcdc; } .leplayer-controls.controls-fullscreen .volume-marker { background: #0170bc; border-top: 1px solid #0170bc; } .leplayer-controls .control { background: #f5f5f5; border: none; border-radius: 0; color: #4a4a4a; cursor: pointer; display: -ms-flexbox; display: flex; -ms-flex-align: center; align-items: center; -ms-flex-pack: center; justify-content: center; font-size: 16px; height: 32px; width: auto; line-height: 100%; padding: 0 8px; text-align: center; vertical-align: middle; } .leplayer-controls .control.control--tap, .leplayer-controls .control.control--no-iphone:hover { background: #c3c9ce; color: #011f33; } .leplayer-controls .control.play { background: #0170bc; color: white; padding: 0 22px; } .leplayer-controls .control.play.disabled:hover { background: #0170bc; } .leplayer-controls .control.play.control--tap, .leplayer-controls .control.play.control--no-iphone:hover { background: #004B80; color: #f5f5f5; } .leplayer-controls .control.disabled { cursor: not-allowed; color: #e0e0e0; pointer-events: none; } @media screen and (max-width: 420px) { .leplayer-controls .control { padding: 0 5px; } } .leplayer-controls .control-checkbox--checked { background: #4a4a4a; color: #f5f5f5; } .leplayer-controls .control-checkbox--checked.control--tap, .leplayer-controls .control-checkbox--checked.control--no-iphone:hover { background: #3d3d3d; } .leplayer-controls .control-dropdown { position: relative; } .leplayer-controls .control-dropdown .leplayer-icon svg { pointer-events: none; } .leplayer-controls .control-dropdown__content { background: #f5f5f5; bottom: 32px; cursor: default; display: none; left: 0; min-width: 100%; position: absolute; z-index: 508; left: 50%; transform: translateX(-50%); } .leplayer-controls .control-dropdown__content:before { content: ''; position: absolute; width: 32px; height: 1px; bottom: -1px; left: 0; } .leplayer-controls .info-control__content { white-space: nowrap; text-align: left; background: #f5f5f5; padding: 10px; color: black; font-size: 12px; /*left: 50%;*/ min-width: 300px; /*transform: translateX(-50%);*/ } .leplayer-controls .control-container { display: -ms-flexbox; display: flex; height: 32px; position: relative; } .leplayer-controls .control-container__item { display: block; color: #4a4a4a; white-space: nowrap; cursor: pointer; font-size: 12px; line-height: 32px; padding: 0 7px; } .leplayer-controls .control-container__item:hover { background: #c3c9ce !important; color: #011f33; } .leplayer-controls .control-container__item--active { background: #4a4a4a; color: #f5f5f5; } .leplayer-controls .control-icon { line-height: 32px; padding: 0 8px; } .leplayer-controls .control-text { background: #f5f5f5; color: #4a4a4a; display: -ms-flexbox; display: flex; -ms-flex-align: center; align-items: center; -ms-flex-pack: center; justify-content: center; font-size: 12px; box-sizing: content-box; line-height: 100%; padding: 0 5px; text-align: center; } .leplayer-controls .divider { background: none; display: block; padding: 0 5px; width: 0.01%; } .leplayer-controls .fa { text-align: center; width: 16px; } .leplayer-controls .timeline { background: #dcdcdc; cursor: pointer; display: block; height: 12px; margin: 10px 0; position: relative; width: 100%; } .leplayer-controls .time-current { width: 40px; } .leplayer-controls .timeline-container { background: #f5f5f5; position: relative; white-space: nowrap; width: 100%; } .leplayer-controls .timeline-container.control--tap, .leplayer-controls .timeline-container.control--no-iphone:hover { background: #f5f5f5; } .leplayer-controls .timeline-subcontainer { display: -ms-flexbox; display: flex; width: 100%; } .leplayer-controls .time-marker { background: #0170bc; border-right: 1px solid #0170bc; cursor: pointer; height: 16px; left: 0; margin-left: -2px; position: absolute; top: -2px; width: 2px; z-index: 507; } .leplayer-controls .time-marker:before { content: ''; width: 4px; height: 100%; position: absolute; left: -1px; background: transparent; } .leplayer-controls .time-marker--drag:before { background: #0170bc; } .leplayer-controls .time-marker.shadow { background: #0170bc; border-right: 1px solid #4a4a4a; transition: none; z-index: 506; } .leplayer-controls .time-marker.shadow:before { content: none; } .leplayer-controls .time-marker .time { background: #0170bc; border-radius: 1px; bottom: 20px; color: white; font-size: 12px; line-height: 18px; margin-left: -18px; padding: 0 5px; position: absolute; z-index: 503; } .leplayer-controls .timline-container.control--no-iphone .time-marker:hover:before { background: #0170bc; } .leplayer-controls .timline-container.control--tap .time-marker:before { background: #0170bc; } .leplayer-controls .time-played { background: #4a4a4a; bottom: 0; left: 0; position: absolute; top: 0; width: 0; z-index: 505; } .leplayer-controls .leplayer-timeline-sections { overflow-x: hidden; position: absolute; top: 0; bottom: 0; left: 0; right: 0; } .leplayer-controls .leplayer-timeline-section { background: #dcdcdc; bottom: 0; left: 0; position: absolute; top: 0; width: 0; z-index: 504; } .leplayer-controls .leplayer-timeline-section:nth-child(2n) { background: #f5f5f5; } .leplayer-controls .time-buffered { background-color: #dcdcdc; bottom: 0; left: 0; position: absolute; top: 0; width: 0; z-index: 504; } .leplayer-controls .volume-active { background: #4a4a4a; bottom: 0; height: 50%; position: absolute; width: 100%; } .leplayer-controls .volume-slider { height: 144px; } .leplayer-controls .volume-line { background: #dcdcdc; bottom: 10px; position: absolute; left: 12px; right: 12px; top: 10px; } .leplayer-controls .volume-marker { background: #0170bc; bottom: 50%; border-top: 1px solid #0170bc; cursor: pointer; height: 2px; left: -4px; margin-bottom: -1px; right: -4px; position: absolute; } .leplayer-control-collection { margin-top: 10px; margin-bottom: 10px; outline: none; } .leplayer-control-collection--one-row { display: -ms-flexbox; display: flex; } .leplayer-control-collection--fullscreen { display: none; bottom: 0; left: 20px; position: fixed; right: 20px; width: auto; z-index: 1007; } .leplayer--fullscreen .leplayer-control-collection--common { display: none; } .leplayer--fullscreen.leplayer--user-active .leplayer-control-collection--fullscreen { display: block; } .leplayer-error-display { position: absolute; top: 0; left: 0; right: 0; background: red; color: white; font-weight: 500; width: 100%; height: auto; display: none; text-align: center; font-size: 15px; padding: 15px; z-index: 508; } .leplayer--fullscreen .leplayer-error-display { z-index: 1008; } .leplayer--error .leplayer-error-display { display: block; } .leplayer-icon { display: block; min-width: 1em; min-height: 1em; } .leplayer-icon svg { display: block; width: 1em; height: 1em; } .leplayer__inner { position: relative; overflow: hidden; } .leplayer--fullscreen .leplayer__inner { height: 100%; margin: 0 auto; position: absolute; top: 0; width: 100%; z-index: 1006; } .leplayer--mini .leplayer__inner { top: 0; left: 0; right: 0; height: auto; display: -ms-flexbox; display: flex; position: fixed; max-width: 100%; margin-left: auto; margin-right: auto; -ms-flex-align: stretch; align-items: stretch; box-sizing: border-box; z-index: 600; max-height: 127px; background: #f5f8fa; box-shadow: 0 10px 15px -10px rgba(0, 0, 0, 0.75); } .leplayer__info { display: none; } .leplayer__last { display: none; position: absolute; } .leplayer__last .leplayer-time { display: inline; } .leplayer--mini .leplayer__info { display: -ms-flexbox; display: flex; padding: 10px; height: 50px; margin: 0; -ms-flex-direction: column; flex-direction: column; color: black; height: 100%; min-width: 300px; } .leplayer--mini .leplayer__last { display: block; right: 20px; } @media screen and (max-width: 750px) { .leplayer--mini .leplayer__last { display: none; } } .leplayer--mini .leplayer__title { color: black; font-size: 14px; margin-bottom: 5px; font-weight: 500; line-height: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .leplayer--mini .leplayer__video-info { margin-bottom: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .leplayer__title { color: black; font-size: 14px; margin-bottom: 5px; font-weight: 500; line-height: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .leplayer--mini .leplayer__title { display: block; } .leplayer-key { font-family: inherit; font-size: inherit; box-shadow: 1px 1px 0 1px rgba(120, 120, 120, 0.5); background: #eee; border-radius: 2px; color: #000; display: inline-block; margin: 4.25px 2px 4.25px 0; padding: 4px; } .leplayer-control-collection--mini { margin-top: auto; margin-bottom: auto; display: none; } .leplayer-control-collection--mini .control-time { display: block; padding: 6px 10px; font-weight: 500; width: 150px; white-space: nowrap; box-sizing: border-box; } @media (max-width: 440px) { .leplayer-control-collection--mini .control-time { display: none; } } .leplayer-control-collection--mini .control-time__current { background: none; cursor: default; font-size: 15px; text-align: right; color: black; display: inline; } .leplayer-control-collection--mini .control-time__total { background: none; cursor: default; color: black; display: inline; } .leplayer-control-collection--mini .control-time__total:before { content: '/'; margin-right: 9px; } .leplayer-control-collection--mini .volume-control:hover .volume-slider { display: none; } .leplayer-control-collection--mini .rate-current { min-width: 34px; } .leplayer--mini .leplayer-control-collection--mini { display: block; } @keyframes leplayer-splashicon-fadeout { 0% { opacity: 1; } to { opacity: 0; transform: scale(2); } } .leplayer-splashicon { display: none; position: absolute; left: 50%; top: 50%; width: 52px; height: 52px; z-index: 17; margin-left: -26px; margin-top: -26px; background: rgba(0, 0, 0, 0.5); border-radius: 26px; color: white; -ms-flex-pack: center; justify-content: center; -ms-flex-align: center; align-items: center; animation: leplayer-splashicon-fadeout 0.5s linear 1 normal forwards; } .leplayer-splashicon--active { display: -ms-flexbox; display: flex; } .leplayer--virgin .leplayer-splashicon { display: none; } .leplayer--iphone .leplayer-controls .timeline-container { width: auto; } .leplayer--iphone .leplayer-controls .timeline { display: none; } .leplayer--mobile.leplayer--fullscreen .leplayer-control-collection--fullscreen { position: static; } .leplayer--mobile.leplayer--fullscreen .controls-fullscreen { position: absolute; z-index: 1007; } .leplayer--mobile.leplayer--fullscreen .controls-fullscreen:nth-child(1) { bottom: 0; margin-bottom: 0; width: 100%; } .leplayer--mobile.leplayer--fullscreen .controls-fullscreen:nth-child(2) { top: 0px; left: 0px; } .leplayer--mobile.leplayer--fullscreen .controls-fullscreen:nth-child(2) .control-dropdown__content { bottom: auto; top: 32px; } .leplayer-video { background: #000; display: block; outline: 0; left: 0; position: relative; z-index: 506; } .leplayer-video video { display: block; max-width: 100%; width: 100%; outline: 0; height: auto; } .leplayer-video video::-webkit-media-controls { display: none !important; } .leplayer-video video::-webkit-media-controls-enclosure { display: none !important; } .leplayer--fullscreen .leplayer-video, .leplayer--fullscreen video { height: 100% !important; margin: 0 auto; width: 100% !important; padding-top: 0 !important; z-index: 1006; } .leplayer--mini .leplayer-video { z-index: 601; position: relative; width: 170px; -ms-flex: 0 0 170px; flex: 0 0 170px; top: auto; left: auto; } .leplayer--mini video { position: absolute; top: 0; bottom: 0; margin-top: auto; margin-bottom: auto; } .leplayer-play-button, .leplayer-loader-container { display: none; -ms-flex-align: center; align-items: center; align-contents: center; -ms-flex-pack: center; justify-content: center; background: rgba(0, 0, 0, 0.5); color: #0170bc; cursor: pointer; position: absolute; height: 100%; width: 100%; outline: 0; text-align: center; z-index: 508; font-size: 50px; } .leplayer-play-button.control--hover, .leplayer-play-button.control--no-iphone:hover { background: rgba(0, 0, 0, 0.2); } .leplayer-play-button.control--hover .leplayer-play-button__button, .leplayer-play-button.control--no-iphone:hover .leplayer-play-button__button { opacity: 0.8; } .leplayer-play-button__button { text-shadow: 0 0 10px rgba(255, 255, 255, 0.3); padding: 0.5em; background-color: white; border-radius: 50%; cursor: pointer; } .leplayer-play-button .leplayer-icon { position: relative; left: 0.08em; } .leplayer--inited.leplayer--virgin .leplayer-play-button { display: -ms-flexbox; display: flex; } .leplayer--inited.leplayer--virgin.leplayer--waiting .leplayer-play-button { display: none; } @media screen and (max-width: 420px) { .leplayer-play-button, .leplayer-loader-container { font-size: 35px; } } .leplayer--fullscreen .leplayer-play-button, .leplayer--fullscreen .leplayer-loader-container { z-index: 1008; } .leplayer--fullscreen .leplayer-play-button, .leplayer--fullscreen .leplayer-loader-container { font-size: 50px; } .leplayer--mini .leplayer-play-button { font-size: 30px; } .leplayer--playing .leplayer-play-button, .leplayer--error .leplayer-play-button, .leplayer--waiting .leplayer-play-button { display: none; } .leplayer-loader-container { color: white; font-size: 116px; display: -ms-flexbox; display: flex; } .leplayer-loader-container__icon { animation: leplayer-spin 2s infinite linear; } .leplayer--fullscreen .leplayer-loader-container { font-size: 128px; } .leplayer--mini .leplayer-loader-container { font-size: 82px; } .leplayer--inited .leplayer-loader-container, .leplayer--error .leplayer-loader-container { display: none; } .leplayer--inited .leplayer-loader-container__icon, .leplayer--error .leplayer-loader-container__icon { animation: none; } .leplayer--waiting .leplayer-loader-container { display: -ms-flexbox; display: flex; } .leplayer--waiting .leplayer-loader-container__icon { animation: leplayer-spin 2s infinite linear; } .leplayer--iphone .leplayer-loader-container { display: none; } .leplayer--iphone .leplayer-loader-container__icon { animation: none; } @keyframes leplayer-spin { 100% { transform: rotate(360deg); } } .leplayer-sections { font-size: 13px; height: 100%; overflow: hidden; width: 260px; z-index: 506; box-sizing: border-box; position: relative; outline: none; } .leplayer-sections--hidden { display: none; } .leplayer-sections--fsonly { display: none; } .leplayer-sections--hide-scroll .leplayer-sections__inner { position: absolute; top: 0; bottom: 0; left: 0; right: -15px; box-sizing: content-box; } .leplayer-sections__inner { overflow-y: scroll; height: 100%; } .leplayer-section { display: -ms-flexbox; display: flex; cursor: pointer; padding: 5px 0; background: white; color: black; width: 100%; } .leplayer-section:nth-child(2n) { background: #f2f8fd; } .leplayer-section.leplayer-section--active { background: #e0e0e0; } .leplayer-section.leplayer-section--active .leplayer-section-description { display: block; } .leplayer-section:hover { background: #9fccea; } .leplayer-section-time { color: #555; display: block; font-size: 0.92em; font-weight: 400; padding-top: 2px; text-align: right; width: 3.5em; -ms-flex: 0 0 3.5em; flex: 0 0 3.5em; } .leplayer-section-info { display: block; padding-left: 10px; padding-right: 7px; width: calc(100% - 3.5em); } .leplayer-section-title { font-weight: 500; word-wrap: break-word; } .leplayer-section-description { display: none; word-wrap: break-word; } .leplayer-section-next-info { display: none; } .leplayer__inner .leplayer-sections { position: absolute; top: 0; right: 0; } .leplayer__inner .leplayer-section { background: rgba(255, 255, 255, 0.8); } .leplayer__inner .leplayer-section:nth-child(2n) { background: rgba(242, 248, 253, 0.8); } .leplayer__inner .leplayer-section.leplayer-section--active { background: rgba(224, 224, 224, 0.8); } .leplayer__inner .leplayer-section:hover { background: rgba(159, 204, 234, 0.8); } .leplayer--fullscreen .leplayer-sections { display: none; position: absolute; top: 50px; right: 50px; bottom: 132px; z-index: 1008; height: calc(100% - 120px); } @media screen and (max-width: 500px) { .leplayer--fullscreen .leplayer-sections { top: 50%; left: 50%; bottom: auto; transform: translate(-50%, -50%); } } .leplayer--fullscreen.leplayer--user-active .leplayer-sections { display: block; } .leplayer--fullscreen.leplayer--user-active .leplayer-sections--hidden { display: none; } .leplayer--fullscreen .leplayer-sections--hidden { display: none; } .leplayer--fullscreen .leplayer-section { background: rgba(0, 0, 0, 0.7); color: #4a4a4a; } .leplayer--fullscreen .leplayer-section.leplayer-section--active, .leplayer--fullscreen .leplayer-section:hover { background: black; } .leplayer--fullscreen .leplayer-section:nth-child(2n) { background: rgba(47, 52, 63, 0.7); } .leplayer--fullscreen .leplayer-section:nth-child(2n).leplayer-section--active { background: #2f343f; } .leplayer--fullscreen .leplayer-section:nth-child(2n):hover { background: #29313d; } .leplayer--fullscreen .leplayer-section:hover { background: #14191f; } .leplayer--fullscreen.leplayer--android .leplayer-section.leplayer-section--active { background: #4a4a4a; } .leplayer--fullscreen .leplayer-section-time { color: white; } .leplayer--mini .leplayer__inner .leplayer-sections { margin-left: auto; display: -ms-flexbox; display: flex; position: relative; -ms-flex: 0 0 260px; flex: 0 0 260px; width: 260px; } @media screen and (max-width: 750px) { .leplayer--mini .leplayer__inner .leplayer-sections { display: none; } } .leplayer--mini .leplayer__inner .leplayer-section-next-info { display: block; margin-bottom: 15px; } .leplayer--mini .leplayer__inner .leplayer-section-description { display: none; } .leplayer--mini .leplayer__inner .leplayer-section { display: none; height: 100%; background: #f2f8fd; } .leplayer--mini .leplayer__inner .leplayer-section:hover { background: #9fccea; } .leplayer--mini .leplayer__inner .leplayer-sections { overflow: hidden; } .leplayer--mini .leplayer__inner .leplayer-section-time { display: none; } .leplayer--mini .leplayer__inner .leplayer-section--active + .leplayer-section { display: block; } .leplayer-timeline-buffered__range { position: absolute; top: 0; bottom: 0; background-color: #dcdcdc; z-index: 505; } .leplayer-poster { display: none; position: absolute; z-index: 507; left: 0; right: 0; top: 0; bottom: 0; background-size: 100% auto; background-repeat: no-repeat; background-position: center; } .leplayer--virgin .leplayer-poster { display: block; } .leplayer--fullscreen .leplayer-poster { z-index: 1007; }