PageSourceSearch

https://campaign.network/assets/plugins/cn-campaign-demo/js/campaign-demo.min.js?ver=1784673548

js campaign.network collected 2026-10-03 02:54:57 UTC 6,134 bytes, 18 lines download raw bytes

1(function($){"use strict";const CampaignDemo={currentBudget:"emerging",events:[],translations:{},receipts:[],init:function(){if(!$("#campaignDemo").length)return;typeof cnCampaignDemo<"u"&&(this.events=cnCampaignDemo.events||[],this.translations=cnCampaignDemo.translations||{},this.receipts=cnCampaignDemo.receipts||[]);const savedBudget=localStorage.getItem("cn_selected_budget");savedBudget&&(this.currentBudget=this.mapBudgetTier(savedBudget)),this.renderSpine(),this.renderReceipts(),this.setupEventHandlers(),this.updateBudgetUI()},mapBudgetTier:function(tier){return{bootstrap:"indie",emerging:"emerging",established:"major_label",major:"major_label"}[tier]||"emerging"},renderSpine:function(){const $spine=$("#campaignSpine");if(!$spine.length||this.events.length===0)return;let html="";this.events.forEach((event,index)=>{const icon=this.getEventIcon(event.icon);html+=`
2                    <div class="spine-event" 
3                         data-event-id="${event.id}" 
4                         data-category="${event.category}"
5                         data-index="${index}">
6                        <div class="spine-event-icon">${icon}</div>
7                        <span class="spine-event-category">${event.category}</span>
8                        <div class="spine-event-title">${event.title}</div>
9                        <div class="spine-event-date">${event.date}</div>
10                        <div class="spine-event-cost">${event.original_cost}</div>
11                    </div>
12                `}),$spine.html(html)},getEventIcon:function(iconName){const icons={megaphone:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M3 11l18-5v12L3 13v-2z"/><path d="M11.6 16.8a3 3 0 1 1-5.8-1.6"/></svg>',music:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M9 18V5l12-2v13"/><circle cx="6" cy="18" r="3"/><circle cx="18" cy="16" r="3"/></svg>',video:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="2" y="6" width="14" height="12" rx="2"/><path d="M23 9l-7 3 7 3V9z"/></svg>',trending:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><polyline points="23 6 13.5 15.5 8.5 10.5 1 18"/><polyline points="17 6 23 6 23 12"/></svg>',newspaper:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M4 22h16a2 2 0 002-2V6l-6-4H6a2 2 0 00-2 2v16a2 2 0 002 2z"/><path d="M14 2v4a2 2 0 002 2h4"/><path d="M8 10h8"/><path d="M8 14h8"/><path d="M8 18h4"/></svg>',star:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><polygon points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"/></svg>',tv:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="2" y="7" width="20" height="15" rx="2"/><polyline points="17 2 12 7 7 2"/></svg>',"map-pin":'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0118 0z"/><circle cx="12" cy="10" r="3"/></svg>',trophy:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M6 9H4.5a2.5 2.5 0 010-5H6"/><path d="M18 9h1.5a2.5 2.5 0 000-5H18"/><path d="M4 22h16"/><path d="M10 14.66V17c0 .55-.47.98-.97 1.21C7.85 18.75 7 20.24 7 22"/><path d="M14 14.66V17c0 .55.47.98.97 1.21C16.15 18.75 17 20.24 17 22"/><path d="M18 2H6v7a6 6 0 1012 0V2z"/></svg>',headphones:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M3 18v-6a9 9 0 0118 0v6"/><path d="M21 19a2 2 0 01-2 2h-1a2 2 0 01-2-2v-3a2 2 0 012-2h3v5z"/><path d="M3 19a2 2 0 002 2h1a2 2 0 002-2v-3a2 2 0 00-2-2H3v5z"/></svg>',award:'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="12" cy="8" r="6"/><path d="M15.477 12.89L17 22l-5-3-5 3 1.523-9.11"/></svg>'};return icons[iconName]||icons.star},renderReceipts:function(){const $grid=$("#receiptsGrid");if(!$grid.length||this.receipts.length===0)return;let html="";this.receipts.forEach(receipt=>{const icon=this.getEventIcon(receipt.icon);html+=`
13                    <div class="receipt-card">
14                        <div class="receipt-icon">${icon}</div>
15                        <div class="receipt-metric">${receipt.metric}</div>
16                        <div class="receipt-label">${receipt.label}</div>
17                    </div>
18                `}),$grid.html(html)},setupEventHandlers:function(){const self=this;$(".budget-pill").on("click",function(){const budget=$(this).data("budget");self.currentBudget=budget,self.updateBudgetUI()}),$(document).on("mouseenter",".spine-event",function(){const eventId=$(this).data("event-id"),index=$(this).data("index");$(this).addClass("is-hovered"),self.showTranslationPill(eventId,index,$(this))}),$(document).on("mouseleave",".spine-event",function(){$(this).removeClass("is-hovered"),self.hideTranslationPill()}),$(document).on("click",".spine-event",function(){typeof showRequestAccessModal=="function"&&showRequestAccessModal()})},updateBudgetUI:function(){$(".budget-pill").removeClass("active"),$(`.budget-pill[data-budget="${this.currentBudget}
18"]`).addClass("active"),this.events.forEach((event,index)=>{const translation=this.translations[this.currentBudget]?.[event.id];translation&&$(`.spine-event[data-event-id="${event.id}"] .spine-event-cost`).text(translation.cost)})},showTranslationPill:function(eventId,index,$card){const event=this.events.find(e=>e.id===eventId),translation=this.translations[this.currentBudget]?.[eventId];if(!event||!translation)return;$("#originalValue").text(event.description),$("#adaptedValue").text(translation.action),$("#adaptedCost").text(translation.cost);const $pill=$("#translationPill"),cardOffset=$card.offset(),cardWidth=$card.outerWidth(),containerOffset=$(".campaign-spine-wrapper").offset(),left=cardOffset.left-containerOffset.left+cardWidth/2;$pill.css("left",left+"px"),$pill.addClass("is-visible")},hideTranslationPill:function(){$("#translationPill").removeClass("is-visible")}};$(document).ready(function(){CampaignDemo.init()})})(jQuery);

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.