corequery 0.18.0 → 0.18.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/package.json +1 -1
  2. package/web/dist/assets/{About-DCZPSDgX.js → About-CAf6-nDt.js} +1 -1
  3. package/web/dist/assets/AdminControls-B031rLMC.js +1 -0
  4. package/web/dist/assets/{Alert-DqAOXpg1.js → Alert-CzjHVmGJ.js} +1 -1
  5. package/web/dist/assets/{Debug-CofWDu-3.js → Debug-CaIPS7C9.js} +1 -1
  6. package/web/dist/assets/{Divider-BcodRRFp.js → Divider-2CyojEuM.js} +1 -1
  7. package/web/dist/assets/Home-TCrBBlhk.js +1 -0
  8. package/web/dist/assets/{Line-Bmt5V-JG.js → Line-CHDt7wk6.js} +1 -1
  9. package/web/dist/assets/{LinkText-CuzmudpX.js → LinkText-hoDnNcKa.js} +1 -1
  10. package/web/dist/assets/{Markdown-Cac8FRvA.js → Markdown-CdjM3EWV.js} +1 -1
  11. package/web/dist/assets/Nearby-CL-_r0F3.js +1 -0
  12. package/web/dist/assets/NotFound-C4LMPDBR.js +1 -0
  13. package/web/dist/assets/{NotFoundPage-CjreacId.js → NotFoundPage-DGh2AlPH.js} +1 -1
  14. package/web/dist/assets/{Page-BISwM3fy.js → Page-DdURsQrw.js} +1 -1
  15. package/web/dist/assets/{Picker-CNeXxMsu.js → Picker-DgCfICF8.js} +1 -1
  16. package/web/dist/assets/{Placeholder-CfWUL8Q7.js → Placeholder-ot4omkMw.js} +1 -1
  17. package/web/dist/assets/{Settings-DTkq0LPs.js → Settings-DrvaPw5K.js} +1 -1
  18. package/web/dist/assets/Status-Dtg7aSyd.js +1 -0
  19. package/web/dist/assets/{Stop-BTYeBxkC.js → Stop-Bt6cRJ9f.js} +1 -1
  20. package/web/dist/assets/{Strong-BND8QD53.js → Strong-B3a6utE4.js} +1 -1
  21. package/web/dist/assets/ZenMode-DqkK9TS1.js +1 -0
  22. package/web/dist/assets/{index-jI1qL-AF.js → index-ggoGQEW6.js} +2 -2
  23. package/web/dist/assets/{use-simple-headers-CqMikxZC.js → use-simple-headers-dzwgogJg.js} +1 -1
  24. package/web/dist/index.html +1 -1
  25. package/web/dist/sw.js +1 -1
  26. package/web/dist/assets/AdminControls-CpAjDT3_.js +0 -1
  27. package/web/dist/assets/Home-dNO-yO__.js +0 -1
  28. package/web/dist/assets/Nearby-C8uhAo0W.js +0 -1
  29. package/web/dist/assets/NotFound-cAXZYx-i.js +0 -1
  30. package/web/dist/assets/Status-CHOcJQcX.js +0 -1
  31. package/web/dist/assets/ZenMode-DPheq9G5.js +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "corequery",
3
- "version": "0.18.0",
3
+ "version": "0.18.1",
4
4
  "type": "module",
