PageSourceSearch

https://syracusecityschools.com/dist/assets/EventsRepository-BfSVWlH7.js

js syracusecityschools.com collected 2026-09-24 09:13:52 UTC 9,286 bytes, 2 lines download raw bytes

1import{g as R}from"./_commonjsHelpers-CE1G-McA.js";import{o as M,s as t,n as T,b as d,a as B}from"./schemas-BdgNnLKl.js";const G=M({id:t(),title:t(),start_date:t(),start_time:t().nullable(),start_datetime:t(),end_date:t(),end_time:t().nullable(),end_datetime:t(),timezone:t().optional(),all_day:d(),description:t(),color:t(),text_color:t(),calendar_id:T(),calendar_name:t(),feed_id:T().nullable().optional(),feed_source:t().nullable().optional(),address:t().nullable().optional(),link:t().nullable().optional(),event_url:t()}),W=M({events:B(G),site_timezone:t(),error:t()}),V=M({success:d(),error:t().optional().nullable(),data:W}),re={FOUR_EVENTS:0,SIX_EVENTS:1,FOUR_EVENTS_FULL_CALENDAR:2,FOUR_EVENTS_FACEBOOK_FEED:3,FULL_CALENDAR:4,GRID:5},se={LEFT:1,RIGHT:2},oe={RECTANGLE:0,CIRCLE:1},ie=M({pageAccessID:t(),itemID:T(),componentTitle:t(),componentIntro:t(),editable:d(),isStackItemVisible:d(),hasBackgroundBreakout:d(),hasContentBreakout:d(),hasStackBackground:d(),showCalendar:d(),calendarID:T(),calendarApiID:T(),calendarLink:t(),calendarStyle:T(),componentHeadingAlignment:T(),gridTopBandShowImageOverlay:d(),hasGridTopBg:d(),hasGridBottomBg:d(),numberOfEvents:T(),standaloneCalendar:d().nullable(),calendarDateShape:T(),isMealCalendar:d(),hasComponentBody:d(),componentBodyPosition:T(),componentBodyContent:t(),componentBodyHeading:t().nullable(),useDefaultComponentHeadingColors:d(),facebookFeedURL:t().nullable(),facebookFeedHeading:t().nullable(),"--ss-calendar-events-background-color":t(),"--ss-calendar-events-background-image":t(),"--ss-calendar-events-background-opacity":t(),"--ss-calendar-events-optional-heading-color":t(),"--ss-calendar-events-optional-heading-accent-line-color":t(),"--ss-calendar-events-event-date-color":t(),"--ss-calendar-events-event-date-bg-color":t(),"--ss-calendar-events-event-date-font-family":t(),"--ss-calendar-events-event-date-font-weight":t(),"--ss-calendar-events-event-date-font-style":t().or(d().transform($=>$?"italic":"normal")),"--ss-calendar-events-event-content-color":t(),"--ss-calendar-events-event-time-color":t(),"--ss-calendar-events-grid-event-details-time-color":t(),"--ss-calendar-events-event-title-font-family":t(),"--ss-calendar-events-event-title-font-weight":t(),"--ss-calendar-events-event-title-font-style":t().or(d().transform($=>$?"italic":"normal")),"--ss-calendar-events-component-intro-text-color":t().optional(),"--ss-calendar-events-component-intro-link-color":t().optional(),"--ss-calendar-events-calendar-link-color":t(),"--ss-calendar-events-calendar-link-background-color":t(),"--ss-calendar-events-calendar-link-font-family":t(),"--ss-calendar-events-calendar-link-font-weight":t(),"--ss-calendar-events-calendar-link-font-size":t(),"--ss-calendar-events-grid-top-bg-color":t(),"--ss-calendar-events-grid-bottom-bg-color":t()});var y={exports:{}},Z=y.exports,L;function q(){return L||(L=1,(function($,S){(function(v,m){$.exports=m()})(Z,(function(){var v="minute",m=/[+-]\d\d(?::?\d\d)?/g,z=/([+-]|\d\d)/g;return function(D,i,r){var a=i.prototype;r.utc=function(e){var n={date:e,utc:!0,args:arguments};return new i(n)},a.utc=function(e){var n=r(this.toDate(),{locale:this.$L,utc:!0});return e?n.add(this.utcOffset(),v):n},a.local=function(){return r(this.toDate(),{locale:this.$L,utc:!1})};var u=a.parse;a.parse=function(e){e.utc&&(this.$u=!0),this.$utils().u(e.$offset)||(this.$offset=e.$offset),u.call(this,e)};var x=a.init;a.init=function(){if(this.$u){var e=this.$d;this.$y=e.getUTCFullYear(),this.$M=e.getUTCMonth(),this.$D=e.getUTCDate(),this.$W=e.getUTCDay(),this.$H=e.getUTCHours(),this.$m=e.getUTCMinutes(),this.$s=e.getUTCSeconds(),this.$ms=e.getUTCMilliseconds()}else x.call(this)};var E=a.utcOffset;a.utcOffset=function(e,n){var h=this.$utils().u;if(h(e))return this.$u?0:h(this.$offset)?E.call(this):this.$offset;if(typeof e=="string"&&(e=(function(p){p===void 0&&(p="");var b=p.match(m);if(!b)return null;var k=(""+b[0]).match(z)||["-",0,0],O=k[0],w=60*+k[1]+ +k[2];return w===0?0:O==="+"?w:-w})(e),e===null))return this;var c=Math.abs(e)<=16?60*e:e;if(c===0)return this.utc(n);var l=this.clone();if(n)return l.$offset=c,l.$u=!1,l;var g=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(l=this.local().add(c+g,v)).$offset=c,l.$x.$localOffset=g,l};var o=a.format;a.format=function(e){var n=e||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return o.call(this,n)},a.valueOf=function(){var e=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*e},a.isUTC=function(){return!!this.$u},a.toISOString=function(){return this.toDate().toISOString()},a.toString=function(){return this.toDate().toUTCString()};var f=a.toDate;a.toDate=function(e){return e==="s"&&this.$offset?r(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():f.call(this)};var s=a.diff;a.diff=function(e,n,h){if(e&&this.$u===e.$u)return s.call(this,e,n,h);var c=this.local(),l=r(e).local();return s.call(c,l,n,h)}}}))})(y)),y.exports}var j=q();const ce=R(j);var I={exports:{}},X=I.exports,H;function Q(){return H||(H=1,(function($,S){(function(v,m){$.exports=m()})(X,(function(){var v={year:0,month:1,day:2,hour:3,minute:4,second:5},m={};return function(z,D,i){var r,a=function(o,f,s){s===void 0&&(s={});var e=new Date(o),n=(function(h,c){c===void 0&&(c={});var l=c.timeZoneName||"short",g=h+"|"+l,p=m[g];return p||(p=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:h,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:l}),m[g]=p),p})(f,s);return n.formatToParts(e)},u=function(o,f){for(var s=a(o,f),e=[],n=0;n<s.length;n+=1){var h=s[n],c=h.type,l=h.value,g=v[c];g>=0&&(e[g]=parseInt(l,10))}var p=e[3],b=p===24?0:p,k=e[0]+"-"+e[1]+"-"+e[2]+" "+b+":"+e[4]+":"+e[5]+":000",O=+o;return(i.utc(k).valueOf()-(O-=O%1e3))/6e4},x=D.prototype;x.tz=function(o,f){if(o===void 0&&(o=r),!this.isValid())return this;
1var s,e=this.utcOffset(),n=this.toDate(),h=n.toLocaleString("en-US",{timeZone:o}),c=u(+n,o);if(!Number(c))s=this.utcOffset(0,f);else if(s=i(h,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(c,!0),f){var l=s.utcOffset();s=s.add(e-l,"minute")}return s.$x.$timezone=o,s},x.offsetName=function(o){var f=this.$x.$timezone||i.tz.guess(),s=a(this.valueOf(),f,{timeZoneName:o}).find((function(e){return e.type.toLowerCase()==="timezonename"}));return s&&s.value};var E=x.startOf;x.startOf=function(o,f){if(!this.$x||!this.$x.$timezone)return E.call(this,o,f);var s=i(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return E.call(s,o,f).tz(this.$x.$timezone,!0)},i.tz=function(o,f,s){var e=s&&f,n=s||f||r,h=u(+i(),n);if(typeof o!="string")return i(o).tz(n);var c=i.utc(o,e).valueOf();if(Number.isNaN(c)){var l=i(NaN);return l.$x.$timezone=n,l}var g=(function(O,w,F){var _=O-60*w*1e3,C=u(_,F);if(w===C)return[_,w];var N=u(_-=60*(C-w)*1e3,F);return C===N?[_,C]:[O-60*Math.min(C,N)*1e3,Math.max(C,N)]})(c,h,n),p=g[0],b=g[1],k=i(p).utcOffset(b);return k.$x.$timezone=n,k},i.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},i.tz.setDefault=function(o){r=o}}}))})(I)),I.exports}var K=Q();const le=R(K);var A={exports:{}},J=A.exports,P;function ee(){return P||(P=1,(function($,S){(function(v,m){$.exports=m()})(J,(function(){return function(v,m){var z=m.prototype,D=z.format;z.format=function(i){var r=this,a=this.$locale();if(!this.isValid())return D.bind(this)(i);var u=this.$utils(),x=(i||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(E){switch(E){case"Q":return Math.ceil((r.$M+1)/3);case"Do":return a.ordinal(r.$D);case"gggg":return r.weekYear();case"GGGG":return r.isoWeekYear();case"wo":return a.ordinal(r.week(),"W");case"w":case"ww":return u.s(r.week(),E==="w"?1:2,"0");case"W":case"WW":return u.s(r.isoWeek(),E==="W"?1:2,"0");case"k":case"kk":return u.s(String(r.$H===0?24:r.$H),E==="k"?1:2,"0");case"X":return Math.floor(r.$d.getTime()/1e3);case"x":return r.$d.getTime();case"z":return"["+r.offsetName()+"]";case"zzz":return"["+r.offsetName("long")+"]";default:return E}}));return D.bind(this)(x)}}}))})(A)),A.exports}var te=ee();const ue=R(te);class U extends Error{details;constructor(S,v){super(S),this.name="InvalidSchemaError",this.details=v,Error.captureStackTrace&&Error.captureStackTrace(this,U)}}class Y extends Error{details;constructor(S,v){super(S),this.name="RequestError",this.details=v,Error.captureStackTrace&&Error.captureStackTrace(this,Y)}}class de{async fetchEvents(S,v,m,z="event-slider"){const D=new URL(`/api/calendars/${S}/events`,window.location.origin);D.searchParams.set("start_date",v),D.searchParams.set("end_date",m),D.searchParams.set("view_source",z);const i=await fetch(D.toString(),{method:"GET",headers:{Accept:"application/json"}});if(!i.ok)throw new Error(`HTTP error! status: ${i.status}`);const r=await i.json(),a=V.safeParse(r);if(!a.success)throw console.error("Invalid API response:",a.error,a),new U("Invalid API response",a.error);const u=a.data;if(!u.success||u.data.error)throw console.error("API returned error:",u.data.error),new Y(u.data.error);return{events:u.data.events,siteTimezone:u.data.site_timezone}}}export{re as C,oe as D,de as E,ie as V,ue as a,se as b,le as t,ce as u};
2//# sourceMappingURL=EventsRepository-BfSVWlH7.js.map

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.