PageSourceSearch

https://techcrunch.com/_static/??/wp-content/themes/tc-24/dist/js/…/js/widget.subscribe.js?m=1781027138j

js techcrunch.com collected 2026-09-24 05:18:08 UTC 2,832 bytes, 59 lines download raw bytes

1!function(){"use strict";const e="turnstile_verified",t="turnstile_failed";(new URLSearchParams(window.location.search).get("turnstile_is_bot")??"")&&(sessionStorage.removeItem(t),localStorage.removeItem(e)),(()=>{const e=new URL(window.location.href);if(!e.pathname.startsWith("/events/"))return;const t=e.hostname,n=["promo","ref","utm_campaign","utm_content","utm_medium","utm_source","utm_term"].filter((t=>e.searchParams.has(t)));if(!n.length)return;const o=t=>{let o=t.getAttribute("href");o&&(t.dataset.trackingParamsApplied||(n.forEach((t=>{const n=e.searchParams.get(t);if(n&&!o.includes(`${t}=`)){const e=o.includes("?")?"&":"?";o+=`${e}${t}=${n}`}})),t.setAttribute("href",o),t.dataset.trackingParamsApplied="true"))},r=(e=document)=>{e.querySelectorAll(`a[href^="https://${t}/events"], a[href^="/events/"]`).forEach(o)};r();const s=new MutationObserver((function(e){e.forEach((e=>{e.addedNodes.forEach((e=>{e.nodeType===Node.ELEMENT_NODE&&(e.matches?.("a")?r(e.parentNode):r(e))}))}))}));(()=>{const e=document.body||document.documentElement||document;try{s.observe(e,{childList:!0,subtree:!0})}catch(e){document.addEventListener("DOMContentLoaded",(()=>{document.body&&s.observe(document.body,{childList:!0,subtree:!0})}),{once:!0})}})()})()}();;
2(function ($) {
3	"use strict";
4	$(function () {
5		$('#sailthru-modal').hide();
6
7		$( ".show_shortcode" ).on( "click", function( e ) {
8			e.preventDefault();
9			var posTop = $(this).offset().top;
10			var modal = $( "#sailthru-modal");
11			modal.css("top", '100px');
12			modal.css("left", Math.max(0, (($(window).width() - $(modal).outerWidth()) / 2) + $(window).scrollLeft()) + "px");
13
14			$('.sailthru_shortcode_hidden .sailthru-signup-widget-close').show();
15			modal.fadeIn();
16		});
17
18		$('#sailthru-modal .sailthru-signup-widget-close').click(function(){
19			$('#sailthru-modal ').fadeOut();
20		}) ;
21
22		// when a user clicks subscribe
23		$(".sailthru-add-subscriber-form").submit(async function(e){
24
25			e.preventDefault();
26			var recaptcha = $("#sailthruToken");
27			var siteKey = $("#siteKey").val();
28			if (!recaptcha.val() && siteKey) {
29				var token = await grecaptcha.execute(siteKey, {action: 'homepage'});
30				recaptcha.val(token);
31			}
32
33			var user_input = $(this).serialize();
34			var form = $(this);
35			$.ajax({
36				url: sailthru_vars.ajaxurl,
37				type: 'post',
38				data: user_input,
39				dataType: "json",
40				xhrFields: {
41					withCredentials: true
42				},
43				success: function (data, status) {
44					if (data.success == false) {
45						$('#' + form.attr('id') + " .sailthru-add-subscriber-errors").html(data.message);
46					} else {
47						$('#sailthru-modal .sailthru-signup-widget-close').fadeIn();
48						$(form).html('');
49						$(form).parent().find(".success").show();
50						$(form).parent().find(".hide_toggle").hide();
51					}
52				}
53			});
54
55		});
56
57	});
58}(jQuery));
59;

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.