convex-cms 0.0.1 → 0.0.3

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 (267) hide show
  1. package/LICENSE +190 -0
  2. package/README.md +99 -0
  3. package/admin-dist/nitro.json +15 -0
  4. package/admin-dist/public/assets/CmsEmptyState-CRswfTzk.js +5 -0
  5. package/admin-dist/public/assets/CmsPageHeader-CirpXndm.js +1 -0
  6. package/admin-dist/public/assets/CmsStatusBadge-CbEUpQu-.js +1 -0
  7. package/admin-dist/public/assets/CmsToolbar-BI2nZOXp.js +1 -0
  8. package/admin-dist/public/assets/ContentEntryEditor-CBeCyK_m.js +4 -0
  9. package/admin-dist/public/assets/ErrorState-BIVaWmom.js +1 -0
  10. package/admin-dist/public/assets/TaxonomyFilter-ChaY6Y_x.js +1 -0
  11. package/admin-dist/public/assets/_contentTypeId-DQ8k_Rvw.js +1 -0
  12. package/admin-dist/public/assets/_entryId-CKU_glsK.js +1 -0
  13. package/admin-dist/public/assets/alert-BXjTqrwQ.js +1 -0
  14. package/admin-dist/public/assets/badge-hvUOzpVZ.js +1 -0
  15. package/admin-dist/public/assets/circle-check-big-CF_pR17r.js +1 -0
  16. package/admin-dist/public/assets/command-DU82cJlt.js +1 -0
  17. package/admin-dist/public/assets/content-_LXl3pp7.js +1 -0
  18. package/admin-dist/public/assets/content-types-KjxaXGxY.js +2 -0
  19. package/admin-dist/public/assets/globals-CS6BZ0zp.css +1 -0
  20. package/admin-dist/public/assets/index-DNGIZHL-.js +1 -0
  21. package/admin-dist/public/assets/label-KNtpL71g.js +1 -0
  22. package/admin-dist/public/assets/link-2-Bw2aI4V4.js +1 -0
  23. package/admin-dist/public/assets/list-sYepHjt_.js +1 -0
  24. package/admin-dist/public/assets/main-CKj5yfEi.js +97 -0
  25. package/admin-dist/public/assets/media-Bkrkffm7.js +1 -0
  26. package/admin-dist/public/assets/new._contentTypeId-C3LstjNs.js +1 -0
  27. package/admin-dist/public/assets/plus-DUn8v_Xf.js +1 -0
  28. package/admin-dist/public/assets/rotate-ccw-DJEoHcRI.js +1 -0
  29. package/admin-dist/public/assets/scroll-area-DfIlT0in.js +1 -0
  30. package/admin-dist/public/assets/search-MuAUDJKR.js +1 -0
  31. package/admin-dist/public/assets/select-BD29IXCI.js +1 -0
  32. package/admin-dist/public/assets/settings-DmMyn_6A.js +1 -0
  33. package/admin-dist/public/assets/switch-h3Rrnl5i.js +1 -0
  34. package/admin-dist/public/assets/tabs-imc8h-Dp.js +1 -0
  35. package/admin-dist/public/assets/taxonomies-dAsrT65H.js +1 -0
  36. package/admin-dist/public/assets/textarea-BTy7nwzR.js +1 -0
  37. package/admin-dist/public/assets/trash-SAWKZZHv.js +1 -0
  38. package/admin-dist/public/assets/triangle-alert-E52Vfeuh.js +1 -0
  39. package/admin-dist/public/assets/useBreadcrumbLabel-BECBMCzM.js +1 -0
  40. package/admin-dist/public/assets/usePermissions-Basjs9BT.js +1 -0
  41. package/admin-dist/public/favicon.ico +0 -0
  42. package/admin-dist/server/_chunks/_libs/@date-fns/tz.mjs +217 -0
  43. package/admin-dist/server/_chunks/_libs/@floating-ui/core.mjs +719 -0
  44. package/admin-dist/server/_chunks/_libs/@floating-ui/dom.mjs +622 -0
  45. package/admin-dist/server/_chunks/_libs/@floating-ui/react-dom.mjs +292 -0
  46. package/admin-dist/server/_chunks/_libs/@floating-ui/utils.mjs +320 -0
  47. package/admin-dist/server/_chunks/_libs/@radix-ui/number.mjs +6 -0
  48. package/admin-dist/server/_chunks/_libs/@radix-ui/primitive.mjs +11 -0
  49. package/admin-dist/server/_chunks/_libs/@radix-ui/react-arrow.mjs +23 -0
  50. package/admin-dist/server/_chunks/_libs/@radix-ui/react-avatar.mjs +119 -0
  51. package/admin-dist/server/_chunks/_libs/@radix-ui/react-checkbox.mjs +270 -0
  52. package/admin-dist/server/_chunks/_libs/@radix-ui/react-collection.mjs +69 -0
  53. package/admin-dist/server/_chunks/_libs/@radix-ui/react-compose-refs.mjs +39 -0
  54. package/admin-dist/server/_chunks/_libs/@radix-ui/react-context.mjs +137 -0
  55. package/admin-dist/server/_chunks/_libs/@radix-ui/react-dialog.mjs +325 -0
  56. package/admin-dist/server/_chunks/_libs/@radix-ui/react-direction.mjs +9 -0
  57. package/admin-dist/server/_chunks/_libs/@radix-ui/react-dismissable-layer.mjs +210 -0
  58. package/admin-dist/server/_chunks/_libs/@radix-ui/react-dropdown-menu.mjs +253 -0
  59. package/admin-dist/server/_chunks/_libs/@radix-ui/react-focus-guards.mjs +29 -0
  60. package/admin-dist/server/_chunks/_libs/@radix-ui/react-focus-scope.mjs +206 -0
  61. package/admin-dist/server/_chunks/_libs/@radix-ui/react-id.mjs +14 -0
  62. package/admin-dist/server/_chunks/_libs/@radix-ui/react-label.mjs +23 -0
  63. package/admin-dist/server/_chunks/_libs/@radix-ui/react-menu.mjs +812 -0
  64. package/admin-dist/server/_chunks/_libs/@radix-ui/react-popover.mjs +300 -0
  65. package/admin-dist/server/_chunks/_libs/@radix-ui/react-popper.mjs +286 -0
  66. package/admin-dist/server/_chunks/_libs/@radix-ui/react-portal.mjs +16 -0
  67. package/admin-dist/server/_chunks/_libs/@radix-ui/react-presence.mjs +128 -0
  68. package/admin-dist/server/_chunks/_libs/@radix-ui/react-primitive.mjs +141 -0
  69. package/admin-dist/server/_chunks/_libs/@radix-ui/react-roving-focus.mjs +224 -0
  70. package/admin-dist/server/_chunks/_libs/@radix-ui/react-scroll-area.mjs +721 -0
  71. package/admin-dist/server/_chunks/_libs/@radix-ui/react-select.mjs +1163 -0
  72. package/admin-dist/server/_chunks/_libs/@radix-ui/react-separator.mjs +28 -0
  73. package/admin-dist/server/_chunks/_libs/@radix-ui/react-slot.mjs +601 -0
  74. package/admin-dist/server/_chunks/_libs/@radix-ui/react-switch.mjs +152 -0
  75. package/admin-dist/server/_chunks/_libs/@radix-ui/react-tabs.mjs +189 -0
  76. package/admin-dist/server/_chunks/_libs/@radix-ui/react-use-callback-ref.mjs +11 -0
  77. package/admin-dist/server/_chunks/_libs/@radix-ui/react-use-controllable-state.mjs +69 -0
  78. package/admin-dist/server/_chunks/_libs/@radix-ui/react-use-effect-event.mjs +1 -0
  79. package/admin-dist/server/_chunks/_libs/@radix-ui/react-use-escape-keydown.mjs +17 -0
  80. package/admin-dist/server/_chunks/_libs/@radix-ui/react-use-is-hydrated.mjs +15 -0
  81. package/admin-dist/server/_chunks/_libs/@radix-ui/react-use-layout-effect.mjs +6 -0
  82. package/admin-dist/server/_chunks/_libs/@radix-ui/react-use-previous.mjs +14 -0
  83. package/admin-dist/server/_chunks/_libs/@radix-ui/react-use-size.mjs +39 -0
  84. package/admin-dist/server/_chunks/_libs/@radix-ui/react-visually-hidden.mjs +33 -0
  85. package/admin-dist/server/_chunks/_libs/@tanstack/history.mjs +409 -0
  86. package/admin-dist/server/_chunks/_libs/@tanstack/react-router.mjs +1711 -0
  87. package/admin-dist/server/_chunks/_libs/@tanstack/react-store.mjs +56 -0
  88. package/admin-dist/server/_chunks/_libs/@tanstack/router-core.mjs +4829 -0
  89. package/admin-dist/server/_chunks/_libs/@tanstack/store.mjs +134 -0
  90. package/admin-dist/server/_chunks/_libs/react-dom.mjs +10781 -0
  91. package/admin-dist/server/_chunks/_libs/react.mjs +513 -0
  92. package/admin-dist/server/_libs/aria-hidden.mjs +122 -0
  93. package/admin-dist/server/_libs/class-variance-authority.mjs +44 -0
  94. package/admin-dist/server/_libs/clsx.mjs +16 -0
  95. package/admin-dist/server/_libs/cmdk.mjs +315 -0
  96. package/admin-dist/server/_libs/convex.mjs +4841 -0
  97. package/admin-dist/server/_libs/cookie-es.mjs +58 -0
  98. package/admin-dist/server/_libs/croner.mjs +1 -0
  99. package/admin-dist/server/_libs/crossws.mjs +1 -0
  100. package/admin-dist/server/_libs/date-fns.mjs +1716 -0
  101. package/admin-dist/server/_libs/detect-node-es.mjs +1 -0
  102. package/admin-dist/server/_libs/get-nonce.mjs +9 -0
  103. package/admin-dist/server/_libs/h3-v2.mjs +277 -0
  104. package/admin-dist/server/_libs/h3.mjs +401 -0
  105. package/admin-dist/server/_libs/hookable.mjs +1 -0
  106. package/admin-dist/server/_libs/isbot.mjs +20 -0
  107. package/admin-dist/server/_libs/lucide-react.mjs +850 -0
  108. package/admin-dist/server/_libs/ohash.mjs +1 -0
  109. package/admin-dist/server/_libs/react-day-picker.mjs +2201 -0
  110. package/admin-dist/server/_libs/react-remove-scroll-bar.mjs +82 -0
  111. package/admin-dist/server/_libs/react-remove-scroll.mjs +328 -0
  112. package/admin-dist/server/_libs/react-style-singleton.mjs +69 -0
  113. package/admin-dist/server/_libs/rou3.mjs +8 -0
  114. package/admin-dist/server/_libs/seroval-plugins.mjs +58 -0
  115. package/admin-dist/server/_libs/seroval.mjs +1765 -0
  116. package/admin-dist/server/_libs/srvx.mjs +719 -0
  117. package/admin-dist/server/_libs/tailwind-merge.mjs +3010 -0
  118. package/admin-dist/server/_libs/tiny-invariant.mjs +12 -0
  119. package/admin-dist/server/_libs/tiny-warning.mjs +5 -0
  120. package/admin-dist/server/_libs/tslib.mjs +39 -0
  121. package/admin-dist/server/_libs/ufo.mjs +54 -0
  122. package/admin-dist/server/_libs/unctx.mjs +1 -0
  123. package/admin-dist/server/_libs/unstorage.mjs +1 -0
  124. package/admin-dist/server/_libs/use-callback-ref.mjs +66 -0
  125. package/admin-dist/server/_libs/use-sidecar.mjs +106 -0
  126. package/admin-dist/server/_libs/use-sync-external-store.mjs +139 -0
  127. package/admin-dist/server/_libs/zod.mjs +4223 -0
  128. package/admin-dist/server/_ssr/CmsEmptyState-DU7-7-mV.mjs +290 -0
  129. package/admin-dist/server/_ssr/CmsPageHeader-CseW0AHm.mjs +24 -0
  130. package/admin-dist/server/_ssr/CmsStatusBadge-B_pi4KCp.mjs +127 -0
  131. package/admin-dist/server/_ssr/CmsToolbar-X75ex6ek.mjs +49 -0
  132. package/admin-dist/server/_ssr/ContentEntryEditor-CepusRsA.mjs +3720 -0
  133. package/admin-dist/server/_ssr/ErrorState-cI-bKLez.mjs +89 -0
  134. package/admin-dist/server/_ssr/TaxonomyFilter-Bwrq0-cz.mjs +188 -0
  135. package/admin-dist/server/_ssr/_contentTypeId-BqYKEcLr.mjs +379 -0
  136. package/admin-dist/server/_ssr/_entryId-CRfnqeDf.mjs +161 -0
  137. package/admin-dist/server/_ssr/_tanstack-start-manifest_v-BwDlABVk.mjs +4 -0
  138. package/admin-dist/server/_ssr/alert-CVt45UUP.mjs +92 -0
  139. package/admin-dist/server/_ssr/badge-6BsP37vG.mjs +125 -0
  140. package/admin-dist/server/_ssr/command-fy8epIKf.mjs +128 -0
  141. package/admin-dist/server/_ssr/config.server-D7JHDcDv.mjs +117 -0
  142. package/admin-dist/server/_ssr/content-B5RhL7uW.mjs +532 -0
  143. package/admin-dist/server/_ssr/content-types-BIOqCQYN.mjs +1166 -0
  144. package/admin-dist/server/_ssr/index-DHSHDPt1.mjs +193 -0
  145. package/admin-dist/server/_ssr/index.mjs +1275 -0
  146. package/admin-dist/server/_ssr/label-C8Dko1j7.mjs +22 -0
  147. package/admin-dist/server/_ssr/media-CSx3XttC.mjs +1832 -0
  148. package/admin-dist/server/_ssr/new._contentTypeId-DzanEZQM.mjs +144 -0
  149. package/admin-dist/server/_ssr/router-DDWcF-kt.mjs +1556 -0
  150. package/admin-dist/server/_ssr/scroll-area-bjPYwhXN.mjs +59 -0
  151. package/admin-dist/server/_ssr/select-BUhDDf4T.mjs +142 -0
  152. package/admin-dist/server/_ssr/settings-DAsxnw2q.mjs +348 -0
  153. package/admin-dist/server/_ssr/start-HYkvq4Ni.mjs +4 -0
  154. package/admin-dist/server/_ssr/switch-BgyRtQ1Z.mjs +31 -0
  155. package/admin-dist/server/_ssr/tabs-DzMdRB1A.mjs +628 -0
  156. package/admin-dist/server/_ssr/taxonomies-C8j8g5Q5.mjs +915 -0
  157. package/admin-dist/server/_ssr/textarea-9jNeYJSc.mjs +18 -0
  158. package/admin-dist/server/_ssr/trash-DYMxwhZB.mjs +291 -0
  159. package/admin-dist/server/_ssr/useBreadcrumbLabel-FNSAr2Ha.mjs +16 -0
  160. package/admin-dist/server/_ssr/usePermissions-BJGGahrJ.mjs +68 -0
  161. package/admin-dist/server/favicon.ico +0 -0
  162. package/admin-dist/server/index.mjs +627 -0
  163. package/dist/cli/index.js +0 -0
  164. package/dist/client/admin-config.d.ts +0 -1
  165. package/dist/client/admin-config.d.ts.map +1 -1
  166. package/dist/client/admin-config.js +0 -1
  167. package/dist/client/admin-config.js.map +1 -1
  168. package/dist/client/adminApi.d.ts.map +1 -1
  169. package/dist/client/agentTools.d.ts +1237 -135
  170. package/dist/client/agentTools.d.ts.map +1 -1
  171. package/dist/client/agentTools.js +33 -9
  172. package/dist/client/agentTools.js.map +1 -1
  173. package/dist/client/index.d.ts +1 -1
  174. package/dist/client/index.d.ts.map +1 -1
  175. package/dist/client/index.js.map +1 -1
  176. package/dist/component/_generated/component.d.ts +9 -0
  177. package/dist/component/_generated/component.d.ts.map +1 -1
  178. package/dist/component/mediaAssets.d.ts +35 -0
  179. package/dist/component/mediaAssets.d.ts.map +1 -1
  180. package/dist/component/mediaAssets.js +81 -0
  181. package/dist/component/mediaAssets.js.map +1 -1
  182. package/dist/test.d.ts.map +1 -1
  183. package/dist/test.js +2 -1
  184. package/dist/test.js.map +1 -1
  185. package/package.json +24 -9
  186. package/dist/component/auditLog.d.ts +0 -410
  187. package/dist/component/auditLog.d.ts.map +0 -1
  188. package/dist/component/auditLog.js +0 -607
  189. package/dist/component/auditLog.js.map +0 -1
  190. package/dist/component/types.d.ts +0 -4
  191. package/dist/component/types.d.ts.map +0 -1
  192. package/dist/component/types.js +0 -2
  193. package/dist/component/types.js.map +0 -1
  194. package/src/cli/commands/admin.ts +0 -104
  195. package/src/cli/index.ts +0 -21
  196. package/src/cli/utils/detectConvexUrl.ts +0 -54
  197. package/src/cli/utils/openBrowser.ts +0 -16
  198. package/src/client/admin-config.ts +0 -138
  199. package/src/client/adminApi.ts +0 -942
  200. package/src/client/agentTools.ts +0 -1311
  201. package/src/client/argTypes.ts +0 -316
  202. package/src/client/field-types.ts +0 -187
  203. package/src/client/index.ts +0 -1301
  204. package/src/client/queryBuilder.ts +0 -1100
  205. package/src/client/schema/codegen.ts +0 -500
  206. package/src/client/schema/defineContentType.ts +0 -501
  207. package/src/client/schema/index.ts +0 -169
  208. package/src/client/schema/schemaDrift.ts +0 -574
  209. package/src/client/schema/typedClient.ts +0 -688
  210. package/src/client/schema/types.ts +0 -666
  211. package/src/client/types.ts +0 -723
  212. package/src/client/workflows.ts +0 -141
  213. package/src/client/wrapper.ts +0 -4304
  214. package/src/component/_generated/api.ts +0 -140
  215. package/src/component/_generated/component.ts +0 -5029
  216. package/src/component/_generated/dataModel.ts +0 -60
  217. package/src/component/_generated/server.ts +0 -156
  218. package/src/component/authorization.ts +0 -647
  219. package/src/component/authorizationHooks.ts +0 -668
  220. package/src/component/bulkOperations.ts +0 -687
  221. package/src/component/contentEntries.ts +0 -1976
  222. package/src/component/contentEntryMutations.ts +0 -1223
  223. package/src/component/contentEntryValidation.ts +0 -707
  224. package/src/component/contentLock.ts +0 -550
  225. package/src/component/contentTypeMigration.ts +0 -1064
  226. package/src/component/contentTypeMutations.ts +0 -969
  227. package/src/component/contentTypes.ts +0 -346
  228. package/src/component/convex.config.ts +0 -44
  229. package/src/component/documentTypes.ts +0 -240
  230. package/src/component/eventEmitter.ts +0 -485
  231. package/src/component/exportImport.ts +0 -1169
  232. package/src/component/index.ts +0 -491
  233. package/src/component/lib/deepReferenceResolver.ts +0 -999
  234. package/src/component/lib/errors.ts +0 -816
  235. package/src/component/lib/index.ts +0 -145
  236. package/src/component/lib/mediaReferenceResolver.ts +0 -495
  237. package/src/component/lib/metadataExtractor.ts +0 -792
  238. package/src/component/lib/mutationAuth.ts +0 -199
  239. package/src/component/lib/queries.ts +0 -79
  240. package/src/component/lib/ragContentChunker.ts +0 -1371
  241. package/src/component/lib/referenceResolver.ts +0 -430
  242. package/src/component/lib/slugGenerator.ts +0 -262
  243. package/src/component/lib/slugUniqueness.ts +0 -333
  244. package/src/component/lib/softDelete.ts +0 -44
  245. package/src/component/localeFallbackChain.ts +0 -673
  246. package/src/component/localeFields.ts +0 -896
  247. package/src/component/mediaAssetMutations.ts +0 -725
  248. package/src/component/mediaAssets.ts +0 -932
  249. package/src/component/mediaFolderMutations.ts +0 -1046
  250. package/src/component/mediaUploadMutations.ts +0 -224
  251. package/src/component/mediaVariantMutations.ts +0 -900
  252. package/src/component/mediaVariants.ts +0 -793
  253. package/src/component/ragContentIndexer.ts +0 -1067
  254. package/src/component/rateLimitHooks.ts +0 -572
  255. package/src/component/roles.ts +0 -1360
  256. package/src/component/scheduledPublish.ts +0 -358
  257. package/src/component/schema.ts +0 -617
  258. package/src/component/taxonomies.ts +0 -949
  259. package/src/component/taxonomyMutations.ts +0 -1210
  260. package/src/component/trash.ts +0 -724
  261. package/src/component/userContext.ts +0 -898
  262. package/src/component/validation.ts +0 -1388
  263. package/src/component/validators.ts +0 -949
  264. package/src/component/versionMutations.ts +0 -392
  265. package/src/component/webhookTrigger.ts +0 -1922
  266. package/src/react/index.ts +0 -898
  267. package/src/test.ts +0 -1580
