SILENT KILLERPanel

Current Path: > home > transcarter > public_html > wp-includes > > js


Operation   : Linux host59.registrar-servers.com 4.18.0-513.18.1.lve.2.el8.x86_64 #1 SMP Sat Mar 30 15:36:11 UTC 2024 x86_64
Software     : Apache
Server IP    : 198.54.126.42 | Your IP: 216.73.216.135
Domains      : 1034 Domain(s)
Permission   : [ 0755 ]

Files and Folders in: /home/transcarter/public_html/wp-includes//js

NameTypeSizeLast ModifiedActions
codemirror Directory - -
crop Directory - -
dist Directory - -
imgareaselect Directory - -
jcrop Directory - -
jquery Directory - -
mediaelement Directory - -
plupload Directory - -
swfupload Directory - -
thickbox Directory - -
tinymce Directory - -
admin-bar.js File 10547 bytes May 11 2024 17:28:08.
admin-bar.min.js File 3487 bytes May 11 2024 17:28:08.
api-request.js File 3324 bytes December 01 2020 03:44:06.
api-request.min.js File 1023 bytes April 08 2022 19:07:18.
autosave.js File 22476 bytes March 18 2021 18:01:04.
autosave.min.js File 5807 bytes February 02 2023 16:36:32.
backbone.js File 79742 bytes August 11 2023 15:12:22.
backbone.min.js File 24140 bytes June 27 2024 12:51:44.
clipboard.js File 26807 bytes October 04 2022 14:55:24.
clipboard.min.js File 9009 bytes June 27 2024 12:51:44.
colorpicker.js File 29083 bytes November 17 2012 15:11:30.
colorpicker.min.js File 16517 bytes September 23 2022 18:55:30.
comment-reply.js File 12457 bytes January 10 2023 09:30:14.
comment-reply.min.js File 2981 bytes June 27 2024 12:51:44.
customize-base.js File 25822 bytes May 20 2023 09:19:24.
customize-base.min.js File 7852 bytes February 02 2023 16:36:32.
customize-loader.js File 7903 bytes April 12 2024 16:47:14.
customize-loader.min.js File 3551 bytes February 02 2023 16:36:32.
customize-models.js File 6821 bytes June 25 2020 11:43:08.
customize-models.min.js File 3681 bytes February 02 2023 16:36:32.
customize-preview-nav-menus.js File 15024 bytes July 27 2020 22:35:02.
customize-preview-nav-menus.min.js File 5038 bytes June 27 2024 12:51:44.
customize-preview-widgets.js File 23253 bytes June 20 2020 11:58:10.
customize-preview-widgets.min.js File 7825 bytes February 02 2023 16:36:32.
customize-preview.js File 27960 bytes July 27 2020 22:35:02.
customize-preview.min.js File 10704 bytes February 02 2023 16:36:32.
customize-selective-refresh.js File 33335 bytes April 12 2024 16:47:14.
customize-selective-refresh.min.js File 10695 bytes June 27 2024 12:51:44.
customize-views.js File 5065 bytes June 28 2018 01:30:16.
customize-views.min.js File 2451 bytes January 06 2021 15:29:24.
heartbeat.js File 23952 bytes October 09 2023 20:31:28.
heartbeat.min.js File 6013 bytes October 09 2023 20:31:28.
hoverIntent.js File 7225 bytes January 03 2022 15:03:18.
hoverIntent.min.js File 1499 bytes June 27 2024 12:51:44.
hoverintent-js.min.js File 1718 bytes December 10 2019 01:03:02.
imagesloaded.min.js File 5520 bytes August 11 2023 17:18:26.
json2.js File 18422 bytes October 06 2015 13:02:26.
json2.min.js File 3143 bytes June 27 2024 12:51:44.
masonry.min.js File 24138 bytes June 13 2020 17:53:28.
mce-view.js File 25849 bytes October 09 2023 20:31:28.
mce-view.min.js File 9770 bytes June 27 2024 12:51:44.
media-audiovideo.js File 24976 bytes February 15 2024 16:53:16.
media-audiovideo.min.js File 12058 bytes February 15 2024 16:53:16.
media-editor.js File 29119 bytes July 27 2020 22:35:02.
media-editor.min.js File 10885 bytes February 02 2023 16:36:32.
media-grid.js File 26808 bytes February 15 2024 16:53:16.
media-grid.min.js File 13260 bytes February 15 2024 16:53:16.
media-models.js File 43761 bytes February 15 2024 16:53:16.
media-models.min.js File 13288 bytes June 27 2024 12:51:44.
media-views.js File 271508 bytes May 14 2024 15:49:10.
media-views.min.js File 109998 bytes June 27 2024 12:51:44.
quicktags.js File 22601 bytes September 08 2021 22:29:58.
quicktags.min.js File 11132 bytes February 02 2023 16:36:32.
shortcode.js File 10758 bytes January 29 2020 00:45:18.
shortcode.min.js File 2643 bytes September 23 2022 18:55:30.
swfobject.js File 10231 bytes April 17 2012 22:09:30.
tw-sack.js File 4969 bytes August 22 2012 23:04:18.
tw-sack.min.js File 3288 bytes April 08 2022 19:07:18.
twemoji.js File 32934 bytes February 13 2024 14:36:08.
twemoji.min.js File 15787 bytes June 27 2024 12:51:44.
underscore.js File 68373 bytes September 27 2022 14:18:26.
underscore.min.js File 18833 bytes June 27 2024 12:51:44.
utils.js File 4665 bytes January 29 2020 00:45:18.
utils.min.js File 1864 bytes September 23 2022 18:55:30.
wp-ajax-response.js File 3837 bytes June 21 2024 17:17:14.
wp-ajax-response.min.js File 2505 bytes June 21 2024 17:17:14.
wp-api.js File 46983 bytes January 10 2023 09:30:14.
wp-api.min.js File 14682 bytes June 27 2024 12:51:44.
wp-auth-check.js File 4207 bytes March 18 2021 18:01:04.
wp-auth-check.min.js File 1658 bytes March 18 2021 18:01:04.
wp-backbone.js File 15241 bytes April 12 2024 16:47:14.
wp-backbone.min.js File 3039 bytes April 08 2022 19:07:18.
wp-custom-header.js File 10465 bytes April 10 2021 11:40:06.
wp-custom-header.min.js File 4442 bytes February 02 2023 16:36:32.
wp-embed-template.js File 6779 bytes November 11 2021 02:49:18.
wp-embed-template.min.js File 3174 bytes June 27 2024 12:51:44.
wp-embed.js File 3214 bytes August 10 2023 18:49:18.
wp-embed.min.js File 1251 bytes June 27 2024 12:51:44.
wp-emoji-loader.js File 12204 bytes February 13 2024 14:36:08.
wp-emoji-loader.min.js File 2929 bytes February 13 2024 14:36:08.
wp-emoji-release.min.js File 18726 bytes June 27 2024 12:51:44.
wp-emoji.js File 8969 bytes February 02 2023 00:53:26.
wp-emoji.min.js File 2890 bytes February 02 2023 00:53:26.
wp-list-revisions.js File 970 bytes June 28 2018 01:30:16.
wp-list-revisions.min.js File 597 bytes January 06 2021 15:29:24.
wp-lists.js File 25315 bytes June 24 2023 13:32:20.
wp-lists.min.js File 7521 bytes June 24 2023 13:32:20.
wp-pointer.js File 10233 bytes February 16 2021 20:25:04.
wp-pointer.min.js File 3621 bytes April 08 2022 19:07:18.
wp-sanitize.js File 1350 bytes September 04 2019 16:13:22.
wp-sanitize.min.js File 458 bytes April 08 2022 19:07:18.
wp-util.js File 4679 bytes September 20 2022 02:52:10.
wp-util.min.js File 1426 bytes September 20 2022 02:52:10.
wpdialog.js File 569 bytes January 24 2023 21:13:12.
wpdialog.min.js File 281 bytes January 24 2023 21:13:12.
wplink.js File 21255 bytes June 20 2024 19:27:12.
wplink.min.js File 11332 bytes June 20 2024 19:27:12.
zxcvbn-async.js File 821 bytes June 28 2018 01:30:16.
zxcvbn-async.min.js File 351 bytes February 23 2021 16:45:20.
zxcvbn.min.js File 822237 bytes October 25 2019 23:17:08.

