HEX
Server: LiteSpeed
System: Linux eko108.isimtescil.net 4.18.0-477.21.1.lve.1.el8.x86_64 #1 SMP Tue Sep 5 23:08:35 UTC 2023 x86_64
User: uyarreklamcomtr (11202)
PHP: 7.4.33
Disabled: opcache_get_status
Upload Files
File: /var/www/vhosts/uyarreklam.com.tr/httpdocs/so-video-widget.js.tar
uyarreklam.com.tr/httpdocs/wp-content/plugins/so-widgets-bundle/widgets/video/js/so-video-widget.js000064400000002433151554350470032516 0ustar00var/www/vhosts/* globals jQuery, sowb */

var sowb = window.sowb || {};

jQuery( function ( $ ) {
	sowb.setupVideoPlayers = () => {
		const $video = $( 'video.sow-video-widget' );

		if ( $video.data( 'initialized' ) ) {
			return $video;
		}

		$video.each( function () {
			const $this = $( this );

			// Do we need to set up Media Elements?
			if (
				typeof $.fn.mediaelementplayer === 'function' &&
				$this.attr( 'controls' )
			) {
				$this.mediaelementplayer();
				return;
			}

			// Controls are hidden. Add click event to play/pause video.
			$this.on( 'click', ( e ) => {
				if ( e.target.nodeName !== 'VIDEO' ) {
					return;
				}

				const video = e.target;
				video.paused ? video.play() : video.pause();
			} );
		} );

		if ( typeof $.fn.fitVids === 'function' ) {
			$( '.sow-video-wrapper.use-fitvids' ).fitVids();
		}

		$video.data( 'initialized', true );
	};
	sowb.setupVideoPlayers();

	$( sowb ).on( 'setup_widgets', sowb.setupVideoPlayers );

	jQuery( '.sow-video-wrapper.use-fitvids' ).on( 'setupFitVids', function() {
		$( this ).fitVids();
	} );
} );

// It's possible that the video was blocked during initial setup by the SO Embed Blocker.
jQuery( document ).on('siteorigin_embed_blocker_unblock', () => {
	jQuery( '.sow-video-wrapper.use-fitvids' ).trigger( 'setupFitVids' );
} );