5
5
  "files": [
6
6
  "server/dist",
@@ -1 +1 @@
1
- import{u as m,a as p,b as u,c as h,d as s,C as l,T as d}from"./index-jI1qL-AF.js";import{T as a}from"./Placeholder-CfWUL8Q7.js";import{M as f,I as w}from"./Markdown-Cac8FRvA.js";import{P as r}from"./Page-BISwM3fy.js";import{u as x}from"./use-simple-headers-CqMikxZC.js";import{D as v}from"./Divider-BcodRRFp.js";import{A as k}from"./Alert-DqAOXpg1.js";import"./LinkText-CuzmudpX.js";import"./Strong-BND8QD53.js";function I(){const{appName:c}=m(),{foda:o}=p(),{data:e,loading:i,error:n}=u(h,{}),t=x({title:`About ${c}`});return i?s(r,{...t,children:s(l,{class:"px-4 py-8",children:[s(a,{class:"w-[30%] text-xl"}),s("div",{class:"h-8"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-[60%] text-md"}),s("div",{class:"h-12"}),s(a,{class:"w-[40%] text-lg"}),s("div",{class:"h-8"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-[20%] text-md"}),s("div",{class:"h-12"}),s(a,{class:"w-[50%] text-lg"}),s("div",{class:"h-8"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-[80%] text-md"})]})}):n!=null||e==null?s(r,{...t,children:s(l,{class:"px-4 py-8",children:s(k,{type:"error",children:s(d,{children:"Unable to load the about page."})})})}):s(r,{...t,children:s(l,{class:"px-4 py-8 gap-12",children:[s(f,{markdown:e.primaryMarkdown}),s(l,{class:"gap-8",children:[s(v,{}),s(d,{as:"p",style:"small-weak",children:s(w,{markdown:o.footerPrimaryMarkdown})})]})]})})}export{I as default};
1
+ import{u as m,a as p,b as u,c as h,d as s,C as l,T as d}from"./index-ggoGQEW6.js";import{T as a}from"./Placeholder-ot4omkMw.js";import{M as f,I as w}from"./Markdown-CdjM3EWV.js";import{P as r}from"./Page-DdURsQrw.js";import{u as x}from"./use-simple-headers-dzwgogJg.js";import{D as v}from"./Divider-2CyojEuM.js";import{A as k}from"./Alert-CzjHVmGJ.js";import"./LinkText-hoDnNcKa.js";import"./Strong-B3a6utE4.js";function I(){const{appName:c}=m(),{foda:o}=p(),{data:e,loading:i,error:n}=u(h,{}),t=x({title:`About ${c}`});return i?s(r,{...t,children:s(l,{class:"px-4 py-8",children:[s(a,{class:"w-[30%] text-xl"}),s("div",{class:"h-8"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-[60%] text-md"}),s("div",{class:"h-12"}),s(a,{class:"w-[40%] text-lg"}),s("div",{class:"h-8"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-[20%] text-md"}),s("div",{class:"h-12"}),s(a,{class:"w-[50%] text-lg"}),s("div",{class:"h-8"}),s(a,{class:"w-full text-md"}),s("div",{class:"h-3"}),s(a,{class:"w-[80%] text-md"})]})}):n!=null||e==null?s(r,{...t,children:s(l,{class:"px-4 py-8",children:s(k,{type:"error",children:s(d,{children:"Unable to load the about page."})})})}):s(r,{...t,children:s(l,{class:"px-4 py-8 gap-12",children:[s(f,{markdown:e.primaryMarkdown}),s(l,{class:"gap-8",children:[s(v,{}),s(d,{as:"p",style:"small-weak",children:s(w,{markdown:o.footerPrimaryMarkdown})})]})]})})}export{I as default};
@@ -0,0 +1 @@
1
+ import{d as e,C as r,T as a}from"./index-ggoGQEW6.js";import{P as o}from"./Page-DdURsQrw.js";import{u as t}from"./use-simple-headers-dzwgogJg.js";function i(){return e(o,{...t({title:"Admin controls"}),children:e(r,{class:"px-4 py-8 gap-8",children:e(a,{children:"Maybe the real admin controls were the friends we made along the way?"})})})}export{i as default};
@@ -1 +1 @@
1
- import{d as e,e as o,p as a,U as i,g as s,G as g}from"./index-jI1qL-AF.js";function f(l){return e("div",{class:o(l.class,"flex flex-col justify-center items-stretch"),style:{height:`${l.heightRem}rem`},children:l.children})}function h(l){return e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...l,children:e("g",{fill:"none",children:[e("path",{d:"m12.593 23.258l-.011.002l-.071.035l-.02.004l-.014-.004l-.071-.035q-.016-.005-.024.005l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.017-.018m.265-.113l-.013.002l-.185.093l-.01.01l-.003.011l.018.43l.005.012l.008.007l.201.093q.019.005.029-.008l.004-.014l-.034-.614q-.005-.018-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.004-.011l.017-.43l-.003-.012l-.01-.01z"}),e("path",{fill:"currentColor",d:"m13.299 3.148l8.634 14.954a1.5 1.5 0 0 1-1.299 2.25H3.366a1.5 1.5 0 0 1-1.299-2.25l8.634-14.954c.577-1 2.02-1 2.598 0M12 4.898L4.232 18.352h15.536zM12 15a1 1 0 1 1 0 2a1 1 0 0 1 0-2m0-7a1 1 0 0 1 1 1v4a1 1 0 1 1-2 0V9a1 1 0 0 1 1-1"})]})})}function d(l){return e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...l,children:e("g",{fill:"none",fillRule:"evenodd",children:[e("path",{d:"m12.593 23.258l-.011.002l-.071.035l-.02.004l-.014-.004l-.071-.035q-.016-.005-.024.005l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.017-.018m.265-.113l-.013.002l-.185.093l-.01.01l-.003.011l.018.43l.005.012l.008.007l.201.093q.019.005.029-.008l.004-.014l-.034-.614q-.005-.018-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.004-.011l.017-.43l-.003-.012l-.01-.01z"}),e("path",{fill:"currentColor",d:"M21.192 5.465a1 1 0 0 1 0 1.414L9.95 18.122a1.1 1.1 0 0 1-1.556 0l-5.586-5.586a1 1 0 1 1 1.415-1.415l4.95 4.95L19.777 5.465a1 1 0 0 1 1.414 0Z"})]})})}function x(l){const t={info:i,error:a,warning:h,success:d}[l.type],r=l.icon!==void 0?l.icon:t,c={info:"bg-soft-accent",error:"bg-soft-error",warning:"bg-soft-warning",success:"bg-soft-success"}[l.type],n={info:["[--color-fg:var(--color-accent-text)]","[--color-fg-strong:var(--color-accent-text)]","[--color-fg-weak:var(--color-accent-text)]"],error:["[--color-fg:var(--color-error-text)]","[--color-fg-strong:var(--color-error-text)]","[--color-fg-weak:var(--color-error-text)]"],warning:["[--color-fg:var(--color-warning-text)]","[--color-fg-strong:var(--color-warning-text)]","[--color-fg-weak:var(--color-warning-text)]"],success:["[--color-fg:var(--color-success-text)]","[--color-fg-strong:var(--color-success-text)]","[--color-fg-weak:var(--color-success-text)]"]}[l.type];return e(g,{class:o(l.class,c,n,"px-4 py-4.5 rounded-sm gap-2 items-start",{"grid-cols-[auto_1fr]":r!=null}),children:[r!=null&&e(f,{heightRem:s("text-md"),children:e(r,{class:"text-fg text-icon-lg"})}),l.children]})}export{x as A,f as V};
1
+ import{d as e,e as o,p as a,U as i,g as s,G as g}from"./index-ggoGQEW6.js";function f(l){return e("div",{class:o(l.class,"flex flex-col justify-center items-stretch"),style:{height:`${l.heightRem}rem`},children:l.children})}function h(l){return e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...l,children:e("g",{fill:"none",children:[e("path",{d:"m12.593 23.258l-.011.002l-.071.035l-.02.004l-.014-.004l-.071-.035q-.016-.005-.024.005l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.017-.018m.265-.113l-.013.002l-.185.093l-.01.01l-.003.011l.018.43l.005.012l.008.007l.201.093q.019.005.029-.008l.004-.014l-.034-.614q-.005-.018-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.004-.011l.017-.43l-.003-.012l-.01-.01z"}),e("path",{fill:"currentColor",d:"m13.299 3.148l8.634 14.954a1.5 1.5 0 0 1-1.299 2.25H3.366a1.5 1.5 0 0 1-1.299-2.25l8.634-14.954c.577-1 2.02-1 2.598 0M12 4.898L4.232 18.352h15.536zM12 15a1 1 0 1 1 0 2a1 1 0 0 1 0-2m0-7a1 1 0 0 1 1 1v4a1 1 0 1 1-2 0V9a1 1 0 0 1 1-1"})]})})}function d(l){return e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...l,children:e("g",{fill:"none",fillRule:"evenodd",children:[e("path",{d:"m12.593 23.258l-.011.002l-.071.035l-.02.004l-.014-.004l-.071-.035q-.016-.005-.024.005l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.017-.018m.265-.113l-.013.002l-.185.093l-.01.01l-.003.011l.018.43l.005.012l.008.007l.201.093q.019.005.029-.008l.004-.014l-.034-.614q-.005-.018-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.004-.011l.017-.43l-.003-.012l-.01-.01z"}),e("path",{fill:"currentColor",d:"M21.192 5.465a1 1 0 0 1 0 1.414L9.95 18.122a1.1 1.1 0 0 1-1.556 0l-5.586-5.586a1 1 0 1 1 1.415-1.415l4.95 4.95L19.777 5.465a1 1 0 0 1 1.414 0Z"})]})})}function x(l){const t={info:i,error:a,warning:h,success:d}[l.type],r=l.icon!==void 0?l.icon:t,c={info:"bg-soft-accent",error:"bg-soft-error",warning:"bg-soft-warning",success:"bg-soft-success"}[l.type],n={info:["[--color-fg:var(--color-accent-text)]","[--color-fg-strong:var(--color-accent-text)]","[--color-fg-weak:var(--color-accent-text)]"],error:["[--color-fg:var(--color-error-text)]","[--color-fg-strong:var(--color-error-text)]","[--color-fg-weak:var(--color-error-text)]"],warning:["[--color-fg:var(--color-warning-text)]","[--color-fg-strong:var(--color-warning-text)]","[--color-fg-weak:var(--color-warning-text)]"],success:["[--color-fg:var(--color-success-text)]","[--color-fg-strong:var(--color-success-text)]","[--color-fg-weak:var(--color-success-text)]"]}[l.type];return e(g,{class:o(l.class,c,n,"px-4 py-4.5 rounded-sm gap-2 items-start",{"grid-cols-[auto_1fr]":r!=null}),children:[r!=null&&e(f,{heightRem:s("text-md"),children:e(r,{class:"text-fg text-icon-lg"})}),l.children]})}export{x as A,f as V};
@@ -1 +1 @@
1
- import{X as P,x as A,d as e,T as l,e as i,G as f,g as h,R as g,f as R,M as S,B as k,L as D,h as H,C as a,u as v,b as B,i as L,a as T}from"./index-jI1qL-AF.js";import{P as E}from"./Page-BISwM3fy.js";import{u as F}from"./use-simple-headers-CqMikxZC.js";import{D as d}from"./Divider-BcodRRFp.js";import{V as m,A as p}from"./Alert-DqAOXpg1.js";import{T as x}from"./Placeholder-CfWUL8Q7.js";const y=P(null);function c(){const n=A(y);if(n==null)throw new Error("Foundational data unavailable outside provider.");return n}function U(n){const r={info:"bg-soft-accent",error:"bg-soft-error",warning:"bg-soft-warning",success:"bg-soft-success"}[n.type],t={info:"[--color-fg:var(--color-accent-text)]",error:"[--color-fg:var(--color-error-text)]",warning:"[--color-fg:var(--color-warning-text)]",success:"[--color-fg:var(--color-success-text)]"}[n.type];return e(f,{class:i(n.class,r,t,"px-2 py-1.5 rounded-full"),children:e(l,{style:"small",children:n.text})})}function C(n){return e(g,{class:i(n.class,"gap-x-2 gap-y-3"),wrap:!0,children:[e(l,{style:"strong",children:n.header}),n.loading&&e(x,{class:"w-[20%] text-md"}),!n.loading&&n.pillContent!=null&&e(m,{heightRem:h("text-md"),children:e(U,{type:n.pillContent.type,text:n.pillContent.text})})]})}function V(n){return e(C,{class:n.class,header:n.header,pillContent:M(n.currentValue,n.latestValue),loading:n.loading})}function M(n,r){return r==null?null:{text:n===r?"Up to date":"Outdated",type:n===r?"success":"error"}}function u(n){return n.loading?e(f,{class:n.class,children:e(x,{class:"w-[40%] text-md"})}):n.value==null?null:e(l,{class:n.class,children:[n.prefix,": ",n.value]})}function o(n){return n==null?null:n.length<32||!/^[0-9a-f]+$/.test(n)?n:n.slice(0,7)}function O(n){const{isUpdateAvailable:r,update:t}=R();return r?e(k,{theme:"accent",text:"Refresh & update",class:"self-start",icon:S,onClick:()=>{t()}}):e(g,{class:i(n.class,"gap-2"),children:[e(m,{heightRem:h("text-md"),children:e(D,{})}),e(l,{class:"min-w-0 shrink",children:"Waiting for service worker to install update..."})]})}function W(n){const{isHotReloadingEnabled:r}=H();return r?e(Q,{...n}):e(q,{...n})}function Q(n){const{data:r,loading:t}=c();return e(a,{class:i(n.class,"gap-6"),children:[e(C,{header:"App version",pillContent:{text:"Development",type:"info"},loading:!1}),e(l,{children:"All frontend code is being served with hot-reloading enabled, not through the PWA. (The below values are meaningless.)"}),e(w,{}),e(u,{prefix:"Latest version",value:r?.frontendVersion.slice(0,8)??null,loading:t})]})}function q(n){const{frontendVersion:r}=v(),{data:t,loading:s}=c(),b=!s&&t!=null&&t?.frontendVersion!==r;return e(a,{class:i(n.class,"gap-8"),children:e(a,{class:"gap-6",children:[e(V,{header:"App version",currentValue:r,latestValue:t?.frontendVersion??null,loading:s}),e(w,{}),e(u,{prefix:"Latest version",value:o(t?.frontendVersion),loading:s}),b&&e(O,{})]})})}function w(){const{frontendVersion:n,versionsOnLastUpdate:r}=v();return e(a,{class:"gap-4",children:[e(l,{children:["Current version: ",o(n)]}),e(a,{class:"gap-3",children:[e(l,{style:"small-weak",children:["Server version: ",o(r.serverVersion)]}),e(l,{style:"small-weak",children:["CoreQuery version: ",r.corequeryPackageVersion]})]})]})}function G(n){const r=B(L,{});return e(y.Provider,{value:r,children:n.children})}function $(n){const{data:r,loading:t}=c(),{foda:s}=T();return e(a,{class:i(n.class,"gap-6"),children:[e(V,{header:"Foundational data",currentValue:s.hash,latestValue:r?.foundationalDataHash??null,loading:t}),e(a,{class:"gap-4",children:[e(l,{children:["Current version: ",o(s.hash)]}),e(l,{style:"small-weak",children:["Server version: ",o(s.serverVersion)]})]}),e(u,{prefix:"Latest version",value:o(r?.foundationalDataHash),loading:t})]})}function I(n){const{data:r,loading:t}=c();return e(a,{class:i(n.class,"gap-8"),children:e(a,{class:"gap-6",children:[e(l,{style:"strong",children:"Server"}),e(X,{}),e(a,{class:"gap-4",children:[e(u,{prefix:"Server version",value:o(r?.serverVersion),loading:t}),e(u,{prefix:"CoreQuery version",value:r?.corequeryPackageVersion??null,loading:t})]})]})})}function X(){const{error:n}=c();return n==null?null:e(p,{type:"error",children:e(l,{children:"Unable to fetch the latest version info from the server."})})}function _(){return e(E,{...F({title:"Developer info"}),children:e(G,{children:e(a,{class:"px-4 py-8 gap-8",children:[e(j,{}),e(W,{}),e(d,{}),e($,{}),e(d,{}),e(I,{}),e(d,{})]})})})}function j(){const{error:n}=c();return n==null?null:e(p,{type:"error",children:e(l,{children:"Unable to fetch the latest version info from the server."})})}export{_ as default};
1
+ import{X as P,x as A,d as e,T as l,e as i,G as f,g as h,R as g,f as R,M as S,B as k,L as D,h as H,C as a,u as v,b as B,i as L,a as T}from"./index-ggoGQEW6.js";import{P as E}from"./Page-DdURsQrw.js";import{u as F}from"./use-simple-headers-dzwgogJg.js";import{D as d}from"./Divider-2CyojEuM.js";import{V as m,A as p}from"./Alert-CzjHVmGJ.js";import{T as x}from"./Placeholder-ot4omkMw.js";const y=P(null);function c(){const n=A(y);if(n==null)throw new Error("Foundational data unavailable outside provider.");return n}function U(n){const r={info:"bg-soft-accent",error:"bg-soft-error",warning:"bg-soft-warning",success:"bg-soft-success"}[n.type],t={info:"[--color-fg:var(--color-accent-text)]",error:"[--color-fg:var(--color-error-text)]",warning:"[--color-fg:var(--color-warning-text)]",success:"[--color-fg:var(--color-success-text)]"}[n.type];return e(f,{class:i(n.class,r,t,"px-2 py-1.5 rounded-full"),children:e(l,{style:"small",children:n.text})})}function C(n){return e(g,{class:i(n.class,"gap-x-2 gap-y-3"),wrap:!0,children:[e(l,{style:"strong",children:n.header}),n.loading&&e(x,{class:"w-[20%] text-md"}),!n.loading&&n.pillContent!=null&&e(m,{heightRem:h("text-md"),children:e(U,{type:n.pillContent.type,text:n.pillContent.text})})]})}function V(n){return e(C,{class:n.class,header:n.header,pillContent:M(n.currentValue,n.latestValue),loading:n.loading})}function M(n,r){return r==null?null:{text:n===r?"Up to date":"Outdated",type:n===r?"success":"error"}}function u(n){return n.loading?e(f,{class:n.class,children:e(x,{class:"w-[40%] text-md"})}):n.value==null?null:e(l,{class:n.class,children:[n.prefix,": ",n.value]})}function o(n){return n==null?null:n.length<32||!/^[0-9a-f]+$/.test(n)?n:n.slice(0,7)}function O(n){const{isUpdateAvailable:r,update:t}=R();return r?e(k,{theme:"accent",text:"Refresh & update",class:"self-start",icon:S,onClick:()=>{t()}}):e(g,{class:i(n.class,"gap-2"),children:[e(m,{heightRem:h("text-md"),children:e(D,{})}),e(l,{class:"min-w-0 shrink",children:"Waiting for service worker to install update..."})]})}function W(n){const{isHotReloadingEnabled:r}=H();return r?e(Q,{...n}):e(q,{...n})}function Q(n){const{data:r,loading:t}=c();return e(a,{class:i(n.class,"gap-6"),children:[e(C,{header:"App version",pillContent:{text:"Development",type:"info"},loading:!1}),e(l,{children:"All frontend code is being served with hot-reloading enabled, not through the PWA. (The below values are meaningless.)"}),e(w,{}),e(u,{prefix:"Latest version",value:r?.frontendVersion.slice(0,8)??null,loading:t})]})}function q(n){const{frontendVersion:r}=v(),{data:t,loading:s}=c(),b=!s&&t!=null&&t?.frontendVersion!==r;return e(a,{class:i(n.class,"gap-8"),children:e(a,{class:"gap-6",children:[e(V,{header:"App version",currentValue:r,latestValue:t?.frontendVersion??null,loading:s}),e(w,{}),e(u,{prefix:"Latest version",value:o(t?.frontendVersion),loading:s}),b&&e(O,{})]})})}function w(){const{frontendVersion:n,versionsOnLastUpdate:r}=v();return e(a,{class:"gap-4",children:[e(l,{children:["Current version: ",o(n)]}),e(a,{class:"gap-3",children:[e(l,{style:"small-weak",children:["Server version: ",o(r.serverVersion)]}),e(l,{style:"small-weak",children:["CoreQuery version: ",r.corequeryPackageVersion]})]})]})}function G(n){const r=B(L,{});return e(y.Provider,{value:r,children:n.children})}function $(n){const{data:r,loading:t}=c(),{foda:s}=T();return e(a,{class:i(n.class,"gap-6"),children:[e(V,{header:"Foundational data",currentValue:s.hash,latestValue:r?.foundationalDataHash??null,loading:t}),e(a,{class:"gap-4",children:[e(l,{children:["Current version: ",o(s.hash)]}),e(l,{style:"small-weak",children:["Server version: ",o(s.serverVersion)]})]}),e(u,{prefix:"Latest version",value:o(r?.foundationalDataHash),loading:t})]})}function I(n){const{data:r,loading:t}=c();return e(a,{class:i(n.class,"gap-8"),children:e(a,{class:"gap-6",children:[e(l,{style:"strong",children:"Server"}),e(X,{}),e(a,{class:"gap-4",children:[e(u,{prefix:"Server version",value:o(r?.serverVersion),loading:t}),e(u,{prefix:"CoreQuery version",value:r?.corequeryPackageVersion??null,loading:t})]})]})})}function X(){const{error:n}=c();return n==null?null:e(p,{type:"error",children:e(l,{children:"Unable to fetch the latest version info from the server."})})}function _(){return e(E,{...F({title:"Developer info"}),children:e(G,{children:e(a,{class:"px-4 py-8 gap-8",children:[e(j,{}),e(W,{}),e(d,{}),e($,{}),e(d,{}),e(I,{}),e(d,{})]})})})}function j(){const{error:n}=c();return n==null?null:e(p,{type:"error",children:e(l,{children:"Unable to fetch the latest version info from the server."})})}export{_ as default};
@@ -1 +1 @@
1
- import{d as s,e as o}from"./index-jI1qL-AF.js";function d(r){return s("div",{class:o(r.class,"border-b border-soft-border")})}export{d as D};
1
+ import{d as s,e as o}from"./index-ggoGQEW6.js";function d(r){return s("div",{class:o(r.class,"border-b border-soft-border")})}export{d as D};
@@ -0,0 +1 @@
1
+ import{a as r,d as a,C as m}from"./index-ggoGQEW6.js";import{P as e}from"./Page-DdURsQrw.js";import{u as t}from"./use-simple-headers-dzwgogJg.js";import{M as i}from"./Markdown-CdjM3EWV.js";import"./LinkText-hoDnNcKa.js";import"./Strong-B3a6utE4.js";function f(){const{foda:o}=r();return a(e,{...t({title:"Home"}),children:a(m,{class:"px-4 py-8 gap-12",children:a(i,{markdown:o.landingPage.primaryMarkdown})})})}export{f as default};
@@ -1 +1 @@
1
- import{a as D,u as X,j as w,d as n,T as v,C as f,e as d,A as B,m as N,y as Y,G as _,n as h,k as G,q as j,l as Q,o as Z}from"./index-jI1qL-AF.js";import{P as K}from"./Page-BISwM3fy.js";import{u as J}from"./use-simple-headers-CqMikxZC.js";import{N as tt}from"./NotFoundPage-CjreacId.js";import{L as P}from"./LinkText-CuzmudpX.js";import{A as et}from"./Alert-DqAOXpg1.js";import{P as ot}from"./Picker-CNeXxMsu.js";function R(t){throw new Error(`Unexpected value: ${String(t)}`)}function nt(t){if(!/^-?[0-9]+$/g.test(t))throw it(t);return parseInt(t,10)}const it=t=>new Error(`"${t}" is not an integer.`);function st(t){const{foda:e}=D(),{appName:o}=X(),i=w(()=>t.fallbackStopList.map(s=>e.stops.require(s)).sort((s,l)=>s.name.localeCompare(l.name)),[e.stops,t.fallbackStopList]);return n(f,{class:d(t.class,"gap-6"),children:[n(v,{style:"subtitle",children:"Stops"}),n(et,{type:"info",children:n(f,{class:"gap-6",children:[n(v,{children:["A neat little diagram is also available for this line, but it's of a new type, and so requires a newer version of ",o," to be able to view."," "]}),n(v,{style:"strong",children:n(P,{href:"/debug",children:"Help me update"})})]})}),n("ul",{class:"flex-col flex list-disc list-inside gap-4",children:i.map(s=>n(v,{children:n("li",{children:n(P,{href:`/stop/${s.urlPath}`,children:s.name})})}))})]})}class rt{constructor(e,o){this._canvasContainer=e,this._canvas=o;const i=this._canvas.getContext("2d");if(i==null)throw new Error("Failed to get 2D rendering context.");this.ctx=i,this._resizeListener=this._onResize.bind(this),this._resizeObserver=new ResizeObserver(this._resizeListener),this._data=null,this._width=1,this._height=1,this._dpiRatio=1,this._dirty=!0,this._running=!1}_canvasContainer;_canvas;ctx;_resizeListener;_resizeObserver;_data;_width;_height;_dpiRatio;_dirty;_running;get data(){if(this._data==null)throw new Error("Data not set.");return this._data}get width(){return this._width}get height(){return this._height}setData(e){this._data=e,this.onDataUpdated(),this._dirty=!0,this._running||this._start()}_start(){this._fitCanvas(),this._running=!0,this._render(),window.addEventListener("resize",this._resizeListener),this._resizeObserver.observe(this._canvasContainer),this.onStart()}destroy(){this._running=!1,window.removeEventListener("resize",this._resizeListener),this._resizeObserver.unobserve(this._canvasContainer),this.onDestroy()}_render(){this._running&&(requestAnimationFrame(()=>{this._render()}),this._dirty&&(this._dirty=!1,this.ctx.save(),this.ctx.clearRect(0,0,this._width*this._dpiRatio,this._height*this._dpiRatio),this.ctx.scale(this._dpiRatio,this._dpiRatio),this.onRender(),this.ctx.restore()))}onStart(){}onDestroy(){}onDataUpdated(){}_onResize(){this._fitCanvas()}_fitCanvas(){const e=this._canvasContainer.getBoundingClientRect();this._width=e.width,this._height=e.height;const o=window.devicePixelRatio??1,i=this.ctx.backingStorePixelRatio??1;this._dpiRatio=o/i,this._canvas.style.width=`${this._width}px`,this._canvas.style.height=`${this._height}px`,this._canvas.width=this._width*this._dpiRatio,this._canvas.height=this._height*this._dpiRatio,this._dirty=!0}markDirty(){this._dirty=!0}}function at(t){const{data:e,createController:o}=t,i=B(null),s=B(null),[l,r]=N(null),a=t.interceptTouches??!1?{touchAction:"none"}:void 0;return Y(()=>{if(i.current==null||s.current==null)return;const c=o(i.current,s.current);return r(c),()=>{c?.destroy()}},[o]),Y(()=>{l?.setData(e)},[l,e]),n("div",{ref:i,className:d(t.class,"relative overflow-hidden"),children:n("canvas",{className:"absolute top-0 left-0",ref:s,style:a})})}function lt(){const t=window.getComputedStyle(document.body);return{bg:t.getPropertyValue("--color-bg"),fg:t.getPropertyValue("--color-fg"),"fg-strong":t.getPropertyValue("--color-fg-strong"),"fg-weak":t.getPropertyValue("--color-fg-weak")}}const M="_diagram-common-stops",F="_diagram-branch-a-stops",W="_diagram-branch-b-stops";function ct(t){return n("div",{ref:t.contentParentRef,class:d(t.class,"grid grid-cols-[auto_auto_auto] grid-rows-[auto_auto] gap-y-8 gap-x-4"),children:[n(I,{class:"w-12 col-2 row-span-full",structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:t.contentParent}),n(f,{class:d("gap-6 col-3 row-1 -ml-4",M),xAlign:"left",children:t.structure.commonStops.map(e=>n(_,{children:e.content}))}),n(f,{class:d("gap-6 col-1 row-2",F),xAlign:"right",children:t.structure.branchAStops.map(e=>n(_,{children:e.content}))}),n(f,{class:d("gap-6 col-3 row-2",W),xAlign:"left",children:t.structure.branchBStops.map(e=>n(_,{children:e.content}))})]})}const $="_diagram-main-stops",V="_diagram-loop-left-stops",U="_diagram-loop-right-stops";function ht(t){return n("div",{ref:t.contentParentRef,class:d(t.class,"grid grid-cols-[auto_auto_auto] grid-rows-[auto_auto] gap-x-4"),children:[n(I,{class:"w-12 col-2 row-span-full",structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:t.contentParent}),n(f,{class:d("gap-6 col-1 row-1 py-4",V),xAlign:"right",yAlign:"center",children:t.structure.loopLeftStops.map(e=>n(_,{children:e.content}))}),n(f,{class:d("gap-6 col-3 row-1 py-4",U),xAlign:"left",yAlign:"center",children:t.structure.loopRightStops.map(e=>n(_,{children:e.content}))}),n(f,{class:d("gap-6 col-3 row-2 -ml-4",$,{"pt-4":t.structure.mainStops.length>0}),xAlign:"left",children:t.structure.mainStops.map(e=>n(_,{children:e.content}))})]})}const b=16,dt=6,p=6,C=10,T=15,H=24,L=1;class ut extends rt{_css;_prefersDark;constructor(e,o){super(e,o),this._css=lt(),this._prefersDark=window.matchMedia("(prefers-color-scheme: dark)").matches}onRender(){this.data.contentParent!=null&&(this.ctx.strokeStyle="#000000",this.data.structure.type==="linear"?this._renderLinear(this.data.structure,this.data.contentParent):this.data.structure.type==="branch"?this._renderBranch(this.data.structure,this.data.contentParent):this.data.structure.type==="loop"?this._renderLoop(this.data.structure,this.data.contentParent):R(this.data.structure),this.ctx.globalCompositeOperation="source-in",this.ctx.fillStyle=this._getDiagramColor(),this.ctx.fillRect(0,0,this.width,this.height))}_renderLinear(e,o){this._renderSection({stops:e.stops,x:this.width/2,yLevels:this._extractYLevels(e.stops,o),terminatesAtTop:!0,terminatesAtBottom:!0,notchSide:"right"})}_renderBranch(e,o){const i=this._extractYLevels(e.commonStops,o,M),s=this._extractYLevels(e.branchAStops,o,F),l=this._extractYLevels(e.branchBStops,o,W),r=this.width/2,a=b/2,c=this.width-b/2;this._renderSection({stops:e.commonStops,x:r,yLevels:i,terminatesAtTop:!0,terminatesAtBottom:!1,notchSide:"right"}),this._renderSection({stops:e.branchAStops,x:a,yLevels:s,terminatesAtTop:!1,terminatesAtBottom:!0,notchSide:"left"}),this._renderSection({stops:e.branchBStops,x:c,yLevels:l,terminatesAtTop:!1,terminatesAtBottom:!0,notchSide:"right"});const m=h(i[i.length-1]),S=h(s[0]),g=h(l[0]),u=Math.min(S,g);this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(r,m),this.ctx.lineTo(r,m+C),this.ctx.bezierCurveTo(r,m+T+C,a,u-T,a,u),this.ctx.lineTo(a,S),this.ctx.moveTo(r,m+C),this.ctx.bezierCurveTo(r,m+T+C,c,u-T,c,u),this.ctx.lineTo(c,g),this.ctx.stroke()}_renderLoop(e,o){const i=this._extractYLevels(e.loopLeftStops,o,V),s=this._extractYLevels(e.loopRightStops,o,U),l=this._extractYLevels(e.mainStops,o,$),r=b/2,a=this.width-b/2,c=this.width/2,m=i[i.length-1],S=s[s.length-1],g=h(m??S),u=h(S??m),k=i[0],z=s[0],E=h(k??z),O=h(z??k);e.loopLeftStops.length>0?this._renderSection({stops:e.loopLeftStops,x:r,yLevels:i,terminatesAtTop:!1,terminatesAtBottom:!1,notchSide:"left"}):(this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(r,E-L),this.ctx.lineTo(r,g+L),this.ctx.stroke()),e.loopRightStops.length>0?this._renderSection({stops:e.loopRightStops,x:a,yLevels:s,terminatesAtTop:!1,terminatesAtBottom:!1,notchSide:"right"}):(this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(a,O-L),this.ctx.lineTo(a,u+L),this.ctx.stroke());const x=Math.max(g,u);if(e.mainStops.length>0){const y=h(l[0]);this._renderSection({stops:e.mainStops,x:c,yLevels:l,terminatesAtTop:!1,terminatesAtBottom:!0,notchSide:"right"}),this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(c,y),this.ctx.lineTo(c,y-C),this.ctx.bezierCurveTo(c,y-T-C,r,x+T,r,x),this.ctx.lineTo(r,g),this.ctx.moveTo(c,y-C),this.ctx.bezierCurveTo(c,y-T-C,a,x+T,a,x),this.ctx.lineTo(a,u),this.ctx.stroke()}else this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(r,g),this.ctx.lineTo(r,x),this.ctx.bezierCurveTo(r,x+H,a,x+H,a,x),this.ctx.lineTo(a,u),this.ctx.stroke();const A=Math.min(E,O);this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(r,E),this.ctx.lineTo(r,A),this.ctx.bezierCurveTo(r,A-H,a,A-H,a,A),this.ctx.lineTo(a,O),this.ctx.stroke()}_renderSection({stops:e,x:o,yLevels:i,terminatesAtTop:s,terminatesAtBottom:l,notchSide:r}){if(e.length<1)throw new Error("Expecting at least one stop.");if(e.length!==i.length)throw new Error("Bad length.");const a=h(i[0]),c=h(i[i.length-1]);this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(o,a-L),this.ctx.lineTo(o,c+L),this.ctx.stroke();const m={left:-1,right:1}[r];e.forEach((S,g)=>{const u=h(i[g]),k=g===0&&s||g===e.length-1&&l;(S.drawMark??!0)&&(this.ctx.lineWidth=dt,this.ctx.beginPath(),this.ctx.moveTo(k?o-b/2*m:o,u),this.ctx.lineTo(o+b/2*m,u),this.ctx.stroke())})}_extractYLevels(e,o,i){const s=this._extractChildElements(o,i);if(e.length!==s.length)throw new Error("Bad length.");return e.map((l,r)=>{const a=h(s[r]);return l.getOverriddenMarkYPosition!=null?l.getOverriddenMarkYPosition(a):this._getDefaultMarkYPosition(a)})}_extractChildElements(e,o){const i=o==null?e:e.querySelector(`.${o}`);if(i==null)throw new Error(`Couldn't find "${o}".`);return Array.from(i.childNodes.values()).filter(s=>s instanceof HTMLElement)}_getDefaultMarkYPosition(e){const o=this._canvasContainer.getBoundingClientRect(),i=e.getBoundingClientRect();return i.top-o.top+i.height/2}_getDiagramColor(){const e={dark:"darkThemeColorHexCode",light:"lightThemeColorHexCode",auto:this._prefersDark?"darkThemeColorHexCode":"lightThemeColorHexCode"}[this.data.colorTheme];return this.data[e]??this._css.fg}}function I(t){const{settings:e}=G(),o=w(()=>({structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:t.contentParent,colorTheme:e.theme}),[t.darkThemeColorHexCode,t.contentParent,t.lightThemeColorHexCode,t.structure,e.theme]),i=j((s,l)=>new ut(s,l),[]);return n(at,{class:d(t.class),createController:i,data:o})}function mt(t){return n(_,{class:d(t.class,"grid-cols-[auto_1fr] gap-4"),children:[n(I,{class:"w-4",structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:t.contentParent}),n("div",{ref:t.contentParentRef,class:"flex flex-col gap-6",children:t.structure.stops.map(e=>n(_,{children:e.content}))})]})}function gt(t){const e=B(null),[o,i]=N(null);if(Y(()=>{i(e.current)},[]),t.structure.type==="linear")return n(mt,{class:t.class,structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:o,contentParentRef:e});if(t.structure.type==="branch")return n(ct,{class:t.class,structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:o,contentParentRef:e});if(t.structure.type==="loop")return n(ht,{class:t.class,structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:o,contentParentRef:e});R(t.structure)}function q(t){const{foda:e}=D(),o=w(()=>ft(e,t.diagram),[e,t.diagram]);return n(_,{class:d(t.class,"bg-bg-raised px-4 py-8 justify-center rounded-sm border border-soft-border"),children:n(gt,{structure:o,lightThemeColorHexCode:t.diagram.color?.lightModeHexCode??null,darkThemeColorHexCode:t.diagram.color?.darkModeHexCode??null})})}function ft(t,e){function o(i){return i.map(s=>_t(t,s.stopId,s.type))}if(e.type==="linear")return{type:"linear",stops:o(e.stops)};if(e.type==="branch")return{type:"branch",commonStops:o(e.commonStops),branchAStops:o(e.branchAStops),branchBStops:o(e.branchBStops)};if(e.type==="loop")return{type:"loop",loopLeftStops:o(e.loopLeftStops),loopRightStops:o(e.loopRightStops),mainStops:o(e.mainStops)};R(e)}function _t(t,e,o){const i=t.stops.require(e),s=`/stop/${i.urlPath}`;if(o==="regular")return{content:n(v,{style:"strong",children:n(P,{href:s,style:"subtle",children:i.name})})};if(o==="always-express")return{content:n(v,{style:"small-weak",children:n(P,{href:s,style:"subtle",children:["Skips ",i.name]})}),drawMark:!1};R(o)}const xt={linear:!0,branch:!0,loop:!0},Ct=Object.keys(xt);function Tt(t){const e=t.diagram.entries.filter(o=>Ct.includes(o.type));return e.length<t.diagram.entries.length?n(st,{fallbackStopList:t.diagram.fallbackStopList}):n(f,{class:d(t.class,"gap-6"),children:[n(v,{style:"subtitle",children:"Diagram"}),e.length===1?n(q,{diagram:h(e[0])}):n(St,{entries:e},e.length)]})}function St(t){const[e,o]=N(0),i=w(()=>t.entries.map((s,l)=>({value:l.toFixed(),label:s.name??`Route ${l+1}`})),[t.entries]);return n(f,{class:"gap-4",children:[n(ot,{class:"self-start",value:e.toFixed(),options:i,onChange:s=>{o(nt(s))}}),n(q,{diagram:h(t.entries[e])},e)]})}function Ht(){const{params:{id:t}}=Q(),{foda:e}=D(),o=w(()=>e.lines.getByUrlPath(t??""),[e.lines,t]);return o===null?n(tt,{afterConfirming:"foundational-data-version"}):n(pt,{line:o})}function pt(t){const{formatLine:e}=Z();return n(K,{...J({title:e(t.line.name)}),children:n(f,{class:"px-4 py-8 gap-8",children:t.line.diagram.entries.length>0&&n(Tt,{diagram:t.line.diagram})})})}export{Ht as default};
1
+ import{a as D,u as X,j as w,d as n,T as v,C as f,e as d,A as B,m as N,y as Y,G as _,n as h,k as G,q as j,l as Q,o as Z}from"./index-ggoGQEW6.js";import{P as K}from"./Page-DdURsQrw.js";import{u as J}from"./use-simple-headers-dzwgogJg.js";import{N as tt}from"./NotFoundPage-DGh2AlPH.js";import{L as P}from"./LinkText-hoDnNcKa.js";import{A as et}from"./Alert-CzjHVmGJ.js";import{P as ot}from"./Picker-DgCfICF8.js";function R(t){throw new Error(`Unexpected value: ${String(t)}`)}function nt(t){if(!/^-?[0-9]+$/g.test(t))throw it(t);return parseInt(t,10)}const it=t=>new Error(`"${t}" is not an integer.`);function st(t){const{foda:e}=D(),{appName:o}=X(),i=w(()=>t.fallbackStopList.map(s=>e.stops.require(s)).sort((s,l)=>s.name.localeCompare(l.name)),[e.stops,t.fallbackStopList]);return n(f,{class:d(t.class,"gap-6"),children:[n(v,{style:"subtitle",children:"Stops"}),n(et,{type:"info",children:n(f,{class:"gap-6",children:[n(v,{children:["A neat little diagram is also available for this line, but it's of a new type, and so requires a newer version of ",o," to be able to view."," "]}),n(v,{style:"strong",children:n(P,{href:"/debug",children:"Help me update"})})]})}),n("ul",{class:"flex-col flex list-disc list-inside gap-4",children:i.map(s=>n(v,{children:n("li",{children:n(P,{href:`/stop/${s.urlPath}`,children:s.name})})}))})]})}class rt{constructor(e,o){this._canvasContainer=e,this._canvas=o;const i=this._canvas.getContext("2d");if(i==null)throw new Error("Failed to get 2D rendering context.");this.ctx=i,this._resizeListener=this._onResize.bind(this),this._resizeObserver=new ResizeObserver(this._resizeListener),this._data=null,this._width=1,this._height=1,this._dpiRatio=1,this._dirty=!0,this._running=!1}_canvasContainer;_canvas;ctx;_resizeListener;_resizeObserver;_data;_width;_height;_dpiRatio;_dirty;_running;get data(){if(this._data==null)throw new Error("Data not set.");return this._data}get width(){return this._width}get height(){return this._height}setData(e){this._data=e,this.onDataUpdated(),this._dirty=!0,this._running||this._start()}_start(){this._fitCanvas(),this._running=!0,this._render(),window.addEventListener("resize",this._resizeListener),this._resizeObserver.observe(this._canvasContainer),this.onStart()}destroy(){this._running=!1,window.removeEventListener("resize",this._resizeListener),this._resizeObserver.unobserve(this._canvasContainer),this.onDestroy()}_render(){this._running&&(requestAnimationFrame(()=>{this._render()}),this._dirty&&(this._dirty=!1,this.ctx.save(),this.ctx.clearRect(0,0,this._width*this._dpiRatio,this._height*this._dpiRatio),this.ctx.scale(this._dpiRatio,this._dpiRatio),this.onRender(),this.ctx.restore()))}onStart(){}onDestroy(){}onDataUpdated(){}_onResize(){this._fitCanvas()}_fitCanvas(){const e=this._canvasContainer.getBoundingClientRect();this._width=e.width,this._height=e.height;const o=window.devicePixelRatio??1,i=this.ctx.backingStorePixelRatio??1;this._dpiRatio=o/i,this._canvas.style.width=`${this._width}px`,this._canvas.style.height=`${this._height}px`,this._canvas.width=this._width*this._dpiRatio,this._canvas.height=this._height*this._dpiRatio,this._dirty=!0}markDirty(){this._dirty=!0}}function at(t){const{data:e,createController:o}=t,i=B(null),s=B(null),[l,r]=N(null),a=t.interceptTouches??!1?{touchAction:"none"}:void 0;return Y(()=>{if(i.current==null||s.current==null)return;const c=o(i.current,s.current);return r(c),()=>{c?.destroy()}},[o]),Y(()=>{l?.setData(e)},[l,e]),n("div",{ref:i,className:d(t.class,"relative overflow-hidden"),children:n("canvas",{className:"absolute top-0 left-0",ref:s,style:a})})}function lt(){const t=window.getComputedStyle(document.body);return{bg:t.getPropertyValue("--color-bg"),fg:t.getPropertyValue("--color-fg"),"fg-strong":t.getPropertyValue("--color-fg-strong"),"fg-weak":t.getPropertyValue("--color-fg-weak")}}const M="_diagram-common-stops",F="_diagram-branch-a-stops",W="_diagram-branch-b-stops";function ct(t){return n("div",{ref:t.contentParentRef,class:d(t.class,"grid grid-cols-[auto_auto_auto] grid-rows-[auto_auto] gap-y-8 gap-x-4"),children:[n(I,{class:"w-12 col-2 row-span-full",structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:t.contentParent}),n(f,{class:d("gap-6 col-3 row-1 -ml-4",M),xAlign:"left",children:t.structure.commonStops.map(e=>n(_,{children:e.content}))}),n(f,{class:d("gap-6 col-1 row-2",F),xAlign:"right",children:t.structure.branchAStops.map(e=>n(_,{children:e.content}))}),n(f,{class:d("gap-6 col-3 row-2",W),xAlign:"left",children:t.structure.branchBStops.map(e=>n(_,{children:e.content}))})]})}const $="_diagram-main-stops",V="_diagram-loop-left-stops",U="_diagram-loop-right-stops";function ht(t){return n("div",{ref:t.contentParentRef,class:d(t.class,"grid grid-cols-[auto_auto_auto] grid-rows-[auto_auto] gap-x-4"),children:[n(I,{class:"w-12 col-2 row-span-full",structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:t.contentParent}),n(f,{class:d("gap-6 col-1 row-1 py-4",V),xAlign:"right",yAlign:"center",children:t.structure.loopLeftStops.map(e=>n(_,{children:e.content}))}),n(f,{class:d("gap-6 col-3 row-1 py-4",U),xAlign:"left",yAlign:"center",children:t.structure.loopRightStops.map(e=>n(_,{children:e.content}))}),n(f,{class:d("gap-6 col-3 row-2 -ml-4",$,{"pt-4":t.structure.mainStops.length>0}),xAlign:"left",children:t.structure.mainStops.map(e=>n(_,{children:e.content}))})]})}const b=16,dt=6,p=6,C=10,T=15,H=24,y=1;class ut extends rt{_css;_prefersDark;constructor(e,o){super(e,o),this._css=lt(),this._prefersDark=window.matchMedia("(prefers-color-scheme: dark)").matches}onRender(){this.data.contentParent!=null&&(this.ctx.strokeStyle="#000000",this.data.structure.type==="linear"?this._renderLinear(this.data.structure,this.data.contentParent):this.data.structure.type==="branch"?this._renderBranch(this.data.structure,this.data.contentParent):this.data.structure.type==="loop"?this._renderLoop(this.data.structure,this.data.contentParent):R(this.data.structure),this.ctx.globalCompositeOperation="source-in",this.ctx.fillStyle=this._getDiagramColor(),this.ctx.fillRect(0,0,this.width,this.height))}_renderLinear(e,o){this._renderSection({stops:e.stops,x:this.width/2,yLevels:this._extractYLevels(e.stops,o),terminatesAtTop:!0,terminatesAtBottom:!0,notchSide:"right"})}_renderBranch(e,o){const i=this._extractYLevels(e.commonStops,o,M),s=this._extractYLevels(e.branchAStops,o,F),l=this._extractYLevels(e.branchBStops,o,W),r=this.width/2,a=b/2,c=this.width-b/2;this._renderSection({stops:e.commonStops,x:r,yLevels:i,terminatesAtTop:!0,terminatesAtBottom:!1,notchSide:"right"}),this._renderSection({stops:e.branchAStops,x:a,yLevels:s,terminatesAtTop:!1,terminatesAtBottom:!0,notchSide:"left"}),this._renderSection({stops:e.branchBStops,x:c,yLevels:l,terminatesAtTop:!1,terminatesAtBottom:!0,notchSide:"right"});const m=h(i[i.length-1]),S=h(s[0]),g=h(l[0]),u=Math.min(S,g);this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(r,m),this.ctx.lineTo(r,m+C),this.ctx.bezierCurveTo(r,m+T+C,a,u-T,a,u),this.ctx.lineTo(a,S),this.ctx.moveTo(r,m+C),this.ctx.bezierCurveTo(r,m+T+C,c,u-T,c,u),this.ctx.lineTo(c,g),this.ctx.stroke()}_renderLoop(e,o){const i=this._extractYLevels(e.loopLeftStops,o,V),s=this._extractYLevels(e.loopRightStops,o,U),l=this._extractYLevels(e.mainStops,o,$),r=b/2,a=this.width-b/2,c=this.width/2,m=i[i.length-1],S=s[s.length-1],g=h(m??S),u=h(S??m),k=i[0],z=s[0],E=h(k??z),O=h(z??k);e.loopLeftStops.length>0?this._renderSection({stops:e.loopLeftStops,x:r,yLevels:i,terminatesAtTop:!1,terminatesAtBottom:!1,notchSide:"left"}):(this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(r,E-y),this.ctx.lineTo(r,g+y),this.ctx.stroke()),e.loopRightStops.length>0?this._renderSection({stops:e.loopRightStops,x:a,yLevels:s,terminatesAtTop:!1,terminatesAtBottom:!1,notchSide:"right"}):(this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(a,O-y),this.ctx.lineTo(a,u+y),this.ctx.stroke());const x=Math.max(g,u);if(e.mainStops.length>0){const L=h(l[0]);this._renderSection({stops:e.mainStops,x:c,yLevels:l,terminatesAtTop:!1,terminatesAtBottom:!0,notchSide:"right"}),this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(c,L),this.ctx.lineTo(c,L-C),this.ctx.bezierCurveTo(c,L-T-C,r,x+T,r,x),this.ctx.lineTo(r,g),this.ctx.moveTo(c,L-C),this.ctx.bezierCurveTo(c,L-T-C,a,x+T,a,x),this.ctx.lineTo(a,u),this.ctx.stroke()}else this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(r,g),this.ctx.lineTo(r,x),this.ctx.bezierCurveTo(r,x+H,a,x+H,a,x),this.ctx.lineTo(a,u),this.ctx.stroke();const A=Math.min(E,O);this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(r,E),this.ctx.lineTo(r,A),this.ctx.bezierCurveTo(r,A-H,a,A-H,a,A),this.ctx.lineTo(a,O),this.ctx.stroke()}_renderSection({stops:e,x:o,yLevels:i,terminatesAtTop:s,terminatesAtBottom:l,notchSide:r}){if(e.length<1)throw new Error("Expecting at least one stop.");if(e.length!==i.length)throw new Error("Bad length.");const a=h(i[0]),c=h(i[i.length-1]);this.ctx.lineWidth=p,this.ctx.beginPath(),this.ctx.moveTo(o,a-y),this.ctx.lineTo(o,c+y),this.ctx.stroke();const m={left:-1,right:1}[r];e.forEach((S,g)=>{const u=h(i[g]),k=g===0&&s||g===e.length-1&&l;(S.drawMark??!0)&&(this.ctx.lineWidth=dt,this.ctx.beginPath(),this.ctx.moveTo(k?o-b/2*m:o,u),this.ctx.lineTo(o+b/2*m,u),this.ctx.stroke())})}_extractYLevels(e,o,i){const s=this._extractChildElements(o,i);if(e.length!==s.length)throw new Error("Bad length.");return e.map((l,r)=>{const a=h(s[r]);return l.getOverriddenMarkYPosition!=null?l.getOverriddenMarkYPosition(a):this._getDefaultMarkYPosition(a)})}_extractChildElements(e,o){const i=o==null?e:e.querySelector(`.${o}`);if(i==null)throw new Error(`Couldn't find "${o}".`);return Array.from(i.childNodes.values()).filter(s=>s instanceof HTMLElement)}_getDefaultMarkYPosition(e){const o=this._canvasContainer.getBoundingClientRect(),i=e.getBoundingClientRect();return i.top-o.top+i.height/2}_getDiagramColor(){const e={dark:"darkThemeColorHexCode",light:"lightThemeColorHexCode",auto:this._prefersDark?"darkThemeColorHexCode":"lightThemeColorHexCode"}[this.data.colorTheme];return this.data[e]??this._css.fg}}function I(t){const{settings:e}=G(),o=w(()=>({structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:t.contentParent,colorTheme:e.theme}),[t.darkThemeColorHexCode,t.contentParent,t.lightThemeColorHexCode,t.structure,e.theme]),i=j((s,l)=>new ut(s,l),[]);return n(at,{class:d(t.class),createController:i,data:o})}function mt(t){return n(_,{class:d(t.class,"grid-cols-[auto_1fr] gap-4"),children:[n(I,{class:"w-4",structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:t.contentParent}),n("div",{ref:t.contentParentRef,class:"flex flex-col gap-6",children:t.structure.stops.map(e=>n(_,{children:e.content}))})]})}function gt(t){const e=B(null),[o,i]=N(null);if(Y(()=>{i(e.current)},[]),t.structure.type==="linear")return n(mt,{class:t.class,structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:o,contentParentRef:e});if(t.structure.type==="branch")return n(ct,{class:t.class,structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:o,contentParentRef:e});if(t.structure.type==="loop")return n(ht,{class:t.class,structure:t.structure,lightThemeColorHexCode:t.lightThemeColorHexCode,darkThemeColorHexCode:t.darkThemeColorHexCode,contentParent:o,contentParentRef:e});R(t.structure)}function q(t){const{foda:e}=D(),o=w(()=>ft(e,t.diagram),[e,t.diagram]);return n(_,{class:d(t.class,"bg-bg-raised px-4 py-8 justify-center rounded-sm border border-soft-border"),children:n(gt,{structure:o,lightThemeColorHexCode:t.diagram.color?.lightModeHexCode??null,darkThemeColorHexCode:t.diagram.color?.darkModeHexCode??null})})}function ft(t,e){function o(i){return i.map(s=>_t(t,s.stopId,s.type))}if(e.type==="linear")return{type:"linear",stops:o(e.stops)};if(e.type==="branch")return{type:"branch",commonStops:o(e.commonStops),branchAStops:o(e.branchAStops),branchBStops:o(e.branchBStops)};if(e.type==="loop")return{type:"loop",loopLeftStops:o(e.loopLeftStops),loopRightStops:o(e.loopRightStops),mainStops:o(e.mainStops)};R(e)}function _t(t,e,o){const i=t.stops.require(e),s=`/stop/${i.urlPath}`;if(o==="regular")return{content:n(v,{style:"strong",children:n(P,{href:s,style:"subtle",children:i.name})})};if(o==="always-express")return{content:n(v,{style:"small-weak",children:n(P,{href:s,style:"subtle",children:["Skips ",i.name]})}),drawMark:!1};R(o)}const xt={linear:!0,branch:!0,loop:!0},Ct=Object.keys(xt);function Tt(t){const e=t.diagram.entries.filter(o=>Ct.includes(o.type));return e.length<t.diagram.entries.length?n(st,{fallbackStopList:t.diagram.fallbackStopList}):n(f,{class:d(t.class,"gap-6"),children:[n(v,{style:"subtitle",children:"Diagram"}),e.length===1?n(q,{diagram:h(e[0])}):n(St,{entries:e},e.length)]})}function St(t){const[e,o]=N(0),i=w(()=>t.entries.map((s,l)=>({value:l.toFixed(),label:s.name??`Route ${l+1}`})),[t.entries]);return n(f,{class:"gap-4",children:[n(ot,{class:"self-start",value:e.toFixed(),options:i,onChange:s=>{o(nt(s))}}),n(q,{diagram:h(t.entries[e])},h(t.entries[e]).type)]})}function Ht(){const{params:{id:t}}=Q(),{foda:e}=D(),o=w(()=>e.lines.getByUrlPath(t??""),[e.lines,t]);return o===null?n(tt,{afterConfirming:"foundational-data-version"}):n(pt,{line:o})}function pt(t){const{formatLine:e}=Z();return n(K,{...J({title:e(t.line.name)}),children:n(f,{class:"px-4 py-8 gap-8",children:t.line.diagram.entries.length>0&&n(Tt,{diagram:t.line.diagram})})})}export{Ht as default};
@@ -1 +1 @@
1
- import{e as t,d as n}from"./index-jI1qL-AF.js";const i={default:"text-accent-text underline",subtle:"hover:underline"};function a(e){const c=i[e.style??"default"],l=t(c,"inline",e.class);return e.onClick!=null?n("span",{class:l,onClick:e.onClick,children:e.children}):e.href!=null?n("a",{class:l,href:e.href,children:e.children}):n("span",{class:l,children:e.children})}export{a as L};
1
+ import{e as t,d as n}from"./index-ggoGQEW6.js";const i={default:"text-accent-text underline",subtle:"hover:underline"};function a(e){const c=i[e.style??"default"],l=t(c,"inline",e.class);return e.onClick!=null?n("span",{class:l,onClick:e.onClick,children:e.children}):e.href!=null?n("a",{class:l,href:e.href,children:e.children}):n("span",{class:l,children:e.children})}export{a as L};
@@ -1,2 +1,2 @@
1
- import{d as i,S as u,e as d,T as a,j as h,C as k}from"./index-jI1qL-AF.js";import{L as p}from"./LinkText-CuzmudpX.js";import{S as x}from"./Strong-BND8QD53.js";const g=/\[([^[\]]+)\]\(([^()]+)\)/,w=/\*\*(.+?)\*\*/,T=/\*([^*]+)\*/,y=/_([^_]+)_/;function m(t,n){const l=[];let e=t;for(;e.length>0;){const r=b(e);if(r==null){l.push(e);break}r.index>0&&l.push(e.slice(0,r.index));const c=m(r.innerContent,n);l.push(r.wrap(i(u,{children:c}),n)),e=e.slice(r.index+r.fullMatch.length)}return l}function b(t){const n=[M(t),I(t),s(t,T),s(t,y)];let l=null;for(const e of n)e!=null&&(l==null||e.index<l.index)&&(l=e);return l}function M(t){const n=t.match(g);if(n==null||n.index==null||n[1]==null||n[2]==null)return null;const l=n[2];return!l.startsWith("https://")&&!l.startsWith("/")?null:{index:n.index,fullMatch:n[0],innerContent:n[1],wrap:(e,r)=>r.link(e,l)}}function I(t){const n=t.match(w);return n==null||n.index==null||n[1]==null?null:{index:n.index,fullMatch:n[0],innerContent:n[1],wrap:(l,e)=>e.bold(l)}}function s(t,n){const l=t.match(n);return l==null||l.index==null||l[1]==null?null:{index:l.index,fullMatch:l[0],innerContent:l[1],wrap:(e,r)=>r.italic(e)}}function C(t){return i("em",{class:d(t.class),children:t.children})}const o={bold:t=>i(x,{children:t}),italic:t=>i(C,{children:t}),link:(t,n)=>i(p,{href:n,children:t})},S={h1:{render:(t,n)=>i(a,{as:"h1",style:"title",children:t},n),marginTop:"mt-12"},h2:{render:(t,n)=>i(a,{as:"h2",style:"subtitle",children:t},n),marginTop:"mt-12"},h3:{render:(t,n)=>i(a,{as:"h3",style:"strong",children:t},n),marginTop:"mt-12"},p:{render:(t,n)=>i(a,{as:"p",children:t},n),marginTop:"mt-8"},bold:o.bold,italic:o.italic,link:o.link};function P(t){const n=t.style??o,l=h(()=>m(t.markdown,n),[t.markdown,n]);return i(u,{children:l})}function B(t){return t.split(`
1
+ import{d as i,S as u,e as d,T as a,j as h,C as k}from"./index-ggoGQEW6.js";import{L as p}from"./LinkText-hoDnNcKa.js";import{S as x}from"./Strong-B3a6utE4.js";const g=/\[([^[\]]+)\]\(([^()]+)\)/,w=/\*\*(.+?)\*\*/,T=/\*([^*]+)\*/,y=/_([^_]+)_/;function m(t,n){const l=[];let e=t;for(;e.length>0;){const r=b(e);if(r==null){l.push(e);break}r.index>0&&l.push(e.slice(0,r.index));const c=m(r.innerContent,n);l.push(r.wrap(i(u,{children:c}),n)),e=e.slice(r.index+r.fullMatch.length)}return l}function b(t){const n=[M(t),I(t),s(t,T),s(t,y)];let l=null;for(const e of n)e!=null&&(l==null||e.index<l.index)&&(l=e);return l}function M(t){const n=t.match(g);if(n==null||n.index==null||n[1]==null||n[2]==null)return null;const l=n[2];return!l.startsWith("https://")&&!l.startsWith("/")?null:{index:n.index,fullMatch:n[0],innerContent:n[1],wrap:(e,r)=>r.link(e,l)}}function I(t){const n=t.match(w);return n==null||n.index==null||n[1]==null?null:{index:n.index,fullMatch:n[0],innerContent:n[1],wrap:(l,e)=>e.bold(l)}}function s(t,n){const l=t.match(n);return l==null||l.index==null||l[1]==null?null:{index:l.index,fullMatch:l[0],innerContent:l[1],wrap:(e,r)=>r.italic(e)}}function C(t){return i("em",{class:d(t.class),children:t.children})}const o={bold:t=>i(x,{children:t}),italic:t=>i(C,{children:t}),link:(t,n)=>i(p,{href:n,children:t})},S={h1:{render:(t,n)=>i(a,{as:"h1",style:"title",children:t},n),marginTop:"mt-12"},h2:{render:(t,n)=>i(a,{as:"h2",style:"subtitle",children:t},n),marginTop:"mt-12"},h3:{render:(t,n)=>i(a,{as:"h3",style:"strong",children:t},n),marginTop:"mt-12"},p:{render:(t,n)=>i(a,{as:"p",children:t},n),marginTop:"mt-8"},bold:o.bold,italic:o.italic,link:o.link};function P(t){const n=t.style??o,l=h(()=>m(t.markdown,n),[t.markdown,n]);return i(u,{children:l})}function B(t){return t.split(`
2
2
  `).map(n=>n.replace(/[\r\t]/g,"").trim()).filter(n=>n.length>0).map(n=>{const l=n.match(/^### (.+)$/);if(l!=null&&l[1]!=null)return{kind:"h3",content:l[1]};const e=n.match(/^## (.+)$/);if(e!=null&&e[1]!=null)return{kind:"h2",content:e[1]};const r=n.match(/^# (.+)$/);return r!=null&&r[1]!=null?{kind:"h1",content:r[1]}:{kind:"p",content:n}})}function W(t){const n=t.style??S,l=h(()=>B(t.markdown).map((e,r)=>{const c=n[e.kind],f=r===0?"":c.marginTop;return i("div",{class:f,children:c.render(i(P,{style:n,markdown:e.content}),r)},r)}),[t.markdown,n]);return i(k,{class:d(t.class),children:l})}export{P as I,W as M};
@@ -0,0 +1 @@
1
+ import{d as e,C as r,T as a}from"./index-ggoGQEW6.js";import{P as l}from"./Page-DdURsQrw.js";function n(){return e(l,{mobileHeader:null,desktopHeader:null,children:e(r,{class:"px-4 py-8 gap-8",children:e(a,{children:"Idk"})})})}export{n as default};
@@ -0,0 +1 @@
1
+ import{d as o}from"./index-ggoGQEW6.js";import{N as r}from"./NotFoundPage-DGh2AlPH.js";import"./Page-DdURsQrw.js";function f(){return o(r,{afterConfirming:"frontend-version"})}export{f as default};
@@ -1 +1 @@
1
- import{h as F,u as H,f as A,a as D,b,i as k,m as P,y as g,s as B,F as L,d as n,C as p,L as S,T as m,B as T,v as E,w as I}from"./index-jI1qL-AF.js";import{P as y}from"./Page-BISwM3fy.js";function R({afterConfirming:i}){const{isHotReloadingEnabled:v}=F(),{frontendVersion:w}=H(),{unregister:r}=A(),{foda:e,updateFoda:l}=D(),{callApi:d}=I(),{data:a,loading:t,error:u}=b(k,{}),[x,c]=P(!1),o=i==="frontend-version"&&!v&&!t&&u==null&&a!=null&&a.frontendVersion!==w,f=i==="foundational-data-version"&&!t&&u==null&&a!=null&&a.foundationalDataHash!==e.hash;return g(()=>{if(!o)return;async function s(){await r(),window.location.reload()}s()},[o,r]),g(()=>{if(!f)return;async function s(){c(!0);try{const h=await d(B,{hash:e.hash});h.result==="outdated"&&l(new L(h.foundationalData))}catch{}finally{c(!1)}}s()},[f,d,e.hash,l]),t||o||x?n(y,{mobileHeader:null,desktopHeader:null,children:n(p,{xAlign:"center",yAlign:"center",children:n(S,{})})}):n(y,{mobileHeader:null,desktopHeader:null,children:n(p,{class:"px-4 py-8 gap-8",xAlign:"center",yAlign:"center",children:[n(m,{style:"title",align:"center",children:"Page not found"}),n(m,{align:"center",children:"This page doesn't exist, at least not anymore!"}),n(T,{href:"/",text:"Go home",icon:E})]})})}export{R as N};
1
+ import{h as F,u as H,f as A,a as D,b,i as k,m as P,y as g,s as B,F as L,d as n,C as p,L as S,T as m,B as T,v as E,w as I}from"./index-ggoGQEW6.js";import{P as y}from"./Page-DdURsQrw.js";function R({afterConfirming:i}){const{isHotReloadingEnabled:v}=F(),{frontendVersion:w}=H(),{unregister:r}=A(),{foda:e,updateFoda:l}=D(),{callApi:d}=I(),{data:a,loading:t,error:u}=b(k,{}),[x,c]=P(!1),o=i==="frontend-version"&&!v&&!t&&u==null&&a!=null&&a.frontendVersion!==w,f=i==="foundational-data-version"&&!t&&u==null&&a!=null&&a.foundationalDataHash!==e.hash;return g(()=>{if(!o)return;async function s(){await r(),window.location.reload()}s()},[o,r]),g(()=>{if(!f)return;async function s(){c(!0);try{const h=await d(B,{hash:e.hash});h.result==="outdated"&&l(new L(h.foundationalData))}catch{}finally{c(!1)}}s()},[f,d,e.hash,l]),t||o||x?n(y,{mobileHeader:null,desktopHeader:null,children:n(p,{xAlign:"center",yAlign:"center",children:n(S,{})})}):n(y,{mobileHeader:null,desktopHeader:null,children:n(p,{class:"px-4 py-8 gap-8",xAlign:"center",yAlign:"center",children:[n(m,{style:"title",align:"center",children:"Page not found"}),n(m,{align:"center",children:"This page doesn't exist, at least not anymore!"}),n(T,{href:"/",text:"Go home",icon:E})]})})}export{R as N};
@@ -1 +1 @@
1
- import{d,e as r,G as n,z as a,P as i}from"./index-jI1qL-AF.js";function s(e){return d(n,{class:r(e.class,"not-desktop:hidden"),children:e.children})}function c(e){return d(n,{class:r(e.class,"fixed top-0 left-0 right-0 bg-bg-navbar border-b border-soft-border desktop:hidden"),children:e.children})}function h(e){const{showMobileNav:l}=a(),t=e.centered??!0;return d(n,{class:r("bg-bg min-h-svh relative",{"pt-14":e.mobileHeader!=null,"not-desktop:pb-18":l,"desktop:grid-rows-[auto_1fr]":e.desktopHeader!=null},"desktop:pt-12"),children:[e.desktopHeader!=null&&d(s,{children:e.desktopHeader}),e.mobileHeader!=null&&d(c,{class:"h-14 z-1",children:e.mobileHeader}),d(n,{class:"z-0",children:t?d(i,{children:e.children}):e.children})]})}export{h as P};
1
+ import{d,e as r,G as n,z as a,P as i}from"./index-ggoGQEW6.js";function s(e){return d(n,{class:r(e.class,"not-desktop:hidden"),children:e.children})}function c(e){return d(n,{class:r(e.class,"fixed top-0 left-0 right-0 bg-bg-navbar border-b border-soft-border desktop:hidden"),children:e.children})}function h(e){const{showMobileNav:l}=a(),t=e.centered??!0;return d(n,{class:r("bg-bg min-h-svh relative",{"pt-14":e.mobileHeader!=null,"not-desktop:pb-18":l,"desktop:grid-rows-[auto_1fr]":e.desktopHeader!=null},"desktop:pt-12"),children:[e.desktopHeader!=null&&d(s,{children:e.desktopHeader}),e.mobileHeader!=null&&d(c,{class:"h-14 z-1",children:e.mobileHeader}),d(n,{class:"z-0",children:t?d(i,{children:e.children}):e.children})]})}export{h as P};
@@ -1 +1 @@
1
- import{d as c,e as a,R as t,T as o,r}from"./index-jI1qL-AF.js";const s=["bg-transparent","group-hover:bg-soft-hover","group-active:bg-soft-active"],i=["bg-accent","group-hover:bg-accent-hover","group-active:bg-accent-active"],v=["[--color-fg:var(--color-on-accent)]","[--color-fg-strong:var(--color-on-accent)]","[--color-fg-weak:var(--color-on-accent)]"],g=a(s),u=a(i),d=a(v);function k(e){return c(t,{class:a(e.class,"overflow-hidden rounded-sm border border-accent max-w-full"),children:e.options.map((n,l)=>c(b,{class:"shrink",label:n.label,active:n.value===e.value,last:l===e.options.length-1,onClick:()=>e.onChange(n.value)},n.value))})}function b(e){return c(r,{class:a(e.class,"relative group min-h-8",{[d]:e.active,"border-r border-accent":!e.last}),onClick:e.onClick,children:[c("div",{class:a("absolute z-0 top-0 bottom-0 left-0 right-0",{[g]:!e.active,[u]:e.active})}),c(t,{class:"relative z-1 px-6 py-2 min-w-0",xAlign:"center",yAlign:"center",children:c(o,{class:"shrink min-w-min",align:"center",children:e.label})})]})}export{k as P};
1
+ import{d as c,e as a,R as t,T as o,r}from"./index-ggoGQEW6.js";const s=["bg-transparent","group-hover:bg-soft-hover","group-active:bg-soft-active"],i=["bg-accent","group-hover:bg-accent-hover","group-active:bg-accent-active"],v=["[--color-fg:var(--color-on-accent)]","[--color-fg-strong:var(--color-on-accent)]","[--color-fg-weak:var(--color-on-accent)]"],g=a(s),u=a(i),d=a(v);function k(e){return c(t,{class:a(e.class,"overflow-hidden rounded-sm border border-accent max-w-full"),children:e.options.map((n,l)=>c(b,{class:"shrink",label:n.label,active:n.value===e.value,last:l===e.options.length-1,onClick:()=>e.onChange(n.value)},n.value))})}function b(e){return c(r,{class:a(e.class,"relative group min-h-8",{[d]:e.active,"border-r border-accent":!e.last}),onClick:e.onClick,children:[c("div",{class:a("absolute z-0 top-0 bottom-0 left-0 right-0",{[g]:!e.active,[u]:e.active})}),c(t,{class:"relative z-1 px-6 py-2 min-w-0",xAlign:"center",yAlign:"center",children:c(o,{class:"shrink min-w-min",align:"center",children:e.label})})]})}export{k as P};
@@ -1 +1 @@
1
- import{d as l,e as a}from"./index-jI1qL-AF.js";function s(e){return l("div",{class:a(e.class,"bg-placeholder animate-placeholder-pulse")})}function r(e){return l(s,{...e,class:a(e.class,"h-[1em] -my-[0.13em]")})}export{r as T};
1
+ import{d as l,e as a}from"./index-ggoGQEW6.js";function s(e){return l("div",{class:a(e.class,"bg-placeholder animate-placeholder-pulse")})}function r(e){return l(s,{...e,class:a(e.class,"h-[1em] -my-[0.13em]")})}export{r as T};
@@ -1 +1 @@
1
- import{k as n,d as e,t as c,C as o,T as t}from"./index-jI1qL-AF.js";import{P as m}from"./Picker-CNeXxMsu.js";import{P as u}from"./Page-BISwM3fy.js";import{u as h}from"./use-simple-headers-CqMikxZC.js";import{D as d}from"./Divider-BcodRRFp.js";const g={auto:"Auto",light:"Light",dark:"Dark"},p=c.map(s=>({value:s,label:g[s]}));function f(s){const{settings:r,updateSettings:a}=n();return e(m,{class:s.class,value:r.theme,options:p,onChange:i=>{a(l=>l.with({theme:i}))}})}function P(){return e(u,{...h({title:"Settings"}),children:e(o,{class:"px-4 py-8 gap-8",children:[e(o,{class:"gap-6",children:[e(t,{style:"strong",children:"Theme"}),e(t,{children:`"Auto" means the colour theme should follow your device's/browser's settings.`}),e(f,{class:"self-start"})]}),e(d,{}),e(t,{style:"small-weak",children:"(Settings are saved to your device's/browser's local storage.)"})]})})}export{P as default};
1
+ import{k as n,d as e,t as c,C as o,T as t}from"./index-ggoGQEW6.js";import{P as m}from"./Picker-DgCfICF8.js";import{P as u}from"./Page-DdURsQrw.js";import{u as h}from"./use-simple-headers-dzwgogJg.js";import{D as d}from"./Divider-2CyojEuM.js";const g={auto:"Auto",light:"Light",dark:"Dark"},p=c.map(s=>({value:s,label:g[s]}));function f(s){const{settings:r,updateSettings:a}=n();return e(m,{class:s.class,value:r.theme,options:p,onChange:i=>{a(l=>l.with({theme:i}))}})}function P(){return e(u,{...h({title:"Settings"}),children:e(o,{class:"px-4 py-8 gap-8",children:[e(o,{class:"gap-6",children:[e(t,{style:"strong",children:"Theme"}),e(t,{children:`"Auto" means the colour theme should follow your device's/browser's settings.`}),e(f,{class:"self-start"})]}),e(d,{}),e(t,{style:"small-weak",children:"(Settings are saved to your device's/browser's local storage.)"})]})})}export{P as default};
@@ -0,0 +1 @@
1
+ import{d as t,C as a,T as e}from"./index-ggoGQEW6.js";import{P as r}from"./Page-DdURsQrw.js";import{u as s}from"./use-simple-headers-dzwgogJg.js";function u(){return t(r,{...s({title:"Status"}),children:t(a,{class:"px-4 py-8 gap-8",children:t(e,{children:"LGTM"})})})}export{u as default};
@@ -1 +1 @@
1
- import{l as u,a as r,j as l,d as o,C as c,T as f}from"./index-jI1qL-AF.js";import{P as p}from"./Page-BISwM3fy.js";import{u as d}from"./use-simple-headers-CqMikxZC.js";import{N as m}from"./NotFoundPage-CjreacId.js";function g(n,e,t,a){if(n.length===0)return"";if(n.length===1)return n[0];if(n.length===2)return`${n[0]}${a}${n[1]}`;const s=n.slice(0,-1).join(e),i=n[n.length-1];return`${s}${t}${i}`}function h(n){return g(n,", ",", and "," and ")}function y(){const{params:{id:n}}=u(),{foda:e}=r(),t=l(()=>e.stops.getByUrlPath(n??""),[e.stops,n]);return t===null?o(m,{afterConfirming:"foundational-data-version"}):o(S,{stop:t})}function S(n){const{foda:e}=r();return o(p,{...d({title:n.stop.name}),children:o(c,{class:"px-4 py-8 gap-8",children:o(f,{children:[h(n.stop.canonicalLinesServingStop.map(t=>e.lines.require(t).name).sort((t,a)=>t.localeCompare(a)))," ",n.stop.canonicalLinesServingStop.length===1?"Line":"lines"]})})})}export{y as default};
1
+ import{l as u,a as r,j as l,d as o,C as c,T as f}from"./index-ggoGQEW6.js";import{P as p}from"./Page-DdURsQrw.js";import{u as d}from"./use-simple-headers-dzwgogJg.js";import{N as m}from"./NotFoundPage-DGh2AlPH.js";function g(n,e,t,a){if(n.length===0)return"";if(n.length===1)return n[0];if(n.length===2)return`${n[0]}${a}${n[1]}`;const s=n.slice(0,-1).join(e),i=n[n.length-1];return`${s}${t}${i}`}function h(n){return g(n,", ",", and "," and ")}function y(){const{params:{id:n}}=u(),{foda:e}=r(),t=l(()=>e.stops.getByUrlPath(n??""),[e.stops,n]);return t===null?o(m,{afterConfirming:"foundational-data-version"}):o(S,{stop:t})}function S(n){const{foda:e}=r();return o(p,{...d({title:n.stop.name}),children:o(c,{class:"px-4 py-8 gap-8",children:o(f,{children:[h(n.stop.canonicalLinesServingStop.map(t=>e.lines.require(t).name).sort((t,a)=>t.localeCompare(a)))," ",n.stop.canonicalLinesServingStop.length===1?"Line":"lines"]})})})}export{y as default};
@@ -1 +1 @@
1
- import{d as s,e as t}from"./index-jI1qL-AF.js";function c(r){return s("strong",{class:t(r.class,"text-fg-strong"),children:r.children})}export{c as S};
1
+ import{d as s,e as t}from"./index-ggoGQEW6.js";function c(r){return s("strong",{class:t(r.class,"text-fg-strong"),children:r.children})}export{c as S};
@@ -0,0 +1 @@
1
+ import{d as e,C as o,T as n}from"./index-ggoGQEW6.js";import{P as a}from"./Page-DdURsQrw.js";import{u as i}from"./use-simple-headers-dzwgogJg.js";import{S as r}from"./Strong-B3a6utE4.js";function d(){return e(a,{...i({title:"Zen mode"}),children:e(o,{class:"px-4 py-8 gap-8",children:e(n,{children:[e(r,{children:"✨"})," Zen! ",e(r,{children:"✨"})]})})})}export{d as default};