Reading File: /home/transcarter/public_html/wp-includes//js/wp-custom-header.js

/**
 * @output wp-includes/js/wp-custom-header.js
 */

/* global YT */
(function( window, settings ) {

	var NativeHandler, YouTubeHandler;

	/** @namespace wp */
	window.wp = window.wp || {};

	// Fail gracefully in unsupported browsers.
	if ( ! ( 'addEventListener' in window ) ) {
		return;
	}

	/**
	 * Trigger an event.
	 *
	 * @param {Element} target HTML element to dispatch the event on.
	 * @param {string} name Event name.
	 */
	function trigger( target, name ) {
		var evt;

		if ( 'function' === typeof window.Event ) {
			evt = new Event( name );
		} else {
			evt = document.createEvent( 'Event' );
			evt.initEvent( name, true, true );
		}

		target.dispatchEvent( evt );
	}

	/**
	 * Create a custom header instance.
	 *
	 * @memberOf wp
	 *
	 * @class
	 */
	function CustomHeader() {
		this.handlers = {
			nativeVideo: new NativeHandler(),
			youtube: new YouTubeHandler()
		};
	}

	CustomHeader.prototype = {
		/**
		 * Initialize the custom header.
		 *
		 * If the environment supports video, loops through registered handlers
		 * until one is found that can handle the video.
		 */
		initialize: function() {
			if ( this.supportsVideo() ) {
				for ( var id in this.handlers ) {
					var handler = this.handlers[ id ];

					if ( 'test' in handler && handler.test( settings ) ) {
						this.activeHandler = handler.initialize.call( handler, settings );

						// Dispatch custom event when the video is loaded.
						trigger( document, 'wp-custom-header-video-loaded' );
						break;
					}
				}
			}
		},

		/**
		 * Determines if the current environment supports video.
		 *
		 * Themes and plugins can override this method to change the criteria.
		 *
		 * @return {boolean}
		 */
		supportsVideo: function() {
			// Don't load video on small screens. @todo Consider bandwidth and other factors.
			if ( window.innerWidth < settings.minWidth || window.innerHeight < settings.minHeight ) {
				return false;
			}

			return true;
		},

		/**
		 * Base handler for custom handlers to extend.
		 *
		 * @type {BaseHandler}
		 */
		BaseVideoHandler: BaseHandler
	};

	/**
	 * Create a video handler instance.
	 *
	 * @memberOf wp
	 *
	 * @class
	 */
	function BaseHandler() {}

	BaseHandler.prototype = {
		/**
		 * Initialize the video handler.
		 *
		 * @param {Object} settings Video settings.
		 */
		initialize: function( settings ) {
			var handler = this,
				button = document.createElement( 'button' );

			this.settings = settings;
			this.container = document.getElementById( 'wp-custom-header' );
			this.button = button;

			button.setAttribute( 'type', 'button' );
			button.setAttribute( 'id', 'wp-custom-header-video-button' );
			button.setAttribute( 'class', 'wp-custom-header-video-button wp-custom-header-video-play' );
			button.innerHTML = settings.l10n.play;

			// Toggle video playback when the button is clicked.
			button.addEventListener( 'click', function() {
				if ( handler.isPaused() ) {
					handler.play();
				} else {
					handler.pause();
				}
			});

			// Update the button class and text when the video state changes.
			this.container.addEventListener( 'play', function() {
				button.className = 'wp-custom-header-video-button wp-custom-header-video-play';
				button.innerHTML = settings.l10n.pause;
				if ( 'a11y' in window.wp ) {
					window.wp.a11y.speak( settings.l10n.playSpeak);
				}
			});

			this.container.addEventListener( 'pause', function() {
				button.className = 'wp-custom-header-video-button wp-custom-header-video-pause';
				button.innerHTML = settings.l10n.play;
				if ( 'a11y' in window.wp ) {
					window.wp.a11y.speak( settings.l10n.pauseSpeak);
				}
			});

			this.ready();
		},

		/**
		 * Ready method called after a handler is initialized.
		 *
		 * @abstract
		 */
		ready: function() {},

		/**
		 * Whether the video is paused.
		 *
		 * @abstract
		 * @return {boolean}
		 */
		isPaused: function() {},

		/**
		 * Pause the video.
		 *
		 * @abstract
		 */
		pause: function() {},

		/**
		 * Play the video.
		 *
		 * @abstract
		 */
		play: function() {},

		/**
		 * Append a video node to the header container.
		 *
		 * @param {Element} node HTML element.
		 */
		setVideo: function( node ) {
			var editShortcutNode,
				editShortcut = this.container.getElementsByClassName( 'customize-partial-edit-shortcut' );

			if ( editShortcut.length ) {
				editShortcutNode = this.container.removeChild( editShortcut[0] );
			}

			this.container.innerHTML = '';
			this.container.appendChild( node );

			if ( editShortcutNode ) {
				this.container.appendChild( editShortcutNode );
			}
		},

		/**
		 * Show the video controls.
		 *
		 * Appends a play/pause button to header container.
		 */
		showControls: function() {
			if ( ! this.container.contains( this.button ) ) {
				this.container.appendChild( this.button );
			}
		},

		/**
		 * Whether the handler can process a video.
		 *
		 * @abstract
		 * @param {Object} settings Video settings.
		 * @return {boolean}
		 */
		test: function() {
			return false;
		},

		/**
		 * Trigger an event on the header container.
		 *
		 * @param {string} name Event name.
		 */
		trigger: function( name ) {
			trigger( this.container, name );
		}
	};

	/**
	 * Create a custom handler.
	 *
	 * @memberOf wp
	 *
	 * @param {Object} protoProps Properties to apply to the prototype.
	 * @return CustomHandler The subclass.
	 */
	BaseHandler.extend = function( protoProps ) {
		var prop;

		function CustomHandler() {
			var result = BaseHandler.apply( this, arguments );
			return result;
		}

		CustomHandler.prototype = Object.create( BaseHandler.prototype );
		CustomHandler.prototype.constructor = CustomHandler;

		for ( prop in protoProps ) {
			CustomHandler.prototype[ prop ] = protoProps[ prop ];
		}

		return CustomHandler;
	};

	/**
	 * Native video handler.
	 *
	 * @memberOf wp
	 *
	 * @class
	 */
	NativeHandler = BaseHandler.extend(/** @lends wp.NativeHandler.prototype */{
		/**
		 * Whether the native handler supports a video.
		 *
		 * @param {Object} settings Video settings.
		 * @return {boolean}
		 */
		test: function( settings ) {
			var video = document.createElement( 'video' );
			return video.canPlayType( settings.mimeType );
		},

		/**
		 * Set up a native video element.
		 */
		ready: function() {
			var handler = this,
				video = document.createElement( 'video' );

			video.id = 'wp-custom-header-video';
			video.autoplay = true;
			video.loop = true;
			video.muted = true;
			video.playsInline = true;
			video.width = this.settings.width;
			video.height = this.settings.height;

			video.addEventListener( 'play', function() {
				handler.trigger( 'play' );
			});

			video.addEventListener( 'pause', function() {
				handler.trigger( 'pause' );
			});

			video.addEventListener( 'canplay', function() {
				handler.showControls();
			});

			this.video = video;
			handler.setVideo( video );
			video.src = this.settings.videoUrl;
		},

		/**
		 * Whether the video is paused.
		 *
		 * @return {boolean}
		 */
		isPaused: function() {
			return this.video.paused;
		},

		/**
		 * Pause the video.
		 */
		pause: function() {
			this.video.pause();
		},

		/**
		 * Play the video.
		 */
		play: function() {
			this.video.play();
		}
	});

	/**
	 * YouTube video handler.
	 *
	 * @memberOf wp
	 *
	 * @class wp.YouTubeHandler
	 */
	YouTubeHandler = BaseHandler.extend(/** @lends wp.YouTubeHandler.prototype */{
		/**
		 * Whether the handler supports a video.
		 *
		 * @param {Object} settings Video settings.
		 * @return {boolean}
		 */
		test: function( settings ) {
			return 'video/x-youtube' === settings.mimeType;
		},

		/**
		 * Set up a YouTube iframe.
		 *
		 * Loads the YouTube IFrame API if the 'YT' global doesn't exist.
		 */
		ready: function() {
			var handler = this;

			if ( 'YT' in window ) {
				YT.ready( handler.loadVideo.bind( handler ) );
			} else {
				var tag = document.createElement( 'script' );
				tag.src = 'https://www.youtube.com/iframe_api';
				tag.onload = function () {
					YT.ready( handler.loadVideo.bind( handler ) );
				};

				document.getElementsByTagName( 'head' )[0].appendChild( tag );
			}
		},

		/**
		 * Load a YouTube video.
		 */
		loadVideo: function() {
			var handler = this,
				video = document.createElement( 'div' ),
				// @link http://stackoverflow.com/a/27728417
				VIDEO_ID_REGEX = /^.*(?:(?:youtu\.be\/|v\/|vi\/|u\/\w\/|embed\/)|(?:(?:watch)?\?v(?:i)?=|\&v(?:i)?=))([^#\&\?]*).*/;

			video.id = 'wp-custom-header-video';
			handler.setVideo( video );

			handler.player = new YT.Player( video, {
				height: this.settings.height,
				width: this.settings.width,
				videoId: this.settings.videoUrl.match( VIDEO_ID_REGEX )[1],
				events: {
					onReady: function( e ) {
						e.target.mute();
						handler.showControls();
					},
					onStateChange: function( e ) {
						if ( YT.PlayerState.PLAYING === e.data ) {
							handler.trigger( 'play' );
						} else if ( YT.PlayerState.PAUSED === e.data ) {
							handler.trigger( 'pause' );
						} else if ( YT.PlayerState.ENDED === e.data ) {
							e.target.playVideo();
						}
					}
				},
				playerVars: {
					autoplay: 1,
					controls: 0,
					disablekb: 1,
					fs: 0,
					iv_load_policy: 3,
					loop: 1,
					modestbranding: 1,
					playsinline: 1,
					rel: 0,
					showinfo: 0
				}
			});
		},

		/**
		 * Whether the video is paused.
		 *
		 * @return {boolean}
		 */
		isPaused: function() {
			return YT.PlayerState.PAUSED === this.player.getPlayerState();
		},

		/**
		 * Pause the video.
		 */
		pause: function() {
			this.player.pauseVideo();
		},

		/**
		 * Play the video.
		 */
		play: function() {
			this.player.playVideo();
		}
	});

	// Initialize the custom header when the DOM is ready.
	window.wp.customHeader = new CustomHeader();
	document.addEventListener( 'DOMContentLoaded', window.wp.customHeader.initialize.bind( window.wp.customHeader ), false );

	// Selective refresh support in the Customizer.
	if ( 'customize' in window.wp ) {
		window.wp.customize.selectiveRefresh.bind( 'render-partials-response', function( response ) {
			if ( 'custom_header_settings' in response ) {
				settings = response.custom_header_settings;
			}
		});

		window.wp.customize.selectiveRefresh.bind( 'partial-content-rendered', function( placement ) {
			if ( 'custom_header' === placement.partial.id ) {
				window.wp.customHeader.initialize();
			}
		});
	}

})( window, window._wpCustomHeaderSettings || {} );

SILENT KILLER Tool