pleroma/priv/static/packs/containers/media_container.js

2 lines
396 KiB
JavaScript
Raw Normal View History

(window.webpackJsonp=window.webpackJsonp||[]).push([[3],{101:function(e,t,n){"use strict";n.r(t);var a=n(11);n.d(t,"setLocale",function(){return a.setLocale}),n.d(t,"getLocale",function(){return a.getLocale})},105:function(e,t,n){"use strict";var a=n(29),r=n(0),o=n(7),i=n(2),s=n.n(i),l=n(84),f=n.n(l),c=["opacity","backgroundOpacity"],u=function(e){function t(){return e.apply(this,arguments)||this}return Object(o.a)(t,e),t.prototype.render=function(){var e=this.props,n=e.style,a=e.defaultStyle,t=e.children;return Object.keys(n).forEach(function(e){var t;c.includes(e)||(n[e]=a[e]="object"==typeof(t=n[e])&&t&&"val"in t?t.val:t)}),Object(r.a)(f.a,{style:n,defaultStyle:a},void 0,t)},t}(s.a.Component);t.a=a.m?u:f.a},12:function(e,t,n){var a;!function(){"use strict";var i={}.hasOwnProperty;function s(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var a=typeof n;if("string"===a||"number"===a)e.push(n);else if(Array.isArray(n)&&n.length){var r=s.apply(null,n);r&&e.push(r)}else if("object"===a)for(var o in n)i.call(n,o)&&n[o]&&e.push(o)}}return e.join(" ")}e.exports?(s.default=s,e.exports=s):void 0===(a=function(){return s}.apply(t,[]))||(e.exports=a)}()},132:function(e,t,n){"use strict";n.r(t),n.d(t,"findElementPosition",function(){return p}),n.d(t,"getPointerPosition",function(){return m}),n.d(t,"default",function(){return g});var a,P=n(0),r=n(3),o=n(7),i=n(1),s=n(87),l=n.n(s),f=n(2),T=n.n(f),L=n(6),c=n(4),u=n(12),N=n.n(u),d=n(231),h=n(29),A=Object(L.f)({play:{id:"video.play",defaultMessage:"Play"},pause:{id:"video.pause",defaultMessage:"Pause"},mute:{id:"video.mute",defaultMessage:"Mute sound"},unmute:{id:"video.unmute",defaultMessage:"Unmute sound"},hide:{id:"video.hide",defaultMessage:"Hide video"},expand:{id:"video.expand",defaultMessage:"Expand video"},close:{id:"video.close",defaultMessage:"Close video"},fullscreen:{id:"video.fullscreen",defaultMessage:"Full screen"},exit_fullscreen:{id:"video.exit_fullscreen",defaultMessage:"Exit full screen"}}),R=function(e){var t=Math.floor(e/3600),n=Math.floor((e-3600*t)/60),a=e-3600*t-60*n;return t<10&&(t="0"+t),n<10&&(n="0"+n),a<10&&(a="0"+a),("00"===t?"":t+":")+n+":"+a},p=function(e){var t;if(e.getBoundingClientRect&&e.parentNode&&(t=e.getBoundingClientRect()),!t)return{left:0,top:0};var n=document.documentElement,a=document.body,r=n.clientLeft||a.clientLeft||0,o=window.pageXOffset||a.scrollLeft,i=t.left+o-r,s=n.clientTop||a.clientTop||0,l=window.pageYOffset||a.scrollTop,f=t.top+l-s;return{left:Math.round(i),top:Math.round(f)}},m=function(e,t){var n={},a=p(e),r=e.offsetWidth,o=e.offsetHeight,i=a.top,s=a.left,l=t.pageY,f=t.pageX;return t.changedTouches&&(f=t.changedTouches[0].pageX,l=t.changedTouches[0].pageY),n.y=Math.max(0,Math.min(1,(l-i)/o)),n.x=Math.max(0,Math.min(1,(f-s)/r)),n},g=Object(L.g)(a=function(a){function e(){for(var s,e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return s=a.call.apply(a,[this].concat(t))||this,Object(i.a)(Object(r.a)(s),"state",{currentTime:0,duration:0,volume:.5,paused:!0,dragging:!1,containerWidth:s.props.width,fullscreen:!1,hovered:!1,muted:!1,revealed:void 0===s.props.revealed?"hide_all"!==h.f&&!s.props.sensitive||"show_all"===h.f:s.props.revealed}),Object(i.a)(Object(r.a)(s),"volWidth",50),Object(i.a)(Object(r.a)(s),"volOffset",70),Object(i.a)(Object(r.a)(s),"volHandleOffset",function(e){var t=e*s.volWidth+s.volOffset;return 110<t?110:t}),Object(i.a)(Object(r.a)(s),"setPlayerRef",function(e){(s.player=e)&&e.offsetWidth&&e.offsetWidth!=s.state.containerWidth&&(s.props.cacheWidth&&s.props.cacheWidth(s.player.offsetWidth),s.setState({containerWidth:e.offsetWidth}))}),Object(i.a)(Object(r.a)(s),"setVideoRef",function(e){s.video=e,s.video&&s.setState({volume:s.video.volume,muted:s.video.muted})}),Object(i.a)(Object(r.a)(s),"setSeekRef",function(e){s.seek=e}),Object(i.a)(Object(r.a)(s),"setVolumeRef",function(e){s.volume=e}),Object(i.a)(Object(r.a)(s),"handleMouseDownRoot",function(e){e.preventDefault(),e.stopPropagation()}),Object(i.a)(Object(r.a)(s),"handlePlay",function(){s.setState({paused:!1})}),Object(i.a)(
2018-08-12 13:29:30 +00:00
//# sourceMappingURL=media_container.js.map