JSFiddle - React, Tailwind, and code Playground

by denniswaltermartinez

HTML

<a href="http://www.youtube.com/watch?v=U7F_SJgjsbI" data-ob="lightbox">link</a>

CSS

/*
 * version: 3.0.0
 * package: OrangeBox
 * author: David Paul Hamilton - http://orangebox.davidpaulhamilton.net
 * copyright: Copyright (c) 2011 David Hamilton / DavidPaulHamilton.net All rights reserved.
 * license: GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
 */
#ob_overlay {
	background-color:#333;
	height:100%;
	left:0;
	position:fixed;
	top:0;
	width:100%;
	z-index:1000;
}
#ob_container {
	position:absolute;
	top:0;
	left:0;
	margin:0;
	padding:0;
	width:100%;
	height:100%;
	z-index:1001;
}
#ob_float {
	float:left;
	height:50%;
	min-width:100%;
}
#ob_content {
	clear:both;
	cursor:default;
	position:relative;
	margin:22px auto 44px;
	background-color:#fff;
	border:0 solid #fff;
	-webkit-box-shadow: 0px 0px 8px 2px #222222;
	-moz-box-shadow: 0px 0px 8px 2px #222222;
	line-height:0;
	display:none;
	z-index:1003;
}
#ob_iframe {
	-webkit-overflow-scrolling:touch;
	overflow:auto;
	font-size:0;
}
#ob_caption {
	color:#333;
	background-color:#fff;
	font-size:small;
}
#ob_caption p {
	padding:0;
	margin:10px;
	cursor:auto;
	line-height:1.625em;
}
#ob_video_wrapper {
	background:#000;
}
#ob_image {
	display:block;
	margin:0 auto;
}
#ob_inline {
	overflow:auto;
	cursor:auto;
}
#ob_inline .inline_content {
	padding:20px;
	line-height:1.625em;
}
#ob_load {
	-moz-border-radius:5px;
	background:url(loading.gif) no-repeat center;
	background-color:#fff;
	border-radius:5px;
	height:40px;
	left:50%;
	position:fixed;
	top:50%;
	width:40px;
	margin:-25px 0 0 -25px;
	padding:5px;
	-webkit-box-shadow: 0px 0px 8px 2px #222222;
	-moz-box-shadow: 0px 0px 8px 2px #222222;
	z-index:1002;
}
#ob_error {
	text-align:center;
	padding:10px;
}
#ob_close {
	background:url(buttons.png);
	cursor:pointer;
	height:30px;
	left:-26px;
	position:absolute;
	top:-26px;
	width:30px;
	z-index:1005;
}
#ob_title {
	color:#fff;
	left:auto;
	position:absolute;
	margin-left:15px;
	right:0;
	text-align:right;
	z-index:1004;
	line-height:1em;
	cursor:auto;
}
#ob_left,#ob_right...

JavaScript

/*
 * version: 3.0.0
 * package: OrangeBox
 * author: David Paul Hamilton - http://davidpaulhamilton.net/orangebox
 * copyright: Copyright (c) 2012 David Hamilton / DavidPaulHamilton.net All rights reserved.
 * license: GNU/GPL license: http://www.gnu.org/copyleft/gpl.html
 */

if(typeof oB!=='undefined'){console.log('OrangeBox: Variable "oB", used by OrangeBox, is already defined');}else{var oB;(function($){oB={gallery:[],settings:{autoplay:false,searchTerm:'lightbox',fadeControls:false,keyboardNavigation:true,orangeControls:false,showClose:true,showDots:false,showNav:true,addThis:true,addThisServices:'twitter,facebook,digg,delicious,more',notFound:'Not Found',overlayOpacity:0.95,contentBorderWidth:4,contentRoundedBorder:true,contentMinSize:[100,200],contentMaxSize:[0.75,0.75],videoAspect:[390,640],fadeTime:200,slideshowTimer:3000,streamItems:10,logging:false,checkAlias:true},methods:{init:function(o){function checkURL(searchTerm){if(oB.ourl.match(/#\..{1,}\.facebook/)){oB.ourl=oB.ourl.substr(0,oB.ourl.search(/#\..{1,}\.facebook/));}
    if(oB.ourl.match(/^#\w{1,}$/)&&$('#'+oB.ourl).length>0){oB.methods.create($('#'+oB.ourl));}else{$(searchTerm).each(function(){var href=$(this).attr('href');href=href.replace(/\//gi,'').replace(/\./gi,'').replace(/:/gi,'').replace(/\?/gi,'').replace(/&/gi,'').replace(/\=/gi,'').replace(/#/gi,'');if(href.indexOf(oB.ourl)!==-1){oB.methods.create($(this));return false;}});}}
    if(!$('#ob_content').length){if(o){$.extend(oB.settings,o);}
        var searchTerm='a[data-ob*=lightbox], area[data-ob*=lightbox], a[rel*=lightbox], area[rel*=lightbox]';if(oB.settings.searchTerm!==""){searchTerm='a[data-ob*='+oB.settings.searchTerm+'], area[data-ob*='+oB.settings.searchTerm+'], a[rel*='+oB.settings.searchTerm+'], area[rel*='+oB.settings.searchTerm+']';}
        oB.windowURL=window.location.href;if(oB.windowURL.match(/(&|\?)orangebox=/)){oB.windowURL=oB.windowURL.substr(0,oB.windowURL.search(/(&|\?)orangebox=/));}
       ...