d1s 0.2.6 → 0.2.8

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 (247) hide show
  1. package/README.md +3 -1
  2. package/dist/.next/.next/BUILD_ID +1 -1
  3. package/dist/.next/.next/app-build-manifest.json +34 -27
  4. package/dist/.next/.next/app-path-routes-manifest.json +1 -1
  5. package/dist/.next/.next/build-manifest.json +2 -2
  6. package/dist/.next/.next/cache/.rscinfo +1 -1
  7. package/dist/.next/.next/cache/.tsbuildinfo +1 -1
  8. package/dist/.next/.next/cache/webpack/client-development/0.pack.gz +0 -0
  9. package/dist/.next/.next/cache/webpack/client-development/1.pack.gz +0 -0
  10. package/dist/.next/.next/cache/webpack/client-development/2.pack.gz +0 -0
  11. package/dist/.next/.next/cache/webpack/client-development/3.pack.gz +0 -0
  12. package/dist/.next/.next/cache/webpack/client-development/4.pack.gz +0 -0
  13. package/dist/.next/.next/cache/webpack/client-development/index.pack.gz +0 -0
  14. package/dist/.next/.next/cache/webpack/client-development/index.pack.gz.old +0 -0
  15. package/dist/.next/.next/cache/webpack/client-production/0.pack +0 -0
  16. package/dist/.next/.next/cache/webpack/client-production/1.pack +0 -0
  17. package/dist/.next/.next/cache/webpack/client-production/10.pack +0 -0
  18. package/dist/.next/.next/cache/webpack/client-production/11.pack +0 -0
  19. package/dist/.next/.next/cache/webpack/client-production/12.pack +0 -0
  20. package/dist/.next/.next/cache/webpack/client-production/13.pack +0 -0
  21. package/dist/.next/.next/cache/webpack/client-production/14.pack +0 -0
  22. package/dist/.next/.next/cache/webpack/client-production/2.pack +0 -0
  23. package/dist/.next/.next/cache/webpack/client-production/3.pack +0 -0
  24. package/dist/.next/.next/cache/webpack/client-production/4.pack +0 -0
  25. package/dist/.next/.next/cache/webpack/client-production/5.pack +0 -0
  26. package/dist/.next/.next/cache/webpack/client-production/6.pack +0 -0
  27. package/dist/.next/.next/cache/webpack/client-production/7.pack +0 -0
  28. package/dist/.next/.next/cache/webpack/client-production/8.pack +0 -0
  29. package/dist/.next/.next/cache/webpack/client-production/9.pack +0 -0
  30. package/dist/.next/.next/cache/webpack/client-production/index.pack +0 -0
  31. package/dist/.next/.next/cache/webpack/client-production/index.pack.old +0 -0
  32. package/dist/.next/.next/cache/webpack/edge-server-production/index.pack +0 -0
  33. package/dist/.next/.next/cache/webpack/server-development/0.pack.gz +0 -0
  34. package/dist/.next/.next/cache/webpack/server-development/1.pack.gz +0 -0
  35. package/dist/.next/.next/cache/webpack/server-development/2.pack.gz +0 -0
  36. package/dist/.next/.next/cache/webpack/server-development/3.pack.gz +0 -0
  37. package/dist/.next/.next/cache/webpack/server-development/4.pack.gz +0 -0
  38. package/dist/.next/.next/cache/webpack/server-development/index.pack.gz +0 -0
  39. package/dist/.next/.next/cache/webpack/server-development/index.pack.gz.old +0 -0
  40. package/dist/.next/.next/cache/webpack/server-production/0.pack +0 -0
  41. package/dist/.next/.next/cache/webpack/server-production/1.pack +0 -0
  42. package/dist/.next/.next/cache/webpack/server-production/10.pack +0 -0
  43. package/dist/.next/.next/cache/webpack/server-production/11.pack +0 -0
  44. package/dist/.next/.next/cache/webpack/server-production/12.pack +0 -0
  45. package/dist/.next/.next/cache/webpack/server-production/13.pack +0 -0
  46. package/dist/.next/.next/cache/webpack/server-production/2.pack +0 -0
  47. package/dist/.next/.next/cache/webpack/server-production/3.pack +0 -0
  48. package/dist/.next/.next/cache/webpack/server-production/4.pack +0 -0
  49. package/dist/.next/.next/cache/webpack/server-production/5.pack +0 -0
  50. package/dist/.next/.next/cache/webpack/server-production/6.pack +0 -0
  51. package/dist/.next/.next/cache/webpack/server-production/7.pack +0 -0
  52. package/dist/.next/.next/cache/webpack/server-production/8.pack +0 -0
  53. package/dist/.next/.next/cache/webpack/server-production/9.pack +0 -0
  54. package/dist/.next/.next/cache/webpack/server-production/index.pack +0 -0
  55. package/dist/.next/.next/cache/webpack/server-production/index.pack.old +0 -0
  56. package/dist/.next/.next/next-minimal-server.js.nft.json +1 -1
  57. package/dist/.next/.next/next-server.js.nft.json +1 -1
  58. package/dist/.next/.next/prerender-manifest.json +1 -1
  59. package/dist/.next/.next/server/app/_not-found/page.js +1 -1
  60. package/dist/.next/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  61. package/dist/.next/.next/server/app/_not-found.html +1 -1
  62. package/dist/.next/.next/server/app/_not-found.rsc +2 -2
  63. package/dist/.next/.next/server/app/api/cloudflare/route.js +1 -1
  64. package/dist/.next/.next/server/app/api/cloudflare/route.js.nft.json +1 -1
  65. package/dist/.next/.next/server/app/api/cloudflare/route_client-reference-manifest.js +1 -1
  66. package/dist/.next/.next/server/app/api/databases/route.js +1 -1
  67. package/dist/.next/.next/server/app/api/databases/route.js.nft.json +1 -1
  68. package/dist/.next/.next/server/app/api/databases/route_client-reference-manifest.js +1 -1
  69. package/dist/.next/.next/server/app/api/migrations/sync/route.js +3 -3
  70. package/dist/.next/.next/server/app/api/migrations/sync/route.js.nft.json +1 -1
  71. package/dist/.next/.next/server/app/api/migrations/sync/route_client-reference-manifest.js +1 -1
  72. package/dist/.next/.next/server/app/api/migrations/sync-files/route.js +1 -1
  73. package/dist/.next/.next/server/app/api/migrations/sync-files/route.js.nft.json +1 -1
  74. package/dist/.next/.next/server/app/api/migrations/sync-files/route_client-reference-manifest.js +1 -1
  75. package/dist/.next/.next/server/app/api/pull-remote/confirm/route.js +1 -1
  76. package/dist/.next/.next/server/app/api/pull-remote/confirm/route.js.nft.json +1 -1
  77. package/dist/.next/.next/server/app/api/pull-remote/confirm/route_client-reference-manifest.js +1 -1
  78. package/dist/.next/.next/server/app/api/pull-remote/preview/route.js +1 -1
  79. package/dist/.next/.next/server/app/api/pull-remote/preview/route.js.nft.json +1 -1
  80. package/dist/.next/.next/server/app/api/pull-remote/preview/route_client-reference-manifest.js +1 -1
  81. package/dist/.next/.next/server/app/api/push-remote/confirm/route.js +2 -2
  82. package/dist/.next/.next/server/app/api/push-remote/confirm/route.js.nft.json +1 -1
  83. package/dist/.next/.next/server/app/api/push-remote/confirm/route_client-reference-manifest.js +1 -1
  84. package/dist/.next/.next/server/app/api/push-remote/preview/route.js +2 -2
  85. package/dist/.next/.next/server/app/api/push-remote/preview/route.js.nft.json +1 -1
  86. package/dist/.next/.next/server/app/api/push-remote/preview/route_client-reference-manifest.js +1 -1
  87. package/dist/.next/.next/server/app/api/query/route.js +2 -2
  88. package/dist/.next/.next/server/app/api/query/route.js.nft.json +1 -1
  89. package/dist/.next/.next/server/app/api/query/route_client-reference-manifest.js +1 -1
  90. package/dist/.next/.next/server/app/api/tables/[name]/route.js +4 -4
  91. package/dist/.next/.next/server/app/api/tables/[name]/route.js.nft.json +1 -1
  92. package/dist/.next/.next/server/app/api/tables/[name]/route_client-reference-manifest.js +1 -1
  93. package/dist/.next/.next/server/app/api/tables/route.js +2 -2
  94. package/dist/.next/.next/server/app/api/tables/route.js.nft.json +1 -1
  95. package/dist/.next/.next/server/app/api/tables/route_client-reference-manifest.js +1 -1
  96. package/dist/.next/.next/server/app/api/update/route.js +5 -0
  97. package/dist/.next/.next/server/app/api/update/route.js.nft.json +1 -0
  98. package/dist/.next/.next/server/app/api/update/route_client-reference-manifest.js +1 -0
  99. package/dist/.next/.next/server/app/index.html +3 -3
  100. package/dist/.next/.next/server/app/index.rsc +3 -3
  101. package/dist/.next/.next/server/app/page.js +14 -12
  102. package/dist/.next/.next/server/app/page_client-reference-manifest.js +1 -1
  103. package/dist/.next/.next/server/app-paths-manifest.json +4 -3
  104. package/dist/.next/.next/server/chunks/336.js +1 -1
  105. package/dist/.next/.next/server/chunks/391.js +23 -0
  106. package/dist/.next/.next/server/chunks/452.js +1 -0
  107. package/dist/.next/.next/server/chunks/627.js +3 -3
  108. package/dist/.next/.next/server/chunks/638.js +3 -3
  109. package/dist/.next/.next/server/chunks/801.js +55 -0
  110. package/dist/.next/.next/server/chunks/992.js +3 -3
  111. package/dist/.next/.next/server/pages/404.html +1 -1
  112. package/dist/.next/.next/server/pages/500.html +1 -1
  113. package/dist/.next/.next/server/pages/_app.js +1 -1
  114. package/dist/.next/.next/server/pages/_document.js +1 -1
  115. package/dist/.next/.next/server/pages/_error.js +1 -1
  116. package/dist/.next/.next/server/pages-manifest.json +1 -1
  117. package/dist/.next/.next/server/server-reference-manifest.json +1 -1
  118. package/dist/.next/.next/static/JrwgdSDcipr0Zh7k19Cj_/_buildManifest.js +1 -0
  119. package/dist/.next/.next/static/chunks/958-98887928efebfdf7.js +1 -0
  120. package/dist/.next/.next/static/chunks/app/api/cloudflare/route-5133155a604f2719.js +1 -0
  121. package/dist/.next/.next/static/chunks/app/api/databases/route-63a31080b565794e.js +1 -0
  122. package/dist/.next/.next/static/chunks/app/api/migrations/sync/route-d97667565b4a59b6.js +1 -0
  123. package/dist/.next/.next/static/chunks/app/api/migrations/sync-files/route-7089bcbfeb6b5260.js +1 -0
  124. package/dist/.next/.next/static/chunks/app/api/pull-remote/confirm/route-9143e6e4c3f05162.js +1 -0
  125. package/dist/.next/.next/static/chunks/app/api/pull-remote/preview/route-c963d143a51aed66.js +1 -0
  126. package/dist/.next/.next/static/chunks/app/api/push-remote/confirm/route-072132c0a6cb3df3.js +1 -0
  127. package/dist/.next/.next/static/chunks/app/api/push-remote/preview/route-ca6bf35aa72661ee.js +1 -0
  128. package/dist/.next/.next/static/chunks/app/api/query/route-1466f6b7ffd8b6c0.js +1 -0
  129. package/dist/.next/.next/static/chunks/app/api/tables/[name]/route-898d3f85fc8544c4.js +1 -0
  130. package/dist/.next/.next/static/chunks/app/api/tables/route-91650359fc3735cb.js +1 -0
  131. package/dist/.next/.next/static/chunks/app/api/update/route-504d663df9124f97.js +1 -0
  132. package/dist/.next/.next/static/chunks/app/page-2c28a255a4ecd8d4.js +1 -0
  133. package/dist/.next/.next/static/chunks/app/page-3db7feef57019055.js +1 -0
  134. package/dist/.next/.next/static/css/4957328384ed5c42.css +3 -0
  135. package/dist/.next/.next/static/gc8l1G6KXOeLLOM7VJip6/_buildManifest.js +1 -0
  136. package/dist/.next/.next/static/kYsJoni86CJWDuTkc1xU6/_buildManifest.js +1 -0
  137. package/dist/.next/.next/static/kYsJoni86CJWDuTkc1xU6/_ssgManifest.js +1 -0
  138. package/dist/.next/.next/static/scC5qwQC9H7rR1groM0Q-/_ssgManifest.js +1 -0
  139. package/dist/.next/.next/static/tEHOI_-t-iqfJClNzuo9m/_buildManifest.js +1 -0
  140. package/dist/.next/.next/static/tEHOI_-t-iqfJClNzuo9m/_ssgManifest.js +1 -0
  141. package/dist/.next/.next/static/vin2VQs5pM_dH2e2_I7AN/_buildManifest.js +1 -0
  142. package/dist/.next/.next/static/vin2VQs5pM_dH2e2_I7AN/_ssgManifest.js +1 -0
  143. package/dist/.next/.next/static/wHKwQhaxin5_i06GFVDHb/_buildManifest.js +1 -0
  144. package/dist/.next/.next/static/wHKwQhaxin5_i06GFVDHb/_ssgManifest.js +1 -0
  145. package/dist/.next/.next/static/xW4MspD8XibrhXDi_q2IO/_ssgManifest.js +1 -0
  146. package/dist/.next/.next/trace +3 -3
  147. package/dist/.next/.next/types/app/api/update/route.ts +347 -0
  148. package/dist/.next/BUILD_ID +1 -1
  149. package/dist/.next/app-build-manifest.json +17 -17
  150. package/dist/.next/app-path-routes-manifest.json +1 -1
  151. package/dist/.next/build-manifest.json +2 -2
  152. package/dist/.next/cache/.rscinfo +1 -1
  153. package/dist/.next/cache/.tsbuildinfo +1 -1
  154. package/dist/.next/cache/webpack/client-production/0.pack +0 -0
  155. package/dist/.next/cache/webpack/client-production/index.pack +0 -0
  156. package/dist/.next/cache/webpack/edge-server-production/index.pack +0 -0
  157. package/dist/.next/cache/webpack/server-production/0.pack +0 -0
  158. package/dist/.next/cache/webpack/server-production/index.pack +0 -0
  159. package/dist/.next/next-minimal-server.js.nft.json +1 -1
  160. package/dist/.next/next-server.js.nft.json +1 -1
  161. package/dist/.next/prerender-manifest.json +1 -1
  162. package/dist/.next/server/app/_not-found.html +1 -1
  163. package/dist/.next/server/app/_not-found.rsc +1 -1
  164. package/dist/.next/server/app/api/cloudflare/route.js +1 -1
  165. package/dist/.next/server/app/api/databases/route.js +1 -1
  166. package/dist/.next/server/app/api/migrations/sync/route.js +3 -3
  167. package/dist/.next/server/app/api/migrations/sync/route.js.nft.json +1 -1
  168. package/dist/.next/server/app/api/migrations/sync-files/route.js +1 -1
  169. package/dist/.next/server/app/api/migrations/sync-files/route.js.nft.json +1 -1
  170. package/dist/.next/server/app/api/pull-remote/confirm/route.js +1 -1
  171. package/dist/.next/server/app/api/pull-remote/confirm/route.js.nft.json +1 -1
  172. package/dist/.next/server/app/api/pull-remote/preview/route.js +1 -1
  173. package/dist/.next/server/app/api/pull-remote/preview/route.js.nft.json +1 -1
  174. package/dist/.next/server/app/api/push-remote/confirm/route.js +2 -2
  175. package/dist/.next/server/app/api/push-remote/confirm/route.js.nft.json +1 -1
  176. package/dist/.next/server/app/api/push-remote/preview/route.js +2 -2
  177. package/dist/.next/server/app/api/push-remote/preview/route.js.nft.json +1 -1
  178. package/dist/.next/server/app/api/query/route.js +2 -2
  179. package/dist/.next/server/app/api/query/route.js.nft.json +1 -1
  180. package/dist/.next/server/app/api/tables/[name]/route.js +4 -4
  181. package/dist/.next/server/app/api/tables/route.js +2 -2
  182. package/dist/.next/server/app/index.html +1 -1
  183. package/dist/.next/server/app/index.rsc +1 -1
  184. package/dist/.next/server/app-paths-manifest.json +6 -6
  185. package/dist/.next/server/chunks/801.js +55 -0
  186. package/dist/.next/server/pages/404.html +1 -1
  187. package/dist/.next/server/pages/500.html +1 -1
  188. package/dist/.next/server/server-reference-manifest.json +1 -1
  189. package/dist/.next/static/ZwNOdZJ0LOtE0AJMNWwzY/_buildManifest.js +1 -0
  190. package/dist/.next/static/ZwNOdZJ0LOtE0AJMNWwzY/_ssgManifest.js +1 -0
  191. package/dist/.next/trace +14 -14
  192. package/dist/app/api/cloudflare/route.js +5 -1
  193. package/dist/app/api/databases/route.js +3 -4
  194. package/dist/app/api/migrations/sync/route.js +5 -3
  195. package/dist/app/api/pull-remote/confirm/route.js +24 -23
  196. package/dist/app/api/pull-remote/preview/route.js +4 -3
  197. package/dist/app/api/push-remote/preview/route.js +3 -2
  198. package/dist/app/api/query/route.js +11 -3
  199. package/dist/app/api/tables/[name]/route.js +3 -2
  200. package/dist/app/api/tables/route.js +6 -2
  201. package/dist/app/app/api/cloudflare/route.js +5 -1
  202. package/dist/app/app/api/databases/route.js +3 -4
  203. package/dist/app/app/api/migrations/sync/route.js +5 -3
  204. package/dist/app/app/api/pull-remote/confirm/route.js +24 -23
  205. package/dist/app/app/api/pull-remote/preview/route.js +4 -3
  206. package/dist/app/app/api/push-remote/preview/route.js +3 -2
  207. package/dist/app/app/api/query/route.js +11 -3
  208. package/dist/app/app/api/tables/[name]/route.js +3 -2
  209. package/dist/app/app/api/tables/route.js +6 -2
  210. package/dist/app/app/api/update/route.js +11 -0
  211. package/dist/app/app/page.jsx +7 -1
  212. package/dist/d1-studio.js +94 -58
  213. package/dist/lib/database-queue.js +34 -30
  214. package/dist/lib/find-wrangler-config.js +14 -8
  215. package/dist/lib/logger.js +11 -2
  216. package/dist/lib/migrations.js +4 -4
  217. package/dist/lib/schema-operations.js +4 -1
  218. package/dist/lib/sql-operations.js +8 -1
  219. package/package.json +3 -1
  220. package/scripts/studio.js +94 -58
  221. package/scripts/test.js +280 -82
  222. package/src/app/api/cloudflare/route.js +5 -1
  223. package/src/app/api/databases/route.js +3 -4
  224. package/src/app/api/migrations/sync/route.js +5 -3
  225. package/src/app/api/pull-remote/confirm/route.js +24 -23
  226. package/src/app/api/pull-remote/preview/route.js +4 -3
  227. package/src/app/api/push-remote/preview/route.js +3 -2
  228. package/src/app/api/query/route.js +11 -3
  229. package/src/app/api/tables/[name]/route.js +3 -2
  230. package/src/app/api/tables/route.js +6 -2
  231. package/src/app/api/update/route.js +11 -0
  232. package/src/app/page.jsx +7 -1
  233. package/src/components/update-banner.jsx +64 -0
  234. package/src/lib/database-queue.js +34 -30
  235. package/src/lib/find-wrangler-config.js +14 -8
  236. package/src/lib/logger.js +11 -2
  237. package/src/lib/migrations.js +4 -4
  238. package/src/lib/schema-operations.js +4 -1
  239. package/src/lib/sql-operations.js +8 -1
  240. package/dist/.next/.next/server/chunks/603.js +0 -55
  241. package/dist/.next/server/chunks/603.js +0 -55
  242. /package/dist/.next/.next/static/{HsZ8OanS5v86DqC9rErO- → IWRJZhjf8U8mjzz4h0VNE}/_buildManifest.js +0 -0
  243. /package/dist/.next/.next/static/{HsZ8OanS5v86DqC9rErO- → IWRJZhjf8U8mjzz4h0VNE}/_ssgManifest.js +0 -0
  244. /package/dist/.next/.next/static/{q6WmQmyONe88bMN0_jrC2 → JrwgdSDcipr0Zh7k19Cj_}/_ssgManifest.js +0 -0
  245. /package/dist/.next/{static/Tk1fnz_CXLavm23ZEeChG → .next/static/gc8l1G6KXOeLLOM7VJip6}/_ssgManifest.js +0 -0
  246. /package/dist/.next/.next/static/{q6WmQmyONe88bMN0_jrC2 → scC5qwQC9H7rR1groM0Q-}/_buildManifest.js +0 -0
  247. /package/dist/.next/{static/Tk1fnz_CXLavm23ZEeChG → .next/static/xW4MspD8XibrhXDi_q2IO}/_buildManifest.js +0 -0
