PageSourceSearch

https://downtownmckinney.com/sites/mckinneymainstreet/img/s-e46fb47f3d3bdd0e.js?r=4

js downtownmckinney.com collected 2026-10-09 01:38:54 UTC 27,392 bytes, 201 lines download raw bytes

1window.__resources = window.__resources || {};
2window.__IMGV = {};
3window.__DC_LOGIC_FN = function (DCLogic, StreamableLogic, React) {
4
5class Component extends DCLogic {
6  state = { menuOpen: false, month: new Date().getMonth(), filter: "all", cal: "all", recurringOnly: false };
7
8  // The calendar grid shows the Events Calendar page's own records: the build
9  // (build.mjs loadOverride) writes them in place of the null below, each as
10  // { n name, h link, i photo, m venue, r recurrence, g group, d dates }.
11  // Opened in the design tool, where nothing is injected, the grid is empty.
12  calendar() {
13    const LIVE = [{"n":"Farmer's Market McKinney","h":"/sites/mckinneymainstreet/replica/design/downtown/v3/shopping/farmers-market","i":"/sites/mckinneymainstreet/vault/40f69e7986c225e7.jpg","m":"Chestnut Square Heritage Village","r":"Every Saturday","g":"markets","d":["2026-09-19","2026-09-26","2026-10-03","2026-10-10","2026-10-17","2026-10-24","2026-10-31","2026-11-07","2026-11-14","2026-11-21","2026-11-28","2026-12-05","2026-12-12","2026-12-19","2026-12-26","2027-01-02","2027-01-09","2027-01-16","2027-01-23","2027-01-30","2027-02-06","2027-02-13","2027-02-20","2027-02-27","2027-03-06","2027-03-13","2027-03-20","2027-03-27","2027-04-03","2027-04-10","2027-04-17","2027-04-24","2027-05-01","2027-05-08","2027-05-15","2027-05-22","2027-05-29","2027-06-05","2027-06-12","2027-06-19","2027-06-26","2027-07-03","2027-07-10","2027-07-17","2027-07-24","2027-07-31","2027-08-07","2027-08-14","2027-08-21","2027-08-28","2027-09-04","2027-09-11"],"s":"farmer's market mckinney chestnut square heritage village chestnut square heritage village shopping markets & shopping"},{"n":"1st Friday Late Night Paint Night","h":"https://www.wallsofclaymckinney.com/","i":"/sites/mckinneymainstreet/vault/ba661bf74fe4999e.jpg","m":"Walls of Clay","r":"1st Friday of the month","g":"classes","d":["2026-10-02","2026-11-06","2026-12-04","2027-01-01","2027-02-05","2027-03-05","2027-04-02","2027-05-07","2027-06-04","2027-07-02","2027-08-06","2027-09-03"],"s":"1st friday late night paint night walls of clay walls of clay class classes & workshops"},{"n":"The Garage Book Club: Sip, Read, Discuss","h":"https://thegaragemckinney.com/","i":"/sites/mckinneymainstreet/vault/6fae264932893e34.png","m":"The Garage (at Spoons)","r":"2nd Thursday of the month","g":"nights","d":["2026-10-08","2026-11-12","2026-12-10","2027-01-14","2027-02-11","2027-03-11","2027-04-08","2027-05-13","2027-06-10","2027-07-08","2027-08-12","2027-09-09"],"s":"the garage book club: sip, read, discuss the garage (at spoons) the garage (at spoons) listing music & nights out"},{"n":"Karaoke at Kentucky St: Grab the Mic!","h":"https://thegaragemckinney.com/","i":"/sites/mckinneymainstreet/vault/7baddbbf599b22aa.png","m":"The Garage (at Spoons)","r":"Every Friday","g":"nights","d":["2026-09-18","2026-09-25","2026-10-02","2026-10-09","2026-10-16","2026-10-23","2026-10-30","2026-11-06","2026-11-13","2026-11-20","2026-11-27","2026-12-04","2026-12-11","2026-12-18","2026-12-25","2027-01-01","2027-01-08","2027-01-15","2027-01-22","2027-01-29","2027-02-05","2027-02-12","2027-02-19","2027-02-26","2027-03-05","2027-03-12","2027-03-19","2027-03-26","2027-04-02","2027-04-09","2027-04-16","2027-04-23","2027-04-30","2027-05-07","2027-05-14","2027-05-21","2027-05-28","2027-06-04","2027-06-11","2027-06-18","2027-06-25","2027-07-02","2027-07-09","2027-07-16","2027-07-23","2027-07-30","2027-08-06","2027-08-13","2027-08-20","2027-08-27","2027-09-03","2027-09-10"],"s":"karaoke at kentucky st: grab the mic! the garage (at spoons) the garage (at spoons) live music music & nights out"},{"n":"Psychic Night McKinney","h":"https://www.psychicnight.net/","i":"/sites/mckinneymainstreet/vault/b0d186255a92ba9d.png","m":"Uptown Style Home Furnishings","r":"3rd Thursday of the month","g":"nights","d":["2026-09-17","2026-10-15","2026-11-19","2026-12-17","2027-01-21","2027-02-18","2027-03-18","2027-04-15","2027-05-20","2027-06-17","2027-07-15","2027-08-19","2027-09-16"],"s":"psychic night mckinney uptown style home furnishings uptown style home furnishings festivals music & nights out"},{"n":"Glow Metalworks: Metal Casting Art Workshop","h":"https://www.arthousetx.com/metalworks","i":"/sites/mckinneymainstreet/vault/4d671220343f2d35.png","m":"McKinney Art House","r":"Every Friday & Saturday","g":"classes","d":["2026-09-18","2026-09-19","2026-09-25","2026-09-26","2026-10-02","2026-10-03","2026-10-09","2026-10-10","202
136-10-16","2026-10-17","2026-10-23","2026-10-24","2026-10-30","2026-10-31","2026-11-06","2026-11-07","2026-11-13","2026-11-14","2026-11-20","2026-11-21","2026-11-27","2026-11-28","2026-12-04","2026-12-05","2026-12-11","2026-12-12","2026-12-18","2026-12-19","2026-12-25","2026-12-26","2027-01-01","2027-01-02","2027-01-08","2027-01-09","2027-01-15","2027-01-16","2027-01-22","2027-01-23","2027-01-29","2027-01-30","2027-02-05","2027-02-06","2027-02-12","2027-02-13","2027-02-19","2027-02-20","2027-02-26","2027-02-27","2027-03-05","2027-03-06","2027-03-12","2027-03-13","2027-03-19","2027-03-20","2027-03-26","2027-03-27","2027-04-02","2027-04-03","2027-04-09","2027-04-10"],"s":"glow metalworks: metal casting art workshop mckinney art house mckinney art house workshop classes & workshops"},{"n":"Guided Historic Walking Tour","h":"https://www.visitmckinney.com/things-to-do/tours/historic-district-tours/","i":"/sites/mckinneymainstreet/vault/f7f4fb067190d9db.jpg","m":"Visit McKinney","r":"","g":"tours","d":["2026-10-13","2026-11-10","2026-12-08"],"s":"guided historic walking tour visit mckinney visitors center, 200 w. virginia tour america 250 tours & history"},{"n":"Come Clay with Me: One-Time Pottery Wheel Class","h":"https://arthousetx.com/pottery-classes/potteryexperience","i":"/sites/mckinneymainstreet/vault/23e5e5eac23f3fdb.jpg","m":"McKinney Art House","r":"Every Friday, Saturday & Sunday","g":"classes","d":["2026-09-18","2026-09-19","2026-09-20","2026-09-25","2026-09-26","2026-09-27","2026-10-02","2026-10-03","2026-10-04","2026-10-09","2026-10-10","2026-10-11","2026-10-16","2026-10-17","2026-10-18","2026-10-23","2026-10-24","2026-10-25","2026-10-30","2026-10-31","2026-11-01","202
136-11-06","2026-11-07","2026-11-08","2026-11-13","2026-11-14","2026-11-15","2026-11-20","2026-11-21","2026-11-22","2026-11-27","2026-11-28","2026-11-29","2026-12-04","2026-12-05","2026-12-06","2026-12-11","2026-12-12","2026-12-13","2026-12-18","2026-12-19","2026-12-20","2026-12-25","2026-12-26","2026-12-27","2027-01-01","2027-01-02","2027-01-03","2027-01-08","2027-01-09","2027-01-10","2027-01-15","2027-01-16","2027-01-17","2027-01-22","2027-01-23","2027-01-24","2027-01-29","2027-01-30","2027-01-31"],"s":"come clay with me: one-time pottery wheel class mckinney art house mckinney art house class classes & workshops"},{"n":"Living History Day","h":"https://www.chestnutsquare.org/events-tours/living-history","i":"/sites/mckinneymainstreet/vault/8577fc029c58c6c5.jpg","m":"Chestnut Square Heritage Village","r":"1st Saturday of the month","g":"tours","d":["2026-10-03","2026-11-07"],"s":"living history day  chestnut square heritage village history tours & history"},{"n":"TUPPS Brewery Hops and Shops","h":"https://www.eventbrite.com","i":"/sites/mckinneymainstreet/vault/be32c9c22a845041.jpg","m":"TUPPS Brewery","r":"","g":"nights","d":["2026-09-25"],"s":"tupps brewery hops and shops tupps brewery tupps brewery social event music & nights out"},{"n":"Guided Public Art Tour","h":"https://www.visitmckinney.com/things-to-do/tours/public-art-tours/","i":"/sites/mckinneymainstreet/vault/1e5d91163d5b8f47.png","m":"Visit McKinney","r":"","g":"tours","d":["2026-09-23","2026-09-26"],"s":"guided public art tour visit mckinney visit mckinney tour tours & history"},{"n":"Red Zeppelin Records & WMG Vinyl Take-Back","h":"https://www.wmg.com/news/independent-record-stores-and-warner-music-group-launch-nationwide-pilot-to-explore-recovery-pathways-for-vinyl-records","i":"/sites/mckinneymainstreet/vault/3cb1cfcf9774bf25.png","m":"Red Zeppelin Records","r":"Daily through September","g":"markets","d":["2026-09-16","2026-09-17","2026-09-18","2026-09-19","2026-09-20","2026-09-21","2026-09-22","2026-09-23","2026-09-24","2026-09-25","2026-09-26","2026-09-27","2026-09-28","2026-09-29","2026-09-30"],"s":"red zeppelin records & wmg vinyl take-back red zeppelin records red zeppelin records shopping markets & shopping"},{"n":"McKinney Oktoberfest","h":"/sites/mckinneymainstreet/replica/design/downtown/v3/events/oktoberfest","i":"/sites/mckinneymainstreet/vault/8e62f4ba88d030ef.jpg","m":"Downtown McKinney","r":"","g":"festivals","d":["2026-09-25","2026-09-26","2026-09-27"],"s":"mckinney oktoberfest downtown mckinney historic downtown mckinney festivals festivals"},{"n":"Día de los Muertos","h":"https://www.mckinneydiadelosmuertos.com/","i":"/sites/mckinneymainstreet/vault/632f8f5d8aabe440.jpg","m":"TUPPS Brewery","r":"","g":"festivals","d":["2026-10-17"],"s":"día de los muertos tupps brewery tupps brewery festivals festivals"},{"n":"Ratrodtober Fest","h":"https://www.ratrodtober.com/","i":"/sites/mckinneymainstreet/vault/20f85f5900901ea5.png","m":"TUPPS Brewery","r":"","g":"festivals","d":["2026-10-10"],"s":"ratrodtober fest tupps brewery tupps brewery festivals social event festivals"},{"n":"Oktoberfest Stoneware Workshop: Steins, Mugs & Glasses","h":"https://bit.ly/4zf9c8r","i":"/sites/mckinneymainstreet/vault/9524fb1059dd55c4.png","m":"Walls of Clay","r":"","g":"classes","d":["2026-09-26"],"s":"oktoberfest stoneware workshop: steins, mugs & glasses walls of clay walls of clay workshop classes & workshops"},{"n":"North Texas Giving Day: Cheers to Careers","h":"https://forms.cloud.microsoft/pages/responsepage.aspx?id=hOvgYiU9mUS1TD1k3qK83CzXhbm6cZdFpz5p4kLGGgxUNFY2RkQxWFpBTkhCU001VkFKVkFZWTlLUy4u&route=shorturl","i":"/sites/mckinneymainstreet/vault/6ea3d9b0a639e157.jpg","m":"Hugs Cafe","r":"","g":"food","d":["2026-09-17"],"s":"north texas giving day: cheers to careers hugs cafe hugs cafe culinary food & drink"},{"n":"Oktoberfest Pottery + Cookie Decorating Collab","h":"https://wallsofclaymckinney.com/event/09-24-2026-oktoberfest-pottery-cookie-collab-reservations-required/","i":"/sites/mckinneymainstreet/vault/ec7c58df848167f0.png","m":"Walls of Clay","r":"","g":"classes","d":["2026-09-24"],"s":"oktoberfest pottery + cookie decorating collab walls of clay walls of clay culinary social event workshop class classes & workshops"},{"n":"The Foraged Feast","h":"https://thechestnuthall.com/events/","i":"/sites/mckinneymainstreet/vault/60a82c77dec3ea11.jpg","m":"The Chestnut Hall","r":"","g":"food","d":["2026-09-17"],"s":"the foraged feast the chestnut hall the chestnut hall culinary food & drink"}];
14    const KIND = { festivals: "Festival", tours: "Tours & history", classes: "Classes & workshops", nights: "Music & nights out", food: "Food & drink", markets: "Markets & shopping" };
15    const MS = ["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];
16    const now = new Date();
17    const today = now.getFullYear() + "-" + String(now.getMonth() + 1).padStart(2, "0") + "-" + String(now.getDate()).padStart(2, "0");
18    // The next date from today on labels the card and sorts it; an event with no date left drops out.
19    return (LIVE || []).map(c => {
20      const left = c.d.filter(d => d >= today);
21      if (!left.length) return null;
22      const more = c.r || (left.length > 1 ? "+" + (left.length - 1) + (left.length === 2 ? " more date" : " more dates") : "");
23      return { name: c.n, venue: c.m, href: c.h, img: c.i, group: c.g, kind: KIND[c.g], repeat: more, recurring: !!c.r, next: left[0], day: left[0].slice(8, 10), mon: MS[Number(left[0].slice(5, 7)) - 1] };
24    }
24).filter(Boolean).sort((a, b) => (a.next < b.next ? -1 : a.next > b.next ? 1 : 0));
25  }
26
27  componentDidMount() {
28    this._v3search = (e) => {
29      const t = e.target && e.target.closest ? e.target : null;
30      if (!t) return;
31      const form = e.type === "submit" ? t : t.closest("[data-site-search]");
32      if (!form || !form.hasAttribute || !form.hasAttribute("data-site-search")) return;
33      if (e.type === "click" && !t.closest("[data-search-go]")) return;
34      const go = form.querySelector("[data-search-go]");
35      const input = form.querySelector("input");
36      if (!go) return;
37      // Before the runtime's own link handling sees the click: on window, in
38      // the capture phase, and stopped there. (The designed pages' runtime
39      // treats a click on a .dc.html link as a screen change and would drop
40      // the query.)
41      e.preventDefault();
42      e.stopPropagation();
43      const base = (go.getAttribute("href") || "").split("?")[0];
44      const q = ((input && input.value) || "").trim();
45      window.location.assign(base + (q ? "?q=" + encodeURIComponent(q) : ""));
46    };
47    window.addEventListener("submit", this._v3search, true);
48    window.addEventListener("click", this._v3search, true);
49    this._v3bar = (e) => {
50      const bar = document.querySelector("header[data-v3-bar]");
51      if (!bar) return;
52      const t = e && e.target && e.target !== document ? e.target : null;
53      const y = window.scrollY || document.documentElement.scrollTop || (t && t.scrollTop) || 0;
54      if (y > 40) bar.setAttribute("data-solid", ""); else bar.removeAttribute("data-solid");
55    };
56    window.addEventListener("scroll", this._v3bar, { passive: true });
57    document.addEventListener("scroll", this._v3bar, { passive: true, capture: true });
58    this._v3bar();
59    // The .dc runtime renders video elements without their muted and loop attributes,
60    // and a browser only autoplays a muted video, so the hero film sat on its
61    // poster. Restore both as properties and start it.
62    document.querySelectorAll("video[autoplay]").forEach((v) => {
63      v.muted = true;
64      v.defaultMuted = true;
65      if (v.hasAttribute("data-loop")) v.loop = true;
66      const go = v.play();
67      if (go && go.catch) go.catch(() => {});
68    });
69    // If the loop property is ever lost (a re-render), start the film again.
70    this._v3ended = (e) => {
71      const v = e.target;
72      if (v && v.tagName === "VIDEO" && v.hasAttribute("data-loop")) { v.currentTime = 0; const go = v.play(); if (go && go.catch) go.catch(() => {}); }
73    };
74    document.addEventListener("ended", this._v3ended, true);
75    // The hero film's pause button (9/16).
76    this._v3pause = (e) => {
77      const btn = e.target && e.target.closest ? e.target.closest("[data-hero-pause]") : null;
78      if (!btn) return;
79      const v = (btn.closest("section") || document).querySelector("video");
80      if (!v) return;
81      e.preventDefault();
82      if (!v.paused) v.pause(); else { const go = v.play(); if (go && go.catch) go.catch(() => {}); }
83    };
84    document.addEventListener("click", this._v3pause);
85    // The button shows what the film is doing, including an autoplay the
86    // browser refused.
87    this._v3playState = (e) => {
88      const v = e.target;
89      if (!v || v.tagName !== "VIDEO") return;
90      const btn = (v.closest("section") || document).querySelector("[data-hero-pause]");
91      if (!btn) return;
92      const paused = v.paused;
93      btn.setAttribute("aria-label", paused ? "Play the video" : "Pause the video");
94      btn.setAttribute("aria-pressed", paused ? "true" : "false");
95      const ip = btn.querySelector("[data-icon-pause]"), pl = btn.querySelector("[data-icon-play]");
96      if (ip) ip.style.display = paused ? "none" : "flex";
97      if (pl) pl.style.display = paused ? "block" : "none";
98    };
99    document.addEventListener("play", this._v3playState, true);
100    document.addEventListener("pause", this._v3playState, true);
101    document.querySelectorAll("video[data-loop]").forEach((v) => this._v3playState({ target: v }));
102    this._v3fitNow = () => {
103      document.querySelectorAll("[data-fit]").forEach((el) => {
104        el.style.setProperty("--fit", "1");
105        const box = el.getBoundingClientRect();
106        if (!box.width) return;
107        const cs = getComputedStyle(el);
108        const pb = el.parentElement ? el.parentElement.getBoundingClientRect() : box;
109        const inner = Math.min(box.right - parseFloat(cs.paddingRight || 0
109), pb.right);
110        let k = 1;
111        for (let i = 0; i < 4; i += 1) {
112          const r = document.createRange();
113          r.selectNodeContents(el);
114          let right = box.left;
115          for (const q of r.getClientRects()) right = Math.max(right, q.right);
116          const need = right - box.left;
117          const avail = inner - box.left;
118          if (need <= avail + 1 || avail <= 0) break;
119          k = Math.max(0.42, k * (avail / need) * 0.985);
120          el.style.setProperty("--fit", String(k));
121        }
122      });
123    };
124    this._v3fit = () => { cancelAnimationFrame(this._v3raf); this._v3raf = requestAnimationFrame(this._v3fitNow); };
125    window.addEventListener("resize", this._v3fit);
126    if (document.fonts && document.fonts.ready) document.fonts.ready.then(this._v3fit);
127    this._v3fit();
128    this._onKey = (e) => { if (e.key === "Escape" && this.state.menuOpen) this.setState({ menuOpen: false }); };
129    window.addEventListener("keydown", this._onKey);
130  }
131  componentWillUnmount() { window.removeEventListener("keydown", this._onKey); document.documentElement.style.overflow = ""; }
132  componentDidUpdate() { if (this._v3fit) this._v3fit(); document.documentElement.style.overflow = this.state.menuOpen ? "hidden" : ""; }
133
134  signature() {
135    const I = "https://assets.simpleviewinc.com/simpleview/image/upload/";
136    return [
137      { name: "Krewe of Barkus", when: "Traditionally the Sunday before Mardi Gras", months: [1], season: "Winter", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/krewe-of-barkus", cta: "Plan your visit →", img: "/sites/mckinneymainstreet/img/v-c0b53f8e0b47f5ee-1280.webp", alt: "Three small dogs in a wagon with Mardi Gras decor" },
138      { name: "Arts in Bloom", when: "Traditionally the second weekend in April", months: [3], season: "Spring", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/arts-in-bloom", cta: "Plan your visit →", img: "/sites/mckinneymainstreet/img/v-6e51fa0574bc6594-1280.webp", alt: "Arts in Bloom couple with flowers" },
139      { name: "McKinney Historic Half", when: "Saturday, April 3, 2027 · City Hall to TUPPS Brewery", months: [3], season: "Spring", href: "https://mckinneyhalf.com/", cta: "Race website ↗", img: "/sites/mckinneymainstreet/img/v-60330432903e7ab6-1280.webp", alt: "Runners on the McKinney Historic Half course" },
140      { name: "Texas Music Revolution", when: "Traditionally the first full weekend of June", months: [5], season: "Summer", href: "https://tmrfest.com/", cta: "Event website ↗", img: "/sites/mckinneymainstreet/img/v-8d3bf0ec087b994d-1280.webp", alt: "Cowboys playing guitar by moonlight, Texas Music Revolution poster" },
141      { name: "4th of July Hometown Parade", when: "Traditionally July 4th", months: [6], season: "Summer", href: "https://www.mckinneytexas.org/830/Red-White-and-BOOM", cta: "Event website ↗", img: "/sites/mckinneymainstreet/img/v-1c7ee0bd3fa4a9d9-1280.webp", alt: "McKinney Red, White & Boom Parade on July 4" },
142      { name: "McKinney Oktoberfest", when: "Traditionally the last full weekend of September", months: [8], season: "Fall", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/oktoberfest", cta: "Plan your visit →", img: "/sites/mckinneymainstreet/img/v-11ebfda375453d58-1280.webp", alt: "Oktoberfest dancers" },
143      { name: "Home for the Holidays", when: "Traditionally held Thanksgiving weekend", months: [10], season: "Winter", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/home-for-the-holidays", cta: "Plan your visit →", img: "/sites/mckinneymainstreet/img/v-a57b6c250a706f9d-1280.webp", alt: "Downtown McKinney aerial view during Home for the Holidays" }
144    ];
145  }
146
147  community() {
148    // months are 0-indexed; drawn from the dates published on the current site
149    const O = "/sites/mckinneymainstreet/replica/design/downtown/v3/events/other-events";
150    return [
151      { name: "Coffee Crawl", kind: "Food & drink", group: "eat", month: 0, when: "Typically late January", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/other
151-events", cta: "Details →", color: "#CDB265", text: "Grab your punch card and sip your way through Downtown McKinney's top coffee stops. Each location offers a sample-sized drink and fun atmosphere to enjoy with friends." },
152      { name: "Girls Night Out", kind: "Shop & sip", group: "shop", month: 1, when: "Typically mid-February", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/other-events", cta: "Details →", color: "#B03470", text: "Shop late, sip drinks, and enjoy exclusive deals during this downtown favorite. Participating businesses offer festive vibes, pop-ups, and surprises for your crew." },
153      { name: "SoTenn Night Market", kind: "Market", group: "market", month: 2, when: "Typically late March", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/other-events", cta: "Details →", color: "#4280BE", text: "This evening street market on South Tennessee features artisan vendors, food trucks, live music, and glowing lights under the stars. Free and open to the public." },
154      { name: "Easter Bunny Pop-Up", kind: "Family", group: "family", month: 2, when: "Typically late March", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/other-events", cta: "Details →", color: "#CDB265", text: "Bring the kids to meet the Easter Bunny in the heart of downtown. Enjoy photo ops, bunny treats, and egg-themed surprises from local merchants." },
155      { name: "Downtown Bridal Walk", kind: "Shop", group: "shop", month: 3, when: "Typically early April", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/other-events", cta: "Details →", color: "#52B9BC", text: "Brides and bridal parties are invited to explore wedding venues, stylists, florists, and more during this self-guided walk through Downtown McKinney's charming spaces." },
156      { name: "Downtown McKinney Classic Car Show", kind: "Cars", group: "market", month: 7, when: "August", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/other-events/car-show", cta: "Event page →", color: "#DD4C38", text: "Come see 150 classic cars at the Downtown McKinney Classic Car Show." },
157      { name: "Downtown Scavenger Hunt", kind: "Family", group: "family", month: 7, when: "Saturday, August 29, 2026", href: "/sites/mckinneymainstreet/replica/design/downtown/v3/events/other-events/scavengerhunt", cta: "Event page →", color: "#A4B9A6", img: "/sites/mckinneymainstreet/img/v-afeda8fb7339f934-1280.webp", alt: "Downtown McKinney Scavenger Hunt banner, hand-lettered on a gold sign", text: "Downtown is your canvas this year! From hidden brushstrokes to glowing murals, keep your eyes open for details most people walk right past. We've hidden the fun in plain sight. Will you see it?" }
158    ];
159  }
160
161  renderVals() {
162    const S = this.state, sig = this.signature(), com = this.community();
163    const MN = ["January","February","March","April","May","June","July","August","September","October","November","December"];
164    const MS = ["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];
165    const now = new Date(), thisMonth = now.getMonth();
166    const chip = (on, dark) => "font-family: Figtree; cursor: pointer; font-size: 14px; font-weight: " + (on ? 700 : 600) + "; padding: 9px 14px; border-radius: 999px; " + (on ? "background: #17415E; color: #fff; border: 1.5px solid #17415E;" : "background: #fff; color: #17415E; border: 1.5px solid rgba(23,65,94,0.25);");
167    const seasonColor = { Winter: "#4280BE", Spring: "#CDB265", Summer: "#DD4C38", Fall: "#CDB265" };
168    const signature = sig.map(e => Object.assign({}, e, { seasonStyle: "position: absolute; left: 16px; top: 16px; font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; padding: 6px 10px; border-radius: 999px; background: " + seasonColor[e.season] + "; color: " + (e.season === "Spring" || e.season === "Fall" ? "#17415E" : "#fff") + ";" }));
169
170    const filters = [["all","Everything"],["eat","Food & drink"],["shop","Shop & sip"],["family","Family"],["market","Markets & shows"]];
171    const grid = com.filter(e => S.filter === "all" || e.group === S.filter).map(e => Object.assign({}, e, {
172      monthShort: e.month === null ? "Any" : MS[e.month], whenLine: e.when, hasImg: !!e.img,
173      bannerStyle: "position: relative; overflow: hidden; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; padding: 16px 18px; min-height: " + (e.img ? "190px" : "130px") + "; background: " + e.color + "; color: " + (!e.img && ["#CDB265","#CDB265","#52B9BC","#A4B9A6"].includes(e.color) ? "#17415E" : "#fff") + ";"
174    }));
175    const hfth = new Date(2026, 10, 27), diff = Math.ceil((hfth - now) / 86400000);
176    const darkChip = (on) => "font-family: Figtree; cursor: pointer; font-size: 14px; font-weight: " + (on ? 700 : 600) + "; padding: 9px 14px; border-radius: 999px; min-height: 40px; " + (on ? "background: #CDB265; color: #17415E; border: 1.5px solid #CDB265;" : "background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,0.3);");
177    const calGroups = [["all","Everything"],["festivals","Festivals"],["tours","Tours & history"],["classes","Classes & workshops"],["nights","Music & nights out"],["food","Food & drink"],["markets","Markets & shopping"]].filter(g => g[0] === "all" || this.calendar().some(e => e.group === g[0]));
178    const calAll = this.calendar();
179    const calEvents = calAll.filter(e => (S.cal === "all" || e.group === S.cal) && (!S.recurringOnly || e.recurring)).map(e => Object.assign({}, e, {
180      hasRepeat: !!e.repeat,
181      mediaStyle: "position: relative; display: block; overflow: hidden; aspect-ratio: 4 / 3; background: #17415E;"
182    }));
183    return {
184      calFilters: calGroups.map(([k, l]) => ({ label: l, style: darkChip(S.cal === k), pick: () => this.setState({ cal: k }) })),
185      toggleRecurring: () => this.setState({ recurringOnly: !S.recurringOnly }),
186      recurringStyle: darkChip(S.recurringOnly).replace("border-radius: 999px", "border-radius: 999px; border-style: dashed"),
187      recurringLabel: S.recurringOnly ? "✓ Recurring only" : "Recurring only",
188      calEvents, calEmpty: calEvents.length === 0,
189      calCount: calEvents.length + " of " + calAll.length + " upcoming",
190      calTitle: S.cal === "all" ? "Classes, tours, karaoke and more" : calGroups.find(g => g[0] === S.cal)[1],
191      menuOpen: S.menuOpen, openMenu: () => this.setState({ menuOpen: true }), closeMenu: () => this.setState({ menuOpen: false }),
192      nextCountdown: diff > 1 ? "in " + diff + " days" : diff === 1 ? "tomorrow" : diff > -3 ? "happening now" : "see you next year",
193      signature,
194      filters: filters.map(([k, l]) => ({ label: l, style: chip(S.filter === k), pick: () => this.setState({ filter: k }) })),
195      grid, gridTitle: S.filter === "all" ? "Curated to enhance your visit to the square" : grid.length + (grid.length === 1 ? " event" : " events") + " · " + filters.find(f => f[0] === S.filter)[1].toLowerCase()
196    };
197  }
198}
199
200;return (typeof Component !== "undefined" && Component) || undefined;
201};

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.