@screenreader-speech-capture/bridge 0.0.0-stage → 0.0.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 (328) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +46 -2
  3. package/dist/cli.mjs +6291 -0
  4. package/dist/ui/adapter-node.js +11 -0
  5. package/dist/ui/client/ui/_app/immutable/assets/0.ONZWQgDA.css +1 -0
  6. package/dist/ui/client/ui/_app/immutable/assets/0.ONZWQgDA.css.br +0 -0
  7. package/dist/ui/client/ui/_app/immutable/assets/0.ONZWQgDA.css.gz +0 -0
  8. package/dist/ui/client/ui/_app/immutable/assets/2.DSVNnDlO.css +1 -0
  9. package/dist/ui/client/ui/_app/immutable/assets/2.DSVNnDlO.css.br +3 -0
  10. package/dist/ui/client/ui/_app/immutable/assets/2.DSVNnDlO.css.gz +0 -0
  11. package/dist/ui/client/ui/_app/immutable/assets/3.WduKm4aT.css +1 -0
  12. package/dist/ui/client/ui/_app/immutable/assets/3.WduKm4aT.css.br +0 -0
  13. package/dist/ui/client/ui/_app/immutable/assets/3.WduKm4aT.css.gz +0 -0
  14. package/dist/ui/client/ui/_app/immutable/assets/4.DyY1vjRV.css +1 -0
  15. package/dist/ui/client/ui/_app/immutable/assets/4.DyY1vjRV.css.br +0 -0
  16. package/dist/ui/client/ui/_app/immutable/assets/4.DyY1vjRV.css.gz +0 -0
  17. package/dist/ui/client/ui/_app/immutable/assets/5.YyxFzHED.css +1 -0
  18. package/dist/ui/client/ui/_app/immutable/assets/5.YyxFzHED.css.br +0 -0
  19. package/dist/ui/client/ui/_app/immutable/assets/5.YyxFzHED.css.gz +0 -0
  20. package/dist/ui/client/ui/_app/immutable/assets/6.C0Nhvs_m.css +1 -0
  21. package/dist/ui/client/ui/_app/immutable/assets/6.C0Nhvs_m.css.br +0 -0
  22. package/dist/ui/client/ui/_app/immutable/assets/6.C0Nhvs_m.css.gz +0 -0
  23. package/dist/ui/client/ui/_app/immutable/assets/ExternalLink.CYXazpKA.css +1 -0
  24. package/dist/ui/client/ui/_app/immutable/assets/ExternalLink.CYXazpKA.css.br +0 -0
  25. package/dist/ui/client/ui/_app/immutable/assets/ExternalLink.CYXazpKA.css.gz +0 -0
  26. package/dist/ui/client/ui/_app/immutable/assets/Pane.Dgdg5KMw.css +1 -0
  27. package/dist/ui/client/ui/_app/immutable/assets/Pane.Dgdg5KMw.css.br +0 -0
  28. package/dist/ui/client/ui/_app/immutable/assets/Pane.Dgdg5KMw.css.gz +0 -0
  29. package/dist/ui/client/ui/_app/immutable/assets/material-symbols-outlined-latin-400-normal.BhEvR8fk.woff2 +0 -0
  30. package/dist/ui/client/ui/_app/immutable/assets/roboto-flex-cyrillic-ext-opsz-normal.nDQikIyu.woff2 +0 -0
  31. package/dist/ui/client/ui/_app/immutable/assets/roboto-flex-cyrillic-opsz-normal.SjuC5rw5.woff2 +0 -0
  32. package/dist/ui/client/ui/_app/immutable/assets/roboto-flex-greek-opsz-normal.C14fFRny.woff2 +0 -0
  33. package/dist/ui/client/ui/_app/immutable/assets/roboto-flex-latin-ext-opsz-normal.xNclTVCo.woff2 +0 -0
  34. package/dist/ui/client/ui/_app/immutable/assets/roboto-flex-latin-opsz-normal.hy8fyBBC.woff2 +0 -0
  35. package/dist/ui/client/ui/_app/immutable/assets/roboto-flex-vietnamese-opsz-normal.C-H_yGOU.woff2 +0 -0
  36. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-cyrillic-400-normal.B3hIXASd.woff +0 -0
  37. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-cyrillic-400-normal.C-_K-ZCn.woff2 +0 -0
  38. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-cyrillic-500-normal.DGZ7-lUP.woff2 +0 -0
  39. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-cyrillic-500-normal.NpUJFYX7.woff +0 -0
  40. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-cyrillic-ext-400-normal.BHxv52bw.woff2 +0 -0
  41. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-cyrillic-ext-400-normal.W26xs1TL.woff +0 -0
  42. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-cyrillic-ext-500-normal.6xdwlG7p.woff +0 -0
  43. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-cyrillic-ext-500-normal.DC57U9n8.woff2 +0 -0
  44. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-greek-400-normal.CH_u3Aru.woff2 +0 -0
  45. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-greek-400-normal.P8xe1gs1.woff +0 -0
  46. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-greek-500-normal.C2M8jX6G.woff +0 -0
  47. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-greek-500-normal.DpRFkptA.woff2 +0 -0
  48. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-latin-400-normal.DBZPkcnn.woff +0 -0
  49. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-latin-400-normal.GekRknry.woff2 +0 -0
  50. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-latin-500-normal.D6j6AMzd.woff +0 -0
  51. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-latin-500-normal.pxIOXZmA.woff2 +0 -0
  52. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-latin-ext-400-normal.BwLXVYNz.woff +0 -0
  53. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-latin-ext-400-normal.DLAV9S_w.woff2 +0 -0
  54. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-latin-ext-500-normal.B1IjfbhL.woff +0 -0
  55. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-latin-ext-500-normal.Db3ge6Oe.woff2 +0 -0
  56. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-vietnamese-400-normal.CzWHQABp.woff +0 -0
  57. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-vietnamese-400-normal.yYTFiTTs.woff2 +0 -0
  58. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-vietnamese-500-normal.Cq-quQMu.woff2 +0 -0
  59. package/dist/ui/client/ui/_app/immutable/assets/roboto-mono-vietnamese-500-normal.IxzxMIj7.woff +0 -0
  60. package/dist/ui/client/ui/_app/immutable/chunks/0FroJ-XN.js +3 -0
  61. package/dist/ui/client/ui/_app/immutable/chunks/0FroJ-XN.js.br +0 -0
  62. package/dist/ui/client/ui/_app/immutable/chunks/0FroJ-XN.js.gz +0 -0
  63. package/dist/ui/client/ui/_app/immutable/chunks/4wvZDMeR.js +33 -0
  64. package/dist/ui/client/ui/_app/immutable/chunks/4wvZDMeR.js.br +0 -0
  65. package/dist/ui/client/ui/_app/immutable/chunks/4wvZDMeR.js.gz +0 -0
  66. package/dist/ui/client/ui/_app/immutable/chunks/B1Ryegye.js +3 -0
  67. package/dist/ui/client/ui/_app/immutable/chunks/B1Ryegye.js.br +0 -0
  68. package/dist/ui/client/ui/_app/immutable/chunks/B1Ryegye.js.gz +0 -0
  69. package/dist/ui/client/ui/_app/immutable/chunks/B1vArRqi.js +3 -0
  70. package/dist/ui/client/ui/_app/immutable/chunks/B1vArRqi.js.br +0 -0
  71. package/dist/ui/client/ui/_app/immutable/chunks/B1vArRqi.js.gz +0 -0
  72. package/dist/ui/client/ui/_app/immutable/chunks/BS7n1gMj.js +40 -0
  73. package/dist/ui/client/ui/_app/immutable/chunks/BS7n1gMj.js.br +0 -0
  74. package/dist/ui/client/ui/_app/immutable/chunks/BS7n1gMj.js.gz +0 -0
  75. package/dist/ui/client/ui/_app/immutable/chunks/B_ZElYu_.js +1 -0
  76. package/dist/ui/client/ui/_app/immutable/chunks/B_ZElYu_.js.br +2 -0
  77. package/dist/ui/client/ui/_app/immutable/chunks/B_ZElYu_.js.gz +0 -0
  78. package/dist/ui/client/ui/_app/immutable/chunks/Beqi9dRN.js +72 -0
  79. package/dist/ui/client/ui/_app/immutable/chunks/Beqi9dRN.js.br +0 -0
  80. package/dist/ui/client/ui/_app/immutable/chunks/Beqi9dRN.js.gz +0 -0
  81. package/dist/ui/client/ui/_app/immutable/chunks/BnU72Mow.js +2 -0
  82. package/dist/ui/client/ui/_app/immutable/chunks/BnU72Mow.js.br +0 -0
  83. package/dist/ui/client/ui/_app/immutable/chunks/BnU72Mow.js.gz +0 -0
  84. package/dist/ui/client/ui/_app/immutable/chunks/Bvlvl8SZ.js +1 -0
  85. package/dist/ui/client/ui/_app/immutable/chunks/Bvlvl8SZ.js.br +0 -0
  86. package/dist/ui/client/ui/_app/immutable/chunks/Bvlvl8SZ.js.gz +0 -0
  87. package/dist/ui/client/ui/_app/immutable/chunks/CK3uUd4t.js +48 -0
  88. package/dist/ui/client/ui/_app/immutable/chunks/CK3uUd4t.js.br +0 -0
  89. package/dist/ui/client/ui/_app/immutable/chunks/CK3uUd4t.js.gz +0 -0
  90. package/dist/ui/client/ui/_app/immutable/chunks/CMWEX9XL.js +138 -0
  91. package/dist/ui/client/ui/_app/immutable/chunks/CMWEX9XL.js.br +0 -0
  92. package/dist/ui/client/ui/_app/immutable/chunks/CMWEX9XL.js.gz +0 -0
  93. package/dist/ui/client/ui/_app/immutable/chunks/CVpgcnu3.js +1 -0
  94. package/dist/ui/client/ui/_app/immutable/chunks/CVpgcnu3.js.br +0 -0
  95. package/dist/ui/client/ui/_app/immutable/chunks/CVpgcnu3.js.gz +0 -0
  96. package/dist/ui/client/ui/_app/immutable/chunks/D-2Nx62w.js +1 -0
  97. package/dist/ui/client/ui/_app/immutable/chunks/D-2Nx62w.js.br +4 -0
  98. package/dist/ui/client/ui/_app/immutable/chunks/D-2Nx62w.js.gz +0 -0
  99. package/dist/ui/client/ui/_app/immutable/chunks/D0famktY.js +1 -0
  100. package/dist/ui/client/ui/_app/immutable/chunks/D0famktY.js.br +2 -0
  101. package/dist/ui/client/ui/_app/immutable/chunks/D0famktY.js.gz +0 -0
  102. package/dist/ui/client/ui/_app/immutable/chunks/DHsTyp2W.js +1 -0
  103. package/dist/ui/client/ui/_app/immutable/chunks/DHsTyp2W.js.br +2 -0
  104. package/dist/ui/client/ui/_app/immutable/chunks/DHsTyp2W.js.gz +0 -0
  105. package/dist/ui/client/ui/_app/immutable/chunks/DOY87jO2.js +1 -0
  106. package/dist/ui/client/ui/_app/immutable/chunks/DOY87jO2.js.br +0 -0
  107. package/dist/ui/client/ui/_app/immutable/chunks/DOY87jO2.js.gz +0 -0
  108. package/dist/ui/client/ui/_app/immutable/chunks/DUTjbZNf.js +1 -0
  109. package/dist/ui/client/ui/_app/immutable/chunks/DUTjbZNf.js.br +0 -0
  110. package/dist/ui/client/ui/_app/immutable/chunks/DUTjbZNf.js.gz +0 -0
  111. package/dist/ui/client/ui/_app/immutable/chunks/Dvxhfd7j.js +3 -0
  112. package/dist/ui/client/ui/_app/immutable/chunks/Dvxhfd7j.js.br +0 -0
  113. package/dist/ui/client/ui/_app/immutable/chunks/Dvxhfd7j.js.gz +0 -0
  114. package/dist/ui/client/ui/_app/immutable/chunks/DzInmTUe.js +1 -0
  115. package/dist/ui/client/ui/_app/immutable/chunks/DzInmTUe.js.br +1 -0
  116. package/dist/ui/client/ui/_app/immutable/chunks/DzInmTUe.js.gz +0 -0
  117. package/dist/ui/client/ui/_app/immutable/chunks/tKonUL5Y.js +4 -0
  118. package/dist/ui/client/ui/_app/immutable/chunks/tKonUL5Y.js.br +0 -0
  119. package/dist/ui/client/ui/_app/immutable/chunks/tKonUL5Y.js.gz +0 -0
  120. package/dist/ui/client/ui/_app/immutable/entry/app.C8tsut3X.js +2 -0
  121. package/dist/ui/client/ui/_app/immutable/entry/app.C8tsut3X.js.br +0 -0
  122. package/dist/ui/client/ui/_app/immutable/entry/app.C8tsut3X.js.gz +0 -0
  123. package/dist/ui/client/ui/_app/immutable/entry/payload.DSmR2FwN.js +1 -0
  124. package/dist/ui/client/ui/_app/immutable/entry/payload.DSmR2FwN.js.br +0 -0
  125. package/dist/ui/client/ui/_app/immutable/entry/payload.DSmR2FwN.js.gz +0 -0
  126. package/dist/ui/client/ui/_app/immutable/entry/start.DqIv9xYX.js +2 -0
  127. package/dist/ui/client/ui/_app/immutable/entry/start.DqIv9xYX.js.br +0 -0
  128. package/dist/ui/client/ui/_app/immutable/entry/start.DqIv9xYX.js.gz +0 -0
  129. package/dist/ui/client/ui/_app/immutable/nodes/0.3bVKqGbx.js +1 -0
  130. package/dist/ui/client/ui/_app/immutable/nodes/0.3bVKqGbx.js.br +0 -0
  131. package/dist/ui/client/ui/_app/immutable/nodes/0.3bVKqGbx.js.gz +0 -0
  132. package/dist/ui/client/ui/_app/immutable/nodes/1.C81neQJL.js +1 -0
  133. package/dist/ui/client/ui/_app/immutable/nodes/1.C81neQJL.js.br +0 -0
  134. package/dist/ui/client/ui/_app/immutable/nodes/1.C81neQJL.js.gz +0 -0
  135. package/dist/ui/client/ui/_app/immutable/nodes/2.CmlyeAx_.js +1 -0
  136. package/dist/ui/client/ui/_app/immutable/nodes/2.CmlyeAx_.js.br +0 -0
  137. package/dist/ui/client/ui/_app/immutable/nodes/2.CmlyeAx_.js.gz +0 -0
  138. package/dist/ui/client/ui/_app/immutable/nodes/3.WT26F_BF.js +5 -0
  139. package/dist/ui/client/ui/_app/immutable/nodes/3.WT26F_BF.js.br +0 -0
  140. package/dist/ui/client/ui/_app/immutable/nodes/3.WT26F_BF.js.gz +0 -0
  141. package/dist/ui/client/ui/_app/immutable/nodes/4.tiDJxi6M.js +160 -0
  142. package/dist/ui/client/ui/_app/immutable/nodes/4.tiDJxi6M.js.br +0 -0
  143. package/dist/ui/client/ui/_app/immutable/nodes/4.tiDJxi6M.js.gz +0 -0
  144. package/dist/ui/client/ui/_app/immutable/nodes/5.MzfJoePg.js +6 -0
  145. package/dist/ui/client/ui/_app/immutable/nodes/5.MzfJoePg.js.br +0 -0
  146. package/dist/ui/client/ui/_app/immutable/nodes/5.MzfJoePg.js.gz +0 -0
  147. package/dist/ui/client/ui/_app/immutable/nodes/6.bNZhqiRK.js +6 -0
  148. package/dist/ui/client/ui/_app/immutable/nodes/6.bNZhqiRK.js.br +0 -0
  149. package/dist/ui/client/ui/_app/immutable/nodes/6.bNZhqiRK.js.gz +0 -0
  150. package/dist/ui/client/ui/_app/version.json +1 -0
  151. package/dist/ui/client/ui/_app/version.json.br +0 -0
  152. package/dist/ui/client/ui/_app/version.json.gz +0 -0
  153. package/dist/ui/client/ui/robots.txt +3 -0
  154. package/dist/ui/client/ui/robots.txt.br +0 -0
  155. package/dist/ui/client/ui/robots.txt.gz +0 -0
  156. package/dist/ui/handler.js +1 -0
  157. package/dist/ui/index.js +1 -0
  158. package/dist/ui/server/.vite/manifest.json +761 -0
  159. package/dist/ui/server/_app/immutable/assets/ExternalLink.CYXazpKA.css +1 -0
  160. package/dist/ui/server/_app/immutable/assets/Pane.Dgdg5KMw.css +1 -0
  161. package/dist/ui/server/_app/immutable/assets/_layout.DSVNnDlO.css +1 -0
  162. package/dist/ui/server/_app/immutable/assets/_layout.ONZWQgDA.css +1 -0
  163. package/dist/ui/server/_app/immutable/assets/_page.C0Nhvs_m.css +1 -0
  164. package/dist/ui/server/_app/immutable/assets/_page.DyY1vjRV.css +1 -0
  165. package/dist/ui/server/_app/immutable/assets/_page.WduKm4aT.css +1 -0
  166. package/dist/ui/server/_app/immutable/assets/_page.YyxFzHED.css +1 -0
  167. package/dist/ui/server/_app/immutable/assets/material-symbols-outlined-latin-400-normal.BhEvR8fk.woff2 +0 -0
  168. package/dist/ui/server/_app/immutable/assets/roboto-flex-cyrillic-ext-opsz-normal.nDQikIyu.woff2 +0 -0
  169. package/dist/ui/server/_app/immutable/assets/roboto-flex-cyrillic-opsz-normal.SjuC5rw5.woff2 +0 -0
  170. package/dist/ui/server/_app/immutable/assets/roboto-flex-greek-opsz-normal.C14fFRny.woff2 +0 -0
  171. package/dist/ui/server/_app/immutable/assets/roboto-flex-latin-ext-opsz-normal.xNclTVCo.woff2 +0 -0
  172. package/dist/ui/server/_app/immutable/assets/roboto-flex-latin-opsz-normal.hy8fyBBC.woff2 +0 -0
  173. package/dist/ui/server/_app/immutable/assets/roboto-flex-vietnamese-opsz-normal.C-H_yGOU.woff2 +0 -0
  174. package/dist/ui/server/_app/immutable/assets/roboto-mono-cyrillic-400-normal.B3hIXASd.woff +0 -0
  175. package/dist/ui/server/_app/immutable/assets/roboto-mono-cyrillic-400-normal.C-_K-ZCn.woff2 +0 -0
  176. package/dist/ui/server/_app/immutable/assets/roboto-mono-cyrillic-500-normal.DGZ7-lUP.woff2 +0 -0
  177. package/dist/ui/server/_app/immutable/assets/roboto-mono-cyrillic-500-normal.NpUJFYX7.woff +0 -0
  178. package/dist/ui/server/_app/immutable/assets/roboto-mono-cyrillic-ext-400-normal.BHxv52bw.woff2 +0 -0
  179. package/dist/ui/server/_app/immutable/assets/roboto-mono-cyrillic-ext-400-normal.W26xs1TL.woff +0 -0
  180. package/dist/ui/server/_app/immutable/assets/roboto-mono-cyrillic-ext-500-normal.6xdwlG7p.woff +0 -0
  181. package/dist/ui/server/_app/immutable/assets/roboto-mono-cyrillic-ext-500-normal.DC57U9n8.woff2 +0 -0
  182. package/dist/ui/server/_app/immutable/assets/roboto-mono-greek-400-normal.CH_u3Aru.woff2 +0 -0
  183. package/dist/ui/server/_app/immutable/assets/roboto-mono-greek-400-normal.P8xe1gs1.woff +0 -0
  184. package/dist/ui/server/_app/immutable/assets/roboto-mono-greek-500-normal.C2M8jX6G.woff +0 -0
  185. package/dist/ui/server/_app/immutable/assets/roboto-mono-greek-500-normal.DpRFkptA.woff2 +0 -0
  186. package/dist/ui/server/_app/immutable/assets/roboto-mono-latin-400-normal.DBZPkcnn.woff +0 -0
  187. package/dist/ui/server/_app/immutable/assets/roboto-mono-latin-400-normal.GekRknry.woff2 +0 -0
  188. package/dist/ui/server/_app/immutable/assets/roboto-mono-latin-500-normal.D6j6AMzd.woff +0 -0
  189. package/dist/ui/server/_app/immutable/assets/roboto-mono-latin-500-normal.pxIOXZmA.woff2 +0 -0
  190. package/dist/ui/server/_app/immutable/assets/roboto-mono-latin-ext-400-normal.BwLXVYNz.woff +0 -0
  191. package/dist/ui/server/_app/immutable/assets/roboto-mono-latin-ext-400-normal.DLAV9S_w.woff2 +0 -0
  192. package/dist/ui/server/_app/immutable/assets/roboto-mono-latin-ext-500-normal.B1IjfbhL.woff +0 -0
  193. package/dist/ui/server/_app/immutable/assets/roboto-mono-latin-ext-500-normal.Db3ge6Oe.woff2 +0 -0
  194. package/dist/ui/server/_app/immutable/assets/roboto-mono-vietnamese-400-normal.CzWHQABp.woff +0 -0
  195. package/dist/ui/server/_app/immutable/assets/roboto-mono-vietnamese-400-normal.yYTFiTTs.woff2 +0 -0
  196. package/dist/ui/server/_app/immutable/assets/roboto-mono-vietnamese-500-normal.Cq-quQMu.woff2 +0 -0
  197. package/dist/ui/server/_app/immutable/assets/roboto-mono-vietnamese-500-normal.IxzxMIj7.woff +0 -0
  198. package/dist/ui/server/adapter-env.js +1 -0
  199. package/dist/ui/server/adapter-index.js +73 -0
  200. package/dist/ui/server/adapter-index.js.map +1 -0
  201. package/dist/ui/server/adapter-node-env.js +63 -0
  202. package/dist/ui/server/adapter-node-env.js.map +1 -0
  203. package/dist/ui/server/adapter-node-handler.js +638 -0
  204. package/dist/ui/server/adapter-node-handler.js.map +1 -0
  205. package/dist/ui/server/chunks/ExternalLink.js +12 -0
  206. package/dist/ui/server/chunks/ExternalLink.js.map +1 -0
  207. package/dist/ui/server/chunks/Pane.js +13 -0
  208. package/dist/ui/server/chunks/Pane.js.map +1 -0
  209. package/dist/ui/server/chunks/composition.js +3468 -0
  210. package/dist/ui/server/chunks/composition.js.map +1 -0
  211. package/dist/ui/server/chunks/config-state.js +21 -0
  212. package/dist/ui/server/chunks/config-state.js.map +1 -0
  213. package/dist/ui/server/chunks/config.js +145 -0
  214. package/dist/ui/server/chunks/config.js.map +1 -0
  215. package/dist/ui/server/chunks/dialog.js +592 -0
  216. package/dist/ui/server/chunks/dialog.js.map +1 -0
  217. package/dist/ui/server/chunks/exports.js +352 -0
  218. package/dist/ui/server/chunks/exports.js.map +1 -0
  219. package/dist/ui/server/chunks/filled-button.js +116 -0
  220. package/dist/ui/server/chunks/filled-button.js.map +1 -0
  221. package/dist/ui/server/chunks/functions.js +29 -0
  222. package/dist/ui/server/chunks/functions.js.map +1 -0
  223. package/dist/ui/server/chunks/icon-button.js +234 -0
  224. package/dist/ui/server/chunks/icon-button.js.map +1 -0
  225. package/dist/ui/server/chunks/icon.js +49 -0
  226. package/dist/ui/server/chunks/icon.js.map +1 -0
  227. package/dist/ui/server/chunks/index-server.js +6 -0
  228. package/dist/ui/server/chunks/index-server.js.map +1 -0
  229. package/dist/ui/server/chunks/instance.js +3577 -0
  230. package/dist/ui/server/chunks/instance.js.map +1 -0
  231. package/dist/ui/server/chunks/internal.js +3577 -0
  232. package/dist/ui/server/chunks/internal.js.map +1 -0
  233. package/dist/ui/server/chunks/navigation.js +11 -0
  234. package/dist/ui/server/chunks/navigation.js.map +1 -0
  235. package/dist/ui/server/chunks/navigation2.js +15 -0
  236. package/dist/ui/server/chunks/navigation2.js.map +1 -0
  237. package/dist/ui/server/chunks/outlined-text-field.js +1477 -0
  238. package/dist/ui/server/chunks/outlined-text-field.js.map +1 -0
  239. package/dist/ui/server/chunks/paths.js +2 -0
  240. package/dist/ui/server/chunks/redispatch-event.js +91 -0
  241. package/dist/ui/server/chunks/redispatch-event.js.map +1 -0
  242. package/dist/ui/server/chunks/remote-1j2tn2d.js +4 -0
  243. package/dist/ui/server/chunks/remote.js +1580 -0
  244. package/dist/ui/server/chunks/remote.js.map +1 -0
  245. package/dist/ui/server/chunks/scope.js +13 -0
  246. package/dist/ui/server/chunks/scope.js.map +1 -0
  247. package/dist/ui/server/chunks/server-errors.js +471 -0
  248. package/dist/ui/server/chunks/server-errors.js.map +1 -0
  249. package/dist/ui/server/chunks/server.js +8 -0
  250. package/dist/ui/server/chunks/server.js.map +1 -0
  251. package/dist/ui/server/chunks/server2.js +1960 -0
  252. package/dist/ui/server/chunks/server2.js.map +1 -0
  253. package/dist/ui/server/chunks/sessions.js +65 -0
  254. package/dist/ui/server/chunks/sessions.js.map +1 -0
  255. package/dist/ui/server/chunks/sessions.remote.js +56 -0
  256. package/dist/ui/server/chunks/sessions.remote.js.map +1 -0
  257. package/dist/ui/server/chunks/shared-errors.js +198 -0
  258. package/dist/ui/server/chunks/shared-errors.js.map +1 -0
  259. package/dist/ui/server/chunks/shared.js +85 -0
  260. package/dist/ui/server/chunks/shared.js.map +1 -0
  261. package/dist/ui/server/chunks/src.js +1217 -0
  262. package/dist/ui/server/chunks/src.js.map +1 -0
  263. package/dist/ui/server/chunks/state.js +38 -0
  264. package/dist/ui/server/chunks/state.js.map +1 -0
  265. package/dist/ui/server/chunks/static-html.js +38 -0
  266. package/dist/ui/server/chunks/static-html.js.map +1 -0
  267. package/dist/ui/server/chunks/text-button.js +307 -0
  268. package/dist/ui/server/chunks/text-button.js.map +1 -0
  269. package/dist/ui/server/entries/endpoints/api/config/_server.ts.js +19 -0
  270. package/dist/ui/server/entries/endpoints/api/config/_server.ts.js.map +1 -0
  271. package/dist/ui/server/entries/endpoints/api/input/keys/_server.ts.js +14 -0
  272. package/dist/ui/server/entries/endpoints/api/input/keys/_server.ts.js.map +1 -0
  273. package/dist/ui/server/entries/endpoints/api/markers/_server.ts.js +13 -0
  274. package/dist/ui/server/entries/endpoints/api/markers/_server.ts.js.map +1 -0
  275. package/dist/ui/server/entries/endpoints/api/sessions/_id_id_/_server.ts.js +12 -0
  276. package/dist/ui/server/entries/endpoints/api/sessions/_id_id_/_server.ts.js.map +1 -0
  277. package/dist/ui/server/entries/endpoints/api/sessions/_server.ts.js +13 -0
  278. package/dist/ui/server/entries/endpoints/api/sessions/_server.ts.js.map +1 -0
  279. package/dist/ui/server/entries/endpoints/api/sessions/end/_server.ts.js +9 -0
  280. package/dist/ui/server/entries/endpoints/api/sessions/end/_server.ts.js.map +1 -0
  281. package/dist/ui/server/entries/endpoints/api/speech/_server.ts.js +25 -0
  282. package/dist/ui/server/entries/endpoints/api/speech/_server.ts.js.map +1 -0
  283. package/dist/ui/server/entries/endpoints/api/speech/stream/_server.ts.js +19 -0
  284. package/dist/ui/server/entries/endpoints/api/speech/stream/_server.ts.js.map +1 -0
  285. package/dist/ui/server/entries/endpoints/api/status/_server.ts.js +9 -0
  286. package/dist/ui/server/entries/endpoints/api/status/_server.ts.js.map +1 -0
  287. package/dist/ui/server/entries/hooks.server.js +161 -0
  288. package/dist/ui/server/entries/hooks.server.js.map +1 -0
  289. package/dist/ui/server/entries/pages/_error.svelte.js +16 -0
  290. package/dist/ui/server/entries/pages/_error.svelte.js.map +1 -0
  291. package/dist/ui/server/entries/pages/_layout.server.ts.js +17 -0
  292. package/dist/ui/server/entries/pages/_layout.server.ts.js.map +1 -0
  293. package/dist/ui/server/entries/pages/_layout.svelte.js +175 -0
  294. package/dist/ui/server/entries/pages/_layout.svelte.js.map +1 -0
  295. package/dist/ui/server/entries/pages/_page.server.ts.js +18 -0
  296. package/dist/ui/server/entries/pages/_page.server.ts.js.map +1 -0
  297. package/dist/ui/server/entries/pages/_page.svelte.js +444 -0
  298. package/dist/ui/server/entries/pages/_page.svelte.js.map +1 -0
  299. package/dist/ui/server/entries/pages/settings/_page.server.ts.js +12 -0
  300. package/dist/ui/server/entries/pages/settings/_page.server.ts.js.map +1 -0
  301. package/dist/ui/server/entries/pages/settings/_page.svelte.js +3531 -0
  302. package/dist/ui/server/entries/pages/settings/_page.svelte.js.map +1 -0
  303. package/dist/ui/server/entries/pages/setup/_layout.svelte.js +51 -0
  304. package/dist/ui/server/entries/pages/setup/_layout.svelte.js.map +1 -0
  305. package/dist/ui/server/entries/pages/setup/_page.svelte.js +230 -0
  306. package/dist/ui/server/entries/pages/setup/_page.svelte.js.map +1 -0
  307. package/dist/ui/server/entries/pages/setup/instructions/_page.server.ts.js +12 -0
  308. package/dist/ui/server/entries/pages/setup/instructions/_page.server.ts.js.map +1 -0
  309. package/dist/ui/server/entries/pages/setup/instructions/_page.svelte.js +271 -0
  310. package/dist/ui/server/entries/pages/setup/instructions/_page.svelte.js.map +1 -0
  311. package/dist/ui/server/entries/params.js +60 -0
  312. package/dist/ui/server/entries/params.js.map +1 -0
  313. package/dist/ui/server/env.js +1 -0
  314. package/dist/ui/server/handler.js +1 -0
  315. package/dist/ui/server/index.js +67 -0
  316. package/dist/ui/server/index.js.map +1 -0
  317. package/dist/ui/server/manifest-full.js +126 -0
  318. package/dist/ui/server/manifest.js +126 -0
  319. package/dist/ui/server/nodes/0.js +10 -0
  320. package/dist/ui/server/nodes/1.js +8 -0
  321. package/dist/ui/server/nodes/2.js +8 -0
  322. package/dist/ui/server/nodes/3.js +10 -0
  323. package/dist/ui/server/nodes/4.js +10 -0
  324. package/dist/ui/server/nodes/5.js +8 -0
  325. package/dist/ui/server/nodes/6.js +10 -0
  326. package/dist/ui/server/remote-entry.js +1 -0
  327. package/dist/ui/server/server.js +128 -0
  328. package/package.json +39 -3