@@ -0,0 +1,347 @@
1
+ // File: /Users/karenredona/Desktop/d1studio/src/app/api/update/route.js
2
+ import * as entry from '../../../../../src/app/api/update/route.js'
3
+ import type { NextRequest } from 'next/server.js'
4
+
5
+ type TEntry = typeof import('../../../../../src/app/api/update/route.js')
6
+
7
+ type SegmentParams<T extends Object = any> = T extends Record<string, any>
8
+ ? { [K in keyof T]: T[K] extends string ? string | string[] | undefined : never }
9
+ : T
10
+
11
+ // Check that the entry is a valid entry
12
+ checkFields<Diff<{
13
+ GET?: Function
14
+ HEAD?: Function
15
+ OPTIONS?: Function
16
+ POST?: Function
17
+ PUT?: Function
18
+ DELETE?: Function
19
+ PATCH?: Function
20
+ config?: {}
21
+ generateStaticParams?: Function
22
+ revalidate?: RevalidateRange<TEntry> | false
23
+ dynamic?: 'auto' | 'force-dynamic' | 'error' | 'force-static'
24
+ dynamicParams?: boolean
25
+ fetchCache?: 'auto' | 'force-no-store' | 'only-no-store' | 'default-no-store' | 'default-cache' | 'only-cache' | 'force-cache'
26
+ preferredRegion?: 'auto' | 'global' | 'home' | string | string[]
27
+ runtime?: 'nodejs' | 'experimental-edge' | 'edge'
28
+ maxDuration?: number
29
+
30
+ }, TEntry, ''>>()
31
+
32
+ type RouteContext = { params: Promise<SegmentParams> }
33
+ // Check the prop type of the entry function
34
+ if ('GET' in entry) {
35
+ checkFields<
36
+ Diff<
37
+ ParamCheck<Request | NextRequest>,
38
+ {
39
+ __tag__: 'GET'
40
+ __param_position__: 'first'
41
+ __param_type__: FirstArg<MaybeField<TEntry, 'GET'>>
42
+ },
43
+ 'GET'
44
+ >
45
+ >()
46
+ checkFields<
47
+ Diff<
48
+ ParamCheck<RouteContext>,
49
+ {
50
+ __tag__: 'GET'
51
+ __param_position__: 'second'
52
+ __param_type__: SecondArg<MaybeField<TEntry, 'GET'>>
53
+ },
54
+ 'GET'
55
+ >
56
+ >()
57
+
58
+ checkFields<
59
+ Diff<
60
+ {
61
+ __tag__: 'GET',
62
+ __return_type__: Response | void | never | Promise<Response | void | never>
63
+ },
64
+ {
65
+ __tag__: 'GET',
66
+ __return_type__: ReturnType<MaybeField<TEntry, 'GET'>>
67
+ },
68
+ 'GET'
69
+ >
70
+ >()
71
+ }
72
+ // Check the prop type of the entry function
73
+ if ('HEAD' in entry) {
74
+ checkFields<
75
+ Diff<
76
+ ParamCheck<Request | NextRequest>,
77
+ {
78
+ __tag__: 'HEAD'
79
+ __param_position__: 'first'
80
+ __param_type__: FirstArg<MaybeField<TEntry, 'HEAD'>>
81
+ },
82
+ 'HEAD'
83
+ >
84
+ >()
85
+ checkFields<
86
+ Diff<
87
+ ParamCheck<RouteContext>,
88
+ {
89
+ __tag__: 'HEAD'
90
+ __param_position__: 'second'
91
+ __param_type__: SecondArg<MaybeField<TEntry, 'HEAD'>>
92
+ },
93
+ 'HEAD'
94
+ >
95
+ >()
96
+
97
+ checkFields<
98
+ Diff<
99
+ {
100
+ __tag__: 'HEAD',
101
+ __return_type__: Response | void | never | Promise<Response | void | never>
102
+ },
103
+ {
104
+ __tag__: 'HEAD',
105
+ __return_type__: ReturnType<MaybeField<TEntry, 'HEAD'>>
106
+ },
107
+ 'HEAD'
108
+ >
109
+ >()
110
+ }
111
+ // Check the prop type of the entry function
112
+ if ('OPTIONS' in entry) {
113
+ checkFields<
114
+ Diff<
115
+ ParamCheck<Request | NextRequest>,
116
+ {
117
+ __tag__: 'OPTIONS'
118
+ __param_position__: 'first'
119
+ __param_type__: FirstArg<MaybeField<TEntry, 'OPTIONS'>>
120
+ },
121
+ 'OPTIONS'
122
+ >
123
+ >()
124
+ checkFields<
125
+ Diff<
126
+ ParamCheck<RouteContext>,
127
+ {
128
+ __tag__: 'OPTIONS'
129
+ __param_position__: 'second'
130
+ __param_type__: SecondArg<MaybeField<TEntry, 'OPTIONS'>>
131
+ },
132
+ 'OPTIONS'
133
+ >
134
+ >()
135
+
136
+ checkFields<
137
+ Diff<
138
+ {
139
+ __tag__: 'OPTIONS',
140
+ __return_type__: Response | void | never | Promise<Response | void | never>
141
+ },
142
+ {
143
+ __tag__: 'OPTIONS',
144
+ __return_type__: ReturnType<MaybeField<TEntry, 'OPTIONS'>>
145
+ },
146
+ 'OPTIONS'
147
+ >
148
+ >()
149
+ }
150
+ // Check the prop type of the entry function
151
+ if ('POST' in entry) {
152
+ checkFields<
153
+ Diff<
154
+ ParamCheck<Request | NextRequest>,
155
+ {
156
+ __tag__: 'POST'
157
+ __param_position__: 'first'
158
+ __param_type__: FirstArg<MaybeField<TEntry, 'POST'>>
159
+ },
160
+ 'POST'
161
+ >
162
+ >()
163
+ checkFields<
164
+ Diff<
165
+ ParamCheck<RouteContext>,
166
+ {
167
+ __tag__: 'POST'
168
+ __param_position__: 'second'
169
+ __param_type__: SecondArg<MaybeField<TEntry, 'POST'>>
170
+ },
171
+ 'POST'
172
+ >
173
+ >()
174
+
175
+ checkFields<
176
+ Diff<
177
+ {
178
+ __tag__: 'POST',
179
+ __return_type__: Response | void | never | Promise<Response | void | never>
180
+ },
181
+ {
182
+ __tag__: 'POST',
183
+ __return_type__: ReturnType<MaybeField<TEntry, 'POST'>>
184
+ },
185
+ 'POST'
186
+ >
187
+ >()
188
+ }
189
+ // Check the prop type of the entry function
190
+ if ('PUT' in entry) {
191
+ checkFields<
192
+ Diff<
193
+ ParamCheck<Request | NextRequest>,
194
+ {
195
+ __tag__: 'PUT'
196
+ __param_position__: 'first'
197
+ __param_type__: FirstArg<MaybeField<TEntry, 'PUT'>>
198
+ },
199
+ 'PUT'
200
+ >
201
+ >()
202
+ checkFields<
203
+ Diff<
204
+ ParamCheck<RouteContext>,
205
+ {
206
+ __tag__: 'PUT'
207
+ __param_position__: 'second'
208
+ __param_type__: SecondArg<MaybeField<TEntry, 'PUT'>>
209
+ },
210
+ 'PUT'
211
+ >
212
+ >()
213
+
214
+ checkFields<
215
+ Diff<
216
+ {
217
+ __tag__: 'PUT',
218
+ __return_type__: Response | void | never | Promise<Response | void | never>
219
+ },
220
+ {
221
+ __tag__: 'PUT',
222
+ __return_type__: ReturnType<MaybeField<TEntry, 'PUT'>>
223
+ },
224
+ 'PUT'
225
+ >
226
+ >()
227
+ }
228
+ // Check the prop type of the entry function
229
+ if ('DELETE' in entry) {
230
+ checkFields<
231
+ Diff<
232
+ ParamCheck<Request | NextRequest>,
233
+ {
234
+ __tag__: 'DELETE'
235
+ __param_position__: 'first'
236
+ __param_type__: FirstArg<MaybeField<TEntry, 'DELETE'>>
237
+ },
238
+ 'DELETE'
239
+ >
240
+ >()
241
+ checkFields<
242
+ Diff<
243
+ ParamCheck<RouteContext>,
244
+ {
245
+ __tag__: 'DELETE'
246
+ __param_position__: 'second'
247
+ __param_type__: SecondArg<MaybeField<TEntry, 'DELETE'>>
248
+ },
249
+ 'DELETE'
250
+ >
251
+ >()
252
+
253
+ checkFields<
254
+ Diff<
255
+ {
256
+ __tag__: 'DELETE',
257
+ __return_type__: Response | void | never | Promise<Response | void | never>
258
+ },
259
+ {
260
+ __tag__: 'DELETE',
261
+ __return_type__: ReturnType<MaybeField<TEntry, 'DELETE'>>
262
+ },
263
+ 'DELETE'
264
+ >
265
+ >()
266
+ }
267
+ // Check the prop type of the entry function
268
+ if ('PATCH' in entry) {
269
+ checkFields<
270
+ Diff<
271
+ ParamCheck<Request | NextRequest>,
272
+ {
273
+ __tag__: 'PATCH'
274
+ __param_position__: 'first'
275
+ __param_type__: FirstArg<MaybeField<TEntry, 'PATCH'>>
276
+ },
277
+ 'PATCH'
278
+ >
279
+ >()
280
+ checkFields<
281
+ Diff<
282
+ ParamCheck<RouteContext>,
283
+ {
284
+ __tag__: 'PATCH'
285
+ __param_position__: 'second'
286
+ __param_type__: SecondArg<MaybeField<TEntry, 'PATCH'>>
287
+ },
288
+ 'PATCH'
289
+ >
290
+ >()
291
+
292
+ checkFields<
293
+ Diff<
294
+ {
295
+ __tag__: 'PATCH',
296
+ __return_type__: Response | void | never | Promise<Response | void | never>
297
+ },
298
+ {
299
+ __tag__: 'PATCH',
300
+ __return_type__: ReturnType<MaybeField<TEntry, 'PATCH'>>
301
+ },
302
+ 'PATCH'
303
+ >
304
+ >()
305
+ }
306
+
307
+ // Check the arguments and return type of the generateStaticParams function
308
+ if ('generateStaticParams' in entry) {
309
+ checkFields<Diff<{ params: SegmentParams }, FirstArg<MaybeField<TEntry, 'generateStaticParams'>>, 'generateStaticParams'>>()
310
+ checkFields<Diff<{ __tag__: 'generateStaticParams', __return_type__: any[] | Promise<any[]> }, { __tag__: 'generateStaticParams', __return_type__: ReturnType<MaybeField<TEntry, 'generateStaticParams'>> }>>()
311
+ }
312
+
313
+ export interface PageProps {
314
+ params?: Promise<SegmentParams>
315
+ searchParams?: Promise<any>
316
+ }
317
+ export interface LayoutProps {
318
+ children?: React.ReactNode
319
+
320
+ params?: Promise<SegmentParams>
321
+ }
322
+
323
+ // =============
324
+ // Utility types
325
+ type RevalidateRange<T> = T extends { revalidate: any } ? NonNegative<T['revalidate']> : never
326
+
327
+ // If T is unknown or any, it will be an empty {} type. Otherwise, it will be the same as Omit<T, keyof Base>.
328
+ type OmitWithTag<T, K extends keyof any, _M> = Omit<T, K>
329
+ type Diff<Base, T extends Base, Message extends string = ''> = 0 extends (1 & T) ? {} : OmitWithTag<T, keyof Base, Message>
330
+
331
+ type FirstArg<T extends Function> = T extends (...args: [infer T, any]) => any ? unknown extends T ? any : T : never
332
+ type SecondArg<T extends Function> = T extends (...args: [any, infer T]) => any ? unknown extends T ? any : T : never
333
+ type MaybeField<T, K extends string> = T extends { [k in K]: infer G } ? G extends Function ? G : never : never
334
+
335
+ type ParamCheck<T> = {
336
+ __tag__: string
337
+ __param_position__: string
338
+ __param_type__: T
339
+ }
340
+
341
+ function checkFields<_ extends { [k in keyof any]: never }>() {}
342
+
343
+ // https://github.com/sindresorhus/type-fest
344
+ type Numeric = number | bigint
345
+ type Zero = 0 | 0n
346
+ type Negative<T extends Numeric> = T extends Zero ? never : `${T}` extends `-${string}` ? T : never
347
+ type NonNegative<T extends Numeric> = T extends Zero ? T : Negative<T> extends never ? T : '__invalid_negative_number__'
@@ -1 +1 @@
1
- Tk1fnz_CXLavm23ZEeChG
1
+ ZwNOdZJ0LOtE0AJMNWwzY
@@ -7,13 +7,6 @@
7
7
  "static/chunks/main-app-d36cdfb402b40f13.js",
