1import { s as delegateEvents, l as createEffect, a1 as onCleanup, R as getNextElement, T as getNextMarker, W as insert, i as createComponent, a6 as setAttribute, n as createRenderEffect, ad as style, a4 as runHydrationEvents, S as Show, Z as memo, M as Match, c as Switch, ae as template, m as createMemo } from "./tr-UliDDw9Z.js"; 2import { a as logoLight, l as logoDark } from "./logo-ornate-dark-CCGQN_4x.js"; 3import { u as useI18n, b as useLanguage, c as createStore } from "./i18n-Igr6ftC6.js"; 4import { c as config, g as github } from "./config-Cd2rvrWG.js"; 5import { o as useNavigate } from "./query-C5C68Kfb.js"; 6import { A } from "./components-CNaz94iW.js"; 7import { c as createAsync } from "./createAsync-KTPCmejz.js"; 8const copyLogoLight = "data:image/svg+xml,%3csvg%20width='22'%20height='26'%20viewBox='0%200%2022%2026'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_1311_94907)'%3e%3cpath%20d='M15%2019H7V11H15V19Z'%20fill='%23BCBBBB'/%3e%3cpath%20d='M15%207H7V19H15V7ZM19%2023H3V3H19V23Z'%20fill='%23211E1E'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_1311_94907'%3e%3crect%20width='16'%20height='20'%20fill='white'%20transform='translate(3%203)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"; 9const copyLogoDark = "data:image/svg+xml,%3csvg%20width='22'%20height='26'%20viewBox='0%200%2022%2026'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_1311_94916)'%3e%3cpath%20d='M15%2019H7V11H15V19Z'%20fill='%234B4646'/%3e%3cpath%20d='M15%207H7V19H15V7ZM19%2023H3V3H19V23Z'%20fill='%23F1ECEC'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_1311_94916'%3e%3crect%20width='16'%20height='20'%20fill='white'%20transform='translate(3%203)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"; 10const copyWordmarkLight = "data:image/svg+xml,%3csvg%20width='22'%20height='26'%20viewBox='0%200%2022%2026'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M4.33203%207.99967V6.33301H10.9987M17.6654%207.99967V6.33301H10.9987M10.9987%206.33301V19.6663M10.9987%2019.6663H9.33203M10.9987%2019.6663H12.6654'%20stroke='black'%20stroke-width='2'%20stroke-linecap='square'/%3e%3c/svg%3e"; 11const copyWordmarkDark = "data:image/svg+xml,%3csvg%20width='22'%20height='26'%20viewBox='0%200%2022%2026'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M4.33203%207.99967V6.33301H10.9987M17.6654%207.99967V6.33301H10.9987M10.9987%206.33301V19.6663M10.9987%2019.6663H9.33203M10.9987%2019.6663H12.6654'%20stroke='%23F1ECEC'%20stroke-width='2'%20stroke-linecap='square'/%3e%3c/svg%3e"; 12const copyBrandAssetsLight = "data:image/svg+xml,%3csvg%20width='22'%20height='26'%20viewBox='0%200%2022%2026'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M15%207H7V19H15V7ZM19%2023H3V3H19V23Z'%20fill='url(%23paint0_linear_1311_94913)'%20stroke='%238E8B8B'/%3e%3cpath%20d='M3%200V26M19%200V26M15%200V26M7%200V26M0%203H22M0%207H22M0%2019H22M0%2023H22'%20stroke='%23110000'%20stroke-opacity='0.121569'/%3e%3cdefs%3e%3clinearGradient%20id='paint0_linear_1311_94913'%20x1='11'%20y1='3'%20x2='11'%20y2='23'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23F9F8F8'/%3e%3cstop%20offset='1'%20stop-color='%23E9E8E8'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e"; 13const copyBrandAssetsDark = "data:image/svg+xml,%3csvg%20width='22'%20height='26'%20viewBox='0%200%2022%2026'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M15%207H7V19H15V7ZM19%2023H3V3H19V23Z'%20fill='url(%23paint0_linear_1311_94922)'%20stroke='%23F1ECEC'/%3e%3cpath%20d='M3%200V26M19%200V26M15%200V26M7%200V26M0%203H22M0%207H22M0%2019H22M0%2023H22'%20stroke='%234B4646'%20stroke-opacity='0.4'/%3e%3cdefs%3e%3clinearGradient%20id='paint0_linear_1311_94922'%20x1='11'%20y1='3'%20x2='11'%20y2='23'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%231B1818'/%3e%3cstop%20offset='1'%20stop-color='%232D2828'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e"; 14const copyLogoSvgLight = "data:image/svg+xml,%3csvg%20width='32'%20height='40'%20viewBox='0%200%2032%2040'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_1311_94969)'%3e%3cpath%20d='M24%2032H8V16H24V32Z'%20fill='%23BCBBBB'/%3e%3cpath%20d='M24%208H8V32H24V8ZM32%2040H0V0H32V40Z'%20fill='%23211E1E'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_1311_94969'%3e%3crect%20width='32'%20height='40'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"; 15const copyLogoSvgDark = "data:image/svg+xml,%3csvg%20width='32'%20height='40'%20viewBox='0%200%2032%2040'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_1311_94973)'%3e%3cpath%20d='M24%2032H8V16H24V32Z'%20fill='%234B4646'/%3e%3cpath%20d='M24%208H8V32H24V8ZM32%2040H0V0H32V40Z'%20fill='%23F1ECEC'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_1311_94973'%3e%3crect%20width='32'%20height='40'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"; 16const copyWordmarkSvgLight = "data:image/svg+xml,%3csvg%20width='234'%20height='42'%20viewBox='0%200%20234%2042'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_1311_95049)'%3e%3cpath%20d='M18%2030H6V18H18V30Z'%20fill='%23CFCECD'/%3e%3cpath%20d='M18%2012H6V30H18V12ZM24%2036H0V6H24V36Z'%20fill='%23656363'/%3e%3cpath%20d='M48%2030H36V18H48V30Z'%20fill='%23CFCECD'/%3e%3cpath%20d='M36%2030H48V12H36V30ZM54%2036H36V42H30V6H54V36Z'%20fill='%23656363'/%3e%3cpath%20d='M84%2024V30H66V24H84Z'%20fill='%23CFCECD'/%3e%3cpath%20d='M84%2024H66V30H84V36H60V6H84V24ZM66%2018H78V12H66V18Z'%20fill='%23656363'/%3e%3cpath%20d='M108%2036H96V18H108V36Z'%20fill='%23CFCECD'/%3e%3cpath%20d='M108%2012H96V36H90V6H108V12ZM114%2036H108V12H114V36Z'%20fill='%23656363'/%3e%3cpath%20d='M144%2030H126V18H144V30Z'%20fill='%23CFCECD'/%3e%3cpath%20d='M144%2012H126V30H144V36H120V6H144V12Z'%20fill='%23211E1E'/%3e%3cpath%20d='M168%2030H156V18H168V30Z'%20fill='%23CFCECD'/%3e%3cpath%20d='M168%2012H156V30H168V12ZM174%2036H150V6H174V36Z'%20fill='%23211E1E'/%3e%3cpath%20d='M198%2030H186V18H198V30Z'%20fill='%23CFCECD'/%3e%3cpath%20d='M198%2012H186V30H198V12ZM204%2036H180V6H198V0H204V36Z'%20fill='%23211E1E'/%3e%3cpath%20d='M234%2024V30H216V24H234Z'%20fill='%23CFCECD'/%3e%3cpath%20d='M216%2012V18H228V12H216ZM234%2024H216V30H234V36H210V6H234V24Z'%20fill='%23211E1E'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_1311_95049'%3e%3crect%20width='234'%20height='42'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"; 17const copyWordmarkSvgDark = "data:image/svg+xml,%3csvg%20width='234'%20height='42'%20viewBox='0%200%20234%2042'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20clip-path='url(%23clip0_1311_95032)'%3e%3cpath%20d='M18%2030H6V18H18V30Z'%20fill='%234B4646'/%3e%3cpath%20d='M18%2012H6V30H18V12ZM24%2036H0V6H24V36Z'%20fill='%23B7B1B1'/%3e%3cpath%20d='M48%2030H36V18H48V30Z'%20fill='%234B4646'/%3e%3cpath%20d='M36%2030H48V12H36V30ZM54%2036H36V42H30V6H54V36Z'%20fill='%23B7B1B1'/%3e%3cpath%20d='M84%2024V30H66V24H84Z'%20fill='%234B4646'/%3e%3cpath%20d='M84%2024H66V30H84V36H60V6H84V24ZM66%2018H78V12H66V18Z'%20fill='%23B7B1B1'/%3e%3cpath%20d='M108%2036H96V18H108V36Z'%20fill='%234B4646'/%3e%3cpath%20d='M108%2012H96V36H90V6H108V12ZM114%2036H108V12H114V36Z'%20fill='%23B7B1B1'/%3e%3cpath%20d='M144%2030H126V18H144V30Z'%20fill='%234B4646'/%3e%3cpath%20d='M144%2012H126V30H144V36H120V6H144V12Z'%20fill='%23F1ECEC'/%3e%3cpath%20d='M168%2030H156V18H168V30Z'%20fill='%234B4646'/%3e%3cpath%20d='M168%2012H156V30H168V12ZM174%2036H150V6H174V36Z'%20fill='%23F1ECEC'/%3e%3cpath%20d='M198%2030H186V18H198V30Z'%20fill='%234B4646'/%3e%3cpath%20d='M198%2012H186V30H198V12ZM204%2036H180V6H198V0H204V36Z'%20fill='%23F1ECEC'/%3e%3cpath%20d='M234%2024V30H216V24H234Z'%20fill='%234B4646'/%3e%3cpath%20d='M216%2012V18H228V12H216ZM234%2024H216V30H234V36H210V6H234V24Z'%20fill='%23F1ECEC'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_1311_95032'%3e%3crect%20width='234'%20height='42'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"; 18var _tmpl$$1 = /* @__PURE__ */ template(`<img data-slot="logo light"width=189 height=34>`), _tmpl$2 = /* @__PURE__ */ template(`<img data-slot="logo dark"width=189 height=34>`), _tmpl$3 = /* @__PURE__ */ template(`<div class=context-menu><button class=context-menu-item><img data-slot="copy light"alt><img data-slot="copy dark"alt><!$><!/></button><button class=context-menu-item><img data-slot="copy light"alt><img data-slot="copy dark"alt><!$><!/></button><button class=context-menu-item><img data-slot="copy light"alt><img data-slot="copy dark"alt><!$><!/>`), _tmpl$4 = /* @__PURE__ */ template(`<li><a href=/auth>`), _tmpl$5 = /* @__PURE__ */ template(`<svg width=18 height=18 viewBox="0 0 18 18"fill=none xmlns=http://www.w3.org/2000/svg style=flex-shrink:0><path d="M12.1875 9.75L9.00001 12.9375L5.8125 9.75M9.00001 2.0625L9 12.375M14.4375 15.9375H3.5625"stroke=currentColor stroke-width=1.5 stroke-linecap=square>`), _tmpl$6 = /* @__PURE__ */ template(`<li>`), _tmpl$7 = /* @__PURE__ */ template(`<svg class="icon icon-close"width=24 height=24 viewBox="0 0 24 24"fill=none aria-hidden=true xmlns=http://www.w3.org/2000/svg><path d="M12.7071 11.9993L18.0104 17.3026L17.3033 18.0097L12 12.7064L6.6967 18.0097L5.98959 17.3026L11.2929 11.9993L5.98959 6.69595L6.6967 5.98885L12 11.2921L17.3033 5.98885L18.0104 6.69595L12.7071 11.9993Z"fill=currentColor>`), _tmpl$8 = /* @__PURE__ */ template(`<svg class="icon icon-hamburger"width=24 height=24 viewBox="0 0 24 24"fill=none aria-hidden=true xmlns=http://www.w3.org/2000/svg><path d="M19 17H5V16H19V17Z"fill=currentColor></path><path d="M19 8H5V7H19V8Z"fill=currentColor>`), _tmpl$9 = /* @__PURE__ */ template(`<div id=nav-mobile-menu data-component=nav-mobile><nav data-component=nav-mobile-menu-list><ul><li></li><li><a target=_blank style=white-space:nowrap></a></li><li><a href=/v2/docs></a></li><li><a></a></li><!$><!/><!$><!/><li></li><!$><!/><!$><!/>`), _tmpl$0 = /* @__PURE__ */ template(`<section data-component=top><div></div><!$><!/><nav data-component=nav-desktop><ul><li><a target=_blank style=white-space:nowrap></a></li><li><a href=/v2/docs></a></li><li><a></a></li><li></li><li></li><li></li><!$><!/><!$><!/></ul></nav><nav data-component=nav-mobile><button type=button data-component=nav-mobile-toggle aria-expanded=false aria-controls=nav-mobile-menu class=nav-toggle><span class=sr-only></span><!$><!/></button><!$><!/>`); 19const isDarkMode = () => window.matchMedia("(prefers-color-scheme: dark)").matches; 20const fetchSvgContent = async (svgPath) => { 21 try { 22 const response = await fetch(svgPath); 23 const svgText = await response.text(); 24 return svgText; 25 } catch (err) { 26 console.error("Failed to fetch SVG content:", err); 27 throw err; 28 } 29}; 30function Header(props) { 31 const navigate = useNavigate(); 32 const i18n = useI18n(); 33 const language = useLanguage(); 34 const [store, setStore] = createStore({ 35 mobileMenuOpen: false, 36 contextMenuOpen: false, 37 contextMenuPosition: { 38 x: 0, 39 y: 0 40 } 41 });
42 createEffect(() => { 43 const handleClickOutside = () => { 44 setStore("contextMenuOpen", false); 45 }; 46 const handleContextMenu = (event) => { 47 event.preventDefault(); 48 setStore("contextMenuOpen", false); 49 }; 50 const handleKeyDown = (event) => { 51 if (event.key === "Escape") { 52 setStore("contextMenuOpen", false); 53 } 54 }; 55 if (store.contextMenuOpen) { 56 document.addEventListener("click", handleClickOutside); 57 document.addEventListener("contextmenu", handleContextMenu); 58 document.addEventListener("keydown", handleKeyDown); 59 onCleanup(() => { 60 document.removeEventListener("click", handleClickOutside); 61 document.removeEventListener("contextmenu", handleContextMenu); 62 document.removeEventListener("keydown", handleKeyDown); 63 }); 64 } 65 }); 66 const handleLogoContextMenu = (event) => { 67 event.preventDefault(); 68 const logoElement = event.currentTarget.querySelector("a"); 69 if (logoElement) { 70 const rect = logoElement.getBoundingClientRect(); 71 setStore("contextMenuPosition", { 72 x: rect.left - 16, 73 y: rect.bottom + 8 74 }); 75 } 76 setStore("contextMenuOpen", true); 77 }; 78 const copyWordmarkToClipboard = async () => { 79 try { 80 const isDark = isDarkMode(); 81 const wordmarkSvgPath = isDark ? copyWordmarkSvgDark : copyWordmarkSvgLight; 82 const wordmarkSvg = await fetchSvgContent(wordmarkSvgPath); 83 await navigator.clipboard.writeText(wordmarkSvg); 84 } catch (err) { 85 console.error("Failed to copy wordmark to clipboard:", err); 86 } 87 }; 88 const copyLogoToClipboard = async () => { 89 try { 90 const isDark = isDarkMode(); 91 const logoSvgPath = isDark ? copyLogoSvgDark : copyLogoSvgLight; 92 const logoSvg = await fetchSvgContent(logoSvgPath); 93 await navigator.clipboard.writeText(logoSvg); 94 } catch (err) { 95 console.error("Failed to copy logo to clipboard:", err); 96 } 97 }; 98 return (() => { 99 var _el$ = getNextElement(_tmpl$0), _el$2 = _el$.firstChild, _el$71 = _el$2.nextSibling, [_el$72, _co$10] = getNextMarker(_el$71.nextSibling), _el$19 = _el$72.nextSibling, _el$20 = _el$19.firstChild, _el$21 = _el$20.firstChild, _el$22 = _el$21.firstChild, _el$23 = _el$21.nextSibling, _el$24 = _el$23.firstChild, _el$25 = _el$23.nextSibling, _el$26 = _el$25.firstChild, _el$27 = _el$25.nextSibling, _el$28 = _el$27.nextSibling, _el$29 = _el$28.nextSibling, _el$34 = _el$29.nextSibling, [_el$35, _co$4] = getNextMarker(_el$34.nextSibling), _el$36 = _el$35.nextSibling, [_el$37, _co$5] = getNextMarker(_el$36.nextSibling), _el$38 = _el$19.nextSibling, _el$39 = _el$38.firstChild, _el$40 = _el$39.firstChild, _el$43 = _el$40.nextSibling, [_el$44, _co$6] = getNextMarker(_el$43.nextSibling), _el$69 = _el$39.nextSibling, [_el$70, _co$1] = getNextMarker(_el$69.nextSibling); 100 _el$2.$$contextmenu = handleLogoContextMenu; 101 insert(_el$2, createComponent(A, { 102 get href() { 103 return language.route("/"); 104 }, 105 get children() { 106 return [(() => { 107 var _el$3 = getNextElement(_tmpl$$1); 108 setAttribute(_el$3, "src", logoLight); 109 createRenderEffect(() => setAttribute(_el$3, "alt", i18n.t("nav.logoAlt"))); 110 return _el$3; 111 })(), (() => { 112 var _el$4 = getNextElement(_tmpl$2); 113 setAttribute(_el$4, "src", logoDark); 114 createRenderEffect(() => setAttribute(_el$4, "alt", i18n.t("nav.logoAlt"))); 115 return _el$4; 116 })()]; 117 } 118 })); 119 insert(_el$, createComponent(Show, { 120 get when() { 121 return store.contextMenuOpen; 122 }, 123 get children() { 124 var _el$5 = getNextElement(_tmpl$3), _el$6 = _el$5.firstChild, _el$7 = _el$6.firstChild, _el$8 = _el$7.nextSibling, _el$9 = _el$8.nextSibling, [_el$0, _co$] = getNextMarker(_el$9.nextSibling), _el$1 = _el$6.nextSibling, _el$10 = _el$1.firstChild, _el$11 = _el$10.nextSibling, _el$12 = _el$11.nextSibling, [_el$13, _co$2] = getNextMarker(_el$12.nextSibling), _el$14 = _el$1.nextSibling, _el$15 = _el$14.firstChild, _el$16 = _el$15.nextSibling, _el$17 = _el$16.nextSibling, [_el$18, _co$3] = getNextMarker(_el$17.nextSibling); 125 _el$6.$$click = copyLogoToClipboard; 126 setAttribute(_el$7, "src", copyLogoLight); 127 setAttribute(_el$8, "src", copyLogoDark); 128 insert(_el$6, () => i18n.t("nav.context.copyLogo"), _el$0, _co$); 129 _el$1.$$click = copyWordmarkToClipboard; 130 setAttribute(_el$10, "src", copyWordmarkLight); 131 setAttribute(_el$11, "src", copyWordmarkDark); 132 insert(_el$1, () => i18n.t("nav.context.copyWordmark"), _el$13, _co$2); 133 _el$14.$$click = () => navigate(language.route("/brand")); 134 setAttribute(_el$15, "src", copyBrandAssetsLight); 135 setAttribute(_el$16, "src", copyBrandAssetsDark); 136 insert(_el$14, () => i18n.t("nav.context.brandAssets"), _el$18, _co$3); 137 createRenderEffect((_$p) => style(_el$5, `left: ${store.contextMenuPosition.x}px; top: ${store.contextMenuPosition.y}px;`, _$p)); 138 runHydrationEvents(); 139 return _el$5; 140 } 141 }
141), _el$72, _co$10); 142 insert(_el$22, () => i18n.t("nav.github")); 143 insert(_el$24, () => i18n.t("nav.docs")); 144 insert(_el$26, () => i18n.t("nav.data")); 145 insert(_el$27, createComponent(A, { 146 get href() { 147 return language.route("/zen"); 148 }, 149 get children() { 150 return i18n.t("nav.zen"); 151 } 152 })); 153 insert(_el$28, createComponent(A, { 154 get href() { 155 return language.route("/go"); 156 }, 157 get children() { 158 return i18n.t("nav.go"); 159 } 160 })); 161 insert(_el$29, createComponent(A, { 162 get href() { 163 return language.route("/enterprise"); 164 }, 165 get children() { 166 return i18n.t("nav.enterprise"); 167 } 168 })); 169 insert(_el$20, createComponent(Show, { 170 get when() { 171 return props.zen || props.go; 172 }, 173 get children() { 174 var _el$30 = getNextElement(_tmpl$4), _el$31 = _el$30.firstChild; 175 insert(_el$31, () => i18n.t("nav.login")); 176 return _el$30; 177 } 178 }), _el$35, _co$4); 179 insert(_el$20, createComponent(Show, { 180 get when() { 181 return !props.hideGetStarted; 182 }, 183 get children() { 184 var _el$32 = getNextElement(_tmpl$6); 185 insert(_el$32, createComponent(A, { 186 get href() { 187 return language.route("/download"); 188 }, 189 "data-slot": "cta-button", 190 get children() { 191 return [getNextElement(_tmpl$5), memo(() => i18n.t("nav.free"))]; 192 } 193 })); 194 return _el$32; 195 } 196 }), _el$37, _co$5); 197 _el$39.$$click = () => setStore("mobileMenuOpen", !store.mobileMenuOpen); 198 insert(_el$40, () => i18n.t("nav.openMenu")); 199 insert(_el$39, createComponent(Switch, { 200 get children() { 201 return [createComponent(Match, { 202 get when() { 203 return store.mobileMenuOpen; 204 }, 205 get children() { 206 return getNextElement(_tmpl$7); 207 } 208 }), createComponent(Match, { 209 get when() { 210 return !store.mobileMenuOpen; 211 }, 212 get children() { 213 return getNextElement(_tmpl$8); 214 } 215 })]; 216 } 217 }), _el$44, _co$6); 218 insert(_el$38, createComponent(Show, { 219 get when() { 220 return store.mobileMenuOpen; 221 }, 222 get children() { 223 var _el$45 = getNextElement(_tmpl$9), _el$46 = _el$45.firstChild, _el$47 = _el$46.firstChild, _el$48 = _el$47.firstChild, _el$49 = _el$48.nextSibling, _el$50 = _el$49.firstChild, _el$51 = _el$49.nextSibling, _el$52 = _el$51.firstChild, _el$53 = _el$51.nextSibling, _el$54 = _el$53.firstChild, _el$61 = _el$53.nextSibling, [_el$62, _co$7] = getNextMarker(_el$61.nextSibling), _el$63 = _el$62.nextSibling, [_el$64, _co$8] = getNextMarker(_el$63.nextSibling), _el$57 = _el$64.nextSibling, _el$65 = _el$57.nextSibling, [_el$66, _co$9] = getNextMarker(_el$65.nextSibling), _el$67 = _el$66.nextSibling, [_el$68, _co$0] = getNextMarker(_el$67.nextSibling); 224 insert(_el$48, createComponent(A, { 225 get href() { 226 return language.route("/"); 227 }, 228 get children() { 229 return i18n.t("nav.home"); 230 } 231 })); 232 insert(_el$50, () => i18n.t("nav.github")); 233 insert(_el$52, () => i18n.t("nav.docs")); 234 insert(_el$54, () => i18n.t("nav.data")); 235 insert(_el$47, createComponent(Show, { 236 get when() { 237 return !props.zen; 238 }, 239 get children() { 240 var _el$55 = getNextElement(_tmpl$6); 241 insert(_el$55, createComponent(A, { 242 get href() { 243 return language.route("/zen"); 244 }, 245 get children() { 246 return i18n.t("nav.zen"); 247 } 248 })); 249 return _el$55; 250 } 251 }), _el$62, _co$7); 252 insert(_el$47, createComponent(Show, { 253 get when() { 254 return !props.go; 255 }, 256 get children() { 257 var _el$56 = getNextElement(_tmpl$6); 258 insert(_el$56, createComponent(A, { 259 get href() { 260 return language.route("/go"); 261 }, 262 get children() { 263 return i18n.t("nav.go"); 264 } 265 })); 266 return _el$56; 267 } 268 }), _el$64, _co$8); 269 insert(_el$57, createComponent(A, { 270 get href() { 271 return language.route("/enterprise"); 272 }, 273 get children() { 274 return i18n.t("nav.enterprise"); 275 } 276 })); 277 insert(_el$47, createComponent(Show, { 278 get when() { 279 return props.zen || props.go; 280 }, 281 get children() { 282 var _el$58 = getNextElement(_tmpl$4), _el$59 = _el$58.firstChild; 283 insert(_el$59, () => i18n.t("nav.login")); 284 return _el$58; 285 } 286 }), _el$66, _co$9); 287 insert(_el$47, createComponent(Show, { 288 get when() { 289 return !props.hideGetStarted; 290 }, 291 get children() { 292 var _el$60 = getNextElement(_tmpl$6); 293 insert(_el$60, createComponent(A, { 294 get href() { 295 return language.route("/download"); 296 }, 297 "data-slot": "cta-button", 298 get children() { 299 return i18n.t("nav.getStartedFree"); 300 } 301 })); 302 return _el$60; 303 } 304 }), _el$68, _co$0); 305 createRenderEffect((_p$) => { 306 var _v$ = `${config.github.repoUrl}/tree/v2`, _v$2 = language.route("/data"); 307 _v$ !== _p$.e && setAttribute(_el$50, "href", _p$.e = _v$); 308 _v$2 !== _p$.t && setAttribute(_el$54, "href", _p$.t = _v$2); 309 return _p$; 310 }, { 311 e: void 0, 312 t: void 0 313 }); 314 return _el$45; 315 } 316 }), _el$70, _co$1); 317 createRenderEffect((_p$) => { 318 var _v$3 = `${config.github.repoUrl}/tree/v2`, _v$4 = language.route("/data"); 319 _v$3 !== _p$.e && setAttribute(_el$22, "href", _p$.e = _v$3); 320 _v$4 !== _p$.t && setAttribute(_el$26, "href", _p$.t = _v$4); 321 return _p$; 322 }, {
323 e: void 0, 324 t: void 0 325 }); 326 runHydrationEvents(); 327 return _el$; 328 })(); 329} 330delegateEvents(["contextmenu", "click"]); 331var _tmpl$ = /* @__PURE__ */ template(`<footer data-component=footer><div data-slot=cell><a target=_blank><!$><!/> <span>[<!$><!/>]</span></a></div><div data-slot=cell><a></a></div><div data-slot=cell><a></a></div><div data-slot=cell><a></a></div><div data-slot=cell><a>`); 332function Footer() { 333 const language = useLanguage(); 334 const i18n = useI18n(); 335 const community = createMemo(() => { 336 const locale = language.locale(); 337 return locale === "zh" || locale === "zht" ? { 338 key: "footer.feishu", 339 link: language.route("/feishu") 340 } : { 341 key: "footer.discord", 342 link: language.route("/discord") 343 }; 344 }); 345 const githubData = createAsync(() => github()); 346 const starCount = createMemo(() => githubData()?.stars ? new Intl.NumberFormat(language.tag(language.locale()), { 347 notation: "compact", 348 compactDisplay: "short" 349 }).format(githubData().stars) : config.github.starsFormatted.compact); 350 return (() => { 351 var _el$ = getNextElement(_tmpl$), _el$2 = _el$.firstChild, _el$3 = _el$2.firstChild, _el$0 = _el$3.firstChild, [_el$1, _co$2] = getNextMarker(_el$0.nextSibling), _el$4 = _el$1.nextSibling, _el$5 = _el$4.nextSibling, _el$6 = _el$5.firstChild, _el$8 = _el$6.nextSibling, [_el$9, _co$] = getNextMarker(_el$8.nextSibling); 352 _el$9.nextSibling; 353 var _el$10 = _el$2.nextSibling, _el$11 = _el$10.firstChild, _el$12 = _el$10.nextSibling, _el$13 = _el$12.firstChild, _el$14 = _el$12.nextSibling, _el$15 = _el$14.firstChild, _el$16 = _el$14.nextSibling, _el$17 = _el$16.firstChild; 354 insert(_el$3, () => i18n.t("footer.github"), _el$1, _co$2); 355 insert(_el$5, starCount, _el$9, _co$); 356 insert(_el$11, () => i18n.t("footer.docs")); 357 insert(_el$13, () => i18n.t("footer.changelog")); 358 insert(_el$15, () => i18n.t(community().key)); 359 insert(_el$17, () => i18n.t("footer.x")); 360 createRenderEffect((_p$) => { 361 var _v$ = config.github.repoUrl, _v$2 = language.route("/docs"), _v$3 = language.route("/changelog"), _v$4 = community().link, _v$5 = config.social.twitter; 362 _v$ !== _p$.e && setAttribute(_el$3, "href", _p$.e = _v$); 363 _v$2 !== _p$.t && setAttribute(_el$11, "href", _p$.t = _v$2); 364 _v$3 !== _p$.a && setAttribute(_el$13, "href", _p$.a = _v$3); 365 _v$4 !== _p$.o && setAttribute(_el$15, "href", _p$.o = _v$4); 366 _v$5 !== _p$.i && setAttribute(_el$17, "href", _p$.i = _v$5); 367 return _p$; 368 }, { 369 e: void 0, 370 t: void 0, 371 a: void 0, 372 o: void 0, 373 i: void 0 374 }); 375 return _el$; 376 })(); 377} 378export { 379 Footer as F, 380 Header as H 381};
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.