@@ -0,0 +1,638 @@
1
+ import process from "node:process";
2
+ import fs, { createReadStream } from "node:fs";
3
+ import { Readable, pipeline } from "node:stream";
4
+ import { a as SvelteKitError } from "./chunks/shared.js";
5
+ import { n as noop } from "./chunks/functions.js";
6
+ import { app_path, assets, base, dir, env_prefix, mime_types, origin, prerendered_assets, server } from "../adapter-node.js";
7
+ import { t as env } from "./adapter-node-env.js";
8
+ import { format } from "node:url";
9
+ import path from "node:path";
10
+ // ../../node_modules/.pnpm/@sveltejs+kit@3.4.1_@sveltejs+vite-plugin-svelte@7.3.2_svelte@5.59.2_@typescript-eslint_728102f730ebab1d17bec5b56ce561d1/node_modules/@sveltejs/kit/src/exports/node/index.js
11
+ /** @type {WeakMap<import('http').IncomingMessage, (chunk: Buffer) => void>} */
12
+ var body_data_listeners = /* @__PURE__ */ new WeakMap();
13
+ /** @type {WeakSet<import('http').IncomingMessage>} */
14
+ var draining = /* @__PURE__ */ new WeakSet();
15
+ /**
16
+ * @param {import('http').IncomingMessage} req
17
+ * @param {number} [body_size_limit]
18
+ */
19
+ function get_raw_body(req, body_size_limit) {
20
+ const h = req.headers;
21
+ const content_length = Number(h["content-length"]);
22
+ const has_content_length = Number.isFinite(content_length);
23
+ if (req.httpVersionMajor === 1 && !has_content_length && h["transfer-encoding"] == null || content_length === 0) return null;
24
+ if (req.destroyed) {
25
+ const readable = new ReadableStream();
26
+ readable.cancel();
27
+ return readable;
28
+ }
29
+ let size = 0;
30
+ let cancelled = false;
31
+ let ended = false;
32
+ return new ReadableStream({
33
+ start(controller) {
34
+ if (body_size_limit !== void 0 && has_content_length && content_length > body_size_limit) {
35
+ const error = new SvelteKitError(413, "Payload Too Large", `Content-length of ${content_length} exceeds limit of ${body_size_limit} bytes.`);
36
+ controller.error(error);
37
+ return;
38
+ }
39
+ /** @param {Error} error */
40
+ const on_error = (error) => {
41
+ cancelled = true;
42
+ controller.error(error);
43
+ };
44
+ const on_end = () => {
45
+ ended = true;
46
+ if (cancelled) return;
47
+ controller.close();
48
+ };
49
+ const on_close = () => {
50
+ if (ended || cancelled) return;
51
+ cancelled = true;
52
+ controller.error(/* @__PURE__ */ new Error("Request closed before the body was fully received"));
53
+ };
54
+ /** @param {Buffer} chunk */
55
+ const on_data = (chunk) => {
56
+ if (cancelled) return;
57
+ size += chunk.length;
58
+ if (body_size_limit !== void 0 && size > body_size_limit) {
59
+ cancelled = true;
60
+ const message = `request body size exceeded BODY_SIZE_LIMIT of ${body_size_limit}`;
61
+ const error = new SvelteKitError(413, "Payload Too Large", message);
62
+ controller.error(error);
63
+ return;
64
+ }
65
+ if (has_content_length && size > content_length) {
66
+ cancelled = true;
67
+ const message = `request body size exceeded content-length of ${content_length}`;
68
+ const error = new SvelteKitError(413, "Payload Too Large", message);
69
+ controller.error(error);
70
+ return;
71
+ }
72
+ controller.enqueue(chunk);
73
+ if (controller.desiredSize === null || controller.desiredSize <= 0) req.pause();
74
+ };
75
+ req.on("error", on_error);
76
+ req.on("end", on_end);
77
+ req.on("close", on_close);
78
+ req.on("data", on_data);
79
+ body_data_listeners.set(req, on_data);
80
+ },
81
+ pull() {
82
+ req.resume();
83
+ },
84
+ cancel(reason) {
85
+ cancelled = true;
86
+ req.destroy(reason);
87
+ }
88
+ });
89
+ }
90
+ /**
91
+ * @param {{
92
+ * request: import('http').IncomingMessage;
93
+ * response?: import('http').ServerResponse;
94
+ * base: string;
95
+ * bodySizeLimit?: number;
96
+ * }} options
97
+ * @returns {Request}
98
+ */
99
+ function getRequest({ request, response, base, bodySizeLimit }) {
100
+ let headers = request.headers;
101
+ if (request.httpVersionMajor >= 2) {
102
+ headers = Object.assign({}, headers);
103
+ if (headers[":authority"]) headers.host = headers[":authority"];
104
+ delete headers[":authority"];
105
+ delete headers[":method"];
106
+ delete headers[":path"];
107
+ delete headers[":scheme"];
108
+ }
109
+ const controller = new AbortController();
110
+ request.once("close", () => {
111
+ if (request.readableAborted) controller.abort();
112
+ });
113
+ response?.once("close", () => {
114
+ if (!response.writableEnded) controller.abort();
115
+ });
116
+ return new Request(base + request.url, {
117
+ duplex: "half",
118
+ method: request.method,
119
+ headers: Object.entries(headers),
120
+ signal: controller.signal,
121
+ body: request.method === "GET" || request.method === "HEAD" ? void 0 : get_raw_body(request, bodySizeLimit)
122
+ });
123
+ }
124
+ /**
125
+ * Drains any unconsumed request body once the response has been sent. When a
126
+ * route doesn't read the request body (for example a page route receiving a
127
+ * POST), the unread bytes remain buffered in the socket. On keep-alive
128
+ * connections Node's HTTP parser then reads those leftover bytes as the next
129
+ * request, fails to parse them, and resets the connection — losing any
130
+ * pipelined request. Resuming the request discards the bytes so the connection
131
+ * stays usable.
132
+ *
133
+ * Because `get_raw_body` attaches a `data` listener, Node marks the request as
134
+ * being consumed (`req._consuming`) and skips its own automatic drain, so we
135
+ * have to do it ourselves. The whole remaining body is read and discarded; this
136
+ * is the intended trade-off (keeping the connection reusable) over destroying it.
137
+ * @see https://github.com/sveltejs/kit/issues/14916
138
+ * @see https://github.com/sveltejs/kit/issues/15526
139
+ * @param {import('http').ServerResponse} res
140
+ */
141
+ function drain_request(res) {
142
+ const req = res.req;
143
+ if (!req || req.readableEnded || req.destroyed) return;
144
+ const on_data = body_data_listeners.get(req);
145
+ if (on_data) {
146
+ req.removeListener("data", on_data);
147
+ body_data_listeners.delete(req);
148
+ }
149
+ const socket = req.socket;
150
+ if (req.httpVersionMajor === 1 && socket && !draining.has(req)) {
151
+ draining.add(req);
152
+ if (socket.destroyed) req.destroy();
153
+ else {
154
+ const on_close = () => {
155
+ if (!req.readableEnded) req.destroy();
156
+ };
157
+ socket.once("close", on_close);
158
+ req.once("end", () => socket.off("close", on_close));
159
+ }
160
+ }
161
+ req.resume();
162
+ }
163
+ /**
164
+ * @param {import('http').ServerResponse} res
165
+ * @param {Response} response
166
+ * @returns {void}
167
+ */
168
+ function setResponse(res, response) {
169
+ res.once("finish", () => drain_request(res));
170
+ res.once("close", () => drain_request(res));
171
+ for (const [key, value] of response.headers) try {
172
+ res.setHeader(key, key === "set-cookie" ? response.headers.getSetCookie() : value);
173
+ } catch (error) {
174
+ res.getHeaderNames().forEach((name) => res.removeHeader(name));
175
+ res.writeHead(500).end(String(error));
176
+ return;
177
+ }
178
+ if (!response.body) {
179
+ res.writeHead(response.status);
180
+ res.end();
181
+ return;
182
+ }
183
+ if (response.body.locked) {
184
+ res.writeHead(response.status);
185
+ res.end("Fatal error: Response body is locked. This can happen when the response was already read (for example through 'response.json()' or 'response.text()').");
186
+ return;
187
+ }
188
+ const reader = response.body.getReader();
189
+ if (res.destroyed) {
190
+ reader.cancel();
191
+ return;
192
+ }
193
+ const cancel = (error) => {
194
+ res.off("close", cancel);
195
+ res.off("error", cancel);
196
+ reader.cancel(error).catch(noop);
197
+ if (error) res.destroy(error);
198
+ };
199
+ res.on("close", cancel);
200
+ res.on("error", cancel);
201
+ /** @type {Uint8Array<ArrayBuffer>[]} */
202
+ const buffered = [];
203
+ /** @type {ReturnType<typeof reader.read> | null} */
204
+ let pending = null;
205
+ probe();
206
+ async function probe() {
207
+ try {
208
+ /** @type {Promise<undefined>} */
209
+ const deadline = new Promise((fulfil) => setImmediate(() => fulfil(void 0)));
210
+ while (buffered.length < 2) {
211
+ pending = reader.read();
212
+ const result = await Promise.race([pending, deadline]);
213
+ if (!result) break;
214
+ pending = null;
215
+ if (result.done) {
216
+ if (!res.hasHeader("content-length") && !res.hasHeader("transfer-encoding")) res.setHeader("content-length", buffered.reduce((total, chunk) => total + chunk.byteLength, 0));
217
+ break;
218
+ }
219
+ buffered.push(result.value);
220
+ }
221
+ if (res.destroyed) return;
222
+ res.writeHead(response.status);
223
+ await next();
224
+ } catch (error) {
225
+ if (!res.headersSent) res.writeHead(response.status);
226
+ cancel(error instanceof Error ? error : new Error(String(error)));
227
+ }
228
+ }
229
+ async function next() {
230
+ try {
231
+ for (;;) {
232
+ /** @type {Awaited<ReturnType<typeof reader.read>>} */
233
+ let result;
234
+ if (buffered.length > 0) result = {
235
+ done: false,
236
+ value: buffered.shift()
237
+ };
238
+ else if (pending) {
239
+ result = await pending;
240
+ pending = null;
241
+ } else result = await reader.read();
242
+ const { done, value } = result;
243
+ if (done) break;
244
+ if (!res.write(value)) {
245
+ res.once("drain", next);
246
+ return;
247
+ }
248
+ }
249
+ res.end();
250
+ } catch (error) {
251
+ cancel(error instanceof Error ? error : new Error(String(error)));
252
+ }
253
+ }
254
+ }
255
+ /**
256
+ * Converts a file on disk to a readable stream
257
+ * @param {string} file
258
+ * @returns {ReadableStream}
259
+ * @since 2.4.0
260
+ */
261
+ function createReadableStream(file) {
262
+ return Readable.toWeb(createReadStream(file));
263
+ }
264
+ // ../../node_modules/.pnpm/@sveltejs+adapter-server@0.2.0_vite@8.4.0_@types+node@25.9.12_esbuild@0.28.2_tsx@4.23.15_yaml@2.9.1_/node_modules/@sveltejs/adapter-server/runtime.js
265
+ /** @type {typeof import('./runtime.js').negotiateEncoding} */
266
+ function negotiateEncoding(header, variants) {
267
+ if (!header || !(variants.br || variants.gz)) return;
268
+ /** @type {Map<string, number>} */
269
+ const weights = /* @__PURE__ */ new Map();
270
+ for (const part of header.toLowerCase().split(",")) {
271
+ const [coding, ...params] = part.split(";");
272
+ let weight = 1;
273
+ for (const param of params) {
274
+ const [name, value] = param.split("=");
275
+ if (name.trim() === "q") weight = parseFloat(value) || 0;
276
+ }
277
+ weights.set(coding.trim(), weight);
278
+ }
279
+ /** @param {string} coding */
280
+ const weight = (coding) => weights.get(coding) ?? weights.get("*") ?? 0;
281
+ const br = variants.br ? weight("br") : 0;
282
+ if ((variants.gz ? weight("gzip") : 0) > br) return "gz";
283
+ if (br > 0) return "br";
284
+ }
285
+ /** @type {typeof import('./runtime.js').forwardedAddress} */
286
+ function forwardedAddress({ header, value, depth, envPrefix }) {
287
+ if (value == null) throw new Error(`Address header was specified with ${envPrefix}ADDRESS_HEADER=${header} but is absent from request`);
288
+ if (header !== "x-forwarded-for") return value;
289
+ const addresses = value.split(",");
290
+ if (depth < 1) throw new Error(`${envPrefix}XFF_DEPTH must be a positive integer`);
291
+ if (depth > addresses.length) throw new Error(`${envPrefix}XFF_DEPTH is ${depth}, but only found ${addresses.length} addresses`);
292
+ return addresses[addresses.length - depth].trim();
293
+ }
294
+ /** @type {typeof import('./runtime.js').trailingSlashLocation} */
295
+ function trailingSlashLocation(pathname) {
296
+ const segment = pathname.replace(/\/$/, "").split("/").at(-1).split("%").map(encodeURI).join("%");
297
+ return pathname.endsWith("/") ? `../${segment}` : `./${segment}/`;
298
+ }
299
+ // ../../node_modules/.pnpm/@sveltejs+adapter-node@6.0.6_@sveltejs+kit@3.4.1_@sveltejs+vite-plugin-svelte@7.3.2_sve_3be120119c99b54480c47076181533fb/node_modules/@sveltejs/adapter-node/src/utils.js
300
+ /**
301
+ * Parses the given value into number of bytes.
302
+ *
303
+ * @param {string} value - Size in bytes. Can also be specified with a unit suffix kilobytes (K), megabytes (M), or gigabytes (G).
304
+ * @returns {number}
305
+ */
306
+ function parse_as_bytes(value) {
307
+ const multiplier = {
308
+ K: 1024,
309
+ M: 1048576,
310
+ G: 0x40000000
311
+ }[value[value.length - 1]?.toUpperCase()] ?? 1;
312
+ return Number(multiplier != 1 ? value.substring(0, value.length - 1) : value) * multiplier;
313
+ }
314
+ /**
315
+ * Parses and validates an origin URL.
316
+ *
317
+ * @param {string | undefined} value - Origin URL with http:// or https:// protocol
318
+ * @returns {string | undefined} The validated origin, or undefined if value is undefined
319
+ * @throws {Error} If value is provided but invalid
320
+ */
321
+ function parse_origin(value) {
322
+ if (value === void 0) return;
323
+ const trimmed = value.trim();
324
+ let url;
325
+ try {
326
+ url = new URL(trimmed);
327
+ } catch (error) {
328
+ throw new Error(`Invalid ORIGIN: '${trimmed}'. ORIGIN must be a valid URL with http:// or https:// protocol. For example: 'http://localhost:3000' or 'https://my.site'`, { cause: error });
329
+ }
330
+ if (url.protocol !== "http:" && url.protocol !== "https:") throw new Error(`Invalid ORIGIN: '${trimmed}'. Only http:// and https:// protocols are supported. Received protocol: ${url.protocol}`);
331
+ return url.origin;
332
+ }
333
+ /**
334
+ * Formats the address the server is listening on.
335
+ *
336
+ * @param {string | false} path
337
+ * @param {string} host
338
+ * @param {string | false} port
339
+ * @param {import('node:net').AddressInfo | string | null} address
340
+ * @returns {string}
341
+ */
342
+ function format_listening_address(path, host, port, address) {
343
+ if (path) return path;
344
+ if (address && typeof address === "object") return format({
345
+ protocol: "http:",
346
+ hostname: address.address,
347
+ port: address.port
348
+ });
349
+ return format({
350
+ protocol: "http:",
351
+ hostname: host,
352
+ port: String(port)
353
+ });
354
+ }
355
+ // ../../node_modules/.pnpm/@sveltejs+adapter-node@6.0.6_@sveltejs+kit@3.4.1_@sveltejs+vite-plugin-svelte@7.3.2_sve_3be120119c99b54480c47076181533fb/node_modules/@sveltejs/adapter-node/src/static.js
356
+ /** @import { IncomingMessage, ServerResponse } from 'node:http' */
357
+ /**
358
+ * @typedef {(req: IncomingMessage, res: ServerResponse, next: () => void | Promise<void>) => void | Promise<void>} Middleware
359
+ * @typedef {AssetEntry & { type?: string, cache_control?: string }} Asset
360
+ * @typedef {Asset | { location: string }} Entry
361
+ */
362
+ /**
363
+ * Splits `req.url` into a decoded pathname and the search string.
364
+ * Decoding follows kit's router: reserved characters such as `%2F` stay
365
+ * encoded. An undecodable pathname is returned as-is, so it misses the
366
+ * asset table and falls through to SvelteKit's 400
367
+ * @param {import('node:http').IncomingMessage} req
368
+ */
369
+ function split_url(req) {
370
+ let pathname = req.url;
371
+ let search = "";
372
+ const query_index = pathname.indexOf("?");
373
+ if (query_index !== -1) {
374
+ search = pathname.slice(query_index);
375
+ pathname = pathname.slice(0, query_index);
376
+ }
377
+ if (pathname.includes("%")) try {
378
+ pathname = pathname.split("%25").map(decodeURI).join("%25");
379
+ } catch {}
380
+ return {
381
+ pathname,
382
+ search
383
+ };
384
+ }
385
+ /**
386
+ * Whether an `If-None-Match` value matches `etag`, using weak comparison
387
+ * @param {string | undefined} header
388
+ * @param {string} etag
389
+ */
390
+ function etag_matches(header, etag) {
391
+ if (!header) return false;
392
+ if (header.trim() === "*") return true;
393
+ return header.split(",").some((tag) => tag.trim().replace(/^W\//, "") === etag);
394
+ }
395
+ /**
396
+ * Absolute file paths and content types for one table
397
+ * @param {string} dir
398
+ * @param {AssetTable} table
399
+ * @param {Record<string, string>} mime_types
400
+ * @returns {Map<string, Asset>}
401
+ */
402
+ function resolve(dir, table, mime_types) {
403
+ /** @type {Map<string, Asset>} */
404
+ const files = /* @__PURE__ */ new Map();
405
+ for (const [key, entry] of table.entries) {
406
+ let type = mime_types[entry.file.slice(entry.file.lastIndexOf("."))];
407
+ if (type === "text/html") type += ";charset=utf-8";
408
+ files.set(key, {
409
+ ...entry,
410
+ file: path.join(dir, entry.file),
411
+ type
412
+ });
413
+ }
414
+ for (const [alias, key] of table.aliases) files.set(alias, files.get(key));
415
+ return files;
416
+ }
417
+ /**
418
+ * One lookup for every request, decided at boot: client assets (immutable below
419
+ * `app_path`), prerendered pages, and a 308 from the non-canonical trailing-slash
420
+ * form of a prerendered path to the canonical one. Client assets win a collision
421
+ * @param {{
422
+ * dir: string,
423
+ * base: string,
424
+ * app_path: string,
425
+ * mime_types: Record<string, string>,
426
+ * assets: AssetTable,
427
+ * prerendered_assets: AssetTable
428
+ * }} opts
429
+ * @returns {Map<string, Entry>}
430
+ */
431
+ function create_file_map({ dir, base, app_path, mime_types, assets, prerendered_assets }) {
432
+ /** @type {Map<string, Entry>} */
433
+ const files = resolve(`${dir}/client${base}`, assets, mime_types);
434
+ const immutable = `/${app_path}/immutable/`;
435
+ for (const [key, asset] of files) if (key.startsWith(immutable))
436
+ /** @type {Asset} */ asset.cache_control = "public,max-age=31536000,immutable";
437
+ const prerendered = resolve(`${dir}/prerendered${base}`, prerendered_assets, mime_types);
438
+ for (const [key, asset] of prerendered) if (!files.has(key)) files.set(key, asset);
439
+ for (const key of prerendered.keys()) {
440
+ const inverted = key.at(-1) === "/" ? key.slice(0, -1) : key + "/";
441
+ if (inverted && !files.has(inverted)) files.set(inverted, { location: trailingSlashLocation(inverted) });
442
+ }
443
+ return files;
444
+ }
445
+ /**
446
+ * Serves the closed set of files recorded at adapt time. Everything about a
447
+ * response is decided before the first request, so a request is one map
448
+ * lookup, header negotiation and a stream
449
+ * @param {Map<string, Entry>} files
450
+ * @returns {Middleware}
451
+ */
452
+ function serve_static(files) {
453
+ return (req, res, next) => {
454
+ const { pathname, search } = split_url(req);
455
+ const asset = files.get(pathname);
456
+ if (!asset) return next();
457
+ if (req.method !== "GET" && req.method !== "HEAD") {
458
+ res.writeHead(405, { allow: "GET, HEAD" }).end();
459
+ return;
460
+ }
461
+ if ("location" in asset) {
462
+ res.writeHead(308, { location: asset.location + search }).end();
463
+ return;
464
+ }
465
+ let file = asset.file;
466
+ let size = asset.size;
467
+ let etag = `"${asset.etag}"`;
468
+ const variant = negotiateEncoding(req.headers["accept-encoding"], asset);
469
+ if (variant) {
470
+ size = asset[variant];
471
+ file += `.${variant}`;
472
+ etag = `"${asset.etag}.${variant}"`;
473
+ }
474
+ /** @type {Record<string, string | number>} */
475
+ const headers = { etag };
476
+ if (asset.br || asset.gz) headers.vary = "Accept-Encoding";
477
+ if (asset.cache_control) headers["cache-control"] = asset.cache_control;
478
+ if (etag_matches(req.headers["if-none-match"], etag)) {
479
+ res.writeHead(304, headers).end();
480
+ return;
481
+ }
482
+ headers["content-length"] = size;
483
+ headers["accept-ranges"] = "bytes";
484
+ if (asset.type) headers["content-type"] = asset.type;
485
+ if (variant) headers["content-encoding"] = variant === "gz" ? "gzip" : "br";
486
+ /** @type {{ start?: number, end?: number }} */
487
+ const range = {};
488
+ let status = 200;
489
+ const if_range = req.headers["if-range"];
490
+ if (req.method === "GET" && req.headers.range && (!if_range || if_range === etag)) {
491
+ const match = /^bytes=(\d*)-(\d*)$/.exec(req.headers.range);
492
+ if (match && (match[1] || match[2])) {
493
+ let start = match[1] ? parseInt(match[1], 10) : NaN;
494
+ let end = match[2] ? parseInt(match[2], 10) : size - 1;
495
+ if (isNaN(start)) {
496
+ start = Math.max(size - end, 0);
497
+ end = size - 1;
498
+ } else end = Math.min(end, size - 1);
499
+ if (start >= size || start > end) {
500
+ res.writeHead(416, { "content-range": `bytes */${size}` }).end();
501
+ return;
502
+ }
503
+ status = 206;
504
+ headers["content-range"] = `bytes ${start}-${end}/${size}`;
505
+ headers["content-length"] = end - start + 1;
506
+ range.start = start;
507
+ range.end = end;
508
+ }
509
+ }
510
+ res.writeHead(status, headers);
511
+ if (req.method === "HEAD") {
512
+ res.end();
513
+ return;
514
+ }
515
+ pipeline(fs.createReadStream(file, range), res, () => {});
516
+ };
517
+ }
518
+ // ../../node_modules/.pnpm/@sveltejs+adapter-node@6.0.6_@sveltejs+kit@3.4.1_@sveltejs+vite-plugin-svelte@7.3.2_sve_3be120119c99b54480c47076181533fb/node_modules/@sveltejs/adapter-node/src/handler.js
519
+ /** @import { IncomingHttpHeaders } from 'node:http' */
520
+ /** @import { Middleware } from './static.js' */
521
+ var env_origin = env("ORIGIN", void 0);
522
+ if (origin && env_origin !== void 0) console.warn(`${env_prefix}ORIGIN is ignored because the SvelteKit configuration \`paths.origin\` setting was set to ${origin}`);
523
+ var public_origin = origin || parse_origin(env_origin);
524
+ var xff_depth = parseInt(env("XFF_DEPTH", "1"));
525
+ var address_header = env("ADDRESS_HEADER", "").toLowerCase();
526
+ var protocol_header = env("PROTOCOL_HEADER", "").toLowerCase();
527
+ var host_header = env("HOST_HEADER", "").toLowerCase();
528
+ var port_header = env("PORT_HEADER", "").toLowerCase();
529
+ var body_size_limit = parse_as_bytes(env("BODY_SIZE_LIMIT", "512K"));
530
+ if (isNaN(body_size_limit)) throw new Error(`Invalid BODY_SIZE_LIMIT: '${env("BODY_SIZE_LIMIT")}'. Please provide a numeric value.`);
531
+ var asset_dir = `${dir}/client${base}`;
532
+ await server.init({
533
+ env: process.env,
534
+ read: (file) => createReadableStream(`${asset_dir}/${file}`)
535
+ });
536
+ /** @type {Middleware} */
537
+ var ssr = async (req, res) => {
538
+ /** @type {Request} */
539
+ let request;
540
+ let request_origin = public_origin;
541
+ if (!request_origin) try {
542
+ request_origin = get_origin(req.headers);
543
+ } catch (error) {
544
+ console.error(`Could not determine request origin: ${error instanceof Error ? error.message : String(error)}`);
545
+ res.statusCode = 400;
546
+ res.end("Bad Request");
547
+ return;
548
+ }
549
+ try {
550
+ request = getRequest({
551
+ base: request_origin,
552
+ request: req,
553
+ response: res,
554
+ bodySizeLimit: body_size_limit
555
+ });
556
+ } catch {
557
+ res.statusCode = 400;
558
+ res.end("Bad Request");
559
+ return;
560
+ }
561
+ const response = await server.respond(request, {
562
+ platform: { req },
563
+ getClientAddress: () => {
564
+ if (address_header) return forwardedAddress({
565
+ header: address_header,
566
+ value: req.headers[address_header],
567
+ depth: xff_depth,
568
+ envPrefix: env_prefix
569
+ });
570
+ return req.connection?.remoteAddress || req.connection?.socket?.remoteAddress || req.socket?.remoteAddress || req.info?.remoteAddress;
571
+ }
572
+ });
573
+ if (response.headers.get("content-type")?.startsWith("text/event-stream")) res.setHeader("x-accel-buffering", "no");
574
+ setResponse(res, response);
575
+ };
576
+ /**
577
+ * @param {string} name
578
+ * @param {string | string[] | undefined} value
579
+ * @returns {string | undefined}
580
+ */
581
+ function normalise_header(name, value) {
582
+ if (!name) return void 0;
583
+ if (Array.isArray(value)) {
584
+ if (value.length === 0) return void 0;
585
+ if (value.length === 1) return value[0];
586
+ throw new Error(`Multiple values provided for ${name} header where only one expected: ${value}`);
587
+ }
588
+ return value;
589
+ }
590
+ /**
591
+ * @param {IncomingHttpHeaders} headers
592
+ * @returns {string}
593
+ */
594
+ function get_origin(headers) {
595
+ const protocol = decodeURIComponent(normalise_header(protocol_header, headers[protocol_header]) || "https");
596
+ if (protocol.includes(":")) throw new Error(`The ${protocol_header} header specified ${protocol} which is an invalid because it includes \`:\`. It should only contain the protocol scheme (e.g. \`https\`)`);
597
+ const host = normalise_header(host_header, headers[host_header]) || normalise_header("host", headers["host"]);
598
+ if (!host) {
599
+ const header_names = host_header ? `${host_header} or host headers` : "host header";
600
+ throw new Error(`Could not determine host. The request must have a value provided by the ${header_names}`);
601
+ }
602
+ const port = normalise_header(port_header, headers[port_header]);
603
+ if (port && isNaN(+port)) throw new Error(`The ${port_header} header specified ${port} which is an invalid port because it is not a number. The value should only contain the port number (e.g. 443)`);
604
+ return port && !/:\d*$/.test(host) ? `${protocol}://${host}:${port}` : `${protocol}://${host}`;
605
+ }
606
+ var serve = serve_static(create_file_map({
607
+ dir,
608
+ base,
609
+ app_path,
610
+ mime_types,
611
+ assets,
612
+ prerendered_assets
613
+ }));
614
+ /**
615
+ * If anything throws or rejects while handling a request (serving a static or
616
+ * prerendered file, or rendering), log the error and respond with a 500 instead
617
+ * of letting it become an uncaught exception that takes down the whole process
618
+ * @type {Middleware}
619
+ */
620
+ var handler = async (req, res, next) => {
621
+ try {
622
+ await serve(req, res, () => ssr(req, res, next));
623
+ } catch (error) {
624
+ console.error(error);
625
+ if (res.headersSent) {
626
+ res.destroy();
627
+ return;
628
+ }
629
+ res.getHeaderNames().forEach((name) => res.removeHeader(name));
630
+ res.writeHead(500, {
631
+ "content-type": "text/plain",
632
+ "content-length": 21
633
+ }).end("Internal Server Error");
634
+ }
635
+ };
636
+ export { format_listening_address as n, handler as t };
637
+
638
+ //# sourceMappingURL=adapter-node-handler.js.map