vendor: 3,618 bytes, lines 1-102
1var _____WB$wombat$assign$function_____ = function(name) {return (self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init(name)) || self[name]; }; 2if (!self.__WB_pmw) { self.__WB_pmw = function(obj) { this.__WB_source = obj; return this; } } 3{ 4 let window = _____WB$wombat$assign$function_____("window"); 5 let self = _____WB$wombat$assign$function_____("self"); 6 let document = _____WB$wombat$assign$function_____("document"); 7 let location = _____WB$wombat$assign$function_____("location"); 8 let top = _____WB$wombat$assign$function_____("top"); 9 let parent = _____WB$wombat$assign$function_____("parent"); 10 let frames = _____WB$wombat$assign$function_____("frames"); 11 let opener = _____WB$wombat$assign$function_____("opener"); 12 13/*global jQuery */ 14/*jshint multistr:true browser:true */ 15/*! 16* FitVids 1.0 17* 18* Copyright 2011, Chris Coyier - http://css-tricks.com + Dave Rupert - http://daverupert.com 19* Credit to Thierry Koblentz - http://www.alistapart.com/articles/creating-intrinsic-ratios-for-video/ 20* Released under the WTFPL license - http://sam.zoy.org/wtfpl/ 21* 22* Date: Thu Sept 01 18:00:00 2011 -0500 23*/ 24 25(function( $ ){ 26 27 "use strict"; 28 29 $.fn.fitVids = function( options ) { 30 var settings = { 31 customSelector: null 32 }; 33 34 if(!document.getElementById('fit-vids-style')) { 35 36 var div = document.createElement('div'), 37 ref = document.getElementsByTagName('base')[0] || document.getElementsByTagName('script')[0]; 38 39 div.className = 'fit-vids-style'; 40 div.id = 'fit-vids-style'; 41 div.style.display = 'none'; 42 div.innerHTML = '­<style> \ 43 .fluid-width-video-wrapper { \ 44 width: 100%; \ 45 position: relative; \ 46 padding: 0; \ 47 } \ 48 \ 49 .fluid-width-video-wrapper iframe, \ 50 .fluid-width-video-wrapper object, \ 51 .fluid-width-video-wrapper embed { \ 52 position: absolute; \ 53 top: 0; \ 54 left: 0; \ 55 width: 100%; \ 56 height: 100%; \ 57 } \ 58 </style>'; 59 60 ref.parentNode.insertBefore(div,ref); 61 62 } 63 64 if ( options ) { 65 $.extend( settings, options ); 66 } 67 68 return this.each(function(){ 69 var selectors = [ 70 "iframe[src*='player.vimeo.com']", 71 "iframe[src*='youtube.com']", 72 "iframe[src*='youtube-nocookie.com']", 73 "iframe[src*='kickstarter.com'][src*='video.html']", 74 "object", 75 "embed" 76 ]; 77 78 if (settings.customSelector) { 79 selectors.push(settings.customSelector); 80 } 81 82 var $allVideos = $(this).find(selectors.join(',')); 83 $allVideos = $allVideos.not("object object"); // SwfObj conflict patch 84 85 $allVideos.each(function(){ 86 var $this = $(this); 87 if (this.tagName.toLowerCase() === 'embed' && $this.parent('object').length || $this.parent('.fluid-width-video-wrapper').length) { return; } 88 var height = ( this.tagName.toLowerCase() === 'object' || ($this.attr('height') && !isNaN(parseInt($this.attr('height'), 10))) ) ? parseInt($this.attr('height'), 10) : $this.height(), 89 width = !isNaN(parseInt($this.attr('width'), 10)) ? parseInt($this.attr('width'), 10) : $this.width(), 90 aspectRatio = height / width; 91 if(!$this.attr('id')){ 92 var videoID = 'fitvid' + Math.floor(Math.random()*999999); 93 $this.attr('id', videoID); 94 } 95 $this.wrap('<div class="fluid-width-video-wrapper"></div>').parent('.fluid-width-video-wrapper').css('padding-top', (aspectRatio * 100)+"%"); 96 $this.removeAttr('height').removeAttr('width'); 97 }); 98 }); 99 }; 100})( jQuery ); 101 102}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.