1/*! js-cookie v3.0.5 | MIT */ 2!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self,function(){var n=e.Cookies,o=e.Cookies=t();o.noConflict=function(){return e.Cookies=n,o}}())}(this,(function(){"use strict";function e(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)e[o]=n[o]}return e}var t=function t(n,o){function r(t,r,i){if("undefined"!=typeof document){"number"==typeof(i=e({},o,i)).expires&&(i.expires=new Date(Date.now()+864e5*i.expires)),i.expires&&(i.expires=i.expires.toUTCString()),t=encodeURIComponent(t).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var c="";for(var u in i)i[u]&&(c+="; "+u,!0!==i[u]&&(c+="="+i[u].split(";")[0]));return document.cookie=t+"="+n.write(r,t)+c}}return Object.create({set:r,get:function(e){if("undefined"!=typeof document&&(!arguments.length||e)){for(var t=document.cookie?document.cookie.split("; "):[],o={},r=0;r<t.length;r++){var i=t[r].split("="),c=i.slice(1).join("=");try{var u=decodeURIComponent(i[0]);if(o[u]=n.read(c,u),e===u)break}catch(e){}}return e?o[e]:o}},remove:function(t,n){r(t,"",e({},n,{expires:-1}))},withAttributes:function(n){return t(this.converter,e({},this.attributes,n))},withConverter:function(n){return t(e({},this.converter,n),this.attributes)}},{attributes:{value:Object.freeze(o)},converter:{value:Object.freeze(n)}})}({read:function(e){return'"'===e[0]&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}},{path:"/"});return t})); 3 4jQuery(function($){ 5 "use strict" 6 7 function get_current_show() { 8 //Get the current show data 9 $.post( 10 crudScriptURL, 11 { 12 "action" : "show-time-curd", 13 "crud-action" : "read", 14 "read-type" : "current" 15 }, 16 function (currentShowJSON) { 17 var schedule = $.parseJSON(currentShowJSON); 18 var outputHTML = ''; 19 var currentShow = schedule['current-show']; 20 var joanurl = ''; 21 22 if (currentShow.showName){ 23 var currentShowName = currentShow.showName; 24 var showName = currentShow.showName; 25 //var imageURL = currentShow.imageURL; 26 var jimageURL = currentShow.jock_image_url; 27 var linkURL = currentShow.linkURL; 28 var imageURL = currentShow.imageURL; 29 var showImage = currentShow.display_jock_image; 30 var startClock = currentShow.startClock; 31 var endClock = currentShow.endClock; 32 var showStatus = currentShow.showStatus; 33 var urlTarget = currentShow.url_target; 34 var joan_pn_image = joan_front_obj.joan_pn_image; 35 36 if (linkURL){ 37 currentShowName = '<a target="' + urlTarget + '" href="' + linkURL + '">' + currentShowName + '</a>'; 38 joanurl = linkURL; 39 } 40 41 var status_label = ''; 42 if(showStatus == 'late') { 43 status_label += ' <small>(<i>' + joan_front_obj.starting_late + ')</i></small><br>'; 44 } 45 else if(showStatus=='canceled') { 46 status_label += ' <small>(<i>' + joan_front_obj.Canceled + ')</i></small><br>'; 47 } 48 else /*if(showStatus=='normal')*/{ 49 status_label += ' <small>(<i>' + joan_front_obj.Ontime + ')</i></small><br>'; 50 } 51 52 if( joan_front_obj.label_status == 'hide' ){ 53 status_label = ''; 54 } 55 56 //outputHTML += '<img src='+imageURL+' style=""/>'; 57 if( joan_pn_image == 'all' || joan_pn_image == 'text' ){ 58 outputHTML += '<h6 class="current-show">' + currentShowName + '</h6>'; 59 } 60 outputHTML += '<h6>' + startClock + ' - ' + endClock + ' ' + status_label + '</h6>'; 61 /* 62 if(showStatus=='late'){ 63 outputHTML += ' <small>(<i>' + joan_front_obj.starting_late + ')</i></small><br>'; 64 } 65 else if(showStatus=='canceled'){ 66 outputHTML += ' <small>(<i>' + joan_front_obj.Canceled + ')</i></small><br>'; 67 } 68 else if(showStatus=='normal'){ 69 outputHTML += ' <small>(<i>' + joan_front_obj.Ontime + ')</i></small><br>'; 70 } 71 */ 72 73 //if (imageURL && '0' != showImage){ 74 if( joan_pn_image == 'all' || joan_pn_image == 'image' ){ 75 if ( imageURL ){
76 if (linkURL){ 77 outputHTML += '<a target="' + urlTarget + '" href="' + linkURL + '"><img class="joan-image-thumbnail" src="' + imageURL + '" alt="' + currentShow.showName + '" /></a>'; 78 } 79 else { 80 outputHTML += '<img class="joan-image-thumbnail" src="' + imageURL + '" alt="' + currentShow.showName + '" />'; 81 } 82 } 83 } 84 85 //share Button 86 if( 'show' == joan_front_obj.fb_status || 'show' == joan_front_obj.tw_status ){ 87 outputHTML += '<div class="share-it social-share-btns">'; 88 if( 'show' == joan_front_obj.fb_status ){ 89 outputHTML += '<button type="button" data-type="fb" data-id="' + currentShow.id + '" data-text="Live on ' + showName + ' @ ' + startClock + ' - ' + endClock + ' - ' + blog_name + '" class="shareBtn share-btn fb-share-button share-btn-facebook" data-joanurl="'+ joanurl +'"><i class="joan-icon icon-facebook-squared"></i></button>'; 90 } 91 if( 'show' == joan_front_obj.tw_status ){ 92 outputHTML += '<button type="button" data-type="tw" data-id="' + currentShow.id + '" data-text="Live on ' + showName + ' @ ' + startClock + ' - ' + endClock + ' - ' + blog_name + '. ' + joan_front_obj.follow_us + ' @' + tw_username + '" data-username="' + tw_username + '" data-joanurl="'+ joanurl +'" class="shareBtn share-btn tw-share-button share-btn-twitter"><i class="joan-icon icon-x-square"></i></button>'; 93 } 94 outputHTML += '</div>'; 95 } 96 97 } 98 else { 99 outputHTML += '<h6 class="current-show">' + currentShow + '<h6>'; 100 101 //share Button 102 //outputHTML += '<div class="share-it">'; 103 //outputHTML += '<button type="button" data-type="fb" data-id="' + currentShow.id + '" data-text="Live on ' + showName + ' @ ' + startClock + ' - ' + endClock + ' - ' + blog_name + '" class="shareBtn fb-share-button"><i class="fa fa-facebook"></i></button>'; 104 //outputHTML += '<button type="button" data-type="tw" data-id="' + currentShow.id + '" data-text="Live on ' + showName + ' @ - ' + startClock + ' - ' + endClock + ' - ' + blog_name + '" data-username="' + tw_username + '" class="shareBtn tw-share-button"><i class="fa fa-twitter"></i></button>'; 105 //outputHTML += '</div>'; 106 } 107 108 var upcomingShow = schedule['upcoming-show']; 109 if ( upcomingShow ){ 110 var upcomingShowName = upcomingShow.showName; 111 if( upcomingShowName === undefined ){ 112 outputHTML += '<h6 class="upcoming-show"><strong>' + joan_front_obj.Upnext + ':</strong> ' + joan_front_obj.no_upcoming_show + '<h6>'; 113 } 114 else{ 115 var upcomingShowLink = upcomingShow.linkURL; 116 var imageURL = upcomingShow.imageURL; 117 var showStatus = upcomingShow.showStatus; 118 var upcomingStartClock = upcomingShow.startClock; 119 var upcomingEndClock = upcomingShow.endClock; 120 var showImage = upcomingShow.display_jock_image; 121 var urlTarget = upcomingShow.url_target; 122 123 //outputHTML += '<img src=' + imageURL + ' style=""/>'; 124 if (upcomingShowLink){ 125 outputHTML += '<h6 class="upcoming-show"><strong>' + joan_front_obj.Upnext + ':</strong> <a target="_blank" href="' + upcomingShowLink + '">' + upcomingShowName + '</a></h6>'; 126 } else { 127 outputHTML += '<h6 class="upcoming-show"><strong>' + joan_front_obj.Upnext + ':</strong> ' + upcomingShowName + '</h6>'; 128 } 129 130 var status_label = ''; 131 if(showStatus == 'late') { 132 status_label += ' <small>(<i>' + joan_front_obj.starting_late + ')</i></small>'; 133 } 134 else if(showStatus == 'canceled') { 135 status_label += ' <small>(<i>' + joan_front_obj.Canceled + ')</i></small>'; 136 } 137 else /*if(showStatus=='normal')*/{ 138 status_label += ' <small>(<i>' + joan_front_obj.Ontime + ')</i></small>'; 139 } 140 141 if( joan_front_obj.label_status == 'hide' ){ 142 status_label = ''; 143 } 144 145 outputHTML += '<h6>'+upcomingStartClock + ' - ' + upcomingEndClock + ' ' + status_label + '</h6>'; 146 147 /* 148 if(showStatus=='late') { 149 outputHTML += ' <small>(<i>' + joan_front_obj.starting_late + ')</i></small>'; 150 } 151 else if(showStatus=='canceled') { 152 outputHTML += ' <small>(<i>' + joan_front_obj.Canceled + ')</i></small>'; 153 } 154 else{ 155 outputHTML += ' <small>(<i>' + joan_front_obj.Ontime + ')</i></small>'; 156 } 157 */ 158 159 //if (imageURL && '0' != showImage){ 160 if ( imageURL ){
161 if (linkURL){ 162 outputHTML += '<a target="' + urlTarget + '" href="' + linkURL + '"><img class="joan-image-thumbnail" src="' + imageURL + '" alt="' + currentShow.showName + '" /></a>'; 163 } 164 else { 165 outputHTML += '<img class="joan-image-thumbnail" src="' + imageURL + '" alt="' + currentShow.showName + '" />'; 166 } 167 } 168 169 } 170 } 171 172 $('.joan-now-playing, #Onlive').html(outputHTML); 173 //Set a timer to update the widget every 2 minutes 174 setTimeout( 175 get_current_show, 176 (120 * 1000) 177 ); 178 } 179 ); 180 } 181 182 get_current_show(); 183 184 $(document).on('click', '.shareBtn', function( e ){ 185 var id = $(this).data('id'); 186 var type = $(this).data('type'); 187 var linkURL = $(this).data('joanurl'); 188 var shareUrl = ''; 189 190 if( 'fb' == type ){ 191 192 var shareUrl = blog_url + 'joan/' + id; 193 if( '' != linkURL ){ 194 shareUrl = linkURL; 195 } 196 197 FB.ui({ 198 method: 'share', 199 mobile_iframe: true, 200 href: blog_url + 'joan/' + id 201 }, 202 function(response){ 203 console.log(response); 204 }); 205 } 206 207 if( 'tw' == type ){ 208 var text = $(this).data('text'); 209 var username = $(this).data('username'); 210 211 var shareUrl = blog_url + 'joan/' + id; 212 if( '' != linkURL ){ 213 shareUrl = linkURL; 214 } 215 216 //window.open( 'https://twitter.com/intent/tweet?text='+ text +'&url=' + shareUrl + '&via=' + username, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=400,width=550' ); 217 //window.open( 'https://twitter.com/intent/tweet?text='+ text +'&url=' + shareUrl + '&via=' + username, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=400,width=550' ); 218 window.open( 'https://x.com/intent/tweet?text='+ text +'&url=' + shareUrl, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=400,width=550' ); 219 } 220 221 }); 222 223 jQuery(document).ready(function(){ 224 setTimeout( 225 function(){ 226 var cookies = JSON.parse( JSON.stringify(Cookies.get()) ); 227 var currentView = ('undefined' !== typeof cookies.current_view ? cookies.current_view : 'grid'); 228 if( 'grid' == currentView ){ 229 var width = 100/joan_front_obj.grid_per_row; 230 jQuery('.grid .item').addClass('col-25'); 231 jQuery('.grid .item').css('width', width + '%'); 232 jQuery('.grid span.separator').replaceWith('<div class="separator"></div>'); 233 } 234 else { 235 jQuery('.grid .item').removeClass('col-25'); 236 jQuery('.grid .item').css('width', '99%'); 237 jQuery('.grid div.separator').replaceWith('<span class="separator"></span>'); 238 } 239 }, 240 100 241 ); 242 }); 243 244}); 245 246function listView( count ){ 247 var width = 100/count; 248 jQuery('.grid .item').removeClass('col-25'); 249 jQuery('.grid .item').css('width', '99%'); 250 jQuery('.grid div.separator').replaceWith('<span class="separator"></span>'); 251 Cookies.set('current_view', 'list'); 252} 253 254function gridView( count ){ 255 var width = 100/count; 256 jQuery('.grid .item').addClass('col-25'); 257 jQuery('.grid .item').css('width', width + '%'); 258 jQuery('.grid span.separator').replaceWith('<div class="separator"></div>'); 259 Cookies.set('current_view', 'grid'); 260}
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.