@@ -0,0 +1,12 @@
1
+ var prefix = "Invariant failed";
2
+ function invariant(condition, message) {
3
+ if (condition) {
4
+ return;
5
+ }
6
+ {
7
+ throw new Error(prefix);
8
+ }
9
+ }
10
+ export {
11
+ invariant as i
12
+ };
@@ -0,0 +1,5 @@
1
+ function warning(condition, message) {
2
+ }
3
+ export {
4
+ warning as w
5
+ };
@@ -0,0 +1,39 @@
1
+ var __assign = function() {
2
+ __assign = Object.assign || function __assign2(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
6
+ }
7
+ return t;
8
+ };
9
+ return __assign.apply(this, arguments);
10
+ };
11
+ function __rest(s, e) {
12
+ var t = {};
13
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
14
+ t[p] = s[p];
15
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
16
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
17
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
18
+ t[p[i]] = s[p[i]];
19
+ }
20
+ return t;
21
+ }
22
+ function __spreadArray(to, from, pack) {
23
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
24
+ if (ar || !(i in from)) {
25
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
26
+ ar[i] = from[i];
27
+ }
28
+ }
29
+ return to.concat(ar || Array.prototype.slice.call(from));
30
+ }
31
+ typeof SuppressedError === "function" ? SuppressedError : function(error, suppressed, message) {
32
+ var e = new Error(message);
33
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
34
+ };
35
+ export {
36
+ __assign as _,
37
+ __rest as a,
38
+ __spreadArray as b
39
+ };
@@ -0,0 +1,54 @@
1
+ const ENC_SLASH_RE = /%2f/gi;
2
+ function decode(text = "") {
3
+ try {
4
+ return decodeURIComponent("" + text);
5
+ } catch {
6
+ return "" + text;
7
+ }
8
+ }
9
+ function decodePath(text) {
10
+ return decode(text.replace(ENC_SLASH_RE, "%252F"));
11
+ }
12
+ const JOIN_LEADING_SLASH_RE = /^\.?\//;
13
+ function hasTrailingSlash(input = "", respectQueryAndFragment) {
14
+ {
15
+ return input.endsWith("/");
16
+ }
17
+ }
18
+ function withoutTrailingSlash(input = "", respectQueryAndFragment) {
19
+ {
20
+ return (hasTrailingSlash(input) ? input.slice(0, -1) : input) || "/";
21
+ }
22
+ }
23
+ function withTrailingSlash(input = "", respectQueryAndFragment) {
24
+ {
25
+ return input.endsWith("/") ? input : input + "/";
26
+ }
27
+ }
28
+ function hasLeadingSlash(input = "") {
29
+ return input.startsWith("/");
30
+ }
31
+ function withLeadingSlash(input = "") {
32
+ return hasLeadingSlash(input) ? input : "/" + input;
33
+ }
34
+ function isNonEmptyURL(url) {
35
+ return url && url !== "/";
36
+ }
37
+ function joinURL(base, ...input) {
38
+ let url = base || "";
39
+ for (const segment of input.filter((url2) => isNonEmptyURL(url2))) {
40
+ if (url) {
41
+ const _segment = segment.replace(JOIN_LEADING_SLASH_RE, "");
42
+ url = withTrailingSlash(url) + _segment;
43
+ } else {
44
+ url = segment;
45
+ }
46
+ }
47
+ return url;
48
+ }
49
+ export {
50
+ withoutTrailingSlash as a,
51
+ decodePath as d,
52
+ joinURL as j,
53
+ withLeadingSlash as w
54
+ };
@@ -0,0 +1 @@
1
+
@@ -0,0 +1,66 @@
1
+ import { r as reactExports } from "../_chunks/_libs/react.mjs";
2
+ function assignRef(ref, value) {
3
+ if (typeof ref === "function") {
4
+ ref(value);
5
+ } else if (ref) {
6
+ ref.current = value;
7
+ }
8
+ return ref;
9
+ }
10
+ function useCallbackRef(initialValue, callback) {
11
+ var ref = reactExports.useState(function() {
12
+ return {
13
+ // value
14
+ value: initialValue,
15
+ // last callback
16
+ callback,
17
+ // "memoized" public interface
18
+ facade: {
19
+ get current() {
20
+ return ref.value;
21
+ },
22
+ set current(value) {
23
+ var last = ref.value;
24
+ if (last !== value) {
25
+ ref.value = value;
26
+ ref.callback(value, last);
27
+ }
28
+ }
29
+ }
30
+ };
31
+ })[0];
32
+ ref.callback = callback;
33
+ return ref.facade;
34
+ }
35
+ var useIsomorphicLayoutEffect = typeof window !== "undefined" ? reactExports.useLayoutEffect : reactExports.useEffect;
36
+ var currentValues = /* @__PURE__ */ new WeakMap();
37
+ function useMergeRefs(refs, defaultValue) {
38
+ var callbackRef = useCallbackRef(null, function(newValue) {
39
+ return refs.forEach(function(ref) {
40
+ return assignRef(ref, newValue);
41
+ });
42
+ });
43
+ useIsomorphicLayoutEffect(function() {
44
+ var oldValue = currentValues.get(callbackRef);
45
+ if (oldValue) {
46
+ var prevRefs_1 = new Set(oldValue);
47
+ var nextRefs_1 = new Set(refs);
48
+ var current_1 = callbackRef.current;
49
+ prevRefs_1.forEach(function(ref) {
50
+ if (!nextRefs_1.has(ref)) {
51
+ assignRef(ref, null);
52
+ }
53
+ });
54
+ nextRefs_1.forEach(function(ref) {
55
+ if (!prevRefs_1.has(ref)) {
56
+ assignRef(ref, current_1);
57
+ }
58
+ });
59
+ }
60
+ currentValues.set(callbackRef, refs);
61
+ }, [refs]);
62
+ return callbackRef;
63
+ }
64
+ export {
65
+ useMergeRefs as u
66
+ };
@@ -0,0 +1,106 @@
1
+ import { _ as __assign, a as __rest } from "./tslib.mjs";
2
+ import { r as reactExports } from "../_chunks/_libs/react.mjs";
3
+ function ItoI(a) {
4
+ return a;
5
+ }
6
+ function innerCreateMedium(defaults, middleware) {
7
+ if (middleware === void 0) {
8
+ middleware = ItoI;
9
+ }
10
+ var buffer = [];
11
+ var assigned = false;
12
+ var medium = {
13
+ read: function() {
14
+ if (assigned) {
15
+ throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");
16
+ }
17
+ if (buffer.length) {
18
+ return buffer[buffer.length - 1];
19
+ }
20
+ return defaults;
21
+ },
22
+ useMedium: function(data) {
23
+ var item = middleware(data, assigned);
24
+ buffer.push(item);
25
+ return function() {
26
+ buffer = buffer.filter(function(x) {
27
+ return x !== item;
28
+ });
29
+ };
30
+ },
31
+ assignSyncMedium: function(cb) {
32
+ assigned = true;
33
+ while (buffer.length) {
34
+ var cbs = buffer;
35
+ buffer = [];
36
+ cbs.forEach(cb);
37
+ }
38
+ buffer = {
39
+ push: function(x) {
40
+ return cb(x);
41
+ },
42
+ filter: function() {
43
+ return buffer;
44
+ }
45
+ };
46
+ },
47
+ assignMedium: function(cb) {
48
+ assigned = true;
49
+ var pendingQueue = [];
50
+ if (buffer.length) {
51
+ var cbs = buffer;
52
+ buffer = [];
53
+ cbs.forEach(cb);
54
+ pendingQueue = buffer;
55
+ }
56
+ var executeQueue = function() {
57
+ var cbs2 = pendingQueue;
58
+ pendingQueue = [];
59
+ cbs2.forEach(cb);
60
+ };
61
+ var cycle = function() {
62
+ return Promise.resolve().then(executeQueue);
63
+ };
64
+ cycle();
65
+ buffer = {
66
+ push: function(x) {
67
+ pendingQueue.push(x);
68
+ cycle();
69
+ },
70
+ filter: function(filter) {
71
+ pendingQueue = pendingQueue.filter(filter);
72
+ return buffer;
73
+ }
74
+ };
75
+ }
76
+ };
77
+ return medium;
78
+ }
79
+ function createSidecarMedium(options) {
80
+ if (options === void 0) {
81
+ options = {};
82
+ }
83
+ var medium = innerCreateMedium(null);
84
+ medium.options = __assign({ async: true, ssr: false }, options);
85
+ return medium;
86
+ }
87
+ var SideCar = function(_a) {
88
+ var sideCar = _a.sideCar, rest = __rest(_a, ["sideCar"]);
89
+ if (!sideCar) {
90
+ throw new Error("Sidecar: please provide `sideCar` property to import the right car");
91
+ }
92
+ var Target = sideCar.read();
93
+ if (!Target) {
94
+ throw new Error("Sidecar medium not found");
95
+ }
96
+ return reactExports.createElement(Target, __assign({}, rest));
97
+ };
98
+ SideCar.isSideCarExport = true;
99
+ function exportSidecar(medium, exported) {
100
+ medium.useMedium(exported);
101
+ return SideCar;
102
+ }
103
+ export {
104
+ createSidecarMedium as c,
105
+ exportSidecar as e
106
+ };
@@ -0,0 +1,139 @@
1
+ import { b as requireReact } from "../_chunks/_libs/react.mjs";
2
+ var withSelector = { exports: {} };
3
+ var withSelector_production = {};
4
+ var shim = { exports: {} };
5
+ var useSyncExternalStoreShim_production = {};
6
+ var hasRequiredUseSyncExternalStoreShim_production;
7
+ function requireUseSyncExternalStoreShim_production() {
8
+ if (hasRequiredUseSyncExternalStoreShim_production) return useSyncExternalStoreShim_production;
9
+ hasRequiredUseSyncExternalStoreShim_production = 1;
10
+ var React = /* @__PURE__ */ requireReact();
11
+ function is(x, y) {
12
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
13
+ }
14
+ var objectIs = "function" === typeof Object.is ? Object.is : is, useState = React.useState, useEffect = React.useEffect, useLayoutEffect = React.useLayoutEffect, useDebugValue = React.useDebugValue;
15
+ function useSyncExternalStore$2(subscribe, getSnapshot) {
16
+ var value = getSnapshot(), _useState = useState({ inst: { value, getSnapshot } }), inst = _useState[0].inst, forceUpdate = _useState[1];
17
+ useLayoutEffect(
18
+ function() {
19
+ inst.value = value;
20
+ inst.getSnapshot = getSnapshot;
21
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
22
+ },
23
+ [subscribe, value, getSnapshot]
24
+ );
25
+ useEffect(
26
+ function() {
27
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
28
+ return subscribe(function() {
29
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
30
+ });
31
+ },
32
+ [subscribe]
33
+ );
34
+ useDebugValue(value);
35
+ return value;
36
+ }
37
+ function checkIfSnapshotChanged(inst) {
38
+ var latestGetSnapshot = inst.getSnapshot;
39
+ inst = inst.value;
40
+ try {
41
+ var nextValue = latestGetSnapshot();
42
+ return !objectIs(inst, nextValue);
43
+ } catch (error) {
44
+ return true;
45
+ }
46
+ }
47
+ function useSyncExternalStore$1(subscribe, getSnapshot) {
48
+ return getSnapshot();
49
+ }
50
+ var shim2 = "undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement ? useSyncExternalStore$1 : useSyncExternalStore$2;
51
+ useSyncExternalStoreShim_production.useSyncExternalStore = void 0 !== React.useSyncExternalStore ? React.useSyncExternalStore : shim2;
52
+ return useSyncExternalStoreShim_production;
53
+ }
54
+ var hasRequiredShim;
55
+ function requireShim() {
56
+ if (hasRequiredShim) return shim.exports;
57
+ hasRequiredShim = 1;
58
+ {
59
+ shim.exports = /* @__PURE__ */ requireUseSyncExternalStoreShim_production();
60
+ }
61
+ return shim.exports;
62
+ }
63
+ var hasRequiredWithSelector_production;
64
+ function requireWithSelector_production() {
65
+ if (hasRequiredWithSelector_production) return withSelector_production;
66
+ hasRequiredWithSelector_production = 1;
67
+ var React = /* @__PURE__ */ requireReact(), shim2 = /* @__PURE__ */ requireShim();
68
+ function is(x, y) {
69
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
70
+ }
71
+ var objectIs = "function" === typeof Object.is ? Object.is : is, useSyncExternalStore = shim2.useSyncExternalStore, useRef = React.useRef, useEffect = React.useEffect, useMemo = React.useMemo, useDebugValue = React.useDebugValue;
72
+ withSelector_production.useSyncExternalStoreWithSelector = function(subscribe, getSnapshot, getServerSnapshot, selector, isEqual) {
73
+ var instRef = useRef(null);
74
+ if (null === instRef.current) {
75
+ var inst = { hasValue: false, value: null };
76
+ instRef.current = inst;
77
+ } else inst = instRef.current;
78
+ instRef = useMemo(
79
+ function() {
80
+ function memoizedSelector(nextSnapshot) {
81
+ if (!hasMemo) {
82
+ hasMemo = true;
83
+ memoizedSnapshot = nextSnapshot;
84
+ nextSnapshot = selector(nextSnapshot);
85
+ if (void 0 !== isEqual && inst.hasValue) {
86
+ var currentSelection = inst.value;
87
+ if (isEqual(currentSelection, nextSnapshot))
88
+ return memoizedSelection = currentSelection;
89
+ }
90
+ return memoizedSelection = nextSnapshot;
91
+ }
92
+ currentSelection = memoizedSelection;
93
+ if (objectIs(memoizedSnapshot, nextSnapshot)) return currentSelection;
94
+ var nextSelection = selector(nextSnapshot);
95
+ if (void 0 !== isEqual && isEqual(currentSelection, nextSelection))
96
+ return memoizedSnapshot = nextSnapshot, currentSelection;
97
+ memoizedSnapshot = nextSnapshot;
98
+ return memoizedSelection = nextSelection;
99
+ }
100
+ var hasMemo = false, memoizedSnapshot, memoizedSelection, maybeGetServerSnapshot = void 0 === getServerSnapshot ? null : getServerSnapshot;
101
+ return [
102
+ function() {
103
+ return memoizedSelector(getSnapshot());
104
+ },
105
+ null === maybeGetServerSnapshot ? void 0 : function() {
106
+ return memoizedSelector(maybeGetServerSnapshot());
107
+ }
108
+ ];
109
+ },
110
+ [getSnapshot, getServerSnapshot, selector, isEqual]
111
+ );
112
+ var value = useSyncExternalStore(subscribe, instRef[0], instRef[1]);
113
+ useEffect(
114
+ function() {
115
+ inst.hasValue = true;
116
+ inst.value = value;
117
+ },
118
+ [value]
119
+ );
120
+ useDebugValue(value);
121
+ return value;
122
+ };
123
+ return withSelector_production;
124
+ }
125
+ var hasRequiredWithSelector;
126
+ function requireWithSelector() {
127
+ if (hasRequiredWithSelector) return withSelector.exports;
128
+ hasRequiredWithSelector = 1;
129
+ {
130
+ withSelector.exports = /* @__PURE__ */ requireWithSelector_production();
131
+ }
132
+ return withSelector.exports;
133
+ }
134
+ var withSelectorExports = /* @__PURE__ */ requireWithSelector();
135
+ var shimExports = /* @__PURE__ */ requireShim();
136
+ export {
137
+ shimExports as s,
138
+ withSelectorExports as w
139
+ };