8
8
  "static/chunks/app/_not-found/page-b786c3dd79ad15a5.js"
9
9
  ],
10
- "/api/migrations/sync/route": [
11
- "static/chunks/webpack-c76ac1e586b2802a.js",
12
- "static/chunks/4bd1b696-8c908eb707f85a27.js",
13
- "static/chunks/517-3b698a5d3da06ff7.js",
14
- "static/chunks/main-app-d36cdfb402b40f13.js",
15
- "static/chunks/app/api/migrations/sync/route-03766b3afcf043ba.js"
16
- ],
17
10
  "/api/cloudflare/route": [
18
11
  "static/chunks/webpack-c76ac1e586b2802a.js",
19
12
  "static/chunks/4bd1b696-8c908eb707f85a27.js",
@@ -53,19 +46,19 @@
53
46
  "static/chunks/main-app-d36cdfb402b40f13.js",
54
47
  "static/chunks/app/api/pull-remote/confirm/route-7e05bb8920127abe.js"
55
48
  ],
56
- "/api/query/route": [
49
+ "/api/migrations/sync/route": [
57
50
  "static/chunks/webpack-c76ac1e586b2802a.js",
58
51
  "static/chunks/4bd1b696-8c908eb707f85a27.js",
59
52
  "static/chunks/517-3b698a5d3da06ff7.js",
60
53
  "static/chunks/main-app-d36cdfb402b40f13.js",
61
- "static/chunks/app/api/query/route-e90d0030a5083e20.js"
54
+ "static/chunks/app/api/migrations/sync/route-03766b3afcf043ba.js"
62
55
  ],
63
- "/api/push-remote/preview/route": [
56
+ "/api/pull-remote/preview/route": [
64
57
  "static/chunks/webpack-c76ac1e586b2802a.js",
65
58
  "static/chunks/4bd1b696-8c908eb707f85a27.js",
66
59
  "static/chunks/517-3b698a5d3da06ff7.js",
67
60
  "static/chunks/main-app-d36cdfb402b40f13.js",
68
- "static/chunks/app/api/push-remote/preview/route-a798679c67374552.js"
61
+ "static/chunks/app/api/pull-remote/preview/route-0fa15f783e8a306c.js"
69
62
  ],
70
63
  "/api/push-remote/confirm/route": [
71
64
  "static/chunks/webpack-c76ac1e586b2802a.js",
@@ -74,26 +67,26 @@
74
67
  "static/chunks/main-app-d36cdfb402b40f13.js",
75
68
  "static/chunks/app/api/push-remote/confirm/route-96691f1880e4ed14.js"
76
69
  ],
77
- "/api/pull-remote/preview/route": [
70
+ "/api/push-remote/preview/route": [
78
71
  "static/chunks/webpack-c76ac1e586b2802a.js",
79
72
  "static/chunks/4bd1b696-8c908eb707f85a27.js",
80
73
  "static/chunks/517-3b698a5d3da06ff7.js",
81
74
  "static/chunks/main-app-d36cdfb402b40f13.js",
82
- "static/chunks/app/api/pull-remote/preview/route-0fa15f783e8a306c.js"
75
+ "static/chunks/app/api/push-remote/preview/route-a798679c67374552.js"
83
76
  ],
84
- "/api/tables/route": [
77
+ "/api/query/route": [
85
78
  "static/chunks/webpack-c76ac1e586b2802a.js",
86
79
  "static/chunks/4bd1b696-8c908eb707f85a27.js",
87
80
  "static/chunks/517-3b698a5d3da06ff7.js",
88
81
  "static/chunks/main-app-d36cdfb402b40f13.js",
89
- "static/chunks/app/api/tables/route-3772b4f480c4b4a4.js"
82
+ "static/chunks/app/api/query/route-e90d0030a5083e20.js"
90
83
  ],
91
- "/api/tables/[name]/route": [
84
+ "/api/tables/route": [
92
85
  "static/chunks/webpack-c76ac1e586b2802a.js",
93
86
  "static/chunks/4bd1b696-8c908eb707f85a27.js",
94
87
  "static/chunks/517-3b698a5d3da06ff7.js",
95
88
  "static/chunks/main-app-d36cdfb402b40f13.js",
96
- "static/chunks/app/api/tables/[name]/route-1efe63e73b480e58.js"
89
+ "static/chunks/app/api/tables/route-3772b4f480c4b4a4.js"
97
90
  ],
98
91
  "/page": [
99
92
  "static/chunks/webpack-c76ac1e586b2802a.js",
@@ -104,6 +97,13 @@
104
97
  "static/chunks/422-6fa3c14fc64ad67b.js",
105
98
  "static/chunks/735-c9144179c6bd7d06.js",
106
99
  "static/chunks/app/page-79049bfa6cc07e11.js"
100
+ ],
101
+ "/api/tables/[name]/route": [
102
+ "static/chunks/webpack-c76ac1e586b2802a.js",
103
+ "static/chunks/4bd1b696-8c908eb707f85a27.js",
104
+ "static/chunks/517-3b698a5d3da06ff7.js",
105
+ "static/chunks/main-app-d36cdfb402b40f13.js",
106
+ "static/chunks/app/api/tables/[name]/route-1efe63e73b480e58.js"
107
107
  ]
108
108
  }
109
109
  }
@@ -1 +1 @@
1
- {"/api/migrations/sync/route":"/api/migrations/sync","/api/cloudflare/route":"/api/cloudflare","/_not-found/page":"/_not-found","/api/migrations/sync-files/route":"/api/migrations/sync-files","/api/databases/route":"/api/databases","/api/pull-remote/confirm/route":"/api/pull-remote/confirm","/api/query/route":"/api/query","/api/push-remote/preview/route":"/api/push-remote/preview","/api/push-remote/confirm/route":"/api/push-remote/confirm","/api/pull-remote/preview/route":"/api/pull-remote/preview","/api/tables/route":"/api/tables","/api/tables/[name]/route":"/api/tables/[name]","/page":"/"}
1
+ {"/api/cloudflare/route":"/api/cloudflare","/_not-found/page":"/_not-found","/api/migrations/sync-files/route":"/api/migrations/sync-files","/api/databases/route":"/api/databases","/api/pull-remote/confirm/route":"/api/pull-remote/confirm","/api/migrations/sync/route":"/api/migrations/sync","/api/pull-remote/preview/route":"/api/pull-remote/preview","/api/push-remote/confirm/route":"/api/push-remote/confirm","/api/push-remote/preview/route":"/api/push-remote/preview","/api/query/route":"/api/query","/api/tables/route":"/api/tables","/page":"/","/api/tables/[name]/route":"/api/tables/[name]"}
@@ -5,8 +5,8 @@
5
5
  "devFiles": [],
6
6
  "ampDevFiles": [],
7
7
  "lowPriorityFiles": [
8
- "static/Tk1fnz_CXLavm23ZEeChG/_buildManifest.js",
9
- "static/Tk1fnz_CXLavm23ZEeChG/_ssgManifest.js"
8
+ "static/ZwNOdZJ0LOtE0AJMNWwzY/_buildManifest.js",
9
+ "static/ZwNOdZJ0LOtE0AJMNWwzY/_ssgManifest.js"
10
10
  ],
11
11
  "rootMainFiles": [
12
12
  "static/chunks/webpack-c76ac1e586b2802a.js",
@@ -1 +1 @@
1
- {"encryption.key":"68HiSTEtbGI9XRiB6Urj3iM3Aub8VpZstSFpma1pda8=","encryption.expire_at":1741247711636}
1
+ {"encryption.key":"7A171S4q7P1nVD8e90wQ5OZ8ha7rgYNSXoD7gCOGvPw=","encryption.expire_at":1741411210116}